Improve browser/Cordova compatibility

This commit is contained in:
Skylar Ittner 2022-04-03 22:17:18 -06:00
parent c68fc954a3
commit fe5a15d566

View File

@ -176,6 +176,7 @@ function initCordova() {
}, function (err) {});
window.htmlopen = window.open;
if (typeof device != "undefined" && device.platform != "browser") {
window.open = cordova.InAppBrowser.open;
openBrowser = function (url, options, onclose, onmessage) {
@ -208,6 +209,16 @@ function initCordova() {
openExternalBrowser = function (url) {
window.open(url, '_system', '');
}
} else {
// Running in browser, use a "real" window instead of an IAB one
openBrowser = function (url) {
window.open(url);
}
openExternalBrowser = function (url) {
window.open(url);
}
}
IonicDeeplink.onDeepLink(function (link) {
if (link.host != "helena.express") {