PageSourceSearch

https://hq.fieldedgeapp.com/assets/vendor-ui-DSgpZMyZ.js

js fieldedgeapp.com collected 2026-10-07 11:40:38 UTC 409,577 bytes, 42 lines download raw bytes

vendor: 4,354 bytes, line 1
1import{r as l,j as E,t as kn,a as Te,d as Cc,R as w}from"./vendor-react-WodaM8AR.js";import{R as lr,h as cr,u as Sc,o as ia,s as Pc,f as Mc,a as Tc,b as Jh,c as em,d as kc,l as tm,e as nm,i as om,g as la,t as An,j as ca,k as Rc,n as Dc,m as Be,p as to,q as Ie,r as cn,K as rm,v as ua,w as ke,x as Gt,y as sm,z as am,A as im,B as _s,C as lm,S as Ic,D as da,E as cm,F as um,G as dm,H as fm,M as Go,I as fa,J as Wo,L as Fi,N as pm,O as hm,P as mm,Q as Oc,T as Je,U as Ac,V as vm,W as Ns,X as _c,Y as gm,Z as Yo,_ as Pn,$ as Nc,a0 as $c,a1 as ym,a2 as bm,a3 as xm,a4 as rs,a5 as wm,a6 as Em,a7 as ss,a8 as Cm,a9 as Sm,aa as zo,ab as $o,ac as Pm,ad as as,ae as is,af as Mm,ag as Tm,ah as zt,ai as hn,aj as km}from"./vendor-misc-Dyk2Lweh.js";import{e as zn,f as Qn,a as Rm,b as Dm,c as Im,d as Om,g as Am,h as _m,i as Nm,j as $m,k as Fm,l as Lm,m as jm,n as Bm,o as Vm,p as Wm,q as Hm,r as Um,s as Gm,t as Ym,u as zm,v as Km,w as qm,x as Xm,y as Zm,z as Qm,A as Jm,B as ev,C as tv,D as nv,E as ov,F as rv,G as sv}from"./vendor-data-Cjdh6TND.js";function Li(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function ze(...e){return t=>{let n=!1;const o=e.map(r=>{const s=Li(r,t);return!n&&typeof s=="function"&&(n=!0),s});if(n)return()=>{for(let r=0;r<o.length;r++){const s=o[r];typeof s=="function"?s():Li(e[r],null)}}}}function he(...e){return l.useCallback(ze(...e),e)}var av=Symbol.for("react.lazy"),Ko=kn[" use ".trim().toString()];function iv(e){return typeof e=="object"&&e!==null&&"then"in e}function Fc(e){return e!=null&&typeof e=="object"&&"$$typeof"in e&&e.$$typeof===av&&"_payload"in e&&iv(e._payload)}function ur(e){const t=lv(e),n=l.forwardRef((o,r)=>{let{children:s,...a}=o;Fc(s)&&typeof Ko=="function"&&(s=Ko(s._payload));const i=l.Children.toArray(s),c=i.find(uv);if(c){const u=c.props.children,d=i.map(f=>f===c?l.Children.count(u)>1?l.Children.only(null):l.isValidElement(u)?u.props.children:null:f);return E.jsx(t,{...a,ref:r,children:l.isValidElement(u)?l.cloneElement(u,void 0,d):null})}return E.jsx(t,{...a,ref:r,children:s})});return n.displayName=`${e}.Slot`,n}var vD=ur("Slot");function lv(e){const t=l.forwardRef((n,o)=>{let{children:r,...s}=n;if(Fc(r)&&typeof Ko=="function"&&(r=Ko(r._payload)),l.isValidElement(r)){const a=fv(r),i=dv(s,r.props);return r.type!==l.Fragment&&(i.ref=o?ze(o,a):a),l.cloneElement(r,i)}return l.Children.count(r)>1?l.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var cv=Symbol("radix.slottable");function uv(e){return l.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===cv}function dv(e,t){const n={...t};for(const o in t){const r=e[o],s=t[o];/^on[A-Z]/.test(o)?r&&s?n[o]=(...i)=>{const c=s(...i);return r(...i),c}:r&&(n[o]=r):o==="style"?n[o]={...r,...s}:o==="className"&&(n[o]=[r,s].filter(Boolean).join(" "))}return{...e,...n}}function fv(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}const pv=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),hv=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(t,n,o)=>o?o.toUpperCase():n.toLowerCase()),ji=e=>{const t=hv(e);return t.charAt(0).toUpperCase()+t.slice(1)},Lc=(...e)=>e.filter((t,n,o)=>!!t&&t.trim()!==""&&o.indexOf(t)===n).join(" ").trim(),mv=e=>{for(const t in e)if(t.startsWith("aria-")||t==="role"||t==="title")return!0};var vv={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};const gv=l.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:o,className:r="",children:s,iconNode:a,...i},c)=>l.createElement("svg",{ref:c,...vv,width:t,height:t,stroke:e,strokeWidth:o?Number(n)*24/Number(t):n,className:Lc("lucide",r),...!s&&!mv(i)&&{"aria-hidden":"true"},...i},[...a.map(([u,d])=>l.createElement(u,d)),...Array.isArray(s)?s:[s]]));const X=(e,t)=>{const n=l.forwardRef(({className:o,...r},s)=>l.createElement(gv,{ref:s,iconNode:t,className:Lc(`lucide-${pv(ji(e))}`,`lucide-${e}`,o),...r}));return n.displayName=ji(e),n};const yv=[["path",{d:"M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l
1-2.35 8.36A2 2 0 0 1 4.49 12H2",key:"169zse"}]],gD=X("activity",yv);const bv=[["path",{d:"M12 5v14",key:"s699le"}],["path",{d:"m19 12-7 7-7-7",key:"1idqje"}]],yD=X("arrow-down",bv);const xv=[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]],bD=X("arrow-left",xv);const wv=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]],xD=X("arrow-right",wv);const Ev=[["path",{d:"m21 16-4 4-4-4",key:"f6ql7i"}],["path",{d:"M17 20V4",key:"1ejh1v"}],["path",{d:"m3 8 4-4 4 4",key:"11wl7u"}],["path",{d:"M7 4v16",key:"1glfcx"}]],wD=X("arrow-up-down",Ev);const Cv=[["path",{d:"M7 7h10v10",key:"1tivn9"}],["path",{d:"M7 17 17 7",key:"1vkiza"}]],ED=X("arrow-up-right",Cv);const Sv=[["path",{d:"m5 12 7-7 7 7",key:"hav0vg"}],["path",{d:"M12 19V5",key:"x0mq9r"}]],CD=X("arrow-up",Sv);const Pv=[["path",{d:"M3.85 8.62a4 4 0 0 1 4.78-4.77 4 4 0 0 1 6.74 0 4 4 0 0 1 4.78 4.78 4 4 0 0 1 0 6.74 4 4 0 0 1-4.77 4.78 4 4 0 0 1-6.75 0 4 4 0 0 1-4.78-4.77 4 4 0 0 1 0-6.76Z",key:"3c2336"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]],SD=X("badge-check",Pv);const Mv=[["path",{d:"M12 7v14",key:"1akyts"}],["path",{d:"M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z",key:"ruj8y"}]],PD=X("book-open",Mv);const Tv=[["path",{d:"M10 12h4",key:"a56b0p"}],["path",{d:"M10 8h4",key:"1sr2af"}],["path",{d:"M14 21v-3a2 2 0 0 0-4 0v3",key:"1rgiei"}],["path",{d:"M6 10H4a2 2 0 0 0-2 2v7a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2V9a2 2 0 0 0-2-2h-2",key:"secmi2"}],["path",{d:"M6 21V5a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v16",key:"16ra0t"}]],MD=X("building-2",Tv);const kv=[["path",{d:"M8 2v4",key:"1cmpym"}],["path",{d:"M16 2v4",key:"4m81vk"}],["rect",{width:"18",height:"18",x:"3",y:"4",rx:"2",key:"1hopcy"}],["path",{d:"M3 10h18",key:"8toen8"}]],TD=X("calendar",kv);const Rv=[["path",{d:"M3 3v16a2 2 0 0 0 2 2h16",key:"c24i48"}],["path",{d:"M18 17V9",key:"2bz60n"}],["path",{d:"M13 17V5",key:"1frdt8"}],["path",{d:"M8 17v-3",key:"17ska0"}]],kD=X("chart-column",Rv);const Dv=[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]],RD=X("check",Dv);const Iv=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],DD=X("chevron-down",Iv);const Ov=[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]],ID=X("chevron-left",Ov);const Av=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],OD=X("chevron-right",Av);const _v=[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]],AD=X("chevron-up",_v);const Nv=[["path",{d:"m7 15 5 5 5-5",key:"1hf1tw"}],["path",{d:"m7 9 5-5 5 5",key:"sgt6xg"}]],_D=X("chevrons-up-down",Nv);const $v=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]],ND=X("circle-alert",$v);const Fv=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]],$D=X("circle-check",Fv);const Lv=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3",key:"1u773s"}],["path",{d:"M12 17h.01",key:"p32p05"}]],FD=X("circle-question-mark",Lv);const jv=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]],LD=X("circle-x",jv);const Bv=[["rect",{width:"8",height:"4",x:"8",y:"2",rx:"1",ry:"1",key:"tgr4d6"}],["path",{d:"M16 4h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h2",key:"116196"}],["path",{d:"M12 11h4",key:"1jrz19"}],["path",{d:"M12 16h4",key:"n85exb"}],["path",{d:"M8 11h.01",key:"1dfujw"}],["path",{d:"M8 16h.01",key:"18s6g9"}]],jD=X("clipboard-list",Bv);const Vv=[["path",{d:"M12 6v6l4 2",key:"mmk7yg"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],BD=X("clock",Vv);const Wv=[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]],VD=X("copy",Wv);const Hv=[["rect",{width:"20",height:"14",x:"2",y:"5",rx:"2",key:"ynyp8z"}],["line",{x1:"2",x2:"22",y1:"10",y2:"10",key:"1b3vmo"}]],WD=X("credit-card",Hv);const Uv=[["path",{d:"M11 20H2",key:"nlcfvz"}],["path",{d:"M11 4.562v16.157a1 1 0 0 0 1.242.97L19 20V5.562a2 2 0 0 0-1.515-1.94l-4-1A2 2 0 0 0 11 4.561z",key:"au4z13"}],["path",{d:"M11 4H8a2 2 0 0 0-2 2v14",key:"74r1mk"}],["path",{d:"M14 12h.01",key:"1jfl7z"}],["path",{d:"M22 20h-3",key:"vhrsz"}]],HD=X("door-open",Uv);const Gv=[["path",{d:"M12 15V3",key:"m9g1x1"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["path",{d:"m7 10 5 5 5-5",key:"brsn70"}]],UD=X("download",Gv);const Yv=[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"19",cy:"12",r:"1",key:"1wjl8i"}],["circle",{cx:"5",cy:"12",r:"1",key:"1pcz8c"}]],GD=X("ellipsis",Yv);const zv=[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]],YD=X("external-link",zv);const Kv=[["path",{d:"M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49",key:"ct8e1f"}],["path",{d:"M14.084 14.158a3 3 0 0 1-4.242-4.242",key:"151rxh"}],["path",{d:"M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143",key:"13bj9a"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]],zD=X("eye-off",Kv);const qv=[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0",key:"1nclc0"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],KD=X("eye",qv);const Xv=[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M8 13h2",key:"yr2amv"}],["path",{d:"M14 13h2",key:"un5t4a"}],["path",{d:"M8 17h2",key:"2yhykz"}],["path",{d:"M14 17h2",key:"10kma7"}]],qD=X("file-spreadsheet",Xv);const Zv=[["path",{d:"M4 16v-2.38C4 11.5 2.97 10.5 3 8c.03-2.72 1.49-6 4.5-6C9.37 2 10 3.8 10 5.5c0 3.11-2 5.66-2 8.68V16a2 2 0 1 1-4 0Z",key:"1dudjm"}],["path",{d:"M20 20v-2.38c0-2.12 1.03-3.12 1-5.62-.03-2.72-1.49-6-4.5-6C14.63 6 14 7.8 14 9.5c0 3.11 2 5.66 2 8.68V20a2 2 0 1 0 4 0Z",key:"l2t8xc"}],["path",{d:"M16 17h4",key:"1dejxt"}],["path",{d:"M4 13h4",key:"1bwh8b"}]],XD=X("footprints",Zv);const Qv=[["path",{d:"M10 20a1 1 0 0 0 .553.895l2 1A1 1 0 0 0 14 21v-7a2 2 0 0 1 .517-1.341L21.74 4.67A1 1 0 0 0 21 3H3a1 1 0 0 0-.742 1.67l7.225 7.989A2 2 0 0 1 10 14z",key:"sc7q7i"}]],ZD=X("funnel",Qv);const Jv=[["path",{d:"M7 2h10",key:"nczekb"}],["path",{d:"M5 6h14",key:"u2x4p"}],["rect",{width:"18",height:"12",x:"3",y:"10",rx:"2",key:"l0tzu3"}]],QD=X("gallery-vertical-end",Jv);const eg=[["path",{d:"m12 14 4-4",key:"9kzdfg"}],["path",{d:"M3.34 19a10 10 0 1 1 17.32 0",key:"19p75a"}]],JD=X("gauge",eg);const tg=[["path",{d:"M21.42 10.922a1 1 0 0 0-.019-1.838L12.83 5.18a2 2 0 0 0-1.66 0L2.6 9.08a1 1 0 0 0 0 1.832l8.57 3.908a2 2 0 0 0 1.66 0z",key:"j76jl0"}],["path",{d:"M22 10v6",key:"1lu8f3"}],["path",{d:"M6 12.5V16a6 3 0 0 0 12 0v-3.5",key:"1r8lef"}]],eI=X("graduation-cap",tg);const ng=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M3 9h18",key:"1pudct"}],["path",{d:"M3 15h18",key:"5xshup"}],["path",{d:"M9 3v18",key:"fh3hqa"}],["path",{d:"M15 3v18",key:"14nvp0"}]],tI=X("grid-3x3",ng);const og=[["circle",{cx:"9",cy:"12",r:"1",key:"1vctgf"}],["circle",{cx:"9",cy:"5",r:"1",key:"hp0tcf"}],["circle",{cx:"9",cy:"19",r:"1",key:"fkjjf6"}],["circle",{cx:"15",cy:"12",r:"1",key:"1tmaij"}],["circle",{cx:"15",cy:"5",r:"1",key:"19l28e"}],["circle",{cx:"15",cy:"19",r:"1",key:"f4zoj3"}]],nI=X("grip-vertical",og);const rg=[["path",{d:"M15 21v-8a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v8",key:"5wwlr5"}],["path",{d:"M3 10a2 2 0 0 1 .709-1.528l7-6a2 2 0 0 1 2.582 0l7 6A2 2 0 0 1 21 10v9a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z",key:"r6nss1"}]],oI=X("house",rg);const sg=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2",key:"1m3agn"}],["circle",{cx:"9",cy:"9",r:"2",key:"af1f0g"}],["path",{d:"m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21",key:"1xmnt7"}]],rI=X("image",sg);const ag=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]],sI=X("info",ag);const ig=[["path",{d:"M13 5h8",key:"a7qcls"}],["path",{d:"M13 12h8",key:"h98zly"}],["path",{d:"M13 19h8",key:"c3s6r1"}],["path",{d:"m3 17 2 2 4-4",key:"1jhpwq"}],["path",{d:"m3 7 2 2 4-4",key:"1obspn"}]],aI=X("list-checks",ig);const lg=[["path",{d:"M21 5H3",key:"1fi0y6"}],["path",{d:"M7 12H3",key:"13ou7f"}],["path",{d:"M7 19H3",key:"wbqt3n"}],["path",{d:"M12 18a5 5 0 0 0 9-3 4.5 4.5 0 0 0-4.5-4.5c-1.33 0-2.54.54-3.41 1.41L11 14",key:"qth677"}],["path",{d:"M11 10v4h4",key:"172dkj"}]],iI=X("list-restart",lg);const cg=[["path",{d:"M3 5h.01",key:"18ugdj"}],["path",{d:"M3 12h.01",key:"nlz23k"}],["path",{d:"M3 19h.01",key:"noohij"}],["path",{d:"M8 5h13",key:"1pao27"}],["path",{d:"M8 12h13",key:"1za7za"}],["path",{d:"M8 19h13",key:"m83p4d"}]],lI=X("list",cg);const ug=[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]],cI=X("loader-circle",ug);const dg=[["path",{d:"m16 17 5-5-5-5",key:"1bji2h"}],["path",{d:"M21 12H9",key:"dn1m92"}],["path",{d:"M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4",key:"1uf3rs"}]],uI=X("log-out",dg);const fg=[["path",{d:"m22 7-8.991 5.727a2 2 0 0 1-2.009 0L2 7",key:"132q7q"}],["rect",{x:"2",y:"4",width:"20",height:"16",rx:"2",key:"izxlao"}]],dI=X("mail",fg);const pg=[["path",{d:"M20 10c0 4.993-5.539 10.193-7.399 11.799a1 1 0 0 1-1.202 0C9.539 20.193 4 14.993 4 10a8 8 0 0 1 16 0",key:"1r0f0z"}],["circle",{cx:"12",cy:"10",r:"3",key:"ilqhr7"}]],fI=X("map-pin",pg);const hg=[["path",{d:"M2.992 16.342a2 2 0 0 1 .094 1.167l-1.065 3.29a1 1 0 0 0 1.236 1.168l3.413-.998a2 2 0 0 1 1.099.092 10 10 0 1 0-4.777-4.719",key:"1sd12s"}]],pI=X("message-circle",hg);const mg=[["path",{d:"M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z",key:"18887p"}]],hI=X("message-square",mg);const vg=[["path",{d:"M5 12h14",key:"1ays0h"}]],mI=X("minus",vg);const gg=[["path",{d:"M13 5H19V11",key:"1n1gyv"}],["path",{d:"M19 5L5 19",key:"72u4yj"}]],vI=X("move-up-right",gg);const yg=[["polygon",{points:"3 11 22 2 13 21 11 13 3 11",key:"1ltx0t"}]],gI=X("navigation",yg);const bg=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M9 3v18",key:"fh3hqa"}]],yI=X("panel-left",bg);const xg=[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}],["path",{d:"m15 5 4 4",key:"1mk7zo"}]],bI=X("pencil",xg);const wg=[["path",{d:"M13 2a9 9 0 0 1 9 9",key:"1itnx2"}],["path",{d:"M13 6a5 5 0 0 1 5 5",key:"11nki7"}],["path",{d:"M13.832 16.568a1 1 0 0 0 1.213-.303l.355-.465A2 2 
10 0 1 17 15h3a2 2 0 0 1 2 2v3a2 2 0 0 1-2 2A18 18 0 0 1 2 4a2 2 0 0 1 2-2h3a2 2 0 0 1 2 2v3a2 2 0 0 1-.8 1.6l-.468.351a1 1 0 0 0-.292 1.233 14 14 0 0 0 6.392 6.384",key:"9njp5v"}]],xI=X("phone-call",wg);const Eg=[["path",{d:"M13.832 16.568a1 1 0 0 0 1.213-.303l.355-.465A2 2 0 0 1 17 15h3a2 2 0 0 1 2 2v3a2 2 0 0 1-2 2A18 18 0 0 1 2 4a2 2 0 0 1 2-2h3a2 2 0 0 1 2 2v3a2 2 0 0 1-.8 1.6l-.468.351a1 1 0 0 0-.292 1.233 14 14 0 0 0 6.392 6.384",key:"9njp5v"}]],wI=X("phone",Eg);const Cg=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]],EI=X("plus",Cg);const Sg=[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]],CI=X("refresh-cw",Sg);const Pg=[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}]],SI=X("rotate-ccw",Pg);const Mg=[["path",{d:"M21.3 15.3a2.4 2.4 0 0 1 0 3.4l-2.6 2.6a2.4 2.4 0 0 1-3.4 0L2.7 8.7a2.41 2.41 0 0 1 0-3.4l2.6-2.6a2.41 2.41 0 0 1 3.4 0Z",key:"icamh8"}],["path",{d:"m14.5 12.5 2-2",key:"inckbg"}],["path",{d:"m11.5 9.5 2-2",key:"fmmyf7"}],["path",{d:"m8.5 6.5 2-2",key:"vc6u1g"}],["path",{d:"m17.5 15.5 2-2",key:"wo5hmg"}]],PI=X("ruler",Mg);const Tg=[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]],MI=X("search",Tg);const kg=[["path",{d:"M14 17H5",key:"gfn3mx"}],["path",{d:"M19 7h-9",key:"6i9tg"}],["circle",{cx:"17",cy:"17",r:"3",key:"18b49y"}],["circle",{cx:"7",cy:"7",r:"3",key:"dfmy0x"}]],TI=X("settings-2",kg);const Rg=[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]],kI=X("shield-check",Rg);const Dg=[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}],["path",{d:"m14.5 9.5-5 5",key:"17q4r4"}],["path",{d:"m9.5 9.5 5 5",key:"18nt4w"}]],RI=X("shield-x",Dg);const Ig=[["path",{d:"M11.017 2.814a1 1 0 0 1 1.966 0l1.051 5.558a2 2 0 0 0 1.594 1.594l5.558 1.051a1 1 0 0 1 0 1.966l-5.558 1.051a2 2 0 0 0-1.594 1.594l-1.051 5.558a1 1 0 0 1-1.966 0l-1.051-5.558a2 2 0 0 0-1.594-1.594l-5.558-1.051a1 1 0 0 1 0-1.966l5.558-1.051a2 2 0 0 0 1.594-1.594z",key:"1s2grr"}],["path",{d:"M20 2v4",key:"1rf3ol"}
vendor: 9,172 bytes, line 1
1],["path",{d:"M22 4h-4",key:"gwowj6"}],["circle",{cx:"4",cy:"20",r:"2",key:"6kqj1y"}]],DI=X("sparkles",Ig);const Og=[["path",{d:"M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z",key:"r04s7s"}]],II=X("star",Og);const Ag=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["circle",{cx:"12",cy:"12",r:"6",key:"1vlfrh"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}]],OI=X("target",Ag);const _g=[["path",{d:"M10 11v6",key:"nco0om"}],["path",{d:"M14 11v6",key:"outv1u"}],["path",{d:"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6",key:"miytrc"}],["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2",key:"e791ji"}]],AI=X("trash-2",_g);const Ng=[["path",{d:"M16 7h6v6",key:"box55l"}],["path",{d:"m22 7-8.5 8.5-5-5L2 17",key:"1t1m79"}]],_I=X("trending-up",Ng);const $g=[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]],NI=X("triangle-alert",$g);const Fg=[["path",{d:"M12 3v12",key:"1x0j5s"}],["path",{d:"m17 8-5-5-5 5",key:"7q97r8"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}]],$I=X("upload",Fg);const Lg=[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["line",{x1:"19",x2:"19",y1:"8",y2:"14",key:"1bvyxn"}],["line",{x1:"22",x2:"16",y1:"11",y2:"11",key:"1shjgl"}]],FI=X("user-plus",Lg);const jg=[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]],LI=X("user",jg);const Bg=[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["path",{d:"M16 3.128a4 4 0 0 1 0 7.744",key:"16gr8j"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}]],jI=X("users",Bg);const Vg=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],BI=X("x",Vg);const Wg=[["path",{d:"M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z",key:"1xq2db"}]],VI=X("zap",Wg);var Hg=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Ug=Hg.reduce((e,t)=>{const n=ur(`Primitive.${t}`),o=l.forwardRef((r,s)=>{const{asChild:a,...i}=r,c=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),E.jsx(c,{...i,ref:s})});return o.displayName=`Primitive.${t}`,{...e,[t]:o}},{}),Gg="Separator",Bi="horizontal",Yg=["horizontal","vertical"],jc=l.forwardRef((e,t)=>{const{decorative:n,orientation:o=Bi,...r}=e,s=zg(o)?o:Bi,i=n?{role:"none"}:{"aria-orientation":s==="vertical"?s:void 0,role:"separator"};return E.jsx(Ug.div,{"data-orientation":s,...i,...r,ref:t})});jc.displayName=Gg;function zg(e){return Yg.includes(e)}var WI=jc;function J(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(e?.(r),n===!1||!r.defaultPrevented)return t?.(r)}}function Kg(e,t){const n=l.createContext(t),o=s=>{const{children:a,...i}=s,c=l.useMemo(()=>i,Object.values(i));return E.jsx(n.Provider,{value:c,children:a})};o.displayName=e+"Provider";function r(s){const a=l.useContext(n);if(a)return a;if(t!==void 0)return t;throw new Error(`\`${s}\` must be used within \`${e}\``)}return[o,r]}function rt(e,t=[]){let n=[];function o(s,a){const i=l.createContext(a),c=n.length;n=[...n,a];const u=f=>{const{scope:p,children:h,...m}=f,v=p?.[e]?.[c]||i,g=l.useMemo(()=>m,Object.values(m));return E.jsx(v.Provider,{value:g,children:h})};u.displayName=s+"Provider";function d(f,p){const h=p?.[e]?.[c]||i,m=l.useContext(h);if(m)return m;if(a!==void 0)return a;throw new Error(`\`${f}\` must be used within \`${s}\``)}return[u,d]}const r=()=>{const s=n.map(a=>l.createContext(a));return function(i){const c=i?.[e]||s;return l.useMemo(()=>({[`__scope${e}`]:{...i,[e]:c}}),[i,c])}};return r.scopeName=e,[o,qg(r,...t)]}function qg(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const o=e.map(r=>({useScope:r(),scopeName:r.scopeName}));return function(s){const a=o.reduce((i,{useScope:c,scopeName:u})=>{const f=c(s)[`__scope${u}`];return{...i,...f}},{});return l.useMemo(()=>({[`__scope${t.scopeName}`]:a}),[a])}};return n.scopeName=t.scopeName,n}var _e=globalThis?.document?l.useLayoutEffect:()=>{},Xg=kn[" useId ".trim().toString()]||(()=>{}),Zg=0;function $e(e){const[t,n]=l.useState(Xg());return _e(()=>{n(o=>o??String(Zg++))},[e]),t?`radix-${t}`:""}var Qg=kn[" useInsertionEffect ".trim().toString()]||_e;function Mt({prop:e,defaultProp:t,onChange:n=()=>{},caller:o}){const[r,s,a]=Jg({defaultProp:t,onChange:n}),i=e!==void 0,c=i?e:r;{const d=l.useRef(e!==void 0);l.useEffect(()=>{const f=d.current;f!==i&&console.warn(`${o} is changing from ${f?"controlled":"uncontrolled"} to ${i?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),d.current=i},[i,o])}const u=l.useCallback(d=>{if(i){const f=ey(d)?d(e):d;f!==e&&a.current?.(f)}else s(d)},[i,e,s,a]);return[c,u]}function Jg({defaultProp:e,onChange:t}){const[n,o]=l.useState(e),r=l.useRef(n),s=l.useRef(t);return Qg(()=>{s.current=t},[t]),l.useEffect(()=>{r.current!==n&&(s.current?.(n),r.current=n)},[n,r]),[n,o,s]}function ey(e){return typeof e=="function"}function ty(e){const t=ny(e),n=l.forwardRef((o,r)=>{const{children:s,...a}=o,i=l.Children.toArray(s),c=i.find(ry);if(c){const u=c.props.children,d=i.map(f=>f===c?l.Children.count(u)>1?l.Children.only(null):l.isValidElement(u)?u.props.children:null:f);return E.jsx(t,{...a,ref:r,children:l.isValidElement(u)?l.cloneElement(u,void 0,d):null})}return E.jsx(t,{...a,ref:r,children:s})});return n.displayName=`${e}.Slot`,n}function ny(e){const t=l.forwardRef((n,o)=>{const{children:r,...s}=n;if(l.isValidElement(r)){const a=ay(r),i=sy(s,r.props);return r.type!==l.Fragment&&(i.ref=o?ze(o,a):a),l.cloneElement(r,i)}return l.Children.count(r)>1?l.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var oy=Symbol("radix.slottable");function ry(e){return l.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===oy}function sy(e,t){const n={...t};for(const o in t){const r=e[o],s=t[o];/^on[A-Z]/.test(o)?r&&s?n[o]=(...i)=>{const c=s(...i);return r(...i),c}:r&&(n[o]=r):o==="style"?n[o]={...r,...s}:o==="className"&&(n[o]=[r,s].filter(Boolean).join(" "))}return{...e,...n}}function ay(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var iy=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],re=iy.reduce((e,t)=>{const n=ty(`Primitive.${t}`),o=l.forwardRef((r,s)=>{const{asChild:a,...i}=r,c=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),E.jsx(c,{...i,ref:s})});return o.displayName=`Primitive.${t}`,{...e,[t]:o}},{});function Bc(e,t){e&&Te.flushSync(()=>e.dispatchEvent(t))}function vt(e){const t=l.useRef(e);return l.useEffect(()=>{t.current=e}),l.useMemo(()=>(...n)=>t.current?.(...n),[])}function ly(e,t=globalThis?.document){const n=vt(e);l.useEffect(()=>{const o=r=>{r.key==="Escape"&&n(r)};return t.addEventListener("keydown",o,{capture:!0}),()=>t.removeEventListener("keydown",o,{capture:!0})},[n,t])}var cy="DismissableLayer",$s="dismissableLayer.update",uy="dismissableLayer.pointerDownOutside",dy="dismissableLayer.focusOutside",Vi,Vc=l.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),_n=l.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:o,onPointerDownOutside:r,onFocusOutside:s,onInteractOutside:a,onDismiss:i,...c}=e,u=l.useContext(Vc),[d,f]=l.useState(null),p=d?.ownerDocument??globalThis?.document,[,h]=l.useState({}),m=he(t,P=>f(P)),v=Array.from(u.layers),[g]=[...u.layersWithOutsidePointerEventsDisabled].slice(-1),y=v.indexOf(g),b=d?v.indexOf(d):-1,x=u.layersWithOutsidePointerEventsDisabled.size>0,S=b>=y,T=hy(P=>{const _=P.target,O=[...u.branches].some(I=>I.contains(_));!S||O||(r?.(P),a?.(P),P.defaultPrevented||i?.())},p),C=my(P=>{const _=P.target;[...u.branches].some(I=>I.contains(_))||(s?.(P),a?.(P),P.defaultPrevented||i?.())},p);return ly(P=>{b===u.layers.size-1&&(o?.(P),!P.defaultPrevented&&i&&(P.preventDefault(),i()))},p),l.useEffect(()=>{if(d)return n&&(u.layersWithOutsidePointerEventsDisabled.size===0&&(Vi=p.body.style.pointerEvents,p.body.style.pointerEvents="none"),u.layersWithOutsidePointerEventsDisabled.add(d)),u.layers.add(d),Wi(),()=>{n&&u.layersWithOutsidePointerEventsDisabled.size===1&&(p.body.style.pointerEvents=Vi)}},[d,p,n,u]),l.useEffect(()=>()=>
vendor: 19,265 bytes, lines 1-5
1{d&&(u.layers.delete(d),u.layersWithOutsidePointerEventsDisabled.delete(d),Wi())},[d,u]),l.useEffect(()=>{const P=()=>h({});return document.addEventListener($s,P),()=>document.removeEventListener($s,P)},[]),E.jsx(re.div,{...c,ref:m,style:{pointerEvents:x?S?"auto":"none":void 0,...e.style},onFocusCapture:J(e.onFocusCapture,C.onFocusCapture),onBlurCapture:J(e.onBlurCapture,C.onBlurCapture),onPointerDownCapture:J(e.onPointerDownCapture,T.onPointerDownCapture)})});_n.displayName=cy;var fy="DismissableLayerBranch",py=l.forwardRef((e,t)=>{const n=l.useContext(Vc),o=l.useRef(null),r=he(t,o);return l.useEffect(()=>{const s=o.current;if(s)return n.branches.add(s),()=>{n.branches.delete(s)}},[n.branches]),E.jsx(re.div,{...e,ref:r})});py.displayName=fy;function hy(e,t=globalThis?.document){const n=vt(e),o=l.useRef(!1),r=l.useRef(()=>{});return l.useEffect(()=>{const s=i=>{if(i.target&&!o.current){let c=function(){Wc(uy,n,u,{discrete:!0})};const u={originalEvent:i};i.pointerType==="touch"?(t.removeEventListener("click",r.current),r.current=c,t.addEventListener("click",r.current,{once:!0})):c()}else t.removeEventListener("click",r.current);o.current=!1},a=window.setTimeout(()=>{t.addEventListener("pointerdown",s)},0);return()=>{window.clearTimeout(a),t.removeEventListener("pointerdown",s),t.removeEventListener("click",r.current)}},[t,n]),{onPointerDownCapture:()=>o.current=!0}}function my(e,t=globalThis?.document){const n=vt(e),o=l.useRef(!1);return l.useEffect(()=>{const r=s=>{s.target&&!o.current&&Wc(dy,n,{originalEvent:s},{discrete:!1})};return t.addEventListener("focusin",r),()=>t.removeEventListener("focusin",r)},[t,n]),{onFocusCapture:()=>o.current=!0,onBlurCapture:()=>o.current=!1}}function Wi(){const e=new CustomEvent($s);document.dispatchEvent(e)}function Wc(e,t,n,{discrete:o}){const r=n.originalEvent.target,s=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&r.addEventListener(e,t,{once:!0}),o?Bc(r,s):r.dispatchEvent(s)}var ls="focusScope.autoFocusOnMount",cs="focusScope.autoFocusOnUnmount",Hi={bubbles:!1,cancelable:!0},vy="FocusScope",mo=l.forwardRef((e,t)=>{const{loop:n=!1,trapped:o=!1,onMountAutoFocus:r,onUnmountAutoFocus:s,...a}=e,[i,c]=l.useState(null),u=vt(r),d=vt(s),f=l.useRef(null),p=he(t,v=>c(v)),h=l.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;l.useEffect(()=>{if(o){let v=function(x){if(h.paused||!i)return;const S=x.target;i.contains(S)?f.current=S:Bt(f.current,{select:!0})},g=function(x){if(h.paused||!i)return;const S=x.relatedTarget;S!==null&&(i.contains(S)||Bt(f.current,{select:!0}))},y=function(x){if(document.activeElement===document.body)for(const T of x)T.removedNodes.length>0&&Bt(i)};document.addEventListener("focusin",v),document.addEventListener("focusout",g);const b=new MutationObserver(y);return i&&b.observe(i,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",v),document.removeEventListener("focusout",g),b.disconnect()}}},[o,i,h.paused]),l.useEffect(()=>{if(i){Gi.add(h);const v=document.activeElement;if(!i.contains(v)){const y=new CustomEvent(ls,Hi);i.addEventListener(ls,u),i.dispatchEvent(y),y.defaultPrevented||(gy(Ey(Hc(i)),{select:!0}),document.activeElement===v&&Bt(i))}return()=>{i.removeEventListener(ls,u),setTimeout(()=>{const y=new CustomEvent(cs,Hi);i.addEventListener(cs,d),i.dispatchEvent(y),y.defaultPrevented||Bt(v??document.body,{select:!0}),i.removeEventListener(cs,d),Gi.remove(h)},0)}}},[i,u,d,h]);const m=l.useCallback(v=>{if(!n&&!o||h.paused)return;const g=v.key==="Tab"&&!v.altKey&&!v.ctrlKey&&!v.metaKey,y=document.activeElement;if(g&&y){const b=v.currentTarget,[x,S]=yy(b);x&&S?!v.shiftKey&&y===S?(v.preventDefault(),n&&Bt(x,{select:!0})):v.shiftKey&&y===x&&(v.preventDefault(),n&&Bt(S,{select:!0})):y===b&&v.preventDefault()}},[n,o,h.paused]);return E.jsx(re.div,{tabIndex:-1,...a,ref:p,onKeyDown:m})});mo.displayName=vy;function gy(e,{select:t=!1}={}){const n=document.activeElement;for(const o of e)if(Bt(o,{select:t}),document.activeElement!==n)return}function yy(e){const t=Hc(e),n=Ui(t,e),o=Ui(t.reverse(),e);return[n,o]}function Hc(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:o=>{const r=o.tagName==="INPUT"&&o.type==="hidden";return o.disabled||o.hidden||r?NodeFilter.FILTER_SKIP:o.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function Ui(e,t){for(const n of e)if(!by(n,{upTo:t}))return n}function by(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function xy(e){return e instanceof HTMLInputElement&&"select"in e}function Bt(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&xy(e)&&t&&e.select()}}var Gi=wy();function wy(){let e=[];return{add(t){const n=e[0];t!==n&&n?.pause(),e=Yi(e,t),e.unshift(t)},remove(t){e=Yi(e,t),e[0]?.resume()}}}function Yi(e,t){const n=[...e],o=n.indexOf(t);return o!==-1&&n.splice(o,1),n}function Ey(e){return e.filter(t=>t.tagName!=="A")}var Cy="Portal",Nn=l.forwardRef((e,t)=>{const{container:n,...o}=e,[r,s]=l.useState(!1);_e(()=>s(!0),[]);const a=n||r&&globalThis?.document?.body;return a?Cc.createPortal(E.jsx(re.div,{...o,ref:t}),a):null});Nn.displayName=Cy;function Sy(e,t){return l.useReducer((n,o)=>t[n][o]??n,e)}var Ze=e=>{const{present:t,children:n}=e,o=Py(t),r=typeof n=="function"?n({present:o.isPresent}):l.Children.only(n),s=he(o.ref,My(r));return typeof n=="function"||o.isPresent?l.cloneElement(r,{ref:s}):null};Ze.displayName="Presence";function Py(e){const[t,n]=l.useState(),o=l.useRef(null),r=l.useRef(e),s=l.useRef("none"),a=e?"mounted":"unmounted",[i,c]=Sy(a,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return l.useEffect(()=>{const u=Fo(o.current);s.current=i==="mounted"?u:"none"},[i]),_e(()=>{const u=o.current,d=r.current;if(d!==e){const p=s.current,h=Fo(u);e?c("MOUNT"):h==="none"||u?.display==="none"?c("UNMOUNT"):c(d&&p!==h?"ANIMATION_OUT":"UNMOUNT"),r.current=e}},[e,c]),_e(()=>{if(t){let u;const d=t.ownerDocument.defaultView??window,f=h=>{const v=Fo(o.current).includes(CSS.escape(h.animationName));if(h.target===t&&v&&(c("ANIMATION_END"),!r.current)){const g=t.style.animationFillMode;t.style.animationFillMode="forwards",u=d.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=g)})}},p=h=>{h.target===t&&(s.current=Fo(o.current))};return t.addEventListener("animationstart",p),t.addEventListener("animationcancel",f),t.addEventListener("animationend",f),()=>{d.clearTimeout(u),t.removeEventListener("animationstart",p),t.removeEventListener("animationcancel",f),t.removeEventListener("animationend",f)}}else c("ANIMATION_END")},[t,c]),{isPresent:["mounted","unmountSuspended"].includes(i),ref:l.useCallback(u=>{o.current=u?getComputedStyle(u):null,n(u)},[])}}function Fo(e){return e?.animationName||"none"}function My(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var us=0;function dr(){l.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??zi()),document.body.insertAdjacentElement("beforeend",e[1]??zi()),us++,()=>{us===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),us--}},[])}function zi(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}function Ty(e){const t=ky(e),n=l.forwardRef((o,r)=>{const{children:s,...a}=o,i=l.Children.toArray(s),c=i.find(Dy);if(c){const u=c.props.children,d=i.map(f=>f===c?l.Children.count(u)>1?l.Children.only(null):l.isValidElement(u)?u.props.children:null:f);return E.jsx(t,{...a,ref:r,children:l.isValidElement(u)?l.cloneElement(u,void 0,d):null})}return E.jsx(t,{...a,ref:r,children:s})});return n.displayName=`${e}.Slot`,n}function ky(e){const t=l.forwardRef((n,o)=>{const{children:r,...s}=n;if(l.isValidElement(r)){const a=Oy(r),i=Iy(s,r.props);return r.type!==l.Fragment&&(i.ref=o?ze(o,a):a),l.cloneElement(r,i)}return l.Children.count(r)>1?l.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Ry=Symbol("radix.slottable");function Dy(e){return l.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Ry}function Iy(e,t){const n={...t};for(const o in t){const r=e[o],s=t[o];/^on[A-Z]/.test(o)?r&&s?n[o]=(...i)=>{const c=s(...i);return r(...i),c}:r&&(n[o]=r):o==="style"?n[o]={...r,...s}:o==="className"&&(n[o]=[r,s].filter(Boolean).join(" "))}return{...e,...n}}function Oy(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var fr="Dialog",[Uc,Gc]=rt(fr),[Ay,yt]=Uc(fr),Yc=e=>{const{__scopeDialog:t,children:n,open:o,defaultOpen:r,onOpenChange:s,modal:a=!0}=e,i=l.useRef(null),c=l.useRef(null),[u,d]=Mt({prop:o,defaultProp:r??!1,onChange:s,caller:fr});return E.jsx(Ay,{scope:t,triggerRef:i,contentRef:c,contentId:$e(),titleId:$e(),descriptionId:$e(),open:u,onOpenChange:d,onOpenToggle:l.useCallback(()=>d(f=>!f),[d]),modal:a,children:n})};Yc.displayName=fr;var zc="DialogTrigger",Kc=l.forwardRef((e,t)=>{const{__scopeDialog:n,...o}=e,r=yt(zc,n),s=he(t,r.triggerRef);return E.jsx(re.button,{type:"button","aria-haspopup":"dialog","aria-expanded":r.open,"aria-controls":r.contentId,"data-state":ma(r.open),...o,ref:s,onClick:J(e.onClick,r.onOpenToggle)})});Kc.displayName=zc;var pa="DialogPortal",[_y,qc]=Uc(pa,{forceMount:void 0}),Xc=e=>{const{__scopeDialog:t,forceMount:n,children:o,container:r}=e,s=yt(pa,t);return E.jsx(_y,{scope:t,forceMount:n,children:l.Children.map(o,a=>E.jsx(Ze,{present:n||s.open,children:E.jsx(Nn,{asChild:!0,container:r,children:a})}))})};Xc.displayName=pa;var qo="DialogOverlay",Zc=l.forwardRef((e,t)=>{const n=qc(qo,e.__scopeDialog),{forceMount:o=n.forceMount,...r}=e,s=yt(qo,e.__scopeDialog);return s.modal?E.jsx(Ze,{present:o||s.open,children:E.jsx($y,{...r,ref:t})}):null});Zc.displayName=qo;var Ny=Ty("DialogOverlay.RemoveScroll"),$y=l.forwardRef((e,t)=>{const{__scopeDialog:n,...o}=e,r=yt(qo,n);return E.jsx(lr,{as:Ny,allowPinchZoom:!0,shards:[r.contentRef],children:E.jsx(re.div,{"data-state":ma(r.open),...o,ref:t,style:{pointerEvents:"auto",...o.style}})})}),un="DialogContent",Qc=l.forwardRef((e,t)=>{const n=qc(un,e.__scopeDialog),{forceMount:o=n.forceMount,...r}=e,s=yt(un,e.__scopeDialog);return E.jsx(Ze,{present:o||s.open,children:s.modal?E.jsx(Fy,{...r,ref:t}):E.jsx(Ly,{...r,ref:t})})});Qc.displayName=un;var Fy=l.forwardRef((e,t)=>{const n=yt(un,e.__scopeDialog),o=l.useRef(null),r=he(t,n.contentRef,o);return l.useEffect(()=>{const s=o.current;if(s)return cr(s)},[]),E.jsx(Jc,{...e,ref:r,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:J(e.onCloseAutoFocus,s=>{s.preventDefault(),n.triggerRef.current?.focus()}),onPointerDownOutside:J(e.onPointerDownOutside,s=>{const a=s.detail.originalEvent,i=a.button===0&&a.ctrlKey===!0;(a.button===2||i)&&s.preventDefault()}),onFocusOutside:J(e.onFocusOutside,s=>s.preventDefault())})}),Ly=l.forwardRef((e,t)=>{const n=yt(un,e.__scopeDialog),o=l.useRef(!1),r=l.useRef(!1);return E.jsx(Jc,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:s=>{e.onCloseAutoFocus?.(s),s.defaultPrevented||(o.current||n.triggerRef.current?.focus(),s.preventDefault()),o.current=!1,r.current=!1},onInteractOutside:s=>{e.onInteractOutside?.(s),s.defaultPrevented||(o.current=!0,s.detail.originalEvent.type==="pointerdown"&&(r.current=!0));const a=s.target;n.triggerRef.current?.contains(a)&&s.preventDefault(),s.detail.originalEvent.type==="focusin"&&r.current&&s.preventDefault()}})}),Jc=l.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:o,onOpenAutoFocus:r,onCloseAutoFocus:s,...a}=e,i=yt(un,n),c=l.useRef(null),u=he(t,c);return dr(),E.jsxs(E.Fragment,{children:[E.jsx(mo,{asChild:!0,loop:!0,trapped:o,onMountAutoFocus:r,onUnmountAutoFocus:s,children:E.jsx(_n,{role:"dialog",id:i.contentId,"aria-describedby":i.descriptionId,"aria-labelledby":i.titleId,"data-state":ma(i.open),...a,ref:u,onDismiss:()=>i.onOpenChange(!1)})}),E.jsxs(E.Fragment,{children:[E.jsx(By,{titleId:i.titleId}),E.jsx(Wy,{contentRef:c,descriptionId:i.descriptionId})]})]})}),ha="DialogTitle",eu=l.forwardRef((e,t)=>{const{__scopeDialog:n,...o}=e,r=yt(ha,n);return E.jsx(re.h2,{id:r.titleId,...o,ref:t})});eu.displayName=ha;var tu="DialogDescription",nu=l.forwardRef((e,t)=>{const{__scopeDialog:n,...o}=e,r=yt(tu,n);return E.jsx(re.p,{id:r.descriptionId,...o,ref:t})});nu.displayName=tu;var ou="DialogClose",ru=l.forwardRef((e,t)=>{const{__scopeDialog:n,...o}=e,r=yt(ou,n);return E.jsx(re.button,{type:"button",...o,ref:t,onClick:J(e.onClick,()=>r.onOpenChange(!1))})});ru.displayName=ou;function ma(e){return e?"open":"closed"}var su="DialogTitleWarning",[jy,au]=Kg(su,{contentName:un,titleName:ha,docsSlug:"dialog"}),By=({titleId:e})=>{const t=au(su),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
2
3If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
4
5For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return l.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},Vy="DialogDescriptionWarning",Wy=({contentRef:e,descriptionId:t})=>{const o=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${au(Vy).contentName}}.`;return l.useEffect(()=>{const r=e.current?.getAttribute("aria-describedby");t&&r&&(document.getElementById(t)||console.warn(o))},[o,e,t]),null},iu=Yc,Hy=Kc,lu=Xc,cu=Zc,uu=Qc,Uy=eu,Gy=nu,du=ru,Yy="Arrow",fu=l.forwardRef((e,t)=>{const{children:n,width:o=10,height:r=5,...s}=e;return E.jsx(re.svg,{...s,ref:t,width:o,height:r,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:E.jsx("polygon",{points:"0,0 30,0 15,10"})})});fu.displayName=Yy;var zy=fu;function va(e){const[t,n]=l.useState(void 0);return _e(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const o=new ResizeObserver(r=>{if(!Array.isArray(r)||!r.length)return;const s=r[0];let a,i;if("borderBoxSize"in s){const c=s.borderBoxSize,u=Array.isArray(c)?c[0]:c;a=u.inlineSize,i=u.blockSize}else a=e.offsetWidth,i=e.offsetHeight;n({width:a,height:i})});return o.observe(e,{box:"border-box"}),()=>o.unobserve(e)}else n(void 0)},[e]),t}var ga="Popper",[pu,Kt]=rt(ga),[Ky,hu]=pu(ga),mu=e=>{const{__scopePopper:t,children:n}=e,[o,r]=l.useState(null);return E.jsx(Ky,{scope:t,anchor:o,onAnchorChange:r,children:n})};mu.displayName=ga;var vu="PopperAnchor",gu=l.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:o,...r}=e,s=hu(vu,n),a=l.useRef(null),i=he(t,a),c=l.useRef(null);return l.useEffect(()=>{const u=c.current;c.current=o?.current||a.current,u!==c.current&&s.onAnchorChange(c.current)}),o?null:E.jsx(re.div,{...r,ref:i})});gu.displayName=vu;var ya="PopperContent",[qy,Xy]=pu(ya),yu=l.forwardRef((e,t)=>{const{__scopePopper:n,side:o="bottom",sideOffset:r=0,align:s="center",alignOffset:a=0,arrowPadding:i=0,avoidCollisions:c=!0,collisionBoundary:u=[],collisionPadding:d=0,sticky:f="partial",hideWhenDetached:p=!1,updatePositionStrategy:h="optimized",onPlaced:m,...v}=e,g=hu(ya,n),[y,b]=l.useState(null),x=he(t,N=>b(N)),[S,T]=l.useState(null),C=va(S),P=C?.width??0,_=C?.height??0,O=o+(s!=="center"?"-"+s:""),I=typeof d=="number"?d:{top:0,right:0,bottom:0,left:0,...d},$=Array.isArray(u)?u:[u],G=$.length>0,W={padding:I,boundary:$.filter(Qy),altBoundary:G},{refs:B,floatingStyles:K,placement:H,isPositioned:U,middlewareData:q}=Sc({strategy:"fixed",placement:O,whileElementsMounted:(...N)=>kc(...N,{animationFrame:h==="always"}),elements:{reference:g.anchor},middleware:[ia({mainAxis:r+_,alignmentAxis:a}),c&&Pc({mainAxis:!0,crossAxis:!1,limiter:f==="partial"?tm():void 0,...W}),c&&Mc({...W}),Tc({...W,apply:({elements:N,rects:Y,availableWidth:te,availableHeight:ae})=>{const{width:pe,height:ee}=Y.reference,ue=N.floating.style;ue.setProperty("--radix-popper-available-width",`${te}px`),ue.setProperty("--radix-popper-available-height",`${ae}px`),ue.setProperty("--radix-popper-anchor-width",`${pe}px`),ue.setProperty("--radix-popper-anchor-height",`${ee}px`)}}),S&&Jh({element:S,padding:i}),Jy({arrowWidth:P,arrowHeight:_}),p&&em({strategy:"referenceHidden",...W})]}),[R,D]=wu(H),L=vt(m);_e(()=>{U&&L?.()},[U,L]);const k=q.arrow?.x,M=q.arrow?.y,F=q.arrow?.centerOffset!==0,[A,z]=l.useState();return _e(()=>{y&&z(window.getComputedStyle(y).zIndex)},[y]),E.jsx("div",{ref:B.setFloating,"data-radix-popper-content-wrapper":"",style:{...K,transform:U?K.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:A,"--radix-popper-transform-origin":[q.transformOrigin?.x,q.transformOrigin?.y].join(" "),...q.hide?.referenceHidden&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:E.jsx(qy,{scope:n,placedSide:R,onArrowChange:T,arrowX:k,arrowY:M,shouldHideArrow:F,children:E.jsx(re.div,{"data-side":R,"data-align":D,...v,ref:x,style:{...v.style,animation:U?void 0:"none"}})})})});yu.displayName=ya;var bu="PopperArrow",Zy={top:"bottom",right:"left",bottom:"top",left:"right"},xu=l.forwardRef(function(t,n){const{__scopePopper:o,...r}=t,s=Xy(bu,o),a=Zy[s.placedSide];return E.jsx("span",{ref:s.onArrowChange,style:{position:"absolute",left:s.arrowX,top:s.arrowY,[a]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[s.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[s.placedSide],visibility:s.shouldHideArrow?"hidden":void 0},children:E.jsx(zy,{...r,ref:n,style:{...r.style,display:"block"}})})});xu.displayName=bu;function Qy(e){return e!==null}var Jy=e=>({name:"transformOrigin",options:e,fn(t){const{placement:n,rects:o,middlewareData:r}=t,a=r.arrow?.centerOffset!==0,i=a?0:e.arrowWidth,c=a?0:e.arrowHeight,[u,d]=wu(n),f={start:"0%",center:"50%",end:"100%"}[d],p=(r.arrow?.x??0)+i/2,h=(r.arrow?.y??0)+c/2;let m="",v="";return u==="bottom"?(m=a?f:`${p}px`,v=`${-c}px`):u==="top"?(m=a?f:`${p}px`,v=`${o.floating.height+c}px`):u==="right"?(m=`${-c}px`,v=a?f:`${h}px`):u==="left"&&(m=`${o.floating.width+c}px`,v=a?f:`${h}px`),{data:{x:m,y:v}}}});function wu(e){const[t,n="center"]=e.split("-");return[t,n]}var pr=mu,vo=gu,hr=yu,mr=xu,eb=Symbol("radix.slottable");function tb(e){const t=({children:n})=>E.jsx(E.Fragment,{children:n});return t.displayName=`${e}.Slottable`,t.__radixId=eb,t}var Eu=Object.freeze({position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal"}),nb="VisuallyHidden",Cu=l.forwardRef((e,t)=>
vendor: 4,608 bytes, line 5
5E.jsx(re.span,{...e,ref:t,style:{...Eu,...e.style}}));Cu.displayName=nb;var ob=Cu,[vr]=rt("Tooltip",[Kt]),gr=Kt(),Su="TooltipProvider",rb=700,Fs="tooltip.open",[sb,ba]=vr(Su),Pu=e=>{const{__scopeTooltip:t,delayDuration:n=rb,skipDelayDuration:o=300,disableHoverableContent:r=!1,children:s}=e,a=l.useRef(!0),i=l.useRef(!1),c=l.useRef(0);return l.useEffect(()=>{const u=c.current;return()=>window.clearTimeout(u)},[]),E.jsx(sb,{scope:t,isOpenDelayedRef:a,delayDuration:n,onOpen:l.useCallback(()=>{window.clearTimeout(c.current),a.current=!1},[]),onClose:l.useCallback(()=>{window.clearTimeout(c.current),c.current=window.setTimeout(()=>a.current=!0,o)},[o]),isPointerInTransitRef:i,onPointerInTransitChange:l.useCallback(u=>{i.current=u},[]),disableHoverableContent:r,children:s})};Pu.displayName=Su;var ao="Tooltip",[ab,go]=vr(ao),Mu=e=>{const{__scopeTooltip:t,children:n,open:o,defaultOpen:r,onOpenChange:s,disableHoverableContent:a,delayDuration:i}=e,c=ba(ao,e.__scopeTooltip),u=gr(t),[d,f]=l.useState(null),p=$e(),h=l.useRef(0),m=a??c.disableHoverableContent,v=i??c.delayDuration,g=l.useRef(!1),[y,b]=Mt({prop:o,defaultProp:r??!1,onChange:P=>{P?(c.onOpen(),document.dispatchEvent(new CustomEvent(Fs))):c.onClose(),s?.(P)},caller:ao}),x=l.useMemo(()=>y?g.current?"delayed-open":"instant-open":"closed",[y]),S=l.useCallback(()=>{window.clearTimeout(h.current),h.current=0,g.current=!1,b(!0)},[b]),T=l.useCallback(()=>{window.clearTimeout(h.current),h.current=0,b(!1)},[b]),C=l.useCallback(()=>{window.clearTimeout(h.current),h.current=window.setTimeout(()=>{g.current=!0,b(!0),h.current=0},v)},[v,b]);return l.useEffect(()=>()=>{h.current&&(window.clearTimeout(h.current),h.current=0)},[]),E.jsx(pr,{...u,children:E.jsx(ab,{scope:t,contentId:p,open:y,stateAttribute:x,trigger:d,onTriggerChange:f,onTriggerEnter:l.useCallback(()=>{c.isOpenDelayedRef.current?C():S()},[c.isOpenDelayedRef,C,S]),onTriggerLeave:l.useCallback(()=>{m?T():(window.clearTimeout(h.current),h.current=0)},[T,m]),onOpen:S,onClose:T,disableHoverableContent:m,children:n})})};Mu.displayName=ao;var Ls="TooltipTrigger",Tu=l.forwardRef((e,t)=>{const{__scopeTooltip:n,...o}=e,r=go(Ls,n),s=ba(Ls,n),a=gr(n),i=l.useRef(null),c=he(t,i,r.onTriggerChange),u=l.useRef(!1),d=l.useRef(!1),f=l.useCallback(()=>u.current=!1,[]);return l.useEffect(()=>()=>document.removeEventListener("pointerup",f),[f]),E.jsx(vo,{asChild:!0,...a,children:E.jsx(re.button,{"aria-describedby":r.open?r.contentId:void 0,"data-state":r.stateAttribute,...o,ref:c,onPointerMove:J(e.onPointerMove,p=>{p.pointerType!=="touch"&&!d.current&&!s.isPointerInTransitRef.current&&(r.onTriggerEnter(),d.current=!0)}),onPointerLeave:J(e.onPointerLeave,()=>{r.onTriggerLeave(),d.current=!1}),onPointerDown:J(e.onPointerDown,()=>{r.open&&r.onClose(),u.current=!0,document.addEventListener("pointerup",f,{once:!0})}),onFocus:J(e.onFocus,()=>{u.current||r.onOpen()}),onBlur:J(e.onBlur,r.onClose),onClick:J(e.onClick,r.onClose)})})});Tu.displayName=Ls;var xa="TooltipPortal",[ib,lb]=vr(xa,{forceMount:void 0}),ku=e=>{const{__scopeTooltip:t,forceMount:n,children:o,container:r}=e,s=go(xa,t);return E.jsx(ib,{scope:t,forceMount:n,children:E.jsx(Ze,{present:n||s.open,children:E.jsx(Nn,{asChild:!0,container:r,children:o})})})};ku.displayName=xa;var Rn="TooltipContent",Ru=l.forwardRef((e,t)=>{const n=lb(Rn,e.__scopeTooltip),{forceMount:o=n.forceMount,side:r="top",...s}=e,a=go(Rn,e.__scopeTooltip);return E.jsx(Ze,{present:o||a.open,children:a.disableHoverableContent?E.jsx(Du,{side:r,...s,ref:t}):E.jsx(cb,{side:r,...s,ref:t})})}),cb=l.forwardRef((e,t)=>{const n=go(Rn,e.__scopeTooltip),o=ba(Rn,e.__scopeTooltip),r=l.useRef(null),s=he(t,r),[a,i]=l.useState(null),{trigger:c,onClose:u}=n,d=r.current,{onPointerInTransitChange:f}=o,p=l.useCallback(()=>{i(null),f(!1)},[f]),h=l.useCallback((m,v)=>{const g=m.currentTarget,y={x:m.clientX,y:m.clientY},b=pb(y,g.getBoundingClientRect()),x=hb(y,b),S=mb(v.getBoundingClientRect()),T=gb([...x,...S]);i(T),f(!0)},[f]);return l.useEffect(()=>()=>p(),[p]),l.useEffect(()=>{if(c&&d){const m=g=>h(g,d),v=g=>h(g,c);return c.addEventListener("pointerleave",m),d.addEventListener("pointerleave",v),()=>{c.removeEventListener("pointerleave",m),d.removeEventListener("pointerleave",v)}}},[c,d,h,p]),l.useEffect(()=>{if(a){const m=v=>{const g=v.target,y={x:v.clientX,y:v.clientY},b=c?.contains(g)||d?.contains(g),x=!vb(y,a);b?p():x&&(p(),u())};return document.addEventListener("pointermove",m),()=>document.removeEventListener("pointermove",m)}},[c,d,a,u,p]),E.jsx(Du,{...e,ref:s})}),[ub,db]=vr(ao,{isInside:!1}),fb=tb("TooltipContent"),Du=l.forwardRef((e,t)=>
vendor: 8,529 bytes, line 5
5{const{__scopeTooltip:n,children:o,"aria-label":r,onEscapeKeyDown:s,onPointerDownOutside:a,...i}=e,c=go(Rn,n),u=gr(n),{onClose:d}=c;return l.useEffect(()=>(document.addEventListener(Fs,d),()=>document.removeEventListener(Fs,d)),[d]),l.useEffect(()=>{if(c.trigger){const f=p=>{p.target?.contains(c.trigger)&&d()};return window.addEventListener("scroll",f,{capture:!0}),()=>window.removeEventListener("scroll",f,{capture:!0})}},[c.trigger,d]),E.jsx(_n,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:s,onPointerDownOutside:a,onFocusOutside:f=>f.preventDefault(),onDismiss:d,children:E.jsxs(hr,{"data-state":c.stateAttribute,...u,...i,ref:t,style:{...i.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"},children:[E.jsx(fb,{children:o}),E.jsx(ub,{scope:n,isInside:!0,children:E.jsx(ob,{id:c.contentId,role:"tooltip",children:r||o})})]})})});Ru.displayName=Rn;var Iu="TooltipArrow",Ou=l.forwardRef((e,t)=>{const{__scopeTooltip:n,...o}=e,r=gr(n);return db(Iu,n).isInside?null:E.jsx(mr,{...r,...o,ref:t})});Ou.displayName=Iu;function pb(e,t){const n=Math.abs(t.top-e.y),o=Math.abs(t.bottom-e.y),r=Math.abs(t.right-e.x),s=Math.abs(t.left-e.x);switch(Math.min(n,o,r,s)){case s:return"left";case r:return"right";case n:return"top";case o:return"bottom";default:throw new Error("unreachable")}}function hb(e,t,n=5){const o=[];switch(t){case"top":o.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":o.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":o.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":o.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n});break}return o}function mb(e){const{top:t,right:n,bottom:o,left:r}=e;return[{x:r,y:t},{x:n,y:t},{x:n,y:o},{x:r,y:o}]}function vb(e,t){const{x:n,y:o}=e;let r=!1;for(let s=0,a=t.length-1;s<t.length;a=s++){const i=t[s],c=t[a],u=i.x,d=i.y,f=c.x,p=c.y;d>o!=p>o&&n<(f-u)*(o-d)/(p-d)+u&&(r=!r)}return r}function gb(e){const t=e.slice();return t.sort((n,o)=>n.x<o.x?-1:n.x>o.x?1:n.y<o.y?-1:n.y>o.y?1:0),yb(t)}function yb(e){if(e.length<=1)return e.slice();const t=[];for(let o=0;o<e.length;o++){const r=e[o];for(;t.length>=2;){const s=t[t.length-1],a=t[t.length-2];if((s.x-a.x)*(r.y-a.y)>=(s.y-a.y)*(r.x-a.x))t.pop();else break}t.push(r)}t.pop();const n=[];for(let o=e.length-1;o>=0;o--){const r=e[o];for(;n.length>=2;){const s=n[n.length-1],a=n[n.length-2];if((s.x-a.x)*(r.y-a.y)>=(s.y-a.y)*(r.x-a.x))n.pop();else break}n.push(r)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}var HI=Pu,UI=Mu,GI=Tu,YI=ku,zI=Ru,KI=Ou;function bb(e,t=[]){let n=[];function o(s,a){const i=l.createContext(a);i.displayName=s+"Context";const c=n.length;n=[...n,a];const u=f=>{const{scope:p,children:h,...m}=f,v=p?.[e]?.[c]||i,g=l.useMemo(()=>m,Object.values(m));return E.jsx(v.Provider,{value:g,children:h})};u.displayName=s+"Provider";function d(f,p){const h=p?.[e]?.[c]||i,m=l.useContext(h);if(m)return m;if(a!==void 0)return a;throw new Error(`\`${f}\` must be used within \`${s}\``)}return[u,d]}const r=()=>{const s=n.map(a=>l.createContext(a));return function(i){const c=i?.[e]||s;return l.useMemo(()=>({[`__scope${e}`]:{...i,[e]:c}}),[i,c])}};return r.scopeName=e,[o,xb(r,...t)]}function xb(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const o=e.map(r=>({useScope:r(),scopeName:r.scopeName}));return function(s){const a=o.reduce((i,{useScope:c,scopeName:u})=>{const f=c(s)[`__scope${u}`];return{...i,...f}},{});return l.useMemo(()=>({[`__scope${t.scopeName}`]:a}),[a])}};return n.scopeName=t.scopeName,n}var wb=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],wa=wb.reduce((e,t)=>{const n=ur(`Primitive.${t}`),o=l.forwardRef((r,s)=>{const{asChild:a,...i}=r,c=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),E.jsx(c,{...i,ref:s})});return o.displayName=`Primitive.${t}`,{...e,[t]:o}},{});function Eb(){return nm.useSyncExternalStore(Cb,()=>!0,()=>!1)}function Cb(){return()=>{}}var Ea="Avatar",[Sb]=bb(Ea),[Pb,Au]=Sb(Ea),_u=l.forwardRef((e,t)=>{const{__scopeAvatar:n,...o}=e,[r,s]=l.useState("idle");return E.jsx(Pb,{scope:n,imageLoadingStatus:r,onImageLoadingStatusChange:s,children:E.jsx(wa.span,{...o,ref:t})})});_u.displayName=Ea;var Nu="AvatarImage",$u=l.forwardRef((e,t)=>{const{__scopeAvatar:n,src:o,onLoadingStatusChange:r=()=>{},...s}=e,a=Au(Nu,n),i=Mb(o,s),c=vt(u=>{r(u),a.onImageLoadingStatusChange(u)});return _e(()=>{i!=="idle"&&c(i)},[i,c]),i==="loaded"?E.jsx(wa.img,{...s,ref:t,src:o}):null});$u.displayName=Nu;var Fu="AvatarFallback",Lu=l.forwardRef((e,t)=>{const{__scopeAvatar:n,delayMs:o,...r}=e,s=Au(Fu,n),[a,i]=l.useState(o===void 0);return l.useEffect(()=>{if(o!==void 0){const c=window.setTimeout(()=>i(!0),o);return()=>window.clearTimeout(c)}},[o]),a&&s.imageLoadingStatus!=="loaded"?E.jsx(wa.span,{...r,ref:t}):null});Lu.displayName=Fu;function Ki(e,t){return e?t?(e.src!==t&&(e.src=t),e.complete&&e.naturalWidth>0?"loaded":"loading"):"error":"idle"}function Mb(e,{referrerPolicy:t,crossOrigin:n}){const o=Eb(),r=l.useRef(null),s=o?(r.current||(r.current=new window.Image),r.current):null,[a,i]=l.useState(()=>Ki(s,e));return _e(()=>{i(Ki(s,e))},[s,e]),_e(()=>{const c=f=>()=>{i(f)};if(!s)return;const u=c("loaded"),d=c("error");return s.addEventListener("load",u),s.addEventListener("error",d),t&&(s.referrerPolicy=t),typeof n=="string"&&(s.crossOrigin=n),()=>{s.removeEventListener("load",u),s.removeEventListener("error",d)}},[s,n,t]),a}var qI=_u,XI=$u,ZI=Lu;function qi(e){const t=Tb(e),n=l.forwardRef((o,r)=>{const{children:s,...a}=o,i=l.Children.toArray(s),c=i.find(Rb);if(c){const u=c.props.children,d=i.map(f=>f===c?l.Children.count(u)>1?l.Children.only(null):l.isValidElement(u)?u.props.children:null:f);return E.jsx(t,{...a,ref:r,children:l.isValidElement(u)?l.cloneElement(u,void 0,d):null})}return E.jsx(t,{...a,ref:r,children:s})});return n.displayName=`${e}.Slot`,n}function Tb(e){const t=l.forwardRef((n,o)=>{const{children:r,...s}=n;if(l.isValidElement(r)){const a=Ib(r),i=Db(s,r.props);return r.type!==l.Fragment&&(i.ref=o?ze(o,a):a),l.cloneElement(r,i)}return l.Children.count(r)>1?l.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var kb=Symbol("radix.slottable");function Rb(e){return l.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===kb}function Db(e,t){const n={...t};for(const o in t){const r=e[o],s=t[o];/^on[A-Z]/.test(o)?r&&s?n[o]=(...i)=>{const c=s(...i);return r(...i),c}:r&&(n[o]=r):o==="style"?n[o]={...r,...s}:o==="className"&&(n[o]=[r,s].filter(Boolean).join(" "))}return{...e,...n}}function Ib(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function Ca(e){const t=e+"CollectionProvider",[n,o]=rt(t),[r,s]=n(t,{collectionRef:{current:null},itemMap:new Map}),a=v=>{const{scope:g,children:y}=v,b=w.useRef(null),x=w.useRef(new Map).current;return E.jsx(r,{scope:g,itemMap:x,collectionRef:b,children:y})};a.displayName=t;const i=e+"CollectionSlot",c=qi(i),u=w.forwardRef((v,g)=>{const{scope:y,children:b}=v,x=s(i,y),S=he(g,x.collectionRef);return E.jsx(c,{ref:S,children:b})});u.displayName=i;const d=e+"CollectionItemSlot",f="data-radix-collection-item",p=qi(d),h=w.forwardRef((v,g)=>{const{scope:y,children:b,...x}=v,S=w.useRef(null),T=he(g,S),C=s(d,y);return w.useEffect(()=>(C.itemMap.set(S,{ref:S,...x}),()=>void C.itemMap.delete(S))),E.jsx(p,{[f]:"",ref:T,children:b})});h.displayName=d;function m(v){const g=s(e+"CollectionConsumer",v);return w.useCallback(()=>{const b=g.collectionRef.current;if(!b)return[];const x=Array.from(b.querySelectorAll(`[${f}]`));return Array.from(g.itemMap.values()).sort((C,P)=>x.indexOf(C.ref.current)-x.indexOf(P.ref.current))},[g.collectionRef,g.itemMap])}return[{Provider:a,Slot:u,ItemSlot:h},m,o]}var Ob=l.createContext(void 0);function yr(e){const t=l.useContext(Ob);return e||t||"ltr"}var ds="rovingFocusGroup.onEntryFocus",Ab={bubbles:!1,cancelable:!0},yo="RovingFocusGroup",[js,ju,_b]=Ca(yo),[Nb,br]=rt(yo,[_b]),[$b,Fb]=Nb(yo),Bu=l.forwardRef((e,t)=>
vendor: 1,745 bytes, line 5
5E.jsx(js.Provider,{scope:e.__scopeRovingFocusGroup,children:E.jsx(js.Slot,{scope:e.__scopeRovingFocusGroup,children:E.jsx(Lb,{...e,ref:t})})}));Bu.displayName=yo;var Lb=l.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:o,loop:r=!1,dir:s,currentTabStopId:a,defaultCurrentTabStopId:i,onCurrentTabStopIdChange:c,onEntryFocus:u,preventScrollOnEntryFocus:d=!1,...f}=e,p=l.useRef(null),h=he(t,p),m=yr(s),[v,g]=Mt({prop:a,defaultProp:i??null,onChange:c,caller:yo}),[y,b]=l.useState(!1),x=vt(u),S=ju(n),T=l.useRef(!1),[C,P]=l.useState(0);return l.useEffect(()=>{const _=p.current;if(_)return _.addEventListener(ds,x),()=>_.removeEventListener(ds,x)},[x]),E.jsx($b,{scope:n,orientation:o,dir:m,loop:r,currentTabStopId:v,onItemFocus:l.useCallback(_=>g(_),[g]),onItemShiftTab:l.useCallback(()=>b(!0),[]),onFocusableItemAdd:l.useCallback(()=>P(_=>_+1),[]),onFocusableItemRemove:l.useCallback(()=>P(_=>_-1),[]),children:E.jsx(re.div,{tabIndex:y||C===0?-1:0,"data-orientation":o,...f,ref:h,style:{outline:"none",...e.style},onMouseDown:J(e.onMouseDown,()=>{T.current=!0}),onFocus:J(e.onFocus,_=>{const O=!T.current;if(_.target===_.currentTarget&&O&&!y){const I=new CustomEvent(ds,Ab);if(_.currentTarget.dispatchEvent(I),!I.defaultPrevented){const $=S().filter(H=>H.focusable),G=$.find(H=>H.active),W=$.find(H=>H.id===v),K=[G,W,...$].filter(Boolean).map(H=>H.ref.current);Hu(K,d)}}T.current=!1}),onBlur:J(e.onBlur,()=>b(!1))})})}),Vu="RovingFocusGroupItem",Wu=l.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:o=!0,active:r=!1,tabStopId:s,children:a,...i}=e,c=$e(),u=s||c,d=Fb(Vu,n),f=d.currentTabStopId===u,p=ju(n),{onFocusableItemAdd:h,onFocusableItemRemove:m,currentTabStopId:v}=d;return l.useEffect(()=>{if(o)return h(),()=>m()}
vendor: 21,947 bytes, line 5
5,[o,h,m]),E.jsx(js.ItemSlot,{scope:n,id:u,focusable:o,active:r,children:E.jsx(re.span,{tabIndex:f?0:-1,"data-orientation":d.orientation,...i,ref:t,onMouseDown:J(e.onMouseDown,g=>{o?d.onItemFocus(u):g.preventDefault()}),onFocus:J(e.onFocus,()=>d.onItemFocus(u)),onKeyDown:J(e.onKeyDown,g=>{if(g.key==="Tab"&&g.shiftKey){d.onItemShiftTab();return}if(g.target!==g.currentTarget)return;const y=Vb(g,d.orientation,d.dir);if(y!==void 0){if(g.metaKey||g.ctrlKey||g.altKey||g.shiftKey)return;g.preventDefault();let x=p().filter(S=>S.focusable).map(S=>S.ref.current);if(y==="last")x.reverse();else if(y==="prev"||y==="next"){y==="prev"&&x.reverse();const S=x.indexOf(g.currentTarget);x=d.loop?Wb(x,S+1):x.slice(S+1)}setTimeout(()=>Hu(x))}}),children:typeof a=="function"?a({isCurrentTabStop:f,hasTabStop:v!=null}):a})})});Wu.displayName=Vu;var jb={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function Bb(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function Vb(e,t,n){const o=Bb(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(o))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(o)))return jb[o]}function Hu(e,t=!1){const n=document.activeElement;for(const o of e)if(o===n||(o.focus({preventScroll:t}),document.activeElement!==n))return}function Wb(e,t){return e.map((n,o)=>e[(t+o)%e.length])}var Uu=Bu,Gu=Wu;function Hb(e){const t=Ub(e),n=l.forwardRef((o,r)=>{const{children:s,...a}=o,i=l.Children.toArray(s),c=i.find(Yb);if(c){const u=c.props.children,d=i.map(f=>f===c?l.Children.count(u)>1?l.Children.only(null):l.isValidElement(u)?u.props.children:null:f);return E.jsx(t,{...a,ref:r,children:l.isValidElement(u)?l.cloneElement(u,void 0,d):null})}return E.jsx(t,{...a,ref:r,children:s})});return n.displayName=`${e}.Slot`,n}function Ub(e){const t=l.forwardRef((n,o)=>{const{children:r,...s}=n;if(l.isValidElement(r)){const a=Kb(r),i=zb(s,r.props);return r.type!==l.Fragment&&(i.ref=o?ze(o,a):a),l.cloneElement(r,i)}return l.Children.count(r)>1?l.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Gb=Symbol("radix.slottable");function Yb(e){return l.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Gb}function zb(e,t){const n={...t};for(const o in t){const r=e[o],s=t[o];/^on[A-Z]/.test(o)?r&&s?n[o]=(...i)=>{const c=s(...i);return r(...i),c}:r&&(n[o]=r):o==="style"?n[o]={...r,...s}:o==="className"&&(n[o]=[r,s].filter(Boolean).join(" "))}return{...e,...n}}function Kb(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Bs=["Enter"," "],qb=["ArrowDown","PageUp","Home"],Yu=["ArrowUp","PageDown","End"],Xb=[...qb,...Yu],Zb={ltr:[...Bs,"ArrowRight"],rtl:[...Bs,"ArrowLeft"]},Qb={ltr:["ArrowLeft"],rtl:["ArrowRight"]},bo="Menu",[io,Jb,e0]=Ca(bo),[mn,zu]=rt(bo,[e0,Kt,br]),xr=Kt(),Ku=br(),[t0,vn]=mn(bo),[n0,xo]=mn(bo),qu=e=>{const{__scopeMenu:t,open:n=!1,children:o,dir:r,onOpenChange:s,modal:a=!0}=e,i=xr(t),[c,u]=l.useState(null),d=l.useRef(!1),f=vt(s),p=yr(r);return l.useEffect(()=>{const h=()=>{d.current=!0,document.addEventListener("pointerdown",m,{capture:!0,once:!0}),document.addEventListener("pointermove",m,{capture:!0,once:!0})},m=()=>d.current=!1;return document.addEventListener("keydown",h,{capture:!0}),()=>{document.removeEventListener("keydown",h,{capture:!0}),document.removeEventListener("pointerdown",m,{capture:!0}),document.removeEventListener("pointermove",m,{capture:!0})}},[]),E.jsx(pr,{...i,children:E.jsx(t0,{scope:t,open:n,onOpenChange:f,content:c,onContentChange:u,children:E.jsx(n0,{scope:t,onClose:l.useCallback(()=>f(!1),[f]),isUsingKeyboardRef:d,dir:p,modal:a,children:o})})})};qu.displayName=bo;var o0="MenuAnchor",Sa=l.forwardRef((e,t)=>{const{__scopeMenu:n,...o}=e,r=xr(n);return E.jsx(vo,{...r,...o,ref:t})});Sa.displayName=o0;var Pa="MenuPortal",[r0,Xu]=mn(Pa,{forceMount:void 0}),Zu=e=>{const{__scopeMenu:t,forceMount:n,children:o,container:r}=e,s=vn(Pa,t);return E.jsx(r0,{scope:t,forceMount:n,children:E.jsx(Ze,{present:n||s.open,children:E.jsx(Nn,{asChild:!0,container:r,children:o})})})};Zu.displayName=Pa;var it="MenuContent",[s0,Ma]=mn(it),Qu=l.forwardRef((e,t)=>{const n=Xu(it,e.__scopeMenu),{forceMount:o=n.forceMount,...r}=e,s=vn(it,e.__scopeMenu),a=xo(it,e.__scopeMenu);return E.jsx(io.Provider,{scope:e.__scopeMenu,children:E.jsx(Ze,{present:o||s.open,children:E.jsx(io.Slot,{scope:e.__scopeMenu,children:a.modal?E.jsx(a0,{...r,ref:t}):E.jsx(i0,{...r,ref:t})})})})}),a0=l.forwardRef((e,t)=>{const n=vn(it,e.__scopeMenu),o=l.useRef(null),r=he(t,o);return l.useEffect(()=>{const s=o.current;if(s)return cr(s)},[]),E.jsx(Ta,{...e,ref:r,trapFocus:n.open,disableOutsidePointerEvents:n.open,disableOutsideScroll:!0,onFocusOutside:J(e.onFocusOutside,s=>s.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>n.onOpenChange(!1)})}),i0=l.forwardRef((e,t)=>{const n=vn(it,e.__scopeMenu);return E.jsx(Ta,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>n.onOpenChange(!1)})}),l0=Hb("MenuContent.ScrollLock"),Ta=l.forwardRef((e,t)=>{const{__scopeMenu:n,loop:o=!1,trapFocus:r,onOpenAutoFocus:s,onCloseAutoFocus:a,disableOutsidePointerEvents:i,onEntryFocus:c,onEscapeKeyDown:u,onPointerDownOutside:d,onFocusOutside:f,onInteractOutside:p,onDismiss:h,disableOutsideScroll:m,...v}=e,g=vn(it,n),y=xo(it,n),b=xr(n),x=Ku(n),S=Jb(n),[T,C]=l.useState(null),P=l.useRef(null),_=he(t,P,g.onContentChange),O=l.useRef(0),I=l.useRef(""),$=l.useRef(0),G=l.useRef(null),W=l.useRef("right"),B=l.useRef(0),K=m?lr:l.Fragment,H=m?{as:l0,allowPinchZoom:!0}:void 0,U=R=>{const D=I.current+R,L=S().filter(N=>!N.disabled),k=document.activeElement,M=L.find(N=>N.ref.current===k)?.textValue,F=L.map(N=>N.textValue),A=x0(F,D,M),z=L.find(N=>N.textValue===A)?.ref.current;(function N(Y){I.current=Y,window.clearTimeout(O.current),Y!==""&&(O.current=window.setTimeout(()=>N(""),1e3))})(D),z&&setTimeout(()=>z.focus())};l.useEffect(()=>()=>window.clearTimeout(O.current),[]),dr();const q=l.useCallback(R=>W.current===G.current?.side&&E0(R,G.current?.area),[]);return E.jsx(s0,{scope:n,searchRef:I,onItemEnter:l.useCallback(R=>{q(R)&&R.preventDefault()},[q]),onItemLeave:l.useCallback(R=>{q(R)||(P.current?.focus(),C(null))},[q]),onTriggerLeave:l.useCallback(R=>{q(R)&&R.preventDefault()},[q]),pointerGraceTimerRef:$,onPointerGraceIntentChange:l.useCallback(R=>{G.current=R},[]),children:E.jsx(K,{...H,children:E.jsx(mo,{asChild:!0,trapped:r,onMountAutoFocus:J(s,R=>{R.preventDefault(),P.current?.focus({preventScroll:!0})}),onUnmountAutoFocus:a,children:E.jsx(_n,{asChild:!0,disableOutsidePointerEvents:i,onEscapeKeyDown:u,onPointerDownOutside:d,onFocusOutside:f,onInteractOutside:p,onDismiss:h,children:E.jsx(Uu,{asChild:!0,...x,dir:y.dir,orientation:"vertical",loop:o,currentTabStopId:T,onCurrentTabStopIdChange:C,onEntryFocus:J(c,R=>{y.isUsingKeyboardRef.current||R.preventDefault()}),preventScrollOnEntryFocus:!0,children:E.jsx(hr,{role:"menu","aria-orientation":"vertical","data-state":hd(g.open),"data-radix-menu-content":"",dir:y.dir,...b,...v,ref:_,style:{outline:"none",...v.style},onKeyDown:J(v.onKeyDown,R=>{const L=R.target.closest("[data-radix-menu-content]")===R.currentTarget,k=R.ctrlKey||R.altKey||R.metaKey,M=R.key.length===1;L&&(R.key==="Tab"&&R.preventDefault(),!k&&M&&U(R.key));const F=P.current;if(R.target!==F||!Xb.includes(R.key))return;R.preventDefault();const z=S().filter(N=>!N.disabled).map(N=>N.ref.current);Yu.includes(R.key)&&z.reverse(),y0(z)}),onBlur:J(e.onBlur,R=>{R.currentTarget.contains(R.target)||(window.clearTimeout(O.current),I.current="")}),onPointerMove:J(e.onPointerMove,lo(R=>{const D=R.target,L=B.current!==R.clientX;if(R.currentTarget.contains(D)&&L){const k=R.clientX>B.current?"right":"left";W.current=k,B.current=R.clientX}}))})})})})})})});Qu.displayName=it;var c0="MenuGroup",ka=l.forwardRef((e,t)=>{const{__scopeMenu:n,...o}=e;return E.jsx(re.div,{role:"group",...o,ref:t})});ka.displayName=c0;var u0="MenuLabel",Ju=l.forwardRef((e,t)=>{const{__scopeMenu:n,...o}=e;return E.jsx(re.div,{...o,ref:t})});Ju.displayName=u0;var Xo="MenuItem",Xi="menu.itemSelect",wr=l.forwardRef((e,t)=>{const{disabled:n=!1,onSelect:o,...r}=e,s=l.useRef(null),a=xo(Xo,e.__scopeMenu),i=Ma(Xo,e.__scopeMenu),c=he(t,s),u=l.useRef(!1),d=()=>{const f=s.current;if(!n&&f){const p=new CustomEvent(Xi,{bubbles:!0,cancelable:!0});f.addEventListener(Xi,h=>o?.(h),{once:!0}),Bc(f,p),p.defaultPrevented?u.current=!1:a.onClose()}};return E.jsx(ed,{...r,ref:c,disabled:n,onClick:J(e.onClick,d),onPointerDown:f=>{e.onPointerDown?.(f),u.current=!0},onPointerUp:J(e.onPointerUp,f=>{u.current||f.currentTarget?.click()}),onKeyDown:J(e.onKeyDown,f=>{const p=i.searchRef.current!=="";n||p&&f.key===" "||Bs.includes(f.key)&&(f.currentTarget.click(),f.preventDefault())})})});wr.displayName=Xo;var ed=l.forwardRef((e,t)=>{const{__scopeMenu:n,disabled:o=!1,textValue:r,...s}=e,a=Ma(Xo,n),i=Ku(n),c=l.useRef(null),u=he(t,c),[d,f]=l.useState(!1),[p,h]=l.useState("");return l.useEffect(()=>{const m=c.current;m&&h((m.textContent??"").trim())},[s.children]),E.jsx(io.ItemSlot,{scope:n,disabled:o,textValue:r??p,children:E.jsx(Gu,{asChild:!0,...i,focusable:!o,children:E.jsx(re.div,{role:"menuitem","data-highlighted":d?"":void 0,"aria-disabled":o||void 0,"data-disabled":o?"":void 0,...s,ref:u,onPointerMove:J(e.onPointerMove,lo(m=>{o?a.onItemLeave(m):(a.onItemEnter(m),m.defaultPrevented||m.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:J(e.onPointerLeave,lo(m=>a.onItemLeave(m))),onFocus:J(e.onFocus,()=>f(!0)),onBlur:J(e.onBlur,()=>f(!1))})})})}),d0="MenuCheckboxItem",td=l.forwardRef((e,t)=>{const{checked:n=!1,onCheckedChange:o,...r}=e;return E.jsx(ad,{scope:e.__scopeMenu,checked:n,children:E.jsx(wr,{role:"menuitemcheckbox","aria-checked":Zo(n)?"mixed":n,...r,ref:t,"data-state":Da(n),onSelect:J(r.onSelect,()=>o?.(Zo(n)?!0:!n),{checkForDefaultPrevented:!1})})})});td.displayName=d0;var nd="MenuRadioGroup",[f0,p0]=mn(nd,{value:void 0,onValueChange:()=>{}}),od=l.forwardRef((e,t)=>{const{value:n,onValueChange:o,...r}=e,s=vt(o);return E.jsx(f0,{scope:e.__scopeMenu,value:n,onValueChange:s,children:E.jsx(ka,{...r,ref:t})})});od.displayName=nd;var rd="MenuRadioItem",sd=l.forwardRef((e,t)=>{const{value:n,...o}=e,r=p0(rd,e.__scopeMenu),s=n===r.value;return E.jsx(ad,{scope:e.__scopeMenu,checked:s,children:E.jsx(wr,{role:"menuitemradio","aria-checked":s,...o,ref:t,"data-state":Da(s),onSelect:J(o.onSelect,()=>r.onValueChange?.(n),{checkForDefaultPrevented:!1})})})});sd.displayName=rd;var Ra="MenuItemIndicator",[ad,h0]=mn(Ra,{checked:!1}),id=l.forwardRef((e,t)=>{const{__scopeMenu:n,forceMount:o,...r}=e,s=h0(Ra,n);return E.jsx(Ze,{present:o||Zo(s.checked)||s.checked===!0,children:E.jsx(re.span,{...r,ref:t,"data-state":Da(s.checked)})})});id.displayName=Ra;var m0="MenuSeparator",ld=l.forwardRef((e,t)=>{const{__scopeMenu:n,...o}=e;return E.jsx(re.div,{role:"separator","aria-orientation":"horizontal",...o,ref:t})});ld.displayName=m0;var v0="MenuArrow",cd=l.forwardRef((e,t)=>{const{__scopeMenu:n,...o}=e,r=xr(n);return E.jsx(mr,{...r,...o,ref:t})});cd.displayName=v0;var g0="MenuSub",[QI,ud]=mn(g0),Jn="MenuSubTrigger",dd=l.forwardRef((e,t)=>{const n=vn(Jn,e.__scopeMenu),o=xo(Jn,e.__scopeMenu),r=ud(Jn,e.__scopeMenu),s=Ma(Jn,e.__scopeMenu),a=l.useRef(null),{pointerGraceTimerRef:i,onPointerGraceIntentChange:c}=s,u={__scopeMenu:e.__scopeMenu},d=l.useCallback(()=>{a.current&&window.clearTimeout(a.current),a.current=null},[]);return l.useEffect(()=>d,[d]),l.useEffect(()=>{const f=i.current;return()=>{window.clearTimeout(f),c(null)}},[i,c]),E.jsx(Sa,{asChild:!0,...u,children:E.jsx(ed,{id:r.triggerId,"aria-haspopup":"menu","aria-expanded":n.open,"aria-controls":r.contentId,"data-state":hd(n.open),...e,ref:ze(t,r.onTriggerChange),onClick:f=>{e.onClick?.(f),!(e.disabled||f.defaultPrevented)&&(f.currentTarget.focus(),n.open||n.onOpenChange(!0))},onPointerMove:J(e.onPointerMove,lo(f=>{s.onItemEnter(f),!f.defaultPrevented&&!e.disabled&&!n.open&&!a.current&&(s.onPointerGraceIntentChange(null),a.current=window.setTimeout(()=>{n.onOpenChange(!0),d()},100))})),onPointerLeave:J(e.onPointerLeave,lo(f=>{d();const p=n.content?.getBoundingClientRect();if(p){const h=n.content?.dataset.side,m=h==="right",v=m?-5:5,g=p[m?"left":"right"],y=p[m?"right":"left"];s.onPointerGraceIntentChange({area:[{x:f.clientX+v,y:f.clientY},{x:g,y:p.top},{x:y,y:p.top},{x:y,y:p.bottom},{x:g,y:p.bottom}],side:h}),window.clearTimeout(i.current),i.current=window.setTimeout(()=>s.onPointerGraceIntentChange(null),300)}else{if(s.onTriggerLeave(f),f.defaultPrevented)return;s.onPointerGraceIntentChange(null)}})),onKeyDown:J(e.onKeyDown,f=>{const p=s.searchRef.current!=="";e.disabled||p&&f.key===" "||Zb[o.dir].includes(f.key)&&(n.onOpenChange(!0),n.content?.focus(),f.preventDefault())})})})});dd.displayName=Jn;var fd="MenuSubContent",pd=l.forwardRef((e,t)=>{const n=Xu(it,e.__scopeMenu),{forceMount:o=n.forceMount,...r}=e,s=vn(it,e.__scopeMenu),a=xo(it,e.__scopeMenu),i=ud(fd,e.__scopeMenu),c=l.useRef(null),u=he(t,c);return E.jsx(io.Provider,{scope:e.__scopeMenu,children:E.jsx(Ze,{present:o||s.open,children:E.jsx(io.Slot,{scope:e.__scopeMenu,children:E.jsx(Ta,{id:i.contentId,"aria-labelledby":i.triggerId,...r,ref:u,align:"start",side:a.dir==="rtl"?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:d=>{a.isUsingKeyboardRef.current&&c.current?.focus(),d.preventDefault()},onCloseAutoFocus:d=>d.preventDefault(),onFocusOutside:J(e.onFocusOutside,d=>{d.target!==i.trigger&&s.onOpenChange(!1)}),onEscapeKeyDown:J(e.onEscapeKeyDown,d=>{a.onClose(),d.preventDefault()}),onKeyDown:J(e.onKeyDown,d=>{const f=d.currentTarget.contains(d.target),p=Qb[a.dir].includes(d.key);f&&p&&(s.onOpenChange(!1),i.trigger?.focus(),d.preventDefault())})})})})})});pd.displayName=fd;function hd(e){return e?"open":"closed"}function Zo(e){return e==="indeterminate"}function Da(e){return Zo(e)?"indeterminate":e?"checked":"unchecked"}function y0(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function b0(e,t){return e.map((n,o)=>e[(t+o)%e.length])}function x0(e,t,n){const r=t.length>1&&Array.from(t).every(u=>u===t[0])?t[0]:t,s=n?e.indexOf(n):-1;let a=b0(e,Math.max(s,0));r.length===1&&(a=a.filter(u=>u!==n));const c=a.find(u=>u.toLowerCase().startsWith(r.toLowerCase()));return c!==n?c:void 0}function w0(e,t){const{x:n,y:o}=e;let r=!1;for(let s=0,a=t.length-1;s<t.length;a=s++){const i=t[s],c=t[a],u=i.x,d=i.y,f=c.x,p=c.y;d>o!=p>o&&n<(f-u)*(o-d)/(p-d)+u&&(r=!r)}return r}function E0(e,t){if(!t)return!1;const n={x:e.clientX,y:e.clientY};return w0(n,t)}function lo(e){return t=>t.pointerType==="mouse"?e(t):void 0}var C0=qu,S0=Sa,P0=Zu,M0=Qu,T0=ka,k0=Ju,R0=wr,D0=td,I0=od,O0=sd,A0=id,_0=ld,N0=cd,$0=dd,F0=pd,Er="DropdownMenu",[L0]=rt(Er,[zu]),Ke=zu(),[j0,md]=L0(Er),vd=e=>{const{__scopeDropdownMenu:t,children:n,dir:o,open:r,defaultOpen:s,onOpenChange:a,modal:i=!0}=e,c=Ke(t),u=l.useRef(null),[d,f]=Mt({prop:r,defaultProp:s??!1,onChange:a,caller:Er});return E.jsx(j0,{scope:t,triggerId:$e(),triggerRef:u,contentId:$e(),open:d,onOpenChange:f,onOpenToggle:l.useCallback(()=>f(p=>!p),[f]),modal:i,children:E.jsx(C0,{...c,open:d,onOpenChange:f,dir:o,modal:i,children:n})})};vd.displayName=Er;var gd="DropdownMenuTrigger",yd=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,disabled:o=!1,...r}=e,s=md(gd,n),a=Ke(n);return E.jsx(S0,{asChild:!0,...a,children:E.jsx(re.button,{type:"button",id:s.triggerId,"aria-haspopup":"menu","aria-expanded":s.open,"aria-controls":s.open?s.contentId:void 0,"data-state":s.open?"open":"closed","data-disabled":o?"":void 0,disabled:o,...r,ref:ze(t,s.triggerRef),onPointerDown:J(e.onPointerDown,i=>{!o&&i.button===0&&i.ctrlKey===!1&&(s.onOpenToggle(),s.open||i.preventDefault())}),onKeyDown:J(e.onKeyDown,i=>{o||(["Enter"," "].includes(i.key)&&s.onOpenToggle(),i.key==="ArrowDown"&&s.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(i.key)&&i.preventDefault())})})})});yd.displayName=gd;var B0="DropdownMenuPortal",bd=e=>{const{__scopeDropdownMenu:t,...n}=e,o=Ke(t);return E.jsx(P0,{...o,...n})};bd.displayName=B0;var xd="DropdownMenuContent",wd=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=md(xd,n),s=Ke(n),a=l.useRef(!1);return E.jsx(M0,{id:r.contentId,"aria-labelledby":r.triggerId,...s,...o,ref:t,onCloseAutoFocus:J(e.onCloseAutoFocus,i=>{a.current||r.triggerRef.current?.focus(),a.current=!1,i.preventDefault()}),onInteractOutside:J(e.onInteractOutside,i=>{const c=i.detail.originalEvent,u=c.button===0&&c.ctrlKey===!0,d=c.button===2||u;(!r.modal||d)&&(a.current=!0)}),style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});wd.displayName=xd;var V0="DropdownMenuGroup",Ed=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=Ke(n);return E.jsx(T0,{...r,...o,ref:t})});Ed.displayName=V0;var W0="DropdownMenuLabel",Cd=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=Ke(n);return E.jsx(k0,{...r,...o,ref:t})});Cd.displayName=W0;var H0="DropdownMenuItem",Sd=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=Ke(n);return E.jsx(R0,{...r,...o,ref:t})});Sd.displayName=H0;var U0="DropdownMenuCheckboxItem",G0=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=Ke(n);return E.jsx(D0,{...r,...o,ref:t})});G0.displayName=U0;var Y0="DropdownMenuRadioGroup",z0=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=Ke(n);return E.jsx(I0,{...r,...o,ref:t})});z0.displayName=Y0;var K0="DropdownMenuRadioItem",q0=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=Ke(n);return E.jsx(O0,{...r,...o,ref:t})});q0.displayName=K0;var X0="DropdownMenuItemIndicator",Z0=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=Ke(n);return E.jsx(A0,{...r,...o,ref:t})});Z0.displayName=X0;var Q0="DropdownMenuSeparator",Pd=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=Ke(n);return E.jsx(_0,{...r,...o,ref:t})});Pd.displayName=Q0;var J0="DropdownMenuArrow",ex=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=Ke(n);return E.jsx(N0,{...r,...o,ref:t})});ex.displayName=J0;var tx="DropdownMenuSubTrigger",nx=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=Ke(n);return E.jsx($0,{...r,...o,ref:t})});nx.displayName=tx;var ox="DropdownMenuSubContent",rx=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=Ke(n);return E.jsx(F0,{...r,...o,ref:t,style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});rx.displayName=ox;var JI=vd,e2=yd,t2=bd,n2=wd,o2=Ed,r2=Cd,s2=Sd,a2=Pd;function sx(e){const t=ax(e),n=l.forwardRef((o,r)=>{const{children:s,...a}=o,i=l.Children.toArray(s),c=i.find(lx);if(c){const u=c.props.children,d=i.map(f=>f===c?l.Children.count(u)>1?l.Children.only(null):l.isValidElement(u)?u.props.children:null:f);return E.jsx(t,{...a,ref:r,children:l.isValidElement(u)?l.cloneElement(u,void 0,d):null})}return E.jsx(t,{...a,ref:r,children:s})});return n.displayName=`${e}.Slot`,n}function ax(e){const t=l.forwardRef((n,o)=>{const{children:r,...s}=n;if(l.isValidElement(r)){const a=ux(r),i=cx(s,r.props);return r.type!==l.Fragment&&(i.ref=o?ze(o,a):a),l.cloneElement(r,i)}return l.Children.count(r)>1?l.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var ix=Symbol("radix.slottable");function lx(e){return l.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===ix}function cx(e,t){const n={...t};for(const o in t){const r=e[o],s=t[o];/^on[A-Z]/.test(o)?r&&s?n[o]=(...i)=>{const c=s(...i);return r(...i),c}:r&&(n[o]=r):o==="style"?n[o]={...r,...s}:o==="className"&&(n[o]=[r,s].filter(Boolean).join(" "))}return{...e,...n}}function ux(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Cr="Popover",[Md]=rt(Cr,[Kt]),wo=Kt(),[dx,qt]=Md(Cr),Td=e=>{const{__scopePopover:t,children:n,open:o,defaultOpen:r,onOpenChange:s,modal:a=!1}=e,i=wo(t),c=l.useRef(null),[u,d]=l.useState(!1),[f,p]=Mt({prop:o,defaultProp:r??!1,onChange:s,caller:Cr});return E.jsx(pr,{...i,children:E.jsx(dx,{scope:t,contentId:$e(),triggerRef:c,open:f,onOpenChange:p,onOpenToggle:l.useCallback(()=>p(h=>!h),[p]),hasCustomAnchor:u,onCustomAnchorAdd:l.useCallback(()=>d(!0),[]),onCustomAnchorRemove:l.useCallback(()=>d(!1),[]),modal:a,children:n})})};Td.displayName=Cr;var kd="PopoverAnchor",fx=l.forwardRef((e,t)=>{const{__scopePopover:n,...o}=e,r=qt(kd,n),s=wo(n),{onCustomAnchorAdd:a,onCustomAnchorRemove:i}=r;return l.useEffect(()=>(a(),()=>i()),[a,i]),E.jsx(vo,{...s,...o,ref:t})});fx.displayName=kd;var Rd="PopoverTrigger",Dd=l.forwardRef((e,t)=>{const{__scopePopover:n,...o}=e,r=qt(Rd,n),s=wo(n),a=he(t,r.triggerRef),i=E.jsx(re.button,{type:"button","aria-haspopup":"dialog","aria-expanded":r.open,"aria-controls":r.contentId,"data-state":Nd(r.open),...o,ref:a,onClick:J(e.onClick,r.onOpenToggle)});
vendor: 18,792 bytes, line 5
5return r.hasCustomAnchor?i:E.jsx(vo,{asChild:!0,...s,children:i})});Dd.displayName=Rd;var Ia="PopoverPortal",[px,hx]=Md(Ia,{forceMount:void 0}),Id=e=>{const{__scopePopover:t,forceMount:n,children:o,container:r}=e,s=qt(Ia,t);return E.jsx(px,{scope:t,forceMount:n,children:E.jsx(Ze,{present:n||s.open,children:E.jsx(Nn,{asChild:!0,container:r,children:o})})})};Id.displayName=Ia;var Dn="PopoverContent",Od=l.forwardRef((e,t)=>{const n=hx(Dn,e.__scopePopover),{forceMount:o=n.forceMount,...r}=e,s=qt(Dn,e.__scopePopover);return E.jsx(Ze,{present:o||s.open,children:s.modal?E.jsx(vx,{...r,ref:t}):E.jsx(gx,{...r,ref:t})})});Od.displayName=Dn;var mx=sx("PopoverContent.RemoveScroll"),vx=l.forwardRef((e,t)=>{const n=qt(Dn,e.__scopePopover),o=l.useRef(null),r=he(t,o),s=l.useRef(!1);return l.useEffect(()=>{const a=o.current;if(a)return cr(a)},[]),E.jsx(lr,{as:mx,allowPinchZoom:!0,children:E.jsx(Ad,{...e,ref:r,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:J(e.onCloseAutoFocus,a=>{a.preventDefault(),s.current||n.triggerRef.current?.focus()}),onPointerDownOutside:J(e.onPointerDownOutside,a=>{const i=a.detail.originalEvent,c=i.button===0&&i.ctrlKey===!0,u=i.button===2||c;s.current=u},{checkForDefaultPrevented:!1}),onFocusOutside:J(e.onFocusOutside,a=>a.preventDefault(),{checkForDefaultPrevented:!1})})})}),gx=l.forwardRef((e,t)=>{const n=qt(Dn,e.__scopePopover),o=l.useRef(!1),r=l.useRef(!1);return E.jsx(Ad,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:s=>{e.onCloseAutoFocus?.(s),s.defaultPrevented||(o.current||n.triggerRef.current?.focus(),s.preventDefault()),o.current=!1,r.current=!1},onInteractOutside:s=>{e.onInteractOutside?.(s),s.defaultPrevented||(o.current=!0,s.detail.originalEvent.type==="pointerdown"&&(r.current=!0));const a=s.target;n.triggerRef.current?.contains(a)&&s.preventDefault(),s.detail.originalEvent.type==="focusin"&&r.current&&s.preventDefault()}})}),Ad=l.forwardRef((e,t)=>{const{__scopePopover:n,trapFocus:o,onOpenAutoFocus:r,onCloseAutoFocus:s,disableOutsidePointerEvents:a,onEscapeKeyDown:i,onPointerDownOutside:c,onFocusOutside:u,onInteractOutside:d,...f}=e,p=qt(Dn,n),h=wo(n);return dr(),E.jsx(mo,{asChild:!0,loop:!0,trapped:o,onMountAutoFocus:r,onUnmountAutoFocus:s,children:E.jsx(_n,{asChild:!0,disableOutsidePointerEvents:a,onInteractOutside:d,onEscapeKeyDown:i,onPointerDownOutside:c,onFocusOutside:u,onDismiss:()=>p.onOpenChange(!1),children:E.jsx(hr,{"data-state":Nd(p.open),role:"dialog",id:p.contentId,...h,...f,ref:t,style:{...f.style,"--radix-popover-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-popover-content-available-width":"var(--radix-popper-available-width)","--radix-popover-content-available-height":"var(--radix-popper-available-height)","--radix-popover-trigger-width":"var(--radix-popper-anchor-width)","--radix-popover-trigger-height":"var(--radix-popper-anchor-height)"}})})})}),_d="PopoverClose",yx=l.forwardRef((e,t)=>{const{__scopePopover:n,...o}=e,r=qt(_d,n);return E.jsx(re.button,{type:"button",...o,ref:t,onClick:J(e.onClick,()=>r.onOpenChange(!1))})});yx.displayName=_d;var bx="PopoverArrow",xx=l.forwardRef((e,t)=>{const{__scopePopover:n,...o}=e,r=wo(n);return E.jsx(mr,{...r,...o,ref:t})});xx.displayName=bx;function Nd(e){return e?"open":"closed"}var i2=Td,l2=Dd,c2=Id,u2=Od,Zi=1,wx=.9,Ex=.8,Cx=.17,fs=.1,ps=.999,Sx=.9999,Px=.99,Mx=/[\\\/_+.#"@\[\(\{&]/,Tx=/[\\\/_+.#"@\[\(\{&]/g,kx=/[\s-]/,$d=/[\s-]/g;function Vs(e,t,n,o,r,s,a){if(s===t.length)return r===e.length?Zi:Px;var i=`${r},${s}`;if(a[i]!==void 0)return a[i];for(var c=o.charAt(s),u=n.indexOf(c,r),d=0,f,p,h,m;u>=0;)f=Vs(e,t,n,o,u+1,s+1,a),f>d&&(u===r?f*=Zi:Mx.test(e.charAt(u-1))?(f*=Ex,h=e.slice(r,u-1).match(Tx),h&&r>0&&(f*=Math.pow(ps,h.length))):kx.test(e.charAt(u-1))?(f*=wx,m=e.slice(r,u-1).match($d),m&&r>0&&(f*=Math.pow(ps,m.length))):(f*=Cx,r>0&&(f*=Math.pow(ps,u-r))),e.charAt(u)!==t.charAt(s)&&(f*=Sx)),(f<fs&&n.charAt(u-1)===o.charAt(s+1)||o.charAt(s+1)===o.charAt(s)&&n.charAt(u-1)!==o.charAt(s))&&(p=Vs(e,t,n,o,u+1,s+2,a),p*fs>f&&(f=p*fs)),f>d&&(d=f),u=n.indexOf(c,u+1);return a[i]=d,d}function Qi(e){return e.toLowerCase().replace($d," ")}function Rx(e,t,n){return e=n&&n.length>0?`${e+" "+n.join(" ")}`:e,Vs(e,t,Qi(e),Qi(t),0,0,{})}var Kn='[cmdk-group=""]',hs='[cmdk-group-items=""]',Dx='[cmdk-group-heading=""]',Fd='[cmdk-item=""]',Ji=`${Fd}:not([aria-disabled="true"])`,Ws="cmdk-item-select",bn="data-value",Ix=(e,t,n)=>Rx(e,t,n),Ld=l.createContext(void 0),Eo=()=>l.useContext(Ld),jd=l.createContext(void 0),Oa=()=>l.useContext(jd),Bd=l.createContext(void 0),Vd=l.forwardRef((e,t)=>{let n=xn(()=>{var k,M;return{search:"",value:(M=(k=e.value)!=null?k:e.defaultValue)!=null?M:"",selectedItemId:void 0,filtered:{count:0,items:new Map,groups:new Set}}}),o=xn(()=>new Set),r=xn(()=>new Map),s=xn(()=>new Map),a=xn(()=>new Set),i=Wd(e),{label:c,children:u,value:d,onValueChange:f,filter:p,shouldFilter:h,loop:m,disablePointerSelection:v=!1,vimBindings:g=!0,...y}=e,b=$e(),x=$e(),S=$e(),T=l.useRef(null),C=Wx();dn(()=>{if(d!==void 0){let k=d.trim();n.current.value=k,P.emit()}},[d]),dn(()=>{C(6,W)},[]);let P=l.useMemo(()=>({subscribe:k=>(a.current.add(k),()=>a.current.delete(k)),snapshot:()=>n.current,setState:(k,M,F)=>{var A,z,N,Y;if(!Object.is(n.current[k],M)){if(n.current[k]=M,k==="search")G(),I(),C(1,$);else if(k==="value"){if(document.activeElement.hasAttribute("cmdk-input")||document.activeElement.hasAttribute("cmdk-root")){let te=document.getElementById(S);te?te.focus():(A=document.getElementById(b))==null||A.focus()}if(C(7,()=>{var te;n.current.selectedItemId=(te=B())==null?void 0:te.id,P.emit()}),F||C(5,W),((z=i.current)==null?void 0:z.value)!==void 0){let te=M??"";(Y=(N=i.current).onValueChange)==null||Y.call(N,te);return}}P.emit()}},emit:()=>{a.current.forEach(k=>k())}}),[]),_=l.useMemo(()=>({value:(k,M,F)=>{var A;M!==((A=s.current.get(k))==null?void 0:A.value)&&(s.current.set(k,{value:M,keywords:F}),n.current.filtered.items.set(k,O(M,F)),C(2,()=>{I(),P.emit()}))},item:(k,M)=>(o.current.add(k),M&&(r.current.has(M)?r.current.get(M).add(k):r.current.set(M,new Set([k]))),C(3,()=>{G(),I(),n.current.value||$(),P.emit()}),()=>{s.current.delete(k),o.current.delete(k),n.current.filtered.items.delete(k);let F=B();C(4,()=>{G(),F?.getAttribute("id")===k&&$(),P.emit()})}),group:k=>(r.current.has(k)||r.current.set(k,new Set),()=>{s.current.delete(k),r.current.delete(k)}),filter:()=>i.current.shouldFilter,label:c||e["aria-label"],getDisablePointerSelection:()=>i.current.disablePointerSelection,listId:b,inputId:S,labelId:x,listInnerRef:T}),[]);function O(k,M){var F,A;let z=(A=(F=i.current)==null?void 0:F.filter)!=null?A:Ix;return k?z(k,n.current.search,M):0}function I(){if(!n.current.search||i.current.shouldFilter===!1)return;let k=n.current.filtered.items,M=[];n.current.filtered.groups.forEach(A=>{let z=r.current.get(A),N=0;z.forEach(Y=>{let te=k.get(Y);N=Math.max(te,N)}),M.push([A,N])});let F=T.current;K().sort((A,z)=>{var N,Y;let te=A.getAttribute("id"),ae=z.getAttribute("id");return((N=k.get(ae))!=null?N:0)-((Y=k.get(te))!=null?Y:0)}).forEach(A=>{let z=A.closest(hs);z?z.appendChild(A.parentElement===z?A:A.closest(`${hs} > *`)):F.appendChild(A.parentElement===F?A:A.closest(`${hs} > *`))}),M.sort((A,z)=>z[1]-A[1]).forEach(A=>{var z;let N=(z=T.current)==null?void 0:z.querySelector(`${Kn}[${bn}="${encodeURIComponent(A[0])}"]`);N?.parentElement.appendChild(N)})}function $(){let k=K().find(F=>F.getAttribute("aria-disabled")!=="true"),M=k?.getAttribute(bn);P.setState("value",M||void 0)}function G(){var k,M,F,A;if(!n.current.search||i.current.shouldFilter===!1){n.current.filtered.count=o.current.size;return}n.current.filtered.groups=new Set;let z=0;for(let N of o.current){let Y=(M=(k=s.current.get(N))==null?void 0:k.value)!=null?M:"",te=(A=(F=s.current.get(N))==null?void 0:F.keywords)!=null?A:[],ae=O(Y,te);n.current.filtered.items.set(N,ae),ae>0&&z++}for(let[N,Y]of r.current)for(let te of Y)if(n.current.filtered.items.get(te)>0){n.current.filtered.groups.add(N);break}n.current.filtered.count=z}function W(){var k,M,F;let A=B();A&&(((k=A.parentElement)==null?void 0:k.firstChild)===A&&((F=(M=A.closest(Kn))==null?void 0:M.querySelector(Dx))==null||F.scrollIntoView({block:"nearest"})),A.scrollIntoView({block:"nearest"}))}function B(){var k;return(k=T.current)==null?void 0:k.querySelector(`${Fd}[aria-selected="true"]`)}function K(){var k;return Array.from(((k=T.current)==null?void 0:k.querySelectorAll(Ji))||[])}function H(k){let M=K()[k];M&&P.setState("value",M.getAttribute(bn))}function U(k){var M;let F=B(),A=K(),z=A.findIndex(Y=>Y===F),N=A[z+k];(M=i.current)!=null&&M.loop&&(N=z+k<0?A[A.length-1]:z+k===A.length?A[0]:A[z+k]),N&&P.setState("value",N.getAttribute(bn))}function q(k){let M=B(),F=M?.closest(Kn),A;for(;F&&!A;)F=k>0?Bx(F,Kn):Vx(F,Kn),A=F?.querySelector(Ji);A?P.setState("value",A.getAttribute(bn)):U(k)}let R=()=>H(K().length-1),D=k=>{k.preventDefault(),k.metaKey?R():k.altKey?q(1):U(1)},L=k=>{k.preventDefault(),k.metaKey?H(0):k.altKey?q(-1):U(-1)};return l.createElement(re.div,{ref:t,tabIndex:-1,...y,"cmdk-root":"",onKeyDown:k=>{var M;(M=y.onKeyDown)==null||M.call(y,k);let F=k.nativeEvent.isComposing||k.keyCode===229;if(!(k.defaultPrevented||F))switch(k.key){case"n":case"j":{g&&k.ctrlKey&&D(k);break}case"ArrowDown":{D(k);break}case"p":case"k":{g&&k.ctrlKey&&L(k);break}case"ArrowUp":{L(k);break}case"Home":{k.preventDefault(),H(0);break}case"End":{k.preventDefault(),R();break}case"Enter":{k.preventDefault();let A=B();if(A){let z=new Event(Ws);A.dispatchEvent(z)}}}}},l.createElement("label",{"cmdk-label":"",htmlFor:_.inputId,id:_.labelId,style:Ux},c),Sr(e,k=>l.createElement(jd.Provider,{value:P},l.createElement(Ld.Provider,{value:_},k))))}),Ox=l.forwardRef((e,t)=>{var n,o;let r=$e(),s=l.useRef(null),a=l.useContext(Bd),i=Eo(),c=Wd(e),u=(o=(n=c.current)==null?void 0:n.forceMount)!=null?o:a?.forceMount;dn(()=>{if(!u)return i.item(r,a?.id)},[u]);let d=Hd(r,s,[e.value,e.children,s],e.keywords),f=Oa(),p=Yt(C=>C.value&&C.value===d.current),h=Yt(C=>u||i.filter()===!1?!0:C.search?C.filtered.items.get(r)>0:!0);l.useEffect(()=>{let C=s.current;if(!(!C||e.disabled))return C.addEventListener(Ws,m),()=>C.removeEventListener(Ws,m)},[h,e.onSelect,e.disabled]);function m(){var C,P;v(),(P=(C=c.current).onSelect)==null||P.call(C,d.current)}function v(){f.setState("value",d.current,!0)}if(!h)return null;let{disabled:g,value:y,onSelect:b,forceMount:x,keywords:S,...T}=e;return l.createElement(re.div,{ref:ze(s,t),...T,id:r,"cmdk-item":"",role:"option","aria-disabled":!!g,"aria-selected":!!p,"data-disabled":!!g,"data-selected":!!p,onPointerMove:g||i.getDisablePointerSelection()?void 0:v,onClick:g?void 0:m},e.children)}),Ax=l.forwardRef((e,t)=>{let{heading:n,children:o,forceMount:r,...s}=e,a=$e(),i=l.useRef(null),c=l.useRef(null),u=$e(),d=Eo(),f=Yt(h=>r||d.filter()===!1?!0:h.search?h.filtered.groups.has(a):!0);dn(()=>d.group(a),[]),Hd(a,i,[e.value,e.heading,c]);let p=l.useMemo(()=>({id:a,forceMount:r}),[r]);return l.createElement(re.div,{ref:ze(i,t),...s,"cmdk-group":"",role:"presentation",hidden:f?void 0:!0},n&&l.createElement("div",{ref:c,"cmdk-group-heading":"","aria-hidden":!0,id:u},n),Sr(e,h=>l.createElement("div",{"cmdk-group-items":"",role:"group","aria-labelledby":n?u:void 0},l.createElement(Bd.Provider,{value:p},h))))}),_x=l.forwardRef((e,t)=>{let{alwaysRender:n,...o}=e,r=l.useRef(null),s=Yt(a=>!a.search);return!n&&!s?null:l.createElement(re.div,{ref:ze(r,t),...o,"cmdk-separator":"",role:"separator"})}),Nx=l.forwardRef((e,t)=>{let{onValueChange:n,...o}=e,r=e.value!=null,s=Oa(),a=Yt(u=>u.search),i=Yt(u=>u.selectedItemId),c=Eo();return l.useEffect(()=>{e.value!=null&&s.setState("search",e.value)},[e.value]),l.createElement(re.input,{ref:t,...o,"cmdk-input":"",autoComplete:"off",autoCorrect:"off",spellCheck:!1,"aria-autocomplete":"list",role:"combobox","aria-expanded":!0,"aria-controls":c.listId,"aria-labelledby":c.labelId,"aria-activedescendant":i,id:c.inputId,type:"text",value:r?e.value:a,onChange:u=>{r||s.setState("search",u.target.value),n?.(u.target.value)}})}),$x=l.forwardRef((e,t)=>{let{children:n,label:o="Suggestions",...r}=e,s=l.useRef(null),a=l.useRef(null),i=Yt(u=>u.selectedItemId),c=Eo();return l.useEffect(()=>{if(a.current&&s.current){let u=a.current,d=s.current,f,p=new ResizeObserver(()=>{f=requestAnimationFrame(()=>{let h=u.offsetHeight;d.style.setProperty("--cmdk-list-height",h.toFixed(1)+"px")})});return p.observe(u),()=>{cancelAnimationFrame(f),p.unobserve(u)}}},[]),l.createElement(re.div,{ref:ze(s,t),...r,"cmdk-list":"",role:"listbox",tabIndex:-1,"aria-activedescendant":i,"aria-label":o,id:c.listId},Sr(e,u=>l.createElement("div",{ref:ze(a,c.listInnerRef),"cmdk-list-sizer":""},u)))}),Fx=l.forwardRef((e,t)=>{let{open:n,onOpenChange:o,overlayClassName:r,contentClassName:s,container:a,...i}=e;return l.createElement(iu,{open:n,onOpenChange:o},l.createElement(lu,{container:a},l.createElement(cu,{"cmdk-overlay":"",className:r}),l.createElement(uu,{"aria-label":e.label,"cmdk-dialog":"",className:s},l.createElement(Vd,{ref:t,...i}))))}),Lx=l.forwardRef((e,t)=>Yt(n=>n.filtered.count===0)?l.createElement(re.div,{ref:t,...e,"cmdk-empty":"",role:"presentation"}):null),jx=l.forwardRef((e,t)=>{let{progress:n,children:o,label:r="Loading...",...s}=e;return l.createElement(re.div,{ref:t,...s,"cmdk-loading":"",role:"progressbar","aria-valuenow":n,"aria-valuemin":0,"aria-valuemax":100,"aria-label":r},Sr(e,a=>l.createElement("div",{"aria-hidden":!0},a)))}),d2=Object.assign(Vd,{List:$x,Item:Ox,Input:Nx,Group:Ax,Separator:_x,Dialog:Fx,Empty:Lx,Loading:jx});function Bx(e,t){let n=e.nextElementSibling;for(;n;){if(n.matches(t))return n;n=n.nextElementSibling}}function Vx(e,t){let n=e.previousElementSibling;for(;n;){if(n.matches(t))return n;n=n.previousElementSibling}}function Wd(e){let t=l.useRef(e);return dn(()=>{t.current=e}),t}var dn=typeof window>"u"?l.useEffect:l.useLayoutEffect;function xn(e){let t=l.useRef();return t.current===void 0&&(t.current=e()),t}function Yt(e){let t=Oa(),n=()=>e(t.snapshot());return l.useSyncExternalStore(t.subscribe,n,n)}function Hd(e,t,n,o=[]){let r=l.useRef(),s=Eo();return dn(()=>{var a;let i=(()=>{var u;for(let d of n){if(typeof d=="string")return d.trim();if(typeof d=="object"&&"current"in d)return d.current?(u=d.current.textContent)==null?void 0:u.trim():r.current}})(),c=o.map(u=>u.trim());s.value(e,i,c),(a=t.current)==null||a.setAttribute(bn,i),r.current=i}),r}var Wx=()=>{let[e,t]=l.useState(),n=xn(()=>new Map);return dn(()=>{n.current.forEach(o=>o()),n.current=new Map},[e]),(o,r)=>{n.current.set(o,r),t({})}};function Hx(e){let t=e.type;return typeof t=="function"?t(e.props):"render"in t?t.render(e.props):e}function Sr({asChild:e,children:t},n){return e&&l.isValidElement(t)?l.cloneElement(Hx(t),{ref:t.ref},n(t.props.children)):n(t)}var Ux={position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0"};function el(e,[t,n]){return Math.min(n,Math.max(t,e))}function Gx(e){const t=Yx(e),n=l.forwardRef((o,r)=>{const{children:s,...a}=o,i=l.Children.toArray(s),c=i.find(Kx);if(c){const u=c.props.children,d=i.map(f=>f===c?l.Children.count(u)>1?l.Children.only(null):l.isValidElement(u)?u.props.children:null:f);return E.jsx(t,{...a,ref:r,children:l.isValidElement(u)?l.cloneElement(u,void 0,d):null})}return E.jsx(t,{...a,ref:r,children:s})});return n.displayName=`${e}.Slot`,n}function Yx(e){const t=l.forwardRef((n,o)=>{const{children:r,...s}=n;if(l.isValidElement(r)){const a=Xx(r),i=qx(s,r.props);return r.type!==l.Fragment&&(i.ref=o?ze(o,a):a),l.cloneElement(r,i)}return l.Children.count(r)>1?l.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var zx=Symbol("radix.slottable");function Kx(e){return l.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===zx}function qx(e,t){const n={...t};for(const o in t){const r=e[o],s=t[o];/^on[A-Z]/.test(o)?r&&s?n[o]=(...i)=>{const c=s(...i);return r(...i),c}:r&&(n[o]=r):o==="style"?n[o]={...r,...s}:o==="className"&&(n[o]=[r,s].filter(Boolean).join(" "))}return{...e,...n}}function Xx(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function Aa(e){const t=l.useRef({value:e,previous:e});return l.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}var Zx=[" ","Enter","ArrowUp","ArrowDown"],Qx=[" ","Enter"],fn="Select",[Pr,Mr,Jx]=Ca(fn),[$n]=rt(fn,[Jx,Kt]),Tr=Kt(),[e1,Xt]=$n(fn),[t1,n1]=$n(fn),Ud=e=>{const{__scopeSelect:t,children:n,open:o,defaultOpen:r,onOpenChange:s,value:a,defaultValue:i,onValueChange:c,dir:u,name:d,autoComplete:f,disabled:p,required:h,form:m}=e,v=Tr(t),[g,y]=l.useState(null),[b,x]=l.useState(null),[S,T]=l.useState(!1),C=yr(u),[P,_]=Mt({prop:o,defaultProp:r??!1,onChange:s,caller:fn}),[O,I]=Mt({prop:a,defaultProp:i,onChange:c,caller:fn}),$=l.useRef(null),G=g?m||!!g.closest("form"):!0,[W,B]=l.useState(new Set),K=Array.from(W).map(H=>H.props.value).join(";");return E.jsx(pr,{...v,children:E.jsxs(e1,{required:h,scope:t,trigger:g,onTriggerChange:y,valueNode:b,onValueNodeChange:x,valueNodeHasChildren:S,onValueNodeHasChildrenChange:T,contentId:$e(),value:O,onValueChange:I,open:P,onOpenChange:_,dir:C,triggerPointerDownPosRef:$,disabled:p,children:[E.jsx(Pr.Provider,{scope:t,children:E.jsx(t1,{scope:e.__scopeSelect,onNativeOptionAdd:l.useCallback(H=>{B(U=>new Set(U).add(H))},[]),onNativeOptionRemove:l.useCallback(H=>{B(U=>{const q=new Set(U);return q.delete(H),q})},[]),children:n})}),G?E.jsxs(mf,{"aria-hidden":!0,required:h,tabIndex:-1,name:d,autoComplete:f,value:O,onChange:H=>I(H.target.value),disabled:p,form:m,children:[O===void 0?E.jsx("option",{value:""}):null,Array.from(W)]},K):null]})})};Ud.displayName=fn;var Gd="SelectTrigger",Yd=l.forwardRef((e,t)=>{const{__scopeSelect:n,disabled:o=!1,...r}=e,s=Tr(n),a=Xt(Gd,n),i=a.disabled||o,c=he(t,a.onTriggerChange),u=Mr(n),d=l.useRef("touch"),[f,p,h]=gf(v=>{const g=u().filter(x=>!x.disabled),y=g.find(x=>x.value===a.value),b=yf(g,v,y);b!==void 0&&a.onValueChange(b.value)}),m=v=>{i||(a.onOpenChange(!0),h()),v&&(a.triggerPointerDownPosRef.current={x:Math.round(v.pageX),y:Math.round(v.pageY)})};return E.jsx(vo,{asChild:!0,...s,children:E.jsx(re.button,{type:"button",role:"combobox","aria-controls":a.contentId,"aria-expanded":a.open,"aria-required":a.required,"aria-autocomplete":"none",dir:a.dir,"data-state":a.open?"open":"closed",disabled:i,"data-disabled":i?"":void 0,"data-placeholder":vf(a.value)?"":void 0,...r,ref:c,onClick:J(r.onClick,v=>
vendor: 21,959 bytes, line 5
5{v.currentTarget.focus(),d.current!=="mouse"&&m(v)}),onPointerDown:J(r.onPointerDown,v=>{d.current=v.pointerType;const g=v.target;g.hasPointerCapture(v.pointerId)&&g.releasePointerCapture(v.pointerId),v.button===0&&v.ctrlKey===!1&&v.pointerType==="mouse"&&(m(v),v.preventDefault())}),onKeyDown:J(r.onKeyDown,v=>{const g=f.current!=="";!(v.ctrlKey||v.altKey||v.metaKey)&&v.key.length===1&&p(v.key),!(g&&v.key===" ")&&Zx.includes(v.key)&&(m(),v.preventDefault())})})})});Yd.displayName=Gd;var zd="SelectValue",Kd=l.forwardRef((e,t)=>{const{__scopeSelect:n,className:o,style:r,children:s,placeholder:a="",...i}=e,c=Xt(zd,n),{onValueNodeHasChildrenChange:u}=c,d=s!==void 0,f=he(t,c.onValueNodeChange);return _e(()=>{u(d)},[u,d]),E.jsx(re.span,{...i,ref:f,style:{pointerEvents:"none"},children:vf(c.value)?E.jsx(E.Fragment,{children:a}):s})});Kd.displayName=zd;var o1="SelectIcon",qd=l.forwardRef((e,t)=>{const{__scopeSelect:n,children:o,...r}=e;return E.jsx(re.span,{"aria-hidden":!0,...r,ref:t,children:o||"▼"})});qd.displayName=o1;var r1="SelectPortal",Xd=e=>E.jsx(Nn,{asChild:!0,...e});Xd.displayName=r1;var pn="SelectContent",Zd=l.forwardRef((e,t)=>{const n=Xt(pn,e.__scopeSelect),[o,r]=l.useState();if(_e(()=>{r(new DocumentFragment)},[]),!n.open){const s=o;return s?Te.createPortal(E.jsx(Qd,{scope:e.__scopeSelect,children:E.jsx(Pr.Slot,{scope:e.__scopeSelect,children:E.jsx("div",{children:e.children})})}),s):null}return E.jsx(Jd,{...e,ref:t})});Zd.displayName=pn;var ht=10,[Qd,Zt]=$n(pn),s1="SelectContentImpl",a1=Gx("SelectContent.RemoveScroll"),Jd=l.forwardRef((e,t)=>{const{__scopeSelect:n,position:o="item-aligned",onCloseAutoFocus:r,onEscapeKeyDown:s,onPointerDownOutside:a,side:i,sideOffset:c,align:u,alignOffset:d,arrowPadding:f,collisionBoundary:p,collisionPadding:h,sticky:m,hideWhenDetached:v,avoidCollisions:g,...y}=e,b=Xt(pn,n),[x,S]=l.useState(null),[T,C]=l.useState(null),P=he(t,N=>S(N)),[_,O]=l.useState(null),[I,$]=l.useState(null),G=Mr(n),[W,B]=l.useState(!1),K=l.useRef(!1);l.useEffect(()=>{if(x)return cr(x)},[x]),dr();const H=l.useCallback(N=>{const[Y,...te]=G().map(ee=>ee.ref.current),[ae]=te.slice(-1),pe=document.activeElement;for(const ee of N)if(ee===pe||(ee?.scrollIntoView({block:"nearest"}),ee===Y&&T&&(T.scrollTop=0),ee===ae&&T&&(T.scrollTop=T.scrollHeight),ee?.focus(),document.activeElement!==pe))return},[G,T]),U=l.useCallback(()=>H([_,x]),[H,_,x]);l.useEffect(()=>{W&&U()},[W,U]);const{onOpenChange:q,triggerPointerDownPosRef:R}=b;l.useEffect(()=>{if(x){let N={x:0,y:0};const Y=ae=>{N={x:Math.abs(Math.round(ae.pageX)-(R.current?.x??0)),y:Math.abs(Math.round(ae.pageY)-(R.current?.y??0))}},te=ae=>{N.x<=10&&N.y<=10?ae.preventDefault():x.contains(ae.target)||q(!1),document.removeEventListener("pointermove",Y),R.current=null};return R.current!==null&&(document.addEventListener("pointermove",Y),document.addEventListener("pointerup",te,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",Y),document.removeEventListener("pointerup",te,{capture:!0})}}},[x,q,R]),l.useEffect(()=>{const N=()=>q(!1);return window.addEventListener("blur",N),window.addEventListener("resize",N),()=>{window.removeEventListener("blur",N),window.removeEventListener("resize",N)}},[q]);const[D,L]=gf(N=>{const Y=G().filter(pe=>!pe.disabled),te=Y.find(pe=>pe.ref.current===document.activeElement),ae=yf(Y,N,te);ae&&setTimeout(()=>ae.ref.current.focus())}),k=l.useCallback((N,Y,te)=>{const ae=!K.current&&!te;(b.value!==void 0&&b.value===Y||ae)&&(O(N),ae&&(K.current=!0))},[b.value]),M=l.useCallback(()=>x?.focus(),[x]),F=l.useCallback((N,Y,te)=>{const ae=!K.current&&!te;(b.value!==void 0&&b.value===Y||ae)&&$(N)},[b.value]),A=o==="popper"?Hs:ef,z=A===Hs?{side:i,sideOffset:c,align:u,alignOffset:d,arrowPadding:f,collisionBoundary:p,collisionPadding:h,sticky:m,hideWhenDetached:v,avoidCollisions:g}:{};return E.jsx(Qd,{scope:n,content:x,viewport:T,onViewportChange:C,itemRefCallback:k,selectedItem:_,onItemLeave:M,itemTextRefCallback:F,focusSelectedItem:U,selectedItemText:I,position:o,isPositioned:W,searchRef:D,children:E.jsx(lr,{as:a1,allowPinchZoom:!0,children:E.jsx(mo,{asChild:!0,trapped:b.open,onMountAutoFocus:N=>{N.preventDefault()},onUnmountAutoFocus:J(r,N=>{b.trigger?.focus({preventScroll:!0}),N.preventDefault()}),children:E.jsx(_n,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:s,onPointerDownOutside:a,onFocusOutside:N=>N.preventDefault(),onDismiss:()=>b.onOpenChange(!1),children:E.jsx(A,{role:"listbox",id:b.contentId,"data-state":b.open?"open":"closed",dir:b.dir,onContextMenu:N=>N.preventDefault(),...y,...z,onPlaced:()=>B(!0),ref:P,style:{display:"flex",flexDirection:"column",outline:"none",...y.style},onKeyDown:J(y.onKeyDown,N=>{const Y=N.ctrlKey||N.altKey||N.metaKey;if(N.key==="Tab"&&N.preventDefault(),!Y&&N.key.length===1&&L(N.key),["ArrowUp","ArrowDown","Home","End"].includes(N.key)){let ae=G().filter(pe=>!pe.disabled).map(pe=>pe.ref.current);if(["ArrowUp","End"].includes(N.key)&&(ae=ae.slice().reverse()),["ArrowUp","ArrowDown"].includes(N.key)){const pe=N.target,ee=ae.indexOf(pe);ae=ae.slice(ee+1)}setTimeout(()=>H(ae)),N.preventDefault()}})})})})})})});Jd.displayName=s1;var i1="SelectItemAlignedPosition",ef=l.forwardRef((e,t)=>{const{__scopeSelect:n,onPlaced:o,...r}=e,s=Xt(pn,n),a=Zt(pn,n),[i,c]=l.useState(null),[u,d]=l.useState(null),f=he(t,P=>d(P)),p=Mr(n),h=l.useRef(!1),m=l.useRef(!0),{viewport:v,selectedItem:g,selectedItemText:y,focusSelectedItem:b}=a,x=l.useCallback(()=>{if(s.trigger&&s.valueNode&&i&&u&&v&&g&&y){const P=s.trigger.getBoundingClientRect(),_=u.getBoundingClientRect(),O=s.valueNode.getBoundingClientRect(),I=y.getBoundingClientRect();if(s.dir!=="rtl"){const pe=I.left-_.left,ee=O.left-pe,ue=P.left-ee,V=P.width+ue,Q=Math.max(V,_.width),me=window.innerWidth-ht,we=el(ee,[ht,Math.max(ht,me-Q)]);i.style.minWidth=V+"px",i.style.left=we+"px"}else{const pe=_.right-I.right,ee=window.innerWidth-O.right-pe,ue=window.innerWidth-P.right-ee,V=P.width+ue,Q=Math.max(V,_.width),me=window.innerWidth-ht,we=el(ee,[ht,Math.max(ht,me-Q)]);i.style.minWidth=V+"px",i.style.right=we+"px"}const $=p(),G=window.innerHeight-ht*2,W=v.scrollHeight,B=window.getComputedStyle(u),K=parseInt(B.borderTopWidth,10),H=parseInt(B.paddingTop,10),U=parseInt(B.borderBottomWidth,10),q=parseInt(B.paddingBottom,10),R=K+H+W+q+U,D=Math.min(g.offsetHeight*5,R),L=window.getComputedStyle(v),k=parseInt(L.paddingTop,10),M=parseInt(L.paddingBottom,10),F=P.top+P.height/2-ht,A=G-F,z=g.offsetHeight/2,N=g.offsetTop+z,Y=K+H+N,te=R-Y;if(Y<=F){const pe=$.length>0&&g===$[$.length-1].ref.current;i.style.bottom="0px";const ee=u.clientHeight-v.offsetTop-v.offsetHeight,ue=Math.max(A,z+(pe?M:0)+ee+U),V=Y+ue;i.style.height=V+"px"}else{const pe=$.length>0&&g===$[0].ref.current;i.style.top="0px";const ue=Math.max(F,K+v.offsetTop+(pe?k:0)+z)+te;i.style.height=ue+"px",v.scrollTop=Y-F+v.offsetTop}i.style.margin=`${ht}px 0`,i.style.minHeight=D+"px",i.style.maxHeight=G+"px",o?.(),requestAnimationFrame(()=>h.current=!0)}},[p,s.trigger,s.valueNode,i,u,v,g,y,s.dir,o]);_e(()=>x(),[x]);const[S,T]=l.useState();_e(()=>{u&&T(window.getComputedStyle(u).zIndex)},[u]);const C=l.useCallback(P=>{P&&m.current===!0&&(x(),b?.(),m.current=!1)},[x,b]);return E.jsx(c1,{scope:n,contentWrapper:i,shouldExpandOnScrollRef:h,onScrollButtonChange:C,children:E.jsx("div",{ref:c,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:S},children:E.jsx(re.div,{...r,ref:f,style:{boxSizing:"border-box",maxHeight:"100%",...r.style}})})})});ef.displayName=i1;var l1="SelectPopperPosition",Hs=l.forwardRef((e,t)=>{const{__scopeSelect:n,align:o="start",collisionPadding:r=ht,...s}=e,a=Tr(n);return E.jsx(hr,{...a,...s,ref:t,align:o,collisionPadding:r,style:{boxSizing:"border-box",...s.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}})});Hs.displayName=l1;var[c1,_a]=$n(pn,{}),Us="SelectViewport",tf=l.forwardRef((e,t)=>{const{__scopeSelect:n,nonce:o,...r}=e,s=Zt(Us,n),a=_a(Us,n),i=he(t,s.onViewportChange),c=l.useRef(0);return E.jsxs(E.Fragment,{children:[E.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"},nonce:o}),E.jsx(Pr.Slot,{scope:n,children:E.jsx(re.div,{"data-radix-select-viewport":"",role:"presentation",...r,ref:i,style:{position:"relative",flex:1,overflow:"hidden auto",...r.style},onScroll:J(r.onScroll,u=>{const d=u.currentTarget,{contentWrapper:f,shouldExpandOnScrollRef:p}=a;if(p?.current&&f){const h=Math.abs(c.current-d.scrollTop);if(h>0){const m=window.innerHeight-ht*2,v=parseFloat(f.style.minHeight),g=parseFloat(f.style.height),y=Math.max(v,g);if(y<m){const b=y+h,x=Math.min(m,b),S=b-x;f.style.height=x+"px",f.style.bottom==="0px"&&(d.scrollTop=S>0?S:0,f.style.justifyContent="flex-end")}}}c.current=d.scrollTop})})})]})});tf.displayName=Us;var nf="SelectGroup",[u1,d1]=$n(nf),f1=l.forwardRef((e,t)=>{const{__scopeSelect:n,...o}=e,r=$e();return E.jsx(u1,{scope:n,id:r,children:E.jsx(re.div,{role:"group","aria-labelledby":r,...o,ref:t})})});f1.displayName=nf;var of="SelectLabel",rf=l.forwardRef((e,t)=>{const{__scopeSelect:n,...o}=e,r=d1(of,n);return E.jsx(re.div,{id:r.id,...o,ref:t})});rf.displayName=of;var Qo="SelectItem",[p1,sf]=$n(Qo),af=l.forwardRef((e,t)=>{const{__scopeSelect:n,value:o,disabled:r=!1,textValue:s,...a}=e,i=Xt(Qo,n),c=Zt(Qo,n),u=i.value===o,[d,f]=l.useState(s??""),[p,h]=l.useState(!1),m=he(t,b=>c.itemRefCallback?.(b,o,r)),v=$e(),g=l.useRef("touch"),y=()=>{r||(i.onValueChange(o),i.onOpenChange(!1))};if(o==="")throw new Error("A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return E.jsx(p1,{scope:n,value:o,disabled:r,textId:v,isSelected:u,onItemTextChange:l.useCallback(b=>{f(x=>x||(b?.textContent??"").trim())},[]),children:E.jsx(Pr.ItemSlot,{scope:n,value:o,disabled:r,textValue:d,children:E.jsx(re.div,{role:"option","aria-labelledby":v,"data-highlighted":p?"":void 0,"aria-selected":u&&p,"data-state":u?"checked":"unchecked","aria-disabled":r||void 0,"data-disabled":r?"":void 0,tabIndex:r?void 0:-1,...a,ref:m,onFocus:J(a.onFocus,()=>h(!0)),onBlur:J(a.onBlur,()=>h(!1)),onClick:J(a.onClick,()=>{g.current!=="mouse"&&y()}),onPointerUp:J(a.onPointerUp,()=>{g.current==="mouse"&&y()}),onPointerDown:J(a.onPointerDown,b=>{g.current=b.pointerType}),onPointerMove:J(a.onPointerMove,b=>{g.current=b.pointerType,r?c.onItemLeave?.():g.current==="mouse"&&b.currentTarget.focus({preventScroll:!0})}),onPointerLeave:J(a.onPointerLeave,b=>{b.currentTarget===document.activeElement&&c.onItemLeave?.()}),onKeyDown:J(a.onKeyDown,b=>{c.searchRef?.current!==""&&b.key===" "||(Qx.includes(b.key)&&y(),b.key===" "&&b.preventDefault())})})})})});af.displayName=Qo;var eo="SelectItemText",lf=l.forwardRef((e,t)=>{const{__scopeSelect:n,className:o,style:r,...s}=e,a=Xt(eo,n),i=Zt(eo,n),c=sf(eo,n),u=n1(eo,n),[d,f]=l.useState(null),p=he(t,y=>f(y),c.onItemTextChange,y=>i.itemTextRefCallback?.(y,c.value,c.disabled)),h=d?.textContent,m=l.useMemo(()=>E.jsx("option",{value:c.value,disabled:c.disabled,children:h},c.value),[c.disabled,c.value,h]),{onNativeOptionAdd:v,onNativeOptionRemove:g}=u;return _e(()=>(v(m),()=>g(m)),[v,g,m]),E.jsxs(E.Fragment,{children:[E.jsx(re.span,{id:c.textId,...s,ref:p}),c.isSelected&&a.valueNode&&!a.valueNodeHasChildren?Te.createPortal(s.children,a.valueNode):null]})});lf.displayName=eo;var cf="SelectItemIndicator",uf=l.forwardRef((e,t)=>{const{__scopeSelect:n,...o}=e;return sf(cf,n).isSelected?E.jsx(re.span,{"aria-hidden":!0,...o,ref:t}):null});uf.displayName=cf;var Gs="SelectScrollUpButton",df=l.forwardRef((e,t)=>{const n=Zt(Gs,e.__scopeSelect),o=_a(Gs,e.__scopeSelect),[r,s]=l.useState(!1),a=he(t,o.onScrollButtonChange);return _e(()=>{if(n.viewport&&n.isPositioned){let i=function(){const u=c.scrollTop>0;s(u)};const c=n.viewport;return i(),c.addEventListener("scroll",i),()=>c.removeEventListener("scroll",i)}},[n.viewport,n.isPositioned]),r?E.jsx(pf,{...e,ref:a,onAutoScroll:()=>{const{viewport:i,selectedItem:c}=n;i&&c&&(i.scrollTop=i.scrollTop-c.offsetHeight)}}):null});df.displayName=Gs;var Ys="SelectScrollDownButton",ff=l.forwardRef((e,t)=>{const n=Zt(Ys,e.__scopeSelect),o=_a(Ys,e.__scopeSelect),[r,s]=l.useState(!1),a=he(t,o.onScrollButtonChange);return _e(()=>{if(n.viewport&&n.isPositioned){let i=function(){const u=c.scrollHeight-c.clientHeight,d=Math.ceil(c.scrollTop)<u;s(d)};const c=n.viewport;return i(),c.addEventListener("scroll",i),()=>c.removeEventListener("scroll",i)}},[n.viewport,n.isPositioned]),r?E.jsx(pf,{...e,ref:a,onAutoScroll:()=>{const{viewport:i,selectedItem:c}=n;i&&c&&(i.scrollTop=i.scrollTop+c.offsetHeight)}}):null});ff.displayName=Ys;var pf=l.forwardRef((e,t)=>{const{__scopeSelect:n,onAutoScroll:o,...r}=e,s=Zt("SelectScrollButton",n),a=l.useRef(null),i=Mr(n),c=l.useCallback(()=>{a.current!==null&&(window.clearInterval(a.current),a.current=null)},[]);return l.useEffect(()=>()=>c(),[c]),_e(()=>{i().find(d=>d.ref.current===document.activeElement)?.ref.current?.scrollIntoView({block:"nearest"})},[i]),E.jsx(re.div,{"aria-hidden":!0,...r,ref:t,style:{flexShrink:0,...r.style},onPointerDown:J(r.onPointerDown,()=>{a.current===null&&(a.current=window.setInterval(o,50))}),onPointerMove:J(r.onPointerMove,()=>{s.onItemLeave?.(),a.current===null&&(a.current=window.setInterval(o,50))}),onPointerLeave:J(r.onPointerLeave,()=>{c()})})}),h1="SelectSeparator",hf=l.forwardRef((e,t)=>{const{__scopeSelect:n,...o}=e;return E.jsx(re.div,{"aria-hidden":!0,...o,ref:t})});hf.displayName=h1;var zs="SelectArrow",m1=l.forwardRef((e,t)=>{const{__scopeSelect:n,...o}=e,r=Tr(n),s=Xt(zs,n),a=Zt(zs,n);return s.open&&a.position==="popper"?E.jsx(mr,{...r,...o,ref:t}):null});m1.displayName=zs;var v1="SelectBubbleInput",mf=l.forwardRef(({__scopeSelect:e,value:t,...n},o)=>{const r=l.useRef(null),s=he(o,r),a=Aa(t);return l.useEffect(()=>{const i=r.current;if(!i)return;const c=window.HTMLSelectElement.prototype,d=Object.getOwnPropertyDescriptor(c,"value").set;if(a!==t&&d){const f=new Event("change",{bubbles:!0});d.call(i,t),i.dispatchEvent(f)}},[a,t]),E.jsx(re.select,{...n,style:{...Eu,...n.style},ref:s,defaultValue:t})});mf.displayName=v1;function vf(e){return e===""||e===void 0}function gf(e){const t=vt(e),n=l.useRef(""),o=l.useRef(0),r=l.useCallback(a=>{const i=n.current+a;t(i),(function c(u){n.current=u,window.clearTimeout(o.current),u!==""&&(o.current=window.setTimeout(()=>c(""),1e3))})(i)},[t]),s=l.useCallback(()=>{n.current="",window.clearTimeout(o.current)},[]);return l.useEffect(()=>()=>window.clearTimeout(o.current),[]),[n,r,s]}function yf(e,t,n){const r=t.length>1&&Array.from(t).every(u=>u===t[0])?t[0]:t,s=n?e.indexOf(n):-1;let a=g1(e,Math.max(s,0));r.length===1&&(a=a.filter(u=>u!==n));const c=a.find(u=>u.textValue.toLowerCase().startsWith(r.toLowerCase()));return c!==n?c:void 0}function g1(e,t){return e.map((n,o)=>e[(t+o)%e.length])}var f2=Ud,p2=Yd,h2=Kd,m2=qd,v2=Xd,g2=Zd,y2=tf,b2=rf,x2=af,w2=lf,E2=uf,C2=df,S2=ff,P2=hf;function y1(e){if(typeof document>"u")return;let t=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css",t.appendChild(n),n.styleSheet?n.styleSheet.cssText=e:n.appendChild(document.createTextNode(e))}const b1=e=>{switch(e){case"success":return E1;case"info":return S1;case"warning":return C1;case"error":return P1;default:return null}},x1=Array(12).fill(0),w1=({visible:e,className:t})=>w.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},w.createElement("div",{className:"sonner-spinner"},x1.map((n,o)=>w.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${o}`})))),E1=w.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},w.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),C1=w.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},w.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),S1=w.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},w.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),P1=w.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},w.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),M1=w.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},w.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),w.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),T1=()=>{const[e,t]=w.useState(document.hidden);return w.useEffect(()=>{const n=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",n),()=>window.removeEventListener("visibilitychange",n)},[]),e};let Ks=1;class k1{constructor(){this.subscribe=t=>(this.subscribers.push(t),()=>{const n=this.subscribers.indexOf(t);this.subscribers.splice(n,1)}),this.publish=t=>{this.subscribers.forEach(n=>n(t))},this.addToast=t=>{this.publish(t),this.toasts=[...this.toasts,t]},this.create=t=>{var n;const{message:o,...r}=t,s=typeof t?.id=="number"||((n=t.id)==null?void 0:n.length)>0?t.id:Ks++,a=this.toasts.find(c=>c.id===s),i=t.dismissible===void 0?!0:t.dismissible;return this.dismissedToasts.has(s)&&this.dismissedToasts.delete(s),a?this.toasts=this.toasts.map(c=>c.id===s?(this.publish({...c,...t,id:s,title:o}),{...c,...t,id:s,dismissible:i,title:o}):c):this.addToast({title:o,...r,dismissible:i,id:s}),s},this.dismiss=t=>(t?(this.dismissedToasts.add(t),requestAnimationFrame(()=>this.subscribers.forEach(n=>n({id:t,dismiss:!0})))):this.toasts.forEach(n=>{this.subscribers.forEach(o=>o({id:n.id,dismiss:!0}))}),t),this.message=(t,n)=>this.create({...n,message:t}),this.error=(t,n)=>this.create({...n,message:t,type:"error"}),this.success=(t,n)=>this.create({...n,type:"success",message:t}),this.info=(t,n)=>this.create({...n,type:"info",message:t}),this.warning=(t,n)=>this.create({...n,type:"warning",message:t}),this.loading=(t,n)=>this.create({...n,type:"loading",message:t}),this.promise=(t,n)=>{if(!n)return;let o;n.loading!==void 0&&(o=this.create({...n,promise:t,type:"loading",message:n.loading,description:typeof n.description!="function"?n.description:void 0}));const r=Promise.resolve(t instanceof Function?t():t);let s=o!==void 0,a;const i=r.then(async u=>{if(a=["resolve",u],w.isValidElement(u))s=!1,this.create({id:o,type:"default",message:u});else if(D1(u)&&!u.ok){s=!1;const f=typeof n.error=="function"?await n.error(`HTTP error! status: ${u.status}`):n.error,p=typeof n.description=="function"?await n.description(`HTTP error! status: ${u.status}`):n.description,m=typeof f=="object"&&!w.isValidElement(f)?f:{message:f};this.create({id:o,type:"error",description:p,...m})}else if(u instanceof Error){s=!1;const f=typeof n.error=="function"?await n.error(u):n.error,p=typeof n.description=="function"?await n.description(u):n.description,m=typeof f=="object"&&!w.isValidElement(f)?f:{message:f};this.create({id:o,type:"error",description:p,...m})}else if(n.success!==void 0){s=!1;const f=typeof n.success=="function"?await n.success(u):n.success,p=typeof n.description=="function"?await n.description(u):n.description,m=typeof f=="object"&&!w.isValidElement(f)?f:{message:f};this.create({id:o,type:"success",description:p,...m})}}).catch(async u=>{if(a=["reject",u],n.error!==void 0){s=!1;const d=typeof n.error=="function"?await n.error(u):n.error,f=typeof n.description=="function"?await n.description(u):n.description,h=typeof d=="object"&&!w.isValidElement(d)?d:{message:d};this.create({id:o,type:"error",description:f,...h})}}).finally(()=>{s&&(this.dismiss(o),o=void 0),n.finally==null||n.finally.call(n)}),c=()=>new Promise((u,d)=>i.then(()=>a[0]==="reject"?d(a[1]):u(a[1])).catch(d));return typeof o!="string"&&typeof o!="number"?{unwrap:c}:Object.assign(o,{unwrap:c})},this.custom=(t,n)=>{const o=n?.id||Ks++;return this.create({jsx:t(o),id:o,...n}),o},this.getActiveToasts=()=>this.toasts.filter(t=>!this.dismissedToasts.has(t.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}}const Xe=new k1,R1=(e,t)=>{const n=t?.id||Ks++;return Xe.addToast({title:e,...t,id:n}),n},D1=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",I1=R1,O1=()=>Xe.toasts,A1=()=>Xe.getActiveToasts(),M2=Object.assign(I1,{success:Xe.success,info:Xe.info,warning:Xe.warning,error:Xe.error,custom:Xe.custom,message:Xe.message,promise:Xe.promise,dismiss:Xe.dismiss,loading:Xe.loading},{getHistory:O1,getToasts:A1});y1
vendor: 4,787 bytes, line 5
5("[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-rich-colors=true][data-sonner-toast][data-styled=true] [data-description]{color:inherit}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;
vendor: 10,086 bytes, line 5
5left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);background:var(--normal-bg);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast][data-expanded=true]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}");function 
vendor: 961 bytes, line 5
5Lo(e){return e.label!==void 0}const _1=3,N1="24px",$1="16px",tl=4e3,F1=356,L1=14,j1=45,B1=200;function Et(...e){return e.filter(Boolean).join(" ")}function V1(e){const[t,n]=e.split("-"),o=[];return t&&o.push(t),n&&o.push(n),o}const W1=e=>{var t,n,o,r,s,a,i,c,u;const{invert:d,toast:f,unstyled:p,interacting:h,setHeights:m,visibleToasts:v,heights:g,index:y,toasts:b,expanded:x,removeToast:S,defaultRichColors:T,closeButton:C,style:P,cancelButtonStyle:_,actionButtonStyle:O,className:I="",descriptionClassName:$="",duration:G,position:W,gap:B,expandByDefault:K,classNames:H,icons:U,closeButtonAriaLabel:q="Close toast"}=e,[R,D]=w.useState(null),[L,k]=w.useState(null),[M,F]=w.useState(!1),[A,z]=w.useState(!1),[N,Y]=w.useState(!1),[te,ae]=w.useState(!1),[pe,ee]=w.useState(!1),[ue,V]=w.useState(0),[Q,me]=w.useState(0),we=w.useRef(f.duration||G||tl),Re=w.useRef(null),ve=w.useRef(null),Fe=y===0,Ft=y+1<=v,Se=f.type,Le=f.dismissible!==!1,We=f.className||"",qe=f.de
vendor: 8,743 bytes, line 5
5scriptionClassName||"",He=w.useMemo(()=>g.findIndex(Z=>Z.toastId===f.id)||0,[g,f.id]),lt=w.useMemo(()=>{var Z;return(Z=f.closeButton)!=null?Z:C},[f.closeButton,C]),en=w.useMemo(()=>f.duration||G||tl,[f.duration,G]),Lt=w.useRef(0),xt=w.useRef(0),gn=w.useRef(0),wt=w.useRef(null),[ct,tn]=W.split("-"),yn=w.useMemo(()=>g.reduce((Z,De,Ne)=>Ne>=He?Z:Z+De.height,0),[g,He]),Ao=T1(),_o=f.invert||d,Yn=Se==="loading";xt.current=w.useMemo(()=>He*B+yn,[He,yn]),w.useEffect(()=>{we.current=en},[en]),w.useEffect(()=>{F(!0)},[]),w.useEffect(()=>{const Z=ve.current;if(Z){const De=Z.getBoundingClientRect().height;return me(De),m(Ne=>[{toastId:f.id,height:De,position:f.position},...Ne]),()=>m(Ne=>Ne.filter(Ue=>Ue.toastId!==f.id))}},[m,f.id]),w.useLayoutEffect(()=>{if(!M)return;const Z=ve.current,De=Z.style.height;Z.style.height="auto";const Ne=Z.getBoundingClientRect().height;Z.style.height=De,me(Ne),m(Ue=>Ue.find(Me=>Me.toastId===f.id)?Ue.map(Me=>Me.toastId===f.id?{...Me,height:Ne}:Me):[{toastId:f.id,height:Ne,position:f.position},...Ue])},[M,f.title,f.description,m,f.id,f.jsx,f.action,f.cancel]);const se=w.useCallback(()=>{z(!0),V(xt.current),m(Z=>Z.filter(De=>De.toastId!==f.id)),setTimeout(()=>{S(f)},B1)},[f,S,m,xt]);w.useEffect(()=>{if(f.promise&&Se==="loading"||f.duration===1/0||f.type==="loading")return;let Z;return x||h||Ao?(()=>{if(gn.current<Lt.current){const Ue=new Date().getTime()-Lt.current;we.current=we.current-Ue}gn.current=new Date().getTime()})():(()=>{we.current!==1/0&&(Lt.current=new Date().getTime(),Z=setTimeout(()=>{f.onAutoClose==null||f.onAutoClose.call(f,f),se()},we.current))})(),()=>clearTimeout(Z)},[x,h,f,Se,Ao,se]),w.useEffect(()=>{f.delete&&(se(),f.onDismiss==null||f.onDismiss.call(f,f))},[se,f.delete]);function be(){var Z;if(U?.loading){var De;return w.createElement("div",{className:Et(H?.loader,f==null||(De=f.classNames)==null?void 0:De.loader,"sonner-loader"),"data-visible":Se==="loading"},U.loading)}return w.createElement(w1,{className:Et(H?.loader,f==null||(Z=f.classNames)==null?void 0:Z.loader),visible:Se==="loading"})}const ie=f.icon||U?.[Se]||b1(Se);var xe,Qe;return w.createElement("li",{tabIndex:0,ref:ve,className:Et(I,We,H?.toast,f==null||(t=f.classNames)==null?void 0:t.toast,H?.default,H?.[Se],f==null||(n=f.classNames)==null?void 0:n[Se]),"data-sonner-toast":"","data-rich-colors":(xe=f.richColors)!=null?xe:T,"data-styled":!(f.jsx||f.unstyled||p),"data-mounted":M,"data-promise":!!f.promise,"data-swiped":pe,"data-removed":A,"data-visible":Ft,"data-y-position":ct,"data-x-position":tn,"data-index":y,"data-front":Fe,"data-swiping":N,"data-dismissible":Le,"data-type":Se,"data-invert":_o,"data-swipe-out":te,"data-swipe-direction":L,"data-expanded":!!(x||K&&M),"data-testid":f.testId,style:{"--index":y,"--toasts-before":y,"--z-index":b.length-y,"--offset":`${A?ue:xt.current}px`,"--initial-height":K?"auto":`${Q}px`,...P,...f.style},onDragEnd:()=>{Y(!1),D(null),wt.current=null},onPointerDown:Z=>{Z.button!==2&&(Yn||!Le||(Re.current=new Date,V(xt.current),Z.target.setPointerCapture(Z.pointerId),Z.target.tagName!=="BUTTON"&&(Y(!0),wt.current={x:Z.clientX,y:Z.clientY})))},onPointerUp:()=>{var Z,De,Ne;if(te||!Le)return;wt.current=null;const Ue=Number(((Z=ve.current)==null?void 0:Z.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),jt=Number(((De=ve.current)==null?void 0:De.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),Me=new Date().getTime()-((Ne=Re.current)==null?void 0:Ne.getTime()),st=R==="x"?Ue:jt,No=Math.abs(st)/Me;if(Math.abs(st)>=j1||No>.11){V(xt.current),f.onDismiss==null||f.onDismiss.call(f,f),k(R==="x"?Ue>0?"right":"left":jt>0?"down":"up"),se(),ae(!0);return}else{var ut,dt;(ut=ve.current)==null||ut.style.setProperty("--swipe-amount-x","0px"),(dt=ve.current)==null||dt.style.setProperty("--swipe-amount-y","0px")}ee(!1),Y(!1),D(null)},onPointerMove:Z=>{var De,Ne,Ue;if(!wt.current||!Le||((De=window.getSelection())==null?void 0:De.toString().length)>0)return;const Me=Z.clientY-wt.current.y,st=Z.clientX-wt.current.x;var No;const ut=(No=e.swipeDirections)!=null?No:V1(W);!R&&(Math.abs(st)>1||Math.abs(Me)>1)&&D(Math.abs(st)>Math.abs(Me)?"x":"y");let dt={x:0,y:0};const $i=nn=>1/(1.5+Math.abs(nn)/20);if(R==="y"){if(ut.includes("top")||ut.includes("bottom"))if(ut.includes("top")&&Me<0||ut.includes("bottom")&&Me>0)dt.y=Me;else{const nn=Me*$i(Me);dt.y=Math.abs(nn)<Math.abs(Me)?nn:Me}}else if(R==="x"&&(ut.includes("left")||ut.includes("right")))if(ut.includes("left")&&st<0||ut.includes("right")&&st>0)dt.x=st;else{const nn=st*$i(st);dt.x=Math.abs(nn)<Math.abs(st)?nn:st}(Math.abs(dt.x)>0||Math.abs(dt.y)>0)&&ee(!0),(Ne=ve.current)==null||Ne.style.setProperty("--swipe-amount-x",`${dt.x}px`),(Ue=ve.current)==null||Ue.style.setProperty("--swipe-amount-y",`${dt.y}px`)}},lt&&!f.jsx&&Se!=="loading"?w.createElement("button",{"aria-label":q,"data-disabled":Yn,"data-close-button":!0,onClick:Yn||!Le?()=>{}:()=>{se(),f.onDismiss==null||f.onDismiss.call(f,f)},className:Et(H?.closeButton,f==null||(o=f.classNames)==null?void 0:o.closeButton)},(Qe=U?.close)!=null?Qe:M1):null,(Se||f.icon||f.promise)&&f.icon!==null&&(U?.[Se]!==null||f.icon)?w.createElement("div",{"data-icon":"",className:Et(H?.icon,f==null||(r=f.classNames)==null?void 0:r.icon)},f.promise||f.type==="loading"&&!f.icon?f.icon||be():null,f.type!=="loading"?ie:null):null,w.createElement("div",{"data-content":"",className:Et(H?.content,f==null||(s=f.classNames)==null?void 0:s.content)},w.createElement("div",{"data-title":"",className:Et(H?.title,f==null||(a=f.classNames)==null?void 0:a.title)},f.jsx?f.jsx:typeof f.title=="function"?f.title():f.title),f.description?w.createElement("div",{"data-description":"",className:Et($,qe,H?.description,f==null||(i=f.classNames)==null?void 0:i.description)},typeof f.description=="function"?f.description():f.description):null),w.isValidElement(f.cancel)?f.cancel:f.cancel&&Lo(f.cancel)?w.createElement("button",{"data-button":!0,"data-cancel":!0,style:f.cancelButtonStyle||_,onClick:Z=>{Lo(f.cancel)&&Le&&(f.cancel.onClick==null||f.cancel.onClick.call(f.cancel,Z),se())},className:Et(H?.cancelButton,f==null||(c=f.classNames)==null?void 0:c.cancelButton)},f.cancel.label):null,w.isValidElement(f.action)?f.action:f.action&&Lo(f.action)?w.createElement("button",{"data-button":!0,"data-action":!0,style:f.actionButtonStyle||O,onClick:Z=>{Lo(f.action)&&(f.action.onClick==null||f.action.onClick.call(f.action,Z),!Z.defaultPrevented&&se())},className:Et(H?.actionButton,f==null||(u=f.classNames)==null?void 0:u.actionButton)},f.action.label):null)};function nl(){if(typeof window>"u"||typeof document>"u")return"ltr";const e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}function H1(e,t){const n={};return[e,t].forEach((o,r)=>{const s=r===1,a=s?"--mobile-offset":"--offset",i=s?$1:N1;function c(u){["top","right","bottom","left"].forEach(d=>{n[`${a}-${d}`]=typeof u=="number"?`${u}px`:u})}typeof o=="number"||typeof o=="string"?c(o):typeof o=="object"?["top","right","bottom","left"].forEach(u=>{o[u]===void 0?n[`${a}-${u}`]=i:n[`${a}-${u}`]=typeof o[u]=="number"?`${o[u]}px`:o[u]}):c(i)}),n}const T2=w.forwardRef(function(t,n){const{id:o,invert:r,position:s="bottom-right",hotkey:a=["altKey","KeyT"],expand:i,closeButton:c,className:u,offset:d,mobileOffset:f,theme:p="light",richColors:h,duration:m,style:v,visibleToasts:g=_1,toastOptions:y,dir:b=nl(),gap:x=L1,icons:S,containerAriaLabel:T="Notifications"}=t,[C,P]=w.useState([]),_=w.useMemo(()=>o?C.filter(M=>M.toasterId===o):C.filter(M=>!M.toasterId),[C,o]),O=w.useMemo(()=>Array.from(new Set([s].concat(_.filter(M=>M.position).map(M=>M.position)))),[_,s]),[I,$]=w.useState([]),[G,W]=w.useState(!1),[B,K]=w.useState(!1),[H,U]=w.useState(p!=="system"?p:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),q=w.useRef(null),R=a.join("+").replace(/Key/g,"").replace(/Digit/g,""),D=w.useRef(null),L=w.useRef(!1),k=w.useCallback(M=>{P(F=>{var A;return(A=F.find(z=>z.id===M.id))!=null&&A.delete||Xe.dismiss(M.id),F.filter(({id:z})=>z!==M.id)})},[]);return w.useEffect(()=>Xe.subscribe(M=>{if(M.dismiss){requestAnimationFrame(()=>{P(F=>F.map(A=>A.id===M.id?{...A,delete:!0}:A))});return}setTimeout(()=>{Cc.flushSync(()=>{P(F=>{const A=F.findIndex(z=>z.id===M.id);return A!==-1?[...F.slice(0,A),{...F[A],...M},...F.slice(A+1)]:[M,...F]})})})}),[C]),w.useEffect(()=>{if(p!=="system"){U(p);return}if(p==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?U("dark"):U("light")),typeof window>"u")return;const M=window.matchMedia("(prefers-color-scheme: dark)");try{M.addEventListener("change",({matches:F})=>
5{U(F?"dark":"light")})}catch{M.addListener(({matches:A})=>{try{U(A?"dark":"light")}catch(z){console.error(z)}})}},[p]),w.useEffect(()=>{C.length<=1&&W(!1)},[C]),w.useEffect(()=>{const M=F=>{var A;if(a.every(Y=>F[Y]||F.code===Y)){var N;W(!0),(N=q.current)==null||N.focus()}F.code==="Escape"&&(document.activeElement===q.current||(A=q.current)!=null&&A.contains(document.activeElement))&&W(!1)};return document.addEventListener("keydown",M),()=>document.removeEventListener("keydown",M)},[a]),w.useEffect(()=>{if(q.current)return()=>{D.current&&(D.current.focus({preventScroll:!0}),D.current=null,L.current=!1)}},[q.current]),w.createElement("section",{ref:n,"aria-label":`${T} ${R}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},O.map((M,F)=>{var A;const[z,N]=M.split("-");return _.length?w.createElement("ol",{key:M,dir:b==="auto"?nl():b,tabIndex:-1,ref:q,className:u,"data-sonner-toaster":!0,"data-sonner-theme":H,"data-y-position":z,"data-x-position":N,style:{"--front-toast-height":`${((A=I[0])==null?void 0:A.height)||0}px`,"--width":`${F1}px`,"--gap":`${x}px`,...v,...H1(d,f)},onBlur:Y=>{L.current&&!Y.currentTarget.contains(Y.relatedTarget)&&(L.current=!1,D.current&&(D.current.focus({preventScroll:!0}),D.current=null))},onFocus:Y=>{Y.target instanceof HTMLElement&&Y.target.dataset.dismissible==="false"||L.current||(L.current=!0,D.current=Y.relatedTarget)},onMouseEnter:()=>W(!0),onMouseMove:()=>W(!0),onMouseLeave:()=>{B||W(!1)},onDragEnd:()=>W(!1),onPointerDown:Y=>{Y.target instanceof HTMLElement&&Y.target.dataset.dismissible==="false"||K(!0)},onPointerUp:()=>K(!1)},_.filter(Y=>!Y.position&&F===0||Y.position===M).map((Y,te)=>{var ae,pe;return w.createElement(W1,{key:Y.id,icons:S,index:te,toast:Y,defaultRichColors:h,duration:(ae=y?.duration)!=null?ae:m,className:y?.className,descriptionClassName:y?.descriptionClassName,invert:r,visibleToasts:g,closeButton:(pe=y?.closeButton)!=null?pe:c,interacting:B,position:M,style:y?.style,unstyled:y?.unstyled,classNames:y?.classNames,cancelButtonStyle:y?.cancelButtonStyle,actionButtonStyle:y?.actionButtonStyle,closeButtonAriaLabel:y?.closeButtonAriaLabel,removeToast:k,toasts:_.filter(ee=>ee.position==Y.position),heights:I.filter(ee=>ee.position==Y.position),setHeights:$,expandByDefault:i,gap:x,expanded:G,swipeDirections:t.swipeDirections})})):null}))});var U1=Object.defineProperty,G1=Object.defineProperties,Y1=Object.getOwnPropertyDescriptors,Jo=Object.getOwnPropertySymbols,bf=Object.prototype.hasOwnProperty,xf=Object.prototype.propertyIsEnumerable,ol=(e,t,n)=>t in e?U1(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,z1=(e,t)=>{for(var n in t||(t={}))bf.call(t,n)&&ol(e,n,t[n]);if(Jo)for(var n of Jo(t))xf.call(t,n)&&ol(e,n,t[n]);return e},K1=(e,t)=>G1(e,Y1(t)),q1=(e,t)=>{var n={};for(var o in e)bf.call(e,o)&&t.indexOf(o)<0&&(n[o]=e[o]);if(e!=null&&Jo)for(var o of Jo(e))t.indexOf(o)<0&&xf.call(e,o)&&(n[o]=e[o]);return n};function X1(e){let t=setTimeout(e,0),n=setTimeout(e,10),o=setTimeout(e,50);return[t,n,o]}function Z1(e){let t=l.useRef();return l.useEffect(()=>{t.current=e}),t.current}var Q1=18,wf=40,J1=`${wf}px`,ew=["[data-lastpass-icon-root]","com-1password-button","[data-dashlanecreated]",'[style$="2147483647 !important;"]'].join(",");function tw({containerRef:e,inputRef:t,pushPasswordManagerStrategy:n,isFocused:o}){let[r,s]=l.useState(!1),[a,i]=l.useState(!1),[c,u]=l.useState(!1),d=l.useMemo(()=>n==="none"?!1:(n==="increase-width"||n==="experimental-no-flickering")&&r&&a,[r,a,n]),f=l.useCallback(()=>{let p=e.current,h=t.current;if(!p||!h||c||n==="none")return;let m=p,v=m.getBoundingClientRect().left+m.offsetWidth,g=m.getBoundingClientRect().top+m.offsetHeight/2,y=v-Q1,b=g;document.querySelectorAll(ew).length===0&&document.elementFromPoint(y,b)===p||(s(!0),u(!0))},[e,t,c,n]);return l.useEffect(()=>{let p=e.current;if(!p||n==="none")return;function h(){let v=window.innerWidth-p.getBoundingClientRect().right;i(v>=wf)}h();let m=setInterval(h,1e3);return()=>{clearInterval(m)}},[e,n]),l.useEffect(()=>{let p=o||document.activeElement===t.current;if(n==="none"||!p)return;let h=setTimeout(f,0),m=setTimeout(f,2e3),v=setTimeout(f,5e3),g=setTimeout(()=>{u(!0)},6e3);return()=>{clearTimeout(h),clearTimeout(m),clearTimeout(v),clearTimeout(g)}},[t,o,n,f]),{hasPWMBadge:r,willPushPWMBadge:d,PWM_BADGE_SPACE_WIDTH:J1}}var nw=l.createContext({}),ow=l.forwardRef((e,t)=>
5{var n=e,{value:o,onChange:r,maxLength:s,textAlign:a="left",pattern:i,placeholder:c,inputMode:u="numeric",onComplete:d,pushPasswordManagerStrategy:f="increase-width",pasteTransformer:p,containerClassName:h,noScriptCSSFallback:m=rw,render:v,children:g}=n,y=q1(n,["value","onChange","maxLength","textAlign","pattern","placeholder","inputMode","onComplete","pushPasswordManagerStrategy","pasteTransformer","containerClassName","noScriptCSSFallback","render","children"]),b,x,S,T,C;let[P,_]=l.useState(typeof y.defaultValue=="string"?y.defaultValue:""),O=o??P,I=Z1(O),$=l.useCallback(V=>{r?.(V),_(V)},[r]),G=l.useMemo(()=>i?typeof i=="string"?new RegExp(i):i:null,[i]),W=l.useRef(null),B=l.useRef(null),K=l.useRef({value:O,onChange:$,isIOS:typeof window<"u"&&((x=(b=window?.CSS)==null?void 0:b.supports)==null?void 0:x.call(b,"-webkit-touch-callout","none"))}),H=l.useRef({prev:[(S=W.current)==null?void 0:S.selectionStart,(T=W.current)==null?void 0:T.selectionEnd,(C=W.current)==null?void 0:C.selectionDirection]});l.useImperativeHandle(t,()=>W.current,[]),l.useEffect(()=>{let V=W.current,Q=B.current;if(!V||!Q)return;K.current.value!==V.value&&K.current.onChange(V.value),H.current.prev=[V.selectionStart,V.selectionEnd,V.selectionDirection];function me(){if(document.activeElement!==V){k(null),F(null);return}let ve=V.selectionStart,Fe=V.selectionEnd,Ft=V.selectionDirection,Se=V.maxLength,Le=V.value,We=H.current.prev,qe=-1,He=-1,lt;if(Le.length!==0&&ve!==null&&Fe!==null){let gn=ve===Fe,wt=ve===Le.length&&Le.length<Se;if(gn&&!wt){let ct=ve;if(ct===0)qe=0,He=1,lt="forward";else if(ct===Se)qe=ct-1,He=ct,lt="backward";else if(Se>1&&Le.length>1){let tn=0;if(We[0]!==null&&We[1]!==null){lt=ct<We[1]?"backward":"forward";let yn=We[0]===We[1]&&We[0]<Se;lt==="backward"&&!yn&&(tn=-1)}qe=tn+ct,He=tn+ct+1}}qe!==-1&&He!==-1&&qe!==He&&W.current.setSelectionRange(qe,He,lt)}let en=qe!==-1?qe:ve,Lt=He!==-1?He:Fe,xt=lt??Ft;k(en),F(Lt),H.current.prev=[en,Lt,xt]}if(document.addEventListener("selectionchange",me,{capture:!0}),me(),document.activeElement===V&&D(!0),!document.getElementById("input-otp-style")){let ve=document.createElement("style");if(ve.id="input-otp-style",document.head.appendChild(ve),ve.sheet){let Fe="background: transparent !important; color: transparent !important; border-color: transparent !important; opacity: 0 !important; box-shadow: none !important; -webkit-box-shadow: none !important; -webkit-text-fill-color: transparent !important;";qn(ve.sheet,"[data-input-otp]::selection { background: transparent !important; color: transparent !important; }"),qn(ve.sheet,`[data-input-otp]:autofill { ${Fe} }`),qn(ve.sheet,`[data-input-otp]:-webkit-autofill { ${Fe} }`),qn(ve.sheet,"@supports (-webkit-touch-callout: none) { [data-input-otp] { letter-spacing: -.6em !important; font-weight: 100 !important; font-stretch: ultra-condensed; font-optical-sizing: none !important; left: -1px !important; right: 1px !important; } }"),qn(ve.sheet,"[data-input-otp] + * { pointer-events: all !important; }")}}let we=()=>{Q&&Q.style.setProperty("--root-height",`${V.clientHeight}px`)};we();let Re=new ResizeObserver(we);return Re.observe(V),()=>{document.removeEventListener("selectionchange",me,{capture:!0}),Re.disconnect()}},[]);let[U,q]=l.useState(!1),[R,D]=l.useState(!1),[L,k]=l.useState(null),[M,F]=l.useState(null);l.useEffect(()=>{X1(()=>{var V,Q,me,we;(V=W.current)==null||V.dispatchEvent(new Event("input"));let Re=(Q=W.current)==null?void 0:Q.selectionStart,ve=(me=W.current)==null?void 0:me.selectionEnd,Fe=(we=W.current)==null?void 0:we.selectionDirection;Re!==null&&ve!==null&&(k(Re),F(ve),H.current.prev=[Re,ve,Fe])})},[O,R]),l.useEffect(()=>{I!==void 0&&O!==I&&I.length<s&&O.length===s&&d?.(O)},[s,d,I,O]);let A=tw({containerRef:B,inputRef:W,pushPasswordManagerStrategy:f,isFocused:R}),z=l.useCallback(V=>{let Q=V.currentTarget.value.slice(0,s);if(Q.length>0&&G&&!G.test(Q)){V.preventDefault();return}typeof I=="string"&&Q.length<I.length&&document.dispatchEvent(new Event("selectionchange")),$(Q)},[s,$,I,G]),N=l.useCallback(()=>{var V;if(W.current){let Q=Math.min(W.current.value.length,s-1),me=W.current.value.length;(V=W.current)==null||V.setSelectionRange(Q,me),k(Q),F(me)}D(!0)},[s]),Y=l.useCallback(V=>{var Q,me;let we=W.current;
5if(!p&&(!K.current.isIOS||!V.clipboardData||!we))return;let Re=V.clipboardData.getData("text/plain"),ve=p?p(Re):Re;V.preventDefault();let Fe=(Q=W.current)==null?void 0:Q.selectionStart,Ft=(me=W.current)==null?void 0:me.selectionEnd,Se=(Fe!==Ft?O.slice(0,Fe)+ve+O.slice(Ft):O.slice(0,Fe)+ve+O.slice(Fe)).slice(0,s);if(Se.length>0&&G&&!G.test(Se))return;we.value=Se,$(Se);let Le=Math.min(Se.length,s-1),We=Se.length;we.setSelectionRange(Le,We),k(Le),F(We)},[s,$,G,O]),te=l.useMemo(()=>({position:"relative",cursor:y.disabled?"default":"text",userSelect:"none",WebkitUserSelect:"none",pointerEvents:"none"}),[y.disabled]),ae=l.useMemo(()=>({position:"absolute",inset:0,width:A.willPushPWMBadge?`calc(100% + ${A.PWM_BADGE_SPACE_WIDTH})`:"100%",clipPath:A.willPushPWMBadge?`inset(0 ${A.PWM_BADGE_SPACE_WIDTH} 0 0)`:void 0,height:"100%",display:"flex",textAlign:a,opacity:"1",color:"transparent",pointerEvents:"all",background:"transparent",caretColor:"transparent",border:"0 solid transparent",outline:"0 solid transparent",boxShadow:"none",lineHeight:"1",letterSpacing:"-.5em",fontSize:"var(--root-height)",fontFamily:"monospace",fontVariantNumeric:"tabular-nums"}),[A.PWM_BADGE_SPACE_WIDTH,A.willPushPWMBadge,a]),pe=l.useMemo(()=>l.createElement("input",K1(z1({autoComplete:y.autoComplete||"one-time-code"},y),{"data-input-otp":!0,"data-input-otp-placeholder-shown":O.length===0||void 0,"data-input-otp-mss":L,"data-input-otp-mse":M,inputMode:u,pattern:G?.source,"aria-placeholder":c,style:ae,maxLength:s,value:O,ref:W,onPaste:V=>{var Q;Y(V),(Q=y.onPaste)==null||Q.call(y,V)},onChange:z,onMouseOver:V=>{var Q;q(!0),(Q=y.onMouseOver)==null||Q.call(y,V)},onMouseLeave:V=>{var Q;q(!1),(Q=y.onMouseLeave)==null||Q.call(y,V)},onFocus:V=>{var Q;N(),(Q=y.onFocus)==null||Q.call(y,V)},onBlur:V=>{var Q;D(!1),(Q=y.onBlur)==null||Q.call(y,V)}})),[z,N,Y,u,ae,s,M,L,y,G?.source,O]),ee=l.useMemo(()=>({slots:Array.from({length:s}).map((V,Q)=>{var me;let we=R&&L!==null&&M!==null&&(L===M&&Q===L||Q>=L&&Q<M),Re=O[Q]!==void 0?O[Q]:null,ve=O[0]!==void 0?null:(me=c?.[Q])!=null?me:null;return{char:Re,placeholderChar:ve,isActive:we,hasFakeCaret:we&&Re===null}}),isFocused:R,isHovering:!y.disabled&&U}),[R,U,s,M,L,y.disabled,O]),ue=l.useMemo(()=>v?v(ee):l.createElement(nw.Provider,{value:ee},g),[g,ee,v]);return l.createElement(l.Fragment,null,m!==null&&l.createElement("noscript",null,l.createElement("style",null,m)),l.createElement("div",{ref:B,"data-input-otp-container":!0,style:te,className:h},ue,l.createElement("div",{style:{position:"absolute",inset:0,pointerEvents:"none"}},pe)))});ow.displayName="Input";function qn(e,t){try{e.insertRule(t)}catch{console.error("input-otp could not insert CSS rule:",t)}}var rw=`
6[data-input-otp] {
7  --nojs-bg: white !important;
8  --nojs-fg: black !important;
9
10  background-color: var(--nojs-bg) !important;
11  color: var(--nojs-fg) !important;
12  caret-color: var(--nojs-fg) !important;
13  letter-spacing: .25em !important;
14  text-align: center !important;
15  border: 1px solid var(--nojs-fg) !important;
16  border-radius: 4px !important;
17  width: 100% !important;
18}
19@media (prefers-color-scheme: dark) {
20  [data-input-otp] {
21    --nojs-bg: black !important;
22    --nojs-fg: white !important;
23  }
24}`,sw=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],aw=sw.reduce((e,t)=>{const n=ur(`Primitive.${t}`),o=l.forwardRef((r,s)=>{const{asChild:a,...i}=r,c=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),E.jsx(c,{...i,ref:s})});return o.displayName=`Primitive.${t}`,{...e,[t]:o}},{}),iw="Label",Ef=l.forwardRef((e,t)=>E.jsx(aw.label,{...e,ref:t,onMouseDown:n=>{n.target.closest("button, input, select, textarea")||(e.onMouseDown?.(n),!n.defaultPrevented&&n.detail>1&&n.preventDefault())}}));Ef.displayName=iw;var k2=Ef,lw=Symbol("radix.slottable");function cw(e){const t=({children:n})=>E.jsx(E.Fragment,{children:n});return t.displayName=`${e}.Slottable`,t.__radixId=lw,t}var Cf="AlertDialog",[uw]=rt(Cf,[Gc]),Nt=Gc(),Sf=e=>{const{__scopeAlertDialog:t,...n}=e,o=Nt(t);return E.jsx(iu,{...o,...n,modal:!0})};
vendor: 4,504 bytes, lines 24-30
24Sf.displayName=Cf;var dw="AlertDialogTrigger",fw=l.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...o}=e,r=Nt(n);return E.jsx(Hy,{...r,...o,ref:t})});fw.displayName=dw;var pw="AlertDialogPortal",Pf=e=>{const{__scopeAlertDialog:t,...n}=e,o=Nt(t);return E.jsx(lu,{...o,...n})};Pf.displayName=pw;var hw="AlertDialogOverlay",Mf=l.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...o}=e,r=Nt(n);return E.jsx(cu,{...r,...o,ref:t})});Mf.displayName=hw;var Mn="AlertDialogContent",[mw,vw]=uw(Mn),gw=cw("AlertDialogContent"),Tf=l.forwardRef((e,t)=>{const{__scopeAlertDialog:n,children:o,...r}=e,s=Nt(n),a=l.useRef(null),i=he(t,a),c=l.useRef(null);return E.jsx(jy,{contentName:Mn,titleName:kf,docsSlug:"alert-dialog",children:E.jsx(mw,{scope:n,cancelRef:c,children:E.jsxs(uu,{role:"alertdialog",...s,...r,ref:i,onOpenAutoFocus:J(r.onOpenAutoFocus,u=>{u.preventDefault(),c.current?.focus({preventScroll:!0})}),onPointerDownOutside:u=>u.preventDefault(),onInteractOutside:u=>u.preventDefault(),children:[E.jsx(gw,{children:o}),E.jsx(bw,{contentRef:a})]})})})});Tf.displayName=Mn;var kf="AlertDialogTitle",Rf=l.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...o}=e,r=Nt(n);return E.jsx(Uy,{...r,...o,ref:t})});Rf.displayName=kf;var Df="AlertDialogDescription",If=l.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...o}=e,r=Nt(n);return E.jsx(Gy,{...r,...o,ref:t})});If.displayName=Df;var yw="AlertDialogAction",Of=l.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...o}=e,r=Nt(n);return E.jsx(du,{...r,...o,ref:t})});Of.displayName=yw;var Af="AlertDialogCancel",_f=l.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...o}=e,{cancelRef:r}=vw(Af,n),s=Nt(n),a=he(t,r);return E.jsx(du,{...s,...o,ref:a})});_f.displayName=Af;var bw=({contentRef:e})=>{const t=`\`${Mn}\` requires a description for the component to be accessible for screen reader users.
25
26You can add a description to the \`${Mn}\` by passing a \`${Df}\` component as a child, which also benefits sighted users by adding visible context to the dialog.
27
28Alternatively, you can use your own component as a description by assigning it an \`id\` and passing the same value to the \`aria-describedby\` prop in \`${Mn}\`. If the description is confusing or duplicative for sighted users, you can use the \`@radix-ui/react-visually-hidden\` primitive as a wrapper around your description component.
29
30For more information, see https://radix-ui.com/primitives/docs/components/alert-dialog`;return l.useEffect(()=>{document.getElementById(e.current?.getAttribute("aria-describedby"))||console.warn(t)},[t,e]),null},R2=Sf,D2=Pf,I2=Mf,O2=Tf,A2=Of,_2=_f,N2=Rf,$2=If,kr="Checkbox",[xw]=rt(kr),[ww,Na]=xw(kr);function Ew(e){const{__scopeCheckbox:t,checked:n,children:o,defaultChecked:r,disabled:s,form:a,name:i,onCheckedChange:c,required:u,value:d="on",internal_do_not_use_render:f}=e,[p,h]=Mt({prop:n,defaultProp:r??!1,onChange:c,caller:kr}),[m,v]=l.useState(null),[g,y]=l.useState(null),b=l.useRef(!1),x=m?!!a||!!m.closest("form"):!0,S={checked:p,disabled:s,setChecked:h,control:m,setControl:v,name:i,form:a,value:d,hasConsumerStoppedPropagationRef:b,required:u,defaultChecked:Ut(r)?!1:r,isFormControl:x,bubbleInput:g,setBubbleInput:y};return E.jsx(ww,{scope:t,...S,children:Pw(f)?f(S):o})}var Nf="CheckboxTrigger",$f=l.forwardRef(({__scopeCheckbox:e,onKeyDown:t,onClick:n,...o},r)=>{const{control:s,value:a,disabled:i,checked:c,required:u,setControl:d,setChecked:f,hasConsumerStoppedPropagationRef:p,isFormControl:h,bubbleInput:m}=Na(Nf,e),v=he(r,d),g=l.useRef(c);return l.useEffect(()=>{const y=s?.form;if(y){const b=()=>f(g.current);return y.addEventListener("reset",b),()=>y.removeEventListener("reset",b)}},[s,f]),E.jsx(re.button,{type:"button",role:"checkbox","aria-checked":Ut(c)?"mixed":c,"aria-required":u,"data-state":Bf(c),"data-disabled":i?"":void 0,disabled:i,value:a,...o,ref:v,onKeyDown:J(t,y=>{y.key==="Enter"&&y.preventDefault()}),onClick:J(n,y=>{f(b=>Ut(b)?!0:!b),m&&h&&(p.current=y.isPropagationStopped(),p.current||y.stopPropagation())})})});$f.displayName=Nf;var Cw=l.forwardRef((e,t)=>{const{__scopeCheckbox:n,name:o,checked:r,defaultChecked:s,required:a,disabled:i,value:c,onCheckedChange:u,form:d,...f}=e;return E.jsx(Ew,{__scopeCheckbox:n,checked:r,defaultChecked:s,disabled:i,required:a,onCheckedChange:u,name:o,form:d,value:c,internal_do_not_use_render:({isFormControl:p})=>E.jsxs(E.Fragment,{children:[E.jsx($f,{...f,ref:t,__scopeCheckbox:n}),p&&E.jsx(jf,{__scopeCheckbox:n})]})})});Cw.displayName=kr;var Ff="CheckboxIndicator",Sw=l.forwardRef((e,t)=>
vendor: 4,268 bytes, line 30
30{const{__scopeCheckbox:n,forceMount:o,...r}=e,s=Na(Ff,n);return E.jsx(Ze,{present:o||Ut(s.checked)||s.checked===!0,children:E.jsx(re.span,{"data-state":Bf(s.checked),"data-disabled":s.disabled?"":void 0,...r,ref:t,style:{pointerEvents:"none",...e.style}})})});Sw.displayName=Ff;var Lf="CheckboxBubbleInput",jf=l.forwardRef(({__scopeCheckbox:e,...t},n)=>{const{control:o,hasConsumerStoppedPropagationRef:r,checked:s,defaultChecked:a,required:i,disabled:c,name:u,value:d,form:f,bubbleInput:p,setBubbleInput:h}=Na(Lf,e),m=he(n,h),v=Aa(s),g=va(o);l.useEffect(()=>{const b=p;if(!b)return;const x=window.HTMLInputElement.prototype,T=Object.getOwnPropertyDescriptor(x,"checked").set,C=!r.current;if(v!==s&&T){const P=new Event("click",{bubbles:C});b.indeterminate=Ut(s),T.call(b,Ut(s)?!1:s),b.dispatchEvent(P)}},[p,v,s,r]);const y=l.useRef(Ut(s)?!1:s);return E.jsx(re.input,{type:"checkbox","aria-hidden":!0,defaultChecked:a??y.current,required:i,disabled:c,name:u,value:d,form:f,...t,tabIndex:-1,ref:m,style:{...t.style,...g,position:"absolute",pointerEvents:"none",opacity:0,margin:0,transform:"translateX(-100%)"}})});jf.displayName=Lf;function Pw(e){return typeof e=="function"}function Ut(e){return e==="indeterminate"}function Bf(e){return Ut(e)?"indeterminate":e?"checked":"unchecked"}var Rr="Tabs",[Mw]=rt(Rr,[br]),Vf=br(),[Tw,$a]=Mw(Rr),Wf=l.forwardRef((e,t)=>{const{__scopeTabs:n,value:o,onValueChange:r,defaultValue:s,orientation:a="horizontal",dir:i,activationMode:c="automatic",...u}=e,d=yr(i),[f,p]=Mt({prop:o,onChange:r,defaultProp:s??"",caller:Rr});return E.jsx(Tw,{scope:n,baseId:$e(),value:f,onValueChange:p,orientation:a,dir:d,activationMode:c,children:E.jsx(re.div,{dir:d,"data-orientation":a,...u,ref:t})})});Wf.displayName=Rr;var Hf="TabsList",Uf=l.forwardRef((e,t)=>{const{__scopeTabs:n,loop:o=!0,...r}=e,s=$a(Hf,n),a=Vf(n);return E.jsx(Uu,{asChild:!0,...a,orientation:s.orientation,dir:s.dir,loop:o,children:E.jsx(re.div,{role:"tablist","aria-orientation":s.orientation,...r,ref:t})})});Uf.displayName=Hf;var Gf="TabsTrigger",Yf=l.forwardRef((e,t)=>{const{__scopeTabs:n,value:o,disabled:r=!1,...s}=e,a=$a(Gf,n),i=Vf(n),c=Kf(a.baseId,o),u=qf(a.baseId,o),d=o===a.value;return E.jsx(Gu,{asChild:!0,...i,focusable:!r,active:d,children:E.jsx(re.button,{type:"button",role:"tab","aria-selected":d,"aria-controls":u,"data-state":d?"active":"inactive","data-disabled":r?"":void 0,disabled:r,id:c,...s,ref:t,onMouseDown:J(e.onMouseDown,f=>{!r&&f.button===0&&f.ctrlKey===!1?a.onValueChange(o):f.preventDefault()}),onKeyDown:J(e.onKeyDown,f=>{[" ","Enter"].includes(f.key)&&a.onValueChange(o)}),onFocus:J(e.onFocus,()=>{const f=a.activationMode!=="manual";!d&&!r&&f&&a.onValueChange(o)})})})});Yf.displayName=Gf;var zf="TabsContent",kw=l.forwardRef((e,t)=>{const{__scopeTabs:n,value:o,forceMount:r,children:s,...a}=e,i=$a(zf,n),c=Kf(i.baseId,o),u=qf(i.baseId,o),d=o===i.value,f=l.useRef(d);return l.useEffect(()=>{const p=requestAnimationFrame(()=>f.current=!1);return()=>cancelAnimationFrame(p)},[]),E.jsx(Ze,{present:r||d,children:({present:p})=>E.jsx(re.div,{"data-state":d?"active":"inactive","data-orientation":i.orientation,role:"tabpanel","aria-labelledby":c,hidden:!p,id:u,tabIndex:0,...a,ref:t,style:{...e.style,animationDuration:f.current?"0s":void 0},children:p&&s})})});kw.displayName=zf;function Kf(e,t){return`${e}-trigger-${t}`}function qf(e,t){return`${e}-content-${t}`}var F2=Wf,L2=Uf,j2=Yf,Dr="Switch",[Rw]=rt(Dr),[Dw,Iw]=Rw(Dr),Xf=l.forwardRef((e,t)=>{const{__scopeSwitch:n,name:o,checked:r,defaultChecked:s,required:a,disabled:i,value:c="on",onCheckedChange:u,form:d,...f}=e,[p,h]=l.useState(null),m=he(t,x=>h(x)),v=l.useRef(!1),g=p?d||!!p.closest("form"):!0,[y,b]=Mt({prop:r,defaultProp:s??!1,onChange:u,caller:Dr});return E.jsxs(Dw,{scope:n,checked:y,disabled:i,children:[E.jsx(re.button,{type:"button",role:"switch","aria-checked":y,"aria-required":a,"data-state":ep(y),"data-disabled":i?"":void 0,disabled:i,value:c,...f,ref:m,onClick:J(e.onClick,x=>{b(S=>!S),g&&(v.current=x.isPropagationStopped(),v.current||x.stopPropagation())})}),g&&E.jsx(Jf,{control:p,bubbles:!v.current,name:o,value:c,checked:y,required:a,disabled:i,form:d,style:{transform:"translateX(-100%)"}})]})});Xf.displayName=Dr;var Zf="SwitchThumb",Qf=l.forwardRef((e,t)=>
vendor: 7,504 bytes, lines 30-38
30{const{__scopeSwitch:n,...o}=e,r=Iw(Zf,n);return E.jsx(re.span,{"data-state":ep(r.checked),"data-disabled":r.disabled?"":void 0,...o,ref:t})});Qf.displayName=Zf;var Ow="SwitchBubbleInput",Jf=l.forwardRef(({__scopeSwitch:e,control:t,checked:n,bubbles:o=!0,...r},s)=>{const a=l.useRef(null),i=he(a,s),c=Aa(n),u=va(t);return l.useEffect(()=>{const d=a.current;if(!d)return;const f=window.HTMLInputElement.prototype,h=Object.getOwnPropertyDescriptor(f,"checked").set;if(c!==n&&h){const m=new Event("click",{bubbles:o});h.call(d,n),d.dispatchEvent(m)}},[c,n,o]),E.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:n,...r,tabIndex:-1,ref:i,style:{...r.style,...u,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});Jf.displayName=Ow;function ep(e){return e?"checked":"unchecked"}var B2=Xf,V2=Qf;const Fa=l.createContext({});function Qt(e){const t=l.useRef(null);return t.current===null&&(t.current=e()),t.current}const La=typeof window<"u",ja=La?l.useLayoutEffect:l.useEffect,Ir=l.createContext(null),Or=l.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});function rl(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function Aw(...e){return t=>{let n=!1;const o=e.map(r=>{const s=rl(r,t);return!n&&typeof s=="function"&&(n=!0),s});if(n)return()=>{for(let r=0;r<o.length;r++){const s=o[r];typeof s=="function"?s():rl(e[r],null)}}}}function _w(...e){return l.useCallback(Aw(...e),e)}class Nw extends l.Component{getSnapshotBeforeUpdate(t){const n=this.props.childRef.current;if(n&&t.isPresent&&!this.props.isPresent){const o=n.offsetParent,r=om(o)&&o.offsetWidth||0,s=this.props.sizeRef.current;s.height=n.offsetHeight||0,s.width=n.offsetWidth||0,s.top=n.offsetTop,s.left=n.offsetLeft,s.right=r-s.width-s.left}return null}componentDidUpdate(){}render(){return this.props.children}}function $w({children:e,isPresent:t,anchorX:n,root:o}){const r=l.useId(),s=l.useRef(null),a=l.useRef({width:0,height:0,top:0,left:0,right:0}),{nonce:i}=l.useContext(Or),c=_w(s,e?.ref);return l.useInsertionEffect(()=>{const{width:u,height:d,top:f,left:p,right:h}=a.current;if(t||!s.current||!u||!d)return;const m=n==="left"?`left: ${p}`:`right: ${h}`;s.current.dataset.motionPopId=r;const v=document.createElement("style");i&&(v.nonce=i);const g=o??document.head;return g.appendChild(v),v.sheet&&v.sheet.insertRule(`
31          [data-motion-pop-id="${r}"] {
32            position: absolute !important;
33            width: ${u}px !important;
34            height: ${d}px !important;
35            ${m}px !important;
36            top: ${f}px !important;
37          }
38        `),()=>{g.contains(v)&&g.removeChild(v)}},[t]),E.jsx(Nw,{isPresent:t,childRef:s,sizeRef:a,children:l.cloneElement(e,{ref:c})})}const Fw=({children:e,initial:t,isPresent:n,onExitComplete:o,custom:r,presenceAffectsLayout:s,mode:a,anchorX:i,root:c})=>{const u=Qt(Lw),d=l.useId();let f=!0,p=l.useMemo(()=>(f=!1,{id:d,initial:t,isPresent:n,custom:r,onExitComplete:h=>{u.set(h,!0);for(const m of u.values())if(!m)return;o&&o()},register:h=>(u.set(h,!1),()=>u.delete(h))}),[n,u,o]);return s&&f&&(p={...p}),l.useMemo(()=>{u.forEach((h,m)=>u.set(m,!1))},[n]),l.useEffect(()=>{!n&&!u.size&&o&&o()},[n]),a==="popLayout"&&(e=E.jsx($w,{isPresent:n,anchorX:i,root:c,children:e})),E.jsx(Ir.Provider,{value:p,children:e})};function Lw(){return new Map}function tp(e=!0){const t=l.useContext(Ir);if(t===null)return[!0,null];const{isPresent:n,onExitComplete:o,register:r}=t,s=l.useId();l.useEffect(()=>{if(e)return r(s)},[e]);const a=l.useCallback(()=>e&&o&&o(s),[s,o,e]);return!n&&o?[!1,a]:[!0]}const jo=e=>e.key||"";function sl(e){const t=[];return l.Children.forEach(e,n=>{l.isValidElement(n)&&t.push(n)}),t}const W2=({children:e,custom:t,initial:n=!0,onExitComplete:o,presenceAffectsLayout:r=!0,mode:s="sync",propagate:a=!1,anchorX:i="left",root:c})=>{const[u,d]=tp(a),f=l.useMemo(()=>sl(e),[e]),p=a&&!u?[]:f.map(jo),h=l.useRef(!0),m=l.useRef(f),v=Qt(()=>new Map),[g,y]=l.useState(f),[b,x]=l.useState(f);ja(()=>{h.current=!1,m.current=f;for(let C=0;C<b.length;C++){const P=jo(b[C]);p.includes(P)?v.delete(P):v.get(P)!==!0&&v.set(P,!1)}},[b,p.length,p.join("-")]);const S=[];if(f!==g){let C=[...f];for(let P=0;P<b.length;P++){const _=b[P],O=jo(_);p.includes(O)||(C.splice(P,0,_),S.push(_))}return s==="wait"&&S.length&&(C=S),x(sl(C)),y(f),null}const{forceRender:T}=l.useContext(Fa);return E.jsx(E.Fragment,{children:b.map(C=>{const P=jo(C),_=a&&!u?!1:f===b||p.includes(P),O=()=>{if(v.has(P))v.set(P,!0);else return;let I=!0;v.forEach($=>{$||(I=!1)}),I&&(T?.(),x(m.current),a&&d?.(),o&&o())};return E.jsx(Fw,{isPresent:_,initial:!h.current||n?void 0:!1,custom:t,presenceAffectsLayout:r,mode:s,root:c,onExitComplete:_?void 0:O,anchorX:i,children:C},P)})})},np=l.createContext({strict:!1}),al={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},In={};for(const e in al)In[e]={isEnabled:t=>al[e].some(n=>!!t[n])};function jw(e){for(const t in e)In[t]={...In[t],...e[t]}}const Bw=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function er(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||Bw.has(e)}let op=e=>!er(e);function Vw(e){typeof e=="function"&&(op=t=>t.startsWith("on")?!er(t):e(t))}try{Vw(require("@emotion/is-prop-valid").default)}catch{}function Ww(e,t,n){const o={};for(const r in e)r==="values"&&typeof e.values=="object"||(op(r)||n===!0&&er(r)||!t&&!er(r)||e.draggable&&r.startsWith("onDrag"))&&(o[r]=e[r]);return o}const Ar=l.createContext({});function _r(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function co(e){return typeof e=="string"||Array.isArray(e)}const Ba=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],Va=["initial",...Ba];function Nr(e){return _r(e.animate)||Va.some(t=>co(e[t]))}function rp(e){return!!(Nr(e)||e.variants)}function Hw(e,t){if(Nr(e)){const{initial:n,animate:o}=e;return{initial:n===!1||co(n)?n:void 0,animate:co(o)?o:void 0}}return e.inherit!==!1?t:{}}function Uw(e){const{initial:t,animate:n}=Hw(e,l.useContext(Ar));return l.useMemo(()=>({initial:t,animate:n}),[il(t),il(n)])}function il(e){return Array.isArray(e)?e.join(" "):e}const uo={};function Gw(e){for(const t in e)uo[t]=e[t],la(t)&&(uo[t].isCSSVariable=!0)}function sp(e,{layout:t,layoutId:n}){return An.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!uo[e]||e==="opacity")}const Yw={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},zw=ca.length;function Kw(e,t,n){let o="",r=!0;for(let s=0;s<zw;s++){const a=ca[s],i=e[a];if(i===void 0)continue;let c=!0;if(typeof i=="number"?c=i===(a.startsWith("scale")?1:0):c=parseFloat(i)===0,!c||n){const u=Rc(i,Dc[a]
vendor: 5,207 bytes, line 38
38);if(!c){r=!1;const d=Yw[a]||a;o+=`${d}(${u}) `}n&&(t[a]=u)}}return o=o.trim(),n?o=n(t,r?"":o):r&&(o="none"),o}function Wa(e,t,n){const{style:o,vars:r,transformOrigin:s}=e;let a=!1,i=!1;for(const c in t){const u=t[c];if(An.has(c)){a=!0;continue}else if(la(c)){r[c]=u;continue}else{const d=Rc(u,Dc[c]);c.startsWith("origin")?(i=!0,s[c]=d):o[c]=d}}if(t.transform||(a||n?o.transform=Kw(t,e.transform,n):o.transform&&(o.transform="none")),i){const{originX:c="50%",originY:u="50%",originZ:d=0}=s;o.transformOrigin=`${c} ${u} ${d}`}}const Ha=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function ap(e,t,n){for(const o in t)!Be(t[o])&&!sp(o,n)&&(e[o]=t[o])}function qw({transformTemplate:e},t){return l.useMemo(()=>{const n=Ha();return Wa(n,t,e),Object.assign({},n.vars,n.style)},[t])}function Xw(e,t){const n=e.style||{},o={};return ap(o,n,e),Object.assign(o,qw(e,t)),o}function Zw(e,t){const n={},o=Xw(e,t);return e.drag&&e.dragListener!==!1&&(n.draggable=!1,o.userSelect=o.WebkitUserSelect=o.WebkitTouchCallout="none",o.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=o,n}const Qw={offset:"stroke-dashoffset",array:"stroke-dasharray"},Jw={offset:"strokeDashoffset",array:"strokeDasharray"};function eE(e,t,n=1,o=0,r=!0){e.pathLength=1;const s=r?Qw:Jw;e[s.offset]=to.transform(-o);const a=to.transform(t),i=to.transform(n);e[s.array]=`${a} ${i}`}function ip(e,{attrX:t,attrY:n,attrScale:o,pathLength:r,pathSpacing:s=1,pathOffset:a=0,...i},c,u,d){if(Wa(e,i,u),c){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:f,style:p}=e;f.transform&&(p.transform=f.transform,delete f.transform),(p.transform||f.transformOrigin)&&(p.transformOrigin=f.transformOrigin??"50% 50%",delete f.transformOrigin),p.transform&&(p.transformBox=d?.transformBox??"fill-box",delete f.transformBox),t!==void 0&&(f.x=t),n!==void 0&&(f.y=n),o!==void 0&&(f.scale=o),r!==void 0&&eE(f,r,s,a,!1)}const lp=()=>({...Ha(),attrs:{}}),cp=e=>typeof e=="string"&&e.toLowerCase()==="svg";function tE(e,t,n,o){const r=l.useMemo(()=>{const s=lp();return ip(s,t,cp(o),e.transformTemplate,e.style),{...s.attrs,style:{...s.style}}},[t]);if(e.style){const s={};ap(s,e.style,e),r.style={...s,...r.style}}return r}const nE=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function Ua(e){return typeof e!="string"||e.includes("-")?!1:!!(nE.indexOf(e)>-1||/[A-Z]/u.test(e))}function oE(e,t,n,{latestValues:o},r,s=!1){const i=(Ua(e)?tE:Zw)(t,o,r,e),c=Ww(t,typeof e=="string",s),u=e!==l.Fragment?{...c,...i,ref:n}:{},{children:d}=t,f=l.useMemo(()=>Be(d)?d.get():d,[d]);return l.createElement(e,{...u,children:f})}function ll(e){const t=[{},{}];return e?.values.forEach((n,o)=>{t[0][o]=n.get(),t[1][o]=n.getVelocity()}),t}function Ga(e,t,n,o){if(typeof t=="function"){const[r,s]=ll(o);t=t(n!==void 0?n:e.custom,r,s)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[r,s]=ll(o);t=t(n!==void 0?n:e.custom,r,s)}return t}function Ho(e){return Be(e)?e.get():e}function rE({scrapeMotionValuesFromProps:e,createRenderState:t},n,o,r){return{latestValues:sE(n,o,r,e),renderState:t()}}function sE(e,t,n,o){const r={},s=o(e,{});for(const p in s)r[p]=Ho(s[p]);let{initial:a,animate:i}=e;const c=Nr(e),u=rp(e);t&&u&&!c&&e.inherit!==!1&&(a===void 0&&(a=t.initial),i===void 0&&(i=t.animate));let d=n?n.initial===!1:!1;d=d||a===!1;const f=d?i:a;if(f&&typeof f!="boolean"&&!_r(f)){const p=Array.isArray(f)?f:[f];for(let h=0;h<p.length;h++){const m=Ga(e,p[h]);if(m){const{transitionEnd:v,transition:g,...y}=m;for(const b in y){let x=y[b];if(Array.isArray(x)){const S=d?x.length-1:0;x=x[S]}x!==null&&(r[b]=x)}for(const b in v)r[b]=v[b]}}}return r}const up=e=>(t,n)=>{const o=l.useContext(Ar),r=l.useContext(Ir),s=()=>rE(e,t,o,r);return n?s():Qt(s)};function Ya(e,t,n){const{style:o}=e,r={};for(const s in o)(Be(o[s])||t.style&&Be(t.style[s])||sp(s,e)||n?.getValue(s)?.liveStyle!==void 0)&&(r[s]=o[s]);return r}const aE=up({scrapeMotionValuesFromProps:Ya,createRenderState:Ha});function dp(e,t,n){const o=Ya(e,t,n);for(const r in e)if(Be(e[r])||Be(t[r])){const s=ca.indexOf(r)!==-1?"attr"+r.charAt(0).toUpperCase()+r.substring(1):r;o[s]=e[r]}return o}const iE=up({scrapeMotionValuesFromProps:dp,createRenderState:lp}),lE=Symbol.for("motionComponentSymbol");function wn(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function cE(e,t,n){return l.useCallback(o=>{o&&e.onMount&&e.onMount(o),t&&(o?t.mount(o):t.unmount()),n&&(typeof n=="function"?n(o):wn(n)&&(n.current=o))},[t])}const za=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),uE="framerAppearId",fp="data-"+za(uE),pp=l.createContext({});function dE(e,t,n,o,r){const{visualElement:s}=l.useContext(Ar),a=l.useContext(np),i=l.useContext(Ir),c=l.useContext(Or).reducedMotion,u=l.useRef(null);o=o||a.renderer,!u.current&&o&&(u.current=o(e,{visualState:t,parent:s,props:n,presenceContext:i,blockInitialAnimation:i?i.initial===!1:!1,reducedMotionConfig:c}
vendor: 29,461 bytes, line 38
38));const d=u.current,f=l.useContext(pp);d&&!d.projection&&r&&(d.type==="html"||d.type==="svg")&&fE(u.current,n,r,f);const p=l.useRef(!1);l.useInsertionEffect(()=>{d&&p.current&&d.update(n,i)});const h=n[fp],m=l.useRef(!!h&&!window.MotionHandoffIsComplete?.(h)&&window.MotionHasOptimisedAnimation?.(h));return ja(()=>{d&&(p.current=!0,window.MotionIsMounted=!0,d.updateFeatures(),d.scheduleRenderMicrotask(),m.current&&d.animationState&&d.animationState.animateChanges())}),l.useEffect(()=>{d&&(!m.current&&d.animationState&&d.animationState.animateChanges(),m.current&&(queueMicrotask(()=>{window.MotionHandoffMarkAsComplete?.(h)}),m.current=!1),d.enteringChildren=void 0)}),d}function fE(e,t,n,o){const{layoutId:r,layout:s,drag:a,dragConstraints:i,layoutScroll:c,layoutRoot:u,layoutCrossfade:d}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:hp(e.parent)),e.projection.setOptions({layoutId:r,layout:s,alwaysMeasureLayout:!!a||i&&wn(i),visualElement:e,animationType:typeof s=="string"?s:"both",initialPromotionConfig:o,crossfade:d,layoutScroll:c,layoutRoot:u})}function hp(e){if(e)return e.options.allowProjection!==!1?e.projection:hp(e.parent)}function ms(e,{forwardMotionProps:t=!1}={},n,o){n&&jw(n);const r=Ua(e)?iE:aE;function s(i,c){let u;const d={...l.useContext(Or),...i,layoutId:pE(i)},{isStatic:f}=d,p=Uw(i),h=r(i,f);if(!f&&La){hE();const m=mE(d);u=m.MeasureLayout,p.visualElement=dE(e,h,d,o,m.ProjectionNode)}return E.jsxs(Ar.Provider,{value:p,children:[u&&p.visualElement?E.jsx(u,{visualElement:p.visualElement,...d}):null,oE(e,i,cE(h,p.visualElement,c),h,f,t)]})}s.displayName=`motion.${typeof e=="string"?e:`create(${e.displayName??e.name??""})`}`;const a=l.forwardRef(s);return a[lE]=e,a}function pE({layoutId:e}){const t=l.useContext(Fa).id;return t&&e!==void 0?t+"-"+e:e}function hE(e,t){l.useContext(np).strict}function mE(e){const{drag:t,layout:n}=In;if(!t&&!n)return{};const o={...t,...n};return{MeasureLayout:t?.isEnabled(e)||n?.isEnabled(e)?o.MeasureLayout:void 0,ProjectionNode:o.ProjectionNode}}function vE(e,t){if(typeof Proxy>"u")return ms;const n=new Map,o=(s,a)=>ms(s,a,e,t),r=(s,a)=>o(s,a);return new Proxy(r,{get:(s,a)=>a==="create"?o:(n.has(a)||n.set(a,ms(a,void 0,e,t)),n.get(a))})}function mp({top:e,left:t,right:n,bottom:o}){return{x:{min:t,max:n},y:{min:e,max:o}}}function gE({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function yE(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),o=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:o.y,right:o.x}}function vs(e){return e===void 0||e===1}function qs({scale:e,scaleX:t,scaleY:n}){return!vs(e)||!vs(t)||!vs(n)}function rn(e){return qs(e)||vp(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function vp(e){return cl(e.x)||cl(e.y)}function cl(e){return e&&e!=="0%"}function tr(e,t,n){const o=e-n,r=t*o;return n+r}function ul(e,t,n,o,r){return r!==void 0&&(e=tr(e,r,o)),tr(e,n,o)+t}function Xs(e,t=0,n=1,o,r){e.min=ul(e.min,t,n,o,r),e.max=ul(e.max,t,n,o,r)}function gp(e,{x:t,y:n}){Xs(e.x,t.translate,t.scale,t.originPoint),Xs(e.y,n.translate,n.scale,n.originPoint)}const dl=.999999999999,fl=1.0000000000001;function bE(e,t,n,o=!1){const r=n.length;if(!r)return;t.x=t.y=1;let s,a;for(let i=0;i<r;i++){s=n[i],a=s.projectionDelta;const{visualElement:c}=s.options;c&&c.props.style&&c.props.style.display==="contents"||(o&&s.options.layoutScroll&&s.scroll&&s!==s.root&&Cn(e,{x:-s.scroll.offset.x,y:-s.scroll.offset.y}),a&&(t.x*=a.x.scale,t.y*=a.y.scale,gp(e,a)),o&&rn(s.latestValues)&&Cn(e,s.latestValues))}t.x<fl&&t.x>dl&&(t.x=1),t.y<fl&&t.y>dl&&(t.y=1)}function En(e,t){e.min=e.min+t,e.max=e.max+t}function pl(e,t,n,o,r=.5){const s=Ie(e.min,e.max,r);Xs(e,t,n,s,o)}function Cn(e,t){pl(e.x,t.x,t.scaleX,t.scale,t.originX),pl(e.y,t.y,t.scaleY,t.scale,t.originY)}function yp(e,t){return mp(yE(e.getBoundingClientRect(),t))}function xE(e,t,n){const o=yp(e,n),{scroll:r}=t;return r&&(En(o.x,r.offset.x),En(o.y,r.offset.y)),o}const hl=()=>({translate:0,scale:1,origin:0,originPoint:0}),Sn=()=>({x:hl(),y:hl()}),ml=()=>({min:0,max:0}),Oe=()=>({x:ml(),y:ml()}),nr={current:null},Ka={current:!1};function bp(){if(Ka.current=!0,!!La)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>nr.current=e.matches;e.addEventListener("change",t),t()}else nr.current=!1}const wE=new WeakMap;function EE(e,t,n){for(const o in t){const r=t[o],s=n[o];if(Be(r))e.addValue(o,r);else if(Be(s))e.addValue(o,cn(r,{owner:e}));else if(s!==r)if(e.hasValue(o)){const a=e.getValue(o);a.liveStyle===!0?a.jump(r):a.hasAnimated||a.set(r)}else{const a=e.getStaticValue(o);e.addValue(o,cn(a!==void 0?a:r,{owner:e}))}}for(const o in n)t[o]===void 0&&e.removeValue(o);return t}const vl=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class CE{scrapeMotionValuesFromProps(t,n,o){return{}}constructor({parent:t,props:n,presenceContext:o,reducedMotionConfig:r,blockInitialAnimation:s,visualState:a},i={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=rm,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const p=ua.now();this.renderScheduledAt<p&&(this.renderScheduledAt=p,ke.render(this.render,!1,!0))};const{latestValues:c,renderState:u}=a;this.latestValues=c,this.baseTarget={...c},this.initialValues=n.initial?{...c}:{},this.renderState=u,this.parent=t,this.props=n,this.presenceContext=o,this.depth=t?t.depth+1:0,this.reducedMotionConfig=r,this.options=i,this.blockInitialAnimation=!!s,this.isControllingVariants=Nr(n),this.isVariantNode=rp(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:d,...f}=this.scrapeMotionValuesFromProps(n,{},this);for(const p in f){const h=f[p];c[p]!==void 0&&Be(h)&&h.set(c[p])}}mount(t){this.current=t,wE.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((n,o)=>this.bindToMotionValue(o,n)),Ka.current||bp(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:nr.current,this.parent?.addChild(this),this.update(this.props,this.presenceContext)}unmount(){this.projection&&this.projection.unmount(),Gt(this.notifyUpdate),Gt(this.render),this.valueSubscriptions.forEach(t=>t()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent?.removeChild(this);for(const t in this.events)this.events[t].clear();for(const t in this.features){const n=this.features[t];n&&(n.unmount(),n.isMounted=!1)}this.current=null}addChild(t){this.children.add(t),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(t)}removeChild(t){this.children.delete(t),this.enteringChildren&&this.enteringChildren.delete(t)}bindToMotionValue(t,n){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();const o=An.has(t);o&&this.onBindTransform&&this.onBindTransform();const r=n.on("change",a=>{this.latestValues[t]=a,this.props.onUpdate&&ke.preRender(this.notifyUpdate),o&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let s;window.MotionCheckAppearSync&&(s=window.MotionCheckAppearSync(this,t,n)),this.valueSubscriptions.set(t,()=>{r(),s&&s(),n.owner&&n.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in In){const n=In[t];if(!n)continue;const{isEnabled:o,Feature:r}=n;if(!this.features[t]&&r&&o(this.props)&&(this.features[t]=new r(this)),this.features[t]){const s=this.features[t];s.isMounted?s.update():(s.mount(),s.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):Oe()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let o=0;o<vl.length;o++){const r=vl[o];this.propEventSubscriptions[r]&&(this.propEventSubscriptions[r](),delete this.propEventSubscriptions[r]);const s="on"+r,a=t[s];a&&(this.propEventSubscriptions[r]=this.on(r,a))}this.prevMotionValues=EE(this,this.scrapeMotionValuesFromProps(t,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(t){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(t),()=>n.variantChildren.delete(t)}addValue(t,n){const o=this.values.get(t);n!==o&&(o&&this.removeValue(t),this.bindToMotionValue(t,n),this.values.set(t,n),this.latestValues[t]=n.get())}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let o=this.values.get(t);return o===void 0&&n!==void 0&&(o=cn(n===null?void 0:n,{owner:this}),this.addValue(t,o)),o}readValue(t,n){let o=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options);return o!=null&&(typeof o=="string"&&(sm(o)||am(o))?o=parseFloat(o):!im(o)&&_s.test(n)&&(o=lm(t,n)),this.setBaseTarget(t,Be(o)?o.get():o)),Be(o)?o.get():o}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){const{initial:n}=this.props;let o;if(typeof n=="string"||typeof n=="object"){const s=Ga(this.props,n,this.presenceContext?.custom);s&&(o=s[t])}if(n&&o!==void 0)return o;const r=this.getBaseTargetFromProps(this.props,t);return r!==void 0&&!Be(r)?r:this.initialValues[t]!==void 0&&o===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new Ic),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}scheduleRenderMicrotask(){da.render(this.render)}}class xp extends CE{constructor(){super(...arguments),this.KeyframeResolver=cm}sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){return t.style?t.style[n]:void 0}removeValueFromRenderState(t,{vars:n,style:o}){delete n[t],delete o[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;Be(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}function wp(e,{style:t,vars:n},o,r){const s=e.style;let a;for(a in t)s[a]=t[a];r?.applyProjectionStyles(s,o);for(a in n)s.setProperty(a,n[a])}function SE(e){return window.getComputedStyle(e)}class PE extends xp{constructor(){super(...arguments),this.type="html",this.renderInstance=wp}readValueFromInstance(t,n){if(An.has(n))return this.projection?.isProjecting?um(n):dm(t,n);{const o=SE(t),r=(la(n)?o.getPropertyValue(n):o[n])||0;return typeof r=="string"?r.trim():r}}measureInstanceViewportBox(t,{transformPagePoint:n}){return yp(t,n)}build(t,n,o){Wa(t,n,o.transformTemplate)}scrapeMotionValuesFromProps(t,n,o){return Ya(t,n,o)}}const Ep=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function ME(e,t,n,o){wp(e,t,void 0,o);for(const r in t.attrs)e.setAttribute(Ep.has(r)?r:za(r),t.attrs[r])}class TE extends xp{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=Oe}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(An.has(n)){const o=fm(n);return o&&o.default||0}return n=Ep.has(n)?n:za(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,o){return dp(t,n,o)}build(t,n,o){ip(t,n,this.isSVGTag,o.transformTemplate,o.style)}renderInstance(t,n,o,r){ME(t,n,o,r)}mount(t){this.isSVGTag=cp(t.tagName),super.mount(t)}}const kE=(e,t)=>Ua(e)?new TE(t):new PE(t,{allowProjection:e!==l.Fragment});function Tn(e,t,n){const o=e.getProps();return Ga(o,t,n!==void 0?n:o.custom,e)}const Zs=e=>Array.isArray(e);function RE(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,cn(n))}function DE(e){return Zs(e)?e[e.length-1]||0:e}function IE(e,t){const n=Tn(e,t);let{transitionEnd:o={},transition:r={},...s}=n||{};s={...s,...o};for(const a in s){const i=DE(s[a]);RE(e,a,i)}}function OE(e){return!!(Be(e)&&e.add)}function Qs(e,t){const n=e.getValue("willChange");if(OE(n))return n.add(t);if(!n&&Go.WillChange){const o=new Go.WillChange("auto");e.addValue("willChange",o),o.add(t)}}function Cp(e){return e.props[fp]}const AE=e=>e!==null;function _E(e,{repeat:t,repeatType:n="loop"},o){const r=e.filter(AE),s=t&&n!=="loop"&&t%2===1?0:r.length-1;return r[s]}const NE={type:"spring",stiffness:500,damping:25,restSpeed:10},$E=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),FE={type:"keyframes",duration:.8},LE={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},jE=(e,{keyframes:t})=>t.length>2?FE:An.has(e)?e.startsWith("scale")?$E(t[1]):NE:LE;function BE({when:e,delay:t,delayChildren:n,staggerChildren:o,staggerDirection:r,repeat:s,repeatType:a,repeatDelay:i,from:c,elapsed:u,...d}){return!!Object.keys(d).length}const qa=(e,t,n,o={},r,s)=>a=>{const i=fa(o,e)||{},c=i.delay||o.delay||0;let{elapsed:u=0}=o;u=u-Wo(c);const d={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...i,delay:-u,onUpdate:p=>{t.set(p),i.onUpdate&&i.onUpdate(p)},onComplete:()=>{a(),i.onComplete&&i.onComplete()},name:e,motionValue:t,element:s?void 0:r};BE(i)||Object.assign(d,jE(e,d)),d.duration&&(d.duration=Wo(d.duration)),d.repeatDelay&&(d.repeatDelay=Wo(d.repeatDelay)),d.from!==void 0&&(d.keyframes[0]=d.from);let f=!1;if((d.type===!1||d.duration===0&&!d.repeatDelay)&&(Fi(d),d.delay===0&&(f=!0)),(Go.instantAnimations||Go.skipAnimations)&&(f=!0,Fi(d),d.delay=0),d.allowFlatten=!i.type&&!i.ease,f&&!s&&t.get()!==void 0){const p=_E(d.keyframes,i);if(p!==void 0){ke.update(()=>{d.onUpdate(p),d.onComplete()});return}}return i.isSync?new pm(d):new hm(d)};function VE({protectedKeys:e,needsAnimating:t},n){const o=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,o}function Sp(e,t,{delay:n=0,transitionOverride:o,type:r}={}){let{transition:s=e.getDefaultTransition(),transitionEnd:a,...i}=t;o&&(s=o);const c=[],u=r&&e.animationState&&e.animationState.getState()[r];for(const d in i){const f=e.getValue(d,e.latestValues[d]??null),p=i[d];if(p===void 0||u&&VE(u,d))continue;const h={delay:n,...fa(s||{},d)},m=f.get();if(m!==void 0&&!f.isAnimating&&!Array.isArray(p)&&p===m&&!h.velocity)continue;let v=!1;if(window.MotionHandoffAnimation){const y=Cp(e);if(y){const b=window.MotionHandoffAnimation(y,d,ke);b!==null&&(h.startTime=b,v=!0)}}Qs(e,d),f.start(qa(d,f,p,e.shouldReduceMotion&&mm.has(d)?{type:!1}:h,e,v));const g=f.animation;g&&c.push(g)}return a&&Promise.all(c).then(()=>{ke.update(()=>{a&&IE(e,a)})}),c}function Pp(e,t,n,o=0,r=1){const s=Array.from(e).sort((u,d)=>u.sortNodePosition(d)).indexOf(t),a=e.size,i=(a-1)*o;return typeof n=="function"?n(s,a):r===1?s*o:i-s*o}function Js(e,t,n={}){const o=Tn(e,t,n.type==="exit"?e.presenceContext?.custom:void 0);let{transition:r=e.getDefaultTransition()||{}}=o||{};n.transitionOverride&&(r=n.transitionOverride);const s=o?()=>Promise.all(Sp(e,o,n)):()=>Promise.resolve(),a=e.variantChildren&&e.variantChildren.size?(c=0)=>{const{delayChildren:u=0,staggerChildren:d,staggerDirection:f}=r;return WE(e,t,c,u,d,f,n)}:()=>Promise.resolve(),{when:i}=r;if(i){const[c,u]=i==="beforeChildren"?[s,a]:[a,s];return c().then(()=>u())}else return Promise.all([s(),a(n.delay)])}function WE(e,t,n=0,o=0,r=0,s=1,a){const i=[];for(const c of e.variantChildren)c.notify("AnimationStart",t),i.push(Js(c,t,{...a,delay:n+(typeof o=="function"?0:o)+Pp(e.variantChildren,c,o,r,s)}).then(()=>c.notify("AnimationComplete",t)));return Promise.all(i)}function HE(e,t,n={}){e.notify("AnimationStart",t);let o;if(Array.isArray(t)){const r=t.map(s=>Js(e,s,n));o=Promise.all(r)}else if(typeof t=="string")o=Js(e,t,n);else{const r=typeof t=="function"?Tn(e,t,n.custom):t;o=Promise.all(Sp(e,r,n))}return o.then(()=>{e.notify("AnimationComplete",t)})}function Mp(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let o=0;o<n;o++)if(t[o]!==e[o])return!1;return!0}const UE=Va.length;function Tp(e){if(!e)return;if(!e.isControllingVariants){const n=e.parent?Tp(e.parent)||{}:{};return e.props.initial!==void 0&&(n.initial=e.props.initial),n}const t={};for(let n=0;n<UE;n++){const o=Va[n],r=e.props[o];(co(r)||r===!1)&&(t[o]=r)}return t}const GE=[...Ba].reverse(),YE=Ba.length;function zE(e){return t=>Promise.all(t.map(({animation:n,options:o})=>HE(e,n,o)))}function KE(e){let t=zE(e),n=gl(),o=!0;const r=c=>(u,d)=>{const f=Tn(e,d,c==="exit"?e.presenceContext?.custom:void 0);if(f){const{transition:p,transitionEnd:h,...m}=f;u={...u,...m,...h}}return u};function s(c){t=c(e)}function a(c){const{props:u}=e,d=Tp(e.parent)||{},f=[],p=new Set;let h={},m=1/0;for(let g=0;g<YE;g++){const y=GE[g],b=n[y],x=u[y]!==void 0?u[y]:d[y],S=co(x),T=y===c?b.isActive:null;T===!1&&(m=g);let C=x===d[y]&&x!==u[y]&&S;if(C&&o&&e.manuallyAnimateOnMount&&(C=!1),b.protectedKeys={...h},!b.isActive&&T===null||!x&&!b.prevProp||_r(x)||typeof x=="boolean")continue;const P=qE(b.prevProp,x);let _=P||y===c&&b.isActive&&!C&&S||g>m&&S,O=!1;const I=Array.isArray(x)?x:[x];let $=I.reduce(r(y),{});T===!1&&($={});const{prevResolvedValues:G={}}=b,W={...G,...$},B=U=>{_=!0,p.has(U)&&(O=!0,p.delete(U)),b.needsAnimating[U]=!0;const q=e.getValue(U);q&&(q.liveStyle=!1)};for(const U in W){const q=$[U],R=G[U];if(h.hasOwnProperty(U))continue;let D=!1;Zs(q)&&Zs(R)?D=!Mp(q,R):D=q!==R,D?q!=null?B(U):p.add(U):q!==void 0&&p.has(U)?B(U):b.protectedKeys[U]=!0}b.prevProp=x,b.prevResolvedValues=$,b.isActive&&(h={...h,...$}),o&&e.blockInitialAnimation&&(_=!1);const K=C&&P;_&&(!K||O)&&f.push(...I.map(U=>{const q={type:y};if(typeof U=="string"&&o&&!K&&e.manuallyAnimateOnMount&&e.parent){const{parent:R}=e,D=Tn(R,U);if(R.enteringChildren&&D){const{delayChildren:L}=D.transition||{};q.delay=Pp(R.enteringChildren,e,L)}}return{animation:U,options:q}}))}if(p.size){const g={};if(typeof u.initial!="boolean"){const y=Tn(e,Array.isArray(u.initial)?u.initial[0]:u.initial);y&&y.transition&&(g.transition=y.transition)}p.forEach(y=>{const b=e.getBaseTarget(y),x=e.getValue(y);x&&(x.liveStyle=!0),g[y]=b??null}),f.push({animation:g})}let v=!!f.length;return o&&(u.initial===!1||u.initial===u.animate)&&!e.manuallyAnimateOnMount&&(v=!1),o=!1,v?t(f):Promise.resolve()}function i(c,u){if(n[c].isActive===u)return Promise.resolve();e.variantChildren?.forEach(f=>f.animationState?.setActive(c,u)),n[c].isActive=u;const d=a(c);for(const f in n)n[f].protectedKeys={};return d}return{animateChanges:a,setActive:i,setAnimateFunction:s,getState:()=>n,reset:()=>{n=gl()}}}function qE(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!Mp(t,e):!1}function on(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function gl(){return{animate:on(!0),whileInView:on(),whileHover:on(),whileTap:on(),whileDrag:on(),whileFocus:on(),exit:on()}}class Jt{constructor(t){this.isMounted=!1,this.node=t}update(){}}class XE extends Jt{constructor(t){super(t),t.animationState||(t.animationState=KE(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();_r(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){this.node.animationState.reset(),this.unmountControls?.()}}let ZE=0;class QE extends Jt{constructor(){super(...arguments),this.id=ZE++}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n}=this.node.presenceContext,{isPresent:o}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===o)return;const r=this.node.animationState.setActive("exit",!t);n&&!t&&r.then(()=>{n(this.id)})}mount(){const{register:t,onExitComplete:n}=this.node.presenceContext||{};n&&n(this.id),t&&(this.unmount=t(this.id))}unmount(){}}const JE={animation:{Feature:XE},exit:{Feature:QE}};function fo(e,t,n,o={passive:!0}){return e.addEventListener(t,n,o),()=>e.removeEventListener(t,n)}function Co(e){return{point:{x:e.pageX,y:e.pageY}}}const eC=e=>t=>Oc(t)&&e(t,Co(t));function no(e,t,n,o){return fo(e,t,eC(n),o)}const kp=1e-4,tC=1-kp,nC=1+kp,Rp=.01,oC=0-Rp,rC=0+Rp;function Ge(e){return e.max-e.min}function sC(e,t,n){return Math.abs(e-t)<=n}function yl(e,t,n,o=.5){e.origin=o,e.originPoint=Ie(t.min,t.max,e.origin),e.scale=Ge(n)/Ge(t),e.translate=Ie(n.min,n.max,e.origin)-e.originPoint,(e.scale>=tC&&e.scale<=nC||isNaN(e.scale))&&(e.scale=1),(e.translate>=oC&&e.translate<=rC||isNaN(e.translate))&&(e.translate=0)}function oo(e,t,n,o){yl(e.x,t.x,n.x,o?o.originX:void 0),yl(e.y,t.y,n.y,o?o.originY:void 0)}function bl(e,t,n){e.min=n.min+t.min,e.max=e.min+Ge(t)}function aC(e,t,n){bl(e.x,t.x,n.x),bl(e.y,t.y,n.y)}function xl(e,t,n){e.min=t.min-n.min,e.max=e.min+Ge(t)}function or(e,t,n){xl(e.x,t.x,n.x),xl(e.y,t.y,n.y)}function at(e){return[e("x"),e("y")]}const Dp=({current:e})=>e?e.ownerDocument.defaultView:null,wl=(e,t)=>Math.abs(e-t);function iC(e,t){const n=wl(e.x,t.x),o=wl(e.y,t.y);return Math.sqrt(n**2+o**2)}class Ip{constructor(t,n,{transformPagePoint:o,contextWindow:r=window,dragSnapToOrigin:s=!1,distanceThreshold:a=3}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const p=ys(this.lastMoveEventInfo,this.history),h=this.startEvent!==null,m=iC(p.offset,{x:0,y:0})>=this.distanceThreshold;if(!h&&!m)return;const{point:v}=p,{timestamp:g}=Je;this.history.push({...v,timestamp:g});const{onStart:y,onMove:b}=this.handlers;h||(y&&y(this.lastMoveEvent,p),this.startEvent=this.lastMoveEvent),b&&b(this.lastMoveEvent,p)},this.handlePointerMove=(p,h)=>{this.lastMoveEvent=p,this.lastMoveEventInfo=gs(h,this.transformPagePoint),ke.update(this.updatePoint,!0)},this.handlePointerUp=(p,h)=>{this.end();const{onEnd:m,onSessionEnd:v,resumeAnimation:g}=this.handlers;if(this.dragSnapToOrigin&&g&&g(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const y=ys(p.type==="pointercancel"?this.lastMoveEventInfo:gs(h,this.transformPagePoint),this.history);this.startEvent&&m&&m(p,y),v&&v(p,y)},!Oc(t))return;this.dragSnapToOrigin=s,this.handlers=n,this.transformPagePoint=o,this.distanceThreshold=a,this.contextWindow=r||window;const i=Co(t),c=gs(i,this.transformPagePoint),{point:u}=c,{timestamp:d}=Je;this.history=[{...u,timestamp:d}];const{onSessionStart:f}=n;f&&f(t,ys(c,this.history)),this.removeListeners=Ac(no(this.contextWindow,"pointermove",this.handlePointerMove),no(this.contextWindow,"pointerup",this.handlePointerUp),no(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),Gt(this.updatePoint)}}function gs(e,t){return t?{point:t(e.point)}:e}function El(e,t){return{x:e.x-t.x,y:e.y-t.y}}function ys({point:e},t){return{point:e,delta:El(e,Op(t)),offset:El(e,lC(t)),velocity:cC(t,.1)}}function lC(e){return e[0]}function Op(e){return e[e.length-1]}function cC(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,o=null;const r=Op(e);for(;n>=0&&(o=e[n],!(r.timestamp-o.timestamp>Wo(t)));)n--;if(!o)return{x:0,y:0};const s=vm(r.timestamp-o.timestamp);if(s===0)return{x:0,y:0};const a={x:(r.x-o.x)/s,y:(r.y-o.y)/s};return a.x===1/0&&(a.x=0),a.y===1/0&&(a.y=0),a}function uC(e,{min:t,max:n},o){return t!==void 0&&e<t?e=o?Ie(t,e,o.min):Math.max(e,t):n!==void 0&&e>n&&(e=o?Ie(n,e,o.max):Math.min(e,n)),e}function Cl(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function dC(e,{top:t,left:n,bottom:o,right:r}){return{x:Cl(e.x,n,r),y:Cl(e.y,t,o)}}function Sl(e,t){let n=t.min-e.min,o=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,o]=[o,n]),{min:n,max:o}}function fC(e,t){return{x:Sl(e.x,t.x),y:Sl(e.y,t.y)}}function pC(e,t){let n=.5;const o=Ge(e),r=Ge(t);return r>o?n=Ns(t.min,t.max-o,e.min):o>r&&(n=Ns(e.min,e.max-r,t.min)),_c(0,1,n)}function hC(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const ea=.35;function mC(e=ea){return e===!1?e=0:e===!0&&(e=ea),{x:Pl(e,"left","right"),y:Pl(e,"top","bottom")}}function Pl(e,t,n){return{min:Ml(e,t),max:Ml(e,n)}}function Ml(e,t){return typeof e=="number"?e:e[t]||0}const vC=new WeakMap;class gC{constructor(t){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=Oe(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=t}start(t,{snapToCursor:n=!1,distanceThreshold:o}={}){const{presenceContext:r}=this.visualElement;if(r&&r.isPresent===!1)return;const s=f=>{const{dragSnapToOrigin:p}=this.getProps();p?this.pauseAnimation():this.stopAnimation(),n&&this.snapToCursor(Co(f).point)},a=(f,p)=>{const{drag:h,dragPropagation:m,onDragStart:v}=this.getProps();if(h&&!m&&(this.openDragLock&&this.openDragLock(),this.openDragLock=gm(h),!this.openDragLock))return;this.latestPointerEvent=f,this.latestPanInfo=p,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),at(y=>{let b=this.getAxisMotionValue(y).get()||0;if(Yo.test(b)){const{projection:x}=this.visualElement;if(x&&x.layout){const S=x.layout.layoutBox[y];S&&(b=Ge(S)*(parseFloat(b)/100))}}this.originPoint[y]=b}),v&&ke.postRender(()=>v(f,p)),Qs(this.visualElement,"transform");const{animationState:g}=this.visualElement;g&&g.setActive("whileDrag",!0)},i=(f,p)=>{this.latestPointerEvent=f,this.latestPanInfo=p;const{dragPropagation:h,dragDirectionLock:m,onDirectionLock:v,onDrag:g}=this.getProps();if(!h&&!this.openDragLock)return;const{offset:y}=p;if(m&&this.currentDirection===null){this.currentDirection=yC(y),this.currentDirection!==null&&v&&v(this.currentDirection);return}this.updateAxis("x",p.point,y),this.updateAxis("y",p.point,y),this.visualElement.render(),g&&g(f,p)},c=(f,p)=>{this.latestPointerEvent=f,this.latestPanInfo=p,this.stop(f,p),this.latestPointerEvent=null,this.latestPanInfo=null},u=()=>at(f=>this.getAnimationState(f)==="paused"&&this.getAxisMotionValue(f).animation?.play()),{dragSnapToOrigin:d}=this.getProps();this.panSession=new Ip(t,{onSessionStart:s,onStart:a,onMove:i,onSessionEnd:c,resumeAnimation:u},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:d,distanceThreshold:o,contextWindow:Dp(this.visualElement)})}stop(t,n){const o=t||this.latestPointerEvent,r=n||this.latestPanInfo,s=this.isDragging;if(this.cancel(),!s||!r||!o)return;const{velocity:a}=r;this.startAnimation(a);const{onDragEnd:i}=this.getProps();i&&ke.postRender(()=>i(o,r))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:o}=this.getProps();!o&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",!1)}updateAxis(t,n,o){const{drag:r}=this.getProps();if(!o||!Bo(t,r,this.currentDirection))return;const s=this.getAxisMotionValue(t);let a=this.originPoint[t]+o[t];this.constraints&&this.constraints[t]&&(a=uC(a,this.constraints[t],this.elastic[t])),s.set(a)}resolveConstraints(){const{dragConstraints:t,dragElastic:n}=this.getProps(),o=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):this.visualElement.projection?.layout,r=this.constraints;t&&wn(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&o?this.constraints=dC(o.layoutBox,t):this.constraints=!1,this.elastic=mC(n),r!==this.constraints&&o&&this.constraints&&!this.hasMutatedConstraints&&at(s=>{this.constraints!==!1&&this.getAxisMotionValue(s)&&(this.constraints[s]=hC(o.layoutBox[s],this.constraints[s])
vendor: 10,039 bytes, line 38
38)})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!wn(t))return!1;const o=t.current,{projection:r}=this.visualElement;if(!r||!r.layout)return!1;const s=xE(o,r.root,this.visualElement.getTransformPagePoint());let a=fC(r.layout.layoutBox,s);if(n){const i=n(gE(a));this.hasMutatedConstraints=!!i,i&&(a=mp(i))}return a}startAnimation(t){const{drag:n,dragMomentum:o,dragElastic:r,dragTransition:s,dragSnapToOrigin:a,onDragTransitionEnd:i}=this.getProps(),c=this.constraints||{},u=at(d=>{if(!Bo(d,n,this.currentDirection))return;let f=c&&c[d]||{};a&&(f={min:0,max:0});const p=r?200:1e6,h=r?40:1e7,m={type:"inertia",velocity:o?t[d]:0,bounceStiffness:p,bounceDamping:h,timeConstant:750,restDelta:1,restSpeed:10,...s,...f};return this.startAxisValueAnimation(d,m)});return Promise.all(u).then(i)}startAxisValueAnimation(t,n){const o=this.getAxisMotionValue(t);return Qs(this.visualElement,t),o.start(qa(t,o,0,n,this.visualElement,!1))}stopAnimation(){at(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){at(t=>this.getAxisMotionValue(t).animation?.pause())}getAnimationState(t){return this.getAxisMotionValue(t).animation?.state}getAxisMotionValue(t){const n=`_drag${t.toUpperCase()}`,o=this.visualElement.getProps(),r=o[n];return r||this.visualElement.getValue(t,(o.initial?o.initial[t]:void 0)||0)}snapToCursor(t){at(n=>{const{drag:o}=this.getProps();if(!Bo(n,o,this.currentDirection))return;const{projection:r}=this.visualElement,s=this.getAxisMotionValue(n);if(r&&r.layout){const{min:a,max:i}=r.layout.layoutBox[n];s.set(t[n]-Ie(a,i,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:o}=this.visualElement;if(!wn(n)||!o||!this.constraints)return;this.stopAnimation();const r={x:0,y:0};at(a=>{const i=this.getAxisMotionValue(a);if(i&&this.constraints!==!1){const c=i.get();r[a]=pC({min:c,max:c},this.constraints[a])}});const{transformTemplate:s}=this.visualElement.getProps();this.visualElement.current.style.transform=s?s({},""):"none",o.root&&o.root.updateScroll(),o.updateLayout(),this.resolveConstraints(),at(a=>{if(!Bo(a,t,null))return;const i=this.getAxisMotionValue(a),{min:c,max:u}=this.constraints[a];i.set(Ie(c,u,r[a]))})}addListeners(){if(!this.visualElement.current)return;vC.set(this.visualElement,this);const t=this.visualElement.current,n=no(t,"pointerdown",c=>{const{drag:u,dragListener:d=!0}=this.getProps();u&&d&&this.start(c)}),o=()=>{const{dragConstraints:c}=this.getProps();wn(c)&&c.current&&(this.constraints=this.resolveRefConstraints())},{projection:r}=this.visualElement,s=r.addEventListener("measure",o);r&&!r.layout&&(r.root&&r.root.updateScroll(),r.updateLayout()),ke.read(o);const a=fo(window,"resize",()=>this.scalePositionWithinConstraints()),i=r.addEventListener("didUpdate",(({delta:c,hasLayoutChanged:u})=>{this.isDragging&&u&&(at(d=>{const f=this.getAxisMotionValue(d);f&&(this.originPoint[d]+=c[d].translate,f.set(f.get()+c[d].translate))}),this.visualElement.render())}));return()=>{a(),n(),s(),i&&i()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:o=!1,dragPropagation:r=!1,dragConstraints:s=!1,dragElastic:a=ea,dragMomentum:i=!0}=t;return{...t,drag:n,dragDirectionLock:o,dragPropagation:r,dragConstraints:s,dragElastic:a,dragMomentum:i}}}function Bo(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function yC(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class bC extends Jt{constructor(t){super(t),this.removeGroupControls=Pn,this.removeListeners=Pn,this.controls=new gC(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Pn}unmount(){this.removeGroupControls(),this.removeListeners()}}const Tl=e=>(t,n)=>{e&&ke.postRender(()=>e(t,n))};class xC extends Jt{constructor(){super(...arguments),this.removePointerDownListener=Pn}onPointerDown(t){this.session=new Ip(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:Dp(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:o,onPanEnd:r}=this.node.getProps();return{onSessionStart:Tl(t),onStart:Tl(n),onMove:o,onEnd:(s,a)=>{delete this.session,r&&ke.postRender(()=>r(s,a))}}}mount(){this.removePointerDownListener=no(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}const Uo={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function kl(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const Xn={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(to.test(e))e=parseFloat(e);else return e;const n=kl(e,t.target.x),o=kl(e,t.target.y);return`${n}% ${o}%`}},wC={correct:(e,{treeScale:t,projectionDelta:n})=>{const o=e,r=_s.parse(e);if(r.length>5)return o;const s=_s.createTransformer(e),a=typeof r[0]!="number"?1:0,i=n.x.scale*t.x,c=n.y.scale*t.y;r[0+a]/=i,r[1+a]/=c;const u=Ie(i,c,.5);return typeof r[2+a]=="number"&&(r[2+a]/=u),typeof r[3+a]=="number"&&(r[3+a]/=u),s(r)}};let bs=!1;class EC extends l.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:o,layoutId:r}=this.props,{projection:s}=t;Gw(CC),s&&(n.group&&n.group.add(s),o&&o.register&&r&&o.register(s),bs&&s.root.didUpdate(),s.addEventListener("animationComplete",()=>{this.safeToRemove()}),s.setOptions({...s.options,onExitComplete:()=>this.safeToRemove()})),Uo.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:o,drag:r,isPresent:s}=this.props,{projection:a}=o;return a&&(a.isPresent=s,bs=!0,r||t.layoutDependency!==n||n===void 0||t.isPresent!==s?a.willUpdate():this.safeToRemove(),t.isPresent!==s&&(s?a.promote():a.relegate()||ke.postRender(()=>{const i=a.getStack();(!i||!i.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),da.postRender(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:o}=this.props,{projection:r}=t;bs=!0,r&&(r.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(r),o&&o.deregister&&o.deregister(r))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function Ap(e){const[t,n]=tp(),o=l.useContext(Fa);return E.jsx(EC,{...e,layoutGroup:o,switchLayoutGroup:l.useContext(pp),isPresent:t,safeToRemove:n})}const CC={borderRadius:{...Xn,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:Xn,borderTopRightRadius:Xn,borderBottomLeftRadius:Xn,borderBottomRightRadius:Xn,boxShadow:wC};function SC(e,t,n){const o=Be(e)?e:cn(e);return o.start(qa("",o,t,n)),o.animation}const PC=(e,t)=>e.depth-t.depth;class MC{constructor(){this.children=[],this.isDirty=!1}add(t){Nc(this.children,t),this.isDirty=!0}remove(t){$c(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(PC),this.isDirty=!1,this.children.forEach(t)}}function TC(e,t){const n=ua.now(),o=({timestamp:r})=>{const s=r-n;s>=t&&(Gt(o),e(s-t))};return ke.setup(o,!0),()=>Gt(o)}const _p=["TopLeft","TopRight","BottomLeft","BottomRight"],kC=_p.length,Rl=e=>typeof e=="string"?parseFloat(e):e,Dl=e=>typeof e=="number"||to.test(e);function RC(e,t,n,o,r,s){r?(e.opacity=Ie(0,n.opacity??1,DC(o)),e.opacityExit=Ie(t.opacity??1,0,IC(o))):s&&(e.opacity=Ie(t.opacity??1,n.opacity??1,o));for(let a=0;a<kC;a++){const i=`border${_p[a]}Radius`;let c=Il(t,i),u=Il(n,i);if(c===void 0&&u===void 0)continue;c||(c=0),u||(u=0),c===0||u===0||Dl(c)===Dl(u)?(e[i]=Math.max(Ie(Rl(c),Rl(u),o),0),(Yo.test(u)||Yo.test(c))&&(e[i]+="%")):e[i]=u}(t.rotate||n.rotate)&&(e.rotate=Ie(t.rotate||0,n.rotate||0,o))}function Il(e,t){return e[t]!==void 0?e[t]:e.borderRadius}const DC=Np(0,.5,ym),IC=Np(.5,.95,Pn);function Np(e,t,n){return o=>o<e?0:o>t?1:n(Ns(e,t,o))}function Ol(e,t){e.min=t.min,e.max=t.max}function ft(e,t){Ol(e.x,t.x),Ol(e.y,t.y)}function Al(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function _l(e,t,n,o,r){return e-=t,e=tr(e,1/n,o),r!==void 0&&(e=tr(e,1/r,o)),e}function OC(e,t=0,n=1,o=.5,r,s=e,a=e){if(Yo.test(t)&&(t=parseFloat(t),t=Ie(a.min,a.max,t/100)-a.min),typeof t!="number")return;let i=Ie(s.min,s.max,o);e===s&&(i-=t),e.min=_l(e.min,t,n,i,r),e.max=_l(e.max,t,n,i,r)}function Nl(e,t,[n,o,r],s,a){OC(e,t[n],t[o],t[r],t.scale,s,a)}const AC=["x","scaleX","originX"],_C=["y","scaleY","originY"];function $l(e,t,n,o){Nl(e.x,t,AC,n?n.x:void 0,o?o.x:void 0),Nl(e.y,t,_C,n?n.y:void 0,o?o.y:void 0)}function Fl(e){return e.translate===0&&e.scale===1}function $p(e){return Fl(e.x)&&Fl(e.y)}function Ll(e,t){return e.min===t.min&&e.max===t.max}function NC(e,t){return Ll(e.x,t.x)&&Ll(e.y,t.y)}function jl(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function Fp(e,t){return jl(e.x,t.x)&&jl(e.y,t.y)}function Bl(e){return Ge(e.x)/Ge(e.y)}function Vl(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}class $C{constructor(){this.members=[]}add(t){Nc(this.members,t),t.scheduleRender()}remove(t){if($c(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){const n=this.members.findIndex(r=>t===r);if(n===0)return!1;let o;for(let r=n;r>=0;r--){const s=this.members[r];if(s.isPresent!==!1){o=s;break}}return o?(this.promote(o),!0):!1}promote(t,n){const o=this.lead;if(t!==o&&(this.prevLead=o,this.lead=t,t.show(),o)){o.instance&&o.scheduleRender(),t.scheduleRender(),t.resumeFrom=o,n&&(t.resumeFrom.preserveOpacity=!0),o.snapshot&&(t.snapshot=o.snapshot,t.snapshot.latestValues=o.animationValues||o.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);const{crossfade:r}=t.options;r===!1&&o.hide()}}
vendor: 21,980 bytes, line 38
38exitAnimationComplete(){this.members.forEach(t=>{const{options:n,resumingFrom:o}=t;n.onExitComplete&&n.onExitComplete(),o&&o.options.onExitComplete&&o.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}function FC(e,t,n){let o="";const r=e.x.translate/t.x,s=e.y.translate/t.y,a=n?.z||0;if((r||s||a)&&(o=`translate3d(${r}px, ${s}px, ${a}px) `),(t.x!==1||t.y!==1)&&(o+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:u,rotate:d,rotateX:f,rotateY:p,skewX:h,skewY:m}=n;u&&(o=`perspective(${u}px) ${o}`),d&&(o+=`rotate(${d}deg) `),f&&(o+=`rotateX(${f}deg) `),p&&(o+=`rotateY(${p}deg) `),h&&(o+=`skewX(${h}deg) `),m&&(o+=`skewY(${m}deg) `)}const i=e.x.scale*t.x,c=e.y.scale*t.y;return(i!==1||c!==1)&&(o+=`scale(${i}, ${c})`),o||"none"}const xs=["","X","Y","Z"],LC=1e3;let jC=0;function ws(e,t,n,o){const{latestValues:r}=t;r[e]&&(n[e]=r[e],t.setStaticValue(e,0),o&&(o[e]=0))}function Lp(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=Cp(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:r,layoutId:s}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",ke,!(r||s))}const{parent:o}=e;o&&!o.hasCheckedOptimisedAppear&&Lp(o)}function jp({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:o,resetTransform:r}){return class{constructor(a={},i=t?.()){this.id=jC++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.layoutVersion=0,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(WC),this.nodes.forEach(YC),this.nodes.forEach(zC),this.nodes.forEach(HC)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=a,this.root=i?i.root||i:this,this.path=i?[...i.path,i]:[],this.parent=i,this.depth=i?i.depth+1:0;for(let c=0;c<this.path.length;c++)this.path[c].shouldResetTransform=!0;this.root===this&&(this.nodes=new MC)}addEventListener(a,i){return this.eventHandlers.has(a)||this.eventHandlers.set(a,new Ic),this.eventHandlers.get(a).add(i)}notifyListeners(a,...i){const c=this.eventHandlers.get(a);c&&c.notify(...i)}hasListeners(a){return this.eventHandlers.has(a)}mount(a){if(this.instance)return;this.isSVG=bm(a)&&!xm(a),this.instance=a;const{layoutId:i,layout:c,visualElement:u}=this.options;if(u&&!u.current&&u.mount(a),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(c||i)&&(this.isLayoutDirty=!0),e){let d,f=0;const p=()=>this.root.updateBlockedByResize=!1;ke.read(()=>{f=window.innerWidth}),e(a,()=>{const h=window.innerWidth;h!==f&&(f=h,this.root.updateBlockedByResize=!0,d&&d(),d=TC(p,250),Uo.hasAnimatedSinceResize&&(Uo.hasAnimatedSinceResize=!1,this.nodes.forEach(Ul)))})}i&&this.root.registerSharedNode(i,this),this.options.animate!==!1&&u&&(i||c)&&this.addEventListener("didUpdate",({delta:d,hasLayoutChanged:f,hasRelativeLayoutChanged:p,layout:h})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const m=this.options.transition||u.getDefaultTransition()||QC,{onLayoutAnimationStart:v,onLayoutAnimationComplete:g}=u.getProps(),y=!this.targetLayout||!Fp(this.targetLayout,h),b=!f&&p;if(this.options.layoutRoot||this.resumeFrom||b||f&&(y||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const x={...fa(m,"layout"),onPlay:v,onComplete:g};(u.shouldReduceMotion||this.options.layoutRoot)&&(x.delay=0,x.type=!1),this.startAnimation(x),this.setAnimationOrigin(d,b)}else f||Ul(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=h})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const a=this.getStack();a&&a.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),Gt(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(KC),this.animationId++)}getTransformTemplate(){const{visualElement:a}=this.options;return a&&a.getProps().transformTemplate}willUpdate(a=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&Lp(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let d=0;d<this.path.length;d++){const f=this.path[d];f.shouldResetTransform=!0,f.updateScroll("snapshot"),f.options.layoutRoot&&f.willUpdate(!1)}const{layoutId:i,layout:c}=this.options;if(i===void 0&&!c)return;const u=this.getTransformTemplate();this.prevTransformTemplateValue=u?u(this.latestValues,""):void 0,this.updateSnapshot(),a&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(Wl);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(Hl);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(GC),this.nodes.forEach(BC),this.nodes.forEach(VC)):this.nodes.forEach(Hl),this.clearAllSnapshots();const i=ua.now();Je.delta=_c(0,1e3/60,i-Je.timestamp),Je.timestamp=i,Je.isProcessing=!0,rs.update.process(Je),rs.preRender.process(Je),rs.render.process(Je),Je.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,da.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(UC),this.sharedNodes.forEach(qC)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,ke.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){ke.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!Ge(this.snapshot.measuredBox.x)&&!Ge(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let c=0;c<this.path.length;c++)this.path[c].updateScroll();const a=this.layout;this.layout=this.measure(!1),this.layoutVersion++,this.layoutCorrected=Oe(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:i}=this.options;i&&i.notify("LayoutMeasure",this.layout.layoutBox,a?a.layoutBox:void 0)}updateScroll(a="measure"){let i=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===a&&(i=!1),i&&this.instance){const c=o(this.instance);this.scroll={animationId:this.root.animationId,phase:a,isRoot:c,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:c}}}resetTransform(){if(!r)return;const a=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,i=this.projectionDelta&&!$p(this.projectionDelta),c=this.getTransformTemplate(),u=c?c(this.latestValues,""):void 0,d=u!==this.prevTransformTemplateValue;a&&this.instance&&(i||rn(this.latestValues)||d)&&(r(this.instance,u),this.shouldResetTransform=!1,this.scheduleRender())}measure(a=!0){const i=this.measurePageBox();let c=this.removeElementScroll(i);return a&&(c=this.removeTransform(c)),JC(c),{animationId:this.root.animationId,measuredBox:i,layoutBox:c,latestValues:{},source:this.id}}measurePageBox(){const{visualElement:a}=this.options;if(!a)return Oe();const i=a.measureViewportBox();if(!(this.scroll?.wasRoot||this.path.some(eS))){const{scroll:u}=this.root;u&&(En(i.x,u.offset.x),En(i.y,u.offset.y))}return i}removeElementScroll(a){const i=Oe();if(ft(i,a),this.scroll?.wasRoot)return i;for(let c=0;c<this.path.length;c++){const u=this.path[c],{scroll:d,options:f}=u;u!==this.root&&d&&f.layoutScroll&&(d.wasRoot&&ft(i,a),En(i.x,d.offset.x),En(i.y,d.offset.y))}return i}applyTransform(a,i=!1){const c=Oe();ft(c,a);for(let u=0;u<this.path.length;u++){const d=this.path[u];!i&&d.options.layoutScroll&&d.scroll&&d!==d.root&&Cn(c,{x:-d.scroll.offset.x,y:-d.scroll.offset.y}),rn(d.latestValues)&&Cn(c,d.latestValues)}return rn(this.latestValues)&&Cn(c,this.latestValues),c}removeTransform(a){const i=Oe();ft(i,a);for(let c=0;c<this.path.length;c++){const u=this.path[c];if(!u.instance||!rn(u.latestValues))continue;qs(u.latestValues)&&u.updateSnapshot();const d=Oe(),f=u.measurePageBox();ft(d,f),$l(i,u.latestValues,u.snapshot?u.snapshot.layoutBox:void 0,d)}return rn(this.latestValues)&&$l(i,this.latestValues),i}setTargetDelta(a){this.targetDelta=a,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(a){this.options={...this.options,...a,crossfade:a.crossfade!==void 0?a.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==Je.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(a=!1){const i=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=i.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=i.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=i.isSharedProjectionDirty);const c=!!this.resumingFrom||this!==i;if(!(a||c&&this.isSharedProjectionDirty||this.isProjectionDirty||this.parent?.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:d,layoutId:f}=this.options;if(!this.layout||!(d||f))return;this.resolvedRelativeTargetAt=Je.timestamp;const p=this.getClosestProjectingParent();p&&this.linkedParentVersion!==p.layoutVersion&&!p.options.layoutRoot&&this.removeRelativeTarget(),!this.targetDelta&&!this.relativeTarget&&(p&&p.layout?this.createRelativeTarget(p,this.layout.layoutBox,p.layout.layoutBox):this.removeRelativeTarget()),!(!this.relativeTarget&&!this.targetDelta)&&(this.target||(this.target=Oe(),this.targetWithTransforms=Oe()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),aC(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):ft(this.target,this.layout.layoutBox),gp(this.target,this.targetDelta)):ft(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=!1,p&&!!p.resumingFrom==!!this.resumingFrom&&!p.options.layoutScroll&&p.target&&this.animationProgress!==1?this.createRelativeTarget(p,this.target,p.target):this.relativeParent=this.relativeTarget=void 0))}getClosestProjectingParent(){if(!(!this.parent||qs(this.parent.latestValues)||vp(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(a,i,c){this.relativeParent=a,this.linkedParentVersion=a.layoutVersion,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Oe(),this.relativeTargetOrigin=Oe(),or(this.relativeTargetOrigin,i,c),ft(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){const a=this.getLead(),i=!!this.resumingFrom||this!==a;let c=!0;if((this.isProjectionDirty||this.parent?.isProjectionDirty)&&(c=!1),i&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(c=!1),this.resolvedRelativeTargetAt===Je.timestamp&&(c=!1),c)return;const{layout:u,layoutId:d}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(u||d))return;ft(this.layoutCorrected,this.layout.layoutBox);const f=this.treeScale.x,p=this.treeScale.y;bE(this.layoutCorrected,this.treeScale,this.path,i),a.layout&&!a.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(a.target=a.layout.layoutBox,a.targetWithTransforms=Oe());const{target:h}=a;if(!h){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(Al(this.prevProjectionDelta.x,this.projectionDelta.x),Al(this.prevProjectionDelta.y,this.projectionDelta.y)),oo(this.projectionDelta,this.layoutCorrected,h,this.latestValues),(this.treeScale.x!==f||this.treeScale.y!==p||!Vl(this.projectionDelta.x,this.prevProjectionDelta.x)||!Vl(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",h))}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(a=!0){if(this.options.visualElement?.scheduleRender(),a){const i=this.getStack();i&&i.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=Sn(),this.projectionDelta=Sn(),this.projectionDeltaWithTransform=Sn()}setAnimationOrigin(a,i=!1){const c=this.snapshot,u=c?c.latestValues:{},d={...this.latestValues},f=Sn();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!i;const p=Oe(),h=c?c.source:void 0,m=this.layout?this.layout.source:void 0,v=h!==m,g=this.getStack(),y=!g||g.members.length<=1,b=!!(v&&!y&&this.options.crossfade===!0&&!this.path.some(ZC));this.animationProgress=0;let x;this.mixTargetDelta=S=>{const T=S/1e3;Gl(f.x,a.x,T),Gl(f.y,a.y,T),this.setTargetDelta(f),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(or(p,this.layout.layoutBox,this.relativeParent.layout.layoutBox),XC(this.relativeTarget,this.relativeTargetOrigin,p,T),x&&NC(this.relativeTarget,x)&&(this.isProjectionDirty=!1),x||(x=Oe()),ft(x,this.relativeTarget)),v&&(this.animationValues=d,RC(d,u,this.latestValues,T,b,y)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=T},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(a){this.notifyListeners("animationStart"),this.currentAnimation?.stop(),this.resumingFrom?.currentAnimation?.stop(),this.pendingAnimation&&(Gt(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=ke.update(()=>{Uo.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=cn(0)),this.currentAnimation=SC(this.motionValue,[0,1e3],{...a,velocity:0,isSync:!0,onUpdate:i=>{this.mixTargetDelta(i),a.onUpdate&&a.onUpdate(i)},onStop:()=>{},onComplete:()=>{a.onComplete&&a.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const a=this.getStack();a&&a.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(LC),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const a=this.getLead();let{targetWithTransforms:i,target:c,layout:u,latestValues:d}=a;if(!(!i||!c||!u)){if(this!==a&&this.layout&&u&&Bp(this.options.animationType,this.layout.layoutBox,u.layoutBox)){c=this.target||Oe();const f=Ge(this.layout.layoutBox.x);c.x.min=a.target.x.min,c.x.max=c.x.min+f;const p=Ge(this.layout.layoutBox.y);c.y.min=a.target.y.min,c.y.max=c.y.min+p}ft(i,c),Cn(i,d),oo(this.projectionDeltaWithTransform,this.layoutCorrected,i,d)}}registerSharedNode(a,i){this.sharedNodes.has(a)||this.sharedNodes.set(a,new $C),this.sharedNodes.get(a).add(i);const u=i.options.initialPromotionConfig;i.promote({transition:u?u.transition:void 0,preserveFollowOpacity:u&&u.shouldPreserveFollowOpacity?u.shouldPreserveFollowOpacity(i):void 0})}isLead(){const a=this.getStack();return a?a.lead===this:!0}getLead(){const{layoutId:a}=this.options;return a?this.getStack()?.lead||this:this}getPrevLead(){const{layoutId:a}=this.options;return a?this.getStack()?.prevLead:void 0}getStack(){const{layoutId:a}=this.options;if(a)return this.root.sharedNodes.get(a)}promote({needsReset:a,transition:i,preserveFollowOpacity:c}={}){const u=this.getStack();u&&u.promote(this,c),a&&(this.projectionDelta=void 0,this.needsReset=!0),i&&this.setOptions({transition:i})}relegate(){const a=this.getStack();return a?a.relegate(this):!1}resetSkewAndRotation(){const{visualElement:a}=this.options;if(!a)return;let i=!1;const{latestValues:c}=a;if((c.z||c.rotate||c.rotateX||c.rotateY||c.rotateZ||c.skewX||c.skewY)&&(i=!0),!i)return;const u={};c.z&&ws("z",a,u,this.animationValues);for(let d=0;d<xs.length;d++)ws(`rotate${xs[d]}`,a,u,this.animationValues),ws(`skew${xs[d]}`,a,u,this.animationValues);a.render();for(const d in u)a.setStaticValue(d,u[d]),this.animationValues&&(this.animationValues[d]=u[d]);a.scheduleRender()}applyProjectionStyles(a,i){if(!this.instance||this.isSVG)return;if(!this.isVisible){a.visibility="hidden";return}const c=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,a.visibility="",a.opacity="",a.pointerEvents=Ho(i?.pointerEvents)||"",a.transform=c?c(this.latestValues,""):"none";return}const u=this.getLead();if(!this.projectionDelta||!this.layout||!u.target){this.options.layoutId&&(a.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,a.pointerEvents=Ho(i?.pointerEvents)||""),this.hasProjected&&!rn(this.latestValues)&&(a.transform=c?c({},""):"none",this.hasProjected=!1);return}a.visibility="";const d=u.animationValues||u.latestValues;this.applyTransformsToTarget();let f=FC(this.projectionDeltaWithTransform,this.treeScale,d);c&&(f=c(d,f)),a.transform=f;const{x:p,y:h}=this.projectionDelta;a.transformOrigin=`${p.origin*100}% ${h.origin*100}% 0`,u.animationValues?a.opacity=u===this?d.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:d.opacityExit:a.opacity=u===this?d.opacity!==void 0?d.opacity:"":d.opacityExit!==void 0?d.opacityExit:0;for(const m in uo){if(d[m]===void 0)continue;const{correct:v,applyTo:g,isCSSVariable:y}=uo[m],b=f==="none"?d[m]:v(d[m],u);if(g){const x=g.length;for(let S=0;S<x;S++)a[g[S]]=b}else y?this.options.visualElement.renderState.vars[m]=b:a[m]=b}this.options.layoutId&&(a.pointerEvents=u===this?Ho(i?.pointerEvents)||"":"none")}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(a=>a.currentAnimation?.stop()),this.root.nodes.forEach(Wl),this.root.sharedNodes.clear()}}}function BC(e){e.updateLayout()}function VC(e){const t=e.resumeFrom?.snapshot||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners("didUpdate")){const{layoutBox:n,measuredBox:o}=e.layout,{animationType:r}=e.options,s=t.source!==e.layout.source;r==="size"?at(d=>{const f=s?t.measuredBox[d]:t.layoutBox[d],p=Ge(f);f.min=n[d].min,f.max=f.min+p}):Bp(r,t.layoutBox,n)&&at(d=>{const f=s?t.measuredBox[d]:t.layoutBox[d],p=Ge(n[d]);f.max=f.min+p,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[d].max=e.relativeTarget[d].min+p)});const a=Sn();oo(a,n,t.layoutBox);const i=Sn();s?oo(i,e.applyTransform(o,!0),t.measuredBox):oo(i,n,t.layoutBox);const c=!$p(a);let u=!1;if(!e.resumeFrom){const d=e.getClosestProjectingParent();if(d&&!d.resumeFrom){const{snapshot:f,layout:p}=d;if(f&&p){const h=Oe();or(h,t.layoutBox,f.layoutBox);const m=Oe();or(m,n,p.layoutBox),Fp(h,m)||(u=!0),d.options.layoutRoot&&(e.relativeTarget=m,e.relativeTargetOrigin=h,e.relativeParent=d)}}}e.notifyListeners("didUpdate",{layout:n,snapshot:t,delta:i,layoutDelta:a,hasLayoutChanged:c,hasRelativeLayoutChanged:u})}else if(e.isLead()){const{onExitComplete:n}=e.options;n&&n()}e.options.transition=void 0}function WC(e){e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function HC(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function UC(e){e.clearSnapshot()}function Wl(e){e.clearMeasurements()}function Hl(e){e.isLayoutDirty=!1}function GC(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function Ul(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function YC(e){e.resolveTargetDelta()}function zC(e){e.calcProjection()}
vendor: 4,517 bytes, line 38
38function KC(e){e.resetSkewAndRotation()}function qC(e){e.removeLeadSnapshot()}function Gl(e,t,n){e.translate=Ie(t.translate,0,n),e.scale=Ie(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function Yl(e,t,n,o){e.min=Ie(t.min,n.min,o),e.max=Ie(t.max,n.max,o)}function XC(e,t,n,o){Yl(e.x,t.x,n.x,o),Yl(e.y,t.y,n.y,o)}function ZC(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const QC={duration:.45,ease:[.4,0,.1,1]},zl=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),Kl=zl("applewebkit/")&&!zl("chrome/")?Math.round:Pn;function ql(e){e.min=Kl(e.min),e.max=Kl(e.max)}function JC(e){ql(e.x),ql(e.y)}function Bp(e,t,n){return e==="position"||e==="preserve-aspect"&&!sC(Bl(t),Bl(n),.2)}function eS(e){return e!==e.root&&e.scroll?.wasRoot}const tS=jp({attachResizeListener:(e,t)=>fo(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),Es={current:void 0},Vp=jp({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!Es.current){const e=new tS({});e.mount(window),e.setOptions({layoutScroll:!0}),Es.current=e}return Es.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),nS={pan:{Feature:xC},drag:{Feature:bC,ProjectionNode:Vp,MeasureLayout:Ap}};function Xl(e,t,n){const{props:o}=e;e.animationState&&o.whileHover&&e.animationState.setActive("whileHover",n==="Start");const r="onHover"+n,s=o[r];s&&ke.postRender(()=>s(t,Co(t)))}class oS extends Jt{mount(){const{current:t}=this.node;t&&(this.unmount=wm(t,(n,o)=>(Xl(this.node,o,"Start"),r=>Xl(this.node,r,"End"))))}unmount(){}}class rS extends Jt{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=Ac(fo(this.node.current,"focus",()=>this.onFocus()),fo(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function Zl(e,t,n){const{props:o}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&o.whileTap&&e.animationState.setActive("whileTap",n==="Start");const r="onTap"+(n==="End"?"":n),s=o[r];s&&ke.postRender(()=>s(t,Co(t)))}class sS extends Jt{mount(){const{current:t}=this.node;t&&(this.unmount=Em(t,(n,o)=>(Zl(this.node,o,"Start"),(r,{success:s})=>Zl(this.node,r,s?"End":"Cancel")),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}const ta=new WeakMap,Cs=new WeakMap,aS=e=>{const t=ta.get(e.target);t&&t(e)},iS=e=>{e.forEach(aS)};function lS({root:e,...t}){const n=e||document;Cs.has(n)||Cs.set(n,{});const o=Cs.get(n),r=JSON.stringify(t);return o[r]||(o[r]=new IntersectionObserver(iS,{root:e,...t})),o[r]}function cS(e,t,n){const o=lS(t);return ta.set(e,n),o.observe(e),()=>{ta.delete(e),o.unobserve(e)}}const uS={some:0,all:1};class dS extends Jt{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:n,margin:o,amount:r="some",once:s}=t,a={root:n?n.current:void 0,rootMargin:o,threshold:typeof r=="number"?r:uS[r]},i=c=>{const{isIntersecting:u}=c;if(this.isInView===u||(this.isInView=u,s&&!u&&this.hasEnteredView))return;u&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",u);const{onViewportEnter:d,onViewportLeave:f}=this.node.getProps(),p=u?d:f;p&&p(c)};return cS(this.node.current,a,i)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(fS(t,n))&&this.startObserver()}unmount(){}}function fS({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const pS={inView:{Feature:dS},tap:{Feature:sS},focus:{Feature:rS},hover:{Feature:oS}},hS={layout:{ProjectionNode:Vp,MeasureLayout:Ap}},mS={...JE,...pS,...nS,...hS},Wp=vE(mS,kE);function Hp(e){const t=Qt(()=>cn(e)),{isStatic:n}=l.useContext(Or);if(n){const[,o]=l.useState(e);l.useEffect(()=>t.on("change",o),[])}return t}function Up(e,t){const n=Hp(t()),o=()=>n.set(t());return o(),ja(()=>{const r=()=>ke.preRender(o,!1,!0),s=e.map(a=>a.on("change",r));return()=>
38{s.forEach(a=>a()),Gt(o)}}),n}function vS(e){ss.current=[],e();const t=Up(ss.current,e);return ss.current=void 0,t}function gS(e,t,n,o){if(typeof e=="function")return vS(e);const r=typeof t=="function"?t:Cm(t,n,o);return Array.isArray(e)?Ql(e,r):Ql([e],([s])=>r(s))}function Ql(e,t){const n=Qt(()=>[]);return Up(e,()=>{n.length=0;const o=e.length;for(let r=0;r<o;r++)n[r]=e[r].get();return t(n)})}function U2(){!Ka.current&&bp();const[e]=l.useState(nr.current);return e}class yS{constructor(){this.componentControls=new Set}subscribe(t){return this.componentControls.add(t),()=>this.componentControls.delete(t)}start(t,n){this.componentControls.forEach(o=>{o.start(t.nativeEvent||t,n)})}cancel(){this.componentControls.forEach(t=>{t.cancel()})}stop(){this.componentControls.forEach(t=>{t.stop()})}}const bS=()=>new yS;function G2(){return Qt(bS)}const Gp=l.createContext(null);function xS(e,t,n,o){if(!o)return e;const r=e.findIndex(d=>d.value===t);if(r===-1)return e;const s=o>0?1:-1,a=e[r+s];if(!a)return e;const i=e[r],c=a.layout,u=Ie(c.min,c.max,.5);return s===1&&i.layout.max+n>u||s===-1&&i.layout.min+n<u?Sm(e,r,r+s):e}function wS({children:e,as:t="ul",axis:n="y",onReorder:o,values:r,...s},a){const i=Qt(()=>Wp[t]),c=[],u=l.useRef(!1),d={axis:n,registerItem:(f,p)=>{const h=c.findIndex(m=>f===m.value);h!==-1?c[h].layout=p[n]:c.push({value:f,layout:p[n]}),c.sort(CS)},updateOrder:(f,p,h)=>{if(u.current)return;const m=xS(c,f,p,h);c!==m&&(u.current=!0,o(m.map(ES).filter(v=>r.indexOf(v)!==-1)))}};return l.useEffect(()=>{u.current=!1}),E.jsx(i,{...s,ref:a,ignoreStrict:!0,children:E.jsx(Gp.Provider,{value:d,children:e})})}const Y2=l.forwardRef(wS);function ES(e){return e.value}function CS(e,t){return e.layout.min-t.layout.min}function Jl(e,t=0){return Be(e)?e:Hp(t)}function SS({children:e,style:t={},value:n,as:o="li",onDrag:r,layout:s=!0,...a},i){const c=Qt(()=>Wp[o]),u=l.useContext(Gp),d={x:Jl(t.x),y:Jl(t.y)},f=gS([d.x,d.y],([v,g])=>v||g?1:"unset"),{axis:p,registerItem:h,updateOrder:m}=u;return E.jsx(c,{drag:p,...a,dragSnapToOrigin:!0,style:{...t,x:d.x,y:d.y,zIndex:f},layout:s,onDrag:(v,g)=>{const{velocity:y}=g;y[p]&&m(n,d[p].get(),y[p]),r&&r(v,g)},onLayoutMeasure:v=>h(n,v),ref:i,ignoreStrict:!0,children:e})}const z2=l.forwardRef(SS),ec=5,PS=4;function MS(e,t){const n=t.startOfMonth(e),o=n.getDay()>0?n.getDay():7,r=t.addDays(e,-o+1),s=t.addDays(r,ec*7-1);return t.getMonth(e)===t.getMonth(s)?ec:PS}function Yp(e,t){const n=t.startOfMonth(e),o=n.getDay();return o===1?n:o===0?t.addDays(n,-6):t.addDays(n,-1*(o-1))}function TS(e,t){const n=Yp(e,t),o=MS(e,t);return t.addDays(n,o*7-1)}const zp={...zn,labels:{labelDayButton:(e,t,n,o)=>{let r;o&&typeof o.format=="function"?r=o.format.bind(o):r=(a,i)=>Qn(a,i,{locale:zn,...n});let s=r(e,"PPPP");return t.today&&(s=`Today, ${s}`),t.selected&&(s=`${s}, selected`),s},labelMonthDropdown:"Choose the Month",labelNext:"Go to the Next Month",labelPrevious:"Go to the Previous Month",labelWeekNumber:e=>`Week ${e}`,labelYearDropdown:"Choose the Year",labelGrid:(e,t,n)=>{let o;return n&&typeof n.format=="function"?o=n.format.bind(n):o=(r,s)=>Qn(r,s,{locale:zn,...t}),o(e,"LLLL yyyy")},labelGridcell:(e,t,n,o)=>{let r;o&&typeof o.format=="function"?r=o.format.bind(o):r=(a,i)=>Qn(a,i,{locale:zn,...n});let s=r(e,"PPPP");return t?.today&&(s=`Today, ${s}`),s},labelNav:"Navigation bar",labelWeekNumberHeader:"Week Number",labelWeekday:(e,t,n)=>{let o;return n&&typeof n.format=="function"?o=n.format.bind(n):o=(r,s)=>Qn(r,s,{locale:zn,...t}),o(e,"cccc")}}};class nt{constructor(t,n){this.Date=Date,this.today=()=>this.overrides?.today?this.overrides.today():this.options.timeZone?zo.tz(this.options.timeZone):new this.Date,this.newDate=(o,r,s)=>this.overrides?.newDate?this.overrides.newDate(o,r,s):this.options.timeZone?new zo(o,r,s,this.options.timeZone):new Date(o,r,s),this.addDays=(o,r)=>
vendor: 7,488 bytes, line 38
38this.overrides?.addDays?this.overrides.addDays(o,r):Rm(o,r),this.addMonths=(o,r)=>this.overrides?.addMonths?this.overrides.addMonths(o,r):Dm(o,r),this.addWeeks=(o,r)=>this.overrides?.addWeeks?this.overrides.addWeeks(o,r):Im(o,r),this.addYears=(o,r)=>this.overrides?.addYears?this.overrides.addYears(o,r):Om(o,r),this.differenceInCalendarDays=(o,r)=>this.overrides?.differenceInCalendarDays?this.overrides.differenceInCalendarDays(o,r):Am(o,r),this.differenceInCalendarMonths=(o,r)=>this.overrides?.differenceInCalendarMonths?this.overrides.differenceInCalendarMonths(o,r):_m(o,r),this.eachMonthOfInterval=o=>this.overrides?.eachMonthOfInterval?this.overrides.eachMonthOfInterval(o):Nm(o),this.eachYearOfInterval=o=>{const r=this.overrides?.eachYearOfInterval?this.overrides.eachYearOfInterval(o):$m(o),s=new Set(r.map(i=>this.getYear(i)));if(s.size===r.length)return r;const a=[];return s.forEach(i=>{a.push(new Date(i,0,1))}),a},this.endOfBroadcastWeek=o=>this.overrides?.endOfBroadcastWeek?this.overrides.endOfBroadcastWeek(o):TS(o,this),this.endOfISOWeek=o=>this.overrides?.endOfISOWeek?this.overrides.endOfISOWeek(o):Fm(o),this.endOfMonth=o=>this.overrides?.endOfMonth?this.overrides.endOfMonth(o):Lm(o),this.endOfWeek=(o,r)=>this.overrides?.endOfWeek?this.overrides.endOfWeek(o,r):jm(o,this.options),this.endOfYear=o=>this.overrides?.endOfYear?this.overrides.endOfYear(o):Bm(o),this.format=(o,r,s)=>{const a=this.overrides?.format?this.overrides.format(o,r,this.options):Qn(o,r,this.options);return this.options.numerals&&this.options.numerals!=="latn"?this.replaceDigits(a):a},this.getISOWeek=o=>this.overrides?.getISOWeek?this.overrides.getISOWeek(o):Vm(o),this.getMonth=(o,r)=>this.overrides?.getMonth?this.overrides.getMonth(o,this.options):Wm(o,this.options),this.getYear=(o,r)=>this.overrides?.getYear?this.overrides.getYear(o,this.options):Hm(o,this.options),this.getWeek=(o,r)=>this.overrides?.getWeek?this.overrides.getWeek(o,this.options):Um(o,this.options),this.isAfter=(o,r)=>this.overrides?.isAfter?this.overrides.isAfter(o,r):Gm(o,r),this.isBefore=(o,r)=>this.overrides?.isBefore?this.overrides.isBefore(o,r):Ym(o,r),this.isDate=o=>this.overrides?.isDate?this.overrides.isDate(o):zm(o),this.isSameDay=(o,r)=>this.overrides?.isSameDay?this.overrides.isSameDay(o,r):Km(o,r),this.isSameMonth=(o,r)=>this.overrides?.isSameMonth?this.overrides.isSameMonth(o,r):qm(o,r),this.isSameYear=(o,r)=>this.overrides?.isSameYear?this.overrides.isSameYear(o,r):Xm(o,r),this.max=o=>this.overrides?.max?this.overrides.max(o):Zm(o),this.min=o=>this.overrides?.min?this.overrides.min(o):Qm(o),this.setMonth=(o,r)=>this.overrides?.setMonth?this.overrides.setMonth(o,r):Jm(o,r),this.setYear=(o,r)=>this.overrides?.setYear?this.overrides.setYear(o,r):ev(o,r),this.startOfBroadcastWeek=(o,r)=>this.overrides?.startOfBroadcastWeek?this.overrides.startOfBroadcastWeek(o,this):Yp(o,this),this.startOfDay=o=>this.overrides?.startOfDay?this.overrides.startOfDay(o):tv(o),this.startOfISOWeek=o=>this.overrides?.startOfISOWeek?this.overrides.startOfISOWeek(o):nv(o),this.startOfMonth=o=>this.overrides?.startOfMonth?this.overrides.startOfMonth(o):ov(o),this.startOfWeek=(o,r)=>this.overrides?.startOfWeek?this.overrides.startOfWeek(o,this.options):rv(o,this.options),this.startOfYear=o=>this.overrides?.startOfYear?this.overrides.startOfYear(o):sv(o),this.options={locale:zp,...t},this.overrides=n}getDigitMap(){const{numerals:t="latn"}=this.options,n=new Intl.NumberFormat("en-US",{numberingSystem:t}),o={};for(let r=0;r<10;r++)o[r.toString()]=n.format(r);return o}replaceDigits(t){const n=this.getDigitMap();return t.replace(/\d/g,o=>n[o]||o)}formatNumber(t){return this.replaceDigits(t.toString())}getMonthYearOrder(){const t=this.options.locale?.code;return t&&nt.yearFirstLocales.has(t)?"year-first":"month-first"}formatMonthYear(t){const{locale:n,timeZone:o,numerals:r}=this.options,s=n?.code;if(s&&nt.yearFirstLocales.has(s))try{return new Intl.DateTimeFormat(s,{month:"long",year:"numeric",timeZone:o,numberingSystem:r}).format(t)}catch{}const a=this.getMonthYearOrder()==="year-first"?"y LLLL":"LLLL y";return this.format(t,a)}}nt.yearFirstLocales=new Set(["eu","hu","ja","ja-Hira","ja-JP","ko","ko-KR","lt","lt-LT","lv","lv-LV","mn","mn-MN","zh","zh-CN","zh-HK","zh-TW"]);const Rt=new nt;class Kp{constructor(t,n,o=Rt){this.date=t,this.displayMonth=n,this.outside=!!(n&&!o.isSameMonth(t,n)),this.dateLib=o,this.isoDate=o.format(t,"yyyy-MM-dd"),this.displayMonthId=o.format(n,"yyyy-MM"),this.dateMonthId=o.format(t,"yyyy-MM")}isEqualTo(t){return this.dateLib.isSameDay(t.date,this.date)&&this.dateLib.isSameMonth(t.displayMonth,this.displayMonth)}}class kS{constructor(t,n){this.date=t,this.weeks=n}}class RS{constructor(t,n){this.days=n,this.weekNumber=t}}function DS(e){return w.createElement("button",{...e})}function IS(e){return w.createElement("span",{...e})}function OS(e){const{size:t=24,orientation:n="left",className:o}=e;return w.createElement("svg",{className:o,width:t,height:t,viewBox:"0 0 24 24"},n==="up"&&w.createElement("polygon",{points:"6.77 17 12.5 11.43 18.24 17 20 15.28 12.5 8 5 15.28"}),n==="down"&&w.createElement("polygon",{points:"6.77 8 12.5 13.57 18.24 8 20 9.72 12.5 17 5 9.72"}),n==="left"&&w.createElement("polygon",{points:"16 18.112 9.81111111 12 16 5.87733333 14.0888889 4 6 12 14.0888889 20"}),n==="right"&&w.createElement("polygon",{points:"8 18.112 14.18888889 12 8 5.87733333 9.91111111 4 18 12 9.91111111 20"}))}function AS(e){const{day:t,modifiers:n,...o}=e;return w.createElement("td",{...o})}function _S(e){const{day:t,modifiers:n,...o}=e,r=w.useRef(null);return w.useEffect(()=>{n.focused&&r.current?.focus()},[n.focused]),w.createElement("button",{ref:r,...o})}var oe;(function(e){e.Root="root",e.Chevron="chevron",e.Day="day",e.DayButton="day_button",e.CaptionLabel="caption_label",e.Dropdowns="dropdowns",e.Dropdown="dropdown",e.DropdownRoot="dropdown_root",e.Footer="footer",e.MonthGrid="month_grid",e.MonthCaption="month_caption",e.MonthsDropdown="months_dropdown",e.Month="month",e.Months="months",e.Nav="nav",e.NextMonthButton="button_next",e.PreviousMonthButton="button_previous",e.Week="week",e.Weeks="weeks",e.Weekday="weekday",e.Weekdays="weekdays",e.WeekNumber="week_number",e.WeekNumberHeader="week_number_header",e.YearsDropdown="years_dropdown"})(oe||(oe={}));var Pe;(function(e){e.disabled="disabled",e.hidden="hidden",e.outside="outside",e.focused="focused",e.today="today"})(Pe||(Pe={}));var mt;(function(e){e.range_end="range_end",e.range_middle="range_middle",e.range_start="range_start",e.selected="selected"})(mt||(mt={}));var et;(function(e){e.weeks_before_enter="weeks_before_enter",e.weeks_before_exit="weeks_before_exit",e.weeks_after_enter="weeks_after_enter",e.weeks_after_exit="weeks_after_exit",e.caption_after_enter="caption_after_enter",e.caption_after_exit="caption_after_exit",e.caption_before_enter="caption_before_enter",e.caption_before_exit="caption_before_exit"})(et||(et={}));function NS(e){const{options:t,className:n,components:o,classNames:r,...s}=e,a=[r[oe.Dropdown],n].join(" "),i=t?.find(({value:c})=>c===s.value);return w.createElement("span",{"data-disabled":s.disabled,className:r[oe.DropdownRoot]},w.createElement(o.Select,{className:a,...s},t?.map(({value:c,label:u,disabled:d})=>w.createElement(o.Option,{key:c,value:c,disabled:d},u))),w.createElement("span",{className:r[oe.CaptionLabel],"aria-hidden":!0},i?.label,w.createElement(o.Chevron,{orientation:"down",size:18,className:r[oe.Chevron]}
vendor: 12,625 bytes, line 38
38)))}function $S(e){return w.createElement("div",{...e})}function FS(e){return w.createElement("div",{...e})}function LS(e){const{calendarMonth:t,displayIndex:n,...o}=e;return w.createElement("div",{...o},e.children)}function jS(e){const{calendarMonth:t,displayIndex:n,...o}=e;return w.createElement("div",{...o})}function BS(e){return w.createElement("table",{...e})}function VS(e){return w.createElement("div",{...e})}const qp=l.createContext(void 0);function So(){const e=l.useContext(qp);if(e===void 0)throw new Error("useDayPicker() must be used within a custom component.");return e}function WS(e){const{components:t}=So();return w.createElement(t.Dropdown,{...e})}function HS(e){const{onPreviousClick:t,onNextClick:n,previousMonth:o,nextMonth:r,...s}=e,{components:a,classNames:i,labels:{labelPrevious:c,labelNext:u}}=So(),d=l.useCallback(p=>{r&&n?.(p)},[r,n]),f=l.useCallback(p=>{o&&t?.(p)},[o,t]);return w.createElement("nav",{...s},w.createElement(a.PreviousMonthButton,{type:"button",className:i[oe.PreviousMonthButton],tabIndex:o?void 0:-1,"aria-disabled":o?void 0:!0,"aria-label":c(o),onClick:f},w.createElement(a.Chevron,{disabled:o?void 0:!0,className:i[oe.Chevron],orientation:"left"})),w.createElement(a.NextMonthButton,{type:"button",className:i[oe.NextMonthButton],tabIndex:r?void 0:-1,"aria-disabled":r?void 0:!0,"aria-label":u(r),onClick:d},w.createElement(a.Chevron,{disabled:r?void 0:!0,orientation:"right",className:i[oe.Chevron]})))}function US(e){const{components:t}=So();return w.createElement(t.Button,{...e})}function GS(e){return w.createElement("option",{...e})}function YS(e){const{components:t}=So();return w.createElement(t.Button,{...e})}function zS(e){const{rootRef:t,...n}=e;return w.createElement("div",{...n,ref:t})}function KS(e){return w.createElement("select",{...e})}function qS(e){const{week:t,...n}=e;return w.createElement("tr",{...n})}function XS(e){return w.createElement("th",{...e})}function ZS(e){return w.createElement("thead",{"aria-hidden":!0},w.createElement("tr",{...e}))}function QS(e){const{week:t,...n}=e;return w.createElement("th",{...n})}function JS(e){return w.createElement("th",{...e})}function eP(e){return w.createElement("tbody",{...e})}function tP(e){const{components:t}=So();return w.createElement(t.Dropdown,{...e})}const nP=Object.freeze(Object.defineProperty({__proto__:null,Button:DS,CaptionLabel:IS,Chevron:OS,Day:AS,DayButton:_S,Dropdown:NS,DropdownNav:$S,Footer:FS,Month:LS,MonthCaption:jS,MonthGrid:BS,Months:VS,MonthsDropdown:WS,Nav:HS,NextMonthButton:US,Option:GS,PreviousMonthButton:YS,Root:zS,Select:KS,Week:qS,WeekNumber:QS,WeekNumberHeader:JS,Weekday:XS,Weekdays:ZS,Weeks:eP,YearsDropdown:tP},Symbol.toStringTag,{value:"Module"}));function Ot(e,t,n=!1,o=Rt){let{from:r,to:s}=e;const{differenceInCalendarDays:a,isSameDay:i}=o;return r&&s?(a(s,r)<0&&([r,s]=[s,r]),a(t,r)>=(n?1:0)&&a(s,t)>=(n?1:0)):!n&&s?i(s,t):!n&&r?i(r,t):!1}function Xa(e){return!!(e&&typeof e=="object"&&"before"in e&&"after"in e)}function $r(e){return!!(e&&typeof e=="object"&&"from"in e)}function Za(e){return!!(e&&typeof e=="object"&&"after"in e)}function Qa(e){return!!(e&&typeof e=="object"&&"before"in e)}function Xp(e){return!!(e&&typeof e=="object"&&"dayOfWeek"in e)}function Zp(e,t){return Array.isArray(e)&&e.every(t.isDate)}function At(e,t,n=Rt){const o=Array.isArray(t)?t:[t],{isSameDay:r,differenceInCalendarDays:s,isAfter:a}=n;return o.some(i=>{if(typeof i=="boolean")return i;if(n.isDate(i))return r(e,i);if(Zp(i,n))return i.some(c=>r(e,c));if($r(i))return Ot(i,e,!1,n);if(Xp(i))return Array.isArray(i.dayOfWeek)?i.dayOfWeek.includes(e.getDay()):i.dayOfWeek===e.getDay();if(Xa(i)){const c=s(i.before,e),u=s(i.after,e),d=c>0,f=u<0;return a(i.before,i.after)?f&&d:d||f}return Za(i)?s(e,i.after)>0:Qa(i)?s(i.before,e)>0:typeof i=="function"?i(e):!1})}function oP(e,t,n,o,r){const{disabled:s,hidden:a,modifiers:i,showOutsideDays:c,broadcastCalendar:u,today:d=r.today()}=t,{isSameDay:f,isSameMonth:p,startOfMonth:h,isBefore:m,endOfMonth:v,isAfter:g}=r,y=n&&h(n),b=o&&v(o),x={[Pe.focused]:[],[Pe.outside]:[],[Pe.disabled]:[],[Pe.hidden]:[],[Pe.today]:[]},S={};for(const T of e){const{date:C,displayMonth:P}=T,_=!!(P&&!p(C,P)),O=!!(y&&m(C,y)),I=!!(b&&g(C,b)),$=!!(s&&At(C,s,r)),G=!!(a&&At(C,a,r))||O||I||!u&&!c&&_||u&&c===!1&&_,W=f(C,d);_&&x.outside.push(T),$&&x.disabled.push(T),G&&x.hidden.push(T),W&&x.today.push(T),i&&Object.keys(i).forEach(B=>{const K=i?.[B];K&&At(C,K,r)&&(S[B]?S[B].push(T):S[B]=[T])})}return T=>{const C={[Pe.focused]:!1,[Pe.disabled]:!1,[Pe.hidden]:!1,[Pe.outside]:!1,[Pe.today]:!1},P={};for(const _ in x){const O=x[_];C[_]=O.some(I=>I===T)}for(const _ in S)P[_]=S[_].some(O=>O===T);return{...C,...P}}}function rP(e,t,n={}){return Object.entries(e).filter(([,r])=>r===!0).reduce((r,[s])=>(n[s]?r.push(n[s]):t[Pe[s]]?r.push(t[Pe[s]]):t[mt[s]]&&r.push(t[mt[s]]),r),[t[oe.Day]])}function sP(e){return{...nP,...e}}function aP(e){const t={"data-mode":e.mode??void 0,"data-required":"required"in e?e.required:void 0,"data-multiple-months":e.numberOfMonths&&e.numberOfMonths>1||void 0,"data-week-numbers":e.showWeekNumber||void 0,"data-broadcast-calendar":e.broadcastCalendar||void 0,"data-nav-layout":e.navLayout||void 0};return Object.entries(e).forEach(([n,o])=>{n.startsWith("data-")&&(t[n]=o)}),t}function iP(){const e={};for(const t in oe)e[oe[t]]=`rdp-${oe[t]}`;for(const t in Pe)e[Pe[t]]=`rdp-${Pe[t]}`;for(const t in mt)e[mt[t]]=`rdp-${mt[t]}`;for(const t in et)e[et[t]]=`rdp-${et[t]}`;return e}function Qp(e,t,n){return(n??new nt(t)).formatMonthYear(e)}const lP=Qp;function cP(e,t,n){return(n??new nt(t)).format(e,"d")}function uP(e,t=Rt){return t.format(e,"LLLL")}function dP(e,t,n){return(n??new nt(t)).format(e,"cccccc")}function fP(e,t=Rt){return e<10?t.formatNumber(`0${e.toLocaleString()}`):t.formatNumber(`${e.toLocaleString()}`)}function pP(){return""}function Jp(e,t=Rt){return t.format(e,"yyyy")}const hP=Jp,mP=Object.freeze(Object.defineProperty({__proto__:null,formatCaption:Qp,formatDay:cP,formatMonthCaption:lP,formatMonthDropdown:uP,formatWeekNumber:fP,formatWeekNumberHeader:pP,formatWeekdayName:dP,formatYearCaption:hP,formatYearDropdown:Jp},Symbol.toStringTag,{value:"Module"}));function vP(e){return e?.formatMonthCaption&&!e.formatCaption&&(e.formatCaption=e.formatMonthCaption),e?.formatYearCaption&&!e.formatYearDropdown&&(e.formatYearDropdown=e.formatYearCaption),{...mP,...e}}function Ja(e,t,n,o){let r=(o??new nt(n)).format(e,"PPPP");return t.today&&(r=`Today, ${r}`),t.selected&&(r=`${r}, selected`),r}const gP=Ja;function ei(e,t,n){return(n??new nt(t)).formatMonthYear(e)}const yP=ei;function eh(e,t,n,o){let r=(o??new nt(n)).format(e,"PPPP");return t?.today&&(r=`Today, ${r}`),r}function th(e){return"Choose the Month"}function nh(){return""}const bP="Go to the Next Month";function oh(e,t){return bP}function rh(e){return"Go to the Previous Month"}function sh(e,t,n){return(n??new nt(t)).format(e,"cccc")}function ah(e,t){return`Week ${e}`}function ih(e){return"Week Number"}function lh(e){return"Choose the Year"}const xP=Object.freeze(Object.defineProperty({__proto__:null,labelCaption:yP,labelDay:gP,labelDayButton:Ja,labelGrid:ei,labelGridcell:eh,labelMonthDropdown:th,labelNav:nh,labelNext:oh,labelPrevious:rh,labelWeekNumber:ah,labelWeekNumberHeader:ih,labelWeekday:sh,labelYearDropdown:lh},Symbol.toStringTag,{value:"Module"})),pt=(e,t,n)=>t||(n?typeof n=="function"?n:(...o)=>n:e);function wP(e,t){const n=t.locale?.labels??{};return{...xP,...e??{},labelDayButton:pt(Ja,e?.labelDayButton,n.labelDayButton),labelMonthDropdown:pt(th,e?.labelMonthDropdown,n.labelMonthDropdown),labelNext:pt(oh,e?.labelNext,n.labelNext),labelPrevious:pt(rh,e?.labelPrevious,n.labelPrevious),labelWeekNumber:pt(ah,e?.labelWeekNumber,n.labelWeekNumber),labelYearDropdown:pt(lh,e?.labelYearDropdown,n.labelYearDropdown),labelGrid:pt(ei,e?.labelGrid,n.labelGrid),labelGridcell:pt(eh,e?.labelGridcell,n.labelGridcell),labelNav:pt(nh,e?.labelNav,n.labelNav),labelWeekNumberHeader:pt(ih,e?.labelWeekNumberHeader,n.labelWeekNumberHeader),labelWeekday:pt(sh,e?.labelWeekday,n.labelWeekday)}}function EP(e,t,n,o,r){const{startOfMonth:s,startOfYear:a,endOfYear:i,eachMonthOfInterval:c,getMonth:u}=r;return c({start:a(e),end:i(e)}).map(p=>{const h=o.formatMonthDropdown(p,r),m=u(p),v=t&&p<s(t)||n&&p>s(n)||!1;return{value:m,label:h,disabled:v}})}function CP(e,t={},n={}){let o={...t?.[oe.Day]};return Object.entries(e).filter(([,r])=>r===!0).forEach(([r])=>{o={...o,...n?.[r]}}),o}function SP(e,t,n,o){const r=o??e.today(),s=n?e.startOfBroadcastWeek(r,e):t?e.startOfISOWeek(r):e.startOfWeek(r),a=[];for(let i=0;i<7;i++){const c=e.addDays(s,i);a.push(c)}return a}function PP(e,t,n,o,r=!1){if(!e||!t)return;const{startOfYear:s,endOfYear:a,eachYearOfInterval:i,getYear:c}=o,u=s(e),d=a(t),f=i({start:u,end:d});return r&&f.reverse(),f.map(p=>{const h=n.formatYearDropdown(p,o);return{value:c(p),label:h,disabled:!1}})}const Po=e=>e instanceof HTMLElement?e:null,Ss=e=>[...e.querySelectorAll("[data-animated-month]")??[]],MP=e=>Po(e.querySelector("[data-animated-month]")),Ps=e=>Po(e.querySelector("[data-animated-caption]")),Ms=e=>Po(e.querySelector("[data-animated-weeks]")),TP=e=>Po(e.querySelector("[data-animated-nav]")),kP=e=>Po(e.querySelector("[data-animated-weekdays]"));function RP(e,t,{classNames:n,months:o,focused:r,dateLib:s}){const a=l.useRef(null),i=l.useRef(o),c=l.useRef(!1);l.useLayoutEffect(()=>{const u=i.current;if(i.current=o,!t||!e.current||!(e.current instanceof HTMLElement)||o.length===0||u.length===0||o.length!==u.length)return;const d=s.isSameMonth(o[0].date,u[0].date),f=s.isAfter(o[0].date,u[0].date),p=f?n[et.caption_after_enter]:n[et.caption_before_enter],h=f?n[et.weeks_after_enter]:n[et.weeks_before_enter],m=a.current,v=e.current.cloneNode(!0);if(v instanceof HTMLElement?(Ss(v).forEach(x=>{if(!(x instanceof HTMLElement))return;const S=MP(x);S&&x.contains(S)&&x.removeChild(S);const T=Ps(x);T&&T.classList.remove(p);const C=Ms(x);C&&C.classList.remove(h)}),a.current=v):a.current=null,c.current||d||r)return;const g=m instanceof HTMLElement?Ss(m):[],y=Ss(e.current);if(y?.every(b=>b instanceof HTMLElement)&&g&&g.every(b=>b instanceof HTMLElement)){c.current=!0,e.current.style.isolation="isolate";const b=TP(e.current);b&&(b.style.zIndex="1"),y.forEach((x,S)=>{const T=g[S];if(!T)return;x.style.position="relative",x.style.overflow="hidden";const C=Ps(x);C&&C.classList.add(p);const P=Ms(x);P&&P.classList.add(h);const _=()=>{c.current=!1,e.current&&(e.current.style.isolation=""),b&&(b.style.zIndex=""),C&&C.classList.remove(p),P&&P.classList.remove(h),x.style.position="",x.style.overflow="",x.contains(T)&&x.removeChild(T)};T.style.pointerEvents="none",T.style.position="absolute",T.style.overflow="hidden",T.setAttribute("aria-hidden","true");const O=kP(T);O&&(O.style.opacity="0");const I=Ps(T);I&&(I.classList.add(f?n[et.caption_before_exit]:n[et.caption_after_exit]),I.addEventListener("animationend",_));const $=Ms(T);$&&$.classList.add(f?n[et.weeks_before_exit]:n[et.weeks_after_exit]),x.insertBefore(T,x.firstChild)})}})}function DP(e,t,n,o){const r=e[0],s=e[e.length-1],{ISOWeek:a,fixedWeeks:i,broadcastCalendar:c}=n??{},{addDays:u,differenceInCalendarDays:d,differenceInCalendarMonths:f,endOfBroadcastWeek:p,endOfISOWeek:h,endOfMonth:m,endOfWeek:v,isAfter:g,startOfBroadcastWeek:y,startOfISOWeek:b,startOfWeek:x}=o,S=c?y(r,o):a?b(r):x(r),T=c?p(s):a?h(m(s)):v(m(s)),C=t&&(c?p(t):a?h(t):v(t)),P=C&&g(T,C)?C:T,_=d(P,S),O=f(s,r)+1,I=[];for(let W=0;W<=_;W++){const B=u(S,W);I.push(B)}const G=(c?35:42)*O;if(i&&I.length<G){const W=G-I.length;for(let B=0;B<W;B++){const K=u(I[I.length-1],1);I.push(K)}}return I}function IP(e){const t=[];return e.reduce((n,o)=>{const r=o.weeks.reduce((s,a)=>s.concat(a.days.slice()),t.slice());return n.concat(r.slice())},t.slice())}function OP(e,t,n,o){const{numberOfMonths:r=1}=n,s=[];for(let a=0;a<r;a++){const i=o.addMonths(e,a);if(t&&i>t)break;s.push(i)}return s}function tc(e,t,n,o){const{month:r,defaultMonth:s,today:a=o.today(),numberOfMonths:i=1}=e;let c=r||s||a;const{differenceInCalendarMonths:u,addMonths:d,startOfMonth:f}=o;if(n&&u(n,c)<i-1){const p=-1*(i-1);c=d(n,p)}return t&&u(c,t)<0&&(c=t),f(c)}function AP(e,t,n,o){const{addDays:r,endOfBroadcastWeek:s,endOfISOWeek:a,endOfMonth:i,endOfWeek:c,getISOWeek:u,getWeek:d,startOfBroadcastWeek:f,startOfISOWeek:p,startOfWeek:h}=o,m=e.reduce((v,g)=>{const y=n.broadcastCalendar?f(g,o):n.ISOWeek?p(g):h(g),b=n.broadcastCalendar?s(g):n.ISOWeek?a(i(g)):c(i(g)),x=t.filter(P=>P>=y&&P<=b),S=n.broadcastCalendar?35:42;if(n.fixedWeeks&&x.length<S){const P=t.filter(_=>{const O=S-x.length;return _>b&&_<=r(b,O)}
vendor: 8,788 bytes, line 38
38);x.push(...P)}const T=x.reduce((P,_)=>{const O=n.ISOWeek?u(_):d(_),I=P.find(G=>G.weekNumber===O),$=new Kp(_,g,o);return I?I.days.push($):P.push(new RS(O,[$])),P},[]),C=new kS(g,T);return v.push(C),v},[]);return n.reverseMonths?m.reverse():m}function _P(e,t){let{startMonth:n,endMonth:o}=e;const{startOfYear:r,startOfDay:s,startOfMonth:a,endOfMonth:i,addYears:c,endOfYear:u,newDate:d,today:f}=t,{fromYear:p,toYear:h,fromMonth:m,toMonth:v}=e;!n&&m&&(n=m),!n&&p&&(n=t.newDate(p,0,1)),!o&&v&&(o=v),!o&&h&&(o=d(h,11,31));const g=e.captionLayout==="dropdown"||e.captionLayout==="dropdown-years";return n?n=a(n):p?n=d(p,0,1):!n&&g&&(n=r(c(e.today??f(),-100))),o?o=i(o):h?o=d(h,11,31):!o&&g&&(o=u(e.today??f())),[n&&s(n),o&&s(o)]}function NP(e,t,n,o){if(n.disableNavigation)return;const{pagedNavigation:r,numberOfMonths:s=1}=n,{startOfMonth:a,addMonths:i,differenceInCalendarMonths:c}=o,u=r?s:1,d=a(e);if(!t)return i(d,u);if(!(c(t,e)<s))return i(d,u)}function $P(e,t,n,o){if(n.disableNavigation)return;const{pagedNavigation:r,numberOfMonths:s}=n,{startOfMonth:a,addMonths:i,differenceInCalendarMonths:c}=o,u=r?s??1:1,d=a(e);if(!t)return i(d,-u);if(!(c(d,t)<=0))return i(d,-u)}function FP(e){const t=[];return e.reduce((n,o)=>n.concat(o.weeks.slice()),t.slice())}function Fr(e,t){const[n,o]=l.useState(e);return[t===void 0?n:t,o]}function LP(e,t){const[n,o]=_P(e,t),{startOfMonth:r,endOfMonth:s}=t,a=tc(e,n,o,t),[i,c]=Fr(a,e.month?a:void 0);l.useEffect(()=>{const S=tc(e,n,o,t);c(S)},[e.timeZone]);const{months:u,weeks:d,days:f,previousMonth:p,nextMonth:h}=l.useMemo(()=>{const S=OP(i,o,{numberOfMonths:e.numberOfMonths},t),T=DP(S,e.endMonth?s(e.endMonth):void 0,{ISOWeek:e.ISOWeek,fixedWeeks:e.fixedWeeks,broadcastCalendar:e.broadcastCalendar},t),C=AP(S,T,{broadcastCalendar:e.broadcastCalendar,fixedWeeks:e.fixedWeeks,ISOWeek:e.ISOWeek,reverseMonths:e.reverseMonths},t),P=FP(C),_=IP(C),O=$P(i,n,e,t),I=NP(i,o,e,t);return{months:C,weeks:P,days:_,previousMonth:O,nextMonth:I}},[t,i.getTime(),o?.getTime(),n?.getTime(),e.disableNavigation,e.broadcastCalendar,e.endMonth?.getTime(),e.fixedWeeks,e.ISOWeek,e.numberOfMonths,e.pagedNavigation,e.reverseMonths]),{disableNavigation:m,onMonthChange:v}=e,g=S=>d.some(T=>T.days.some(C=>C.isEqualTo(S))),y=S=>{if(m)return;let T=r(S);n&&T<r(n)&&(T=r(n)),o&&T>r(o)&&(T=r(o)),c(T),v?.(T)};return{months:u,weeks:d,days:f,navStart:n,navEnd:o,previousMonth:p,nextMonth:h,goToMonth:y,goToDay:S=>{g(S)||y(S.date)}}}var Ct;(function(e){e[e.Today=0]="Today",e[e.Selected=1]="Selected",e[e.LastFocused=2]="LastFocused",e[e.FocusedModifier=3]="FocusedModifier"})(Ct||(Ct={}));function nc(e){return!e[Pe.disabled]&&!e[Pe.hidden]&&!e[Pe.outside]}function jP(e,t,n,o){let r,s=-1;for(const a of e){const i=t(a);nc(i)&&(i[Pe.focused]&&s<Ct.FocusedModifier?(r=a,s=Ct.FocusedModifier):o?.isEqualTo(a)&&s<Ct.LastFocused?(r=a,s=Ct.LastFocused):n(a.date)&&s<Ct.Selected?(r=a,s=Ct.Selected):i[Pe.today]&&s<Ct.Today&&(r=a,s=Ct.Today))}return r||(r=e.find(a=>nc(t(a)))),r}function BP(e,t,n,o,r,s,a){const{ISOWeek:i,broadcastCalendar:c}=s,{addDays:u,addMonths:d,addWeeks:f,addYears:p,endOfBroadcastWeek:h,endOfISOWeek:m,endOfWeek:v,max:g,min:y,startOfBroadcastWeek:b,startOfISOWeek:x,startOfWeek:S}=a;let C={day:u,week:f,month:d,year:p,startOfWeek:P=>c?b(P,a):i?x(P):S(P),endOfWeek:P=>c?h(P):i?m(P):v(P)}[e](n,t==="after"?1:-1);return t==="before"&&o?C=g([o,C]):t==="after"&&r&&(C=y([r,C])),C}function ch(e,t,n,o,r,s,a,i=0){if(i>365)return;const c=BP(e,t,n.date,o,r,s,a),u=!!(s.disabled&&At(c,s.disabled,a)),d=!!(s.hidden&&At(c,s.hidden,a)),f=c,p=new Kp(c,f,a);return!u&&!d?p:ch(e,t,p,o,r,s,a,i+1)}function VP(e,t,n,o,r){const{autoFocus:s}=e,[a,i]=l.useState(),c=jP(t.days,n,o||(()=>!1),a),[u,d]=l.useState(s?c:void 0);return{isFocusTarget:v=>!!c?.isEqualTo(v),setFocused:d,focused:u,blur:()=>{i(u),d(void 0)},moveFocus:(v,g)=>{if(!u)return;const y=ch(v,g,u,t.navStart,t.navEnd,e,r);y&&(e.disableNavigation&&!t.days.some(x=>x.isEqualTo(y))||(t.goToDay(y),d(y)))}}}function WP(e,t){const{selected:n,required:o,onSelect:r}=e,[s,a]=Fr(n,r?n:void 0),i=r?n:s,{isSameDay:c}=t,u=h=>i?.some(m=>c(m,h))??!1,{min:d,max:f}=e;return{selected:i,select:(h,m,v)=>{let g=[...i??[]];if(u(h)){if(i?.length===d||o&&i?.length===1)return;g=i?.filter(y=>!c(y,h))}else i?.length===f?g=[h]:g=[...g,h];return r||a(g),r?.(g,h,m,v),g},isSelected:u}}function HP(e,t,n=0,o=0,r=!1,s=Rt){const{from:a,to:i}=t||{},{isSameDay:c,isAfter:u,isBefore:d}=s;let f;if(!a&&!i)f={from:e,to:n>0?void 0:e};else if(a&&!i)c(a,e)?n===0?f={from:a,to:e}:r?f={from:a,to:void 0}:f=void 0:d(e,a)?f={from:e,to:a}:f={from:a,to:e};else if(a&&i)if(c(a,e)&&c(i,e))r?f={from:a,to:i}:f=void 0;else if(c(a,e))f={from:a,to:n>0?void 0:e};else if(c(i,e))f={from:e,to:n>0?void 0:e};else if(d(e,a))f={from:e,to:i};else if(u(e,a))f={from:a,to:e};else if(u(e,i))f={from:a,to:e};else throw new Error("Invalid range");if(f?.from&&f?.to){const p=s.differenceInCalendarDays(f.to,f.from);o>0&&p>o?f={from:e,to:void 0}:n>1&&p<n&&(f={from:e,to:void 0})}return f}function UP(e,t,n=Rt){const o=Array.isArray(t)?t:[t];let r=e.from;const s=n.differenceInCalendarDays(e.to,e.from),a=Math.min(s,6);for(let i=0;i<=a;i++){if(o.includes(r.getDay()))return!0;r=n.addDays(r,1)}return!1}function oc(e,t,n=Rt){return Ot(e,t.from,!1,n)||Ot(e,t.to,!1,n)||Ot(t,e.from,!1,n)||Ot(t,e.to,!1,n)}function GP(e,t,n=Rt){const o=Array.isArray(t)?t:[t];if(o.filter(i=>typeof i!="function").some(i=>typeof i=="boolean"?i:n.isDate(i)?Ot(e,i,!1,n):Zp(i,n)?i.some(c=>Ot(e,c,!1,n)):$r(i)?i.from&&i.to?oc(e,{from:i.from,to:i.to},n):!1:Xp(i)?UP(e,i.dayOfWeek,n):Xa(i)?n.isAfter(i.before,i.after)?oc(e,{from:n.addDays(i.after,1),to:n.addDays(i.before,-1)},n):At(e.from,i,n)||At(e.to,i,n):Za(i)||Qa(i)?At(e.from,i,n)||At(e.to,i,n):!1))return!0;const a=o.filter(i=>typeof i=="function");if(a.length){let i=e.from;const c=n.differenceInCalendarDays(e.to,e.from);for(let u=0;u<=c;u++){if(a.some(d=>d(i)))return!0;i=n.addDays(i,1)}}return!1}function YP(e,t){const{disabled:n,excludeDisabled:o,selected:r,required:s,onSelect:a}=e,[i,c]=Fr(r,a?r:void 0),u=a?r:i;return{selected:u,select:(p,h,m)=>{const{min:v,max:g}=e,y=p?HP(p,u,v,g,s,t):void 0;return o&&n&&y?.from&&y.to&&GP({from:y.from,to:y.to},n,t)&&(y.from=p,y.to=void 0),a||c(y),a?.(y,p,h,m),y},isSelected:p=>u&&Ot(u,p,!1,t)}}function zP(e,t){const{selected:n,required:o,onSelect:r}=e,[s,a]=Fr(n,r?n:void 0),i=r?n:s,{isSameDay:c}=t;return{selected:i,select:(f,p,h)=>{let m=f;return!o&&i&&i&&c(f,i)&&(m=void 0),r||a(m),r?.(m,f,p,h),m},isSelected:f=>i?c(i,f):!1}}function KP(e,t){const n=zP(e,t),o=WP(e,t),r=YP(e,t);switch(e.mode){case"single":return n;case"multiple":return o;case"range":return r;default:return}}function je(e,t){return e instanceof zo&&e.timeZone===t?e:new zo(e,t)}function rc(e,t){return typeof e=="boolean"||typeof e=="function"?e:e instanceof Date?je(e,t):Array.isArray(e)?e.map(n=>n instanceof Date?je(n,t):n):$r(e)?{...e,from:e.from?je(e.from,t):e.from,to:e.to?je(e.to,t):e.to}:Xa(e)?{before:je(e.before,t),after:je(e.after,t)}:Za(e)?{after:je(e.after,t)}:Qa(e)?{before:je(e.before,t)}:e}function Ts(e,t){return e&&(Array.isArray(e)?e.map(n=>rc(n,t)):rc(e,t))}function K2(e){let t=e;const n=t.timeZone;if(n&&(t={...e,timeZone:n},t.today&&(t.today=je(t.today,n)),t.month&&(t.month=je(t.month,n)),t.defaultMonth&&(t.defaultMonth=je(t.defaultMonth,n)),t.startMonth&&(t.startMonth=je(t.startMonth,n)),t.endMonth&&(t.endMonth=je(t.endMonth,n)),t.mode==="single"&&t.selected?t.selected=je(t.selected,n):t.mode==="multiple"&&t.selected?t.selected=t.selected?.map(se=>je(se,n)):t.mode==="range"&&t.selected&&(t.selected={from:t.selected.from?je(t.selected.from,n):t.selected.from,to:t.selected.to?je(t.selected.to,n):t.selected.to}),t.disabled!==void 0&&(t.disabled=Ts(t.disabled,n)),t.hidden!==void 0&&(t.hidden=Ts(t.hidden,n)),t.modifiers)){const se={};Object.keys(t.modifiers).forEach(be=>{se[be]=Ts(t.modifiers?.[be],n)}),t.modifiers=se}const{components:o,formatters:r,labels:s,dateLib:a,locale:i,classNames:c}=l.useMemo(()=>{const se={...zp,...t.locale},be=new nt({locale:se,weekStartsOn:t.broadcastCalendar?1:t.weekStartsOn,firstWeekContainsDate:t.firstWeekContainsDate,useAdditionalWeekYearTokens:t.useAdditionalWeekYearTokens,useAdditionalDayOfYearTokens:t.useAdditionalDayOfYearTokens,timeZone:t.timeZone,numerals:t.numerals},t.dateLib);return{dateLib:be,components:sP(t.components),formatters:vP(t.formatters),labels:wP(t.labels,be.options),locale:se,classNames:{...iP(),...t.classNames}}},[t.locale,t.broadcastCalendar,t.weekStartsOn,t.firstWeekContainsDate,t.useAdditionalWeekYearTokens,t.useAdditionalDayOfYearTokens,t.timeZone,t.numerals,t.dateLib,t.components,t.formatters,t.labels,t.classNames]);t.today||(t={...t,today:a.today()});const{captionLayout:u,mode:d,navLayout:f,numberOfMonths:p=1,onDayBlur:h,onDayCl
vendor: 5,374 bytes, line 38
38ick:m,onDayFocus:v,onDayKeyDown:g,onDayMouseEnter:y,onDayMouseLeave:b,onNextClick:x,onPrevClick:S,showWeekNumber:T,styles:C}=t,{formatCaption:P,formatDay:_,formatMonthDropdown:O,formatWeekNumber:I,formatWeekNumberHeader:$,formatWeekdayName:G,formatYearDropdown:W}=r,B=LP(t,a),{days:K,months:H,navStart:U,navEnd:q,previousMonth:R,nextMonth:D,goToMonth:L}=B,k=oP(K,t,U,q,a),{isSelected:M,select:F,selected:A}=KP(t,a)??{},{blur:z,focused:N,isFocusTarget:Y,moveFocus:te,setFocused:ae}=VP(t,B,k,M??(()=>!1),a),{labelDayButton:pe,labelGridcell:ee,labelGrid:ue,labelMonthDropdown:V,labelNav:Q,labelPrevious:me,labelNext:we,labelWeekday:Re,labelWeekNumber:ve,labelWeekNumberHeader:Fe,labelYearDropdown:Ft}=s,Se=l.useMemo(()=>SP(a,t.ISOWeek,t.broadcastCalendar,t.today),[a,t.ISOWeek,t.broadcastCalendar,t.today]),Le=d!==void 0||m!==void 0,We=l.useCallback(()=>{R&&(L(R),S?.(R))},[R,L,S]),qe=l.useCallback(()=>{D&&(L(D),x?.(D))},[L,D,x]),He=l.useCallback((se,be)=>ie=>{ie.preventDefault(),ie.stopPropagation(),ae(se),!be.disabled&&(F?.(se.date,be,ie),m?.(se.date,be,ie))},[F,m,ae]),lt=l.useCallback((se,be)=>ie=>{ae(se),v?.(se.date,be,ie)},[v,ae]),en=l.useCallback((se,be)=>ie=>{z(),h?.(se.date,be,ie)},[z,h]),Lt=l.useCallback((se,be)=>ie=>{const xe={ArrowLeft:[ie.shiftKey?"month":"day",t.dir==="rtl"?"after":"before"],ArrowRight:[ie.shiftKey?"month":"day",t.dir==="rtl"?"before":"after"],ArrowDown:[ie.shiftKey?"year":"week","after"],ArrowUp:[ie.shiftKey?"year":"week","before"],PageUp:[ie.shiftKey?"year":"month","before"],PageDown:[ie.shiftKey?"year":"month","after"],Home:["startOfWeek","before"],End:["endOfWeek","after"]};if(xe[ie.key]){ie.preventDefault(),ie.stopPropagation();const[Qe,Z]=xe[ie.key];te(Qe,Z)}g?.(se.date,be,ie)},[te,g,t.dir]),xt=l.useCallback((se,be)=>ie=>{y?.(se.date,be,ie)},[y]),gn=l.useCallback((se,be)=>ie=>{b?.(se.date,be,ie)},[b]),wt=l.useCallback(se=>be=>{const ie=Number(be.target.value),xe=a.setMonth(a.startOfMonth(se),ie);L(xe)},[a,L]),ct=l.useCallback(se=>be=>{const ie=Number(be.target.value),xe=a.setYear(a.startOfMonth(se),ie);L(xe)},[a,L]),{className:tn,style:yn}=l.useMemo(()=>({className:[c[oe.Root],t.className].filter(Boolean).join(" "),style:{...C?.[oe.Root],...t.style}}),[c,t.className,t.style,C]),Ao=aP(t),_o=l.useRef(null);RP(_o,!!t.animate,{classNames:c,months:H,focused:N,dateLib:a});const Yn={dayPickerProps:t,selected:A,select:F,isSelected:M,months:H,nextMonth:D,previousMonth:R,goToMonth:L,getModifiers:k,components:o,classNames:c,styles:C,labels:s,formatters:r};return w.createElement(qp.Provider,{value:Yn},w.createElement(o.Root,{rootRef:t.animate?_o:void 0,className:tn,style:yn,dir:t.dir,id:t.id,lang:t.lang,nonce:t.nonce,title:t.title,role:t.role,"aria-label":t["aria-label"],"aria-labelledby":t["aria-labelledby"],...Ao},w.createElement(o.Months,{className:c[oe.Months],style:C?.[oe.Months]},!t.hideNavigation&&!f&&w.createElement(o.Nav,{"data-animated-nav":t.animate?"true":void 0,className:c[oe.Nav],style:C?.[oe.Nav],"aria-label":Q(),onPreviousClick:We,onNextClick:qe,previousMonth:R,nextMonth:D}),H.map((se,be)=>w.createElement(o.Month,{"data-animated-month":t.animate?"true":void 0,className:c[oe.Month],style:C?.[oe.Month],key:be,displayIndex:be,calendarMonth:se},f==="around"&&!t.hideNavigation&&be===0&&w.createElement(o.PreviousMonthButton,{type:"button",className:c[oe.PreviousMonthButton],tabIndex:R?void 0:-1,"aria-disabled":R?void 0:!0,"aria-label":me(R),onClick:We,"data-animated-button":t.animate?"true":void 0},w.createElement(o.Chevron,{disabled:R?void 0:!0,className:c[oe.Chevron],orientation:t.dir==="rtl"?"right":"left"})),w.createElement(o.MonthCaption,{"data-animated-caption":t.animate?"true":void 0,className:c[oe.MonthCaption],style:C?.[oe.MonthCaption],calendarMonth:se,displayIndex:be},u?.startsWith("dropdown")?w.createElement(o.DropdownNav,{className:c[oe.Dropdowns],style:C?.[oe.Dropdowns]},(()=>{const ie=u==="dropdown"||u==="dropdown-months"?w.createElement(o.MonthsDropdown,{key:"month",className:c[oe.MonthsDropdown],"aria-label":V(),classNames:c,components:o,disabled:!!t.disableNavigation,onChange:wt(se.date),options:EP(se.date,U,q,r,a),style:C?.[oe.Dropdown],value:a.getMonth(se.date)}):w.createElement("span",{key:"month"},O(se.date,a)),xe=u==="dropdown"||u==="dropdown-years"?w.createElement(o.YearsDropdown,{key:"year",className:c[oe.YearsDropdown],"aria-label":Ft(a.options),classNames:c,components:o,disabled:!!t.disableNavigation,onChange:ct(se.date),options:PP(U,q,r,a,!!t.reverseYears),style:C?.[oe.Dropdown],value:a.getYear(se.date)}):w.createElement("span",{key:"year"},W(se.date,a));return a.getMonthYearOrder()==="year-first"?[xe,ie]:[ie,xe]})(),w.createElement("span",{role:"status","aria-live":"polite",style:{border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"absolute",width:"1px",whiteSpace:"nowrap",wordWrap:"normal"}},P(se.date,a.options,a))):w.createElement(o.CaptionLabel,{className:c[oe.CaptionLabel],role:"status","aria-live":"polite"},P(se.date,a.options,a))),f==="around"&&!t.hideNavigation&&be===p-1&&w.createElement(o.NextMonthButton,{type:"button",className:c[oe.NextMonthButton],tabIndex:D?void 0:-1,"aria-disabled":D?void 0:!0,"aria-label":we(D),onClick:qe,"data-animated-button":t.animate?"true":void 0},w.createElement(o.Chevron,{disabled:D?void 0:!0,className:c[oe.Chevron],orientation:t.dir==="rtl"?"left"
38:"right"})),be===p-1&&f==="after"&&!t.hideNavigation&&w.createElement(o.Nav,{"data-animated-nav":t.animate?"true":void 0,className:c[oe.Nav],style:C?.[oe.Nav],"aria-label":Q(),onPreviousClick:We,onNextClick:qe,previousMonth:R,nextMonth:D}),w.createElement(o.MonthGrid,{role:"grid","aria-multiselectable":d==="multiple"||d==="range","aria-label":ue(se.date,a.options,a)||void 0,className:c[oe.MonthGrid],style:C?.[oe.MonthGrid]},!t.hideWeekdays&&w.createElement(o.Weekdays,{"data-animated-weekdays":t.animate?"true":void 0,className:c[oe.Weekdays],style:C?.[oe.Weekdays]},T&&w.createElement(o.WeekNumberHeader,{"aria-label":Fe(a.options),className:c[oe.WeekNumberHeader],style:C?.[oe.WeekNumberHeader],scope:"col"},$()),Se.map(ie=>w.createElement(o.Weekday,{"aria-label":Re(ie,a.options,a),className:c[oe.Weekday],key:String(ie),style:C?.[oe.Weekday],scope:"col"},G(ie,a.options,a)))),w.createElement(o.Weeks,{"data-animated-weeks":t.animate?"true":void 0,className:c[oe.Weeks],style:C?.[oe.Weeks]},se.weeks.map(ie=>w.createElement(o.Week,{className:c[oe.Week],key:ie.weekNumber,style:C?.[oe.Week],week:ie},T&&w.createElement(o.WeekNumber,{week:ie,style:C?.[oe.WeekNumber],"aria-label":ve(ie.weekNumber,{locale:i}),className:c[oe.WeekNumber],scope:"row",role:"rowheader"},I(ie.weekNumber,a)),ie.days.map(xe=>{const{date:Qe}=xe,Z=k(xe);if(Z[Pe.focused]=!Z.hidden&&!!N?.isEqualTo(xe),Z[mt.selected]=M?.(Qe)||Z.selected,$r(A)){const{from:jt,to:Me}=A;Z[mt.range_start]=!!(jt&&Me&&a.isSameDay(Qe,jt)),Z[mt.range_end]=!!(jt&&Me&&a.isSameDay(Qe,Me)),Z[mt.range_middle]=Ot(A,Qe,!0,a)}const De=CP(Z,C,t.modifiersStyles),Ne=rP(Z,c,t.modifiersClassNames),Ue=!Le&&!Z.hidden?ee(Qe,Z,a.options,a):void 0;return w.createElement(o.Day,{key:`${xe.isoDate}_${xe.displayMonthId}`,day:xe,modifiers:Z,className:Ne.join(" "),style:De,role:"gridcell","aria-selected":Z.selected||void 0,"aria-label":Ue,"data-day":xe.isoDate,"data-month":xe.outside?xe.dateMonthId:void 0,"data-selected":Z.selected||void 0,"data-disabled":Z.disabled||void 0,"data-hidden":Z.hidden||void 0,"data-outside":xe.outside||void 0,"data-focused":Z.focused||void 0,"data-today":Z.today||void 0},!Z.hidden&&Le?w.createElement(o.DayButton,{className:c[oe.DayButton],style:C?.[oe.DayButton],type:"button",day:xe,modifiers:Z,disabled:!Z.focused&&Z.disabled||void 0,"aria-disabled":Z.focused&&Z.disabled||void 0,tabIndex:Y(xe)?0:-1,"aria-label":pe(Qe,Z,a.options,a),onClick:He(xe,Z),onBlur:en(xe,Z),onFocus:lt(xe,Z),onKeyDown:Lt(xe,Z),onMouseEnter:xt(xe,Z),onMouseLeave:gn(xe,Z)},_(Qe,a.options,a)):!Z.hidden&&_(xe.date,a.options,a))})))))))),t.footer&&w.createElement(o.Footer,{className:c[oe.Footer],style:C?.[oe.Footer],role:"status","aria-live":"polite"},t.footer)))}var qP=Object.defineProperty,XP=(e,t,n)=>t in e?qP(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ks=(e,t,n)=>(XP(e,typeof t!="symbol"?t+"":t,n),n);let ZP=class{constructor(){ks(this,"current",this.detect()),ks(this,"handoffState","pending"),ks(this,"currentId",0)}set(t){this.current!==t&&(this.handoffState="pending",this.currentId=0,this.current=t)}reset(){this.set(this.detect())}nextId(){return++this.currentId}get isServer(){return this.current==="server"}get isClient(){return this.current==="client"}detect(){return typeof window>"u"||typeof document>"u"?"server":"client"}handoff(){this.handoffState==="pending"&&(this.handoffState="complete")}get isHandoffComplete(){return this.handoffState==="complete"}},ln=new ZP;function Dt(e){return ln.isServer?null:e instanceof Node?e.ownerDocument:e!=null&&e.hasOwnProperty("current")&&e.current instanceof Node?e.current.ownerDocument:document}function Mo(e){typeof queueMicrotask=="function"?queueMicrotask(e):Promise.resolve().then(e).catch(t=>setTimeout(()=>{throw t}))}function gt(){let e=[],t={addEventListener(n,o,r,s){return n.addEventListener(o,r,s),t.add(()=>n.removeEventListener(o,r,s))},requestAnimationFrame(...n){let o=requestAnimationFrame(...n);return t.add(()=>cancelAnimationFrame(o))},nextFrame(...n){return t.requestAnimationFrame(()=>t.requestAnimationFrame(...n))},setTimeout(...n){let o=setTimeout(...n);return t.add(()=>clearTimeout(o))},microTask(...n){let o={current:!0};return Mo(()=>{o.current&&n[0]()}),t.add(()=>{o.current=!1})},style(n,o,r){let s=n.style.getPropertyValue(o);
vendor: 24,094 bytes, lines 38-41
38return Object.assign(n.style,{[o]:r}),this.add(()=>{Object.assign(n.style,{[o]:s})})},group(n){let o=gt();return n(o),this.add(()=>o.dispose())},add(n){return e.includes(n)||e.push(n),()=>{let o=e.indexOf(n);if(o>=0)for(let r of e.splice(o,1))r()}},dispose(){for(let n of e.splice(0))n()}};return t}function It(){let[e]=l.useState(gt);return l.useEffect(()=>()=>e.dispose(),[e]),e}let ce=(e,t)=>{ln.isServer?l.useEffect(e,t):l.useLayoutEffect(e,t)};function Ye(e){let t=l.useRef(e);return ce(()=>{t.current=e},[e]),t}let j=function(e){let t=Ye(e);return w.useCallback((...n)=>t.current(...n),[t])};function QP(e){let t=e.width/2,n=e.height/2;return{top:e.clientY-n,right:e.clientX+t,bottom:e.clientY+n,left:e.clientX-t}}function JP(e,t){return!(!e||!t||e.right<t.left||e.left>t.right||e.bottom<t.top||e.top>t.bottom)}function Fn({disabled:e=!1}={}){let t=l.useRef(null),[n,o]=l.useState(!1),r=It(),s=j(()=>{t.current=null,o(!1),r.dispose()}),a=j(i=>{if(r.dispose(),t.current===null){t.current=i.currentTarget,o(!0);{let c=Dt(i.currentTarget);r.addEventListener(c,"pointerup",s,!1),r.addEventListener(c,"pointermove",u=>{if(t.current){let d=QP(u);o(JP(d,t.current.getBoundingClientRect()))}},!1),r.addEventListener(c,"pointercancel",s,!1)}}});return{pressed:n,pressProps:e?{}:{onPointerDown:a,onPointerUp:s,onClick:s}}}let eM=l.createContext(void 0);function To(){return l.useContext(eM)}function na(...e){return Array.from(new Set(e.flatMap(t=>typeof t=="string"?t.split(" "):[]))).filter(Boolean).join(" ")}function ge(e,t,...n){if(e in t){let r=t[e];return typeof r=="function"?r(...n):r}let o=new Error(`Tried to handle "${e}" but there is no handler defined. Only defined handlers are: ${Object.keys(t).map(r=>`"${r}"`).join(", ")}.`);throw Error.captureStackTrace&&Error.captureStackTrace(o,ge),o}var Ve=(e=>(e[e.None=0]="None",e[e.RenderStrategy=1]="RenderStrategy",e[e.Static=2]="Static",e))(Ve||{}),Wt=(e=>(e[e.Unmount=0]="Unmount",e[e.Hidden=1]="Hidden",e))(Wt||{});function fe(){let e=nM();return l.useCallback(t=>tM({mergeRefs:e,...t}),[e])}function tM({ourProps:e,theirProps:t,slot:n,defaultTag:o,features:r,visible:s=!0,name:a,mergeRefs:i}){i=i??oM;let c=uh(t,e);if(s)return Vo(c,n,o,a,i);let u=r??0;if(u&2){let{static:d=!1,...f}=c;if(d)return Vo(f,n,o,a,i)}if(u&1){let{unmount:d=!0,...f}=c;return ge(d?0:1,{0(){return null},1(){return Vo({...f,hidden:!0,style:{display:"none"}},n,o,a,i)}})}return Vo(c,n,o,a,i)}function Vo(e,t={},n,o,r){let{as:s=n,children:a,refName:i="ref",...c}=Rs(e,["unmount","static"]),u=e.ref!==void 0?{[i]:e.ref}:{},d=typeof a=="function"?a(t):a;"className"in c&&c.className&&typeof c.className=="function"&&(c.className=c.className(t)),c["aria-labelledby"]&&c["aria-labelledby"]===c.id&&(c["aria-labelledby"]=void 0);let f={};if(t){let p=!1,h=[];for(let[m,v]of Object.entries(t))typeof v=="boolean"&&(p=!0),v===!0&&h.push(m.replace(/([A-Z])/g,g=>`-${g.toLowerCase()}`));if(p){f["data-headlessui-state"]=h.join(" ");for(let m of h)f[`data-${m}`]=""}}if(s===l.Fragment&&(Object.keys(Vt(c)).length>0||Object.keys(Vt(f)).length>0))if(!l.isValidElement(d)||Array.isArray(d)&&d.length>1){if(Object.keys(Vt(c)).length>0)throw new Error(['Passing props on "Fragment"!',"",`The current component <${o} /> is rendering a "Fragment".`,"However we need to passthrough the following props:",Object.keys(Vt(c)).concat(Object.keys(Vt(f))).map(p=>`  - ${p}`).join(`
39`),"","You can apply a few solutions:",['Add an `as="..."` prop, to ensure that we render an actual element instead of a "Fragment".',"Render a single element as the child so that we can forward the props onto that element."].map(p=>`  - ${p}`).join(`
40`)].join(`
41`))}else{let p=d.props,h=p?.className,m=typeof h=="function"?(...y)=>na(h(...y),c.className):na(h,c.className),v=m?{className:m}:{},g=uh(d.props,Vt(Rs(c,["ref"])));for(let y in f)y in g&&delete f[y];return l.cloneElement(d,Object.assign({},g,f,u,{ref:r(rM(d),u.ref)},v))}return l.createElement(s,Object.assign({},Rs(c,["ref"]),s!==l.Fragment&&u,s!==l.Fragment&&f),d)}function nM(){let e=l.useRef([]),t=l.useCallback(n=>{for(let o of e.current)o!=null&&(typeof o=="function"?o(n):o.current=n)},[]);return(...n)=>{if(!n.every(o=>o==null))return e.current=n,t}}function oM(...e){return e.every(t=>t==null)?void 0:t=>{for(let n of e)n!=null&&(typeof n=="function"?n(t):n.current=t)}}function uh(...e){if(e.length===0)return{};if(e.length===1)return e[0];let t={},n={};for(let o of e)for(let r in o)r.startsWith("on")&&typeof o[r]=="function"?(n[r]!=null||(n[r]=[]),n[r].push(o[r])):t[r]=o[r];if(t.disabled||t["aria-disabled"])for(let o in n)/^(on(?:Click|Pointer|Mouse|Key)(?:Down|Up|Press)?)$/.test(o)&&(n[o]=[r=>{var s;return(s=r?.preventDefault)==null?void 0:s.call(r)}]);for(let o in n)Object.assign(t,{[o](r,...s){let a=n[o];for(let i of a){if((r instanceof Event||r?.nativeEvent instanceof Event)&&r.defaultPrevented)return;i(r,...s)}}});return t}function ot(...e){if(e.length===0)return{};if(e.length===1)return e[0];let t={},n={};for(let o of e)for(let r in o)r.startsWith("on")&&typeof o[r]=="function"?(n[r]!=null||(n[r]=[]),n[r].push(o[r])):t[r]=o[r];for(let o in n)Object.assign(t,{[o](...r){let s=n[o];for(let a of s)a?.(...r)}});return t}function le(e){var t;return Object.assign(l.forwardRef(e),{displayName:(t=e.displayName)!=null?t:e.name})}function Vt(e){let t=Object.assign({},e);for(let n in t)t[n]===void 0&&delete t[n];return t}function Rs(e,t=[]){let n=Object.assign({},e);for(let o of t)o in n&&delete n[o];return n}function rM(e){return w.version.split(".")[0]>="19"?e.props.ref:e.ref}function ti(e,t,n){let[o,r]=l.useState(n),s=e!==void 0,a=l.useRef(s),i=l.useRef(!1),c=l.useRef(!1);return s&&!a.current&&!i.current?(i.current=!0,a.current=s,console.error("A component is changing from uncontrolled to controlled. This may be caused by the value changing from undefined to a defined value, which should not happen.")):!s&&a.current&&!c.current&&(c.current=!0,a.current=s,console.error("A component is changing from controlled to uncontrolled. This may be caused by the value changing from a defined value to undefined, which should not happen.")),[s?e:o,j(u=>(s||r(u),t?.(u)))]}function ni(e){let[t]=l.useState(e);return t}function dh(e={},t=null,n=[]){for(let[o,r]of Object.entries(e))ph(n,fh(t,o),r);return n}function fh(e,t){return e?e+"["+t+"]":t}function ph(e,t,n){if(Array.isArray(n))for(let[o,r]of n.entries())ph(e,fh(t,o.toString()),r);else n instanceof Date?e.push([t,n.toISOString()]):typeof n=="boolean"?e.push([t,n?"1":"0"]):typeof n=="string"?e.push([t,n]):typeof n=="number"?e.push([t,`${n}`]):n==null?e.push([t,""]):dh(n,t,e)}function hh(e){var t,n;let o=(t=e?.form)!=null?t:e.closest("form");if(o){for(let r of o.elements)if(r!==e&&(r.tagName==="INPUT"&&r.type==="submit"||r.tagName==="BUTTON"&&r.type==="submit"||r.nodeName==="INPUT"&&r.type==="image")){r.click();return}(n=o.requestSubmit)==null||n.call(o)}}let sM="span";var Tt=(e=>(e[e.None=1]="None",e[e.Focusable=2]="Focusable",e[e.Hidden=4]="Hidden",e))(Tt||{});function aM(e,t){var n;let{features:o=1,...r}=e,s={ref:t,"aria-hidden":(o&2)===2?!0:(n=r["aria-hidden"])!=null?n:void 0,hidden:(o&4)===4?!0:void 0,style:{position:"fixed",top:1,left:1,width:1,height:0,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0",...(o&4)===4&&(o&2)!==2&&{display:"none"}}};return fe()({ourProps:s,theirProps:r,slot:{},defaultTag:sM,name:"Hidden"})}let kt=le(aM),iM=l.createContext(null);function lM({children:e}){let t=l.useContext(iM);if(!t)return w.createElement(w.Fragment,null,e);let{target:n}=t;return n?Te.createPortal(w.createElement(w.Fragment,null,e),n):null}function oi({data:e,form:t,disabled:n,onReset:o,overrides:r}){let[s,a]=l.useState(null),i=It();return l.useEffect(()=>{if(o&&s)return i.addEventListener(s,"reset",o)},[s,t,o]),w.createElement(lM,null,w.createElement(cM,{setForm:a,formId:t}),dh(e).map(([c,u])=>w.createElement(kt,{features:Tt.Hidden,...Vt({key:c,as:"input",type:"hidden",hidden:!0,readOnly:!0,form:t,disabled:n,name:c,value:u,...r})})))}function cM({setForm:e,formId:t}){return l.useEffect(()=>{if(t){let n=document.getElementById(t);n&&e(n)}},[e,t]),t?null:w.createElement(kt,{features:Tt.Hidden,as:"input",type:"hidden",hidden:!0,readOnly:!0,ref:n=>{if(!n)return;let o=n.closest("form");o&&e(o)}})}let uM=l.createContext(void 0);function Lr(){return l.useContext(uM)}function Ln(e){let t=e.parentElement,n=null;for(;t&&!(t instanceof HTMLFieldSetElement);)t instanceof HTMLLegendElement&&(n=t),t=t.parentElement;let o=t?.getAttribute("disabled")==="";return o&&dM(n)?!1:o}function dM(e){if(!e)return!1;let t=e.previousElementSibling;for(;t!==null;){if(t instanceof HTMLLegendElement)return!1;t=t.previousElementSibling}return!0}let mh=Symbol();function ri(e,t=!0){return Object.assign(e,{[mh]:t})}function ye(...e){let t=l.useRef(e);l.useEffect(()=>{t.current=e},[e]);let n=j(o=>{for(let r of t.current)r!=null&&(typeof r=="function"?r(o):r.current=o)});return e.every(o=>o==null||o?.[mh])?void 0:n}let jr=l.createContext(null);jr.displayName="DescriptionContext";function vh(){let e=l.useContext(jr);if(e===null){let t=new Error("You used a <Description /> component, but it is not inside a relevant parent.");throw Error.captureStackTrace&&Error.captureStackTrace(t,vh),t}return e}function si(){var e,t;return(t=(e=l.useContext(jr))==null?void 0:e.value)!=null?t:void 0}function gh(){let[e,t]=l.useState([]);return[e.length>0?e.join(" "):void 0,l.useMemo(()=>function(n){let o=j(s=>(t(a=>[...a,s]),()=>t(a=>{let i=a.slice(),c=i.indexOf(s);return c!==-1&&i.splice(c,1),i}))),r=l.useMemo(()=>({register:o,slot:n.slot,name:n.name,props:n.props,value:n.value}),[o,n.slot,n.name,n.props,n.value]);return w.createElement(jr.Provider,{value:r},n.children)},[t])]}let fM="p";function pM(e,t){let n=l.useId(),o=To(),{id:r=`headlessui-description-${n}`,...s}=e,a=vh(),i=ye(t);ce(()=>a.register(r),[r,a.register]);let c=o||!1,u=l.useMemo(()=>({...a.slot,disabled:c}),[a.slot,c]),d={ref:i,...a.props,id:r};return fe()({ourProps:d,theirProps:s,slot:u,defaultTag:fM,name:a.name||"Description"})}let hM=le(pM),yh=Object.assign(hM,{});var ne=(e=>(e.Space=" ",e.Enter="Enter",e.Escape="Escape",e.Backspace="Backspace",e.Delete="Delete",e.ArrowLeft="ArrowLeft",e.ArrowUp="ArrowUp",e.ArrowRight="ArrowRight",e.ArrowDown="ArrowDown",e.Home="Home",e.End="End",e.PageUp="PageUp",e.PageDown="PageDown",e.Tab="Tab",e))(ne||{});let Br=l.createContext(null);Br.displayName="LabelContext";function bh(){let e=l.useContext(Br);if(e===null){let t=new Error("You used a <Label /> component, but it is not inside a relevant parent.");throw Error.captureStackTrace&&Error.captureStackTrace(t,bh),t}return e}function jn(e){var t,n,o;let r=(n=(t=l.useContext(Br))==null?void 0:t.value)!=null?n:void 0;return((o=e?.length)!=null?o:0)>0?[r,...e].filter(Boolean).join(" "):r}function ai({inherit:e=!1}={}){let t=jn(),[n,o]=l.useState([]),r=e?[t,...n].filter(Boolean):n;return[r.length>0?r.join(" "):void 0,l.useMemo(()=>function(s){let a=j(c=>(o(u=>[...u,c]),()=>o(u=>{let d=u.slice(),f=d.indexOf(c);return f!==-1&&d.splice(f,1),d}))),i=l.useMemo(()=>({register:a,slot:s.slot,name:s.name,props:s.props,value:s.value}),[a,s.slot,s.name,s.props,s.value]);return w.createElement(Br.Provider,{value:i},s.children)},[o])]}let mM="label";function vM(e,t){var n;let o=l.useId(),r=bh(),s=Lr(),a=To(),{id:i=`headlessui-label-${o}`,htmlFor:c=s??((n=r.props)==null?void 0:n.htmlFor),passive:u=!1,...d}=e,f=ye(t);ce(()=>r.register(i),[i,r.register]);let p=j(g=>{let y=g.currentTarget;if(y instanceof HTMLLabelElement&&g.preventDefault(),r.props&&"onClick"in r.props&&typeof r.props.onClick=="function"&&r.props.onClick(g),y instanceof HTMLLabelElement){let b=document.getElementById(y.htmlFor);if(b){let x=b.getAttribute("disabled");if(x==="true"||x==="")return;let S=b.getAttribute("aria-disabled");if(S==="true"||S==="")return;(b instanceof HTMLInputElement&&(b.type==="radio"||b.type==="checkbox")||b.role==="radio"||b.role==="checkbox"||b.role==="switch")&&b.click(),b.focus({preventScroll:!0})}}}),h=a||!1,m=l.useMemo(()=>({...r.slot,disabled:h}),[r.slot,h]),v={ref:f,...r.props,id:i,htmlFor:c,onClick:p};return u&&("onClick"in v&&(delete v.htmlFor,delete v.onClick),"onClick"in d&&delete d.onClick),fe()({ourProps:v,theirProps:d,slot:m,defaultTag:c?mM:"div",name:r.name||"Label"})}let gM=le(vM),ii=Object.assign(gM,{}),yM=l.createContext(()=>{});function li({value:e,children:t}){return w.createElement(yM.Provider,{value:e},t)}function bM(e,t){return e!==null&&t!==null&&typeof e=="object"&&typeof t=="object"&&"id"in e&&"id"in t?e.id===t.id:e===t}function xh(e=bM){return l.useCallback((t,n)=>{if(typeof e=="string"){let o=e;return t?.[o]===n?.[o]}return e(t,n)},[e])}function xM(e){if(e===null)return{width:0,height:0};let{width:t,height:n}=e.getBoundingClientRect();return{width:t,height:n}}function rr(e,t=!1){let[n,o]=l.useReducer(()=>({}),{}),r=l.useMemo(()=>xM(e),[e,n]);return ce(()=>{if(!e)return;let s=new ResizeObserver(o);return s.observe(e),()=>{s.disconnect()}},[e]),t?{width:`${r.width}px`,height:`${r.height}px`}:r}let wM=class extends Map{constructor(t){super(),this.factory=t}get(t){let n=super.get(t);return n===void 0&&(n=this.factory(t),this.set(t,n)),n}};function wh(e,t){let n=e(),o=new Set;return{getSnapshot(){return n},subscribe(r){return o.add(r),()=>o.delete(r)},dispatch(r,...s){let a=t[r].call(n,...s);a&&(n=a,o.forEach(i=>i()))}}}function Eh(e){return l.useSyncExternalStore(e.subscribe,e.getSnapshot,e.getSnapshot)}let EM=new wM(()=>wh(()=>[],{ADD(e){return this.includes(e)?this:[...this,e]},REMOVE(e){let t=this.indexOf(e);if(t===-1)return this;let n=this.slice();return n.splice(t,1),n}}));function Bn(e,t){let n=EM.get(t),o=l.useId(),r=Eh(n);if(ce(()=>{if(e)return n.dispatch("ADD",o),()=>n.dispatch("REMOVE",o)},[n,e]),!e)return!1;let s=r.indexOf(o),a=r.length;return s===-1&&(s=a,a+=1),s===a-1}let oa=new Map,ro=new Map;function sc(e){var t;let n=(t=ro.get(e))!=null?t:0;return ro.set(e,n+1),n!==0?()=>ac(e):(oa.set(e,{"aria-hidden":e.getAttribute("aria-hidden"),inert:e.inert}),e.setAttribute("aria-hidden","true"),e.inert=!0,()=>ac(e))}function ac(e){var t;let n=(t=ro.get(e))!=null?t:1;if(n===1?ro.delete(e):ro.set(e,n-1),n!==1)return;let o=oa.get(e);o&&(o["aria-hidden"]===null?e.removeAttribute("aria-hidden"):e.setAttribute("aria-hidden",o["aria-hidden"]),e.inert=o.inert,oa.delete(e))}function ci(e,{allowed:t,disallowed:n}={}){let o=Bn(e,"inert-others");ce(()=>{var r,s;if(!o)return;let a=gt();for(let c of(r=n?.())!=null?r:[])c&&a.add(sc(c));let i=(s=t?.())!=null?s:[];for(let c of i){if(!c)continue;let u=Dt(c);if(!u)continue;let d=c.parentElement;for(;d&&d!==u.body;){for(let f of d.children)i.some(p=>f.contains(p))||a.add(sc(f));d=d.parentElement}}return a.dispose},[o,t,n])}function Vr(e,t,n){let o=Ye(r=>{let s=r.getBoundingClientRect();s.x===0&&s.y===0&&s.width===0&&s.height===0&&n()});l.useEffect(()=>{if(!e)return;let r=t===null?null:t instanceof HTMLElement?t:t.current;if(!r)return;let s=gt();if(typeof ResizeObserver<"u"){let a=new ResizeObserver(()=>o.current(r));a.observe(r),s.add(()=>a.disconnect())}if(typeof IntersectionObserver<"u"){let a=new IntersectionObserver(()=>o.current(r));a.observe(r),s.add(()=>a.disconnect())}return()=>s.dispose()},[t,o,e])}let sr=["[contentEditable=true]","[tabindex]","a[href]","area[href]","button:not([disabled])","iframe","input:not([disabled])","select:not([disabled])","textarea:not([disabled])"].map(e=>`${e}:not([tabindex='-1'])`).join(","),CM=["[data-autofocus]"].map(e=>`${e}:not([tabindex='-1'])`).join(",");var Ee=(e=>(e[e.First=1]="First",e[e.Previous=2]="Previous",e[e.Next=4]="Next",e[e.Last=8]="Last",e[e.WrapAround=16]="WrapAround",e[e.NoScroll=32]="NoScroll",e[e.AutoFocus=64]="AutoFocus",e))(Ee||{}),Pt=(e=>(e[e.Error=0]="Error",e[e.Overflow=1]="Overflow",e[e.Success=2]="Success",e[e.Underflow=3]="Underflow",e))(Pt||{}),SM=(e=>(e[e.Previous=-1]="Previous",e[e.Next=1]="Next",e))(SM||{});function ko(e=document.body){return e==null?[]:Array.from(e.querySelectorAll(sr)).sort((t,n)=>Math.sign((t.tabIndex||Number.MAX_SAFE_INTEGER)-(n.tabIndex||Number.MAX_SAFE_INTEGER)))}function PM(e=document.body){return e==null?[]:Array.from(e.querySelectorAll(CM)).sort((t,n)=>Math.sign((t.tabIndex||Number.MAX_SAFE_INTEGER)-(n.tabIndex||Number.MAX_SAFE_INTEGER)))}var Wr=(e=>(e[e.Strict=0]="Strict",e[e.Loose=1]="Loose",e))(Wr||{});function ui(e,t=0){var n;return e===((n=Dt(e))==null?void 0:n.body)?!1:ge(t,{0(){return e.matches(sr)},1(){let o=e;for(;o!==null;){if(o.matches(sr))return!0;o=o.parentElement}return!1}})}var MM=(e=>(e[e.Keyboard=0]="Keyboard",e[e.Mouse=1]="Mouse",e))(MM||{});typeof window<"u"&&typeof document<"u"&&(document.addEventListener("keydown",e=>{e.metaKey||e.altKey||e.ctrlKey||(document.documentElement.dataset.headlessuiFocusVisible="")},!0),document.addEventListener("click",e=>{e.detail===1?delete document.documentElement.dataset.headlessuiFocusVisible:e.detail===0&&(document.documentElement.dataset.headlessuiFocusVisible="")},!0));function _t(e){e?.focus({preventScroll:!0})}let TM=["textarea","input"].join(",");function kM(e){var t,n;return(n=(t=e?.matches)==null?void 0:t.call(e,TM))!=null?n:!1}function Ht(e,t=n=>n){return e.slice().sort((n,o)=>{let r=t(n),s=t(o);if(r===null||s===null)return 0;let a=r.compareDocumentPosition(s);return a&Node.DOCUMENT_POSITION_FOLLOWING?-1:a&Node.DOCUMENT_POSITION_PRECEDING?1:0})}function RM(e,t){return Ae(ko(),t,{relativeTo:e})}function Ae(e,t,{sorted:n=!0,relativeTo:o=null,skipElements:r=[]}={}){let s=Array.isArray(e)?e.length>0?e[0].ownerDocument:document:e.ownerDocument,a=Array.isArray(e)?n?Ht(e):e:t&64?PM(e):ko(e);r.length>0&&a.length>1&&(a=a.filter(h=>!r.some(m=>m!=null&&"current"in m?m?.current===h:m===h))),o=o??s.activeElement;let i=(()=>{if(t&5)return 1;if(t&10)return-1;throw new Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),c=(()=>{if(t&1)return 0;if(t&2)return Math.max(0,a.indexOf(o))-1;if(t&4)return Math.max(0,a.indexOf(o))+1;if(t&8)return a.length-1;throw new Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),u=t&32?{preventScroll:!0}:{},d=0,f=a.length,p;do{if(d>=f||d+f<=0)return 0;let h=c+d;if(t&16)h=(h+f)%f;else{if(h<0)return 3;if(h>=f)return 1}p=a[h],p?.focus(u),d+=i}while(p!==s.activeElement);return t&6&&kM(p)&&p.select(),2}function Ch(){return/iPhone/gi.test(window.navigator.platform)||/Mac/gi.test(window.navigator.platform)&&window.navigator.maxTouchPoints>0}function DM(){return/Android/gi.test(window.navigator.userAgent)}function Sh(){return Ch()||DM()}function Zn(e,t,n,o){let r=Ye(n);l.useEffect(()=>{if(!e)return;function s(a){r.current(a)}return document.addEventListener(t,s,o),()=>document.removeEventListener(t,s,o)},[e,t,o])}function Ph(e,t,n,o){let r=Ye(n);l.useEffect(()=>{if(!e)return;function s(a){r.current(a)}return window.addEventListener(t,s,o),()=>window.removeEventListener(t,s,o)},[e,t,o])}const ic=30;function Hr(e,t,n){let o=Bn(e,"outside-click"),r=Ye(n),s=l.useCallback(function(c,u){if(c.defaultPrevented)return;let d=u(c);if(d===null||!d.getRootNode().contains(d)||!d.isConnected)return;let f=(function p(h){return typeof h=="function"?p(h()):Array.isArray(h)||h instanceof Set?h:[h]})(t);for(let p of f)if(p!==null&&(p.contains(d)||c.composed&&c.composedPath().includes(p)))return;return!ui(d,Wr.Loose)&&d.tabIndex!==-1&&c.preventDefault(),r.current(c,d)},[r,t]),a=l.useRef(null);Zn(o,"pointerdown",c=>{var u,d;a.current=((d=(u=c.composedPath)==null?void 0:u.call(c))==null?void 0:d[0])||c.target},!0),Zn(o,"mousedown",c=>{var u,d;a.current=((d=(u=c.composedPath)==null?void 0:u.call(c))==null?void 0:d[0])||c.target},!0),Zn(o,"click",c=>{Sh()||a.current&&(s(c,()=>a.current),a.current=null)},!0);let i=l.useRef({x:0,y:0});Zn(o,"touchstart",c=>{i.current.x=c.touches[0].clientX,i.current.y=c.touches[0].clientY},!0),Zn(o,"touchend",c=>{let u={x:c.changedTouches[0].clientX,y:c.changedTouches[0].clientY};if(!(Math.abs(u.x-i.current.x)>=ic||Math.abs(u.y-i.current.y)>=ic))return s(c,()=>c.target instanceof HTMLElement?c.target:null)},!0),Ph(o,"blur",c=>s(c,()=>window.document.activeElement instanceof HTMLIFrameElement?window.document.activeElement:null),!0)}function bt(...e){return l.useMemo(()=>Dt(...e),[...e])}function Ur(e,t,n,o){let r=Ye(n);l.useEffect(()=>{e=e??window;function s(a){r.current(a)}return e.addEventListener(t,s,o),()=>e.removeEventListener(t,s,o)},[e,t,o])}function Mh(e){let t=l.useRef({value:"",selectionStart:null,selectionEnd:null});return Ur(e,"blur",n=>{let o=n.target;o instanceof HTMLInputElement&&(t.current={value:o.value,selectionStart:o.selectionStart,selectionEnd:o.selectionEnd})}),j(()=>{if(document.activeElement!==e&&e instanceof HTMLInputElement&&e.isConnected){if(e.focus({preventScroll:!0}),e.value!==t.current.value)e.setSelectionRange(e.value.length,e.value.length);else{let{selectionStart:n,selectionEnd:o}=t.current;n!==null&&o!==null&&e.setSelectionRange(n,o)}t.current={value:"",selectionStart:null,selectionEnd:null}}})}function Vn(e,t){return l.useMemo(()=>{var n;if(e.type)return e.type;let o=(n=e.as)!=null?n:"button";if(typeof o=="string"&&o.toLowerCase()==="button"||t?.tagName==="BUTTON"&&!t.hasAttribute("type"))return"button"},[e.type,e.as,t])}function IM(){let e;return{before({doc:t}){var n;let o=t.documentElement,r=(n=t.defaultView)!=null?n:window;e=Math.max(0,r.innerWidth-o.clientWidth)},after({doc:t,d:n}){let o=t.documentElement,r=Math.max(0,o.clientWidth-o.offsetWidth),s=Math.max(0,e-r);n.style(o,"paddingRight",`${s}px`)}}}function OM(){return Ch()?{before({doc:e,d:t,meta:n}){function o(r){return n.containers.flatMap(s=>s()).some(s=>s.contains(r))}t.microTask(()=>{var r;if(window.getComputedStyle(e.documentElement).scrollBehavior!=="auto"){let i=gt();i.style(e.documentElement,"scrollBehavior","auto"),t.add(()=>t.microTask(()=>i.dispose()))}let s=(r=window.scrollY)!=null?r:window.pageYOffset,a=null;t.addEventListener(e,"click",i=>{if(i.target instanceof HTMLElement)try{let c=i.target.closest("a");if(!c)return;let{hash:u}=new URL(c.href),d=e.querySelector(u);d&&!o(d)&&(a=d)}catch{}},!0),t.addEventListener(e,"touchstart",i=>{if(i.target instanceof HTMLElement)if(o(i.target)){let c=i.target;for(;c.parentElement&&o(c.parentElement);)c=c.parentElement;t.style(c,"overscrollBehavior","contain")}else t.style(i.target,"touchAction","none")}),t.addEventListener(e,"touchmove",i=>{if(i.target instanceof HTMLElement){if(i.target.tagName==="INPUT")return;if(o(i.target)){let c=i.target;for(;c.parentElement&&c.dataset.headlessuiPortal!==""&&!(c.scrollHeight>c.clientHeight||c.scrollWidth>c.clientWidth);)c=c.parentElement;c.dataset.headlessuiPortal===""&&i.preventDefault()}else i.preventDefault()}},{passive:!1}),t.add(()=>{var i;let c=(i=window.scrollY)!=null?i:window.pageYOffset;s!==c&&window.scrollTo(0,s),a&&a.isConnected&&(a.scrollIntoView({block:"nearest"}),a=null)})})}}:{}}function AM(){return{before({doc:e,d:t}){t.style(e.documentElement,"overflow","hidden")}}}function _M(e){let t={};for(let n of e)Object.assign(t,n(t));return t}let an=wh(()=>new Map,{PUSH(e,t){var n;let o=(n=this.get(e))!=null?n:{doc:e,count:0,d:gt(),meta:new Set};return o.count++,o.meta.add(t),this.set(e,o),this},POP(e,t){let n=this.get(e);return n&&(n.count--,n.meta.delete(t)),this},SCROLL_PREVENT({doc:e,d:t,meta:n}){let o={doc:e,d:t,meta:_M(n)},r=[OM(),IM(),AM()];r.forEach(({before:s})=>s?.(o)),r.forEach(({after:s})=>s?.(o))},SCROLL_ALLOW({d:e}){e.dispose()},TEARDOWN({doc:e}){this.delete(e)}});an.subscribe(()=>{let e=an.getSnapshot(),t=new Map;for(let[n]of e)t.set(n,n.documentElement.style.overflow);for(let n of e.values()){let o=t.get(n.doc)==="hidden",r=n.count!==0;(r&&!o||!r&&o)&&an.dispatch(n.count>0?"SCROLL_PREVENT":"SCROLL_ALLOW",n),n.count===0&&an.dispatch("TEARDOWN",n)}});function NM(e,t,n=()=>({containers:[]})){let o=Eh(an),r=t?o.get(t):void 0,s=r?r.count>0:!1;return ce(()=>{if(!(!t||!e))return an.dispatch("PUSH",t,n),()=>an.dispatch("POP",t,n)},[e,t]),s}function Gr(e,t,n=()=>[document.body]){let o=Bn(e,"scroll-lock");NM(o,t,r=>{var s;
vendor: 15,923 bytes, lines 41-42
41return{containers:[...(s=r.containers)!=null?s:[],n]}})}function lc(e){return[e.screenX,e.screenY]}function Th(){let e=l.useRef([-1,-1]);return{wasMoved(t){let n=lc(t);return e.current[0]===n[0]&&e.current[1]===n[1]?!1:(e.current=n,!0)},update(t){e.current=lc(t)}}}function $M(e=0){let[t,n]=l.useState(e),o=l.useCallback(c=>n(c),[t]),r=l.useCallback(c=>n(u=>u|c),[t]),s=l.useCallback(c=>(t&c)===c,[t]),a=l.useCallback(c=>n(u=>u&~c),[n]),i=l.useCallback(c=>n(u=>u^c),[n]);return{flags:t,setFlag:o,addFlag:r,hasFlag:s,removeFlag:a,toggleFlag:i}}var FM={},cc,uc;typeof process<"u"&&typeof globalThis<"u"&&typeof Element<"u"&&((cc=process==null?void 0:FM)==null?void 0:cc.NODE_ENV)==="test"&&typeof((uc=Element?.prototype)==null?void 0:uc.getAnimations)>"u"&&(Element.prototype.getAnimations=function(){return console.warn(["Headless UI has polyfilled `Element.prototype.getAnimations` for your tests.","Please install a proper polyfill e.g. `jsdom-testing-mocks`, to silence these warnings.","","Example usage:","```js","import { mockAnimationsApi } from 'jsdom-testing-mocks'","mockAnimationsApi()","```"].join(`
42`)),[]});var LM=(e=>(e[e.None=0]="None",e[e.Closed=1]="Closed",e[e.Enter=2]="Enter",e[e.Leave=4]="Leave",e))(LM||{});function Wn(e){let t={};for(let n in e)e[n]===!0&&(t[`data-${n}`]="");return t}function Hn(e,t,n,o){let[r,s]=l.useState(n),{hasFlag:a,addFlag:i,removeFlag:c}=$M(e&&r?3:0),u=l.useRef(!1),d=l.useRef(!1),f=It();return ce(()=>{var p;if(e){if(n&&s(!0),!t){n&&i(3);return}return(p=o?.start)==null||p.call(o,n),jM(t,{inFlight:u,prepare(){d.current?d.current=!1:d.current=u.current,u.current=!0,!d.current&&(n?(i(3),c(4)):(i(4),c(2)))},run(){d.current?n?(c(3),i(4)):(c(4),i(3)):n?c(1):i(1)},done(){var h;d.current&&typeof t.getAnimations=="function"&&t.getAnimations().length>0||(u.current=!1,c(7),n||s(!1),(h=o?.end)==null||h.call(o,n))}})}},[e,n,t,f]),e?[r,{closed:a(1),enter:a(2),leave:a(4),transition:a(2)||a(4)}]:[n,{closed:void 0,enter:void 0,leave:void 0,transition:void 0}]}function jM(e,{prepare:t,run:n,done:o,inFlight:r}){let s=gt();return VM(e,{prepare:t,inFlight:r}),s.nextFrame(()=>{n(),s.requestAnimationFrame(()=>{s.add(BM(e,o))})}),s.dispose}function BM(e,t){var n,o;let r=gt();if(!e)return r.dispose;let s=!1;r.add(()=>{s=!0});let a=(o=(n=e.getAnimations)==null?void 0:n.call(e).filter(i=>i instanceof CSSTransition))!=null?o:[];return a.length===0?(t(),r.dispose):(Promise.allSettled(a.map(i=>i.finished)).then(()=>{s||t()}),r.dispose)}function VM(e,{inFlight:t,prepare:n}){if(t!=null&&t.current){n();return}let o=e.style.transition;e.style.transition="none",n(),e.offsetHeight,e.style.transition=o}function WM(e,{container:t,accept:n,walk:o}){let r=l.useRef(n),s=l.useRef(o);l.useEffect(()=>{r.current=n,s.current=o},[n,o]),ce(()=>{if(!t||!e)return;let a=Dt(t);if(!a)return;let i=r.current,c=s.current,u=Object.assign(f=>i(f),{acceptNode:i}),d=a.createTreeWalker(t,NodeFilter.SHOW_ELEMENT,u,!1);for(;d.nextNode();)c(d.currentNode)},[t,e,r,s])}function po(e,t){let n=l.useRef([]),o=j(e);l.useEffect(()=>{let r=[...n.current];for(let[s,a]of t.entries())if(n.current[s]!==a){let i=o(t,r);return n.current=t,i}},[o,...t])}function HM(){const e=navigator.userAgentData;return e&&Array.isArray(e.brands)?e.brands.map(t=>{let{brand:n,version:o}=t;return n+"/"+o}).join(" "):navigator.userAgent}const kh={...kn},UM=kh.useInsertionEffect,GM=UM||(e=>e());function Rh(e){const t=l.useRef(()=>{});return GM(()=>{t.current=e}),l.useCallback(function(){for(var n=arguments.length,o=new Array(n),r=0;r<n;r++)o[r]=arguments[r];return t.current==null?void 0:t.current(...o)},[])}var ra=typeof document<"u"?l.useLayoutEffect:l.useEffect;let dc=!1,YM=0;const fc=()=>"floating-ui-"+Math.random().toString(36).slice(2,6)+YM++;function zM(){const[e,t]=l.useState(()=>dc?fc():void 0);return ra(()=>{e==null&&t(fc())},[]),l.useEffect(()=>{dc=!0},[]),e}const KM=kh.useId,qM=KM||zM;function XM(){const e=new Map;return{emit(t,n){var o;(o=e.get(t))==null||o.forEach(r=>r(n))},on(t,n){e.set(t,[...e.get(t)||[],n])},off(t,n){var o;e.set(t,((o=e.get(t))==null?void 0:o.filter(r=>r!==n))||[])}}}const ZM=l.createContext(null),QM=l.createContext(null),JM=()=>{var e;return((e=l.useContext(ZM))==null?void 0:e.id)||null},eT=()=>l.useContext(QM),tT="data-floating-ui-focusable";function nT(e){const{open:t=!1,onOpenChange:n,elements:o}=e,r=qM(),s=l.useRef({}),[a]=l.useState(()=>XM()),i=JM()!=null,[c,u]=l.useState(o.reference),d=Rh((h,m,v)=>{s.current.openEvent=h?m:void 0,a.emit("openchange",{open:h,event:m,reason:v,nested:i}),n?.(h,m,v)}),f=l.useMemo(()=>({setPositionReference:u}),[]),p=l.useMemo(()=>({reference:c||o.reference||null,floating:o.floating||null,domReference:o.reference}),[c,o.reference,o.floating]);return l.useMemo(()=>({dataRef:s,open:t,onOpenChange:d,elements:p,events:a,floatingId:r,refs:f}),[t,d,p,a,r,f])}function oT(e){e===void 0&&(e={});const{nodeId:t}=e,n=nT({...e,elements:{reference:null,floating:null,...e.elements}}),o=e.rootContext||n,r=o.elements,[s,a]=l.useState(null),[i,c]=l.useState(null),d=r?.domReference||s,f=l.useRef(null),p=eT();ra(()=>{d&&(f.current=d)},[d]);const h=Sc({...e,elements:{...r,...i&&{reference:i}}}),m=l.useCallback(x=>{const S=$o(x)?{getBoundingClientRect:()=>x.getBoundingClientRect(),contextElement:x}:x;c(S),h.refs.setReference(S)},[h.refs]),v=l.useCallback(x=>{($o(x)||x===null)&&(f.current=x,a(x)),($o(h.refs.reference.current)||h.refs.reference.current===null||x!==null&&!$o(x))&&h.refs.setReference(x)},[h.refs]),g=l.useMemo(()=>({...h.refs,setReference:v,setPositionReference:m,domReference:f}),[h.refs,v,m]),y=l.useMemo(()=>({...h.elements,domReference:d}),[h.elements,d]),b=l.useMemo(()=>({...h,...o,refs:g,elements:y,nodeId:t}),[h,g,y,t,o]);return ra(()=>{o.dataRef.current.floatingContext=b;const x=p?.nodesRef.current.find(S=>S.id===t);x&&(x.context=b)}),l.useMemo(()=>({...h,context:b,refs:g,elements:y}),[h,g,y,b])}const pc="active",hc="selected";function Ds(e,t,n){const o=new Map,r=n==="item";let s=e;if(r&&e){const{[pc]:a,[hc]:i,...c}=e;s=c}return{...n==="floating"&&{tabIndex:-1,[tT]:""},...s,...t.map(a=>{const i=a?a[n]:null;return typeof i=="function"?e?i(e):null:i}).concat(e).reduce((a,i)=>(i&&Object.entries(i).forEach(c=>{let[u,d]=c;if(!(r&&[pc,hc].includes(u)))if(u.indexOf("on")===0){if(o.has(u)||o.set(u,[]),typeof d=="function"){var f;(f=o.get(u))==null||f.push(d),a[u]=function(){for(var p,h=arguments.length,m=new Array(h),v=0;v<h;v++)m[v]=arguments[v];return(p=o.get(u))==null?void 0:p.map(g=>g(...m)).find(g=>g!==void 0)}}}else a[u]=d}),a),{})}}function rT(e){e===void 0&&(e=[]);const t=e.map(i=>i?.reference),n=e.map(i=>i?.floating),o=e.map(i=>i?.item),r=l.useCallback(i=>Ds(i,e,"reference"),t),s=l.useCallback(i=>Ds(i,e,"floating"),n),a=l.useCallback(i=>Ds(i,e,"item"),o);return l.useMemo(()=>({getReferenceProps:r,getFloatingProps:s,getItemProps:a}),[r,s,a])}function mc(e,t){return{...e,rects:{...e.rects,floating:{...e.rects.floating,height:t}}}}const sT=e=>({name:"inner",options:e,async fn(t){const{listRef:n,overflowRef:o,onFallbackChange:r,offset:s=0,index:a=0,minItemsVisible:i=4,referenceOverflowThreshold:c=0,scrollRef:u,...d}=Pm(e,t),{rects:f,elements:{floating:p}}=t,h=n.current[a],m=u?.current||p,v=p.clientTop||m.clientTop,g=p.clientTop!==0,y=m.clientTop!==0,b=p===m;if(!h)return{};const x={...t,...await ia(-h.offsetTop-p.clientTop-f.reference.height/2-h.offsetHeight/2-s).fn(t)},S=await as(mc(x,m.scrollHeight+v+p.clientTop),d),T=await as(x,{...d,elementContext:"reference"}),C=is(0,S.top),P=x.y+C,I=(m.scrollHeight>m.clientHeight?$=>$:Tm)(is(0,m.scrollHeight+(g&&b||y?v*2:0)-C-is(0,S.bottom)));if(m.style.maxHeight=I+"px",m.scrollTop=C,r){const $=m.offsetHeight<h.offsetHeight*Mm(i,n.current.length)-1||T.top>=-c||T.bottom>=-c;Te.flushSync(()=>r($))}return o&&(o.current=await as(mc({...x,y:P},m.offsetHeight+v+p.clientTop),d)),{y:P}}});function aT(e,t){const{open:n,elements:o}=e,{enabled:r=!0,overflowRef:s,scrollRef:a,onChange:i}=t,c=Rh(i),u=l.useRef(!1),d=l.useRef(null),f=l.useRef(null);l.useEffect(()=>{if(!r)return;function h(v){if(v.ctrlKey||!m||s.current==null)return;const g=v.deltaY,y=s.current.top>=-.5,b=s.current.bottom>=-.5,x=m.scrollHeight-m.clientHeight,S=g<0?-1:1,T=g<0?"max":"min";m.scrollHeight<=m.clientHeight||(!y&&g>0||!b&&g<0?(v.preventDefault(),Te.flushSync(()=>{c(C=>C+Math[T](g,x*S))})):/firefox/i.test(HM())&&(m.scrollTop+=g))}const m=a?.current||o.floating;if(n&&m)return m.addEventListener("wheel",h),requestAnimationFrame(()=>{d.current=m.scrollTop,s.current!=null&&(f.current={...s.current})}),()=>{d.current=null,f.current=null,m.removeEventListener("wheel",h)}},[r,n,o.floating,s,a,c]);const p=l.useMemo(()=>({onKeyDown(){u.current=!0},onWheel(){u.current=!1},onPointerMove(){u.current=!1},onScroll(){const h=a?.current||o.floating;if(!(!s.current||!h||!u.current)){if(d.current!==null){const m=h.scrollTop-d.current;(s.current.bottom<-.5&&m<-1||s.current.top<-.5&&m>1)&&Te.flushSync(()=>c(v=>v+m))}requestAnimationFrame(()=>{d.current=h.scrollTop})}}}),[o.floating,c,s,a]);return l.useMemo(()=>r?{floating:p}:{},[r,p])}let Un=l.createContext({styles:void 0,setReference:()=>{},setFloating:()=>{},getReferenceProps:()=>({}),getFloatingProps:()=>({}),slot:{}});Un.displayName="FloatingContext";let di=l.createContext(null);di.displayName="PlacementContext";function fi(e){return l.useMemo(()=>e?typeof e=="string"?{to:e}:e:null,[e])}function pi(){return l.useContext(Un).setReference}function iT(){return l.useContext(Un).getReferenceProps}function hi(){let{getFloatingProps:e,slot:t}=l.useContext(Un);return l.useCallback((...n)=>Object.assign({},e(...n),{"data-anchor":t.anchor}),[e,t])}function mi(e=null){e===!1&&(e=null),typeof e=="string"&&(e={to:e});let t=l.useContext(di),n=l.useMemo(()=>e,[JSON.stringify(e,(r,s)=>{var a;return(a=s?.outerHTML)!=null?a:s})]);ce(()=>{t?.(n??null)},[t,n]);let o=l.useContext(Un);return l.useMemo(()=>[o.setFloating,e?o.styles:{}],[o.setFloating,e,o.styles])}let vc=4;function vi({children:e,enabled:t=!0}){let[n,o]=l.useState(null),[r,s]=l.useState(0),a=l.useRef(null),[i,c]=l.useState(null);lT(i);let u=t&&n!==null&&i!==null,{to:d="bottom",gap:f=0,offset:p=0,padding:h=0,inner:m}=cT(n,i),[v,g="center"]=d.split(" ");ce(()=>{u&&s(0)},[u]);let{refs:y,floatingStyles:b,context:x}=oT({open:u,placement:v==="selection"?g==="center"?"bottom":`bottom-${g}`:g==="center"?`${v}`:`${v}-${g}`,strategy:"absolute",transform:!1,middleware:[ia({mainAxis:v==="selection"?0:f,crossAxis:p}),Pc({padding:h}),v!=="selection"&&Mc({padding:h}),v==="selection"&&m?sT({...m,padding:h,overflowRef:a,offset:r,minItemsVisible:vc,referenceOverflowThreshold:h,onFallbackChange($){var G,W;if(!$)return;let B=x.elements.floating;if(!B)return;let K=parseFloat(getComputedStyle(B).scrollPaddingBottom)||0,H=Math.min(vc,B.childElementCount),U=0,q=0;for(let R of(W=(G=x.elements.floating)==null?void 0:G.childNodes)!=null?W:[])if(R instanceof HTMLElement){let D=R.offsetTop,L=D+R.clientHeight+K,k=B.scrollTop,M=k+B.clientHeight;if(D>=k&&L<=M)H--;else{q=Math.max(0,Math.min(L,M)-Math.max(D,k)),U=R.clientHeight;break}}H>=1&&s(R=>{let D=U*H-q+K;return R>=D?R:D})}}):null,Tc({padding:h,apply({availableWidth:$,availableHeight:G,elements:W}){Object.assign(W.floating.style,{overflow:"auto",maxWidth:`${$}px`,maxHeight:`min(var(--anchor-max-height, 100vh), ${G}px)`})}})].filter(Boolean),whileElementsMounted:kc}),[S=v,T=g]=x.placement.split("-");v==="selection"&&(S="selection");let C=l.useMemo(()=>({anchor:[S,T].filter(Boolean).join(" ")}),[S,T]),P=aT(x,{overflowRef:a,onChange:s}),{getReferenceProps:_,getFloatingProps:O}=rT([P]),I=j($=>{c($),y.setFloating($)});return l.createElement(di.Provider,{value:o},l.createElement(Un.Provider,{value:{setFloating:I,setReference:y.setReference,styles:b,getReferenceProps:_,getFloatingProps:O,slot:C}},e))}function lT(e){ce(()=>{if(!e)return;let t=new MutationObserver(()=>{let n=window.getComputedStyle(e).maxHeight,o=parseFloat(n);if(isNaN(o))return;let r=parseInt(n);isNaN(r)||o!==r&&(e.style.maxHeight=`${Math.ceil(o)}px`)});return t.observe(e,{attributes:!0,attributeFilter:["style"]}),()=>{t.disconnect()}},[e])}function cT(e,t){var n,o,r;let s=Is((n=e?.gap)!=null?n:"var(--anchor-gap, 0)",t),a=Is((o=e?.offset)!=null?o:"var(--anchor-offset, 0)",t),i=Is((r=e?.padding)!=null?r:"var(--anchor-padding, 0)",t);return{...e,gap:s,offset:a,padding:i}}function Is(e,t,n=void 0){let o=It(),r=j((c,u)=>{if(c==null)return[n,null];if(typeof c=="number")return[c,null];if(typeof c=="string"){if(!u)return[n,null];let d=gc(c,u);return[d,f=>{let p=Dh(c);{let h=p.map(m=>window.getComputedStyle(u).getPropertyValue(m));o.requestAnimationFrame(function m(){o.nextFrame(m);let v=!1;for(let[y,b]of p.entries()){let x=window.getComputedStyle(u).getPropertyValue(b);if(h[y]!==x){h[y]=x,v=!0;break}}if(!v)return;let g=gc(c,u);d!==g&&(f(g),d=g)})}return o.dispose}]}return[n,null]}),s=l.useMemo(()=>r(e,t)[0],[e,t]),[a=s,i]=l.useState();return ce(()=>{let[c,u]=r(e,t);if(i(c),!!u)return u(i)},[e,t]),a}function Dh(e){let t=/var\((.*)\)/.exec(e);if(t){let n=t[1].indexOf(",");if(n===-1)return[t[1]];let o=t[1].slice(0,n).trim(),r=t[1].slice(n+1).trim();return r?[o,...Dh(r)]:[o]}return[]}function gc(e,t){let n=document.createElement("div");t.appendChild(n),n.style.setProperty("margin-top","0px","important"),n.style.setProperty("margin-top",e,"important");let o=parseFloat(window.getComputedStyle(n).marginTop)||0;return t.removeChild(n),o}function uT({children:e,freeze:t}){let n=ar(t,e);return w.createElement(w.Fragment,null,n)}function ar(e,t){let[n,o]=l.useState(t);return!e&&n!==t&&o(t),e?n:t}let Yr=l.createContext(null);Yr.displayName="OpenClosedContext";var Ce=(e=>(e[e.Open=1]="Open",e[e.Closed=2]="Closed",e[e.Closing=4]="Closing",e[e.Opening=8]="Opening",e))(Ce||{});function $t(){return l.useContext(Yr)}function Ro({value:e,children:t}){return w.createElement(Yr.Provider,{value:e},t)}function gi({children:e}){return w.createElement(Yr.Provider,{value:null},e)}function dT(e){function t(){document.readyState!=="loading"&&(e(),document.removeEventListener("DOMContentLoaded",t))}typeof window<"u"&&typeof document<"u"&&(document.addEventListener("DOMContentLoaded",t),t())}let St=[];dT(()=>{function e(t){if(!(t.target instanceof HTMLElement)||t.target===document.body||St[0]===t.target)return;let n=t.target;n=n.closest(sr),St.unshift(n??t.target),St=St.filter(o=>o!=null&&o.isConnected),St.splice(10)}window.addEventListener("click",e,{capture:!0}),window.addEventListener("mousedown",e,{capture:!0}),window.addEventListener("focus",e,{capture:!0}),document.body.addEventListener("click",e,{capture:!0}),document.body.addEventListener("mousedown",e,{capture:!0}),document.body.addEventListener("focus",e,{capture:!0})});function fT(e){throw new Error("Unexpected object: "+e)}var de=(e=>(e[e.First=0]="First",e[e.Previous=1]="Previous",e[e.Next=2]="Next",e[e.Last=3]="Last",e[e.Specific=4]="Specific",e[e.Nothing=5]="Nothing",e))(de||{});function so(e,t){let n=t.resolveItems();if(n.length<=0)return null;let o=t.resolveActiveIndex(),r=o??-1;switch(e.focus){case 0:{for(let s=0;s<n.length;++s)if(!t.resolveDisabled(n[s],s,n))return s;return o}case 1:{r===-1&&(r=n.length);for(let s=r-1;s>=0;--s)if(!t.resolveDisabled(n[s],s,n))return s;return o}case 2:{for(let s=r+1;s<n.length;++s)if(!t.resolveDisabled(n[s],s,n))return s;return o}case 3:{for(let s=n.length-1;s>=0;--s)if(!t.resolveDisabled(n[s],s,n))return s;return o}case 4:{for(let s=0;s<n.length;++s)if(t.resolveId(n[s],s,n)===e.id)return s;return o}case 5:return null;default:fT(e)}}var yi=(e=>(e[e.Left=0]="Left",e[e.Right=2]="Right",e))(yi||{});function Ih(e){let t=j(e),n=l.useRef(!1);l.useEffect(()=>(n.current=!1,()=>{n.current=!0,Mo(()=>{n.current&&t()})}),[t])}function pT(){let e=typeof document>"u";return"useSyncExternalStore"in kn?(t=>t.useSyncExternalStore)(kn)(()=>()=>{},()=>!1,()=>!e):!1}function Do(){let e=pT(),[t,n]=l.useState(ln.isHandoffComplete);
vendor: 28,496 bytes, line 42
42return t&&ln.isHandoffComplete===!1&&n(!1),l.useEffect(()=>{t!==!0&&n(!0)},[t]),l.useEffect(()=>ln.handoff(),[]),e?!1:t}let Oh=l.createContext(!1);function hT(){return l.useContext(Oh)}function yc(e){return w.createElement(Oh.Provider,{value:e.force},e.children)}function mT(e){let t=hT(),n=l.useContext(_h),o=bt(e),[r,s]=l.useState(()=>{var a;if(!t&&n!==null)return(a=n.current)!=null?a:null;if(ln.isServer)return null;let i=o?.getElementById("headlessui-portal-root");if(i)return i;if(o===null)return null;let c=o.createElement("div");return c.setAttribute("id","headlessui-portal-root"),o.body.appendChild(c)});return l.useEffect(()=>{r!==null&&(o!=null&&o.body.contains(r)||o==null||o.body.appendChild(r))},[r,o]),l.useEffect(()=>{t||n!==null&&s(n.current)},[n,s,t]),r}let Ah=l.Fragment,vT=le(function(e,t){let n=e,o=l.useRef(null),r=ye(ri(f=>{o.current=f}),t),s=bt(o),a=mT(o),[i]=l.useState(()=>{var f;return ln.isServer?null:(f=s?.createElement("div"))!=null?f:null}),c=l.useContext(sa),u=Do();ce(()=>{!a||!i||a.contains(i)||(i.setAttribute("data-headlessui-portal",""),a.appendChild(i))},[a,i]),ce(()=>{if(i&&c)return c.register(i)},[c,i]),Ih(()=>{var f;!a||!i||(i instanceof Node&&a.contains(i)&&a.removeChild(i),a.childNodes.length<=0&&((f=a.parentElement)==null||f.removeChild(a)))});let d=fe();return u?!a||!i?null:Te.createPortal(d({ourProps:{ref:r},theirProps:n,slot:{},defaultTag:Ah,name:"Portal"}),i):null});function gT(e,t){let n=ye(t),{enabled:o=!0,...r}=e,s=fe();return o?w.createElement(vT,{...r,ref:n}):s({ourProps:{ref:n},theirProps:r,slot:{},defaultTag:Ah,name:"Portal"})}let yT=l.Fragment,_h=l.createContext(null);function bT(e,t){let{target:n,...o}=e,r={ref:ye(t)},s=fe();return w.createElement(_h.Provider,{value:n},s({ourProps:r,theirProps:o,defaultTag:yT,name:"Popover.Group"}))}let sa=l.createContext(null);function Nh(){let e=l.useContext(sa),t=l.useRef([]),n=j(s=>(t.current.push(s),e&&e.register(s),()=>o(s))),o=j(s=>{let a=t.current.indexOf(s);a!==-1&&t.current.splice(a,1),e&&e.unregister(s)}),r=l.useMemo(()=>({register:n,unregister:o,portals:t}),[n,o,t]);return[t,l.useMemo(()=>function({children:s}){return w.createElement(sa.Provider,{value:r},s)},[r])]}let xT=le(gT),$h=le(bT),zr=Object.assign(xT,{Group:$h});var wT=(e=>(e[e.Open=0]="Open",e[e.Closed=1]="Closed",e))(wT||{}),ET=(e=>(e[e.Single=0]="Single",e[e.Multi=1]="Multi",e))(ET||{}),CT=(e=>(e[e.Pointer=0]="Pointer",e[e.Focus=1]="Focus",e[e.Other=2]="Other",e))(CT||{}),ST=(e=>(e[e.OpenCombobox=0]="OpenCombobox",e[e.CloseCombobox=1]="CloseCombobox",e[e.GoToOption=2]="GoToOption",e[e.SetTyping=3]="SetTyping",e[e.RegisterOption=4]="RegisterOption",e[e.UnregisterOption=5]="UnregisterOption",e[e.SetActivationTrigger=6]="SetActivationTrigger",e[e.UpdateVirtualConfiguration=7]="UpdateVirtualConfiguration",e[e.SetInputElement=8]="SetInputElement",e[e.SetButtonElement=9]="SetButtonElement",e[e.SetOptionsElement=10]="SetOptionsElement",e))(ST||{});function Os(e,t=n=>n){let n=e.activeOptionIndex!==null?e.options[e.activeOptionIndex]:null,o=t(e.options.slice()),r=o.length>0&&o[0].dataRef.current.order!==null?o.sort((a,i)=>a.dataRef.current.order-i.dataRef.current.order):Ht(o,a=>a.dataRef.current.domRef.current),s=n?r.indexOf(n):null;return s===-1&&(s=null),{options:r,activeOptionIndex:s}}let PT={1(e){var t;return(t=e.dataRef.current)!=null&&t.disabled||e.comboboxState===1?e:{...e,activeOptionIndex:null,comboboxState:1,isTyping:!1,activationTrigger:2,__demoMode:!1}},0(e){var t,n;if((t=e.dataRef.current)!=null&&t.disabled||e.comboboxState===0)return e;if((n=e.dataRef.current)!=null&&n.value){let o=e.dataRef.current.calculateIndex(e.dataRef.current.value);if(o!==-1)return{...e,activeOptionIndex:o,comboboxState:0,__demoMode:!1}}return{...e,comboboxState:0,__demoMode:!1}},3(e,t){return e.isTyping===t.isTyping?e:{...e,isTyping:t.isTyping}},2(e,t){var n,o,r,s;if((n=e.dataRef.current)!=null&&n.disabled||e.optionsElement&&!((o=e.dataRef.current)!=null&&o.optionsPropsRef.current.static)&&e.comboboxState===1)return e;if(e.virtual){let{options:u,disabled:d}=e.virtual,f=t.focus===de.Specific?t.idx:so(t,{resolveItems:()=>u,resolveActiveIndex:()=>{var h,m;return(m=(h=e.activeOptionIndex)!=null?h:u.findIndex(v=>!d(v)))!=null?m:null},resolveDisabled:d,resolveId(){throw new Error("Function not implemented.")}}),p=(r=t.trigger)!=null?r:2;return e.activeOptionIndex===f&&e.activationTrigger===p?e:{...e,activeOptionIndex:f,activationTrigger:p,isTyping:!1,__demoMode:!1}}let a=Os(e);if(a.activeOptionIndex===null){let u=a.options.findIndex(d=>!d.dataRef.current.disabled);u!==-1&&(a.activeOptionIndex=u)}let i=t.focus===de.Specific?t.idx:so(t,{resolveItems:()=>a.options,resolveActiveIndex:()=>a.activeOptionIndex,resolveId:u=>u.id,resolveDisabled:u=>u.dataRef.current.disabled}),c=(s=t.trigger)!=null?s:2;return e.activeOptionIndex===i&&e.activationTrigger===c?e:{...e,...a,isTyping:!1,activeOptionIndex:i,activationTrigger:c,__demoMode:!1}},4:(e,t)=>{var n,o,r;if((n=e.dataRef.current)!=null&&n.virtual)return{...e,options:[...e.options,t.payload]};let s=t.payload,a=Os(e,c=>(c.push(s),c));e.activeOptionIndex===null&&(o=e.dataRef.current)!=null&&o.isSelected(t.payload.dataRef.current.value)&&(a.activeOptionIndex=a.options.indexOf(s));let i={...e,...a,activationTrigger:2};return(r=e.dataRef.current)!=null&&r.__demoMode&&e.dataRef.current.value===void 0&&(i.activeOptionIndex=0),i},5:(e,t)=>{var n;if((n=e.dataRef.current)!=null&&n.virtual)return{...e,options:e.options.filter(r=>r.id!==t.id)};let o=Os(e,r=>{let s=r.findIndex(a=>a.id===t.id);return s!==-1&&r.splice(s,1),r});return{...e,...o,activationTrigger:2}},6:(e,t)=>e.activationTrigger===t.trigger?e:{...e,activationTrigger:t.trigger},7:(e,t)=>{var n,o;if(e.virtual===null)return{...e,virtual:{options:t.options,disabled:(n=t.disabled)!=null?n:()=>!1}};if(e.virtual.options===t.options&&e.virtual.disabled===t.disabled)return e;let r=e.activeOptionIndex;if(e.activeOptionIndex!==null){let s=t.options.indexOf(e.virtual.options[e.activeOptionIndex]);s!==-1?r=s:r=null}return{...e,activeOptionIndex:r,virtual:{options:t.options,disabled:(o=t.disabled)!=null?o:()=>!1}}},8:(e,t)=>e.inputElement===t.element?e:{...e,inputElement:t.element},9:(e,t)=>e.buttonElement===t.element?e:{...e,buttonElement:t.element},10:(e,t)=>e.optionsElement===t.element?e:{...e,optionsElement:t.element}},bi=l.createContext(null);bi.displayName="ComboboxActionsContext";function Io(e){let t=l.useContext(bi);if(t===null){let n=new Error(`<${e} /> is missing a parent <Combobox /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,Io),n}return t}let Fh=l.createContext(null);function MT(e){let t=Gn("VirtualProvider"),{options:n}=t.virtual,[o,r]=l.useMemo(()=>{let u=t.optionsElement;if(!u)return[0,0];let d=window.getComputedStyle(u);return[parseFloat(d.paddingBlockStart||d.paddingTop),parseFloat(d.paddingBlockEnd||d.paddingBottom)]},[t.optionsElement]),s=km({enabled:n.length!==0,scrollPaddingStart:o,scrollPaddingEnd:r,count:n.length,estimateSize(){return 40},getScrollElement(){return t.optionsElement},overscan:12}),[a,i]=l.useState(0);ce(()=>{i(u=>u+1)},[n]);let c=s.getVirtualItems();return c.length===0?null:w.createElement(Fh.Provider,{value:s},w.createElement("div",{style:{position:"relative",width:"100%",height:`${s.getTotalSize()}px`},ref:u=>{u&&t.activationTrigger!==0&&t.activeOptionIndex!==null&&n.length>t.activeOptionIndex&&s.scrollToIndex(t.activeOptionIndex)}},c.map(u=>{var d;return w.createElement(l.Fragment,{key:u.key},w.cloneElement((d=e.children)==null?void 0:d.call(e,{...e.slot,option:n[u.index]}),{key:`${a}-${u.key}`,"data-index":u.index,"aria-setsize":n.length,"aria-posinset":u.index+1,style:{position:"absolute",top:0,left:0,transform:`translateY(${u.start}px)`,overflowAnchor:"none"}}))})))}let ho=l.createContext(null);ho.displayName="ComboboxDataContext";function Gn(e){let t=l.useContext(ho);if(t===null){let n=new Error(`<${e} /> is missing a parent <Combobox /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,Gn),n}return t}function TT(e,t){return ge(t.type,PT,e,t)}let kT=l.Fragment;function RT(e,t){var n,o;let r=To(),{value:s,defaultValue:a,onChange:i,form:c,name:u,by:d,disabled:f=r||!1,onClose:p,__demoMode:h=!1,multiple:m=!1,immediate:v=!1,virtual:g=null,nullable:y,...b}=e,x=ni(a),[S=m?[]:void 0,T]=ti(s,i,x),[C,P]=l.useReducer(TT,{dataRef:l.createRef(),comboboxState:h?0:1,isTyping:!1,options:[],virtual:g?{options:g.options,disabled:(n=g.disabled)!=null?n:()=>!1}:null,activeOptionIndex:null,activationTrigger:2,inputElement:null,buttonElement:null,optionsElement:null,__demoMode:h}),_=l.useRef(!1),O=l.useRef({static:!1,hold:!1}),I=xh(d),$=j(V=>g?d===null?g.options.indexOf(V):g.options.findIndex(Q=>I(Q,V)):C.options.findIndex(Q=>I(Q.dataRef.current.value,V))),G=l.useCallback(V=>ge(B.mode,{1:()=>S.some(Q=>I(Q,V)),0:()=>I(S,V)}),[S]),W=j(V=>C.activeOptionIndex===$(V)),B=l.useMemo(()=>({...C,immediate:v,optionsPropsRef:O,value:S,defaultValue:x,disabled:f,mode:m?1:0,virtual:g?C.virtual:null,get activeOptionIndex(){if(_.current&&C.activeOptionIndex===null&&(g?g.options.length>0:C.options.length>0)){if(g){let Q=g.options.findIndex(me=>{var we,Re;return!((Re=(we=g.disabled)==null?void 0:we.call(g,me))!=null&&Re)});if(Q!==-1)return Q}let V=C.options.findIndex(Q=>!Q.dataRef.current.disabled);if(V!==-1)return V}return C.activeOptionIndex},calculateIndex:$,compare:I,isSelected:G,isActive:W}),[S,x,f,m,h,C,g]);ce(()=>{var V;g&&P({type:7,options:g.options,disabled:(V=g.disabled)!=null?V:null})},[g,g?.options,g?.disabled]),ce(()=>{C.dataRef.current=B},[B]);let K=B.comboboxState===0;Hr(K,[B.buttonElement,B.inputElement,B.optionsElement],()=>Y.closeCombobox());let H=l.useMemo(()=>{var V,Q,me;return{open:B.comboboxState===0,disabled:f,activeIndex:B.activeOptionIndex,activeOption:B.activeOptionIndex===null?null:B.virtual?B.virtual.options[(V=B.activeOptionIndex)!=null?V:0]:(me=(Q=B.options[B.activeOptionIndex])==null?void 0:Q.dataRef.current.value)!=null?me:null,value:S}},[B,f,S]),U=j(()=>{if(B.activeOptionIndex!==null){if(Y.setIsTyping(!1),B.virtual)M(B.virtual.options[B.activeOptionIndex]);else{let{dataRef:V}=B.options[B.activeOptionIndex];M(V.current.value)}Y.goToOption(de.Specific,B.activeOptionIndex)}}),q=j(()=>{P({type:0}),_.current=!0}),R=j(()=>{P({type:1}),_.current=!1,p?.()}),D=j(V=>{P({type:3,isTyping:V})}),L=j((V,Q,me)=>(_.current=!1,V===de.Specific?P({type:2,focus:de.Specific,idx:Q,trigger:me}):P({type:2,focus:V,trigger:me}))),k=j((V,Q)=>(P({type:4,payload:{id:V,dataRef:Q}}),()=>{B.isActive(Q.current.value)&&(_.current=!0),P({type:5,id:V})})),M=j(V=>ge(B.mode,{0(){return T?.(V)},1(){let Q=B.value.slice(),me=Q.findIndex(we=>I(we,V));return me===-1?Q.push(V):Q.splice(me,1),T?.(Q)}})),F=j(V=>{P({type:6,trigger:V})}),A=j(V=>{P({type:8,element:V})}),z=j(V=>{P({type:9,element:V})}),N=j(V=>{P({type:10,element:V})}),Y=l.useMemo(()=>({onChange:M,registerOption:k,goToOption:L,setIsTyping:D,closeCombobox:R,openCombobox:q,setActivationTrigger:F,selectActiveOption:U,setInputElement:A,setButtonElement:z,setOptionsElement:N}),[]),[te,ae]=ai(),pe=t===null?{}:{ref:t},ee=l.useCallback(()=>{if(x!==void 0)return T?.(x)},[T,x]),ue=fe();return w.createElement(ae,{value:te,props:{htmlFor:(o=B.inputElement)==null?void 0:o.id},slot:{open:B.comboboxState===0,disabled:f}},w.createElement(vi,null,w.createElement(bi.Provider,{value:Y},w.createElement(ho.Provider,{value:B},w.createElement(Ro,{value:ge(B.comboboxState,{0:Ce.Open,1:Ce.Closed})},u!=null&&w.createElement(oi,{disabled:f,data:S!=null?{[u]:S}:{},form:c,onReset:ee}),ue({ourProps:pe,theirProps:b,slot:H,defaultTag:kT,name:"Combobox"}))))))}let DT="input";function IT(e,t){var n,o,r,s,a;let i=Gn("Combobox.Input"),c=Io("Combobox.Input"),u=l.useId(),d=Lr(),{id:f=d||`headlessui-combobox-input-${u}`,onChange:p,displayValue:h,disabled:m=i.disabled||!1,autoFocus:v=!1,type:g="text",...y}=e,b=l.useRef(null),x=ye(b,t,pi(),c.setInputElement),S=bt(i.inputElement),T=It(),C=j(()=>{c.onChange(null),i.optionsElement&&(i.optionsElement.scrollTop=0),c.goToOption(de.Nothing)}),P=l.useMemo(()=>{var M;return typeof h=="function"&&i.value!==void 0?(M=h(i.value))!=null?M:"":typeof i.value=="string"?i.value:""},[i.value,h]);po(([M,F],[A,z])=>{if(i.isTyping)return;let N=b.current;N&&((z===0&&F===1||M!==A)&&(N.value=M),requestAnimationFrame(()=>{if(i.isTyping||!N||S?.activeElement!==N)return;let{selectionStart:Y,selectionEnd:te}=N;Math.abs((te??0)-(Y??0))===0&&Y===0&&N.setSelectionRange(N.value.length,N.value.length)}))},[P,i.comboboxState,S,i.isTyping]),po(([M],[F])=>{if(M===0&&F===1){if(i.isTyping)return;let A=b.current;if(!A)return;let z=A.value,{selectionStart:N,selectionEnd:Y,selectionDirection:te}=A;A.value="",A.value=z,te!==null?A.setSelectionRange(N,Y,te):A.setSelectionRange(N,Y)}},[i.comboboxState]);let _=l.useRef(!1),O=j(()=>{_.current=!0}),I=j(()=>{T.nextFrame(()=>{_.current=!1})}),$=j(M=>{switch(c.setIsTyping(!0),M.key){case ne.Enter:if(i.comboboxState!==0||_.current)return;if(M.preventDefault(),M.stopPropagation(),i.activeOptionIndex===null){c.closeCombobox();return}c.selectActiveOption(),i.mode===0&&c.closeCombobox();break;case ne.ArrowDown:return M.preventDefault(),M.stopPropagation(),ge(i.comboboxState,{0:()=>c.goToOption(de.Next),1:()=>c.openCombobox()});case ne.ArrowUp:return M.preventDefault(),M.stopPropagation(),ge(i.comboboxState,{0:()=>c.goToOption(de.Previous),1:()=>{Te.flushSync(()=>c.openCombobox()),i.value||c.goToOption(de.Last)}});case ne.Home:if(M.shiftKey)break;return M.preventDefault(),M.stopPropagation(),c.goToOption(de.First);case ne.PageUp:return M.preventDefault(),M.stopPropagation(),c.goToOption(de.First);case ne.End:if(M.shiftKey)break;return M.preventDefault(),M.stopPropagation(),c.goToOption(de.Last);case ne.PageDown:return M.preventDefault(),M.stopPropagation(),c.goToOption(de.Last);case ne.Escape:return i.comboboxState!==0?void 0:(M.preventDefault(),i.optionsElement&&!i.optionsPropsRef.current.static&&M.stopPropagation(),i.mode===0&&i.value===null&&C(),c.closeCombobox());case ne.Tab:if(i.comboboxState!==0)return;i.mode===0&&i.activationTrigger!==1&&c.selectActiveOption(),c.closeCombobox();break}}),G=j(M=>{p?.(M),i.mode===0&&M.target.value===""&&C(),c.openCombobox()}),W=j(M=>{var F,A,z;let N=(F=M.relatedTarget)!=null?F:St.find(Y=>Y!==M.currentTarget);if(!((A=i.optionsElement)!=null&&A.contains(N))&&!((z=i.buttonElement)!=null&&z.contains(N))&&i.comboboxState===0)return M.preventDefault(),i.mode===0&&i.value===null&&C(),c.closeCombobox()}),B=j(M=>{var F,A,z;let N=(F=M.relatedTarget)!=null?F:St.find(Y=>Y!==M.currentTarget);(A=i.buttonElement)!=null&&A.contains(N)||(z=i.optionsElement)!=null&&z.contains(N)||i.disabled||i.immediate&&i.comboboxState!==0&&T.microTask(()=>{Te.flushSync(()=>c.openCombobox()),c.setActivationTrigger(1)})}),K=jn(),H=si(),{isFocused:U,focusProps:q}=zt({autoFocus:v}),{isHovered:R,hoverProps:D}=hn({isDisabled:m}),L=l.useMemo(()=>({open:i.comboboxState===0,disabled:m,hover:R,focus:U,autofocus:v}),[i,R,U,v,m]),k=ot({ref:x,id:f,role:"combobox",type:g,"aria-controls":(n=i.optionsElement)==null?void 0:n.id,"aria-expanded":i.comboboxState===0,"aria-activedescendant":i.activeOptionIndex===null?void 0:i.virtual?(o=i.options.find(M=>!M.dataRef.current.disabled&&i.compare(M.dataRef.current.value,i.virtual.options[i.activeOptionIndex])))==null?void 0:o.id:(r=i.options[i.activeOptionIndex])==null?void 0:r.id,"aria-labelledby":K,"aria-describedby":H,"aria-autocomplete":"list",defaultValue:(a=(s=e.defaultValue)!=null?s:i.defaultValue!==void 0?h?.(i.defaultValue):null)!=null?a:i.defaultValue,disabled:m||void 0,autoFocus:v,onCompositionStart:O,onCompositionEnd:I,onKeyDown:$,onChange:G,onFocus:B,onBlur:W},q,D);return fe()({ourProps:k,theirProps:y,slot:L,defaultTag:DT,name:"Combobox.Input"})}let OT="button";function AT(e,t){var n;let o=Gn("Combobox.Button"),r=Io("Combobox.Button"),s=ye(t,r.setButtonElement),a=l.useId(),{id:i=`headlessui-combobox-button-${a}`,disabled:c=o.disabled||!1,autoFocus:u=!1,...d}=e,f=Mh(o.inputElement),p=j(P=>{switch(P.key){case ne.Space:case ne.Enter:P.preventDefault(),P.stopPropagation(),o.comboboxState===1&&Te.flushSync(()=>r.openCombobox()),f();return;case ne.ArrowDown:P.preventDefault(),P.stopPropagation(),o.comboboxState===1&&(Te.flushSync(()=>r.openCombobox()),o.value||r.goToOption(de.First)),f();return;case ne.ArrowUp:P.preventDefault(),P.stopPropagation(),o.comboboxState===1&&(Te.flushSync(()=>r.openCombobox()),o.value||r.goToOption(de.Last)),f();return;case ne.Escape:if(o.comboboxState!==0)return;P.preventDefault(),o.optionsElement&&!o.optionsPropsRef.current.static&&P.stopPropagation(),Te.flushSync(()=>r.closeCombobox()),f();return;default:return}}),h=j(P=>{P.preventDefault(),!Ln(P.currentTarget)&&(P.button===yi.Left&&(o.comboboxState===0?r.closeCombobox():r.openCombobox()),f())}),m=jn([i]),{isFocusVisible:v,focusProps:g}=zt({autoFocus:u}),{isHovered:y,hoverProps:b}=hn({isDisabled:c}),{pressed:x,pressProps:S}=Fn({disabled:c}),T=l.useMemo(()=>({open:o.comboboxState===0,active:x||o.comboboxState===0,disabled:c,value:o.value,hover:y,focus:v}),[o,y,v,x,c]),C=ot({ref:s,id:i,type:Vn(e,o.buttonElement),tabIndex:-1,"aria-haspopup":"listbox","aria-controls":(n=o.optionsElement)==null?void 0:n.id,"aria-expanded":o.comboboxState===0,"aria-labelledby":m,disabled:c||void 0,autoFocus:u,onMouseDown:h,onKeyDown:p},g,b,S);return fe()({ourProps:C,theirProps:d,slot:T,defaultTag:OT,name:"Combobox.Button"})}let _T="div",NT=Ve.RenderStrategy|Ve.Static;function $T(e,t){var n,o,r;let s=l.useId(),{id:a=`headlessui-combobox-options-${s}`,hold:i=!1,anchor:c,portal:u=!1,modal:d=!0,transition:f=!1,...p}=e,h=Gn("Combobox.Options"),m=Io("Combobox.Options"),v=fi(c);v&&(u=!0);let[g,y]=mi(v),[b,x]=l.useState(null),S=hi(),T=ye(t,v?g:null,m.setOptionsElement,x),C=bt(h.optionsElement),P=$t(),[_,O]=Hn(f,b,P!==null?(P&Ce.Open)===Ce.Open:h.comboboxState===0);Vr(_,h.inputElement,m.closeCombobox);let I=h.__demoMode?!1:d&&h.comboboxState===0;Gr(I,C);let $=h.__demoMode?!1:d&&h.comboboxState===0;ci($,{allowed:l.useCallback(()=>[h.inputElement,h.buttonElement,h.optionsElement],[h.inputElement,h.buttonElement,h.optionsElement])}),ce(()=>{var k;h.optionsPropsRef.current.static=(k=e.static)!=null?k:!1},[h.optionsPropsRef,e.static]),ce(()=>{h.optionsPropsRef.current.hold=i},[h.optionsPropsRef,i]),WM(h.comboboxState===0,{container:h.optionsElement,accept(k){return k.getAttribute("role")==="option"?NodeFilter.FILTER_REJECT:k.hasAttribute("role")?NodeFilter.FILTER_SKIP:NodeFilter.FILTER_ACCEPT},walk(k){k.setAttribute("role","none")}});let G=jn([(n=h.buttonElement)==null?void 0:n.id]),W=l.useMemo(()=>({open:h.comboboxState===0,option:void 0}),[h.comboboxState]),B=j(()=>{m.setActivationTrigger(0)}),K=j(k=>{k.preventDefault(),m.setActivationTrigger(0)}),H=ot(v?S():{},{"aria-labelledby":G,role:"listbox","aria-multiselectable":h.mode===1?!0:void 0,id:a,ref:T,style:{...p.style,...y,"--input-width":rr(h.inputElement,!0).width,"--button-width":rr(h.buttonElement,!0).width},onWheel:h.activationTrigger===0?void 0:B,onMouseDown:K,...Wn(O)}),U=_&&h.comboboxState===1,q=ar(U,(o=h.virtual)==null?void 0:o.options),R=ar(U,h.value),D=j(k=>h.compare(R,k));if(h.virtual){if(q===void 0)throw new Error("Missing `options` in virtual mode");Object.assign(p,{children:w.createElement(ho.Provider,{value:q!==h.virtual.options?{...h,virtual:{...h.virtual,options:q}}:h},w.createElement(MT,{slot:W},p.children))})}let L=fe();return w.createElement(zr,{enabled:u?e.static||_:!1},w.createElement(ho.Provider,{value:h.mode===1?h:{...h,isSelected:D}},L({ourProps:H,theirProps:{...p,children:w.createElement(uT,{freeze:U},typeof p.children=="function"?(r=p.children)==null?void 0:r.call(p,W):p.children)},slot:W,defaultTag:_T,features:NT,visible:_,name:"Combobox.Options"})))}let FT="div";function LT(e,t){var n,o,r,s;let a=Gn("Combobox.Option"),i=Io("Combobox.Option"),c=l.useId(),{id:u=`headlessui-combobox-option-${c}`,value:d,disabled:f=(r=(o=(n=a.virtual)==null?void 0:n.disabled)==null?void 0:o.call(n,d))!=null?r:!1,order:p=null,...h}=e,m=Mh(a.inputElement),v=a.virtual?a.activeOptionIndex===a.calculateIndex(d):a.activeOptionIndex===null?!1:((s=a.options[a.activeOptionIndex])==null?void 0:s.id)===u,g=a.isSelected(d),y=l.useRef(null),b=Ye({disabled:f,value:d,domRef:y,order:p}),x=l.useContext(Fh),S=ye(t,y,x?x.measureElement:null),T=j(()=>{i.setIsTyping(!1),i.onChange(d)});ce(()=>i.registerOption(u,b),[b,u]);let C=l.useRef(!(a.virtual||a.__demoMode));ce(()=>{if(!a.virtual&&!a.__demoMode)return gt().requestAnimationFrame(()=>{C.current=!0})},[a.virtual,a.__demoMode]),ce(()=>{if(C.current&&a.comboboxState===0&&v&&a.activationTrigger!==0)return gt().requestAnimationFrame(()=>{var K,H;(H=(K=y.current)==null?void 0:K.scrollIntoView)==null||H.call(K,{block:"nearest"})})},[y,v,a.comboboxState,a.activationTrigger,a.activeOptionIndex]);let P=j(K=>{K.preventDefault(),K.button===yi.Left&&(f||(T(),Sh()||requestAnimationFrame(()=>m()),a.mode===0&&i.closeCombobox()))}),_=j(()=>{if(f)return i.goToOption(de.Nothing);let K=a.calculateIndex(d);i.goToOption(de.Specific,K)}),O=Th(),I=j(K=>O.update(K)),$=j(K=>{if(!O.wasMoved(K)||f||v)return;let H=a.calculateIndex(d);i.goToOption(de.Specific,H,0)}),G=j(K=>{O.wasMoved(K)&&(f||v&&(a.optionsPropsRef.current.hold||i.goToOption(de.Nothing)))}),W=l.useMemo(()=>({active:v,focus:v,selected:g,disabled:f}),[v,g,f]),B={id:u,ref:S,role:"option",tabIndex:f===!0?void 0:-1,"aria-disabled":f===!0?!0:void 0,"aria-selected":g,disabled:void 0,onMouseDown:P,onFocus:_,onPointerEnter:I,onMouseEnter:I,onPointerMove:$,onMouseMove:$,onPointerLeave:G,onMouseLeave:G};return fe()({ourProps:B,theirProps:h,slot:W,defaultTag:FT,name:"Combobox.Option"})}let jT=le(RT),BT=le(AT),VT=le(IT),WT=ii,HT=le($T),UT=le(LT),Z2=Object.assign(jT,{Input:VT,Button:BT,Label:WT,Options:HT,Option:UT});function GT(e,t=typeof document<"u"?document.defaultView:null,n){let o=Bn(e,"escape");Ur(t,"keydown",r=>{o&&(r.defaultPrevented||r.key===ne.Escape&&n(r))})}function YT(){var e;let[t]=l.useState(()=>typeof window<"u"&&typeof window.matchMedia=="function"?window.matchMedia("(pointer: coarse)"):null),[n,o]=l.useState((e=t?.matches)!=null?e:!1);return ce(()=>{if(!t)return;function r(s){o(s.matches)}return t.addEventListener("change",r),()=>t.removeEventListener("change",r)},[t]),n}function Lh({defaultContainers:e=[],portals:t,mainTreeNode:n}={}){let o=bt(n),r=j(()=>{var s,a;let i=[];for(let c of e)c!==null&&(c instanceof HTMLElement?i.push(c):"current"in c&&c.current instanceof HTMLElement&&i.push(c.current));if(t!=null&&t.current)for(let c of t.current)i.push(c);for(let c of(s=o?.querySelectorAll("html > *, body > *"))!=null?s:[])c!==document.body&&c!==document.head&&c instanceof HTMLElement&&c.id!=="headlessui-portal-root"&&(n&&(c.contains(n)||c.contains((a=n?.getRootNode())==null?void 0:a.host))||i.some(u=>c.contains(u))||i.push(c));return i});return{resolveContainers:r,contains:j(s=>r().some(a=>a.contains(s)))}}let jh=l.createContext(null);function ir({children:e,node:t}){let[n,o]=l.useState(null),r=xi(t??n);return w.createElement(jh.Provider,{value:r},e,r===null&&w.createElement(kt,{features:Tt.Hidden,ref:s=>{var a,i;if(s){for(let c of(i=(a=Dt(s))==null?void 0:a.querySelectorAll("html > *, body > *"))!=null?i:[])if(c!==document.body&&c!==document.head&&c instanceof HTMLElement&&c!=null&&c.contains(s)){o(c);break}}}}))}function xi(e=null){var t;return(t=l.useContext(jh))!=null?t:e}function Kr(){let e=l.useRef(!1);return ce(()=>(e.current=!0,()=>{e.current=!1}),[]),e}var tt=(e=>(e[e.Forwards=0]="Forwards",e[e.Backwards=1]="Backwards",e))(tt||{});function wi(){let e=l.useRef(0);return Ph(!0,"keydown",t=>{t.key==="Tab"&&(e.current=t.shiftKey?1:0)},!0),e}function Bh(e){if(!e)return new Set;if(typeof e=="function")return new Set(e());let t=new Set;for(let n of e.current)n.current instanceof HTMLElement&&t.add(n.current);return t}let zT="div";var sn=(e=>(e[e.None=0]="None",e[e.InitialFocus=1]="InitialFocus",e[e.TabLock=2]="TabLock",e[e.FocusLock=4]="FocusLock",e[e.RestoreFocus=8]="RestoreFocus",e[e.AutoFocus=16]="AutoFocus",e))(sn||{});function KT(e,t){let n=l.useRef(null),o=ye(n,t),{initialFocus:r,initialFocusFallback:s,containers:a,features:i=15,...c}=e;Do()||(i=0);let u=bt(n);QT(i,{ownerDocument:u});let d=JT(i,{ownerDocument:u,container:n,initialFocus:r,initialFocusFallback:s});ek(i,{ownerDocument:u,container:n,containers:a,previousActiveElement:d});let f=wi(),p=j(b=>{let x=n.current;x&&(S=>S())(()=>{ge(f.current,{[tt.Forwards]:()=>{Ae(x,Ee.First,{skipElements:[b.relatedTarget,s]})},[tt.Backwards]:()=>{Ae(x,Ee.Last,{skipElements:[b.relatedTarget,s]})}})})}),h=Bn(!!(i&2),"focus-trap#tab-lock"),m=It(),v=l.useRef(!1),g={ref:o,onKeyDown(b){b.key=="Tab"&&(v.current=!0,m.requestAnimationFrame(()=>{v.current=!1}))},onBlur(b){if(!(i&4))return;let x=Bh(a);n.current instanceof HTMLElement&&x.add(n.current);let S=b.relatedTarget;S instanceof HTMLElement&&S.dataset.headlessuiFocusGuard!=="true"&&(Vh(x,S)||(v.current?Ae(n.current,ge(f.current,{[tt.Forwards]:()=>Ee.Next,[tt.Backwards]:()=>Ee.Previous})|Ee.WrapAround,{relativeTo:b.target}):b.target instanceof HTMLElement&&_t(b.target)))}},y=fe();return w.createElement(w.Fragment,null,h&&w.createElement(kt,{as:"button",type:"button","data-headlessui-focus-guard":!0,onFocus:p,features:Tt.Focusable}),y({ourProps:g,theirProps:c,defaultTag:zT,name:"FocusTrap"}),h&&w.createElement(kt,{as:"button",type:"button","data-headlessui-focus-guard":!0,onFocus:p,features:Tt.Focusable}))}let qT=le(KT),XT=Object.assign(qT,{features:sn});function ZT(e=!0){let t=l.useRef(St.slice());return po(([n],[o])=>{o===!0&&n===!1&&Mo(()=>{t.current.splice(0)}),o===!1&&n===!0&&(t.current=St.slice())},[e,St,t]),j(()=>{var n;return(n=t.current.find(o=>o!=null&&o.isConnected))!=null?n:null})}function QT(e,{ownerDocument:t}){let n=!!(e&8),o=ZT(n);po(()=>{n||t?.activeElement===t?.body&&_t(o())},[n]),Ih(()=>{n&&_t(o())})}function JT(e,{ownerDocument:t,container:n,initialFocus:o,initialFocusFallback:r}){let s=l.useRef(null),a=Bn(!!(e&1),"focus-trap#initial-focus"),i=Kr();return po(()=>{if(e===0)return;if(!a){r!=null&&r.current&&_t(r.current);return}let c=n.current;c&&Mo(()=>{if(!i.current)return;let u=t?.activeElement;if(o!=null&&o.current){if(o?.current===u){s.current=u;return}}else if(c.contains(u)){s.current=u;return}if(o!=null&&o.current)_t(o.current);else{if(e&16){if(Ae(c,Ee.First|Ee.AutoFocus)!==Pt.Error)return}else if(Ae(c,Ee.First)!==Pt.Error)return;if(r!=null&&r.current&&(_t(r.current),t?.activeElement===r.current))return;console.warn("There are no focusable elements inside the <FocusTrap />")}s.current=t?.activeElement})},[r,a,e]),s}function ek(e,{ownerDocument:t,container:n,containers:o,previousActiveElement:r}){let s=Kr(),a=!!(e&4);Ur(t?.defaultView,"focus",i=>{if(!a||!s.current)return;let c=Bh(o);n.current instanceof HTMLElement&&c.add(n.current);let u=r.current;if(!u)return;let d=i.target;d&&d instanceof HTMLElement?Vh(c,d)?(r.current=d,_t(d)):(i.preventDefault(),i.stopPropagation(),_t(u)):_t(r.current)},!0)}function Vh(e,t){for(let n of e)if(n.contains(t))return!0;return!1}function Wh(e){var t;return!!(e.enter||e.enterFrom||e.enterTo||e.leave||e.leaveFrom||e.leaveTo)||((t=e.as)!=null?t:Uh)!==l.Fragment||w.Children.count(e.children)===1}let qr=l.createContext(null);qr.displayName="TransitionContext";var tk=(e=>(e.Visible="visible",e.Hidden="hidden",e))(tk||{});function nk(){let e=l.useContext(qr);if(e===null)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return e}function ok(){let e=l.useContext(Xr);if(e===null)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return e}let Xr=l.createContext(null);Xr.displayName="NestingContext";function Zr(e){return"children"in e?Zr(e.children):e.current.filter(({el:t})=>t.current!==null).filter(({state:t})=>t==="visible").length>0}function Hh(e,t){let n=Ye(e),o=l.useRef([]),r=Kr(),s=It(),a=j((h,m=Wt.Hidden)=>{let v=o.current.findIndex(({el:g})=>g===h);v!==-1&&(ge(m,{[Wt.Unmount](){o.current.splice(v,1)},[Wt.Hidden](){o.current[v].state="hidden"}}),s.microTask(()=>{var g;!Zr(o)&&r.current&&((g=n.current)==null||g.call(n))}))}),i=j(h=>{let m=o.current.find(({el:v})=>v===h);return m?m.state!=="visible"&&(m.state="visible"):o.current.push({el:h,state:"visible"}),()=>a(h,Wt.Unmount)}),c=l.useRef([]),u=l.useRef(Promise.resolve()),d=l.useRef({enter:[],leave:[]}
vendor: 4,347 bytes, line 42
42),f=j((h,m,v)=>{c.current.splice(0),t&&(t.chains.current[m]=t.chains.current[m].filter(([g])=>g!==h)),t?.chains.current[m].push([h,new Promise(g=>{c.current.push(g)})]),t?.chains.current[m].push([h,new Promise(g=>{Promise.all(d.current[m].map(([y,b])=>b)).then(()=>g())})]),m==="enter"?u.current=u.current.then(()=>t?.wait.current).then(()=>v(m)):v(m)}),p=j((h,m,v)=>{Promise.all(d.current[m].splice(0).map(([g,y])=>y)).then(()=>{var g;(g=c.current.shift())==null||g()}).then(()=>v(m))});return l.useMemo(()=>({children:o,register:i,unregister:a,onStart:f,onStop:p,wait:u,chains:d}),[i,a,o,f,p,d,u])}let Uh=l.Fragment,Gh=Ve.RenderStrategy;function rk(e,t){var n,o;let{transition:r=!0,beforeEnter:s,afterEnter:a,beforeLeave:i,afterLeave:c,enter:u,enterFrom:d,enterTo:f,entered:p,leave:h,leaveFrom:m,leaveTo:v,...g}=e,[y,b]=l.useState(null),x=l.useRef(null),S=Wh(e),T=ye(...S?[x,t,b]:t===null?[]:[t]),C=(n=g.unmount)==null||n?Wt.Unmount:Wt.Hidden,{show:P,appear:_,initial:O}=nk(),[I,$]=l.useState(P?"visible":"hidden"),G=ok(),{register:W,unregister:B}=G;ce(()=>W(x),[W,x]),ce(()=>{if(C===Wt.Hidden&&x.current){if(P&&I!=="visible"){$("visible");return}return ge(I,{hidden:()=>B(x),visible:()=>W(x)})}},[I,x,W,B,P,C]);let K=Do();ce(()=>{if(S&&K&&I==="visible"&&x.current===null)throw new Error("Did you forget to passthrough the `ref` to the actual DOM node?")},[x,I,K,S]);let H=O&&!_,U=_&&P&&O,q=l.useRef(!1),R=Hh(()=>{q.current||($("hidden"),B(x))},G),D=j(N=>{q.current=!0;let Y=N?"enter":"leave";R.onStart(x,Y,te=>{te==="enter"?s?.():te==="leave"&&i?.()})}),L=j(N=>{let Y=N?"enter":"leave";q.current=!1,R.onStop(x,Y,te=>{te==="enter"?a?.():te==="leave"&&c?.()}),Y==="leave"&&!Zr(R)&&($("hidden"),B(x))});l.useEffect(()=>{S&&r||(D(P),L(P))},[P,S,r]);let k=!(!r||!S||!K||H),[,M]=Hn(k,y,P,{start:D,end:L}),F=Vt({ref:T,className:((o=na(g.className,U&&u,U&&d,M.enter&&u,M.enter&&M.closed&&d,M.enter&&!M.closed&&f,M.leave&&h,M.leave&&!M.closed&&m,M.leave&&M.closed&&v,!M.transition&&P&&p))==null?void 0:o.trim())||void 0,...Wn(M)}),A=0;I==="visible"&&(A|=Ce.Open),I==="hidden"&&(A|=Ce.Closed),M.enter&&(A|=Ce.Opening),M.leave&&(A|=Ce.Closing);let z=fe();return w.createElement(Xr.Provider,{value:R},w.createElement(Ro,{value:A},z({ourProps:F,theirProps:g,defaultTag:Uh,features:Gh,visible:I==="visible",name:"Transition.Child"})))}function sk(e,t){let{show:n,appear:o=!1,unmount:r=!0,...s}=e,a=l.useRef(null),i=Wh(e),c=ye(...i?[a,t]:t===null?[]:[t]);Do();let u=$t();if(n===void 0&&u!==null&&(n=(u&Ce.Open)===Ce.Open),n===void 0)throw new Error("A <Transition /> is used but it is missing a `show={true | false}` prop.");let[d,f]=l.useState(n?"visible":"hidden"),p=Hh(()=>{n||f("hidden")}),[h,m]=l.useState(!0),v=l.useRef([n]);ce(()=>{h!==!1&&v.current[v.current.length-1]!==n&&(v.current.push(n),m(!1))},[v,n]);let g=l.useMemo(()=>({show:n,appear:o,initial:h}),[n,o,h]);ce(()=>{n?f("visible"):!Zr(p)&&a.current!==null&&f("hidden")},[n,p]);let y={unmount:r},b=j(()=>{var T;h&&m(!1),(T=e.beforeEnter)==null||T.call(e)}),x=j(()=>{var T;h&&m(!1),(T=e.beforeLeave)==null||T.call(e)}),S=fe();return w.createElement(Xr.Provider,{value:p},w.createElement(qr.Provider,{value:g},S({ourProps:{...y,as:l.Fragment,children:w.createElement(Yh,{ref:c,...y,...s,beforeEnter:b,beforeLeave:x})},theirProps:{},defaultTag:l.Fragment,features:Gh,visible:d==="visible",name:"Transition"})))}function ak(e,t){let n=l.useContext(qr)!==null,o=$t()!==null;return w.createElement(w.Fragment,null,!n&&o?w.createElement(aa,{ref:t,...e}):w.createElement(Yh,{ref:t,...e}))}let aa=le(sk),Yh=le(rk),Ei=le(ak),ik=Object.assign(aa,{Child:Ei,Root:aa});var lk=(e=>(e[e.Open=0]="Open",e[e.Closed=1]="Closed",e))(lk||{}),ck=(e=>(e[e.SetTitleId=0]="SetTitleId",e))(ck||{});let uk={0(e,t){return e.titleId===t.id?e:{...e,titleId:t.id}}},Ci=l.createContext(null);Ci.displayName="DialogContext";function Qr(e){let t=l.useContext(Ci);if(t===null){let n=new Error(`<${e} /> is missing a parent <Dialog /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,Qr),n}return t}function dk(e,t){return ge(t.type,uk,e,t)}let bc=le(function(e,t){let n=l.useId(),{id:o=`headlessui-dialog-${n}`,open:r,onClose:s,initialFocus:a,role:i="dialog",autoFocus:c=!0,__demoMode:u=!1,unmount:d=!1,...f}=e,p=l.useRef(!1);i=(function(){return i==="dialog"||i==="alertdialog"?i:(p.current||(p.current=!0,
vendor: 45,712 bytes, line 42
42console.warn(`Invalid role [${i}] passed to <Dialog />. Only \`dialog\` and and \`alertdialog\` are supported. Using \`dialog\` instead.`)),"dialog")})();let h=$t();r===void 0&&h!==null&&(r=(h&Ce.Open)===Ce.Open);let m=l.useRef(null),v=ye(m,t),g=bt(m),y=r?0:1,[b,x]=l.useReducer(dk,{titleId:null,descriptionId:null,panelRef:l.createRef()}),S=j(()=>s(!1)),T=j(L=>x({type:0,id:L})),C=Do()?y===0:!1,[P,_]=Nh(),O={get current(){var L;return(L=b.panelRef.current)!=null?L:m.current}},I=xi(),{resolveContainers:$}=Lh({mainTreeNode:I,portals:P,defaultContainers:[O]}),G=h!==null?(h&Ce.Closing)===Ce.Closing:!1;ci(u||G?!1:C,{allowed:j(()=>{var L,k;return[(k=(L=m.current)==null?void 0:L.closest("[data-headlessui-portal]"))!=null?k:null]}),disallowed:j(()=>{var L;return[(L=I?.closest("body > *:not(#headlessui-portal-root)"))!=null?L:null]})}),Hr(C,$,L=>{L.preventDefault(),S()}),GT(C,g?.defaultView,L=>{L.preventDefault(),L.stopPropagation(),document.activeElement&&"blur"in document.activeElement&&typeof document.activeElement.blur=="function"&&document.activeElement.blur(),S()}),Gr(u||G?!1:C,g,$),Vr(C,m,S);let[W,B]=gh(),K=l.useMemo(()=>[{dialogState:y,close:S,setTitleId:T,unmount:d},b],[y,b,S,T,d]),H=l.useMemo(()=>({open:y===0}),[y]),U={ref:v,id:o,role:i,tabIndex:-1,"aria-modal":u?void 0:y===0?!0:void 0,"aria-labelledby":b.titleId,"aria-describedby":W,unmount:d},q=!YT(),R=sn.None;C&&!u&&(R|=sn.RestoreFocus,R|=sn.TabLock,c&&(R|=sn.AutoFocus),q&&(R|=sn.InitialFocus));let D=fe();return w.createElement(gi,null,w.createElement(yc,{force:!0},w.createElement(zr,null,w.createElement(Ci.Provider,{value:K},w.createElement($h,{target:m},w.createElement(yc,{force:!1},w.createElement(B,{slot:H},w.createElement(_,null,w.createElement(XT,{initialFocus:a,initialFocusFallback:m,containers:$,features:R},w.createElement(li,{value:S},D({ourProps:U,theirProps:f,slot:H,defaultTag:fk,features:pk,visible:y===0,name:"Dialog"})))))))))))}),fk="div",pk=Ve.RenderStrategy|Ve.Static;function hk(e,t){let{transition:n=!1,open:o,...r}=e,s=$t(),a=e.hasOwnProperty("open")||s!==null,i=e.hasOwnProperty("onClose");if(!a&&!i)throw new Error("You have to provide an `open` and an `onClose` prop to the `Dialog` component.");if(!a)throw new Error("You provided an `onClose` prop to the `Dialog`, but forgot an `open` prop.");if(!i)throw new Error("You provided an `open` prop to the `Dialog`, but forgot an `onClose` prop.");if(!s&&typeof e.open!="boolean")throw new Error(`You provided an \`open\` prop to the \`Dialog\`, but the value is not a boolean. Received: ${e.open}`);if(typeof e.onClose!="function")throw new Error(`You provided an \`onClose\` prop to the \`Dialog\`, but the value is not a function. Received: ${e.onClose}`);return(o!==void 0||n)&&!r.static?w.createElement(ir,null,w.createElement(ik,{show:o,transition:n,unmount:r.unmount},w.createElement(bc,{ref:t,...r}))):w.createElement(ir,null,w.createElement(bc,{ref:t,open:o,...r}))}let mk="div";function vk(e,t){let n=l.useId(),{id:o=`headlessui-dialog-panel-${n}`,transition:r=!1,...s}=e,[{dialogState:a,unmount:i},c]=Qr("Dialog.Panel"),u=ye(t,c.panelRef),d=l.useMemo(()=>({open:a===0}),[a]),f=j(g=>{g.stopPropagation()}),p={ref:u,id:o,onClick:f},h=r?Ei:l.Fragment,m=r?{unmount:i}:{},v=fe();return w.createElement(h,{...m},v({ourProps:p,theirProps:s,slot:d,defaultTag:mk,name:"Dialog.Panel"}))}let gk="div";function yk(e,t){let{transition:n=!1,...o}=e,[{dialogState:r,unmount:s}]=Qr("Dialog.Backdrop"),a=l.useMemo(()=>({open:r===0}),[r]),i={ref:t,"aria-hidden":!0},c=n?Ei:l.Fragment,u=n?{unmount:s}:{},d=fe();return w.createElement(c,{...u},d({ourProps:i,theirProps:o,slot:a,defaultTag:gk,name:"Dialog.Backdrop"}))}let bk="h2";function xk(e,t){let n=l.useId(),{id:o=`headlessui-dialog-title-${n}`,...r}=e,[{dialogState:s,setTitleId:a}]=Qr("Dialog.Title"),i=ye(t);l.useEffect(()=>(a(o),()=>a(null)),[o,a]);let c=l.useMemo(()=>({open:s===0}),[s]),u={ref:i,id:o};return fe()({ourProps:u,theirProps:r,slot:c,defaultTag:bk,name:"Dialog.Title"})}let wk=le(hk),Ek=le(vk),Q2=le(yk),Ck=le(xk),J2=Object.assign(wk,{Panel:Ek,Title:Ck,Description:yh});var xc;let Sk=(xc=w.startTransition)!=null?xc:function(e){e()};var Pk=(e=>(e[e.Open=0]="Open",e[e.Closed=1]="Closed",e))(Pk||{}),Mk=(e=>(e[e.ToggleDisclosure=0]="ToggleDisclosure",e[e.CloseDisclosure=1]="CloseDisclosure",e[e.SetButtonId=2]="SetButtonId",e[e.SetPanelId=3]="SetPanelId",e[e.SetButtonElement=4]="SetButtonElement",e[e.SetPanelElement=5]="SetPanelElement",e))(Mk||{});let Tk={0:e=>({...e,disclosureState:ge(e.disclosureState,{0:1,1:0})}),1:e=>e.disclosureState===1?e:{...e,disclosureState:1},2(e,t){return e.buttonId===t.buttonId?e:{...e,buttonId:t.buttonId}},3(e,t){return e.panelId===t.panelId?e:{...e,panelId:t.panelId}},4(e,t){return e.buttonElement===t.element?e:{...e,buttonElement:t.element}},5(e,t){return e.panelElement===t.element?e:{...e,panelElement:t.element}}},Si=l.createContext(null);Si.displayName="DisclosureContext";function Pi(e){let t=l.useContext(Si);if(t===null){let n=new Error(`<${e} /> is missing a parent <Disclosure /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,Pi),n}return t}let Mi=l.createContext(null);Mi.displayName="DisclosureAPIContext";function zh(e){let t=l.useContext(Mi);if(t===null){let n=new Error(`<${e} /> is missing a parent <Disclosure /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,zh),n}return t}let Ti=l.createContext(null);Ti.displayName="DisclosurePanelContext";function kk(){return l.useContext(Ti)}function Rk(e,t){return ge(t.type,Tk,e,t)}let Dk=l.Fragment;function Ik(e,t){let{defaultOpen:n=!1,...o}=e,r=l.useRef(null),s=ye(t,ri(v=>{r.current=v},e.as===void 0||e.as===l.Fragment)),a=l.useReducer(Rk,{disclosureState:n?0:1,buttonElement:null,panelElement:null,buttonId:null,panelId:null}),[{disclosureState:i,buttonId:c},u]=a,d=j(v=>{u({type:1});let g=Dt(r);if(!g||!c)return;let y=v?v instanceof HTMLElement?v:v.current instanceof HTMLElement?v.current:g.getElementById(c):g.getElementById(c);y?.focus()}),f=l.useMemo(()=>({close:d}),[d]),p=l.useMemo(()=>({open:i===0,close:d}),[i,d]),h={ref:s},m=fe();return w.createElement(Si.Provider,{value:a},w.createElement(Mi.Provider,{value:f},w.createElement(li,{value:d},w.createElement(Ro,{value:ge(i,{0:Ce.Open,1:Ce.Closed})},m({ourProps:h,theirProps:o,slot:p,defaultTag:Dk,name:"Disclosure"})))))}let Ok="button";function Ak(e,t){let n=l.useId(),{id:o=`headlessui-disclosure-button-${n}`,disabled:r=!1,autoFocus:s=!1,...a}=e,[i,c]=Pi("Disclosure.Button"),u=kk(),d=u===null?!1:u===i.panelId,f=l.useRef(null),p=ye(f,t,j(O=>{if(!d)return c({type:4,element:O})}));l.useEffect(()=>{if(!d)return c({type:2,buttonId:o}),()=>{c({type:2,buttonId:null})}},[o,c,d]);let h=j(O=>{var I;if(d){if(i.disclosureState===1)return;switch(O.key){case ne.Space:case ne.Enter:O.preventDefault(),O.stopPropagation(),c({type:0}),(I=i.buttonElement)==null||I.focus();break}}else switch(O.key){case ne.Space:case ne.Enter:O.preventDefault(),O.stopPropagation(),c({type:0});break}}),m=j(O=>{switch(O.key){case ne.Space:O.preventDefault();break}}),v=j(O=>{var I;Ln(O.currentTarget)||r||(d?(c({type:0}),(I=i.buttonElement)==null||I.focus()):c({type:0}))}),{isFocusVisible:g,focusProps:y}=zt({autoFocus:s}),{isHovered:b,hoverProps:x}=hn({isDisabled:r}),{pressed:S,pressProps:T}=Fn({disabled:r}),C=l.useMemo(()=>({open:i.disclosureState===0,hover:b,active:S,disabled:r,focus:g,autofocus:s}),[i,b,S,g,r,s]),P=Vn(e,i.buttonElement),_=ot(d?{ref:p,type:P,disabled:r||void 0,autoFocus:s,onKeyDown:h,onClick:v}:{ref:p,id:o,type:P,"aria-expanded":i.disclosureState===0,"aria-controls":i.panelElement?i.panelId:void 0,disabled:r||void 0,autoFocus:s,onKeyDown:h,onKeyUp:m,onClick:v},y,x,T);return fe()({ourProps:_,theirProps:a,slot:C,defaultTag:Ok,name:"Disclosure.Button"})}let _k="div",Nk=Ve.RenderStrategy|Ve.Static;function $k(e,t){let n=l.useId(),{id:o=`headlessui-disclosure-panel-${n}`,transition:r=!1,...s}=e,[a,i]=Pi("Disclosure.Panel"),{close:c}=zh("Disclosure.Panel"),[u,d]=l.useState(null),f=ye(t,j(b=>{Sk(()=>i({type:5,element:b}))}),d);l.useEffect(()=>(i({type:3,panelId:o}),()=>{i({type:3,panelId:null})}),[o,i]);let p=$t(),[h,m]=Hn(r,u,p!==null?(p&Ce.Open)===Ce.Open:a.disclosureState===0),v=l.useMemo(()=>({open:a.disclosureState===0,close:c}),[a.disclosureState,c]),g={ref:f,id:o,...Wn(m)},y=fe();return w.createElement(gi,null,w.createElement(Ti.Provider,{value:a.panelId},y({ourProps:g,theirProps:s,slot:v,defaultTag:_k,features:Nk,visible:h,name:"Disclosure.Panel"})))}let Fk=le(Ik),Lk=le(Ak),jk=le($k),eO=Object.assign(Fk,{Button:Lk,Panel:jk});function Bk(e,t){let n=l.useRef({left:0,top:0});if(ce(()=>{if(!t)return;let r=t.getBoundingClientRect();r&&(n.current=r)},[e,t]),t==null||!e||t===document.activeElement)return!1;let o=t.getBoundingClientRect();return o.top!==n.current.top||o.left!==n.current.left}let wc=/([\u2700-\u27BF]|[\uE000-\uF8FF]|\uD83C[\uDC00-\uDFFF]|\uD83D[\uDC00-\uDFFF]|[\u2011-\u26FF]|\uD83E[\uDD10-\uDDFF])/g;function Ec(e){var t,n;let o=(t=e.innerText)!=null?t:"",r=e.cloneNode(!0);if(!(r instanceof HTMLElement))return o;let s=!1;for(let i of r.querySelectorAll('[hidden],[aria-hidden],[role="img"]'))i.remove(),s=!0;let a=s?(n=r.innerText)!=null?n:"":o;return wc.test(a)&&(a=a.replace(wc,"")),a}function Vk(e){let t=e.getAttribute("aria-label");if(typeof t=="string")return t.trim();let n=e.getAttribute("aria-labelledby");if(n){let o=n.split(" ").map(r=>{let s=document.getElementById(r);if(s){let a=s.getAttribute("aria-label");return typeof a=="string"?a.trim():Ec(s).trim()}return null}).filter(Boolean);if(o.length>0)return o.join(", ")}return Ec(e).trim()}function Wk(e){let t=l.useRef(""),n=l.useRef("");return j(()=>{let o=e.current;if(!o)return"";let r=o.innerText;if(t.current===r)return n.current;let s=Vk(o).trim().toLowerCase();return t.current=r,n.current=s,s})}var Hk=(e=>(e[e.Open=0]="Open",e[e.Closed=1]="Closed",e))(Hk||{}),Uk=(e=>(e[e.Single=0]="Single",e[e.Multi=1]="Multi",e))(Uk||{}),Gk=(e=>(e[e.Pointer=0]="Pointer",e[e.Other=1]="Other",e))(Gk||{}),Yk=(e=>(e[e.OpenListbox=0]="OpenListbox",e[e.CloseListbox=1]="CloseListbox",e[e.GoToOption=2]="GoToOption",e[e.Search=3]="Search",e[e.ClearSearch=4]="ClearSearch",e[e.RegisterOption=5]="RegisterOption",e[e.UnregisterOption=6]="UnregisterOption",e[e.SetButtonElement=7]="SetButtonElement",e[e.SetOptionsElement=8]="SetOptionsElement",e))(Yk||{});function As(e,t=n=>n){let n=e.activeOptionIndex!==null?e.options[e.activeOptionIndex]:null,o=Ht(t(e.options.slice()),s=>s.dataRef.current.domRef.current),r=n?o.indexOf(n):null;return r===-1&&(r=null),{options:o,activeOptionIndex:r}}let zk={1(e){return e.dataRef.current.disabled||e.listboxState===1?e:{...e,activeOptionIndex:null,listboxState:1,__demoMode:!1}},0(e){if(e.dataRef.current.disabled||e.listboxState===0)return e;let t=e.activeOptionIndex,{isSelected:n}=e.dataRef.current,o=e.options.findIndex(r=>n(r.dataRef.current.value));return o!==-1&&(t=o),{...e,listboxState:0,activeOptionIndex:t,__demoMode:!1}},2(e,t){var n,o,r,s,a;if(e.dataRef.current.disabled||e.listboxState===1)return e;let i={...e,searchQuery:"",activationTrigger:(n=t.trigger)!=null?n:1,__demoMode:!1};if(t.focus===de.Nothing)return{...i,activeOptionIndex:null};if(t.focus===de.Specific)return{...i,activeOptionIndex:e.options.findIndex(d=>d.id===t.id)};if(t.focus===de.Previous){let d=e.activeOptionIndex;if(d!==null){let f=e.options[d].dataRef.current.domRef,p=so(t,{resolveItems:()=>e.options,resolveActiveIndex:()=>e.activeOptionIndex,resolveId:h=>h.id,resolveDisabled:h=>h.dataRef.current.disabled});if(p!==null){let h=e.options[p].dataRef.current.domRef;if(((o=f.current)==null?void 0:o.previousElementSibling)===h.current||((r=h.current)==null?void 0:r.previousElementSibling)===null)return{...i,activeOptionIndex:p}}}}else if(t.focus===de.Next){let d=e.activeOptionIndex;if(d!==null){let f=e.options[d].dataRef.current.domRef,p=so(t,{resolveItems:()=>e.options,resolveActiveIndex:()=>e.activeOptionIndex,resolveId:h=>h.id,resolveDisabled:h=>h.dataRef.current.disabled});if(p!==null){let h=e.options[p].dataRef.current.domRef;if(((s=f.current)==null?void 0:s.nextElementSibling)===h.current||((a=h.current)==null?void 0:a.nextElementSibling)===null)return{...i,activeOptionIndex:p}}}}let c=As(e),u=so(t,{resolveItems:()=>c.options,resolveActiveIndex:()=>c.activeOptionIndex,resolveId:d=>d.id,resolveDisabled:d=>d.dataRef.current.disabled});return{...i,...c,activeOptionIndex:u}},3:(e,t)=>{if(e.dataRef.current.disabled||e.listboxState===1)return e;let n=e.searchQuery!==""?0:1,o=e.searchQuery+t.value.toLowerCase(),r=(e.activeOptionIndex!==null?e.options.slice(e.activeOptionIndex+n).concat(e.options.slice(0,e.activeOptionIndex+n)):e.options).find(a=>{var i;return!a.dataRef.current.disabled&&((i=a.dataRef.current.textValue)==null?void 0:i.startsWith(o))}),s=r?e.options.indexOf(r):-1;return s===-1||s===e.activeOptionIndex?{...e,searchQuery:o}:{...e,searchQuery:o,activeOptionIndex:s,activationTrigger:1}},4(e){return e.dataRef.current.disabled||e.listboxState===1||e.searchQuery===""?e:{...e,searchQuery:""}},5:(e,t)=>{let n={id:t.id,dataRef:t.dataRef},o=As(e,r=>[...r,n]);return e.activeOptionIndex===null&&e.dataRef.current.isSelected(t.dataRef.current.value)&&(o.activeOptionIndex=o.options.indexOf(n)),{...e,...o}},6:(e,t)=>{let n=As(e,o=>{let r=o.findIndex(s=>s.id===t.id);return r!==-1&&o.splice(r,1),o});return{...e,...n,activationTrigger:1}},7:(e,t)=>e.buttonElement===t.element?e:{...e,buttonElement:t.element},8:(e,t)=>e.optionsElement===t.element?e:{...e,optionsElement:t.element}},ki=l.createContext(null);ki.displayName="ListboxActionsContext";function Jr(e){let t=l.useContext(ki);if(t===null){let n=new Error(`<${e} /> is missing a parent <Listbox /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,Jr),n}return t}let es=l.createContext(null);es.displayName="ListboxDataContext";function Oo(e){let t=l.useContext(es);if(t===null){let n=new Error(`<${e} /> is missing a parent <Listbox /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,Oo),n}return t}function Kk(e,t){return ge(t.type,zk,e,t)}let qk=l.Fragment;function Xk(e,t){var n;let o=To(),{value:r,defaultValue:s,form:a,name:i,onChange:c,by:u,invalid:d=!1,disabled:f=o||!1,horizontal:p=!1,multiple:h=!1,__demoMode:m=!1,...v}=e;const g=p?"horizontal":"vertical";let y=ye(t),b=ni(s),[x=h?[]:void 0,S]=ti(r,c,b),[T,C]=l.useReducer(Kk,{dataRef:l.createRef(),listboxState:m?0:1,options:[],searchQuery:"",activeOptionIndex:null,activationTrigger:1,optionsVisible:!1,buttonElement:null,optionsElement:null,__demoMode:m}),P=l.useRef({static:!1,hold:!1}),_=l.useRef(new Map),O=xh(u),I=l.useCallback(ee=>ge($.mode,{1:()=>x.some(ue=>O(ue,ee)),0:()=>O(x,ee)}),[x]),$=l.useMemo(()=>({...T,value:x,disabled:f,invalid:d,mode:h?1:0,orientation:g,compare:O,isSelected:I,optionsPropsRef:P,listRef:_}),[x,f,d,h,T,_]);ce(()=>{T.dataRef.current=$},[$]);let G=$.listboxState===0;Hr(G,[$.buttonElement,$.optionsElement],(ee,ue)=>{var V;C({type:1}),ui(ue,Wr.Loose)||(ee.preventDefault(),(V=$.buttonElement)==null||V.focus())});let W=l.useMemo(()=>({open:$.listboxState===0,disabled:f,invalid:d,value:x}),[$,f,x,d]),B=j(ee=>{let ue=$.options.find(V=>V.id===ee);ue&&L(ue.dataRef.current.value)}),K=j(()=>{if($.activeOptionIndex!==null){let{dataRef:ee,id:ue}=$.options[$.activeOptionIndex];L(ee.current.value),C({type:2,focus:de.Specific,id:ue})}}),H=j(()=>C({type:0})),U=j(()=>C({type:1})),q=It(),R=j((ee,ue,V)=>{q.dispose(),q.microTask(()=>ee===de.Specific?C({type:2,focus:de.Specific,id:ue,trigger:V}):C({type:2,focus:ee,trigger:V}))}),D=j((ee,ue)=>(C({type:5,id:ee,dataRef:ue}),()=>C({type:6,id:ee}))),L=j(ee=>ge($.mode,{0(){return S?.(ee)},1(){let ue=$.value.slice(),V=ue.findIndex(Q=>O(Q,ee));return V===-1?ue.push(ee):ue.splice(V,1),S?.(ue)}})),k=j(ee=>C({type:3,value:ee})),M=j(()=>C({type:4})),F=j(ee=>{C({type:7,element:ee})}),A=j(ee=>{C({type:8,element:ee})}),z=l.useMemo(()=>({onChange:L,registerOption:D,goToOption:R,closeListbox:U,openListbox:H,selectActiveOption:K,selectOption:B,search:k,clearSearch:M,setButtonElement:F,setOptionsElement:A}),[]),[N,Y]=ai({inherit:!0}),te={ref:y},ae=l.useCallback(()=>{if(b!==void 0)return S?.(b)},[S,b]),pe=fe();return w.createElement(Y,{value:N,props:{htmlFor:(n=$.buttonElement)==null?void 0:n.id},slot:{open:$.listboxState===0,disabled:f}},w.createElement(vi,null,w.createElement(ki.Provider,{value:z},w.createElement(es.Provider,{value:$},w.createElement(Ro,{value:ge($.listboxState,{0:Ce.Open,1:Ce.Closed})},i!=null&&x!=null&&w.createElement(oi,{disabled:f,data:{[i]:x},form:a,onReset:ae}),pe({ourProps:te,theirProps:v,slot:W,defaultTag:qk,name:"Listbox"}))))))}let Zk="button";function Qk(e,t){var n;let o=Oo("Listbox.Button"),r=Jr("Listbox.Button"),s=l.useId(),a=Lr(),{id:i=a||`headlessui-listbox-button-${s}`,disabled:c=o.disabled||!1,autoFocus:u=!1,...d}=e,f=ye(t,pi(),r.setButtonElement),p=iT(),h=j($=>{switch($.key){case ne.Enter:hh($.currentTarget);break;case ne.Space:case ne.ArrowDown:$.preventDefault(),Te.flushSync(()=>r.openListbox()),o.value||r.goToOption(de.First);break;case ne.ArrowUp:$.preventDefault(),Te.flushSync(()=>r.openListbox()),o.value||r.goToOption(de.Last);break}}),m=j($=>{switch($.key){case ne.Space:$.preventDefault();break}}),v=j($=>{var G;if(Ln($.currentTarget))return $.preventDefault();o.listboxState===0?(Te.flushSync(()=>r.closeListbox()),(G=o.buttonElement)==null||G.focus({preventScroll:!0})):($.preventDefault(),r.openListbox())}),g=j($=>$.preventDefault()),y=jn([i]),b=si(),{isFocusVisible:x,focusProps:S}=zt({autoFocus:u}),{isHovered:T,hoverProps:C}=hn({isDisabled:c}),{pressed:P,pressProps:_}=Fn({disabled:c}),O=l.useMemo(()=>({open:o.listboxState===0,active:P||o.listboxState===0,disabled:c,invalid:o.invalid,value:o.value,hover:T,focus:x,autofocus:u}),[o.listboxState,o.value,c,T,x,P,o.invalid,u]),I=ot(p(),{ref:f,id:i,type:Vn(e,o.buttonElement),"aria-haspopup":"listbox","aria-controls":(n=o.optionsElement)==null?void 0:n.id,"aria-expanded":o.listboxState===0,"aria-labelledby":y,"aria-describedby":b,disabled:c||void 0,autoFocus:u,onKeyDown:h,onKeyUp:m,onKeyPress:g,onClick:v},S,C,_);return fe()({ourProps:I,theirProps:d,slot:O,defaultTag:Zk,name:"Listbox.Button"})}let Kh=l.createContext(!1),Jk="div",eR=Ve.RenderStrategy|Ve.Static;function tR(e,t){var n,o;let r=l.useId(),{id:s=`headlessui-listbox-options-${r}`,anchor:a,portal:i=!1,modal:c=!0,transition:u=!1,...d}=e,f=fi(a),[p,h]=l.useState(null);f&&(i=!0);let m=Oo("Listbox.Options"),v=Jr("Listbox.Options"),g=bt(m.optionsElement),y=$t(),[b,x]=Hn(u,p,y!==null?(y&Ce.Open)===Ce.Open:m.listboxState===0);Vr(b,m.buttonElement,v.closeListbox);let S=m.__demoMode?!1:c&&m.listboxState===0;Gr(S,g);let T=m.__demoMode?!1:c&&m.listboxState===0;ci(T,{allowed:l.useCallback(()=>[m.buttonElement,m.optionsElement],[m.buttonElement,m.optionsElement])});let C=m.listboxState!==0,P=Bk(C,m.buttonElement)?!1:b,_=b&&m.listboxState===1,O=ar(_,m.value),I=j(M=>m.compare(O,M)),$=l.useMemo(()=>{var M;if(f==null||!((M=f?.to)!=null&&M.includes("selection")))return null;let F=m.options.findIndex(A=>I(A.dataRef.current.value));return F===-1&&(F=0),F},[f,m.options]),G=(()=>{if(f==null)return;if($===null)return{...f,inner:void 0};let M=Array.from(m.listRef.current.values());return{...f,inner:{listRef:{current:M},index:$}}})(),[W,B]=mi(G),K=hi(),H=ye(t,f?W:null,v.setOptionsElement,h),U=It();l.useEffect(()=>{var M;let F=m.optionsElement;F&&m.listboxState===0&&F!==((M=Dt(F))==null?void 0:M.activeElement)&&F?.focus({preventScroll:!0})},[m.listboxState,m.optionsElement]);let q=j(M=>{var F,A;switch(U.dispose(),M.key){case ne.Space:if(m.searchQuery!=="")return M.preventDefault(),M.stopPropagation(),v.search(M.key);case ne.Enter:if(M.preventDefault(),M.stopPropagation(),m.activeOptionIndex!==null){let{dataRef:z}=m.options[m.activeOptionIndex];v.onChange(z.current.value)}m.mode===0&&(Te.flushSync(()=>v.closeListbox()),(F=m.buttonElement)==null||F.focus({preventScroll:!0}));break;case ge(m.orientation,{vertical:ne.ArrowDown,horizontal:ne.ArrowRight}):return M.preventDefault(),M.stopPropagation(),v.goToOption(de.Next);case ge(m.orientation,{vertical:ne.ArrowUp,horizontal:ne.ArrowLeft}):return M.preventDefault(),M.stopPropagation(),v.goToOption(de.Previous);case ne.Home:case ne.PageUp:return M.preventDefault(),M.stopPropagation(),v.goToOption(de.First);case ne.End:case ne.PageDown:return M.preventDefault(),M.stopPropagation(),v.goToOption(de.Last);case ne.Escape:M.preventDefault(),M.stopPropagation(),Te.flushSync(()=>v.closeListbox()),(A=m.buttonElement)==null||A.focus({preventScroll:!0});return;case ne.Tab:M.preventDefault(),M.stopPropagation(),Te.flushSync(()=>v.closeListbox()),RM(m.buttonElement,M.shiftKey?Ee.Previous:Ee.Next);break;default:M.key.length===1&&(v.search(M.key),U.setTimeout(()=>v.clearSearch(),350));break}}),R=(n=m.buttonElement)==null?void 0:n.id,D=l.useMemo(()=>({open:m.listboxState===0}),[m.listboxState]),L=ot(f?K():{},{id:s,ref:H,"aria-activedescendant":m.activeOptionIndex===null||(o=m.options[m.activeOptionIndex])==null?void 0:o.id,"aria-multiselectable":m.mode===1?!0:void 0,"aria-labelledby":R,"aria-orientation":m.orientation,onKeyDown:q,role:"listbox",tabIndex:m.listboxState===0?0:void 0,style:{...d.style,...B,"--button-width":rr(m.buttonElement,!0).width},...Wn(x)}),k=fe();return w.createElement(zr,{enabled:i?e.static||b:!1},w.createElement(es.Provider,{value:m.mode===1?m:{...m,isSelected:I}},k({ourProps:L,theirProps:d,slot:D,defaultTag:Jk,features:eR,visible:P,name:"Listbox.Options"})))}let nR="div";function oR(e,t){let n=l.useId(),{id:o=`headlessui-listbox-option-${n}`,disabled:r=!1,value:s,...a}=e,i=l.useContext(Kh)===!0,c=Oo("Listbox.Option"),u=Jr("Listbox.Option"),d=c.activeOptionIndex!==null?c.options[c.activeOptionIndex].id===o:!1,f=c.isSelected(s),p=l.useRef(null),h=Wk(p),m=Ye({disabled:r,value:s,domRef:p,get textValue(){return h()}}),v=ye(t,p,O=>{O?c.listRef.current.set(o,O):c.listRef.current.delete(o)});ce(()=>{if(!c.__demoMode&&c.listboxState===0&&d&&c.activationTrigger!==0)return gt().requestAnimationFrame(()=>{var O,I;(I=(O=p.current)==null?void 0:O.scrollIntoView)==null||I.call(O,{block:"nearest"})})},[p,d,c.__demoMode,c.listboxState,c.activationTrigger,c.activeOptionIndex]),ce(()=>{if(!i)return u.registerOption(o,m)},[m,o,i]);let g=j(O=>{var I;if(r)return O.preventDefault();u.onChange(s),c.mode===0&&(Te.flushSync(()=>u.closeListbox()),(I=c.buttonElement)==null||I.focus({preventScroll:!0}))}),y=j(()=>{if(r)return u.goToOption(de.Nothing);u.goToOption(de.Specific,o)}),b=Th(),x=j(O=>{b.update(O),!r&&(d||u.goToOption(de.Specific,o,0))}),S=j(O=>{b.wasMoved(O)&&(r||d||u.goToOption(de.Specific,o,0))}),T=j(O=>{b.wasMoved(O)&&(r||d&&u.goToOption(de.Nothing))}),C=l.useMemo(()=>({active:d,focus:d,selected:f,disabled:r,selectedOption:f&&i}),[d,f,r,i]),P=i?{}:{id:o,ref:v,role:"option",tabIndex:r===!0?void 0:-1,"aria-disabled":r===!0?!0:void 0,"aria-selected":f,disabled:void 0,onClick:g,onFocus:y,onPointerEnter:x,onMouseEnter:x,onPointerMove:S,onMouseMove:S,onPointerLeave:T,onMouseLeave:T},_=fe();return!f&&i?null:_({ourProps:P,theirProps:a,slot:C,defaultTag:nR,name:"Listbox.Option"})}let rR=l.Fragment;function sR(e,t){let{options:n,placeholder:o,...r}=e,s={ref:ye(t)},a=Oo("ListboxSelectedOption"),i=l.useMemo(()=>({}),[]),c=a.value===void 0||a.value===null||a.mode===1&&Array.isArray(a.value)&&a.value.length===0,u=fe();return w.createElement(Kh.Provider,{value:!0},u({ourProps:s,theirProps:{...r,children:w.createElement(w.Fragment,null,o&&c?o:n)},slot:i,defaultTag:rR,name:"ListboxSelectedOption"}))}let aR=le(Xk),iR=le(Qk),lR=ii,cR=le(tR),uR=le(oR),dR=le(sR),tO=Object.assign(aR,{Button:iR,Label:lR,Options:cR,Option:uR,SelectedOption:dR});var fR=(e=>(e[e.Open=0]="Open",e[e.Closed=1]="Closed",e))(fR||{}),pR=(e=>(e[e.TogglePopover=0]="TogglePopover",e[e.ClosePopover=1]="ClosePopover",e[e.SetButton=2]="SetButton",e[e.SetButtonId=3]="SetButtonId",e[e.SetPanel=4]="SetPanel",e[e.SetPanelId=5]="SetPanelId",e))(pR||{});let hR={0:e=>({...e,popoverState:ge(e.popoverState,{0:1,1:0}),__demoMode:!1}),1(e){return e.popoverState===1?e:{...e,popoverState:1,__demoMode:!1}},2(e,t){return e.button===t.button?e:{...e,button:t.button}},3(e,t){return e.buttonId===t.buttonId?e:{...e,buttonId:t.buttonId}},4(e,t){return e.panel===t.panel?e:{...e,panel:t.panel}},5(e,t){return e.panelId===t.panelId?e:{...e,panelId:t.panelId}}},Ri=l.createContext(null);Ri.displayName="PopoverContext";function ts(e){let t=l.useContext(Ri);if(t===null){let n=new Error(`<${e} /> is missing a parent <Popover /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,ts),n}return t}let ns=l.createContext(null);ns.displayName="PopoverAPIContext";function Di(e){let t=l.useContext(ns);if(t===null){let n=new Error(`<${e} /> is missing a parent <Popover /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,Di),n}return t}let Ii=l.createContext(null);Ii.displayName="PopoverGroupContext";function qh(){return l.useContext(Ii)}let os=l.createContext(null);os.displayName="PopoverPanelContext";function mR(){return l.useContext(os)}function vR(e,t){return ge(t.type,hR,e,t)}let gR="div";function yR(e,t){var n;let{__demoMode:o=!1,...r}=e,s=l.useRef(null),a=ye(t,ri(R=>{s.current=R})),i=l.useRef([]),c=l.useReducer(vR,{__demoMode:o,popoverState:o?0:1,buttons:i,button:null,buttonId:null,panel:null,panelId:null,beforePanelSentinel:l.createRef(),afterPanelSentinel:l.createRef(),afterButtonSentinel:l.createRef()}),[{popoverState:u,button:d,buttonId:f,panel:p,panelId:h,beforePanelSentinel:m,afterPanelSentinel:v,afterButtonSentinel:g},y]=c,b=bt((n=s.current)!=null?n:d),x=l.useMemo(()=>{if(!d||!p)return!1;for(let A of document.querySelectorAll("body > *"))if(Number(A?.contains(d))^Number(A?.contains(p)))return!0;let R=ko(),D=R.indexOf(d),L=(D+R.length-1)%R.length,k=(D+1)%R.length,M=R[L],F=R[k];return!p.contains(M)&&!p.contains(F)},[d,p]),S=Ye(f),T=Ye(h),C=l.useMemo(()=>({buttonId:S,panelId:T,close:()=>y({type:1})}),[S,T,y]),P=qh(),_=P?.registerPopover,O=j(()=>{var R;return(R=P?.isFocusWithinPopoverGroup())!=null?R:b?.activeElement&&(d?.contains(b.activeElement)||p?.contains(b.activeElement))});l.useEffect(()=>_?.(C),[_,C]);let[I,$]=Nh(),G=xi(d),W=Lh({mainTreeNode:G,portals:I,defaultContainers:[d,p]});Ur(b?.defaultView,"focus",R=>{var D,L,k,M,F,A;R.target!==window&&R.target instanceof HTMLElement&&u===0&&(O()||d&&p&&(W.contains(R.target)||(L=(D=m.current)==null?void 0:D.contains)!=null&&L.call(D,R.target)||(M=(k=v.current)==null?void 0:k.contains)!=null&&M.call(k,R.target)||(A=(F=g.current)==null?void 0:F.contains)!=null&&A.call(F,R.target)||y({type:1})))},!0),Hr(u===0,W.resolveContainers,(R,D)=>{y({type:1}),ui(D,Wr.Loose)||(R.preventDefault(),d?.focus())});let B=j(R=>{y({type:1});let D=R?R instanceof HTMLElement?R:"current"in R&&R.current instanceof HTMLElement?R.current:d:d;D?.focus()}),K=l.useMemo(()=>({close:B,isPortalled:x}),[B,x]),H=l.useMemo(()=>({open:u===0,close:B}),[u,B]),U={ref:a},q=fe();return w.createElement(ir,{node:G},w.createElement(vi,null,w.createElement(os.Provider,{value:null},w.createElement(Ri.Provider,{value:c},w.createElement(ns.Provider,{value:K},w.createElement(li,{value:B},w.createElement(Ro,{value:ge(u,{0:Ce.Open,1:Ce.Closed})},w.createElement($,null,q({ourProps:U,theirProps:r,slot:H,defaultTag:gR,name:"Popover"})))))))))}let bR="button";function xR(e,t){let n=l.useId(),{id:o=`headlessui-popover-button-${n}`,disabled:r=!1,autoFocus:s=!1,...a}=e,[i,c]=ts("Popover.Button"),{isPortalled:u}=Di("Popover.Button"),d=l.useRef(null),f=`headlessui-focus-sentinel-${l.useId()}`,p=qh(),h=p?.closeOthers,m=mR()!==null;l.useEffect(()=>{if(!m)return c({type:3,buttonId:o}),()=>{c({type:3,buttonId:null})}},[m,o,c]);let[v]=l.useState(()=>Symbol()),g=ye(d,t,pi(),j(D=>{if(!m){if(D)i.buttons.current.push(v);else{let L=i.buttons.current.indexOf(v);L!==-1&&i.buttons.current.splice(L,1)}i.buttons.current.length>1&&console.warn("You are already using a <Popover.Button /> but only 1 <Popover.Button /> is supported."),D&&c({type:2,button:D})}})),y=ye(d,t),b=bt(d),x=j(D=>{var L,k,M;if(m){if(i.popoverState===1)return;switch(D.key){case ne.Space:case ne.Enter:D.preventDefault(),(k=(L=D.target).click)==null||k.call(L),c({type:1}),(M=i.button)==null||M.focus();break}}else switch(D.key){case ne.Space:case ne.Enter:D.preventDefault(),D.stopPropagation(),i.popoverState===1&&h?.(i.buttonId),c({type:0});break;case ne.Escape:if(i.popoverState!==0)return h?.(i.buttonId);if(!d.current||b!=null&&b.activeElement&&!d.current.contains(b.activeElement))return;D.preventDefault(),D.stopPropagation(),c({type:1});break}}),S=j(D=>{m||D.key===ne.Space&&D.preventDefault()}),T=j(D=>{var L,k;Ln(D.currentTarget)||r||(m?(c({type:1}),(L=i.button)==null||L.focus()):(D.preventDefault(),D.stopPropagation(),i.popoverState===1&&h?.(i.buttonId),c({type:0}),(k=i.button)==null||k.focus()))}),C=j(D=>{D.preventDefault(),D.stopPropagation()}),{isFocusVisible:P,focusProps:_}=zt({autoFocus:s}),{isHovered:O,hoverProps:I}=hn({isDisabled:r}),{pressed:$,pressProps:G}=Fn({disabled:r}),W=i.popoverState===0,B=l.useMemo(()=>({open:W,active:$||W,disabled:r,hover:O,focus:P,autofocus:s}),[W,O,P,$,r,s]),K=Vn(e,i.button),H=ot(m?{ref:y,type:K,onKeyDown:x,onClick:T,disabled:r||void 0,autoFocus:s}:{ref:g,id:i.buttonId,type:K,"aria-expanded":i.popoverState===0,"aria-controls":i.panel?i.panelId:void 0,disabled:r||void 0,autoFocus:s,onKeyDown:x,onKeyUp:S,onClick:T,onMouseDown:C},_,I,G),U=wi(),q=j(()=>{let D=i.panel;if(!D)return;function L(){ge(U.current,{[tt.Forwards]:()=>Ae(D,Ee.First),[tt.Backwards]:()=>Ae(D,Ee.Last)})===Pt.Error&&Ae(ko().filter(k=>k.dataset.headlessuiFocusGuard!=="true"),ge(U.current,{[tt.Forwards]:Ee.Next,[tt.Backwards]:Ee.Previous}),{relativeTo:i.button})}L()}),R=fe();return w.createElement(w.Fragment,null,R({ourProps:H,theirProps:a,slot:B,defaultTag:bR,name:"Popover.Button"}),W&&!m&&u&&w.createElement(kt,{id:f,ref:i.afterButtonSentinel,features:Tt.Focusable,"data-headlessui-focus-guard":!0,as:"button",type:"button",onFocus:q}))}let wR="div",ER=Ve.RenderStrategy|Ve.Static;function Xh(e,t){let n=l.useId(),{id:o=`headlessui-popover-backdrop-${n}`,transition:r=!1,...s}=e,[{popoverState:a},i]=ts("Popover.Backdrop"),[c,u]=l.useState(null),d=ye(t,u),f=$t(),[p,h]=Hn(r,c,f!==null?(f&Ce.Open)===Ce.Open:a===0),m=j(y=>{if(Ln(y.currentTarget))return y.preventDefault();i({type:1})}),v=l.useMemo(()=>({open:a===0}),[a]),g={ref:d,id:o,"aria-hidden":!0,onClick:m,...Wn(h)};return fe()({ourProps:g,theirProps:s,slot:v,defaultTag:wR,features:ER,visible:p,name:"Popover.Backdrop"})}let CR="div",SR=Ve.RenderStrategy|Ve.Static;function PR(e,t){let n=l.useId(),{id:o=`headlessui-popover-panel-${n}`,focus:r=!1,anchor:s,portal:a=!1,modal:i=!1,transition:c=!1,...u}=e,[d,f]=ts("Popover.Panel"),{close:p,isPortalled:h}=Di("Popover.Panel"),m=`headlessui-focus-sentinel-before-${n}`,v=`headlessui-focus-sentinel-after-${n}`,g=l.useRef(null),y=fi(s),[b,x]=mi(y),S=hi();y&&(a=!0);let[T,C]=l.useState(null),P=ye(g,t,y?b:null,j(D=>f({type:4,panel:D})),C),_=bt(g);ce(()=>(f({type:5,panelId:o}),()=>{f({type:5,panelId:null})}),[o,f]);let O=$t(),[I,$]=Hn(c,T,O!==null?(O&Ce.Open)===Ce.Open:d.popoverState===0);Vr(I,d.button,()=>{f({type:1})});let G=d.__demoMode?!1:i&&I;Gr(G,_);let W=j(D=>{var L;switch(D.key){case ne.Escape:if(d.popoverState!==0||!g.current||_!=null&&_.activeElement&&!g.current.contains(_.activeElement))return;D.preventDefault(),D.stopPropagation(),f({type:1}),(L=d.button)==null||L.focus();break}});l.useEffect(()=>{var D;e.static||d.popoverState===1&&((D=e.unmount)==null||D)&&f({type:4,panel:null})},[d.popoverState,e.unmount,e.static,f]),l.useEffect(()=>{if(d.__demoMode||!r||d.popoverState!==0||!g.current)return;let D=_?.activeElement;g.current.contains(D)||Ae(g.current,Ee.First)},[d.__demoMode,r,g.current,d.popoverState]);let B=l.useMemo(()=>({open:d.popoverState===0,close:p}),[d.popoverState,p]),K=ot(y?S():{},{ref:P,id:o,onKeyDown:W,onBlur:r&&d.popoverState===0?D=>{var L,k,M,F,A;let z=D.relatedTarget;z&&g.current&&((L=g.current)!=null&&L.contains(z)||(f({type:1}),((M=(k=d.beforePanelSentinel.current)==null?void 0:k.contains)!=null&&M.call(k,z)||(A=(F=d.afterPanelSentinel.current)==null?void 0:F.contains)!=null&&A.call(F,z))&&z.focus({preventScroll:!0})))}:void 0,tabIndex:-1,style:{...u.style,...x,"--button-width":rr(d.button,!0).width},...Wn($)}),H=wi(),U=j(()=>{let D=g.current;if(!D)return;function L(){ge(H.current,{[tt.Forwards]:()=>{var k;Ae(D,Ee.First)===Pt.Error&&((k=d.afterPanelSentinel.current)==null||k.focus())},[tt.Backwards]:()=>{var k;(k=d.button)==null||k.focus({preventScroll:!0})}})}L()}),q=j(()=>{let D=g.current;if(!D)return;function L(){ge(H.current,{[tt.Forwards]:()=>{if(!d.button)return;let k=ko(),M=k.indexOf(d.button),F=k.slice(0,M+1),A=[...k.slice(M+1),...F];for(let z of A.slice())if(z.dataset.headlessuiFocusGuard==="true"||T!=null&&T.contains(z)){let N=A.indexOf(z);N!==-1&&A.splice(N,1)}Ae(A,Ee.First,{sorted:!1})},[tt.Backwards]:()=>{var k;Ae(D,Ee.Previous)===Pt.Error&&((k=d.button)==null||k.focus())}})}L()}),R=fe();return w.createElement(gi,null,w.createElement(os.Provider,{value:o},w.createElement(ns.Provider,{value:{close:p,isPortalled:h}},w.createElement(zr,{enabled:a?e.static||I:!1},I&&h&&w.createElement(kt,{id:m,ref:d.beforePanelSentinel,features:Tt.Focusable,"data-headlessui-focus-guard":!0,as:"button",type:"button",onFocus:U}),R({ourProps:K,theirProps:u,slot:B,defaultTag:CR,features:SR,visible:I,name:"Popover.Panel"}),I&&h&&w.createElement(kt,{id:v,ref:d.afterPanelSentinel,features:Tt.Focusable,"data-headlessui-focus-guard":!0,as:"button",type:"button",onFocus:q})))))}let MR="div";function TR(e,t){let n=l.useRef(null),o=ye(n,t),[r,s]=l.useState([]),a=j(v=>{s(g=>{let y=g.indexOf(v);if(y!==-1){let b=g.slice();return b.splice(y,1),b}return g})}),i=j(v=>(s(g=>[...g,v]),()=>a(v))),c=j(()=>{var v;let g=Dt(n);if(!g)return!1;let y=g.activeElement;return(v=n.current)!=null&&v.contains(y)?!0:r.some(b=>{var x,S;return((x=g.getElementById(b.buttonId.current))==null?void 0:x.contains(y))||((S=g.getElementById(b.panelId.current))==null?void 0:S.contains(y))})}),u=j(v=>{for(let g of r)g.buttonId.current!==v&&g.close()}),d=l.useMemo(()=>({registerPopover:i,unregisterPopover:a,isFocusWithinPopoverGroup:c,closeOthers:u}),[i,a,c,u]),f=l.useMemo(()=>({}),[]),p=e,h={ref:o},m=fe();return w.createElement(ir,null,w.createElement(Ii.Provider,{value:d},m({ourProps:h,theirProps:p,slot:f,defaultTag:MR,name:"Popover.Group"})))}let kR=le(yR),RR=le(xR),DR=le(Xh),IR=le(Xh),OR=le(PR),AR=le(TR),nO=Object.assign(kR,{Button:RR,Backdrop:IR,Overlay:DR,Panel:OR,Group:AR}),Oi=l.createContext(null);Oi.displayName="GroupContext";let _R=l.Fragment;function NR(e){var t;let[n,o]=l.useState(null),[r,s]=ai(),[a,i]=gh(),c=l.useMemo(()=>({switch:n,setSwitch:o}),[n,o]),u={},d=e,f=fe();return w.createElement(i,{name:"Switch.Description",value:a},w.createElement(s,{name:"Switch.Label",value:r,props:{htmlFor:(t=c.switch)==null?void 0:t.id,onClick(p){n&&(p.currentTarget instanceof HTMLLabelElement&&p.preventDefault(),n.click(),n.focus({preventScroll:!0}))}}},w.createElement(Oi.Provider,{value:c},f({ourProps:u,theirProps:d,slot:{},defaultTag:_R,name:"Switch.Group"}))))}let $R="button";function FR(e,t){var n;let o=l.useId(),r=Lr(),s=To(),{id:a=r||`headlessui-switch-${o}`,disabled:i=s||!1,checked:c,defaultChecked:u,onChange:d,name:f,value:p,form:h,autoFocus:m=!1,...v}=e,g=l.useContext(Oi),[y,b]=l.useState(null),x=l.useRef(null),S=ye(x,t,g===null?null:g.setSwitch,b),T=ni(u),[C,P]=ti(c,d,T??!1),_=It(),[O,I]=l.useState(!1),$=j(()=>{I(!0),P?.(!C),_.nextFrame(()=>{I(!1)})}),G=j(N=>{if(Ln(N.currentTarget))return N.preventDefault();N.preventDefault(),$()}),W=j(N=>{N.key===ne.Space?(N.preventDefault(),$()):N.key===ne.Enter&&hh(N.currentTarget)}),B=j(N=>N.preventDefault()),K=jn(),H=si(),{isFocusVisible:U,focusProps:q}=zt({autoFocus:m}),{isHovered:R,hoverProps:D}=hn({isDisabled:i}),{pressed:L,pressProps:k}=Fn({disabled:i}),M=l.useMemo(()=>({checked:C,disabled:i,hover:R,focus:U,active:L,autofocus:m,changing:O}),[C,R,U,L,i,O,m]),F=ot({id:a,ref:S,role:"switch",type:Vn(e,y),tabIndex:e.tabIndex===-1?0:(n=e.tabIndex)!=null?n:0,"aria-checked":C,"aria-labelledby":K,"aria-describedby":H,disabled:i||void 0,autoFocus:m,onClick:G,onKeyUp:W,onKeyPress:B},q,D,k),A=l.useCallback(()=>{if(T!==void 0)return P?.(T)},[P,T]),z=fe();return w.createElement(w.Fragment,null,f!=null&&w.createElement(oi,{disabled:i,data:{[f]:p||"on"},overrides:{type:"checkbox",checked:C},form:h,onReset:A}),z({ourProps:F,theirProps:v,slot:M,defaultTag:$R,name:"Switch"}))}let LR=le(FR),jR=NR,BR=ii,VR=yh,oO=Object.assign(LR,{Group:jR,Label:BR,Description:VR});function WR({onFocus:e}){let[t,n]=l.useState(!0),o=Kr();return t?w.createElement(kt,{as:"button",type:"button",features:Tt.Focusable,onFocus:r=>{r.preventDefault();let s,a=50;function i(){if(a--<=0){s&&cancelAnimationFrame(s);return}if(e()){if(cancelAnimationFrame(s),!o.current)return;n(!1);return}s=requestAnimationFrame(i)}s=requestAnimationFrame(i)}}):null}const Zh=l.createContext(null);function HR(){return{groups:new Map,get(e,t){var n;let o=this.groups.get(e);o||(o=new Map,this.groups.set(e,o));let r=(n=o.get(t))!=null?n:0;o.set(t,r+1);let s=Array.from(o.keys()).indexOf(t);function a(){let i=o.get(t);i>1?o.set(t,i-1):o.delete(t)}return[s,a]}}}function UR({children:e}){let t=l.useRef(HR());return l.createElement(Zh.Provider,{value:t},e)}function Qh(e){let t=l.useContext(Zh);if(!t)throw new Error("You must wrap your component in a <StableCollection>");let n=l.useId(),[o,r]=t.current.get(e,n);return l.useEffect(()=>r,[]),o}var GR=(e=>(e[e.Forwards=0]="Forwards",e[e.Backwards=1]="Backwards",e))(GR||{}),YR=(e=>(e[e.Less=-1]="Less",e[e.Equal=0]="Equal",e[e.Greater=1]="Greater",e))(YR||{}),zR=(e=>(e[e.SetSelectedIndex=0]="SetSelectedIndex",e[e.RegisterTab=1]="RegisterTab",e[e.UnregisterTab=2]="UnregisterTab",e[e.RegisterPanel=3]="RegisterPanel",e[e.UnregisterPanel=4]="UnregisterPanel",e))(zR||{});let KR={0(e,t){var n;let o=Ht(e.tabs,d=>d.current),r=Ht(e.panels,d=>d.current),s=o.filter(d=>{var f;return!((f=d.current)!=null&&f.hasAttribute("disabled"))}),a={...e,tabs:o,panels:r};if(t.index<0||t.index>o.length-1){let d=ge(Math.sign(t.index-e.selectedIndex),{[-1]:()=>1,0:()=>ge(Math.sign(t.index),{[-1]:()=>0,0:()=>0,1:()=>1}),1:()=>0});if(s.length===0)return a;let f=ge(d,{0:()=>o.indexOf(s[0]),1:()=>o.indexOf(s[s.length-1])});return{...a,selectedIndex:f===-1?e.selectedIndex:f}}let i=o.slice(0,t.index),c=[...o.slice(t.index),...i].find(d=>s.includes(d));if(!c)return a;let u=(n=o.indexOf(c))!=null?n:e.selectedIndex;return u===-1&&(u=e.selectedIndex),{...a,selectedIndex:u}},1(e,t){if(e.tabs.includes(t.tab))return e;let n=e.tabs[e.selectedIndex],o=Ht([...e.tabs,t.tab],s=>s.current),r=e.selectedIndex;return e.info.current.isControlled||(r=o.indexOf(n),r===-1&&(r=e.selectedIndex)),{...e,tabs:o,selectedIndex:r}},2(e,t){return{...e,tabs:e.tabs.filter(n=>n!==t.tab)}},3(e,t){return e.panels.includes(t.panel)?e:{...e,panels:Ht([...e.panels,t.panel],n=>n.current)}},4(e,t){return{...e,panels:e.panels.filter(n=>n!==t.panel)}}},Ai=l.createContext(null);Ai.displayName="TabsDataContext";function On(e){let t=l.useContext(Ai);if(t===null){let n=new Error(`<${e} /> is missing a parent <Tab.Group /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,On),n}return t}let _i=l.createContext(null);_i.displayName="TabsActionsContext";function Ni(e){let t=l.useContext(_i);if(t===null){let n=new Error(`<${e} /> is missing a parent <Tab.Group /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,Ni),n}return t}function qR(e,t){return ge(t.type,KR,e,t)}let XR="div";function ZR(e,t){let{defaultIndex:n=0,vertical:o=!1,manual:r=!1,onChange:s,selectedIndex:a=null,...i}=e;const c=o?"vertical":"horizontal",u=r?"manual":"auto";let d=a!==null,f=Ye({isControlled:d}),p=ye(t),[h,m]=l.useReducer(qR,{info:f,selectedIndex:a??n,tabs:[],panels:[]}),v=l.useMemo(()=>({selectedIndex:h.selectedIndex}),[h.selectedIndex]),g=Ye(s||(()=>{})),y=Ye(h.tabs),b=l.useMemo(()=>({orientation:c,activation:u,...h}),[c,u,h]),x=j(I=>(m({type:1,tab:I}),()=>m({type:2,tab:I}))),S=j(I=>(m({type:3,panel:I}),()=>m({type:4,panel:I}))),T=j(I=>{C.current!==I&&g.current(I),d||m({type:0,index:I})}),C=Ye(d?e.selectedIndex:h.selectedIndex),P=l.useMemo(()=>({registerTab:x,registerPanel:S,change:T}),[]);ce(()=>{m({type:0,index:a??n})},[a]),ce(()=>{if(C.current===void 0||h.tabs.length<=0)return;let I=Ht(h.tabs,$=>$.current);I.some(($,G)=>h.tabs[G]!==$)&&T(I.indexOf(h.tabs[C.current]))});let _={ref:p},O=fe();return w.createElement(UR,null,w.createElement(_i.Provider,{value:P},w.createElement(Ai.Provider,{value:b},b.tabs.length<=0&&w.createElement(WR,{onFocus:()=>{var I,$;for(let G of y.current)if(((I=G.current)==null?void 0:I.tabIndex)===0)return($=G.current)==null||$.focus(),!0;return!1}}),O({ourProps:_,theirProps:i,slot:v,defaultTag:XR,name:"Tabs"}))))}let QR="div";function JR(e,t){let{orientation:n,selectedIndex:o}=On("Tab.List"),r=ye(t),s=l.useMemo(()=>({selectedIndex:o}),[o]),a=e,i={ref:r,role:"tablist","aria-orientation":n};return fe()({ourProps:i,theirProps:a,slot:s,defaultTag:QR,name:"Tabs.List"})}let eD="button";function tD(e,t){var n,o;let r=l.useId(),{id:s=`headlessui-tabs-tab-${r}`,disabled:a=!1,autoFocus:i=!1,...c}=e,{orientation:u,activation:d,selectedIndex:f,tabs:p,panels:h}=On("Tab"),m=Ni("Tab"),v=On("Tab"),[g,y]=l.useState(null),b=l.useRef(null),x=ye(b,t,y);ce(()=>m.registerTab(b),[m,b]);let S=Qh("tabs"),T=p.indexOf(b);T===-1&&(T=S);let C=T===f,P=j(D=>{var L;let k=D();if(k===Pt.Success&&d==="auto"){let M=(L=Dt(b))==null?void 0:L.activeElement,F=v.tabs.findIndex(A=>A.current===M);F!==-1&&m.change(F)}return k}),_=j(D=>{let L=p.map(k=>k.current).filter(Boolean);if(D.key===ne.Space||D.key===ne.Enter){D.preventDefault(),D.stopPropagation(),m.change(T);return}switch(D.key){case ne.Home:case ne.PageUp:return D.preventDefault(),D.stopPropagation(),P(()=>Ae(L,Ee.First));case ne.End:case ne.PageDown:return D.preventDefault(),D.stopPropagation(),P(()=>Ae(L,Ee.Last))}if(P(()=>ge(u,{vertical(){return D.key===ne.ArrowUp?Ae(L,Ee.Previous|Ee.WrapAround):D.key===ne.ArrowDown?Ae(L,Ee.Next|Ee.WrapAround):Pt.Error},horizontal(){return D.key===ne.ArrowLeft?Ae(L,Ee.Previous|Ee.WrapAround):D.key===ne.ArrowRight?Ae(L,Ee.Next|Ee.WrapAround):Pt.Error}}))===Pt.Success)return D.preventDefault()}),O=l.useRef(!1),I=j(()=>{var D;O.current||(O.current=!0,(D=b.current)==null||D.focus({preventScroll:!0}),m.change(T),Mo(()=>{O.current=!1}))}),$=j(D=>{D.preventDefault()}),{isFocusVisible:G,focusProps:W}=zt({autoFocus:i}),{isHovered:B,hoverProps:K}=hn({isDisabled:a}),{pressed:H,pressProps:U}=Fn({disabled:a}),q=l.useMemo(()=>({selected:C,hover:B,active:H,focus:G,autofocus:i,disabled:a}),[C,B,G,H,i,a]),R=ot({ref:x,onKeyDown:_,onMouseDown:$,onClick:I,id:s,role:"tab",type:Vn(e,g),"aria-controls":(o=(n=h[T])==null?void 0:n.current)==null?void 0:o.id,"aria-selected":C,tabIndex:C?0:-1,disabled:a||void 0,autoFocus:i},W,K,U);return fe()({ourProps:R,theirProps:c,slot:q,defaultTag:eD,name:"Tabs.Tab"})}let nD="div";function oD(e,t){let{selectedIndex:n}=On("Tab.Panels"),o=ye(t),r=l.useMemo(()=>({selectedIndex:n}),[n]),s=e,a={ref:o};return fe()({ourProps:a,theirProps:s,slot:r,defaultTag:nD,name:"Tabs.Panels"})}let rD="div",sD=Ve.RenderStrategy|Ve.Static;function aD(e,t){var n,o,r,s;let a=l.useId(),{id:i=`headlessui-tabs-panel-${a}`,tabIndex:c=0,...u}=e,{selectedIndex:d,tabs:f,panels:p}=On("Tab.Panel"),h=Ni("Tab.Panel"),m=l.useRef(null),v=ye(m,t);ce(()=>h.registerPanel(m),[h,m]);let g=Qh("panels"),y=p.indexOf(m);y===-1&&(y=g);let b=y===d,{isFocusVisible:x,focusProps:S}=zt(),T=l.useMemo(()=>({selected:b,focus:x}),[b,x]),C=ot({ref:v,id:i,role:"tabpanel","aria-labelledby":(o=(n=f[y])==null?void 0:n.current)==null?void 0:o.id,tabIndex:b?c:-1},S),P=fe();return!b&&((r=u.unmount)==null||r)&&!((s=u.static)!=null&&s)?w.createElement(kt,{"aria-hidden":"true",...C}):P({ourProps:C,theirProps:u,slot:T,defaultTag:rD,features:sD,visible:b,name:"Tabs.Panel"})}let iD=le(tD),lD=le(ZR),cD=le(JR),uD=le(oD),dD=le(aD),rO=Object.assign(iD,{Group:lD,List:cD,Panels:uD,Panel:dD});export{MD as $,KI as A,n2 as B,uu as C,Q2 as D,YD as E,Ei as F,cR as G,Z2 as H,XI as I,s2 as J,HT as K,r2 as L,tO as M,iR as N,cu as O,lu as P,a2 as Q,OR as R,RR as S,rO as T,BT as U,uR as V,o2 as W,BI as X,oO as Y,_D as Z,SD as _,VT as a,sI as a$,WD as a0,uI as a1,l2 as a2,i2 as a3,u2 as a4,c2 as a5,d2 as a6,MI as a7,QD as a8,EI as a9,NI as aA,M2 as aB,pI as aC,ow as aD,nw as aE,zD as aF,KD as aG,ED as aH,xD as aI,PD as aJ,xI as aK,UD as aL,kI as aM,VI as aN,k2 as aO,SI as aP,hI as aQ,R2 as aR,O2 as aS,N2 as aT,$2 as aU,_2 as aV,A2 as aW,D2 as aX,I2 as aY,Cw as aZ,Sw as a_,RD as aa,BD as ab,DI as ac,oI as ad,jI as ae,rI as af,kD as ag,tI as ah,FD as ai,cI as aj,bD as ak,p2 as al,m2 as am,C2 as an,AD as ao,S2 as ap,v2 as aq,g2 as ar,y2 as as,b2 as at,x2 as au,E2 as av,w2 as aw,P2 as ax,f2 as ay,h2 as az,eO as b,FI as b0,GD as b1,AI as b2,dI as b3,ND as b4,$D as b5,mI as b6,$I as b7,LD as b8,bI as b9,Y2 as bA,G2 as bB,z2 as bC,nI as bD,XD as bE,U2 as bF,aI as bG,iI as bH,qD as bI,gD as bJ,RI as bK,ZD as bL,CD as bM,yD as bN,vI as bO,eI as bP,T2 as bQ,lI as ba,F2 as bb,L2 as bc,j2 as bd,VD as be,TI as bf,B2 as bg,V2 as bh,fI as bi,wI as bj,II as bk,W2 as bl,Wp as bm,jD as bn,K2 as bo,ID as bp,TD as bq,_I as br,wD as bs,CI as bt,HD as bu,LI as bv,JD as bw,gI as bx,PI as by,OI as bz,Ek as c,vD as d,WI as e,iu as f,du as g,Uy as h,Gy as i,UT as j,UI as k,nO as l,GI as m,YI as n,zI as o,HI as p,yI as q,OD as r,DD as s,qI as t,ZI as u,JI as v,e2 as w,t2 as x,J2 as y,ik as z};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.