@ikas/storefront 0.0.4 → 0.0.6
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 +158 -51
- package/build/index.js +157 -50
- package/build/models/data/brand/index.d.ts +2 -2
- package/build/models/data/cart/index.d.ts +2 -2
- package/build/models/data/category/index.d.ts +2 -2
- package/build/models/data/checkout/index.d.ts +21 -21
- package/build/models/data/customer/address/index.d.ts +17 -17
- package/build/models/data/customer/index.d.ts +1 -1
- package/build/models/data/html-meta-data/index.d.ts +1 -1
- package/build/models/data/order/address/index.d.ts +15 -15
- package/build/models/data/order/line-item/index.d.ts +4 -4
- package/build/models/data/order/line-item/variant/index.d.ts +4 -4
- package/build/models/theme/page/component/prop-value/brand-list.d.ts +4 -4
- package/build/models/theme/page/component/prop-value/brand.d.ts +2 -2
- package/build/models/theme/page/component/prop-value/link.d.ts +9 -9
- package/build/models/theme/page/component/prop-value/product-detail.d.ts +3 -3
- package/build/models/theme/page/component/prop-value/product-list.d.ts +5 -5
- package/build/models/ui/navigation-link/index.d.ts +1 -1
- package/build/models/ui/product-list/filter.d.ts +2 -2
- package/build/store/customer.d.ts +3 -3
- package/build/storefront/index.d.ts +2 -1
- package/build/utils/providers/page-data.d.ts +2 -2
- package/package.json +1 -1
package/build/index.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { makeAutoObservable, toJS, runInAction, reaction, action, computed,
|
|
1
|
+
import { makeAutoObservable, toJS, runInAction, reaction, action, computed, configure } from 'mobx';
|
|
2
2
|
import queryString$1 from 'querystring';
|
|
3
3
|
import React, { createElement, useState, useEffect, Fragment, useCallback, useRef } from 'react';
|
|
4
4
|
import { observer } from 'mobx-react-lite';
|
|
@@ -10865,14 +10865,16 @@ function setContext(setter) {
|
|
|
10865
10865
|
var IkasStorefrontConfig = /** @class */ (function () {
|
|
10866
10866
|
function IkasStorefrontConfig() {
|
|
10867
10867
|
}
|
|
10868
|
-
IkasStorefrontConfig.init = function (store, components, config, localTheme) {
|
|
10868
|
+
IkasStorefrontConfig.init = function (store, components, config, localTheme, apiUrlOverride) {
|
|
10869
10869
|
IkasStorefrontConfig.store = store;
|
|
10870
10870
|
IkasStorefrontConfig.components = components;
|
|
10871
10871
|
IkasStorefrontConfig.config = config;
|
|
10872
10872
|
IkasStorefrontConfig.localTheme = localTheme;
|
|
10873
|
+
IkasStorefrontConfig.apiUrlOverride = apiUrlOverride;
|
|
10873
10874
|
};
|
|
10874
10875
|
IkasStorefrontConfig.components = {};
|
|
10875
10876
|
IkasStorefrontConfig.config = {};
|
|
10877
|
+
IkasStorefrontConfig.apiUrlOverride = null;
|
|
10876
10878
|
return IkasStorefrontConfig;
|
|
10877
10879
|
}());
|
|
10878
10880
|
|
|
@@ -10931,6 +10933,7 @@ var apollo = new Apollo();
|
|
|
10931
10933
|
var IkasHTMLMetaData = /** @class */ (function () {
|
|
10932
10934
|
function IkasHTMLMetaData(data) {
|
|
10933
10935
|
if (data === void 0) { data = {}; }
|
|
10936
|
+
this.redirectTo = null;
|
|
10934
10937
|
this.slug = data.slug || "";
|
|
10935
10938
|
this.pageTitle = data.pageTitle || null;
|
|
10936
10939
|
this.description = data.description || null;
|
|
@@ -10951,6 +10954,8 @@ var IkasHTMLMetaDataTargetType;
|
|
|
10951
10954
|
|
|
10952
10955
|
var IkasBrand = /** @class */ (function () {
|
|
10953
10956
|
function IkasBrand(data) {
|
|
10957
|
+
this.metaData = null;
|
|
10958
|
+
this.image = null;
|
|
10954
10959
|
this.id = data.id || "";
|
|
10955
10960
|
this.name = data.name || "";
|
|
10956
10961
|
this.metaData = data.metaData
|
|
@@ -10974,6 +10979,8 @@ var IkasBrand = /** @class */ (function () {
|
|
|
10974
10979
|
|
|
10975
10980
|
var IkasCategory = /** @class */ (function () {
|
|
10976
10981
|
function IkasCategory(data) {
|
|
10982
|
+
this.metaData = null;
|
|
10983
|
+
this.image = null;
|
|
10977
10984
|
this.id = data.id || "";
|
|
10978
10985
|
this.name = data.name || "";
|
|
10979
10986
|
this.parentId = data.parentId || null;
|
|
@@ -11751,6 +11758,7 @@ var IkasLinkPropValueProvider = /** @class */ (function () {
|
|
|
11751
11758
|
|
|
11752
11759
|
var IkasNavigationLink = /** @class */ (function () {
|
|
11753
11760
|
function IkasNavigationLink(href, label, subLinks, isExternal) {
|
|
11761
|
+
this.isExternal = null;
|
|
11754
11762
|
this.href = href;
|
|
11755
11763
|
this.label = label;
|
|
11756
11764
|
this.subLinks = subLinks;
|
|
@@ -11762,8 +11770,10 @@ var IkasNavigationLink = /** @class */ (function () {
|
|
|
11762
11770
|
|
|
11763
11771
|
var IkasPageDataProvider = /** @class */ (function () {
|
|
11764
11772
|
function IkasPageDataProvider(theme, pageParams, pageType) {
|
|
11773
|
+
this.pageType = null;
|
|
11765
11774
|
this.pageParams = {};
|
|
11766
11775
|
this.pageComponentPropValues = [];
|
|
11776
|
+
this.pageSpecificData = null;
|
|
11767
11777
|
this.theme = new IkasTheme(theme);
|
|
11768
11778
|
this.pageParams = pageParams || {};
|
|
11769
11779
|
this.pageType = pageType;
|
|
@@ -12166,21 +12176,36 @@ var formatMoney = function (price, currency) {
|
|
|
12166
12176
|
var IkasOrderAddress = /** @class */ (function () {
|
|
12167
12177
|
function IkasOrderAddress(data) {
|
|
12168
12178
|
if (data === void 0) { data = {}; }
|
|
12169
|
-
this.addressLine1 =
|
|
12170
|
-
this.addressLine2 =
|
|
12171
|
-
this.country =
|
|
12172
|
-
this.state =
|
|
12173
|
-
this.city =
|
|
12174
|
-
this.district =
|
|
12175
|
-
this.isDefault =
|
|
12176
|
-
this.company =
|
|
12177
|
-
this.firstName =
|
|
12178
|
-
this.lastName =
|
|
12179
|
-
this.phone =
|
|
12180
|
-
this.postalCode =
|
|
12181
|
-
this.identityNumber =
|
|
12182
|
-
this.taxNumber =
|
|
12183
|
-
this.taxOffice =
|
|
12179
|
+
this.addressLine1 = null;
|
|
12180
|
+
this.addressLine2 = null;
|
|
12181
|
+
this.country = null;
|
|
12182
|
+
this.state = null;
|
|
12183
|
+
this.city = null;
|
|
12184
|
+
this.district = null;
|
|
12185
|
+
this.isDefault = null;
|
|
12186
|
+
this.company = null;
|
|
12187
|
+
this.firstName = null;
|
|
12188
|
+
this.lastName = null;
|
|
12189
|
+
this.phone = null;
|
|
12190
|
+
this.postalCode = null;
|
|
12191
|
+
this.identityNumber = null;
|
|
12192
|
+
this.taxNumber = null;
|
|
12193
|
+
this.taxOffice = null;
|
|
12194
|
+
this.addressLine1 = data.addressLine1 || null;
|
|
12195
|
+
this.addressLine2 = data.addressLine2 || null;
|
|
12196
|
+
this.country = data.country || null;
|
|
12197
|
+
this.state = data.state || null;
|
|
12198
|
+
this.city = data.city || null;
|
|
12199
|
+
this.district = data.district || null;
|
|
12200
|
+
this.isDefault = data.isDefault || null;
|
|
12201
|
+
this.company = data.company || null;
|
|
12202
|
+
this.firstName = data.firstName || null;
|
|
12203
|
+
this.lastName = data.lastName || null;
|
|
12204
|
+
this.phone = data.phone || null;
|
|
12205
|
+
this.postalCode = data.postalCode || null;
|
|
12206
|
+
this.identityNumber = data.identityNumber || null;
|
|
12207
|
+
this.taxNumber = data.taxNumber || null;
|
|
12208
|
+
this.taxOffice = data.taxOffice || null;
|
|
12184
12209
|
makeAutoObservable(this);
|
|
12185
12210
|
}
|
|
12186
12211
|
Object.defineProperty(IkasOrderAddress.prototype, "addressText", {
|
|
@@ -12287,6 +12312,11 @@ var IkasImage = /** @class */ (function () {
|
|
|
12287
12312
|
var IkasOrderLineVariant = /** @class */ (function () {
|
|
12288
12313
|
function IkasOrderLineVariant(data) {
|
|
12289
12314
|
if (data === void 0) { data = {}; }
|
|
12315
|
+
this.sku = null;
|
|
12316
|
+
this.slug = null;
|
|
12317
|
+
this.mainImageId = null;
|
|
12318
|
+
// Extra
|
|
12319
|
+
this.mainImage = null;
|
|
12290
12320
|
this.id = data.id || "";
|
|
12291
12321
|
this.name = data.name || "";
|
|
12292
12322
|
this.productId = data.productId || "";
|
|
@@ -12349,6 +12379,10 @@ var IkasOrderLineVariantVariantValue = /** @class */ (function () {
|
|
|
12349
12379
|
|
|
12350
12380
|
var IkasOrderLineItem = /** @class */ (function () {
|
|
12351
12381
|
function IkasOrderLineItem(data) {
|
|
12382
|
+
this.discount = null;
|
|
12383
|
+
this.discountPrice = null;
|
|
12384
|
+
this.originalOrderLineItemId = null;
|
|
12385
|
+
this.taxValue = null;
|
|
12352
12386
|
this.id = data.id || "";
|
|
12353
12387
|
this.createdAt = data.createdAt || "";
|
|
12354
12388
|
this.updatedAt = data.updatedAt || "";
|
|
@@ -12381,6 +12415,8 @@ var IkasOrderLineItem = /** @class */ (function () {
|
|
|
12381
12415
|
|
|
12382
12416
|
var IkasCart = /** @class */ (function () {
|
|
12383
12417
|
function IkasCart(data) {
|
|
12418
|
+
this.dueDate = null;
|
|
12419
|
+
this.customerId = null;
|
|
12384
12420
|
this.id = data.id || "";
|
|
12385
12421
|
this.createdAt = data.createdAt || "";
|
|
12386
12422
|
this.updatedAt = data.updatedAt || "";
|
|
@@ -12410,6 +12446,27 @@ var IkasCart = /** @class */ (function () {
|
|
|
12410
12446
|
var IkasCheckout = /** @class */ (function () {
|
|
12411
12447
|
function IkasCheckout(data) {
|
|
12412
12448
|
if (data === void 0) { data = {}; }
|
|
12449
|
+
this.id = null;
|
|
12450
|
+
this.createdAt = null;
|
|
12451
|
+
this.updatedAt = null;
|
|
12452
|
+
this.cartId = null;
|
|
12453
|
+
this.cart = null;
|
|
12454
|
+
this.orderId = null;
|
|
12455
|
+
this.orderNumber = null;
|
|
12456
|
+
this.merchantId = null;
|
|
12457
|
+
this.shippingSettingsId = null;
|
|
12458
|
+
this.shippingZoneRateId = null;
|
|
12459
|
+
this.customer = null;
|
|
12460
|
+
this.billingAddress = null;
|
|
12461
|
+
this.shippingAddress = null;
|
|
12462
|
+
this.shippingLines = null;
|
|
12463
|
+
this.shippingMethod = null;
|
|
12464
|
+
this.status = null;
|
|
12465
|
+
this.couponCode = null;
|
|
12466
|
+
this.recoverEmailStatus = null;
|
|
12467
|
+
this.recoveryStatus = null;
|
|
12468
|
+
this.totalFinalPrice = null;
|
|
12469
|
+
this.adjustments = null;
|
|
12413
12470
|
this.id = data.id;
|
|
12414
12471
|
this.createdAt = data.createdAt;
|
|
12415
12472
|
this.updatedAt = data.updatedAt;
|
|
@@ -12522,23 +12579,40 @@ var IkasShippingMethodEnum;
|
|
|
12522
12579
|
var IkasCustomerAddress = /** @class */ (function () {
|
|
12523
12580
|
function IkasCustomerAddress(data) {
|
|
12524
12581
|
if (data === void 0) { data = {}; }
|
|
12525
|
-
this.id =
|
|
12526
|
-
this.title =
|
|
12527
|
-
this.addressLine1 =
|
|
12528
|
-
this.addressLine2 =
|
|
12529
|
-
this.country =
|
|
12530
|
-
this.state =
|
|
12531
|
-
this.city =
|
|
12532
|
-
this.district =
|
|
12533
|
-
this.isDefault =
|
|
12534
|
-
this.company =
|
|
12535
|
-
this.firstName =
|
|
12536
|
-
this.lastName =
|
|
12537
|
-
this.phone =
|
|
12538
|
-
this.postalCode =
|
|
12539
|
-
this.identityNumber =
|
|
12540
|
-
this.taxNumber =
|
|
12541
|
-
this.taxOffice =
|
|
12582
|
+
this.id = null;
|
|
12583
|
+
this.title = null;
|
|
12584
|
+
this.addressLine1 = null;
|
|
12585
|
+
this.addressLine2 = null;
|
|
12586
|
+
this.country = null;
|
|
12587
|
+
this.state = null;
|
|
12588
|
+
this.city = null;
|
|
12589
|
+
this.district = null;
|
|
12590
|
+
this.isDefault = null;
|
|
12591
|
+
this.company = null;
|
|
12592
|
+
this.firstName = null;
|
|
12593
|
+
this.lastName = null;
|
|
12594
|
+
this.phone = null;
|
|
12595
|
+
this.postalCode = null;
|
|
12596
|
+
this.identityNumber = null;
|
|
12597
|
+
this.taxNumber = null;
|
|
12598
|
+
this.taxOffice = null;
|
|
12599
|
+
this.id = data.id || null;
|
|
12600
|
+
this.title = data.title || null;
|
|
12601
|
+
this.addressLine1 = data.addressLine1 || null;
|
|
12602
|
+
this.addressLine2 = data.addressLine2 || null;
|
|
12603
|
+
this.country = data.country || null;
|
|
12604
|
+
this.state = data.state || null;
|
|
12605
|
+
this.city = data.city || null;
|
|
12606
|
+
this.district = data.district || null;
|
|
12607
|
+
this.isDefault = data.isDefault || null;
|
|
12608
|
+
this.company = data.company || null;
|
|
12609
|
+
this.firstName = data.firstName || null;
|
|
12610
|
+
this.lastName = data.lastName || null;
|
|
12611
|
+
this.phone = data.phone || null;
|
|
12612
|
+
this.postalCode = data.postalCode || null;
|
|
12613
|
+
this.identityNumber = data.identityNumber || null;
|
|
12614
|
+
this.taxNumber = data.taxNumber || null;
|
|
12615
|
+
this.taxOffice = data.taxOffice || null;
|
|
12542
12616
|
makeAutoObservable(this);
|
|
12543
12617
|
}
|
|
12544
12618
|
Object.defineProperty(IkasCustomerAddress.prototype, "addressText", {
|
|
@@ -12595,6 +12669,7 @@ var IkasCustomerAddress = /** @class */ (function () {
|
|
|
12595
12669
|
|
|
12596
12670
|
var IkasCustomer = /** @class */ (function () {
|
|
12597
12671
|
function IkasCustomer(data) {
|
|
12672
|
+
this.phone = null;
|
|
12598
12673
|
this.id = data.id || "";
|
|
12599
12674
|
this.firstName = data.firstName || "";
|
|
12600
12675
|
this.lastName = data.lastName || "";
|
|
@@ -13217,6 +13292,16 @@ var IkasTheme = /** @class */ (function () {
|
|
|
13217
13292
|
var IkasLinkPropValue = /** @class */ (function () {
|
|
13218
13293
|
function IkasLinkPropValue(data) {
|
|
13219
13294
|
if (data === void 0) { data = {}; }
|
|
13295
|
+
this.id = null;
|
|
13296
|
+
this.linkType = null;
|
|
13297
|
+
this.label = null;
|
|
13298
|
+
this.pageId = null;
|
|
13299
|
+
this.pageType = null;
|
|
13300
|
+
this.itemId = null;
|
|
13301
|
+
this.externalLink = null;
|
|
13302
|
+
this.fileUrl = null;
|
|
13303
|
+
// This will be used to link to a specific part of the page
|
|
13304
|
+
this.pageComponentId = null;
|
|
13220
13305
|
this.id = data.id;
|
|
13221
13306
|
this.linkType = data.linkType;
|
|
13222
13307
|
this.label = data.label;
|
|
@@ -13240,6 +13325,9 @@ var IkasLinkType;
|
|
|
13240
13325
|
|
|
13241
13326
|
var IkasBrandPropValue = /** @class */ (function () {
|
|
13242
13327
|
function IkasBrandPropValue(data) {
|
|
13328
|
+
this.brandId = null;
|
|
13329
|
+
// Only for brand detail page
|
|
13330
|
+
this.usePageData = null;
|
|
13243
13331
|
this.brandId = data.brandId;
|
|
13244
13332
|
this.usePageData = data.usePageData;
|
|
13245
13333
|
makeAutoObservable(this);
|
|
@@ -13251,6 +13339,7 @@ var IkasBrandList = /** @class */ (function () {
|
|
|
13251
13339
|
function IkasBrandList(data) {
|
|
13252
13340
|
var _this = this;
|
|
13253
13341
|
this._initialized = false;
|
|
13342
|
+
this._minPage = null;
|
|
13254
13343
|
this._isLoading = false;
|
|
13255
13344
|
this.getInitial = function () { return __awaiter(_this, void 0, void 0, function () {
|
|
13256
13345
|
var response_1, err_1;
|
|
@@ -13516,6 +13605,11 @@ var IkasBrandListSortType;
|
|
|
13516
13605
|
|
|
13517
13606
|
var IkasBrandListPropValue = /** @class */ (function () {
|
|
13518
13607
|
function IkasBrandListPropValue(data) {
|
|
13608
|
+
this.initialSort = null;
|
|
13609
|
+
this.initialLimit = null;
|
|
13610
|
+
// Only for static lists
|
|
13611
|
+
this.brandCount = null;
|
|
13612
|
+
this.brandIds = null;
|
|
13519
13613
|
this.brandListType = data.brandListType || IkasBrandListType.ALL;
|
|
13520
13614
|
this.initialSort = data.initialSort || IkasBrandListSortType.A_Z;
|
|
13521
13615
|
this.initialLimit = data.initialLimit || 20;
|
|
@@ -13528,6 +13622,8 @@ var IkasBrandListPropValue = /** @class */ (function () {
|
|
|
13528
13622
|
|
|
13529
13623
|
var IkasProductDetail = /** @class */ (function () {
|
|
13530
13624
|
function IkasProductDetail(product, selectedVariantValues, usePageData, router) {
|
|
13625
|
+
this.usePageData = null;
|
|
13626
|
+
this.router = null;
|
|
13531
13627
|
this.product = new IkasProduct(product);
|
|
13532
13628
|
this.selectedVariantValues = selectedVariantValues.map(function (vv) { return new IkasVariantValue(vv); });
|
|
13533
13629
|
this.usePageData = usePageData;
|
|
@@ -13597,6 +13693,9 @@ var IkasProductDetail = /** @class */ (function () {
|
|
|
13597
13693
|
var IkasProductListFilter = /** @class */ (function () {
|
|
13598
13694
|
function IkasProductListFilter(data) {
|
|
13599
13695
|
if (data === void 0) { data = {}; }
|
|
13696
|
+
// /collections/slug ve /brands/slug sayfalarında bunlar sabit filtre olacak
|
|
13697
|
+
this.category = null;
|
|
13698
|
+
this.brand = null;
|
|
13600
13699
|
this.categories = data.categories || [];
|
|
13601
13700
|
this.brands = data.brands || [];
|
|
13602
13701
|
this.variantValues = data.variantValues || [];
|
|
@@ -13610,6 +13709,11 @@ var IkasProductList = /** @class */ (function () {
|
|
|
13610
13709
|
function IkasProductList(data) {
|
|
13611
13710
|
var _this = this;
|
|
13612
13711
|
this._initialized = false;
|
|
13712
|
+
this._minPage = null;
|
|
13713
|
+
// Used for ProducListType.ALL
|
|
13714
|
+
this._filters = null;
|
|
13715
|
+
// Used for recommending products for a specific product
|
|
13716
|
+
this._recommendFor = null; // productId
|
|
13613
13717
|
this._isLoading = false;
|
|
13614
13718
|
this.getInitial = function () { return __awaiter(_this, void 0, void 0, function () {
|
|
13615
13719
|
var page, limit, response_1, data_1, err_1;
|
|
@@ -13922,7 +14026,9 @@ var IkasProductList = /** @class */ (function () {
|
|
|
13922
14026
|
enumerable: false,
|
|
13923
14027
|
configurable: true
|
|
13924
14028
|
});
|
|
13925
|
-
IkasProductList.prototype.applyFilters = function () {
|
|
14029
|
+
IkasProductList.prototype.applyFilters = function () {
|
|
14030
|
+
return;
|
|
14031
|
+
};
|
|
13926
14032
|
IkasProductList.prototype.toJSON = function () {
|
|
13927
14033
|
return {
|
|
13928
14034
|
data: this.data,
|
|
@@ -13961,6 +14067,14 @@ var IkasProductListSortType;
|
|
|
13961
14067
|
|
|
13962
14068
|
var IkasProductListPropValue = /** @class */ (function () {
|
|
13963
14069
|
function IkasProductListPropValue(data) {
|
|
14070
|
+
this.initialSort = null;
|
|
14071
|
+
this.initialLimit = null;
|
|
14072
|
+
// Only for static lists
|
|
14073
|
+
this.productCount = null;
|
|
14074
|
+
this.productIds = null;
|
|
14075
|
+
// Only for collection and brand pages
|
|
14076
|
+
// Example collections/man -> lists products inside the "man" category
|
|
14077
|
+
this.usePageFilter = null;
|
|
13964
14078
|
this.productListType = data.productListType || IkasProductListType.ALL;
|
|
13965
14079
|
this.initialSort = data.initialSort || IkasProductListSortType.A_Z;
|
|
13966
14080
|
this.initialLimit = data.initialLimit || 20;
|
|
@@ -13974,6 +14088,10 @@ var IkasProductListPropValue = /** @class */ (function () {
|
|
|
13974
14088
|
|
|
13975
14089
|
var IkasProductDetailPropValue = /** @class */ (function () {
|
|
13976
14090
|
function IkasProductDetailPropValue(data) {
|
|
14091
|
+
this.productId = null;
|
|
14092
|
+
this.variantId = null;
|
|
14093
|
+
// Only for product detail page
|
|
14094
|
+
this.usePageData = null;
|
|
13977
14095
|
this.productId = data.productId;
|
|
13978
14096
|
this.variantId = data.variantId;
|
|
13979
14097
|
this.usePageData = data.usePageData;
|
|
@@ -19929,6 +20047,10 @@ var LS_CUSTOMER_KEY = "customer";
|
|
|
19929
20047
|
var IkasCustomerStore = /** @class */ (function () {
|
|
19930
20048
|
function IkasCustomerStore(baseStore) {
|
|
19931
20049
|
var _this = this;
|
|
20050
|
+
this.customer = null;
|
|
20051
|
+
this.token = null;
|
|
20052
|
+
this.tokenExpiry = null;
|
|
20053
|
+
this.baseStore = null;
|
|
19932
20054
|
this._initialized = false;
|
|
19933
20055
|
this.login = function (email, password) { return __awaiter(_this, void 0, void 0, function () {
|
|
19934
20056
|
var response, cart;
|
|
@@ -22187,22 +22309,7 @@ var IkasCartStore = /** @class */ (function () {
|
|
|
22187
22309
|
_this._checkoutId = undefined;
|
|
22188
22310
|
};
|
|
22189
22311
|
this.baseStore = baseStore;
|
|
22190
|
-
|
|
22191
|
-
cart: observable,
|
|
22192
|
-
//@ts-ignore
|
|
22193
|
-
baseStore: observable,
|
|
22194
|
-
//@ts-ignore
|
|
22195
|
-
_checkoutId: observable,
|
|
22196
|
-
//@ts-ignore
|
|
22197
|
-
_isLoadingCart: observable,
|
|
22198
|
-
//@ts-ignore
|
|
22199
|
-
_cartLoadFinished: observable,
|
|
22200
|
-
isBrowser: computed,
|
|
22201
|
-
isLoadingCart: computed,
|
|
22202
|
-
cartLoadFinished: computed,
|
|
22203
|
-
checkoutId: computed,
|
|
22204
|
-
checkoutUrl: computed,
|
|
22205
|
-
});
|
|
22312
|
+
makeAutoObservable(this);
|
|
22206
22313
|
this.getCart();
|
|
22207
22314
|
}
|
|
22208
22315
|
Object.defineProperty(IkasCartStore.prototype, "isBrowser", {
|
package/build/index.js
CHANGED
|
@@ -10878,14 +10878,16 @@ function setContext(setter) {
|
|
|
10878
10878
|
var IkasStorefrontConfig = /** @class */ (function () {
|
|
10879
10879
|
function IkasStorefrontConfig() {
|
|
10880
10880
|
}
|
|
10881
|
-
IkasStorefrontConfig.init = function (store, components, config, localTheme) {
|
|
10881
|
+
IkasStorefrontConfig.init = function (store, components, config, localTheme, apiUrlOverride) {
|
|
10882
10882
|
IkasStorefrontConfig.store = store;
|
|
10883
10883
|
IkasStorefrontConfig.components = components;
|
|
10884
10884
|
IkasStorefrontConfig.config = config;
|
|
10885
10885
|
IkasStorefrontConfig.localTheme = localTheme;
|
|
10886
|
+
IkasStorefrontConfig.apiUrlOverride = apiUrlOverride;
|
|
10886
10887
|
};
|
|
10887
10888
|
IkasStorefrontConfig.components = {};
|
|
10888
10889
|
IkasStorefrontConfig.config = {};
|
|
10890
|
+
IkasStorefrontConfig.apiUrlOverride = null;
|
|
10889
10891
|
return IkasStorefrontConfig;
|
|
10890
10892
|
}());
|
|
10891
10893
|
|
|
@@ -10944,6 +10946,7 @@ var apollo = new Apollo();
|
|
|
10944
10946
|
var IkasHTMLMetaData = /** @class */ (function () {
|
|
10945
10947
|
function IkasHTMLMetaData(data) {
|
|
10946
10948
|
if (data === void 0) { data = {}; }
|
|
10949
|
+
this.redirectTo = null;
|
|
10947
10950
|
this.slug = data.slug || "";
|
|
10948
10951
|
this.pageTitle = data.pageTitle || null;
|
|
10949
10952
|
this.description = data.description || null;
|
|
@@ -10963,6 +10966,8 @@ var IkasHTMLMetaData = /** @class */ (function () {
|
|
|
10963
10966
|
|
|
10964
10967
|
var IkasBrand = /** @class */ (function () {
|
|
10965
10968
|
function IkasBrand(data) {
|
|
10969
|
+
this.metaData = null;
|
|
10970
|
+
this.image = null;
|
|
10966
10971
|
this.id = data.id || "";
|
|
10967
10972
|
this.name = data.name || "";
|
|
10968
10973
|
this.metaData = data.metaData
|
|
@@ -10986,6 +10991,8 @@ var IkasBrand = /** @class */ (function () {
|
|
|
10986
10991
|
|
|
10987
10992
|
var IkasCategory = /** @class */ (function () {
|
|
10988
10993
|
function IkasCategory(data) {
|
|
10994
|
+
this.metaData = null;
|
|
10995
|
+
this.image = null;
|
|
10989
10996
|
this.id = data.id || "";
|
|
10990
10997
|
this.name = data.name || "";
|
|
10991
10998
|
this.parentId = data.parentId || null;
|
|
@@ -11763,6 +11770,7 @@ var IkasLinkPropValueProvider = /** @class */ (function () {
|
|
|
11763
11770
|
|
|
11764
11771
|
var IkasNavigationLink = /** @class */ (function () {
|
|
11765
11772
|
function IkasNavigationLink(href, label, subLinks, isExternal) {
|
|
11773
|
+
this.isExternal = null;
|
|
11766
11774
|
this.href = href;
|
|
11767
11775
|
this.label = label;
|
|
11768
11776
|
this.subLinks = subLinks;
|
|
@@ -11774,8 +11782,10 @@ var IkasNavigationLink = /** @class */ (function () {
|
|
|
11774
11782
|
|
|
11775
11783
|
var IkasPageDataProvider = /** @class */ (function () {
|
|
11776
11784
|
function IkasPageDataProvider(theme, pageParams, pageType) {
|
|
11785
|
+
this.pageType = null;
|
|
11777
11786
|
this.pageParams = {};
|
|
11778
11787
|
this.pageComponentPropValues = [];
|
|
11788
|
+
this.pageSpecificData = null;
|
|
11779
11789
|
this.theme = new IkasTheme(theme);
|
|
11780
11790
|
this.pageParams = pageParams || {};
|
|
11781
11791
|
this.pageType = pageType;
|
|
@@ -12178,21 +12188,36 @@ var formatMoney = function (price, currency) {
|
|
|
12178
12188
|
var IkasOrderAddress = /** @class */ (function () {
|
|
12179
12189
|
function IkasOrderAddress(data) {
|
|
12180
12190
|
if (data === void 0) { data = {}; }
|
|
12181
|
-
this.addressLine1 =
|
|
12182
|
-
this.addressLine2 =
|
|
12183
|
-
this.country =
|
|
12184
|
-
this.state =
|
|
12185
|
-
this.city =
|
|
12186
|
-
this.district =
|
|
12187
|
-
this.isDefault =
|
|
12188
|
-
this.company =
|
|
12189
|
-
this.firstName =
|
|
12190
|
-
this.lastName =
|
|
12191
|
-
this.phone =
|
|
12192
|
-
this.postalCode =
|
|
12193
|
-
this.identityNumber =
|
|
12194
|
-
this.taxNumber =
|
|
12195
|
-
this.taxOffice =
|
|
12191
|
+
this.addressLine1 = null;
|
|
12192
|
+
this.addressLine2 = null;
|
|
12193
|
+
this.country = null;
|
|
12194
|
+
this.state = null;
|
|
12195
|
+
this.city = null;
|
|
12196
|
+
this.district = null;
|
|
12197
|
+
this.isDefault = null;
|
|
12198
|
+
this.company = null;
|
|
12199
|
+
this.firstName = null;
|
|
12200
|
+
this.lastName = null;
|
|
12201
|
+
this.phone = null;
|
|
12202
|
+
this.postalCode = null;
|
|
12203
|
+
this.identityNumber = null;
|
|
12204
|
+
this.taxNumber = null;
|
|
12205
|
+
this.taxOffice = null;
|
|
12206
|
+
this.addressLine1 = data.addressLine1 || null;
|
|
12207
|
+
this.addressLine2 = data.addressLine2 || null;
|
|
12208
|
+
this.country = data.country || null;
|
|
12209
|
+
this.state = data.state || null;
|
|
12210
|
+
this.city = data.city || null;
|
|
12211
|
+
this.district = data.district || null;
|
|
12212
|
+
this.isDefault = data.isDefault || null;
|
|
12213
|
+
this.company = data.company || null;
|
|
12214
|
+
this.firstName = data.firstName || null;
|
|
12215
|
+
this.lastName = data.lastName || null;
|
|
12216
|
+
this.phone = data.phone || null;
|
|
12217
|
+
this.postalCode = data.postalCode || null;
|
|
12218
|
+
this.identityNumber = data.identityNumber || null;
|
|
12219
|
+
this.taxNumber = data.taxNumber || null;
|
|
12220
|
+
this.taxOffice = data.taxOffice || null;
|
|
12196
12221
|
mobx.makeAutoObservable(this);
|
|
12197
12222
|
}
|
|
12198
12223
|
Object.defineProperty(IkasOrderAddress.prototype, "addressText", {
|
|
@@ -12299,6 +12324,11 @@ var IkasImage = /** @class */ (function () {
|
|
|
12299
12324
|
var IkasOrderLineVariant = /** @class */ (function () {
|
|
12300
12325
|
function IkasOrderLineVariant(data) {
|
|
12301
12326
|
if (data === void 0) { data = {}; }
|
|
12327
|
+
this.sku = null;
|
|
12328
|
+
this.slug = null;
|
|
12329
|
+
this.mainImageId = null;
|
|
12330
|
+
// Extra
|
|
12331
|
+
this.mainImage = null;
|
|
12302
12332
|
this.id = data.id || "";
|
|
12303
12333
|
this.name = data.name || "";
|
|
12304
12334
|
this.productId = data.productId || "";
|
|
@@ -12361,6 +12391,10 @@ var IkasOrderLineVariantVariantValue = /** @class */ (function () {
|
|
|
12361
12391
|
|
|
12362
12392
|
var IkasOrderLineItem = /** @class */ (function () {
|
|
12363
12393
|
function IkasOrderLineItem(data) {
|
|
12394
|
+
this.discount = null;
|
|
12395
|
+
this.discountPrice = null;
|
|
12396
|
+
this.originalOrderLineItemId = null;
|
|
12397
|
+
this.taxValue = null;
|
|
12364
12398
|
this.id = data.id || "";
|
|
12365
12399
|
this.createdAt = data.createdAt || "";
|
|
12366
12400
|
this.updatedAt = data.updatedAt || "";
|
|
@@ -12393,6 +12427,8 @@ var IkasOrderLineItem = /** @class */ (function () {
|
|
|
12393
12427
|
|
|
12394
12428
|
var IkasCart = /** @class */ (function () {
|
|
12395
12429
|
function IkasCart(data) {
|
|
12430
|
+
this.dueDate = null;
|
|
12431
|
+
this.customerId = null;
|
|
12396
12432
|
this.id = data.id || "";
|
|
12397
12433
|
this.createdAt = data.createdAt || "";
|
|
12398
12434
|
this.updatedAt = data.updatedAt || "";
|
|
@@ -12422,6 +12458,27 @@ var IkasCart = /** @class */ (function () {
|
|
|
12422
12458
|
var IkasCheckout = /** @class */ (function () {
|
|
12423
12459
|
function IkasCheckout(data) {
|
|
12424
12460
|
if (data === void 0) { data = {}; }
|
|
12461
|
+
this.id = null;
|
|
12462
|
+
this.createdAt = null;
|
|
12463
|
+
this.updatedAt = null;
|
|
12464
|
+
this.cartId = null;
|
|
12465
|
+
this.cart = null;
|
|
12466
|
+
this.orderId = null;
|
|
12467
|
+
this.orderNumber = null;
|
|
12468
|
+
this.merchantId = null;
|
|
12469
|
+
this.shippingSettingsId = null;
|
|
12470
|
+
this.shippingZoneRateId = null;
|
|
12471
|
+
this.customer = null;
|
|
12472
|
+
this.billingAddress = null;
|
|
12473
|
+
this.shippingAddress = null;
|
|
12474
|
+
this.shippingLines = null;
|
|
12475
|
+
this.shippingMethod = null;
|
|
12476
|
+
this.status = null;
|
|
12477
|
+
this.couponCode = null;
|
|
12478
|
+
this.recoverEmailStatus = null;
|
|
12479
|
+
this.recoveryStatus = null;
|
|
12480
|
+
this.totalFinalPrice = null;
|
|
12481
|
+
this.adjustments = null;
|
|
12425
12482
|
this.id = data.id;
|
|
12426
12483
|
this.createdAt = data.createdAt;
|
|
12427
12484
|
this.updatedAt = data.updatedAt;
|
|
@@ -12528,23 +12585,40 @@ var IkasCheckout = /** @class */ (function () {
|
|
|
12528
12585
|
var IkasCustomerAddress = /** @class */ (function () {
|
|
12529
12586
|
function IkasCustomerAddress(data) {
|
|
12530
12587
|
if (data === void 0) { data = {}; }
|
|
12531
|
-
this.id =
|
|
12532
|
-
this.title =
|
|
12533
|
-
this.addressLine1 =
|
|
12534
|
-
this.addressLine2 =
|
|
12535
|
-
this.country =
|
|
12536
|
-
this.state =
|
|
12537
|
-
this.city =
|
|
12538
|
-
this.district =
|
|
12539
|
-
this.isDefault =
|
|
12540
|
-
this.company =
|
|
12541
|
-
this.firstName =
|
|
12542
|
-
this.lastName =
|
|
12543
|
-
this.phone =
|
|
12544
|
-
this.postalCode =
|
|
12545
|
-
this.identityNumber =
|
|
12546
|
-
this.taxNumber =
|
|
12547
|
-
this.taxOffice =
|
|
12588
|
+
this.id = null;
|
|
12589
|
+
this.title = null;
|
|
12590
|
+
this.addressLine1 = null;
|
|
12591
|
+
this.addressLine2 = null;
|
|
12592
|
+
this.country = null;
|
|
12593
|
+
this.state = null;
|
|
12594
|
+
this.city = null;
|
|
12595
|
+
this.district = null;
|
|
12596
|
+
this.isDefault = null;
|
|
12597
|
+
this.company = null;
|
|
12598
|
+
this.firstName = null;
|
|
12599
|
+
this.lastName = null;
|
|
12600
|
+
this.phone = null;
|
|
12601
|
+
this.postalCode = null;
|
|
12602
|
+
this.identityNumber = null;
|
|
12603
|
+
this.taxNumber = null;
|
|
12604
|
+
this.taxOffice = null;
|
|
12605
|
+
this.id = data.id || null;
|
|
12606
|
+
this.title = data.title || null;
|
|
12607
|
+
this.addressLine1 = data.addressLine1 || null;
|
|
12608
|
+
this.addressLine2 = data.addressLine2 || null;
|
|
12609
|
+
this.country = data.country || null;
|
|
12610
|
+
this.state = data.state || null;
|
|
12611
|
+
this.city = data.city || null;
|
|
12612
|
+
this.district = data.district || null;
|
|
12613
|
+
this.isDefault = data.isDefault || null;
|
|
12614
|
+
this.company = data.company || null;
|
|
12615
|
+
this.firstName = data.firstName || null;
|
|
12616
|
+
this.lastName = data.lastName || null;
|
|
12617
|
+
this.phone = data.phone || null;
|
|
12618
|
+
this.postalCode = data.postalCode || null;
|
|
12619
|
+
this.identityNumber = data.identityNumber || null;
|
|
12620
|
+
this.taxNumber = data.taxNumber || null;
|
|
12621
|
+
this.taxOffice = data.taxOffice || null;
|
|
12548
12622
|
mobx.makeAutoObservable(this);
|
|
12549
12623
|
}
|
|
12550
12624
|
Object.defineProperty(IkasCustomerAddress.prototype, "addressText", {
|
|
@@ -12601,6 +12675,7 @@ var IkasCustomerAddress = /** @class */ (function () {
|
|
|
12601
12675
|
|
|
12602
12676
|
var IkasCustomer = /** @class */ (function () {
|
|
12603
12677
|
function IkasCustomer(data) {
|
|
12678
|
+
this.phone = null;
|
|
12604
12679
|
this.id = data.id || "";
|
|
12605
12680
|
this.firstName = data.firstName || "";
|
|
12606
12681
|
this.lastName = data.lastName || "";
|
|
@@ -13208,6 +13283,16 @@ var IkasTheme = /** @class */ (function () {
|
|
|
13208
13283
|
var IkasLinkPropValue = /** @class */ (function () {
|
|
13209
13284
|
function IkasLinkPropValue(data) {
|
|
13210
13285
|
if (data === void 0) { data = {}; }
|
|
13286
|
+
this.id = null;
|
|
13287
|
+
this.linkType = null;
|
|
13288
|
+
this.label = null;
|
|
13289
|
+
this.pageId = null;
|
|
13290
|
+
this.pageType = null;
|
|
13291
|
+
this.itemId = null;
|
|
13292
|
+
this.externalLink = null;
|
|
13293
|
+
this.fileUrl = null;
|
|
13294
|
+
// This will be used to link to a specific part of the page
|
|
13295
|
+
this.pageComponentId = null;
|
|
13211
13296
|
this.id = data.id;
|
|
13212
13297
|
this.linkType = data.linkType;
|
|
13213
13298
|
this.label = data.label;
|
|
@@ -13230,6 +13315,9 @@ var IkasLinkPropValue = /** @class */ (function () {
|
|
|
13230
13315
|
|
|
13231
13316
|
var IkasBrandPropValue = /** @class */ (function () {
|
|
13232
13317
|
function IkasBrandPropValue(data) {
|
|
13318
|
+
this.brandId = null;
|
|
13319
|
+
// Only for brand detail page
|
|
13320
|
+
this.usePageData = null;
|
|
13233
13321
|
this.brandId = data.brandId;
|
|
13234
13322
|
this.usePageData = data.usePageData;
|
|
13235
13323
|
mobx.makeAutoObservable(this);
|
|
@@ -13241,6 +13329,7 @@ var IkasBrandList = /** @class */ (function () {
|
|
|
13241
13329
|
function IkasBrandList(data) {
|
|
13242
13330
|
var _this = this;
|
|
13243
13331
|
this._initialized = false;
|
|
13332
|
+
this._minPage = null;
|
|
13244
13333
|
this._isLoading = false;
|
|
13245
13334
|
this.getInitial = function () { return __awaiter(_this, void 0, void 0, function () {
|
|
13246
13335
|
var response_1, err_1;
|
|
@@ -13504,6 +13593,11 @@ var IkasBrandList = /** @class */ (function () {
|
|
|
13504
13593
|
|
|
13505
13594
|
var IkasBrandListPropValue = /** @class */ (function () {
|
|
13506
13595
|
function IkasBrandListPropValue(data) {
|
|
13596
|
+
this.initialSort = null;
|
|
13597
|
+
this.initialLimit = null;
|
|
13598
|
+
// Only for static lists
|
|
13599
|
+
this.brandCount = null;
|
|
13600
|
+
this.brandIds = null;
|
|
13507
13601
|
this.brandListType = data.brandListType || exports.IkasBrandListType.ALL;
|
|
13508
13602
|
this.initialSort = data.initialSort || exports.IkasBrandListSortType.A_Z;
|
|
13509
13603
|
this.initialLimit = data.initialLimit || 20;
|
|
@@ -13516,6 +13610,8 @@ var IkasBrandListPropValue = /** @class */ (function () {
|
|
|
13516
13610
|
|
|
13517
13611
|
var IkasProductDetail = /** @class */ (function () {
|
|
13518
13612
|
function IkasProductDetail(product, selectedVariantValues, usePageData, router) {
|
|
13613
|
+
this.usePageData = null;
|
|
13614
|
+
this.router = null;
|
|
13519
13615
|
this.product = new IkasProduct(product);
|
|
13520
13616
|
this.selectedVariantValues = selectedVariantValues.map(function (vv) { return new IkasVariantValue(vv); });
|
|
13521
13617
|
this.usePageData = usePageData;
|
|
@@ -13585,6 +13681,9 @@ var IkasProductDetail = /** @class */ (function () {
|
|
|
13585
13681
|
var IkasProductListFilter = /** @class */ (function () {
|
|
13586
13682
|
function IkasProductListFilter(data) {
|
|
13587
13683
|
if (data === void 0) { data = {}; }
|
|
13684
|
+
// /collections/slug ve /brands/slug sayfalarında bunlar sabit filtre olacak
|
|
13685
|
+
this.category = null;
|
|
13686
|
+
this.brand = null;
|
|
13588
13687
|
this.categories = data.categories || [];
|
|
13589
13688
|
this.brands = data.brands || [];
|
|
13590
13689
|
this.variantValues = data.variantValues || [];
|
|
@@ -13598,6 +13697,11 @@ var IkasProductList = /** @class */ (function () {
|
|
|
13598
13697
|
function IkasProductList(data) {
|
|
13599
13698
|
var _this = this;
|
|
13600
13699
|
this._initialized = false;
|
|
13700
|
+
this._minPage = null;
|
|
13701
|
+
// Used for ProducListType.ALL
|
|
13702
|
+
this._filters = null;
|
|
13703
|
+
// Used for recommending products for a specific product
|
|
13704
|
+
this._recommendFor = null; // productId
|
|
13601
13705
|
this._isLoading = false;
|
|
13602
13706
|
this.getInitial = function () { return __awaiter(_this, void 0, void 0, function () {
|
|
13603
13707
|
var page, limit, response_1, data_1, err_1;
|
|
@@ -13910,7 +14014,9 @@ var IkasProductList = /** @class */ (function () {
|
|
|
13910
14014
|
enumerable: false,
|
|
13911
14015
|
configurable: true
|
|
13912
14016
|
});
|
|
13913
|
-
IkasProductList.prototype.applyFilters = function () {
|
|
14017
|
+
IkasProductList.prototype.applyFilters = function () {
|
|
14018
|
+
return;
|
|
14019
|
+
};
|
|
13914
14020
|
IkasProductList.prototype.toJSON = function () {
|
|
13915
14021
|
return {
|
|
13916
14022
|
data: this.data,
|
|
@@ -13947,6 +14053,14 @@ var IkasProductList = /** @class */ (function () {
|
|
|
13947
14053
|
|
|
13948
14054
|
var IkasProductListPropValue = /** @class */ (function () {
|
|
13949
14055
|
function IkasProductListPropValue(data) {
|
|
14056
|
+
this.initialSort = null;
|
|
14057
|
+
this.initialLimit = null;
|
|
14058
|
+
// Only for static lists
|
|
14059
|
+
this.productCount = null;
|
|
14060
|
+
this.productIds = null;
|
|
14061
|
+
// Only for collection and brand pages
|
|
14062
|
+
// Example collections/man -> lists products inside the "man" category
|
|
14063
|
+
this.usePageFilter = null;
|
|
13950
14064
|
this.productListType = data.productListType || exports.IkasProductListType.ALL;
|
|
13951
14065
|
this.initialSort = data.initialSort || exports.IkasProductListSortType.A_Z;
|
|
13952
14066
|
this.initialLimit = data.initialLimit || 20;
|
|
@@ -13960,6 +14074,10 @@ var IkasProductListPropValue = /** @class */ (function () {
|
|
|
13960
14074
|
|
|
13961
14075
|
var IkasProductDetailPropValue = /** @class */ (function () {
|
|
13962
14076
|
function IkasProductDetailPropValue(data) {
|
|
14077
|
+
this.productId = null;
|
|
14078
|
+
this.variantId = null;
|
|
14079
|
+
// Only for product detail page
|
|
14080
|
+
this.usePageData = null;
|
|
13963
14081
|
this.productId = data.productId;
|
|
13964
14082
|
this.variantId = data.variantId;
|
|
13965
14083
|
this.usePageData = data.usePageData;
|
|
@@ -19915,6 +20033,10 @@ var LS_CUSTOMER_KEY = "customer";
|
|
|
19915
20033
|
var IkasCustomerStore = /** @class */ (function () {
|
|
19916
20034
|
function IkasCustomerStore(baseStore) {
|
|
19917
20035
|
var _this = this;
|
|
20036
|
+
this.customer = null;
|
|
20037
|
+
this.token = null;
|
|
20038
|
+
this.tokenExpiry = null;
|
|
20039
|
+
this.baseStore = null;
|
|
19918
20040
|
this._initialized = false;
|
|
19919
20041
|
this.login = function (email, password) { return __awaiter(_this, void 0, void 0, function () {
|
|
19920
20042
|
var response, cart;
|
|
@@ -22173,22 +22295,7 @@ var IkasCartStore = /** @class */ (function () {
|
|
|
22173
22295
|
_this._checkoutId = undefined;
|
|
22174
22296
|
};
|
|
22175
22297
|
this.baseStore = baseStore;
|
|
22176
|
-
mobx.
|
|
22177
|
-
cart: mobx.observable,
|
|
22178
|
-
//@ts-ignore
|
|
22179
|
-
baseStore: mobx.observable,
|
|
22180
|
-
//@ts-ignore
|
|
22181
|
-
_checkoutId: mobx.observable,
|
|
22182
|
-
//@ts-ignore
|
|
22183
|
-
_isLoadingCart: mobx.observable,
|
|
22184
|
-
//@ts-ignore
|
|
22185
|
-
_cartLoadFinished: mobx.observable,
|
|
22186
|
-
isBrowser: mobx.computed,
|
|
22187
|
-
isLoadingCart: mobx.computed,
|
|
22188
|
-
cartLoadFinished: mobx.computed,
|
|
22189
|
-
checkoutId: mobx.computed,
|
|
22190
|
-
checkoutUrl: mobx.computed,
|
|
22191
|
-
});
|
|
22298
|
+
mobx.makeAutoObservable(this);
|
|
22192
22299
|
this.getCart();
|
|
22193
22300
|
}
|
|
22194
22301
|
Object.defineProperty(IkasCartStore.prototype, "isBrowser", {
|
|
@@ -3,8 +3,8 @@ import { IkasHTMLMetaData } from "../html-meta-data/index";
|
|
|
3
3
|
export declare class IkasBrand {
|
|
4
4
|
id: string;
|
|
5
5
|
name: string;
|
|
6
|
-
metaData?: IkasHTMLMetaData;
|
|
7
|
-
image?: IkasImage;
|
|
6
|
+
metaData?: IkasHTMLMetaData | null;
|
|
7
|
+
image?: IkasImage | null;
|
|
8
8
|
constructor(data: Partial<IkasBrand>);
|
|
9
9
|
get href(): string;
|
|
10
10
|
}
|
|
@@ -3,9 +3,9 @@ export declare class IkasCart {
|
|
|
3
3
|
id: string;
|
|
4
4
|
createdAt: string;
|
|
5
5
|
updatedAt: string;
|
|
6
|
-
dueDate?: string;
|
|
6
|
+
dueDate?: string | null;
|
|
7
7
|
currencyCode: string;
|
|
8
|
-
customerId?: string;
|
|
8
|
+
customerId?: string | null;
|
|
9
9
|
itemCount: number;
|
|
10
10
|
items: IkasOrderLineItem[];
|
|
11
11
|
merchantId: string;
|
|
@@ -4,8 +4,8 @@ export declare class IkasCategory {
|
|
|
4
4
|
id: string;
|
|
5
5
|
name: string;
|
|
6
6
|
parentId: string | null;
|
|
7
|
-
metaData?: IkasHTMLMetaData;
|
|
8
|
-
image?: IkasImage;
|
|
7
|
+
metaData?: IkasHTMLMetaData | null;
|
|
8
|
+
image?: IkasImage | null;
|
|
9
9
|
constructor(data: Partial<IkasCategory>);
|
|
10
10
|
get href(): string;
|
|
11
11
|
}
|
|
@@ -3,28 +3,28 @@ import { IkasOrderShippingLine } from "../order/shipping-line/index";
|
|
|
3
3
|
import { IkasCart } from "../cart/index";
|
|
4
4
|
import { IkasOrderAdjustment } from "../order/index";
|
|
5
5
|
export declare class IkasCheckout {
|
|
6
|
-
id?: string;
|
|
7
|
-
createdAt?: string;
|
|
8
|
-
updatedAt?: string;
|
|
9
|
-
cartId?: string;
|
|
10
|
-
cart?: IkasCart;
|
|
11
|
-
orderId?: string;
|
|
12
|
-
orderNumber?: string;
|
|
13
|
-
merchantId?: string;
|
|
14
|
-
shippingSettingsId?: string;
|
|
15
|
-
shippingZoneRateId?: string;
|
|
6
|
+
id?: string | null;
|
|
7
|
+
createdAt?: string | null;
|
|
8
|
+
updatedAt?: string | null;
|
|
9
|
+
cartId?: string | null;
|
|
10
|
+
cart?: IkasCart | null;
|
|
11
|
+
orderId?: string | null;
|
|
12
|
+
orderNumber?: string | null;
|
|
13
|
+
merchantId?: string | null;
|
|
14
|
+
shippingSettingsId?: string | null;
|
|
15
|
+
shippingZoneRateId?: string | null;
|
|
16
16
|
availableShippingMethods: IkasAvailableShippingMethod[];
|
|
17
|
-
customer?: IkasCheckoutCustomer;
|
|
18
|
-
billingAddress?: IkasOrderAddress;
|
|
19
|
-
shippingAddress?: IkasOrderAddress;
|
|
20
|
-
shippingLines?: IkasOrderShippingLine[];
|
|
21
|
-
shippingMethod?: IkasShippingMethod;
|
|
22
|
-
status?: IkasCheckoutStatus;
|
|
23
|
-
couponCode?: string;
|
|
24
|
-
recoverEmailStatus?: IkasCheckoutRecoveryEmailStatus;
|
|
25
|
-
recoveryStatus?: IkasCheckoutRecoveryStatus;
|
|
26
|
-
totalFinalPrice?: number;
|
|
27
|
-
adjustments?: IkasOrderAdjustment[];
|
|
17
|
+
customer?: IkasCheckoutCustomer | null;
|
|
18
|
+
billingAddress?: IkasOrderAddress | null;
|
|
19
|
+
shippingAddress?: IkasOrderAddress | null;
|
|
20
|
+
shippingLines?: IkasOrderShippingLine[] | null;
|
|
21
|
+
shippingMethod?: IkasShippingMethod | null;
|
|
22
|
+
status?: IkasCheckoutStatus | null;
|
|
23
|
+
couponCode?: string | null;
|
|
24
|
+
recoverEmailStatus?: IkasCheckoutRecoveryEmailStatus | null;
|
|
25
|
+
recoveryStatus?: IkasCheckoutRecoveryStatus | null;
|
|
26
|
+
totalFinalPrice?: number | null;
|
|
27
|
+
adjustments?: IkasOrderAdjustment[] | null;
|
|
28
28
|
constructor(data?: Partial<IkasCheckout>);
|
|
29
29
|
get shippingTotal(): number;
|
|
30
30
|
get hasCustomer(): boolean;
|
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
export declare class IkasCustomerAddress {
|
|
2
|
-
id?: string;
|
|
3
|
-
title?: string;
|
|
4
|
-
addressLine1?: string;
|
|
5
|
-
addressLine2?: string;
|
|
6
|
-
country?: IkasCustomerAddressCountry;
|
|
7
|
-
state?: IkasCustomerAddressState;
|
|
8
|
-
city?: IkasCustomerAddressCity;
|
|
9
|
-
district?: IkasCustomerAddressDistrict;
|
|
10
|
-
isDefault?: boolean;
|
|
11
|
-
company?: string;
|
|
12
|
-
firstName?: string;
|
|
13
|
-
lastName?: string;
|
|
14
|
-
phone?: string;
|
|
15
|
-
postalCode?: string;
|
|
16
|
-
identityNumber?: string;
|
|
17
|
-
taxNumber?: string;
|
|
18
|
-
taxOffice?: string;
|
|
2
|
+
id?: string | null;
|
|
3
|
+
title?: string | null;
|
|
4
|
+
addressLine1?: string | null;
|
|
5
|
+
addressLine2?: string | null;
|
|
6
|
+
country?: IkasCustomerAddressCountry | null;
|
|
7
|
+
state?: IkasCustomerAddressState | null;
|
|
8
|
+
city?: IkasCustomerAddressCity | null;
|
|
9
|
+
district?: IkasCustomerAddressDistrict | null;
|
|
10
|
+
isDefault?: boolean | null;
|
|
11
|
+
company?: string | null;
|
|
12
|
+
firstName?: string | null;
|
|
13
|
+
lastName?: string | null;
|
|
14
|
+
phone?: string | null;
|
|
15
|
+
postalCode?: string | null;
|
|
16
|
+
identityNumber?: string | null;
|
|
17
|
+
taxNumber?: string | null;
|
|
18
|
+
taxOffice?: string | null;
|
|
19
19
|
constructor(data?: Partial<IkasCustomerAddress>);
|
|
20
20
|
get addressText(): string;
|
|
21
21
|
get validationResult(): IkasAddressValidationResult;
|
|
@@ -4,7 +4,7 @@ export declare class IkasHTMLMetaData {
|
|
|
4
4
|
description: string | null;
|
|
5
5
|
targetType: IkasHTMLMetaDataTargetType | null;
|
|
6
6
|
targetId: string | null;
|
|
7
|
-
redirectTo?: string;
|
|
7
|
+
redirectTo?: string | null;
|
|
8
8
|
constructor(data?: Partial<IkasHTMLMetaData>);
|
|
9
9
|
}
|
|
10
10
|
export declare enum IkasHTMLMetaDataTargetType {
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
export declare class IkasOrderAddress {
|
|
2
|
-
addressLine1?: string;
|
|
3
|
-
addressLine2?: string;
|
|
4
|
-
country?: IkasOrderAddressCountry;
|
|
5
|
-
state?: IkasOrderAddressState;
|
|
6
|
-
city?: IkasOrderAddressCity;
|
|
7
|
-
district?: IkasOrderAddressDistrict;
|
|
8
|
-
isDefault?: boolean;
|
|
9
|
-
company?: string;
|
|
10
|
-
firstName?: string;
|
|
11
|
-
lastName?: string;
|
|
12
|
-
phone?: string;
|
|
13
|
-
postalCode?: string;
|
|
14
|
-
identityNumber?: string;
|
|
15
|
-
taxNumber?: string;
|
|
16
|
-
taxOffice?: string;
|
|
2
|
+
addressLine1?: string | null;
|
|
3
|
+
addressLine2?: string | null;
|
|
4
|
+
country?: IkasOrderAddressCountry | null;
|
|
5
|
+
state?: IkasOrderAddressState | null;
|
|
6
|
+
city?: IkasOrderAddressCity | null;
|
|
7
|
+
district?: IkasOrderAddressDistrict | null;
|
|
8
|
+
isDefault?: boolean | null;
|
|
9
|
+
company?: string | null;
|
|
10
|
+
firstName?: string | null;
|
|
11
|
+
lastName?: string | null;
|
|
12
|
+
phone?: string | null;
|
|
13
|
+
postalCode?: string | null;
|
|
14
|
+
identityNumber?: string | null;
|
|
15
|
+
taxNumber?: string | null;
|
|
16
|
+
taxOffice?: string | null;
|
|
17
17
|
constructor(data?: Partial<IkasOrderAddress>);
|
|
18
18
|
get addressText(): string;
|
|
19
19
|
get validationResult(): IkasAddressValidationResult;
|
|
@@ -6,13 +6,13 @@ export declare class IkasOrderLineItem {
|
|
|
6
6
|
updatedAt: string;
|
|
7
7
|
deleted: boolean;
|
|
8
8
|
currencyCode: string;
|
|
9
|
-
discount?: IkasOrderLineDiscount;
|
|
10
|
-
discountPrice?: number;
|
|
9
|
+
discount?: IkasOrderLineDiscount | null;
|
|
10
|
+
discountPrice?: number | null;
|
|
11
11
|
finalPrice: number;
|
|
12
|
-
originalOrderLineItemId?: string;
|
|
12
|
+
originalOrderLineItemId?: string | null;
|
|
13
13
|
price: number;
|
|
14
14
|
quantity: number;
|
|
15
|
-
taxValue?: number;
|
|
15
|
+
taxValue?: number | null;
|
|
16
16
|
variant: IkasOrderLineVariant;
|
|
17
17
|
constructor(data: Partial<IkasOrderLineItem>);
|
|
18
18
|
get tax(): number;
|
|
@@ -3,13 +3,13 @@ export declare class IkasOrderLineVariant {
|
|
|
3
3
|
id: string;
|
|
4
4
|
name: string;
|
|
5
5
|
productId: string;
|
|
6
|
-
sku?: string;
|
|
7
|
-
slug?: string;
|
|
6
|
+
sku?: string | null;
|
|
7
|
+
slug?: string | null;
|
|
8
8
|
barcodeList: string[];
|
|
9
|
-
mainImageId?: string;
|
|
9
|
+
mainImageId?: string | null;
|
|
10
10
|
taxValue: number;
|
|
11
11
|
variantValues: IkasOrderLineVariantVariantValue[];
|
|
12
|
-
mainImage?: IkasImage;
|
|
12
|
+
mainImage?: IkasImage | null;
|
|
13
13
|
constructor(data?: Partial<IkasOrderLineVariant>);
|
|
14
14
|
get href(): string;
|
|
15
15
|
}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { IkasBrandListSortType, IkasBrandListType } from "../../../../ui/brand-list/index";
|
|
2
2
|
export declare class IkasBrandListPropValue {
|
|
3
3
|
brandListType: IkasBrandListType;
|
|
4
|
-
initialSort?: IkasBrandListSortType;
|
|
5
|
-
initialLimit?: number;
|
|
6
|
-
brandCount?: number;
|
|
7
|
-
brandIds?: string[];
|
|
4
|
+
initialSort?: IkasBrandListSortType | null;
|
|
5
|
+
initialLimit?: number | null;
|
|
6
|
+
brandCount?: number | null;
|
|
7
|
+
brandIds?: string[] | null;
|
|
8
8
|
constructor(data: Partial<IkasBrandListPropValue>);
|
|
9
9
|
}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { IkasThemePageType } from "../../index";
|
|
2
2
|
export declare class IkasLinkPropValue {
|
|
3
|
-
id?: string;
|
|
4
|
-
linkType?: IkasLinkType;
|
|
5
|
-
label?: string;
|
|
6
|
-
pageId?: string;
|
|
7
|
-
pageType?: IkasThemePageType;
|
|
8
|
-
itemId?: string;
|
|
9
|
-
externalLink?: string;
|
|
10
|
-
fileUrl?: string;
|
|
11
|
-
pageComponentId?: string;
|
|
3
|
+
id?: string | null;
|
|
4
|
+
linkType?: IkasLinkType | null;
|
|
5
|
+
label?: string | null;
|
|
6
|
+
pageId?: string | null;
|
|
7
|
+
pageType?: IkasThemePageType | null;
|
|
8
|
+
itemId?: string | null;
|
|
9
|
+
externalLink?: string | null;
|
|
10
|
+
fileUrl?: string | null;
|
|
11
|
+
pageComponentId?: string | null;
|
|
12
12
|
subLinks: IkasLinkPropValue[];
|
|
13
13
|
constructor(data?: Partial<IkasLinkPropValue>);
|
|
14
14
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export declare class IkasProductDetailPropValue {
|
|
2
|
-
productId?: string;
|
|
3
|
-
variantId?: string;
|
|
4
|
-
usePageData?: boolean;
|
|
2
|
+
productId?: string | null;
|
|
3
|
+
variantId?: string | null;
|
|
4
|
+
usePageData?: boolean | null;
|
|
5
5
|
constructor(data: Partial<IkasProductDetailPropValue>);
|
|
6
6
|
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { IkasProductListSortType, IkasProductListType } from "../../../../ui/index";
|
|
2
2
|
export declare class IkasProductListPropValue {
|
|
3
3
|
productListType: IkasProductListType;
|
|
4
|
-
initialSort?: IkasProductListSortType;
|
|
5
|
-
initialLimit?: number;
|
|
6
|
-
productCount?: number;
|
|
7
|
-
productIds?: IkasProductVariantId[];
|
|
8
|
-
usePageFilter?: boolean;
|
|
4
|
+
initialSort?: IkasProductListSortType | null;
|
|
5
|
+
initialLimit?: number | null;
|
|
6
|
+
productCount?: number | null;
|
|
7
|
+
productIds?: IkasProductVariantId[] | null;
|
|
8
|
+
usePageFilter?: boolean | null;
|
|
9
9
|
constructor(data: Partial<IkasProductListPropValue>);
|
|
10
10
|
}
|
|
11
11
|
declare type IkasProductVariantId = {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { IkasCustomer, IkasOrderTransaction } from "../models/index";
|
|
2
2
|
import { IkasBaseStore } from "./base";
|
|
3
3
|
export declare class IkasCustomerStore {
|
|
4
|
-
customer?: IkasCustomer;
|
|
5
|
-
token?: string;
|
|
6
|
-
tokenExpiry?: number;
|
|
4
|
+
customer?: IkasCustomer | null;
|
|
5
|
+
token?: string | null;
|
|
6
|
+
tokenExpiry?: number | null;
|
|
7
7
|
private baseStore?;
|
|
8
8
|
private _initialized;
|
|
9
9
|
constructor(baseStore?: IkasBaseStore);
|
|
@@ -5,5 +5,6 @@ export declare class IkasStorefrontConfig {
|
|
|
5
5
|
static components: any;
|
|
6
6
|
static config: Record<string, any>;
|
|
7
7
|
static localTheme: IkasTheme;
|
|
8
|
-
static
|
|
8
|
+
static apiUrlOverride: string | null;
|
|
9
|
+
static init(store: IkasBaseStore, components: any, config: Record<string, any>, localTheme: IkasTheme, apiUrlOverride?: string): void;
|
|
9
10
|
}
|
|
@@ -2,10 +2,10 @@ import { NextRouter } from "next/router";
|
|
|
2
2
|
import { IkasTheme, IkasThemePageType, IkasThemePageComponent, IkasThemeComponentProp, IkasThemeComponent, IkasThemePage } from "../../models/index";
|
|
3
3
|
export declare class IkasPageDataProvider {
|
|
4
4
|
theme: IkasTheme;
|
|
5
|
-
pageType?: IkasThemePageType;
|
|
5
|
+
pageType?: IkasThemePageType | null;
|
|
6
6
|
pageParams: Record<string, any>;
|
|
7
7
|
pageComponentPropValues: IkasPageComponentPropValue[];
|
|
8
|
-
pageSpecificData?: any;
|
|
8
|
+
pageSpecificData?: any | null;
|
|
9
9
|
constructor(theme: IkasTheme, pageParams?: Record<string, any>, pageType?: IkasThemePageType);
|
|
10
10
|
get page(): IkasThemePage | undefined;
|
|
11
11
|
get nextPageData(): {
|