webtonative 1.0.74 → 1.0.75-beta.2
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/.editorconfig +10 -0
- package/.prettierrc.json +7 -0
- package/README.md +31 -2
- package/build/ATTConsent/index.d.ts +17 -0
- package/build/ATTConsent/index.d.ts.map +1 -0
- package/build/ATTConsent/index.js +54 -0
- package/build/ATTConsent/index.js.map +1 -0
- package/build/ATTConsent/types.d.ts +15 -0
- package/build/ATTConsent/types.d.ts.map +1 -0
- package/build/ATTConsent/types.js +3 -0
- package/build/ATTConsent/types.js.map +1 -0
- package/build/AdMob/index.d.ts +31 -0
- package/build/AdMob/index.d.ts.map +1 -0
- package/build/AdMob/index.js +102 -0
- package/build/AdMob/index.js.map +1 -0
- package/build/AdMob/types.d.ts +25 -0
- package/build/AdMob/types.d.ts.map +1 -0
- package/build/AdMob/types.js +4 -0
- package/build/AdMob/types.js.map +1 -0
- package/build/AppReview/index.d.ts +7 -0
- package/build/AppReview/index.d.ts.map +1 -0
- package/build/AppReview/index.js +22 -0
- package/build/AppReview/index.js.map +1 -0
- package/build/AppReview/types.d.ts +8 -0
- package/build/AppReview/types.d.ts.map +1 -0
- package/build/AppReview/types.js +4 -0
- package/build/AppReview/types.js.map +1 -0
- package/build/AppsFlyer/index.d.ts +15 -0
- package/build/AppsFlyer/index.d.ts.map +1 -0
- package/build/AppsFlyer/index.js +43 -0
- package/build/AppsFlyer/index.js.map +1 -0
- package/build/AppsFlyer/types.d.ts +10 -0
- package/build/AppsFlyer/types.d.ts.map +1 -0
- package/build/AppsFlyer/types.js +3 -0
- package/build/AppsFlyer/types.js.map +1 -0
- package/build/BackgroundLocation/index.d.ts +12 -0
- package/build/BackgroundLocation/index.d.ts.map +1 -0
- package/build/BackgroundLocation/index.js +65 -0
- package/build/BackgroundLocation/index.js.map +1 -0
- package/build/BackgroundLocation/types.d.ts +32 -0
- package/build/BackgroundLocation/types.d.ts.map +1 -0
- package/build/BackgroundLocation/types.js +3 -0
- package/build/BackgroundLocation/types.js.map +1 -0
- package/build/Beacon/index.d.ts +7 -0
- package/build/Beacon/index.d.ts.map +1 -0
- package/build/Beacon/index.js +30 -0
- package/build/Beacon/index.js.map +1 -0
- package/build/Beacon/types.d.ts +19 -0
- package/build/Beacon/types.d.ts.map +1 -0
- package/build/Beacon/types.js +3 -0
- package/build/Beacon/types.js.map +1 -0
- package/build/Biometric/index.d.ts +27 -0
- package/build/Biometric/index.d.ts.map +1 -0
- package/build/Biometric/index.js +125 -0
- package/build/Biometric/index.js.map +1 -0
- package/build/Biometric/types.d.ts +24 -0
- package/build/Biometric/types.d.ts.map +1 -0
- package/build/Biometric/types.js +3 -0
- package/build/Biometric/types.js.map +1 -0
- package/build/Bluetooth/index.d.ts +17 -0
- package/build/Bluetooth/index.d.ts.map +1 -0
- package/build/Bluetooth/index.js +67 -0
- package/build/Bluetooth/index.js.map +1 -0
- package/build/Bluetooth/types.d.ts +34 -0
- package/build/Bluetooth/types.d.ts.map +1 -0
- package/build/Bluetooth/types.js +3 -0
- package/build/Bluetooth/types.js.map +1 -0
- package/build/BottomNavigation/index.d.ts +11 -0
- package/build/BottomNavigation/index.d.ts.map +1 -0
- package/build/BottomNavigation/index.js +41 -0
- package/build/BottomNavigation/index.js.map +1 -0
- package/build/BottomNavigation/types.d.ts +9 -0
- package/build/BottomNavigation/types.d.ts.map +1 -0
- package/build/BottomNavigation/types.js +3 -0
- package/build/BottomNavigation/types.js.map +1 -0
- package/build/Clipboard/index.d.ts +12 -0
- package/build/Clipboard/index.d.ts.map +1 -0
- package/build/Clipboard/index.js +45 -0
- package/build/Clipboard/index.js.map +1 -0
- package/build/Clipboard/types.d.ts +20 -0
- package/build/Clipboard/types.d.ts.map +1 -0
- package/build/Clipboard/types.js +4 -0
- package/build/Clipboard/types.js.map +1 -0
- package/build/Facebook/events.d.ts +13 -0
- package/build/Facebook/events.d.ts.map +1 -0
- package/build/Facebook/events.js +44 -0
- package/build/Facebook/events.js.map +1 -0
- package/build/Facebook/index.d.ts +3 -0
- package/build/Facebook/index.d.ts.map +1 -0
- package/build/Facebook/index.js +29 -0
- package/build/Facebook/index.js.map +1 -0
- package/build/Facebook/types.d.ts +22 -0
- package/build/Facebook/types.d.ts.map +1 -0
- package/build/Facebook/types.js +3 -0
- package/build/Facebook/types.js.map +1 -0
- package/build/Firebase/Analytics/index.d.ts +32 -0
- package/build/Firebase/Analytics/index.d.ts.map +1 -0
- package/build/Firebase/Analytics/index.js +110 -0
- package/build/Firebase/Analytics/index.js.map +1 -0
- package/build/Firebase/Messaging/index.d.ts +17 -0
- package/build/Firebase/Messaging/index.d.ts.map +1 -0
- package/build/Firebase/Messaging/index.js +64 -0
- package/build/Firebase/Messaging/index.js.map +1 -0
- package/build/Firebase/index.d.ts +4 -0
- package/build/Firebase/index.d.ts.map +1 -0
- package/build/Firebase/index.js +31 -0
- package/build/Firebase/index.js.map +1 -0
- package/build/Firebase/types.d.ts +58 -0
- package/build/Firebase/types.d.ts.map +1 -0
- package/build/Firebase/types.js +4 -0
- package/build/Firebase/types.js.map +1 -0
- package/build/FirebaseAnalytics/index.d.ts +3 -0
- package/build/FirebaseAnalytics/index.d.ts.map +1 -0
- package/build/FirebaseAnalytics/index.js +29 -0
- package/build/FirebaseAnalytics/index.js.map +1 -0
- package/build/Haptics/index.d.ts +7 -0
- package/build/Haptics/index.d.ts.map +1 -0
- package/build/Haptics/index.js +21 -0
- package/build/Haptics/index.js.map +1 -0
- package/build/Haptics/types.d.ts +8 -0
- package/build/Haptics/types.d.ts.map +1 -0
- package/build/Haptics/types.js +3 -0
- package/build/Haptics/types.js.map +1 -0
- package/build/InAppPurchase/index.d.ts +23 -0
- package/build/InAppPurchase/index.d.ts.map +1 -0
- package/build/InAppPurchase/index.js +81 -0
- package/build/InAppPurchase/index.js.map +1 -0
- package/build/InAppPurchase/types.d.ts +30 -0
- package/build/InAppPurchase/types.d.ts.map +1 -0
- package/build/InAppPurchase/types.js +3 -0
- package/build/InAppPurchase/types.js.map +1 -0
- package/build/InAppUpdate/index.d.ts +12 -0
- package/build/InAppUpdate/index.d.ts.map +1 -0
- package/build/InAppUpdate/index.js +39 -0
- package/build/InAppUpdate/index.js.map +1 -0
- package/build/InAppUpdate/types.d.ts +15 -0
- package/build/InAppUpdate/types.d.ts.map +1 -0
- package/build/InAppUpdate/types.js +3 -0
- package/build/InAppUpdate/types.js.map +1 -0
- package/build/MediaPlayer/index.d.ts +17 -0
- package/build/MediaPlayer/index.d.ts.map +1 -0
- package/build/MediaPlayer/index.js +56 -0
- package/build/MediaPlayer/index.js.map +1 -0
- package/build/MediaPlayer/types.d.ts +14 -0
- package/build/MediaPlayer/types.d.ts.map +1 -0
- package/build/MediaPlayer/types.js +3 -0
- package/build/MediaPlayer/types.js.map +1 -0
- package/build/NativeContacts/index.d.ts +12 -0
- package/build/NativeContacts/index.d.ts.map +1 -0
- package/build/NativeContacts/index.js +51 -0
- package/build/NativeContacts/index.js.map +1 -0
- package/build/NativeContacts/types.d.ts +14 -0
- package/build/NativeContacts/types.d.ts.map +1 -0
- package/build/NativeContacts/types.js +3 -0
- package/build/NativeContacts/types.js.map +1 -0
- package/build/Notification/index.d.ts +11 -0
- package/build/Notification/index.d.ts.map +1 -0
- package/build/Notification/index.js +42 -0
- package/build/Notification/index.js.map +1 -0
- package/build/Notification/types.d.ts +14 -0
- package/build/Notification/types.d.ts.map +1 -0
- package/build/Notification/types.js +3 -0
- package/build/Notification/types.js.map +1 -0
- package/build/OneSignal/index.d.ts +4 -0
- package/build/OneSignal/index.d.ts.map +1 -0
- package/build/OneSignal/index.js +59 -0
- package/build/OneSignal/index.js.map +1 -0
- package/build/OneSignal/types.d.ts +11 -0
- package/build/OneSignal/types.d.ts.map +1 -0
- package/build/OneSignal/types.js +4 -0
- package/build/OneSignal/types.js.map +1 -0
- package/build/Printing/index.d.ts +7 -0
- package/build/Printing/index.d.ts.map +1 -0
- package/build/Printing/index.js +20 -0
- package/build/Printing/index.js.map +1 -0
- package/build/Printing/types.d.ts +9 -0
- package/build/Printing/types.d.ts.map +1 -0
- package/build/Printing/types.js +3 -0
- package/build/Printing/types.js.map +1 -0
- package/build/README.md +33 -0
- package/build/Screen/index.d.ts +9 -0
- package/build/Screen/index.d.ts.map +1 -0
- package/build/Screen/index.js +35 -0
- package/build/Screen/index.js.map +1 -0
- package/build/Screen/types.d.ts +6 -0
- package/build/Screen/types.d.ts.map +1 -0
- package/build/Screen/types.js +4 -0
- package/build/Screen/types.js.map +1 -0
- package/build/Siri/index.d.ts +7 -0
- package/build/Siri/index.d.ts.map +1 -0
- package/build/Siri/index.js +26 -0
- package/build/Siri/index.js.map +1 -0
- package/build/Siri/types.d.ts +14 -0
- package/build/Siri/types.d.ts.map +1 -0
- package/build/Siri/types.js +3 -0
- package/build/Siri/types.js.map +1 -0
- package/build/SocialLogin/apple.d.ts +12 -0
- package/build/SocialLogin/apple.d.ts.map +1 -0
- package/build/SocialLogin/apple.js +32 -0
- package/build/SocialLogin/apple.js.map +1 -0
- package/build/SocialLogin/facebook.d.ts +22 -0
- package/build/SocialLogin/facebook.d.ts.map +1 -0
- package/build/SocialLogin/facebook.js +61 -0
- package/build/SocialLogin/facebook.js.map +1 -0
- package/build/SocialLogin/google.d.ts +22 -0
- package/build/SocialLogin/google.d.ts.map +1 -0
- package/build/SocialLogin/google.js +61 -0
- package/build/SocialLogin/google.js.map +1 -0
- package/build/SocialLogin/index.d.ts +17 -0
- package/build/SocialLogin/index.d.ts.map +1 -0
- package/build/SocialLogin/index.js +23 -0
- package/build/SocialLogin/index.js.map +1 -0
- package/build/SocialLogin/types.d.ts +39 -0
- package/build/SocialLogin/types.d.ts.map +1 -0
- package/build/SocialLogin/types.js +3 -0
- package/build/SocialLogin/types.js.map +1 -0
- package/build/Stripe/index.d.ts +3 -0
- package/build/Stripe/index.d.ts.map +1 -0
- package/build/Stripe/index.js +49 -0
- package/build/Stripe/index.js.map +1 -0
- package/build/Stripe/types.d.ts +32 -0
- package/build/Stripe/types.d.ts.map +1 -0
- package/build/Stripe/types.js +3 -0
- package/build/Stripe/types.js.map +1 -0
- package/build/VoiceSearch/index.d.ts +13 -0
- package/build/VoiceSearch/index.d.ts.map +1 -0
- package/build/VoiceSearch/index.js +34 -0
- package/build/VoiceSearch/index.js.map +1 -0
- package/build/VoiceSearch/types.d.ts +10 -0
- package/build/VoiceSearch/types.d.ts.map +1 -0
- package/build/VoiceSearch/types.js +3 -0
- package/build/VoiceSearch/types.js.map +1 -0
- package/build/barcode/barcode-scan.d.ts +16 -0
- package/build/barcode/barcode-scan.d.ts.map +1 -0
- package/build/barcode/barcode-scan.js +40 -0
- package/build/barcode/barcode-scan.js.map +1 -0
- package/build/barcode/barcode-types.d.ts +18 -0
- package/build/barcode/barcode-types.d.ts.map +1 -0
- package/build/barcode/barcode-types.js +3 -0
- package/build/barcode/barcode-types.js.map +1 -0
- package/build/barcode/formats.d.ts +18 -0
- package/build/barcode/formats.d.ts.map +1 -0
- package/build/barcode/formats.js +23 -0
- package/build/barcode/formats.js.map +1 -0
- package/build/barcode/index.d.ts +5 -0
- package/build/barcode/index.d.ts.map +1 -0
- package/build/barcode/index.js +13 -0
- package/build/barcode/index.js.map +1 -0
- package/build/barcode/types.d.ts +17 -0
- package/build/barcode/types.d.ts.map +1 -0
- package/build/barcode/types.js +22 -0
- package/build/barcode/types.js.map +1 -0
- package/build/index.d.ts +15 -0
- package/build/index.d.ts.map +1 -0
- package/build/index.js +110 -0
- package/build/index.js.map +1 -0
- package/build/package.json +155 -0
- package/build/types/index.d.ts +49 -0
- package/build/types/index.d.ts.map +1 -0
- package/build/types/index.js +4 -0
- package/build/types/index.js.map +1 -0
- package/build/utills.d.ts +12 -0
- package/build/utills.d.ts.map +1 -0
- package/build/utills.js +111 -0
- package/build/utills.js.map +1 -0
- package/build/webtonative.min.js +1 -0
- package/buildScript.ts +35 -0
- package/client.ts +106 -0
- package/index.d.ts +65 -0
- package/package.json +36 -31
- package/src/ATTConsent/index.ts +51 -0
- package/src/ATTConsent/types.ts +17 -0
- package/src/AdMob/index.ts +113 -0
- package/src/AdMob/types.ts +37 -0
- package/src/AppReview/index.ts +19 -0
- package/src/AppReview/types.ts +12 -0
- package/src/AppsFlyer/index.ts +46 -0
- package/src/AppsFlyer/types.ts +10 -0
- package/src/BackgroundLocation/index.ts +78 -0
- package/src/BackgroundLocation/types.ts +34 -0
- package/src/Beacon/index.ts +28 -0
- package/src/Beacon/types.ts +22 -0
- package/src/Biometric/index.ts +126 -0
- package/src/Biometric/types.ts +27 -0
- package/src/Bluetooth/index.ts +71 -0
- package/src/Bluetooth/types.ts +40 -0
- package/src/BottomNavigation/index.ts +39 -0
- package/src/BottomNavigation/types.ts +9 -0
- package/src/Clipboard/index.ts +48 -0
- package/src/Clipboard/types.ts +30 -0
- package/src/Facebook/events.ts +45 -0
- package/src/Facebook/index.ts +3 -0
- package/src/Facebook/types.ts +24 -0
- package/src/Firebase/Analytics/index.ts +127 -0
- package/src/Firebase/Messaging/index.ts +73 -0
- package/src/Firebase/index.ts +4 -0
- package/src/Firebase/types.ts +74 -0
- package/src/FirebaseAnalytics/index.ts +3 -0
- package/src/Haptics/index.ts +17 -0
- package/src/Haptics/types.ts +8 -0
- package/src/InAppPurchase/index.ts +92 -0
- package/src/InAppPurchase/types.ts +35 -0
- package/src/InAppUpdate/index.ts +40 -0
- package/src/InAppUpdate/types.ts +17 -0
- package/src/MediaPlayer/index.ts +56 -0
- package/src/MediaPlayer/types.ts +15 -0
- package/src/NativeContacts/index.ts +50 -0
- package/src/NativeContacts/types.ts +16 -0
- package/src/Notification/index.ts +41 -0
- package/src/Notification/types.ts +16 -0
- package/src/OneSignal/index.ts +54 -0
- package/src/OneSignal/types.ts +15 -0
- package/src/Printing/index.ts +17 -0
- package/src/Printing/types.ts +9 -0
- package/src/Screen/index.ts +34 -0
- package/src/Screen/types.ts +8 -0
- package/src/Siri/index.ts +23 -0
- package/src/Siri/types.ts +14 -0
- package/src/SocialLogin/apple.ts +31 -0
- package/src/SocialLogin/facebook.ts +64 -0
- package/src/SocialLogin/google.ts +64 -0
- package/src/SocialLogin/index.ts +20 -0
- package/src/SocialLogin/types.ts +52 -0
- package/src/Stripe/index.ts +54 -0
- package/src/Stripe/types.ts +37 -0
- package/src/VoiceSearch/index.ts +37 -0
- package/src/VoiceSearch/types.ts +12 -0
- package/src/barcode/barcode-scan.ts +59 -0
- package/src/barcode/barcode-types.ts +22 -0
- package/src/barcode/formats.ts +19 -0
- package/src/barcode/index.ts +5 -0
- package/src/barcode/types.ts +18 -0
- package/src/index.ts +105 -0
- package/src/types/index.ts +71 -0
- package/src/utills.ts +110 -0
- package/tsconfig.json +27 -0
- package/webpack.config.js +57 -0
- package/ATTConsent/index.js +0 -1
- package/AdMob/index.js +0 -1
- package/AppReview/index.js +0 -1
- package/AppsFlyer/index.js +0 -4
- package/BackgroundLocation/index.js +0 -4
- package/Beacon/index.js +0 -1
- package/Biometric/index.js +0 -1
- package/Bluetooth/index.js +0 -1
- package/BottomNavigation/index.js +0 -4
- package/Clipboard/index.js +0 -4
- package/Facebook/events.js +0 -4
- package/Facebook/index.js +0 -1
- package/Firebase/Analytics/index.js +0 -4
- package/Firebase/Messaging/index.js +0 -4
- package/Firebase/index.js +0 -1
- package/FirebaseAnalytics/index.js +0 -1
- package/Haptics/index.js +0 -1
- package/InAppPurchase/index.js +0 -1
- package/InAppUpdate/index.js +0 -1
- package/MediaPlayer/index.js +0 -7
- package/NativeContacts/index.js +0 -6
- package/Notification/index.js +0 -5
- package/OneSignal/index.js +0 -1
- package/Printing/index.js +0 -1
- package/Screen/index.js +0 -4
- package/Siri/index.js +0 -1
- package/SocialLogin/apple.js +0 -1
- package/SocialLogin/facebook.js +0 -9
- package/SocialLogin/google.js +0 -9
- package/SocialLogin/index.js +0 -1
- package/Stripe/index.js +0 -1
- package/VoiceSearch/index.js +0 -1
- package/barcode/barcode-scan.js +0 -1
- package/barcode/formats.js +0 -1
- package/barcode/index.js +0 -1
- package/barcode/types.js +0 -1
- package/index.js +0 -4
- package/utills.js +0 -1
- package/webtonative.min.js +0 -1
|
@@ -0,0 +1,155 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "webtonative",
|
|
3
|
+
"version": "1.0.75-beta.2",
|
|
4
|
+
"description": "",
|
|
5
|
+
"main": "build/index.js",
|
|
6
|
+
"types": "build/index.d.ts",
|
|
7
|
+
"scripts": {
|
|
8
|
+
"build": "rimraf build && tsc && ts-node buildScript.ts && npm run dist",
|
|
9
|
+
"test": "echo \"Error: no test specified\" && exit 1",
|
|
10
|
+
"dist": "NODE_ENV=production webpack --config webpack.config.js"
|
|
11
|
+
},
|
|
12
|
+
"repository": {
|
|
13
|
+
"type": "git",
|
|
14
|
+
"url": "git+https://github.com/webtonative/webtonative.git"
|
|
15
|
+
},
|
|
16
|
+
"author": "",
|
|
17
|
+
"license": "ISC",
|
|
18
|
+
"bugs": {
|
|
19
|
+
"url": "https://github.com/webtonative/webtonative/issues"
|
|
20
|
+
},
|
|
21
|
+
"homepage": "https://github.com/webtonative/webtonative#readme",
|
|
22
|
+
"dependencies": {},
|
|
23
|
+
"devDependencies": {
|
|
24
|
+
"@babel/cli": "^7.14.5",
|
|
25
|
+
"@babel/core": "^7.14.6",
|
|
26
|
+
"@babel/preset-env": "^7.14.7",
|
|
27
|
+
"@types/node": "^18.11.18",
|
|
28
|
+
"babel-loader": "^8.2.2",
|
|
29
|
+
"babel-preset-minify": "^0.5.1",
|
|
30
|
+
"rimraf": "^3.0.2",
|
|
31
|
+
"ts-loader": "^9.4.2",
|
|
32
|
+
"ts-node": "^10.9.1",
|
|
33
|
+
"typescript": "^4.9.4",
|
|
34
|
+
"webpack": "^5.40.0",
|
|
35
|
+
"webpack-cli": "^4.7.2"
|
|
36
|
+
},
|
|
37
|
+
"exports": {
|
|
38
|
+
".": {
|
|
39
|
+
"import": "./build/index.js",
|
|
40
|
+
"types": "./build/index.d.ts"
|
|
41
|
+
},
|
|
42
|
+
"./ATTConsent": {
|
|
43
|
+
"import": "./build/ATTConsent/index.js",
|
|
44
|
+
"types": "./build/ATTConsent/index.d.ts"
|
|
45
|
+
},
|
|
46
|
+
"./AdMob": {
|
|
47
|
+
"import": "./build/AdMob/index.js",
|
|
48
|
+
"types": "./build/AdMob/index.d.ts"
|
|
49
|
+
},
|
|
50
|
+
"./AppReview": {
|
|
51
|
+
"import": "./build/AppReview/index.js",
|
|
52
|
+
"types": "./build/AppReview/index.d.ts"
|
|
53
|
+
},
|
|
54
|
+
"./AppsFlyer": {
|
|
55
|
+
"import": "./build/AppsFlyer/index.js",
|
|
56
|
+
"types": "./build/AppsFlyer/index.d.ts"
|
|
57
|
+
},
|
|
58
|
+
"./BackgroundLocation": {
|
|
59
|
+
"import": "./build/BackgroundLocation/index.js",
|
|
60
|
+
"types": "./build/BackgroundLocation/index.d.ts"
|
|
61
|
+
},
|
|
62
|
+
"./Beacon": {
|
|
63
|
+
"import": "./build/Beacon/index.js",
|
|
64
|
+
"types": "./build/Beacon/index.d.ts"
|
|
65
|
+
},
|
|
66
|
+
"./Biometric": {
|
|
67
|
+
"import": "./build/Biometric/index.js",
|
|
68
|
+
"types": "./build/Biometric/index.d.ts"
|
|
69
|
+
},
|
|
70
|
+
"./Bluetooth": {
|
|
71
|
+
"import": "./build/Bluetooth/index.js",
|
|
72
|
+
"types": "./build/Bluetooth/index.d.ts"
|
|
73
|
+
},
|
|
74
|
+
"./BottomNavigation": {
|
|
75
|
+
"import": "./build/BottomNavigation/index.js",
|
|
76
|
+
"types": "./build/BottomNavigation/index.d.ts"
|
|
77
|
+
},
|
|
78
|
+
"./Clipboard": {
|
|
79
|
+
"import": "./build/Clipboard/index.js",
|
|
80
|
+
"types": "./build/Clipboard/index.d.ts"
|
|
81
|
+
},
|
|
82
|
+
"./Facebook": {
|
|
83
|
+
"import": "./build/Facebook/index.js",
|
|
84
|
+
"types": "./build/Facebook/index.d.ts"
|
|
85
|
+
},
|
|
86
|
+
"./Firebase": {
|
|
87
|
+
"import": "./build/Firebase/index.js",
|
|
88
|
+
"types": "./build/Firebase/index.d.ts"
|
|
89
|
+
},
|
|
90
|
+
"./FirebaseAnalytics": {
|
|
91
|
+
"import": "./build/FirebaseAnalytics/index.js",
|
|
92
|
+
"types": "./build/FirebaseAnalytics/index.d.ts"
|
|
93
|
+
},
|
|
94
|
+
"./Haptics": {
|
|
95
|
+
"import": "./build/Haptics/index.js",
|
|
96
|
+
"types": "./build/Haptics/index.d.ts"
|
|
97
|
+
},
|
|
98
|
+
"./InAppPurchase": {
|
|
99
|
+
"import": "./build/InAppPurchase/index.js",
|
|
100
|
+
"types": "./build/InAppPurchase/index.d.ts"
|
|
101
|
+
},
|
|
102
|
+
"./InAppUpdate": {
|
|
103
|
+
"import": "./build/InAppUpdate/index.js",
|
|
104
|
+
"types": "./build/InAppUpdate/index.d.ts"
|
|
105
|
+
},
|
|
106
|
+
"./MediaPlayer": {
|
|
107
|
+
"import": "./build/MediaPlayer/index.js",
|
|
108
|
+
"types": "./build/MediaPlayer/index.d.ts"
|
|
109
|
+
},
|
|
110
|
+
"./NativeContacts": {
|
|
111
|
+
"import": "./build/NativeContacts/index.js",
|
|
112
|
+
"types": "./build/NativeContacts/index.d.ts"
|
|
113
|
+
},
|
|
114
|
+
"./Notification": {
|
|
115
|
+
"import": "./build/Notification/index.js",
|
|
116
|
+
"types": "./build/Notification/index.d.ts"
|
|
117
|
+
},
|
|
118
|
+
"./OneSignal": {
|
|
119
|
+
"import": "./build/OneSignal/index.js",
|
|
120
|
+
"types": "./build/OneSignal/index.d.ts"
|
|
121
|
+
},
|
|
122
|
+
"./Printing": {
|
|
123
|
+
"import": "./build/Printing/index.js",
|
|
124
|
+
"types": "./build/Printing/index.d.ts"
|
|
125
|
+
},
|
|
126
|
+
"./Screen": {
|
|
127
|
+
"import": "./build/Screen/index.js",
|
|
128
|
+
"types": "./build/Screen/index.d.ts"
|
|
129
|
+
},
|
|
130
|
+
"./Siri": {
|
|
131
|
+
"import": "./build/Siri/index.js",
|
|
132
|
+
"types": "./build/Siri/index.d.ts"
|
|
133
|
+
},
|
|
134
|
+
"./SocialLogin": {
|
|
135
|
+
"import": "./build/SocialLogin/index.js",
|
|
136
|
+
"types": "./build/SocialLogin/index.d.ts"
|
|
137
|
+
},
|
|
138
|
+
"./Stripe": {
|
|
139
|
+
"import": "./build/Stripe/index.js",
|
|
140
|
+
"types": "./build/Stripe/index.d.ts"
|
|
141
|
+
},
|
|
142
|
+
"./VoiceSearch": {
|
|
143
|
+
"import": "./build/VoiceSearch/index.js",
|
|
144
|
+
"types": "./build/VoiceSearch/index.d.ts"
|
|
145
|
+
},
|
|
146
|
+
"./barcode": {
|
|
147
|
+
"import": "./build/barcode/index.js",
|
|
148
|
+
"types": "./build/barcode/index.d.ts"
|
|
149
|
+
},
|
|
150
|
+
"./types": {
|
|
151
|
+
"import": "./build/types/index.js",
|
|
152
|
+
"types": "./build/types/index.d.ts"
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
}
|
|
@@ -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
|
+
}
|
|
18
|
+
export interface DownloadBlobFileOptions {
|
|
19
|
+
fileName: string;
|
|
20
|
+
downloadUrl: string;
|
|
21
|
+
}
|
|
22
|
+
export interface CustomFileDownloadOptions {
|
|
23
|
+
downloadUrl: string;
|
|
24
|
+
fileName: string;
|
|
25
|
+
isBlob?: boolean;
|
|
26
|
+
mimeType?: string;
|
|
27
|
+
cookies?: string;
|
|
28
|
+
userAgent?: string;
|
|
29
|
+
openFileAfterDownload?: boolean;
|
|
30
|
+
}
|
|
31
|
+
export interface DeviceInfoResponse {
|
|
32
|
+
[key: string]: any;
|
|
33
|
+
}
|
|
34
|
+
export interface WebToNativeInterface {
|
|
35
|
+
getAndroidVersion?: () => string;
|
|
36
|
+
hideSplashScreen?: () => void;
|
|
37
|
+
statusBar?: (options: string) => void;
|
|
38
|
+
downloadFile?: (options: string) => void;
|
|
39
|
+
getDeviceInfo?: () => void;
|
|
40
|
+
showInAppReview?: () => void;
|
|
41
|
+
startScanner?: (options: string) => void;
|
|
42
|
+
androidCBHook?: (results: string) => void;
|
|
43
|
+
androidAdMobCBHook?: (results: string) => void;
|
|
44
|
+
[key: string]: any;
|
|
45
|
+
}
|
|
46
|
+
export interface WebToNativeIosInterface {
|
|
47
|
+
postMessage: (message: any) => void;
|
|
48
|
+
}
|
|
49
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":"AAGA,MAAM,MAAM,QAAQ,GAAG,aAAa,GAAG,SAAS,GAAG,SAAS,CAAC;AAG7D,MAAM,WAAW,YAAY;IAC3B,IAAI,EAAE,MAAM,CAAC;IACb,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAC;CACpB;AAGD,MAAM,WAAW,YAAY;IAC3B,CAAC,QAAQ,EAAE,YAAY,GAAG,IAAI,CAAC;CAChC;AAGD,MAAM,MAAM,gBAAgB,GAAG,CAAC,QAAQ,EAAE,GAAG,KAAK,IAAI,CAAC;AAGvD,MAAM,WAAW,uBAAuB;IACtC,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,YAAY,CAAC,EAAE,OAAO,CAAC;CACxB;AAGD,MAAM,WAAW,gBAAgB;IAC/B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;CAC1B;AAGD,MAAM,WAAW,uBAAuB;IACtC,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;CACrB;AAGD,MAAM,WAAW,yBAAyB;IACxC,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,qBAAqB,CAAC,EAAE,OAAO,CAAC;CACjC;AAGD,MAAM,WAAW,kBAAkB;IACjC,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAC;CACpB;AAGD,MAAM,WAAW,oBAAoB;IACnC,iBAAiB,CAAC,EAAE,MAAM,MAAM,CAAC;IACjC,gBAAgB,CAAC,EAAE,MAAM,IAAI,CAAC;IAC9B,SAAS,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;IACtC,YAAY,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;IACzC,aAAa,CAAC,EAAE,MAAM,IAAI,CAAC;IAC3B,eAAe,CAAC,EAAE,MAAM,IAAI,CAAC;IAC7B,YAAY,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;IACzC,aAAa,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;IAC1C,kBAAkB,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;IAC/C,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAC;CACpB;AAGD,MAAM,WAAW,uBAAuB;IACtC,WAAW,EAAE,CAAC,OAAO,EAAE,GAAG,KAAK,IAAI,CAAC;CACrC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":";AAAA,kDAAkD"}
|
|
@@ -0,0 +1,12 @@
|
|
|
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, };
|
|
12
|
+
//# sourceMappingURL=utills.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"utills.d.ts","sourceRoot":"","sources":["../src/utills.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,oBAAoB,EAAE,uBAAuB,EAAE,gBAAgB,EAAE,uBAAuB,EAAE,MAAM,SAAS,CAAC;AAE7H,QAAA,MAAM,QAAQ,EAAE,OAAuC,CAAC;AACxD,QAAA,MAAM,WAAW,EAAE,oBAA+E,CAAC;AACnG,QAAA,MAAM,cAAc,EAAE,uBAAuB,GAAG,KAIY,CAAC;AAC7D,QAAA,MAAM,QAAQ,EAAE,QAIJ,CAAC;AACb,QAAA,MAAM,WAAW,EAAE,OAA4C,CAAC;AA4DhE,QAAA,MAAM,UAAU,OAAQ,gBAAgB,QAAQ,uBAAuB,SAStE,CAAC;AACF,QAAA,MAAM,kBAAkB,OAAQ,gBAAgB,SAI/C,CAAC;AACF,QAAA,MAAM,oBAAoB,YAIzB,CAAC;AAEF,QAAA,MAAM,iBAAiB,QAAS,MAAM,GAAG,MAAM,SAE9C,CAAC;AAEF,OAAO,EACN,WAAW,EACX,QAAQ,EACR,cAAc,EACd,QAAQ,EACR,WAAW,EACX,UAAU,EACV,kBAAkB,EAClB,oBAAoB,EACpB,iBAAiB,GACjB,CAAC"}
|
package/build/utills.js
ADDED
|
@@ -0,0 +1,111 @@
|
|
|
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;
|
|
111
|
+
//# sourceMappingURL=utills.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"utills.js","sourceRoot":"","sources":["../src/utills.ts"],"names":[],"mappings":";;;AAEA,IAAM,QAAQ,GAAY,OAAO,MAAM,KAAK,WAAW,CAAC;AAmGvD,4BAAQ;AAlGT,IAAM,WAAW,GAAyB,CAAC,QAAQ,IAAK,MAAc,CAAC,oBAAoB,CAAC,IAAI,EAAE,CAAC;AAiGlG,kCAAW;AAhGZ,IAAM,cAAc,GACnB,QAAQ;IACP,MAAc,CAAC,MAAM;IACrB,MAAc,CAAC,MAAM,CAAC,eAAe;IACrC,MAAc,CAAC,MAAM,CAAC,eAAe,CAAC,oBAAoB,CAAC;AA8F5D,wCAAc;AA7Ff,IAAM,QAAQ,GAAa,WAAW,CAAC,iBAAiB;IACvD,CAAC,CAAC,aAAa;IACf,CAAC,CAAC,cAAc;QAChB,CAAC,CAAC,SAAS;QACX,CAAC,CAAC,SAAS,CAAC;AA0FZ,4BAAQ;AAzFT,IAAM,WAAW,GAAY,QAAQ,IAAI,QAAQ,KAAK,SAAS,CAAC;AA0F/D,kCAAW;AAzFZ,IAAM,KAAK,GAA8E,EAAE,CAAC;AAC5F,IAAI,OAAO,GAAW,CAAC,CAAC;AACxB,IAAI,OAAO,GAA4B,IAAI,CAAC;AAC5C,IAAI,WAAW,EAAE;IAChB,WAAW,CAAC,aAAa,GAAG,UAAC,OAAe;QAC3C,IAAI,QAAQ,GAAQ,OAAO,CAAC;QAC5B,IAAI;YACH,QAAQ,GAAG,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;SAC/B;QAAC,OAAO,CAAC,EAAE;YACX,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;SACf;QACO,IAAA,IAAI,GAAK,QAAQ,KAAb,CAAc;QAC1B,KAAK,IAAI,GAAG,IAAI,KAAK,EAAE;YAChB,IAAA,KAA+B,KAAK,CAAC,GAAG,CAAC,EAAvC,EAAE,QAAA,EAAE,oBAAoB,EAApB,YAAY,mBAAG,KAAK,KAAe,CAAC;YAChD,IAAI,QAAQ,IAAI,QAAQ,CAAC,OAAO,EAAE;gBACjC,IAAI,GAAG,IAAI,QAAQ,CAAC,SAAS,CAAC,EAAE;oBAC/B,EAAE,CAAC,QAAQ,CAAC,CAAC;oBACb,IAAI,CAAC,YAAY,EAAE;wBAClB,OAAO,KAAK,CAAC,GAAG,CAAC,CAAC;qBAClB;iBACD;aACD;iBAAM;gBACN,EAAE,CAAC,QAAQ,CAAC,CAAC;gBACb,IAAI,CAAC,YAAY,EAAE;oBAClB,OAAO,KAAK,CAAC,GAAG,CAAC,CAAC;iBAClB;aACD;SACD;IACF,CAAC,CAAC;IACD,MAAc,CAAC,cAAc,GAAG,WAAW,CAAC,kBAAkB,GAAG,UAAC,OAAe;QACjF,IAAM,WAAW,GAAG,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;QACxC,OAAO,IAAI,OAAO,CAAC,WAAW,CAAC,CAAC;IACjC,CAAC,CAAC;IACD,MAAc,CAAC,SAAS,GAAG,UAAC,OAAe;QAC3C,IAAI,QAAQ,GAAQ,OAAO,CAAC;QAC5B,IAAI;YACH,QAAQ,GAAG,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;SAC/B;QAAC,OAAO,CAAC,EAAE;YACX,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;SACf;QACD,KAAK,IAAI,GAAG,IAAI,KAAK,EAAE;YAChB,IAAA,KAA+B,KAAK,CAAC,GAAG,CAAC,EAAvC,EAAE,QAAA,EAAE,oBAAoB,EAApB,YAAY,mBAAG,KAAK,KAAe,CAAC;YAChD,IAAI,QAAQ,IAAI,QAAQ,CAAC,OAAO,EAAE;gBACjC,IAAI,GAAG,IAAI,QAAQ,CAAC,SAAS,CAAC,EAAE;oBAC/B,EAAE,CAAC,QAAQ,CAAC,CAAC;oBACb,IAAI,CAAC,YAAY,EAAE;wBAClB,OAAO,KAAK,CAAC,GAAG,CAAC,CAAC;qBAClB;iBACD;aACD;iBAAM;gBACN,EAAE,CAAC,QAAQ,CAAC,CAAC;gBACb,IAAI,CAAC,YAAY,EAAE;oBAClB,OAAO,KAAK,CAAC,GAAG,CAAC,CAAC;iBAClB;aACD;SACD;IACF,CAAC,CAAC;CACF;AAED,IAAM,UAAU,GAAG,UAAC,EAAoB,EAAE,GAA6B;IACtE,IAAI,OAAO,EAAE,KAAK,UAAU,EAAE;QAC7B,IAAI,GAAG,IAAI,GAAG,CAAC,GAAG,EAAE;YACnB,KAAK,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC,GAAG,EAAE,EAAE,IAAA,EAAE,YAAY,EAAE,GAAG,CAAC,YAAY,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,EAAE,CAAC;SAC1E;aAAM;YACN,KAAK,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,IAAA,EAAE,YAAY,EAAE,GAAG,IAAI,GAAG,CAAC,YAAY,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,EAAE,CAAC;YAC9E,OAAO,IAAI,CAAC,CAAC;SACb;KACD;AACF,CAAC,CAAC;AAsBD,gCAAU;AArBX,IAAM,kBAAkB,GAAG,UAAC,EAAoB;IAC/C,IAAI,OAAO,EAAE,KAAK,UAAU,EAAE;QAC7B,OAAO,GAAG,EAAE,CAAC;KACb;AACF,CAAC,CAAC;AAkBD,gDAAkB;AAjBnB,IAAM,oBAAoB,GAAG;IAC5B,IAAI,OAAO,EAAE;QACZ,OAAO,GAAG,IAAI,CAAC;KACf;AACF,CAAC,CAAC;AAcD,oDAAoB;AAZrB,IAAM,iBAAiB,GAAG,UAAC,GAAoB;IAC9C,OAAO,KAAK,CAAC,GAAG,CAAC,CAAC;AACnB,CAAC,CAAC;AAWD,8CAAiB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
!function(){"use strict";var e={433:function(e,t,o){var i=this&&this.__createBinding||(Object.create?function(e,t,o,i){void 0===i&&(i=o);var a=Object.getOwnPropertyDescriptor(t,o);a&&!("get"in a?!t.__esModule:a.writable||a.configurable)||(a={enumerable:!0,get:function(){return t[o]}}),Object.defineProperty(e,i,a)}:function(e,t,o,i){void 0===i&&(i=o),e[i]=t[o]}),a=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),r=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var o in e)"default"!==o&&Object.prototype.hasOwnProperty.call(e,o)&&i(t,e,o);return a(t,e),t},n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var s=r(o(56)),c=r(o(198)),l=n(o(781)),p=r(o(706)),u=r(o(545)),P=o(699),f=r(o(45)),d=o(854),v=r(o(959)),A=r(o(226)),b=r(o(380)),I=r(o(549)),N=r(o(30)),_=r(o(200)),O=r(o(283)),w=r(o(358)),D=r(o(750)),m=r(o(539)),T=r(o(211)),g=r(o(153)),S=r(o(448)),y=r(o(550)),R=r(o(148)),M=r(o(75)),h=r(o(157)),C=r(o(876)),k=r(o(668)),F=r(o(633));window.WTN=s,window.WTN.OneSignal=c,window.WTN.VoiceSearch=l.default,window.WTN.Barcode=p,window.WTN.AdMob=u,window.WTN.socialLogin=P.socialLogin,window.WTN.inAppPurchase=d.inAppPurchase,window.WTN.getAllPurchases=d.getAllPurchases,window.WTN.getReceiptData=d.getReceiptData,window.WTN.appsflyer=f,window.WTN.bottomNavigation=A,window.WTN.contacts=b,window.WTN.screen=N,window.WTN.backgroundLocation=I,window.WTN.clipboard=_,window.WTN.appReview=O,window.WTN.Biometric=w,window.WTN.ATTConsent=D,window.WTN.facebook={events:v},window.WTN.FirebaseAnalytics=m,window.WTN.Firebase=T,window.WTN.Haptics=g,window.WTN.MediaPlayer=S,window.WTN.Printing=y,window.WTN.Notification=R,window.WTN.Bluetooth=M,window.WTN.Stripe=h,window.WTN.InAppUpdate=C,window.WTN.Siri=k,window.WTN.Beacon=F,t.default=window.WTN},750:function(e,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.status=t.request=void 0;var i=o(612);t.request=function(e){void 0===e&&(e={});var t=e.callback;["IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"requestTrackingConsent"===e.type&&t&&t(e)})),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"requestTrackingAuthorization"}))},t.status=function(e){void 0===e&&(e={});var t=e.callback;["IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"trackingConsentStatus"===e.type&&t&&t(e)})),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"trackingConsentStatus"}))}},545:function(e,t,o){var i=this;Object.defineProperty(t,"__esModule",{value:!0}),t.rewardsAd=t.fullScreenAd=t.bannerAd=void 0;var a=o(612),r=null;t.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},t.fullScreenAd=function(e){if(void 0===e&&(e={}),["ANDROID_APP","IOS_APP"].includes(a.platform)){var t=e.fullScreenAdCallback;return(0,a.registerForAbMobCb)((function(e){var t=e.status;r&&r(e),"adDismissed"===t&&(r=null),["adDismissed","adLoadError","adError"].indexOf(t)>-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 t&&(r=t),i}},t.rewardsAd=function(e){if(void 0===e&&(e={}),["ANDROID_APP","IOS_APP"].includes(a.platform)){var t=e.rewardsAdCallback;return(0,a.registerForAbMobCb)((function(e){var t=e.status;r&&r(e),"adDismissed"===t&&(r=null),["adDismissed","adLoadError","adError"].indexOf(t)>-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 t&&(r=t),i}}},283:function(e,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.prompt=void 0;var i=o(612);t.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,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.logEvent=t.setCustomerUserId=void 0;var i=o(612);t.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}))},t.logEvent=function(e,t){["ANDROID_APP","IOS_APP"].includes(i.platform)&&("ANDROID_APP"===i.platform&&i.webToNative.addEventToAppsFlyer(e,JSON.stringify(t)),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"addEventToAppsFlyer",eventName:e,eventValues:t}))}},549:function(e,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.stop=t.start=void 0;var i=o(612);t.start=function(e){if(void 0===e&&(e={}),["ANDROID_APP","IOS_APP"].includes(i.platform)){var t=e.data,o=e.callback,a=e.backgroundIndicator,r=void 0!==a&&a,n=e.pauseAutomatically,s=void 0===n||n,c=e.distanceFilter,l=void 0===c?0:c,p=e.desiredAccuracy,u=void 0===p?"best":p,P=e.activityType,f=void 0===P?"other":P,d=e.apiUrl,v=e.timeout;(0,i.registerCb)((function(e){"LOCATION_UPDATE"===e.type&&o&&o(e)}),{key:"LOCATION_UPDATE",ignoreDelete:!0}),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"startLocation",data:t,backgroundIndicator:r,pauseAutomatically:s,distanceFilter:l,desiredAccuracy:u,activityType:f,apiUrl:d,timeout:v}),"ANDROID_APP"===i.platform&&i.webToNative.startTrackingLocation(JSON.stringify({action:"startLocation",data:t,interval:v,callback:o,apiUrl:d,displacement:l}))}},t.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,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.initBeaconData=void 0;var i=o(612);t.initBeaconData=function(e){void 0===e&&(e={});var t=e.callback,o=e.beaconData;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"initBeaconData"===e.type&&t&&t(e)})),"ANDROID_APP"===i.platform&&i.webToNative.initBeaconData(JSON.stringify(o)),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"initBeaconData",data:o}))}},358:function(e,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.biometricAuthWithDismissOnCancel=t.show=t.deleteSecret=t.saveSecret=t.checkStatus=void 0;var i=o(612);t.checkStatus=function(e){void 0===e&&(e={});var t=e.callback;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"checkBiometricStatus"===e.type&&t&&t(e)})),"ANDROID_APP"===i.platform&&i.webToNative.checkBiometricStatus(),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"checkBiometricStatus"}))},t.saveSecret=function(e){void 0===e&&(e={});var t=e.callback,o=e.secret;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"saveBiometricSecret"===e.type&&t&&t(e)})),"ANDROID_APP"===i.platform&&i.webToNative.saveSecret(o),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"saveBiometricSecret",secret:o}))},t.deleteSecret=function(e){void 0===e&&(e={});var t=e.callback;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"deleteBiometricSecret"===e.type&&t&&t(e)})),"ANDROID_APP"===i.platform&&i.webToNative.deleteSecret(),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"deleteBiometricSecret"}))},t.show=function(e){void 0===e&&(e={});var t=e.callback,o=e.prompt;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"showBiometric"===e.type&&t&&t(e)})),"ANDROID_APP"===i.platform&&i.webToNative.callBiometric(o||"Authenticate to continue!"),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"showBiometric",prompt:o||""}))},t.biometricAuthWithDismissOnCancel=function(e){void 0===e&&(e={});var t=e.callback,o=e.prompt,a=e.isAuthenticationOptional,r=void 0!==a&&a;["ANDROID_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"biometricAuthWithDismissOnCancel"===e.type&&t&&t(e)})),"ANDROID_APP"===i.platform&&i.webToNative.biometricAuthWithDismissOnCancel(JSON.stringify({prompt:o||"Authenticate to continue!",isAuthenticationOptional:r})))}},75:function(e,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.unpairDevice=t.pairDevice=t.startBluetoothScan=void 0;var i=o(612);t.startBluetoothScan=function(e){void 0===e&&(e={});var t=e.callback;["ANDROID_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"startBluetoothScan"===e.type&&t&&t(e)})),"ANDROID_APP"===i.platform&&i.webToNative.startBluetoothScan())},t.pairDevice=function(e){void 0===e&&(e={});var t=e.callback,o=e.address,a=e.timeout,r=void 0===a?10:a;["ANDROID_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"pairWithDevice"===e.type&&t&&t(e)})),"ANDROID_APP"===i.platform&&i.webToNative.pairWithDevice(JSON.stringify({address:o,timeout:r})))},t.unpairDevice=function(e){void 0===e&&(e={});var t=e.callback,o=e.address;["ANDROID_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"unpairDevice"===e.type&&t&&t(e)})),"ANDROID_APP"===i.platform&&i.webToNative.unpairDevice(JSON.stringify({address:o})))}},226:function(e,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.show=t.hide=void 0;var i=o(612);t.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}))},t.show=function(e){void 0===e&&(e={});var t=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:t}))}},200:function(e,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.set=t.get=void 0;var i=o(612);t.get=function(e){void 0===e&&(e={});var t=e.callback;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"CLIPBOARD_CONTENT"===e.type&&t&&t(e)})),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"getClipBoardData"}),"ANDROID_APP"===i.platform&&i.webToNative.getText())},t.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,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.sendPurchase=t.send=void 0;var i=o(612);t.send=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var t=e.event,o=e.valueToSum,a=e.parameters;"ANDROID_APP"===i.platform&&i.webToNative.addFbEvents(t,a),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"sendFBEvent",eventName:t,valueToSum:o,parameters:a})}},t.sendPurchase=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var t=e.amount,o=e.currency,a=e.parameters;"ANDROID_APP"===i.platform&&i.webToNative.addFbPurchaseEvent(t,o,a),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"sendFBPurchaseEvent",currency:o,amount:t,parameters:a})}}},800:function(e,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.logScreen=t.logEvent=t.setDefaultEventParameters=t.setUserProperty=t.setUserId=t.setCollection=void 0;var i=o(612);t.setCollection=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var t=e.enabled;"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"setFirebaseAnalyticsCollection",enabled:t}),"ANDROID_APP"===i.platform&&i.webToNative.setFirebaseAnalyticsCollection(t)}},t.setUserId=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var t=e.userId;"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"setFirebaseUserId",userId:t}),"ANDROID_APP"===i.platform&&i.webToNative.setFirebaseUserId(t)}},t.setUserProperty=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var t=e.key,o=e.value;"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"setFirebaseUserProp",key:t,value:o}),"ANDROID_APP"===i.platform&&i.webToNative.setFirebaseUserProp(t,o)}},t.setDefaultEventParameters=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var t=e.parameters;"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"setFirebaseDefaultParam",parameters:t}),"ANDROID_APP"===i.platform&&i.webToNative.setFirebaseDefaultParam(t)}},t.logEvent=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var t=e.eventName,o=e.parameters;"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"logFirebaseEvent",eventName:t,parameters:o}),"ANDROID_APP"===i.platform&&i.webToNative.logFirebaseEvent(t,o)}},t.logScreen=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var t=e.screenName,o=e.screenClass;"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"logFirebaseScreenView",screenName:t,screenClass:o}),"ANDROID_APP"===i.platform&&i.webToNative.logFirebaseScreenView(t,o)}}},918:function(e,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.getFCMToken=t.unsubscribe=t.subscribe=void 0;var i=o(612);t.subscribe=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var t=e.toTopic;"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"firebaseSubscribeToTopic",topic:t}),"ANDROID_APP"===i.platform&&i.webToNative.subscribeToTopic(t)}},t.unsubscribe=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var t=e.fromTopic;"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"firebaseUnsubscribeFromTopic",topic:t}),"ANDROID_APP"===i.platform&&i.webToNative.unsubscribeFromTopic(t)}},t.getFCMToken=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var t=e.callback;(0,i.registerCb)((function(e){"getFCMToken"===e.type&&("ANDROID_APP"===i.platform&&(e.token=e.fcm_registration_token),t&&t(e))})),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"getFCMToken"}),"ANDROID_APP"===i.platform&&i.webToNative.getRegistrationToken()}}},211:function(e,t,o){var i=this&&this.__createBinding||(Object.create?function(e,t,o,i){void 0===i&&(i=o);var a=Object.getOwnPropertyDescriptor(t,o);a&&!("get"in a?!t.__esModule:a.writable||a.configurable)||(a={enumerable:!0,get:function(){return t[o]}}),Object.defineProperty(e,i,a)}:function(e,t,o,i){void 0===i&&(i=o),e[i]=t[o]}),a=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),r=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var o in e)"default"!==o&&Object.prototype.hasOwnProperty.call(e,o)&&i(t,e,o);return a(t,e),t};Object.defineProperty(t,"__esModule",{value:!0}),t.Messaging=t.Analytics=void 0;var n=r(o(800));t.Analytics=n;var s=r(o(918));t.Messaging=s},539:function(e,t,o){var i=this&&this.__createBinding||(Object.create?function(e,t,o,i){void 0===i&&(i=o);var a=Object.getOwnPropertyDescriptor(t,o);a&&!("get"in a?!t.__esModule:a.writable||a.configurable)||(a={enumerable:!0,get:function(){return t[o]}}),Object.defineProperty(e,i,a)}:function(e,t,o,i){void 0===i&&(i=o),e[i]=t[o]}),a=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),r=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var o in e)"default"!==o&&Object.prototype.hasOwnProperty.call(e,o)&&i(t,e,o);return a(t,e),t};Object.defineProperty(t,"__esModule",{value:!0}),t.events=void 0;var n=r(o(800));t.events=n},153:function(e,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.trigger=void 0;var i=o(612);t.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,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.getReceiptData=t.getAllPurchases=t.inAppPurchase=void 0;var i=o(612);t.inAppPurchase=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var t=e.callback,o=e.productId,a=e.productType,r=e.isConsumable,n=void 0!==r&&r;(0,i.registerCb)((function(e){"inAppPurchase"===e.type&&t&&t(e)})),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"inAppPurchase",productId:o}),"ANDROID_APP"===i.platform&&i.webToNative.inAppPurchase(JSON.stringify({action:"inAppPurchase",productId:o,productType:a,isConsumable:n}))}},t.getAllPurchases=function(e){if(["ANDROID_APP"].includes(i.platform)){var t=e.callback;(0,i.registerCb)((function(e){"purchaseList"===e.type&&t&&t(e)})),"ANDROID_APP"===i.platform&&i.webToNative.getAllPurchases({action:"purchaseList"})}},t.getReceiptData=function(e){if(["IOS_APP"].includes(i.platform)){var t=e.callback;(0,i.registerCb)((function(e){"getReceiptData"===e.type&&t&&t(e)})),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"getReceiptData"})}}},876:function(e,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.updateApplication=t.checkIfAppUpdateAvailable=void 0;var i=o(612);t.checkIfAppUpdateAvailable=function(e){if(["ANDROID_APP"].includes(i.platform)){var t=e.callback;(0,i.registerCb)((function(e){"checkIfAppUpdateAvailable"===e.type&&t&&t(e)})),"ANDROID_APP"===i.platform&&i.webToNative.checkIfAppUpdateAvailable()}},t.updateApplication=function(e){if(["ANDROID_APP"].includes(i.platform)){var t=e.updateType,o=void 0===t?"immediate":t,a=e.callback;(0,i.registerCb)((function(e){"updateApplication"===e.type&&a&&a(e)})),"ANDROID_APP"===i.platform&&i.webToNative.updateApplication(o)}}},448:function(e,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.stopMedia=t.pauseMedia=t.playMedia=void 0;var i=o(612);t.playMedia=function(e){void 0===e&&(e={});var t=e.url,o=e.imageUrl,a=void 0===o?"https://images.freeimages.com/images/large-previews/3b2/prague-conference-center-1056491.jpg":o;["ANDROID_APP","IOS_APP"].includes(i.platform)&&("ANDROID_APP"===i.platform&&i.webToNative.playMedia(JSON.stringify({url:t,imageUrl:a})),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"playMedia",url:t,image:a}))},t.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"}))},t.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,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.getAll=t.getPermissionStatus=void 0;var i=o(612);t.getPermissionStatus=function(e){void 0===e&&(e={});var t=e.callback;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"contactPermissionStatus"===e.type&&t&&t(e)})),"ANDROID_APP"===i.platform&&i.webToNative.getPermissionStatus(),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"askUserForContactPermission"}))},t.getAll=function(e){void 0===e&&(e={});var t=e.callback;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"contactDetails"===e.type&&t&&t(e)})),"ANDROID_APP"===i.platform&&i.webToNative.getAll(),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"getUserContactDetails"}))}},148:function(e,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.openAppNotificationPage=t.checkNotificationPermission=void 0;var i=o(612);t.checkNotificationPermission=function(e){void 0===e&&(e={});var t=e.callback;["ANDROID_APP","IOS_APP"].includes(i.platform)&&((0,i.registerCb)((function(e){"checkNotificationPermission"===e.type&&t&&t(e)})),"ANDROID_APP"===i.platform&&i.webToNative.checkNotificationPermission(),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"checkNotificationPermission"}))},t.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,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.removeExternalUserId=t.setExternalUserId=t.getPlayerId=void 0;var i=o(612);t.getPlayerId=function(){return new Promise((function(e,t){(0,i.registerCb)((function(o){o.isSuccess?e(o.playerId):t(o)}),{key:"getPlayerId"}),"ANDROID_APP"===i.platform?i.webToNative.getOneSignalId():"IOS_APP"===i.platform&&i.webToNativeIos?i.webToNativeIos.postMessage({action:"getPlayerId"}):t("This function will work in Native App Powered By WebToNative")}))},t.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})},t.removeExternalUserId=function(){if("ANDROID_APP"===i.platform)return i.isNativeApp&&i.webToNative.removeExternalUserId();"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"removeExternalUserId"})}},550:function(e,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.setPrintSize=void 0;var i=o(612);t.setPrintSize=function(e){if(["ANDROID_APP"].includes(i.platform)){var t=e.printSize,o=void 0===t?"ISO_A4":t,a=e.label,r=void 0===a?"":a;"ANDROID_APP"===i.platform&&i.webToNative.setPrintSize(JSON.stringify({printSize:o,label:r}))}}},30:function(e,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.keepScreenNormal=t.keepScreenOn=void 0;var i=o(612);t.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())},t.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,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.addToSiri=void 0;var i=o(612);t.addToSiri=function(e){void 0===e&&(e={});var t=e.actionUrl,o=e.suggestedPhrase,a=e.title;["IOS_APP"].includes(i.platform)&&"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"addToSiri",data:{actionUrl:t,suggestedPhrase:o,title:a}})}},832:function(e,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.login=void 0;var i=o(612);t.login=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var t=e.callback,o=e.scope;(0,i.registerCb)((function(e){"appleLoginToken"===e.type&&t&&t(e)})),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"appleSignIn",scope:o})}}},716:function(e,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.logout=t.login=void 0;var i=o(612);t.login=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var t=e.callback,o=e.scope;(0,i.registerCb)((function(e){"fbLoginToken"===e.type&&t&&t(e)})),"ANDROID_APP"===i.platform&&i.webToNative.loginWithFacebook(),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"fbSignIn",scope:o})}},t.logout=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var t=e.callback,o=e.scope;(0,i.registerCb)((function(e){"fbLogOut"===e.type&&t&&t(e)})),"ANDROID_APP"===i.platform&&i.webToNative.logoutWithFacebook(),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"fbSignOut",scope:o})}}},288:function(e,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.logout=t.login=void 0;var i=o(612);t.login=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var t=e.callback,o=e.scope;(0,i.registerCb)((function(e){"googleLoginToken"===e.type&&t&&t(e)})),"ANDROID_APP"===i.platform&&i.webToNative.signInWithGoogle(),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"googleSignIn",scope:o})}},t.logout=function(e){if(["ANDROID_APP","IOS_APP"].includes(i.platform)){var t=e.callback,o=e.scope;(0,i.registerCb)((function(e){"googleLogOut"===e.type&&t&&t(e)})),"ANDROID_APP"===i.platform&&i.webToNative.signOutWithGoogle(),"IOS_APP"===i.platform&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"googleSignOut",scope:o})}}},699:function(e,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.socialLogin=void 0;var i=o(716),a=o(832),r=o(288);t.socialLogin={facebook:{login:i.login,logout:i.logout},google:{login:r.login,logout:r.logout},apple:{login:a.login}}},157:function(e,t,o){var i=this&&this.__assign||function(){return i=Object.assign||function(e){for(var t,o=1,i=arguments.length;o<i;o++)for(var a in t=arguments[o])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e},i.apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.makeTapToPay=void 0;var a=o(612);t.makeTapToPay=function(e){if(["ANDROID_APP","IOS_APP"].includes(a.platform)){var t=e.callback,o=e.apiUrl,r=void 0===o?null:o,n=e.amount,s=e.currency,c=e.isSimulated,l=void 0!==c&&c,p=e.captureMethod,u=void 0===p?"automatic":p,P=e.connectionToken,f=e.stripeLocationId,d=e.clientSecret,v=void 0===d?null:d;(0,a.registerCb)((function(e){"makeTapToPayStripePayment"===e.type&&t&&t(e)}));var A={secretToken:P,amount:n,currency:s,isSimulated:l,captureMethod:u,locationId:f};if(r&&(A.apiUrl=r),v&&(A.client_secret=v),"ANDROID_APP"===a.platform&&a.webToNative.makeTapToPayStripePayment(JSON.stringify(A)),"IOS_APP"===a.platform&&a.webToNativeIos){var b=i({action:"makeTapToPayStripePayment"},A);a.webToNativeIos.postMessage(b)}}}},781:function(e,t,o){var i=this;Object.defineProperty(t,"__esModule",{value:!0});var a=o(612),r=null;t.default=function(e){void 0===e&&(e={});var t=e.onVoiceSearch;return(0,a.registerCb)((function(e){var t=e,o=t.type,i=t.results;"VOICE_SEARCH_RESULT"===o&&(r&&r(i),r=null)})),a.isNativeApp&&a.webToNative.openVoiceSearch(),"function"==typeof t&&(r=t),i}},768:function(e,t,o){var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var a=o(612),r=i(o(333));t.default=function(e){if(["ANDROID_APP","IOS_APP"].includes(a.platform)){var t=e.onBarcodeSearch,o=e.format;(0,a.registerCb)((function(e){var o=e.type,i=e.value;"BARCODE_SCAN"===o&&t&&t(i)})),"ANDROID_APP"===a.platform&&a.webToNative.startScanner&&a.webToNative.startScanner(JSON.stringify({formats:o?[o]:[]})),"IOS_APP"===a.platform&&a.webToNativeIos&&a.webToNativeIos.postMessage({action:"barcodeScan",barcodeFormat:String(o||r.default.ALL_FORMATS)})}}},333:function(e,t){var o;Object.defineProperty(t,"__esModule",{value:!0}),t.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"}(o=t.BarcodeFormat||(t.BarcodeFormat={})),t.default=o},706:function(e,t,o){var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.BarcodeScan=t.Types=t.Format=void 0;var a=i(o(333));t.Format=a.default;var r=i(o(408));t.Types=r.default;var n=i(o(768));t.BarcodeScan=n.default},408:function(e,t){var o;Object.defineProperty(t,"__esModule",{value:!0}),t.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"}(o=t.BarcodeType||(t.BarcodeType={})),t.default=o},56:function(e,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.showInAppReview=t.deviceInfo=t.customFileDownload=t.downloadBlobFile=t.downloadFile=t.statusBar=t.hideSplashScreen=t.isIosApp=t.isAndroidApp=void 0;var i=o(612);t.isAndroidApp="ANDROID_APP"===i.platform,t.isIosApp="IOS_APP"===i.platform,t.hideSplashScreen=function(){i.isNativeApp&&i.webToNative.hideSplashScreen&&i.webToNative.hideSplashScreen()},t.statusBar=function(e){i.isNativeApp&&(t.isAndroidApp?i.webToNative.statusBar&&i.webToNative.statusBar(JSON.stringify(e)):t.isIosApp&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"statusBar",color:e.color,style:e.style}))},t.downloadFile=function(e){i.isNativeApp&&(t.isAndroidApp||t.isIosApp&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"downloadFile",downloadUrl:e}))},t.downloadBlobFile=function(e){var o=e.fileName,a=e.downloadUrl;["IOS_APP"].includes(i.platform)&&t.isIosApp&&i.webToNativeIos&&i.webToNativeIos.postMessage({action:"downloadBlobFile",fileName:o,url:a})},t.customFileDownload=function(e){var t=e.downloadUrl,o=e.fileName,a=e.isBlob,r=e.mimeType,n=e.cookies,s=e.userAgent,c=e.openFileAfterDownload;["ANDROID_APP"].includes(i.platform)&&"ANDROID_APP"===i.platform&&i.webToNative.downloadFile&&i.webToNative.downloadFile(JSON.stringify({url:t,fileName:o,isBlob:a,mimeType:r,cookies:n,userAgent:s,openFileAfterDownload:c}))},t.deviceInfo=function(){return new Promise((function(e,t){(0,i.registerCb)((function(o){o?e(o):t({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"}):t("This function will work in Native App Powered By WebToNative")}))},t.showInAppReview=function(){i.isNativeApp&&i.webToNative.showInAppReview&&i.webToNative.showInAppReview()}},612:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.deRegisterCbByKey=t.deRegisterForAbMobCb=t.registerForAbMobCb=t.registerCb=t.isNativeApp=t.platform=t.webToNativeIos=t.isClient=t.webToNative=void 0;var o="undefined"!=typeof window;t.isClient=o;var i=o&&window.WebToNativeInterface||{};t.webToNative=i;var a=o&&window.webkit&&window.webkit.messageHandlers&&window.webkit.messageHandlers.webToNativeInterface;t.webToNativeIos=a;var r=i.getAndroidVersion?"ANDROID_APP":a?"IOS_APP":"WEBSITE";t.platform=r;var n=o&&"WEBSITE"!==r;t.isNativeApp=n;var s={},c=1,l=null;n&&(i.androidCBHook=function(e){var t=e;try{t=JSON.parse(e)}catch(e){console.log(e)}for(var o in t.type,s){var i=s[o],a=i.cb,r=i.ignoreDelete,n=void 0!==r&&r;t&&t.reqType?o==t.reqType&&(a(t),n||delete s[o]):(a(t),n||delete s[o])}},window.iOSAdMobCBHook=i.androidAdMobCBHook=function(e){var t=JSON.parse(e);l&&l(t)},window.iosCBHook=function(e){var t=e;try{t=JSON.parse(e)}catch(e){console.log(e)}for(var o in s){var i=s[o],a=i.cb,r=i.ignoreDelete,n=void 0!==r&&r;t&&t.reqType?o==t.reqType&&(a(t),n||delete s[o]):(a(t),n||delete s[o])}}),t.registerCb=function(e,t){"function"==typeof e&&(t&&t.key?s[t.key]={cb:e,ignoreDelete:!!t.ignoreDelete}:(s[c]={cb:e,ignoreDelete:!(!t||!t.ignoreDelete)},c+=1))},t.registerForAbMobCb=function(e){"function"==typeof e&&(l=e)},t.deRegisterForAbMobCb=function(){l&&(l=null)},t.deRegisterCbByKey=function(e){delete s[e]}}},t={};!function o(i){var a=t[i];if(void 0!==a)return a.exports;var r=t[i]={exports:{}};return e[i].call(r.exports,r,r.exports,o),r.exports}(433)}();
|
package/buildScript.ts
ADDED
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
const fs = require("fs");
|
|
2
|
+
import path from "path";
|
|
3
|
+
|
|
4
|
+
// Copy README.md to build folder
|
|
5
|
+
fs.copyFileSync("README.md", "build/README.md");
|
|
6
|
+
|
|
7
|
+
// Read package.json, remove private flag, and write to build folder
|
|
8
|
+
const packageJson = JSON.parse(fs.readFileSync("package.json", "utf8"));
|
|
9
|
+
delete packageJson.private;
|
|
10
|
+
|
|
11
|
+
const buildPath = path.resolve("build");
|
|
12
|
+
|
|
13
|
+
const exportsMap = {
|
|
14
|
+
".": {
|
|
15
|
+
import: "./build/index.js",
|
|
16
|
+
types: "./build/index.d.ts",
|
|
17
|
+
},
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
const entries = fs.readdirSync(buildPath, { withFileTypes: true });
|
|
21
|
+
|
|
22
|
+
for (const entry of entries) {
|
|
23
|
+
if (entry.isDirectory()) {
|
|
24
|
+
const name = entry.name;
|
|
25
|
+
exportsMap[`./${name}`] = {
|
|
26
|
+
import: `./build/${name}/index.js`,
|
|
27
|
+
types: `./build/${name}/index.d.ts`,
|
|
28
|
+
};
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
packageJson.exports = exportsMap;
|
|
33
|
+
|
|
34
|
+
// Write the modified package.json to build folder
|
|
35
|
+
fs.writeFileSync("build/package.json", JSON.stringify(packageJson, null, 4));
|
package/client.ts
ADDED
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
import * as webToNative from "./src/index";
|
|
2
|
+
import * as OneSignal from "./src/OneSignal";
|
|
3
|
+
import VoiceSearch from "./src/VoiceSearch";
|
|
4
|
+
import * as Barcode from "./src/barcode";
|
|
5
|
+
import * as AdMob from "./src/AdMob";
|
|
6
|
+
import { socialLogin } from "./src/SocialLogin/index";
|
|
7
|
+
import * as AppsFlyer from "./src/AppsFlyer";
|
|
8
|
+
import { inAppPurchase, getAllPurchases, getReceiptData } from "./src/InAppPurchase";
|
|
9
|
+
import * as FBEvents from "./src/Facebook/events";
|
|
10
|
+
import * as BottomNavigation from "./src/BottomNavigation";
|
|
11
|
+
import * as contacts from "./src/NativeContacts";
|
|
12
|
+
import * as backgroundLocation from "./src/BackgroundLocation";
|
|
13
|
+
import * as screen from "./src/Screen";
|
|
14
|
+
import * as clipboard from "./src/Clipboard";
|
|
15
|
+
import * as appReview from "./src/AppReview";
|
|
16
|
+
import * as Biometric from "./src/Biometric";
|
|
17
|
+
import * as ATTConsent from "./src/ATTConsent";
|
|
18
|
+
import * as FirebaseAnalytics from "./src/FirebaseAnalytics";
|
|
19
|
+
import * as Firebase from "./src/Firebase";
|
|
20
|
+
import * as Haptics from "./src/Haptics";
|
|
21
|
+
import * as MediaPlayer from "./src/MediaPlayer";
|
|
22
|
+
import * as Printing from "./src/Printing";
|
|
23
|
+
import * as Notification from "./src/Notification";
|
|
24
|
+
import * as Bluetooth from "./src/Bluetooth";
|
|
25
|
+
import * as Stripe from "./src/Stripe";
|
|
26
|
+
import * as InAppUpdate from "./src/InAppUpdate";
|
|
27
|
+
import * as Siri from "./src/Siri";
|
|
28
|
+
import * as Beacon from "./src/Beacon";
|
|
29
|
+
import { webToNativeIos } from "./src/utills";
|
|
30
|
+
|
|
31
|
+
// Define the window interface to add WTN property
|
|
32
|
+
declare global {
|
|
33
|
+
interface Window {
|
|
34
|
+
WTN: typeof webToNative & {
|
|
35
|
+
OneSignal: typeof OneSignal;
|
|
36
|
+
VoiceSearch: typeof VoiceSearch;
|
|
37
|
+
Barcode: typeof Barcode;
|
|
38
|
+
AdMob: typeof AdMob;
|
|
39
|
+
socialLogin: typeof socialLogin;
|
|
40
|
+
inAppPurchase: typeof inAppPurchase;
|
|
41
|
+
getAllPurchases: typeof getAllPurchases;
|
|
42
|
+
getReceiptData: typeof getReceiptData;
|
|
43
|
+
appsflyer: typeof AppsFlyer;
|
|
44
|
+
bottomNavigation: typeof BottomNavigation;
|
|
45
|
+
contacts: typeof contacts;
|
|
46
|
+
screen: typeof screen;
|
|
47
|
+
backgroundLocation: typeof backgroundLocation;
|
|
48
|
+
clipboard: typeof clipboard;
|
|
49
|
+
appReview: typeof appReview;
|
|
50
|
+
Biometric: typeof Biometric;
|
|
51
|
+
ATTConsent: typeof ATTConsent;
|
|
52
|
+
facebook: {
|
|
53
|
+
events: typeof FBEvents;
|
|
54
|
+
};
|
|
55
|
+
FirebaseAnalytics: typeof FirebaseAnalytics;
|
|
56
|
+
Firebase: typeof Firebase;
|
|
57
|
+
Haptics: typeof Haptics;
|
|
58
|
+
MediaPlayer: typeof MediaPlayer;
|
|
59
|
+
Printing: typeof Printing;
|
|
60
|
+
Notification: typeof Notification;
|
|
61
|
+
Bluetooth: typeof Bluetooth;
|
|
62
|
+
Stripe: typeof Stripe;
|
|
63
|
+
InAppUpdate: typeof InAppUpdate;
|
|
64
|
+
Siri: typeof Siri;
|
|
65
|
+
Beacon: typeof Beacon;
|
|
66
|
+
};
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
// Assign to window.WTN
|
|
71
|
+
window.WTN = webToNative as any;
|
|
72
|
+
|
|
73
|
+
window.WTN.OneSignal = OneSignal;
|
|
74
|
+
window.WTN.VoiceSearch = VoiceSearch;
|
|
75
|
+
window.WTN.Barcode = Barcode;
|
|
76
|
+
window.WTN.AdMob = AdMob;
|
|
77
|
+
window.WTN.socialLogin = socialLogin;
|
|
78
|
+
window.WTN.inAppPurchase = inAppPurchase;
|
|
79
|
+
window.WTN.getAllPurchases = getAllPurchases;
|
|
80
|
+
window.WTN.getReceiptData = getReceiptData;
|
|
81
|
+
window.WTN.appsflyer = AppsFlyer;
|
|
82
|
+
window.WTN.bottomNavigation = BottomNavigation;
|
|
83
|
+
window.WTN.contacts = contacts;
|
|
84
|
+
window.WTN.screen = screen;
|
|
85
|
+
window.WTN.backgroundLocation = backgroundLocation;
|
|
86
|
+
window.WTN.clipboard = clipboard;
|
|
87
|
+
window.WTN.appReview = appReview;
|
|
88
|
+
window.WTN.Biometric = Biometric;
|
|
89
|
+
window.WTN.ATTConsent = ATTConsent;
|
|
90
|
+
window.WTN.facebook = {
|
|
91
|
+
events: FBEvents,
|
|
92
|
+
};
|
|
93
|
+
window.WTN.FirebaseAnalytics = FirebaseAnalytics;
|
|
94
|
+
window.WTN.Firebase = Firebase;
|
|
95
|
+
window.WTN.Haptics = Haptics;
|
|
96
|
+
window.WTN.MediaPlayer = MediaPlayer;
|
|
97
|
+
window.WTN.Printing = Printing;
|
|
98
|
+
window.WTN.Notification = Notification;
|
|
99
|
+
window.WTN.Bluetooth = Bluetooth;
|
|
100
|
+
window.WTN.Stripe = Stripe;
|
|
101
|
+
window.WTN.InAppUpdate = InAppUpdate;
|
|
102
|
+
window.WTN.Siri = Siri;
|
|
103
|
+
window.WTN.Beacon = Beacon;
|
|
104
|
+
|
|
105
|
+
// Export the WTN object as default
|
|
106
|
+
export default window.WTN;
|
package/index.d.ts
ADDED
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
// Type definitions for webtonative
|
|
2
|
+
|
|
3
|
+
import { Platform, StatusBarOptions, DownloadBlobFileOptions, CustomFileDownloadOptions } from './src/types';
|
|
4
|
+
|
|
5
|
+
// Export platform constants
|
|
6
|
+
export const isAndroidApp: boolean;
|
|
7
|
+
export const isIosApp: boolean;
|
|
8
|
+
|
|
9
|
+
// Export core functions
|
|
10
|
+
export function hideSplashScreen(): void;
|
|
11
|
+
export function statusBar(options: StatusBarOptions): void;
|
|
12
|
+
export function downloadFile(downloadUrl: string): void;
|
|
13
|
+
export function downloadBlobFile(options: DownloadBlobFileOptions): void;
|
|
14
|
+
export function customFileDownload(options: CustomFileDownloadOptions): void;
|
|
15
|
+
export function deviceInfo(): Promise<any>;
|
|
16
|
+
export function showInAppReview(): void;
|
|
17
|
+
|
|
18
|
+
// Barcode module
|
|
19
|
+
export namespace Barcode {
|
|
20
|
+
enum Format {
|
|
21
|
+
ALL_FORMATS = 0,
|
|
22
|
+
CODE_128 = 1,
|
|
23
|
+
CODE_39 = 2,
|
|
24
|
+
CODE_93 = 4,
|
|
25
|
+
CODABAR = 8,
|
|
26
|
+
DATA_MATRIX = 16,
|
|
27
|
+
EAN_13 = 32,
|
|
28
|
+
EAN_8 = 64,
|
|
29
|
+
ITF = 128,
|
|
30
|
+
QR_CODE = 256,
|
|
31
|
+
UPC_A = 512,
|
|
32
|
+
UPC_E = 1024,
|
|
33
|
+
PDF417 = 2048,
|
|
34
|
+
AZTEC = 4096
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
enum Types {
|
|
38
|
+
QR_CODE = 'QR_CODE',
|
|
39
|
+
DATA_MATRIX = 'DATA_MATRIX',
|
|
40
|
+
UPC_E = 'UPC_E',
|
|
41
|
+
UPC_A = 'UPC_A',
|
|
42
|
+
EAN_8 = 'EAN_8',
|
|
43
|
+
EAN_13 = 'EAN_13',
|
|
44
|
+
CODE_128 = 'CODE_128',
|
|
45
|
+
CODE_39 = 'CODE_39',
|
|
46
|
+
CODE_93 = 'CODE_93',
|
|
47
|
+
CODABAR = 'CODABAR',
|
|
48
|
+
ITF = 'ITF',
|
|
49
|
+
AZTEC = 'AZTEC',
|
|
50
|
+
PDF_417 = 'PDF_417'
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
interface BarcodeScanOptions {
|
|
54
|
+
onBarcodeSearch?: (value: string) => void;
|
|
55
|
+
format?: number;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
function BarcodeScan(options: BarcodeScanOptions): void;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
// Define the main module
|
|
62
|
+
declare module 'webtonative' {
|
|
63
|
+
export * from './src/index';
|
|
64
|
+
export default function webtonative(): typeof import('./src/index');
|
|
65
|
+
}
|