@billgangcom/theme-lib 1.125.5 → 1.125.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (41) hide show
  1. package/dist/{builder-2YNszRul.js → builder-CQv65ONw.js} +5 -5
  2. package/dist/{builder-DT2MPQIe.cjs → builder-DajwWRB4.cjs} +2 -2
  3. package/dist/{builder-components-CfB-cXOa.js → builder-components-BR6CyOIi.js} +4 -4
  4. package/dist/{builder-components-HQ8ccfQi.cjs → builder-components-Cy-VmxAd.cjs} +1 -1
  5. package/dist/builder.cjs.js +1 -1
  6. package/dist/builder.es.js +23 -23
  7. package/dist/{charge-CeL8jXzk.js → charge-BIOFTYrp.js} +11 -9
  8. package/dist/{charge-Dd6podcM.cjs → charge-BOfQrkLv.cjs} +2 -2
  9. package/dist/{checkout-hG4nZAfL.cjs → checkout-B1l5LksI.cjs} +1 -1
  10. package/dist/{checkout-dKBgx4_t.js → checkout-g545jGLZ.js} +5 -5
  11. package/dist/exports.cjs.js +1 -1
  12. package/dist/exports.es.js +6 -6
  13. package/dist/{index-DrlEFa_A.cjs → index-B1ymclv0.cjs} +1 -1
  14. package/dist/{index-BBmLGlCP.cjs → index-B7-PVkQx.cjs} +1 -1
  15. package/dist/{index-CPXgL1Te.js → index-BhSh0O1l.js} +1 -1
  16. package/dist/{index-m8mNLWAF.js → index-C3lnL6j6.js} +5 -5
  17. package/dist/{index-BGWhMhIz.cjs → index-C65UzOoU.cjs} +1 -1
  18. package/dist/{index-BcBa6BVj.js → index-CidKvUav.js} +2 -2
  19. package/dist/{index-DCCA87NY.js → index-Cm8S5Gki.js} +5 -5
  20. package/dist/{index-DH3suBKA.cjs → index-DCaryi7j.cjs} +1 -1
  21. package/dist/{index-BsRq6_oH.js → index-DPIhmGN5.js} +5 -5
  22. package/dist/{index-ljnGesWX.cjs → index-DXzoPSoa.cjs} +1 -1
  23. package/dist/{index-WlsBw3sd.cjs → index-WT_hm-vy.cjs} +1 -1
  24. package/dist/{index-DxY9GcmW.js → index-r6UXCC-e.js} +5 -5
  25. package/dist/index.cjs.js +1 -1
  26. package/dist/index.es.js +6 -6
  27. package/dist/{order-bjCcFmx6.js → order-CCmQ1de6.js} +5 -5
  28. package/dist/{order-f8DTpqHu.cjs → order-DUfIq98T.cjs} +1 -1
  29. package/dist/{subscription-DuQaeZpz.cjs → subscription-BU1AfEvj.cjs} +1 -1
  30. package/dist/{subscription-B520eImG.js → subscription-Cr4tlTfV.js} +5 -5
  31. package/dist/{ticket-C_4dunoG.cjs → ticket-D-hMXIqO.cjs} +1 -1
  32. package/dist/{ticket-HPAqmPkQ.js → ticket-UPvqJdN6.js} +5 -5
  33. package/dist/{top-up-CE-L-n3m.js → top-up-BG4dnsZh.js} +5 -5
  34. package/dist/{top-up-xnDj358Z.cjs → top-up-C3qZGkbN.cjs} +1 -1
  35. package/dist/{ui-components-t7AROe_i.js → ui-components-Bc8Z_6jF.js} +4 -4
  36. package/dist/{ui-components-CoVj1ReR.cjs → ui-components-cdIfqSzy.cjs} +1 -1
  37. package/dist/ui.cjs.js +1 -1
  38. package/dist/ui.es.js +1 -1
  39. package/dist/{validation-BmbrCdXv.js → validation-B5t0eZSV.js} +5 -5
  40. package/dist/{validation-BFKCs4Vw.cjs → validation-CGW91G0m.cjs} +1 -1
  41. package/package.json +1 -1
@@ -2,10 +2,10 @@ import * as y from "react";
2
2
  import Te, { useRef as $r, useEffect as Ta } from "react";
3
3
  import * as Pa from "react-dom";
4
4
  import { jsx as M, jsxs as Ee, Fragment as Oa } from "react/jsx-runtime";
5
- import { I as Wt, B as zr, a as Zn, C as Ma, b as Aa, L as Da } from "./ui-components-t7AROe_i.js";
6
- import "./charge-CeL8jXzk.js";
7
- import { N as Fa, H as Ia, S as Ba, P as Ha, M as Ua } from "./builder-components-CfB-cXOa.js";
8
- import "./ticket-HPAqmPkQ.js";
5
+ import { I as Wt, B as zr, a as Zn, C as Ma, b as Aa, L as Da } from "./ui-components-Bc8Z_6jF.js";
6
+ import "./charge-BIOFTYrp.js";
7
+ import { N as Fa, H as Ia, S as Ba, P as Ha, M as Ua } from "./builder-components-BR6CyOIi.js";
8
+ import "./ticket-UPvqJdN6.js";
9
9
  /**
10
10
  * @remix-run/router v1.23.0
11
11
  *
@@ -5293,7 +5293,7 @@ const {
5293
5293
  const S = (w = p.response) == null ? void 0 : w.status;
5294
5294
  if (S === 401)
5295
5295
  try {
5296
- const _ = await import("./charge-CeL8jXzk.js").then((N) => N.a6);
5296
+ const _ = await import("./charge-BIOFTYrp.js").then((N) => N.a6);
5297
5297
  _ && _.logoutCustomer ? await _.logoutCustomer() : localStorage.removeItem("token"), window.location.reload();
5298
5298
  } catch (_) {
5299
5299
  console.error("Failed to import logoutCustomer:", _), localStorage.removeItem("token"), window.location.reload();
@@ -1,4 +1,4 @@
1
- "use strict";const we=require("react"),$a=require("react-dom"),k=require("react/jsx-runtime"),Be=require("./ui-components-CoVj1ReR.cjs");require("./charge-Dd6podcM.cjs");const Ft=require("./builder-components-HQ8ccfQi.cjs");require("./ticket-C_4dunoG.cjs");function Mo(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const v=Mo(we),za=Mo($a);/**
1
+ "use strict";const we=require("react"),$a=require("react-dom"),k=require("react/jsx-runtime"),Be=require("./ui-components-cdIfqSzy.cjs");require("./charge-BOfQrkLv.cjs");const Ft=require("./builder-components-Cy-VmxAd.cjs");require("./ticket-D-hMXIqO.cjs");function Mo(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const v=Mo(we),za=Mo($a);/**
2
2
  * @remix-run/router v1.23.0
3
3
  *
4
4
  * Copyright (c) Remix Software Inc.
@@ -33,7 +33,7 @@
33
33
  `)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...n){const r=new this(t);return n.forEach(o=>r.set(o)),r}static accessor(t){const r=(this[So]=this[So]={accessors:{}}).accessors,o=this.prototype;function a(s){const i=Ut(s);r[i]||(oc(o,s),r[i]=!0)}return E.isArray(t)?t.forEach(a):a(t),this}};Oe.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);E.reduceDescriptors(Oe.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(r){this[n]=r}}});E.freezeMethods(Oe);function nr(e,t){const n=this||nn,r=t||n,o=Oe.from(r.headers);let a=r.data;return E.forEach(e,function(i){a=i.call(n,a,o.normalize(),t?t.status:void 0)}),o.normalize(),a}function pa(e){return!!(e&&e.__CANCEL__)}function Ot(e,t,n){$.call(this,e??"canceled",$.ERR_CANCELED,t,n),this.name="CanceledError"}E.inherits(Ot,$,{__CANCEL__:!0});function ma(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new $("Request failed with status code "+n.status,[$.ERR_BAD_REQUEST,$.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}function ac(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function sc(e,t){e=e||10;const n=new Array(e),r=new Array(e);let o=0,a=0,s;return t=t!==void 0?t:1e3,function(l){const c=Date.now(),u=r[a];s||(s=c),n[o]=l,r[o]=c;let d=a,h=0;for(;d!==o;)h+=n[d++],d=d%e;if(o=(o+1)%e,o===a&&(a=(a+1)%e),c-s<t)return;const w=u&&c-u;return w?Math.round(h*1e3/w):void 0}}function ic(e,t){let n=0,r=1e3/t,o,a;const s=(c,u=Date.now())=>{n=u,o=null,a&&(clearTimeout(a),a=null),e.apply(null,c)};return[(...c)=>{const u=Date.now(),d=u-n;d>=r?s(c,u):(o=c,a||(a=setTimeout(()=>{a=null,s(o)},r-d)))},()=>o&&s(o)]}const Pn=(e,t,n=3)=>{let r=0;const o=sc(50,250);return ic(a=>{const s=a.loaded,i=a.lengthComputable?a.total:void 0,l=s-r,c=o(l),u=s<=i;r=s;const d={loaded:s,total:i,progress:i?s/i:void 0,bytes:l,rate:c||void 0,estimated:c&&i&&u?(i-s)/c:void 0,event:a,lengthComputable:i!=null,[t?"download":"upload"]:!0};e(d)},n)},bo=(e,t)=>{const n=e!=null;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},Co=e=>(...t)=>E.asap(()=>e(...t)),lc=Te.hasStandardBrowserEnv?((e,t)=>n=>(n=new URL(n,Te.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)))(new URL(Te.origin),Te.navigator&&/(msie|trident)/i.test(Te.navigator.userAgent)):()=>!0,cc=Te.hasStandardBrowserEnv?{write(e,t,n,r,o,a){const s=[e+"="+encodeURIComponent(t)];E.isNumber(n)&&s.push("expires="+new Date(n).toGMTString()),E.isString(r)&&s.push("path="+r),E.isString(o)&&s.push("domain="+o),a===!0&&s.push("secure"),document.cookie=s.join("; ")},read(e){const t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove(e){this.write(e,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function uc(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function dc(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function ga(e,t,n){let r=!uc(t);return e&&r||n==!1?dc(e,t):t}const Eo=e=>e instanceof Oe?{...e}:e;function bt(e,t){t=t||{};const n={};function r(c,u,d,h){return E.isPlainObject(c)&&E.isPlainObject(u)?E.merge.call({caseless:h},c,u):E.isPlainObject(u)?E.merge({},u):E.isArray(u)?u.slice():u}function o(c,u,d,h){if(E.isUndefined(u)){if(!E.isUndefined(c))return r(void 0,c,d,h)}else return r(c,u,d,h)}function a(c,u){if(!E.isUndefined(u))return r(void 0,u)}function s(c,u){if(E.isUndefined(u)){if(!E.isUndefined(c))return r(void 0,c)}else return r(void 0,u)}function i(c,u,d){if(d in t)return r(c,u);if(d in e)return r(void 0,c)}const l={url:a,method:a,data:a,baseURL:s,transformRequest:s,transformResponse:s,paramsSerializer:s,timeout:s,timeoutMessage:s,withCredentials:s,withXSRFToken:s,adapter:s,responseType:s,xsrfCookieName:s,xsrfHeaderName:s,onUploadProgress:s,onDownloadProgress:s,decompress:s,maxContentLength:s,maxBodyLength:s,beforeRedirect:s,transport:s,httpAgent:s,httpsAgent:s,cancelToken:s,socketPath:s,responseEncoding:s,validateStatus:i,headers:(c,u,d)=>o(Eo(c),Eo(u),d,!0)};return E.forEach(Object.keys(Object.assign({},e,t)),function(u){const d=l[u]||o,h=d(e[u],t[u],u);E.isUndefined(h)&&d!==i||(n[u]=h)}),n}const va=e=>{const t=bt({},e);let{data:n,withXSRFToken:r,xsrfHeaderName:o,xsrfCookieName:a,headers:s,auth:i}=t;t.headers=s=Oe.from(s),t.url=da(ga(t.baseURL,t.url),e.params,e.paramsSerializer),i&&s.set("Authorization","Basic "+btoa((i.username||"")+":"+(i.password?unescape(encodeURIComponent(i.password)):"")));let l;if(E.isFormData(n)){if(Te.hasStandardBrowserEnv||Te.hasStandardBrowserWebWorkerEnv)s.setContentType(void 0);else if((l=s.getContentType())!==!1){const[c,...u]=l?l.split(";").map(d=>d.trim()).filter(Boolean):[];s.setContentType([c||"multipart/form-data",...u].join("; "))}}if(Te.hasStandardBrowserEnv&&(r&&E.isFunction(r)&&(r=r(t)),r||r!==!1&&lc(t.url))){const c=o&&a&&cc.read(a);c&&s.set(o,c)}return t},fc=typeof XMLHttpRequest<"u",hc=fc&&function(e){return new Promise(function(n,r){const o=va(e);let a=o.data;const s=Oe.from(o.headers).normalize();let{responseType:i,onUploadProgress:l,onDownloadProgress:c}=o,u,d,h,w,m;function p(){w&&w(),m&&m(),o.cancelToken&&o.cancelToken.unsubscribe(u),o.signal&&o.signal.removeEventListener("abort",u)}let y=new XMLHttpRequest;y.open(o.method.toUpperCase(),o.url,!0),y.timeout=o.timeout;function L(){if(!y)return;const R=Oe.from("getAllResponseHeaders"in y&&y.getAllResponseHeaders()),T={data:!i||i==="text"||i==="json"?y.responseText:y.response,status:y.status,statusText:y.statusText,headers:R,config:e,request:y};ma(function(S){n(S),p()},function(S){r(S),p()},T),y=null}"onloadend"in y?y.onloadend=L:y.onreadystatechange=function(){!y||y.readyState!==4||y.status===0&&!(y.responseURL&&y.responseURL.indexOf("file:")===0)||setTimeout(L)},y.onabort=function(){y&&(r(new $("Request aborted",$.ECONNABORTED,e,y)),y=null)},y.onerror=function(){r(new $("Network Error",$.ERR_NETWORK,e,y)),y=null},y.ontimeout=function(){let P=o.timeout?"timeout of "+o.timeout+"ms exceeded":"timeout exceeded";const T=o.transitional||fa;o.timeoutErrorMessage&&(P=o.timeoutErrorMessage),r(new $(P,T.clarifyTimeoutError?$.ETIMEDOUT:$.ECONNABORTED,e,y)),y=null},a===void 0&&s.setContentType(null),"setRequestHeader"in y&&E.forEach(s.toJSON(),function(P,T){y.setRequestHeader(T,P)}),E.isUndefined(o.withCredentials)||(y.withCredentials=!!o.withCredentials),i&&i!=="json"&&(y.responseType=o.responseType),c&&([h,m]=Pn(c,!0),y.addEventListener("progress",h)),l&&y.upload&&([d,w]=Pn(l),y.upload.addEventListener("progress",d),y.upload.addEventListener("loadend",w)),(o.cancelToken||o.signal)&&(u=R=>{y&&(r(!R||R.type?new Ot(null,e,y):R),y.abort(),y=null)},o.cancelToken&&o.cancelToken.subscribe(u),o.signal&&(o.signal.aborted?u():o.signal.addEventListener("abort",u)));const b=ac(o.url);if(b&&Te.protocols.indexOf(b)===-1){r(new $("Unsupported protocol "+b+":",$.ERR_BAD_REQUEST,e));return}y.send(a||null)})},pc=(e,t)=>{const{length:n}=e=e?e.filter(Boolean):[];if(t||n){let r=new AbortController,o;const a=function(c){if(!o){o=!0,i();const u=c instanceof Error?c:this.reason;r.abort(u instanceof $?u:new Ot(u instanceof Error?u.message:u))}};let s=t&&setTimeout(()=>{s=null,a(new $(`timeout ${t} of ms exceeded`,$.ETIMEDOUT))},t);const i=()=>{e&&(s&&clearTimeout(s),s=null,e.forEach(c=>{c.unsubscribe?c.unsubscribe(a):c.removeEventListener("abort",a)}),e=null)};e.forEach(c=>c.addEventListener("abort",a));const{signal:l}=r;return l.unsubscribe=()=>E.asap(i),l}},mc=function*(e,t){let n=e.byteLength;if(n<t){yield e;return}let r=0,o;for(;r<n;)o=r+t,yield e.slice(r,o),r=o},gc=async function*(e,t){for await(const n of vc(e))yield*mc(n,t)},vc=async function*(e){if(e[Symbol.asyncIterator]){yield*e;return}const t=e.getReader();try{for(;;){const{done:n,value:r}=await t.read();if(n)break;yield r}}finally{await t.cancel()}},xo=(e,t,n,r)=>{const o=gc(e,t);let a=0,s,i=l=>{s||(s=!0,r&&r(l))};return new ReadableStream({async pull(l){try{const{done:c,value:u}=await o.next();if(c){i(),l.close();return}let d=u.byteLength;if(n){let h=a+=d;n(h)}l.enqueue(new Uint8Array(u))}catch(c){throw i(c),c}},cancel(l){return i(l),o.return()}},{highWaterMark:2})},$n=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",ya=$n&&typeof ReadableStream=="function",yc=$n&&(typeof TextEncoder=="function"?(e=>t=>e.encode(t))(new TextEncoder):async e=>new Uint8Array(await new Response(e).arrayBuffer())),wa=(e,...t)=>{try{return!!e(...t)}catch{return!1}},wc=ya&&wa(()=>{let e=!1;const t=new Request(Te.origin,{body:new ReadableStream,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!t}),Lo=64*1024,gr=ya&&wa(()=>E.isReadableStream(new Response("").body)),_n={stream:gr&&(e=>e.body)};$n&&(e=>{["text","arrayBuffer","blob","formData","stream"].forEach(t=>{!_n[t]&&(_n[t]=E.isFunction(e[t])?n=>n[t]():(n,r)=>{throw new $(`Response type '${t}' is not supported`,$.ERR_NOT_SUPPORT,r)})})})(new Response);const Sc=async e=>{if(e==null)return 0;if(E.isBlob(e))return e.size;if(E.isSpecCompliantForm(e))return(await new Request(Te.origin,{method:"POST",body:e}).arrayBuffer()).byteLength;if(E.isArrayBufferView(e)||E.isArrayBuffer(e))return e.byteLength;if(E.isURLSearchParams(e)&&(e=e+""),E.isString(e))return(await yc(e)).byteLength},bc=async(e,t)=>{const n=E.toFiniteNumber(e.getContentLength());return n??Sc(t)},Cc=$n&&(async e=>{let{url:t,method:n,data:r,signal:o,cancelToken:a,timeout:s,onDownloadProgress:i,onUploadProgress:l,responseType:c,headers:u,withCredentials:d="same-origin",fetchOptions:h}=va(e);c=c?(c+"").toLowerCase():"text";let w=pc([o,a&&a.toAbortSignal()],s),m;const p=w&&w.unsubscribe&&(()=>{w.unsubscribe()});let y;try{if(l&&wc&&n!=="get"&&n!=="head"&&(y=await bc(u,r))!==0){let T=new Request(t,{method:"POST",body:r,duplex:"half"}),H;if(E.isFormData(r)&&(H=T.headers.get("content-type"))&&u.setContentType(H),T.body){const[S,_]=bo(y,Pn(Co(l)));r=xo(T.body,Lo,S,_)}}E.isString(d)||(d=d?"include":"omit");const L="credentials"in Request.prototype;m=new Request(t,{...h,signal:w,method:n.toUpperCase(),headers:u.normalize().toJSON(),body:r,duplex:"half",credentials:L?d:void 0});let b=await fetch(m);const R=gr&&(c==="stream"||c==="response");if(gr&&(i||R&&p)){const T={};["status","statusText","headers"].forEach(G=>{T[G]=b[G]});const H=E.toFiniteNumber(b.headers.get("content-length")),[S,_]=i&&bo(H,Pn(Co(i),!0))||[];b=new Response(xo(b.body,Lo,S,()=>{_&&_(),p&&p()}),T)}c=c||"text";let P=await _n[E.findKey(_n,c)||"text"](b,e);return!R&&p&&p(),await new Promise((T,H)=>{ma(T,H,{data:P,headers:Oe.from(b.headers),status:b.status,statusText:b.statusText,config:e,request:m})})}catch(L){throw p&&p(),L&&L.name==="TypeError"&&/fetch/i.test(L.message)?Object.assign(new $("Network Error",$.ERR_NETWORK,e,m),{cause:L.cause||L}):$.from(L,L&&L.code,e,m)}}),vr={http:Fl,xhr:hc,fetch:Cc};E.forEach(vr,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const Ro=e=>`- ${e}`,Ec=e=>E.isFunction(e)||e===null||e===!1,Sa={getAdapter:e=>{e=E.isArray(e)?e:[e];const{length:t}=e;let n,r;const o={};for(let a=0;a<t;a++){n=e[a];let s;if(r=n,!Ec(n)&&(r=vr[(s=String(n)).toLowerCase()],r===void 0))throw new $(`Unknown adapter '${s}'`);if(r)break;o[s||"#"+a]=r}if(!r){const a=Object.entries(o).map(([i,l])=>`adapter ${i} `+(l===!1?"is not supported by the environment":"is not available in the build"));let s=t?a.length>1?`since :
34
34
  `+a.map(Ro).join(`
35
35
  `):" "+Ro(a[0]):"as no adapter specified";throw new $("There is no suitable adapter to dispatch the request "+s,"ERR_NOT_SUPPORT")}return r},adapters:vr};function rr(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Ot(null,e)}function ko(e){return rr(e),e.headers=Oe.from(e.headers),e.data=nr.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),Sa.getAdapter(e.adapter||nn.adapter)(e).then(function(r){return rr(e),r.data=nr.call(e,e.transformResponse,r),r.headers=Oe.from(r.headers),r},function(r){return pa(r)||(rr(e),r&&r.response&&(r.response.data=nr.call(e,e.transformResponse,r.response),r.response.headers=Oe.from(r.response.headers))),Promise.reject(r)})}const ba="1.8.1",zn={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{zn[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});const No={};zn.transitional=function(t,n,r){function o(a,s){return"[Axios v"+ba+"] Transitional option '"+a+"'"+s+(r?". "+r:"")}return(a,s,i)=>{if(t===!1)throw new $(o(s," has been removed"+(n?" in "+n:"")),$.ERR_DEPRECATED);return n&&!No[s]&&(No[s]=!0,console.warn(o(s," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(a,s,i):!0}};zn.spelling=function(t){return(n,r)=>(console.warn(`${r} is likely a misspelling of ${t}`),!0)};function xc(e,t,n){if(typeof e!="object")throw new $("options must be an object",$.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let o=r.length;for(;o-- >0;){const a=r[o],s=t[a];if(s){const i=e[a],l=i===void 0||s(i,a,e);if(l!==!0)throw new $("option "+a+" must be "+l,$.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new $("Unknown option "+a,$.ERR_BAD_OPTION)}}const xn={assertOptions:xc,validators:zn},Qe=xn.validators;let St=class{constructor(t){this.defaults=t,this.interceptors={request:new wo,response:new wo}}async request(t,n){try{return await this._request(t,n)}catch(r){if(r instanceof Error){let o={};Error.captureStackTrace?Error.captureStackTrace(o):o=new Error;const a=o.stack?o.stack.replace(/^.+\n/,""):"";try{r.stack?a&&!String(r.stack).endsWith(a.replace(/^.+\n.+\n/,""))&&(r.stack+=`
36
- `+a):r.stack=a}catch{}}throw r}}_request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=bt(this.defaults,n);const{transitional:r,paramsSerializer:o,headers:a}=n;r!==void 0&&xn.assertOptions(r,{silentJSONParsing:Qe.transitional(Qe.boolean),forcedJSONParsing:Qe.transitional(Qe.boolean),clarifyTimeoutError:Qe.transitional(Qe.boolean)},!1),o!=null&&(E.isFunction(o)?n.paramsSerializer={serialize:o}:xn.assertOptions(o,{encode:Qe.function,serialize:Qe.function},!0)),n.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?n.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:n.allowAbsoluteUrls=!0),xn.assertOptions(n,{baseUrl:Qe.spelling("baseURL"),withXsrfToken:Qe.spelling("withXSRFToken")},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let s=a&&E.merge(a.common,a[n.method]);a&&E.forEach(["delete","get","head","post","put","patch","common"],m=>{delete a[m]}),n.headers=Oe.concat(s,a);const i=[];let l=!0;this.interceptors.request.forEach(function(p){typeof p.runWhen=="function"&&p.runWhen(n)===!1||(l=l&&p.synchronous,i.unshift(p.fulfilled,p.rejected))});const c=[];this.interceptors.response.forEach(function(p){c.push(p.fulfilled,p.rejected)});let u,d=0,h;if(!l){const m=[ko.bind(this),void 0];for(m.unshift.apply(m,i),m.push.apply(m,c),h=m.length,u=Promise.resolve(n);d<h;)u=u.then(m[d++],m[d++]);return u}h=i.length;let w=n;for(d=0;d<h;){const m=i[d++],p=i[d++];try{w=m(w)}catch(y){p.call(this,y);break}}try{u=ko.call(this,w)}catch(m){return Promise.reject(m)}for(d=0,h=c.length;d<h;)u=u.then(c[d++],c[d++]);return u}getUri(t){t=bt(this.defaults,t);const n=ga(t.baseURL,t.url,t.allowAbsoluteUrls);return da(n,t.params,t.paramsSerializer)}};E.forEach(["delete","get","head","options"],function(t){St.prototype[t]=function(n,r){return this.request(bt(r||{},{method:t,url:n,data:(r||{}).data}))}});E.forEach(["post","put","patch"],function(t){function n(r){return function(a,s,i){return this.request(bt(i||{},{method:t,headers:r?{"Content-Type":"multipart/form-data"}:{},url:a,data:s}))}}St.prototype[t]=n(),St.prototype[t+"Form"]=n(!0)});let Lc=class Ca{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(a){n=a});const r=this;this.promise.then(o=>{if(!r._listeners)return;let a=r._listeners.length;for(;a-- >0;)r._listeners[a](o);r._listeners=null}),this.promise.then=o=>{let a;const s=new Promise(i=>{r.subscribe(i),a=i}).then(o);return s.cancel=function(){r.unsubscribe(a)},s},t(function(a,s,i){r.reason||(r.reason=new Ot(a,s,i),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const n=this._listeners.indexOf(t);n!==-1&&this._listeners.splice(n,1)}toAbortSignal(){const t=new AbortController,n=r=>{t.abort(r)};return this.subscribe(n),t.signal.unsubscribe=()=>this.unsubscribe(n),t.signal}static source(){let t;return{token:new Ca(function(o){t=o}),cancel:t}}};function Rc(e){return function(n){return e.apply(null,n)}}function kc(e){return E.isObject(e)&&e.isAxiosError===!0}const yr={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(yr).forEach(([e,t])=>{yr[t]=e});function Ea(e){const t=new St(e),n=ea(St.prototype.request,t);return E.extend(n,St.prototype,t,{allOwnKeys:!0}),E.extend(n,t,null,{allOwnKeys:!0}),n.create=function(o){return Ea(bt(e,o))},n}const ue=Ea(nn);ue.Axios=St;ue.CanceledError=Ot;ue.CancelToken=Lc;ue.isCancel=pa;ue.VERSION=ba;ue.toFormData=Vn;ue.AxiosError=$;ue.Cancel=ue.CanceledError;ue.all=function(t){return Promise.all(t)};ue.spread=Rc;ue.isAxiosError=kc;ue.mergeConfig=bt;ue.AxiosHeaders=Oe;ue.formToJSON=e=>ha(E.isHTMLForm(e)?new FormData(e):e);ue.getAdapter=Sa.getAdapter;ue.HttpStatusCode=yr;ue.default=ue;const{Axios:sf,AxiosError:Nc,CanceledError:lf,isCancel:cf,CancelToken:uf,VERSION:df,all:ff,Cancel:hf,isAxiosError:pf,spread:mf,toFormData:gf,AxiosHeaders:vf,HttpStatusCode:yf,formToJSON:wf,getAdapter:Sf,mergeConfig:bf}=ue,gn="https://localhost:5043",et=async e=>{var h,w;const{url:t,withToken:n,method:r,body:o,contentType:a,typeToken:s="seller"}=e,i=n?localStorage.getItem("sellerAccessToken"):null,l=n?localStorage.getItem("token"):null,c=s==="seller"?i:l,u=localStorage.getItem("dv"),d={};a&&!(o instanceof FormData)?d["Content-Type"]=a:o instanceof FormData||(d["Content-Type"]="application/json"),n&&c&&(d.Authorization=`Bearer ${c}`);try{let m=null;switch(r){case"get":m=await ue.get(u?gn:t,{headers:d});break;case"post":m=await ue.post(u?gn:t,o,{headers:d});break;case"put":m=await ue.put(u?gn:t,o,{headers:d});break;case"delete":m=await ue.delete(u?gn:t,{headers:d});break}return{data:m==null?void 0:m.data,status:m==null?void 0:m.status,headers:m==null?void 0:m.headers}}catch(m){const p=m,y=(h=p.response)==null?void 0:h.data;let L="Something Went Wrong";y&&(L=y.errors[0]);const b=(w=p.response)==null?void 0:w.status;if(b===401)try{const P=await Promise.resolve().then(()=>require("./charge-Dd6podcM.cjs")).then(T=>T.auth);P&&P.logoutCustomer?await P.logoutCustomer():localStorage.removeItem("token"),window.location.reload()}catch(P){console.error("Failed to import logoutCustomer:",P),localStorage.removeItem("token"),window.location.reload()}const R=new Nc(L,(b==null?void 0:b.toString())||"400");throw R.response=p.response,R}},Tc="https://g-api.billgang.com",Pc="https://www.googleapis.com/webfonts/v1/webfonts",_c="https://stores-api.billgang.com",Oc="https://sl-api.billgang.com",Mc="https://customers-api.billgang.com",Ac="https://cashapp-api.billgang.com",Dc={api:Tc,googleFonts:Pc,storeApi:_c,slApi:Oc,customersApi:Mc,cashappApi:Ac},Ic=(e,t="300")=>e==="not found"?"empty":`https://imagedelivery.net/${e}/w=${t}`,Fc=e=>{const t=new Intl.NumberFormat("en-US",{style:"currency",currency:e.currency||"USD"});let n=e.amount;return e.quantity&&(n=n*e.quantity),t.format(n)},Bc=(e,t)=>{if(e===0)throw new Error("Old value cannot be zero, as it would result in division by zero.");return(t-e)/Math.abs(e)*100},jc=e=>{if(Math.abs(e-365)<=15){const a=Math.round(e/365);return a===1?"year":`${a} years`}else if(Math.abs(e-30)<=5){const a=Math.round(e/30);return a===1?"month":`${a} months`}else return`${e} days`},Hc=e=>new Date(e).toLocaleDateString("en-US",{year:"numeric",month:"short",day:"numeric"}),Uc=e=>{const t=new Date(e),n={day:"2-digit",month:"2-digit",year:"numeric"},r={hour:"2-digit",minute:"2-digit"},o=t.toLocaleString("en-US",n),a=t.toLocaleString("en-US",r);return[o,a]},wr=e=>{const t=window.localStorage.getItem(e);if(t===null)return null;try{return JSON.parse(t)}catch{return t}},To=(e,t)=>{(t===null||typeof t!="object")&&window.localStorage.setItem(e,String(t));const n=JSON.stringify(t);window.localStorage.setItem(e,n)},or="f10120ab-7ebb-4785-b240-7428edaa3c4e",Vt="https://t-api.billgang.com",$t="https://internal-t-api.antistock.io",qt="I",Vc=10*1e3,$c=15*1e3,zc=15*60*1e3,xa=()=>{var t;const e=wr(qt);return((t=e==null?void 0:e.s)==null?void 0:t.i)||null},Jc=(e,t="production",n)=>{const{pathname:r}=qe(),o=we.useRef(),a=we.useRef(document.visibilityState);we.useEffect(()=>{if(!e)return;const s=()=>Date.now(),i=async()=>(await et({url:`${n?$t:Vt}/${e}/t/p`,method:"post",withToken:!1})).data.data.id,l=async m=>(await et({url:`${n?$t:Vt}/${e}/t/p/${t==="development"?or:m}/s`,method:"post",withToken:!1})).data.data.id,c=async(m,p,y,L)=>{const b=t==="development"?or:m;try{return(await et({url:`${n?$t:Vt}/${e}/t/p/${b}/s/${p}/e`,method:"post",withToken:!1,body:{url:y,oldEventId:L},contentType:"application/json"})).data.data.id}catch{return p=await l(m),(await et({url:`${n?$t:Vt}/${e}/t/p/${b}/s/${p}/e`,method:"post",withToken:!1,body:{url:y},contentType:"application/json"})).data.data.id}},u=async(m,p,y)=>{await et({url:`${n?$t:Vt}/${e}/t/p/${t==="development"?or:m}/s/${p}/e/${y}/h`,method:"post",withToken:!1});const b=wr(qt);b&&(b.s.u=s().toString(),b.lu=s().toString(),To(qt,b))},d=(m,p,y)=>{o.current&&clearInterval(o.current),o.current=setInterval(async()=>{if(document.visibilityState==="visible")try{await u(m,p,y)}catch{await h()}},Vc)},h=async()=>{var L,b,R,P;const m=`${window.location.hostname}${r}`,p=wr(qt),y=s();try{let T=p==null?void 0:p.p;T||(T=await i());let H=(L=p==null?void 0:p.s)==null?void 0:L.i;const S=Number(((b=p==null?void 0:p.s)==null?void 0:b.u)||((R=p==null?void 0:p.s)==null?void 0:R.c)),_=!H||y-S>zc;(!H||_)&&(H=await l(T));const G=Number((p==null?void 0:p.lu)||0),B=y-G>$c,ae=await c(T,H,m,p!=null&&p.l&&!B?p.l:void 0),se={p:T,s:{i:H,c:((P=p==null?void 0:p.s)==null?void 0:P.c)??y.toString(),u:y.toString()},l:ae,lu:y.toString()};To(qt,se),d(T,H,ae)}catch(T){console.error("[TrackingAnalytics] error",T)}};h();const w=()=>{document.visibilityState==="visible"&&a.current!=="visible"&&h(),a.current=document.visibilityState};return document.addEventListener("visibilitychange",w),()=>{o.current&&clearInterval(o.current),document.removeEventListener("visibilitychange",w)}},[r,e,t])},Wc={customerEmail:"",recaptcha:"",gateway:"",paymentMethod:"",parts:[],customFields:{},discordSocialConnectId:null,coupon:null,tsId:xa()};let Nt=null;const Po=localStorage.getItem("token");if(Po)try{Nt=Qo(JSON.parse(Po)||"")}catch{Nt=null}const qc=ie(e=>({cart:{...Wc,customerEmail:Nt?Nt.email:""},products:[],coupon:null,pending:!1,applyCouponPending:!1,customerEmail:Nt?Nt.email:"",recaptcha:"",priceAdjustment:null,serviceFee:null,replacementConfig:null,setCart:t=>e(n=>({cart:typeof t=="function"?t(n.cart):t})),setProducts:t=>e(n=>({products:typeof t=="function"?t(n.products):t})),setRecaptcha:t=>e({recaptcha:t}),setCoupon:t=>e({coupon:t}),setPending:t=>e({pending:t}),setApplyCouponPending:t=>e({applyCouponPending:t}),setCustomerEmail:t=>e({customerEmail:t}),setPriceAdjustment:t=>e({priceAdjustment:t}),setServiceFee:t=>e({serviceFee:t}),setReplacementConfig:t=>e({replacementConfig:t}),setUsePriorityReplacement:t=>e(n=>({cart:{...n.cart,usePriorityReplacement:t}}))})),Zc=ie(e=>({page:1,setPage:t=>e(()=>({page:t})),resetPage:()=>e(()=>({page:1}))})),Gc=ie(e=>({discordInfo:null,setDiscordInfo:t=>e(()=>({discordInfo:t}))})),Kc=ie(e=>({subscription:null,setSubscription:t=>e({subscription:t})})),Mt=ie(e=>({apiUrls:Dc,setApiUrls:t=>e(()=>({apiUrls:t}))})),La=ie(e=>({header:null,footer:null,announcement:null,setHeader:t=>e(()=>({header:t})),setFooter:t=>e(()=>({footer:t})),setAnnouncement:t=>e(()=>({announcement:t})),blocks:null,setBlocks:t=>e(()=>({blocks:t})),activeBlock:null,setActiveBlock:t=>e(()=>({activeBlock:t})),sourceBlocks:{},setSourceBlocks:t=>e(()=>({sourceBlocks:t})),currentInstance:null,setCurrentInstance:t=>e(()=>({currentInstance:t})),settings:null,setSettings:t=>e(()=>({settings:t})),settingsInstance:null,setSettingsInstance:t=>e(()=>({settingsInstance:t}))})),Jn=ie(e=>({general:null,setGeneral:t=>e(()=>({general:t})),isAntistock:!1,setIsAntistock:t=>e(()=>({isAntistock:t}))})),Sr=ie(e=>({settings:null,setSettings:t=>{e(()=>({settings:t}))},isLoadingSettings:!0,setIsLoadingSettings:t=>e(()=>({isLoadingSettings:t}))})),On=ie((e,t)=>({activeBlock:null,setActiveBlock:n=>e(()=>({activeBlock:n})),activeFont:null,setActiveFont:n=>e(()=>({activeFont:n})),setThemeSettings:n=>e(()=>({themeSettings:n})),activeColorCategory:null,setActiveColorCategory:n=>e(()=>({activeColorCategory:n})),themeSettings:{colors:{text:{primary:"#252525",secondary:"#757575",tertiary:"#C2C2C2",inverted:"#FFFFFF",action:"#FF3F19",actionHover:"#DA2400",disabled:"#C2C2C2",warning:"#C1972A",error:"#C12A2A",success:"#338B13",information:"#3683F7",link:"#3683F7"},icon:{primary:"#252525",secondary:"#555555",tertiary:"#C2C2C2",inverted:"#FFFFFF",action:"#FF3F19",actionHover:"#DA2400",disabled:"#C2C2C2",warning:"#C1972A",error:"#C12A2A",success:"#338B13",information:"#3683F7",link:"#3683F7"},border:{primary:"#C2C2C2",secondary:"#E6E6E6",action:"#FF3F19",actionHover:"#DA2400",disabled:"#E6E6E6",warning:"#C1972A",error:"#C12A2A",success:"#338B13",information:"#3683F7",focus:"#FF3F19"},surface:{primary:"#FFFFFF",secondary:"#F8F8F8",action1:"#FF3F19",action1Hover:"#DA2400",action2:"#FFFFFF",action2Hover:"#F8F8F8",disabled:"#C2C2C2",warning:"#FAF4E6",error:"#FAE6E6",success:"#E5FADD",information:"#E9F1FE",modal:"rgba(1, 1, 4, 0.4)"}},fonts:{mobile:{fontSizePercentage:30},tablet:{fontSizePercentage:50},desktop:{heading:{h1:{font:"Archivo",weight:"700",size:48,boldWeight:"900",case:"normal"},h2:{font:"Archivo",weight:"700",size:32,boldWeight:"800",case:"normal"},h3:{font:"Archivo",weight:"600",size:24,boldWeight:"700",case:"normal"},h4:{font:"Archivo",weight:"500",size:20,boldWeight:"700",case:"normal"},h5:{font:"Archivo",weight:"400",size:16,boldWeight:"700",case:"normal"},h6:{font:"Archivo",weight:"400",size:14,boldWeight:"700",case:"uppercase"},h7:{font:"Archivo",weight:"400",size:14,boldWeight:"700",case:"normal"}},body:{lg:{font:"Archivo",size:16,weight:"400",boldWeight:"700",case:"normal"},md:{font:"Archivo",size:14,weight:"400",boldWeight:"700",case:"normal"},sm:{font:"Archivo",size:12,weight:"400",boldWeight:"700",case:"normal"}}}},borders:{radius:"var(--radius-lg)",thickness:"var(--border-none)"},buttons:{primary:{size:26,alignment:"left",radius:32,height:40,background:"#ff3f19",hover:!0,font:"Archivo",boxShadow:{left:0,top:0,blur:0,spread:0,color:"#000000"},color:"#ffffff",colorHover:"#ffffff",backgroundHover:"#ff3f19"},secondary:{size:26,alignment:"left",radius:10,height:20,background:"#c2c2c2",hover:!1,font:"Archivo",boxShadow:{left:0,top:4,blur:10,spread:0,color:"#000000"},color:"#757575",colorHover:"#757575",backgroundHover:"#c2c2c2"},tertiary:{size:12,alignment:"left",radius:30,height:30,background:"#c2c2c2",hover:!0,font:"Archivo",boxShadow:{left:0,top:4,blur:10,spread:0,color:"#000000"},color:"#757575",colorHover:"#757575",backgroundHover:"#c2c2c2"}},inputs:{field:{color:"#f3f3f3",active:!0,opacity:40},label:{size:14,color:"#555555",height:40,alignment:"left"},border:{color:"#f3f3f3",style:"solid",active:!0,radius:14,thickness:0},general:{size:14,color:"#252525",height:40},placeholder:{color:"#C2C2C2"}}},updateColor:(n,r,o)=>e(a=>{const s=JSON.parse(JSON.stringify(t().themeSettings));Pe.getState().addHistory({themeSettings:s});const i={...a.themeSettings.colors,[n]:{...a.themeSettings.colors[n],[r]:o}};return{themeSettings:{...a.themeSettings,colors:i}}}),updateFont:(n,r,o,a,s)=>e(i=>{const l=JSON.parse(JSON.stringify(t().themeSettings));Pe.getState().addHistory({themeSettings:l});const c={...i.themeSettings.fonts,[n]:{...i.themeSettings.fonts[n],[r]:{...i.themeSettings.fonts[n][r],[o]:{...i.themeSettings.fonts[n][r][o],[a]:s}}}};return{themeSettings:{...i.themeSettings,fonts:c}}}),updateFontSizePercentage:(n,r)=>e(o=>{const a=JSON.parse(JSON.stringify(t().themeSettings));Pe.getState().addHistory({themeSettings:a});const s={...o.themeSettings.fonts,[n]:{...o.themeSettings.fonts[n],fontSizePercentage:r}};return{themeSettings:{...o.themeSettings,fonts:s}}}),updateBorder:(n,r)=>e(o=>{const a=JSON.parse(JSON.stringify(t().themeSettings));Pe.getState().addHistory({themeSettings:a});const s={...o.themeSettings.borders,[n]:r};return{themeSettings:{...o.themeSettings,borders:s}}}),updateButton:(n,r,o)=>e(a=>{const s=JSON.parse(JSON.stringify(t().themeSettings));Pe.getState().addHistory({themeSettings:s});const i={...a.themeSettings.buttons[n],[r]:o},l={...a.themeSettings.buttons,[n]:i};return{themeSettings:{...a.themeSettings,buttons:l}}}),updateInput:(n,r,o)=>e(a=>{const s=JSON.parse(JSON.stringify(t().themeSettings));return Pe.getState().addHistory({themeSettings:s}),{themeSettings:{...a.themeSettings,inputs:{...a.themeSettings.inputs,[n]:{...a.themeSettings.inputs[n],[o]:r}}}}}),isLoadingThemeSettings:!1,setIsLoadingThemeSettings:n=>e(()=>({isLoadingThemeSettings:n}))})),De=ie(e=>({notifications:[],setNotifications:t=>e(()=>({notifications:t}))})),Yc=ie(e=>({isOpen:!0,setIsOpen:t=>e(()=>({isOpen:t}))}));var ke=[];for(var ar=0;ar<256;++ar)ke.push((ar+256).toString(16).slice(1));function Xc(e,t=0){return(ke[e[t+0]]+ke[e[t+1]]+ke[e[t+2]]+ke[e[t+3]]+"-"+ke[e[t+4]]+ke[e[t+5]]+"-"+ke[e[t+6]]+ke[e[t+7]]+"-"+ke[e[t+8]]+ke[e[t+9]]+"-"+ke[e[t+10]]+ke[e[t+11]]+ke[e[t+12]]+ke[e[t+13]]+ke[e[t+14]]+ke[e[t+15]]).toLowerCase()}var vn,Qc=new Uint8Array(16);function eu(){if(!vn&&(vn=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!vn))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return vn(Qc)}var tu=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto);const _o={randomUUID:tu};function st(e,t,n){if(_o.randomUUID&&!e)return _o.randomUUID();e=e||{};var r=e.random||(e.rng||eu)();return r[6]=r[6]&15|64,r[8]=r[8]&63|128,Xc(r)}function nu(e,t){let n;try{n=e()}catch{return}return{getItem:o=>{var a;const s=l=>l===null?null:JSON.parse(l,void 0),i=(a=n.getItem(o))!=null?a:null;return i instanceof Promise?i.then(s):s(i)},setItem:(o,a)=>n.setItem(o,JSON.stringify(a,void 0)),removeItem:o=>n.removeItem(o)}}const br=e=>t=>{try{const n=e(t);return n instanceof Promise?n:{then(r){return br(r)(n)},catch(r){return this}}}catch(n){return{then(r){return this},catch(r){return br(r)(n)}}}},ru=(e,t)=>(n,r,o)=>{let a={storage:nu(()=>localStorage),partialize:p=>p,version:0,merge:(p,y)=>({...y,...p}),...t},s=!1;const i=new Set,l=new Set;let c=a.storage;if(!c)return e((...p)=>{console.warn(`[zustand persist middleware] Unable to update item '${a.name}', the given storage is currently unavailable.`),n(...p)},r,o);const u=()=>{const p=a.partialize({...r()});return c.setItem(a.name,{state:p,version:a.version})},d=o.setState;o.setState=(p,y)=>{d(p,y),u()};const h=e((...p)=>{n(...p),u()},r,o);o.getInitialState=()=>h;let w;const m=()=>{var p,y;if(!c)return;s=!1,i.forEach(b=>{var R;return b((R=r())!=null?R:h)});const L=((y=a.onRehydrateStorage)==null?void 0:y.call(a,(p=r())!=null?p:h))||void 0;return br(c.getItem.bind(c))(a.name).then(b=>{if(b)if(typeof b.version=="number"&&b.version!==a.version){if(a.migrate)return[!0,a.migrate(b.state,b.version)];console.error("State loaded from storage couldn't be migrated since no migrate function was provided")}else return[!1,b.state];return[!1,void 0]}).then(b=>{var R;const[P,T]=b;if(w=a.merge(T,(R=r())!=null?R:h),n(w,!0),P)return u()}).then(()=>{L==null||L(w,void 0),w=r(),s=!0,l.forEach(b=>b(w))}).catch(b=>{L==null||L(void 0,b)})};return o.persist={setOptions:p=>{a={...a,...p},p.storage&&(c=p.storage)},clearStorage:()=>{c==null||c.removeItem(a.name)},getOptions:()=>a,rehydrate:()=>m(),hasHydrated:()=>s,onHydrate:p=>(i.add(p),()=>{i.delete(p)}),onFinishHydration:p=>(l.add(p),()=>{l.delete(p)})},a.skipHydration||m(),w||h},Wn=ru,Xt=ie(Wn((e,t)=>({pages:null,currentPage:"",setPages:n=>e(()=>({pages:n})),pageContext:{listings:null,products:null,reviews:null,categories:null,faqs:null,general:null,fullPosts:null,posts:null,preserveContent:!1,vouches:null},isOpenModal:!1,isOpenSelectModal:!1,isEdit:!1,editedPage:null,setEditedPage:n=>e(()=>({editedPage:n})),setCurrentPage:n=>e(()=>({currentPage:n})),setPageContext:n=>e(()=>({pageContext:n})),setIsOpenModal:n=>e(()=>({isOpenModal:n})),setIsOpenSelectModal:n=>e(()=>({isOpenSelectModal:n})),setIsEdit:n=>e(()=>({isEdit:n})),createPage:n=>{const r=t().pages,o=st();if(r)r[o]=n,e({pages:r});else{const a=t().setPages;a({});const s=t().pages;s[o]=n,e({pages:s})}},updatePage:(n,r)=>{const o=t().pages;o&&(o[n]={...r},e({pages:o}))},deletePage:n=>{const r=t().pages;r&&(delete r[n],e({pages:r}))}}),{name:"pages-storage",partialize:e=>{const{pages:t,pageContext:n}=e;return{pages:t,pageContext:n}}})),ou=ie(e=>({isOpenModal:!1,setIsOpenModal:t=>e(()=>({isOpenModal:t}))})),Mn=ie(Wn((e,t)=>({header:null,blocks:{},announcement:null,footer:null,currentBlock:null,positionBlock:null,setBlocks:n=>{e({blocks:n})},setHeader:(n,r=!0)=>{const o=JSON.parse(JSON.stringify(t().header)),a=JSON.parse(JSON.stringify(n));JSON.stringify(o)!==JSON.stringify(a)&&r&&Pe.getState().addHistory({header:o}),e({header:a})},setFooter:(n,r=!0)=>{const o=JSON.parse(JSON.stringify(t().footer)),a=JSON.parse(JSON.stringify(n));JSON.stringify(o)!==JSON.stringify(a)&&r&&Pe.getState().addHistory({footer:o}),e({footer:a})},setAnnouncement:(n,r=!0)=>{const o=JSON.parse(JSON.stringify(t().announcement)),a=JSON.parse(JSON.stringify(n));JSON.stringify(o)!==JSON.stringify(a)&&r&&Pe.getState().addHistory({announcement:o}),e({announcement:a})},createPage:n=>{const r=t().blocks;r[n]={data:{},order:[]},e({blocks:r})},deletePage:n=>{const r=t().blocks;delete r[n],e({blocks:r})},updatePage:(n,r)=>{const o=t().blocks;if(o[r])return;const a=o[n];delete o[n],o[r]=a,e({blocks:o})},setCurrentBlock:n=>{e({currentBlock:n})},setPositionBlock:(n,r=!1)=>{const{blocks:o}=t(),{currentPage:a,pages:s}=Xt.getState();if(!a||!s||!s[a]||!o[s[a].path]){console.error("Cannot set position: invalid page or block data");return}const i=s[a].path,l=o[i],c=n?l.order.indexOf(n):-1;if(c===-1&&n){console.error(`Block with ID "${n}" not found in page "${i}"`);return}const u=c!==-1?c+(r?1:0):l.order.length;e({positionBlock:u})},addBlock:(n,r)=>{const o=JSON.parse(JSON.stringify(t().blocks));Pe.getState().addHistory({layers:o});const a={...t().blocks},s=a[n]||{data:{},order:[]},i=t().positionBlock,l=st(),c={name:r.name,value:r.value};return s.data[l]=c,i===null||i>=s.order.length?s.order.push(l):s.order.splice(i,0,l),e({blocks:{...a,[n]:{data:s.data,order:s.order}},currentBlock:l,positionBlock:null}),De.getState().setNotifications([...De.getState().notifications,{id:st(),message:"Block successfully added",status:"success"}]),l},editBlock:(n,r,o)=>{const a=JSON.parse(JSON.stringify(t().blocks));Pe.getState().addHistory({layers:a});const s=t().blocks,i=s[n]||{};i.data[r]={name:o.name,value:{...o.value}},e({blocks:{...s,[n]:i}})},removeBlock:(n,r)=>{const o=JSON.parse(JSON.stringify(t().blocks));Pe.getState().addHistory({layers:o});const a=JSON.parse(JSON.stringify(t().blocks)),s=a[n];if(!s){console.error(`Page at path "${n}" does not exist.`);return}delete s.data[r],s.order=s.order.filter(i=>i!==r),e({blocks:{...a,[n]:s}}),De.getState().setNotifications([...De.getState().notifications,{id:st(),message:"Block successfully deleted",status:"success"}])},moveBlock:(n,r,o)=>e(a=>{const s=JSON.parse(JSON.stringify(t().blocks));if(Pe.getState().addHistory({layers:s}),!a.blocks[n])return console.error(`Path ${n} does not exist in blocks`),a;const i={...a.blocks[n]},l=[...i.order];if(r<0||o<0||r>=l.length||o>=l.length)return console.error(`Invalid indices: fromIndex=${r}, toIndex=${o}`),a;const[c]=l.splice(r,1);return l.splice(o,0,c),De.getState().setNotifications([...De.getState().notifications,{id:st(),message:"Block successfully moved",status:"success"}]),{blocks:{...a.blocks,[n]:{...i,order:l}}}}),duplicateBlock:(n,r)=>{const o=JSON.parse(JSON.stringify(t().blocks));Pe.getState().addHistory({layers:o});const a=JSON.parse(JSON.stringify(t().blocks)),s=a[n];if(!s||!s.data[r]){console.error(`Block with ID "${r}" not found in page "${n}"`);return}const i=st(),l=s.data[r],c={name:l.name,value:JSON.parse(JSON.stringify({...l.value}))};s.data[i]={...c};const u=s.order.indexOf(r);if(u===-1){console.error(`Block ID "${r}" not found in order array`);return}s.order.splice(u+1,0,i),e({blocks:{...a,[n]:s},currentBlock:i}),Ra.getState().setActiveBlock({id:i,neededScroll:!0}),De.getState().setNotifications([...De.getState().notifications,{id:st(),message:"Block successfully duplicated",status:"success"}])},isLoadingLayers:!1,setIsLoadingLayers:n=>e(()=>({isLoadingLayers:n}))}),{name:"layers-storage",partialize:e=>{const{blocks:t,header:n,footer:r,announcement:o}=e;return{blocks:t,header:n,footer:r,announcement:o}}})),Pe=ie((e,t)=>({past:[],future:[],addHistory:n=>{e(r=>{const o=r.past[r.past.length-1];return o&&JSON.stringify(o)===JSON.stringify(n)?r:{past:[...r.past,n],future:[]}})},undo:()=>{const{past:n,future:r}=t();if(n.length===0)return;const o=n[n.length-1],a=n.slice(0,-1),{blocks:s,header:i,footer:l,announcement:c,setBlocks:u,setHeader:d,setFooter:h,setAnnouncement:w}=Mn.getState(),{themeSettings:m,setThemeSettings:p}=On.getState(),y={themeSettings:JSON.parse(JSON.stringify(m)),layers:JSON.parse(JSON.stringify(s)),header:JSON.parse(JSON.stringify(i)),footer:JSON.parse(JSON.stringify(l)),announcement:JSON.parse(JSON.stringify(c))};e({past:a,future:[y,...r]}),o.themeSettings&&p(o.themeSettings),o.layers&&u(o.layers),o.header&&d(o.header,!1),o.footer&&h(o.footer,!1),o.announcement&&w(o.announcement,!1)},redo:()=>{const{past:n,future:r}=t();if(r.length===0)return;const{blocks:o,header:a,footer:s,announcement:i,setBlocks:l,setHeader:c,setFooter:u,setAnnouncement:d}=Mn.getState(),{themeSettings:h,setThemeSettings:w}=On.getState(),m=r[0],p=r.slice(1),y={themeSettings:JSON.parse(JSON.stringify(h)),layers:JSON.parse(JSON.stringify(o)),header:JSON.parse(JSON.stringify(a)),footer:JSON.parse(JSON.stringify(s)),announcement:JSON.parse(JSON.stringify(i))};e({past:[...n,y],future:p}),m.themeSettings&&w(m.themeSettings),m.layers&&l(m.layers),m.header&&c(m.header,!1),m.footer&&u(m.footer,!1),m.announcement&&d(m.announcement,!1)}})),Ra=ie(Wn(e=>({onPreview:!0,setOnPreview:t=>e(()=>({onPreview:t})),activeBlock:{id:null,neededScroll:!1},setActiveBlock:t=>e(()=>({activeBlock:t})),zoomLevel:1,setZoomLevel:t=>e(()=>({zoomLevel:t}))}),{name:"preview-storage",partialize:e=>{const{onPreview:t}=e;return{onPreview:t}}})),ka=[{icon:"TreeStructure",name:"Layers"},{icon:"Plus",name:"Add"},{icon:"Palette",name:"Theme"},{icon:"Gear",name:"Settings"}],au=[{icon:"Desktop",value:"desktop"},{icon:"DeviceTabletCamera",value:"tablet"},{icon:"DeviceMobileCamera",value:"mobile"}],su=[{icon:"PaintBrushBroad",name:"Colors"},{icon:"TextAa",name:"Fonts"},{icon:"CornersOut",name:"Borders"},{icon:"ArrowSquareIn",name:"Buttons"},{icon:"Textbox",name:"Inputs"}],iu=[6,8,10,12,14,16,18,20,24,28,32,40,48,52,56,60,64].map(e=>String(e)),lu=["/","/reviews","/faqs","/contact","/products","/ticket","/login"],zt={"/":{path:"/",name:"Home",icon:"HouseSimple",seo:{pageDescription:"",pageTitle:""},visibility:"public"},"/products":{path:"/products",name:"Products",icon:"SquaresFour",seo:{pageDescription:"",pageTitle:""},visibility:"public"},"/faqs":{path:"/faqs",name:"Faqs",icon:"SealQuestion",seo:{pageDescription:"",pageTitle:""},visibility:"public"},"/reviews":{path:"/reviews",name:"Reviews",icon:"Star",seo:{pageDescription:"",pageTitle:""},visibility:"public"},"/contact":{path:"/contact",name:"Contact",icon:"ChatCentered",seo:{pageDescription:"",pageTitle:""},visibility:"public"},"/ticket":{path:"/ticket",name:"Ticket",icon:"Ticket",seo:{pageDescription:"",pageTitle:""},visibility:"public"},"/login":{path:"/login",name:"Login",icon:"UserCircleGear",seo:{pageDescription:"",pageTitle:""},visibility:"public"}},cu=typeof window<"u"&&(window.location.hostname.includes("localhost")||window.location.hostname.includes("192")||window.location.hostname.includes("local-rst.sp-internal.work")),uu={None:"var(--radius-none)",4:"var(--radius-xs)",8:"var(--radius-sm)",12:"var(--radius-md)",16:"var(--radius-lg)",20:"var(--radius-xl)",24:"var(--radius-2xl)"},du={None:"var(--border-none)",1:"var(--border-sm)",2:"var(--border-md)",4:"var(--border-lg)"},fu={"1:1":"1:1","4:3":"4:3","16:9":"16:9","9:16":"9:16"},hu=[{value:"4:3",addon:k.jsx("div",{style:{width:24,height:24,display:"flex",alignItems:"center",justifyContent:"center"},children:k.jsx("div",{style:{width:18.5,height:14.5,border:"1.5px solid #252525",borderRadius:3}})})},{value:"16:9",addon:k.jsx("div",{style:{width:24,height:24,display:"flex",alignItems:"center",justifyContent:"center"},children:k.jsx("div",{style:{width:20.5,height:12.5,border:"1.5px solid #252525",borderRadius:3}})})},{value:"9:16",addon:k.jsx("div",{style:{width:24,height:24,display:"flex",alignItems:"center",justifyContent:"center"},children:k.jsx("div",{style:{width:14.5,height:18.5,border:"1.5px solid #252525",borderRadius:3}})})},{value:"1:1",addon:k.jsx("div",{style:{width:24,height:24,display:"flex",alignItems:"center",justifyContent:"center"},children:k.jsx("div",{style:{width:16.5,height:16.5,border:"1.5px solid #252525",borderRadius:3}})})}],pu={h1:"Heading 1",h2:"Heading 2",h3:"Heading 3",h4:"Heading 4",h5:"Heading 5",h6:"Heading 6",h7:"Heading 7",lg:"Paragraph Large",md:"Paragraph Medium",sm:"Paragraph Small"},mu=ie(e=>({activeBlock:ka[0],setActiveBlock:t=>e(()=>({activeBlock:t}))})),Na=ie(e=>({openModal:!1,setOpenModal:t=>e(()=>({openModal:t})),onChange:null,setOnChange:t=>e(()=>({onChange:t})),tip:"",setTip:t=>e(()=>({tip:t}))})),gu=ie(e=>({error:null,setError:t=>e(()=>({error:t}))})),Ta=ie(e=>({title:null,description:null,onConfirm:null,setTitle:t=>e(()=>({title:t})),setDescription:t=>e(()=>({description:t})),setOnConfirm:t=>e(()=>({onConfirm:t}))}));var vu=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Pa(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var _a={exports:{}};/*!
36
+ `+a):r.stack=a}catch{}}throw r}}_request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=bt(this.defaults,n);const{transitional:r,paramsSerializer:o,headers:a}=n;r!==void 0&&xn.assertOptions(r,{silentJSONParsing:Qe.transitional(Qe.boolean),forcedJSONParsing:Qe.transitional(Qe.boolean),clarifyTimeoutError:Qe.transitional(Qe.boolean)},!1),o!=null&&(E.isFunction(o)?n.paramsSerializer={serialize:o}:xn.assertOptions(o,{encode:Qe.function,serialize:Qe.function},!0)),n.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?n.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:n.allowAbsoluteUrls=!0),xn.assertOptions(n,{baseUrl:Qe.spelling("baseURL"),withXsrfToken:Qe.spelling("withXSRFToken")},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let s=a&&E.merge(a.common,a[n.method]);a&&E.forEach(["delete","get","head","post","put","patch","common"],m=>{delete a[m]}),n.headers=Oe.concat(s,a);const i=[];let l=!0;this.interceptors.request.forEach(function(p){typeof p.runWhen=="function"&&p.runWhen(n)===!1||(l=l&&p.synchronous,i.unshift(p.fulfilled,p.rejected))});const c=[];this.interceptors.response.forEach(function(p){c.push(p.fulfilled,p.rejected)});let u,d=0,h;if(!l){const m=[ko.bind(this),void 0];for(m.unshift.apply(m,i),m.push.apply(m,c),h=m.length,u=Promise.resolve(n);d<h;)u=u.then(m[d++],m[d++]);return u}h=i.length;let w=n;for(d=0;d<h;){const m=i[d++],p=i[d++];try{w=m(w)}catch(y){p.call(this,y);break}}try{u=ko.call(this,w)}catch(m){return Promise.reject(m)}for(d=0,h=c.length;d<h;)u=u.then(c[d++],c[d++]);return u}getUri(t){t=bt(this.defaults,t);const n=ga(t.baseURL,t.url,t.allowAbsoluteUrls);return da(n,t.params,t.paramsSerializer)}};E.forEach(["delete","get","head","options"],function(t){St.prototype[t]=function(n,r){return this.request(bt(r||{},{method:t,url:n,data:(r||{}).data}))}});E.forEach(["post","put","patch"],function(t){function n(r){return function(a,s,i){return this.request(bt(i||{},{method:t,headers:r?{"Content-Type":"multipart/form-data"}:{},url:a,data:s}))}}St.prototype[t]=n(),St.prototype[t+"Form"]=n(!0)});let Lc=class Ca{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(a){n=a});const r=this;this.promise.then(o=>{if(!r._listeners)return;let a=r._listeners.length;for(;a-- >0;)r._listeners[a](o);r._listeners=null}),this.promise.then=o=>{let a;const s=new Promise(i=>{r.subscribe(i),a=i}).then(o);return s.cancel=function(){r.unsubscribe(a)},s},t(function(a,s,i){r.reason||(r.reason=new Ot(a,s,i),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const n=this._listeners.indexOf(t);n!==-1&&this._listeners.splice(n,1)}toAbortSignal(){const t=new AbortController,n=r=>{t.abort(r)};return this.subscribe(n),t.signal.unsubscribe=()=>this.unsubscribe(n),t.signal}static source(){let t;return{token:new Ca(function(o){t=o}),cancel:t}}};function Rc(e){return function(n){return e.apply(null,n)}}function kc(e){return E.isObject(e)&&e.isAxiosError===!0}const yr={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(yr).forEach(([e,t])=>{yr[t]=e});function Ea(e){const t=new St(e),n=ea(St.prototype.request,t);return E.extend(n,St.prototype,t,{allOwnKeys:!0}),E.extend(n,t,null,{allOwnKeys:!0}),n.create=function(o){return Ea(bt(e,o))},n}const ue=Ea(nn);ue.Axios=St;ue.CanceledError=Ot;ue.CancelToken=Lc;ue.isCancel=pa;ue.VERSION=ba;ue.toFormData=Vn;ue.AxiosError=$;ue.Cancel=ue.CanceledError;ue.all=function(t){return Promise.all(t)};ue.spread=Rc;ue.isAxiosError=kc;ue.mergeConfig=bt;ue.AxiosHeaders=Oe;ue.formToJSON=e=>ha(E.isHTMLForm(e)?new FormData(e):e);ue.getAdapter=Sa.getAdapter;ue.HttpStatusCode=yr;ue.default=ue;const{Axios:sf,AxiosError:Nc,CanceledError:lf,isCancel:cf,CancelToken:uf,VERSION:df,all:ff,Cancel:hf,isAxiosError:pf,spread:mf,toFormData:gf,AxiosHeaders:vf,HttpStatusCode:yf,formToJSON:wf,getAdapter:Sf,mergeConfig:bf}=ue,gn="https://localhost:5043",et=async e=>{var h,w;const{url:t,withToken:n,method:r,body:o,contentType:a,typeToken:s="seller"}=e,i=n?localStorage.getItem("sellerAccessToken"):null,l=n?localStorage.getItem("token"):null,c=s==="seller"?i:l,u=localStorage.getItem("dv"),d={};a&&!(o instanceof FormData)?d["Content-Type"]=a:o instanceof FormData||(d["Content-Type"]="application/json"),n&&c&&(d.Authorization=`Bearer ${c}`);try{let m=null;switch(r){case"get":m=await ue.get(u?gn:t,{headers:d});break;case"post":m=await ue.post(u?gn:t,o,{headers:d});break;case"put":m=await ue.put(u?gn:t,o,{headers:d});break;case"delete":m=await ue.delete(u?gn:t,{headers:d});break}return{data:m==null?void 0:m.data,status:m==null?void 0:m.status,headers:m==null?void 0:m.headers}}catch(m){const p=m,y=(h=p.response)==null?void 0:h.data;let L="Something Went Wrong";y&&(L=y.errors[0]);const b=(w=p.response)==null?void 0:w.status;if(b===401)try{const P=await Promise.resolve().then(()=>require("./charge-BOfQrkLv.cjs")).then(T=>T.auth);P&&P.logoutCustomer?await P.logoutCustomer():localStorage.removeItem("token"),window.location.reload()}catch(P){console.error("Failed to import logoutCustomer:",P),localStorage.removeItem("token"),window.location.reload()}const R=new Nc(L,(b==null?void 0:b.toString())||"400");throw R.response=p.response,R}},Tc="https://g-api.billgang.com",Pc="https://www.googleapis.com/webfonts/v1/webfonts",_c="https://stores-api.billgang.com",Oc="https://sl-api.billgang.com",Mc="https://customers-api.billgang.com",Ac="https://cashapp-api.billgang.com",Dc={api:Tc,googleFonts:Pc,storeApi:_c,slApi:Oc,customersApi:Mc,cashappApi:Ac},Ic=(e,t="300")=>e==="not found"?"empty":`https://imagedelivery.net/${e}/w=${t}`,Fc=e=>{const t=new Intl.NumberFormat("en-US",{style:"currency",currency:e.currency||"USD"});let n=e.amount;return e.quantity&&(n=n*e.quantity),t.format(n)},Bc=(e,t)=>{if(e===0)throw new Error("Old value cannot be zero, as it would result in division by zero.");return(t-e)/Math.abs(e)*100},jc=e=>{if(Math.abs(e-365)<=15){const a=Math.round(e/365);return a===1?"year":`${a} years`}else if(Math.abs(e-30)<=5){const a=Math.round(e/30);return a===1?"month":`${a} months`}else return`${e} days`},Hc=e=>new Date(e).toLocaleDateString("en-US",{year:"numeric",month:"short",day:"numeric"}),Uc=e=>{const t=new Date(e),n={day:"2-digit",month:"2-digit",year:"numeric"},r={hour:"2-digit",minute:"2-digit"},o=t.toLocaleString("en-US",n),a=t.toLocaleString("en-US",r);return[o,a]},wr=e=>{const t=window.localStorage.getItem(e);if(t===null)return null;try{return JSON.parse(t)}catch{return t}},To=(e,t)=>{(t===null||typeof t!="object")&&window.localStorage.setItem(e,String(t));const n=JSON.stringify(t);window.localStorage.setItem(e,n)},or="f10120ab-7ebb-4785-b240-7428edaa3c4e",Vt="https://t-api.billgang.com",$t="https://internal-t-api.antistock.io",qt="I",Vc=10*1e3,$c=15*1e3,zc=15*60*1e3,xa=()=>{var t;const e=wr(qt);return((t=e==null?void 0:e.s)==null?void 0:t.i)||null},Jc=(e,t="production",n)=>{const{pathname:r}=qe(),o=we.useRef(),a=we.useRef(document.visibilityState);we.useEffect(()=>{if(!e)return;const s=()=>Date.now(),i=async()=>(await et({url:`${n?$t:Vt}/${e}/t/p`,method:"post",withToken:!1})).data.data.id,l=async m=>(await et({url:`${n?$t:Vt}/${e}/t/p/${t==="development"?or:m}/s`,method:"post",withToken:!1})).data.data.id,c=async(m,p,y,L)=>{const b=t==="development"?or:m;try{return(await et({url:`${n?$t:Vt}/${e}/t/p/${b}/s/${p}/e`,method:"post",withToken:!1,body:{url:y,oldEventId:L},contentType:"application/json"})).data.data.id}catch{return p=await l(m),(await et({url:`${n?$t:Vt}/${e}/t/p/${b}/s/${p}/e`,method:"post",withToken:!1,body:{url:y},contentType:"application/json"})).data.data.id}},u=async(m,p,y)=>{await et({url:`${n?$t:Vt}/${e}/t/p/${t==="development"?or:m}/s/${p}/e/${y}/h`,method:"post",withToken:!1});const b=wr(qt);b&&(b.s.u=s().toString(),b.lu=s().toString(),To(qt,b))},d=(m,p,y)=>{o.current&&clearInterval(o.current),o.current=setInterval(async()=>{if(document.visibilityState==="visible")try{await u(m,p,y)}catch{await h()}},Vc)},h=async()=>{var L,b,R,P;const m=`${window.location.hostname}${r}`,p=wr(qt),y=s();try{let T=p==null?void 0:p.p;T||(T=await i());let H=(L=p==null?void 0:p.s)==null?void 0:L.i;const S=Number(((b=p==null?void 0:p.s)==null?void 0:b.u)||((R=p==null?void 0:p.s)==null?void 0:R.c)),_=!H||y-S>zc;(!H||_)&&(H=await l(T));const G=Number((p==null?void 0:p.lu)||0),B=y-G>$c,ae=await c(T,H,m,p!=null&&p.l&&!B?p.l:void 0),se={p:T,s:{i:H,c:((P=p==null?void 0:p.s)==null?void 0:P.c)??y.toString(),u:y.toString()},l:ae,lu:y.toString()};To(qt,se),d(T,H,ae)}catch(T){console.error("[TrackingAnalytics] error",T)}};h();const w=()=>{document.visibilityState==="visible"&&a.current!=="visible"&&h(),a.current=document.visibilityState};return document.addEventListener("visibilitychange",w),()=>{o.current&&clearInterval(o.current),document.removeEventListener("visibilitychange",w)}},[r,e,t])},Wc={customerEmail:"",recaptcha:"",gateway:"",paymentMethod:"",parts:[],customFields:{},discordSocialConnectId:null,coupon:null,tsId:xa()};let Nt=null;const Po=localStorage.getItem("token");if(Po)try{Nt=Qo(JSON.parse(Po)||"")}catch{Nt=null}const qc=ie(e=>({cart:{...Wc,customerEmail:Nt?Nt.email:""},products:[],coupon:null,pending:!1,applyCouponPending:!1,customerEmail:Nt?Nt.email:"",recaptcha:"",priceAdjustment:null,serviceFee:null,replacementConfig:null,setCart:t=>e(n=>({cart:typeof t=="function"?t(n.cart):t})),setProducts:t=>e(n=>({products:typeof t=="function"?t(n.products):t})),setRecaptcha:t=>e({recaptcha:t}),setCoupon:t=>e({coupon:t}),setPending:t=>e({pending:t}),setApplyCouponPending:t=>e({applyCouponPending:t}),setCustomerEmail:t=>e({customerEmail:t}),setPriceAdjustment:t=>e({priceAdjustment:t}),setServiceFee:t=>e({serviceFee:t}),setReplacementConfig:t=>e({replacementConfig:t}),setUsePriorityReplacement:t=>e(n=>({cart:{...n.cart,usePriorityReplacement:t}}))})),Zc=ie(e=>({page:1,setPage:t=>e(()=>({page:t})),resetPage:()=>e(()=>({page:1}))})),Gc=ie(e=>({discordInfo:null,setDiscordInfo:t=>e(()=>({discordInfo:t}))})),Kc=ie(e=>({subscription:null,setSubscription:t=>e({subscription:t})})),Mt=ie(e=>({apiUrls:Dc,setApiUrls:t=>e(()=>({apiUrls:t}))})),La=ie(e=>({header:null,footer:null,announcement:null,setHeader:t=>e(()=>({header:t})),setFooter:t=>e(()=>({footer:t})),setAnnouncement:t=>e(()=>({announcement:t})),blocks:null,setBlocks:t=>e(()=>({blocks:t})),activeBlock:null,setActiveBlock:t=>e(()=>({activeBlock:t})),sourceBlocks:{},setSourceBlocks:t=>e(()=>({sourceBlocks:t})),currentInstance:null,setCurrentInstance:t=>e(()=>({currentInstance:t})),settings:null,setSettings:t=>e(()=>({settings:t})),settingsInstance:null,setSettingsInstance:t=>e(()=>({settingsInstance:t}))})),Jn=ie(e=>({general:null,setGeneral:t=>e(()=>({general:t})),isAntistock:!1,setIsAntistock:t=>e(()=>({isAntistock:t}))})),Sr=ie(e=>({settings:null,setSettings:t=>{e(()=>({settings:t}))},isLoadingSettings:!0,setIsLoadingSettings:t=>e(()=>({isLoadingSettings:t}))})),On=ie((e,t)=>({activeBlock:null,setActiveBlock:n=>e(()=>({activeBlock:n})),activeFont:null,setActiveFont:n=>e(()=>({activeFont:n})),setThemeSettings:n=>e(()=>({themeSettings:n})),activeColorCategory:null,setActiveColorCategory:n=>e(()=>({activeColorCategory:n})),themeSettings:{colors:{text:{primary:"#252525",secondary:"#757575",tertiary:"#C2C2C2",inverted:"#FFFFFF",action:"#FF3F19",actionHover:"#DA2400",disabled:"#C2C2C2",warning:"#C1972A",error:"#C12A2A",success:"#338B13",information:"#3683F7",link:"#3683F7"},icon:{primary:"#252525",secondary:"#555555",tertiary:"#C2C2C2",inverted:"#FFFFFF",action:"#FF3F19",actionHover:"#DA2400",disabled:"#C2C2C2",warning:"#C1972A",error:"#C12A2A",success:"#338B13",information:"#3683F7",link:"#3683F7"},border:{primary:"#C2C2C2",secondary:"#E6E6E6",action:"#FF3F19",actionHover:"#DA2400",disabled:"#E6E6E6",warning:"#C1972A",error:"#C12A2A",success:"#338B13",information:"#3683F7",focus:"#FF3F19"},surface:{primary:"#FFFFFF",secondary:"#F8F8F8",action1:"#FF3F19",action1Hover:"#DA2400",action2:"#FFFFFF",action2Hover:"#F8F8F8",disabled:"#C2C2C2",warning:"#FAF4E6",error:"#FAE6E6",success:"#E5FADD",information:"#E9F1FE",modal:"rgba(1, 1, 4, 0.4)"}},fonts:{mobile:{fontSizePercentage:30},tablet:{fontSizePercentage:50},desktop:{heading:{h1:{font:"Archivo",weight:"700",size:48,boldWeight:"900",case:"normal"},h2:{font:"Archivo",weight:"700",size:32,boldWeight:"800",case:"normal"},h3:{font:"Archivo",weight:"600",size:24,boldWeight:"700",case:"normal"},h4:{font:"Archivo",weight:"500",size:20,boldWeight:"700",case:"normal"},h5:{font:"Archivo",weight:"400",size:16,boldWeight:"700",case:"normal"},h6:{font:"Archivo",weight:"400",size:14,boldWeight:"700",case:"uppercase"},h7:{font:"Archivo",weight:"400",size:14,boldWeight:"700",case:"normal"}},body:{lg:{font:"Archivo",size:16,weight:"400",boldWeight:"700",case:"normal"},md:{font:"Archivo",size:14,weight:"400",boldWeight:"700",case:"normal"},sm:{font:"Archivo",size:12,weight:"400",boldWeight:"700",case:"normal"}}}},borders:{radius:"var(--radius-lg)",thickness:"var(--border-none)"},buttons:{primary:{size:26,alignment:"left",radius:32,height:40,background:"#ff3f19",hover:!0,font:"Archivo",boxShadow:{left:0,top:0,blur:0,spread:0,color:"#000000"},color:"#ffffff",colorHover:"#ffffff",backgroundHover:"#ff3f19"},secondary:{size:26,alignment:"left",radius:10,height:20,background:"#c2c2c2",hover:!1,font:"Archivo",boxShadow:{left:0,top:4,blur:10,spread:0,color:"#000000"},color:"#757575",colorHover:"#757575",backgroundHover:"#c2c2c2"},tertiary:{size:12,alignment:"left",radius:30,height:30,background:"#c2c2c2",hover:!0,font:"Archivo",boxShadow:{left:0,top:4,blur:10,spread:0,color:"#000000"},color:"#757575",colorHover:"#757575",backgroundHover:"#c2c2c2"}},inputs:{field:{color:"#f3f3f3",active:!0,opacity:40},label:{size:14,color:"#555555",height:40,alignment:"left"},border:{color:"#f3f3f3",style:"solid",active:!0,radius:14,thickness:0},general:{size:14,color:"#252525",height:40},placeholder:{color:"#C2C2C2"}}},updateColor:(n,r,o)=>e(a=>{const s=JSON.parse(JSON.stringify(t().themeSettings));Pe.getState().addHistory({themeSettings:s});const i={...a.themeSettings.colors,[n]:{...a.themeSettings.colors[n],[r]:o}};return{themeSettings:{...a.themeSettings,colors:i}}}),updateFont:(n,r,o,a,s)=>e(i=>{const l=JSON.parse(JSON.stringify(t().themeSettings));Pe.getState().addHistory({themeSettings:l});const c={...i.themeSettings.fonts,[n]:{...i.themeSettings.fonts[n],[r]:{...i.themeSettings.fonts[n][r],[o]:{...i.themeSettings.fonts[n][r][o],[a]:s}}}};return{themeSettings:{...i.themeSettings,fonts:c}}}),updateFontSizePercentage:(n,r)=>e(o=>{const a=JSON.parse(JSON.stringify(t().themeSettings));Pe.getState().addHistory({themeSettings:a});const s={...o.themeSettings.fonts,[n]:{...o.themeSettings.fonts[n],fontSizePercentage:r}};return{themeSettings:{...o.themeSettings,fonts:s}}}),updateBorder:(n,r)=>e(o=>{const a=JSON.parse(JSON.stringify(t().themeSettings));Pe.getState().addHistory({themeSettings:a});const s={...o.themeSettings.borders,[n]:r};return{themeSettings:{...o.themeSettings,borders:s}}}),updateButton:(n,r,o)=>e(a=>{const s=JSON.parse(JSON.stringify(t().themeSettings));Pe.getState().addHistory({themeSettings:s});const i={...a.themeSettings.buttons[n],[r]:o},l={...a.themeSettings.buttons,[n]:i};return{themeSettings:{...a.themeSettings,buttons:l}}}),updateInput:(n,r,o)=>e(a=>{const s=JSON.parse(JSON.stringify(t().themeSettings));return Pe.getState().addHistory({themeSettings:s}),{themeSettings:{...a.themeSettings,inputs:{...a.themeSettings.inputs,[n]:{...a.themeSettings.inputs[n],[o]:r}}}}}),isLoadingThemeSettings:!1,setIsLoadingThemeSettings:n=>e(()=>({isLoadingThemeSettings:n}))})),De=ie(e=>({notifications:[],setNotifications:t=>e(()=>({notifications:t}))})),Yc=ie(e=>({isOpen:!0,setIsOpen:t=>e(()=>({isOpen:t}))}));var ke=[];for(var ar=0;ar<256;++ar)ke.push((ar+256).toString(16).slice(1));function Xc(e,t=0){return(ke[e[t+0]]+ke[e[t+1]]+ke[e[t+2]]+ke[e[t+3]]+"-"+ke[e[t+4]]+ke[e[t+5]]+"-"+ke[e[t+6]]+ke[e[t+7]]+"-"+ke[e[t+8]]+ke[e[t+9]]+"-"+ke[e[t+10]]+ke[e[t+11]]+ke[e[t+12]]+ke[e[t+13]]+ke[e[t+14]]+ke[e[t+15]]).toLowerCase()}var vn,Qc=new Uint8Array(16);function eu(){if(!vn&&(vn=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!vn))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return vn(Qc)}var tu=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto);const _o={randomUUID:tu};function st(e,t,n){if(_o.randomUUID&&!e)return _o.randomUUID();e=e||{};var r=e.random||(e.rng||eu)();return r[6]=r[6]&15|64,r[8]=r[8]&63|128,Xc(r)}function nu(e,t){let n;try{n=e()}catch{return}return{getItem:o=>{var a;const s=l=>l===null?null:JSON.parse(l,void 0),i=(a=n.getItem(o))!=null?a:null;return i instanceof Promise?i.then(s):s(i)},setItem:(o,a)=>n.setItem(o,JSON.stringify(a,void 0)),removeItem:o=>n.removeItem(o)}}const br=e=>t=>{try{const n=e(t);return n instanceof Promise?n:{then(r){return br(r)(n)},catch(r){return this}}}catch(n){return{then(r){return this},catch(r){return br(r)(n)}}}},ru=(e,t)=>(n,r,o)=>{let a={storage:nu(()=>localStorage),partialize:p=>p,version:0,merge:(p,y)=>({...y,...p}),...t},s=!1;const i=new Set,l=new Set;let c=a.storage;if(!c)return e((...p)=>{console.warn(`[zustand persist middleware] Unable to update item '${a.name}', the given storage is currently unavailable.`),n(...p)},r,o);const u=()=>{const p=a.partialize({...r()});return c.setItem(a.name,{state:p,version:a.version})},d=o.setState;o.setState=(p,y)=>{d(p,y),u()};const h=e((...p)=>{n(...p),u()},r,o);o.getInitialState=()=>h;let w;const m=()=>{var p,y;if(!c)return;s=!1,i.forEach(b=>{var R;return b((R=r())!=null?R:h)});const L=((y=a.onRehydrateStorage)==null?void 0:y.call(a,(p=r())!=null?p:h))||void 0;return br(c.getItem.bind(c))(a.name).then(b=>{if(b)if(typeof b.version=="number"&&b.version!==a.version){if(a.migrate)return[!0,a.migrate(b.state,b.version)];console.error("State loaded from storage couldn't be migrated since no migrate function was provided")}else return[!1,b.state];return[!1,void 0]}).then(b=>{var R;const[P,T]=b;if(w=a.merge(T,(R=r())!=null?R:h),n(w,!0),P)return u()}).then(()=>{L==null||L(w,void 0),w=r(),s=!0,l.forEach(b=>b(w))}).catch(b=>{L==null||L(void 0,b)})};return o.persist={setOptions:p=>{a={...a,...p},p.storage&&(c=p.storage)},clearStorage:()=>{c==null||c.removeItem(a.name)},getOptions:()=>a,rehydrate:()=>m(),hasHydrated:()=>s,onHydrate:p=>(i.add(p),()=>{i.delete(p)}),onFinishHydration:p=>(l.add(p),()=>{l.delete(p)})},a.skipHydration||m(),w||h},Wn=ru,Xt=ie(Wn((e,t)=>({pages:null,currentPage:"",setPages:n=>e(()=>({pages:n})),pageContext:{listings:null,products:null,reviews:null,categories:null,faqs:null,general:null,fullPosts:null,posts:null,preserveContent:!1,vouches:null},isOpenModal:!1,isOpenSelectModal:!1,isEdit:!1,editedPage:null,setEditedPage:n=>e(()=>({editedPage:n})),setCurrentPage:n=>e(()=>({currentPage:n})),setPageContext:n=>e(()=>({pageContext:n})),setIsOpenModal:n=>e(()=>({isOpenModal:n})),setIsOpenSelectModal:n=>e(()=>({isOpenSelectModal:n})),setIsEdit:n=>e(()=>({isEdit:n})),createPage:n=>{const r=t().pages,o=st();if(r)r[o]=n,e({pages:r});else{const a=t().setPages;a({});const s=t().pages;s[o]=n,e({pages:s})}},updatePage:(n,r)=>{const o=t().pages;o&&(o[n]={...r},e({pages:o}))},deletePage:n=>{const r=t().pages;r&&(delete r[n],e({pages:r}))}}),{name:"pages-storage",partialize:e=>{const{pages:t,pageContext:n}=e;return{pages:t,pageContext:n}}})),ou=ie(e=>({isOpenModal:!1,setIsOpenModal:t=>e(()=>({isOpenModal:t}))})),Mn=ie(Wn((e,t)=>({header:null,blocks:{},announcement:null,footer:null,currentBlock:null,positionBlock:null,setBlocks:n=>{e({blocks:n})},setHeader:(n,r=!0)=>{const o=JSON.parse(JSON.stringify(t().header)),a=JSON.parse(JSON.stringify(n));JSON.stringify(o)!==JSON.stringify(a)&&r&&Pe.getState().addHistory({header:o}),e({header:a})},setFooter:(n,r=!0)=>{const o=JSON.parse(JSON.stringify(t().footer)),a=JSON.parse(JSON.stringify(n));JSON.stringify(o)!==JSON.stringify(a)&&r&&Pe.getState().addHistory({footer:o}),e({footer:a})},setAnnouncement:(n,r=!0)=>{const o=JSON.parse(JSON.stringify(t().announcement)),a=JSON.parse(JSON.stringify(n));JSON.stringify(o)!==JSON.stringify(a)&&r&&Pe.getState().addHistory({announcement:o}),e({announcement:a})},createPage:n=>{const r=t().blocks;r[n]={data:{},order:[]},e({blocks:r})},deletePage:n=>{const r=t().blocks;delete r[n],e({blocks:r})},updatePage:(n,r)=>{const o=t().blocks;if(o[r])return;const a=o[n];delete o[n],o[r]=a,e({blocks:o})},setCurrentBlock:n=>{e({currentBlock:n})},setPositionBlock:(n,r=!1)=>{const{blocks:o}=t(),{currentPage:a,pages:s}=Xt.getState();if(!a||!s||!s[a]||!o[s[a].path]){console.error("Cannot set position: invalid page or block data");return}const i=s[a].path,l=o[i],c=n?l.order.indexOf(n):-1;if(c===-1&&n){console.error(`Block with ID "${n}" not found in page "${i}"`);return}const u=c!==-1?c+(r?1:0):l.order.length;e({positionBlock:u})},addBlock:(n,r)=>{const o=JSON.parse(JSON.stringify(t().blocks));Pe.getState().addHistory({layers:o});const a={...t().blocks},s=a[n]||{data:{},order:[]},i=t().positionBlock,l=st(),c={name:r.name,value:r.value};return s.data[l]=c,i===null||i>=s.order.length?s.order.push(l):s.order.splice(i,0,l),e({blocks:{...a,[n]:{data:s.data,order:s.order}},currentBlock:l,positionBlock:null}),De.getState().setNotifications([...De.getState().notifications,{id:st(),message:"Block successfully added",status:"success"}]),l},editBlock:(n,r,o)=>{const a=JSON.parse(JSON.stringify(t().blocks));Pe.getState().addHistory({layers:a});const s=t().blocks,i=s[n]||{};i.data[r]={name:o.name,value:{...o.value}},e({blocks:{...s,[n]:i}})},removeBlock:(n,r)=>{const o=JSON.parse(JSON.stringify(t().blocks));Pe.getState().addHistory({layers:o});const a=JSON.parse(JSON.stringify(t().blocks)),s=a[n];if(!s){console.error(`Page at path "${n}" does not exist.`);return}delete s.data[r],s.order=s.order.filter(i=>i!==r),e({blocks:{...a,[n]:s}}),De.getState().setNotifications([...De.getState().notifications,{id:st(),message:"Block successfully deleted",status:"success"}])},moveBlock:(n,r,o)=>e(a=>{const s=JSON.parse(JSON.stringify(t().blocks));if(Pe.getState().addHistory({layers:s}),!a.blocks[n])return console.error(`Path ${n} does not exist in blocks`),a;const i={...a.blocks[n]},l=[...i.order];if(r<0||o<0||r>=l.length||o>=l.length)return console.error(`Invalid indices: fromIndex=${r}, toIndex=${o}`),a;const[c]=l.splice(r,1);return l.splice(o,0,c),De.getState().setNotifications([...De.getState().notifications,{id:st(),message:"Block successfully moved",status:"success"}]),{blocks:{...a.blocks,[n]:{...i,order:l}}}}),duplicateBlock:(n,r)=>{const o=JSON.parse(JSON.stringify(t().blocks));Pe.getState().addHistory({layers:o});const a=JSON.parse(JSON.stringify(t().blocks)),s=a[n];if(!s||!s.data[r]){console.error(`Block with ID "${r}" not found in page "${n}"`);return}const i=st(),l=s.data[r],c={name:l.name,value:JSON.parse(JSON.stringify({...l.value}))};s.data[i]={...c};const u=s.order.indexOf(r);if(u===-1){console.error(`Block ID "${r}" not found in order array`);return}s.order.splice(u+1,0,i),e({blocks:{...a,[n]:s},currentBlock:i}),Ra.getState().setActiveBlock({id:i,neededScroll:!0}),De.getState().setNotifications([...De.getState().notifications,{id:st(),message:"Block successfully duplicated",status:"success"}])},isLoadingLayers:!1,setIsLoadingLayers:n=>e(()=>({isLoadingLayers:n}))}),{name:"layers-storage",partialize:e=>{const{blocks:t,header:n,footer:r,announcement:o}=e;return{blocks:t,header:n,footer:r,announcement:o}}})),Pe=ie((e,t)=>({past:[],future:[],addHistory:n=>{e(r=>{const o=r.past[r.past.length-1];return o&&JSON.stringify(o)===JSON.stringify(n)?r:{past:[...r.past,n],future:[]}})},undo:()=>{const{past:n,future:r}=t();if(n.length===0)return;const o=n[n.length-1],a=n.slice(0,-1),{blocks:s,header:i,footer:l,announcement:c,setBlocks:u,setHeader:d,setFooter:h,setAnnouncement:w}=Mn.getState(),{themeSettings:m,setThemeSettings:p}=On.getState(),y={themeSettings:JSON.parse(JSON.stringify(m)),layers:JSON.parse(JSON.stringify(s)),header:JSON.parse(JSON.stringify(i)),footer:JSON.parse(JSON.stringify(l)),announcement:JSON.parse(JSON.stringify(c))};e({past:a,future:[y,...r]}),o.themeSettings&&p(o.themeSettings),o.layers&&u(o.layers),o.header&&d(o.header,!1),o.footer&&h(o.footer,!1),o.announcement&&w(o.announcement,!1)},redo:()=>{const{past:n,future:r}=t();if(r.length===0)return;const{blocks:o,header:a,footer:s,announcement:i,setBlocks:l,setHeader:c,setFooter:u,setAnnouncement:d}=Mn.getState(),{themeSettings:h,setThemeSettings:w}=On.getState(),m=r[0],p=r.slice(1),y={themeSettings:JSON.parse(JSON.stringify(h)),layers:JSON.parse(JSON.stringify(o)),header:JSON.parse(JSON.stringify(a)),footer:JSON.parse(JSON.stringify(s)),announcement:JSON.parse(JSON.stringify(i))};e({past:[...n,y],future:p}),m.themeSettings&&w(m.themeSettings),m.layers&&l(m.layers),m.header&&c(m.header,!1),m.footer&&u(m.footer,!1),m.announcement&&d(m.announcement,!1)}})),Ra=ie(Wn(e=>({onPreview:!0,setOnPreview:t=>e(()=>({onPreview:t})),activeBlock:{id:null,neededScroll:!1},setActiveBlock:t=>e(()=>({activeBlock:t})),zoomLevel:1,setZoomLevel:t=>e(()=>({zoomLevel:t}))}),{name:"preview-storage",partialize:e=>{const{onPreview:t}=e;return{onPreview:t}}})),ka=[{icon:"TreeStructure",name:"Layers"},{icon:"Plus",name:"Add"},{icon:"Palette",name:"Theme"},{icon:"Gear",name:"Settings"}],au=[{icon:"Desktop",value:"desktop"},{icon:"DeviceTabletCamera",value:"tablet"},{icon:"DeviceMobileCamera",value:"mobile"}],su=[{icon:"PaintBrushBroad",name:"Colors"},{icon:"TextAa",name:"Fonts"},{icon:"CornersOut",name:"Borders"},{icon:"ArrowSquareIn",name:"Buttons"},{icon:"Textbox",name:"Inputs"}],iu=[6,8,10,12,14,16,18,20,24,28,32,40,48,52,56,60,64].map(e=>String(e)),lu=["/","/reviews","/faqs","/contact","/products","/ticket","/login"],zt={"/":{path:"/",name:"Home",icon:"HouseSimple",seo:{pageDescription:"",pageTitle:""},visibility:"public"},"/products":{path:"/products",name:"Products",icon:"SquaresFour",seo:{pageDescription:"",pageTitle:""},visibility:"public"},"/faqs":{path:"/faqs",name:"Faqs",icon:"SealQuestion",seo:{pageDescription:"",pageTitle:""},visibility:"public"},"/reviews":{path:"/reviews",name:"Reviews",icon:"Star",seo:{pageDescription:"",pageTitle:""},visibility:"public"},"/contact":{path:"/contact",name:"Contact",icon:"ChatCentered",seo:{pageDescription:"",pageTitle:""},visibility:"public"},"/ticket":{path:"/ticket",name:"Ticket",icon:"Ticket",seo:{pageDescription:"",pageTitle:""},visibility:"public"},"/login":{path:"/login",name:"Login",icon:"UserCircleGear",seo:{pageDescription:"",pageTitle:""},visibility:"public"}},cu=typeof window<"u"&&(window.location.hostname.includes("localhost")||window.location.hostname.includes("192")||window.location.hostname.includes("local-rst.sp-internal.work")),uu={None:"var(--radius-none)",4:"var(--radius-xs)",8:"var(--radius-sm)",12:"var(--radius-md)",16:"var(--radius-lg)",20:"var(--radius-xl)",24:"var(--radius-2xl)"},du={None:"var(--border-none)",1:"var(--border-sm)",2:"var(--border-md)",4:"var(--border-lg)"},fu={"1:1":"1:1","4:3":"4:3","16:9":"16:9","9:16":"9:16"},hu=[{value:"4:3",addon:k.jsx("div",{style:{width:24,height:24,display:"flex",alignItems:"center",justifyContent:"center"},children:k.jsx("div",{style:{width:18.5,height:14.5,border:"1.5px solid #252525",borderRadius:3}})})},{value:"16:9",addon:k.jsx("div",{style:{width:24,height:24,display:"flex",alignItems:"center",justifyContent:"center"},children:k.jsx("div",{style:{width:20.5,height:12.5,border:"1.5px solid #252525",borderRadius:3}})})},{value:"9:16",addon:k.jsx("div",{style:{width:24,height:24,display:"flex",alignItems:"center",justifyContent:"center"},children:k.jsx("div",{style:{width:14.5,height:18.5,border:"1.5px solid #252525",borderRadius:3}})})},{value:"1:1",addon:k.jsx("div",{style:{width:24,height:24,display:"flex",alignItems:"center",justifyContent:"center"},children:k.jsx("div",{style:{width:16.5,height:16.5,border:"1.5px solid #252525",borderRadius:3}})})}],pu={h1:"Heading 1",h2:"Heading 2",h3:"Heading 3",h4:"Heading 4",h5:"Heading 5",h6:"Heading 6",h7:"Heading 7",lg:"Paragraph Large",md:"Paragraph Medium",sm:"Paragraph Small"},mu=ie(e=>({activeBlock:ka[0],setActiveBlock:t=>e(()=>({activeBlock:t}))})),Na=ie(e=>({openModal:!1,setOpenModal:t=>e(()=>({openModal:t})),onChange:null,setOnChange:t=>e(()=>({onChange:t})),tip:"",setTip:t=>e(()=>({tip:t}))})),gu=ie(e=>({error:null,setError:t=>e(()=>({error:t}))})),Ta=ie(e=>({title:null,description:null,onConfirm:null,setTitle:t=>e(()=>({title:t})),setDescription:t=>e(()=>({description:t})),setOnConfirm:t=>e(()=>({onConfirm:t}))}));var vu=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Pa(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var _a={exports:{}};/*!
37
37
  Copyright (c) 2018 Jed Watson.
38
38
  Licensed under the MIT License (MIT), see
39
39
  http://jedwatson.github.io/classnames
@@ -1,10 +1,10 @@
1
1
  import { jsxs as w, jsx as c, Fragment as Pe } from "react/jsx-runtime";
2
2
  import A, { useLayoutEffect as Mr, useEffect as U, useRef as V, useMemo as H, useCallback as te, useState as he, memo as Rr, useReducer as Or, createContext as Pt, useContext as nt } from "react";
3
- import { u as ne, a as Je, b as J, c as se, d as Po, e as Un, f as E, v as en, T as vt, g as $r, h as Vn, i as Fe, j as Lo, r as Fo, k as un, l as Et, m as X, n as zo, L as ot, o as Kn, p as rt, q as Pr, s as Gn, t as tt, w as dn, x as Yn, y as jo, A as Lr, S as Fr, C as zr, z as Ho, B as ft, D as jr, E as Ee, F as Lt, R as bn, G as _n, H as Wo, I as tn, J as we, P as go, K as Hr } from "./builder-2YNszRul.js";
4
- import { I as R, u as Wr, B as qe, E as nn, c as ue, S as Ce, d as In, T as Ur } from "./ui-components-t7AROe_i.js";
5
- import "./charge-CeL8jXzk.js";
3
+ import { u as ne, a as Je, b as J, c as se, d as Po, e as Un, f as E, v as en, T as vt, g as $r, h as Vn, i as Fe, j as Lo, r as Fo, k as un, l as Et, m as X, n as zo, L as ot, o as Kn, p as rt, q as Pr, s as Gn, t as tt, w as dn, x as Yn, y as jo, A as Lr, S as Fr, C as zr, z as Ho, B as ft, D as jr, E as Ee, F as Lt, R as bn, G as _n, H as Wo, I as tn, J as we, P as go, K as Hr } from "./builder-CQv65ONw.js";
4
+ import { I as R, u as Wr, B as qe, E as nn, c as ue, S as Ce, d as In, T as Ur } from "./ui-components-Bc8Z_6jF.js";
5
+ import "./charge-BIOFTYrp.js";
6
6
  import { unstable_batchedUpdates as Vt, createPortal as Vr } from "react-dom";
7
- import "./ticket-HPAqmPkQ.js";
7
+ import "./ticket-UPvqJdN6.js";
8
8
  const Xn = ({ render: e, block: t }) => e(t), Uo = ({ settings: e, pageContext: t }) => {
9
9
  const { footer: n } = ne(), { settings: o } = Je(), { pageContext: r } = J(), { footer: s } = se();
10
10
  if (!s || !n) return null;
@@ -1,4 +1,4 @@
1
- "use strict";const i=require("react/jsx-runtime"),f=require("react"),l=require("./builder-DT2MPQIe.cjs"),j=require("./ui-components-CoVj1ReR.cjs");require("./charge-Dd6podcM.cjs");const at=require("react-dom");require("./ticket-C_4dunoG.cjs");const Tt=({render:e,block:t})=>e(t),dn=({settings:e,pageContext:t})=>{const{footer:n}=l.useLayersStore(),{settings:s}=l.useSettingsStore(),{pageContext:o}=l.usePagesStore(),{footer:r}=l.useBlocksStore();if(!r||!n)return null;const a=new r;return Object.keys(n).map(c=>{a[c]=n[c]}),a.renderBlock((e==null?void 0:e.blockSettings)||s,t||o)},hn=({settings:e,pageContext:t})=>{const{header:n}=l.useLayersStore(),{settings:s}=l.useSettingsStore(),{pageContext:o}=l.usePagesStore(),{header:r}=l.useBlocksStore();if(!r||!n)return null;const a=new r;return Object.keys(n).map(c=>{a[c]=n[c]}),a.renderBlock((e==null?void 0:e.blockSettings)||s,t||o)},fn=({settings:e,pageContext:t})=>{const{announcement:n}=l.useLayersStore(),{settings:s}=l.useSettingsStore(),{pageContext:o}=l.usePagesStore(),{announcement:r}=l.useBlocksStore();if(!r||!n)return null;const a=new r;return Object.keys(n).map(c=>{a[c]=n[c]}),a.renderBlock(e||s,t||o)},Us=Object.freeze(Object.defineProperty({__proto__:null,RenderAnnouncement:fn,RenderBlock:Tt,RenderFooter:dn,RenderHeader:hn},Symbol.toStringTag,{value:"Module"}));function Ce(e){return Array.isArray?Array.isArray(e):es(e)==="[object Array]"}function Vs(e){if(typeof e=="string")return e;let t=e+"";return t=="0"&&1/e==-1/0?"-0":t}function Ks(e){return e==null?"":Vs(e)}function ve(e){return typeof e=="string"}function Qn(e){return typeof e=="number"}function Gs(e){return e===!0||e===!1||Ys(e)&&es(e)=="[object Boolean]"}function Zn(e){return typeof e=="object"}function Ys(e){return Zn(e)&&e!==null}function te(e){return e!=null}function zt(e){return!e.trim().length}function es(e){return e==null?e===void 0?"[object Undefined]":"[object Null]":Object.prototype.toString.call(e)}const Xs="Incorrect 'index' type",qs=e=>`Invalid value for key ${e}`,Js=e=>`Pattern length exceeds max of ${e}.`,Qs=e=>`Missing ${e} property in key`,Zs=e=>`Property 'weight' in key '${e}' must be a positive integer`,Bn=Object.prototype.hasOwnProperty;class eo{constructor(t){this._keys=[],this._keyMap={};let n=0;t.forEach(s=>{let o=ts(s);this._keys.push(o),this._keyMap[o.id]=o,n+=o.weight}),this._keys.forEach(s=>{s.weight/=n})}get(t){return this._keyMap[t]}keys(){return this._keys}toJSON(){return JSON.stringify(this._keys)}}function ts(e){let t=null,n=null,s=null,o=1,r=null;if(ve(e)||Ce(e))s=e,t=En(e),n=Qt(e);else{if(!Bn.call(e,"name"))throw new Error(Qs("name"));const a=e.name;if(s=a,Bn.call(e,"weight")&&(o=e.weight,o<=0))throw new Error(Zs(a));t=En(a),n=Qt(a),r=e.getFn}return{path:t,id:n,weight:o,src:s,getFn:r}}function En(e){return Ce(e)?e:e.split(".")}function Qt(e){return Ce(e)?e.join("."):e}function to(e,t){let n=[],s=!1;const o=(r,a,c)=>{if(te(r))if(!a[c])n.push(r);else{let u=a[c];const h=r[u];if(!te(h))return;if(c===a.length-1&&(ve(h)||Qn(h)||Gs(h)))n.push(Ks(h));else if(Ce(h)){s=!0;for(let d=0,p=h.length;d<p;d+=1)o(h[d],a,c+1)}else a.length&&o(h,a,c+1)}};return o(e,ve(t)?t.split("."):t,0),s?n:n[0]}const no={includeMatches:!1,findAllMatches:!1,minMatchCharLength:1},so={isCaseSensitive:!1,ignoreDiacritics:!1,includeScore:!1,keys:[],shouldSort:!0,sortFn:(e,t)=>e.score===t.score?e.idx<t.idx?-1:1:e.score<t.score?-1:1},oo={location:0,threshold:.6,distance:100},ro={useExtendedSearch:!1,getFn:to,ignoreLocation:!1,ignoreFieldNorm:!1,fieldNormWeight:1};var B={...so,...no,...oo,...ro};const io=/[^ ]+/g;function ao(e=1,t=3){const n=new Map,s=Math.pow(10,t);return{get(o){const r=o.match(io).length;if(n.has(r))return n.get(r);const a=1/Math.pow(r,.5*e),c=parseFloat(Math.round(a*s)/s);return n.set(r,c),c},clear(){n.clear()}}}class gn{constructor({getFn:t=B.getFn,fieldNormWeight:n=B.fieldNormWeight}={}){this.norm=ao(n,3),this.getFn=t,this.isCreated=!1,this.setIndexRecords()}setSources(t=[]){this.docs=t}setIndexRecords(t=[]){this.records=t}setKeys(t=[]){this.keys=t,this._keysMap={},t.forEach((n,s)=>{this._keysMap[n.id]=s})}create(){this.isCreated||!this.docs.length||(this.isCreated=!0,ve(this.docs[0])?this.docs.forEach((t,n)=>{this._addString(t,n)}):this.docs.forEach((t,n)=>{this._addObject(t,n)}),this.norm.clear())}add(t){const n=this.size();ve(t)?this._addString(t,n):this._addObject(t,n)}removeAt(t){this.records.splice(t,1);for(let n=t,s=this.size();n<s;n+=1)this.records[n].i-=1}getValueForItemAtKeyId(t,n){return t[this._keysMap[n]]}size(){return this.records.length}_addString(t,n){if(!te(t)||zt(t))return;let s={v:t,i:n,n:this.norm.get(t)};this.records.push(s)}_addObject(t,n){let s={i:n,$:{}};this.keys.forEach((o,r)=>{let a=o.getFn?o.getFn(t):this.getFn(t,o.path);if(te(a)){if(Ce(a)){let c=[];const u=[{nestedArrIndex:-1,value:a}];for(;u.length;){const{nestedArrIndex:h,value:d}=u.pop();if(te(d))if(ve(d)&&!zt(d)){let p={v:d,i:h,n:this.norm.get(d)};c.push(p)}else Ce(d)&&d.forEach((p,v)=>{u.push({nestedArrIndex:v,value:p})})}s.$[r]=c}else if(ve(a)&&!zt(a)){let c={v:a,n:this.norm.get(a)};s.$[r]=c}}}),this.records.push(s)}toJSON(){return{keys:this.keys,records:this.records}}}function ns(e,t,{getFn:n=B.getFn,fieldNormWeight:s=B.fieldNormWeight}={}){const o=new gn({getFn:n,fieldNormWeight:s});return o.setKeys(e.map(ts)),o.setSources(t),o.create(),o}function co(e,{getFn:t=B.getFn,fieldNormWeight:n=B.fieldNormWeight}={}){const{keys:s,records:o}=e,r=new gn({getFn:t,fieldNormWeight:n});return r.setKeys(s),r.setIndexRecords(o),r}function xt(e,{errors:t=0,currentLocation:n=0,expectedLocation:s=0,distance:o=B.distance,ignoreLocation:r=B.ignoreLocation}={}){const a=t/e.length;if(r)return a;const c=Math.abs(s-n);return o?a+c/o:c?1:a}function lo(e=[],t=B.minMatchCharLength){let n=[],s=-1,o=-1,r=0;for(let a=e.length;r<a;r+=1){let c=e[r];c&&s===-1?s=r:!c&&s!==-1&&(o=r-1,o-s+1>=t&&n.push([s,o]),s=-1)}return e[r-1]&&r-s>=t&&n.push([s,r-1]),n}const Pe=32;function uo(e,t,n,{location:s=B.location,distance:o=B.distance,threshold:r=B.threshold,findAllMatches:a=B.findAllMatches,minMatchCharLength:c=B.minMatchCharLength,includeMatches:u=B.includeMatches,ignoreLocation:h=B.ignoreLocation}={}){if(t.length>Pe)throw new Error(Js(Pe));const d=t.length,p=e.length,v=Math.max(0,Math.min(s,p));let m=r,_=v;const g=c>1||u,x=g?Array(p):[];let y;for(;(y=e.indexOf(t,_))>-1;){let S=xt(t,{currentLocation:y,expectedLocation:v,distance:o,ignoreLocation:h});if(m=Math.min(S,m),_=y+d,g){let N=0;for(;N<d;)x[y+N]=1,N+=1}}_=-1;let w=[],b=1,A=d+p;const C=1<<d-1;for(let S=0;S<d;S+=1){let N=0,M=A;for(;N<M;)xt(t,{errors:S,currentLocation:v+M,expectedLocation:v,distance:o,ignoreLocation:h})<=m?N=M:A=M,M=Math.floor((A-N)/2+N);A=M;let $=Math.max(1,v-M+1),R=a?p:Math.min(v+M,p)+d,D=Array(R+2);D[R+1]=(1<<S)-1;for(let T=R;T>=$;T-=1){let z=T-1,X=n[e.charAt(z)];if(g&&(x[z]=+!!X),D[T]=(D[T+1]<<1|1)&X,S&&(D[T]|=(w[T+1]|w[T])<<1|1|w[T+1]),D[T]&C&&(b=xt(t,{errors:S,currentLocation:z,expectedLocation:v,distance:o,ignoreLocation:h}),b<=m)){if(m=b,_=z,_<=v)break;$=Math.max(1,2*v-_)}}if(xt(t,{errors:S+1,currentLocation:v,expectedLocation:v,distance:o,ignoreLocation:h})>m)break;w=D}const k={isMatch:_>=0,score:Math.max(.001,b)};if(g){const S=lo(x,c);S.length?u&&(k.indices=S):k.isMatch=!1}return k}function ho(e){let t={};for(let n=0,s=e.length;n<s;n+=1){const o=e.charAt(n);t[o]=(t[o]||0)|1<<s-n-1}return t}const At=String.prototype.normalize?e=>e.normalize("NFD").replace(/[\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08D3-\u08E1\u08E3-\u0903\u093A-\u093C\u093E-\u094F\u0951-\u0957\u0962\u0963\u0981-\u0983\u09BC\u09BE-\u09C4\u09C7\u09C8\u09CB-\u09CD\u09D7\u09E2\u09E3\u09FE\u0A01-\u0A03\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81-\u0A83\u0ABC\u0ABE-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01-\u0B03\u0B3C\u0B3E-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B62\u0B63\u0B82\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD7\u0C00-\u0C04\u0C3E-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81-\u0C83\u0CBC\u0CBE-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D00-\u0D03\u0D3B\u0D3C\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4D\u0D57\u0D62\u0D63\u0D82\u0D83\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DF2\u0DF3\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EB9\u0EBB\u0EBC\u0EC8-\u0ECD\u0F18\u0F19\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F71-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102B-\u103E\u1056-\u1059\u105E-\u1060\u1062-\u1064\u1067-\u106D\u1071-\u1074\u1082-\u108D\u108F\u109A-\u109D\u135D-\u135F\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4-\u17D3\u17DD\u180B-\u180D\u1885\u1886\u18A9\u1920-\u192B\u1930-\u193B\u1A17-\u1A1B\u1A55-\u1A5E\u1A60-\u1A7C\u1A7F\u1AB0-\u1ABE\u1B00-\u1B04\u1B34-\u1B44\u1B6B-\u1B73\u1B80-\u1B82\u1BA1-\u1BAD\u1BE6-\u1BF3\u1C24-\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE8\u1CED\u1CF2-\u1CF4\u1CF7-\u1CF9\u1DC0-\u1DF9\u1DFB-\u1DFF\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA823-\uA827\uA880\uA881\uA8B4-\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA953\uA980-\uA983\uA9B3-\uA9C0\uA9E5\uAA29-\uAA36\uAA43\uAA4C\uAA4D\uAA7B-\uAA7D\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEB-\uAAEF\uAAF5\uAAF6\uABE3-\uABEA\uABEC\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F]/g,""):e=>e;class ss{constructor(t,{location:n=B.location,threshold:s=B.threshold,distance:o=B.distance,includeMatches:r=B.includeMatches,findAllMatches:a=B.findAllMatches,minMatchCharLength:c=B.minMatchCharLength,isCaseSensitive:u=B.isCaseSensitive,ignoreDiacritics:h=B.ignoreDiacritics,ignoreLocation:d=B.ignoreLocation}={}){if(this.options={location:n,threshold:s,distance:o,includeMatches:r,findAllMatches:a,minMatchCharLength:c,isCaseSensitive:u,ignoreDiacritics:h,ignoreLocation:d},t=u?t:t.toLowerCase(),t=h?At(t):t,this.pattern=t,this.chunks=[],!this.pattern.length)return;const p=(m,_)=>{this.chunks.push({pattern:m,alphabet:ho(m),startIndex:_})},v=this.pattern.length;if(v>Pe){let m=0;const _=v%Pe,g=v-_;for(;m<g;)p(this.pattern.substr(m,Pe),m),m+=Pe;if(_){const x=v-Pe;p(this.pattern.substr(x),x)}}else p(this.pattern,0)}searchIn(t){const{isCaseSensitive:n,ignoreDiacritics:s,includeMatches:o}=this.options;if(t=n?t:t.toLowerCase(),t=s?At(t):t,this.pattern===t){let g={isMatch:!0,score:0};return o&&(g.indices=[[0,t.length-1]]),g}const{location:r,distance:a,threshold:c,findAllMatches:u,minMatchCharLength:h,ignoreLocation:d}=this.options;let p=[],v=0,m=!1;this.chunks.forEach(({pattern:g,alphabet:x,startIndex:y})=>{const{isMatch:w,score:b,indices:A}=uo(t,g,x,{location:r+y,distance:a,threshold:c,findAllMatches:u,minMatchCharLength:h,includeMatches:o,ignoreLocation:d});w&&(m=!0),v+=b,w&&A&&(p=[...p,...A])});let _={isMatch:m,score:m?v/this.chunks.length:1};return m&&o&&(_.indices=p),_}}class Me{constructor(t){this.pattern=t}static isMultiMatch(t){return Dn(t,this.multiRegex)}static isSingleMatch(t){return Dn(t,this.singleRegex)}search(){}}function Dn(e,t){const n=e.match(t);return n?n[1]:null}class fo extends Me{constructor(t){super(t)}static get type(){return"exact"}static get multiRegex(){return/^="(.*)"$/}static get singleRegex(){return/^=(.*)$/}search(t){const n=t===this.pattern;return{isMatch:n,score:n?0:1,indices:[0,this.pattern.length-1]}}}class go extends Me{constructor(t){super(t)}static get type(){return"inverse-exact"}static get multiRegex(){return/^!"(.*)"$/}static get singleRegex(){return/^!(.*)$/}search(t){const s=t.indexOf(this.pattern)===-1;return{isMatch:s,score:s?0:1,indices:[0,t.length-1]}}}class po extends Me{constructor(t){super(t)}static get type(){return"prefix-exact"}static get multiRegex(){return/^\^"(.*)"$/}static get singleRegex(){return/^\^(.*)$/}search(t){const n=t.startsWith(this.pattern);return{isMatch:n,score:n?0:1,indices:[0,this.pattern.length-1]}}}class mo extends Me{constructor(t){super(t)}static get type(){return"inverse-prefix-exact"}static get multiRegex(){return/^!\^"(.*)"$/}static get singleRegex(){return/^!\^(.*)$/}search(t){const n=!t.startsWith(this.pattern);return{isMatch:n,score:n?0:1,indices:[0,t.length-1]}}}class vo extends Me{constructor(t){super(t)}static get type(){return"suffix-exact"}static get multiRegex(){return/^"(.*)"\$$/}static get singleRegex(){return/^(.*)\$$/}search(t){const n=t.endsWith(this.pattern);return{isMatch:n,score:n?0:1,indices:[t.length-this.pattern.length,t.length-1]}}}class bo extends Me{constructor(t){super(t)}static get type(){return"inverse-suffix-exact"}static get multiRegex(){return/^!"(.*)"\$$/}static get singleRegex(){return/^!(.*)\$$/}search(t){const n=!t.endsWith(this.pattern);return{isMatch:n,score:n?0:1,indices:[0,t.length-1]}}}class os extends Me{constructor(t,{location:n=B.location,threshold:s=B.threshold,distance:o=B.distance,includeMatches:r=B.includeMatches,findAllMatches:a=B.findAllMatches,minMatchCharLength:c=B.minMatchCharLength,isCaseSensitive:u=B.isCaseSensitive,ignoreDiacritics:h=B.ignoreDiacritics,ignoreLocation:d=B.ignoreLocation}={}){super(t),this._bitapSearch=new ss(t,{location:n,threshold:s,distance:o,includeMatches:r,findAllMatches:a,minMatchCharLength:c,isCaseSensitive:u,ignoreDiacritics:h,ignoreLocation:d})}static get type(){return"fuzzy"}static get multiRegex(){return/^"(.*)"$/}static get singleRegex(){return/^(.*)$/}search(t){return this._bitapSearch.searchIn(t)}}class rs extends Me{constructor(t){super(t)}static get type(){return"include"}static get multiRegex(){return/^'"(.*)"$/}static get singleRegex(){return/^'(.*)$/}search(t){let n=0,s;const o=[],r=this.pattern.length;for(;(s=t.indexOf(this.pattern,n))>-1;)n=s+r,o.push([s,n-1]);const a=!!o.length;return{isMatch:a,score:a?0:1,indices:o}}}const Zt=[fo,rs,po,mo,bo,vo,go,os],Tn=Zt.length,xo=/ +(?=(?:[^\"]*\"[^\"]*\")*[^\"]*$)/,So="|";function yo(e,t={}){return e.split(So).map(n=>{let s=n.trim().split(xo).filter(r=>r&&!!r.trim()),o=[];for(let r=0,a=s.length;r<a;r+=1){const c=s[r];let u=!1,h=-1;for(;!u&&++h<Tn;){const d=Zt[h];let p=d.isMultiMatch(c);p&&(o.push(new d(p,t)),u=!0)}if(!u)for(h=-1;++h<Tn;){const d=Zt[h];let p=d.isSingleMatch(c);if(p){o.push(new d(p,t));break}}}return o})}const _o=new Set([os.type,rs.type]);class Co{constructor(t,{isCaseSensitive:n=B.isCaseSensitive,ignoreDiacritics:s=B.ignoreDiacritics,includeMatches:o=B.includeMatches,minMatchCharLength:r=B.minMatchCharLength,ignoreLocation:a=B.ignoreLocation,findAllMatches:c=B.findAllMatches,location:u=B.location,threshold:h=B.threshold,distance:d=B.distance}={}){this.query=null,this.options={isCaseSensitive:n,ignoreDiacritics:s,includeMatches:o,minMatchCharLength:r,findAllMatches:c,ignoreLocation:a,location:u,threshold:h,distance:d},t=n?t:t.toLowerCase(),t=s?At(t):t,this.pattern=t,this.query=yo(this.pattern,this.options)}static condition(t,n){return n.useExtendedSearch}searchIn(t){const n=this.query;if(!n)return{isMatch:!1,score:1};const{includeMatches:s,isCaseSensitive:o,ignoreDiacritics:r}=this.options;t=o?t:t.toLowerCase(),t=r?At(t):t;let a=0,c=[],u=0;for(let h=0,d=n.length;h<d;h+=1){const p=n[h];c.length=0,a=0;for(let v=0,m=p.length;v<m;v+=1){const _=p[v],{isMatch:g,indices:x,score:y}=_.search(t);if(g){if(a+=1,u+=y,s){const w=_.constructor.type;_o.has(w)?c=[...c,...x]:c.push(x)}}else{u=0,a=0,c.length=0;break}}if(a){let v={isMatch:!0,score:u/a};return s&&(v.indices=c),v}}return{isMatch:!1,score:1}}}const en=[];function wo(...e){en.push(...e)}function tn(e,t){for(let n=0,s=en.length;n<s;n+=1){let o=en[n];if(o.condition(e,t))return new o(e,t)}return new ss(e,t)}const Nt={AND:"$and",OR:"$or"},nn={PATH:"$path",PATTERN:"$val"},sn=e=>!!(e[Nt.AND]||e[Nt.OR]),ko=e=>!!e[nn.PATH],jo=e=>!Ce(e)&&Zn(e)&&!sn(e),Mn=e=>({[Nt.AND]:Object.keys(e).map(t=>({[t]:e[t]}))});function is(e,t,{auto:n=!0}={}){const s=o=>{let r=Object.keys(o);const a=ko(o);if(!a&&r.length>1&&!sn(o))return s(Mn(o));if(jo(o)){const u=a?o[nn.PATH]:r[0],h=a?o[nn.PATTERN]:o[u];if(!ve(h))throw new Error(qs(u));const d={keyId:Qt(u),pattern:h};return n&&(d.searcher=tn(h,t)),d}let c={children:[],operator:r[0]};return r.forEach(u=>{const h=o[u];Ce(h)&&h.forEach(d=>{c.children.push(s(d))})}),c};return sn(e)||(e=Mn(e)),s(e)}function Ao(e,{ignoreFieldNorm:t=B.ignoreFieldNorm}){e.forEach(n=>{let s=1;n.matches.forEach(({key:o,norm:r,score:a})=>{const c=o?o.weight:null;s*=Math.pow(a===0&&c?Number.EPSILON:a,(c||1)*(t?1:r))}),n.score=s})}function No(e,t){const n=e.matches;t.matches=[],te(n)&&n.forEach(s=>{if(!te(s.indices)||!s.indices.length)return;const{indices:o,value:r}=s;let a={indices:o,value:r};s.key&&(a.key=s.key.src),s.idx>-1&&(a.refIndex=s.idx),t.matches.push(a)})}function Io(e,t){t.score=e.score}function Bo(e,t,{includeMatches:n=B.includeMatches,includeScore:s=B.includeScore}={}){const o=[];return n&&o.push(No),s&&o.push(Io),e.map(r=>{const{idx:a}=r,c={item:t[a],refIndex:a};return o.length&&o.forEach(u=>{u(r,c)}),c})}class Oe{constructor(t,n={},s){this.options={...B,...n},this.options.useExtendedSearch,this._keyStore=new eo(this.options.keys),this.setCollection(t,s)}setCollection(t,n){if(this._docs=t,n&&!(n instanceof gn))throw new Error(Xs);this._myIndex=n||ns(this.options.keys,this._docs,{getFn:this.options.getFn,fieldNormWeight:this.options.fieldNormWeight})}add(t){te(t)&&(this._docs.push(t),this._myIndex.add(t))}remove(t=()=>!1){const n=[];for(let s=0,o=this._docs.length;s<o;s+=1){const r=this._docs[s];t(r,s)&&(this.removeAt(s),s-=1,o-=1,n.push(r))}return n}removeAt(t){this._docs.splice(t,1),this._myIndex.removeAt(t)}getIndex(){return this._myIndex}search(t,{limit:n=-1}={}){const{includeMatches:s,includeScore:o,shouldSort:r,sortFn:a,ignoreFieldNorm:c}=this.options;let u=ve(t)?ve(this._docs[0])?this._searchStringList(t):this._searchObjectList(t):this._searchLogical(t);return Ao(u,{ignoreFieldNorm:c}),r&&u.sort(a),Qn(n)&&n>-1&&(u=u.slice(0,n)),Bo(u,this._docs,{includeMatches:s,includeScore:o})}_searchStringList(t){const n=tn(t,this.options),{records:s}=this._myIndex,o=[];return s.forEach(({v:r,i:a,n:c})=>{if(!te(r))return;const{isMatch:u,score:h,indices:d}=n.searchIn(r);u&&o.push({item:r,idx:a,matches:[{score:h,value:r,norm:c,indices:d}]})}),o}_searchLogical(t){const n=is(t,this.options),s=(c,u,h)=>{if(!c.children){const{keyId:p,searcher:v}=c,m=this._findMatches({key:this._keyStore.get(p),value:this._myIndex.getValueForItemAtKeyId(u,p),searcher:v});return m&&m.length?[{idx:h,item:u,matches:m}]:[]}const d=[];for(let p=0,v=c.children.length;p<v;p+=1){const m=c.children[p],_=s(m,u,h);if(_.length)d.push(..._);else if(c.operator===Nt.AND)return[]}return d},o=this._myIndex.records,r={},a=[];return o.forEach(({$:c,i:u})=>{if(te(c)){let h=s(n,c,u);h.length&&(r[u]||(r[u]={idx:u,item:c,matches:[]},a.push(r[u])),h.forEach(({matches:d})=>{r[u].matches.push(...d)}))}}),a}_searchObjectList(t){const n=tn(t,this.options),{keys:s,records:o}=this._myIndex,r=[];return o.forEach(({$:a,i:c})=>{if(!te(a))return;let u=[];s.forEach((h,d)=>{u.push(...this._findMatches({key:h,value:a[d],searcher:n}))}),u.length&&r.push({idx:c,item:a,matches:u})}),r}_findMatches({key:t,value:n,searcher:s}){if(!te(n))return[];let o=[];if(Ce(n))n.forEach(({v:r,i:a,n:c})=>{if(!te(r))return;const{isMatch:u,score:h,indices:d}=s.searchIn(r);u&&o.push({score:h,key:t,value:r,idx:a,norm:c,indices:d})});else{const{v:r,n:a}=n,{isMatch:c,score:u,indices:h}=s.searchIn(r);c&&o.push({score:u,key:t,value:r,norm:a,indices:h})}return o}}Oe.version="7.1.0";Oe.createIndex=ns;Oe.parseIndex=co;Oe.config=B;Oe.parseQuery=is;wo(Co);function Eo(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return f.useMemo(()=>s=>{t.forEach(o=>o(s))},t)}const Mt=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function Xe(e){const t=Object.prototype.toString.call(e);return t==="[object Window]"||t==="[object global]"}function pn(e){return"nodeType"in e}function J(e){var t,n;return e?Xe(e)?e:pn(e)&&(t=(n=e.ownerDocument)==null?void 0:n.defaultView)!=null?t:window:window}function mn(e){const{Document:t}=J(e);return e instanceof t}function ft(e){return Xe(e)?!1:e instanceof J(e).HTMLElement}function as(e){return e instanceof J(e).SVGElement}function qe(e){return e?Xe(e)?e.document:pn(e)?mn(e)?e:ft(e)||as(e)?e.ownerDocument:document:document:document}const be=Mt?f.useLayoutEffect:f.useEffect;function vn(e){const t=f.useRef(e);return be(()=>{t.current=e}),f.useCallback(function(){for(var n=arguments.length,s=new Array(n),o=0;o<n;o++)s[o]=arguments[o];return t.current==null?void 0:t.current(...s)},[])}function Do(){const e=f.useRef(null),t=f.useCallback((s,o)=>{e.current=setInterval(s,o)},[]),n=f.useCallback(()=>{e.current!==null&&(clearInterval(e.current),e.current=null)},[]);return[t,n]}function dt(e,t){t===void 0&&(t=[e]);const n=f.useRef(e);return be(()=>{n.current!==e&&(n.current=e)},t),n}function gt(e,t){const n=f.useRef();return f.useMemo(()=>{const s=e(n.current);return n.current=s,s},[...t])}function It(e){const t=vn(e),n=f.useRef(null),s=f.useCallback(o=>{o!==n.current&&(t==null||t(o,n.current)),n.current=o},[]);return[n,s]}function on(e){const t=f.useRef();return f.useEffect(()=>{t.current=e},[e]),t.current}let Ht={};function pt(e,t){return f.useMemo(()=>{if(t)return t;const n=Ht[e]==null?0:Ht[e]+1;return Ht[e]=n,e+"-"+n},[e,t])}function cs(e){return function(t){for(var n=arguments.length,s=new Array(n>1?n-1:0),o=1;o<n;o++)s[o-1]=arguments[o];return s.reduce((r,a)=>{const c=Object.entries(a);for(const[u,h]of c){const d=r[u];d!=null&&(r[u]=d+e*h)}return r},{...t})}}const Ge=cs(1),Bt=cs(-1);function To(e){return"clientX"in e&&"clientY"in e}function bn(e){if(!e)return!1;const{KeyboardEvent:t}=J(e.target);return t&&e instanceof t}function Mo(e){if(!e)return!1;const{TouchEvent:t}=J(e.target);return t&&e instanceof t}function rn(e){if(Mo(e)){if(e.touches&&e.touches.length){const{clientX:t,clientY:n}=e.touches[0];return{x:t,y:n}}else if(e.changedTouches&&e.changedTouches.length){const{clientX:t,clientY:n}=e.changedTouches[0];return{x:t,y:n}}}return To(e)?{x:e.clientX,y:e.clientY}:null}const Ye=Object.freeze({Translate:{toString(e){if(!e)return;const{x:t,y:n}=e;return"translate3d("+(t?Math.round(t):0)+"px, "+(n?Math.round(n):0)+"px, 0)"}},Scale:{toString(e){if(!e)return;const{scaleX:t,scaleY:n}=e;return"scaleX("+t+") scaleY("+n+")"}},Transform:{toString(e){if(e)return[Ye.Translate.toString(e),Ye.Scale.toString(e)].join(" ")}},Transition:{toString(e){let{property:t,duration:n,easing:s}=e;return t+" "+n+"ms "+s}}}),Rn="a,frame,iframe,input:not([type=hidden]):not(:disabled),select:not(:disabled),textarea:not(:disabled),button:not(:disabled),*[tabindex]";function Ro(e){return e.matches(Rn)?e:e.querySelector(Rn)}const Po={display:"none"};function Oo(e){let{id:t,value:n}=e;return f.createElement("div",{id:t,style:Po},n)}function Lo(e){let{id:t,announcement:n,ariaLiveType:s="assertive"}=e;const o={position:"fixed",top:0,left:0,width:1,height:1,margin:-1,border:0,padding:0,overflow:"hidden",clip:"rect(0 0 0 0)",clipPath:"inset(100%)",whiteSpace:"nowrap"};return f.createElement("div",{id:t,style:o,role:"status","aria-live":s,"aria-atomic":!0},n)}function $o(){const[e,t]=f.useState("");return{announce:f.useCallback(s=>{s!=null&&t(s)},[]),announcement:e}}const ls=f.createContext(null);function Fo(e){const t=f.useContext(ls);f.useEffect(()=>{if(!t)throw new Error("useDndMonitor must be used within a children of <DndContext>");return t(e)},[e,t])}function zo(){const[e]=f.useState(()=>new Set),t=f.useCallback(s=>(e.add(s),()=>e.delete(s)),[e]);return[f.useCallback(s=>{let{type:o,event:r}=s;e.forEach(a=>{var c;return(c=a[o])==null?void 0:c.call(a,r)})},[e]),t]}const Ho={draggable:`
1
+ "use strict";const i=require("react/jsx-runtime"),f=require("react"),l=require("./builder-DajwWRB4.cjs"),j=require("./ui-components-cdIfqSzy.cjs");require("./charge-BOfQrkLv.cjs");const at=require("react-dom");require("./ticket-D-hMXIqO.cjs");const Tt=({render:e,block:t})=>e(t),dn=({settings:e,pageContext:t})=>{const{footer:n}=l.useLayersStore(),{settings:s}=l.useSettingsStore(),{pageContext:o}=l.usePagesStore(),{footer:r}=l.useBlocksStore();if(!r||!n)return null;const a=new r;return Object.keys(n).map(c=>{a[c]=n[c]}),a.renderBlock((e==null?void 0:e.blockSettings)||s,t||o)},hn=({settings:e,pageContext:t})=>{const{header:n}=l.useLayersStore(),{settings:s}=l.useSettingsStore(),{pageContext:o}=l.usePagesStore(),{header:r}=l.useBlocksStore();if(!r||!n)return null;const a=new r;return Object.keys(n).map(c=>{a[c]=n[c]}),a.renderBlock((e==null?void 0:e.blockSettings)||s,t||o)},fn=({settings:e,pageContext:t})=>{const{announcement:n}=l.useLayersStore(),{settings:s}=l.useSettingsStore(),{pageContext:o}=l.usePagesStore(),{announcement:r}=l.useBlocksStore();if(!r||!n)return null;const a=new r;return Object.keys(n).map(c=>{a[c]=n[c]}),a.renderBlock(e||s,t||o)},Us=Object.freeze(Object.defineProperty({__proto__:null,RenderAnnouncement:fn,RenderBlock:Tt,RenderFooter:dn,RenderHeader:hn},Symbol.toStringTag,{value:"Module"}));function Ce(e){return Array.isArray?Array.isArray(e):es(e)==="[object Array]"}function Vs(e){if(typeof e=="string")return e;let t=e+"";return t=="0"&&1/e==-1/0?"-0":t}function Ks(e){return e==null?"":Vs(e)}function ve(e){return typeof e=="string"}function Qn(e){return typeof e=="number"}function Gs(e){return e===!0||e===!1||Ys(e)&&es(e)=="[object Boolean]"}function Zn(e){return typeof e=="object"}function Ys(e){return Zn(e)&&e!==null}function te(e){return e!=null}function zt(e){return!e.trim().length}function es(e){return e==null?e===void 0?"[object Undefined]":"[object Null]":Object.prototype.toString.call(e)}const Xs="Incorrect 'index' type",qs=e=>`Invalid value for key ${e}`,Js=e=>`Pattern length exceeds max of ${e}.`,Qs=e=>`Missing ${e} property in key`,Zs=e=>`Property 'weight' in key '${e}' must be a positive integer`,Bn=Object.prototype.hasOwnProperty;class eo{constructor(t){this._keys=[],this._keyMap={};let n=0;t.forEach(s=>{let o=ts(s);this._keys.push(o),this._keyMap[o.id]=o,n+=o.weight}),this._keys.forEach(s=>{s.weight/=n})}get(t){return this._keyMap[t]}keys(){return this._keys}toJSON(){return JSON.stringify(this._keys)}}function ts(e){let t=null,n=null,s=null,o=1,r=null;if(ve(e)||Ce(e))s=e,t=En(e),n=Qt(e);else{if(!Bn.call(e,"name"))throw new Error(Qs("name"));const a=e.name;if(s=a,Bn.call(e,"weight")&&(o=e.weight,o<=0))throw new Error(Zs(a));t=En(a),n=Qt(a),r=e.getFn}return{path:t,id:n,weight:o,src:s,getFn:r}}function En(e){return Ce(e)?e:e.split(".")}function Qt(e){return Ce(e)?e.join("."):e}function to(e,t){let n=[],s=!1;const o=(r,a,c)=>{if(te(r))if(!a[c])n.push(r);else{let u=a[c];const h=r[u];if(!te(h))return;if(c===a.length-1&&(ve(h)||Qn(h)||Gs(h)))n.push(Ks(h));else if(Ce(h)){s=!0;for(let d=0,p=h.length;d<p;d+=1)o(h[d],a,c+1)}else a.length&&o(h,a,c+1)}};return o(e,ve(t)?t.split("."):t,0),s?n:n[0]}const no={includeMatches:!1,findAllMatches:!1,minMatchCharLength:1},so={isCaseSensitive:!1,ignoreDiacritics:!1,includeScore:!1,keys:[],shouldSort:!0,sortFn:(e,t)=>e.score===t.score?e.idx<t.idx?-1:1:e.score<t.score?-1:1},oo={location:0,threshold:.6,distance:100},ro={useExtendedSearch:!1,getFn:to,ignoreLocation:!1,ignoreFieldNorm:!1,fieldNormWeight:1};var B={...so,...no,...oo,...ro};const io=/[^ ]+/g;function ao(e=1,t=3){const n=new Map,s=Math.pow(10,t);return{get(o){const r=o.match(io).length;if(n.has(r))return n.get(r);const a=1/Math.pow(r,.5*e),c=parseFloat(Math.round(a*s)/s);return n.set(r,c),c},clear(){n.clear()}}}class gn{constructor({getFn:t=B.getFn,fieldNormWeight:n=B.fieldNormWeight}={}){this.norm=ao(n,3),this.getFn=t,this.isCreated=!1,this.setIndexRecords()}setSources(t=[]){this.docs=t}setIndexRecords(t=[]){this.records=t}setKeys(t=[]){this.keys=t,this._keysMap={},t.forEach((n,s)=>{this._keysMap[n.id]=s})}create(){this.isCreated||!this.docs.length||(this.isCreated=!0,ve(this.docs[0])?this.docs.forEach((t,n)=>{this._addString(t,n)}):this.docs.forEach((t,n)=>{this._addObject(t,n)}),this.norm.clear())}add(t){const n=this.size();ve(t)?this._addString(t,n):this._addObject(t,n)}removeAt(t){this.records.splice(t,1);for(let n=t,s=this.size();n<s;n+=1)this.records[n].i-=1}getValueForItemAtKeyId(t,n){return t[this._keysMap[n]]}size(){return this.records.length}_addString(t,n){if(!te(t)||zt(t))return;let s={v:t,i:n,n:this.norm.get(t)};this.records.push(s)}_addObject(t,n){let s={i:n,$:{}};this.keys.forEach((o,r)=>{let a=o.getFn?o.getFn(t):this.getFn(t,o.path);if(te(a)){if(Ce(a)){let c=[];const u=[{nestedArrIndex:-1,value:a}];for(;u.length;){const{nestedArrIndex:h,value:d}=u.pop();if(te(d))if(ve(d)&&!zt(d)){let p={v:d,i:h,n:this.norm.get(d)};c.push(p)}else Ce(d)&&d.forEach((p,v)=>{u.push({nestedArrIndex:v,value:p})})}s.$[r]=c}else if(ve(a)&&!zt(a)){let c={v:a,n:this.norm.get(a)};s.$[r]=c}}}),this.records.push(s)}toJSON(){return{keys:this.keys,records:this.records}}}function ns(e,t,{getFn:n=B.getFn,fieldNormWeight:s=B.fieldNormWeight}={}){const o=new gn({getFn:n,fieldNormWeight:s});return o.setKeys(e.map(ts)),o.setSources(t),o.create(),o}function co(e,{getFn:t=B.getFn,fieldNormWeight:n=B.fieldNormWeight}={}){const{keys:s,records:o}=e,r=new gn({getFn:t,fieldNormWeight:n});return r.setKeys(s),r.setIndexRecords(o),r}function xt(e,{errors:t=0,currentLocation:n=0,expectedLocation:s=0,distance:o=B.distance,ignoreLocation:r=B.ignoreLocation}={}){const a=t/e.length;if(r)return a;const c=Math.abs(s-n);return o?a+c/o:c?1:a}function lo(e=[],t=B.minMatchCharLength){let n=[],s=-1,o=-1,r=0;for(let a=e.length;r<a;r+=1){let c=e[r];c&&s===-1?s=r:!c&&s!==-1&&(o=r-1,o-s+1>=t&&n.push([s,o]),s=-1)}return e[r-1]&&r-s>=t&&n.push([s,r-1]),n}const Pe=32;function uo(e,t,n,{location:s=B.location,distance:o=B.distance,threshold:r=B.threshold,findAllMatches:a=B.findAllMatches,minMatchCharLength:c=B.minMatchCharLength,includeMatches:u=B.includeMatches,ignoreLocation:h=B.ignoreLocation}={}){if(t.length>Pe)throw new Error(Js(Pe));const d=t.length,p=e.length,v=Math.max(0,Math.min(s,p));let m=r,_=v;const g=c>1||u,x=g?Array(p):[];let y;for(;(y=e.indexOf(t,_))>-1;){let S=xt(t,{currentLocation:y,expectedLocation:v,distance:o,ignoreLocation:h});if(m=Math.min(S,m),_=y+d,g){let N=0;for(;N<d;)x[y+N]=1,N+=1}}_=-1;let w=[],b=1,A=d+p;const C=1<<d-1;for(let S=0;S<d;S+=1){let N=0,M=A;for(;N<M;)xt(t,{errors:S,currentLocation:v+M,expectedLocation:v,distance:o,ignoreLocation:h})<=m?N=M:A=M,M=Math.floor((A-N)/2+N);A=M;let $=Math.max(1,v-M+1),R=a?p:Math.min(v+M,p)+d,D=Array(R+2);D[R+1]=(1<<S)-1;for(let T=R;T>=$;T-=1){let z=T-1,X=n[e.charAt(z)];if(g&&(x[z]=+!!X),D[T]=(D[T+1]<<1|1)&X,S&&(D[T]|=(w[T+1]|w[T])<<1|1|w[T+1]),D[T]&C&&(b=xt(t,{errors:S,currentLocation:z,expectedLocation:v,distance:o,ignoreLocation:h}),b<=m)){if(m=b,_=z,_<=v)break;$=Math.max(1,2*v-_)}}if(xt(t,{errors:S+1,currentLocation:v,expectedLocation:v,distance:o,ignoreLocation:h})>m)break;w=D}const k={isMatch:_>=0,score:Math.max(.001,b)};if(g){const S=lo(x,c);S.length?u&&(k.indices=S):k.isMatch=!1}return k}function ho(e){let t={};for(let n=0,s=e.length;n<s;n+=1){const o=e.charAt(n);t[o]=(t[o]||0)|1<<s-n-1}return t}const At=String.prototype.normalize?e=>e.normalize("NFD").replace(/[\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08D3-\u08E1\u08E3-\u0903\u093A-\u093C\u093E-\u094F\u0951-\u0957\u0962\u0963\u0981-\u0983\u09BC\u09BE-\u09C4\u09C7\u09C8\u09CB-\u09CD\u09D7\u09E2\u09E3\u09FE\u0A01-\u0A03\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81-\u0A83\u0ABC\u0ABE-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01-\u0B03\u0B3C\u0B3E-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B62\u0B63\u0B82\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD7\u0C00-\u0C04\u0C3E-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81-\u0C83\u0CBC\u0CBE-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D00-\u0D03\u0D3B\u0D3C\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4D\u0D57\u0D62\u0D63\u0D82\u0D83\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DF2\u0DF3\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EB9\u0EBB\u0EBC\u0EC8-\u0ECD\u0F18\u0F19\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F71-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102B-\u103E\u1056-\u1059\u105E-\u1060\u1062-\u1064\u1067-\u106D\u1071-\u1074\u1082-\u108D\u108F\u109A-\u109D\u135D-\u135F\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4-\u17D3\u17DD\u180B-\u180D\u1885\u1886\u18A9\u1920-\u192B\u1930-\u193B\u1A17-\u1A1B\u1A55-\u1A5E\u1A60-\u1A7C\u1A7F\u1AB0-\u1ABE\u1B00-\u1B04\u1B34-\u1B44\u1B6B-\u1B73\u1B80-\u1B82\u1BA1-\u1BAD\u1BE6-\u1BF3\u1C24-\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE8\u1CED\u1CF2-\u1CF4\u1CF7-\u1CF9\u1DC0-\u1DF9\u1DFB-\u1DFF\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA823-\uA827\uA880\uA881\uA8B4-\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA953\uA980-\uA983\uA9B3-\uA9C0\uA9E5\uAA29-\uAA36\uAA43\uAA4C\uAA4D\uAA7B-\uAA7D\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEB-\uAAEF\uAAF5\uAAF6\uABE3-\uABEA\uABEC\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F]/g,""):e=>e;class ss{constructor(t,{location:n=B.location,threshold:s=B.threshold,distance:o=B.distance,includeMatches:r=B.includeMatches,findAllMatches:a=B.findAllMatches,minMatchCharLength:c=B.minMatchCharLength,isCaseSensitive:u=B.isCaseSensitive,ignoreDiacritics:h=B.ignoreDiacritics,ignoreLocation:d=B.ignoreLocation}={}){if(this.options={location:n,threshold:s,distance:o,includeMatches:r,findAllMatches:a,minMatchCharLength:c,isCaseSensitive:u,ignoreDiacritics:h,ignoreLocation:d},t=u?t:t.toLowerCase(),t=h?At(t):t,this.pattern=t,this.chunks=[],!this.pattern.length)return;const p=(m,_)=>{this.chunks.push({pattern:m,alphabet:ho(m),startIndex:_})},v=this.pattern.length;if(v>Pe){let m=0;const _=v%Pe,g=v-_;for(;m<g;)p(this.pattern.substr(m,Pe),m),m+=Pe;if(_){const x=v-Pe;p(this.pattern.substr(x),x)}}else p(this.pattern,0)}searchIn(t){const{isCaseSensitive:n,ignoreDiacritics:s,includeMatches:o}=this.options;if(t=n?t:t.toLowerCase(),t=s?At(t):t,this.pattern===t){let g={isMatch:!0,score:0};return o&&(g.indices=[[0,t.length-1]]),g}const{location:r,distance:a,threshold:c,findAllMatches:u,minMatchCharLength:h,ignoreLocation:d}=this.options;let p=[],v=0,m=!1;this.chunks.forEach(({pattern:g,alphabet:x,startIndex:y})=>{const{isMatch:w,score:b,indices:A}=uo(t,g,x,{location:r+y,distance:a,threshold:c,findAllMatches:u,minMatchCharLength:h,includeMatches:o,ignoreLocation:d});w&&(m=!0),v+=b,w&&A&&(p=[...p,...A])});let _={isMatch:m,score:m?v/this.chunks.length:1};return m&&o&&(_.indices=p),_}}class Me{constructor(t){this.pattern=t}static isMultiMatch(t){return Dn(t,this.multiRegex)}static isSingleMatch(t){return Dn(t,this.singleRegex)}search(){}}function Dn(e,t){const n=e.match(t);return n?n[1]:null}class fo extends Me{constructor(t){super(t)}static get type(){return"exact"}static get multiRegex(){return/^="(.*)"$/}static get singleRegex(){return/^=(.*)$/}search(t){const n=t===this.pattern;return{isMatch:n,score:n?0:1,indices:[0,this.pattern.length-1]}}}class go extends Me{constructor(t){super(t)}static get type(){return"inverse-exact"}static get multiRegex(){return/^!"(.*)"$/}static get singleRegex(){return/^!(.*)$/}search(t){const s=t.indexOf(this.pattern)===-1;return{isMatch:s,score:s?0:1,indices:[0,t.length-1]}}}class po extends Me{constructor(t){super(t)}static get type(){return"prefix-exact"}static get multiRegex(){return/^\^"(.*)"$/}static get singleRegex(){return/^\^(.*)$/}search(t){const n=t.startsWith(this.pattern);return{isMatch:n,score:n?0:1,indices:[0,this.pattern.length-1]}}}class mo extends Me{constructor(t){super(t)}static get type(){return"inverse-prefix-exact"}static get multiRegex(){return/^!\^"(.*)"$/}static get singleRegex(){return/^!\^(.*)$/}search(t){const n=!t.startsWith(this.pattern);return{isMatch:n,score:n?0:1,indices:[0,t.length-1]}}}class vo extends Me{constructor(t){super(t)}static get type(){return"suffix-exact"}static get multiRegex(){return/^"(.*)"\$$/}static get singleRegex(){return/^(.*)\$$/}search(t){const n=t.endsWith(this.pattern);return{isMatch:n,score:n?0:1,indices:[t.length-this.pattern.length,t.length-1]}}}class bo extends Me{constructor(t){super(t)}static get type(){return"inverse-suffix-exact"}static get multiRegex(){return/^!"(.*)"\$$/}static get singleRegex(){return/^!(.*)\$$/}search(t){const n=!t.endsWith(this.pattern);return{isMatch:n,score:n?0:1,indices:[0,t.length-1]}}}class os extends Me{constructor(t,{location:n=B.location,threshold:s=B.threshold,distance:o=B.distance,includeMatches:r=B.includeMatches,findAllMatches:a=B.findAllMatches,minMatchCharLength:c=B.minMatchCharLength,isCaseSensitive:u=B.isCaseSensitive,ignoreDiacritics:h=B.ignoreDiacritics,ignoreLocation:d=B.ignoreLocation}={}){super(t),this._bitapSearch=new ss(t,{location:n,threshold:s,distance:o,includeMatches:r,findAllMatches:a,minMatchCharLength:c,isCaseSensitive:u,ignoreDiacritics:h,ignoreLocation:d})}static get type(){return"fuzzy"}static get multiRegex(){return/^"(.*)"$/}static get singleRegex(){return/^(.*)$/}search(t){return this._bitapSearch.searchIn(t)}}class rs extends Me{constructor(t){super(t)}static get type(){return"include"}static get multiRegex(){return/^'"(.*)"$/}static get singleRegex(){return/^'(.*)$/}search(t){let n=0,s;const o=[],r=this.pattern.length;for(;(s=t.indexOf(this.pattern,n))>-1;)n=s+r,o.push([s,n-1]);const a=!!o.length;return{isMatch:a,score:a?0:1,indices:o}}}const Zt=[fo,rs,po,mo,bo,vo,go,os],Tn=Zt.length,xo=/ +(?=(?:[^\"]*\"[^\"]*\")*[^\"]*$)/,So="|";function yo(e,t={}){return e.split(So).map(n=>{let s=n.trim().split(xo).filter(r=>r&&!!r.trim()),o=[];for(let r=0,a=s.length;r<a;r+=1){const c=s[r];let u=!1,h=-1;for(;!u&&++h<Tn;){const d=Zt[h];let p=d.isMultiMatch(c);p&&(o.push(new d(p,t)),u=!0)}if(!u)for(h=-1;++h<Tn;){const d=Zt[h];let p=d.isSingleMatch(c);if(p){o.push(new d(p,t));break}}}return o})}const _o=new Set([os.type,rs.type]);class Co{constructor(t,{isCaseSensitive:n=B.isCaseSensitive,ignoreDiacritics:s=B.ignoreDiacritics,includeMatches:o=B.includeMatches,minMatchCharLength:r=B.minMatchCharLength,ignoreLocation:a=B.ignoreLocation,findAllMatches:c=B.findAllMatches,location:u=B.location,threshold:h=B.threshold,distance:d=B.distance}={}){this.query=null,this.options={isCaseSensitive:n,ignoreDiacritics:s,includeMatches:o,minMatchCharLength:r,findAllMatches:c,ignoreLocation:a,location:u,threshold:h,distance:d},t=n?t:t.toLowerCase(),t=s?At(t):t,this.pattern=t,this.query=yo(this.pattern,this.options)}static condition(t,n){return n.useExtendedSearch}searchIn(t){const n=this.query;if(!n)return{isMatch:!1,score:1};const{includeMatches:s,isCaseSensitive:o,ignoreDiacritics:r}=this.options;t=o?t:t.toLowerCase(),t=r?At(t):t;let a=0,c=[],u=0;for(let h=0,d=n.length;h<d;h+=1){const p=n[h];c.length=0,a=0;for(let v=0,m=p.length;v<m;v+=1){const _=p[v],{isMatch:g,indices:x,score:y}=_.search(t);if(g){if(a+=1,u+=y,s){const w=_.constructor.type;_o.has(w)?c=[...c,...x]:c.push(x)}}else{u=0,a=0,c.length=0;break}}if(a){let v={isMatch:!0,score:u/a};return s&&(v.indices=c),v}}return{isMatch:!1,score:1}}}const en=[];function wo(...e){en.push(...e)}function tn(e,t){for(let n=0,s=en.length;n<s;n+=1){let o=en[n];if(o.condition(e,t))return new o(e,t)}return new ss(e,t)}const Nt={AND:"$and",OR:"$or"},nn={PATH:"$path",PATTERN:"$val"},sn=e=>!!(e[Nt.AND]||e[Nt.OR]),ko=e=>!!e[nn.PATH],jo=e=>!Ce(e)&&Zn(e)&&!sn(e),Mn=e=>({[Nt.AND]:Object.keys(e).map(t=>({[t]:e[t]}))});function is(e,t,{auto:n=!0}={}){const s=o=>{let r=Object.keys(o);const a=ko(o);if(!a&&r.length>1&&!sn(o))return s(Mn(o));if(jo(o)){const u=a?o[nn.PATH]:r[0],h=a?o[nn.PATTERN]:o[u];if(!ve(h))throw new Error(qs(u));const d={keyId:Qt(u),pattern:h};return n&&(d.searcher=tn(h,t)),d}let c={children:[],operator:r[0]};return r.forEach(u=>{const h=o[u];Ce(h)&&h.forEach(d=>{c.children.push(s(d))})}),c};return sn(e)||(e=Mn(e)),s(e)}function Ao(e,{ignoreFieldNorm:t=B.ignoreFieldNorm}){e.forEach(n=>{let s=1;n.matches.forEach(({key:o,norm:r,score:a})=>{const c=o?o.weight:null;s*=Math.pow(a===0&&c?Number.EPSILON:a,(c||1)*(t?1:r))}),n.score=s})}function No(e,t){const n=e.matches;t.matches=[],te(n)&&n.forEach(s=>{if(!te(s.indices)||!s.indices.length)return;const{indices:o,value:r}=s;let a={indices:o,value:r};s.key&&(a.key=s.key.src),s.idx>-1&&(a.refIndex=s.idx),t.matches.push(a)})}function Io(e,t){t.score=e.score}function Bo(e,t,{includeMatches:n=B.includeMatches,includeScore:s=B.includeScore}={}){const o=[];return n&&o.push(No),s&&o.push(Io),e.map(r=>{const{idx:a}=r,c={item:t[a],refIndex:a};return o.length&&o.forEach(u=>{u(r,c)}),c})}class Oe{constructor(t,n={},s){this.options={...B,...n},this.options.useExtendedSearch,this._keyStore=new eo(this.options.keys),this.setCollection(t,s)}setCollection(t,n){if(this._docs=t,n&&!(n instanceof gn))throw new Error(Xs);this._myIndex=n||ns(this.options.keys,this._docs,{getFn:this.options.getFn,fieldNormWeight:this.options.fieldNormWeight})}add(t){te(t)&&(this._docs.push(t),this._myIndex.add(t))}remove(t=()=>!1){const n=[];for(let s=0,o=this._docs.length;s<o;s+=1){const r=this._docs[s];t(r,s)&&(this.removeAt(s),s-=1,o-=1,n.push(r))}return n}removeAt(t){this._docs.splice(t,1),this._myIndex.removeAt(t)}getIndex(){return this._myIndex}search(t,{limit:n=-1}={}){const{includeMatches:s,includeScore:o,shouldSort:r,sortFn:a,ignoreFieldNorm:c}=this.options;let u=ve(t)?ve(this._docs[0])?this._searchStringList(t):this._searchObjectList(t):this._searchLogical(t);return Ao(u,{ignoreFieldNorm:c}),r&&u.sort(a),Qn(n)&&n>-1&&(u=u.slice(0,n)),Bo(u,this._docs,{includeMatches:s,includeScore:o})}_searchStringList(t){const n=tn(t,this.options),{records:s}=this._myIndex,o=[];return s.forEach(({v:r,i:a,n:c})=>{if(!te(r))return;const{isMatch:u,score:h,indices:d}=n.searchIn(r);u&&o.push({item:r,idx:a,matches:[{score:h,value:r,norm:c,indices:d}]})}),o}_searchLogical(t){const n=is(t,this.options),s=(c,u,h)=>{if(!c.children){const{keyId:p,searcher:v}=c,m=this._findMatches({key:this._keyStore.get(p),value:this._myIndex.getValueForItemAtKeyId(u,p),searcher:v});return m&&m.length?[{idx:h,item:u,matches:m}]:[]}const d=[];for(let p=0,v=c.children.length;p<v;p+=1){const m=c.children[p],_=s(m,u,h);if(_.length)d.push(..._);else if(c.operator===Nt.AND)return[]}return d},o=this._myIndex.records,r={},a=[];return o.forEach(({$:c,i:u})=>{if(te(c)){let h=s(n,c,u);h.length&&(r[u]||(r[u]={idx:u,item:c,matches:[]},a.push(r[u])),h.forEach(({matches:d})=>{r[u].matches.push(...d)}))}}),a}_searchObjectList(t){const n=tn(t,this.options),{keys:s,records:o}=this._myIndex,r=[];return o.forEach(({$:a,i:c})=>{if(!te(a))return;let u=[];s.forEach((h,d)=>{u.push(...this._findMatches({key:h,value:a[d],searcher:n}))}),u.length&&r.push({idx:c,item:a,matches:u})}),r}_findMatches({key:t,value:n,searcher:s}){if(!te(n))return[];let o=[];if(Ce(n))n.forEach(({v:r,i:a,n:c})=>{if(!te(r))return;const{isMatch:u,score:h,indices:d}=s.searchIn(r);u&&o.push({score:h,key:t,value:r,idx:a,norm:c,indices:d})});else{const{v:r,n:a}=n,{isMatch:c,score:u,indices:h}=s.searchIn(r);c&&o.push({score:u,key:t,value:r,norm:a,indices:h})}return o}}Oe.version="7.1.0";Oe.createIndex=ns;Oe.parseIndex=co;Oe.config=B;Oe.parseQuery=is;wo(Co);function Eo(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return f.useMemo(()=>s=>{t.forEach(o=>o(s))},t)}const Mt=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function Xe(e){const t=Object.prototype.toString.call(e);return t==="[object Window]"||t==="[object global]"}function pn(e){return"nodeType"in e}function J(e){var t,n;return e?Xe(e)?e:pn(e)&&(t=(n=e.ownerDocument)==null?void 0:n.defaultView)!=null?t:window:window}function mn(e){const{Document:t}=J(e);return e instanceof t}function ft(e){return Xe(e)?!1:e instanceof J(e).HTMLElement}function as(e){return e instanceof J(e).SVGElement}function qe(e){return e?Xe(e)?e.document:pn(e)?mn(e)?e:ft(e)||as(e)?e.ownerDocument:document:document:document}const be=Mt?f.useLayoutEffect:f.useEffect;function vn(e){const t=f.useRef(e);return be(()=>{t.current=e}),f.useCallback(function(){for(var n=arguments.length,s=new Array(n),o=0;o<n;o++)s[o]=arguments[o];return t.current==null?void 0:t.current(...s)},[])}function Do(){const e=f.useRef(null),t=f.useCallback((s,o)=>{e.current=setInterval(s,o)},[]),n=f.useCallback(()=>{e.current!==null&&(clearInterval(e.current),e.current=null)},[]);return[t,n]}function dt(e,t){t===void 0&&(t=[e]);const n=f.useRef(e);return be(()=>{n.current!==e&&(n.current=e)},t),n}function gt(e,t){const n=f.useRef();return f.useMemo(()=>{const s=e(n.current);return n.current=s,s},[...t])}function It(e){const t=vn(e),n=f.useRef(null),s=f.useCallback(o=>{o!==n.current&&(t==null||t(o,n.current)),n.current=o},[]);return[n,s]}function on(e){const t=f.useRef();return f.useEffect(()=>{t.current=e},[e]),t.current}let Ht={};function pt(e,t){return f.useMemo(()=>{if(t)return t;const n=Ht[e]==null?0:Ht[e]+1;return Ht[e]=n,e+"-"+n},[e,t])}function cs(e){return function(t){for(var n=arguments.length,s=new Array(n>1?n-1:0),o=1;o<n;o++)s[o-1]=arguments[o];return s.reduce((r,a)=>{const c=Object.entries(a);for(const[u,h]of c){const d=r[u];d!=null&&(r[u]=d+e*h)}return r},{...t})}}const Ge=cs(1),Bt=cs(-1);function To(e){return"clientX"in e&&"clientY"in e}function bn(e){if(!e)return!1;const{KeyboardEvent:t}=J(e.target);return t&&e instanceof t}function Mo(e){if(!e)return!1;const{TouchEvent:t}=J(e.target);return t&&e instanceof t}function rn(e){if(Mo(e)){if(e.touches&&e.touches.length){const{clientX:t,clientY:n}=e.touches[0];return{x:t,y:n}}else if(e.changedTouches&&e.changedTouches.length){const{clientX:t,clientY:n}=e.changedTouches[0];return{x:t,y:n}}}return To(e)?{x:e.clientX,y:e.clientY}:null}const Ye=Object.freeze({Translate:{toString(e){if(!e)return;const{x:t,y:n}=e;return"translate3d("+(t?Math.round(t):0)+"px, "+(n?Math.round(n):0)+"px, 0)"}},Scale:{toString(e){if(!e)return;const{scaleX:t,scaleY:n}=e;return"scaleX("+t+") scaleY("+n+")"}},Transform:{toString(e){if(e)return[Ye.Translate.toString(e),Ye.Scale.toString(e)].join(" ")}},Transition:{toString(e){let{property:t,duration:n,easing:s}=e;return t+" "+n+"ms "+s}}}),Rn="a,frame,iframe,input:not([type=hidden]):not(:disabled),select:not(:disabled),textarea:not(:disabled),button:not(:disabled),*[tabindex]";function Ro(e){return e.matches(Rn)?e:e.querySelector(Rn)}const Po={display:"none"};function Oo(e){let{id:t,value:n}=e;return f.createElement("div",{id:t,style:Po},n)}function Lo(e){let{id:t,announcement:n,ariaLiveType:s="assertive"}=e;const o={position:"fixed",top:0,left:0,width:1,height:1,margin:-1,border:0,padding:0,overflow:"hidden",clip:"rect(0 0 0 0)",clipPath:"inset(100%)",whiteSpace:"nowrap"};return f.createElement("div",{id:t,style:o,role:"status","aria-live":s,"aria-atomic":!0},n)}function $o(){const[e,t]=f.useState("");return{announce:f.useCallback(s=>{s!=null&&t(s)},[]),announcement:e}}const ls=f.createContext(null);function Fo(e){const t=f.useContext(ls);f.useEffect(()=>{if(!t)throw new Error("useDndMonitor must be used within a children of <DndContext>");return t(e)},[e,t])}function zo(){const[e]=f.useState(()=>new Set),t=f.useCallback(s=>(e.add(s),()=>e.delete(s)),[e]);return[f.useCallback(s=>{let{type:o,event:r}=s;e.forEach(a=>{var c;return(c=a[o])==null?void 0:c.call(a,r)})},[e]),t]}const Ho={draggable:`
2
2
  To pick up a draggable item, press the space bar.
3
3
  While dragging, use the arrow keys to move the item.
4
4
  Press space again to drop the item in its new position, or press escape to cancel.
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("react/jsx-runtime"),i=require("./builder-DT2MPQIe.cjs"),m=require("./ticket-C_4dunoG.cjs"),o=require("react"),D=require("./charge-Dd6podcM.cjs"),_=require("./ui-components-CoVj1ReR.cjs"),e=require("@phosphor-icons/react"),Q=({children:r,shopDomain:d,shopId:h,shopPassword:g,shopLogo:I})=>{const{setShopDomain:x,setShopId:P,setShopPassword:y,setShopTerms:p,setShopPrivacyPolicy:l,setShopRefundPolicy:f,setShopLogo:A}=i.useStorefrontStore();return o.useLayoutEffect(()=>{const s=async()=>{const{data:u}=await D.fetchTerms();p(u)},C=async()=>{const{data:u}=await D.fetchPrivacyPolicy();l(u)},w=async()=>{const{data:u}=await D.fetchRefundPolicy();f(u)};x(d),P(h),g&&y(g),I&&A(I),s(),C(),w()},[d,h,g]),t.jsx(t.Fragment,{children:r})},X="_wrapper_1xuz3_18",L={wrapper:X};function J(){_.registerIcons({X:e.XIcon,Plus:e.PlusIcon,Minus:e.MinusIcon,Check:e.CheckIcon,Clock:e.ClockIcon,Info:e.InfoIcon,Copy:e.CopyIcon,Trash:e.TrashIcon,Sliders:e.SlidersIcon,Image:e.ImageIcon,List:e.ListIcon,Handbag:e.HandbagIcon,Bag:e.BagIcon,Eye:e.EyeIcon,Crown:e.CrownIcon,ArrowUp:e.ArrowUpIcon,ArrowDown:e.ArrowDownIcon,Confetti:e.ConfettiIcon,ArrowLeft:e.ArrowLeftIcon,ArrowRight:e.ArrowRightIcon,ArrowLineUpRight:e.ArrowLineUpRightIcon,ArrowUpRight:e.ArrowUpRightIcon,ArrowUUpLeft:e.ArrowUUpLeftIcon,ArrowUUpRight:e.ArrowUUpRightIcon,CaretRight:e.CaretRightIcon,CaretDown:e.CaretDownIcon,CaretUp:e.CaretUpIcon,CaretLeft:e.CaretLeftIcon,MagnifyingGlass:e.MagnifyingGlassIcon,MagnifyingGlassMinus:e.MagnifyingGlassMinusIcon,ArrowLineDown:e.ArrowLineDownIcon,Selection:e.SelectionIcon,CloudArrowUpIcon:e.CloudArrowUpIcon,ArrowsHorizontal:e.ArrowsHorizontalIcon,ArrowsVertical:e.ArrowsVerticalIcon,CheckCircle:e.CheckCircleIcon,XCircle:e.XCircleIcon,Star:e.StarIcon,Fire:e.FireIcon,Lightning:e.LightningIcon,AlignCenterHorizontal:e.AlignCenterHorizontalIcon,File:e.FileIcon,FileText:e.FileTextIcon,BookOpen:e.BookOpenIcon,DownloadSimple:e.DownloadSimpleIcon,DiscordLogo:e.DiscordLogoIcon,TelegramLogo:e.TelegramLogoIcon,SignOut:e.SignOutIcon,Wallet:e.WalletIcon,PaperPlaneRight:e.PaperPlaneRightIcon,ChatsTeardrop:e.ChatsTeardropIcon,DotsSixVertical:e.DotsSixVerticalIcon,Share:e.ShareIcon,Shield:e.ShieldIcon,ShieldCheck:e.ShieldCheckIcon,FileCloud:e.FileCloudIcon,Lock:e.LockIcon,Heart:e.HeartIcon,User:e.UserIcon,Calendar:e.CalendarIcon,Smiley:e.SmileyIcon,Globe:e.GlobeIcon,House:e.HouseIcon,HouseSimple:e.HouseSimpleIcon,CurrencyCircleDollar:e.CurrencyCircleDollarIcon,Medal:e.MedalIcon,CalendarCheck:e.CalendarCheckIcon,Question:e.QuestionIcon,Warning:e.WarningIcon,WarningDiamond:e.WarningDiamondIcon,TreeStructure:e.TreeStructureIcon,Palette:e.PaletteIcon,Gear:e.GearIcon,PaintBrushBroad:e.PaintBrushBroadIcon,TextAa:e.TextAaIcon,TextB:e.TextBIcon,TextH:e.TextHIcon,CornersOut:e.CornersOutIcon,ArrowSquareIn:e.ArrowSquareInIcon,Textbox:e.TextboxIcon,SquaresFour:e.SquaresFourIcon,SealQuestion:e.SealQuestionIcon,ChatCentered:e.ChatCenteredIcon,Ticket:e.TicketIcon,UserCircleGear:e.UserCircleGearIcon,Desktop:e.DesktopIcon,DeviceTabletCamera:e.DeviceTabletCameraIcon,DeviceMobileCamera:e.DeviceMobileCameraIcon,Cards:e.CardsIcon,PushPin:e.PushPinIcon,TextAlignLeft:e.TextAlignLeftIcon,TextAlignRight:e.TextAlignRightIcon,TextAlignCenter:e.TextAlignCenterIcon,AlignLeft:e.AlignLeftIcon,AlignRight:e.AlignRightIcon,AlignTop:e.AlignTopIcon,AlignBottom:e.AlignBottomIcon,TextItalic:e.TextItalicIcon,TextStrikethrough:e.TextStrikethroughIcon,TextUnderline:e.TextUnderlineIcon})}const $=o.lazy(()=>Promise.resolve().then(()=>require("./builder-DT2MPQIe.cjs")).then(r=>r.index).then(r=>({default:r.BuilderPage}))),K=o.lazy(()=>Promise.resolve().then(()=>require("./index-BBmLGlCP.cjs")).then(r=>({default:r.ErrorPage}))),Y=o.lazy(()=>Promise.resolve().then(()=>require("./index-ljnGesWX.cjs")).then(r=>({default:r.ActivePage}))),Z=o.lazy(()=>Promise.resolve().then(()=>require("./validation-BFKCs4Vw.cjs")).then(r=>({default:r.ValidationPage}))),ee=o.lazy(()=>Promise.resolve().then(()=>require("./index-DH3suBKA.cjs")).then(r=>({default:r.WrapperPage}))),te=o.lazy(()=>Promise.resolve().then(()=>require("./index-WlsBw3sd.cjs")).then(r=>({default:r.RouterErrorPage}))),c=o.lazy(()=>Promise.resolve().then(()=>require("./index-DrlEFa_A.cjs")).then(r=>({default:r.DynamicErrorPage}))),re=o.lazy(()=>Promise.resolve().then(()=>require("./checkout-hG4nZAfL.cjs")).then(r=>({default:r.Checkout}))),oe=o.lazy(()=>Promise.resolve().then(()=>require("./charge-Dd6podcM.cjs")).then(r=>r.index$1).then(r=>({default:r.ChargePage}))),ne=o.lazy(()=>Promise.resolve().then(()=>require("./ticket-C_4dunoG.cjs")).then(r=>r.index).then(r=>({default:r.TicketItem}))),se=o.lazy(()=>Promise.resolve().then(()=>require("./subscription-DuQaeZpz.cjs")).then(r=>r.index).then(r=>({default:r.Subscription}))),ce=o.lazy(()=>Promise.resolve().then(()=>require("./top-up-xnDj358Z.cjs")).then(r=>({default:r.TopUpBalance}))),ie=o.lazy(()=>Promise.resolve().then(()=>require("./order-f8DTpqHu.cjs")).then(r=>r.index).then(r=>({default:r.OrderPage}))),ae=o.lazy(()=>Promise.resolve().then(()=>require("./index-BGWhMhIz.cjs")).then(r=>({default:r.TermsPage}))),le=o.lazy(()=>Promise.resolve().then(()=>require("./charge-Dd6podcM.cjs")).then(r=>r.index).then(r=>({default:r.CustomerDashboard}))),U=o.lazy(()=>Promise.resolve().then(()=>require("./charge-Dd6podcM.cjs")).then(r=>r.recapcha).then(r=>({default:r.ReCaptchaProvider}))),ue=()=>null,n=({children:r})=>t.jsx(o.Suspense,{fallback:t.jsx(ue,{}),children:r}),B=o.lazy(()=>Promise.resolve().then(()=>require("./builder-components-HQ8ccfQi.cjs")).then(r=>r.index).then(r=>({default:r.RenderAnnouncement}))),R=o.lazy(()=>Promise.resolve().then(()=>require("./builder-components-HQ8ccfQi.cjs")).then(r=>r.index).then(r=>({default:r.RenderFooter}))),b=o.lazy(()=>Promise.resolve().then(()=>require("./builder-components-HQ8ccfQi.cjs")).then(r=>r.index).then(r=>({default:r.RenderHeader}))),de=r=>{var E;const{blocks:d,settings:h,header:g,footer:I,announcement:x,routes:P=[],shopLogo:y,apiURLs:p,isAntistock:l=!1}=r,[f,A]=o.useState(null),{general:s,setIsAntistock:C}=i.useGeneralStore(),{setApiUrls:w}=i.useApiStore(),u=((E=s==null?void 0:s.info)==null?void 0:E.customerAccountSettings)??"OPTIONAL",z=u==="DISABLED",{setBlocks:H,setSourceBlocks:F,setHeader:O,setFooter:M,setAnnouncement:G,setSettings:W}=i.useBlocksStore(),{themeSettings:S}=i.useThemeSettingsStore(),{settings:T,setSettings:V}=i.useSettingsStore(),k=i.IS_LOCAL_HOST?localStorage.getItem("fakeDomain")||"":window.location.hostname,N=localStorage.getItem("shopPassword"),q=localStorage.getItem("shopId")||"";return o.useEffect(()=>{if(C(l),l){const a=document.documentElement;getComputedStyle(a).getPropertyValue("--brand-color").trim()==="#ff3f19"&&a.style.setProperty("--brand-color","#a13dff")}},[l,C]),o.useEffect(()=>{!q&&(s!=null&&s.info.id)&&localStorage.setItem("shopId",s==null?void 0:s.info.id)},[s]),o.useEffect(()=>{!k&&!l&&localStorage.setItem("fakeDomain","drafts-ca18cf24-6659-4015-b1ab-9ebe9fa64e74.bgng.io")},[k]),o.useEffect(()=>{if(S&&T){const a=m.generateDynamicStyles(S,T);m.loadCustomFonts(),m.setupDynamicFonts(S),m.injectStylesToDOM(a)}},[S,JSON.stringify(T),window.location.hostname]),o.useEffect(()=>{const j=new h().blockSettings;V(j)},[]),o.useEffect(()=>{J()},[]),o.useLayoutEffect(()=>{const a={};Object.keys(d).map(v=>{a[v]=d[v]}),F(a),H(a),O(g),M(I),G(x),W(h),p&&w(p);const j=i.createBrowserRouter([{element:t.jsx(Q,{shopDomain:k,shopId:q,shopPassword:N||void 0,shopLogo:y,children:t.jsx(U,{children:t.jsx(ee,{children:t.jsx(i.Outlet,{})})})}),errorElement:t.jsx(n,{children:t.jsx(te,{})}),children:[{path:"/admin/builder/*",element:t.jsx(n,{children:t.jsx(Y,{children:t.jsx($,{blocks:d,settings:h,header:g,footer:I,announcement:x})})}),errorElement:t.jsx(n,{children:t.jsx(K,{})})},...P,{path:"/checkout",element:t.jsx(n,{children:t.jsx(re,{})}),errorElement:t.jsx(n,{children:t.jsx(c,{})}),loader:()=>(document.title="Checkout",!0)},{path:"/top-up",element:t.jsx(n,{children:t.jsx(ce,{})}),errorElement:t.jsx(n,{children:t.jsx(c,{})}),loader:()=>(document.title="Top Up Balance",!0)},{path:"/charges/:id",element:t.jsx(n,{children:t.jsx(oe,{})}),errorElement:t.jsx(n,{children:t.jsx(c,{})}),loader:()=>(document.title="Charges",!0)},{path:"/orders/:id/:accessToken?",element:t.jsx(n,{children:t.jsx(ie,{})}),errorElement:t.jsx(n,{children:t.jsx(c,{})}),loader:()=>(document.title="Orders",!0)},{path:"/subscriptions/:id/:accessToken?",element:t.jsx(n,{children:t.jsx(se,{})}),errorElement:t.jsx(n,{children:t.jsx(c,{})}),loader:()=>(document.title="Subscriptions",!0)},...z?[]:[{path:l?"/account":"/customer-dash",element:t.jsx(n,{children:t.jsxs("div",{className:L.wrapper,children:[t.jsx(B,{}),t.jsx(b,{}),t.jsx("div",{style:{flex:"1 1 auto"},children:t.jsx(le,{})}),t.jsx(R,{})]})}),errorElement:t.jsx(n,{children:t.jsx(c,{})}),loader:()=>(document.title=l?"Account":"Customer Dashboard",!0)}],{path:"/validation",element:t.jsx(n,{children:t.jsx(Z,{})}),errorElement:t.jsx(n,{children:t.jsx(c,{})}),loader:()=>(document.title="Validation",!0)},{path:"/ticket/:id/:accessToken",element:t.jsx(n,{children:t.jsxs("div",{className:L.wrapper,children:[t.jsx(b,{}),t.jsx("div",{style:{flex:1,width:"100%",height:"100%"},children:t.jsx(U,{children:t.jsx(ne,{})})}),t.jsx(R,{})]})}),errorElement:t.jsx(n,{children:t.jsx(c,{})}),loader:()=>(document.title="Ticket",!0)},{path:"/terms",element:t.jsx(n,{children:t.jsxs("div",{className:L.wrapper,children:[t.jsx(B,{}),t.jsx(b,{}),t.jsx("div",{style:{flex:1,width:"100%"},children:t.jsx(ae,{})}),t.jsx(R,{})]})}),errorElement:t.jsx(n,{children:t.jsx(c,{})}),loader:()=>(document.title="Terms of Service",!0)},{path:"*",element:t.jsx(m.DynamicRouteWrapper,{}),errorElement:t.jsx(n,{children:t.jsx(c,{})})}]}]);A(j)},[s,u]),t.jsx(o.Suspense,{fallback:null,children:f&&t.jsx(i.RouterProvider,{router:f})})};exports.App=de;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("react/jsx-runtime"),i=require("./builder-DajwWRB4.cjs"),m=require("./ticket-D-hMXIqO.cjs"),o=require("react"),D=require("./charge-BOfQrkLv.cjs"),_=require("./ui-components-cdIfqSzy.cjs"),e=require("@phosphor-icons/react"),Q=({children:r,shopDomain:d,shopId:h,shopPassword:g,shopLogo:I})=>{const{setShopDomain:x,setShopId:P,setShopPassword:y,setShopTerms:p,setShopPrivacyPolicy:l,setShopRefundPolicy:f,setShopLogo:A}=i.useStorefrontStore();return o.useLayoutEffect(()=>{const s=async()=>{const{data:u}=await D.fetchTerms();p(u)},C=async()=>{const{data:u}=await D.fetchPrivacyPolicy();l(u)},w=async()=>{const{data:u}=await D.fetchRefundPolicy();f(u)};x(d),P(h),g&&y(g),I&&A(I),s(),C(),w()},[d,h,g]),t.jsx(t.Fragment,{children:r})},X="_wrapper_1xuz3_18",L={wrapper:X};function J(){_.registerIcons({X:e.XIcon,Plus:e.PlusIcon,Minus:e.MinusIcon,Check:e.CheckIcon,Clock:e.ClockIcon,Info:e.InfoIcon,Copy:e.CopyIcon,Trash:e.TrashIcon,Sliders:e.SlidersIcon,Image:e.ImageIcon,List:e.ListIcon,Handbag:e.HandbagIcon,Bag:e.BagIcon,Eye:e.EyeIcon,Crown:e.CrownIcon,ArrowUp:e.ArrowUpIcon,ArrowDown:e.ArrowDownIcon,Confetti:e.ConfettiIcon,ArrowLeft:e.ArrowLeftIcon,ArrowRight:e.ArrowRightIcon,ArrowLineUpRight:e.ArrowLineUpRightIcon,ArrowUpRight:e.ArrowUpRightIcon,ArrowUUpLeft:e.ArrowUUpLeftIcon,ArrowUUpRight:e.ArrowUUpRightIcon,CaretRight:e.CaretRightIcon,CaretDown:e.CaretDownIcon,CaretUp:e.CaretUpIcon,CaretLeft:e.CaretLeftIcon,MagnifyingGlass:e.MagnifyingGlassIcon,MagnifyingGlassMinus:e.MagnifyingGlassMinusIcon,ArrowLineDown:e.ArrowLineDownIcon,Selection:e.SelectionIcon,CloudArrowUpIcon:e.CloudArrowUpIcon,ArrowsHorizontal:e.ArrowsHorizontalIcon,ArrowsVertical:e.ArrowsVerticalIcon,CheckCircle:e.CheckCircleIcon,XCircle:e.XCircleIcon,Star:e.StarIcon,Fire:e.FireIcon,Lightning:e.LightningIcon,AlignCenterHorizontal:e.AlignCenterHorizontalIcon,File:e.FileIcon,FileText:e.FileTextIcon,BookOpen:e.BookOpenIcon,DownloadSimple:e.DownloadSimpleIcon,DiscordLogo:e.DiscordLogoIcon,TelegramLogo:e.TelegramLogoIcon,SignOut:e.SignOutIcon,Wallet:e.WalletIcon,PaperPlaneRight:e.PaperPlaneRightIcon,ChatsTeardrop:e.ChatsTeardropIcon,DotsSixVertical:e.DotsSixVerticalIcon,Share:e.ShareIcon,Shield:e.ShieldIcon,ShieldCheck:e.ShieldCheckIcon,FileCloud:e.FileCloudIcon,Lock:e.LockIcon,Heart:e.HeartIcon,User:e.UserIcon,Calendar:e.CalendarIcon,Smiley:e.SmileyIcon,Globe:e.GlobeIcon,House:e.HouseIcon,HouseSimple:e.HouseSimpleIcon,CurrencyCircleDollar:e.CurrencyCircleDollarIcon,Medal:e.MedalIcon,CalendarCheck:e.CalendarCheckIcon,Question:e.QuestionIcon,Warning:e.WarningIcon,WarningDiamond:e.WarningDiamondIcon,TreeStructure:e.TreeStructureIcon,Palette:e.PaletteIcon,Gear:e.GearIcon,PaintBrushBroad:e.PaintBrushBroadIcon,TextAa:e.TextAaIcon,TextB:e.TextBIcon,TextH:e.TextHIcon,CornersOut:e.CornersOutIcon,ArrowSquareIn:e.ArrowSquareInIcon,Textbox:e.TextboxIcon,SquaresFour:e.SquaresFourIcon,SealQuestion:e.SealQuestionIcon,ChatCentered:e.ChatCenteredIcon,Ticket:e.TicketIcon,UserCircleGear:e.UserCircleGearIcon,Desktop:e.DesktopIcon,DeviceTabletCamera:e.DeviceTabletCameraIcon,DeviceMobileCamera:e.DeviceMobileCameraIcon,Cards:e.CardsIcon,PushPin:e.PushPinIcon,TextAlignLeft:e.TextAlignLeftIcon,TextAlignRight:e.TextAlignRightIcon,TextAlignCenter:e.TextAlignCenterIcon,AlignLeft:e.AlignLeftIcon,AlignRight:e.AlignRightIcon,AlignTop:e.AlignTopIcon,AlignBottom:e.AlignBottomIcon,TextItalic:e.TextItalicIcon,TextStrikethrough:e.TextStrikethroughIcon,TextUnderline:e.TextUnderlineIcon})}const $=o.lazy(()=>Promise.resolve().then(()=>require("./builder-DajwWRB4.cjs")).then(r=>r.index).then(r=>({default:r.BuilderPage}))),K=o.lazy(()=>Promise.resolve().then(()=>require("./index-B7-PVkQx.cjs")).then(r=>({default:r.ErrorPage}))),Y=o.lazy(()=>Promise.resolve().then(()=>require("./index-DXzoPSoa.cjs")).then(r=>({default:r.ActivePage}))),Z=o.lazy(()=>Promise.resolve().then(()=>require("./validation-CGW91G0m.cjs")).then(r=>({default:r.ValidationPage}))),ee=o.lazy(()=>Promise.resolve().then(()=>require("./index-DCaryi7j.cjs")).then(r=>({default:r.WrapperPage}))),te=o.lazy(()=>Promise.resolve().then(()=>require("./index-WT_hm-vy.cjs")).then(r=>({default:r.RouterErrorPage}))),c=o.lazy(()=>Promise.resolve().then(()=>require("./index-B1ymclv0.cjs")).then(r=>({default:r.DynamicErrorPage}))),re=o.lazy(()=>Promise.resolve().then(()=>require("./checkout-B1l5LksI.cjs")).then(r=>({default:r.Checkout}))),oe=o.lazy(()=>Promise.resolve().then(()=>require("./charge-BOfQrkLv.cjs")).then(r=>r.index$1).then(r=>({default:r.ChargePage}))),ne=o.lazy(()=>Promise.resolve().then(()=>require("./ticket-D-hMXIqO.cjs")).then(r=>r.index).then(r=>({default:r.TicketItem}))),se=o.lazy(()=>Promise.resolve().then(()=>require("./subscription-BU1AfEvj.cjs")).then(r=>r.index).then(r=>({default:r.Subscription}))),ce=o.lazy(()=>Promise.resolve().then(()=>require("./top-up-C3qZGkbN.cjs")).then(r=>({default:r.TopUpBalance}))),ie=o.lazy(()=>Promise.resolve().then(()=>require("./order-DUfIq98T.cjs")).then(r=>r.index).then(r=>({default:r.OrderPage}))),ae=o.lazy(()=>Promise.resolve().then(()=>require("./index-C65UzOoU.cjs")).then(r=>({default:r.TermsPage}))),le=o.lazy(()=>Promise.resolve().then(()=>require("./charge-BOfQrkLv.cjs")).then(r=>r.index).then(r=>({default:r.CustomerDashboard}))),U=o.lazy(()=>Promise.resolve().then(()=>require("./charge-BOfQrkLv.cjs")).then(r=>r.recapcha).then(r=>({default:r.ReCaptchaProvider}))),ue=()=>null,n=({children:r})=>t.jsx(o.Suspense,{fallback:t.jsx(ue,{}),children:r}),B=o.lazy(()=>Promise.resolve().then(()=>require("./builder-components-Cy-VmxAd.cjs")).then(r=>r.index).then(r=>({default:r.RenderAnnouncement}))),R=o.lazy(()=>Promise.resolve().then(()=>require("./builder-components-Cy-VmxAd.cjs")).then(r=>r.index).then(r=>({default:r.RenderFooter}))),b=o.lazy(()=>Promise.resolve().then(()=>require("./builder-components-Cy-VmxAd.cjs")).then(r=>r.index).then(r=>({default:r.RenderHeader}))),de=r=>{var E;const{blocks:d,settings:h,header:g,footer:I,announcement:x,routes:P=[],shopLogo:y,apiURLs:p,isAntistock:l=!1}=r,[f,A]=o.useState(null),{general:s,setIsAntistock:C}=i.useGeneralStore(),{setApiUrls:w}=i.useApiStore(),u=((E=s==null?void 0:s.info)==null?void 0:E.customerAccountSettings)??"OPTIONAL",z=u==="DISABLED",{setBlocks:H,setSourceBlocks:F,setHeader:O,setFooter:M,setAnnouncement:G,setSettings:W}=i.useBlocksStore(),{themeSettings:S}=i.useThemeSettingsStore(),{settings:T,setSettings:V}=i.useSettingsStore(),k=i.IS_LOCAL_HOST?localStorage.getItem("fakeDomain")||"":window.location.hostname,N=localStorage.getItem("shopPassword"),q=localStorage.getItem("shopId")||"";return o.useEffect(()=>{if(C(l),l){const a=document.documentElement;getComputedStyle(a).getPropertyValue("--brand-color").trim()==="#ff3f19"&&a.style.setProperty("--brand-color","#a13dff")}},[l,C]),o.useEffect(()=>{!q&&(s!=null&&s.info.id)&&localStorage.setItem("shopId",s==null?void 0:s.info.id)},[s]),o.useEffect(()=>{!k&&!l&&localStorage.setItem("fakeDomain","drafts-ca18cf24-6659-4015-b1ab-9ebe9fa64e74.bgng.io")},[k]),o.useEffect(()=>{if(S&&T){const a=m.generateDynamicStyles(S,T);m.loadCustomFonts(),m.setupDynamicFonts(S),m.injectStylesToDOM(a)}},[S,JSON.stringify(T),window.location.hostname]),o.useEffect(()=>{const j=new h().blockSettings;V(j)},[]),o.useEffect(()=>{J()},[]),o.useLayoutEffect(()=>{const a={};Object.keys(d).map(v=>{a[v]=d[v]}),F(a),H(a),O(g),M(I),G(x),W(h),p&&w(p);const j=i.createBrowserRouter([{element:t.jsx(Q,{shopDomain:k,shopId:q,shopPassword:N||void 0,shopLogo:y,children:t.jsx(U,{children:t.jsx(ee,{children:t.jsx(i.Outlet,{})})})}),errorElement:t.jsx(n,{children:t.jsx(te,{})}),children:[{path:"/admin/builder/*",element:t.jsx(n,{children:t.jsx(Y,{children:t.jsx($,{blocks:d,settings:h,header:g,footer:I,announcement:x})})}),errorElement:t.jsx(n,{children:t.jsx(K,{})})},...P,{path:"/checkout",element:t.jsx(n,{children:t.jsx(re,{})}),errorElement:t.jsx(n,{children:t.jsx(c,{})}),loader:()=>(document.title="Checkout",!0)},{path:"/top-up",element:t.jsx(n,{children:t.jsx(ce,{})}),errorElement:t.jsx(n,{children:t.jsx(c,{})}),loader:()=>(document.title="Top Up Balance",!0)},{path:"/charges/:id",element:t.jsx(n,{children:t.jsx(oe,{})}),errorElement:t.jsx(n,{children:t.jsx(c,{})}),loader:()=>(document.title="Charges",!0)},{path:"/orders/:id/:accessToken?",element:t.jsx(n,{children:t.jsx(ie,{})}),errorElement:t.jsx(n,{children:t.jsx(c,{})}),loader:()=>(document.title="Orders",!0)},{path:"/subscriptions/:id/:accessToken?",element:t.jsx(n,{children:t.jsx(se,{})}),errorElement:t.jsx(n,{children:t.jsx(c,{})}),loader:()=>(document.title="Subscriptions",!0)},...z?[]:[{path:l?"/account":"/customer-dash",element:t.jsx(n,{children:t.jsxs("div",{className:L.wrapper,children:[t.jsx(B,{}),t.jsx(b,{}),t.jsx("div",{style:{flex:"1 1 auto"},children:t.jsx(le,{})}),t.jsx(R,{})]})}),errorElement:t.jsx(n,{children:t.jsx(c,{})}),loader:()=>(document.title=l?"Account":"Customer Dashboard",!0)}],{path:"/validation",element:t.jsx(n,{children:t.jsx(Z,{})}),errorElement:t.jsx(n,{children:t.jsx(c,{})}),loader:()=>(document.title="Validation",!0)},{path:"/ticket/:id/:accessToken",element:t.jsx(n,{children:t.jsxs("div",{className:L.wrapper,children:[t.jsx(b,{}),t.jsx("div",{style:{flex:1,width:"100%",height:"100%"},children:t.jsx(U,{children:t.jsx(ne,{})})}),t.jsx(R,{})]})}),errorElement:t.jsx(n,{children:t.jsx(c,{})}),loader:()=>(document.title="Ticket",!0)},{path:"/terms",element:t.jsx(n,{children:t.jsxs("div",{className:L.wrapper,children:[t.jsx(B,{}),t.jsx(b,{}),t.jsx("div",{style:{flex:1,width:"100%"},children:t.jsx(ae,{})}),t.jsx(R,{})]})}),errorElement:t.jsx(n,{children:t.jsx(c,{})}),loader:()=>(document.title="Terms of Service",!0)},{path:"*",element:t.jsx(m.DynamicRouteWrapper,{}),errorElement:t.jsx(n,{children:t.jsx(c,{})})}]}]);A(j)},[s,u]),t.jsx(o.Suspense,{fallback:null,children:f&&t.jsx(i.RouterProvider,{router:f})})};exports.App=de;
@@ -1,9 +1,9 @@
1
1
  import { jsx as e, Fragment as j, jsxs as D } from "react/jsx-runtime";
2
- import { N as _, z as N, j as q, c as Q, m as X, a as J, M as $, aj as K, ak as Y, al as Z } from "./builder-2YNszRul.js";
3
- import { f as ee, l as te, j as oe, k as ne, D as re } from "./ticket-HPAqmPkQ.js";
2
+ import { N as _, z as N, j as q, c as Q, m as X, a as J, M as $, aj as K, ak as Y, al as Z } from "./builder-CQv65ONw.js";
3
+ import { f as ee, l as te, j as oe, k as ne, D as re } from "./ticket-UPvqJdN6.js";
4
4
  import o, { Suspense as ce } from "react";
5
- import { $ as ae, a0 as ie, a1 as le } from "./charge-CeL8jXzk.js";
6
- import { w as se } from "./ui-components-t7AROe_i.js";
5
+ import { $ as ae, a0 as ie, a1 as le } from "./charge-BIOFTYrp.js";
6
+ import { w as se } from "./ui-components-Bc8Z_6jF.js";
7
7
  import { TextUnderlineIcon as de, TextStrikethroughIcon as ue, TextItalicIcon as he, AlignBottomIcon as me, AlignTopIcon as pe, AlignRightIcon as Ie, AlignLeftIcon as ge, TextAlignCenterIcon as fe, TextAlignRightIcon as Ce, TextAlignLeftIcon as Se, PushPinIcon as ye, CardsIcon as Ae, DeviceMobileCameraIcon as we, DeviceTabletCameraIcon as Te, DesktopIcon as Pe, UserCircleGearIcon as ke, TicketIcon as De, ChatCenteredIcon as Le, SealQuestionIcon as Re, SquaresFourIcon as xe, TextboxIcon as be, ArrowSquareInIcon as Ee, CornersOutIcon as Be, TextHIcon as Ue, TextBIcon as ze, TextAaIcon as ve, PaintBrushBroadIcon as He, GearIcon as Fe, PaletteIcon as Oe, TreeStructureIcon as Me, WarningDiamondIcon as Ge, WarningIcon as We, QuestionIcon as Ve, CalendarCheckIcon as je, MedalIcon as _e, CurrencyCircleDollarIcon as Ne, HouseSimpleIcon as qe, HouseIcon as Qe, GlobeIcon as Xe, SmileyIcon as Je, CalendarIcon as $e, UserIcon as Ke, HeartIcon as Ye, LockIcon as Ze, FileCloudIcon as et, ShieldCheckIcon as tt, ShieldIcon as ot, ShareIcon as nt, DotsSixVerticalIcon as rt, ChatsTeardropIcon as ct, PaperPlaneRightIcon as at, WalletIcon as it, SignOutIcon as lt, TelegramLogoIcon as st, DiscordLogoIcon as dt, DownloadSimpleIcon as ut, BookOpenIcon as ht, FileTextIcon as mt, FileIcon as pt, AlignCenterHorizontalIcon as It, LightningIcon as gt, FireIcon as ft, StarIcon as Ct, XCircleIcon as St, CheckCircleIcon as yt, ArrowsVerticalIcon as At, ArrowsHorizontalIcon as wt, CloudArrowUpIcon as Tt, SelectionIcon as Pt, ArrowLineDownIcon as kt, MagnifyingGlassMinusIcon as Dt, MagnifyingGlassIcon as Lt, CaretLeftIcon as Rt, CaretUpIcon as xt, CaretDownIcon as bt, CaretRightIcon as Et, ArrowUUpRightIcon as Bt, ArrowUUpLeftIcon as Ut, ArrowUpRightIcon as zt, ArrowLineUpRightIcon as vt, ArrowRightIcon as Ht, ArrowLeftIcon as Ft, ConfettiIcon as Ot, ArrowDownIcon as Mt, ArrowUpIcon as Gt, CrownIcon as Wt, EyeIcon as Vt, BagIcon as jt, HandbagIcon as _t, ListIcon as Nt, ImageIcon as qt, SlidersIcon as Qt, TrashIcon as Xt, CopyIcon as Jt, InfoIcon as $t, ClockIcon as Kt, CheckIcon as Yt, MinusIcon as Zt, PlusIcon as eo, XIcon as to } from "@phosphor-icons/react";
8
8
  const oo = ({
9
9
  children: t,
@@ -154,47 +154,47 @@ function ro() {
154
154
  });
155
155
  }
156
156
  const co = o.lazy(
157
- () => import("./builder-2YNszRul.js").then((t) => t.ao).then((t) => ({ default: t.BuilderPage }))
157
+ () => import("./builder-CQv65ONw.js").then((t) => t.ao).then((t) => ({ default: t.BuilderPage }))
158
158
  ), ao = o.lazy(
159
- () => import("./index-m8mNLWAF.js").then((t) => ({ default: t.ErrorPage }))
159
+ () => import("./index-C3lnL6j6.js").then((t) => ({ default: t.ErrorPage }))
160
160
  ), io = o.lazy(
161
- () => import("./index-CPXgL1Te.js").then((t) => ({ default: t.ActivePage }))
161
+ () => import("./index-BhSh0O1l.js").then((t) => ({ default: t.ActivePage }))
162
162
  ), lo = o.lazy(
163
- () => import("./validation-BmbrCdXv.js").then((t) => ({ default: t.ValidationPage }))
163
+ () => import("./validation-B5t0eZSV.js").then((t) => ({ default: t.ValidationPage }))
164
164
  ), so = o.lazy(
165
- () => import("./index-DCCA87NY.js").then((t) => ({ default: t.WrapperPage }))
165
+ () => import("./index-Cm8S5Gki.js").then((t) => ({ default: t.WrapperPage }))
166
166
  ), uo = o.lazy(
167
- () => import("./index-DxY9GcmW.js").then((t) => ({ default: t.RouterErrorPage }))
167
+ () => import("./index-r6UXCC-e.js").then((t) => ({ default: t.RouterErrorPage }))
168
168
  ), c = o.lazy(
169
- () => import("./index-BsRq6_oH.js").then((t) => ({ default: t.DynamicErrorPage }))
169
+ () => import("./index-DPIhmGN5.js").then((t) => ({ default: t.DynamicErrorPage }))
170
170
  ), ho = o.lazy(
171
- () => import("./checkout-dKBgx4_t.js").then((t) => ({ default: t.Checkout }))
171
+ () => import("./checkout-g545jGLZ.js").then((t) => ({ default: t.Checkout }))
172
172
  ), mo = o.lazy(
173
- () => import("./charge-CeL8jXzk.js").then((t) => t.a9).then((t) => ({ default: t.ChargePage }))
173
+ () => import("./charge-BIOFTYrp.js").then((t) => t.a9).then((t) => ({ default: t.ChargePage }))
174
174
  ), po = o.lazy(
175
- () => import("./ticket-HPAqmPkQ.js").then((t) => t.m).then((t) => ({ default: t.TicketItem }))
175
+ () => import("./ticket-UPvqJdN6.js").then((t) => t.m).then((t) => ({ default: t.TicketItem }))
176
176
  ), Io = o.lazy(
177
- () => import("./subscription-B520eImG.js").then((t) => t.i).then((t) => ({ default: t.Subscription }))
177
+ () => import("./subscription-Cr4tlTfV.js").then((t) => t.i).then((t) => ({ default: t.Subscription }))
178
178
  ), go = o.lazy(
179
- () => import("./top-up-CE-L-n3m.js").then((t) => ({ default: t.TopUpBalance }))
179
+ () => import("./top-up-BG4dnsZh.js").then((t) => ({ default: t.TopUpBalance }))
180
180
  ), fo = o.lazy(
181
- () => import("./order-bjCcFmx6.js").then((t) => t.i).then((t) => ({ default: t.OrderPage }))
181
+ () => import("./order-CCmQ1de6.js").then((t) => t.i).then((t) => ({ default: t.OrderPage }))
182
182
  ), Co = o.lazy(
183
- () => import("./index-BcBa6BVj.js").then((t) => ({ default: t.TermsPage }))
183
+ () => import("./index-CidKvUav.js").then((t) => ({ default: t.TermsPage }))
184
184
  ), So = o.lazy(
185
- () => import("./charge-CeL8jXzk.js").then((t) => t.a8).then((t) => ({ default: t.CustomerDashboard }))
185
+ () => import("./charge-BIOFTYrp.js").then((t) => t.a8).then((t) => ({ default: t.CustomerDashboard }))
186
186
  ), B = o.lazy(
187
- () => import("./charge-CeL8jXzk.js").then((t) => t.a7).then((t) => ({ default: t.ReCaptchaProvider }))
187
+ () => import("./charge-BIOFTYrp.js").then((t) => t.a7).then((t) => ({ default: t.ReCaptchaProvider }))
188
188
  ), yo = () => null, n = ({ children: t }) => /* @__PURE__ */ e(ce, { fallback: /* @__PURE__ */ e(yo, {}), children: t }), U = o.lazy(
189
- () => import("./builder-components-CfB-cXOa.js").then((t) => t.i).then((t) => ({
189
+ () => import("./builder-components-BR6CyOIi.js").then((t) => t.i).then((t) => ({
190
190
  default: t.RenderAnnouncement
191
191
  }))
192
192
  ), R = o.lazy(
193
- () => import("./builder-components-CfB-cXOa.js").then((t) => t.i).then((t) => ({
193
+ () => import("./builder-components-BR6CyOIi.js").then((t) => t.i).then((t) => ({
194
194
  default: t.RenderFooter
195
195
  }))
196
196
  ), x = o.lazy(
197
- () => import("./builder-components-CfB-cXOa.js").then((t) => t.i).then((t) => ({
197
+ () => import("./builder-components-BR6CyOIi.js").then((t) => t.i).then((t) => ({
198
198
  default: t.RenderHeader
199
199
  }))
200
200
  ), xo = (t) => {
@@ -1,13 +1,13 @@
1
- import { j as Be, M as We, r as He, N as zt, O as qt, p as hn, f as J, Q as La, z as Re, U as Pt, V as dt, W as Ye, X as gr, e as vt, K as Je, Y as kt, v as we, b as x2, u as A2, a as ks, Z as I2, _ as _n, $ as xs, a0 as As, a1 as S2, a2 as N2, a3 as vu, a4 as Wi, a5 as v2, a6 as No, a7 as Fl, a8 as Is, a9 as Pa, aa as w2 } from "./builder-2YNszRul.js";
1
+ import { j as Be, M as We, r as He, N as zt, O as qt, p as hn, f as J, Q as La, z as Re, U as Pt, V as dt, W as Ye, X as gr, e as vt, K as Je, Y as kt, v as we, b as x2, u as A2, a as ks, Z as I2, _ as _n, $ as xs, a0 as As, a1 as S2, a2 as N2, a3 as vu, a4 as Wi, a5 as v2, a6 as No, a7 as Fl, a8 as Is, a9 as Pa, aa as w2 } from "./builder-CQv65ONw.js";
2
2
  import { jsx as o, jsxs as b, Fragment as ze } from "react/jsx-runtime";
3
3
  import * as be from "react";
4
4
  import $, { createElement as lt, isValidElement as D2, useEffect as yn, forwardRef as Bl, Component as L2, useState as Ce, useRef as Jn, useMemo as Kn } from "react";
5
- import { I as H, e as _t, f as Tn, g as ee, h as Ea, M as Ft, W as P2, i as Ss, j as Hl, k as Ul, l as Hu, m as ma, R as R2 } from "./ui-components-t7AROe_i.js";
6
- import { F as Vl } from "./builder-components-CfB-cXOa.js";
5
+ import { I as H, e as _t, f as Tn, g as ee, h as Ea, M as Ft, W as P2, i as Ss, j as Hl, k as Ul, l as Hu, m as ma, R as R2 } from "./ui-components-Bc8Z_6jF.js";
6
+ import { F as Vl } from "./builder-components-BR6CyOIi.js";
7
7
  import "react-dom";
8
- import { T as $l } from "./ticket-HPAqmPkQ.js";
9
- import { O as zl } from "./order-bjCcFmx6.js";
10
- import { S as M2 } from "./subscription-B520eImG.js";
8
+ import { T as $l } from "./ticket-UPvqJdN6.js";
9
+ import { O as zl } from "./order-CCmQ1de6.js";
10
+ import { S as M2 } from "./subscription-Cr4tlTfV.js";
11
11
  async function uR(e) {
12
12
  const t = Be.getState().apiUrls, n = We ? localStorage.getItem("fakeDomain") : window.location.hostname, r = `${t.storeApi}/shops/${n}/general` + (e ? `?password=${e}` : "");
13
13
  return (await He({
@@ -2743,7 +2743,9 @@ const Gl = ({ adaptiveStyles: e }) => {
2743
2743
  if (t.length === 0) return si;
2744
2744
  const n = e[0];
2745
2745
  if (!n) return si;
2746
- const r = t.find((s) => s.id === n.productId), u = r == null ? void 0 : r.variants.find((s) => s.id === n.productVariantId);
2746
+ const r = t.find((s) => s.id === n.productId), u = r == null ? void 0 : r.variants.find(
2747
+ (s) => s.id === n.productVariantId
2748
+ );
2747
2749
  if (!u) return si;
2748
2750
  const a = Ro(u);
2749
2751
  for (const s of e) {
@@ -2848,7 +2850,7 @@ const Gl = ({ adaptiveStyles: e }) => {
2848
2850
  return c(S), S;
2849
2851
  }, g = {
2850
2852
  reset() {
2851
- i({ ...cp });
2853
+ i({ ...cp }), c(null);
2852
2854
  },
2853
2855
  addProducts: (_) => {
2854
2856
  const y = _n.getState().products, C = _.filter(
@@ -2926,7 +2928,7 @@ const Gl = ({ adaptiveStyles: e }) => {
2926
2928
  e.coupon && !y && f(e.coupon);
2927
2929
  },
2928
2930
  setPaymentMethod(_) {
2929
- i((y) => ({ ...y, paymentMethod: _ }));
2931
+ i((y) => ({ ...y, paymentMethod: _, coupon: null })), c(null);
2930
2932
  },
2931
2933
  async submitCart(_) {
2932
2934
  l(!0);