webtonative 1.0.76 → 1.0.78
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/ATTConsent/index.d.ts +16 -0
- package/ATTConsent/index.js +53 -1
- package/ATTConsent/types.d.ts +14 -0
- package/ATTConsent/types.js +2 -0
- package/AdMob/index.d.ts +30 -0
- package/AdMob/index.js +101 -1
- package/AdMob/types.d.ts +24 -0
- package/AdMob/types.js +3 -0
- package/AppReview/index.d.ts +6 -0
- package/AppReview/index.js +21 -1
- package/AppReview/types.d.ts +7 -0
- package/AppReview/types.js +3 -0
- package/AppsFlyer/index.d.ts +14 -0
- package/AppsFlyer/index.js +42 -4
- package/AppsFlyer/types.d.ts +9 -0
- package/AppsFlyer/types.js +2 -0
- package/BackgroundLocation/index.d.ts +11 -0
- package/BackgroundLocation/index.js +64 -4
- package/BackgroundLocation/types.d.ts +31 -0
- package/BackgroundLocation/types.js +2 -0
- package/Beacon/index.d.ts +6 -0
- package/Beacon/index.js +29 -1
- package/Beacon/types.d.ts +18 -0
- package/Beacon/types.js +2 -0
- package/Biometric/index.d.ts +26 -0
- package/Biometric/index.js +124 -1
- package/Biometric/types.d.ts +23 -0
- package/Biometric/types.js +2 -0
- package/Bluetooth/index.d.ts +16 -0
- package/Bluetooth/index.js +66 -1
- package/Bluetooth/types.d.ts +33 -0
- package/Bluetooth/types.js +2 -0
- package/BottomNavigation/index.d.ts +10 -0
- package/BottomNavigation/index.js +40 -4
- package/BottomNavigation/types.d.ts +8 -0
- package/BottomNavigation/types.js +2 -0
- package/Clipboard/index.d.ts +11 -0
- package/Clipboard/index.js +44 -4
- package/Clipboard/types.d.ts +19 -0
- package/Clipboard/types.js +3 -0
- package/Facebook/events.d.ts +12 -0
- package/Facebook/events.js +43 -4
- package/Facebook/index.d.ts +2 -0
- package/Facebook/index.js +28 -1
- package/Facebook/types.d.ts +21 -0
- package/Facebook/types.js +2 -0
- package/Firebase/Analytics/index.d.ts +31 -0
- package/Firebase/Analytics/index.js +109 -4
- package/Firebase/Messaging/index.d.ts +16 -0
- package/Firebase/Messaging/index.js +63 -4
- package/Firebase/index.d.ts +3 -0
- package/Firebase/index.js +30 -1
- package/Firebase/types.d.ts +57 -0
- package/Firebase/types.js +3 -0
- package/FirebaseAnalytics/index.d.ts +2 -0
- package/FirebaseAnalytics/index.js +28 -1
- package/Haptics/index.d.ts +6 -0
- package/Haptics/index.js +20 -1
- package/Haptics/types.d.ts +7 -0
- package/Haptics/types.js +2 -0
- package/InAppPurchase/index.d.ts +22 -0
- package/InAppPurchase/index.js +80 -1
- package/InAppPurchase/types.d.ts +33 -0
- package/InAppPurchase/types.js +2 -0
- package/InAppUpdate/index.d.ts +11 -0
- package/InAppUpdate/index.js +38 -1
- package/InAppUpdate/types.d.ts +14 -0
- package/InAppUpdate/types.js +2 -0
- package/MediaPlayer/index.d.ts +16 -0
- package/MediaPlayer/index.js +55 -7
- package/MediaPlayer/types.d.ts +13 -0
- package/MediaPlayer/types.js +2 -0
- package/NativeContacts/index.d.ts +11 -0
- package/NativeContacts/index.js +50 -6
- package/NativeContacts/types.d.ts +13 -0
- package/NativeContacts/types.js +2 -0
- package/NativeDatastore/index.d.ts +7 -0
- package/NativeDatastore/index.js +134 -1
- package/NativeDatastore/type.d.ts +23 -0
- package/NativeDatastore/type.js +2 -0
- package/Notification/index.d.ts +10 -0
- package/Notification/index.js +41 -5
- package/Notification/types.d.ts +13 -0
- package/Notification/types.js +2 -0
- package/OneSignal/index.d.ts +17 -0
- package/OneSignal/index.js +264 -1
- package/OneSignal/types.d.ts +40 -0
- package/OneSignal/types.js +3 -0
- package/Printing/index.d.ts +6 -0
- package/Printing/index.js +19 -1
- package/Printing/types.d.ts +8 -0
- package/Printing/types.js +2 -0
- package/README.md +31 -2
- package/Screen/index.d.ts +8 -0
- package/Screen/index.js +34 -4
- package/Screen/types.d.ts +5 -0
- package/Screen/types.js +3 -0
- package/Siri/index.d.ts +6 -0
- package/Siri/index.js +25 -1
- package/Siri/types.d.ts +13 -0
- package/Siri/types.js +2 -0
- package/SocialLogin/apple/index.d.ts +11 -0
- package/SocialLogin/apple/index.js +31 -0
- package/SocialLogin/facebook/index.d.ts +21 -0
- package/SocialLogin/facebook/index.js +60 -0
- package/SocialLogin/google/index.d.ts +21 -0
- package/SocialLogin/google/index.js +60 -0
- package/SocialLogin/index.d.ts +16 -0
- package/SocialLogin/index.js +22 -1
- package/SocialLogin/types.d.ts +38 -0
- package/SocialLogin/types.js +2 -0
- package/Stripe/index.d.ts +2 -0
- package/Stripe/index.js +48 -1
- package/Stripe/types.d.ts +31 -0
- package/Stripe/types.js +2 -0
- package/VoiceSearch/index.d.ts +12 -0
- package/VoiceSearch/index.js +33 -1
- package/VoiceSearch/types.d.ts +9 -0
- package/VoiceSearch/types.js +2 -0
- package/barcode/barcode-scan.d.ts +15 -0
- package/barcode/barcode-scan.js +39 -1
- package/barcode/barcode-types.d.ts +17 -0
- package/barcode/barcode-types.js +2 -0
- package/barcode/formats.d.ts +17 -0
- package/barcode/formats.js +22 -1
- package/barcode/index.d.ts +4 -0
- package/barcode/index.js +12 -1
- package/barcode/types.d.ts +16 -0
- package/barcode/types.js +21 -1
- package/index.d.ts +155 -0
- package/index.js +540 -2
- package/package.json +150 -3
- package/types/index.d.ts +49 -0
- package/types/index.js +3 -0
- package/utills.d.ts +11 -0
- package/utills.js +110 -1
- package/webtonative.min.js +1 -1
- package/SocialLogin/apple.js +0 -1
- package/SocialLogin/facebook.js +0 -9
- package/SocialLogin/google.js +0 -9
package/package.json
CHANGED
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "webtonative",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.78",
|
|
4
4
|
"description": "",
|
|
5
|
-
"main": "index.js",
|
|
5
|
+
"main": "build/index.js",
|
|
6
|
+
"types": "build/index.d.ts",
|
|
6
7
|
"scripts": {
|
|
7
|
-
"build": "rimraf build &&
|
|
8
|
+
"build": "rimraf build && tsc && ts-node buildScript.ts && npm run dist",
|
|
8
9
|
"test": "echo \"Error: no test specified\" && exit 1",
|
|
9
10
|
"dist": "NODE_ENV=production webpack --config webpack.config.js"
|
|
10
11
|
},
|
|
@@ -23,10 +24,156 @@
|
|
|
23
24
|
"@babel/cli": "^7.14.5",
|
|
24
25
|
"@babel/core": "^7.14.6",
|
|
25
26
|
"@babel/preset-env": "^7.14.7",
|
|
27
|
+
"@types/node": "^18.11.18",
|
|
26
28
|
"babel-loader": "^8.2.2",
|
|
27
29
|
"babel-preset-minify": "^0.5.1",
|
|
28
30
|
"rimraf": "^3.0.2",
|
|
31
|
+
"ts-loader": "^9.4.2",
|
|
32
|
+
"ts-node": "^10.9.1",
|
|
33
|
+
"typescript": "^4.9.4",
|
|
29
34
|
"webpack": "^5.40.0",
|
|
30
35
|
"webpack-cli": "^4.7.2"
|
|
36
|
+
},
|
|
37
|
+
"exports": {
|
|
38
|
+
".": {
|
|
39
|
+
"import": "./index.js",
|
|
40
|
+
"types": "./index.d.ts"
|
|
41
|
+
},
|
|
42
|
+
"./ATTConsent": {
|
|
43
|
+
"import": "./ATTConsent/index.js",
|
|
44
|
+
"types": "./ATTConsent/index.d.ts"
|
|
45
|
+
},
|
|
46
|
+
"./AdMob": {
|
|
47
|
+
"import": "./AdMob/index.js",
|
|
48
|
+
"types": "./AdMob/index.d.ts"
|
|
49
|
+
},
|
|
50
|
+
"./AppReview": {
|
|
51
|
+
"import": "./AppReview/index.js",
|
|
52
|
+
"types": "./AppReview/index.d.ts"
|
|
53
|
+
},
|
|
54
|
+
"./AppsFlyer": {
|
|
55
|
+
"import": "./AppsFlyer/index.js",
|
|
56
|
+
"types": "./AppsFlyer/index.d.ts"
|
|
57
|
+
},
|
|
58
|
+
"./BackgroundLocation": {
|
|
59
|
+
"import": "./BackgroundLocation/index.js",
|
|
60
|
+
"types": "./BackgroundLocation/index.d.ts"
|
|
61
|
+
},
|
|
62
|
+
"./Beacon": {
|
|
63
|
+
"import": "./Beacon/index.js",
|
|
64
|
+
"types": "./Beacon/index.d.ts"
|
|
65
|
+
},
|
|
66
|
+
"./Biometric": {
|
|
67
|
+
"import": "./Biometric/index.js",
|
|
68
|
+
"types": "./Biometric/index.d.ts"
|
|
69
|
+
},
|
|
70
|
+
"./Bluetooth": {
|
|
71
|
+
"import": "./Bluetooth/index.js",
|
|
72
|
+
"types": "./Bluetooth/index.d.ts"
|
|
73
|
+
},
|
|
74
|
+
"./BottomNavigation": {
|
|
75
|
+
"import": "./BottomNavigation/index.js",
|
|
76
|
+
"types": "./BottomNavigation/index.d.ts"
|
|
77
|
+
},
|
|
78
|
+
"./Clipboard": {
|
|
79
|
+
"import": "./Clipboard/index.js",
|
|
80
|
+
"types": "./Clipboard/index.d.ts"
|
|
81
|
+
},
|
|
82
|
+
"./Facebook": {
|
|
83
|
+
"import": "./Facebook/index.js",
|
|
84
|
+
"types": "./Facebook/index.d.ts"
|
|
85
|
+
},
|
|
86
|
+
"./Firebase": {
|
|
87
|
+
"import": "./Firebase/index.js",
|
|
88
|
+
"types": "./Firebase/index.d.ts"
|
|
89
|
+
},
|
|
90
|
+
"./Firebase/Analytics": {
|
|
91
|
+
"import": "./Firebase/Analytics/index.js",
|
|
92
|
+
"types": "./Firebase/Analytics/index.d.ts"
|
|
93
|
+
},
|
|
94
|
+
"./Firebase/Messaging": {
|
|
95
|
+
"import": "./Firebase/Messaging/index.js",
|
|
96
|
+
"types": "./Firebase/Messaging/index.d.ts"
|
|
97
|
+
},
|
|
98
|
+
"./FirebaseAnalytics": {
|
|
99
|
+
"import": "./FirebaseAnalytics/index.js",
|
|
100
|
+
"types": "./FirebaseAnalytics/index.d.ts"
|
|
101
|
+
},
|
|
102
|
+
"./Haptics": {
|
|
103
|
+
"import": "./Haptics/index.js",
|
|
104
|
+
"types": "./Haptics/index.d.ts"
|
|
105
|
+
},
|
|
106
|
+
"./InAppPurchase": {
|
|
107
|
+
"import": "./InAppPurchase/index.js",
|
|
108
|
+
"types": "./InAppPurchase/index.d.ts"
|
|
109
|
+
},
|
|
110
|
+
"./InAppUpdate": {
|
|
111
|
+
"import": "./InAppUpdate/index.js",
|
|
112
|
+
"types": "./InAppUpdate/index.d.ts"
|
|
113
|
+
},
|
|
114
|
+
"./MediaPlayer": {
|
|
115
|
+
"import": "./MediaPlayer/index.js",
|
|
116
|
+
"types": "./MediaPlayer/index.d.ts"
|
|
117
|
+
},
|
|
118
|
+
"./NativeContacts": {
|
|
119
|
+
"import": "./NativeContacts/index.js",
|
|
120
|
+
"types": "./NativeContacts/index.d.ts"
|
|
121
|
+
},
|
|
122
|
+
"./NativeDatastore": {
|
|
123
|
+
"import": "./NativeDatastore/index.js",
|
|
124
|
+
"types": "./NativeDatastore/index.d.ts"
|
|
125
|
+
},
|
|
126
|
+
"./Notification": {
|
|
127
|
+
"import": "./Notification/index.js",
|
|
128
|
+
"types": "./Notification/index.d.ts"
|
|
129
|
+
},
|
|
130
|
+
"./OneSignal": {
|
|
131
|
+
"import": "./OneSignal/index.js",
|
|
132
|
+
"types": "./OneSignal/index.d.ts"
|
|
133
|
+
},
|
|
134
|
+
"./Printing": {
|
|
135
|
+
"import": "./Printing/index.js",
|
|
136
|
+
"types": "./Printing/index.d.ts"
|
|
137
|
+
},
|
|
138
|
+
"./Screen": {
|
|
139
|
+
"import": "./Screen/index.js",
|
|
140
|
+
"types": "./Screen/index.d.ts"
|
|
141
|
+
},
|
|
142
|
+
"./Siri": {
|
|
143
|
+
"import": "./Siri/index.js",
|
|
144
|
+
"types": "./Siri/index.d.ts"
|
|
145
|
+
},
|
|
146
|
+
"./SocialLogin": {
|
|
147
|
+
"import": "./SocialLogin/index.js",
|
|
148
|
+
"types": "./SocialLogin/index.d.ts"
|
|
149
|
+
},
|
|
150
|
+
"./SocialLogin/apple": {
|
|
151
|
+
"import": "./SocialLogin/apple/index.js",
|
|
152
|
+
"types": "./SocialLogin/apple/index.d.ts"
|
|
153
|
+
},
|
|
154
|
+
"./SocialLogin/facebook": {
|
|
155
|
+
"import": "./SocialLogin/facebook/index.js",
|
|
156
|
+
"types": "./SocialLogin/facebook/index.d.ts"
|
|
157
|
+
},
|
|
158
|
+
"./SocialLogin/google": {
|
|
159
|
+
"import": "./SocialLogin/google/index.js",
|
|
160
|
+
"types": "./SocialLogin/google/index.d.ts"
|
|
161
|
+
},
|
|
162
|
+
"./Stripe": {
|
|
163
|
+
"import": "./Stripe/index.js",
|
|
164
|
+
"types": "./Stripe/index.d.ts"
|
|
165
|
+
},
|
|
166
|
+
"./VoiceSearch": {
|
|
167
|
+
"import": "./VoiceSearch/index.js",
|
|
168
|
+
"types": "./VoiceSearch/index.d.ts"
|
|
169
|
+
},
|
|
170
|
+
"./barcode": {
|
|
171
|
+
"import": "./barcode/index.js",
|
|
172
|
+
"types": "./barcode/index.d.ts"
|
|
173
|
+
},
|
|
174
|
+
"./types": {
|
|
175
|
+
"import": "./types/index.js",
|
|
176
|
+
"types": "./types/index.d.ts"
|
|
177
|
+
}
|
|
31
178
|
}
|
|
32
179
|
}
|
package/types/index.d.ts
ADDED
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
export type Platform = "ANDROID_APP" | "IOS_APP" | "WEBSITE";
|
|
2
|
+
export interface BaseResponse {
|
|
3
|
+
type: string;
|
|
4
|
+
[key: string]: any;
|
|
5
|
+
}
|
|
6
|
+
export interface BaseCallback {
|
|
7
|
+
(response: BaseResponse): void;
|
|
8
|
+
}
|
|
9
|
+
export type CallbackFunction = (response: any) => void;
|
|
10
|
+
export interface RegisterCallbackOptions {
|
|
11
|
+
key?: string;
|
|
12
|
+
ignoreDelete?: boolean;
|
|
13
|
+
}
|
|
14
|
+
export interface StatusBarOptions {
|
|
15
|
+
color?: string;
|
|
16
|
+
style?: "light" | "dark";
|
|
17
|
+
overlay?: boolean;
|
|
18
|
+
}
|
|
19
|
+
export interface DownloadBlobFileOptions {
|
|
20
|
+
fileName: string;
|
|
21
|
+
downloadUrl: string;
|
|
22
|
+
}
|
|
23
|
+
export interface CustomFileDownloadOptions {
|
|
24
|
+
downloadUrl: string;
|
|
25
|
+
fileName: string;
|
|
26
|
+
isBlob?: boolean;
|
|
27
|
+
mimeType?: string;
|
|
28
|
+
cookies?: string;
|
|
29
|
+
userAgent?: string;
|
|
30
|
+
openFileAfterDownload?: boolean;
|
|
31
|
+
}
|
|
32
|
+
export interface DeviceInfoResponse {
|
|
33
|
+
[key: string]: any;
|
|
34
|
+
}
|
|
35
|
+
export interface WebToNativeInterface {
|
|
36
|
+
getAndroidVersion?: () => string;
|
|
37
|
+
hideSplashScreen?: () => void;
|
|
38
|
+
statusBar?: (options: string) => void;
|
|
39
|
+
downloadFile?: (options: string) => void;
|
|
40
|
+
getDeviceInfo?: () => void;
|
|
41
|
+
showInAppReview?: () => void;
|
|
42
|
+
startScanner?: (options: string) => void;
|
|
43
|
+
androidCBHook?: (results: string) => void;
|
|
44
|
+
androidAdMobCBHook?: (results: string) => void;
|
|
45
|
+
[key: string]: any;
|
|
46
|
+
}
|
|
47
|
+
export interface WebToNativeIosInterface {
|
|
48
|
+
postMessage: (message: any) => void;
|
|
49
|
+
}
|
package/types/index.js
ADDED
package/utills.d.ts
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Platform, WebToNativeInterface, WebToNativeIosInterface, CallbackFunction, RegisterCallbackOptions } from './types';
|
|
2
|
+
declare const isClient: boolean;
|
|
3
|
+
declare const webToNative: WebToNativeInterface;
|
|
4
|
+
declare const webToNativeIos: WebToNativeIosInterface | false;
|
|
5
|
+
declare const platform: Platform;
|
|
6
|
+
declare const isNativeApp: boolean;
|
|
7
|
+
declare const registerCb: (cb: CallbackFunction, obj?: RegisterCallbackOptions) => void;
|
|
8
|
+
declare const registerForAbMobCb: (cb: CallbackFunction) => void;
|
|
9
|
+
declare const deRegisterForAbMobCb: () => void;
|
|
10
|
+
declare const deRegisterCbByKey: (key: string | number) => void;
|
|
11
|
+
export { webToNative, isClient, webToNativeIos, platform, isNativeApp, registerCb, registerForAbMobCb, deRegisterForAbMobCb, deRegisterCbByKey, };
|
package/utills.js
CHANGED
|
@@ -1 +1,110 @@
|
|
|
1
|
-
"use strict";
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.deRegisterCbByKey = exports.deRegisterForAbMobCb = exports.registerForAbMobCb = exports.registerCb = exports.isNativeApp = exports.platform = exports.webToNativeIos = exports.isClient = exports.webToNative = void 0;
|
|
4
|
+
var isClient = typeof window !== "undefined";
|
|
5
|
+
exports.isClient = isClient;
|
|
6
|
+
var webToNative = (isClient && window.WebToNativeInterface) || {};
|
|
7
|
+
exports.webToNative = webToNative;
|
|
8
|
+
var webToNativeIos = isClient &&
|
|
9
|
+
window.webkit &&
|
|
10
|
+
window.webkit.messageHandlers &&
|
|
11
|
+
window.webkit.messageHandlers.webToNativeInterface;
|
|
12
|
+
exports.webToNativeIos = webToNativeIos;
|
|
13
|
+
var platform = webToNative.getAndroidVersion
|
|
14
|
+
? "ANDROID_APP"
|
|
15
|
+
: webToNativeIos
|
|
16
|
+
? "IOS_APP"
|
|
17
|
+
: "WEBSITE";
|
|
18
|
+
exports.platform = platform;
|
|
19
|
+
var isNativeApp = isClient && platform !== "WEBSITE";
|
|
20
|
+
exports.isNativeApp = isNativeApp;
|
|
21
|
+
var cbObj = {};
|
|
22
|
+
var counter = 1;
|
|
23
|
+
var abMobCb = null;
|
|
24
|
+
if (isNativeApp) {
|
|
25
|
+
webToNative.androidCBHook = function (results) {
|
|
26
|
+
var response = results;
|
|
27
|
+
try {
|
|
28
|
+
response = JSON.parse(results);
|
|
29
|
+
}
|
|
30
|
+
catch (e) {
|
|
31
|
+
console.log(e);
|
|
32
|
+
}
|
|
33
|
+
var type = response.type;
|
|
34
|
+
for (var key in cbObj) {
|
|
35
|
+
var _a = cbObj[key], cb = _a.cb, _b = _a.ignoreDelete, ignoreDelete = _b === void 0 ? false : _b;
|
|
36
|
+
if (response && response.reqType) {
|
|
37
|
+
if (key == response["reqType"]) {
|
|
38
|
+
cb(response);
|
|
39
|
+
if (!ignoreDelete) {
|
|
40
|
+
delete cbObj[key];
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
else {
|
|
45
|
+
cb(response);
|
|
46
|
+
if (!ignoreDelete) {
|
|
47
|
+
delete cbObj[key];
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
};
|
|
52
|
+
window.iOSAdMobCBHook = webToNative.androidAdMobCBHook = function (results) {
|
|
53
|
+
var responseObj = JSON.parse(results);
|
|
54
|
+
abMobCb && abMobCb(responseObj);
|
|
55
|
+
};
|
|
56
|
+
window.iosCBHook = function (results) {
|
|
57
|
+
var response = results;
|
|
58
|
+
try {
|
|
59
|
+
response = JSON.parse(results);
|
|
60
|
+
}
|
|
61
|
+
catch (e) {
|
|
62
|
+
console.log(e);
|
|
63
|
+
}
|
|
64
|
+
for (var key in cbObj) {
|
|
65
|
+
var _a = cbObj[key], cb = _a.cb, _b = _a.ignoreDelete, ignoreDelete = _b === void 0 ? false : _b;
|
|
66
|
+
if (response && response.reqType) {
|
|
67
|
+
if (key == response["reqType"]) {
|
|
68
|
+
cb(response);
|
|
69
|
+
if (!ignoreDelete) {
|
|
70
|
+
delete cbObj[key];
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
else {
|
|
75
|
+
cb(response);
|
|
76
|
+
if (!ignoreDelete) {
|
|
77
|
+
delete cbObj[key];
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
};
|
|
82
|
+
}
|
|
83
|
+
var registerCb = function (cb, obj) {
|
|
84
|
+
if (typeof cb === "function") {
|
|
85
|
+
if (obj && obj.key) {
|
|
86
|
+
cbObj[obj["key"]] = { cb: cb, ignoreDelete: obj.ignoreDelete ? true : false };
|
|
87
|
+
}
|
|
88
|
+
else {
|
|
89
|
+
cbObj[counter] = { cb: cb, ignoreDelete: obj && obj.ignoreDelete ? true : false };
|
|
90
|
+
counter += 1;
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
};
|
|
94
|
+
exports.registerCb = registerCb;
|
|
95
|
+
var registerForAbMobCb = function (cb) {
|
|
96
|
+
if (typeof cb === "function") {
|
|
97
|
+
abMobCb = cb;
|
|
98
|
+
}
|
|
99
|
+
};
|
|
100
|
+
exports.registerForAbMobCb = registerForAbMobCb;
|
|
101
|
+
var deRegisterForAbMobCb = function () {
|
|
102
|
+
if (abMobCb) {
|
|
103
|
+
abMobCb = null;
|
|
104
|
+
}
|
|
105
|
+
};
|
|
106
|
+
exports.deRegisterForAbMobCb = deRegisterForAbMobCb;
|
|
107
|
+
var deRegisterCbByKey = function (key) {
|
|
108
|
+
delete cbObj[key];
|
|
109
|
+
};
|
|
110
|
+
exports.deRegisterCbByKey = deRegisterCbByKey;
|
package/webtonative.min.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(){"use strict";var e={d:function(n,t){for(var i in t)e.o(t,i)&&!e.o(n,i)&&Object.defineProperty(n,i,{enumerable:!0,get:t[i]})},o:function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},r:function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}},n={};e.r(n),e.d(n,{addToSiri:function(){return ce},appFirstLoad:function(){return se},checkPermission:function(){return De},clearAppCache:function(){return ee},closeApp:function(){return te},customBackHandling:function(){return pe},customFileDownload:function(){return G},default:function(){return Ne},deviceInfo:function(){return z},disableScreenshot:function(){return de},downloadBlobFile:function(){return K},downloadFile:function(){return q},enablePullToRefresh:function(){return $},forceUpdateCookies:function(){return ue},getAddOnStatus:function(){return Oe},getSafeArea:function(){return fe},hideNativeComponents:function(){return Ie},hideSplashScreen:function(){return H},isAndroidApp:function(){return L},isAndroidORIosApp:function(){return j},isDeviceGPSEnabled:function(){return Q},isIosApp:function(){return V},isNativeApp:function(){return C},loadOfferCard:function(){return re},nfcSupported:function(){return ae},openAppSettingForPermission:function(){return Pe},openUrlInBrowser:function(){return Y},platform:function(){return M},printFunction:function(){return oe},registerNotification:function(){return Se},setOrientation:function(){return ge},shareFile:function(){return ne},shareLink:function(){return Z},showDateTimePicker:function(){return ie},showInAppReview:function(){return X},showNativeComponents:function(){return _e},showPermission:function(){return Ae},statusBar:function(){return x},updateAppIcon:function(){return le}});var t={};e.r(t),e.d(t,{addTrigger:function(){return Re},addTriggers:function(){return we},getPlayerId:function(){return ve},getTriggerValue:function(){return Te},getTriggers:function(){return Me},logoutEmail:function(){return Ee},logoutSMSNumber:function(){return Be},optInUser:function(){return We},optOutUser:function(){return Ue},removeExternalUserId:function(){return me},removeTrigger:function(){return be},removeTriggers:function(){return ke},setEmail:function(){return Ce},setExternalUserId:function(){return ye},setSMSNumber:function(){return Fe},setTags:function(){return he}});var i={};e.r(i),e.d(i,{BarcodeScan:function(){return He},Format:function(){return Ve},Types:function(){return je}});var o={};e.r(o),e.d(o,{bannerAd:function(){return Ke},fullScreenAd:function(){return Ge},rewardsAd:function(){return ze}});var a={};e.r(a),e.d(a,{logEvent:function(){return Ze},setCustomerUserId:function(){return Qe}});var r={};e.r(r),e.d(r,{send:function(){return Ye},sendPurchase:function(){return $e}});var c={};e.r(c),e.d(c,{hide:function(){return en},show:function(){return nn}});var s={};e.r(s),e.d(s,{getAll:function(){return on},getPermissionStatus:function(){return tn}});var u={};e.r(u),e.d(u,{start:function(){return an},stop:function(){return rn}});var P={};e.r(P),e.d(P,{keepScreenNormal:function(){return sn},keepScreenOn:function(){return cn}});var A={};e.r(A),e.d(A,{get:function(){return un},set:function(){return Pn}});var l={};e.r(l),e.d(l,{prompt:function(){return An}});var d={};e.r(d),e.d(d,{biometricAuthWithDismissOnCancel:function(){return On},checkStatus:function(){return ln},deleteSecret:function(){return pn},saveSecret:function(){return dn},show:function(){return fn}});var p={};e.r(p),e.d(p,{request:function(){return Dn},status:function(){return gn}});var f={};e.r(f),e.d(f,{logEvent:function(){return vn},logScreen:function(){return yn},setCollection:function(){return In},setDefaultEventParameters:function(){return Nn},setUserId:function(){return _n},setUserProperty:function(){return Sn}});var O={};e.r(O),e.d(O,{events:function(){return f}});var D={};e.r(D),e.d(D,{getFCMToken:function(){return Rn},subscribe:function(){return mn},unsubscribe:function(){return hn}});var g={};e.r(g),e.d(g,{Analytics:function(){return f},Messaging:function(){return D}});var I={};e.r(I),e.d(I,{trigger:function(){return wn}});var _={};e.r(_),e.d(_,{pauseMedia:function(){return kn},playMedia:function(){return bn},stopMedia:function(){return Tn}});var S={};e.r(S),e.d(S,{setPrintSize:function(){return Mn}});var N={};e.r(N),e.d(N,{checkNotificationPermission:function(){return Cn},openAppNotificationPage:function(){return Fn}});var v={};e.r(v),e.d(v,{pairDevice:function(){return Bn},startBluetoothScan:function(){return En},unpairDevice:function(){return Wn}});var y={};e.r(y),e.d(y,{makeTapToPay:function(){return Ln}});var m={};e.r(m),e.d(m,{checkIfAppUpdateAvailable:function(){return Vn},updateApplication:function(){return jn}});var h={};e.r(h),e.d(h,{addToSiri:function(){return Hn}});var R={};e.r(R),e.d(R,{initBeaconData:function(){return xn}});var w={};e.r(w),e.d(w,{deleteAppData:function(){return Gn},deleteCloudData:function(){return Qn},getAppData:function(){return Kn},getCloudData:function(){return Xn},setAppData:function(){return qn},setCloudData:function(){return zn}});var b="undefined"!=typeof window,k=b&&window.WebToNativeInterface||{},T=b&&window.webkit&&window.webkit.messageHandlers&&window.webkit.messageHandlers.webToNativeInterface,M=k.getAndroidVersion?"ANDROID_APP":T?"IOS_APP":"WEBSITE",C=b&&"WEBSITE"!==M,F={},E=1,B=null;C&&(k.androidCBHook=function(e){var n=e;try{n=JSON.parse(e)}catch(e){console.log(e)}for(var t in n.type,F){var i=F[t],o=i.cb,a=i.ignoreDelete,r=void 0!==a&&a;n&&n.reqType?t==n.reqType&&(o(n),r||delete F[t]):(o(n),r||delete F[t])}},window.iOSAdMobCBHook=k.androidAdMobCBHook=function(e){var n=JSON.parse(e);B&&B(n)},window.iosCBHook=function(e){var n=e;try{n=JSON.parse(e)}catch(e){console.log(e)}for(var t in F){var i=F[t],o=i.cb,a=i.ignoreDelete,r=void 0!==a&&a;n&&n.reqType?t==n.reqType&&(o(n),r||delete F[t]):(o(n),r||delete F[t])}});var W=function(e,n){"function"==typeof e&&(n&&n.key?F[n.key]={cb:e,ignoreDelete:!!n.ignoreDelete}:(F[E]={cb:e,ignoreDelete:!(!n||!n.ignoreDelete)},E+=1))},U=function(e){"function"==typeof e&&(B=e)},J=function(){B&&(B=null)},L="ANDROID_APP"===M,V="IOS_APP"===M,j=["ANDROID_APP","IOS_APP"].includes(M),H=function(){C&&k.hideSplashScreen()},x=function(e){C&&(L?k.statusBar(JSON.stringify(e)):V&&T.postMessage({action:"statusBar",color:e.color,style:e.style}))},q=function(e){C&&(L||V&&T.postMessage({action:"downloadFile",downloadUrl:e}))},K=function(e){var n=e.fileName,t=e.downloadUrl;["IOS_APP"].includes(M)&&V&&T.postMessage({action:"downloadBlobFile",fileName:n,url:t})},G=function(e){var n=e.downloadUrl,t=e.fileName,i=e.isBlob,o=e.mimeType,a=e.cookies,r=e.userAgent,c=e.openFileAfterDownload;["ANDROID_APP"].includes(M)&&"ANDROID_APP"===M&&k.downloadFile(JSON.stringify({url:n,fileName:t,isBlob:i,mimeType:o,cookies:a,userAgent:r,openFileAfterDownload:c}))},z=function(){return new Promise((function(e,n){W((function(t){t?e(t):n({err:"Error getting device info"})}),{key:"deviceInfo"}),"ANDROID_APP"===M?k.getDeviceInfo():"IOS_APP"===M?T.postMessage({action:"deviceInfo"}):n("This function will work in Native App Powered By WebToNative")}))},X=function(){C&&k.showInAppReview()},Q=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.callback;["ANDROID_APP","IOS_APP"].includes(M)&&(W((function(e){"isDeviceGPSEnabled"===e.type&&n&&n(e)})),"ANDROID_APP"===M&&k.isLocationServiceEnabled())},Z=function(e){var n=e.url,t=void 0===n?"":n;if(!t)throw"url is mandatory";L&&k.openShareIntent(t),V&&T.postMessage({action:"share",url:t})},Y=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";if(!e)throw"url is mandatory";L&&k.openUrlInBrowser(e)},$=function(e){L&&k.enableSwipeRefresh(e)},ee=function(e){L&&k.clearWebViewCache(JSON.stringify({reload:e}))},ne=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;L&&k.shareFile(e,n,t)},te=function(){L&&k.closeApp(),V&&T.postMessage({action:"closeApp"})},ie=function(e){if(["ANDROID_APP"].includes(M)){var n=e.callback,t=e.showDate,i=e.showTime;W((function(e){"DATE_TIME_PICKER"===e.type&&n&&n(e)})),L&&k.pickDateTime(JSON.stringify({showDate:t,showTime:i}))}},oe=function(e){if(["ANDROID_APP"].includes(M)){var n=e.type,t=void 0===n?"url":n,i=e.url,o=void 0===i?"":i;L&&k.print(JSON.stringify({type:t,url:o}))}},ae=function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.callback;W((function(e){"nfcSupported"===e.type&&n&&n(e)})),L&&k.nfcSupported(),V&&T.postMessage({action:"nfcSupported"})}},re=function(e){["ANDROID_APP","IOS_APP"].includes(M)&&(L&&k.showOfferCard(JSON.stringify(e)),e.data&&(e.data=JSON.stringify(e.data)),V&&T.postMessage(e))},ce=function(e){["IOS_APP"].includes(M)&&(e.data&&(e.data=JSON.stringify(e.data)),V&&T.postMessage(e))},se=function(){return new Promise((function(e,n){W((function(t){"firstCallWhenAppStarted"===t.type&&(t?e(t):n({err:"Error getting request"}))}),{key:"firstCallWhenAppStarted"}),"ANDROID_APP"===M?k.firstCallWhenAppStarted():"IOS_APP"===M?T.postMessage({action:"firstCallWhenAppStarted"}):n("This function will work in Native App Powered By WebToNative")}))},ue=function(){["ANDROID_APP"].includes(M)&&L&&k.forceUpdateCookies()},Pe=function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.callback,t=e.values;W((function(e){var t=e.type;e.typeValue,"openAppSettingForPermission"===t&&n&&n(e)})),L&&k.openAppSettingForPermission(t),V&&T.postMessage({action:"openAppSettingForPermission",values:t})}},Ae=function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.callback,t=e.permission,i=e.openAppSetting,o=void 0!==i&&i,a=e.alertDialogStyle;W((function(e){var t=e.type,i=e.typeValue;"showPermission"!==t&&"showPermission"!==i||n&&n(e)})),L&&k.showPermission(JSON.stringify({permission:t,openAppSetting:o,alertDialogStyle:a})),V&&T.postMessage({action:"showPermission",permission:t,openAppSetting:o,alertDialogStyle:a})}},le=function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.active,t=void 0!==n&&n,i=e.iconName,o=void 0===i?null:i;L&&k.updateAppIcon(JSON.stringify({active:t,iconName:o})),V&&T.postMessage({action:"updateAppIcon",iconName:o,active:t})}},de=function(e){if(["IOS_APP"].includes(M)){var n=e.ssKey,t=void 0!==n&&n;V&&T.postMessage({action:"disableScreenshotForPage",ssKey:t})}},pe=function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.enable,t=void 0!==n&&n;L&&k.customBackHandling(JSON.stringify({enable:t})),V&&T.postMessage({action:"customBackHandling",enable:t})}},fe=function(e){if(["IOS_APP"].includes(M)){var n=e.callback;W((function(e){"getSafeArea"===e.type&&n&&n(e)})),V&&T.postMessage({action:"getSafeArea"})}},Oe=function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.callback,t=e.addOnName;W((function(e){"getAddOnStatus"===e.type&&n&&n(e)})),L&&k.getAddOnStatus(JSON.stringify({addOnName:t})),V&&T.postMessage({action:"getAddOnStatus",addOnName:t})}},De=function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.callback,t=e.permissionName;W((function(e){"checkPermission"===e.type&&n&&n(e)})),L&&k.checkPermission(JSON.stringify(t)),V&&T.postMessage({action:"checkPermission",permissionName:t})}},ge=function(e){if(["ANDROID_APP"].includes(M)){var n=e.orientation,t=e.forceOrientation,i=void 0!==t&&t;L&&k.setOrientation(JSON.stringify({orientation:n,forceOrientation:i}))}},Ie=function(e){if(j){var n=(e||{}).components;L&&k.hideNativeComponents(JSON.stringify(e)),V&&T.postMessage({action:"hideNativeComponents",components:n})}},_e=function(e){if(j){var n=(e||{}).components;L&&k.checkPermission(JSON.stringify(e)),V&&T.postMessage({action:"showNativeComponents",components:n})}},Se=function(e){if(j){var n=(e||{}).callback;W((function(e){"registerNotification"===e.type&&n&&n(e)})),L&&k.registerNotification(),V&&T.postMessage({action:"registerNotification"})}},Ne={isAndroidApp:L,isIosApp:V,hideSplashScreen:H,statusBar:x,deviceInfo:z,showInAppReview:X,shareLink:Z,platform:M,isNativeApp:C,isDeviceGPSEnabled:Q,openUrlInBrowser:Y,enablePullToRefresh:$,shareFile:ne,clearAppCache:ee,closeApp:te,showDateTimePicker:ie,downloadBlobFile:K,customFileDownload:G,printFunction:oe,loadOfferCard:re,appFirstLoad:se,addToSiri:ce,showPermission:Ae,forceUpdateCookies:ue,updateAppIcon:le,disableScreenshot:de,getSafeArea:fe,getAddOnStatus:Oe,setOrientation:ge,checkPermission:De,openAppSettingForPermission:Pe,customBackHandling:pe,hideNativeComponents:Ie,showNativeComponents:_e,registerNotification:Se},ve=function(){return new Promise((function(e,n){W((function(t){t.isSuccess?e(t.playerId):n(t)}),{key:"getPlayerId"}),"ANDROID_APP"===M?k.getOneSignalId():"IOS_APP"===M?T.postMessage({action:"getPlayerId"}):n("This function will work in Native App Powered By WebToNative")}))},ye=function(e){if(!e)throw"userId is required";if("ANDROID_APP"===M)return C&&k.setExternalUserId(e);"IOS_APP"===M&&T.postMessage({action:"setExternalUserId",userId:e})},me=function(){if("ANDROID_APP"===M)return C&&k.removeExternalUserId();"IOS_APP"===M&&T.postMessage({action:"removeExternalUserId"})},he=function(e){var n=e.tags;if(n){if("ANDROID_APP"===M)return C&&k.setUserTags(JSON.stringify(n));"IOS_APP"===M&&T.postMessage({action:"setUserTags",tags:n})}},Re=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.key,t=e.value;"ANDROID_APP"===M?k.addTrigger(JSON.stringify({key:n,value:t})):"IOS_APP"===M&&T.postMessage({action:"addTrigger",key:n,value:t})},we=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.triggers;"ANDROID_APP"===M?k.addTriggers(JSON.stringify({triggers:n})):"IOS_APP"===M&&T.postMessage({action:"addTriggers",triggers:n})},be=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.key;"ANDROID_APP"===M?k.removeTriggerForKey(n):"IOS_APP"===M&&T.postMessage({action:"removeTrigger",key:n})},ke=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.keys;"ANDROID_APP"===M?k.removeTriggersForKeys(JSON.stringify({keys:n})):"IOS_APP"===M&&T.postMessage({action:"removeTriggers",keys:n})},Te=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.key,t=e.callback;["ANDROID_APP","IOS_APP"].includes(M)&&(W((function(e){"getTriggerValue"===e.type&&t&&t(e)})),"ANDROID_APP"===M?k.getTriggerValueForKey(n):"IOS_APP"===M&&T.postMessage({action:"getTriggerValue",key:n}))},Me=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.callback;["ANDROID_APP","IOS_APP"].includes(M)&&(W((function(e){"getTriggers"===e.type&&n&&n(e)})),"ANDROID_APP"===M?k.getTriggers():"IOS_APP"===M&&T.postMessage({action:"getTriggers"}))},Ce=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.emailId;["ANDROID_APP","IOS_APP"].includes(M)&&"ANDROID_APP"===M&&k.setEmail(n)},Fe=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.smsNumber;["ANDROID_APP","IOS_APP"].includes(M)&&"ANDROID_APP"===M&&k.setSMSNumber(n)},Ee=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.emailId;["ANDROID_APP","IOS_APP"].includes(M)&&"ANDROID_APP"===M&&k.logoutEmail(n)},Be=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.smsNumber;["ANDROID_APP","IOS_APP"].includes(M)&&"ANDROID_APP"===M&&k.logoutSMSNumber(n)},We=function(){"ANDROID_APP"===M?k.optInOneSignalPermissionDialog():"IOS_APP"===M&&T.postMessage({action:"optInOneSignalPermissionDialog"})},Ue=function(){"ANDROID_APP"===M?k.optOutOneSignalPermissionDialog():"IOS_APP"===M&&T.postMessage({action:"optOutOneSignalPermissionDialog"})},Je=void 0,Le=null,Ve={UNKNOWN:-1,ALL_FORMATS:0,CODE_128:1,CODE_39:2,CODE_93:4,CODABAR:8,DATA_MATRIX:16,EAN_13:32,EAN_8:64,ITF:128,QR_CODE:256,UPC_A:512,UPC_E:1024,PDF417:2048,AZTEC:4096},je={UNKNOWN:0,CONTACT_INFO:1,EMAIL:2,ISBN:3,PHONE:4,PRODUCT:5,SMS:6,TEXT:7,URL:8,WIFI:9,GEO:10,CALENDAR_EVENT:11,DRIVER_LICENSE:12},He=function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.onBarcodeSearch,t=e.format;W((function(e){var t=e.type,i=e.value;"BARCODE_SCAN"===t&&n&&n(i)})),"ANDROID_APP"===M&&k.startScanner(JSON.stringify({formats:t?[t]:[]})),"IOS_APP"===M&&T.postMessage({action:"barcodeScan",barcodeFormat:String(t||Ve.ALL_FORMATS)})}},xe=void 0,qe=null,Ke=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(["ANDROID_APP","IOS_APP"].includes(M))return"IOS_APP"===M&&T.postMessage({action:"showBannerAd",adId:e.adId||""}),"ANDROID_APP"===M&&k.showBannerAd(JSON.stringify(e)),xe},Ge=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.fullScreenAdCallback;return U((function(e){var n=e.status;qe&&qe(e),"adDismissed"===n&&(qe=null),["adDismissed","adLoadError","adError"].indexOf(n)>-1&&J()})),"IOS_APP"===M&&T.postMessage({action:"showFullScreenAd",adId:e.adId||""}),"ANDROID_APP"===M&&k.showFullScreenAd(JSON.stringify(e)),"function"==typeof n&&(qe=n),xe}},ze=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.rewardsAdCallback;return U((function(e){var n=e.status;qe&&qe(e),"adDismissed"===n&&(qe=null),["adDismissed","adLoadError","adError"].indexOf(n)>-1&&J()})),"IOS_APP"===M&&T.postMessage({action:"showRewardAd",adId:e.adId||""}),"ANDROID_APP"===M&&k.showRewardsAd(JSON.stringify(e)),"function"==typeof n&&(qe=n),xe}},Xe={facebook:{login:function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.callback,t=e.scope;W((function(e){"fbLoginToken"===e.type&&n&&n(e)})),"ANDROID_APP"===M&&k.loginWithFacebook(),"IOS_APP"===M&&T.postMessage({action:"fbSignIn",scope:t})}},logout:function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.callback,t=e.scope;W((function(e){"fbLogOut"===e.type&&n&&n(e)})),"ANDROID_APP"===M&&k.logoutWithFacebook(),"IOS_APP"===M&&T.postMessage({action:"fbSignOut",scope:t})}}},google:{login:function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.callback,t=e.scope;W((function(e){"googleLoginToken"===e.type&&n&&n(e)})),"ANDROID_APP"===M&&k.signInWithGoogle(),"IOS_APP"===M&&T.postMessage({action:"googleSignIn",scope:t})}},logout:function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.callback,t=e.scope;W((function(e){"googleLogOut"===e.type&&n&&n(e)})),"ANDROID_APP"===M&&k.signOutWithGoogle(),"IOS_APP"===M&&T.postMessage({action:"googleSignOut",scope:t})}}},apple:{login:function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.callback,t=e.scope;W((function(e){"appleLoginToken"===e.type&&n&&n(e)})),"IOS_APP"===M&&T.postMessage({action:"appleSignIn",scope:t})}}}},Qe=function(e){["ANDROID_APP","IOS_APP"].includes(M)&&("ANDROID_APP"===M&&k.setAppsFlyerUserId(e),"IOS_APP"===M&&T.postMessage({action:"setAppsFlyerUserId",userId:e}))},Ze=function(e,n){["ANDROID_APP","IOS_APP"].includes(M)&&("ANDROID_APP"===M&&k.addEventToAppsFlyer(e,JSON.stringify(n)),"IOS_APP"===M&&T.postMessage({action:"addEventToAppsFlyer",eventName:e,eventValues:n}))},Ye=function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.event,t=e.valueToSum,i=e.parameters;"ANDROID_APP"===M&&k.addFbEvents(n,i),"IOS_APP"===M&&T.postMessage({action:"sendFBEvent",eventName:n,valueToSum:t,parameters:i})}},$e=function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.amount,t=e.currency,i=e.parameters;"ANDROID_APP"===M&&k.addFbPurchaseEvent(n,t,i),"IOS_APP"===M&&T.postMessage({action:"sendFBPurchaseEvent",currency:t,amount:n,parameters:i})}},en=function(){["ANDROID_APP","IOS_APP"].includes(M)&&("ANDROID_APP"===M&&k.showHideStickyFooter(!1),"IOS_APP"===M&&T.postMessage({action:"showHideStickyFooter",show:!1}))},nn=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.key;["ANDROID_APP","IOS_APP"].includes(M)&&("ANDROID_APP"===M&&k.showHideStickyFooter(!0),"IOS_APP"===M&&T.postMessage({action:"showHideStickyFooter",show:!0,key:n}))},tn=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.callback;["ANDROID_APP","IOS_APP"].includes(M)&&(W((function(e){"contactPermissionStatus"===e.type&&n&&n(e)})),"ANDROID_APP"===M&&k.getPermissionStatus(),"IOS_APP"===M&&T.postMessage({action:"askUserForContactPermission"}))},on=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.callback;["ANDROID_APP","IOS_APP"].includes(M)&&(W((function(e){"contactDetails"===e.type&&n&&n(e)})),"ANDROID_APP"===M&&k.getAll(),"IOS_APP"===M&&T.postMessage({action:"getUserContactDetails"}))},an=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.data,t=e.callback,i=e.backgroundIndicator,o=void 0!==i&&i,a=e.pauseAutomatically,r=void 0===a||a,c=e.distanceFilter,s=void 0===c?0:c,u=e.desiredAccuracy,P=void 0===u?"best":u,A=e.activityType,l=void 0===A?"other":A,d=e.apiUrl,p=e.timeout;W((function(e){"LOCATION_UPDATE"===e.type&&t&&t(e)}),{key:"LOCATION_UPDATE",ignoreDelete:!0}),"IOS_APP"===M&&T.postMessage({action:"startLocation",data:n,backgroundIndicator:o,pauseAutomatically:r,distanceFilter:s,desiredAccuracy:P,activityType:l,apiUrl:d,timeout:p}),"ANDROID_APP"===M&&k.startTrackingLocation(JSON.stringify({action:"startLocation",data:n,interval:p,callback:t,apiUrl:d,displacement:s}))}},rn=function(){["ANDROID_APP","IOS_APP"].includes(M)&&(delete F["LOCATION_UPDATE"],"IOS_APP"===M&&T.postMessage({action:"stopLocation"}),"ANDROID_APP"===M&&k.stopTrackingLocation())},cn=function(){["ANDROID_APP","IOS_APP"].includes(M)&&("IOS_APP"===M&&T.postMessage({action:"keepScreenOn",flag:!0}),"ANDROID_APP"===M&&k.keepScreenOn())},sn=function(){["ANDROID_APP","IOS_APP"].includes(M)&&("IOS_APP"===M&&T.postMessage({action:"keepScreenOn",flag:!1}),"ANDROID_APP"===M&&k.keepScreenNormal())},un=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.callback;["ANDROID_APP","IOS_APP"].includes(M)&&(W((function(e){"CLIPBOARD_CONTENT"===e.type&&n&&n(e)})),"IOS_APP"===M&&T.postMessage({action:"getClipBoardData"}),"ANDROID_APP"===M&&k.getText())},Pn=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};["ANDROID_APP","IOS_APP"].includes(M)&&("IOS_APP"===M&&T.postMessage({action:"setClipBoardData",text:e.data||""}),"ANDROID_APP"===M&&k.setText(e.data||""))},An=function(){["ANDROID_APP","IOS_APP"].includes(M)&&("IOS_APP"===M&&T.postMessage({action:"showAppRating"}),"ANDROID_APP"===M&&k.showInAppReview())},ln=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.callback;["ANDROID_APP","IOS_APP"].includes(M)&&(W((function(e){"checkBiometricStatus"===e.type&&n&&n(e)})),"ANDROID_APP"===M&&k.checkBiometricStatus(),"IOS_APP"===M&&T.postMessage({action:"checkBiometricStatus"}))},dn=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.callback,t=e.secret;["ANDROID_APP","IOS_APP"].includes(M)&&(W((function(e){"saveBiometricSecret"===e.type&&n&&n(e)})),"ANDROID_APP"===M&&k.saveSecret(t),"IOS_APP"===M&&T.postMessage({action:"saveBiometricSecret",secret:t}))},pn=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.callback;["ANDROID_APP","IOS_APP"].includes(M)&&(W((function(e){"deleteBiometricSecret"===e.type&&n&&n(e)})),"ANDROID_APP"===M&&k.deleteSecret(),"IOS_APP"===M&&T.postMessage({action:"deleteBiometricSecret"}))},fn=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.callback,t=e.prompt;["ANDROID_APP","IOS_APP"].includes(M)&&(W((function(e){"showBiometric"===e.type&&n&&n(e)})),"ANDROID_APP"===M&&k.callBiometric(t||"Authenticate to continue!"),"IOS_APP"===M&&T.postMessage({action:"showBiometric",prompt:t||""}))},On=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.callback,t=e.prompt,i=e.isAuthenticationOptional,o=void 0!==i&&i;["ANDROID_APP"].includes(M)&&(W((function(e){"biometricAuthWithDismissOnCancel"===e.type&&n&&n(e)})),"ANDROID_APP"===M&&k.biometricAuthWithDismissOnCancel(JSON.stringify({prompt:t||"Authenticate to continue!",isAuthenticationOptional:o})))},Dn=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.callback;["IOS_APP"].includes(M)&&(W((function(e){"requestTrackingConsent"===e.type&&n&&n(e)})),"IOS_APP"===M&&T.postMessage({action:"requestTrackingAuthorization"}))},gn=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.callback;["IOS_APP"].includes(M)&&(W((function(e){"trackingConsentStatus"===e.type&&n&&n(e)})),"IOS_APP"===M&&T.postMessage({action:"trackingConsentStatus"}))},In=function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.enabled;"IOS_APP"===M&&T.postMessage({action:"setFirebaseAnalyticsCollection",enabled:n}),"ANDROID_APP"===M&&k.setFirebaseAnalyticsCollection(n)}},_n=function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.userId;"IOS_APP"===M&&T.postMessage({action:"setFirebaseUserId",userId:n}),"ANDROID_APP"===M&&k.setFirebaseUserId(n)}},Sn=function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.key,t=e.value;"IOS_APP"===M&&T.postMessage({action:"setFirebaseUserProp",key:n,value:t}),"ANDROID_APP"===M&&k.setFirebaseUserProp(n,t)}},Nn=function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.parameters;"IOS_APP"===M&&T.postMessage({action:"setFirebaseDefaultParam",parameters:n}),"ANDROID_APP"===M&&k.setFirebaseDefaultParam(n)}},vn=function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.eventName,t=e.parameters;"IOS_APP"===M&&T.postMessage({action:"logFirebaseEvent",eventName:n,parameters:t}),"ANDROID_APP"===M&&k.logFirebaseEvent(n,t)}},yn=function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.screenName,t=e.screenClass;"IOS_APP"===M&&T.postMessage({action:"logFirebaseScreenView",screenName:n,screenClass:t}),"ANDROID_APP"===M&&k.logFirebaseScreenView(n,t)}},mn=function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.toTopic;"IOS_APP"===M&&T.postMessage({action:"firebaseSubscribeToTopic",topic:n}),"ANDROID_APP"===M&&k.subscribeToTopic(n)}},hn=function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.fromTopic;"IOS_APP"===M&&T.postMessage({action:"firebaseUnsubscribeFromTopic",topic:n}),"ANDROID_APP"===M&&k.unsubscribeFromTopic(n)}},Rn=function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.callback;W((function(e){"getFCMToken"===e.type&&("ANDROID_APP"===M&&(e.token=e.fcm_registration_token),n&&n(e))})),"IOS_APP"===M&&T.postMessage({action:"getFCMToken"}),"ANDROID_APP"===M&&k.getRegistrationToken()}},wn=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};["ANDROID_APP","IOS_APP"].includes(M)&&"IOS_APP"===M&&T.postMessage({action:"haptikEffect",effect:e.effect})},bn=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.url,t=e.imageUrl,i=void 0===t?"https://images.freeimages.com/images/large-previews/3b2/prague-conference-center-1056491.jpg":t;["ANDROID_APP","IOS_APP"].includes(M)&&("ANDROID_APP"===M&&k.playMedia(JSON.stringify({url:n,imageUrl:i})),"IOS_APP"===M&&T.postMessage({action:"playMedia",url:n,image:i}))},kn=function(){["ANDROID_APP","IOS_APP"].includes(M)&&("ANDROID_APP"===M&&k.pausePlaying(),"IOS_APP"===M&&T.postMessage({action:"pauseMedia"}))},Tn=function(){["ANDROID_APP","IOS_APP"].includes(M)&&("ANDROID_APP"===M&&k.stopPlaying(),"IOS_APP"===M&&T.postMessage({action:"stopMedia"}))},Mn=function(e){if(["ANDROID_APP"].includes(M)){var n=e.printSize,t=void 0===n?"ISO_A4":n,i=e.label,o=void 0===i?"":i;"ANDROID_APP"===M&&k.setPrintSize(JSON.stringify({printSize:t,label:o}))}},Cn=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.callback;["ANDROID_APP","IOS_APP"].includes(M)&&(W((function(e){"checkNotificationPermission"===e.type&&n&&n(e)})),"ANDROID_APP"===M&&k.checkNotificationPermission(),"IOS_APP"===M&&T.postMessage({action:"checkNotificationPermission"}))},Fn=function(){["ANDROID_APP","IOS_APP"].includes(M)&&("ANDROID_APP"===M&&k.openAppNotificationPage(),"IOS_APP"===M&&T.postMessage({action:"openAppNotificationPage"}))},En=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.callback;["ANDROID_APP"].includes(M)&&(W((function(e){"startBluetoothScan"===e.type&&n&&n(e)})),"ANDROID_APP"===M&&k.startBluetoothScan())},Bn=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.callback,t=e.address,i=e.timeout,o=void 0===i?10:i;["ANDROID_APP"].includes(M)&&(W((function(e){"pairWithDevice"===e.type&&n&&n(e)})),"ANDROID_APP"===M&&k.pairWithDevice(JSON.stringify({address:t,timeout:o})))},Wn=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.callback,t=e.address;["ANDROID_APP"].includes(M)&&(W((function(e){"unpairDevice"===e.type&&n&&n(e)})),"ANDROID_APP"===M&&k.unpairDevice(JSON.stringify({address:t})))};function Un(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);n&&(i=i.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,i)}return t}function Jn(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}var Ln=function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.callback,t=e.apiUrl,i=void 0===t?null:t,o=e.amount,a=e.currency,r=e.isSimulated,c=void 0!==r&&r,s=e.captureMethod,u=void 0===s?"automatic":s,P=e.connectionToken,A=e.stripeLocationId,l=e.clientSecret,d=void 0===l?null:l;W((function(e){"makeTapToPayStripePayment"===e.type&&n&&n(e)}));var p={secretToken:P,amount:o,currency:a,isSimulated:c,captureMethod:u,locationId:A};i&&(p.apiUrl=i),d&&(p.client_secret=d),"ANDROID_APP"===M&&k.makeTapToPayStripePayment(JSON.stringify(p)),"IOS_APP"===M&&T.postMessage(function(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?Un(Object(t),!0).forEach((function(n){Jn(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):Un(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}({action:"makeTapToPayStripePayment"},p))}},Vn=function(e){if(["ANDROID_APP"].includes(M)){var n=e.callback;W((function(e){"checkIfAppUpdateAvailable"===e.type&&n&&n(e)})),"ANDROID_APP"===M&&k.checkIfAppUpdateAvailable()}},jn=function(e){if(["ANDROID_APP"].includes(M)){var n=e.updateType,t=void 0===n?"immediate":n,i=e.callback;W((function(e){"updateApplication"===e.type&&i&&i(e)})),"ANDROID_APP"===M&&k.updateApplication(t)}},Hn=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.actionUrl,t=e.suggestedPhrase,i=e.title;["IOS_APP"].includes(M)&&"IOS_APP"===M&&T.postMessage({action:"addToSiri",data:{actionUrl:n,suggestedPhrase:t,title:i}})},xn=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.callback,t=e.beaconData;["ANDROID_APP","IOS_APP"].includes(M)&&(W((function(e){"initBeaconData"===e.type&&n&&n(e)})),"ANDROID_APP"===M&&k.initBeaconData(JSON.stringify(t)),"IOS_APP"===M&&T.postMessage({action:"initBeaconData",data:t}))},qn=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.callback,t=e.keyName,i=e.value;["ANDROID_APP","IOS_APP"].includes(M)&&(W((function(e){"setAppData"===e.type&&n&&n(e)})),"ANDROID_APP"===M&&k.setAppData(JSON.stringify({keyName:t,value:i})),"IOS_APP"===M&&T.postMessage({action:"setAppData",keyName:t,value:i}))},Kn=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.callback,t=e.keyName;["ANDROID_APP","IOS_APP"].includes(M)&&(W((function(e){"getAppData"===e.type&&n&&n(e)})),"ANDROID_APP"===M&&k.getAppData(t),"IOS_APP"===M&&T.postMessage({action:"getAppData",keyName:t}))},Gn=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.callback,t=e.keyName;["ANDROID_APP","IOS_APP"].includes(M)&&(W((function(e){"deleteAppData"===e.type&&n&&n(e)})),"ANDROID_APP"===M&&k.deleteAppData(t),"IOS_APP"===M&&T.postMessage({action:"deleteAppData",keyName:t}))},zn=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.callback,t=e.keyName,i=e.value;["ANDROID_APP","IOS_APP"].includes(M)&&(W((function(e){"setCloudData"===e.type&&n&&n(e)})),"ANDROID_APP"===M&&k.setCloudData(JSON.stringify({keyName:t,value:i})),"IOS_APP"===M&&T.postMessage({action:"setCloudData",keyName:t,value:i}))},Xn=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.callback,t=e.keyName;["ANDROID_APP","IOS_APP"].includes(M)&&(W((function(e){"getCloudData"===e.type&&n&&n(e)})),"ANDROID_APP"===M&&k.getCloudData(t),"IOS_APP"===M&&T.postMessage({action:"getCloudData",keyName:t}))},Qn=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.callback,t=e.keyName;["ANDROID_APP","IOS_APP"].includes(M)&&(W((function(e){"deleteCloudData"===e.type&&n&&n(e)})),"ANDROID_APP"===M&&k.deleteCloudData(t),"IOS_APP"===M&&T.postMessage({action:"deleteCloudData",keyName:t}))};window.WTN=n,window.WTN.OneSignal=t,window.WTN.VoiceSearch=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.onVoiceSearch;return W((function(e){var n=e.type,t=e.results;"VOICE_SEARCH_RESULT"===n&&(Le&&Le(t),Le=null)})),C&&k.openVoiceSearch(),"function"==typeof n&&(Le=n),Je},window.WTN.Barcode=i,window.WTN.AdMob=o,window.WTN.socialLogin=Xe,window.WTN.inAppPurchase=function(e){if(["ANDROID_APP","IOS_APP"].includes(M)){var n=e.callback,t=e.productId,i=e.productType,o=e.isConsumable,a=void 0!==o&&o;W((function(e){"inAppPurchase"===e.type&&n&&n(e)})),"IOS_APP"===M&&T.postMessage({action:"inAppPurchase",productId:t}),"ANDROID_APP"===M&&k.inAppPurchase(JSON.stringify({action:"inAppPurchase",productId:t,productType:i,isConsumable:a}))}},window.WTN.getAllPurchases=function(e){if(["ANDROID_APP"].includes(M)){var n=e.callback;W((function(e){"purchaseList"===e.type&&n&&n(e)})),"ANDROID_APP"===M&&k.getAllPurchases({action:"purchaseList"})}},window.WTN.getReceiptData=function(e){if(["IOS_APP"].includes(M)){var n=e.callback;W((function(e){"getReceiptData"===e.type&&n&&n(e)})),"IOS_APP"===M&&T.postMessage({action:"getReceiptData"})}},window.WTN.appsflyer=a,window.WTN.bottomNavigation=c,window.WTN.contacts=s,window.WTN.screen=P,window.WTN.backgroundLocation=u,window.WTN.clipboard=A,window.WTN.appReview=l,window.WTN.Biometric=d,window.WTN.ATTConsent=p,window.WTN.facebook={events:r},window.WTN.firebaseAnalytics=O,window.WTN.haptics=I,window.WTN.Firebase=g,window.WTN.MediaPlayer=_,window.WTN.Printing=S,window.WTN.Notification=N,window.WTN.Bluetooth=v,window.WTN.Stripe=y,window.WTN.InAppUpdate=m,window.WTN.Siri=h,window.WTN.Beacon=R,window.WTN.NativeDatastore=w,window&&window.WebToNativeInterface&&window.WebToNativeInterface.getAndroidVersion?window.navigator.share=function(e){return new Promise((function(n,t){window.WebToNativeInterface.openShareIntent(e.url),n()}))}:WTN.isIosApp&&(window.navigator.share=function(e){return new Promise((function(n,t){T.postMessage({action:"share",url:e.url}),n()}))})}();
|
|
1
|
+
!function(){"use strict";var e={433:function(e,o,t){var i=this&&this.__createBinding||(Object.create?function(e,o,t,i){void 0===i&&(i=t);var a=Object.getOwnPropertyDescriptor(o,t);a&&!("get"in a?!o.__esModule:a.writable||a.configurable)||(a={enumerable:!0,get:function(){return o[t]}}),Object.defineProperty(e,i,a)}:function(e,o,t,i){void 0===i&&(i=t),e[i]=o[t]}),a=this&&this.__setModuleDefault||(Object.create?function(e,o){Object.defineProperty(e,"default",{enumerable:!0,value:o})}:function(e,o){e.default=o}),n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var o={};if(null!=e)for(var t in e)"default"!==t&&Object.prototype.hasOwnProperty.call(e,t)&&i(o,e,t);return a(o,e),o},r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(o,"__esModule",{value:!0});var s=n(t(56)),l=n(t(198)),p=r(t(781)),c=n(t(706)),d=n(t(545)),f=t(699),P=n(t(45)),u=t(854),v=n(t(959)),A=n(t(226)),N=n(t(380)),b=n(t(549)),I=n(t(30)),w=n(t(200)),m=n(t(283)),g=n(t(358)),O=n(t(750)),T=n(t(539)),_=n(t(97)),D=n(t(153)),S=n(t(448)),y=n(t(550)),h=n(t(148)),R=n(t(75)),C=n(t(157)),M=n(t(876)),k=n(t(668)),F=n(t(633)),E=n(t(261)),B=t(612);window.WTN=s,window.WTN.OneSignal=l,window.WTN.VoiceSearch=p.default,window.WTN.Barcode=c,window.WTN.AdMob=d,window.WTN.socialLogin=f.socialLogin,window.WTN.inAppPurchase=u.inAppPurchase,window.WTN.getAllPurchases=u.getAllPurchases,window.WTN.getReceiptData=u.getReceiptData,window.WTN.appsflyer=P,window.WTN.bottomNavigation=A,window.WTN.contacts=N,window.WTN.screen=I,window.WTN.backgroundLocation=b,window.WTN.clipboard=w,window.WTN.appReview=m,window.WTN.Biometric=g,window.WTN.ATTConsent=O,window.WTN.facebook={events:v},window.WTN.firebaseAnalytics=T,window.WTN.Firebase=_,window.WTN.haptics=D,window.WTN.MediaPlayer=S,window.WTN.Printing=y,window.WTN.Notification=h,window.WTN.Bluetooth=R,window.WTN.Stripe=C,window.WTN.InAppUpdate=M,window.WTN.Siri=k,window.WTN.Beacon=F,window.WTN.NativeDatastore=E,window&&window.WebToNativeInterface&&window.WebToNativeInterface.getAndroidVersion?window.navigator.share=function(e){return new Promise((function(o,t){window.WebToNativeInterface.openShareIntent(e.url),o()}))}:window.WTN.isIosApp&&(window.navigator.share=function(e){return new Promise((function(o,t){B.webToNativeIos&&(null===B.webToNativeIos||void 0===B.webToNativeIos||B.webToNativeIos.postMessage({action:"share",url:e.url})),o()}))}),o.default=window.WTN},750:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.status=o.request=void 0;var i=t(612);o.request=function(e){void 0===e&&(e={});var o=e.callback;["IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"requestTrackingConsent"===e.type&&o&&o(e)})),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"requestTrackingAuthorization"}))},o.status=function(e){void 0===e&&(e={});var o=e.callback;["IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"trackingConsentStatus"===e.type&&o&&o(e)})),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"trackingConsentStatus"}))}},545:function(e,o,t){var i=this;Object.defineProperty(o,"__esModule",{value:!0}),o.rewardsAd=o.fullScreenAd=o.bannerAd=void 0;var a=t(612),n=null;o.bannerAd=function(e){if(void 0===e&&(e={}),["ANDROID_APP","IOS_APP"].includes(a.platform))return"IOS_APP"===a.platform&&a.webToNativeIos&&a.webToNativeIos.postMessage({action:"showBannerAd",adId:e.adId||""}),"ANDROID_APP"===a.platform&&a.webToNative.showBannerAd(JSON.stringify(e)),i},o.fullScreenAd=function(e){if(void 0===e&&(e={}),["ANDROID_APP","IOS_APP"].includes(a.platform)){var o=e.fullScreenAdCallback;return(0,a.registerForAbMobCb)((function(e){var o=e.status;n&&n(e),"adDismissed"===o&&(n=null),["adDismissed","adLoadError","adError"].indexOf(o)>-1&&(0,a.deRegisterForAbMobCb)()})),"IOS_APP"===a.platform&&a.webToNativeIos&&a.webToNativeIos.postMessage({action:"showFullScreenAd",adId:e.adId||""}),"ANDROID_APP"===a.platform&&a.webToNative.showFullScreenAd(JSON.stringify(e)),"function"==typeof o&&(n=o),i}},o.rewardsAd=function(e){if(void 0===e&&(e={}),["ANDROID_APP","IOS_APP"].includes(a.platform)){var o=e.rewardsAdCallback;return(0,a.registerForAbMobCb)((function(e){var o=e.status;n&&n(e),"adDismissed"===o&&(n=null),["adDismissed","adLoadError","adError"].indexOf(o)>-1&&(0,a.deRegisterForAbMobCb)()})),"IOS_APP"===a.platform&&a.webToNativeIos&&a.webToNativeIos.postMessage({action:"showRewardAd",adId:e.adId||""}),"ANDROID_APP"===a.platform&&a.webToNative.showRewardsAd(JSON.stringify(e)),"function"==typeof o&&(n=o),i}}},283:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.prompt=void 0;var i=t(612);o.prompt=function(e){void 0===e&&(e={}),["ANDROID_APP","IOS_APP"].includes(i.platform)&&("IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"showAppRating"}),"ANDROID_APP"===i.platform&&i.webToNative.showInAppReview())}},45:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.logEvent=o.setCustomerUserId=void 0;var i=t(612);o.setCustomerUserId=function(e){["ANDROID_APP","IOS_APP"].includes(i.platform)&&("ANDROID_APP"===i.platform&&i.webToNative.setAppsFlyerUserId(e),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"setAppsFlyerUserId",userId:e}))},o.logEvent=function(e,o){["ANDROID_APP","IOS_APP"].includes(i.platform)&&("ANDROID_APP"===i.platform&&i.webToNative.addEventToAppsFlyer(e,JSON.stringify(o)),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"addEventToAppsFlyer",eventName:e,eventValues:o}))}},549:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.stop=o.start=void 0;var i=t(612);o.start=function(e){if(void 0===e&&(e={}),["ANDROID_APP","IOS_APP"].includes(i.platform)){var o=e.data,t=e.callback,a=e.backgroundIndicator,n=void 0!==a&&a,r=e.pauseAutomatically,s=void 0===r||r,l=e.distanceFilter,p=void 0===l?0:l,c=e.desiredAccuracy,d=void 0===c?"best":c,f=e.activityType,P=void 0===f?"other":f,u=e.apiUrl,v=e.timeout;(0,i.registerCb)((function(e){"LOCATION_UPDATE"===e.type&&t&&t(e)}),{key:"LOCATION_UPDATE",ignoreDelete:!0}),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"startLocation",data:o,backgroundIndicator:n,pauseAutomatically:s,distanceFilter:p,desiredAccuracy:d,activityType:P,apiUrl:u,timeout:v}),"ANDROID_APP"===i.platform&&i.webToNative.startTrackingLocation(JSON.stringify({action:"startLocation",data:o,interval:v,callback:t,apiUrl:u,displacement:p}))}},o.stop=function(e){void 0===e&&(e={}),["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.deRegisterCbByKey)("LOCATION_UPDATE"),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"stopLocation"}),"ANDROID_APP"===i.platform&&i.webToNative.stopTrackingLocation())}},633:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.initBeaconData=void 0;var i=t(612);o.initBeaconData=function(e){void 0===e&&(e={});var o=e.callback,t=e.beaconData;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"initBeaconData"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform&&i.webToNative.initBeaconData(JSON.stringify(t)),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"initBeaconData",data:t}))}},358:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.biometricAuthWithDismissOnCancel=o.show=o.deleteSecret=o.saveSecret=o.checkStatus=void 0;var i=t(612);o.checkStatus=function(e){void 0===e&&(e={});var o=e.callback;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"checkBiometricStatus"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform&&i.webToNative.checkBiometricStatus(),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"checkBiometricStatus"}))},o.saveSecret=function(e){void 0===e&&(e={});var o=e.callback,t=e.secret;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"saveBiometricSecret"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform&&i.webToNative.saveSecret(t),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"saveBiometricSecret",secret:t}))},o.deleteSecret=function(e){void 0===e&&(e={});var o=e.callback;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"deleteBiometricSecret"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform&&i.webToNative.deleteSecret(),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"deleteBiometricSecret"}))},o.show=function(e){void 0===e&&(e={});var o=e.callback,t=e.prompt;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"showBiometric"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform&&i.webToNative.callBiometric(t||"Authenticate to continue!"),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"showBiometric",prompt:t||""}))},o.biometricAuthWithDismissOnCancel=function(e){void 0===e&&(e={});var o=e.callback,t=e.prompt,a=e.isAuthenticationOptional,n=void 0!==a&&a;["ANDROID_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"biometricAuthWithDismissOnCancel"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform&&i.webToNative.biometricAuthWithDismissOnCancel(JSON.stringify({prompt:t||"Authenticate to continue!",isAuthenticationOptional:n})))}},75:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.unpairDevice=o.pairDevice=o.startBluetoothScan=void 0;var i=t(612);o.startBluetoothScan=function(e){void 0===e&&(e={});var o=e.callback;["ANDROID_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"startBluetoothScan"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform&&i.webToNative.startBluetoothScan())},o.pairDevice=function(e){void 0===e&&(e={});var o=e.callback,t=e.address,a=e.timeout,n=void 0===a?10:a;["ANDROID_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"pairWithDevice"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform&&i.webToNative.pairWithDevice(JSON.stringify({address:t,timeout:n})))},o.unpairDevice=function(e){void 0===e&&(e={});var o=e.callback,t=e.address;["ANDROID_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"unpairDevice"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform&&i.webToNative.unpairDevice(JSON.stringify({address:t})))}},226:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.show=o.hide=void 0;var i=t(612);o.hide=function(){["ANDROID_APP","IOS_APP"].includes(i.platform)&&("ANDROID_APP"===i.platform&&i.webToNative.showHideStickyFooter(!1),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"showHideStickyFooter",show:!1}))},o.show=function(e){void 0===e&&(e={});var o=e.key;["ANDROID_APP","IOS_APP"].includes(i.platform)&&("ANDROID_APP"===i.platform&&i.webToNative.showHideStickyFooter(!0),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"showHideStickyFooter",show:!0,key:o}))}},200:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.set=o.get=void 0;var i=t(612);o.get=function(e){void 0===e&&(e={});var o=e.callback;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"CLIPBOARD_CONTENT"===e.type&&o&&o(e)})),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"getClipBoardData"}),"ANDROID_APP"===i.platform&&i.webToNative.getText())},o.set=function(e){void 0===e&&(e={}),["ANDROID_APP","IOS_APP"].includes(i.platform)&&("IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"setClipBoardData",text:e.data||""}),"ANDROID_APP"===i.platform&&i.webToNative.setText(e.data||""))}},959:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.sendPurchase=o.send=void 0;var i=t(612);o.send=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var o=e.event,t=e.valueToSum,a=e.parameters;"ANDROID_APP"===i.platform&&i.webToNative.addFbEvents(o,a),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"sendFBEvent",eventName:o,valueToSum:t,parameters:a})}},o.sendPurchase=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var o=e.amount,t=e.currency,a=e.parameters;"ANDROID_APP"===i.platform&&i.webToNative.addFbPurchaseEvent(o,t,a),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"sendFBPurchaseEvent",currency:t,amount:o,parameters:a})}}},800:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.logScreen=o.logEvent=o.setDefaultEventParameters=o.setUserProperty=o.setUserId=o.setCollection=void 0;var i=t(612);o.setCollection=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var o=e.enabled;"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"setFirebaseAnalyticsCollection",enabled:o}),"ANDROID_APP"===i.platform&&i.webToNative.setFirebaseAnalyticsCollection(o)}},o.setUserId=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var o=e.userId;"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"setFirebaseUserId",userId:o}),"ANDROID_APP"===i.platform&&i.webToNative.setFirebaseUserId(o)}},o.setUserProperty=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var o=e.key,t=e.value;"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"setFirebaseUserProp",key:o,value:t}),"ANDROID_APP"===i.platform&&i.webToNative.setFirebaseUserProp(o,t)}},o.setDefaultEventParameters=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var o=e.parameters;"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"setFirebaseDefaultParam",parameters:o}),"ANDROID_APP"===i.platform&&i.webToNative.setFirebaseDefaultParam(o)}},o.logEvent=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var o=e.eventName,t=e.parameters;"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"logFirebaseEvent",eventName:o,parameters:t}),"ANDROID_APP"===i.platform&&i.webToNative.logFirebaseEvent(o,t)}},o.logScreen=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var o=e.screenName,t=e.screenClass;"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"logFirebaseScreenView",screenName:o,screenClass:t}),"ANDROID_APP"===i.platform&&i.webToNative.logFirebaseScreenView(o,t)}}},918:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.getFCMToken=o.unsubscribe=o.subscribe=void 0;var i=t(612);o.subscribe=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var o=e.toTopic;"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"firebaseSubscribeToTopic",topic:o}),"ANDROID_APP"===i.platform&&i.webToNative.subscribeToTopic(o)}},o.unsubscribe=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var o=e.fromTopic;"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"firebaseUnsubscribeFromTopic",topic:o}),"ANDROID_APP"===i.platform&&i.webToNative.unsubscribeFromTopic(o)}},o.getFCMToken=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var o=e.callback;(0,i.registerCb)((function(e){"getFCMToken"===e.type&&("ANDROID_APP"===i.platform&&(e.token=e.fcm_registration_token),o&&o(e))})),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"getFCMToken"}),"ANDROID_APP"===i.platform&&i.webToNative.getRegistrationToken()}}},97:function(e,o,t){var i=this&&this.__createBinding||(Object.create?function(e,o,t,i){void 0===i&&(i=t);var a=Object.getOwnPropertyDescriptor(o,t);a&&!("get"in a?!o.__esModule:a.writable||a.configurable)||(a={enumerable:!0,get:function(){return o[t]}}),Object.defineProperty(e,i,a)}:function(e,o,t,i){void 0===i&&(i=t),e[i]=o[t]}),a=this&&this.__setModuleDefault||(Object.create?function(e,o){Object.defineProperty(e,"default",{enumerable:!0,value:o})}:function(e,o){e.default=o}),n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var o={};if(null!=e)for(var t in e)"default"!==t&&Object.prototype.hasOwnProperty.call(e,t)&&i(o,e,t);return a(o,e),o};Object.defineProperty(o,"__esModule",{value:!0}),o.Messaging=o.Analytics=void 0;var r=n(t(800));o.Analytics=r;var s=n(t(918));o.Messaging=s},539:function(e,o,t){var i=this&&this.__createBinding||(Object.create?function(e,o,t,i){void 0===i&&(i=t);var a=Object.getOwnPropertyDescriptor(o,t);a&&!("get"in a?!o.__esModule:a.writable||a.configurable)||(a={enumerable:!0,get:function(){return o[t]}}),Object.defineProperty(e,i,a)}:function(e,o,t,i){void 0===i&&(i=t),e[i]=o[t]}),a=this&&this.__setModuleDefault||(Object.create?function(e,o){Object.defineProperty(e,"default",{enumerable:!0,value:o})}:function(e,o){e.default=o}),n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var o={};if(null!=e)for(var t in e)"default"!==t&&Object.prototype.hasOwnProperty.call(e,t)&&i(o,e,t);return a(o,e),o};Object.defineProperty(o,"__esModule",{value:!0}),o.events=void 0;var r=n(t(800));o.events=r},153:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.trigger=void 0;var i=t(612);o.trigger=function(e){void 0===e&&(e={}),["ANDROID_APP","IOS_APP"].includes(i.platform)&&"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"haptikEffect",effect:e.effect})}},854:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.getReceiptData=o.getAllPurchases=o.inAppPurchase=void 0;var i=t(612);o.inAppPurchase=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var o=e.callback,t=e.productId,a=e.productType,n=e.isConsumable,r=void 0!==n&&n;(0,i.registerCb)((function(e){"inAppPurchase"===e.type&&o&&o(e)})),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"inAppPurchase",productId:t}),"ANDROID_APP"===i.platform&&i.webToNative.inAppPurchase(JSON.stringify({action:"inAppPurchase",productId:t,productType:a,isConsumable:r}))}},o.getAllPurchases=function(e){if(["ANDROID_APP"].includes(i.platform)){var o=e.callback;(0,i.registerCb)((function(e){"purchaseList"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform&&i.webToNative.getAllPurchases({action:"purchaseList"})}},o.getReceiptData=function(e){if(["IOS_APP"].includes(i.platform)){var o=e.callback;(0,i.registerCb)((function(e){"getReceiptData"===e.type&&o&&o(e)})),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"getReceiptData"})}}},876:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.updateApplication=o.checkIfAppUpdateAvailable=void 0;var i=t(612);o.checkIfAppUpdateAvailable=function(e){if(["ANDROID_APP"].includes(i.platform)){var o=e.callback;(0,i.registerCb)((function(e){"checkIfAppUpdateAvailable"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform&&i.webToNative.checkIfAppUpdateAvailable()}},o.updateApplication=function(e){if(["ANDROID_APP"].includes(i.platform)){var o=e.updateType,t=void 0===o?"immediate":o,a=e.callback;(0,i.registerCb)((function(e){"updateApplication"===e.type&&a&&a(e)})),"ANDROID_APP"===i.platform&&i.webToNative.updateApplication(t)}}},448:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.stopMedia=o.pauseMedia=o.playMedia=void 0;var i=t(612);o.playMedia=function(e){void 0===e&&(e={});var o=e.url,t=e.imageUrl,a=void 0===t?"https://images.freeimages.com/images/large-previews/3b2/prague-conference-center-1056491.jpg":t;["ANDROID_APP","IOS_APP"].includes(i.platform)&&("ANDROID_APP"===i.platform&&i.webToNative.playMedia(JSON.stringify({url:o,imageUrl:a})),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"playMedia",url:o,image:a}))},o.pauseMedia=function(e){void 0===e&&(e={}),["ANDROID_APP","IOS_APP"].includes(i.platform)&&("ANDROID_APP"===i.platform&&i.webToNative.pausePlaying(),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"pauseMedia"}))},o.stopMedia=function(e){void 0===e&&(e={}),["ANDROID_APP","IOS_APP"].includes(i.platform)&&("ANDROID_APP"===i.platform&&i.webToNative.stopPlaying(),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"stopMedia"}))}},380:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.getAll=o.getPermissionStatus=void 0;var i=t(612);o.getPermissionStatus=function(e){void 0===e&&(e={});var o=e.callback;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"contactPermissionStatus"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform&&i.webToNative.getPermissionStatus(),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"askUserForContactPermission"}))},o.getAll=function(e){void 0===e&&(e={});var o=e.callback;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"contactDetails"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform&&i.webToNative.getAll(),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"getUserContactDetails"}))}},261:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.deleteCloudData=o.getCloudData=o.setCloudData=o.deleteAppData=o.getAppData=o.setAppData=void 0;var i=t(612);o.setAppData=function(e){void 0===e&&(e={});var o=e.callback,t=e.keyName,a=e.value;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"setAppData"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform&&i.webToNative.setAppData(JSON.stringify({keyName:t,value:a})),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"setAppData",keyName:t,value:a}))},o.getAppData=function(e){void 0===e&&(e={});var o=e.callback,t=e.keyName;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"getAppData"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform&&i.webToNative.getAppData(t),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"getAppData",keyName:t}))},o.deleteAppData=function(e){void 0===e&&(e={});var o=e.callback,t=e.keyName;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"deleteAppData"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform&&i.webToNative.deleteAppData(t),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"deleteAppData",keyName:t}))},o.setCloudData=function(e){void 0===e&&(e={});var o=e.callback,t=e.keyName,a=e.value;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"setCloudData"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform&&i.webToNative.setCloudData(JSON.stringify({keyName:t,value:a})),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"setCloudData",keyName:t,value:a}))},o.getCloudData=function(e){void 0===e&&(e={});var o=e.callback,t=e.keyName;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"getCloudData"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform&&i.webToNative.getCloudData(t),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"getCloudData",keyName:t}))},o.deleteCloudData=function(e){void 0===e&&(e={});var o=e.callback,t=e.keyName;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"deleteCloudData"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform&&i.webToNative.deleteCloudData(t),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"deleteCloudData",keyName:t}))}},148:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.openAppNotificationPage=o.checkNotificationPermission=void 0;var i=t(612);o.checkNotificationPermission=function(e){void 0===e&&(e={});var o=e.callback;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"checkNotificationPermission"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform&&i.webToNative.checkNotificationPermission(),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"checkNotificationPermission"}))},o.openAppNotificationPage=function(){["ANDROID_APP","IOS_APP"].includes(i.platform)&&("ANDROID_APP"===i.platform&&i.webToNative.openAppNotificationPage(),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"openAppNotificationPage"}))}},198:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.optOutUser=o.optInUser=o.logoutSMSNumber=o.logoutEmail=o.setSMSNumber=o.setEmail=o.getTriggers=o.getTriggerValue=o.removeTriggers=o.removeTrigger=o.addTriggers=o.addTrigger=o.setTags=o.removeExternalUserId=o.setExternalUserId=o.getPlayerId=void 0;var i=t(612);o.getPlayerId=function(){return new Promise((function(e,o){(0,i.registerCb)((function(t){t.isSuccess?e(t.playerId):o(t)}),{key:"getPlayerId"}),"ANDROID_APP"===i.platform?i.webToNative.getOneSignalId():"IOS_APP"===i.platform&&i.webToNativeIos?i.webToNativeIos.postMessage({action:"getPlayerId"}):o("This function will work in Native App Powered By WebToNative")}))},o.setExternalUserId=function(e){if(!e)throw"userId is required";if("ANDROID_APP"===i.platform)return i.isNativeApp&&i.webToNative.setExternalUserId(e);"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"setExternalUserId",userId:e})},o.removeExternalUserId=function(){if("ANDROID_APP"===i.platform)return i.isNativeApp&&i.webToNative.removeExternalUserId();"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"removeExternalUserId"})},o.setTags=function(e){var o=e.tags;if(o){if("ANDROID_APP"===i.platform)return i.isNativeApp&&i.webToNative.setUserTags(JSON.stringify(o));"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"setUserTags",tags:o})}},o.addTrigger=function(e){void 0===e&&(e={});var o=e.key,t=e.value;"ANDROID_APP"===i.platform?i.webToNative.addTrigger(JSON.stringify({key:o,value:t})):"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"addTrigger",key:o,value:t})},o.addTriggers=function(e){void 0===e&&(e={});var o=e.triggers;"ANDROID_APP"===i.platform?i.webToNative.addTriggers(JSON.stringify({triggers:o})):"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"addTriggers",triggers:o})},o.removeTrigger=function(e){void 0===e&&(e={});var o=e.key;"ANDROID_APP"===i.platform?i.webToNative.removeTriggerForKey(o):"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"removeTrigger",key:o})},o.removeTriggers=function(e){void 0===e&&(e={});var o=e.keys;"ANDROID_APP"===i.platform?i.webToNative.removeTriggersForKeys(JSON.stringify({keys:o})):"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"removeTriggers",keys:o})},o.getTriggerValue=function(e){void 0===e&&(e={});var o=e.key,t=e.callback;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"getTriggerValue"===e.type&&t&&t(e)})),"ANDROID_APP"===i.platform?i.webToNative.getTriggerValueForKey(o):"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"getTriggerValue",key:o}))},o.getTriggers=function(e){void 0===e&&(e={});var o=e.callback;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"getTriggers"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform?i.webToNative.getTriggers():"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"getTriggers"}))},o.setEmail=function(e){void 0===e&&(e={});var o=e.emailId;["ANDROID_APP","IOS_APP"].includes(i.platform)&&("ANDROID_APP"===i.platform?i.webToNative.setEmail(o):"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"setEmail",emailId:o}))},o.setSMSNumber=function(e){void 0===e&&(e={});var o=e.smsNumber;["ANDROID_APP","IOS_APP"].includes(i.platform)&&("ANDROID_APP"===i.platform?i.webToNative.setSMSNumber(o):"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"setSMSNumber",smsNumber:o}))},o.logoutEmail=function(e){void 0===e&&(e={});var o=e.emailId;["ANDROID_APP","IOS_APP"].includes(i.platform)&&("ANDROID_APP"===i.platform?i.webToNative.logoutEmail(o):"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"logoutEmail",emailId:o}))},o.logoutSMSNumber=function(e){void 0===e&&(e={});var o=e.smsNumber;["ANDROID_APP","IOS_APP"].includes(i.platform)&&("ANDROID_APP"===i.platform?i.webToNative.logoutSMSNumber(o):"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"logoutSMSNumber",smsNumber:o}))},o.optInUser=function(){"ANDROID_APP"===i.platform?i.webToNative.optInOneSignalPermissionDialog():"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"optInOneSignalPermissionDialog"})},o.optOutUser=function(){"ANDROID_APP"===i.platform?i.webToNative.optOutOneSignalPermissionDialog():"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"optOutOneSignalPermissionDialog"})}},550:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.setPrintSize=void 0;var i=t(612);o.setPrintSize=function(e){if(["ANDROID_APP"].includes(i.platform)){var o=e.printSize,t=void 0===o?"ISO_A4":o,a=e.label,n=void 0===a?"":a;"ANDROID_APP"===i.platform&&i.webToNative.setPrintSize(JSON.stringify({printSize:t,label:n}))}}},30:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.keepScreenNormal=o.keepScreenOn=void 0;var i=t(612);o.keepScreenOn=function(){["ANDROID_APP","IOS_APP"].includes(i.platform)&&("IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"keepScreenOn",flag:!0}),"ANDROID_APP"===i.platform&&i.webToNative.keepScreenOn())},o.keepScreenNormal=function(){["ANDROID_APP","IOS_APP"].includes(i.platform)&&("IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"keepScreenOn",flag:!1}),"ANDROID_APP"===i.platform&&i.webToNative.keepScreenNormal())}},668:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.addToSiri=void 0;var i=t(612);o.addToSiri=function(e){void 0===e&&(e={});var o=e.actionUrl,t=e.suggestedPhrase,a=e.title;["IOS_APP"].includes(i.platform)&&"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"addToSiri",data:{actionUrl:o,suggestedPhrase:t,title:a}})}},759:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.login=void 0;var i=t(612);o.login=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var o=e.callback,t=e.scope;(0,i.registerCb)((function(e){"appleLoginToken"===e.type&&o&&o(e)})),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"appleSignIn",scope:t})}}},211:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.logout=o.login=void 0;var i=t(612);o.login=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var o=e.callback,t=e.scope;(0,i.registerCb)((function(e){"fbLoginToken"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform&&i.webToNative.loginWithFacebook(),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"fbSignIn",scope:t})}},o.logout=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var o=e.callback,t=e.scope;(0,i.registerCb)((function(e){"fbLogOut"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform&&i.webToNative.logoutWithFacebook(),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"fbSignOut",scope:t})}}},254:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.logout=o.login=void 0;var i=t(612);o.login=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var o=e.callback,t=e.scope;(0,i.registerCb)((function(e){"googleLoginToken"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform&&i.webToNative.signInWithGoogle(),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"googleSignIn",scope:t})}},o.logout=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var o=e.callback,t=e.scope;(0,i.registerCb)((function(e){"googleLogOut"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform&&i.webToNative.signOutWithGoogle(),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"googleSignOut",scope:t})}}},699:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.socialLogin=void 0;var i=t(211),a=t(759),n=t(254);o.socialLogin={facebook:{login:i.login,logout:i.logout},google:{login:n.login,logout:n.logout},apple:{login:a.login}}},157:function(e,o,t){var i=this&&this.__assign||function(){return i=Object.assign||function(e){for(var o,t=1,i=arguments.length;t<i;t++)for(var a in o=arguments[t])Object.prototype.hasOwnProperty.call(o,a)&&(e[a]=o[a]);return e},i.apply(this,arguments)};Object.defineProperty(o,"__esModule",{value:!0}),o.makeTapToPay=void 0;var a=t(612);o.makeTapToPay=function(e){if(["ANDROID_APP","IOS_APP"].includes(a.platform)){var o=e.callback,t=e.apiUrl,n=void 0===t?null:t,r=e.amount,s=e.currency,l=e.isSimulated,p=void 0!==l&&l,c=e.captureMethod,d=void 0===c?"automatic":c,f=e.connectionToken,P=e.stripeLocationId,u=e.clientSecret,v=void 0===u?null:u;(0,a.registerCb)((function(e){"makeTapToPayStripePayment"===e.type&&o&&o(e)}));var A={secretToken:f,amount:r,currency:s,isSimulated:p,captureMethod:d,locationId:P};if(n&&(A.apiUrl=n),v&&(A.client_secret=v),"ANDROID_APP"===a.platform&&a.webToNative.makeTapToPayStripePayment(JSON.stringify(A)),"IOS_APP"===a.platform&&a.webToNativeIos){var N=i({action:"makeTapToPayStripePayment"},A);a.webToNativeIos.postMessage(N)}}}},781:function(e,o,t){var i=this;Object.defineProperty(o,"__esModule",{value:!0});var a=t(612),n=null;o.default=function(e){void 0===e&&(e={});var o=e.onVoiceSearch;return(0,a.registerCb)((function(e){var o=e,t=o.type,i=o.results;"VOICE_SEARCH_RESULT"===t&&(n&&n(i),n=null)})),a.isNativeApp&&a.webToNative.openVoiceSearch(),"function"==typeof o&&(n=o),i}},768:function(e,o,t){var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(o,"__esModule",{value:!0});var a=t(612),n=i(t(333));o.default=function(e){if(["ANDROID_APP","IOS_APP"].includes(a.platform)){var o=e.onBarcodeSearch,t=e.format;(0,a.registerCb)((function(e){var t=e.type,i=e.value;"BARCODE_SCAN"===t&&o&&o(i)})),"ANDROID_APP"===a.platform&&a.webToNative.startScanner&&a.webToNative.startScanner(JSON.stringify({formats:t?[t]:[]})),"IOS_APP"===a.platform&&a.webToNativeIos&&a.webToNativeIos.postMessage({action:"barcodeScan",barcodeFormat:String(t||n.default.ALL_FORMATS)})}}},333:function(e,o){var t;Object.defineProperty(o,"__esModule",{value:!0}),o.BarcodeFormat=void 0,function(e){e[e.ALL_FORMATS=0]="ALL_FORMATS",e[e.CODE_128=1]="CODE_128",e[e.CODE_39=2]="CODE_39",e[e.CODE_93=4]="CODE_93",e[e.CODABAR=8]="CODABAR",e[e.DATA_MATRIX=16]="DATA_MATRIX",e[e.EAN_13=32]="EAN_13",e[e.EAN_8=64]="EAN_8",e[e.ITF=128]="ITF",e[e.QR_CODE=256]="QR_CODE",e[e.UPC_A=512]="UPC_A",e[e.UPC_E=1024]="UPC_E",e[e.PDF417=2048]="PDF417",e[e.AZTEC=4096]="AZTEC"}(t=o.BarcodeFormat||(o.BarcodeFormat={})),o.default=t},706:function(e,o,t){var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(o,"__esModule",{value:!0}),o.BarcodeScan=o.Types=o.Format=void 0;var a=i(t(333));o.Format=a.default;var n=i(t(408));o.Types=n.default;var r=i(t(768));o.BarcodeScan=r.default},408:function(e,o){var t;Object.defineProperty(o,"__esModule",{value:!0}),o.BarcodeType=void 0,function(e){e.QR_CODE="QR_CODE",e.DATA_MATRIX="DATA_MATRIX",e.UPC_E="UPC_E",e.UPC_A="UPC_A",e.EAN_8="EAN_8",e.EAN_13="EAN_13",e.CODE_128="CODE_128",e.CODE_39="CODE_39",e.CODE_93="CODE_93",e.CODABAR="CODABAR",e.ITF="ITF",e.AZTEC="AZTEC",e.PDF_417="PDF_417"}(t=o.BarcodeType||(o.BarcodeType={})),o.default=t},56:function(e,o,t){Object.defineProperty(o,"__esModule",{value:!0}),o.isNativeApp=o.platform=o.registerNotification=o.showNativeComponents=o.hideNativeComponents=o.setOrientation=o.checkPermission=o.getAddOnStatus=o.getSafeArea=o.customBackHandling=o.disableScreenshot=o.updateAppIcon=o.showPermission=o.openAppSettingForPermission=o.forceUpdateCookies=o.appFirstLoad=o.addToSiri=o.loadOfferCard=o.nfcSupported=o.printFunction=o.showDateTimePicker=o.closeApp=o.shareFile=o.clearAppCache=o.enablePullToRefresh=o.openUrlInBrowser=o.shareLink=o.isDeviceGPSEnabled=o.showInAppReview=o.deviceInfo=o.customFileDownload=o.downloadBlobFile=o.downloadFile=o.statusBar=o.hideSplashScreen=o.isAndroidORIosApp=o.isIosApp=o.isAndroidApp=void 0;var i=t(612);Object.defineProperty(o,"isNativeApp",{enumerable:!0,get:function(){return i.isNativeApp}}),Object.defineProperty(o,"platform",{enumerable:!0,get:function(){return i.platform}}),o.isAndroidApp="ANDROID_APP"===i.platform,o.isIosApp="IOS_APP"===i.platform,o.isAndroidORIosApp=["ANDROID_APP","IOS_APP"].includes(i.platform),o.hideSplashScreen=function(){i.isNativeApp&&i.webToNative.hideSplashScreen&&i.webToNative.hideSplashScreen()},o.statusBar=function(e){i.isNativeApp&&(o.isAndroidApp?i.webToNative.statusBar&&i.webToNative.statusBar(JSON.stringify(e)):o.isIosApp&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"statusBar",color:e.color,style:e.style}))},o.downloadFile=function(e){i.isNativeApp&&(o.isAndroidApp||o.isIosApp&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"downloadFile",downloadUrl:e}))},o.downloadBlobFile=function(e){var t=e.fileName,a=e.downloadUrl;["IOS_APP"].includes(i.platform)&&o.isIosApp&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"downloadBlobFile",fileName:t,url:a})},o.customFileDownload=function(e){var o=e.downloadUrl,t=e.fileName,a=e.isBlob,n=e.mimeType,r=e.cookies,s=e.userAgent,l=e.openFileAfterDownload;["ANDROID_APP"].includes(i.platform)&&"ANDROID_APP"===i.platform&&i.webToNative.downloadFile&&i.webToNative.downloadFile(JSON.stringify({url:o,fileName:t,isBlob:a,mimeType:n,cookies:r,userAgent:s,openFileAfterDownload:l}))},o.deviceInfo=function(){return new Promise((function(e,o){(0,i.registerCb)((function(t){t?e(t):o({err:"Error getting device info"})}),{key:"deviceInfo"}),"ANDROID_APP"===i.platform?i.webToNative.getDeviceInfo&&i.webToNative.getDeviceInfo():"IOS_APP"===i.platform?i.webToNativeIos&&i.webToNativeIos.postMessage({action:"deviceInfo"}):o("This function will work in Native App Powered By WebToNative")}))},o.showInAppReview=function(){i.isNativeApp&&i.webToNative.showInAppReview&&i.webToNative.showInAppReview()},o.isDeviceGPSEnabled=function(e){void 0===e&&(e={});var o=e.callback;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"isDeviceGPSEnabled"===e.type&&o&&o(e)})),"ANDROID_APP"===i.platform&&i.webToNative.isLocationServiceEnabled&&i.webToNative.isLocationServiceEnabled())},o.shareLink=function(e){var t=e.url,a=void 0===t?"":t;if(!a)throw"url is mandatory";o.isAndroidApp&&i.webToNative.openShareIntent&&i.webToNative.openShareIntent(a),o.isIosApp&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"share",url:a})},o.openUrlInBrowser=function(e){if(void 0===e&&(e=""),!e)throw"url is mandatory";o.isAndroidApp&&i.webToNative.openUrlInBrowser&&i.webToNative.openUrlInBrowser(e)},o.enablePullToRefresh=function(e){o.isAndroidApp&&i.webToNative.enableSwipeRefresh&&i.webToNative.enableSwipeRefresh(e)},o.clearAppCache=function(e){o.isAndroidApp&&i.webToNative.clearWebViewCache&&i.webToNative.clearWebViewCache(JSON.stringify({reload:e}))},o.shareFile=function(e,t,a){void 0===e&&(e=null),void 0===t&&(t=null),void 0===a&&(a=null),o.isAndroidApp&&i.webToNative.shareFile&&i.webToNative.shareFile(e,t,a)},o.closeApp=function(){o.isAndroidApp&&i.webToNative.closeApp&&i.webToNative.closeApp(),o.isIosApp&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"closeApp"})},o.showDateTimePicker=function(e){if(["ANDROID_APP"].includes(i.platform)){var t=e.callback,a=e.showDate,n=e.showTime;(0,i.registerCb)((function(e){"DATE_TIME_PICKER"===e.type&&t&&t(e)})),o.isAndroidApp&&i.webToNative.pickDateTime&&i.webToNative.pickDateTime(JSON.stringify({showDate:a,showTime:n}))}},o.printFunction=function(e){if(["ANDROID_APP"].includes(i.platform)){var t=e.type,a=void 0===t?"url":t,n=e.url,r=void 0===n?"":n;o.isAndroidApp&&i.webToNative.print&&i.webToNative.print(JSON.stringify({type:a,url:r}))}},o.nfcSupported=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var t=e.callback;(0,i.registerCb)((function(e){"nfcSupported"===e.type&&t&&t(e)})),o.isAndroidApp&&i.webToNative.nfcSupported&&i.webToNative.nfcSupported(),o.isIosApp&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"nfcSupported"})}},o.loadOfferCard=function(e){["ANDROID_APP","IOS_APP"].includes(i.platform)&&(o.isAndroidApp&&i.webToNative.showOfferCard&&i.webToNative.showOfferCard(JSON.stringify(e)),e.data&&(e.data=JSON.stringify(e.data)),o.isIosApp&&i.webToNativeIos&&i.webToNativeIos.postMessage(e))},o.addToSiri=function(e){["IOS_APP"].includes(i.platform)&&(e.data&&(e.data=JSON.stringify(e.data)),o.isIosApp&&i.webToNativeIos&&i.webToNativeIos.postMessage(e))},o.appFirstLoad=function(){return new Promise((function(e,o){(0,i.registerCb)((function(t){"firstCallWhenAppStarted"===t.type&&(t?e(t):o({err:"Error getting request"}))}),{key:"firstCallWhenAppStarted"}),"ANDROID_APP"===i.platform?i.webToNative.firstCallWhenAppStarted&&i.webToNative.firstCallWhenAppStarted():"IOS_APP"===i.platform?i.webToNativeIos&&i.webToNativeIos.postMessage({action:"firstCallWhenAppStarted"}):o("This function will work in Native App Powered By WebToNative")}))},o.forceUpdateCookies=function(){["ANDROID_APP"].includes(i.platform)&&o.isAndroidApp&&i.webToNative.forceUpdateCookies&&i.webToNative.forceUpdateCookies()},o.openAppSettingForPermission=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var t=e.callback,a=e.values;(0,i.registerCb)((function(e){var o=e.type;e.typeValue,"openAppSettingForPermission"===o&&t&&t(e)})),o.isAndroidApp&&i.webToNative.openAppSettingForPermission&&i.webToNative.openAppSettingForPermission(a),o.isIosApp&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"openAppSettingForPermission",values:a})}},o.showPermission=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var t=e.callback,a=e.permission,n=e.openAppSetting,r=void 0!==n&&n,s=e.alertDialogStyle;(0,i.registerCb)((function(e){var o=e.type,i=e.typeValue;"showPermission"!==o&&"showPermission"!==i||t&&t(e)})),o.isAndroidApp&&i.webToNative.showPermission&&i.webToNative.showPermission(JSON.stringify({permission:a,openAppSetting:r,alertDialogStyle:s})),o.isIosApp&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"showPermission",permission:a,openAppSetting:r,alertDialogStyle:s})}},o.updateAppIcon=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var t=e.active,a=void 0!==t&&t,n=e.iconName,r=void 0===n?null:n;o.isAndroidApp&&i.webToNative.updateAppIcon&&i.webToNative.updateAppIcon(JSON.stringify({active:a,iconName:r})),o.isIosApp&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"updateAppIcon",iconName:r,active:a})}},o.disableScreenshot=function(e){if(["IOS_APP"].includes(i.platform)){var t=e.ssKey,a=void 0!==t&&t;o.isIosApp&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"disableScreenshotForPage",ssKey:a})}},o.customBackHandling=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var t=e.enable,a=void 0!==t&&t;o.isAndroidApp&&i.webToNative.customBackHandling&&i.webToNative.customBackHandling(JSON.stringify({enable:a})),o.isIosApp&&i.webToNativeIos&&(null===i.webToNativeIos||void 0===i.webToNativeIos||i.webToNativeIos.postMessage({action:"customBackHandling",enable:a}))}},o.getSafeArea=function(e){if(["IOS_APP"].includes(i.platform)){var t=e.callback;(0,i.registerCb)((function(e){"getSafeArea"===e.type&&t&&t(e)})),o.isIosApp&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"getSafeArea"})}},o.getAddOnStatus=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var t=e.callback,a=e.addOnName;(0,i.registerCb)((function(e){"getAddOnStatus"===e.type&&t&&t(e)})),o.isAndroidApp&&i.webToNative.getAddOnStatus&&i.webToNative.getAddOnStatus(JSON.stringify({addOnName:a})),o.isIosApp&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"getAddOnStatus",addOnName:a})}},o.checkPermission=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var t=e.callback,a=e.permissionName;(0,i.registerCb)((function(e){"checkPermission"===e.type&&t&&t(e)})),o.isAndroidApp&&i.webToNative.checkPermission&&i.webToNative.checkPermission(JSON.stringify(a)),o.isIosApp&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"checkPermission",permissionName:a})}},o.setOrientation=function(e){if(["ANDROID_APP"].includes(i.platform)){var t=e.orientation,a=e.forceOrientation,n=void 0!==a&&a;o.isAndroidApp&&i.webToNative.setOrientation&&i.webToNative.setOrientation(JSON.stringify({orientation:t,forceOrientation:n}))}},o.hideNativeComponents=function(e){if(o.isAndroidORIosApp){var t=(e||{}).components;o.isAndroidApp&&i.webToNative.hideNativeComponents&&i.webToNative.hideNativeComponents(JSON.stringify(e)),o.isIosApp&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"hideNativeComponents",components:t})}},o.showNativeComponents=function(e){if(o.isAndroidORIosApp){var t=(e||{}).components;o.isAndroidApp&&i.webToNative.showNativeComponents&&i.webToNative.showNativeComponents(JSON.stringify(e)),o.isIosApp&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"showNativeComponents",components:t})}},o.registerNotification=function(e){if(o.isAndroidORIosApp){var t=(e||{}).callback;(0,i.registerCb)((function(e){"registerNotification"===e.type&&t&&t(e)})),o.isAndroidApp&&i.webToNative.registerNotification&&i.webToNative.registerNotification(),o.isIosApp&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"registerNotification"})}},o.default={isAndroidApp:o.isAndroidApp,isIosApp:o.isIosApp,hideSplashScreen:o.hideSplashScreen,statusBar:o.statusBar,deviceInfo:o.deviceInfo,showInAppReview:o.showInAppReview,shareLink:o.shareLink,platform:i.platform,isNativeApp:i.isNativeApp,isDeviceGPSEnabled:o.isDeviceGPSEnabled,openUrlInBrowser:o.openUrlInBrowser,enablePullToRefresh:o.enablePullToRefresh,shareFile:o.shareFile,clearAppCache:o.clearAppCache,closeApp:o.closeApp,showDateTimePicker:o.showDateTimePicker,downloadBlobFile:o.downloadBlobFile,customFileDownload:o.customFileDownload,printFunction:o.printFunction,loadOfferCard:o.loadOfferCard,appFirstLoad:o.appFirstLoad,addToSiri:o.addToSiri,showPermission:o.showPermission,forceUpdateCookies:o.forceUpdateCookies,updateAppIcon:o.updateAppIcon,disableScreenshot:o.disableScreenshot,getSafeArea:o.getSafeArea,getAddOnStatus:o.getAddOnStatus,setOrientation:o.setOrientation,checkPermission:o.checkPermission,openAppSettingForPermission:o.openAppSettingForPermission,customBackHandling:o.customBackHandling,hideNativeComponents:o.hideNativeComponents,showNativeComponents:o.showNativeComponents,registerNotification:o.registerNotification}},612:function(e,o){Object.defineProperty(o,"__esModule",{value:!0}),o.deRegisterCbByKey=o.deRegisterForAbMobCb=o.registerForAbMobCb=o.registerCb=o.isNativeApp=o.platform=o.webToNativeIos=o.isClient=o.webToNative=void 0;var t="undefined"!=typeof window;o.isClient=t;var i=t&&window.WebToNativeInterface||{};o.webToNative=i;var a=t&&window.webkit&&window.webkit.messageHandlers&&window.webkit.messageHandlers.webToNativeInterface;o.webToNativeIos=a;var n=i.getAndroidVersion?"ANDROID_APP":a?"IOS_APP":"WEBSITE";o.platform=n;var r=t&&"WEBSITE"!==n;o.isNativeApp=r;var s={},l=1,p=null;r&&(i.androidCBHook=function(e){var o=e;try{o=JSON.parse(e)}catch(e){console.log(e)}for(var t in o.type,s){var i=s[t],a=i.cb,n=i.ignoreDelete,r=void 0!==n&&n;o&&o.reqType?t==o.reqType&&(a(o),r||delete s[t]):(a(o),r||delete s[t])}},window.iOSAdMobCBHook=i.androidAdMobCBHook=function(e){var o=JSON.parse(e);p&&p(o)},window.iosCBHook=function(e){var o=e;try{o=JSON.parse(e)}catch(e){console.log(e)}for(var t in s){var i=s[t],a=i.cb,n=i.ignoreDelete,r=void 0!==n&&n;o&&o.reqType?t==o.reqType&&(a(o),r||delete s[t]):(a(o),r||delete s[t])}}),o.registerCb=function(e,o){"function"==typeof e&&(o&&o.key?s[o.key]={cb:e,ignoreDelete:!!o.ignoreDelete}:(s[l]={cb:e,ignoreDelete:!(!o||!o.ignoreDelete)},l+=1))},o.registerForAbMobCb=function(e){"function"==typeof e&&(p=e)},o.deRegisterForAbMobCb=function(){p&&(p=null)},o.deRegisterCbByKey=function(e){delete s[e]}}},o={};!function t(i){var a=o[i];if(void 0!==a)return a.exports;var n=o[i]={exports:{}};return e[i].call(n.exports,n,n.exports,t),n.exports}(433)}();
|
package/SocialLogin/apple.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.login=void 0;var _utills=require("../utills"),login=function(a){if(["ANDROID_APP","IOS_APP"].includes(_utills.platform)){var b=a.callback,c=a.scope;(0,_utills.registerCb)(function(a){var c=a.type;"appleLoginToken"===c&&b&&b(a)}),"IOS_APP"===_utills.platform&&_utills.webToNativeIos.postMessage({action:"appleSignIn",scope:c})}};exports.login=login;
|
package/SocialLogin/facebook.js
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.logout=exports.login=void 0;var _utills=require("../utills"),login=function(a){if(["ANDROID_APP","IOS_APP"].includes(_utills.platform)){var b=a.callback,c=a.scope;(0,_utills.registerCb)(function(a){var c=a.type;"fbLoginToken"===c&&b&&b(a)}),"ANDROID_APP"===_utills.platform&&_utills.webToNative.loginWithFacebook(),"IOS_APP"===_utills.platform&&_utills.webToNativeIos.postMessage({action:"fbSignIn",scope:c})}};exports.login=login;/**
|
|
2
|
-
* This function handles native facebook logout
|
|
3
|
-
* @param {object} options
|
|
4
|
-
* @example wtn.socialLogin.facebook.logout({
|
|
5
|
-
* callback:(data)=>{
|
|
6
|
-
* console.log(data);
|
|
7
|
-
* }
|
|
8
|
-
* });
|
|
9
|
-
*/var logout=function(a){if(["ANDROID_APP","IOS_APP"].includes(_utills.platform)){var b=a.callback,c=a.scope;(0,_utills.registerCb)(function(a){var c=a.type;"fbLogOut"===c&&b&&b(a)}),"ANDROID_APP"===_utills.platform&&_utills.webToNative.logoutWithFacebook(),"IOS_APP"===_utills.platform&&_utills.webToNativeIos.postMessage({action:"fbSignOut",scope:c})}};exports.logout=logout;
|
package/SocialLogin/google.js
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.logout=exports.login=void 0;var _utills=require("../utills"),login=function(a){if(["ANDROID_APP","IOS_APP"].includes(_utills.platform)){var b=a.callback,c=a.scope;(0,_utills.registerCb)(function(a){var c=a.type;"googleLoginToken"===c&&b&&b(a)}),"ANDROID_APP"===_utills.platform&&_utills.webToNative.signInWithGoogle(),"IOS_APP"===_utills.platform&&_utills.webToNativeIos.postMessage({action:"googleSignIn",scope:c})}};exports.login=login;/**
|
|
2
|
-
* This function handles native google logout
|
|
3
|
-
* @param {object} options
|
|
4
|
-
* @example wtn.socialLogin.google.logout({
|
|
5
|
-
* callback:(data)=>{
|
|
6
|
-
* console.log(data);
|
|
7
|
-
* }
|
|
8
|
-
* });
|
|
9
|
-
*/var logout=function(a){if(["ANDROID_APP","IOS_APP"].includes(_utills.platform)){var b=a.callback,c=a.scope;(0,_utills.registerCb)(function(a){var c=a.type;"googleLogOut"===c&&b&&b(a)}),"ANDROID_APP"===_utills.platform&&_utills.webToNative.signOutWithGoogle(),"IOS_APP"===_utills.platform&&_utills.webToNativeIos.postMessage({action:"googleSignOut",scope:c})}};exports.logout=logout;
|