/home/smartbloks/.trash/extendify/public/build/extendify-deactivate.js
!function(){"use strict";var e,t,n={250:function(e,t,n){var r=n(196),o="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},i=r.useState,s=r.useEffect,a=r.useLayoutEffect,u=r.useDebugValue;function l(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!o(e,n)}catch(e){return!0}}var c="undefined"==typeof window||void 0===window.document||void 0===window.document.createElement?function(e,t){return t()}:function(e,t){var n=t(),r=i({inst:{value:n,getSnapshot:t}}),o=r[0].inst,c=r[1];return a((function(){o.value=n,o.getSnapshot=t,l(o)&&c({inst:o})}),[e,n,t]),s((function(){return l(o)&&c({inst:o}),e((function(){l(o)&&c({inst:o})}))}),[e]),u(n),n};t.useSyncExternalStore=void 0!==r.useSyncExternalStore?r.useSyncExternalStore:c},139:function(e,t,n){var r=n(196),o=n(688),i="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},s=o.useSyncExternalStore,a=r.useRef,u=r.useEffect,l=r.useMemo,c=r.useDebugValue;t.useSyncExternalStoreWithSelector=function(e,t,n,r,o){var d=a(null);if(null===d.current){var f={hasValue:!1,value:null};d.current=f}else f=d.current;d=l((function(){function e(e){if(!u){if(u=!0,s=e,e=r(e),void 0!==o&&f.hasValue){var t=f.value;if(o(t,e))return a=t}return a=e}if(t=a,i(s,e))return t;var n=r(e);return void 0!==o&&o(t,n)?t:(s=e,a=n)}var s,a,u=!1,l=void 0===n?null:n;return[function(){return e(t())},null===l?void 0:function(){return e(l())}]}),[t,n,r,o]);var p=s(e,d[0],d[1]);return u((function(){f.hasValue=!0,f.value=p}),[p]),c(p),p}},688:function(e,t,n){e.exports=n(250)},798:function(e,t,n){e.exports=n(139)},196:function(e){e.exports=window.React}},r={};function o(e){var t=r[e];if(void 0!==t)return t.exports;var i=r[e]={exports:{}};return n[e](i,i.exports,o),i.exports}t=Object.getPrototypeOf?function(e){return Object.getPrototypeOf(e)}:function(e){return e.__proto__},o.t=function(n,r){if(1&r&&(n=this(n)),8&r)return n;if("object"==typeof n&&n){if(4&r&&n.__esModule)return n;if(16&r&&"function"==typeof n.then)return n}var i=Object.create(null);o.r(i);var s={};e=e||[null,t({}),t([]),t(t)];for(var a=2&r&&n;"object"==typeof a&&!~e.indexOf(a);a=t(a))Object.getOwnPropertyNames(a).forEach((function(e){s[e]=function(){return n[e]}}));return s.default=function(){return n},o.d(i,s),i},o.d=function(e,t){for(var n in t)o.o(t,n)&&!o.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},o.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},o.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},function(){var e=window.wp.element,t=window.wp.components,n=window.wp.i18n,r=function(t){let{icon:n,size:r=24,...o}=t;return(0,e.cloneElement)(n,{width:r,height:r,...o})},i=window.wp.primitives,s=(0,e.createElement)(i.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,e.createElement)(i.Path,{d:"M13 11.8l6.1-6.3-1-1-6.1 6.2-6.1-6.2-1 1 6.1 6.3-6.5 6.7 1 1 6.5-6.6 6.5 6.6 1-1z"})),a=o(196),u=o.t(a,2);function l(e,t,...n){if(e in t){let r=t[e];return"function"==typeof r?r(...n):r}let r=new Error(`Tried to handle "${e}" but there is no handler defined. Only defined handlers are: ${Object.keys(t).map((e=>`"${e}"`)).join(", ")}.`);throw Error.captureStackTrace&&Error.captureStackTrace(r,l),r}var c,d=((c=d||{})[c.None=0]="None",c[c.RenderStrategy=1]="RenderStrategy",c[c.Static=2]="Static",c),f=(e=>(e[e.Unmount=0]="Unmount",e[e.Hidden=1]="Hidden",e))(f||{});function p({ourProps:e,theirProps:t,slot:n,defaultTag:r,features:o,visible:i=!0,name:s}){let a=h(t,e);if(i)return m(a,n,r,s);let u=null!=o?o:0;if(2&u){let{static:e=!1,...t}=a;if(e)return m(t,n,r,s)}if(1&u){let{unmount:e=!0,...t}=a;return l(e?0:1,{0(){return null},1(){return m({...t,hidden:!0,style:{display:"none"}},n,r,s)}})}return m(a,n,r,s)}function m(e,t={},n,r){var o;let{as:i=n,children:s,refName:u="ref",...l}=v(e,["unmount","static"]),c=void 0!==e.ref?{[u]:e.ref}:{},d="function"==typeof s?s(t):s;l.className&&"function"==typeof l.className&&(l.className=l.className(t));let f={};if(t){let e=!1,n=[];for(let[r,o]of Object.entries(t))"boolean"==typeof o&&(e=!0),!0===o&&n.push(r);e&&(f["data-headlessui-state"]=n.join(" "))}if(i===a.Fragment&&Object.keys(y(l)).length>0){if(!(0,a.isValidElement)(d)||Array.isArray(d)&&d.length>1)throw new Error(['Passing props on "Fragment"!',"",`The current component <${r} /> is rendering a "Fragment".`,"However we need to passthrough the following props:",Object.keys(l).map((e=>`  - ${e}`)).join("\n"),"","You can apply a few solutions:",['Add an `as="..."` prop, to ensure that we render an actual element instead of a "Fragment".',"Render a single element as the child so that we can forward the props onto that element."].map((e=>`  - ${e}`)).join("\n")].join("\n"));let e=function(...e){return e.filter(Boolean).join(" ")}(null==(o=d.props)?void 0:o.className,l.className),t=e?{className:e}:{};return(0,a.cloneElement)(d,Object.assign({},h(d.props,y(v(l,["ref"]))),f,c,function(...e){return{ref:e.every((e=>null==e))?void 0:t=>{for(let n of e)null!=n&&("function"==typeof n?n(t):n.current=t)}}}(d.ref,c.ref),t))}return(0,a.createElement)(i,Object.assign({},v(l,["ref"]),i!==a.Fragment&&c,i!==a.Fragment&&f),d)}function h(...e){if(0===e.length)return{};if(1===e.length)return e[0];let t={},n={};for(let r of e)for(let e in r)e.startsWith("on")&&"function"==typeof r[e]?(null!=n[e]||(n[e]=[]),n[e].push(r[e])):t[e]=r[e];if(t.disabled||t["aria-disabled"])return Object.assign(t,Object.fromEntries(Object.keys(n).map((e=>[e,void 0]))));for(let e in n)Object.assign(t,{[e](t,...r){let o=n[e];for(let e of o){if((t instanceof Event||(null==t?void 0:t.nativeEvent)instanceof Event)&&t.defaultPrevented)return;e(t,...r)}}});return t}function g(e){var t;return Object.assign((0,a.forwardRef)(e),{displayName:null!=(t=e.displayName)?t:e.name})}function y(e){let t=Object.assign({},e);for(let e in t)void 0===t[e]&&delete t[e];return t}function v(e,t=[]){let n=Object.assign({},e);for(let e of t)e in n&&delete n[e];return n}var w=Object.defineProperty,b=(e,t,n)=>(((e,t,n)=>{t in e?w(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n})(e,"symbol"!=typeof t?t+"":t,n),n);let E=new class{constructor(){b(this,"current",this.detect()),b(this,"handoffState","pending"),b(this,"currentId",0)}set(e){this.current!==e&&(this.handoffState="pending",this.currentId=0,this.current=e)}reset(){this.set(this.detect())}nextId(){return++this.currentId}get isServer(){return"server"===this.current}get isClient(){return"client"===this.current}detect(){return"undefined"==typeof window||"undefined"==typeof document?"server":"client"}handoff(){"pending"===this.handoffState&&(this.handoffState="complete")}get isHandoffComplete(){return"complete"===this.handoffState}},S=(e,t)=>{E.isServer?(0,a.useEffect)(e,t):(0,a.useLayoutEffect)(e,t)};function O(e){let t=(0,a.useRef)(e);return S((()=>{t.current=e}),[e]),t}let R=function(e){let t=O(e);return a.useCallback(((...e)=>t.current(...e)),[t])},x=Symbol();function T(e,t=!0){return Object.assign(e,{[x]:t})}function A(...e){let t=(0,a.useRef)(e);(0,a.useEffect)((()=>{t.current=e}),[e]);let n=R((e=>{for(let n of t.current)null!=n&&("function"==typeof n?n(e):n.current=e)}));return e.every((e=>null==e||(null==e?void 0:e[x])))?void 0:n}var P,N,D=((N=D||{}).Space=" ",N.Enter="Enter",N.Escape="Escape",N.Backspace="Backspace",N.Delete="Delete",N.ArrowLeft="ArrowLeft",N.ArrowUp="ArrowUp",N.ArrowRight="ArrowRight",N.ArrowDown="ArrowDown",N.Home="Home",N.End="End",N.PageUp="PageUp",N.PageDown="PageDown",N.Tab="Tab",N);function C(){let[e,t]=(0,a.useState)(E.isHandoffComplete);return e&&!1===E.isHandoffComplete&&t(!1),(0,a.useEffect)((()=>{!0!==e&&t(!0)}),[e]),(0,a.useEffect)((()=>E.handoff()),[]),e}let j=null!=(P=a.useId)?P:function(){let e=C(),[t,n]=a.useState(e?()=>E.nextId():null);return S((()=>{null===t&&n(E.nextId())}),[t]),null!=t?""+t:void 0};var L=(e=>(e[e.None=1]="None",e[e.Focusable=2]="Focusable",e[e.Hidden=4]="Hidden",e))(L||{});let F=g((function(e,t){let{features:n=1,...r}=e;return p({ourProps:{ref:t,"aria-hidden":2==(2&n)||void 0,style:{position:"fixed",top:1,left:1,width:1,height:0,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0",...4==(4&n)&&2!=(2&n)&&{display:"none"}}},theirProps:r,slot:{},defaultTag:"div",name:"Hidden"})}));function k(e){return E.isServer?null:e instanceof Node?e.ownerDocument:null!=e&&e.hasOwnProperty("current")&&e.current instanceof Node?e.current.ownerDocument:document}let _=["[contentEditable=true]","[tabindex]","a[href]","area[href]","button:not([disabled])","iframe","input:not([disabled])","select:not([disabled])","textarea:not([disabled])"].map((e=>`${e}:not([tabindex='-1'])`)).join(",");var I,U,B=(e=>(e[e.First=1]="First",e[e.Previous=2]="Previous",e[e.Next=4]="Next",e[e.Last=8]="Last",e[e.WrapAround=16]="WrapAround",e[e.NoScroll=32]="NoScroll",e))(B||{}),M=((U=M||{})[U.Error=0]="Error",U[U.Overflow=1]="Overflow",U[U.Success=2]="Success",U[U.Underflow=3]="Underflow",U),H=((I=H||{})[I.Previous=-1]="Previous",I[I.Next=1]="Next",I);var q=(e=>(e[e.Strict=0]="Strict",e[e.Loose=1]="Loose",e))(q||{});function z(e,t=0){var n;return e!==(null==(n=k(e))?void 0:n.body)&&l(t,{0(){return e.matches(_)},1(){let t=e;for(;null!==t;){if(t.matches(_))return!0;t=t.parentElement}return!1}})}function W(e){null==e||e.focus({preventScroll:!0})}let V=["textarea","input"].join(",");function $(e,t,{sorted:n=!0,relativeTo:r=null,skipElements:o=[]}={}){let i=Array.isArray(e)?e.length>0?e[0].ownerDocument:document:e.ownerDocument,s=Array.isArray(e)?n?function(e,t=(e=>e)){return e.slice().sort(((e,n)=>{let r=t(e),o=t(n);if(null===r||null===o)return 0;let i=r.compareDocumentPosition(o);return i&Node.DOCUMENT_POSITION_FOLLOWING?-1:i&Node.DOCUMENT_POSITION_PRECEDING?1:0}))}(e):e:function(e=document.body){return null==e?[]:Array.from(e.querySelectorAll(_)).sort(((e,t)=>Math.sign((e.tabIndex||Number.MAX_SAFE_INTEGER)-(t.tabIndex||Number.MAX_SAFE_INTEGER))))}(e);o.length>0&&s.length>1&&(s=s.filter((e=>!o.includes(e)))),r=null!=r?r:i.activeElement;let a,u=(()=>{if(5&t)return 1;if(10&t)return-1;throw new Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),l=(()=>{if(1&t)return 0;if(2&t)return Math.max(0,s.indexOf(r))-1;if(4&t)return Math.max(0,s.indexOf(r))+1;if(8&t)return s.length-1;throw new Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),c=32&t?{preventScroll:!0}:{},d=0,f=s.length;do{if(d>=f||d+f<=0)return 0;let e=l+d;if(16&t)e=(e+f)%f;else{if(e<0)return 3;if(e>=f)return 1}a=s[e],null==a||a.focus(c),d+=u}while(a!==i.activeElement);return 6&t&&function(e){var t,n;return null!=(n=null==(t=null==e?void 0:e.matches)?void 0:t.call(e,V))&&n}(a)&&a.select(),a.hasAttribute("tabindex")||a.setAttribute("tabindex","0"),2}var J=(e=>(e[e.Forwards=0]="Forwards",e[e.Backwards=1]="Backwards",e))(J||{});function G(){let e=(0,a.useRef)(!1);return S((()=>(e.current=!0,()=>{e.current=!1})),[]),e}function K(...e){return(0,a.useMemo)((()=>k(...e)),[...e])}function X(e,t,n,r){let o=O(n);(0,a.useEffect)((()=>{function n(e){o.current(e)}return(e=null!=e?e:window).addEventListener(t,n,r),()=>e.removeEventListener(t,n,r)}),[e,t,r])}function Y(e){"function"==typeof queueMicrotask?queueMicrotask(e):Promise.resolve().then(e).catch((e=>setTimeout((()=>{throw e}))))}function Q(e,t){let n=(0,a.useRef)([]),r=R(e);(0,a.useEffect)((()=>{let e=[...n.current];for(let[o,i]of t.entries())if(n.current[o]!==i){let o=r(t,e);return n.current=t,o}}),[r,...t])}function Z(){let e=[],t=[],n={enqueue(e){t.push(e)},addEventListener(e,t,r,o){return e.addEventListener(t,r,o),n.add((()=>e.removeEventListener(t,r,o)))},requestAnimationFrame(...e){let t=requestAnimationFrame(...e);return n.add((()=>cancelAnimationFrame(t)))},nextFrame(...e){return n.requestAnimationFrame((()=>n.requestAnimationFrame(...e)))},setTimeout(...e){let t=setTimeout(...e);return n.add((()=>clearTimeout(t)))},microTask(...e){let t={current:!0};return Y((()=>{t.current&&e[0]()})),n.add((()=>{t.current=!1}))},add(t){return e.push(t),()=>{let n=e.indexOf(t);if(n>=0){let[t]=e.splice(n,1);t()}}},dispose(){for(let t of e.splice(0))t()},async workQueue(){for(let e of t.splice(0))await e()},style(e,t,n){let r=e.style.getPropertyValue(t);return Object.assign(e.style,{[t]:n}),this.add((()=>{Object.assign(e.style,{[t]:r})}))}};return n}var ee,te=((ee=te||{})[ee.None=1]="None",ee[ee.InitialFocus=2]="InitialFocus",ee[ee.TabLock=4]="TabLock",ee[ee.FocusLock=8]="FocusLock",ee[ee.RestoreFocus=16]="RestoreFocus",ee[ee.All=30]="All",ee);let ne=Object.assign(g((function(e,t){let n=(0,a.useRef)(null),r=A(n,t),{initialFocus:o,containers:i,features:s=30,...u}=e;C()||(s=1);let c=K(n);!function({ownerDocument:e},t){let n=(0,a.useRef)(null);X(null==e?void 0:e.defaultView,"focusout",(e=>{!t||n.current||(n.current=e.target)}),!0),Q((()=>{t||((null==e?void 0:e.activeElement)===(null==e?void 0:e.body)&&W(n.current),n.current=null)}),[t]);let r=(0,a.useRef)(!1);(0,a.useEffect)((()=>(r.current=!1,()=>{r.current=!0,Y((()=>{!r.current||(W(n.current),n.current=null)}))})),[])}({ownerDocument:c},Boolean(16&s));let d=function({ownerDocument:e,container:t,initialFocus:n},r){let o=(0,a.useRef)(null),i=G();return Q((()=>{if(!r)return;let s=t.current;!s||Y((()=>{if(!i.current)return;let t=null==e?void 0:e.activeElement;if(null!=n&&n.current){if((null==n?void 0:n.current)===t)return void(o.current=t)}else if(s.contains(t))return void(o.current=t);null!=n&&n.current?W(n.current):$(s,B.First)===M.Error&&console.warn("There are no focusable elements inside the <FocusTrap />"),o.current=null==e?void 0:e.activeElement}))}),[r]),o}({ownerDocument:c,container:n,initialFocus:o},Boolean(2&s));!function({ownerDocument:e,container:t,containers:n,previousActiveElement:r},o){let i=G();X(null==e?void 0:e.defaultView,"focus",(e=>{if(!o||!i.current)return;let s=new Set(null==n?void 0:n.current);s.add(t);let a=r.current;if(!a)return;let u=e.target;u&&u instanceof HTMLElement?re(s,u)?(r.current=u,W(u)):(e.preventDefault(),e.stopPropagation(),W(a)):W(r.current)}),!0)}({ownerDocument:c,container:n,containers:i,previousActiveElement:d},Boolean(8&s));let f=function(){let e=(0,a.useRef)(0);return function(e,t,n){let r=O(t);(0,a.useEffect)((()=>{function t(e){r.current(e)}return window.addEventListener(e,t,n),()=>window.removeEventListener(e,t,n)}),[e,n])}("keydown",(t=>{"Tab"===t.key&&(e.current=t.shiftKey?1:0)}),!0),e}(),m=R((e=>{let t=n.current;t&&l(f.current,{[J.Forwards]:()=>{$(t,B.First,{skipElements:[e.relatedTarget]})},[J.Backwards]:()=>{$(t,B.Last,{skipElements:[e.relatedTarget]})}})})),h=function(){let[e]=(0,a.useState)(Z);return(0,a.useEffect)((()=>()=>e.dispose()),[e]),e}(),g=(0,a.useRef)(!1),y={ref:r,onKeyDown(e){"Tab"==e.key&&(g.current=!0,h.requestAnimationFrame((()=>{g.current=!1})))},onBlur(e){let t=new Set(null==i?void 0:i.current);t.add(n);let r=e.relatedTarget;r instanceof HTMLElement&&"true"!==r.dataset.headlessuiFocusGuard&&(re(t,r)||(g.current?$(n.current,l(f.current,{[J.Forwards]:()=>B.Next,[J.Backwards]:()=>B.Previous})|B.WrapAround,{relativeTo:e.target}):e.target instanceof HTMLElement&&W(e.target)))}};return a.createElement(a.Fragment,null,Boolean(4&s)&&a.createElement(F,{as:"button",type:"button","data-headlessui-focus-guard":!0,onFocus:m,features:L.Focusable}),p({ourProps:y,theirProps:u,defaultTag:"div",name:"FocusTrap"}),Boolean(4&s)&&a.createElement(F,{as:"button",type:"button","data-headlessui-focus-guard":!0,onFocus:m,features:L.Focusable}))})),{features:te});function re(e,t){var n;for(let r of e)if(null!=(n=r.current)&&n.contains(t))return!0;return!1}let oe=new Set,ie=new Map;function se(e){e.setAttribute("aria-hidden","true"),e.inert=!0}function ae(e){let t=ie.get(e);!t||(null===t["aria-hidden"]?e.removeAttribute("aria-hidden"):e.setAttribute("aria-hidden",t["aria-hidden"]),e.inert=t.inert)}function ue(e,t=!0){S((()=>{if(!t||!e.current)return;let n=e.current,r=k(n);if(r){oe.add(n);for(let e of ie.keys())e.contains(n)&&(ae(e),ie.delete(e));return r.querySelectorAll("body > *").forEach((e=>{if(e instanceof HTMLElement){for(let t of oe)if(e.contains(t))return;1===oe.size&&(ie.set(e,{"aria-hidden":e.getAttribute("aria-hidden"),inert:e.inert}),se(e))}})),()=>{if(oe.delete(n),oe.size>0)r.querySelectorAll("body > *").forEach((e=>{if(e instanceof HTMLElement&&!ie.has(e)){for(let t of oe)if(e.contains(t))return;ie.set(e,{"aria-hidden":e.getAttribute("aria-hidden"),inert:e.inert}),se(e)}}));else for(let e of ie.keys())ae(e),ie.delete(e)}}}),[t])}var le=window.ReactDOM;let ce=(0,a.createContext)(!1);function de(){return(0,a.useContext)(ce)}function fe(e){return a.createElement(ce.Provider,{value:e.force},e.children)}let pe=a.Fragment,me=g((function(e,t){let n=e,r=(0,a.useRef)(null),o=A(T((e=>{r.current=e})),t),i=K(r),s=function(e){let t=de(),n=(0,a.useContext)(ge),r=K(e),[o,i]=(0,a.useState)((()=>{if(!t&&null!==n||E.isServer)return null;let e=null==r?void 0:r.getElementById("headlessui-portal-root");if(e)return e;if(null===r)return null;let o=r.createElement("div");return o.setAttribute("id","headlessui-portal-root"),r.body.appendChild(o)}));return(0,a.useEffect)((()=>{null!==o&&(null!=r&&r.body.contains(o)||null==r||r.body.appendChild(o))}),[o,r]),(0,a.useEffect)((()=>{t||null!==n&&i(n.current)}),[n,i,t]),o}(r),[u]=(0,a.useState)((()=>{var e;return E.isServer?null:null!=(e=null==i?void 0:i.createElement("div"))?e:null})),l=C(),c=(0,a.useRef)(!1);return S((()=>{if(c.current=!1,s&&u)return s.contains(u)||(u.setAttribute("data-headlessui-portal",""),s.appendChild(u)),()=>{c.current=!0,Y((()=>{var e;!c.current||!s||!u||(u instanceof Node&&s.contains(u)&&s.removeChild(u),s.childNodes.length<=0&&(null==(e=s.parentElement)||e.removeChild(s)))}))}}),[s,u]),l&&s&&u?(0,le.createPortal)(p({ourProps:{ref:o},theirProps:n,defaultTag:pe,name:"Portal"}),u):null})),he=a.Fragment,ge=(0,a.createContext)(null),ye=g((function(e,t){let{target:n,...r}=e,o={ref:A(t)};return a.createElement(ge.Provider,{value:n},p({ourProps:o,theirProps:r,defaultTag:he,name:"Popover.Group"}))})),ve=Object.assign(me,{Group:ye}),we=(0,a.createContext)(null);function be(){let e=(0,a.useContext)(we);if(null===e){let e=new Error("You used a <Description /> component, but it is not inside a relevant parent.");throw Error.captureStackTrace&&Error.captureStackTrace(e,be),e}return e}let Ee=g((function(e,t){let n=j(),{id:r=`headlessui-description-${n}`,...o}=e,i=be(),s=A(t);return S((()=>i.register(r)),[r,i.register]),p({ourProps:{ref:s,...i.props,id:r},theirProps:o,slot:i.slot||{},defaultTag:"p",name:i.name||"Description"})})),Se=(0,a.createContext)(null);Se.displayName="OpenClosedContext";var Oe=(e=>(e[e.Open=0]="Open",e[e.Closed=1]="Closed",e))(Oe||{});let Re=(0,a.createContext)((()=>{}));Re.displayName="StackContext";var xe=(e=>(e[e.Add=0]="Add",e[e.Remove=1]="Remove",e))(xe||{});function Te({children:e,onUpdate:t,type:n,element:r,enabled:o}){let i=(0,a.useContext)(Re),s=R(((...e)=>{null==t||t(...e),i(...e)}));return S((()=>{let e=void 0===o||!0===o;return e&&s(0,n,r),()=>{e&&s(1,n,r)}}),[s,n,r,o]),a.createElement(Re.Provider,{value:s},e)}function Ae(e,t,n){let r=O(t);(0,a.useEffect)((()=>{function t(e){r.current(e)}return document.addEventListener(e,t,n),()=>document.removeEventListener(e,t,n)}),[e,n])}function Pe(e,t,n=!0){let r=(0,a.useRef)(!1);function o(n,o){if(!r.current||n.defaultPrevented)return;let i=function e(t){return"function"==typeof t?e(t()):Array.isArray(t)||t instanceof Set?t:[t]}(e),s=o(n);if(null!==s&&s.getRootNode().contains(s)){for(let e of i){if(null===e)continue;let t=e instanceof HTMLElement?e:e.current;if(null!=t&&t.contains(s)||n.composed&&n.composedPath().includes(t))return}return!z(s,q.Loose)&&-1!==s.tabIndex&&n.preventDefault(),t(n,s)}}(0,a.useEffect)((()=>{requestAnimationFrame((()=>{r.current=n}))}),[n]);let i=(0,a.useRef)(null);Ae("mousedown",(e=>{var t,n;r.current&&(i.current=(null==(n=null==(t=e.composedPath)?void 0:t.call(e))?void 0:n[0])||e.target)}),!0),Ae("click",(e=>{!i.current||(o(e,(()=>i.current)),i.current=null)}),!0),Ae("blur",(e=>o(e,(()=>window.document.activeElement instanceof HTMLIFrameElement?window.document.activeElement:null))),!0)}const Ne="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},{useState:De,useEffect:Ce,useLayoutEffect:je,useDebugValue:Le}=u;function Fe(e){const t=e.getSnapshot,n=e.value;try{const e=t();return!Ne(n,e)}catch{return!0}}const ke="undefined"==typeof window||void 0===window.document||void 0===window.document.createElement?function(e,t,n){return t()}:function(e,t,n){const r=t(),[{inst:o},i]=De({inst:{value:r,getSnapshot:t}});return je((()=>{o.value=r,o.getSnapshot=t,Fe(o)&&i({inst:o})}),[e,r,t]),Ce((()=>(Fe(o)&&i({inst:o}),e((()=>{Fe(o)&&i({inst:o})})))),[e]),Le(r),r},_e="useSyncExternalStore"in u?(e=>e.useSyncExternalStore)(u):ke;function Ie(){let e;return{before({doc:t}){var n;let r=t.documentElement;e=(null!=(n=t.defaultView)?n:window).innerWidth-r.clientWidth},after({doc:t,d:n}){let r=t.documentElement,o=r.clientWidth-r.offsetWidth,i=e-o;n.style(r,"paddingRight",`${i}px`)}}}function Ue(){if(!(/iPhone/gi.test(window.navigator.platform)||/Mac/gi.test(window.navigator.platform)&&window.navigator.maxTouchPoints>0))return{};let e;return{before(){e=window.pageYOffset},after({doc:t,d:n,meta:r}){function o(e){return r.containers.flatMap((e=>e())).some((t=>t.contains(e)))}n.style(t.body,"marginTop",`-${e}px`),window.scrollTo(0,0);let i=null;n.addEventListener(t,"click",(e=>{if(e.target instanceof HTMLElement)try{let n=e.target.closest("a");if(!n)return;let{hash:r}=new URL(n.href),s=t.querySelector(r);s&&!o(s)&&(i=s)}catch{}}),!0),n.addEventListener(t,"touchmove",(e=>{e.target instanceof HTMLElement&&!o(e.target)&&e.preventDefault()}),{passive:!1}),n.add((()=>{window.scrollTo(0,window.pageYOffset+e),i&&i.isConnected&&(i.scrollIntoView({block:"nearest"}),i=null)}))}}}function Be(e){let t={};for(let n of e)Object.assign(t,n(t));return t}let Me=function(e,t){let n=new Map,r=new Set;return{getSnapshot(){return n},subscribe(e){return r.add(e),()=>r.delete(e)},dispatch(e,...o){let i=t[e].call(n,...o);i&&(n=i,r.forEach((e=>e())))}}}(0,{PUSH(e,t){var n;let r=null!=(n=this.get(e))?n:{doc:e,count:0,d:Z(),meta:new Set};return r.count++,r.meta.add(t),this.set(e,r),this},POP(e,t){let n=this.get(e);return n&&(n.count--,n.meta.delete(t)),this},SCROLL_PREVENT({doc:e,d:t,meta:n}){let r={doc:e,d:t,meta:Be(n)},o=[Ue(),Ie(),{before({doc:e,d:t}){t.style(e.documentElement,"overflow","hidden")}}];o.forEach((({before:e})=>null==e?void 0:e(r))),o.forEach((({after:e})=>null==e?void 0:e(r)))},SCROLL_ALLOW({d:e}){e.dispose()},TEARDOWN({doc:e}){this.delete(e)}});Me.subscribe((()=>{let e=Me.getSnapshot(),t=new Map;for(let[n]of e)t.set(n,n.documentElement.style.overflow);for(let n of e.values()){let e="hidden"===t.get(n.doc),r=0!==n.count;(r&&!e||!r&&e)&&Me.dispatch(n.count>0?"SCROLL_PREVENT":"SCROLL_ALLOW",n),0===n.count&&Me.dispatch("TEARDOWN",n)}}));var He=(e=>(e[e.Open=0]="Open",e[e.Closed=1]="Closed",e))(He||{}),qe=(e=>(e[e.SetTitleId=0]="SetTitleId",e))(qe||{});let ze={0(e,t){return e.titleId===t.id?e:{...e,titleId:t.id}}},We=(0,a.createContext)(null);function Ve(e){let t=(0,a.useContext)(We);if(null===t){let t=new Error(`<${e} /> is missing a parent <Dialog /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(t,Ve),t}return t}function $e(e,t){return l(t.type,ze,e,t)}We.displayName="DialogContext";let Je=d.RenderStrategy|d.Static,Ge=g((function(e,t){let n=j(),{id:r=`headlessui-dialog-${n}`,open:o,onClose:i,initialFocus:s,__demoMode:u=!1,...c}=e,[d,f]=(0,a.useState)(0),m=(0,a.useContext)(Se);void 0===o&&null!==m&&(o=l(m,{[Oe.Open]:!0,[Oe.Closed]:!1}));let h=(0,a.useRef)(new Set),g=(0,a.useRef)(null),y=A(g,t),v=(0,a.useRef)(null),w=K(g),b=e.hasOwnProperty("open")||null!==m,E=e.hasOwnProperty("onClose");if(!b&&!E)throw new Error("You have to provide an `open` and an `onClose` prop to the `Dialog` component.");if(!b)throw new Error("You provided an `onClose` prop to the `Dialog`, but forgot an `open` prop.");if(!E)throw new Error("You provided an `open` prop to the `Dialog`, but forgot an `onClose` prop.");if("boolean"!=typeof o)throw new Error(`You provided an \`open\` prop to the \`Dialog\`, but the value is not a boolean. Received: ${o}`);if("function"!=typeof i)throw new Error(`You provided an \`onClose\` prop to the \`Dialog\`, but the value is not a function. Received: ${i}`);let O=o?0:1,[x,T]=(0,a.useReducer)($e,{titleId:null,descriptionId:null,panelRef:(0,a.createRef)()}),P=R((()=>i(!1))),N=R((e=>T({type:0,id:e}))),k=!!C()&&!u&&0===O,_=d>1,I=null!==(0,a.useContext)(We),U=_?"parent":"leaf";ue(g,!!_&&k);let B=R((()=>{var e,t;return[...Array.from(null!=(e=null==w?void 0:w.querySelectorAll("html > *, body > *, [data-headlessui-portal]"))?e:[]).filter((e=>!(e===document.body||e===document.head||!(e instanceof HTMLElement)||e.contains(v.current)||x.panelRef.current&&e.contains(x.panelRef.current)))),null!=(t=x.panelRef.current)?t:g.current]}));Pe((()=>B()),P,k&&!_),X(null==w?void 0:w.defaultView,"keydown",(e=>{e.defaultPrevented||e.key===D.Escape&&0===O&&(_||(e.preventDefault(),e.stopPropagation(),P()))})),function(e,t,n=(()=>[document.body])){!function(e,t,n){let r=function(e){return _e(e.subscribe,e.getSnapshot,e.getSnapshot)}(Me),o=e?r.get(e):void 0,i=!!o&&o.count>0;S((()=>{if(e&&t)return Me.dispatch("PUSH",e,n),()=>Me.dispatch("POP",e,n)}),[t,e])}(e,t,(e=>{var t;return{containers:[...null!=(t=e.containers)?t:[],n]}}))}(w,0===O&&!I,B),(0,a.useEffect)((()=>{if(0!==O||!g.current)return;let e=new IntersectionObserver((e=>{for(let t of e)0===t.boundingClientRect.x&&0===t.boundingClientRect.y&&0===t.boundingClientRect.width&&0===t.boundingClientRect.height&&P()}));return e.observe(g.current),()=>e.disconnect()}),[O,g,P]);let[M,H]=function(){let[e,t]=(0,a.useState)([]);return[e.length>0?e.join(" "):void 0,(0,a.useMemo)((()=>function(e){let n=R((e=>(t((t=>[...t,e])),()=>t((t=>{let n=t.slice(),r=n.indexOf(e);return-1!==r&&n.splice(r,1),n}))))),r=(0,a.useMemo)((()=>({register:n,slot:e.slot,name:e.name,props:e.props})),[n,e.slot,e.name,e.props]);return a.createElement(we.Provider,{value:r},e.children)}),[t])]}(),q=(0,a.useMemo)((()=>[{dialogState:O,close:P,setTitleId:N},x]),[O,x,P,N]),z=(0,a.useMemo)((()=>({open:0===O})),[O]),W={ref:y,id:r,role:"dialog","aria-modal":0===O||void 0,"aria-labelledby":x.titleId,"aria-describedby":M};return a.createElement(Te,{type:"Dialog",enabled:0===O,element:g,onUpdate:R(((e,t,n)=>{"Dialog"===t&&l(e,{[xe.Add](){h.current.add(n),f((e=>e+1))},[xe.Remove](){h.current.add(n),f((e=>e-1))}})}))},a.createElement(fe,{force:!0},a.createElement(ve,null,a.createElement(We.Provider,{value:q},a.createElement(ve.Group,{target:g},a.createElement(fe,{force:!1},a.createElement(H,{slot:z,name:"Dialog.Description"},a.createElement(ne,{initialFocus:s,containers:h,features:k?l(U,{parent:ne.features.RestoreFocus,leaf:ne.features.All&~ne.features.FocusLock}):ne.features.None},p({ourProps:W,theirProps:c,slot:z,defaultTag:"div",features:Je,visible:0===O,name:"Dialog"})))))))),a.createElement(F,{features:L.Hidden,ref:v}))})),Ke=g((function(e,t){let n=j(),{id:r=`headlessui-dialog-overlay-${n}`,...o}=e,[{dialogState:i,close:s}]=Ve("Dialog.Overlay"),u=A(t),l=R((e=>{if(e.target===e.currentTarget){if(function(e){let t=e.parentElement,n=null;for(;t&&!(t instanceof HTMLFieldSetElement);)t instanceof HTMLLegendElement&&(n=t),t=t.parentElement;let r=""===(null==t?void 0:t.getAttribute("disabled"));return(!r||!function(e){if(!e)return!1;let t=e.previousElementSibling;for(;null!==t;){if(t instanceof HTMLLegendElement)return!1;t=t.previousElementSibling}return!0}(n))&&r}(e.currentTarget))return e.preventDefault();e.preventDefault(),e.stopPropagation(),s()}}));return p({ourProps:{ref:u,id:r,"aria-hidden":!0,onClick:l},theirProps:o,slot:(0,a.useMemo)((()=>({open:0===i})),[i]),defaultTag:"div",name:"Dialog.Overlay"})})),Xe=g((function(e,t){let n=j(),{id:r=`headlessui-dialog-backdrop-${n}`,...o}=e,[{dialogState:i},s]=Ve("Dialog.Backdrop"),u=A(t);(0,a.useEffect)((()=>{if(null===s.panelRef.current)throw new Error("A <Dialog.Backdrop /> component is being used, but a <Dialog.Panel /> component is missing.")}),[s.panelRef]);let l=(0,a.useMemo)((()=>({open:0===i})),[i]);return a.createElement(fe,{force:!0},a.createElement(ve,null,p({ourProps:{ref:u,id:r,"aria-hidden":!0},theirProps:o,slot:l,defaultTag:"div",name:"Dialog.Backdrop"})))})),Ye=g((function(e,t){let n=j(),{id:r=`headlessui-dialog-panel-${n}`,...o}=e,[{dialogState:i},s]=Ve("Dialog.Panel"),u=A(t,s.panelRef),l=(0,a.useMemo)((()=>({open:0===i})),[i]),c=R((e=>{e.stopPropagation()}));return p({ourProps:{ref:u,id:r,onClick:c},theirProps:o,slot:l,defaultTag:"div",name:"Dialog.Panel"})})),Qe=g((function(e,t){let n=j(),{id:r=`headlessui-dialog-title-${n}`,...o}=e,[{dialogState:i,setTitleId:s}]=Ve("Dialog.Title"),u=A(t);(0,a.useEffect)((()=>(s(r),()=>s(null))),[r,s]);let l=(0,a.useMemo)((()=>({open:0===i})),[i]);return p({ourProps:{ref:u,id:r},theirProps:o,slot:l,defaultTag:"h2",name:"Dialog.Title"})})),Ze=Object.assign(Ge,{Backdrop:Xe,Panel:Ye,Overlay:Ke,Title:Qe,Description:Ee});function et(e,t){return function(){return e.apply(t,arguments)}}const{toString:tt}=Object.prototype,{getPrototypeOf:nt}=Object,rt=(ot=Object.create(null),e=>{const t=tt.call(e);return ot[t]||(ot[t]=t.slice(8,-1).toLowerCase())});var ot;const it=e=>(e=e.toLowerCase(),t=>rt(t)===e),st=e=>t=>typeof t===e,{isArray:at}=Array,ut=st("undefined"),lt=it("ArrayBuffer"),ct=st("string"),dt=st("function"),ft=st("number"),pt=e=>null!==e&&"object"==typeof e,mt=e=>{if("object"!==rt(e))return!1;const t=nt(e);return!(null!==t&&t!==Object.prototype&&null!==Object.getPrototypeOf(t)||Symbol.toStringTag in e||Symbol.iterator in e)},ht=it("Date"),gt=it("File"),yt=it("Blob"),vt=it("FileList"),wt=it("URLSearchParams");function bt(e,t,{allOwnKeys:n=!1}={}){if(null==e)return;let r,o;if("object"!=typeof e&&(e=[e]),at(e))for(r=0,o=e.length;r<o;r++)t.call(null,e[r],r,e);else{const o=n?Object.getOwnPropertyNames(e):Object.keys(e),i=o.length;let s;for(r=0;r<i;r++)s=o[r],t.call(null,e[s],s,e)}}function Et(e,t){t=t.toLowerCase();const n=Object.keys(e);let r,o=n.length;for(;o-- >0;)if(r=n[o],t===r.toLowerCase())return r;return null}const St="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:global,Ot=e=>!ut(e)&&e!==St,Rt=(xt="undefined"!=typeof Uint8Array&&nt(Uint8Array),e=>xt&&e instanceof xt);var xt;const Tt=it("HTMLFormElement"),At=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),Pt=it("RegExp"),Nt=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};bt(n,((n,o)=>{!1!==t(n,o,e)&&(r[o]=n)})),Object.defineProperties(e,r)},Dt="abcdefghijklmnopqrstuvwxyz",Ct="0123456789",jt={DIGIT:Ct,ALPHA:Dt,ALPHA_DIGIT:Dt+Dt.toUpperCase()+Ct};var Lt={isArray:at,isArrayBuffer:lt,isBuffer:function(e){return null!==e&&!ut(e)&&null!==e.constructor&&!ut(e.constructor)&&dt(e.constructor.isBuffer)&&e.constructor.isBuffer(e)},isFormData:e=>{const t="[object FormData]";return e&&("function"==typeof FormData&&e instanceof FormData||tt.call(e)===t||dt(e.toString)&&e.toString()===t)},isArrayBufferView:function(e){let t;return t="undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&lt(e.buffer),t},isString:ct,isNumber:ft,isBoolean:e=>!0===e||!1===e,isObject:pt,isPlainObject:mt,isUndefined:ut,isDate:ht,isFile:gt,isBlob:yt,isRegExp:Pt,isFunction:dt,isStream:e=>pt(e)&&dt(e.pipe),isURLSearchParams:wt,isTypedArray:Rt,isFileList:vt,forEach:bt,merge:function e(){const{caseless:t}=Ot(this)&&this||{},n={},r=(r,o)=>{const i=t&&Et(n,o)||o;mt(n[i])&&mt(r)?n[i]=e(n[i],r):mt(r)?n[i]=e({},r):at(r)?n[i]=r.slice():n[i]=r};for(let e=0,t=arguments.length;e<t;e++)arguments[e]&&bt(arguments[e],r);return n},extend:(e,t,n,{allOwnKeys:r}={})=>(bt(t,((t,r)=>{n&&dt(t)?e[r]=et(t,n):e[r]=t}),{allOwnKeys:r}),e),trim:e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,""),stripBOM:e=>(65279===e.charCodeAt(0)&&(e=e.slice(1)),e),inherits:(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),n&&Object.assign(e.prototype,n)},toFlatObject:(e,t,n,r)=>{let o,i,s;const a={};if(t=t||{},null==e)return t;do{for(o=Object.getOwnPropertyNames(e),i=o.length;i-- >0;)s=o[i],r&&!r(s,e,t)||a[s]||(t[s]=e[s],a[s]=!0);e=!1!==n&&nt(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},kindOf:rt,kindOfTest:it,endsWith:(e,t,n)=>{e=String(e),(void 0===n||n>e.length)&&(n=e.length),n-=t.length;const r=e.indexOf(t,n);return-1!==r&&r===n},toArray:e=>{if(!e)return null;if(at(e))return e;let t=e.length;if(!ft(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},forEachEntry:(e,t)=>{const n=(e&&e[Symbol.iterator]).call(e);let r;for(;(r=n.next())&&!r.done;){const n=r.value;t.call(e,n[0],n[1])}},matchAll:(e,t)=>{let n;const r=[];for(;null!==(n=e.exec(t));)r.push(n);return r},isHTMLForm:Tt,hasOwnProperty:At,hasOwnProp:At,reduceDescriptors:Nt,freezeMethods:e=>{Nt(e,((t,n)=>{if(dt(e)&&-1!==["arguments","caller","callee"].indexOf(n))return!1;const r=e[n];dt(r)&&(t.enumerable=!1,"writable"in t?t.writable=!1:t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")}))}))},toObjectSet:(e,t)=>{const n={},r=e=>{e.forEach((e=>{n[e]=!0}))};return at(e)?r(e):r(String(e).split(t)),n},toCamelCase:e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,(function(e,t,n){return t.toUpperCase()+n})),noop:()=>{},toFiniteNumber:(e,t)=>(e=+e,Number.isFinite(e)?e:t),findKey:Et,global:St,isContextDefined:Ot,ALPHABET:jt,generateString:(e=16,t=jt.ALPHA_DIGIT)=>{let n="";const{length:r}=t;for(;e--;)n+=t[Math.random()*r|0];return n},isSpecCompliantForm:function(e){return!!(e&&dt(e.append)&&"FormData"===e[Symbol.toStringTag]&&e[Symbol.iterator])},toJSONObject:e=>{const t=new Array(10),n=(e,r)=>{if(pt(e)){if(t.indexOf(e)>=0)return;if(!("toJSON"in e)){t[r]=e;const o=at(e)?[]:{};return bt(e,((e,t)=>{const i=n(e,r+1);!ut(i)&&(o[t]=i)})),t[r]=void 0,o}}return e};return n(e,0)}};function Ft(e,t,n,r,o){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=(new Error).stack,this.message=e,this.name="AxiosError",t&&(this.code=t),n&&(this.config=n),r&&(this.request=r),o&&(this.response=o)}Lt.inherits(Ft,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:Lt.toJSONObject(this.config),code:this.code,status:this.response&&this.response.status?this.response.status:null}}});const kt=Ft.prototype,_t={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach((e=>{_t[e]={value:e}})),Object.defineProperties(Ft,_t),Object.defineProperty(kt,"isAxiosError",{value:!0}),Ft.from=(e,t,n,r,o,i)=>{const s=Object.create(kt);return Lt.toFlatObject(e,s,(function(e){return e!==Error.prototype}),(e=>"isAxiosError"!==e)),Ft.call(s,e.message,t,n,r,o),s.cause=e,s.name=e.name,i&&Object.assign(s,i),s};var It=Ft;function Ut(e){return Lt.isPlainObject(e)||Lt.isArray(e)}function Bt(e){return Lt.endsWith(e,"[]")?e.slice(0,-2):e}function Mt(e,t,n){return e?e.concat(t).map((function(e,t){return e=Bt(e),!n&&t?"["+e+"]":e})).join(n?".":""):t}const Ht=Lt.toFlatObject(Lt,{},null,(function(e){return/^is[A-Z]/.test(e)}));var qt=function(e,t,n){if(!Lt.isObject(e))throw new TypeError("target must be an object");t=t||new FormData;const r=(n=Lt.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,(function(e,t){return!Lt.isUndefined(t[e])}))).metaTokens,o=n.visitor||l,i=n.dots,s=n.indexes,a=(n.Blob||"undefined"!=typeof Blob&&Blob)&&Lt.isSpecCompliantForm(t);if(!Lt.isFunction(o))throw new TypeError("visitor must be a function");function u(e){if(null===e)return"";if(Lt.isDate(e))return e.toISOString();if(!a&&Lt.isBlob(e))throw new It("Blob is not supported. Use a Buffer instead.");return Lt.isArrayBuffer(e)||Lt.isTypedArray(e)?a&&"function"==typeof Blob?new Blob([e]):Buffer.from(e):e}function l(e,n,o){let a=e;if(e&&!o&&"object"==typeof e)if(Lt.endsWith(n,"{}"))n=r?n:n.slice(0,-2),e=JSON.stringify(e);else if(Lt.isArray(e)&&function(e){return Lt.isArray(e)&&!e.some(Ut)}(e)||(Lt.isFileList(e)||Lt.endsWith(n,"[]"))&&(a=Lt.toArray(e)))return n=Bt(n),a.forEach((function(e,r){!Lt.isUndefined(e)&&null!==e&&t.append(!0===s?Mt([n],r,i):null===s?n:n+"[]",u(e))})),!1;return!!Ut(e)||(t.append(Mt(o,n,i),u(e)),!1)}const c=[],d=Object.assign(Ht,{defaultVisitor:l,convertValue:u,isVisitable:Ut});if(!Lt.isObject(e))throw new TypeError("data must be an object");return function e(n,r){if(!Lt.isUndefined(n)){if(-1!==c.indexOf(n))throw Error("Circular reference detected in "+r.join("."));c.push(n),Lt.forEach(n,(function(n,i){!0===(!(Lt.isUndefined(n)||null===n)&&o.call(t,n,Lt.isString(i)?i.trim():i,r,d))&&e(n,r?r.concat(i):[i])})),c.pop()}}(e),t};function zt(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,(function(e){return t[e]}))}function Wt(e,t){this._pairs=[],e&&qt(e,this,t)}const Vt=Wt.prototype;Vt.append=function(e,t){this._pairs.push([e,t])},Vt.toString=function(e){const t=e?function(t){return e.call(this,t,zt)}:zt;return this._pairs.map((function(e){return t(e[0])+"="+t(e[1])}),"").join("&")};var $t=Wt;function Jt(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function Gt(e,t,n){if(!t)return e;const r=n&&n.encode||Jt,o=n&&n.serialize;let i;if(i=o?o(t,n):Lt.isURLSearchParams(t)?t.toString():new $t(t,n).toString(r),i){const t=e.indexOf("#");-1!==t&&(e=e.slice(0,t)),e+=(-1===e.indexOf("?")?"?":"&")+i}return e}var Kt=class{constructor(){this.handlers=[]}use(e,t,n){return this.handlers.push({fulfilled:e,rejected:t,synchronous:!!n&&n.synchronous,runWhen:n?n.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){Lt.forEach(this.handlers,(function(t){null!==t&&e(t)}))}},Xt={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},Yt="undefined"!=typeof URLSearchParams?URLSearchParams:$t,Qt=FormData;const Zt=(()=>{let e;return("undefined"==typeof navigator||"ReactNative"!==(e=navigator.product)&&"NativeScript"!==e&&"NS"!==e)&&"undefined"!=typeof window&&"undefined"!=typeof document})(),en="undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&"function"==typeof self.importScripts;var tn={isBrowser:!0,classes:{URLSearchParams:Yt,FormData:Qt,Blob:Blob},isStandardBrowserEnv:Zt,isStandardBrowserWebWorkerEnv:en,protocols:["http","https","file","blob","url","data"]},nn=function(e){function t(e,n,r,o){let i=e[o++];const s=Number.isFinite(+i),a=o>=e.length;return i=!i&&Lt.isArray(r)?r.length:i,a?(Lt.hasOwnProp(r,i)?r[i]=[r[i],n]:r[i]=n,!s):(r[i]&&Lt.isObject(r[i])||(r[i]=[]),t(e,n,r[i],o)&&Lt.isArray(r[i])&&(r[i]=function(e){const t={},n=Object.keys(e);let r;const o=n.length;let i;for(r=0;r<o;r++)i=n[r],t[i]=e[i];return t}(r[i])),!s)}if(Lt.isFormData(e)&&Lt.isFunction(e.entries)){const n={};return Lt.forEachEntry(e,((e,r)=>{t(function(e){return Lt.matchAll(/\w+|\[(\w*)]/g,e).map((e=>"[]"===e[0]?"":e[1]||e[0]))}(e),r,n,0)})),n}return null};const rn={"Content-Type":void 0},on={transitional:Xt,adapter:["xhr","http"],transformRequest:[function(e,t){const n=t.getContentType()||"",r=n.indexOf("application/json")>-1,o=Lt.isObject(e);if(o&&Lt.isHTMLForm(e)&&(e=new FormData(e)),Lt.isFormData(e))return r&&r?JSON.stringify(nn(e)):e;if(Lt.isArrayBuffer(e)||Lt.isBuffer(e)||Lt.isStream(e)||Lt.isFile(e)||Lt.isBlob(e))return e;if(Lt.isArrayBufferView(e))return e.buffer;if(Lt.isURLSearchParams(e))return t.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let i;if(o){if(n.indexOf("application/x-www-form-urlencoded")>-1)return function(e,t){return qt(e,new tn.classes.URLSearchParams,Object.assign({visitor:function(e,t,n,r){return tn.isNode&&Lt.isBuffer(e)?(this.append(t,e.toString("base64")),!1):r.defaultVisitor.apply(this,arguments)}},t))}(e,this.formSerializer).toString();if((i=Lt.isFileList(e))||n.indexOf("multipart/form-data")>-1){const t=this.env&&this.env.FormData;return qt(i?{"files[]":e}:e,t&&new t,this.formSerializer)}}return o||r?(t.setContentType("application/json",!1),function(e,t,n){if(Lt.isString(e))try{return(0,JSON.parse)(e),Lt.trim(e)}catch(e){if("SyntaxError"!==e.name)throw e}return(0,JSON.stringify)(e)}(e)):e}],transformResponse:[function(e){const t=this.transitional||on.transitional,n=t&&t.forcedJSONParsing,r="json"===this.responseType;if(e&&Lt.isString(e)&&(n&&!this.responseType||r)){const n=!(t&&t.silentJSONParsing)&&r;try{return JSON.parse(e)}catch(e){if(n){if("SyntaxError"===e.name)throw It.from(e,It.ERR_BAD_RESPONSE,this,null,this.response);throw e}}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:tn.classes.FormData,Blob:tn.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};Lt.forEach(["delete","get","head"],(function(e){on.headers[e]={}})),Lt.forEach(["post","put","patch"],(function(e){on.headers[e]=Lt.merge(rn)}));var sn=on;const an=Lt.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),un=Symbol("internals");function ln(e){return e&&String(e).trim().toLowerCase()}function cn(e){return!1===e||null==e?e:Lt.isArray(e)?e.map(cn):String(e)}function dn(e,t,n,r){return Lt.isFunction(r)?r.call(this,t,n):Lt.isString(t)?Lt.isString(r)?-1!==t.indexOf(r):Lt.isRegExp(r)?r.test(t):void 0:void 0}class fn{constructor(e){e&&this.set(e)}set(e,t,n){const r=this;function o(e,t,n){const o=ln(t);if(!o)throw new Error("header name must be a non-empty string");const i=Lt.findKey(r,o);(!i||void 0===r[i]||!0===n||void 0===n&&!1!==r[i])&&(r[i||t]=cn(e))}const i=(e,t)=>Lt.forEach(e,((e,n)=>o(e,n,t)));return Lt.isPlainObject(e)||e instanceof this.constructor?i(e,t):Lt.isString(e)&&(e=e.trim())&&!/^[-_a-zA-Z]+$/.test(e.trim())?i((e=>{const t={};let n,r,o;return e&&e.split("\n").forEach((function(e){o=e.indexOf(":"),n=e.substring(0,o).trim().toLowerCase(),r=e.substring(o+1).trim(),!n||t[n]&&an[n]||("set-cookie"===n?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)})),t})(e),t):null!=e&&o(t,e,n),this}get(e,t){if(e=ln(e)){const n=Lt.findKey(this,e);if(n){const e=this[n];if(!t)return e;if(!0===t)return function(e){const t=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(e);)t[r[1]]=r[2];return t}(e);if(Lt.isFunction(t))return t.call(this,e,n);if(Lt.isRegExp(t))return t.exec(e);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,t){if(e=ln(e)){const n=Lt.findKey(this,e);return!(!n||void 0===this[n]||t&&!dn(0,this[n],n,t))}return!1}delete(e,t){const n=this;let r=!1;function o(e){if(e=ln(e)){const o=Lt.findKey(n,e);!o||t&&!dn(0,n[o],o,t)||(delete n[o],r=!0)}}return Lt.isArray(e)?e.forEach(o):o(e),r}clear(e){const t=Object.keys(this);let n=t.length,r=!1;for(;n--;){const o=t[n];e&&!dn(0,this[o],o,e)||(delete this[o],r=!0)}return r}normalize(e){const t=this,n={};return Lt.forEach(this,((r,o)=>{const i=Lt.findKey(n,o);if(i)return t[i]=cn(r),void delete t[o];const s=e?function(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,((e,t,n)=>t.toUpperCase()+n))}(o):String(o).trim();s!==o&&delete t[o],t[s]=cn(r),n[s]=!0})),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const t=Object.create(null);return Lt.forEach(this,((n,r)=>{null!=n&&!1!==n&&(t[r]=e&&Lt.isArray(n)?n.join(", "):n)})),t}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map((([e,t])=>e+": "+t)).join("\n")}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...t){const n=new this(e);return t.forEach((e=>n.set(e))),n}static accessor(e){const t=(this[un]=this[un]={accessors:{}}).accessors,n=this.prototype;function r(e){const r=ln(e);t[r]||(function(e,t){const n=Lt.toCamelCase(" "+t);["get","set","has"].forEach((r=>{Object.defineProperty(e,r+n,{value:function(e,n,o){return this[r].call(this,t,e,n,o)},configurable:!0})}))}(n,e),t[r]=!0)}return Lt.isArray(e)?e.forEach(r):r(e),this}}fn.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),Lt.freezeMethods(fn.prototype),Lt.freezeMethods(fn);var pn=fn;function mn(e,t){const n=this||sn,r=t||n,o=pn.from(r.headers);let i=r.data;return Lt.forEach(e,(function(e){i=e.call(n,i,o.normalize(),t?t.status:void 0)})),o.normalize(),i}function hn(e){return!(!e||!e.__CANCEL__)}function gn(e,t,n){It.call(this,null==e?"canceled":e,It.ERR_CANCELED,t,n),this.name="CanceledError"}Lt.inherits(gn,It,{__CANCEL__:!0});var yn=gn,vn=tn.isStandardBrowserEnv?{write:function(e,t,n,r,o,i){const s=[];s.push(e+"="+encodeURIComponent(t)),Lt.isNumber(n)&&s.push("expires="+new Date(n).toGMTString()),Lt.isString(r)&&s.push("path="+r),Lt.isString(o)&&s.push("domain="+o),!0===i&&s.push("secure"),document.cookie=s.join("; ")},read:function(e){const t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove:function(e){this.write(e,"",Date.now()-864e5)}}:{write:function(){},read:function(){return null},remove:function(){}};function wn(e,t){return e&&!/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)?function(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}(e,t):t}var bn=tn.isStandardBrowserEnv?function(){const e=/(msie|trident)/i.test(navigator.userAgent),t=document.createElement("a");let n;function r(n){let r=n;return e&&(t.setAttribute("href",r),r=t.href),t.setAttribute("href",r),{href:t.href,protocol:t.protocol?t.protocol.replace(/:$/,""):"",host:t.host,search:t.search?t.search.replace(/^\?/,""):"",hash:t.hash?t.hash.replace(/^#/,""):"",hostname:t.hostname,port:t.port,pathname:"/"===t.pathname.charAt(0)?t.pathname:"/"+t.pathname}}return n=r(window.location.href),function(e){const t=Lt.isString(e)?r(e):e;return t.protocol===n.protocol&&t.host===n.host}}():function(){return!0},En=function(e,t){e=e||10;const n=new Array(e),r=new Array(e);let o,i=0,s=0;return t=void 0!==t?t:1e3,function(a){const u=Date.now(),l=r[s];o||(o=u),n[i]=a,r[i]=u;let c=s,d=0;for(;c!==i;)d+=n[c++],c%=e;if(i=(i+1)%e,i===s&&(s=(s+1)%e),u-o<t)return;const f=l&&u-l;return f?Math.round(1e3*d/f):void 0}};function Sn(e,t){let n=0;const r=En(50,250);return o=>{const i=o.loaded,s=o.lengthComputable?o.total:void 0,a=i-n,u=r(a);n=i;const l={loaded:i,total:s,progress:s?i/s:void 0,bytes:a,rate:u||void 0,estimated:u&&s&&i<=s?(s-i)/u:void 0,event:o};l[t?"download":"upload"]=!0,e(l)}}const On={http:null,xhr:"undefined"!=typeof XMLHttpRequest&&function(e){return new Promise((function(t,n){let r=e.data;const o=pn.from(e.headers).normalize(),i=e.responseType;let s;function a(){e.cancelToken&&e.cancelToken.unsubscribe(s),e.signal&&e.signal.removeEventListener("abort",s)}Lt.isFormData(r)&&(tn.isStandardBrowserEnv||tn.isStandardBrowserWebWorkerEnv)&&o.setContentType(!1);let u=new XMLHttpRequest;if(e.auth){const t=e.auth.username||"",n=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";o.set("Authorization","Basic "+btoa(t+":"+n))}const l=wn(e.baseURL,e.url);function c(){if(!u)return;const r=pn.from("getAllResponseHeaders"in u&&u.getAllResponseHeaders());!function(e,t,n){const r=n.config.validateStatus;n.status&&r&&!r(n.status)?t(new It("Request failed with status code "+n.status,[It.ERR_BAD_REQUEST,It.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n)):e(n)}((function(e){t(e),a()}),(function(e){n(e),a()}),{data:i&&"text"!==i&&"json"!==i?u.response:u.responseText,status:u.status,statusText:u.statusText,headers:r,config:e,request:u}),u=null}if(u.open(e.method.toUpperCase(),Gt(l,e.params,e.paramsSerializer),!0),u.timeout=e.timeout,"onloadend"in u?u.onloadend=c:u.onreadystatechange=function(){u&&4===u.readyState&&(0!==u.status||u.responseURL&&0===u.responseURL.indexOf("file:"))&&setTimeout(c)},u.onabort=function(){u&&(n(new It("Request aborted",It.ECONNABORTED,e,u)),u=null)},u.onerror=function(){n(new It("Network Error",It.ERR_NETWORK,e,u)),u=null},u.ontimeout=function(){let t=e.timeout?"timeout of "+e.timeout+"ms exceeded":"timeout exceeded";const r=e.transitional||Xt;e.timeoutErrorMessage&&(t=e.timeoutErrorMessage),n(new It(t,r.clarifyTimeoutError?It.ETIMEDOUT:It.ECONNABORTED,e,u)),u=null},tn.isStandardBrowserEnv){const t=(e.withCredentials||bn(l))&&e.xsrfCookieName&&vn.read(e.xsrfCookieName);t&&o.set(e.xsrfHeaderName,t)}void 0===r&&o.setContentType(null),"setRequestHeader"in u&&Lt.forEach(o.toJSON(),(function(e,t){u.setRequestHeader(t,e)})),Lt.isUndefined(e.withCredentials)||(u.withCredentials=!!e.withCredentials),i&&"json"!==i&&(u.responseType=e.responseType),"function"==typeof e.onDownloadProgress&&u.addEventListener("progress",Sn(e.onDownloadProgress,!0)),"function"==typeof e.onUploadProgress&&u.upload&&u.upload.addEventListener("progress",Sn(e.onUploadProgress)),(e.cancelToken||e.signal)&&(s=t=>{u&&(n(!t||t.type?new yn(null,e,u):t),u.abort(),u=null)},e.cancelToken&&e.cancelToken.subscribe(s),e.signal&&(e.signal.aborted?s():e.signal.addEventListener("abort",s)));const d=function(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}(l);d&&-1===tn.protocols.indexOf(d)?n(new It("Unsupported protocol "+d+":",It.ERR_BAD_REQUEST,e)):u.send(r||null)}))}};Lt.forEach(On,((e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch(e){}Object.defineProperty(e,"adapterName",{value:t})}}));var Rn={getAdapter:e=>{e=Lt.isArray(e)?e:[e];const{length:t}=e;let n,r;for(let o=0;o<t&&(n=e[o],!(r=Lt.isString(n)?On[n.toLowerCase()]:n));o++);if(!r){if(!1===r)throw new It(`Adapter ${n} is not supported by the environment`,"ERR_NOT_SUPPORT");throw new Error(Lt.hasOwnProp(On,n)?`Adapter '${n}' is not available in the build`:`Unknown adapter '${n}'`)}if(!Lt.isFunction(r))throw new TypeError("adapter is not a function");return r},adapters:On};function xn(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new yn(null,e)}function Tn(e){return xn(e),e.headers=pn.from(e.headers),e.data=mn.call(e,e.transformRequest),-1!==["post","put","patch"].indexOf(e.method)&&e.headers.setContentType("application/x-www-form-urlencoded",!1),Rn.getAdapter(e.adapter||sn.adapter)(e).then((function(t){return xn(e),t.data=mn.call(e,e.transformResponse,t),t.headers=pn.from(t.headers),t}),(function(t){return hn(t)||(xn(e),t&&t.response&&(t.response.data=mn.call(e,e.transformResponse,t.response),t.response.headers=pn.from(t.response.headers))),Promise.reject(t)}))}const An=e=>e instanceof pn?e.toJSON():e;function Pn(e,t){t=t||{};const n={};function r(e,t,n){return Lt.isPlainObject(e)&&Lt.isPlainObject(t)?Lt.merge.call({caseless:n},e,t):Lt.isPlainObject(t)?Lt.merge({},t):Lt.isArray(t)?t.slice():t}function o(e,t,n){return Lt.isUndefined(t)?Lt.isUndefined(e)?void 0:r(void 0,e,n):r(e,t,n)}function i(e,t){if(!Lt.isUndefined(t))return r(void 0,t)}function s(e,t){return Lt.isUndefined(t)?Lt.isUndefined(e)?void 0:r(void 0,e):r(void 0,t)}function a(n,o,i){return i in t?r(n,o):i in e?r(void 0,n):void 0}const u={url:i,method:i,data:i,baseURL:s,transformRequest:s,transformResponse:s,paramsSerializer:s,timeout:s,timeoutMessage:s,withCredentials: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:a,headers:(e,t)=>o(An(e),An(t),!0)};return Lt.forEach(Object.keys(e).concat(Object.keys(t)),(function(r){const i=u[r]||o,s=i(e[r],t[r],r);Lt.isUndefined(s)&&i!==a||(n[r]=s)})),n}const Nn="1.3.2",Dn={};["object","boolean","number","function","string","symbol"].forEach(((e,t)=>{Dn[e]=function(n){return typeof n===e||"a"+(t<1?"n ":" ")+e}}));const Cn={};Dn.transitional=function(e,t,n){function r(e,t){return"[Axios v"+Nn+"] Transitional option '"+e+"'"+t+(n?". "+n:"")}return(n,o,i)=>{if(!1===e)throw new It(r(o," has been removed"+(t?" in "+t:"")),It.ERR_DEPRECATED);return t&&!Cn[o]&&(Cn[o]=!0,console.warn(r(o," has been deprecated since v"+t+" and will be removed in the near future"))),!e||e(n,o,i)}};var jn={assertOptions:function(e,t,n){if("object"!=typeof e)throw new It("options must be an object",It.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let o=r.length;for(;o-- >0;){const i=r[o],s=t[i];if(s){const t=e[i],n=void 0===t||s(t,i,e);if(!0!==n)throw new It("option "+i+" must be "+n,It.ERR_BAD_OPTION_VALUE)}else if(!0!==n)throw new It("Unknown option "+i,It.ERR_BAD_OPTION)}},validators:Dn};const Ln=jn.validators;class Fn{constructor(e){this.defaults=e,this.interceptors={request:new Kt,response:new Kt}}request(e,t){"string"==typeof e?(t=t||{}).url=e:t=e||{},t=Pn(this.defaults,t);const{transitional:n,paramsSerializer:r,headers:o}=t;let i;void 0!==n&&jn.assertOptions(n,{silentJSONParsing:Ln.transitional(Ln.boolean),forcedJSONParsing:Ln.transitional(Ln.boolean),clarifyTimeoutError:Ln.transitional(Ln.boolean)},!1),void 0!==r&&jn.assertOptions(r,{encode:Ln.function,serialize:Ln.function},!0),t.method=(t.method||this.defaults.method||"get").toLowerCase(),i=o&&Lt.merge(o.common,o[t.method]),i&&Lt.forEach(["delete","get","head","post","put","patch","common"],(e=>{delete o[e]})),t.headers=pn.concat(i,o);const s=[];let a=!0;this.interceptors.request.forEach((function(e){"function"==typeof e.runWhen&&!1===e.runWhen(t)||(a=a&&e.synchronous,s.unshift(e.fulfilled,e.rejected))}));const u=[];let l;this.interceptors.response.forEach((function(e){u.push(e.fulfilled,e.rejected)}));let c,d=0;if(!a){const e=[Tn.bind(this),void 0];for(e.unshift.apply(e,s),e.push.apply(e,u),c=e.length,l=Promise.resolve(t);d<c;)l=l.then(e[d++],e[d++]);return l}c=s.length;let f=t;for(d=0;d<c;){const e=s[d++],t=s[d++];try{f=e(f)}catch(e){t.call(this,e);break}}try{l=Tn.call(this,f)}catch(e){return Promise.reject(e)}for(d=0,c=u.length;d<c;)l=l.then(u[d++],u[d++]);return l}getUri(e){return Gt(wn((e=Pn(this.defaults,e)).baseURL,e.url),e.params,e.paramsSerializer)}}Lt.forEach(["delete","get","head","options"],(function(e){Fn.prototype[e]=function(t,n){return this.request(Pn(n||{},{method:e,url:t,data:(n||{}).data}))}})),Lt.forEach(["post","put","patch"],(function(e){function t(t){return function(n,r,o){return this.request(Pn(o||{},{method:e,headers:t?{"Content-Type":"multipart/form-data"}:{},url:n,data:r}))}}Fn.prototype[e]=t(),Fn.prototype[e+"Form"]=t(!0)}));var kn=Fn;class In{constructor(e){if("function"!=typeof e)throw new TypeError("executor must be a function.");let t;this.promise=new Promise((function(e){t=e}));const n=this;this.promise.then((e=>{if(!n._listeners)return;let t=n._listeners.length;for(;t-- >0;)n._listeners[t](e);n._listeners=null})),this.promise.then=e=>{let t;const r=new Promise((e=>{n.subscribe(e),t=e})).then(e);return r.cancel=function(){n.unsubscribe(t)},r},e((function(e,r,o){n.reason||(n.reason=new yn(e,r,o),t(n.reason))}))}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){this.reason?e(this.reason):this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const t=this._listeners.indexOf(e);-1!==t&&this._listeners.splice(t,1)}static source(){let e;const t=new In((function(t){e=t}));return{token:t,cancel:e}}}var Un=In;const Bn={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(Bn).forEach((([e,t])=>{Bn[t]=e}));var Mn=Bn;const Hn=function e(t){const n=new kn(t),r=et(kn.prototype.request,n);return Lt.extend(r,kn.prototype,n,{allOwnKeys:!0}),Lt.extend(r,n,null,{allOwnKeys:!0}),r.create=function(n){return e(Pn(t,n))},r}(sn);Hn.Axios=kn,Hn.CanceledError=yn,Hn.CancelToken=Un,Hn.isCancel=hn,Hn.VERSION=Nn,Hn.toFormData=qt,Hn.AxiosError=It,Hn.Cancel=Hn.CanceledError,Hn.all=function(e){return Promise.all(e)},Hn.spread=function(e){return function(t){return e.apply(null,t)}},Hn.isAxiosError=function(e){return Lt.isObject(e)&&!0===e.isAxiosError},Hn.mergeConfig=Pn,Hn.AxiosHeaders=pn,Hn.formToJSON=e=>nn(Lt.isHTMLForm(e)?new FormData(e):e),Hn.HttpStatusCode=Mn,Hn.default=Hn;var qn=Hn;const zn=e=>{let t;const n=new Set,r=(e,r)=>{const o="function"==typeof e?e(t):e;if(!Object.is(o,t)){const e=t;t=(null!=r?r:"object"!=typeof o)?o:Object.assign({},t,o),n.forEach((n=>n(t,e)))}},o=()=>t,i={setState:r,getState:o,subscribe:e=>(n.add(e),()=>n.delete(e)),destroy:()=>{console.warn("[DEPRECATED] The `destroy` method will be unsupported in a future version. Instead use unsubscribe function returned by subscribe. Everything will be garbage-collected if store is garbage-collected."),n.clear()}};return t=e(r,o,i),i};var Wn=o(798);const{useSyncExternalStoreWithSelector:Vn}=Wn,$n=e=>{"function"!=typeof e&&console.warn("[DEPRECATED] Passing a vanilla store will be unsupported in a future version. Instead use `import { useStore } from 'zustand'`.");const t="function"==typeof e?(e=>e?zn(e):zn)(e):e,n=(e,n)=>function(e,t=e.getState,n){const r=Vn(e.subscribe,e.getState,e.getServerState||e.getState,t,n);return(0,a.useDebugValue)(r),r}(t,e,n);return Object.assign(n,t),n};function Jn(e){let t;try{t=e()}catch(e){return}return{getItem:e=>{var n;const r=e=>null===e?null:JSON.parse(e),o=null!=(n=t.getItem(e))?n:null;return o instanceof Promise?o.then(r):r(o)},setItem:(e,n)=>t.setItem(e,JSON.stringify(n)),removeItem:e=>t.removeItem(e)}}const Gn=e=>t=>{try{const n=e(t);return n instanceof Promise?n:{then(e){return Gn(e)(n)},catch(e){return this}}}catch(e){return{then(e){return this},catch(t){return Gn(t)(e)}}}},Kn={async getData(){const e=await fetch(`${window.extendifyData.root}/user`,{method:"GET",headers:{"X-WP-Nonce":window.extendifyData.nonce,"X-Requested-With":"XMLHttpRequest","X-Extendify":!0}});return await e.json()},getMeta(e){return Qn.get("user-meta",{params:{key:e}})},authenticate(e,t){const n=new FormData;return n.append("email",e),n.append("key",t),Qn.post("login",n,{headers:{"Content-Type":"multipart/form-data"}})},register(e){const t=new FormData;return t.append("data",e),Qn.post("register",t,{headers:{"Content-Type":"multipart/form-data"}})},setData(e){const t=new FormData;return t.append("data",JSON.stringify(e)),Qn.post("user",t,{headers:{"Content-Type":"multipart/form-data"}})},deleteData(){return Qn.post("clear-user")}},Xn={getItem:async()=>await Kn.getData(),setItem:async(e,t)=>await Kn.setData(t),removeItem:async()=>await Kn.deleteData()},Yn=(er=(e,t)=>({firstLoadedOn:(new Date).toISOString(),email:"",apiKey:"",uuid:"",sdkPartner:"",noticesDismissedAt:{},modalNoticesDismissedAt:{},imports:0,runningImports:0,entryPoint:"not-set",enabled:null===window.extendifyData.sitesettings||window.extendifyData?.sitesettings?.state?.enabled,canInstallPlugins:!1,canActivatePlugins:!1,openOnNewPage:void 0,setOpenOnNewPage:t=>e({openOnNewPage:t}),incrementImports:()=>{e((e=>({imports:Number(e.imports)+1,runningImports:Number(e.runningImports)+1})))},hasAvailableImports:()=>!!t().apiKey||Number(t().runningImports)<10,remainingImports:()=>{const e=10-Number(t().runningImports);return e>0?e:0},markNoticeSeen:(n,r)=>{e({[`${r}DismissedAt`]:{...t()[`${r}DismissedAt`],[n]:(new Date).toISOString()}})}}),tr={name:"extendify-user",storage:Jn((()=>Xn))},Zn="getStorage"in tr||"serialize"in tr||"deserialize"in tr?(console.warn("[DEPRECATED] `getStorage`, `serialize` and `deserialize` options are deprecated. Use `storage` option instead."),((e,t)=>(n,r,o)=>{let i={getStorage:()=>localStorage,serialize:JSON.stringify,deserialize:JSON.parse,partialize:e=>e,version:0,merge:(e,t)=>({...t,...e}),...t},s=!1;const a=new Set,u=new Set;let l;try{l=i.getStorage()}catch(e){}if(!l)return e(((...e)=>{console.warn(`[zustand persist middleware] Unable to update item '${i.name}', the given storage is currently unavailable.`),n(...e)}),r,o);const c=Gn(i.serialize),d=()=>{const e=i.partialize({...r()});let t;const n=c({state:e,version:i.version}).then((e=>l.setItem(i.name,e))).catch((e=>{t=e}));if(t)throw t;return n},f=o.setState;o.setState=(e,t)=>{f(e,t),d()};const p=e(((...e)=>{n(...e),d()}),r,o);let m;const h=()=>{var e;if(!l)return;s=!1,a.forEach((e=>e(r())));const t=(null==(e=i.onRehydrateStorage)?void 0:e.call(i,r()))||void 0;return Gn(l.getItem.bind(l))(i.name).then((e=>{if(e)return i.deserialize(e)})).then((e=>{if(e){if("number"!=typeof e.version||e.version===i.version)return e.state;if(i.migrate)return i.migrate(e.state,e.version);console.error("State loaded from storage couldn't be migrated since no migrate function was provided")}})).then((e=>{var t;return m=i.merge(e,null!=(t=r())?t:p),n(m,!0),d()})).then((()=>{null==t||t(m,void 0),s=!0,u.forEach((e=>e(m)))})).catch((e=>{null==t||t(void 0,e)}))};return o.persist={setOptions:e=>{i={...i,...e},e.getStorage&&(l=e.getStorage())},clearStorage:()=>{null==l||l.removeItem(i.name)},getOptions:()=>i,rehydrate:()=>h(),hasHydrated:()=>s,onHydrate:e=>(a.add(e),()=>{a.delete(e)}),onFinishHydration:e=>(u.add(e),()=>{u.delete(e)})},h(),m||p})(er,tr)):((e,t)=>(n,r,o)=>{let i={storage:Jn((()=>localStorage)),partialize:e=>e,version:0,merge:(e,t)=>({...t,...e}),...t},s=!1;const a=new Set,u=new Set;let l=i.storage;if(!l)return e(((...e)=>{console.warn(`[zustand persist middleware] Unable to update item '${i.name}', the given storage is currently unavailable.`),n(...e)}),r,o);const c=()=>{const e=i.partialize({...r()});return l.setItem(i.name,{state:e,version:i.version})},d=o.setState;o.setState=(e,t)=>{d(e,t),c()};const f=e(((...e)=>{n(...e),c()}),r,o);let p;const m=()=>{var e,t;if(!l)return;s=!1,a.forEach((e=>{var t;return e(null!=(t=r())?t:f)}));const o=(null==(t=i.onRehydrateStorage)?void 0:t.call(i,null!=(e=r())?e:f))||void 0;return Gn(l.getItem.bind(l))(i.name).then((e=>{if(e){if("number"!=typeof e.version||e.version===i.version)return e.state;if(i.migrate)return i.migrate(e.state,e.version);console.error("State loaded from storage couldn't be migrated since no migrate function was provided")}})).then((e=>{var t;return p=i.merge(e,null!=(t=r())?t:f),n(p,!0),c()})).then((()=>{null==o||o(p,void 0),p=r(),s=!0,u.forEach((e=>e(p)))})).catch((e=>{null==o||o(void 0,e)}))};return o.persist={setOptions:e=>{i={...i,...e},e.storage&&(l=e.storage)},clearStorage:()=>{null==l||l.removeItem(i.name)},getOptions:()=>i,rehydrate:()=>m(),hasHydrated:()=>s,onHydrate:e=>(a.add(e),()=>{a.delete(e)}),onFinishHydration:e=>(u.add(e),()=>{u.delete(e)})},i.skipHydration||m(),p||f})(er,tr),Zn?$n(Zn):$n),Qn=qn.create({baseURL:window.extendifyData.root,headers:{"X-WP-Nonce":window.extendifyData.nonce,"X-Requested-With":"XMLHttpRequest","X-Extendify-Library":!0,"X-Extendify":!0}});var Zn,er,tr;function nr(e){return Object.prototype.hasOwnProperty.call(e,"data")?e.data:e}Qn.interceptors.response.use((e=>function(e){return Object.prototype.hasOwnProperty.call(e,"soft_error")&&window.dispatchEvent(new CustomEvent("extendify::softerror-encountered",{detail:e.soft_error,bubbles:!0})),e}(nr(e))),(e=>function(e){if(e.response)return console.error(e.response),Promise.reject(nr(e.response))}(e))),Qn.interceptors.request.use((e=>function(e){return e.headers["X-Extendify-Dev-Mode"]=window.location.search.indexOf("DEVMODE")>-1,e.headers["X-Extendify-Local-Mode"]=window.location.search.indexOf("LOCALMODE")>-1,e}(function(e){const t=Yn.getState(),n=t.apiKey?"unlimited":t.remainingImports();return e.data&&(e.data.remaining_imports=n,e.data.entry_point=t.entryPoint,e.data.total_imports=t.imports),e}(e))),(e=>e));const rr={getData(){return Qn.get("site-settings")},setData(e){const t=new FormData;return t.append("data",JSON.stringify(e)),Qn.post("site-settings",t,{headers:{"Content-Type":"multipart/form-data"}})},updateOption(e,t){return Qn.post("site-settings/options",{option:e,value:t})},addUtilsToGlobalStyles(){return Qn.post("site-settings/add-utils-to-global-styles")}},or=Object.assign(document.createElement("div"),{id:"extendify-deactivation-prompt"});document.body.append(or),(0,e.render)((0,e.createElement)((function(){const[o,i]=(0,e.useState)(!1),a=(0,e.useRef)(!1),u=(0,e.useRef)(null),l="#deactivate-extendify",c=()=>{a.current=!0,i(!1),document.querySelector(l).click()};return(0,e.useEffect)((()=>{const e=document.querySelector(l);if(!e)return;const t=e=>{a.current||(e.preventDefault(),i(!0))};return e.addEventListener("click",t),()=>{e.removeEventListener("click",t)}}),[i]),(0,e.createElement)(Ze,{as:"div",className:"extendify extendify-deactivation-prompt-modal",open:o,initialFocus:u,onClose:()=>i(!1)},(0,e.createElement)("div",{className:"fixed top-0 mx-auto w-full h-full overflow-hidden p-2 md:p-6 md:flex justify-center items-center z-high"},(0,e.createElement)("div",{className:"fixed inset-0 bg-black bg-opacity-40 transition-opacity","aria-hidden":"true"}),(0,e.createElement)("div",{className:"sm:flex relative shadow-2xl sm:overflow-hidden mx-auto bg-white flex flex-col sm:min-w-md rounded-sm"},(0,e.createElement)("div",{className:"flex items-center justify-between"},(0,e.createElement)(Ze.Title,{className:"m-0 px-6 text-base text-gray-900"},(0,n.__)("Keep styles?","extendify")),(0,e.createElement)(t.Button,{className:"border-0 cursor-pointer m-4",onClick:()=>i(!1),icon:(0,e.createElement)(r,{icon:s,size:24}),label:(0,n.__)("Close Modal","extendify"),showTooltip:!1})),(0,e.createElement)("div",{className:"m-0 p-6 pt-0 text-left relative max-w-lg"},(0,e.createElement)("p",{className:"mt-0"},(0,n.__)('We detected that you have added some designs from the Site Launcher or Design Library. Click "yes" below to add the styles to your theme (as Additional CSS) so they continue to display properly on your site.',"extendify")),(0,e.createElement)("div",{className:"flex justify-end gap-4"},(0,e.createElement)(t.Button,{ref:u,className:"components-button bg-design-main text-design-text is-primary",onClick:()=>{rr.addUtilsToGlobalStyles().finally(c)},showTooltip:!1},(0,n.__)("Yes, add styles","extendify")),(0,e.createElement)(t.Button,{className:"components-button bg-design-main text-design-text is-primary",onClick:c,showTooltip:!1},(0,n.__)("Deactivate only","extendify")))))))}),null),or)}()}();