@ikas/storefront 0.0.164-alpha.3 → 0.0.164-alpha.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/build/index.es.js +9 -8
- package/build/index.js +9 -8
- package/package.json +1 -1
package/build/index.es.js
CHANGED
|
@@ -11328,6 +11328,8 @@ var IkasOrderAddress = /** @class */ (function () {
|
|
|
11328
11328
|
this.identityNumber = data.identityNumber || null;
|
|
11329
11329
|
this.taxNumber = data.taxNumber || null;
|
|
11330
11330
|
this.taxOffice = data.taxOffice || null;
|
|
11331
|
+
this.checkoutSettings = data.checkoutSettings;
|
|
11332
|
+
this.isDistrictRequired = data.isDistrictRequired || false;
|
|
11331
11333
|
makeAutoObservable(this);
|
|
11332
11334
|
}
|
|
11333
11335
|
Object.defineProperty(IkasOrderAddress.prototype, "addressText", {
|
|
@@ -23185,10 +23187,7 @@ var CheckoutViewModel = /** @class */ (function () {
|
|
|
23185
23187
|
newCheckout = _a.sent();
|
|
23186
23188
|
if (newCheckout) {
|
|
23187
23189
|
oldCheckout = this.checkout;
|
|
23188
|
-
this.checkout = newCheckout;
|
|
23189
|
-
this.checkout.customer = oldCheckout.customer;
|
|
23190
|
-
this.checkout.shippingAddress = oldCheckout.shippingAddress;
|
|
23191
|
-
this.checkout.billingAddress = oldCheckout.billingAddress;
|
|
23190
|
+
this.checkout = new IkasCheckout(__assign(__assign({}, newCheckout), { shippingAddress: oldCheckout.shippingAddress, billingAddress: oldCheckout.billingAddress, customer: oldCheckout.customer }));
|
|
23192
23191
|
}
|
|
23193
23192
|
return [3 /*break*/, 4];
|
|
23194
23193
|
case 3:
|
|
@@ -61102,7 +61101,8 @@ var CartSummary = observer(function (_a) {
|
|
|
61102
61101
|
!!vm.installmentExtraPrice && (createElement(InfoRow, { label: t("checkout-page:cartInterest"), value: formatMoney(vm.installmentExtraPrice, cart.currencyCode) })),
|
|
61103
61102
|
createElement(Adjustments, { vm: vm }),
|
|
61104
61103
|
createElement(CalculatedAdditionalPrices, { vm: vm }),
|
|
61105
|
-
((vm.step === CheckoutStep.SUCCESS &&
|
|
61104
|
+
((vm.step === CheckoutStep.SUCCESS &&
|
|
61105
|
+
(!!vm.checkout.note || !!vm.checkout.appliedCouponCode)) ||
|
|
61106
61106
|
vm.step !== CheckoutStep.SUCCESS) && (createElement("div", { className: styles$h.Divider, style: { marginTop: "24px", marginBottom: "24px" } })),
|
|
61107
61107
|
createElement(Coupon, { vm: vm, isAddingCoupon: isAddingCoupon, setAddingCoupon: setAddingCoupon, setCouponError: setCouponError }),
|
|
61108
61108
|
createElement(Note, { vm: vm, isAddingNote: isAddingNote, setAddingNote: setAddingNote })),
|
|
@@ -61202,7 +61202,8 @@ var Coupon = observer(function (_a) {
|
|
|
61202
61202
|
}
|
|
61203
61203
|
});
|
|
61204
61204
|
}); };
|
|
61205
|
-
|
|
61205
|
+
var isSuccess = vm.step === CheckoutStep.SUCCESS;
|
|
61206
|
+
if (isSuccess && !vm.checkout.appliedCouponCode)
|
|
61206
61207
|
return null;
|
|
61207
61208
|
var adjustment = vm.checkout.couponAdjustment;
|
|
61208
61209
|
return (createElement("div", { className: styles$h.InfoRow },
|
|
@@ -61216,8 +61217,8 @@ var Coupon = observer(function (_a) {
|
|
|
61216
61217
|
t("checkout-page:couponCode"),
|
|
61217
61218
|
createElement("span", { className: styles$h.AppliedCoupon },
|
|
61218
61219
|
createElement("span", { className: styles$h.CouponCode }, vm.checkout.appliedCouponCode),
|
|
61219
|
-
createElement("span", { className: styles$h.ClearCoupon, onClick: onClearCouponCode },
|
|
61220
|
-
createElement(SVGCross, null))))),
|
|
61220
|
+
vm.step !== CheckoutStep.SUCCESS && (createElement("span", { className: styles$h.ClearCoupon, onClick: onClearCouponCode },
|
|
61221
|
+
createElement(SVGCross, null)))))),
|
|
61221
61222
|
!!vm.checkout.appliedCouponCode && !isAddingCoupon && (createElement("div", { className: styles$h.Value },
|
|
61222
61223
|
createElement("span", null, (adjustment === null || adjustment === void 0 ? void 0 : adjustment.type) === "DECREMENT" ? "- " : ""),
|
|
61223
61224
|
" ",
|
package/build/index.js
CHANGED
|
@@ -11344,6 +11344,8 @@ var IkasOrderAddress = /** @class */ (function () {
|
|
|
11344
11344
|
this.identityNumber = data.identityNumber || null;
|
|
11345
11345
|
this.taxNumber = data.taxNumber || null;
|
|
11346
11346
|
this.taxOffice = data.taxOffice || null;
|
|
11347
|
+
this.checkoutSettings = data.checkoutSettings;
|
|
11348
|
+
this.isDistrictRequired = data.isDistrictRequired || false;
|
|
11347
11349
|
mobx.makeAutoObservable(this);
|
|
11348
11350
|
}
|
|
11349
11351
|
Object.defineProperty(IkasOrderAddress.prototype, "addressText", {
|
|
@@ -23193,10 +23195,7 @@ var CheckoutViewModel = /** @class */ (function () {
|
|
|
23193
23195
|
newCheckout = _a.sent();
|
|
23194
23196
|
if (newCheckout) {
|
|
23195
23197
|
oldCheckout = this.checkout;
|
|
23196
|
-
this.checkout = newCheckout;
|
|
23197
|
-
this.checkout.customer = oldCheckout.customer;
|
|
23198
|
-
this.checkout.shippingAddress = oldCheckout.shippingAddress;
|
|
23199
|
-
this.checkout.billingAddress = oldCheckout.billingAddress;
|
|
23198
|
+
this.checkout = new IkasCheckout(__assign(__assign({}, newCheckout), { shippingAddress: oldCheckout.shippingAddress, billingAddress: oldCheckout.billingAddress, customer: oldCheckout.customer }));
|
|
23200
23199
|
}
|
|
23201
23200
|
return [3 /*break*/, 4];
|
|
23202
23201
|
case 3:
|
|
@@ -61081,7 +61080,8 @@ var CartSummary = mobxReactLite.observer(function (_a) {
|
|
|
61081
61080
|
!!vm.installmentExtraPrice && (React.createElement(InfoRow, { label: t("checkout-page:cartInterest"), value: formatMoney(vm.installmentExtraPrice, cart.currencyCode) })),
|
|
61082
61081
|
React.createElement(Adjustments, { vm: vm }),
|
|
61083
61082
|
React.createElement(CalculatedAdditionalPrices, { vm: vm }),
|
|
61084
|
-
((vm.step === CheckoutStep.SUCCESS &&
|
|
61083
|
+
((vm.step === CheckoutStep.SUCCESS &&
|
|
61084
|
+
(!!vm.checkout.note || !!vm.checkout.appliedCouponCode)) ||
|
|
61085
61085
|
vm.step !== CheckoutStep.SUCCESS) && (React.createElement("div", { className: styles$h.Divider, style: { marginTop: "24px", marginBottom: "24px" } })),
|
|
61086
61086
|
React.createElement(Coupon, { vm: vm, isAddingCoupon: isAddingCoupon, setAddingCoupon: setAddingCoupon, setCouponError: setCouponError }),
|
|
61087
61087
|
React.createElement(Note, { vm: vm, isAddingNote: isAddingNote, setAddingNote: setAddingNote })),
|
|
@@ -61181,7 +61181,8 @@ var Coupon = mobxReactLite.observer(function (_a) {
|
|
|
61181
61181
|
}
|
|
61182
61182
|
});
|
|
61183
61183
|
}); };
|
|
61184
|
-
|
|
61184
|
+
var isSuccess = vm.step === CheckoutStep.SUCCESS;
|
|
61185
|
+
if (isSuccess && !vm.checkout.appliedCouponCode)
|
|
61185
61186
|
return null;
|
|
61186
61187
|
var adjustment = vm.checkout.couponAdjustment;
|
|
61187
61188
|
return (React.createElement("div", { className: styles$h.InfoRow },
|
|
@@ -61195,8 +61196,8 @@ var Coupon = mobxReactLite.observer(function (_a) {
|
|
|
61195
61196
|
t("checkout-page:couponCode"),
|
|
61196
61197
|
React.createElement("span", { className: styles$h.AppliedCoupon },
|
|
61197
61198
|
React.createElement("span", { className: styles$h.CouponCode }, vm.checkout.appliedCouponCode),
|
|
61198
|
-
React.createElement("span", { className: styles$h.ClearCoupon, onClick: onClearCouponCode },
|
|
61199
|
-
React.createElement(SVGCross, null))))),
|
|
61199
|
+
vm.step !== CheckoutStep.SUCCESS && (React.createElement("span", { className: styles$h.ClearCoupon, onClick: onClearCouponCode },
|
|
61200
|
+
React.createElement(SVGCross, null)))))),
|
|
61200
61201
|
!!vm.checkout.appliedCouponCode && !isAddingCoupon && (React.createElement("div", { className: styles$h.Value },
|
|
61201
61202
|
React.createElement("span", null, (adjustment === null || adjustment === void 0 ? void 0 : adjustment.type) === "DECREMENT" ? "- " : ""),
|
|
61202
61203
|
" ",
|