react-native-google-mobile-ads 8.1.0 → 8.1.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/android/src/main/java/io/invertase/googlemobileads/ReactNativeGoogleMobileAdsAdHelper.kt +17 -42
- package/ios_config.sh +3 -3
- package/lib/commonjs/AdEventType.js +1 -4
- package/lib/commonjs/AdEventType.js.map +1 -1
- package/lib/commonjs/AdsConsent.js +2 -25
- package/lib/commonjs/AdsConsent.js.map +1 -1
- package/lib/commonjs/AdsConsentDebugGeography.js +0 -3
- package/lib/commonjs/AdsConsentDebugGeography.js.map +1 -1
- package/lib/commonjs/AdsConsentPurposes.js +1 -4
- package/lib/commonjs/AdsConsentPurposes.js.map +1 -1
- package/lib/commonjs/AdsConsentSpecialFeatures.js +1 -4
- package/lib/commonjs/AdsConsentSpecialFeatures.js.map +1 -1
- package/lib/commonjs/AdsConsentStatus.js +0 -3
- package/lib/commonjs/AdsConsentStatus.js.map +1 -1
- package/lib/commonjs/BannerAdSize.js +1 -4
- package/lib/commonjs/BannerAdSize.js.map +1 -1
- package/lib/commonjs/GAMAdEventType.js +1 -4
- package/lib/commonjs/GAMAdEventType.js.map +1 -1
- package/lib/commonjs/MaxAdContentRating.js +1 -4
- package/lib/commonjs/MaxAdContentRating.js.map +1 -1
- package/lib/commonjs/MobileAds.js +0 -14
- package/lib/commonjs/MobileAds.js.map +1 -1
- package/lib/commonjs/RewardedAdEventType.js +1 -4
- package/lib/commonjs/RewardedAdEventType.js.map +1 -1
- package/lib/commonjs/TestIds.js +1 -2
- package/lib/commonjs/TestIds.js.map +1 -1
- package/lib/commonjs/ads/AppOpenAd.js +0 -14
- package/lib/commonjs/ads/AppOpenAd.js.map +1 -1
- package/lib/commonjs/ads/BannerAd.js +1 -6
- package/lib/commonjs/ads/BannerAd.js.map +1 -1
- package/lib/commonjs/ads/BaseAd.js +1 -20
- package/lib/commonjs/ads/BaseAd.js.map +1 -1
- package/lib/commonjs/ads/GAMBannerAd.js +1 -14
- package/lib/commonjs/ads/GAMBannerAd.js.map +1 -1
- package/lib/commonjs/ads/GAMInterstitialAd.js +0 -6
- package/lib/commonjs/ads/GAMInterstitialAd.js.map +1 -1
- package/lib/commonjs/ads/InterstitialAd.js +0 -14
- package/lib/commonjs/ads/InterstitialAd.js.map +1 -1
- package/lib/commonjs/ads/MobileAd.js +2 -55
- package/lib/commonjs/ads/MobileAd.js.map +1 -1
- package/lib/commonjs/ads/RewardedAd.js +0 -16
- package/lib/commonjs/ads/RewardedAd.js.map +1 -1
- package/lib/commonjs/ads/RewardedInterstitialAd.js +0 -16
- package/lib/commonjs/ads/RewardedInterstitialAd.js.map +1 -1
- package/lib/commonjs/common/Base64.js +4 -23
- package/lib/commonjs/common/Base64.js.map +1 -1
- package/lib/commonjs/common/MutatableParams.js +2 -12
- package/lib/commonjs/common/MutatableParams.js.map +1 -1
- package/lib/commonjs/common/ReferenceBase.js +2 -10
- package/lib/commonjs/common/ReferenceBase.js.map +1 -1
- package/lib/commonjs/common/deeps.js +1 -17
- package/lib/commonjs/common/deeps.js.map +1 -1
- package/lib/commonjs/common/id.js +7 -17
- package/lib/commonjs/common/id.js.map +1 -1
- package/lib/commonjs/common/index.js +2 -34
- package/lib/commonjs/common/index.js.map +1 -1
- package/lib/commonjs/common/path.js +9 -28
- package/lib/commonjs/common/path.js.map +1 -1
- package/lib/commonjs/common/promise.js +1 -7
- package/lib/commonjs/common/promise.js.map +1 -1
- package/lib/commonjs/common/serialize.js +4 -8
- package/lib/commonjs/common/serialize.js.map +1 -1
- package/lib/commonjs/common/validate.js +17 -44
- package/lib/commonjs/common/validate.js.map +1 -1
- package/lib/commonjs/declarations.d.js.map +1 -1
- package/lib/commonjs/hooks/useAppOpenAd.js +0 -6
- package/lib/commonjs/hooks/useAppOpenAd.js.map +1 -1
- package/lib/commonjs/hooks/useFullScreenAd.js +5 -16
- package/lib/commonjs/hooks/useFullScreenAd.js.map +1 -1
- package/lib/commonjs/hooks/useInterstitialAd.js +0 -6
- package/lib/commonjs/hooks/useInterstitialAd.js.map +1 -1
- package/lib/commonjs/hooks/useRewardedAd.js +0 -6
- package/lib/commonjs/hooks/useRewardedAd.js.map +1 -1
- package/lib/commonjs/hooks/useRewardedInterstitialAd.js +0 -6
- package/lib/commonjs/hooks/useRewardedInterstitialAd.js.map +1 -1
- package/lib/commonjs/index.js +1 -29
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/internal/GoogleMobileAdsNativeEventEmitter.js +8 -20
- package/lib/commonjs/internal/GoogleMobileAdsNativeEventEmitter.js.map +1 -1
- package/lib/commonjs/internal/Module.js +2 -18
- package/lib/commonjs/internal/Module.js.map +1 -1
- package/lib/commonjs/internal/NativeError.js +2 -13
- package/lib/commonjs/internal/NativeError.js.map +1 -1
- package/lib/commonjs/internal/SharedEventEmitter.js +2 -3
- package/lib/commonjs/internal/SharedEventEmitter.js.map +1 -1
- package/lib/commonjs/internal/constants.js +1 -1
- package/lib/commonjs/internal/constants.js.map +1 -1
- package/lib/commonjs/internal/index.js +0 -5
- package/lib/commonjs/internal/index.js.map +1 -1
- package/lib/commonjs/internal/registry/nativeModule.js +13 -44
- package/lib/commonjs/internal/registry/nativeModule.js.map +1 -1
- package/lib/commonjs/types/AdEventListener.js.map +1 -1
- package/lib/commonjs/types/AdEventsListener.js.map +1 -1
- package/lib/commonjs/types/AdShowOptions.js.map +1 -1
- package/lib/commonjs/types/AdStates.js.map +1 -1
- package/lib/commonjs/types/AdapterStatus.js +3 -6
- package/lib/commonjs/types/AdapterStatus.js.map +1 -1
- package/lib/commonjs/types/AdsConsent.interface.js.map +1 -1
- package/lib/commonjs/types/AppEvent.js.map +1 -1
- package/lib/commonjs/types/BannerAdProps.js.map +1 -1
- package/lib/commonjs/types/GoogleMobileAdsNativeModule.js.map +1 -1
- package/lib/commonjs/types/MobileAd.interface.js.map +1 -1
- package/lib/commonjs/types/MobileAdsModule.interface.js.map +1 -1
- package/lib/commonjs/types/Module.interface.js.map +1 -1
- package/lib/commonjs/types/RequestConfiguration.js.map +1 -1
- package/lib/commonjs/types/RequestOptions.js.map +1 -1
- package/lib/commonjs/types/RewardedAdReward.js.map +1 -1
- package/lib/commonjs/types/index.js +0 -22
- package/lib/commonjs/types/index.js.map +1 -1
- package/lib/commonjs/validateAdRequestConfiguration.js +1 -13
- package/lib/commonjs/validateAdRequestConfiguration.js.map +1 -1
- package/lib/commonjs/validateAdRequestOptions.js +1 -29
- package/lib/commonjs/validateAdRequestOptions.js.map +1 -1
- package/lib/commonjs/validateAdShowOptions.js +1 -7
- package/lib/commonjs/validateAdShowOptions.js.map +1 -1
- package/lib/commonjs/version.js +1 -1
- package/lib/commonjs/version.js.map +1 -1
- package/lib/module/AdEventType.js +1 -1
- package/lib/module/AdEventType.js.map +1 -1
- package/lib/module/AdsConsent.js +2 -18
- package/lib/module/AdsConsent.js.map +1 -1
- package/lib/module/AdsConsentDebugGeography.js +0 -1
- package/lib/module/AdsConsentDebugGeography.js.map +1 -1
- package/lib/module/AdsConsentPurposes.js +1 -1
- package/lib/module/AdsConsentPurposes.js.map +1 -1
- package/lib/module/AdsConsentSpecialFeatures.js +1 -1
- package/lib/module/AdsConsentSpecialFeatures.js.map +1 -1
- package/lib/module/AdsConsentStatus.js +0 -1
- package/lib/module/AdsConsentStatus.js.map +1 -1
- package/lib/module/BannerAdSize.js +1 -1
- package/lib/module/BannerAdSize.js.map +1 -1
- package/lib/module/GAMAdEventType.js +1 -1
- package/lib/module/GAMAdEventType.js.map +1 -1
- package/lib/module/MaxAdContentRating.js +1 -1
- package/lib/module/MaxAdContentRating.js.map +1 -1
- package/lib/module/MobileAds.js +0 -8
- package/lib/module/MobileAds.js.map +1 -1
- package/lib/module/RewardedAdEventType.js +1 -1
- package/lib/module/RewardedAdEventType.js.map +1 -1
- package/lib/module/TestIds.js +1 -0
- package/lib/module/TestIds.js.map +1 -1
- package/lib/module/ads/AppOpenAd.js +1 -8
- package/lib/module/ads/AppOpenAd.js.map +1 -1
- package/lib/module/ads/BannerAd.js +2 -2
- package/lib/module/ads/BannerAd.js.map +1 -1
- package/lib/module/ads/BaseAd.js +1 -9
- package/lib/module/ads/BaseAd.js.map +1 -1
- package/lib/module/ads/GAMBannerAd.js +2 -7
- package/lib/module/ads/GAMBannerAd.js.map +1 -1
- package/lib/module/ads/GAMInterstitialAd.js +0 -3
- package/lib/module/ads/GAMInterstitialAd.js.map +1 -1
- package/lib/module/ads/InterstitialAd.js +1 -9
- package/lib/module/ads/InterstitialAd.js.map +1 -1
- package/lib/module/ads/MobileAd.js +3 -47
- package/lib/module/ads/MobileAd.js.map +1 -1
- package/lib/module/ads/RewardedAd.js +1 -10
- package/lib/module/ads/RewardedAd.js.map +1 -1
- package/lib/module/ads/RewardedInterstitialAd.js +1 -10
- package/lib/module/ads/RewardedInterstitialAd.js.map +1 -1
- package/lib/module/common/Base64.js +4 -17
- package/lib/module/common/Base64.js.map +1 -1
- package/lib/module/common/MutatableParams.js +3 -9
- package/lib/module/common/MutatableParams.js.map +1 -1
- package/lib/module/common/ReferenceBase.js +2 -8
- package/lib/module/common/ReferenceBase.js.map +1 -1
- package/lib/module/common/deeps.js +3 -15
- package/lib/module/common/deeps.js.map +1 -1
- package/lib/module/common/id.js +7 -16
- package/lib/module/common/id.js.map +1 -1
- package/lib/module/common/index.js +2 -11
- package/lib/module/common/index.js.map +1 -1
- package/lib/module/common/path.js +9 -19
- package/lib/module/common/path.js.map +1 -1
- package/lib/module/common/promise.js +3 -5
- package/lib/module/common/promise.js.map +1 -1
- package/lib/module/common/serialize.js +4 -4
- package/lib/module/common/serialize.js.map +1 -1
- package/lib/module/common/validate.js +17 -24
- package/lib/module/common/validate.js.map +1 -1
- package/lib/module/declarations.d.js.map +1 -1
- package/lib/module/hooks/useAppOpenAd.js +2 -1
- package/lib/module/hooks/useAppOpenAd.js.map +1 -1
- package/lib/module/hooks/useFullScreenAd.js +5 -11
- package/lib/module/hooks/useFullScreenAd.js.map +1 -1
- package/lib/module/hooks/useInterstitialAd.js +2 -1
- package/lib/module/hooks/useInterstitialAd.js.map +1 -1
- package/lib/module/hooks/useRewardedAd.js +2 -1
- package/lib/module/hooks/useRewardedAd.js.map +1 -1
- package/lib/module/hooks/useRewardedInterstitialAd.js +2 -1
- package/lib/module/hooks/useRewardedInterstitialAd.js.map +1 -1
- package/lib/module/index.js +3 -1
- package/lib/module/index.js.map +1 -1
- package/lib/module/internal/GoogleMobileAdsNativeEventEmitter.js +9 -18
- package/lib/module/internal/GoogleMobileAdsNativeEventEmitter.js.map +1 -1
- package/lib/module/internal/Module.js +3 -13
- package/lib/module/internal/Module.js.map +1 -1
- package/lib/module/internal/NativeError.js +2 -11
- package/lib/module/internal/NativeError.js.map +1 -1
- package/lib/module/internal/SharedEventEmitter.js +1 -0
- package/lib/module/internal/SharedEventEmitter.js.map +1 -1
- package/lib/module/internal/constants.js +1 -0
- package/lib/module/internal/constants.js.map +1 -1
- package/lib/module/internal/index.js +1 -0
- package/lib/module/internal/index.js.map +1 -1
- package/lib/module/internal/registry/nativeModule.js +13 -35
- package/lib/module/internal/registry/nativeModule.js.map +1 -1
- package/lib/module/types/AdEventListener.js.map +1 -1
- package/lib/module/types/AdEventsListener.js.map +1 -1
- package/lib/module/types/AdShowOptions.js.map +1 -1
- package/lib/module/types/AdStates.js.map +1 -1
- package/lib/module/types/AdapterStatus.js +1 -1
- package/lib/module/types/AdapterStatus.js.map +1 -1
- package/lib/module/types/AdsConsent.interface.js.map +1 -1
- package/lib/module/types/AppEvent.js.map +1 -1
- package/lib/module/types/BannerAdProps.js.map +1 -1
- package/lib/module/types/GoogleMobileAdsNativeModule.js.map +1 -1
- package/lib/module/types/MobileAd.interface.js.map +1 -1
- package/lib/module/types/MobileAdsModule.interface.js.map +1 -1
- package/lib/module/types/Module.interface.js.map +1 -1
- package/lib/module/types/RequestConfiguration.js.map +1 -1
- package/lib/module/types/RequestOptions.js.map +1 -1
- package/lib/module/types/RewardedAdReward.js.map +1 -1
- package/lib/module/types/index.js +1 -0
- package/lib/module/types/index.js.map +1 -1
- package/lib/module/validateAdRequestConfiguration.js +1 -10
- package/lib/module/validateAdRequestConfiguration.js.map +1 -1
- package/lib/module/validateAdRequestOptions.js +1 -27
- package/lib/module/validateAdRequestOptions.js.map +1 -1
- package/lib/module/validateAdShowOptions.js +1 -5
- package/lib/module/validateAdShowOptions.js.map +1 -1
- package/lib/module/version.js +1 -1
- package/lib/module/version.js.map +1 -1
- package/lib/typescript/common/Base64.d.ts +0 -1
- package/lib/typescript/index.d.ts +1 -1
- package/lib/typescript/version.d.ts +1 -1
- package/package.json +35 -29
- package/src/internal/registry/nativeModule.ts +2 -0
- package/src/version.ts +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"names":["MutatableParams","constructor","parentInstance","_mutatableParams","_parentInstance","set","param","value","deepSet","get","deepGet","toJSON","Object","assign","validate"],"sources":["MutatableParams.ts"],"sourcesContent":["/*\n * Copyright (c) 2016-present Invertase Limited & Contributors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this library except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n *\n */\n\nimport { deepGet, deepSet } from './deeps';\n\nexport class MutatableParams {\n _mutatableParams: Record<string, unknown>;\n _parentInstance: MutatableParams;\n\n constructor(parentInstance: MutatableParams) {\n if (parentInstance) {\n this._mutatableParams = parentInstance._mutatableParams;\n this._parentInstance = parentInstance;\n } else {\n this._mutatableParams = {};\n this._parentInstance = this;\n }\n }\n\n set(param: string, value: unknown) {\n deepSet(this._mutatableParams, param, value);\n return this._parentInstance;\n }\n\n get(param: string) {\n return deepGet(this._mutatableParams, param, '.');\n }\n\n toJSON() {\n return Object.assign({}, this._mutatableParams);\n }\n\n validate() {\n // do nothing\n }\n}\n"],"mappings":";;;;;;AAiBA;AAA2C;AAEpC,MAAMA,eAAe,CAAC;EAI3BC,WAAW,CAACC,cAA+B,EAAE;IAAA;IAAA;IAC3C,IAAIA,cAAc,EAAE;MAClB,IAAI,CAACC,gBAAgB,GAAGD,cAAc,CAACC,gBAAgB;MACvD,IAAI,CAACC,eAAe,GAAGF,cAAc;IACvC,CAAC,MAAM;MACL,IAAI,CAACC,gBAAgB,GAAG,CAAC,CAAC;MAC1B,IAAI,CAACC,eAAe,GAAG,IAAI;IAC7B;EACF;EAEAC,GAAG,CAACC,KAAa,EAAEC,KAAc,EAAE;IACjC,IAAAC,cAAO,EAAC,IAAI,CAACL,gBAAgB,EAAEG,KAAK,EAAEC,KAAK,CAAC;IAC5C,OAAO,IAAI,CAACH,eAAe;EAC7B;EAEAK,GAAG,CAACH,KAAa,EAAE;IACjB,OAAO,IAAAI,cAAO,EAAC,IAAI,CAACP,gBAAgB,EAAEG,KAAK,EAAE,GAAG,CAAC;EACnD;EAEAK,MAAM,GAAG;IACP,OAAOC,MAAM,CAACC,MAAM,CAAC,CAAC,CAAC,EAAE,IAAI,CAACV,gBAAgB,CAAC;EACjD;EAEAW,QAAQ,GAAG;IACT;EACF;AACF;AAAC"}
|
|
@@ -4,9 +4,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.ReferenceBase = void 0;
|
|
7
|
-
|
|
8
7
|
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
9
|
-
|
|
10
8
|
/*
|
|
11
9
|
* Copyright (c) 2016-present Invertase Limited & Contributors
|
|
12
10
|
*
|
|
@@ -23,37 +21,31 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
23
21
|
* limitations under the License.
|
|
24
22
|
*
|
|
25
23
|
*/
|
|
24
|
+
|
|
26
25
|
class ReferenceBase {
|
|
27
26
|
constructor(_path) {
|
|
28
27
|
_defineProperty(this, "path", void 0);
|
|
29
|
-
|
|
30
28
|
let path = _path;
|
|
31
|
-
|
|
32
29
|
if (path) {
|
|
33
30
|
path = path.length > 1 && path.endsWith('/') ? path.substring(0, path.length - 1) : path;
|
|
34
|
-
|
|
35
31
|
if (path.startsWith('/') && path.length > 1) {
|
|
36
32
|
path = path.substring(1, path.length);
|
|
37
33
|
}
|
|
38
34
|
} else {
|
|
39
35
|
path = '/';
|
|
40
36
|
}
|
|
41
|
-
|
|
42
37
|
this.path = path;
|
|
43
38
|
}
|
|
39
|
+
|
|
44
40
|
/**
|
|
45
41
|
* The last part of a Reference's path (after the last '/')
|
|
46
42
|
* The key of a root Reference is null.
|
|
47
43
|
* @type {String}
|
|
48
44
|
* {@link https://firebase.google.com/docs/reference/js/firebase.database.Reference#key}
|
|
49
45
|
*/
|
|
50
|
-
|
|
51
|
-
|
|
52
46
|
get key() {
|
|
53
47
|
return this.path === '/' ? null : this.path.substring(this.path.lastIndexOf('/') + 1);
|
|
54
48
|
}
|
|
55
|
-
|
|
56
49
|
}
|
|
57
|
-
|
|
58
50
|
exports.ReferenceBase = ReferenceBase;
|
|
59
51
|
//# sourceMappingURL=ReferenceBase.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"names":["ReferenceBase","constructor","_path","path","length","endsWith","substring","startsWith","key","lastIndexOf"],"sources":["ReferenceBase.ts"],"sourcesContent":["/*\n * Copyright (c) 2016-present Invertase Limited & Contributors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this library except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n *\n */\n\nexport class ReferenceBase {\n path: string;\n\n constructor(_path: string) {\n let path = _path;\n\n if (path) {\n path = path.length > 1 && path.endsWith('/') ? path.substring(0, path.length - 1) : path;\n if (path.startsWith('/') && path.length > 1) {\n path = path.substring(1, path.length);\n }\n } else {\n path = '/';\n }\n\n this.path = path;\n }\n\n /**\n * The last part of a Reference's path (after the last '/')\n * The key of a root Reference is null.\n * @type {String}\n * {@link https://firebase.google.com/docs/reference/js/firebase.database.Reference#key}\n */\n get key() {\n return this.path === '/' ? null : this.path.substring(this.path.lastIndexOf('/') + 1);\n }\n}\n"],"mappings":";;;;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEO,MAAMA,aAAa,CAAC;EAGzBC,WAAW,CAACC,KAAa,EAAE;IAAA;IACzB,IAAIC,IAAI,GAAGD,KAAK;IAEhB,IAAIC,IAAI,EAAE;MACRA,IAAI,GAAGA,IAAI,CAACC,MAAM,GAAG,CAAC,IAAID,IAAI,CAACE,QAAQ,CAAC,GAAG,CAAC,GAAGF,IAAI,CAACG,SAAS,CAAC,CAAC,EAAEH,IAAI,CAACC,MAAM,GAAG,CAAC,CAAC,GAAGD,IAAI;MACxF,IAAIA,IAAI,CAACI,UAAU,CAAC,GAAG,CAAC,IAAIJ,IAAI,CAACC,MAAM,GAAG,CAAC,EAAE;QAC3CD,IAAI,GAAGA,IAAI,CAACG,SAAS,CAAC,CAAC,EAAEH,IAAI,CAACC,MAAM,CAAC;MACvC;IACF,CAAC,MAAM;MACLD,IAAI,GAAG,GAAG;IACZ;IAEA,IAAI,CAACA,IAAI,GAAGA,IAAI;EAClB;;EAEA;AACF;AACA;AACA;AACA;AACA;EACE,IAAIK,GAAG,GAAG;IACR,OAAO,IAAI,CAACL,IAAI,KAAK,GAAG,GAAG,IAAI,GAAG,IAAI,CAACA,IAAI,CAACG,SAAS,CAAC,IAAI,CAACH,IAAI,CAACM,WAAW,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;EACvF;AACF;AAAC"}
|
|
@@ -5,9 +5,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.deepGet = deepGet;
|
|
7
7
|
exports.deepSet = deepSet;
|
|
8
|
-
|
|
9
8
|
var _validate = require("./validate");
|
|
10
|
-
|
|
11
9
|
/*
|
|
12
10
|
* Copyright (c) 2016-present Invertase Limited & Contributors
|
|
13
11
|
*
|
|
@@ -35,28 +33,23 @@ var _validate = require("./validate");
|
|
|
35
33
|
*/
|
|
36
34
|
function deepGet(object, path) {
|
|
37
35
|
let joiner = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : '/';
|
|
38
|
-
|
|
39
36
|
if (!(0, _validate.isObject)(object) && !Array.isArray(object)) {
|
|
40
37
|
return undefined;
|
|
41
38
|
}
|
|
42
|
-
|
|
43
39
|
const keys = path.split(joiner);
|
|
44
40
|
let i = 0;
|
|
45
41
|
let value;
|
|
46
42
|
const len = keys.length;
|
|
47
|
-
|
|
48
43
|
while (i < len) {
|
|
49
44
|
const key = keys[i++];
|
|
50
|
-
|
|
51
45
|
if (!object || !Object.hasOwnProperty.call(object, key)) {
|
|
52
46
|
return undefined;
|
|
53
47
|
}
|
|
54
|
-
|
|
55
48
|
value = object[key];
|
|
56
49
|
}
|
|
57
|
-
|
|
58
50
|
return value;
|
|
59
51
|
}
|
|
52
|
+
|
|
60
53
|
/**
|
|
61
54
|
* Deep set a value
|
|
62
55
|
* @param object
|
|
@@ -65,37 +58,28 @@ function deepGet(object, path) {
|
|
|
65
58
|
* @param initPaths
|
|
66
59
|
* @param joiner
|
|
67
60
|
*/
|
|
68
|
-
|
|
69
|
-
|
|
70
61
|
function deepSet(object, path, value) {
|
|
71
62
|
let initPaths = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : true;
|
|
72
63
|
let joiner = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : '.';
|
|
73
|
-
|
|
74
64
|
if (!(0, _validate.isObject)(object)) {
|
|
75
65
|
return false;
|
|
76
66
|
}
|
|
77
|
-
|
|
78
67
|
const keys = path.split(joiner);
|
|
79
68
|
let i = 0;
|
|
80
69
|
let _object = object;
|
|
81
70
|
const len = keys.length - 1;
|
|
82
|
-
|
|
83
71
|
while (i < len) {
|
|
84
72
|
const key = keys[i++];
|
|
85
|
-
|
|
86
73
|
if (initPaths && !Object.hasOwnProperty.call(object, key)) {
|
|
87
74
|
_object[key] = {};
|
|
88
75
|
}
|
|
89
|
-
|
|
90
76
|
_object = _object[key];
|
|
91
77
|
}
|
|
92
|
-
|
|
93
78
|
if ((0, _validate.isObject)(_object) || (0, _validate.isArray)(_object) && !Number.isNaN(keys[i])) {
|
|
94
79
|
_object[keys[i]] = value;
|
|
95
80
|
} else {
|
|
96
81
|
return false;
|
|
97
82
|
}
|
|
98
|
-
|
|
99
83
|
return true;
|
|
100
84
|
}
|
|
101
85
|
//# sourceMappingURL=deeps.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"names":["deepGet","object","path","joiner","isObject","Array","isArray","undefined","keys","split","i","value","len","length","key","Object","hasOwnProperty","call","deepSet","initPaths","_object","Number","isNaN"],"sources":["deeps.ts"],"sourcesContent":["/*\n * Copyright (c) 2016-present Invertase Limited & Contributors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this library except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n *\n */\n\nimport { isArray, isObject } from './validate';\n\n/**\n * Deep get a value from an object.\n * @website https://github.com/Salakar/deeps\n * @param object\n * @param path\n * @param joiner\n * @returns {*}\n */\nexport function deepGet(object: Record<string, unknown>, path: string, joiner = '/') {\n if (!isObject(object) && !Array.isArray(object)) {\n return undefined;\n }\n const keys = path.split(joiner);\n\n let i = 0;\n let value;\n const len = keys.length;\n\n while (i < len) {\n const key = keys[i++];\n if (!object || !Object.hasOwnProperty.call(object, key)) {\n return undefined;\n }\n value = object[key];\n }\n\n return value;\n}\n\n/**\n * Deep set a value\n * @param object\n * @param path\n * @param value\n * @param initPaths\n * @param joiner\n */\nexport function deepSet(\n object: Record<string, unknown>,\n path: string,\n value: unknown,\n initPaths = true,\n joiner = '.',\n) {\n if (!isObject(object)) {\n return false;\n }\n const keys = path.split(joiner);\n\n let i = 0;\n let _object = object;\n const len = keys.length - 1;\n\n while (i < len) {\n const key = keys[i++];\n if (initPaths && !Object.hasOwnProperty.call(object, key)) {\n _object[key] = {};\n }\n _object = _object[key] as Record<string, unknown>;\n }\n\n if (isObject(_object) || (isArray(_object) && !Number.isNaN(keys[i]))) {\n _object[keys[i]] = value;\n } else {\n return false;\n }\n\n return true;\n}\n"],"mappings":";;;;;;;AAiBA;AAjBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAIA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,SAASA,OAAO,CAACC,MAA+B,EAAEC,IAAY,EAAgB;EAAA,IAAdC,MAAM,uEAAG,GAAG;EACjF,IAAI,CAAC,IAAAC,kBAAQ,EAACH,MAAM,CAAC,IAAI,CAACI,KAAK,CAACC,OAAO,CAACL,MAAM,CAAC,EAAE;IAC/C,OAAOM,SAAS;EAClB;EACA,MAAMC,IAAI,GAAGN,IAAI,CAACO,KAAK,CAACN,MAAM,CAAC;EAE/B,IAAIO,CAAC,GAAG,CAAC;EACT,IAAIC,KAAK;EACT,MAAMC,GAAG,GAAGJ,IAAI,CAACK,MAAM;EAEvB,OAAOH,CAAC,GAAGE,GAAG,EAAE;IACd,MAAME,GAAG,GA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AK;EACd;EAEA,OAAO,IAAI;AACb"}
|
|
@@ -6,38 +6,36 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
exports.generateDatabaseId = generateDatabaseId;
|
|
7
7
|
exports.generateFirestoreId = generateFirestoreId;
|
|
8
8
|
const PUSH_CHARS = '-0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ_abcdefghijklmnopqrstuvwxyz';
|
|
9
|
-
const AUTO_ID_CHARS = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789';
|
|
9
|
+
const AUTO_ID_CHARS = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789';
|
|
10
10
|
|
|
11
|
-
|
|
11
|
+
// timestamp of last push, used to prevent local collisions if you push twice in one ms.
|
|
12
|
+
let lastPushTime = 0;
|
|
13
|
+
|
|
14
|
+
// we generate 72-bits of randomness which get turned into 12 characters and appended to the
|
|
12
15
|
// timestamp to prevent collisions with other clients. We store the last characters we
|
|
13
16
|
// generated because in the event of a collision, we'll use those same characters except
|
|
14
17
|
// "incremented" by one.
|
|
15
|
-
|
|
16
18
|
const lastRandChars = [];
|
|
19
|
+
|
|
17
20
|
/**
|
|
18
21
|
* Generate a firebase id - for use with ref().push(val, cb) - e.g. -KXMr7k2tXUFQqiaZRY4'
|
|
19
22
|
* @param serverTimeOffset - pass in server time offset from native side
|
|
20
23
|
* @returns {string}
|
|
21
24
|
*/
|
|
22
|
-
|
|
23
25
|
function generateDatabaseId() {
|
|
24
26
|
let serverTimeOffset = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0;
|
|
25
27
|
const timeStampChars = new Array(8);
|
|
26
28
|
let now = new Date().getTime() + serverTimeOffset;
|
|
27
29
|
const duplicateTime = now === lastPushTime;
|
|
28
30
|
lastPushTime = now;
|
|
29
|
-
|
|
30
31
|
for (let i = 7; i >= 0; i -= 1) {
|
|
31
32
|
timeStampChars[i] = PUSH_CHARS.charAt(now % 64);
|
|
32
33
|
now = Math.floor(now / 64);
|
|
33
34
|
}
|
|
34
|
-
|
|
35
35
|
if (now !== 0) {
|
|
36
36
|
throw new Error('We should have converted the entire timestamp.');
|
|
37
37
|
}
|
|
38
|
-
|
|
39
38
|
let id = timeStampChars.join('');
|
|
40
|
-
|
|
41
39
|
if (!duplicateTime) {
|
|
42
40
|
for (let i = 0; i < 12; i += 1) {
|
|
43
41
|
lastRandChars[i] = Math.floor(Math.random() * 64);
|
|
@@ -46,37 +44,29 @@ function generateDatabaseId() {
|
|
|
46
44
|
// if the timestamp hasn't changed since last push,
|
|
47
45
|
// use the same random number, but increment it by 1.
|
|
48
46
|
let i;
|
|
49
|
-
|
|
50
47
|
for (i = 11; i >= 0 && lastRandChars[i] === 63; i -= 1) {
|
|
51
48
|
lastRandChars[i] = 0;
|
|
52
49
|
}
|
|
53
|
-
|
|
54
50
|
lastRandChars[i] += 1;
|
|
55
51
|
}
|
|
56
|
-
|
|
57
52
|
for (let i = 0; i < 12; i++) {
|
|
58
53
|
id += PUSH_CHARS.charAt(lastRandChars[i]);
|
|
59
54
|
}
|
|
60
|
-
|
|
61
55
|
if (id.length !== 20) {
|
|
62
56
|
throw new Error('Length should be 20.');
|
|
63
57
|
}
|
|
64
|
-
|
|
65
58
|
return id;
|
|
66
59
|
}
|
|
60
|
+
|
|
67
61
|
/**
|
|
68
62
|
* Generate a firestore auto id for use with collection/document .add()
|
|
69
63
|
* @return {string}
|
|
70
64
|
*/
|
|
71
|
-
|
|
72
|
-
|
|
73
65
|
function generateFirestoreId() {
|
|
74
66
|
let autoId = '';
|
|
75
|
-
|
|
76
67
|
for (let i = 0; i < 20; i++) {
|
|
77
68
|
autoId += AUTO_ID_CHARS.charAt(Math.floor(Math.random() * AUTO_ID_CHARS.length));
|
|
78
69
|
}
|
|
79
|
-
|
|
80
70
|
return autoId;
|
|
81
71
|
}
|
|
82
72
|
//# sourceMappingURL=id.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"names":["PUSH_CHARS","AUTO_ID_CHARS","lastPushTime","lastRandChars","generateDatabaseId","serverTimeOffset","timeStampChars","Array","now","Date","getTime","duplicateTime","i","charAt","Math","floor","Error","id","join","random","length","generateFirestoreId","autoId"],"sources":["id.ts"],"sourcesContent":["const PUSH_CHARS = '-0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ_abcdefghijklmnopqrstuvwxyz';\n\nconst AUTO_ID_CHARS = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789';\n\n// timestamp of last push, used to prevent local collisions if you push twice in one ms.\nlet lastPushTime = 0;\n\n// we generate 72-bits of randomness which get turned into 12 characters and appended to the\n// timestamp to prevent collisions with other clients. We store the last characters we\n// generated because in the event of a collision, we'll use those same characters except\n// \"incremented\" by one.\nconst lastRandChars: number[] = [];\n\n/**\n * Generate a firebase id - for use with ref().push(val, cb) - e.g. -KXMr7k2tXUFQqiaZRY4'\n * @param serverTimeOffset - pass in server time offset from native side\n * @returns {string}\n */\nexport function generateDatabaseId(serverTimeOffset = 0) {\n const timeStampChars = new Array(8);\n let now = new Date().getTime() + serverTimeOffset;\n const duplicateTime = now === lastPushTime;\n\n lastPushTime = now;\n\n for (let i = 7; i >= 0; i -= 1) {\n timeStampChars[i] = PUSH_CHARS.charAt(now % 64);\n now = Math.floor(now / 64);\n }\n\n if (now !== 0) {\n throw new Error('We should have converted the entire timestamp.');\n }\n\n let id = timeStampChars.join('');\n\n if (!duplicateTime) {\n for (let i = 0; i < 12; i += 1) {\n lastRandChars[i] = Math.floor(Math.random() * 64);\n }\n } else {\n // if the timestamp hasn't changed since last push,\n // use the same random number, but increment it by 1.\n let i;\n for (i = 11; i >= 0 && lastRandChars[i] === 63; i -= 1) {\n lastRandChars[i] = 0;\n }\n\n lastRandChars[i] += 1;\n }\n\n for (let i = 0; i < 12; i++) {\n id += PUSH_CHARS.charAt(lastRandChars[i]);\n }\n\n if (id.length !== 20) {\n throw new Error('Length should be 20.');\n }\n\n return id;\n}\n\n/**\n * Generate a firestore auto id for use with collection/document .add()\n * @return {string}\n */\nexport function generateFirestoreId() {\n let autoId = '';\n\n for (let i = 0; i < 20; i++) {\n autoId += AUTO_ID_CHARS.charAt(Math.floor(Math.random() * AUTO_ID_CHARS.length));\n }\n return autoId;\n}\n"],"mappings":";;;;;;;AAAA,MAAMA,UAAU,GAAG,kEAAkE;AAErF,MAAMC,aAAa,GAAG,gEAAgE;;AAEtF;AACA,IAAIC,YAAY,GAAG,CAAC;;AAEpB;AACA;AACA;AACA;AACA,MAAMC,aAAuB,GAAG,EAAE;;AAElC;AACA;AACA;AACA;AACA;AACO,SAASC,kBAAkB,GAAuB;EAAA,IAAtBC,gBAAgB,uEAAG,CAAC;EACrD,MAAMC,cAAc,GAAG,IAAIC,KAAK,CAAC,CAAC,CAAC;EACnC,IAAIC,GAAG,GAAG,IAAIC,IAAI,EAAE,CAACC,OAAO,EAAE,GAAGL,gBAAgB;EACjD,MAAMM,aAAa,GAAGH,GAAG,KAAKN,YAAY;EAE1CA,YAAY,GAAGM,GAAG;EAElB,KAAK,IAAII,CAAC,GAAG,CAAC,EAAEA,CAAC,IAAI,CAAC,EAAEA,CAAC,IAAI,CAAC,EAAE;IAC9BN,cAAc,CAACM,CAAC,CAAC,GAAGZ,UAAU,CAACa,MAAM,CAACL,GAAG,GAAG,EAAE,CAAC;IAC/CA,GAAG,GAAGM,IAAI,CAACC,KAAK,CAACP,GAAG,GAAG,EAAE,CAAC;EAC5B;EAEA,IAAIA,GAAG,KAAK,CAAC,EAAE;IACb,MAAM,IAAIQ,KAAK,CAAC,gDAAgD,CAAC;EACnE;EAEA,IAAIC,EAAE,GAAGX,cAAc,CAACY,IAAI,CAAC,EAAE,CAAC;EAEhC,IAAI,CAACP,aAAa,EAAE;IAClB,KAAK,IAAIC,CAAC,GAAG,CAAC,EAAEA,CAAC,GAAG,EAAE,EAAEA,CAAC,IAAI,CAAC,EAAE;MAC9BT,aAAa,CAACS,CAAC,CAAC,GAAGE,IAAI,CAACC,KAAK,CAACD,IAAI,CAACK,MAAM,EAAE,GAAG,EAAE,CAAC;IACnD;EACF,CAAC,MAAM;IACL;IACA;IACA,IAAIP,CAAC;IACL,KAAKA,CAAC,GAAG,EAAE,EAAEA,CAAC,IAAI,CAAC,IAAIT,aAAa,CAACS,CAAC,CAAC,KAAK,EAAE,EAAEA,CAAC,IAAI,CAAC,EAAE;MACtDT,aAAa,CAACS,CAAC,CAAC,GAAG,CAAC;IACtB;IAEAT,aAAa,CAACS,CAAC,CAAC,IAAI,CAAC;EACvB;EAEA,KAAK,IAAIA,CAAC,GAAG,CAAC,EAAEA,CAAC,GAAG,EAAE,EAAEA,CAAC,EAAE,EAAE;IAC3BK,EAAE,IAAIjB,UAAU,CAACa,MAAM,CAACV,aAAa,CAACS,CAAC,CAAC,CAAC;EAC3C;EAEA,IAAIK,EAAE,CAACG,MAAM,KAAK,EAAE,EAAE;IACpB,MAAM,IAAIJ,KAAK,CAAC,sBAAsB,CAAC;EACzC;EAEA,OAAOC,EAAE;AACX;;AAEA;AACA;AACA;AACA;AACO,SAASI,mBAAmB,GAAG;EACpC,IAAIC,MAAM,GAAG,EAAE;EAEf,KAAK,IAAIV,CAAC,GAAG,CAAC,EAAEA,CAAC,GAAG,EAAE,EAAEA,CAAC,EAAE,EAAE;IAC3BU,MAAM,IAAIrB,aAAa,CAACY,MAAM,CAACC,IAAI,CAACC,KAAK,CAACD,IAAI,CAACK,MAAM,EAAE,GAAGlB,aAAa,CAACmB,MAAM,CAAC,CAAC;EAClF;EACA,OAAOE,MAAM;AACf"}
|
|
@@ -34,15 +34,10 @@ exports.once = once;
|
|
|
34
34
|
exports.stripTrailingSlash = stripTrailingSlash;
|
|
35
35
|
exports.tryJSONParse = tryJSONParse;
|
|
36
36
|
exports.tryJSONStringify = tryJSONStringify;
|
|
37
|
-
|
|
38
37
|
var _reactNative = require("react-native");
|
|
39
|
-
|
|
40
38
|
var Base64 = _interopRequireWildcard(require("./Base64"));
|
|
41
|
-
|
|
42
39
|
exports.Base64 = Base64;
|
|
43
|
-
|
|
44
40
|
var _validate = require("./validate");
|
|
45
|
-
|
|
46
41
|
Object.keys(_validate).forEach(function (key) {
|
|
47
42
|
if (key === "default" || key === "__esModule") return;
|
|
48
43
|
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
@@ -54,9 +49,7 @@ Object.keys(_validate).forEach(function (key) {
|
|
|
54
49
|
}
|
|
55
50
|
});
|
|
56
51
|
});
|
|
57
|
-
|
|
58
52
|
var _id = require("./id");
|
|
59
|
-
|
|
60
53
|
Object.keys(_id).forEach(function (key) {
|
|
61
54
|
if (key === "default" || key === "__esModule") return;
|
|
62
55
|
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
@@ -68,9 +61,7 @@ Object.keys(_id).forEach(function (key) {
|
|
|
68
61
|
}
|
|
69
62
|
});
|
|
70
63
|
});
|
|
71
|
-
|
|
72
64
|
var _path = require("./path");
|
|
73
|
-
|
|
74
65
|
Object.keys(_path).forEach(function (key) {
|
|
75
66
|
if (key === "default" || key === "__esModule") return;
|
|
76
67
|
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
@@ -82,9 +73,7 @@ Object.keys(_path).forEach(function (key) {
|
|
|
82
73
|
}
|
|
83
74
|
});
|
|
84
75
|
});
|
|
85
|
-
|
|
86
76
|
var _promise = require("./promise");
|
|
87
|
-
|
|
88
77
|
Object.keys(_promise).forEach(function (key) {
|
|
89
78
|
if (key === "default" || key === "__esModule") return;
|
|
90
79
|
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
@@ -96,13 +85,9 @@ Object.keys(_promise).forEach(function (key) {
|
|
|
96
85
|
}
|
|
97
86
|
});
|
|
98
87
|
});
|
|
99
|
-
|
|
100
88
|
var _ReferenceBase = require("./ReferenceBase");
|
|
101
|
-
|
|
102
89
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
103
|
-
|
|
104
90
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
105
|
-
|
|
106
91
|
/*
|
|
107
92
|
* Copyright (c) 2016-present Invertase Limited & Contributors
|
|
108
93
|
*
|
|
@@ -119,87 +104,71 @@ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj &&
|
|
|
119
104
|
* limitations under the License.
|
|
120
105
|
*
|
|
121
106
|
*/
|
|
107
|
+
|
|
122
108
|
function getDataUrlParts(dataUrlString) {
|
|
123
109
|
const isBase64 = dataUrlString.includes(';base64');
|
|
124
110
|
let [mediaType, base64String] = dataUrlString.split(',');
|
|
125
|
-
|
|
126
111
|
if (!mediaType || !base64String) {
|
|
127
112
|
return {
|
|
128
113
|
base64String: undefined,
|
|
129
114
|
mediaType: undefined
|
|
130
115
|
};
|
|
131
116
|
}
|
|
132
|
-
|
|
133
117
|
mediaType = mediaType.replace('data:', '').replace(';base64', '');
|
|
134
|
-
|
|
135
118
|
if (base64String && base64String.includes('%')) {
|
|
136
119
|
base64String = decodeURIComponent(base64String);
|
|
137
120
|
}
|
|
138
|
-
|
|
139
121
|
if (!isBase64) {
|
|
140
122
|
base64String = Base64.btoa(base64String);
|
|
141
123
|
}
|
|
142
|
-
|
|
143
124
|
return {
|
|
144
125
|
base64String,
|
|
145
126
|
mediaType
|
|
146
127
|
};
|
|
147
128
|
}
|
|
148
|
-
|
|
149
129
|
function once(fn, context) {
|
|
150
130
|
let onceResult;
|
|
151
131
|
let ranOnce = false;
|
|
152
132
|
return function onceInner() {
|
|
153
133
|
if (!ranOnce) {
|
|
154
134
|
ranOnce = true;
|
|
155
|
-
|
|
156
135
|
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
157
136
|
args[_key] = arguments[_key];
|
|
158
137
|
}
|
|
159
|
-
|
|
160
138
|
onceResult = fn.apply(context || this, args);
|
|
161
139
|
}
|
|
162
|
-
|
|
163
140
|
return onceResult;
|
|
164
141
|
};
|
|
165
142
|
}
|
|
166
|
-
|
|
167
143
|
function isError(value) {
|
|
168
144
|
if (Object.prototype.toString.call(value) === '[object Error]') {
|
|
169
145
|
return true;
|
|
170
146
|
}
|
|
171
|
-
|
|
172
147
|
return value instanceof Error;
|
|
173
148
|
}
|
|
174
|
-
|
|
175
149
|
function hasOwnProperty(target, property) {
|
|
176
150
|
return Object.hasOwnProperty.call(target, property);
|
|
177
151
|
}
|
|
178
|
-
|
|
179
152
|
function isPropertySet(target, property) {
|
|
180
153
|
return hasOwnProperty(target, property) && !(0, _validate.isUndefined)(target[property]);
|
|
181
154
|
}
|
|
155
|
+
|
|
182
156
|
/**
|
|
183
157
|
* Remove a trailing forward slash from a string if it exists
|
|
184
158
|
*
|
|
185
159
|
* @param string
|
|
186
160
|
* @returns {*}
|
|
187
161
|
*/
|
|
188
|
-
|
|
189
|
-
|
|
190
162
|
function stripTrailingSlash(string) {
|
|
191
163
|
if (!(0, _validate.isString)(string)) {
|
|
192
164
|
return string;
|
|
193
165
|
}
|
|
194
|
-
|
|
195
166
|
return string.endsWith('/') ? string.slice(0, -1) : string;
|
|
196
167
|
}
|
|
197
|
-
|
|
198
168
|
const isIOS = _reactNative.Platform.OS === 'ios';
|
|
199
169
|
exports.isIOS = isIOS;
|
|
200
170
|
const isAndroid = _reactNative.Platform.OS === 'android';
|
|
201
171
|
exports.isAndroid = isAndroid;
|
|
202
|
-
|
|
203
172
|
function tryJSONParse(string) {
|
|
204
173
|
try {
|
|
205
174
|
return string && JSON.parse(string);
|
|
@@ -207,7 +176,6 @@ function tryJSONParse(string) {
|
|
|
207
176
|
return string;
|
|
208
177
|
}
|
|
209
178
|
}
|
|
210
|
-
|
|
211
179
|
function tryJSONStringify(data) {
|
|
212
180
|
try {
|
|
213
181
|
return JSON.stringify(data);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"names":["getDataUrlParts","dataUrlString","isBase64","includes","mediaType","base64String","split","undefined","replace","decodeURIComponent","Base64","btoa","once","fn","context","onceResult","ranOnce","onceInner","args","apply","isError","value","Object","prototype","toString","call","Error","hasOwnProperty","target","property","isPropertySet","isUndefined","stripTrailingSlash","string","isString","endsWith","slice","isIOS","Platform","OS","isAndroid","tryJSONParse","JSON","parse","jsonError","tryJSONStringify","data","stringify"],"sources":["index.ts"],"sourcesContent":["/*\n * Copyright (c) 2016-present Invertase Limited & Contributors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this library except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n *\n */\n\nimport { Platform } from 'react-native';\nimport * as Base64 from './Base64';\nimport { isString, isUndefined } from './validate';\n\nexport * from './id';\nexport * from './path';\nexport * from './promise';\nexport * from './validate';\n\nexport { Base64 };\nexport { ReferenceBase } from './ReferenceBase';\n\nexport function getDataUrlParts(dataUrlString: string) {\n const isBase64 = dataUrlString.includes(';base64');\n let [mediaType, base64String] = dataUrlString.split(',');\n if (!mediaType || !base64String) {\n return { base64String: undefined, mediaType: undefined };\n }\n mediaType = mediaType.replace('data:', '').replace(';base64', '');\n if (base64String && base64String.includes('%')) {\n base64String = decodeURIComponent(base64String);\n }\n if (!isBase64) {\n base64String = Base64.btoa(base64String);\n }\n return { base64String, mediaType };\n}\n\nexport function once<T>(fn: () => void, context: unknown): (this: T, ...args: []) => void {\n let onceResult: unknown;\n let ranOnce = false;\n\n return function onceInner(...args: []) {\n if (!ranOnce) {\n ranOnce = true;\n onceResult = fn.apply(context || this, args);\n }\n\n return onceResult;\n };\n}\n\nexport function isError(value: unknown) {\n if (Object.prototype.toString.call(value) === '[object Error]') {\n return true;\n }\n\n return value instanceof Error;\n}\n\nexport function hasOwnProperty(target: unknown, property: PropertyKey) {\n return Object.hasOwnProperty.call(target, property);\n}\n\nexport function isPropertySet(target: unknown, property: PropertyKey) {\n return (\n hasOwnProperty(target, property) &&\n !isUndefined((target as Record<PropertyKey, unknown>)[property])\n );\n}\n\n/**\n * Remove a trailing forward slash from a string if it exists\n *\n * @param string\n * @returns {*}\n */\nexport function stripTrailingSlash(string: string) {\n if (!isString(string)) {\n return string;\n }\n return string.endsWith('/') ? string.slice(0, -1) : string;\n}\n\nexport const isIOS = Platform.OS === 'ios';\n\nexport const isAndroid = Platform.OS === 'android';\n\nexport function tryJSONParse(string: string) {\n try {\n return string && JSON.parse(string);\n } catch (jsonError) {\n return string;\n }\n}\n\nexport function tryJSONStringify(data: unknown) {\n try {\n return JSON.stringify(data);\n } catch (jsonError) {\n return null;\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAiBA;AACA;AAAmC;AACnC;AAKA;EAAA;EAAA;EAAA;EAAA;IAAA;IAAA;MAAA;IAAA;EAAA;AAAA;AAHA;AAAA;EAAA;EAAA;EAAA;EAAA;IAAA;IAAA;MAAA;IAAA;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,IAAI,CAACK,SAAS,CAACD,IAAI,CAAC;EAC7B,CAAC,CAAC,OAAOF,SAAS,EAAE;IAClB,OAAO,IAAI;EACb;AACF"}
|
|
@@ -12,7 +12,6 @@ exports.pathParent = pathParent;
|
|
|
12
12
|
exports.pathPieces = pathPieces;
|
|
13
13
|
exports.pathToUrlEncodedString = pathToUrlEncodedString;
|
|
14
14
|
exports.toFilePath = toFilePath;
|
|
15
|
-
|
|
16
15
|
/*
|
|
17
16
|
* Copyright (c) 2016-present Invertase Limited & Contributors
|
|
18
17
|
*
|
|
@@ -37,108 +36,90 @@ function pathParent(path) {
|
|
|
37
36
|
if (path.length === 0) {
|
|
38
37
|
return null;
|
|
39
38
|
}
|
|
40
|
-
|
|
41
39
|
const index = path.lastIndexOf('/');
|
|
42
|
-
|
|
43
40
|
if (index <= 0) {
|
|
44
41
|
return null;
|
|
45
42
|
}
|
|
46
|
-
|
|
47
43
|
return path.slice(0, index);
|
|
48
44
|
}
|
|
45
|
+
|
|
49
46
|
/**
|
|
50
47
|
* Joins a parent and a child path
|
|
51
48
|
*/
|
|
52
|
-
|
|
53
|
-
|
|
54
49
|
function pathChild(path, childPath) {
|
|
55
50
|
const canonicalChildPath = pathPieces(childPath).join('/');
|
|
56
|
-
|
|
57
51
|
if (path.length === 0) {
|
|
58
52
|
return canonicalChildPath;
|
|
59
53
|
}
|
|
60
|
-
|
|
61
54
|
return `${path}/${canonicalChildPath}`;
|
|
62
55
|
}
|
|
56
|
+
|
|
63
57
|
/**
|
|
64
58
|
* Returns the last component of a path, e.g /foo/bar.jpeg -> bar.jpeg
|
|
65
59
|
*/
|
|
66
|
-
|
|
67
|
-
|
|
68
60
|
function pathLastComponent(path) {
|
|
69
61
|
const index = path.lastIndexOf('/', path.length - 2);
|
|
70
|
-
|
|
71
62
|
if (index === -1) {
|
|
72
63
|
return path;
|
|
73
64
|
}
|
|
74
|
-
|
|
75
65
|
return path.slice(index + 1);
|
|
76
66
|
}
|
|
67
|
+
|
|
77
68
|
/**
|
|
78
69
|
* Returns all none empty pieces of the path
|
|
79
70
|
* @param path
|
|
80
71
|
* @returns {*}
|
|
81
72
|
*/
|
|
82
|
-
|
|
83
|
-
|
|
84
73
|
function pathPieces(path) {
|
|
85
74
|
return path.split('/').filter($ => $.length > 0);
|
|
86
75
|
}
|
|
76
|
+
|
|
87
77
|
/**
|
|
88
78
|
* Returns whether a given path is empty
|
|
89
79
|
* @param path
|
|
90
80
|
* @returns {boolean}
|
|
91
81
|
*/
|
|
92
|
-
|
|
93
|
-
|
|
94
82
|
function pathIsEmpty(path) {
|
|
95
83
|
return !pathPieces(path).length;
|
|
96
84
|
}
|
|
85
|
+
|
|
97
86
|
/**
|
|
98
87
|
* Converts a given path to a URL encoded string
|
|
99
88
|
* @param path
|
|
100
89
|
* @returns {string|string}
|
|
101
90
|
*/
|
|
102
|
-
|
|
103
|
-
|
|
104
91
|
function pathToUrlEncodedString(path) {
|
|
105
92
|
const pieces = pathPieces(path);
|
|
106
93
|
let pathString = '';
|
|
107
|
-
|
|
108
94
|
for (let i = 0; i < pieces.length; i++) {
|
|
109
95
|
pathString += `/${encodeURIComponent(String(pieces[i]))}`;
|
|
110
96
|
}
|
|
111
|
-
|
|
112
97
|
return pathString || '/';
|
|
113
|
-
}
|
|
114
|
-
|
|
98
|
+
}
|
|
115
99
|
|
|
100
|
+
// eslint-disable-next-line no-control-regex
|
|
116
101
|
const INVALID_PATH_REGEX = /[[\].#$\u0000-\u001F\u007F]/;
|
|
102
|
+
|
|
117
103
|
/**
|
|
118
104
|
* Ensures a given path is a valid Firebase path
|
|
119
105
|
* @param path
|
|
120
106
|
* @returns {boolean}
|
|
121
107
|
*/
|
|
122
|
-
|
|
123
108
|
exports.INVALID_PATH_REGEX = INVALID_PATH_REGEX;
|
|
124
|
-
|
|
125
109
|
function isValidPath(path) {
|
|
126
110
|
return typeof path === 'string' && path.length !== 0 && !INVALID_PATH_REGEX.test(path);
|
|
127
111
|
}
|
|
112
|
+
|
|
128
113
|
/**
|
|
129
114
|
* Converts a file path to a standardized string path
|
|
130
115
|
* @param path
|
|
131
116
|
* @returns {*}
|
|
132
117
|
*/
|
|
133
|
-
|
|
134
|
-
|
|
135
118
|
function toFilePath(path) {
|
|
136
119
|
let _filePath = path.replace('file://', '');
|
|
137
|
-
|
|
138
120
|
if (_filePath.includes('%')) {
|
|
139
121
|
_filePath = decodeURIComponent(_filePath);
|
|
140
122
|
}
|
|
141
|
-
|
|
142
123
|
return _filePath;
|
|
143
124
|
}
|
|
144
125
|
//# sourceMappingURL=path.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"names":["pathParent","path","length","index","lastIndexOf","slice","pathChild","childPath","canonicalChildPath","pathPieces","join","pathLastComponent","split","filter","$","pathIsEmpty","pathToUrlEncodedString","pieces","pathString","i","encodeURIComponent","String","INVALID_PATH_REGEX","isValidPath","test","toFilePath","_filePath","replace","includes","decodeURIComponent"],"sources":["path.ts"],"sourcesContent":["/*\n * Copyright (c) 2016-present Invertase Limited & Contributors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this library except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n *\n */\n\n/**\n * Returns the next parent of the path e.g. /foo/bar/car -> /foo/bar\n */\nexport function pathParent(path: string) {\n if (path.length === 0) {\n return null;\n }\n\n const index = path.lastIndexOf('/');\n if (index <= 0) {\n return null;\n }\n\n return path.slice(0, index);\n}\n\n/**\n * Joins a parent and a child path\n */\nexport function pathChild(path: string, childPath: string) {\n const canonicalChildPath = pathPieces(childPath).join('/');\n\n if (path.length === 0) {\n return canonicalChildPath;\n }\n\n return `${path}/${canonicalChildPath}`;\n}\n\n/**\n * Returns the last component of a path, e.g /foo/bar.jpeg -> bar.jpeg\n */\nexport function pathLastComponent(path: string) {\n const index = path.lastIndexOf('/', path.length - 2);\n if (index === -1) {\n return path;\n }\n\n return path.slice(index + 1);\n}\n\n/**\n * Returns all none empty pieces of the path\n * @param path\n * @returns {*}\n */\nexport function pathPieces(path: string) {\n return path.split('/').filter($ => $.length > 0);\n}\n\n/**\n * Returns whether a given path is empty\n * @param path\n * @returns {boolean}\n */\nexport function pathIsEmpty(path: string) {\n return !pathPieces(path).length;\n}\n\n/**\n * Converts a given path to a URL encoded string\n * @param path\n * @returns {string|string}\n */\nexport function pathToUrlEncodedString(path: string) {\n const pieces = pathPieces(path);\n let pathString = '';\n for (let i = 0; i < pieces.length; i++) {\n pathString += `/${encodeURIComponent(String(pieces[i]))}`;\n }\n return pathString || '/';\n}\n\n// eslint-disable-next-line no-control-regex\nexport const INVALID_PATH_REGEX = /[[\\].#$\\u0000-\\u001F\\u007F]/;\n\n/**\n * Ensures a given path is a valid Firebase path\n * @param path\n * @returns {boolean}\n */\nexport function isValidPath(path: unknown) {\n return typeof path === 'string' && path.length !== 0 && !INVALID_PATH_REGEX.test(path);\n}\n\n/**\n * Converts a file path to a standardized string path\n * @param path\n * @returns {*}\n */\nexport function toFilePath(path: string) {\n let _filePath = path.replace('file://', '');\n if (_filePath.includes('%')) {\n _filePath = decodeURIComponent(_filePath);\n }\n return _filePath;\n}\n"],"mappings":";;;;;;;;;;;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACO,SAASA,UAAU,CAACC,IAAY,EAAE;EACvC,IAAIA,IAAI,CAACC,MAAM,KAAK,CAAC,EAAE;IACrB,OAAO,IAAI;EACb;EAEA,MAAMC,KAAK,GAAGF,IAAI,CAACG,WAAW,CAAC,GAAG,CAAC;EACnC,IAAID,KAAK,IAAI,CAAC,EAAE;IACd,OAAO,IAAI;EACb;EAEA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