@billgangcom/theme-lib 1.124.4 → 1.124.7

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 (44) hide show
  1. package/dist/{builder-NZcfw_uK.js → builder-BGSGUvbw.js} +5 -5
  2. package/dist/{builder-C0CY2NqW.cjs → builder-BoZFTb7G.cjs} +2 -2
  3. package/dist/{builder-components-Df75FZjk.cjs → builder-components-Ce-GvvbU.cjs} +2 -2
  4. package/dist/{builder-components-t8vV2Uyv.js → builder-components-uIH6kfbb.js} +12 -4
  5. package/dist/builder.cjs.js +1 -1
  6. package/dist/builder.es.js +23 -23
  7. package/dist/{charge-Dlt2N2gE.js → charge-BlJi0xCO.js} +3107 -3084
  8. package/dist/{charge-1NVtSa19.cjs → charge-w4kIp324.cjs} +33 -33
  9. package/dist/{checkout-DQQO7oVk.js → checkout-B32zo5ao.js} +5 -5
  10. package/dist/{checkout-B9xrJpzo.cjs → checkout-CtUeXuTx.cjs} +1 -1
  11. package/dist/exports.cjs.js +1 -1
  12. package/dist/exports.es.js +6 -6
  13. package/dist/{index-D8IUUs19.cjs → index-B3eXZddH.cjs} +1 -1
  14. package/dist/{index-C-R7NUm4.js → index-BNJDqT-0.js} +5 -5
  15. package/dist/{index-uoTQcf9e.cjs → index-BRdmeZZl.cjs} +1 -1
  16. package/dist/{index-Df1M0AqD.cjs → index-BTyOlaxG.cjs} +1 -1
  17. package/dist/{index-D5e4nxfb.js → index-BuxbXdLp.js} +5 -5
  18. package/dist/{index-DeVXhlDm.js → index-CoCTJ62P.js} +5 -5
  19. package/dist/{index-FcGMiqa9.js → index-DAKSB_F0.js} +2 -2
  20. package/dist/{index-BKO1t2iG.cjs → index-RtcNex9r.cjs} +1 -1
  21. package/dist/{index-DKixA0l5.cjs → index-SyO84kfM.cjs} +1 -1
  22. package/dist/{index-CVatcZ-w.js → index-TvJTXZf9.js} +1 -1
  23. package/dist/{index-BPf7tR5l.cjs → index-fnVhuwC_.cjs} +1 -1
  24. package/dist/{index-BlN9RDzk.js → index-z_-C0z77.js} +5 -5
  25. package/dist/index.cjs.js +1 -1
  26. package/dist/index.es.js +6 -6
  27. package/dist/{order-CtTYCM0e.cjs → order-Amk-Jg5s.cjs} +1 -1
  28. package/dist/{order-QenSr8PO.js → order-Nvdr1Xpq.js} +5 -5
  29. package/dist/src/assets/storefront-icons/index.d.ts +3 -0
  30. package/dist/src/storefront/components/PaymentMethod/model.d.ts +2 -1
  31. package/dist/src/storefront/models/payment.d.ts +2 -1
  32. package/dist/{subscription-tZMq2hbO.js → subscription-BtN0ZLhW.js} +5 -5
  33. package/dist/{subscription-i9Trr3Dj.cjs → subscription-Dke5SI7x.cjs} +1 -1
  34. package/dist/{ticket-B7_yQkrG.js → ticket-DR1de6DJ.js} +5 -5
  35. package/dist/{ticket-D5hDuE4u.cjs → ticket-DpkxSuxR.cjs} +1 -1
  36. package/dist/{top-up-D5nnzq3p.cjs → top-up-Cma1nW3z.cjs} +1 -1
  37. package/dist/{top-up-Cf5uGOet.js → top-up-D2COqVbe.js} +5 -5
  38. package/dist/{ui-components-DYyu32oT.js → ui-components-BQyCaYte.js} +4 -4
  39. package/dist/{ui-components-DTLctw1s.cjs → ui-components-CaI7HLsm.cjs} +1 -1
  40. package/dist/ui.cjs.js +1 -1
  41. package/dist/ui.es.js +1 -1
  42. package/dist/{validation-Bco9jXpi.js → validation-BBKKW104.js} +5 -5
  43. package/dist/{validation-BDFP1fbJ.cjs → validation-CYN2gbtD.cjs} +1 -1
  44. package/package.json +1 -1
@@ -2,10 +2,10 @@ import * as y from "react";
2
2
  import _e, { useRef as jr, useEffect as Ta } from "react";
3
3
  import * as Pa from "react-dom";
4
4
  import { jsx as M, jsxs as Le, Fragment as Oa } from "react/jsx-runtime";
5
- import { I as Wt, B as $r, a as Zn, C as Ma, b as Aa, L as Da } from "./ui-components-DYyu32oT.js";
6
- import "./charge-Dlt2N2gE.js";
7
- import { N as Fa, H as Ia, S as Ba, P as Ha, M as Ua } from "./builder-components-t8vV2Uyv.js";
8
- import "./ticket-B7_yQkrG.js";
5
+ import { I as Wt, B as $r, a as Zn, C as Ma, b as Aa, L as Da } from "./ui-components-BQyCaYte.js";
6
+ import "./charge-BlJi0xCO.js";
7
+ import { N as Fa, H as Ia, S as Ba, P as Ha, M as Ua } from "./builder-components-uIH6kfbb.js";
8
+ import "./ticket-DR1de6DJ.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-Dlt2N2gE.js").then((N) => N.a6);
5296
+ const _ = await import("./charge-BlJi0xCO.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"),je=require("./ui-components-DTLctw1s.cjs");require("./charge-1NVtSa19.cjs");const Ft=require("./builder-components-Df75FZjk.cjs");require("./ticket-D5hDuE4u.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 y=Mo(we),za=Mo($a);/**
1
+ "use strict";const we=require("react"),$a=require("react-dom"),k=require("react/jsx-runtime"),je=require("./ui-components-CaI7HLsm.cjs");require("./charge-w4kIp324.cjs");const Ft=require("./builder-components-Ce-GvvbU.cjs");require("./ticket-DpkxSuxR.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 y=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(i){const s=Ht(i);r[s]||(oc(o,i),r[s]=!0)}return E.isArray(t)?t.forEach(a):a(t),this}};De.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);E.reduceDescriptors(De.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(r){this[n]=r}}});E.freezeMethods(De);function tr(e,t){const n=this||tn,r=t||n,o=De.from(r.headers);let a=r.data;return E.forEach(e,function(s){a=s.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 ic(e,t){e=e||10;const n=new Array(e),r=new Array(e);let o=0,a=0,i;return t=t!==void 0?t:1e3,function(l){const c=Date.now(),u=r[a];i||(i=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-i<t)return;const w=u&&c-u;return w?Math.round(h*1e3/w):void 0}}function sc(e,t){let n=0,r=1e3/t,o,a;const i=(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?i(c,u):(o=c,a||(a=setTimeout(()=>{a=null,i(o)},r-d)))},()=>o&&i(o)]}const Pn=(e,t,n=3)=>{let r=0;const o=ic(50,250);return sc(a=>{const i=a.loaded,s=a.lengthComputable?a.total:void 0,l=i-r,c=o(l),u=i<=s;r=i;const d={loaded:i,total:s,progress:s?i/s:void 0,bytes:l,rate:c||void 0,estimated:c&&s&&u?(s-i)/c:void 0,event:a,lengthComputable:s!=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=Ne.hasStandardBrowserEnv?((e,t)=>n=>(n=new URL(n,Ne.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)))(new URL(Ne.origin),Ne.navigator&&/(msie|trident)/i.test(Ne.navigator.userAgent)):()=>!0,cc=Ne.hasStandardBrowserEnv?{write(e,t,n,r,o,a){const i=[e+"="+encodeURIComponent(t)];E.isNumber(n)&&i.push("expires="+new Date(n).toGMTString()),E.isString(r)&&i.push("path="+r),E.isString(o)&&i.push("domain="+o),a===!0&&i.push("secure"),document.cookie=i.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 De?{...e}:e;function St(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 i(c,u){if(E.isUndefined(u)){if(!E.isUndefined(c))return r(void 0,c)}else return r(void 0,u)}function s(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:i,transformRequest:i,transformResponse:i,paramsSerializer:i,timeout:i,timeoutMessage:i,withCredentials:i,withXSRFToken:i,adapter:i,responseType:i,xsrfCookieName:i,xsrfHeaderName:i,onUploadProgress:i,onDownloadProgress:i,decompress:i,maxContentLength:i,maxBodyLength:i,beforeRedirect:i,transport:i,httpAgent:i,httpsAgent:i,cancelToken:i,socketPath:i,responseEncoding:i,validateStatus:s,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!==s||(n[u]=h)}),n}const ya=e=>{const t=St({},e);let{data:n,withXSRFToken:r,xsrfHeaderName:o,xsrfCookieName:a,headers:i,auth:s}=t;t.headers=i=De.from(i),t.url=da(ga(t.baseURL,t.url),e.params,e.paramsSerializer),s&&i.set("Authorization","Basic "+btoa((s.username||"")+":"+(s.password?unescape(encodeURIComponent(s.password)):"")));let l;if(E.isFormData(n)){if(Ne.hasStandardBrowserEnv||Ne.hasStandardBrowserWebWorkerEnv)i.setContentType(void 0);else if((l=i.getContentType())!==!1){const[c,...u]=l?l.split(";").map(d=>d.trim()).filter(Boolean):[];i.setContentType([c||"multipart/form-data",...u].join("; "))}}if(Ne.hasStandardBrowserEnv&&(r&&E.isFunction(r)&&(r=r(t)),r||r!==!1&&lc(t.url))){const c=o&&a&&cc.read(a);c&&i.set(o,c)}return t},fc=typeof XMLHttpRequest<"u",hc=fc&&function(e){return new Promise(function(n,r){const o=ya(e);let a=o.data;const i=De.from(o.headers).normalize();let{responseType:s,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 v=new XMLHttpRequest;v.open(o.method.toUpperCase(),o.url,!0),v.timeout=o.timeout;function L(){if(!v)return;const R=De.from("getAllResponseHeaders"in v&&v.getAllResponseHeaders()),T={data:!s||s==="text"||s==="json"?v.responseText:v.response,status:v.status,statusText:v.statusText,headers:R,config:e,request:v};ma(function(S){n(S),p()},function(S){r(S),p()},T),v=null}"onloadend"in v?v.onloadend=L:v.onreadystatechange=function(){!v||v.readyState!==4||v.status===0&&!(v.responseURL&&v.responseURL.indexOf("file:")===0)||setTimeout(L)},v.onabort=function(){v&&(r(new $("Request aborted",$.ECONNABORTED,e,v)),v=null)},v.onerror=function(){r(new $("Network Error",$.ERR_NETWORK,e,v)),v=null},v.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,v)),v=null},a===void 0&&i.setContentType(null),"setRequestHeader"in v&&E.forEach(i.toJSON(),function(P,T){v.setRequestHeader(T,P)}),E.isUndefined(o.withCredentials)||(v.withCredentials=!!o.withCredentials),s&&s!=="json"&&(v.responseType=o.responseType),c&&([h,m]=Pn(c,!0),v.addEventListener("progress",h)),l&&v.upload&&([d,w]=Pn(l),v.upload.addEventListener("progress",d),v.upload.addEventListener("loadend",w)),(o.cancelToken||o.signal)&&(u=R=>{v&&(r(!R||R.type?new Ot(null,e,v):R),v.abort(),v=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&&Ne.protocols.indexOf(b)===-1){r(new $("Unsupported protocol "+b+":",$.ERR_BAD_REQUEST,e));return}v.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,s();const u=c instanceof Error?c:this.reason;r.abort(u instanceof $?u:new Ot(u instanceof Error?u.message:u))}};let i=t&&setTimeout(()=>{i=null,a(new $(`timeout ${t} of ms exceeded`,$.ETIMEDOUT))},t);const s=()=>{e&&(i&&clearTimeout(i),i=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(s),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 yc(e))yield*mc(n,t)},yc=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,i,s=l=>{i||(i=!0,r&&r(l))};return new ReadableStream({async pull(l){try{const{done:c,value:u}=await o.next();if(c){s(),l.close();return}let d=u.byteLength;if(n){let h=a+=d;n(h)}l.enqueue(new Uint8Array(u))}catch(c){throw s(c),c}},cancel(l){return s(l),o.return()}},{highWaterMark:2})},$n=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",va=$n&&typeof ReadableStream=="function",vc=$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=va&&wa(()=>{let e=!1;const t=new Request(Ne.origin,{body:new ReadableStream,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!t}),Lo=64*1024,mr=va&&wa(()=>E.isReadableStream(new Response("").body)),_n={stream:mr&&(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(Ne.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 vc(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:i,onDownloadProgress:s,onUploadProgress:l,responseType:c,headers:u,withCredentials:d="same-origin",fetchOptions:h}=ya(e);c=c?(c+"").toLowerCase():"text";let w=pc([o,a&&a.toAbortSignal()],i),m;const p=w&&w.unsubscribe&&(()=>{w.unsubscribe()});let v;try{if(l&&wc&&n!=="get"&&n!=="head"&&(v=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(v,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=mr&&(c==="stream"||c==="response");if(mr&&(s||R&&p)){const T={};["status","statusText","headers"].forEach(G=>{T[G]=b[G]});const H=E.toFiniteNumber(b.headers.get("content-length")),[S,_]=s&&bo(H,Pn(Co(s),!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:De.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)}}),gr={http:Il,xhr:hc,fetch:Cc};E.forEach(gr,(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 i;if(r=n,!Ec(n)&&(r=gr[(i=String(n)).toLowerCase()],r===void 0))throw new $(`Unknown adapter '${i}'`);if(r)break;o[i||"#"+a]=r}if(!r){const a=Object.entries(o).map(([s,l])=>`adapter ${s} `+(l===!1?"is not supported by the environment":"is not available in the build"));let i=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 "+i,"ERR_NOT_SUPPORT")}return r},adapters:gr};function nr(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Ot(null,e)}function ko(e){return nr(e),e.headers=De.from(e.headers),e.data=tr.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),Sa.getAdapter(e.adapter||tn.adapter)(e).then(function(r){return nr(e),r.data=tr.call(e,e.transformResponse,r),r.headers=De.from(r.headers),r},function(r){return pa(r)||(nr(e),r&&r.response&&(r.response.data=tr.call(e,e.transformResponse,r.response),r.response.headers=De.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,i){return"[Axios v"+ba+"] Transitional option '"+a+"'"+i+(r?". "+r:"")}return(a,i,s)=>{if(t===!1)throw new $(o(i," has been removed"+(n?" in "+n:"")),$.ERR_DEPRECATED);return n&&!No[i]&&(No[i]=!0,console.warn(o(i," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(a,i,s):!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],i=t[a];if(i){const s=e[a],l=s===void 0||i(s,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},Xe=xn.validators;let wt=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=St(this.defaults,n);const{transitional:r,paramsSerializer:o,headers:a}=n;r!==void 0&&xn.assertOptions(r,{silentJSONParsing:Xe.transitional(Xe.boolean),forcedJSONParsing:Xe.transitional(Xe.boolean),clarifyTimeoutError:Xe.transitional(Xe.boolean)},!1),o!=null&&(E.isFunction(o)?n.paramsSerializer={serialize:o}:xn.assertOptions(o,{encode:Xe.function,serialize:Xe.function},!0)),n.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?n.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:n.allowAbsoluteUrls=!0),xn.assertOptions(n,{baseUrl:Xe.spelling("baseURL"),withXsrfToken:Xe.spelling("withXSRFToken")},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let i=a&&E.merge(a.common,a[n.method]);a&&E.forEach(["delete","get","head","post","put","patch","common"],m=>{delete a[m]}),n.headers=De.concat(i,a);const s=[];let l=!0;this.interceptors.request.forEach(function(p){typeof p.runWhen=="function"&&p.runWhen(n)===!1||(l=l&&p.synchronous,s.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,s),m.push.apply(m,c),h=m.length,u=Promise.resolve(n);d<h;)u=u.then(m[d++],m[d++]);return u}h=s.length;let w=n;for(d=0;d<h;){const m=s[d++],p=s[d++];try{w=m(w)}catch(v){p.call(this,v);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=St(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){wt.prototype[t]=function(n,r){return this.request(St(r||{},{method:t,url:n,data:(r||{}).data}))}});E.forEach(["post","put","patch"],function(t){function n(r){return function(a,i,s){return this.request(St(s||{},{method:t,headers:r?{"Content-Type":"multipart/form-data"}:{},url:a,data:i}))}}wt.prototype[t]=n(),wt.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 i=new Promise(s=>{r.subscribe(s),a=s}).then(o);return i.cancel=function(){r.unsubscribe(a)},i},t(function(a,i,s){r.reason||(r.reason=new Ot(a,i,s),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 wt(e),n=ea(wt.prototype.request,t);return E.extend(n,wt.prototype,t,{allOwnKeys:!0}),E.extend(n,t,null,{allOwnKeys:!0}),n.create=function(o){return Ea(St(e,o))},n}const ce=Ea(tn);ce.Axios=wt;ce.CanceledError=Ot;ce.CancelToken=Lc;ce.isCancel=pa;ce.VERSION=ba;ce.toFormData=Vn;ce.AxiosError=$;ce.Cancel=ce.CanceledError;ce.all=function(t){return Promise.all(t)};ce.spread=Rc;ce.isAxiosError=kc;ce.mergeConfig=St;ce.AxiosHeaders=De;ce.formToJSON=e=>ha(E.isHTMLForm(e)?new FormData(e):e);ce.getAdapter=Sa.getAdapter;ce.HttpStatusCode=yr;ce.default=ce;const{Axios:af,AxiosError:Nc,CanceledError:sf,isCancel:lf,CancelToken:cf,VERSION:uf,all:df,Cancel:ff,isAxiosError:hf,spread:pf,toFormData:mf,AxiosHeaders:gf,HttpStatusCode:yf,formToJSON:vf,getAdapter:wf,mergeConfig:Sf}=ce,gn="https://localhost:5043",at=async e=>{var h,w;const{url:t,withToken:n,method:r,body:o,contentType:a,typeToken:i="seller"}=e,s=n?localStorage.getItem("sellerAccessToken"):null,l=n?localStorage.getItem("token"):null,c=i==="seller"?s: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 ce.get(u?gn:t,{headers:d});break;case"post":m=await ce.post(u?gn:t,o,{headers:d});break;case"put":m=await ce.put(u?gn:t,o,{headers:d});break;case"delete":m=await ce.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,v=(h=p.response)==null?void 0:h.data;let L="Something Went Wrong";v&&(L=v.errors[0]);const b=(w=p.response)==null?void 0:w.status;if(b===401)try{const P=await Promise.resolve().then(()=>require("./charge-1NVtSa19.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},Fc=(e,t="300")=>e==="not found"?"empty":`https://imagedelivery.net/${e}/w=${t}`,Ic=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]},vr=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)},rr="f10120ab-7ebb-4785-b240-7428edaa3c4e",Ut="https://t-api.billgang.com",Vt="https://internal-t-api.antistock.io",Wt="I",Vc=10*1e3,$c=15*1e3,zc=15*60*1e3,xa=()=>{var t;const e=vr(Wt);return((t=e==null?void 0:e.s)==null?void 0:t.i)||null},Jc=(e,t="production",n)=>{const{pathname:r}=We(),o=we.useRef(),a=we.useRef(document.visibilityState);we.useEffect(()=>{if(!e)return;const i=()=>Date.now(),s=async()=>(await at({url:`${n?Vt:Ut}/${e}/t/p`,method:"post",withToken:!1})).data.data.id,l=async m=>(await at({url:`${n?Vt:Ut}/${e}/t/p/${t==="development"?rr:m}/s`,method:"post",withToken:!1})).data.data.id,c=async(m,p,v,L)=>{const b=t==="development"?rr:m;try{return(await at({url:`${n?Vt:Ut}/${e}/t/p/${b}/s/${p}/e`,method:"post",withToken:!1,body:{url:v,oldEventId:L},contentType:"application/json"})).data.data.id}catch{return p=await l(m),(await at({url:`${n?Vt:Ut}/${e}/t/p/${b}/s/${p}/e`,method:"post",withToken:!1,body:{url:v},contentType:"application/json"})).data.data.id}},u=async(m,p,v)=>{await at({url:`${n?Vt:Ut}/${e}/t/p/${t==="development"?rr:m}/s/${p}/e/${v}/h`,method:"post",withToken:!1});const b=vr(Wt);b&&(b.s.u=i().toString(),b.lu=i().toString(),To(Wt,b))},d=(m,p,v)=>{o.current&&clearInterval(o.current),o.current=setInterval(async()=>{if(document.visibilityState==="visible")try{await u(m,p,v)}catch{await h()}},Vc)},h=async()=>{var L,b,R,P;const m=`${window.location.hostname}${r}`,p=vr(Wt),v=i();try{let T=p==null?void 0:p.p;T||(T=await s());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||v-S>zc;(!H||_)&&(H=await l(T));const G=Number((p==null?void 0:p.lu)||0),B=v-G>$c,ae=await c(T,H,m,p!=null&&p.l&&!B?p.l:void 0),ee={p:T,s:{i:H,c:((P=p==null?void 0:p.s)==null?void 0:P.c)??v.toString(),u:v.toString()},l:ae,lu:v.toString()};To(Wt,ee),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=se(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=se(e=>({page:1,setPage:t=>e(()=>({page:t})),resetPage:()=>e(()=>({page:1}))})),Gc=se(e=>({discordInfo:null,setDiscordInfo:t=>e(()=>({discordInfo:t}))})),Kc=se(e=>({subscription:null,setSubscription:t=>e({subscription:t})})),nn=se(e=>({apiUrls:Dc,setApiUrls:t=>e(()=>({apiUrls:t}))})),La=se(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}))})),Ar=se(e=>({general:null,setGeneral:t=>e(()=>({general:t})),isAntistock:!1,setIsAntistock:t=>e(()=>({isAntistock:t}))})),wr=se(e=>({settings:null,setSettings:t=>{e(()=>({settings:t}))},isLoadingSettings:!0,setIsLoadingSettings:t=>e(()=>({isLoadingSettings:t}))})),On=se((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 i=JSON.parse(JSON.stringify(t().themeSettings));_e.getState().addHistory({themeSettings:i});const s={...a.themeSettings.colors,[n]:{...a.themeSettings.colors[n],[r]:o}};return{themeSettings:{...a.themeSettings,colors:s}}}),updateFont:(n,r,o,a,i)=>e(s=>{const l=JSON.parse(JSON.stringify(t().themeSettings));_e.getState().addHistory({themeSettings:l});const c={...s.themeSettings.fonts,[n]:{...s.themeSettings.fonts[n],[r]:{...s.themeSettings.fonts[n][r],[o]:{...s.themeSettings.fonts[n][r][o],[a]:i}}}};return{themeSettings:{...s.themeSettings,fonts:c}}}),updateFontSizePercentage:(n,r)=>e(o=>{const a=JSON.parse(JSON.stringify(t().themeSettings));_e.getState().addHistory({themeSettings:a});const i={...o.themeSettings.fonts,[n]:{...o.themeSettings.fonts[n],fontSizePercentage:r}};return{themeSettings:{...o.themeSettings,fonts:i}}}),updateBorder:(n,r)=>e(o=>{const a=JSON.parse(JSON.stringify(t().themeSettings));_e.getState().addHistory({themeSettings:a});const i={...o.themeSettings.borders,[n]:r};return{themeSettings:{...o.themeSettings,borders:i}}}),updateButton:(n,r,o)=>e(a=>{const i=JSON.parse(JSON.stringify(t().themeSettings));_e.getState().addHistory({themeSettings:i});const s={...a.themeSettings.buttons[n],[r]:o},l={...a.themeSettings.buttons,[n]:s};return{themeSettings:{...a.themeSettings,buttons:l}}}),updateInput:(n,r,o)=>e(a=>{const i=JSON.parse(JSON.stringify(t().themeSettings));return _e.getState().addHistory({themeSettings:i}),{themeSettings:{...a.themeSettings,inputs:{...a.themeSettings.inputs,[n]:{...a.themeSettings.inputs[n],[o]:r}}}}}),isLoadingThemeSettings:!1,setIsLoadingThemeSettings:n=>e(()=>({isLoadingThemeSettings:n}))})),Fe=se(e=>({notifications:[],setNotifications:t=>e(()=>({notifications:t}))})),Yc=se(e=>({isOpen:!0,setIsOpen:t=>e(()=>({isOpen:t}))}));var ke=[];for(var or=0;or<256;++or)ke.push((or+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 yn,Qc=new Uint8Array(16);function eu(){if(!yn&&(yn=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!yn))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return yn(Qc)}var tu=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto);const _o={randomUUID:tu};function ot(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 i=l=>l===null?null:JSON.parse(l,void 0),s=(a=n.getItem(o))!=null?a:null;return s instanceof Promise?s.then(i):i(s)},setItem:(o,a)=>n.setItem(o,JSON.stringify(a,void 0)),removeItem:o=>n.removeItem(o)}}const Sr=e=>t=>{try{const n=e(t);return n instanceof Promise?n:{then(r){return Sr(r)(n)},catch(r){return this}}}catch(n){return{then(r){return this},catch(r){return Sr(r)(n)}}}},ru=(e,t)=>(n,r,o)=>{let a={storage:nu(()=>localStorage),partialize:p=>p,version:0,merge:(p,v)=>({...v,...p}),...t},i=!1;const s=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,v)=>{d(p,v),u()};const h=e((...p)=>{n(...p),u()},r,o);o.getInitialState=()=>h;let w;const m=()=>{var p,v;if(!c)return;i=!1,s.forEach(b=>{var R;return b((R=r())!=null?R:h)});const L=((v=a.onRehydrateStorage)==null?void 0:v.call(a,(p=r())!=null?p:h))||void 0;return Sr(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(),i=!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:()=>i,onHydrate:p=>(s.add(p),()=>{s.delete(p)}),onFinishHydration:p=>(l.add(p),()=>{l.delete(p)})},a.skipHydration||m(),w||h},Jn=ru,Yt=se(Jn((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=ot();if(r)r[o]=n,e({pages:r});else{const a=t().setPages;a({});const i=t().pages;i[o]=n,e({pages:i})}},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=se(e=>({isOpenModal:!1,setIsOpenModal:t=>e(()=>({isOpenModal:t}))})),Mn=se(Jn((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&&_e.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&&_e.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&&_e.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:i}=Yt.getState();if(!a||!i||!i[a]||!o[i[a].path]){console.error("Cannot set position: invalid page or block data");return}const s=i[a].path,l=o[s],c=n?l.order.indexOf(n):-1;if(c===-1&&n){console.error(`Block with ID "${n}" not found in page "${s}"`);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));_e.getState().addHistory({layers:o});const a={...t().blocks},i=a[n]||{data:{},order:[]},s=t().positionBlock,l=ot(),c={name:r.name,value:r.value};return i.data[l]=c,s===null||s>=i.order.length?i.order.push(l):i.order.splice(s,0,l),e({blocks:{...a,[n]:{data:i.data,order:i.order}},currentBlock:l,positionBlock:null}),Fe.getState().setNotifications([...Fe.getState().notifications,{id:ot(),message:"Block successfully added",status:"success"}]),l},editBlock:(n,r,o)=>{const a=JSON.parse(JSON.stringify(t().blocks));_e.getState().addHistory({layers:a});const i=t().blocks,s=i[n]||{};s.data[r]={name:o.name,value:{...o.value}},e({blocks:{...i,[n]:s}})},removeBlock:(n,r)=>{const o=JSON.parse(JSON.stringify(t().blocks));_e.getState().addHistory({layers:o});const a=JSON.parse(JSON.stringify(t().blocks)),i=a[n];if(!i){console.error(`Page at path "${n}" does not exist.`);return}delete i.data[r],i.order=i.order.filter(s=>s!==r),e({blocks:{...a,[n]:i}}),Fe.getState().setNotifications([...Fe.getState().notifications,{id:ot(),message:"Block successfully deleted",status:"success"}])},moveBlock:(n,r,o)=>e(a=>{const i=JSON.parse(JSON.stringify(t().blocks));if(_e.getState().addHistory({layers:i}),!a.blocks[n])return console.error(`Path ${n} does not exist in blocks`),a;const s={...a.blocks[n]},l=[...s.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),Fe.getState().setNotifications([...Fe.getState().notifications,{id:ot(),message:"Block successfully moved",status:"success"}]),{blocks:{...a.blocks,[n]:{...s,order:l}}}}),duplicateBlock:(n,r)=>{const o=JSON.parse(JSON.stringify(t().blocks));_e.getState().addHistory({layers:o});const a=JSON.parse(JSON.stringify(t().blocks)),i=a[n];if(!i||!i.data[r]){console.error(`Block with ID "${r}" not found in page "${n}"`);return}const s=ot(),l=i.data[r],c={name:l.name,value:JSON.parse(JSON.stringify({...l.value}))};i.data[s]={...c};const u=i.order.indexOf(r);if(u===-1){console.error(`Block ID "${r}" not found in order array`);return}i.order.splice(u+1,0,s),e({blocks:{...a,[n]:i},currentBlock:s}),Ra.getState().setActiveBlock({id:s,neededScroll:!0}),Fe.getState().setNotifications([...Fe.getState().notifications,{id:ot(),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}}})),_e=se((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:i,header:s,footer:l,announcement:c,setBlocks:u,setHeader:d,setFooter:h,setAnnouncement:w}=Mn.getState(),{themeSettings:m,setThemeSettings:p}=On.getState(),v={themeSettings:JSON.parse(JSON.stringify(m)),layers:JSON.parse(JSON.stringify(i)),header:JSON.parse(JSON.stringify(s)),footer:JSON.parse(JSON.stringify(l)),announcement:JSON.parse(JSON.stringify(c))};e({past:a,future:[v,...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:i,announcement:s,setBlocks:l,setHeader:c,setFooter:u,setAnnouncement:d}=Mn.getState(),{themeSettings:h,setThemeSettings:w}=On.getState(),m=r[0],p=r.slice(1),v={themeSettings:JSON.parse(JSON.stringify(h)),layers:JSON.parse(JSON.stringify(o)),header:JSON.parse(JSON.stringify(a)),footer:JSON.parse(JSON.stringify(i)),announcement:JSON.parse(JSON.stringify(s))};e({past:[...n,v],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=se(Jn(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"}],iu=[{icon:"PaintBrushBroad",name:"Colors"},{icon:"TextAa",name:"Fonts"},{icon:"CornersOut",name:"Borders"},{icon:"ArrowSquareIn",name:"Buttons"},{icon:"Textbox",name:"Inputs"}],su=[12,14,16,18,20,24,28,32,40,48].map(e=>String(e)),lu=["/","/reviews","/faqs","/contact","/products","/ticket","/login"],$t={"/":{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=se(e=>({activeBlock:ka[0],setActiveBlock:t=>e(()=>({activeBlock:t}))})),Na=se(e=>({openModal:!1,setOpenModal:t=>e(()=>({openModal:t})),onChange:null,setOnChange:t=>e(()=>({onChange:t})),tip:"",setTip:t=>e(()=>({tip:t}))})),gu=se(e=>({error:null,setError:t=>e(()=>({error:t}))})),Ta=se(e=>({title:null,description:null,onConfirm:null,setTitle:t=>e(()=>({title:t})),setDescription:t=>e(()=>({description:t})),setOnConfirm:t=>e(()=>({onConfirm:t}))}));var yu=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=St(this.defaults,n);const{transitional:r,paramsSerializer:o,headers:a}=n;r!==void 0&&xn.assertOptions(r,{silentJSONParsing:Xe.transitional(Xe.boolean),forcedJSONParsing:Xe.transitional(Xe.boolean),clarifyTimeoutError:Xe.transitional(Xe.boolean)},!1),o!=null&&(E.isFunction(o)?n.paramsSerializer={serialize:o}:xn.assertOptions(o,{encode:Xe.function,serialize:Xe.function},!0)),n.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?n.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:n.allowAbsoluteUrls=!0),xn.assertOptions(n,{baseUrl:Xe.spelling("baseURL"),withXsrfToken:Xe.spelling("withXSRFToken")},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let i=a&&E.merge(a.common,a[n.method]);a&&E.forEach(["delete","get","head","post","put","patch","common"],m=>{delete a[m]}),n.headers=De.concat(i,a);const s=[];let l=!0;this.interceptors.request.forEach(function(p){typeof p.runWhen=="function"&&p.runWhen(n)===!1||(l=l&&p.synchronous,s.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,s),m.push.apply(m,c),h=m.length,u=Promise.resolve(n);d<h;)u=u.then(m[d++],m[d++]);return u}h=s.length;let w=n;for(d=0;d<h;){const m=s[d++],p=s[d++];try{w=m(w)}catch(v){p.call(this,v);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=St(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){wt.prototype[t]=function(n,r){return this.request(St(r||{},{method:t,url:n,data:(r||{}).data}))}});E.forEach(["post","put","patch"],function(t){function n(r){return function(a,i,s){return this.request(St(s||{},{method:t,headers:r?{"Content-Type":"multipart/form-data"}:{},url:a,data:i}))}}wt.prototype[t]=n(),wt.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 i=new Promise(s=>{r.subscribe(s),a=s}).then(o);return i.cancel=function(){r.unsubscribe(a)},i},t(function(a,i,s){r.reason||(r.reason=new Ot(a,i,s),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 wt(e),n=ea(wt.prototype.request,t);return E.extend(n,wt.prototype,t,{allOwnKeys:!0}),E.extend(n,t,null,{allOwnKeys:!0}),n.create=function(o){return Ea(St(e,o))},n}const ce=Ea(tn);ce.Axios=wt;ce.CanceledError=Ot;ce.CancelToken=Lc;ce.isCancel=pa;ce.VERSION=ba;ce.toFormData=Vn;ce.AxiosError=$;ce.Cancel=ce.CanceledError;ce.all=function(t){return Promise.all(t)};ce.spread=Rc;ce.isAxiosError=kc;ce.mergeConfig=St;ce.AxiosHeaders=De;ce.formToJSON=e=>ha(E.isHTMLForm(e)?new FormData(e):e);ce.getAdapter=Sa.getAdapter;ce.HttpStatusCode=yr;ce.default=ce;const{Axios:af,AxiosError:Nc,CanceledError:sf,isCancel:lf,CancelToken:cf,VERSION:uf,all:df,Cancel:ff,isAxiosError:hf,spread:pf,toFormData:mf,AxiosHeaders:gf,HttpStatusCode:yf,formToJSON:vf,getAdapter:wf,mergeConfig:Sf}=ce,gn="https://localhost:5043",at=async e=>{var h,w;const{url:t,withToken:n,method:r,body:o,contentType:a,typeToken:i="seller"}=e,s=n?localStorage.getItem("sellerAccessToken"):null,l=n?localStorage.getItem("token"):null,c=i==="seller"?s: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 ce.get(u?gn:t,{headers:d});break;case"post":m=await ce.post(u?gn:t,o,{headers:d});break;case"put":m=await ce.put(u?gn:t,o,{headers:d});break;case"delete":m=await ce.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,v=(h=p.response)==null?void 0:h.data;let L="Something Went Wrong";v&&(L=v.errors[0]);const b=(w=p.response)==null?void 0:w.status;if(b===401)try{const P=await Promise.resolve().then(()=>require("./charge-w4kIp324.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},Fc=(e,t="300")=>e==="not found"?"empty":`https://imagedelivery.net/${e}/w=${t}`,Ic=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]},vr=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)},rr="f10120ab-7ebb-4785-b240-7428edaa3c4e",Ut="https://t-api.billgang.com",Vt="https://internal-t-api.antistock.io",Wt="I",Vc=10*1e3,$c=15*1e3,zc=15*60*1e3,xa=()=>{var t;const e=vr(Wt);return((t=e==null?void 0:e.s)==null?void 0:t.i)||null},Jc=(e,t="production",n)=>{const{pathname:r}=We(),o=we.useRef(),a=we.useRef(document.visibilityState);we.useEffect(()=>{if(!e)return;const i=()=>Date.now(),s=async()=>(await at({url:`${n?Vt:Ut}/${e}/t/p`,method:"post",withToken:!1})).data.data.id,l=async m=>(await at({url:`${n?Vt:Ut}/${e}/t/p/${t==="development"?rr:m}/s`,method:"post",withToken:!1})).data.data.id,c=async(m,p,v,L)=>{const b=t==="development"?rr:m;try{return(await at({url:`${n?Vt:Ut}/${e}/t/p/${b}/s/${p}/e`,method:"post",withToken:!1,body:{url:v,oldEventId:L},contentType:"application/json"})).data.data.id}catch{return p=await l(m),(await at({url:`${n?Vt:Ut}/${e}/t/p/${b}/s/${p}/e`,method:"post",withToken:!1,body:{url:v},contentType:"application/json"})).data.data.id}},u=async(m,p,v)=>{await at({url:`${n?Vt:Ut}/${e}/t/p/${t==="development"?rr:m}/s/${p}/e/${v}/h`,method:"post",withToken:!1});const b=vr(Wt);b&&(b.s.u=i().toString(),b.lu=i().toString(),To(Wt,b))},d=(m,p,v)=>{o.current&&clearInterval(o.current),o.current=setInterval(async()=>{if(document.visibilityState==="visible")try{await u(m,p,v)}catch{await h()}},Vc)},h=async()=>{var L,b,R,P;const m=`${window.location.hostname}${r}`,p=vr(Wt),v=i();try{let T=p==null?void 0:p.p;T||(T=await s());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||v-S>zc;(!H||_)&&(H=await l(T));const G=Number((p==null?void 0:p.lu)||0),B=v-G>$c,ae=await c(T,H,m,p!=null&&p.l&&!B?p.l:void 0),ee={p:T,s:{i:H,c:((P=p==null?void 0:p.s)==null?void 0:P.c)??v.toString(),u:v.toString()},l:ae,lu:v.toString()};To(Wt,ee),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=se(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=se(e=>({page:1,setPage:t=>e(()=>({page:t})),resetPage:()=>e(()=>({page:1}))})),Gc=se(e=>({discordInfo:null,setDiscordInfo:t=>e(()=>({discordInfo:t}))})),Kc=se(e=>({subscription:null,setSubscription:t=>e({subscription:t})})),nn=se(e=>({apiUrls:Dc,setApiUrls:t=>e(()=>({apiUrls:t}))})),La=se(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}))})),Ar=se(e=>({general:null,setGeneral:t=>e(()=>({general:t})),isAntistock:!1,setIsAntistock:t=>e(()=>({isAntistock:t}))})),wr=se(e=>({settings:null,setSettings:t=>{e(()=>({settings:t}))},isLoadingSettings:!0,setIsLoadingSettings:t=>e(()=>({isLoadingSettings:t}))})),On=se((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 i=JSON.parse(JSON.stringify(t().themeSettings));_e.getState().addHistory({themeSettings:i});const s={...a.themeSettings.colors,[n]:{...a.themeSettings.colors[n],[r]:o}};return{themeSettings:{...a.themeSettings,colors:s}}}),updateFont:(n,r,o,a,i)=>e(s=>{const l=JSON.parse(JSON.stringify(t().themeSettings));_e.getState().addHistory({themeSettings:l});const c={...s.themeSettings.fonts,[n]:{...s.themeSettings.fonts[n],[r]:{...s.themeSettings.fonts[n][r],[o]:{...s.themeSettings.fonts[n][r][o],[a]:i}}}};return{themeSettings:{...s.themeSettings,fonts:c}}}),updateFontSizePercentage:(n,r)=>e(o=>{const a=JSON.parse(JSON.stringify(t().themeSettings));_e.getState().addHistory({themeSettings:a});const i={...o.themeSettings.fonts,[n]:{...o.themeSettings.fonts[n],fontSizePercentage:r}};return{themeSettings:{...o.themeSettings,fonts:i}}}),updateBorder:(n,r)=>e(o=>{const a=JSON.parse(JSON.stringify(t().themeSettings));_e.getState().addHistory({themeSettings:a});const i={...o.themeSettings.borders,[n]:r};return{themeSettings:{...o.themeSettings,borders:i}}}),updateButton:(n,r,o)=>e(a=>{const i=JSON.parse(JSON.stringify(t().themeSettings));_e.getState().addHistory({themeSettings:i});const s={...a.themeSettings.buttons[n],[r]:o},l={...a.themeSettings.buttons,[n]:s};return{themeSettings:{...a.themeSettings,buttons:l}}}),updateInput:(n,r,o)=>e(a=>{const i=JSON.parse(JSON.stringify(t().themeSettings));return _e.getState().addHistory({themeSettings:i}),{themeSettings:{...a.themeSettings,inputs:{...a.themeSettings.inputs,[n]:{...a.themeSettings.inputs[n],[o]:r}}}}}),isLoadingThemeSettings:!1,setIsLoadingThemeSettings:n=>e(()=>({isLoadingThemeSettings:n}))})),Fe=se(e=>({notifications:[],setNotifications:t=>e(()=>({notifications:t}))})),Yc=se(e=>({isOpen:!0,setIsOpen:t=>e(()=>({isOpen:t}))}));var ke=[];for(var or=0;or<256;++or)ke.push((or+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 yn,Qc=new Uint8Array(16);function eu(){if(!yn&&(yn=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!yn))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return yn(Qc)}var tu=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto);const _o={randomUUID:tu};function ot(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 i=l=>l===null?null:JSON.parse(l,void 0),s=(a=n.getItem(o))!=null?a:null;return s instanceof Promise?s.then(i):i(s)},setItem:(o,a)=>n.setItem(o,JSON.stringify(a,void 0)),removeItem:o=>n.removeItem(o)}}const Sr=e=>t=>{try{const n=e(t);return n instanceof Promise?n:{then(r){return Sr(r)(n)},catch(r){return this}}}catch(n){return{then(r){return this},catch(r){return Sr(r)(n)}}}},ru=(e,t)=>(n,r,o)=>{let a={storage:nu(()=>localStorage),partialize:p=>p,version:0,merge:(p,v)=>({...v,...p}),...t},i=!1;const s=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,v)=>{d(p,v),u()};const h=e((...p)=>{n(...p),u()},r,o);o.getInitialState=()=>h;let w;const m=()=>{var p,v;if(!c)return;i=!1,s.forEach(b=>{var R;return b((R=r())!=null?R:h)});const L=((v=a.onRehydrateStorage)==null?void 0:v.call(a,(p=r())!=null?p:h))||void 0;return Sr(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(),i=!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:()=>i,onHydrate:p=>(s.add(p),()=>{s.delete(p)}),onFinishHydration:p=>(l.add(p),()=>{l.delete(p)})},a.skipHydration||m(),w||h},Jn=ru,Yt=se(Jn((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=ot();if(r)r[o]=n,e({pages:r});else{const a=t().setPages;a({});const i=t().pages;i[o]=n,e({pages:i})}},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=se(e=>({isOpenModal:!1,setIsOpenModal:t=>e(()=>({isOpenModal:t}))})),Mn=se(Jn((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&&_e.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&&_e.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&&_e.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:i}=Yt.getState();if(!a||!i||!i[a]||!o[i[a].path]){console.error("Cannot set position: invalid page or block data");return}const s=i[a].path,l=o[s],c=n?l.order.indexOf(n):-1;if(c===-1&&n){console.error(`Block with ID "${n}" not found in page "${s}"`);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));_e.getState().addHistory({layers:o});const a={...t().blocks},i=a[n]||{data:{},order:[]},s=t().positionBlock,l=ot(),c={name:r.name,value:r.value};return i.data[l]=c,s===null||s>=i.order.length?i.order.push(l):i.order.splice(s,0,l),e({blocks:{...a,[n]:{data:i.data,order:i.order}},currentBlock:l,positionBlock:null}),Fe.getState().setNotifications([...Fe.getState().notifications,{id:ot(),message:"Block successfully added",status:"success"}]),l},editBlock:(n,r,o)=>{const a=JSON.parse(JSON.stringify(t().blocks));_e.getState().addHistory({layers:a});const i=t().blocks,s=i[n]||{};s.data[r]={name:o.name,value:{...o.value}},e({blocks:{...i,[n]:s}})},removeBlock:(n,r)=>{const o=JSON.parse(JSON.stringify(t().blocks));_e.getState().addHistory({layers:o});const a=JSON.parse(JSON.stringify(t().blocks)),i=a[n];if(!i){console.error(`Page at path "${n}" does not exist.`);return}delete i.data[r],i.order=i.order.filter(s=>s!==r),e({blocks:{...a,[n]:i}}),Fe.getState().setNotifications([...Fe.getState().notifications,{id:ot(),message:"Block successfully deleted",status:"success"}])},moveBlock:(n,r,o)=>e(a=>{const i=JSON.parse(JSON.stringify(t().blocks));if(_e.getState().addHistory({layers:i}),!a.blocks[n])return console.error(`Path ${n} does not exist in blocks`),a;const s={...a.blocks[n]},l=[...s.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),Fe.getState().setNotifications([...Fe.getState().notifications,{id:ot(),message:"Block successfully moved",status:"success"}]),{blocks:{...a.blocks,[n]:{...s,order:l}}}}),duplicateBlock:(n,r)=>{const o=JSON.parse(JSON.stringify(t().blocks));_e.getState().addHistory({layers:o});const a=JSON.parse(JSON.stringify(t().blocks)),i=a[n];if(!i||!i.data[r]){console.error(`Block with ID "${r}" not found in page "${n}"`);return}const s=ot(),l=i.data[r],c={name:l.name,value:JSON.parse(JSON.stringify({...l.value}))};i.data[s]={...c};const u=i.order.indexOf(r);if(u===-1){console.error(`Block ID "${r}" not found in order array`);return}i.order.splice(u+1,0,s),e({blocks:{...a,[n]:i},currentBlock:s}),Ra.getState().setActiveBlock({id:s,neededScroll:!0}),Fe.getState().setNotifications([...Fe.getState().notifications,{id:ot(),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}}})),_e=se((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:i,header:s,footer:l,announcement:c,setBlocks:u,setHeader:d,setFooter:h,setAnnouncement:w}=Mn.getState(),{themeSettings:m,setThemeSettings:p}=On.getState(),v={themeSettings:JSON.parse(JSON.stringify(m)),layers:JSON.parse(JSON.stringify(i)),header:JSON.parse(JSON.stringify(s)),footer:JSON.parse(JSON.stringify(l)),announcement:JSON.parse(JSON.stringify(c))};e({past:a,future:[v,...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:i,announcement:s,setBlocks:l,setHeader:c,setFooter:u,setAnnouncement:d}=Mn.getState(),{themeSettings:h,setThemeSettings:w}=On.getState(),m=r[0],p=r.slice(1),v={themeSettings:JSON.parse(JSON.stringify(h)),layers:JSON.parse(JSON.stringify(o)),header:JSON.parse(JSON.stringify(a)),footer:JSON.parse(JSON.stringify(i)),announcement:JSON.parse(JSON.stringify(s))};e({past:[...n,v],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=se(Jn(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"}],iu=[{icon:"PaintBrushBroad",name:"Colors"},{icon:"TextAa",name:"Fonts"},{icon:"CornersOut",name:"Borders"},{icon:"ArrowSquareIn",name:"Buttons"},{icon:"Textbox",name:"Inputs"}],su=[12,14,16,18,20,24,28,32,40,48].map(e=>String(e)),lu=["/","/reviews","/faqs","/contact","/products","/ticket","/login"],$t={"/":{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=se(e=>({activeBlock:ka[0],setActiveBlock:t=>e(()=>({activeBlock:t}))})),Na=se(e=>({openModal:!1,setOpenModal:t=>e(()=>({openModal:t})),onChange:null,setOnChange:t=>e(()=>({onChange:t})),tip:"",setTip:t=>e(()=>({tip:t}))})),gu=se(e=>({error:null,setError:t=>e(()=>({error:t}))})),Ta=se(e=>({title:null,description:null,onConfirm:null,setTitle:t=>e(()=>({title:t})),setDescription:t=>e(()=>({description:t})),setOnConfirm:t=>e(()=>({onConfirm:t}))}));var yu=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