@perevorot/shop 2.0.63 → 2.0.65

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.
@@ -1,2 +1,2 @@
1
- "use strict";var e=require("vue"),t=require("vuex"),o={name:"user",props:{resetToken:{type:String,default:""},resetEmail:{type:String,default:""},tokenValid:{type:Boolean,default:!1}},setup:function(o){var n=t.useStore(),l=e.computed((function(){return n.getters["auth/me"]})),a=e.computed((function(){return n.getters["auth/modal"]})),r=e.computed((function(){return Object.keys(l.value).length>0})),c=e.ref(!1),s=e.computed((function(){return n.getters["auth/account"]})),i=function(){n.commit("auth/modal",null),n.dispatch("auth/me")};return n.dispatch("auth/me",{finally:function(){c.value=!0}}),window.addEventListener("keyup",(function(e){a.value&&"Escape"===e.key&&i()})),o.resetToken&&n.commit("auth/modal","reset"),{mounted:c,user:l,logged:r,modal:a,open:function(){n.commit("auth/modal","login")},close:i,register:function(){n.commit("auth/modal","registration")},logout:function(){n.dispatch("auth/logout")},routes:s}}},n={key:0,class:"auth-user"},l={class:"modal-content"},a=[e.createElementVNode("svg",{class:"icon close"},[e.createElementVNode("use",{"xlink:href":"#close"})],-1)],r={class:"box"},c={class:"tabs"},s={key:1,class:"auth-user"},i={class:"dropdown is-right is-hoverable"},u={class:"dropdown-trigger"},d=["href"],m=e.createElementVNode("i",{class:"fas fa-user"},null,-1),p=e.createElementVNode("span",{class:"icon is-small"},[e.createElementVNode("i",{class:"fas fa-angle-down","aria-hidden":"true"})],-1),g={class:"dropdown-menu",role:"menu"},k={class:"dropdown-content"},f=["href"],v={key:0,class:"icon"},E=["xlink:href"],h={key:1,class:"badge"},V={key:1,class:"dropdown-divider"},N=e.createElementVNode("hr",{class:"dropdown-divider"},null,-1),y=e.createElementVNode("svg",{class:"icon"},[e.createElementVNode("use",{"xlink:href":"#icon-logout"})],-1);o.render=function(t,o,B,C,w,S){var b=e.resolveComponent("login"),x=e.resolveComponent("registration"),_=e.resolveComponent("reset");return C.mounted&&!C.logged?(e.openBlock(),e.createElementBlock("div",n,[e.renderSlot(t.$slots,"login",{open:C.open,label:t.__("auth.login.login")},(function(){return[e.createElementVNode("a",{class:"button",onClick:o[0]||(o[0]=function(){return C.open&&C.open.apply(C,arguments)})},e.toDisplayString(t.__("auth.login.login")),1)]})),e.createElementVNode("div",{class:e.normalizeClass(["modal",{"is-active":C.modal}])},[e.createElementVNode("div",{class:"modal-background",onClick:o[1]||(o[1]=function(){return C.close&&C.close.apply(C,arguments)})}),e.createElementVNode("div",l,[e.createElementVNode("button",{class:"modal-close is-large",onClick:o[2]||(o[2]=function(){return C.close&&C.close.apply(C,arguments)})},a),e.createElementVNode("div",r,[e.createElementVNode("div",c,[e.createElementVNode("ul",null,[e.createElementVNode("li",{class:e.normalizeClass({"is-active":"login"==C.modal||"forget"==C.modal})},[e.createElementVNode("a",{onClick:o[3]||(o[3]=function(){return C.open&&C.open.apply(C,arguments)})},e.toDisplayString(t.__("auth.login.login")),1)],2),e.createElementVNode("li",{class:e.normalizeClass({"is-active":"registration"==C.modal}),onClick:o[4]||(o[4]=function(){return C.register&&C.register.apply(C,arguments)})},[e.createElementVNode("a",null,e.toDisplayString(t.__("auth.login.signup")),1)],2)])]),(e.openBlock(),e.createBlock(e.KeepAlive,null,["login"==C.modal||"forget"==C.modal?(e.openBlock(),e.createBlock(b,{key:0})):e.createCommentVNode("v-if",!0)],1024)),(e.openBlock(),e.createBlock(e.KeepAlive,null,["registration"==C.modal?(e.openBlock(),e.createBlock(x,{key:0})):e.createCommentVNode("v-if",!0)],1024)),e.withDirectives(e.createVNode(_,null,null,512),[[e.vShow,"reset"==C.modal]])])])],2)])):C.mounted?(e.openBlock(),e.createElementBlock("div",s,[e.createElementVNode("div",i,[e.createElementVNode("div",u,[e.createElementVNode("a",{class:"button",href:C.routes[0].path},[e.renderSlot(t.$slots,"user",{user:C.user.name?C.user.name:C.user.email},(function(){return[e.createElementVNode("span",null,[m,e.createTextVNode(" "+e.toDisplayString(C.user.name?C.user.name:C.user.email),1)]),p]}))],8,d)]),e.createElementVNode("div",g,[e.createElementVNode("div",k,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(C.routes,(function(t,o){return e.openBlock(),e.createElementBlock("div",{key:o},[t.text?(e.openBlock(),e.createElementBlock("a",{key:0,href:t.path,class:"dropdown-item"},[t.icon?(e.openBlock(),e.createElementBlock("svg",v,[e.createElementVNode("use",{"xlink:href":"#"+t.icon},null,8,E)])):e.createCommentVNode("v-if",!0),e.createElementVNode("span",null,e.toDisplayString(t.text),1),t.badge?(e.openBlock(),e.createElementBlock("span",h,e.toDisplayString(t.badge),1)):e.createCommentVNode("v-if",!0)],8,f)):(e.openBlock(),e.createElementBlock("hr",V))])})),128)),N,e.createElementVNode("a",{class:"dropdown-item",onClick:o[5]||(o[5]=function(){return C.logout&&C.logout.apply(C,arguments)})},[y,e.createElementVNode("span",null,e.toDisplayString(t.__("auth.user.menu.logout")),1)])])])])])):e.createCommentVNode("v-if",!0)},module.exports=o;
1
+ "use strict";var e=require("vue"),t=require("vuex"),o={name:"user",props:{resetToken:{type:String,default:""},resetEmail:{type:String,default:""},tokenValid:{type:Boolean,default:!1}},setup:function(o){var n=t.useStore(),l=e.computed((function(){return n.getters["auth/me"]})),a=e.computed((function(){return n.getters["auth/modal"]})),r=e.computed((function(){return Object.keys(l.value).length>0})),c=e.ref(!1),s=e.computed((function(){return n.getters["auth/account"]})),i=function(){n.commit("auth/modal",null),n.dispatch("auth/me")};return n.dispatch("auth/me",{finally:function(){c.value=!0}}),window.addEventListener("keyup",(function(e){a.value&&"Escape"===e.key&&i()})),o.resetToken&&n.commit("auth/modal","reset"),{mounted:c,user:l,logged:r,modal:a,open:function(){n.commit("auth/modal","login")},close:i,register:function(){n.commit("auth/modal","registration")},logout:function(){n.dispatch("auth/logout")},routes:s}}},n={key:0,class:"auth-user"},l={class:"modal-content"},a=[e.createElementVNode("svg",{class:"icon close"},[e.createElementVNode("use",{"xlink:href":"#close"})],-1)],r={class:"box"},c={class:"tabs"},s={key:1,class:"auth-user"},i={class:"dropdown is-right is-hoverable"},u={class:"dropdown-trigger"},d=["href"],m=e.createElementVNode("i",{class:"fas fa-user"},null,-1),p=e.createElementVNode("span",{class:"icon is-small"},[e.createElementVNode("i",{class:"fas fa-angle-down","aria-hidden":"true"})],-1),g={class:"dropdown-menu",role:"menu"},k={class:"dropdown-content"},f=["href"],v={key:0,class:"icon"},E=["xlink:href"],h={key:1,class:"badge"},V={key:1,class:"dropdown-divider"},N=e.createElementVNode("hr",{class:"dropdown-divider"},null,-1),y=e.createElementVNode("svg",{class:"icon"},[e.createElementVNode("use",{"xlink:href":"#icon-logout"})],-1);o.render=function(t,o,B,C,S,w){var b=e.resolveComponent("login"),x=e.resolveComponent("registration"),_=e.resolveComponent("reset");return C.mounted&&!C.logged?(e.openBlock(),e.createElementBlock("div",n,[e.renderSlot(t.$slots,"login",{open:C.open,label:t.__("auth.login.login")},(function(){return[e.createElementVNode("a",{class:"button",onClick:o[0]||(o[0]=function(){return C.open&&C.open.apply(C,arguments)})},e.toDisplayString(t.__("auth.login.login")),1)]})),e.createElementVNode("div",{class:e.normalizeClass(["modal",{"is-active":C.modal}])},[e.createElementVNode("div",{class:"modal-background",onClick:o[1]||(o[1]=function(){return C.close&&C.close.apply(C,arguments)})}),e.createElementVNode("div",l,[e.createElementVNode("button",{class:"modal-close is-large",onClick:o[2]||(o[2]=function(){return C.close&&C.close.apply(C,arguments)})},a),e.createElementVNode("div",r,[e.renderSlot(t.$slots,"hero"),e.createElementVNode("div",c,[e.createElementVNode("ul",null,[e.createElementVNode("li",{class:e.normalizeClass({"is-active":"login"==C.modal||"forget"==C.modal})},[e.createElementVNode("a",{onClick:o[3]||(o[3]=function(){return C.open&&C.open.apply(C,arguments)})},e.toDisplayString(t.__("auth.login.login")),1)],2),e.createElementVNode("li",{class:e.normalizeClass({"is-active":"registration"==C.modal}),onClick:o[4]||(o[4]=function(){return C.register&&C.register.apply(C,arguments)})},[e.createElementVNode("a",null,e.toDisplayString(t.__("auth.login.signup")),1)],2)])]),(e.openBlock(),e.createBlock(e.KeepAlive,null,["login"==C.modal||"forget"==C.modal?(e.openBlock(),e.createBlock(b,{key:0})):e.createCommentVNode("v-if",!0)],1024)),(e.openBlock(),e.createBlock(e.KeepAlive,null,["registration"==C.modal?(e.openBlock(),e.createBlock(x,{key:0})):e.createCommentVNode("v-if",!0)],1024)),e.withDirectives(e.createVNode(_,null,null,512),[[e.vShow,"reset"==C.modal]])])])],2)])):C.mounted?(e.openBlock(),e.createElementBlock("div",s,[e.createElementVNode("div",i,[e.createElementVNode("div",u,[e.createElementVNode("a",{class:"button",href:C.routes[0].path},[e.renderSlot(t.$slots,"user",{user:C.user.name?C.user.name:C.user.email},(function(){return[e.createElementVNode("span",null,[m,e.createTextVNode(" "+e.toDisplayString(C.user.name?C.user.name:C.user.email),1)]),p]}))],8,d)]),e.createElementVNode("div",g,[e.createElementVNode("div",k,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(C.routes,(function(t,o){return e.openBlock(),e.createElementBlock("div",{key:o},[t.text?(e.openBlock(),e.createElementBlock("a",{key:0,href:t.path,class:"dropdown-item"},[t.icon?(e.openBlock(),e.createElementBlock("svg",v,[e.createElementVNode("use",{"xlink:href":"#"+t.icon},null,8,E)])):e.createCommentVNode("v-if",!0),e.createElementVNode("span",null,e.toDisplayString(t.text),1),t.badge?(e.openBlock(),e.createElementBlock("span",h,e.toDisplayString(t.badge),1)):e.createCommentVNode("v-if",!0)],8,f)):(e.openBlock(),e.createElementBlock("hr",V))])})),128)),N,e.createElementVNode("a",{class:"dropdown-item",onClick:o[5]||(o[5]=function(){return C.logout&&C.logout.apply(C,arguments)})},[y,e.createElementVNode("span",null,e.toDisplayString(t.__("auth.user.menu.logout")),1)])])])])])):e.createCommentVNode("v-if",!0)},module.exports=o;
2
2
  //# sourceMappingURL=User.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"User.js","sources":["../../../src/components/auth/User.vue","../../../src/components/auth/User.vue?vue&type=template&id=d3f9c2e6&lang.js"],"sourcesContent":["<template>\n <div class=\"auth-user\" v-if=\"mounted && !logged\">\n <slot name=\"login\" :open=\"open\" :label=\"__('auth.login.login')\">\n <a class=\"button\" @click=\"open\">{{ __('auth.login.login') }}</a>\n </slot>\n <div class=\"modal\" v-bind:class=\"{ 'is-active': modal }\">\n <div class=\"modal-background\" @click=\"close\"></div>\n <div class=\"modal-content\">\n <button class=\"modal-close is-large\" @click=\"close\">\n <svg class=\"icon close\">\n <use xlink:href=\"#close\" />\n </svg>\n </button>\n <div class=\"box\">\n <div class=\"tabs\">\n <ul>\n <li\n v-bind:class=\"{\n 'is-active': modal == 'login' || modal == 'forget'\n }\"\n >\n <a @click=\"open\">{{ __('auth.login.login') }}</a>\n </li>\n <li\n v-bind:class=\"{\n 'is-active': modal == 'registration'\n }\"\n @click=\"register\"\n >\n <a>{{ __('auth.login.signup') }}</a>\n </li>\n </ul>\n </div>\n <keep-alive>\n <login v-if=\"modal == 'login' || modal == 'forget'\"></login>\n </keep-alive>\n <keep-alive>\n <registration v-if=\"modal == 'registration'\"></registration>\n </keep-alive>\n <reset v-show=\"modal == 'reset'\"></reset>\n </div>\n </div>\n </div>\n </div>\n <div class=\"auth-user\" v-else-if=\"mounted\">\n <div class=\"dropdown is-right is-hoverable\">\n <div class=\"dropdown-trigger\">\n <a class=\"button\" :href=\"routes[0].path\">\n <slot name=\"user\" :user=\"user.name ? user.name : user.email\">\n <span>\n <i class=\"fas fa-user\"></i>\n {{ user.name ? user.name : user.email }}\n </span>\n <span class=\"icon is-small\">\n <i class=\"fas fa-angle-down\" aria-hidden=\"true\"></i>\n </span>\n </slot>\n </a>\n </div>\n <div class=\"dropdown-menu\" role=\"menu\">\n <div class=\"dropdown-content\">\n <div v-for=\"(item, key) in routes\" v-bind:key=\"key\">\n <a :href=\"item.path\" v-if=\"item.text\" class=\"dropdown-item\">\n <svg class=\"icon\" v-if=\"item.icon\">\n <use :xlink:href=\"'#' + item.icon\" />\n </svg>\n <span>{{ item.text }}</span>\n <span class=\"badge\" v-if=\"item.badge\">{{ item.badge }}</span>\n </a>\n <hr class=\"dropdown-divider\" v-else />\n </div>\n <hr class=\"dropdown-divider\" />\n <a class=\"dropdown-item\" @click=\"logout\">\n <svg class=\"icon\">\n <use xlink:href=\"#icon-logout\" />\n </svg>\n <span>{{ __('auth.user.menu.logout') }}</span>\n </a>\n </div>\n </div>\n </div>\n </div>\n</template>\n\n<script>\nimport { ref, computed } from 'vue';\nimport { useStore } from 'vuex';\n\nexport default {\n name: 'user',\n props: {\n resetToken: {\n type: String,\n default: ''\n },\n resetEmail: {\n type: String,\n default: ''\n },\n tokenValid: {\n type: Boolean,\n default: false\n }\n },\n setup(props) {\n const store = useStore();\n const user = computed(() => store.getters['auth/me']);\n const modal = computed(() => store.getters['auth/modal']);\n const logged = computed(() => Object.keys(user.value).length > 0);\n const mounted = ref(false);\n const routes = computed(() => store.getters['auth/account']);\n\n const open = () => {\n store.commit('auth/modal', 'login');\n };\n\n const close = () => {\n store.commit('auth/modal', null);\n store.dispatch('auth/me');\n };\n\n const logout = () => {\n store.dispatch('auth/logout');\n };\n\n const register = () => {\n store.commit('auth/modal', 'registration');\n };\n\n store.dispatch('auth/me', {\n finally: () => {\n mounted.value = true;\n }\n });\n\n window.addEventListener('keyup', (e) => {\n if (modal.value && e.key === 'Escape') {\n close();\n }\n });\n\n if (props.resetToken) {\n store.commit('auth/modal', 'reset');\n }\n\n return {\n mounted,\n user,\n logged,\n modal,\n open,\n close,\n register,\n logout,\n routes\n };\n }\n};\n</script>","<template>\n <div class=\"auth-user\" v-if=\"mounted && !logged\">\n <slot name=\"login\" :open=\"open\" :label=\"__('auth.login.login')\">\n <a class=\"button\" @click=\"open\">{{ __('auth.login.login') }}</a>\n </slot>\n <div class=\"modal\" v-bind:class=\"{ 'is-active': modal }\">\n <div class=\"modal-background\" @click=\"close\"></div>\n <div class=\"modal-content\">\n <button class=\"modal-close is-large\" @click=\"close\">\n <svg class=\"icon close\">\n <use xlink:href=\"#close\" />\n </svg>\n </button>\n <div class=\"box\">\n <div class=\"tabs\">\n <ul>\n <li\n v-bind:class=\"{\n 'is-active': modal == 'login' || modal == 'forget'\n }\"\n >\n <a @click=\"open\">{{ __('auth.login.login') }}</a>\n </li>\n <li\n v-bind:class=\"{\n 'is-active': modal == 'registration'\n }\"\n @click=\"register\"\n >\n <a>{{ __('auth.login.signup') }}</a>\n </li>\n </ul>\n </div>\n <keep-alive>\n <login v-if=\"modal == 'login' || modal == 'forget'\"></login>\n </keep-alive>\n <keep-alive>\n <registration v-if=\"modal == 'registration'\"></registration>\n </keep-alive>\n <reset v-show=\"modal == 'reset'\"></reset>\n </div>\n </div>\n </div>\n </div>\n <div class=\"auth-user\" v-else-if=\"mounted\">\n <div class=\"dropdown is-right is-hoverable\">\n <div class=\"dropdown-trigger\">\n <a class=\"button\" :href=\"routes[0].path\">\n <slot name=\"user\" :user=\"user.name ? user.name : user.email\">\n <span>\n <i class=\"fas fa-user\"></i>\n {{ user.name ? user.name : user.email }}\n </span>\n <span class=\"icon is-small\">\n <i class=\"fas fa-angle-down\" aria-hidden=\"true\"></i>\n </span>\n </slot>\n </a>\n </div>\n <div class=\"dropdown-menu\" role=\"menu\">\n <div class=\"dropdown-content\">\n <div v-for=\"(item, key) in routes\" v-bind:key=\"key\">\n <a :href=\"item.path\" v-if=\"item.text\" class=\"dropdown-item\">\n <svg class=\"icon\" v-if=\"item.icon\">\n <use :xlink:href=\"'#' + item.icon\" />\n </svg>\n <span>{{ item.text }}</span>\n <span class=\"badge\" v-if=\"item.badge\">{{ item.badge }}</span>\n </a>\n <hr class=\"dropdown-divider\" v-else />\n </div>\n <hr class=\"dropdown-divider\" />\n <a class=\"dropdown-item\" @click=\"logout\">\n <svg class=\"icon\">\n <use xlink:href=\"#icon-logout\" />\n </svg>\n <span>{{ __('auth.user.menu.logout') }}</span>\n </a>\n </div>\n </div>\n </div>\n </div>\n</template>\n\n<script>\nimport { ref, computed } from 'vue';\nimport { useStore } from 'vuex';\n\nexport default {\n name: 'user',\n props: {\n resetToken: {\n type: String,\n default: ''\n },\n resetEmail: {\n type: String,\n default: ''\n },\n tokenValid: {\n type: Boolean,\n default: false\n }\n },\n setup(props) {\n const store = useStore();\n const user = computed(() => store.getters['auth/me']);\n const modal = computed(() => store.getters['auth/modal']);\n const logged = computed(() => Object.keys(user.value).length > 0);\n const mounted = ref(false);\n const routes = computed(() => store.getters['auth/account']);\n\n const open = () => {\n store.commit('auth/modal', 'login');\n };\n\n const close = () => {\n store.commit('auth/modal', null);\n store.dispatch('auth/me');\n };\n\n const logout = () => {\n store.dispatch('auth/logout');\n };\n\n const register = () => {\n store.commit('auth/modal', 'registration');\n };\n\n store.dispatch('auth/me', {\n finally: () => {\n mounted.value = true;\n }\n });\n\n window.addEventListener('keyup', (e) => {\n if (modal.value && e.key === 'Escape') {\n close();\n }\n });\n\n if (props.resetToken) {\n store.commit('auth/modal', 'reset');\n }\n\n return {\n mounted,\n user,\n logged,\n modal,\n open,\n close,\n register,\n logout,\n routes\n };\n }\n};\n</script>"],"names":["name","props","resetToken","type","String","resetEmail","tokenValid","Boolean","setup","store","useStore","user","computed","getters","modal","logged","Object","keys","value","length","mounted","ref","routes","close","commit","dispatch","window","addEventListener","e","key","open","register","logout","_createElementVNode","role","$setup","_createElementBlock","_hoisted_1","_renderSlot","label","_ctx","onClick","_hoisted_2","_hoisted_5","_hoisted_6","_createBlock","_createVNode","_hoisted_7","_hoisted_8","_hoisted_9","href","path","email","_hoisted_11","_hoisted_12","_hoisted_13","_hoisted_14","item","text","icon","_hoisted_16","badge","_hoisted_18","_hoisted_19","_hoisted_20","_hoisted_21"],"mappings":"sDAwFe,CACXA,KAAM,OACNC,MAAO,CACHC,WAAY,CACRC,KAAMC,eACG,IAEbC,WAAY,CACRF,KAAMC,eACG,IAEbE,WAAY,CACRH,KAAMI,iBACG,IAGjBC,eAAMP,OACIQ,EAAQC,aACRC,EAA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AERF,gDAAMO,qDAIlBK,yCACiBV,mBAAoBA,uBAAjCU,iFAEJA,gDACwBV,uBAApBU,mFAEJC,kDAAeX,sBAKGA,yBAAlCC,2BAAAW,GACId,2BAAAe,GACIf,2BAAAgB,GACIhB,gCAAS,SAAUiB,KAAMf,YAAUgB,OAC/Bb,8BAAmB3B,KAAMwB,OAAKnC,KAAOmC,OAAKnC,KAAOmC,OAAKiB,QAAtD,kBACInB,kCACIoB,0CACGlB,OAAKnC,KAAOmC,OAAKnC,KAAOmC,OAAKiB,YAEpCE,cAMZrB,2BAAAsB,GACItB,2BAAAuB,oBACIpB,kDAA2BD,mBAAdsB,EAAM5B,wBAAnBO,4BAA0CP,IAAKA,IAChB4B,EAAKC,oBAAhCtB,gCAAIc,KAAMO,EAAKN,WAA6B,kBAChBM,EAAKE,oBAA7BvB,2BAAAwB,GACI3B,6CAAwBwB,EAAKE,mDAEjC1B,mDAASwB,EAAKC,SACYD,EAAKI,qBAA/BzB,4BAAA0B,oBAAyCL,EAAKI,iEAElDzB,0BAAA2B,eAEJC,EACA/B,gCAAS,gBAAiBQ,sCAAON,0CAC7B8B,EAGAhC,mDAASO"}
1
+ {"version":3,"file":"User.js","sources":["../../../src/components/auth/User.vue","../../../src/components/auth/User.vue?vue&type=template&id=1889af98&lang.js"],"sourcesContent":["<template>\n <div class=\"auth-user\" v-if=\"mounted && !logged\">\n <slot name=\"login\" :open=\"open\" :label=\"__('auth.login.login')\">\n <a class=\"button\" @click=\"open\">{{ __('auth.login.login') }}</a>\n </slot>\n <div class=\"modal\" v-bind:class=\"{ 'is-active': modal }\">\n <div class=\"modal-background\" @click=\"close\"></div>\n <div class=\"modal-content\">\n <button class=\"modal-close is-large\" @click=\"close\">\n <svg class=\"icon close\">\n <use xlink:href=\"#close\" />\n </svg>\n </button>\n <div class=\"box\">\n <slot name=\"hero\"></slot>\n <div class=\"tabs\">\n <ul>\n <li v-bind:class=\"{\n 'is-active': modal == 'login' || modal == 'forget'\n }\">\n <a @click=\"open\">{{ __('auth.login.login') }}</a>\n </li>\n <li v-bind:class=\"{\n 'is-active': modal == 'registration'\n }\" @click=\"register\">\n <a>{{ __('auth.login.signup') }}</a>\n </li>\n </ul>\n </div>\n <keep-alive>\n <login v-if=\"modal == 'login' || modal == 'forget'\"></login>\n </keep-alive>\n <keep-alive>\n <registration v-if=\"modal == 'registration'\"></registration>\n </keep-alive>\n <reset v-show=\"modal == 'reset'\"></reset>\n </div>\n </div>\n </div>\n </div>\n <div class=\"auth-user\" v-else-if=\"mounted\">\n <div class=\"dropdown is-right is-hoverable\">\n <div class=\"dropdown-trigger\">\n <a class=\"button\" :href=\"routes[0].path\">\n <slot name=\"user\" :user=\"user.name ? user.name : user.email\">\n <span>\n <i class=\"fas fa-user\"></i>\n {{ user.name ? user.name : user.email }}\n </span>\n <span class=\"icon is-small\">\n <i class=\"fas fa-angle-down\" aria-hidden=\"true\"></i>\n </span>\n </slot>\n </a>\n </div>\n <div class=\"dropdown-menu\" role=\"menu\">\n <div class=\"dropdown-content\">\n <div v-for=\"(item, key) in routes\" v-bind:key=\"key\">\n <a :href=\"item.path\" v-if=\"item.text\" class=\"dropdown-item\">\n <svg class=\"icon\" v-if=\"item.icon\">\n <use :xlink:href=\"'#' + item.icon\" />\n </svg>\n <span>{{ item.text }}</span>\n <span class=\"badge\" v-if=\"item.badge\">{{ item.badge }}</span>\n </a>\n <hr class=\"dropdown-divider\" v-else />\n </div>\n <hr class=\"dropdown-divider\" />\n <a class=\"dropdown-item\" @click=\"logout\">\n <svg class=\"icon\">\n <use xlink:href=\"#icon-logout\" />\n </svg>\n <span>{{ __('auth.user.menu.logout') }}</span>\n </a>\n </div>\n </div>\n </div>\n </div>\n</template>\n\n<script>\nimport { ref, computed } from 'vue';\nimport { useStore } from 'vuex';\n\nexport default {\n name: 'user',\n props: {\n resetToken: {\n type: String,\n default: ''\n },\n resetEmail: {\n type: String,\n default: ''\n },\n tokenValid: {\n type: Boolean,\n default: false\n }\n },\n setup(props) {\n const store = useStore();\n const user = computed(() => store.getters['auth/me']);\n const modal = computed(() => store.getters['auth/modal']);\n const logged = computed(() => Object.keys(user.value).length > 0);\n const mounted = ref(false);\n const routes = computed(() => store.getters['auth/account']);\n\n const open = () => {\n store.commit('auth/modal', 'login');\n };\n\n const close = () => {\n store.commit('auth/modal', null);\n store.dispatch('auth/me');\n };\n\n const logout = () => {\n store.dispatch('auth/logout');\n };\n\n const register = () => {\n store.commit('auth/modal', 'registration');\n };\n\n store.dispatch('auth/me', {\n finally: () => {\n mounted.value = true;\n }\n });\n\n window.addEventListener('keyup', (e) => {\n if (modal.value && e.key === 'Escape') {\n close();\n }\n });\n\n if (props.resetToken) {\n store.commit('auth/modal', 'reset');\n }\n\n return {\n mounted,\n user,\n logged,\n modal,\n open,\n close,\n register,\n logout,\n routes\n };\n }\n};\n</script>","<template>\n <div class=\"auth-user\" v-if=\"mounted && !logged\">\n <slot name=\"login\" :open=\"open\" :label=\"__('auth.login.login')\">\n <a class=\"button\" @click=\"open\">{{ __('auth.login.login') }}</a>\n </slot>\n <div class=\"modal\" v-bind:class=\"{ 'is-active': modal }\">\n <div class=\"modal-background\" @click=\"close\"></div>\n <div class=\"modal-content\">\n <button class=\"modal-close is-large\" @click=\"close\">\n <svg class=\"icon close\">\n <use xlink:href=\"#close\" />\n </svg>\n </button>\n <div class=\"box\">\n <slot name=\"hero\"></slot>\n <div class=\"tabs\">\n <ul>\n <li v-bind:class=\"{\n 'is-active': modal == 'login' || modal == 'forget'\n }\">\n <a @click=\"open\">{{ __('auth.login.login') }}</a>\n </li>\n <li v-bind:class=\"{\n 'is-active': modal == 'registration'\n }\" @click=\"register\">\n <a>{{ __('auth.login.signup') }}</a>\n </li>\n </ul>\n </div>\n <keep-alive>\n <login v-if=\"modal == 'login' || modal == 'forget'\"></login>\n </keep-alive>\n <keep-alive>\n <registration v-if=\"modal == 'registration'\"></registration>\n </keep-alive>\n <reset v-show=\"modal == 'reset'\"></reset>\n </div>\n </div>\n </div>\n </div>\n <div class=\"auth-user\" v-else-if=\"mounted\">\n <div class=\"dropdown is-right is-hoverable\">\n <div class=\"dropdown-trigger\">\n <a class=\"button\" :href=\"routes[0].path\">\n <slot name=\"user\" :user=\"user.name ? user.name : user.email\">\n <span>\n <i class=\"fas fa-user\"></i>\n {{ user.name ? user.name : user.email }}\n </span>\n <span class=\"icon is-small\">\n <i class=\"fas fa-angle-down\" aria-hidden=\"true\"></i>\n </span>\n </slot>\n </a>\n </div>\n <div class=\"dropdown-menu\" role=\"menu\">\n <div class=\"dropdown-content\">\n <div v-for=\"(item, key) in routes\" v-bind:key=\"key\">\n <a :href=\"item.path\" v-if=\"item.text\" class=\"dropdown-item\">\n <svg class=\"icon\" v-if=\"item.icon\">\n <use :xlink:href=\"'#' + item.icon\" />\n </svg>\n <span>{{ item.text }}</span>\n <span class=\"badge\" v-if=\"item.badge\">{{ item.badge }}</span>\n </a>\n <hr class=\"dropdown-divider\" v-else />\n </div>\n <hr class=\"dropdown-divider\" />\n <a class=\"dropdown-item\" @click=\"logout\">\n <svg class=\"icon\">\n <use xlink:href=\"#icon-logout\" />\n </svg>\n <span>{{ __('auth.user.menu.logout') }}</span>\n </a>\n </div>\n </div>\n </div>\n </div>\n</template>\n\n<script>\nimport { ref, computed } from 'vue';\nimport { useStore } from 'vuex';\n\nexport default {\n name: 'user',\n props: {\n resetToken: {\n type: String,\n default: ''\n },\n resetEmail: {\n type: String,\n default: ''\n },\n tokenValid: {\n type: Boolean,\n default: false\n }\n },\n setup(props) {\n const store = useStore();\n const user = computed(() => store.getters['auth/me']);\n const modal = computed(() => store.getters['auth/modal']);\n const logged = computed(() => Object.keys(user.value).length > 0);\n const mounted = ref(false);\n const routes = computed(() => store.getters['auth/account']);\n\n const open = () => {\n store.commit('auth/modal', 'login');\n };\n\n const close = () => {\n store.commit('auth/modal', null);\n store.dispatch('auth/me');\n };\n\n const logout = () => {\n store.dispatch('auth/logout');\n };\n\n const register = () => {\n store.commit('auth/modal', 'registration');\n };\n\n store.dispatch('auth/me', {\n finally: () => {\n mounted.value = true;\n }\n });\n\n window.addEventListener('keyup', (e) => {\n if (modal.value && e.key === 'Escape') {\n close();\n }\n });\n\n if (props.resetToken) {\n store.commit('auth/modal', 'reset');\n }\n\n return {\n mounted,\n user,\n logged,\n modal,\n open,\n close,\n register,\n logout,\n routes\n };\n }\n};\n</script>"],"names":["name","props","resetToken","type","String","resetEmail","tokenValid","Boolean","setup","store","useStore","user","computed","getters","modal","logged","Object","keys","value","length","mounted","ref","routes","close","commit","dispatch","window","addEventListener","e","key","open","register","logout","_createElementVNode","role","$setup","_createElementBlock","_hoisted_1","_renderSlot","label","_ctx","onClick","_hoisted_2","_hoisted_5","_hoisted_6","_createBlock","_createVNode","_hoisted_7","_hoisted_8","_hoisted_9","href","path","email","_hoisted_11","_hoisted_12","_hoisted_13","_hoisted_14","item","text","icon","_hoisted_16","badge","_hoisted_18","_hoisted_19","_hoisted_20","_hoisted_21"],"mappings":"sDAoFe,CACXA,KAAM,OACNC,MAAO,CACHC,WAAY,CACRC,KAAMC,eACG,IAEbC,WAAY,CACRF,KAAMC,eACG,IAEbE,WAAY,CACRH,KAAMI,iBACG,IAGjBC,eAAMP,OACIQ,EAAQC,aACRC,EAAOC,YAAS,kBAAMH,EAAMI,QAAQ,cACpCC,EAAQF,YAAS,kBAAMH,EAAMI,QAAQ,iBACrCE,EAASH,YAAS,kBAAMI,OAAOC,KAAKN,EAAKO,OAAOC,OAAS,KACzDC,EAAUC,OAAI,GACdC,EAASV,YAAS,kBAAMH,EAAMI,QAAQ,mBAMtCU,EAAQ,WACVd,EAAMe,OAAO,aAAc,MAC3Bf,EAAMgB,SAAS,mBAWnBhB,EAAMgB,SAAS,UAAW,SACb,WACLL,EAAQF,OAAQ,KAIxBQ,OAAOC,iBAAiB,SAAS,SAACC,GAC1Bd,EAAMI,OAAmB,WAAVU,EAAEC,KACjBN,OAIJtB,EAAMC,YACNO,EAAMe,OAAO,aAAc,SAGxB,CACHJ,QAAAA,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gCAAIc,KAAMO,EAAKN,WAA6B,kBAChBM,EAAKE,oBAA7BvB,2BAAAwB,GACI3B,6CAAwBwB,EAAKE,mDAEjC1B,mDAASwB,EAAKC,SACYD,EAAKI,qBAA/BzB,4BAAA0B,oBAAyCL,EAAKI,iEAElDzB,0BAAA2B,eAEJC,EACA/B,gCAAS,gBAAiBQ,sCAAON,0CAC7B8B,EAGAhC,mDAASO"}
@@ -1,2 +1,2 @@
1
- "use strict";var e=require("vue"),t=require("vuex"),n=require("@perevorot/shop/dist/helpers"),l=require("swiper");function o(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var c=o(l),r=e.defineComponent({name:"cart",props:{isModal:{type:Boolean,default:!0}},setup:function(){var o=t.useStore(),r=e.ref(!1),a=e.computed((function(){return o.getters["cart/items"]})),s=e.computed((function(){return o.getters["cart/modal"]})),i=e.computed((function(){return o.getters["cart/total"]})),d=e.computed((function(){return o.getters["cart/quantity"]}));e.watch(s,(function(e){window.cartToggleCallback&&window.cartToggleCallback(e)}));var u=function(){o.commit("cart/modal",!1)};o.dispatch("cart/get",{finally:function(){}}),window.addEventListener("keyup",(function(e){s.value&&"Escape"===e.key&&u()}));var m,p,v=e.ref(null),E=e.ref(null),k=e.ref(null),N=e.computed((function(){var e=o.getters["cart/cross"];return v.value&&(m&&m.destroy(),e.length&&(m=new c.default(v.value,{slidesPerView:1,slidesPerGroup:1,breakpoints:{768:{slidesPerView:2,slidesPerGroup:2}},spaceBetween:0,allowTouchMove:!0,modules:[l.Navigation],mousewheel:{forceToAxis:!0},navigation:{nextEl:E.value,prevEl:k.value}}))),e})),g=e.ref(null),f=e.ref(null),V=e.ref(null),h=e.computed((function(){var e=o.getters["cart/bundles"];return g.value&&(p&&p.destroy(),e.length&&(p=new c.default(g.value,{slidesPerView:1,spaceBetween:0,allowTouchMove:!0,mousewheel:{forceToAxis:!0},navigation:{nextEl:f.value,prevEl:V.value}}))),e}));window.addEventListener("beforeunload",(function(){o.commit("cart/modal",null)})),window.addEventListener("pagehide",(function(){o.commit("cart/modal",null)}));var w=e.ref(!1);return{loading:r,items:a,modal:s,total:i,quantity:d,open:function(){o.commit("cart/modal",!s.value)},close:u,clear:function(){r.value=!0,o.dispatch("cart/clear",{finally:function(){r.value=!1}})},pluralize:n.pluralize,goto:function(e){window.addEventListener("beforeunload",(function(){o.commit("cart/modal",!1)})),window.addEventListener("pagehide",(function(){o.commit("cart/modal",!1)})),window.location.href=e},cross:N,crossSlider:v,crossSliderPrev:k,crossSliderNext:E,bundles:h,bundlesSlider:g,bundlesSliderPrev:V,bundlesSliderNext:f,checkout:function(){try{w.value=!0;var e=[];a.value.forEach((function(t){e.push({name:t.name,id:t.attributes.code,price:t.attributes.price,brand:t.attributes.brand,category:t.attributes.category,quantity:t.quantity})}));var t={ecommerce:{checkout:{products:[e]}},event:"gtm-ee-event","gtm-ee-event-category":"Ecommerce","gtm-ee-event-action":"Checkout","gtm-ee-event-non-interaction":"False",eventCallback:function(){window.location.href=$ziggy("shop.checkout")},eventTimeout:2e3};window.dataLayer?(window.dataLayer.push({ecommerce:null}),window.dataLayer.push(t)):window.location.href=$ziggy("shop.checkout"),setTimeout((function(){window.location.href=$ziggy("shop.checkout")}),2e3)}catch(e){console.error(e),window.location.href=$ziggy("shop.checkout")}},isLoading:w}}}),a={class:"cart"},s={class:"dropdown is-right is-hoverable"},i={class:"dropdown-trigger"},d=e.createElementVNode("i",{class:"fas fa-shopping-cart"},null,-1),u=e.createElementVNode("span",{class:"icon is-small"},[e.createElementVNode("i",{class:"fas fa-angle-down","aria-hidden":"true"})],-1),m={class:"dropdown-menu",role:"menu"},p={key:0,class:"dropdown-content"},v={class:"dropdown-item"},E={class:"columns"},k={class:"column"},N=["innerHTML"],g=e.createElementVNode("div",{class:"dropdown-divider"},null,-1),f={class:"dropdown-item has-text-centered"},V={class:"dropdown-item has-text-centered"},h={key:1,class:"dropdown-content"},w={class:"dropdown-item"},y={class:"modal-content"},B=[e.createElementVNode("svg",{class:"icon close"},[e.createElementVNode("use",{"xlink:href":"#close"})],-1)],b={class:"box"},C={class:"cart-title"},_=["textContent"],x={key:0,class:"items-wrapper"},S={class:"items"},T={class:"columns is-gapless is-vcentered main-actions"},L={class:"column"},M={class:"column has-text-right"},D={class:"totals"},H={class:"title"},$=["innerHTML"],q={class:"column is-narrow"},z={key:0,class:"cross"},P={class:"title"},F={class:"swiper",ref:"crossSlider"},O={class:"swiper-wrapper"},A={class:"columns is-gapless"},G={class:"column is-narrow"},j=["onClick"],I=["src"],J={key:1},K=[e.createElementVNode("use",{"xlink:href":"#logo"},null,-1)],Q={class:"column"},R=["data-code"],U={class:"name"},W=["onClick"],X={class:"columns is-gapless is-vcentered"},Y={class:"column is-narrow"},Z={class:"prices"},ee=["innerHTML"],te=["innerHTML"],ne={class:"column"},le=e.createElementVNode("svg",null,[e.createElementVNode("use",{"xlink:href":"#cart-alternate"})],-1),oe={class:"swiper-nav prev",ref:"crossSliderPrev"},ce=[e.createElementVNode("use",{"xlink:href":"#arrow-submenu"},null,-1)],re={class:"swiper-nav next",ref:"crossSliderNext"},ae=[e.createElementVNode("use",{"xlink:href":"#arrow-submenu"},null,-1)],se={key:1,class:"bundles"},ie={class:"title"},de={class:"swiper",ref:"bundlesSlider"},ue={class:"swiper-wrapper"},me={class:"column is-narrow"},pe=["onClick"],ve=["src"],Ee={key:1},ke=[e.createElementVNode("use",{"xlink:href":"#logo"},null,-1)],Ne={class:"column"},ge={class:"product"},fe={class:"name"},Ve=["onClick"],he={class:"columns is-gapless is-vcentered"},we={class:"prices"},ye=["innerHTML"],Be=e.createElementVNode("div",{class:"column is-narrow"},[e.createElementVNode("svg",{class:"bundle-icon plus"},[e.createElementVNode("use",{"xlink:href":"#bundle-plus"})])],-1),be={class:"column is-narrow"},Ce=["onClick"],_e=["src"],xe={key:1},Se=[e.createElementVNode("use",{"xlink:href":"#logo"},null,-1)],Te={class:"column"},Le={class:"product"},Me={class:"name"},De=["onClick"],He={class:"columns is-gapless is-vcentered"},$e={class:"prices"},qe=["innerHTML"],ze={key:0,class:"column is-narrow"},Pe=[e.createElementVNode("svg",{class:"bundle-icon plus"},[e.createElementVNode("use",{"xlink:href":"#bundle-plus"})],-1)],Fe={key:1,class:"column is-narrow"},Oe=["onClick"],Ae=["src"],Ge={key:1},je=[e.createElementVNode("use",{"xlink:href":"#logo"},null,-1)],Ie={key:2,class:"column"},Je={class:"product"},Ke={class:"name"},Qe=["onClick"],Re={class:"columns is-gapless is-vcentered"},Ue={class:"prices"},We=["innerHTML"],Xe={class:"columns is-vcentered"},Ye={class:"column"},Ze=["innerHTML"],et=["innerHTML"],tt={class:"column"},nt={class:"is-flex is-align-items-center"},lt=["innerHTML"],ot={class:"swiper-nav prev",ref:"bundlesSliderPrev"},ct=[e.createElementVNode("use",{"xlink:href":"#arrow-submenu"},null,-1)],rt={class:"swiper-nav next",ref:"bundlesSliderNext"},at=[e.createElementVNode("use",{"xlink:href":"#arrow-submenu"},null,-1)],st={key:1,class:"empty"},it={class:"title"},dt={class:"message"},ut=["href"],mt=e.createTextVNode(", "),pt=e.createElementVNode("br",null,null,-1),vt={class:"viewed-wrapper"};r.render=function(t,n,l,o,c,r){var Et=e.resolveComponent("cart-item"),kt=e.resolveComponent("cart-add"),Nt=e.resolveComponent("bundle-add"),gt=e.resolveComponent("viewed");return e.openBlock(),e.createElementBlock("div",a,[e.createElementVNode("div",s,[e.createElementVNode("div",i,[e.renderSlot(t.$slots,"default",{total:t.quantity,open:t.open},(function(){return[e.createElementVNode("button",{class:"button",onClick:n[0]||(n[0]=function(){return t.open&&t.open.apply(t,arguments)})},[e.createElementVNode("span",null,[d,e.createTextVNode(" "+e.toDisplayString(t.quantity),1)]),u])]}))]),e.createElementVNode("div",m,[t.items.length?(e.openBlock(),e.createElementBlock("div",p,[e.createElementVNode("div",v,[e.createElementVNode("div",E,[e.createElementVNode("div",k,e.toDisplayString(t.__("shop.cart.total")),1),e.createElementVNode("div",{class:"column has-text-right",innerHTML:t.$filters.price(t.total)},null,8,N)])]),g,e.createElementVNode("div",f,[e.createElementVNode("a",{onClick:n[1]||(n[1]=function(){return t.checkout&&t.checkout.apply(t,arguments)}),class:e.normalizeClass(["button is-link",{"is-disabled":t.isLoading}])},e.toDisplayString(t.__("shop.cart.checkout")),3)]),e.createElementVNode("div",V,[e.renderSlot(t.$slots,"open",{open:t.open},(function(){return[e.createElementVNode("a",{onClick:n[2]||(n[2]=function(){return t.open&&t.open.apply(t,arguments)})},e.toDisplayString(t.__("shop.cart.open")),1)]}))])])):(e.openBlock(),e.createElementBlock("div",h,[e.renderSlot(t.$slots,"empty",{},(function(){return[e.createElementVNode("div",w,e.toDisplayString(t.__("shop.cart.empty")),1)]}))]))])]),t.isModal?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["modal",{"is-active":t.modal}])},[e.createElementVNode("div",{class:"modal-background",onClick:n[3]||(n[3]=function(){return t.close&&t.close.apply(t,arguments)})}),e.createElementVNode("div",y,[e.createElementVNode("button",{class:"modal-close is-large",onClick:n[4]||(n[4]=function(){return t.close&&t.close.apply(t,arguments)})},B),e.createElementVNode("div",b,[e.createElementVNode("div",C,[e.createTextVNode(e.toDisplayString(t.__("shop.cart.title"))+" ",1),t.quantity?(e.openBlock(),e.createElementBlock("span",{key:0,textContent:e.toDisplayString(t.pluralize(t.quantity,t.__("shop.pluralize.products")))},null,8,_)):e.createCommentVNode("v-if",!0)]),t.items.length?(e.openBlock(),e.createElementBlock("div",x,[e.createElementVNode("div",S,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(function(t){return e.openBlock(),e.createBlock(Et,{key:t.id,item:t},null,8,["item"])})),128))]),e.createElementVNode("div",T,[e.createElementVNode("div",L,[e.createElementVNode("button",{class:"button continue",onClick:n[5]||(n[5]=function(){return t.close&&t.close.apply(t,arguments)})},e.toDisplayString(t.__("shop.cart.continue")),1)]),e.createElementVNode("div",M,[e.createElementVNode("div",D,[e.createElementVNode("div",H,[e.createTextVNode(e.toDisplayString(t.__("shop.cart.total"))+" ",1),e.createElementVNode("span",{innerHTML:t.$filters.price(t.total)},null,8,$)])])]),e.createElementVNode("div",q,[e.createElementVNode("a",{onClick:n[6]||(n[6]=function(){return t.checkout&&t.checkout.apply(t,arguments)}),class:"button is-link checkout"},e.toDisplayString(t.__("shop.cart.go_checkout")),1)])]),t.cross.length?(e.openBlock(),e.createElementBlock("div",z,[e.createElementVNode("div",P,e.toDisplayString(t.__("shop.cart.cross")),1),e.createElementVNode("div",F,[e.createElementVNode("div",O,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.cross,(function(n){return e.openBlock(),e.createElementBlock("div",{class:"swiper-slide",key:n.id},[e.createElementVNode("div",A,[e.createElementVNode("div",G,[e.createElementVNode("a",{onClick:function(e){return t.goto(n.href)}},[e.createElementVNode("figure",{class:e.normalizeClass(["image is-square",{"no-thumb":!n.image}])},[n.image?(e.openBlock(),e.createElementBlock("img",{key:0,src:n.image},null,8,I)):(e.openBlock(),e.createElementBlock("svg",J,K))],2)],8,j)]),e.createElementVNode("div",Q,[e.createElementVNode("div",{class:"product","data-code":n.code,"shop-product":""},[e.createElementVNode("div",U,[e.createElementVNode("a",{onClick:function(e){return t.goto(n.href)},"shop-product-name":""},e.toDisplayString(n.name),9,W)]),e.createElementVNode("div",X,[e.createElementVNode("div",Y,[e.createElementVNode("div",Z,[n.priceOld?(e.openBlock(),e.createElementBlock("div",{key:0,class:"price-old",innerHTML:t.$filters.price(n.priceOld)},null,8,ee)):e.createCommentVNode("v-if",!0),e.createElementVNode("div",{class:"price",innerHTML:t.$filters.price(n.price),"shop-product-price":""},null,8,te)])]),e.createElementVNode("div",ne,[e.createVNode(kt,{id:n.id,"is-simple":!0},{default:e.withCtx((function(){return[le]})),_:2},1032,["id"])])])],8,R)])])])})),128))]),(e.openBlock(),e.createElementBlock("svg",oe,ce,512)),(e.openBlock(),e.createElementBlock("svg",re,ae,512))],512)])):e.createCommentVNode("v-if",!0),t.bundles.length?(e.openBlock(),e.createElementBlock("div",se,[e.createElementVNode("div",ie,e.toDisplayString(t.__("shop.cart.bundle")),1),e.createElementVNode("div",de,[e.createElementVNode("div",ue,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.bundles,(function(n){return e.openBlock(),e.createElementBlock("div",{class:"swiper-slide",key:n.id},[e.createElementVNode("div",{class:e.normalizeClass(["columns is-gapless is-vcentered",{"is-third":n.third}])},[e.createElementVNode("div",me,[e.createElementVNode("a",{onClick:function(e){return t.goto(n.href)}},[e.createElementVNode("figure",{class:e.normalizeClass(["image is-square",{"no-thumb":!n.image}])},[n.image?(e.openBlock(),e.createElementBlock("img",{key:0,src:n.image},null,8,ve)):(e.openBlock(),e.createElementBlock("svg",Ee,ke))],2)],8,pe)]),e.createElementVNode("div",Ne,[e.createElementVNode("div",ge,[e.createElementVNode("div",fe,[e.createElementVNode("a",{onClick:function(e){return t.goto(n.href)}},e.toDisplayString(n.name),9,Ve)]),e.createElementVNode("div",he,[e.createElementVNode("div",we,[e.createElementVNode("div",{class:"price",innerHTML:t.$filters.price(n.price)},null,8,ye)])])])]),Be,e.createElementVNode("div",be,[e.createElementVNode("a",{onClick:function(e){return t.goto(n.second.href)}},[e.createElementVNode("figure",{class:e.normalizeClass(["image is-square",{"no-thumb":!n.second.image}])},[n.second.image?(e.openBlock(),e.createElementBlock("img",{key:0,src:n.second.image},null,8,_e)):(e.openBlock(),e.createElementBlock("svg",xe,Se))],2)],8,Ce)]),e.createElementVNode("div",Te,[e.createElementVNode("div",Le,[e.createElementVNode("div",Me,[e.createElementVNode("a",{onClick:function(e){return t.goto(n.second.href)}},e.toDisplayString(n.second.name),9,De)]),e.createElementVNode("div",He,[e.createElementVNode("div",$e,[e.createElementVNode("div",{class:"price",innerHTML:t.$filters.price(n.second.price)},null,8,qe)])])])]),n.third?(e.openBlock(),e.createElementBlock("div",ze,Pe)):e.createCommentVNode("v-if",!0),n.third?(e.openBlock(),e.createElementBlock("div",Fe,[e.createElementVNode("a",{onClick:function(e){return t.goto(n.third.href)}},[e.createElementVNode("figure",{class:e.normalizeClass(["image is-square",{"no-thumb":!n.third.image}])},[n.third.image?(e.openBlock(),e.createElementBlock("img",{key:0,src:n.third.image},null,8,Ae)):(e.openBlock(),e.createElementBlock("svg",Ge,je))],2)],8,Oe)])):e.createCommentVNode("v-if",!0),n.third?(e.openBlock(),e.createElementBlock("div",Ie,[e.createElementVNode("div",Je,[e.createElementVNode("div",Ke,[e.createElementVNode("a",{onClick:function(e){return t.goto(n.third.href)}},e.toDisplayString(n.third.name),9,Qe)]),e.createElementVNode("div",Re,[e.createElementVNode("div",Ue,[e.createElementVNode("div",{class:"price",innerHTML:t.$filters.price(n.third.price)},null,8,We)])])])])):e.createCommentVNode("v-if",!0)],2),e.createElementVNode("div",Xe,[e.createElementVNode("div",Ye,[e.createElementVNode("span",{class:"total-old",innerHTML:t.$filters.price(n.bundle.priceOld)},null,8,Ze),e.createElementVNode("span",{class:"bundle-amount",innerHTML:t.__("shop.cart.bundle_amount")+n.bundle.amount},null,8,et)]),e.createElementVNode("div",tt,[e.createElementVNode("div",nt,[e.createElementVNode("span",{class:"total",innerHTML:t.$filters.price(n.bundle.price)},null,8,lt),e.createVNode(Nt,{id:n.id,second:n.second.id,third:n.third?n.third.id:null},null,8,["id","second","third"])])])])])})),128))])],512),(e.openBlock(),e.createElementBlock("svg",ot,ct,512)),(e.openBlock(),e.createElementBlock("svg",rt,at,512))])):e.createCommentVNode("v-if",!0)])):(e.openBlock(),e.createElementBlock("div",st,[e.createElementVNode("div",it,e.toDisplayString(t.__("shop.cart.no_no")),1),e.createElementVNode("div",dt,[e.createTextVNode(e.toDisplayString(t.__("shop.cart.no_prop"))+" ",1),e.createElementVNode("a",{href:t.$env.locale.url?t.$env.locale.url:"/"},e.toDisplayString(t.__("shop.cart.no_home")),9,ut),mt,pt,e.createTextVNode(e.toDisplayString(t.__("shop.cart.no_search")),1)]),e.createElementVNode("button",{class:"button continue",onClick:n[7]||(n[7]=function(){return t.close&&t.close.apply(t,arguments)})},e.toDisplayString(t.__("shop.cart.continue")),1),e.createElementVNode("div",vt,[e.createVNode(gt,{slider:!0})])]))])])],2)):e.createCommentVNode("v-if",!0)])},module.exports=r;
1
+ "use strict";var e=require("vue"),t=require("vuex"),n=require("@perevorot/shop/dist/helpers"),l=require("swiper");function o(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var c=o(l),r=e.defineComponent({name:"cart",props:{isModal:{type:Boolean,default:!0}},setup:function(){var o=t.useStore(),r=e.ref(!1),a=e.computed((function(){return o.getters["cart/items"]})),s=e.computed((function(){return o.getters["cart/modal"]})),i=e.computed((function(){return o.getters["cart/total"]})),d=e.computed((function(){return o.getters["cart/quantity"]})),u=function(){o.commit("cart/modal",!1)};o.dispatch("cart/get",{finally:function(){}}),window.addEventListener("keyup",(function(e){s.value&&"Escape"===e.key&&u()}));var m,p,v=e.ref(null),E=e.ref(null),k=e.ref(null),N=e.computed((function(){var e=o.getters["cart/cross"];return v.value&&(m&&m.destroy(),e.length&&(m=new c.default(v.value,{slidesPerView:1,slidesPerGroup:1,breakpoints:{768:{slidesPerView:2,slidesPerGroup:2}},spaceBetween:0,allowTouchMove:!0,modules:[l.Navigation],mousewheel:{forceToAxis:!0},navigation:{nextEl:E.value,prevEl:k.value}}))),e})),V=e.ref(null),f=e.ref(null),g=e.ref(null),h=e.computed((function(){var e=o.getters["cart/bundles"];return V.value&&(p&&p.destroy(),e.length&&(p=new c.default(V.value,{slidesPerView:1,spaceBetween:0,allowTouchMove:!0,mousewheel:{forceToAxis:!0},navigation:{nextEl:f.value,prevEl:g.value}}))),e}));window.addEventListener("beforeunload",(function(){o.commit("cart/modal",null)})),window.addEventListener("pagehide",(function(){o.commit("cart/modal",null)}));var y=e.ref(!1);return{loading:r,items:a,modal:s,total:i,quantity:d,open:function(){o.commit("cart/modal",!s.value)},close:u,clear:function(){r.value=!0,o.dispatch("cart/clear",{finally:function(){r.value=!1}})},pluralize:n.pluralize,goto:function(e){window.addEventListener("beforeunload",(function(){o.commit("cart/modal",!1)})),window.addEventListener("pagehide",(function(){o.commit("cart/modal",!1)})),window.location.href=e},cross:N,crossSlider:v,crossSliderPrev:k,crossSliderNext:E,bundles:h,bundlesSlider:V,bundlesSliderPrev:g,bundlesSliderNext:f,checkout:function(){try{y.value=!0;var e=[];a.value.forEach((function(t){e.push({name:t.name,id:t.attributes.code,price:t.attributes.price,brand:t.attributes.brand,category:t.attributes.category,quantity:t.quantity})}));var t={ecommerce:{checkout:{products:[e]}},event:"gtm-ee-event","gtm-ee-event-category":"Ecommerce","gtm-ee-event-action":"Checkout","gtm-ee-event-non-interaction":"False",eventCallback:function(){window.location.href=$ziggy("shop.checkout")},eventTimeout:2e3};window.dataLayer?(window.dataLayer.push({ecommerce:null}),window.dataLayer.push(t)):window.location.href=$ziggy("shop.checkout"),setTimeout((function(){window.location.href=$ziggy("shop.checkout")}),2e3)}catch(e){console.error(e),window.location.href=$ziggy("shop.checkout")}},isLoading:y}}}),a={class:"cart"},s={class:"dropdown is-right is-hoverable"},i={class:"dropdown-trigger"},d=e.createElementVNode("i",{class:"fas fa-shopping-cart"},null,-1),u=e.createElementVNode("span",{class:"icon is-small"},[e.createElementVNode("i",{class:"fas fa-angle-down","aria-hidden":"true"})],-1),m={class:"dropdown-menu",role:"menu"},p={key:0,class:"dropdown-content"},v={class:"dropdown-item"},E={class:"columns"},k={class:"column"},N=["innerHTML"],V=e.createElementVNode("div",{class:"dropdown-divider"},null,-1),f={class:"dropdown-item has-text-centered"},g={class:"dropdown-item has-text-centered"},h={key:1,class:"dropdown-content"},y={class:"dropdown-item"},w={class:"modal-content"},B=[e.createElementVNode("svg",{class:"icon close"},[e.createElementVNode("use",{"xlink:href":"#close"})],-1)],b={class:"box"},C={class:"cart-title"},_=["textContent"],x={key:0,class:"items-wrapper"},S={class:"items"},L={class:"columns is-gapless is-vcentered main-actions"},T={class:"column"},M={class:"column has-text-right"},D={class:"totals"},H={class:"title"},$=["innerHTML"],q={class:"column is-narrow"},z={key:0,class:"cross"},P={class:"title"},F={class:"swiper",ref:"crossSlider"},O={class:"swiper-wrapper"},A={class:"columns is-gapless"},G={class:"column is-narrow"},j=["onClick"],I=["src"],J={key:1},K=[e.createElementVNode("use",{"xlink:href":"#logo"},null,-1)],Q={class:"column"},R=["data-code"],U={class:"name"},W=["onClick"],X={class:"columns is-gapless is-vcentered"},Y={class:"column is-narrow"},Z={class:"prices"},ee=["innerHTML"],te=["innerHTML"],ne={class:"column"},le=e.createElementVNode("svg",null,[e.createElementVNode("use",{"xlink:href":"#cart-alternate"})],-1),oe={class:"swiper-nav prev",ref:"crossSliderPrev"},ce=[e.createElementVNode("use",{"xlink:href":"#arrow-submenu"},null,-1)],re={class:"swiper-nav next",ref:"crossSliderNext"},ae=[e.createElementVNode("use",{"xlink:href":"#arrow-submenu"},null,-1)],se={key:1,class:"bundles"},ie={class:"title"},de={class:"swiper",ref:"bundlesSlider"},ue={class:"swiper-wrapper"},me={class:"column is-narrow"},pe=["onClick"],ve=["src"],Ee={key:1},ke=[e.createElementVNode("use",{"xlink:href":"#logo"},null,-1)],Ne={class:"column"},Ve={class:"product"},fe={class:"name"},ge=["onClick"],he={class:"columns is-gapless is-vcentered"},ye={class:"prices"},we=["innerHTML"],Be=e.createElementVNode("div",{class:"column is-narrow"},[e.createElementVNode("svg",{class:"bundle-icon plus"},[e.createElementVNode("use",{"xlink:href":"#bundle-plus"})])],-1),be={class:"column is-narrow"},Ce=["onClick"],_e=["src"],xe={key:1},Se=[e.createElementVNode("use",{"xlink:href":"#logo"},null,-1)],Le={class:"column"},Te={class:"product"},Me={class:"name"},De=["onClick"],He={class:"columns is-gapless is-vcentered"},$e={class:"prices"},qe=["innerHTML"],ze={key:0,class:"column is-narrow"},Pe=[e.createElementVNode("svg",{class:"bundle-icon plus"},[e.createElementVNode("use",{"xlink:href":"#bundle-plus"})],-1)],Fe={key:1,class:"column is-narrow"},Oe=["onClick"],Ae=["src"],Ge={key:1},je=[e.createElementVNode("use",{"xlink:href":"#logo"},null,-1)],Ie={key:2,class:"column"},Je={class:"product"},Ke={class:"name"},Qe=["onClick"],Re={class:"columns is-gapless is-vcentered"},Ue={class:"prices"},We=["innerHTML"],Xe={class:"columns is-vcentered"},Ye={class:"column"},Ze=["innerHTML"],et=["innerHTML"],tt={class:"column"},nt={class:"is-flex is-align-items-center"},lt=["innerHTML"],ot={class:"swiper-nav prev",ref:"bundlesSliderPrev"},ct=[e.createElementVNode("use",{"xlink:href":"#arrow-submenu"},null,-1)],rt={class:"swiper-nav next",ref:"bundlesSliderNext"},at=[e.createElementVNode("use",{"xlink:href":"#arrow-submenu"},null,-1)],st={key:1,class:"empty"},it={class:"title"},dt={class:"message"},ut=["href"],mt=e.createTextVNode(", "),pt=e.createElementVNode("br",null,null,-1),vt={class:"viewed-wrapper"};r.render=function(t,n,l,o,c,r){var Et=e.resolveComponent("cart-item"),kt=e.resolveComponent("cart-add"),Nt=e.resolveComponent("bundle-add"),Vt=e.resolveComponent("viewed");return e.openBlock(),e.createElementBlock("div",a,[e.createElementVNode("div",s,[e.createElementVNode("div",i,[e.renderSlot(t.$slots,"default",{total:t.quantity,open:t.open},(function(){return[e.createElementVNode("button",{class:"button",onClick:n[0]||(n[0]=function(){return t.open&&t.open.apply(t,arguments)})},[e.createElementVNode("span",null,[d,e.createTextVNode(" "+e.toDisplayString(t.quantity),1)]),u])]}))]),e.createElementVNode("div",m,[t.items.length?(e.openBlock(),e.createElementBlock("div",p,[e.createElementVNode("div",v,[e.createElementVNode("div",E,[e.createElementVNode("div",k,e.toDisplayString(t.__("shop.cart.total")),1),e.createElementVNode("div",{class:"column has-text-right",innerHTML:t.$filters.price(t.total)},null,8,N)])]),V,e.createElementVNode("div",f,[e.createElementVNode("a",{onClick:n[1]||(n[1]=function(){return t.checkout&&t.checkout.apply(t,arguments)}),class:e.normalizeClass(["button is-link",{"is-disabled":t.isLoading}])},e.toDisplayString(t.__("shop.cart.checkout")),3)]),e.createElementVNode("div",g,[e.renderSlot(t.$slots,"open",{open:t.open},(function(){return[e.createElementVNode("a",{onClick:n[2]||(n[2]=function(){return t.open&&t.open.apply(t,arguments)})},e.toDisplayString(t.__("shop.cart.open")),1)]}))])])):(e.openBlock(),e.createElementBlock("div",h,[e.renderSlot(t.$slots,"empty",{},(function(){return[e.createElementVNode("div",y,e.toDisplayString(t.__("shop.cart.empty")),1)]}))]))])]),t.isModal?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["modal",{"is-active":t.modal}])},[e.createElementVNode("div",{class:"modal-background",onClick:n[3]||(n[3]=function(){return t.close&&t.close.apply(t,arguments)})}),e.createElementVNode("div",w,[e.createElementVNode("button",{class:"modal-close is-large",onClick:n[4]||(n[4]=function(){return t.close&&t.close.apply(t,arguments)})},B),e.createElementVNode("div",b,[e.createElementVNode("div",C,[e.createTextVNode(e.toDisplayString(t.__("shop.cart.title"))+" ",1),t.quantity?(e.openBlock(),e.createElementBlock("span",{key:0,textContent:e.toDisplayString(t.pluralize(t.quantity,t.__("shop.pluralize.products")))},null,8,_)):e.createCommentVNode("v-if",!0)]),e.renderSlot(t.$slots,"clear",{clear:t.clear,quantity:t.quantity}),t.items.length?(e.openBlock(),e.createElementBlock("div",x,[e.createElementVNode("div",S,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(function(t){return e.openBlock(),e.createBlock(Et,{key:t.id,item:t},null,8,["item"])})),128))]),e.createElementVNode("div",L,[e.createElementVNode("div",T,[e.createElementVNode("button",{class:"button continue",onClick:n[5]||(n[5]=function(){return t.close&&t.close.apply(t,arguments)})},e.toDisplayString(t.__("shop.cart.continue")),1)]),e.createElementVNode("div",M,[e.createElementVNode("div",D,[e.createElementVNode("div",H,[e.createTextVNode(e.toDisplayString(t.__("shop.cart.total"))+" ",1),e.createElementVNode("span",{innerHTML:t.$filters.price(t.total)},null,8,$)])])]),e.createElementVNode("div",q,[e.createElementVNode("a",{onClick:n[6]||(n[6]=function(){return t.checkout&&t.checkout.apply(t,arguments)}),class:"button is-link checkout"},e.toDisplayString(t.__("shop.cart.go_checkout")),1)])]),t.cross.length?(e.openBlock(),e.createElementBlock("div",z,[e.createElementVNode("div",P,e.toDisplayString(t.__("shop.cart.cross")),1),e.createElementVNode("div",F,[e.createElementVNode("div",O,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.cross,(function(n){return e.openBlock(),e.createElementBlock("div",{class:"swiper-slide",key:n.id},[e.createElementVNode("div",A,[e.createElementVNode("div",G,[e.createElementVNode("a",{onClick:function(e){return t.goto(n.href)}},[e.createElementVNode("figure",{class:e.normalizeClass(["image is-square",{"no-thumb":!n.image}])},[n.image?(e.openBlock(),e.createElementBlock("img",{key:0,src:n.image},null,8,I)):(e.openBlock(),e.createElementBlock("svg",J,K))],2)],8,j)]),e.createElementVNode("div",Q,[e.createElementVNode("div",{class:"product","data-code":n.code,"shop-product":""},[e.createElementVNode("div",U,[e.createElementVNode("a",{onClick:function(e){return t.goto(n.href)},"shop-product-name":""},e.toDisplayString(n.name),9,W)]),e.createElementVNode("div",X,[e.createElementVNode("div",Y,[e.createElementVNode("div",Z,[n.priceOld?(e.openBlock(),e.createElementBlock("div",{key:0,class:"price-old",innerHTML:t.$filters.price(n.priceOld)},null,8,ee)):e.createCommentVNode("v-if",!0),e.createElementVNode("div",{class:"price",innerHTML:t.$filters.price(n.price),"shop-product-price":""},null,8,te)])]),e.createElementVNode("div",ne,[e.createVNode(kt,{id:n.id,"is-simple":!0},{default:e.withCtx((function(){return[le]})),_:2},1032,["id"])])])],8,R)])])])})),128))]),(e.openBlock(),e.createElementBlock("svg",oe,ce,512)),(e.openBlock(),e.createElementBlock("svg",re,ae,512))],512)])):e.createCommentVNode("v-if",!0),t.bundles.length?(e.openBlock(),e.createElementBlock("div",se,[e.createElementVNode("div",ie,e.toDisplayString(t.__("shop.cart.bundle")),1),e.createElementVNode("div",de,[e.createElementVNode("div",ue,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.bundles,(function(n){return e.openBlock(),e.createElementBlock("div",{class:"swiper-slide",key:n.id},[e.createElementVNode("div",{class:e.normalizeClass(["columns is-gapless is-vcentered",{"is-third":n.third}])},[e.createElementVNode("div",me,[e.createElementVNode("a",{onClick:function(e){return t.goto(n.href)}},[e.createElementVNode("figure",{class:e.normalizeClass(["image is-square",{"no-thumb":!n.image}])},[n.image?(e.openBlock(),e.createElementBlock("img",{key:0,src:n.image},null,8,ve)):(e.openBlock(),e.createElementBlock("svg",Ee,ke))],2)],8,pe)]),e.createElementVNode("div",Ne,[e.createElementVNode("div",Ve,[e.createElementVNode("div",fe,[e.createElementVNode("a",{onClick:function(e){return t.goto(n.href)}},e.toDisplayString(n.name),9,ge)]),e.createElementVNode("div",he,[e.createElementVNode("div",ye,[e.createElementVNode("div",{class:"price",innerHTML:t.$filters.price(n.price)},null,8,we)])])])]),Be,e.createElementVNode("div",be,[e.createElementVNode("a",{onClick:function(e){return t.goto(n.second.href)}},[e.createElementVNode("figure",{class:e.normalizeClass(["image is-square",{"no-thumb":!n.second.image}])},[n.second.image?(e.openBlock(),e.createElementBlock("img",{key:0,src:n.second.image},null,8,_e)):(e.openBlock(),e.createElementBlock("svg",xe,Se))],2)],8,Ce)]),e.createElementVNode("div",Le,[e.createElementVNode("div",Te,[e.createElementVNode("div",Me,[e.createElementVNode("a",{onClick:function(e){return t.goto(n.second.href)}},e.toDisplayString(n.second.name),9,De)]),e.createElementVNode("div",He,[e.createElementVNode("div",$e,[e.createElementVNode("div",{class:"price",innerHTML:t.$filters.price(n.second.price)},null,8,qe)])])])]),n.third?(e.openBlock(),e.createElementBlock("div",ze,Pe)):e.createCommentVNode("v-if",!0),n.third?(e.openBlock(),e.createElementBlock("div",Fe,[e.createElementVNode("a",{onClick:function(e){return t.goto(n.third.href)}},[e.createElementVNode("figure",{class:e.normalizeClass(["image is-square",{"no-thumb":!n.third.image}])},[n.third.image?(e.openBlock(),e.createElementBlock("img",{key:0,src:n.third.image},null,8,Ae)):(e.openBlock(),e.createElementBlock("svg",Ge,je))],2)],8,Oe)])):e.createCommentVNode("v-if",!0),n.third?(e.openBlock(),e.createElementBlock("div",Ie,[e.createElementVNode("div",Je,[e.createElementVNode("div",Ke,[e.createElementVNode("a",{onClick:function(e){return t.goto(n.third.href)}},e.toDisplayString(n.third.name),9,Qe)]),e.createElementVNode("div",Re,[e.createElementVNode("div",Ue,[e.createElementVNode("div",{class:"price",innerHTML:t.$filters.price(n.third.price)},null,8,We)])])])])):e.createCommentVNode("v-if",!0)],2),e.createElementVNode("div",Xe,[e.createElementVNode("div",Ye,[e.createElementVNode("span",{class:"total-old",innerHTML:t.$filters.price(n.bundle.priceOld)},null,8,Ze),e.createElementVNode("span",{class:"bundle-amount",innerHTML:t.__("shop.cart.bundle_amount")+n.bundle.amount},null,8,et)]),e.createElementVNode("div",tt,[e.createElementVNode("div",nt,[e.createElementVNode("span",{class:"total",innerHTML:t.$filters.price(n.bundle.price)},null,8,lt),e.createVNode(Nt,{id:n.id,second:n.second.id,third:n.third?n.third.id:null},null,8,["id","second","third"])])])])])})),128))])],512),(e.openBlock(),e.createElementBlock("svg",ot,ct,512)),(e.openBlock(),e.createElementBlock("svg",rt,at,512))])):e.createCommentVNode("v-if",!0)])):(e.openBlock(),e.createElementBlock("div",st,[e.createElementVNode("div",it,e.toDisplayString(t.__("shop.cart.no_no")),1),e.createElementVNode("div",dt,[e.createTextVNode(e.toDisplayString(t.__("shop.cart.no_prop"))+" ",1),e.createElementVNode("a",{href:t.$env.locale.url?t.$env.locale.url:"/"},e.toDisplayString(t.__("shop.cart.no_home")),9,ut),mt,pt,e.createTextVNode(e.toDisplayString(t.__("shop.cart.no_search")),1)]),e.createElementVNode("button",{class:"button continue",onClick:n[7]||(n[7]=function(){return t.close&&t.close.apply(t,arguments)})},e.toDisplayString(t.__("shop.cart.continue")),1),e.createElementVNode("div",vt,[e.createVNode(Vt,{slider:!0})])]))])])],2)):e.createCommentVNode("v-if",!0)])},module.exports=r;
2
2
  //# sourceMappingURL=Cart.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Cart.js","sources":["../../../../src/components/shop/cart/Cart.vue","../../../../src/components/shop/cart/Cart.vue?vue&type=template&id=6d36431b&lang.js"],"sourcesContent":["<template>\n <div class=\"cart\">\n <div class=\"dropdown is-right is-hoverable\">\n <div class=\"dropdown-trigger\">\n <slot :total=\"quantity\" :open=\"open\">\n <button class=\"button\" @click=\"open\">\n <span>\n <i class=\"fas fa-shopping-cart\"></i>\n {{ quantity }}\n </span>\n <span class=\"icon is-small\">\n <i class=\"fas fa-angle-down\" aria-hidden=\"true\"></i>\n </span>\n </button>\n </slot>\n </div>\n <div class=\"dropdown-menu\" role=\"menu\">\n <div class=\"dropdown-content\" v-if=\"items.length\">\n <div class=\"dropdown-item\">\n <div class=\"columns\">\n <div class=\"column\">{{ __('shop.cart.total') }}</div>\n <div class=\"column has-text-right\" v-html=\"$filters.price(total)\"></div>\n </div>\n </div>\n <div class=\"dropdown-divider\"></div>\n <div class=\"dropdown-item has-text-centered\">\n <a @click=\"checkout\" class=\"button is-link\" v-bind:class=\"{ 'is-disabled': isLoading }\">{{ __('shop.cart.checkout') }}</a>\n </div>\n <div class=\"dropdown-item has-text-centered\">\n <slot name=\"open\" :open=\"open\">\n <a @click=\"open\">{{ __('shop.cart.open') }}</a>\n </slot>\n </div>\n </div>\n <div class=\"dropdown-content\" v-else>\n <slot name=\"empty\">\n <div class=\"dropdown-item\">{{ __('shop.cart.empty') }}</div>\n </slot>\n </div>\n </div>\n </div>\n <div class=\"modal\" v-if=\"isModal\" v-bind:class=\"{ 'is-active': modal }\">\n <div class=\"modal-background\" @click=\"close\"></div>\n <div class=\"modal-content\">\n <button class=\"modal-close is-large\" @click=\"close\">\n <svg class=\"icon close\">\n <use xlink:href=\"#close\" />\n </svg>\n </button>\n <div class=\"box\">\n <div class=\"cart-title\">\n {{ __('shop.cart.title') }}\n <span v-if=\"quantity\" v-text=\"pluralize(quantity, __('shop.pluralize.products'))\"></span>\n </div>\n <div class=\"items-wrapper\" v-if=\"items.length\">\n <div class=\"items\">\n <cart-item v-for=\"item in items\" v-bind:key=\"item.id\" :item=\"item\"></cart-item>\n </div>\n\n <div class=\"columns is-gapless is-vcentered main-actions\">\n <div class=\"column\">\n <button class=\"button continue\" @click=\"close\">{{ __('shop.cart.continue') }}</button>\n </div>\n <div class=\"column has-text-right\">\n <div class=\"totals\">\n <div class=\"title\">\n {{ __('shop.cart.total') }}\n <span v-html=\"$filters.price(total)\"></span>\n </div>\n </div>\n </div>\n <div class=\"column is-narrow\">\n <a @click=\"checkout\" class=\"button is-link checkout\">{{ __('shop.cart.go_checkout') }}</a>\n </div>\n </div>\n\n <div class=\"cross\" v-if=\"cross.length\">\n <div class=\"title\">{{ __('shop.cart.cross') }}</div>\n <div class=\"swiper\" ref=\"crossSlider\">\n <div class=\"swiper-wrapper\">\n <div class=\"swiper-slide\" v-for=\"item in cross\" v-bind:key=\"item.id\">\n <div class=\"columns is-gapless\">\n <div class=\"column is-narrow\">\n <a @click=\"goto(item.href)\">\n <figure class=\"image is-square\" v-bind:class=\"{ 'no-thumb': !item.image }\">\n <img :src=\"item.image\" v-if=\"item.image\" />\n <svg v-else>\n <use xlink:href=\"#logo\" />\n </svg>\n </figure>\n </a>\n </div>\n <div class=\"column\">\n <div class=\"product\" :data-code=\"item.code\" shop-product>\n <div class=\"name\">\n <a @click=\"goto(item.href)\" shop-product-name>{{ item.name }}</a>\n </div>\n <div class=\"columns is-gapless is-vcentered\">\n <div class=\"column is-narrow\">\n <div class=\"prices\">\n <div class=\"price-old\" v-if=\"item.priceOld\" v-html=\"$filters.price(item.priceOld)\"></div>\n <div class=\"price\" v-html=\"$filters.price(item.price)\" shop-product-price></div>\n </div>\n </div>\n <div class=\"column\">\n <cart-add :id=\"item.id\" :is-simple=\"true\">\n <svg>\n <use xlink:href=\"#cart-alternate\" />\n </svg>\n </cart-add>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n <svg class=\"swiper-nav prev\" ref=\"crossSliderPrev\">\n <use xlink:href=\"#arrow-submenu\" />\n </svg>\n <svg class=\"swiper-nav next\" ref=\"crossSliderNext\">\n <use xlink:href=\"#arrow-submenu\" />\n </svg>\n </div>\n </div>\n <div class=\"bundles\" v-if=\"bundles.length\">\n <div class=\"title\">{{ __('shop.cart.bundle') }}</div>\n <div class=\"swiper\" ref=\"bundlesSlider\">\n <div class=\"swiper-wrapper\">\n <div class=\"swiper-slide\" v-for=\"item in bundles\" v-bind:key=\"item.id\">\n <div class=\"columns is-gapless is-vcentered\" v-bind:class=\"{ 'is-third': item.third }\">\n <div class=\"column is-narrow\">\n <a @click=\"goto(item.href)\">\n <figure class=\"image is-square\" v-bind:class=\"{ 'no-thumb': !item.image }\">\n <img :src=\"item.image\" v-if=\"item.image\" />\n <svg v-else>\n <use xlink:href=\"#logo\" />\n </svg>\n </figure>\n </a>\n </div>\n <div class=\"column\">\n <div class=\"product\">\n <div class=\"name\">\n <a @click=\"goto(item.href)\">{{ item.name }}</a>\n </div>\n <div class=\"columns is-gapless is-vcentered\">\n <div class=\"prices\">\n <div class=\"price\" v-html=\"$filters.price(item.price)\"></div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"column is-narrow\">\n <svg class=\"bundle-icon plus\">\n <use xlink:href=\"#bundle-plus\" />\n </svg>\n </div>\n <div class=\"column is-narrow\">\n <a @click=\"goto(item.second.href)\">\n <figure class=\"image is-square\" v-bind:class=\"{ 'no-thumb': !item.second.image }\">\n <img :src=\"item.second.image\" v-if=\"item.second.image\" />\n <svg v-else>\n <use xlink:href=\"#logo\" />\n </svg>\n </figure>\n </a>\n </div>\n <div class=\"column\">\n <div class=\"product\">\n <div class=\"name\">\n <a @click=\"goto(item.second.href)\">{{ item.second.name }}</a>\n </div>\n <div class=\"columns is-gapless is-vcentered\">\n <div class=\"prices\">\n <div class=\"price\" v-html=\"$filters.price(item.second.price)\"></div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"column is-narrow\" v-if=\"item.third\">\n <svg class=\"bundle-icon plus\">\n <use xlink:href=\"#bundle-plus\" />\n </svg>\n </div>\n <div class=\"column is-narrow\" v-if=\"item.third\">\n <a @click=\"goto(item.third.href)\">\n <figure class=\"image is-square\" v-bind:class=\"{ 'no-thumb': !item.third.image }\">\n <img :src=\"item.third.image\" v-if=\"item.third.image\" />\n <svg v-else>\n <use xlink:href=\"#logo\" />\n </svg>\n </figure>\n </a>\n </div>\n <div class=\"column\" v-if=\"item.third\">\n <div class=\"product\">\n <div class=\"name\">\n <a @click=\"goto(item.third.href)\">{{ item.third.name }}</a>\n </div>\n <div class=\"columns is-gapless is-vcentered\">\n <div class=\"prices\">\n <div class=\"price\" v-html=\"$filters.price(item.third.price)\"></div>\n </div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"columns is-vcentered\">\n <div class=\"column\">\n <span class=\"total-old\" v-html=\"$filters.price(item.bundle.priceOld)\"></span>\n <span class=\"bundle-amount\" v-html=\"__('shop.cart.bundle_amount') + item.bundle.amount\"></span>\n </div>\n <div class=\"column\">\n <div class=\"is-flex is-align-items-center\">\n <span class=\"total\" v-html=\"$filters.price(item.bundle.price)\"></span>\n <bundle-add :id=\"item.id\" :second=\"item.second.id\" v-bind:third=\"item.third ? item.third.id : null\"></bundle-add>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n <svg class=\"swiper-nav prev\" ref=\"bundlesSliderPrev\">\n <use xlink:href=\"#arrow-submenu\" />\n </svg>\n <svg class=\"swiper-nav next\" ref=\"bundlesSliderNext\">\n <use xlink:href=\"#arrow-submenu\" />\n </svg>\n </div>\n </div>\n <div v-else class=\"empty\">\n <div class=\"title\">{{ __('shop.cart.no_no') }}</div>\n <div class=\"message\">\n {{ __('shop.cart.no_prop') }}\n <a :href=\"$env.locale.url ? $env.locale.url : '/'\">{{ __('shop.cart.no_home') }}</a>, <br />{{ __('shop.cart.no_search') }}\n </div>\n <button class=\"button continue\" @click=\"close\">{{ __('shop.cart.continue') }}</button>\n <div class=\"viewed-wrapper\">\n <viewed :slider=\"true\"></viewed>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n</template>\n\n<script>\nimport { ref, computed, defineComponent, watch } from 'vue';\nimport { useStore } from 'vuex';\nimport { pluralize } from '@perevorot/shop/dist/helpers';\nimport Swiper, { Navigation } from 'swiper';\n\nexport default /*#__PURE__*/ defineComponent({\n name: 'cart',\n props: {\n isModal: {\n type: Boolean,\n default: true\n }\n },\n setup() {\n const store = useStore();\n const loading = ref(false);\n\n const items = computed(() => store.getters['cart/items']);\n const modal = computed(() => store.getters['cart/modal']);\n const total = computed(() => store.getters['cart/total']);\n const quantity = computed(() => store.getters['cart/quantity']);\n\n watch(modal, (value) => {\n if (window.cartToggleCallback) {\n window.cartToggleCallback(value);\n }\n });\n\n const open = () => {\n store.commit('cart/modal', !modal.value);\n };\n\n const close = () => {\n store.commit('cart/modal', false);\n };\n\n const clear = () => {\n loading.value = true;\n\n store.dispatch('cart/clear', {\n finally: () => {\n loading.value = false;\n }\n });\n };\n\n store.dispatch('cart/get', {\n finally: () => { }\n });\n\n window.addEventListener('keyup', (e) => {\n if (modal.value && e.key === 'Escape') {\n close();\n }\n });\n\n const goto = (href) => {\n window.addEventListener('beforeunload', () => {\n store.commit('cart/modal', false);\n });\n\n window.addEventListener('pagehide', () => {\n store.commit('cart/modal', false);\n });\n\n window.location.href = href;\n };\n\n let crossSwiper;\n const crossSlider = ref(null);\n const crossSliderNext = ref(null);\n const crossSliderPrev = ref(null);\n\n const cross = computed(() => {\n const cross = store.getters['cart/cross'];\n\n if (crossSlider.value) {\n if (crossSwiper) {\n crossSwiper.destroy();\n }\n\n if (cross.length) {\n crossSwiper = new Swiper(crossSlider.value, {\n slidesPerView: 1,\n slidesPerGroup: 1,\n breakpoints: {\n 768: {\n slidesPerView: 2,\n slidesPerGroup: 2\n }\n },\n spaceBetween: 0,\n allowTouchMove: true,\n modules: [Navigation],\n mousewheel: {\n forceToAxis: true\n },\n navigation: {\n nextEl: crossSliderNext.value,\n prevEl: crossSliderPrev.value\n }\n });\n }\n }\n\n return cross;\n });\n\n let bundlesSwiper;\n const bundlesSlider = ref(null);\n const bundlesSliderNext = ref(null);\n const bundlesSliderPrev = ref(null);\n\n const bundles = computed(() => {\n const bundles = store.getters['cart/bundles'];\n\n if (bundlesSlider.value) {\n if (bundlesSwiper) {\n bundlesSwiper.destroy();\n }\n\n if (bundles.length) {\n bundlesSwiper = new Swiper(bundlesSlider.value, {\n slidesPerView: 1,\n spaceBetween: 0,\n allowTouchMove: true,\n mousewheel: {\n forceToAxis: true\n },\n navigation: {\n nextEl: bundlesSliderNext.value,\n prevEl: bundlesSliderPrev.value\n }\n });\n }\n }\n\n return bundles;\n });\n\n window.addEventListener('beforeunload', () => {\n store.commit('cart/modal', null);\n });\n\n window.addEventListener('pagehide', () => {\n store.commit('cart/modal', null);\n });\n\n const isLoading = ref(false);\n\n const checkout = () => {\n try {\n isLoading.value = true;\n\n let products = [];\n\n items.value.forEach((item) => {\n products.push({\n name: item.name,\n id: item.attributes.code,\n price: item.attributes.price,\n brand: item.attributes.brand,\n category: item.attributes.category,\n quantity: item.quantity\n });\n });\n\n const object = {\n ecommerce: {\n checkout: {\n products: [products]\n }\n },\n event: 'gtm-ee-event',\n 'gtm-ee-event-category': 'Ecommerce',\n 'gtm-ee-event-action': 'Checkout',\n 'gtm-ee-event-non-interaction': 'False',\n eventCallback: function () {\n window.location.href = $ziggy('shop.checkout');\n },\n eventTimeout: 2000\n };\n\n if (window.dataLayer) {\n window.dataLayer.push({\n ecommerce: null\n });\n\n window.dataLayer.push(object);\n } else {\n window.location.href = $ziggy('shop.checkout');\n }\n\n setTimeout(() => {\n window.location.href = $ziggy('shop.checkout');\n }, 2000);\n } catch (error) {\n console.error(error);\n\n window.location.href = $ziggy('shop.checkout');\n }\n };\n\n return {\n loading,\n items,\n modal,\n total,\n quantity,\n open,\n close,\n clear,\n pluralize,\n goto,\n cross,\n crossSlider,\n crossSliderPrev,\n crossSliderNext,\n bundles,\n bundlesSlider,\n bundlesSliderPrev,\n bundlesSliderNext,\n checkout,\n isLoading,\n };\n }\n});\n</script>","<template>\n <div class=\"cart\">\n <div class=\"dropdown is-right is-hoverable\">\n <div class=\"dropdown-trigger\">\n <slot :total=\"quantity\" :open=\"open\">\n <button class=\"button\" @click=\"open\">\n <span>\n <i class=\"fas fa-shopping-cart\"></i>\n {{ quantity }}\n </span>\n <span class=\"icon is-small\">\n <i class=\"fas fa-angle-down\" aria-hidden=\"true\"></i>\n </span>\n </button>\n </slot>\n </div>\n <div class=\"dropdown-menu\" role=\"menu\">\n <div class=\"dropdown-content\" v-if=\"items.length\">\n <div class=\"dropdown-item\">\n <div class=\"columns\">\n <div class=\"column\">{{ __('shop.cart.total') }}</div>\n <div class=\"column has-text-right\" v-html=\"$filters.price(total)\"></div>\n </div>\n </div>\n <div class=\"dropdown-divider\"></div>\n <div class=\"dropdown-item has-text-centered\">\n <a @click=\"checkout\" class=\"button is-link\" v-bind:class=\"{ 'is-disabled': isLoading }\">{{ __('shop.cart.checkout') }}</a>\n </div>\n <div class=\"dropdown-item has-text-centered\">\n <slot name=\"open\" :open=\"open\">\n <a @click=\"open\">{{ __('shop.cart.open') }}</a>\n </slot>\n </div>\n </div>\n <div class=\"dropdown-content\" v-else>\n <slot name=\"empty\">\n <div class=\"dropdown-item\">{{ __('shop.cart.empty') }}</div>\n </slot>\n </div>\n </div>\n </div>\n <div class=\"modal\" v-if=\"isModal\" v-bind:class=\"{ 'is-active': modal }\">\n <div class=\"modal-background\" @click=\"close\"></div>\n <div class=\"modal-content\">\n <button class=\"modal-close is-large\" @click=\"close\">\n <svg class=\"icon close\">\n <use xlink:href=\"#close\" />\n </svg>\n </button>\n <div class=\"box\">\n <div class=\"cart-title\">\n {{ __('shop.cart.title') }}\n <span v-if=\"quantity\" v-text=\"pluralize(quantity, __('shop.pluralize.products'))\"></span>\n </div>\n <div class=\"items-wrapper\" v-if=\"items.length\">\n <div class=\"items\">\n <cart-item v-for=\"item in items\" v-bind:key=\"item.id\" :item=\"item\"></cart-item>\n </div>\n\n <div class=\"columns is-gapless is-vcentered main-actions\">\n <div class=\"column\">\n <button class=\"button continue\" @click=\"close\">{{ __('shop.cart.continue') }}</button>\n </div>\n <div class=\"column has-text-right\">\n <div class=\"totals\">\n <div class=\"title\">\n {{ __('shop.cart.total') }}\n <span v-html=\"$filters.price(total)\"></span>\n </div>\n </div>\n </div>\n <div class=\"column is-narrow\">\n <a @click=\"checkout\" class=\"button is-link checkout\">{{ __('shop.cart.go_checkout') }}</a>\n </div>\n </div>\n\n <div class=\"cross\" v-if=\"cross.length\">\n <div class=\"title\">{{ __('shop.cart.cross') }}</div>\n <div class=\"swiper\" ref=\"crossSlider\">\n <div class=\"swiper-wrapper\">\n <div class=\"swiper-slide\" v-for=\"item in cross\" v-bind:key=\"item.id\">\n <div class=\"columns is-gapless\">\n <div class=\"column is-narrow\">\n <a @click=\"goto(item.href)\">\n <figure class=\"image is-square\" v-bind:class=\"{ 'no-thumb': !item.image }\">\n <img :src=\"item.image\" v-if=\"item.image\" />\n <svg v-else>\n <use xlink:href=\"#logo\" />\n </svg>\n </figure>\n </a>\n </div>\n <div class=\"column\">\n <div class=\"product\" :data-code=\"item.code\" shop-product>\n <div class=\"name\">\n <a @click=\"goto(item.href)\" shop-product-name>{{ item.name }}</a>\n </div>\n <div class=\"columns is-gapless is-vcentered\">\n <div class=\"column is-narrow\">\n <div class=\"prices\">\n <div class=\"price-old\" v-if=\"item.priceOld\" v-html=\"$filters.price(item.priceOld)\"></div>\n <div class=\"price\" v-html=\"$filters.price(item.price)\" shop-product-price></div>\n </div>\n </div>\n <div class=\"column\">\n <cart-add :id=\"item.id\" :is-simple=\"true\">\n <svg>\n <use xlink:href=\"#cart-alternate\" />\n </svg>\n </cart-add>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n <svg class=\"swiper-nav prev\" ref=\"crossSliderPrev\">\n <use xlink:href=\"#arrow-submenu\" />\n </svg>\n <svg class=\"swiper-nav next\" ref=\"crossSliderNext\">\n <use xlink:href=\"#arrow-submenu\" />\n </svg>\n </div>\n </div>\n <div class=\"bundles\" v-if=\"bundles.length\">\n <div class=\"title\">{{ __('shop.cart.bundle') }}</div>\n <div class=\"swiper\" ref=\"bundlesSlider\">\n <div class=\"swiper-wrapper\">\n <div class=\"swiper-slide\" v-for=\"item in bundles\" v-bind:key=\"item.id\">\n <div class=\"columns is-gapless is-vcentered\" v-bind:class=\"{ 'is-third': item.third }\">\n <div class=\"column is-narrow\">\n <a @click=\"goto(item.href)\">\n <figure class=\"image is-square\" v-bind:class=\"{ 'no-thumb': !item.image }\">\n <img :src=\"item.image\" v-if=\"item.image\" />\n <svg v-else>\n <use xlink:href=\"#logo\" />\n </svg>\n </figure>\n </a>\n </div>\n <div class=\"column\">\n <div class=\"product\">\n <div class=\"name\">\n <a @click=\"goto(item.href)\">{{ item.name }}</a>\n </div>\n <div class=\"columns is-gapless is-vcentered\">\n <div class=\"prices\">\n <div class=\"price\" v-html=\"$filters.price(item.price)\"></div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"column is-narrow\">\n <svg class=\"bundle-icon plus\">\n <use xlink:href=\"#bundle-plus\" />\n </svg>\n </div>\n <div class=\"column is-narrow\">\n <a @click=\"goto(item.second.href)\">\n <figure class=\"image is-square\" v-bind:class=\"{ 'no-thumb': !item.second.image }\">\n <img :src=\"item.second.image\" v-if=\"item.second.image\" />\n <svg v-else>\n <use xlink:href=\"#logo\" />\n </svg>\n </figure>\n </a>\n </div>\n <div class=\"column\">\n <div class=\"product\">\n <div class=\"name\">\n <a @click=\"goto(item.second.href)\">{{ item.second.name }}</a>\n </div>\n <div class=\"columns is-gapless is-vcentered\">\n <div class=\"prices\">\n <div class=\"price\" v-html=\"$filters.price(item.second.price)\"></div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"column is-narrow\" v-if=\"item.third\">\n <svg class=\"bundle-icon plus\">\n <use xlink:href=\"#bundle-plus\" />\n </svg>\n </div>\n <div class=\"column is-narrow\" v-if=\"item.third\">\n <a @click=\"goto(item.third.href)\">\n <figure class=\"image is-square\" v-bind:class=\"{ 'no-thumb': !item.third.image }\">\n <img :src=\"item.third.image\" v-if=\"item.third.image\" />\n <svg v-else>\n <use xlink:href=\"#logo\" />\n </svg>\n </figure>\n </a>\n </div>\n <div class=\"column\" v-if=\"item.third\">\n <div class=\"product\">\n <div class=\"name\">\n <a @click=\"goto(item.third.href)\">{{ item.third.name }}</a>\n </div>\n <div class=\"columns is-gapless is-vcentered\">\n <div class=\"prices\">\n <div class=\"price\" v-html=\"$filters.price(item.third.price)\"></div>\n </div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"columns is-vcentered\">\n <div class=\"column\">\n <span class=\"total-old\" v-html=\"$filters.price(item.bundle.priceOld)\"></span>\n <span class=\"bundle-amount\" v-html=\"__('shop.cart.bundle_amount') + item.bundle.amount\"></span>\n </div>\n <div class=\"column\">\n <div class=\"is-flex is-align-items-center\">\n <span class=\"total\" v-html=\"$filters.price(item.bundle.price)\"></span>\n <bundle-add :id=\"item.id\" :second=\"item.second.id\" v-bind:third=\"item.third ? item.third.id : null\"></bundle-add>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n <svg class=\"swiper-nav prev\" ref=\"bundlesSliderPrev\">\n <use xlink:href=\"#arrow-submenu\" />\n </svg>\n <svg class=\"swiper-nav next\" ref=\"bundlesSliderNext\">\n <use xlink:href=\"#arrow-submenu\" />\n </svg>\n </div>\n </div>\n <div v-else class=\"empty\">\n <div class=\"title\">{{ __('shop.cart.no_no') }}</div>\n <div class=\"message\">\n {{ __('shop.cart.no_prop') }}\n <a :href=\"$env.locale.url ? $env.locale.url : '/'\">{{ __('shop.cart.no_home') }}</a>, <br />{{ __('shop.cart.no_search') }}\n </div>\n <button class=\"button continue\" @click=\"close\">{{ __('shop.cart.continue') }}</button>\n <div class=\"viewed-wrapper\">\n <viewed :slider=\"true\"></viewed>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n</template>\n\n<script>\nimport { ref, computed, defineComponent, watch } from 'vue';\nimport { useStore } from 'vuex';\nimport { pluralize } from '@perevorot/shop/dist/helpers';\nimport Swiper, { Navigation } from 'swiper';\n\nexport default /*#__PURE__*/ defineComponent({\n name: 'cart',\n props: {\n isModal: {\n type: Boolean,\n default: true\n }\n },\n setup() {\n const store = useStore();\n const loading = ref(false);\n\n const items = computed(() => store.getters['cart/items']);\n const modal = computed(() => store.getters['cart/modal']);\n const total = computed(() => store.getters['cart/total']);\n const quantity = computed(() => store.getters['cart/quantity']);\n\n watch(modal, (value) => {\n if (window.cartToggleCallback) {\n window.cartToggleCallback(value);\n }\n });\n\n const open = () => {\n store.commit('cart/modal', !modal.value);\n };\n\n const close = () => {\n store.commit('cart/modal', false);\n };\n\n const clear = () => {\n loading.value = true;\n\n store.dispatch('cart/clear', {\n finally: () => {\n loading.value = false;\n }\n });\n };\n\n store.dispatch('cart/get', {\n finally: () => { }\n });\n\n window.addEventListener('keyup', (e) => {\n if (modal.value && e.key === 'Escape') {\n close();\n }\n });\n\n const goto = (href) => {\n window.addEventListener('beforeunload', () => {\n store.commit('cart/modal', false);\n });\n\n window.addEventListener('pagehide', () => {\n store.commit('cart/modal', false);\n });\n\n window.location.href = href;\n };\n\n let crossSwiper;\n const crossSlider = ref(null);\n const crossSliderNext = ref(null);\n const crossSliderPrev = ref(null);\n\n const cross = computed(() => {\n const cross = store.getters['cart/cross'];\n\n if (crossSlider.value) {\n if (crossSwiper) {\n crossSwiper.destroy();\n }\n\n if (cross.length) {\n crossSwiper = new Swiper(crossSlider.value, {\n slidesPerView: 1,\n slidesPerGroup: 1,\n breakpoints: {\n 768: {\n slidesPerView: 2,\n slidesPerGroup: 2\n }\n },\n spaceBetween: 0,\n allowTouchMove: true,\n modules: [Navigation],\n mousewheel: {\n forceToAxis: true\n },\n navigation: {\n nextEl: crossSliderNext.value,\n prevEl: crossSliderPrev.value\n }\n });\n }\n }\n\n return cross;\n });\n\n let bundlesSwiper;\n const bundlesSlider = ref(null);\n const bundlesSliderNext = ref(null);\n const bundlesSliderPrev = ref(null);\n\n const bundles = computed(() => {\n const bundles = store.getters['cart/bundles'];\n\n if (bundlesSlider.value) {\n if (bundlesSwiper) {\n bundlesSwiper.destroy();\n }\n\n if (bundles.length) {\n bundlesSwiper = new Swiper(bundlesSlider.value, {\n slidesPerView: 1,\n spaceBetween: 0,\n allowTouchMove: true,\n mousewheel: {\n forceToAxis: true\n },\n navigation: {\n nextEl: bundlesSliderNext.value,\n prevEl: bundlesSliderPrev.value\n }\n });\n }\n }\n\n return bundles;\n });\n\n window.addEventListener('beforeunload', () => {\n store.commit('cart/modal', null);\n });\n\n window.addEventListener('pagehide', () => {\n store.commit('cart/modal', null);\n });\n\n const isLoading = ref(false);\n\n const checkout = () => {\n try {\n isLoading.value = true;\n\n let products = [];\n\n items.value.forEach((item) => {\n products.push({\n name: item.name,\n id: item.attributes.code,\n price: item.attributes.price,\n brand: item.attributes.brand,\n category: item.attributes.category,\n quantity: item.quantity\n });\n });\n\n const object = {\n ecommerce: {\n checkout: {\n products: [products]\n }\n },\n event: 'gtm-ee-event',\n 'gtm-ee-event-category': 'Ecommerce',\n 'gtm-ee-event-action': 'Checkout',\n 'gtm-ee-event-non-interaction': 'False',\n eventCallback: function () {\n window.location.href = $ziggy('shop.checkout');\n },\n eventTimeout: 2000\n };\n\n if (window.dataLayer) {\n window.dataLayer.push({\n ecommerce: null\n });\n\n window.dataLayer.push(object);\n } else {\n window.location.href = $ziggy('shop.checkout');\n }\n\n setTimeout(() => {\n window.location.href = $ziggy('shop.checkout');\n }, 2000);\n } catch (error) {\n console.error(error);\n\n window.location.href = $ziggy('shop.checkout');\n }\n };\n\n return {\n loading,\n items,\n modal,\n total,\n quantity,\n open,\n close,\n clear,\n pluralize,\n goto,\n cross,\n crossSlider,\n crossSliderPrev,\n crossSliderNext,\n bundles,\n bundlesSlider,\n bundlesSliderPrev,\n bundlesSliderNext,\n checkout,\n isLoading,\n };\n }\n});\n</script>"],"names":["defineComponent","name","props","isModal","type","Boolean","setup","store","useStore","loading","ref","items","computed","getters","modal","total","quantity","watch","value","window","cartToggleCallback","close","commit","dispatch","addEventListener","e","key","crossSwiper","bundlesSwiper","crossSlider","crossSliderNext","crossSliderPrev","cross","destroy","length","Swiper","slidesPerView","slidesPerGroup","breakpoints","spaceBetween","allowTouchMove","modules","Navigation","mousewheel","forceToAxis","navigation","nextEl","prevEl","bundlesSlider","bundlesSliderNext","bundlesSliderPrev","bundles","isLoading","open","clear","pluralize","href","location","checkout","products","forEach","item","push","id","attributes","code","price","brand","category","object","ecommerce","event","eventCallback","$ziggy","eventTimeout","dataLayer","setTimeout","error","console","_createElementVNode","role","_createElementBlock","_hoisted_1","_hoisted_2","_hoisted_3","_renderSlot","_ctx","onClick","_hoisted_4","_hoisted_5","_hoisted_6","_hoisted_7","_hoisted_8","_hoisted_9","_hoisted_10","innerHTML","_hoisted_12","_hoisted_13","_hoisted_14","_hoisted_15","_hoisted_16","_hoisted_17","_hoisted_20","_hoisted_21","_toDisplayString","_hoisted_23","_hoisted_24","_createBlock","_hoisted_25","_hoisted_26","_hoisted_27","_hoisted_28","_hoisted_29","_hoisted_31","_hoisted_32","_hoisted_33","_hoisted_34","_hoisted_35","_hoisted_36","_hoisted_37","image","src","_hoisted_43","_hoisted_45","_hoisted_47","_hoisted_48","_hoisted_49","priceOld","_hoisted_52","_createVNode","_hoisted_53","_hoisted_54","_hoisted_57","_hoisted_60","_hoisted_61","_hoisted_62","_hoisted_63","third","_hoisted_64","_hoisted_70","_hoisted_71","_hoisted_72","_hoisted_74","_hoisted_75","_hoisted_77","_hoisted_78","second","_hoisted_84","_hoisted_85","_hoisted_86","_hoisted_88","_hoisted_89","_hoisted_91","_hoisted_94","_hoisted_100","_hoisted_101","_hoisted_102","_hoisted_104","_hoisted_105","_hoisted_107","_hoisted_108","bundle","amount","_hoisted_111","_hoisted_112","_hoisted_114","_hoisted_117","_hois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AAalE,GAAIF,EAAKE,GAAKmF,OAAQrF,EAAKqF,OAAOnF,GAAW0E,MAAO5E,EAAK4E,MAAQ5E,EAAK4E,MAAM1E,iFAOjHkB,2BAAAoF,2BAGApF,2BAAAqF,iEAKRrF,2BAAAsF,IACIxF,2BAAAyF,qBAAsBlF,4BACtBP,2BAAA0F,wCACOnF,kCACHP,qBAAoF,KAAhFvB,KAAM8B,OAAKoF,OAAOC,IAAMrF,OAAKoF,OAAOC,2BAAcrF,oCAAgCsF,uCAAStF,kCAEnGP,qCAAc,kBAAmBQ,sCAAOD,yDAAUA,+BAClDP,2BAAA8F,IACI5C,kBAAS6C,QAAQ"}
1
+ {"version":3,"file":"Cart.js","sources":["../../../../src/components/shop/cart/Cart.vue","../../../../src/components/shop/cart/Cart.vue?vue&type=template&id=92529214&lang.js"],"sourcesContent":["<template>\n <div class=\"cart\">\n <div class=\"dropdown is-right is-hoverable\">\n <div class=\"dropdown-trigger\">\n <slot :total=\"quantity\" :open=\"open\">\n <button class=\"button\" @click=\"open\">\n <span>\n <i class=\"fas fa-shopping-cart\"></i>\n {{ quantity }}\n </span>\n <span class=\"icon is-small\">\n <i class=\"fas fa-angle-down\" aria-hidden=\"true\"></i>\n </span>\n </button>\n </slot>\n </div>\n <div class=\"dropdown-menu\" role=\"menu\">\n <div class=\"dropdown-content\" v-if=\"items.length\">\n <div class=\"dropdown-item\">\n <div class=\"columns\">\n <div class=\"column\">{{ __('shop.cart.total') }}</div>\n <div class=\"column has-text-right\" v-html=\"$filters.price(total)\"></div>\n </div>\n </div>\n <div class=\"dropdown-divider\"></div>\n <div class=\"dropdown-item has-text-centered\">\n <a @click=\"checkout\" class=\"button is-link\" v-bind:class=\"{ 'is-disabled': isLoading }\">{{ __('shop.cart.checkout') }}</a>\n </div>\n <div class=\"dropdown-item has-text-centered\">\n <slot name=\"open\" :open=\"open\">\n <a @click=\"open\">{{ __('shop.cart.open') }}</a>\n </slot>\n </div>\n </div>\n <div class=\"dropdown-content\" v-else>\n <slot name=\"empty\">\n <div class=\"dropdown-item\">{{ __('shop.cart.empty') }}</div>\n </slot>\n </div>\n </div>\n </div>\n <div class=\"modal\" v-if=\"isModal\" v-bind:class=\"{ 'is-active': modal }\">\n <div class=\"modal-background\" @click=\"close\"></div>\n <div class=\"modal-content\">\n <button class=\"modal-close is-large\" @click=\"close\">\n <svg class=\"icon close\">\n <use xlink:href=\"#close\" />\n </svg>\n </button>\n <div class=\"box\">\n <div class=\"cart-title\">\n {{ __('shop.cart.title') }}\n <span v-if=\"quantity\" v-text=\"pluralize(quantity, __('shop.pluralize.products'))\"></span>\n </div>\n <slot name=\"clear\" :clear=\"clear\" :quantity=\"quantity\"></slot>\n <div class=\"items-wrapper\" v-if=\"items.length\">\n <div class=\"items\">\n <cart-item v-for=\"item in items\" v-bind:key=\"item.id\" :item=\"item\"></cart-item>\n </div>\n\n <div class=\"columns is-gapless is-vcentered main-actions\">\n <div class=\"column\">\n <button class=\"button continue\" @click=\"close\">{{ __('shop.cart.continue') }}</button>\n </div>\n <div class=\"column has-text-right\">\n <div class=\"totals\">\n <div class=\"title\">\n {{ __('shop.cart.total') }}\n <span v-html=\"$filters.price(total)\"></span>\n </div>\n </div>\n </div>\n <div class=\"column is-narrow\">\n <a @click=\"checkout\" class=\"button is-link checkout\">{{ __('shop.cart.go_checkout') }}</a>\n </div>\n </div>\n\n <div class=\"cross\" v-if=\"cross.length\">\n <div class=\"title\">{{ __('shop.cart.cross') }}</div>\n <div class=\"swiper\" ref=\"crossSlider\">\n <div class=\"swiper-wrapper\">\n <div class=\"swiper-slide\" v-for=\"item in cross\" v-bind:key=\"item.id\">\n <div class=\"columns is-gapless\">\n <div class=\"column is-narrow\">\n <a @click=\"goto(item.href)\">\n <figure class=\"image is-square\" v-bind:class=\"{ 'no-thumb': !item.image }\">\n <img :src=\"item.image\" v-if=\"item.image\" />\n <svg v-else>\n <use xlink:href=\"#logo\" />\n </svg>\n </figure>\n </a>\n </div>\n <div class=\"column\">\n <div class=\"product\" :data-code=\"item.code\" shop-product>\n <div class=\"name\">\n <a @click=\"goto(item.href)\" shop-product-name>{{ item.name }}</a>\n </div>\n <div class=\"columns is-gapless is-vcentered\">\n <div class=\"column is-narrow\">\n <div class=\"prices\">\n <div class=\"price-old\" v-if=\"item.priceOld\" v-html=\"$filters.price(item.priceOld)\"></div>\n <div class=\"price\" v-html=\"$filters.price(item.price)\" shop-product-price></div>\n </div>\n </div>\n <div class=\"column\">\n <cart-add :id=\"item.id\" :is-simple=\"true\">\n <svg>\n <use xlink:href=\"#cart-alternate\" />\n </svg>\n </cart-add>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n <svg class=\"swiper-nav prev\" ref=\"crossSliderPrev\">\n <use xlink:href=\"#arrow-submenu\" />\n </svg>\n <svg class=\"swiper-nav next\" ref=\"crossSliderNext\">\n <use xlink:href=\"#arrow-submenu\" />\n </svg>\n </div>\n </div>\n <div class=\"bundles\" v-if=\"bundles.length\">\n <div class=\"title\">{{ __('shop.cart.bundle') }}</div>\n <div class=\"swiper\" ref=\"bundlesSlider\">\n <div class=\"swiper-wrapper\">\n <div class=\"swiper-slide\" v-for=\"item in bundles\" v-bind:key=\"item.id\">\n <div class=\"columns is-gapless is-vcentered\" v-bind:class=\"{ 'is-third': item.third }\">\n <div class=\"column is-narrow\">\n <a @click=\"goto(item.href)\">\n <figure class=\"image is-square\" v-bind:class=\"{ 'no-thumb': !item.image }\">\n <img :src=\"item.image\" v-if=\"item.image\" />\n <svg v-else>\n <use xlink:href=\"#logo\" />\n </svg>\n </figure>\n </a>\n </div>\n <div class=\"column\">\n <div class=\"product\">\n <div class=\"name\">\n <a @click=\"goto(item.href)\">{{ item.name }}</a>\n </div>\n <div class=\"columns is-gapless is-vcentered\">\n <div class=\"prices\">\n <div class=\"price\" v-html=\"$filters.price(item.price)\"></div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"column is-narrow\">\n <svg class=\"bundle-icon plus\">\n <use xlink:href=\"#bundle-plus\" />\n </svg>\n </div>\n <div class=\"column is-narrow\">\n <a @click=\"goto(item.second.href)\">\n <figure class=\"image is-square\" v-bind:class=\"{ 'no-thumb': !item.second.image }\">\n <img :src=\"item.second.image\" v-if=\"item.second.image\" />\n <svg v-else>\n <use xlink:href=\"#logo\" />\n </svg>\n </figure>\n </a>\n </div>\n <div class=\"column\">\n <div class=\"product\">\n <div class=\"name\">\n <a @click=\"goto(item.second.href)\">{{ item.second.name }}</a>\n </div>\n <div class=\"columns is-gapless is-vcentered\">\n <div class=\"prices\">\n <div class=\"price\" v-html=\"$filters.price(item.second.price)\"></div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"column is-narrow\" v-if=\"item.third\">\n <svg class=\"bundle-icon plus\">\n <use xlink:href=\"#bundle-plus\" />\n </svg>\n </div>\n <div class=\"column is-narrow\" v-if=\"item.third\">\n <a @click=\"goto(item.third.href)\">\n <figure class=\"image is-square\" v-bind:class=\"{ 'no-thumb': !item.third.image }\">\n <img :src=\"item.third.image\" v-if=\"item.third.image\" />\n <svg v-else>\n <use xlink:href=\"#logo\" />\n </svg>\n </figure>\n </a>\n </div>\n <div class=\"column\" v-if=\"item.third\">\n <div class=\"product\">\n <div class=\"name\">\n <a @click=\"goto(item.third.href)\">{{ item.third.name }}</a>\n </div>\n <div class=\"columns is-gapless is-vcentered\">\n <div class=\"prices\">\n <div class=\"price\" v-html=\"$filters.price(item.third.price)\"></div>\n </div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"columns is-vcentered\">\n <div class=\"column\">\n <span class=\"total-old\" v-html=\"$filters.price(item.bundle.priceOld)\"></span>\n <span class=\"bundle-amount\" v-html=\"__('shop.cart.bundle_amount') + item.bundle.amount\"></span>\n </div>\n <div class=\"column\">\n <div class=\"is-flex is-align-items-center\">\n <span class=\"total\" v-html=\"$filters.price(item.bundle.price)\"></span>\n <bundle-add :id=\"item.id\" :second=\"item.second.id\" v-bind:third=\"item.third ? item.third.id : null\"></bundle-add>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n <svg class=\"swiper-nav prev\" ref=\"bundlesSliderPrev\">\n <use xlink:href=\"#arrow-submenu\" />\n </svg>\n <svg class=\"swiper-nav next\" ref=\"bundlesSliderNext\">\n <use xlink:href=\"#arrow-submenu\" />\n </svg>\n </div>\n </div>\n <div v-else class=\"empty\">\n <div class=\"title\">{{ __('shop.cart.no_no') }}</div>\n <div class=\"message\">\n {{ __('shop.cart.no_prop') }}\n <a :href=\"$env.locale.url ? $env.locale.url : '/'\">{{ __('shop.cart.no_home') }}</a>, <br />{{ __('shop.cart.no_search') }}\n </div>\n <button class=\"button continue\" @click=\"close\">{{ __('shop.cart.continue') }}</button>\n <div class=\"viewed-wrapper\">\n <viewed :slider=\"true\"></viewed>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n</template>\n\n<script>\nimport { ref, computed, defineComponent } from 'vue';\nimport { useStore } from 'vuex';\nimport { pluralize } from '@perevorot/shop/dist/helpers';\nimport Swiper, { Navigation } from 'swiper';\n\nexport default /*#__PURE__*/ defineComponent({\n name: 'cart',\n props: {\n isModal: {\n type: Boolean,\n default: true\n }\n },\n setup() {\n const store = useStore();\n const loading = ref(false);\n\n const items = computed(() => store.getters['cart/items']);\n const modal = computed(() => store.getters['cart/modal']);\n const total = computed(() => store.getters['cart/total']);\n const quantity = computed(() => store.getters['cart/quantity']);\n\n const open = () => {\n store.commit('cart/modal', !modal.value);\n };\n\n const close = () => {\n store.commit('cart/modal', false);\n };\n\n const clear = () => {\n loading.value = true;\n\n store.dispatch('cart/clear', {\n finally: () => {\n loading.value = false;\n }\n });\n };\n\n store.dispatch('cart/get', {\n finally: () => { }\n });\n\n window.addEventListener('keyup', (e) => {\n if (modal.value && e.key === 'Escape') {\n close();\n }\n });\n\n const goto = (href) => {\n window.addEventListener('beforeunload', () => {\n store.commit('cart/modal', false);\n });\n\n window.addEventListener('pagehide', () => {\n store.commit('cart/modal', false);\n });\n\n window.location.href = href;\n };\n\n let crossSwiper;\n const crossSlider = ref(null);\n const crossSliderNext = ref(null);\n const crossSliderPrev = ref(null);\n\n const cross = computed(() => {\n const cross = store.getters['cart/cross'];\n\n if (crossSlider.value) {\n if (crossSwiper) {\n crossSwiper.destroy();\n }\n\n if (cross.length) {\n crossSwiper = new Swiper(crossSlider.value, {\n slidesPerView: 1,\n slidesPerGroup: 1,\n breakpoints: {\n 768: {\n slidesPerView: 2,\n slidesPerGroup: 2\n }\n },\n spaceBetween: 0,\n allowTouchMove: true,\n modules: [Navigation],\n mousewheel: {\n forceToAxis: true\n },\n navigation: {\n nextEl: crossSliderNext.value,\n prevEl: crossSliderPrev.value\n }\n });\n }\n }\n\n return cross;\n });\n\n let bundlesSwiper;\n const bundlesSlider = ref(null);\n const bundlesSliderNext = ref(null);\n const bundlesSliderPrev = ref(null);\n\n const bundles = computed(() => {\n const bundles = store.getters['cart/bundles'];\n\n if (bundlesSlider.value) {\n if (bundlesSwiper) {\n bundlesSwiper.destroy();\n }\n\n if (bundles.length) {\n bundlesSwiper = new Swiper(bundlesSlider.value, {\n slidesPerView: 1,\n spaceBetween: 0,\n allowTouchMove: true,\n mousewheel: {\n forceToAxis: true\n },\n navigation: {\n nextEl: bundlesSliderNext.value,\n prevEl: bundlesSliderPrev.value\n }\n });\n }\n }\n\n return bundles;\n });\n\n window.addEventListener('beforeunload', () => {\n store.commit('cart/modal', null);\n });\n\n window.addEventListener('pagehide', () => {\n store.commit('cart/modal', null);\n });\n\n const isLoading = ref(false);\n\n const checkout = () => {\n try {\n isLoading.value = true;\n\n let products = [];\n\n items.value.forEach((item) => {\n products.push({\n name: item.name,\n id: item.attributes.code,\n price: item.attributes.price,\n brand: item.attributes.brand,\n category: item.attributes.category,\n quantity: item.quantity\n });\n });\n\n const object = {\n ecommerce: {\n checkout: {\n products: [products]\n }\n },\n event: 'gtm-ee-event',\n 'gtm-ee-event-category': 'Ecommerce',\n 'gtm-ee-event-action': 'Checkout',\n 'gtm-ee-event-non-interaction': 'False',\n eventCallback: function () {\n window.location.href = $ziggy('shop.checkout');\n },\n eventTimeout: 2000\n };\n\n if (window.dataLayer) {\n window.dataLayer.push({\n ecommerce: null\n });\n\n window.dataLayer.push(object);\n } else {\n window.location.href = $ziggy('shop.checkout');\n }\n\n setTimeout(() => {\n window.location.href = $ziggy('shop.checkout');\n }, 2000);\n } catch (error) {\n console.error(error);\n\n window.location.href = $ziggy('shop.checkout');\n }\n };\n\n return {\n loading,\n items,\n modal,\n total,\n quantity,\n open,\n close,\n clear,\n pluralize,\n goto,\n cross,\n crossSlider,\n crossSliderPrev,\n crossSliderNext,\n bundles,\n bundlesSlider,\n bundlesSliderPrev,\n bundlesSliderNext,\n checkout,\n isLoading,\n };\n }\n});\n</script>","<template>\n <div class=\"cart\">\n <div class=\"dropdown is-right is-hoverable\">\n <div class=\"dropdown-trigger\">\n <slot :total=\"quantity\" :open=\"open\">\n <button class=\"button\" @click=\"open\">\n <span>\n <i class=\"fas fa-shopping-cart\"></i>\n {{ quantity }}\n </span>\n <span class=\"icon is-small\">\n <i class=\"fas fa-angle-down\" aria-hidden=\"true\"></i>\n </span>\n </button>\n </slot>\n </div>\n <div class=\"dropdown-menu\" role=\"menu\">\n <div class=\"dropdown-content\" v-if=\"items.length\">\n <div class=\"dropdown-item\">\n <div class=\"columns\">\n <div class=\"column\">{{ __('shop.cart.total') }}</div>\n <div class=\"column has-text-right\" v-html=\"$filters.price(total)\"></div>\n </div>\n </div>\n <div class=\"dropdown-divider\"></div>\n <div class=\"dropdown-item has-text-centered\">\n <a @click=\"checkout\" class=\"button is-link\" v-bind:class=\"{ 'is-disabled': isLoading }\">{{ __('shop.cart.checkout') }}</a>\n </div>\n <div class=\"dropdown-item has-text-centered\">\n <slot name=\"open\" :open=\"open\">\n <a @click=\"open\">{{ __('shop.cart.open') }}</a>\n </slot>\n </div>\n </div>\n <div class=\"dropdown-content\" v-else>\n <slot name=\"empty\">\n <div class=\"dropdown-item\">{{ __('shop.cart.empty') }}</div>\n </slot>\n </div>\n </div>\n </div>\n <div class=\"modal\" v-if=\"isModal\" v-bind:class=\"{ 'is-active': modal }\">\n <div class=\"modal-background\" @click=\"close\"></div>\n <div class=\"modal-content\">\n <button class=\"modal-close is-large\" @click=\"close\">\n <svg class=\"icon close\">\n <use xlink:href=\"#close\" />\n </svg>\n </button>\n <div class=\"box\">\n <div class=\"cart-title\">\n {{ __('shop.cart.title') }}\n <span v-if=\"quantity\" v-text=\"pluralize(quantity, __('shop.pluralize.products'))\"></span>\n </div>\n <slot name=\"clear\" :clear=\"clear\" :quantity=\"quantity\"></slot>\n <div class=\"items-wrapper\" v-if=\"items.length\">\n <div class=\"items\">\n <cart-item v-for=\"item in items\" v-bind:key=\"item.id\" :item=\"item\"></cart-item>\n </div>\n\n <div class=\"columns is-gapless is-vcentered main-actions\">\n <div class=\"column\">\n <button class=\"button continue\" @click=\"close\">{{ __('shop.cart.continue') }}</button>\n </div>\n <div class=\"column has-text-right\">\n <div class=\"totals\">\n <div class=\"title\">\n {{ __('shop.cart.total') }}\n <span v-html=\"$filters.price(total)\"></span>\n </div>\n </div>\n </div>\n <div class=\"column is-narrow\">\n <a @click=\"checkout\" class=\"button is-link checkout\">{{ __('shop.cart.go_checkout') }}</a>\n </div>\n </div>\n\n <div class=\"cross\" v-if=\"cross.length\">\n <div class=\"title\">{{ __('shop.cart.cross') }}</div>\n <div class=\"swiper\" ref=\"crossSlider\">\n <div class=\"swiper-wrapper\">\n <div class=\"swiper-slide\" v-for=\"item in cross\" v-bind:key=\"item.id\">\n <div class=\"columns is-gapless\">\n <div class=\"column is-narrow\">\n <a @click=\"goto(item.href)\">\n <figure class=\"image is-square\" v-bind:class=\"{ 'no-thumb': !item.image }\">\n <img :src=\"item.image\" v-if=\"item.image\" />\n <svg v-else>\n <use xlink:href=\"#logo\" />\n </svg>\n </figure>\n </a>\n </div>\n <div class=\"column\">\n <div class=\"product\" :data-code=\"item.code\" shop-product>\n <div class=\"name\">\n <a @click=\"goto(item.href)\" shop-product-name>{{ item.name }}</a>\n </div>\n <div class=\"columns is-gapless is-vcentered\">\n <div class=\"column is-narrow\">\n <div class=\"prices\">\n <div class=\"price-old\" v-if=\"item.priceOld\" v-html=\"$filters.price(item.priceOld)\"></div>\n <div class=\"price\" v-html=\"$filters.price(item.price)\" shop-product-price></div>\n </div>\n </div>\n <div class=\"column\">\n <cart-add :id=\"item.id\" :is-simple=\"true\">\n <svg>\n <use xlink:href=\"#cart-alternate\" />\n </svg>\n </cart-add>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n <svg class=\"swiper-nav prev\" ref=\"crossSliderPrev\">\n <use xlink:href=\"#arrow-submenu\" />\n </svg>\n <svg class=\"swiper-nav next\" ref=\"crossSliderNext\">\n <use xlink:href=\"#arrow-submenu\" />\n </svg>\n </div>\n </div>\n <div class=\"bundles\" v-if=\"bundles.length\">\n <div class=\"title\">{{ __('shop.cart.bundle') }}</div>\n <div class=\"swiper\" ref=\"bundlesSlider\">\n <div class=\"swiper-wrapper\">\n <div class=\"swiper-slide\" v-for=\"item in bundles\" v-bind:key=\"item.id\">\n <div class=\"columns is-gapless is-vcentered\" v-bind:class=\"{ 'is-third': item.third }\">\n <div class=\"column is-narrow\">\n <a @click=\"goto(item.href)\">\n <figure class=\"image is-square\" v-bind:class=\"{ 'no-thumb': !item.image }\">\n <img :src=\"item.image\" v-if=\"item.image\" />\n <svg v-else>\n <use xlink:href=\"#logo\" />\n </svg>\n </figure>\n </a>\n </div>\n <div class=\"column\">\n <div class=\"product\">\n <div class=\"name\">\n <a @click=\"goto(item.href)\">{{ item.name }}</a>\n </div>\n <div class=\"columns is-gapless is-vcentered\">\n <div class=\"prices\">\n <div class=\"price\" v-html=\"$filters.price(item.price)\"></div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"column is-narrow\">\n <svg class=\"bundle-icon plus\">\n <use xlink:href=\"#bundle-plus\" />\n </svg>\n </div>\n <div class=\"column is-narrow\">\n <a @click=\"goto(item.second.href)\">\n <figure class=\"image is-square\" v-bind:class=\"{ 'no-thumb': !item.second.image }\">\n <img :src=\"item.second.image\" v-if=\"item.second.image\" />\n <svg v-else>\n <use xlink:href=\"#logo\" />\n </svg>\n </figure>\n </a>\n </div>\n <div class=\"column\">\n <div class=\"product\">\n <div class=\"name\">\n <a @click=\"goto(item.second.href)\">{{ item.second.name }}</a>\n </div>\n <div class=\"columns is-gapless is-vcentered\">\n <div class=\"prices\">\n <div class=\"price\" v-html=\"$filters.price(item.second.price)\"></div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"column is-narrow\" v-if=\"item.third\">\n <svg class=\"bundle-icon plus\">\n <use xlink:href=\"#bundle-plus\" />\n </svg>\n </div>\n <div class=\"column is-narrow\" v-if=\"item.third\">\n <a @click=\"goto(item.third.href)\">\n <figure class=\"image is-square\" v-bind:class=\"{ 'no-thumb': !item.third.image }\">\n <img :src=\"item.third.image\" v-if=\"item.third.image\" />\n <svg v-else>\n <use xlink:href=\"#logo\" />\n </svg>\n </figure>\n </a>\n </div>\n <div class=\"column\" v-if=\"item.third\">\n <div class=\"product\">\n <div class=\"name\">\n <a @click=\"goto(item.third.href)\">{{ item.third.name }}</a>\n </div>\n <div class=\"columns is-gapless is-vcentered\">\n <div class=\"prices\">\n <div class=\"price\" v-html=\"$filters.price(item.third.price)\"></div>\n </div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"columns is-vcentered\">\n <div class=\"column\">\n <span class=\"total-old\" v-html=\"$filters.price(item.bundle.priceOld)\"></span>\n <span class=\"bundle-amount\" v-html=\"__('shop.cart.bundle_amount') + item.bundle.amount\"></span>\n </div>\n <div class=\"column\">\n <div class=\"is-flex is-align-items-center\">\n <span class=\"total\" v-html=\"$filters.price(item.bundle.price)\"></span>\n <bundle-add :id=\"item.id\" :second=\"item.second.id\" v-bind:third=\"item.third ? item.third.id : null\"></bundle-add>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n <svg class=\"swiper-nav prev\" ref=\"bundlesSliderPrev\">\n <use xlink:href=\"#arrow-submenu\" />\n </svg>\n <svg class=\"swiper-nav next\" ref=\"bundlesSliderNext\">\n <use xlink:href=\"#arrow-submenu\" />\n </svg>\n </div>\n </div>\n <div v-else class=\"empty\">\n <div class=\"title\">{{ __('shop.cart.no_no') }}</div>\n <div class=\"message\">\n {{ __('shop.cart.no_prop') }}\n <a :href=\"$env.locale.url ? $env.locale.url : '/'\">{{ __('shop.cart.no_home') }}</a>, <br />{{ __('shop.cart.no_search') }}\n </div>\n <button class=\"button continue\" @click=\"close\">{{ __('shop.cart.continue') }}</button>\n <div class=\"viewed-wrapper\">\n <viewed :slider=\"true\"></viewed>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n</template>\n\n<script>\nimport { ref, computed, defineComponent } from 'vue';\nimport { useStore } from 'vuex';\nimport { pluralize } from '@perevorot/shop/dist/helpers';\nimport Swiper, { Navigation } from 'swiper';\n\nexport default /*#__PURE__*/ defineComponent({\n name: 'cart',\n props: {\n isModal: {\n type: Boolean,\n default: true\n }\n },\n setup() {\n const store = useStore();\n const loading = ref(false);\n\n const items = computed(() => store.getters['cart/items']);\n const modal = computed(() => store.getters['cart/modal']);\n const total = computed(() => store.getters['cart/total']);\n const quantity = computed(() => store.getters['cart/quantity']);\n\n const open = () => {\n store.commit('cart/modal', !modal.value);\n };\n\n const close = () => {\n store.commit('cart/modal', false);\n };\n\n const clear = () => {\n loading.value = true;\n\n store.dispatch('cart/clear', {\n finally: () => {\n loading.value = false;\n }\n });\n };\n\n store.dispatch('cart/get', {\n finally: () => { }\n });\n\n window.addEventListener('keyup', (e) => {\n if (modal.value && e.key === 'Escape') {\n close();\n }\n });\n\n const goto = (href) => {\n window.addEventListener('beforeunload', () => {\n store.commit('cart/modal', false);\n });\n\n window.addEventListener('pagehide', () => {\n store.commit('cart/modal', false);\n });\n\n window.location.href = href;\n };\n\n let crossSwiper;\n const crossSlider = ref(null);\n const crossSliderNext = ref(null);\n const crossSliderPrev = ref(null);\n\n const cross = computed(() => {\n const cross = store.getters['cart/cross'];\n\n if (crossSlider.value) {\n if (crossSwiper) {\n crossSwiper.destroy();\n }\n\n if (cross.length) {\n crossSwiper = new Swiper(crossSlider.value, {\n slidesPerView: 1,\n slidesPerGroup: 1,\n breakpoints: {\n 768: {\n slidesPerView: 2,\n slidesPerGroup: 2\n }\n },\n spaceBetween: 0,\n allowTouchMove: true,\n modules: [Navigation],\n mousewheel: {\n forceToAxis: true\n },\n navigation: {\n nextEl: crossSliderNext.value,\n prevEl: crossSliderPrev.value\n }\n });\n }\n }\n\n return cross;\n });\n\n let bundlesSwiper;\n const bundlesSlider = ref(null);\n const bundlesSliderNext = ref(null);\n const bundlesSliderPrev = ref(null);\n\n const bundles = computed(() => {\n const bundles = store.getters['cart/bundles'];\n\n if (bundlesSlider.value) {\n if (bundlesSwiper) {\n bundlesSwiper.destroy();\n }\n\n if (bundles.length) {\n bundlesSwiper = new Swiper(bundlesSlider.value, {\n slidesPerView: 1,\n spaceBetween: 0,\n allowTouchMove: true,\n mousewheel: {\n forceToAxis: true\n },\n navigation: {\n nextEl: bundlesSliderNext.value,\n prevEl: bundlesSliderPrev.value\n }\n });\n }\n }\n\n return bundles;\n });\n\n window.addEventListener('beforeunload', () => {\n store.commit('cart/modal', null);\n });\n\n window.addEventListener('pagehide', () => {\n store.commit('cart/modal', null);\n });\n\n const isLoading = ref(false);\n\n const checkout = () => {\n try {\n isLoading.value = true;\n\n let products = [];\n\n items.value.forEach((item) => {\n products.push({\n name: item.name,\n id: item.attributes.code,\n price: item.attributes.price,\n brand: item.attributes.brand,\n category: item.attributes.category,\n quantity: item.quantity\n });\n });\n\n const object = {\n ecommerce: {\n checkout: {\n products: [products]\n }\n },\n event: 'gtm-ee-event',\n 'gtm-ee-event-category': 'Ecommerce',\n 'gtm-ee-event-action': 'Checkout',\n 'gtm-ee-event-non-interaction': 'False',\n eventCallback: function () {\n window.location.href = $ziggy('shop.checkout');\n },\n eventTimeout: 2000\n };\n\n if (window.dataLayer) {\n window.dataLayer.push({\n ecommerce: null\n });\n\n window.dataLayer.push(object);\n } else {\n window.location.href = $ziggy('shop.checkout');\n }\n\n setTimeout(() => {\n window.location.href = $ziggy('shop.checkout');\n }, 2000);\n } catch (error) {\n console.error(error);\n\n window.location.href = $ziggy('shop.checkout');\n }\n };\n\n return {\n loading,\n items,\n modal,\n total,\n quantity,\n open,\n close,\n clear,\n pluralize,\n goto,\n cross,\n crossSlider,\n crossSliderPrev,\n crossSliderNext,\n bundles,\n bundlesSlider,\n bundlesSliderPrev,\n bundlesSliderNext,\n checkout,\n isLoading,\n };\n }\n});\n</script>"],"names":["defineComponent","name","props","isModal","type","Boolean","setup","store","useStore","loading","ref","items","computed","getters","modal","total","quantity","close","commit","dispatch","window","addEventListener","e","value","key","crossSwiper","bundlesSwiper","crossSlider","crossSliderNext","crossSliderPrev","cross","destroy","length","Swiper","slidesPerView","slidesPerGroup","breakpoints","spaceBetween","allowTouchMove","modules","Navigation","mousewheel","forceToAxis","navigation","nextEl","prevEl","bundlesSlider","bundlesSliderNext","bundlesSliderPrev","bundles","isLoading","open","clear","pluralize","href","location","checkout","products","forEach","item","push","id","attributes","code","price","brand","category","object","ecommerce","event","eventCallback","$ziggy","eventTimeout","dataLayer","setTimeout","error","console","_createElementVNode","role","_createElementBlock","_hoisted_1","_hoisted_2","_hoisted_3","_renderSlot","_ctx","onClick","_hoisted_4","_hoisted_5","_hoisted_6","_hoisted_7","_hoisted_8","_hoisted_9","_hoisted_10","innerHTML","_hoisted_12","_hoisted_13","_hoisted_14","_hoisted_15","_hoisted_16","_hoisted_17","_hoisted_20","_hoisted_21","_toDisplayString","_hoisted_23","_hoisted_24","_createBlock","_hoisted_25","_hoisted_26","_hoisted_27","_hoisted_28","_hoisted_29","_hoisted_31","_hoisted_32","_hoisted_33","_hoisted_34","_hoisted_35","_hoisted_36","_hoisted_37","image","src","_hoisted_43","_hoisted_45","_hoisted_47","_hoisted_48","_hoisted_49","priceOld","_hoisted_52","_createVNode","_hoisted_53","_hoisted_54","_hoisted_57","_hoisted_60","_hoisted_61","_hoisted_62","_hoisted_63","third","_hoisted_64","_hoisted_70","_hoisted_71","_hoisted_72","_hoisted_74","_hoisted_75","_hoisted_77","_hoisted_78","second","_hoisted_84","_hoisted_85","_hoisted_86","_hoisted_88","_hoisted_89","_hoisted_91","_hoisted_94","_hoisted_100","_hoisted_101","_hoisted_102","_hoisted_104","_hoisted_105","_hoisted_107","_hoisted_108","bundle","amount","_hoisted_111","_hoisted_112","_hoisted_114","_hoisted_117","_hoisted_120","_hoisted_121","_hoisted_122","locale","url","_hoisted_125","_hoisted_126","slider"],"mappings":"uMA+P6BA,kBAAgB,CACzCC,KAAM,OACNC,MAAO,CACHC,QAAS,CACLC,KAAMC,iBACG,IAGjBC,qBACUC,EAAQC,aACRC,EAAUC,OAAI,GAEdC,EAAQC,YAAS,kBAAML,EAAMM,QAAQ,iBACrCC,EAAQF,YAAS,kBAAML,EAAMM,QAAQ,iBACrCE,EAAQH,YAAS,kBAAML,EAAMM,QAAQ,iBACrCG,EAAWJ,YAAS,kBAAML,EAAMM,QAAQ,oBAMxCI,EAAQ,WACVV,EAAMW,OAAO,cAAc,IAa/BX,EAAMY,SAAS,WAAY,SACd,eAGbC,OAAOC,iBAAiB,SAAS,SAACC,GAC1BR,EAAMS,OAAmB,WAAVD,EAAEE,KACjBP,WAgBJQ,EAwCAC,EAvCEC,EAAcjB,MAAI,MAClBkB,EAAkBlB,MAAI,MACtBmB,EAAkBnB,MAAI,MAEtBoB,EAAQlB,YAAS,eACbkB,EAAQvB,EAAMM,QAAQ,qBAExBc,EAAYJ,QACRE,GACAA,EAAYM,UAGZD,EAAME,SACNP,EAAc,IAAIQ,UAAON,EAAYJ,MAAO,CACxCW,cAAe,EACfC,eAAgB,EAChBC,YAAa,KACJ,CACDF,cAAe,EACfC,eAAgB,IAGxBE,aAAc,EACdC,gBAAgB,EAChBC,QAAS,CAACC,cACVC,WAAY,CACRC,aAAa,GAEjBC,WAAY,CACRC,OAAQhB,EAAgBL,MAC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