@vezham/hooks 0.2.0-poc-env-1 → 0.2.0-poc-env-1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.js +19 -21
- package/index.mjs +1320 -1520
- package/package.json +9 -9
package/index.js
CHANGED
|
@@ -1,27 +1,25 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const u=require("react"),Er=require("react-dom");var ze=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Sr(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function xr(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var ae={exports:{}};const Tr={},Rr=Object.freeze(Object.defineProperty({__proto__:null,default:Tr},Symbol.toStringTag,{value:"Module"})),Ze=xr(Rr),_r="16.4.7",Or={version:_r},xt=Ze,Dt=Ze,Cr=Ze,Nr=Ze,kr=Or,Mt=kr.version,Ar=/(?:^|^)\s*(?:export\s+)?([\w.-]+)(?:\s*=\s*?|:\s+?)(\s*'(?:\\'|[^'])*'|\s*"(?:\\"|[^"])*"|\s*`(?:\\`|[^`])*`|[^#\r\n]+)?\s*(?:#.*)?(?:$|$)/mg;function Lr(e){const t={};let n=e.toString();n=n.replace(/\r\n?/mg,`
|
|
2
|
-
`);let r;for(;(r=Ar.exec(n))!=null;){const o=r[1];let s=r[2]||"";s=s.trim();const a=s[0];s=s.replace(/^(['"`])([\s\S]*)\1$/mg,"$2"),a==='"'&&(s=s.replace(/\\n/g,`
|
|
3
|
-
`),s=s.replace(/\\r/g,"\r")),t[o]=s}return t}function Dr(e){const t=_n(e),n=I.configDotenv({path:t});if(!n.parsed){const a=new Error(`MISSING_DATA: Cannot parse ${t} for an unknown reason`);throw a.code="MISSING_DATA",a}const r=Rn(e).split(","),o=r.length;let s;for(let a=0;a<o;a++)try{const i=r[a].trim(),d=Pr(n,i);s=I.decrypt(d.ciphertext,d.key);break}catch(i){if(a+1>=o)throw i}return I.parse(s)}function Mr(e){console.log(`[dotenv@${Mt}][INFO] ${e}`)}function Ir(e){console.log(`[dotenv@${Mt}][WARN] ${e}`)}function Ge(e){console.log(`[dotenv@${Mt}][DEBUG] ${e}`)}function Rn(e){return e&&e.DOTENV_KEY&&e.DOTENV_KEY.length>0?e.DOTENV_KEY:process.env.DOTENV_KEY&&process.env.DOTENV_KEY.length>0?process.env.DOTENV_KEY:""}function Pr(e,t){let n;try{n=new URL(t)}catch(i){if(i.code==="ERR_INVALID_URL"){const d=new Error("INVALID_DOTENV_KEY: Wrong format. Must be in valid uri format like dotenv://:key_1234@dotenvx.com/vault/.env.vault?environment=development");throw d.code="INVALID_DOTENV_KEY",d}throw i}const r=n.password;if(!r){const i=new Error("INVALID_DOTENV_KEY: Missing key part");throw i.code="INVALID_DOTENV_KEY",i}const o=n.searchParams.get("environment");if(!o){const i=new Error("INVALID_DOTENV_KEY: Missing environment part");throw i.code="INVALID_DOTENV_KEY",i}const s=`DOTENV_VAULT_${o.toUpperCase()}`,a=e.parsed[s];if(!a){const i=new Error(`NOT_FOUND_DOTENV_ENVIRONMENT: Cannot locate environment ${s} in your .env.vault file.`);throw i.code="NOT_FOUND_DOTENV_ENVIRONMENT",i}return{ciphertext:a,key:r}}function _n(e){let t=null;if(e&&e.path&&e.path.length>0)if(Array.isArray(e.path))for(const n of e.path)xt.existsSync(n)&&(t=n.endsWith(".vault")?n:`${n}.vault`);else t=e.path.endsWith(".vault")?e.path:`${e.path}.vault`;else t=Dt.resolve(process.cwd(),".env.vault");return xt.existsSync(t)?t:null}function Jt(e){return e[0]==="~"?Dt.join(Cr.homedir(),e.slice(1)):e}function Br(e){Mr("Loading env from encrypted .env.vault");const t=I._parseVault(e);let n=process.env;return e&&e.processEnv!=null&&(n=e.processEnv),I.populate(n,t,e),{parsed:t}}function Fr(e){const t=Dt.resolve(process.cwd(),".env");let n="utf8";const r=!!(e&&e.debug);e&&e.encoding?n=e.encoding:r&&Ge("No encoding is specified. UTF-8 is used by default");let o=[t];if(e&&e.path)if(!Array.isArray(e.path))o=[Jt(e.path)];else{o=[];for(const d of e.path)o.push(Jt(d))}let s;const a={};for(const d of o)try{const c=I.parse(xt.readFileSync(d,{encoding:n}));I.populate(a,c,e)}catch(c){r&&Ge(`Failed to load ${d} ${c.message}`),s=c}let i=process.env;return e&&e.processEnv!=null&&(i=e.processEnv),I.populate(i,a,e),s?{parsed:a,error:s}:{parsed:a}}function Ur(e){if(Rn(e).length===0)return I.configDotenv(e);const t=_n(e);return t?I._configVault(e):(Ir(`You set DOTENV_KEY but you are missing a .env.vault file at ${t}. Did you forget to build it?`),I.configDotenv(e))}function jr(e,t){const n=Buffer.from(t.slice(-64),"hex");let r=Buffer.from(e,"base64");const o=r.subarray(0,12),s=r.subarray(-16);r=r.subarray(12,-16);try{const a=Nr.createDecipheriv("aes-256-gcm",n,o);return a.setAuthTag(s),`${a.update(r)}${a.final()}`}catch(a){const i=a instanceof RangeError,d=a.message==="Invalid key length",c=a.message==="Unsupported state or unable to authenticate data";if(i||d){const f=new Error("INVALID_DOTENV_KEY: It must be 64 characters long (or more)");throw f.code="INVALID_DOTENV_KEY",f}else if(c){const f=new Error("DECRYPTION_FAILED: Please check your DOTENV_KEY");throw f.code="DECRYPTION_FAILED",f}else throw a}}function $r(e,t,n={}){const r=!!(n&&n.debug),o=!!(n&&n.override);if(typeof t!="object"){const s=new Error("OBJECT_REQUIRED: Please check the processEnv argument being passed to populate");throw s.code="OBJECT_REQUIRED",s}for(const s of Object.keys(t))Object.prototype.hasOwnProperty.call(e,s)?(o===!0&&(e[s]=t[s]),r&&Ge(o===!0?`"${s}" is already defined and WAS overwritten`:`"${s}" is already defined and was NOT overwritten`)):e[s]=t[s]}const I={configDotenv:Fr,_configVault:Br,_parseVault:Dr,config:Ur,decrypt:jr,parse:Lr,populate:$r};ae.exports.configDotenv=I.configDotenv;ae.exports._configVault=I._configVault;ae.exports._parseVault=I._parseVault;ae.exports.config=I.config;ae.exports.decrypt=I.decrypt;ae.exports.parse=I.parse;ae.exports.populate=I.populate;ae.exports=I;var zr=ae.exports;const Se={};process.env.DOTENV_CONFIG_ENCODING!=null&&(Se.encoding=process.env.DOTENV_CONFIG_ENCODING);process.env.DOTENV_CONFIG_PATH!=null&&(Se.path=process.env.DOTENV_CONFIG_PATH);process.env.DOTENV_CONFIG_DEBUG!=null&&(Se.debug=process.env.DOTENV_CONFIG_DEBUG);process.env.DOTENV_CONFIG_OVERRIDE!=null&&(Se.override=process.env.DOTENV_CONFIG_OVERRIDE);process.env.DOTENV_CONFIG_DOTENV_KEY!=null&&(Se.DOTENV_KEY=process.env.DOTENV_CONFIG_DOTENV_KEY);var Hr=Se;const Vr=/^dotenv_config_(encoding|path|debug|override|DOTENV_KEY)=(.+)$/;var qr=function(t){return t.reduce(function(n,r){const o=r.match(Vr);return o&&(n[o[1]]=o[2]),n},{})};(function(){zr.config(Object.assign({},Hr,qr(process.argv)))})();const Wr={BASE_URL:"/",DEV:!1,MODE:"production",PROD:!0,SSR:!1};console.log("import");console.table({...Wr});console.log("process");console.table({...process.env});const re={...process.env};console.table(re);const Kr=re.NODE_ENV!=="production",Yr=re.V_IS_DEBUG==="true",Ce=re.V_APP_NAME||"v0xapp",Gt=re.V_BASE_API_URL||"api",Jr=()=>Gt==="local"?re.V_MOCK_LOCAL_API_URL:Gt==="mock"?re.V_MOCK_API_URL:config.domain_type===IAM.DomainType.SANDBOX?re.V_APP_SANDBOX_API_URL:config.domain_type===IAM.DomainType.DC?re.V_APP_DC_API_URL:re.V_APP_API_URL,Gr=()=>new Date().toISOString(),Ne=(e,t,n)=>`[vezham] [${Gr()}] [${e}] [${t}] ${n}`,ht=()=>!Kr,F={log:(e=Ce,t,n)=>{console.log(Ne("LOG",e,t),n||"")},debug:(e=Ce,t,n)=>{Yr&&console.info(Ne("DEBUG",e,t),n||"")},info:(e=Ce,t,n)=>{ht()||console.info(Ne("INFO",e,t),n||"")},warn:(e=Ce,t,n)=>{ht()||console.warn(Ne("WARN",e,t),n||"")},error:(e=Ce,t,n)=>{ht()||console.error(Ne("ERROR",e,t),n||"")}};var Xr=e=>{switch(e){case"success":return eo;case"info":return no;case"warning":return to;case"error":return ro;default:return null}},Qr=Array(12).fill(0),Zr=({visible:e,className:t})=>u.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},u.createElement("div",{className:"sonner-spinner"},Qr.map((n,r)=>u.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${r}`})))),eo=u.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},u.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),to=u.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},u.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),no=u.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},u.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),ro=u.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},u.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),oo=u.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},u.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),u.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),so=()=>{let[e,t]=u.useState(document.hidden);return u.useEffect(()=>{let n=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",n),()=>window.removeEventListener("visibilitychange",n)},[]),e},Tt=1,ao=class{constructor(){this.subscribe=e=>(this.subscribers.push(e),()=>{let t=this.subscribers.indexOf(e);this.subscribers.splice(t,1)}),this.publish=e=>{this.subscribers.forEach(t=>t(e))},this.addToast=e=>{this.publish(e),this.toasts=[...this.toasts,e]},this.create=e=>{var t;let{message:n,...r}=e,o=typeof(e==null?void 0:e.id)=="number"||((t=e.id)==null?void 0:t.length)>0?e.id:Tt++,s=this.toasts.find(i=>i.id===o),a=e.dismissible===void 0?!0:e.dismissible;return this.dismissedToasts.has(o)&&this.dismissedToasts.delete(o),s?this.toasts=this.toasts.map(i=>i.id===o?(this.publish({...i,...e,id:o,title:n}),{...i,...e,id:o,dismissible:a,title:n}):i):this.addToast({title:n,...r,dismissible:a,id:o}),o},this.dismiss=e=>(this.dismissedToasts.add(e),e||this.toasts.forEach(t=>{this.subscribers.forEach(n=>n({id:t.id,dismiss:!0}))}),this.subscribers.forEach(t=>t({id:e,dismiss:!0})),e),this.message=(e,t)=>this.create({...t,message:e}),this.error=(e,t)=>this.create({...t,message:e,type:"error"}),this.success=(e,t)=>this.create({...t,type:"success",message:e}),this.info=(e,t)=>this.create({...t,type:"info",message:e}),this.warning=(e,t)=>this.create({...t,type:"warning",message:e}),this.loading=(e,t)=>this.create({...t,type:"loading",message:e}),this.promise=(e,t)=>{if(!t)return;let n;t.loading!==void 0&&(n=this.create({...t,promise:e,type:"loading",message:t.loading,description:typeof t.description!="function"?t.description:void 0}));let r=e instanceof Promise?e:e(),o=n!==void 0,s,a=r.then(async d=>{if(s=["resolve",d],u.isValidElement(d))o=!1,this.create({id:n,type:"default",message:d});else if(lo(d)&&!d.ok){o=!1;let c=typeof t.error=="function"?await t.error(`HTTP error! status: ${d.status}`):t.error,f=typeof t.description=="function"?await t.description(`HTTP error! status: ${d.status}`):t.description;this.create({id:n,type:"error",message:c,description:f})}else if(t.success!==void 0){o=!1;let c=typeof t.success=="function"?await t.success(d):t.success,f=typeof t.description=="function"?await t.description(d):t.description;this.create({id:n,type:"success",message:c,description:f})}}).catch(async d=>{if(s=["reject",d],t.error!==void 0){o=!1;let c=typeof t.error=="function"?await t.error(d):t.error,f=typeof t.description=="function"?await t.description(d):t.description;this.create({id:n,type:"error",message:c,description:f})}}).finally(()=>{var d;o&&(this.dismiss(n),n=void 0),(d=t.finally)==null||d.call(t)}),i=()=>new Promise((d,c)=>a.then(()=>s[0]==="reject"?c(s[1]):d(s[1])).catch(c));return typeof n!="string"&&typeof n!="number"?{unwrap:i}:Object.assign(n,{unwrap:i})},this.custom=(e,t)=>{let n=(t==null?void 0:t.id)||Tt++;return this.create({jsx:e(n),id:n,...t}),n},this.getActiveToasts=()=>this.toasts.filter(e=>!this.dismissedToasts.has(e.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}},z=new ao,io=(e,t)=>{let n=(t==null?void 0:t.id)||Tt++;return z.addToast({title:e,...t,id:n}),n},lo=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",co=io,uo=()=>z.toasts,fo=()=>z.getActiveToasts(),po=Object.assign(co,{success:z.success,info:z.info,warning:z.warning,error:z.error,custom:z.custom,message:z.message,promise:z.promise,dismiss:z.dismiss,loading:z.loading},{getHistory:uo,getToasts:fo});function ho(e,{insertAt:t}={}){if(typeof document>"u")return;let n=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",t==="top"&&n.firstChild?n.insertBefore(r,n.firstChild):n.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}ho(`:where(html[dir="ltr"]),:where([data-sonner-toaster][dir="ltr"]){--toast-icon-margin-start: -3px;--toast-icon-margin-end: 4px;--toast-svg-margin-start: -1px;--toast-svg-margin-end: 0px;--toast-button-margin-start: auto;--toast-button-margin-end: 0;--toast-close-button-start: 0;--toast-close-button-end: unset;--toast-close-button-transform: translate(-35%, -35%)}:where(html[dir="rtl"]),:where([data-sonner-toaster][dir="rtl"]){--toast-icon-margin-start: 4px;--toast-icon-margin-end: -3px;--toast-svg-margin-start: 0px;--toast-svg-margin-end: -1px;--toast-button-margin-start: 0;--toast-button-margin-end: auto;--toast-close-button-start: unset;--toast-close-button-end: 0;--toast-close-button-transform: translate(35%, -35%)}:where([data-sonner-toaster]){position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1: hsl(0, 0%, 99%);--gray2: hsl(0, 0%, 97.3%);--gray3: hsl(0, 0%, 95.1%);--gray4: hsl(0, 0%, 93%);--gray5: hsl(0, 0%, 90.9%);--gray6: hsl(0, 0%, 88.7%);--gray7: hsl(0, 0%, 85.8%);--gray8: hsl(0, 0%, 78%);--gray9: hsl(0, 0%, 56.1%);--gray10: hsl(0, 0%, 52.3%);--gray11: hsl(0, 0%, 43.5%);--gray12: hsl(0, 0%, 9%);--border-radius: 8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:none;z-index:999999999;transition:transform .4s ease}:where([data-sonner-toaster][data-lifted="true"]){transform:translateY(-10px)}@media (hover: none) and (pointer: coarse){:where([data-sonner-toaster][data-lifted="true"]){transform:none}}:where([data-sonner-toaster][data-x-position="right"]){right:var(--offset-right)}:where([data-sonner-toaster][data-x-position="left"]){left:var(--offset-left)}:where([data-sonner-toaster][data-x-position="center"]){left:50%;transform:translate(-50%)}:where([data-sonner-toaster][data-y-position="top"]){top:var(--offset-top)}:where([data-sonner-toaster][data-y-position="bottom"]){bottom:var(--offset-bottom)}:where([data-sonner-toast]){--y: translateY(100%);--lift-amount: calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);filter:blur(0);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:none;overflow-wrap:anywhere}:where([data-sonner-toast][data-styled="true"]){padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px #0000001a;width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}:where([data-sonner-toast]:focus-visible){box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast][data-y-position="top"]){top:0;--y: translateY(-100%);--lift: 1;--lift-amount: calc(1 * var(--gap))}:where([data-sonner-toast][data-y-position="bottom"]){bottom:0;--y: translateY(100%);--lift: -1;--lift-amount: calc(var(--lift) * var(--gap))}:where([data-sonner-toast]) :where([data-description]){font-weight:400;line-height:1.4;color:inherit}:where([data-sonner-toast]) :where([data-title]){font-weight:500;line-height:1.5;color:inherit}:where([data-sonner-toast]) :where([data-icon]){display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}:where([data-sonner-toast][data-promise="true"]) :where([data-icon])>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}:where([data-sonner-toast]) :where([data-icon])>*{flex-shrink:0}:where([data-sonner-toast]) :where([data-icon]) svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}:where([data-sonner-toast]) :where([data-content]){display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;cursor:pointer;outline:none;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}:where([data-sonner-toast]) :where([data-button]):focus-visible{box-shadow:0 0 0 2px #0006}:where([data-sonner-toast]) :where([data-button]):first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}:where([data-sonner-toast]) :where([data-cancel]){color:var(--normal-text);background:rgba(0,0,0,.08)}:where([data-sonner-toast][data-theme="dark"]) :where([data-cancel]){background:rgba(255,255,255,.3)}:where([data-sonner-toast]) :where([data-close-button]){position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast] [data-close-button]{background:var(--gray1)}:where([data-sonner-toast]) :where([data-close-button]):focus-visible{box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast]) :where([data-disabled="true"]){cursor:not-allowed}:where([data-sonner-toast]):hover :where([data-close-button]):hover{background:var(--gray2);border-color:var(--gray5)}:where([data-sonner-toast][data-swiping="true"]):before{content:"";position:absolute;left:-50%;right:-50%;height:100%;z-index:-1}:where([data-sonner-toast][data-y-position="top"][data-swiping="true"]):before{bottom:50%;transform:scaleY(3) translateY(50%)}:where([data-sonner-toast][data-y-position="bottom"][data-swiping="true"]):before{top:50%;transform:scaleY(3) translateY(-50%)}:where([data-sonner-toast][data-swiping="false"][data-removed="true"]):before{content:"";position:absolute;inset:0;transform:scaleY(2)}:where([data-sonner-toast]):after{content:"";position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}:where([data-sonner-toast][data-mounted="true"]){--y: translateY(0);opacity:1}:where([data-sonner-toast][data-expanded="false"][data-front="false"]){--scale: var(--toasts-before) * .05 + 1;--y: translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}:where([data-sonner-toast])>*{transition:opacity .4s}:where([data-sonner-toast][data-expanded="false"][data-front="false"][data-styled="true"])>*{opacity:0}:where([data-sonner-toast][data-visible="false"]){opacity:0;pointer-events:none}:where([data-sonner-toast][data-mounted="true"][data-expanded="true"]){--y: translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}:where([data-sonner-toast][data-removed="true"][data-front="true"][data-swipe-out="false"]){--y: translateY(calc(var(--lift) * -100%));opacity:0}:where([data-sonner-toast][data-removed="true"][data-front="false"][data-swipe-out="false"][data-expanded="true"]){--y: translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}:where([data-sonner-toast][data-removed="true"][data-front="false"][data-swipe-out="false"][data-expanded="false"]){--y: translateY(40%);opacity:0;transition:transform .5s,opacity .2s}:where([data-sonner-toast][data-removed="true"][data-front="false"]):before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y, 0px)) translate(var(--swipe-amount-x, 0px));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{0%{transform:var(--y) translate(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translate(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{0%{transform:var(--y) translate(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translate(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{0%{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{0%{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width: 600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-theme=light]{--normal-bg: #fff;--normal-border: var(--gray4);--normal-text: var(--gray12);--success-bg: hsl(143, 85%, 96%);--success-border: hsl(145, 92%, 91%);--success-text: hsl(140, 100%, 27%);--info-bg: hsl(208, 100%, 97%);--info-border: hsl(221, 91%, 91%);--info-text: hsl(210, 92%, 45%);--warning-bg: hsl(49, 100%, 97%);--warning-border: hsl(49, 91%, 91%);--warning-text: hsl(31, 92%, 45%);--error-bg: hsl(359, 100%, 97%);--error-border: hsl(359, 100%, 94%);--error-text: hsl(360, 100%, 45%)}[data-sonner-toaster][data-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg: #000;--normal-border: hsl(0, 0%, 20%);--normal-text: var(--gray1)}[data-sonner-toaster][data-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg: #fff;--normal-border: var(--gray3);--normal-text: var(--gray12)}[data-sonner-toaster][data-theme=dark]{--normal-bg: #000;--normal-bg-hover: hsl(0, 0%, 12%);--normal-border: hsl(0, 0%, 20%);--normal-border-hover: hsl(0, 0%, 25%);--normal-text: var(--gray1);--success-bg: hsl(150, 100%, 6%);--success-border: hsl(147, 100%, 12%);--success-text: hsl(150, 86%, 65%);--info-bg: hsl(215, 100%, 6%);--info-border: hsl(223, 100%, 12%);--info-text: hsl(216, 87%, 65%);--warning-bg: hsl(64, 100%, 6%);--warning-border: hsl(60, 100%, 12%);--warning-text: hsl(46, 87%, 65%);--error-bg: hsl(358, 76%, 10%);--error-border: hsl(357, 89%, 16%);--error-text: hsl(358, 100%, 81%)}[data-sonner-toaster][data-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success],[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info],[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning],[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error],[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size: 16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:nth-child(1){animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}to{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}to{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}to{opacity:.15}}@media (prefers-reduced-motion){[data-sonner-toast],[data-sonner-toast]>*,.sonner-loading-bar{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}
|
|
4
|
-
`);function He(e){return e.label!==void 0}var mo=3,go="32px",wo="16px",Xt=4e3,yo=356,bo=14,vo=20,Eo=200;function Z(...e){return e.filter(Boolean).join(" ")}function So(e){let[t,n]=e.split("-"),r=[];return t&&r.push(t),n&&r.push(n),r}var xo=e=>{var t,n,r,o,s,a,i,d,c,f,m;let{invert:h,toast:l,unstyled:w,interacting:g,setHeights:y,visibleToasts:T,heights:S,index:R,toasts:B,expanded:k,removeToast:E,defaultRichColors:D,closeButton:j,style:te,cancelButtonStyle:it,actionButtonStyle:Pe,className:oe="",descriptionClassName:Be="",duration:ge,position:Fe,gap:ue,loadingIcon:se,expandByDefault:Ue,classNames:x,icons:q,closeButtonAriaLabel:lt="Close toast",pauseWhenPageIsHidden:C}=e,[N,L]=u.useState(null),[$,we]=u.useState(null),[M,ct]=u.useState(!1),[Re,je]=u.useState(!1),[_e,ut]=u.useState(!1),[$t,lr]=u.useState(!1),[cr,zt]=u.useState(!1),[ur,dt]=u.useState(0),[dr,Ht]=u.useState(0),Oe=u.useRef(l.duration||ge||Xt),Vt=u.useRef(null),de=u.useRef(null),fr=R===0,pr=R+1<=T,Y=l.type,ye=l.dismissible!==!1,hr=l.className||"",mr=l.descriptionClassName||"",$e=u.useMemo(()=>S.findIndex(b=>b.toastId===l.id)||0,[S,l.id]),gr=u.useMemo(()=>{var b;return(b=l.closeButton)!=null?b:j},[l.closeButton,j]),qt=u.useMemo(()=>l.duration||ge||Xt,[l.duration,ge]),ft=u.useRef(0),be=u.useRef(0),Wt=u.useRef(0),ve=u.useRef(null),[wr,yr]=Fe.split("-"),Kt=u.useMemo(()=>S.reduce((b,_,A)=>A>=$e?b:b+_.height,0),[S,$e]),Yt=so(),br=l.invert||h,pt=Y==="loading";be.current=u.useMemo(()=>$e*ue+Kt,[$e,Kt]),u.useEffect(()=>{Oe.current=qt},[qt]),u.useEffect(()=>{ct(!0)},[]),u.useEffect(()=>{let b=de.current;if(b){let _=b.getBoundingClientRect().height;return Ht(_),y(A=>[{toastId:l.id,height:_,position:l.position},...A]),()=>y(A=>A.filter(G=>G.toastId!==l.id))}},[y,l.id]),u.useLayoutEffect(()=>{if(!M)return;let b=de.current,_=b.style.height;b.style.height="auto";let A=b.getBoundingClientRect().height;b.style.height=_,Ht(A),y(G=>G.find(X=>X.toastId===l.id)?G.map(X=>X.toastId===l.id?{...X,height:A}:X):[{toastId:l.id,height:A,position:l.position},...G])},[M,l.title,l.description,y,l.id]);let ie=u.useCallback(()=>{je(!0),dt(be.current),y(b=>b.filter(_=>_.toastId!==l.id)),setTimeout(()=>{E(l)},Eo)},[l,E,y,be]);u.useEffect(()=>{if(l.promise&&Y==="loading"||l.duration===1/0||l.type==="loading")return;let b;return k||g||C&&Yt?(()=>{if(Wt.current<ft.current){let _=new Date().getTime()-ft.current;Oe.current=Oe.current-_}Wt.current=new Date().getTime()})():Oe.current!==1/0&&(ft.current=new Date().getTime(),b=setTimeout(()=>{var _;(_=l.onAutoClose)==null||_.call(l,l),ie()},Oe.current)),()=>clearTimeout(b)},[k,g,l,Y,C,Yt,ie]),u.useEffect(()=>{l.delete&&ie()},[ie,l.delete]);function vr(){var b,_,A;return q!=null&&q.loading?u.createElement("div",{className:Z(x==null?void 0:x.loader,(b=l==null?void 0:l.classNames)==null?void 0:b.loader,"sonner-loader"),"data-visible":Y==="loading"},q.loading):se?u.createElement("div",{className:Z(x==null?void 0:x.loader,(_=l==null?void 0:l.classNames)==null?void 0:_.loader,"sonner-loader"),"data-visible":Y==="loading"},se):u.createElement(Zr,{className:Z(x==null?void 0:x.loader,(A=l==null?void 0:l.classNames)==null?void 0:A.loader),visible:Y==="loading"})}return u.createElement("li",{tabIndex:0,ref:de,className:Z(oe,hr,x==null?void 0:x.toast,(t=l==null?void 0:l.classNames)==null?void 0:t.toast,x==null?void 0:x.default,x==null?void 0:x[Y],(n=l==null?void 0:l.classNames)==null?void 0:n[Y]),"data-sonner-toast":"","data-rich-colors":(r=l.richColors)!=null?r:D,"data-styled":!(l.jsx||l.unstyled||w),"data-mounted":M,"data-promise":!!l.promise,"data-swiped":cr,"data-removed":Re,"data-visible":pr,"data-y-position":wr,"data-x-position":yr,"data-index":R,"data-front":fr,"data-swiping":_e,"data-dismissible":ye,"data-type":Y,"data-invert":br,"data-swipe-out":$t,"data-swipe-direction":$,"data-expanded":!!(k||Ue&&M),style:{"--index":R,"--toasts-before":R,"--z-index":B.length-R,"--offset":`${Re?ur:be.current}px`,"--initial-height":Ue?"auto":`${dr}px`,...te,...l.style},onDragEnd:()=>{ut(!1),L(null),ve.current=null},onPointerDown:b=>{pt||!ye||(Vt.current=new Date,dt(be.current),b.target.setPointerCapture(b.pointerId),b.target.tagName!=="BUTTON"&&(ut(!0),ve.current={x:b.clientX,y:b.clientY}))},onPointerUp:()=>{var b,_,A,G;if($t||!ye)return;ve.current=null;let X=Number(((b=de.current)==null?void 0:b.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),le=Number(((_=de.current)==null?void 0:_.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),fe=new Date().getTime()-((A=Vt.current)==null?void 0:A.getTime()),Q=N==="x"?X:le,ce=Math.abs(Q)/fe;if(Math.abs(Q)>=vo||ce>.11){dt(be.current),(G=l.onDismiss)==null||G.call(l,l),we(N==="x"?X>0?"right":"left":le>0?"down":"up"),ie(),lr(!0),zt(!1);return}ut(!1),L(null)},onPointerMove:b=>{var _,A,G,X;if(!ve.current||!ye||((_=window.getSelection())==null?void 0:_.toString().length)>0)return;let le=b.clientY-ve.current.y,fe=b.clientX-ve.current.x,Q=(A=e.swipeDirections)!=null?A:So(Fe);!N&&(Math.abs(fe)>1||Math.abs(le)>1)&&L(Math.abs(fe)>Math.abs(le)?"x":"y");let ce={x:0,y:0};N==="y"?(Q.includes("top")||Q.includes("bottom"))&&(Q.includes("top")&&le<0||Q.includes("bottom")&&le>0)&&(ce.y=le):N==="x"&&(Q.includes("left")||Q.includes("right"))&&(Q.includes("left")&&fe<0||Q.includes("right")&&fe>0)&&(ce.x=fe),(Math.abs(ce.x)>0||Math.abs(ce.y)>0)&&zt(!0),(G=de.current)==null||G.style.setProperty("--swipe-amount-x",`${ce.x}px`),(X=de.current)==null||X.style.setProperty("--swipe-amount-y",`${ce.y}px`)}},gr&&!l.jsx?u.createElement("button",{"aria-label":lt,"data-disabled":pt,"data-close-button":!0,onClick:pt||!ye?()=>{}:()=>{var b;ie(),(b=l.onDismiss)==null||b.call(l,l)},className:Z(x==null?void 0:x.closeButton,(o=l==null?void 0:l.classNames)==null?void 0:o.closeButton)},(s=q==null?void 0:q.close)!=null?s:oo):null,l.jsx||u.isValidElement(l.title)?l.jsx?l.jsx:typeof l.title=="function"?l.title():l.title:u.createElement(u.Fragment,null,Y||l.icon||l.promise?u.createElement("div",{"data-icon":"",className:Z(x==null?void 0:x.icon,(a=l==null?void 0:l.classNames)==null?void 0:a.icon)},l.promise||l.type==="loading"&&!l.icon?l.icon||vr():null,l.type!=="loading"?l.icon||(q==null?void 0:q[Y])||Xr(Y):null):null,u.createElement("div",{"data-content":"",className:Z(x==null?void 0:x.content,(i=l==null?void 0:l.classNames)==null?void 0:i.content)},u.createElement("div",{"data-title":"",className:Z(x==null?void 0:x.title,(d=l==null?void 0:l.classNames)==null?void 0:d.title)},typeof l.title=="function"?l.title():l.title),l.description?u.createElement("div",{"data-description":"",className:Z(Be,mr,x==null?void 0:x.description,(c=l==null?void 0:l.classNames)==null?void 0:c.description)},typeof l.description=="function"?l.description():l.description):null),u.isValidElement(l.cancel)?l.cancel:l.cancel&&He(l.cancel)?u.createElement("button",{"data-button":!0,"data-cancel":!0,style:l.cancelButtonStyle||it,onClick:b=>{var _,A;He(l.cancel)&&ye&&((A=(_=l.cancel).onClick)==null||A.call(_,b),ie())},className:Z(x==null?void 0:x.cancelButton,(f=l==null?void 0:l.classNames)==null?void 0:f.cancelButton)},l.cancel.label):null,u.isValidElement(l.action)?l.action:l.action&&He(l.action)?u.createElement("button",{"data-button":!0,"data-action":!0,style:l.actionButtonStyle||Pe,onClick:b=>{var _,A;He(l.action)&&((A=(_=l.action).onClick)==null||A.call(_,b),!b.defaultPrevented&&ie())},className:Z(x==null?void 0:x.actionButton,(m=l==null?void 0:l.classNames)==null?void 0:m.actionButton)},l.action.label):null))};function Qt(){if(typeof window>"u"||typeof document>"u")return"ltr";let e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}function To(e,t){let n={};return[e,t].forEach((r,o)=>{let s=o===1,a=s?"--mobile-offset":"--offset",i=s?wo:go;function d(c){["top","right","bottom","left"].forEach(f=>{n[`${a}-${f}`]=typeof c=="number"?`${c}px`:c})}typeof r=="number"||typeof r=="string"?d(r):typeof r=="object"?["top","right","bottom","left"].forEach(c=>{r[c]===void 0?n[`${a}-${c}`]=i:n[`${a}-${c}`]=typeof r[c]=="number"?`${r[c]}px`:r[c]}):d(i)}),n}u.forwardRef(function(e,t){let{invert:n,position:r="bottom-right",hotkey:o=["altKey","KeyT"],expand:s,closeButton:a,className:i,offset:d,mobileOffset:c,theme:f="light",richColors:m,duration:h,style:l,visibleToasts:w=mo,toastOptions:g,dir:y=Qt(),gap:T=bo,loadingIcon:S,icons:R,containerAriaLabel:B="Notifications",pauseWhenPageIsHidden:k}=e,[E,D]=u.useState([]),j=u.useMemo(()=>Array.from(new Set([r].concat(E.filter(C=>C.position).map(C=>C.position)))),[E,r]),[te,it]=u.useState([]),[Pe,oe]=u.useState(!1),[Be,ge]=u.useState(!1),[Fe,ue]=u.useState(f!=="system"?f:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),se=u.useRef(null),Ue=o.join("+").replace(/Key/g,"").replace(/Digit/g,""),x=u.useRef(null),q=u.useRef(!1),lt=u.useCallback(C=>{D(N=>{var L;return(L=N.find($=>$.id===C.id))!=null&&L.delete||z.dismiss(C.id),N.filter(({id:$})=>$!==C.id)})},[]);return u.useEffect(()=>z.subscribe(C=>{if(C.dismiss){D(N=>N.map(L=>L.id===C.id?{...L,delete:!0}:L));return}setTimeout(()=>{Er.flushSync(()=>{D(N=>{let L=N.findIndex($=>$.id===C.id);return L!==-1?[...N.slice(0,L),{...N[L],...C},...N.slice(L+1)]:[C,...N]})})})}),[]),u.useEffect(()=>{if(f!=="system"){ue(f);return}if(f==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?ue("dark"):ue("light")),typeof window>"u")return;let C=window.matchMedia("(prefers-color-scheme: dark)");try{C.addEventListener("change",({matches:N})=>{ue(N?"dark":"light")})}catch{C.addListener(({matches:L})=>{try{ue(L?"dark":"light")}catch($){console.error($)}})}},[f]),u.useEffect(()=>{E.length<=1&&oe(!1)},[E]),u.useEffect(()=>{let C=N=>{var L,$;o.every(we=>N[we]||N.code===we)&&(oe(!0),(L=se.current)==null||L.focus()),N.code==="Escape"&&(document.activeElement===se.current||($=se.current)!=null&&$.contains(document.activeElement))&&oe(!1)};return document.addEventListener("keydown",C),()=>document.removeEventListener("keydown",C)},[o]),u.useEffect(()=>{if(se.current)return()=>{x.current&&(x.current.focus({preventScroll:!0}),x.current=null,q.current=!1)}},[se.current]),u.createElement("section",{ref:t,"aria-label":`${B} ${Ue}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},j.map((C,N)=>{var L;let[$,we]=C.split("-");return E.length?u.createElement("ol",{key:C,dir:y==="auto"?Qt():y,tabIndex:-1,ref:se,className:i,"data-sonner-toaster":!0,"data-theme":Fe,"data-y-position":$,"data-lifted":Pe&&E.length>1&&!s,"data-x-position":we,style:{"--front-toast-height":`${((L=te[0])==null?void 0:L.height)||0}px`,"--width":`${yo}px`,"--gap":`${T}px`,...l,...To(d,c)},onBlur:M=>{q.current&&!M.currentTarget.contains(M.relatedTarget)&&(q.current=!1,x.current&&(x.current.focus({preventScroll:!0}),x.current=null))},onFocus:M=>{M.target instanceof HTMLElement&&M.target.dataset.dismissible==="false"||q.current||(q.current=!0,x.current=M.relatedTarget)},onMouseEnter:()=>oe(!0),onMouseMove:()=>oe(!0),onMouseLeave:()=>{Be||oe(!1)},onDragEnd:()=>oe(!1),onPointerDown:M=>{M.target instanceof HTMLElement&&M.target.dataset.dismissible==="false"||ge(!0)},onPointerUp:()=>ge(!1)},E.filter(M=>!M.position&&N===0||M.position===C).map((M,ct)=>{var Re,je;return u.createElement(xo,{key:M.id,icons:R,index:ct,toast:M,defaultRichColors:m,duration:(Re=g==null?void 0:g.duration)!=null?Re:h,className:g==null?void 0:g.className,descriptionClassName:g==null?void 0:g.descriptionClassName,invert:n,visibleToasts:w,closeButton:(je=g==null?void 0:g.closeButton)!=null?je:a,interacting:Be,position:C,style:g==null?void 0:g.style,unstyled:g==null?void 0:g.unstyled,classNames:g==null?void 0:g.classNames,cancelButtonStyle:g==null?void 0:g.cancelButtonStyle,actionButtonStyle:g==null?void 0:g.actionButtonStyle,removeToast:lt,toasts:E.filter(_e=>_e.position==M.position),heights:te.filter(_e=>_e.position==M.position),setHeights:it,expandByDefault:s,gap:T,loadingIcon:S,expanded:Pe,pauseWhenPageIsHidden:k,swipeDirections:e.swipeDirections})})):null}))});function On(){return{toast:async({id:t,title:n,description:r,action:o={label:"",onClick:()=>{}},...s})=>{const a={description:r};o.label&&(a.action={label:o.label,onClick:o.onClick}),po(n,a)}}}var Ro="Expected a function",Zt=NaN,_o="[object Symbol]",Oo=/^\s+|\s+$/g,Co=/^[-+]0x[0-9a-f]+$/i,No=/^0b[01]+$/i,ko=/^0o[0-7]+$/i,Ao=parseInt,Lo=typeof ze=="object"&&ze&&ze.Object===Object&&ze,Do=typeof self=="object"&&self&&self.Object===Object&&self,Mo=Lo||Do||Function("return this")(),Io=Object.prototype,Po=Io.toString,Bo=Math.max,Fo=Math.min,mt=function(){return Mo.Date.now()};function Uo(e,t,n){var r,o,s,a,i,d,c=0,f=!1,m=!1,h=!0;if(typeof e!="function")throw new TypeError(Ro);t=en(t)||0,Rt(n)&&(f=!!n.leading,m="maxWait"in n,s=m?Bo(en(n.maxWait)||0,t):s,h="trailing"in n?!!n.trailing:h);function l(E){var D=r,j=o;return r=o=void 0,c=E,a=e.apply(j,D),a}function w(E){return c=E,i=setTimeout(T,t),f?l(E):a}function g(E){var D=E-d,j=E-c,te=t-D;return m?Fo(te,s-j):te}function y(E){var D=E-d,j=E-c;return d===void 0||D>=t||D<0||m&&j>=s}function T(){var E=mt();if(y(E))return S(E);i=setTimeout(T,g(E))}function S(E){return i=void 0,h&&r?l(E):(r=o=void 0,a)}function R(){i!==void 0&&clearTimeout(i),c=0,r=d=o=i=void 0}function B(){return i===void 0?a:S(mt())}function k(){var E=mt(),D=y(E);if(r=arguments,o=this,d=E,D){if(i===void 0)return w(d);if(m)return i=setTimeout(T,t),l(d)}return i===void 0&&(i=setTimeout(T,t)),a}return k.cancel=R,k.flush=B,k}function Rt(e){var t=typeof e;return!!e&&(t=="object"||t=="function")}function jo(e){return!!e&&typeof e=="object"}function $o(e){return typeof e=="symbol"||jo(e)&&Po.call(e)==_o}function en(e){if(typeof e=="number")return e;if($o(e))return Zt;if(Rt(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=Rt(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=e.replace(Oo,"");var n=No.test(e);return n||ko.test(e)?Ao(e.slice(2),n?2:8):Co.test(e)?Zt:+e}var zo=Uo;const tn=Sr(zo);function Cn(e=!1){if(typeof e!="boolean")throw new Error("defaultValue must be `true` or `false`");const[t,n]=u.useState(e),r=u.useCallback(()=>{n(!0)},[]),o=u.useCallback(()=>{n(!1)},[]),s=u.useCallback(()=>{n(a=>!a)},[]);return{value:t,setValue:n,setTrue:r,setFalse:o,toggle:s}}var J=typeof window<"u"?u.useLayoutEffect:u.useEffect;function V(e,t,n,r){const o=u.useRef(t);J(()=>{o.current=t},[t]),u.useEffect(()=>{const s=(n==null?void 0:n.current)??window;if(!(s&&s.addEventListener))return;const a=i=>{o.current(i)};return s.addEventListener(e,a,r),()=>{s.removeEventListener(e,a,r)}},[e,n,r])}function Ho(e){V("click",t=>{e(t)})}var gt="useCopyToClipboard";function Vo(){const[e,t]=u.useState(null),{toast:n}=On(),r=u.useCallback(async s=>{if(!(navigator!=null&&navigator.clipboard))return F.log(gt,"not supported"),!1;try{return await navigator.clipboard.writeText(s),t(s),!0}catch(a){return F.error(gt,"Copy failed",a),t(null),!1}},[]);return{value:e,copy:r,copyWithToast:async(s="",a="copied to clipboard")=>{const i=await r(s);return i&&(F.debug(gt,a),n({title:a})),i}}}function Nn(e){const[t,n]=u.useState(e??0),r=u.useCallback(()=>{n(a=>a+1)},[]),o=u.useCallback(()=>{n(a=>a-1)},[]),s=u.useCallback(()=>{n(e??0)},[e]);return{count:t,increment:r,decrement:o,reset:s,setCount:n}}function kn(e,t){const n=u.useRef(e);J(()=>{n.current=e},[e]),u.useEffect(()=>{if(t===null)return;const r=setInterval(()=>{n.current()},t);return()=>{clearInterval(r)}},[t])}function qo({countStart:e,countStop:t=0,intervalMs:n=1e3,isIncrement:r=!1}){const{count:o,increment:s,decrement:a,reset:i}=Nn(e),{value:d,setTrue:c,setFalse:f}=Cn(!1),m=u.useCallback(()=>{f(),i()},[f,i]),h=u.useCallback(()=>{if(o===t){f();return}r?s():a()},[o,t,a,s,r,f]);return kn(h,d?n:null),[o,{startCountdown:c,stopCountdown:f,resetCountdown:m}]}function Le(e){const t=u.useRef(()=>{throw new Error("Cannot call an event handler while rendering.")});return J(()=>{t.current=e},[e]),u.useCallback((...n)=>{var r;return(r=t.current)==null?void 0:r.call(t,...n)},[t])}var ke="useLocalStorage",wt=typeof window>"u";function It(e,t,n={}){const{initializeWithValue:r=!0}=n,o=u.useCallback(h=>n.serializer?n.serializer(h):JSON.stringify(h),[n]),s=u.useCallback(h=>{if(n.deserializer)return n.deserializer(h);if(h==="undefined")return;const l=t instanceof Function?t():t;let w;try{w=JSON.parse(h)}catch(g){return F.error(ke,"Error parsing JSON:",g),l}return w},[n,t]),a=u.useCallback(()=>{const h=t instanceof Function?t():t;if(wt)return h;try{const l=window.localStorage.getItem(e);return l?s(l):h}catch(l){return F.error(ke,`Error reading localStorage key “${e}”:`,l),h}},[t,e,s]),[i,d]=u.useState(()=>r?a():t instanceof Function?t():t),c=Le(h=>{wt&&F.warn(ke,`Tried setting localStorage key “${e}” even though environment is not a client`);try{const l=h instanceof Function?h(a()):h;window.localStorage.setItem(e,o(l)),d(l),window.dispatchEvent(new StorageEvent("local-storage",{key:e}))}catch(l){F.warn(ke,`Error setting localStorage key “${e}”:`,l)}}),f=Le(()=>{wt&&F.warn(ke,`Tried removing localStorage key “${e}” even though environment is not a client`);const h=t instanceof Function?t():t;window.localStorage.removeItem(e),d(h),window.dispatchEvent(new StorageEvent("local-storage",{key:e}))});u.useEffect(()=>{d(a())},[e]);const m=u.useCallback(h=>{h.key&&h.key!==e||d(a())},[e,a]);return V("storage",m),V("local-storage",m),[i,c,f]}var Wo=typeof window>"u";function Pt(e,{defaultValue:t=!1,initializeWithValue:n=!0}={}){const r=i=>Wo?t:window.matchMedia(i).matches,[o,s]=u.useState(()=>n?r(e):t);function a(){s(r(e))}return J(()=>{const i=window.matchMedia(e);return a(),i.addListener?i.addListener(a):i.addEventListener("change",a),()=>{i.removeListener?i.removeListener(a):i.removeEventListener("change",a)}},[e]),o}var Ko="(prefers-color-scheme: dark)",Yo="usehooks-ts-dark-mode";function Jo(e={}){const{defaultValue:t,localStorageKey:n=Yo,initializeWithValue:r=!0}=e,o=Pt(Ko,{initializeWithValue:r,defaultValue:t}),[s,a]=It(n,t??o??!1,{initializeWithValue:r});return J(()=>{o!==s&&a(o)},[o]),{isDarkMode:s,toggle:()=>{a(i=>!i)},enable:()=>{a(!0)},disable:()=>{a(!1)},set:i=>{a(i)}}}function Bt(e){const t=u.useRef(e);t.current=e,u.useEffect(()=>()=>{t.current()},[])}function et(e,t=500,n){const r=u.useRef();Bt(()=>{r.current&&r.current.cancel()});const o=u.useMemo(()=>{const s=tn(e,t,n),a=(...i)=>s(...i);return a.cancel=()=>{s.cancel()},a.isPending=()=>!!r.current,a.flush=()=>s.flush(),a},[e,t,n]);return u.useEffect(()=>{r.current=tn(e,t,n)},[e,t,n]),o}function Go(e,t,n){const r=(n==null?void 0:n.equalityFn)??((c,f)=>c===f),o=e instanceof Function?e():e,[s,a]=u.useState(o),i=u.useRef(o),d=et(a,t,n);return r(i.current,o)||(d(o),i.current=o),[s,d]}function Xo(e,t={}){const{preserveTitleOnUnmount:n=!0}=t,r=u.useRef(null);J(()=>{r.current=window.document.title},[]),J(()=>{window.document.title=e},[e]),Bt(()=>{!n&&r.current&&(window.document.title=r.current)})}function An(){const e=u.useRef(!0);return e.current?(e.current=!1,!0):e.current}function Qo(e,t){const n=An();u.useEffect(()=>{if(!n)return e()},t)}function Zo(e){const[t,n]=u.useState(!1),r=()=>{n(!0)},o=()=>{n(!1)};return V("mouseenter",r,e),V("mouseleave",o,e),t}function es({threshold:e=0,root:t=null,rootMargin:n="0%",freezeOnceVisible:r=!1,initialIsIntersecting:o=!1,onChange:s}={}){var a;const[i,d]=u.useState(null),[c,f]=u.useState(()=>({isIntersecting:o,entry:void 0})),m=u.useRef();m.current=s;const h=((a=c.entry)==null?void 0:a.isIntersecting)&&r;u.useEffect(()=>{if(!i||!("IntersectionObserver"in window)||h)return;const g=new IntersectionObserver(y=>{const T=Array.isArray(g.thresholds)?g.thresholds:[g.thresholds];y.forEach(S=>{const R=S.isIntersecting&&T.some(B=>S.intersectionRatio>=B);f({isIntersecting:R,entry:S}),m.current&&m.current(R,S)})},{threshold:e,root:t,rootMargin:n});return g.observe(i),()=>{g.disconnect()}},[i,JSON.stringify(e),t,n,h,r]);const l=u.useRef(null);u.useEffect(()=>{var g;!i&&((g=c.entry)!=null&&g.target)&&!r&&!h&&l.current!==c.entry.target&&(l.current=c.entry.target,f({isIntersecting:o,entry:void 0}))},[i,c.entry,r,h,o]);const w=[d,!!c.isIntersecting,c.entry];return w.ref=w[0],w.isIntersecting=w[1],w.entry=w[2],w}function ts(){const[e,t]=u.useState(!1);return u.useEffect(()=>{t(!0)},[]),e}function Ln(){const e=u.useRef(!1);return u.useEffect(()=>(e.current=!0,()=>{e.current=!1}),[]),u.useCallback(()=>e.current,[])}function ns(e=new Map){const[t,n]=u.useState(new Map(e)),r={set:u.useCallback((o,s)=>{n(a=>{const i=new Map(a);return i.set(o,s),i})},[]),setAll:u.useCallback(o=>{n(()=>new Map(o))},[]),remove:u.useCallback(o=>{n(s=>{const a=new Map(s);return a.delete(o),a})},[]),reset:u.useCallback(()=>{n(()=>new Map)},[])};return[t,r]}function rs(e,t,n="mousedown",r={}){V(n,o=>{const s=o.target;if(!(s!=null&&s.isConnected))return;(Array.isArray(e)?e.filter(i=>!!i.current).every(i=>i.current&&!i.current.contains(s)):e.current&&!e.current.contains(s))&&t(o)},void 0,r)}var nn=typeof window>"u";function os(e,t={}){let{initializeWithValue:n=!0}=t;nn&&(n=!1);const r=u.useCallback(d=>{if(t.deserializer)return t.deserializer(d);if(d==="undefined")return;let c;try{c=JSON.parse(d)}catch(f){return console.error("Error parsing JSON:",f),null}return c},[t]),o=u.useCallback(()=>{if(nn)return null;try{const d=window.localStorage.getItem(e);return d?r(d):null}catch(d){return console.warn(`Error reading localStorage key “${e}”:`,d),null}},[e,r]),[s,a]=u.useState(()=>{if(n)return o()});u.useEffect(()=>{a(o())},[e]);const i=u.useCallback(d=>{d.key&&d.key!==e||a(o())},[e,o]);return V("storage",i),V("local-storage",i),s}var rn={width:void 0,height:void 0};function ss(e){const{ref:t,box:n="content-box"}=e,[{width:r,height:o},s]=u.useState(rn),a=Ln(),i=u.useRef({...rn}),d=u.useRef(void 0);return d.current=e.onResize,u.useEffect(()=>{if(!t.current||typeof window>"u"||!("ResizeObserver"in window))return;const c=new ResizeObserver(([f])=>{const m=n==="border-box"?"borderBoxSize":n==="device-pixel-content-box"?"devicePixelContentBoxSize":"contentBoxSize",h=on(f,m,"inlineSize"),l=on(f,m,"blockSize");if(i.current.width!==h||i.current.height!==l){const g={width:h,height:l};i.current.width=h,i.current.height=l,d.current?d.current(g):a()&&s(g)}});return c.observe(t.current,{box:n}),()=>{c.disconnect()}},[n,t,a]),{width:r,height:o}}function on(e,t,n){return e[t]?Array.isArray(e[t])?e[t][0][n]:e[t][n]:t==="contentBoxSize"?e.contentRect[n==="inlineSize"?"width":"height"]:void 0}var sn=typeof window>"u";function as(e={}){let{initializeWithValue:t=!0}=e;sn&&(t=!1);const n=()=>{if(!sn)return window.screen},[r,o]=u.useState(()=>{if(t)return n()}),s=et(o,e.debounceDelay);function a(){const i=n(),d=e.debounceDelay?s:o;if(i){const{width:c,height:f,availHeight:m,availWidth:h,colorDepth:l,orientation:w,pixelDepth:g}=i;d({width:c,height:f,availHeight:m,availWidth:h,colorDepth:l,orientation:w,pixelDepth:g})}}return V("resize",a),J(()=>{a()},[]),r}var Ve=new Map;function is(e){const t=document.querySelector(`script[src="${e}"]`),n=t==null?void 0:t.getAttribute("data-status");return{node:t,status:n}}function ls(e,t){const[n,r]=u.useState(()=>!e||t!=null&&t.shouldPreventLoad?"idle":typeof window>"u"?"loading":Ve.get(e)??"loading");return u.useEffect(()=>{if(!e||t!=null&&t.shouldPreventLoad)return;const o=Ve.get(e);if(o==="ready"||o==="error"){r(o);return}const s=is(e);let a=s.node;if(a)r(s.status??o??"loading");else{a=document.createElement("script"),a.src=e,a.async=!0,t!=null&&t.id&&(a.id=t.id),a.setAttribute("data-status","loading"),document.body.appendChild(a);const d=c=>{const f=c.type==="load"?"ready":"error";a==null||a.setAttribute("data-status",f)};a.addEventListener("load",d),a.addEventListener("error",d)}const i=d=>{const c=d.type==="load"?"ready":"error";r(c),Ve.set(e,c)};return a.addEventListener("load",i),a.addEventListener("error",i),()=>{a&&(a.removeEventListener("load",i),a.removeEventListener("error",i)),a&&(t!=null&&t.removeOnUnmount)&&(a.remove(),Ve.delete(e))}},[e,t==null?void 0:t.shouldPreventLoad,t==null?void 0:t.removeOnUnmount,t==null?void 0:t.id]),n}var cs=typeof window>"u";function us(e={}){const{autoLock:t=!0,lockTarget:n,widthReflow:r=!0}=e,[o,s]=u.useState(!1),a=u.useRef(null),i=u.useRef(null),d=()=>{if(a.current){const{overflow:f,paddingRight:m}=a.current.style;if(i.current={overflow:f,paddingRight:m},r){const h=a.current===document.body?window.innerWidth:a.current.offsetWidth,l=parseInt(window.getComputedStyle(a.current).paddingRight,10)||0,w=h-a.current.scrollWidth;a.current.style.paddingRight=`${w+l}px`}a.current.style.overflow="hidden",s(!0)}},c=()=>{a.current&&i.current&&(a.current.style.overflow=i.current.overflow,r&&(a.current.style.paddingRight=i.current.paddingRight)),s(!1)};return J(()=>{if(!cs)return n&&(a.current=typeof n=="string"?document.querySelector(n):n),a.current||(a.current=document.body),t&&d(),()=>{c()}},[t,n,r]),{isLocked:o,lock:d,unlock:c}}var yt=typeof window>"u";function ds(e,t,n={}){const{initializeWithValue:r=!0}=n,o=u.useCallback(h=>n.serializer?n.serializer(h):JSON.stringify(h),[n]),s=u.useCallback(h=>{if(n.deserializer)return n.deserializer(h);if(h==="undefined")return;const l=t instanceof Function?t():t;let w;try{w=JSON.parse(h)}catch(g){return console.error("Error parsing JSON:",g),l}return w},[n,t]),a=u.useCallback(()=>{const h=t instanceof Function?t():t;if(yt)return h;try{const l=window.sessionStorage.getItem(e);return l?s(l):h}catch(l){return console.warn(`Error reading sessionStorage key “${e}”:`,l),h}},[t,e,s]),[i,d]=u.useState(()=>r?a():t instanceof Function?t():t),c=Le(h=>{yt&&console.warn(`Tried setting sessionStorage key “${e}” even though environment is not a client`);try{const l=h instanceof Function?h(a()):h;window.sessionStorage.setItem(e,o(l)),d(l),window.dispatchEvent(new StorageEvent("session-storage",{key:e}))}catch(l){console.warn(`Error setting sessionStorage key “${e}”:`,l)}}),f=Le(()=>{yt&&console.warn(`Tried removing sessionStorage key “${e}” even though environment is not a client`);const h=t instanceof Function?t():t;window.sessionStorage.removeItem(e),d(h),window.dispatchEvent(new StorageEvent("session-storage",{key:e}))});u.useEffect(()=>{d(a())},[e]);const m=u.useCallback(h=>{h.key&&h.key!==e||d(a())},[e,a]);return V("storage",m),V("session-storage",m),[i,c,f]}function fs(e){const[t,n]=u.useState(1),r=t+1<=e,o=t-1>0,s=u.useCallback(c=>{const f=c instanceof Function?c(t):c;if(f>=1&&f<=e){n(f);return}throw new Error("Step not valid")},[e,t]),a=u.useCallback(()=>{r&&n(c=>c+1)},[r]),i=u.useCallback(()=>{o&&n(c=>c-1)},[o]),d=u.useCallback(()=>{n(1)},[]);return[t,{goToNextStep:a,goToPrevStep:i,canGoToNextStep:r,canGoToPrevStep:o,setStep:s,reset:d}]}var ps="(prefers-color-scheme: dark)",hs="usehooks-ts-ternary-dark-mode";function ms({defaultValue:e="system",localStorageKey:t=hs,initializeWithValue:n=!0}={}){const r=Pt(ps,{initializeWithValue:n}),[o,s]=It(t,e,{initializeWithValue:n});return{isDarkMode:o==="dark"||o==="system"&&r,ternaryDarkMode:o,setTernaryDarkMode:s,toggleTernaryDarkMode:()=>{const d=["light","system","dark"];s(c=>{const f=(d.indexOf(c)+1)%d.length;return d[f]})}}}function gs(e,t){const n=u.useRef(e);J(()=>{n.current=e},[e]),u.useEffect(()=>{if(!t&&t!==0)return;const r=setTimeout(()=>{n.current()},t);return()=>{clearTimeout(r)}},[t])}function ws(e){const[t,n]=u.useState(!!e),r=u.useCallback(()=>{n(o=>!o)},[]);return[t,r,n]}var ys=typeof window>"u";function bs(e={}){let{initializeWithValue:t=!0}=e;ys&&(t=!1);const[n,r]=u.useState(()=>t?{width:window.innerWidth,height:window.innerHeight}:{width:void 0,height:void 0}),o=et(r,e.debounceDelay);function s(){(e.debounceDelay?o:r)({width:window.innerWidth,height:window.innerHeight})}return V("resize",s),J(()=>{s()},[]),n}function Dn(e,t){return function(){return e.apply(t,arguments)}}const{toString:vs}=Object.prototype,{getPrototypeOf:Ft}=Object,tt=(e=>t=>{const n=vs.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),ee=e=>(e=e.toLowerCase(),t=>tt(t)===e),nt=e=>t=>typeof t===e,{isArray:xe}=Array,De=nt("undefined");function Es(e){return e!==null&&!De(e)&&e.constructor!==null&&!De(e.constructor)&&K(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const Mn=ee("ArrayBuffer");function Ss(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&Mn(e.buffer),t}const xs=nt("string"),K=nt("function"),In=nt("number"),rt=e=>e!==null&&typeof e=="object",Ts=e=>e===!0||e===!1,Ke=e=>{if(tt(e)!=="object")return!1;const t=Ft(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},Rs=ee("Date"),_s=ee("File"),Os=ee("Blob"),Cs=ee("FileList"),Ns=e=>rt(e)&&K(e.pipe),ks=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||K(e.append)&&((t=tt(e))==="formdata"||t==="object"&&K(e.toString)&&e.toString()==="[object FormData]"))},As=ee("URLSearchParams"),[Ls,Ds,Ms,Is]=["ReadableStream","Request","Response","Headers"].map(ee),Ps=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Me(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e>"u")return;let r,o;if(typeof e!="object"&&(e=[e]),xe(e))for(r=0,o=e.length;r<o;r++)t.call(null,e[r],r,e);else{const s=n?Object.getOwnPropertyNames(e):Object.keys(e),a=s.length;let i;for(r=0;r<a;r++)i=s[r],t.call(null,e[i],i,e)}}function Pn(e,t){t=t.toLowerCase();const n=Object.keys(e);let r=n.length,o;for(;r-- >0;)if(o=n[r],t===o.toLowerCase())return o;return null}const pe=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,Bn=e=>!De(e)&&e!==pe;function _t(){const{caseless:e}=Bn(this)&&this||{},t={},n=(r,o)=>{const s=e&&Pn(t,o)||o;Ke(t[s])&&Ke(r)?t[s]=_t(t[s],r):Ke(r)?t[s]=_t({},r):xe(r)?t[s]=r.slice():t[s]=r};for(let r=0,o=arguments.length;r<o;r++)arguments[r]&&Me(arguments[r],n);return t}const Bs=(e,t,n,{allOwnKeys:r}={})=>(Me(t,(o,s)=>{n&&K(o)?e[s]=Dn(o,n):e[s]=o},{allOwnKeys:r}),e),Fs=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),Us=(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)},js=(e,t,n,r)=>{let o,s,a;const i={};if(t=t||{},e==null)return t;do{for(o=Object.getOwnPropertyNames(e),s=o.length;s-- >0;)a=o[s],(!r||r(a,e,t))&&!i[a]&&(t[a]=e[a],i[a]=!0);e=n!==!1&&Ft(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},$s=(e,t,n)=>{e=String(e),(n===void 0||n>e.length)&&(n=e.length),n-=t.length;const r=e.indexOf(t,n);return r!==-1&&r===n},zs=e=>{if(!e)return null;if(xe(e))return e;let t=e.length;if(!In(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},Hs=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&Ft(Uint8Array)),Vs=(e,t)=>{const r=(e&&e[Symbol.iterator]).call(e);let o;for(;(o=r.next())&&!o.done;){const s=o.value;t.call(e,s[0],s[1])}},qs=(e,t)=>{let n;const r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},Ws=ee("HTMLFormElement"),Ks=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,o){return r.toUpperCase()+o}),an=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),Ys=ee("RegExp"),Fn=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};Me(n,(o,s)=>{let a;(a=t(o,s,e))!==!1&&(r[s]=a||o)}),Object.defineProperties(e,r)},Js=e=>{Fn(e,(t,n)=>{if(K(e)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const r=e[n];if(K(r)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},Gs=(e,t)=>{const n={},r=o=>{o.forEach(s=>{n[s]=!0})};return xe(e)?r(e):r(String(e).split(t)),n},Xs=()=>{},Qs=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function Zs(e){return!!(e&&K(e.append)&&e[Symbol.toStringTag]==="FormData"&&e[Symbol.iterator])}const ea=e=>{const t=new Array(10),n=(r,o)=>{if(rt(r)){if(t.indexOf(r)>=0)return;if(!("toJSON"in r)){t[o]=r;const s=xe(r)?[]:{};return Me(r,(a,i)=>{const d=n(a,o+1);!De(d)&&(s[i]=d)}),t[o]=void 0,s}}return r};return n(e,0)},ta=ee("AsyncFunction"),na=e=>e&&(rt(e)||K(e))&&K(e.then)&&K(e.catch),Un=((e,t)=>e?setImmediate:t?((n,r)=>(pe.addEventListener("message",({source:o,data:s})=>{o===pe&&s===n&&r.length&&r.shift()()},!1),o=>{r.push(o),pe.postMessage(n,"*")}))(`axios@${Math.random()}`,[]):n=>setTimeout(n))(typeof setImmediate=="function",K(pe.postMessage)),ra=typeof queueMicrotask<"u"?queueMicrotask.bind(pe):typeof process<"u"&&process.nextTick||Un,p={isArray:xe,isArrayBuffer:Mn,isBuffer:Es,isFormData:ks,isArrayBufferView:Ss,isString:xs,isNumber:In,isBoolean:Ts,isObject:rt,isPlainObject:Ke,isReadableStream:Ls,isRequest:Ds,isResponse:Ms,isHeaders:Is,isUndefined:De,isDate:Rs,isFile:_s,isBlob:Os,isRegExp:Ys,isFunction:K,isStream:Ns,isURLSearchParams:As,isTypedArray:Hs,isFileList:Cs,forEach:Me,merge:_t,extend:Bs,trim:Ps,stripBOM:Fs,inherits:Us,toFlatObject:js,kindOf:tt,kindOfTest:ee,endsWith:$s,toArray:zs,forEachEntry:Vs,matchAll:qs,isHTMLForm:Ws,hasOwnProperty:an,hasOwnProp:an,reduceDescriptors:Fn,freezeMethods:Js,toObjectSet:Gs,toCamelCase:Ks,noop:Xs,toFiniteNumber:Qs,findKey:Pn,global:pe,isContextDefined:Bn,isSpecCompliantForm:Zs,toJSONObject:ea,isAsyncFn:ta,isThenable:na,setImmediate:Un,asap:ra};function v(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,this.status=o.status?o.status:null)}p.inherits(v,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:p.toJSONObject(this.config),code:this.code,status:this.status}}});const jn=v.prototype,$n={};["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=>{$n[e]={value:e}});Object.defineProperties(v,$n);Object.defineProperty(jn,"isAxiosError",{value:!0});v.from=(e,t,n,r,o,s)=>{const a=Object.create(jn);return p.toFlatObject(e,a,function(d){return d!==Error.prototype},i=>i!=="isAxiosError"),v.call(a,e.message,t,n,r,o),a.cause=e,a.name=e.name,s&&Object.assign(a,s),a};const oa=null;function Ot(e){return p.isPlainObject(e)||p.isArray(e)}function zn(e){return p.endsWith(e,"[]")?e.slice(0,-2):e}function ln(e,t,n){return e?e.concat(t).map(function(o,s){return o=zn(o),!n&&s?"["+o+"]":o}).join(n?".":""):t}function sa(e){return p.isArray(e)&&!e.some(Ot)}const aa=p.toFlatObject(p,{},null,function(t){return/^is[A-Z]/.test(t)});function ot(e,t,n){if(!p.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=p.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(g,y){return!p.isUndefined(y[g])});const r=n.metaTokens,o=n.visitor||f,s=n.dots,a=n.indexes,d=(n.Blob||typeof Blob<"u"&&Blob)&&p.isSpecCompliantForm(t);if(!p.isFunction(o))throw new TypeError("visitor must be a function");function c(w){if(w===null)return"";if(p.isDate(w))return w.toISOString();if(!d&&p.isBlob(w))throw new v("Blob is not supported. Use a Buffer instead.");return p.isArrayBuffer(w)||p.isTypedArray(w)?d&&typeof Blob=="function"?new Blob([w]):Buffer.from(w):w}function f(w,g,y){let T=w;if(w&&!y&&typeof w=="object"){if(p.endsWith(g,"{}"))g=r?g:g.slice(0,-2),w=JSON.stringify(w);else if(p.isArray(w)&&sa(w)||(p.isFileList(w)||p.endsWith(g,"[]"))&&(T=p.toArray(w)))return g=zn(g),T.forEach(function(R,B){!(p.isUndefined(R)||R===null)&&t.append(a===!0?ln([g],B,s):a===null?g:g+"[]",c(R))}),!1}return Ot(w)?!0:(t.append(ln(y,g,s),c(w)),!1)}const m=[],h=Object.assign(aa,{defaultVisitor:f,convertValue:c,isVisitable:Ot});function l(w,g){if(!p.isUndefined(w)){if(m.indexOf(w)!==-1)throw Error("Circular reference detected in "+g.join("."));m.push(w),p.forEach(w,function(T,S){(!(p.isUndefined(T)||T===null)&&o.call(t,T,p.isString(S)?S.trim():S,g,h))===!0&&l(T,g?g.concat(S):[S])}),m.pop()}}if(!p.isObject(e))throw new TypeError("data must be an object");return l(e),t}function cn(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(r){return t[r]})}function Ut(e,t){this._pairs=[],e&&ot(e,this,t)}const Hn=Ut.prototype;Hn.append=function(t,n){this._pairs.push([t,n])};Hn.toString=function(t){const n=t?function(r){return t.call(this,r,cn)}:cn;return this._pairs.map(function(o){return n(o[0])+"="+n(o[1])},"").join("&")};function ia(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function Vn(e,t,n){if(!t)return e;const r=n&&n.encode||ia;p.isFunction(n)&&(n={serialize:n});const o=n&&n.serialize;let s;if(o?s=o(t,n):s=p.isURLSearchParams(t)?t.toString():new Ut(t,n).toString(r),s){const a=e.indexOf("#");a!==-1&&(e=e.slice(0,a)),e+=(e.indexOf("?")===-1?"?":"&")+s}return e}class un{constructor(){this.handlers=[]}use(t,n,r){return this.handlers.push({fulfilled:t,rejected:n,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){p.forEach(this.handlers,function(r){r!==null&&t(r)})}}const qn={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},la=typeof URLSearchParams<"u"?URLSearchParams:Ut,ca=typeof FormData<"u"?FormData:null,ua=typeof Blob<"u"?Blob:null,da={isBrowser:!0,classes:{URLSearchParams:la,FormData:ca,Blob:ua},protocols:["http","https","file","blob","url","data"]},jt=typeof window<"u"&&typeof document<"u",Ct=typeof navigator=="object"&&navigator||void 0,fa=jt&&(!Ct||["ReactNative","NativeScript","NS"].indexOf(Ct.product)<0),pa=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",ha=jt&&window.location.href||"http://localhost",ma=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:jt,hasStandardBrowserEnv:fa,hasStandardBrowserWebWorkerEnv:pa,navigator:Ct,origin:ha},Symbol.toStringTag,{value:"Module"})),U={...ma,...da};function ga(e,t){return ot(e,new U.classes.URLSearchParams,Object.assign({visitor:function(n,r,o,s){return U.isNode&&p.isBuffer(n)?(this.append(r,n.toString("base64")),!1):s.defaultVisitor.apply(this,arguments)}},t))}function wa(e){return p.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function ya(e){const t={},n=Object.keys(e);let r;const o=n.length;let s;for(r=0;r<o;r++)s=n[r],t[s]=e[s];return t}function Wn(e){function t(n,r,o,s){let a=n[s++];if(a==="__proto__")return!0;const i=Number.isFinite(+a),d=s>=n.length;return a=!a&&p.isArray(o)?o.length:a,d?(p.hasOwnProp(o,a)?o[a]=[o[a],r]:o[a]=r,!i):((!o[a]||!p.isObject(o[a]))&&(o[a]=[]),t(n,r,o[a],s)&&p.isArray(o[a])&&(o[a]=ya(o[a])),!i)}if(p.isFormData(e)&&p.isFunction(e.entries)){const n={};return p.forEachEntry(e,(r,o)=>{t(wa(r),o,n,0)}),n}return null}function ba(e,t,n){if(p.isString(e))try{return(t||JSON.parse)(e),p.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(e)}const Ie={transitional:qn,adapter:["xhr","http","fetch"],transformRequest:[function(t,n){const r=n.getContentType()||"",o=r.indexOf("application/json")>-1,s=p.isObject(t);if(s&&p.isHTMLForm(t)&&(t=new FormData(t)),p.isFormData(t))return o?JSON.stringify(Wn(t)):t;if(p.isArrayBuffer(t)||p.isBuffer(t)||p.isStream(t)||p.isFile(t)||p.isBlob(t)||p.isReadableStream(t))return t;if(p.isArrayBufferView(t))return t.buffer;if(p.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let i;if(s){if(r.indexOf("application/x-www-form-urlencoded")>-1)return ga(t,this.formSerializer).toString();if((i=p.isFileList(t))||r.indexOf("multipart/form-data")>-1){const d=this.env&&this.env.FormData;return ot(i?{"files[]":t}:t,d&&new d,this.formSerializer)}}return s||o?(n.setContentType("application/json",!1),ba(t)):t}],transformResponse:[function(t){const n=this.transitional||Ie.transitional,r=n&&n.forcedJSONParsing,o=this.responseType==="json";if(p.isResponse(t)||p.isReadableStream(t))return t;if(t&&p.isString(t)&&(r&&!this.responseType||o)){const a=!(n&&n.silentJSONParsing)&&o;try{return JSON.parse(t)}catch(i){if(a)throw i.name==="SyntaxError"?v.from(i,v.ERR_BAD_RESPONSE,this,null,this.response):i}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:U.classes.FormData,Blob:U.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};p.forEach(["delete","get","head","post","put","patch"],e=>{Ie.headers[e]={}});const va=p.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"]),Ea=e=>{const t={};let n,r,o;return e&&e.split(`
|
|
5
|
-
|
|
6
|
-
`)}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[dn]=this[dn]={accessors:{}}).accessors,o=this.prototype;function s(a){const i=Ae(a);r[i]||(Ra(o,a),r[i]=!0)}return p.isArray(t)?t.forEach(s):s(t),this}};H.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);p.reduceDescriptors(H.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(r){this[n]=r}}});p.freezeMethods(H);function vt(e,t){const n=this||Ie,r=t||n,o=H.from(r.headers);let s=r.data;return p.forEach(e,function(i){s=i.call(n,s,o.normalize(),t?t.status:void 0)}),o.normalize(),s}function Kn(e){return!!(e&&e.__CANCEL__)}function Te(e,t,n){v.call(this,e??"canceled",v.ERR_CANCELED,t,n),this.name="CanceledError"}p.inherits(Te,v,{__CANCEL__:!0});function Yn(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new v("Request failed with status code "+n.status,[v.ERR_BAD_REQUEST,v.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}function _a(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function Oa(e,t){e=e||10;const n=new Array(e),r=new Array(e);let o=0,s=0,a;return t=t!==void 0?t:1e3,function(d){const c=Date.now(),f=r[s];a||(a=c),n[o]=d,r[o]=c;let m=s,h=0;for(;m!==o;)h+=n[m++],m=m%e;if(o=(o+1)%e,o===s&&(s=(s+1)%e),c-a<t)return;const l=f&&c-f;return l?Math.round(h*1e3/l):void 0}}function Ca(e,t){let n=0,r=1e3/t,o,s;const a=(c,f=Date.now())=>{n=f,o=null,s&&(clearTimeout(s),s=null),e.apply(null,c)};return[(...c)=>{const f=Date.now(),m=f-n;m>=r?a(c,f):(o=c,s||(s=setTimeout(()=>{s=null,a(o)},r-m)))},()=>o&&a(o)]}const Xe=(e,t,n=3)=>{let r=0;const o=Oa(50,250);return Ca(s=>{const a=s.loaded,i=s.lengthComputable?s.total:void 0,d=a-r,c=o(d),f=a<=i;r=a;const m={loaded:a,total:i,progress:i?a/i:void 0,bytes:d,rate:c||void 0,estimated:c&&i&&f?(i-a)/c:void 0,event:s,lengthComputable:i!=null,[t?"download":"upload"]:!0};e(m)},n)},fn=(e,t)=>{const n=e!=null;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},pn=e=>(...t)=>p.asap(()=>e(...t)),Na=U.hasStandardBrowserEnv?((e,t)=>n=>(n=new URL(n,U.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)))(new URL(U.origin),U.navigator&&/(msie|trident)/i.test(U.navigator.userAgent)):()=>!0,ka=U.hasStandardBrowserEnv?{write(e,t,n,r,o,s){const a=[e+"="+encodeURIComponent(t)];p.isNumber(n)&&a.push("expires="+new Date(n).toGMTString()),p.isString(r)&&a.push("path="+r),p.isString(o)&&a.push("domain="+o),s===!0&&a.push("secure"),document.cookie=a.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 Aa(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function La(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function Jn(e,t,n){let r=!Aa(t);return e&&r||n==!1?La(e,t):t}const hn=e=>e instanceof H?{...e}:e;function me(e,t){t=t||{};const n={};function r(c,f,m,h){return p.isPlainObject(c)&&p.isPlainObject(f)?p.merge.call({caseless:h},c,f):p.isPlainObject(f)?p.merge({},f):p.isArray(f)?f.slice():f}function o(c,f,m,h){if(p.isUndefined(f)){if(!p.isUndefined(c))return r(void 0,c,m,h)}else return r(c,f,m,h)}function s(c,f){if(!p.isUndefined(f))return r(void 0,f)}function a(c,f){if(p.isUndefined(f)){if(!p.isUndefined(c))return r(void 0,c)}else return r(void 0,f)}function i(c,f,m){if(m in t)return r(c,f);if(m in e)return r(void 0,c)}const d={url:s,method:s,data:s,baseURL:a,transformRequest:a,transformResponse:a,paramsSerializer:a,timeout:a,timeoutMessage:a,withCredentials:a,withXSRFToken:a,adapter:a,responseType:a,xsrfCookieName:a,xsrfHeaderName:a,onUploadProgress:a,onDownloadProgress:a,decompress:a,maxContentLength:a,maxBodyLength:a,beforeRedirect:a,transport:a,httpAgent:a,httpsAgent:a,cancelToken:a,socketPath:a,responseEncoding:a,validateStatus:i,headers:(c,f,m)=>o(hn(c),hn(f),m,!0)};return p.forEach(Object.keys(Object.assign({},e,t)),function(f){const m=d[f]||o,h=m(e[f],t[f],f);p.isUndefined(h)&&m!==i||(n[f]=h)}),n}const Gn=e=>{const t=me({},e);let{data:n,withXSRFToken:r,xsrfHeaderName:o,xsrfCookieName:s,headers:a,auth:i}=t;t.headers=a=H.from(a),t.url=Vn(Jn(t.baseURL,t.url),e.params,e.paramsSerializer),i&&a.set("Authorization","Basic "+btoa((i.username||"")+":"+(i.password?unescape(encodeURIComponent(i.password)):"")));let d;if(p.isFormData(n)){if(U.hasStandardBrowserEnv||U.hasStandardBrowserWebWorkerEnv)a.setContentType(void 0);else if((d=a.getContentType())!==!1){const[c,...f]=d?d.split(";").map(m=>m.trim()).filter(Boolean):[];a.setContentType([c||"multipart/form-data",...f].join("; "))}}if(U.hasStandardBrowserEnv&&(r&&p.isFunction(r)&&(r=r(t)),r||r!==!1&&Na(t.url))){const c=o&&s&&ka.read(s);c&&a.set(o,c)}return t},Da=typeof XMLHttpRequest<"u",Ma=Da&&function(e){return new Promise(function(n,r){const o=Gn(e);let s=o.data;const a=H.from(o.headers).normalize();let{responseType:i,onUploadProgress:d,onDownloadProgress:c}=o,f,m,h,l,w;function g(){l&&l(),w&&w(),o.cancelToken&&o.cancelToken.unsubscribe(f),o.signal&&o.signal.removeEventListener("abort",f)}let y=new XMLHttpRequest;y.open(o.method.toUpperCase(),o.url,!0),y.timeout=o.timeout;function T(){if(!y)return;const R=H.from("getAllResponseHeaders"in y&&y.getAllResponseHeaders()),k={data:!i||i==="text"||i==="json"?y.responseText:y.response,status:y.status,statusText:y.statusText,headers:R,config:e,request:y};Yn(function(D){n(D),g()},function(D){r(D),g()},k),y=null}"onloadend"in y?y.onloadend=T:y.onreadystatechange=function(){!y||y.readyState!==4||y.status===0&&!(y.responseURL&&y.responseURL.indexOf("file:")===0)||setTimeout(T)},y.onabort=function(){y&&(r(new v("Request aborted",v.ECONNABORTED,e,y)),y=null)},y.onerror=function(){r(new v("Network Error",v.ERR_NETWORK,e,y)),y=null},y.ontimeout=function(){let B=o.timeout?"timeout of "+o.timeout+"ms exceeded":"timeout exceeded";const k=o.transitional||qn;o.timeoutErrorMessage&&(B=o.timeoutErrorMessage),r(new v(B,k.clarifyTimeoutError?v.ETIMEDOUT:v.ECONNABORTED,e,y)),y=null},s===void 0&&a.setContentType(null),"setRequestHeader"in y&&p.forEach(a.toJSON(),function(B,k){y.setRequestHeader(k,B)}),p.isUndefined(o.withCredentials)||(y.withCredentials=!!o.withCredentials),i&&i!=="json"&&(y.responseType=o.responseType),c&&([h,w]=Xe(c,!0),y.addEventListener("progress",h)),d&&y.upload&&([m,l]=Xe(d),y.upload.addEventListener("progress",m),y.upload.addEventListener("loadend",l)),(o.cancelToken||o.signal)&&(f=R=>{y&&(r(!R||R.type?new Te(null,e,y):R),y.abort(),y=null)},o.cancelToken&&o.cancelToken.subscribe(f),o.signal&&(o.signal.aborted?f():o.signal.addEventListener("abort",f)));const S=_a(o.url);if(S&&U.protocols.indexOf(S)===-1){r(new v("Unsupported protocol "+S+":",v.ERR_BAD_REQUEST,e));return}y.send(s||null)})},Ia=(e,t)=>{const{length:n}=e=e?e.filter(Boolean):[];if(t||n){let r=new AbortController,o;const s=function(c){if(!o){o=!0,i();const f=c instanceof Error?c:this.reason;r.abort(f instanceof v?f:new Te(f instanceof Error?f.message:f))}};let a=t&&setTimeout(()=>{a=null,s(new v(`timeout ${t} of ms exceeded`,v.ETIMEDOUT))},t);const i=()=>{e&&(a&&clearTimeout(a),a=null,e.forEach(c=>{c.unsubscribe?c.unsubscribe(s):c.removeEventListener("abort",s)}),e=null)};e.forEach(c=>c.addEventListener("abort",s));const{signal:d}=r;return d.unsubscribe=()=>p.asap(i),d}},Pa=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},Ba=async function*(e,t){for await(const n of Fa(e))yield*Pa(n,t)},Fa=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()}},mn=(e,t,n,r)=>{const o=Ba(e,t);let s=0,a,i=d=>{a||(a=!0,r&&r(d))};return new ReadableStream({async pull(d){try{const{done:c,value:f}=await o.next();if(c){i(),d.close();return}let m=f.byteLength;if(n){let h=s+=m;n(h)}d.enqueue(new Uint8Array(f))}catch(c){throw i(c),c}},cancel(d){return i(d),o.return()}},{highWaterMark:2})},st=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",Xn=st&&typeof ReadableStream=="function",Ua=st&&(typeof TextEncoder=="function"?(e=>t=>e.encode(t))(new TextEncoder):async e=>new Uint8Array(await new Response(e).arrayBuffer())),Qn=(e,...t)=>{try{return!!e(...t)}catch{return!1}},ja=Xn&&Qn(()=>{let e=!1;const t=new Request(U.origin,{body:new ReadableStream,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!t}),gn=64*1024,Nt=Xn&&Qn(()=>p.isReadableStream(new Response("").body)),Qe={stream:Nt&&(e=>e.body)};st&&(e=>{["text","arrayBuffer","blob","formData","stream"].forEach(t=>{!Qe[t]&&(Qe[t]=p.isFunction(e[t])?n=>n[t]():(n,r)=>{throw new v(`Response type '${t}' is not supported`,v.ERR_NOT_SUPPORT,r)})})})(new Response);const $a=async e=>{if(e==null)return 0;if(p.isBlob(e))return e.size;if(p.isSpecCompliantForm(e))return(await new Request(U.origin,{method:"POST",body:e}).arrayBuffer()).byteLength;if(p.isArrayBufferView(e)||p.isArrayBuffer(e))return e.byteLength;if(p.isURLSearchParams(e)&&(e=e+""),p.isString(e))return(await Ua(e)).byteLength},za=async(e,t)=>{const n=p.toFiniteNumber(e.getContentLength());return n??$a(t)},Ha=st&&(async e=>{let{url:t,method:n,data:r,signal:o,cancelToken:s,timeout:a,onDownloadProgress:i,onUploadProgress:d,responseType:c,headers:f,withCredentials:m="same-origin",fetchOptions:h}=Gn(e);c=c?(c+"").toLowerCase():"text";let l=Ia([o,s&&s.toAbortSignal()],a),w;const g=l&&l.unsubscribe&&(()=>{l.unsubscribe()});let y;try{if(d&&ja&&n!=="get"&&n!=="head"&&(y=await za(f,r))!==0){let k=new Request(t,{method:"POST",body:r,duplex:"half"}),E;if(p.isFormData(r)&&(E=k.headers.get("content-type"))&&f.setContentType(E),k.body){const[D,j]=fn(y,Xe(pn(d)));r=mn(k.body,gn,D,j)}}p.isString(m)||(m=m?"include":"omit");const T="credentials"in Request.prototype;w=new Request(t,{...h,signal:l,method:n.toUpperCase(),headers:f.normalize().toJSON(),body:r,duplex:"half",credentials:T?m:void 0});let S=await fetch(w);const R=Nt&&(c==="stream"||c==="response");if(Nt&&(i||R&&g)){const k={};["status","statusText","headers"].forEach(te=>{k[te]=S[te]});const E=p.toFiniteNumber(S.headers.get("content-length")),[D,j]=i&&fn(E,Xe(pn(i),!0))||[];S=new Response(mn(S.body,gn,D,()=>{j&&j(),g&&g()}),k)}c=c||"text";let B=await Qe[p.findKey(Qe,c)||"text"](S,e);return!R&&g&&g(),await new Promise((k,E)=>{Yn(k,E,{data:B,headers:H.from(S.headers),status:S.status,statusText:S.statusText,config:e,request:w})})}catch(T){throw g&&g(),T&&T.name==="TypeError"&&/fetch/i.test(T.message)?Object.assign(new v("Network Error",v.ERR_NETWORK,e,w),{cause:T.cause||T}):v.from(T,T&&T.code,e,w)}}),kt={http:oa,xhr:Ma,fetch:Ha};p.forEach(kt,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const wn=e=>`- ${e}`,Va=e=>p.isFunction(e)||e===null||e===!1,Zn={getAdapter:e=>{e=p.isArray(e)?e:[e];const{length:t}=e;let n,r;const o={};for(let s=0;s<t;s++){n=e[s];let a;if(r=n,!Va(n)&&(r=kt[(a=String(n)).toLowerCase()],r===void 0))throw new v(`Unknown adapter '${a}'`);if(r)break;o[a||"#"+s]=r}if(!r){const s=Object.entries(o).map(([i,d])=>`adapter ${i} `+(d===!1?"is not supported by the environment":"is not available in the build"));let a=t?s.length>1?`since :
|
|
7
|
-
`+s.
|
|
8
|
-
`
|
|
9
|
-
`+s):r.stack=s}catch{}}throw r}}_request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=me(this.defaults,n);const{transitional:r,paramsSerializer:o,headers:s}=n;r!==void 0&&Je.assertOptions(r,{silentJSONParsing:ne.transitional(ne.boolean),forcedJSONParsing:ne.transitional(ne.boolean),clarifyTimeoutError:ne.transitional(ne.boolean)},!1),o!=null&&(p.isFunction(o)?n.paramsSerializer={serialize:o}:Je.assertOptions(o,{encode:ne.function,serialize:ne.function},!0)),n.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?n.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:n.allowAbsoluteUrls=!0),Je.assertOptions(n,{baseUrl:ne.spelling("baseURL"),withXsrfToken:ne.spelling("withXSRFToken")},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let a=s&&p.merge(s.common,s[n.method]);s&&p.forEach(["delete","get","head","post","put","patch","common"],w=>{delete s[w]}),n.headers=H.concat(a,s);const i=[];let d=!0;this.interceptors.request.forEach(function(g){typeof g.runWhen=="function"&&g.runWhen(n)===!1||(d=d&&g.synchronous,i.unshift(g.fulfilled,g.rejected))});const c=[];this.interceptors.response.forEach(function(g){c.push(g.fulfilled,g.rejected)});let f,m=0,h;if(!d){const w=[yn.bind(this),void 0];for(w.unshift.apply(w,i),w.push.apply(w,c),h=w.length,f=Promise.resolve(n);m<h;)f=f.then(w[m++],w[m++]);return f}h=i.length;let l=n;for(m=0;m<h;){const w=i[m++],g=i[m++];try{l=w(l)}catch(y){g.call(this,y);break}}try{f=yn.call(this,l)}catch(w){return Promise.reject(w)}for(m=0,h=c.length;m<h;)f=f.then(c[m++],c[m++]);return f}getUri(t){t=me(this.defaults,t);const n=Jn(t.baseURL,t.url,t.allowAbsoluteUrls);return Vn(n,t.params,t.paramsSerializer)}};p.forEach(["delete","get","head","options"],function(t){he.prototype[t]=function(n,r){return this.request(me(r||{},{method:t,url:n,data:(r||{}).data}))}});p.forEach(["post","put","patch"],function(t){function n(r){return function(s,a,i){return this.request(me(i||{},{method:t,headers:r?{"Content-Type":"multipart/form-data"}:{},url:s,data:a}))}}he.prototype[t]=n(),he.prototype[t+"Form"]=n(!0)});let Wa=class tr{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(s){n=s});const r=this;this.promise.then(o=>{if(!r._listeners)return;let s=r._listeners.length;for(;s-- >0;)r._listeners[s](o);r._listeners=null}),this.promise.then=o=>{let s;const a=new Promise(i=>{r.subscribe(i),s=i}).then(o);return a.cancel=function(){r.unsubscribe(s)},a},t(function(s,a,i){r.reason||(r.reason=new Te(s,a,i),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const n=this._listeners.indexOf(t);n!==-1&&this._listeners.splice(n,1)}toAbortSignal(){const t=new AbortController,n=r=>{t.abort(r)};return this.subscribe(n),t.signal.unsubscribe=()=>this.unsubscribe(n),t.signal}static source(){let t;return{token:new tr(function(o){t=o}),cancel:t}}};function Ka(e){return function(n){return e.apply(null,n)}}function Ya(e){return p.isObject(e)&&e.isAxiosError===!0}const At={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(At).forEach(([e,t])=>{At[t]=e});function nr(e){const t=new he(e),n=Dn(he.prototype.request,t);return p.extend(n,he.prototype,t,{allOwnKeys:!0}),p.extend(n,t,null,{allOwnKeys:!0}),n.create=function(o){return nr(me(e,o))},n}const O=nr(Ie);O.Axios=he;O.CanceledError=Te;O.CancelToken=Wa;O.isCancel=Kn;O.VERSION=er;O.toFormData=ot;O.AxiosError=v;O.Cancel=O.CanceledError;O.all=function(t){return Promise.all(t)};O.spread=Ka;O.isAxiosError=Ya;O.mergeConfig=me;O.AxiosHeaders=H;O.formToJSON=e=>Wn(p.isHTMLForm(e)?new FormData(e):e);O.getAdapter=Zn.getAdapter;O.HttpStatusCode=At;O.default=O;const{Axios:ui,AxiosError:di,CanceledError:fi,isCancel:pi,CancelToken:hi,VERSION:mi,all:gi,Cancel:wi,isAxiosError:yi,spread:bi,toFormData:vi,AxiosHeaders:Ei,HttpStatusCode:Si,formToJSON:xi,getAdapter:Ti,mergeConfig:Ri}=O,Lt="useAxios",Ja=async(e=n=>{},t)=>(t.baseURL=Jr(),F.debug(Lt,`baseURL::${t.baseURL}`),e(t),t),Ga=async(e=n=>{},t)=>{var r;if(e(t),t.response.status!==500){if(t.response.status<=401)return F.info(Lt,t.response.data.meta),Promise.reject(t.response.data.meta);if(t.response.status===404)return F.info(Lt,t.response.data.meta),Promise.reject(t.response.data.meta)}let n;try{let o="";t.request.config&&t.request.config.token_type?o=t.request.config.token_type:t.response.config&&t.response.config.token_type&&(o=t.response.config.token_type),n=O(t.response.config)}catch(o){(r=o==null?void 0:o.data)!=null&&r.meta?n=Promise.reject(o.data.meta):o.data?n=Promise.reject(o.data):n=Promise.reject(o)}return n},qe="useAxios",Xa=({onRequest:e,onError:t})=>{O.interceptors.request.use(n=>Ja(e,n)),O.interceptors.response.use(n=>n.data.data,n=>Ga(t,n)),O.defaults.headers.common["content-type"]="application/json"},Qa={get:async(e,t)=>(F.debug(qe,`[get] url | ${e}`),O.get(e,t)),post:async(e,t,n)=>(F.debug(qe,`[post] url | ${e} | payload | ${t}`),O.post(e,t,n)),put:async(e,t,n)=>(F.debug(qe,`[put] url | ${e} | payload | ${t}`),O.put(e,t,n)),delete:async(e,t)=>(F.debug(qe,`[delete] url | ${e}`),O.delete(e,t))};var W=(e=>(e.MINI_MOBILE="mob-sm",e.MOBILE_PORTRAIT="mob",e.MOBILE_LANDSCAPE="mob-l",e.MOBILE_LANDSCAPE_XL="mob-xl",e.TAB_PORTRAIT="tab",e.TAB_LANDSCAPE="tab-l",e.LAPTOP="lap",e.DESKTOP="desk",e))(W||{});const vn={iphone_15:{width:{min:850,max:854},height:{min:390,max:395}},iphone_14_pro_max:{width:{min:925,max:935},height:{min:427,max:435}},iphone_12_pro:{width:{min:840,max:845},height:{min:388,max:392}},iphone_13_mini:{width:{min:810,max:815},height:{min:370,max:377}},iphone_se_22:{width:{min:664,max:668},height:{min:370,max:377}},iphone_xr:{width:{min:894,max:898},height:{min:410,max:417}},gpixel_6_pro:{width:{min:890,max:895},height:{min:408,max:415}},gpixel_4xl:{width:{min:865,max:972},height:{min:408,max:415}},gpixel_3xl:{width:{min:784,max:788},height:{min:390,max:395}},sam_galaxy_s22:{width:{min:778,max:783},height:{min:357,max:365}},sam_galaxy_s22_plus:{width:{min:830,max:835},height:{min:380,max:387}},sam_galaxy_s22_ultra:{width:{min:820,max:825},height:{min:380,max:387}},sam_galaxy_s21:{width:{min:798,max:805},height:{min:358,max:365}},sam_galaxy_s21_plus:{width:{min:850,max:857},height:{min:380,max:387}},sam_galaxy_s20_ultra:{width:{min:910,max:918},height:{min:408,max:415}},nokia_n9:{width:{min:853,max:855},height:{min:478,max:482}}},rr=()=>({width:window.innerWidth,height:window.innerHeight}),Za=({width:e,height:t})=>{const{width:n,height:r}=rr();return e.min<=n&&e.max>=n&&t.min<=r&&t.max>=r},or=()=>{for(const r of Object.keys(vn)){const o=vn[r];if(Za(o))return o.vdevice||W.MOBILE_LANDSCAPE_XL}const{width:e,height:t}=rr(),n=t>=e;return e<=320?W.MINI_MOBILE:e<=480&&e>=320?W.MOBILE_PORTRAIT:e<=767&&e>=481?W.MOBILE_LANDSCAPE:e<=1024&&e>=768?n?W.TAB_PORTRAIT:W.TAB_LANDSCAPE:e<=1280&&e>=1025?W.LAPTOP:(e>=1281,W.DESKTOP)},ei=["h1","h3","blockquote","br"],ti={strong:"*",b:"*",i:"_",u:"__",s:"~",strike:"~",highlight:"`",blockquote:">",h1:"# ",h3:"### ",br:`
|
|
10
|
-
`},P={bold:/(^|\s|[{\[])\*{1,2}(.*?\S *)?\*{1,2}(?=$|\s|[\.,\?:;\-}\]](?:$|\s))/g,italic:/(^|\s|[{\[])\_(.*?\S *)?\_(?=$|\s|[\.,\?:;\-}\]](?:$|\s))/g,underline:/(^|\s|[{\[])\_{2}(.*?\S *)?\_{2}(?=$|\s|[\.,\?:;\-}\]](?:$|\s))/g,strike:/(^|\s|[{\[])\~(.*?\S *)?\~(?=$|\s|[\.,\?:;\-}\]](?:$|\s))/g,heading:/(?:^|\n)(\#{1,6}) (.*?\S *)(?:\n|$)/gm,blockquote:/(?:^|\n)(?:>|>\s|>\s) (.+?)(?:\n|$)/gm,monospace:/(^|\s)\`(.*?\S *)?\`(?=$|\s)/g,codeblock:/(^|\s)`{3}((?:(?:.*?$)\n)?(?:[\s\S]*?))`{3}(?=$|\s)/g,nextline:/(.*)(\n)(.*)/gm,line:/(^|[\n])(\*{3,}|\-{3,})(?=$|[\n])(.*)/g,link:/(^|\s)\[(.+?)\]\(((?:(?:https?:\/\/(?:www\.)?|www\.)|(?:mailto:)).*?)\)(?:{:(.*)})?/gi,image:/!\[(.*)\]\((.*?)\s*(?:(?:'|"|")(.*)(?:'|"|"))?\s*\)(?:{:(.*)})?/gi,video:/(?:\[\!\[(.*)\]\((.*?)\s*(?:(?:'|"|")(.*)(?:'|"|"))?\s*\)(?:{:(.*)})?]\((.*?)\s*(?:(?:'|"|")(.*)(?:'|"|"))?\s*\))(?:{:(.*)})?/gi,bullet:/(^\s|\n|^)([\*|\-|●|○] )(.*?\S *)*(?:(?:.*?$)\n)?((\s)*([\*|\-|●|○] )(.*?\S *)*(?:(?:.*?$)\n)?)*/gm,numlist:/(^\s|\n|^)(\d)+(\.) (.*?\S *)*(?:(?:.*?$)\n)?((\s)*(\d)+(\.)(.*?\S *)*(?:(?:.*?$)\n)?)*/gm,anchor_tag:/<a(>| .*?>)(.*?)<\/a>/g,href:/href=(?:'|")(.*?)(?:'|") ?/g,gdrive_url:/(?:https:\/\/drive\.google\.com\/file\/d\/(.*?)\/view)/,vtype:/(?:vtype=(?:'|"|")(image|audio|video)(?:'|"|"))/},St=e=>e.replace(/\*/g,"*").replace(/\_/g,"_").replace(/\~/g,"~"),ni=e=>e.replace(/*/g,"*").replace(/_/g,"_").replace(/~/g,"~"),En=e=>(e&&typeof e=="string"&&(e=e.replace(/'|'/g,"'").replace(/"/g,'"').replace(/>/g,">").replace(/</g,"<").replace(/&/g,"&").replace(///g,"/").replace(/ /g," ").replace(/%2C/g,",")),e),Ee=(e,t)=>{let n="",r="";return(e[0]===`
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("react"),dr=require("react-dom");var Y=typeof document<"u"?document.currentScript:null;const fr={BASE_URL:"/",DEV:!1,MODE:"production",PROD:!0,SSR:!1};try{console.log("V_APP_NAME: ",process.env.V_APP_NAME)}catch{console.log("isVite:",typeof{url:typeof document>"u"?require("url").pathToFileURL(__filename).href:Y&&Y.tagName.toUpperCase()==="SCRIPT"&&Y.src||new URL("index.js",document.baseURI).href}<"u"&&"env"in{url:typeof document>"u"?require("url").pathToFileURL(__filename).href:Y&&Y.tagName.toUpperCase()==="SCRIPT"&&Y.src||new URL("index.js",document.baseURI).href}),console.log("V_APP_NAME:fb")}try{console.log("NODE_ENV: ",process.env.NODE_ENV)}catch{console.log("NODE_ENV:fb")}try{console.table({url:typeof document>"u"?require("url").pathToFileURL(__filename).href:Y&&Y.tagName.toUpperCase()==="SCRIPT"&&Y.src||new URL("index.js",document.baseURI).href}),console.table(fr)}catch{console.log("import:fb")}try{console.table(process.env)}catch{console.log("process:fb")}let W=process.env||{url:typeof document>"u"?require("url").pathToFileURL(__filename).href:Y&&Y.tagName.toUpperCase()==="SCRIPT"&&Y.src||new URL("index.js",document.baseURI).href};const pr=W.NODE_ENV!=="production";W.NODE_ENV;W.NODE_ENV;W.V_IS_PREVIEW;const hr=W.V_IS_DEBUG==="true";W.V_IS_BETA;const Ce=W.V_APP_NAME||"v0xapp",Ht=W.V_BASE_API_URL||"api",mr=()=>Ht==="local"?W.V_MOCK_LOCAL_API_URL:Ht==="mock"?W.V_MOCK_API_URL:config.domain_type===IAM.DomainType.SANDBOX?W.V_APP_SANDBOX_API_URL:config.domain_type===IAM.DomainType.DC?W.V_APP_DC_API_URL:W.V_APP_API_URL,gr=()=>new Date().toISOString(),_e=(e,t,n)=>`[vezham] [${gr()}] [${e}] [${t}] ${n}`,ut=()=>!pr,B={log:(e=Ce,t,n)=>{console.log(_e("LOG",e,t),n||"")},debug:(e=Ce,t,n)=>{hr&&console.info(_e("DEBUG",e,t),n||"")},info:(e=Ce,t,n)=>{ut()||console.info(_e("INFO",e,t),n||"")},warn:(e=Ce,t,n)=>{ut()||console.warn(_e("WARN",e,t),n||"")},error:(e=Ce,t,n)=>{ut()||console.error(_e("ERROR",e,t),n||"")}};var wr=e=>{switch(e){case"success":return vr;case"info":return Er;case"warning":return Sr;case"error":return xr;default:return null}},br=Array(12).fill(0),yr=({visible:e,className:t})=>c.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},c.createElement("div",{className:"sonner-spinner"},br.map((n,r)=>c.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${r}`})))),vr=c.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},c.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),Sr=c.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},c.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),Er=c.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},c.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),xr=c.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},c.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),Rr=c.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},c.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),c.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),Tr=()=>{let[e,t]=c.useState(document.hidden);return c.useEffect(()=>{let n=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",n),()=>window.removeEventListener("visibilitychange",n)},[]),e},yt=1,Cr=class{constructor(){this.subscribe=e=>(this.subscribers.push(e),()=>{let t=this.subscribers.indexOf(e);this.subscribers.splice(t,1)}),this.publish=e=>{this.subscribers.forEach(t=>t(e))},this.addToast=e=>{this.publish(e),this.toasts=[...this.toasts,e]},this.create=e=>{var t;let{message:n,...r}=e,o=typeof(e==null?void 0:e.id)=="number"||((t=e.id)==null?void 0:t.length)>0?e.id:yt++,a=this.toasts.find(i=>i.id===o),s=e.dismissible===void 0?!0:e.dismissible;return this.dismissedToasts.has(o)&&this.dismissedToasts.delete(o),a?this.toasts=this.toasts.map(i=>i.id===o?(this.publish({...i,...e,id:o,title:n}),{...i,...e,id:o,dismissible:s,title:n}):i):this.addToast({title:n,...r,dismissible:s,id:o}),o},this.dismiss=e=>(this.dismissedToasts.add(e),e||this.toasts.forEach(t=>{this.subscribers.forEach(n=>n({id:t.id,dismiss:!0}))}),this.subscribers.forEach(t=>t({id:e,dismiss:!0})),e),this.message=(e,t)=>this.create({...t,message:e}),this.error=(e,t)=>this.create({...t,message:e,type:"error"}),this.success=(e,t)=>this.create({...t,type:"success",message:e}),this.info=(e,t)=>this.create({...t,type:"info",message:e}),this.warning=(e,t)=>this.create({...t,type:"warning",message:e}),this.loading=(e,t)=>this.create({...t,type:"loading",message:e}),this.promise=(e,t)=>{if(!t)return;let n;t.loading!==void 0&&(n=this.create({...t,promise:e,type:"loading",message:t.loading,description:typeof t.description!="function"?t.description:void 0}));let r=e instanceof Promise?e:e(),o=n!==void 0,a,s=r.then(async d=>{if(a=["resolve",d],c.isValidElement(d))o=!1,this.create({id:n,type:"default",message:d});else if(kr(d)&&!d.ok){o=!1;let u=typeof t.error=="function"?await t.error(`HTTP error! status: ${d.status}`):t.error,p=typeof t.description=="function"?await t.description(`HTTP error! status: ${d.status}`):t.description;this.create({id:n,type:"error",message:u,description:p})}else if(t.success!==void 0){o=!1;let u=typeof t.success=="function"?await t.success(d):t.success,p=typeof t.description=="function"?await t.description(d):t.description;this.create({id:n,type:"success",message:u,description:p})}}).catch(async d=>{if(a=["reject",d],t.error!==void 0){o=!1;let u=typeof t.error=="function"?await t.error(d):t.error,p=typeof t.description=="function"?await t.description(d):t.description;this.create({id:n,type:"error",message:u,description:p})}}).finally(()=>{var d;o&&(this.dismiss(n),n=void 0),(d=t.finally)==null||d.call(t)}),i=()=>new Promise((d,u)=>s.then(()=>a[0]==="reject"?u(a[1]):d(a[1])).catch(u));return typeof n!="string"&&typeof n!="number"?{unwrap:i}:Object.assign(n,{unwrap:i})},this.custom=(e,t)=>{let n=(t==null?void 0:t.id)||yt++;return this.create({jsx:e(n),id:n,...t}),n},this.getActiveToasts=()=>this.toasts.filter(e=>!this.dismissedToasts.has(e.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}},z=new Cr,_r=(e,t)=>{let n=(t==null?void 0:t.id)||yt++;return z.addToast({title:e,...t,id:n}),n},kr=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",Or=_r,Ar=()=>z.toasts,Lr=()=>z.getActiveToasts(),Nr=Object.assign(Or,{success:z.success,info:z.info,warning:z.warning,error:z.error,custom:z.custom,message:z.message,promise:z.promise,dismiss:z.dismiss,loading:z.loading},{getHistory:Ar,getToasts:Lr});function Mr(e,{insertAt:t}={}){if(typeof document>"u")return;let n=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",t==="top"&&n.firstChild?n.insertBefore(r,n.firstChild):n.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}Mr(`:where(html[dir="ltr"]),:where([data-sonner-toaster][dir="ltr"]){--toast-icon-margin-start: -3px;--toast-icon-margin-end: 4px;--toast-svg-margin-start: -1px;--toast-svg-margin-end: 0px;--toast-button-margin-start: auto;--toast-button-margin-end: 0;--toast-close-button-start: 0;--toast-close-button-end: unset;--toast-close-button-transform: translate(-35%, -35%)}:where(html[dir="rtl"]),:where([data-sonner-toaster][dir="rtl"]){--toast-icon-margin-start: 4px;--toast-icon-margin-end: -3px;--toast-svg-margin-start: 0px;--toast-svg-margin-end: -1px;--toast-button-margin-start: 0;--toast-button-margin-end: auto;--toast-close-button-start: unset;--toast-close-button-end: 0;--toast-close-button-transform: translate(35%, -35%)}:where([data-sonner-toaster]){position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1: hsl(0, 0%, 99%);--gray2: hsl(0, 0%, 97.3%);--gray3: hsl(0, 0%, 95.1%);--gray4: hsl(0, 0%, 93%);--gray5: hsl(0, 0%, 90.9%);--gray6: hsl(0, 0%, 88.7%);--gray7: hsl(0, 0%, 85.8%);--gray8: hsl(0, 0%, 78%);--gray9: hsl(0, 0%, 56.1%);--gray10: hsl(0, 0%, 52.3%);--gray11: hsl(0, 0%, 43.5%);--gray12: hsl(0, 0%, 9%);--border-radius: 8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:none;z-index:999999999;transition:transform .4s ease}:where([data-sonner-toaster][data-lifted="true"]){transform:translateY(-10px)}@media (hover: none) and (pointer: coarse){:where([data-sonner-toaster][data-lifted="true"]){transform:none}}:where([data-sonner-toaster][data-x-position="right"]){right:var(--offset-right)}:where([data-sonner-toaster][data-x-position="left"]){left:var(--offset-left)}:where([data-sonner-toaster][data-x-position="center"]){left:50%;transform:translate(-50%)}:where([data-sonner-toaster][data-y-position="top"]){top:var(--offset-top)}:where([data-sonner-toaster][data-y-position="bottom"]){bottom:var(--offset-bottom)}:where([data-sonner-toast]){--y: translateY(100%);--lift-amount: calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);filter:blur(0);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:none;overflow-wrap:anywhere}:where([data-sonner-toast][data-styled="true"]){padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px #0000001a;width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}:where([data-sonner-toast]:focus-visible){box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast][data-y-position="top"]){top:0;--y: translateY(-100%);--lift: 1;--lift-amount: calc(1 * var(--gap))}:where([data-sonner-toast][data-y-position="bottom"]){bottom:0;--y: translateY(100%);--lift: -1;--lift-amount: calc(var(--lift) * var(--gap))}:where([data-sonner-toast]) :where([data-description]){font-weight:400;line-height:1.4;color:inherit}:where([data-sonner-toast]) :where([data-title]){font-weight:500;line-height:1.5;color:inherit}:where([data-sonner-toast]) :where([data-icon]){display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}:where([data-sonner-toast][data-promise="true"]) :where([data-icon])>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}:where([data-sonner-toast]) :where([data-icon])>*{flex-shrink:0}:where([data-sonner-toast]) :where([data-icon]) svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}:where([data-sonner-toast]) :where([data-content]){display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;cursor:pointer;outline:none;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}:where([data-sonner-toast]) :where([data-button]):focus-visible{box-shadow:0 0 0 2px #0006}:where([data-sonner-toast]) :where([data-button]):first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}:where([data-sonner-toast]) :where([data-cancel]){color:var(--normal-text);background:rgba(0,0,0,.08)}:where([data-sonner-toast][data-theme="dark"]) :where([data-cancel]){background:rgba(255,255,255,.3)}:where([data-sonner-toast]) :where([data-close-button]){position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast] [data-close-button]{background:var(--gray1)}:where([data-sonner-toast]) :where([data-close-button]):focus-visible{box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast]) :where([data-disabled="true"]){cursor:not-allowed}:where([data-sonner-toast]):hover :where([data-close-button]):hover{background:var(--gray2);border-color:var(--gray5)}:where([data-sonner-toast][data-swiping="true"]):before{content:"";position:absolute;left:-50%;right:-50%;height:100%;z-index:-1}:where([data-sonner-toast][data-y-position="top"][data-swiping="true"]):before{bottom:50%;transform:scaleY(3) translateY(50%)}:where([data-sonner-toast][data-y-position="bottom"][data-swiping="true"]):before{top:50%;transform:scaleY(3) translateY(-50%)}:where([data-sonner-toast][data-swiping="false"][data-removed="true"]):before{content:"";position:absolute;inset:0;transform:scaleY(2)}:where([data-sonner-toast]):after{content:"";position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}:where([data-sonner-toast][data-mounted="true"]){--y: translateY(0);opacity:1}:where([data-sonner-toast][data-expanded="false"][data-front="false"]){--scale: var(--toasts-before) * .05 + 1;--y: translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}:where([data-sonner-toast])>*{transition:opacity .4s}:where([data-sonner-toast][data-expanded="false"][data-front="false"][data-styled="true"])>*{opacity:0}:where([data-sonner-toast][data-visible="false"]){opacity:0;pointer-events:none}:where([data-sonner-toast][data-mounted="true"][data-expanded="true"]){--y: translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}:where([data-sonner-toast][data-removed="true"][data-front="true"][data-swipe-out="false"]){--y: translateY(calc(var(--lift) * -100%));opacity:0}:where([data-sonner-toast][data-removed="true"][data-front="false"][data-swipe-out="false"][data-expanded="true"]){--y: translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}:where([data-sonner-toast][data-removed="true"][data-front="false"][data-swipe-out="false"][data-expanded="false"]){--y: translateY(40%);opacity:0;transition:transform .5s,opacity .2s}:where([data-sonner-toast][data-removed="true"][data-front="false"]):before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y, 0px)) translate(var(--swipe-amount-x, 0px));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{0%{transform:var(--y) translate(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translate(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{0%{transform:var(--y) translate(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translate(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{0%{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{0%{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width: 600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-theme=light]{--normal-bg: #fff;--normal-border: var(--gray4);--normal-text: var(--gray12);--success-bg: hsl(143, 85%, 96%);--success-border: hsl(145, 92%, 91%);--success-text: hsl(140, 100%, 27%);--info-bg: hsl(208, 100%, 97%);--info-border: hsl(221, 91%, 91%);--info-text: hsl(210, 92%, 45%);--warning-bg: hsl(49, 100%, 97%);--warning-border: hsl(49, 91%, 91%);--warning-text: hsl(31, 92%, 45%);--error-bg: hsl(359, 100%, 97%);--error-border: hsl(359, 100%, 94%);--error-text: hsl(360, 100%, 45%)}[data-sonner-toaster][data-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg: #000;--normal-border: hsl(0, 0%, 20%);--normal-text: var(--gray1)}[data-sonner-toaster][data-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg: #fff;--normal-border: var(--gray3);--normal-text: var(--gray12)}[data-sonner-toaster][data-theme=dark]{--normal-bg: #000;--normal-bg-hover: hsl(0, 0%, 12%);--normal-border: hsl(0, 0%, 20%);--normal-border-hover: hsl(0, 0%, 25%);--normal-text: var(--gray1);--success-bg: hsl(150, 100%, 6%);--success-border: hsl(147, 100%, 12%);--success-text: hsl(150, 86%, 65%);--info-bg: hsl(215, 100%, 6%);--info-border: hsl(223, 100%, 12%);--info-text: hsl(216, 87%, 65%);--warning-bg: hsl(64, 100%, 6%);--warning-border: hsl(60, 100%, 12%);--warning-text: hsl(46, 87%, 65%);--error-bg: hsl(358, 76%, 10%);--error-border: hsl(357, 89%, 16%);--error-text: hsl(358, 100%, 81%)}[data-sonner-toaster][data-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success],[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info],[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning],[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error],[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size: 16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:nth-child(1){animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}to{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}to{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}to{opacity:.15}}@media (prefers-reduced-motion){[data-sonner-toast],[data-sonner-toast]>*,.sonner-loading-bar{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}
|
|
2
|
+
`);function je(e){return e.label!==void 0}var Pr=3,Ir="32px",Dr="16px",qt=4e3,Br=356,Ur=14,Fr=20,jr=200;function ee(...e){return e.filter(Boolean).join(" ")}function zr(e){let[t,n]=e.split("-"),r=[];return t&&r.push(t),n&&r.push(n),r}var Hr=e=>{var t,n,r,o,a,s,i,d,u,p,m;let{invert:h,toast:l,unstyled:w,interacting:g,setHeights:b,visibleToasts:R,heights:E,index:T,toasts:D,expanded:A,removeToast:S,defaultRichColors:M,closeButton:F,style:ne,cancelButtonStyle:rt,actionButtonStyle:Pe,className:oe="",descriptionClassName:Ie="",duration:me,position:De,gap:ce,loadingIcon:se,expandByDefault:Be,classNames:x,icons:$,closeButtonAriaLabel:ot="Close toast",pauseWhenPageIsHidden:k}=e,[O,N]=c.useState(null),[j,ge]=c.useState(null),[P,st]=c.useState(!1),[xe,Ue]=c.useState(!1),[Re,at]=c.useState(!1),[Pt,Qn]=c.useState(!1),[Zn,It]=c.useState(!1),[er,it]=c.useState(0),[tr,Dt]=c.useState(0),Te=c.useRef(l.duration||me||qt),Bt=c.useRef(null),ue=c.useRef(null),nr=T===0,rr=T+1<=R,K=l.type,we=l.dismissible!==!1,or=l.className||"",sr=l.descriptionClassName||"",Fe=c.useMemo(()=>E.findIndex(y=>y.toastId===l.id)||0,[E,l.id]),ar=c.useMemo(()=>{var y;return(y=l.closeButton)!=null?y:F},[l.closeButton,F]),Ut=c.useMemo(()=>l.duration||me||qt,[l.duration,me]),lt=c.useRef(0),be=c.useRef(0),Ft=c.useRef(0),ye=c.useRef(null),[ir,lr]=De.split("-"),jt=c.useMemo(()=>E.reduce((y,C,L)=>L>=Fe?y:y+C.height,0),[E,Fe]),zt=Tr(),cr=l.invert||h,ct=K==="loading";be.current=c.useMemo(()=>Fe*ce+jt,[Fe,jt]),c.useEffect(()=>{Te.current=Ut},[Ut]),c.useEffect(()=>{st(!0)},[]),c.useEffect(()=>{let y=ue.current;if(y){let C=y.getBoundingClientRect().height;return Dt(C),b(L=>[{toastId:l.id,height:C,position:l.position},...L]),()=>b(L=>L.filter(X=>X.toastId!==l.id))}},[b,l.id]),c.useLayoutEffect(()=>{if(!P)return;let y=ue.current,C=y.style.height;y.style.height="auto";let L=y.getBoundingClientRect().height;y.style.height=C,Dt(L),b(X=>X.find(Q=>Q.toastId===l.id)?X.map(Q=>Q.toastId===l.id?{...Q,height:L}:Q):[{toastId:l.id,height:L,position:l.position},...X])},[P,l.title,l.description,b,l.id]);let ae=c.useCallback(()=>{Ue(!0),it(be.current),b(y=>y.filter(C=>C.toastId!==l.id)),setTimeout(()=>{S(l)},jr)},[l,S,b,be]);c.useEffect(()=>{if(l.promise&&K==="loading"||l.duration===1/0||l.type==="loading")return;let y;return A||g||k&&zt?(()=>{if(Ft.current<lt.current){let C=new Date().getTime()-lt.current;Te.current=Te.current-C}Ft.current=new Date().getTime()})():Te.current!==1/0&&(lt.current=new Date().getTime(),y=setTimeout(()=>{var C;(C=l.onAutoClose)==null||C.call(l,l),ae()},Te.current)),()=>clearTimeout(y)},[A,g,l,K,k,zt,ae]),c.useEffect(()=>{l.delete&&ae()},[ae,l.delete]);function ur(){var y,C,L;return $!=null&&$.loading?c.createElement("div",{className:ee(x==null?void 0:x.loader,(y=l==null?void 0:l.classNames)==null?void 0:y.loader,"sonner-loader"),"data-visible":K==="loading"},$.loading):se?c.createElement("div",{className:ee(x==null?void 0:x.loader,(C=l==null?void 0:l.classNames)==null?void 0:C.loader,"sonner-loader"),"data-visible":K==="loading"},se):c.createElement(yr,{className:ee(x==null?void 0:x.loader,(L=l==null?void 0:l.classNames)==null?void 0:L.loader),visible:K==="loading"})}return c.createElement("li",{tabIndex:0,ref:ue,className:ee(oe,or,x==null?void 0:x.toast,(t=l==null?void 0:l.classNames)==null?void 0:t.toast,x==null?void 0:x.default,x==null?void 0:x[K],(n=l==null?void 0:l.classNames)==null?void 0:n[K]),"data-sonner-toast":"","data-rich-colors":(r=l.richColors)!=null?r:M,"data-styled":!(l.jsx||l.unstyled||w),"data-mounted":P,"data-promise":!!l.promise,"data-swiped":Zn,"data-removed":xe,"data-visible":rr,"data-y-position":ir,"data-x-position":lr,"data-index":T,"data-front":nr,"data-swiping":Re,"data-dismissible":we,"data-type":K,"data-invert":cr,"data-swipe-out":Pt,"data-swipe-direction":j,"data-expanded":!!(A||Be&&P),style:{"--index":T,"--toasts-before":T,"--z-index":D.length-T,"--offset":`${xe?er:be.current}px`,"--initial-height":Be?"auto":`${tr}px`,...ne,...l.style},onDragEnd:()=>{at(!1),N(null),ye.current=null},onPointerDown:y=>{ct||!we||(Bt.current=new Date,it(be.current),y.target.setPointerCapture(y.pointerId),y.target.tagName!=="BUTTON"&&(at(!0),ye.current={x:y.clientX,y:y.clientY}))},onPointerUp:()=>{var y,C,L,X;if(Pt||!we)return;ye.current=null;let Q=Number(((y=ue.current)==null?void 0:y.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),ie=Number(((C=ue.current)==null?void 0:C.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),de=new Date().getTime()-((L=Bt.current)==null?void 0:L.getTime()),Z=O==="x"?Q:ie,le=Math.abs(Z)/de;if(Math.abs(Z)>=Fr||le>.11){it(be.current),(X=l.onDismiss)==null||X.call(l,l),ge(O==="x"?Q>0?"right":"left":ie>0?"down":"up"),ae(),Qn(!0),It(!1);return}at(!1),N(null)},onPointerMove:y=>{var C,L,X,Q;if(!ye.current||!we||((C=window.getSelection())==null?void 0:C.toString().length)>0)return;let ie=y.clientY-ye.current.y,de=y.clientX-ye.current.x,Z=(L=e.swipeDirections)!=null?L:zr(De);!O&&(Math.abs(de)>1||Math.abs(ie)>1)&&N(Math.abs(de)>Math.abs(ie)?"x":"y");let le={x:0,y:0};O==="y"?(Z.includes("top")||Z.includes("bottom"))&&(Z.includes("top")&&ie<0||Z.includes("bottom")&&ie>0)&&(le.y=ie):O==="x"&&(Z.includes("left")||Z.includes("right"))&&(Z.includes("left")&&de<0||Z.includes("right")&&de>0)&&(le.x=de),(Math.abs(le.x)>0||Math.abs(le.y)>0)&&It(!0),(X=ue.current)==null||X.style.setProperty("--swipe-amount-x",`${le.x}px`),(Q=ue.current)==null||Q.style.setProperty("--swipe-amount-y",`${le.y}px`)}},ar&&!l.jsx?c.createElement("button",{"aria-label":ot,"data-disabled":ct,"data-close-button":!0,onClick:ct||!we?()=>{}:()=>{var y;ae(),(y=l.onDismiss)==null||y.call(l,l)},className:ee(x==null?void 0:x.closeButton,(o=l==null?void 0:l.classNames)==null?void 0:o.closeButton)},(a=$==null?void 0:$.close)!=null?a:Rr):null,l.jsx||c.isValidElement(l.title)?l.jsx?l.jsx:typeof l.title=="function"?l.title():l.title:c.createElement(c.Fragment,null,K||l.icon||l.promise?c.createElement("div",{"data-icon":"",className:ee(x==null?void 0:x.icon,(s=l==null?void 0:l.classNames)==null?void 0:s.icon)},l.promise||l.type==="loading"&&!l.icon?l.icon||ur():null,l.type!=="loading"?l.icon||($==null?void 0:$[K])||wr(K):null):null,c.createElement("div",{"data-content":"",className:ee(x==null?void 0:x.content,(i=l==null?void 0:l.classNames)==null?void 0:i.content)},c.createElement("div",{"data-title":"",className:ee(x==null?void 0:x.title,(d=l==null?void 0:l.classNames)==null?void 0:d.title)},typeof l.title=="function"?l.title():l.title),l.description?c.createElement("div",{"data-description":"",className:ee(Ie,sr,x==null?void 0:x.description,(u=l==null?void 0:l.classNames)==null?void 0:u.description)},typeof l.description=="function"?l.description():l.description):null),c.isValidElement(l.cancel)?l.cancel:l.cancel&&je(l.cancel)?c.createElement("button",{"data-button":!0,"data-cancel":!0,style:l.cancelButtonStyle||rt,onClick:y=>{var C,L;je(l.cancel)&&we&&((L=(C=l.cancel).onClick)==null||L.call(C,y),ae())},className:ee(x==null?void 0:x.cancelButton,(p=l==null?void 0:l.classNames)==null?void 0:p.cancelButton)},l.cancel.label):null,c.isValidElement(l.action)?l.action:l.action&&je(l.action)?c.createElement("button",{"data-button":!0,"data-action":!0,style:l.actionButtonStyle||Pe,onClick:y=>{var C,L;je(l.action)&&((L=(C=l.action).onClick)==null||L.call(C,y),!y.defaultPrevented&&ae())},className:ee(x==null?void 0:x.actionButton,(m=l==null?void 0:l.classNames)==null?void 0:m.actionButton)},l.action.label):null))};function $t(){if(typeof window>"u"||typeof document>"u")return"ltr";let e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}function qr(e,t){let n={};return[e,t].forEach((r,o)=>{let a=o===1,s=a?"--mobile-offset":"--offset",i=a?Dr:Ir;function d(u){["top","right","bottom","left"].forEach(p=>{n[`${s}-${p}`]=typeof u=="number"?`${u}px`:u})}typeof r=="number"||typeof r=="string"?d(r):typeof r=="object"?["top","right","bottom","left"].forEach(u=>{r[u]===void 0?n[`${s}-${u}`]=i:n[`${s}-${u}`]=typeof r[u]=="number"?`${r[u]}px`:r[u]}):d(i)}),n}c.forwardRef(function(e,t){let{invert:n,position:r="bottom-right",hotkey:o=["altKey","KeyT"],expand:a,closeButton:s,className:i,offset:d,mobileOffset:u,theme:p="light",richColors:m,duration:h,style:l,visibleToasts:w=Pr,toastOptions:g,dir:b=$t(),gap:R=Ur,loadingIcon:E,icons:T,containerAriaLabel:D="Notifications",pauseWhenPageIsHidden:A}=e,[S,M]=c.useState([]),F=c.useMemo(()=>Array.from(new Set([r].concat(S.filter(k=>k.position).map(k=>k.position)))),[S,r]),[ne,rt]=c.useState([]),[Pe,oe]=c.useState(!1),[Ie,me]=c.useState(!1),[De,ce]=c.useState(p!=="system"?p:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),se=c.useRef(null),Be=o.join("+").replace(/Key/g,"").replace(/Digit/g,""),x=c.useRef(null),$=c.useRef(!1),ot=c.useCallback(k=>{M(O=>{var N;return(N=O.find(j=>j.id===k.id))!=null&&N.delete||z.dismiss(k.id),O.filter(({id:j})=>j!==k.id)})},[]);return c.useEffect(()=>z.subscribe(k=>{if(k.dismiss){M(O=>O.map(N=>N.id===k.id?{...N,delete:!0}:N));return}setTimeout(()=>{dr.flushSync(()=>{M(O=>{let N=O.findIndex(j=>j.id===k.id);return N!==-1?[...O.slice(0,N),{...O[N],...k},...O.slice(N+1)]:[k,...O]})})})}),[]),c.useEffect(()=>{if(p!=="system"){ce(p);return}if(p==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?ce("dark"):ce("light")),typeof window>"u")return;let k=window.matchMedia("(prefers-color-scheme: dark)");try{k.addEventListener("change",({matches:O})=>{ce(O?"dark":"light")})}catch{k.addListener(({matches:N})=>{try{ce(N?"dark":"light")}catch(j){console.error(j)}})}},[p]),c.useEffect(()=>{S.length<=1&&oe(!1)},[S]),c.useEffect(()=>{let k=O=>{var N,j;o.every(ge=>O[ge]||O.code===ge)&&(oe(!0),(N=se.current)==null||N.focus()),O.code==="Escape"&&(document.activeElement===se.current||(j=se.current)!=null&&j.contains(document.activeElement))&&oe(!1)};return document.addEventListener("keydown",k),()=>document.removeEventListener("keydown",k)},[o]),c.useEffect(()=>{if(se.current)return()=>{x.current&&(x.current.focus({preventScroll:!0}),x.current=null,$.current=!1)}},[se.current]),c.createElement("section",{ref:t,"aria-label":`${D} ${Be}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},F.map((k,O)=>{var N;let[j,ge]=k.split("-");return S.length?c.createElement("ol",{key:k,dir:b==="auto"?$t():b,tabIndex:-1,ref:se,className:i,"data-sonner-toaster":!0,"data-theme":De,"data-y-position":j,"data-lifted":Pe&&S.length>1&&!a,"data-x-position":ge,style:{"--front-toast-height":`${((N=ne[0])==null?void 0:N.height)||0}px`,"--width":`${Br}px`,"--gap":`${R}px`,...l,...qr(d,u)},onBlur:P=>{$.current&&!P.currentTarget.contains(P.relatedTarget)&&($.current=!1,x.current&&(x.current.focus({preventScroll:!0}),x.current=null))},onFocus:P=>{P.target instanceof HTMLElement&&P.target.dataset.dismissible==="false"||$.current||($.current=!0,x.current=P.relatedTarget)},onMouseEnter:()=>oe(!0),onMouseMove:()=>oe(!0),onMouseLeave:()=>{Ie||oe(!1)},onDragEnd:()=>oe(!1),onPointerDown:P=>{P.target instanceof HTMLElement&&P.target.dataset.dismissible==="false"||me(!0)},onPointerUp:()=>me(!1)},S.filter(P=>!P.position&&O===0||P.position===k).map((P,st)=>{var xe,Ue;return c.createElement(Hr,{key:P.id,icons:T,index:st,toast:P,defaultRichColors:m,duration:(xe=g==null?void 0:g.duration)!=null?xe:h,className:g==null?void 0:g.className,descriptionClassName:g==null?void 0:g.descriptionClassName,invert:n,visibleToasts:w,closeButton:(Ue=g==null?void 0:g.closeButton)!=null?Ue:s,interacting:Ie,position:k,style:g==null?void 0:g.style,unstyled:g==null?void 0:g.unstyled,classNames:g==null?void 0:g.classNames,cancelButtonStyle:g==null?void 0:g.cancelButtonStyle,actionButtonStyle:g==null?void 0:g.actionButtonStyle,removeToast:ot,toasts:S.filter(Re=>Re.position==P.position),heights:ne.filter(Re=>Re.position==P.position),setHeights:rt,expandByDefault:a,gap:R,loadingIcon:E,expanded:Pe,pauseWhenPageIsHidden:A,swipeDirections:e.swipeDirections})})):null}))});function wn(){return{toast:async({id:t,title:n,description:r,action:o={label:"",onClick:()=>{}},...a})=>{const s={description:r};o.label&&(s.action={label:o.label,onClick:o.onClick}),Nr(n,s)}}}var ze=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function $r(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Vr="Expected a function",Vt=NaN,Wr="[object Symbol]",Jr=/^\s+|\s+$/g,Kr=/^[-+]0x[0-9a-f]+$/i,Yr=/^0b[01]+$/i,Gr=/^0o[0-7]+$/i,Xr=parseInt,Qr=typeof ze=="object"&&ze&&ze.Object===Object&&ze,Zr=typeof self=="object"&&self&&self.Object===Object&&self,eo=Qr||Zr||Function("return this")(),to=Object.prototype,no=to.toString,ro=Math.max,oo=Math.min,dt=function(){return eo.Date.now()};function so(e,t,n){var r,o,a,s,i,d,u=0,p=!1,m=!1,h=!0;if(typeof e!="function")throw new TypeError(Vr);t=Wt(t)||0,vt(n)&&(p=!!n.leading,m="maxWait"in n,a=m?ro(Wt(n.maxWait)||0,t):a,h="trailing"in n?!!n.trailing:h);function l(S){var M=r,F=o;return r=o=void 0,u=S,s=e.apply(F,M),s}function w(S){return u=S,i=setTimeout(R,t),p?l(S):s}function g(S){var M=S-d,F=S-u,ne=t-M;return m?oo(ne,a-F):ne}function b(S){var M=S-d,F=S-u;return d===void 0||M>=t||M<0||m&&F>=a}function R(){var S=dt();if(b(S))return E(S);i=setTimeout(R,g(S))}function E(S){return i=void 0,h&&r?l(S):(r=o=void 0,s)}function T(){i!==void 0&&clearTimeout(i),u=0,r=d=o=i=void 0}function D(){return i===void 0?s:E(dt())}function A(){var S=dt(),M=b(S);if(r=arguments,o=this,d=S,M){if(i===void 0)return w(d);if(m)return i=setTimeout(R,t),l(d)}return i===void 0&&(i=setTimeout(R,t)),s}return A.cancel=T,A.flush=D,A}function vt(e){var t=typeof e;return!!e&&(t=="object"||t=="function")}function ao(e){return!!e&&typeof e=="object"}function io(e){return typeof e=="symbol"||ao(e)&&no.call(e)==Wr}function Wt(e){if(typeof e=="number")return e;if(io(e))return Vt;if(vt(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=vt(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=e.replace(Jr,"");var n=Yr.test(e);return n||Gr.test(e)?Xr(e.slice(2),n?2:8):Kr.test(e)?Vt:+e}var lo=so;const Jt=$r(lo);function bn(e=!1){if(typeof e!="boolean")throw new Error("defaultValue must be `true` or `false`");const[t,n]=c.useState(e),r=c.useCallback(()=>{n(!0)},[]),o=c.useCallback(()=>{n(!1)},[]),a=c.useCallback(()=>{n(s=>!s)},[]);return{value:t,setValue:n,setTrue:r,setFalse:o,toggle:a}}var G=typeof window<"u"?c.useLayoutEffect:c.useEffect;function q(e,t,n,r){const o=c.useRef(t);G(()=>{o.current=t},[t]),c.useEffect(()=>{const a=(n==null?void 0:n.current)??window;if(!(a&&a.addEventListener))return;const s=i=>{o.current(i)};return a.addEventListener(e,s,r),()=>{a.removeEventListener(e,s,r)}},[e,n,r])}function co(e){q("click",t=>{e(t)})}var ft="useCopyToClipboard";function uo(){const[e,t]=c.useState(null),{toast:n}=wn(),r=c.useCallback(async a=>{if(!(navigator!=null&&navigator.clipboard))return B.log(ft,"not supported"),!1;try{return await navigator.clipboard.writeText(a),t(a),!0}catch(s){return B.error(ft,"Copy failed",s),t(null),!1}},[]);return{value:e,copy:r,copyWithToast:async(a="",s="copied to clipboard")=>{const i=await r(a);return i&&(B.debug(ft,s),n({title:s})),i}}}function yn(e){const[t,n]=c.useState(e??0),r=c.useCallback(()=>{n(s=>s+1)},[]),o=c.useCallback(()=>{n(s=>s-1)},[]),a=c.useCallback(()=>{n(e??0)},[e]);return{count:t,increment:r,decrement:o,reset:a,setCount:n}}function vn(e,t){const n=c.useRef(e);G(()=>{n.current=e},[e]),c.useEffect(()=>{if(t===null)return;const r=setInterval(()=>{n.current()},t);return()=>{clearInterval(r)}},[t])}function fo({countStart:e,countStop:t=0,intervalMs:n=1e3,isIncrement:r=!1}){const{count:o,increment:a,decrement:s,reset:i}=yn(e),{value:d,setTrue:u,setFalse:p}=bn(!1),m=c.useCallback(()=>{p(),i()},[p,i]),h=c.useCallback(()=>{if(o===t){p();return}r?a():s()},[o,t,s,a,r,p]);return vn(h,d?n:null),[o,{startCountdown:u,stopCountdown:p,resetCountdown:m}]}function Ae(e){const t=c.useRef(()=>{throw new Error("Cannot call an event handler while rendering.")});return G(()=>{t.current=e},[e]),c.useCallback((...n)=>{var r;return(r=t.current)==null?void 0:r.call(t,...n)},[t])}var ke="useLocalStorage",pt=typeof window>"u";function kt(e,t,n={}){const{initializeWithValue:r=!0}=n,o=c.useCallback(h=>n.serializer?n.serializer(h):JSON.stringify(h),[n]),a=c.useCallback(h=>{if(n.deserializer)return n.deserializer(h);if(h==="undefined")return;const l=t instanceof Function?t():t;let w;try{w=JSON.parse(h)}catch(g){return B.error(ke,"Error parsing JSON:",g),l}return w},[n,t]),s=c.useCallback(()=>{const h=t instanceof Function?t():t;if(pt)return h;try{const l=window.localStorage.getItem(e);return l?a(l):h}catch(l){return B.error(ke,`Error reading localStorage key “${e}”:`,l),h}},[t,e,a]),[i,d]=c.useState(()=>r?s():t instanceof Function?t():t),u=Ae(h=>{pt&&B.warn(ke,`Tried setting localStorage key “${e}” even though environment is not a client`);try{const l=h instanceof Function?h(s()):h;window.localStorage.setItem(e,o(l)),d(l),window.dispatchEvent(new StorageEvent("local-storage",{key:e}))}catch(l){B.warn(ke,`Error setting localStorage key “${e}”:`,l)}}),p=Ae(()=>{pt&&B.warn(ke,`Tried removing localStorage key “${e}” even though environment is not a client`);const h=t instanceof Function?t():t;window.localStorage.removeItem(e),d(h),window.dispatchEvent(new StorageEvent("local-storage",{key:e}))});c.useEffect(()=>{d(s())},[e]);const m=c.useCallback(h=>{h.key&&h.key!==e||d(s())},[e,s]);return q("storage",m),q("local-storage",m),[i,u,p]}var po=typeof window>"u";function Ot(e,{defaultValue:t=!1,initializeWithValue:n=!0}={}){const r=i=>po?t:window.matchMedia(i).matches,[o,a]=c.useState(()=>n?r(e):t);function s(){a(r(e))}return G(()=>{const i=window.matchMedia(e);return s(),i.addListener?i.addListener(s):i.addEventListener("change",s),()=>{i.removeListener?i.removeListener(s):i.removeEventListener("change",s)}},[e]),o}var ho="(prefers-color-scheme: dark)",mo="usehooks-ts-dark-mode";function go(e={}){const{defaultValue:t,localStorageKey:n=mo,initializeWithValue:r=!0}=e,o=Ot(ho,{initializeWithValue:r,defaultValue:t}),[a,s]=kt(n,t??o??!1,{initializeWithValue:r});return G(()=>{o!==a&&s(o)},[o]),{isDarkMode:a,toggle:()=>{s(i=>!i)},enable:()=>{s(!0)},disable:()=>{s(!1)},set:i=>{s(i)}}}function At(e){const t=c.useRef(e);t.current=e,c.useEffect(()=>()=>{t.current()},[])}function Ge(e,t=500,n){const r=c.useRef();At(()=>{r.current&&r.current.cancel()});const o=c.useMemo(()=>{const a=Jt(e,t,n),s=(...i)=>a(...i);return s.cancel=()=>{a.cancel()},s.isPending=()=>!!r.current,s.flush=()=>a.flush(),s},[e,t,n]);return c.useEffect(()=>{r.current=Jt(e,t,n)},[e,t,n]),o}function wo(e,t,n){const r=(n==null?void 0:n.equalityFn)??((u,p)=>u===p),o=e instanceof Function?e():e,[a,s]=c.useState(o),i=c.useRef(o),d=Ge(s,t,n);return r(i.current,o)||(d(o),i.current=o),[a,d]}function bo(e,t={}){const{preserveTitleOnUnmount:n=!0}=t,r=c.useRef(null);G(()=>{r.current=window.document.title},[]),G(()=>{window.document.title=e},[e]),At(()=>{!n&&r.current&&(window.document.title=r.current)})}function Sn(){const e=c.useRef(!0);return e.current?(e.current=!1,!0):e.current}function yo(e,t){const n=Sn();c.useEffect(()=>{if(!n)return e()},t)}function vo(e){const[t,n]=c.useState(!1),r=()=>{n(!0)},o=()=>{n(!1)};return q("mouseenter",r,e),q("mouseleave",o,e),t}function So({threshold:e=0,root:t=null,rootMargin:n="0%",freezeOnceVisible:r=!1,initialIsIntersecting:o=!1,onChange:a}={}){var s;const[i,d]=c.useState(null),[u,p]=c.useState(()=>({isIntersecting:o,entry:void 0})),m=c.useRef();m.current=a;const h=((s=u.entry)==null?void 0:s.isIntersecting)&&r;c.useEffect(()=>{if(!i||!("IntersectionObserver"in window)||h)return;const g=new IntersectionObserver(b=>{const R=Array.isArray(g.thresholds)?g.thresholds:[g.thresholds];b.forEach(E=>{const T=E.isIntersecting&&R.some(D=>E.intersectionRatio>=D);p({isIntersecting:T,entry:E}),m.current&&m.current(T,E)})},{threshold:e,root:t,rootMargin:n});return g.observe(i),()=>{g.disconnect()}},[i,JSON.stringify(e),t,n,h,r]);const l=c.useRef(null);c.useEffect(()=>{var g;!i&&((g=u.entry)!=null&&g.target)&&!r&&!h&&l.current!==u.entry.target&&(l.current=u.entry.target,p({isIntersecting:o,entry:void 0}))},[i,u.entry,r,h,o]);const w=[d,!!u.isIntersecting,u.entry];return w.ref=w[0],w.isIntersecting=w[1],w.entry=w[2],w}function Eo(){const[e,t]=c.useState(!1);return c.useEffect(()=>{t(!0)},[]),e}function En(){const e=c.useRef(!1);return c.useEffect(()=>(e.current=!0,()=>{e.current=!1}),[]),c.useCallback(()=>e.current,[])}function xo(e=new Map){const[t,n]=c.useState(new Map(e)),r={set:c.useCallback((o,a)=>{n(s=>{const i=new Map(s);return i.set(o,a),i})},[]),setAll:c.useCallback(o=>{n(()=>new Map(o))},[]),remove:c.useCallback(o=>{n(a=>{const s=new Map(a);return s.delete(o),s})},[]),reset:c.useCallback(()=>{n(()=>new Map)},[])};return[t,r]}function Ro(e,t,n="mousedown",r={}){q(n,o=>{const a=o.target;if(!(a!=null&&a.isConnected))return;(Array.isArray(e)?e.filter(i=>!!i.current).every(i=>i.current&&!i.current.contains(a)):e.current&&!e.current.contains(a))&&t(o)},void 0,r)}var Kt=typeof window>"u";function To(e,t={}){let{initializeWithValue:n=!0}=t;Kt&&(n=!1);const r=c.useCallback(d=>{if(t.deserializer)return t.deserializer(d);if(d==="undefined")return;let u;try{u=JSON.parse(d)}catch(p){return console.error("Error parsing JSON:",p),null}return u},[t]),o=c.useCallback(()=>{if(Kt)return null;try{const d=window.localStorage.getItem(e);return d?r(d):null}catch(d){return console.warn(`Error reading localStorage key “${e}”:`,d),null}},[e,r]),[a,s]=c.useState(()=>{if(n)return o()});c.useEffect(()=>{s(o())},[e]);const i=c.useCallback(d=>{d.key&&d.key!==e||s(o())},[e,o]);return q("storage",i),q("local-storage",i),a}var Yt={width:void 0,height:void 0};function Co(e){const{ref:t,box:n="content-box"}=e,[{width:r,height:o},a]=c.useState(Yt),s=En(),i=c.useRef({...Yt}),d=c.useRef(void 0);return d.current=e.onResize,c.useEffect(()=>{if(!t.current||typeof window>"u"||!("ResizeObserver"in window))return;const u=new ResizeObserver(([p])=>{const m=n==="border-box"?"borderBoxSize":n==="device-pixel-content-box"?"devicePixelContentBoxSize":"contentBoxSize",h=Gt(p,m,"inlineSize"),l=Gt(p,m,"blockSize");if(i.current.width!==h||i.current.height!==l){const g={width:h,height:l};i.current.width=h,i.current.height=l,d.current?d.current(g):s()&&a(g)}});return u.observe(t.current,{box:n}),()=>{u.disconnect()}},[n,t,s]),{width:r,height:o}}function Gt(e,t,n){return e[t]?Array.isArray(e[t])?e[t][0][n]:e[t][n]:t==="contentBoxSize"?e.contentRect[n==="inlineSize"?"width":"height"]:void 0}var Xt=typeof window>"u";function _o(e={}){let{initializeWithValue:t=!0}=e;Xt&&(t=!1);const n=()=>{if(!Xt)return window.screen},[r,o]=c.useState(()=>{if(t)return n()}),a=Ge(o,e.debounceDelay);function s(){const i=n(),d=e.debounceDelay?a:o;if(i){const{width:u,height:p,availHeight:m,availWidth:h,colorDepth:l,orientation:w,pixelDepth:g}=i;d({width:u,height:p,availHeight:m,availWidth:h,colorDepth:l,orientation:w,pixelDepth:g})}}return q("resize",s),G(()=>{s()},[]),r}var He=new Map;function ko(e){const t=document.querySelector(`script[src="${e}"]`),n=t==null?void 0:t.getAttribute("data-status");return{node:t,status:n}}function Oo(e,t){const[n,r]=c.useState(()=>!e||t!=null&&t.shouldPreventLoad?"idle":typeof window>"u"?"loading":He.get(e)??"loading");return c.useEffect(()=>{if(!e||t!=null&&t.shouldPreventLoad)return;const o=He.get(e);if(o==="ready"||o==="error"){r(o);return}const a=ko(e);let s=a.node;if(s)r(a.status??o??"loading");else{s=document.createElement("script"),s.src=e,s.async=!0,t!=null&&t.id&&(s.id=t.id),s.setAttribute("data-status","loading"),document.body.appendChild(s);const d=u=>{const p=u.type==="load"?"ready":"error";s==null||s.setAttribute("data-status",p)};s.addEventListener("load",d),s.addEventListener("error",d)}const i=d=>{const u=d.type==="load"?"ready":"error";r(u),He.set(e,u)};return s.addEventListener("load",i),s.addEventListener("error",i),()=>{s&&(s.removeEventListener("load",i),s.removeEventListener("error",i)),s&&(t!=null&&t.removeOnUnmount)&&(s.remove(),He.delete(e))}},[e,t==null?void 0:t.shouldPreventLoad,t==null?void 0:t.removeOnUnmount,t==null?void 0:t.id]),n}var Ao=typeof window>"u";function Lo(e={}){const{autoLock:t=!0,lockTarget:n,widthReflow:r=!0}=e,[o,a]=c.useState(!1),s=c.useRef(null),i=c.useRef(null),d=()=>{if(s.current){const{overflow:p,paddingRight:m}=s.current.style;if(i.current={overflow:p,paddingRight:m},r){const h=s.current===document.body?window.innerWidth:s.current.offsetWidth,l=parseInt(window.getComputedStyle(s.current).paddingRight,10)||0,w=h-s.current.scrollWidth;s.current.style.paddingRight=`${w+l}px`}s.current.style.overflow="hidden",a(!0)}},u=()=>{s.current&&i.current&&(s.current.style.overflow=i.current.overflow,r&&(s.current.style.paddingRight=i.current.paddingRight)),a(!1)};return G(()=>{if(!Ao)return n&&(s.current=typeof n=="string"?document.querySelector(n):n),s.current||(s.current=document.body),t&&d(),()=>{u()}},[t,n,r]),{isLocked:o,lock:d,unlock:u}}var ht=typeof window>"u";function No(e,t,n={}){const{initializeWithValue:r=!0}=n,o=c.useCallback(h=>n.serializer?n.serializer(h):JSON.stringify(h),[n]),a=c.useCallback(h=>{if(n.deserializer)return n.deserializer(h);if(h==="undefined")return;const l=t instanceof Function?t():t;let w;try{w=JSON.parse(h)}catch(g){return console.error("Error parsing JSON:",g),l}return w},[n,t]),s=c.useCallback(()=>{const h=t instanceof Function?t():t;if(ht)return h;try{const l=window.sessionStorage.getItem(e);return l?a(l):h}catch(l){return console.warn(`Error reading sessionStorage key “${e}”:`,l),h}},[t,e,a]),[i,d]=c.useState(()=>r?s():t instanceof Function?t():t),u=Ae(h=>{ht&&console.warn(`Tried setting sessionStorage key “${e}” even though environment is not a client`);try{const l=h instanceof Function?h(s()):h;window.sessionStorage.setItem(e,o(l)),d(l),window.dispatchEvent(new StorageEvent("session-storage",{key:e}))}catch(l){console.warn(`Error setting sessionStorage key “${e}”:`,l)}}),p=Ae(()=>{ht&&console.warn(`Tried removing sessionStorage key “${e}” even though environment is not a client`);const h=t instanceof Function?t():t;window.sessionStorage.removeItem(e),d(h),window.dispatchEvent(new StorageEvent("session-storage",{key:e}))});c.useEffect(()=>{d(s())},[e]);const m=c.useCallback(h=>{h.key&&h.key!==e||d(s())},[e,s]);return q("storage",m),q("session-storage",m),[i,u,p]}function Mo(e){const[t,n]=c.useState(1),r=t+1<=e,o=t-1>0,a=c.useCallback(u=>{const p=u instanceof Function?u(t):u;if(p>=1&&p<=e){n(p);return}throw new Error("Step not valid")},[e,t]),s=c.useCallback(()=>{r&&n(u=>u+1)},[r]),i=c.useCallback(()=>{o&&n(u=>u-1)},[o]),d=c.useCallback(()=>{n(1)},[]);return[t,{goToNextStep:s,goToPrevStep:i,canGoToNextStep:r,canGoToPrevStep:o,setStep:a,reset:d}]}var Po="(prefers-color-scheme: dark)",Io="usehooks-ts-ternary-dark-mode";function Do({defaultValue:e="system",localStorageKey:t=Io,initializeWithValue:n=!0}={}){const r=Ot(Po,{initializeWithValue:n}),[o,a]=kt(t,e,{initializeWithValue:n});return{isDarkMode:o==="dark"||o==="system"&&r,ternaryDarkMode:o,setTernaryDarkMode:a,toggleTernaryDarkMode:()=>{const d=["light","system","dark"];a(u=>{const p=(d.indexOf(u)+1)%d.length;return d[p]})}}}function Bo(e,t){const n=c.useRef(e);G(()=>{n.current=e},[e]),c.useEffect(()=>{if(!t&&t!==0)return;const r=setTimeout(()=>{n.current()},t);return()=>{clearTimeout(r)}},[t])}function Uo(e){const[t,n]=c.useState(!!e),r=c.useCallback(()=>{n(o=>!o)},[]);return[t,r,n]}var Fo=typeof window>"u";function jo(e={}){let{initializeWithValue:t=!0}=e;Fo&&(t=!1);const[n,r]=c.useState(()=>t?{width:window.innerWidth,height:window.innerHeight}:{width:void 0,height:void 0}),o=Ge(r,e.debounceDelay);function a(){(e.debounceDelay?o:r)({width:window.innerWidth,height:window.innerHeight})}return q("resize",a),G(()=>{a()},[]),n}function xn(e,t){return function(){return e.apply(t,arguments)}}const{toString:zo}=Object.prototype,{getPrototypeOf:Lt}=Object,Xe=(e=>t=>{const n=zo.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),te=e=>(e=e.toLowerCase(),t=>Xe(t)===e),Qe=e=>t=>typeof t===e,{isArray:Se}=Array,Le=Qe("undefined");function Ho(e){return e!==null&&!Le(e)&&e.constructor!==null&&!Le(e.constructor)&&J(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const Rn=te("ArrayBuffer");function qo(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&Rn(e.buffer),t}const $o=Qe("string"),J=Qe("function"),Tn=Qe("number"),Ze=e=>e!==null&&typeof e=="object",Vo=e=>e===!0||e===!1,Ve=e=>{if(Xe(e)!=="object")return!1;const t=Lt(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},Wo=te("Date"),Jo=te("File"),Ko=te("Blob"),Yo=te("FileList"),Go=e=>Ze(e)&&J(e.pipe),Xo=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||J(e.append)&&((t=Xe(e))==="formdata"||t==="object"&&J(e.toString)&&e.toString()==="[object FormData]"))},Qo=te("URLSearchParams"),[Zo,es,ts,ns]=["ReadableStream","Request","Response","Headers"].map(te),rs=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Ne(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e>"u")return;let r,o;if(typeof e!="object"&&(e=[e]),Se(e))for(r=0,o=e.length;r<o;r++)t.call(null,e[r],r,e);else{const a=n?Object.getOwnPropertyNames(e):Object.keys(e),s=a.length;let i;for(r=0;r<s;r++)i=a[r],t.call(null,e[i],i,e)}}function Cn(e,t){t=t.toLowerCase();const n=Object.keys(e);let r=n.length,o;for(;r-- >0;)if(o=n[r],t===o.toLowerCase())return o;return null}const fe=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,_n=e=>!Le(e)&&e!==fe;function St(){const{caseless:e}=_n(this)&&this||{},t={},n=(r,o)=>{const a=e&&Cn(t,o)||o;Ve(t[a])&&Ve(r)?t[a]=St(t[a],r):Ve(r)?t[a]=St({},r):Se(r)?t[a]=r.slice():t[a]=r};for(let r=0,o=arguments.length;r<o;r++)arguments[r]&&Ne(arguments[r],n);return t}const os=(e,t,n,{allOwnKeys:r}={})=>(Ne(t,(o,a)=>{n&&J(o)?e[a]=xn(o,n):e[a]=o},{allOwnKeys:r}),e),ss=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),as=(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)},is=(e,t,n,r)=>{let o,a,s;const i={};if(t=t||{},e==null)return t;do{for(o=Object.getOwnPropertyNames(e),a=o.length;a-- >0;)s=o[a],(!r||r(s,e,t))&&!i[s]&&(t[s]=e[s],i[s]=!0);e=n!==!1&&Lt(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},ls=(e,t,n)=>{e=String(e),(n===void 0||n>e.length)&&(n=e.length),n-=t.length;const r=e.indexOf(t,n);return r!==-1&&r===n},cs=e=>{if(!e)return null;if(Se(e))return e;let t=e.length;if(!Tn(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},us=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&Lt(Uint8Array)),ds=(e,t)=>{const r=(e&&e[Symbol.iterator]).call(e);let o;for(;(o=r.next())&&!o.done;){const a=o.value;t.call(e,a[0],a[1])}},fs=(e,t)=>{let n;const r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},ps=te("HTMLFormElement"),hs=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,o){return r.toUpperCase()+o}),Qt=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),ms=te("RegExp"),kn=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};Ne(n,(o,a)=>{let s;(s=t(o,a,e))!==!1&&(r[a]=s||o)}),Object.defineProperties(e,r)},gs=e=>{kn(e,(t,n)=>{if(J(e)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const r=e[n];if(J(r)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},ws=(e,t)=>{const n={},r=o=>{o.forEach(a=>{n[a]=!0})};return Se(e)?r(e):r(String(e).split(t)),n},bs=()=>{},ys=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function vs(e){return!!(e&&J(e.append)&&e[Symbol.toStringTag]==="FormData"&&e[Symbol.iterator])}const Ss=e=>{const t=new Array(10),n=(r,o)=>{if(Ze(r)){if(t.indexOf(r)>=0)return;if(!("toJSON"in r)){t[o]=r;const a=Se(r)?[]:{};return Ne(r,(s,i)=>{const d=n(s,o+1);!Le(d)&&(a[i]=d)}),t[o]=void 0,a}}return r};return n(e,0)},Es=te("AsyncFunction"),xs=e=>e&&(Ze(e)||J(e))&&J(e.then)&&J(e.catch),On=((e,t)=>e?setImmediate:t?((n,r)=>(fe.addEventListener("message",({source:o,data:a})=>{o===fe&&a===n&&r.length&&r.shift()()},!1),o=>{r.push(o),fe.postMessage(n,"*")}))(`axios@${Math.random()}`,[]):n=>setTimeout(n))(typeof setImmediate=="function",J(fe.postMessage)),Rs=typeof queueMicrotask<"u"?queueMicrotask.bind(fe):typeof process<"u"&&process.nextTick||On,f={isArray:Se,isArrayBuffer:Rn,isBuffer:Ho,isFormData:Xo,isArrayBufferView:qo,isString:$o,isNumber:Tn,isBoolean:Vo,isObject:Ze,isPlainObject:Ve,isReadableStream:Zo,isRequest:es,isResponse:ts,isHeaders:ns,isUndefined:Le,isDate:Wo,isFile:Jo,isBlob:Ko,isRegExp:ms,isFunction:J,isStream:Go,isURLSearchParams:Qo,isTypedArray:us,isFileList:Yo,forEach:Ne,merge:St,extend:os,trim:rs,stripBOM:ss,inherits:as,toFlatObject:is,kindOf:Xe,kindOfTest:te,endsWith:ls,toArray:cs,forEachEntry:ds,matchAll:fs,isHTMLForm:ps,hasOwnProperty:Qt,hasOwnProp:Qt,reduceDescriptors:kn,freezeMethods:gs,toObjectSet:ws,toCamelCase:hs,noop:bs,toFiniteNumber:ys,findKey:Cn,global:fe,isContextDefined:_n,isSpecCompliantForm:vs,toJSONObject:Ss,isAsyncFn:Es,isThenable:xs,setImmediate:On,asap:Rs};function v(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,this.status=o.status?o.status:null)}f.inherits(v,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:f.toJSONObject(this.config),code:this.code,status:this.status}}});const An=v.prototype,Ln={};["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=>{Ln[e]={value:e}});Object.defineProperties(v,Ln);Object.defineProperty(An,"isAxiosError",{value:!0});v.from=(e,t,n,r,o,a)=>{const s=Object.create(An);return f.toFlatObject(e,s,function(d){return d!==Error.prototype},i=>i!=="isAxiosError"),v.call(s,e.message,t,n,r,o),s.cause=e,s.name=e.name,a&&Object.assign(s,a),s};const Ts=null;function Et(e){return f.isPlainObject(e)||f.isArray(e)}function Nn(e){return f.endsWith(e,"[]")?e.slice(0,-2):e}function Zt(e,t,n){return e?e.concat(t).map(function(o,a){return o=Nn(o),!n&&a?"["+o+"]":o}).join(n?".":""):t}function Cs(e){return f.isArray(e)&&!e.some(Et)}const _s=f.toFlatObject(f,{},null,function(t){return/^is[A-Z]/.test(t)});function et(e,t,n){if(!f.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=f.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(g,b){return!f.isUndefined(b[g])});const r=n.metaTokens,o=n.visitor||p,a=n.dots,s=n.indexes,d=(n.Blob||typeof Blob<"u"&&Blob)&&f.isSpecCompliantForm(t);if(!f.isFunction(o))throw new TypeError("visitor must be a function");function u(w){if(w===null)return"";if(f.isDate(w))return w.toISOString();if(!d&&f.isBlob(w))throw new v("Blob is not supported. Use a Buffer instead.");return f.isArrayBuffer(w)||f.isTypedArray(w)?d&&typeof Blob=="function"?new Blob([w]):Buffer.from(w):w}function p(w,g,b){let R=w;if(w&&!b&&typeof w=="object"){if(f.endsWith(g,"{}"))g=r?g:g.slice(0,-2),w=JSON.stringify(w);else if(f.isArray(w)&&Cs(w)||(f.isFileList(w)||f.endsWith(g,"[]"))&&(R=f.toArray(w)))return g=Nn(g),R.forEach(function(T,D){!(f.isUndefined(T)||T===null)&&t.append(s===!0?Zt([g],D,a):s===null?g:g+"[]",u(T))}),!1}return Et(w)?!0:(t.append(Zt(b,g,a),u(w)),!1)}const m=[],h=Object.assign(_s,{defaultVisitor:p,convertValue:u,isVisitable:Et});function l(w,g){if(!f.isUndefined(w)){if(m.indexOf(w)!==-1)throw Error("Circular reference detected in "+g.join("."));m.push(w),f.forEach(w,function(R,E){(!(f.isUndefined(R)||R===null)&&o.call(t,R,f.isString(E)?E.trim():E,g,h))===!0&&l(R,g?g.concat(E):[E])}),m.pop()}}if(!f.isObject(e))throw new TypeError("data must be an object");return l(e),t}function en(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(r){return t[r]})}function Nt(e,t){this._pairs=[],e&&et(e,this,t)}const Mn=Nt.prototype;Mn.append=function(t,n){this._pairs.push([t,n])};Mn.toString=function(t){const n=t?function(r){return t.call(this,r,en)}:en;return this._pairs.map(function(o){return n(o[0])+"="+n(o[1])},"").join("&")};function ks(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function Pn(e,t,n){if(!t)return e;const r=n&&n.encode||ks;f.isFunction(n)&&(n={serialize:n});const o=n&&n.serialize;let a;if(o?a=o(t,n):a=f.isURLSearchParams(t)?t.toString():new Nt(t,n).toString(r),a){const s=e.indexOf("#");s!==-1&&(e=e.slice(0,s)),e+=(e.indexOf("?")===-1?"?":"&")+a}return e}class tn{constructor(){this.handlers=[]}use(t,n,r){return this.handlers.push({fulfilled:t,rejected:n,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){f.forEach(this.handlers,function(r){r!==null&&t(r)})}}const In={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},Os=typeof URLSearchParams<"u"?URLSearchParams:Nt,As=typeof FormData<"u"?FormData:null,Ls=typeof Blob<"u"?Blob:null,Ns={isBrowser:!0,classes:{URLSearchParams:Os,FormData:As,Blob:Ls},protocols:["http","https","file","blob","url","data"]},Mt=typeof window<"u"&&typeof document<"u",xt=typeof navigator=="object"&&navigator||void 0,Ms=Mt&&(!xt||["ReactNative","NativeScript","NS"].indexOf(xt.product)<0),Ps=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",Is=Mt&&window.location.href||"http://localhost",Ds=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:Mt,hasStandardBrowserEnv:Ms,hasStandardBrowserWebWorkerEnv:Ps,navigator:xt,origin:Is},Symbol.toStringTag,{value:"Module"})),U={...Ds,...Ns};function Bs(e,t){return et(e,new U.classes.URLSearchParams,Object.assign({visitor:function(n,r,o,a){return U.isNode&&f.isBuffer(n)?(this.append(r,n.toString("base64")),!1):a.defaultVisitor.apply(this,arguments)}},t))}function Us(e){return f.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function Fs(e){const t={},n=Object.keys(e);let r;const o=n.length;let a;for(r=0;r<o;r++)a=n[r],t[a]=e[a];return t}function Dn(e){function t(n,r,o,a){let s=n[a++];if(s==="__proto__")return!0;const i=Number.isFinite(+s),d=a>=n.length;return s=!s&&f.isArray(o)?o.length:s,d?(f.hasOwnProp(o,s)?o[s]=[o[s],r]:o[s]=r,!i):((!o[s]||!f.isObject(o[s]))&&(o[s]=[]),t(n,r,o[s],a)&&f.isArray(o[s])&&(o[s]=Fs(o[s])),!i)}if(f.isFormData(e)&&f.isFunction(e.entries)){const n={};return f.forEachEntry(e,(r,o)=>{t(Us(r),o,n,0)}),n}return null}function js(e,t,n){if(f.isString(e))try{return(t||JSON.parse)(e),f.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(e)}const Me={transitional:In,adapter:["xhr","http","fetch"],transformRequest:[function(t,n){const r=n.getContentType()||"",o=r.indexOf("application/json")>-1,a=f.isObject(t);if(a&&f.isHTMLForm(t)&&(t=new FormData(t)),f.isFormData(t))return o?JSON.stringify(Dn(t)):t;if(f.isArrayBuffer(t)||f.isBuffer(t)||f.isStream(t)||f.isFile(t)||f.isBlob(t)||f.isReadableStream(t))return t;if(f.isArrayBufferView(t))return t.buffer;if(f.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let i;if(a){if(r.indexOf("application/x-www-form-urlencoded")>-1)return Bs(t,this.formSerializer).toString();if((i=f.isFileList(t))||r.indexOf("multipart/form-data")>-1){const d=this.env&&this.env.FormData;return et(i?{"files[]":t}:t,d&&new d,this.formSerializer)}}return a||o?(n.setContentType("application/json",!1),js(t)):t}],transformResponse:[function(t){const n=this.transitional||Me.transitional,r=n&&n.forcedJSONParsing,o=this.responseType==="json";if(f.isResponse(t)||f.isReadableStream(t))return t;if(t&&f.isString(t)&&(r&&!this.responseType||o)){const s=!(n&&n.silentJSONParsing)&&o;try{return JSON.parse(t)}catch(i){if(s)throw i.name==="SyntaxError"?v.from(i,v.ERR_BAD_RESPONSE,this,null,this.response):i}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:U.classes.FormData,Blob:U.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};f.forEach(["delete","get","head","post","put","patch"],e=>{Me.headers[e]={}});const zs=f.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"]),Hs=e=>{const t={};let n,r,o;return e&&e.split(`
|
|
3
|
+
`).forEach(function(s){o=s.indexOf(":"),n=s.substring(0,o).trim().toLowerCase(),r=s.substring(o+1).trim(),!(!n||t[n]&&zs[n])&&(n==="set-cookie"?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)}),t},nn=Symbol("internals");function Oe(e){return e&&String(e).trim().toLowerCase()}function We(e){return e===!1||e==null?e:f.isArray(e)?e.map(We):String(e)}function qs(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}const $s=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function mt(e,t,n,r,o){if(f.isFunction(r))return r.call(this,t,n);if(o&&(t=n),!!f.isString(t)){if(f.isString(r))return t.indexOf(r)!==-1;if(f.isRegExp(r))return r.test(t)}}function Vs(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,n,r)=>n.toUpperCase()+r)}function Ws(e,t){const n=f.toCamelCase(" "+t);["get","set","has"].forEach(r=>{Object.defineProperty(e,r+n,{value:function(o,a,s){return this[r].call(this,t,o,a,s)},configurable:!0})})}let H=class{constructor(t){t&&this.set(t)}set(t,n,r){const o=this;function a(i,d,u){const p=Oe(d);if(!p)throw new Error("header name must be a non-empty string");const m=f.findKey(o,p);(!m||o[m]===void 0||u===!0||u===void 0&&o[m]!==!1)&&(o[m||d]=We(i))}const s=(i,d)=>f.forEach(i,(u,p)=>a(u,p,d));if(f.isPlainObject(t)||t instanceof this.constructor)s(t,n);else if(f.isString(t)&&(t=t.trim())&&!$s(t))s(Hs(t),n);else if(f.isHeaders(t))for(const[i,d]of t.entries())a(d,i,r);else t!=null&&a(n,t,r);return this}get(t,n){if(t=Oe(t),t){const r=f.findKey(this,t);if(r){const o=this[r];if(!n)return o;if(n===!0)return qs(o);if(f.isFunction(n))return n.call(this,o,r);if(f.isRegExp(n))return n.exec(o);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,n){if(t=Oe(t),t){const r=f.findKey(this,t);return!!(r&&this[r]!==void 0&&(!n||mt(this,this[r],r,n)))}return!1}delete(t,n){const r=this;let o=!1;function a(s){if(s=Oe(s),s){const i=f.findKey(r,s);i&&(!n||mt(r,r[i],i,n))&&(delete r[i],o=!0)}}return f.isArray(t)?t.forEach(a):a(t),o}clear(t){const n=Object.keys(this);let r=n.length,o=!1;for(;r--;){const a=n[r];(!t||mt(this,this[a],a,t,!0))&&(delete this[a],o=!0)}return o}normalize(t){const n=this,r={};return f.forEach(this,(o,a)=>{const s=f.findKey(r,a);if(s){n[s]=We(o),delete n[a];return}const i=t?Vs(a):String(a).trim();i!==a&&delete n[a],n[i]=We(o),r[i]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const n=Object.create(null);return f.forEach(this,(r,o)=>{r!=null&&r!==!1&&(n[o]=t&&f.isArray(r)?r.join(", "):r)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,n])=>t+": "+n).join(`
|
|
4
|
+
`)}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[nn]=this[nn]={accessors:{}}).accessors,o=this.prototype;function a(s){const i=Oe(s);r[i]||(Ws(o,s),r[i]=!0)}return f.isArray(t)?t.forEach(a):a(t),this}};H.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);f.reduceDescriptors(H.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(r){this[n]=r}}});f.freezeMethods(H);function gt(e,t){const n=this||Me,r=t||n,o=H.from(r.headers);let a=r.data;return f.forEach(e,function(i){a=i.call(n,a,o.normalize(),t?t.status:void 0)}),o.normalize(),a}function Bn(e){return!!(e&&e.__CANCEL__)}function Ee(e,t,n){v.call(this,e??"canceled",v.ERR_CANCELED,t,n),this.name="CanceledError"}f.inherits(Ee,v,{__CANCEL__:!0});function Un(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new v("Request failed with status code "+n.status,[v.ERR_BAD_REQUEST,v.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}function Js(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function Ks(e,t){e=e||10;const n=new Array(e),r=new Array(e);let o=0,a=0,s;return t=t!==void 0?t:1e3,function(d){const u=Date.now(),p=r[a];s||(s=u),n[o]=d,r[o]=u;let m=a,h=0;for(;m!==o;)h+=n[m++],m=m%e;if(o=(o+1)%e,o===a&&(a=(a+1)%e),u-s<t)return;const l=p&&u-p;return l?Math.round(h*1e3/l):void 0}}function Ys(e,t){let n=0,r=1e3/t,o,a;const s=(u,p=Date.now())=>{n=p,o=null,a&&(clearTimeout(a),a=null),e.apply(null,u)};return[(...u)=>{const p=Date.now(),m=p-n;m>=r?s(u,p):(o=u,a||(a=setTimeout(()=>{a=null,s(o)},r-m)))},()=>o&&s(o)]}const Ke=(e,t,n=3)=>{let r=0;const o=Ks(50,250);return Ys(a=>{const s=a.loaded,i=a.lengthComputable?a.total:void 0,d=s-r,u=o(d),p=s<=i;r=s;const m={loaded:s,total:i,progress:i?s/i:void 0,bytes:d,rate:u||void 0,estimated:u&&i&&p?(i-s)/u:void 0,event:a,lengthComputable:i!=null,[t?"download":"upload"]:!0};e(m)},n)},rn=(e,t)=>{const n=e!=null;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},on=e=>(...t)=>f.asap(()=>e(...t)),Gs=U.hasStandardBrowserEnv?((e,t)=>n=>(n=new URL(n,U.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)))(new URL(U.origin),U.navigator&&/(msie|trident)/i.test(U.navigator.userAgent)):()=>!0,Xs=U.hasStandardBrowserEnv?{write(e,t,n,r,o,a){const s=[e+"="+encodeURIComponent(t)];f.isNumber(n)&&s.push("expires="+new Date(n).toGMTString()),f.isString(r)&&s.push("path="+r),f.isString(o)&&s.push("domain="+o),a===!0&&s.push("secure"),document.cookie=s.join("; ")},read(e){const t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove(e){this.write(e,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function Qs(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function Zs(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function Fn(e,t,n){let r=!Qs(t);return e&&r||n==!1?Zs(e,t):t}const sn=e=>e instanceof H?{...e}:e;function he(e,t){t=t||{};const n={};function r(u,p,m,h){return f.isPlainObject(u)&&f.isPlainObject(p)?f.merge.call({caseless:h},u,p):f.isPlainObject(p)?f.merge({},p):f.isArray(p)?p.slice():p}function o(u,p,m,h){if(f.isUndefined(p)){if(!f.isUndefined(u))return r(void 0,u,m,h)}else return r(u,p,m,h)}function a(u,p){if(!f.isUndefined(p))return r(void 0,p)}function s(u,p){if(f.isUndefined(p)){if(!f.isUndefined(u))return r(void 0,u)}else return r(void 0,p)}function i(u,p,m){if(m in t)return r(u,p);if(m in e)return r(void 0,u)}const d={url:a,method:a,data:a,baseURL:s,transformRequest:s,transformResponse:s,paramsSerializer:s,timeout:s,timeoutMessage:s,withCredentials:s,withXSRFToken:s,adapter:s,responseType:s,xsrfCookieName:s,xsrfHeaderName:s,onUploadProgress:s,onDownloadProgress:s,decompress:s,maxContentLength:s,maxBodyLength:s,beforeRedirect:s,transport:s,httpAgent:s,httpsAgent:s,cancelToken:s,socketPath:s,responseEncoding:s,validateStatus:i,headers:(u,p,m)=>o(sn(u),sn(p),m,!0)};return f.forEach(Object.keys(Object.assign({},e,t)),function(p){const m=d[p]||o,h=m(e[p],t[p],p);f.isUndefined(h)&&m!==i||(n[p]=h)}),n}const jn=e=>{const t=he({},e);let{data:n,withXSRFToken:r,xsrfHeaderName:o,xsrfCookieName:a,headers:s,auth:i}=t;t.headers=s=H.from(s),t.url=Pn(Fn(t.baseURL,t.url),e.params,e.paramsSerializer),i&&s.set("Authorization","Basic "+btoa((i.username||"")+":"+(i.password?unescape(encodeURIComponent(i.password)):"")));let d;if(f.isFormData(n)){if(U.hasStandardBrowserEnv||U.hasStandardBrowserWebWorkerEnv)s.setContentType(void 0);else if((d=s.getContentType())!==!1){const[u,...p]=d?d.split(";").map(m=>m.trim()).filter(Boolean):[];s.setContentType([u||"multipart/form-data",...p].join("; "))}}if(U.hasStandardBrowserEnv&&(r&&f.isFunction(r)&&(r=r(t)),r||r!==!1&&Gs(t.url))){const u=o&&a&&Xs.read(a);u&&s.set(o,u)}return t},ea=typeof XMLHttpRequest<"u",ta=ea&&function(e){return new Promise(function(n,r){const o=jn(e);let a=o.data;const s=H.from(o.headers).normalize();let{responseType:i,onUploadProgress:d,onDownloadProgress:u}=o,p,m,h,l,w;function g(){l&&l(),w&&w(),o.cancelToken&&o.cancelToken.unsubscribe(p),o.signal&&o.signal.removeEventListener("abort",p)}let b=new XMLHttpRequest;b.open(o.method.toUpperCase(),o.url,!0),b.timeout=o.timeout;function R(){if(!b)return;const T=H.from("getAllResponseHeaders"in b&&b.getAllResponseHeaders()),A={data:!i||i==="text"||i==="json"?b.responseText:b.response,status:b.status,statusText:b.statusText,headers:T,config:e,request:b};Un(function(M){n(M),g()},function(M){r(M),g()},A),b=null}"onloadend"in b?b.onloadend=R:b.onreadystatechange=function(){!b||b.readyState!==4||b.status===0&&!(b.responseURL&&b.responseURL.indexOf("file:")===0)||setTimeout(R)},b.onabort=function(){b&&(r(new v("Request aborted",v.ECONNABORTED,e,b)),b=null)},b.onerror=function(){r(new v("Network Error",v.ERR_NETWORK,e,b)),b=null},b.ontimeout=function(){let D=o.timeout?"timeout of "+o.timeout+"ms exceeded":"timeout exceeded";const A=o.transitional||In;o.timeoutErrorMessage&&(D=o.timeoutErrorMessage),r(new v(D,A.clarifyTimeoutError?v.ETIMEDOUT:v.ECONNABORTED,e,b)),b=null},a===void 0&&s.setContentType(null),"setRequestHeader"in b&&f.forEach(s.toJSON(),function(D,A){b.setRequestHeader(A,D)}),f.isUndefined(o.withCredentials)||(b.withCredentials=!!o.withCredentials),i&&i!=="json"&&(b.responseType=o.responseType),u&&([h,w]=Ke(u,!0),b.addEventListener("progress",h)),d&&b.upload&&([m,l]=Ke(d),b.upload.addEventListener("progress",m),b.upload.addEventListener("loadend",l)),(o.cancelToken||o.signal)&&(p=T=>{b&&(r(!T||T.type?new Ee(null,e,b):T),b.abort(),b=null)},o.cancelToken&&o.cancelToken.subscribe(p),o.signal&&(o.signal.aborted?p():o.signal.addEventListener("abort",p)));const E=Js(o.url);if(E&&U.protocols.indexOf(E)===-1){r(new v("Unsupported protocol "+E+":",v.ERR_BAD_REQUEST,e));return}b.send(a||null)})},na=(e,t)=>{const{length:n}=e=e?e.filter(Boolean):[];if(t||n){let r=new AbortController,o;const a=function(u){if(!o){o=!0,i();const p=u instanceof Error?u:this.reason;r.abort(p instanceof v?p:new Ee(p instanceof Error?p.message:p))}};let s=t&&setTimeout(()=>{s=null,a(new v(`timeout ${t} of ms exceeded`,v.ETIMEDOUT))},t);const i=()=>{e&&(s&&clearTimeout(s),s=null,e.forEach(u=>{u.unsubscribe?u.unsubscribe(a):u.removeEventListener("abort",a)}),e=null)};e.forEach(u=>u.addEventListener("abort",a));const{signal:d}=r;return d.unsubscribe=()=>f.asap(i),d}},ra=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},oa=async function*(e,t){for await(const n of sa(e))yield*ra(n,t)},sa=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()}},an=(e,t,n,r)=>{const o=oa(e,t);let a=0,s,i=d=>{s||(s=!0,r&&r(d))};return new ReadableStream({async pull(d){try{const{done:u,value:p}=await o.next();if(u){i(),d.close();return}let m=p.byteLength;if(n){let h=a+=m;n(h)}d.enqueue(new Uint8Array(p))}catch(u){throw i(u),u}},cancel(d){return i(d),o.return()}},{highWaterMark:2})},tt=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",zn=tt&&typeof ReadableStream=="function",aa=tt&&(typeof TextEncoder=="function"?(e=>t=>e.encode(t))(new TextEncoder):async e=>new Uint8Array(await new Response(e).arrayBuffer())),Hn=(e,...t)=>{try{return!!e(...t)}catch{return!1}},ia=zn&&Hn(()=>{let e=!1;const t=new Request(U.origin,{body:new ReadableStream,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!t}),ln=64*1024,Rt=zn&&Hn(()=>f.isReadableStream(new Response("").body)),Ye={stream:Rt&&(e=>e.body)};tt&&(e=>{["text","arrayBuffer","blob","formData","stream"].forEach(t=>{!Ye[t]&&(Ye[t]=f.isFunction(e[t])?n=>n[t]():(n,r)=>{throw new v(`Response type '${t}' is not supported`,v.ERR_NOT_SUPPORT,r)})})})(new Response);const la=async e=>{if(e==null)return 0;if(f.isBlob(e))return e.size;if(f.isSpecCompliantForm(e))return(await new Request(U.origin,{method:"POST",body:e}).arrayBuffer()).byteLength;if(f.isArrayBufferView(e)||f.isArrayBuffer(e))return e.byteLength;if(f.isURLSearchParams(e)&&(e=e+""),f.isString(e))return(await aa(e)).byteLength},ca=async(e,t)=>{const n=f.toFiniteNumber(e.getContentLength());return n??la(t)},ua=tt&&(async e=>{let{url:t,method:n,data:r,signal:o,cancelToken:a,timeout:s,onDownloadProgress:i,onUploadProgress:d,responseType:u,headers:p,withCredentials:m="same-origin",fetchOptions:h}=jn(e);u=u?(u+"").toLowerCase():"text";let l=na([o,a&&a.toAbortSignal()],s),w;const g=l&&l.unsubscribe&&(()=>{l.unsubscribe()});let b;try{if(d&&ia&&n!=="get"&&n!=="head"&&(b=await ca(p,r))!==0){let A=new Request(t,{method:"POST",body:r,duplex:"half"}),S;if(f.isFormData(r)&&(S=A.headers.get("content-type"))&&p.setContentType(S),A.body){const[M,F]=rn(b,Ke(on(d)));r=an(A.body,ln,M,F)}}f.isString(m)||(m=m?"include":"omit");const R="credentials"in Request.prototype;w=new Request(t,{...h,signal:l,method:n.toUpperCase(),headers:p.normalize().toJSON(),body:r,duplex:"half",credentials:R?m:void 0});let E=await fetch(w);const T=Rt&&(u==="stream"||u==="response");if(Rt&&(i||T&&g)){const A={};["status","statusText","headers"].forEach(ne=>{A[ne]=E[ne]});const S=f.toFiniteNumber(E.headers.get("content-length")),[M,F]=i&&rn(S,Ke(on(i),!0))||[];E=new Response(an(E.body,ln,M,()=>{F&&F(),g&&g()}),A)}u=u||"text";let D=await Ye[f.findKey(Ye,u)||"text"](E,e);return!T&&g&&g(),await new Promise((A,S)=>{Un(A,S,{data:D,headers:H.from(E.headers),status:E.status,statusText:E.statusText,config:e,request:w})})}catch(R){throw g&&g(),R&&R.name==="TypeError"&&/fetch/i.test(R.message)?Object.assign(new v("Network Error",v.ERR_NETWORK,e,w),{cause:R.cause||R}):v.from(R,R&&R.code,e,w)}}),Tt={http:Ts,xhr:ta,fetch:ua};f.forEach(Tt,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const cn=e=>`- ${e}`,da=e=>f.isFunction(e)||e===null||e===!1,qn={getAdapter:e=>{e=f.isArray(e)?e:[e];const{length:t}=e;let n,r;const o={};for(let a=0;a<t;a++){n=e[a];let s;if(r=n,!da(n)&&(r=Tt[(s=String(n)).toLowerCase()],r===void 0))throw new v(`Unknown adapter '${s}'`);if(r)break;o[s||"#"+a]=r}if(!r){const a=Object.entries(o).map(([i,d])=>`adapter ${i} `+(d===!1?"is not supported by the environment":"is not available in the build"));let s=t?a.length>1?`since :
|
|
5
|
+
`+a.map(cn).join(`
|
|
6
|
+
`):" "+cn(a[0]):"as no adapter specified";throw new v("There is no suitable adapter to dispatch the request "+s,"ERR_NOT_SUPPORT")}return r},adapters:Tt};function wt(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Ee(null,e)}function un(e){return wt(e),e.headers=H.from(e.headers),e.data=gt.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),qn.getAdapter(e.adapter||Me.adapter)(e).then(function(r){return wt(e),r.data=gt.call(e,e.transformResponse,r),r.headers=H.from(r.headers),r},function(r){return Bn(r)||(wt(e),r&&r.response&&(r.response.data=gt.call(e,e.transformResponse,r.response),r.response.headers=H.from(r.response.headers))),Promise.reject(r)})}const $n="1.8.2",nt={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{nt[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});const dn={};nt.transitional=function(t,n,r){function o(a,s){return"[Axios v"+$n+"] Transitional option '"+a+"'"+s+(r?". "+r:"")}return(a,s,i)=>{if(t===!1)throw new v(o(s," has been removed"+(n?" in "+n:"")),v.ERR_DEPRECATED);return n&&!dn[s]&&(dn[s]=!0,console.warn(o(s," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(a,s,i):!0}};nt.spelling=function(t){return(n,r)=>(console.warn(`${r} is likely a misspelling of ${t}`),!0)};function fa(e,t,n){if(typeof e!="object")throw new v("options must be an object",v.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let o=r.length;for(;o-- >0;){const a=r[o],s=t[a];if(s){const i=e[a],d=i===void 0||s(i,a,e);if(d!==!0)throw new v("option "+a+" must be "+d,v.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new v("Unknown option "+a,v.ERR_BAD_OPTION)}}const Je={assertOptions:fa,validators:nt},re=Je.validators;let pe=class{constructor(t){this.defaults=t,this.interceptors={request:new tn,response:new tn}}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+=`
|
|
7
|
+
`+a):r.stack=a}catch{}}throw r}}_request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=he(this.defaults,n);const{transitional:r,paramsSerializer:o,headers:a}=n;r!==void 0&&Je.assertOptions(r,{silentJSONParsing:re.transitional(re.boolean),forcedJSONParsing:re.transitional(re.boolean),clarifyTimeoutError:re.transitional(re.boolean)},!1),o!=null&&(f.isFunction(o)?n.paramsSerializer={serialize:o}:Je.assertOptions(o,{encode:re.function,serialize:re.function},!0)),n.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?n.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:n.allowAbsoluteUrls=!0),Je.assertOptions(n,{baseUrl:re.spelling("baseURL"),withXsrfToken:re.spelling("withXSRFToken")},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let s=a&&f.merge(a.common,a[n.method]);a&&f.forEach(["delete","get","head","post","put","patch","common"],w=>{delete a[w]}),n.headers=H.concat(s,a);const i=[];let d=!0;this.interceptors.request.forEach(function(g){typeof g.runWhen=="function"&&g.runWhen(n)===!1||(d=d&&g.synchronous,i.unshift(g.fulfilled,g.rejected))});const u=[];this.interceptors.response.forEach(function(g){u.push(g.fulfilled,g.rejected)});let p,m=0,h;if(!d){const w=[un.bind(this),void 0];for(w.unshift.apply(w,i),w.push.apply(w,u),h=w.length,p=Promise.resolve(n);m<h;)p=p.then(w[m++],w[m++]);return p}h=i.length;let l=n;for(m=0;m<h;){const w=i[m++],g=i[m++];try{l=w(l)}catch(b){g.call(this,b);break}}try{p=un.call(this,l)}catch(w){return Promise.reject(w)}for(m=0,h=u.length;m<h;)p=p.then(u[m++],u[m++]);return p}getUri(t){t=he(this.defaults,t);const n=Fn(t.baseURL,t.url,t.allowAbsoluteUrls);return Pn(n,t.params,t.paramsSerializer)}};f.forEach(["delete","get","head","options"],function(t){pe.prototype[t]=function(n,r){return this.request(he(r||{},{method:t,url:n,data:(r||{}).data}))}});f.forEach(["post","put","patch"],function(t){function n(r){return function(a,s,i){return this.request(he(i||{},{method:t,headers:r?{"Content-Type":"multipart/form-data"}:{},url:a,data:s}))}}pe.prototype[t]=n(),pe.prototype[t+"Form"]=n(!0)});let pa=class Vn{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(a){n=a});const r=this;this.promise.then(o=>{if(!r._listeners)return;let a=r._listeners.length;for(;a-- >0;)r._listeners[a](o);r._listeners=null}),this.promise.then=o=>{let a;const s=new Promise(i=>{r.subscribe(i),a=i}).then(o);return s.cancel=function(){r.unsubscribe(a)},s},t(function(a,s,i){r.reason||(r.reason=new Ee(a,s,i),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const n=this._listeners.indexOf(t);n!==-1&&this._listeners.splice(n,1)}toAbortSignal(){const t=new AbortController,n=r=>{t.abort(r)};return this.subscribe(n),t.signal.unsubscribe=()=>this.unsubscribe(n),t.signal}static source(){let t;return{token:new Vn(function(o){t=o}),cancel:t}}};function ha(e){return function(n){return e.apply(null,n)}}function ma(e){return f.isObject(e)&&e.isAxiosError===!0}const Ct={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(Ct).forEach(([e,t])=>{Ct[t]=e});function Wn(e){const t=new pe(e),n=xn(pe.prototype.request,t);return f.extend(n,pe.prototype,t,{allOwnKeys:!0}),f.extend(n,t,null,{allOwnKeys:!0}),n.create=function(o){return Wn(he(e,o))},n}const _=Wn(Me);_.Axios=pe;_.CanceledError=Ee;_.CancelToken=pa;_.isCancel=Bn;_.VERSION=$n;_.toFormData=et;_.AxiosError=v;_.Cancel=_.CanceledError;_.all=function(t){return Promise.all(t)};_.spread=ha;_.isAxiosError=ma;_.mergeConfig=he;_.AxiosHeaders=H;_.formToJSON=e=>Dn(f.isHTMLForm(e)?new FormData(e):e);_.getAdapter=qn.getAdapter;_.HttpStatusCode=Ct;_.default=_;const{Axios:La,AxiosError:Na,CanceledError:Ma,isCancel:Pa,CancelToken:Ia,VERSION:Da,all:Ba,Cancel:Ua,isAxiosError:Fa,spread:ja,toFormData:za,AxiosHeaders:Ha,HttpStatusCode:qa,formToJSON:$a,getAdapter:Va,mergeConfig:Wa}=_,_t="useAxios",ga=async(e=n=>{},t)=>(t.baseURL=mr(),B.debug(_t,`baseURL::${t.baseURL}`),e(t),t),wa=async(e=n=>{},t)=>{var r;if(e(t),t.response.status!==500){if(t.response.status<=401)return B.info(_t,t.response.data.meta),Promise.reject(t.response.data.meta);if(t.response.status===404)return B.info(_t,t.response.data.meta),Promise.reject(t.response.data.meta)}let n;try{let o="";t.request.config&&t.request.config.token_type?o=t.request.config.token_type:t.response.config&&t.response.config.token_type&&(o=t.response.config.token_type),n=_(t.response.config)}catch(o){(r=o==null?void 0:o.data)!=null&&r.meta?n=Promise.reject(o.data.meta):o.data?n=Promise.reject(o.data):n=Promise.reject(o)}return n},qe="useAxios",ba=({onRequest:e,onError:t})=>{_.interceptors.request.use(n=>ga(e,n)),_.interceptors.response.use(n=>n.data.data,n=>wa(t,n)),_.defaults.headers.common["content-type"]="application/json"},ya={get:async(e,t)=>(B.debug(qe,`[get] url | ${e}`),_.get(e,t)),post:async(e,t,n)=>(B.debug(qe,`[post] url | ${e} | payload | ${t}`),_.post(e,t,n)),put:async(e,t,n)=>(B.debug(qe,`[put] url | ${e} | payload | ${t}`),_.put(e,t,n)),delete:async(e,t)=>(B.debug(qe,`[delete] url | ${e}`),_.delete(e,t))};var V=(e=>(e.MINI_MOBILE="mob-sm",e.MOBILE_PORTRAIT="mob",e.MOBILE_LANDSCAPE="mob-l",e.MOBILE_LANDSCAPE_XL="mob-xl",e.TAB_PORTRAIT="tab",e.TAB_LANDSCAPE="tab-l",e.LAPTOP="lap",e.DESKTOP="desk",e))(V||{});const fn={iphone_15:{width:{min:850,max:854},height:{min:390,max:395}},iphone_14_pro_max:{width:{min:925,max:935},height:{min:427,max:435}},iphone_12_pro:{width:{min:840,max:845},height:{min:388,max:392}},iphone_13_mini:{width:{min:810,max:815},height:{min:370,max:377}},iphone_se_22:{width:{min:664,max:668},height:{min:370,max:377}},iphone_xr:{width:{min:894,max:898},height:{min:410,max:417}},gpixel_6_pro:{width:{min:890,max:895},height:{min:408,max:415}},gpixel_4xl:{width:{min:865,max:972},height:{min:408,max:415}},gpixel_3xl:{width:{min:784,max:788},height:{min:390,max:395}},sam_galaxy_s22:{width:{min:778,max:783},height:{min:357,max:365}},sam_galaxy_s22_plus:{width:{min:830,max:835},height:{min:380,max:387}},sam_galaxy_s22_ultra:{width:{min:820,max:825},height:{min:380,max:387}},sam_galaxy_s21:{width:{min:798,max:805},height:{min:358,max:365}},sam_galaxy_s21_plus:{width:{min:850,max:857},height:{min:380,max:387}},sam_galaxy_s20_ultra:{width:{min:910,max:918},height:{min:408,max:415}},nokia_n9:{width:{min:853,max:855},height:{min:478,max:482}}},Jn=()=>({width:window.innerWidth,height:window.innerHeight}),va=({width:e,height:t})=>{const{width:n,height:r}=Jn();return e.min<=n&&e.max>=n&&t.min<=r&&t.max>=r},Kn=()=>{for(const r of Object.keys(fn)){const o=fn[r];if(va(o))return o.vdevice||V.MOBILE_LANDSCAPE_XL}const{width:e,height:t}=Jn(),n=t>=e;return e<=320?V.MINI_MOBILE:e<=480&&e>=320?V.MOBILE_PORTRAIT:e<=767&&e>=481?V.MOBILE_LANDSCAPE:e<=1024&&e>=768?n?V.TAB_PORTRAIT:V.TAB_LANDSCAPE:e<=1280&&e>=1025?V.LAPTOP:(e>=1281,V.DESKTOP)},Sa=["h1","h3","blockquote","br"],Ea={strong:"*",b:"*",i:"_",u:"__",s:"~",strike:"~",highlight:"`",blockquote:">",h1:"# ",h3:"### ",br:`
|
|
8
|
+
`},I={bold:/(^|\s|[{\[])\*{1,2}(.*?\S *)?\*{1,2}(?=$|\s|[\.,\?:;\-}\]](?:$|\s))/g,italic:/(^|\s|[{\[])\_(.*?\S *)?\_(?=$|\s|[\.,\?:;\-}\]](?:$|\s))/g,underline:/(^|\s|[{\[])\_{2}(.*?\S *)?\_{2}(?=$|\s|[\.,\?:;\-}\]](?:$|\s))/g,strike:/(^|\s|[{\[])\~(.*?\S *)?\~(?=$|\s|[\.,\?:;\-}\]](?:$|\s))/g,heading:/(?:^|\n)(\#{1,6}) (.*?\S *)(?:\n|$)/gm,blockquote:/(?:^|\n)(?:>|>\s|>\s) (.+?)(?:\n|$)/gm,monospace:/(^|\s)\`(.*?\S *)?\`(?=$|\s)/g,codeblock:/(^|\s)`{3}((?:(?:.*?$)\n)?(?:[\s\S]*?))`{3}(?=$|\s)/g,nextline:/(.*)(\n)(.*)/gm,line:/(^|[\n])(\*{3,}|\-{3,})(?=$|[\n])(.*)/g,link:/(^|\s)\[(.+?)\]\(((?:(?:https?:\/\/(?:www\.)?|www\.)|(?:mailto:)).*?)\)(?:{:(.*)})?/gi,image:/!\[(.*)\]\((.*?)\s*(?:(?:'|"|")(.*)(?:'|"|"))?\s*\)(?:{:(.*)})?/gi,video:/(?:\[\!\[(.*)\]\((.*?)\s*(?:(?:'|"|")(.*)(?:'|"|"))?\s*\)(?:{:(.*)})?]\((.*?)\s*(?:(?:'|"|")(.*)(?:'|"|"))?\s*\))(?:{:(.*)})?/gi,bullet:/(^\s|\n|^)([\*|\-|●|○] )(.*?\S *)*(?:(?:.*?$)\n)?((\s)*([\*|\-|●|○] )(.*?\S *)*(?:(?:.*?$)\n)?)*/gm,numlist:/(^\s|\n|^)(\d)+(\.) (.*?\S *)*(?:(?:.*?$)\n)?((\s)*(\d)+(\.)(.*?\S *)*(?:(?:.*?$)\n)?)*/gm,anchor_tag:/<a(>| .*?>)(.*?)<\/a>/g,href:/href=(?:'|")(.*?)(?:'|") ?/g,gdrive_url:/(?:https:\/\/drive\.google\.com\/file\/d\/(.*?)\/view)/,vtype:/(?:vtype=(?:'|"|")(image|audio|video)(?:'|"|"))/},bt=e=>e.replace(/\*/g,"*").replace(/\_/g,"_").replace(/\~/g,"~"),xa=e=>e.replace(/*/g,"*").replace(/_/g,"_").replace(/~/g,"~"),pn=e=>(e&&typeof e=="string"&&(e=e.replace(/'|'/g,"'").replace(/"/g,'"').replace(/>/g,">").replace(/</g,"<").replace(/&/g,"&").replace(///g,"/").replace(/ /g," ").replace(/%2C/g,",")),e),ve=(e,t)=>{let n="",r="";return(e[0]===`
|
|
11
9
|
`||e[0]===" ")&&(n=e[0]),(e[e.length-1]===`
|
|
12
|
-
`||e[e.length-1]===" ")&&(r=e[e.length-1]),n+t+r},
|
|
10
|
+
`||e[e.length-1]===" ")&&(r=e[e.length-1]),n+t+r},hn=e=>new RegExp(`<${e}.*?/?>`,"gm"),mn=e=>{let t=e.match(I.gdrive_url);if(t&&t.length>1&&t[1])return`http://docs.google.com/uc?export=open&id=${t[1]}`;if(e.startsWith("@")){let n=e.split("@")[1].split(":");if(n[0]==="gdrive")return`http://docs.google.com/uc?export=open&id=${n[1]}`}return e},gn=(e="",t="",n="",r="")=>{let o="image";if(r.length){let a=r.match(I.vtype);a&&a.length>1&&a[1]&&(o=a[1])}return o=="audio"?`<audio vmd="audio" controls ${r}>
|
|
13
11
|
<source src="${n}" type="audio/mp3"/>
|
|
14
12
|
</audio>`:o=="video"?`<video vmd="video" controls ${r}>
|
|
15
13
|
<source src="${n}" type="video/mp4"/>
|
|
16
|
-
</video>`:`<img vmd="image" src="${n}" alt="${e}" title="${t}" ${r}>`},
|
|
17
|
-
`),e=
|
|
14
|
+
</video>`:`<img vmd="image" src="${n}" alt="${e}" title="${t}" ${r}>`},Ra={applyReverseMarkdown:e=>(e=e.replace(hn("br"),`
|
|
15
|
+
`),e=pn(e),e=Markdown.reverseAnchor(e),e=e.replace(hn("hr")," --- "),e=Markdown.reverseRecursive(e),e.trim()),reverseRecursive:e=>{let n=new DOMParser().parseFromString(e,"text/html").body.childNodes,r=e===`
|
|
18
16
|
`?`
|
|
19
|
-
`:"";return Array.from(n).forEach(o=>{let
|
|
20
|
-
`))||s
|
|
17
|
+
`:"";return Array.from(n).forEach(o=>{let a=o.nodeType===Node.TEXT_NODE,s=!a&&o.tagName.toLowerCase();const i=o.innerText;if(i&&(i.trim()||i.includes(`
|
|
18
|
+
`))||a||s==="br"){if(a)return r+=o.data;let d=Ea[s]||"",u=o.childNodes.length?Markdown.reverseRecursive(o.innerHTML):i;r+=!u.trim()&&u.includes(`
|
|
21
19
|
`)?`
|
|
22
|
-
`:"";let
|
|
23
|
-
`,m=
|
|
24
|
-
`:
|
|
25
|
-
`).trim(),e=Markdown.applyRecursive(e,t),e=Markdown.applyOnce(e),e=Markdown.applyNextLine(e),e=
|
|
26
|
-
`),
|
|
27
|
-
`),
|
|
20
|
+
`:"";let p=u[u.length-1]===`
|
|
21
|
+
`,m=Sa.includes(s)?"":d;r+=d+(p?u.slice(0,u.length-1)+m+`
|
|
22
|
+
`:u+m)}}),r},reverseAnchor:e=>{let{anchor_tag:t,href:n}=I;return e.replace(t,(r,o,a)=>{const s=a;let i;return o.replace(n,(d,u)=>{i=u}),i.includes("mailto:")?i.replace("mailto:",""):`${e[e.indexOf(r)-1]!==" "?" ":""}[${s}](${encodeURI(i)})`})},applyMarkdown:(e,t=!1)=>typeof e!="string"?e:(e=pn(e),e=e.replace(/</g,"<").replace(/>/g,">").replace(/<br>/g,`
|
|
23
|
+
`).trim(),e=Markdown.applyRecursive(e,t),e=Markdown.applyOnce(e),e=Markdown.applyNextLine(e),e=xa(e),'<div class="vmd">'+e+"</div>"),applyRecursive:(e,t=!1)=>(e=e.replace(I.bold,Markdown.getBoldHTML),e=e.replace(I.italic,Markdown.getItalicHTML),e=e.replace(I.underline,Markdown.getUnderLineHTML),e=e.replace(I.strike,Markdown.getStrikeHTML),e=e.replace(I.line,Markdown.getLineHTML),e=e.replace(I.bullet,Markdown.getBulletHTML),e=e.replace(I.numlist,Markdown.getNumlistHTML),t||(e=e.replace(I.video,Markdown.getVideoHTML),e=e.replace(I.image,Markdown.getImageHTML)),e=e.replace(I.link,Markdown.getLinkHTML),e),applyOnce:e=>(e=e.replace(I.blockquote,Markdown.getBlockQuoteHTML),e=e.replace(I.heading,Markdown.getHeadingHTML),e=e.replace(I.codeblock,Markdown.getCodeblockHTML),e=e.replace(I.monospace,Markdown.getMonoSpaceHTML),e),applyNextLine:e=>e.replace(I.nextline,Markdown.getNextLineHTML),getBoldHTML:(e,t,n)=>!n||!n.match(/[^_*`~]/)||n[0]==="*"||n[n.length-1]==="*"||n[0]===" "&&n[n.length-1]===" "||!n?e:t+' <strong vmd="bold">'+Markdown.applyRecursive(n)+"</strong> ",getItalicHTML:(e,t,n)=>!n||!n.match(/[^_*`~]/)||n[0]==="_"||n[n.length-1]==="_"||n[0]===" "&&n[n.length-1]===" "||!n?e:t+' <i vmd="italic">'+Markdown.applyRecursive(n)+"</i> ",getUnderLineHTML:(e,t,n)=>!n||!n.match(/[^_*`~]/)||n[0]==="__"||n[n.length-1]==="__"||n[0]===" "&&n[n.length-1]===" "||!n?e:t+' <u vmd="underline">'+Markdown.applyRecursive(n)+"</u>",getStrikeHTML:(e,t,n)=>!n||!n.match(/[^_*`~]/)||n[0]==="~"||n[n.length-1]==="~"||n[0]===" "&&n[n.length-1]===" "||!n?e:t+' <strike vmd="strike">'+Markdown.applyRecursive(n)+"</strike> ",getHeadingHTML:(e,t,n)=>{let r=t.length;return ve(e," <h"+r+` vmd="h${r}">`+bt(n)+"</h"+r+"> ")},getBlockQuoteHTML:(e,t)=>(t=t.trim(),t.length?ve(e,' <blockquote vmd="blockquote"><p>'+Markdown.applyRecursive(t)+"</p></blockquote> "):e),getMonoSpaceHTML:(e,t,n)=>!n||!n.match(/[^_*`~]/)||n[0]==="`"||n[n.length-1]==="`"||n[0]===" "&&n[n.length-1]===" "?e:t+' <code vmd="monospace" class="code">“'+bt(n)+"”</code> ",getCodeblockHTML:(e,t,n)=>n.trim().length===0?e:t+' <pre vmd="codeblock"> '+Markdown.applyRecursive(n)+"</pre>",getNextLineHTML:(e,t,n,r)=>t+' <br vmd="br" > '+r,getLineHTML:(e,t,n,r)=>t+'<hr vmd="line" class="hr w100">'+Markdown.applyRecursive(r.trim()),getLinkHTML:(e,t,n,r,o)=>{var a=r.startsWith("www.")?"http://"+r:r;return t+` <a vmd="link" href="${encodeURI(a)}" rel="noopener noreferrer" ${o}>${bt(n)}</a>`},getImageHTML:(e,t,n,r,o)=>{let a=gn(t,r,mn(n),o);return ve(e,a)},getVideoHTML:(e,t,n,r,o,a,s,i)=>{let d=gn(t,r,mn(n),o);return ve(e,`<a vmd="hyperlink" href="${a}" title="${s}" rel="noreferrer" ${i}>${d}</a>`)},getBulletHTML:e=>{if(isNaN(e)){if(e.replace(/\s/g,"").replace(/\*/g,"").length==0)return e}else return e;return ve(e,' <ul vmd="list-bullet" style="list-style-type: disc; list-style: inherit;">'+(n=>{let r="";for(var o=n.split(`
|
|
24
|
+
`),a=0;a<o.length;a++)o[a]=o[a].replace(/[\-|●|○]/,"-"),o[a].includes("-")&&(r+=o[a].replace(/\-/,' <li style="list-style: inherit"> ')+"</li> ");return r})(e)+"</ul> ")},getNumlistHTML:e=>isNaN(e)?ve(e,' <ol vmd="list-number">'+(n=>{let r="";for(var o=n.split(`
|
|
25
|
+
`),a=0;a<o.length;a++)o[a]=o[a].replace(/(\d)*(\.)/,"-"),o[a].includes("-")&&(r+=o[a].replace(/\-/,'<li style="list-style: decimal"> ')+"</li>");return r})(e)+"</ol> "):e};function Ta(){return{toTop:()=>{window.scrollTo({top:0,behavior:"smooth"})},toNextPage:()=>{window.scrollTo({top:window.innerHeight,behavior:"smooth"})},byId:(o="",a=!0)=>{const s=document.getElementById(o);let i="start";if(a){const d=Kn();i=d===V.MINI_MOBILE||d===V.MOBILE_PORTRAIT?"start":"center"}s==null||s.scrollIntoView({behavior:"smooth",block:i})},byIdOffSet:(o="")=>{const a=document.getElementById(o),s=75,i=document.body.getBoundingClientRect().top,p=a.getBoundingClientRect().top-i-s;window.scroll({top:p,behavior:"smooth"})}}}function Ca({meta:e=!1,ctrl:t=!1,shift:n=!1,key:r,handler:o}){q("keydown",a=>{if(a.metaKey===e){if(a.ctrlKey!==t)return;if(a.shiftKey!==n)return;a.key===r&&(a.stopImmediatePropagation(),a.preventDefault(),a.stopPropagation(),o())}})}const _a="useStore";let Yn="v0xapp",Gn="1.0.5-alpha";function $e(e){return`vezham-ls-${Yn}-${Gn}-${e}`}const ka=e=>{e.pretext&&(Yn=e.pretext),e.version&&(Gn=e.version)},Xn={get:(e,t)=>{try{const n=window.localStorage.getItem($e(e));return n&&n!=="undefined"?n:t||""}catch(n){return B.error(_a,`key | ${$e(e)} | err: `,n),t||""}},has:e=>!!Xn.get(e),set:(e,t)=>window.localStorage.setItem($e(e),t),delete:e=>window.localStorage.removeItem($e(e)),purge:()=>window.localStorage.clear()};exports.GetDevice=Kn;exports.Vdevice=V;exports.defineAxios=ba;exports.defineStore=ka;exports.useAxios=ya;exports.useBoolean=bn;exports.useClickAnyWhere=co;exports.useCopyToClipboard=uo;exports.useCountdown=fo;exports.useCounter=yn;exports.useDarkMode=go;exports.useDebounceCallback=Ge;exports.useDebounceValue=wo;exports.useDocumentTitle=bo;exports.useEffect=yo;exports.useEventCallback=Ae;exports.useEventListener=q;exports.useHover=vo;exports.useIntersectionObserver=So;exports.useInterval=vn;exports.useIsClient=Eo;exports.useIsFirstRender=Sn;exports.useIsMounted=En;exports.useIsomorphicLayoutEffect=G;exports.useLocalStorage=kt;exports.useLogger=B;exports.useMap=xo;exports.useMarkdown=Ra;exports.useMediaQuery=Ot;exports.useOnClickOutside=Ro;exports.useReadLocalStorage=To;exports.useResizeObserver=Co;exports.useScreen=_o;exports.useScript=Oo;exports.useScrollLock=Lo;exports.useScrollTo=Ta;exports.useSessionStorage=No;exports.useShortcut=Ca;exports.useStep=Mo;exports.useStore=Xn;exports.useTernaryDarkMode=Do;exports.useTimeout=Bo;exports.useToast=wn;exports.useToggle=Uo;exports.useUnmount=At;exports.useWindowSize=jo;
|