@liip/liipgpt 3.0.6 → 3.1.1
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/button/liipgpt-button.iife.js +93 -5
- package/chat/liipgpt-chat.iife.js +162 -124
- package/config/index.cjs +31 -1
- package/config/index.d.ts +243 -8
- package/config/index.js +31 -1
- package/configurator/_app/env.js +1 -1
- package/configurator/_app/immutable/chunks/B0YFyw9m.js +1 -0
- package/configurator/_app/immutable/chunks/Bp3niLsp.js +3 -0
- package/configurator/_app/immutable/chunks/CDW8Ir6T.js +1 -0
- package/configurator/_app/immutable/chunks/CMMtw-vR.js +15 -0
- package/configurator/_app/immutable/chunks/Cx_YT9bD.js +1 -0
- package/configurator/_app/immutable/chunks/D54U55sL.js +1 -0
- package/configurator/_app/immutable/chunks/{BzNmKNYl.js → DGq0_RSw.js} +2 -2
- package/configurator/_app/immutable/chunks/{Du-AngZl.js → DUP4EfpK.js} +1 -1
- package/configurator/_app/immutable/chunks/{CdOhT63o.js → DZ0HWR8Z.js} +1 -1
- package/configurator/_app/immutable/chunks/DePuinxN.js +1 -0
- package/configurator/_app/immutable/chunks/Dm-paoVs.js +1 -0
- package/configurator/_app/immutable/chunks/WrgP-GnX.js +108 -0
- package/configurator/_app/immutable/chunks/qZ4Lj-J3.js +1 -0
- package/configurator/_app/immutable/chunks/qjMtaNLq.js +143 -0
- package/configurator/_app/immutable/entry/app.Fk5x0s8c.js +2 -0
- package/configurator/_app/immutable/entry/start.Dr0bP8NY.js +1 -0
- package/configurator/_app/immutable/nodes/{0.DQ5pdmr8.js → 0.CuD2CzcR.js} +3 -2
- package/configurator/_app/immutable/nodes/1.Cyll3zcL.js +1 -0
- package/configurator/_app/immutable/nodes/2.DSwioKer.js +30 -0
- package/configurator/_app/immutable/nodes/3.xBzsReXf.js +897 -0
- package/configurator/_app/version.json +1 -1
- package/configurator/index.html +10 -10
- package/configurator/sidebar.html +10 -10
- package/index.cjs +109 -7
- package/index.d.ts +554 -18
- package/index.js +109 -7
- package/package.json +1 -1
- package/configurator/_app/immutable/chunks/6iiGzJiA.js +0 -1
- package/configurator/_app/immutable/chunks/7RznL39c.js +0 -1
- package/configurator/_app/immutable/chunks/BcxyVcfq.js +0 -1
- package/configurator/_app/immutable/chunks/BkMkT2yX.js +0 -1
- package/configurator/_app/immutable/chunks/CIVexZRw.js +0 -1
- package/configurator/_app/immutable/chunks/CO1VjDW9.js +0 -212
- package/configurator/_app/immutable/chunks/CknFvNnh.js +0 -3
- package/configurator/_app/immutable/chunks/DDyGsrRo.js +0 -1
- package/configurator/_app/immutable/chunks/DeC3Wj5S.js +0 -15
- package/configurator/_app/immutable/chunks/w-7tIaYZ.js +0 -1
- package/configurator/_app/immutable/entry/app.COsCZK0Q.js +0 -2
- package/configurator/_app/immutable/entry/start.t_88bEga.js +0 -1
- package/configurator/_app/immutable/nodes/1.iGq4bplI.js +0 -1
- package/configurator/_app/immutable/nodes/2.D1z7Il5A.js +0 -30
- package/configurator/_app/immutable/nodes/3.DO39A0EF.js +0 -897
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import"./NZTpNUN0.js";import{p as G,N as b,a as d,O as M,b as n,d as N,v as k,G as x,P as O,F as q,Q,R as U,c as j,S as A,f as R,s as E,t as D,g as H,T as S,e as w,r as z}from"./Cx_YT9bD.js";import{i as F}from"./B0YFyw9m.js";import{a as I}from"./WrgP-GnX.js";import{p as P}from"./DePuinxN.js";var J=(u,a)=>a()(),K=R('<div class="chat-app__container"><div class="error-message svelte-4thrqu">Server is unreachable, please try later... <button class="error-message__retry-button svelte-4thrqu">Retry</button></div></div>'),L=R(" <!>",1);const V={hash:"svelte-4thrqu",code:`
|
|
2
|
+
/* These styles are inline, because at this point theme loading has failed. */.error-message.svelte-4thrqu {display:table;z-index:1000;width:auto;margin:2rem auto;padding:2rem;border-radius:2px;background:white;color:oklch(27.8% 0.033 256.848);font-family:-apple-system,
|
|
3
|
+
BlinkMacSystemFont,
|
|
4
|
+
avenir next,
|
|
5
|
+
avenir,
|
|
6
|
+
segoe ui,
|
|
7
|
+
helvetica neue,
|
|
8
|
+
helvetica,
|
|
9
|
+
Cantarell,
|
|
10
|
+
Ubuntu,
|
|
11
|
+
roboto,
|
|
12
|
+
noto,
|
|
13
|
+
arial,
|
|
14
|
+
sans-serif;}.error-message__retry-button.svelte-4thrqu {border:none;outline:none;background:none;font-size:1rem;text-decoration:underline;&:active {outline:none;}}`};function W(u,a){G(a,!0),I(u,V);const h=(e,o=q,f=q)=>{A();var i=L(),l=d(i),r=E(l);{var c=t=>{},_=t=>{var p=K(),y=w(p),C=E(w(y));C.__click=[J,f],z(y),z(p),n(t,p)};F(r,t=>{m()?t(c):t(_,!1)})}D(t=>H(l,`${t??""} `),[()=>console.error(`Panic, uncaught error:
|
|
15
|
+
`,o())??""]),n(e,i)};let v=P(a,"body",7),m=P(a,"silent",7),s=O(void 0);const T=e=>{S(s,{error:e},!0)};var g=b(),B=d(g);return M(B,{get failed(){return h}},e=>{var o=b(),f=d(o);{var i=r=>{h(r,()=>x(s).error,()=>()=>{S(s,void 0)})},l=r=>{var c=b(),_=d(c);Q(_,v,()=>T),n(r,c)};F(f,r=>{x(s)?r(i):r(l,!1)})}n(e,o)}),n(u,g),N({get body(){return v()},set body(e){v(e),k()},get silent(){return m()},set silent(e){m(e),k()}})}U(["click"]);j(W,{body:{},silent:{}},[],[],!0);export{W as E};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var Ee=Array.isArray,fn=Array.prototype.indexOf,cn=Array.from,It=Object.keys,ct=Object.defineProperty,ot=Object.getOwnPropertyDescriptor,_n=Object.getOwnPropertyDescriptors,hn=Object.prototype,dn=Array.prototype,Te=Object.getPrototypeOf,de=Object.isExtensible;function kr(t){return typeof t=="function"}const vn=()=>{};function Cr(t){return typeof t?.then=="function"}function Nr(t){return t()}function Ae(t){for(var e=0;e<t.length;e++)t[e]()}function pn(){var t,e,n=new Promise((r,i)=>{t=r,e=i});return{promise:n,resolve:t,reject:e}}function Or(t,e){if(Array.isArray(t))return t;if(!(Symbol.iterator in t))return Array.from(t);const n=[];for(const r of t)if(n.push(r),n.length===e)break;return n}const S=2,ne=4,jt=8,Et=16,H=32,rt=64,re=128,x=256,Pt=512,$=1024,O=2048,st=4096,X=8192,vt=16384,se=32768,Ft=65536,ve=1<<17,xe=1<<18,qt=1<<19,ie=1<<20,Kt=1<<21,ae=1<<22,Q=1<<23,tt=Symbol("$state"),gn=Symbol("legacy props"),Rr=Symbol(""),ue=new class extends Error{name="StaleReactionError";message="The reaction that called `getAbortSignal()` was re-run or destroyed"},Pr=1,oe=3,_t=8,bn=11;function yn(){throw new Error("https://svelte.dev/e/await_outside_boundary")}function $n(t){throw new Error("https://svelte.dev/e/lifecycle_outside_component")}function wn(){throw new Error("https://svelte.dev/e/async_derived_orphan")}function mn(t){throw new Error("https://svelte.dev/e/effect_in_teardown")}function En(){throw new Error("https://svelte.dev/e/effect_in_unowned_derived")}function Tn(t){throw new Error("https://svelte.dev/e/effect_orphan")}function An(){throw new Error("https://svelte.dev/e/effect_update_depth_exceeded")}function Mr(){throw new Error("https://svelte.dev/e/get_abort_signal_outside_reaction")}function xn(){throw new Error("https://svelte.dev/e/hydration_failed")}function Dr(t){throw new Error("https://svelte.dev/e/lifecycle_legacy_only")}function Lr(t){throw new Error("https://svelte.dev/e/props_invalid_value")}function Sn(){throw new Error("https://svelte.dev/e/state_descriptors_fixed")}function kn(){throw new Error("https://svelte.dev/e/state_prototype_fixed")}function Cn(){throw new Error("https://svelte.dev/e/state_unsafe_mutation")}const jr=1,Fr=2,qr=4,Br=8,Vr=16,Hr=1,Yr=2,Ur=4,Wr=8,Gr=16,Kr=1,zr=2,Xr=4,Nn=1,On=2,le="[",Rn="[!",Se="]",lt={},m=Symbol(),Jr="http://www.w3.org/1999/xhtml",Zr="http://www.w3.org/2000/svg",Qr="@attach";function Bt(t){console.warn("https://svelte.dev/e/hydration_mismatch")}function ts(){console.warn("https://svelte.dev/e/select_multiple_invalid_value")}let g=!1;function at(t){g=t}let p;function I(t){if(t===null)throw Bt(),lt;return p=t}function Tt(){return I(L(p))}function es(t){if(g){if(L(p)!==null)throw Bt(),lt;p=t}}function In(t=1){if(g){for(var e=t,n=p;e--;)n=L(n);p=n}}function Pn(){for(var t=0,e=p;;){if(e.nodeType===_t){var n=e.data;if(n===Se){if(t===0)return e;t-=1}else(n===le||n===Rn)&&(t+=1)}var r=L(e);e.remove(),e=r}}function ns(t){if(!t||t.nodeType!==_t)throw Bt(),lt;return t.data}function ke(t){return t===this.v}function Mn(t,e){return t!=t?e==e:t!==e||t!==null&&typeof t=="object"||typeof t=="function"}function rs(t,e){return t!==e}function Ce(t){return!Mn(t,this.v)}let Vt=!1;function ss(){Vt=!0}let b=null;function ht(t){b=t}function is(t){return Ht().get(t)}function as(t,e){return Ht().set(t,e),e}function us(t){return Ht().has(t)}function os(){return Ht()}function Dn(t,e=!1,n){b={p:b,c:null,e:null,s:t,x:null,l:Vt&&!e?{s:null,u:null,$:[]}:null}}function Ln(t){var e=b,n=e.e;if(n!==null){e.e=null;for(var r of n)Ye(r)}return t!==void 0&&(e.x=t),b=e.p,t??{}}function At(){return!Vt||b!==null&&b.l===null}function Ht(t){return b===null&&$n(),b.c??=new Map(jn(b)||void 0)}function jn(t){let e=t.p;for(;e!==null;){const n=e.c;if(n!==null)return n;e=e.p}return null}const Fn=new WeakMap;function qn(t){var e=d;if(e===null)return v.f|=Q,t;if((e.f&se)===0){if((e.f&re)===0)throw!e.parent&&t instanceof Error&&Ne(t),t;e.b.error(t)}else Yt(t,e)}function Yt(t,e){for(;e!==null;){if((e.f&re)!==0)try{e.b.error(t);return}catch{}e=e.parent}throw t instanceof Error&&Ne(t),t}function Ne(t){const e=Fn.get(t);e&&(ct(t,"message",{value:e.message}),ct(t,"stack",{value:e.stack}))}const Bn=typeof requestIdleCallback>"u"?t=>setTimeout(t,1):requestIdleCallback;let $t=[],wt=[];function Oe(){var t=$t;$t=[],Ae(t)}function Re(){var t=wt;wt=[],Ae(t)}function Ut(t){$t.length===0&&queueMicrotask(Oe),$t.push(t)}function ls(t){wt.length===0&&Bn(Re),wt.push(t)}function Vn(){$t.length>0&&Oe(),wt.length>0&&Re()}function Hn(t){let e=0,n=xt(0),r;return()=>{rr()&&(B(n),Ue(()=>(e===0&&(r=_r(()=>t(()=>Nt(n)))),e+=1,()=>{Ut(()=>{e-=1,e===0&&(r?.(),r=void 0)})})))}}var Yn=Ft|qt|re;function fs(t,e,n){new Un(t,e,n)}class Un{pending=!1;parent;#t;#e;#s;#o;#f;#i=null;#n=null;#a=null;#u=null;#r=0;#l=!1;#c=null;#h=()=>{this.#c&&Mt(this.#c,this.#r)};#_=Hn(()=>(this.#c=xt(this.#r),()=>{this.#c=null}));constructor(e,n,r){this.#t=e,this.#s=n,this.#o=r,this.#e=p,this.parent=d.b,this.pending=!!this.#s.pending,this.#f=_e(()=>{d.b=this,g&&Tt();const i=this.#s.pending;if(g&&i)this.#n=G(()=>i(this.#t)),queueMicrotask(()=>{this.#i=this.#d(()=>(Z.ensure(),G(()=>this.#o(this.#t)))),this.#r>0?this.#v():(Ot(this.#n,()=>{this.#n=null}),this.pending=!1)});else{try{this.#i=G(()=>r(this.#t))}catch(s){this.error(s)}this.#r>0?this.#v():this.pending=!1}},Yn),g&&(this.#t=p)}has_pending_snippet(){return!!this.#s.pending}#d(e){var n=d,r=v,i=b;F(this.#f),T(this.#f),ht(this.#f.ctx);try{return e()}finally{F(n),T(r),ht(i)}}#v(){const e=this.#s.pending;this.#i!==null&&(this.#u=document.createDocumentFragment(),Wn(this.#i,this.#u)),this.#n===null&&(this.#n=G(()=>e(this.#t)))}#p(e){this.#r+=e,this.#r===0&&(this.pending=!1,this.#n&&Ot(this.#n,()=>{this.#n=null}),this.#u&&(this.#t.before(this.#u),this.#u=null))}update_pending_count(e){this.has_pending_snippet()?this.#p(e):this.parent&&this.parent.#p(e),zt.add(this.#h)}get_effect_pending(){return this.#_(),B(this.#c)}error(e){var n=this.#s.onerror;let r=this.#s.failed;const i=()=>{this.#r=0,this.#a!==null&&Ot(this.#a,()=>{this.#a=null}),this.pending=!0,this.#i=this.#d(()=>(this.#l=!1,G(()=>this.#o(this.#t)))),this.#r>0?this.#v():this.pending=!1};if(this.#l||!n&&!r)throw e;var s=v;try{T(null),n?.(e,i)}finally{T(s)}this.#i&&(R(this.#i),this.#i=null),this.#n&&(R(this.#n),this.#n=null),this.#a&&(R(this.#a),this.#a=null),g&&(I(this.#e),In(),I(Pn())),r&&Ut(()=>{this.#a=this.#d(()=>{this.#l=!0;try{return G(()=>{r(this.#t,()=>e,()=>i)})}catch(a){return Yt(a,this.#f.parent),null}finally{this.#l=!1}})})}}function Wn(t,e){for(var n=t.nodes_start,r=t.nodes_end;n!==null;){var i=n===r?null:L(n);e.append(n),n=i}}function Gn(){for(var t=d.b;t!==null&&!t.has_pending_snippet();)t=t.parent;return t===null&&yn(),t}function fe(t){var e=S|O,n=v!==null&&(v.f&S)!==0?v:null;return d===null||n!==null&&(n.f&x)!==0?e|=x:d.f|=qt,{ctx:b,deps:null,effects:null,equals:ke,f:e,fn:t,reactions:null,rv:0,v:m,wv:0,parent:n??d,ac:null}}function Kn(t,e){let n=d;n===null&&wn();var r=n.b,i=void 0,s=xt(m),a=null,u=!v;return ar(()=>{try{var o=t()}catch(_){o=Promise.reject(_)}var l=()=>o;i=a?.then(l,l)??Promise.resolve(o),a=i;var f=C,h=r.pending;u&&(r.update_pending_count(1),h||f.increment());const c=(_,y=void 0)=>{a=null,h||f.activate(),y?y!==ue&&(s.f|=Q,Mt(s,y)):((s.f&Q)!==0&&(s.f^=Q),Mt(s,_)),u&&(r.update_pending_count(-1),h||f.decrement()),Me()};if(i.then(c,_=>c(null,_||"unknown")),f)return()=>{queueMicrotask(()=>f.neuter())}}),new Promise(o=>{function l(f){function h(){f===i?o(s):l(i)}f.then(h,h)}l(i)})}function cs(t){const e=fe(t);return Je(e),e}function zn(t){const e=fe(t);return e.equals=Ce,e}function Ie(t){var e=t.effects;if(e!==null){t.effects=null;for(var n=0;n<e.length;n+=1)R(e[n])}}function Xn(t){for(var e=t.parent;e!==null;){if((e.f&S)===0)return e;e=e.parent}return null}function ce(t){var e,n=d;F(Xn(t));try{Ie(t),e=tn(t)}finally{F(n)}return e}function Pe(t){var e=ce(t);if(t.equals(e)||(t.v=e,t.wv=Ze()),!pt)if(dt!==null)dt.set(t,t.v);else{var n=(K||(t.f&x)!==0)&&t.deps!==null?st:$;w(t,n)}}function Jn(t,e,n){const r=At()?fe:zn;if(e.length===0){n(t.map(r));return}var i=C,s=d,a=Zn(),u=Gn();Promise.all(e.map(o=>Kn(o))).then(o=>{i?.activate(),a();try{n([...t.map(r),...o])}catch(l){(s.f&vt)===0&&Yt(l,s)}i?.deactivate(),Me()}).catch(o=>{u.error(o)})}function Zn(){var t=d,e=v,n=b;return function(){F(t),T(e),ht(n)}}function Me(){F(null),T(null),ht(null)}const Ct=new Set;let C=null,dt=null,zt=new Set,ut=[],Wt=null,Xt=!1;class Z{#t=new Map;#e=new Map;#s=new Set;#o=0;#f=null;#i=!1;#n=[];#a=[];#u=[];#r=[];#l=[];skipped_effects=new Set;#c(e){ut=[];var n=null;if(Ct.size>1){n=new Map,dt=new Map;for(const[s,a]of this.#t)n.set(s,{v:s.v,wv:s.wv}),s.v=a;for(const s of Ct)if(s!==this)for(const[a,u]of s.#e)n.has(a)||(n.set(a,{v:a.v,wv:a.wv}),a.v=u)}for(const s of e)this.#h(s);if(this.#n.length===0&&this.#o===0){var r=this.#u,i=this.#r;this.#u=[],this.#r=[],this.#l=[],this.#_(),pe(r),pe(i),this.#f?.resolve()}else{for(const s of this.#u)w(s,$);for(const s of this.#r)w(s,$);for(const s of this.#l)w(s,$)}if(n){for(const[s,{v:a,wv:u}]of n)s.wv<=u&&(s.v=a);dt=null}for(const s of this.#n)yt(s);for(const s of this.#a)yt(s);this.#n=[],this.#a=[]}#h(e){e.f^=$;for(var n=e.first;n!==null;){var r=n.f,i=(r&(H|rt))!==0,s=i&&(r&$)!==0,a=s||(r&X)!==0||this.skipped_effects.has(n);if(!a&&n.fn!==null){if(i)n.f^=$;else if((r&ne)!==0)this.#r.push(n);else if(Gt(n))if((r&ae)!==0){var u=n.b?.pending?this.#a:this.#n;u.push(n)}else(n.f&Et)!==0&&this.#l.push(n),yt(n);var o=n.first;if(o!==null){n=o;continue}}var l=n.parent;for(n=n.next;n===null&&l!==null;)n=l.next,l=l.parent}}capture(e,n){this.#e.has(e)||this.#e.set(e,n),this.#t.set(e,e.v)}activate(){C=this}deactivate(){C=null;for(const e of zt)if(zt.delete(e),e(),C!==null)break}neuter(){this.#i=!0}flush(){ut.length>0?this.flush_effects():this.#_(),C===this&&(this.#o===0&&Ct.delete(this),this.deactivate())}flush_effects(){var e=ft;Xt=!0;try{var n=0;for(ye(!0);ut.length>0;){if(n++>1e3){var r,i;Qn()}this.#c(ut),et.clear()}}finally{Xt=!1,ye(e),Wt=null}}#_(){if(!this.#i)for(const e of this.#s)e();this.#s.clear()}increment(){this.#o+=1}decrement(){if(this.#o-=1,this.#o===0){for(const e of this.#u)w(e,O),z(e);for(const e of this.#r)w(e,O),z(e);for(const e of this.#l)w(e,O),z(e);this.#u=[],this.#r=[],this.flush()}else this.deactivate()}add_callback(e){this.#s.add(e)}settled(){return(this.#f??=pn()).promise}static ensure(e=!0){if(C===null){const n=C=new Z;Ct.add(C),e&&queueMicrotask(()=>{C===n&&n.flush()})}return C}}function De(t){var e;const n=Z.ensure(!1);for(t&&(n.flush_effects(),e=t());;){if(Vn(),ut.length===0)return n===C&&n.flush(),Wt=null,e;n.flush_effects()}}function Qn(){try{An()}catch(t){Yt(t,Wt)}}function pe(t){var e=t.length;if(e!==0){for(var n=0;n<e;n++){var r=t[n];if((r.f&(vt|X))===0&&Gt(r)){var i=Dt;if(yt(r),r.deps===null&&r.first===null&&r.nodes_start===null&&(r.teardown===null?Ke(r):r.fn=null),Dt>i&&(r.f&ie)!==0)break}}for(;n<e;n+=1)z(t[n])}}function z(t){for(var e=Wt=t;e.parent!==null;){e=e.parent;var n=e.f;if(Xt&&e===d&&(n&Et)!==0)return;if((n&(rt|H))!==0){if((n&$)===0)return;e.f^=$}}ut.push(e)}const et=new Map;function xt(t,e){var n={f:0,v:t,reactions:null,equals:ke,rv:0,wv:0};return n}function U(t,e){const n=xt(t);return Je(n),n}function tr(t,e=!1,n=!0){const r=xt(t);return e||(r.equals=Ce),Vt&&n&&b!==null&&b.l!==null&&(b.l.s??=[]).push(r),r}function W(t,e,n=!1){v!==null&&(!P||(v.f&ve)!==0)&&At()&&(v.f&(S|Et|ae|ve))!==0&&!V?.includes(t)&&Cn();let r=n?gt(e):e;return Mt(t,r)}function Mt(t,e){if(!t.equals(e)){var n=t.v;pt?et.set(t,e):et.set(t,n),t.v=e,Z.ensure().capture(t,n),(t.f&S)!==0&&((t.f&O)!==0&&ce(t),w(t,(t.f&x)===0?$:st)),t.wv=Ze(),Le(t,O),At()&&d!==null&&(d.f&$)!==0&&(d.f&(H|rt))===0&&(N===null?fr([t]):N.push(t))}return e}function Nt(t){W(t,t.v+1)}function Le(t,e){var n=t.reactions;if(n!==null)for(var r=At(),i=n.length,s=0;s<i;s++){var a=n[s],u=a.f;(u&O)===0&&(!r&&a===d||(w(a,e),(u&($|x))!==0&&((u&S)!==0?Le(a,st):z(a))))}}function gt(t){if(typeof t!="object"||t===null||tt in t)return t;const e=Te(t);if(e!==hn&&e!==dn)return t;var n=new Map,r=Ee(t),i=U(0),s=nt,a=u=>{if(nt===s)return u();var o=v,l=nt;T(null),we(s);var f=u();return T(o),we(l),f};return r&&n.set("length",U(t.length)),new Proxy(t,{defineProperty(u,o,l){(!("value"in l)||l.configurable===!1||l.enumerable===!1||l.writable===!1)&&Sn();var f=n.get(o);return f===void 0?f=a(()=>{var h=U(l.value);return n.set(o,h),h}):W(f,l.value,!0),!0},deleteProperty(u,o){var l=n.get(o);if(l===void 0){if(o in u){const f=a(()=>U(m));n.set(o,f),Nt(i)}}else W(l,m),Nt(i);return!0},get(u,o,l){if(o===tt)return t;var f=n.get(o),h=o in u;if(f===void 0&&(!h||ot(u,o)?.writable)&&(f=a(()=>{var _=gt(h?u[o]:m),y=U(_);return y}),n.set(o,f)),f!==void 0){var c=B(f);return c===m?void 0:c}return Reflect.get(u,o,l)},getOwnPropertyDescriptor(u,o){var l=Reflect.getOwnPropertyDescriptor(u,o);if(l&&"value"in l){var f=n.get(o);f&&(l.value=B(f))}else if(l===void 0){var h=n.get(o),c=h?.v;if(h!==void 0&&c!==m)return{enumerable:!0,configurable:!0,value:c,writable:!0}}return l},has(u,o){if(o===tt)return!0;var l=n.get(o),f=l!==void 0&&l.v!==m||Reflect.has(u,o);if(l!==void 0||d!==null&&(!f||ot(u,o)?.writable)){l===void 0&&(l=a(()=>{var c=f?gt(u[o]):m,_=U(c);return _}),n.set(o,l));var h=B(l);if(h===m)return!1}return f},set(u,o,l,f){var h=n.get(o),c=o in u;if(r&&o==="length")for(var _=l;_<h.v;_+=1){var y=n.get(_+"");y!==void 0?W(y,m):_ in u&&(y=a(()=>U(m)),n.set(_+"",y))}if(h===void 0)(!c||ot(u,o)?.writable)&&(h=a(()=>U(void 0)),W(h,gt(l)),n.set(o,h));else{c=h.v!==m;var q=a(()=>gt(l));W(h,q)}var St=Reflect.getOwnPropertyDescriptor(u,o);if(St?.set&&St.set.call(f,l),!c){if(r&&typeof o=="string"){var kt=n.get("length"),Y=Number(o);Number.isInteger(Y)&&Y>=kt.v&&W(kt,Y+1)}Nt(i)}return!0},ownKeys(u){B(i);var o=Reflect.ownKeys(u).filter(h=>{var c=n.get(h);return c===void 0||c.v!==m});for(var[l,f]of n)f.v!==m&&!(l in u)&&o.push(l);return o},setPrototypeOf(){kn()}})}function ge(t){try{if(t!==null&&typeof t=="object"&&tt in t)return t[tt]}catch{}return t}function _s(t,e){return Object.is(ge(t),ge(e))}var be,er,je,Fe,qe;function Jt(){if(be===void 0){be=window,er=document,je=/Firefox/.test(navigator.userAgent);var t=Element.prototype,e=Node.prototype,n=Text.prototype;Fe=ot(e,"firstChild").get,qe=ot(e,"nextSibling").get,de(t)&&(t.__click=void 0,t.__className=void 0,t.__attributes=null,t.__style=void 0,t.__e=void 0),de(n)&&(n.__t=void 0)}}function J(t=""){return document.createTextNode(t)}function D(t){return Fe.call(t)}function L(t){return qe.call(t)}function hs(t,e){if(!g)return D(t);var n=D(p);if(n===null)n=p.appendChild(J());else if(e&&n.nodeType!==oe){var r=J();return n?.before(r),I(r),r}return I(n),n}function ds(t,e){if(!g){var n=D(t);return n instanceof Comment&&n.data===""?L(n):n}return p}function vs(t,e=1,n=!1){let r=g?p:t;for(var i;e--;)i=r,r=L(r);if(!g)return r;if(n&&r?.nodeType!==oe){var s=J();return r===null?i?.after(s):r.before(s),I(s),s}return I(r),r}function Be(t){t.textContent=""}function ps(){return!1}function Ve(t){d===null&&v===null&&Tn(),v!==null&&(v.f&x)!==0&&d===null&&En(),pt&&mn()}function nr(t,e){var n=e.last;n===null?e.last=e.first=t:(n.next=t,t.prev=n,e.last=t)}function j(t,e,n,r=!0){var i=d;i!==null&&(i.f&X)!==0&&(t|=X);var s={ctx:b,deps:null,nodes_start:null,nodes_end:null,f:t|O,first:null,fn:e,last:null,next:null,parent:i,b:i&&i.b,prev:null,teardown:null,transitions:null,wv:0,ac:null};if(n)try{yt(s),s.f|=se}catch(o){throw R(s),o}else e!==null&&z(s);var a=n&&s.deps===null&&s.first===null&&s.nodes_start===null&&s.teardown===null&&(s.f&qt)===0;if(!a&&r&&(i!==null&&nr(s,i),v!==null&&(v.f&S)!==0)){var u=v;(u.effects??=[]).push(s)}return s}function rr(){return v!==null&&!P}function He(t){const e=j(jt,null,!1);return w(e,$),e.teardown=t,e}function gs(t){Ve();var e=d.f,n=!v&&(e&H)!==0&&(e&se)===0;if(n){var r=b;(r.e??=[]).push(t)}else return Ye(t)}function Ye(t){return j(ne|ie,t,!1)}function bs(t){return Ve(),j(jt|ie,t,!0)}function sr(t){Z.ensure();const e=j(rt,t,!0);return()=>{R(e)}}function ir(t){Z.ensure();const e=j(rt,t,!0);return(n={})=>new Promise(r=>{n.outro?Ot(e,()=>{R(e),r(void 0)}):(R(e),r(void 0))})}function ys(t){return j(ne,t,!1)}function ar(t){return j(ae|qt,t,!0)}function Ue(t,e=0){return j(jt|e,t,!0)}function $s(t,e=[],n=[]){Jn(e,n,r=>{j(jt,()=>t(...r.map(B)),!0)})}function _e(t,e=0){var n=j(Et|e,t,!0);return n}function G(t,e=!0){return j(H,t,!0,e)}function We(t){var e=t.teardown;if(e!==null){const n=pt,r=v;$e(!0),T(null);try{e.call(null)}finally{$e(n),T(r)}}}function Ge(t,e=!1){var n=t.first;for(t.first=t.last=null;n!==null;){n.ac?.abort(ue);var r=n.next;(n.f&rt)!==0?n.parent=null:R(n,e),n=r}}function ur(t){for(var e=t.first;e!==null;){var n=e.next;(e.f&H)===0&&R(e),e=n}}function R(t,e=!0){var n=!1;(e||(t.f&xe)!==0)&&t.nodes_start!==null&&t.nodes_end!==null&&(or(t.nodes_start,t.nodes_end),n=!0),Ge(t,e&&!n),Lt(t,0),w(t,vt);var r=t.transitions;if(r!==null)for(const s of r)s.stop();We(t);var i=t.parent;i!==null&&i.first!==null&&Ke(t),t.next=t.prev=t.teardown=t.ctx=t.deps=t.fn=t.nodes_start=t.nodes_end=t.ac=null}function or(t,e){for(;t!==null;){var n=t===e?null:L(t);t.remove(),t=n}}function Ke(t){var e=t.parent,n=t.prev,r=t.next;n!==null&&(n.next=r),r!==null&&(r.prev=n),e!==null&&(e.first===t&&(e.first=r),e.last===t&&(e.last=n))}function Ot(t,e){var n=[];ze(t,n,!0),lr(n,()=>{R(t),e&&e()})}function lr(t,e){var n=t.length;if(n>0){var r=()=>--n||e();for(var i of t)i.out(r)}else e()}function ze(t,e,n){if((t.f&X)===0){if(t.f^=X,t.transitions!==null)for(const a of t.transitions)(a.is_global||n)&&e.push(a);for(var r=t.first;r!==null;){var i=r.next,s=(r.f&Ft)!==0||(r.f&H)!==0;ze(r,e,s?n:!1),r=i}}}function ws(t){Xe(t,!0)}function Xe(t,e){if((t.f&X)!==0){t.f^=X,(t.f&$)===0&&(w(t,O),z(t));for(var n=t.first;n!==null;){var r=n.next,i=(n.f&Ft)!==0||(n.f&H)!==0;Xe(n,i?e:!1),n=r}if(t.transitions!==null)for(const s of t.transitions)(s.is_global||e)&&s.in()}}let ft=!1;function ye(t){ft=t}let pt=!1;function $e(t){pt=t}let v=null,P=!1;function T(t){v=t}let d=null;function F(t){d=t}let V=null;function Je(t){v!==null&&(V===null?V=[t]:V.push(t))}let E=null,A=0,N=null;function fr(t){N=t}let Dt=1,mt=0,nt=mt;function we(t){nt=t}let K=!1;function Ze(){return++Dt}function Gt(t){var e=t.f;if((e&O)!==0)return!0;if((e&st)!==0){var n=t.deps,r=(e&x)!==0;if(n!==null){var i,s,a=(e&Pt)!==0,u=r&&d!==null&&!K,o=n.length;if((a||u)&&(d===null||(d.f&vt)===0)){var l=t,f=l.parent;for(i=0;i<o;i++)s=n[i],(a||!s?.reactions?.includes(l))&&(s.reactions??=[]).push(l);a&&(l.f^=Pt),u&&f!==null&&(f.f&x)===0&&(l.f^=x)}for(i=0;i<o;i++)if(s=n[i],Gt(s)&&Pe(s),s.wv>t.wv)return!0}(!r||d!==null&&!K)&&w(t,$)}return!1}function Qe(t,e,n=!0){var r=t.reactions;if(r!==null&&!V?.includes(t))for(var i=0;i<r.length;i++){var s=r[i];(s.f&S)!==0?Qe(s,e,!1):e===s&&(n?w(s,O):(s.f&$)!==0&&w(s,st),z(s))}}function tn(t){var e=E,n=A,r=N,i=v,s=K,a=V,u=b,o=P,l=nt,f=t.f;E=null,A=0,N=null,K=(f&x)!==0&&(P||!ft||v===null),v=(f&(H|rt))===0?t:null,V=null,ht(t.ctx),P=!1,nt=++mt,t.ac!==null&&(t.ac.abort(ue),t.ac=null);try{t.f|=Kt;var h=(0,t.fn)(),c=t.deps;if(E!==null){var _;if(Lt(t,A),c!==null&&A>0)for(c.length=A+E.length,_=0;_<E.length;_++)c[A+_]=E[_];else t.deps=c=E;if(!K||(f&S)!==0&&t.reactions!==null)for(_=A;_<c.length;_++)(c[_].reactions??=[]).push(t)}else c!==null&&A<c.length&&(Lt(t,A),c.length=A);if(At()&&N!==null&&!P&&c!==null&&(t.f&(S|st|O))===0)for(_=0;_<N.length;_++)Qe(N[_],t);return i!==null&&i!==t&&(mt++,N!==null&&(r===null?r=N:r.push(...N))),(t.f&Q)!==0&&(t.f^=Q),h}catch(y){return qn(y)}finally{t.f^=Kt,E=e,A=n,N=r,v=i,K=s,V=a,ht(u),P=o,nt=l}}function cr(t,e){let n=e.reactions;if(n!==null){var r=fn.call(n,t);if(r!==-1){var i=n.length-1;i===0?n=e.reactions=null:(n[r]=n[i],n.pop())}}n===null&&(e.f&S)!==0&&(E===null||!E.includes(e))&&(w(e,st),(e.f&(x|Pt))===0&&(e.f^=Pt),Ie(e),Lt(e,0))}function Lt(t,e){var n=t.deps;if(n!==null)for(var r=e;r<n.length;r++)cr(t,n[r])}function yt(t){var e=t.f;if((e&vt)===0){w(t,$);var n=d,r=ft;d=t,ft=!0;try{(e&Et)!==0?ur(t):Ge(t),We(t);var i=tn(t);t.teardown=typeof i=="function"?i:null,t.wv=Dt;var s}finally{ft=r,d=n}}}async function ms(){await Promise.resolve(),De()}function Es(){return Z.ensure().settled()}function B(t){var e=t.f,n=(e&S)!==0;if(v!==null&&!P){var r=d!==null&&(d.f&vt)!==0;if(!r&&!V?.includes(t)){var i=v.deps;if((v.f&Kt)!==0)t.rv<mt&&(t.rv=mt,E===null&&i!==null&&i[A]===t?A++:E===null?E=[t]:(!K||!E.includes(t))&&E.push(t));else{(v.deps??=[]).push(t);var s=t.reactions;s===null?t.reactions=[v]:s.includes(v)||s.push(v)}}}else if(n&&t.deps===null&&t.effects===null){var a=t,u=a.parent;u!==null&&(u.f&x)===0&&(a.f^=x)}if(pt){if(et.has(t))return et.get(t);if(n){a=t;var o=a.v;return((a.f&$)!==0||en(a))&&(o=ce(a)),et.set(a,o),o}}else if(n){if(a=t,dt?.has(a))return dt.get(a);Gt(a)&&Pe(a)}if((t.f&Q)!==0)throw t.v;return t.v}function en(t){if(t.v===m)return!0;if(t.deps===null)return!1;for(const e of t.deps)if(et.has(e)||(e.f&S)!==0&&en(e))return!0;return!1}function _r(t){var e=P;try{return P=!0,t()}finally{P=e}}const hr=-7169;function w(t,e){t.f=t.f&hr|e}function Ts(t){if(!(typeof t!="object"||!t||t instanceof EventTarget)){if(tt in t)Zt(t);else if(!Array.isArray(t))for(let e in t){const n=t[e];typeof n=="object"&&n&&tt in n&&Zt(n)}}}function Zt(t,e=new Set){if(typeof t=="object"&&t!==null&&!(t instanceof EventTarget)&&!e.has(t)){e.add(t),t instanceof Date&&t.getTime();for(let r in t)try{Zt(t[r],e)}catch{}const n=Te(t);if(n!==Object.prototype&&n!==Array.prototype&&n!==Map.prototype&&n!==Set.prototype&&n!==Date.prototype){const r=_n(n);for(let i in r){const s=r[i].get;if(s)try{s.call(t)}catch{}}}}}function As(t){return t.endsWith("capture")&&t!=="gotpointercapture"&&t!=="lostpointercapture"}const dr=["beforeinput","click","change","dblclick","contextmenu","focusin","focusout","input","keydown","keyup","mousedown","mousemove","mouseout","mouseover","mouseup","pointerdown","pointermove","pointerout","pointerover","pointerup","touchend","touchmove","touchstart"];function xs(t){return dr.includes(t)}const vr={formnovalidate:"formNoValidate",ismap:"isMap",nomodule:"noModule",playsinline:"playsInline",readonly:"readOnly",defaultvalue:"defaultValue",defaultchecked:"defaultChecked",srcobject:"srcObject",novalidate:"noValidate",allowfullscreen:"allowFullscreen",disablepictureinpicture:"disablePictureInPicture",disableremoteplayback:"disableRemotePlayback"};function Ss(t){return t=t.toLowerCase(),vr[t]??t}const pr=["touchstart","touchmove"];function gr(t){return pr.includes(t)}const br=["textarea","script","style","title"];function ks(t){return br.includes(t)}function Cs(t,e){if(e){const n=document.body;t.autofocus=!0,Ut(()=>{document.activeElement===n&&t.focus()})}}function Ns(t){g&&D(t)!==null&&Be(t)}let me=!1;function yr(){me||(me=!0,document.addEventListener("reset",t=>{Promise.resolve().then(()=>{if(!t.defaultPrevented)for(const e of t.target.elements)e.__on_r?.()})},{capture:!0}))}function nn(t){var e=v,n=d;T(null),F(null);try{return t()}finally{T(e),F(n)}}function Os(t,e,n,r=n){t.addEventListener(e,()=>nn(n));const i=t.__on_r;i?t.__on_r=()=>{i(),r(!0)}:t.__on_r=()=>r(!0),yr()}const rn=new Set,Qt=new Set;function sn(t,e,n,r={}){function i(s){if(r.capture||bt.call(e,s),!s.cancelBubble)return nn(()=>n?.call(this,s))}return t.startsWith("pointer")||t.startsWith("touch")||t==="wheel"?Ut(()=>{e.addEventListener(t,i,r)}):e.addEventListener(t,i,r),i}function Rs(t,e,n,r={}){var i=sn(e,t,n,r);return()=>{t.removeEventListener(e,i,r)}}function Is(t,e,n,r,i){var s={capture:r,passive:i},a=sn(t,e,n,s);(e===document.body||e===window||e===document||e instanceof HTMLMediaElement)&&He(()=>{e.removeEventListener(t,a,s)})}function Ps(t){for(var e=0;e<t.length;e++)rn.add(t[e]);for(var n of Qt)n(t)}function bt(t){var e=this,n=e.ownerDocument,r=t.type,i=t.composedPath?.()||[],s=i[0]||t.target,a=0,u=t.__root;if(u){var o=i.indexOf(u);if(o!==-1&&(e===document||e===window)){t.__root=e;return}var l=i.indexOf(e);if(l===-1)return;o<=l&&(a=o)}if(s=i[a]||t.target,s!==e){ct(t,"currentTarget",{configurable:!0,get(){return s||n}});var f=v,h=d;T(null),F(null);try{for(var c,_=[];s!==null;){var y=s.assignedSlot||s.parentNode||s.host||null;try{var q=s["__"+r];if(q!=null&&(!s.disabled||t.target===s))if(Ee(q)){var[St,...kt]=q;St.apply(s,[t,...kt])}else q.call(s,t)}catch(Y){c?_.push(Y):c=Y}if(t.cancelBubble||y===e||y===null)break;s=y}if(c){for(let Y of _)queueMicrotask(()=>{throw Y});throw c}}finally{t.__root=e,delete t.currentTarget,T(f),F(h)}}}let k;function $r(){k=void 0}function Ms(t){let e=null,n=g;var r;if(g){for(e=p,k===void 0&&(k=D(document.head));k!==null&&(k.nodeType!==_t||k.data!==le);)k=L(k);k===null?at(!1):k=I(L(k))}g||(r=document.head.appendChild(J()));try{_e(()=>t(r),xe)}finally{n&&(at(!0),k=p,I(e))}}function he(t){var e=document.createElement("template");return e.innerHTML=t.replaceAll("<!>","<!---->"),e.content}function M(t,e){var n=d;n.nodes_start===null&&(n.nodes_start=t,n.nodes_end=e)}function Ds(t,e){var n=(e&Nn)!==0,r=(e&On)!==0,i,s=!t.startsWith("<!>");return()=>{if(g)return M(p,null),p;i===void 0&&(i=he(s?t:"<!>"+t),n||(i=D(i)));var a=r||je?document.importNode(i,!0):i.cloneNode(!0);if(n){var u=D(a),o=a.lastChild;M(u,o)}else M(a,a);return a}}function wr(t,e,n="svg"){var r=!t.startsWith("<!>"),i=`<${n}>${r?t:"<!>"+t}</${n}>`,s;return()=>{if(g)return M(p,null),p;if(!s){var a=he(i),u=D(a);s=D(u)}var o=s.cloneNode(!0);return M(o,o),o}}function Ls(t,e){return wr(t,e,"svg")}function js(t){return()=>mr(t())}function mr(t){if(g)return t;const e=t.nodeType===bn,n=t.tagName==="SCRIPT"?[t]:t.querySelectorAll("script"),r=d;for(const s of n){const a=document.createElement("script");for(var i of s.attributes)a.setAttribute(i.name,i.value);a.textContent=s.textContent,(e?t.firstChild===s:t===s)&&(r.nodes_start=a),(e?t.lastChild===s:t===s)&&(r.nodes_end=a),s.replaceWith(a)}return t}function Fs(t=""){if(!g){var e=J(t+"");return M(e,e),e}var n=p;return n.nodeType!==oe&&(n.before(n=J()),I(n)),M(n,n),n}function qs(){if(g)return M(p,null),p;var t=document.createDocumentFragment(),e=document.createComment(""),n=J();return t.append(e,n),M(e,n),t}function Er(t,e){if(g){d.nodes_end=p,Tt();return}t!==null&&t.before(e)}function Bs(){if(g&&p&&p.nodeType===_t&&p.textContent?.startsWith("#")){const t=p.textContent.substring(1);return Tt(),t}return(window.__svelte??={}).uid??=1,`c${window.__svelte.uid++}`}let te=!0;function Vs(t){te=t}function Hs(t,e){var n=e==null?"":typeof e=="object"?e+"":e;n!==(t.__t??=t.nodeValue)&&(t.__t=n,t.nodeValue=n+"")}function an(t,e){return un(t,e)}function Tr(t,e){Jt(),e.intro=e.intro??!1;const n=e.target,r=g,i=p;try{for(var s=D(n);s&&(s.nodeType!==_t||s.data!==le);)s=L(s);if(!s)throw lt;at(!0),I(s),Tt();const a=un(t,{...e,anchor:s});if(p===null||p.nodeType!==_t||p.data!==Se)throw Bt(),lt;return at(!1),a}catch(a){if(a===lt)return e.recover===!1&&xn(),Jt(),Be(n),at(!1),an(t,e);throw a}finally{at(r),I(i),$r()}}const it=new Map;function un(t,{target:e,anchor:n,props:r={},events:i,context:s,intro:a=!0}){Jt();var u=new Set,o=h=>{for(var c=0;c<h.length;c++){var _=h[c];if(!u.has(_)){u.add(_);var y=gr(_);e.addEventListener(_,bt,{passive:y});var q=it.get(_);q===void 0?(document.addEventListener(_,bt,{passive:y}),it.set(_,1)):it.set(_,q+1)}}};o(cn(rn)),Qt.add(o);var l=void 0,f=ir(()=>{var h=n??e.appendChild(J());return G(()=>{if(s){Dn({});var c=b;c.c=s}i&&(r.$$events=i),g&&M(h,null),te=a,l=t(h,r)||{},te=!0,g&&(d.nodes_end=p),s&&Ln()}),()=>{for(var c of u){e.removeEventListener(c,bt);var _=it.get(c);--_===0?(document.removeEventListener(c,bt),it.delete(c)):it.set(c,_)}Qt.delete(o),h!==n&&h.parentNode?.removeChild(h)}});return ee.set(l,f),l}let ee=new WeakMap;function Ar(t,e){const n=ee.get(t);return n?(ee.delete(t),n(e)):Promise.resolve()}function Ys(t,e,...n){var r=t,i=vn,s;_e(()=>{i!==(i=e())&&(s&&(R(s),s=null),s=G(()=>i(r,...n)))},Ft),g&&(r=p)}function Us(t){return(e,...n)=>{var r=t(...n),i;if(g)i=p,Tt();else{var s=r.render().trim(),a=he(s);i=D(a),e.before(i)}const u=r.setup?.(i);M(i,i),typeof u=="function"&&He(u)}}function xr(t){return new on(t)}function Ws(t){return class extends on{constructor(e){super({component:t,...e})}}}class on{#t;#e;constructor(e){var n=new Map,r=(s,a)=>{var u=tr(a,!1,!1);return n.set(s,u),u};const i=new Proxy({...e.props||{},$$events:{}},{get(s,a){return B(n.get(a)??r(a,Reflect.get(s,a)))},has(s,a){return a===gn?!0:(B(n.get(a)??r(a,Reflect.get(s,a))),Reflect.has(s,a))},set(s,a,u){return W(n.get(a)??r(a,u),u),Reflect.set(s,a,u)}});this.#e=(e.hydrate?Tr:an)(e.component,{target:e.target,anchor:e.anchor,props:i,context:e.context,intro:e.intro??!1,recover:e.recover}),(!e?.props?.$$host||e.sync===!1)&&De(),this.#t=i.$$events;for(const s of Object.keys(this.#e))s==="$set"||s==="$destroy"||s==="$on"||ct(this,s,{get(){return this.#e[s]},set(a){this.#e[s]=a},enumerable:!0});this.#e.$set=s=>{Object.assign(i,s)},this.#e.$destroy=()=>{Ar(this.#e)}}$set(e){this.#e.$set(e)}$on(e,n){this.#t[e]=this.#t[e]||[];const r=(...i)=>n.call(this,...i);return this.#t[e].push(r),()=>{this.#t[e]=this.#t[e].filter(i=>i!==r)}}$destroy(){this.#e.$destroy()}}let ln;typeof HTMLElement=="function"&&(ln=class extends HTMLElement{$$ctor;$$s;$$c;$$cn=!1;$$d={};$$r=!1;$$p_d={};$$l={};$$l_u=new Map;$$me;constructor(t,e,n){super(),this.$$ctor=t,this.$$s=e,n&&this.attachShadow({mode:"open"})}addEventListener(t,e,n){if(this.$$l[t]=this.$$l[t]||[],this.$$l[t].push(e),this.$$c){const r=this.$$c.$on(t,e);this.$$l_u.set(e,r)}super.addEventListener(t,e,n)}removeEventListener(t,e,n){if(super.removeEventListener(t,e,n),this.$$c){const r=this.$$l_u.get(e);r&&(r(),this.$$l_u.delete(e))}}async connectedCallback(){if(this.$$cn=!0,!this.$$c){let t=function(r){return i=>{const s=document.createElement("slot");r!=="default"&&(s.name=r),Er(i,s)}};if(await Promise.resolve(),!this.$$cn||this.$$c)return;const e={},n=Sr(this);for(const r of this.$$s)r in n&&(r==="default"&&!this.$$d.children?(this.$$d.children=t(r),e.default=!0):e[r]=t(r));for(const r of this.attributes){const i=this.$$g_p(r.name);i in this.$$d||(this.$$d[i]=Rt(i,r.value,this.$$p_d,"toProp"))}for(const r in this.$$p_d)!(r in this.$$d)&&this[r]!==void 0&&(this.$$d[r]=this[r],delete this[r]);this.$$c=xr({component:this.$$ctor,target:this.shadowRoot||this,props:{...this.$$d,$$slots:e,$$host:this}}),this.$$me=sr(()=>{Ue(()=>{this.$$r=!0;for(const r of It(this.$$c)){if(!this.$$p_d[r]?.reflect)continue;this.$$d[r]=this.$$c[r];const i=Rt(r,this.$$d[r],this.$$p_d,"toAttribute");i==null?this.removeAttribute(this.$$p_d[r].attribute||r):this.setAttribute(this.$$p_d[r].attribute||r,i)}this.$$r=!1})});for(const r in this.$$l)for(const i of this.$$l[r]){const s=this.$$c.$on(r,i);this.$$l_u.set(i,s)}this.$$l={}}}attributeChangedCallback(t,e,n){this.$$r||(t=this.$$g_p(t),this.$$d[t]=Rt(t,n,this.$$p_d,"toProp"),this.$$c?.$set({[t]:this.$$d[t]}))}disconnectedCallback(){this.$$cn=!1,Promise.resolve().then(()=>{!this.$$cn&&this.$$c&&(this.$$c.$destroy(),this.$$me(),this.$$c=void 0)})}$$g_p(t){return It(this.$$p_d).find(e=>this.$$p_d[e].attribute===t||!this.$$p_d[e].attribute&&e.toLowerCase()===t)||t}});function Rt(t,e,n,r){const i=n[t]?.type;if(e=i==="Boolean"&&typeof e!="boolean"?e!=null:e,!r||!n[t])return e;if(r==="toAttribute")switch(i){case"Object":case"Array":return e==null?null:JSON.stringify(e);case"Boolean":return e?"":null;case"Number":return e??null;default:return e}else switch(i){case"Object":case"Array":return e&&JSON.parse(e);case"Boolean":return e;case"Number":return e!=null?+e:e;default:return e}}function Sr(t){const e={};return t.childNodes.forEach(n=>{e[n.slot||"default"]=!0}),e}function Gs(t,e,n,r,i,s){let a=class extends ln{constructor(){super(t,n,i),this.$$p_d=e}static get observedAttributes(){return It(e).map(u=>(e[u].attribute||u).toLowerCase())}};return It(e).forEach(u=>{ct(a.prototype,u,{get(){return this.$$c&&u in this.$$c?this.$$c[u]:this.$$d[u]},set(o){o=Rt(u,o,e),this.$$d[u]=o;var l=this.$$c;if(l){var f=ot(l,u)?.get;f?l[u]=o:l.$set({[u]:o})}}})}),r.forEach(u=>{ct(a.prototype,u,{get(){return this.$$c?.[u]}})}),t.element=a,a}export{gn as $,an as A,as as B,Es as C,ms as D,Ar as E,vn as F,B as G,cs as H,bs as I,Ae as J,Nr as K,Ts as L,fe as M,qs as N,fs as O,U as P,Ys as Q,Ps as R,In as S,W as T,d as U,vt as V,pt as W,gt as X,zn as Y,kr as Z,tt as _,ds as a,lr as a$,ot as a0,Lr as a1,Ur as a2,Hr as a3,Wr as a4,Yr as a5,Gr as a6,ss as a7,Fs as a8,Ws as a9,T as aA,ht as aB,Ms as aC,Is as aD,Or as aE,er as aF,Ns as aG,js as aH,Hn as aI,Rs as aJ,Ls as aK,Bs as aL,be as aM,Te as aN,hn as aO,Qr as aP,rs as aQ,Mn as aR,cn as aS,Fr as aT,X as aU,R as aV,jr as aW,Vr as aX,L as aY,ze as aZ,Be as a_,_e as aa,Ft as ab,J as ac,G as ad,C as ae,m as af,ps as ag,ws as ah,Ot as ai,g as aj,Tt as ak,ns as al,Rn as am,Pn as an,I as ao,at as ap,p as aq,ys as ar,Ue as as,Ut as at,At as au,Cr as av,Mt as aw,xt as ax,tr as ay,F as az,Er as b,D as b0,_t as b1,Se as b2,qr as b3,Br as b4,or as b5,Bt as b6,lt as b7,M as b8,he as b9,nt as bA,Nt as bB,sr as bC,Zr as ba,Pr as bb,Vs as bc,ks as bd,ts as be,_s as bf,He as bg,Jn as bh,As as bi,sn as bj,Cs as bk,Ss as bl,Jr as bm,Rr as bn,ls as bo,yr as bp,xs as bq,_n as br,te as bs,Et as bt,se as bu,Xr as bv,nn as bw,Kr as bx,zr as by,Os as bz,Gs as c,Ln as d,hs as e,Ds as f,Hs as g,v as h,Mr as i,b as j,Ee as k,$n as l,Dr as m,Vt as n,_r as o,Dn as p,Us as q,es as r,vs as s,$s as t,gs as u,De as v,os as w,is as x,us as y,Tr as z};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{l as a,u as v,h as i,i as d,j as e,k as g,m as f,n as y,o as c,q as b,v as x,w as h,x as C,y as k,z as S,A as w,B as A,C as j,D,E}from"./Cx_YT9bD.js";function z(){return i===null&&d(),(i.ac??=new AbortController).signal}function _(t){e===null&&a(),y&&e.l!==null?u(e).m.push(t):v(()=>{const n=c(t);if(typeof n=="function")return n})}function M(t){e===null&&a(),_(()=>()=>c(t))}function O(t,n,{bubbles:l=!1,cancelable:s=!1}={}){return new CustomEvent(t,{detail:n,bubbles:l,cancelable:s})}function P(){const t=e;return t===null&&a(),(n,l,s)=>{const o=t.s.$$events?.[n];if(o){const p=g(o)?o.slice():[o],r=O(n,l,s);for(const m of p)m.call(t.x,r);return!r.defaultPrevented}return!0}}function U(t){e===null&&a(),e.l===null&&f(),u(e).b.push(t)}function $(t){e===null&&a(),e.l===null&&f(),u(e).a.push(t)}function u(t){var n=t.l;return n.u??={a:[],b:[],m:[]}}const B=Object.freeze(Object.defineProperty({__proto__:null,afterUpdate:$,beforeUpdate:U,createEventDispatcher:P,createRawSnippet:b,flushSync:x,getAbortSignal:z,getAllContexts:h,getContext:C,hasContext:k,hydrate:S,mount:w,onDestroy:M,onMount:_,setContext:A,settled:j,tick:D,unmount:E,untrack:c},Symbol.toStringTag,{value:"Module"}));export{_ as o,B as s};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const Wr="https://liipgpt.api.dev.genai.liip.ch/liipgpt",Fr="3.0.6";function Xe(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var se,we;function Qe(){if(we)return se;we=1;var t=function(k){return e(k)&&!r(k)};function e(v){return!!v&&typeof v=="object"}function r(v){var k=Object.prototype.toString.call(v);return k==="[object RegExp]"||k==="[object Date]"||o(v)}var a=typeof Symbol=="function"&&Symbol.for,n=a?Symbol.for("react.element"):60103;function o(v){return v.$$typeof===n}function s(v){return Array.isArray(v)?[]:{}}function i(v,k){return k.clone!==!1&&k.isMergeableObject(v)?D(s(v),v,k):v}function f(v,k,w){return v.concat(k).map(function(M){return i(M,w)})}function p(v,k){if(!k.customMerge)return D;var w=k.customMerge(v);return typeof w=="function"?w:D}function _(v){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(v).filter(function(k){return Object.propertyIsEnumerable.call(v,k)}):[]}function E(v){return Object.keys(v).concat(_(v))}function J(v,k){try{return k in v}catch{return!1}}function Ge(v,k){return J(v,k)&&!(Object.hasOwnProperty.call(v,k)&&Object.propertyIsEnumerable.call(v,k))}function qe(v,k,w){var M={};return w.isMergeableObject(v)&&E(v).forEach(function(j){M[j]=i(v[j],w)}),E(k).forEach(function(j){Ge(v,j)||(J(v,j)&&w.isMergeableObject(k[j])?M[j]=p(j,w)(v[j],k[j],w):M[j]=i(k[j],w))}),M}function D(v,k,w){w=w||{},w.arrayMerge=w.arrayMerge||f,w.isMergeableObject=w.isMergeableObject||t,w.cloneUnlessOtherwiseSpecified=i;var M=Array.isArray(k),j=Array.isArray(v),Je=M===j;return Je?M?w.arrayMerge(v,k,w):qe(v,k,w):i(k,w)}D.all=function(k,w){if(!Array.isArray(k))throw new Error("first argument should be an array");return k.reduce(function(M,j){return D(M,j,w)},{})};var Ye=D;return se=Ye,se}var Ke=Qe();const er=Xe(Ke),rr=t=>t===null||typeof t!="object",ce=t=>{if(rr(t))return t;if(Array.isArray(t))return t.map(ce);const e=Object.entries(t).filter(([r,a])=>a!==void 0).map(([r,a])=>[r,ce(a)]);return Object.fromEntries(e)},tr=(t,e)=>{const r=ce(e);return er(t,r)},$e={tokens:{font:{family:"-apple-system, BlinkMacSystemFont, avenir next, avenir, segoe ui, helvetica neue, helvetica, Cantarell, Ubuntu, roboto, noto, arial, sans-serif"},colors:{brand:{50:"#f9fafb",100:"#f3f4f6",200:"#e5e7eb",300:"#d1d5db",400:"#9ca3af",500:"#6b7280",600:"#4b5563",700:"#374151",800:"#2d3748",900:"#1a202c",950:"#171923"},highlight:{50:"#f9fafb",100:"#f3f4f6",200:"#e5e7eb",300:"#d1d5db",400:"#9ca3af",500:"#6b7280",600:"#4b5563",700:"#374151",800:"#2d3748",900:"#1a202c",950:"#171923"},grey:{0:"#ffffff",50:"#f9fafb",100:"#f3f4f6",200:"#e5e7eb",300:"#d1d5db",400:"#9ca3af",500:"#6b7280",600:"#4b5563",700:"#374151",800:"#2d3748",900:"#1a202c",950:"#171923",1e3:"#000000"}},base:{fontSizeXs:{minRem:.75,maxRem:.875},fontSizeSm:{minRem:1,maxRem:1},fontSizeBody:{minRem:1,maxRem:1.25},fontSizeH3:{minRem:1.125,maxRem:1.5},fontSizeH2:{minRem:1.25,maxRem:1.75},fontSizeH1:{minRem:1.5,maxRem:2},fontWeightNormal:"400",fontWeightBold:"700",fontWeightTitle:"700",lineHeightDefault:"1.5",lineHeightSnug:"1.375",lineHeightTight:"1.25",borderRadius:{minRem:.5,maxRem:.75},lineColor:"color-mix(in srgb, var(--color-brand-950) 20%, transparent)",boxShadow:"0px 0px 2px rgba(0, 0, 0, 0.15), 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1)"},components:{body:{background:"var(--color-grey-0)",color:"var(--color-grey-900)",focus:{color:"var(--color-highlight-500)"},custom:{selectionColor:"var(--color-grey-0)",selectionBackground:"var(--color-brand-700)",focusWidth:"var(--spacer-3)",focusOffset:"var(--spacer-2)",focusStyle:"solid"}},container:{custom:{maxWidth:"1024px"}},avatar:{color:"var(--color-brand-400)",background:"var(--color-grey-100)"},anchor:{color:"var(--color-brand-600)",hover:{color:"var(--color-brand-950)"}},btnPrimary:{color:"var(--color-grey-0)",background:"var(--color-brand-700)",borderRadius:"var(--base-border-radius)",hover:{background:"var(--color-brand-900)"}},btnSecondary:{color:"var(--color-brand-700)",background:"var(--color-brand-100)",borderRadius:"var(--base-border-radius)",hover:{color:"var(--color-grey-1000)",background:"var(--color-brand-200)"}},btnTertiary:{color:"var(--anchor-color)",background:"transparent",borderRadius:"var(--base-border-radius)",hover:{color:"var(--anchor-hover-color)"}},card:{color:"var(--color-grey-900)",background:"var(--color-grey-100)",borderRadius:"var(--base-border-radius)",boxShadow:"none",hover:{color:"var(--color-grey-1000)",background:"var(--color-brand-100)"},custom:{iconColor:"var(--anchor-color)",iconHoverColor:"var(--anchor-hover-color)"}},input:{background:"var(--color-grey-0)",borderColor:"var(--color-grey-300)",borderWidth:"1px",borderRadius:"var(--base-border-radius)",custom:{padding:"var(--spacer-r-16) var(--spacer-r-20)",placeholderColor:"var(--color-grey-500)",placeholderOpacity:"1"}},label:{color:"var(--color-grey-600)"},hr:{color:"var(--base-line-color)"},checkbox:{color:"transparent",background:"var(--color-grey-0)",borderColor:"var(--color-grey-300)",borderWidth:"1px",borderRadius:"0.2em",custom:{checkedColor:"var(--btn-primary-color)",checkedBorderColor:"var(--color-brand-700)",checkedBackground:"var(--color-brand-700)"}},radio:{color:"transparent",background:"var(--color-grey-0)",borderColor:"var(--color-grey-300)",borderWidth:"1px",custom:{checkedColor:"var(--btn-primary-color)",checkedBorderColor:"var(--color-brand-700)",checkedBackground:"var(--color-brand-700)"}},contextBox:{color:"var(--card-color)",background:"var(--card-background)",borderColor:"var(--card-border-color)",borderWidth:"var(--card-border-width)",borderRadius:"var(--card-border-radius)",boxShadow:"var(--base-box-shadow)",custom:{transitionDuration:200,transitionDelay:200,transitionY:8,titleColor:"var(--color-grey-1000)",titleFontWeight:"var(--base-font-weight-bold)",separatorColor:"var(--base-line-color)",errorColor:"var(--message-error-color)"}},contextBoxMenuItem:{background:"transparent",color:"var(--body-color)",borderRadius:"calc(var(--base-border-radius) / 2)",hover:{color:"var(--btn-secondary-hover-color)",background:"var(--btn-secondary-hover-background)"},custom:{activeColor:"var(--btn-secondary-hover-color)",activeBackground:"var(--btn-secondary-hover-background)"}},chatFooter:{color:"var(--color-grey-400)",background:"var(--body-background)",borderRadius:"var(--base-border-radius)",boxShadow:"0px -10px 20px 5px color-mix(in srgb, var(--body-background) 90%, transparent)"},chatInput:{color:"var(--color-grey-700)",background:"var(--card-background)",borderRadius:"var(--base-border-radius)",borderColor:"transparent",borderWidth:"3px",hover:{background:"var(--card-hover-background)"},focus:{borderColor:"var(--body-focus-color)"}},chatInputSubmit:{color:"var(--btn-primary-color)",background:"var(--btn-primary-background)",borderRadius:"calc(var(--base-border-radius) / 1.25)",hover:{color:"var(--btn-primary-hover-color)",background:"var(--btn-primary-hover-background)"},custom:{strokeWidth:"2",deactivatedBackground:"var(--color-grey-500)",deactivatedOpacity:"0.25",deactivatedScale:"0.8",deactivatedBorderColor:"var(--color-grey-500)"}},chatInputNotification:{background:"#dd1313",color:"var(--color-grey-0)",borderColor:"#dd1313",borderWidth:"1px",borderRadius:"calc(var(--base-border-radius) / 2)"},dialog:{background:"var(--card-background)",color:"var(--body-color)",borderColor:"var(--card-border-color)",borderWidth:"var(--card-border-width)",borderRadius:"var(--card-border-radius)",boxShadow:"var(--base-box-shadow)",custom:{transitionDuration:200,transitionDelay:0,transitionY:30,backgroundOverlay:"rgba(0, 0, 0, 0.25)",headerBorderBottomColor:"var(--base-line-color)"}},aside:{background:"var(--card-background)",custom:{width:"400px",containerWidthForMobileLayout:1024,backgroundOverlay:"rgba(0, 0, 0, 0.4)",headerColor:"var(--card-color)",headerBorderColor:"var(--base-line-color)",headerBorderWidth:"1px"}},message:{color:"var(--body-color)",custom:{errorColor:"#C91658",transitionDuration:300,transitionDelay:0,transitionY:30,transitionBotLoadingDelay:300}},messageOptions:{borderColor:"var(--base-line-color)",borderWidth:"1px",custom:{transitionDuration:300,transitionDelay:0,transitionY:30}},messageUser:{color:"var(--body-color)",background:"var(--card-background)",boxShadow:"var(--card-box-shadow)",borderRadius:"var(--card-border-radius)"},openButton:{color:"var(--card-color)",background:"var(--card-background)",borderColor:"var(--card-background)",borderWidth:"0",borderRadius:"calc(var(--base-border-radius) / 2)",hover:{color:"var(--card-hover-color)",background:"var(--card-hover-background)"}},referencesToggle:{color:"var(--anchor-color)",hover:{color:"var(--anchor-hover-color)"}},referenceNumberTrigger:{color:"var(--btn-secondary-color)",background:"var(--btn-secondary-background)",borderRadius:"calc(var(--base-border-radius) / 2)",hover:{color:"var(--btn-secondary-hover-color)",background:"var(--btn-secondary-hover-background)"},custom:{padding:"0.25em"}},referenceDomain:{color:"var(--anchor-color)",hover:{color:"var(--anchor-hover-color)"},custom:{padding:"0px"}},referenceNumberContent:{color:"var(--card-color)",background:"var(--card-background)",borderColor:"var(--card-border-color)",borderWidth:"var(--card-border-width)",borderRadius:"var(--card-border-radius)",hover:{color:"var(--card-hover-color)",background:"var(--card-hover-background)",borderColor:"var(--card-hover-border-color)",borderWidth:"var(--card-hover-border-width)"},boxShadow:"var(--base-box-shadow)",custom:{width:"95cqi",maxWidth:"450px",transitionDuration:200,transitionDelay:200,transitionY:8}},reference:{color:"var(--card-color)",background:"var(--card-background)",borderColor:"var(--card-border-color)",borderWidth:"var(--card-border-width)",borderRadius:"var(--card-border-radius)",hover:{color:"var(--card-hover-color)",background:"var(--body-background)",borderColor:"var(--card-hover-border-color)",borderWidth:"var(--card-hover-border-width)"}},referenceDescription:{color:"var(--reference-color)",hover:{color:"var(--reference-hover-color)"}},referenceNumber:{color:"var(--reference-number-trigger-color)",background:"var(--body-background)",borderColor:"var(--reference-number-trigger-border-color)",borderWidth:"var(--reference-number-trigger-border-width)",borderRadius:"var(--reference-number-trigger-border-radius)",hover:{color:"var(--reference-number-trigger-color)",background:"var(--reference-number-trigger-background)",borderColor:"var(--reference-number-trigger-border-color)",borderWidth:"var(--reference-number-trigger-border-width)"},custom:{padding:"var(--reference-number-trigger-padding)"}},toast:{background:"var(--card-background)",color:"var(--body-color)",boxShadow:"var(--base-box-shadow)",borderRadius:"var(--card-border-radius)",custom:{iconSuccessColor:"#22c55e",iconErrorColor:"#ef4444",iconWarningColor:"#f97316",iconInfoColor:"#3b82f6"}},tooltip:{background:"var(--color-grey-200)",color:"var(--body-color)",borderRadius:"calc(var(--base-border-radius) / 2)"}},svgs:{predefinedQuestion:`
|
|
1
|
+
const Wr="https://liipgpt.api.dev.genai.liip.ch/liipgpt",Fr="3.1.1";function Xe(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var se,we;function Qe(){if(we)return se;we=1;var t=function(k){return e(k)&&!r(k)};function e(v){return!!v&&typeof v=="object"}function r(v){var k=Object.prototype.toString.call(v);return k==="[object RegExp]"||k==="[object Date]"||o(v)}var a=typeof Symbol=="function"&&Symbol.for,n=a?Symbol.for("react.element"):60103;function o(v){return v.$$typeof===n}function s(v){return Array.isArray(v)?[]:{}}function i(v,k){return k.clone!==!1&&k.isMergeableObject(v)?D(s(v),v,k):v}function f(v,k,w){return v.concat(k).map(function(M){return i(M,w)})}function p(v,k){if(!k.customMerge)return D;var w=k.customMerge(v);return typeof w=="function"?w:D}function _(v){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(v).filter(function(k){return Object.propertyIsEnumerable.call(v,k)}):[]}function E(v){return Object.keys(v).concat(_(v))}function J(v,k){try{return k in v}catch{return!1}}function Ge(v,k){return J(v,k)&&!(Object.hasOwnProperty.call(v,k)&&Object.propertyIsEnumerable.call(v,k))}function qe(v,k,w){var M={};return w.isMergeableObject(v)&&E(v).forEach(function(j){M[j]=i(v[j],w)}),E(k).forEach(function(j){Ge(v,j)||(J(v,j)&&w.isMergeableObject(k[j])?M[j]=p(j,w)(v[j],k[j],w):M[j]=i(k[j],w))}),M}function D(v,k,w){w=w||{},w.arrayMerge=w.arrayMerge||f,w.isMergeableObject=w.isMergeableObject||t,w.cloneUnlessOtherwiseSpecified=i;var M=Array.isArray(k),j=Array.isArray(v),Je=M===j;return Je?M?w.arrayMerge(v,k,w):qe(v,k,w):i(k,w)}D.all=function(k,w){if(!Array.isArray(k))throw new Error("first argument should be an array");return k.reduce(function(M,j){return D(M,j,w)},{})};var Ye=D;return se=Ye,se}var Ke=Qe();const er=Xe(Ke),rr=t=>t===null||typeof t!="object",ce=t=>{if(rr(t))return t;if(Array.isArray(t))return t.map(ce);const e=Object.entries(t).filter(([r,a])=>a!==void 0).map(([r,a])=>[r,ce(a)]);return Object.fromEntries(e)},tr=(t,e)=>{const r=ce(e);return er(t,r)},$e={tokens:{font:{family:"-apple-system, BlinkMacSystemFont, avenir next, avenir, segoe ui, helvetica neue, helvetica, Cantarell, Ubuntu, roboto, noto, arial, sans-serif"},colors:{brand:{50:"#f9fafb",100:"#f3f4f6",200:"#e5e7eb",300:"#d1d5db",400:"#9ca3af",500:"#6b7280",600:"#4b5563",700:"#374151",800:"#2d3748",900:"#1a202c",950:"#171923"},highlight:{50:"#f9fafb",100:"#f3f4f6",200:"#e5e7eb",300:"#d1d5db",400:"#9ca3af",500:"#6b7280",600:"#4b5563",700:"#374151",800:"#2d3748",900:"#1a202c",950:"#171923"},grey:{0:"#ffffff",50:"#f9fafb",100:"#f3f4f6",200:"#e5e7eb",300:"#d1d5db",400:"#9ca3af",500:"#6b7280",600:"#4b5563",700:"#374151",800:"#2d3748",900:"#1a202c",950:"#171923",1e3:"#000000"}},base:{fontSizeXs:{minRem:.75,maxRem:.875},fontSizeSm:{minRem:1,maxRem:1},fontSizeBody:{minRem:1,maxRem:1.25},fontSizeH3:{minRem:1.125,maxRem:1.5},fontSizeH2:{minRem:1.25,maxRem:1.75},fontSizeH1:{minRem:1.5,maxRem:2},fontWeightNormal:"400",fontWeightBold:"700",fontWeightTitle:"700",lineHeightDefault:"1.5",lineHeightSnug:"1.375",lineHeightTight:"1.25",borderRadius:{minRem:.5,maxRem:.75},lineColor:"color-mix(in srgb, var(--color-brand-950) 20%, transparent)",boxShadow:"0px 0px 2px rgba(0, 0, 0, 0.15), 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1)"},components:{body:{background:"var(--color-grey-0)",color:"var(--color-grey-900)",focus:{color:"var(--color-highlight-500)"},custom:{selectionColor:"var(--color-grey-0)",selectionBackground:"var(--color-brand-700)",focusWidth:"var(--spacer-3)",focusOffset:"var(--spacer-2)",focusStyle:"solid"}},container:{custom:{maxWidth:"1024px"}},avatar:{color:"var(--color-brand-400)",background:"var(--color-grey-100)"},anchor:{color:"var(--color-brand-600)",hover:{color:"var(--color-brand-950)"}},btnPrimary:{color:"var(--color-grey-0)",background:"var(--color-brand-700)",borderRadius:"var(--base-border-radius)",hover:{background:"var(--color-brand-900)"}},btnSecondary:{color:"var(--color-brand-700)",background:"var(--color-brand-100)",borderRadius:"var(--base-border-radius)",hover:{color:"var(--color-grey-1000)",background:"var(--color-brand-200)"}},btnTertiary:{color:"var(--anchor-color)",background:"transparent",borderRadius:"var(--base-border-radius)",hover:{color:"var(--anchor-hover-color)"}},card:{color:"var(--color-grey-900)",background:"var(--color-grey-100)",borderRadius:"var(--base-border-radius)",boxShadow:"none",hover:{color:"var(--color-grey-1000)",background:"var(--color-brand-100)"},custom:{iconColor:"var(--anchor-color)",iconHoverColor:"var(--anchor-hover-color)"}},input:{background:"var(--color-grey-0)",borderColor:"var(--color-grey-300)",borderWidth:"1px",borderRadius:"var(--base-border-radius)",custom:{padding:"var(--spacer-r-16) var(--spacer-r-20)",placeholderColor:"var(--color-grey-500)",placeholderOpacity:"1"}},label:{color:"var(--color-grey-600)"},hr:{color:"var(--base-line-color)"},checkbox:{color:"transparent",background:"var(--color-grey-0)",borderColor:"var(--color-grey-300)",borderWidth:"1px",borderRadius:"0.2em",custom:{checkedColor:"var(--btn-primary-color)",checkedBorderColor:"var(--color-brand-700)",checkedBackground:"var(--color-brand-700)"}},radio:{color:"transparent",background:"var(--color-grey-0)",borderColor:"var(--color-grey-300)",borderWidth:"1px",custom:{checkedColor:"var(--btn-primary-color)",checkedBorderColor:"var(--color-brand-700)",checkedBackground:"var(--color-brand-700)"}},contextBox:{color:"var(--card-color)",background:"var(--card-background)",borderColor:"var(--card-border-color)",borderWidth:"var(--card-border-width)",borderRadius:"var(--card-border-radius)",boxShadow:"var(--base-box-shadow)",custom:{transitionDuration:200,transitionDelay:200,transitionY:8,titleColor:"var(--color-grey-1000)",titleFontWeight:"var(--base-font-weight-bold)",separatorColor:"var(--base-line-color)",errorColor:"var(--message-error-color)"}},contextBoxMenuItem:{background:"transparent",color:"var(--body-color)",borderRadius:"calc(var(--base-border-radius) / 2)",hover:{color:"var(--btn-secondary-hover-color)",background:"var(--btn-secondary-hover-background)"},custom:{activeColor:"var(--btn-secondary-hover-color)",activeBackground:"var(--btn-secondary-hover-background)"}},chatFooter:{color:"var(--color-grey-400)",background:"var(--body-background)",borderRadius:"var(--base-border-radius)",boxShadow:"0px -10px 20px 5px color-mix(in srgb, var(--body-background) 90%, transparent)"},chatInput:{color:"var(--color-grey-700)",background:"var(--card-background)",borderRadius:"var(--base-border-radius)",borderColor:"transparent",borderWidth:"3px",hover:{background:"var(--card-hover-background)"},focus:{borderColor:"var(--body-focus-color)"}},chatInputSubmit:{color:"var(--btn-primary-color)",background:"var(--btn-primary-background)",borderRadius:"calc(var(--base-border-radius) / 1.25)",hover:{color:"var(--btn-primary-hover-color)",background:"var(--btn-primary-hover-background)"},custom:{strokeWidth:"2",deactivatedBackground:"var(--color-grey-500)",deactivatedOpacity:"0.25",deactivatedScale:"0.8",deactivatedBorderColor:"var(--color-grey-500)"}},chatInputNotification:{background:"#dd1313",color:"var(--color-grey-0)",borderColor:"#dd1313",borderWidth:"1px",borderRadius:"calc(var(--base-border-radius) / 2)"},dialog:{background:"var(--card-background)",color:"var(--body-color)",borderColor:"var(--card-border-color)",borderWidth:"var(--card-border-width)",borderRadius:"var(--card-border-radius)",boxShadow:"var(--base-box-shadow)",custom:{transitionDuration:200,transitionDelay:0,transitionY:30,backgroundOverlay:"rgba(0, 0, 0, 0.25)",headerBorderBottomColor:"var(--base-line-color)"}},aside:{background:"var(--card-background)",custom:{width:"400px",containerWidthForMobileLayout:1024,backgroundOverlay:"rgba(0, 0, 0, 0.4)",headerColor:"var(--card-color)",headerBorderColor:"var(--base-line-color)",headerBorderWidth:"1px"}},message:{color:"var(--body-color)",custom:{errorColor:"#C91658",transitionDuration:300,transitionDelay:0,transitionY:30,transitionBotLoadingDelay:300}},messageOptions:{borderColor:"var(--base-line-color)",borderWidth:"1px",custom:{transitionDuration:300,transitionDelay:0,transitionY:30}},messageUser:{color:"var(--body-color)",background:"var(--card-background)",boxShadow:"var(--card-box-shadow)",borderRadius:"var(--card-border-radius)"},openButton:{color:"var(--card-color)",background:"var(--card-background)",borderColor:"var(--card-background)",borderWidth:"0",borderRadius:"calc(var(--base-border-radius) / 2)",hover:{color:"var(--card-hover-color)",background:"var(--card-hover-background)"}},referencesToggle:{color:"var(--color-brand-700)",hover:{color:"var(--anchor-hover-color)"}},referenceNumberTrigger:{color:"var(--btn-secondary-color)",background:"var(--btn-secondary-background)",borderRadius:"calc(var(--base-border-radius) / 2)",hover:{color:"var(--btn-secondary-hover-color)",background:"var(--btn-secondary-hover-background)"},custom:{padding:"0.25em"}},referenceDomain:{color:"var(--color-brand-700)",hover:{color:"var(--color-brand-800)"},custom:{padding:"0px"}},referenceNumberContent:{color:"var(--card-color)",background:"var(--card-background)",borderColor:"var(--card-border-color)",borderWidth:"var(--card-border-width)",borderRadius:"var(--card-border-radius)",hover:{color:"var(--card-hover-color)",background:"var(--card-hover-background)",borderColor:"var(--card-hover-border-color)",borderWidth:"var(--card-hover-border-width)"},boxShadow:"var(--base-box-shadow)",custom:{width:"95cqi",maxWidth:"450px",transitionDuration:200,transitionDelay:200,transitionY:8}},reference:{color:"var(--card-color)",background:"var(--card-background)",borderColor:"var(--card-border-color)",borderWidth:"var(--card-border-width)",borderRadius:"var(--card-border-radius)",hover:{color:"var(--card-hover-color)",background:"var(--body-background)",borderColor:"var(--card-hover-border-color)",borderWidth:"var(--card-hover-border-width)"}},referenceDescription:{color:"var(--reference-color)",hover:{color:"var(--reference-hover-color)"}},referenceNumber:{color:"var(--reference-number-trigger-color)",background:"var(--body-background)",borderColor:"var(--reference-number-trigger-border-color)",borderWidth:"var(--reference-number-trigger-border-width)",borderRadius:"var(--reference-number-trigger-border-radius)",hover:{color:"var(--reference-number-trigger-color)",background:"var(--reference-number-trigger-background)",borderColor:"var(--reference-number-trigger-border-color)",borderWidth:"var(--reference-number-trigger-border-width)"},custom:{padding:"var(--reference-number-trigger-padding)"}},toast:{background:"var(--card-background)",color:"var(--body-color)",boxShadow:"var(--base-box-shadow)",borderRadius:"var(--card-border-radius)",custom:{iconSuccessColor:"#22c55e",iconErrorColor:"#ef4444",iconWarningColor:"#f97316",iconInfoColor:"#3b82f6"}},tooltip:{background:"var(--color-grey-200)",color:"var(--body-color)",borderRadius:"calc(var(--base-border-radius) / 2)"}},svgs:{predefinedQuestion:`
|
|
2
2
|
<svg viewBox="0 0 24 24" >
|
|
3
3
|
<path d="M11 3.5A10.5 10.5 0 0 0 0.5 14v1.5" fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path>
|
|
4
4
|
<path d="M0.5 15.498a5 5 0 1 0 10 0 5 5 0 1 0 -10 0" fill="currentColor" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path>
|
|
@@ -266,4 +266,4 @@ const Wr="https://liipgpt.api.dev.genai.liip.ch/liipgpt",Fr="3.0.6";function Xe(
|
|
|
266
266
|
<svg viewBox="0 0 24 24" fill="none">
|
|
267
267
|
<path d="M18 6L10 16L5 11" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
|
268
268
|
</svg>
|
|
269
|
-
`}}},ar=tr($e,{tokens:{base:{lineColor:"color-mix(in srgb, var(--color-brand-100) 20%, transparent)"},components:{body:{background:"var(--color-grey-900)",color:"var(--color-grey-100)",focus:{color:"var(--color-highlight-400)"},custom:{selectionColor:"var(--color-grey-1000)",selectionBackground:"var(--color-brand-400)"}},avatar:{color:"var(--color-brand-200)",background:"var(--color-grey-800)"},anchor:{color:"var(--color-brand-300)",hover:{color:"var(--color-brand-50)"}},btnPrimary:{color:"var(--color-grey-1000)",background:"var(--color-brand-300)",hover:{background:"var(--color-brand-100)"}},btnSecondary:{color:"var(--color-brand-100)",background:"var(--color-brand-900)",hover:{color:"var(--color-grey-0)",background:"var(--color-brand-800)"}},btnTertiary:{color:"var(--anchor-color)",background:"transparent",borderRadius:"var(--base-border-radius)",hover:{color:"var(--anchor-hover-color)"}},card:{color:"var(--body-color)",background:"var(--color-grey-800)",hover:{color:"var(--color-grey-0)",background:"var(--color-brand-900)"}},input:{background:"var(--color-grey-900)",borderColor:"var(--color-grey-700)",custom:{placeholderColor:"var(--color-grey-400)"}},label:{color:"var(--color-grey-50)"},contextBox:{custom:{titleColor:"var(--color-grey-50)"}},referenceDescription:{color:"var(--color-grey-300)",hover:{color:"var(--color-grey-300)"}},chatFooter:{color:"var(--color-grey-500)"},chatInput:{color:"var(--color-grey-100)"},chatInputSubmit:{custom:{deactivatedBackground:"var(--color-grey-400)",deactivatedBorderColor:"var(--color-grey-400)"}},dialog:{custom:{backgroundOverlay:"rgba(0, 0, 0, 0.5)"}},tooltip:{background:"var(--color-grey-1000)"}}}}),oe={fineGrained:{light:$e,dark:ar}},nr=Object.freeze(Object.defineProperty({__proto__:null,theme:oe},Symbol.toStringTag,{value:"Module"})),ye=structuredClone(oe.fineGrained.light);ye.tokens.colors={brand:{50:"#f0f9ff",100:"#e0f2fe",200:"#bae6fd",300:"#7dd3fc",400:"#38bdf8",500:"#0ea5e9",600:"#0284c7",700:"#0369a1",800:"#075985",900:"#0c4a6e",950:"#082f49"},highlight:{50:"#f5f3ff",100:"#ede9fe",200:"#ddd6fe",300:"#c4b5fd",400:"#a78bfa",500:"#8b5cf6",600:"#7c3aed",700:"#6d28d9",800:"#5b21b6",900:"#4c1d95",950:"#2e1065"},grey:{0:"#ffffff",50:"#f9fafb",100:"#f3f4f6",200:"#e5e7eb",300:"#d1d5db",400:"#9ca3af",500:"#6b7280",600:"#4b5563",700:"#374151",800:"#2d3748",900:"#1a202c",950:"#171923",1e3:"#000000"}};const De=structuredClone(oe.fineGrained.dark);De.tokens.colors=ye.tokens.colors;const or={fineGrained:{light:ye,dark:De}},sr=Object.freeze(Object.defineProperty({__proto__:null,theme:or},Symbol.toStringTag,{value:"Module"}));var x;(function(t){t.assertEqual=n=>{};function e(n){}t.assertIs=e;function r(n){throw new Error}t.assertNever=r,t.arrayToEnum=n=>{const o={};for(const s of n)o[s]=s;return o},t.getValidEnumValues=n=>{const o=t.objectKeys(n).filter(i=>typeof n[n[i]]!="number"),s={};for(const i of o)s[i]=n[i];return t.objectValues(s)},t.objectValues=n=>t.objectKeys(n).map(function(o){return n[o]}),t.objectKeys=typeof Object.keys=="function"?n=>Object.keys(n):n=>{const o=[];for(const s in n)Object.prototype.hasOwnProperty.call(n,s)&&o.push(s);return o},t.find=(n,o)=>{for(const s of n)if(o(s))return s},t.isInteger=typeof Number.isInteger=="function"?n=>Number.isInteger(n):n=>typeof n=="number"&&Number.isFinite(n)&&Math.floor(n)===n;function a(n,o=" | "){return n.map(s=>typeof s=="string"?`'${s}'`:s).join(o)}t.joinValues=a,t.jsonStringifyReplacer=(n,o)=>typeof o=="bigint"?o.toString():o})(x||(x={}));var Ce;(function(t){t.mergeShapes=(e,r)=>({...e,...r})})(Ce||(Ce={}));const l=x.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),B=t=>{switch(typeof t){case"undefined":return l.undefined;case"string":return l.string;case"number":return Number.isNaN(t)?l.nan:l.number;case"boolean":return l.boolean;case"function":return l.function;case"bigint":return l.bigint;case"symbol":return l.symbol;case"object":return Array.isArray(t)?l.array:t===null?l.null:t.then&&typeof t.then=="function"&&t.catch&&typeof t.catch=="function"?l.promise:typeof Map<"u"&&t instanceof Map?l.map:typeof Set<"u"&&t instanceof Set?l.set:typeof Date<"u"&&t instanceof Date?l.date:l.object;default:return l.unknown}},d=x.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]);class I extends Error{get errors(){return this.issues}constructor(e){super(),this.issues=[],this.addIssue=a=>{this.issues=[...this.issues,a]},this.addIssues=(a=[])=>{this.issues=[...this.issues,...a]};const r=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,r):this.__proto__=r,this.name="ZodError",this.issues=e}format(e){const r=e||function(o){return o.message},a={_errors:[]},n=o=>{for(const s of o.issues)if(s.code==="invalid_union")s.unionErrors.map(n);else if(s.code==="invalid_return_type")n(s.returnTypeError);else if(s.code==="invalid_arguments")n(s.argumentsError);else if(s.path.length===0)a._errors.push(r(s));else{let i=a,f=0;for(;f<s.path.length;){const p=s.path[f];f===s.path.length-1?(i[p]=i[p]||{_errors:[]},i[p]._errors.push(r(s))):i[p]=i[p]||{_errors:[]},i=i[p],f++}}};return n(this),a}static assert(e){if(!(e instanceof I))throw new Error(`Not a ZodError: ${e}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,x.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(e=r=>r.message){const r={},a=[];for(const n of this.issues)if(n.path.length>0){const o=n.path[0];r[o]=r[o]||[],r[o].push(e(n))}else a.push(e(n));return{formErrors:a,fieldErrors:r}}get formErrors(){return this.flatten()}}I.create=t=>new I(t);const le=(t,e)=>{let r;switch(t.code){case d.invalid_type:t.received===l.undefined?r="Required":r=`Expected ${t.expected}, received ${t.received}`;break;case d.invalid_literal:r=`Invalid literal value, expected ${JSON.stringify(t.expected,x.jsonStringifyReplacer)}`;break;case d.unrecognized_keys:r=`Unrecognized key(s) in object: ${x.joinValues(t.keys,", ")}`;break;case d.invalid_union:r="Invalid input";break;case d.invalid_union_discriminator:r=`Invalid discriminator value. Expected ${x.joinValues(t.options)}`;break;case d.invalid_enum_value:r=`Invalid enum value. Expected ${x.joinValues(t.options)}, received '${t.received}'`;break;case d.invalid_arguments:r="Invalid function arguments";break;case d.invalid_return_type:r="Invalid function return type";break;case d.invalid_date:r="Invalid date";break;case d.invalid_string:typeof t.validation=="object"?"includes"in t.validation?(r=`Invalid input: must include "${t.validation.includes}"`,typeof t.validation.position=="number"&&(r=`${r} at one or more positions greater than or equal to ${t.validation.position}`)):"startsWith"in t.validation?r=`Invalid input: must start with "${t.validation.startsWith}"`:"endsWith"in t.validation?r=`Invalid input: must end with "${t.validation.endsWith}"`:x.assertNever(t.validation):t.validation!=="regex"?r=`Invalid ${t.validation}`:r="Invalid";break;case d.too_small:t.type==="array"?r=`Array must contain ${t.exact?"exactly":t.inclusive?"at least":"more than"} ${t.minimum} element(s)`:t.type==="string"?r=`String must contain ${t.exact?"exactly":t.inclusive?"at least":"over"} ${t.minimum} character(s)`:t.type==="number"?r=`Number must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${t.minimum}`:t.type==="bigint"?r=`Number must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${t.minimum}`:t.type==="date"?r=`Date must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(t.minimum))}`:r="Invalid input";break;case d.too_big:t.type==="array"?r=`Array must contain ${t.exact?"exactly":t.inclusive?"at most":"less than"} ${t.maximum} element(s)`:t.type==="string"?r=`String must contain ${t.exact?"exactly":t.inclusive?"at most":"under"} ${t.maximum} character(s)`:t.type==="number"?r=`Number must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`:t.type==="bigint"?r=`BigInt must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`:t.type==="date"?r=`Date must be ${t.exact?"exactly":t.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(t.maximum))}`:r="Invalid input";break;case d.custom:r="Invalid input";break;case d.invalid_intersection_types:r="Intersection results could not be merged";break;case d.not_multiple_of:r=`Number must be a multiple of ${t.multipleOf}`;break;case d.not_finite:r="Number must be finite";break;default:r=e.defaultError,x.assertNever(t)}return{message:r}};let ir=le;function dr(){return ir}const cr=t=>{const{data:e,path:r,errorMaps:a,issueData:n}=t,o=[...r,...n.path||[]],s={...n,path:o};if(n.message!==void 0)return{...n,path:o,message:n.message};let i="";const f=a.filter(p=>!!p).slice().reverse();for(const p of f)i=p(s,{data:e,defaultError:i}).message;return{...n,path:o,message:i}};function c(t,e){const r=dr(),a=cr({issueData:e,data:t.data,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,r,r===le?void 0:le].filter(n=>!!n)});t.common.issues.push(a)}class O{constructor(){this.value="valid"}dirty(){this.value==="valid"&&(this.value="dirty")}abort(){this.value!=="aborted"&&(this.value="aborted")}static mergeArray(e,r){const a=[];for(const n of r){if(n.status==="aborted")return g;n.status==="dirty"&&e.dirty(),a.push(n.value)}return{status:e.value,value:a}}static async mergeObjectAsync(e,r){const a=[];for(const n of r){const o=await n.key,s=await n.value;a.push({key:o,value:s})}return O.mergeObjectSync(e,a)}static mergeObjectSync(e,r){const a={};for(const n of r){const{key:o,value:s}=n;if(o.status==="aborted"||s.status==="aborted")return g;o.status==="dirty"&&e.dirty(),s.status==="dirty"&&e.dirty(),o.value!=="__proto__"&&(typeof s.value<"u"||n.alwaysSet)&&(a[o.value]=s.value)}return{status:e.value,value:a}}}const g=Object.freeze({status:"aborted"}),G=t=>({status:"dirty",value:t}),R=t=>({status:"valid",value:t}),Se=t=>t.status==="aborted",je=t=>t.status==="dirty",V=t=>t.status==="valid",Q=t=>typeof Promise<"u"&&t instanceof Promise;var u;(function(t){t.errToObj=e=>typeof e=="string"?{message:e}:e||{},t.toString=e=>typeof e=="string"?e:e?.message})(u||(u={}));class N{constructor(e,r,a,n){this._cachedPath=[],this.parent=e,this.data=r,this._path=a,this._key=n}get path(){return this._cachedPath.length||(Array.isArray(this._key)?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}}const Te=(t,e)=>{if(V(e))return{success:!0,data:e.value};if(!t.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;const r=new I(t.common.issues);return this._error=r,this._error}}};function y(t){if(!t)return{};const{errorMap:e,invalid_type_error:r,required_error:a,description:n}=t;if(e&&(r||a))throw new Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);return e?{errorMap:e,description:n}:{errorMap:(s,i)=>{const{message:f}=t;return s.code==="invalid_enum_value"?{message:f??i.defaultError}:typeof i.data>"u"?{message:f??a??i.defaultError}:s.code!=="invalid_type"?{message:i.defaultError}:{message:f??r??i.defaultError}},description:n}}class b{get description(){return this._def.description}_getType(e){return B(e.data)}_getOrReturnCtx(e,r){return r||{common:e.parent.common,data:e.data,parsedType:B(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}_processInputParams(e){return{status:new O,ctx:{common:e.parent.common,data:e.data,parsedType:B(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}}_parseSync(e){const r=this._parse(e);if(Q(r))throw new Error("Synchronous parse encountered promise.");return r}_parseAsync(e){const r=this._parse(e);return Promise.resolve(r)}parse(e,r){const a=this.safeParse(e,r);if(a.success)return a.data;throw a.error}safeParse(e,r){const a={common:{issues:[],async:r?.async??!1,contextualErrorMap:r?.errorMap},path:r?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:B(e)},n=this._parseSync({data:e,path:a.path,parent:a});return Te(a,n)}"~validate"(e){const r={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:B(e)};if(!this["~standard"].async)try{const a=this._parseSync({data:e,path:[],parent:r});return V(a)?{value:a.value}:{issues:r.common.issues}}catch(a){a?.message?.toLowerCase()?.includes("encountered")&&(this["~standard"].async=!0),r.common={issues:[],async:!0}}return this._parseAsync({data:e,path:[],parent:r}).then(a=>V(a)?{value:a.value}:{issues:r.common.issues})}async parseAsync(e,r){const a=await this.safeParseAsync(e,r);if(a.success)return a.data;throw a.error}async safeParseAsync(e,r){const a={common:{issues:[],contextualErrorMap:r?.errorMap,async:!0},path:r?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:B(e)},n=this._parse({data:e,path:a.path,parent:a}),o=await(Q(n)?n:Promise.resolve(n));return Te(a,o)}refine(e,r){const a=n=>typeof r=="string"||typeof r>"u"?{message:r}:typeof r=="function"?r(n):r;return this._refinement((n,o)=>{const s=e(n),i=()=>o.addIssue({code:d.custom,...a(n)});return typeof Promise<"u"&&s instanceof Promise?s.then(f=>f?!0:(i(),!1)):s?!0:(i(),!1)})}refinement(e,r){return this._refinement((a,n)=>e(a)?!0:(n.addIssue(typeof r=="function"?r(a,n):r),!1))}_refinement(e){return new F({schema:this,typeName:m.ZodEffects,effect:{type:"refinement",refinement:e}})}superRefine(e){return this._refinement(e)}constructor(e){this.spa=this.safeParseAsync,this._def=e,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this),this["~standard"]={version:1,vendor:"zod",validate:r=>this["~validate"](r)}}optional(){return z.create(this,this._def)}nullable(){return H.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return A.create(this)}promise(){return ae.create(this,this._def)}or(e){return ee.create([this,e],this._def)}and(e){return re.create(this,e,this._def)}transform(e){return new F({...y(this._def),schema:this,typeName:m.ZodEffects,effect:{type:"transform",transform:e}})}default(e){const r=typeof e=="function"?e:()=>e;return new pe({...y(this._def),innerType:this,defaultValue:r,typeName:m.ZodDefault})}brand(){return new Nr({typeName:m.ZodBranded,type:this,...y(this._def)})}catch(e){const r=typeof e=="function"?e:()=>e;return new me({...y(this._def),innerType:this,catchValue:r,typeName:m.ZodCatch})}describe(e){const r=this.constructor;return new r({...this._def,description:e})}pipe(e){return ke.create(this,e)}readonly(){return ge.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}const lr=/^c[^\s-]{8,}$/i,ur=/^[0-9a-z]+$/,hr=/^[0-9A-HJKMNP-TV-Z]{26}$/i,fr=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,pr=/^[a-z0-9_-]{21}$/i,mr=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,gr=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,vr=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,yr="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";let ie;const kr=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,br=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/(3[0-2]|[12]?[0-9])$/,_r=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))$/,xr=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,wr=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,Cr=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,Pe="((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",Sr=new RegExp(`^${Pe}$`);function Ve(t){let e="[0-5]\\d";t.precision?e=`${e}\\.\\d{${t.precision}}`:t.precision==null&&(e=`${e}(\\.\\d+)?`);const r=t.precision?"+":"?";return`([01]\\d|2[0-3]):[0-5]\\d(:${e})${r}`}function jr(t){return new RegExp(`^${Ve(t)}$`)}function Tr(t){let e=`${Pe}T${Ve(t)}`;const r=[];return r.push(t.local?"Z?":"Z"),t.offset&&r.push("([+-]\\d{2}:?\\d{2})"),e=`${e}(${r.join("|")})`,new RegExp(`^${e}$`)}function Or(t,e){return!!((e==="v4"||!e)&&kr.test(t)||(e==="v6"||!e)&&_r.test(t))}function Rr(t,e){if(!mr.test(t))return!1;try{const[r]=t.split(".");if(!r)return!1;const a=r.replace(/-/g,"+").replace(/_/g,"/").padEnd(r.length+(4-r.length%4)%4,"="),n=JSON.parse(atob(a));return!(typeof n!="object"||n===null||"typ"in n&&n?.typ!=="JWT"||!n.alg||e&&n.alg!==e)}catch{return!1}}function Mr(t,e){return!!((e==="v4"||!e)&&br.test(t)||(e==="v6"||!e)&&xr.test(t))}class Z extends b{_parse(e){if(this._def.coerce&&(e.data=String(e.data)),this._getType(e)!==l.string){const o=this._getOrReturnCtx(e);return c(o,{code:d.invalid_type,expected:l.string,received:o.parsedType}),g}const a=new O;let n;for(const o of this._def.checks)if(o.kind==="min")e.data.length<o.value&&(n=this._getOrReturnCtx(e,n),c(n,{code:d.too_small,minimum:o.value,type:"string",inclusive:!0,exact:!1,message:o.message}),a.dirty());else if(o.kind==="max")e.data.length>o.value&&(n=this._getOrReturnCtx(e,n),c(n,{code:d.too_big,maximum:o.value,type:"string",inclusive:!0,exact:!1,message:o.message}),a.dirty());else if(o.kind==="length"){const s=e.data.length>o.value,i=e.data.length<o.value;(s||i)&&(n=this._getOrReturnCtx(e,n),s?c(n,{code:d.too_big,maximum:o.value,type:"string",inclusive:!0,exact:!0,message:o.message}):i&&c(n,{code:d.too_small,minimum:o.value,type:"string",inclusive:!0,exact:!0,message:o.message}),a.dirty())}else if(o.kind==="email")vr.test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"email",code:d.invalid_string,message:o.message}),a.dirty());else if(o.kind==="emoji")ie||(ie=new RegExp(yr,"u")),ie.test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"emoji",code:d.invalid_string,message:o.message}),a.dirty());else if(o.kind==="uuid")fr.test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"uuid",code:d.invalid_string,message:o.message}),a.dirty());else if(o.kind==="nanoid")pr.test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"nanoid",code:d.invalid_string,message:o.message}),a.dirty());else if(o.kind==="cuid")lr.test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"cuid",code:d.invalid_string,message:o.message}),a.dirty());else if(o.kind==="cuid2")ur.test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"cuid2",code:d.invalid_string,message:o.message}),a.dirty());else if(o.kind==="ulid")hr.test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"ulid",code:d.invalid_string,message:o.message}),a.dirty());else if(o.kind==="url")try{new URL(e.data)}catch{n=this._getOrReturnCtx(e,n),c(n,{validation:"url",code:d.invalid_string,message:o.message}),a.dirty()}else o.kind==="regex"?(o.regex.lastIndex=0,o.regex.test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"regex",code:d.invalid_string,message:o.message}),a.dirty())):o.kind==="trim"?e.data=e.data.trim():o.kind==="includes"?e.data.includes(o.value,o.position)||(n=this._getOrReturnCtx(e,n),c(n,{code:d.invalid_string,validation:{includes:o.value,position:o.position},message:o.message}),a.dirty()):o.kind==="toLowerCase"?e.data=e.data.toLowerCase():o.kind==="toUpperCase"?e.data=e.data.toUpperCase():o.kind==="startsWith"?e.data.startsWith(o.value)||(n=this._getOrReturnCtx(e,n),c(n,{code:d.invalid_string,validation:{startsWith:o.value},message:o.message}),a.dirty()):o.kind==="endsWith"?e.data.endsWith(o.value)||(n=this._getOrReturnCtx(e,n),c(n,{code:d.invalid_string,validation:{endsWith:o.value},message:o.message}),a.dirty()):o.kind==="datetime"?Tr(o).test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{code:d.invalid_string,validation:"datetime",message:o.message}),a.dirty()):o.kind==="date"?Sr.test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{code:d.invalid_string,validation:"date",message:o.message}),a.dirty()):o.kind==="time"?jr(o).test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{code:d.invalid_string,validation:"time",message:o.message}),a.dirty()):o.kind==="duration"?gr.test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"duration",code:d.invalid_string,message:o.message}),a.dirty()):o.kind==="ip"?Or(e.data,o.version)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"ip",code:d.invalid_string,message:o.message}),a.dirty()):o.kind==="jwt"?Rr(e.data,o.alg)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"jwt",code:d.invalid_string,message:o.message}),a.dirty()):o.kind==="cidr"?Mr(e.data,o.version)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"cidr",code:d.invalid_string,message:o.message}),a.dirty()):o.kind==="base64"?wr.test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"base64",code:d.invalid_string,message:o.message}),a.dirty()):o.kind==="base64url"?Cr.test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"base64url",code:d.invalid_string,message:o.message}),a.dirty()):x.assertNever(o);return{status:a.value,value:e.data}}_regex(e,r,a){return this.refinement(n=>e.test(n),{validation:r,code:d.invalid_string,...u.errToObj(a)})}_addCheck(e){return new Z({...this._def,checks:[...this._def.checks,e]})}email(e){return this._addCheck({kind:"email",...u.errToObj(e)})}url(e){return this._addCheck({kind:"url",...u.errToObj(e)})}emoji(e){return this._addCheck({kind:"emoji",...u.errToObj(e)})}uuid(e){return this._addCheck({kind:"uuid",...u.errToObj(e)})}nanoid(e){return this._addCheck({kind:"nanoid",...u.errToObj(e)})}cuid(e){return this._addCheck({kind:"cuid",...u.errToObj(e)})}cuid2(e){return this._addCheck({kind:"cuid2",...u.errToObj(e)})}ulid(e){return this._addCheck({kind:"ulid",...u.errToObj(e)})}base64(e){return this._addCheck({kind:"base64",...u.errToObj(e)})}base64url(e){return this._addCheck({kind:"base64url",...u.errToObj(e)})}jwt(e){return this._addCheck({kind:"jwt",...u.errToObj(e)})}ip(e){return this._addCheck({kind:"ip",...u.errToObj(e)})}cidr(e){return this._addCheck({kind:"cidr",...u.errToObj(e)})}datetime(e){return typeof e=="string"?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:e}):this._addCheck({kind:"datetime",precision:typeof e?.precision>"u"?null:e?.precision,offset:e?.offset??!1,local:e?.local??!1,...u.errToObj(e?.message)})}date(e){return this._addCheck({kind:"date",message:e})}time(e){return typeof e=="string"?this._addCheck({kind:"time",precision:null,message:e}):this._addCheck({kind:"time",precision:typeof e?.precision>"u"?null:e?.precision,...u.errToObj(e?.message)})}duration(e){return this._addCheck({kind:"duration",...u.errToObj(e)})}regex(e,r){return this._addCheck({kind:"regex",regex:e,...u.errToObj(r)})}includes(e,r){return this._addCheck({kind:"includes",value:e,position:r?.position,...u.errToObj(r?.message)})}startsWith(e,r){return this._addCheck({kind:"startsWith",value:e,...u.errToObj(r)})}endsWith(e,r){return this._addCheck({kind:"endsWith",value:e,...u.errToObj(r)})}min(e,r){return this._addCheck({kind:"min",value:e,...u.errToObj(r)})}max(e,r){return this._addCheck({kind:"max",value:e,...u.errToObj(r)})}length(e,r){return this._addCheck({kind:"length",value:e,...u.errToObj(r)})}nonempty(e){return this.min(1,u.errToObj(e))}trim(){return new Z({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new Z({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new Z({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(e=>e.kind==="datetime")}get isDate(){return!!this._def.checks.find(e=>e.kind==="date")}get isTime(){return!!this._def.checks.find(e=>e.kind==="time")}get isDuration(){return!!this._def.checks.find(e=>e.kind==="duration")}get isEmail(){return!!this._def.checks.find(e=>e.kind==="email")}get isURL(){return!!this._def.checks.find(e=>e.kind==="url")}get isEmoji(){return!!this._def.checks.find(e=>e.kind==="emoji")}get isUUID(){return!!this._def.checks.find(e=>e.kind==="uuid")}get isNANOID(){return!!this._def.checks.find(e=>e.kind==="nanoid")}get isCUID(){return!!this._def.checks.find(e=>e.kind==="cuid")}get isCUID2(){return!!this._def.checks.find(e=>e.kind==="cuid2")}get isULID(){return!!this._def.checks.find(e=>e.kind==="ulid")}get isIP(){return!!this._def.checks.find(e=>e.kind==="ip")}get isCIDR(){return!!this._def.checks.find(e=>e.kind==="cidr")}get isBase64(){return!!this._def.checks.find(e=>e.kind==="base64")}get isBase64url(){return!!this._def.checks.find(e=>e.kind==="base64url")}get minLength(){let e=null;for(const r of this._def.checks)r.kind==="min"&&(e===null||r.value>e)&&(e=r.value);return e}get maxLength(){let e=null;for(const r of this._def.checks)r.kind==="max"&&(e===null||r.value<e)&&(e=r.value);return e}}Z.create=t=>new Z({checks:[],typeName:m.ZodString,coerce:t?.coerce??!1,...y(t)});function Ar(t,e){const r=(t.toString().split(".")[1]||"").length,a=(e.toString().split(".")[1]||"").length,n=r>a?r:a,o=Number.parseInt(t.toFixed(n).replace(".","")),s=Number.parseInt(e.toFixed(n).replace(".",""));return o%s/10**n}class U extends b{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(e){if(this._def.coerce&&(e.data=Number(e.data)),this._getType(e)!==l.number){const o=this._getOrReturnCtx(e);return c(o,{code:d.invalid_type,expected:l.number,received:o.parsedType}),g}let a;const n=new O;for(const o of this._def.checks)o.kind==="int"?x.isInteger(e.data)||(a=this._getOrReturnCtx(e,a),c(a,{code:d.invalid_type,expected:"integer",received:"float",message:o.message}),n.dirty()):o.kind==="min"?(o.inclusive?e.data<o.value:e.data<=o.value)&&(a=this._getOrReturnCtx(e,a),c(a,{code:d.too_small,minimum:o.value,type:"number",inclusive:o.inclusive,exact:!1,message:o.message}),n.dirty()):o.kind==="max"?(o.inclusive?e.data>o.value:e.data>=o.value)&&(a=this._getOrReturnCtx(e,a),c(a,{code:d.too_big,maximum:o.value,type:"number",inclusive:o.inclusive,exact:!1,message:o.message}),n.dirty()):o.kind==="multipleOf"?Ar(e.data,o.value)!==0&&(a=this._getOrReturnCtx(e,a),c(a,{code:d.not_multiple_of,multipleOf:o.value,message:o.message}),n.dirty()):o.kind==="finite"?Number.isFinite(e.data)||(a=this._getOrReturnCtx(e,a),c(a,{code:d.not_finite,message:o.message}),n.dirty()):x.assertNever(o);return{status:n.value,value:e.data}}gte(e,r){return this.setLimit("min",e,!0,u.toString(r))}gt(e,r){return this.setLimit("min",e,!1,u.toString(r))}lte(e,r){return this.setLimit("max",e,!0,u.toString(r))}lt(e,r){return this.setLimit("max",e,!1,u.toString(r))}setLimit(e,r,a,n){return new U({...this._def,checks:[...this._def.checks,{kind:e,value:r,inclusive:a,message:u.toString(n)}]})}_addCheck(e){return new U({...this._def,checks:[...this._def.checks,e]})}int(e){return this._addCheck({kind:"int",message:u.toString(e)})}positive(e){return this._addCheck({kind:"min",value:0,inclusive:!1,message:u.toString(e)})}negative(e){return this._addCheck({kind:"max",value:0,inclusive:!1,message:u.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:0,inclusive:!0,message:u.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:0,inclusive:!0,message:u.toString(e)})}multipleOf(e,r){return this._addCheck({kind:"multipleOf",value:e,message:u.toString(r)})}finite(e){return this._addCheck({kind:"finite",message:u.toString(e)})}safe(e){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:u.toString(e)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:u.toString(e)})}get minValue(){let e=null;for(const r of this._def.checks)r.kind==="min"&&(e===null||r.value>e)&&(e=r.value);return e}get maxValue(){let e=null;for(const r of this._def.checks)r.kind==="max"&&(e===null||r.value<e)&&(e=r.value);return e}get isInt(){return!!this._def.checks.find(e=>e.kind==="int"||e.kind==="multipleOf"&&x.isInteger(e.value))}get isFinite(){let e=null,r=null;for(const a of this._def.checks){if(a.kind==="finite"||a.kind==="int"||a.kind==="multipleOf")return!0;a.kind==="min"?(r===null||a.value>r)&&(r=a.value):a.kind==="max"&&(e===null||a.value<e)&&(e=a.value)}return Number.isFinite(r)&&Number.isFinite(e)}}U.create=t=>new U({checks:[],typeName:m.ZodNumber,coerce:t?.coerce||!1,...y(t)});class q extends b{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(e){if(this._def.coerce)try{e.data=BigInt(e.data)}catch{return this._getInvalidInput(e)}if(this._getType(e)!==l.bigint)return this._getInvalidInput(e);let a;const n=new O;for(const o of this._def.checks)o.kind==="min"?(o.inclusive?e.data<o.value:e.data<=o.value)&&(a=this._getOrReturnCtx(e,a),c(a,{code:d.too_small,type:"bigint",minimum:o.value,inclusive:o.inclusive,message:o.message}),n.dirty()):o.kind==="max"?(o.inclusive?e.data>o.value:e.data>=o.value)&&(a=this._getOrReturnCtx(e,a),c(a,{code:d.too_big,type:"bigint",maximum:o.value,inclusive:o.inclusive,message:o.message}),n.dirty()):o.kind==="multipleOf"?e.data%o.value!==BigInt(0)&&(a=this._getOrReturnCtx(e,a),c(a,{code:d.not_multiple_of,multipleOf:o.value,message:o.message}),n.dirty()):x.assertNever(o);return{status:n.value,value:e.data}}_getInvalidInput(e){const r=this._getOrReturnCtx(e);return c(r,{code:d.invalid_type,expected:l.bigint,received:r.parsedType}),g}gte(e,r){return this.setLimit("min",e,!0,u.toString(r))}gt(e,r){return this.setLimit("min",e,!1,u.toString(r))}lte(e,r){return this.setLimit("max",e,!0,u.toString(r))}lt(e,r){return this.setLimit("max",e,!1,u.toString(r))}setLimit(e,r,a,n){return new q({...this._def,checks:[...this._def.checks,{kind:e,value:r,inclusive:a,message:u.toString(n)}]})}_addCheck(e){return new q({...this._def,checks:[...this._def.checks,e]})}positive(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:u.toString(e)})}negative(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:u.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:u.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:u.toString(e)})}multipleOf(e,r){return this._addCheck({kind:"multipleOf",value:e,message:u.toString(r)})}get minValue(){let e=null;for(const r of this._def.checks)r.kind==="min"&&(e===null||r.value>e)&&(e=r.value);return e}get maxValue(){let e=null;for(const r of this._def.checks)r.kind==="max"&&(e===null||r.value<e)&&(e=r.value);return e}}q.create=t=>new q({checks:[],typeName:m.ZodBigInt,coerce:t?.coerce??!1,...y(t)});class ue extends b{_parse(e){if(this._def.coerce&&(e.data=!!e.data),this._getType(e)!==l.boolean){const a=this._getOrReturnCtx(e);return c(a,{code:d.invalid_type,expected:l.boolean,received:a.parsedType}),g}return R(e.data)}}ue.create=t=>new ue({typeName:m.ZodBoolean,coerce:t?.coerce||!1,...y(t)});class K extends b{_parse(e){if(this._def.coerce&&(e.data=new Date(e.data)),this._getType(e)!==l.date){const o=this._getOrReturnCtx(e);return c(o,{code:d.invalid_type,expected:l.date,received:o.parsedType}),g}if(Number.isNaN(e.data.getTime())){const o=this._getOrReturnCtx(e);return c(o,{code:d.invalid_date}),g}const a=new O;let n;for(const o of this._def.checks)o.kind==="min"?e.data.getTime()<o.value&&(n=this._getOrReturnCtx(e,n),c(n,{code:d.too_small,message:o.message,inclusive:!0,exact:!1,minimum:o.value,type:"date"}),a.dirty()):o.kind==="max"?e.data.getTime()>o.value&&(n=this._getOrReturnCtx(e,n),c(n,{code:d.too_big,message:o.message,inclusive:!0,exact:!1,maximum:o.value,type:"date"}),a.dirty()):x.assertNever(o);return{status:a.value,value:new Date(e.data.getTime())}}_addCheck(e){return new K({...this._def,checks:[...this._def.checks,e]})}min(e,r){return this._addCheck({kind:"min",value:e.getTime(),message:u.toString(r)})}max(e,r){return this._addCheck({kind:"max",value:e.getTime(),message:u.toString(r)})}get minDate(){let e=null;for(const r of this._def.checks)r.kind==="min"&&(e===null||r.value>e)&&(e=r.value);return e!=null?new Date(e):null}get maxDate(){let e=null;for(const r of this._def.checks)r.kind==="max"&&(e===null||r.value<e)&&(e=r.value);return e!=null?new Date(e):null}}K.create=t=>new K({checks:[],coerce:t?.coerce||!1,typeName:m.ZodDate,...y(t)});class Oe extends b{_parse(e){if(this._getType(e)!==l.symbol){const a=this._getOrReturnCtx(e);return c(a,{code:d.invalid_type,expected:l.symbol,received:a.parsedType}),g}return R(e.data)}}Oe.create=t=>new Oe({typeName:m.ZodSymbol,...y(t)});class Re extends b{_parse(e){if(this._getType(e)!==l.undefined){const a=this._getOrReturnCtx(e);return c(a,{code:d.invalid_type,expected:l.undefined,received:a.parsedType}),g}return R(e.data)}}Re.create=t=>new Re({typeName:m.ZodUndefined,...y(t)});class Me extends b{_parse(e){if(this._getType(e)!==l.null){const a=this._getOrReturnCtx(e);return c(a,{code:d.invalid_type,expected:l.null,received:a.parsedType}),g}return R(e.data)}}Me.create=t=>new Me({typeName:m.ZodNull,...y(t)});class Ae extends b{constructor(){super(...arguments),this._any=!0}_parse(e){return R(e.data)}}Ae.create=t=>new Ae({typeName:m.ZodAny,...y(t)});class Ne extends b{constructor(){super(...arguments),this._unknown=!0}_parse(e){return R(e.data)}}Ne.create=t=>new Ne({typeName:m.ZodUnknown,...y(t)});class L extends b{_parse(e){const r=this._getOrReturnCtx(e);return c(r,{code:d.invalid_type,expected:l.never,received:r.parsedType}),g}}L.create=t=>new L({typeName:m.ZodNever,...y(t)});class Ze extends b{_parse(e){if(this._getType(e)!==l.undefined){const a=this._getOrReturnCtx(e);return c(a,{code:d.invalid_type,expected:l.void,received:a.parsedType}),g}return R(e.data)}}Ze.create=t=>new Ze({typeName:m.ZodVoid,...y(t)});class A extends b{_parse(e){const{ctx:r,status:a}=this._processInputParams(e),n=this._def;if(r.parsedType!==l.array)return c(r,{code:d.invalid_type,expected:l.array,received:r.parsedType}),g;if(n.exactLength!==null){const s=r.data.length>n.exactLength.value,i=r.data.length<n.exactLength.value;(s||i)&&(c(r,{code:s?d.too_big:d.too_small,minimum:i?n.exactLength.value:void 0,maximum:s?n.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:n.exactLength.message}),a.dirty())}if(n.minLength!==null&&r.data.length<n.minLength.value&&(c(r,{code:d.too_small,minimum:n.minLength.value,type:"array",inclusive:!0,exact:!1,message:n.minLength.message}),a.dirty()),n.maxLength!==null&&r.data.length>n.maxLength.value&&(c(r,{code:d.too_big,maximum:n.maxLength.value,type:"array",inclusive:!0,exact:!1,message:n.maxLength.message}),a.dirty()),r.common.async)return Promise.all([...r.data].map((s,i)=>n.type._parseAsync(new N(r,s,r.path,i)))).then(s=>O.mergeArray(a,s));const o=[...r.data].map((s,i)=>n.type._parseSync(new N(r,s,r.path,i)));return O.mergeArray(a,o)}get element(){return this._def.type}min(e,r){return new A({...this._def,minLength:{value:e,message:u.toString(r)}})}max(e,r){return new A({...this._def,maxLength:{value:e,message:u.toString(r)}})}length(e,r){return new A({...this._def,exactLength:{value:e,message:u.toString(r)}})}nonempty(e){return this.min(1,e)}}A.create=(t,e)=>new A({type:t,minLength:null,maxLength:null,exactLength:null,typeName:m.ZodArray,...y(e)});function P(t){if(t instanceof C){const e={};for(const r in t.shape){const a=t.shape[r];e[r]=z.create(P(a))}return new C({...t._def,shape:()=>e})}else return t instanceof A?new A({...t._def,type:P(t.element)}):t instanceof z?z.create(P(t.unwrap())):t instanceof H?H.create(P(t.unwrap())):t instanceof $?$.create(t.items.map(e=>P(e))):t}class C extends b{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;const e=this._def.shape(),r=x.objectKeys(e);return this._cached={shape:e,keys:r},this._cached}_parse(e){if(this._getType(e)!==l.object){const p=this._getOrReturnCtx(e);return c(p,{code:d.invalid_type,expected:l.object,received:p.parsedType}),g}const{status:a,ctx:n}=this._processInputParams(e),{shape:o,keys:s}=this._getCached(),i=[];if(!(this._def.catchall instanceof L&&this._def.unknownKeys==="strip"))for(const p in n.data)s.includes(p)||i.push(p);const f=[];for(const p of s){const _=o[p],E=n.data[p];f.push({key:{status:"valid",value:p},value:_._parse(new N(n,E,n.path,p)),alwaysSet:p in n.data})}if(this._def.catchall instanceof L){const p=this._def.unknownKeys;if(p==="passthrough")for(const _ of i)f.push({key:{status:"valid",value:_},value:{status:"valid",value:n.data[_]}});else if(p==="strict")i.length>0&&(c(n,{code:d.unrecognized_keys,keys:i}),a.dirty());else if(p!=="strip")throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{const p=this._def.catchall;for(const _ of i){const E=n.data[_];f.push({key:{status:"valid",value:_},value:p._parse(new N(n,E,n.path,_)),alwaysSet:_ in n.data})}}return n.common.async?Promise.resolve().then(async()=>{const p=[];for(const _ of f){const E=await _.key,J=await _.value;p.push({key:E,value:J,alwaysSet:_.alwaysSet})}return p}).then(p=>O.mergeObjectSync(a,p)):O.mergeObjectSync(a,f)}get shape(){return this._def.shape()}strict(e){return u.errToObj,new C({...this._def,unknownKeys:"strict",...e!==void 0?{errorMap:(r,a)=>{const n=this._def.errorMap?.(r,a).message??a.defaultError;return r.code==="unrecognized_keys"?{message:u.errToObj(e).message??n}:{message:n}}}:{}})}strip(){return new C({...this._def,unknownKeys:"strip"})}passthrough(){return new C({...this._def,unknownKeys:"passthrough"})}extend(e){return new C({...this._def,shape:()=>({...this._def.shape(),...e})})}merge(e){return new C({unknownKeys:e._def.unknownKeys,catchall:e._def.catchall,shape:()=>({...this._def.shape(),...e._def.shape()}),typeName:m.ZodObject})}setKey(e,r){return this.augment({[e]:r})}catchall(e){return new C({...this._def,catchall:e})}pick(e){const r={};for(const a of x.objectKeys(e))e[a]&&this.shape[a]&&(r[a]=this.shape[a]);return new C({...this._def,shape:()=>r})}omit(e){const r={};for(const a of x.objectKeys(this.shape))e[a]||(r[a]=this.shape[a]);return new C({...this._def,shape:()=>r})}deepPartial(){return P(this)}partial(e){const r={};for(const a of x.objectKeys(this.shape)){const n=this.shape[a];e&&!e[a]?r[a]=n:r[a]=n.optional()}return new C({...this._def,shape:()=>r})}required(e){const r={};for(const a of x.objectKeys(this.shape))if(e&&!e[a])r[a]=this.shape[a];else{let o=this.shape[a];for(;o instanceof z;)o=o._def.innerType;r[a]=o}return new C({...this._def,shape:()=>r})}keyof(){return Ue(x.objectKeys(this.shape))}}C.create=(t,e)=>new C({shape:()=>t,unknownKeys:"strip",catchall:L.create(),typeName:m.ZodObject,...y(e)});C.strictCreate=(t,e)=>new C({shape:()=>t,unknownKeys:"strict",catchall:L.create(),typeName:m.ZodObject,...y(e)});C.lazycreate=(t,e)=>new C({shape:t,unknownKeys:"strip",catchall:L.create(),typeName:m.ZodObject,...y(e)});class ee extends b{_parse(e){const{ctx:r}=this._processInputParams(e),a=this._def.options;function n(o){for(const i of o)if(i.result.status==="valid")return i.result;for(const i of o)if(i.result.status==="dirty")return r.common.issues.push(...i.ctx.common.issues),i.result;const s=o.map(i=>new I(i.ctx.common.issues));return c(r,{code:d.invalid_union,unionErrors:s}),g}if(r.common.async)return Promise.all(a.map(async o=>{const s={...r,common:{...r.common,issues:[]},parent:null};return{result:await o._parseAsync({data:r.data,path:r.path,parent:s}),ctx:s}})).then(n);{let o;const s=[];for(const f of a){const p={...r,common:{...r.common,issues:[]},parent:null},_=f._parseSync({data:r.data,path:r.path,parent:p});if(_.status==="valid")return _;_.status==="dirty"&&!o&&(o={result:_,ctx:p}),p.common.issues.length&&s.push(p.common.issues)}if(o)return r.common.issues.push(...o.ctx.common.issues),o.result;const i=s.map(f=>new I(f));return c(r,{code:d.invalid_union,unionErrors:i}),g}}get options(){return this._def.options}}ee.create=(t,e)=>new ee({options:t,typeName:m.ZodUnion,...y(e)});function he(t,e){const r=B(t),a=B(e);if(t===e)return{valid:!0,data:t};if(r===l.object&&a===l.object){const n=x.objectKeys(e),o=x.objectKeys(t).filter(i=>n.indexOf(i)!==-1),s={...t,...e};for(const i of o){const f=he(t[i],e[i]);if(!f.valid)return{valid:!1};s[i]=f.data}return{valid:!0,data:s}}else if(r===l.array&&a===l.array){if(t.length!==e.length)return{valid:!1};const n=[];for(let o=0;o<t.length;o++){const s=t[o],i=e[o],f=he(s,i);if(!f.valid)return{valid:!1};n.push(f.data)}return{valid:!0,data:n}}else return r===l.date&&a===l.date&&+t==+e?{valid:!0,data:t}:{valid:!1}}class re extends b{_parse(e){const{status:r,ctx:a}=this._processInputParams(e),n=(o,s)=>{if(Se(o)||Se(s))return g;const i=he(o.value,s.value);return i.valid?((je(o)||je(s))&&r.dirty(),{status:r.value,value:i.data}):(c(a,{code:d.invalid_intersection_types}),g)};return a.common.async?Promise.all([this._def.left._parseAsync({data:a.data,path:a.path,parent:a}),this._def.right._parseAsync({data:a.data,path:a.path,parent:a})]).then(([o,s])=>n(o,s)):n(this._def.left._parseSync({data:a.data,path:a.path,parent:a}),this._def.right._parseSync({data:a.data,path:a.path,parent:a}))}}re.create=(t,e,r)=>new re({left:t,right:e,typeName:m.ZodIntersection,...y(r)});class $ extends b{_parse(e){const{status:r,ctx:a}=this._processInputParams(e);if(a.parsedType!==l.array)return c(a,{code:d.invalid_type,expected:l.array,received:a.parsedType}),g;if(a.data.length<this._def.items.length)return c(a,{code:d.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),g;!this._def.rest&&a.data.length>this._def.items.length&&(c(a,{code:d.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),r.dirty());const o=[...a.data].map((s,i)=>{const f=this._def.items[i]||this._def.rest;return f?f._parse(new N(a,s,a.path,i)):null}).filter(s=>!!s);return a.common.async?Promise.all(o).then(s=>O.mergeArray(r,s)):O.mergeArray(r,o)}get items(){return this._def.items}rest(e){return new $({...this._def,rest:e})}}$.create=(t,e)=>{if(!Array.isArray(t))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new $({items:t,typeName:m.ZodTuple,rest:null,...y(e)})};class te extends b{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){const{status:r,ctx:a}=this._processInputParams(e);if(a.parsedType!==l.object)return c(a,{code:d.invalid_type,expected:l.object,received:a.parsedType}),g;const n=[],o=this._def.keyType,s=this._def.valueType;for(const i in a.data)n.push({key:o._parse(new N(a,i,a.path,i)),value:s._parse(new N(a,a.data[i],a.path,i)),alwaysSet:i in a.data});return a.common.async?O.mergeObjectAsync(r,n):O.mergeObjectSync(r,n)}get element(){return this._def.valueType}static create(e,r,a){return r instanceof b?new te({keyType:e,valueType:r,typeName:m.ZodRecord,...y(a)}):new te({keyType:Z.create(),valueType:e,typeName:m.ZodRecord,...y(r)})}}class Ie extends b{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){const{status:r,ctx:a}=this._processInputParams(e);if(a.parsedType!==l.map)return c(a,{code:d.invalid_type,expected:l.map,received:a.parsedType}),g;const n=this._def.keyType,o=this._def.valueType,s=[...a.data.entries()].map(([i,f],p)=>({key:n._parse(new N(a,i,a.path,[p,"key"])),value:o._parse(new N(a,f,a.path,[p,"value"]))}));if(a.common.async){const i=new Map;return Promise.resolve().then(async()=>{for(const f of s){const p=await f.key,_=await f.value;if(p.status==="aborted"||_.status==="aborted")return g;(p.status==="dirty"||_.status==="dirty")&&r.dirty(),i.set(p.value,_.value)}return{status:r.value,value:i}})}else{const i=new Map;for(const f of s){const p=f.key,_=f.value;if(p.status==="aborted"||_.status==="aborted")return g;(p.status==="dirty"||_.status==="dirty")&&r.dirty(),i.set(p.value,_.value)}return{status:r.value,value:i}}}}Ie.create=(t,e,r)=>new Ie({valueType:e,keyType:t,typeName:m.ZodMap,...y(r)});class Y extends b{_parse(e){const{status:r,ctx:a}=this._processInputParams(e);if(a.parsedType!==l.set)return c(a,{code:d.invalid_type,expected:l.set,received:a.parsedType}),g;const n=this._def;n.minSize!==null&&a.data.size<n.minSize.value&&(c(a,{code:d.too_small,minimum:n.minSize.value,type:"set",inclusive:!0,exact:!1,message:n.minSize.message}),r.dirty()),n.maxSize!==null&&a.data.size>n.maxSize.value&&(c(a,{code:d.too_big,maximum:n.maxSize.value,type:"set",inclusive:!0,exact:!1,message:n.maxSize.message}),r.dirty());const o=this._def.valueType;function s(f){const p=new Set;for(const _ of f){if(_.status==="aborted")return g;_.status==="dirty"&&r.dirty(),p.add(_.value)}return{status:r.value,value:p}}const i=[...a.data.values()].map((f,p)=>o._parse(new N(a,f,a.path,p)));return a.common.async?Promise.all(i).then(f=>s(f)):s(i)}min(e,r){return new Y({...this._def,minSize:{value:e,message:u.toString(r)}})}max(e,r){return new Y({...this._def,maxSize:{value:e,message:u.toString(r)}})}size(e,r){return this.min(e,r).max(e,r)}nonempty(e){return this.min(1,e)}}Y.create=(t,e)=>new Y({valueType:t,minSize:null,maxSize:null,typeName:m.ZodSet,...y(e)});class Ee extends b{get schema(){return this._def.getter()}_parse(e){const{ctx:r}=this._processInputParams(e);return this._def.getter()._parse({data:r.data,path:r.path,parent:r})}}Ee.create=(t,e)=>new Ee({getter:t,typeName:m.ZodLazy,...y(e)});class fe extends b{_parse(e){if(e.data!==this._def.value){const r=this._getOrReturnCtx(e);return c(r,{received:r.data,code:d.invalid_literal,expected:this._def.value}),g}return{status:"valid",value:e.data}}get value(){return this._def.value}}fe.create=(t,e)=>new fe({value:t,typeName:m.ZodLiteral,...y(e)});function Ue(t,e){return new W({values:t,typeName:m.ZodEnum,...y(e)})}class W extends b{_parse(e){if(typeof e.data!="string"){const r=this._getOrReturnCtx(e),a=this._def.values;return c(r,{expected:x.joinValues(a),received:r.parsedType,code:d.invalid_type}),g}if(this._cache||(this._cache=new Set(this._def.values)),!this._cache.has(e.data)){const r=this._getOrReturnCtx(e),a=this._def.values;return c(r,{received:r.data,code:d.invalid_enum_value,options:a}),g}return R(e.data)}get options(){return this._def.values}get enum(){const e={};for(const r of this._def.values)e[r]=r;return e}get Values(){const e={};for(const r of this._def.values)e[r]=r;return e}get Enum(){const e={};for(const r of this._def.values)e[r]=r;return e}extract(e,r=this._def){return W.create(e,{...this._def,...r})}exclude(e,r=this._def){return W.create(this.options.filter(a=>!e.includes(a)),{...this._def,...r})}}W.create=Ue;class Be extends b{_parse(e){const r=x.getValidEnumValues(this._def.values),a=this._getOrReturnCtx(e);if(a.parsedType!==l.string&&a.parsedType!==l.number){const n=x.objectValues(r);return c(a,{expected:x.joinValues(n),received:a.parsedType,code:d.invalid_type}),g}if(this._cache||(this._cache=new Set(x.getValidEnumValues(this._def.values))),!this._cache.has(e.data)){const n=x.objectValues(r);return c(a,{received:a.data,code:d.invalid_enum_value,options:n}),g}return R(e.data)}get enum(){return this._def.values}}Be.create=(t,e)=>new Be({values:t,typeName:m.ZodNativeEnum,...y(e)});class ae extends b{unwrap(){return this._def.type}_parse(e){const{ctx:r}=this._processInputParams(e);if(r.parsedType!==l.promise&&r.common.async===!1)return c(r,{code:d.invalid_type,expected:l.promise,received:r.parsedType}),g;const a=r.parsedType===l.promise?r.data:Promise.resolve(r.data);return R(a.then(n=>this._def.type.parseAsync(n,{path:r.path,errorMap:r.common.contextualErrorMap})))}}ae.create=(t,e)=>new ae({type:t,typeName:m.ZodPromise,...y(e)});class F extends b{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===m.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(e){const{status:r,ctx:a}=this._processInputParams(e),n=this._def.effect||null,o={addIssue:s=>{c(a,s),s.fatal?r.abort():r.dirty()},get path(){return a.path}};if(o.addIssue=o.addIssue.bind(o),n.type==="preprocess"){const s=n.transform(a.data,o);if(a.common.async)return Promise.resolve(s).then(async i=>{if(r.value==="aborted")return g;const f=await this._def.schema._parseAsync({data:i,path:a.path,parent:a});return f.status==="aborted"?g:f.status==="dirty"||r.value==="dirty"?G(f.value):f});{if(r.value==="aborted")return g;const i=this._def.schema._parseSync({data:s,path:a.path,parent:a});return i.status==="aborted"?g:i.status==="dirty"||r.value==="dirty"?G(i.value):i}}if(n.type==="refinement"){const s=i=>{const f=n.refinement(i,o);if(a.common.async)return Promise.resolve(f);if(f instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return i};if(a.common.async===!1){const i=this._def.schema._parseSync({data:a.data,path:a.path,parent:a});return i.status==="aborted"?g:(i.status==="dirty"&&r.dirty(),s(i.value),{status:r.value,value:i.value})}else return this._def.schema._parseAsync({data:a.data,path:a.path,parent:a}).then(i=>i.status==="aborted"?g:(i.status==="dirty"&&r.dirty(),s(i.value).then(()=>({status:r.value,value:i.value}))))}if(n.type==="transform")if(a.common.async===!1){const s=this._def.schema._parseSync({data:a.data,path:a.path,parent:a});if(!V(s))return g;const i=n.transform(s.value,o);if(i instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:r.value,value:i}}else return this._def.schema._parseAsync({data:a.data,path:a.path,parent:a}).then(s=>V(s)?Promise.resolve(n.transform(s.value,o)).then(i=>({status:r.value,value:i})):g);x.assertNever(n)}}F.create=(t,e,r)=>new F({schema:t,typeName:m.ZodEffects,effect:e,...y(r)});F.createWithPreprocess=(t,e,r)=>new F({schema:e,effect:{type:"preprocess",transform:t},typeName:m.ZodEffects,...y(r)});class z extends b{_parse(e){return this._getType(e)===l.undefined?R(void 0):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}z.create=(t,e)=>new z({innerType:t,typeName:m.ZodOptional,...y(e)});class H extends b{_parse(e){return this._getType(e)===l.null?R(null):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}H.create=(t,e)=>new H({innerType:t,typeName:m.ZodNullable,...y(e)});class pe extends b{_parse(e){const{ctx:r}=this._processInputParams(e);let a=r.data;return r.parsedType===l.undefined&&(a=this._def.defaultValue()),this._def.innerType._parse({data:a,path:r.path,parent:r})}removeDefault(){return this._def.innerType}}pe.create=(t,e)=>new pe({innerType:t,typeName:m.ZodDefault,defaultValue:typeof e.default=="function"?e.default:()=>e.default,...y(e)});class me extends b{_parse(e){const{ctx:r}=this._processInputParams(e),a={...r,common:{...r.common,issues:[]}},n=this._def.innerType._parse({data:a.data,path:a.path,parent:{...a}});return Q(n)?n.then(o=>({status:"valid",value:o.status==="valid"?o.value:this._def.catchValue({get error(){return new I(a.common.issues)},input:a.data})})):{status:"valid",value:n.status==="valid"?n.value:this._def.catchValue({get error(){return new I(a.common.issues)},input:a.data})}}removeCatch(){return this._def.innerType}}me.create=(t,e)=>new me({innerType:t,typeName:m.ZodCatch,catchValue:typeof e.catch=="function"?e.catch:()=>e.catch,...y(e)});class ze extends b{_parse(e){if(this._getType(e)!==l.nan){const a=this._getOrReturnCtx(e);return c(a,{code:d.invalid_type,expected:l.nan,received:a.parsedType}),g}return{status:"valid",value:e.data}}}ze.create=t=>new ze({typeName:m.ZodNaN,...y(t)});class Nr extends b{_parse(e){const{ctx:r}=this._processInputParams(e),a=r.data;return this._def.type._parse({data:a,path:r.path,parent:r})}unwrap(){return this._def.type}}class ke extends b{_parse(e){const{status:r,ctx:a}=this._processInputParams(e);if(a.common.async)return(async()=>{const o=await this._def.in._parseAsync({data:a.data,path:a.path,parent:a});return o.status==="aborted"?g:o.status==="dirty"?(r.dirty(),G(o.value)):this._def.out._parseAsync({data:o.value,path:a.path,parent:a})})();{const n=this._def.in._parseSync({data:a.data,path:a.path,parent:a});return n.status==="aborted"?g:n.status==="dirty"?(r.dirty(),{status:"dirty",value:n.value}):this._def.out._parseSync({data:n.value,path:a.path,parent:a})}}static create(e,r){return new ke({in:e,out:r,typeName:m.ZodPipeline})}}class ge extends b{_parse(e){const r=this._def.innerType._parse(e),a=n=>(V(n)&&(n.value=Object.freeze(n.value)),n);return Q(r)?r.then(n=>a(n)):a(r)}unwrap(){return this._def.innerType}}ge.create=(t,e)=>new ge({innerType:t,typeName:m.ZodReadonly,...y(e)});var m;(function(t){t.ZodString="ZodString",t.ZodNumber="ZodNumber",t.ZodNaN="ZodNaN",t.ZodBigInt="ZodBigInt",t.ZodBoolean="ZodBoolean",t.ZodDate="ZodDate",t.ZodSymbol="ZodSymbol",t.ZodUndefined="ZodUndefined",t.ZodNull="ZodNull",t.ZodAny="ZodAny",t.ZodUnknown="ZodUnknown",t.ZodNever="ZodNever",t.ZodVoid="ZodVoid",t.ZodArray="ZodArray",t.ZodObject="ZodObject",t.ZodUnion="ZodUnion",t.ZodDiscriminatedUnion="ZodDiscriminatedUnion",t.ZodIntersection="ZodIntersection",t.ZodTuple="ZodTuple",t.ZodRecord="ZodRecord",t.ZodMap="ZodMap",t.ZodSet="ZodSet",t.ZodFunction="ZodFunction",t.ZodLazy="ZodLazy",t.ZodLiteral="ZodLiteral",t.ZodEnum="ZodEnum",t.ZodEffects="ZodEffects",t.ZodNativeEnum="ZodNativeEnum",t.ZodOptional="ZodOptional",t.ZodNullable="ZodNullable",t.ZodDefault="ZodDefault",t.ZodCatch="ZodCatch",t.ZodPromise="ZodPromise",t.ZodBranded="ZodBranded",t.ZodPipeline="ZodPipeline",t.ZodReadonly="ZodReadonly"})(m||(m={}));const h=Z.create,ve=U.create,Hr=ue.create;L.create;const Zr=A.create,S=C.create,be=ee.create;re.create;$.create;const _e=te.create,Gr=fe.create,We=W.create;ae.create;z.create;H.create;const Ir=S({minRem:ve(),maxRem:ve()}),T=Ir.or(h()),X=S({0:h().optional(),50:h(),100:h(),200:h(),300:h(),400:h(),500:h(),600:h(),700:h(),800:h(),900:h(),950:h(),1e3:h().optional()}),de=S({color:h().optional(),background:h().optional(),borderWidth:h().optional(),borderColor:h().optional(),boxShadow:h().optional()}),Er=S({borderRadius:T.optional(),custom:_e(h(),be([h(),ve()])).optional(),hover:de.optional(),focus:de.optional()}).and(de),Br=S({family:h().optional()}),zr=_e(We(["predefinedQuestion","edit","newConversation","voteUp","voteDown","retry","message","messageLoading","thread","submit","abort","expand","help","attach","record","reward","share","audio","copy","dismiss","menu","info","menuClose","chevronDown","chevronUp","chevronTopDown","chevronDownSmall","internalLink","externalLink","liip","avatar","avatarLarge","openChat","speechInput","listUnordered","lightMode","darkMode","avatarLarge","settings","settingsClose","sources","model","checkbox"]),h()),Lr=S({font:Br.optional(),colors:S({brand:X,accent:X.optional(),highlight:X,grey:X}),base:S({fontSizeXs:T.optional(),fontSizeSm:T.optional(),fontSizeBody:T.optional(),fontSizeH3:T.optional(),fontSizeH2:T.optional(),fontSizeH1:T.optional(),fontWeightNormal:h().optional(),fontWeightBold:h().optional(),fontWeightTitle:h().optional(),lineHeightDefault:h().optional(),lineHeightSnug:h().optional(),lineHeightTight:h().optional(),borderRadius:T.optional(),lineColor:h().optional(),boxShadow:h().optional()}),components:_e(h(),Er),svgs:zr}),ne=S({customCSS:h().optional(),fontCSS:h().optional(),fontURLs:h().array().optional(),tokens:Lr});S({light:ne,dark:ne});const $r=S({light:ne,dark:ne}).deepPartial(),Fe=S({50:h(),100:h(),200:h(),300:h(),400:h(),500:h(),600:h(),700:h(),800:h(),900:h(),950:h()}),He=We(["slate","gray","zinc","neutral","stone","red","orange","amber","yellow","lime","green","emerald","teal","cyan","sky","blue","indigo","violet","purple","fuchsia","pink","rose"]),Le=be([Fe,He]),Dr=be([Fe.and(S({0:h(),1e3:h()})),He]),Pr=S({avatarImageUrl:h().optional(),colors:S({brand:Le.optional(),highlight:Le.optional(),grey:Dr.optional(),background:h().optional(),text:h().optional(),anchor:S({default:h().optional(),hover:h().optional()}).optional()}).optional(),font:S({family:h().optional(),urls:Zr(h()).optional(),sizeXs:T.optional(),sizeSm:T.optional(),sizeBody:T.optional(),sizeH3:T.optional(),sizeH2:T.optional(),sizeH1:T.optional(),weightNormal:h().optional(),weightBold:h().optional(),weightTitle:h().optional()}).optional(),borderRadius:T.optional(),fineGrained:$r.optional()}),Vr=t=>t.split("/").pop().split(".")[0],Ur=Object.assign({"./default/fallback-dev.theme.ts":sr,"./default/fallback.theme.ts":nr}),xe=new Map;Object.entries(Ur).forEach(([t,e])=>{const{error:r,data:a}=Pr.safeParse(e?.theme);if(r){console.error(`Invalid theme in ${t}:`,r);return}xe.set(Vr(t),a)});const qr=t=>{const e=xe.get(t);return e||(console.error(`Theme ${t} not found`),oe)};Array.from(xe.keys());export{Wr as P,Zr as a,Hr as b,Pr as c,er as d,We as e,Vr as f,Xe as g,qr as h,Fr as i,Gr as l,tr as m,ve as n,S as o,_e as r,h as s,oe as t,be as u};
|
|
269
|
+
`}}},ar=tr($e,{tokens:{base:{lineColor:"color-mix(in srgb, var(--color-brand-100) 20%, transparent)"},components:{body:{background:"var(--color-grey-900)",color:"var(--color-grey-100)",focus:{color:"var(--color-highlight-400)"},custom:{selectionColor:"var(--color-grey-1000)",selectionBackground:"var(--color-brand-400)"}},avatar:{color:"var(--color-brand-200)",background:"var(--color-grey-800)"},anchor:{color:"var(--color-brand-300)",hover:{color:"var(--color-brand-50)"}},btnPrimary:{color:"var(--color-grey-1000)",background:"var(--color-brand-300)",hover:{background:"var(--color-brand-100)"}},btnSecondary:{color:"var(--color-brand-100)",background:"var(--color-brand-900)",hover:{color:"var(--color-grey-0)",background:"var(--color-brand-800)"}},btnTertiary:{color:"var(--anchor-color)",background:"transparent",borderRadius:"var(--base-border-radius)",hover:{color:"var(--anchor-hover-color)"}},card:{color:"var(--body-color)",background:"var(--color-grey-800)",hover:{color:"var(--color-grey-0)",background:"var(--color-brand-900)"}},input:{background:"var(--color-grey-900)",borderColor:"var(--color-grey-700)",custom:{placeholderColor:"var(--color-grey-400)"}},label:{color:"var(--color-grey-50)"},contextBox:{custom:{titleColor:"var(--color-grey-50)"}},referenceDescription:{color:"var(--color-grey-300)",hover:{color:"var(--color-grey-300)"}},chatFooter:{color:"var(--color-grey-500)"},chatInput:{color:"var(--color-grey-100)"},chatInputSubmit:{custom:{deactivatedBackground:"var(--color-grey-400)",deactivatedBorderColor:"var(--color-grey-400)"}},dialog:{custom:{backgroundOverlay:"rgba(0, 0, 0, 0.5)"}},tooltip:{background:"var(--color-grey-1000)"}}}}),oe={fineGrained:{light:$e,dark:ar}},nr=Object.freeze(Object.defineProperty({__proto__:null,theme:oe},Symbol.toStringTag,{value:"Module"})),ye=structuredClone(oe.fineGrained.light);ye.tokens.colors={brand:{50:"#f0f9ff",100:"#e0f2fe",200:"#bae6fd",300:"#7dd3fc",400:"#38bdf8",500:"#0ea5e9",600:"#037ABA",700:"#0369a1",800:"#075985",900:"#0c4a6e",950:"#082f49"},highlight:{50:"#f5f3ff",100:"#ede9fe",200:"#ddd6fe",300:"#c4b5fd",400:"#a78bfa",500:"#8b5cf6",600:"#7c3aed",700:"#6d28d9",800:"#5b21b6",900:"#4c1d95",950:"#2e1065"},grey:{0:"#ffffff",50:"#f9fafb",100:"#f3f4f6",200:"#e5e7eb",300:"#d1d5db",400:"#9ca3af",500:"#6b7280",600:"#4b5563",700:"#374151",800:"#2d3748",900:"#1a202c",950:"#171923",1e3:"#000000"}};const De=structuredClone(oe.fineGrained.dark);De.tokens.colors=ye.tokens.colors;const or={fineGrained:{light:ye,dark:De}},sr=Object.freeze(Object.defineProperty({__proto__:null,theme:or},Symbol.toStringTag,{value:"Module"}));var x;(function(t){t.assertEqual=n=>{};function e(n){}t.assertIs=e;function r(n){throw new Error}t.assertNever=r,t.arrayToEnum=n=>{const o={};for(const s of n)o[s]=s;return o},t.getValidEnumValues=n=>{const o=t.objectKeys(n).filter(i=>typeof n[n[i]]!="number"),s={};for(const i of o)s[i]=n[i];return t.objectValues(s)},t.objectValues=n=>t.objectKeys(n).map(function(o){return n[o]}),t.objectKeys=typeof Object.keys=="function"?n=>Object.keys(n):n=>{const o=[];for(const s in n)Object.prototype.hasOwnProperty.call(n,s)&&o.push(s);return o},t.find=(n,o)=>{for(const s of n)if(o(s))return s},t.isInteger=typeof Number.isInteger=="function"?n=>Number.isInteger(n):n=>typeof n=="number"&&Number.isFinite(n)&&Math.floor(n)===n;function a(n,o=" | "){return n.map(s=>typeof s=="string"?`'${s}'`:s).join(o)}t.joinValues=a,t.jsonStringifyReplacer=(n,o)=>typeof o=="bigint"?o.toString():o})(x||(x={}));var Ce;(function(t){t.mergeShapes=(e,r)=>({...e,...r})})(Ce||(Ce={}));const l=x.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),B=t=>{switch(typeof t){case"undefined":return l.undefined;case"string":return l.string;case"number":return Number.isNaN(t)?l.nan:l.number;case"boolean":return l.boolean;case"function":return l.function;case"bigint":return l.bigint;case"symbol":return l.symbol;case"object":return Array.isArray(t)?l.array:t===null?l.null:t.then&&typeof t.then=="function"&&t.catch&&typeof t.catch=="function"?l.promise:typeof Map<"u"&&t instanceof Map?l.map:typeof Set<"u"&&t instanceof Set?l.set:typeof Date<"u"&&t instanceof Date?l.date:l.object;default:return l.unknown}},d=x.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]);class I extends Error{get errors(){return this.issues}constructor(e){super(),this.issues=[],this.addIssue=a=>{this.issues=[...this.issues,a]},this.addIssues=(a=[])=>{this.issues=[...this.issues,...a]};const r=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,r):this.__proto__=r,this.name="ZodError",this.issues=e}format(e){const r=e||function(o){return o.message},a={_errors:[]},n=o=>{for(const s of o.issues)if(s.code==="invalid_union")s.unionErrors.map(n);else if(s.code==="invalid_return_type")n(s.returnTypeError);else if(s.code==="invalid_arguments")n(s.argumentsError);else if(s.path.length===0)a._errors.push(r(s));else{let i=a,f=0;for(;f<s.path.length;){const p=s.path[f];f===s.path.length-1?(i[p]=i[p]||{_errors:[]},i[p]._errors.push(r(s))):i[p]=i[p]||{_errors:[]},i=i[p],f++}}};return n(this),a}static assert(e){if(!(e instanceof I))throw new Error(`Not a ZodError: ${e}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,x.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(e=r=>r.message){const r={},a=[];for(const n of this.issues)if(n.path.length>0){const o=n.path[0];r[o]=r[o]||[],r[o].push(e(n))}else a.push(e(n));return{formErrors:a,fieldErrors:r}}get formErrors(){return this.flatten()}}I.create=t=>new I(t);const le=(t,e)=>{let r;switch(t.code){case d.invalid_type:t.received===l.undefined?r="Required":r=`Expected ${t.expected}, received ${t.received}`;break;case d.invalid_literal:r=`Invalid literal value, expected ${JSON.stringify(t.expected,x.jsonStringifyReplacer)}`;break;case d.unrecognized_keys:r=`Unrecognized key(s) in object: ${x.joinValues(t.keys,", ")}`;break;case d.invalid_union:r="Invalid input";break;case d.invalid_union_discriminator:r=`Invalid discriminator value. Expected ${x.joinValues(t.options)}`;break;case d.invalid_enum_value:r=`Invalid enum value. Expected ${x.joinValues(t.options)}, received '${t.received}'`;break;case d.invalid_arguments:r="Invalid function arguments";break;case d.invalid_return_type:r="Invalid function return type";break;case d.invalid_date:r="Invalid date";break;case d.invalid_string:typeof t.validation=="object"?"includes"in t.validation?(r=`Invalid input: must include "${t.validation.includes}"`,typeof t.validation.position=="number"&&(r=`${r} at one or more positions greater than or equal to ${t.validation.position}`)):"startsWith"in t.validation?r=`Invalid input: must start with "${t.validation.startsWith}"`:"endsWith"in t.validation?r=`Invalid input: must end with "${t.validation.endsWith}"`:x.assertNever(t.validation):t.validation!=="regex"?r=`Invalid ${t.validation}`:r="Invalid";break;case d.too_small:t.type==="array"?r=`Array must contain ${t.exact?"exactly":t.inclusive?"at least":"more than"} ${t.minimum} element(s)`:t.type==="string"?r=`String must contain ${t.exact?"exactly":t.inclusive?"at least":"over"} ${t.minimum} character(s)`:t.type==="number"?r=`Number must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${t.minimum}`:t.type==="bigint"?r=`Number must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${t.minimum}`:t.type==="date"?r=`Date must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(t.minimum))}`:r="Invalid input";break;case d.too_big:t.type==="array"?r=`Array must contain ${t.exact?"exactly":t.inclusive?"at most":"less than"} ${t.maximum} element(s)`:t.type==="string"?r=`String must contain ${t.exact?"exactly":t.inclusive?"at most":"under"} ${t.maximum} character(s)`:t.type==="number"?r=`Number must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`:t.type==="bigint"?r=`BigInt must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`:t.type==="date"?r=`Date must be ${t.exact?"exactly":t.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(t.maximum))}`:r="Invalid input";break;case d.custom:r="Invalid input";break;case d.invalid_intersection_types:r="Intersection results could not be merged";break;case d.not_multiple_of:r=`Number must be a multiple of ${t.multipleOf}`;break;case d.not_finite:r="Number must be finite";break;default:r=e.defaultError,x.assertNever(t)}return{message:r}};let ir=le;function dr(){return ir}const cr=t=>{const{data:e,path:r,errorMaps:a,issueData:n}=t,o=[...r,...n.path||[]],s={...n,path:o};if(n.message!==void 0)return{...n,path:o,message:n.message};let i="";const f=a.filter(p=>!!p).slice().reverse();for(const p of f)i=p(s,{data:e,defaultError:i}).message;return{...n,path:o,message:i}};function c(t,e){const r=dr(),a=cr({issueData:e,data:t.data,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,r,r===le?void 0:le].filter(n=>!!n)});t.common.issues.push(a)}class O{constructor(){this.value="valid"}dirty(){this.value==="valid"&&(this.value="dirty")}abort(){this.value!=="aborted"&&(this.value="aborted")}static mergeArray(e,r){const a=[];for(const n of r){if(n.status==="aborted")return g;n.status==="dirty"&&e.dirty(),a.push(n.value)}return{status:e.value,value:a}}static async mergeObjectAsync(e,r){const a=[];for(const n of r){const o=await n.key,s=await n.value;a.push({key:o,value:s})}return O.mergeObjectSync(e,a)}static mergeObjectSync(e,r){const a={};for(const n of r){const{key:o,value:s}=n;if(o.status==="aborted"||s.status==="aborted")return g;o.status==="dirty"&&e.dirty(),s.status==="dirty"&&e.dirty(),o.value!=="__proto__"&&(typeof s.value<"u"||n.alwaysSet)&&(a[o.value]=s.value)}return{status:e.value,value:a}}}const g=Object.freeze({status:"aborted"}),G=t=>({status:"dirty",value:t}),R=t=>({status:"valid",value:t}),Se=t=>t.status==="aborted",je=t=>t.status==="dirty",V=t=>t.status==="valid",Q=t=>typeof Promise<"u"&&t instanceof Promise;var u;(function(t){t.errToObj=e=>typeof e=="string"?{message:e}:e||{},t.toString=e=>typeof e=="string"?e:e?.message})(u||(u={}));class N{constructor(e,r,a,n){this._cachedPath=[],this.parent=e,this.data=r,this._path=a,this._key=n}get path(){return this._cachedPath.length||(Array.isArray(this._key)?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}}const Te=(t,e)=>{if(V(e))return{success:!0,data:e.value};if(!t.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;const r=new I(t.common.issues);return this._error=r,this._error}}};function y(t){if(!t)return{};const{errorMap:e,invalid_type_error:r,required_error:a,description:n}=t;if(e&&(r||a))throw new Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);return e?{errorMap:e,description:n}:{errorMap:(s,i)=>{const{message:f}=t;return s.code==="invalid_enum_value"?{message:f??i.defaultError}:typeof i.data>"u"?{message:f??a??i.defaultError}:s.code!=="invalid_type"?{message:i.defaultError}:{message:f??r??i.defaultError}},description:n}}class b{get description(){return this._def.description}_getType(e){return B(e.data)}_getOrReturnCtx(e,r){return r||{common:e.parent.common,data:e.data,parsedType:B(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}_processInputParams(e){return{status:new O,ctx:{common:e.parent.common,data:e.data,parsedType:B(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}}_parseSync(e){const r=this._parse(e);if(Q(r))throw new Error("Synchronous parse encountered promise.");return r}_parseAsync(e){const r=this._parse(e);return Promise.resolve(r)}parse(e,r){const a=this.safeParse(e,r);if(a.success)return a.data;throw a.error}safeParse(e,r){const a={common:{issues:[],async:r?.async??!1,contextualErrorMap:r?.errorMap},path:r?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:B(e)},n=this._parseSync({data:e,path:a.path,parent:a});return Te(a,n)}"~validate"(e){const r={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:B(e)};if(!this["~standard"].async)try{const a=this._parseSync({data:e,path:[],parent:r});return V(a)?{value:a.value}:{issues:r.common.issues}}catch(a){a?.message?.toLowerCase()?.includes("encountered")&&(this["~standard"].async=!0),r.common={issues:[],async:!0}}return this._parseAsync({data:e,path:[],parent:r}).then(a=>V(a)?{value:a.value}:{issues:r.common.issues})}async parseAsync(e,r){const a=await this.safeParseAsync(e,r);if(a.success)return a.data;throw a.error}async safeParseAsync(e,r){const a={common:{issues:[],contextualErrorMap:r?.errorMap,async:!0},path:r?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:B(e)},n=this._parse({data:e,path:a.path,parent:a}),o=await(Q(n)?n:Promise.resolve(n));return Te(a,o)}refine(e,r){const a=n=>typeof r=="string"||typeof r>"u"?{message:r}:typeof r=="function"?r(n):r;return this._refinement((n,o)=>{const s=e(n),i=()=>o.addIssue({code:d.custom,...a(n)});return typeof Promise<"u"&&s instanceof Promise?s.then(f=>f?!0:(i(),!1)):s?!0:(i(),!1)})}refinement(e,r){return this._refinement((a,n)=>e(a)?!0:(n.addIssue(typeof r=="function"?r(a,n):r),!1))}_refinement(e){return new F({schema:this,typeName:m.ZodEffects,effect:{type:"refinement",refinement:e}})}superRefine(e){return this._refinement(e)}constructor(e){this.spa=this.safeParseAsync,this._def=e,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this),this["~standard"]={version:1,vendor:"zod",validate:r=>this["~validate"](r)}}optional(){return z.create(this,this._def)}nullable(){return H.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return A.create(this)}promise(){return ae.create(this,this._def)}or(e){return ee.create([this,e],this._def)}and(e){return re.create(this,e,this._def)}transform(e){return new F({...y(this._def),schema:this,typeName:m.ZodEffects,effect:{type:"transform",transform:e}})}default(e){const r=typeof e=="function"?e:()=>e;return new pe({...y(this._def),innerType:this,defaultValue:r,typeName:m.ZodDefault})}brand(){return new Nr({typeName:m.ZodBranded,type:this,...y(this._def)})}catch(e){const r=typeof e=="function"?e:()=>e;return new me({...y(this._def),innerType:this,catchValue:r,typeName:m.ZodCatch})}describe(e){const r=this.constructor;return new r({...this._def,description:e})}pipe(e){return ke.create(this,e)}readonly(){return ge.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}const lr=/^c[^\s-]{8,}$/i,ur=/^[0-9a-z]+$/,hr=/^[0-9A-HJKMNP-TV-Z]{26}$/i,fr=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,pr=/^[a-z0-9_-]{21}$/i,mr=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,gr=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,vr=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,yr="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";let ie;const kr=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,br=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/(3[0-2]|[12]?[0-9])$/,_r=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))$/,xr=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,wr=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,Cr=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,Pe="((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",Sr=new RegExp(`^${Pe}$`);function Ve(t){let e="[0-5]\\d";t.precision?e=`${e}\\.\\d{${t.precision}}`:t.precision==null&&(e=`${e}(\\.\\d+)?`);const r=t.precision?"+":"?";return`([01]\\d|2[0-3]):[0-5]\\d(:${e})${r}`}function jr(t){return new RegExp(`^${Ve(t)}$`)}function Tr(t){let e=`${Pe}T${Ve(t)}`;const r=[];return r.push(t.local?"Z?":"Z"),t.offset&&r.push("([+-]\\d{2}:?\\d{2})"),e=`${e}(${r.join("|")})`,new RegExp(`^${e}$`)}function Or(t,e){return!!((e==="v4"||!e)&&kr.test(t)||(e==="v6"||!e)&&_r.test(t))}function Rr(t,e){if(!mr.test(t))return!1;try{const[r]=t.split(".");if(!r)return!1;const a=r.replace(/-/g,"+").replace(/_/g,"/").padEnd(r.length+(4-r.length%4)%4,"="),n=JSON.parse(atob(a));return!(typeof n!="object"||n===null||"typ"in n&&n?.typ!=="JWT"||!n.alg||e&&n.alg!==e)}catch{return!1}}function Mr(t,e){return!!((e==="v4"||!e)&&br.test(t)||(e==="v6"||!e)&&xr.test(t))}class Z extends b{_parse(e){if(this._def.coerce&&(e.data=String(e.data)),this._getType(e)!==l.string){const o=this._getOrReturnCtx(e);return c(o,{code:d.invalid_type,expected:l.string,received:o.parsedType}),g}const a=new O;let n;for(const o of this._def.checks)if(o.kind==="min")e.data.length<o.value&&(n=this._getOrReturnCtx(e,n),c(n,{code:d.too_small,minimum:o.value,type:"string",inclusive:!0,exact:!1,message:o.message}),a.dirty());else if(o.kind==="max")e.data.length>o.value&&(n=this._getOrReturnCtx(e,n),c(n,{code:d.too_big,maximum:o.value,type:"string",inclusive:!0,exact:!1,message:o.message}),a.dirty());else if(o.kind==="length"){const s=e.data.length>o.value,i=e.data.length<o.value;(s||i)&&(n=this._getOrReturnCtx(e,n),s?c(n,{code:d.too_big,maximum:o.value,type:"string",inclusive:!0,exact:!0,message:o.message}):i&&c(n,{code:d.too_small,minimum:o.value,type:"string",inclusive:!0,exact:!0,message:o.message}),a.dirty())}else if(o.kind==="email")vr.test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"email",code:d.invalid_string,message:o.message}),a.dirty());else if(o.kind==="emoji")ie||(ie=new RegExp(yr,"u")),ie.test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"emoji",code:d.invalid_string,message:o.message}),a.dirty());else if(o.kind==="uuid")fr.test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"uuid",code:d.invalid_string,message:o.message}),a.dirty());else if(o.kind==="nanoid")pr.test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"nanoid",code:d.invalid_string,message:o.message}),a.dirty());else if(o.kind==="cuid")lr.test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"cuid",code:d.invalid_string,message:o.message}),a.dirty());else if(o.kind==="cuid2")ur.test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"cuid2",code:d.invalid_string,message:o.message}),a.dirty());else if(o.kind==="ulid")hr.test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"ulid",code:d.invalid_string,message:o.message}),a.dirty());else if(o.kind==="url")try{new URL(e.data)}catch{n=this._getOrReturnCtx(e,n),c(n,{validation:"url",code:d.invalid_string,message:o.message}),a.dirty()}else o.kind==="regex"?(o.regex.lastIndex=0,o.regex.test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"regex",code:d.invalid_string,message:o.message}),a.dirty())):o.kind==="trim"?e.data=e.data.trim():o.kind==="includes"?e.data.includes(o.value,o.position)||(n=this._getOrReturnCtx(e,n),c(n,{code:d.invalid_string,validation:{includes:o.value,position:o.position},message:o.message}),a.dirty()):o.kind==="toLowerCase"?e.data=e.data.toLowerCase():o.kind==="toUpperCase"?e.data=e.data.toUpperCase():o.kind==="startsWith"?e.data.startsWith(o.value)||(n=this._getOrReturnCtx(e,n),c(n,{code:d.invalid_string,validation:{startsWith:o.value},message:o.message}),a.dirty()):o.kind==="endsWith"?e.data.endsWith(o.value)||(n=this._getOrReturnCtx(e,n),c(n,{code:d.invalid_string,validation:{endsWith:o.value},message:o.message}),a.dirty()):o.kind==="datetime"?Tr(o).test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{code:d.invalid_string,validation:"datetime",message:o.message}),a.dirty()):o.kind==="date"?Sr.test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{code:d.invalid_string,validation:"date",message:o.message}),a.dirty()):o.kind==="time"?jr(o).test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{code:d.invalid_string,validation:"time",message:o.message}),a.dirty()):o.kind==="duration"?gr.test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"duration",code:d.invalid_string,message:o.message}),a.dirty()):o.kind==="ip"?Or(e.data,o.version)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"ip",code:d.invalid_string,message:o.message}),a.dirty()):o.kind==="jwt"?Rr(e.data,o.alg)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"jwt",code:d.invalid_string,message:o.message}),a.dirty()):o.kind==="cidr"?Mr(e.data,o.version)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"cidr",code:d.invalid_string,message:o.message}),a.dirty()):o.kind==="base64"?wr.test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"base64",code:d.invalid_string,message:o.message}),a.dirty()):o.kind==="base64url"?Cr.test(e.data)||(n=this._getOrReturnCtx(e,n),c(n,{validation:"base64url",code:d.invalid_string,message:o.message}),a.dirty()):x.assertNever(o);return{status:a.value,value:e.data}}_regex(e,r,a){return this.refinement(n=>e.test(n),{validation:r,code:d.invalid_string,...u.errToObj(a)})}_addCheck(e){return new Z({...this._def,checks:[...this._def.checks,e]})}email(e){return this._addCheck({kind:"email",...u.errToObj(e)})}url(e){return this._addCheck({kind:"url",...u.errToObj(e)})}emoji(e){return this._addCheck({kind:"emoji",...u.errToObj(e)})}uuid(e){return this._addCheck({kind:"uuid",...u.errToObj(e)})}nanoid(e){return this._addCheck({kind:"nanoid",...u.errToObj(e)})}cuid(e){return this._addCheck({kind:"cuid",...u.errToObj(e)})}cuid2(e){return this._addCheck({kind:"cuid2",...u.errToObj(e)})}ulid(e){return this._addCheck({kind:"ulid",...u.errToObj(e)})}base64(e){return this._addCheck({kind:"base64",...u.errToObj(e)})}base64url(e){return this._addCheck({kind:"base64url",...u.errToObj(e)})}jwt(e){return this._addCheck({kind:"jwt",...u.errToObj(e)})}ip(e){return this._addCheck({kind:"ip",...u.errToObj(e)})}cidr(e){return this._addCheck({kind:"cidr",...u.errToObj(e)})}datetime(e){return typeof e=="string"?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:e}):this._addCheck({kind:"datetime",precision:typeof e?.precision>"u"?null:e?.precision,offset:e?.offset??!1,local:e?.local??!1,...u.errToObj(e?.message)})}date(e){return this._addCheck({kind:"date",message:e})}time(e){return typeof e=="string"?this._addCheck({kind:"time",precision:null,message:e}):this._addCheck({kind:"time",precision:typeof e?.precision>"u"?null:e?.precision,...u.errToObj(e?.message)})}duration(e){return this._addCheck({kind:"duration",...u.errToObj(e)})}regex(e,r){return this._addCheck({kind:"regex",regex:e,...u.errToObj(r)})}includes(e,r){return this._addCheck({kind:"includes",value:e,position:r?.position,...u.errToObj(r?.message)})}startsWith(e,r){return this._addCheck({kind:"startsWith",value:e,...u.errToObj(r)})}endsWith(e,r){return this._addCheck({kind:"endsWith",value:e,...u.errToObj(r)})}min(e,r){return this._addCheck({kind:"min",value:e,...u.errToObj(r)})}max(e,r){return this._addCheck({kind:"max",value:e,...u.errToObj(r)})}length(e,r){return this._addCheck({kind:"length",value:e,...u.errToObj(r)})}nonempty(e){return this.min(1,u.errToObj(e))}trim(){return new Z({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new Z({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new Z({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(e=>e.kind==="datetime")}get isDate(){return!!this._def.checks.find(e=>e.kind==="date")}get isTime(){return!!this._def.checks.find(e=>e.kind==="time")}get isDuration(){return!!this._def.checks.find(e=>e.kind==="duration")}get isEmail(){return!!this._def.checks.find(e=>e.kind==="email")}get isURL(){return!!this._def.checks.find(e=>e.kind==="url")}get isEmoji(){return!!this._def.checks.find(e=>e.kind==="emoji")}get isUUID(){return!!this._def.checks.find(e=>e.kind==="uuid")}get isNANOID(){return!!this._def.checks.find(e=>e.kind==="nanoid")}get isCUID(){return!!this._def.checks.find(e=>e.kind==="cuid")}get isCUID2(){return!!this._def.checks.find(e=>e.kind==="cuid2")}get isULID(){return!!this._def.checks.find(e=>e.kind==="ulid")}get isIP(){return!!this._def.checks.find(e=>e.kind==="ip")}get isCIDR(){return!!this._def.checks.find(e=>e.kind==="cidr")}get isBase64(){return!!this._def.checks.find(e=>e.kind==="base64")}get isBase64url(){return!!this._def.checks.find(e=>e.kind==="base64url")}get minLength(){let e=null;for(const r of this._def.checks)r.kind==="min"&&(e===null||r.value>e)&&(e=r.value);return e}get maxLength(){let e=null;for(const r of this._def.checks)r.kind==="max"&&(e===null||r.value<e)&&(e=r.value);return e}}Z.create=t=>new Z({checks:[],typeName:m.ZodString,coerce:t?.coerce??!1,...y(t)});function Ar(t,e){const r=(t.toString().split(".")[1]||"").length,a=(e.toString().split(".")[1]||"").length,n=r>a?r:a,o=Number.parseInt(t.toFixed(n).replace(".","")),s=Number.parseInt(e.toFixed(n).replace(".",""));return o%s/10**n}class U extends b{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(e){if(this._def.coerce&&(e.data=Number(e.data)),this._getType(e)!==l.number){const o=this._getOrReturnCtx(e);return c(o,{code:d.invalid_type,expected:l.number,received:o.parsedType}),g}let a;const n=new O;for(const o of this._def.checks)o.kind==="int"?x.isInteger(e.data)||(a=this._getOrReturnCtx(e,a),c(a,{code:d.invalid_type,expected:"integer",received:"float",message:o.message}),n.dirty()):o.kind==="min"?(o.inclusive?e.data<o.value:e.data<=o.value)&&(a=this._getOrReturnCtx(e,a),c(a,{code:d.too_small,minimum:o.value,type:"number",inclusive:o.inclusive,exact:!1,message:o.message}),n.dirty()):o.kind==="max"?(o.inclusive?e.data>o.value:e.data>=o.value)&&(a=this._getOrReturnCtx(e,a),c(a,{code:d.too_big,maximum:o.value,type:"number",inclusive:o.inclusive,exact:!1,message:o.message}),n.dirty()):o.kind==="multipleOf"?Ar(e.data,o.value)!==0&&(a=this._getOrReturnCtx(e,a),c(a,{code:d.not_multiple_of,multipleOf:o.value,message:o.message}),n.dirty()):o.kind==="finite"?Number.isFinite(e.data)||(a=this._getOrReturnCtx(e,a),c(a,{code:d.not_finite,message:o.message}),n.dirty()):x.assertNever(o);return{status:n.value,value:e.data}}gte(e,r){return this.setLimit("min",e,!0,u.toString(r))}gt(e,r){return this.setLimit("min",e,!1,u.toString(r))}lte(e,r){return this.setLimit("max",e,!0,u.toString(r))}lt(e,r){return this.setLimit("max",e,!1,u.toString(r))}setLimit(e,r,a,n){return new U({...this._def,checks:[...this._def.checks,{kind:e,value:r,inclusive:a,message:u.toString(n)}]})}_addCheck(e){return new U({...this._def,checks:[...this._def.checks,e]})}int(e){return this._addCheck({kind:"int",message:u.toString(e)})}positive(e){return this._addCheck({kind:"min",value:0,inclusive:!1,message:u.toString(e)})}negative(e){return this._addCheck({kind:"max",value:0,inclusive:!1,message:u.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:0,inclusive:!0,message:u.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:0,inclusive:!0,message:u.toString(e)})}multipleOf(e,r){return this._addCheck({kind:"multipleOf",value:e,message:u.toString(r)})}finite(e){return this._addCheck({kind:"finite",message:u.toString(e)})}safe(e){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:u.toString(e)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:u.toString(e)})}get minValue(){let e=null;for(const r of this._def.checks)r.kind==="min"&&(e===null||r.value>e)&&(e=r.value);return e}get maxValue(){let e=null;for(const r of this._def.checks)r.kind==="max"&&(e===null||r.value<e)&&(e=r.value);return e}get isInt(){return!!this._def.checks.find(e=>e.kind==="int"||e.kind==="multipleOf"&&x.isInteger(e.value))}get isFinite(){let e=null,r=null;for(const a of this._def.checks){if(a.kind==="finite"||a.kind==="int"||a.kind==="multipleOf")return!0;a.kind==="min"?(r===null||a.value>r)&&(r=a.value):a.kind==="max"&&(e===null||a.value<e)&&(e=a.value)}return Number.isFinite(r)&&Number.isFinite(e)}}U.create=t=>new U({checks:[],typeName:m.ZodNumber,coerce:t?.coerce||!1,...y(t)});class q extends b{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(e){if(this._def.coerce)try{e.data=BigInt(e.data)}catch{return this._getInvalidInput(e)}if(this._getType(e)!==l.bigint)return this._getInvalidInput(e);let a;const n=new O;for(const o of this._def.checks)o.kind==="min"?(o.inclusive?e.data<o.value:e.data<=o.value)&&(a=this._getOrReturnCtx(e,a),c(a,{code:d.too_small,type:"bigint",minimum:o.value,inclusive:o.inclusive,message:o.message}),n.dirty()):o.kind==="max"?(o.inclusive?e.data>o.value:e.data>=o.value)&&(a=this._getOrReturnCtx(e,a),c(a,{code:d.too_big,type:"bigint",maximum:o.value,inclusive:o.inclusive,message:o.message}),n.dirty()):o.kind==="multipleOf"?e.data%o.value!==BigInt(0)&&(a=this._getOrReturnCtx(e,a),c(a,{code:d.not_multiple_of,multipleOf:o.value,message:o.message}),n.dirty()):x.assertNever(o);return{status:n.value,value:e.data}}_getInvalidInput(e){const r=this._getOrReturnCtx(e);return c(r,{code:d.invalid_type,expected:l.bigint,received:r.parsedType}),g}gte(e,r){return this.setLimit("min",e,!0,u.toString(r))}gt(e,r){return this.setLimit("min",e,!1,u.toString(r))}lte(e,r){return this.setLimit("max",e,!0,u.toString(r))}lt(e,r){return this.setLimit("max",e,!1,u.toString(r))}setLimit(e,r,a,n){return new q({...this._def,checks:[...this._def.checks,{kind:e,value:r,inclusive:a,message:u.toString(n)}]})}_addCheck(e){return new q({...this._def,checks:[...this._def.checks,e]})}positive(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:u.toString(e)})}negative(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:u.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:u.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:u.toString(e)})}multipleOf(e,r){return this._addCheck({kind:"multipleOf",value:e,message:u.toString(r)})}get minValue(){let e=null;for(const r of this._def.checks)r.kind==="min"&&(e===null||r.value>e)&&(e=r.value);return e}get maxValue(){let e=null;for(const r of this._def.checks)r.kind==="max"&&(e===null||r.value<e)&&(e=r.value);return e}}q.create=t=>new q({checks:[],typeName:m.ZodBigInt,coerce:t?.coerce??!1,...y(t)});class ue extends b{_parse(e){if(this._def.coerce&&(e.data=!!e.data),this._getType(e)!==l.boolean){const a=this._getOrReturnCtx(e);return c(a,{code:d.invalid_type,expected:l.boolean,received:a.parsedType}),g}return R(e.data)}}ue.create=t=>new ue({typeName:m.ZodBoolean,coerce:t?.coerce||!1,...y(t)});class K extends b{_parse(e){if(this._def.coerce&&(e.data=new Date(e.data)),this._getType(e)!==l.date){const o=this._getOrReturnCtx(e);return c(o,{code:d.invalid_type,expected:l.date,received:o.parsedType}),g}if(Number.isNaN(e.data.getTime())){const o=this._getOrReturnCtx(e);return c(o,{code:d.invalid_date}),g}const a=new O;let n;for(const o of this._def.checks)o.kind==="min"?e.data.getTime()<o.value&&(n=this._getOrReturnCtx(e,n),c(n,{code:d.too_small,message:o.message,inclusive:!0,exact:!1,minimum:o.value,type:"date"}),a.dirty()):o.kind==="max"?e.data.getTime()>o.value&&(n=this._getOrReturnCtx(e,n),c(n,{code:d.too_big,message:o.message,inclusive:!0,exact:!1,maximum:o.value,type:"date"}),a.dirty()):x.assertNever(o);return{status:a.value,value:new Date(e.data.getTime())}}_addCheck(e){return new K({...this._def,checks:[...this._def.checks,e]})}min(e,r){return this._addCheck({kind:"min",value:e.getTime(),message:u.toString(r)})}max(e,r){return this._addCheck({kind:"max",value:e.getTime(),message:u.toString(r)})}get minDate(){let e=null;for(const r of this._def.checks)r.kind==="min"&&(e===null||r.value>e)&&(e=r.value);return e!=null?new Date(e):null}get maxDate(){let e=null;for(const r of this._def.checks)r.kind==="max"&&(e===null||r.value<e)&&(e=r.value);return e!=null?new Date(e):null}}K.create=t=>new K({checks:[],coerce:t?.coerce||!1,typeName:m.ZodDate,...y(t)});class Oe extends b{_parse(e){if(this._getType(e)!==l.symbol){const a=this._getOrReturnCtx(e);return c(a,{code:d.invalid_type,expected:l.symbol,received:a.parsedType}),g}return R(e.data)}}Oe.create=t=>new Oe({typeName:m.ZodSymbol,...y(t)});class Re extends b{_parse(e){if(this._getType(e)!==l.undefined){const a=this._getOrReturnCtx(e);return c(a,{code:d.invalid_type,expected:l.undefined,received:a.parsedType}),g}return R(e.data)}}Re.create=t=>new Re({typeName:m.ZodUndefined,...y(t)});class Me extends b{_parse(e){if(this._getType(e)!==l.null){const a=this._getOrReturnCtx(e);return c(a,{code:d.invalid_type,expected:l.null,received:a.parsedType}),g}return R(e.data)}}Me.create=t=>new Me({typeName:m.ZodNull,...y(t)});class Ae extends b{constructor(){super(...arguments),this._any=!0}_parse(e){return R(e.data)}}Ae.create=t=>new Ae({typeName:m.ZodAny,...y(t)});class Ne extends b{constructor(){super(...arguments),this._unknown=!0}_parse(e){return R(e.data)}}Ne.create=t=>new Ne({typeName:m.ZodUnknown,...y(t)});class L extends b{_parse(e){const r=this._getOrReturnCtx(e);return c(r,{code:d.invalid_type,expected:l.never,received:r.parsedType}),g}}L.create=t=>new L({typeName:m.ZodNever,...y(t)});class Ze extends b{_parse(e){if(this._getType(e)!==l.undefined){const a=this._getOrReturnCtx(e);return c(a,{code:d.invalid_type,expected:l.void,received:a.parsedType}),g}return R(e.data)}}Ze.create=t=>new Ze({typeName:m.ZodVoid,...y(t)});class A extends b{_parse(e){const{ctx:r,status:a}=this._processInputParams(e),n=this._def;if(r.parsedType!==l.array)return c(r,{code:d.invalid_type,expected:l.array,received:r.parsedType}),g;if(n.exactLength!==null){const s=r.data.length>n.exactLength.value,i=r.data.length<n.exactLength.value;(s||i)&&(c(r,{code:s?d.too_big:d.too_small,minimum:i?n.exactLength.value:void 0,maximum:s?n.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:n.exactLength.message}),a.dirty())}if(n.minLength!==null&&r.data.length<n.minLength.value&&(c(r,{code:d.too_small,minimum:n.minLength.value,type:"array",inclusive:!0,exact:!1,message:n.minLength.message}),a.dirty()),n.maxLength!==null&&r.data.length>n.maxLength.value&&(c(r,{code:d.too_big,maximum:n.maxLength.value,type:"array",inclusive:!0,exact:!1,message:n.maxLength.message}),a.dirty()),r.common.async)return Promise.all([...r.data].map((s,i)=>n.type._parseAsync(new N(r,s,r.path,i)))).then(s=>O.mergeArray(a,s));const o=[...r.data].map((s,i)=>n.type._parseSync(new N(r,s,r.path,i)));return O.mergeArray(a,o)}get element(){return this._def.type}min(e,r){return new A({...this._def,minLength:{value:e,message:u.toString(r)}})}max(e,r){return new A({...this._def,maxLength:{value:e,message:u.toString(r)}})}length(e,r){return new A({...this._def,exactLength:{value:e,message:u.toString(r)}})}nonempty(e){return this.min(1,e)}}A.create=(t,e)=>new A({type:t,minLength:null,maxLength:null,exactLength:null,typeName:m.ZodArray,...y(e)});function P(t){if(t instanceof C){const e={};for(const r in t.shape){const a=t.shape[r];e[r]=z.create(P(a))}return new C({...t._def,shape:()=>e})}else return t instanceof A?new A({...t._def,type:P(t.element)}):t instanceof z?z.create(P(t.unwrap())):t instanceof H?H.create(P(t.unwrap())):t instanceof $?$.create(t.items.map(e=>P(e))):t}class C extends b{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;const e=this._def.shape(),r=x.objectKeys(e);return this._cached={shape:e,keys:r},this._cached}_parse(e){if(this._getType(e)!==l.object){const p=this._getOrReturnCtx(e);return c(p,{code:d.invalid_type,expected:l.object,received:p.parsedType}),g}const{status:a,ctx:n}=this._processInputParams(e),{shape:o,keys:s}=this._getCached(),i=[];if(!(this._def.catchall instanceof L&&this._def.unknownKeys==="strip"))for(const p in n.data)s.includes(p)||i.push(p);const f=[];for(const p of s){const _=o[p],E=n.data[p];f.push({key:{status:"valid",value:p},value:_._parse(new N(n,E,n.path,p)),alwaysSet:p in n.data})}if(this._def.catchall instanceof L){const p=this._def.unknownKeys;if(p==="passthrough")for(const _ of i)f.push({key:{status:"valid",value:_},value:{status:"valid",value:n.data[_]}});else if(p==="strict")i.length>0&&(c(n,{code:d.unrecognized_keys,keys:i}),a.dirty());else if(p!=="strip")throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{const p=this._def.catchall;for(const _ of i){const E=n.data[_];f.push({key:{status:"valid",value:_},value:p._parse(new N(n,E,n.path,_)),alwaysSet:_ in n.data})}}return n.common.async?Promise.resolve().then(async()=>{const p=[];for(const _ of f){const E=await _.key,J=await _.value;p.push({key:E,value:J,alwaysSet:_.alwaysSet})}return p}).then(p=>O.mergeObjectSync(a,p)):O.mergeObjectSync(a,f)}get shape(){return this._def.shape()}strict(e){return u.errToObj,new C({...this._def,unknownKeys:"strict",...e!==void 0?{errorMap:(r,a)=>{const n=this._def.errorMap?.(r,a).message??a.defaultError;return r.code==="unrecognized_keys"?{message:u.errToObj(e).message??n}:{message:n}}}:{}})}strip(){return new C({...this._def,unknownKeys:"strip"})}passthrough(){return new C({...this._def,unknownKeys:"passthrough"})}extend(e){return new C({...this._def,shape:()=>({...this._def.shape(),...e})})}merge(e){return new C({unknownKeys:e._def.unknownKeys,catchall:e._def.catchall,shape:()=>({...this._def.shape(),...e._def.shape()}),typeName:m.ZodObject})}setKey(e,r){return this.augment({[e]:r})}catchall(e){return new C({...this._def,catchall:e})}pick(e){const r={};for(const a of x.objectKeys(e))e[a]&&this.shape[a]&&(r[a]=this.shape[a]);return new C({...this._def,shape:()=>r})}omit(e){const r={};for(const a of x.objectKeys(this.shape))e[a]||(r[a]=this.shape[a]);return new C({...this._def,shape:()=>r})}deepPartial(){return P(this)}partial(e){const r={};for(const a of x.objectKeys(this.shape)){const n=this.shape[a];e&&!e[a]?r[a]=n:r[a]=n.optional()}return new C({...this._def,shape:()=>r})}required(e){const r={};for(const a of x.objectKeys(this.shape))if(e&&!e[a])r[a]=this.shape[a];else{let o=this.shape[a];for(;o instanceof z;)o=o._def.innerType;r[a]=o}return new C({...this._def,shape:()=>r})}keyof(){return Ue(x.objectKeys(this.shape))}}C.create=(t,e)=>new C({shape:()=>t,unknownKeys:"strip",catchall:L.create(),typeName:m.ZodObject,...y(e)});C.strictCreate=(t,e)=>new C({shape:()=>t,unknownKeys:"strict",catchall:L.create(),typeName:m.ZodObject,...y(e)});C.lazycreate=(t,e)=>new C({shape:t,unknownKeys:"strip",catchall:L.create(),typeName:m.ZodObject,...y(e)});class ee extends b{_parse(e){const{ctx:r}=this._processInputParams(e),a=this._def.options;function n(o){for(const i of o)if(i.result.status==="valid")return i.result;for(const i of o)if(i.result.status==="dirty")return r.common.issues.push(...i.ctx.common.issues),i.result;const s=o.map(i=>new I(i.ctx.common.issues));return c(r,{code:d.invalid_union,unionErrors:s}),g}if(r.common.async)return Promise.all(a.map(async o=>{const s={...r,common:{...r.common,issues:[]},parent:null};return{result:await o._parseAsync({data:r.data,path:r.path,parent:s}),ctx:s}})).then(n);{let o;const s=[];for(const f of a){const p={...r,common:{...r.common,issues:[]},parent:null},_=f._parseSync({data:r.data,path:r.path,parent:p});if(_.status==="valid")return _;_.status==="dirty"&&!o&&(o={result:_,ctx:p}),p.common.issues.length&&s.push(p.common.issues)}if(o)return r.common.issues.push(...o.ctx.common.issues),o.result;const i=s.map(f=>new I(f));return c(r,{code:d.invalid_union,unionErrors:i}),g}}get options(){return this._def.options}}ee.create=(t,e)=>new ee({options:t,typeName:m.ZodUnion,...y(e)});function he(t,e){const r=B(t),a=B(e);if(t===e)return{valid:!0,data:t};if(r===l.object&&a===l.object){const n=x.objectKeys(e),o=x.objectKeys(t).filter(i=>n.indexOf(i)!==-1),s={...t,...e};for(const i of o){const f=he(t[i],e[i]);if(!f.valid)return{valid:!1};s[i]=f.data}return{valid:!0,data:s}}else if(r===l.array&&a===l.array){if(t.length!==e.length)return{valid:!1};const n=[];for(let o=0;o<t.length;o++){const s=t[o],i=e[o],f=he(s,i);if(!f.valid)return{valid:!1};n.push(f.data)}return{valid:!0,data:n}}else return r===l.date&&a===l.date&&+t==+e?{valid:!0,data:t}:{valid:!1}}class re extends b{_parse(e){const{status:r,ctx:a}=this._processInputParams(e),n=(o,s)=>{if(Se(o)||Se(s))return g;const i=he(o.value,s.value);return i.valid?((je(o)||je(s))&&r.dirty(),{status:r.value,value:i.data}):(c(a,{code:d.invalid_intersection_types}),g)};return a.common.async?Promise.all([this._def.left._parseAsync({data:a.data,path:a.path,parent:a}),this._def.right._parseAsync({data:a.data,path:a.path,parent:a})]).then(([o,s])=>n(o,s)):n(this._def.left._parseSync({data:a.data,path:a.path,parent:a}),this._def.right._parseSync({data:a.data,path:a.path,parent:a}))}}re.create=(t,e,r)=>new re({left:t,right:e,typeName:m.ZodIntersection,...y(r)});class $ extends b{_parse(e){const{status:r,ctx:a}=this._processInputParams(e);if(a.parsedType!==l.array)return c(a,{code:d.invalid_type,expected:l.array,received:a.parsedType}),g;if(a.data.length<this._def.items.length)return c(a,{code:d.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),g;!this._def.rest&&a.data.length>this._def.items.length&&(c(a,{code:d.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),r.dirty());const o=[...a.data].map((s,i)=>{const f=this._def.items[i]||this._def.rest;return f?f._parse(new N(a,s,a.path,i)):null}).filter(s=>!!s);return a.common.async?Promise.all(o).then(s=>O.mergeArray(r,s)):O.mergeArray(r,o)}get items(){return this._def.items}rest(e){return new $({...this._def,rest:e})}}$.create=(t,e)=>{if(!Array.isArray(t))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new $({items:t,typeName:m.ZodTuple,rest:null,...y(e)})};class te extends b{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){const{status:r,ctx:a}=this._processInputParams(e);if(a.parsedType!==l.object)return c(a,{code:d.invalid_type,expected:l.object,received:a.parsedType}),g;const n=[],o=this._def.keyType,s=this._def.valueType;for(const i in a.data)n.push({key:o._parse(new N(a,i,a.path,i)),value:s._parse(new N(a,a.data[i],a.path,i)),alwaysSet:i in a.data});return a.common.async?O.mergeObjectAsync(r,n):O.mergeObjectSync(r,n)}get element(){return this._def.valueType}static create(e,r,a){return r instanceof b?new te({keyType:e,valueType:r,typeName:m.ZodRecord,...y(a)}):new te({keyType:Z.create(),valueType:e,typeName:m.ZodRecord,...y(r)})}}class Ie extends b{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){const{status:r,ctx:a}=this._processInputParams(e);if(a.parsedType!==l.map)return c(a,{code:d.invalid_type,expected:l.map,received:a.parsedType}),g;const n=this._def.keyType,o=this._def.valueType,s=[...a.data.entries()].map(([i,f],p)=>({key:n._parse(new N(a,i,a.path,[p,"key"])),value:o._parse(new N(a,f,a.path,[p,"value"]))}));if(a.common.async){const i=new Map;return Promise.resolve().then(async()=>{for(const f of s){const p=await f.key,_=await f.value;if(p.status==="aborted"||_.status==="aborted")return g;(p.status==="dirty"||_.status==="dirty")&&r.dirty(),i.set(p.value,_.value)}return{status:r.value,value:i}})}else{const i=new Map;for(const f of s){const p=f.key,_=f.value;if(p.status==="aborted"||_.status==="aborted")return g;(p.status==="dirty"||_.status==="dirty")&&r.dirty(),i.set(p.value,_.value)}return{status:r.value,value:i}}}}Ie.create=(t,e,r)=>new Ie({valueType:e,keyType:t,typeName:m.ZodMap,...y(r)});class Y extends b{_parse(e){const{status:r,ctx:a}=this._processInputParams(e);if(a.parsedType!==l.set)return c(a,{code:d.invalid_type,expected:l.set,received:a.parsedType}),g;const n=this._def;n.minSize!==null&&a.data.size<n.minSize.value&&(c(a,{code:d.too_small,minimum:n.minSize.value,type:"set",inclusive:!0,exact:!1,message:n.minSize.message}),r.dirty()),n.maxSize!==null&&a.data.size>n.maxSize.value&&(c(a,{code:d.too_big,maximum:n.maxSize.value,type:"set",inclusive:!0,exact:!1,message:n.maxSize.message}),r.dirty());const o=this._def.valueType;function s(f){const p=new Set;for(const _ of f){if(_.status==="aborted")return g;_.status==="dirty"&&r.dirty(),p.add(_.value)}return{status:r.value,value:p}}const i=[...a.data.values()].map((f,p)=>o._parse(new N(a,f,a.path,p)));return a.common.async?Promise.all(i).then(f=>s(f)):s(i)}min(e,r){return new Y({...this._def,minSize:{value:e,message:u.toString(r)}})}max(e,r){return new Y({...this._def,maxSize:{value:e,message:u.toString(r)}})}size(e,r){return this.min(e,r).max(e,r)}nonempty(e){return this.min(1,e)}}Y.create=(t,e)=>new Y({valueType:t,minSize:null,maxSize:null,typeName:m.ZodSet,...y(e)});class Ee extends b{get schema(){return this._def.getter()}_parse(e){const{ctx:r}=this._processInputParams(e);return this._def.getter()._parse({data:r.data,path:r.path,parent:r})}}Ee.create=(t,e)=>new Ee({getter:t,typeName:m.ZodLazy,...y(e)});class fe extends b{_parse(e){if(e.data!==this._def.value){const r=this._getOrReturnCtx(e);return c(r,{received:r.data,code:d.invalid_literal,expected:this._def.value}),g}return{status:"valid",value:e.data}}get value(){return this._def.value}}fe.create=(t,e)=>new fe({value:t,typeName:m.ZodLiteral,...y(e)});function Ue(t,e){return new W({values:t,typeName:m.ZodEnum,...y(e)})}class W extends b{_parse(e){if(typeof e.data!="string"){const r=this._getOrReturnCtx(e),a=this._def.values;return c(r,{expected:x.joinValues(a),received:r.parsedType,code:d.invalid_type}),g}if(this._cache||(this._cache=new Set(this._def.values)),!this._cache.has(e.data)){const r=this._getOrReturnCtx(e),a=this._def.values;return c(r,{received:r.data,code:d.invalid_enum_value,options:a}),g}return R(e.data)}get options(){return this._def.values}get enum(){const e={};for(const r of this._def.values)e[r]=r;return e}get Values(){const e={};for(const r of this._def.values)e[r]=r;return e}get Enum(){const e={};for(const r of this._def.values)e[r]=r;return e}extract(e,r=this._def){return W.create(e,{...this._def,...r})}exclude(e,r=this._def){return W.create(this.options.filter(a=>!e.includes(a)),{...this._def,...r})}}W.create=Ue;class Be extends b{_parse(e){const r=x.getValidEnumValues(this._def.values),a=this._getOrReturnCtx(e);if(a.parsedType!==l.string&&a.parsedType!==l.number){const n=x.objectValues(r);return c(a,{expected:x.joinValues(n),received:a.parsedType,code:d.invalid_type}),g}if(this._cache||(this._cache=new Set(x.getValidEnumValues(this._def.values))),!this._cache.has(e.data)){const n=x.objectValues(r);return c(a,{received:a.data,code:d.invalid_enum_value,options:n}),g}return R(e.data)}get enum(){return this._def.values}}Be.create=(t,e)=>new Be({values:t,typeName:m.ZodNativeEnum,...y(e)});class ae extends b{unwrap(){return this._def.type}_parse(e){const{ctx:r}=this._processInputParams(e);if(r.parsedType!==l.promise&&r.common.async===!1)return c(r,{code:d.invalid_type,expected:l.promise,received:r.parsedType}),g;const a=r.parsedType===l.promise?r.data:Promise.resolve(r.data);return R(a.then(n=>this._def.type.parseAsync(n,{path:r.path,errorMap:r.common.contextualErrorMap})))}}ae.create=(t,e)=>new ae({type:t,typeName:m.ZodPromise,...y(e)});class F extends b{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===m.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(e){const{status:r,ctx:a}=this._processInputParams(e),n=this._def.effect||null,o={addIssue:s=>{c(a,s),s.fatal?r.abort():r.dirty()},get path(){return a.path}};if(o.addIssue=o.addIssue.bind(o),n.type==="preprocess"){const s=n.transform(a.data,o);if(a.common.async)return Promise.resolve(s).then(async i=>{if(r.value==="aborted")return g;const f=await this._def.schema._parseAsync({data:i,path:a.path,parent:a});return f.status==="aborted"?g:f.status==="dirty"||r.value==="dirty"?G(f.value):f});{if(r.value==="aborted")return g;const i=this._def.schema._parseSync({data:s,path:a.path,parent:a});return i.status==="aborted"?g:i.status==="dirty"||r.value==="dirty"?G(i.value):i}}if(n.type==="refinement"){const s=i=>{const f=n.refinement(i,o);if(a.common.async)return Promise.resolve(f);if(f instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return i};if(a.common.async===!1){const i=this._def.schema._parseSync({data:a.data,path:a.path,parent:a});return i.status==="aborted"?g:(i.status==="dirty"&&r.dirty(),s(i.value),{status:r.value,value:i.value})}else return this._def.schema._parseAsync({data:a.data,path:a.path,parent:a}).then(i=>i.status==="aborted"?g:(i.status==="dirty"&&r.dirty(),s(i.value).then(()=>({status:r.value,value:i.value}))))}if(n.type==="transform")if(a.common.async===!1){const s=this._def.schema._parseSync({data:a.data,path:a.path,parent:a});if(!V(s))return g;const i=n.transform(s.value,o);if(i instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:r.value,value:i}}else return this._def.schema._parseAsync({data:a.data,path:a.path,parent:a}).then(s=>V(s)?Promise.resolve(n.transform(s.value,o)).then(i=>({status:r.value,value:i})):g);x.assertNever(n)}}F.create=(t,e,r)=>new F({schema:t,typeName:m.ZodEffects,effect:e,...y(r)});F.createWithPreprocess=(t,e,r)=>new F({schema:e,effect:{type:"preprocess",transform:t},typeName:m.ZodEffects,...y(r)});class z extends b{_parse(e){return this._getType(e)===l.undefined?R(void 0):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}z.create=(t,e)=>new z({innerType:t,typeName:m.ZodOptional,...y(e)});class H extends b{_parse(e){return this._getType(e)===l.null?R(null):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}H.create=(t,e)=>new H({innerType:t,typeName:m.ZodNullable,...y(e)});class pe extends b{_parse(e){const{ctx:r}=this._processInputParams(e);let a=r.data;return r.parsedType===l.undefined&&(a=this._def.defaultValue()),this._def.innerType._parse({data:a,path:r.path,parent:r})}removeDefault(){return this._def.innerType}}pe.create=(t,e)=>new pe({innerType:t,typeName:m.ZodDefault,defaultValue:typeof e.default=="function"?e.default:()=>e.default,...y(e)});class me extends b{_parse(e){const{ctx:r}=this._processInputParams(e),a={...r,common:{...r.common,issues:[]}},n=this._def.innerType._parse({data:a.data,path:a.path,parent:{...a}});return Q(n)?n.then(o=>({status:"valid",value:o.status==="valid"?o.value:this._def.catchValue({get error(){return new I(a.common.issues)},input:a.data})})):{status:"valid",value:n.status==="valid"?n.value:this._def.catchValue({get error(){return new I(a.common.issues)},input:a.data})}}removeCatch(){return this._def.innerType}}me.create=(t,e)=>new me({innerType:t,typeName:m.ZodCatch,catchValue:typeof e.catch=="function"?e.catch:()=>e.catch,...y(e)});class ze extends b{_parse(e){if(this._getType(e)!==l.nan){const a=this._getOrReturnCtx(e);return c(a,{code:d.invalid_type,expected:l.nan,received:a.parsedType}),g}return{status:"valid",value:e.data}}}ze.create=t=>new ze({typeName:m.ZodNaN,...y(t)});class Nr extends b{_parse(e){const{ctx:r}=this._processInputParams(e),a=r.data;return this._def.type._parse({data:a,path:r.path,parent:r})}unwrap(){return this._def.type}}class ke extends b{_parse(e){const{status:r,ctx:a}=this._processInputParams(e);if(a.common.async)return(async()=>{const o=await this._def.in._parseAsync({data:a.data,path:a.path,parent:a});return o.status==="aborted"?g:o.status==="dirty"?(r.dirty(),G(o.value)):this._def.out._parseAsync({data:o.value,path:a.path,parent:a})})();{const n=this._def.in._parseSync({data:a.data,path:a.path,parent:a});return n.status==="aborted"?g:n.status==="dirty"?(r.dirty(),{status:"dirty",value:n.value}):this._def.out._parseSync({data:n.value,path:a.path,parent:a})}}static create(e,r){return new ke({in:e,out:r,typeName:m.ZodPipeline})}}class ge extends b{_parse(e){const r=this._def.innerType._parse(e),a=n=>(V(n)&&(n.value=Object.freeze(n.value)),n);return Q(r)?r.then(n=>a(n)):a(r)}unwrap(){return this._def.innerType}}ge.create=(t,e)=>new ge({innerType:t,typeName:m.ZodReadonly,...y(e)});var m;(function(t){t.ZodString="ZodString",t.ZodNumber="ZodNumber",t.ZodNaN="ZodNaN",t.ZodBigInt="ZodBigInt",t.ZodBoolean="ZodBoolean",t.ZodDate="ZodDate",t.ZodSymbol="ZodSymbol",t.ZodUndefined="ZodUndefined",t.ZodNull="ZodNull",t.ZodAny="ZodAny",t.ZodUnknown="ZodUnknown",t.ZodNever="ZodNever",t.ZodVoid="ZodVoid",t.ZodArray="ZodArray",t.ZodObject="ZodObject",t.ZodUnion="ZodUnion",t.ZodDiscriminatedUnion="ZodDiscriminatedUnion",t.ZodIntersection="ZodIntersection",t.ZodTuple="ZodTuple",t.ZodRecord="ZodRecord",t.ZodMap="ZodMap",t.ZodSet="ZodSet",t.ZodFunction="ZodFunction",t.ZodLazy="ZodLazy",t.ZodLiteral="ZodLiteral",t.ZodEnum="ZodEnum",t.ZodEffects="ZodEffects",t.ZodNativeEnum="ZodNativeEnum",t.ZodOptional="ZodOptional",t.ZodNullable="ZodNullable",t.ZodDefault="ZodDefault",t.ZodCatch="ZodCatch",t.ZodPromise="ZodPromise",t.ZodBranded="ZodBranded",t.ZodPipeline="ZodPipeline",t.ZodReadonly="ZodReadonly"})(m||(m={}));const h=Z.create,ve=U.create,Hr=ue.create;L.create;const Zr=A.create,S=C.create,be=ee.create;re.create;$.create;const _e=te.create,Gr=fe.create,We=W.create;ae.create;z.create;H.create;const Ir=S({minRem:ve(),maxRem:ve()}),T=Ir.or(h()),X=S({0:h().optional(),50:h(),100:h(),200:h(),300:h(),400:h(),500:h(),600:h(),700:h(),800:h(),900:h(),950:h(),1e3:h().optional()}),de=S({color:h().optional(),background:h().optional(),borderWidth:h().optional(),borderColor:h().optional(),boxShadow:h().optional()}),Er=S({borderRadius:T.optional(),custom:_e(h(),be([h(),ve()])).optional(),hover:de.optional(),focus:de.optional()}).and(de),Br=S({family:h().optional()}),zr=_e(We(["predefinedQuestion","edit","newConversation","voteUp","voteDown","retry","message","messageLoading","thread","submit","abort","expand","help","attach","record","reward","share","audio","copy","dismiss","menu","info","menuClose","chevronDown","chevronUp","chevronTopDown","chevronDownSmall","internalLink","externalLink","liip","avatar","avatarLarge","openChat","speechInput","listUnordered","lightMode","darkMode","avatarLarge","settings","settingsClose","sources","model","checkbox"]),h()),Lr=S({font:Br.optional(),colors:S({brand:X,accent:X.optional(),highlight:X,grey:X}),base:S({fontSizeXs:T.optional(),fontSizeSm:T.optional(),fontSizeBody:T.optional(),fontSizeH3:T.optional(),fontSizeH2:T.optional(),fontSizeH1:T.optional(),fontWeightNormal:h().optional(),fontWeightBold:h().optional(),fontWeightTitle:h().optional(),lineHeightDefault:h().optional(),lineHeightSnug:h().optional(),lineHeightTight:h().optional(),borderRadius:T.optional(),lineColor:h().optional(),boxShadow:h().optional()}),components:_e(h(),Er),svgs:zr}),ne=S({customCSS:h().optional(),fontCSS:h().optional(),fontURLs:h().array().optional(),tokens:Lr});S({light:ne,dark:ne});const $r=S({light:ne,dark:ne}).deepPartial(),Fe=S({50:h(),100:h(),200:h(),300:h(),400:h(),500:h(),600:h(),700:h(),800:h(),900:h(),950:h()}),He=We(["slate","gray","zinc","neutral","stone","red","orange","amber","yellow","lime","green","emerald","teal","cyan","sky","blue","indigo","violet","purple","fuchsia","pink","rose"]),Le=be([Fe,He]),Dr=be([Fe.and(S({0:h(),1e3:h()})),He]),Pr=S({avatarImageUrl:h().optional(),colors:S({brand:Le.optional(),highlight:Le.optional(),grey:Dr.optional(),background:h().optional(),text:h().optional(),anchor:S({default:h().optional(),hover:h().optional()}).optional()}).optional(),font:S({family:h().optional(),urls:Zr(h()).optional(),sizeXs:T.optional(),sizeSm:T.optional(),sizeBody:T.optional(),sizeH3:T.optional(),sizeH2:T.optional(),sizeH1:T.optional(),weightNormal:h().optional(),weightBold:h().optional(),weightTitle:h().optional()}).optional(),borderRadius:T.optional(),fineGrained:$r.optional()}),Vr=t=>t.split("/").pop().split(".")[0],Ur=Object.assign({"./default/fallback-dev.theme.ts":sr,"./default/fallback.theme.ts":nr}),xe=new Map;Object.entries(Ur).forEach(([t,e])=>{const{error:r,data:a}=Pr.safeParse(e?.theme);if(r){console.error(`Invalid theme in ${t}:`,r);return}xe.set(Vr(t),a)});const qr=t=>{const e=xe.get(t);return e||(console.error(`Theme ${t} not found`),oe)};Array.from(xe.keys());export{Wr as P,Zr as a,Hr as b,Pr as c,er as d,We as e,Vr as f,Xe as g,qr as h,Fr as i,Gr as l,tr as m,ve as n,S as o,_e as r,h as s,oe as t,be as u};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import"./NZTpNUN0.js";import{p as m,F as y,d as f,v as r,G as S,H as d,c as h}from"./
|
|
1
|
+
import"./NZTpNUN0.js";import{p as m,F as y,d as f,v as r,G as S,H as d,c as h}from"./Cx_YT9bD.js";import{p as n,s as _}from"./DePuinxN.js";import{E as T}from"./CMMtw-vR.js";import{O as k}from"./qZ4Lj-J3.js";function C(c,e){m(e,!0);let o=n(e,"onclick",7),u=n(e,"buttonClass",7),l=n(e,"buttonStyle",7),s=n(e,"apiUrl",7),a=n(e,"forceTheme",7),i=n(e,"lang",7),b=d(()=>({onclick:o(),buttonClass:u(),buttonStyle:l(),apiUrl:s(),forceTheme:a(),lang:i()}));return T(c,{silent:!0,body:(g,p=y)=>{k(g,_({host:e.$$host,get onError(){return p()}},()=>S(b)))},$$slots:{body:!0}}),f({get onclick(){return o()},set onclick(t){o(t),r()},get buttonClass(){return u()},set buttonClass(t){u(t),r()},get buttonStyle(){return l()},set buttonStyle(t){l(t),r()},get apiUrl(){return s()},set apiUrl(t){s(t),r()},get forceTheme(){return a()},set forceTheme(t){a(t),r()},get lang(){return i()},set lang(t){i(t),r()}})}customElements.define("liipgpt-button",h(C,{forceTheme:{attribute:"force-theme",type:"String"},buttonClass:{attribute:"button-class",type:"String"},buttonStyle:{attribute:"button-style",type:"String"},apiUrl:{attribute:"api-url",type:"String"},lang:{attribute:"lang",type:"String"},onclick:{}},[],[],!0));export{C as LiipGPTButton};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import"./NZTpNUN0.js";import{p as k,F as B,G as d,H as m,d as T,v as r,c as A}from"./
|
|
1
|
+
import"./NZTpNUN0.js";import{p as k,F as B,G as d,H as m,d as T,v as r,c as A}from"./Cx_YT9bD.js";import{p as o,s as R}from"./DePuinxN.js";import{C as U}from"./qjMtaNLq.js";import{E as _}from"./CMMtw-vR.js";function E(S,t){k(t,!0);let a=o(t,"forceTheme",7),l=o(t,"apiUrl",7),i=o(t,"apiKey",7),u=o(t,"speechRecognitionApiKey",7),n=o(t,"lang",7),y=o(t,"features",7),s=o(t,"loaderBackground",7),g=o(t,"loaderColor",7),f=o(t,"flyout",7),c=o(t,"flyoutStyle",7),p=o(t,"flyoutClass",7),h=m(()=>({forceTheme:a(),apiUrl:l(),apiKey:i(),speechRecognitionApiKey:u(),lang:n(),features:y(),loaderBackground:s(),loaderColor:g(),flyout:f(),flyoutStyle:c(),flyoutClass:p()}));{const e=(b,K=B)=>{U(b,R({host:t.$$host,get onError(){return K()}},()=>d(h)))};let C=m(()=>d(h).flyout??!1);_(S,{get silent(){return d(C)},body:e,$$slots:{body:!0}})}return T({get forceTheme(){return a()},set forceTheme(e){a(e),r()},get apiUrl(){return l()},set apiUrl(e){l(e),r()},get apiKey(){return i()},set apiKey(e){i(e),r()},get speechRecognitionApiKey(){return u()},set speechRecognitionApiKey(e){u(e),r()},get lang(){return n()},set lang(e){n(e),r()},get features(){return y()},set features(e){y(e),r()},get loaderBackground(){return s()},set loaderBackground(e){s(e),r()},get loaderColor(){return g()},set loaderColor(e){g(e),r()},get flyout(){return f()},set flyout(e){f(e),r()},get flyoutStyle(){return c()},set flyoutStyle(e){c(e),r()},get flyoutClass(){return p()},set flyoutClass(e){p(e),r()}})}customElements.define("liipgpt-chat",A(E,{forceTheme:{attribute:"force-theme",type:"String"},apiUrl:{attribute:"api-url",type:"String"},apiKey:{attribute:"api-key",type:"String"},speechRecognitionApiKey:{attribute:"speech-recognition-api-key",type:"String"},lang:{attribute:"lang",type:"String"},features:{attribute:"features",type:"String"},loaderBackground:{attribute:"loader-background",type:"String"},loaderColor:{attribute:"loader-color",type:"String"},flyout:{attribute:"flyout",type:"Boolean"},flyoutStyle:{attribute:"flyout-style",type:"String"},flyoutClass:{attribute:"flyout-class",type:"String"}},[],[],!0));export{E as LiipGPTChat};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{G as S,T as m,U as A,V as D,M as T,W as L,X as Y,Y as B,Z as c,_ as O,$ as I,a0 as g,a1 as M,a2 as U,a3 as j,a4 as K,o as N,n as $,a5 as G,a6 as Z}from"./Cx_YT9bD.js";let p=!1;function q(e){var r=p;try{return p=!1,[e(),p]}finally{p=r}}const z={get(e,r){if(!e.exclude.includes(r))return e.props[r]},set(e,r){return!1},getOwnPropertyDescriptor(e,r){if(!e.exclude.includes(r)&&r in e.props)return{enumerable:!0,configurable:!0,value:e.props[r]}},has(e,r){return e.exclude.includes(r)?!1:r in e.props},ownKeys(e){return Reflect.ownKeys(e.props).filter(r=>!e.exclude.includes(r))}};function W(e,r,t){return new Proxy({props:e,exclude:r},z)}const C={get(e,r){let t=e.props.length;for(;t--;){let n=e.props[t];if(c(n)&&(n=n()),typeof n=="object"&&n!==null&&r in n)return n[r]}},set(e,r,t){let n=e.props.length;for(;n--;){let i=e.props[n];c(i)&&(i=i());const u=g(i,r);if(u&&u.set)return u.set(t),!0}return!1},getOwnPropertyDescriptor(e,r){let t=e.props.length;for(;t--;){let n=e.props[t];if(c(n)&&(n=n()),typeof n=="object"&&n!==null&&r in n){const i=g(n,r);return i&&!i.configurable&&(i.configurable=!0),i}}},has(e,r){if(r===O||r===I)return!1;for(let t of e.props)if(c(t)&&(t=t()),t!=null&&r in t)return!0;return!1},ownKeys(e){const r=[];for(let t of e.props)if(c(t)&&(t=t()),!!t){for(const n in t)r.includes(n)||r.push(n);for(const n of Object.getOwnPropertySymbols(t))r.includes(n)||r.push(n)}return r}};function X(...e){return new Proxy({props:e},C)}function F(e,r,t,n){var i=!$||(t&G)!==0,u=(t&K)!==0,y=(t&Z)!==0,f=n,v=!0,b=()=>(v&&(v=!1,f=y?N(n):n),f),l;if(u){var R=O in e||I in e;l=g(e,r)?.set??(R&&r in e?s=>e[r]=s:void 0)}var o,h=!1;u?[o,h]=q(()=>e[r]):o=e[r],o===void 0&&n!==void 0&&(o=b(),l&&(i&&M(),l(o)));var a;if(i?a=()=>{var s=e[r];return s===void 0?b():(v=!0,s)}:a=()=>{var s=e[r];return s!==void 0&&(f=void 0),s===void 0?f:s},i&&(t&U)===0)return a;if(l){var x=e.$$legacy;return function(s,_){return arguments.length>0?((!i||!_||x||h)&&l(_?a():s),s):a()}}var P=!1,d=((t&j)!==0?T:B)(()=>(P=!1,a()));u&&S(d);var E=A;return function(s,_){if(arguments.length>0){const w=_?S(d):i&&u?Y(s):s;return m(d,w),P=!0,f!==void 0&&(f=w),s}return L&&P||(E.f&D)!==0?d.v:S(d)}}export{F as p,W as r,X as s};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a7 as r}from"./Cx_YT9bD.js";import{s as t,p as e}from"./Bp3niLsp.js";r();const a={get error(){return e.error},get status(){return e.status},get url(){return e.url}};t.updated.check;const p=a;export{p};
|