@ikas/storefront 6.1.0-beta.8 → 6.1.0-beta.80
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/analytics/analytics.d.ts +3 -3
- package/build/analytics/analytics.js +1 -1
- package/build/analytics/googleAnalytics.js +1 -1
- package/build/analytics/googleTagManager.d.ts +3 -2
- package/build/analytics/googleTagManager.js +1 -1
- package/build/analytics/ikasV3.d.ts +5 -0
- package/build/analytics/ikasV3.js +1 -1
- package/build/components/checkout/components/address-form/index.js +1 -1
- package/build/components/checkout/components/address-form/model.d.ts +3 -0
- package/build/components/checkout/components/address-form/model.js +1 -1
- package/build/components/checkout/components/cart-summary/index.d.ts +2 -0
- package/build/components/checkout/components/cart-summary/index.js +1 -1
- package/build/components/checkout/components/cart-summary/style.module.scss.js +1 -1
- package/build/components/checkout/components/customer-addresses/index.d.ts +1 -0
- package/build/components/checkout/components/customer-addresses/index.js +1 -1
- package/build/components/checkout/components/form-item/index.js +1 -1
- package/build/components/checkout/components/form-item/model.d.ts +2 -0
- package/build/components/checkout/components/form-item/model.js +1 -1
- package/build/components/checkout/components/form-item/style.module.scss.js +1 -1
- package/build/components/checkout/components/hepsipay/index.d.ts +9 -0
- package/build/components/checkout/components/hepsipay/index.js +1 -0
- package/build/components/checkout/components/input-with-button/style.module.scss.js +1 -1
- package/build/components/checkout/components/offer-product/index.js +1 -1
- package/build/components/checkout/components/stripe/checkout-form.js +1 -1
- package/build/components/checkout/index.js +1 -1
- package/build/components/checkout/model.d.ts +13 -3
- package/build/components/checkout/model.js +1 -1
- package/build/components/checkout/steps/step-info/index.js +1 -1
- package/build/components/checkout/steps/step-payment/billing-address/index.js +1 -1
- package/build/components/checkout/steps/step-payment/payment-gateways/index.js +1 -1
- package/build/components/checkout/steps/step-success/index.js +1 -1
- package/build/components/image/index.d.ts +1 -0
- package/build/components/image/index.js +1 -1
- package/build/components/index.d.ts +2 -0
- package/build/components/page/head.js +1 -1
- package/build/components/page/index.js +1 -1
- package/build/components/page-editor/ThemeComponentEditor.js +1 -1
- package/build/components/page-editor/model.js +1 -1
- package/build/components/paypal-express-checkout/index.d.ts +9 -0
- package/build/components/paypal-express-checkout/index.js +1 -0
- package/build/components/plain-image/index.d.ts +13 -0
- package/build/components/plain-image/index.js +1 -0
- package/build/components/popup/index.js +1 -1
- package/build/ext/@ikas/popup-renderer/build/popup-renderer/components/form-element-renderer/index.js +1 -1
- package/build/ext/@ikas/popup-renderer/build/popup-renderer/components/index.js +1 -1
- package/build/hooks/useStore.js +1 -1
- package/build/index.js +1 -1
- package/build/models/data/checkout-settings/index.d.ts +1 -0
- package/build/models/data/checkout-settings/index.js +1 -1
- package/build/models/data/order/gift-card-line/index.d.ts +8 -0
- package/build/models/data/order/gift-card-line/index.js +1 -0
- package/build/models/data/order/index.d.ts +2 -0
- package/build/models/data/order/index.js +1 -1
- package/build/models/data/order/line-item/bundle-product-settings/index.d.ts +7 -0
- package/build/models/data/order/line-item/bundle-product-settings/index.js +1 -0
- package/build/models/data/order/line-item/index.d.ts +2 -0
- package/build/models/data/order/line-item/index.js +1 -1
- package/build/models/data/product/index.js +1 -1
- package/build/models/data/product/variant/index.d.ts +1 -0
- package/build/models/data/product/variant/index.js +1 -1
- package/build/models/ui/product-list/index.js +1 -1
- package/build/page-data-init/index.js +1 -1
- package/build/pages/checkout.js +1 -1
- package/build/store/cart/api.d.ts +2 -1
- package/build/store/cart/api.js +1 -1
- package/build/store/checkout/index.d.ts +3 -1
- package/build/store/checkout/index.js +1 -1
- package/build/store/customer/index.js +1 -1
- package/package.json +12 -12
|
@@ -1 +1 @@
|
|
|
1
|
-
import{__spreadArray as
|
|
1
|
+
import{__awaiter as e,__generator as t,__spreadArray as r}from'./../../ext/tslib/tslib.es6.js';import*as n from"react";import{observer as i}from"mobx-react-lite";import{IkasStorefrontConfig as o}from"@ikas/storefront-config";import s from"../../hooks/useDimension.js";import l from"./renderer/index.js";import{checkSavedSessionForPopups as u,checkIsPopupSavedToLocalStorage as c}from"./utils/index.js";import{IkasStorefrontPopupPageFilterTypeEnum as a,IkasStorefrontPopupPageFilterDataTypeEnum as d,IkasStorefrontPopupDeviceTypeEnum as p}from"@ikas/storefront-models";var f=i((function(){var i=s().isMobile,f=n.useState([]),m=f[0],v=f[1];return n.useEffect((function(){e(void 0,void 0,void 0,(function(){var e,n,s,l;return t(this,(function(t){switch(t.label){case 0:return[4,new Promise((function(e){var t=setInterval((function(){var r=o.getSessionId();r&&(clearInterval(t),e(r))}),100)}))];case 1:return t.sent(),u(),e=[],n=o.getStorefrontPopups().filter((function(t){var r;if(c(t.id))return!1;var n=[];if((null===(r=t.pageFilters)||void 0===r?void 0:r.length)&&(n=t.pageFilters.filter((function(e){return e.pageType===a.CUSTOM}))).length){var o=window.location.href;o.includes("http://localhost:3333/")&&(o=o.replace("http://localhost:3333/","https://bundle.myikas.dev/")),n.forEach((function(t){var r;null===(r=t.filters)||void 0===r||r.forEach((function(t){t.type===d.CONTAINS&&o.includes(t.value)?e.push(d.CONTAINS):t.type===d.DOES_NOT_CONTAIN&&o.includes(t.value)?e.push(d.DOES_NOT_CONTAIN):t.type===d.EXACT_MATCH&&o===t.value&&e.push(d.EXACT_MATCH)}))}))}if(e.includes(d.DOES_NOT_CONTAIN))return!1;var s=function(){return i?[p.ALL,p.MOBILE].includes(t.visibleDevice):[p.ALL,p.DESKTOP].includes(t.visibleDevice)};return(e.length||!(!e.length&&!t.isFilteredOnServerSide))&&s()})),s=document.head.querySelector('link[href="https://cdn.jsdelivr.net/npm/swiper@11/swiper-bundle.min.css"]'),n.length&&!s&&((l=document.createElement("link")).type="text/css",l.rel="stylesheet",l.href="https://cdn.jsdelivr.net/npm/swiper@11/swiper-bundle.min.css",document.head.appendChild(l)),v(r([],n,!0)),[2]}}))}))}),[i]),n.createElement(n.Fragment,null,m.map((function(e,t){return n.createElement(l,{storefrontPopup:e,key:e.id})})))}));export{f as PopupListRendererForPage};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{__awaiter as e,__generator as r}from"../../../ext/tslib/tslib.es6.mjs.js";import t from"react";import{observer as n}from"../../../../../../mobx-react/dist/mobxreact.esm.js";import{getHorizontalAlignment as a,injectFontScript as o,validateEmail as i,validatePhoneNumber as
|
|
1
|
+
import{__awaiter as e,__generator as r}from"../../../ext/tslib/tslib.es6.mjs.js";import t from"react";import{observer as n}from"../../../../../../mobx-react/dist/mobxreact.esm.js";import{getHorizontalAlignment as a,injectFontScript as o,validateEmail as i,validatePhoneNumber as s}from"../../helpers/index.js";import{FormItemTypeEnum as l}from"../../models/modal/step/elements/form/index.js";import u from"../button-element-renderer/index.js";import m from"./input-item-view/index.js";import{CheckboxItemView as d}from"./checkbox-item-view/index.js";import c from"./date-item-view/index.js";import f from"./gender-item-view/index.js";var E=n((function(n){var E=n.element,p=n.popup,v=n.isPreviewMode,C=n.sfProps,I=t.useState(!1);I[0];var h=I[1],M=E,S=M.rows.slice().sort((function(e,r){return e.order-r.order})),g=M.formSettings,R=M.buttonSettings,O=M.bgColor,_={display:"flex",flexDirection:"column",justifyContent:a(M.horizontalAlignment),gap:"".concat(g.gapBetweenItems,"px"),padding:"".concat(M.outerVerticalPadding,"px ").concat(M.outerHorizontalPadding,"px"),backgroundColor:O,width:"100%"},T={display:"flex",flexDirection:"row",width:"100%",gap:"".concat(g.gapBetweenItems,"px")},b={flex:1,display:"flex",alignItems:"flex-end",fontFamily:o(g.fontFamily),fontSize:g.fontSize},U=function(){return e(void 0,void 0,void 0,(function(){var e,t,a;return r(this,(function(r){switch(r.label){case 0:return e=p.modal.steps.findIndex((function(e){return e.id===p.modal.selectedStep.id})),t=e===p.modal.steps.length-2,!v&&C&&t?(h(!0),o=0,M.rows.forEach((function(e){e.columns.forEach((function(e){switch(e.type){case l.CUSTOMER_BIRTHDAY:var r=e.formItem;r.required&&!r.value&&(r.required.hasError=!0,o++);break;case l.CUSTOMER_EMAIL:case l.CUSTOMER_PHONE:case l.CUSTOMER_NAME:case l.CUSTOMER_SURNAME:var t=e.formItem;if(t.required&&!t.value){if(t.type===l.CUSTOMER_EMAIL&&(null==C?void 0:C.isCustomerLoggedIn))return;t.required.hasError=!0,o++}else if(e.type===l.CUSTOMER_EMAIL){var n=i(t.value||"");t.validEmailError.hasError=!n,n||o++}else if(e.type===l.CUSTOMER_PHONE&&t.required){var a=s(t.value||"",null==C?void 0:C.currentCountryCode);t.validPhoneError.hasError=!a,a||o++}break;case l.CUSTOMER_GENDER:var u=e.formItem,m=u.genders.find((function(e){return e.isSelected}));u.required&&!m&&(u.required.hasError=!0,o++);break;case l.CHECKBOX_FORM_ITEM:var d=e.formItem;d.requiredToBeChecked&&!d.isChecked&&(d.requiredToBeChecked.hasError=!0,o++)}}))})),o>0?(h(!1),[2]):(a={},M.rows.forEach((function(e){e.columns.forEach((function(e){var r;switch(e.type){case l.CUSTOMER_BIRTHDAY:a.birthday=e.formItem.value;break;case l.CUSTOMER_EMAIL:a.email=e.formItem.value;break;case l.CUSTOMER_GENDER:a.gender=(null===(r=e.formItem.genders.find((function(e){return e.isSelected})))||void 0===r?void 0:r.type)||"";break;case l.CUSTOMER_PHONE:a.phone=e.formItem.value;break;case l.CUSTOMER_NAME:a.firstName=e.formItem.value||"";break;case l.CUSTOMER_SURNAME:a.lastName=e.formItem.value||"";break;case l.CHECKBOX_FORM_ITEM:a.hasPermission=e.formItem.isChecked}}))})),[4,C.onCustomerSave(a)])):[3,2];case 1:r.sent(),n.setIsCustomerSaved(!0),h(!1),r.label=2;case 2:return-1!==e&&e<p.modal.steps.length&&(p.modal.selectedStep=p.modal.steps[e+1]),[2]}var o}))}))};return t.createElement("div",{style:_},S.map((function(e,r){return t.createElement("div",{style:T,key:r},e.columns.slice().sort((function(e,r){return e.order-r.order})).map((function(e,r){return t.createElement("div",{style:b,key:r},function(e){switch(e.type){case l.CUSTOMER_EMAIL:case l.CUSTOMER_PHONE:case l.CUSTOMER_NAME:case l.CUSTOMER_SURNAME:var r=e.formItem;if(r.type===l.CUSTOMER_EMAIL&&(null==C?void 0:C.isCustomerLoggedIn)&&!v)return null;var n=null;if(e.type===l.CUSTOMER_EMAIL){var a=r;a.validEmailError.hasError&&(n=a.validEmailError.validationErrorMessage)}else if(e.type===l.CUSTOMER_PHONE){var o=r;o.validPhoneError.hasError&&(n=o.validPhoneError.validationErrorMessage)}return t.createElement(m,{formInputSettings:g.formInputSettings,inputLabel:r.inputLabel,isRequired:r.required,onValueChange:function(e){return v?null:r.value=e},placeholder:r.placeholder,updateCurrentInfo:r.updateCurrentInfo,value:r.value||"",validationErrorMessage:n});case l.CUSTOMER_BIRTHDAY:var i=e.formItem;return t.createElement(c,{formInputSettings:g.formInputSettings,inputLabel:i.inputLabel,isRequired:i.required,onValueChange:function(e){return v?null:i.value=e},placeholder:i.placeholder,updateCurrentInfo:i.updateCurrentInfo,value:i.value||""});case l.CUSTOMER_GENDER:var s=e.formItem;return t.createElement(f,{genderFormItem:s,formInputSettings:g.formInputSettings,onValueChange:function(e){return v?null:s.genders.forEach((function(r){r.isSelected=r.label===e}))}});case l.CHECKBOX_FORM_ITEM:return t.createElement(d,{checkboxItem:e.formItem})}}(e))})))})),t.createElement("div",{style:{width:"100%",minWidth:"fit-content"},onClick:function(e){U(),e.preventDefault(),e.stopPropagation()}},t.createElement(u,{element:R})," "))}));export{E as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import e from"react";import{observer as t}from"../../../../../mobx-react/dist/mobxreact.esm.js";import{PopupTypeEnum as o,PopupPositonEnum as n}from"../models/modal/index.js";import i from"../assets/x-close.js";import{CloseButtonPositionTypeEnum as r,CloseIconTypeEnum as
|
|
1
|
+
import e from"react";import{observer as t}from"../../../../../mobx-react/dist/mobxreact.esm.js";import{PopupTypeEnum as o,PopupPositonEnum as n}from"../models/modal/index.js";import i from"../assets/x-close.js";import{CloseButtonPositionTypeEnum as r,CloseIconTypeEnum as s,CloseButtonDisplayTypeEnum as l}from"../models/modal/close-settings/index.js";import{PopupElementTypeEnum as a,ComponentVerticalAlignmentEnum as d}from"../models/modal/step/elements/base/index.js";import c from"./text-element-renderer/index.js";import m from"./button-element-renderer/index.js";import p from"./space-element-renderer/index.js";import u from"./divider-element-renderer/index.js";import f from"./social-element-renderer/index.js";import P from"./image-element-renderer/index.js";import E from"./image-column-element-renderer/index.js";import x from"./product-list-renderer/index.js";import v from"./form-element-renderer/index.js";import{ImageColumnPositionEnum as g,MobileImageColumnPositionEnum as T}from"../models/modal/step/elements/image-column/index.js";var y=t((function(t){var y,b,C,O,I=t.popup,_=t.dynamicData,h=t.dashboardComponents,M=t.previewMode,S=t.sfProps,w=t.isMobile,A=e.useState(!1),D=A[0],R=A[1],k=I.modal,N=k.teaser,j=!!k.selectedStep.isTeaser,B=k.selectedStep.elements.find((function(e){return e.type===a.IMAGE_COLUMN})),L=j?N.backgroundSettings:k.backgroundSettings,U=j?N.windowSettings:k.windowSettings,H=j?N.closeSettings:k.closeSettings,W=L.allowScrollingWhenPopupOpen,F=I.isPreviewMode||M,V=!!F||k.isVisible;document.body.style.overflow=V&&!W?"hidden":"auto";var G=L.overlay,z=L.border,K="center",X="center";switch(j?o.POPUP:k.type){case o.POPUP:var Y=j?N.position:k.position;Y===n.POPUP_TOP_LEFT?(K="flex-start",X="flex-start"):Y===n.POPUP_TOP_CENTER?(K="center",X="flex-start"):Y===n.POPUP_TOP_RIGHT?(K="flex-end",X="flex-start"):Y===n.POPUP_MIDDLE_LEFT?(K="flex-start",X="center"):Y===n.POPUP_MIDDLE_CENTER?(K="center",X="center"):Y===n.POPUP_MIDDLE_RIGHT?(K="flex-end",X="center"):Y===n.POPUP_BOTTOM_LEFT?(K="flex-start",X="flex-end"):Y===n.POPUP_BOTTOM_CENTER?(K="center",X="flex-end"):Y===n.POPUP_BOTTOM_RIGHT&&(K="flex-end",X="flex-end");break;case o.DRAWER:k.position===n.DRAWER_LEFT?(K="flex-start",X="center"):k.position===n.DRAWER_RIGHT&&(K="flex-end",X="center");break;case o.NOTIFICATION_BAR:k.position===n.NOTIFICATION_BAR_UP?(K="center",X="flex-start"):k.position===n.NOTIFICATION_BAR_DOWN&&(K="center",X="flex-end")}var q=e.useMemo((function(){return 2147483644}),[]),J=e.useMemo((function(){return q+1}),[]),Q=e.useMemo((function(){return J+1}),[]),Z=e.useMemo((function(){return Q+1}),[]),$={position:"fixed",display:"flex",justifyContent:K,alignItems:X,top:0,left:0,right:0,bottom:0,zIndex:q,overflow:"hidden",padding:"".concat(U.outerVerticalPadding,"px ").concat(U.outerHorizontalPadding,"px"),opacity:V?1:0,visibility:V?"visible":"hidden",transition:"opacity 0.3s ease, visibility 0.3s ease"},ee={position:"fixed",top:0,left:0,right:0,bottom:0,zIndex:J,backgroundColor:G?G.bgColor:"",opacity:G?(G.bgOpacity||100)/100:void 0},te={position:"relative",zIndex:Q,backgroundColor:L.bgColor,border:z?"".concat(z.borderWidth,"px ").concat(z.borderStyle," ").concat(z.borderColor):"",borderRadius:"".concat(U.borderRadius,"px"),maxWidth:"100%",maxHeight:"100%",width:U.takeFullWidth?"100%":void 0,minHeight:U.minHeight,height:U.takeFullHeight?"100%":void 0,boxShadow:L.shadow?"0 0 10px ".concat(L.shadow.color):"",overflow:"auto",opacity:V?1:0,visibility:V?"visible":"hidden",transition:"opacity 0.3s ease, visibility 0.3s ease"},oe="";switch(null==B?void 0:B.verticalAlignment){case d.BOTTOM:oe="flex-end";break;case d.MIDDLE:oe="center";break;case d.TOP:oe="flex-start"}var ne=B?B.imagePosition===g.LEFT_ALIGN?"row-reverse":"row":"",ie=B?B.mobilePosition===T.TOP?"column-reverse":"column":"",re={display:"flex",flexDirection:B?w?ie:ne:"column",overflow:"hidden"},se={width:U.takeFullWidth?"100%":U.maxWidth,maxWidth:"100%",overflow:"auto",display:"flex",flexDirection:"column",justifyContent:oe,padding:"".concat(U.innerVerticalPadding,"px ").concat(U.innerHorizontalPadding,"px")},le={position:H.closeButtonPositionType===r.TAKE_SPACE?"relative":"absolute",float:H.closeButtonPositionType===r.TAKE_SPACE?"right":"none",top:8,right:8,zIndex:Z},ae={position:"sticky",padding:"6px",marginLeft:H.closeButtonPositionType===r.TAKE_SPACE?"14px":void 0,display:"flex",justifyContent:"center",alignItems:"center",border:(null===(y=H.iconSettings)||void 0===y?void 0:y.type)===s.WITH_BORDER?"1px solid ".concat(null===(b=H.iconSettings)||void 0===b?void 0:b.color):"",borderRadius:"50%",backgroundColor:null===(C=H.iconSettings)||void 0===C?void 0:C.backgroundColor},de={color:null===(O=H.iconSettings)||void 0===O?void 0:O.color,cursor:"pointer"},ce=function(t){var o=t.type,n=h&&h[o]&&h[o].length?h[o][0]:null,i=n&&I.marketingPopupViewModel?e.createElement(n,{element:t,marketingPopupViewModel:I.marketingPopupViewModel}):void 0;switch(o){case a.TEXT:return e.createElement(c,{element:t});case a.IMAGE:return e.createElement(P,{element:t,popup:I,editModeChildren:i});case a.IMAGE_COLUMN:return w&&B.mobilePosition===T.HIDE?null:e.createElement(E,{element:t,popup:I,editModeChildren:i,isMobile:w});case a.BUTTON:return e.createElement(m,{element:t,onClose:me,isStandaloneButtonComponent:!0});case a.DIVIDER:return e.createElement(u,{element:t});case a.FORM:return e.createElement(v,{element:t,popup:I,isPreviewMode:!!F,sfProps:S,setIsCustomerSaved:R});case a.PRODUCT_LIST:return e.createElement(x,{element:t,products:_.products[t.id],popup:I,editModeChildren:i,isPreviewMode:!!F,sfProps:S,onClose:me});case a.SOCIAL_MEDIA:return e.createElement(f,{element:t,popup:I,editModeChildren:i});case a.SPACE:return e.createElement(p,{element:t})}},me=function(e){if(!F&&k.isVisible){var t=D||e;k.isVisible=!1,S&&S.onModalClose(t),R(!1)}};return e.createElement("div",{className:"ikas-popup-default-styles",id:"ikas-popup-container",style:$},e.createElement("div",{style:te},H.closeButtonDisplayType!==l.ALWAYS_HIDDEN&&e.createElement("div",{style:le,onClick:function(){return me()}},e.createElement("div",{style:ae,className:H.closeButtonDisplayType===l.VISIBLE_ON_HOVER?"visible-on-hover":""},e.createElement(i,{style:de}))),e.createElement("div",{style:re,onClick:function(e){j&&(k.selectedStep=k.steps[0])}},e.createElement("div",{style:se},k.selectedStep.elements.filter((function(e){return e.type!==a.IMAGE_COLUMN})).slice().sort((function(e,t){return e.order-t.order})).map((function(e){return ce(e)}))),B&&ce(B))),e.createElement("div",{style:ee,onClick:function(){return me()}}))}));export{y as default};
|
package/build/hooks/useStore.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import"../analytics/analytics.js";import"../analytics/head/index.js";import"../components/page/index.js";import"../components/page/head.js";import"react";import"next/image.js";import"@ikas/storefront-model-functions";import"../components/link/index.js";import"../components/page-editor/loader/style.module.scss.js";import"../components/google-captcha/index.js";import"../models/data/blog/category/index.js";import"../models/data/blog/content/index.js";import"../models/data/blog/meta-data/index.js";import"../models/data/blog/tag/index.js";import"../models/data/blog/index.js";import"../models/data/brand/index.js";import"@ikas/storefront-models";import"mobx";import"../models/data/campaign-offer/index.js";import"../models/data/cart/campaign-offer/index.js";import"../models/data/cart/index.js";import"../models/data/category/path-item/index.js";import"../models/data/category/index.js";import"../models/data/checkout/index.js";import"../models/data/checkout-settings/index.js";import"../models/data/city/index.js";import"../models/data/country/index.js";import"../models/data/customer/address/region/index.js";import"../models/data/customer/address/index.js";import"../models/data/customer/address/ikas-localized-customer-address.js";import"../models/data/customer/attribute/index.js";import"../models/data/customer/review/summary/index.js";import"../models/data/customer/review/index.js";import"../models/data/customer/index.js";import"../models/data/customer-form-data-input/index.js";import"../models/data/district/index.js";import"../models/data/favorite-product/index.js";import"../models/data/filter-category/index.js";import"../models/data/html-meta-data/index.js";import"../models/data/image/index.js";import"../models/data/order/address/region/index.js";import"../models/data/order/address/index.js";import"../models/data/order/line-item/option/value/index.js";import"../models/data/order/line-item/variant/value/index.js";import"../models/data/order/line-item/variant/index.js";import"../models/data/order/line-item/index.js";import"../models/data/order/order-transaction-with-prices/index.js";import"../models/data/order/package/index.js";import"../models/data/order/transaction/index.js";import"../models/data/order/index.js";import"../models/data/payment-gateway/index.js";import"../models/data/product/attribute-value/index.js";import"../models/data/product/filter/index.js";import"../models/data/product/campaign-offer/index.js";import"../models/data/product/option-set/option/index.js";import"../models/data/product/option-set/index.js";import"../models/data/product/stock-location/index.js";import"../models/data/product/variant/price/index.js";import"../models/data/product/variant/index.js";import"../models/data/variant-type/index.js";import"../models/data/product/index.js";import"../models/data/raffle/index.js";import"../models/data/shipping-zone/state/city/district/region/index.js";import"../models/data/state/index.js";import"../models/data/storefront-popup/storefront-popup-display-filter/index.js";import"../models/data/storefront-popup/storefront-popup-display-settings/index.js";import"../models/data/storefront-popup/storefront-popup-page-filter/index.js";import"../models/data/storefront-popup/index.js";import"../models/data/theme-json/index.js";import"../models/data/theme-json/component/index.js";import"../models/data/theme-json/custom-data/index.js";import"../models/data/variant-type/variant-value/index.js";import"@ikas/localized-address";import"../models/ui/blog-list/index.js";import"../models/ui/blog-category-list/index.js";import"../models/ui/brand-list/index.js";import"../models/ui/category-list/index.js";import"../models/ui/product-list/index.js";import"../models/ui/product-attribute-detail/index.js";import"../models/ui/product-attribute-list/index.js";import"../models/ui/customer-review-list/index.js";import"../models/ui/customer-review-summary-list/index.js";import"../models/ui/validator/index.js";import"../models/ui/validator/rules/index.js";import"../models/ui/validator/form/login.js";import"../models/ui/validator/form/address.js";import"../models/ui/validator/form/ikas-address.js";import"../models/ui/validator/form/register.js";import"../models/ui/validator/form/contact-form.js";import"../models/ui/validator/form/forgot-password.js";import"../models/ui/validator/form/recover-password.js";import"../models/ui/validator/form/account-info.js";import"../models/ui/validator/form/raffle-form.js";import"../models/ui/validator/form/customer-review.js";import"../models/ui/raffle-list/index.js";import"../pages/home.js";import"../pages/_slug_/index.js";import"../pages/pages/_slug_.js";import"../pages/checkout.js";import"../pages/account/index.js";import"../pages/account/addresses.js";import"../pages/account/orders/index.js";import"../pages/account/orders/_id_.js";import"../pages/account/login.js";import"../pages/account/register.js";import"../pages/account/forgot-password.js";import"../pages/account/recover-password.js";import"../pages/cart.js";import"../pages/editor.js";import"../pages/account/favorite-products.js";import"../pages/search.js";import"next/error.js";import"../pages/blog/index.js";import"../pages/blog/_slug_.js";import"../pages/raffle/_slug_.js";import"../pages/raffle/index.js";import"../pages/account/raffles.js";import"../pages/account/activate.js";import{IkasBaseStore as o}from"../store/base.js";import"../store/customer/index.js";import"../store/cart/index.js";import"
|
|
1
|
+
import"../analytics/analytics.js";import"../analytics/head/index.js";import"../components/page/index.js";import"../components/page/head.js";import"react";import"next/image.js";import"@ikas/storefront-model-functions";import"@ikas/storefront-config";import"../components/link/index.js";import"../components/page-editor/loader/style.module.scss.js";import"../components/google-captcha/index.js";import"../components/paypal-express-checkout/index.js";import"../models/data/blog/category/index.js";import"../models/data/blog/content/index.js";import"../models/data/blog/meta-data/index.js";import"../models/data/blog/tag/index.js";import"../models/data/blog/index.js";import"../models/data/brand/index.js";import"@ikas/storefront-models";import"mobx";import"../models/data/campaign-offer/index.js";import"../models/data/cart/campaign-offer/index.js";import"../models/data/cart/index.js";import"../models/data/category/path-item/index.js";import"../models/data/category/index.js";import"../models/data/checkout/index.js";import"../models/data/checkout-settings/index.js";import"../models/data/city/index.js";import"../models/data/country/index.js";import"../models/data/customer/address/region/index.js";import"../models/data/customer/address/index.js";import"../models/data/customer/address/ikas-localized-customer-address.js";import"../models/data/customer/attribute/index.js";import"../models/data/customer/review/summary/index.js";import"../models/data/customer/review/index.js";import"../models/data/customer/index.js";import"../models/data/customer-form-data-input/index.js";import"../models/data/district/index.js";import"../models/data/favorite-product/index.js";import"../models/data/filter-category/index.js";import"../models/data/html-meta-data/index.js";import"../models/data/image/index.js";import"../models/data/order/address/region/index.js";import"../models/data/order/address/index.js";import"../models/data/order/line-item/option/value/index.js";import"../models/data/order/line-item/variant/value/index.js";import"../models/data/order/line-item/variant/index.js";import"../models/data/order/line-item/index.js";import"../models/data/order/order-transaction-with-prices/index.js";import"../models/data/order/package/index.js";import"../models/data/order/transaction/index.js";import"../models/data/order/index.js";import"../models/data/payment-gateway/index.js";import"../models/data/product/attribute-value/index.js";import"../models/data/product/filter/index.js";import"../models/data/product/campaign-offer/index.js";import"../models/data/product/option-set/option/index.js";import"../models/data/product/option-set/index.js";import"../models/data/product/stock-location/index.js";import"../models/data/product/variant/price/index.js";import"../models/data/product/variant/index.js";import"../models/data/variant-type/index.js";import"../models/data/product/index.js";import"../models/data/raffle/index.js";import"../models/data/shipping-zone/state/city/district/region/index.js";import"../models/data/state/index.js";import"../models/data/storefront-popup/storefront-popup-display-filter/index.js";import"../models/data/storefront-popup/storefront-popup-display-settings/index.js";import"../models/data/storefront-popup/storefront-popup-page-filter/index.js";import"../models/data/storefront-popup/index.js";import"../models/data/theme-json/index.js";import"../models/data/theme-json/component/index.js";import"../models/data/theme-json/custom-data/index.js";import"../models/data/variant-type/variant-value/index.js";import"@ikas/localized-address";import"../models/ui/blog-list/index.js";import"../models/ui/blog-category-list/index.js";import"../models/ui/brand-list/index.js";import"../models/ui/category-list/index.js";import"../models/ui/product-list/index.js";import"../models/ui/product-attribute-detail/index.js";import"../models/ui/product-attribute-list/index.js";import"../models/ui/customer-review-list/index.js";import"../models/ui/customer-review-summary-list/index.js";import"../models/ui/validator/index.js";import"../models/ui/validator/rules/index.js";import"../models/ui/validator/form/login.js";import"../models/ui/validator/form/address.js";import"../models/ui/validator/form/ikas-address.js";import"../models/ui/validator/form/register.js";import"../models/ui/validator/form/contact-form.js";import"../models/ui/validator/form/forgot-password.js";import"../models/ui/validator/form/recover-password.js";import"../models/ui/validator/form/account-info.js";import"../models/ui/validator/form/raffle-form.js";import"../models/ui/validator/form/customer-review.js";import"../models/ui/raffle-list/index.js";import"../pages/home.js";import"../pages/_slug_/index.js";import"../pages/pages/_slug_.js";import"../pages/checkout.js";import"../pages/account/index.js";import"../pages/account/addresses.js";import"../pages/account/orders/index.js";import"../pages/account/orders/_id_.js";import"../pages/account/login.js";import"../pages/account/register.js";import"../pages/account/forgot-password.js";import"../pages/account/recover-password.js";import"../pages/cart.js";import"../pages/editor.js";import"../pages/account/favorite-products.js";import"../pages/search.js";import"next/error.js";import"../pages/blog/index.js";import"../pages/blog/_slug_.js";import"../pages/raffle/_slug_.js";import"../pages/raffle/index.js";import"../pages/account/raffles.js";import"../pages/account/activate.js";import{IkasBaseStore as o}from"../store/base.js";import"../store/customer/index.js";import"../store/cart/index.js";import"lodash/get";function t(){return o.getInstance()}export{t as useStore};
|
package/build/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{Analytics}from"./analytics/analytics.js";export{AnalyticsBody,AnalyticsHead}from"./analytics/head/index.js";export{IkasPage}from"./components/page/index.js";export{IkasPageHead}from"./components/page/head.js";export{Image}from"./components/image/index.js";export{default as Link}from"./components/link/index.js";export{IkasEditorComponentLoader}from"./components/page-editor/loader/index.js";export{GoogleCaptcha}from"./components/google-captcha/index.js";export{useStore}from"./hooks/useStore.js";export{useCustomerReviews}from"./hooks/useCustomerReviews.js";import"react";export{IkasBaseModel}from"./models/data/base/index.js";export{IkasBlogCategory}from"./models/data/blog/category/index.js";export{IkasBlogContent}from"./models/data/blog/content/index.js";export{IkasBlogMetaData,IkasBlogMetaDataTargetType}from"./models/data/blog/meta-data/index.js";export{IkasBlogTag}from"./models/data/blog/tag/index.js";export{IkasBlogWriter}from"./models/data/blog/writer/index.js";export{IkasBlog}from"./models/data/blog/index.js";export{IkasProductBrandTranslation}from"./models/data/brand/translation/index.js";export{IkasBrand,IkasBrandOrderType}from"./models/data/brand/index.js";export{IkasCampaignOfferProduct,IkasCampaignOfferProductTranslation}from"./models/data/campaign-offer/product/index.js";export{IkasCampaignOffer,IkasCampaignOfferTriggerSettings}from"./models/data/campaign-offer/index.js";export{IkasAvailableShippingMethod}from"./models/data/cart/available-shipping-method/index.js";export{IkasCartCampaignOffer}from"./models/data/cart/campaign-offer/index.js";export{IkasCart}from"./models/data/cart/index.js";export{IkasCategoryPathItem}from"./models/data/category/path-item/index.js";export{IkasCategoryTranslation}from"./models/data/category/translations/index.js";export{IkasCategory}from"./models/data/category/index.js";export{IkasCheckout}from"./models/data/checkout/index.js";export{IkasCheckoutOption}from"./models/data/checkout-settings/option/index.js";export{IkasCheckoutSettingsPrice}from"./models/data/checkout-settings/price/index.js";export{IkasCheckoutSettings}from"./models/data/checkout-settings/index.js";export{IkasCity}from"./models/data/city/index.js";export{IkasContactForm}from"./models/data/contact-form/index.js";export{IkasCountry}from"./models/data/country/index.js";export{IkasCustomerAddressCity}from"./models/data/customer/address/city/index.js";export{IkasCustomerAddressCountry}from"./models/data/customer/address/country/index.js";export{IkasCustomerAddressDistrict}from"./models/data/customer/address/district/index.js";export{IkasCustomerAddressRegion}from"./models/data/customer/address/region/index.js";export{IkasCustomerAddressState}from"./models/data/customer/address/state/index.js";export{IkasCustomerAddress}from"./models/data/customer/address/index.js";export{IkasLocalizedCustomerAddress}from"./models/data/customer/address/ikas-localized-customer-address.js";export{IkasCustomerAttributeOption}from"./models/data/customer/attribute/option/index.js";export{IkasCustomerAttributeSalesChannel}from"./models/data/customer/attribute/sales-channel/index.js";export{IkasCustomerAttributeOptionTranslation}from"./models/data/customer/attribute/translation/option/index.js";export{IkasCustomerAttributeTranslation}from"./models/data/customer/attribute/translation/index.js";export{IkasCustomerAttributeValue}from"./models/data/customer/attribute/value/index.js";export{IkasCustomerAttribute}from"./models/data/customer/attribute/index.js";export{IkasCustomerPriceListRuleFilter}from"./models/data/customer/price-list-rule/filter/index.js";export{IkasCustomerPriceListRule}from"./models/data/customer/price-list-rule/index.js";export{IkasCustomerReviewSettings}from"./models/data/customer/review/settings/index.js";export{IkasCustomerReviewSummaryStar}from"./models/data/customer/review/summary/star/index.js";export{IkasCustomerReviewSummary}from"./models/data/customer/review/summary/index.js";export{IkasCustomerReview}from"./models/data/customer/review/index.js";export{IkasCustomer}from"./models/data/customer/index.js";export{IkasCustomerRegisterSubscriptionInput}from"./models/data/customer-form-data-input/customer-register-subscription-input/index.js";export{IkasCustomerGenderTypeEnum,IkasSaveCustomerFormDataInput}from"./models/data/customer-form-data-input/index.js";export{IkasDistrict}from"./models/data/district/index.js";export{IkasFavoriteProduct}from"./models/data/favorite-product/index.js";export{IkasFilterCategory}from"./models/data/filter-category/index.js";export{IkasHTMLMetaDataTranslations}from"./models/data/html-meta-data/translations/index.js";export{IkasHTMLMetaData,IkasHTMLMetaDataOverride,IkasHTMLMetaDataTargetType}from"./models/data/html-meta-data/index.js";export{IkasImage}from"./models/data/image/index.js";export{IkasLastViewedProduct}from"./models/data/last-viewed-product/index.js";export{IkasMerchantSettings}from"./models/data/merchant-settings/index.js";export{IkasOrderAddressCity}from"./models/data/order/address/city/index.js";export{IkasOrderAddressCountry}from"./models/data/order/address/country/index.js";export{IkasOrderAddressDistrict}from"./models/data/order/address/district/index.js";export{IkasOrderAddressRegion}from"./models/data/order/address/region/index.js";export{IkasOrderAddressState}from"./models/data/order/address/state/index.js";export{IkasOrderAddress}from"./models/data/order/address/index.js";export{IkasOrderAdjustmentAppliedOrderLine}from"./models/data/order/adjustment/applied-order-line/index.js";export{IkasOrderAdjustment}from"./models/data/order/adjustment/index.js";export{IkasOrderCustomer}from"./models/data/order/customer/index.js";export{IkasOrderGiftPackageLine}from"./models/data/order/gift-line/index.js";export{IkasInvoice}from"./models/data/order/invoice/index.js";export{IkasOrderLineDiscount}from"./models/data/order/line-item/discount/index.js";export{IkasOrderLineItemOptionValue}from"./models/data/order/line-item/option/value/index.js";export{IkasOrderLineItemOption}from"./models/data/order/line-item/option/index.js";export{IkasOrderLineVariantBrand}from"./models/data/order/line-item/variant/brand/index.js";export{IkasOrderLineVariantCategory,IkasOrderLineVariantCategoryPath}from"./models/data/order/line-item/variant/category/index.js";export{IkasOrderLineVariantPrice}from"./models/data/order/line-item/variant/price/index.js";export{IkasOrderLineVariantVariantValue}from"./models/data/order/line-item/variant/value/index.js";export{IkasOrderLineVariant}from"./models/data/order/line-item/variant/index.js";export{IkasOrderLineItem}from"./models/data/order/line-item/index.js";export{IkasOrderTransactionWithPrices}from"./models/data/order/order-transaction-with-prices/index.js";export{IkasTrackingInfo}from"./models/data/order/package/tracking-info/index.js";export{IkasOrderPackage}from"./models/data/order/package/index.js";export{IkasOrderPaymentMethod}from"./models/data/order/payment-method/index.js";export{IkasOrderRefundOrderLineInput}from"./models/data/order/refund/line-item/index.js";export{IkasOrderRefundSettings}from"./models/data/order/refund/settings/index.js";export{IkasRefund}from"./models/data/order/refund/index.js";export{IkasOrderShippingLine}from"./models/data/order/shipping-line/index.js";export{IkasOrderTaxLine}from"./models/data/order/tax-line/index.js";export{IkasTransactionError}from"./models/data/order/transaction/error/index.js";export{IkasTransactionInstallmentPrice}from"./models/data/order/transaction/payment-method-detail/installment-price/index.js";export{IkasTransactionPaymentMethodDetail}from"./models/data/order/transaction/payment-method-detail/index.js";export{IkasOrderTransaction}from"./models/data/order/transaction/index.js";export{IkasOrder}from"./models/data/order/index.js";export{IkasPaymentGatewayAdditionalPrice}from"./models/data/payment-gateway/additional-price/index.js";export{IkasPaymentGatewaySettings}from"./models/data/payment-gateway/settings/index.js";export{IkasPaymentGatewayTranslation}from"./models/data/payment-gateway/translation/index.js";export{IkasPaymentGateway}from"./models/data/payment-gateway/index.js";export{IkasProductAttributeOption}from"./models/data/product/attribute/option/index.js";export{IkasProductAttributeTableCell}from"./models/data/product/attribute/table-cell/index.js";export{IkasProductAttributeTableTemplate}from"./models/data/product/attribute/table-template/index.js";export{IkasProductAttributeOptionTranslation,IkasProductAttributeTranslation}from"./models/data/product/attribute/translation/index.js";export{IkasProductAttribute}from"./models/data/product/attribute/index.js";export{IkasAttributeTableCellValue,IkasProductAttributeMap,IkasProductAttributeValue}from"./models/data/product/attribute-value/index.js";export{IkasProductBackInStockSettings}from"./models/data/product/back-in-stock-settings/index.js";export{IkasApplicableProductFilterValue,IkasFilterRangeValue,IkasProductFilter,IkasProductFilterNumberRangeListOption,IkasProductFilterSettings,IkasProductFilterValue,parseRangeStr}from"./models/data/product/filter/index.js";export{IkasProductCampaignData}from"./models/data/product/campaign/data/index.js";export{IkasProductCampaignFilter}from"./models/data/product/campaign/filter/index.js";export{IkasProductBuyX,IkasProductBuyXThenGetY,IkasProductGetY}from"./models/data/product/campaign/product-buyx-then-gety/index.js";export{IkasProductCampaignDateRangeField}from"./models/data/product/campaign/product-campaign-date-range-field/index.js";export{IkasCampaignMinMaxRangeField,IkasProductFixedDiscount}from"./models/data/product/campaign/product-fixed-discount/index.js";export{IkasProductCampaign}from"./models/data/product/campaign/index.js";export{IkasProductCampaignOffer,IkasProductOffer}from"./models/data/product/campaign-offer/index.js";export{IkasProductImage}from"./models/data/product/image/index.js";export{IkasProductOption,IkasProductOptionDateSettings,IkasProductOptionFileSettings,IkasProductOptionOtherPrice,IkasProductOptionSelectSettings,IkasProductOptionSelectValue,IkasProductOptionTextSettings}from"./models/data/product/option-set/option/index.js";export{IkasProductOptionSelectValueTranslations,IkasProductOptionSet,IkasProductOptionSetTranslations,IkasProductOptionTranslations}from"./models/data/product/option-set/index.js";export{IkasProductStockLocations}from"./models/data/product/stock-location/index.js";export{IkasProductTag}from"./models/data/product/tag/index.js";export{IkasProductPrice}from"./models/data/product/variant/price/index.js";export{IkasProductVariant}from"./models/data/product/variant/index.js";export{IkasProductVariantType}from"./models/data/product/variant-type/index.js";export{IkasProduct}from"./models/data/product/index.js";export{IkasProductFile}from"./models/data/product-file/index.js";export{IkasRaffle,IkasRaffleAppliedProduct,IkasRaffleDateRangeField,IkasRaffleMetaData,IkasRaffleParticipant}from"./models/data/raffle/index.js";export{IkasSalesChannel,IkasSalesChannelPaymentGateway,IkasSalesChannelStockLocation}from"./models/data/sales-channel/index.js";export{IkasShippingZoneRegion}from"./models/data/shipping-zone/state/city/district/region/index.js";export{IkasShippingZoneDistrict}from"./models/data/shipping-zone/state/city/district/index.js";export{IkasShippingZoneCity}from"./models/data/shipping-zone/state/city/index.js";export{IkasShippingZoneState}from"./models/data/shipping-zone/state/index.js";export{IkasShippingZone}from"./models/data/shipping-zone/index.js";export{IkasState}from"./models/data/state/index.js";export{IkasStockLocationAddressCity}from"./models/data/stock-location/address/city/index.js";export{IkasStockLocationAddressCountry}from"./models/data/stock-location/address/country/index.js";export{IkasStockLocationAddressDistrict}from"./models/data/stock-location/address/district/index.js";export{IkasStockLocationAddressState}from"./models/data/stock-location/address/state/index.js";export{IkasStockLocationAddress}from"./models/data/stock-location/address/index.js";export{IkasAvailableStockLocation}from"./models/data/stock-location/available/index.js";export{IkasStockLocation}from"./models/data/stock-location/index.js";export{IkasStorefrontPopupAnalytics}from"./models/data/storefront-popup/storefront-popup-analytics/index.js";export{IkasStorefrontPopupDateFilter}from"./models/data/storefront-popup/storefront-popup-date-filter/index.js";export{IkasStorefrontPopupDisplayFilter,IkasStorefrontPopupDisplayFilterTypeEnum}from"./models/data/storefront-popup/storefront-popup-display-filter/index.js";export{IkasStorefrontPopupDisplayFrequencyEnum,IkasStorefrontPopupDisplaySettings,IkasStorefrontPopupDisplayTriggerTypeEnum}from"./models/data/storefront-popup/storefront-popup-display-settings/index.js";export{IkasStorefrontPopupPageFilter,IkasStorefrontPopupPageFilterTypeEnum}from"./models/data/storefront-popup/storefront-popup-page-filter/index.js";export{IkasStorefrontPopupRouting}from"./models/data/storefront-popup/storefront-popup-routing/index.js";export{IkasStorefrontPopup,IkasStorefrontPopupDeviceTypeEnum,IkasStorefrontPopupStatusEnum,IkasStorefrontPopupTypeEnum}from"./models/data/storefront-popup/index.js";export{IkasStorefrontB2BSettings}from"./models/data/storefront/b2b-settings/index.js";export{IkasStorefrontDomain}from"./models/data/storefront/domain/index.js";export{IkasIndexPageSeoSetting}from"./models/data/storefront/index-page-seo-setting/index.js";export{IkasStorefrontLocalization}from"./models/data/storefront/localization/index.js";export{IkasStorefrontDynamicCurrencySettings}from"./models/data/storefront/routing/dynamic-currency/index.js";export{IkasStorefrontRouting}from"./models/data/storefront/routing/index.js";export{IkasStorefrontTheme}from"./models/data/storefront/theme/index.js";export{IkasStorefrontThemeLocalization}from"./models/data/storefront/theme-localization/index.js";export{IkasStorefront}from"./models/data/storefront/index.js";export{IkasThemeJsonComponentProp}from"./models/data/theme-json/component/prop/index.js";export{ComponentTranslation,IkasThemeJsonComponent}from"./models/data/theme-json/component/index.js";export{IkasThemeJsonCustomData,IkasThemeJsonCustomDataEnumOptionTranslation,IkasThemeJsonCustomDataTranslation,IkasThemeJsonEnumOption}from"./models/data/theme-json/custom-data/index.js";export{IkasThemeJsonPageComponent}from"./models/data/theme-json/page/component/index.js";export{IkasThemeJsonPage,IkasThemeJsonPageSpecification}from"./models/data/theme-json/page/index.js";export{IkasThemeJsonColor,IkasThemeJsonColorTranslation}from"./models/data/theme-json/settings/color/index.js";export{IkasThemeJsonFavicon}from"./models/data/theme-json/settings/favicon/index.js";export{IkasThemeJsonFontFamily}from"./models/data/theme-json/settings/font-family/index.js";export{IkasThemeJsonSettings}from"./models/data/theme-json/settings/index.js";export{CHECKOUT_ID,IkasThemeJson}from"./models/data/theme-json/index.js";export{IkasVariantValue}from"./models/data/variant-type/variant-value/index.js";export{IkasVariantType}from"./models/data/variant-type/index.js";export{IkasVideo}from"./models/data/video/index.js";export{AddressFormItem,BillingFormItem}from"@ikas/localized-address";export{IkasBlogList,IkasBlogListType}from"./models/ui/blog-list/index.js";export{IkasBlogCategoryList,IkasBlogCategoryListType}from"./models/ui/blog-category-list/index.js";export{IkasBrandList,IkasBrandListSortType,IkasBrandListType}from"./models/ui/brand-list/index.js";export{IkasCategoryList,IkasCategoryListSortType,IkasCategoryListType}from"./models/ui/category-list/index.js";export{IkasNavigationLink}from"./models/ui/navigation-link/index.js";export{IkasProductList,IkasProductListSortByTypeEnum,IkasProductListSortType,IkasProductListType,IkasRelatedProductsType}from"./models/ui/product-list/index.js";export{IkasAttributeDetail}from"./models/ui/product-attribute-detail/index.js";export{IkasAttributeList}from"./models/ui/product-attribute-list/index.js";export{IkasCustomerReviewList}from"./models/ui/customer-review-list/index.js";export{IkasCustomerReviewSummaryList}from"./models/ui/customer-review-summary-list/index.js";export{Validator}from"./models/ui/validator/index.js";export{EmailRule,EqualsRule,IdentityNumberRule,LessThanRule,MaxRule,MinRule,PhoneRule,RequiredRule,ValidationRule,ValidatorErrorType}from"./models/ui/validator/rules/index.js";export{LoginForm}from"./models/ui/validator/form/login.js";export{AddressForm}from"./models/ui/validator/form/address.js";export{IkasAddressForm}from"./models/ui/validator/form/ikas-address.js";export{RegisterForm}from"./models/ui/validator/form/register.js";export{ContactForm}from"./models/ui/validator/form/contact-form.js";export{ForgotPasswordForm}from"./models/ui/validator/form/forgot-password.js";export{RecoverPasswordForm}from"./models/ui/validator/form/recover-password.js";export{AccountInfoForm}from"./models/ui/validator/form/account-info.js";export{RaffleForm}from"./models/ui/validator/form/raffle-form.js";export{CustomerReviewForm}from"./models/ui/validator/form/customer-review.js";export{IkasComponentRenderer}from"./models/ui/component-renderer/index.js";export{IkasRaffleList}from"./models/ui/raffle-list/index.js";import*as e from"./pages/home.js";export{e as IndexPage};import*as t from"./pages/_slug_/index.js";export{t as SlugPage};import*as o from"./pages/pages/_slug_.js";export{o as CustomPage};import*as a from"./pages/checkout.js";export{a as CheckoutPage};import*as r from"./pages/account/index.js";export{r as AccountPage};import*as s from"./pages/account/addresses.js";export{s as AddressesPage};import*as d from"./pages/account/orders/index.js";export{d as OrdersPage};import*as i from"./pages/account/orders/_id_.js";export{i as OrderDetailPage};import*as n from"./pages/account/login.js";export{n as LoginPage};import*as m from"./pages/account/register.js";export{m as RegisterPage};import*as p from"./pages/account/forgot-password.js";export{p as ForgotPasswordPage};import*as l from"./pages/account/recover-password.js";export{l as RecoverPasswordPage};import*as x from"./pages/cart.js";export{x as CartPage};import*as u from"./pages/editor.js";export{u as EditorPage};import*as c from"./pages/account/favorite-products.js";export{c as FavoriteProductsPage};import*as f from"./pages/search.js";export{f as SearchPage};import*as k from"./pages/404.js";export{k as NotFoundPage};import*as I from"./pages/blog/index.js";export{I as BlogPage};import*as g from"./pages/blog/_slug_.js";export{g as BlogSlugPage};import*as j from"./pages/raffle/_slug_.js";export{j as RafflePage};import*as y from"./pages/raffle/index.js";export{y as RafflesPage};import*as P from"./pages/account/raffles.js";export{P as AccountRafflesPage};import*as T from"./pages/account/activate.js";export{T as ActivateCustomerPage};export{IkasBaseStore}from"./store/base.js";export{IkasCustomerStore}from"./store/customer/index.js";export{IkasCartStore}from"./store/cart/index.js";export{formatDate}from"./utils/helper.js";export{formatCurrency}from"./utils/currency.js";export{createTranslationInputData,useTranslation}from"./utils/i18n.js";export{IkasAdjustmentType,IkasAmountType,IkasCampaignApplicablePrice,IkasCampaignCreatedFor,IkasCampaignFilterType,IkasCampaignOfferProductShowCriteria,IkasCampaignOfferTargetPageType,IkasCampaignType,IkasCartCampaignOfferStatus,IkasCategoryProductsOrderType as IkasCategoryOrderType,IkasCheckoutRequirement,IkasCustomerAccountStatus,IkasCustomerAttributeType,IkasCustomerEmailSubscriptionStatus,IkasCustomerPriceListRuleFilterType,IkasCustomerPriceListRuleValueType,IkasCustomerRegistrationSource,IkasCustomerReviewStatus,IkasInvoiceType,IkasOrderCancelReason,IkasOrderLineItemStatus,IkasOrderPackageFullfillStatus,IkasOrderPackageStatus,IkasOrderPaymentStatus,IkasOrderShippingMethod,IkasOrderStatus,IkasPaymentGatewayAdditionalPriceType,IkasPaymentGatewaySettingsType,IkasPaymentGatewayTransactionFeeType,IkasPaymentGatewayType,IkasPaymentMethodType,IkasPaymentMethodTypeWithPrices,IkasProductAttributeType,IkasProductFilterDisplayType,IkasProductFilterSortType,IkasProductFilterType,IkasProductOptionSelectType,IkasProductOptionType,IkasProductStockFilterValue,IkasProductType,IkasRaffleMetadataTargetType,IkasRaffleVerificationType,IkasShippingMethod,IkasStockLocationDeliveryTime,IkasStockLocationType,IkasStorefrontB2BShowPricesEnum,IkasStorefrontB2BShowProductsEnum,IkasStorefrontStatus,IkasThemeJsonComponentPropType,IkasThemeJsonPageType,IkasThemeJsonStockPreference,IkasTransactionSourceWithPrices,IkasTransactionStatus,IkasTransactionStatusWithPrices,IkasTransactionType,IkasTransactionTypeWithPrices,IkasVariantSelectionType}from"@ikas/storefront-models";export{IkasTransactionWithPrices}from"./models/data/order/order-transaction-with-prices/transaction-with-prices/index.js";
|
|
1
|
+
export{Analytics}from"./analytics/analytics.js";export{AnalyticsBody,AnalyticsHead}from"./analytics/head/index.js";export{IkasPage}from"./components/page/index.js";export{IkasPageHead}from"./components/page/head.js";export{Image}from"./components/image/index.js";export{PlainImage}from"./components/plain-image/index.js";export{default as Link}from"./components/link/index.js";export{IkasEditorComponentLoader}from"./components/page-editor/loader/index.js";export{GoogleCaptcha}from"./components/google-captcha/index.js";export{PaypalExpressCheckout}from"./components/paypal-express-checkout/index.js";export{useStore}from"./hooks/useStore.js";export{useCustomerReviews}from"./hooks/useCustomerReviews.js";import"react";export{IkasBaseModel}from"./models/data/base/index.js";export{IkasBlogCategory}from"./models/data/blog/category/index.js";export{IkasBlogContent}from"./models/data/blog/content/index.js";export{IkasBlogMetaData,IkasBlogMetaDataTargetType}from"./models/data/blog/meta-data/index.js";export{IkasBlogTag}from"./models/data/blog/tag/index.js";export{IkasBlogWriter}from"./models/data/blog/writer/index.js";export{IkasBlog}from"./models/data/blog/index.js";export{IkasProductBrandTranslation}from"./models/data/brand/translation/index.js";export{IkasBrand,IkasBrandOrderType}from"./models/data/brand/index.js";export{IkasCampaignOfferProduct,IkasCampaignOfferProductTranslation}from"./models/data/campaign-offer/product/index.js";export{IkasCampaignOffer,IkasCampaignOfferTriggerSettings}from"./models/data/campaign-offer/index.js";export{IkasAvailableShippingMethod}from"./models/data/cart/available-shipping-method/index.js";export{IkasCartCampaignOffer}from"./models/data/cart/campaign-offer/index.js";export{IkasCart}from"./models/data/cart/index.js";export{IkasCategoryPathItem}from"./models/data/category/path-item/index.js";export{IkasCategoryTranslation}from"./models/data/category/translations/index.js";export{IkasCategory}from"./models/data/category/index.js";export{IkasCheckout}from"./models/data/checkout/index.js";export{IkasCheckoutOption}from"./models/data/checkout-settings/option/index.js";export{IkasCheckoutSettingsPrice}from"./models/data/checkout-settings/price/index.js";export{IkasCheckoutSettings}from"./models/data/checkout-settings/index.js";export{IkasCity}from"./models/data/city/index.js";export{IkasContactForm}from"./models/data/contact-form/index.js";export{IkasCountry}from"./models/data/country/index.js";export{IkasCustomerAddressCity}from"./models/data/customer/address/city/index.js";export{IkasCustomerAddressCountry}from"./models/data/customer/address/country/index.js";export{IkasCustomerAddressDistrict}from"./models/data/customer/address/district/index.js";export{IkasCustomerAddressRegion}from"./models/data/customer/address/region/index.js";export{IkasCustomerAddressState}from"./models/data/customer/address/state/index.js";export{IkasCustomerAddress}from"./models/data/customer/address/index.js";export{IkasLocalizedCustomerAddress}from"./models/data/customer/address/ikas-localized-customer-address.js";export{IkasCustomerAttributeOption}from"./models/data/customer/attribute/option/index.js";export{IkasCustomerAttributeSalesChannel}from"./models/data/customer/attribute/sales-channel/index.js";export{IkasCustomerAttributeOptionTranslation}from"./models/data/customer/attribute/translation/option/index.js";export{IkasCustomerAttributeTranslation}from"./models/data/customer/attribute/translation/index.js";export{IkasCustomerAttributeValue}from"./models/data/customer/attribute/value/index.js";export{IkasCustomerAttribute}from"./models/data/customer/attribute/index.js";export{IkasCustomerPriceListRuleFilter}from"./models/data/customer/price-list-rule/filter/index.js";export{IkasCustomerPriceListRule}from"./models/data/customer/price-list-rule/index.js";export{IkasCustomerReviewSettings}from"./models/data/customer/review/settings/index.js";export{IkasCustomerReviewSummaryStar}from"./models/data/customer/review/summary/star/index.js";export{IkasCustomerReviewSummary}from"./models/data/customer/review/summary/index.js";export{IkasCustomerReview}from"./models/data/customer/review/index.js";export{IkasCustomer}from"./models/data/customer/index.js";export{IkasCustomerRegisterSubscriptionInput}from"./models/data/customer-form-data-input/customer-register-subscription-input/index.js";export{IkasCustomerGenderTypeEnum,IkasSaveCustomerFormDataInput}from"./models/data/customer-form-data-input/index.js";export{IkasDistrict}from"./models/data/district/index.js";export{IkasFavoriteProduct}from"./models/data/favorite-product/index.js";export{IkasFilterCategory}from"./models/data/filter-category/index.js";export{IkasHTMLMetaDataTranslations}from"./models/data/html-meta-data/translations/index.js";export{IkasHTMLMetaData,IkasHTMLMetaDataOverride,IkasHTMLMetaDataTargetType}from"./models/data/html-meta-data/index.js";export{IkasImage}from"./models/data/image/index.js";export{IkasLastViewedProduct}from"./models/data/last-viewed-product/index.js";export{IkasMerchantSettings}from"./models/data/merchant-settings/index.js";export{IkasOrderAddressCity}from"./models/data/order/address/city/index.js";export{IkasOrderAddressCountry}from"./models/data/order/address/country/index.js";export{IkasOrderAddressDistrict}from"./models/data/order/address/district/index.js";export{IkasOrderAddressRegion}from"./models/data/order/address/region/index.js";export{IkasOrderAddressState}from"./models/data/order/address/state/index.js";export{IkasOrderAddress}from"./models/data/order/address/index.js";export{IkasOrderAdjustmentAppliedOrderLine}from"./models/data/order/adjustment/applied-order-line/index.js";export{IkasOrderAdjustment}from"./models/data/order/adjustment/index.js";export{IkasOrderCustomer}from"./models/data/order/customer/index.js";export{IkasOrderGiftPackageLine}from"./models/data/order/gift-line/index.js";export{IkasInvoice}from"./models/data/order/invoice/index.js";export{IkasOrderLineDiscount}from"./models/data/order/line-item/discount/index.js";export{IkasOrderLineItemOptionValue}from"./models/data/order/line-item/option/value/index.js";export{IkasOrderLineItemOption}from"./models/data/order/line-item/option/index.js";export{IkasOrderLineVariantBrand}from"./models/data/order/line-item/variant/brand/index.js";export{IkasOrderLineVariantCategory,IkasOrderLineVariantCategoryPath}from"./models/data/order/line-item/variant/category/index.js";export{IkasOrderLineVariantPrice}from"./models/data/order/line-item/variant/price/index.js";export{IkasOrderLineVariantVariantValue}from"./models/data/order/line-item/variant/value/index.js";export{IkasOrderLineVariant}from"./models/data/order/line-item/variant/index.js";export{IkasOrderLineItem}from"./models/data/order/line-item/index.js";export{IkasOrderTransactionWithPrices}from"./models/data/order/order-transaction-with-prices/index.js";export{IkasTrackingInfo}from"./models/data/order/package/tracking-info/index.js";export{IkasOrderPackage}from"./models/data/order/package/index.js";export{IkasOrderPaymentMethod}from"./models/data/order/payment-method/index.js";export{IkasOrderRefundOrderLineInput}from"./models/data/order/refund/line-item/index.js";export{IkasOrderRefundSettings}from"./models/data/order/refund/settings/index.js";export{IkasRefund}from"./models/data/order/refund/index.js";export{IkasOrderShippingLine}from"./models/data/order/shipping-line/index.js";export{IkasOrderTaxLine}from"./models/data/order/tax-line/index.js";export{IkasTransactionError}from"./models/data/order/transaction/error/index.js";export{IkasTransactionInstallmentPrice}from"./models/data/order/transaction/payment-method-detail/installment-price/index.js";export{IkasTransactionPaymentMethodDetail}from"./models/data/order/transaction/payment-method-detail/index.js";export{IkasOrderTransaction}from"./models/data/order/transaction/index.js";export{IkasOrder}from"./models/data/order/index.js";export{IkasPaymentGatewayAdditionalPrice}from"./models/data/payment-gateway/additional-price/index.js";export{IkasPaymentGatewaySettings}from"./models/data/payment-gateway/settings/index.js";export{IkasPaymentGatewayTranslation}from"./models/data/payment-gateway/translation/index.js";export{IkasPaymentGateway}from"./models/data/payment-gateway/index.js";export{IkasProductAttributeOption}from"./models/data/product/attribute/option/index.js";export{IkasProductAttributeTableCell}from"./models/data/product/attribute/table-cell/index.js";export{IkasProductAttributeTableTemplate}from"./models/data/product/attribute/table-template/index.js";export{IkasProductAttributeOptionTranslation,IkasProductAttributeTranslation}from"./models/data/product/attribute/translation/index.js";export{IkasProductAttribute}from"./models/data/product/attribute/index.js";export{IkasAttributeTableCellValue,IkasProductAttributeMap,IkasProductAttributeValue}from"./models/data/product/attribute-value/index.js";export{IkasProductBackInStockSettings}from"./models/data/product/back-in-stock-settings/index.js";export{IkasApplicableProductFilterValue,IkasFilterRangeValue,IkasProductFilter,IkasProductFilterNumberRangeListOption,IkasProductFilterSettings,IkasProductFilterValue,parseRangeStr}from"./models/data/product/filter/index.js";export{IkasProductCampaignData}from"./models/data/product/campaign/data/index.js";export{IkasProductCampaignFilter}from"./models/data/product/campaign/filter/index.js";export{IkasProductBuyX,IkasProductBuyXThenGetY,IkasProductGetY}from"./models/data/product/campaign/product-buyx-then-gety/index.js";export{IkasProductCampaignDateRangeField}from"./models/data/product/campaign/product-campaign-date-range-field/index.js";export{IkasCampaignMinMaxRangeField,IkasProductFixedDiscount}from"./models/data/product/campaign/product-fixed-discount/index.js";export{IkasProductCampaign}from"./models/data/product/campaign/index.js";export{IkasProductCampaignOffer,IkasProductOffer}from"./models/data/product/campaign-offer/index.js";export{IkasProductImage}from"./models/data/product/image/index.js";export{IkasProductOption,IkasProductOptionDateSettings,IkasProductOptionFileSettings,IkasProductOptionOtherPrice,IkasProductOptionSelectSettings,IkasProductOptionSelectValue,IkasProductOptionTextSettings}from"./models/data/product/option-set/option/index.js";export{IkasProductOptionSelectValueTranslations,IkasProductOptionSet,IkasProductOptionSetTranslations,IkasProductOptionTranslations}from"./models/data/product/option-set/index.js";export{IkasProductStockLocations}from"./models/data/product/stock-location/index.js";export{IkasProductTag}from"./models/data/product/tag/index.js";export{IkasProductPrice}from"./models/data/product/variant/price/index.js";export{IkasProductVariant}from"./models/data/product/variant/index.js";export{IkasProductVariantType}from"./models/data/product/variant-type/index.js";export{IkasProduct}from"./models/data/product/index.js";export{IkasProductFile}from"./models/data/product-file/index.js";export{IkasRaffle,IkasRaffleAppliedProduct,IkasRaffleDateRangeField,IkasRaffleMetaData,IkasRaffleParticipant}from"./models/data/raffle/index.js";export{IkasSalesChannel,IkasSalesChannelPaymentGateway,IkasSalesChannelStockLocation}from"./models/data/sales-channel/index.js";export{IkasShippingZoneRegion}from"./models/data/shipping-zone/state/city/district/region/index.js";export{IkasShippingZoneDistrict}from"./models/data/shipping-zone/state/city/district/index.js";export{IkasShippingZoneCity}from"./models/data/shipping-zone/state/city/index.js";export{IkasShippingZoneState}from"./models/data/shipping-zone/state/index.js";export{IkasShippingZone}from"./models/data/shipping-zone/index.js";export{IkasState}from"./models/data/state/index.js";export{IkasStockLocationAddressCity}from"./models/data/stock-location/address/city/index.js";export{IkasStockLocationAddressCountry}from"./models/data/stock-location/address/country/index.js";export{IkasStockLocationAddressDistrict}from"./models/data/stock-location/address/district/index.js";export{IkasStockLocationAddressState}from"./models/data/stock-location/address/state/index.js";export{IkasStockLocationAddress}from"./models/data/stock-location/address/index.js";export{IkasAvailableStockLocation}from"./models/data/stock-location/available/index.js";export{IkasStockLocation}from"./models/data/stock-location/index.js";export{IkasStorefrontPopupAnalytics}from"./models/data/storefront-popup/storefront-popup-analytics/index.js";export{IkasStorefrontPopupDateFilter}from"./models/data/storefront-popup/storefront-popup-date-filter/index.js";export{IkasStorefrontPopupDisplayFilter,IkasStorefrontPopupDisplayFilterTypeEnum}from"./models/data/storefront-popup/storefront-popup-display-filter/index.js";export{IkasStorefrontPopupDisplayFrequencyEnum,IkasStorefrontPopupDisplaySettings,IkasStorefrontPopupDisplayTriggerTypeEnum}from"./models/data/storefront-popup/storefront-popup-display-settings/index.js";export{IkasStorefrontPopupPageFilter,IkasStorefrontPopupPageFilterTypeEnum}from"./models/data/storefront-popup/storefront-popup-page-filter/index.js";export{IkasStorefrontPopupRouting}from"./models/data/storefront-popup/storefront-popup-routing/index.js";export{IkasStorefrontPopup,IkasStorefrontPopupDeviceTypeEnum,IkasStorefrontPopupStatusEnum,IkasStorefrontPopupTypeEnum}from"./models/data/storefront-popup/index.js";export{IkasStorefrontB2BSettings}from"./models/data/storefront/b2b-settings/index.js";export{IkasStorefrontDomain}from"./models/data/storefront/domain/index.js";export{IkasIndexPageSeoSetting}from"./models/data/storefront/index-page-seo-setting/index.js";export{IkasStorefrontLocalization}from"./models/data/storefront/localization/index.js";export{IkasStorefrontDynamicCurrencySettings}from"./models/data/storefront/routing/dynamic-currency/index.js";export{IkasStorefrontRouting}from"./models/data/storefront/routing/index.js";export{IkasStorefrontTheme}from"./models/data/storefront/theme/index.js";export{IkasStorefrontThemeLocalization}from"./models/data/storefront/theme-localization/index.js";export{IkasStorefront}from"./models/data/storefront/index.js";export{IkasThemeJsonComponentProp}from"./models/data/theme-json/component/prop/index.js";export{ComponentTranslation,IkasThemeJsonComponent}from"./models/data/theme-json/component/index.js";export{IkasThemeJsonCustomData,IkasThemeJsonCustomDataEnumOptionTranslation,IkasThemeJsonCustomDataTranslation,IkasThemeJsonEnumOption}from"./models/data/theme-json/custom-data/index.js";export{IkasThemeJsonPageComponent}from"./models/data/theme-json/page/component/index.js";export{IkasThemeJsonPage,IkasThemeJsonPageSpecification}from"./models/data/theme-json/page/index.js";export{IkasThemeJsonColor,IkasThemeJsonColorTranslation}from"./models/data/theme-json/settings/color/index.js";export{IkasThemeJsonFavicon}from"./models/data/theme-json/settings/favicon/index.js";export{IkasThemeJsonFontFamily}from"./models/data/theme-json/settings/font-family/index.js";export{IkasThemeJsonSettings}from"./models/data/theme-json/settings/index.js";export{CHECKOUT_ID,IkasThemeJson}from"./models/data/theme-json/index.js";export{IkasVariantValue}from"./models/data/variant-type/variant-value/index.js";export{IkasVariantType}from"./models/data/variant-type/index.js";export{IkasVideo}from"./models/data/video/index.js";export{AddressFormItem,BillingFormItem}from"@ikas/localized-address";export{IkasBlogList,IkasBlogListType}from"./models/ui/blog-list/index.js";export{IkasBlogCategoryList,IkasBlogCategoryListType}from"./models/ui/blog-category-list/index.js";export{IkasBrandList,IkasBrandListSortType,IkasBrandListType}from"./models/ui/brand-list/index.js";export{IkasCategoryList,IkasCategoryListSortType,IkasCategoryListType}from"./models/ui/category-list/index.js";export{IkasNavigationLink}from"./models/ui/navigation-link/index.js";export{IkasProductList,IkasProductListSortByTypeEnum,IkasProductListSortType,IkasProductListType,IkasRelatedProductsType}from"./models/ui/product-list/index.js";export{IkasAttributeDetail}from"./models/ui/product-attribute-detail/index.js";export{IkasAttributeList}from"./models/ui/product-attribute-list/index.js";export{IkasCustomerReviewList}from"./models/ui/customer-review-list/index.js";export{IkasCustomerReviewSummaryList}from"./models/ui/customer-review-summary-list/index.js";export{Validator}from"./models/ui/validator/index.js";export{EmailRule,EqualsRule,IdentityNumberRule,LessThanRule,MaxRule,MinRule,PhoneRule,RequiredRule,ValidationRule,ValidatorErrorType}from"./models/ui/validator/rules/index.js";export{LoginForm}from"./models/ui/validator/form/login.js";export{AddressForm}from"./models/ui/validator/form/address.js";export{IkasAddressForm}from"./models/ui/validator/form/ikas-address.js";export{RegisterForm}from"./models/ui/validator/form/register.js";export{ContactForm}from"./models/ui/validator/form/contact-form.js";export{ForgotPasswordForm}from"./models/ui/validator/form/forgot-password.js";export{RecoverPasswordForm}from"./models/ui/validator/form/recover-password.js";export{AccountInfoForm}from"./models/ui/validator/form/account-info.js";export{RaffleForm}from"./models/ui/validator/form/raffle-form.js";export{CustomerReviewForm}from"./models/ui/validator/form/customer-review.js";export{IkasComponentRenderer}from"./models/ui/component-renderer/index.js";export{IkasRaffleList}from"./models/ui/raffle-list/index.js";import*as e from"./pages/home.js";export{e as IndexPage};import*as t from"./pages/_slug_/index.js";export{t as SlugPage};import*as o from"./pages/pages/_slug_.js";export{o as CustomPage};import*as a from"./pages/checkout.js";export{a as CheckoutPage};import*as r from"./pages/account/index.js";export{r as AccountPage};import*as s from"./pages/account/addresses.js";export{s as AddressesPage};import*as d from"./pages/account/orders/index.js";export{d as OrdersPage};import*as i from"./pages/account/orders/_id_.js";export{i as OrderDetailPage};import*as n from"./pages/account/login.js";export{n as LoginPage};import*as m from"./pages/account/register.js";export{m as RegisterPage};import*as p from"./pages/account/forgot-password.js";export{p as ForgotPasswordPage};import*as l from"./pages/account/recover-password.js";export{l as RecoverPasswordPage};import*as x from"./pages/cart.js";export{x as CartPage};import*as u from"./pages/editor.js";export{u as EditorPage};import*as c from"./pages/account/favorite-products.js";export{c as FavoriteProductsPage};import*as f from"./pages/search.js";export{f as SearchPage};import*as k from"./pages/404.js";export{k as NotFoundPage};import*as I from"./pages/blog/index.js";export{I as BlogPage};import*as g from"./pages/blog/_slug_.js";export{g as BlogSlugPage};import*as j from"./pages/raffle/_slug_.js";export{j as RafflePage};import*as y from"./pages/raffle/index.js";export{y as RafflesPage};import*as P from"./pages/account/raffles.js";export{P as AccountRafflesPage};import*as T from"./pages/account/activate.js";export{T as ActivateCustomerPage};export{IkasBaseStore}from"./store/base.js";export{IkasCustomerStore}from"./store/customer/index.js";export{IkasCartStore}from"./store/cart/index.js";export{formatDate}from"./utils/helper.js";export{formatCurrency}from"./utils/currency.js";export{createTranslationInputData,useTranslation}from"./utils/i18n.js";export{IkasAdjustmentType,IkasAmountType,IkasCampaignApplicablePrice,IkasCampaignCreatedFor,IkasCampaignFilterType,IkasCampaignOfferProductShowCriteria,IkasCampaignOfferTargetPageType,IkasCampaignType,IkasCartCampaignOfferStatus,IkasCategoryProductsOrderType as IkasCategoryOrderType,IkasCheckoutRequirement,IkasCustomerAccountStatus,IkasCustomerAttributeType,IkasCustomerEmailSubscriptionStatus,IkasCustomerPriceListRuleFilterType,IkasCustomerPriceListRuleValueType,IkasCustomerRegistrationSource,IkasCustomerReviewStatus,IkasInvoiceType,IkasOrderCancelReason,IkasOrderLineItemStatus,IkasOrderPackageFullfillStatus,IkasOrderPackageStatus,IkasOrderPaymentStatus,IkasOrderShippingMethod,IkasOrderStatus,IkasPaymentGatewayAdditionalPriceType,IkasPaymentGatewaySettingsType,IkasPaymentGatewayTransactionFeeType,IkasPaymentGatewayType,IkasPaymentMethodType,IkasPaymentMethodTypeWithPrices,IkasProductAttributeType,IkasProductFilterDisplayType,IkasProductFilterSortType,IkasProductFilterType,IkasProductOptionSelectType,IkasProductOptionType,IkasProductStockFilterValue,IkasProductType,IkasRaffleMetadataTargetType,IkasRaffleVerificationType,IkasShippingMethod,IkasStockLocationDeliveryTime,IkasStockLocationType,IkasStorefrontB2BShowPricesEnum,IkasStorefrontB2BShowProductsEnum,IkasStorefrontStatus,IkasThemeJsonComponentPropType,IkasThemeJsonPageType,IkasThemeJsonStockPreference,IkasTransactionSourceWithPrices,IkasTransactionStatus,IkasTransactionStatusWithPrices,IkasTransactionType,IkasTransactionTypeWithPrices,IkasVariantSelectionType}from"@ikas/storefront-models";export{IkasTransactionWithPrices}from"./models/data/order/order-transaction-with-prices/transaction-with-prices/index.js";
|
|
@@ -17,6 +17,7 @@ export declare class IkasCheckoutSettings extends IkasBaseModel implements IChec
|
|
|
17
17
|
couponCodeRequirement: IkasCouponCodeRequirement | null;
|
|
18
18
|
showCheckoutNote: boolean | null;
|
|
19
19
|
showCompanyInfoInShippingAddress: boolean | null;
|
|
20
|
+
showBillingAddressOnShippingStep: boolean | null;
|
|
20
21
|
showTermsAndConditionsCheckbox: boolean;
|
|
21
22
|
storefrontId: string;
|
|
22
23
|
constructor(data: ICheckoutSettings);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{__extends as e}from'./../../../ext/tslib/tslib.es6.js';import{IkasCouponCodeRequirement as
|
|
1
|
+
import{__extends as e}from'./../../../ext/tslib/tslib.es6.js';import{IkasCouponCodeRequirement as n}from"@ikas/storefront-models";export{IkasCheckoutRequirement}from"@ikas/storefront-models";import{IkasBaseModel as o}from"../base/index.js";import{IkasCheckoutOption as i}from"./option/index.js";import{IkasCheckoutSettingsPrice as t}from"./price/index.js";var s=function(o){function s(e){var s,r,l=this;return(l=o.call(this,e)||this).corporateInvoiceRequirement=null,l.giftPackagePriceList=null,l.identityNumberRequirement=null,l.isGiftPackageEnabled=null,l.isShowPostalCode=null,l.isTermsAndConditionsDefaultChecked=null,l.options=null,l.postalCodeRequirement=null,l.couponCodeRequirement=null,l.showCheckoutNote=null,l.showCompanyInfoInShippingAddress=null,l.showBillingAddressOnShippingStep=null,l.corporateInvoiceRequirement=e.corporateInvoiceRequirement||null,l.giftPackagePriceList=(null===(s=e.giftPackagePriceList)||void 0===s?void 0:s.map((function(e){return new t(e)})))||null,l.identityNumberRequirement=e.identityNumberRequirement,l.isAccountRequired=e.isAccountRequired,l.isGiftPackageEnabled=e.isGiftPackageEnabled,l.isQuickRegistrationEnabled=e.isQuickRegistrationEnabled,l.isShowPostalCode=e.isShowPostalCode,l.isTermsAndConditionsDefaultChecked=e.isTermsAndConditionsDefaultChecked,l.options=(null===(r=e.options)||void 0===r?void 0:r.map((function(e){return new i(e)})))||null,l.phoneRequirement=e.phoneRequirement,l.postalCodeRequirement=e.postalCodeRequirement||null,l.couponCodeRequirement=e.couponCodeRequirement||n.DEFAULT,l.showCheckoutNote=e.showCheckoutNote||null,l.showCompanyInfoInShippingAddress=e.showCompanyInfoInShippingAddress||null,l.showBillingAddressOnShippingStep=e.showBillingAddressOnShippingStep||null,l.showTermsAndConditionsCheckbox=e.showTermsAndConditionsCheckbox,l.storefrontId=e.storefrontId,l}return e(s,o),s}(o);export{s as IkasCheckoutSettings};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { IkasOrderGiftCardLine as IOrderGiftCardLine } from "@ikas/storefront-models";
|
|
2
|
+
export declare class IkasOrderGiftCardLine implements IOrderGiftCardLine {
|
|
3
|
+
amount: number;
|
|
4
|
+
code: string;
|
|
5
|
+
giftCardId: string;
|
|
6
|
+
id: string;
|
|
7
|
+
constructor(data: IOrderGiftCardLine);
|
|
8
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{makeAutoObservable as t}from"mobx";var i=function(i){this.amount=i.amount||0,this.code=i.code||"",this.giftCardId=i.giftCardId||"",this.id=i.id||"",t(this)};export{i as IkasOrderGiftCardLine};
|
|
@@ -12,6 +12,7 @@ import { IkasOrderTaxLine } from "./tax-line";
|
|
|
12
12
|
import { IkasBaseModel } from "../base";
|
|
13
13
|
import { IkasOrderCancelReason, IkasOrderPackageStatus, IkasOrderPaymentStatus, IkasOrderShippingMethod, IkasOrderStatus } from "@ikas/storefront-models";
|
|
14
14
|
import { IkasOrder as IOrder } from "@ikas/storefront-models";
|
|
15
|
+
import { IkasOrderGiftCardLine } from "./gift-card-line";
|
|
15
16
|
declare type IOrderConstructorData = {
|
|
16
17
|
refundSettings?: IkasOrderRefundSettings | null;
|
|
17
18
|
} & IOrder;
|
|
@@ -23,6 +24,7 @@ export declare class IkasOrder extends IkasBaseModel implements IOrder {
|
|
|
23
24
|
currencySymbol: string | null;
|
|
24
25
|
customer: IkasOrderCustomer | null;
|
|
25
26
|
customerId: string | null;
|
|
27
|
+
giftCardLines: IkasOrderGiftCardLine[] | null;
|
|
26
28
|
giftPackageLines: IkasOrderGiftPackageLine[] | null;
|
|
27
29
|
giftPackageNote: string | null;
|
|
28
30
|
invoices: IkasInvoice[] | null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{__extends as e}from'./../../../ext/tslib/tslib.es6.js';import{IkasOrderAddress as t}from"./address/index.js";import{IkasOrderShippingLine as n}from"./shipping-line/index.js";import{IkasOrderLineItem as r}from"./line-item/index.js";import{IkasOrderCustomer as o}from"./customer/index.js";import{IkasOrderGiftPackageLine as i}from"./gift-line/index.js";import{IkasInvoice as u}from"./invoice/index.js";import{IkasOrderPaymentMethod as l}from"./payment-method/index.js";import{IkasOrderAdjustment as s}from"./adjustment/index.js";import{IkasOrderPackage as a}from"./package/index.js";import{IkasOrderTaxLine as d}from"./tax-line/index.js";import{IkasBaseModel as c}from"../base/index.js";import{IkasCampaignType as m,IkasOrderShippingMethod as p,IkasOrderStatus as f}from"@ikas/storefront-models";export{IkasOrderCancelReason,IkasOrderPackageStatus,IkasOrderPaymentStatus,IkasOrderShippingMethod,IkasOrderStatus}from"@ikas/storefront-models";import{makeObservable as g,observable as b,computed as y}from"mobx";import{IkasOrderFunctions as h}from"@ikas/storefront-model-functions";import{formatCurrency as P}from"../../../utils/currency.js";var
|
|
1
|
+
import{__extends as e}from'./../../../ext/tslib/tslib.es6.js';import{IkasOrderAddress as t}from"./address/index.js";import{IkasOrderShippingLine as n}from"./shipping-line/index.js";import{IkasOrderLineItem as r}from"./line-item/index.js";import{IkasOrderCustomer as o}from"./customer/index.js";import{IkasOrderGiftPackageLine as i}from"./gift-line/index.js";import{IkasInvoice as u}from"./invoice/index.js";import{IkasOrderPaymentMethod as l}from"./payment-method/index.js";import{IkasOrderAdjustment as s}from"./adjustment/index.js";import{IkasOrderPackage as a}from"./package/index.js";import{IkasOrderTaxLine as d}from"./tax-line/index.js";import{IkasBaseModel as c}from"../base/index.js";import{IkasCampaignType as m,IkasOrderShippingMethod as p,IkasOrderStatus as f}from"@ikas/storefront-models";export{IkasOrderCancelReason,IkasOrderPackageStatus,IkasOrderPaymentStatus,IkasOrderShippingMethod,IkasOrderStatus}from"@ikas/storefront-models";import{makeObservable as g,observable as b,computed as y}from"mobx";import{IkasOrderFunctions as h}from"@ikas/storefront-model-functions";import{formatCurrency as P}from"../../../utils/currency.js";import{IkasOrderGiftCardLine as j}from"./gift-card-line/index.js";var v=function(c){function v(e,m){var h,P,v,A,k,I,S,O,x,C,L,T=this;(T=c.call(this,e)||this).billingAddress=null,T.cancelReason=null,T.cancelledAt=null,T.currencySymbol=null,T.customer=null,T.customerId=null,T.giftPackageLines=null,T.giftPackageNote=null,T.invoices=null,T.isGiftPackage=null,T.note=null,T.orderAdjustments=null,T.orderNumber=null,T.orderPackageStatus=null,T.orderPackages=null,T.orderPaymentStatus=null,T.orderedAt=null,T.priceListId=null,T.paymentMethods=null,T.shippingAddress=null,T.shippingLines=null,T.taxLines=null,T.billingAddress=e.billingAddress?new t(e.billingAddress):null,T.cancelReason=e.cancelReason||null,T.cancelledAt=e.cancelledAt||null,T.currencyCode=e.currencyCode||"",T.currencySymbol=e.currencySymbol||null,T.customer=e.customer?new o(e.customer):null,T.customerId=e.customerId||null,T.giftCardLines=(null===(h=e.giftCardLines)||void 0===h?void 0:h.map((function(e){return new j(e)})))||null,T.giftPackageLines=(null===(P=e.giftPackageLines)||void 0===P?void 0:P.map((function(e){return new i(e)})))||null,T.giftPackageNote=e.giftPackageNote||null,T.invoices=(null===(v=e.invoices)||void 0===v?void 0:v.map((function(e){return new u(e)})))||null,T.isGiftPackage=e.isGiftPackage||null,T.note=e.note||null,T.orderAdjustments=(null===(A=e.orderAdjustments)||void 0===A?void 0:A.map((function(e){return new s(e)})))||null,T.orderLineItems=(null===(k=e.orderLineItems)||void 0===k?void 0:k.map((function(e){return new r(e)})).filter((function(e){return!e.deleted})))||[],T.orderNumber=e.orderNumber||null,T.orderPackageStatus=e.orderPackageStatus||null,T.orderPackages=(null===(I=e.orderPackages)||void 0===I?void 0:I.map((function(e){return new a(e)})))||null,T.orderPaymentStatus=e.orderPaymentStatus||null,T.orderedAt=e.orderedAt||null,T.priceListId=e.priceListId||null,T.paymentMethods=(null===(S=e.paymentMethods)||void 0===S?void 0:S.map((function(e){return new l(e)})))||null,T.shippingAddress=e.shippingAddress?new t(e.shippingAddress):null,T.shippingLines=(null===(O=e.shippingLines)||void 0===O?void 0:O.map((function(e){return new n(e)})))||null,T.shippingMethod=e.shippingMethod||p.SHIPMENT,T.status=e.status||f.CREATED,T.taxLines=(null===(x=e.taxLines)||void 0===x?void 0:x.map((function(e){return new d(e)})))||null,T.totalFinalPrice=null!==(C=e.totalFinalPrice)&&void 0!==C?C:0,T.totalPrice=null!==(L=e.totalPrice)&&void 0!==L?L:0,T.refundSettings=e.refundSettings;var F={billingAddress:b,cancelReason:b,cancelledAt:b,currencyCode:b,currencySymbol:b,customer:b,customerId:b,giftCardLines:b,giftPackageLines:b,giftPackageNote:b,invoices:b,isGiftPackage:b,note:b,orderAdjustments:b,orderLineItems:b,orderNumber:b,orderPackageStatus:b,orderPackages:b,orderPaymentStatus:b,orderedAt:b,paymentMethods:b,shippingAddress:b,shippingLines:b,shippingMethod:b,status:b,taxLines:b,totalFinalPrice:b,totalPrice:b,refundSettings:b,items:y,itemCount:y,refundableItems:y,unfullfilledItems:y,refundedItems:y,totalTax:y,formattedTotalTax:y,shippingTotal:y,formattedShippingTotal:y,formattedTotalFinalPrice:y,formattedTotalPrice:y,hasCustomer:y,hasValidCustomerEmail:y,customerFullName:y,formattedDate:y,couponAdjustment:y,nonCouponAdjustments:y,orderProductFileIds:y};return m&&(delete F.billingAddress,delete F.shippingAddress),g(T,F),T}return e(v,c),Object.defineProperty(v.prototype,"items",{get:function(){return this.orderLineItems},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"itemCount",{get:function(){var e;return(null===(e=this.items)||void 0===e?void 0:e.length)||0},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"itemQuantity",{get:function(){return this.items.reduce((function(e,t){return e+t.quantity}),0)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"refundableItems",{get:function(){return this.refundSettings?h.getRefundableItems(this,this.refundSettings):[]},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"displayedPackages",{get:function(){return h.getDisplayedPackages(this).map((function(e){return new a(e)}))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"unfullfilledItems",{get:function(){return h.getUnfullfilledItems(this)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"refundedItems",{get:function(){return h.getRefundedItems(this)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"totalTax",{get:function(){return h.getTotalTax(this)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"formattedTotalTax",{get:function(){return P(this.totalTax,this.currencyCode,this.currencySymbol||"")},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"shippingTotal",{get:function(){return h.getShippingTotal(this)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"formattedShippingTotal",{get:function(){return P(this.shippingTotal,this.currencyCode,this.currencySymbol||"")},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"formattedTotalFinalPrice",{get:function(){return P(this.totalFinalPrice,this.currencyCode,this.currencySymbol||"")},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"formattedTotalPrice",{get:function(){return P(this.totalPrice,this.currencyCode,this.currencySymbol||"")},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"hasCustomer",{get:function(){return h.hasCustomer(this)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"hasValidCustomerEmail",{get:function(){return h.hasValidCustomerEmail(this)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"customerFullName",{get:function(){return h.getCustomerFullName(this)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"formattedDate",{get:function(){return h.getFormattedDate(this)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"couponAdjustment",{get:function(){return h.getCouponAdjustment(this)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"nonCouponAdjustments",{get:function(){return h.getNonCouponAdjustments(this)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"isRefundEnabled",{get:function(){return this.refundableItems.some((function(e){return null!==e.refundQuantity}))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"displayedOrderAdjustments",{get:function(){var e;return null===(e=this.orderAdjustments)||void 0===e?void 0:e.filter((function(e){return e.campaignType!==m.FREE_SHIPPING}))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"orderProductFileIds",{get:function(){return h.getOrderProductFiles(this)},enumerable:!1,configurable:!0}),v}(c);export{v as IkasOrder};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { IkasOrderLineBundleProductSettings as IOrderLineBundleProductSettings } from "@ikas/storefront-models";
|
|
2
|
+
export declare class IkasOrderLineBundleProductSettings implements IOrderLineBundleProductSettings {
|
|
3
|
+
bundleLineId: string;
|
|
4
|
+
bundleLineQuantity: number;
|
|
5
|
+
name: string | null;
|
|
6
|
+
constructor(data: IOrderLineBundleProductSettings);
|
|
7
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{makeAutoObservable as n}from"mobx";var i=function(i){this.bundleLineId=i.bundleLineId||"",this.bundleLineQuantity=i.bundleLineQuantity||0,this.name=i.name||null,n(this)};export{i as IkasOrderLineBundleProductSettings};
|
|
@@ -2,11 +2,13 @@ import { IkasOrderLineItem as IOrderLineItem, IkasOrderLineItemStatus } from "@i
|
|
|
2
2
|
import { IkasOrderLineDiscount } from "./discount";
|
|
3
3
|
import { IkasOrderLineVariant } from "./variant";
|
|
4
4
|
import { IkasOrderLineItemOption } from "./option";
|
|
5
|
+
import { IkasOrderLineBundleProductSettings } from "./bundle-product-settings";
|
|
5
6
|
import { IkasBaseModel } from "../../base";
|
|
6
7
|
declare type IOrderLineItemConstructorParams = {
|
|
7
8
|
refundQuantity?: number;
|
|
8
9
|
} & IOrderLineItem;
|
|
9
10
|
export declare class IkasOrderLineItem extends IkasBaseModel implements IOrderLineItem {
|
|
11
|
+
bundleProductSettings: IkasOrderLineBundleProductSettings | null;
|
|
10
12
|
currencyCode: string | null;
|
|
11
13
|
currencySymbol: string | null;
|
|
12
14
|
discount: IkasOrderLineDiscount | null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{__extends as t}from'./../../../../ext/tslib/tslib.es6.js';export{IkasOrderLineItemStatus}from"@ikas/storefront-models";import{IkasOrderLineDiscount as e}from"./discount/index.js";import{IkasOrderLineVariant as i}from"./variant/index.js";import{IkasOrderLineItemOption as
|
|
1
|
+
import{__extends as t}from'./../../../../ext/tslib/tslib.es6.js';export{IkasOrderLineItemStatus}from"@ikas/storefront-models";import{IkasOrderLineDiscount as e}from"./discount/index.js";import{IkasOrderLineVariant as i}from"./variant/index.js";import{IkasOrderLineItemOption as n}from"./option/index.js";import{IkasOrderLineBundleProductSettings as r}from"./bundle-product-settings/index.js";import{IkasBaseModel as o}from"../../base/index.js";import{makeObservable as u,observable as c,computed as a,action as l}from"mobx";import{IkasOrderLineItemFunctions as d}from"@ikas/storefront-model-functions";import{formatCurrency as s}from"../../../../utils/currency.js";import{IkasBaseStore as f}from"../../../../store/base.js";import"../../../../store/customer/index.js";import"../../../../store/cart/index.js";var y=function(o){function y(t){var d,s,f,y,m,p=this;return(p=o.call(this,t)||this).bundleProductSettings=null,p.currencyCode=null,p.discount=null,p.discountPrice=null,p.finalPrice=null,p.options=null,p.originalOrderLineItemId=null,p.statusUpdatedAt=null,p.stockLocationId=null,p.taxValue=null,p._refundQuantity=null,p.bundleProductSettings=t.bundleProductSettings?new r(t.bundleProductSettings):null,p.currencyCode=t.currencyCode||null,p.currencySymbol=t.currencySymbol||null,p.discount=t.discount?new e(t.discount):null,p.discountPrice=null!==(d=t.discountPrice)&&void 0!==d?d:null,p.finalPrice=null!==(s=t.finalPrice)&&void 0!==s?s:null,p.finalUnitPrice=null!==(f=t.finalUnitPrice)&&void 0!==f?f:null,p.options=(null===(y=t.options)||void 0===y?void 0:y.map((function(t){return new n(t)})))||null,p.originalOrderLineItemId=t.originalOrderLineItemId||null,p.price=t.price,p.quantity=t.quantity,p.status=t.status,p.statusUpdatedAt=t.statusUpdatedAt,p.stockLocationId=t.stockLocationId,p.taxValue=t.taxValue,p.unitPrice=null!==(m=t.unitPrice)&&void 0!==m?m:null,p.variant=new i(t.variant),p.orderedAt=t.orderedAt,p.refundQuantity=t.refundQuantity,u(p,{bundleProductSettings:c,currencyCode:c,currencySymbol:c,discount:c,discountPrice:c,finalPrice:c,finalUnitPrice:c,options:c,originalOrderLineItemId:c,price:c,quantity:c,status:c,statusUpdatedAt:c,stockLocationId:c,taxValue:c,unitPrice:c,variant:c,orderedAt:c,_refundQuantity:c,priceWithQuantity:a,formattedPriceWithQuantity:a,overridenPriceWithQuantity:a,formattedOverridenPriceWithQuantity:a,formattedFinalPrice:a,formattedUnitPrice:a,formattedFinalUnitPrice:a,formattedDiscountPrice:a,finalPriceWithQuantity:a,formattedFinalPriceWithQuantity:a,tax:a,formattedTax:a,refundQuantity:a,editLineItem:l.bound}),p}return t(y,o),Object.defineProperty(y.prototype,"priceWithQuantity",{get:function(){return d.getPriceWithQuantity(this)},enumerable:!1,configurable:!0}),Object.defineProperty(y.prototype,"formattedPriceWithQuantity",{get:function(){return s(this.priceWithQuantity,this.currencyCode||"",this.currencySymbol||"")},enumerable:!1,configurable:!0}),Object.defineProperty(y.prototype,"overridenPriceWithQuantity",{get:function(){return d.getOverridenPriceWithQuantity(this)},enumerable:!1,configurable:!0}),Object.defineProperty(y.prototype,"formattedOverridenPriceWithQuantity",{get:function(){return s(this.overridenPriceWithQuantity||0,this.currencyCode||"",this.currencySymbol||"")},enumerable:!1,configurable:!0}),Object.defineProperty(y.prototype,"formattedFinalPrice",{get:function(){return s(this.finalPrice||0,this.currencyCode||"",this.currencySymbol||"")},enumerable:!1,configurable:!0}),Object.defineProperty(y.prototype,"formattedUnitPrice",{get:function(){return s(this.unitPrice||0,this.currencyCode||"",this.currencySymbol||"")},enumerable:!1,configurable:!0}),Object.defineProperty(y.prototype,"formattedFinalUnitPrice",{get:function(){return s(this.finalUnitPrice||0,this.currencyCode||"",this.currencySymbol||"")},enumerable:!1,configurable:!0}),Object.defineProperty(y.prototype,"unitPriceText",{get:function(){var t,e,i,n;if(null!==this.finalUnitPrice){var r=null===(t=this.variant.baseUnit)||void 0===t?void 0:t.baseAmount,o=(null===(i=null===(e=this.variant.baseUnit)||void 0===e?void 0:e.unit)||void 0===i?void 0:i.name)||(null===(n=this.variant.baseUnit)||void 0===n?void 0:n.type);return"".concat(s(this.finalUnitPrice,this.currencyCode||"",this.currencySymbol||"")," / ").concat(r&&1!==r?r:"").concat(o)}},enumerable:!1,configurable:!0}),Object.defineProperty(y.prototype,"formattedDiscountPrice",{get:function(){return s(this.discountPrice||0,this.currencyCode||"",this.currencySymbol||"")},enumerable:!1,configurable:!0}),Object.defineProperty(y.prototype,"finalPriceWithQuantity",{get:function(){return d.getFinalPriceWithQuantity(this)},enumerable:!1,configurable:!0}),Object.defineProperty(y.prototype,"formattedFinalPriceWithQuantity",{get:function(){return s(this.finalPriceWithQuantity||0,this.currencyCode||"",this.currencySymbol||"")},enumerable:!1,configurable:!0}),Object.defineProperty(y.prototype,"tax",{get:function(){return d.getTax(this)},enumerable:!1,configurable:!0}),Object.defineProperty(y.prototype,"formattedTax",{get:function(){return s(this.tax,this.currencyCode||"",this.currencySymbol||"")},enumerable:!1,configurable:!0}),Object.defineProperty(y.prototype,"hasDiscount",{get:function(){return d.hasDiscount(this)},enumerable:!1,configurable:!0}),Object.defineProperty(y.prototype,"refundQuantity",{get:function(){return this._refundQuantity},set:function(t){t?(t>this.quantity&&(t=this.quantity),t<=0&&(t=null),this._refundQuantity=t):this._refundQuantity=null},enumerable:!1,configurable:!0}),y.prototype.editLineItem=function(){var t,e=this.variant.href||"";e=e.includes("?")?e+"&editLineID="+this.id:e+"?editLineID="+this.id,null===(t=f.getInstance().router)||void 0===t||t.push(e)},y}(o);export{y as IkasOrderLineItem};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{__spreadArray as t,__assign as e,__awaiter as i,__generator as n}from'./../../../ext/tslib/tslib.es6.js';import r from"lodash/sortBy";import a from"lodash/cloneDeep";import{IkasCategory as o}from"../category/index.js";import{IkasProductVariant as s}from"./variant/index.js";import{IkasProductAttributeValue as u}from"./attribute-value/index.js";import{IkasProductVariantType as c}from"./variant-type/index.js";import{IkasBrand as d}from"../brand/index.js";import{IkasHTMLMetaData as l}from"../html-meta-data/index.js";import{IkasProductTag as p}from"./tag/index.js";import{IkasProductOptionPriceTypeEnum as f,IkasProductType as v}from"@ikas/storefront-models";export{IkasProductType}from"@ikas/storefront-models";import{IkasProductOptionSet as h}from"./option-set/index.js";import{makeObservable as m,observable as g,computed as V}from"mobx";import{IkasProductFunctions as b}from"@ikas/storefront-model-functions";import{IkasProductCampaign as y}from"./campaign/index.js";import{IkasStorefrontConfig as P}from"@ikas/storefront-config";import{IkasBaseStore as I}from"../../../store/base.js";import O from"lodash/groupBy";import{IkasProductBaseUnit as w}from"./base-unit/index.js";import{formatCurrency as S}from"../../../utils/currency.js";import"lodash/get";import T from"../../../store/product/index.js";import{IkasCustomerReviewList as j}from"../../ui/customer-review-list/index.js";import{IkasProductStar as C}from"./star/index.js";import{IkasProductCampaignOffer as x,IkasProductOffer as R}from"./campaign-offer/index.js";import{IkasProductGroup as G}from"./group/index.js";import{IkasImage as E}from"../image/index.js";import{IkasProductSalesChannel as A}from"./sales-channel/index.js";var k=function(){function k(b){void 0===b&&(b={});var O,E,L,D=this;this.metaData=null,this.brand=null,this.tags=null,this.productOptionSetId=null,this.productOptionSet=null,this.campaigns=null,this.selectedVariantValues=[],this.isFiltered=!1,this.isStatic=!1,this.bundleProductCache={},this.productGroupItems=[],this.showVariantsInGroup=!1,this.selectVariantValue=function(i,n){var r,a=D.metaData,o=D.selectedVariantValues.map((function(t){return t.variantTypeId===i.variantTypeId?i:t})),s=D.variants.find((function(t){return t.isActive&&o.every((function(e){return t.variantValues.some((function(t){return t.id===e.id}))}))}));if(s)D.selectedVariantValues=o;else{var u=D.variantTypes.findIndex((function(t){return t.variantType.id===i.variantTypeId}));if(u>0){var c=D.variantTypes.slice(0,u),d=D.selectedVariantValues.filter((function(t){return c.some((function(e){return e.variantType.id===t.variantTypeId}))})),l=t(t([],d,!0),[i],!1);s=D.variants.find((function(t){return t.isActive&&l.every((function(e){return t.variantValues.some((function(t){return t.id===e.id}))}))}))}else{var p=o.slice(0,o.length-1);(s=D.variants.find((function(t){return t.isActive&&p.every((function(e){return t.variantValues.some((function(t){return t.id===e.id}))}))})))||(s=D.variants.find((function(t){return t.isActive&&t.variantValues.some((function(t){return t.id===i.id}))})))}if(!s)return;D.selectedVariantValues=s.variantValues}var f={};new URLSearchParams(window.location.search).forEach((function(t,i){var n;"vid"!==i&&(f=e(e({},f),((n={})[i]=t,n)))})),D.variantTypes.map((function(t){delete f[t.variantType.slug]}));var v=t(t([],D.variantTypes.map((function(t){var e=t.variantType,i=e.values.find((function(t){return D.selectedVariantValues.some((function(e){return e.id===t.id}))}));if(i)return"".concat(e.slug,"=").concat(i.slug)})),!0),Object.entries(f).map((function(t){var e=t[0],i=t[1];return"".concat(e,"=").concat(i)})),!0).filter((function(t){return!!t})).join("&");if(D.setOptionRealPrices(),!n){var h="/".concat(a.slug);if(v&&(h="/".concat(a.slug,"?").concat(v)),h===window.location.pathname)return;null===(r=I.getInstance().router)||void 0===r||r.replace(h,void 0,{shallow:!1,scroll:!1})}},this.getVariantUnitPriceText=function(t){var e,i,n=t.price;if(n.unitPrice&&D.baseUnit){var r=D.baseUnit.baseAmount,a=(null===(i=null===(e=D.baseUnit)||void 0===e?void 0:e.unit)||void 0===i?void 0:i.name)||"";return"".concat(S(n.unitPrice,n.currency||"",n.currencySymbol||"")," / ").concat(r&&1!==r?r:"").concat(a)}},this.getCampaigns=function(){return i(D,void 0,void 0,(function(){var t,e,i,r,a,o=this;return n(this,(function(n){switch(n.label){case 0:return t=I.getInstance(),e=t.customerStore.customer,i=e?e.customerGroupIds:null,r=this.variants.map((function(t){return t.id})),[4,T.getProductCampaigns({input:{customerGroupIds:i,salesChannelId:P.getSalesChannelId()||"",variantIds:r}})];case 1:return a=n.sent(),this.campaigns=a.data,this.campaigns?(this.campaigns.map((function(t){o.variants.map((function(e){var i;t.variantIds.some((function(t){return t===e.id}))&&(null===(i=e.campaigns)||void 0===i||i.push(t))}))})),[2,this.campaigns]):[2]}}))}))},this.getAvailableStockLocations=function(){return i(D,void 0,void 0,(function(){var t,e;return n(this,(function(i){switch(i.label){case 0:return t=this.variants.map((function(t){return t.id})),e=P.getPickupStockLocationIds(),[4,T.getVariantStockLocations({stockLocationIdList:e,variantIds:t})];case 1:return[2,i.sent().data||[]]}}))}))},this.getCustomerReviews=function(t){return i(D,void 0,void 0,(function(){var i,r,a,o,s;return n(this,(function(n){switch(n.label){case 0:return i=!!(null===(o=this.selectedVariant.bundleSettings)||void 0===o?void 0:o.products.length),r=[this.id],i&&(null===(s=this.selectedVariant.bundleSettings)||void 0===s||s.products.forEach((function(t){r.push(t.productId)}))),[4,(a=new j(e(e(e({},i?{}:{productId:this.id}),{limit:null==t?void 0:t.limit,page:null==t?void 0:t.page,hasImage:null==t?void 0:t.hasImage}),i?{productIds:r}:{}))).getInitial()];case 1:return n.sent(),[2,a]}}))}))},this.getProductOptionSet=function(){return i(D,void 0,void 0,(function(){var t,e;return n(this,(function(i){switch(i.label){case 0:return this.productOptionSet?[2,!0]:this.productOptionSetId?[4,T.listProductOptionSet({id:{eq:this.productOptionSetId}})]:[2,!1];case 1:return(t=i.sent()).isSuccess&&(null===(e=t.data)||void 0===e?void 0:e.length)?(this.productOptionSet=t.data[0],this.setOptionPrices(),this.setOptionRealPrices(),[2,!0]):[2,!1]}}))}))},this.initBundleProducts=function(){return i(D,void 0,void 0,(function(){var t,e,i,r,a,o;return n(this,(function(n){switch(n.label){case 0:return t="","undefined"!=typeof window&&(e=new URLSearchParams(window.location.search),t=e.get("editLineID")||""),t?(i=null===(a=I.getInstance().cartStore.cart)||void 0===a?void 0:a.items.find((function(e){return e.id===t})))&&(r=this.variants.find((function(t){return t.id===i.variant.id})))?(this.selectedVariantValues=r.variantValues,[4,this.getBundleProductsOfVariant(r)]):[3,2]:[3,3];case 1:n.sent(),null===(o=r.bundleSettings)||void 0===o||o.products.forEach((function(t){var e,n,r;try{var a=null===(e=i.variant.bundleProducts)||void 0===e?void 0:e.find((function(e){return e.id===t.id})),o=t.product.variants.find((function(t){return t.id===(null==a?void 0:a.variant.id)}));t.product.selectedVariantValues=o.variantValues,t.quantity=(null===(r=null===(n=i.variant.bundleProducts)||void 0===n?void 0:n.find((function(t){return t.variant.id===o.id})))||void 0===r?void 0:r.quantity)||0}catch(t){console.error(t)}})),n.label=2;case 2:return[3,5];case 3:return[4,this.getBundleProductsOfVariant(this.selectedVariant)];case 4:n.sent(),n.label=5;case 5:return[2]}}))}))},this.setShowVariantsInGroup=function(t){D.showVariantsInGroup=t},this.getBundleProductsOfVariant=function(t){return i(D,void 0,void 0,(function(){var e,i,r,o,s,u,c=this;return n(this,(function(n){switch(n.label){case 0:return(null==(e=null===(r=t.bundleSettings)||void 0===r?void 0:r.products.map((function(t){return t.productId})).filter((function(t){return-1===Object.keys(c.bundleProductCache).indexOf(t)})))?void 0:e.length)?[4,T.searchProducts({input:{productIdList:e,perPage:200,priceListId:P.getPriceListId(),salesChannelId:P.getSalesChannelId()}})]:[3,2];case 1:(i=n.sent()).isSuccess&&(null===(s=null===(o=i.data)||void 0===o?void 0:o.data)||void 0===s||s.forEach((function(t){c.bundleProductCache[t.id]=t}))),n.label=2;case 2:return null===(u=t.bundleSettings)||void 0===u||u.products.forEach((function(t){var e=c.bundleProductCache[t.productId];t.setProduct(new k(a(e)))})),[2]}}))}))},this.setOptionRealPrices=function(){var t,e=D.selectedVariant||D.variants[0];if(e){var i=e.price.currency;i&&(null===(t=D.productOptionSet)||void 0===t||t.options.forEach((function(t){var e;if(t.selectSettings)t.selectSettings.values.forEach((function(t){var e;if(t.priceType===f.RATIO&&t.initPrice)if(t.otherPrices){var n=(null===(e=t.otherPrices.find((function(t){return t.currencyCode===i})))||void 0===e?void 0:e.price)||t.initPrice||1;t.price=D.selectedVariant.price.finalPrice*n/100}else t.price=D.selectedVariant.price.finalPrice*t.initPrice/100}));else if(t.priceType===f.RATIO&&t.initPrice)if(t.otherPrices){var n=(null===(e=t.otherPrices.find((function(t){return t.currencyCode===i})))||void 0===e?void 0:e.price)||t.initPrice||1;t.price=D.selectedVariant.price.finalPrice*n/100}else t.price=D.selectedVariant.price.finalPrice*t.initPrice/100})))}},this.setOptionPrices=function(){var t,e=D.variants[0];if(e){var i=e.price.currency;null===(t=D.productOptionSet)||void 0===t||t.options.forEach((function(t){var n,r;if(t.selectSettings&&t.selectSettings.values.forEach((function(t){var n,r;if(t.otherPrices)if(t.priceType===f.RATIO){var a=(null===(n=t.otherPrices.find((function(t){return t.currencyCode===i})))||void 0===n?void 0:n.price)||t.price||1;t.price=e.price.finalPrice*a}else t.price=(null===(r=t.otherPrices.find((function(t){return t.currencyCode===i})))||void 0===r?void 0:r.price)||t.price})),t.otherPrices)if(t.priceType===f.RATIO){var a=(null===(n=t.otherPrices.find((function(t){return t.currencyCode===i})))||void 0===n?void 0:n.price)||t.price||1;t.price=e.price.finalPrice*a}else t.price=(null===(r=t.otherPrices.find((function(t){return t.currencyCode===i})))||void 0===r?void 0:r.price)||t.price}))}},this.id=b.id||Date.now()+"",this.name=b.name||"",this.type=b.type||v.PHYSICAL,this.description=b.description||"",this.shortDescription=b.shortDescription||"",this.metaData=b.metaData?new l(b.metaData):null,this.brand=b.brand?new d(b.brand):null,this.categories=b.categories?b.categories.map((function(t){return new o(t)})):[],this.deleted=b.deleted||null,this.tags=b.tags?b.tags.map((function(t){return new p(t)})):[],this.variants=b.variants?b.variants.map((function(t){return new s(t)})):[],this.attributes=b.attributes?b.attributes.map((function(t){return new u(t)})):[],this.variantTypes=b.variantTypes?b.variantTypes.map((function(t){return new c(t)})):[],this.productOptionSetId=b.productOptionSetId||null,this.averageRating=null!==(O=b.averageRating)&&void 0!==O?O:null,this.reviewCount=null!==(E=b.reviewCount)&&void 0!==E?E:null,this.stars=b.stars?b.stars.map((function(t){return new C(t)})):null,this.baseUnit=b.baseUnit?new w(b.baseUnit):null,this.campaigns=(null===(L=b.campaigns)||void 0===L?void 0:L.map((function(t){return new y(t)})))||null,this.selectedVariantValues=b.selectedVariantValues||[],this.productOptionSet=b.productOptionSet?new h(b.productOptionSet):null,this.variantTypes=r(this.variantTypes,"order"),this.groupVariantsByVariantTypeId=b.groupVariantsByVariantTypeId||null,this.dynamicPriceListIds=b.dynamicPriceListIds||null,this.productVolumeDiscountId=b.productVolumeDiscountId||null,this.campaignOffers=b.campaignOffers?b.campaignOffers.map((function(t){return new x(t)})):null,this.appliedCampaignOffer=b.appliedCampaignOffer,this.offers=b.offers?b.offers.map((function(t){return new R(t)})):void 0,this.productGroup=b.productGroup?new G(b.productGroup):null,this.salesChannels=b.salesChannels?b.salesChannels.map((function(t){return new A(t)})):null,this.productGroupItems=b.productGroupItems,this.variants.forEach((function(t){return t.product=D})),this.setOptionPrices(),this.setOptionRealPrices(),this.customerReviews=b.customerReviews?new j(b.customerReviews):null,m(this,{selectedVariantValues:g,isFiltered:g,isStatic:g,showVariantsInGroup:g,hasVariant:V,hasStock:V,hasValidProductOptionValues:V,href:V,productHref:V,mainVariantType:V,mainVariantValue:V,selectedVariant:V,displayedVariantTypes:V,isCustomerReviewEnabled:V,isCustomerReviewLoginRequired:V,isAddToCartEnabled:V,groupedAttributeValues:V,selectedVariantUnitPriceText:V,displayedProductGroups:V})}return Object.defineProperty(k.prototype,"hasVariant",{get:function(){return b.hasVariant(this,this.showVariantsInGroup)},enumerable:!1,configurable:!0}),Object.defineProperty(k.prototype,"hasStock",{get:function(){return this.isStatic?this.selectedVariant.hasStock:b.hasStock(this)},enumerable:!1,configurable:!0}),Object.defineProperty(k.prototype,"hasValidProductOptionValues",{get:function(){return!this.productOptionSet||this.productOptionSet.hasValidValues},enumerable:!1,configurable:!0}),Object.defineProperty(k.prototype,"href",{get:function(){return b.getSelectedVariantHref(this,this.selectedVariantValues)},enumerable:!1,configurable:!0}),Object.defineProperty(k.prototype,"productHref",{get:function(){return this.groupVariantsByVariantTypeId||this.isFiltered?this.href:b.getProductHref(this)},enumerable:!1,configurable:!0}),Object.defineProperty(k.prototype,"mainVariantType",{get:function(){return b.getMainVariantType(this)},enumerable:!1,configurable:!0}),Object.defineProperty(k.prototype,"mainVariantValue",{get:function(){return b.getMainVariantValue(this.selectedVariantValues)},enumerable:!1,configurable:!0}),Object.defineProperty(k.prototype,"selectedVariant",{get:function(){if(!this.hasVariant)return this.variants[0];var t=this.selectedVariantValues.map((function(t){return t.id}));return this.variants.find((function(e){return e.variantValues.every((function(e){return t.includes(e.id)}))}))},enumerable:!1,configurable:!0}),Object.defineProperty(k.prototype,"displayedVariantTypes",{get:function(){return this.hasVariant?b.getDisplayedVariantTypes(this,this.selectedVariantValues):[]},enumerable:!1,configurable:!0}),Object.defineProperty(k.prototype,"isCustomerReviewEnabled",{get:function(){return P.isCustomerReviewEnabled()},enumerable:!1,configurable:!0}),Object.defineProperty(k.prototype,"isCustomerReviewLoginRequired",{get:function(){return P.isCustomerReviewLoginRequired()},enumerable:!1,configurable:!0}),Object.defineProperty(k.prototype,"isAddToCartEnabled",{get:function(){var t,e=!0;return null===(t=this.selectedVariant.bundleSettings)||void 0===t||t.products.forEach((function(t){0===t.quantity&&null!==t.minQuantity&&0!==t.minQuantity&&(e=!1)})),e&&this.hasValidProductOptionValues&&(this.selectedVariant.hasStock||this.selectedVariant.sellIfOutOfStock)},enumerable:!1,configurable:!0}),Object.defineProperty(k.prototype,"groupedAttributeValues",{get:function(){var t,e=O(this.attributes,"productAttributeId");return(null===(t=this.attributes)||void 0===t?void 0:t.map((function(t){var i=t.productAttributeId;if(i){var n=e[i];return(null==n?void 0:n.length)&&n[0].productAttribute?{attribute:n[0].productAttribute,values:n}:void 0}})).filter((function(t){return!!t})))||[]},enumerable:!1,configurable:!0}),Object.defineProperty(k.prototype,"selectedVariantUnitPriceText",{get:function(){return this.getVariantUnitPriceText(this.selectedVariant)},enumerable:!1,configurable:!0}),Object.defineProperty(k.prototype,"displayedProductGroups",{get:function(){var e,i=this,n=[],a=[];return null===(e=this.productGroupItems)||void 0===e||e.forEach((function(t){t.groupValues.forEach((function(t){n.includes(t.name)||n.push(t.name)}))})),n.forEach((function(e){var n,o={name:e,items:[]};i.productGroupItems=r(i.productGroupItems,(function(t){var e;return parseInt((null===(e=t.order)||void 0===e?void 0:e.value)||"999",10)})),null===(n=i.productGroupItems)||void 0===n||n.forEach((function(n){var r,a,s,u=n.groupValues.find((function(t){return t.name===e}));if(u&&!o.items.some((function(t){return t.value===u.value}))){var c="";if(n.productId===i.id)c=i.href;else{var d=(null===(r=i.productGroup)||void 0===r?void 0:r.values.filter((function(t){return t.name!==e})))||[],l=t(t([],d,!0),[u],!1),p=null===(a=i.productGroupItems)||void 0===a?void 0:a.find((function(t){return l.every((function(e){return t.groupValues.some((function(t){return e.name===t.name&&e.value===t.value}))}))}));c=p?p.href:n.href}o.items.push({image:n.image?new E(n.image):null,href:c,value:u.value,isSelected:(null===(s=i.productGroupItems)||void 0===s?void 0:s.some((function(t){return t.groupValues.some((function(t){return t.value===u.value}))&&t.productId===i.id})))||!1})}})),a.push(o)})),a},enumerable:!1,configurable:!0}),k}();export{k as IkasProduct};
|
|
1
|
+
import{__spreadArray as t,__assign as e,__awaiter as i,__generator as n}from'./../../../ext/tslib/tslib.es6.js';import r from"lodash/sortBy";import a from"lodash/cloneDeep";import{IkasCategory as o}from"../category/index.js";import{IkasProductVariant as s}from"./variant/index.js";import{IkasProductAttributeValue as u}from"./attribute-value/index.js";import{IkasProductVariantType as c}from"./variant-type/index.js";import{IkasBrand as d}from"../brand/index.js";import{IkasHTMLMetaData as l}from"../html-meta-data/index.js";import{IkasProductTag as p}from"./tag/index.js";import{IkasProductOptionPriceTypeEnum as f,IkasProductType as v}from"@ikas/storefront-models";export{IkasProductType}from"@ikas/storefront-models";import{IkasProductOptionSet as h}from"./option-set/index.js";import{makeObservable as m,observable as g,computed as V}from"mobx";import{IkasProductFunctions as b}from"@ikas/storefront-model-functions";import{IkasProductCampaign as y}from"./campaign/index.js";import{IkasStorefrontConfig as P}from"@ikas/storefront-config";import{IkasBaseStore as I}from"../../../store/base.js";import O from"lodash/groupBy";import{IkasProductBaseUnit as w}from"./base-unit/index.js";import{formatCurrency as S}from"../../../utils/currency.js";import"lodash/get";import T from"../../../store/product/index.js";import{IkasCustomerReviewList as j}from"../../ui/customer-review-list/index.js";import{IkasProductStar as C}from"./star/index.js";import{IkasProductCampaignOffer as x,IkasProductOffer as R}from"./campaign-offer/index.js";import{IkasProductGroup as L}from"./group/index.js";import{IkasImage as G}from"../image/index.js";import{IkasProductSalesChannel as E}from"./sales-channel/index.js";var A=function(){function A(b){void 0===b&&(b={});var O,G,k,D=this;this.metaData=null,this.brand=null,this.tags=null,this.productOptionSetId=null,this.productOptionSet=null,this.campaigns=null,this.selectedVariantValues=[],this.isFiltered=!1,this.isStatic=!1,this.bundleProductCache={},this.productGroupItems=[],this.showVariantsInGroup=!1,this.selectVariantValue=function(i,n){var r,a=D.metaData,o=D.selectedVariantValues.map((function(t){return t.variantTypeId===i.variantTypeId?i:t})),s=D.variants.find((function(t){return t.isActive&&o.every((function(e){return t.variantValues.some((function(t){return t.id===e.id}))}))}));if(s)D.selectedVariantValues=o;else{var u=D.variantTypes.findIndex((function(t){return t.variantType.id===i.variantTypeId}));if(u>0){var c=D.variantTypes.slice(0,u),d=D.selectedVariantValues.filter((function(t){return c.some((function(e){return e.variantType.id===t.variantTypeId}))})),l=t(t([],d,!0),[i],!1);s=D.variants.find((function(t){return t.isActive&&l.every((function(e){return t.variantValues.some((function(t){return t.id===e.id}))}))}))}else{var p=o.slice(0,o.length-1);(s=D.variants.find((function(t){return t.isActive&&p.every((function(e){return t.variantValues.some((function(t){return t.id===e.id}))}))})))||(s=D.variants.find((function(t){return t.isActive&&t.variantValues.some((function(t){return t.id===i.id}))})))}if(!s)return;D.selectedVariantValues=s.variantValues}var f={};new URLSearchParams(window.location.search).forEach((function(t,i){var n;"vid"!==i&&(f=e(e({},f),((n={})[i]=t,n)))})),D.variantTypes.map((function(t){delete f[decodeURIComponent(t.variantType.slug)]}));var v=t(t([],Object.entries(f).map((function(t){var e=t[0],i=t[1];return"".concat(e,"=").concat(i)})),!0),D.variantTypes.map((function(t){var e=t.variantType,i=e.values.find((function(t){return D.selectedVariantValues.some((function(e){return e.id===t.id}))}));if(i)return"".concat(e.slug,"=").concat(i.slug)})),!0).filter((function(t){return!!t})).join("&");if(D.setOptionRealPrices(),!n){var h="/".concat(a.slug);if(v&&(h="/".concat(a.slug,"?").concat(v)),h===window.location.pathname)return;null===(r=I.getInstance().router)||void 0===r||r.replace(h,void 0,{shallow:!1,scroll:!1})}},this.getVariantUnitPriceText=function(t){var e,i,n=t.price;if(n.unitPrice&&D.baseUnit){var r=D.baseUnit.baseAmount,a=(null===(i=null===(e=D.baseUnit)||void 0===e?void 0:e.unit)||void 0===i?void 0:i.name)||"";return"".concat(S(n.unitPrice,n.currency||"",n.currencySymbol||"")," / ").concat(r&&1!==r?r:"").concat(a)}},this.getCampaigns=function(){return i(D,void 0,void 0,(function(){var t,e,i,r,a,o=this;return n(this,(function(n){switch(n.label){case 0:return t=I.getInstance(),e=t.customerStore.customer,i=e?e.customerGroupIds:null,r=this.variants.map((function(t){return t.id})),[4,T.getProductCampaigns({input:{customerGroupIds:i,salesChannelId:P.getSalesChannelId()||"",variantIds:r}})];case 1:return a=n.sent(),this.campaigns=a.data,this.campaigns?(this.campaigns.map((function(t){o.variants.map((function(e){var i;t.variantIds.some((function(t){return t===e.id}))&&(null===(i=e.campaigns)||void 0===i||i.push(t))}))})),[2,this.campaigns]):[2]}}))}))},this.getAvailableStockLocations=function(){return i(D,void 0,void 0,(function(){var t,e;return n(this,(function(i){switch(i.label){case 0:return t=this.variants.map((function(t){return t.id})),e=P.getPickupStockLocationIds(),[4,T.getVariantStockLocations({stockLocationIdList:e,variantIds:t})];case 1:return[2,i.sent().data||[]]}}))}))},this.getCustomerReviews=function(t){return i(D,void 0,void 0,(function(){var i,r,a,o,s;return n(this,(function(n){switch(n.label){case 0:return i=!!(null===(o=this.selectedVariant.bundleSettings)||void 0===o?void 0:o.products.length),r=[this.id],i&&(null===(s=this.selectedVariant.bundleSettings)||void 0===s||s.products.forEach((function(t){r.push(t.productId)}))),[4,(a=new j(e(e(e({},i?{}:{productId:this.id}),{limit:null==t?void 0:t.limit,page:null==t?void 0:t.page,hasImage:null==t?void 0:t.hasImage}),i?{productIds:r}:{}))).getInitial()];case 1:return n.sent(),[2,a]}}))}))},this.getProductOptionSet=function(){return i(D,void 0,void 0,(function(){var t,e;return n(this,(function(i){switch(i.label){case 0:return this.productOptionSet?[2,!0]:this.productOptionSetId?[4,T.listProductOptionSet({id:{eq:this.productOptionSetId}})]:[2,!1];case 1:return(t=i.sent()).isSuccess&&(null===(e=t.data)||void 0===e?void 0:e.length)?(this.productOptionSet=t.data[0],this.setOptionPrices(),this.setOptionRealPrices(),[2,!0]):[2,!1]}}))}))},this.initBundleProducts=function(){return i(D,void 0,void 0,(function(){var t,e,i,r,a,o;return n(this,(function(n){switch(n.label){case 0:return t="","undefined"!=typeof window&&(e=new URLSearchParams(window.location.search),t=e.get("editLineID")||""),t?(i=null===(a=I.getInstance().cartStore.cart)||void 0===a?void 0:a.items.find((function(e){return e.id===t})))&&(r=this.variants.find((function(t){return t.id===i.variant.id})))?(this.selectedVariantValues=r.variantValues,[4,this.getBundleProductsOfVariant(r)]):[3,2]:[3,3];case 1:n.sent(),null===(o=r.bundleSettings)||void 0===o||o.products.forEach((function(t){var e,n,r;try{var a=null===(e=i.variant.bundleProducts)||void 0===e?void 0:e.find((function(e){return e.id===t.id})),o=t.product.variants.find((function(t){return t.id===(null==a?void 0:a.variant.id)}));t.product.selectedVariantValues=o.variantValues,t.quantity=(null===(r=null===(n=i.variant.bundleProducts)||void 0===n?void 0:n.find((function(t){return t.variant.id===o.id})))||void 0===r?void 0:r.quantity)||0}catch(t){console.error(t)}})),n.label=2;case 2:return[3,5];case 3:return[4,this.getBundleProductsOfVariant(this.selectedVariant)];case 4:n.sent(),n.label=5;case 5:return[2]}}))}))},this.setShowVariantsInGroup=function(t){D.showVariantsInGroup=t},this.getBundleProductsOfVariant=function(t){return i(D,void 0,void 0,(function(){var e,i,r,o,s,u,c=this;return n(this,(function(n){switch(n.label){case 0:return(null==(e=null===(r=t.bundleSettings)||void 0===r?void 0:r.products.map((function(t){return t.productId})).filter((function(t){return-1===Object.keys(c.bundleProductCache).indexOf(t)})))?void 0:e.length)?[4,T.searchProducts({input:{productIdList:e,perPage:200,priceListId:P.getPriceListId(),salesChannelId:P.getSalesChannelId()}})]:[3,2];case 1:(i=n.sent()).isSuccess&&(null===(s=null===(o=i.data)||void 0===o?void 0:o.data)||void 0===s||s.forEach((function(t){c.bundleProductCache[t.id]=t}))),n.label=2;case 2:return null===(u=t.bundleSettings)||void 0===u||u.products.forEach((function(t){var e=c.bundleProductCache[t.productId];t.setProduct(new A(a(e)))})),[2]}}))}))},this.setOptionRealPrices=function(){var t,e=D.selectedVariant||D.variants[0];if(e){var i=e.price.priceListId;i&&(null===(t=D.productOptionSet)||void 0===t||t.options.forEach((function(t){var e;if(t.selectSettings)t.selectSettings.values.forEach((function(t){var e;if(t.priceType===f.RATIO&&t.initPrice)if(t.otherPrices){var n=(null===(e=t.otherPrices.find((function(t){return t.priceListId===i})))||void 0===e?void 0:e.price)||t.initPrice||1;t.price=D.selectedVariant.price.finalPrice*n/100}else t.price=D.selectedVariant.price.finalPrice*t.initPrice/100}));else if(t.priceType===f.RATIO&&t.initPrice)if(t.otherPrices){var n=(null===(e=t.otherPrices.find((function(t){return t.priceListId===i})))||void 0===e?void 0:e.price)||t.initPrice||1;t.price=D.selectedVariant.price.finalPrice*n/100}else t.price=D.selectedVariant.price.finalPrice*t.initPrice/100})))}},this.setOptionPrices=function(){var t,e=D.variants[0];if(e){var i=e.price.priceListId;null===(t=D.productOptionSet)||void 0===t||t.options.forEach((function(t){var n,r;if(t.selectSettings&&t.selectSettings.values.forEach((function(t){var n,r;if(t.otherPrices)if(t.priceType===f.RATIO){var a=(null===(n=t.otherPrices.find((function(t){return t.priceListId===i})))||void 0===n?void 0:n.price)||t.price||1;t.price=e.price.finalPrice*a/100}else t.price=(null===(r=t.otherPrices.find((function(t){return t.priceListId===i})))||void 0===r?void 0:r.price)||t.price})),t.otherPrices)if(t.priceType===f.RATIO){var a=(null===(n=t.otherPrices.find((function(t){return t.priceListId===i})))||void 0===n?void 0:n.price)||t.price||1;t.price=e.price.finalPrice*a/100}else t.price=(null===(r=t.otherPrices.find((function(t){return t.priceListId===i})))||void 0===r?void 0:r.price)||t.price}))}},this.id=b.id||Date.now()+"",this.name=b.name||"",this.type=b.type||v.PHYSICAL,this.description=b.description||"",this.shortDescription=b.shortDescription||"",this.metaData=b.metaData?new l(b.metaData):null,this.brand=b.brand?new d(b.brand):null,this.categories=b.categories?b.categories.map((function(t){return new o(t)})):[],this.deleted=b.deleted||null,this.tags=b.tags?b.tags.map((function(t){return new p(t)})):[],this.variants=b.variants?b.variants.map((function(t){return new s(t)})):[],this.attributes=b.attributes?b.attributes.map((function(t){return new u(t)})):[],this.variantTypes=b.variantTypes?b.variantTypes.map((function(t){return new c(t)})):[],this.productOptionSetId=b.productOptionSetId||null,this.averageRating=null!==(O=b.averageRating)&&void 0!==O?O:null,this.reviewCount=null!==(G=b.reviewCount)&&void 0!==G?G:null,this.stars=b.stars?b.stars.map((function(t){return new C(t)})):null,this.baseUnit=b.baseUnit?new w(b.baseUnit):null,this.campaigns=(null===(k=b.campaigns)||void 0===k?void 0:k.map((function(t){return new y(t)})))||null,this.selectedVariantValues=b.selectedVariantValues||[],this.productOptionSet=b.productOptionSet?new h(b.productOptionSet):null,this.variantTypes=r(this.variantTypes,"order"),this.groupVariantsByVariantTypeId=b.groupVariantsByVariantTypeId||null,this.dynamicPriceListIds=b.dynamicPriceListIds||null,this.productVolumeDiscountId=b.productVolumeDiscountId||null,this.campaignOffers=b.campaignOffers?b.campaignOffers.map((function(t){return new x(t)})):null,this.appliedCampaignOffer=b.appliedCampaignOffer,this.offers=b.offers?b.offers.map((function(t){return new R(t)})):void 0,this.productGroup=b.productGroup?new L(b.productGroup):null,this.salesChannels=b.salesChannels?b.salesChannels.map((function(t){return new E(t)})):null,this.productGroupItems=b.productGroupItems,this.variants.forEach((function(t){return t.product=D})),this.setOptionPrices(),this.setOptionRealPrices(),this.customerReviews=b.customerReviews?new j(b.customerReviews):null,m(this,{selectedVariantValues:g,isFiltered:g,isStatic:g,showVariantsInGroup:g,hasVariant:V,hasStock:V,hasValidProductOptionValues:V,href:V,productHref:V,mainVariantType:V,mainVariantValue:V,selectedVariant:V,displayedVariantTypes:V,isCustomerReviewEnabled:V,isCustomerReviewLoginRequired:V,isAddToCartEnabled:V,groupedAttributeValues:V,selectedVariantUnitPriceText:V,displayedProductGroups:V})}return Object.defineProperty(A.prototype,"hasVariant",{get:function(){return b.hasVariant(this,this.showVariantsInGroup)},enumerable:!1,configurable:!0}),Object.defineProperty(A.prototype,"hasStock",{get:function(){return this.isStatic?this.selectedVariant.hasStock:b.hasStock(this)},enumerable:!1,configurable:!0}),Object.defineProperty(A.prototype,"hasValidProductOptionValues",{get:function(){return!this.productOptionSet||this.productOptionSet.hasValidValues},enumerable:!1,configurable:!0}),Object.defineProperty(A.prototype,"href",{get:function(){return b.getSelectedVariantHref(this,this.selectedVariantValues)},enumerable:!1,configurable:!0}),Object.defineProperty(A.prototype,"productHref",{get:function(){return this.groupVariantsByVariantTypeId||this.isFiltered?this.href:b.getProductHref(this)},enumerable:!1,configurable:!0}),Object.defineProperty(A.prototype,"mainVariantType",{get:function(){return b.getMainVariantType(this)},enumerable:!1,configurable:!0}),Object.defineProperty(A.prototype,"mainVariantValue",{get:function(){return b.getMainVariantValue(this.selectedVariantValues)},enumerable:!1,configurable:!0}),Object.defineProperty(A.prototype,"selectedVariant",{get:function(){if(!this.hasVariant)return this.variants[0];var t=this.selectedVariantValues.map((function(t){return t.id}));return this.variants.find((function(e){return e.variantValues.every((function(e){return t.includes(e.id)}))}))},enumerable:!1,configurable:!0}),Object.defineProperty(A.prototype,"displayedVariantTypes",{get:function(){return this.hasVariant?b.getDisplayedVariantTypes(this,this.selectedVariantValues):[]},enumerable:!1,configurable:!0}),Object.defineProperty(A.prototype,"isCustomerReviewEnabled",{get:function(){return P.isCustomerReviewEnabled()},enumerable:!1,configurable:!0}),Object.defineProperty(A.prototype,"isCustomerReviewLoginRequired",{get:function(){return P.isCustomerReviewLoginRequired()},enumerable:!1,configurable:!0}),Object.defineProperty(A.prototype,"isAddToCartEnabled",{get:function(){var t,e=!0;return null===(t=this.selectedVariant.bundleSettings)||void 0===t||t.products.forEach((function(t){0===t.quantity&&null!==t.minQuantity&&0!==t.minQuantity&&(e=!1)})),e&&this.hasValidProductOptionValues&&(this.selectedVariant.hasStock||this.selectedVariant.sellIfOutOfStock)},enumerable:!1,configurable:!0}),Object.defineProperty(A.prototype,"groupedAttributeValues",{get:function(){var t,e=O(this.attributes,"productAttributeId");return(null===(t=this.attributes)||void 0===t?void 0:t.map((function(t){var i=t.productAttributeId;if(i){var n=e[i];return(null==n?void 0:n.length)&&n[0].productAttribute?{attribute:n[0].productAttribute,values:n}:void 0}})).filter((function(t){return!!t})))||[]},enumerable:!1,configurable:!0}),Object.defineProperty(A.prototype,"selectedVariantUnitPriceText",{get:function(){return this.getVariantUnitPriceText(this.selectedVariant)},enumerable:!1,configurable:!0}),Object.defineProperty(A.prototype,"displayedProductGroups",{get:function(){var e,i=this,n=[],a=[];return null===(e=this.productGroupItems)||void 0===e||e.forEach((function(t){t.groupValues.forEach((function(t){n.includes(t.name)||n.push(t.name)}))})),n.forEach((function(e){var n,o={name:e,items:[]};i.productGroupItems=r(i.productGroupItems,(function(t){var e;return parseInt((null===(e=t.order)||void 0===e?void 0:e.value)||"999",10)})),null===(n=i.productGroupItems)||void 0===n||n.forEach((function(n){var r,a,s,u=n.groupValues.find((function(t){return t.name===e}));if(u&&!o.items.some((function(t){return t.value===u.value}))){var c="";if(n.productId===i.id)c=i.href;else{var d=(null===(r=i.productGroup)||void 0===r?void 0:r.values.filter((function(t){return t.name!==e})))||[],l=t(t([],d,!0),[u],!1),p=null===(a=i.productGroupItems)||void 0===a?void 0:a.find((function(t){return l.every((function(e){return t.groupValues.some((function(t){return e.name===t.name&&e.value===t.value}))}))}));c=p?p.href:n.href}o.items.push({image:n.image?new G(n.image):null,href:c,value:u.value,isSelected:(null===(s=i.productGroupItems)||void 0===s?void 0:s.some((function(t){return t.groupValues.some((function(t){return t.value===u.value}))&&t.productId===i.id})))||!1})}})),a.push(o)})),a},enumerable:!1,configurable:!0}),A}();export{A as IkasProduct};
|
|
@@ -68,6 +68,7 @@ export declare class IkasProductVariant implements IProductVariant {
|
|
|
68
68
|
formattedSellPriceWithQuantity: string;
|
|
69
69
|
formattedFinalPrice: string;
|
|
70
70
|
formattedFinalPriceWithQuantity: string;
|
|
71
|
+
salesChannelIds: string[] | null;
|
|
71
72
|
}[];
|
|
72
73
|
saveBackInStockReminder(email: string): Promise<boolean>;
|
|
73
74
|
toJSON(): this;
|