cloudcommerce 2.6.4 → 2.7.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.github/workflows/test-apps.yml +2 -2
- package/CHANGELOG.md +30 -0
- package/action.yml +2 -2
- package/{commitlint.config.cjs → commitlint.config.mjs} +2 -2
- package/ecomplus-stores/barradoce/.gitpod.yml +1 -1
- package/ecomplus-stores/barradoce/.idx/dev.nix +5 -4
- package/ecomplus-stores/barradoce/functions/many/package.json +3 -3
- package/ecomplus-stores/barradoce/functions/ssr/content/pages/home.json +106 -8
- package/ecomplus-stores/barradoce/functions/ssr/content/pages/products.json +3 -0
- package/ecomplus-stores/barradoce/functions/ssr/content/types.d.ts +1 -1
- package/ecomplus-stores/barradoce/functions/ssr/package.json +6 -6
- package/ecomplus-stores/barradoce/functions/ssr/src/components/BuyerReviews.vue +83 -0
- package/ecomplus-stores/barradoce/functions/ssr/src/components/CheckoutPage.vue +6 -6
- package/ecomplus-stores/barradoce/functions/ssr/src/components/FooterStamps.vue +4 -4
- package/ecomplus-stores/barradoce/functions/ssr/src/components/ProductDetails.vue +36 -5
- package/ecomplus-stores/barradoce/functions/ssr/src/components/ProductShelf.vue +8 -7
- package/ecomplus-stores/barradoce/functions/ssr/src/components/ShippingCalculator.vue +1 -1
- package/ecomplus-stores/barradoce/functions/ssr/src/main/content/Sections.astro +4 -0
- package/ecomplus-stores/barradoce/functions/with-apps/package.json +3 -3
- package/ecomplus-stores/barradoce/package.json +2 -2
- package/package.json +5 -5
- package/packages/api/package.json +1 -1
- package/packages/apps/affiliate-program/package.json +1 -1
- package/packages/apps/correios/package.json +1 -1
- package/packages/apps/custom-payment/package.json +1 -1
- package/packages/apps/custom-shipping/package.json +1 -1
- package/packages/apps/datafrete/package.json +1 -1
- package/packages/apps/discounts/package.json +1 -1
- package/packages/apps/emails/package.json +1 -1
- package/packages/apps/fb-conversions/package.json +1 -1
- package/packages/apps/flash-courier/package.json +1 -1
- package/packages/apps/frenet/package.json +1 -1
- package/packages/apps/galaxpay/package.json +1 -1
- package/packages/apps/google-analytics/package.json +1 -1
- package/packages/apps/jadlog/package.json +1 -1
- package/packages/apps/loyalty-points/package.json +1 -1
- package/packages/apps/mandae/package.json +1 -1
- package/packages/apps/melhor-envio/package.json +1 -1
- package/packages/apps/mercadopago/package.json +1 -1
- package/packages/apps/pagarme/package.json +1 -1
- package/packages/apps/pagarme-v5/package.json +1 -1
- package/packages/apps/paghiper/package.json +1 -1
- package/packages/apps/pix/package.json +1 -1
- package/packages/apps/tiny-erp/package.json +1 -1
- package/packages/apps/webhooks/package.json +1 -1
- package/packages/cli/package.json +1 -1
- package/packages/config/package.json +1 -1
- package/packages/emails/package.json +2 -2
- package/packages/eslint/package.json +1 -1
- package/packages/events/package.json +1 -1
- package/packages/feeds/package.json +1 -1
- package/packages/firebase/package.json +1 -1
- package/packages/i18n/package.json +1 -1
- package/packages/modules/package.json +1 -1
- package/packages/passport/package.json +1 -1
- package/packages/ssr/lib/lib/cron-ssr-save-views.js +7 -85
- package/packages/ssr/lib/lib/cron-ssr-save-views.js.map +1 -1
- package/packages/ssr/package.json +3 -3
- package/packages/ssr/src/lib/cron-ssr-save-views.ts +7 -91
- package/packages/storefront/dist/client/_astro/{AccountPage.B4WZaOzX.js → AccountPage.Cq0jrJE5.js} +1 -1
- package/packages/storefront/dist/client/_astro/{CartSidebar.DAGdpIcU.js → CartSidebar.DkX2BE1w.js} +1 -1
- package/packages/storefront/dist/client/_astro/{HeroSlider.Dq_9kcdU.js → HeroSlider.CZujn8cU.js} +1 -1
- package/packages/storefront/dist/client/_astro/{PitchBar.BwLlIs6F.js → PitchBar.DhcSEQPV.js} +1 -1
- package/packages/storefront/dist/client/_astro/{Prices.BgHTq5id.js → Prices.D1uItqV5.js} +1 -1
- package/packages/storefront/dist/client/_astro/{ProductDetails.CnYNdPl5.js → ProductDetails.DDNMc2oj.js} +1 -1
- package/packages/storefront/dist/client/_astro/ProductShelf.BwRDTU-V.js +1 -0
- package/packages/storefront/dist/client/_astro/{SearchModal.DcmvABes.js → SearchModal.DgrtGsIu.js} +1 -1
- package/packages/storefront/dist/client/_astro/{SearchShowcase.C9GWwOnF.js → SearchShowcase.DggdcmcI.js} +1 -1
- package/packages/storefront/dist/client/_astro/{ShippingCalculator.DE01D7dt.js → ShippingCalculator.B5JIh5xw.js} +1 -1
- package/packages/storefront/dist/client/_astro/{ShopHeader.Cf4t6O6z.js → ShopHeader.CIsQLhMR.js} +2 -2
- package/packages/storefront/dist/client/_astro/{_plugin-vue_export-helper.CBemkWnU.js → _plugin-vue_export-helper.3R8ooc_r.js} +3 -3
- package/packages/storefront/dist/client/_astro/{_slug_.DX_OkMX7.css → _slug_.CnXAH2gj.css} +1 -1
- package/packages/storefront/dist/client/_astro/client.mwowSQrH.js +1 -0
- package/packages/storefront/dist/client/_astro/{customer-session.CNe1heRH.js → customer-session.BAjMMoBA.js} +1 -1
- package/packages/storefront/dist/client/_astro/{format-money.DINpWB0x.js → format-money.vLicYTv9.js} +1 -1
- package/packages/storefront/dist/client/_astro/{grid-title.D4m7-g3h.js → grid-title.CxNZApGL.js} +1 -1
- package/packages/storefront/dist/client/_astro/{hoisted.EBqhuD5o.js → hoisted.B8Lw6O9a.js} +1 -1
- package/packages/storefront/dist/client/_astro/{hoisted.B2rH1xwX.js → hoisted.D4m7OTKi.js} +1 -1
- package/packages/storefront/dist/client/_astro/{hoisted.ut_nNM_H.js → hoisted.DSAg3dYh.js} +1 -1
- package/packages/storefront/dist/client/_astro/hoisted.D_dlmSy5.js +1 -0
- package/packages/storefront/dist/client/_astro/{i18n.B3skIOFg.js → i18n.BE5r_SIU.js} +1 -1
- package/packages/storefront/dist/client/_astro/{img.D5a6GzeE.js → img.CB-F9VLo.js} +1 -1
- package/packages/storefront/dist/client/_astro/{index.DBfgCyd-.js → index.BAyyMfaO.js} +1 -1
- package/packages/storefront/dist/client/_astro/{index.CFw6O-Kt.js → index.CTTHpJlV.js} +1 -1
- package/packages/storefront/dist/client/_astro/{modules-info.BHKiT6oA.js → modules-info.C6KJuGeB.js} +1 -1
- package/packages/storefront/dist/client/_astro/name.CIPngEFN.js +1 -0
- package/packages/storefront/dist/client/_astro/sf-utils.xmJHVMAX.js +13 -0
- package/packages/storefront/dist/client/_astro/{shopping-cart.D-w8Z-4p.js → shopping-cart.DGvCZWRZ.js} +1 -1
- package/packages/storefront/dist/client/_astro/{use-analytics.CQDdNgwF.js → use-analytics.BWhF_fCv.js} +1 -1
- package/packages/storefront/dist/client/_astro/{use-cms-preview.4Hq7LCmA.js → use-cms-preview.CPGTKut8.js} +1 -1
- package/packages/storefront/dist/client/_astro/{use-product-card.CQRlRsNX.js → use-product-card.C-RbCwna.js} +1 -1
- package/packages/storefront/dist/client/_astro/{use-text-value.UjCYLWjm.js → use-text-value.D4Rw7N4D.js} +1 -1
- package/packages/storefront/dist/server/chunks/{CartSidebar_BmwcZuxv.mjs → CartSidebar_lUckG0fs.mjs} +1 -1
- package/packages/storefront/dist/server/chunks/{SearchModal_BvEnUvAx.mjs → SearchModal_B2f22Mff.mjs} +1 -1
- package/packages/storefront/dist/server/chunks/{_.._DORZHe_Z.mjs → _.._CvgSOb3Z.mjs} +1 -1
- package/packages/storefront/dist/server/chunks/{_page__DU3kNewy.mjs → _page__Ex4FhYrc.mjs} +1 -1
- package/packages/storefront/dist/server/chunks/{account_CaTloREf.mjs → account_B7sLjsXD.mjs} +1 -1
- package/packages/storefront/dist/server/chunks/astro/{assets-service_B77Hm2ue.mjs → assets-service_BOyOfKDQ.mjs} +1 -1
- package/packages/storefront/dist/server/chunks/{astro_ISB6VLqs.mjs → astro_B5LBy7PI.mjs} +8 -4
- package/packages/storefront/dist/server/chunks/{index_BTDpenpc.mjs → index_BOh755yP.mjs} +1 -1
- package/packages/storefront/dist/server/chunks/{index_D0q4ab_n.mjs → index_C2hkTn-w.mjs} +1 -1
- package/packages/storefront/dist/server/chunks/{node_C7sdLKL4.mjs → node_DavlI8UF.mjs} +1 -1
- package/packages/storefront/dist/server/chunks/pages/{__B4CsSrck.mjs → __RXg_hYeF.mjs} +57 -18
- package/packages/storefront/dist/server/chunks/pages/{_page__sb5Idhgp.mjs → _page__Dyte93f2.mjs} +2 -2
- package/packages/storefront/dist/server/chunks/pages/{account_iWjHfkwu.mjs → account_C66y6_Y9.mjs} +2 -2
- package/packages/storefront/dist/server/chunks/pages/{index_BZlpKBRL.mjs → index_EO1hhrt8.mjs} +2 -2
- package/packages/storefront/dist/server/chunks/pages/{node_GFu-CQ19.mjs → node_hc25rqYt.mjs} +3 -3
- package/packages/storefront/dist/server/chunks/pages/{~fallback_C07rzeay.mjs → ~fallback_-K3esUV3.mjs} +2 -2
- package/packages/storefront/dist/server/chunks/{~fallback_YpJa9BIL.mjs → ~fallback_DQ6yB81s.mjs} +1 -1
- package/packages/storefront/dist/server/entry.mjs +625 -601
- package/packages/storefront/dist/server/{manifest_KFjAaJaC.mjs → manifest_bZVxjk3o.mjs} +3 -3
- package/packages/storefront/dist/server/renderers.mjs +1 -1
- package/packages/storefront/package.json +3 -3
- package/packages/storefront/src/lib/components/Carousel.vue +6 -0
- package/packages/storefront/src/lib/composables/use-product-shelf.ts +23 -4
- package/packages/storefront/src/lib/layouts/use-page-main.ts +6 -7
- package/packages/test-base/package.json +1 -1
- package/packages/types/package.json +1 -1
- package/packages/storefront/dist/client/_astro/ProductShelf.kfADQTUO.js +0 -1
- package/packages/storefront/dist/client/_astro/client.CdXC84C5.js +0 -1
- package/packages/storefront/dist/client/_astro/hoisted.DBPXHTEb.js +0 -1
- package/packages/storefront/dist/client/_astro/name.BZA9xqh-.js +0 -1
- package/packages/storefront/dist/client/_astro/sf-utils.Cigv01cN.js +0 -13
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{_ as k,T as oe,w as se,c as ie,d as le}from"./_plugin-vue_export-helper.3R8ooc_r.js";import{d as C,c,o as f,$ as A,h as W,Z as b,a2 as ee,e as g,a4 as te,a5 as re,f as Y,n as p,l as F,F as ue,k as ce,ab as de,ag as fe,a as E,w as z,a8 as D,T as me,Q as ve,al as pe,ad as he,z as $,am as ge}from"./sf-utils.xmJHVMAX.js";import{i as ye}from"./img.CB-F9VLo.js";import{e as _e}from"./index.CTTHpJlV.js";import{i as we}from"./img-sizes.rFK7so02.js";import{i as xe}from"./i18n.BE5r_SIU.js";import{f as Se}from"./format-money.vLicYTv9.js";import{a as be,b as Ce}from"./index.BAyyMfaO.js";import"./price.CHiL6Z1J.js";const Pe=C({__name:"Fade",props:{speed:{default:"default"},slide:{},isFloating:{type:Boolean,default:!1},isLeaveTo:{type:Boolean,default:!0},isEnterFrom:{type:Boolean,default:!0}},setup(r,{expose:a}){a();const e=r,t=c(()=>e.speed==="default"?"var(--transition, .2s linear)":`var(--transition-${e.speed}, .4s linear)`),l=c(()=>{switch(e.slide){case"down":return"translate3d(0, -100%, 0)";case"left":return"translate3d(-100%, 0, 0)";case"right":return"translate3d(100%, 0, 0)";case"up":return"translate3d(0, 100%, 0)";default:return"none"}}),i=c(()=>l.value!=="none"?.1:0),s=c(()=>e.isEnterFrom?i.value:1),y=c(()=>e.isLeaveTo?i.value:1),P=c(()=>e.isEnterFrom?l.value:"none"),m=c(()=>e.isLeaveTo?l.value:"none"),u=c(()=>e.slide==="down"||e.slide==="up"),w=c(()=>e.isFloating?null:u.value?0:"auto"),T=c(()=>e.isFloating?null:e.slide&&!u.value?0:"auto"),v=c(()=>e.isEnterFrom?w.value:"auto"),S=c(()=>e.isEnterFrom?T.value:"auto"),x=c(()=>{let n="opacity";return l.value!=="none"&&(n+=", transform"),w.value===0&&(n+=", height"),T.value===0&&(n+=", width"),n}),h={props:e,duration:t,transform:l,opacity:i,enterFromOpacity:s,leaveToOpacity:y,enterFromTransform:P,leaveToTransform:m,isSlideY:u,height:w,width:T,enterFromHeight:v,enterFromWidth:S,willChange:x,setInitialStyles:n=>{n.style.setProperty("--fade-will-change",x.value),n.style.setProperty("--fade-duration",t.value),n.style.setProperty("--fade-enter-opacity",String(s.value)),n.style.setProperty("--fade-enter-transform",String(P.value)),n.style.setProperty("--fade-enter-height",String(v.value)),n.style.setProperty("--fade-enter-width",String(S.value)),n.style.setProperty("--fade-leave-opacity",String(y.value)),n.style.setProperty("--fade-leave-transform",String(m.value))},onEnter:n=>{if(e.slide&&!e.isFloating&&e.isEnterFrom){u.value?(n.style.width=getComputedStyle(n).width,n.style.height="auto"):(n.style.width="auto",n.style.height=getComputedStyle(n).height),n.style.position="absolute",n.style.visibility="hidden";const{width:_,height:I}=getComputedStyle(n);n.style.width=u.value?"":"0",n.style.height=u.value?"0":"",n.style.position="",n.style.visibility="",getComputedStyle(n)[u.value?"height":"width"],requestAnimationFrame(()=>{u.value?n.style.height=I:n.style.width=_})}},onAfterEnter:n=>{e.slide&&!e.isFloating&&e.isEnterFrom&&(n.style[u.value?"height":"width"]="")},onLeave:n=>{if(e.slide&&!e.isFloating&&e.isLeaveTo){u.value?n.style.height=getComputedStyle(n).height:n.style.width=getComputedStyle(n).width;const _=u.value?"height":"width";getComputedStyle(n)[_],requestAnimationFrame(()=>{n.style[_]="0"})}}};return Object.defineProperty(h,"__isScriptSetup",{enumerable:!1,value:!0}),h}});function Te(r,a,e,t,l,i){return f(),A(oe,{name:"sf-fade",onBeforeEnter:t.setInitialStyles,onEnter:t.onEnter,onBeforeLeave:t.setInitialStyles,onAfterEnter:t.onAfterEnter,onLeave:t.onLeave},{default:W(()=>[b(r.$slots,"default")]),_:3},8,["onBeforeEnter","onEnter","onBeforeLeave","onAfterEnter","onLeave"])}const Le=k(Pe,[["render",Te]]),Ee=C({__name:"ALink",props:{href:{},target:{}},setup(r,{expose:a}){a();const e=r,t=c(()=>{if(e.href){if(e.target)return e.target;if(e.href.startsWith("http")){const i=globalThis.$storefront.settings.domain||window.location.host;return e.href.startsWith(`https://${i}`)?void 0:"_blank"}}}),l={props:e,linkTarget:t};return Object.defineProperty(l,"__isScriptSetup",{enumerable:!1,value:!0}),l}});function Fe(r,a,e,t,l,i){return f(),A(ee(e.href?"a":"span"),{href:e.href,target:t.linkTarget,rel:t.linkTarget==="_blank"?"noopener":void 0},{default:W(()=>[b(r.$slots,"default")]),_:3},8,["href","target","rel"])}const ke=k(Ee,[["render",Fe]]),Be=C({__name:"AImg",props:{picture:{},loading:{default:"lazy"},decoding:{},alt:{},preferredSize:{}},setup(r,{expose:a}){a();const e=r,t=c(()=>e.picture.url?e.picture:ye(e.picture,void 0,e.preferredSize)||{}),l=c(()=>we(t.value)),i=c(()=>({src:t.value.url,alt:t.value.alt||e.alt,width:l.value.width||void 0,height:l.value.height||void 0,loading:e.loading,decoding:e.decoding||(l.value.height?"async":void 0)})),s={props:e,image:t,dimensions:l,attrs:i};return Object.defineProperty(s,"__isScriptSetup",{enumerable:!1,value:!0}),s}});function ze(r,a,e,t,l,i){return f(),g("img",te(re(t.attrs)),null,16)}const Ae=k(Be,[["render",ze]]),Q="bg-base-200 rounded-md",We=C({__name:"Skeleton",props:{isBold:{type:Boolean},isLarge:{type:Boolean},numRows:{default:6}},setup(r,{expose:a}){a();const e=r,t=c(()=>`${Q} ${e.isBold?"h-8 mb-6":"h-2.5 mb-4"}`),l=c(()=>`${Q} ${e.isBold?"h-5 mb-4":"h-2 mb-2.5"}`),i={props:e,rowClassName:Q,firstRowClassName:t,nextRowsClassName:l};return Object.defineProperty(i,"__isScriptSetup",{enumerable:!1,value:!0}),i}}),Re=Y("span",{class:"sr-only"},"Loading...",-1);function Ie(r,a,e,t,l,i){return f(),g("div",{role:"status",class:p(["animate-pulse",e.isLarge?"max-w-4xl":"max-w-sm"])},[Y("div",{class:p([t.firstRowClassName,e.isLarge?"w-96":"w-48"])},null,2),e.numRows>1?(f(),g("div",{key:0,class:p([t.nextRowsClassName,e.isLarge?"max-w-[680px]":"max-w-[340px]"])},null,2)):F("",!0),e.numRows>2?(f(),g("div",{key:1,class:p(t.nextRowsClassName)},null,2)):F("",!0),e.numRows>3?(f(),g("div",{key:2,class:p([t.nextRowsClassName,e.isLarge?"max-w-[660px]":"max-w-[330px]"])},null,2)):F("",!0),e.numRows>4?(f(),g("div",{key:3,class:p([t.nextRowsClassName,e.isLarge?"max-w-[600px]":"max-w-[300px]"])},null,2)):F("",!0),(f(!0),g(ue,null,ce(e.numRows-5,s=>(f(),g("div",{key:s,class:p([t.nextRowsClassName,e.isLarge?"max-w-[720px]":"max-w-[360px]"])},null,2))),128)),Re],2)}const Ne=k(We,[["render",Ie]]),He=(r,a=1)=>Number.isInteger(r)?`${r}%`:`${r.toFixed(a)}%`,Oe=r=>{r.use({install:(a,e)=>{a.config.globalProperties.$t=(i,s)=>xe(i,s||e?.lang),a.config.globalProperties.$money=Se,a.config.globalProperties.$percentage=He;const{settings:t,apiContext:l}=globalThis.$storefront||{};a.config.globalProperties.$settings=t,a.config.globalProperties.$apiContext=l,a.config.globalProperties.$useId=de}}),r.component("Fade",Le),r.component("ALink",ke),r.component("AImg",Ae),r.component("Skeleton",Ne)},$e=C({__name:"CarouselControl",props:{isPrev:{type:Boolean,default:!1}},setup(r,{expose:a}){a();const{axis:e,changeSlide:t}=fe(U),i={axis:e,changeSlide:t,isX:e==="x"};return Object.defineProperty(i,"__isScriptSetup",{enumerable:!1,value:!0}),i}}),je=["aria-label","data-carousel-control"];function Xe(r,a,e,t,l,i){return f(),g("button",{type:"button","aria-label":e.isPrev?"Anterior":"Próximo",onClick:a[0]||(a[0]=se(s=>t.changeSlide(e.isPrev?-1:1),["stop","prevent"])),class:p(["group absolute z-[11]",t.isX?`${e.isPrev?"left-0":"right-0"} top-0`:`${e.isPrev?"top-0":"bottom-0"} left-0`]),"data-carousel-control":e.isPrev?"previous":"next"},[b(r.$slots,"default",{},()=>[Y("i",{class:p(["m-0 i-chevron-right",{"group-active:translate-x-1":t.isX&&!e.isPrev,"rotate-180 group-active:-translate-x-1":t.isX&&e.isPrev,"rotate-90 group-active:translate-y-1":!t.isX&&!e.isPrev,"-rotate-90 group-active:-translate-y-1":!t.isX&&e.isPrev}])},null,2)])],10,je)}const ne=k($e,[["render",Xe]]),U=Symbol("carousel"),Me=C({__name:"Carousel",props:{as:{default:"ul"},index:{default:0},autoplay:{},axis:{default:"x"},hasControls:{type:Boolean},wrapperKey:{}},emits:["update:index"],setup(r,{expose:a,emit:e}){a();const t=r,l=e,i=E(0);z(D(t,"index"),o=>{if(o!==i.value){const d=o-i.value;_(d,!1)}},{immediate:!0}),z(i,(o,d)=>{o!==d&&l("update:index",o)});const s=E(null),{[t.axis]:y,isScrolling:P,arrivedState:m}=be(s),u=t.axis==="x",w=c(()=>u?m.left:m.top),T=c(()=>u?m.right:m.bottom),v=E([]),S=E(0),x=E(0),j=()=>{s.value&&(u?(S.value=s.value.scrollWidth,x.value=s.value.offsetWidth):(S.value=s.value.scrollHeight,x.value=s.value.offsetHeight))},X=()=>{if(!s.value)return;let o=[...s.value.children];o.length===1&&o[0].tagName.endsWith("SLOT")&&(o=[...o[0].children]),v.value=o.map(d=>({offset:u?d.offsetLeft:d.offsetTop,size:u?d.offsetWidth:d.offsetHeight}))},M=o=>{let d=i.value+o;if(d>=v.value.length)return 0;d<0&&(d=v.value.length+d);const{offset:B,size:L}=v.value[d]||{};return L?B:0},R=()=>{const o=v.value.findIndex(d=>Math.abs(d.offset-y.value)<=5);o>-1&&(i.value=o||0)};let h;const n=()=>{t.autoplay&&(clearTimeout(h),h=setTimeout(()=>{_(1)},t.autoplay))},_=(o,d=!0)=>{if(v.value.length<2)return;let B=-1;if(y.value+x.value>=S.value)B=0;else{if(d&&(o===1||o===-1)){let L=0,J=0;for(let V=i.value;V<v.value.length;V++){const{size:q}=v.value[V]||{};if(q&&(L+=1,J+=q,J+q*.75>=x.value))break}L&&(o=o>0?L:-L)}B=M(o)}s.value?.scrollTo({[u?"left":"top"]:B,behavior:"smooth"}),n()};z(P,o=>{o?clearTimeout(h):(R(),n())});const I=E(null),Z=Ce(I);z(Z,o=>{o?clearTimeout(h):n()});let N=0,H=0;const O=()=>{s.value&&(N=s.value.clientWidth,H=s.value.clientHeight,j(),X(),R())},K=_e(()=>{if(!s.value)return;const{clientWidth:o,clientHeight:d}=s.value;o===N&&d===H||(u?s.value.scrollLeft=0:s.value.scrollTop=0,O())},400);me(()=>{O(),ve(()=>{s.value&&[...s.value.children].forEach(o=>{o.setAttribute("tabindex","0")})}),n(),window.addEventListener("resize",K)}),z(D(t,"wrapperKey"),O),pe(()=>{window.removeEventListener("resize",K),clearTimeout(h)}),he(U,{autoplay:D(t,"autoplay"),axis:t.axis,changeSlide:_,isBoundStart:w,isBoundEnd:T});const G={carouselKey:U,props:t,emit:l,activeIndex:i,wrapper:s,currentPos:y,isScrolling:P,arrivedState:m,isX:u,isBoundStart:w,isBoundEnd:T,slideSizes:v,wrapperScrollSize:S,wrapperVisibleSize:x,calcWrapperSize:j,calcSlidesSize:X,calcNextOffset:M,calcCurrentIndex:R,get autoplayTimer(){return h},set autoplayTimer(o){h=o},restartAutoplay:n,changeSlide:_,carousel:I,isHovered:Z,get initWrapperWidth(){return N},set initWrapperWidth(o){N=o},get initWrapperHeight(){return H},set initWrapperHeight(o){H=o},calcOnInit:O,onResize:K,CarouselControl:ne};return Object.defineProperty(G,"__isScriptSetup",{enumerable:!1,value:!0}),G}});function Ke(r,a,e,t,l,i){return f(),g("div",{ref:"carousel",class:p(`relative ${t.isX?"":"overflow-hidden"}`),"data-carousel":""},[(f(),A(ee(e.as),{ref:"wrapper",class:p(["m-0 flex snap-mandatory list-none scroll-smooth p-0 [&>*]:snap-start [&>*]:outline-none",t.isX?"snap-x overflow-y-hidden overflow-x-scroll":"h-full flex-col snap-y overflow-x-hidden overflow-y-scroll"]),style:{"scrollbar-width":"none","-webkit-overflow-scrolling":"touch","-ms-overflow-style":"none"},"data-carousel-wrapper":""},{default:W(()=>[b(r.$slots,"default")]),_:3},8,["class"])),b(r.$slots,"controls",te(re({changeSlide:t.changeSlide,isBoundStart:t.isBoundStart,isBoundEnd:t.isBoundEnd,activeIndex:t.activeIndex})),()=>[t.slideSizes.length>1||e.hasControls?(f(),A(t.CarouselControl,{key:0,"is-prev":""},{default:W(()=>[b(r.$slots,"previous")]),_:3})):F("",!0),t.slideSizes.length>1||e.hasControls?(f(),A(t.CarouselControl,{key:1},{default:W(()=>[b(r.$slots,"next")]),_:3})):F("",!0)])],2)}const Ve=k(Me,[["render",Ke]]),ae=r=>{Oe(r),r.component("Carousel",Ve),r.component("CarouselControl",ne)},qe=Object.freeze(Object.defineProperty({__proto__:null,default:ae},Symbol.toStringTag,{value:"Module"})),De=async r=>{"default"in qe&&await ae(r)},Qe=C({props:{value:String,name:String,hydrate:{type:Boolean,default:!0}},setup({name:r,value:a,hydrate:e}){if(!a)return()=>null;let t=e?"astro-slot":"astro-static-slot";return()=>$(t,{name:r,innerHTML:a})}}),ot=r=>async(a,e,t,{client:l})=>{if(!r.hasAttribute("ssr"))return;const i=a.name?`${a.name} Host`:void 0,s={};for(const[u,w]of Object.entries(t))s[u]=()=>$(Qe,{value:w,name:u==="default"?void 0:u});const y=l!=="only",m=(y?ie:le)({name:i,render(){let u=$(a,e,s);return Ue(a.setup)&&(u=$(ge,null,u)),u}});await De(m),m.mount(r,y),r.addEventListener("astro:unmount",()=>m.unmount(),{once:!0})};function Ue(r){const a=r?.constructor;return a&&a.name==="AsyncFunction"}export{ot as default};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import"./server-data.CUHTES8a.js";import{r as C,c as y,b as U}from"./sf-utils.
|
|
1
|
+
import"./server-data.CUHTES8a.js";import{r as C,c as y,b as U}from"./sf-utils.xmJHVMAX.js";import{h as x}from"./index.CTTHpJlV.js";const K=e=>{if(e){if(e.display_name)return e.display_name;if(e.name&&e.name.given_name)return e.name.given_name}return""},z="modulepreload",G=function(e){return"/"+e},I={},J=function(a,t,i){let r=Promise.resolve();if(t&&t.length>0){const n=document.getElementsByTagName("link");r=Promise.all(t.map(s=>{if(s=G(s),s in I)return;I[s]=!0;const o=s.endsWith(".css"),c=o?'[rel="stylesheet"]':"";if(!!i)for(let p=n.length-1;p>=0;p--){const g=n[p];if(g.href===s&&(!o||g.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${s}"]${c}`))return;const u=document.createElement("link");if(u.rel=o?"stylesheet":z,o||(u.as="script",u.crossOrigin=""),u.href=s,document.head.appendChild(u),o)return new Promise((p,g)=>{u.addEventListener("load",p),u.addEventListener("error",()=>g(new Error(`Unable to preload CSS for ${s}`)))})}))}return r.then(()=>a()).catch(n=>{const s=new Event("vite:preloadError",{cancelable:!0});if(s.payload=n,window.dispatchEvent(s),!s.defaultPrevented)throw n})},V=(e,a,t=globalThis.localStorage,i=!0)=>{if(!t)return C(a);const r=()=>{const c=t.getItem(e);if(c)try{return JSON.parse(c)}catch{return t.removeItem(e),null}},n=r(),s=C(n||a);let o;return i&&globalThis.BroadcastChannel&&(o=new BroadcastChannel(e),o.onmessage=c=>{c.data==="set"&&Object.assign(s,r())}),x(s,()=>{t.setItem(e,JSON.stringify(s)),o&&o.postMessage("set")},{debounce:50}),s};globalThis.__apiCache||(globalThis.__apiCache={});const b=typeof process=="object"&&process?.env||globalThis;class S extends Error{constructor(a,t,i,r=!1){t?(super(t.statusText),this.data=t.data,this.statusCode=t.status):super(i||"Request error"),this.config=a,this.response=t,this.isTimeout=r}}const F={middleware(e){const a={...e.headers};if(!e.isNoAuth)if(e.accessToken)a.Authorization=`Bearer ${e.accessToken}`;else{const n=e.authenticationId||b.ECOM_AUTHENTICATION_ID,s=e.apiKey||b.ECOM_API_KEY;if(n&&s){const o=`${n}:${s}`,c=typeof Buffer=="function"?Buffer.from(o).toString("base64"):btoa(o);a.Authorization=`Basic ${c}`}}let t=e.baseUrl||b.API_BASE_URL||"https://ecomplus.io/v2";const{endpoint:i,params:r}=e;if(i!=="login"&&i!=="authenticate"&&i!=="ask-auth-callback"&&i!=="check-username"){const n=e.storeId||b.ECOM_STORE_ID;if(!n)throw new Error("`storeId` must be set in config or `ECOM_STORE_ID` env var");t+=`/:${n}`;const s=e.lang||b.ECOM_LANG;s&&(t+=`,lang:${s}`)}if(t+=`/${i}`,typeof r=="string")t+=`?${r}`;else{const n=r||{};if(["fields","sort"].forEach(s=>{const o=e[s];o&&!n[s]&&(n[s]=o.join(","))}),["limit","offset","count","buckets","concise","verbose"].forEach(s=>{const o=e[s];o&&!n[s]&&(n[s]=o)}),Object.keys(n).length){const s=new URLSearchParams;Object.keys(n).forEach(o=>{const c=n[o];Array.isArray(c)?c.forEach(_=>{s.append(o,_)}):c!==void 0&&s.append(o,c)}),t+=`?${s.toString()}`}}return{url:t,headers:a}}},l=async(e,a=0)=>{const t=globalThis.$apiMergeConfig?{...globalThis.$apiMergeConfig,...e}:e,{url:i,headers:r}=F.middleware(t),n=t.method?.toUpperCase()||"GET",{timeout:s=2e4,maxRetries:o=3,cacheMaxAge:c=Number(b.API_CACHE_MAX_AGE)||12e4}=t,_=n==="GET"&&t.canCache;let u;if(_){u=`${i}${JSON.stringify(r)}`;const f=globalThis.__apiCache[u];if(f&&Date.now()-f.timestamp<=c)return{...f.res,config:t}}const p=t.body||t.data;let g;p&&(g=JSON.stringify(p),r["Content-Type"]="application/json");const T=new AbortController;let A=!1;const M=setTimeout(()=>{T.abort(),A=!0},s);let h;try{h=await(t.fetch||fetch)(i,{method:n,headers:r,body:g,signal:T.signal})}catch(f){let d=f.message;throw f.cause&&(d+=` - ${f.cause}`),new S(t,h,d,A)}if(clearTimeout(M),h){if(h.ok){const d=h;return d.data=h.status!==204?await h.json():null,_&&u&&(globalThis.__apiCache[u]={timestamp:Date.now(),res:d}),d.config=t,d}const{status:f}=h;if(o<a&&(f===429||f>=500)){const d=h.headers.get("retry-after");return new Promise((D,L)=>{setTimeout(()=>{l(e,a+1).then(D).catch(L)},d&&parseInt(d,10)*1e3||5e3)})}}try{h.data=await h?.json()}catch{}throw new S(t,h)},H=(e,a)=>l({...a,endpoint:e}),Y=(e,a,t)=>l({...t,method:"post",endpoint:e,body:a}),q=(e,a,t)=>l({...t,method:"put",endpoint:e,body:a}),X=(e,a,t)=>l({...t,method:"patch",endpoint:e,body:a}),N=(e,a)=>l({...a,method:"delete",endpoint:e});l.get=H;l.post=Y;l.put=q;l.patch=X;l.del=N;l.delete=N;const Q="emailForSignIn",P="ecomSession",E={customer:{display_name:"",main_email:""},auth:null},m=V(P,E),v=y(()=>{const{auth:e}=m;return e&&new Date(e.expires).getTime()-Date.now()>1e3*10}),R=y(()=>m.customer),O=y(()=>K(R.value)),$=y({get(){return R.value.main_email},set(e){m.customer.main_email=e}});let w;const oe=y(()=>v.value||!!w?.currentUser?.emailVerified),W=()=>{m.auth=E.auth,m.customer=E.customer,localStorage.removeItem(P),w.signOut()},j=(e="Not authenticated")=>{const a=new Error(e);throw a.isNoAuth=!0,a},B=async()=>{const e=await w.currentUser?.getIdToken();if(!e){j("Can't get Firebase user ID token");return}const{domain:a}=globalThis.$storefront.settings;try{const t=await fetch(`https://${a}/_api/passport/token`,{method:"POST",headers:{"Content-Type":"application/json",Authorization:`Bearer ${e}`}});m.auth=await t.json()}catch(t){console.error(t)}},Z=async()=>(v.value||await B(),m.auth?m.auth.access_token:j()),ee=async()=>{const e=await Z(),a=m.auth,{data:t}=await l.get(`customers/${a.customer_id}`,{accessToken:e});return m.customer=t,t};let k=!1;const ne=e=>{if(k)return;e===void 0&&(e=!window.location.pathname.startsWith("/app/")),k=!0;const a=()=>J(()=>import("./firebase-app.CBckq0Sj.js"),__vite__mapDeps([0,1])).then(({getAuth:t,onAuthStateChanged:i,isSignInWithEmailLink:r,signInWithEmailLink:n})=>{if(w=t(),i(w,async s=>{if(s){if(s.displayName&&!O.value&&(m.customer.display_name=s.displayName),s.email&&(!$.value||s.emailVerified)&&(m.customer.main_email=s.email),s.emailVerified){const o=s.email!==$.value;(o||!v.value)&&(await B(),(o||!O.value)&&await ee())}}else W()}),r(w,window.location.href)){const o=new URLSearchParams(window.location.search).get("email");o&&n(w,o,window.location.href).then(()=>window.localStorage.removeItem(Q)).catch(console.error)}}).catch(console.error);e?U(a):a()};export{Q as E,J as _,O as a,l as b,R as c,oe as d,ne as e,$ as f,v as i,W as l,m as s,V as u};
|
|
2
2
|
function __vite__mapDeps(indexes) {
|
|
3
3
|
if (!__vite__mapDeps.viteFileDeps) {
|
|
4
4
|
__vite__mapDeps.viteFileDeps = ["_astro/firebase-app.CBckq0Sj.js","_astro/index-bea2a320.CHELEM8n.js"]
|
package/packages/storefront/dist/client/_astro/{format-money.DINpWB0x.js → format-money.vLicYTv9.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{_ as t}from"./sf-utils.
|
|
1
|
+
import{_ as t}from"./sf-utils.xmJHVMAX.js";import{p as c}from"./price.CHiL6Z1J.js";const s=(r,o=t.get("currency"),e=t.get("lang"))=>{if(typeof r=="object"?r!==null&&(r=c(r)):typeof r=="string"&&(r=parseFloat(r)),o)try{return r.toLocaleString(e.replace("_","-"),{style:"currency",currency:o})}catch(f){console.error(f)}const n=(o||t.get("currency_symbol"))+" ";return typeof r=="number"?n+r:""},y=s;export{y as f};
|
package/packages/storefront/dist/client/_astro/{grid-title.D4m7-g3h.js → grid-title.CxNZApGL.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{_ as a}from"./sf-utils.
|
|
1
|
+
import{_ as a}from"./sf-utils.xmJHVMAX.js";import{n as g}from"./name.CIPngEFN.js";const l=(e,t,i=a.get("lang"))=>{let r;return Array.isArray(t)?r=t.find(o=>o.grid_id===e):console.error("`grids` must be array to get grid title"),r?g(r,i):e};export{l as g};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{i as E,s as b,c as p,a as N}from"./customer-session.
|
|
1
|
+
import{i as E,s as b,c as p,a as N}from"./customer-session.BAjMMoBA.js";import{s as w}from"./shopping-cart.DGvCZWRZ.js";import{g as v,e as I}from"./use-analytics.BWhF_fCv.js";import{u as O}from"./afetch.DPLba2tr.js";import"./index.CTTHpJlV.js";import{w as T}from"./sf-utils.xmJHVMAX.js";import"./hoisted.DSAg3dYh.js";import"./server-data.CUHTES8a.js";import"./price.CHiL6Z1J.js";import"./name.CIPngEFN.js";import"./i18n.BE5r_SIU.js";const R=o=>{let a="";if(typeof o=="object"&&o!==null){let i=Array.isArray(o.phones)?o.phones[0]:o;i&&i.number&&(i.country_code&&(a=`+${i.country_code} `),a+=i.number)}return a},k=()=>{const o=window.storefrontApp?.router;if(o){const a=()=>sessionStorage.getItem("st_discount_coupon")||void 0,i=s=>Math.round(s*100)/100,h=[],r=(s,t)=>{h.includes(s)||(h.push(s),t||(t={value:i(w.subtotal||0),items:w.items.map(v)}),s!=="view_cart"&&(t.coupon=a(),h.includes("begin_checkout")||r("begin_checkout")),I(s,t))};let g=!1;const m=(s,t)=>{if(!g){if(localStorage.getItem("gtag.orderIdSent")!==s){let _;if(t)try{_=JSON.parse(t)}catch{}const{amount:l}=_||window.storefrontApp,S={transaction_id:s,value:i(l?.total||w.subtotal||0),items:w.items.map(v),coupon:_?_.extra_discount?.discount_coupon:a()};l&&(l.freight!==void 0&&(S.shipping=i(l.freight)),l.tax!==void 0&&(S.tax=i(l.tax)));let A=1;const{dataLayer:y,__sendGTMExtraPurchaseData:P}=window;if(y&&P){const n={};let e;if(p){n.customerDisplayName=N.value;let c=p.value.name;if(!c?.given_name)try{const f=sessionStorage.getItem("ecomCustomerAccount");if(f){const C=JSON.parse(f);typeof C=="object"&&C&&(c=C.name)}}catch{}c&&(n.customerGivenName=c.given_name,n.customerFamilyName=c.family_name),n.customerEmail=p.value.main_email,n.customerPhone=R(p.value),e=p.value.addresses?.[0]}try{const c=sessionStorage.getItem("ecomCustomerAddress");if(c){const f=JSON.parse(c);typeof e=="object"&&e?Object.assign(e,f):e=f}}catch{}e&&e.zip&&(n.shippingAddrZip=e.zip,n.shippingAddrStreet=e.street,n.shippingAddrNumber=e.number,e.street&&e.number&&(n.shippingAddrStreet+=`, ${e.number}`),n.shippingAddrCity=e.city,n.shippingAddrProvinceCode=e.province_code),y.push({event:"purchaseExtraData",...n}),A=100}setTimeout(()=>I("purchase",S),A),localStorage.setItem("gtag.orderIdSent",s)}g=!0}};let u;const d=({name:s,params:t})=>{switch(s){case"cart":r("view_cart");break;case"checkout":t.step?Number(t.step)===1?r("add_shipping_info"):Number(t.step)===2&&r("add_payment_info"):r("begin_checkout");break;case"confirmation":clearTimeout(u),t.json?m(t.id,decodeURIComponent(t.json)):u=setTimeout(()=>{m(t.id)},1500);break}};o.currentRoute&&d(o.currentRoute),o.afterEach(d)}};{Object.keys(O).length&&sessionStorage.setItem("ecomUtm",JSON.stringify(O));let o=window.location.search;!o&&window.location.hash&&(o="?"+window.location.hash.split("?")[1]);const a=new URLSearchParams(o);a.get("product_id")&&a.get("quantity")==="1"&&(localStorage.setItem("ecomShoppingCart__tmp",JSON.stringify({items:[{product_id:a.get("product_id"),variation_id:a.get("variation_id")||void 0,quantity:1}]})),window.ECOM_CART_STORAGE_KEY="ecomShoppingCart__tmp");const{hostname:i}=window.location,{domain:h}=globalThis.$storefront.settings,r=`https://ecomplus.io/v2/:${window.ECOM_STORE_ID}/`;window.ECOMCLIENT_API_STORE=r,window.ECOMCLIENT_API_STORE_CACHE=r,window.ECOMCLIENT_API_PASSPORT=r,window.ECOMCLIENT_API_SEARCH=`${r}/search/_els/`,window.ECOMCLIENT_API_MODULES=["localhost","127.0.0.1"].includes(i)?`https://${h}/_api/modules/`:"/_api/modules/";const g=()=>{const{ecomPassport:u}=window;T(E,async()=>{E.value?u.setSession({auth:{...b.auth,id:b.auth?.customer_id,level:3},customer:p.value}):u.checkLogin()&&u.logout()},{immediate:!0}),T(p,d=>{(d.display_name||d.main_email)&&u.setCustomer(d)},{immediate:!0}),setTimeout(k,400)},m=document.createElement("script");m.src="https://cdn.jsdelivr.net/npm/@ecomplus/storefront-app@2.0.0-beta.190/dist/lib/js/app.js",m.onload=g,document.body.appendChild(m)}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{g as L}from"./_commonjsHelpers.Cpj98o6Y.js";import{a as R}from"./afetch.DPLba2tr.js";import{i as $}from"./i18n.
|
|
1
|
+
import{g as L}from"./_commonjsHelpers.Cpj98o6Y.js";import{a as R}from"./afetch.DPLba2tr.js";import{i as $}from"./i18n.BE5r_SIU.js";import{a as D,s as T,w as P}from"./sf-utils.xmJHVMAX.js";import{e as U}from"./index.CTTHpJlV.js";import"./hoisted.DSAg3dYh.js";import"./use-analytics.BWhF_fCv.js";import"./customer-session.BAjMMoBA.js";import"./server-data.CUHTES8a.js";import"./shopping-cart.DGvCZWRZ.js";import"./price.CHiL6Z1J.js";import"./name.CIPngEFN.js";var I={exports:{}};const q=Object.getPrototypeOf({});function E(t){function d(e){return e!=="constructor"&&e!=="prototype"&&e!=="__proto__"}function a(e){let n=0;const s=e.length,i=new Array(s);for(n=0;n<s;++n)i[n]=h(e[n]);return i}function o(e){const n={};if(b&&Object.getPrototypeOf(e)!==q)return b(e);const s=m(e);let i,c,u;for(i=0,c=s.length;i<c;++i)d(u=s[i])&&(n[u]=h(e[u]));return n}function r(e,n){const s=e.length,i=n.length;let c=0;const u=new Array(s+i);for(c=0;c<s;++c)u[c]=h(e[c]);for(c=0;c<i;++c)u[c+s]=h(n[c]);return u}const l=Object.prototype.propertyIsEnumerable;function g(e){const n=Object.keys(e),s=Object.getOwnPropertySymbols(e);for(let i=0,c=s.length;i<c;++i)l.call(e,s[i])&&n.push(s[i]);return n}const m=t&&t.symbols?g:Object.keys,b=typeof t?.cloneProtoObject=="function"?t.cloneProtoObject:void 0;function w(e){return typeof e=="object"&&e!==null&&!(e instanceof RegExp)&&!(e instanceof Date)}function p(e){return typeof e!="object"||e===null}const _=typeof Buffer<"u"?e=>typeof e!="object"||e===null||e instanceof RegExp||e instanceof Date||e instanceof Buffer:e=>typeof e!="object"||e===null||e instanceof RegExp||e instanceof Date,C=t&&typeof t.mergeArray=="function"?t.mergeArray({clone:h,deepmerge:S,getKeys:m,isMergeableObject:w}):r;function h(e){return w(e)?Array.isArray(e)?a(e):o(e):e}function A(e,n){const s={},i=m(e),c=m(n);let u,O,k;for(u=0,O=i.length;u<O;++u)d(k=i[u])&&c.indexOf(k)===-1&&(s[k]=h(e[k]));for(u=0,O=c.length;u<O;++u)d(k=c[u])&&(k in e&&(i.indexOf(k)!==-1&&(s[k]=S(e[k],n[k])),!0)||(s[k]=h(n[k])));return s}function S(e,n){const s=Array.isArray(n),i=Array.isArray(e);return p(n)?n:_(e)?h(n):s&&i?C(e,n):s!==i?h(n):A(e,n)}function y(){switch(arguments.length){case 0:return{};case 1:return h(arguments[0]);case 2:return S(arguments[0],arguments[1])}let e;for(let n=0,s=arguments.length;n<s;++n)e=S(e,arguments[n]);return e}return t&&t.all?y:S}I.exports=E;I.exports.default=E;I.exports.deepmerge=E;var N=I.exports;const x=L(N),W=()=>{const{CMS_REPO_BASE_DIR:t,CMS_LANG:d,CMS_MAX_FILE_SIZE:a,CMS:o}=window;if(!o)throw Error("Missing global CMS");const{domain:r}=window.$storefront?.settings||{},l=t||"functions/ssr/",g=d||"pt",m=_=>$(_,g),b=x();o.registerLocale(g,b(o.getLocale(g),{editor:{editorControl:{field:{optional:"?"}},editorWidgets:{image:{chooseDifferent:m({en:"Change image",pt:"Mudar imagem"}),remove:m({en:"Remove",pt:"Remover"})}}}}));const w=Math.max(a||0,1e6);return{locale:g,load_config_file:!1,publish_mode:"editorial_workflow",media_folder:`${l}public/img/uploads`,public_folder:"/img/uploads",site_url:`https://${r}/~preview`,display_url:`https://${r}`,logo_url:"https://ecom.nyc3.digitaloceanspaces.com/storefront/cms.png",show_preview_links:!0,search:!1,slug:{encoding:"ascii",clean_accents:!0,sanitize_replacement:"-"},collections:m([{name:"config",label:{en:"Settings",pt:"Configurações"},description:{en:"General settings for site identity and metadata",pt:"Configurações gerais para identidade e metadados do site"},delete:!1,editor:{preview:!1},files:[{name:"settings",label:{en:"General config",pt:"Configurações gerais"},file:`${l}content/settings.json`,editor:{preview:!0},fields:[{label:"e-com.plus Store ID",name:"storeId",widget:"hidden"},{label:"Repository",name:"repository",widget:"hidden"},{label:{en:"Domain name",pt:"Domínio"},name:"domain",widget:"string"},{label:{en:"Store name",pt:"Nome da loja"},name:"name",widget:"string"},{label:{en:"Short description",pt:"Descrição curta"},name:"description",widget:"text"},{label:{en:"Logo",pt:"Logomarca"},name:"logo",widget:"image",media_library:{config:{max_file_size:w}}},{label:{en:"Icon",pt:"Ícone"},name:"icon",widget:"image",media_library:{config:{max_file_size:w}}},{label:{en:"Primary color",pt:"Cor primária"},name:"primaryColor",widget:"color"},{label:{en:"Secondary color",pt:"Cor secundária"},name:"secondaryColor",widget:"color",required:!1},{label:{en:"Contact email",pt:"E-mail de contato"},name:"email",widget:"string",required:!1},{label:{en:"Service telephone",pt:"Telefone de atendimento"},name:"phone",widget:"string",required:!1},{label:{en:"Store address",pt:"Endereço da loja"},name:"address",widget:"string",required:!1},{label:{en:"Corporate name",pt:"Razão social da empresa"},name:"corporateName",widget:"string"},{label:{en:"Store document number",pt:"CNPJ"},name:"docNumber",widget:"string"},{label:{en:"Service links",pt:"Links de atendimento"},name:"serviceLinks",widget:"list",summary:"{{fields.title}}",fields:[{label:{en:"Title",pt:"Título"},name:"title",widget:"string"},{label:"Link",name:"href",widget:"string"}]},{label:{en:"Payment methods",pt:"Formas de pagamento"},name:"paymentMethods",widget:"select",multiple:!0,options:["pix","visa","mastercard","elo","amex","hipercard","boleto","diners","discover"]},{label:"WhatsApp",name:"whatsapp",widget:"string",required:!1},{label:"Instagram",name:"instagram",widget:"string",required:!1},{label:"Facebook",name:"facebook",widget:"string",required:!1},{label:"X / Twitter",name:"twitter",widget:"string",required:!1},{label:"YouTube",name:"youtube",widget:"string",required:!1},{label:"TikTok",name:"tiktok",widget:"string",required:!1},{label:"Pinterest",name:"pinterest",widget:"string",required:!1},{label:"Threads",name:"threads",widget:"string",required:!1},{label:{en:"Default locale",pt:"Língua padrão"},name:"lang",widget:"select",options:[{label:"Português",value:"pt_br"},{label:"Inglês",value:"en_us"}],default:"pt_br"},{label:{en:"Currency code",pt:"Código da moeda"},name:"currency",widget:"hidden",default:"BRL"},{label:{en:"Currency symbol",pt:"Símbolo da moeda"},name:"currencySymbol",widget:"hidden",default:"R$"},{label:{en:"Country code",pt:"Código do país"},name:"countryCode",widget:"hidden",default:"BR"},{name:"modules",widget:"hidden"},{name:"cartUrl",widget:"hidden"},{name:"checkoutUrl",widget:"hidden"},{name:"accountUrl",widget:"hidden"},{name:"ordersUrl",widget:"hidden"},{name:"favoritesUrl",widget:"hidden"},{name:"metafields",widget:"hidden"}]}]}])}},v=(t,d,a,o)=>{const r=o?t[a]?.[o]:t[a],l=o?d[a]?.[o]:d[a];if(typeof r!=typeof l)return!1;if(typeof r=="object"&&r&&l){const g=Object.keys(r);return g.length!==Object.keys(l).length?!1:g.every(m=>v(r,l,m))}return r===l},B=(t,d)=>{const a=[];return Object.keys(t).forEach(o=>{if(typeof t[o]=="object"&&t[o]){Object.keys(t[o]).forEach(r=>{Array.isArray(t[o])&&(r=Number(r)),v(t,d,o,r)||a.push([o,r])});return}v(t,d,o)||a.push([o])}),a},F=({createClass:t,h:d})=>{const{host:a}=window.location,o=a.includes("localhost")||a.includes("127.0.0.1"),r=D(null),l=T({}),g=U((b,w)=>{r.value=new URL(`http${o?"":"s"}://${a}/~preview/${b}`),w.forEach(({filename:p,data:_})=>{r.value.searchParams.append(`content:${p}`,JSON.stringify(_))})},100),m="pagePreview";return t({render(){const b=this.props.entry;l.value=b.toJS().data;const w=`
|
|
2
2
|
<iframe
|
|
3
3
|
id="${m}"
|
|
4
4
|
border="0"
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{u as C,w as V,e as I,a as R,t as S,b as Y}from"./use-analytics.
|
|
1
|
+
import{u as C,w as V,e as I,a as R,t as S,b as Y}from"./use-analytics.BWhF_fCv.js";import{a as $}from"./afetch.DPLba2tr.js";import{e as D}from"./index.CTTHpJlV.js";import"./customer-session.BAjMMoBA.js";import"./server-data.CUHTES8a.js";import"./sf-utils.xmJHVMAX.js";import"./shopping-cart.DGvCZWRZ.js";import"./price.CHiL6Z1J.js";import"./name.CIPngEFN.js";import"./i18n.BE5r_SIU.js";const h={waiting:Promise.resolve(),params:{content_ids:[],content_name:""}},A=(t,e="BRL",a=!1)=>{const n={currency:e,content_category:t.item_category,content_name:t.item_name,value:t.price,content_type:"product"};return a?(n.contents=[{id:t.item_id,quantity:t.quantity}],Number(t.quantity)<0&&(n.value=0)):n.content_ids=[t.item_id],n},W=async({event:t})=>{if(t.name==="page_view")return h.waiting=new Promise(n=>{setTimeout(n,110)}),h.params.content_name=t.params.page_title,[{name:"PageView"}];const{items:e,currency:a}=t.params;if(t.name==="view_item"&&e){const n=e[0];if(n)return n.item_list_id==="product-page"?[{name:"ViewContent",params:A(n,a)}]:(e.forEach(({item_id:r})=>{h.params.content_ids.push(r)}),h.params.content_ids.length>e.length?[{name:null}]:(await h.waiting,[{name:"ViewContent",params:{...h.params,content_type:"product"}}]))}if((t.name==="add_to_cart"||t.name==="remove_from_cart")&&e){const n=t.name==="add_to_cart";return e.map(r=>({name:"AddToCart",params:A({...r,quantity:n?r.quantity||1:-(r.quantity||1)},a,!0)}))}return[{name:null}]},y={waiting:Promise.resolve(),params:{description:"",contents:[]}},E=(t,e=!1)=>{const a={content_id:t.item_id,content_name:t.item_name,price:t.price,content_category:t.item_category,brand:t.item_brand};return e&&(a.quantity=t.quantity),a},F=async({event:t})=>{if(t.name==="page_view")return y.waiting=new Promise(n=>{setTimeout(n,110)}),y.params.description=t.params.page_title,[{name:"PageView"}];const{items:e,currency:a}=t.params;if(t.name==="view_item"&&e){const n=e[0];if(n)return n.item_list_id==="product-page"?[{name:"ViewContent",params:{contents:[E(n)],content_type:"product",currency:a,value:n.price}}]:(e.forEach(r=>{y.params.contents.push(E(r))}),y.params.contents.length>e.length?[{name:null}]:(await y.waiting,[{name:"ViewContent",params:{...y.params,content_type:"product",currency:a}}]))}if((t.name==="add_to_cart"||t.name==="remove_from_cart")&&e){const n=t.name==="add_to_cart";return e.map(r=>{const l=r.quantity||1,{price:m}=r;return{name:"AddToCart",params:{contents:[E({...r,quantity:n?l:-l},!0)],content_type:"product",currency:a,value:n&&typeof m=="number"?l*m:0}}})}return[{name:null}]},H={BASE_URL:"/",MODE:"production",DEV:!1,PROD:!0,SSR:!1,SITE:"https://demo.ecomplus.app",ASSETS_PREFIX:void 0}.DEPLOY_RAND||"_";let b=[];const M=D(t=>{$("/_analytics",{method:"POST",body:{exp_variant_string:t?.expVariantString,...Y(),events:b}}),b=[]},200);if(!window.location.search.includes(`__isrV=${H}`)){const t=C(),e=r=>{b.push(r),M(t)};V(async r=>{const{name:l,params:m}=r.event;e({type:"gtag",name:l,params:m});const{gtag:i,dataLayer:s,fbq:d,ttq:o}=window;typeof i=="function"&&i("event",l,m),s&&typeof s.push=="function"&&s.push(["event",l,m]),(await W(r)).forEach(u=>{u.name&&(e({type:"fbq",...u}),typeof d=="function"&&d("track",u.name,u.params))}),(await F(r)).forEach(u=>{u.name&&(e({type:"ttk",...u}),typeof o?.page=="function"&&(u.name==="PageView"?o.page():o.track(u.name,u.params)))})});let a="";const n=()=>{const r=window.location.toString();r!==a&&(I("page_view",{...R(),page_location:r,client_id:S.g_client_id||S.client_id}),a=r)};n(),window.addEventListener("storefront:apiContext",()=>{try{window.dataLayer.push(function(){this.reset(),n()})}catch{n()}})}const g=t=>history.replaceState(t,""),P=!!document.startViewTransition,w=()=>!!document.querySelector('[name="astro-view-transitions-enabled"]'),k=t=>document.dispatchEvent(new Event(t)),x=()=>k("astro:load"),f="data-astro-transition-persist";let p=history.state?.index||0;!history.state&&w()&&g({index:p,scrollY:0});const O=(t,e)=>{let a=!1,n=!1;return(...r)=>{if(a){n=!0;return}t(...r),a=!0,setTimeout(()=>{n&&(n=!1,t(...r)),a=!1},e)}};async function G(t){const e=await fetch(t),a=await e.text();return{ok:e.ok,html:a}}function q(){const t=document.querySelector('[name="astro-view-transitions-fallback"]');return t?t.getAttribute("content"):"animate"}function L(){for(const t of document.scripts)t.dataset.astroExec=""}function B(){let t=Promise.resolve();for(const e of Array.from(document.scripts)){if(e.dataset.astroExec==="")continue;const a=document.createElement("script");a.innerHTML=e.innerHTML;for(const n of e.attributes){if(n.name==="src"){const r=new Promise(l=>{a.onload=l});t=t.then(()=>r)}a.setAttribute(n.name,n.value)}a.dataset.astroExec="",e.replaceWith(a)}return t}const K=new DOMParser;async function v(t,e,a){const n=K.parseFromString(t,"text/html"),r=i=>{const s=i.getAttribute(f),d=s&&n.head.querySelector(`[${f}="${s}"]`);if(d)return d;if(i.matches("link[rel=stylesheet]")){const o=i.getAttribute("href");return n.head.querySelector(`link[rel=stylesheet][href="${o}"]`)}if(i.tagName==="SCRIPT"){let o=i;for(const c of n.scripts)if(o.textContent&&o.textContent===c.textContent||o.type===c.type&&o.src&&o.src===c.src)return c}return null},l=()=>{n.querySelectorAll("head noscript").forEach(o=>o.remove());const i=document.documentElement,s=[...i.attributes].filter(({name:o})=>(i.removeAttribute(o),o.startsWith("data-astro-")));[...n.documentElement.attributes,...s].forEach(({name:o,value:c})=>i.setAttribute(o,c));for(const o of Array.from(document.head.children)){const c=r(o);c?c.remove():o.remove()}document.head.append(...n.head.children);const d=document.body;document.body.replaceWith(n.body);for(const o of d.querySelectorAll(`[${f}]`)){const c=o.getAttribute(f),_=document.querySelector(`[${f}="${c}"]`);_&&_.replaceWith(o)}if(scrollTo({left:0,top:0,behavior:"instant"}),e?.scrollY===0&&location.hash){const o=decodeURIComponent(location.hash.slice(1)),c=document.getElementById(o);c&&(e.scrollY=c.offsetTop,g(e),c.scrollIntoView())}else e&&e.scrollY!==0&&scrollTo(0,e.scrollY);k("astro:beforeload")},m=[];for(const i of n.querySelectorAll("head link[rel=stylesheet]"))if(!document.querySelector(`[${f}="${i.getAttribute(f)}"], link[rel=stylesheet]`)){const s=document.createElement("link");s.setAttribute("rel","preload"),s.setAttribute("as","style"),s.setAttribute("href",i.getAttribute("href")),m.push(new Promise(d=>{["load","error"].forEach(o=>s.addEventListener(o,d)),document.head.append(s)}))}if(m.length&&await Promise.all(m),a==="animate"){let i=!1;addEventListener("animationstart",()=>i=!0,{once:!0}),document.documentElement.dataset.astroTransitionFallback="old",await new Promise(s=>{const d=()=>{removeEventListener("animationend",d),clearTimeout(o),l(),s(!0),document.documentElement.dataset.astroTransitionFallback="new"};addEventListener("animationend",d,{once:!0});let o=setTimeout(()=>!i&&d())})}else l()}async function T(t,e,a){let n;const{html:r,ok:l}=await G(e);if(!l){location.href=e;return}document.documentElement.dataset.astroTransition=t,P?n=document.startViewTransition(()=>v(r,a)).finished:n=v(r,a,q());try{await n}finally{await B(),L(),x()}}function N(t){if(document.querySelector(`link[rel=prefetch][href="${t}"]`))return;if(navigator.connection){let a=navigator.connection;if(a.saveData||/(2|3)g/.test(a.effectiveType||""))return}let e=document.createElement("link");e.setAttribute("rel","prefetch"),e.setAttribute("href",t),document.head.append(e)}(P||q()!=="none")&&!location.pathname.startsWith("/app/")&&!location.pathname.startsWith("/admin/")&&(L(),document.addEventListener("click",t=>{let e=t.target;if(e instanceof Element&&e.tagName!=="A"&&(e=e.closest("a")),!e||!(e instanceof HTMLAnchorElement)||e.dataset.astroReload!==void 0||e.hasAttribute("download")||!e.href||e.pathname.startsWith("/app/")||e.pathname.startsWith("/admin/")||e.target&&e.target!=="_self"||e.origin!==location.origin||t.button!==0||t.metaKey||t.ctrlKey||t.altKey||t.shiftKey||t.defaultPrevented||!w())return;if(location.pathname===e.pathname&&location.search===e.search){if(e.hash)return;if(t.preventDefault(),g({...history.state,scrollY}),scrollTo({left:0,top:0,behavior:"instant"}),location.hash){const n={index:++p,scrollY:0};history.pushState(n,"",e.href)}return}t.preventDefault(),T("forward",e.href,{index:++p,scrollY:0});const a={index:p,scrollY};g({index:p-1,scrollY}),history.pushState(a,"",e.href)}),addEventListener("popstate",t=>{if(!w()&&t.state){location.reload();return}if(t.state===null)return;const e=history.state,a=e?.index??p+1,n=a>p?"forward":"back";T(n,location.href,e),p=a}),["mouseenter","touchstart","focus"].forEach(t=>{document.addEventListener(t,e=>{if(e.target instanceof HTMLAnchorElement){let a=e.target;a.origin===location.origin&&a.pathname!==location.pathname&&!a.pathname.startsWith("/app/")&&!a.pathname.startsWith("/admin/")&&a.dataset.astroReload===void 0&&!a.hasAttribute("download")&&a.role!=="button"&&w()&&N(a.pathname)}},{passive:!0,capture:!0})}),addEventListener("load",x),addEventListener("scroll",O(()=>{history.state&&g({...history.state,scrollY})},300),{passive:!0}));
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"./hoisted.DSAg3dYh.js";import"./afetch.DPLba2tr.js";import"./use-analytics.BWhF_fCv.js";import"./customer-session.BAjMMoBA.js";import"./server-data.CUHTES8a.js";import"./sf-utils.xmJHVMAX.js";import"./index.CTTHpJlV.js";import"./shopping-cart.DGvCZWRZ.js";import"./price.CHiL6Z1J.js";import"./name.CIPngEFN.js";import"./i18n.BE5r_SIU.js";const t=window.location.search.includes("status=404")?"404Msg":"5xxMsg";document.getElementById(t).style.display="block";document.getElementById("loadingMsg").style.display="none";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{D as t,_ as l}from"./sf-utils.
|
|
1
|
+
import{D as t,_ as l}from"./sf-utils.xmJHVMAX.js";const o=(e,f=l.get("lang"))=>{if(typeof e=="object"&&e!==null){const p=Object.keys(e)[0];if(/^[a-z]{2}(_[a-z]{2})?$/.test(p))return e[f]||e[t]||e[p];{const r=Array.isArray(e)?[]:{};for(const s in e)e[s]!==void 0&&(r[s]=o(e[s],f));return r}}return e};export{o as i};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{_ as t}from"./sf-utils.
|
|
1
|
+
import{_ as t}from"./sf-utils.xmJHVMAX.js";const g=(l,n,o)=>{if(o||(o=t.get("default_img_size")||"normal"),l){let{pictures:a,picture:i}=l;i||a||(Array.isArray(l)?a=l:i=l),Array.isArray(a)&&(i=n&&a.filter(r=>r._id===n)[0]||a[0]);let f;if(typeof i=="object"&&i!==null){if(f=i[o],f&&f.url)return f;let r;switch(o){case"small":r=["normal","big"];break;case"normal":r=["big","zoom","small"];break;case"big":r=["zoom","normal"];break;case"zoom":r=["big"];break;default:r=["big","zoom","normal","small"]}for(let e=0;e<r.length;e++){const s=r[e];if(i[s]&&i[s].url)return i[s]}for(const e in i)if(i[e]&&i[e].url)return i[e]}}};export{g as i};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{m as X,w as q,i as z,n as $,a as B,t as A,c as Q,u as Y,b as G,d as J,e as Z,f as ee}from"./index.
|
|
1
|
+
import{m as X,w as q,i as z,n as $,a as B,t as A,c as Q,u as Y,b as G,d as J,e as Z,f as ee}from"./index.CTTHpJlV.js";import{s as te,r as D,w as oe,d as j,a as C,c as U}from"./sf-utils.xmJHVMAX.js";function le(n={}){const{inheritAttrs:u=!0}=n,r=te(),a=j({setup(m,{slots:e}){return()=>{r.value=e.default}}}),y=j({inheritAttrs:u,setup(m,{attrs:e,slots:i}){return()=>{var p;r.value;const f=(p=r.value)==null?void 0:p.call(r,{...ne(e),$slots:i});return u&&f?.length===1?f[0]:f}}});return X({define:a,reuse:y},[a,y])}function ne(n){const u={};for(const r in n)u[Q(r)]=n[r];return u}function O(n){var u;const r=A(n);return(u=r?.$el)!=null?u:r}const R=z?window:void 0;function S(...n){let u,r,a,y;if(typeof n[0]=="string"||Array.isArray(n[0])?([r,a,y]=n,u=R):[u,r,a,y]=n,!u)return $;Array.isArray(r)||(r=[r]),Array.isArray(a)||(a=[a]);const m=[],e=()=>{m.forEach(b=>b()),m.length=0},i=(b,v,o,c)=>(b.addEventListener(v,o,c),()=>b.removeEventListener(v,o,c)),p=oe(()=>[O(u),A(y)],([b,v])=>{if(e(),!b)return;const o=B(v)?{...v}:v;m.push(...r.flatMap(c=>a.map(h=>i(b,c,h,o))))},{immediate:!0,flush:"post"}),f=()=>{p(),e()};return ee(f),f}let K=!1;function ae(n,u,r={}){const{window:a=R,ignore:y=[],capture:m=!0,detectIframe:e=!1}=r;if(!a)return $;J&&!K&&(K=!0,Array.from(a.document.body.children).forEach(o=>o.addEventListener("click",$)),a.document.documentElement.addEventListener("click",$));let i=!0;const p=o=>y.some(c=>{if(typeof c=="string")return Array.from(a.document.querySelectorAll(c)).some(h=>h===o.target||o.composedPath().includes(h));{const h=O(c);return h&&(o.target===h||o.composedPath().includes(h))}}),b=[S(a,"click",o=>{const c=O(n);if(!(!c||c===o.target||o.composedPath().includes(c))){if(o.detail===0&&(i=!p(o)),!i){i=!0;return}u(o)}},{passive:!0,capture:m}),S(a,"pointerdown",o=>{const c=O(n);i=!p(o)&&!!(c&&!o.composedPath().includes(c))},{passive:!0}),e&&S(a,"blur",o=>{setTimeout(()=>{var c;const h=O(n);((c=a.document.activeElement)==null?void 0:c.tagName)==="IFRAME"&&!h?.contains(a.document.activeElement)&&u(o)},0)})].filter(Boolean);return()=>b.forEach(o=>o())}function ie(n,u={}){const{delayEnter:r=0,delayLeave:a=0,window:y=R}=u,m=C(!1);let e;const i=p=>{const f=p?r:a;e&&(clearTimeout(e),e=void 0),f?e=setTimeout(()=>m.value=p,f):m.value=p};return y&&(S(n,"mouseenter",()=>i(!0),{passive:!0}),S(n,"mouseleave",()=>i(!1),{passive:!0})),m}const N=1;function ce(n,u={}){const{throttle:r=0,idle:a=200,onStop:y=$,onScroll:m=$,offset:e={left:0,right:0,top:0,bottom:0},eventListenerOptions:i={capture:!1,passive:!0},behavior:p="auto",window:f=R,onError:b=s=>{console.error(s)}}=u,v=C(0),o=C(0),c=U({get(){return v.value},set(s){x(s,void 0)}}),h=U({get(){return o.value},set(s){x(void 0,s)}});function x(s,T){var w,P,k;if(!f)return;const g=A(n);g&&((k=g instanceof Document?f.document.body:g)==null||k.scrollTo({top:(w=A(T))!=null?w:h.value,left:(P=A(s))!=null?P:c.value,behavior:A(p)}))}const _=C(!1),l=D({left:!0,right:!1,top:!0,bottom:!1}),t=D({left:!1,right:!1,top:!1,bottom:!1}),d=s=>{_.value&&(_.value=!1,t.left=!1,t.right=!1,t.top=!1,t.bottom=!1,y(s))},E=Z(d,r+a),H=s=>{var T;if(!f)return;const w=((T=s?.document)==null?void 0:T.documentElement)||s?.documentElement||O(s),{display:P,flexDirection:k}=getComputedStyle(w),g=w.scrollLeft;t.left=g<v.value,t.right=g>v.value;const F=Math.abs(g)<=(e.left||0),I=Math.abs(g)+w.clientWidth>=w.scrollWidth-(e.right||0)-N;P==="flex"&&k==="row-reverse"?(l.left=I,l.right=F):(l.left=F,l.right=I),v.value=g;let L=w.scrollTop;s===f.document&&!L&&(L=f.document.body.scrollTop),t.top=L<o.value,t.bottom=L>o.value;const V=Math.abs(L)<=(e.top||0),W=Math.abs(L)+w.clientHeight>=w.scrollHeight-(e.bottom||0)-N;P==="flex"&&k==="column-reverse"?(l.top=W,l.bottom=V):(l.top=V,l.bottom=W),o.value=L},M=s=>{var T;if(!f)return;const w=(T=s.target.documentElement)!=null?T:s.target;H(w),_.value=!0,E(s),m(s)};return S(n,"scroll",r?Y(M,r,!0,!1):M,i),G(()=>{try{const s=A(n);if(!s)return;H(s)}catch(s){b(s)}}),S(n,"scrollend",d,i),{x:c,y:h,isScrolling:_,arrivedState:l,directions:t,measure(){const s=A(n);f&&s&&H(s)}}}function ue(n="history",u={}){const{initialValue:r={},removeNullishValues:a=!0,removeFalsyValues:y=!1,write:m=!0,window:e=R}=u;if(!e)return D(r);const i=D({});function p(){if(n==="history")return e.location.search||"";if(n==="hash"){const l=e.location.hash||"",t=l.indexOf("?");return t>0?l.slice(t):""}else return(e.location.hash||"").replace(/^#/,"")}function f(l){const t=l.toString();if(n==="history")return`${t?`?${t}`:""}${e.location.hash||""}`;if(n==="hash-params")return`${e.location.search||""}${t?`#${t}`:""}`;const d=e.location.hash||"#",E=d.indexOf("?");return E>0?`${d.slice(0,E)}${t?`?${t}`:""}`:`${d}${t?`?${t}`:""}`}function b(){return new URLSearchParams(p())}function v(l){const t=new Set(Object.keys(i));for(const d of l.keys()){const E=l.getAll(d);i[d]=E.length>1?E:l.get(d)||"",t.delete(d)}Array.from(t).forEach(d=>delete i[d])}const{pause:o,resume:c}=q(i,()=>{const l=new URLSearchParams("");Object.keys(i).forEach(t=>{const d=i[t];Array.isArray(d)?d.forEach(E=>l.append(t,E)):a&&d==null||y&&!d?l.delete(t):l.set(t,d)}),h(l)},{deep:!0});function h(l,t){o(),t&&v(l),e.history.replaceState(e.history.state,e.document.title,e.location.pathname+f(l)),c()}function x(){m&&h(b(),!0)}S(e,"popstate",x,!1),n!=="history"&&S(e,"hashchange",x,!1);const _=b();return _.keys().next().value?v(_):Object.assign(i,r),i}export{ce as a,ie as b,le as c,ae as o,ue as u};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{P as C,_ as A,w as b,Q as T,R as W,a as y,S as O,c as _,T as R,U as k,V as I,W as M,X as V}from"./sf-utils.
|
|
1
|
+
import{P as C,_ as A,w as b,Q as T,R as W,a as y,S as O,c as _,T as R,U as k,V as I,W as M,X as V}from"./sf-utils.xmJHVMAX.js";C.$ecomConfig||A;function z(e){return M()?(V(e),!0):!1}function H(e,t){if(typeof Symbol<"u"){const n={...e};return Object.defineProperty(n,Symbol.iterator,{enumerable:!1,value(){let o=0;return{next:()=>({value:t[o++],done:o>t.length})}}}),n}else return Object.assign([...t],e)}function m(e){return typeof e=="function"?e():W(e)}const F=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const E=Object.prototype.toString,J=e=>E.call(e)==="[object Object]",f=()=>{},K=G();function G(){var e,t;return F&&((e=window?.navigator)==null?void 0:e.userAgent)&&(/iP(ad|hone|od)/.test(window.navigator.userAgent)||((t=window?.navigator)==null?void 0:t.maxTouchPoints)>2&&/iPad|Macintosh/.test(window?.navigator.userAgent))}function w(e,t){function n(...o){return new Promise((i,r)=>{Promise.resolve(e(()=>t.apply(this,o),{fn:t,thisArg:this,args:o})).then(i).catch(r)})}return n}const P=e=>e();function S(e,t={}){let n,o,i=f;const r=s=>{clearTimeout(s),i(),i=f};return s=>{const u=m(e),a=m(t.maxWait);return n&&r(n),u<=0||a!==void 0&&a<=0?(o&&(r(o),o=null),Promise.resolve(s())):new Promise((l,v)=>{i=t.rejectOnCancel?v:l,a&&!o&&(o=setTimeout(()=>{n&&r(n),o=null,l(s())},a)),n=setTimeout(()=>{o&&r(o),o=null,l(s())},u)})}}function L(...e){let t=0,n,o=!0,i=f,r,c,s,u,a;!k(e[0])&&typeof e[0]=="object"?{delay:c,trailing:s=!0,leading:u=!0,rejectOnCancel:a=!1}=e[0]:[c,s=!0,u=!0,a=!1]=e;const l=()=>{n&&(clearTimeout(n),n=void 0,i(),i=f)};return x=>{const d=m(c),h=Date.now()-t,p=()=>r=x();return l(),d<=0?(t=Date.now(),p()):(h>d&&(u||!o)?(t=Date.now(),p()):s&&(r=new Promise((g,D)=>{i=a?D:g,n=setTimeout(()=>{t=Date.now(),o=!0,g(p()),l()},Math.max(0,d-h))})),!u&&!n&&(n=setTimeout(()=>o=!0,d)),o=!1,r)}}function U(e=P){const t=y(!0);function n(){t.value=!1}function o(){t.value=!0}const i=(...r)=>{t.value&&e(...r)};return{isActive:O(t),pause:n,resume:o,eventFilter:i}}function Q(e){const t=Object.create(null);return n=>t[n]||(t[n]=e(n))}const X=/-(\w)/g,N=Q(e=>e.replace(X,(t,n)=>n?n.toUpperCase():""));function Y(e,t=!1,n="Timeout"){return new Promise((o,i)=>{setTimeout(t?()=>i(n):o,e)})}function $(e){return e||I()}function Z(e,t=200,n={}){return w(S(t,n),e)}function ee(e,t=200,n=!1,o=!0,i=!1){return w(L(t,n,o,i),e)}function j(e,t,n={}){const{eventFilter:o=P,...i}=n;return b(e,w(o,t),i)}function te(e,t,n={}){const{eventFilter:o,...i}=n,{eventFilter:r,pause:c,resume:s,isActive:u}=U(o);return{stop:j(e,t,{...i,eventFilter:r}),pause:c,resume:s,isActive:u}}function ne(e,t=!0,n){$()?R(e,n):t?e():T(e)}function q(e,t,n={}){const{immediate:o=!0}=n,i=y(!1);let r=null;function c(){r&&(clearTimeout(r),r=null)}function s(){i.value=!1,c()}function u(...a){c(),i.value=!0,r=setTimeout(()=>{i.value=!1,r=null,e(...a)},m(t))}return o&&(i.value=!0,F&&u()),z(s),{isPending:O(i),start:u,stop:s}}function oe(e=1e3,t={}){const{controls:n=!1,callback:o}=t,i=q(o??f,e,t),r=_(()=>!i.isPending.value);return n?{ready:r,...i}:r}function ie(e,t,n={}){const{debounce:o=0,maxWait:i=void 0,...r}=n;return j(e,t,{...r,eventFilter:S(o,{maxWait:i})})}function re(e,t,n){const o=b(e,(...i)=>(T(()=>o()),t(...i)),n);return o}export{J as a,ne as b,N as c,K as d,Z as e,z as f,re as g,ie as h,F as i,oe as j,H as m,f as n,Y as p,m as t,ee as u,te as w};
|
package/packages/storefront/dist/client/_astro/{modules-info.BHKiT6oA.js → modules-info.C6KJuGeB.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{l as g,u as h,a as d}from"./afetch.DPLba2tr.js";import"./server-data.CUHTES8a.js";import{r as b,b as v,c as p}from"./sf-utils.
|
|
1
|
+
import{l as g,u as h,a as d}from"./afetch.DPLba2tr.js";import"./server-data.CUHTES8a.js";import{r as b,b as v,c as p}from"./sf-utils.xmJHVMAX.js";import{f as O}from"./format-money.vLicYTv9.js";const I={list_payments:{},calculate_shipping:{},apply_discount:{}},i=b(I);g.then(n=>{Object.assign(i,n)});const S=(n,r)=>{const{hostname:l}=window.location,{domain:o}=globalThis.$storefront.settings,a=l!=="localhost"&&l!=="127.0.0.1"?`https://${o}/_api/modules/`:"/_api/modules/";return d(`${a}${n}`,r)};{const n="MODULES_INFO",r=sessionStorage.getItem(n);if(r)try{const o=JSON.parse(r);o.__timestamp>=Date.now()-1e3*60*5?(delete o.__timestamp,Object.assign(i,o)):sessionStorage.removeItem(n)}catch{sessionStorage.removeItem(n)}v(()=>{const o=[];["list_payments","calculate_shipping"].forEach(a=>{Object.keys(i[a]).length||o.push({modName:a})}),Object.keys(h).length&&o.push({modName:"apply_discount",reqOptions:{method:"POST",body:{utm:h}}}),o.forEach(({modName:a,reqOptions:u})=>{S(a,u).then(async m=>{if(m.ok){const s={};i[a]=s;const{result:f}=await m.json();Array.isArray(f)&&f.forEach(({error:y,response:c})=>{if(!y){let t,e;switch(a){case"calculate_shipping":t="free_shipping_from_value",e=c[t],typeof e=="number"&&(s[t]===void 0||e<s[t])&&(s[t]=e);break;case"list_payments":t="installments_option",e=c[t],e&&(!s[t]||e.monthly_interest<s[t].monthly_interest||e.max_number>s[t].max_number)&&(s[t]=e),t="discount_option",e=c[t],e&&(!s[t]||e.value>s[t].value)&&c.payment_gateways.forEach(({discount:_})=>{_&&_.apply_at!=="freight"&&_.value===e.value&&(s[t]={apply_at:_.apply_at,...e})}),t="loyalty_points_programs",e=c[t],e&&(s[t]={...s[t],...e});break;default:t="available_extra_discount",e=c[t],e&&(!s[t]||e.value>s[t].value)&&(s[t]=e)}}}),sessionStorage.setItem(n,JSON.stringify({...i,__timestamp:Date.now()}))}}).catch(console.error)})})}const j=p(()=>i.calculate_shipping.free_shipping_from_value),$=p(()=>i.list_payments.installments_option),D=p(()=>i.list_payments.discount_option),F=p(()=>i.list_payments.loyalty_points_programs),J=p(()=>i.apply_discount.available_extra_discount),x=(n,r,l,o=O)=>p(()=>{const a=`{${l}}`,u=n.indexOf(a);if(u>-1){const m=i[r][l];if(m){const s=o(m);return n.substring(0,u)+s+n.substring(u+a.length)}return""}return n}),M=n=>x(n,"calculate_shipping","free_shipping_from_value");export{J as a,S as b,D as d,j as f,$ as i,F as l,M as p};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{_ as e}from"./sf-utils.xmJHVMAX.js";import{i as r}from"./i18n.BE5r_SIU.js";const s=(i,n=e.get("lang"))=>n&&i.i18n&&i.i18n[n]?i.i18n[n]:i.name||i.title||r(i.i18n,n)||"";export{s as n};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
var _s={};let Vt,yn;typeof window=="object"&&window?yn=Vt=window:typeof process=="object"&&_s?(yn=global,Vt=_s):yn=Vt=typeof self=="object"&&self||{};const Xr="en_us",zr="USD",el="$",tl="US",nl=1011,sl="5b1abe30a4d4531b8fe40725",rl=e=>{if(typeof document=="object"&&document){const t=document.getElementsByTagName("meta");for(let n=0;n<t.length;n++)if(t[n].getAttribute("name")===e.replace(/_/g,"-")){const s=t[n].getAttribute("content");return e==="ecom_store_id"?parseInt(s,10):s}}return Vt[e.toUpperCase()]},Fn={};["lang","currency","currency_symbol","country_code","store_id","store_object_id"].forEach(e=>{Fn[e]=rl("ecom_"+e)});const mo={get(e){const t=Fn[e];if(t!=null&&t!=="")return t;switch(e){case"lang":return Xr;case"currency":return zr;case"currency_symbol":return el;case"country_code":return tl;case"store_id":return nl;case"store_object_id":return sl}return null},set(e,t){Fn[e]=t}};/**
|
|
2
|
+
* @vue/shared v3.4.21
|
|
3
|
+
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
|
+
* @license MIT
|
|
5
|
+
**/function Dn(e,t){const n=new Set(e.split(","));return t?s=>n.has(s.toLowerCase()):s=>n.has(s)}const ee={},nt=[],Te=()=>{},ll=()=>!1,nn=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),Ds=e=>e.startsWith("onUpdate:"),fe=Object.assign,Kn=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},il=Object.prototype.hasOwnProperty,Y=(e,t)=>il.call(e,t),U=Array.isArray,st=e=>Et(e)==="[object Map]",Ks=e=>Et(e)==="[object Set]",ys=e=>Et(e)==="[object Date]",$=e=>typeof e=="function",le=e=>typeof e=="string",Ke=e=>typeof e=="symbol",z=e=>e!==null&&typeof e=="object",Ws=e=>(z(e)||$(e))&&$(e.then)&&$(e.catch),qs=Object.prototype.toString,Et=e=>qs.call(e),ol=e=>Et(e).slice(8,-1),Gs=e=>Et(e)==="[object Object]",Wn=e=>le(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,rt=Dn(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),sn=e=>{const t=Object.create(null);return n=>t[n]||(t[n]=e(n))},cl=/-(\w)/g,Me=sn(e=>e.replace(cl,(t,n)=>n?n.toUpperCase():"")),fl=/\B([A-Z])/g,At=sn(e=>e.replace(fl,"-$1").toLowerCase()),qn=sn(e=>e.charAt(0).toUpperCase()+e.slice(1)),mn=sn(e=>e?`on${qn(e)}`:""),Pe=(e,t)=>!Object.is(e,t),bn=(e,t)=>{for(let n=0;n<e.length;n++)e[n](t)},Gt=(e,t,n)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,value:n})},ul=e=>{const t=parseFloat(e);return isNaN(t)?e:t},al=e=>{const t=le(e)?Number(e):NaN;return isNaN(t)?e:t};let ms;const Js=()=>ms||(ms=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function rn(e){if(U(e)){const t={};for(let n=0;n<e.length;n++){const s=e[n],r=le(s)?pl(s):rn(s);if(r)for(const l in r)t[l]=r[l]}return t}else if(le(e)||z(e))return e}const dl=/;(?![^(]*\))/g,hl=/:([^]+)/,gl=/\/\*[^]*?\*\//g;function pl(e){const t={};return e.replace(gl,"").split(dl).forEach(n=>{if(n){const s=n.split(hl);s.length>1&&(t[s[0].trim()]=s[1].trim())}}),t}function ln(e){let t="";if(le(e))t=e;else if(U(e))for(let n=0;n<e.length;n++){const s=ln(e[n]);s&&(t+=s+" ")}else if(z(e))for(const n in e)e[n]&&(t+=n+" ");return t.trim()}function bo(e){if(!e)return null;let{class:t,style:n}=e;return t&&!le(t)&&(e.class=ln(t)),n&&(e.style=rn(n)),e}const _l="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",xo=Dn(_l);function Co(e){return!!e||e===""}function yl(e,t){if(e.length!==t.length)return!1;let n=!0;for(let s=0;n&&s<e.length;s++)n=Ys(e[s],t[s]);return n}function Ys(e,t){if(e===t)return!0;let n=ys(e),s=ys(t);if(n||s)return n&&s?e.getTime()===t.getTime():!1;if(n=Ke(e),s=Ke(t),n||s)return e===t;if(n=U(e),s=U(t),n||s)return n&&s?yl(e,t):!1;if(n=z(e),s=z(t),n||s){if(!n||!s)return!1;const r=Object.keys(e).length,l=Object.keys(t).length;if(r!==l)return!1;for(const i in e){const o=e.hasOwnProperty(i),f=t.hasOwnProperty(i);if(o&&!f||!o&&f||!Ys(e[i],t[i]))return!1}}return String(e)===String(t)}const To=e=>le(e)?e:e==null?"":U(e)||z(e)&&(e.toString===qs||!$(e.toString))?JSON.stringify(e,Zs,2):String(e),Zs=(e,t)=>t&&t.__v_isRef?Zs(e,t.value):st(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((n,[s,r],l)=>(n[xn(s,l)+" =>"]=r,n),{})}:Ks(t)?{[`Set(${t.size})`]:[...t.values()].map(n=>xn(n))}:Ke(t)?xn(t):z(t)&&!U(t)&&!Gs(t)?String(t):t,xn=(e,t="")=>{var n;return Ke(e)?`Symbol(${(n=e.description)!=null?n:t})`:e};/**
|
|
6
|
+
* @vue/reactivity v3.4.21
|
|
7
|
+
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
8
|
+
* @license MIT
|
|
9
|
+
**/let me;class ml{constructor(t=!1){this.detached=t,this._active=!0,this.effects=[],this.cleanups=[],this.parent=me,!t&&me&&(this.index=(me.scopes||(me.scopes=[])).push(this)-1)}get active(){return this._active}run(t){if(this._active){const n=me;try{return me=this,t()}finally{me=n}}}on(){me=this}off(){me=this.parent}stop(t){if(this._active){let n,s;for(n=0,s=this.effects.length;n<s;n++)this.effects[n].stop();for(n=0,s=this.cleanups.length;n<s;n++)this.cleanups[n]();if(this.scopes)for(n=0,s=this.scopes.length;n<s;n++)this.scopes[n].stop(!0);if(!this.detached&&this.parent&&!t){const r=this.parent.scopes.pop();r&&r!==this&&(this.parent.scopes[this.index]=r,r.index=this.index)}this.parent=void 0,this._active=!1}}}function bl(e,t=me){t&&t.active&&t.effects.push(e)}function xl(){return me}function wo(e){me&&me.cleanups.push(e)}let Ze;class Gn{constructor(t,n,s,r){this.fn=t,this.trigger=n,this.scheduler=s,this.active=!0,this.deps=[],this._dirtyLevel=4,this._trackId=0,this._runnings=0,this._shouldSchedule=!1,this._depsLength=0,bl(this,r)}get dirty(){if(this._dirtyLevel===2||this._dirtyLevel===3){this._dirtyLevel=1,Xe();for(let t=0;t<this._depsLength;t++){const n=this.deps[t];if(n.computed&&(Cl(n.computed),this._dirtyLevel>=4))break}this._dirtyLevel===1&&(this._dirtyLevel=0),ze()}return this._dirtyLevel>=4}set dirty(t){this._dirtyLevel=t?4:0}run(){if(this._dirtyLevel=0,!this.active)return this.fn();let t=Ve,n=Ze;try{return Ve=!0,Ze=this,this._runnings++,bs(this),this.fn()}finally{xs(this),this._runnings--,Ze=n,Ve=t}}stop(){var t;this.active&&(bs(this),xs(this),(t=this.onStop)==null||t.call(this),this.active=!1)}}function Cl(e){return e.value}function bs(e){e._trackId++,e._depsLength=0}function xs(e){if(e.deps.length>e._depsLength){for(let t=e._depsLength;t<e.deps.length;t++)Qs(e.deps[t],e);e.deps.length=e._depsLength}}function Qs(e,t){const n=e.get(t);n!==void 0&&t._trackId!==n&&(e.delete(t),e.size===0&&e.cleanup())}let Ve=!0,Rn=0;const Xs=[];function Xe(){Xs.push(Ve),Ve=!1}function ze(){const e=Xs.pop();Ve=e===void 0?!0:e}function Jn(){Rn++}function Yn(){for(Rn--;!Rn&&In.length;)In.shift()()}function zs(e,t,n){if(t.get(e)!==e._trackId){t.set(e,e._trackId);const s=e.deps[e._depsLength];s!==t?(s&&Qs(s,e),e.deps[e._depsLength++]=t):e._depsLength++}}const In=[];function er(e,t,n){Jn();for(const s of e.keys()){let r;s._dirtyLevel<t&&(r??(r=e.get(s)===s._trackId))&&(s._shouldSchedule||(s._shouldSchedule=s._dirtyLevel===0),s._dirtyLevel=t),s._shouldSchedule&&(r??(r=e.get(s)===s._trackId))&&(s.trigger(),(!s._runnings||s.allowRecurse)&&s._dirtyLevel!==2&&(s._shouldSchedule=!1,s.scheduler&&In.push(s.scheduler)))}Yn()}const tr=(e,t)=>{const n=new Map;return n.cleanup=e,n.computed=t,n},Jt=new WeakMap,Qe=Symbol(""),On=Symbol("");function _e(e,t,n){if(Ve&&Ze){let s=Jt.get(e);s||Jt.set(e,s=new Map);let r=s.get(n);r||s.set(n,r=tr(()=>s.delete(n))),zs(Ze,r)}}function ke(e,t,n,s,r,l){const i=Jt.get(e);if(!i)return;let o=[];if(t==="clear")o=[...i.values()];else if(n==="length"&&U(e)){const f=Number(s);i.forEach((d,h)=>{(h==="length"||!Ke(h)&&h>=f)&&o.push(d)})}else switch(n!==void 0&&o.push(i.get(n)),t){case"add":U(e)?Wn(n)&&o.push(i.get("length")):(o.push(i.get(Qe)),st(e)&&o.push(i.get(On)));break;case"delete":U(e)||(o.push(i.get(Qe)),st(e)&&o.push(i.get(On)));break;case"set":st(e)&&o.push(i.get(Qe));break}Jn();for(const f of o)f&&er(f,4);Yn()}function Tl(e,t){var n;return(n=Jt.get(e))==null?void 0:n.get(t)}const wl=Dn("__proto__,__v_isRef,__isVue"),nr=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(Ke)),Cs=vl();function vl(){const e={};return["includes","indexOf","lastIndexOf"].forEach(t=>{e[t]=function(...n){const s=Z(this);for(let l=0,i=this.length;l<i;l++)_e(s,"get",l+"");const r=s[t](...n);return r===-1||r===!1?s[t](...n.map(Z)):r}}),["push","pop","shift","unshift","splice"].forEach(t=>{e[t]=function(...n){Xe(),Jn();const s=Z(this)[t].apply(this,n);return Yn(),ze(),s}}),e}function El(e){const t=Z(this);return _e(t,"has",e),t.hasOwnProperty(e)}class sr{constructor(t=!1,n=!1){this._isReadonly=t,this._isShallow=n}get(t,n,s){const r=this._isReadonly,l=this._isShallow;if(n==="__v_isReactive")return!r;if(n==="__v_isReadonly")return r;if(n==="__v_isShallow")return l;if(n==="__v_raw")return s===(r?l?jl:or:l?ir:lr).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(s)?t:void 0;const i=U(t);if(!r){if(i&&Y(Cs,n))return Reflect.get(Cs,n,s);if(n==="hasOwnProperty")return El}const o=Reflect.get(t,n,s);return(Ke(n)?nr.has(n):wl(n))||(r||_e(t,"get",n),l)?o:ae(o)?i&&Wn(n)?o:o.value:z(o)?r?cr(o):Xn(o):o}}class rr extends sr{constructor(t=!1){super(!1,t)}set(t,n,s,r){let l=t[n];if(!this._isShallow){const f=ft(l);if(!Yt(s)&&!ft(s)&&(l=Z(l),s=Z(s)),!U(t)&&ae(l)&&!ae(s))return f?!1:(l.value=s,!0)}const i=U(t)&&Wn(n)?Number(n)<t.length:Y(t,n),o=Reflect.set(t,n,s,r);return t===Z(r)&&(i?Pe(s,l)&&ke(t,"set",n,s):ke(t,"add",n,s)),o}deleteProperty(t,n){const s=Y(t,n);t[n];const r=Reflect.deleteProperty(t,n);return r&&s&&ke(t,"delete",n,void 0),r}has(t,n){const s=Reflect.has(t,n);return(!Ke(n)||!nr.has(n))&&_e(t,"has",n),s}ownKeys(t){return _e(t,"iterate",U(t)?"length":Qe),Reflect.ownKeys(t)}}class Al extends sr{constructor(t=!1){super(!0,t)}set(t,n){return!0}deleteProperty(t,n){return!0}}const Fl=new rr,Rl=new Al,Il=new rr(!0),Zn=e=>e,on=e=>Reflect.getPrototypeOf(e);function Pt(e,t,n=!1,s=!1){e=e.__v_raw;const r=Z(e),l=Z(t);n||(Pe(t,l)&&_e(r,"get",t),_e(r,"get",l));const{has:i}=on(r),o=s?Zn:n?es:xt;if(i.call(r,t))return o(e.get(t));if(i.call(r,l))return o(e.get(l));e!==r&&e.get(t)}function Lt(e,t=!1){const n=this.__v_raw,s=Z(n),r=Z(e);return t||(Pe(e,r)&&_e(s,"has",e),_e(s,"has",r)),e===r?n.has(e):n.has(e)||n.has(r)}function Bt(e,t=!1){return e=e.__v_raw,!t&&_e(Z(e),"iterate",Qe),Reflect.get(e,"size",e)}function Ts(e){e=Z(e);const t=Z(this);return on(t).has.call(t,e)||(t.add(e),ke(t,"add",e,e)),this}function ws(e,t){t=Z(t);const n=Z(this),{has:s,get:r}=on(n);let l=s.call(n,e);l||(e=Z(e),l=s.call(n,e));const i=r.call(n,e);return n.set(e,t),l?Pe(t,i)&&ke(n,"set",e,t):ke(n,"add",e,t),this}function vs(e){const t=Z(this),{has:n,get:s}=on(t);let r=n.call(t,e);r||(e=Z(e),r=n.call(t,e)),s&&s.call(t,e);const l=t.delete(e);return r&&ke(t,"delete",e,void 0),l}function Es(){const e=Z(this),t=e.size!==0,n=e.clear();return t&&ke(e,"clear",void 0,void 0),n}function kt(e,t){return function(s,r){const l=this,i=l.__v_raw,o=Z(i),f=t?Zn:e?es:xt;return!e&&_e(o,"iterate",Qe),i.forEach((d,h)=>s.call(r,f(d),f(h),l))}}function Nt(e,t,n){return function(...s){const r=this.__v_raw,l=Z(r),i=st(l),o=e==="entries"||e===Symbol.iterator&&i,f=e==="keys"&&i,d=r[e](...s),h=n?Zn:t?es:xt;return!t&&_e(l,"iterate",f?On:Qe),{next(){const{value:a,done:g}=d.next();return g?{value:a,done:g}:{value:o?[h(a[0]),h(a[1])]:h(a),done:g}},[Symbol.iterator](){return this}}}}function Se(e){return function(...t){return e==="delete"?!1:e==="clear"?void 0:this}}function Ol(){const e={get(l){return Pt(this,l)},get size(){return Bt(this)},has:Lt,add:Ts,set:ws,delete:vs,clear:Es,forEach:kt(!1,!1)},t={get(l){return Pt(this,l,!1,!0)},get size(){return Bt(this)},has:Lt,add:Ts,set:ws,delete:vs,clear:Es,forEach:kt(!1,!0)},n={get(l){return Pt(this,l,!0)},get size(){return Bt(this,!0)},has(l){return Lt.call(this,l,!0)},add:Se("add"),set:Se("set"),delete:Se("delete"),clear:Se("clear"),forEach:kt(!0,!1)},s={get(l){return Pt(this,l,!0,!0)},get size(){return Bt(this,!0)},has(l){return Lt.call(this,l,!0)},add:Se("add"),set:Se("set"),delete:Se("delete"),clear:Se("clear"),forEach:kt(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach(l=>{e[l]=Nt(l,!1,!1),n[l]=Nt(l,!0,!1),t[l]=Nt(l,!1,!0),s[l]=Nt(l,!0,!0)}),[e,n,t,s]}const[Ml,Pl,Ll,Bl]=Ol();function Qn(e,t){const n=t?e?Bl:Ll:e?Pl:Ml;return(s,r,l)=>r==="__v_isReactive"?!e:r==="__v_isReadonly"?e:r==="__v_raw"?s:Reflect.get(Y(n,r)&&r in s?n:s,r,l)}const kl={get:Qn(!1,!1)},Nl={get:Qn(!1,!0)},Sl={get:Qn(!0,!1)},lr=new WeakMap,ir=new WeakMap,or=new WeakMap,jl=new WeakMap;function Ul(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function Hl(e){return e.__v_skip||!Object.isExtensible(e)?0:Ul(ol(e))}function Xn(e){return ft(e)?e:zn(e,!1,Fl,kl,lr)}function $l(e){return zn(e,!1,Il,Nl,ir)}function cr(e){return zn(e,!0,Rl,Sl,or)}function zn(e,t,n,s,r){if(!z(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;const l=r.get(e);if(l)return l;const i=Hl(e);if(i===0)return e;const o=new Proxy(e,i===2?s:n);return r.set(e,o),o}function lt(e){return ft(e)?lt(e.__v_raw):!!(e&&e.__v_isReactive)}function ft(e){return!!(e&&e.__v_isReadonly)}function Yt(e){return!!(e&&e.__v_isShallow)}function fr(e){return lt(e)||ft(e)}function Z(e){const t=e&&e.__v_raw;return t?Z(t):e}function ur(e){return Object.isExtensible(e)&&Gt(e,"__v_skip",!0),e}const xt=e=>z(e)?Xn(e):e,es=e=>z(e)?cr(e):e;class ar{constructor(t,n,s,r){this.getter=t,this._setter=n,this.dep=void 0,this.__v_isRef=!0,this.__v_isReadonly=!1,this.effect=new Gn(()=>t(this._value),()=>pt(this,this.effect._dirtyLevel===2?2:3)),this.effect.computed=this,this.effect.active=this._cacheable=!r,this.__v_isReadonly=s}get value(){const t=Z(this);return(!t._cacheable||t.effect.dirty)&&Pe(t._value,t._value=t.effect.run())&&pt(t,4),ts(t),t.effect._dirtyLevel>=2&&pt(t,2),t._value}set value(t){this._setter(t)}get _dirty(){return this.effect.dirty}set _dirty(t){this.effect.dirty=t}}function Vl(e,t,n=!1){let s,r;const l=$(e);return l?(s=e,r=Te):(s=e.get,r=e.set),new ar(s,r,l||!r,n)}function ts(e){var t;Ve&&Ze&&(e=Z(e),zs(Ze,(t=e.dep)!=null?t:e.dep=tr(()=>e.dep=void 0,e instanceof ar?e:void 0)))}function pt(e,t=4,n){e=Z(e);const s=e.dep;s&&er(s,t)}function ae(e){return!!(e&&e.__v_isRef===!0)}function Dt(e){return dr(e,!1)}function vo(e){return dr(e,!0)}function dr(e,t){return ae(e)?e:new Dl(e,t)}class Dl{constructor(t,n){this.__v_isShallow=n,this.dep=void 0,this.__v_isRef=!0,this._rawValue=n?t:Z(t),this._value=n?t:xt(t)}get value(){return ts(this),this._value}set value(t){const n=this.__v_isShallow||Yt(t)||ft(t);t=n?t:Z(t),Pe(t,this._rawValue)&&(this._rawValue=t,this._value=n?t:xt(t),pt(this,4))}}function Kl(e){return ae(e)?e.value:e}const Wl={get:(e,t,n)=>Kl(Reflect.get(e,t,n)),set:(e,t,n,s)=>{const r=e[t];return ae(r)&&!ae(n)?(r.value=n,!0):Reflect.set(e,t,n,s)}};function hr(e){return lt(e)?e:new Proxy(e,Wl)}class ql{constructor(t){this.dep=void 0,this.__v_isRef=!0;const{get:n,set:s}=t(()=>ts(this),()=>pt(this));this._get=n,this._set=s}get value(){return this._get()}set value(t){this._set(t)}}function Gl(e){return new ql(e)}class Jl{constructor(t,n,s){this._object=t,this._key=n,this._defaultValue=s,this.__v_isRef=!0}get value(){const t=this._object[this._key];return t===void 0?this._defaultValue:t}set value(t){this._object[this._key]=t}get dep(){return Tl(Z(this._object),this._key)}}class Yl{constructor(t){this._getter=t,this.__v_isRef=!0,this.__v_isReadonly=!0}get value(){return this._getter()}}function Eo(e,t,n){return ae(e)?e:$(e)?new Yl(e):z(e)&&arguments.length>1?Zl(e,t,n):Dt(e)}function Zl(e,t,n){const s=e[t];return ae(s)?s:new Jl(e,t,n)}/**
|
|
10
|
+
* @vue/runtime-core v3.4.21
|
|
11
|
+
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
12
|
+
* @license MIT
|
|
13
|
+
**/function De(e,t,n,s){try{return s?e(...s):e()}catch(r){dt(r,t,n)}}function Ee(e,t,n,s){if($(e)){const l=De(e,t,n,s);return l&&Ws(l)&&l.catch(i=>{dt(i,t,n)}),l}const r=[];for(let l=0;l<e.length;l++)r.push(Ee(e[l],t,n,s));return r}function dt(e,t,n,s=!0){const r=t?t.vnode:null;if(t){let l=t.parent;const i=t.proxy,o=`https://vuejs.org/error-reference/#runtime-${n}`;for(;l;){const d=l.ec;if(d){for(let h=0;h<d.length;h++)if(d[h](e,i,o)===!1)return}l=l.parent}const f=t.appContext.config.errorHandler;if(f){De(f,null,10,[e,i,o]);return}}Ql(e,n,r,s)}function Ql(e,t,n,s=!0){console.error(e)}let Ct=!1,Mn=!1;const ue=[];let Ie=0;const it=[];let Ue=null,Je=0;const gr=Promise.resolve();let ns=null;function Xl(e){const t=ns||gr;return e?t.then(this?e.bind(this):e):t}function zl(e){let t=Ie+1,n=ue.length;for(;t<n;){const s=t+n>>>1,r=ue[s],l=Tt(r);l<e||l===e&&r.pre?t=s+1:n=s}return t}function cn(e){(!ue.length||!ue.includes(e,Ct&&e.allowRecurse?Ie+1:Ie))&&(e.id==null?ue.push(e):ue.splice(zl(e.id),0,e),pr())}function pr(){!Ct&&!Mn&&(Mn=!0,ns=gr.then(_r))}function ei(e){const t=ue.indexOf(e);t>Ie&&ue.splice(t,1)}function Pn(e){U(e)?it.push(...e):(!Ue||!Ue.includes(e,e.allowRecurse?Je+1:Je))&&it.push(e),pr()}function As(e,t,n=Ct?Ie+1:0){for(;n<ue.length;n++){const s=ue[n];if(s&&s.pre){if(e&&s.id!==e.uid)continue;ue.splice(n,1),n--,s()}}}function Zt(e){if(it.length){const t=[...new Set(it)].sort((n,s)=>Tt(n)-Tt(s));if(it.length=0,Ue){Ue.push(...t);return}for(Ue=t,Je=0;Je<Ue.length;Je++)Ue[Je]();Ue=null,Je=0}}const Tt=e=>e.id==null?1/0:e.id,ti=(e,t)=>{const n=Tt(e)-Tt(t);if(n===0){if(e.pre&&!t.pre)return-1;if(t.pre&&!e.pre)return 1}return n};function _r(e){Mn=!1,Ct=!0,ue.sort(ti);try{for(Ie=0;Ie<ue.length;Ie++){const t=ue[Ie];t&&t.active!==!1&&De(t,null,14)}}finally{Ie=0,ue.length=0,Zt(),Ct=!1,ns=null,(ue.length||it.length)&&_r()}}function ni(e,t,...n){if(e.isUnmounted)return;const s=e.vnode.props||ee;let r=n;const l=t.startsWith("update:"),i=l&&t.slice(7);if(i&&i in s){const h=`${i==="modelValue"?"model":i}Modifiers`,{number:a,trim:g}=s[h]||ee;g&&(r=n.map(E=>le(E)?E.trim():E)),a&&(r=n.map(ul))}let o,f=s[o=mn(t)]||s[o=mn(Me(t))];!f&&l&&(f=s[o=mn(At(t))]),f&&Ee(f,e,6,r);const d=s[o+"Once"];if(d){if(!e.emitted)e.emitted={};else if(e.emitted[o])return;e.emitted[o]=!0,Ee(d,e,6,r)}}function yr(e,t,n=!1){const s=t.emitsCache,r=s.get(e);if(r!==void 0)return r;const l=e.emits;let i={},o=!1;if(!$(e)){const f=d=>{const h=yr(d,t,!0);h&&(o=!0,fe(i,h))};!n&&t.mixins.length&&t.mixins.forEach(f),e.extends&&f(e.extends),e.mixins&&e.mixins.forEach(f)}return!l&&!o?(z(e)&&s.set(e,null),null):(U(l)?l.forEach(f=>i[f]=null):fe(i,l),z(e)&&s.set(e,i),i)}function fn(e,t){return!e||!nn(t)?!1:(t=t.slice(2).replace(/Once$/,""),Y(e,t[0].toLowerCase()+t.slice(1))||Y(e,At(t))||Y(e,t))}let re=null,mr=null;function Qt(e){const t=re;return re=e,mr=e&&e.type.__scopeId||null,t}function si(e,t=re,n){if(!t||e._n)return e;const s=(...r)=>{s._d&&Hs(-1);const l=Qt(t);let i;try{i=e(...r)}finally{Qt(l),s._d&&Hs(1)}return i};return s._n=!0,s._c=!0,s._d=!0,s}function Cn(e){const{type:t,vnode:n,proxy:s,withProxy:r,props:l,propsOptions:[i],slots:o,attrs:f,emit:d,render:h,renderCache:a,data:g,setupState:E,ctx:I,inheritAttrs:B}=e;let D,q;const K=Qt(e);try{if(n.shapeFlag&4){const T=r||s,C=T;D=Ce(h.call(C,T,a,l,E,g,I)),q=f}else{const T=t;D=Ce(T.length>1?T(l,{attrs:f,slots:o,emit:d}):T(l,null)),q=t.props?f:li(f)}}catch(T){bt.length=0,dt(T,e,1),D=ne(he)}let _=D;if(q&&B!==!1){const T=Object.keys(q),{shapeFlag:C}=_;T.length&&C&7&&(i&&T.some(Ds)&&(q=ii(q,i)),_=We(_,q))}return n.dirs&&(_=We(_),_.dirs=_.dirs?_.dirs.concat(n.dirs):n.dirs),n.transition&&(_.transition=n.transition),D=_,Qt(K),D}function ri(e,t=!0){let n;for(let s=0;s<e.length;s++){const r=e[s];if(vt(r)){if(r.type!==he||r.children==="v-if"){if(n)return;n=r}}else return}return n}const li=e=>{let t;for(const n in e)(n==="class"||n==="style"||nn(n))&&((t||(t={}))[n]=e[n]);return t},ii=(e,t)=>{const n={};for(const s in e)(!Ds(s)||!(s.slice(9)in t))&&(n[s]=e[s]);return n};function oi(e,t,n){const{props:s,children:r,component:l}=e,{props:i,children:o,patchFlag:f}=t,d=l.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&f>=0){if(f&1024)return!0;if(f&16)return s?Fs(s,i,d):!!i;if(f&8){const h=t.dynamicProps;for(let a=0;a<h.length;a++){const g=h[a];if(i[g]!==s[g]&&!fn(d,g))return!0}}}else return(r||o)&&(!o||!o.$stable)?!0:s===i?!1:s?i?Fs(s,i,d):!0:!!i;return!1}function Fs(e,t,n){const s=Object.keys(t);if(s.length!==Object.keys(e).length)return!0;for(let r=0;r<s.length;r++){const l=s[r];if(t[l]!==e[l]&&!fn(n,l))return!0}return!1}function ss({vnode:e,parent:t},n){for(;t;){const s=t.subTree;if(s.suspense&&s.suspense.activeBranch===e&&(s.el=e.el),s===e)(e=t.vnode).el=n,t=t.parent;else break}}const rs="components";function Ao(e,t){return xr(rs,e,!0,t)||e}const br=Symbol.for("v-ndc");function Fo(e){return le(e)?xr(rs,e,!1)||e:e||br}function xr(e,t,n=!0,s=!1){const r=re||oe;if(r){const l=r.type;if(e===rs){const o=uo(l,!1);if(o&&(o===t||o===Me(t)||o===qn(Me(t))))return l}const i=Rs(r[e]||l[e],t)||Rs(r.appContext[e],t);return!i&&s?l:i}}function Rs(e,t){return e&&(e[t]||e[Me(t)]||e[qn(Me(t))])}const ci=e=>e.__isSuspense;let Ln=0;const fi={name:"Suspense",__isSuspense:!0,process(e,t,n,s,r,l,i,o,f,d){if(e==null)ui(t,n,s,r,l,i,o,f,d);else{if(l&&l.deps>0&&!e.suspense.isInFallback){t.suspense=e.suspense,t.suspense.vnode=t,t.el=e.el;return}ai(e,t,n,s,r,i,o,f,d)}},hydrate:di,create:ls,normalize:hi},Ro=fi;function wt(e,t){const n=e.props&&e.props[t];$(n)&&n()}function ui(e,t,n,s,r,l,i,o,f){const{p:d,o:{createElement:h}}=f,a=h("div"),g=e.suspense=ls(e,r,s,t,a,n,l,i,o,f);d(null,g.pendingBranch=e.ssContent,a,null,s,g,l,i),g.deps>0?(wt(e,"onPending"),wt(e,"onFallback"),d(null,e.ssFallback,t,n,s,null,l,i),ot(g,e.ssFallback)):g.resolve(!1,!0)}function ai(e,t,n,s,r,l,i,o,{p:f,um:d,o:{createElement:h}}){const a=t.suspense=e.suspense;a.vnode=t,t.el=e.el;const g=t.ssContent,E=t.ssFallback,{activeBranch:I,pendingBranch:B,isInFallback:D,isHydrating:q}=a;if(B)a.pendingBranch=g,Oe(g,B)?(f(B,g,a.hiddenContainer,null,r,a,l,i,o),a.deps<=0?a.resolve():D&&(q||(f(I,E,n,s,r,null,l,i,o),ot(a,E)))):(a.pendingId=Ln++,q?(a.isHydrating=!1,a.activeBranch=B):d(B,r,a),a.deps=0,a.effects.length=0,a.hiddenContainer=h("div"),D?(f(null,g,a.hiddenContainer,null,r,a,l,i,o),a.deps<=0?a.resolve():(f(I,E,n,s,r,null,l,i,o),ot(a,E))):I&&Oe(g,I)?(f(I,g,n,s,r,a,l,i,o),a.resolve(!0)):(f(null,g,a.hiddenContainer,null,r,a,l,i,o),a.deps<=0&&a.resolve()));else if(I&&Oe(g,I))f(I,g,n,s,r,a,l,i,o),ot(a,g);else if(wt(t,"onPending"),a.pendingBranch=g,g.shapeFlag&512?a.pendingId=g.component.suspenseId:a.pendingId=Ln++,f(null,g,a.hiddenContainer,null,r,a,l,i,o),a.deps<=0)a.resolve();else{const{timeout:K,pendingId:_}=a;K>0?setTimeout(()=>{a.pendingId===_&&a.fallback(E)},K):K===0&&a.fallback(E)}}function ls(e,t,n,s,r,l,i,o,f,d,h=!1){const{p:a,m:g,um:E,n:I,o:{parentNode:B,remove:D}}=d;let q;const K=gi(e);K&&t?.pendingBranch&&(q=t.pendingId,t.deps++);const _=e.props?al(e.props.timeout):void 0,T=l,C={vnode:e,parent:t,parentComponent:n,namespace:i,container:s,hiddenContainer:r,deps:0,pendingId:Ln++,timeout:typeof _=="number"?_:-1,activeBranch:null,pendingBranch:null,isInFallback:!h,isHydrating:h,isUnmounted:!1,effects:[],resolve(b=!1,L=!1){const{vnode:F,activeBranch:P,pendingBranch:O,pendingId:V,effects:J,parentComponent:Q,container:ce}=C;let se=!1;C.isHydrating?C.isHydrating=!1:b||(se=P&&O.transition&&O.transition.mode==="out-in",se&&(P.transition.afterLeave=()=>{V===C.pendingId&&(g(O,ce,l===T?I(P):l,0),Pn(J))}),P&&(B(P.el)!==C.hiddenContainer&&(l=I(P)),E(P,Q,C,!0)),se||g(O,ce,l,0)),ot(C,O),C.pendingBranch=null,C.isInFallback=!1;let k=C.parent,W=!1;for(;k;){if(k.pendingBranch){k.effects.push(...J),W=!0;break}k=k.parent}!W&&!se&&Pn(J),C.effects=[],K&&t&&t.pendingBranch&&q===t.pendingId&&(t.deps--,t.deps===0&&!L&&t.resolve()),wt(F,"onResolve")},fallback(b){if(!C.pendingBranch)return;const{vnode:L,activeBranch:F,parentComponent:P,container:O,namespace:V}=C;wt(L,"onFallback");const J=I(F),Q=()=>{C.isInFallback&&(a(null,b,O,J,P,null,V,o,f),ot(C,b))},ce=b.transition&&b.transition.mode==="out-in";ce&&(F.transition.afterLeave=Q),C.isInFallback=!0,E(F,P,null,!0),ce||Q()},move(b,L,F){C.activeBranch&&g(C.activeBranch,b,L,F),C.container=b},next(){return C.activeBranch&&I(C.activeBranch)},registerDep(b,L){const F=!!C.pendingBranch;F&&C.deps++;const P=b.vnode.el;b.asyncDep.catch(O=>{dt(O,b,0)}).then(O=>{if(b.isUnmounted||C.isUnmounted||C.pendingId!==b.suspenseId)return;b.asyncResolved=!0;const{vnode:V}=b;Vn(b,O,!1),P&&(V.el=P);const J=!P&&b.subTree.el;L(b,V,B(P||b.subTree.el),P?null:I(b.subTree),C,i,f),J&&D(J),ss(b,V.el),F&&--C.deps===0&&C.resolve()})},unmount(b,L){C.isUnmounted=!0,C.activeBranch&&E(C.activeBranch,n,b,L),C.pendingBranch&&E(C.pendingBranch,n,b,L)}};return C}function di(e,t,n,s,r,l,i,o,f){const d=t.suspense=ls(t,s,n,e.parentNode,document.createElement("div"),null,r,l,i,o,!0),h=f(e,d.pendingBranch=t.ssContent,n,d,l,i);return d.deps===0&&d.resolve(!1,!0),h}function hi(e){const{shapeFlag:t,children:n}=e,s=t&32;e.ssContent=Is(s?n.default:n),e.ssFallback=s?Is(n.fallback):ne(he)}function Is(e){let t;if($(e)){const n=at&&e._c;n&&(e._d=!1,fs()),e=e(),n&&(e._d=!0,t=we,$r())}return U(e)&&(e=ri(e)),e=Ce(e),t&&!e.dynamicChildren&&(e.dynamicChildren=t.filter(n=>n!==e)),e}function Cr(e,t){t&&t.pendingBranch?U(e)?t.effects.push(...e):t.effects.push(e):Pn(e)}function ot(e,t){e.activeBranch=t;const{vnode:n,parentComponent:s}=e;let r=t.el;for(;!r&&t.component;)t=t.component.subTree,r=t.el;n.el=r,s&&s.subTree===n&&(s.vnode.el=r,ss(s,r))}function gi(e){var t;return((t=e.props)==null?void 0:t.suspensible)!=null&&e.props.suspensible!==!1}const pi=Symbol.for("v-scx"),_i=()=>Kt(pi);function Io(e,t){return un(e,null,t)}function yi(e,t){return un(e,null,{flush:"sync"})}const St={};function Tn(e,t,n){return un(e,t,n)}function un(e,t,{immediate:n,deep:s,flush:r,once:l,onTrack:i,onTrigger:o}=ee){if(t&&l){const b=t;t=(...L)=>{b(...L),C()}}const f=oe,d=b=>s===!0?b:Ye(b,s===!1?1:void 0);let h,a=!1,g=!1;if(ae(e)?(h=()=>e.value,a=Yt(e)):lt(e)?(h=()=>d(e),a=!0):U(e)?(g=!0,a=e.some(b=>lt(b)||Yt(b)),h=()=>e.map(b=>{if(ae(b))return b.value;if(lt(b))return d(b);if($(b))return De(b,f,2)})):$(e)?t?h=()=>De(e,f,2):h=()=>(E&&E(),Ee(e,f,3,[I])):h=Te,t&&s){const b=h;h=()=>Ye(b())}let E,I=b=>{E=_.onStop=()=>{De(b,f,4),E=_.onStop=void 0}},B;if(It)if(I=Te,t?n&&Ee(t,f,3,[h(),g?[]:void 0,I]):h(),r==="sync"){const b=_i();B=b.__watcherHandles||(b.__watcherHandles=[])}else return Te;let D=g?new Array(e.length).fill(St):St;const q=()=>{if(!(!_.active||!_.dirty))if(t){const b=_.run();(s||a||(g?b.some((L,F)=>Pe(L,D[F])):Pe(b,D)))&&(E&&E(),Ee(t,f,3,[b,D===St?void 0:g&&D[0]===St?[]:D,I]),D=b)}else _.run()};q.allowRecurse=!!t;let K;r==="sync"?K=q:r==="post"?K=()=>ge(q,f&&f.suspense):(q.pre=!0,f&&(q.id=f.uid),K=()=>cn(q));const _=new Gn(h,Te,K),T=xl(),C=()=>{_.stop(),T&&Kn(T.effects,_)};return t?n?q():D=_.run():r==="post"?ge(_.run.bind(_),f&&f.suspense):_.run(),B&&B.push(C),C}function mi(e,t,n){const s=this.proxy,r=le(e)?e.includes(".")?Tr(s,e):()=>s[e]:e.bind(s,s);let l;$(t)?l=t:(l=t.handler,n=t);const i=Rt(this),o=un(r,l.bind(s),n);return i(),o}function Tr(e,t){const n=t.split(".");return()=>{let s=e;for(let r=0;r<n.length&&s;r++)s=s[n[r]];return s}}function Ye(e,t,n=0,s){if(!z(e)||e.__v_skip)return e;if(t&&t>0){if(n>=t)return e;n++}if(s=s||new Set,s.has(e))return e;if(s.add(e),ae(e))Ye(e.value,t,n,s);else if(U(e))for(let r=0;r<e.length;r++)Ye(e[r],t,n,s);else if(Ks(e)||st(e))e.forEach(r=>{Ye(r,t,n,s)});else if(Gs(e))for(const r in e)Ye(e[r],t,n,s);return e}function Oo(e,t){if(re===null)return e;const n=hn(re)||re.proxy,s=e.dirs||(e.dirs=[]);for(let r=0;r<t.length;r++){let[l,i,o,f=ee]=t[r];l&&($(l)&&(l={mounted:l,updated:l}),l.deep&&Ye(i),s.push({dir:l,instance:n,value:i,oldValue:void 0,arg:o,modifiers:f}))}return e}function Re(e,t,n,s){const r=e.dirs,l=t&&t.dirs;for(let i=0;i<r.length;i++){const o=r[i];l&&(o.oldValue=l[i].value);let f=o.dir[s];f&&(Xe(),Ee(f,n,8,[e.el,o,e,t]),ze())}}const He=Symbol("_leaveCb"),jt=Symbol("_enterCb");function bi(){const e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return Ar(()=>{e.isMounted=!0}),Fr(()=>{e.isUnmounting=!0}),e}const be=[Function,Array],xi={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:be,onEnter:be,onAfterEnter:be,onEnterCancelled:be,onBeforeLeave:be,onLeave:be,onAfterLeave:be,onLeaveCancelled:be,onBeforeAppear:be,onAppear:be,onAfterAppear:be,onAppearCancelled:be},Ci={name:"BaseTransition",props:xi,setup(e,{slots:t}){const n=Gr(),s=bi();return()=>{const r=t.default&&vr(t.default(),!0);if(!r||!r.length)return;let l=r[0];if(r.length>1){for(const g of r)if(g.type!==he){l=g;break}}const i=Z(e),{mode:o}=i;if(s.isLeaving)return wn(l);const f=Os(l);if(!f)return wn(l);const d=Bn(f,i,s,n);kn(f,d);const h=n.subTree,a=h&&Os(h);if(a&&a.type!==he&&!Oe(f,a)){const g=Bn(a,i,s,n);if(kn(a,g),o==="out-in")return s.isLeaving=!0,g.afterLeave=()=>{s.isLeaving=!1,n.update.active!==!1&&(n.effect.dirty=!0,n.update())},wn(l);o==="in-out"&&f.type!==he&&(g.delayLeave=(E,I,B)=>{const D=wr(s,a);D[String(a.key)]=a,E[He]=()=>{I(),E[He]=void 0,delete d.delayedLeave},d.delayedLeave=B})}return l}}},Mo=Ci;function wr(e,t){const{leavingVNodes:n}=e;let s=n.get(t.type);return s||(s=Object.create(null),n.set(t.type,s)),s}function Bn(e,t,n,s){const{appear:r,mode:l,persisted:i=!1,onBeforeEnter:o,onEnter:f,onAfterEnter:d,onEnterCancelled:h,onBeforeLeave:a,onLeave:g,onAfterLeave:E,onLeaveCancelled:I,onBeforeAppear:B,onAppear:D,onAfterAppear:q,onAppearCancelled:K}=t,_=String(e.key),T=wr(n,e),C=(F,P)=>{F&&Ee(F,s,9,P)},b=(F,P)=>{const O=P[1];C(F,P),U(F)?F.every(V=>V.length<=1)&&O():F.length<=1&&O()},L={mode:l,persisted:i,beforeEnter(F){let P=o;if(!n.isMounted)if(r)P=B||o;else return;F[He]&&F[He](!0);const O=T[_];O&&Oe(e,O)&&O.el[He]&&O.el[He](),C(P,[F])},enter(F){let P=f,O=d,V=h;if(!n.isMounted)if(r)P=D||f,O=q||d,V=K||h;else return;let J=!1;const Q=F[jt]=ce=>{J||(J=!0,ce?C(V,[F]):C(O,[F]),L.delayedLeave&&L.delayedLeave(),F[jt]=void 0)};P?b(P,[F,Q]):Q()},leave(F,P){const O=String(e.key);if(F[jt]&&F[jt](!0),n.isUnmounting)return P();C(a,[F]);let V=!1;const J=F[He]=Q=>{V||(V=!0,P(),Q?C(I,[F]):C(E,[F]),F[He]=void 0,T[O]===e&&delete T[O])};T[O]=e,g?b(g,[F,J]):J()},clone(F){return Bn(F,t,n,s)}};return L}function wn(e){if(Ft(e))return e=We(e),e.children=null,e}function Os(e){return Ft(e)?e.children?e.children[0]:void 0:e}function kn(e,t){e.shapeFlag&6&&e.component?kn(e.component.subTree,t):e.shapeFlag&128?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function vr(e,t=!1,n){let s=[],r=0;for(let l=0;l<e.length;l++){let i=e[l];const o=n==null?i.key:String(n)+String(i.key!=null?i.key:l);i.type===pe?(i.patchFlag&128&&r++,s=s.concat(vr(i.children,t,o))):(t||i.type!==he)&&s.push(o!=null?We(i,{key:o}):i)}if(r>1)for(let l=0;l<s.length;l++)s[l].patchFlag=-2;return s}/*! #__NO_SIDE_EFFECTS__ */function Ti(e,t){return $(e)?fe({name:e.name},t,{setup:e}):e}const ct=e=>!!e.type.__asyncLoader;/*! #__NO_SIDE_EFFECTS__ */function Po(e){$(e)&&(e={loader:e});const{loader:t,loadingComponent:n,errorComponent:s,delay:r=200,timeout:l,suspensible:i=!0,onError:o}=e;let f=null,d,h=0;const a=()=>(h++,f=null,g()),g=()=>{let E;return f||(E=f=t().catch(I=>{if(I=I instanceof Error?I:new Error(String(I)),o)return new Promise((B,D)=>{o(I,()=>B(a()),()=>D(I),h+1)});throw I}).then(I=>E!==f&&f?f:(I&&(I.__esModule||I[Symbol.toStringTag]==="Module")&&(I=I.default),d=I,I)))};return Ti({name:"AsyncComponentWrapper",__asyncLoader:g,get __asyncResolved(){return d},setup(){const E=oe;if(d)return()=>vn(d,E);const I=K=>{f=null,dt(K,E,13,!s)};if(i&&E.suspense||It)return g().then(K=>()=>vn(K,E)).catch(K=>(I(K),()=>s?ne(s,{error:K}):null));const B=Dt(!1),D=Dt(),q=Dt(!!r);return r&&setTimeout(()=>{q.value=!1},r),l!=null&&setTimeout(()=>{if(!B.value&&!D.value){const K=new Error(`Async component timed out after ${l}ms.`);I(K),D.value=K}},l),g().then(()=>{B.value=!0,E.parent&&Ft(E.parent.vnode)&&(E.parent.effect.dirty=!0,cn(E.parent.update))}).catch(K=>{I(K),D.value=K}),()=>{if(B.value&&d)return vn(d,E);if(D.value&&s)return ne(s,{error:D.value});if(n&&!q.value)return ne(n)}}})}function vn(e,t){const{ref:n,props:s,children:r,ce:l}=t.vnode,i=ne(e,s,r);return i.ref=n,i.ce=l,delete t.vnode.ce,i}const Ft=e=>e.type.__isKeepAlive;function wi(e,t){Er(e,"a",t)}function vi(e,t){Er(e,"da",t)}function Er(e,t,n=oe){const s=e.__wdc||(e.__wdc=()=>{let r=n;for(;r;){if(r.isDeactivated)return;r=r.parent}return e()});if(an(t,s,n),n){let r=n.parent;for(;r&&r.parent;)Ft(r.parent.vnode)&&Ei(s,t,n,r),r=r.parent}}function Ei(e,t,n,s){const r=an(t,e,s,!0);Rr(()=>{Kn(s[t],r)},n)}function an(e,t,n=oe,s=!1){if(n){const r=n[e]||(n[e]=[]),l=t.__weh||(t.__weh=(...i)=>{if(n.isUnmounted)return;Xe();const o=Rt(n),f=Ee(t,n,e,i);return o(),ze(),f});return s?r.unshift(l):r.push(l),l}}const Ne=e=>(t,n=oe)=>(!It||e==="sp")&&an(e,(...s)=>t(...s),n),Ai=Ne("bm"),Ar=Ne("m"),Fi=Ne("bu"),Ri=Ne("u"),Fr=Ne("bum"),Rr=Ne("um"),Ii=Ne("sp"),Oi=Ne("rtg"),Mi=Ne("rtc");function Pi(e,t=oe){an("ec",e,t)}function Lo(e,t,n,s){let r;const l=n&&n[s];if(U(e)||le(e)){r=new Array(e.length);for(let i=0,o=e.length;i<o;i++)r[i]=t(e[i],i,void 0,l&&l[i])}else if(typeof e=="number"){r=new Array(e);for(let i=0;i<e;i++)r[i]=t(i+1,i,void 0,l&&l[i])}else if(z(e))if(e[Symbol.iterator])r=Array.from(e,(i,o)=>t(i,o,void 0,l&&l[o]));else{const i=Object.keys(e);r=new Array(i.length);for(let o=0,f=i.length;o<f;o++){const d=i[o];r[o]=t(e[d],d,o,l&&l[o])}}else r=[];return n&&(n[s]=r),r}function Bo(e,t){for(let n=0;n<t.length;n++){const s=t[n];if(U(s))for(let r=0;r<s.length;r++)e[s[r].name]=s[r].fn;else s&&(e[s.name]=s.key?(...r)=>{const l=s.fn(...r);return l&&(l.key=s.key),l}:s.fn)}return e}function ko(e,t,n={},s,r){if(re.isCE||re.parent&&ct(re.parent)&&re.parent.isCE)return t!=="default"&&(n.name=t),ne("slot",n,s&&s());let l=e[t];l&&l._c&&(l._d=!1),fs();const i=l&&Ir(l(n)),o=Dr(pe,{key:n.key||i&&i.key||`_${t}`},i||(s?s():[]),i&&e._===1?64:-2);return!r&&o.scopeId&&(o.slotScopeIds=[o.scopeId+"-s"]),l&&l._c&&(l._d=!0),o}function Ir(e){return e.some(t=>vt(t)?!(t.type===he||t.type===pe&&!Ir(t.children)):!0)?e:null}const Nn=e=>e?Jr(e)?hn(e)||e.proxy:Nn(e.parent):null,_t=fe(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>Nn(e.parent),$root:e=>Nn(e.root),$emit:e=>e.emit,$options:e=>is(e),$forceUpdate:e=>e.f||(e.f=()=>{e.effect.dirty=!0,cn(e.update)}),$nextTick:e=>e.n||(e.n=Xl.bind(e.proxy)),$watch:e=>mi.bind(e)}),En=(e,t)=>e!==ee&&!e.__isScriptSetup&&Y(e,t),Li={get({_:e},t){const{ctx:n,setupState:s,data:r,props:l,accessCache:i,type:o,appContext:f}=e;let d;if(t[0]!=="$"){const E=i[t];if(E!==void 0)switch(E){case 1:return s[t];case 2:return r[t];case 4:return n[t];case 3:return l[t]}else{if(En(s,t))return i[t]=1,s[t];if(r!==ee&&Y(r,t))return i[t]=2,r[t];if((d=e.propsOptions[0])&&Y(d,t))return i[t]=3,l[t];if(n!==ee&&Y(n,t))return i[t]=4,n[t];Sn&&(i[t]=0)}}const h=_t[t];let a,g;if(h)return t==="$attrs"&&_e(e,"get",t),h(e);if((a=o.__cssModules)&&(a=a[t]))return a;if(n!==ee&&Y(n,t))return i[t]=4,n[t];if(g=f.config.globalProperties,Y(g,t))return g[t]},set({_:e},t,n){const{data:s,setupState:r,ctx:l}=e;return En(r,t)?(r[t]=n,!0):s!==ee&&Y(s,t)?(s[t]=n,!0):Y(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(l[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:s,appContext:r,propsOptions:l}},i){let o;return!!n[i]||e!==ee&&Y(e,i)||En(t,i)||(o=l[0])&&Y(o,i)||Y(s,i)||Y(_t,i)||Y(r.config.globalProperties,i)},defineProperty(e,t,n){return n.get!=null?e._.accessCache[t]=0:Y(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}};function Xt(e){return U(e)?e.reduce((t,n)=>(t[n]=null,t),{}):e}function No(e,t){return!e||!t?e||t:U(e)&&U(t)?e.concat(t):fe({},Xt(e),Xt(t))}let Sn=!0;function Bi(e){const t=is(e),n=e.proxy,s=e.ctx;Sn=!1,t.beforeCreate&&Ms(t.beforeCreate,e,"bc");const{data:r,computed:l,methods:i,watch:o,provide:f,inject:d,created:h,beforeMount:a,mounted:g,beforeUpdate:E,updated:I,activated:B,deactivated:D,beforeDestroy:q,beforeUnmount:K,destroyed:_,unmounted:T,render:C,renderTracked:b,renderTriggered:L,errorCaptured:F,serverPrefetch:P,expose:O,inheritAttrs:V,components:J,directives:Q,filters:ce}=t;if(d&&ki(d,s,null),i)for(const W in i){const S=i[W];$(S)&&(s[W]=S.bind(n))}if(r){const W=r.call(n,n);z(W)&&(e.data=Xn(W))}if(Sn=!0,l)for(const W in l){const S=l[W],Le=$(S)?S.bind(n,n):$(S.get)?S.get.bind(n,n):Te,Ot=!$(S)&&$(S.set)?S.set.bind(n):Te,qe=ho({get:Le,set:Ot});Object.defineProperty(s,W,{enumerable:!0,configurable:!0,get:()=>qe.value,set:Ae=>qe.value=Ae})}if(o)for(const W in o)Or(o[W],s,n,W);if(f){const W=$(f)?f.call(n):f;Reflect.ownKeys(W).forEach(S=>{$i(S,W[S])})}h&&Ms(h,e,"c");function k(W,S){U(S)?S.forEach(Le=>W(Le.bind(n))):S&&W(S.bind(n))}if(k(Ai,a),k(Ar,g),k(Fi,E),k(Ri,I),k(wi,B),k(vi,D),k(Pi,F),k(Mi,b),k(Oi,L),k(Fr,K),k(Rr,T),k(Ii,P),U(O))if(O.length){const W=e.exposed||(e.exposed={});O.forEach(S=>{Object.defineProperty(W,S,{get:()=>n[S],set:Le=>n[S]=Le})})}else e.exposed||(e.exposed={});C&&e.render===Te&&(e.render=C),V!=null&&(e.inheritAttrs=V),J&&(e.components=J),Q&&(e.directives=Q)}function ki(e,t,n=Te){U(e)&&(e=jn(e));for(const s in e){const r=e[s];let l;z(r)?"default"in r?l=Kt(r.from||s,r.default,!0):l=Kt(r.from||s):l=Kt(r),ae(l)?Object.defineProperty(t,s,{enumerable:!0,configurable:!0,get:()=>l.value,set:i=>l.value=i}):t[s]=l}}function Ms(e,t,n){Ee(U(e)?e.map(s=>s.bind(t.proxy)):e.bind(t.proxy),t,n)}function Or(e,t,n,s){const r=s.includes(".")?Tr(n,s):()=>n[s];if(le(e)){const l=t[e];$(l)&&Tn(r,l)}else if($(e))Tn(r,e.bind(n));else if(z(e))if(U(e))e.forEach(l=>Or(l,t,n,s));else{const l=$(e.handler)?e.handler.bind(n):t[e.handler];$(l)&&Tn(r,l,e)}}function is(e){const t=e.type,{mixins:n,extends:s}=t,{mixins:r,optionsCache:l,config:{optionMergeStrategies:i}}=e.appContext,o=l.get(t);let f;return o?f=o:!r.length&&!n&&!s?f=t:(f={},r.length&&r.forEach(d=>zt(f,d,i,!0)),zt(f,t,i)),z(t)&&l.set(t,f),f}function zt(e,t,n,s=!1){const{mixins:r,extends:l}=t;l&&zt(e,l,n,!0),r&&r.forEach(i=>zt(e,i,n,!0));for(const i in t)if(!(s&&i==="expose")){const o=Ni[i]||n&&n[i];e[i]=o?o(e[i],t[i]):t[i]}return e}const Ni={data:Ps,props:Ls,emits:Ls,methods:gt,computed:gt,beforeCreate:de,created:de,beforeMount:de,mounted:de,beforeUpdate:de,updated:de,beforeDestroy:de,beforeUnmount:de,destroyed:de,unmounted:de,activated:de,deactivated:de,errorCaptured:de,serverPrefetch:de,components:gt,directives:gt,watch:ji,provide:Ps,inject:Si};function Ps(e,t){return t?e?function(){return fe($(e)?e.call(this,this):e,$(t)?t.call(this,this):t)}:t:e}function Si(e,t){return gt(jn(e),jn(t))}function jn(e){if(U(e)){const t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function de(e,t){return e?[...new Set([].concat(e,t))]:t}function gt(e,t){return e?fe(Object.create(null),e,t):t}function Ls(e,t){return e?U(e)&&U(t)?[...new Set([...e,...t])]:fe(Object.create(null),Xt(e),Xt(t??{})):t}function ji(e,t){if(!e)return t;if(!t)return e;const n=fe(Object.create(null),e);for(const s in t)n[s]=de(e[s],t[s]);return n}function Mr(){return{app:null,config:{isNativeTag:ll,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}let Ui=0;function Hi(e,t){return function(s,r=null){$(s)||(s=fe({},s)),r!=null&&!z(r)&&(r=null);const l=Mr(),i=new WeakSet;let o=!1;const f=l.app={_uid:Ui++,_component:s,_props:r,_container:null,_context:l,_instance:null,version:go,get config(){return l.config},set config(d){},use(d,...h){return i.has(d)||(d&&$(d.install)?(i.add(d),d.install(f,...h)):$(d)&&(i.add(d),d(f,...h))),f},mixin(d){return l.mixins.includes(d)||l.mixins.push(d),f},component(d,h){return h?(l.components[d]=h,f):l.components[d]},directive(d,h){return h?(l.directives[d]=h,f):l.directives[d]},mount(d,h,a){if(!o){const g=ne(s,r);return g.appContext=l,a===!0?a="svg":a===!1&&(a=void 0),h&&t?t(g,d):e(g,d,a),o=!0,f._container=d,d.__vue_app__=f,hn(g.component)||g.component.proxy}},unmount(){o&&(e(null,f._container),delete f._container.__vue_app__)},provide(d,h){return l.provides[d]=h,f},runWithContext(d){const h=yt;yt=f;try{return d()}finally{yt=h}}};return f}}let yt=null;function $i(e,t){if(oe){let n=oe.provides;const s=oe.parent&&oe.parent.provides;s===n&&(n=oe.provides=Object.create(s)),n[e]=t}}function Kt(e,t,n=!1){const s=oe||re;if(s||yt){const r=s?s.parent==null?s.vnode.appContext&&s.vnode.appContext.provides:s.parent.provides:yt._context.provides;if(r&&e in r)return r[e];if(arguments.length>1)return n&&$(t)?t.call(s&&s.proxy):t}}function Vi(e,t,n,s=!1){const r={},l={};Gt(l,dn,1),e.propsDefaults=Object.create(null),Pr(e,t,r,l);for(const i in e.propsOptions[0])i in r||(r[i]=void 0);n?e.props=s?r:$l(r):e.type.props?e.props=r:e.props=l,e.attrs=l}function Di(e,t,n,s){const{props:r,attrs:l,vnode:{patchFlag:i}}=e,o=Z(r),[f]=e.propsOptions;let d=!1;if((s||i>0)&&!(i&16)){if(i&8){const h=e.vnode.dynamicProps;for(let a=0;a<h.length;a++){let g=h[a];if(fn(e.emitsOptions,g))continue;const E=t[g];if(f)if(Y(l,g))E!==l[g]&&(l[g]=E,d=!0);else{const I=Me(g);r[I]=Un(f,o,I,E,e,!1)}else E!==l[g]&&(l[g]=E,d=!0)}}}else{Pr(e,t,r,l)&&(d=!0);let h;for(const a in o)(!t||!Y(t,a)&&((h=At(a))===a||!Y(t,h)))&&(f?n&&(n[a]!==void 0||n[h]!==void 0)&&(r[a]=Un(f,o,a,void 0,e,!0)):delete r[a]);if(l!==o)for(const a in l)(!t||!Y(t,a))&&(delete l[a],d=!0)}d&&ke(e,"set","$attrs")}function Pr(e,t,n,s){const[r,l]=e.propsOptions;let i=!1,o;if(t)for(let f in t){if(rt(f))continue;const d=t[f];let h;r&&Y(r,h=Me(f))?!l||!l.includes(h)?n[h]=d:(o||(o={}))[h]=d:fn(e.emitsOptions,f)||(!(f in s)||d!==s[f])&&(s[f]=d,i=!0)}if(l){const f=Z(n),d=o||ee;for(let h=0;h<l.length;h++){const a=l[h];n[a]=Un(r,f,a,d[a],e,!Y(d,a))}}return i}function Un(e,t,n,s,r,l){const i=e[n];if(i!=null){const o=Y(i,"default");if(o&&s===void 0){const f=i.default;if(i.type!==Function&&!i.skipFactory&&$(f)){const{propsDefaults:d}=r;if(n in d)s=d[n];else{const h=Rt(r);s=d[n]=f.call(null,t),h()}}else s=f}i[0]&&(l&&!o?s=!1:i[1]&&(s===""||s===At(n))&&(s=!0))}return s}function Lr(e,t,n=!1){const s=t.propsCache,r=s.get(e);if(r)return r;const l=e.props,i={},o=[];let f=!1;if(!$(e)){const h=a=>{f=!0;const[g,E]=Lr(a,t,!0);fe(i,g),E&&o.push(...E)};!n&&t.mixins.length&&t.mixins.forEach(h),e.extends&&h(e.extends),e.mixins&&e.mixins.forEach(h)}if(!l&&!f)return z(e)&&s.set(e,nt),nt;if(U(l))for(let h=0;h<l.length;h++){const a=Me(l[h]);Bs(a)&&(i[a]=ee)}else if(l)for(const h in l){const a=Me(h);if(Bs(a)){const g=l[h],E=i[a]=U(g)||$(g)?{type:g}:fe({},g);if(E){const I=Ss(Boolean,E.type),B=Ss(String,E.type);E[0]=I>-1,E[1]=B<0||I<B,(I>-1||Y(E,"default"))&&o.push(a)}}}const d=[i,o];return z(e)&&s.set(e,d),d}function Bs(e){return e[0]!=="$"&&!rt(e)}function ks(e){return e===null?"null":typeof e=="function"?e.name||"":typeof e=="object"&&e.constructor&&e.constructor.name||""}function Ns(e,t){return ks(e)===ks(t)}function Ss(e,t){return U(t)?t.findIndex(n=>Ns(n,e)):$(t)&&Ns(t,e)?0:-1}const Br=e=>e[0]==="_"||e==="$stable",os=e=>U(e)?e.map(Ce):[Ce(e)],Ki=(e,t,n)=>{if(t._n)return t;const s=si((...r)=>os(t(...r)),n);return s._c=!1,s},kr=(e,t,n)=>{const s=e._ctx;for(const r in e){if(Br(r))continue;const l=e[r];if($(l))t[r]=Ki(r,l,s);else if(l!=null){const i=os(l);t[r]=()=>i}}},Nr=(e,t)=>{const n=os(t);e.slots.default=()=>n},Wi=(e,t)=>{if(e.vnode.shapeFlag&32){const n=t._;n?(e.slots=Z(t),Gt(t,"_",n)):kr(t,e.slots={})}else e.slots={},t&&Nr(e,t);Gt(e.slots,dn,1)},qi=(e,t,n)=>{const{vnode:s,slots:r}=e;let l=!0,i=ee;if(s.shapeFlag&32){const o=t._;o?n&&o===1?l=!1:(fe(r,t),!n&&o===1&&delete r._):(l=!t.$stable,kr(t,r)),i=t}else t&&(Nr(e,t),i={default:1});if(l)for(const o in r)!Br(o)&&i[o]==null&&delete r[o]};function en(e,t,n,s,r=!1){if(U(e)){e.forEach((g,E)=>en(g,t&&(U(t)?t[E]:t),n,s,r));return}if(ct(s)&&!r)return;const l=s.shapeFlag&4?hn(s.component)||s.component.proxy:s.el,i=r?null:l,{i:o,r:f}=e,d=t&&t.r,h=o.refs===ee?o.refs={}:o.refs,a=o.setupState;if(d!=null&&d!==f&&(le(d)?(h[d]=null,Y(a,d)&&(a[d]=null)):ae(d)&&(d.value=null)),$(f))De(f,o,12,[i,h]);else{const g=le(f),E=ae(f);if(g||E){const I=()=>{if(e.f){const B=g?Y(a,f)?a[f]:h[f]:f.value;r?U(B)&&Kn(B,l):U(B)?B.includes(l)||B.push(l):g?(h[f]=[l],Y(a,f)&&(a[f]=h[f])):(f.value=[l],e.k&&(h[e.k]=f.value))}else g?(h[f]=i,Y(a,f)&&(a[f]=i)):E&&(f.value=i,e.k&&(h[e.k]=i))};i?(I.id=-1,ge(I,n)):I()}}}let je=!1;const Gi=e=>e.namespaceURI.includes("svg")&&e.tagName!=="foreignObject",Ji=e=>e.namespaceURI.includes("MathML"),Ut=e=>{if(Gi(e))return"svg";if(Ji(e))return"mathml"},Ht=e=>e.nodeType===8;function Yi(e){const{mt:t,p:n,o:{patchProp:s,createText:r,nextSibling:l,parentNode:i,remove:o,insert:f,createComment:d}}=e,h=(_,T)=>{if(!T.hasChildNodes()){n(null,_,T),Zt(),T._vnode=_;return}je=!1,a(T.firstChild,_,null,null,null),Zt(),T._vnode=_,je&&console.error("Hydration completed but contains mismatches.")},a=(_,T,C,b,L,F=!1)=>{const P=Ht(_)&&_.data==="[",O=()=>B(_,T,C,b,L,P),{type:V,ref:J,shapeFlag:Q,patchFlag:ce}=T;let se=_.nodeType;T.el=_,ce===-2&&(F=!1,T.dynamicChildren=null);let k=null;switch(V){case ut:se!==3?T.children===""?(f(T.el=r(""),i(_),_),k=_):k=O():(_.data!==T.children&&(je=!0,_.data=T.children),k=l(_));break;case he:K(_)?(k=l(_),q(T.el=_.content.firstChild,_,C)):se!==8||P?k=O():k=l(_);break;case Wt:if(P&&(_=l(_),se=_.nodeType),se===1||se===3){k=_;const W=!T.children.length;for(let S=0;S<T.staticCount;S++)W&&(T.children+=k.nodeType===1?k.outerHTML:k.data),S===T.staticCount-1&&(T.anchor=k),k=l(k);return P?l(k):k}else O();break;case pe:P?k=I(_,T,C,b,L,F):k=O();break;default:if(Q&1)(se!==1||T.type.toLowerCase()!==_.tagName.toLowerCase())&&!K(_)?k=O():k=g(_,T,C,b,L,F);else if(Q&6){T.slotScopeIds=L;const W=i(_);if(P?k=D(_):Ht(_)&&_.data==="teleport start"?k=D(_,_.data,"teleport end"):k=l(_),t(T,W,null,C,b,Ut(W),F),ct(T)){let S;P?(S=ne(pe),S.anchor=k?k.previousSibling:W.lastChild):S=_.nodeType===3?qr(""):ne("div"),S.el=_,T.component.subTree=S}}else Q&64?se!==8?k=O():k=T.type.hydrate(_,T,C,b,L,F,e,E):Q&128&&(k=T.type.hydrate(_,T,C,b,Ut(i(_)),L,F,e,a))}return J!=null&&en(J,null,b,T),k},g=(_,T,C,b,L,F)=>{F=F||!!T.dynamicChildren;const{type:P,props:O,patchFlag:V,shapeFlag:J,dirs:Q,transition:ce}=T,se=P==="input"||P==="option";if(se||V!==-1){Q&&Re(T,null,C,"created");let k=!1;if(K(_)){k=jr(b,ce)&&C&&C.vnode.props&&C.vnode.props.appear;const S=_.content.firstChild;k&&ce.beforeEnter(S),q(S,_,C),T.el=_=S}if(J&16&&!(O&&(O.innerHTML||O.textContent))){let S=E(_.firstChild,T,_,C,b,L,F);for(;S;){je=!0;const Le=S;S=S.nextSibling,o(Le)}}else J&8&&_.textContent!==T.children&&(je=!0,_.textContent=T.children);if(O)if(se||!F||V&48)for(const S in O)(se&&(S.endsWith("value")||S==="indeterminate")||nn(S)&&!rt(S)||S[0]===".")&&s(_,S,null,O[S],void 0,void 0,C);else O.onClick&&s(_,"onClick",null,O.onClick,void 0,void 0,C);let W;(W=O&&O.onVnodeBeforeMount)&&xe(W,C,T),Q&&Re(T,null,C,"beforeMount"),((W=O&&O.onVnodeMounted)||Q||k)&&Cr(()=>{W&&xe(W,C,T),k&&ce.enter(_),Q&&Re(T,null,C,"mounted")},b)}return _.nextSibling},E=(_,T,C,b,L,F,P)=>{P=P||!!T.dynamicChildren;const O=T.children,V=O.length;for(let J=0;J<V;J++){const Q=P?O[J]:O[J]=Ce(O[J]);if(_)_=a(_,Q,b,L,F,P);else{if(Q.type===ut&&!Q.children)continue;je=!0,n(null,Q,C,null,b,L,Ut(C),F)}}return _},I=(_,T,C,b,L,F)=>{const{slotScopeIds:P}=T;P&&(L=L?L.concat(P):P);const O=i(_),V=E(l(_),T,O,C,b,L,F);return V&&Ht(V)&&V.data==="]"?l(T.anchor=V):(je=!0,f(T.anchor=d("]"),O,V),V)},B=(_,T,C,b,L,F)=>{if(je=!0,T.el=null,F){const V=D(_);for(;;){const J=l(_);if(J&&J!==V)o(J);else break}}const P=l(_),O=i(_);return o(_),n(null,T,O,P,C,b,Ut(O),L),P},D=(_,T="[",C="]")=>{let b=0;for(;_;)if(_=l(_),_&&Ht(_)&&(_.data===T&&b++,_.data===C)){if(b===0)return l(_);b--}return _},q=(_,T,C)=>{const b=T.parentNode;b&&b.replaceChild(_,T);let L=C;for(;L;)L.vnode.el===T&&(L.vnode.el=L.subTree.el=_),L=L.parent},K=_=>_.nodeType===1&&_.tagName.toLowerCase()==="template";return[h,a]}const ge=Cr;function So(e){return Sr(e)}function jo(e){return Sr(e,Yi)}function Sr(e,t){const n=Js();n.__VUE__=!0;const{insert:s,remove:r,patchProp:l,createElement:i,createText:o,createComment:f,setText:d,setElementText:h,parentNode:a,nextSibling:g,setScopeId:E=Te,insertStaticContent:I}=e,B=(c,u,p,y=null,m=null,v=null,R=void 0,w=null,A=!!u.dynamicChildren)=>{if(c===u)return;c&&!Oe(c,u)&&(y=Mt(c),Ae(c,m,v,!0),c=null),u.patchFlag===-2&&(A=!1,u.dynamicChildren=null);const{type:x,ref:M,shapeFlag:j}=u;switch(x){case ut:D(c,u,p,y);break;case he:q(c,u,p,y);break;case Wt:c==null&&K(u,p,y,R);break;case pe:J(c,u,p,y,m,v,R,w,A);break;default:j&1?C(c,u,p,y,m,v,R,w,A):j&6?Q(c,u,p,y,m,v,R,w,A):(j&64||j&128)&&x.process(c,u,p,y,m,v,R,w,A,et)}M!=null&&m&&en(M,c&&c.ref,v,u||c,!u)},D=(c,u,p,y)=>{if(c==null)s(u.el=o(u.children),p,y);else{const m=u.el=c.el;u.children!==c.children&&d(m,u.children)}},q=(c,u,p,y)=>{c==null?s(u.el=f(u.children||""),p,y):u.el=c.el},K=(c,u,p,y)=>{[c.el,c.anchor]=I(c.children,u,p,y,c.el,c.anchor)},_=({el:c,anchor:u},p,y)=>{let m;for(;c&&c!==u;)m=g(c),s(c,p,y),c=m;s(u,p,y)},T=({el:c,anchor:u})=>{let p;for(;c&&c!==u;)p=g(c),r(c),c=p;r(u)},C=(c,u,p,y,m,v,R,w,A)=>{u.type==="svg"?R="svg":u.type==="math"&&(R="mathml"),c==null?b(u,p,y,m,v,R,w,A):P(c,u,m,v,R,w,A)},b=(c,u,p,y,m,v,R,w)=>{let A,x;const{props:M,shapeFlag:j,transition:N,dirs:H}=c;if(A=c.el=i(c.type,v,M&&M.is,M),j&8?h(A,c.children):j&16&&F(c.children,A,null,y,m,An(c,v),R,w),H&&Re(c,null,y,"created"),L(A,c,c.scopeId,R,y),M){for(const X in M)X!=="value"&&!rt(X)&&l(A,X,null,M[X],v,c.children,y,m,Be);"value"in M&&l(A,"value",null,M.value,v),(x=M.onVnodeBeforeMount)&&xe(x,y,c)}H&&Re(c,null,y,"beforeMount");const G=jr(m,N);G&&N.beforeEnter(A),s(A,u,p),((x=M&&M.onVnodeMounted)||G||H)&&ge(()=>{x&&xe(x,y,c),G&&N.enter(A),H&&Re(c,null,y,"mounted")},m)},L=(c,u,p,y,m)=>{if(p&&E(c,p),y)for(let v=0;v<y.length;v++)E(c,y[v]);if(m){let v=m.subTree;if(u===v){const R=m.vnode;L(c,R,R.scopeId,R.slotScopeIds,m.parent)}}},F=(c,u,p,y,m,v,R,w,A=0)=>{for(let x=A;x<c.length;x++){const M=c[x]=w?$e(c[x]):Ce(c[x]);B(null,M,u,p,y,m,v,R,w)}},P=(c,u,p,y,m,v,R)=>{const w=u.el=c.el;let{patchFlag:A,dynamicChildren:x,dirs:M}=u;A|=c.patchFlag&16;const j=c.props||ee,N=u.props||ee;let H;if(p&&Ge(p,!1),(H=N.onVnodeBeforeUpdate)&&xe(H,p,u,c),M&&Re(u,c,p,"beforeUpdate"),p&&Ge(p,!0),x?O(c.dynamicChildren,x,w,p,y,An(u,m),v):R||S(c,u,w,null,p,y,An(u,m),v,!1),A>0){if(A&16)V(w,u,j,N,p,y,m);else if(A&2&&j.class!==N.class&&l(w,"class",null,N.class,m),A&4&&l(w,"style",j.style,N.style,m),A&8){const G=u.dynamicProps;for(let X=0;X<G.length;X++){const te=G[X],ie=j[te],ve=N[te];(ve!==ie||te==="value")&&l(w,te,ie,ve,m,c.children,p,y,Be)}}A&1&&c.children!==u.children&&h(w,u.children)}else!R&&x==null&&V(w,u,j,N,p,y,m);((H=N.onVnodeUpdated)||M)&&ge(()=>{H&&xe(H,p,u,c),M&&Re(u,c,p,"updated")},y)},O=(c,u,p,y,m,v,R)=>{for(let w=0;w<u.length;w++){const A=c[w],x=u[w],M=A.el&&(A.type===pe||!Oe(A,x)||A.shapeFlag&70)?a(A.el):p;B(A,x,M,null,y,m,v,R,!0)}},V=(c,u,p,y,m,v,R)=>{if(p!==y){if(p!==ee)for(const w in p)!rt(w)&&!(w in y)&&l(c,w,p[w],null,R,u.children,m,v,Be);for(const w in y){if(rt(w))continue;const A=y[w],x=p[w];A!==x&&w!=="value"&&l(c,w,x,A,R,u.children,m,v,Be)}"value"in y&&l(c,"value",p.value,y.value,R)}},J=(c,u,p,y,m,v,R,w,A)=>{const x=u.el=c?c.el:o(""),M=u.anchor=c?c.anchor:o("");let{patchFlag:j,dynamicChildren:N,slotScopeIds:H}=u;H&&(w=w?w.concat(H):H),c==null?(s(x,p,y),s(M,p,y),F(u.children||[],p,M,m,v,R,w,A)):j>0&&j&64&&N&&c.dynamicChildren?(O(c.dynamicChildren,N,p,m,v,R,w),(u.key!=null||m&&u===m.subTree)&&cs(c,u,!0)):S(c,u,p,M,m,v,R,w,A)},Q=(c,u,p,y,m,v,R,w,A)=>{u.slotScopeIds=w,c==null?u.shapeFlag&512?m.ctx.activate(u,p,y,R,A):ce(u,p,y,m,v,R,A):se(c,u,A)},ce=(c,u,p,y,m,v,R)=>{const w=c.component=lo(c,y,m);if(Ft(c)&&(w.ctx.renderer=et),io(w),w.asyncDep){if(m&&m.registerDep(w,k),!c.el){const A=w.subTree=ne(he);q(null,A,u,p)}}else k(w,c,u,p,m,v,R)},se=(c,u,p)=>{const y=u.component=c.component;if(oi(c,u,p))if(y.asyncDep&&!y.asyncResolved){W(y,u,p);return}else y.next=u,ei(y.update),y.effect.dirty=!0,y.update();else u.el=c.el,y.vnode=u},k=(c,u,p,y,m,v,R)=>{const w=()=>{if(c.isMounted){let{next:M,bu:j,u:N,parent:H,vnode:G}=c;{const tt=Ur(c);if(tt){M&&(M.el=G.el,W(c,M,R)),tt.asyncDep.then(()=>{c.isUnmounted||w()});return}}let X=M,te;Ge(c,!1),M?(M.el=G.el,W(c,M,R)):M=G,j&&bn(j),(te=M.props&&M.props.onVnodeBeforeUpdate)&&xe(te,H,M,G),Ge(c,!0);const ie=Cn(c),ve=c.subTree;c.subTree=ie,B(ve,ie,a(ve.el),Mt(ve),c,m,v),M.el=ie.el,X===null&&ss(c,ie.el),N&&ge(N,m),(te=M.props&&M.props.onVnodeUpdated)&&ge(()=>xe(te,H,M,G),m)}else{let M;const{el:j,props:N}=u,{bm:H,m:G,parent:X}=c,te=ct(u);if(Ge(c,!1),H&&bn(H),!te&&(M=N&&N.onVnodeBeforeMount)&&xe(M,X,u),Ge(c,!0),j&&_n){const ie=()=>{c.subTree=Cn(c),_n(j,c.subTree,c,m,null)};te?u.type.__asyncLoader().then(()=>!c.isUnmounted&&ie()):ie()}else{const ie=c.subTree=Cn(c);B(null,ie,p,y,c,m,v),u.el=ie.el}if(G&&ge(G,m),!te&&(M=N&&N.onVnodeMounted)){const ie=u;ge(()=>xe(M,X,ie),m)}(u.shapeFlag&256||X&&ct(X.vnode)&&X.vnode.shapeFlag&256)&&c.a&&ge(c.a,m),c.isMounted=!0,u=p=y=null}},A=c.effect=new Gn(w,Te,()=>cn(x),c.scope),x=c.update=()=>{A.dirty&&A.run()};x.id=c.uid,Ge(c,!0),x()},W=(c,u,p)=>{u.component=c;const y=c.vnode.props;c.vnode=u,c.next=null,Di(c,u.props,y,p),qi(c,u.children,p),Xe(),As(c),ze()},S=(c,u,p,y,m,v,R,w,A=!1)=>{const x=c&&c.children,M=c?c.shapeFlag:0,j=u.children,{patchFlag:N,shapeFlag:H}=u;if(N>0){if(N&128){Ot(x,j,p,y,m,v,R,w,A);return}else if(N&256){Le(x,j,p,y,m,v,R,w,A);return}}H&8?(M&16&&Be(x,m,v),j!==x&&h(p,j)):M&16?H&16?Ot(x,j,p,y,m,v,R,w,A):Be(x,m,v,!0):(M&8&&h(p,""),H&16&&F(j,p,y,m,v,R,w,A))},Le=(c,u,p,y,m,v,R,w,A)=>{c=c||nt,u=u||nt;const x=c.length,M=u.length,j=Math.min(x,M);let N;for(N=0;N<j;N++){const H=u[N]=A?$e(u[N]):Ce(u[N]);B(c[N],H,p,null,m,v,R,w,A)}x>M?Be(c,m,v,!0,!1,j):F(u,p,y,m,v,R,w,A,j)},Ot=(c,u,p,y,m,v,R,w,A)=>{let x=0;const M=u.length;let j=c.length-1,N=M-1;for(;x<=j&&x<=N;){const H=c[x],G=u[x]=A?$e(u[x]):Ce(u[x]);if(Oe(H,G))B(H,G,p,null,m,v,R,w,A);else break;x++}for(;x<=j&&x<=N;){const H=c[j],G=u[N]=A?$e(u[N]):Ce(u[N]);if(Oe(H,G))B(H,G,p,null,m,v,R,w,A);else break;j--,N--}if(x>j){if(x<=N){const H=N+1,G=H<M?u[H].el:y;for(;x<=N;)B(null,u[x]=A?$e(u[x]):Ce(u[x]),p,G,m,v,R,w,A),x++}}else if(x>N)for(;x<=j;)Ae(c[x],m,v,!0),x++;else{const H=x,G=x,X=new Map;for(x=G;x<=N;x++){const ye=u[x]=A?$e(u[x]):Ce(u[x]);ye.key!=null&&X.set(ye.key,x)}let te,ie=0;const ve=N-G+1;let tt=!1,hs=0;const ht=new Array(ve);for(x=0;x<ve;x++)ht[x]=0;for(x=H;x<=j;x++){const ye=c[x];if(ie>=ve){Ae(ye,m,v,!0);continue}let Fe;if(ye.key!=null)Fe=X.get(ye.key);else for(te=G;te<=N;te++)if(ht[te-G]===0&&Oe(ye,u[te])){Fe=te;break}Fe===void 0?Ae(ye,m,v,!0):(ht[Fe-G]=x+1,Fe>=hs?hs=Fe:tt=!0,B(ye,u[Fe],p,null,m,v,R,w,A),ie++)}const gs=tt?Zi(ht):nt;for(te=gs.length-1,x=ve-1;x>=0;x--){const ye=G+x,Fe=u[ye],ps=ye+1<M?u[ye+1].el:y;ht[x]===0?B(null,Fe,p,ps,m,v,R,w,A):tt&&(te<0||x!==gs[te]?qe(Fe,p,ps,2):te--)}}},qe=(c,u,p,y,m=null)=>{const{el:v,type:R,transition:w,children:A,shapeFlag:x}=c;if(x&6){qe(c.component.subTree,u,p,y);return}if(x&128){c.suspense.move(u,p,y);return}if(x&64){R.move(c,u,p,et);return}if(R===pe){s(v,u,p);for(let j=0;j<A.length;j++)qe(A[j],u,p,y);s(c.anchor,u,p);return}if(R===Wt){_(c,u,p);return}if(y!==2&&x&1&&w)if(y===0)w.beforeEnter(v),s(v,u,p),ge(()=>w.enter(v),m);else{const{leave:j,delayLeave:N,afterLeave:H}=w,G=()=>s(v,u,p),X=()=>{j(v,()=>{G(),H&&H()})};N?N(v,G,X):X()}else s(v,u,p)},Ae=(c,u,p,y=!1,m=!1)=>{const{type:v,props:R,ref:w,children:A,dynamicChildren:x,shapeFlag:M,patchFlag:j,dirs:N}=c;if(w!=null&&en(w,null,p,c,!0),M&256){u.ctx.deactivate(c);return}const H=M&1&&N,G=!ct(c);let X;if(G&&(X=R&&R.onVnodeBeforeUnmount)&&xe(X,u,c),M&6)Qr(c.component,p,y);else{if(M&128){c.suspense.unmount(p,y);return}H&&Re(c,null,u,"beforeUnmount"),M&64?c.type.remove(c,u,p,m,et,y):x&&(v!==pe||j>0&&j&64)?Be(x,u,p,!1,!0):(v===pe&&j&384||!m&&M&16)&&Be(A,u,p),y&&as(c)}(G&&(X=R&&R.onVnodeUnmounted)||H)&&ge(()=>{X&&xe(X,u,c),H&&Re(c,null,u,"unmounted")},p)},as=c=>{const{type:u,el:p,anchor:y,transition:m}=c;if(u===pe){Zr(p,y);return}if(u===Wt){T(c);return}const v=()=>{r(p),m&&!m.persisted&&m.afterLeave&&m.afterLeave()};if(c.shapeFlag&1&&m&&!m.persisted){const{leave:R,delayLeave:w}=m,A=()=>R(p,v);w?w(c.el,v,A):A()}else v()},Zr=(c,u)=>{let p;for(;c!==u;)p=g(c),r(c),c=p;r(u)},Qr=(c,u,p)=>{const{bum:y,scope:m,update:v,subTree:R,um:w}=c;y&&bn(y),m.stop(),v&&(v.active=!1,Ae(R,c,u,p)),w&&ge(w,u),ge(()=>{c.isUnmounted=!0},u),u&&u.pendingBranch&&!u.isUnmounted&&c.asyncDep&&!c.asyncResolved&&c.suspenseId===u.pendingId&&(u.deps--,u.deps===0&&u.resolve())},Be=(c,u,p,y=!1,m=!1,v=0)=>{for(let R=v;R<c.length;R++)Ae(c[R],u,p,y,m)},Mt=c=>c.shapeFlag&6?Mt(c.component.subTree):c.shapeFlag&128?c.suspense.next():g(c.anchor||c.el);let gn=!1;const ds=(c,u,p)=>{c==null?u._vnode&&Ae(u._vnode,null,null,!0):B(u._vnode||null,c,u,null,null,null,p),gn||(gn=!0,As(),Zt(),gn=!1),u._vnode=c},et={p:B,um:Ae,m:qe,r:as,mt:ce,mc:F,pc:S,pbc:O,n:Mt,o:e};let pn,_n;return t&&([pn,_n]=t(et)),{render:ds,hydrate:pn,createApp:Hi(ds,pn)}}function An({type:e,props:t},n){return n==="svg"&&e==="foreignObject"||n==="mathml"&&e==="annotation-xml"&&t&&t.encoding&&t.encoding.includes("html")?void 0:n}function Ge({effect:e,update:t},n){e.allowRecurse=t.allowRecurse=n}function jr(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function cs(e,t,n=!1){const s=e.children,r=t.children;if(U(s)&&U(r))for(let l=0;l<s.length;l++){const i=s[l];let o=r[l];o.shapeFlag&1&&!o.dynamicChildren&&((o.patchFlag<=0||o.patchFlag===32)&&(o=r[l]=$e(r[l]),o.el=i.el),n||cs(i,o)),o.type===ut&&(o.el=i.el)}}function Zi(e){const t=e.slice(),n=[0];let s,r,l,i,o;const f=e.length;for(s=0;s<f;s++){const d=e[s];if(d!==0){if(r=n[n.length-1],e[r]<d){t[s]=r,n.push(s);continue}for(l=0,i=n.length-1;l<i;)o=l+i>>1,e[n[o]]<d?l=o+1:i=o;d<e[n[l]]&&(l>0&&(t[s]=n[l-1]),n[l]=s)}}for(l=n.length,i=n[l-1];l-- >0;)n[l]=i,i=t[i];return n}function Ur(e){const t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:Ur(t)}const Qi=e=>e.__isTeleport,mt=e=>e&&(e.disabled||e.disabled===""),js=e=>typeof SVGElement<"u"&&e instanceof SVGElement,Us=e=>typeof MathMLElement=="function"&&e instanceof MathMLElement,Hn=(e,t)=>{const n=e&&e.to;return le(n)?t?t(n):null:n},Xi={name:"Teleport",__isTeleport:!0,process(e,t,n,s,r,l,i,o,f,d){const{mc:h,pc:a,pbc:g,o:{insert:E,querySelector:I,createText:B,createComment:D}}=d,q=mt(t.props);let{shapeFlag:K,children:_,dynamicChildren:T}=t;if(e==null){const C=t.el=B(""),b=t.anchor=B("");E(C,n,s),E(b,n,s);const L=t.target=Hn(t.props,I),F=t.targetAnchor=B("");L&&(E(F,L),i==="svg"||js(L)?i="svg":(i==="mathml"||Us(L))&&(i="mathml"));const P=(O,V)=>{K&16&&h(_,O,V,r,l,i,o,f)};q?P(n,b):L&&P(L,F)}else{t.el=e.el;const C=t.anchor=e.anchor,b=t.target=e.target,L=t.targetAnchor=e.targetAnchor,F=mt(e.props),P=F?n:b,O=F?C:L;if(i==="svg"||js(b)?i="svg":(i==="mathml"||Us(b))&&(i="mathml"),T?(g(e.dynamicChildren,T,P,r,l,i,o),cs(e,t,!0)):f||a(e,t,P,O,r,l,i,o,!1),q)F?t.props&&e.props&&t.props.to!==e.props.to&&(t.props.to=e.props.to):$t(t,n,C,d,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){const V=t.target=Hn(t.props,I);V&&$t(t,V,null,d,0)}else F&&$t(t,b,L,d,1)}Hr(t)},remove(e,t,n,s,{um:r,o:{remove:l}},i){const{shapeFlag:o,children:f,anchor:d,targetAnchor:h,target:a,props:g}=e;if(a&&l(h),i&&l(d),o&16){const E=i||!mt(g);for(let I=0;I<f.length;I++){const B=f[I];r(B,t,n,E,!!B.dynamicChildren)}}},move:$t,hydrate:zi};function $t(e,t,n,{o:{insert:s},m:r},l=2){l===0&&s(e.targetAnchor,t,n);const{el:i,anchor:o,shapeFlag:f,children:d,props:h}=e,a=l===2;if(a&&s(i,t,n),(!a||mt(h))&&f&16)for(let g=0;g<d.length;g++)r(d[g],t,n,2);a&&s(o,t,n)}function zi(e,t,n,s,r,l,{o:{nextSibling:i,parentNode:o,querySelector:f}},d){const h=t.target=Hn(t.props,f);if(h){const a=h._lpa||h.firstChild;if(t.shapeFlag&16)if(mt(t.props))t.anchor=d(i(e),t,o(e),n,s,r,l),t.targetAnchor=a;else{t.anchor=i(e);let g=a;for(;g;)if(g=i(g),g&&g.nodeType===8&&g.data==="teleport anchor"){t.targetAnchor=g,h._lpa=t.targetAnchor&&i(t.targetAnchor);break}d(a,t,h,n,s,r,l)}Hr(t)}return t.anchor&&i(t.anchor)}const Uo=Xi;function Hr(e){const t=e.ctx;if(t&&t.ut){let n=e.children[0].el;for(;n&&n!==e.targetAnchor;)n.nodeType===1&&n.setAttribute("data-v-owner",t.uid),n=n.nextSibling;t.ut()}}const pe=Symbol.for("v-fgt"),ut=Symbol.for("v-txt"),he=Symbol.for("v-cmt"),Wt=Symbol.for("v-stc"),bt=[];let we=null;function fs(e=!1){bt.push(we=e?null:[])}function $r(){bt.pop(),we=bt[bt.length-1]||null}let at=1;function Hs(e){at+=e}function Vr(e){return e.dynamicChildren=at>0?we||nt:null,$r(),at>0&&we&&we.push(e),e}function Ho(e,t,n,s,r,l){return Vr(Wr(e,t,n,s,r,l,!0))}function Dr(e,t,n,s,r){return Vr(ne(e,t,n,s,r,!0))}function vt(e){return e?e.__v_isVNode===!0:!1}function Oe(e,t){return e.type===t.type&&e.key===t.key}const dn="__vInternal",Kr=({key:e})=>e??null,qt=({ref:e,ref_key:t,ref_for:n})=>(typeof e=="number"&&(e=""+e),e!=null?le(e)||ae(e)||$(e)?{i:re,r:e,k:t,f:!!n}:e:null);function Wr(e,t=null,n=null,s=0,r=null,l=e===pe?0:1,i=!1,o=!1){const f={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&Kr(t),ref:t&&qt(t),scopeId:mr,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetAnchor:null,staticCount:0,shapeFlag:l,patchFlag:s,dynamicProps:r,dynamicChildren:null,appContext:null,ctx:re};return o?(us(f,n),l&128&&e.normalize(f)):n&&(f.shapeFlag|=le(n)?8:16),at>0&&!i&&we&&(f.patchFlag>0||l&6)&&f.patchFlag!==32&&we.push(f),f}const ne=eo;function eo(e,t=null,n=null,s=0,r=null,l=!1){if((!e||e===br)&&(e=he),vt(e)){const o=We(e,t,!0);return n&&us(o,n),at>0&&!l&&we&&(o.shapeFlag&6?we[we.indexOf(e)]=o:we.push(o)),o.patchFlag|=-2,o}if(ao(e)&&(e=e.__vccOpts),t){t=to(t);let{class:o,style:f}=t;o&&!le(o)&&(t.class=ln(o)),z(f)&&(fr(f)&&!U(f)&&(f=fe({},f)),t.style=rn(f))}const i=le(e)?1:ci(e)?128:Qi(e)?64:z(e)?4:$(e)?2:0;return Wr(e,t,n,s,r,i,l,!0)}function to(e){return e?fr(e)||dn in e?fe({},e):e:null}function We(e,t,n=!1){const{props:s,ref:r,patchFlag:l,children:i}=e,o=t?no(s||{},t):s;return{__v_isVNode:!0,__v_skip:!0,type:e.type,props:o,key:o&&Kr(o),ref:t&&t.ref?n&&r?U(r)?r.concat(qt(t)):[r,qt(t)]:qt(t):r,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:i,target:e.target,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==pe?l===-1?16:l|16:l,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:e.transition,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&We(e.ssContent),ssFallback:e.ssFallback&&We(e.ssFallback),el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce}}function qr(e=" ",t=0){return ne(ut,null,e,t)}function $o(e="",t=!1){return t?(fs(),Dr(he,null,e)):ne(he,null,e)}function Ce(e){return e==null||typeof e=="boolean"?ne(he):U(e)?ne(pe,null,e.slice()):typeof e=="object"?$e(e):ne(ut,null,String(e))}function $e(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:We(e)}function us(e,t){let n=0;const{shapeFlag:s}=e;if(t==null)t=null;else if(U(t))n=16;else if(typeof t=="object")if(s&65){const r=t.default;r&&(r._c&&(r._d=!1),us(e,r()),r._c&&(r._d=!0));return}else{n=32;const r=t._;!r&&!(dn in t)?t._ctx=re:r===3&&re&&(re.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else $(t)?(t={default:t,_ctx:re},n=32):(t=String(t),s&64?(n=16,t=[qr(t)]):n=8);e.children=t,e.shapeFlag|=n}function no(...e){const t={};for(let n=0;n<e.length;n++){const s=e[n];for(const r in s)if(r==="class")t.class!==s.class&&(t.class=ln([t.class,s.class]));else if(r==="style")t.style=rn([t.style,s.style]);else if(nn(r)){const l=t[r],i=s[r];i&&l!==i&&!(U(l)&&l.includes(i))&&(t[r]=l?[].concat(l,i):i)}else r!==""&&(t[r]=s[r])}return t}function xe(e,t,n,s=null){Ee(e,t,7,[n,s])}const so=Mr();let ro=0;function lo(e,t,n){const s=e.type,r=(t?t.appContext:e.appContext)||so,l={uid:ro++,vnode:e,type:s,parent:t,appContext:r,root:null,next:null,subTree:null,effect:null,update:null,scope:new ml(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(r.provides),accessCache:null,renderCache:[],components:null,directives:null,propsOptions:Lr(s,r),emitsOptions:yr(s,r),emit:null,emitted:null,propsDefaults:ee,inheritAttrs:s.inheritAttrs,ctx:ee,data:ee,props:ee,attrs:ee,slots:ee,refs:ee,setupState:ee,setupContext:null,attrsProxy:null,slotsProxy:null,suspense:n,suspenseId:n?n.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};return l.ctx={_:l},l.root=t?t.root:l,l.emit=ni.bind(null,l),e.ce&&e.ce(l),l}let oe=null;const Gr=()=>oe||re;let tn,$n;{const e=Js(),t=(n,s)=>{let r;return(r=e[n])||(r=e[n]=[]),r.push(s),l=>{r.length>1?r.forEach(i=>i(l)):r[0](l)}};tn=t("__VUE_INSTANCE_SETTERS__",n=>oe=n),$n=t("__VUE_SSR_SETTERS__",n=>It=n)}const Rt=e=>{const t=oe;return tn(e),e.scope.on(),()=>{e.scope.off(),tn(t)}},$s=()=>{oe&&oe.scope.off(),tn(null)};function Jr(e){return e.vnode.shapeFlag&4}let It=!1;function io(e,t=!1){t&&$n(t);const{props:n,children:s}=e.vnode,r=Jr(e);Vi(e,n,r,t),Wi(e,s);const l=r?oo(e,t):void 0;return t&&$n(!1),l}function oo(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=ur(new Proxy(e.ctx,Li));const{setup:s}=n;if(s){const r=e.setupContext=s.length>1?fo(e):null,l=Rt(e);Xe();const i=De(s,e,0,[e.props,r]);if(ze(),l(),Ws(i)){if(i.then($s,$s),t)return i.then(o=>{Vn(e,o,t)}).catch(o=>{dt(o,e,0)});e.asyncDep=i}else Vn(e,i,t)}else Yr(e,t)}function Vn(e,t,n){$(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:z(t)&&(e.setupState=hr(t)),Yr(e,n)}let Vs;function Yr(e,t,n){const s=e.type;if(!e.render){if(!t&&Vs&&!s.render){const r=s.template||is(e).template;if(r){const{isCustomElement:l,compilerOptions:i}=e.appContext.config,{delimiters:o,compilerOptions:f}=s,d=fe(fe({isCustomElement:l,delimiters:o},i),f);s.render=Vs(r,d)}}e.render=s.render||Te}{const r=Rt(e);Xe();try{Bi(e)}finally{ze(),r()}}}function co(e){return e.attrsProxy||(e.attrsProxy=new Proxy(e.attrs,{get(t,n){return _e(e,"get","$attrs"),t[n]}}))}function fo(e){const t=n=>{e.exposed=n||{}};return{get attrs(){return co(e)},slots:e.slots,emit:e.emit,expose:t}}function hn(e){if(e.exposed)return e.exposeProxy||(e.exposeProxy=new Proxy(hr(ur(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in _t)return _t[n](e)},has(t,n){return n in t||n in _t}}))}function uo(e,t=!0){return $(e)?e.displayName||e.name:e.name||t&&e.__name}function ao(e){return $(e)&&"__vccOpts"in e}const ho=(e,t)=>Vl(e,t,It);function Vo(e,t,n=ee){const s=Gr(),r=Me(t),l=At(t),i=Gl((f,d)=>{let h;return yi(()=>{const a=e[t];Pe(h,a)&&(h=a,d())}),{get(){return f(),n.get?n.get(h):h},set(a){const g=s.vnode.props;!(g&&(t in g||r in g||l in g)&&(`onUpdate:${t}`in g||`onUpdate:${r}`in g||`onUpdate:${l}`in g))&&Pe(a,h)&&(h=a,d()),s.emit(`update:${t}`,n.set?n.set(a):a)}}}),o=t==="modelValue"?"modelModifiers":`${t}Modifiers`;return i[Symbol.iterator]=()=>{let f=0;return{next(){return f<2?{value:f++?e[o]||{}:i,done:!1}:{done:!0}}}},i}function Do(e,t,n){const s=arguments.length;return s===2?z(t)&&!U(t)?vt(t)?ne(e,null,[t]):ne(e,t):ne(e,null,t):(s>3?n=Array.prototype.slice.call(arguments,2):s===3&&vt(n)&&(n=[n]),ne(e,t,n))}const go="3.4.21";globalThis.__sfIds||(globalThis.__sfIds={});const Ko=(e="_")=>(typeof globalThis.__sfIds[e]!="number"&&(globalThis.__sfIds[e]=-1),`${e}${++globalThis.__sfIds[e]}`),Wo=(e,t=300)=>{typeof window.requestIdleCallback=="function"?window.requestIdleCallback(e):setTimeout(e,t)},po=e=>e.replace(/[ÁáÃãÂâÀà]/g,"a").replace(/[ÉéÊê]/g,"e").replace(/[Íí]/g,"i").replace(/[ÕõÓóÔô]/g,"o").replace(/[Úú]/g,"u").replace(/[Çç]/g,"c"),qo=e=>po(e.trim()).toLowerCase().replace(/[\W\r\n]/gm,"-").replace(/-{2,}/g,"-").replace(/(^-)|(-$)/g,""),_o=e=>e.toLowerCase().replace(/Á/g,"á").replace(/Ã/g,"ã").replace(/Â/g,"â").replace(/À/g,"à").replace(/É/g,"é").replace(/Ê/g,"ê").replace(/Í/g,"í").replace(/Õ/g,"õ").replace(/Ó/g,"ó").replace(/Ô/g,"ô").replace(/Ú/g,"ú").replace(/Ç/g,"ç"),yo=e=>_o(e.trim()).replace(/[\r\n]/gm," ").replace(/[^\w-&%áãâàéêíõóôúç]/g," ").replace(/\s{2,}/g," "),Go=(e,t="/s/")=>`${t}${encodeURIComponent(yo(e))}`,Jo=(e,t=0)=>{for(;e.offsetParent;)t+=e.offsetTop,e=e.offsetParent;return window.scroll({top:t,behavior:"smooth"})};export{Dr as $,fe as A,Mo as B,xi as C,Xr as D,z as E,pe as F,al as G,nn as H,Ds as I,At as J,Me as K,qn as L,xo as M,Co as N,Ee as O,yn as P,Xl as Q,Kl as R,cr as S,Ar as T,ae as U,Gr as V,xl as W,wo as X,$l as Y,ko as Z,mo as _,Dt as a,qr as a0,To as a1,Fo as a2,no as a3,bo as a4,to as a5,qo as a6,po as a7,Eo as a8,Go as a9,Hs as aa,Ko as ab,rn as ac,$i as ad,Rr as ae,Io as af,Kt as ag,Z as ah,Jo as ai,No as aj,Vo as ak,Fr as al,Ro as am,Uo as an,Po as ao,We as ap,Bo as aq,Wo as b,ho as c,Ti as d,Ho as e,Wr as f,ne as g,si as h,Ao as i,Oo as j,Lo as k,$o as l,$ as m,ln as n,fs as o,le as p,ul as q,Xn as r,vo as s,So as t,jo as u,U as v,Tn as w,bn as x,Ys as y,Do as z};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{u as _}from"./customer-session.
|
|
1
|
+
import{u as _}from"./customer-session.BAjMMoBA.js";import{e as l}from"./index.CTTHpJlV.js";import{p as y}from"./price.CHiL6Z1J.js";import{c as m,w as q}from"./sf-utils.xmJHVMAX.js";const g=()=>{let i=Math.floor(Math.random()*1e6).toString()+Date.now();for(;i.length<24;)i+="0";return i};function h(i){return{all:i=i||new Map,on:function(t,r){var o=i.get(t);o?o.push(r):i.set(t,[r])},off:function(t,r){var o=i.get(t);o&&(r?o.splice(o.indexOf(r)>>>0,1):i.set(t,[]))},emit:function(t,r){var o=i.get(t);o&&o.slice().map(function(n){n(r)}),(o=i.get("*"))&&o.slice().map(function(n){n(t,r)})}}}const b=(i,{flags:t})=>!i.flags&&!t?!0:!i.flags||!t||i.flags.length!==t.length?!1:i.flags.every(r=>t.includes(r)),v=(i,t)=>{if(typeof t.product_id!="string"||typeof t.quantity!="number"||!(t.quantity>=0)||typeof t.price!="number"||!(t.price>=0))return null;const{items:r}=i;if(!t.kit_product)for(let n=0;n<r.length;n++){const a=r[n];if(!a.kit_product&&a.product_id===t.product_id&&a.variation_id===t.variation_id&&(!a.customizations||!a.customizations.length)&&b(a,t))return a.quantity+=t.quantity,t.price&&(a.price=t.price),t.final_price&&(a.final_price=t.final_price),a}const o={...t};if((!t._id||t._id===t.variation_id||r.find(({_id:n})=>n===t._id))&&(o._id=g()),t.customizations){const n=[];t.customizations.forEach((a,c)=>{n[c]={...a}}),o.customizations=n}return r.push(o),o},C=(i,t,r)=>{(typeof r!="number"||Number.isNaN(r))&&(r=i.min_quantity||1);const o=i.min_quantity||0,n=t&&i.variations?i.variations.find(({_id:c})=>c===t):void 0,a={product_id:i._id,variation_id:t,sku:n?.sku||i.sku,name:n?.name||i.name,slug:i.slug,production_time:n?.production_time||i.production_time,currency_id:i.currency_id,currency_symbol:i.currency_symbol,base_price:n?.base_price||i.base_price,max_quantity:i.quantity,quantity:o>0?Math.max(o,r):r,price:y(i)};return n?.picture_id&&i.pictures&&(a.picture=i.pictures.find(c=>c._id===n.picture_id)),!a.picture&&i.pictures&&([a.picture]=i.pictures),a},k="ecomShoppingCart",E={subtotal:0,items:[]},s=_(k,E),S=m(()=>s.items.reduce((i,t)=>i+t.quantity,0)),x=i=>{v(s,i)},j=i=>{for(let t=0;t<s.items.length;t++)if(s.items[t]._id===i){s.items.splice(t,1);break}},D=(i,t,r)=>x(C(i,t,r)),f=h(),p=()=>s.items.map(i=>({...i}));let e=p();const z=l(i=>{["addCartItem","removeCartItem"].forEach(t=>{const r=t==="addCartItem",o=r?i:e,n=r?e:i;o.forEach(a=>{if(!a.quantity)return;const u=n.find(({_id:d})=>d===a._id)?.quantity||0;a.quantity>u&&f.emit(t,{...a,quantity:a.quantity-u})})}),e=p()},200);q(s.items,i=>{i.forEach(t=>{let r=t.kit_product?.price&&t.kit_product.pack_quantity?t.kit_product.price/t.kit_product.pack_quantity:t.price;Array.isArray(t.customizations)&&t.customizations.forEach(a=>{if(a.add_to_price){const{type:c,addition:u}=a.add_to_price;r+=c==="fixed"?u:t.price*(u/100)}}),t.final_price=r;const o=t.min_quantity||1,n=t.max_quantity;typeof t.quantity!="number"||Number.isNaN(t.quantity)||t.quantity<o?t.quantity=o:n&&t.quantity>n&&(t.quantity=n)}),s.subtotal=i.reduce((t,r)=>t+r.quantity*(r.final_price||r.price),0),z(i)});const O={on:f.on,off:f.off};export{D as a,O as c,C as p,j as r,s,S as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{u as C,b as T,d as y,c as x}from"./customer-session.
|
|
1
|
+
import{u as C,b as T,d as y,c as x}from"./customer-session.BAjMMoBA.js";import{c as G}from"./shopping-cart.DGvCZWRZ.js";import{a as m,r as R,c as b,Y as I,w as E}from"./sf-utils.xmJHVMAX.js";import{e as N,g as P}from"./index.CTTHpJlV.js";import{u as A}from"./afetch.DPLba2tr.js";import{n as M}from"./name.CIPngEFN.js";import{p as L}from"./price.CHiL6Z1J.js";const F="ecomSeachHistory",l=C(F,[]);for(let e=0;e<l.length;e++)typeof l[e]!="string"&&(l.splice(e,1),e-=1);const V=async({term:e,params:i,fields:o,url:t="search/v1"})=>{if(typeof e=="string"&&(e=e.trim(),e.length<2))return{data:{result:[],meta:null}};const a=await T.get(t,{fields:o,params:e?{...i,term:e}:i});if(e&&a.data.result.length){const r=e,n=l.findIndex(h=>h.includes(r)&&!h.replace(r,"").includes(" "));if(n>-1){const h=l[n];l.splice(n,1),l.unshift(h)}else{const h=l.findIndex(d=>r.startsWith(d));h>-1&&l.splice(h,1),l.unshift(e)}for(;l.length>20;)l.pop()}return a};class Y{fields;term=m(null);isWithCount=m(!0);isWithBuckets=m(!0);params=R({});pageSize=m(24);pageNumber=m(1);#s=[];#i=m(!1);isFetching=b(()=>this.#i.value);#e=m(!1);wasFetched=b(()=>this.#e.value);#a=m(null);#t;fetching=b(()=>this.#a.value);#n=m(null);fetchError=b(()=>this.#n.value);products=I([]);meta=I({offset:0,limit:0,fields:[],sort:[],query:{}});#o;constructor({fields:i,debounce:o=150}={}){this.fields=i,this.#o=N(t=>(this.#i.value=!0,V(t)),o),E([this.term,this.params,this.pageSize],()=>{this.wasFetched.value&&(this.pageNumber.value=1,this.#e.value=!1)}),E(this.pageNumber,()=>{this.#e.value=!1})}async fetch(i){i!==void 0&&i!==this.term.value&&(this.term.value=i,this.pageNumber.value=1);const o=this.pageSize.value,t=o*(this.pageNumber.value-1);this.#a.value||(this.#a.value=new Promise(n=>{this.#t=n}));let a;const r={term:this.term.value,params:{...this.params,limit:o,offset:t,count:this.isWithCount.value||void 0,buckets:this.isWithBuckets.value||void 0},fields:this.fields};try{for(let n=0;n<this.#s.length;n++)this.#s[n](r);a=await this.#o(r)}catch(n){throw this.#t&&(this.#n.value=n,this.#t()),n}if(a){this.#i.value=!1,this.#e.value=!0;const{data:n}=a;n.meta&&this.setResult(n),this.#t&&this.#t()}}addMiddleware(i){this.#s.push(i)}setResult(i){i.meta&&Object.assign(this.meta,i.meta),i.result&&(this.products.splice(0),i.result.forEach(o=>this.products.push(o))),i.meta&&i.result&&setTimeout(()=>{this.#e.value=!0},9)}}const c={},u={},S=()=>{u.resolve||(u.waiting=new Promise(e=>{u.resolve=e}))};S();const W=()=>({page_location:window.location.toString(),language:globalThis.$storefront.settings.lang||"pt_br",page_title:document.title,user_agent:navigator.userAgent}),q=()=>({...u.params||W(),...c,user_id:x.value._id,utm:A}),$="GtagEvent";let _={},g="";const p=async(e,i)=>{const o=i;if(e==="page_view"){_={};const{apiContext:t}=window.$storefront;if(g="",t){const{name:a}=t.doc;switch(t.resource){case"categories":g=`Category: ${a}`;break;case"brands":g=`Brand: ${a}`;break;case"collections":g=`Collection: ${a}`;break}}else{const{pathname:a}=window.location;a==="/"?g="Home":(/^\/s\/?/.test(a)||a==="/search"||a==="/busca")&&(g="Search results")}u.resolve&&(u.params=i,u.resolve(),u.resolve=null)}else u.waiting&&await u.waiting,e==="view_item"&&o.items?.forEach(t=>{if(t.index!==void 0)return;if(!t.item_list_id&&!t.item_list_name){const{apiContext:r}=window.$storefront;r?.doc._id===t.object_id&&(t.item_list_id="product-page",t.item_list_name="Product page")}const a=t.item_list_id||t.item_list_name||g;a&&(_[a]?_[a]+=1:_[a]=1,t.index=_[a],!t.item_list_id&&!t.item_list_name&&(t.item_list_name=a))}),typeof o.value=="number"&&!o.currency&&(o.currency=window.ECOM_CURRENCY||"BRL");try{const t={type:$,...q(),event:{name:e,params:o}};window.postMessage(t,window.origin)}catch(t){console.error(t)}},Q=e=>{window.addEventListener("message",({data:i})=>{i.type===$&&e(i)})},B=e=>{const[i,...o]=M(e).split(" / "),t={item_name:i,item_id:e.sku,price:Math.round(L(e)*100)/100,object_id:e._id};o&&o.length?t.item_variant=o.join(" / "):e.variation_id&&(t.item_name=i.replace(window.__customGTMVariantRegex||/\s[^\s]+$/,""),t.item_variant=i.replace(t.item_name,"").trim()),(e.quantity===0||e.quantity&&e.product_id)&&(t.quantity=e.quantity);const{brands:a,categories:r}=e;if(a?.length&&(t.item_brand=a[0].name),r?.length)for(let n=0;n<r.length;n++){const{name:h}=r[n];if(n===0)t.item_category=h;else if(t[`item_category${n+1}`]=h,n===4)break}return t},X=({experimentId:e=window.AB_EXPERIMENT_ID}={})=>{document.addEventListener("astro:beforeload",S);const{gtag:i,GTAG_TAG_ID:o,GA_TRACKING_ID:t,GIT_BRANCH:a}=window,r=o||t,n=a&&e?`${e}-${a}`:a?.startsWith("main-")&&a||null;typeof i=="function"&&(r&&["client_id","session_id","gclid"].forEach(s=>{i("get",r,s,f=>{c[s==="gclid"?s:`g_${s}`]=f})}),n&&i("event","experience_impression",{exp_variant_string:n}));const h=new URL(window.location.toString());["gclid","fbclid","ttclid"].forEach(s=>{const f=c[s]||h.searchParams.get(s);f?(c[s]=f,sessionStorage.setItem(`analytics_${s}`,f)):c[s]=sessionStorage.getItem(`analytics_${s}`)||void 0});const d=["_fbp"];return c.fbclid||d.push("_fbc"),c.g_client_id||d.push("_ga"),d.forEach(s=>{document.cookie.split(";").forEach(f=>{const[w,v]=f.split("=");if(w.trim()===s&&v)switch(s){case"_fbp":c.fbp=v;break;case"_fbc":c.fbclid=v;break;case"_ga":c.g_client_id=v.substring(6);break}})}),["client_id","session_id"].forEach(s=>{const f=s==="client_id"?localStorage:sessionStorage,w=f.getItem(`analytics_${s}`);w?c[s]=w:c[s]=c[`g_${s}`]||`${Math.ceil(Math.random()*1e6)}.${Math.ceil(Math.random()*1e6)}`,f.setItem(`analytics_${s}`,c[s])}),y.value?p("login",{}):P(y,()=>p("login",{})),G.on("*",(s,f)=>{p(s==="addCartItem"?"add_to_cart":"remove_from_cart",{items:[B(f)]})}),E(l,()=>{const s=l[0];s&&p("search",{search_term:s})}),window.location.pathname.startsWith("/s")&&setTimeout(()=>{let s=new URLSearchParams(window.location.search).get("q");s||(s=decodeURIComponent(window.location.pathname.split("/")[2])),s&&typeof s=="string"&&p("view_search_results",{search_term:s})},300),{expVariantString:n}};export{Y as S,W as a,q as b,p as e,B as g,l as s,c as t,X as u,Q as w};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{s as u,w as c}from"./sf-utils.
|
|
1
|
+
import{s as u,w as c}from"./sf-utils.xmJHVMAX.js";function d(n){let i,s;Array.isArray(n)&&(i=n[1],s=n[2],n=n[0]);const r=u();if(window.$isCmsPreview){const a=btoa(JSON.stringify({filename:n})),o={type:"open",filename:n,field:i,subfield:s,id:a};window.parent.postMessage(o,window.location.origin),window.addEventListener("message",t=>{t.data.id===a&&(i?r.value=s?t.data.data[i][s]:t.data.data[i]:r.value=t.data.data)})}return{liveContent:r}}const l=({cmsPreview:n},i)=>{if(n){const{contentFilename:s,sectionIndex:r}=n,{liveContent:a}=d([s,"sections",r]);return i&&c(a,o=>{o&&Object.keys(i).forEach(t=>{if(i[t].value!==void 0){if(o[t]===void 0)return;i[t].value=o[t];return}if(o[t]){if(Array.isArray(i[t])){i[t].splice(0),o[t].forEach(e=>i[t].push(e));return}Object.assign(i[t],o[t])}})}),{liveContent:a}}return null};export{l as a,d as u};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b}from"./customer-session.
|
|
1
|
+
import{b}from"./customer-session.BAjMMoBA.js";import"./server-data.CUHTES8a.js";import{a as f,Y as P,c as a,a6 as w}from"./sf-utils.xmJHVMAX.js";import{e as I,g as k}from"./use-analytics.BWhF_fCv.js";import{p as g,o as q}from"./price.CHiL6Z1J.js";import{n as E}from"./name.CIPngEFN.js";import{i as N}from"./img.CB-F9VLo.js";import"./index.CTTHpJlV.js";const $=t=>t&&t.min_quantity||1,G=t=>!t.hasOwnProperty("quantity")||t.quantity>=$(t),M=t=>{const n=f(!1);let s=null;const o=f(null),{productId:r}=t,i=P({...t.product,_id:t.product?._id||r,price:g(t.product||{})});!t.product&&r&&(n.value=!0,s=(async()=>{try{const{data:e}=await b.get(`products/${r}`);Object.assign(i,e)}catch(e){console.error(e),o.value=e}n.value=!1})());const d=a(()=>E(i)),v=a(()=>{const{slug:e}=i;return typeof e=="string"?`/${e}`:null}),h=a(()=>{const{pictures:e}=i,l=[];return e&&e.forEach(p=>{const m=N(p);m&&l.push(m)}),l}),c=a(()=>G(i)),u=a(()=>c.value&&i.available&&i.visible),_=a(()=>{if(q(i)){const e=i.base_price;return Math.round((e-g(i))*100/e)}return 0}),y=a(()=>i.has_variations?!0:!!i.variations?.length);return I("view_item",{value:u.value?i.price:0,items:[{...k(i),item_list_name:t.listName,item_list_id:t.listId||t.listName&&w(t.listName)}]}),{isFetching:n,fetching:s,fetchError:o,product:i,title:d,link:v,images:h,isInStock:c,isActive:u,discountPercentage:_,hasVariations:y}};export{G as i,M as u};
|