@azzas/azzas-tracker-web 2.0.1-preview.1 → 2.0.1
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/mod.cjs +11 -6
- package/dist/mod.cjs.map +1 -1
- package/dist/mod.global.js +11 -6
- package/dist/mod.global.js.map +1 -1
- package/dist/mod.js +11 -6
- package/dist/mod.js.map +1 -1
- package/dist/mod.vtex.global.js +17 -9
- package/package.json +1 -1
package/dist/mod.js
CHANGED
|
@@ -1058,13 +1058,15 @@ var PROD_DOMAINS = {
|
|
|
1058
1058
|
"checkout": "https://secure.offpremium.com.br"
|
|
1059
1059
|
},
|
|
1060
1060
|
"carolbassi": {
|
|
1061
|
-
"store": "https://carolbassi.myvtex.com"
|
|
1061
|
+
"store": "https://carolbassi.myvtex.com",
|
|
1062
|
+
"checkout": "https://secure.carolbassi.com.br"
|
|
1062
1063
|
},
|
|
1063
1064
|
"bynv": {
|
|
1064
1065
|
"store": "https://bynv.myvtex.com"
|
|
1065
1066
|
},
|
|
1066
1067
|
"lojafabula": {
|
|
1067
|
-
"store": "https://lojafabula.myvtex.com"
|
|
1068
|
+
"store": "https://lojafabula.myvtex.com",
|
|
1069
|
+
"checkout": "https://secure.lojafabula.com.br"
|
|
1068
1070
|
}
|
|
1069
1071
|
};
|
|
1070
1072
|
async function getUserInfo(context) {
|
|
@@ -1994,10 +1996,13 @@ var orderFormAdapter = {
|
|
|
1994
1996
|
total_discount: (context) => {
|
|
1995
1997
|
var _a, _b, _c;
|
|
1996
1998
|
if (context == null ? void 0 : context.total_discount) return context.total_discount;
|
|
1997
|
-
|
|
1998
|
-
const
|
|
1999
|
-
|
|
2000
|
-
|
|
1999
|
+
const orderForm = context == null ? void 0 : context.orderForm;
|
|
2000
|
+
const items = orderForm == null ? void 0 : orderForm.items;
|
|
2001
|
+
if (!(items == null ? void 0 : items.length) || typeof (orderForm == null ? void 0 : orderForm.value) !== "number") return null;
|
|
2002
|
+
const itemsFullValue = items.reduce((acc, item) => acc + item.listPrice * item.quantity, 0);
|
|
2003
|
+
const shipping = (_c = (_b = (_a = orderForm == null ? void 0 : orderForm.totalizers) == null ? void 0 : _a.find((t) => t.id === "Shipping")) == null ? void 0 : _b.value) != null ? _c : 0;
|
|
2004
|
+
const derived = itemsFullValue + shipping - orderForm.value;
|
|
2005
|
+
return derived > 0 ? derived / 100 : null;
|
|
2001
2006
|
},
|
|
2002
2007
|
subtotal: (context) => {
|
|
2003
2008
|
var _a, _b;
|