@shware/analytics 11.13.3 → 11.13.4
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/dist/index.cjs +8 -2
- package/dist/utils/stripe.cjs +13 -28
- package/dist/utils/stripe.d.cts +2 -6
- package/dist/utils/stripe.d.mts +2 -6
- package/dist/utils/stripe.mjs +1 -27
- package/package.json +2 -2
- package/dist/utils/stripe.cjs.map +0 -1
- package/dist/utils/stripe.d.cts.map +0 -1
- package/dist/utils/stripe.d.mts.map +0 -1
- package/dist/utils/stripe.mjs.map +0 -1
package/dist/index.cjs
CHANGED
|
@@ -7,8 +7,9 @@ const require_feedback_index = require("./feedback/index.cjs");
|
|
|
7
7
|
const require_link_index = require("./link/index.cjs");
|
|
8
8
|
const require_schema_index = require("./schema/index.cjs");
|
|
9
9
|
const require_bot_index = require("./bot/index.cjs");
|
|
10
|
-
|
|
10
|
+
require("./utils/stripe.cjs");
|
|
11
11
|
const require_hooks_use_track_impression = require("./hooks/use-track-impression.cjs");
|
|
12
|
+
let _shware_utils = require("@shware/utils");
|
|
12
13
|
exports.ALL_ENVIRONMENTS = require_schema_index.ALL_ENVIRONMENTS;
|
|
13
14
|
exports.ALL_PLATFORMS = require_schema_index.ALL_PLATFORMS;
|
|
14
15
|
exports.BOT_CATEGORIES = require_bot_index.BOT_CATEGORIES;
|
|
@@ -26,7 +27,12 @@ exports.sendFeedback = require_feedback_index.sendFeedback;
|
|
|
26
27
|
exports.sendPendingEvents = require_track_index.sendPendingEvents;
|
|
27
28
|
exports.setVisitor = require_visitor_index.setVisitor;
|
|
28
29
|
exports.setupAnalytics = require_setup_index.setupAnalytics;
|
|
29
|
-
exports
|
|
30
|
+
Object.defineProperty(exports, "stripeMinorUnits", {
|
|
31
|
+
enumerable: true,
|
|
32
|
+
get: function() {
|
|
33
|
+
return _shware_utils.stripeMinorUnits;
|
|
34
|
+
}
|
|
35
|
+
});
|
|
30
36
|
exports.track = require_track_index.track;
|
|
31
37
|
exports.trackAsync = require_track_index.trackAsync;
|
|
32
38
|
exports.updateVisitorSchema = require_schema_index.updateVisitorSchema;
|
package/dist/utils/stripe.cjs
CHANGED
|
@@ -1,29 +1,14 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
"VND",
|
|
16
|
-
"VUV",
|
|
17
|
-
"XAF",
|
|
18
|
-
"XOF",
|
|
19
|
-
"XPF"
|
|
20
|
-
];
|
|
21
|
-
/** reference: https://docs.stripe.com/currencies#zero-decimal */
|
|
22
|
-
function stripeMinorUnits(currency) {
|
|
23
|
-
return ZERO_DECIMAL_CURRENCIES.includes(currency.toUpperCase()) ? 1 : 100;
|
|
24
|
-
}
|
|
25
|
-
//#endregion
|
|
26
|
-
exports.ZERO_DECIMAL_CURRENCIES = ZERO_DECIMAL_CURRENCIES;
|
|
27
|
-
exports.stripeMinorUnits = stripeMinorUnits;
|
|
28
|
-
|
|
29
|
-
//# sourceMappingURL=stripe.cjs.map
|
|
2
|
+
let _shware_utils = require("@shware/utils");
|
|
3
|
+
Object.defineProperty(exports, "ZERO_DECIMAL_CURRENCIES", {
|
|
4
|
+
enumerable: true,
|
|
5
|
+
get: function() {
|
|
6
|
+
return _shware_utils.ZERO_DECIMAL_CURRENCIES;
|
|
7
|
+
}
|
|
8
|
+
});
|
|
9
|
+
Object.defineProperty(exports, "stripeMinorUnits", {
|
|
10
|
+
enumerable: true,
|
|
11
|
+
get: function() {
|
|
12
|
+
return _shware_utils.stripeMinorUnits;
|
|
13
|
+
}
|
|
14
|
+
});
|
package/dist/utils/stripe.d.cts
CHANGED
|
@@ -1,6 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
export
|
|
3
|
-
/** reference: https://docs.stripe.com/currencies#zero-decimal */
|
|
4
|
-
export declare function stripeMinorUnits(currency: string): 1 | 100;
|
|
5
|
-
//#endregion
|
|
6
|
-
//# sourceMappingURL=stripe.d.cts.map
|
|
1
|
+
import { ZERO_DECIMAL_CURRENCIES, stripeMinorUnits } from "@shware/utils";
|
|
2
|
+
export { ZERO_DECIMAL_CURRENCIES, stripeMinorUnits };
|
package/dist/utils/stripe.d.mts
CHANGED
|
@@ -1,6 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
export
|
|
3
|
-
/** reference: https://docs.stripe.com/currencies#zero-decimal */
|
|
4
|
-
export declare function stripeMinorUnits(currency: string): 1 | 100;
|
|
5
|
-
//#endregion
|
|
6
|
-
//# sourceMappingURL=stripe.d.mts.map
|
|
1
|
+
import { ZERO_DECIMAL_CURRENCIES, stripeMinorUnits } from "@shware/utils";
|
|
2
|
+
export { ZERO_DECIMAL_CURRENCIES, stripeMinorUnits };
|
package/dist/utils/stripe.mjs
CHANGED
|
@@ -1,27 +1 @@
|
|
|
1
|
-
|
|
2
|
-
const ZERO_DECIMAL_CURRENCIES = [
|
|
3
|
-
"BIF",
|
|
4
|
-
"CLP",
|
|
5
|
-
"DJF",
|
|
6
|
-
"GNF",
|
|
7
|
-
"JPY",
|
|
8
|
-
"KMF",
|
|
9
|
-
"KRW",
|
|
10
|
-
"MGA",
|
|
11
|
-
"PYG",
|
|
12
|
-
"RWF",
|
|
13
|
-
"UGX",
|
|
14
|
-
"VND",
|
|
15
|
-
"VUV",
|
|
16
|
-
"XAF",
|
|
17
|
-
"XOF",
|
|
18
|
-
"XPF"
|
|
19
|
-
];
|
|
20
|
-
/** reference: https://docs.stripe.com/currencies#zero-decimal */
|
|
21
|
-
function stripeMinorUnits(currency) {
|
|
22
|
-
return ZERO_DECIMAL_CURRENCIES.includes(currency.toUpperCase()) ? 1 : 100;
|
|
23
|
-
}
|
|
24
|
-
//#endregion
|
|
25
|
-
export { ZERO_DECIMAL_CURRENCIES, stripeMinorUnits };
|
|
26
|
-
|
|
27
|
-
//# sourceMappingURL=stripe.mjs.map
|
|
1
|
+
export { ZERO_DECIMAL_CURRENCIES, stripeMinorUnits } from "@shware/utils";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@shware/analytics",
|
|
3
|
-
"version": "11.13.
|
|
3
|
+
"version": "11.13.4",
|
|
4
4
|
"private": false,
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -156,7 +156,7 @@
|
|
|
156
156
|
"access": "public"
|
|
157
157
|
},
|
|
158
158
|
"dependencies": {
|
|
159
|
-
"@shware/utils": "^1.
|
|
159
|
+
"@shware/utils": "^1.8.0",
|
|
160
160
|
"capi-param-builder-nodejs": "~1.3.2",
|
|
161
161
|
"cookie": "^2.0.1",
|
|
162
162
|
"uuid": "^14.0.3",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"stripe.cjs","names":[],"sources":["../../src/utils/stripe.ts"],"sourcesContent":["export const ZERO_DECIMAL_CURRENCIES = [\n 'BIF',\n 'CLP',\n 'DJF',\n 'GNF',\n 'JPY',\n 'KMF',\n 'KRW',\n 'MGA',\n 'PYG',\n 'RWF',\n 'UGX',\n 'VND',\n 'VUV',\n 'XAF',\n 'XOF',\n 'XPF',\n];\n\n/** reference: https://docs.stripe.com/currencies#zero-decimal */\nexport function stripeMinorUnits(currency: string) {\n return ZERO_DECIMAL_CURRENCIES.includes(currency.toUpperCase()) ? 1 : 100;\n}\n"],"mappings":";;AAAA,MAAa,0BAA0B;CACrC;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;AACF;;AAGA,SAAgB,iBAAiB,UAAkB;CACjD,OAAO,wBAAwB,SAAS,SAAS,YAAY,CAAC,IAAI,IAAI;AACxE"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"stripe.d.cts","names":[],"sources":["../../src/utils/stripe.ts"],"mappings":";qBAAa;;wBAoBG,iBAAiB"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"stripe.d.mts","names":[],"sources":["../../src/utils/stripe.ts"],"mappings":";qBAAa;;wBAoBG,iBAAiB"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"stripe.mjs","names":[],"sources":["../../src/utils/stripe.ts"],"sourcesContent":["export const ZERO_DECIMAL_CURRENCIES = [\n 'BIF',\n 'CLP',\n 'DJF',\n 'GNF',\n 'JPY',\n 'KMF',\n 'KRW',\n 'MGA',\n 'PYG',\n 'RWF',\n 'UGX',\n 'VND',\n 'VUV',\n 'XAF',\n 'XOF',\n 'XPF',\n];\n\n/** reference: https://docs.stripe.com/currencies#zero-decimal */\nexport function stripeMinorUnits(currency: string) {\n return ZERO_DECIMAL_CURRENCIES.includes(currency.toUpperCase()) ? 1 : 100;\n}\n"],"mappings":";AAAA,MAAa,0BAA0B;CACrC;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;AACF;;AAGA,SAAgB,iBAAiB,UAAkB;CACjD,OAAO,wBAAwB,SAAS,SAAS,YAAY,CAAC,IAAI,IAAI;AACxE"}
|