@ikas/storefront 0.0.139 → 0.0.141
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/api/checkout/__generated__/getCheckoutById.d.ts +1 -0
- package/build/components/checkout/components/button/index.d.ts +4 -1
- package/build/components/checkout/components/cart-summary/cross.d.ts +6 -0
- package/build/components/checkout/components/cart-summary/tag.d.ts +6 -0
- package/build/components/checkout/model.d.ts +2 -0
- package/build/index.es.js +128 -30
- package/build/index.js +128 -30
- package/build/models/data/checkout/index.d.ts +1 -0
- package/build/models/data/order/index.d.ts +1 -0
- package/package.json +1 -1
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
declare type Props = {
|
|
3
|
-
text: string;
|
|
3
|
+
text: string | React.ReactNode;
|
|
4
4
|
isLoading?: boolean;
|
|
5
|
+
isDisabled?: boolean;
|
|
6
|
+
size?: "large" | "medium";
|
|
7
|
+
style?: React.CSSProperties;
|
|
5
8
|
onClick: () => void;
|
|
6
9
|
};
|
|
7
10
|
export declare const Button: React.FC<Props>;
|
|
@@ -65,6 +65,7 @@ export default class CheckoutViewModel {
|
|
|
65
65
|
onEmailChange: (value: string) => void;
|
|
66
66
|
onShippingMethodChange: (shippingMethod: IkasAvailableShippingMethod) => Promise<void>;
|
|
67
67
|
onCouponCodeChange: (value: string) => void;
|
|
68
|
+
onCouponCodeApply: () => Promise<void>;
|
|
68
69
|
onSelectedShippingAddressIdChange: (value: string) => void;
|
|
69
70
|
onSelectedBillingAddressIdChange: (value: string) => void;
|
|
70
71
|
onTermsAndConditionsCheckedChange: (value: boolean) => void;
|
|
@@ -73,6 +74,7 @@ export default class CheckoutViewModel {
|
|
|
73
74
|
onCardHolderNameChange: (value: string) => void;
|
|
74
75
|
onExpirationDateChange: (value: string) => void;
|
|
75
76
|
onCvcChange: (value: string) => void;
|
|
77
|
+
onGoToCartClick: () => void;
|
|
76
78
|
onBackToShoppingClick: () => void;
|
|
77
79
|
onProceedToShippingClick: () => Promise<void>;
|
|
78
80
|
onProceedToPaymentClick: () => Promise<void>;
|
package/build/index.es.js
CHANGED
|
@@ -11439,6 +11439,8 @@ var IkasCheckout = /** @class */ (function () {
|
|
|
11439
11439
|
this.totalFinalPrice = null;
|
|
11440
11440
|
this.adjustments = null;
|
|
11441
11441
|
this.note = null;
|
|
11442
|
+
// Extra
|
|
11443
|
+
this.appliedCouponCode = null;
|
|
11442
11444
|
this.id = data.id;
|
|
11443
11445
|
this.createdAt = data.createdAt;
|
|
11444
11446
|
this.updatedAt = data.updatedAt;
|
|
@@ -11453,14 +11455,15 @@ var IkasCheckout = /** @class */ (function () {
|
|
|
11453
11455
|
this.customer = data.customer;
|
|
11454
11456
|
this.billingAddress = data.billingAddress
|
|
11455
11457
|
? new IkasOrderAddress(data.billingAddress)
|
|
11456
|
-
:
|
|
11458
|
+
: new IkasOrderAddress();
|
|
11457
11459
|
this.shippingAddress = data.shippingAddress
|
|
11458
11460
|
? new IkasOrderAddress(data.shippingAddress)
|
|
11459
|
-
:
|
|
11461
|
+
: new IkasOrderAddress();
|
|
11460
11462
|
this.shippingLines = data.shippingLines || [];
|
|
11461
11463
|
this.shippingMethod = data.shippingMethod || IkasShippingMethod.NO_SHIPMENT;
|
|
11462
11464
|
this.status = data.status || IkasCheckoutStatus.OPEN;
|
|
11463
11465
|
this.couponCode = data.couponCode;
|
|
11466
|
+
this.appliedCouponCode = data.couponCode;
|
|
11464
11467
|
this.recoverEmailStatus = data.recoverEmailStatus;
|
|
11465
11468
|
this.recoveryStatus = data.recoveryStatus;
|
|
11466
11469
|
this.totalFinalPrice = data.totalFinalPrice;
|
|
@@ -16478,6 +16481,33 @@ var CheckoutViewModel = /** @class */ (function () {
|
|
|
16478
16481
|
this.onCouponCodeChange = function (value) {
|
|
16479
16482
|
_this.checkout.couponCode = value;
|
|
16480
16483
|
};
|
|
16484
|
+
this.onCouponCodeApply = function () { return __awaiter(_this, void 0, void 0, function () {
|
|
16485
|
+
var newCheckout, oldCheckout;
|
|
16486
|
+
return __generator(this, function (_a) {
|
|
16487
|
+
switch (_a.label) {
|
|
16488
|
+
case 0:
|
|
16489
|
+
_a.trys.push([0, 3, , 4]);
|
|
16490
|
+
return [4 /*yield*/, this.saveCheckout()];
|
|
16491
|
+
case 1:
|
|
16492
|
+
_a.sent();
|
|
16493
|
+
return [4 /*yield*/, IkasCheckoutAPI.getCheckoutById(this.checkout.id)];
|
|
16494
|
+
case 2:
|
|
16495
|
+
newCheckout = _a.sent();
|
|
16496
|
+
if (newCheckout) {
|
|
16497
|
+
oldCheckout = this.checkout;
|
|
16498
|
+
this.checkout = newCheckout;
|
|
16499
|
+
this.checkout.customer = oldCheckout.customer;
|
|
16500
|
+
this.checkout.shippingAddress = oldCheckout.shippingAddress;
|
|
16501
|
+
this.checkout.billingAddress = oldCheckout.billingAddress;
|
|
16502
|
+
}
|
|
16503
|
+
return [3 /*break*/, 4];
|
|
16504
|
+
case 3:
|
|
16505
|
+
_a.sent();
|
|
16506
|
+
return [3 /*break*/, 4];
|
|
16507
|
+
case 4: return [2 /*return*/];
|
|
16508
|
+
}
|
|
16509
|
+
});
|
|
16510
|
+
}); };
|
|
16481
16511
|
this.onSelectedShippingAddressIdChange = function (value) {
|
|
16482
16512
|
var _a;
|
|
16483
16513
|
_this.selectedShippingAddressId = value;
|
|
@@ -16567,11 +16597,14 @@ var CheckoutViewModel = /** @class */ (function () {
|
|
|
16567
16597
|
_this.cardData.cvv = value;
|
|
16568
16598
|
};
|
|
16569
16599
|
// CREDIT CARD END
|
|
16600
|
+
this.onGoToCartClick = function () {
|
|
16601
|
+
_this.router.push("/cart");
|
|
16602
|
+
};
|
|
16570
16603
|
this.onBackToShoppingClick = function () {
|
|
16571
16604
|
_this.router.push("/");
|
|
16572
16605
|
};
|
|
16573
16606
|
this.onProceedToShippingClick = function () { return __awaiter(_this, void 0, void 0, function () {
|
|
16574
|
-
var newAddress, customer,
|
|
16607
|
+
var newAddress, customer, err_3;
|
|
16575
16608
|
return __generator(this, function (_a) {
|
|
16576
16609
|
switch (_a.label) {
|
|
16577
16610
|
case 0:
|
|
@@ -16601,12 +16634,12 @@ var CheckoutViewModel = /** @class */ (function () {
|
|
|
16601
16634
|
this.changeStep(CheckoutStep.SHIPPING);
|
|
16602
16635
|
return [3 /*break*/, 7];
|
|
16603
16636
|
case 6:
|
|
16604
|
-
|
|
16605
|
-
if (
|
|
16606
|
-
this.error =
|
|
16637
|
+
err_3 = _a.sent();
|
|
16638
|
+
if (err_3.type) {
|
|
16639
|
+
this.error = err_3;
|
|
16607
16640
|
}
|
|
16608
16641
|
else {
|
|
16609
|
-
console.log(
|
|
16642
|
+
console.log(err_3);
|
|
16610
16643
|
this.error = {
|
|
16611
16644
|
type: ErrorType.UNKNOWN,
|
|
16612
16645
|
};
|
|
@@ -16618,7 +16651,7 @@ var CheckoutViewModel = /** @class */ (function () {
|
|
|
16618
16651
|
});
|
|
16619
16652
|
}); };
|
|
16620
16653
|
this.onProceedToPaymentClick = function () { return __awaiter(_this, void 0, void 0, function () {
|
|
16621
|
-
var
|
|
16654
|
+
var err_4;
|
|
16622
16655
|
return __generator(this, function (_a) {
|
|
16623
16656
|
switch (_a.label) {
|
|
16624
16657
|
case 0:
|
|
@@ -16638,12 +16671,12 @@ var CheckoutViewModel = /** @class */ (function () {
|
|
|
16638
16671
|
this.changeStep(CheckoutStep.PAYMENT);
|
|
16639
16672
|
return [3 /*break*/, 4];
|
|
16640
16673
|
case 3:
|
|
16641
|
-
|
|
16642
|
-
if (
|
|
16643
|
-
this.error =
|
|
16674
|
+
err_4 = _a.sent();
|
|
16675
|
+
if (err_4.type) {
|
|
16676
|
+
this.error = err_4;
|
|
16644
16677
|
}
|
|
16645
16678
|
else {
|
|
16646
|
-
console.log(
|
|
16679
|
+
console.log(err_4);
|
|
16647
16680
|
this.error = {
|
|
16648
16681
|
type: ErrorType.UNKNOWN,
|
|
16649
16682
|
};
|
|
@@ -16655,7 +16688,7 @@ var CheckoutViewModel = /** @class */ (function () {
|
|
|
16655
16688
|
});
|
|
16656
16689
|
}); };
|
|
16657
16690
|
this.performPayment = function () { return __awaiter(_this, void 0, void 0, function () {
|
|
16658
|
-
var response, transactionStatus,
|
|
16691
|
+
var response, transactionStatus, err_5;
|
|
16659
16692
|
var _a;
|
|
16660
16693
|
return __generator(this, function (_b) {
|
|
16661
16694
|
switch (_b.label) {
|
|
@@ -16706,10 +16739,10 @@ var CheckoutViewModel = /** @class */ (function () {
|
|
|
16706
16739
|
}
|
|
16707
16740
|
return [3 /*break*/, 6];
|
|
16708
16741
|
case 5:
|
|
16709
|
-
|
|
16710
|
-
if (
|
|
16711
|
-
console.log(
|
|
16712
|
-
this.error =
|
|
16742
|
+
err_5 = _b.sent();
|
|
16743
|
+
if (err_5.type) {
|
|
16744
|
+
console.log(err_5);
|
|
16745
|
+
this.error = err_5;
|
|
16713
16746
|
}
|
|
16714
16747
|
else {
|
|
16715
16748
|
this.error = {
|
|
@@ -21162,6 +21195,7 @@ var IkasProductList = /** @class */ (function () {
|
|
|
21162
21195
|
this.data = this.data.concat(data);
|
|
21163
21196
|
this._count = response.count;
|
|
21164
21197
|
this._page = this.page + 1;
|
|
21198
|
+
this._minPage = this._page;
|
|
21165
21199
|
return [3 /*break*/, 5];
|
|
21166
21200
|
case 3:
|
|
21167
21201
|
err_3 = _a.sent();
|
|
@@ -26538,7 +26572,7 @@ var IkasCheckoutAPI = /** @class */ (function () {
|
|
|
26538
26572
|
return __generator(this, function (_b) {
|
|
26539
26573
|
switch (_b.label) {
|
|
26540
26574
|
case 0:
|
|
26541
|
-
QUERY = src(templateObject_2$3 || (templateObject_2$3 = __makeTemplateObject(["\n query getCheckoutById($id: String!) {\n getCheckoutById(id: $id) {\n totalFinalPrice\n note\n availableShippingMethods {\n price\n rateName\n shippingMethod\n shippingSettingsId\n shippingZoneRateId\n }\n billingAddress {\n addressLine1\n addressLine2\n city {\n code\n id\n name\n }\n company\n country {\n code\n id\n name\n }\n district {\n code\n id\n name\n }\n firstName\n identityNumber\n isDefault\n lastName\n phone\n postalCode\n state {\n code\n id\n name\n }\n taxNumber\n taxOffice\n }\n cartId\n couponCode\n createdAt\n customer {\n email\n firstName\n id\n lastName\n }\n deleted\n id\n merchantId\n orderId\n orderNumber\n recoverEmailStatus\n recoveryStatus\n shippingAddress {\n addressLine1\n addressLine2\n city {\n code\n id\n name\n }\n company\n country {\n id\n code\n name\n }\n district {\n name\n id\n code\n }\n firstName\n identityNumber\n isDefault\n lastName\n phone\n postalCode\n state {\n name\n id\n code\n }\n taxNumber\n taxOffice\n }\n shippingLines {\n title\n taxValue\n price\n shippingSettingsId\n shippingZoneRateId\n }\n shippingMethod\n shippingSettingsId\n shippingZoneRateId\n status\n updatedAt\n cart {\n createdAt\n currencyCode\n customerId\n dueDate\n id\n itemCount\n items {\n createdAt\n currencyCode\n discount {\n amount\n amountType\n reason\n }\n discountPrice\n finalPrice\n id\n originalOrderLineItemId\n price\n quantity\n status\n deleted\n statusUpdatedAt\n stockLocationId\n taxValue\n updatedAt\n variant {\n barcodeList\n id\n mainImageId\n name\n productId\n sku\n variantValues {\n order\n variantTypeId\n variantTypeName\n variantValueId\n variantValueName\n }\n }\n }\n merchantId\n status\n totalPrice\n updatedAt\n }\n adjustments {\n amount\n amountType\n name\n order\n type\n }\n }\n }\n "], ["\n query getCheckoutById($id: String!) {\n getCheckoutById(id: $id) {\n totalFinalPrice\n note\n availableShippingMethods {\n price\n rateName\n shippingMethod\n shippingSettingsId\n shippingZoneRateId\n }\n billingAddress {\n addressLine1\n addressLine2\n city {\n code\n id\n name\n }\n company\n country {\n code\n id\n name\n }\n district {\n code\n id\n name\n }\n firstName\n identityNumber\n isDefault\n lastName\n phone\n postalCode\n state {\n code\n id\n name\n }\n taxNumber\n taxOffice\n }\n cartId\n couponCode\n createdAt\n customer {\n email\n firstName\n id\n lastName\n }\n deleted\n id\n merchantId\n orderId\n orderNumber\n recoverEmailStatus\n recoveryStatus\n shippingAddress {\n addressLine1\n addressLine2\n city {\n code\n id\n name\n }\n company\n country {\n id\n code\n name\n }\n district {\n name\n id\n code\n }\n firstName\n identityNumber\n isDefault\n lastName\n phone\n postalCode\n state {\n name\n id\n code\n }\n taxNumber\n taxOffice\n }\n shippingLines {\n title\n taxValue\n price\n shippingSettingsId\n shippingZoneRateId\n }\n shippingMethod\n shippingSettingsId\n shippingZoneRateId\n status\n updatedAt\n cart {\n createdAt\n currencyCode\n customerId\n dueDate\n id\n itemCount\n items {\n createdAt\n currencyCode\n discount {\n amount\n amountType\n reason\n }\n discountPrice\n finalPrice\n id\n originalOrderLineItemId\n price\n quantity\n status\n deleted\n statusUpdatedAt\n stockLocationId\n taxValue\n updatedAt\n variant {\n barcodeList\n id\n mainImageId\n name\n productId\n sku\n variantValues {\n order\n variantTypeId\n variantTypeName\n variantValueId\n variantValueName\n }\n }\n }\n merchantId\n status\n totalPrice\n updatedAt\n }\n adjustments {\n amount\n amountType\n name\n order\n type\n }\n }\n }\n "])));
|
|
26575
|
+
QUERY = src(templateObject_2$3 || (templateObject_2$3 = __makeTemplateObject(["\n query getCheckoutById($id: String!) {\n getCheckoutById(id: $id) {\n totalFinalPrice\n note\n availableShippingMethods {\n price\n rateName\n shippingMethod\n shippingSettingsId\n shippingZoneRateId\n }\n billingAddress {\n addressLine1\n addressLine2\n city {\n code\n id\n name\n }\n company\n country {\n code\n id\n name\n }\n district {\n code\n id\n name\n }\n firstName\n identityNumber\n isDefault\n lastName\n phone\n postalCode\n state {\n code\n id\n name\n }\n taxNumber\n taxOffice\n }\n cartId\n couponCode\n createdAt\n customer {\n email\n firstName\n id\n lastName\n }\n deleted\n id\n merchantId\n orderId\n orderNumber\n recoverEmailStatus\n recoveryStatus\n shippingAddress {\n addressLine1\n addressLine2\n city {\n code\n id\n name\n }\n company\n country {\n id\n code\n name\n }\n district {\n name\n id\n code\n }\n firstName\n identityNumber\n isDefault\n lastName\n phone\n postalCode\n state {\n name\n id\n code\n }\n taxNumber\n taxOffice\n }\n shippingLines {\n title\n taxValue\n price\n shippingSettingsId\n shippingZoneRateId\n }\n shippingMethod\n shippingSettingsId\n shippingZoneRateId\n status\n updatedAt\n cart {\n createdAt\n currencyCode\n customerId\n dueDate\n id\n itemCount\n items {\n createdAt\n currencyCode\n discount {\n amount\n amountType\n reason\n }\n discountPrice\n finalPrice\n id\n originalOrderLineItemId\n price\n quantity\n status\n deleted\n statusUpdatedAt\n stockLocationId\n taxValue\n updatedAt\n variant {\n barcodeList\n id\n mainImageId\n name\n productId\n sku\n variantValues {\n order\n variantTypeId\n variantTypeName\n variantValueId\n variantValueName\n }\n }\n }\n merchantId\n status\n totalPrice\n updatedAt\n }\n adjustments {\n amount\n amountType\n name\n order\n type\n couponId\n }\n }\n }\n "], ["\n query getCheckoutById($id: String!) {\n getCheckoutById(id: $id) {\n totalFinalPrice\n note\n availableShippingMethods {\n price\n rateName\n shippingMethod\n shippingSettingsId\n shippingZoneRateId\n }\n billingAddress {\n addressLine1\n addressLine2\n city {\n code\n id\n name\n }\n company\n country {\n code\n id\n name\n }\n district {\n code\n id\n name\n }\n firstName\n identityNumber\n isDefault\n lastName\n phone\n postalCode\n state {\n code\n id\n name\n }\n taxNumber\n taxOffice\n }\n cartId\n couponCode\n createdAt\n customer {\n email\n firstName\n id\n lastName\n }\n deleted\n id\n merchantId\n orderId\n orderNumber\n recoverEmailStatus\n recoveryStatus\n shippingAddress {\n addressLine1\n addressLine2\n city {\n code\n id\n name\n }\n company\n country {\n id\n code\n name\n }\n district {\n name\n id\n code\n }\n firstName\n identityNumber\n isDefault\n lastName\n phone\n postalCode\n state {\n name\n id\n code\n }\n taxNumber\n taxOffice\n }\n shippingLines {\n title\n taxValue\n price\n shippingSettingsId\n shippingZoneRateId\n }\n shippingMethod\n shippingSettingsId\n shippingZoneRateId\n status\n updatedAt\n cart {\n createdAt\n currencyCode\n customerId\n dueDate\n id\n itemCount\n items {\n createdAt\n currencyCode\n discount {\n amount\n amountType\n reason\n }\n discountPrice\n finalPrice\n id\n originalOrderLineItemId\n price\n quantity\n status\n deleted\n statusUpdatedAt\n stockLocationId\n taxValue\n updatedAt\n variant {\n barcodeList\n id\n mainImageId\n name\n productId\n sku\n variantValues {\n order\n variantTypeId\n variantTypeName\n variantValueId\n variantValueName\n }\n }\n }\n merchantId\n status\n totalPrice\n updatedAt\n }\n adjustments {\n amount\n amountType\n name\n order\n type\n couponId\n }\n }\n }\n "])));
|
|
26542
26576
|
_b.label = 1;
|
|
26543
26577
|
case 1:
|
|
26544
26578
|
_b.trys.push([1, 3, , 4]);
|
|
@@ -28176,7 +28210,7 @@ var SVGCaretDown = function (_a) {
|
|
|
28176
28210
|
};
|
|
28177
28211
|
|
|
28178
28212
|
var FormItem = observer(function (props) {
|
|
28179
|
-
var
|
|
28213
|
+
var _a = useState(function () { return new FormItemViewModel(props); }), vm = _a[0], setVM = _a[1];
|
|
28180
28214
|
useEffect(function () {
|
|
28181
28215
|
runInAction(function () {
|
|
28182
28216
|
vm.type = props.type;
|
|
@@ -28209,7 +28243,7 @@ var FormItem = observer(function (props) {
|
|
|
28209
28243
|
}, [props.errorText]);
|
|
28210
28244
|
useEffect(function () {
|
|
28211
28245
|
runInAction(function () {
|
|
28212
|
-
|
|
28246
|
+
setVM(new FormItemViewModel(props));
|
|
28213
28247
|
});
|
|
28214
28248
|
}, [props.onChange]);
|
|
28215
28249
|
return (createElement("div", { className: vm.formItemStyle },
|
|
@@ -28610,7 +28644,7 @@ var css_248z$2 = ".common-module_FormSectionTitle___Mykh {\n width: 100%;\n di
|
|
|
28610
28644
|
var commonStyles = {"FormSectionTitle":"common-module_FormSectionTitle___Mykh","Title":"common-module_Title__3JTHt","WithSubTitle":"common-module_WithSubTitle__1VHWv","SubTitle":"common-module_SubTitle__1H4kH","Grid":"common-module_Grid__2CuvH","Grid2":"common-module_Grid2__9CCag","Grid3":"common-module_Grid3__3p0jJ","FormContainer":"common-module_FormContainer__2I_Lj","mtFormRow":"common-module_mtFormRow__2tsDn","mt1":"common-module_mt1__3tpC1","mt2":"common-module_mt2__2bl5q","fadeInFromRight":"common-module_fadeInFromRight__3RYk5"};
|
|
28611
28645
|
styleInject(css_248z$2);
|
|
28612
28646
|
|
|
28613
|
-
var css_248z$3 = ".style-module_CheckoutPage__A_f2V {\n font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif;\n font-size: 16px;\n width: 100%;\n height: 100vh;\n overflow: auto;\n overflow-x: hidden;\n display: flex; }\n .style-module_CheckoutPage__A_f2V * {\n box-sizing: border-box !important; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 {\n width: 50%;\n flex: 0 0 auto;\n display: flex;\n justify-content: flex-end;\n padding-left: 20px;\n padding-right: 40px; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 {\n width: 100%;\n min-width: 400px;\n max-width: 600px;\n display: flex;\n flex-direction: column;\n justify-content: space-between;\n min-height: 100vh; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 .style-module_Space__1e2de {\n width: 100%;\n height: 100px; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 .style-module_Footer__ebdyg {\n flex: 0 0 auto;\n height: 50px;\n background-color: white;\n width: calc(100% - 1em);\n display: flex;\n align-items: center;\n border-top: 1px solid #d9d9d9; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 .style-module_Footer__ebdyg .style-module_FooterItem__1ofBc {\n font-size: 0.7em;\n margin-right: 1.4em;\n color: #737373;\n cursor: pointer;\n user-select: none; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 .style-module_Footer__ebdyg .style-module_FooterItem__1ofBc:hover {\n color: #111111; }\n @media only screen and (max-width: 1000px) {\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 .style-module_Footer__ebdyg {\n width: 100%;\n padding-left: 0.7em; } }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_Header__1vfF1 {\n width: 100%;\n height: 96px;\n display: flex;\n align-items: center;\n font-weight: 500;\n font-size: 1.5em;\n padding-left: 0.4em; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_Header__1vfF1 a {\n width: 100%; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_Header__1vfF1 .style-module_Logo__2E8Do {\n width: 100%;\n height: 64px;\n position: relative;\n user-select: none;\n cursor: pointer; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_Header__1vfF1 .style-module_Logo__2E8Do img {\n object-fit: contain;\n object-position: left;\n pointer-events: none; }\n @media only screen and (min-width: 1000px) {\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_MobileCartSummary__3NrcP {\n display: none; } }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_RowPB__3M7Tz {\n padding-bottom: 0.7em; }\n @media only screen and (max-width: 1000px) {\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 {\n width: 100%;\n justify-content: center;\n padding-right: 0px;\n padding-left: 0px; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 {\n width: 100%;\n min-width: auto;\n max-width: 100%; } }\n .style-module_CheckoutPage__A_f2V .style-module_Right__3AN4f {\n width: 50%;\n min-height: 100%;\n flex: 0 0 auto;\n background-color: #FAFAFA;\n border-left: 1px solid #d9d9d9;\n display: flex;\n padding-left: 40px;\n padding-right: 20px;\n position: sticky;\n top: 0;\n overflow-y: auto; }\n .style-module_CheckoutPage__A_f2V .style-module_Right__3AN4f .style-module_RightContent__1TcO5 {\n width: 100%;\n max-width: 600px;\n padding-top: 80px; }\n @media only screen and (max-width: 1000px) {\n .style-module_CheckoutPage__A_f2V .style-module_Right__3AN4f {\n display: none; } }\n";
|
|
28647
|
+
var css_248z$3 = ".style-module_CheckoutPage__A_f2V {\n font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif;\n font-size: 16px !important;\n width: 100%;\n height: 100vh;\n overflow: auto;\n overflow-x: hidden;\n display: flex; }\n .style-module_CheckoutPage__A_f2V * {\n box-sizing: border-box !important;\n font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif;\n font-size: 16px; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 {\n width: 50%;\n flex: 0 0 auto;\n display: flex;\n justify-content: flex-end;\n padding-left: 20px;\n padding-right: 40px; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 {\n width: 100%;\n min-width: 400px;\n max-width: 600px;\n display: flex;\n flex-direction: column;\n justify-content: space-between;\n min-height: 100vh; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 .style-module_Space__1e2de {\n width: 100%;\n height: 100px; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 .style-module_Footer__ebdyg {\n flex: 0 0 auto;\n height: 50px;\n background-color: white;\n width: calc(100% - 1em);\n display: flex;\n align-items: center;\n border-top: 1px solid #d9d9d9; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 .style-module_Footer__ebdyg .style-module_FooterItem__1ofBc {\n font-size: 0.7em;\n margin-right: 1.4em;\n color: #737373;\n cursor: pointer;\n user-select: none; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 .style-module_Footer__ebdyg .style-module_FooterItem__1ofBc:hover {\n color: #111111; }\n @media only screen and (max-width: 1000px) {\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 .style-module_Footer__ebdyg {\n width: 100%;\n padding-left: 0.7em; } }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_Header__1vfF1 {\n width: 100%;\n height: 96px;\n display: flex;\n align-items: center;\n font-weight: 500;\n font-size: 1.5em;\n padding-left: 0.4em; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_Header__1vfF1 a {\n width: 100%; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_Header__1vfF1 .style-module_Logo__2E8Do {\n width: 100%;\n height: 64px;\n position: relative;\n user-select: none;\n cursor: pointer; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_Header__1vfF1 .style-module_Logo__2E8Do img {\n object-fit: contain;\n object-position: left;\n pointer-events: none; }\n @media only screen and (min-width: 1000px) {\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_MobileCartSummary__3NrcP {\n display: none; } }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_RowPB__3M7Tz {\n padding-bottom: 0.7em; }\n @media only screen and (max-width: 1000px) {\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 {\n width: 100%;\n justify-content: center;\n padding-right: 0px;\n padding-left: 0px; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 {\n width: 100%;\n min-width: auto;\n max-width: 100%; } }\n .style-module_CheckoutPage__A_f2V .style-module_Right__3AN4f {\n width: 50%;\n min-height: 100%;\n flex: 0 0 auto;\n background-color: #FAFAFA;\n border-left: 1px solid #d9d9d9;\n display: flex;\n padding-left: 40px;\n padding-right: 20px;\n position: sticky;\n top: 0;\n overflow-y: auto; }\n .style-module_CheckoutPage__A_f2V .style-module_Right__3AN4f .style-module_RightContent__1TcO5 {\n width: 100%;\n max-width: 600px;\n padding-top: 80px; }\n @media only screen and (max-width: 1000px) {\n .style-module_CheckoutPage__A_f2V .style-module_Right__3AN4f {\n display: none; } }\n";
|
|
28614
28648
|
var styles$2 = {"CheckoutPage":"style-module_CheckoutPage__A_f2V","Left":"style-module_Left__2dWz6","LeftContent":"style-module_LeftContent__1Tyb7","Space":"style-module_Space__1e2de","Footer":"style-module_Footer__ebdyg","FooterItem":"style-module_FooterItem__1ofBc","Header":"style-module_Header__1vfF1","Logo":"style-module_Logo__2E8Do","MobileCartSummary":"style-module_MobileCartSummary__3NrcP","RowPB":"style-module_RowPB__3M7Tz","Right":"style-module_Right__3AN4f","RightContent":"style-module_RightContent__1TcO5"};
|
|
28615
28649
|
styleInject(css_248z$3);
|
|
28616
28650
|
|
|
@@ -28651,16 +28685,17 @@ var AddressForm$1 = observer(function (_a) {
|
|
|
28651
28685
|
IkasCheckoutRequirementEnum.INVISIBLE && (createElement(FormItem, { type: FormItemType.TEXT, label: "TC Kimlik No", value: vm.identityNumber || "", onChange: vm.onIdentityNumberChange, hasError: isErrorsVisible && !(validationResult === null || validationResult === void 0 ? void 0 : validationResult.identityNumber), errorText: "TC kimlik no girin" })))));
|
|
28652
28686
|
});
|
|
28653
28687
|
|
|
28654
|
-
var css_248z$4 = ".style-module_Button__1UPMN {\n cursor: pointer;\n border: 1px transparent solid;\n border-radius: 6px;\n font-weight: 500;\n text-align: center;\n position: relative;\n transition: all .2s;\n display: flex;\n justify-content: center;\n align-items: center; }\n .style-module_Button__1UPMN.style-module_Large__2wPlw {\n height: 64px;\n padding: 0 1.7em; }\n .style-module_Button__1UPMN.style-module_Dark__1Z_hs {\n background-color: #111111;\n color: white; }\n .style-module_Button__1UPMN.style-module_Disabled__3HYF_ {\n background-color: #c8c8c8;\n color: #
|
|
28655
|
-
var styles$3 = {"Button":"style-module_Button__1UPMN","Large":"style-module_Large__2wPlw","Dark":"style-module_Dark__1Z_hs","Disabled":"style-module_Disabled__3HYF_","FullWidthMobile":"style-module_FullWidthMobile__3MTFv","loader":"style-module_loader__3v6kq","load8":"style-module_load8__2z7nj"};
|
|
28688
|
+
var css_248z$4 = ".style-module_Button__1UPMN {\n cursor: pointer;\n border: 1px transparent solid;\n border-radius: 6px;\n font-weight: 500;\n text-align: center;\n position: relative;\n transition: all .2s;\n display: flex;\n justify-content: center;\n align-items: center; }\n .style-module_Button__1UPMN:focus {\n outline: 0; }\n .style-module_Button__1UPMN.style-module_Large__2wPlw {\n height: 64px;\n padding: 0 1.7em; }\n .style-module_Button__1UPMN.style-module_Medium__3t0pu {\n height: 3em;\n padding: 0.5em 1em; }\n .style-module_Button__1UPMN.style-module_Dark__1Z_hs {\n background-color: #111111;\n color: white; }\n .style-module_Button__1UPMN.style-module_Disabled__3HYF_ {\n background-color: #c8c8c8;\n color: #FAFAFA;\n pointer-events: none; }\n @media only screen and (max-width: 1000px) {\n .style-module_Button__1UPMN.style-module_FullWidthMobile__3MTFv {\n width: 100%; } }\n .style-module_Button__1UPMN .style-module_loader__3v6kq,\n .style-module_Button__1UPMN .style-module_loader__3v6kq:after {\n border-radius: 50%;\n width: 5em;\n height: 5em; }\n .style-module_Button__1UPMN .style-module_loader__3v6kq {\n font-size: 6px;\n position: relative;\n text-indent: -9999em;\n border-top: 0.5em solid rgba(255, 255, 255, 0.2);\n border-right: 0.5em solid rgba(255, 255, 255, 0.2);\n border-bottom: 0.5em solid rgba(255, 255, 255, 0.2);\n border-left: 0.5em solid #ffffff;\n -webkit-transform: translateZ(0);\n -ms-transform: translateZ(0);\n transform: translateZ(0);\n -webkit-animation: style-module_load8__2z7nj 1.1s infinite linear;\n animation: style-module_load8__2z7nj 1.1s infinite linear; }\n\n@-webkit-keyframes style-module_load8__2z7nj {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg); }\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg); } }\n\n@keyframes style-module_load8__2z7nj {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg); }\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg); } }\n";
|
|
28689
|
+
var styles$3 = {"Button":"style-module_Button__1UPMN","Large":"style-module_Large__2wPlw","Medium":"style-module_Medium__3t0pu","Dark":"style-module_Dark__1Z_hs","Disabled":"style-module_Disabled__3HYF_","FullWidthMobile":"style-module_FullWidthMobile__3MTFv","loader":"style-module_loader__3v6kq","load8":"style-module_load8__2z7nj"};
|
|
28656
28690
|
styleInject(css_248z$4);
|
|
28657
28691
|
|
|
28658
28692
|
var Button = observer(function (_a) {
|
|
28659
|
-
var text = _a.text, onClick = _a.onClick, isLoading = _a.isLoading;
|
|
28660
|
-
return (createElement("button", { type: "button", className: [
|
|
28693
|
+
var text = _a.text, style = _a.style, onClick = _a.onClick, size = _a.size, isLoading = _a.isLoading, isDisabled = _a.isDisabled;
|
|
28694
|
+
return (createElement("button", { style: style, type: "button", className: [
|
|
28661
28695
|
styles$3.Button,
|
|
28662
28696
|
styles$3.Dark,
|
|
28663
|
-
styles$3.Large,
|
|
28697
|
+
size === "medium" ? styles$3.Medium : styles$3.Large,
|
|
28698
|
+
isDisabled ? styles$3.Disabled : "",
|
|
28664
28699
|
styles$3.FullWidthMobile,
|
|
28665
28700
|
].join(" "), onClick: !isLoading ? onClick : undefined }, isLoading ? (createElement("div", { className: styles$3.loader })) : (createElement("span", null, text))));
|
|
28666
28701
|
});
|
|
@@ -29008,8 +29043,8 @@ var CartItem = observer(function (_a) {
|
|
|
29008
29043
|
createElement("div", { className: styles$e.Price }, formatMoney(cartItem.finalPriceWithQuantity, currencyCode))));
|
|
29009
29044
|
});
|
|
29010
29045
|
|
|
29011
|
-
var css_248z$g = ".style-module_CartSummary__30RcF {\n background-color: #FAFAFA;\n padding: 0 0.7em;\n border-bottom: 1px solid #d9d9d9
|
|
29012
|
-
var styles$f = {"CartSummary":"style-module_CartSummary__30RcF","AllowExpand":"style-module_AllowExpand__3kDXF","ExpandHeader":"style-module_ExpandHeader__2ICjA","Left":"style-module_Left__A54sv","Label":"style-module_Label__3E7LF","ArrowDown":"style-module_ArrowDown__2ET-d","Rotated":"style-module_Rotated__3sgbm","Price":"style-module_Price__sosrJ","Expanded":"style-module_Expanded__3VBL2","DetailsContainer":"style-module_DetailsContainer__FBBIP","Details":"style-module_Details__3-X_i","Divider":"style-module_Divider__2d0Zk","Coupon":"style-module_Coupon__3pdQA","
|
|
29046
|
+
var css_248z$g = ".style-module_CartSummary__30RcF {\n background-color: #FAFAFA;\n padding: 0 0.7em;\n overflow: hidden;\n border-bottom: 1px solid #d9d9d9; }\n .style-module_CartSummary__30RcF.style-module_AllowExpand__3kDXF {\n border-top: 1px solid #d9d9d9; }\n .style-module_CartSummary__30RcF .style-module_ExpandHeader__2ICjA {\n display: flex;\n justify-content: space-between;\n align-items: center;\n height: 56px;\n padding: 0 1em;\n width: calc(100% + 1.4em);\n margin-left: -0.7em;\n border-bottom: 1px solid transparent;\n transition: border-bottom .3s;\n user-select: none; }\n .style-module_CartSummary__30RcF .style-module_ExpandHeader__2ICjA .style-module_Left__A54sv {\n display: flex;\n align-items: center;\n font-size: 0.8em; }\n .style-module_CartSummary__30RcF .style-module_ExpandHeader__2ICjA .style-module_Left__A54sv .style-module_Label__3E7LF {\n margin-left: 0.5em; }\n .style-module_CartSummary__30RcF .style-module_ExpandHeader__2ICjA .style-module_Left__A54sv .style-module_ArrowDown__2ET-d {\n transition: all .3s; }\n .style-module_CartSummary__30RcF .style-module_ExpandHeader__2ICjA .style-module_Left__A54sv .style-module_ArrowDown__2ET-d.style-module_Rotated__3sgbm {\n transform: rotate(-180deg); }\n .style-module_CartSummary__30RcF .style-module_ExpandHeader__2ICjA .style-module_Price__sosrJ {\n font-weight: 500; }\n .style-module_CartSummary__30RcF .style-module_ExpandHeader__2ICjA.style-module_Expanded__3VBL2 {\n border-bottom: 1px solid #d9d9d9; }\n .style-module_CartSummary__30RcF .style-module_DetailsContainer__FBBIP {\n overflow: hidden;\n width: 100%;\n transition: height .3s ease-in-out; }\n .style-module_CartSummary__30RcF .style-module_Details__3-X_i {\n overflow: hidden; }\n .style-module_CartSummary__30RcF .style-module_Divider__2d0Zk {\n width: 100%;\n height: 1px;\n margin: auto;\n background-color: #d9d9d9; }\n .style-module_CartSummary__30RcF .style-module_CouponContainer__1zCXG {\n padding: 1.2em 0.1em;\n border-bottom: 1px solid #d9d9d9; }\n .style-module_CartSummary__30RcF .style-module_Coupon__3pdQA {\n display: flex; }\n .style-module_CartSummary__30RcF .style-module_AppliedCoupon__37qv8 {\n display: inline-flex;\n align-items: center;\n padding: 0.65em;\n margin-top: 0.85em;\n color: #333333;\n background-color: rgba(113, 113, 113, 0.11);\n user-select: none;\n border-radius: 6px; }\n .style-module_CartSummary__30RcF .style-module_AppliedCoupon__37qv8 .style-module_AppliedCouponCode__2o7pn {\n margin-left: 0.25em;\n margin-right: 0.25em;\n font-weight: 500;\n position: relative;\n top: -1px; }\n .style-module_CartSummary__30RcF .style-module_AppliedCoupon__37qv8 .style-module_Cross__2dc3d {\n color: #545454;\n cursor: pointer;\n position: relative;\n bottom: -1px; }\n .style-module_CartSummary__30RcF .style-module_AppliedCoupon__37qv8 .style-module_Cross__2dc3d:hover {\n color: #333333; }\n .style-module_CartSummary__30RcF .style-module_SubTotalInfo__1QMnr {\n padding: 1.2em 0;\n border-bottom: 1px solid #d9d9d9; }\n .style-module_CartSummary__30RcF .style-module_SubTotalInfo__1QMnr .style-module_InfoRow__3eZdJ {\n display: flex;\n justify-content: space-between;\n align-items: center;\n margin-bottom: 0.3em; }\n .style-module_CartSummary__30RcF .style-module_SubTotalInfo__1QMnr .style-module_InfoRow__3eZdJ .style-module_Label__3E7LF {\n color: #545454;\n font-size: 0.8em; }\n .style-module_CartSummary__30RcF .style-module_SubTotalInfo__1QMnr .style-module_InfoRow__3eZdJ .style-module_Value__3mBvk {\n font-size: 0.8em; }\n .style-module_CartSummary__30RcF .style-module_SubTotalInfo__1QMnr .style-module_InfoRow__3eZdJ:last-of-type {\n margin-bottom: 0; }\n .style-module_CartSummary__30RcF .style-module_TotalContainer__36DNt {\n display: flex;\n justify-content: space-between;\n align-items: center;\n padding: 1.5em 0; }\n .style-module_CartSummary__30RcF .style-module_TotalContainer__36DNt .style-module_TitleContainer__3ptQE .style-module_Title__16M5E {\n font-size: 1em; }\n .style-module_CartSummary__30RcF .style-module_TotalContainer__36DNt .style-module_TitleContainer__3ptQE .style-module_Tax__17g6O {\n font-size: 0.8em;\n color: #545454; }\n .style-module_CartSummary__30RcF .style-module_TotalContainer__36DNt .style-module_TotalPrice__2s7DC {\n font-size: 1.5em;\n font-weight: 500; }\n @media only screen and (min-width: 1000px) {\n .style-module_CartSummary__30RcF {\n border-bottom: none; }\n .style-module_CartSummary__30RcF .style-module_SubTotalInfo__1QMnr .style-module_InfoRow__3eZdJ .style-module_Label__3E7LF,\n .style-module_CartSummary__30RcF .style-module_SubTotalInfo__1QMnr .style-module_InfoRow__3eZdJ .style-module_Value__3mBvk {\n font-size: 0.9em; } }\n";
|
|
29047
|
+
var styles$f = {"CartSummary":"style-module_CartSummary__30RcF","AllowExpand":"style-module_AllowExpand__3kDXF","ExpandHeader":"style-module_ExpandHeader__2ICjA","Left":"style-module_Left__A54sv","Label":"style-module_Label__3E7LF","ArrowDown":"style-module_ArrowDown__2ET-d","Rotated":"style-module_Rotated__3sgbm","Price":"style-module_Price__sosrJ","Expanded":"style-module_Expanded__3VBL2","DetailsContainer":"style-module_DetailsContainer__FBBIP","Details":"style-module_Details__3-X_i","Divider":"style-module_Divider__2d0Zk","CouponContainer":"style-module_CouponContainer__1zCXG","Coupon":"style-module_Coupon__3pdQA","AppliedCoupon":"style-module_AppliedCoupon__37qv8","AppliedCouponCode":"style-module_AppliedCouponCode__2o7pn","Cross":"style-module_Cross__2dc3d","SubTotalInfo":"style-module_SubTotalInfo__1QMnr","InfoRow":"style-module_InfoRow__3eZdJ","Value":"style-module_Value__3mBvk","TotalContainer":"style-module_TotalContainer__36DNt","TitleContainer":"style-module_TitleContainer__3ptQE","Title":"style-module_Title__16M5E","Tax":"style-module_Tax__17g6O","TotalPrice":"style-module_TotalPrice__2s7DC"};
|
|
29013
29048
|
styleInject(css_248z$g);
|
|
29014
29049
|
|
|
29015
29050
|
var SVGArrowDown = function (_a) {
|
|
@@ -29026,6 +29061,20 @@ var SVGShoppingBag = function (_a) {
|
|
|
29026
29061
|
createElement("path", { fill: "currentColor", d: "M4 16V4H2V2h3a1 1 0 0 1 1 1v12h12.438l2-8H8V5h13.72a1 1 0 0 1 .97 1.243l-2.5 10a1 1 0 0 1-.97.757H5a1 1 0 0 1-1-1zm2 7a2 2 0 1 1 0-4 2 2 0 0 1 0 4zm12 0a2 2 0 1 1 0-4 2 2 0 0 1 0 4z" })));
|
|
29027
29062
|
};
|
|
29028
29063
|
|
|
29064
|
+
var SVGTag = function (_a) {
|
|
29065
|
+
var className = _a.className;
|
|
29066
|
+
return (createElement("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", width: "24", height: "24", className: className },
|
|
29067
|
+
createElement("path", { fill: "none", d: "M0 0h24v24H0z" }),
|
|
29068
|
+
createElement("path", { fill: "currentColor", d: "M10.9 2.1l9.899 1.415 1.414 9.9-9.192 9.192a1 1 0 0 1-1.414 0l-9.9-9.9a1 1 0 0 1 0-1.414L10.9 2.1zm2.828 8.486a2 2 0 1 0 2.828-2.829 2 2 0 0 0-2.828 2.829z" })));
|
|
29069
|
+
};
|
|
29070
|
+
|
|
29071
|
+
var SVGCross = function (_a) {
|
|
29072
|
+
var className = _a.className;
|
|
29073
|
+
return (createElement("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", width: "24", height: "24", className: className },
|
|
29074
|
+
createElement("path", { fill: "none", d: "M0 0h24v24H0z" }),
|
|
29075
|
+
createElement("path", { fill: "currentColor", d: "M12 10.586l4.95-4.95 1.414 1.414-4.95 4.95 4.95 4.95-1.414 1.414-4.95-4.95-4.95 4.95-1.414-1.414 4.95-4.95-4.95-4.95L7.05 5.636z" })));
|
|
29076
|
+
};
|
|
29077
|
+
|
|
29029
29078
|
var CartSummary = observer(function (_a) {
|
|
29030
29079
|
var _b;
|
|
29031
29080
|
var vm = _a.vm, allowExpand = _a.allowExpand;
|
|
@@ -29083,6 +29132,7 @@ var CartSummary = observer(function (_a) {
|
|
|
29083
29132
|
cart.items.map(function (item, index) { return (createElement("div", { key: index },
|
|
29084
29133
|
createElement(CartItem, { cartItem: item, currencyCode: cart.currencyCode }),
|
|
29085
29134
|
createElement("div", { className: styles$f.Divider }))); }),
|
|
29135
|
+
createElement(Coupon, { vm: vm }),
|
|
29086
29136
|
createElement("div", { className: styles$f.SubTotalInfo },
|
|
29087
29137
|
createElement("div", { className: styles$f.InfoRow },
|
|
29088
29138
|
createElement("div", { className: styles$f.Label }, "Alt Toplam"),
|
|
@@ -29097,7 +29147,10 @@ var CartSummary = observer(function (_a) {
|
|
|
29097
29147
|
createElement("div", { className: styles$f.Value }, formatMoney(vm.installmentExtraPrice, cart.currencyCode)))),
|
|
29098
29148
|
sortBy_1(vm.checkout.adjustments || [], "order").map(function (adjustment, index) { return (createElement("div", { className: styles$f.InfoRow, key: index },
|
|
29099
29149
|
createElement("div", { className: styles$f.Label }, adjustment.name),
|
|
29100
|
-
createElement("div", { className: styles$f.Value },
|
|
29150
|
+
createElement("div", { className: styles$f.Value },
|
|
29151
|
+
createElement("span", null, adjustment.type === "DECREMENT" ? "- " : ""),
|
|
29152
|
+
" ",
|
|
29153
|
+
createElement("span", null, formatMoney(adjustment.amount, cart.currencyCode))))); })),
|
|
29101
29154
|
createElement("div", { className: styles$f.TotalContainer },
|
|
29102
29155
|
createElement("div", { className: styles$f.TitleContainer },
|
|
29103
29156
|
createElement("div", { className: styles$f.Title }, "Toplam"),
|
|
@@ -29106,6 +29159,51 @@ var CartSummary = observer(function (_a) {
|
|
|
29106
29159
|
createElement("div", { className: styles$f.TotalPrice }, formatMoney(vm.installmentPrice ||
|
|
29107
29160
|
vm.checkout.totalFinalPrice ||
|
|
29108
29161
|
cart.totalPrice, cart.currencyCode)))))));
|
|
29162
|
+
});
|
|
29163
|
+
var Coupon = observer(function (_a) {
|
|
29164
|
+
var vm = _a.vm;
|
|
29165
|
+
var _b = useState(""), couponCode = _b[0], setCouponCode = _b[1];
|
|
29166
|
+
var _c = useState(false), isLoadingCoupon = _c[0], setLoadingCoupon = _c[1];
|
|
29167
|
+
var onCouponApply = function () { return __awaiter(void 0, void 0, void 0, function () {
|
|
29168
|
+
return __generator(this, function (_a) {
|
|
29169
|
+
switch (_a.label) {
|
|
29170
|
+
case 0:
|
|
29171
|
+
vm.checkout.couponCode = couponCode;
|
|
29172
|
+
setLoadingCoupon(true);
|
|
29173
|
+
return [4 /*yield*/, vm.onCouponCodeApply()];
|
|
29174
|
+
case 1:
|
|
29175
|
+
_a.sent();
|
|
29176
|
+
setLoadingCoupon(false);
|
|
29177
|
+
setCouponCode("");
|
|
29178
|
+
return [2 /*return*/];
|
|
29179
|
+
}
|
|
29180
|
+
});
|
|
29181
|
+
}); };
|
|
29182
|
+
var onClearCouponCode = function () { return __awaiter(void 0, void 0, void 0, function () {
|
|
29183
|
+
return __generator(this, function (_a) {
|
|
29184
|
+
switch (_a.label) {
|
|
29185
|
+
case 0:
|
|
29186
|
+
vm.checkout.couponCode = null;
|
|
29187
|
+
setLoadingCoupon(true);
|
|
29188
|
+
return [4 /*yield*/, vm.onCouponCodeApply()];
|
|
29189
|
+
case 1:
|
|
29190
|
+
_a.sent();
|
|
29191
|
+
setLoadingCoupon(false);
|
|
29192
|
+
return [2 /*return*/];
|
|
29193
|
+
}
|
|
29194
|
+
});
|
|
29195
|
+
}); };
|
|
29196
|
+
if (vm.step === CheckoutStep.SUCCESS)
|
|
29197
|
+
return null;
|
|
29198
|
+
return (createElement("div", { className: styles$f.CouponContainer },
|
|
29199
|
+
createElement("div", { className: styles$f.Coupon },
|
|
29200
|
+
createElement(FormItem, { type: FormItemType.TEXT, label: "Hediye kartı veya indirim kodu", value: couponCode, onChange: function (value) { return setCouponCode(value); } }),
|
|
29201
|
+
createElement(Button, { text: "Uygula", onClick: onCouponApply, isDisabled: !couponCode, isLoading: isLoadingCoupon, size: "medium", style: { marginLeft: "0.5em", maxWidth: "80px" } })),
|
|
29202
|
+
!!vm.checkout.appliedCouponCode && (createElement("div", { className: styles$f.AppliedCoupon },
|
|
29203
|
+
createElement(SVGTag, null),
|
|
29204
|
+
createElement("div", { className: styles$f.AppliedCouponCode }, vm.checkout.appliedCouponCode),
|
|
29205
|
+
createElement("div", { className: styles$f.Cross, onClick: onClearCouponCode },
|
|
29206
|
+
createElement(SVGCross, null))))));
|
|
29109
29207
|
});
|
|
29110
29208
|
|
|
29111
29209
|
var css_248z$h = ".style-module_Breadcrumbs__1jIPZ {\n display: flex;\n align-items: center;\n padding: 0 0.7em; }\n .style-module_Breadcrumbs__1jIPZ .style-module_Breadcrumb__2qdy3 {\n font-size: 0.8em;\n padding: 1em 0;\n display: flex;\n align-items: center;\n user-select: none;\n cursor: pointer;\n color: #545454; }\n .style-module_Breadcrumbs__1jIPZ .style-module_Breadcrumb__2qdy3 .style-module_icon__3Rq6w {\n transform: rotate(180deg); }\n .style-module_Breadcrumbs__1jIPZ .style-module_Breadcrumb__2qdy3.style-module_Active__3KwX8 {\n color: #111111;\n font-weight: 500; }\n";
|
|
@@ -29136,7 +29234,7 @@ var Breadcrumbs = observer(function (_a) {
|
|
|
29136
29234
|
catch (err) { }
|
|
29137
29235
|
};
|
|
29138
29236
|
return (createElement("div", { className: styles$g.Breadcrumbs },
|
|
29139
|
-
createElement("div", { className: styles$g.Breadcrumb, onClick: vm.
|
|
29237
|
+
createElement("div", { className: styles$g.Breadcrumb, onClick: vm.onGoToCartClick },
|
|
29140
29238
|
createElement("span", null, "Sepet"),
|
|
29141
29239
|
createElement("span", { className: styles$g.icon },
|
|
29142
29240
|
createElement(SVGArrowLeft, null))),
|
package/build/index.js
CHANGED
|
@@ -11453,6 +11453,8 @@ var IkasCheckout = /** @class */ (function () {
|
|
|
11453
11453
|
this.totalFinalPrice = null;
|
|
11454
11454
|
this.adjustments = null;
|
|
11455
11455
|
this.note = null;
|
|
11456
|
+
// Extra
|
|
11457
|
+
this.appliedCouponCode = null;
|
|
11456
11458
|
this.id = data.id;
|
|
11457
11459
|
this.createdAt = data.createdAt;
|
|
11458
11460
|
this.updatedAt = data.updatedAt;
|
|
@@ -11467,14 +11469,15 @@ var IkasCheckout = /** @class */ (function () {
|
|
|
11467
11469
|
this.customer = data.customer;
|
|
11468
11470
|
this.billingAddress = data.billingAddress
|
|
11469
11471
|
? new IkasOrderAddress(data.billingAddress)
|
|
11470
|
-
:
|
|
11472
|
+
: new IkasOrderAddress();
|
|
11471
11473
|
this.shippingAddress = data.shippingAddress
|
|
11472
11474
|
? new IkasOrderAddress(data.shippingAddress)
|
|
11473
|
-
:
|
|
11475
|
+
: new IkasOrderAddress();
|
|
11474
11476
|
this.shippingLines = data.shippingLines || [];
|
|
11475
11477
|
this.shippingMethod = data.shippingMethod || exports.IkasShippingMethod.NO_SHIPMENT;
|
|
11476
11478
|
this.status = data.status || exports.IkasCheckoutStatus.OPEN;
|
|
11477
11479
|
this.couponCode = data.couponCode;
|
|
11480
|
+
this.appliedCouponCode = data.couponCode;
|
|
11478
11481
|
this.recoverEmailStatus = data.recoverEmailStatus;
|
|
11479
11482
|
this.recoveryStatus = data.recoveryStatus;
|
|
11480
11483
|
this.totalFinalPrice = data.totalFinalPrice;
|
|
@@ -16484,6 +16487,33 @@ var CheckoutViewModel = /** @class */ (function () {
|
|
|
16484
16487
|
this.onCouponCodeChange = function (value) {
|
|
16485
16488
|
_this.checkout.couponCode = value;
|
|
16486
16489
|
};
|
|
16490
|
+
this.onCouponCodeApply = function () { return __awaiter(_this, void 0, void 0, function () {
|
|
16491
|
+
var newCheckout, oldCheckout;
|
|
16492
|
+
return __generator(this, function (_a) {
|
|
16493
|
+
switch (_a.label) {
|
|
16494
|
+
case 0:
|
|
16495
|
+
_a.trys.push([0, 3, , 4]);
|
|
16496
|
+
return [4 /*yield*/, this.saveCheckout()];
|
|
16497
|
+
case 1:
|
|
16498
|
+
_a.sent();
|
|
16499
|
+
return [4 /*yield*/, IkasCheckoutAPI.getCheckoutById(this.checkout.id)];
|
|
16500
|
+
case 2:
|
|
16501
|
+
newCheckout = _a.sent();
|
|
16502
|
+
if (newCheckout) {
|
|
16503
|
+
oldCheckout = this.checkout;
|
|
16504
|
+
this.checkout = newCheckout;
|
|
16505
|
+
this.checkout.customer = oldCheckout.customer;
|
|
16506
|
+
this.checkout.shippingAddress = oldCheckout.shippingAddress;
|
|
16507
|
+
this.checkout.billingAddress = oldCheckout.billingAddress;
|
|
16508
|
+
}
|
|
16509
|
+
return [3 /*break*/, 4];
|
|
16510
|
+
case 3:
|
|
16511
|
+
_a.sent();
|
|
16512
|
+
return [3 /*break*/, 4];
|
|
16513
|
+
case 4: return [2 /*return*/];
|
|
16514
|
+
}
|
|
16515
|
+
});
|
|
16516
|
+
}); };
|
|
16487
16517
|
this.onSelectedShippingAddressIdChange = function (value) {
|
|
16488
16518
|
var _a;
|
|
16489
16519
|
_this.selectedShippingAddressId = value;
|
|
@@ -16573,11 +16603,14 @@ var CheckoutViewModel = /** @class */ (function () {
|
|
|
16573
16603
|
_this.cardData.cvv = value;
|
|
16574
16604
|
};
|
|
16575
16605
|
// CREDIT CARD END
|
|
16606
|
+
this.onGoToCartClick = function () {
|
|
16607
|
+
_this.router.push("/cart");
|
|
16608
|
+
};
|
|
16576
16609
|
this.onBackToShoppingClick = function () {
|
|
16577
16610
|
_this.router.push("/");
|
|
16578
16611
|
};
|
|
16579
16612
|
this.onProceedToShippingClick = function () { return __awaiter(_this, void 0, void 0, function () {
|
|
16580
|
-
var newAddress, customer,
|
|
16613
|
+
var newAddress, customer, err_3;
|
|
16581
16614
|
return __generator(this, function (_a) {
|
|
16582
16615
|
switch (_a.label) {
|
|
16583
16616
|
case 0:
|
|
@@ -16607,12 +16640,12 @@ var CheckoutViewModel = /** @class */ (function () {
|
|
|
16607
16640
|
this.changeStep(CheckoutStep.SHIPPING);
|
|
16608
16641
|
return [3 /*break*/, 7];
|
|
16609
16642
|
case 6:
|
|
16610
|
-
|
|
16611
|
-
if (
|
|
16612
|
-
this.error =
|
|
16643
|
+
err_3 = _a.sent();
|
|
16644
|
+
if (err_3.type) {
|
|
16645
|
+
this.error = err_3;
|
|
16613
16646
|
}
|
|
16614
16647
|
else {
|
|
16615
|
-
console.log(
|
|
16648
|
+
console.log(err_3);
|
|
16616
16649
|
this.error = {
|
|
16617
16650
|
type: ErrorType.UNKNOWN,
|
|
16618
16651
|
};
|
|
@@ -16624,7 +16657,7 @@ var CheckoutViewModel = /** @class */ (function () {
|
|
|
16624
16657
|
});
|
|
16625
16658
|
}); };
|
|
16626
16659
|
this.onProceedToPaymentClick = function () { return __awaiter(_this, void 0, void 0, function () {
|
|
16627
|
-
var
|
|
16660
|
+
var err_4;
|
|
16628
16661
|
return __generator(this, function (_a) {
|
|
16629
16662
|
switch (_a.label) {
|
|
16630
16663
|
case 0:
|
|
@@ -16644,12 +16677,12 @@ var CheckoutViewModel = /** @class */ (function () {
|
|
|
16644
16677
|
this.changeStep(CheckoutStep.PAYMENT);
|
|
16645
16678
|
return [3 /*break*/, 4];
|
|
16646
16679
|
case 3:
|
|
16647
|
-
|
|
16648
|
-
if (
|
|
16649
|
-
this.error =
|
|
16680
|
+
err_4 = _a.sent();
|
|
16681
|
+
if (err_4.type) {
|
|
16682
|
+
this.error = err_4;
|
|
16650
16683
|
}
|
|
16651
16684
|
else {
|
|
16652
|
-
console.log(
|
|
16685
|
+
console.log(err_4);
|
|
16653
16686
|
this.error = {
|
|
16654
16687
|
type: ErrorType.UNKNOWN,
|
|
16655
16688
|
};
|
|
@@ -16661,7 +16694,7 @@ var CheckoutViewModel = /** @class */ (function () {
|
|
|
16661
16694
|
});
|
|
16662
16695
|
}); };
|
|
16663
16696
|
this.performPayment = function () { return __awaiter(_this, void 0, void 0, function () {
|
|
16664
|
-
var response, transactionStatus,
|
|
16697
|
+
var response, transactionStatus, err_5;
|
|
16665
16698
|
var _a;
|
|
16666
16699
|
return __generator(this, function (_b) {
|
|
16667
16700
|
switch (_b.label) {
|
|
@@ -16712,10 +16745,10 @@ var CheckoutViewModel = /** @class */ (function () {
|
|
|
16712
16745
|
}
|
|
16713
16746
|
return [3 /*break*/, 6];
|
|
16714
16747
|
case 5:
|
|
16715
|
-
|
|
16716
|
-
if (
|
|
16717
|
-
console.log(
|
|
16718
|
-
this.error =
|
|
16748
|
+
err_5 = _b.sent();
|
|
16749
|
+
if (err_5.type) {
|
|
16750
|
+
console.log(err_5);
|
|
16751
|
+
this.error = err_5;
|
|
16719
16752
|
}
|
|
16720
16753
|
else {
|
|
16721
16754
|
this.error = {
|
|
@@ -21145,6 +21178,7 @@ var IkasProductList = /** @class */ (function () {
|
|
|
21145
21178
|
this.data = this.data.concat(data);
|
|
21146
21179
|
this._count = response.count;
|
|
21147
21180
|
this._page = this.page + 1;
|
|
21181
|
+
this._minPage = this._page;
|
|
21148
21182
|
return [3 /*break*/, 5];
|
|
21149
21183
|
case 3:
|
|
21150
21184
|
err_3 = _a.sent();
|
|
@@ -26517,7 +26551,7 @@ var IkasCheckoutAPI = /** @class */ (function () {
|
|
|
26517
26551
|
return __generator(this, function (_b) {
|
|
26518
26552
|
switch (_b.label) {
|
|
26519
26553
|
case 0:
|
|
26520
|
-
QUERY = src(templateObject_2$3 || (templateObject_2$3 = __makeTemplateObject(["\n query getCheckoutById($id: String!) {\n getCheckoutById(id: $id) {\n totalFinalPrice\n note\n availableShippingMethods {\n price\n rateName\n shippingMethod\n shippingSettingsId\n shippingZoneRateId\n }\n billingAddress {\n addressLine1\n addressLine2\n city {\n code\n id\n name\n }\n company\n country {\n code\n id\n name\n }\n district {\n code\n id\n name\n }\n firstName\n identityNumber\n isDefault\n lastName\n phone\n postalCode\n state {\n code\n id\n name\n }\n taxNumber\n taxOffice\n }\n cartId\n couponCode\n createdAt\n customer {\n email\n firstName\n id\n lastName\n }\n deleted\n id\n merchantId\n orderId\n orderNumber\n recoverEmailStatus\n recoveryStatus\n shippingAddress {\n addressLine1\n addressLine2\n city {\n code\n id\n name\n }\n company\n country {\n id\n code\n name\n }\n district {\n name\n id\n code\n }\n firstName\n identityNumber\n isDefault\n lastName\n phone\n postalCode\n state {\n name\n id\n code\n }\n taxNumber\n taxOffice\n }\n shippingLines {\n title\n taxValue\n price\n shippingSettingsId\n shippingZoneRateId\n }\n shippingMethod\n shippingSettingsId\n shippingZoneRateId\n status\n updatedAt\n cart {\n createdAt\n currencyCode\n customerId\n dueDate\n id\n itemCount\n items {\n createdAt\n currencyCode\n discount {\n amount\n amountType\n reason\n }\n discountPrice\n finalPrice\n id\n originalOrderLineItemId\n price\n quantity\n status\n deleted\n statusUpdatedAt\n stockLocationId\n taxValue\n updatedAt\n variant {\n barcodeList\n id\n mainImageId\n name\n productId\n sku\n variantValues {\n order\n variantTypeId\n variantTypeName\n variantValueId\n variantValueName\n }\n }\n }\n merchantId\n status\n totalPrice\n updatedAt\n }\n adjustments {\n amount\n amountType\n name\n order\n type\n }\n }\n }\n "], ["\n query getCheckoutById($id: String!) {\n getCheckoutById(id: $id) {\n totalFinalPrice\n note\n availableShippingMethods {\n price\n rateName\n shippingMethod\n shippingSettingsId\n shippingZoneRateId\n }\n billingAddress {\n addressLine1\n addressLine2\n city {\n code\n id\n name\n }\n company\n country {\n code\n id\n name\n }\n district {\n code\n id\n name\n }\n firstName\n identityNumber\n isDefault\n lastName\n phone\n postalCode\n state {\n code\n id\n name\n }\n taxNumber\n taxOffice\n }\n cartId\n couponCode\n createdAt\n customer {\n email\n firstName\n id\n lastName\n }\n deleted\n id\n merchantId\n orderId\n orderNumber\n recoverEmailStatus\n recoveryStatus\n shippingAddress {\n addressLine1\n addressLine2\n city {\n code\n id\n name\n }\n company\n country {\n id\n code\n name\n }\n district {\n name\n id\n code\n }\n firstName\n identityNumber\n isDefault\n lastName\n phone\n postalCode\n state {\n name\n id\n code\n }\n taxNumber\n taxOffice\n }\n shippingLines {\n title\n taxValue\n price\n shippingSettingsId\n shippingZoneRateId\n }\n shippingMethod\n shippingSettingsId\n shippingZoneRateId\n status\n updatedAt\n cart {\n createdAt\n currencyCode\n customerId\n dueDate\n id\n itemCount\n items {\n createdAt\n currencyCode\n discount {\n amount\n amountType\n reason\n }\n discountPrice\n finalPrice\n id\n originalOrderLineItemId\n price\n quantity\n status\n deleted\n statusUpdatedAt\n stockLocationId\n taxValue\n updatedAt\n variant {\n barcodeList\n id\n mainImageId\n name\n productId\n sku\n variantValues {\n order\n variantTypeId\n variantTypeName\n variantValueId\n variantValueName\n }\n }\n }\n merchantId\n status\n totalPrice\n updatedAt\n }\n adjustments {\n amount\n amountType\n name\n order\n type\n }\n }\n }\n "])));
|
|
26554
|
+
QUERY = src(templateObject_2$3 || (templateObject_2$3 = __makeTemplateObject(["\n query getCheckoutById($id: String!) {\n getCheckoutById(id: $id) {\n totalFinalPrice\n note\n availableShippingMethods {\n price\n rateName\n shippingMethod\n shippingSettingsId\n shippingZoneRateId\n }\n billingAddress {\n addressLine1\n addressLine2\n city {\n code\n id\n name\n }\n company\n country {\n code\n id\n name\n }\n district {\n code\n id\n name\n }\n firstName\n identityNumber\n isDefault\n lastName\n phone\n postalCode\n state {\n code\n id\n name\n }\n taxNumber\n taxOffice\n }\n cartId\n couponCode\n createdAt\n customer {\n email\n firstName\n id\n lastName\n }\n deleted\n id\n merchantId\n orderId\n orderNumber\n recoverEmailStatus\n recoveryStatus\n shippingAddress {\n addressLine1\n addressLine2\n city {\n code\n id\n name\n }\n company\n country {\n id\n code\n name\n }\n district {\n name\n id\n code\n }\n firstName\n identityNumber\n isDefault\n lastName\n phone\n postalCode\n state {\n name\n id\n code\n }\n taxNumber\n taxOffice\n }\n shippingLines {\n title\n taxValue\n price\n shippingSettingsId\n shippingZoneRateId\n }\n shippingMethod\n shippingSettingsId\n shippingZoneRateId\n status\n updatedAt\n cart {\n createdAt\n currencyCode\n customerId\n dueDate\n id\n itemCount\n items {\n createdAt\n currencyCode\n discount {\n amount\n amountType\n reason\n }\n discountPrice\n finalPrice\n id\n originalOrderLineItemId\n price\n quantity\n status\n deleted\n statusUpdatedAt\n stockLocationId\n taxValue\n updatedAt\n variant {\n barcodeList\n id\n mainImageId\n name\n productId\n sku\n variantValues {\n order\n variantTypeId\n variantTypeName\n variantValueId\n variantValueName\n }\n }\n }\n merchantId\n status\n totalPrice\n updatedAt\n }\n adjustments {\n amount\n amountType\n name\n order\n type\n couponId\n }\n }\n }\n "], ["\n query getCheckoutById($id: String!) {\n getCheckoutById(id: $id) {\n totalFinalPrice\n note\n availableShippingMethods {\n price\n rateName\n shippingMethod\n shippingSettingsId\n shippingZoneRateId\n }\n billingAddress {\n addressLine1\n addressLine2\n city {\n code\n id\n name\n }\n company\n country {\n code\n id\n name\n }\n district {\n code\n id\n name\n }\n firstName\n identityNumber\n isDefault\n lastName\n phone\n postalCode\n state {\n code\n id\n name\n }\n taxNumber\n taxOffice\n }\n cartId\n couponCode\n createdAt\n customer {\n email\n firstName\n id\n lastName\n }\n deleted\n id\n merchantId\n orderId\n orderNumber\n recoverEmailStatus\n recoveryStatus\n shippingAddress {\n addressLine1\n addressLine2\n city {\n code\n id\n name\n }\n company\n country {\n id\n code\n name\n }\n district {\n name\n id\n code\n }\n firstName\n identityNumber\n isDefault\n lastName\n phone\n postalCode\n state {\n name\n id\n code\n }\n taxNumber\n taxOffice\n }\n shippingLines {\n title\n taxValue\n price\n shippingSettingsId\n shippingZoneRateId\n }\n shippingMethod\n shippingSettingsId\n shippingZoneRateId\n status\n updatedAt\n cart {\n createdAt\n currencyCode\n customerId\n dueDate\n id\n itemCount\n items {\n createdAt\n currencyCode\n discount {\n amount\n amountType\n reason\n }\n discountPrice\n finalPrice\n id\n originalOrderLineItemId\n price\n quantity\n status\n deleted\n statusUpdatedAt\n stockLocationId\n taxValue\n updatedAt\n variant {\n barcodeList\n id\n mainImageId\n name\n productId\n sku\n variantValues {\n order\n variantTypeId\n variantTypeName\n variantValueId\n variantValueName\n }\n }\n }\n merchantId\n status\n totalPrice\n updatedAt\n }\n adjustments {\n amount\n amountType\n name\n order\n type\n couponId\n }\n }\n }\n "])));
|
|
26521
26555
|
_b.label = 1;
|
|
26522
26556
|
case 1:
|
|
26523
26557
|
_b.trys.push([1, 3, , 4]);
|
|
@@ -28155,7 +28189,7 @@ var SVGCaretDown = function (_a) {
|
|
|
28155
28189
|
};
|
|
28156
28190
|
|
|
28157
28191
|
var FormItem = mobxReactLite.observer(function (props) {
|
|
28158
|
-
var
|
|
28192
|
+
var _a = React.useState(function () { return new FormItemViewModel(props); }), vm = _a[0], setVM = _a[1];
|
|
28159
28193
|
React.useEffect(function () {
|
|
28160
28194
|
mobx.runInAction(function () {
|
|
28161
28195
|
vm.type = props.type;
|
|
@@ -28188,7 +28222,7 @@ var FormItem = mobxReactLite.observer(function (props) {
|
|
|
28188
28222
|
}, [props.errorText]);
|
|
28189
28223
|
React.useEffect(function () {
|
|
28190
28224
|
mobx.runInAction(function () {
|
|
28191
|
-
|
|
28225
|
+
setVM(new FormItemViewModel(props));
|
|
28192
28226
|
});
|
|
28193
28227
|
}, [props.onChange]);
|
|
28194
28228
|
return (React.createElement("div", { className: vm.formItemStyle },
|
|
@@ -28589,7 +28623,7 @@ var css_248z$2 = ".common-module_FormSectionTitle___Mykh {\n width: 100%;\n di
|
|
|
28589
28623
|
var commonStyles = {"FormSectionTitle":"common-module_FormSectionTitle___Mykh","Title":"common-module_Title__3JTHt","WithSubTitle":"common-module_WithSubTitle__1VHWv","SubTitle":"common-module_SubTitle__1H4kH","Grid":"common-module_Grid__2CuvH","Grid2":"common-module_Grid2__9CCag","Grid3":"common-module_Grid3__3p0jJ","FormContainer":"common-module_FormContainer__2I_Lj","mtFormRow":"common-module_mtFormRow__2tsDn","mt1":"common-module_mt1__3tpC1","mt2":"common-module_mt2__2bl5q","fadeInFromRight":"common-module_fadeInFromRight__3RYk5"};
|
|
28590
28624
|
styleInject(css_248z$2);
|
|
28591
28625
|
|
|
28592
|
-
var css_248z$3 = ".style-module_CheckoutPage__A_f2V {\n font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif;\n font-size: 16px;\n width: 100%;\n height: 100vh;\n overflow: auto;\n overflow-x: hidden;\n display: flex; }\n .style-module_CheckoutPage__A_f2V * {\n box-sizing: border-box !important; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 {\n width: 50%;\n flex: 0 0 auto;\n display: flex;\n justify-content: flex-end;\n padding-left: 20px;\n padding-right: 40px; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 {\n width: 100%;\n min-width: 400px;\n max-width: 600px;\n display: flex;\n flex-direction: column;\n justify-content: space-between;\n min-height: 100vh; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 .style-module_Space__1e2de {\n width: 100%;\n height: 100px; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 .style-module_Footer__ebdyg {\n flex: 0 0 auto;\n height: 50px;\n background-color: white;\n width: calc(100% - 1em);\n display: flex;\n align-items: center;\n border-top: 1px solid #d9d9d9; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 .style-module_Footer__ebdyg .style-module_FooterItem__1ofBc {\n font-size: 0.7em;\n margin-right: 1.4em;\n color: #737373;\n cursor: pointer;\n user-select: none; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 .style-module_Footer__ebdyg .style-module_FooterItem__1ofBc:hover {\n color: #111111; }\n @media only screen and (max-width: 1000px) {\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 .style-module_Footer__ebdyg {\n width: 100%;\n padding-left: 0.7em; } }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_Header__1vfF1 {\n width: 100%;\n height: 96px;\n display: flex;\n align-items: center;\n font-weight: 500;\n font-size: 1.5em;\n padding-left: 0.4em; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_Header__1vfF1 a {\n width: 100%; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_Header__1vfF1 .style-module_Logo__2E8Do {\n width: 100%;\n height: 64px;\n position: relative;\n user-select: none;\n cursor: pointer; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_Header__1vfF1 .style-module_Logo__2E8Do img {\n object-fit: contain;\n object-position: left;\n pointer-events: none; }\n @media only screen and (min-width: 1000px) {\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_MobileCartSummary__3NrcP {\n display: none; } }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_RowPB__3M7Tz {\n padding-bottom: 0.7em; }\n @media only screen and (max-width: 1000px) {\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 {\n width: 100%;\n justify-content: center;\n padding-right: 0px;\n padding-left: 0px; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 {\n width: 100%;\n min-width: auto;\n max-width: 100%; } }\n .style-module_CheckoutPage__A_f2V .style-module_Right__3AN4f {\n width: 50%;\n min-height: 100%;\n flex: 0 0 auto;\n background-color: #FAFAFA;\n border-left: 1px solid #d9d9d9;\n display: flex;\n padding-left: 40px;\n padding-right: 20px;\n position: sticky;\n top: 0;\n overflow-y: auto; }\n .style-module_CheckoutPage__A_f2V .style-module_Right__3AN4f .style-module_RightContent__1TcO5 {\n width: 100%;\n max-width: 600px;\n padding-top: 80px; }\n @media only screen and (max-width: 1000px) {\n .style-module_CheckoutPage__A_f2V .style-module_Right__3AN4f {\n display: none; } }\n";
|
|
28626
|
+
var css_248z$3 = ".style-module_CheckoutPage__A_f2V {\n font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif;\n font-size: 16px !important;\n width: 100%;\n height: 100vh;\n overflow: auto;\n overflow-x: hidden;\n display: flex; }\n .style-module_CheckoutPage__A_f2V * {\n box-sizing: border-box !important;\n font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif;\n font-size: 16px; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 {\n width: 50%;\n flex: 0 0 auto;\n display: flex;\n justify-content: flex-end;\n padding-left: 20px;\n padding-right: 40px; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 {\n width: 100%;\n min-width: 400px;\n max-width: 600px;\n display: flex;\n flex-direction: column;\n justify-content: space-between;\n min-height: 100vh; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 .style-module_Space__1e2de {\n width: 100%;\n height: 100px; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 .style-module_Footer__ebdyg {\n flex: 0 0 auto;\n height: 50px;\n background-color: white;\n width: calc(100% - 1em);\n display: flex;\n align-items: center;\n border-top: 1px solid #d9d9d9; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 .style-module_Footer__ebdyg .style-module_FooterItem__1ofBc {\n font-size: 0.7em;\n margin-right: 1.4em;\n color: #737373;\n cursor: pointer;\n user-select: none; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 .style-module_Footer__ebdyg .style-module_FooterItem__1ofBc:hover {\n color: #111111; }\n @media only screen and (max-width: 1000px) {\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 .style-module_Footer__ebdyg {\n width: 100%;\n padding-left: 0.7em; } }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_Header__1vfF1 {\n width: 100%;\n height: 96px;\n display: flex;\n align-items: center;\n font-weight: 500;\n font-size: 1.5em;\n padding-left: 0.4em; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_Header__1vfF1 a {\n width: 100%; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_Header__1vfF1 .style-module_Logo__2E8Do {\n width: 100%;\n height: 64px;\n position: relative;\n user-select: none;\n cursor: pointer; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_Header__1vfF1 .style-module_Logo__2E8Do img {\n object-fit: contain;\n object-position: left;\n pointer-events: none; }\n @media only screen and (min-width: 1000px) {\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_MobileCartSummary__3NrcP {\n display: none; } }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_RowPB__3M7Tz {\n padding-bottom: 0.7em; }\n @media only screen and (max-width: 1000px) {\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 {\n width: 100%;\n justify-content: center;\n padding-right: 0px;\n padding-left: 0px; }\n .style-module_CheckoutPage__A_f2V .style-module_Left__2dWz6 .style-module_LeftContent__1Tyb7 {\n width: 100%;\n min-width: auto;\n max-width: 100%; } }\n .style-module_CheckoutPage__A_f2V .style-module_Right__3AN4f {\n width: 50%;\n min-height: 100%;\n flex: 0 0 auto;\n background-color: #FAFAFA;\n border-left: 1px solid #d9d9d9;\n display: flex;\n padding-left: 40px;\n padding-right: 20px;\n position: sticky;\n top: 0;\n overflow-y: auto; }\n .style-module_CheckoutPage__A_f2V .style-module_Right__3AN4f .style-module_RightContent__1TcO5 {\n width: 100%;\n max-width: 600px;\n padding-top: 80px; }\n @media only screen and (max-width: 1000px) {\n .style-module_CheckoutPage__A_f2V .style-module_Right__3AN4f {\n display: none; } }\n";
|
|
28593
28627
|
var styles$2 = {"CheckoutPage":"style-module_CheckoutPage__A_f2V","Left":"style-module_Left__2dWz6","LeftContent":"style-module_LeftContent__1Tyb7","Space":"style-module_Space__1e2de","Footer":"style-module_Footer__ebdyg","FooterItem":"style-module_FooterItem__1ofBc","Header":"style-module_Header__1vfF1","Logo":"style-module_Logo__2E8Do","MobileCartSummary":"style-module_MobileCartSummary__3NrcP","RowPB":"style-module_RowPB__3M7Tz","Right":"style-module_Right__3AN4f","RightContent":"style-module_RightContent__1TcO5"};
|
|
28594
28628
|
styleInject(css_248z$3);
|
|
28595
28629
|
|
|
@@ -28630,16 +28664,17 @@ var AddressForm$1 = mobxReactLite.observer(function (_a) {
|
|
|
28630
28664
|
IkasCheckoutRequirementEnum.INVISIBLE && (React.createElement(FormItem, { type: FormItemType.TEXT, label: "TC Kimlik No", value: vm.identityNumber || "", onChange: vm.onIdentityNumberChange, hasError: isErrorsVisible && !(validationResult === null || validationResult === void 0 ? void 0 : validationResult.identityNumber), errorText: "TC kimlik no girin" })))));
|
|
28631
28665
|
});
|
|
28632
28666
|
|
|
28633
|
-
var css_248z$4 = ".style-module_Button__1UPMN {\n cursor: pointer;\n border: 1px transparent solid;\n border-radius: 6px;\n font-weight: 500;\n text-align: center;\n position: relative;\n transition: all .2s;\n display: flex;\n justify-content: center;\n align-items: center; }\n .style-module_Button__1UPMN.style-module_Large__2wPlw {\n height: 64px;\n padding: 0 1.7em; }\n .style-module_Button__1UPMN.style-module_Dark__1Z_hs {\n background-color: #111111;\n color: white; }\n .style-module_Button__1UPMN.style-module_Disabled__3HYF_ {\n background-color: #c8c8c8;\n color: #
|
|
28634
|
-
var styles$3 = {"Button":"style-module_Button__1UPMN","Large":"style-module_Large__2wPlw","Dark":"style-module_Dark__1Z_hs","Disabled":"style-module_Disabled__3HYF_","FullWidthMobile":"style-module_FullWidthMobile__3MTFv","loader":"style-module_loader__3v6kq","load8":"style-module_load8__2z7nj"};
|
|
28667
|
+
var css_248z$4 = ".style-module_Button__1UPMN {\n cursor: pointer;\n border: 1px transparent solid;\n border-radius: 6px;\n font-weight: 500;\n text-align: center;\n position: relative;\n transition: all .2s;\n display: flex;\n justify-content: center;\n align-items: center; }\n .style-module_Button__1UPMN:focus {\n outline: 0; }\n .style-module_Button__1UPMN.style-module_Large__2wPlw {\n height: 64px;\n padding: 0 1.7em; }\n .style-module_Button__1UPMN.style-module_Medium__3t0pu {\n height: 3em;\n padding: 0.5em 1em; }\n .style-module_Button__1UPMN.style-module_Dark__1Z_hs {\n background-color: #111111;\n color: white; }\n .style-module_Button__1UPMN.style-module_Disabled__3HYF_ {\n background-color: #c8c8c8;\n color: #FAFAFA;\n pointer-events: none; }\n @media only screen and (max-width: 1000px) {\n .style-module_Button__1UPMN.style-module_FullWidthMobile__3MTFv {\n width: 100%; } }\n .style-module_Button__1UPMN .style-module_loader__3v6kq,\n .style-module_Button__1UPMN .style-module_loader__3v6kq:after {\n border-radius: 50%;\n width: 5em;\n height: 5em; }\n .style-module_Button__1UPMN .style-module_loader__3v6kq {\n font-size: 6px;\n position: relative;\n text-indent: -9999em;\n border-top: 0.5em solid rgba(255, 255, 255, 0.2);\n border-right: 0.5em solid rgba(255, 255, 255, 0.2);\n border-bottom: 0.5em solid rgba(255, 255, 255, 0.2);\n border-left: 0.5em solid #ffffff;\n -webkit-transform: translateZ(0);\n -ms-transform: translateZ(0);\n transform: translateZ(0);\n -webkit-animation: style-module_load8__2z7nj 1.1s infinite linear;\n animation: style-module_load8__2z7nj 1.1s infinite linear; }\n\n@-webkit-keyframes style-module_load8__2z7nj {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg); }\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg); } }\n\n@keyframes style-module_load8__2z7nj {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg); }\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg); } }\n";
|
|
28668
|
+
var styles$3 = {"Button":"style-module_Button__1UPMN","Large":"style-module_Large__2wPlw","Medium":"style-module_Medium__3t0pu","Dark":"style-module_Dark__1Z_hs","Disabled":"style-module_Disabled__3HYF_","FullWidthMobile":"style-module_FullWidthMobile__3MTFv","loader":"style-module_loader__3v6kq","load8":"style-module_load8__2z7nj"};
|
|
28635
28669
|
styleInject(css_248z$4);
|
|
28636
28670
|
|
|
28637
28671
|
var Button = mobxReactLite.observer(function (_a) {
|
|
28638
|
-
var text = _a.text, onClick = _a.onClick, isLoading = _a.isLoading;
|
|
28639
|
-
return (React.createElement("button", { type: "button", className: [
|
|
28672
|
+
var text = _a.text, style = _a.style, onClick = _a.onClick, size = _a.size, isLoading = _a.isLoading, isDisabled = _a.isDisabled;
|
|
28673
|
+
return (React.createElement("button", { style: style, type: "button", className: [
|
|
28640
28674
|
styles$3.Button,
|
|
28641
28675
|
styles$3.Dark,
|
|
28642
|
-
styles$3.Large,
|
|
28676
|
+
size === "medium" ? styles$3.Medium : styles$3.Large,
|
|
28677
|
+
isDisabled ? styles$3.Disabled : "",
|
|
28643
28678
|
styles$3.FullWidthMobile,
|
|
28644
28679
|
].join(" "), onClick: !isLoading ? onClick : undefined }, isLoading ? (React.createElement("div", { className: styles$3.loader })) : (React.createElement("span", null, text))));
|
|
28645
28680
|
});
|
|
@@ -28987,8 +29022,8 @@ var CartItem = mobxReactLite.observer(function (_a) {
|
|
|
28987
29022
|
React.createElement("div", { className: styles$e.Price }, formatMoney(cartItem.finalPriceWithQuantity, currencyCode))));
|
|
28988
29023
|
});
|
|
28989
29024
|
|
|
28990
|
-
var css_248z$g = ".style-module_CartSummary__30RcF {\n background-color: #FAFAFA;\n padding: 0 0.7em;\n border-bottom: 1px solid #d9d9d9
|
|
28991
|
-
var styles$f = {"CartSummary":"style-module_CartSummary__30RcF","AllowExpand":"style-module_AllowExpand__3kDXF","ExpandHeader":"style-module_ExpandHeader__2ICjA","Left":"style-module_Left__A54sv","Label":"style-module_Label__3E7LF","ArrowDown":"style-module_ArrowDown__2ET-d","Rotated":"style-module_Rotated__3sgbm","Price":"style-module_Price__sosrJ","Expanded":"style-module_Expanded__3VBL2","DetailsContainer":"style-module_DetailsContainer__FBBIP","Details":"style-module_Details__3-X_i","Divider":"style-module_Divider__2d0Zk","Coupon":"style-module_Coupon__3pdQA","
|
|
29025
|
+
var css_248z$g = ".style-module_CartSummary__30RcF {\n background-color: #FAFAFA;\n padding: 0 0.7em;\n overflow: hidden;\n border-bottom: 1px solid #d9d9d9; }\n .style-module_CartSummary__30RcF.style-module_AllowExpand__3kDXF {\n border-top: 1px solid #d9d9d9; }\n .style-module_CartSummary__30RcF .style-module_ExpandHeader__2ICjA {\n display: flex;\n justify-content: space-between;\n align-items: center;\n height: 56px;\n padding: 0 1em;\n width: calc(100% + 1.4em);\n margin-left: -0.7em;\n border-bottom: 1px solid transparent;\n transition: border-bottom .3s;\n user-select: none; }\n .style-module_CartSummary__30RcF .style-module_ExpandHeader__2ICjA .style-module_Left__A54sv {\n display: flex;\n align-items: center;\n font-size: 0.8em; }\n .style-module_CartSummary__30RcF .style-module_ExpandHeader__2ICjA .style-module_Left__A54sv .style-module_Label__3E7LF {\n margin-left: 0.5em; }\n .style-module_CartSummary__30RcF .style-module_ExpandHeader__2ICjA .style-module_Left__A54sv .style-module_ArrowDown__2ET-d {\n transition: all .3s; }\n .style-module_CartSummary__30RcF .style-module_ExpandHeader__2ICjA .style-module_Left__A54sv .style-module_ArrowDown__2ET-d.style-module_Rotated__3sgbm {\n transform: rotate(-180deg); }\n .style-module_CartSummary__30RcF .style-module_ExpandHeader__2ICjA .style-module_Price__sosrJ {\n font-weight: 500; }\n .style-module_CartSummary__30RcF .style-module_ExpandHeader__2ICjA.style-module_Expanded__3VBL2 {\n border-bottom: 1px solid #d9d9d9; }\n .style-module_CartSummary__30RcF .style-module_DetailsContainer__FBBIP {\n overflow: hidden;\n width: 100%;\n transition: height .3s ease-in-out; }\n .style-module_CartSummary__30RcF .style-module_Details__3-X_i {\n overflow: hidden; }\n .style-module_CartSummary__30RcF .style-module_Divider__2d0Zk {\n width: 100%;\n height: 1px;\n margin: auto;\n background-color: #d9d9d9; }\n .style-module_CartSummary__30RcF .style-module_CouponContainer__1zCXG {\n padding: 1.2em 0.1em;\n border-bottom: 1px solid #d9d9d9; }\n .style-module_CartSummary__30RcF .style-module_Coupon__3pdQA {\n display: flex; }\n .style-module_CartSummary__30RcF .style-module_AppliedCoupon__37qv8 {\n display: inline-flex;\n align-items: center;\n padding: 0.65em;\n margin-top: 0.85em;\n color: #333333;\n background-color: rgba(113, 113, 113, 0.11);\n user-select: none;\n border-radius: 6px; }\n .style-module_CartSummary__30RcF .style-module_AppliedCoupon__37qv8 .style-module_AppliedCouponCode__2o7pn {\n margin-left: 0.25em;\n margin-right: 0.25em;\n font-weight: 500;\n position: relative;\n top: -1px; }\n .style-module_CartSummary__30RcF .style-module_AppliedCoupon__37qv8 .style-module_Cross__2dc3d {\n color: #545454;\n cursor: pointer;\n position: relative;\n bottom: -1px; }\n .style-module_CartSummary__30RcF .style-module_AppliedCoupon__37qv8 .style-module_Cross__2dc3d:hover {\n color: #333333; }\n .style-module_CartSummary__30RcF .style-module_SubTotalInfo__1QMnr {\n padding: 1.2em 0;\n border-bottom: 1px solid #d9d9d9; }\n .style-module_CartSummary__30RcF .style-module_SubTotalInfo__1QMnr .style-module_InfoRow__3eZdJ {\n display: flex;\n justify-content: space-between;\n align-items: center;\n margin-bottom: 0.3em; }\n .style-module_CartSummary__30RcF .style-module_SubTotalInfo__1QMnr .style-module_InfoRow__3eZdJ .style-module_Label__3E7LF {\n color: #545454;\n font-size: 0.8em; }\n .style-module_CartSummary__30RcF .style-module_SubTotalInfo__1QMnr .style-module_InfoRow__3eZdJ .style-module_Value__3mBvk {\n font-size: 0.8em; }\n .style-module_CartSummary__30RcF .style-module_SubTotalInfo__1QMnr .style-module_InfoRow__3eZdJ:last-of-type {\n margin-bottom: 0; }\n .style-module_CartSummary__30RcF .style-module_TotalContainer__36DNt {\n display: flex;\n justify-content: space-between;\n align-items: center;\n padding: 1.5em 0; }\n .style-module_CartSummary__30RcF .style-module_TotalContainer__36DNt .style-module_TitleContainer__3ptQE .style-module_Title__16M5E {\n font-size: 1em; }\n .style-module_CartSummary__30RcF .style-module_TotalContainer__36DNt .style-module_TitleContainer__3ptQE .style-module_Tax__17g6O {\n font-size: 0.8em;\n color: #545454; }\n .style-module_CartSummary__30RcF .style-module_TotalContainer__36DNt .style-module_TotalPrice__2s7DC {\n font-size: 1.5em;\n font-weight: 500; }\n @media only screen and (min-width: 1000px) {\n .style-module_CartSummary__30RcF {\n border-bottom: none; }\n .style-module_CartSummary__30RcF .style-module_SubTotalInfo__1QMnr .style-module_InfoRow__3eZdJ .style-module_Label__3E7LF,\n .style-module_CartSummary__30RcF .style-module_SubTotalInfo__1QMnr .style-module_InfoRow__3eZdJ .style-module_Value__3mBvk {\n font-size: 0.9em; } }\n";
|
|
29026
|
+
var styles$f = {"CartSummary":"style-module_CartSummary__30RcF","AllowExpand":"style-module_AllowExpand__3kDXF","ExpandHeader":"style-module_ExpandHeader__2ICjA","Left":"style-module_Left__A54sv","Label":"style-module_Label__3E7LF","ArrowDown":"style-module_ArrowDown__2ET-d","Rotated":"style-module_Rotated__3sgbm","Price":"style-module_Price__sosrJ","Expanded":"style-module_Expanded__3VBL2","DetailsContainer":"style-module_DetailsContainer__FBBIP","Details":"style-module_Details__3-X_i","Divider":"style-module_Divider__2d0Zk","CouponContainer":"style-module_CouponContainer__1zCXG","Coupon":"style-module_Coupon__3pdQA","AppliedCoupon":"style-module_AppliedCoupon__37qv8","AppliedCouponCode":"style-module_AppliedCouponCode__2o7pn","Cross":"style-module_Cross__2dc3d","SubTotalInfo":"style-module_SubTotalInfo__1QMnr","InfoRow":"style-module_InfoRow__3eZdJ","Value":"style-module_Value__3mBvk","TotalContainer":"style-module_TotalContainer__36DNt","TitleContainer":"style-module_TitleContainer__3ptQE","Title":"style-module_Title__16M5E","Tax":"style-module_Tax__17g6O","TotalPrice":"style-module_TotalPrice__2s7DC"};
|
|
28992
29027
|
styleInject(css_248z$g);
|
|
28993
29028
|
|
|
28994
29029
|
var SVGArrowDown = function (_a) {
|
|
@@ -29005,6 +29040,20 @@ var SVGShoppingBag = function (_a) {
|
|
|
29005
29040
|
React.createElement("path", { fill: "currentColor", d: "M4 16V4H2V2h3a1 1 0 0 1 1 1v12h12.438l2-8H8V5h13.72a1 1 0 0 1 .97 1.243l-2.5 10a1 1 0 0 1-.97.757H5a1 1 0 0 1-1-1zm2 7a2 2 0 1 1 0-4 2 2 0 0 1 0 4zm12 0a2 2 0 1 1 0-4 2 2 0 0 1 0 4z" })));
|
|
29006
29041
|
};
|
|
29007
29042
|
|
|
29043
|
+
var SVGTag = function (_a) {
|
|
29044
|
+
var className = _a.className;
|
|
29045
|
+
return (React.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", width: "24", height: "24", className: className },
|
|
29046
|
+
React.createElement("path", { fill: "none", d: "M0 0h24v24H0z" }),
|
|
29047
|
+
React.createElement("path", { fill: "currentColor", d: "M10.9 2.1l9.899 1.415 1.414 9.9-9.192 9.192a1 1 0 0 1-1.414 0l-9.9-9.9a1 1 0 0 1 0-1.414L10.9 2.1zm2.828 8.486a2 2 0 1 0 2.828-2.829 2 2 0 0 0-2.828 2.829z" })));
|
|
29048
|
+
};
|
|
29049
|
+
|
|
29050
|
+
var SVGCross = function (_a) {
|
|
29051
|
+
var className = _a.className;
|
|
29052
|
+
return (React.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", width: "24", height: "24", className: className },
|
|
29053
|
+
React.createElement("path", { fill: "none", d: "M0 0h24v24H0z" }),
|
|
29054
|
+
React.createElement("path", { fill: "currentColor", d: "M12 10.586l4.95-4.95 1.414 1.414-4.95 4.95 4.95 4.95-1.414 1.414-4.95-4.95-4.95 4.95-1.414-1.414 4.95-4.95-4.95-4.95L7.05 5.636z" })));
|
|
29055
|
+
};
|
|
29056
|
+
|
|
29008
29057
|
var CartSummary = mobxReactLite.observer(function (_a) {
|
|
29009
29058
|
var _b;
|
|
29010
29059
|
var vm = _a.vm, allowExpand = _a.allowExpand;
|
|
@@ -29062,6 +29111,7 @@ var CartSummary = mobxReactLite.observer(function (_a) {
|
|
|
29062
29111
|
cart.items.map(function (item, index) { return (React.createElement("div", { key: index },
|
|
29063
29112
|
React.createElement(CartItem, { cartItem: item, currencyCode: cart.currencyCode }),
|
|
29064
29113
|
React.createElement("div", { className: styles$f.Divider }))); }),
|
|
29114
|
+
React.createElement(Coupon, { vm: vm }),
|
|
29065
29115
|
React.createElement("div", { className: styles$f.SubTotalInfo },
|
|
29066
29116
|
React.createElement("div", { className: styles$f.InfoRow },
|
|
29067
29117
|
React.createElement("div", { className: styles$f.Label }, "Alt Toplam"),
|
|
@@ -29076,7 +29126,10 @@ var CartSummary = mobxReactLite.observer(function (_a) {
|
|
|
29076
29126
|
React.createElement("div", { className: styles$f.Value }, formatMoney(vm.installmentExtraPrice, cart.currencyCode)))),
|
|
29077
29127
|
sortBy_1(vm.checkout.adjustments || [], "order").map(function (adjustment, index) { return (React.createElement("div", { className: styles$f.InfoRow, key: index },
|
|
29078
29128
|
React.createElement("div", { className: styles$f.Label }, adjustment.name),
|
|
29079
|
-
React.createElement("div", { className: styles$f.Value },
|
|
29129
|
+
React.createElement("div", { className: styles$f.Value },
|
|
29130
|
+
React.createElement("span", null, adjustment.type === "DECREMENT" ? "- " : ""),
|
|
29131
|
+
" ",
|
|
29132
|
+
React.createElement("span", null, formatMoney(adjustment.amount, cart.currencyCode))))); })),
|
|
29080
29133
|
React.createElement("div", { className: styles$f.TotalContainer },
|
|
29081
29134
|
React.createElement("div", { className: styles$f.TitleContainer },
|
|
29082
29135
|
React.createElement("div", { className: styles$f.Title }, "Toplam"),
|
|
@@ -29085,6 +29138,51 @@ var CartSummary = mobxReactLite.observer(function (_a) {
|
|
|
29085
29138
|
React.createElement("div", { className: styles$f.TotalPrice }, formatMoney(vm.installmentPrice ||
|
|
29086
29139
|
vm.checkout.totalFinalPrice ||
|
|
29087
29140
|
cart.totalPrice, cart.currencyCode)))))));
|
|
29141
|
+
});
|
|
29142
|
+
var Coupon = mobxReactLite.observer(function (_a) {
|
|
29143
|
+
var vm = _a.vm;
|
|
29144
|
+
var _b = React.useState(""), couponCode = _b[0], setCouponCode = _b[1];
|
|
29145
|
+
var _c = React.useState(false), isLoadingCoupon = _c[0], setLoadingCoupon = _c[1];
|
|
29146
|
+
var onCouponApply = function () { return __awaiter(void 0, void 0, void 0, function () {
|
|
29147
|
+
return __generator(this, function (_a) {
|
|
29148
|
+
switch (_a.label) {
|
|
29149
|
+
case 0:
|
|
29150
|
+
vm.checkout.couponCode = couponCode;
|
|
29151
|
+
setLoadingCoupon(true);
|
|
29152
|
+
return [4 /*yield*/, vm.onCouponCodeApply()];
|
|
29153
|
+
case 1:
|
|
29154
|
+
_a.sent();
|
|
29155
|
+
setLoadingCoupon(false);
|
|
29156
|
+
setCouponCode("");
|
|
29157
|
+
return [2 /*return*/];
|
|
29158
|
+
}
|
|
29159
|
+
});
|
|
29160
|
+
}); };
|
|
29161
|
+
var onClearCouponCode = function () { return __awaiter(void 0, void 0, void 0, function () {
|
|
29162
|
+
return __generator(this, function (_a) {
|
|
29163
|
+
switch (_a.label) {
|
|
29164
|
+
case 0:
|
|
29165
|
+
vm.checkout.couponCode = null;
|
|
29166
|
+
setLoadingCoupon(true);
|
|
29167
|
+
return [4 /*yield*/, vm.onCouponCodeApply()];
|
|
29168
|
+
case 1:
|
|
29169
|
+
_a.sent();
|
|
29170
|
+
setLoadingCoupon(false);
|
|
29171
|
+
return [2 /*return*/];
|
|
29172
|
+
}
|
|
29173
|
+
});
|
|
29174
|
+
}); };
|
|
29175
|
+
if (vm.step === CheckoutStep.SUCCESS)
|
|
29176
|
+
return null;
|
|
29177
|
+
return (React.createElement("div", { className: styles$f.CouponContainer },
|
|
29178
|
+
React.createElement("div", { className: styles$f.Coupon },
|
|
29179
|
+
React.createElement(FormItem, { type: FormItemType.TEXT, label: "Hediye kartı veya indirim kodu", value: couponCode, onChange: function (value) { return setCouponCode(value); } }),
|
|
29180
|
+
React.createElement(Button, { text: "Uygula", onClick: onCouponApply, isDisabled: !couponCode, isLoading: isLoadingCoupon, size: "medium", style: { marginLeft: "0.5em", maxWidth: "80px" } })),
|
|
29181
|
+
!!vm.checkout.appliedCouponCode && (React.createElement("div", { className: styles$f.AppliedCoupon },
|
|
29182
|
+
React.createElement(SVGTag, null),
|
|
29183
|
+
React.createElement("div", { className: styles$f.AppliedCouponCode }, vm.checkout.appliedCouponCode),
|
|
29184
|
+
React.createElement("div", { className: styles$f.Cross, onClick: onClearCouponCode },
|
|
29185
|
+
React.createElement(SVGCross, null))))));
|
|
29088
29186
|
});
|
|
29089
29187
|
|
|
29090
29188
|
var css_248z$h = ".style-module_Breadcrumbs__1jIPZ {\n display: flex;\n align-items: center;\n padding: 0 0.7em; }\n .style-module_Breadcrumbs__1jIPZ .style-module_Breadcrumb__2qdy3 {\n font-size: 0.8em;\n padding: 1em 0;\n display: flex;\n align-items: center;\n user-select: none;\n cursor: pointer;\n color: #545454; }\n .style-module_Breadcrumbs__1jIPZ .style-module_Breadcrumb__2qdy3 .style-module_icon__3Rq6w {\n transform: rotate(180deg); }\n .style-module_Breadcrumbs__1jIPZ .style-module_Breadcrumb__2qdy3.style-module_Active__3KwX8 {\n color: #111111;\n font-weight: 500; }\n";
|
|
@@ -29115,7 +29213,7 @@ var Breadcrumbs = mobxReactLite.observer(function (_a) {
|
|
|
29115
29213
|
catch (err) { }
|
|
29116
29214
|
};
|
|
29117
29215
|
return (React.createElement("div", { className: styles$g.Breadcrumbs },
|
|
29118
|
-
React.createElement("div", { className: styles$g.Breadcrumb, onClick: vm.
|
|
29216
|
+
React.createElement("div", { className: styles$g.Breadcrumb, onClick: vm.onGoToCartClick },
|
|
29119
29217
|
React.createElement("span", null, "Sepet"),
|
|
29120
29218
|
React.createElement("span", { className: styles$g.icon },
|
|
29121
29219
|
React.createElement(SVGArrowLeft, null))),
|
|
@@ -26,6 +26,7 @@ export declare class IkasCheckout {
|
|
|
26
26
|
totalFinalPrice?: number | null;
|
|
27
27
|
adjustments?: IkasOrderAdjustment[] | null;
|
|
28
28
|
note: string | null;
|
|
29
|
+
appliedCouponCode?: string | null;
|
|
29
30
|
constructor(data?: Partial<IkasCheckout>);
|
|
30
31
|
get shippingTotal(): number;
|
|
31
32
|
get hasCustomer(): boolean;
|