docthub-core-components 1.0.10 → 1.0.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs.js CHANGED
@@ -1,152 +1,198 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const m=require("react/jsx-runtime"),N=require("react"),cs=require("react-dom");function ls(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const d=ls(N),Tn=ls(cs);function ho(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function lt(...e){return t=>{let n=!1;const r=e.map(o=>{const s=ho(o,t);return!n&&typeof s=="function"&&(n=!0),s});if(n)return()=>{for(let o=0;o<r.length;o++){const s=r[o];typeof s=="function"?s():ho(e[o],null)}}}}function fe(...e){return d.useCallback(lt(...e),e)}function ut(e){const t=jc(e),n=d.forwardRef((r,o)=>{const{children:s,...i}=r,a=d.Children.toArray(s),c=a.find(Wc);if(c){const l=c.props.children,f=a.map(u=>u===c?d.Children.count(l)>1?d.Children.only(null):d.isValidElement(l)?l.props.children:null:u);return m.jsx(t,{...i,ref:o,children:d.isValidElement(l)?d.cloneElement(l,void 0,f):null})}return m.jsx(t,{...i,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}var _c=ut("Slot");function jc(e){const t=d.forwardRef((n,r)=>{const{children:o,...s}=n;if(d.isValidElement(o)){const i=Fc(o),a=$c(s,o.props);return o.type!==d.Fragment&&(a.ref=r?lt(r,i):i),d.cloneElement(o,a)}return d.Children.count(o)>1?d.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Ic=Symbol("radix.slottable");function Wc(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Ic}function $c(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...a)=>{const c=s(...a);return o(...a),c}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function Fc(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function us(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(n=us(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function ds(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=us(e))&&(r&&(r+=" "),r+=t);return r}const po=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,go=ds,Fr=(e,t)=>n=>{var r;if((t==null?void 0:t.variants)==null)return go(e,n==null?void 0:n.class,n==null?void 0:n.className);const{variants:o,defaultVariants:s}=t,i=Object.keys(o).map(l=>{const f=n==null?void 0:n[l],u=s==null?void 0:s[l];if(f===null)return null;const h=po(f)||po(u);return o[l][h]}),a=n&&Object.entries(n).reduce((l,f)=>{let[u,h]=f;return h===void 0||(l[u]=h),l},{}),c=t==null||(r=t.compoundVariants)===null||r===void 0?void 0:r.reduce((l,f)=>{let{class:u,className:h,...g}=f;return Object.entries(g).every(b=>{let[p,v]=b;return Array.isArray(v)?v.includes({...s,...a}[p]):{...s,...a}[p]===v})?[...l,u,h]:l},[]);return go(e,i,c,n==null?void 0:n.class,n==null?void 0:n.className)},Lr="-",Lc=e=>{const t=Yc(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:i=>{const a=i.split(Lr);return a[0]===""&&a.length!==1&&a.shift(),fs(a,t)||Bc(i)},getConflictingClassGroupIds:(i,a)=>{const c=n[i]||[];return a&&r[i]?[...c,...r[i]]:c}}},fs=(e,t)=>{var i;if(e.length===0)return t.classGroupId;const n=e[0],r=t.nextPart.get(n),o=r?fs(e.slice(1),r):void 0;if(o)return o;if(t.validators.length===0)return;const s=e.join(Lr);return(i=t.validators.find(({validator:a})=>a(s)))==null?void 0:i.classGroupId},vo=/^\[(.+)\]$/,Bc=e=>{if(vo.test(e)){const t=vo.exec(e)[1],n=t==null?void 0:t.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}},Yc=e=>{const{theme:t,classGroups:n}=e,r={nextPart:new Map,validators:[]};for(const o in n)br(n[o],r,o,t);return r},br=(e,t,n,r)=>{e.forEach(o=>{if(typeof o=="string"){const s=o===""?t:yo(t,o);s.classGroupId=n;return}if(typeof o=="function"){if(zc(o)){br(o(r),t,n,r);return}t.validators.push({validator:o,classGroupId:n});return}Object.entries(o).forEach(([s,i])=>{br(i,yo(t,s),n,r)})})},yo=(e,t)=>{let n=e;return t.split(Lr).forEach(r=>{n.nextPart.has(r)||n.nextPart.set(r,{nextPart:new Map,validators:[]}),n=n.nextPart.get(r)}),n},zc=e=>e.isThemeGetter,Hc=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=new Map,r=new Map;const o=(s,i)=>{n.set(s,i),t++,t>e&&(t=0,r=n,n=new Map)};return{get(s){let i=n.get(s);if(i!==void 0)return i;if((i=r.get(s))!==void 0)return o(s,i),i},set(s,i){n.has(s)?n.set(s,i):o(s,i)}}},wr="!",xr=":",qc=xr.length,Uc=e=>{const{prefix:t,experimentalParseClassName:n}=e;let r=o=>{const s=[];let i=0,a=0,c=0,l;for(let b=0;b<o.length;b++){let p=o[b];if(i===0&&a===0){if(p===xr){s.push(o.slice(c,b)),c=b+qc;continue}if(p==="/"){l=b;continue}}p==="["?i++:p==="]"?i--:p==="("?a++:p===")"&&a--}const f=s.length===0?o:o.substring(c),u=Gc(f),h=u!==f,g=l&&l>c?l-c:void 0;return{modifiers:s,hasImportantModifier:h,baseClassName:u,maybePostfixModifierPosition:g}};if(t){const o=t+xr,s=r;r=i=>i.startsWith(o)?s(i.substring(o.length)):{isExternal:!0,modifiers:[],hasImportantModifier:!1,baseClassName:i,maybePostfixModifierPosition:void 0}}if(n){const o=r;r=s=>n({className:s,parseClassName:o})}return r},Gc=e=>e.endsWith(wr)?e.substring(0,e.length-1):e.startsWith(wr)?e.substring(1):e,Kc=e=>{const t=Object.fromEntries(e.orderSensitiveModifiers.map(r=>[r,!0]));return r=>{if(r.length<=1)return r;const o=[];let s=[];return r.forEach(i=>{i[0]==="["||t[i]?(o.push(...s.sort(),i),s=[]):s.push(i)}),o.push(...s.sort()),o}},Vc=e=>({cache:Hc(e.cacheSize),parseClassName:Uc(e),sortModifiers:Kc(e),...Lc(e)}),Xc=/\s+/,Zc=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:o,sortModifiers:s}=t,i=[],a=e.trim().split(Xc);let c="";for(let l=a.length-1;l>=0;l-=1){const f=a[l],{isExternal:u,modifiers:h,hasImportantModifier:g,baseClassName:b,maybePostfixModifierPosition:p}=n(f);if(u){c=f+(c.length>0?" "+c:c);continue}let v=!!p,S=r(v?b.substring(0,p):b);if(!S){if(!v){c=f+(c.length>0?" "+c:c);continue}if(S=r(b),!S){c=f+(c.length>0?" "+c:c);continue}v=!1}const y=s(h).join(":"),x=g?y+wr:y,O=x+S;if(i.includes(O))continue;i.push(O);const w=o(S,v);for(let M=0;M<w.length;++M){const C=w[M];i.push(x+C)}c=f+(c.length>0?" "+c:c)}return c};function Qc(){let e=0,t,n,r="";for(;e<arguments.length;)(t=arguments[e++])&&(n=ms(t))&&(r&&(r+=" "),r+=n);return r}const ms=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=ms(e[r]))&&(n&&(n+=" "),n+=t);return n};function Jc(e,...t){let n,r,o,s=i;function i(c){const l=t.reduce((f,u)=>u(f),e());return n=Vc(l),r=n.cache.get,o=n.cache.set,s=a,a(c)}function a(c){const l=r(c);if(l)return l;const f=Zc(c,n);return o(c,f),f}return function(){return s(Qc.apply(null,arguments))}}const he=e=>{const t=n=>n[e]||[];return t.isThemeGetter=!0,t},hs=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,ps=/^\((?:(\w[\w-]*):)?(.+)\)$/i,el=/^\d+\/\d+$/,tl=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,nl=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,rl=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,ol=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,sl=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,wt=e=>el.test(e),ne=e=>!!e&&!Number.isNaN(Number(e)),Ve=e=>!!e&&Number.isInteger(Number(e)),er=e=>e.endsWith("%")&&ne(e.slice(0,-1)),Ye=e=>tl.test(e),al=()=>!0,il=e=>nl.test(e)&&!rl.test(e),gs=()=>!1,cl=e=>ol.test(e),ll=e=>sl.test(e),ul=e=>!z(e)&&!H(e),dl=e=>Rt(e,bs,gs),z=e=>hs.test(e),it=e=>Rt(e,ws,il),tr=e=>Rt(e,gl,ne),bo=e=>Rt(e,vs,gs),fl=e=>Rt(e,ys,ll),an=e=>Rt(e,xs,cl),H=e=>ps.test(e),Lt=e=>_t(e,ws),ml=e=>_t(e,vl),wo=e=>_t(e,vs),hl=e=>_t(e,bs),pl=e=>_t(e,ys),cn=e=>_t(e,xs,!0),Rt=(e,t,n)=>{const r=hs.exec(e);return r?r[1]?t(r[1]):n(r[2]):!1},_t=(e,t,n=!1)=>{const r=ps.exec(e);return r?r[1]?t(r[1]):n:!1},vs=e=>e==="position"||e==="percentage",ys=e=>e==="image"||e==="url",bs=e=>e==="length"||e==="size"||e==="bg-size",ws=e=>e==="length",gl=e=>e==="number",vl=e=>e==="family-name",xs=e=>e==="shadow",yl=()=>{const e=he("color"),t=he("font"),n=he("text"),r=he("font-weight"),o=he("tracking"),s=he("leading"),i=he("breakpoint"),a=he("container"),c=he("spacing"),l=he("radius"),f=he("shadow"),u=he("inset-shadow"),h=he("text-shadow"),g=he("drop-shadow"),b=he("blur"),p=he("perspective"),v=he("aspect"),S=he("ease"),y=he("animate"),x=()=>["auto","avoid","all","avoid-page","page","left","right","column"],O=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],w=()=>[...O(),H,z],M=()=>["auto","hidden","clip","visible","scroll"],C=()=>["auto","contain","none"],D=()=>[H,z,c],Y=()=>[wt,"full","auto",...D()],L=()=>[Ve,"none","subgrid",H,z],$=()=>["auto",{span:["full",Ve,H,z]},Ve,H,z],K=()=>[Ve,"auto",H,z],J=()=>["auto","min","max","fr",H,z],_=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],A=()=>["start","end","center","stretch","center-safe","end-safe"],P=()=>["auto",...D()],T=()=>[wt,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...D()],k=()=>[e,H,z],I=()=>[...O(),wo,bo,{position:[H,z]}],B=()=>["no-repeat",{repeat:["","x","y","space","round"]}],Q=()=>["auto","cover","contain",hl,dl,{size:[H,z]}],E=()=>[er,Lt,it],j=()=>["","none","full",l,H,z],F=()=>["",ne,Lt,it],W=()=>["solid","dashed","dotted","double"],X=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],R=()=>[ne,er,wo,bo],V=()=>["","none",b,H,z],Z=()=>["none",ne,H,z],G=()=>["none",ne,H,z],ee=()=>[ne,H,z],te=()=>[wt,"full",...D()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[Ye],breakpoint:[Ye],color:[al],container:[Ye],"drop-shadow":[Ye],ease:["in","out","in-out"],font:[ul],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[Ye],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[Ye],shadow:[Ye],spacing:["px",ne],text:[Ye],"text-shadow":[Ye],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",wt,z,H,v]}],container:["container"],columns:[{columns:[ne,z,H,a]}],"break-after":[{"break-after":x()}],"break-before":[{"break-before":x()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:w()}],overflow:[{overflow:M()}],"overflow-x":[{"overflow-x":M()}],"overflow-y":[{"overflow-y":M()}],overscroll:[{overscroll:C()}],"overscroll-x":[{"overscroll-x":C()}],"overscroll-y":[{"overscroll-y":C()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:Y()}],"inset-x":[{"inset-x":Y()}],"inset-y":[{"inset-y":Y()}],start:[{start:Y()}],end:[{end:Y()}],top:[{top:Y()}],right:[{right:Y()}],bottom:[{bottom:Y()}],left:[{left:Y()}],visibility:["visible","invisible","collapse"],z:[{z:[Ve,"auto",H,z]}],basis:[{basis:[wt,"full","auto",a,...D()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[ne,wt,"auto","initial","none",z]}],grow:[{grow:["",ne,H,z]}],shrink:[{shrink:["",ne,H,z]}],order:[{order:[Ve,"first","last","none",H,z]}],"grid-cols":[{"grid-cols":L()}],"col-start-end":[{col:$()}],"col-start":[{"col-start":K()}],"col-end":[{"col-end":K()}],"grid-rows":[{"grid-rows":L()}],"row-start-end":[{row:$()}],"row-start":[{"row-start":K()}],"row-end":[{"row-end":K()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":J()}],"auto-rows":[{"auto-rows":J()}],gap:[{gap:D()}],"gap-x":[{"gap-x":D()}],"gap-y":[{"gap-y":D()}],"justify-content":[{justify:[..._(),"normal"]}],"justify-items":[{"justify-items":[...A(),"normal"]}],"justify-self":[{"justify-self":["auto",...A()]}],"align-content":[{content:["normal",..._()]}],"align-items":[{items:[...A(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...A(),{baseline:["","last"]}]}],"place-content":[{"place-content":_()}],"place-items":[{"place-items":[...A(),"baseline"]}],"place-self":[{"place-self":["auto",...A()]}],p:[{p:D()}],px:[{px:D()}],py:[{py:D()}],ps:[{ps:D()}],pe:[{pe:D()}],pt:[{pt:D()}],pr:[{pr:D()}],pb:[{pb:D()}],pl:[{pl:D()}],m:[{m:P()}],mx:[{mx:P()}],my:[{my:P()}],ms:[{ms:P()}],me:[{me:P()}],mt:[{mt:P()}],mr:[{mr:P()}],mb:[{mb:P()}],ml:[{ml:P()}],"space-x":[{"space-x":D()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":D()}],"space-y-reverse":["space-y-reverse"],size:[{size:T()}],w:[{w:[a,"screen",...T()]}],"min-w":[{"min-w":[a,"screen","none",...T()]}],"max-w":[{"max-w":[a,"screen","none","prose",{screen:[i]},...T()]}],h:[{h:["screen","lh",...T()]}],"min-h":[{"min-h":["screen","lh","none",...T()]}],"max-h":[{"max-h":["screen","lh",...T()]}],"font-size":[{text:["base",n,Lt,it]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[r,H,tr]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",er,z]}],"font-family":[{font:[ml,z,t]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:[o,H,z]}],"line-clamp":[{"line-clamp":[ne,"none",H,tr]}],leading:[{leading:[s,...D()]}],"list-image":[{"list-image":["none",H,z]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",H,z]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:k()}],"text-color":[{text:k()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...W(),"wavy"]}],"text-decoration-thickness":[{decoration:[ne,"from-font","auto",H,it]}],"text-decoration-color":[{decoration:k()}],"underline-offset":[{"underline-offset":[ne,"auto",H,z]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:D()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",H,z]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",H,z]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:I()}],"bg-repeat":[{bg:B()}],"bg-size":[{bg:Q()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},Ve,H,z],radial:["",H,z],conic:[Ve,H,z]},pl,fl]}],"bg-color":[{bg:k()}],"gradient-from-pos":[{from:E()}],"gradient-via-pos":[{via:E()}],"gradient-to-pos":[{to:E()}],"gradient-from":[{from:k()}],"gradient-via":[{via:k()}],"gradient-to":[{to:k()}],rounded:[{rounded:j()}],"rounded-s":[{"rounded-s":j()}],"rounded-e":[{"rounded-e":j()}],"rounded-t":[{"rounded-t":j()}],"rounded-r":[{"rounded-r":j()}],"rounded-b":[{"rounded-b":j()}],"rounded-l":[{"rounded-l":j()}],"rounded-ss":[{"rounded-ss":j()}],"rounded-se":[{"rounded-se":j()}],"rounded-ee":[{"rounded-ee":j()}],"rounded-es":[{"rounded-es":j()}],"rounded-tl":[{"rounded-tl":j()}],"rounded-tr":[{"rounded-tr":j()}],"rounded-br":[{"rounded-br":j()}],"rounded-bl":[{"rounded-bl":j()}],"border-w":[{border:F()}],"border-w-x":[{"border-x":F()}],"border-w-y":[{"border-y":F()}],"border-w-s":[{"border-s":F()}],"border-w-e":[{"border-e":F()}],"border-w-t":[{"border-t":F()}],"border-w-r":[{"border-r":F()}],"border-w-b":[{"border-b":F()}],"border-w-l":[{"border-l":F()}],"divide-x":[{"divide-x":F()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":F()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...W(),"hidden","none"]}],"divide-style":[{divide:[...W(),"hidden","none"]}],"border-color":[{border:k()}],"border-color-x":[{"border-x":k()}],"border-color-y":[{"border-y":k()}],"border-color-s":[{"border-s":k()}],"border-color-e":[{"border-e":k()}],"border-color-t":[{"border-t":k()}],"border-color-r":[{"border-r":k()}],"border-color-b":[{"border-b":k()}],"border-color-l":[{"border-l":k()}],"divide-color":[{divide:k()}],"outline-style":[{outline:[...W(),"none","hidden"]}],"outline-offset":[{"outline-offset":[ne,H,z]}],"outline-w":[{outline:["",ne,Lt,it]}],"outline-color":[{outline:k()}],shadow:[{shadow:["","none",f,cn,an]}],"shadow-color":[{shadow:k()}],"inset-shadow":[{"inset-shadow":["none",u,cn,an]}],"inset-shadow-color":[{"inset-shadow":k()}],"ring-w":[{ring:F()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:k()}],"ring-offset-w":[{"ring-offset":[ne,it]}],"ring-offset-color":[{"ring-offset":k()}],"inset-ring-w":[{"inset-ring":F()}],"inset-ring-color":[{"inset-ring":k()}],"text-shadow":[{"text-shadow":["none",h,cn,an]}],"text-shadow-color":[{"text-shadow":k()}],opacity:[{opacity:[ne,H,z]}],"mix-blend":[{"mix-blend":[...X(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":X()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[ne]}],"mask-image-linear-from-pos":[{"mask-linear-from":R()}],"mask-image-linear-to-pos":[{"mask-linear-to":R()}],"mask-image-linear-from-color":[{"mask-linear-from":k()}],"mask-image-linear-to-color":[{"mask-linear-to":k()}],"mask-image-t-from-pos":[{"mask-t-from":R()}],"mask-image-t-to-pos":[{"mask-t-to":R()}],"mask-image-t-from-color":[{"mask-t-from":k()}],"mask-image-t-to-color":[{"mask-t-to":k()}],"mask-image-r-from-pos":[{"mask-r-from":R()}],"mask-image-r-to-pos":[{"mask-r-to":R()}],"mask-image-r-from-color":[{"mask-r-from":k()}],"mask-image-r-to-color":[{"mask-r-to":k()}],"mask-image-b-from-pos":[{"mask-b-from":R()}],"mask-image-b-to-pos":[{"mask-b-to":R()}],"mask-image-b-from-color":[{"mask-b-from":k()}],"mask-image-b-to-color":[{"mask-b-to":k()}],"mask-image-l-from-pos":[{"mask-l-from":R()}],"mask-image-l-to-pos":[{"mask-l-to":R()}],"mask-image-l-from-color":[{"mask-l-from":k()}],"mask-image-l-to-color":[{"mask-l-to":k()}],"mask-image-x-from-pos":[{"mask-x-from":R()}],"mask-image-x-to-pos":[{"mask-x-to":R()}],"mask-image-x-from-color":[{"mask-x-from":k()}],"mask-image-x-to-color":[{"mask-x-to":k()}],"mask-image-y-from-pos":[{"mask-y-from":R()}],"mask-image-y-to-pos":[{"mask-y-to":R()}],"mask-image-y-from-color":[{"mask-y-from":k()}],"mask-image-y-to-color":[{"mask-y-to":k()}],"mask-image-radial":[{"mask-radial":[H,z]}],"mask-image-radial-from-pos":[{"mask-radial-from":R()}],"mask-image-radial-to-pos":[{"mask-radial-to":R()}],"mask-image-radial-from-color":[{"mask-radial-from":k()}],"mask-image-radial-to-color":[{"mask-radial-to":k()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":O()}],"mask-image-conic-pos":[{"mask-conic":[ne]}],"mask-image-conic-from-pos":[{"mask-conic-from":R()}],"mask-image-conic-to-pos":[{"mask-conic-to":R()}],"mask-image-conic-from-color":[{"mask-conic-from":k()}],"mask-image-conic-to-color":[{"mask-conic-to":k()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:I()}],"mask-repeat":[{mask:B()}],"mask-size":[{mask:Q()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",H,z]}],filter:[{filter:["","none",H,z]}],blur:[{blur:V()}],brightness:[{brightness:[ne,H,z]}],contrast:[{contrast:[ne,H,z]}],"drop-shadow":[{"drop-shadow":["","none",g,cn,an]}],"drop-shadow-color":[{"drop-shadow":k()}],grayscale:[{grayscale:["",ne,H,z]}],"hue-rotate":[{"hue-rotate":[ne,H,z]}],invert:[{invert:["",ne,H,z]}],saturate:[{saturate:[ne,H,z]}],sepia:[{sepia:["",ne,H,z]}],"backdrop-filter":[{"backdrop-filter":["","none",H,z]}],"backdrop-blur":[{"backdrop-blur":V()}],"backdrop-brightness":[{"backdrop-brightness":[ne,H,z]}],"backdrop-contrast":[{"backdrop-contrast":[ne,H,z]}],"backdrop-grayscale":[{"backdrop-grayscale":["",ne,H,z]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[ne,H,z]}],"backdrop-invert":[{"backdrop-invert":["",ne,H,z]}],"backdrop-opacity":[{"backdrop-opacity":[ne,H,z]}],"backdrop-saturate":[{"backdrop-saturate":[ne,H,z]}],"backdrop-sepia":[{"backdrop-sepia":["",ne,H,z]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":D()}],"border-spacing-x":[{"border-spacing-x":D()}],"border-spacing-y":[{"border-spacing-y":D()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",H,z]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[ne,"initial",H,z]}],ease:[{ease:["linear","initial",S,H,z]}],delay:[{delay:[ne,H,z]}],animate:[{animate:["none",y,H,z]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[p,H,z]}],"perspective-origin":[{"perspective-origin":w()}],rotate:[{rotate:Z()}],"rotate-x":[{"rotate-x":Z()}],"rotate-y":[{"rotate-y":Z()}],"rotate-z":[{"rotate-z":Z()}],scale:[{scale:G()}],"scale-x":[{"scale-x":G()}],"scale-y":[{"scale-y":G()}],"scale-z":[{"scale-z":G()}],"scale-3d":["scale-3d"],skew:[{skew:ee()}],"skew-x":[{"skew-x":ee()}],"skew-y":[{"skew-y":ee()}],transform:[{transform:[H,z,"","none","gpu","cpu"]}],"transform-origin":[{origin:w()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:te()}],"translate-x":[{"translate-x":te()}],"translate-y":[{"translate-y":te()}],"translate-z":[{"translate-z":te()}],"translate-none":["translate-none"],accent:[{accent:k()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:k()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",H,z]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":D()}],"scroll-mx":[{"scroll-mx":D()}],"scroll-my":[{"scroll-my":D()}],"scroll-ms":[{"scroll-ms":D()}],"scroll-me":[{"scroll-me":D()}],"scroll-mt":[{"scroll-mt":D()}],"scroll-mr":[{"scroll-mr":D()}],"scroll-mb":[{"scroll-mb":D()}],"scroll-ml":[{"scroll-ml":D()}],"scroll-p":[{"scroll-p":D()}],"scroll-px":[{"scroll-px":D()}],"scroll-py":[{"scroll-py":D()}],"scroll-ps":[{"scroll-ps":D()}],"scroll-pe":[{"scroll-pe":D()}],"scroll-pt":[{"scroll-pt":D()}],"scroll-pr":[{"scroll-pr":D()}],"scroll-pb":[{"scroll-pb":D()}],"scroll-pl":[{"scroll-pl":D()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",H,z]}],fill:[{fill:["none",...k()]}],"stroke-w":[{stroke:[ne,Lt,it,tr]}],stroke:[{stroke:["none",...k()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-x","border-w-y","border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-x","border-color-y","border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]},orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}},bl=Jc(yl);function U(...e){return bl(ds(e))}const Ss=Fr("inline-flex items-center justify-center transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50",{variants:{variant:{default:"bg-black text-white hover:bg-black/90",outline:"border-2 border-gray-200 bg-white text-gray-700 hover:bg-gray-100",ghost:"text-gray-700 hover:bg-gray-100",error:"bg-red-500 text-white hover:bg-[#EA4335]",success:"bg-green-500 text-white hover:bg-[#00C752]",warning:"bg-yellow-500 text-white hover:bg-[#FFB200]",blue:"bg-[#4389FF] text-white hover:bg-blue-600",disabled:"bg-gray-200 text-gray-400 cursor-not-allowed hover:bg-gray-200",primary:"bg-customBlue text-white hover:bg-customBlue/90"},size:{large:"rounded-[12px] text-base py-2.5 px-5 leading-snug font-semibold gap-2",medium:"rounded-[10px] text-sm py-2 px-4 leading-tight font-semibold gap-2",small:"rounded-[14px] text-xs py-1.5 px-3 leading-4 font-semibold gap-1 h-9","icon.large":"rounded-[12px] p-2.5","icon.medium":"rounded-[10px] p-2","icon.small":"rounded-[14px] p-1.5"},iconSize:{large:"[&_svg]:w-6 [&_svg]:h-6",medium:"[&_svg]:w-5 [&_svg]:h-5",small:"[&_svg]:w-4 [&_svg]:h-4"},iconPosition:{left:"flex-row",right:"flex-row-reverse"},fullWidth:{true:"w-full",false:"w-auto"}},defaultVariants:{variant:"default",size:"medium",iconPosition:"left",fullWidth:!1}}),dt=N.forwardRef(({className:e,variant:t,size:n,iconSize:r,iconPosition:o,fullWidth:s,asChild:i=!1,icon:a,iconOnly:c,children:l,...f},u)=>{const h=i?_c:"button";let g=n;if(c&&n)switch(n){case"large":g="icon.large";break;case"medium":g="icon.medium";break;case"small":g="icon.small";break}const b=r||(n==="large"?"large":n==="small"?"small":"medium");return m.jsxs(h,{className:U(Ss({variant:t,size:g,iconSize:b,iconPosition:o,fullWidth:s,className:e})),ref:u,...f,children:[a&&m.jsx("span",{"data-testid":"button-icon",children:a}),!c&&l]})});dt.displayName="DoctButton";const wl={h1:{fontSize:"56px",tag:"h1"},h2:{fontSize:"46px",tag:"h2"},h3:{fontSize:"36px",tag:"h3"},h4:{fontSize:"32px",tag:"h4"},h5:{fontSize:"28px",tag:"h5"},h6:{fontSize:"24px",tag:"h6"},h7:{fontSize:"20px",tag:"p"},h8:{fontSize:"18px",tag:"p"},title1:{fontSize:"22px",tag:"p"},title2:{fontSize:"18px",tag:"p"},title3:{fontSize:"14px",tag:"p"},title4:{fontSize:"12px",tag:"p"},body1:{fontSize:"16px",tag:"p"},body2:{fontSize:"14px",tag:"p"},body3:{fontSize:"12px",tag:"p"},body4:{fontSize:"10px",tag:"p"},textLabel1:{fontSize:"16px",tag:"span"},textLabel2:{fontSize:"14px",tag:"span"},textLabel3:{fontSize:"12px",tag:"span"},textLabel4:{fontSize:"11px",tag:"span"}},xl={regular:"400",medium:"500",semiBold:"600",bold:"700",extraBold:"800",light:"300"},Sl=({variant:e,weight:t="regular",children:n,color:r="#000",align:o="inherit",className:s=""})=>{const i=wl[e]??{fontSize:"16px",tag:"p"},{fontSize:a,tag:c}=i;return m.jsx(c,{className:s,style:{fontSize:a,fontWeight:xl[t]??"400",color:r,textAlign:o,margin:0},children:n})};function kl(){return m.jsx("div",{className:"flex flex-col items-center justify-center h-screen w-full bg-white",children:m.jsx("img",{src:"/logoAnimation.gif",alt:"Loading animation",className:"w-32 h-32 object-contain"})})}const Zt=d.forwardRef(({className:e,type:t,...n},r)=>m.jsx("input",{type:t,className:U("flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-base ring-offset-background file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder-gray-400 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",e),ref:r,...n}));Zt.displayName="Input";var Ml=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],oe=Ml.reduce((e,t)=>{const n=ut(`Primitive.${t}`),r=d.forwardRef((o,s)=>{const{asChild:i,...a}=o,c=i?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),m.jsx(c,{...a,ref:s})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function Cl(e,t){e&&Tn.flushSync(()=>e.dispatchEvent(t))}var Nl="Label",ks=d.forwardRef((e,t)=>m.jsx(oe.label,{...e,ref:t,onMouseDown:n=>{var o;n.target.closest("button, input, select, textarea")||((o=e.onMouseDown)==null||o.call(e,n),!n.defaultPrevented&&n.detail>1&&n.preventDefault())}}));ks.displayName=Nl;var Ms=ks;const Dl=Fr("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),yt=d.forwardRef(({className:e,...t},n)=>m.jsx(Ms,{ref:n,className:U(Dl(),e),...t}));yt.displayName=Ms.displayName;function Ne({label:e,placeholder:t,helperText:n,error:r,required:o,type:s="text",icon:i,className:a,inputClassName:c,onChange:l}){return m.jsxs("div",{className:U("space-y-1",a),children:[e&&m.jsxs(yt,{className:"text-sm font-medium text-gray-700",children:[e,o&&m.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),m.jsxs("div",{className:"relative",children:[i&&m.jsx("div",{className:"absolute left-3 top-1/2 transform -translate-y-1/2 text-gray-400",children:i}),m.jsx(Zt,{type:s,placeholder:t,className:U(i&&"pl-10",r&&"border-red-500 focus-visible:ring-red-500",c),onChange:l})]}),(n||r)&&m.jsx("p",{className:U("text-xs",r?"text-red-500":"text-gray-500"),children:r||n})]})}function Ol({length:e=6,label:t,value:n,onChange:r,onComplete:o,className:s}){const i=N.useRef([]),a=(l,f)=>{var h;if(f.length>1)return;const u=[...n];u[l]=f,r(u),f&&l<e-1&&((h=i.current[l+1])==null||h.focus()),u.every(g=>g!=="")&&o&&o(u.join(""))},c=(l,f)=>{var u;f.key==="Backspace"&&!n[l]&&l>0&&((u=i.current[l-1])==null||u.focus())};return m.jsxs("div",{className:U("space-y-2",s),children:[t&&m.jsx(yt,{className:"text-sm font-medium text-gray-700",children:t}),m.jsx("div",{className:"flex gap-2",children:n.map((l,f)=>m.jsx(Zt,{ref:u=>i.current[f]=u,type:"text",inputMode:"numeric",maxLength:1,value:l,onChange:u=>a(f,u.target.value),onKeyDown:u=>c(f,u),className:"w-12 h-12 text-center p-0 text-lg font-semibold"},f))})]})}/**
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const f=require("react/jsx-runtime"),b=require("react"),xa=require("react-dom");function Si(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const d=Si(b),qr=Si(xa);function vs(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function Ct(...e){return t=>{let n=!1;const r=e.map(o=>{const a=vs(o,t);return!n&&typeof a=="function"&&(n=!0),a});if(n)return()=>{for(let o=0;o<r.length;o++){const a=r[o];typeof a=="function"?a():vs(e[o],null)}}}}function he(...e){return d.useCallback(Ct(...e),e)}function Pt(e){const t=km(e),n=d.forwardRef((r,o)=>{const{children:a,...s}=r,i=d.Children.toArray(a),l=i.find(Dm);if(l){const u=l.props.children,m=i.map(c=>c===l?d.Children.count(u)>1?d.Children.only(null):d.isValidElement(u)?u.props.children:null:c);return f.jsx(t,{...s,ref:o,children:d.isValidElement(u)?d.cloneElement(u,void 0,m):null})}return f.jsx(t,{...s,ref:o,children:a})});return n.displayName=`${e}.Slot`,n}var Em=Pt("Slot");function km(e){const t=d.forwardRef((n,r)=>{const{children:o,...a}=n;if(d.isValidElement(o)){const s=Tm(o),i=Rm(a,o.props);return o.type!==d.Fragment&&(i.ref=r?Ct(r,s):s),d.cloneElement(o,i)}return d.Children.count(o)>1?d.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Ci=Symbol("radix.slottable");function Nm(e){const t=({children:n})=>f.jsx(f.Fragment,{children:n});return t.displayName=`${e}.Slottable`,t.__radixId=Ci,t}function Dm(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Ci}function Rm(e,t){const n={...t};for(const r in t){const o=e[r],a=t[r];/^on[A-Z]/.test(r)?o&&a?n[r]=(...i)=>{const l=a(...i);return o(...i),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...a}:r==="className"&&(n[r]=[o,a].filter(Boolean).join(" "))}return{...e,...n}}function Tm(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function Mi(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(n=Mi(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function Ei(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=Mi(e))&&(r&&(r+=" "),r+=t);return r}const ys=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,bs=Ei,Sa=(e,t)=>n=>{var r;if((t==null?void 0:t.variants)==null)return bs(e,n==null?void 0:n.class,n==null?void 0:n.className);const{variants:o,defaultVariants:a}=t,s=Object.keys(o).map(u=>{const m=n==null?void 0:n[u],c=a==null?void 0:a[u];if(m===null)return null;const p=ys(m)||ys(c);return o[u][p]}),i=n&&Object.entries(n).reduce((u,m)=>{let[c,p]=m;return p===void 0||(u[c]=p),u},{}),l=t==null||(r=t.compoundVariants)===null||r===void 0?void 0:r.reduce((u,m)=>{let{class:c,className:p,...h}=m;return Object.entries(h).every(v=>{let[g,y]=v;return Array.isArray(y)?y.includes({...a,...i}[g]):{...a,...i}[g]===y})?[...u,c,p]:u},[]);return bs(e,s,l,n==null?void 0:n.class,n==null?void 0:n.className)},Ca="-",Om=e=>{const t=Pm(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:s=>{const i=s.split(Ca);return i[0]===""&&i.length!==1&&i.shift(),ki(i,t)||_m(s)},getConflictingClassGroupIds:(s,i)=>{const l=n[s]||[];return i&&r[s]?[...l,...r[s]]:l}}},ki=(e,t)=>{var s;if(e.length===0)return t.classGroupId;const n=e[0],r=t.nextPart.get(n),o=r?ki(e.slice(1),r):void 0;if(o)return o;if(t.validators.length===0)return;const a=e.join(Ca);return(s=t.validators.find(({validator:i})=>i(a)))==null?void 0:s.classGroupId},ws=/^\[(.+)\]$/,_m=e=>{if(ws.test(e)){const t=ws.exec(e)[1],n=t==null?void 0:t.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}},Pm=e=>{const{theme:t,classGroups:n}=e,r={nextPart:new Map,validators:[]};for(const o in n)Vo(n[o],r,o,t);return r},Vo=(e,t,n,r)=>{e.forEach(o=>{if(typeof o=="string"){const a=o===""?t:xs(t,o);a.classGroupId=n;return}if(typeof o=="function"){if(Am(o)){Vo(o(r),t,n,r);return}t.validators.push({validator:o,classGroupId:n});return}Object.entries(o).forEach(([a,s])=>{Vo(s,xs(t,a),n,r)})})},xs=(e,t)=>{let n=e;return t.split(Ca).forEach(r=>{n.nextPart.has(r)||n.nextPart.set(r,{nextPart:new Map,validators:[]}),n=n.nextPart.get(r)}),n},Am=e=>e.isThemeGetter,Im=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=new Map,r=new Map;const o=(a,s)=>{n.set(a,s),t++,t>e&&(t=0,r=n,n=new Map)};return{get(a){let s=n.get(a);if(s!==void 0)return s;if((s=r.get(a))!==void 0)return o(a,s),s},set(a,s){n.has(a)?n.set(a,s):o(a,s)}}},Ko="!",Xo=":",jm=Xo.length,$m=e=>{const{prefix:t,experimentalParseClassName:n}=e;let r=o=>{const a=[];let s=0,i=0,l=0,u;for(let v=0;v<o.length;v++){let g=o[v];if(s===0&&i===0){if(g===Xo){a.push(o.slice(l,v)),l=v+jm;continue}if(g==="/"){u=v;continue}}g==="["?s++:g==="]"?s--:g==="("?i++:g===")"&&i--}const m=a.length===0?o:o.substring(l),c=Lm(m),p=c!==m,h=u&&u>l?u-l:void 0;return{modifiers:a,hasImportantModifier:p,baseClassName:c,maybePostfixModifierPosition:h}};if(t){const o=t+Xo,a=r;r=s=>s.startsWith(o)?a(s.substring(o.length)):{isExternal:!0,modifiers:[],hasImportantModifier:!1,baseClassName:s,maybePostfixModifierPosition:void 0}}if(n){const o=r;r=a=>n({className:a,parseClassName:o})}return r},Lm=e=>e.endsWith(Ko)?e.substring(0,e.length-1):e.startsWith(Ko)?e.substring(1):e,Fm=e=>{const t=Object.fromEntries(e.orderSensitiveModifiers.map(r=>[r,!0]));return r=>{if(r.length<=1)return r;const o=[];let a=[];return r.forEach(s=>{s[0]==="["||t[s]?(o.push(...a.sort(),s),a=[]):a.push(s)}),o.push(...a.sort()),o}},Wm=e=>({cache:Im(e.cacheSize),parseClassName:$m(e),sortModifiers:Fm(e),...Om(e)}),Bm=/\s+/,Ym=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:o,sortModifiers:a}=t,s=[],i=e.trim().split(Bm);let l="";for(let u=i.length-1;u>=0;u-=1){const m=i[u],{isExternal:c,modifiers:p,hasImportantModifier:h,baseClassName:v,maybePostfixModifierPosition:g}=n(m);if(c){l=m+(l.length>0?" "+l:l);continue}let y=!!g,w=r(y?v.substring(0,g):v);if(!w){if(!y){l=m+(l.length>0?" "+l:l);continue}if(w=r(v),!w){l=m+(l.length>0?" "+l:l);continue}y=!1}const x=a(p).join(":"),S=h?x+Ko:x,k=S+w;if(s.includes(k))continue;s.push(k);const C=o(w,y);for(let N=0;N<C.length;++N){const M=C[N];s.push(S+M)}l=m+(l.length>0?" "+l:l)}return l};function Hm(){let e=0,t,n,r="";for(;e<arguments.length;)(t=arguments[e++])&&(n=Ni(t))&&(r&&(r+=" "),r+=n);return r}const Ni=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=Ni(e[r]))&&(n&&(n+=" "),n+=t);return n};function zm(e,...t){let n,r,o,a=s;function s(l){const u=t.reduce((m,c)=>c(m),e());return n=Wm(u),r=n.cache.get,o=n.cache.set,a=i,i(l)}function i(l){const u=r(l);if(u)return u;const m=Ym(l,n);return o(l,m),m}return function(){return a(Hm.apply(null,arguments))}}const Re=e=>{const t=n=>n[e]||[];return t.isThemeGetter=!0,t},Di=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,Ri=/^\((?:(\w[\w-]*):)?(.+)\)$/i,Gm=/^\d+\/\d+$/,Um=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,qm=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,Vm=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,Km=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,Xm=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,cn=e=>Gm.test(e),me=e=>!!e&&!Number.isNaN(Number(e)),Rt=e=>!!e&&Number.isInteger(Number(e)),So=e=>e.endsWith("%")&&me(e.slice(0,-1)),wt=e=>Um.test(e),Zm=()=>!0,Qm=e=>qm.test(e)&&!Vm.test(e),Ti=()=>!1,Jm=e=>Km.test(e),ep=e=>Xm.test(e),tp=e=>!J(e)&&!ee(e),np=e=>Sn(e,Pi,Ti),J=e=>Di.test(e),Ut=e=>Sn(e,Ai,Qm),Co=e=>Sn(e,ip,me),Ss=e=>Sn(e,Oi,Ti),rp=e=>Sn(e,_i,ep),vr=e=>Sn(e,Ii,Jm),ee=e=>Ri.test(e),In=e=>Cn(e,Ai),op=e=>Cn(e,cp),Cs=e=>Cn(e,Oi),ap=e=>Cn(e,Pi),sp=e=>Cn(e,_i),yr=e=>Cn(e,Ii,!0),Sn=(e,t,n)=>{const r=Di.exec(e);return r?r[1]?t(r[1]):n(r[2]):!1},Cn=(e,t,n=!1)=>{const r=Ri.exec(e);return r?r[1]?t(r[1]):n:!1},Oi=e=>e==="position"||e==="percentage",_i=e=>e==="image"||e==="url",Pi=e=>e==="length"||e==="size"||e==="bg-size",Ai=e=>e==="length",ip=e=>e==="number",cp=e=>e==="family-name",Ii=e=>e==="shadow",lp=()=>{const e=Re("color"),t=Re("font"),n=Re("text"),r=Re("font-weight"),o=Re("tracking"),a=Re("leading"),s=Re("breakpoint"),i=Re("container"),l=Re("spacing"),u=Re("radius"),m=Re("shadow"),c=Re("inset-shadow"),p=Re("text-shadow"),h=Re("drop-shadow"),v=Re("blur"),g=Re("perspective"),y=Re("aspect"),w=Re("ease"),x=Re("animate"),S=()=>["auto","avoid","all","avoid-page","page","left","right","column"],k=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],C=()=>[...k(),ee,J],N=()=>["auto","hidden","clip","visible","scroll"],M=()=>["auto","contain","none"],D=()=>[ee,J,l],L=()=>[cn,"full","auto",...D()],B=()=>[Rt,"none","subgrid",ee,J],F=()=>["auto",{span:["full",Rt,ee,J]},Rt,ee,J],V=()=>[Rt,"auto",ee,J],$=()=>["auto","min","max","fr",ee,J],I=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],_=()=>["start","end","center","stretch","center-safe","end-safe"],R=()=>["auto",...D()],P=()=>[cn,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...D()],E=()=>[e,ee,J],O=()=>[...k(),Cs,Ss,{position:[ee,J]}],Y=()=>["no-repeat",{repeat:["","x","y","space","round"]}],G=()=>["auto","cover","contain",ap,np,{size:[ee,J]}],T=()=>[So,In,Ut],A=()=>["","none","full",u,ee,J],W=()=>["",me,In,Ut],H=()=>["solid","dashed","dotted","double"],U=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],j=()=>[me,So,Cs,Ss],Z=()=>["","none",v,ee,J],X=()=>["none",me,ee,J],Q=()=>["none",me,ee,J],le=()=>[me,ee,J],de=()=>[cn,"full",...D()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[wt],breakpoint:[wt],color:[Zm],container:[wt],"drop-shadow":[wt],ease:["in","out","in-out"],font:[tp],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[wt],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[wt],shadow:[wt],spacing:["px",me],text:[wt],"text-shadow":[wt],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",cn,J,ee,y]}],container:["container"],columns:[{columns:[me,J,ee,i]}],"break-after":[{"break-after":S()}],"break-before":[{"break-before":S()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:C()}],overflow:[{overflow:N()}],"overflow-x":[{"overflow-x":N()}],"overflow-y":[{"overflow-y":N()}],overscroll:[{overscroll:M()}],"overscroll-x":[{"overscroll-x":M()}],"overscroll-y":[{"overscroll-y":M()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:L()}],"inset-x":[{"inset-x":L()}],"inset-y":[{"inset-y":L()}],start:[{start:L()}],end:[{end:L()}],top:[{top:L()}],right:[{right:L()}],bottom:[{bottom:L()}],left:[{left:L()}],visibility:["visible","invisible","collapse"],z:[{z:[Rt,"auto",ee,J]}],basis:[{basis:[cn,"full","auto",i,...D()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[me,cn,"auto","initial","none",J]}],grow:[{grow:["",me,ee,J]}],shrink:[{shrink:["",me,ee,J]}],order:[{order:[Rt,"first","last","none",ee,J]}],"grid-cols":[{"grid-cols":B()}],"col-start-end":[{col:F()}],"col-start":[{"col-start":V()}],"col-end":[{"col-end":V()}],"grid-rows":[{"grid-rows":B()}],"row-start-end":[{row:F()}],"row-start":[{"row-start":V()}],"row-end":[{"row-end":V()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":$()}],"auto-rows":[{"auto-rows":$()}],gap:[{gap:D()}],"gap-x":[{"gap-x":D()}],"gap-y":[{"gap-y":D()}],"justify-content":[{justify:[...I(),"normal"]}],"justify-items":[{"justify-items":[..._(),"normal"]}],"justify-self":[{"justify-self":["auto",..._()]}],"align-content":[{content:["normal",...I()]}],"align-items":[{items:[..._(),{baseline:["","last"]}]}],"align-self":[{self:["auto",..._(),{baseline:["","last"]}]}],"place-content":[{"place-content":I()}],"place-items":[{"place-items":[..._(),"baseline"]}],"place-self":[{"place-self":["auto",..._()]}],p:[{p:D()}],px:[{px:D()}],py:[{py:D()}],ps:[{ps:D()}],pe:[{pe:D()}],pt:[{pt:D()}],pr:[{pr:D()}],pb:[{pb:D()}],pl:[{pl:D()}],m:[{m:R()}],mx:[{mx:R()}],my:[{my:R()}],ms:[{ms:R()}],me:[{me:R()}],mt:[{mt:R()}],mr:[{mr:R()}],mb:[{mb:R()}],ml:[{ml:R()}],"space-x":[{"space-x":D()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":D()}],"space-y-reverse":["space-y-reverse"],size:[{size:P()}],w:[{w:[i,"screen",...P()]}],"min-w":[{"min-w":[i,"screen","none",...P()]}],"max-w":[{"max-w":[i,"screen","none","prose",{screen:[s]},...P()]}],h:[{h:["screen","lh",...P()]}],"min-h":[{"min-h":["screen","lh","none",...P()]}],"max-h":[{"max-h":["screen","lh",...P()]}],"font-size":[{text:["base",n,In,Ut]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[r,ee,Co]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",So,J]}],"font-family":[{font:[op,J,t]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:[o,ee,J]}],"line-clamp":[{"line-clamp":[me,"none",ee,Co]}],leading:[{leading:[a,...D()]}],"list-image":[{"list-image":["none",ee,J]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",ee,J]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:E()}],"text-color":[{text:E()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...H(),"wavy"]}],"text-decoration-thickness":[{decoration:[me,"from-font","auto",ee,Ut]}],"text-decoration-color":[{decoration:E()}],"underline-offset":[{"underline-offset":[me,"auto",ee,J]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:D()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",ee,J]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",ee,J]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:O()}],"bg-repeat":[{bg:Y()}],"bg-size":[{bg:G()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},Rt,ee,J],radial:["",ee,J],conic:[Rt,ee,J]},sp,rp]}],"bg-color":[{bg:E()}],"gradient-from-pos":[{from:T()}],"gradient-via-pos":[{via:T()}],"gradient-to-pos":[{to:T()}],"gradient-from":[{from:E()}],"gradient-via":[{via:E()}],"gradient-to":[{to:E()}],rounded:[{rounded:A()}],"rounded-s":[{"rounded-s":A()}],"rounded-e":[{"rounded-e":A()}],"rounded-t":[{"rounded-t":A()}],"rounded-r":[{"rounded-r":A()}],"rounded-b":[{"rounded-b":A()}],"rounded-l":[{"rounded-l":A()}],"rounded-ss":[{"rounded-ss":A()}],"rounded-se":[{"rounded-se":A()}],"rounded-ee":[{"rounded-ee":A()}],"rounded-es":[{"rounded-es":A()}],"rounded-tl":[{"rounded-tl":A()}],"rounded-tr":[{"rounded-tr":A()}],"rounded-br":[{"rounded-br":A()}],"rounded-bl":[{"rounded-bl":A()}],"border-w":[{border:W()}],"border-w-x":[{"border-x":W()}],"border-w-y":[{"border-y":W()}],"border-w-s":[{"border-s":W()}],"border-w-e":[{"border-e":W()}],"border-w-t":[{"border-t":W()}],"border-w-r":[{"border-r":W()}],"border-w-b":[{"border-b":W()}],"border-w-l":[{"border-l":W()}],"divide-x":[{"divide-x":W()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":W()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...H(),"hidden","none"]}],"divide-style":[{divide:[...H(),"hidden","none"]}],"border-color":[{border:E()}],"border-color-x":[{"border-x":E()}],"border-color-y":[{"border-y":E()}],"border-color-s":[{"border-s":E()}],"border-color-e":[{"border-e":E()}],"border-color-t":[{"border-t":E()}],"border-color-r":[{"border-r":E()}],"border-color-b":[{"border-b":E()}],"border-color-l":[{"border-l":E()}],"divide-color":[{divide:E()}],"outline-style":[{outline:[...H(),"none","hidden"]}],"outline-offset":[{"outline-offset":[me,ee,J]}],"outline-w":[{outline:["",me,In,Ut]}],"outline-color":[{outline:E()}],shadow:[{shadow:["","none",m,yr,vr]}],"shadow-color":[{shadow:E()}],"inset-shadow":[{"inset-shadow":["none",c,yr,vr]}],"inset-shadow-color":[{"inset-shadow":E()}],"ring-w":[{ring:W()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:E()}],"ring-offset-w":[{"ring-offset":[me,Ut]}],"ring-offset-color":[{"ring-offset":E()}],"inset-ring-w":[{"inset-ring":W()}],"inset-ring-color":[{"inset-ring":E()}],"text-shadow":[{"text-shadow":["none",p,yr,vr]}],"text-shadow-color":[{"text-shadow":E()}],opacity:[{opacity:[me,ee,J]}],"mix-blend":[{"mix-blend":[...U(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":U()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[me]}],"mask-image-linear-from-pos":[{"mask-linear-from":j()}],"mask-image-linear-to-pos":[{"mask-linear-to":j()}],"mask-image-linear-from-color":[{"mask-linear-from":E()}],"mask-image-linear-to-color":[{"mask-linear-to":E()}],"mask-image-t-from-pos":[{"mask-t-from":j()}],"mask-image-t-to-pos":[{"mask-t-to":j()}],"mask-image-t-from-color":[{"mask-t-from":E()}],"mask-image-t-to-color":[{"mask-t-to":E()}],"mask-image-r-from-pos":[{"mask-r-from":j()}],"mask-image-r-to-pos":[{"mask-r-to":j()}],"mask-image-r-from-color":[{"mask-r-from":E()}],"mask-image-r-to-color":[{"mask-r-to":E()}],"mask-image-b-from-pos":[{"mask-b-from":j()}],"mask-image-b-to-pos":[{"mask-b-to":j()}],"mask-image-b-from-color":[{"mask-b-from":E()}],"mask-image-b-to-color":[{"mask-b-to":E()}],"mask-image-l-from-pos":[{"mask-l-from":j()}],"mask-image-l-to-pos":[{"mask-l-to":j()}],"mask-image-l-from-color":[{"mask-l-from":E()}],"mask-image-l-to-color":[{"mask-l-to":E()}],"mask-image-x-from-pos":[{"mask-x-from":j()}],"mask-image-x-to-pos":[{"mask-x-to":j()}],"mask-image-x-from-color":[{"mask-x-from":E()}],"mask-image-x-to-color":[{"mask-x-to":E()}],"mask-image-y-from-pos":[{"mask-y-from":j()}],"mask-image-y-to-pos":[{"mask-y-to":j()}],"mask-image-y-from-color":[{"mask-y-from":E()}],"mask-image-y-to-color":[{"mask-y-to":E()}],"mask-image-radial":[{"mask-radial":[ee,J]}],"mask-image-radial-from-pos":[{"mask-radial-from":j()}],"mask-image-radial-to-pos":[{"mask-radial-to":j()}],"mask-image-radial-from-color":[{"mask-radial-from":E()}],"mask-image-radial-to-color":[{"mask-radial-to":E()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":k()}],"mask-image-conic-pos":[{"mask-conic":[me]}],"mask-image-conic-from-pos":[{"mask-conic-from":j()}],"mask-image-conic-to-pos":[{"mask-conic-to":j()}],"mask-image-conic-from-color":[{"mask-conic-from":E()}],"mask-image-conic-to-color":[{"mask-conic-to":E()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:O()}],"mask-repeat":[{mask:Y()}],"mask-size":[{mask:G()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",ee,J]}],filter:[{filter:["","none",ee,J]}],blur:[{blur:Z()}],brightness:[{brightness:[me,ee,J]}],contrast:[{contrast:[me,ee,J]}],"drop-shadow":[{"drop-shadow":["","none",h,yr,vr]}],"drop-shadow-color":[{"drop-shadow":E()}],grayscale:[{grayscale:["",me,ee,J]}],"hue-rotate":[{"hue-rotate":[me,ee,J]}],invert:[{invert:["",me,ee,J]}],saturate:[{saturate:[me,ee,J]}],sepia:[{sepia:["",me,ee,J]}],"backdrop-filter":[{"backdrop-filter":["","none",ee,J]}],"backdrop-blur":[{"backdrop-blur":Z()}],"backdrop-brightness":[{"backdrop-brightness":[me,ee,J]}],"backdrop-contrast":[{"backdrop-contrast":[me,ee,J]}],"backdrop-grayscale":[{"backdrop-grayscale":["",me,ee,J]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[me,ee,J]}],"backdrop-invert":[{"backdrop-invert":["",me,ee,J]}],"backdrop-opacity":[{"backdrop-opacity":[me,ee,J]}],"backdrop-saturate":[{"backdrop-saturate":[me,ee,J]}],"backdrop-sepia":[{"backdrop-sepia":["",me,ee,J]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":D()}],"border-spacing-x":[{"border-spacing-x":D()}],"border-spacing-y":[{"border-spacing-y":D()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",ee,J]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[me,"initial",ee,J]}],ease:[{ease:["linear","initial",w,ee,J]}],delay:[{delay:[me,ee,J]}],animate:[{animate:["none",x,ee,J]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[g,ee,J]}],"perspective-origin":[{"perspective-origin":C()}],rotate:[{rotate:X()}],"rotate-x":[{"rotate-x":X()}],"rotate-y":[{"rotate-y":X()}],"rotate-z":[{"rotate-z":X()}],scale:[{scale:Q()}],"scale-x":[{"scale-x":Q()}],"scale-y":[{"scale-y":Q()}],"scale-z":[{"scale-z":Q()}],"scale-3d":["scale-3d"],skew:[{skew:le()}],"skew-x":[{"skew-x":le()}],"skew-y":[{"skew-y":le()}],transform:[{transform:[ee,J,"","none","gpu","cpu"]}],"transform-origin":[{origin:C()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:de()}],"translate-x":[{"translate-x":de()}],"translate-y":[{"translate-y":de()}],"translate-z":[{"translate-z":de()}],"translate-none":["translate-none"],accent:[{accent:E()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:E()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",ee,J]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":D()}],"scroll-mx":[{"scroll-mx":D()}],"scroll-my":[{"scroll-my":D()}],"scroll-ms":[{"scroll-ms":D()}],"scroll-me":[{"scroll-me":D()}],"scroll-mt":[{"scroll-mt":D()}],"scroll-mr":[{"scroll-mr":D()}],"scroll-mb":[{"scroll-mb":D()}],"scroll-ml":[{"scroll-ml":D()}],"scroll-p":[{"scroll-p":D()}],"scroll-px":[{"scroll-px":D()}],"scroll-py":[{"scroll-py":D()}],"scroll-ps":[{"scroll-ps":D()}],"scroll-pe":[{"scroll-pe":D()}],"scroll-pt":[{"scroll-pt":D()}],"scroll-pr":[{"scroll-pr":D()}],"scroll-pb":[{"scroll-pb":D()}],"scroll-pl":[{"scroll-pl":D()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",ee,J]}],fill:[{fill:["none",...E()]}],"stroke-w":[{stroke:[me,In,Ut,Co]}],stroke:[{stroke:["none",...E()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-x","border-w-y","border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-x","border-color-y","border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]},orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}},up=zm(lp);function q(...e){return up(Ei(e))}const ji=Sa("inline-flex items-center justify-center transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50",{variants:{variant:{default:"bg-black text-white hover:bg-black/90",outline:"border-2 border-gray-200 bg-white text-gray-700 hover:bg-gray-100",ghost:"text-gray-700 hover:bg-gray-100",error:"bg-red-500 text-white hover:bg-[#EA4335]",success:"bg-green-500 text-white hover:bg-[#00C752]",warning:"bg-yellow-500 text-white hover:bg-[#FFB200]",blue:"bg-[#4389FF] text-white hover:bg-blue-600",disabled:"bg-gray-200 text-gray-400 cursor-not-allowed hover:bg-gray-200",primary:"bg-customBlue text-white hover:bg-customBlue/90"},size:{large:"rounded-[12px] text-base py-2.5 px-5 leading-snug font-semibold gap-2",medium:"rounded-[10px] text-sm py-2 px-4 leading-tight font-semibold gap-2",small:"rounded-[14px] text-xs py-1.5 px-3 leading-4 font-semibold gap-1 h-9","icon.large":"rounded-[12px] p-2.5","icon.medium":"rounded-[10px] p-2","icon.small":"rounded-[14px] p-1.5"},iconSize:{large:"[&_svg]:w-6 [&_svg]:h-6",medium:"[&_svg]:w-5 [&_svg]:h-5",small:"[&_svg]:w-4 [&_svg]:h-4"},iconPosition:{left:"flex-row",right:"flex-row-reverse"},fullWidth:{true:"w-full",false:"w-auto"}},defaultVariants:{variant:"default",size:"medium",iconPosition:"left",fullWidth:!1}}),Kt=b.forwardRef(({className:e,variant:t,size:n,iconSize:r,iconPosition:o,fullWidth:a,asChild:s=!1,icon:i,iconOnly:l,children:u,...m},c)=>{const p=s?Em:"button";let h=n;if(l&&n)switch(n){case"large":h="icon.large";break;case"medium":h="icon.medium";break;case"small":h="icon.small";break}const v=r||(n==="large"?"large":n==="small"?"small":"medium");return f.jsxs(p,{className:q(ji({variant:t,size:h,iconSize:v,iconPosition:o,fullWidth:a,className:e})),ref:c,...m,children:[i&&f.jsx("span",{"data-testid":"button-icon",children:i}),!l&&u]})});Kt.displayName="DoctButton";const dp={h1:{fontSize:"56px",tag:"h1"},h2:{fontSize:"46px",tag:"h2"},h3:{fontSize:"36px",tag:"h3"},h4:{fontSize:"32px",tag:"h4"},h5:{fontSize:"28px",tag:"h5"},h6:{fontSize:"24px",tag:"h6"},h7:{fontSize:"20px",tag:"p"},h8:{fontSize:"18px",tag:"p"},title1:{fontSize:"22px",tag:"p"},title2:{fontSize:"18px",tag:"p"},title3:{fontSize:"14px",tag:"p"},title4:{fontSize:"12px",tag:"p"},body1:{fontSize:"16px",tag:"p"},body2:{fontSize:"14px",tag:"p"},body3:{fontSize:"12px",tag:"p"},body4:{fontSize:"10px",tag:"p"},textLabel1:{fontSize:"16px",tag:"span"},textLabel2:{fontSize:"14px",tag:"span"},textLabel3:{fontSize:"12px",tag:"span"},textLabel4:{fontSize:"11px",tag:"span"}},fp={regular:"400",medium:"500",semiBold:"600",bold:"700",extraBold:"800",light:"300"},mp=({variant:e,weight:t="regular",children:n,color:r="#000",align:o="inherit",className:a=""})=>{const s=dp[e]??{fontSize:"16px",tag:"p"},{fontSize:i,tag:l}=s;return f.jsx(l,{className:a,style:{fontSize:i,fontWeight:fp[t]??"400",color:r,textAlign:o,margin:0},children:n})};function pp(){return f.jsx("div",{className:"flex flex-col items-center justify-center h-screen w-full bg-white",children:f.jsx("img",{src:"/logoAnimation.gif",alt:"Loading animation",className:"w-32 h-32 object-contain"})})}const Mn=d.forwardRef(({className:e,type:t,...n},r)=>f.jsx("input",{type:t,className:q("flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-base ring-offset-background file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder-gray-400 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",e),ref:r,...n}));Mn.displayName="Input";var hp=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],te=hp.reduce((e,t)=>{const n=Pt(`Primitive.${t}`),r=d.forwardRef((o,a)=>{const{asChild:s,...i}=o,l=s?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),f.jsx(l,{...i,ref:a})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function $i(e,t){e&&qr.flushSync(()=>e.dispatchEvent(t))}var gp="Label",Li=d.forwardRef((e,t)=>f.jsx(te.label,{...e,ref:t,onMouseDown:n=>{var o;n.target.closest("button, input, select, textarea")||((o=e.onMouseDown)==null||o.call(e,n),!n.defaultPrevented&&n.detail>1&&n.preventDefault())}}));Li.displayName=gp;var Fi=Li;const vp=Sa("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),tn=d.forwardRef(({className:e,...t},n)=>f.jsx(Fi,{ref:n,className:q(vp(),e),...t}));tn.displayName=Fi.displayName;function Qe({label:e,placeholder:t,helperText:n,error:r,required:o,type:a="text",icon:s,className:i,inputClassName:l,onChange:u}){return f.jsxs("div",{className:q("space-y-1",i),children:[e&&f.jsxs(tn,{className:"text-sm font-medium text-gray-700",children:[e,o&&f.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),f.jsxs("div",{className:"relative",children:[s&&f.jsx("div",{className:"absolute left-3 top-1/2 transform -translate-y-1/2 text-gray-400",children:s}),f.jsx(Mn,{type:a,placeholder:t,className:q(s&&"pl-10",r&&"border-red-500 focus-visible:ring-red-500",l),onChange:u})]}),(n||r)&&f.jsx("p",{className:q("text-xs",r?"text-red-500":"text-gray-500"),children:r||n})]})}function yp({length:e=6,label:t,value:n,onChange:r,onComplete:o,className:a}){const s=b.useRef([]),i=(u,m)=>{var p;if(m.length>1)return;const c=[...n];c[u]=m,r(c),m&&u<e-1&&((p=s.current[u+1])==null||p.focus()),c.every(h=>h!=="")&&o&&o(c.join(""))},l=(u,m)=>{var c;m.key==="Backspace"&&!n[u]&&u>0&&((c=s.current[u-1])==null||c.focus())};return f.jsxs("div",{className:q("space-y-2",a),children:[t&&f.jsx(tn,{className:"text-sm font-medium text-gray-700",children:t}),f.jsx("div",{className:"flex gap-2",children:n.map((u,m)=>f.jsx(Mn,{ref:c=>s.current[m]=c,type:"text",inputMode:"numeric",maxLength:1,value:u,onChange:c=>i(m,c.target.value),onKeyDown:c=>l(m,c),className:"w-12 h-12 text-center p-0 text-lg font-semibold"},m))})]})}/**
2
2
  * @license lucide-react v0.474.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.
5
5
  * See the LICENSE file in the root directory of this source tree.
6
- */const El=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),Cs=(...e)=>e.filter((t,n,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===n).join(" ").trim();/**
6
+ */const bp=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),Wi=(...e)=>e.filter((t,n,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===n).join(" ").trim();/**
7
7
  * @license lucide-react v0.474.0 - ISC
8
8
  *
9
9
  * This source code is licensed under the ISC license.
10
10
  * See the LICENSE file in the root directory of this source tree.
11
- */var Pl={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"};/**
11
+ */var wp={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"};/**
12
12
  * @license lucide-react v0.474.0 - ISC
13
13
  *
14
14
  * This source code is licensed under the ISC license.
15
15
  * See the LICENSE file in the root directory of this source tree.
16
- */const Al=N.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:o="",children:s,iconNode:i,...a},c)=>N.createElement("svg",{ref:c,...Pl,width:t,height:t,stroke:e,strokeWidth:r?Number(n)*24/Number(t):n,className:Cs("lucide",o),...a},[...i.map(([l,f])=>N.createElement(l,f)),...Array.isArray(s)?s:[s]]));/**
16
+ */const xp=b.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:o="",children:a,iconNode:s,...i},l)=>b.createElement("svg",{ref:l,...wp,width:t,height:t,stroke:e,strokeWidth:r?Number(n)*24/Number(t):n,className:Wi("lucide",o),...i},[...s.map(([u,m])=>b.createElement(u,m)),...Array.isArray(a)?a:[a]]));/**
17
17
  * @license lucide-react v0.474.0 - ISC
18
18
  *
19
19
  * This source code is licensed under the ISC license.
20
20
  * See the LICENSE file in the root directory of this source tree.
21
- */const we=(e,t)=>{const n=N.forwardRef(({className:r,...o},s)=>N.createElement(Al,{ref:s,iconNode:t,className:Cs(`lucide-${El(e)}`,r),...o}));return n.displayName=`${e}`,n};/**
21
+ */const Ie=(e,t)=>{const n=b.forwardRef(({className:r,...o},a)=>b.createElement(xp,{ref:a,iconNode:t,className:Wi(`lucide-${bp(e)}`,r),...o}));return n.displayName=`${e}`,n};/**
22
22
  * @license lucide-react v0.474.0 - ISC
23
23
  *
24
24
  * This source code is licensed under the ISC license.
25
25
  * See the LICENSE file in the root directory of this source tree.
26
- */const Tl=[["rect",{width:"16",height:"20",x:"4",y:"2",rx:"2",ry:"2",key:"76otgf"}],["path",{d:"M9 22v-4h6v4",key:"r93iot"}],["path",{d:"M8 6h.01",key:"1dz90k"}],["path",{d:"M16 6h.01",key:"1x0f13"}],["path",{d:"M12 6h.01",key:"1vi96p"}],["path",{d:"M12 10h.01",key:"1nrarc"}],["path",{d:"M12 14h.01",key:"1etili"}],["path",{d:"M16 10h.01",key:"1m94wz"}],["path",{d:"M16 14h.01",key:"1gbofw"}],["path",{d:"M8 10h.01",key:"19clt8"}],["path",{d:"M8 14h.01",key:"6423bh"}]],Rl=we("Building",Tl);/**
26
+ */const Sp=[["rect",{width:"16",height:"20",x:"4",y:"2",rx:"2",ry:"2",key:"76otgf"}],["path",{d:"M9 22v-4h6v4",key:"r93iot"}],["path",{d:"M8 6h.01",key:"1dz90k"}],["path",{d:"M16 6h.01",key:"1x0f13"}],["path",{d:"M12 6h.01",key:"1vi96p"}],["path",{d:"M12 10h.01",key:"1nrarc"}],["path",{d:"M12 14h.01",key:"1etili"}],["path",{d:"M16 10h.01",key:"1m94wz"}],["path",{d:"M16 14h.01",key:"1gbofw"}],["path",{d:"M8 10h.01",key:"19clt8"}],["path",{d:"M8 14h.01",key:"6423bh"}]],Cp=Ie("Building",Sp);/**
27
27
  * @license lucide-react v0.474.0 - ISC
28
28
  *
29
29
  * This source code is licensed under the ISC license.
30
30
  * See the LICENSE file in the root directory of this source tree.
31
- */const _l=[["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"}],["path",{d:"M8 14h.01",key:"6423bh"}],["path",{d:"M12 14h.01",key:"1etili"}],["path",{d:"M16 14h.01",key:"1gbofw"}],["path",{d:"M8 18h.01",key:"lrp35t"}],["path",{d:"M12 18h.01",key:"mhygvu"}],["path",{d:"M16 18h.01",key:"kzsmim"}]],jl=we("CalendarDays",_l);/**
31
+ */const Mp=[["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"}],["path",{d:"M8 14h.01",key:"6423bh"}],["path",{d:"M12 14h.01",key:"1etili"}],["path",{d:"M16 14h.01",key:"1gbofw"}],["path",{d:"M8 18h.01",key:"lrp35t"}],["path",{d:"M12 18h.01",key:"mhygvu"}],["path",{d:"M16 18h.01",key:"kzsmim"}]],Ep=Ie("CalendarDays",Mp);/**
32
32
  * @license lucide-react v0.474.0 - ISC
33
33
  *
34
34
  * This source code is licensed under the ISC license.
35
35
  * See the LICENSE file in the root directory of this source tree.
36
- */const Il=[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]],Ns=we("Check",Il);/**
36
+ */const kp=[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]],Jn=Ie("Check",kp);/**
37
37
  * @license lucide-react v0.474.0 - ISC
38
38
  *
39
39
  * This source code is licensed under the ISC license.
40
40
  * See the LICENSE file in the root directory of this source tree.
41
- */const Wl=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],Ds=we("ChevronDown",Wl);/**
41
+ */const Np=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],Vr=Ie("ChevronDown",Np);/**
42
42
  * @license lucide-react v0.474.0 - ISC
43
43
  *
44
44
  * This source code is licensed under the ISC license.
45
45
  * See the LICENSE file in the root directory of this source tree.
46
- */const $l=[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]],Fl=we("ChevronLeft",$l);/**
46
+ */const Dp=[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]],Rp=Ie("ChevronLeft",Dp);/**
47
47
  * @license lucide-react v0.474.0 - ISC
48
48
  *
49
49
  * This source code is licensed under the ISC license.
50
50
  * See the LICENSE file in the root directory of this source tree.
51
- */const Ll=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],Bl=we("ChevronRight",Ll);/**
51
+ */const Tp=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],Bi=Ie("ChevronRight",Tp);/**
52
52
  * @license lucide-react v0.474.0 - ISC
53
53
  *
54
54
  * This source code is licensed under the ISC license.
55
55
  * See the LICENSE file in the root directory of this source tree.
56
- */const Yl=[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]],zl=we("ChevronUp",Yl);/**
56
+ */const Op=[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]],_p=Ie("ChevronUp",Op);/**
57
57
  * @license lucide-react v0.474.0 - ISC
58
58
  *
59
59
  * This source code is licensed under the ISC license.
60
60
  * See the LICENSE file in the root directory of this source tree.
61
- */const Hl=[["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"}]],ql=we("EyeOff",Hl);/**
61
+ */const Pp=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],Yi=Ie("Circle",Pp);/**
62
62
  * @license lucide-react v0.474.0 - ISC
63
63
  *
64
64
  * This source code is licensed under the ISC license.
65
65
  * See the LICENSE file in the root directory of this source tree.
66
- */const Ul=[["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"}]],Gl=we("Eye",Ul);/**
66
+ */const Ap=[["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"}]],Ip=Ie("EyeOff",Ap);/**
67
67
  * @license lucide-react v0.474.0 - ISC
68
68
  *
69
69
  * This source code is licensed under the ISC license.
70
70
  * See the LICENSE file in the root directory of this source tree.
71
- */const Kl=[["polygon",{points:"22 3 2 3 10 12.46 10 19 14 21 14 12.46 22 3",key:"1yg77f"}]],Vl=we("Filter",Kl);/**
71
+ */const jp=[["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"}]],$p=Ie("Eye",jp);/**
72
72
  * @license lucide-react v0.474.0 - ISC
73
73
  *
74
74
  * This source code is licensed under the ISC license.
75
75
  * See the LICENSE file in the root directory of this source tree.
76
- */const Xl=[["rect",{width:"20",height:"16",x:"2",y:"4",rx:"2",key:"18n3k1"}],["path",{d:"m22 7-8.97 5.7a1.94 1.94 0 0 1-2.06 0L2 7",key:"1ocrg3"}]],Os=we("Mail",Xl);/**
76
+ */const Lp=[["polygon",{points:"22 3 2 3 10 12.46 10 19 14 21 14 12.46 22 3",key:"1yg77f"}]],Fp=Ie("Filter",Lp);/**
77
77
  * @license lucide-react v0.474.0 - ISC
78
78
  *
79
79
  * This source code is licensed under the ISC license.
80
80
  * See the LICENSE file in the root directory of this source tree.
81
- */const Zl=[["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"}]],Ql=we("MapPin",Zl);/**
81
+ */const Wp=[["rect",{width:"20",height:"16",x:"2",y:"4",rx:"2",key:"18n3k1"}],["path",{d:"m22 7-8.97 5.7a1.94 1.94 0 0 1-2.06 0L2 7",key:"1ocrg3"}]],Hi=Ie("Mail",Wp);/**
82
82
  * @license lucide-react v0.474.0 - ISC
83
83
  *
84
84
  * This source code is licensed under the ISC license.
85
85
  * See the LICENSE file in the root directory of this source tree.
86
- */const Jl=[["path",{d:"M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6 19.79 19.79 0 0 1-3.07-8.67A2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72 12.84 12.84 0 0 0 .7 2.81 2 2 0 0 1-.45 2.11L8.09 9.91a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45 12.84 12.84 0 0 0 2.81.7A2 2 0 0 1 22 16.92z",key:"foiqr5"}]],eu=we("Phone",Jl);/**
86
+ */const Bp=[["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"}]],Yp=Ie("MapPin",Bp);/**
87
87
  * @license lucide-react v0.474.0 - ISC
88
88
  *
89
89
  * This source code is licensed under the ISC license.
90
90
  * See the LICENSE file in the root directory of this source tree.
91
- */const tu=[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]],Es=we("Search",tu);/**
91
+ */const Hp=[["path",{d:"M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6 19.79 19.79 0 0 1-3.07-8.67A2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72 12.84 12.84 0 0 0 .7 2.81 2 2 0 0 1-.45 2.11L8.09 9.91a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45 12.84 12.84 0 0 0 2.81.7A2 2 0 0 1 22 16.92z",key:"foiqr5"}]],zp=Ie("Phone",Hp);/**
92
92
  * @license lucide-react v0.474.0 - ISC
93
93
  *
94
94
  * This source code is licensed under the ISC license.
95
95
  * See the LICENSE file in the root directory of this source tree.
96
- */const nu=[["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"}]],ru=we("User",nu);/**
96
+ */const Gp=[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]],zi=Ie("Search",Gp);/**
97
97
  * @license lucide-react v0.474.0 - ISC
98
98
  *
99
99
  * This source code is licensed under the ISC license.
100
100
  * See the LICENSE file in the root directory of this source tree.
101
- */const ou=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],Br=we("X",ou);function Sr({label:e,placeholder:t="Enter password",helperText:n,error:r,required:o,className:s,showPassword:i=!1,onShowPasswordChange:a,value:c,onChange:l}){return m.jsxs("div",{className:U("space-y-1",s),children:[e&&m.jsxs(yt,{className:"text-sm font-medium text-gray-700",children:[e,o&&m.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),m.jsxs("div",{className:"relative",children:[m.jsx(Zt,{type:i?"text":"password",placeholder:t,className:U("pr-10",r&&"border-red-500 focus-visible:ring-red-500"),value:c,onChange:f=>l==null?void 0:l(f.target.value)}),m.jsx(dt,{type:"button",variant:"ghost",size:"small",className:"absolute right-2 top-1/2 -translate-y-1/2",onClick:()=>a==null?void 0:a(!i),children:i?m.jsx(ql,{className:"h-4 w-4 text-gray-400"}):m.jsx(Gl,{className:"h-4 w-4 text-gray-400"})})]}),r&&m.jsx("p",{className:"text-xs text-red-500",children:r}),n&&m.jsx("p",{className:"text-xs text-gray-500",children:n})]})}const Ps=d.forwardRef(({className:e,...t},n)=>m.jsx("textarea",{className:U("flex min-h-[80px] w-full rounded-md border border-input bg-background px-3 py-2 text-base ring-offset-background placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",e),ref:n,...t}));Ps.displayName="Textarea";function As({label:e,placeholder:t="Write here...",helperText:n,error:r,required:o,rows:s=4,className:i,onChange:a}){return m.jsxs("div",{className:U("space-y-1",i),children:[e&&m.jsxs(yt,{className:"text-sm font-medium text-gray-700",children:[e,o&&m.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),m.jsx(Ps,{placeholder:t,rows:s,className:U("resize-none",r&&"border-red-500 focus-visible:ring-red-500"),onChange:a}),(n||r)&&m.jsx("p",{className:U("text-xs",r?"text-red-500":"text-gray-500"),children:r||n})]})}function ae(e,t,{checkForDefaultPrevented:n=!0}={}){return function(o){if(e==null||e(o),n===!1||!o.defaultPrevented)return t==null?void 0:t(o)}}function su(e,t){const n=d.createContext(t),r=s=>{const{children:i,...a}=s,c=d.useMemo(()=>a,Object.values(a));return m.jsx(n.Provider,{value:c,children:i})};r.displayName=e+"Provider";function o(s){const i=d.useContext(n);if(i)return i;if(t!==void 0)return t;throw new Error(`\`${s}\` must be used within \`${e}\``)}return[r,o]}function Qt(e,t=[]){let n=[];function r(s,i){const a=d.createContext(i),c=n.length;n=[...n,i];const l=u=>{var S;const{scope:h,children:g,...b}=u,p=((S=h==null?void 0:h[e])==null?void 0:S[c])||a,v=d.useMemo(()=>b,Object.values(b));return m.jsx(p.Provider,{value:v,children:g})};l.displayName=s+"Provider";function f(u,h){var p;const g=((p=h==null?void 0:h[e])==null?void 0:p[c])||a,b=d.useContext(g);if(b)return b;if(i!==void 0)return i;throw new Error(`\`${u}\` must be used within \`${s}\``)}return[l,f]}const o=()=>{const s=n.map(i=>d.createContext(i));return function(a){const c=(a==null?void 0:a[e])||s;return d.useMemo(()=>({[`__scope${e}`]:{...a,[e]:c}}),[a,c])}};return o.scopeName=e,[r,au(o,...t)]}function au(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(s){const i=r.reduce((a,{useScope:c,scopeName:l})=>{const u=c(s)[`__scope${l}`];return{...a,...u}},{});return d.useMemo(()=>({[`__scope${t.scopeName}`]:i}),[i])}};return n.scopeName=t.scopeName,n}function ft(e){const t=d.useRef(e);return d.useEffect(()=>{t.current=e}),d.useMemo(()=>(...n)=>{var r;return(r=t.current)==null?void 0:r.call(t,...n)},[])}function iu(e,t=globalThis==null?void 0:globalThis.document){const n=ft(e);d.useEffect(()=>{const r=o=>{o.key==="Escape"&&n(o)};return t.addEventListener("keydown",r,{capture:!0}),()=>t.removeEventListener("keydown",r,{capture:!0})},[n,t])}var cu="DismissableLayer",kr="dismissableLayer.update",lu="dismissableLayer.pointerDownOutside",uu="dismissableLayer.focusOutside",xo,Ts=d.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Rn=d.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:s,onInteractOutside:i,onDismiss:a,...c}=e,l=d.useContext(Ts),[f,u]=d.useState(null),h=(f==null?void 0:f.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,g]=d.useState({}),b=fe(t,C=>u(C)),p=Array.from(l.layers),[v]=[...l.layersWithOutsidePointerEventsDisabled].slice(-1),S=p.indexOf(v),y=f?p.indexOf(f):-1,x=l.layersWithOutsidePointerEventsDisabled.size>0,O=y>=S,w=mu(C=>{const D=C.target,Y=[...l.branches].some(L=>L.contains(D));!O||Y||(o==null||o(C),i==null||i(C),C.defaultPrevented||a==null||a())},h),M=hu(C=>{const D=C.target;[...l.branches].some(L=>L.contains(D))||(s==null||s(C),i==null||i(C),C.defaultPrevented||a==null||a())},h);return iu(C=>{y===l.layers.size-1&&(r==null||r(C),!C.defaultPrevented&&a&&(C.preventDefault(),a()))},h),d.useEffect(()=>{if(f)return n&&(l.layersWithOutsidePointerEventsDisabled.size===0&&(xo=h.body.style.pointerEvents,h.body.style.pointerEvents="none"),l.layersWithOutsidePointerEventsDisabled.add(f)),l.layers.add(f),So(),()=>{n&&l.layersWithOutsidePointerEventsDisabled.size===1&&(h.body.style.pointerEvents=xo)}},[f,h,n,l]),d.useEffect(()=>()=>{f&&(l.layers.delete(f),l.layersWithOutsidePointerEventsDisabled.delete(f),So())},[f,l]),d.useEffect(()=>{const C=()=>g({});return document.addEventListener(kr,C),()=>document.removeEventListener(kr,C)},[]),m.jsx(oe.div,{...c,ref:b,style:{pointerEvents:x?O?"auto":"none":void 0,...e.style},onFocusCapture:ae(e.onFocusCapture,M.onFocusCapture),onBlurCapture:ae(e.onBlurCapture,M.onBlurCapture),onPointerDownCapture:ae(e.onPointerDownCapture,w.onPointerDownCapture)})});Rn.displayName=cu;var du="DismissableLayerBranch",fu=d.forwardRef((e,t)=>{const n=d.useContext(Ts),r=d.useRef(null),o=fe(t,r);return d.useEffect(()=>{const s=r.current;if(s)return n.branches.add(s),()=>{n.branches.delete(s)}},[n.branches]),m.jsx(oe.div,{...e,ref:o})});fu.displayName=du;function mu(e,t=globalThis==null?void 0:globalThis.document){const n=ft(e),r=d.useRef(!1),o=d.useRef(()=>{});return d.useEffect(()=>{const s=a=>{if(a.target&&!r.current){let c=function(){Rs(lu,n,l,{discrete:!0})};const l={originalEvent:a};a.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=c,t.addEventListener("click",o.current,{once:!0})):c()}else t.removeEventListener("click",o.current);r.current=!1},i=window.setTimeout(()=>{t.addEventListener("pointerdown",s)},0);return()=>{window.clearTimeout(i),t.removeEventListener("pointerdown",s),t.removeEventListener("click",o.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function hu(e,t=globalThis==null?void 0:globalThis.document){const n=ft(e),r=d.useRef(!1);return d.useEffect(()=>{const o=s=>{s.target&&!r.current&&Rs(uu,n,{originalEvent:s},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function So(){const e=new CustomEvent(kr);document.dispatchEvent(e)}function Rs(e,t,n,{discrete:r}){const o=n.originalEvent.target,s=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?Cl(o,s):o.dispatchEvent(s)}var nr=0;function Yr(){d.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??ko()),document.body.insertAdjacentElement("beforeend",e[1]??ko()),nr++,()=>{nr===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),nr--}},[])}function ko(){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}var rr="focusScope.autoFocusOnMount",or="focusScope.autoFocusOnUnmount",Mo={bubbles:!1,cancelable:!0},pu="FocusScope",_n=d.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:o,onUnmountAutoFocus:s,...i}=e,[a,c]=d.useState(null),l=ft(o),f=ft(s),u=d.useRef(null),h=fe(t,p=>c(p)),g=d.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;d.useEffect(()=>{if(r){let p=function(x){if(g.paused||!a)return;const O=x.target;a.contains(O)?u.current=O:Ze(u.current,{select:!0})},v=function(x){if(g.paused||!a)return;const O=x.relatedTarget;O!==null&&(a.contains(O)||Ze(u.current,{select:!0}))},S=function(x){if(document.activeElement===document.body)for(const w of x)w.removedNodes.length>0&&Ze(a)};document.addEventListener("focusin",p),document.addEventListener("focusout",v);const y=new MutationObserver(S);return a&&y.observe(a,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",p),document.removeEventListener("focusout",v),y.disconnect()}}},[r,a,g.paused]),d.useEffect(()=>{if(a){No.add(g);const p=document.activeElement;if(!a.contains(p)){const S=new CustomEvent(rr,Mo);a.addEventListener(rr,l),a.dispatchEvent(S),S.defaultPrevented||(gu(xu(_s(a)),{select:!0}),document.activeElement===p&&Ze(a))}return()=>{a.removeEventListener(rr,l),setTimeout(()=>{const S=new CustomEvent(or,Mo);a.addEventListener(or,f),a.dispatchEvent(S),S.defaultPrevented||Ze(p??document.body,{select:!0}),a.removeEventListener(or,f),No.remove(g)},0)}}},[a,l,f,g]);const b=d.useCallback(p=>{if(!n&&!r||g.paused)return;const v=p.key==="Tab"&&!p.altKey&&!p.ctrlKey&&!p.metaKey,S=document.activeElement;if(v&&S){const y=p.currentTarget,[x,O]=vu(y);x&&O?!p.shiftKey&&S===O?(p.preventDefault(),n&&Ze(x,{select:!0})):p.shiftKey&&S===x&&(p.preventDefault(),n&&Ze(O,{select:!0})):S===y&&p.preventDefault()}},[n,r,g.paused]);return m.jsx(oe.div,{tabIndex:-1,...i,ref:h,onKeyDown:b})});_n.displayName=pu;function gu(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(Ze(r,{select:t}),document.activeElement!==n)return}function vu(e){const t=_s(e),n=Co(t,e),r=Co(t.reverse(),e);return[n,r]}function _s(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function Co(e,t){for(const n of e)if(!yu(n,{upTo:t}))return n}function yu(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 bu(e){return e instanceof HTMLInputElement&&"select"in e}function Ze(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&bu(e)&&t&&e.select()}}var No=wu();function wu(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=Do(e,t),e.unshift(t)},remove(t){var n;e=Do(e,t),(n=e[0])==null||n.resume()}}}function Do(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function xu(e){return e.filter(t=>t.tagName!=="A")}var be=globalThis!=null&&globalThis.document?d.useLayoutEffect:()=>{},Su=d[" useId ".trim().toString()]||(()=>{}),ku=0;function Me(e){const[t,n]=d.useState(Su());return be(()=>{n(r=>r??String(ku++))},[e]),e||(t?`radix-${t}`:"")}const Mu=["top","right","bottom","left"],Qe=Math.min,ke=Math.max,xn=Math.round,ln=Math.floor,$e=e=>({x:e,y:e}),Cu={left:"right",right:"left",bottom:"top",top:"bottom"},Nu={start:"end",end:"start"};function Mr(e,t,n){return ke(e,Qe(t,n))}function qe(e,t){return typeof e=="function"?e(t):e}function Ue(e){return e.split("-")[0]}function jt(e){return e.split("-")[1]}function zr(e){return e==="x"?"y":"x"}function Hr(e){return e==="y"?"height":"width"}const Du=new Set(["top","bottom"]);function Ie(e){return Du.has(Ue(e))?"y":"x"}function qr(e){return zr(Ie(e))}function Ou(e,t,n){n===void 0&&(n=!1);const r=jt(e),o=qr(e),s=Hr(o);let i=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[s]>t.floating[s]&&(i=Sn(i)),[i,Sn(i)]}function Eu(e){const t=Sn(e);return[Cr(e),t,Cr(t)]}function Cr(e){return e.replace(/start|end/g,t=>Nu[t])}const Oo=["left","right"],Eo=["right","left"],Pu=["top","bottom"],Au=["bottom","top"];function Tu(e,t,n){switch(e){case"top":case"bottom":return n?t?Eo:Oo:t?Oo:Eo;case"left":case"right":return t?Pu:Au;default:return[]}}function Ru(e,t,n,r){const o=jt(e);let s=Tu(Ue(e),n==="start",r);return o&&(s=s.map(i=>i+"-"+o),t&&(s=s.concat(s.map(Cr)))),s}function Sn(e){return e.replace(/left|right|bottom|top/g,t=>Cu[t])}function _u(e){return{top:0,right:0,bottom:0,left:0,...e}}function js(e){return typeof e!="number"?_u(e):{top:e,right:e,bottom:e,left:e}}function kn(e){const{x:t,y:n,width:r,height:o}=e;return{width:r,height:o,top:n,left:t,right:t+r,bottom:n+o,x:t,y:n}}function Po(e,t,n){let{reference:r,floating:o}=e;const s=Ie(t),i=qr(t),a=Hr(i),c=Ue(t),l=s==="y",f=r.x+r.width/2-o.width/2,u=r.y+r.height/2-o.height/2,h=r[a]/2-o[a]/2;let g;switch(c){case"top":g={x:f,y:r.y-o.height};break;case"bottom":g={x:f,y:r.y+r.height};break;case"right":g={x:r.x+r.width,y:u};break;case"left":g={x:r.x-o.width,y:u};break;default:g={x:r.x,y:r.y}}switch(jt(t)){case"start":g[i]-=h*(n&&l?-1:1);break;case"end":g[i]+=h*(n&&l?-1:1);break}return g}const ju=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:s=[],platform:i}=n,a=s.filter(Boolean),c=await(i.isRTL==null?void 0:i.isRTL(t));let l=await i.getElementRects({reference:e,floating:t,strategy:o}),{x:f,y:u}=Po(l,r,c),h=r,g={},b=0;for(let p=0;p<a.length;p++){const{name:v,fn:S}=a[p],{x:y,y:x,data:O,reset:w}=await S({x:f,y:u,initialPlacement:r,placement:h,strategy:o,middlewareData:g,rects:l,platform:i,elements:{reference:e,floating:t}});f=y??f,u=x??u,g={...g,[v]:{...g[v],...O}},w&&b<=50&&(b++,typeof w=="object"&&(w.placement&&(h=w.placement),w.rects&&(l=w.rects===!0?await i.getElementRects({reference:e,floating:t,strategy:o}):w.rects),{x:f,y:u}=Po(l,h,c)),p=-1)}return{x:f,y:u,placement:h,strategy:o,middlewareData:g}};async function Gt(e,t){var n;t===void 0&&(t={});const{x:r,y:o,platform:s,rects:i,elements:a,strategy:c}=e,{boundary:l="clippingAncestors",rootBoundary:f="viewport",elementContext:u="floating",altBoundary:h=!1,padding:g=0}=qe(t,e),b=js(g),v=a[h?u==="floating"?"reference":"floating":u],S=kn(await s.getClippingRect({element:(n=await(s.isElement==null?void 0:s.isElement(v)))==null||n?v:v.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(a.floating)),boundary:l,rootBoundary:f,strategy:c})),y=u==="floating"?{x:r,y:o,width:i.floating.width,height:i.floating.height}:i.reference,x=await(s.getOffsetParent==null?void 0:s.getOffsetParent(a.floating)),O=await(s.isElement==null?void 0:s.isElement(x))?await(s.getScale==null?void 0:s.getScale(x))||{x:1,y:1}:{x:1,y:1},w=kn(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:y,offsetParent:x,strategy:c}):y);return{top:(S.top-w.top+b.top)/O.y,bottom:(w.bottom-S.bottom+b.bottom)/O.y,left:(S.left-w.left+b.left)/O.x,right:(w.right-S.right+b.right)/O.x}}const Iu=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:o,rects:s,platform:i,elements:a,middlewareData:c}=t,{element:l,padding:f=0}=qe(e,t)||{};if(l==null)return{};const u=js(f),h={x:n,y:r},g=qr(o),b=Hr(g),p=await i.getDimensions(l),v=g==="y",S=v?"top":"left",y=v?"bottom":"right",x=v?"clientHeight":"clientWidth",O=s.reference[b]+s.reference[g]-h[g]-s.floating[b],w=h[g]-s.reference[g],M=await(i.getOffsetParent==null?void 0:i.getOffsetParent(l));let C=M?M[x]:0;(!C||!await(i.isElement==null?void 0:i.isElement(M)))&&(C=a.floating[x]||s.floating[b]);const D=O/2-w/2,Y=C/2-p[b]/2-1,L=Qe(u[S],Y),$=Qe(u[y],Y),K=L,J=C-p[b]-$,_=C/2-p[b]/2+D,A=Mr(K,_,J),P=!c.arrow&&jt(o)!=null&&_!==A&&s.reference[b]/2-(_<K?L:$)-p[b]/2<0,T=P?_<K?_-K:_-J:0;return{[g]:h[g]+T,data:{[g]:A,centerOffset:_-A-T,...P&&{alignmentOffset:T}},reset:P}}}),Wu=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:o,middlewareData:s,rects:i,initialPlacement:a,platform:c,elements:l}=t,{mainAxis:f=!0,crossAxis:u=!0,fallbackPlacements:h,fallbackStrategy:g="bestFit",fallbackAxisSideDirection:b="none",flipAlignment:p=!0,...v}=qe(e,t);if((n=s.arrow)!=null&&n.alignmentOffset)return{};const S=Ue(o),y=Ie(a),x=Ue(a)===a,O=await(c.isRTL==null?void 0:c.isRTL(l.floating)),w=h||(x||!p?[Sn(a)]:Eu(a)),M=b!=="none";!h&&M&&w.push(...Ru(a,p,b,O));const C=[a,...w],D=await Gt(t,v),Y=[];let L=((r=s.flip)==null?void 0:r.overflows)||[];if(f&&Y.push(D[S]),u){const _=Ou(o,i,O);Y.push(D[_[0]],D[_[1]])}if(L=[...L,{placement:o,overflows:Y}],!Y.every(_=>_<=0)){var $,K;const _=((($=s.flip)==null?void 0:$.index)||0)+1,A=C[_];if(A&&(!(u==="alignment"?y!==Ie(A):!1)||L.every(k=>k.overflows[0]>0&&Ie(k.placement)===y)))return{data:{index:_,overflows:L},reset:{placement:A}};let P=(K=L.filter(T=>T.overflows[0]<=0).sort((T,k)=>T.overflows[1]-k.overflows[1])[0])==null?void 0:K.placement;if(!P)switch(g){case"bestFit":{var J;const T=(J=L.filter(k=>{if(M){const I=Ie(k.placement);return I===y||I==="y"}return!0}).map(k=>[k.placement,k.overflows.filter(I=>I>0).reduce((I,B)=>I+B,0)]).sort((k,I)=>k[1]-I[1])[0])==null?void 0:J[0];T&&(P=T);break}case"initialPlacement":P=a;break}if(o!==P)return{reset:{placement:P}}}return{}}}};function Ao(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function To(e){return Mu.some(t=>e[t]>=0)}const $u=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...o}=qe(e,t);switch(r){case"referenceHidden":{const s=await Gt(t,{...o,elementContext:"reference"}),i=Ao(s,n.reference);return{data:{referenceHiddenOffsets:i,referenceHidden:To(i)}}}case"escaped":{const s=await Gt(t,{...o,altBoundary:!0}),i=Ao(s,n.floating);return{data:{escapedOffsets:i,escaped:To(i)}}}default:return{}}}}},Is=new Set(["left","top"]);async function Fu(e,t){const{placement:n,platform:r,elements:o}=e,s=await(r.isRTL==null?void 0:r.isRTL(o.floating)),i=Ue(n),a=jt(n),c=Ie(n)==="y",l=Is.has(i)?-1:1,f=s&&c?-1:1,u=qe(t,e);let{mainAxis:h,crossAxis:g,alignmentAxis:b}=typeof u=="number"?{mainAxis:u,crossAxis:0,alignmentAxis:null}:{mainAxis:u.mainAxis||0,crossAxis:u.crossAxis||0,alignmentAxis:u.alignmentAxis};return a&&typeof b=="number"&&(g=a==="end"?b*-1:b),c?{x:g*f,y:h*l}:{x:h*l,y:g*f}}const Lu=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:o,y:s,placement:i,middlewareData:a}=t,c=await Fu(t,e);return i===((n=a.offset)==null?void 0:n.placement)&&(r=a.arrow)!=null&&r.alignmentOffset?{}:{x:o+c.x,y:s+c.y,data:{...c,placement:i}}}}},Bu=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:s=!0,crossAxis:i=!1,limiter:a={fn:v=>{let{x:S,y}=v;return{x:S,y}}},...c}=qe(e,t),l={x:n,y:r},f=await Gt(t,c),u=Ie(Ue(o)),h=zr(u);let g=l[h],b=l[u];if(s){const v=h==="y"?"top":"left",S=h==="y"?"bottom":"right",y=g+f[v],x=g-f[S];g=Mr(y,g,x)}if(i){const v=u==="y"?"top":"left",S=u==="y"?"bottom":"right",y=b+f[v],x=b-f[S];b=Mr(y,b,x)}const p=a.fn({...t,[h]:g,[u]:b});return{...p,data:{x:p.x-n,y:p.y-r,enabled:{[h]:s,[u]:i}}}}}},Yu=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:s,middlewareData:i}=t,{offset:a=0,mainAxis:c=!0,crossAxis:l=!0}=qe(e,t),f={x:n,y:r},u=Ie(o),h=zr(u);let g=f[h],b=f[u];const p=qe(a,t),v=typeof p=="number"?{mainAxis:p,crossAxis:0}:{mainAxis:0,crossAxis:0,...p};if(c){const x=h==="y"?"height":"width",O=s.reference[h]-s.floating[x]+v.mainAxis,w=s.reference[h]+s.reference[x]-v.mainAxis;g<O?g=O:g>w&&(g=w)}if(l){var S,y;const x=h==="y"?"width":"height",O=Is.has(Ue(o)),w=s.reference[u]-s.floating[x]+(O&&((S=i.offset)==null?void 0:S[u])||0)+(O?0:v.crossAxis),M=s.reference[u]+s.reference[x]+(O?0:((y=i.offset)==null?void 0:y[u])||0)-(O?v.crossAxis:0);b<w?b=w:b>M&&(b=M)}return{[h]:g,[u]:b}}}},zu=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:o,rects:s,platform:i,elements:a}=t,{apply:c=()=>{},...l}=qe(e,t),f=await Gt(t,l),u=Ue(o),h=jt(o),g=Ie(o)==="y",{width:b,height:p}=s.floating;let v,S;u==="top"||u==="bottom"?(v=u,S=h===(await(i.isRTL==null?void 0:i.isRTL(a.floating))?"start":"end")?"left":"right"):(S=u,v=h==="end"?"top":"bottom");const y=p-f.top-f.bottom,x=b-f.left-f.right,O=Qe(p-f[v],y),w=Qe(b-f[S],x),M=!t.middlewareData.shift;let C=O,D=w;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(D=x),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(C=y),M&&!h){const L=ke(f.left,0),$=ke(f.right,0),K=ke(f.top,0),J=ke(f.bottom,0);g?D=b-2*(L!==0||$!==0?L+$:ke(f.left,f.right)):C=p-2*(K!==0||J!==0?K+J:ke(f.top,f.bottom))}await c({...t,availableWidth:D,availableHeight:C});const Y=await i.getDimensions(a.floating);return b!==Y.width||p!==Y.height?{reset:{rects:!0}}:{}}}};function jn(){return typeof window<"u"}function It(e){return Ws(e)?(e.nodeName||"").toLowerCase():"#document"}function Ce(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Le(e){var t;return(t=(Ws(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Ws(e){return jn()?e instanceof Node||e instanceof Ce(e).Node:!1}function Pe(e){return jn()?e instanceof Element||e instanceof Ce(e).Element:!1}function Fe(e){return jn()?e instanceof HTMLElement||e instanceof Ce(e).HTMLElement:!1}function Ro(e){return!jn()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof Ce(e).ShadowRoot}const Hu=new Set(["inline","contents"]);function Jt(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=Ae(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!Hu.has(o)}const qu=new Set(["table","td","th"]);function Uu(e){return qu.has(It(e))}const Gu=[":popover-open",":modal"];function In(e){return Gu.some(t=>{try{return e.matches(t)}catch{return!1}})}const Ku=["transform","translate","scale","rotate","perspective"],Vu=["transform","translate","scale","rotate","perspective","filter"],Xu=["paint","layout","strict","content"];function Ur(e){const t=Gr(),n=Pe(e)?Ae(e):e;return Ku.some(r=>n[r]?n[r]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||Vu.some(r=>(n.willChange||"").includes(r))||Xu.some(r=>(n.contain||"").includes(r))}function Zu(e){let t=Je(e);for(;Fe(t)&&!Et(t);){if(Ur(t))return t;if(In(t))return null;t=Je(t)}return null}function Gr(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const Qu=new Set(["html","body","#document"]);function Et(e){return Qu.has(It(e))}function Ae(e){return Ce(e).getComputedStyle(e)}function Wn(e){return Pe(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Je(e){if(It(e)==="html")return e;const t=e.assignedSlot||e.parentNode||Ro(e)&&e.host||Le(e);return Ro(t)?t.host:t}function $s(e){const t=Je(e);return Et(t)?e.ownerDocument?e.ownerDocument.body:e.body:Fe(t)&&Jt(t)?t:$s(t)}function Kt(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=$s(e),s=o===((r=e.ownerDocument)==null?void 0:r.body),i=Ce(o);if(s){const a=Nr(i);return t.concat(i,i.visualViewport||[],Jt(o)?o:[],a&&n?Kt(a):[])}return t.concat(o,Kt(o,[],n))}function Nr(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Fs(e){const t=Ae(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=Fe(e),s=o?e.offsetWidth:n,i=o?e.offsetHeight:r,a=xn(n)!==s||xn(r)!==i;return a&&(n=s,r=i),{width:n,height:r,$:a}}function Kr(e){return Pe(e)?e:e.contextElement}function Dt(e){const t=Kr(e);if(!Fe(t))return $e(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:s}=Fs(t);let i=(s?xn(n.width):n.width)/r,a=(s?xn(n.height):n.height)/o;return(!i||!Number.isFinite(i))&&(i=1),(!a||!Number.isFinite(a))&&(a=1),{x:i,y:a}}const Ju=$e(0);function Ls(e){const t=Ce(e);return!Gr()||!t.visualViewport?Ju:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function ed(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==Ce(e)?!1:t}function mt(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),s=Kr(e);let i=$e(1);t&&(r?Pe(r)&&(i=Dt(r)):i=Dt(e));const a=ed(s,n,r)?Ls(s):$e(0);let c=(o.left+a.x)/i.x,l=(o.top+a.y)/i.y,f=o.width/i.x,u=o.height/i.y;if(s){const h=Ce(s),g=r&&Pe(r)?Ce(r):r;let b=h,p=Nr(b);for(;p&&r&&g!==b;){const v=Dt(p),S=p.getBoundingClientRect(),y=Ae(p),x=S.left+(p.clientLeft+parseFloat(y.paddingLeft))*v.x,O=S.top+(p.clientTop+parseFloat(y.paddingTop))*v.y;c*=v.x,l*=v.y,f*=v.x,u*=v.y,c+=x,l+=O,b=Ce(p),p=Nr(b)}}return kn({width:f,height:u,x:c,y:l})}function Vr(e,t){const n=Wn(e).scrollLeft;return t?t.left+n:mt(Le(e)).left+n}function Bs(e,t,n){n===void 0&&(n=!1);const r=e.getBoundingClientRect(),o=r.left+t.scrollLeft-(n?0:Vr(e,r)),s=r.top+t.scrollTop;return{x:o,y:s}}function td(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const s=o==="fixed",i=Le(r),a=t?In(t.floating):!1;if(r===i||a&&s)return n;let c={scrollLeft:0,scrollTop:0},l=$e(1);const f=$e(0),u=Fe(r);if((u||!u&&!s)&&((It(r)!=="body"||Jt(i))&&(c=Wn(r)),Fe(r))){const g=mt(r);l=Dt(r),f.x=g.x+r.clientLeft,f.y=g.y+r.clientTop}const h=i&&!u&&!s?Bs(i,c,!0):$e(0);return{width:n.width*l.x,height:n.height*l.y,x:n.x*l.x-c.scrollLeft*l.x+f.x+h.x,y:n.y*l.y-c.scrollTop*l.y+f.y+h.y}}function nd(e){return Array.from(e.getClientRects())}function rd(e){const t=Le(e),n=Wn(e),r=e.ownerDocument.body,o=ke(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),s=ke(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let i=-n.scrollLeft+Vr(e);const a=-n.scrollTop;return Ae(r).direction==="rtl"&&(i+=ke(t.clientWidth,r.clientWidth)-o),{width:o,height:s,x:i,y:a}}function od(e,t){const n=Ce(e),r=Le(e),o=n.visualViewport;let s=r.clientWidth,i=r.clientHeight,a=0,c=0;if(o){s=o.width,i=o.height;const l=Gr();(!l||l&&t==="fixed")&&(a=o.offsetLeft,c=o.offsetTop)}return{width:s,height:i,x:a,y:c}}const sd=new Set(["absolute","fixed"]);function ad(e,t){const n=mt(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,s=Fe(e)?Dt(e):$e(1),i=e.clientWidth*s.x,a=e.clientHeight*s.y,c=o*s.x,l=r*s.y;return{width:i,height:a,x:c,y:l}}function _o(e,t,n){let r;if(t==="viewport")r=od(e,n);else if(t==="document")r=rd(Le(e));else if(Pe(t))r=ad(t,n);else{const o=Ls(e);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return kn(r)}function Ys(e,t){const n=Je(e);return n===t||!Pe(n)||Et(n)?!1:Ae(n).position==="fixed"||Ys(n,t)}function id(e,t){const n=t.get(e);if(n)return n;let r=Kt(e,[],!1).filter(a=>Pe(a)&&It(a)!=="body"),o=null;const s=Ae(e).position==="fixed";let i=s?Je(e):e;for(;Pe(i)&&!Et(i);){const a=Ae(i),c=Ur(i);!c&&a.position==="fixed"&&(o=null),(s?!c&&!o:!c&&a.position==="static"&&!!o&&sd.has(o.position)||Jt(i)&&!c&&Ys(e,i))?r=r.filter(f=>f!==i):o=a,i=Je(i)}return t.set(e,r),r}function cd(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const i=[...n==="clippingAncestors"?In(t)?[]:id(t,this._c):[].concat(n),r],a=i[0],c=i.reduce((l,f)=>{const u=_o(t,f,o);return l.top=ke(u.top,l.top),l.right=Qe(u.right,l.right),l.bottom=Qe(u.bottom,l.bottom),l.left=ke(u.left,l.left),l},_o(t,a,o));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function ld(e){const{width:t,height:n}=Fs(e);return{width:t,height:n}}function ud(e,t,n){const r=Fe(t),o=Le(t),s=n==="fixed",i=mt(e,!0,s,t);let a={scrollLeft:0,scrollTop:0};const c=$e(0);function l(){c.x=Vr(o)}if(r||!r&&!s)if((It(t)!=="body"||Jt(o))&&(a=Wn(t)),r){const g=mt(t,!0,s,t);c.x=g.x+t.clientLeft,c.y=g.y+t.clientTop}else o&&l();s&&!r&&o&&l();const f=o&&!r&&!s?Bs(o,a):$e(0),u=i.left+a.scrollLeft-c.x-f.x,h=i.top+a.scrollTop-c.y-f.y;return{x:u,y:h,width:i.width,height:i.height}}function sr(e){return Ae(e).position==="static"}function jo(e,t){if(!Fe(e)||Ae(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return Le(e)===n&&(n=n.ownerDocument.body),n}function zs(e,t){const n=Ce(e);if(In(e))return n;if(!Fe(e)){let o=Je(e);for(;o&&!Et(o);){if(Pe(o)&&!sr(o))return o;o=Je(o)}return n}let r=jo(e,t);for(;r&&Uu(r)&&sr(r);)r=jo(r,t);return r&&Et(r)&&sr(r)&&!Ur(r)?n:r||Zu(e)||n}const dd=async function(e){const t=this.getOffsetParent||zs,n=this.getDimensions,r=await n(e.floating);return{reference:ud(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function fd(e){return Ae(e).direction==="rtl"}const md={convertOffsetParentRelativeRectToViewportRelativeRect:td,getDocumentElement:Le,getClippingRect:cd,getOffsetParent:zs,getElementRects:dd,getClientRects:nd,getDimensions:ld,getScale:Dt,isElement:Pe,isRTL:fd};function Hs(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function hd(e,t){let n=null,r;const o=Le(e);function s(){var a;clearTimeout(r),(a=n)==null||a.disconnect(),n=null}function i(a,c){a===void 0&&(a=!1),c===void 0&&(c=1),s();const l=e.getBoundingClientRect(),{left:f,top:u,width:h,height:g}=l;if(a||t(),!h||!g)return;const b=ln(u),p=ln(o.clientWidth-(f+h)),v=ln(o.clientHeight-(u+g)),S=ln(f),x={rootMargin:-b+"px "+-p+"px "+-v+"px "+-S+"px",threshold:ke(0,Qe(1,c))||1};let O=!0;function w(M){const C=M[0].intersectionRatio;if(C!==c){if(!O)return i();C?i(!1,C):r=setTimeout(()=>{i(!1,1e-7)},1e3)}C===1&&!Hs(l,e.getBoundingClientRect())&&i(),O=!1}try{n=new IntersectionObserver(w,{...x,root:o.ownerDocument})}catch{n=new IntersectionObserver(w,x)}n.observe(e)}return i(!0),s}function pd(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:s=!0,elementResize:i=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:c=!1}=r,l=Kr(e),f=o||s?[...l?Kt(l):[],...Kt(t)]:[];f.forEach(S=>{o&&S.addEventListener("scroll",n,{passive:!0}),s&&S.addEventListener("resize",n)});const u=l&&a?hd(l,n):null;let h=-1,g=null;i&&(g=new ResizeObserver(S=>{let[y]=S;y&&y.target===l&&g&&(g.unobserve(t),cancelAnimationFrame(h),h=requestAnimationFrame(()=>{var x;(x=g)==null||x.observe(t)})),n()}),l&&!c&&g.observe(l),g.observe(t));let b,p=c?mt(e):null;c&&v();function v(){const S=mt(e);p&&!Hs(p,S)&&n(),p=S,b=requestAnimationFrame(v)}return n(),()=>{var S;f.forEach(y=>{o&&y.removeEventListener("scroll",n),s&&y.removeEventListener("resize",n)}),u==null||u(),(S=g)==null||S.disconnect(),g=null,c&&cancelAnimationFrame(b)}}const gd=Lu,vd=Bu,yd=Wu,bd=zu,wd=$u,Io=Iu,xd=Yu,Sd=(e,t,n)=>{const r=new Map,o={platform:md,...n},s={...o.platform,_c:r};return ju(e,t,{...o,platform:s})};var kd=typeof document<"u",Md=function(){},pn=kd?N.useLayoutEffect:Md;function Mn(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!Mn(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,o[r]))return!1;for(r=n;r--!==0;){const s=o[r];if(!(s==="_owner"&&e.$$typeof)&&!Mn(e[s],t[s]))return!1}return!0}return e!==e&&t!==t}function qs(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Wo(e,t){const n=qs(e);return Math.round(t*n)/n}function ar(e){const t=d.useRef(e);return pn(()=>{t.current=e}),t}function Cd(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:s,floating:i}={},transform:a=!0,whileElementsMounted:c,open:l}=e,[f,u]=d.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[h,g]=d.useState(r);Mn(h,r)||g(r);const[b,p]=d.useState(null),[v,S]=d.useState(null),y=d.useCallback(k=>{k!==M.current&&(M.current=k,p(k))},[]),x=d.useCallback(k=>{k!==C.current&&(C.current=k,S(k))},[]),O=s||b,w=i||v,M=d.useRef(null),C=d.useRef(null),D=d.useRef(f),Y=c!=null,L=ar(c),$=ar(o),K=ar(l),J=d.useCallback(()=>{if(!M.current||!C.current)return;const k={placement:t,strategy:n,middleware:h};$.current&&(k.platform=$.current),Sd(M.current,C.current,k).then(I=>{const B={...I,isPositioned:K.current!==!1};_.current&&!Mn(D.current,B)&&(D.current=B,Tn.flushSync(()=>{u(B)}))})},[h,t,n,$,K]);pn(()=>{l===!1&&D.current.isPositioned&&(D.current.isPositioned=!1,u(k=>({...k,isPositioned:!1})))},[l]);const _=d.useRef(!1);pn(()=>(_.current=!0,()=>{_.current=!1}),[]),pn(()=>{if(O&&(M.current=O),w&&(C.current=w),O&&w){if(L.current)return L.current(O,w,J);J()}},[O,w,J,L,Y]);const A=d.useMemo(()=>({reference:M,floating:C,setReference:y,setFloating:x}),[y,x]),P=d.useMemo(()=>({reference:O,floating:w}),[O,w]),T=d.useMemo(()=>{const k={position:n,left:0,top:0};if(!P.floating)return k;const I=Wo(P.floating,f.x),B=Wo(P.floating,f.y);return a?{...k,transform:"translate("+I+"px, "+B+"px)",...qs(P.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:I,top:B}},[n,a,P.floating,f.x,f.y]);return d.useMemo(()=>({...f,update:J,refs:A,elements:P,floatingStyles:T}),[f,J,A,P,T])}const Nd=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:o}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?Io({element:r.current,padding:o}).fn(n):{}:r?Io({element:r,padding:o}).fn(n):{}}}},Dd=(e,t)=>({...gd(e),options:[e,t]}),Od=(e,t)=>({...vd(e),options:[e,t]}),Ed=(e,t)=>({...xd(e),options:[e,t]}),Pd=(e,t)=>({...yd(e),options:[e,t]}),Ad=(e,t)=>({...bd(e),options:[e,t]}),Td=(e,t)=>({...wd(e),options:[e,t]}),Rd=(e,t)=>({...Nd(e),options:[e,t]});var _d="Arrow",Us=d.forwardRef((e,t)=>{const{children:n,width:r=10,height:o=5,...s}=e;return m.jsx(oe.svg,{...s,ref:t,width:r,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:m.jsx("polygon",{points:"0,0 30,0 15,10"})})});Us.displayName=_d;var jd=Us;function Id(e){const[t,n]=d.useState(void 0);return be(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(o=>{if(!Array.isArray(o)||!o.length)return;const s=o[0];let i,a;if("borderBoxSize"in s){const c=s.borderBoxSize,l=Array.isArray(c)?c[0]:c;i=l.inlineSize,a=l.blockSize}else i=e.offsetWidth,a=e.offsetHeight;n({width:i,height:a})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}var Xr="Popper",[Gs,$n]=Qt(Xr),[Wd,Ks]=Gs(Xr),Vs=e=>{const{__scopePopper:t,children:n}=e,[r,o]=d.useState(null);return m.jsx(Wd,{scope:t,anchor:r,onAnchorChange:o,children:n})};Vs.displayName=Xr;var Xs="PopperAnchor",Zs=d.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...o}=e,s=Ks(Xs,n),i=d.useRef(null),a=fe(t,i);return d.useEffect(()=>{s.onAnchorChange((r==null?void 0:r.current)||i.current)}),r?null:m.jsx(oe.div,{...o,ref:a})});Zs.displayName=Xs;var Zr="PopperContent",[$d,Fd]=Gs(Zr),Qs=d.forwardRef((e,t)=>{var R,V,Z,G,ee,te;const{__scopePopper:n,side:r="bottom",sideOffset:o=0,align:s="center",alignOffset:i=0,arrowPadding:a=0,avoidCollisions:c=!0,collisionBoundary:l=[],collisionPadding:f=0,sticky:u="partial",hideWhenDetached:h=!1,updatePositionStrategy:g="optimized",onPlaced:b,...p}=e,v=Ks(Zr,n),[S,y]=d.useState(null),x=fe(t,me=>y(me)),[O,w]=d.useState(null),M=Id(O),C=(M==null?void 0:M.width)??0,D=(M==null?void 0:M.height)??0,Y=r+(s!=="center"?"-"+s:""),L=typeof f=="number"?f:{top:0,right:0,bottom:0,left:0,...f},$=Array.isArray(l)?l:[l],K=$.length>0,J={padding:L,boundary:$.filter(Bd),altBoundary:K},{refs:_,floatingStyles:A,placement:P,isPositioned:T,middlewareData:k}=Cd({strategy:"fixed",placement:Y,whileElementsMounted:(...me)=>pd(...me,{animationFrame:g==="always"}),elements:{reference:v.anchor},middleware:[Dd({mainAxis:o+D,alignmentAxis:i}),c&&Od({mainAxis:!0,crossAxis:!1,limiter:u==="partial"?Ed():void 0,...J}),c&&Pd({...J}),Ad({...J,apply:({elements:me,rects:xe,availableWidth:ot,availableHeight:st})=>{const{width:at,height:Vn}=xe.reference,bt=me.floating.style;bt.setProperty("--radix-popper-available-width",`${ot}px`),bt.setProperty("--radix-popper-available-height",`${st}px`),bt.setProperty("--radix-popper-anchor-width",`${at}px`),bt.setProperty("--radix-popper-anchor-height",`${Vn}px`)}}),O&&Rd({element:O,padding:a}),Yd({arrowWidth:C,arrowHeight:D}),h&&Td({strategy:"referenceHidden",...J})]}),[I,B]=ta(P),Q=ft(b);be(()=>{T&&(Q==null||Q())},[T,Q]);const E=(R=k.arrow)==null?void 0:R.x,j=(V=k.arrow)==null?void 0:V.y,F=((Z=k.arrow)==null?void 0:Z.centerOffset)!==0,[W,X]=d.useState();return be(()=>{S&&X(window.getComputedStyle(S).zIndex)},[S]),m.jsx("div",{ref:_.setFloating,"data-radix-popper-content-wrapper":"",style:{...A,transform:T?A.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:W,"--radix-popper-transform-origin":[(G=k.transformOrigin)==null?void 0:G.x,(ee=k.transformOrigin)==null?void 0:ee.y].join(" "),...((te=k.hide)==null?void 0:te.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:m.jsx($d,{scope:n,placedSide:I,onArrowChange:w,arrowX:E,arrowY:j,shouldHideArrow:F,children:m.jsx(oe.div,{"data-side":I,"data-align":B,...p,ref:x,style:{...p.style,animation:T?void 0:"none"}})})})});Qs.displayName=Zr;var Js="PopperArrow",Ld={top:"bottom",right:"left",bottom:"top",left:"right"},ea=d.forwardRef(function(t,n){const{__scopePopper:r,...o}=t,s=Fd(Js,r),i=Ld[s.placedSide];return m.jsx("span",{ref:s.onArrowChange,style:{position:"absolute",left:s.arrowX,top:s.arrowY,[i]: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:m.jsx(jd,{...o,ref:n,style:{...o.style,display:"block"}})})});ea.displayName=Js;function Bd(e){return e!==null}var Yd=e=>({name:"transformOrigin",options:e,fn(t){var v,S,y;const{placement:n,rects:r,middlewareData:o}=t,i=((v=o.arrow)==null?void 0:v.centerOffset)!==0,a=i?0:e.arrowWidth,c=i?0:e.arrowHeight,[l,f]=ta(n),u={start:"0%",center:"50%",end:"100%"}[f],h=(((S=o.arrow)==null?void 0:S.x)??0)+a/2,g=(((y=o.arrow)==null?void 0:y.y)??0)+c/2;let b="",p="";return l==="bottom"?(b=i?u:`${h}px`,p=`${-c}px`):l==="top"?(b=i?u:`${h}px`,p=`${r.floating.height+c}px`):l==="right"?(b=`${-c}px`,p=i?u:`${g}px`):l==="left"&&(b=`${r.floating.width+c}px`,p=i?u:`${g}px`),{data:{x:b,y:p}}}});function ta(e){const[t,n="center"]=e.split("-");return[t,n]}var na=Vs,Qr=Zs,ra=Qs,oa=ea,zd="Portal",Fn=d.forwardRef((e,t)=>{var a;const{container:n,...r}=e,[o,s]=d.useState(!1);be(()=>s(!0),[]);const i=n||o&&((a=globalThis==null?void 0:globalThis.document)==null?void 0:a.body);return i?cs.createPortal(m.jsx(oe.div,{...r,ref:t}),i):null});Fn.displayName=zd;function Hd(e,t){return d.useReducer((n,r)=>t[n][r]??n,e)}var Wt=e=>{const{present:t,children:n}=e,r=qd(t),o=typeof n=="function"?n({present:r.isPresent}):d.Children.only(n),s=fe(r.ref,Ud(o));return typeof n=="function"||r.isPresent?d.cloneElement(o,{ref:s}):null};Wt.displayName="Presence";function qd(e){const[t,n]=d.useState(),r=d.useRef(null),o=d.useRef(e),s=d.useRef("none"),i=e?"mounted":"unmounted",[a,c]=Hd(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return d.useEffect(()=>{const l=un(r.current);s.current=a==="mounted"?l:"none"},[a]),be(()=>{const l=r.current,f=o.current;if(f!==e){const h=s.current,g=un(l);e?c("MOUNT"):g==="none"||(l==null?void 0:l.display)==="none"?c("UNMOUNT"):c(f&&h!==g?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,c]),be(()=>{if(t){let l;const f=t.ownerDocument.defaultView??window,u=g=>{const p=un(r.current).includes(g.animationName);if(g.target===t&&p&&(c("ANIMATION_END"),!o.current)){const v=t.style.animationFillMode;t.style.animationFillMode="forwards",l=f.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=v)})}},h=g=>{g.target===t&&(s.current=un(r.current))};return t.addEventListener("animationstart",h),t.addEventListener("animationcancel",u),t.addEventListener("animationend",u),()=>{f.clearTimeout(l),t.removeEventListener("animationstart",h),t.removeEventListener("animationcancel",u),t.removeEventListener("animationend",u)}}else c("ANIMATION_END")},[t,c]),{isPresent:["mounted","unmountSuspended"].includes(a),ref:d.useCallback(l=>{r.current=l?getComputedStyle(l):null,n(l)},[])}}function un(e){return(e==null?void 0:e.animationName)||"none"}function Ud(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Gd=d[" useInsertionEffect ".trim().toString()]||be;function Cn({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[o,s,i]=Kd({defaultProp:t,onChange:n}),a=e!==void 0,c=a?e:o;{const f=d.useRef(e!==void 0);d.useEffect(()=>{const u=f.current;u!==a&&console.warn(`${r} is changing from ${u?"controlled":"uncontrolled"} to ${a?"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.`),f.current=a},[a,r])}const l=d.useCallback(f=>{var u;if(a){const h=Vd(f)?f(e):f;h!==e&&((u=i.current)==null||u.call(i,h))}else s(f)},[a,e,s,i]);return[c,l]}function Kd({defaultProp:e,onChange:t}){const[n,r]=d.useState(e),o=d.useRef(n),s=d.useRef(t);return Gd(()=>{s.current=t},[t]),d.useEffect(()=>{var i;o.current!==n&&((i=s.current)==null||i.call(s,n),o.current=n)},[n,o]),[n,r,s]}function Vd(e){return typeof e=="function"}var Xd=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},xt=new WeakMap,dn=new WeakMap,fn={},ir=0,sa=function(e){return e&&(e.host||sa(e.parentNode))},Zd=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=sa(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},Qd=function(e,t,n,r){var o=Zd(t,Array.isArray(e)?e:[e]);fn[n]||(fn[n]=new WeakMap);var s=fn[n],i=[],a=new Set,c=new Set(o),l=function(u){!u||a.has(u)||(a.add(u),l(u.parentNode))};o.forEach(l);var f=function(u){!u||c.has(u)||Array.prototype.forEach.call(u.children,function(h){if(a.has(h))f(h);else try{var g=h.getAttribute(r),b=g!==null&&g!=="false",p=(xt.get(h)||0)+1,v=(s.get(h)||0)+1;xt.set(h,p),s.set(h,v),i.push(h),p===1&&b&&dn.set(h,!0),v===1&&h.setAttribute(n,"true"),b||h.setAttribute(r,"true")}catch(S){console.error("aria-hidden: cannot operate on ",h,S)}})};return f(t),a.clear(),ir++,function(){i.forEach(function(u){var h=xt.get(u)-1,g=s.get(u)-1;xt.set(u,h),s.set(u,g),h||(dn.has(u)||u.removeAttribute(r),dn.delete(u)),g||u.removeAttribute(n)}),ir--,ir||(xt=new WeakMap,xt=new WeakMap,dn=new WeakMap,fn={})}},Jr=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),o=Xd(e);return o?(r.push.apply(r,Array.from(o.querySelectorAll("[aria-live], script"))),Qd(r,o,n,"aria-hidden")):function(){return null}},je=function(){return je=Object.assign||function(t){for(var n,r=1,o=arguments.length;r<o;r++){n=arguments[r];for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(t[s]=n[s])}return t},je.apply(this,arguments)};function aa(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n}function Jd(e,t,n){if(n||arguments.length===2)for(var r=0,o=t.length,s;r<o;r++)(s||!(r in t))&&(s||(s=Array.prototype.slice.call(t,0,r)),s[r]=t[r]);return e.concat(s||Array.prototype.slice.call(t))}var gn="right-scroll-bar-position",vn="width-before-scroll-bar",ef="with-scroll-bars-hidden",tf="--removed-body-scroll-bar-size";function cr(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function nf(e,t){var n=N.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var o=n.value;o!==r&&(n.value=r,n.callback(r,o))}}}})[0];return n.callback=t,n.facade}var rf=typeof window<"u"?d.useLayoutEffect:d.useEffect,$o=new WeakMap;function of(e,t){var n=nf(null,function(r){return e.forEach(function(o){return cr(o,r)})});return rf(function(){var r=$o.get(n);if(r){var o=new Set(r),s=new Set(e),i=n.current;o.forEach(function(a){s.has(a)||cr(a,null)}),s.forEach(function(a){o.has(a)||cr(a,i)})}$o.set(n,e)},[e]),n}function sf(e){return e}function af(e,t){t===void 0&&(t=sf);var n=[],r=!1,o={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(s){var i=t(s,r);return n.push(i),function(){n=n.filter(function(a){return a!==i})}},assignSyncMedium:function(s){for(r=!0;n.length;){var i=n;n=[],i.forEach(s)}n={push:function(a){return s(a)},filter:function(){return n}}},assignMedium:function(s){r=!0;var i=[];if(n.length){var a=n;n=[],a.forEach(s),i=n}var c=function(){var f=i;i=[],f.forEach(s)},l=function(){return Promise.resolve().then(c)};l(),n={push:function(f){i.push(f),l()},filter:function(f){return i=i.filter(f),n}}}};return o}function cf(e){e===void 0&&(e={});var t=af(null);return t.options=je({async:!0,ssr:!1},e),t}var ia=function(e){var t=e.sideCar,n=aa(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return d.createElement(r,je({},n))};ia.isSideCarExport=!0;function lf(e,t){return e.useMedium(t),ia}var ca=cf(),lr=function(){},Ln=d.forwardRef(function(e,t){var n=d.useRef(null),r=d.useState({onScrollCapture:lr,onWheelCapture:lr,onTouchMoveCapture:lr}),o=r[0],s=r[1],i=e.forwardProps,a=e.children,c=e.className,l=e.removeScrollBar,f=e.enabled,u=e.shards,h=e.sideCar,g=e.noRelative,b=e.noIsolation,p=e.inert,v=e.allowPinchZoom,S=e.as,y=S===void 0?"div":S,x=e.gapMode,O=aa(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),w=h,M=of([n,t]),C=je(je({},O),o);return d.createElement(d.Fragment,null,f&&d.createElement(w,{sideCar:ca,removeScrollBar:l,shards:u,noRelative:g,noIsolation:b,inert:p,setCallbacks:s,allowPinchZoom:!!v,lockRef:n,gapMode:x}),i?d.cloneElement(d.Children.only(a),je(je({},C),{ref:M})):d.createElement(y,je({},C,{className:c,ref:M}),a))});Ln.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};Ln.classNames={fullWidth:vn,zeroRight:gn};var uf=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function df(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=uf();return t&&e.setAttribute("nonce",t),e}function ff(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function mf(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var hf=function(){var e=0,t=null;return{add:function(n){e==0&&(t=df())&&(ff(t,n),mf(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},pf=function(){var e=hf();return function(t,n){d.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},la=function(){var e=pf(),t=function(n){var r=n.styles,o=n.dynamic;return e(r,o),null};return t},gf={left:0,top:0,right:0,gap:0},ur=function(e){return parseInt(e||"",10)||0},vf=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],o=t[e==="padding"?"paddingRight":"marginRight"];return[ur(n),ur(r),ur(o)]},yf=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return gf;var t=vf(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},bf=la(),Ot="data-scroll-locked",wf=function(e,t,n,r){var o=e.left,s=e.top,i=e.right,a=e.gap;return n===void 0&&(n="margin"),`
102
- .`.concat(ef,` {
101
+ */const Up=[["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"}]],qp=Ie("User",Up);/**
102
+ * @license lucide-react v0.474.0 - ISC
103
+ *
104
+ * This source code is licensed under the ISC license.
105
+ * See the LICENSE file in the root directory of this source tree.
106
+ */const Vp=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],En=Ie("X",Vp);function Zo({label:e,placeholder:t="Enter password",helperText:n,error:r,required:o,className:a,showPassword:s=!1,onShowPasswordChange:i,value:l,onChange:u}){return f.jsxs("div",{className:q("space-y-1",a),children:[e&&f.jsxs(tn,{className:"text-sm font-medium text-gray-700",children:[e,o&&f.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),f.jsxs("div",{className:"relative",children:[f.jsx(Mn,{type:s?"text":"password",placeholder:t,className:q("pr-10",r&&"border-red-500 focus-visible:ring-red-500"),value:l,onChange:m=>u==null?void 0:u(m.target.value)}),f.jsx(Kt,{type:"button",variant:"ghost",size:"small",className:"absolute right-2 top-1/2 -translate-y-1/2",onClick:()=>i==null?void 0:i(!s),children:s?f.jsx(Ip,{className:"h-4 w-4 text-gray-400"}):f.jsx($p,{className:"h-4 w-4 text-gray-400"})})]}),r&&f.jsx("p",{className:"text-xs text-red-500",children:r}),n&&f.jsx("p",{className:"text-xs text-gray-500",children:n})]})}const Gi=d.forwardRef(({className:e,...t},n)=>f.jsx("textarea",{className:q("flex min-h-[80px] w-full rounded-md border border-input bg-background px-3 py-2 text-base ring-offset-background placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",e),ref:n,...t}));Gi.displayName="Textarea";function Ui({label:e,placeholder:t="Write here...",helperText:n,error:r,required:o,rows:a=4,className:s,onChange:i}){return f.jsxs("div",{className:q("space-y-1",s),children:[e&&f.jsxs(tn,{className:"text-sm font-medium text-gray-700",children:[e,o&&f.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),f.jsx(Gi,{placeholder:t,rows:a,className:q("resize-none",r&&"border-red-500 focus-visible:ring-red-500"),onChange:i}),(n||r)&&f.jsx("p",{className:q("text-xs",r?"text-red-500":"text-gray-500"),children:r||n})]})}function K(e,t,{checkForDefaultPrevented:n=!0}={}){return function(o){if(e==null||e(o),n===!1||!o.defaultPrevented)return t==null?void 0:t(o)}}function Kp(e,t){const n=d.createContext(t),r=a=>{const{children:s,...i}=a,l=d.useMemo(()=>i,Object.values(i));return f.jsx(n.Provider,{value:l,children:s})};r.displayName=e+"Provider";function o(a){const s=d.useContext(n);if(s)return s;if(t!==void 0)return t;throw new Error(`\`${a}\` must be used within \`${e}\``)}return[r,o]}function Ye(e,t=[]){let n=[];function r(a,s){const i=d.createContext(s),l=n.length;n=[...n,s];const u=c=>{var w;const{scope:p,children:h,...v}=c,g=((w=p==null?void 0:p[e])==null?void 0:w[l])||i,y=d.useMemo(()=>v,Object.values(v));return f.jsx(g.Provider,{value:y,children:h})};u.displayName=a+"Provider";function m(c,p){var g;const h=((g=p==null?void 0:p[e])==null?void 0:g[l])||i,v=d.useContext(h);if(v)return v;if(s!==void 0)return s;throw new Error(`\`${c}\` must be used within \`${a}\``)}return[u,m]}const o=()=>{const a=n.map(s=>d.createContext(s));return function(i){const l=(i==null?void 0:i[e])||a;return d.useMemo(()=>({[`__scope${e}`]:{...i,[e]:l}}),[i,l])}};return o.scopeName=e,[r,Xp(o,...t)]}function Xp(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(a){const s=r.reduce((i,{useScope:l,scopeName:u})=>{const c=l(a)[`__scope${u}`];return{...i,...c}},{});return d.useMemo(()=>({[`__scope${t.scopeName}`]:s}),[s])}};return n.scopeName=t.scopeName,n}function et(e){const t=d.useRef(e);return d.useEffect(()=>{t.current=e}),d.useMemo(()=>(...n)=>{var r;return(r=t.current)==null?void 0:r.call(t,...n)},[])}function Zp(e,t=globalThis==null?void 0:globalThis.document){const n=et(e);d.useEffect(()=>{const r=o=>{o.key==="Escape"&&n(o)};return t.addEventListener("keydown",r,{capture:!0}),()=>t.removeEventListener("keydown",r,{capture:!0})},[n,t])}var Qp="DismissableLayer",Qo="dismissableLayer.update",Jp="dismissableLayer.pointerDownOutside",eh="dismissableLayer.focusOutside",Ms,qi=d.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),kn=d.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:a,onInteractOutside:s,onDismiss:i,...l}=e,u=d.useContext(qi),[m,c]=d.useState(null),p=(m==null?void 0:m.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,h]=d.useState({}),v=he(t,M=>c(M)),g=Array.from(u.layers),[y]=[...u.layersWithOutsidePointerEventsDisabled].slice(-1),w=g.indexOf(y),x=m?g.indexOf(m):-1,S=u.layersWithOutsidePointerEventsDisabled.size>0,k=x>=w,C=rh(M=>{const D=M.target,L=[...u.branches].some(B=>B.contains(D));!k||L||(o==null||o(M),s==null||s(M),M.defaultPrevented||i==null||i())},p),N=oh(M=>{const D=M.target;[...u.branches].some(B=>B.contains(D))||(a==null||a(M),s==null||s(M),M.defaultPrevented||i==null||i())},p);return Zp(M=>{x===u.layers.size-1&&(r==null||r(M),!M.defaultPrevented&&i&&(M.preventDefault(),i()))},p),d.useEffect(()=>{if(m)return n&&(u.layersWithOutsidePointerEventsDisabled.size===0&&(Ms=p.body.style.pointerEvents,p.body.style.pointerEvents="none"),u.layersWithOutsidePointerEventsDisabled.add(m)),u.layers.add(m),Es(),()=>{n&&u.layersWithOutsidePointerEventsDisabled.size===1&&(p.body.style.pointerEvents=Ms)}},[m,p,n,u]),d.useEffect(()=>()=>{m&&(u.layers.delete(m),u.layersWithOutsidePointerEventsDisabled.delete(m),Es())},[m,u]),d.useEffect(()=>{const M=()=>h({});return document.addEventListener(Qo,M),()=>document.removeEventListener(Qo,M)},[]),f.jsx(te.div,{...l,ref:v,style:{pointerEvents:S?k?"auto":"none":void 0,...e.style},onFocusCapture:K(e.onFocusCapture,N.onFocusCapture),onBlurCapture:K(e.onBlurCapture,N.onBlurCapture),onPointerDownCapture:K(e.onPointerDownCapture,C.onPointerDownCapture)})});kn.displayName=Qp;var th="DismissableLayerBranch",nh=d.forwardRef((e,t)=>{const n=d.useContext(qi),r=d.useRef(null),o=he(t,r);return d.useEffect(()=>{const a=r.current;if(a)return n.branches.add(a),()=>{n.branches.delete(a)}},[n.branches]),f.jsx(te.div,{...e,ref:o})});nh.displayName=th;function rh(e,t=globalThis==null?void 0:globalThis.document){const n=et(e),r=d.useRef(!1),o=d.useRef(()=>{});return d.useEffect(()=>{const a=i=>{if(i.target&&!r.current){let l=function(){Vi(Jp,n,u,{discrete:!0})};const u={originalEvent:i};i.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=l,t.addEventListener("click",o.current,{once:!0})):l()}else t.removeEventListener("click",o.current);r.current=!1},s=window.setTimeout(()=>{t.addEventListener("pointerdown",a)},0);return()=>{window.clearTimeout(s),t.removeEventListener("pointerdown",a),t.removeEventListener("click",o.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function oh(e,t=globalThis==null?void 0:globalThis.document){const n=et(e),r=d.useRef(!1);return d.useEffect(()=>{const o=a=>{a.target&&!r.current&&Vi(eh,n,{originalEvent:a},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function Es(){const e=new CustomEvent(Qo);document.dispatchEvent(e)}function Vi(e,t,n,{discrete:r}){const o=n.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?$i(o,a):o.dispatchEvent(a)}var Mo=0;function Kr(){d.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??ks()),document.body.insertAdjacentElement("beforeend",e[1]??ks()),Mo++,()=>{Mo===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),Mo--}},[])}function ks(){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}var Eo="focusScope.autoFocusOnMount",ko="focusScope.autoFocusOnUnmount",Ns={bubbles:!1,cancelable:!0},ah="FocusScope",er=d.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:o,onUnmountAutoFocus:a,...s}=e,[i,l]=d.useState(null),u=et(o),m=et(a),c=d.useRef(null),p=he(t,g=>l(g)),h=d.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;d.useEffect(()=>{if(r){let g=function(S){if(h.paused||!i)return;const k=S.target;i.contains(k)?c.current=k:Ot(c.current,{select:!0})},y=function(S){if(h.paused||!i)return;const k=S.relatedTarget;k!==null&&(i.contains(k)||Ot(c.current,{select:!0}))},w=function(S){if(document.activeElement===document.body)for(const C of S)C.removedNodes.length>0&&Ot(i)};document.addEventListener("focusin",g),document.addEventListener("focusout",y);const x=new MutationObserver(w);return i&&x.observe(i,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",g),document.removeEventListener("focusout",y),x.disconnect()}}},[r,i,h.paused]),d.useEffect(()=>{if(i){Rs.add(h);const g=document.activeElement;if(!i.contains(g)){const w=new CustomEvent(Eo,Ns);i.addEventListener(Eo,u),i.dispatchEvent(w),w.defaultPrevented||(sh(dh(Ki(i)),{select:!0}),document.activeElement===g&&Ot(i))}return()=>{i.removeEventListener(Eo,u),setTimeout(()=>{const w=new CustomEvent(ko,Ns);i.addEventListener(ko,m),i.dispatchEvent(w),w.defaultPrevented||Ot(g??document.body,{select:!0}),i.removeEventListener(ko,m),Rs.remove(h)},0)}}},[i,u,m,h]);const v=d.useCallback(g=>{if(!n&&!r||h.paused)return;const y=g.key==="Tab"&&!g.altKey&&!g.ctrlKey&&!g.metaKey,w=document.activeElement;if(y&&w){const x=g.currentTarget,[S,k]=ih(x);S&&k?!g.shiftKey&&w===k?(g.preventDefault(),n&&Ot(S,{select:!0})):g.shiftKey&&w===S&&(g.preventDefault(),n&&Ot(k,{select:!0})):w===x&&g.preventDefault()}},[n,r,h.paused]);return f.jsx(te.div,{tabIndex:-1,...s,ref:p,onKeyDown:v})});er.displayName=ah;function sh(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(Ot(r,{select:t}),document.activeElement!==n)return}function ih(e){const t=Ki(e),n=Ds(t,e),r=Ds(t.reverse(),e);return[n,r]}function Ki(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function Ds(e,t){for(const n of e)if(!ch(n,{upTo:t}))return n}function ch(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 lh(e){return e instanceof HTMLInputElement&&"select"in e}function Ot(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&lh(e)&&t&&e.select()}}var Rs=uh();function uh(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=Ts(e,t),e.unshift(t)},remove(t){var n;e=Ts(e,t),(n=e[0])==null||n.resume()}}}function Ts(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function dh(e){return e.filter(t=>t.tagName!=="A")}var De=globalThis!=null&&globalThis.document?d.useLayoutEffect:()=>{},fh=d[" useId ".trim().toString()]||(()=>{}),mh=0;function ke(e){const[t,n]=d.useState(fh());return De(()=>{n(r=>r??String(mh++))},[e]),e||(t?`radix-${t}`:"")}const ph=["top","right","bottom","left"],At=Math.min,Xe=Math.max,Ir=Math.round,br=Math.floor,ht=e=>({x:e,y:e}),hh={left:"right",right:"left",bottom:"top",top:"bottom"},gh={start:"end",end:"start"};function Jo(e,t,n){return Xe(e,At(t,n))}function Mt(e,t){return typeof e=="function"?e(t):e}function Et(e){return e.split("-")[0]}function Nn(e){return e.split("-")[1]}function Ma(e){return e==="x"?"y":"x"}function Ea(e){return e==="y"?"height":"width"}const vh=new Set(["top","bottom"]);function mt(e){return vh.has(Et(e))?"y":"x"}function ka(e){return Ma(mt(e))}function yh(e,t,n){n===void 0&&(n=!1);const r=Nn(e),o=ka(e),a=Ea(o);let s=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[a]>t.floating[a]&&(s=jr(s)),[s,jr(s)]}function bh(e){const t=jr(e);return[ea(e),t,ea(t)]}function ea(e){return e.replace(/start|end/g,t=>gh[t])}const Os=["left","right"],_s=["right","left"],wh=["top","bottom"],xh=["bottom","top"];function Sh(e,t,n){switch(e){case"top":case"bottom":return n?t?_s:Os:t?Os:_s;case"left":case"right":return t?wh:xh;default:return[]}}function Ch(e,t,n,r){const o=Nn(e);let a=Sh(Et(e),n==="start",r);return o&&(a=a.map(s=>s+"-"+o),t&&(a=a.concat(a.map(ea)))),a}function jr(e){return e.replace(/left|right|bottom|top/g,t=>hh[t])}function Mh(e){return{top:0,right:0,bottom:0,left:0,...e}}function Xi(e){return typeof e!="number"?Mh(e):{top:e,right:e,bottom:e,left:e}}function $r(e){const{x:t,y:n,width:r,height:o}=e;return{width:r,height:o,top:n,left:t,right:t+r,bottom:n+o,x:t,y:n}}function Ps(e,t,n){let{reference:r,floating:o}=e;const a=mt(t),s=ka(t),i=Ea(s),l=Et(t),u=a==="y",m=r.x+r.width/2-o.width/2,c=r.y+r.height/2-o.height/2,p=r[i]/2-o[i]/2;let h;switch(l){case"top":h={x:m,y:r.y-o.height};break;case"bottom":h={x:m,y:r.y+r.height};break;case"right":h={x:r.x+r.width,y:c};break;case"left":h={x:r.x-o.width,y:c};break;default:h={x:r.x,y:r.y}}switch(Nn(t)){case"start":h[s]-=p*(n&&u?-1:1);break;case"end":h[s]+=p*(n&&u?-1:1);break}return h}const Eh=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:a=[],platform:s}=n,i=a.filter(Boolean),l=await(s.isRTL==null?void 0:s.isRTL(t));let u=await s.getElementRects({reference:e,floating:t,strategy:o}),{x:m,y:c}=Ps(u,r,l),p=r,h={},v=0;for(let g=0;g<i.length;g++){const{name:y,fn:w}=i[g],{x,y:S,data:k,reset:C}=await w({x:m,y:c,initialPlacement:r,placement:p,strategy:o,middlewareData:h,rects:u,platform:s,elements:{reference:e,floating:t}});m=x??m,c=S??c,h={...h,[y]:{...h[y],...k}},C&&v<=50&&(v++,typeof C=="object"&&(C.placement&&(p=C.placement),C.rects&&(u=C.rects===!0?await s.getElementRects({reference:e,floating:t,strategy:o}):C.rects),{x:m,y:c}=Ps(u,p,l)),g=-1)}return{x:m,y:c,placement:p,strategy:o,middlewareData:h}};async function Un(e,t){var n;t===void 0&&(t={});const{x:r,y:o,platform:a,rects:s,elements:i,strategy:l}=e,{boundary:u="clippingAncestors",rootBoundary:m="viewport",elementContext:c="floating",altBoundary:p=!1,padding:h=0}=Mt(t,e),v=Xi(h),y=i[p?c==="floating"?"reference":"floating":c],w=$r(await a.getClippingRect({element:(n=await(a.isElement==null?void 0:a.isElement(y)))==null||n?y:y.contextElement||await(a.getDocumentElement==null?void 0:a.getDocumentElement(i.floating)),boundary:u,rootBoundary:m,strategy:l})),x=c==="floating"?{x:r,y:o,width:s.floating.width,height:s.floating.height}:s.reference,S=await(a.getOffsetParent==null?void 0:a.getOffsetParent(i.floating)),k=await(a.isElement==null?void 0:a.isElement(S))?await(a.getScale==null?void 0:a.getScale(S))||{x:1,y:1}:{x:1,y:1},C=$r(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:i,rect:x,offsetParent:S,strategy:l}):x);return{top:(w.top-C.top+v.top)/k.y,bottom:(C.bottom-w.bottom+v.bottom)/k.y,left:(w.left-C.left+v.left)/k.x,right:(C.right-w.right+v.right)/k.x}}const kh=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:o,rects:a,platform:s,elements:i,middlewareData:l}=t,{element:u,padding:m=0}=Mt(e,t)||{};if(u==null)return{};const c=Xi(m),p={x:n,y:r},h=ka(o),v=Ea(h),g=await s.getDimensions(u),y=h==="y",w=y?"top":"left",x=y?"bottom":"right",S=y?"clientHeight":"clientWidth",k=a.reference[v]+a.reference[h]-p[h]-a.floating[v],C=p[h]-a.reference[h],N=await(s.getOffsetParent==null?void 0:s.getOffsetParent(u));let M=N?N[S]:0;(!M||!await(s.isElement==null?void 0:s.isElement(N)))&&(M=i.floating[S]||a.floating[v]);const D=k/2-C/2,L=M/2-g[v]/2-1,B=At(c[w],L),F=At(c[x],L),V=B,$=M-g[v]-F,I=M/2-g[v]/2+D,_=Jo(V,I,$),R=!l.arrow&&Nn(o)!=null&&I!==_&&a.reference[v]/2-(I<V?B:F)-g[v]/2<0,P=R?I<V?I-V:I-$:0;return{[h]:p[h]+P,data:{[h]:_,centerOffset:I-_-P,...R&&{alignmentOffset:P}},reset:R}}}),Nh=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:o,middlewareData:a,rects:s,initialPlacement:i,platform:l,elements:u}=t,{mainAxis:m=!0,crossAxis:c=!0,fallbackPlacements:p,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:v="none",flipAlignment:g=!0,...y}=Mt(e,t);if((n=a.arrow)!=null&&n.alignmentOffset)return{};const w=Et(o),x=mt(i),S=Et(i)===i,k=await(l.isRTL==null?void 0:l.isRTL(u.floating)),C=p||(S||!g?[jr(i)]:bh(i)),N=v!=="none";!p&&N&&C.push(...Ch(i,g,v,k));const M=[i,...C],D=await Un(t,y),L=[];let B=((r=a.flip)==null?void 0:r.overflows)||[];if(m&&L.push(D[w]),c){const I=yh(o,s,k);L.push(D[I[0]],D[I[1]])}if(B=[...B,{placement:o,overflows:L}],!L.every(I=>I<=0)){var F,V;const I=(((F=a.flip)==null?void 0:F.index)||0)+1,_=M[I];if(_&&(!(c==="alignment"?x!==mt(_):!1)||B.every(E=>E.overflows[0]>0&&mt(E.placement)===x)))return{data:{index:I,overflows:B},reset:{placement:_}};let R=(V=B.filter(P=>P.overflows[0]<=0).sort((P,E)=>P.overflows[1]-E.overflows[1])[0])==null?void 0:V.placement;if(!R)switch(h){case"bestFit":{var $;const P=($=B.filter(E=>{if(N){const O=mt(E.placement);return O===x||O==="y"}return!0}).map(E=>[E.placement,E.overflows.filter(O=>O>0).reduce((O,Y)=>O+Y,0)]).sort((E,O)=>E[1]-O[1])[0])==null?void 0:$[0];P&&(R=P);break}case"initialPlacement":R=i;break}if(o!==R)return{reset:{placement:R}}}return{}}}};function As(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Is(e){return ph.some(t=>e[t]>=0)}const Dh=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...o}=Mt(e,t);switch(r){case"referenceHidden":{const a=await Un(t,{...o,elementContext:"reference"}),s=As(a,n.reference);return{data:{referenceHiddenOffsets:s,referenceHidden:Is(s)}}}case"escaped":{const a=await Un(t,{...o,altBoundary:!0}),s=As(a,n.floating);return{data:{escapedOffsets:s,escaped:Is(s)}}}default:return{}}}}},Zi=new Set(["left","top"]);async function Rh(e,t){const{placement:n,platform:r,elements:o}=e,a=await(r.isRTL==null?void 0:r.isRTL(o.floating)),s=Et(n),i=Nn(n),l=mt(n)==="y",u=Zi.has(s)?-1:1,m=a&&l?-1:1,c=Mt(t,e);let{mainAxis:p,crossAxis:h,alignmentAxis:v}=typeof c=="number"?{mainAxis:c,crossAxis:0,alignmentAxis:null}:{mainAxis:c.mainAxis||0,crossAxis:c.crossAxis||0,alignmentAxis:c.alignmentAxis};return i&&typeof v=="number"&&(h=i==="end"?v*-1:v),l?{x:h*m,y:p*u}:{x:p*u,y:h*m}}const Th=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:o,y:a,placement:s,middlewareData:i}=t,l=await Rh(t,e);return s===((n=i.offset)==null?void 0:n.placement)&&(r=i.arrow)!=null&&r.alignmentOffset?{}:{x:o+l.x,y:a+l.y,data:{...l,placement:s}}}}},Oh=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:a=!0,crossAxis:s=!1,limiter:i={fn:y=>{let{x:w,y:x}=y;return{x:w,y:x}}},...l}=Mt(e,t),u={x:n,y:r},m=await Un(t,l),c=mt(Et(o)),p=Ma(c);let h=u[p],v=u[c];if(a){const y=p==="y"?"top":"left",w=p==="y"?"bottom":"right",x=h+m[y],S=h-m[w];h=Jo(x,h,S)}if(s){const y=c==="y"?"top":"left",w=c==="y"?"bottom":"right",x=v+m[y],S=v-m[w];v=Jo(x,v,S)}const g=i.fn({...t,[p]:h,[c]:v});return{...g,data:{x:g.x-n,y:g.y-r,enabled:{[p]:a,[c]:s}}}}}},_h=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:a,middlewareData:s}=t,{offset:i=0,mainAxis:l=!0,crossAxis:u=!0}=Mt(e,t),m={x:n,y:r},c=mt(o),p=Ma(c);let h=m[p],v=m[c];const g=Mt(i,t),y=typeof g=="number"?{mainAxis:g,crossAxis:0}:{mainAxis:0,crossAxis:0,...g};if(l){const S=p==="y"?"height":"width",k=a.reference[p]-a.floating[S]+y.mainAxis,C=a.reference[p]+a.reference[S]-y.mainAxis;h<k?h=k:h>C&&(h=C)}if(u){var w,x;const S=p==="y"?"width":"height",k=Zi.has(Et(o)),C=a.reference[c]-a.floating[S]+(k&&((w=s.offset)==null?void 0:w[c])||0)+(k?0:y.crossAxis),N=a.reference[c]+a.reference[S]+(k?0:((x=s.offset)==null?void 0:x[c])||0)-(k?y.crossAxis:0);v<C?v=C:v>N&&(v=N)}return{[p]:h,[c]:v}}}},Ph=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:o,rects:a,platform:s,elements:i}=t,{apply:l=()=>{},...u}=Mt(e,t),m=await Un(t,u),c=Et(o),p=Nn(o),h=mt(o)==="y",{width:v,height:g}=a.floating;let y,w;c==="top"||c==="bottom"?(y=c,w=p===(await(s.isRTL==null?void 0:s.isRTL(i.floating))?"start":"end")?"left":"right"):(w=c,y=p==="end"?"top":"bottom");const x=g-m.top-m.bottom,S=v-m.left-m.right,k=At(g-m[y],x),C=At(v-m[w],S),N=!t.middlewareData.shift;let M=k,D=C;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(D=S),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(M=x),N&&!p){const B=Xe(m.left,0),F=Xe(m.right,0),V=Xe(m.top,0),$=Xe(m.bottom,0);h?D=v-2*(B!==0||F!==0?B+F:Xe(m.left,m.right)):M=g-2*(V!==0||$!==0?V+$:Xe(m.top,m.bottom))}await l({...t,availableWidth:D,availableHeight:M});const L=await s.getDimensions(i.floating);return v!==L.width||g!==L.height?{reset:{rects:!0}}:{}}}};function Xr(){return typeof window<"u"}function Dn(e){return Qi(e)?(e.nodeName||"").toLowerCase():"#document"}function Ze(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function vt(e){var t;return(t=(Qi(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Qi(e){return Xr()?e instanceof Node||e instanceof Ze(e).Node:!1}function st(e){return Xr()?e instanceof Element||e instanceof Ze(e).Element:!1}function gt(e){return Xr()?e instanceof HTMLElement||e instanceof Ze(e).HTMLElement:!1}function js(e){return!Xr()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof Ze(e).ShadowRoot}const Ah=new Set(["inline","contents"]);function tr(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=it(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!Ah.has(o)}const Ih=new Set(["table","td","th"]);function jh(e){return Ih.has(Dn(e))}const $h=[":popover-open",":modal"];function Zr(e){return $h.some(t=>{try{return e.matches(t)}catch{return!1}})}const Lh=["transform","translate","scale","rotate","perspective"],Fh=["transform","translate","scale","rotate","perspective","filter"],Wh=["paint","layout","strict","content"];function Na(e){const t=Da(),n=st(e)?it(e):e;return Lh.some(r=>n[r]?n[r]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||Fh.some(r=>(n.willChange||"").includes(r))||Wh.some(r=>(n.contain||"").includes(r))}function Bh(e){let t=It(e);for(;gt(t)&&!vn(t);){if(Na(t))return t;if(Zr(t))return null;t=It(t)}return null}function Da(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const Yh=new Set(["html","body","#document"]);function vn(e){return Yh.has(Dn(e))}function it(e){return Ze(e).getComputedStyle(e)}function Qr(e){return st(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function It(e){if(Dn(e)==="html")return e;const t=e.assignedSlot||e.parentNode||js(e)&&e.host||vt(e);return js(t)?t.host:t}function Ji(e){const t=It(e);return vn(t)?e.ownerDocument?e.ownerDocument.body:e.body:gt(t)&&tr(t)?t:Ji(t)}function qn(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=Ji(e),a=o===((r=e.ownerDocument)==null?void 0:r.body),s=Ze(o);if(a){const i=ta(s);return t.concat(s,s.visualViewport||[],tr(o)?o:[],i&&n?qn(i):[])}return t.concat(o,qn(o,[],n))}function ta(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function ec(e){const t=it(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=gt(e),a=o?e.offsetWidth:n,s=o?e.offsetHeight:r,i=Ir(n)!==a||Ir(r)!==s;return i&&(n=a,r=s),{width:n,height:r,$:i}}function Ra(e){return st(e)?e:e.contextElement}function hn(e){const t=Ra(e);if(!gt(t))return ht(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:a}=ec(t);let s=(a?Ir(n.width):n.width)/r,i=(a?Ir(n.height):n.height)/o;return(!s||!Number.isFinite(s))&&(s=1),(!i||!Number.isFinite(i))&&(i=1),{x:s,y:i}}const Hh=ht(0);function tc(e){const t=Ze(e);return!Da()||!t.visualViewport?Hh:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function zh(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==Ze(e)?!1:t}function Xt(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),a=Ra(e);let s=ht(1);t&&(r?st(r)&&(s=hn(r)):s=hn(e));const i=zh(a,n,r)?tc(a):ht(0);let l=(o.left+i.x)/s.x,u=(o.top+i.y)/s.y,m=o.width/s.x,c=o.height/s.y;if(a){const p=Ze(a),h=r&&st(r)?Ze(r):r;let v=p,g=ta(v);for(;g&&r&&h!==v;){const y=hn(g),w=g.getBoundingClientRect(),x=it(g),S=w.left+(g.clientLeft+parseFloat(x.paddingLeft))*y.x,k=w.top+(g.clientTop+parseFloat(x.paddingTop))*y.y;l*=y.x,u*=y.y,m*=y.x,c*=y.y,l+=S,u+=k,v=Ze(g),g=ta(v)}}return $r({width:m,height:c,x:l,y:u})}function Ta(e,t){const n=Qr(e).scrollLeft;return t?t.left+n:Xt(vt(e)).left+n}function nc(e,t,n){n===void 0&&(n=!1);const r=e.getBoundingClientRect(),o=r.left+t.scrollLeft-(n?0:Ta(e,r)),a=r.top+t.scrollTop;return{x:o,y:a}}function Gh(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const a=o==="fixed",s=vt(r),i=t?Zr(t.floating):!1;if(r===s||i&&a)return n;let l={scrollLeft:0,scrollTop:0},u=ht(1);const m=ht(0),c=gt(r);if((c||!c&&!a)&&((Dn(r)!=="body"||tr(s))&&(l=Qr(r)),gt(r))){const h=Xt(r);u=hn(r),m.x=h.x+r.clientLeft,m.y=h.y+r.clientTop}const p=s&&!c&&!a?nc(s,l,!0):ht(0);return{width:n.width*u.x,height:n.height*u.y,x:n.x*u.x-l.scrollLeft*u.x+m.x+p.x,y:n.y*u.y-l.scrollTop*u.y+m.y+p.y}}function Uh(e){return Array.from(e.getClientRects())}function qh(e){const t=vt(e),n=Qr(e),r=e.ownerDocument.body,o=Xe(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=Xe(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let s=-n.scrollLeft+Ta(e);const i=-n.scrollTop;return it(r).direction==="rtl"&&(s+=Xe(t.clientWidth,r.clientWidth)-o),{width:o,height:a,x:s,y:i}}function Vh(e,t){const n=Ze(e),r=vt(e),o=n.visualViewport;let a=r.clientWidth,s=r.clientHeight,i=0,l=0;if(o){a=o.width,s=o.height;const u=Da();(!u||u&&t==="fixed")&&(i=o.offsetLeft,l=o.offsetTop)}return{width:a,height:s,x:i,y:l}}const Kh=new Set(["absolute","fixed"]);function Xh(e,t){const n=Xt(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,a=gt(e)?hn(e):ht(1),s=e.clientWidth*a.x,i=e.clientHeight*a.y,l=o*a.x,u=r*a.y;return{width:s,height:i,x:l,y:u}}function $s(e,t,n){let r;if(t==="viewport")r=Vh(e,n);else if(t==="document")r=qh(vt(e));else if(st(t))r=Xh(t,n);else{const o=tc(e);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return $r(r)}function rc(e,t){const n=It(e);return n===t||!st(n)||vn(n)?!1:it(n).position==="fixed"||rc(n,t)}function Zh(e,t){const n=t.get(e);if(n)return n;let r=qn(e,[],!1).filter(i=>st(i)&&Dn(i)!=="body"),o=null;const a=it(e).position==="fixed";let s=a?It(e):e;for(;st(s)&&!vn(s);){const i=it(s),l=Na(s);!l&&i.position==="fixed"&&(o=null),(a?!l&&!o:!l&&i.position==="static"&&!!o&&Kh.has(o.position)||tr(s)&&!l&&rc(e,s))?r=r.filter(m=>m!==s):o=i,s=It(s)}return t.set(e,r),r}function Qh(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const s=[...n==="clippingAncestors"?Zr(t)?[]:Zh(t,this._c):[].concat(n),r],i=s[0],l=s.reduce((u,m)=>{const c=$s(t,m,o);return u.top=Xe(c.top,u.top),u.right=At(c.right,u.right),u.bottom=At(c.bottom,u.bottom),u.left=Xe(c.left,u.left),u},$s(t,i,o));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function Jh(e){const{width:t,height:n}=ec(e);return{width:t,height:n}}function eg(e,t,n){const r=gt(t),o=vt(t),a=n==="fixed",s=Xt(e,!0,a,t);let i={scrollLeft:0,scrollTop:0};const l=ht(0);function u(){l.x=Ta(o)}if(r||!r&&!a)if((Dn(t)!=="body"||tr(o))&&(i=Qr(t)),r){const h=Xt(t,!0,a,t);l.x=h.x+t.clientLeft,l.y=h.y+t.clientTop}else o&&u();a&&!r&&o&&u();const m=o&&!r&&!a?nc(o,i):ht(0),c=s.left+i.scrollLeft-l.x-m.x,p=s.top+i.scrollTop-l.y-m.y;return{x:c,y:p,width:s.width,height:s.height}}function No(e){return it(e).position==="static"}function Ls(e,t){if(!gt(e)||it(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return vt(e)===n&&(n=n.ownerDocument.body),n}function oc(e,t){const n=Ze(e);if(Zr(e))return n;if(!gt(e)){let o=It(e);for(;o&&!vn(o);){if(st(o)&&!No(o))return o;o=It(o)}return n}let r=Ls(e,t);for(;r&&jh(r)&&No(r);)r=Ls(r,t);return r&&vn(r)&&No(r)&&!Na(r)?n:r||Bh(e)||n}const tg=async function(e){const t=this.getOffsetParent||oc,n=this.getDimensions,r=await n(e.floating);return{reference:eg(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function ng(e){return it(e).direction==="rtl"}const rg={convertOffsetParentRelativeRectToViewportRelativeRect:Gh,getDocumentElement:vt,getClippingRect:Qh,getOffsetParent:oc,getElementRects:tg,getClientRects:Uh,getDimensions:Jh,getScale:hn,isElement:st,isRTL:ng};function ac(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function og(e,t){let n=null,r;const o=vt(e);function a(){var i;clearTimeout(r),(i=n)==null||i.disconnect(),n=null}function s(i,l){i===void 0&&(i=!1),l===void 0&&(l=1),a();const u=e.getBoundingClientRect(),{left:m,top:c,width:p,height:h}=u;if(i||t(),!p||!h)return;const v=br(c),g=br(o.clientWidth-(m+p)),y=br(o.clientHeight-(c+h)),w=br(m),S={rootMargin:-v+"px "+-g+"px "+-y+"px "+-w+"px",threshold:Xe(0,At(1,l))||1};let k=!0;function C(N){const M=N[0].intersectionRatio;if(M!==l){if(!k)return s();M?s(!1,M):r=setTimeout(()=>{s(!1,1e-7)},1e3)}M===1&&!ac(u,e.getBoundingClientRect())&&s(),k=!1}try{n=new IntersectionObserver(C,{...S,root:o.ownerDocument})}catch{n=new IntersectionObserver(C,S)}n.observe(e)}return s(!0),a}function ag(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:a=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:i=typeof IntersectionObserver=="function",animationFrame:l=!1}=r,u=Ra(e),m=o||a?[...u?qn(u):[],...qn(t)]:[];m.forEach(w=>{o&&w.addEventListener("scroll",n,{passive:!0}),a&&w.addEventListener("resize",n)});const c=u&&i?og(u,n):null;let p=-1,h=null;s&&(h=new ResizeObserver(w=>{let[x]=w;x&&x.target===u&&h&&(h.unobserve(t),cancelAnimationFrame(p),p=requestAnimationFrame(()=>{var S;(S=h)==null||S.observe(t)})),n()}),u&&!l&&h.observe(u),h.observe(t));let v,g=l?Xt(e):null;l&&y();function y(){const w=Xt(e);g&&!ac(g,w)&&n(),g=w,v=requestAnimationFrame(y)}return n(),()=>{var w;m.forEach(x=>{o&&x.removeEventListener("scroll",n),a&&x.removeEventListener("resize",n)}),c==null||c(),(w=h)==null||w.disconnect(),h=null,l&&cancelAnimationFrame(v)}}const sg=Th,ig=Oh,cg=Nh,lg=Ph,ug=Dh,Fs=kh,dg=_h,fg=(e,t,n)=>{const r=new Map,o={platform:rg,...n},a={...o.platform,_c:r};return Eh(e,t,{...o,platform:a})};var mg=typeof document<"u",pg=function(){},Rr=mg?b.useLayoutEffect:pg;function Lr(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!Lr(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,o[r]))return!1;for(r=n;r--!==0;){const a=o[r];if(!(a==="_owner"&&e.$$typeof)&&!Lr(e[a],t[a]))return!1}return!0}return e!==e&&t!==t}function sc(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Ws(e,t){const n=sc(e);return Math.round(t*n)/n}function Do(e){const t=d.useRef(e);return Rr(()=>{t.current=e}),t}function hg(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:a,floating:s}={},transform:i=!0,whileElementsMounted:l,open:u}=e,[m,c]=d.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[p,h]=d.useState(r);Lr(p,r)||h(r);const[v,g]=d.useState(null),[y,w]=d.useState(null),x=d.useCallback(E=>{E!==N.current&&(N.current=E,g(E))},[]),S=d.useCallback(E=>{E!==M.current&&(M.current=E,w(E))},[]),k=a||v,C=s||y,N=d.useRef(null),M=d.useRef(null),D=d.useRef(m),L=l!=null,B=Do(l),F=Do(o),V=Do(u),$=d.useCallback(()=>{if(!N.current||!M.current)return;const E={placement:t,strategy:n,middleware:p};F.current&&(E.platform=F.current),fg(N.current,M.current,E).then(O=>{const Y={...O,isPositioned:V.current!==!1};I.current&&!Lr(D.current,Y)&&(D.current=Y,qr.flushSync(()=>{c(Y)}))})},[p,t,n,F,V]);Rr(()=>{u===!1&&D.current.isPositioned&&(D.current.isPositioned=!1,c(E=>({...E,isPositioned:!1})))},[u]);const I=d.useRef(!1);Rr(()=>(I.current=!0,()=>{I.current=!1}),[]),Rr(()=>{if(k&&(N.current=k),C&&(M.current=C),k&&C){if(B.current)return B.current(k,C,$);$()}},[k,C,$,B,L]);const _=d.useMemo(()=>({reference:N,floating:M,setReference:x,setFloating:S}),[x,S]),R=d.useMemo(()=>({reference:k,floating:C}),[k,C]),P=d.useMemo(()=>{const E={position:n,left:0,top:0};if(!R.floating)return E;const O=Ws(R.floating,m.x),Y=Ws(R.floating,m.y);return i?{...E,transform:"translate("+O+"px, "+Y+"px)",...sc(R.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:O,top:Y}},[n,i,R.floating,m.x,m.y]);return d.useMemo(()=>({...m,update:$,refs:_,elements:R,floatingStyles:P}),[m,$,_,R,P])}const gg=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:o}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?Fs({element:r.current,padding:o}).fn(n):{}:r?Fs({element:r,padding:o}).fn(n):{}}}},vg=(e,t)=>({...sg(e),options:[e,t]}),yg=(e,t)=>({...ig(e),options:[e,t]}),bg=(e,t)=>({...dg(e),options:[e,t]}),wg=(e,t)=>({...cg(e),options:[e,t]}),xg=(e,t)=>({...lg(e),options:[e,t]}),Sg=(e,t)=>({...ug(e),options:[e,t]}),Cg=(e,t)=>({...gg(e),options:[e,t]});var Mg="Arrow",ic=d.forwardRef((e,t)=>{const{children:n,width:r=10,height:o=5,...a}=e;return f.jsx(te.svg,{...a,ref:t,width:r,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:f.jsx("polygon",{points:"0,0 30,0 15,10"})})});ic.displayName=Mg;var Eg=ic;function Oa(e){const[t,n]=d.useState(void 0);return De(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(o=>{if(!Array.isArray(o)||!o.length)return;const a=o[0];let s,i;if("borderBoxSize"in a){const l=a.borderBoxSize,u=Array.isArray(l)?l[0]:l;s=u.inlineSize,i=u.blockSize}else s=e.offsetWidth,i=e.offsetHeight;n({width:s,height:i})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}var _a="Popper",[cc,$t]=Ye(_a),[kg,lc]=cc(_a),uc=e=>{const{__scopePopper:t,children:n}=e,[r,o]=d.useState(null);return f.jsx(kg,{scope:t,anchor:r,onAnchorChange:o,children:n})};uc.displayName=_a;var dc="PopperAnchor",fc=d.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...o}=e,a=lc(dc,n),s=d.useRef(null),i=he(t,s);return d.useEffect(()=>{a.onAnchorChange((r==null?void 0:r.current)||s.current)}),r?null:f.jsx(te.div,{...o,ref:i})});fc.displayName=dc;var Pa="PopperContent",[Ng,Dg]=cc(Pa),mc=d.forwardRef((e,t)=>{var j,Z,X,Q,le,de;const{__scopePopper:n,side:r="bottom",sideOffset:o=0,align:a="center",alignOffset:s=0,arrowPadding:i=0,avoidCollisions:l=!0,collisionBoundary:u=[],collisionPadding:m=0,sticky:c="partial",hideWhenDetached:p=!1,updatePositionStrategy:h="optimized",onPlaced:v,...g}=e,y=lc(Pa,n),[w,x]=d.useState(null),S=he(t,xe=>x(xe)),[k,C]=d.useState(null),N=Oa(k),M=(N==null?void 0:N.width)??0,D=(N==null?void 0:N.height)??0,L=r+(a!=="center"?"-"+a:""),B=typeof m=="number"?m:{top:0,right:0,bottom:0,left:0,...m},F=Array.isArray(u)?u:[u],V=F.length>0,$={padding:B,boundary:F.filter(Tg),altBoundary:V},{refs:I,floatingStyles:_,placement:R,isPositioned:P,middlewareData:E}=hg({strategy:"fixed",placement:L,whileElementsMounted:(...xe)=>ag(...xe,{animationFrame:h==="always"}),elements:{reference:y.anchor},middleware:[vg({mainAxis:o+D,alignmentAxis:s}),l&&yg({mainAxis:!0,crossAxis:!1,limiter:c==="partial"?bg():void 0,...$}),l&&wg({...$}),xg({...$,apply:({elements:xe,rects:re,availableWidth:ze,availableHeight:We})=>{const{width:ie,height:pe}=re.reference,Se=xe.floating.style;Se.setProperty("--radix-popper-available-width",`${ze}px`),Se.setProperty("--radix-popper-available-height",`${We}px`),Se.setProperty("--radix-popper-anchor-width",`${ie}px`),Se.setProperty("--radix-popper-anchor-height",`${pe}px`)}}),k&&Cg({element:k,padding:i}),Og({arrowWidth:M,arrowHeight:D}),p&&Sg({strategy:"referenceHidden",...$})]}),[O,Y]=gc(R),G=et(v);De(()=>{P&&(G==null||G())},[P,G]);const T=(j=E.arrow)==null?void 0:j.x,A=(Z=E.arrow)==null?void 0:Z.y,W=((X=E.arrow)==null?void 0:X.centerOffset)!==0,[H,U]=d.useState();return De(()=>{w&&U(window.getComputedStyle(w).zIndex)},[w]),f.jsx("div",{ref:I.setFloating,"data-radix-popper-content-wrapper":"",style:{..._,transform:P?_.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:H,"--radix-popper-transform-origin":[(Q=E.transformOrigin)==null?void 0:Q.x,(le=E.transformOrigin)==null?void 0:le.y].join(" "),...((de=E.hide)==null?void 0:de.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:f.jsx(Ng,{scope:n,placedSide:O,onArrowChange:C,arrowX:T,arrowY:A,shouldHideArrow:W,children:f.jsx(te.div,{"data-side":O,"data-align":Y,...g,ref:S,style:{...g.style,animation:P?void 0:"none"}})})})});mc.displayName=Pa;var pc="PopperArrow",Rg={top:"bottom",right:"left",bottom:"top",left:"right"},hc=d.forwardRef(function(t,n){const{__scopePopper:r,...o}=t,a=Dg(pc,r),s=Rg[a.placedSide];return f.jsx("span",{ref:a.onArrowChange,style:{position:"absolute",left:a.arrowX,top:a.arrowY,[s]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[a.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[a.placedSide],visibility:a.shouldHideArrow?"hidden":void 0},children:f.jsx(Eg,{...o,ref:n,style:{...o.style,display:"block"}})})});hc.displayName=pc;function Tg(e){return e!==null}var Og=e=>({name:"transformOrigin",options:e,fn(t){var y,w,x;const{placement:n,rects:r,middlewareData:o}=t,s=((y=o.arrow)==null?void 0:y.centerOffset)!==0,i=s?0:e.arrowWidth,l=s?0:e.arrowHeight,[u,m]=gc(n),c={start:"0%",center:"50%",end:"100%"}[m],p=(((w=o.arrow)==null?void 0:w.x)??0)+i/2,h=(((x=o.arrow)==null?void 0:x.y)??0)+l/2;let v="",g="";return u==="bottom"?(v=s?c:`${p}px`,g=`${-l}px`):u==="top"?(v=s?c:`${p}px`,g=`${r.floating.height+l}px`):u==="right"?(v=`${-l}px`,g=s?c:`${h}px`):u==="left"&&(v=`${r.floating.width+l}px`,g=s?c:`${h}px`),{data:{x:v,y:g}}}});function gc(e){const[t,n="center"]=e.split("-");return[t,n]}var nr=uc,rr=fc,Jr=mc,eo=hc,_g="Portal",or=d.forwardRef((e,t)=>{var i;const{container:n,...r}=e,[o,a]=d.useState(!1);De(()=>a(!0),[]);const s=n||o&&((i=globalThis==null?void 0:globalThis.document)==null?void 0:i.body);return s?xa.createPortal(f.jsx(te.div,{...r,ref:t}),s):null});or.displayName=_g;function Pg(e,t){return d.useReducer((n,r)=>t[n][r]??n,e)}var He=e=>{const{present:t,children:n}=e,r=Ag(t),o=typeof n=="function"?n({present:r.isPresent}):d.Children.only(n),a=he(r.ref,Ig(o));return typeof n=="function"||r.isPresent?d.cloneElement(o,{ref:a}):null};He.displayName="Presence";function Ag(e){const[t,n]=d.useState(),r=d.useRef(null),o=d.useRef(e),a=d.useRef("none"),s=e?"mounted":"unmounted",[i,l]=Pg(s,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return d.useEffect(()=>{const u=wr(r.current);a.current=i==="mounted"?u:"none"},[i]),De(()=>{const u=r.current,m=o.current;if(m!==e){const p=a.current,h=wr(u);e?l("MOUNT"):h==="none"||(u==null?void 0:u.display)==="none"?l("UNMOUNT"):l(m&&p!==h?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,l]),De(()=>{if(t){let u;const m=t.ownerDocument.defaultView??window,c=h=>{const g=wr(r.current).includes(h.animationName);if(h.target===t&&g&&(l("ANIMATION_END"),!o.current)){const y=t.style.animationFillMode;t.style.animationFillMode="forwards",u=m.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=y)})}},p=h=>{h.target===t&&(a.current=wr(r.current))};return t.addEventListener("animationstart",p),t.addEventListener("animationcancel",c),t.addEventListener("animationend",c),()=>{m.clearTimeout(u),t.removeEventListener("animationstart",p),t.removeEventListener("animationcancel",c),t.removeEventListener("animationend",c)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(i),ref:d.useCallback(u=>{r.current=u?getComputedStyle(u):null,n(u)},[])}}function wr(e){return(e==null?void 0:e.animationName)||"none"}function Ig(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var jg=d[" useInsertionEffect ".trim().toString()]||De;function tt({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[o,a,s]=$g({defaultProp:t,onChange:n}),i=e!==void 0,l=i?e:o;{const m=d.useRef(e!==void 0);d.useEffect(()=>{const c=m.current;c!==i&&console.warn(`${r} is changing from ${c?"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.`),m.current=i},[i,r])}const u=d.useCallback(m=>{var c;if(i){const p=Lg(m)?m(e):m;p!==e&&((c=s.current)==null||c.call(s,p))}else a(m)},[i,e,a,s]);return[l,u]}function $g({defaultProp:e,onChange:t}){const[n,r]=d.useState(e),o=d.useRef(n),a=d.useRef(t);return jg(()=>{a.current=t},[t]),d.useEffect(()=>{var s;o.current!==n&&((s=a.current)==null||s.call(a,n),o.current=n)},[n,o]),[n,r,a]}function Lg(e){return typeof e=="function"}var Fg=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},ln=new WeakMap,xr=new WeakMap,Sr={},Ro=0,vc=function(e){return e&&(e.host||vc(e.parentNode))},Wg=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=vc(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},Bg=function(e,t,n,r){var o=Wg(t,Array.isArray(e)?e:[e]);Sr[n]||(Sr[n]=new WeakMap);var a=Sr[n],s=[],i=new Set,l=new Set(o),u=function(c){!c||i.has(c)||(i.add(c),u(c.parentNode))};o.forEach(u);var m=function(c){!c||l.has(c)||Array.prototype.forEach.call(c.children,function(p){if(i.has(p))m(p);else try{var h=p.getAttribute(r),v=h!==null&&h!=="false",g=(ln.get(p)||0)+1,y=(a.get(p)||0)+1;ln.set(p,g),a.set(p,y),s.push(p),g===1&&v&&xr.set(p,!0),y===1&&p.setAttribute(n,"true"),v||p.setAttribute(r,"true")}catch(w){console.error("aria-hidden: cannot operate on ",p,w)}})};return m(t),i.clear(),Ro++,function(){s.forEach(function(c){var p=ln.get(c)-1,h=a.get(c)-1;ln.set(c,p),a.set(c,h),p||(xr.has(c)||c.removeAttribute(r),xr.delete(c)),h||c.removeAttribute(n)}),Ro--,Ro||(ln=new WeakMap,ln=new WeakMap,xr=new WeakMap,Sr={})}},to=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),o=Fg(e);return o?(r.push.apply(r,Array.from(o.querySelectorAll("[aria-live], script"))),Bg(r,o,n,"aria-hidden")):function(){return null}},ft=function(){return ft=Object.assign||function(t){for(var n,r=1,o=arguments.length;r<o;r++){n=arguments[r];for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(t[a]=n[a])}return t},ft.apply(this,arguments)};function yc(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n}function Yg(e,t,n){if(n||arguments.length===2)for(var r=0,o=t.length,a;r<o;r++)(a||!(r in t))&&(a||(a=Array.prototype.slice.call(t,0,r)),a[r]=t[r]);return e.concat(a||Array.prototype.slice.call(t))}var Tr="right-scroll-bar-position",Or="width-before-scroll-bar",Hg="with-scroll-bars-hidden",zg="--removed-body-scroll-bar-size";function To(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function Gg(e,t){var n=b.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var o=n.value;o!==r&&(n.value=r,n.callback(r,o))}}}})[0];return n.callback=t,n.facade}var Ug=typeof window<"u"?d.useLayoutEffect:d.useEffect,Bs=new WeakMap;function qg(e,t){var n=Gg(null,function(r){return e.forEach(function(o){return To(o,r)})});return Ug(function(){var r=Bs.get(n);if(r){var o=new Set(r),a=new Set(e),s=n.current;o.forEach(function(i){a.has(i)||To(i,null)}),a.forEach(function(i){o.has(i)||To(i,s)})}Bs.set(n,e)},[e]),n}function Vg(e){return e}function Kg(e,t){t===void 0&&(t=Vg);var n=[],r=!1,o={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(a){var s=t(a,r);return n.push(s),function(){n=n.filter(function(i){return i!==s})}},assignSyncMedium:function(a){for(r=!0;n.length;){var s=n;n=[],s.forEach(a)}n={push:function(i){return a(i)},filter:function(){return n}}},assignMedium:function(a){r=!0;var s=[];if(n.length){var i=n;n=[],i.forEach(a),s=n}var l=function(){var m=s;s=[],m.forEach(a)},u=function(){return Promise.resolve().then(l)};u(),n={push:function(m){s.push(m),u()},filter:function(m){return s=s.filter(m),n}}}};return o}function Xg(e){e===void 0&&(e={});var t=Kg(null);return t.options=ft({async:!0,ssr:!1},e),t}var bc=function(e){var t=e.sideCar,n=yc(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return d.createElement(r,ft({},n))};bc.isSideCarExport=!0;function Zg(e,t){return e.useMedium(t),bc}var wc=Xg(),Oo=function(){},no=d.forwardRef(function(e,t){var n=d.useRef(null),r=d.useState({onScrollCapture:Oo,onWheelCapture:Oo,onTouchMoveCapture:Oo}),o=r[0],a=r[1],s=e.forwardProps,i=e.children,l=e.className,u=e.removeScrollBar,m=e.enabled,c=e.shards,p=e.sideCar,h=e.noRelative,v=e.noIsolation,g=e.inert,y=e.allowPinchZoom,w=e.as,x=w===void 0?"div":w,S=e.gapMode,k=yc(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),C=p,N=qg([n,t]),M=ft(ft({},k),o);return d.createElement(d.Fragment,null,m&&d.createElement(C,{sideCar:wc,removeScrollBar:u,shards:c,noRelative:h,noIsolation:v,inert:g,setCallbacks:a,allowPinchZoom:!!y,lockRef:n,gapMode:S}),s?d.cloneElement(d.Children.only(i),ft(ft({},M),{ref:N})):d.createElement(x,ft({},M,{className:l,ref:N}),i))});no.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};no.classNames={fullWidth:Or,zeroRight:Tr};var Qg=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function Jg(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=Qg();return t&&e.setAttribute("nonce",t),e}function ev(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function tv(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var nv=function(){var e=0,t=null;return{add:function(n){e==0&&(t=Jg())&&(ev(t,n),tv(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},rv=function(){var e=nv();return function(t,n){d.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},xc=function(){var e=rv(),t=function(n){var r=n.styles,o=n.dynamic;return e(r,o),null};return t},ov={left:0,top:0,right:0,gap:0},_o=function(e){return parseInt(e||"",10)||0},av=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],o=t[e==="padding"?"paddingRight":"marginRight"];return[_o(n),_o(r),_o(o)]},sv=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return ov;var t=av(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},iv=xc(),gn="data-scroll-locked",cv=function(e,t,n,r){var o=e.left,a=e.top,s=e.right,i=e.gap;return n===void 0&&(n="margin"),`
107
+ .`.concat(Hg,` {
103
108
  overflow: hidden `).concat(r,`;
104
- padding-right: `).concat(a,"px ").concat(r,`;
109
+ padding-right: `).concat(i,"px ").concat(r,`;
105
110
  }
106
- body[`).concat(Ot,`] {
111
+ body[`).concat(gn,`] {
107
112
  overflow: hidden `).concat(r,`;
108
113
  overscroll-behavior: contain;
109
114
  `).concat([t&&"position: relative ".concat(r,";"),n==="margin"&&`
110
115
  padding-left: `.concat(o,`px;
111
- padding-top: `).concat(s,`px;
112
- padding-right: `).concat(i,`px;
116
+ padding-top: `).concat(a,`px;
117
+ padding-right: `).concat(s,`px;
113
118
  margin-left:0;
114
119
  margin-top:0;
115
- margin-right: `).concat(a,"px ").concat(r,`;
116
- `),n==="padding"&&"padding-right: ".concat(a,"px ").concat(r,";")].filter(Boolean).join(""),`
120
+ margin-right: `).concat(i,"px ").concat(r,`;
121
+ `),n==="padding"&&"padding-right: ".concat(i,"px ").concat(r,";")].filter(Boolean).join(""),`
117
122
  }
118
123
 
119
- .`).concat(gn,` {
120
- right: `).concat(a,"px ").concat(r,`;
124
+ .`).concat(Tr,` {
125
+ right: `).concat(i,"px ").concat(r,`;
121
126
  }
122
127
 
123
- .`).concat(vn,` {
124
- margin-right: `).concat(a,"px ").concat(r,`;
128
+ .`).concat(Or,` {
129
+ margin-right: `).concat(i,"px ").concat(r,`;
125
130
  }
126
131
 
127
- .`).concat(gn," .").concat(gn,` {
132
+ .`).concat(Tr," .").concat(Tr,` {
128
133
  right: 0 `).concat(r,`;
129
134
  }
130
135
 
131
- .`).concat(vn," .").concat(vn,` {
136
+ .`).concat(Or," .").concat(Or,` {
132
137
  margin-right: 0 `).concat(r,`;
133
138
  }
134
139
 
135
- body[`).concat(Ot,`] {
136
- `).concat(tf,": ").concat(a,`px;
140
+ body[`).concat(gn,`] {
141
+ `).concat(zg,": ").concat(i,`px;
137
142
  }
138
- `)},Fo=function(){var e=parseInt(document.body.getAttribute(Ot)||"0",10);return isFinite(e)?e:0},xf=function(){d.useEffect(function(){return document.body.setAttribute(Ot,(Fo()+1).toString()),function(){var e=Fo()-1;e<=0?document.body.removeAttribute(Ot):document.body.setAttribute(Ot,e.toString())}},[])},Sf=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,o=r===void 0?"margin":r;xf();var s=d.useMemo(function(){return yf(o)},[o]);return d.createElement(bf,{styles:wf(s,!t,o,n?"":"!important")})},Dr=!1;if(typeof window<"u")try{var mn=Object.defineProperty({},"passive",{get:function(){return Dr=!0,!0}});window.addEventListener("test",mn,mn),window.removeEventListener("test",mn,mn)}catch{Dr=!1}var St=Dr?{passive:!1}:!1,kf=function(e){return e.tagName==="TEXTAREA"},ua=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!kf(e)&&n[t]==="visible")},Mf=function(e){return ua(e,"overflowY")},Cf=function(e){return ua(e,"overflowX")},Lo=function(e,t){var n=t.ownerDocument,r=t;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var o=da(e,r);if(o){var s=fa(e,r),i=s[1],a=s[2];if(i>a)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},Nf=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},Df=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},da=function(e,t){return e==="v"?Mf(t):Cf(t)},fa=function(e,t){return e==="v"?Nf(t):Df(t)},Of=function(e,t){return e==="h"&&t==="rtl"?-1:1},Ef=function(e,t,n,r,o){var s=Of(e,window.getComputedStyle(t).direction),i=s*r,a=n.target,c=t.contains(a),l=!1,f=i>0,u=0,h=0;do{if(!a)break;var g=fa(e,a),b=g[0],p=g[1],v=g[2],S=p-v-s*b;(b||S)&&da(e,a)&&(u+=S,h+=b);var y=a.parentNode;a=y&&y.nodeType===Node.DOCUMENT_FRAGMENT_NODE?y.host:y}while(!c&&a!==document.body||c&&(t.contains(a)||t===a));return(f&&Math.abs(u)<1||!f&&Math.abs(h)<1)&&(l=!0),l},hn=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},Bo=function(e){return[e.deltaX,e.deltaY]},Yo=function(e){return e&&"current"in e?e.current:e},Pf=function(e,t){return e[0]===t[0]&&e[1]===t[1]},Af=function(e){return`
143
+ `)},Ys=function(){var e=parseInt(document.body.getAttribute(gn)||"0",10);return isFinite(e)?e:0},lv=function(){d.useEffect(function(){return document.body.setAttribute(gn,(Ys()+1).toString()),function(){var e=Ys()-1;e<=0?document.body.removeAttribute(gn):document.body.setAttribute(gn,e.toString())}},[])},uv=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,o=r===void 0?"margin":r;lv();var a=d.useMemo(function(){return sv(o)},[o]);return d.createElement(iv,{styles:cv(a,!t,o,n?"":"!important")})},na=!1;if(typeof window<"u")try{var Cr=Object.defineProperty({},"passive",{get:function(){return na=!0,!0}});window.addEventListener("test",Cr,Cr),window.removeEventListener("test",Cr,Cr)}catch{na=!1}var un=na?{passive:!1}:!1,dv=function(e){return e.tagName==="TEXTAREA"},Sc=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!dv(e)&&n[t]==="visible")},fv=function(e){return Sc(e,"overflowY")},mv=function(e){return Sc(e,"overflowX")},Hs=function(e,t){var n=t.ownerDocument,r=t;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var o=Cc(e,r);if(o){var a=Mc(e,r),s=a[1],i=a[2];if(s>i)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},pv=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},hv=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},Cc=function(e,t){return e==="v"?fv(t):mv(t)},Mc=function(e,t){return e==="v"?pv(t):hv(t)},gv=function(e,t){return e==="h"&&t==="rtl"?-1:1},vv=function(e,t,n,r,o){var a=gv(e,window.getComputedStyle(t).direction),s=a*r,i=n.target,l=t.contains(i),u=!1,m=s>0,c=0,p=0;do{if(!i)break;var h=Mc(e,i),v=h[0],g=h[1],y=h[2],w=g-y-a*v;(v||w)&&Cc(e,i)&&(c+=w,p+=v);var x=i.parentNode;i=x&&x.nodeType===Node.DOCUMENT_FRAGMENT_NODE?x.host:x}while(!l&&i!==document.body||l&&(t.contains(i)||t===i));return(m&&Math.abs(c)<1||!m&&Math.abs(p)<1)&&(u=!0),u},Mr=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},zs=function(e){return[e.deltaX,e.deltaY]},Gs=function(e){return e&&"current"in e?e.current:e},yv=function(e,t){return e[0]===t[0]&&e[1]===t[1]},bv=function(e){return`
139
144
  .block-interactivity-`.concat(e,` {pointer-events: none;}
140
145
  .allow-interactivity-`).concat(e,` {pointer-events: all;}
141
- `)},Tf=0,kt=[];function Rf(e){var t=d.useRef([]),n=d.useRef([0,0]),r=d.useRef(),o=d.useState(Tf++)[0],s=d.useState(la)[0],i=d.useRef(e);d.useEffect(function(){i.current=e},[e]),d.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var p=Jd([e.lockRef.current],(e.shards||[]).map(Yo),!0).filter(Boolean);return p.forEach(function(v){return v.classList.add("allow-interactivity-".concat(o))}),function(){document.body.classList.remove("block-interactivity-".concat(o)),p.forEach(function(v){return v.classList.remove("allow-interactivity-".concat(o))})}}},[e.inert,e.lockRef.current,e.shards]);var a=d.useCallback(function(p,v){if("touches"in p&&p.touches.length===2||p.type==="wheel"&&p.ctrlKey)return!i.current.allowPinchZoom;var S=hn(p),y=n.current,x="deltaX"in p?p.deltaX:y[0]-S[0],O="deltaY"in p?p.deltaY:y[1]-S[1],w,M=p.target,C=Math.abs(x)>Math.abs(O)?"h":"v";if("touches"in p&&C==="h"&&M.type==="range")return!1;var D=Lo(C,M);if(!D)return!0;if(D?w=C:(w=C==="v"?"h":"v",D=Lo(C,M)),!D)return!1;if(!r.current&&"changedTouches"in p&&(x||O)&&(r.current=w),!w)return!0;var Y=r.current||w;return Ef(Y,v,p,Y==="h"?x:O)},[]),c=d.useCallback(function(p){var v=p;if(!(!kt.length||kt[kt.length-1]!==s)){var S="deltaY"in v?Bo(v):hn(v),y=t.current.filter(function(w){return w.name===v.type&&(w.target===v.target||v.target===w.shadowParent)&&Pf(w.delta,S)})[0];if(y&&y.should){v.cancelable&&v.preventDefault();return}if(!y){var x=(i.current.shards||[]).map(Yo).filter(Boolean).filter(function(w){return w.contains(v.target)}),O=x.length>0?a(v,x[0]):!i.current.noIsolation;O&&v.cancelable&&v.preventDefault()}}},[]),l=d.useCallback(function(p,v,S,y){var x={name:p,delta:v,target:S,should:y,shadowParent:_f(S)};t.current.push(x),setTimeout(function(){t.current=t.current.filter(function(O){return O!==x})},1)},[]),f=d.useCallback(function(p){n.current=hn(p),r.current=void 0},[]),u=d.useCallback(function(p){l(p.type,Bo(p),p.target,a(p,e.lockRef.current))},[]),h=d.useCallback(function(p){l(p.type,hn(p),p.target,a(p,e.lockRef.current))},[]);d.useEffect(function(){return kt.push(s),e.setCallbacks({onScrollCapture:u,onWheelCapture:u,onTouchMoveCapture:h}),document.addEventListener("wheel",c,St),document.addEventListener("touchmove",c,St),document.addEventListener("touchstart",f,St),function(){kt=kt.filter(function(p){return p!==s}),document.removeEventListener("wheel",c,St),document.removeEventListener("touchmove",c,St),document.removeEventListener("touchstart",f,St)}},[]);var g=e.removeScrollBar,b=e.inert;return d.createElement(d.Fragment,null,b?d.createElement(s,{styles:Af(o)}):null,g?d.createElement(Sf,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function _f(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const jf=lf(ca,Rf);var Bn=d.forwardRef(function(e,t){return d.createElement(Ln,je({},e,{ref:t,sideCar:jf}))});Bn.classNames=Ln.classNames;var Yn="Popover",[ma,Qv]=Qt(Yn,[$n]),en=$n(),[If,tt]=ma(Yn),ha=e=>{const{__scopePopover:t,children:n,open:r,defaultOpen:o,onOpenChange:s,modal:i=!1}=e,a=en(t),c=d.useRef(null),[l,f]=d.useState(!1),[u,h]=Cn({prop:r,defaultProp:o??!1,onChange:s,caller:Yn});return m.jsx(na,{...a,children:m.jsx(If,{scope:t,contentId:Me(),triggerRef:c,open:u,onOpenChange:h,onOpenToggle:d.useCallback(()=>h(g=>!g),[h]),hasCustomAnchor:l,onCustomAnchorAdd:d.useCallback(()=>f(!0),[]),onCustomAnchorRemove:d.useCallback(()=>f(!1),[]),modal:i,children:n})})};ha.displayName=Yn;var pa="PopoverAnchor",Wf=d.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,o=tt(pa,n),s=en(n),{onCustomAnchorAdd:i,onCustomAnchorRemove:a}=o;return d.useEffect(()=>(i(),()=>a()),[i,a]),m.jsx(Qr,{...s,...r,ref:t})});Wf.displayName=pa;var ga="PopoverTrigger",va=d.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,o=tt(ga,n),s=en(n),i=fe(t,o.triggerRef),a=m.jsx(oe.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":Sa(o.open),...r,ref:i,onClick:ae(e.onClick,o.onOpenToggle)});return o.hasCustomAnchor?a:m.jsx(Qr,{asChild:!0,...s,children:a})});va.displayName=ga;var eo="PopoverPortal",[$f,Ff]=ma(eo,{forceMount:void 0}),ya=e=>{const{__scopePopover:t,forceMount:n,children:r,container:o}=e,s=tt(eo,t);return m.jsx($f,{scope:t,forceMount:n,children:m.jsx(Wt,{present:n||s.open,children:m.jsx(Fn,{asChild:!0,container:o,children:r})})})};ya.displayName=eo;var Pt="PopoverContent",ba=d.forwardRef((e,t)=>{const n=Ff(Pt,e.__scopePopover),{forceMount:r=n.forceMount,...o}=e,s=tt(Pt,e.__scopePopover);return m.jsx(Wt,{present:r||s.open,children:s.modal?m.jsx(Bf,{...o,ref:t}):m.jsx(Yf,{...o,ref:t})})});ba.displayName=Pt;var Lf=ut("PopoverContent.RemoveScroll"),Bf=d.forwardRef((e,t)=>{const n=tt(Pt,e.__scopePopover),r=d.useRef(null),o=fe(t,r),s=d.useRef(!1);return d.useEffect(()=>{const i=r.current;if(i)return Jr(i)},[]),m.jsx(Bn,{as:Lf,allowPinchZoom:!0,children:m.jsx(wa,{...e,ref:o,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:ae(e.onCloseAutoFocus,i=>{var a;i.preventDefault(),s.current||(a=n.triggerRef.current)==null||a.focus()}),onPointerDownOutside:ae(e.onPointerDownOutside,i=>{const a=i.detail.originalEvent,c=a.button===0&&a.ctrlKey===!0,l=a.button===2||c;s.current=l},{checkForDefaultPrevented:!1}),onFocusOutside:ae(e.onFocusOutside,i=>i.preventDefault(),{checkForDefaultPrevented:!1})})})}),Yf=d.forwardRef((e,t)=>{const n=tt(Pt,e.__scopePopover),r=d.useRef(!1),o=d.useRef(!1);return m.jsx(wa,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:s=>{var i,a;(i=e.onCloseAutoFocus)==null||i.call(e,s),s.defaultPrevented||(r.current||(a=n.triggerRef.current)==null||a.focus(),s.preventDefault()),r.current=!1,o.current=!1},onInteractOutside:s=>{var c,l;(c=e.onInteractOutside)==null||c.call(e,s),s.defaultPrevented||(r.current=!0,s.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const i=s.target;((l=n.triggerRef.current)==null?void 0:l.contains(i))&&s.preventDefault(),s.detail.originalEvent.type==="focusin"&&o.current&&s.preventDefault()}})}),wa=d.forwardRef((e,t)=>{const{__scopePopover:n,trapFocus:r,onOpenAutoFocus:o,onCloseAutoFocus:s,disableOutsidePointerEvents:i,onEscapeKeyDown:a,onPointerDownOutside:c,onFocusOutside:l,onInteractOutside:f,...u}=e,h=tt(Pt,n),g=en(n);return Yr(),m.jsx(_n,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:o,onUnmountAutoFocus:s,children:m.jsx(Rn,{asChild:!0,disableOutsidePointerEvents:i,onInteractOutside:f,onEscapeKeyDown:a,onPointerDownOutside:c,onFocusOutside:l,onDismiss:()=>h.onOpenChange(!1),children:m.jsx(ra,{"data-state":Sa(h.open),role:"dialog",id:h.contentId,...g,...u,ref:t,style:{...u.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)"}})})})}),xa="PopoverClose",zf=d.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,o=tt(xa,n);return m.jsx(oe.button,{type:"button",...r,ref:t,onClick:ae(e.onClick,()=>o.onOpenChange(!1))})});zf.displayName=xa;var Hf="PopoverArrow",qf=d.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,o=en(n);return m.jsx(oa,{...o,...r,ref:t})});qf.displayName=Hf;function Sa(e){return e?"open":"closed"}var Uf=ha,Gf=va,Kf=ya,ka=ba;const Vf=Uf,Xf=Gf,Ma=d.forwardRef(({className:e,sideOffset:t=4,...n},r)=>m.jsx(Kf,{children:m.jsx(ka,{ref:r,sideOffset:t,className:U("z-50 w-72 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...n})}));Ma.displayName=ka.displayName;function zo(e,[t,n]){return Math.min(n,Math.max(t,e))}function Zf(e){const t=e+"CollectionProvider",[n,r]=Qt(t),[o,s]=n(t,{collectionRef:{current:null},itemMap:new Map}),i=p=>{const{scope:v,children:S}=p,y=N.useRef(null),x=N.useRef(new Map).current;return m.jsx(o,{scope:v,itemMap:x,collectionRef:y,children:S})};i.displayName=t;const a=e+"CollectionSlot",c=ut(a),l=N.forwardRef((p,v)=>{const{scope:S,children:y}=p,x=s(a,S),O=fe(v,x.collectionRef);return m.jsx(c,{ref:O,children:y})});l.displayName=a;const f=e+"CollectionItemSlot",u="data-radix-collection-item",h=ut(f),g=N.forwardRef((p,v)=>{const{scope:S,children:y,...x}=p,O=N.useRef(null),w=fe(v,O),M=s(f,S);return N.useEffect(()=>(M.itemMap.set(O,{ref:O,...x}),()=>void M.itemMap.delete(O))),m.jsx(h,{[u]:"",ref:w,children:y})});g.displayName=f;function b(p){const v=s(e+"CollectionConsumer",p);return N.useCallback(()=>{const y=v.collectionRef.current;if(!y)return[];const x=Array.from(y.querySelectorAll(`[${u}]`));return Array.from(v.itemMap.values()).sort((M,C)=>x.indexOf(M.ref.current)-x.indexOf(C.ref.current))},[v.collectionRef,v.itemMap])}return[{Provider:i,Slot:l,ItemSlot:g},b,r]}var Qf=d.createContext(void 0);function Jf(e){const t=d.useContext(Qf);return e||t||"ltr"}function em(e){const t=d.useRef({value:e,previous:e});return d.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}var Ca=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"}),tm="VisuallyHidden",nm=d.forwardRef((e,t)=>m.jsx(oe.span,{...e,ref:t,style:{...Ca,...e.style}}));nm.displayName=tm;var rm=[" ","Enter","ArrowUp","ArrowDown"],om=[" ","Enter"],ht="Select",[zn,Hn,sm]=Zf(ht),[$t,Jv]=Qt(ht,[sm,$n]),qn=$n(),[am,nt]=$t(ht),[im,cm]=$t(ht),Na=e=>{const{__scopeSelect:t,children:n,open:r,defaultOpen:o,onOpenChange:s,value:i,defaultValue:a,onValueChange:c,dir:l,name:f,autoComplete:u,disabled:h,required:g,form:b}=e,p=qn(t),[v,S]=d.useState(null),[y,x]=d.useState(null),[O,w]=d.useState(!1),M=Jf(l),[C,D]=Cn({prop:r,defaultProp:o??!1,onChange:s,caller:ht}),[Y,L]=Cn({prop:i,defaultProp:a,onChange:c,caller:ht}),$=d.useRef(null),K=v?b||!!v.closest("form"):!0,[J,_]=d.useState(new Set),A=Array.from(J).map(P=>P.props.value).join(";");return m.jsx(na,{...p,children:m.jsxs(am,{required:g,scope:t,trigger:v,onTriggerChange:S,valueNode:y,onValueNodeChange:x,valueNodeHasChildren:O,onValueNodeHasChildrenChange:w,contentId:Me(),value:Y,onValueChange:L,open:C,onOpenChange:D,dir:M,triggerPointerDownPosRef:$,disabled:h,children:[m.jsx(zn.Provider,{scope:t,children:m.jsx(im,{scope:e.__scopeSelect,onNativeOptionAdd:d.useCallback(P=>{_(T=>new Set(T).add(P))},[]),onNativeOptionRemove:d.useCallback(P=>{_(T=>{const k=new Set(T);return k.delete(P),k})},[]),children:n})}),K?m.jsxs(Xa,{"aria-hidden":!0,required:g,tabIndex:-1,name:f,autoComplete:u,value:Y,onChange:P=>L(P.target.value),disabled:h,form:b,children:[Y===void 0?m.jsx("option",{value:""}):null,Array.from(J)]},A):null]})})};Na.displayName=ht;var Da="SelectTrigger",Oa=d.forwardRef((e,t)=>{const{__scopeSelect:n,disabled:r=!1,...o}=e,s=qn(n),i=nt(Da,n),a=i.disabled||r,c=fe(t,i.onTriggerChange),l=Hn(n),f=d.useRef("touch"),[u,h,g]=Qa(p=>{const v=l().filter(x=>!x.disabled),S=v.find(x=>x.value===i.value),y=Ja(v,p,S);y!==void 0&&i.onValueChange(y.value)}),b=p=>{a||(i.onOpenChange(!0),g()),p&&(i.triggerPointerDownPosRef.current={x:Math.round(p.pageX),y:Math.round(p.pageY)})};return m.jsx(Qr,{asChild:!0,...s,children:m.jsx(oe.button,{type:"button",role:"combobox","aria-controls":i.contentId,"aria-expanded":i.open,"aria-required":i.required,"aria-autocomplete":"none",dir:i.dir,"data-state":i.open?"open":"closed",disabled:a,"data-disabled":a?"":void 0,"data-placeholder":Za(i.value)?"":void 0,...o,ref:c,onClick:ae(o.onClick,p=>{p.currentTarget.focus(),f.current!=="mouse"&&b(p)}),onPointerDown:ae(o.onPointerDown,p=>{f.current=p.pointerType;const v=p.target;v.hasPointerCapture(p.pointerId)&&v.releasePointerCapture(p.pointerId),p.button===0&&p.ctrlKey===!1&&p.pointerType==="mouse"&&(b(p),p.preventDefault())}),onKeyDown:ae(o.onKeyDown,p=>{const v=u.current!=="";!(p.ctrlKey||p.altKey||p.metaKey)&&p.key.length===1&&h(p.key),!(v&&p.key===" ")&&rm.includes(p.key)&&(b(),p.preventDefault())})})})});Oa.displayName=Da;var Ea="SelectValue",Pa=d.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:o,children:s,placeholder:i="",...a}=e,c=nt(Ea,n),{onValueNodeHasChildrenChange:l}=c,f=s!==void 0,u=fe(t,c.onValueNodeChange);return be(()=>{l(f)},[l,f]),m.jsx(oe.span,{...a,ref:u,style:{pointerEvents:"none"},children:Za(c.value)?m.jsx(m.Fragment,{children:i}):s})});Pa.displayName=Ea;var lm="SelectIcon",Aa=d.forwardRef((e,t)=>{const{__scopeSelect:n,children:r,...o}=e;return m.jsx(oe.span,{"aria-hidden":!0,...o,ref:t,children:r||"▼"})});Aa.displayName=lm;var um="SelectPortal",Ta=e=>m.jsx(Fn,{asChild:!0,...e});Ta.displayName=um;var pt="SelectContent",Ra=d.forwardRef((e,t)=>{const n=nt(pt,e.__scopeSelect),[r,o]=d.useState();if(be(()=>{o(new DocumentFragment)},[]),!n.open){const s=r;return s?Tn.createPortal(m.jsx(_a,{scope:e.__scopeSelect,children:m.jsx(zn.Slot,{scope:e.__scopeSelect,children:m.jsx("div",{children:e.children})})}),s):null}return m.jsx(ja,{...e,ref:t})});Ra.displayName=pt;var Oe=10,[_a,rt]=$t(pt),dm="SelectContentImpl",fm=ut("SelectContent.RemoveScroll"),ja=d.forwardRef((e,t)=>{const{__scopeSelect:n,position:r="item-aligned",onCloseAutoFocus:o,onEscapeKeyDown:s,onPointerDownOutside:i,side:a,sideOffset:c,align:l,alignOffset:f,arrowPadding:u,collisionBoundary:h,collisionPadding:g,sticky:b,hideWhenDetached:p,avoidCollisions:v,...S}=e,y=nt(pt,n),[x,O]=d.useState(null),[w,M]=d.useState(null),C=fe(t,R=>O(R)),[D,Y]=d.useState(null),[L,$]=d.useState(null),K=Hn(n),[J,_]=d.useState(!1),A=d.useRef(!1);d.useEffect(()=>{if(x)return Jr(x)},[x]),Yr();const P=d.useCallback(R=>{const[V,...Z]=K().map(te=>te.ref.current),[G]=Z.slice(-1),ee=document.activeElement;for(const te of R)if(te===ee||(te==null||te.scrollIntoView({block:"nearest"}),te===V&&w&&(w.scrollTop=0),te===G&&w&&(w.scrollTop=w.scrollHeight),te==null||te.focus(),document.activeElement!==ee))return},[K,w]),T=d.useCallback(()=>P([D,x]),[P,D,x]);d.useEffect(()=>{J&&T()},[J,T]);const{onOpenChange:k,triggerPointerDownPosRef:I}=y;d.useEffect(()=>{if(x){let R={x:0,y:0};const V=G=>{var ee,te;R={x:Math.abs(Math.round(G.pageX)-(((ee=I.current)==null?void 0:ee.x)??0)),y:Math.abs(Math.round(G.pageY)-(((te=I.current)==null?void 0:te.y)??0))}},Z=G=>{R.x<=10&&R.y<=10?G.preventDefault():x.contains(G.target)||k(!1),document.removeEventListener("pointermove",V),I.current=null};return I.current!==null&&(document.addEventListener("pointermove",V),document.addEventListener("pointerup",Z,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",V),document.removeEventListener("pointerup",Z,{capture:!0})}}},[x,k,I]),d.useEffect(()=>{const R=()=>k(!1);return window.addEventListener("blur",R),window.addEventListener("resize",R),()=>{window.removeEventListener("blur",R),window.removeEventListener("resize",R)}},[k]);const[B,Q]=Qa(R=>{const V=K().filter(ee=>!ee.disabled),Z=V.find(ee=>ee.ref.current===document.activeElement),G=Ja(V,R,Z);G&&setTimeout(()=>G.ref.current.focus())}),E=d.useCallback((R,V,Z)=>{const G=!A.current&&!Z;(y.value!==void 0&&y.value===V||G)&&(Y(R),G&&(A.current=!0))},[y.value]),j=d.useCallback(()=>x==null?void 0:x.focus(),[x]),F=d.useCallback((R,V,Z)=>{const G=!A.current&&!Z;(y.value!==void 0&&y.value===V||G)&&$(R)},[y.value]),W=r==="popper"?Or:Ia,X=W===Or?{side:a,sideOffset:c,align:l,alignOffset:f,arrowPadding:u,collisionBoundary:h,collisionPadding:g,sticky:b,hideWhenDetached:p,avoidCollisions:v}:{};return m.jsx(_a,{scope:n,content:x,viewport:w,onViewportChange:M,itemRefCallback:E,selectedItem:D,onItemLeave:j,itemTextRefCallback:F,focusSelectedItem:T,selectedItemText:L,position:r,isPositioned:J,searchRef:B,children:m.jsx(Bn,{as:fm,allowPinchZoom:!0,children:m.jsx(_n,{asChild:!0,trapped:y.open,onMountAutoFocus:R=>{R.preventDefault()},onUnmountAutoFocus:ae(o,R=>{var V;(V=y.trigger)==null||V.focus({preventScroll:!0}),R.preventDefault()}),children:m.jsx(Rn,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:s,onPointerDownOutside:i,onFocusOutside:R=>R.preventDefault(),onDismiss:()=>y.onOpenChange(!1),children:m.jsx(W,{role:"listbox",id:y.contentId,"data-state":y.open?"open":"closed",dir:y.dir,onContextMenu:R=>R.preventDefault(),...S,...X,onPlaced:()=>_(!0),ref:C,style:{display:"flex",flexDirection:"column",outline:"none",...S.style},onKeyDown:ae(S.onKeyDown,R=>{const V=R.ctrlKey||R.altKey||R.metaKey;if(R.key==="Tab"&&R.preventDefault(),!V&&R.key.length===1&&Q(R.key),["ArrowUp","ArrowDown","Home","End"].includes(R.key)){let G=K().filter(ee=>!ee.disabled).map(ee=>ee.ref.current);if(["ArrowUp","End"].includes(R.key)&&(G=G.slice().reverse()),["ArrowUp","ArrowDown"].includes(R.key)){const ee=R.target,te=G.indexOf(ee);G=G.slice(te+1)}setTimeout(()=>P(G)),R.preventDefault()}})})})})})})});ja.displayName=dm;var mm="SelectItemAlignedPosition",Ia=d.forwardRef((e,t)=>{const{__scopeSelect:n,onPlaced:r,...o}=e,s=nt(pt,n),i=rt(pt,n),[a,c]=d.useState(null),[l,f]=d.useState(null),u=fe(t,C=>f(C)),h=Hn(n),g=d.useRef(!1),b=d.useRef(!0),{viewport:p,selectedItem:v,selectedItemText:S,focusSelectedItem:y}=i,x=d.useCallback(()=>{if(s.trigger&&s.valueNode&&a&&l&&p&&v&&S){const C=s.trigger.getBoundingClientRect(),D=l.getBoundingClientRect(),Y=s.valueNode.getBoundingClientRect(),L=S.getBoundingClientRect();if(s.dir!=="rtl"){const ee=L.left-D.left,te=Y.left-ee,me=C.left-te,xe=C.width+me,ot=Math.max(xe,D.width),st=window.innerWidth-Oe,at=zo(te,[Oe,Math.max(Oe,st-ot)]);a.style.minWidth=xe+"px",a.style.left=at+"px"}else{const ee=D.right-L.right,te=window.innerWidth-Y.right-ee,me=window.innerWidth-C.right-te,xe=C.width+me,ot=Math.max(xe,D.width),st=window.innerWidth-Oe,at=zo(te,[Oe,Math.max(Oe,st-ot)]);a.style.minWidth=xe+"px",a.style.right=at+"px"}const $=h(),K=window.innerHeight-Oe*2,J=p.scrollHeight,_=window.getComputedStyle(l),A=parseInt(_.borderTopWidth,10),P=parseInt(_.paddingTop,10),T=parseInt(_.borderBottomWidth,10),k=parseInt(_.paddingBottom,10),I=A+P+J+k+T,B=Math.min(v.offsetHeight*5,I),Q=window.getComputedStyle(p),E=parseInt(Q.paddingTop,10),j=parseInt(Q.paddingBottom,10),F=C.top+C.height/2-Oe,W=K-F,X=v.offsetHeight/2,R=v.offsetTop+X,V=A+P+R,Z=I-V;if(V<=F){const ee=$.length>0&&v===$[$.length-1].ref.current;a.style.bottom="0px";const te=l.clientHeight-p.offsetTop-p.offsetHeight,me=Math.max(W,X+(ee?j:0)+te+T),xe=V+me;a.style.height=xe+"px"}else{const ee=$.length>0&&v===$[0].ref.current;a.style.top="0px";const me=Math.max(F,A+p.offsetTop+(ee?E:0)+X)+Z;a.style.height=me+"px",p.scrollTop=V-F+p.offsetTop}a.style.margin=`${Oe}px 0`,a.style.minHeight=B+"px",a.style.maxHeight=K+"px",r==null||r(),requestAnimationFrame(()=>g.current=!0)}},[h,s.trigger,s.valueNode,a,l,p,v,S,s.dir,r]);be(()=>x(),[x]);const[O,w]=d.useState();be(()=>{l&&w(window.getComputedStyle(l).zIndex)},[l]);const M=d.useCallback(C=>{C&&b.current===!0&&(x(),y==null||y(),b.current=!1)},[x,y]);return m.jsx(pm,{scope:n,contentWrapper:a,shouldExpandOnScrollRef:g,onScrollButtonChange:M,children:m.jsx("div",{ref:c,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:O},children:m.jsx(oe.div,{...o,ref:u,style:{boxSizing:"border-box",maxHeight:"100%",...o.style}})})})});Ia.displayName=mm;var hm="SelectPopperPosition",Or=d.forwardRef((e,t)=>{const{__scopeSelect:n,align:r="start",collisionPadding:o=Oe,...s}=e,i=qn(n);return m.jsx(ra,{...i,...s,ref:t,align:r,collisionPadding:o,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)"}})});Or.displayName=hm;var[pm,to]=$t(pt,{}),Er="SelectViewport",Wa=d.forwardRef((e,t)=>{const{__scopeSelect:n,nonce:r,...o}=e,s=rt(Er,n),i=to(Er,n),a=fe(t,s.onViewportChange),c=d.useRef(0);return m.jsxs(m.Fragment,{children:[m.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:r}),m.jsx(zn.Slot,{scope:n,children:m.jsx(oe.div,{"data-radix-select-viewport":"",role:"presentation",...o,ref:a,style:{position:"relative",flex:1,overflow:"hidden auto",...o.style},onScroll:ae(o.onScroll,l=>{const f=l.currentTarget,{contentWrapper:u,shouldExpandOnScrollRef:h}=i;if(h!=null&&h.current&&u){const g=Math.abs(c.current-f.scrollTop);if(g>0){const b=window.innerHeight-Oe*2,p=parseFloat(u.style.minHeight),v=parseFloat(u.style.height),S=Math.max(p,v);if(S<b){const y=S+g,x=Math.min(b,y),O=y-x;u.style.height=x+"px",u.style.bottom==="0px"&&(f.scrollTop=O>0?O:0,u.style.justifyContent="flex-end")}}}c.current=f.scrollTop})})})]})});Wa.displayName=Er;var $a="SelectGroup",[gm,vm]=$t($a),ym=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=Me();return m.jsx(gm,{scope:n,id:o,children:m.jsx(oe.div,{role:"group","aria-labelledby":o,...r,ref:t})})});ym.displayName=$a;var Fa="SelectLabel",La=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=vm(Fa,n);return m.jsx(oe.div,{id:o.id,...r,ref:t})});La.displayName=Fa;var Nn="SelectItem",[bm,Ba]=$t(Nn),Ya=d.forwardRef((e,t)=>{const{__scopeSelect:n,value:r,disabled:o=!1,textValue:s,...i}=e,a=nt(Nn,n),c=rt(Nn,n),l=a.value===r,[f,u]=d.useState(s??""),[h,g]=d.useState(!1),b=fe(t,y=>{var x;return(x=c.itemRefCallback)==null?void 0:x.call(c,y,r,o)}),p=Me(),v=d.useRef("touch"),S=()=>{o||(a.onValueChange(r),a.onOpenChange(!1))};if(r==="")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 m.jsx(bm,{scope:n,value:r,disabled:o,textId:p,isSelected:l,onItemTextChange:d.useCallback(y=>{u(x=>x||((y==null?void 0:y.textContent)??"").trim())},[]),children:m.jsx(zn.ItemSlot,{scope:n,value:r,disabled:o,textValue:f,children:m.jsx(oe.div,{role:"option","aria-labelledby":p,"data-highlighted":h?"":void 0,"aria-selected":l&&h,"data-state":l?"checked":"unchecked","aria-disabled":o||void 0,"data-disabled":o?"":void 0,tabIndex:o?void 0:-1,...i,ref:b,onFocus:ae(i.onFocus,()=>g(!0)),onBlur:ae(i.onBlur,()=>g(!1)),onClick:ae(i.onClick,()=>{v.current!=="mouse"&&S()}),onPointerUp:ae(i.onPointerUp,()=>{v.current==="mouse"&&S()}),onPointerDown:ae(i.onPointerDown,y=>{v.current=y.pointerType}),onPointerMove:ae(i.onPointerMove,y=>{var x;v.current=y.pointerType,o?(x=c.onItemLeave)==null||x.call(c):v.current==="mouse"&&y.currentTarget.focus({preventScroll:!0})}),onPointerLeave:ae(i.onPointerLeave,y=>{var x;y.currentTarget===document.activeElement&&((x=c.onItemLeave)==null||x.call(c))}),onKeyDown:ae(i.onKeyDown,y=>{var O;((O=c.searchRef)==null?void 0:O.current)!==""&&y.key===" "||(om.includes(y.key)&&S(),y.key===" "&&y.preventDefault())})})})})});Ya.displayName=Nn;var Ht="SelectItemText",za=d.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:o,...s}=e,i=nt(Ht,n),a=rt(Ht,n),c=Ba(Ht,n),l=cm(Ht,n),[f,u]=d.useState(null),h=fe(t,S=>u(S),c.onItemTextChange,S=>{var y;return(y=a.itemTextRefCallback)==null?void 0:y.call(a,S,c.value,c.disabled)}),g=f==null?void 0:f.textContent,b=d.useMemo(()=>m.jsx("option",{value:c.value,disabled:c.disabled,children:g},c.value),[c.disabled,c.value,g]),{onNativeOptionAdd:p,onNativeOptionRemove:v}=l;return be(()=>(p(b),()=>v(b)),[p,v,b]),m.jsxs(m.Fragment,{children:[m.jsx(oe.span,{id:c.textId,...s,ref:h}),c.isSelected&&i.valueNode&&!i.valueNodeHasChildren?Tn.createPortal(s.children,i.valueNode):null]})});za.displayName=Ht;var Ha="SelectItemIndicator",qa=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return Ba(Ha,n).isSelected?m.jsx(oe.span,{"aria-hidden":!0,...r,ref:t}):null});qa.displayName=Ha;var Pr="SelectScrollUpButton",Ua=d.forwardRef((e,t)=>{const n=rt(Pr,e.__scopeSelect),r=to(Pr,e.__scopeSelect),[o,s]=d.useState(!1),i=fe(t,r.onScrollButtonChange);return be(()=>{if(n.viewport&&n.isPositioned){let a=function(){const l=c.scrollTop>0;s(l)};const c=n.viewport;return a(),c.addEventListener("scroll",a),()=>c.removeEventListener("scroll",a)}},[n.viewport,n.isPositioned]),o?m.jsx(Ka,{...e,ref:i,onAutoScroll:()=>{const{viewport:a,selectedItem:c}=n;a&&c&&(a.scrollTop=a.scrollTop-c.offsetHeight)}}):null});Ua.displayName=Pr;var Ar="SelectScrollDownButton",Ga=d.forwardRef((e,t)=>{const n=rt(Ar,e.__scopeSelect),r=to(Ar,e.__scopeSelect),[o,s]=d.useState(!1),i=fe(t,r.onScrollButtonChange);return be(()=>{if(n.viewport&&n.isPositioned){let a=function(){const l=c.scrollHeight-c.clientHeight,f=Math.ceil(c.scrollTop)<l;s(f)};const c=n.viewport;return a(),c.addEventListener("scroll",a),()=>c.removeEventListener("scroll",a)}},[n.viewport,n.isPositioned]),o?m.jsx(Ka,{...e,ref:i,onAutoScroll:()=>{const{viewport:a,selectedItem:c}=n;a&&c&&(a.scrollTop=a.scrollTop+c.offsetHeight)}}):null});Ga.displayName=Ar;var Ka=d.forwardRef((e,t)=>{const{__scopeSelect:n,onAutoScroll:r,...o}=e,s=rt("SelectScrollButton",n),i=d.useRef(null),a=Hn(n),c=d.useCallback(()=>{i.current!==null&&(window.clearInterval(i.current),i.current=null)},[]);return d.useEffect(()=>()=>c(),[c]),be(()=>{var f;const l=a().find(u=>u.ref.current===document.activeElement);(f=l==null?void 0:l.ref.current)==null||f.scrollIntoView({block:"nearest"})},[a]),m.jsx(oe.div,{"aria-hidden":!0,...o,ref:t,style:{flexShrink:0,...o.style},onPointerDown:ae(o.onPointerDown,()=>{i.current===null&&(i.current=window.setInterval(r,50))}),onPointerMove:ae(o.onPointerMove,()=>{var l;(l=s.onItemLeave)==null||l.call(s),i.current===null&&(i.current=window.setInterval(r,50))}),onPointerLeave:ae(o.onPointerLeave,()=>{c()})})}),wm="SelectSeparator",Va=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return m.jsx(oe.div,{"aria-hidden":!0,...r,ref:t})});Va.displayName=wm;var Tr="SelectArrow",xm=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=qn(n),s=nt(Tr,n),i=rt(Tr,n);return s.open&&i.position==="popper"?m.jsx(oa,{...o,...r,ref:t}):null});xm.displayName=Tr;var Sm="SelectBubbleInput",Xa=d.forwardRef(({__scopeSelect:e,value:t,...n},r)=>{const o=d.useRef(null),s=fe(r,o),i=em(t);return d.useEffect(()=>{const a=o.current;if(!a)return;const c=window.HTMLSelectElement.prototype,f=Object.getOwnPropertyDescriptor(c,"value").set;if(i!==t&&f){const u=new Event("change",{bubbles:!0});f.call(a,t),a.dispatchEvent(u)}},[i,t]),m.jsx(oe.select,{...n,style:{...Ca,...n.style},ref:s,defaultValue:t})});Xa.displayName=Sm;function Za(e){return e===""||e===void 0}function Qa(e){const t=ft(e),n=d.useRef(""),r=d.useRef(0),o=d.useCallback(i=>{const a=n.current+i;t(a),function c(l){n.current=l,window.clearTimeout(r.current),l!==""&&(r.current=window.setTimeout(()=>c(""),1e3))}(a)},[t]),s=d.useCallback(()=>{n.current="",window.clearTimeout(r.current)},[]);return d.useEffect(()=>()=>window.clearTimeout(r.current),[]),[n,o,s]}function Ja(e,t,n){const o=t.length>1&&Array.from(t).every(l=>l===t[0])?t[0]:t,s=n?e.indexOf(n):-1;let i=km(e,Math.max(s,0));o.length===1&&(i=i.filter(l=>l!==n));const c=i.find(l=>l.textValue.toLowerCase().startsWith(o.toLowerCase()));return c!==n?c:void 0}function km(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var Mm=Na,ei=Oa,Cm=Pa,Nm=Aa,Dm=Ta,ti=Ra,Om=Wa,ni=La,ri=Ya,Em=za,Pm=qa,oi=Ua,si=Ga,ai=Va;const Rr=Mm,_r=Cm,Dn=d.forwardRef(({className:e,children:t,...n},r)=>m.jsxs(ei,{ref:r,className:U("flex h-10 w-full items-center justify-between rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background data-[placeholder]:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1",e),...n,children:[t,m.jsx(Nm,{asChild:!0,children:m.jsx(Ds,{strokeWidth:1.5,className:"h-5 w-5 ml-6 text-black"})})]}));Dn.displayName=ei.displayName;const ii=d.forwardRef(({className:e,...t},n)=>m.jsx(oi,{ref:n,className:U("flex cursor-default items-center justify-center py-1",e),...t,children:m.jsx(zl,{className:"h-4 w-4"})}));ii.displayName=oi.displayName;const ci=d.forwardRef(({className:e,...t},n)=>m.jsx(si,{ref:n,className:U("flex cursor-default items-center justify-center py-1",e),...t,children:m.jsx(Ds,{className:"h-4 w-4"})}));ci.displayName=si.displayName;const On=d.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>m.jsx(Dm,{children:m.jsxs(ti,{ref:o,className:U("relative z-50 max-h-[--radix-select-content-available-height] min-w-[8rem] overflow-y-auto overflow-x-hidden rounded-md border bg-popover text-popover-foreground shadow-md data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-select-content-transform-origin]",n==="popper"&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",e),position:n,...r,children:[m.jsx(ii,{}),m.jsx(Om,{className:U("p-1",n==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"),children:t}),m.jsx(ci,{})]})}));On.displayName=ti.displayName;const Am=d.forwardRef(({className:e,...t},n)=>m.jsx(ni,{ref:n,className:U("py-1.5 pl-8 pr-2 text-sm font-semibold",e),...t}));Am.displayName=ni.displayName;const En=d.forwardRef(({className:e,children:t,...n},r)=>m.jsxs(ri,{ref:r,className:U("relative flex w-full cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...n,children:[m.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:m.jsx(Pm,{children:m.jsx(Ns,{className:"h-4 w-4"})})}),m.jsx(Em,{children:t})]}));En.displayName=ri.displayName;const Tm=d.forwardRef(({className:e,...t},n)=>m.jsx(ai,{ref:n,className:U("-mx-1 my-1 h-px bg-muted",e),...t}));Tm.displayName=ai.displayName;const dr={},qt={};function Ut(e,t){try{const r=(dr[e]||(dr[e]=new Intl.DateTimeFormat("en-GB",{timeZone:e,hour:"numeric",timeZoneName:"longOffset"}).format))(t).split("GMT")[1]||"";return r in qt?qt[r]:Ho(r,r.split(":"))}catch{if(e in qt)return qt[e];const n=e==null?void 0:e.match(Rm);return n?Ho(e,n.slice(1)):NaN}}const Rm=/([+-]\d\d):?(\d\d)?/;function Ho(e,t){const n=+t[0],r=+(t[1]||0);return qt[e]=n>0?n*60+r:n*60-r}class We extends Date{constructor(...t){super(),t.length>1&&typeof t[t.length-1]=="string"&&(this.timeZone=t.pop()),this.internal=new Date,isNaN(Ut(this.timeZone,this))?this.setTime(NaN):t.length?typeof t[0]=="number"&&(t.length===1||t.length===2&&typeof t[1]!="number")?this.setTime(t[0]):typeof t[0]=="string"?this.setTime(+new Date(t[0])):t[0]instanceof Date?this.setTime(+t[0]):(this.setTime(+new Date(...t)),li(this),jr(this)):this.setTime(Date.now())}static tz(t,...n){return n.length?new We(...n,t):new We(Date.now(),t)}withTimeZone(t){return new We(+this,t)}getTimezoneOffset(){return-Ut(this.timeZone,this)}setTime(t){return Date.prototype.setTime.apply(this,arguments),jr(this),+this}[Symbol.for("constructDateFrom")](t){return new We(+new Date(t),this.timeZone)}}const qo=/^(get|set)(?!UTC)/;Object.getOwnPropertyNames(Date.prototype).forEach(e=>{if(!qo.test(e))return;const t=e.replace(qo,"$1UTC");We.prototype[t]&&(e.startsWith("get")?We.prototype[e]=function(){return this.internal[t]()}:(We.prototype[e]=function(){return Date.prototype[t].apply(this.internal,arguments),_m(this),+this},We.prototype[t]=function(){return Date.prototype[t].apply(this,arguments),jr(this),+this}))});function jr(e){e.internal.setTime(+e),e.internal.setUTCMinutes(e.internal.getUTCMinutes()-e.getTimezoneOffset())}function _m(e){Date.prototype.setFullYear.call(e,e.internal.getUTCFullYear(),e.internal.getUTCMonth(),e.internal.getUTCDate()),Date.prototype.setHours.call(e,e.internal.getUTCHours(),e.internal.getUTCMinutes(),e.internal.getUTCSeconds(),e.internal.getUTCMilliseconds()),li(e)}function li(e){const t=Ut(e.timeZone,e),n=new Date(+e);n.setUTCHours(n.getUTCHours()-1);const r=-new Date(+e).getTimezoneOffset(),o=-new Date(+n).getTimezoneOffset(),s=r-o,i=Date.prototype.getHours.apply(e)!==e.internal.getUTCHours();s&&i&&e.internal.setUTCMinutes(e.internal.getUTCMinutes()+s);const a=r-t;a&&Date.prototype.setUTCMinutes.call(e,Date.prototype.getUTCMinutes.call(e)+a);const c=Ut(e.timeZone,e),f=-new Date(+e).getTimezoneOffset()-c,u=c!==t,h=f-a;if(u&&h){Date.prototype.setUTCMinutes.call(e,Date.prototype.getUTCMinutes.call(e)+h);const g=Ut(e.timeZone,e),b=c-g;b&&(e.internal.setUTCMinutes(e.internal.getUTCMinutes()+b),Date.prototype.setUTCMinutes.call(e,Date.prototype.getUTCMinutes.call(e)+b))}}class ye extends We{static tz(t,...n){return n.length?new ye(...n,t):new ye(Date.now(),t)}toISOString(){const[t,n,r]=this.tzComponents(),o=`${t}${n}:${r}`;return this.internal.toISOString().slice(0,-1)+o}toString(){return`${this.toDateString()} ${this.toTimeString()}`}toDateString(){const[t,n,r,o]=this.internal.toUTCString().split(" ");return`${t==null?void 0:t.slice(0,-1)} ${r} ${n} ${o}`}toTimeString(){const t=this.internal.toUTCString().split(" ")[4],[n,r,o]=this.tzComponents();return`${t} GMT${n}${r}${o} (${jm(this.timeZone,this)})`}toLocaleString(t,n){return Date.prototype.toLocaleString.call(this,t,{...n,timeZone:(n==null?void 0:n.timeZone)||this.timeZone})}toLocaleDateString(t,n){return Date.prototype.toLocaleDateString.call(this,t,{...n,timeZone:(n==null?void 0:n.timeZone)||this.timeZone})}toLocaleTimeString(t,n){return Date.prototype.toLocaleTimeString.call(this,t,{...n,timeZone:(n==null?void 0:n.timeZone)||this.timeZone})}tzComponents(){const t=this.getTimezoneOffset(),n=t>0?"-":"+",r=String(Math.floor(Math.abs(t)/60)).padStart(2,"0"),o=String(Math.abs(t)%60).padStart(2,"0");return[n,r,o]}withTimeZone(t){return new ye(+this,t)}[Symbol.for("constructDateFrom")](t){return new ye(+new Date(t),this.timeZone)}}function jm(e,t){return new Intl.DateTimeFormat("en-GB",{timeZone:e,timeZoneName:"long"}).format(t).slice(12)}var q;(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"})(q||(q={}));var de;(function(e){e.disabled="disabled",e.hidden="hidden",e.outside="outside",e.focused="focused",e.today="today"})(de||(de={}));var Ee;(function(e){e.range_end="range_end",e.range_middle="range_middle",e.range_start="range_start",e.selected="selected"})(Ee||(Ee={}));var Se;(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"})(Se||(Se={}));const ui=6048e5,Im=864e5,Uo=Symbol.for("constructDateFrom");function pe(e,t){return typeof e=="function"?e(t):e&&typeof e=="object"&&Uo in e?e[Uo](t):e instanceof Date?new e.constructor(t):new Date(t)}function le(e,t){return pe(t||e,e)}function di(e,t,n){const r=le(e,n==null?void 0:n.in);return isNaN(t)?pe(e,NaN):(t&&r.setDate(r.getDate()+t),r)}function fi(e,t,n){const r=le(e,n==null?void 0:n.in);if(isNaN(t))return pe(e,NaN);if(!t)return r;const o=r.getDate(),s=pe(e,r.getTime());s.setMonth(r.getMonth()+t+1,0);const i=s.getDate();return o>=i?s:(r.setFullYear(s.getFullYear(),s.getMonth(),o),r)}let Wm={};function tn(){return Wm}function At(e,t){var a,c,l,f;const n=tn(),r=(t==null?void 0:t.weekStartsOn)??((c=(a=t==null?void 0:t.locale)==null?void 0:a.options)==null?void 0:c.weekStartsOn)??n.weekStartsOn??((f=(l=n.locale)==null?void 0:l.options)==null?void 0:f.weekStartsOn)??0,o=le(e,t==null?void 0:t.in),s=o.getDay(),i=(s<r?7:0)+s-r;return o.setDate(o.getDate()-i),o.setHours(0,0,0,0),o}function Vt(e,t){return At(e,{...t,weekStartsOn:1})}function mi(e,t){const n=le(e,t==null?void 0:t.in),r=n.getFullYear(),o=pe(n,0);o.setFullYear(r+1,0,4),o.setHours(0,0,0,0);const s=Vt(o),i=pe(n,0);i.setFullYear(r,0,4),i.setHours(0,0,0,0);const a=Vt(i);return n.getTime()>=s.getTime()?r+1:n.getTime()>=a.getTime()?r:r-1}function Go(e){const t=le(e),n=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return n.setUTCFullYear(t.getFullYear()),+e-+n}function Ft(e,...t){const n=pe.bind(null,t.find(r=>typeof r=="object"));return t.map(n)}function Xt(e,t){const n=le(e,t==null?void 0:t.in);return n.setHours(0,0,0,0),n}function hi(e,t,n){const[r,o]=Ft(n==null?void 0:n.in,e,t),s=Xt(r),i=Xt(o),a=+s-Go(s),c=+i-Go(i);return Math.round((a-c)/Im)}function $m(e,t){const n=mi(e,t),r=pe(e,0);return r.setFullYear(n,0,4),r.setHours(0,0,0,0),Vt(r)}function Fm(e,t,n){return di(e,t*7,n)}function Lm(e,t,n){return fi(e,t*12,n)}function Bm(e,t){let n,r=t==null?void 0:t.in;return e.forEach(o=>{!r&&typeof o=="object"&&(r=pe.bind(null,o));const s=le(o,r);(!n||n<s||isNaN(+s))&&(n=s)}),pe(r,n||NaN)}function Ym(e,t){let n,r=t==null?void 0:t.in;return e.forEach(o=>{!r&&typeof o=="object"&&(r=pe.bind(null,o));const s=le(o,r);(!n||n>s||isNaN(+s))&&(n=s)}),pe(r,n||NaN)}function zm(e,t,n){const[r,o]=Ft(n==null?void 0:n.in,e,t);return+Xt(r)==+Xt(o)}function pi(e){return e instanceof Date||typeof e=="object"&&Object.prototype.toString.call(e)==="[object Date]"}function Hm(e){return!(!pi(e)&&typeof e!="number"||isNaN(+le(e)))}function qm(e,t,n){const[r,o]=Ft(n==null?void 0:n.in,e,t),s=r.getFullYear()-o.getFullYear(),i=r.getMonth()-o.getMonth();return s*12+i}function Um(e,t){const n=le(e,t==null?void 0:t.in),r=n.getMonth();return n.setFullYear(n.getFullYear(),r+1,0),n.setHours(23,59,59,999),n}function Gm(e,t){const[n,r]=Ft(e,t.start,t.end);return{start:n,end:r}}function Km(e,t){const{start:n,end:r}=Gm(t==null?void 0:t.in,e);let o=+n>+r;const s=o?+n:+r,i=o?r:n;i.setHours(0,0,0,0),i.setDate(1);let a=1;const c=[];for(;+i<=s;)c.push(pe(n,i)),i.setMonth(i.getMonth()+a);return o?c.reverse():c}function Vm(e,t){const n=le(e,t==null?void 0:t.in);return n.setDate(1),n.setHours(0,0,0,0),n}function Xm(e,t){const n=le(e,t==null?void 0:t.in),r=n.getFullYear();return n.setFullYear(r+1,0,0),n.setHours(23,59,59,999),n}function gi(e,t){const n=le(e,t==null?void 0:t.in);return n.setFullYear(n.getFullYear(),0,1),n.setHours(0,0,0,0),n}function vi(e,t){var a,c,l,f;const n=tn(),r=(t==null?void 0:t.weekStartsOn)??((c=(a=t==null?void 0:t.locale)==null?void 0:a.options)==null?void 0:c.weekStartsOn)??n.weekStartsOn??((f=(l=n.locale)==null?void 0:l.options)==null?void 0:f.weekStartsOn)??0,o=le(e,t==null?void 0:t.in),s=o.getDay(),i=(s<r?-7:0)+6-(s-r);return o.setDate(o.getDate()+i),o.setHours(23,59,59,999),o}function Zm(e,t){return vi(e,{...t,weekStartsOn:1})}const Qm={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},Jm=(e,t,n)=>{let r;const o=Qm[e];return typeof o=="string"?r=o:t===1?r=o.one:r=o.other.replace("{{count}}",t.toString()),n!=null&&n.addSuffix?n.comparison&&n.comparison>0?"in "+r:r+" ago":r};function fr(e){return(t={})=>{const n=t.width?String(t.width):e.defaultWidth;return e.formats[n]||e.formats[e.defaultWidth]}}const eh={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},th={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},nh={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},rh={date:fr({formats:eh,defaultWidth:"full"}),time:fr({formats:th,defaultWidth:"full"}),dateTime:fr({formats:nh,defaultWidth:"full"})},oh={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},sh=(e,t,n,r)=>oh[e];function Bt(e){return(t,n)=>{const r=n!=null&&n.context?String(n.context):"standalone";let o;if(r==="formatting"&&e.formattingValues){const i=e.defaultFormattingWidth||e.defaultWidth,a=n!=null&&n.width?String(n.width):i;o=e.formattingValues[a]||e.formattingValues[i]}else{const i=e.defaultWidth,a=n!=null&&n.width?String(n.width):e.defaultWidth;o=e.values[a]||e.values[i]}const s=e.argumentCallback?e.argumentCallback(t):t;return o[s]}}const ah={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},ih={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},ch={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},lh={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},uh={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},dh={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},fh=(e,t)=>{const n=Number(e),r=n%100;if(r>20||r<10)switch(r%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"},mh={ordinalNumber:fh,era:Bt({values:ah,defaultWidth:"wide"}),quarter:Bt({values:ih,defaultWidth:"wide",argumentCallback:e=>e-1}),month:Bt({values:ch,defaultWidth:"wide"}),day:Bt({values:lh,defaultWidth:"wide"}),dayPeriod:Bt({values:uh,defaultWidth:"wide",formattingValues:dh,defaultFormattingWidth:"wide"})};function Yt(e){return(t,n={})=>{const r=n.width,o=r&&e.matchPatterns[r]||e.matchPatterns[e.defaultMatchWidth],s=t.match(o);if(!s)return null;const i=s[0],a=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],c=Array.isArray(a)?ph(a,u=>u.test(i)):hh(a,u=>u.test(i));let l;l=e.valueCallback?e.valueCallback(c):c,l=n.valueCallback?n.valueCallback(l):l;const f=t.slice(i.length);return{value:l,rest:f}}}function hh(e,t){for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t(e[n]))return n}function ph(e,t){for(let n=0;n<e.length;n++)if(t(e[n]))return n}function gh(e){return(t,n={})=>{const r=t.match(e.matchPattern);if(!r)return null;const o=r[0],s=t.match(e.parsePattern);if(!s)return null;let i=e.valueCallback?e.valueCallback(s[0]):s[0];i=n.valueCallback?n.valueCallback(i):i;const a=t.slice(o.length);return{value:i,rest:a}}}const vh=/^(\d+)(th|st|nd|rd)?/i,yh=/\d+/i,bh={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},wh={any:[/^b/i,/^(a|c)/i]},xh={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},Sh={any:[/1/i,/2/i,/3/i,/4/i]},kh={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},Mh={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},Ch={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},Nh={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},Dh={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},Oh={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},Eh={ordinalNumber:gh({matchPattern:vh,parsePattern:yh,valueCallback:e=>parseInt(e,10)}),era:Yt({matchPatterns:bh,defaultMatchWidth:"wide",parsePatterns:wh,defaultParseWidth:"any"}),quarter:Yt({matchPatterns:xh,defaultMatchWidth:"wide",parsePatterns:Sh,defaultParseWidth:"any",valueCallback:e=>e+1}),month:Yt({matchPatterns:kh,defaultMatchWidth:"wide",parsePatterns:Mh,defaultParseWidth:"any"}),day:Yt({matchPatterns:Ch,defaultMatchWidth:"wide",parsePatterns:Nh,defaultParseWidth:"any"}),dayPeriod:Yt({matchPatterns:Dh,defaultMatchWidth:"any",parsePatterns:Oh,defaultParseWidth:"any"})},no={code:"en-US",formatDistance:Jm,formatLong:rh,formatRelative:sh,localize:mh,match:Eh,options:{weekStartsOn:0,firstWeekContainsDate:1}};function Ph(e,t){const n=le(e,t==null?void 0:t.in);return hi(n,gi(n))+1}function yi(e,t){const n=le(e,t==null?void 0:t.in),r=+Vt(n)-+$m(n);return Math.round(r/ui)+1}function bi(e,t){var f,u,h,g;const n=le(e,t==null?void 0:t.in),r=n.getFullYear(),o=tn(),s=(t==null?void 0:t.firstWeekContainsDate)??((u=(f=t==null?void 0:t.locale)==null?void 0:f.options)==null?void 0:u.firstWeekContainsDate)??o.firstWeekContainsDate??((g=(h=o.locale)==null?void 0:h.options)==null?void 0:g.firstWeekContainsDate)??1,i=pe((t==null?void 0:t.in)||e,0);i.setFullYear(r+1,0,s),i.setHours(0,0,0,0);const a=At(i,t),c=pe((t==null?void 0:t.in)||e,0);c.setFullYear(r,0,s),c.setHours(0,0,0,0);const l=At(c,t);return+n>=+a?r+1:+n>=+l?r:r-1}function Ah(e,t){var a,c,l,f;const n=tn(),r=(t==null?void 0:t.firstWeekContainsDate)??((c=(a=t==null?void 0:t.locale)==null?void 0:a.options)==null?void 0:c.firstWeekContainsDate)??n.firstWeekContainsDate??((f=(l=n.locale)==null?void 0:l.options)==null?void 0:f.firstWeekContainsDate)??1,o=bi(e,t),s=pe((t==null?void 0:t.in)||e,0);return s.setFullYear(o,0,r),s.setHours(0,0,0,0),At(s,t)}function wi(e,t){const n=le(e,t==null?void 0:t.in),r=+At(n,t)-+Ah(n,t);return Math.round(r/ui)+1}function ce(e,t){const n=e<0?"-":"",r=Math.abs(e).toString().padStart(t,"0");return n+r}const Xe={y(e,t){const n=e.getFullYear(),r=n>0?n:1-n;return ce(t==="yy"?r%100:r,t.length)},M(e,t){const n=e.getMonth();return t==="M"?String(n+1):ce(n+1,2)},d(e,t){return ce(e.getDate(),t.length)},a(e,t){const n=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.toUpperCase();case"aaa":return n;case"aaaaa":return n[0];case"aaaa":default:return n==="am"?"a.m.":"p.m."}},h(e,t){return ce(e.getHours()%12||12,t.length)},H(e,t){return ce(e.getHours(),t.length)},m(e,t){return ce(e.getMinutes(),t.length)},s(e,t){return ce(e.getSeconds(),t.length)},S(e,t){const n=t.length,r=e.getMilliseconds(),o=Math.trunc(r*Math.pow(10,n-3));return ce(o,t.length)}},Mt={midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},Ko={G:function(e,t,n){const r=e.getFullYear()>0?1:0;switch(t){case"G":case"GG":case"GGG":return n.era(r,{width:"abbreviated"});case"GGGGG":return n.era(r,{width:"narrow"});case"GGGG":default:return n.era(r,{width:"wide"})}},y:function(e,t,n){if(t==="yo"){const r=e.getFullYear(),o=r>0?r:1-r;return n.ordinalNumber(o,{unit:"year"})}return Xe.y(e,t)},Y:function(e,t,n,r){const o=bi(e,r),s=o>0?o:1-o;if(t==="YY"){const i=s%100;return ce(i,2)}return t==="Yo"?n.ordinalNumber(s,{unit:"year"}):ce(s,t.length)},R:function(e,t){const n=mi(e);return ce(n,t.length)},u:function(e,t){const n=e.getFullYear();return ce(n,t.length)},Q:function(e,t,n){const r=Math.ceil((e.getMonth()+1)/3);switch(t){case"Q":return String(r);case"QQ":return ce(r,2);case"Qo":return n.ordinalNumber(r,{unit:"quarter"});case"QQQ":return n.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return n.quarter(r,{width:"narrow",context:"formatting"});case"QQQQ":default:return n.quarter(r,{width:"wide",context:"formatting"})}},q:function(e,t,n){const r=Math.ceil((e.getMonth()+1)/3);switch(t){case"q":return String(r);case"qq":return ce(r,2);case"qo":return n.ordinalNumber(r,{unit:"quarter"});case"qqq":return n.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return n.quarter(r,{width:"narrow",context:"standalone"});case"qqqq":default:return n.quarter(r,{width:"wide",context:"standalone"})}},M:function(e,t,n){const r=e.getMonth();switch(t){case"M":case"MM":return Xe.M(e,t);case"Mo":return n.ordinalNumber(r+1,{unit:"month"});case"MMM":return n.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return n.month(r,{width:"narrow",context:"formatting"});case"MMMM":default:return n.month(r,{width:"wide",context:"formatting"})}},L:function(e,t,n){const r=e.getMonth();switch(t){case"L":return String(r+1);case"LL":return ce(r+1,2);case"Lo":return n.ordinalNumber(r+1,{unit:"month"});case"LLL":return n.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return n.month(r,{width:"narrow",context:"standalone"});case"LLLL":default:return n.month(r,{width:"wide",context:"standalone"})}},w:function(e,t,n,r){const o=wi(e,r);return t==="wo"?n.ordinalNumber(o,{unit:"week"}):ce(o,t.length)},I:function(e,t,n){const r=yi(e);return t==="Io"?n.ordinalNumber(r,{unit:"week"}):ce(r,t.length)},d:function(e,t,n){return t==="do"?n.ordinalNumber(e.getDate(),{unit:"date"}):Xe.d(e,t)},D:function(e,t,n){const r=Ph(e);return t==="Do"?n.ordinalNumber(r,{unit:"dayOfYear"}):ce(r,t.length)},E:function(e,t,n){const r=e.getDay();switch(t){case"E":case"EE":case"EEE":return n.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return n.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(r,{width:"short",context:"formatting"});case"EEEE":default:return n.day(r,{width:"wide",context:"formatting"})}},e:function(e,t,n,r){const o=e.getDay(),s=(o-r.weekStartsOn+8)%7||7;switch(t){case"e":return String(s);case"ee":return ce(s,2);case"eo":return n.ordinalNumber(s,{unit:"day"});case"eee":return n.day(o,{width:"abbreviated",context:"formatting"});case"eeeee":return n.day(o,{width:"narrow",context:"formatting"});case"eeeeee":return n.day(o,{width:"short",context:"formatting"});case"eeee":default:return n.day(o,{width:"wide",context:"formatting"})}},c:function(e,t,n,r){const o=e.getDay(),s=(o-r.weekStartsOn+8)%7||7;switch(t){case"c":return String(s);case"cc":return ce(s,t.length);case"co":return n.ordinalNumber(s,{unit:"day"});case"ccc":return n.day(o,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(o,{width:"narrow",context:"standalone"});case"cccccc":return n.day(o,{width:"short",context:"standalone"});case"cccc":default:return n.day(o,{width:"wide",context:"standalone"})}},i:function(e,t,n){const r=e.getDay(),o=r===0?7:r;switch(t){case"i":return String(o);case"ii":return ce(o,t.length);case"io":return n.ordinalNumber(o,{unit:"day"});case"iii":return n.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return n.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return n.day(r,{width:"short",context:"formatting"});case"iiii":default:return n.day(r,{width:"wide",context:"formatting"})}},a:function(e,t,n){const o=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"aaa":return n.dayPeriod(o,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return n.dayPeriod(o,{width:"narrow",context:"formatting"});case"aaaa":default:return n.dayPeriod(o,{width:"wide",context:"formatting"})}},b:function(e,t,n){const r=e.getHours();let o;switch(r===12?o=Mt.noon:r===0?o=Mt.midnight:o=r/12>=1?"pm":"am",t){case"b":case"bb":return n.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"bbb":return n.dayPeriod(o,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return n.dayPeriod(o,{width:"narrow",context:"formatting"});case"bbbb":default:return n.dayPeriod(o,{width:"wide",context:"formatting"})}},B:function(e,t,n){const r=e.getHours();let o;switch(r>=17?o=Mt.evening:r>=12?o=Mt.afternoon:r>=4?o=Mt.morning:o=Mt.night,t){case"B":case"BB":case"BBB":return n.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"BBBBB":return n.dayPeriod(o,{width:"narrow",context:"formatting"});case"BBBB":default:return n.dayPeriod(o,{width:"wide",context:"formatting"})}},h:function(e,t,n){if(t==="ho"){let r=e.getHours()%12;return r===0&&(r=12),n.ordinalNumber(r,{unit:"hour"})}return Xe.h(e,t)},H:function(e,t,n){return t==="Ho"?n.ordinalNumber(e.getHours(),{unit:"hour"}):Xe.H(e,t)},K:function(e,t,n){const r=e.getHours()%12;return t==="Ko"?n.ordinalNumber(r,{unit:"hour"}):ce(r,t.length)},k:function(e,t,n){let r=e.getHours();return r===0&&(r=24),t==="ko"?n.ordinalNumber(r,{unit:"hour"}):ce(r,t.length)},m:function(e,t,n){return t==="mo"?n.ordinalNumber(e.getMinutes(),{unit:"minute"}):Xe.m(e,t)},s:function(e,t,n){return t==="so"?n.ordinalNumber(e.getSeconds(),{unit:"second"}):Xe.s(e,t)},S:function(e,t){return Xe.S(e,t)},X:function(e,t,n){const r=e.getTimezoneOffset();if(r===0)return"Z";switch(t){case"X":return Xo(r);case"XXXX":case"XX":return ct(r);case"XXXXX":case"XXX":default:return ct(r,":")}},x:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"x":return Xo(r);case"xxxx":case"xx":return ct(r);case"xxxxx":case"xxx":default:return ct(r,":")}},O:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"O":case"OO":case"OOO":return"GMT"+Vo(r,":");case"OOOO":default:return"GMT"+ct(r,":")}},z:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"z":case"zz":case"zzz":return"GMT"+Vo(r,":");case"zzzz":default:return"GMT"+ct(r,":")}},t:function(e,t,n){const r=Math.trunc(+e/1e3);return ce(r,t.length)},T:function(e,t,n){return ce(+e,t.length)}};function Vo(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),o=Math.trunc(r/60),s=r%60;return s===0?n+String(o):n+String(o)+t+ce(s,2)}function Xo(e,t){return e%60===0?(e>0?"-":"+")+ce(Math.abs(e)/60,2):ct(e,t)}function ct(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),o=ce(Math.trunc(r/60),2),s=ce(r%60,2);return n+o+t+s}const Zo=(e,t)=>{switch(e){case"P":return t.date({width:"short"});case"PP":return t.date({width:"medium"});case"PPP":return t.date({width:"long"});case"PPPP":default:return t.date({width:"full"})}},xi=(e,t)=>{switch(e){case"p":return t.time({width:"short"});case"pp":return t.time({width:"medium"});case"ppp":return t.time({width:"long"});case"pppp":default:return t.time({width:"full"})}},Th=(e,t)=>{const n=e.match(/(P+)(p+)?/)||[],r=n[1],o=n[2];if(!o)return Zo(e,t);let s;switch(r){case"P":s=t.dateTime({width:"short"});break;case"PP":s=t.dateTime({width:"medium"});break;case"PPP":s=t.dateTime({width:"long"});break;case"PPPP":default:s=t.dateTime({width:"full"});break}return s.replace("{{date}}",Zo(r,t)).replace("{{time}}",xi(o,t))},Rh={p:xi,P:Th},_h=/^D+$/,jh=/^Y+$/,Ih=["D","DD","YY","YYYY"];function Wh(e){return _h.test(e)}function $h(e){return jh.test(e)}function Fh(e,t,n){const r=Lh(e,t,n);if(console.warn(r),Ih.includes(e))throw new RangeError(r)}function Lh(e,t,n){const r=e[0]==="Y"?"years":"days of the month";return`Use \`${e.toLowerCase()}\` instead of \`${e}\` (in \`${t}\`) for formatting ${r} to the input \`${n}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`}const Bh=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,Yh=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,zh=/^'([^]*?)'?$/,Hh=/''/g,qh=/[a-zA-Z]/;function Uh(e,t,n){var f,u,h,g,b,p,v,S;const r=tn(),o=(n==null?void 0:n.locale)??r.locale??no,s=(n==null?void 0:n.firstWeekContainsDate)??((u=(f=n==null?void 0:n.locale)==null?void 0:f.options)==null?void 0:u.firstWeekContainsDate)??r.firstWeekContainsDate??((g=(h=r.locale)==null?void 0:h.options)==null?void 0:g.firstWeekContainsDate)??1,i=(n==null?void 0:n.weekStartsOn)??((p=(b=n==null?void 0:n.locale)==null?void 0:b.options)==null?void 0:p.weekStartsOn)??r.weekStartsOn??((S=(v=r.locale)==null?void 0:v.options)==null?void 0:S.weekStartsOn)??0,a=le(e,n==null?void 0:n.in);if(!Hm(a))throw new RangeError("Invalid time value");let c=t.match(Yh).map(y=>{const x=y[0];if(x==="p"||x==="P"){const O=Rh[x];return O(y,o.formatLong)}return y}).join("").match(Bh).map(y=>{if(y==="''")return{isToken:!1,value:"'"};const x=y[0];if(x==="'")return{isToken:!1,value:Gh(y)};if(Ko[x])return{isToken:!0,value:y};if(x.match(qh))throw new RangeError("Format string contains an unescaped latin alphabet character `"+x+"`");return{isToken:!1,value:y}});o.localize.preprocessor&&(c=o.localize.preprocessor(a,c));const l={firstWeekContainsDate:s,weekStartsOn:i,locale:o};return c.map(y=>{if(!y.isToken)return y.value;const x=y.value;(!(n!=null&&n.useAdditionalWeekYearTokens)&&$h(x)||!(n!=null&&n.useAdditionalDayOfYearTokens)&&Wh(x))&&Fh(x,t,String(e));const O=Ko[x[0]];return O(a,x,o.localize,l)}).join("")}function Gh(e){const t=e.match(zh);return t?t[1].replace(Hh,"'"):e}function Kh(e,t){const n=le(e,t==null?void 0:t.in),r=n.getFullYear(),o=n.getMonth(),s=pe(n,0);return s.setFullYear(r,o+1,0),s.setHours(0,0,0,0),s.getDate()}function Vh(e,t){return le(e,t==null?void 0:t.in).getMonth()}function Xh(e,t){return le(e,t==null?void 0:t.in).getFullYear()}function Zh(e,t){return+le(e)>+le(t)}function Qh(e,t){return+le(e)<+le(t)}function Jh(e,t,n){const[r,o]=Ft(n==null?void 0:n.in,e,t);return r.getFullYear()===o.getFullYear()&&r.getMonth()===o.getMonth()}function ep(e,t,n){const[r,o]=Ft(n==null?void 0:n.in,e,t);return r.getFullYear()===o.getFullYear()}function tp(e,t,n){const r=le(e,n==null?void 0:n.in),o=r.getFullYear(),s=r.getDate(),i=pe(e,0);i.setFullYear(o,t,15),i.setHours(0,0,0,0);const a=Kh(i);return r.setMonth(t,Math.min(s,a)),r}function np(e,t,n){const r=le(e,n==null?void 0:n.in);return isNaN(+r)?pe(e,NaN):(r.setFullYear(t),r)}const Qo=5,rp=4;function op(e,t){const n=t.startOfMonth(e),r=n.getDay()>0?n.getDay():7,o=t.addDays(e,-r+1),s=t.addDays(o,Qo*7-1);return t.getMonth(e)===t.getMonth(s)?Qo:rp}function Si(e,t){const n=t.startOfMonth(e),r=n.getDay();return r===1?n:r===0?t.addDays(n,-1*6):t.addDays(n,-1*(r-1))}function sp(e,t){const n=Si(e,t),r=op(e,t);return t.addDays(n,r*7-1)}class Ge{constructor(t,n){this.Date=Date,this.today=()=>{var r;return(r=this.overrides)!=null&&r.today?this.overrides.today():this.options.timeZone?ye.tz(this.options.timeZone):new this.Date},this.newDate=(r,o,s)=>{var i;return(i=this.overrides)!=null&&i.newDate?this.overrides.newDate(r,o,s):this.options.timeZone?new ye(r,o,s,this.options.timeZone):new Date(r,o,s)},this.addDays=(r,o)=>{var s;return(s=this.overrides)!=null&&s.addDays?this.overrides.addDays(r,o):di(r,o)},this.addMonths=(r,o)=>{var s;return(s=this.overrides)!=null&&s.addMonths?this.overrides.addMonths(r,o):fi(r,o)},this.addWeeks=(r,o)=>{var s;return(s=this.overrides)!=null&&s.addWeeks?this.overrides.addWeeks(r,o):Fm(r,o)},this.addYears=(r,o)=>{var s;return(s=this.overrides)!=null&&s.addYears?this.overrides.addYears(r,o):Lm(r,o)},this.differenceInCalendarDays=(r,o)=>{var s;return(s=this.overrides)!=null&&s.differenceInCalendarDays?this.overrides.differenceInCalendarDays(r,o):hi(r,o)},this.differenceInCalendarMonths=(r,o)=>{var s;return(s=this.overrides)!=null&&s.differenceInCalendarMonths?this.overrides.differenceInCalendarMonths(r,o):qm(r,o)},this.eachMonthOfInterval=r=>{var o;return(o=this.overrides)!=null&&o.eachMonthOfInterval?this.overrides.eachMonthOfInterval(r):Km(r)},this.endOfBroadcastWeek=r=>{var o;return(o=this.overrides)!=null&&o.endOfBroadcastWeek?this.overrides.endOfBroadcastWeek(r):sp(r,this)},this.endOfISOWeek=r=>{var o;return(o=this.overrides)!=null&&o.endOfISOWeek?this.overrides.endOfISOWeek(r):Zm(r)},this.endOfMonth=r=>{var o;return(o=this.overrides)!=null&&o.endOfMonth?this.overrides.endOfMonth(r):Um(r)},this.endOfWeek=(r,o)=>{var s;return(s=this.overrides)!=null&&s.endOfWeek?this.overrides.endOfWeek(r,o):vi(r,this.options)},this.endOfYear=r=>{var o;return(o=this.overrides)!=null&&o.endOfYear?this.overrides.endOfYear(r):Xm(r)},this.format=(r,o,s)=>{var a;const i=(a=this.overrides)!=null&&a.format?this.overrides.format(r,o,this.options):Uh(r,o,this.options);return this.options.numerals&&this.options.numerals!=="latn"?this.replaceDigits(i):i},this.getISOWeek=r=>{var o;return(o=this.overrides)!=null&&o.getISOWeek?this.overrides.getISOWeek(r):yi(r)},this.getMonth=(r,o)=>{var s;return(s=this.overrides)!=null&&s.getMonth?this.overrides.getMonth(r,this.options):Vh(r,this.options)},this.getYear=(r,o)=>{var s;return(s=this.overrides)!=null&&s.getYear?this.overrides.getYear(r,this.options):Xh(r,this.options)},this.getWeek=(r,o)=>{var s;return(s=this.overrides)!=null&&s.getWeek?this.overrides.getWeek(r,this.options):wi(r,this.options)},this.isAfter=(r,o)=>{var s;return(s=this.overrides)!=null&&s.isAfter?this.overrides.isAfter(r,o):Zh(r,o)},this.isBefore=(r,o)=>{var s;return(s=this.overrides)!=null&&s.isBefore?this.overrides.isBefore(r,o):Qh(r,o)},this.isDate=r=>{var o;return(o=this.overrides)!=null&&o.isDate?this.overrides.isDate(r):pi(r)},this.isSameDay=(r,o)=>{var s;return(s=this.overrides)!=null&&s.isSameDay?this.overrides.isSameDay(r,o):zm(r,o)},this.isSameMonth=(r,o)=>{var s;return(s=this.overrides)!=null&&s.isSameMonth?this.overrides.isSameMonth(r,o):Jh(r,o)},this.isSameYear=(r,o)=>{var s;return(s=this.overrides)!=null&&s.isSameYear?this.overrides.isSameYear(r,o):ep(r,o)},this.max=r=>{var o;return(o=this.overrides)!=null&&o.max?this.overrides.max(r):Bm(r)},this.min=r=>{var o;return(o=this.overrides)!=null&&o.min?this.overrides.min(r):Ym(r)},this.setMonth=(r,o)=>{var s;return(s=this.overrides)!=null&&s.setMonth?this.overrides.setMonth(r,o):tp(r,o)},this.setYear=(r,o)=>{var s;return(s=this.overrides)!=null&&s.setYear?this.overrides.setYear(r,o):np(r,o)},this.startOfBroadcastWeek=(r,o)=>{var s;return(s=this.overrides)!=null&&s.startOfBroadcastWeek?this.overrides.startOfBroadcastWeek(r,this):Si(r,this)},this.startOfDay=r=>{var o;return(o=this.overrides)!=null&&o.startOfDay?this.overrides.startOfDay(r):Xt(r)},this.startOfISOWeek=r=>{var o;return(o=this.overrides)!=null&&o.startOfISOWeek?this.overrides.startOfISOWeek(r):Vt(r)},this.startOfMonth=r=>{var o;return(o=this.overrides)!=null&&o.startOfMonth?this.overrides.startOfMonth(r):Vm(r)},this.startOfWeek=(r,o)=>{var s;return(s=this.overrides)!=null&&s.startOfWeek?this.overrides.startOfWeek(r,this.options):At(r,this.options)},this.startOfYear=r=>{var o;return(o=this.overrides)!=null&&o.startOfYear?this.overrides.startOfYear(r):gi(r)},this.options={locale:no,...t},this.overrides=n}getDigitMap(){const{numerals:t="latn"}=this.options,n=new Intl.NumberFormat("en-US",{numberingSystem:t}),r={};for(let o=0;o<10;o++)r[o.toString()]=n.format(o);return r}replaceDigits(t){const n=this.getDigitMap();return t.replace(/\d/g,r=>n[r]||r)}formatNumber(t){return this.replaceDigits(t.toString())}}const Be=new Ge;class ki{constructor(t,n,r=Be){this.date=t,this.displayMonth=n,this.outside=!!(n&&!r.isSameMonth(t,n)),this.dateLib=r}isEqualTo(t){return this.dateLib.isSameDay(t.date,this.date)&&this.dateLib.isSameMonth(t.displayMonth,this.displayMonth)}}class ap{constructor(t,n){this.date=t,this.weeks=n}}class ip{constructor(t,n){this.days=n,this.weekNumber=t}}function ze(e,t,n=!1,r=Be){let{from:o,to:s}=e;const{differenceInCalendarDays:i,isSameDay:a}=r;return o&&s?(i(s,o)<0&&([o,s]=[s,o]),i(t,o)>=(n?1:0)&&i(s,t)>=(n?1:0)):!n&&s?a(s,t):!n&&o?a(o,t):!1}function Mi(e){return!!(e&&typeof e=="object"&&"before"in e&&"after"in e)}function ro(e){return!!(e&&typeof e=="object"&&"from"in e)}function Ci(e){return!!(e&&typeof e=="object"&&"after"in e)}function Ni(e){return!!(e&&typeof e=="object"&&"before"in e)}function Di(e){return!!(e&&typeof e=="object"&&"dayOfWeek"in e)}function Oi(e,t){return Array.isArray(e)&&e.every(t.isDate)}function He(e,t,n=Be){const r=Array.isArray(t)?t:[t],{isSameDay:o,differenceInCalendarDays:s,isAfter:i}=n;return r.some(a=>{if(typeof a=="boolean")return a;if(n.isDate(a))return o(e,a);if(Oi(a,n))return a.includes(e);if(ro(a))return ze(a,e,!1,n);if(Di(a))return Array.isArray(a.dayOfWeek)?a.dayOfWeek.includes(e.getDay()):a.dayOfWeek===e.getDay();if(Mi(a)){const c=s(a.before,e),l=s(a.after,e),f=c>0,u=l<0;return i(a.before,a.after)?u&&f:f||u}return Ci(a)?s(e,a.after)>0:Ni(a)?s(a.before,e)>0:typeof a=="function"?a(e):!1})}function cp(e,t,n,r,o){const{disabled:s,hidden:i,modifiers:a,showOutsideDays:c,broadcastCalendar:l,today:f}=t,{isSameDay:u,isSameMonth:h,startOfMonth:g,isBefore:b,endOfMonth:p,isAfter:v}=o,S=n&&g(n),y=r&&p(r),x={[de.focused]:[],[de.outside]:[],[de.disabled]:[],[de.hidden]:[],[de.today]:[]},O={};for(const w of e){const{date:M,displayMonth:C}=w,D=!!(C&&!h(M,C)),Y=!!(S&&b(M,S)),L=!!(y&&v(M,y)),$=!!(s&&He(M,s,o)),K=!!(i&&He(M,i,o))||Y||L||!l&&!c&&D||l&&c===!1&&D,J=u(M,f??o.today());D&&x.outside.push(w),$&&x.disabled.push(w),K&&x.hidden.push(w),J&&x.today.push(w),a&&Object.keys(a).forEach(_=>{const A=a==null?void 0:a[_];A&&He(M,A,o)&&(O[_]?O[_].push(w):O[_]=[w])})}return w=>{const M={[de.focused]:!1,[de.disabled]:!1,[de.hidden]:!1,[de.outside]:!1,[de.today]:!1},C={};for(const D in x){const Y=x[D];M[D]=Y.some(L=>L===w)}for(const D in O)C[D]=O[D].some(Y=>Y===w);return{...M,...C}}}function lp(e,t,n={}){return Object.entries(e).filter(([,o])=>o===!0).reduce((o,[s])=>(n[s]?o.push(n[s]):t[de[s]]?o.push(t[de[s]]):t[Ee[s]]&&o.push(t[Ee[s]]),o),[t[q.Day]])}function up(e){return N.createElement("button",{...e})}function dp(e){return N.createElement("span",{...e})}function fp(e){const{size:t=24,orientation:n="left",className:r}=e;return N.createElement("svg",{className:r,width:t,height:t,viewBox:"0 0 24 24"},n==="up"&&N.createElement("polygon",{points:"6.77 17 12.5 11.43 18.24 17 20 15.28 12.5 8 5 15.28"}),n==="down"&&N.createElement("polygon",{points:"6.77 8 12.5 13.57 18.24 8 20 9.72 12.5 17 5 9.72"}),n==="left"&&N.createElement("polygon",{points:"16 18.112 9.81111111 12 16 5.87733333 14.0888889 4 6 12 14.0888889 20"}),n==="right"&&N.createElement("polygon",{points:"8 18.112 14.18888889 12 8 5.87733333 9.91111111 4 18 12 9.91111111 20"}))}function mp(e){const{day:t,modifiers:n,...r}=e;return N.createElement("td",{...r})}function hp(e){const{day:t,modifiers:n,...r}=e,o=N.useRef(null);return N.useEffect(()=>{var s;n.focused&&((s=o.current)==null||s.focus())},[n.focused]),N.createElement("button",{ref:o,...r})}function pp(e){const{options:t,className:n,components:r,classNames:o,...s}=e,i=[o[q.Dropdown],n].join(" "),a=t==null?void 0:t.find(({value:c})=>c===s.value);return N.createElement("span",{"data-disabled":s.disabled,className:o[q.DropdownRoot]},N.createElement(r.Select,{className:i,...s},t==null?void 0:t.map(({value:c,label:l,disabled:f})=>N.createElement(r.Option,{key:c,value:c,disabled:f},l))),N.createElement("span",{className:o[q.CaptionLabel],"aria-hidden":!0},a==null?void 0:a.label,N.createElement(r.Chevron,{orientation:"down",size:18,className:o[q.Chevron]})))}function gp(e){return N.createElement("div",{...e})}function vp(e){return N.createElement("div",{...e})}function yp(e){const{calendarMonth:t,displayIndex:n,...r}=e;return N.createElement("div",{...r},e.children)}function bp(e){const{calendarMonth:t,displayIndex:n,...r}=e;return N.createElement("div",{...r})}function wp(e){return N.createElement("table",{...e})}function xp(e){return N.createElement("div",{...e})}const Ei=N.createContext(void 0);function nn(){const e=N.useContext(Ei);if(e===void 0)throw new Error("useDayPicker() must be used within a custom component.");return e}function Sp(e){const{components:t}=nn();return N.createElement(t.Dropdown,{...e})}function kp(e){const{onPreviousClick:t,onNextClick:n,previousMonth:r,nextMonth:o,...s}=e,{components:i,classNames:a,labels:{labelPrevious:c,labelNext:l}}=nn(),f=N.useCallback(h=>{o&&(n==null||n(h))},[o,n]),u=N.useCallback(h=>{r&&(t==null||t(h))},[r,t]);return N.createElement("nav",{...s},N.createElement(i.PreviousMonthButton,{type:"button",className:a[q.PreviousMonthButton],tabIndex:r?void 0:-1,"aria-disabled":r?void 0:!0,"aria-label":c(r),onClick:u},N.createElement(i.Chevron,{disabled:r?void 0:!0,className:a[q.Chevron],orientation:"left"})),N.createElement(i.NextMonthButton,{type:"button",className:a[q.NextMonthButton],tabIndex:o?void 0:-1,"aria-disabled":o?void 0:!0,"aria-label":l(o),onClick:f},N.createElement(i.Chevron,{disabled:o?void 0:!0,orientation:"right",className:a[q.Chevron]})))}function Mp(e){const{components:t}=nn();return N.createElement(t.Button,{...e})}function Cp(e){return N.createElement("option",{...e})}function Np(e){const{components:t}=nn();return N.createElement(t.Button,{...e})}function Dp(e){const{rootRef:t,...n}=e;return N.createElement("div",{...n,ref:t})}function Op(e){return N.createElement("select",{...e})}function Ep(e){const{week:t,...n}=e;return N.createElement("tr",{...n})}function Pp(e){return N.createElement("th",{...e})}function Ap(e){return N.createElement("thead",{"aria-hidden":!0},N.createElement("tr",{...e}))}function Tp(e){const{week:t,...n}=e;return N.createElement("th",{...n})}function Rp(e){return N.createElement("th",{...e})}function _p(e){return N.createElement("tbody",{...e})}function jp(e){const{components:t}=nn();return N.createElement(t.Dropdown,{...e})}const Ip=Object.freeze(Object.defineProperty({__proto__:null,Button:up,CaptionLabel:dp,Chevron:fp,Day:mp,DayButton:hp,Dropdown:pp,DropdownNav:gp,Footer:vp,Month:yp,MonthCaption:bp,MonthGrid:wp,Months:xp,MonthsDropdown:Sp,Nav:kp,NextMonthButton:Mp,Option:Cp,PreviousMonthButton:Np,Root:Dp,Select:Op,Week:Ep,WeekNumber:Tp,WeekNumberHeader:Rp,Weekday:Pp,Weekdays:Ap,Weeks:_p,YearsDropdown:jp},Symbol.toStringTag,{value:"Module"}));function Wp(e){return{...Ip,...e}}function $p(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,r])=>{n.startsWith("data-")&&(t[n]=r)}),t}function Fp(){const e={};for(const t in q)e[q[t]]=`rdp-${q[t]}`;for(const t in de)e[de[t]]=`rdp-${de[t]}`;for(const t in Ee)e[Ee[t]]=`rdp-${Ee[t]}`;for(const t in Se)e[Se[t]]=`rdp-${Se[t]}`;return e}function Pi(e,t,n){return(n??new Ge(t)).format(e,"LLLL y")}const Lp=Pi;function Bp(e,t,n){return(n??new Ge(t)).format(e,"d")}function Yp(e,t=Be){return t.format(e,"LLLL")}function zp(e,t=Be){return e<10?t.formatNumber(`0${e.toLocaleString()}`):t.formatNumber(`${e.toLocaleString()}`)}function Hp(){return""}function qp(e,t,n){return(n??new Ge(t)).format(e,"cccccc")}function Ai(e,t=Be){return t.format(e,"yyyy")}const Up=Ai,Gp=Object.freeze(Object.defineProperty({__proto__:null,formatCaption:Pi,formatDay:Bp,formatMonthCaption:Lp,formatMonthDropdown:Yp,formatWeekNumber:zp,formatWeekNumberHeader:Hp,formatWeekdayName:qp,formatYearCaption:Up,formatYearDropdown:Ai},Symbol.toStringTag,{value:"Module"}));function Kp(e){return e!=null&&e.formatMonthCaption&&!e.formatCaption&&(e.formatCaption=e.formatMonthCaption),e!=null&&e.formatYearCaption&&!e.formatYearDropdown&&(e.formatYearDropdown=e.formatYearCaption),{...Gp,...e}}function Vp(e,t,n,r,o){const{startOfMonth:s,startOfYear:i,endOfYear:a,eachMonthOfInterval:c,getMonth:l}=o;return c({start:i(e),end:a(e)}).map(h=>{const g=r.formatMonthDropdown(h,o),b=l(h),p=t&&h<s(t)||n&&h>s(n)||!1;return{value:b,label:g,disabled:p}})}function Xp(e,t={},n={}){let r={...t==null?void 0:t[q.Day]};return Object.entries(e).filter(([,o])=>o===!0).forEach(([o])=>{r={...r,...n==null?void 0:n[o]}}),r}function Zp(e,t,n){const r=e.today(),o=t?e.startOfISOWeek(r):e.startOfWeek(r),s=[];for(let i=0;i<7;i++){const a=e.addDays(o,i);s.push(a)}return s}function Qp(e,t,n,r){if(!e||!t)return;const{startOfYear:o,endOfYear:s,addYears:i,getYear:a,isBefore:c,isSameYear:l}=r,f=o(e),u=s(t),h=[];let g=f;for(;c(g,u)||l(g,u);)h.push(g),g=i(g,1);return h.map(b=>{const p=n.formatYearDropdown(b,r);return{value:a(b),label:p,disabled:!1}})}function Ti(e,t,n){return(n??new Ge(t)).format(e,"LLLL y")}const Jp=Ti;function eg(e,t,n,r){let o=(r??new Ge(n)).format(e,"PPPP");return t!=null&&t.today&&(o=`Today, ${o}`),o}function Ri(e,t,n,r){let o=(r??new Ge(n)).format(e,"PPPP");return t.today&&(o=`Today, ${o}`),t.selected&&(o=`${o}, selected`),o}const tg=Ri;function ng(){return""}function rg(e){return"Choose the Month"}function og(e){return"Go to the Next Month"}function sg(e){return"Go to the Previous Month"}function ag(e,t,n){return(n??new Ge(t)).format(e,"cccc")}function ig(e,t){return`Week ${e}`}function cg(e){return"Week Number"}function lg(e){return"Choose the Year"}const ug=Object.freeze(Object.defineProperty({__proto__:null,labelCaption:Jp,labelDay:tg,labelDayButton:Ri,labelGrid:Ti,labelGridcell:eg,labelMonthDropdown:rg,labelNav:ng,labelNext:og,labelPrevious:sg,labelWeekNumber:ig,labelWeekNumberHeader:cg,labelWeekday:ag,labelYearDropdown:lg},Symbol.toStringTag,{value:"Module"})),rn=e=>e instanceof HTMLElement?e:null,mr=e=>[...e.querySelectorAll("[data-animated-month]")??[]],dg=e=>rn(e.querySelector("[data-animated-month]")),hr=e=>rn(e.querySelector("[data-animated-caption]")),pr=e=>rn(e.querySelector("[data-animated-weeks]")),fg=e=>rn(e.querySelector("[data-animated-nav]")),mg=e=>rn(e.querySelector("[data-animated-weekdays]"));function hg(e,t,{classNames:n,months:r,focused:o,dateLib:s}){const i=N.useRef(null),a=N.useRef(r),c=N.useRef(!1);N.useLayoutEffect(()=>{const l=a.current;if(a.current=r,!t||!e.current||!(e.current instanceof HTMLElement)||r.length===0||l.length===0||r.length!==l.length)return;const f=s.isSameMonth(r[0].date,l[0].date),u=s.isAfter(r[0].date,l[0].date),h=u?n[Se.caption_after_enter]:n[Se.caption_before_enter],g=u?n[Se.weeks_after_enter]:n[Se.weeks_before_enter],b=i.current,p=e.current.cloneNode(!0);if(p instanceof HTMLElement?(mr(p).forEach(x=>{if(!(x instanceof HTMLElement))return;const O=dg(x);O&&x.contains(O)&&x.removeChild(O);const w=hr(x);w&&w.classList.remove(h);const M=pr(x);M&&M.classList.remove(g)}),i.current=p):i.current=null,c.current||f||o)return;const v=b instanceof HTMLElement?mr(b):[],S=mr(e.current);if(S&&S.every(y=>y instanceof HTMLElement)&&v&&v.every(y=>y instanceof HTMLElement)){c.current=!0,e.current.style.isolation="isolate";const y=fg(e.current);y&&(y.style.zIndex="1"),S.forEach((x,O)=>{const w=v[O];if(!w)return;x.style.position="relative",x.style.overflow="hidden";const M=hr(x);M&&M.classList.add(h);const C=pr(x);C&&C.classList.add(g);const D=()=>{c.current=!1,e.current&&(e.current.style.isolation=""),y&&(y.style.zIndex=""),M&&M.classList.remove(h),C&&C.classList.remove(g),x.style.position="",x.style.overflow="",x.contains(w)&&x.removeChild(w)};w.style.pointerEvents="none",w.style.position="absolute",w.style.overflow="hidden",w.setAttribute("aria-hidden","true");const Y=mg(w);Y&&(Y.style.opacity="0");const L=hr(w);L&&(L.classList.add(u?n[Se.caption_before_exit]:n[Se.caption_after_exit]),L.addEventListener("animationend",D));const $=pr(w);$&&$.classList.add(u?n[Se.weeks_before_exit]:n[Se.weeks_after_exit]),x.insertBefore(w,x.firstChild)})}})}function pg(e,t,n,r){const o=e[0],s=e[e.length-1],{ISOWeek:i,fixedWeeks:a,broadcastCalendar:c}=n??{},{addDays:l,differenceInCalendarDays:f,differenceInCalendarMonths:u,endOfBroadcastWeek:h,endOfISOWeek:g,endOfMonth:b,endOfWeek:p,isAfter:v,startOfBroadcastWeek:S,startOfISOWeek:y,startOfWeek:x}=r,O=c?S(o,r):i?y(o):x(o),w=c?h(s):i?g(b(s)):p(b(s)),M=f(w,O),C=u(s,o)+1,D=[];for(let $=0;$<=M;$++){const K=l(O,$);if(t&&v(K,t))break;D.push(K)}const L=(c?35:42)*C;if(a&&D.length<L){const $=L-D.length;for(let K=0;K<$;K++){const J=l(D[D.length-1],1);D.push(J)}}return D}function gg(e){const t=[];return e.reduce((n,r)=>{const o=r.weeks.reduce((s,i)=>[...s,...i.days],t);return[...n,...o]},t)}function vg(e,t,n,r){const{numberOfMonths:o=1}=n,s=[];for(let i=0;i<o;i++){const a=r.addMonths(e,i);if(t&&a>t)break;s.push(a)}return s}function Jo(e,t,n,r){const{month:o,defaultMonth:s,today:i=r.today(),numberOfMonths:a=1}=e;let c=o||s||i;const{differenceInCalendarMonths:l,addMonths:f,startOfMonth:u}=r;if(n&&l(n,c)<a-1){const h=-1*(a-1);c=f(n,h)}return t&&l(c,t)<0&&(c=t),u(c)}function yg(e,t,n,r){const{addDays:o,endOfBroadcastWeek:s,endOfISOWeek:i,endOfMonth:a,endOfWeek:c,getISOWeek:l,getWeek:f,startOfBroadcastWeek:u,startOfISOWeek:h,startOfWeek:g}=r,b=e.reduce((p,v)=>{const S=n.broadcastCalendar?u(v,r):n.ISOWeek?h(v):g(v),y=n.broadcastCalendar?s(v):n.ISOWeek?i(a(v)):c(a(v)),x=t.filter(C=>C>=S&&C<=y),O=n.broadcastCalendar?35:42;if(n.fixedWeeks&&x.length<O){const C=t.filter(D=>{const Y=O-x.length;return D>y&&D<=o(y,Y)});x.push(...C)}const w=x.reduce((C,D)=>{const Y=n.ISOWeek?l(D):f(D),L=C.find(K=>K.weekNumber===Y),$=new ki(D,v,r);return L?L.days.push($):C.push(new ip(Y,[$])),C},[]),M=new ap(v,w);return p.push(M),p},[]);return n.reverseMonths?b.reverse():b}function bg(e,t){let{startMonth:n,endMonth:r}=e;const{startOfYear:o,startOfDay:s,startOfMonth:i,endOfMonth:a,addYears:c,endOfYear:l,newDate:f,today:u}=t,{fromYear:h,toYear:g,fromMonth:b,toMonth:p}=e;!n&&b&&(n=b),!n&&h&&(n=t.newDate(h,0,1)),!r&&p&&(r=p),!r&&g&&(r=f(g,11,31));const v=e.captionLayout==="dropdown"||e.captionLayout==="dropdown-years";return n?n=i(n):h?n=f(h,0,1):!n&&v&&(n=o(c(e.today??u(),-100))),r?r=a(r):g?r=f(g,11,31):!r&&v&&(r=l(e.today??u())),[n&&s(n),r&&s(r)]}function wg(e,t,n,r){if(n.disableNavigation)return;const{pagedNavigation:o,numberOfMonths:s=1}=n,{startOfMonth:i,addMonths:a,differenceInCalendarMonths:c}=r,l=o?s:1,f=i(e);if(!t)return a(f,l);if(!(c(t,e)<s))return a(f,l)}function xg(e,t,n,r){if(n.disableNavigation)return;const{pagedNavigation:o,numberOfMonths:s}=n,{startOfMonth:i,addMonths:a,differenceInCalendarMonths:c}=r,l=o?s??1:1,f=i(e);if(!t)return a(f,-l);if(!(c(f,t)<=0))return a(f,-l)}function Sg(e){const t=[];return e.reduce((n,r)=>[...n,...r.weeks],t)}function Un(e,t){const[n,r]=N.useState(e);return[t===void 0?n:t,r]}function kg(e,t){const[n,r]=bg(e,t),{startOfMonth:o,endOfMonth:s}=t,i=Jo(e,n,r,t),[a,c]=Un(i,e.month?i:void 0);N.useEffect(()=>{const M=Jo(e,n,r,t);c(M)},[e.timeZone]);const l=vg(a,r,e,t),f=pg(l,e.endMonth?s(e.endMonth):void 0,e,t),u=yg(l,f,e,t),h=Sg(u),g=gg(u),b=xg(a,n,e,t),p=wg(a,r,e,t),{disableNavigation:v,onMonthChange:S}=e,y=M=>h.some(C=>C.days.some(D=>D.isEqualTo(M))),x=M=>{if(v)return;let C=o(M);n&&C<o(n)&&(C=o(n)),r&&C>o(r)&&(C=o(r)),c(C),S==null||S(C)};return{months:u,weeks:h,days:g,navStart:n,navEnd:r,previousMonth:b,nextMonth:p,goToMonth:x,goToDay:M=>{y(M)||x(M.date)}}}var _e;(function(e){e[e.Today=0]="Today",e[e.Selected=1]="Selected",e[e.LastFocused=2]="LastFocused",e[e.FocusedModifier=3]="FocusedModifier"})(_e||(_e={}));function es(e){return!e[de.disabled]&&!e[de.hidden]&&!e[de.outside]}function Mg(e,t,n,r){let o,s=-1;for(const i of e){const a=t(i);es(a)&&(a[de.focused]&&s<_e.FocusedModifier?(o=i,s=_e.FocusedModifier):r!=null&&r.isEqualTo(i)&&s<_e.LastFocused?(o=i,s=_e.LastFocused):n(i.date)&&s<_e.Selected?(o=i,s=_e.Selected):a[de.today]&&s<_e.Today&&(o=i,s=_e.Today))}return o||(o=e.find(i=>es(t(i)))),o}function Cg(e,t,n,r,o,s,i){const{ISOWeek:a,broadcastCalendar:c}=s,{addDays:l,addMonths:f,addWeeks:u,addYears:h,endOfBroadcastWeek:g,endOfISOWeek:b,endOfWeek:p,max:v,min:S,startOfBroadcastWeek:y,startOfISOWeek:x,startOfWeek:O}=i;let M={day:l,week:u,month:f,year:h,startOfWeek:C=>c?y(C,i):a?x(C):O(C),endOfWeek:C=>c?g(C):a?b(C):p(C)}[e](n,t==="after"?1:-1);return t==="before"&&r?M=v([r,M]):t==="after"&&o&&(M=S([o,M])),M}function _i(e,t,n,r,o,s,i,a=0){if(a>365)return;const c=Cg(e,t,n.date,r,o,s,i),l=!!(s.disabled&&He(c,s.disabled,i)),f=!!(s.hidden&&He(c,s.hidden,i)),u=c,h=new ki(c,u,i);return!l&&!f?h:_i(e,t,h,r,o,s,i,a+1)}function Ng(e,t,n,r,o){const{autoFocus:s}=e,[i,a]=N.useState(),c=Mg(t.days,n,r||(()=>!1),i),[l,f]=N.useState(s?c:void 0);return{isFocusTarget:p=>!!(c!=null&&c.isEqualTo(p)),setFocused:f,focused:l,blur:()=>{a(l),f(void 0)},moveFocus:(p,v)=>{if(!l)return;const S=_i(p,v,l,t.navStart,t.navEnd,e,o);S&&(t.goToDay(S),f(S))}}}function Dg(e,t){const{selected:n,required:r,onSelect:o}=e,[s,i]=Un(n,o?n:void 0),a=o?n:s,{isSameDay:c}=t,l=g=>(a==null?void 0:a.some(b=>c(b,g)))??!1,{min:f,max:u}=e;return{selected:a,select:(g,b,p)=>{let v=[...a??[]];if(l(g)){if((a==null?void 0:a.length)===f||r&&(a==null?void 0:a.length)===1)return;v=a==null?void 0:a.filter(S=>!c(S,g))}else(a==null?void 0:a.length)===u?v=[g]:v=[...v,g];return o||i(v),o==null||o(v,g,b,p),v},isSelected:l}}function Og(e,t,n=0,r=0,o=!1,s=Be){const{from:i,to:a}=t||{},{isSameDay:c,isAfter:l,isBefore:f}=s;let u;if(!i&&!a)u={from:e,to:n>0?void 0:e};else if(i&&!a)c(i,e)?o?u={from:i,to:void 0}:u=void 0:f(e,i)?u={from:e,to:i}:u={from:i,to:e};else if(i&&a)if(c(i,e)&&c(a,e))o?u={from:i,to:a}:u=void 0;else if(c(i,e))u={from:i,to:n>0?void 0:e};else if(c(a,e))u={from:e,to:n>0?void 0:e};else if(f(e,i))u={from:e,to:a};else if(l(e,i))u={from:i,to:e};else if(l(e,a))u={from:i,to:e};else throw new Error("Invalid range");if(u!=null&&u.from&&(u!=null&&u.to)){const h=s.differenceInCalendarDays(u.to,u.from);r>0&&h>r?u={from:e,to:void 0}:n>1&&h<n&&(u={from:e,to:void 0})}return u}function Eg(e,t,n=Be){const r=Array.isArray(t)?t:[t];let o=e.from;const s=n.differenceInCalendarDays(e.to,e.from),i=Math.min(s,6);for(let a=0;a<=i;a++){if(r.includes(o.getDay()))return!0;o=n.addDays(o,1)}return!1}function ts(e,t,n=Be){return ze(e,t.from,!1,n)||ze(e,t.to,!1,n)||ze(t,e.from,!1,n)||ze(t,e.to,!1,n)}function Pg(e,t,n=Be){const r=Array.isArray(t)?t:[t];if(r.filter(a=>typeof a!="function").some(a=>typeof a=="boolean"?a:n.isDate(a)?ze(e,a,!1,n):Oi(a,n)?a.some(c=>ze(e,c,!1,n)):ro(a)?a.from&&a.to?ts(e,{from:a.from,to:a.to},n):!1:Di(a)?Eg(e,a.dayOfWeek,n):Mi(a)?n.isAfter(a.before,a.after)?ts(e,{from:n.addDays(a.after,1),to:n.addDays(a.before,-1)},n):He(e.from,a,n)||He(e.to,a,n):Ci(a)||Ni(a)?He(e.from,a,n)||He(e.to,a,n):!1))return!0;const i=r.filter(a=>typeof a=="function");if(i.length){let a=e.from;const c=n.differenceInCalendarDays(e.to,e.from);for(let l=0;l<=c;l++){if(i.some(f=>f(a)))return!0;a=n.addDays(a,1)}}return!1}function Ag(e,t){const{disabled:n,excludeDisabled:r,selected:o,required:s,onSelect:i}=e,[a,c]=Un(o,i?o:void 0),l=i?o:a;return{selected:l,select:(h,g,b)=>{const{min:p,max:v}=e,S=h?Og(h,l,p,v,s,t):void 0;return r&&n&&(S!=null&&S.from)&&S.to&&Pg({from:S.from,to:S.to},n,t)&&(S.from=h,S.to=void 0),i||c(S),i==null||i(S,h,g,b),S},isSelected:h=>l&&ze(l,h,!1,t)}}function Tg(e,t){const{selected:n,required:r,onSelect:o}=e,[s,i]=Un(n,o?n:void 0),a=o?n:s,{isSameDay:c}=t;return{selected:a,select:(u,h,g)=>{let b=u;return!r&&a&&a&&c(u,a)&&(b=void 0),o||i(b),o==null||o(b,u,h,g),b},isSelected:u=>a?c(a,u):!1}}function Rg(e,t){const n=Tg(e,t),r=Dg(e,t),o=Ag(e,t);switch(e.mode){case"single":return n;case"multiple":return r;case"range":return o;default:return}}function _g(e){var mo;let t=e;t.timeZone&&(t={...e},t.today&&(t.today=new ye(t.today,t.timeZone)),t.month&&(t.month=new ye(t.month,t.timeZone)),t.defaultMonth&&(t.defaultMonth=new ye(t.defaultMonth,t.timeZone)),t.startMonth&&(t.startMonth=new ye(t.startMonth,t.timeZone)),t.endMonth&&(t.endMonth=new ye(t.endMonth,t.timeZone)),t.mode==="single"&&t.selected?t.selected=new ye(t.selected,t.timeZone):t.mode==="multiple"&&t.selected?t.selected=(mo=t.selected)==null?void 0:mo.map(re=>new ye(re,t.timeZone)):t.mode==="range"&&t.selected&&(t.selected={from:t.selected.from?new ye(t.selected.from,t.timeZone):void 0,to:t.selected.to?new ye(t.selected.to,t.timeZone):void 0}));const{components:n,formatters:r,labels:o,dateLib:s,locale:i,classNames:a}=N.useMemo(()=>{const re={...no,...t.locale};return{dateLib:new Ge({locale:re,weekStartsOn:t.broadcastCalendar?1:t.weekStartsOn,firstWeekContainsDate:t.firstWeekContainsDate,useAdditionalWeekYearTokens:t.useAdditionalWeekYearTokens,useAdditionalDayOfYearTokens:t.useAdditionalDayOfYearTokens,timeZone:t.timeZone,numerals:t.numerals},t.dateLib),components:Wp(t.components),formatters:Kp(t.formatters),labels:{...ug,...t.labels},locale:re,classNames:{...Fp(),...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]),{captionLayout:c,mode:l,navLayout:f,numberOfMonths:u=1,onDayBlur:h,onDayClick:g,onDayFocus:b,onDayKeyDown:p,onDayMouseEnter:v,onDayMouseLeave:S,onNextClick:y,onPrevClick:x,showWeekNumber:O,styles:w}=t,{formatCaption:M,formatDay:C,formatMonthDropdown:D,formatWeekNumber:Y,formatWeekNumberHeader:L,formatWeekdayName:$,formatYearDropdown:K}=r,J=kg(t,s),{days:_,months:A,navStart:P,navEnd:T,previousMonth:k,nextMonth:I,goToMonth:B}=J,Q=cp(_,t,P,T,s),{isSelected:E,select:j,selected:F}=Rg(t,s)??{},{blur:W,focused:X,isFocusTarget:R,moveFocus:V,setFocused:Z}=Ng(t,J,Q,E??(()=>!1),s),{labelDayButton:G,labelGridcell:ee,labelGrid:te,labelMonthDropdown:me,labelNav:xe,labelPrevious:ot,labelNext:st,labelWeekday:at,labelWeekNumber:Vn,labelWeekNumberHeader:bt,labelYearDropdown:vc}=o,yc=N.useMemo(()=>Zp(s,t.ISOWeek),[s,t.ISOWeek]),uo=l!==void 0||g!==void 0,Xn=N.useCallback(()=>{k&&(B(k),x==null||x(k))},[k,B,x]),Zn=N.useCallback(()=>{I&&(B(I),y==null||y(I))},[B,I,y]),bc=N.useCallback((re,ue)=>se=>{se.preventDefault(),se.stopPropagation(),Z(re),j==null||j(re.date,ue,se),g==null||g(re.date,ue,se)},[j,g,Z]),wc=N.useCallback((re,ue)=>se=>{Z(re),b==null||b(re.date,ue,se)},[b,Z]),xc=N.useCallback((re,ue)=>se=>{W(),h==null||h(re.date,ue,se)},[W,h]),Sc=N.useCallback((re,ue)=>se=>{const Ke={ArrowLeft:[se.shiftKey?"month":"day",t.dir==="rtl"?"after":"before"],ArrowRight:[se.shiftKey?"month":"day",t.dir==="rtl"?"before":"after"],ArrowDown:[se.shiftKey?"year":"week","after"],ArrowUp:[se.shiftKey?"year":"week","before"],PageUp:[se.shiftKey?"year":"month","before"],PageDown:[se.shiftKey?"year":"month","after"],Home:["startOfWeek","before"],End:["endOfWeek","after"]};if(Ke[se.key]){se.preventDefault(),se.stopPropagation();const[De,sn]=Ke[se.key];V(De,sn)}p==null||p(re.date,ue,se)},[V,p,t.dir]),kc=N.useCallback((re,ue)=>se=>{v==null||v(re.date,ue,se)},[v]),Mc=N.useCallback((re,ue)=>se=>{S==null||S(re.date,ue,se)},[S]),Cc=N.useCallback(re=>ue=>{const se=Number(ue.target.value),Ke=s.setMonth(s.startOfMonth(re),se);B(Ke)},[s,B]),Nc=N.useCallback(re=>ue=>{const se=Number(ue.target.value),Ke=s.setYear(s.startOfMonth(re),se);B(Ke)},[s,B]),{className:Dc,style:Oc}=N.useMemo(()=>({className:[a[q.Root],t.className].filter(Boolean).join(" "),style:{...w==null?void 0:w[q.Root],...t.style}}),[a,t.className,t.style,w]),Ec=$p(t),fo=N.useRef(null);hg(fo,!!t.animate,{classNames:a,months:A,focused:X,dateLib:s});const Pc={dayPickerProps:t,selected:F,select:j,isSelected:E,months:A,nextMonth:I,previousMonth:k,goToMonth:B,getModifiers:Q,components:n,classNames:a,styles:w,labels:o,formatters:r};return N.createElement(Ei.Provider,{value:Pc},N.createElement(n.Root,{rootRef:t.animate?fo:void 0,className:Dc,style:Oc,dir:t.dir,id:t.id,lang:t.lang,nonce:t.nonce,title:t.title,role:t.role,"aria-label":t["aria-label"],...Ec},N.createElement(n.Months,{className:a[q.Months],style:w==null?void 0:w[q.Months]},!t.hideNavigation&&!f&&N.createElement(n.Nav,{"data-animated-nav":t.animate?"true":void 0,className:a[q.Nav],style:w==null?void 0:w[q.Nav],"aria-label":xe(),onPreviousClick:Xn,onNextClick:Zn,previousMonth:k,nextMonth:I}),A.map((re,ue)=>{const se=Vp(re.date,P,T,r,s),Ke=Qp(P,T,r,s);return N.createElement(n.Month,{"data-animated-month":t.animate?"true":void 0,className:a[q.Month],style:w==null?void 0:w[q.Month],key:ue,displayIndex:ue,calendarMonth:re},f==="around"&&!t.hideNavigation&&ue===0&&N.createElement(n.PreviousMonthButton,{type:"button",className:a[q.PreviousMonthButton],tabIndex:k?void 0:-1,"aria-disabled":k?void 0:!0,"aria-label":ot(k),onClick:Xn,"data-animated-button":t.animate?"true":void 0},N.createElement(n.Chevron,{disabled:k?void 0:!0,className:a[q.Chevron],orientation:t.dir==="rtl"?"right":"left"})),N.createElement(n.MonthCaption,{"data-animated-caption":t.animate?"true":void 0,className:a[q.MonthCaption],style:w==null?void 0:w[q.MonthCaption],calendarMonth:re,displayIndex:ue},c!=null&&c.startsWith("dropdown")?N.createElement(n.DropdownNav,{className:a[q.Dropdowns],style:w==null?void 0:w[q.Dropdowns]},c==="dropdown"||c==="dropdown-months"?N.createElement(n.MonthsDropdown,{className:a[q.MonthsDropdown],"aria-label":me(),classNames:a,components:n,disabled:!!t.disableNavigation,onChange:Cc(re.date),options:se,style:w==null?void 0:w[q.Dropdown],value:s.getMonth(re.date)}):N.createElement("span",null,D(re.date,s)),c==="dropdown"||c==="dropdown-years"?N.createElement(n.YearsDropdown,{className:a[q.YearsDropdown],"aria-label":vc(s.options),classNames:a,components:n,disabled:!!t.disableNavigation,onChange:Nc(re.date),options:Ke,style:w==null?void 0:w[q.Dropdown],value:s.getYear(re.date)}):N.createElement("span",null,K(re.date,s)),N.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"}},M(re.date,s.options,s))):N.createElement(n.CaptionLabel,{className:a[q.CaptionLabel],role:"status","aria-live":"polite"},M(re.date,s.options,s))),f==="around"&&!t.hideNavigation&&ue===u-1&&N.createElement(n.NextMonthButton,{type:"button",className:a[q.NextMonthButton],tabIndex:I?void 0:-1,"aria-disabled":I?void 0:!0,"aria-label":st(I),onClick:Zn,"data-animated-button":t.animate?"true":void 0},N.createElement(n.Chevron,{disabled:I?void 0:!0,className:a[q.Chevron],orientation:t.dir==="rtl"?"left":"right"})),ue===u-1&&f==="after"&&!t.hideNavigation&&N.createElement(n.Nav,{"data-animated-nav":t.animate?"true":void 0,className:a[q.Nav],style:w==null?void 0:w[q.Nav],"aria-label":xe(),onPreviousClick:Xn,onNextClick:Zn,previousMonth:k,nextMonth:I}),N.createElement(n.MonthGrid,{role:"grid","aria-multiselectable":l==="multiple"||l==="range","aria-label":te(re.date,s.options,s)||void 0,className:a[q.MonthGrid],style:w==null?void 0:w[q.MonthGrid]},!t.hideWeekdays&&N.createElement(n.Weekdays,{"data-animated-weekdays":t.animate?"true":void 0,className:a[q.Weekdays],style:w==null?void 0:w[q.Weekdays]},O&&N.createElement(n.WeekNumberHeader,{"aria-label":bt(s.options),className:a[q.WeekNumberHeader],style:w==null?void 0:w[q.WeekNumberHeader],scope:"col"},L()),yc.map((De,sn)=>N.createElement(n.Weekday,{"aria-label":at(De,s.options,s),className:a[q.Weekday],key:sn,style:w==null?void 0:w[q.Weekday],scope:"col"},$(De,s.options,s)))),N.createElement(n.Weeks,{"data-animated-weeks":t.animate?"true":void 0,className:a[q.Weeks],style:w==null?void 0:w[q.Weeks]},re.weeks.map((De,sn)=>N.createElement(n.Week,{className:a[q.Week],key:De.weekNumber,style:w==null?void 0:w[q.Week],week:De},O&&N.createElement(n.WeekNumber,{week:De,style:w==null?void 0:w[q.WeekNumber],"aria-label":Vn(De.weekNumber,{locale:i}),className:a[q.WeekNumber],scope:"row",role:"rowheader"},Y(De.weekNumber,s)),De.days.map(ve=>{const{date:Re}=ve,ie=Q(ve);if(ie[de.focused]=!ie.hidden&&!!(X!=null&&X.isEqualTo(ve)),ie[Ee.selected]=(E==null?void 0:E(Re))||ie.selected,ro(F)){const{from:Qn,to:Jn}=F;ie[Ee.range_start]=!!(Qn&&Jn&&s.isSameDay(Re,Qn)),ie[Ee.range_end]=!!(Qn&&Jn&&s.isSameDay(Re,Jn)),ie[Ee.range_middle]=ze(F,Re,!0,s)}const Ac=Xp(ie,w,t.modifiersStyles),Tc=lp(ie,a,t.modifiersClassNames),Rc=!uo&&!ie.hidden?ee(Re,ie,s.options,s):void 0;return N.createElement(n.Day,{key:`${s.format(Re,"yyyy-MM-dd")}_${s.format(ve.displayMonth,"yyyy-MM")}`,day:ve,modifiers:ie,className:Tc.join(" "),style:Ac,role:"gridcell","aria-selected":ie.selected||void 0,"aria-label":Rc,"data-day":s.format(Re,"yyyy-MM-dd"),"data-month":ve.outside?s.format(Re,"yyyy-MM"):void 0,"data-selected":ie.selected||void 0,"data-disabled":ie.disabled||void 0,"data-hidden":ie.hidden||void 0,"data-outside":ve.outside||void 0,"data-focused":ie.focused||void 0,"data-today":ie.today||void 0},!ie.hidden&&uo?N.createElement(n.DayButton,{className:a[q.DayButton],style:w==null?void 0:w[q.DayButton],type:"button",day:ve,modifiers:ie,disabled:ie.disabled||void 0,tabIndex:R(ve)?0:-1,"aria-label":G(Re,ie,s.options,s),onClick:bc(ve,ie),onBlur:xc(ve,ie),onFocus:wc(ve,ie),onKeyDown:Sc(ve,ie),onMouseEnter:kc(ve,ie),onMouseLeave:Mc(ve,ie)},C(Re,s.options,s)):!ie.hidden&&C(ve.date,s.options,s))}))))))})),t.footer&&N.createElement(n.Footer,{className:a[q.Footer],style:w==null?void 0:w[q.Footer],role:"status","aria-live":"polite"},t.footer)))}function ji(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var yn={exports:{}},jg=yn.exports,ns;function Ii(){return ns||(ns=1,function(e,t){(function(n,r){e.exports=r()})(jg,function(){var n=1e3,r=6e4,o=36e5,s="millisecond",i="second",a="minute",c="hour",l="day",f="week",u="month",h="quarter",g="year",b="date",p="Invalid Date",v=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,S=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,y={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(_){var A=["th","st","nd","rd"],P=_%100;return"["+_+(A[(P-20)%10]||A[P]||A[0])+"]"}},x=function(_,A,P){var T=String(_);return!T||T.length>=A?_:""+Array(A+1-T.length).join(P)+_},O={s:x,z:function(_){var A=-_.utcOffset(),P=Math.abs(A),T=Math.floor(P/60),k=P%60;return(A<=0?"+":"-")+x(T,2,"0")+":"+x(k,2,"0")},m:function _(A,P){if(A.date()<P.date())return-_(P,A);var T=12*(P.year()-A.year())+(P.month()-A.month()),k=A.clone().add(T,u),I=P-k<0,B=A.clone().add(T+(I?-1:1),u);return+(-(T+(P-k)/(I?k-B:B-k))||0)},a:function(_){return _<0?Math.ceil(_)||0:Math.floor(_)},p:function(_){return{M:u,y:g,w:f,d:l,D:b,h:c,m:a,s:i,ms:s,Q:h}[_]||String(_||"").toLowerCase().replace(/s$/,"")},u:function(_){return _===void 0}},w="en",M={};M[w]=y;var C="$isDayjsObject",D=function(_){return _ instanceof K||!(!_||!_[C])},Y=function _(A,P,T){var k;if(!A)return w;if(typeof A=="string"){var I=A.toLowerCase();M[I]&&(k=I),P&&(M[I]=P,k=I);var B=A.split("-");if(!k&&B.length>1)return _(B[0])}else{var Q=A.name;M[Q]=A,k=Q}return!T&&k&&(w=k),k||!T&&w},L=function(_,A){if(D(_))return _.clone();var P=typeof A=="object"?A:{};return P.date=_,P.args=arguments,new K(P)},$=O;$.l=Y,$.i=D,$.w=function(_,A){return L(_,{locale:A.$L,utc:A.$u,x:A.$x,$offset:A.$offset})};var K=function(){function _(P){this.$L=Y(P.locale,null,!0),this.parse(P),this.$x=this.$x||P.x||{},this[C]=!0}var A=_.prototype;return A.parse=function(P){this.$d=function(T){var k=T.date,I=T.utc;if(k===null)return new Date(NaN);if($.u(k))return new Date;if(k instanceof Date)return new Date(k);if(typeof k=="string"&&!/Z$/i.test(k)){var B=k.match(v);if(B){var Q=B[2]-1||0,E=(B[7]||"0").substring(0,3);return I?new Date(Date.UTC(B[1],Q,B[3]||1,B[4]||0,B[5]||0,B[6]||0,E)):new Date(B[1],Q,B[3]||1,B[4]||0,B[5]||0,B[6]||0,E)}}return new Date(k)}(P),this.init()},A.init=function(){var P=this.$d;this.$y=P.getFullYear(),this.$M=P.getMonth(),this.$D=P.getDate(),this.$W=P.getDay(),this.$H=P.getHours(),this.$m=P.getMinutes(),this.$s=P.getSeconds(),this.$ms=P.getMilliseconds()},A.$utils=function(){return $},A.isValid=function(){return this.$d.toString()!==p},A.isSame=function(P,T){var k=L(P);return this.startOf(T)<=k&&k<=this.endOf(T)},A.isAfter=function(P,T){return L(P)<this.startOf(T)},A.isBefore=function(P,T){return this.endOf(T)<L(P)},A.$g=function(P,T,k){return $.u(P)?this[T]:this.set(k,P)},A.unix=function(){return Math.floor(this.valueOf()/1e3)},A.valueOf=function(){return this.$d.getTime()},A.startOf=function(P,T){var k=this,I=!!$.u(T)||T,B=$.p(P),Q=function(Z,G){var ee=$.w(k.$u?Date.UTC(k.$y,G,Z):new Date(k.$y,G,Z),k);return I?ee:ee.endOf(l)},E=function(Z,G){return $.w(k.toDate()[Z].apply(k.toDate("s"),(I?[0,0,0,0]:[23,59,59,999]).slice(G)),k)},j=this.$W,F=this.$M,W=this.$D,X="set"+(this.$u?"UTC":"");switch(B){case g:return I?Q(1,0):Q(31,11);case u:return I?Q(1,F):Q(0,F+1);case f:var R=this.$locale().weekStart||0,V=(j<R?j+7:j)-R;return Q(I?W-V:W+(6-V),F);case l:case b:return E(X+"Hours",0);case c:return E(X+"Minutes",1);case a:return E(X+"Seconds",2);case i:return E(X+"Milliseconds",3);default:return this.clone()}},A.endOf=function(P){return this.startOf(P,!1)},A.$set=function(P,T){var k,I=$.p(P),B="set"+(this.$u?"UTC":""),Q=(k={},k[l]=B+"Date",k[b]=B+"Date",k[u]=B+"Month",k[g]=B+"FullYear",k[c]=B+"Hours",k[a]=B+"Minutes",k[i]=B+"Seconds",k[s]=B+"Milliseconds",k)[I],E=I===l?this.$D+(T-this.$W):T;if(I===u||I===g){var j=this.clone().set(b,1);j.$d[Q](E),j.init(),this.$d=j.set(b,Math.min(this.$D,j.daysInMonth())).$d}else Q&&this.$d[Q](E);return this.init(),this},A.set=function(P,T){return this.clone().$set(P,T)},A.get=function(P){return this[$.p(P)]()},A.add=function(P,T){var k,I=this;P=Number(P);var B=$.p(T),Q=function(F){var W=L(I);return $.w(W.date(W.date()+Math.round(F*P)),I)};if(B===u)return this.set(u,this.$M+P);if(B===g)return this.set(g,this.$y+P);if(B===l)return Q(1);if(B===f)return Q(7);var E=(k={},k[a]=r,k[c]=o,k[i]=n,k)[B]||1,j=this.$d.getTime()+P*E;return $.w(j,this)},A.subtract=function(P,T){return this.add(-1*P,T)},A.format=function(P){var T=this,k=this.$locale();if(!this.isValid())return k.invalidDate||p;var I=P||"YYYY-MM-DDTHH:mm:ssZ",B=$.z(this),Q=this.$H,E=this.$m,j=this.$M,F=k.weekdays,W=k.months,X=k.meridiem,R=function(G,ee,te,me){return G&&(G[ee]||G(T,I))||te[ee].slice(0,me)},V=function(G){return $.s(Q%12||12,G,"0")},Z=X||function(G,ee,te){var me=G<12?"AM":"PM";return te?me.toLowerCase():me};return I.replace(S,function(G,ee){return ee||function(te){switch(te){case"YY":return String(T.$y).slice(-2);case"YYYY":return $.s(T.$y,4,"0");case"M":return j+1;case"MM":return $.s(j+1,2,"0");case"MMM":return R(k.monthsShort,j,W,3);case"MMMM":return R(W,j);case"D":return T.$D;case"DD":return $.s(T.$D,2,"0");case"d":return String(T.$W);case"dd":return R(k.weekdaysMin,T.$W,F,2);case"ddd":return R(k.weekdaysShort,T.$W,F,3);case"dddd":return F[T.$W];case"H":return String(Q);case"HH":return $.s(Q,2,"0");case"h":return V(1);case"hh":return V(2);case"a":return Z(Q,E,!0);case"A":return Z(Q,E,!1);case"m":return String(E);case"mm":return $.s(E,2,"0");case"s":return String(T.$s);case"ss":return $.s(T.$s,2,"0");case"SSS":return $.s(T.$ms,3,"0");case"Z":return B}return null}(G)||B.replace(":","")})},A.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},A.diff=function(P,T,k){var I,B=this,Q=$.p(T),E=L(P),j=(E.utcOffset()-this.utcOffset())*r,F=this-E,W=function(){return $.m(B,E)};switch(Q){case g:I=W()/12;break;case u:I=W();break;case h:I=W()/3;break;case f:I=(F-j)/6048e5;break;case l:I=(F-j)/864e5;break;case c:I=F/o;break;case a:I=F/r;break;case i:I=F/n;break;default:I=F}return k?I:$.a(I)},A.daysInMonth=function(){return this.endOf(u).$D},A.$locale=function(){return M[this.$L]},A.locale=function(P,T){if(!P)return this.$L;var k=this.clone(),I=Y(P,T,!0);return I&&(k.$L=I),k},A.clone=function(){return $.w(this.$d,this)},A.toDate=function(){return new Date(this.valueOf())},A.toJSON=function(){return this.isValid()?this.toISOString():null},A.toISOString=function(){return this.$d.toISOString()},A.toString=function(){return this.$d.toUTCString()},_}(),J=K.prototype;return L.prototype=J,[["$ms",s],["$s",i],["$m",a],["$H",c],["$W",l],["$M",u],["$y",g],["$D",b]].forEach(function(_){J[_[1]]=function(A){return this.$g(A,_[0],_[1])}}),L.extend=function(_,A){return _.$i||(_(A,K,L),_.$i=!0),L},L.locale=Y,L.isDayjs=D,L.unix=function(_){return L(1e3*_)},L.en=M[w],L.Ls=M,L.p={},L})}(yn)),yn.exports}var Ig=Ii();const Ir=ji(Ig);var bn={exports:{}},Wg=bn.exports,rs;function $g(){return rs||(rs=1,function(e,t){(function(n,r){e.exports=r()})(Wg,function(){var n={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"};return function(r,o,s){var i=o.prototype,a=i.format;s.en.formats=n,i.format=function(c){c===void 0&&(c="YYYY-MM-DDTHH:mm:ssZ");var l=this.$locale().formats,f=function(u,h){return u.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(g,b,p){var v=p&&p.toUpperCase();return b||h[p]||n[p]||h[v].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(S,y,x){return y||x.slice(1)})})}(c,l===void 0?{}:l);return a.call(this,f)}}})}(bn)),bn.exports}var Fg=$g();const Lg=ji(Fg);var wn={exports:{}},Bg=wn.exports,os;function Yg(){return os||(os=1,function(e,t){(function(n,r){e.exports=r(Ii())})(Bg,function(n){function r(i){return i&&typeof i=="object"&&"default"in i?i:{default:i}}var o=r(n),s={name:"fr",weekdays:"dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi".split("_"),weekdaysShort:"dim._lun._mar._mer._jeu._ven._sam.".split("_"),weekdaysMin:"di_lu_ma_me_je_ve_sa".split("_"),months:"janvier_février_mars_avril_mai_juin_juillet_août_septembre_octobre_novembre_décembre".split("_"),monthsShort:"janv._févr._mars_avr._mai_juin_juil._août_sept._oct._nov._déc.".split("_"),weekStart:1,yearStart:4,formats:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},relativeTime:{future:"dans %s",past:"il y a %s",s:"quelques secondes",m:"une minute",mm:"%d minutes",h:"une heure",hh:"%d heures",d:"un jour",dd:"%d jours",M:"un mois",MM:"%d mois",y:"un an",yy:"%d ans"},ordinal:function(i){return""+i+(i===1?"er":"")}};return o.default.locale(s,null,!0),s})}(wn)),wn.exports}Yg();function zg({month:e,onMonthChange:t}){const n=e.getFullYear(),r=e.getMonth(),o=["January","February","March","April","May","June","July","August","September","October","November","December"],s=new Date().getFullYear(),i=Array.from({length:201},(u,h)=>s-100+h),a=u=>{const h=new Date(e);h.setMonth(Number.parseInt(u)),t(h)},c=u=>{const h=new Date(e);h.setFullYear(Number.parseInt(u)),t(h)},l=()=>{const u=new Date(e);u.setMonth(u.getMonth()-1),t(u)},f=()=>{const u=new Date(e);u.setMonth(u.getMonth()+1),t(u)};return m.jsxs("div",{className:"flex items-center justify-between p-2 border-b bg-gray-50",children:[m.jsx(dt,{variant:"outline",size:"small",onClick:l,className:"h-7 w-7 p-0",children:m.jsx(Fl,{className:"h-4 w-4"})}),m.jsxs("div",{className:"flex items-center gap-2",children:[m.jsxs(Rr,{value:r.toString(),onValueChange:a,children:[m.jsx(Dn,{className:"w-32 h-8 text-sm",children:m.jsx(_r,{})}),m.jsx(On,{children:o.map((u,h)=>m.jsx(En,{value:h.toString(),children:u},u))})]}),m.jsxs(Rr,{value:n.toString(),onValueChange:c,children:[m.jsx(Dn,{className:"w-20 h-8 text-sm",children:m.jsx(_r,{})}),m.jsx(On,{className:"max-h-[200px]",children:i.map(u=>m.jsx(En,{value:u.toString(),children:u},u))})]})]}),m.jsx(dt,{variant:"outline",size:"small",onClick:f,className:"h-7 w-7 p-0",children:m.jsx(Bl,{className:"h-4 w-4"})})]})}Ir.extend(Lg);function Pn({label:e,placeholder:t="Pick a date",helperText:n,error:r,required:o,value:s,onSelect:i,className:a,minDate:c,maxDate:l,disabled:f,readOnly:u,locale:h="en",showOutsideDays:g,dayPickerProps:b,month:p,onMonthChange:v,open:S,onOpenChange:y,...x}){const[O,w]=N.useState(!1),M=S!==void 0?S:O,C=y||w,D=p??s??new Date,Y=L=>{L&&(!s||L.getTime()!==s.getTime())&&(i==null||i(L),C(!1))};return Ir.locale(h),m.jsxs("div",{className:U("space-y-1",a),...x,children:[e&&m.jsxs(yt,{className:"text-sm font-medium text-gray-700",children:[e,o&&m.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),m.jsxs(Vf,{open:M,onOpenChange:C,children:[m.jsx(Xf,{asChild:!0,children:m.jsxs(dt,{variant:"outline",className:U("w-full flex justify-between items-center font-normal",!s&&"text-muted-foreground",r&&"border-red-500 focus:ring-red-500"),disabled:f,"aria-readonly":u,onClick:()=>C(!M),children:[m.jsx("span",{className:U("text-left",!s&&"text-gray-400"),children:s?Ir(s).locale(h).format("LL"):t}),m.jsx(jl,{strokeWidth:1.2,className:"ml-6 h-6 w-6 shrink-0 text-foreground"})]})}),m.jsx(Ma,{className:"w-auto p-0",align:"start",children:m.jsxs("div",{className:"bg-white rounded-md border shadow-md",children:[m.jsx(zg,{month:D,onMonthChange:v??(()=>{})}),m.jsx("div",{className:"p-3",children:m.jsx(_g,{mode:"single",selected:s,onSelect:Y,month:D,onMonthChange:v,fromDate:c,toDate:l,showOutsideDays:g,className:"p-0",classNames:{months:"flex flex-col sm:flex-row space-y-4 sm:space-x-4 sm:space-y-0",month:"space-y-4",caption:"hidden",caption_label:"text-sm font-medium",nav:"hidden",nav_button:"h-7 w-7 bg-transparent p-0 opacity-50 hover:opacity-100",nav_button_previous:"absolute left-1 top-1",nav_button_next:"absolute right-1 top-1",table:"w-full border-collapse space-y-1",head_row:"flex",head_cell:"text-muted-foreground rounded-md w-9 font-normal text-[0.8rem]",row:"flex w-full mt-2",cell:"h-9 w-9 text-center text-sm p-0 relative [&:has([aria-selected].day-range-end)]:rounded-r-md [&:has([aria-selected].day-outside)]:bg-accent/50 [&:has([aria-selected])]:bg-accent first:[&:has([aria-selected])]:rounded-l-md last:[&:has([aria-selected])]:rounded-r-md focus-within:relative focus-within:z-20",day:"h-9 w-9 p-0 font-normal aria-selected:opacity-100 hover:bg-accent hover:text-accent-foreground rounded-md transition-colors",day_range_end:"day-range-end",day_selected:"bg-primary text-primary-foreground hover:bg-primary hover:text-primary-foreground focus:bg-primary focus:text-primary-foreground",day_today:"bg-accent text-accent-foreground",day_outside:"day-outside text-muted-foreground opacity-50 aria-selected:bg-accent/50 aria-selected:text-muted-foreground aria-selected:opacity-30",day_disabled:"text-muted-foreground opacity-50",day_range_middle:"aria-selected:bg-accent aria-selected:text-accent-foreground",day_hidden:"invisible"},...b})})]})})]}),(n||r)&&m.jsx("p",{className:U("text-xs",r?"text-red-500":"text-gray-500"),children:r||n})]})}function Tt({label:e,placeholder:t="Select option",options:n,leadingIcon:r,helperText:o,error:s,required:i,onValueChange:a,className:c,variant:l="default",disabled:f=!1}){return m.jsxs("div",{className:U("space-y-1",c),children:[e&&m.jsxs(yt,{className:U("text-sm font-medium",f?"text-gray-400":"text-gray-700"),children:[e,i&&m.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),m.jsxs(Rr,{onValueChange:a,disabled:f,children:[m.jsx(Dn,{className:U(s&&"border-red-500 focus:ring-red-500",l==="gray"&&"bg-gray-100 border-gray-300 text-gray-700",f&&"opacity-50 cursor-not-allowed"),children:m.jsxs("div",{className:"flex items-center gap-2 w-full",children:[r&&m.jsx("div",{className:"text-gray-400",children:r}),m.jsx(_r,{placeholder:t})]})}),m.jsx(On,{children:n.map(u=>m.jsx(En,{value:u.value,children:u.label},u.value))})]}),(o||s)&&m.jsx("p",{className:U("text-xs",s?"text-red-500":f?"text-gray-400":"text-gray-500"),children:s||o})]})}const Hg=({label:e,variant:t="filled",color:n="default",size:r="medium",deletable:o=!1,onDelete:s,onClick:i,icon:a,avatar:c,disabled:l=!1,className:f="",...u})=>{const h="inline-flex items-center gap-1 font-medium transition-all duration-200 focus:outline-none focus:ring-2 focus:ring-offset-2",g={small:"px-2 py-0.5 text-xs rounded-full",medium:"px-3 py-1 text-sm rounded-full",large:"px-4 py-1.5 text-base rounded-lg"},b={default:{filled:"bg-gray-200 text-gray-800 hover:bg-gray-300",outlined:"border border-gray-300 text-gray-700 hover:bg-gray-50"},primary:{filled:"bg-blue-500 text-white hover:bg-blue-600",outlined:"border border-blue-500 text-blue-600 hover:bg-blue-50"},secondary:{filled:"bg-purple-500 text-white hover:bg-purple-600",outlined:"border border-purple-500 text-purple-600 hover:bg-purple-50"},success:{filled:"bg-green-500 text-white hover:bg-green-600",outlined:"border border-green-500 text-green-600 hover:bg-green-50"},warning:{filled:"bg-yellow-500 text-white hover:bg-yellow-600",outlined:"border border-yellow-500 text-yellow-600 hover:bg-yellow-50"},error:{filled:"bg-red-500 text-white hover:bg-red-600",outlined:"border border-red-500 text-red-600 hover:bg-red-50"}},p=l?"opacity-50 cursor-not-allowed":"cursor-pointer",v=i&&!l?"hover:shadow-md":"",S=`
142
- ${h}
143
- ${g[r]}
144
- ${b[n][t]}
146
+ `)},wv=0,dn=[];function xv(e){var t=d.useRef([]),n=d.useRef([0,0]),r=d.useRef(),o=d.useState(wv++)[0],a=d.useState(xc)[0],s=d.useRef(e);d.useEffect(function(){s.current=e},[e]),d.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var g=Yg([e.lockRef.current],(e.shards||[]).map(Gs),!0).filter(Boolean);return g.forEach(function(y){return y.classList.add("allow-interactivity-".concat(o))}),function(){document.body.classList.remove("block-interactivity-".concat(o)),g.forEach(function(y){return y.classList.remove("allow-interactivity-".concat(o))})}}},[e.inert,e.lockRef.current,e.shards]);var i=d.useCallback(function(g,y){if("touches"in g&&g.touches.length===2||g.type==="wheel"&&g.ctrlKey)return!s.current.allowPinchZoom;var w=Mr(g),x=n.current,S="deltaX"in g?g.deltaX:x[0]-w[0],k="deltaY"in g?g.deltaY:x[1]-w[1],C,N=g.target,M=Math.abs(S)>Math.abs(k)?"h":"v";if("touches"in g&&M==="h"&&N.type==="range")return!1;var D=Hs(M,N);if(!D)return!0;if(D?C=M:(C=M==="v"?"h":"v",D=Hs(M,N)),!D)return!1;if(!r.current&&"changedTouches"in g&&(S||k)&&(r.current=C),!C)return!0;var L=r.current||C;return vv(L,y,g,L==="h"?S:k)},[]),l=d.useCallback(function(g){var y=g;if(!(!dn.length||dn[dn.length-1]!==a)){var w="deltaY"in y?zs(y):Mr(y),x=t.current.filter(function(C){return C.name===y.type&&(C.target===y.target||y.target===C.shadowParent)&&yv(C.delta,w)})[0];if(x&&x.should){y.cancelable&&y.preventDefault();return}if(!x){var S=(s.current.shards||[]).map(Gs).filter(Boolean).filter(function(C){return C.contains(y.target)}),k=S.length>0?i(y,S[0]):!s.current.noIsolation;k&&y.cancelable&&y.preventDefault()}}},[]),u=d.useCallback(function(g,y,w,x){var S={name:g,delta:y,target:w,should:x,shadowParent:Sv(w)};t.current.push(S),setTimeout(function(){t.current=t.current.filter(function(k){return k!==S})},1)},[]),m=d.useCallback(function(g){n.current=Mr(g),r.current=void 0},[]),c=d.useCallback(function(g){u(g.type,zs(g),g.target,i(g,e.lockRef.current))},[]),p=d.useCallback(function(g){u(g.type,Mr(g),g.target,i(g,e.lockRef.current))},[]);d.useEffect(function(){return dn.push(a),e.setCallbacks({onScrollCapture:c,onWheelCapture:c,onTouchMoveCapture:p}),document.addEventListener("wheel",l,un),document.addEventListener("touchmove",l,un),document.addEventListener("touchstart",m,un),function(){dn=dn.filter(function(g){return g!==a}),document.removeEventListener("wheel",l,un),document.removeEventListener("touchmove",l,un),document.removeEventListener("touchstart",m,un)}},[]);var h=e.removeScrollBar,v=e.inert;return d.createElement(d.Fragment,null,v?d.createElement(a,{styles:bv(o)}):null,h?d.createElement(uv,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function Sv(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const Cv=Zg(wc,xv);var ar=d.forwardRef(function(e,t){return d.createElement(no,ft({},e,{ref:t,sideCar:Cv}))});ar.classNames=no.classNames;var ro="Popover",[Ec,SM]=Ye(ro,[$t]),sr=$t(),[Mv,Lt]=Ec(ro),kc=e=>{const{__scopePopover:t,children:n,open:r,defaultOpen:o,onOpenChange:a,modal:s=!1}=e,i=sr(t),l=d.useRef(null),[u,m]=d.useState(!1),[c,p]=tt({prop:r,defaultProp:o??!1,onChange:a,caller:ro});return f.jsx(nr,{...i,children:f.jsx(Mv,{scope:t,contentId:ke(),triggerRef:l,open:c,onOpenChange:p,onOpenToggle:d.useCallback(()=>p(h=>!h),[p]),hasCustomAnchor:u,onCustomAnchorAdd:d.useCallback(()=>m(!0),[]),onCustomAnchorRemove:d.useCallback(()=>m(!1),[]),modal:s,children:n})})};kc.displayName=ro;var Nc="PopoverAnchor",Ev=d.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,o=Lt(Nc,n),a=sr(n),{onCustomAnchorAdd:s,onCustomAnchorRemove:i}=o;return d.useEffect(()=>(s(),()=>i()),[s,i]),f.jsx(rr,{...a,...r,ref:t})});Ev.displayName=Nc;var Dc="PopoverTrigger",Rc=d.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,o=Lt(Dc,n),a=sr(n),s=he(t,o.triggerRef),i=f.jsx(te.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":Ac(o.open),...r,ref:s,onClick:K(e.onClick,o.onOpenToggle)});return o.hasCustomAnchor?i:f.jsx(rr,{asChild:!0,...a,children:i})});Rc.displayName=Dc;var Aa="PopoverPortal",[kv,Nv]=Ec(Aa,{forceMount:void 0}),Tc=e=>{const{__scopePopover:t,forceMount:n,children:r,container:o}=e,a=Lt(Aa,t);return f.jsx(kv,{scope:t,forceMount:n,children:f.jsx(He,{present:n||a.open,children:f.jsx(or,{asChild:!0,container:o,children:r})})})};Tc.displayName=Aa;var yn="PopoverContent",Oc=d.forwardRef((e,t)=>{const n=Nv(yn,e.__scopePopover),{forceMount:r=n.forceMount,...o}=e,a=Lt(yn,e.__scopePopover);return f.jsx(He,{present:r||a.open,children:a.modal?f.jsx(Rv,{...o,ref:t}):f.jsx(Tv,{...o,ref:t})})});Oc.displayName=yn;var Dv=Pt("PopoverContent.RemoveScroll"),Rv=d.forwardRef((e,t)=>{const n=Lt(yn,e.__scopePopover),r=d.useRef(null),o=he(t,r),a=d.useRef(!1);return d.useEffect(()=>{const s=r.current;if(s)return to(s)},[]),f.jsx(ar,{as:Dv,allowPinchZoom:!0,children:f.jsx(_c,{...e,ref:o,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:K(e.onCloseAutoFocus,s=>{var i;s.preventDefault(),a.current||(i=n.triggerRef.current)==null||i.focus()}),onPointerDownOutside:K(e.onPointerDownOutside,s=>{const i=s.detail.originalEvent,l=i.button===0&&i.ctrlKey===!0,u=i.button===2||l;a.current=u},{checkForDefaultPrevented:!1}),onFocusOutside:K(e.onFocusOutside,s=>s.preventDefault(),{checkForDefaultPrevented:!1})})})}),Tv=d.forwardRef((e,t)=>{const n=Lt(yn,e.__scopePopover),r=d.useRef(!1),o=d.useRef(!1);return f.jsx(_c,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:a=>{var s,i;(s=e.onCloseAutoFocus)==null||s.call(e,a),a.defaultPrevented||(r.current||(i=n.triggerRef.current)==null||i.focus(),a.preventDefault()),r.current=!1,o.current=!1},onInteractOutside:a=>{var l,u;(l=e.onInteractOutside)==null||l.call(e,a),a.defaultPrevented||(r.current=!0,a.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const s=a.target;((u=n.triggerRef.current)==null?void 0:u.contains(s))&&a.preventDefault(),a.detail.originalEvent.type==="focusin"&&o.current&&a.preventDefault()}})}),_c=d.forwardRef((e,t)=>{const{__scopePopover:n,trapFocus:r,onOpenAutoFocus:o,onCloseAutoFocus:a,disableOutsidePointerEvents:s,onEscapeKeyDown:i,onPointerDownOutside:l,onFocusOutside:u,onInteractOutside:m,...c}=e,p=Lt(yn,n),h=sr(n);return Kr(),f.jsx(er,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:o,onUnmountAutoFocus:a,children:f.jsx(kn,{asChild:!0,disableOutsidePointerEvents:s,onInteractOutside:m,onEscapeKeyDown:i,onPointerDownOutside:l,onFocusOutside:u,onDismiss:()=>p.onOpenChange(!1),children:f.jsx(Jr,{"data-state":Ac(p.open),role:"dialog",id:p.contentId,...h,...c,ref:t,style:{...c.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)"}})})})}),Pc="PopoverClose",Ov=d.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,o=Lt(Pc,n);return f.jsx(te.button,{type:"button",...r,ref:t,onClick:K(e.onClick,()=>o.onOpenChange(!1))})});Ov.displayName=Pc;var _v="PopoverArrow",Pv=d.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,o=sr(n);return f.jsx(eo,{...o,...r,ref:t})});Pv.displayName=_v;function Ac(e){return e?"open":"closed"}var Av=kc,Iv=Rc,jv=Tc,Ic=Oc;const jc=Av,$c=Iv,Ia=d.forwardRef(({className:e,sideOffset:t=4,...n},r)=>f.jsx(jv,{children:f.jsx(Ic,{ref:r,sideOffset:t,className:q("z-50 w-72 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...n})}));Ia.displayName=Ic.displayName;function Us(e,[t,n]){return Math.min(n,Math.max(t,e))}function ja(e){const t=e+"CollectionProvider",[n,r]=Ye(t),[o,a]=n(t,{collectionRef:{current:null},itemMap:new Map}),s=g=>{const{scope:y,children:w}=g,x=b.useRef(null),S=b.useRef(new Map).current;return f.jsx(o,{scope:y,itemMap:S,collectionRef:x,children:w})};s.displayName=t;const i=e+"CollectionSlot",l=Pt(i),u=b.forwardRef((g,y)=>{const{scope:w,children:x}=g,S=a(i,w),k=he(y,S.collectionRef);return f.jsx(l,{ref:k,children:x})});u.displayName=i;const m=e+"CollectionItemSlot",c="data-radix-collection-item",p=Pt(m),h=b.forwardRef((g,y)=>{const{scope:w,children:x,...S}=g,k=b.useRef(null),C=he(y,k),N=a(m,w);return b.useEffect(()=>(N.itemMap.set(k,{ref:k,...S}),()=>void N.itemMap.delete(k))),f.jsx(p,{[c]:"",ref:C,children:x})});h.displayName=m;function v(g){const y=a(e+"CollectionConsumer",g);return b.useCallback(()=>{const x=y.collectionRef.current;if(!x)return[];const S=Array.from(x.querySelectorAll(`[${c}]`));return Array.from(y.itemMap.values()).sort((N,M)=>S.indexOf(N.ref.current)-S.indexOf(M.ref.current))},[y.collectionRef,y.itemMap])}return[{Provider:s,Slot:u,ItemSlot:h},v,r]}var $v=d.createContext(void 0);function ir(e){const t=d.useContext($v);return e||t||"ltr"}function $a(e){const t=d.useRef({value:e,previous:e});return d.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}var Lc=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"}),Lv="VisuallyHidden",Fc=d.forwardRef((e,t)=>f.jsx(te.span,{...e,ref:t,style:{...Lc,...e.style}}));Fc.displayName=Lv;var Fv=Fc,Wv=[" ","Enter","ArrowUp","ArrowDown"],Bv=[" ","Enter"],Zt="Select",[oo,ao,Yv]=ja(Zt),[Rn,CM]=Ye(Zt,[Yv,$t]),so=$t(),[Hv,Ft]=Rn(Zt),[zv,Gv]=Rn(Zt),Wc=e=>{const{__scopeSelect:t,children:n,open:r,defaultOpen:o,onOpenChange:a,value:s,defaultValue:i,onValueChange:l,dir:u,name:m,autoComplete:c,disabled:p,required:h,form:v}=e,g=so(t),[y,w]=d.useState(null),[x,S]=d.useState(null),[k,C]=d.useState(!1),N=ir(u),[M,D]=tt({prop:r,defaultProp:o??!1,onChange:a,caller:Zt}),[L,B]=tt({prop:s,defaultProp:i,onChange:l,caller:Zt}),F=d.useRef(null),V=y?v||!!y.closest("form"):!0,[$,I]=d.useState(new Set),_=Array.from($).map(R=>R.props.value).join(";");return f.jsx(nr,{...g,children:f.jsxs(Hv,{required:h,scope:t,trigger:y,onTriggerChange:w,valueNode:x,onValueNodeChange:S,valueNodeHasChildren:k,onValueNodeHasChildrenChange:C,contentId:ke(),value:L,onValueChange:B,open:M,onOpenChange:D,dir:N,triggerPointerDownPosRef:F,disabled:p,children:[f.jsx(oo.Provider,{scope:t,children:f.jsx(zv,{scope:e.__scopeSelect,onNativeOptionAdd:d.useCallback(R=>{I(P=>new Set(P).add(R))},[]),onNativeOptionRemove:d.useCallback(R=>{I(P=>{const E=new Set(P);return E.delete(R),E})},[]),children:n})}),V?f.jsxs(ul,{"aria-hidden":!0,required:h,tabIndex:-1,name:m,autoComplete:c,value:L,onChange:R=>B(R.target.value),disabled:p,form:v,children:[L===void 0?f.jsx("option",{value:""}):null,Array.from($)]},_):null]})})};Wc.displayName=Zt;var Bc="SelectTrigger",Yc=d.forwardRef((e,t)=>{const{__scopeSelect:n,disabled:r=!1,...o}=e,a=so(n),s=Ft(Bc,n),i=s.disabled||r,l=he(t,s.onTriggerChange),u=ao(n),m=d.useRef("touch"),[c,p,h]=fl(g=>{const y=u().filter(S=>!S.disabled),w=y.find(S=>S.value===s.value),x=ml(y,g,w);x!==void 0&&s.onValueChange(x.value)}),v=g=>{i||(s.onOpenChange(!0),h()),g&&(s.triggerPointerDownPosRef.current={x:Math.round(g.pageX),y:Math.round(g.pageY)})};return f.jsx(rr,{asChild:!0,...a,children:f.jsx(te.button,{type:"button",role:"combobox","aria-controls":s.contentId,"aria-expanded":s.open,"aria-required":s.required,"aria-autocomplete":"none",dir:s.dir,"data-state":s.open?"open":"closed",disabled:i,"data-disabled":i?"":void 0,"data-placeholder":dl(s.value)?"":void 0,...o,ref:l,onClick:K(o.onClick,g=>{g.currentTarget.focus(),m.current!=="mouse"&&v(g)}),onPointerDown:K(o.onPointerDown,g=>{m.current=g.pointerType;const y=g.target;y.hasPointerCapture(g.pointerId)&&y.releasePointerCapture(g.pointerId),g.button===0&&g.ctrlKey===!1&&g.pointerType==="mouse"&&(v(g),g.preventDefault())}),onKeyDown:K(o.onKeyDown,g=>{const y=c.current!=="";!(g.ctrlKey||g.altKey||g.metaKey)&&g.key.length===1&&p(g.key),!(y&&g.key===" ")&&Wv.includes(g.key)&&(v(),g.preventDefault())})})})});Yc.displayName=Bc;var Hc="SelectValue",zc=d.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:o,children:a,placeholder:s="",...i}=e,l=Ft(Hc,n),{onValueNodeHasChildrenChange:u}=l,m=a!==void 0,c=he(t,l.onValueNodeChange);return De(()=>{u(m)},[u,m]),f.jsx(te.span,{...i,ref:c,style:{pointerEvents:"none"},children:dl(l.value)?f.jsx(f.Fragment,{children:s}):a})});zc.displayName=Hc;var Uv="SelectIcon",Gc=d.forwardRef((e,t)=>{const{__scopeSelect:n,children:r,...o}=e;return f.jsx(te.span,{"aria-hidden":!0,...o,ref:t,children:r||"▼"})});Gc.displayName=Uv;var qv="SelectPortal",Uc=e=>f.jsx(or,{asChild:!0,...e});Uc.displayName=qv;var Qt="SelectContent",qc=d.forwardRef((e,t)=>{const n=Ft(Qt,e.__scopeSelect),[r,o]=d.useState();if(De(()=>{o(new DocumentFragment)},[]),!n.open){const a=r;return a?qr.createPortal(f.jsx(Vc,{scope:e.__scopeSelect,children:f.jsx(oo.Slot,{scope:e.__scopeSelect,children:f.jsx("div",{children:e.children})})}),a):null}return f.jsx(Kc,{...e,ref:t})});qc.displayName=Qt;var ot=10,[Vc,Wt]=Rn(Qt),Vv="SelectContentImpl",Kv=Pt("SelectContent.RemoveScroll"),Kc=d.forwardRef((e,t)=>{const{__scopeSelect:n,position:r="item-aligned",onCloseAutoFocus:o,onEscapeKeyDown:a,onPointerDownOutside:s,side:i,sideOffset:l,align:u,alignOffset:m,arrowPadding:c,collisionBoundary:p,collisionPadding:h,sticky:v,hideWhenDetached:g,avoidCollisions:y,...w}=e,x=Ft(Qt,n),[S,k]=d.useState(null),[C,N]=d.useState(null),M=he(t,j=>k(j)),[D,L]=d.useState(null),[B,F]=d.useState(null),V=ao(n),[$,I]=d.useState(!1),_=d.useRef(!1);d.useEffect(()=>{if(S)return to(S)},[S]),Kr();const R=d.useCallback(j=>{const[Z,...X]=V().map(de=>de.ref.current),[Q]=X.slice(-1),le=document.activeElement;for(const de of j)if(de===le||(de==null||de.scrollIntoView({block:"nearest"}),de===Z&&C&&(C.scrollTop=0),de===Q&&C&&(C.scrollTop=C.scrollHeight),de==null||de.focus(),document.activeElement!==le))return},[V,C]),P=d.useCallback(()=>R([D,S]),[R,D,S]);d.useEffect(()=>{$&&P()},[$,P]);const{onOpenChange:E,triggerPointerDownPosRef:O}=x;d.useEffect(()=>{if(S){let j={x:0,y:0};const Z=Q=>{var le,de;j={x:Math.abs(Math.round(Q.pageX)-(((le=O.current)==null?void 0:le.x)??0)),y:Math.abs(Math.round(Q.pageY)-(((de=O.current)==null?void 0:de.y)??0))}},X=Q=>{j.x<=10&&j.y<=10?Q.preventDefault():S.contains(Q.target)||E(!1),document.removeEventListener("pointermove",Z),O.current=null};return O.current!==null&&(document.addEventListener("pointermove",Z),document.addEventListener("pointerup",X,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",Z),document.removeEventListener("pointerup",X,{capture:!0})}}},[S,E,O]),d.useEffect(()=>{const j=()=>E(!1);return window.addEventListener("blur",j),window.addEventListener("resize",j),()=>{window.removeEventListener("blur",j),window.removeEventListener("resize",j)}},[E]);const[Y,G]=fl(j=>{const Z=V().filter(le=>!le.disabled),X=Z.find(le=>le.ref.current===document.activeElement),Q=ml(Z,j,X);Q&&setTimeout(()=>Q.ref.current.focus())}),T=d.useCallback((j,Z,X)=>{const Q=!_.current&&!X;(x.value!==void 0&&x.value===Z||Q)&&(L(j),Q&&(_.current=!0))},[x.value]),A=d.useCallback(()=>S==null?void 0:S.focus(),[S]),W=d.useCallback((j,Z,X)=>{const Q=!_.current&&!X;(x.value!==void 0&&x.value===Z||Q)&&F(j)},[x.value]),H=r==="popper"?ra:Xc,U=H===ra?{side:i,sideOffset:l,align:u,alignOffset:m,arrowPadding:c,collisionBoundary:p,collisionPadding:h,sticky:v,hideWhenDetached:g,avoidCollisions:y}:{};return f.jsx(Vc,{scope:n,content:S,viewport:C,onViewportChange:N,itemRefCallback:T,selectedItem:D,onItemLeave:A,itemTextRefCallback:W,focusSelectedItem:P,selectedItemText:B,position:r,isPositioned:$,searchRef:Y,children:f.jsx(ar,{as:Kv,allowPinchZoom:!0,children:f.jsx(er,{asChild:!0,trapped:x.open,onMountAutoFocus:j=>{j.preventDefault()},onUnmountAutoFocus:K(o,j=>{var Z;(Z=x.trigger)==null||Z.focus({preventScroll:!0}),j.preventDefault()}),children:f.jsx(kn,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:a,onPointerDownOutside:s,onFocusOutside:j=>j.preventDefault(),onDismiss:()=>x.onOpenChange(!1),children:f.jsx(H,{role:"listbox",id:x.contentId,"data-state":x.open?"open":"closed",dir:x.dir,onContextMenu:j=>j.preventDefault(),...w,...U,onPlaced:()=>I(!0),ref:M,style:{display:"flex",flexDirection:"column",outline:"none",...w.style},onKeyDown:K(w.onKeyDown,j=>{const Z=j.ctrlKey||j.altKey||j.metaKey;if(j.key==="Tab"&&j.preventDefault(),!Z&&j.key.length===1&&G(j.key),["ArrowUp","ArrowDown","Home","End"].includes(j.key)){let Q=V().filter(le=>!le.disabled).map(le=>le.ref.current);if(["ArrowUp","End"].includes(j.key)&&(Q=Q.slice().reverse()),["ArrowUp","ArrowDown"].includes(j.key)){const le=j.target,de=Q.indexOf(le);Q=Q.slice(de+1)}setTimeout(()=>R(Q)),j.preventDefault()}})})})})})})});Kc.displayName=Vv;var Xv="SelectItemAlignedPosition",Xc=d.forwardRef((e,t)=>{const{__scopeSelect:n,onPlaced:r,...o}=e,a=Ft(Qt,n),s=Wt(Qt,n),[i,l]=d.useState(null),[u,m]=d.useState(null),c=he(t,M=>m(M)),p=ao(n),h=d.useRef(!1),v=d.useRef(!0),{viewport:g,selectedItem:y,selectedItemText:w,focusSelectedItem:x}=s,S=d.useCallback(()=>{if(a.trigger&&a.valueNode&&i&&u&&g&&y&&w){const M=a.trigger.getBoundingClientRect(),D=u.getBoundingClientRect(),L=a.valueNode.getBoundingClientRect(),B=w.getBoundingClientRect();if(a.dir!=="rtl"){const le=B.left-D.left,de=L.left-le,xe=M.left-de,re=M.width+xe,ze=Math.max(re,D.width),We=window.innerWidth-ot,ie=Us(de,[ot,Math.max(ot,We-ze)]);i.style.minWidth=re+"px",i.style.left=ie+"px"}else{const le=D.right-B.right,de=window.innerWidth-L.right-le,xe=window.innerWidth-M.right-de,re=M.width+xe,ze=Math.max(re,D.width),We=window.innerWidth-ot,ie=Us(de,[ot,Math.max(ot,We-ze)]);i.style.minWidth=re+"px",i.style.right=ie+"px"}const F=p(),V=window.innerHeight-ot*2,$=g.scrollHeight,I=window.getComputedStyle(u),_=parseInt(I.borderTopWidth,10),R=parseInt(I.paddingTop,10),P=parseInt(I.borderBottomWidth,10),E=parseInt(I.paddingBottom,10),O=_+R+$+E+P,Y=Math.min(y.offsetHeight*5,O),G=window.getComputedStyle(g),T=parseInt(G.paddingTop,10),A=parseInt(G.paddingBottom,10),W=M.top+M.height/2-ot,H=V-W,U=y.offsetHeight/2,j=y.offsetTop+U,Z=_+R+j,X=O-Z;if(Z<=W){const le=F.length>0&&y===F[F.length-1].ref.current;i.style.bottom="0px";const de=u.clientHeight-g.offsetTop-g.offsetHeight,xe=Math.max(H,U+(le?A:0)+de+P),re=Z+xe;i.style.height=re+"px"}else{const le=F.length>0&&y===F[0].ref.current;i.style.top="0px";const xe=Math.max(W,_+g.offsetTop+(le?T:0)+U)+X;i.style.height=xe+"px",g.scrollTop=Z-W+g.offsetTop}i.style.margin=`${ot}px 0`,i.style.minHeight=Y+"px",i.style.maxHeight=V+"px",r==null||r(),requestAnimationFrame(()=>h.current=!0)}},[p,a.trigger,a.valueNode,i,u,g,y,w,a.dir,r]);De(()=>S(),[S]);const[k,C]=d.useState();De(()=>{u&&C(window.getComputedStyle(u).zIndex)},[u]);const N=d.useCallback(M=>{M&&v.current===!0&&(S(),x==null||x(),v.current=!1)},[S,x]);return f.jsx(Qv,{scope:n,contentWrapper:i,shouldExpandOnScrollRef:h,onScrollButtonChange:N,children:f.jsx("div",{ref:l,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:k},children:f.jsx(te.div,{...o,ref:c,style:{boxSizing:"border-box",maxHeight:"100%",...o.style}})})})});Xc.displayName=Xv;var Zv="SelectPopperPosition",ra=d.forwardRef((e,t)=>{const{__scopeSelect:n,align:r="start",collisionPadding:o=ot,...a}=e,s=so(n);return f.jsx(Jr,{...s,...a,ref:t,align:r,collisionPadding:o,style:{boxSizing:"border-box",...a.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)"}})});ra.displayName=Zv;var[Qv,La]=Rn(Qt,{}),oa="SelectViewport",Zc=d.forwardRef((e,t)=>{const{__scopeSelect:n,nonce:r,...o}=e,a=Wt(oa,n),s=La(oa,n),i=he(t,a.onViewportChange),l=d.useRef(0);return f.jsxs(f.Fragment,{children:[f.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:r}),f.jsx(oo.Slot,{scope:n,children:f.jsx(te.div,{"data-radix-select-viewport":"",role:"presentation",...o,ref:i,style:{position:"relative",flex:1,overflow:"hidden auto",...o.style},onScroll:K(o.onScroll,u=>{const m=u.currentTarget,{contentWrapper:c,shouldExpandOnScrollRef:p}=s;if(p!=null&&p.current&&c){const h=Math.abs(l.current-m.scrollTop);if(h>0){const v=window.innerHeight-ot*2,g=parseFloat(c.style.minHeight),y=parseFloat(c.style.height),w=Math.max(g,y);if(w<v){const x=w+h,S=Math.min(v,x),k=x-S;c.style.height=S+"px",c.style.bottom==="0px"&&(m.scrollTop=k>0?k:0,c.style.justifyContent="flex-end")}}}l.current=m.scrollTop})})})]})});Zc.displayName=oa;var Qc="SelectGroup",[Jv,ey]=Rn(Qc),ty=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=ke();return f.jsx(Jv,{scope:n,id:o,children:f.jsx(te.div,{role:"group","aria-labelledby":o,...r,ref:t})})});ty.displayName=Qc;var Jc="SelectLabel",el=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=ey(Jc,n);return f.jsx(te.div,{id:o.id,...r,ref:t})});el.displayName=Jc;var Fr="SelectItem",[ny,tl]=Rn(Fr),nl=d.forwardRef((e,t)=>{const{__scopeSelect:n,value:r,disabled:o=!1,textValue:a,...s}=e,i=Ft(Fr,n),l=Wt(Fr,n),u=i.value===r,[m,c]=d.useState(a??""),[p,h]=d.useState(!1),v=he(t,x=>{var S;return(S=l.itemRefCallback)==null?void 0:S.call(l,x,r,o)}),g=ke(),y=d.useRef("touch"),w=()=>{o||(i.onValueChange(r),i.onOpenChange(!1))};if(r==="")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 f.jsx(ny,{scope:n,value:r,disabled:o,textId:g,isSelected:u,onItemTextChange:d.useCallback(x=>{c(S=>S||((x==null?void 0:x.textContent)??"").trim())},[]),children:f.jsx(oo.ItemSlot,{scope:n,value:r,disabled:o,textValue:m,children:f.jsx(te.div,{role:"option","aria-labelledby":g,"data-highlighted":p?"":void 0,"aria-selected":u&&p,"data-state":u?"checked":"unchecked","aria-disabled":o||void 0,"data-disabled":o?"":void 0,tabIndex:o?void 0:-1,...s,ref:v,onFocus:K(s.onFocus,()=>h(!0)),onBlur:K(s.onBlur,()=>h(!1)),onClick:K(s.onClick,()=>{y.current!=="mouse"&&w()}),onPointerUp:K(s.onPointerUp,()=>{y.current==="mouse"&&w()}),onPointerDown:K(s.onPointerDown,x=>{y.current=x.pointerType}),onPointerMove:K(s.onPointerMove,x=>{var S;y.current=x.pointerType,o?(S=l.onItemLeave)==null||S.call(l):y.current==="mouse"&&x.currentTarget.focus({preventScroll:!0})}),onPointerLeave:K(s.onPointerLeave,x=>{var S;x.currentTarget===document.activeElement&&((S=l.onItemLeave)==null||S.call(l))}),onKeyDown:K(s.onKeyDown,x=>{var k;((k=l.searchRef)==null?void 0:k.current)!==""&&x.key===" "||(Bv.includes(x.key)&&w(),x.key===" "&&x.preventDefault())})})})})});nl.displayName=Fr;var Yn="SelectItemText",rl=d.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:o,...a}=e,s=Ft(Yn,n),i=Wt(Yn,n),l=tl(Yn,n),u=Gv(Yn,n),[m,c]=d.useState(null),p=he(t,w=>c(w),l.onItemTextChange,w=>{var x;return(x=i.itemTextRefCallback)==null?void 0:x.call(i,w,l.value,l.disabled)}),h=m==null?void 0:m.textContent,v=d.useMemo(()=>f.jsx("option",{value:l.value,disabled:l.disabled,children:h},l.value),[l.disabled,l.value,h]),{onNativeOptionAdd:g,onNativeOptionRemove:y}=u;return De(()=>(g(v),()=>y(v)),[g,y,v]),f.jsxs(f.Fragment,{children:[f.jsx(te.span,{id:l.textId,...a,ref:p}),l.isSelected&&s.valueNode&&!s.valueNodeHasChildren?qr.createPortal(a.children,s.valueNode):null]})});rl.displayName=Yn;var ol="SelectItemIndicator",al=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return tl(ol,n).isSelected?f.jsx(te.span,{"aria-hidden":!0,...r,ref:t}):null});al.displayName=ol;var aa="SelectScrollUpButton",sl=d.forwardRef((e,t)=>{const n=Wt(aa,e.__scopeSelect),r=La(aa,e.__scopeSelect),[o,a]=d.useState(!1),s=he(t,r.onScrollButtonChange);return De(()=>{if(n.viewport&&n.isPositioned){let i=function(){const u=l.scrollTop>0;a(u)};const l=n.viewport;return i(),l.addEventListener("scroll",i),()=>l.removeEventListener("scroll",i)}},[n.viewport,n.isPositioned]),o?f.jsx(cl,{...e,ref:s,onAutoScroll:()=>{const{viewport:i,selectedItem:l}=n;i&&l&&(i.scrollTop=i.scrollTop-l.offsetHeight)}}):null});sl.displayName=aa;var sa="SelectScrollDownButton",il=d.forwardRef((e,t)=>{const n=Wt(sa,e.__scopeSelect),r=La(sa,e.__scopeSelect),[o,a]=d.useState(!1),s=he(t,r.onScrollButtonChange);return De(()=>{if(n.viewport&&n.isPositioned){let i=function(){const u=l.scrollHeight-l.clientHeight,m=Math.ceil(l.scrollTop)<u;a(m)};const l=n.viewport;return i(),l.addEventListener("scroll",i),()=>l.removeEventListener("scroll",i)}},[n.viewport,n.isPositioned]),o?f.jsx(cl,{...e,ref:s,onAutoScroll:()=>{const{viewport:i,selectedItem:l}=n;i&&l&&(i.scrollTop=i.scrollTop+l.offsetHeight)}}):null});il.displayName=sa;var cl=d.forwardRef((e,t)=>{const{__scopeSelect:n,onAutoScroll:r,...o}=e,a=Wt("SelectScrollButton",n),s=d.useRef(null),i=ao(n),l=d.useCallback(()=>{s.current!==null&&(window.clearInterval(s.current),s.current=null)},[]);return d.useEffect(()=>()=>l(),[l]),De(()=>{var m;const u=i().find(c=>c.ref.current===document.activeElement);(m=u==null?void 0:u.ref.current)==null||m.scrollIntoView({block:"nearest"})},[i]),f.jsx(te.div,{"aria-hidden":!0,...o,ref:t,style:{flexShrink:0,...o.style},onPointerDown:K(o.onPointerDown,()=>{s.current===null&&(s.current=window.setInterval(r,50))}),onPointerMove:K(o.onPointerMove,()=>{var u;(u=a.onItemLeave)==null||u.call(a),s.current===null&&(s.current=window.setInterval(r,50))}),onPointerLeave:K(o.onPointerLeave,()=>{l()})})}),ry="SelectSeparator",ll=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return f.jsx(te.div,{"aria-hidden":!0,...r,ref:t})});ll.displayName=ry;var ia="SelectArrow",oy=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=so(n),a=Ft(ia,n),s=Wt(ia,n);return a.open&&s.position==="popper"?f.jsx(eo,{...o,...r,ref:t}):null});oy.displayName=ia;var ay="SelectBubbleInput",ul=d.forwardRef(({__scopeSelect:e,value:t,...n},r)=>{const o=d.useRef(null),a=he(r,o),s=$a(t);return d.useEffect(()=>{const i=o.current;if(!i)return;const l=window.HTMLSelectElement.prototype,m=Object.getOwnPropertyDescriptor(l,"value").set;if(s!==t&&m){const c=new Event("change",{bubbles:!0});m.call(i,t),i.dispatchEvent(c)}},[s,t]),f.jsx(te.select,{...n,style:{...Lc,...n.style},ref:a,defaultValue:t})});ul.displayName=ay;function dl(e){return e===""||e===void 0}function fl(e){const t=et(e),n=d.useRef(""),r=d.useRef(0),o=d.useCallback(s=>{const i=n.current+s;t(i),function l(u){n.current=u,window.clearTimeout(r.current),u!==""&&(r.current=window.setTimeout(()=>l(""),1e3))}(i)},[t]),a=d.useCallback(()=>{n.current="",window.clearTimeout(r.current)},[]);return d.useEffect(()=>()=>window.clearTimeout(r.current),[]),[n,o,a]}function ml(e,t,n){const o=t.length>1&&Array.from(t).every(u=>u===t[0])?t[0]:t,a=n?e.indexOf(n):-1;let s=sy(e,Math.max(a,0));o.length===1&&(s=s.filter(u=>u!==n));const l=s.find(u=>u.textValue.toLowerCase().startsWith(o.toLowerCase()));return l!==n?l:void 0}function sy(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var iy=Wc,pl=Yc,cy=zc,ly=Gc,uy=Uc,hl=qc,dy=Zc,gl=el,vl=nl,fy=rl,my=al,yl=sl,bl=il,wl=ll;const ca=iy,la=cy,Wr=d.forwardRef(({className:e,children:t,...n},r)=>f.jsxs(pl,{ref:r,className:q("flex h-10 w-full items-center justify-between rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background data-[placeholder]:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1",e),...n,children:[t,f.jsx(ly,{asChild:!0,children:f.jsx(Vr,{strokeWidth:1.5,className:"h-5 w-5 ml-6 text-black"})})]}));Wr.displayName=pl.displayName;const xl=d.forwardRef(({className:e,...t},n)=>f.jsx(yl,{ref:n,className:q("flex cursor-default items-center justify-center py-1",e),...t,children:f.jsx(_p,{className:"h-4 w-4"})}));xl.displayName=yl.displayName;const Sl=d.forwardRef(({className:e,...t},n)=>f.jsx(bl,{ref:n,className:q("flex cursor-default items-center justify-center py-1",e),...t,children:f.jsx(Vr,{className:"h-4 w-4"})}));Sl.displayName=bl.displayName;const Br=d.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>f.jsx(uy,{children:f.jsxs(hl,{ref:o,className:q("relative z-50 max-h-[--radix-select-content-available-height] min-w-[8rem] overflow-y-auto overflow-x-hidden rounded-md border bg-popover text-popover-foreground shadow-md data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-select-content-transform-origin]",n==="popper"&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",e),position:n,...r,children:[f.jsx(xl,{}),f.jsx(dy,{className:q("p-1",n==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"),children:t}),f.jsx(Sl,{})]})}));Br.displayName=hl.displayName;const py=d.forwardRef(({className:e,...t},n)=>f.jsx(gl,{ref:n,className:q("py-1.5 pl-8 pr-2 text-sm font-semibold",e),...t}));py.displayName=gl.displayName;const Yr=d.forwardRef(({className:e,children:t,...n},r)=>f.jsxs(vl,{ref:r,className:q("relative flex w-full cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...n,children:[f.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:f.jsx(my,{children:f.jsx(Jn,{className:"h-4 w-4"})})}),f.jsx(fy,{children:t})]}));Yr.displayName=vl.displayName;const hy=d.forwardRef(({className:e,...t},n)=>f.jsx(wl,{ref:n,className:q("-mx-1 my-1 h-px bg-muted",e),...t}));hy.displayName=wl.displayName;const Po={},Hn={};function Gn(e,t){try{const r=(Po[e]||(Po[e]=new Intl.DateTimeFormat("en-GB",{timeZone:e,hour:"numeric",timeZoneName:"longOffset"}).format))(t).split("GMT")[1]||"";return r in Hn?Hn[r]:qs(r,r.split(":"))}catch{if(e in Hn)return Hn[e];const n=e==null?void 0:e.match(gy);return n?qs(e,n.slice(1)):NaN}}const gy=/([+-]\d\d):?(\d\d)?/;function qs(e,t){const n=+t[0],r=+(t[1]||0);return Hn[e]=n>0?n*60+r:n*60-r}class pt extends Date{constructor(...t){super(),t.length>1&&typeof t[t.length-1]=="string"&&(this.timeZone=t.pop()),this.internal=new Date,isNaN(Gn(this.timeZone,this))?this.setTime(NaN):t.length?typeof t[0]=="number"&&(t.length===1||t.length===2&&typeof t[1]!="number")?this.setTime(t[0]):typeof t[0]=="string"?this.setTime(+new Date(t[0])):t[0]instanceof Date?this.setTime(+t[0]):(this.setTime(+new Date(...t)),Cl(this),ua(this)):this.setTime(Date.now())}static tz(t,...n){return n.length?new pt(...n,t):new pt(Date.now(),t)}withTimeZone(t){return new pt(+this,t)}getTimezoneOffset(){return-Gn(this.timeZone,this)}setTime(t){return Date.prototype.setTime.apply(this,arguments),ua(this),+this}[Symbol.for("constructDateFrom")](t){return new pt(+new Date(t),this.timeZone)}}const Vs=/^(get|set)(?!UTC)/;Object.getOwnPropertyNames(Date.prototype).forEach(e=>{if(!Vs.test(e))return;const t=e.replace(Vs,"$1UTC");pt.prototype[t]&&(e.startsWith("get")?pt.prototype[e]=function(){return this.internal[t]()}:(pt.prototype[e]=function(){return Date.prototype[t].apply(this.internal,arguments),vy(this),+this},pt.prototype[t]=function(){return Date.prototype[t].apply(this,arguments),ua(this),+this}))});function ua(e){e.internal.setTime(+e),e.internal.setUTCMinutes(e.internal.getUTCMinutes()-e.getTimezoneOffset())}function vy(e){Date.prototype.setFullYear.call(e,e.internal.getUTCFullYear(),e.internal.getUTCMonth(),e.internal.getUTCDate()),Date.prototype.setHours.call(e,e.internal.getUTCHours(),e.internal.getUTCMinutes(),e.internal.getUTCSeconds(),e.internal.getUTCMilliseconds()),Cl(e)}function Cl(e){const t=Gn(e.timeZone,e),n=new Date(+e);n.setUTCHours(n.getUTCHours()-1);const r=-new Date(+e).getTimezoneOffset(),o=-new Date(+n).getTimezoneOffset(),a=r-o,s=Date.prototype.getHours.apply(e)!==e.internal.getUTCHours();a&&s&&e.internal.setUTCMinutes(e.internal.getUTCMinutes()+a);const i=r-t;i&&Date.prototype.setUTCMinutes.call(e,Date.prototype.getUTCMinutes.call(e)+i);const l=Gn(e.timeZone,e),m=-new Date(+e).getTimezoneOffset()-l,c=l!==t,p=m-i;if(c&&p){Date.prototype.setUTCMinutes.call(e,Date.prototype.getUTCMinutes.call(e)+p);const h=Gn(e.timeZone,e),v=l-h;v&&(e.internal.setUTCMinutes(e.internal.getUTCMinutes()+v),Date.prototype.setUTCMinutes.call(e,Date.prototype.getUTCMinutes.call(e)+v))}}class Le extends pt{static tz(t,...n){return n.length?new Le(...n,t):new Le(Date.now(),t)}toISOString(){const[t,n,r]=this.tzComponents(),o=`${t}${n}:${r}`;return this.internal.toISOString().slice(0,-1)+o}toString(){return`${this.toDateString()} ${this.toTimeString()}`}toDateString(){const[t,n,r,o]=this.internal.toUTCString().split(" ");return`${t==null?void 0:t.slice(0,-1)} ${r} ${n} ${o}`}toTimeString(){const t=this.internal.toUTCString().split(" ")[4],[n,r,o]=this.tzComponents();return`${t} GMT${n}${r}${o} (${yy(this.timeZone,this)})`}toLocaleString(t,n){return Date.prototype.toLocaleString.call(this,t,{...n,timeZone:(n==null?void 0:n.timeZone)||this.timeZone})}toLocaleDateString(t,n){return Date.prototype.toLocaleDateString.call(this,t,{...n,timeZone:(n==null?void 0:n.timeZone)||this.timeZone})}toLocaleTimeString(t,n){return Date.prototype.toLocaleTimeString.call(this,t,{...n,timeZone:(n==null?void 0:n.timeZone)||this.timeZone})}tzComponents(){const t=this.getTimezoneOffset(),n=t>0?"-":"+",r=String(Math.floor(Math.abs(t)/60)).padStart(2,"0"),o=String(Math.abs(t)%60).padStart(2,"0");return[n,r,o]}withTimeZone(t){return new Le(+this,t)}[Symbol.for("constructDateFrom")](t){return new Le(+new Date(t),this.timeZone)}}function yy(e,t){return new Intl.DateTimeFormat("en-GB",{timeZone:e,timeZoneName:"long"}).format(t).slice(12)}var se;(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"})(se||(se={}));var Ee;(function(e){e.disabled="disabled",e.hidden="hidden",e.outside="outside",e.focused="focused",e.today="today"})(Ee||(Ee={}));var at;(function(e){e.range_end="range_end",e.range_middle="range_middle",e.range_start="range_start",e.selected="selected"})(at||(at={}));var Ke;(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"})(Ke||(Ke={}));const Ml=6048e5,by=864e5,Ks=Symbol.for("constructDateFrom");function Oe(e,t){return typeof e=="function"?e(t):e&&typeof e=="object"&&Ks in e?e[Ks](t):e instanceof Date?new e.constructor(t):new Date(t)}function we(e,t){return Oe(t||e,e)}function El(e,t,n){const r=we(e,n==null?void 0:n.in);return isNaN(t)?Oe(e,NaN):(t&&r.setDate(r.getDate()+t),r)}function kl(e,t,n){const r=we(e,n==null?void 0:n.in);if(isNaN(t))return Oe(e,NaN);if(!t)return r;const o=r.getDate(),a=Oe(e,r.getTime());a.setMonth(r.getMonth()+t+1,0);const s=a.getDate();return o>=s?a:(r.setFullYear(a.getFullYear(),a.getMonth(),o),r)}let wy={};function cr(){return wy}function bn(e,t){var i,l,u,m;const n=cr(),r=(t==null?void 0:t.weekStartsOn)??((l=(i=t==null?void 0:t.locale)==null?void 0:i.options)==null?void 0:l.weekStartsOn)??n.weekStartsOn??((m=(u=n.locale)==null?void 0:u.options)==null?void 0:m.weekStartsOn)??0,o=we(e,t==null?void 0:t.in),a=o.getDay(),s=(a<r?7:0)+a-r;return o.setDate(o.getDate()-s),o.setHours(0,0,0,0),o}function Vn(e,t){return bn(e,{...t,weekStartsOn:1})}function Nl(e,t){const n=we(e,t==null?void 0:t.in),r=n.getFullYear(),o=Oe(n,0);o.setFullYear(r+1,0,4),o.setHours(0,0,0,0);const a=Vn(o),s=Oe(n,0);s.setFullYear(r,0,4),s.setHours(0,0,0,0);const i=Vn(s);return n.getTime()>=a.getTime()?r+1:n.getTime()>=i.getTime()?r:r-1}function Xs(e){const t=we(e),n=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return n.setUTCFullYear(t.getFullYear()),+e-+n}function Tn(e,...t){const n=Oe.bind(null,t.find(r=>typeof r=="object"));return t.map(n)}function Kn(e,t){const n=we(e,t==null?void 0:t.in);return n.setHours(0,0,0,0),n}function Dl(e,t,n){const[r,o]=Tn(n==null?void 0:n.in,e,t),a=Kn(r),s=Kn(o),i=+a-Xs(a),l=+s-Xs(s);return Math.round((i-l)/by)}function xy(e,t){const n=Nl(e,t),r=Oe(e,0);return r.setFullYear(n,0,4),r.setHours(0,0,0,0),Vn(r)}function Sy(e,t,n){return El(e,t*7,n)}function Cy(e,t,n){return kl(e,t*12,n)}function My(e,t){let n,r=t==null?void 0:t.in;return e.forEach(o=>{!r&&typeof o=="object"&&(r=Oe.bind(null,o));const a=we(o,r);(!n||n<a||isNaN(+a))&&(n=a)}),Oe(r,n||NaN)}function Ey(e,t){let n,r=t==null?void 0:t.in;return e.forEach(o=>{!r&&typeof o=="object"&&(r=Oe.bind(null,o));const a=we(o,r);(!n||n>a||isNaN(+a))&&(n=a)}),Oe(r,n||NaN)}function ky(e,t,n){const[r,o]=Tn(n==null?void 0:n.in,e,t);return+Kn(r)==+Kn(o)}function Rl(e){return e instanceof Date||typeof e=="object"&&Object.prototype.toString.call(e)==="[object Date]"}function Ny(e){return!(!Rl(e)&&typeof e!="number"||isNaN(+we(e)))}function Dy(e,t,n){const[r,o]=Tn(n==null?void 0:n.in,e,t),a=r.getFullYear()-o.getFullYear(),s=r.getMonth()-o.getMonth();return a*12+s}function Ry(e,t){const n=we(e,t==null?void 0:t.in),r=n.getMonth();return n.setFullYear(n.getFullYear(),r+1,0),n.setHours(23,59,59,999),n}function Ty(e,t){const[n,r]=Tn(e,t.start,t.end);return{start:n,end:r}}function Oy(e,t){const{start:n,end:r}=Ty(t==null?void 0:t.in,e);let o=+n>+r;const a=o?+n:+r,s=o?r:n;s.setHours(0,0,0,0),s.setDate(1);let i=1;const l=[];for(;+s<=a;)l.push(Oe(n,s)),s.setMonth(s.getMonth()+i);return o?l.reverse():l}function _y(e,t){const n=we(e,t==null?void 0:t.in);return n.setDate(1),n.setHours(0,0,0,0),n}function Py(e,t){const n=we(e,t==null?void 0:t.in),r=n.getFullYear();return n.setFullYear(r+1,0,0),n.setHours(23,59,59,999),n}function Tl(e,t){const n=we(e,t==null?void 0:t.in);return n.setFullYear(n.getFullYear(),0,1),n.setHours(0,0,0,0),n}function Ol(e,t){var i,l,u,m;const n=cr(),r=(t==null?void 0:t.weekStartsOn)??((l=(i=t==null?void 0:t.locale)==null?void 0:i.options)==null?void 0:l.weekStartsOn)??n.weekStartsOn??((m=(u=n.locale)==null?void 0:u.options)==null?void 0:m.weekStartsOn)??0,o=we(e,t==null?void 0:t.in),a=o.getDay(),s=(a<r?-7:0)+6-(a-r);return o.setDate(o.getDate()+s),o.setHours(23,59,59,999),o}function Ay(e,t){return Ol(e,{...t,weekStartsOn:1})}const Iy={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},jy=(e,t,n)=>{let r;const o=Iy[e];return typeof o=="string"?r=o:t===1?r=o.one:r=o.other.replace("{{count}}",t.toString()),n!=null&&n.addSuffix?n.comparison&&n.comparison>0?"in "+r:r+" ago":r};function Ao(e){return(t={})=>{const n=t.width?String(t.width):e.defaultWidth;return e.formats[n]||e.formats[e.defaultWidth]}}const $y={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},Ly={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},Fy={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},Wy={date:Ao({formats:$y,defaultWidth:"full"}),time:Ao({formats:Ly,defaultWidth:"full"}),dateTime:Ao({formats:Fy,defaultWidth:"full"})},By={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},Yy=(e,t,n,r)=>By[e];function jn(e){return(t,n)=>{const r=n!=null&&n.context?String(n.context):"standalone";let o;if(r==="formatting"&&e.formattingValues){const s=e.defaultFormattingWidth||e.defaultWidth,i=n!=null&&n.width?String(n.width):s;o=e.formattingValues[i]||e.formattingValues[s]}else{const s=e.defaultWidth,i=n!=null&&n.width?String(n.width):e.defaultWidth;o=e.values[i]||e.values[s]}const a=e.argumentCallback?e.argumentCallback(t):t;return o[a]}}const Hy={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},zy={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},Gy={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},Uy={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},qy={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},Vy={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},Ky=(e,t)=>{const n=Number(e),r=n%100;if(r>20||r<10)switch(r%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"},Xy={ordinalNumber:Ky,era:jn({values:Hy,defaultWidth:"wide"}),quarter:jn({values:zy,defaultWidth:"wide",argumentCallback:e=>e-1}),month:jn({values:Gy,defaultWidth:"wide"}),day:jn({values:Uy,defaultWidth:"wide"}),dayPeriod:jn({values:qy,defaultWidth:"wide",formattingValues:Vy,defaultFormattingWidth:"wide"})};function $n(e){return(t,n={})=>{const r=n.width,o=r&&e.matchPatterns[r]||e.matchPatterns[e.defaultMatchWidth],a=t.match(o);if(!a)return null;const s=a[0],i=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],l=Array.isArray(i)?Qy(i,c=>c.test(s)):Zy(i,c=>c.test(s));let u;u=e.valueCallback?e.valueCallback(l):l,u=n.valueCallback?n.valueCallback(u):u;const m=t.slice(s.length);return{value:u,rest:m}}}function Zy(e,t){for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t(e[n]))return n}function Qy(e,t){for(let n=0;n<e.length;n++)if(t(e[n]))return n}function Jy(e){return(t,n={})=>{const r=t.match(e.matchPattern);if(!r)return null;const o=r[0],a=t.match(e.parsePattern);if(!a)return null;let s=e.valueCallback?e.valueCallback(a[0]):a[0];s=n.valueCallback?n.valueCallback(s):s;const i=t.slice(o.length);return{value:s,rest:i}}}const eb=/^(\d+)(th|st|nd|rd)?/i,tb=/\d+/i,nb={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},rb={any:[/^b/i,/^(a|c)/i]},ob={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},ab={any:[/1/i,/2/i,/3/i,/4/i]},sb={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},ib={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},cb={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},lb={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},ub={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},db={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},fb={ordinalNumber:Jy({matchPattern:eb,parsePattern:tb,valueCallback:e=>parseInt(e,10)}),era:$n({matchPatterns:nb,defaultMatchWidth:"wide",parsePatterns:rb,defaultParseWidth:"any"}),quarter:$n({matchPatterns:ob,defaultMatchWidth:"wide",parsePatterns:ab,defaultParseWidth:"any",valueCallback:e=>e+1}),month:$n({matchPatterns:sb,defaultMatchWidth:"wide",parsePatterns:ib,defaultParseWidth:"any"}),day:$n({matchPatterns:cb,defaultMatchWidth:"wide",parsePatterns:lb,defaultParseWidth:"any"}),dayPeriod:$n({matchPatterns:ub,defaultMatchWidth:"any",parsePatterns:db,defaultParseWidth:"any"})},Fa={code:"en-US",formatDistance:jy,formatLong:Wy,formatRelative:Yy,localize:Xy,match:fb,options:{weekStartsOn:0,firstWeekContainsDate:1}};function mb(e,t){const n=we(e,t==null?void 0:t.in);return Dl(n,Tl(n))+1}function _l(e,t){const n=we(e,t==null?void 0:t.in),r=+Vn(n)-+xy(n);return Math.round(r/Ml)+1}function Pl(e,t){var m,c,p,h;const n=we(e,t==null?void 0:t.in),r=n.getFullYear(),o=cr(),a=(t==null?void 0:t.firstWeekContainsDate)??((c=(m=t==null?void 0:t.locale)==null?void 0:m.options)==null?void 0:c.firstWeekContainsDate)??o.firstWeekContainsDate??((h=(p=o.locale)==null?void 0:p.options)==null?void 0:h.firstWeekContainsDate)??1,s=Oe((t==null?void 0:t.in)||e,0);s.setFullYear(r+1,0,a),s.setHours(0,0,0,0);const i=bn(s,t),l=Oe((t==null?void 0:t.in)||e,0);l.setFullYear(r,0,a),l.setHours(0,0,0,0);const u=bn(l,t);return+n>=+i?r+1:+n>=+u?r:r-1}function pb(e,t){var i,l,u,m;const n=cr(),r=(t==null?void 0:t.firstWeekContainsDate)??((l=(i=t==null?void 0:t.locale)==null?void 0:i.options)==null?void 0:l.firstWeekContainsDate)??n.firstWeekContainsDate??((m=(u=n.locale)==null?void 0:u.options)==null?void 0:m.firstWeekContainsDate)??1,o=Pl(e,t),a=Oe((t==null?void 0:t.in)||e,0);return a.setFullYear(o,0,r),a.setHours(0,0,0,0),bn(a,t)}function Al(e,t){const n=we(e,t==null?void 0:t.in),r=+bn(n,t)-+pb(n,t);return Math.round(r/Ml)+1}function ye(e,t){const n=e<0?"-":"",r=Math.abs(e).toString().padStart(t,"0");return n+r}const Tt={y(e,t){const n=e.getFullYear(),r=n>0?n:1-n;return ye(t==="yy"?r%100:r,t.length)},M(e,t){const n=e.getMonth();return t==="M"?String(n+1):ye(n+1,2)},d(e,t){return ye(e.getDate(),t.length)},a(e,t){const n=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.toUpperCase();case"aaa":return n;case"aaaaa":return n[0];case"aaaa":default:return n==="am"?"a.m.":"p.m."}},h(e,t){return ye(e.getHours()%12||12,t.length)},H(e,t){return ye(e.getHours(),t.length)},m(e,t){return ye(e.getMinutes(),t.length)},s(e,t){return ye(e.getSeconds(),t.length)},S(e,t){const n=t.length,r=e.getMilliseconds(),o=Math.trunc(r*Math.pow(10,n-3));return ye(o,t.length)}},fn={midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},Zs={G:function(e,t,n){const r=e.getFullYear()>0?1:0;switch(t){case"G":case"GG":case"GGG":return n.era(r,{width:"abbreviated"});case"GGGGG":return n.era(r,{width:"narrow"});case"GGGG":default:return n.era(r,{width:"wide"})}},y:function(e,t,n){if(t==="yo"){const r=e.getFullYear(),o=r>0?r:1-r;return n.ordinalNumber(o,{unit:"year"})}return Tt.y(e,t)},Y:function(e,t,n,r){const o=Pl(e,r),a=o>0?o:1-o;if(t==="YY"){const s=a%100;return ye(s,2)}return t==="Yo"?n.ordinalNumber(a,{unit:"year"}):ye(a,t.length)},R:function(e,t){const n=Nl(e);return ye(n,t.length)},u:function(e,t){const n=e.getFullYear();return ye(n,t.length)},Q:function(e,t,n){const r=Math.ceil((e.getMonth()+1)/3);switch(t){case"Q":return String(r);case"QQ":return ye(r,2);case"Qo":return n.ordinalNumber(r,{unit:"quarter"});case"QQQ":return n.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return n.quarter(r,{width:"narrow",context:"formatting"});case"QQQQ":default:return n.quarter(r,{width:"wide",context:"formatting"})}},q:function(e,t,n){const r=Math.ceil((e.getMonth()+1)/3);switch(t){case"q":return String(r);case"qq":return ye(r,2);case"qo":return n.ordinalNumber(r,{unit:"quarter"});case"qqq":return n.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return n.quarter(r,{width:"narrow",context:"standalone"});case"qqqq":default:return n.quarter(r,{width:"wide",context:"standalone"})}},M:function(e,t,n){const r=e.getMonth();switch(t){case"M":case"MM":return Tt.M(e,t);case"Mo":return n.ordinalNumber(r+1,{unit:"month"});case"MMM":return n.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return n.month(r,{width:"narrow",context:"formatting"});case"MMMM":default:return n.month(r,{width:"wide",context:"formatting"})}},L:function(e,t,n){const r=e.getMonth();switch(t){case"L":return String(r+1);case"LL":return ye(r+1,2);case"Lo":return n.ordinalNumber(r+1,{unit:"month"});case"LLL":return n.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return n.month(r,{width:"narrow",context:"standalone"});case"LLLL":default:return n.month(r,{width:"wide",context:"standalone"})}},w:function(e,t,n,r){const o=Al(e,r);return t==="wo"?n.ordinalNumber(o,{unit:"week"}):ye(o,t.length)},I:function(e,t,n){const r=_l(e);return t==="Io"?n.ordinalNumber(r,{unit:"week"}):ye(r,t.length)},d:function(e,t,n){return t==="do"?n.ordinalNumber(e.getDate(),{unit:"date"}):Tt.d(e,t)},D:function(e,t,n){const r=mb(e);return t==="Do"?n.ordinalNumber(r,{unit:"dayOfYear"}):ye(r,t.length)},E:function(e,t,n){const r=e.getDay();switch(t){case"E":case"EE":case"EEE":return n.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return n.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(r,{width:"short",context:"formatting"});case"EEEE":default:return n.day(r,{width:"wide",context:"formatting"})}},e:function(e,t,n,r){const o=e.getDay(),a=(o-r.weekStartsOn+8)%7||7;switch(t){case"e":return String(a);case"ee":return ye(a,2);case"eo":return n.ordinalNumber(a,{unit:"day"});case"eee":return n.day(o,{width:"abbreviated",context:"formatting"});case"eeeee":return n.day(o,{width:"narrow",context:"formatting"});case"eeeeee":return n.day(o,{width:"short",context:"formatting"});case"eeee":default:return n.day(o,{width:"wide",context:"formatting"})}},c:function(e,t,n,r){const o=e.getDay(),a=(o-r.weekStartsOn+8)%7||7;switch(t){case"c":return String(a);case"cc":return ye(a,t.length);case"co":return n.ordinalNumber(a,{unit:"day"});case"ccc":return n.day(o,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(o,{width:"narrow",context:"standalone"});case"cccccc":return n.day(o,{width:"short",context:"standalone"});case"cccc":default:return n.day(o,{width:"wide",context:"standalone"})}},i:function(e,t,n){const r=e.getDay(),o=r===0?7:r;switch(t){case"i":return String(o);case"ii":return ye(o,t.length);case"io":return n.ordinalNumber(o,{unit:"day"});case"iii":return n.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return n.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return n.day(r,{width:"short",context:"formatting"});case"iiii":default:return n.day(r,{width:"wide",context:"formatting"})}},a:function(e,t,n){const o=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"aaa":return n.dayPeriod(o,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return n.dayPeriod(o,{width:"narrow",context:"formatting"});case"aaaa":default:return n.dayPeriod(o,{width:"wide",context:"formatting"})}},b:function(e,t,n){const r=e.getHours();let o;switch(r===12?o=fn.noon:r===0?o=fn.midnight:o=r/12>=1?"pm":"am",t){case"b":case"bb":return n.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"bbb":return n.dayPeriod(o,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return n.dayPeriod(o,{width:"narrow",context:"formatting"});case"bbbb":default:return n.dayPeriod(o,{width:"wide",context:"formatting"})}},B:function(e,t,n){const r=e.getHours();let o;switch(r>=17?o=fn.evening:r>=12?o=fn.afternoon:r>=4?o=fn.morning:o=fn.night,t){case"B":case"BB":case"BBB":return n.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"BBBBB":return n.dayPeriod(o,{width:"narrow",context:"formatting"});case"BBBB":default:return n.dayPeriod(o,{width:"wide",context:"formatting"})}},h:function(e,t,n){if(t==="ho"){let r=e.getHours()%12;return r===0&&(r=12),n.ordinalNumber(r,{unit:"hour"})}return Tt.h(e,t)},H:function(e,t,n){return t==="Ho"?n.ordinalNumber(e.getHours(),{unit:"hour"}):Tt.H(e,t)},K:function(e,t,n){const r=e.getHours()%12;return t==="Ko"?n.ordinalNumber(r,{unit:"hour"}):ye(r,t.length)},k:function(e,t,n){let r=e.getHours();return r===0&&(r=24),t==="ko"?n.ordinalNumber(r,{unit:"hour"}):ye(r,t.length)},m:function(e,t,n){return t==="mo"?n.ordinalNumber(e.getMinutes(),{unit:"minute"}):Tt.m(e,t)},s:function(e,t,n){return t==="so"?n.ordinalNumber(e.getSeconds(),{unit:"second"}):Tt.s(e,t)},S:function(e,t){return Tt.S(e,t)},X:function(e,t,n){const r=e.getTimezoneOffset();if(r===0)return"Z";switch(t){case"X":return Js(r);case"XXXX":case"XX":return Vt(r);case"XXXXX":case"XXX":default:return Vt(r,":")}},x:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"x":return Js(r);case"xxxx":case"xx":return Vt(r);case"xxxxx":case"xxx":default:return Vt(r,":")}},O:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"O":case"OO":case"OOO":return"GMT"+Qs(r,":");case"OOOO":default:return"GMT"+Vt(r,":")}},z:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"z":case"zz":case"zzz":return"GMT"+Qs(r,":");case"zzzz":default:return"GMT"+Vt(r,":")}},t:function(e,t,n){const r=Math.trunc(+e/1e3);return ye(r,t.length)},T:function(e,t,n){return ye(+e,t.length)}};function Qs(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),o=Math.trunc(r/60),a=r%60;return a===0?n+String(o):n+String(o)+t+ye(a,2)}function Js(e,t){return e%60===0?(e>0?"-":"+")+ye(Math.abs(e)/60,2):Vt(e,t)}function Vt(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),o=ye(Math.trunc(r/60),2),a=ye(r%60,2);return n+o+t+a}const ei=(e,t)=>{switch(e){case"P":return t.date({width:"short"});case"PP":return t.date({width:"medium"});case"PPP":return t.date({width:"long"});case"PPPP":default:return t.date({width:"full"})}},Il=(e,t)=>{switch(e){case"p":return t.time({width:"short"});case"pp":return t.time({width:"medium"});case"ppp":return t.time({width:"long"});case"pppp":default:return t.time({width:"full"})}},hb=(e,t)=>{const n=e.match(/(P+)(p+)?/)||[],r=n[1],o=n[2];if(!o)return ei(e,t);let a;switch(r){case"P":a=t.dateTime({width:"short"});break;case"PP":a=t.dateTime({width:"medium"});break;case"PPP":a=t.dateTime({width:"long"});break;case"PPPP":default:a=t.dateTime({width:"full"});break}return a.replace("{{date}}",ei(r,t)).replace("{{time}}",Il(o,t))},gb={p:Il,P:hb},vb=/^D+$/,yb=/^Y+$/,bb=["D","DD","YY","YYYY"];function wb(e){return vb.test(e)}function xb(e){return yb.test(e)}function Sb(e,t,n){const r=Cb(e,t,n);if(console.warn(r),bb.includes(e))throw new RangeError(r)}function Cb(e,t,n){const r=e[0]==="Y"?"years":"days of the month";return`Use \`${e.toLowerCase()}\` instead of \`${e}\` (in \`${t}\`) for formatting ${r} to the input \`${n}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`}const Mb=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,Eb=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,kb=/^'([^]*?)'?$/,Nb=/''/g,Db=/[a-zA-Z]/;function Rb(e,t,n){var m,c,p,h,v,g,y,w;const r=cr(),o=(n==null?void 0:n.locale)??r.locale??Fa,a=(n==null?void 0:n.firstWeekContainsDate)??((c=(m=n==null?void 0:n.locale)==null?void 0:m.options)==null?void 0:c.firstWeekContainsDate)??r.firstWeekContainsDate??((h=(p=r.locale)==null?void 0:p.options)==null?void 0:h.firstWeekContainsDate)??1,s=(n==null?void 0:n.weekStartsOn)??((g=(v=n==null?void 0:n.locale)==null?void 0:v.options)==null?void 0:g.weekStartsOn)??r.weekStartsOn??((w=(y=r.locale)==null?void 0:y.options)==null?void 0:w.weekStartsOn)??0,i=we(e,n==null?void 0:n.in);if(!Ny(i))throw new RangeError("Invalid time value");let l=t.match(Eb).map(x=>{const S=x[0];if(S==="p"||S==="P"){const k=gb[S];return k(x,o.formatLong)}return x}).join("").match(Mb).map(x=>{if(x==="''")return{isToken:!1,value:"'"};const S=x[0];if(S==="'")return{isToken:!1,value:Tb(x)};if(Zs[S])return{isToken:!0,value:x};if(S.match(Db))throw new RangeError("Format string contains an unescaped latin alphabet character `"+S+"`");return{isToken:!1,value:x}});o.localize.preprocessor&&(l=o.localize.preprocessor(i,l));const u={firstWeekContainsDate:a,weekStartsOn:s,locale:o};return l.map(x=>{if(!x.isToken)return x.value;const S=x.value;(!(n!=null&&n.useAdditionalWeekYearTokens)&&xb(S)||!(n!=null&&n.useAdditionalDayOfYearTokens)&&wb(S))&&Sb(S,t,String(e));const k=Zs[S[0]];return k(i,S,o.localize,u)}).join("")}function Tb(e){const t=e.match(kb);return t?t[1].replace(Nb,"'"):e}function Ob(e,t){const n=we(e,t==null?void 0:t.in),r=n.getFullYear(),o=n.getMonth(),a=Oe(n,0);return a.setFullYear(r,o+1,0),a.setHours(0,0,0,0),a.getDate()}function _b(e,t){return we(e,t==null?void 0:t.in).getMonth()}function Pb(e,t){return we(e,t==null?void 0:t.in).getFullYear()}function Ab(e,t){return+we(e)>+we(t)}function Ib(e,t){return+we(e)<+we(t)}function jb(e,t,n){const[r,o]=Tn(n==null?void 0:n.in,e,t);return r.getFullYear()===o.getFullYear()&&r.getMonth()===o.getMonth()}function $b(e,t,n){const[r,o]=Tn(n==null?void 0:n.in,e,t);return r.getFullYear()===o.getFullYear()}function Lb(e,t,n){const r=we(e,n==null?void 0:n.in),o=r.getFullYear(),a=r.getDate(),s=Oe(e,0);s.setFullYear(o,t,15),s.setHours(0,0,0,0);const i=Ob(s);return r.setMonth(t,Math.min(a,i)),r}function Fb(e,t,n){const r=we(e,n==null?void 0:n.in);return isNaN(+r)?Oe(e,NaN):(r.setFullYear(t),r)}const ti=5,Wb=4;function Bb(e,t){const n=t.startOfMonth(e),r=n.getDay()>0?n.getDay():7,o=t.addDays(e,-r+1),a=t.addDays(o,ti*7-1);return t.getMonth(e)===t.getMonth(a)?ti:Wb}function jl(e,t){const n=t.startOfMonth(e),r=n.getDay();return r===1?n:r===0?t.addDays(n,-1*6):t.addDays(n,-1*(r-1))}function Yb(e,t){const n=jl(e,t),r=Bb(e,t);return t.addDays(n,r*7-1)}class kt{constructor(t,n){this.Date=Date,this.today=()=>{var r;return(r=this.overrides)!=null&&r.today?this.overrides.today():this.options.timeZone?Le.tz(this.options.timeZone):new this.Date},this.newDate=(r,o,a)=>{var s;return(s=this.overrides)!=null&&s.newDate?this.overrides.newDate(r,o,a):this.options.timeZone?new Le(r,o,a,this.options.timeZone):new Date(r,o,a)},this.addDays=(r,o)=>{var a;return(a=this.overrides)!=null&&a.addDays?this.overrides.addDays(r,o):El(r,o)},this.addMonths=(r,o)=>{var a;return(a=this.overrides)!=null&&a.addMonths?this.overrides.addMonths(r,o):kl(r,o)},this.addWeeks=(r,o)=>{var a;return(a=this.overrides)!=null&&a.addWeeks?this.overrides.addWeeks(r,o):Sy(r,o)},this.addYears=(r,o)=>{var a;return(a=this.overrides)!=null&&a.addYears?this.overrides.addYears(r,o):Cy(r,o)},this.differenceInCalendarDays=(r,o)=>{var a;return(a=this.overrides)!=null&&a.differenceInCalendarDays?this.overrides.differenceInCalendarDays(r,o):Dl(r,o)},this.differenceInCalendarMonths=(r,o)=>{var a;return(a=this.overrides)!=null&&a.differenceInCalendarMonths?this.overrides.differenceInCalendarMonths(r,o):Dy(r,o)},this.eachMonthOfInterval=r=>{var o;return(o=this.overrides)!=null&&o.eachMonthOfInterval?this.overrides.eachMonthOfInterval(r):Oy(r)},this.endOfBroadcastWeek=r=>{var o;return(o=this.overrides)!=null&&o.endOfBroadcastWeek?this.overrides.endOfBroadcastWeek(r):Yb(r,this)},this.endOfISOWeek=r=>{var o;return(o=this.overrides)!=null&&o.endOfISOWeek?this.overrides.endOfISOWeek(r):Ay(r)},this.endOfMonth=r=>{var o;return(o=this.overrides)!=null&&o.endOfMonth?this.overrides.endOfMonth(r):Ry(r)},this.endOfWeek=(r,o)=>{var a;return(a=this.overrides)!=null&&a.endOfWeek?this.overrides.endOfWeek(r,o):Ol(r,this.options)},this.endOfYear=r=>{var o;return(o=this.overrides)!=null&&o.endOfYear?this.overrides.endOfYear(r):Py(r)},this.format=(r,o,a)=>{var i;const s=(i=this.overrides)!=null&&i.format?this.overrides.format(r,o,this.options):Rb(r,o,this.options);return this.options.numerals&&this.options.numerals!=="latn"?this.replaceDigits(s):s},this.getISOWeek=r=>{var o;return(o=this.overrides)!=null&&o.getISOWeek?this.overrides.getISOWeek(r):_l(r)},this.getMonth=(r,o)=>{var a;return(a=this.overrides)!=null&&a.getMonth?this.overrides.getMonth(r,this.options):_b(r,this.options)},this.getYear=(r,o)=>{var a;return(a=this.overrides)!=null&&a.getYear?this.overrides.getYear(r,this.options):Pb(r,this.options)},this.getWeek=(r,o)=>{var a;return(a=this.overrides)!=null&&a.getWeek?this.overrides.getWeek(r,this.options):Al(r,this.options)},this.isAfter=(r,o)=>{var a;return(a=this.overrides)!=null&&a.isAfter?this.overrides.isAfter(r,o):Ab(r,o)},this.isBefore=(r,o)=>{var a;return(a=this.overrides)!=null&&a.isBefore?this.overrides.isBefore(r,o):Ib(r,o)},this.isDate=r=>{var o;return(o=this.overrides)!=null&&o.isDate?this.overrides.isDate(r):Rl(r)},this.isSameDay=(r,o)=>{var a;return(a=this.overrides)!=null&&a.isSameDay?this.overrides.isSameDay(r,o):ky(r,o)},this.isSameMonth=(r,o)=>{var a;return(a=this.overrides)!=null&&a.isSameMonth?this.overrides.isSameMonth(r,o):jb(r,o)},this.isSameYear=(r,o)=>{var a;return(a=this.overrides)!=null&&a.isSameYear?this.overrides.isSameYear(r,o):$b(r,o)},this.max=r=>{var o;return(o=this.overrides)!=null&&o.max?this.overrides.max(r):My(r)},this.min=r=>{var o;return(o=this.overrides)!=null&&o.min?this.overrides.min(r):Ey(r)},this.setMonth=(r,o)=>{var a;return(a=this.overrides)!=null&&a.setMonth?this.overrides.setMonth(r,o):Lb(r,o)},this.setYear=(r,o)=>{var a;return(a=this.overrides)!=null&&a.setYear?this.overrides.setYear(r,o):Fb(r,o)},this.startOfBroadcastWeek=(r,o)=>{var a;return(a=this.overrides)!=null&&a.startOfBroadcastWeek?this.overrides.startOfBroadcastWeek(r,this):jl(r,this)},this.startOfDay=r=>{var o;return(o=this.overrides)!=null&&o.startOfDay?this.overrides.startOfDay(r):Kn(r)},this.startOfISOWeek=r=>{var o;return(o=this.overrides)!=null&&o.startOfISOWeek?this.overrides.startOfISOWeek(r):Vn(r)},this.startOfMonth=r=>{var o;return(o=this.overrides)!=null&&o.startOfMonth?this.overrides.startOfMonth(r):_y(r)},this.startOfWeek=(r,o)=>{var a;return(a=this.overrides)!=null&&a.startOfWeek?this.overrides.startOfWeek(r,this.options):bn(r,this.options)},this.startOfYear=r=>{var o;return(o=this.overrides)!=null&&o.startOfYear?this.overrides.startOfYear(r):Tl(r)},this.options={locale:Fa,...t},this.overrides=n}getDigitMap(){const{numerals:t="latn"}=this.options,n=new Intl.NumberFormat("en-US",{numberingSystem:t}),r={};for(let o=0;o<10;o++)r[o.toString()]=n.format(o);return r}replaceDigits(t){const n=this.getDigitMap();return t.replace(/\d/g,r=>n[r]||r)}formatNumber(t){return this.replaceDigits(t.toString())}}const yt=new kt;class $l{constructor(t,n,r=yt){this.date=t,this.displayMonth=n,this.outside=!!(n&&!r.isSameMonth(t,n)),this.dateLib=r}isEqualTo(t){return this.dateLib.isSameDay(t.date,this.date)&&this.dateLib.isSameMonth(t.displayMonth,this.displayMonth)}}class Hb{constructor(t,n){this.date=t,this.weeks=n}}class zb{constructor(t,n){this.days=n,this.weekNumber=t}}function xt(e,t,n=!1,r=yt){let{from:o,to:a}=e;const{differenceInCalendarDays:s,isSameDay:i}=r;return o&&a?(s(a,o)<0&&([o,a]=[a,o]),s(t,o)>=(n?1:0)&&s(a,t)>=(n?1:0)):!n&&a?i(a,t):!n&&o?i(o,t):!1}function Ll(e){return!!(e&&typeof e=="object"&&"before"in e&&"after"in e)}function Wa(e){return!!(e&&typeof e=="object"&&"from"in e)}function Fl(e){return!!(e&&typeof e=="object"&&"after"in e)}function Wl(e){return!!(e&&typeof e=="object"&&"before"in e)}function Bl(e){return!!(e&&typeof e=="object"&&"dayOfWeek"in e)}function Yl(e,t){return Array.isArray(e)&&e.every(t.isDate)}function St(e,t,n=yt){const r=Array.isArray(t)?t:[t],{isSameDay:o,differenceInCalendarDays:a,isAfter:s}=n;return r.some(i=>{if(typeof i=="boolean")return i;if(n.isDate(i))return o(e,i);if(Yl(i,n))return i.includes(e);if(Wa(i))return xt(i,e,!1,n);if(Bl(i))return Array.isArray(i.dayOfWeek)?i.dayOfWeek.includes(e.getDay()):i.dayOfWeek===e.getDay();if(Ll(i)){const l=a(i.before,e),u=a(i.after,e),m=l>0,c=u<0;return s(i.before,i.after)?c&&m:m||c}return Fl(i)?a(e,i.after)>0:Wl(i)?a(i.before,e)>0:typeof i=="function"?i(e):!1})}function Gb(e,t,n,r,o){const{disabled:a,hidden:s,modifiers:i,showOutsideDays:l,broadcastCalendar:u,today:m}=t,{isSameDay:c,isSameMonth:p,startOfMonth:h,isBefore:v,endOfMonth:g,isAfter:y}=o,w=n&&h(n),x=r&&g(r),S={[Ee.focused]:[],[Ee.outside]:[],[Ee.disabled]:[],[Ee.hidden]:[],[Ee.today]:[]},k={};for(const C of e){const{date:N,displayMonth:M}=C,D=!!(M&&!p(N,M)),L=!!(w&&v(N,w)),B=!!(x&&y(N,x)),F=!!(a&&St(N,a,o)),V=!!(s&&St(N,s,o))||L||B||!u&&!l&&D||u&&l===!1&&D,$=c(N,m??o.today());D&&S.outside.push(C),F&&S.disabled.push(C),V&&S.hidden.push(C),$&&S.today.push(C),i&&Object.keys(i).forEach(I=>{const _=i==null?void 0:i[I];_&&St(N,_,o)&&(k[I]?k[I].push(C):k[I]=[C])})}return C=>{const N={[Ee.focused]:!1,[Ee.disabled]:!1,[Ee.hidden]:!1,[Ee.outside]:!1,[Ee.today]:!1},M={};for(const D in S){const L=S[D];N[D]=L.some(B=>B===C)}for(const D in k)M[D]=k[D].some(L=>L===C);return{...N,...M}}}function Ub(e,t,n={}){return Object.entries(e).filter(([,o])=>o===!0).reduce((o,[a])=>(n[a]?o.push(n[a]):t[Ee[a]]?o.push(t[Ee[a]]):t[at[a]]&&o.push(t[at[a]]),o),[t[se.Day]])}function qb(e){return b.createElement("button",{...e})}function Vb(e){return b.createElement("span",{...e})}function Kb(e){const{size:t=24,orientation:n="left",className:r}=e;return b.createElement("svg",{className:r,width:t,height:t,viewBox:"0 0 24 24"},n==="up"&&b.createElement("polygon",{points:"6.77 17 12.5 11.43 18.24 17 20 15.28 12.5 8 5 15.28"}),n==="down"&&b.createElement("polygon",{points:"6.77 8 12.5 13.57 18.24 8 20 9.72 12.5 17 5 9.72"}),n==="left"&&b.createElement("polygon",{points:"16 18.112 9.81111111 12 16 5.87733333 14.0888889 4 6 12 14.0888889 20"}),n==="right"&&b.createElement("polygon",{points:"8 18.112 14.18888889 12 8 5.87733333 9.91111111 4 18 12 9.91111111 20"}))}function Xb(e){const{day:t,modifiers:n,...r}=e;return b.createElement("td",{...r})}function Zb(e){const{day:t,modifiers:n,...r}=e,o=b.useRef(null);return b.useEffect(()=>{var a;n.focused&&((a=o.current)==null||a.focus())},[n.focused]),b.createElement("button",{ref:o,...r})}function Qb(e){const{options:t,className:n,components:r,classNames:o,...a}=e,s=[o[se.Dropdown],n].join(" "),i=t==null?void 0:t.find(({value:l})=>l===a.value);return b.createElement("span",{"data-disabled":a.disabled,className:o[se.DropdownRoot]},b.createElement(r.Select,{className:s,...a},t==null?void 0:t.map(({value:l,label:u,disabled:m})=>b.createElement(r.Option,{key:l,value:l,disabled:m},u))),b.createElement("span",{className:o[se.CaptionLabel],"aria-hidden":!0},i==null?void 0:i.label,b.createElement(r.Chevron,{orientation:"down",size:18,className:o[se.Chevron]})))}function Jb(e){return b.createElement("div",{...e})}function ew(e){return b.createElement("div",{...e})}function tw(e){const{calendarMonth:t,displayIndex:n,...r}=e;return b.createElement("div",{...r},e.children)}function nw(e){const{calendarMonth:t,displayIndex:n,...r}=e;return b.createElement("div",{...r})}function rw(e){return b.createElement("table",{...e})}function ow(e){return b.createElement("div",{...e})}const Hl=b.createContext(void 0);function lr(){const e=b.useContext(Hl);if(e===void 0)throw new Error("useDayPicker() must be used within a custom component.");return e}function aw(e){const{components:t}=lr();return b.createElement(t.Dropdown,{...e})}function sw(e){const{onPreviousClick:t,onNextClick:n,previousMonth:r,nextMonth:o,...a}=e,{components:s,classNames:i,labels:{labelPrevious:l,labelNext:u}}=lr(),m=b.useCallback(p=>{o&&(n==null||n(p))},[o,n]),c=b.useCallback(p=>{r&&(t==null||t(p))},[r,t]);return b.createElement("nav",{...a},b.createElement(s.PreviousMonthButton,{type:"button",className:i[se.PreviousMonthButton],tabIndex:r?void 0:-1,"aria-disabled":r?void 0:!0,"aria-label":l(r),onClick:c},b.createElement(s.Chevron,{disabled:r?void 0:!0,className:i[se.Chevron],orientation:"left"})),b.createElement(s.NextMonthButton,{type:"button",className:i[se.NextMonthButton],tabIndex:o?void 0:-1,"aria-disabled":o?void 0:!0,"aria-label":u(o),onClick:m},b.createElement(s.Chevron,{disabled:o?void 0:!0,orientation:"right",className:i[se.Chevron]})))}function iw(e){const{components:t}=lr();return b.createElement(t.Button,{...e})}function cw(e){return b.createElement("option",{...e})}function lw(e){const{components:t}=lr();return b.createElement(t.Button,{...e})}function uw(e){const{rootRef:t,...n}=e;return b.createElement("div",{...n,ref:t})}function dw(e){return b.createElement("select",{...e})}function fw(e){const{week:t,...n}=e;return b.createElement("tr",{...n})}function mw(e){return b.createElement("th",{...e})}function pw(e){return b.createElement("thead",{"aria-hidden":!0},b.createElement("tr",{...e}))}function hw(e){const{week:t,...n}=e;return b.createElement("th",{...n})}function gw(e){return b.createElement("th",{...e})}function vw(e){return b.createElement("tbody",{...e})}function yw(e){const{components:t}=lr();return b.createElement(t.Dropdown,{...e})}const bw=Object.freeze(Object.defineProperty({__proto__:null,Button:qb,CaptionLabel:Vb,Chevron:Kb,Day:Xb,DayButton:Zb,Dropdown:Qb,DropdownNav:Jb,Footer:ew,Month:tw,MonthCaption:nw,MonthGrid:rw,Months:ow,MonthsDropdown:aw,Nav:sw,NextMonthButton:iw,Option:cw,PreviousMonthButton:lw,Root:uw,Select:dw,Week:fw,WeekNumber:hw,WeekNumberHeader:gw,Weekday:mw,Weekdays:pw,Weeks:vw,YearsDropdown:yw},Symbol.toStringTag,{value:"Module"}));function ww(e){return{...bw,...e}}function xw(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,r])=>{n.startsWith("data-")&&(t[n]=r)}),t}function Sw(){const e={};for(const t in se)e[se[t]]=`rdp-${se[t]}`;for(const t in Ee)e[Ee[t]]=`rdp-${Ee[t]}`;for(const t in at)e[at[t]]=`rdp-${at[t]}`;for(const t in Ke)e[Ke[t]]=`rdp-${Ke[t]}`;return e}function zl(e,t,n){return(n??new kt(t)).format(e,"LLLL y")}const Cw=zl;function Mw(e,t,n){return(n??new kt(t)).format(e,"d")}function Ew(e,t=yt){return t.format(e,"LLLL")}function kw(e,t=yt){return e<10?t.formatNumber(`0${e.toLocaleString()}`):t.formatNumber(`${e.toLocaleString()}`)}function Nw(){return""}function Dw(e,t,n){return(n??new kt(t)).format(e,"cccccc")}function Gl(e,t=yt){return t.format(e,"yyyy")}const Rw=Gl,Tw=Object.freeze(Object.defineProperty({__proto__:null,formatCaption:zl,formatDay:Mw,formatMonthCaption:Cw,formatMonthDropdown:Ew,formatWeekNumber:kw,formatWeekNumberHeader:Nw,formatWeekdayName:Dw,formatYearCaption:Rw,formatYearDropdown:Gl},Symbol.toStringTag,{value:"Module"}));function Ow(e){return e!=null&&e.formatMonthCaption&&!e.formatCaption&&(e.formatCaption=e.formatMonthCaption),e!=null&&e.formatYearCaption&&!e.formatYearDropdown&&(e.formatYearDropdown=e.formatYearCaption),{...Tw,...e}}function _w(e,t,n,r,o){const{startOfMonth:a,startOfYear:s,endOfYear:i,eachMonthOfInterval:l,getMonth:u}=o;return l({start:s(e),end:i(e)}).map(p=>{const h=r.formatMonthDropdown(p,o),v=u(p),g=t&&p<a(t)||n&&p>a(n)||!1;return{value:v,label:h,disabled:g}})}function Pw(e,t={},n={}){let r={...t==null?void 0:t[se.Day]};return Object.entries(e).filter(([,o])=>o===!0).forEach(([o])=>{r={...r,...n==null?void 0:n[o]}}),r}function Aw(e,t,n){const r=e.today(),o=t?e.startOfISOWeek(r):e.startOfWeek(r),a=[];for(let s=0;s<7;s++){const i=e.addDays(o,s);a.push(i)}return a}function Iw(e,t,n,r){if(!e||!t)return;const{startOfYear:o,endOfYear:a,addYears:s,getYear:i,isBefore:l,isSameYear:u}=r,m=o(e),c=a(t),p=[];let h=m;for(;l(h,c)||u(h,c);)p.push(h),h=s(h,1);return p.map(v=>{const g=n.formatYearDropdown(v,r);return{value:i(v),label:g,disabled:!1}})}function Ul(e,t,n){return(n??new kt(t)).format(e,"LLLL y")}const jw=Ul;function $w(e,t,n,r){let o=(r??new kt(n)).format(e,"PPPP");return t!=null&&t.today&&(o=`Today, ${o}`),o}function ql(e,t,n,r){let o=(r??new kt(n)).format(e,"PPPP");return t.today&&(o=`Today, ${o}`),t.selected&&(o=`${o}, selected`),o}const Lw=ql;function Fw(){return""}function Ww(e){return"Choose the Month"}function Bw(e){return"Go to the Next Month"}function Yw(e){return"Go to the Previous Month"}function Hw(e,t,n){return(n??new kt(t)).format(e,"cccc")}function zw(e,t){return`Week ${e}`}function Gw(e){return"Week Number"}function Uw(e){return"Choose the Year"}const qw=Object.freeze(Object.defineProperty({__proto__:null,labelCaption:jw,labelDay:Lw,labelDayButton:ql,labelGrid:Ul,labelGridcell:$w,labelMonthDropdown:Ww,labelNav:Fw,labelNext:Bw,labelPrevious:Yw,labelWeekNumber:zw,labelWeekNumberHeader:Gw,labelWeekday:Hw,labelYearDropdown:Uw},Symbol.toStringTag,{value:"Module"})),ur=e=>e instanceof HTMLElement?e:null,Io=e=>[...e.querySelectorAll("[data-animated-month]")??[]],Vw=e=>ur(e.querySelector("[data-animated-month]")),jo=e=>ur(e.querySelector("[data-animated-caption]")),$o=e=>ur(e.querySelector("[data-animated-weeks]")),Kw=e=>ur(e.querySelector("[data-animated-nav]")),Xw=e=>ur(e.querySelector("[data-animated-weekdays]"));function Zw(e,t,{classNames:n,months:r,focused:o,dateLib:a}){const s=b.useRef(null),i=b.useRef(r),l=b.useRef(!1);b.useLayoutEffect(()=>{const u=i.current;if(i.current=r,!t||!e.current||!(e.current instanceof HTMLElement)||r.length===0||u.length===0||r.length!==u.length)return;const m=a.isSameMonth(r[0].date,u[0].date),c=a.isAfter(r[0].date,u[0].date),p=c?n[Ke.caption_after_enter]:n[Ke.caption_before_enter],h=c?n[Ke.weeks_after_enter]:n[Ke.weeks_before_enter],v=s.current,g=e.current.cloneNode(!0);if(g instanceof HTMLElement?(Io(g).forEach(S=>{if(!(S instanceof HTMLElement))return;const k=Vw(S);k&&S.contains(k)&&S.removeChild(k);const C=jo(S);C&&C.classList.remove(p);const N=$o(S);N&&N.classList.remove(h)}),s.current=g):s.current=null,l.current||m||o)return;const y=v instanceof HTMLElement?Io(v):[],w=Io(e.current);if(w&&w.every(x=>x instanceof HTMLElement)&&y&&y.every(x=>x instanceof HTMLElement)){l.current=!0,e.current.style.isolation="isolate";const x=Kw(e.current);x&&(x.style.zIndex="1"),w.forEach((S,k)=>{const C=y[k];if(!C)return;S.style.position="relative",S.style.overflow="hidden";const N=jo(S);N&&N.classList.add(p);const M=$o(S);M&&M.classList.add(h);const D=()=>{l.current=!1,e.current&&(e.current.style.isolation=""),x&&(x.style.zIndex=""),N&&N.classList.remove(p),M&&M.classList.remove(h),S.style.position="",S.style.overflow="",S.contains(C)&&S.removeChild(C)};C.style.pointerEvents="none",C.style.position="absolute",C.style.overflow="hidden",C.setAttribute("aria-hidden","true");const L=Xw(C);L&&(L.style.opacity="0");const B=jo(C);B&&(B.classList.add(c?n[Ke.caption_before_exit]:n[Ke.caption_after_exit]),B.addEventListener("animationend",D));const F=$o(C);F&&F.classList.add(c?n[Ke.weeks_before_exit]:n[Ke.weeks_after_exit]),S.insertBefore(C,S.firstChild)})}})}function Qw(e,t,n,r){const o=e[0],a=e[e.length-1],{ISOWeek:s,fixedWeeks:i,broadcastCalendar:l}=n??{},{addDays:u,differenceInCalendarDays:m,differenceInCalendarMonths:c,endOfBroadcastWeek:p,endOfISOWeek:h,endOfMonth:v,endOfWeek:g,isAfter:y,startOfBroadcastWeek:w,startOfISOWeek:x,startOfWeek:S}=r,k=l?w(o,r):s?x(o):S(o),C=l?p(a):s?h(v(a)):g(v(a)),N=m(C,k),M=c(a,o)+1,D=[];for(let F=0;F<=N;F++){const V=u(k,F);if(t&&y(V,t))break;D.push(V)}const B=(l?35:42)*M;if(i&&D.length<B){const F=B-D.length;for(let V=0;V<F;V++){const $=u(D[D.length-1],1);D.push($)}}return D}function Jw(e){const t=[];return e.reduce((n,r)=>{const o=r.weeks.reduce((a,s)=>[...a,...s.days],t);return[...n,...o]},t)}function ex(e,t,n,r){const{numberOfMonths:o=1}=n,a=[];for(let s=0;s<o;s++){const i=r.addMonths(e,s);if(t&&i>t)break;a.push(i)}return a}function ni(e,t,n,r){const{month:o,defaultMonth:a,today:s=r.today(),numberOfMonths:i=1}=e;let l=o||a||s;const{differenceInCalendarMonths:u,addMonths:m,startOfMonth:c}=r;if(n&&u(n,l)<i-1){const p=-1*(i-1);l=m(n,p)}return t&&u(l,t)<0&&(l=t),c(l)}function tx(e,t,n,r){const{addDays:o,endOfBroadcastWeek:a,endOfISOWeek:s,endOfMonth:i,endOfWeek:l,getISOWeek:u,getWeek:m,startOfBroadcastWeek:c,startOfISOWeek:p,startOfWeek:h}=r,v=e.reduce((g,y)=>{const w=n.broadcastCalendar?c(y,r):n.ISOWeek?p(y):h(y),x=n.broadcastCalendar?a(y):n.ISOWeek?s(i(y)):l(i(y)),S=t.filter(M=>M>=w&&M<=x),k=n.broadcastCalendar?35:42;if(n.fixedWeeks&&S.length<k){const M=t.filter(D=>{const L=k-S.length;return D>x&&D<=o(x,L)});S.push(...M)}const C=S.reduce((M,D)=>{const L=n.ISOWeek?u(D):m(D),B=M.find(V=>V.weekNumber===L),F=new $l(D,y,r);return B?B.days.push(F):M.push(new zb(L,[F])),M},[]),N=new Hb(y,C);return g.push(N),g},[]);return n.reverseMonths?v.reverse():v}function nx(e,t){let{startMonth:n,endMonth:r}=e;const{startOfYear:o,startOfDay:a,startOfMonth:s,endOfMonth:i,addYears:l,endOfYear:u,newDate:m,today:c}=t,{fromYear:p,toYear:h,fromMonth:v,toMonth:g}=e;!n&&v&&(n=v),!n&&p&&(n=t.newDate(p,0,1)),!r&&g&&(r=g),!r&&h&&(r=m(h,11,31));const y=e.captionLayout==="dropdown"||e.captionLayout==="dropdown-years";return n?n=s(n):p?n=m(p,0,1):!n&&y&&(n=o(l(e.today??c(),-100))),r?r=i(r):h?r=m(h,11,31):!r&&y&&(r=u(e.today??c())),[n&&a(n),r&&a(r)]}function rx(e,t,n,r){if(n.disableNavigation)return;const{pagedNavigation:o,numberOfMonths:a=1}=n,{startOfMonth:s,addMonths:i,differenceInCalendarMonths:l}=r,u=o?a:1,m=s(e);if(!t)return i(m,u);if(!(l(t,e)<a))return i(m,u)}function ox(e,t,n,r){if(n.disableNavigation)return;const{pagedNavigation:o,numberOfMonths:a}=n,{startOfMonth:s,addMonths:i,differenceInCalendarMonths:l}=r,u=o?a??1:1,m=s(e);if(!t)return i(m,-u);if(!(l(m,t)<=0))return i(m,-u)}function ax(e){const t=[];return e.reduce((n,r)=>[...n,...r.weeks],t)}function io(e,t){const[n,r]=b.useState(e);return[t===void 0?n:t,r]}function sx(e,t){const[n,r]=nx(e,t),{startOfMonth:o,endOfMonth:a}=t,s=ni(e,n,r,t),[i,l]=io(s,e.month?s:void 0);b.useEffect(()=>{const N=ni(e,n,r,t);l(N)},[e.timeZone]);const u=ex(i,r,e,t),m=Qw(u,e.endMonth?a(e.endMonth):void 0,e,t),c=tx(u,m,e,t),p=ax(c),h=Jw(c),v=ox(i,n,e,t),g=rx(i,r,e,t),{disableNavigation:y,onMonthChange:w}=e,x=N=>p.some(M=>M.days.some(D=>D.isEqualTo(N))),S=N=>{if(y)return;let M=o(N);n&&M<o(n)&&(M=o(n)),r&&M>o(r)&&(M=o(r)),l(M),w==null||w(M)};return{months:c,weeks:p,days:h,navStart:n,navEnd:r,previousMonth:v,nextMonth:g,goToMonth:S,goToDay:N=>{x(N)||S(N.date)}}}var dt;(function(e){e[e.Today=0]="Today",e[e.Selected=1]="Selected",e[e.LastFocused=2]="LastFocused",e[e.FocusedModifier=3]="FocusedModifier"})(dt||(dt={}));function ri(e){return!e[Ee.disabled]&&!e[Ee.hidden]&&!e[Ee.outside]}function ix(e,t,n,r){let o,a=-1;for(const s of e){const i=t(s);ri(i)&&(i[Ee.focused]&&a<dt.FocusedModifier?(o=s,a=dt.FocusedModifier):r!=null&&r.isEqualTo(s)&&a<dt.LastFocused?(o=s,a=dt.LastFocused):n(s.date)&&a<dt.Selected?(o=s,a=dt.Selected):i[Ee.today]&&a<dt.Today&&(o=s,a=dt.Today))}return o||(o=e.find(s=>ri(t(s)))),o}function cx(e,t,n,r,o,a,s){const{ISOWeek:i,broadcastCalendar:l}=a,{addDays:u,addMonths:m,addWeeks:c,addYears:p,endOfBroadcastWeek:h,endOfISOWeek:v,endOfWeek:g,max:y,min:w,startOfBroadcastWeek:x,startOfISOWeek:S,startOfWeek:k}=s;let N={day:u,week:c,month:m,year:p,startOfWeek:M=>l?x(M,s):i?S(M):k(M),endOfWeek:M=>l?h(M):i?v(M):g(M)}[e](n,t==="after"?1:-1);return t==="before"&&r?N=y([r,N]):t==="after"&&o&&(N=w([o,N])),N}function Vl(e,t,n,r,o,a,s,i=0){if(i>365)return;const l=cx(e,t,n.date,r,o,a,s),u=!!(a.disabled&&St(l,a.disabled,s)),m=!!(a.hidden&&St(l,a.hidden,s)),c=l,p=new $l(l,c,s);return!u&&!m?p:Vl(e,t,p,r,o,a,s,i+1)}function lx(e,t,n,r,o){const{autoFocus:a}=e,[s,i]=b.useState(),l=ix(t.days,n,r||(()=>!1),s),[u,m]=b.useState(a?l:void 0);return{isFocusTarget:g=>!!(l!=null&&l.isEqualTo(g)),setFocused:m,focused:u,blur:()=>{i(u),m(void 0)},moveFocus:(g,y)=>{if(!u)return;const w=Vl(g,y,u,t.navStart,t.navEnd,e,o);w&&(t.goToDay(w),m(w))}}}function ux(e,t){const{selected:n,required:r,onSelect:o}=e,[a,s]=io(n,o?n:void 0),i=o?n:a,{isSameDay:l}=t,u=h=>(i==null?void 0:i.some(v=>l(v,h)))??!1,{min:m,max:c}=e;return{selected:i,select:(h,v,g)=>{let y=[...i??[]];if(u(h)){if((i==null?void 0:i.length)===m||r&&(i==null?void 0:i.length)===1)return;y=i==null?void 0:i.filter(w=>!l(w,h))}else(i==null?void 0:i.length)===c?y=[h]:y=[...y,h];return o||s(y),o==null||o(y,h,v,g),y},isSelected:u}}function dx(e,t,n=0,r=0,o=!1,a=yt){const{from:s,to:i}=t||{},{isSameDay:l,isAfter:u,isBefore:m}=a;let c;if(!s&&!i)c={from:e,to:n>0?void 0:e};else if(s&&!i)l(s,e)?o?c={from:s,to:void 0}:c=void 0:m(e,s)?c={from:e,to:s}:c={from:s,to:e};else if(s&&i)if(l(s,e)&&l(i,e))o?c={from:s,to:i}:c=void 0;else if(l(s,e))c={from:s,to:n>0?void 0:e};else if(l(i,e))c={from:e,to:n>0?void 0:e};else if(m(e,s))c={from:e,to:i};else if(u(e,s))c={from:s,to:e};else if(u(e,i))c={from:s,to:e};else throw new Error("Invalid range");if(c!=null&&c.from&&(c!=null&&c.to)){const p=a.differenceInCalendarDays(c.to,c.from);r>0&&p>r?c={from:e,to:void 0}:n>1&&p<n&&(c={from:e,to:void 0})}return c}function fx(e,t,n=yt){const r=Array.isArray(t)?t:[t];let o=e.from;const a=n.differenceInCalendarDays(e.to,e.from),s=Math.min(a,6);for(let i=0;i<=s;i++){if(r.includes(o.getDay()))return!0;o=n.addDays(o,1)}return!1}function oi(e,t,n=yt){return xt(e,t.from,!1,n)||xt(e,t.to,!1,n)||xt(t,e.from,!1,n)||xt(t,e.to,!1,n)}function mx(e,t,n=yt){const r=Array.isArray(t)?t:[t];if(r.filter(i=>typeof i!="function").some(i=>typeof i=="boolean"?i:n.isDate(i)?xt(e,i,!1,n):Yl(i,n)?i.some(l=>xt(e,l,!1,n)):Wa(i)?i.from&&i.to?oi(e,{from:i.from,to:i.to},n):!1:Bl(i)?fx(e,i.dayOfWeek,n):Ll(i)?n.isAfter(i.before,i.after)?oi(e,{from:n.addDays(i.after,1),to:n.addDays(i.before,-1)},n):St(e.from,i,n)||St(e.to,i,n):Fl(i)||Wl(i)?St(e.from,i,n)||St(e.to,i,n):!1))return!0;const s=r.filter(i=>typeof i=="function");if(s.length){let i=e.from;const l=n.differenceInCalendarDays(e.to,e.from);for(let u=0;u<=l;u++){if(s.some(m=>m(i)))return!0;i=n.addDays(i,1)}}return!1}function px(e,t){const{disabled:n,excludeDisabled:r,selected:o,required:a,onSelect:s}=e,[i,l]=io(o,s?o:void 0),u=s?o:i;return{selected:u,select:(p,h,v)=>{const{min:g,max:y}=e,w=p?dx(p,u,g,y,a,t):void 0;return r&&n&&(w!=null&&w.from)&&w.to&&mx({from:w.from,to:w.to},n,t)&&(w.from=p,w.to=void 0),s||l(w),s==null||s(w,p,h,v),w},isSelected:p=>u&&xt(u,p,!1,t)}}function hx(e,t){const{selected:n,required:r,onSelect:o}=e,[a,s]=io(n,o?n:void 0),i=o?n:a,{isSameDay:l}=t;return{selected:i,select:(c,p,h)=>{let v=c;return!r&&i&&i&&l(c,i)&&(v=void 0),o||s(v),o==null||o(v,c,p,h),v},isSelected:c=>i?l(i,c):!1}}function gx(e,t){const n=hx(e,t),r=ux(e,t),o=px(e,t);switch(e.mode){case"single":return n;case"multiple":return r;case"range":return o;default:return}}function vx(e){var Dt;let t=e;t.timeZone&&(t={...e},t.today&&(t.today=new Le(t.today,t.timeZone)),t.month&&(t.month=new Le(t.month,t.timeZone)),t.defaultMonth&&(t.defaultMonth=new Le(t.defaultMonth,t.timeZone)),t.startMonth&&(t.startMonth=new Le(t.startMonth,t.timeZone)),t.endMonth&&(t.endMonth=new Le(t.endMonth,t.timeZone)),t.mode==="single"&&t.selected?t.selected=new Le(t.selected,t.timeZone):t.mode==="multiple"&&t.selected?t.selected=(Dt=t.selected)==null?void 0:Dt.map(z=>new Le(z,t.timeZone)):t.mode==="range"&&t.selected&&(t.selected={from:t.selected.from?new Le(t.selected.from,t.timeZone):void 0,to:t.selected.to?new Le(t.selected.to,t.timeZone):void 0}));const{components:n,formatters:r,labels:o,dateLib:a,locale:s,classNames:i}=b.useMemo(()=>{const z={...Fa,...t.locale};return{dateLib:new kt({locale:z,weekStartsOn:t.broadcastCalendar?1:t.weekStartsOn,firstWeekContainsDate:t.firstWeekContainsDate,useAdditionalWeekYearTokens:t.useAdditionalWeekYearTokens,useAdditionalDayOfYearTokens:t.useAdditionalDayOfYearTokens,timeZone:t.timeZone,numerals:t.numerals},t.dateLib),components:ww(t.components),formatters:Ow(t.formatters),labels:{...qw,...t.labels},locale:z,classNames:{...Sw(),...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]),{captionLayout:l,mode:u,navLayout:m,numberOfMonths:c=1,onDayBlur:p,onDayClick:h,onDayFocus:v,onDayKeyDown:g,onDayMouseEnter:y,onDayMouseLeave:w,onNextClick:x,onPrevClick:S,showWeekNumber:k,styles:C}=t,{formatCaption:N,formatDay:M,formatMonthDropdown:D,formatWeekNumber:L,formatWeekNumberHeader:B,formatWeekdayName:F,formatYearDropdown:V}=r,$=sx(t,a),{days:I,months:_,navStart:R,navEnd:P,previousMonth:E,nextMonth:O,goToMonth:Y}=$,G=Gb(I,t,R,P,a),{isSelected:T,select:A,selected:W}=gx(t,a)??{},{blur:H,focused:U,isFocusTarget:j,moveFocus:Z,setFocused:X}=lx(t,$,G,T??(()=>!1),a),{labelDayButton:Q,labelGridcell:le,labelGrid:de,labelMonthDropdown:xe,labelNav:re,labelPrevious:ze,labelNext:We,labelWeekday:ie,labelWeekNumber:pe,labelWeekNumberHeader:Se,labelYearDropdown:je}=o,Be=b.useMemo(()=>Aw(a,t.ISOWeek),[a,t.ISOWeek]),_e=u!==void 0||h!==void 0,$e=b.useCallback(()=>{E&&(Y(E),S==null||S(E))},[E,Y,S]),Yt=b.useCallback(()=>{O&&(Y(O),x==null||x(O))},[Y,O,x]),rn=b.useCallback((z,ae)=>oe=>{oe.preventDefault(),oe.stopPropagation(),X(z),A==null||A(z.date,ae,oe),h==null||h(z.date,ae,oe)},[A,h,X]),Nt=b.useCallback((z,ae)=>oe=>{X(z),v==null||v(z.date,ae,oe)},[v,X]),_n=b.useCallback((z,ae)=>oe=>{H(),p==null||p(z.date,ae,oe)},[H,p]),bt=b.useCallback((z,ae)=>oe=>{const fe={ArrowLeft:[oe.shiftKey?"month":"day",t.dir==="rtl"?"after":"before"],ArrowRight:[oe.shiftKey?"month":"day",t.dir==="rtl"?"before":"after"],ArrowDown:[oe.shiftKey?"year":"week","after"],ArrowUp:[oe.shiftKey?"year":"week","before"],PageUp:[oe.shiftKey?"year":"month","before"],PageDown:[oe.shiftKey?"year":"month","after"],Home:["startOfWeek","before"],End:["endOfWeek","after"]};if(fe[oe.key]){oe.preventDefault(),oe.stopPropagation();const[ge,ne]=fe[oe.key];Z(ge,ne)}g==null||g(z.date,ae,oe)},[Z,g,t.dir]),Ht=b.useCallback((z,ae)=>oe=>{y==null||y(z.date,ae,oe)},[y]),nt=b.useCallback((z,ae)=>oe=>{w==null||w(z.date,ae,oe)},[w]),on=b.useCallback(z=>ae=>{const oe=Number(ae.target.value),fe=a.setMonth(a.startOfMonth(z),oe);Y(fe)},[a,Y]),Ge=b.useCallback(z=>ae=>{const oe=Number(ae.target.value),fe=a.setYear(a.startOfMonth(z),oe);Y(fe)},[a,Y]),{className:an,style:Pn}=b.useMemo(()=>({className:[i[se.Root],t.className].filter(Boolean).join(" "),style:{...C==null?void 0:C[se.Root],...t.style}}),[i,t.className,t.style,C]),sn=xw(t),zt=b.useRef(null);Zw(zt,!!t.animate,{classNames:i,months:_,focused:U,dateLib:a});const An={dayPickerProps:t,selected:W,select:A,isSelected:T,months:_,nextMonth:O,previousMonth:E,goToMonth:Y,getModifiers:G,components:n,classNames:i,styles:C,labels:o,formatters:r};return b.createElement(Hl.Provider,{value:An},b.createElement(n.Root,{rootRef:t.animate?zt:void 0,className:an,style:Pn,dir:t.dir,id:t.id,lang:t.lang,nonce:t.nonce,title:t.title,role:t.role,"aria-label":t["aria-label"],...sn},b.createElement(n.Months,{className:i[se.Months],style:C==null?void 0:C[se.Months]},!t.hideNavigation&&!m&&b.createElement(n.Nav,{"data-animated-nav":t.animate?"true":void 0,className:i[se.Nav],style:C==null?void 0:C[se.Nav],"aria-label":re(),onPreviousClick:$e,onNextClick:Yt,previousMonth:E,nextMonth:O}),_.map((z,ae)=>{const oe=_w(z.date,R,P,r,a),fe=Iw(R,P,r,a);return b.createElement(n.Month,{"data-animated-month":t.animate?"true":void 0,className:i[se.Month],style:C==null?void 0:C[se.Month],key:ae,displayIndex:ae,calendarMonth:z},m==="around"&&!t.hideNavigation&&ae===0&&b.createElement(n.PreviousMonthButton,{type:"button",className:i[se.PreviousMonthButton],tabIndex:E?void 0:-1,"aria-disabled":E?void 0:!0,"aria-label":ze(E),onClick:$e,"data-animated-button":t.animate?"true":void 0},b.createElement(n.Chevron,{disabled:E?void 0:!0,className:i[se.Chevron],orientation:t.dir==="rtl"?"right":"left"})),b.createElement(n.MonthCaption,{"data-animated-caption":t.animate?"true":void 0,className:i[se.MonthCaption],style:C==null?void 0:C[se.MonthCaption],calendarMonth:z,displayIndex:ae},l!=null&&l.startsWith("dropdown")?b.createElement(n.DropdownNav,{className:i[se.Dropdowns],style:C==null?void 0:C[se.Dropdowns]},l==="dropdown"||l==="dropdown-months"?b.createElement(n.MonthsDropdown,{className:i[se.MonthsDropdown],"aria-label":xe(),classNames:i,components:n,disabled:!!t.disableNavigation,onChange:on(z.date),options:oe,style:C==null?void 0:C[se.Dropdown],value:a.getMonth(z.date)}):b.createElement("span",null,D(z.date,a)),l==="dropdown"||l==="dropdown-years"?b.createElement(n.YearsDropdown,{className:i[se.YearsDropdown],"aria-label":je(a.options),classNames:i,components:n,disabled:!!t.disableNavigation,onChange:Ge(z.date),options:fe,style:C==null?void 0:C[se.Dropdown],value:a.getYear(z.date)}):b.createElement("span",null,V(z.date,a)),b.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"}},N(z.date,a.options,a))):b.createElement(n.CaptionLabel,{className:i[se.CaptionLabel],role:"status","aria-live":"polite"},N(z.date,a.options,a))),m==="around"&&!t.hideNavigation&&ae===c-1&&b.createElement(n.NextMonthButton,{type:"button",className:i[se.NextMonthButton],tabIndex:O?void 0:-1,"aria-disabled":O?void 0:!0,"aria-label":We(O),onClick:Yt,"data-animated-button":t.animate?"true":void 0},b.createElement(n.Chevron,{disabled:O?void 0:!0,className:i[se.Chevron],orientation:t.dir==="rtl"?"left":"right"})),ae===c-1&&m==="after"&&!t.hideNavigation&&b.createElement(n.Nav,{"data-animated-nav":t.animate?"true":void 0,className:i[se.Nav],style:C==null?void 0:C[se.Nav],"aria-label":re(),onPreviousClick:$e,onNextClick:Yt,previousMonth:E,nextMonth:O}),b.createElement(n.MonthGrid,{role:"grid","aria-multiselectable":u==="multiple"||u==="range","aria-label":de(z.date,a.options,a)||void 0,className:i[se.MonthGrid],style:C==null?void 0:C[se.MonthGrid]},!t.hideWeekdays&&b.createElement(n.Weekdays,{"data-animated-weekdays":t.animate?"true":void 0,className:i[se.Weekdays],style:C==null?void 0:C[se.Weekdays]},k&&b.createElement(n.WeekNumberHeader,{"aria-label":Se(a.options),className:i[se.WeekNumberHeader],style:C==null?void 0:C[se.WeekNumberHeader],scope:"col"},B()),Be.map((ge,ne)=>b.createElement(n.Weekday,{"aria-label":ie(ge,a.options,a),className:i[se.Weekday],key:ne,style:C==null?void 0:C[se.Weekday],scope:"col"},F(ge,a.options,a)))),b.createElement(n.Weeks,{"data-animated-weeks":t.animate?"true":void 0,className:i[se.Weeks],style:C==null?void 0:C[se.Weeks]},z.weeks.map((ge,ne)=>b.createElement(n.Week,{className:i[se.Week],key:ge.weekNumber,style:C==null?void 0:C[se.Week],week:ge},k&&b.createElement(n.WeekNumber,{week:ge,style:C==null?void 0:C[se.WeekNumber],"aria-label":pe(ge.weekNumber,{locale:s}),className:i[se.WeekNumber],scope:"row",role:"rowheader"},L(ge.weekNumber,a)),ge.days.map(ue=>{const{date:ve}=ue,ce=G(ue);if(ce[Ee.focused]=!ce.hidden&&!!(U!=null&&U.isEqualTo(ue)),ce[at.selected]=(T==null?void 0:T(ve))||ce.selected,Wa(W)){const{from:Ve,to:Pe}=W;ce[at.range_start]=!!(Ve&&Pe&&a.isSameDay(ve,Ve)),ce[at.range_end]=!!(Ve&&Pe&&a.isSameDay(ve,Pe)),ce[at.range_middle]=xt(W,ve,!0,a)}const Ue=Pw(ce,C,t.modifiersStyles),be=Ub(ce,i,t.modifiersClassNames),Ce=!_e&&!ce.hidden?le(ve,ce,a.options,a):void 0;return b.createElement(n.Day,{key:`${a.format(ve,"yyyy-MM-dd")}_${a.format(ue.displayMonth,"yyyy-MM")}`,day:ue,modifiers:ce,className:be.join(" "),style:Ue,role:"gridcell","aria-selected":ce.selected||void 0,"aria-label":Ce,"data-day":a.format(ve,"yyyy-MM-dd"),"data-month":ue.outside?a.format(ve,"yyyy-MM"):void 0,"data-selected":ce.selected||void 0,"data-disabled":ce.disabled||void 0,"data-hidden":ce.hidden||void 0,"data-outside":ue.outside||void 0,"data-focused":ce.focused||void 0,"data-today":ce.today||void 0},!ce.hidden&&_e?b.createElement(n.DayButton,{className:i[se.DayButton],style:C==null?void 0:C[se.DayButton],type:"button",day:ue,modifiers:ce,disabled:ce.disabled||void 0,tabIndex:j(ue)?0:-1,"aria-label":Q(ve,ce,a.options,a),onClick:rn(ue,ce),onBlur:_n(ue,ce),onFocus:Nt(ue,ce),onKeyDown:bt(ue,ce),onMouseEnter:Ht(ue,ce),onMouseLeave:nt(ue,ce)},M(ve,a.options,a)):!ce.hidden&&M(ue.date,a.options,a))}))))))})),t.footer&&b.createElement(n.Footer,{className:i[se.Footer],style:C==null?void 0:C[se.Footer],role:"status","aria-live":"polite"},t.footer)))}function Kl(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var _r={exports:{}},yx=_r.exports,ai;function Xl(){return ai||(ai=1,function(e,t){(function(n,r){e.exports=r()})(yx,function(){var n=1e3,r=6e4,o=36e5,a="millisecond",s="second",i="minute",l="hour",u="day",m="week",c="month",p="quarter",h="year",v="date",g="Invalid Date",y=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,w=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,x={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(I){var _=["th","st","nd","rd"],R=I%100;return"["+I+(_[(R-20)%10]||_[R]||_[0])+"]"}},S=function(I,_,R){var P=String(I);return!P||P.length>=_?I:""+Array(_+1-P.length).join(R)+I},k={s:S,z:function(I){var _=-I.utcOffset(),R=Math.abs(_),P=Math.floor(R/60),E=R%60;return(_<=0?"+":"-")+S(P,2,"0")+":"+S(E,2,"0")},m:function I(_,R){if(_.date()<R.date())return-I(R,_);var P=12*(R.year()-_.year())+(R.month()-_.month()),E=_.clone().add(P,c),O=R-E<0,Y=_.clone().add(P+(O?-1:1),c);return+(-(P+(R-E)/(O?E-Y:Y-E))||0)},a:function(I){return I<0?Math.ceil(I)||0:Math.floor(I)},p:function(I){return{M:c,y:h,w:m,d:u,D:v,h:l,m:i,s,ms:a,Q:p}[I]||String(I||"").toLowerCase().replace(/s$/,"")},u:function(I){return I===void 0}},C="en",N={};N[C]=x;var M="$isDayjsObject",D=function(I){return I instanceof V||!(!I||!I[M])},L=function I(_,R,P){var E;if(!_)return C;if(typeof _=="string"){var O=_.toLowerCase();N[O]&&(E=O),R&&(N[O]=R,E=O);var Y=_.split("-");if(!E&&Y.length>1)return I(Y[0])}else{var G=_.name;N[G]=_,E=G}return!P&&E&&(C=E),E||!P&&C},B=function(I,_){if(D(I))return I.clone();var R=typeof _=="object"?_:{};return R.date=I,R.args=arguments,new V(R)},F=k;F.l=L,F.i=D,F.w=function(I,_){return B(I,{locale:_.$L,utc:_.$u,x:_.$x,$offset:_.$offset})};var V=function(){function I(R){this.$L=L(R.locale,null,!0),this.parse(R),this.$x=this.$x||R.x||{},this[M]=!0}var _=I.prototype;return _.parse=function(R){this.$d=function(P){var E=P.date,O=P.utc;if(E===null)return new Date(NaN);if(F.u(E))return new Date;if(E instanceof Date)return new Date(E);if(typeof E=="string"&&!/Z$/i.test(E)){var Y=E.match(y);if(Y){var G=Y[2]-1||0,T=(Y[7]||"0").substring(0,3);return O?new Date(Date.UTC(Y[1],G,Y[3]||1,Y[4]||0,Y[5]||0,Y[6]||0,T)):new Date(Y[1],G,Y[3]||1,Y[4]||0,Y[5]||0,Y[6]||0,T)}}return new Date(E)}(R),this.init()},_.init=function(){var R=this.$d;this.$y=R.getFullYear(),this.$M=R.getMonth(),this.$D=R.getDate(),this.$W=R.getDay(),this.$H=R.getHours(),this.$m=R.getMinutes(),this.$s=R.getSeconds(),this.$ms=R.getMilliseconds()},_.$utils=function(){return F},_.isValid=function(){return this.$d.toString()!==g},_.isSame=function(R,P){var E=B(R);return this.startOf(P)<=E&&E<=this.endOf(P)},_.isAfter=function(R,P){return B(R)<this.startOf(P)},_.isBefore=function(R,P){return this.endOf(P)<B(R)},_.$g=function(R,P,E){return F.u(R)?this[P]:this.set(E,R)},_.unix=function(){return Math.floor(this.valueOf()/1e3)},_.valueOf=function(){return this.$d.getTime()},_.startOf=function(R,P){var E=this,O=!!F.u(P)||P,Y=F.p(R),G=function(X,Q){var le=F.w(E.$u?Date.UTC(E.$y,Q,X):new Date(E.$y,Q,X),E);return O?le:le.endOf(u)},T=function(X,Q){return F.w(E.toDate()[X].apply(E.toDate("s"),(O?[0,0,0,0]:[23,59,59,999]).slice(Q)),E)},A=this.$W,W=this.$M,H=this.$D,U="set"+(this.$u?"UTC":"");switch(Y){case h:return O?G(1,0):G(31,11);case c:return O?G(1,W):G(0,W+1);case m:var j=this.$locale().weekStart||0,Z=(A<j?A+7:A)-j;return G(O?H-Z:H+(6-Z),W);case u:case v:return T(U+"Hours",0);case l:return T(U+"Minutes",1);case i:return T(U+"Seconds",2);case s:return T(U+"Milliseconds",3);default:return this.clone()}},_.endOf=function(R){return this.startOf(R,!1)},_.$set=function(R,P){var E,O=F.p(R),Y="set"+(this.$u?"UTC":""),G=(E={},E[u]=Y+"Date",E[v]=Y+"Date",E[c]=Y+"Month",E[h]=Y+"FullYear",E[l]=Y+"Hours",E[i]=Y+"Minutes",E[s]=Y+"Seconds",E[a]=Y+"Milliseconds",E)[O],T=O===u?this.$D+(P-this.$W):P;if(O===c||O===h){var A=this.clone().set(v,1);A.$d[G](T),A.init(),this.$d=A.set(v,Math.min(this.$D,A.daysInMonth())).$d}else G&&this.$d[G](T);return this.init(),this},_.set=function(R,P){return this.clone().$set(R,P)},_.get=function(R){return this[F.p(R)]()},_.add=function(R,P){var E,O=this;R=Number(R);var Y=F.p(P),G=function(W){var H=B(O);return F.w(H.date(H.date()+Math.round(W*R)),O)};if(Y===c)return this.set(c,this.$M+R);if(Y===h)return this.set(h,this.$y+R);if(Y===u)return G(1);if(Y===m)return G(7);var T=(E={},E[i]=r,E[l]=o,E[s]=n,E)[Y]||1,A=this.$d.getTime()+R*T;return F.w(A,this)},_.subtract=function(R,P){return this.add(-1*R,P)},_.format=function(R){var P=this,E=this.$locale();if(!this.isValid())return E.invalidDate||g;var O=R||"YYYY-MM-DDTHH:mm:ssZ",Y=F.z(this),G=this.$H,T=this.$m,A=this.$M,W=E.weekdays,H=E.months,U=E.meridiem,j=function(Q,le,de,xe){return Q&&(Q[le]||Q(P,O))||de[le].slice(0,xe)},Z=function(Q){return F.s(G%12||12,Q,"0")},X=U||function(Q,le,de){var xe=Q<12?"AM":"PM";return de?xe.toLowerCase():xe};return O.replace(w,function(Q,le){return le||function(de){switch(de){case"YY":return String(P.$y).slice(-2);case"YYYY":return F.s(P.$y,4,"0");case"M":return A+1;case"MM":return F.s(A+1,2,"0");case"MMM":return j(E.monthsShort,A,H,3);case"MMMM":return j(H,A);case"D":return P.$D;case"DD":return F.s(P.$D,2,"0");case"d":return String(P.$W);case"dd":return j(E.weekdaysMin,P.$W,W,2);case"ddd":return j(E.weekdaysShort,P.$W,W,3);case"dddd":return W[P.$W];case"H":return String(G);case"HH":return F.s(G,2,"0");case"h":return Z(1);case"hh":return Z(2);case"a":return X(G,T,!0);case"A":return X(G,T,!1);case"m":return String(T);case"mm":return F.s(T,2,"0");case"s":return String(P.$s);case"ss":return F.s(P.$s,2,"0");case"SSS":return F.s(P.$ms,3,"0");case"Z":return Y}return null}(Q)||Y.replace(":","")})},_.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},_.diff=function(R,P,E){var O,Y=this,G=F.p(P),T=B(R),A=(T.utcOffset()-this.utcOffset())*r,W=this-T,H=function(){return F.m(Y,T)};switch(G){case h:O=H()/12;break;case c:O=H();break;case p:O=H()/3;break;case m:O=(W-A)/6048e5;break;case u:O=(W-A)/864e5;break;case l:O=W/o;break;case i:O=W/r;break;case s:O=W/n;break;default:O=W}return E?O:F.a(O)},_.daysInMonth=function(){return this.endOf(c).$D},_.$locale=function(){return N[this.$L]},_.locale=function(R,P){if(!R)return this.$L;var E=this.clone(),O=L(R,P,!0);return O&&(E.$L=O),E},_.clone=function(){return F.w(this.$d,this)},_.toDate=function(){return new Date(this.valueOf())},_.toJSON=function(){return this.isValid()?this.toISOString():null},_.toISOString=function(){return this.$d.toISOString()},_.toString=function(){return this.$d.toUTCString()},I}(),$=V.prototype;return B.prototype=$,[["$ms",a],["$s",s],["$m",i],["$H",l],["$W",u],["$M",c],["$y",h],["$D",v]].forEach(function(I){$[I[1]]=function(_){return this.$g(_,I[0],I[1])}}),B.extend=function(I,_){return I.$i||(I(_,V,B),I.$i=!0),B},B.locale=L,B.isDayjs=D,B.unix=function(I){return B(1e3*I)},B.en=N[C],B.Ls=N,B.p={},B})}(_r)),_r.exports}var bx=Xl();const da=Kl(bx);var Pr={exports:{}},wx=Pr.exports,si;function xx(){return si||(si=1,function(e,t){(function(n,r){e.exports=r()})(wx,function(){var n={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"};return function(r,o,a){var s=o.prototype,i=s.format;a.en.formats=n,s.format=function(l){l===void 0&&(l="YYYY-MM-DDTHH:mm:ssZ");var u=this.$locale().formats,m=function(c,p){return c.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(h,v,g){var y=g&&g.toUpperCase();return v||p[g]||n[g]||p[y].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(w,x,S){return x||S.slice(1)})})}(l,u===void 0?{}:u);return i.call(this,m)}}})}(Pr)),Pr.exports}var Sx=xx();const Cx=Kl(Sx);var Ar={exports:{}},Mx=Ar.exports,ii;function Ex(){return ii||(ii=1,function(e,t){(function(n,r){e.exports=r(Xl())})(Mx,function(n){function r(s){return s&&typeof s=="object"&&"default"in s?s:{default:s}}var o=r(n),a={name:"fr",weekdays:"dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi".split("_"),weekdaysShort:"dim._lun._mar._mer._jeu._ven._sam.".split("_"),weekdaysMin:"di_lu_ma_me_je_ve_sa".split("_"),months:"janvier_février_mars_avril_mai_juin_juillet_août_septembre_octobre_novembre_décembre".split("_"),monthsShort:"janv._févr._mars_avr._mai_juin_juil._août_sept._oct._nov._déc.".split("_"),weekStart:1,yearStart:4,formats:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},relativeTime:{future:"dans %s",past:"il y a %s",s:"quelques secondes",m:"une minute",mm:"%d minutes",h:"une heure",hh:"%d heures",d:"un jour",dd:"%d jours",M:"un mois",MM:"%d mois",y:"un an",yy:"%d ans"},ordinal:function(s){return""+s+(s===1?"er":"")}};return o.default.locale(a,null,!0),a})}(Ar)),Ar.exports}Ex();function kx({month:e,onMonthChange:t}){const n=e.getFullYear(),r=e.getMonth(),o=["January","February","March","April","May","June","July","August","September","October","November","December"],a=new Date().getFullYear(),s=Array.from({length:201},(c,p)=>a-100+p),i=c=>{const p=new Date(e);p.setMonth(Number.parseInt(c)),t(p)},l=c=>{const p=new Date(e);p.setFullYear(Number.parseInt(c)),t(p)},u=()=>{const c=new Date(e);c.setMonth(c.getMonth()-1),t(c)},m=()=>{const c=new Date(e);c.setMonth(c.getMonth()+1),t(c)};return f.jsxs("div",{className:"flex items-center justify-between p-2 border-b bg-gray-50",children:[f.jsx(Kt,{variant:"outline",size:"small",onClick:u,className:"h-7 w-7 p-0",children:f.jsx(Rp,{className:"h-4 w-4"})}),f.jsxs("div",{className:"flex items-center gap-2",children:[f.jsxs(ca,{value:r.toString(),onValueChange:i,children:[f.jsx(Wr,{className:"w-32 h-8 text-sm",children:f.jsx(la,{})}),f.jsx(Br,{children:o.map((c,p)=>f.jsx(Yr,{value:p.toString(),children:c},c))})]}),f.jsxs(ca,{value:n.toString(),onValueChange:l,children:[f.jsx(Wr,{className:"w-20 h-8 text-sm",children:f.jsx(la,{})}),f.jsx(Br,{className:"max-h-[200px]",children:s.map(c=>f.jsx(Yr,{value:c.toString(),children:c},c))})]})]}),f.jsx(Kt,{variant:"outline",size:"small",onClick:m,className:"h-7 w-7 p-0",children:f.jsx(Bi,{className:"h-4 w-4"})})]})}da.extend(Cx);function Hr({label:e,placeholder:t="Pick a date",helperText:n,error:r,required:o,value:a,onSelect:s,className:i,minDate:l,maxDate:u,disabled:m,readOnly:c,locale:p="en",showOutsideDays:h,dayPickerProps:v,month:g,onMonthChange:y,open:w,onOpenChange:x,...S}){const[k,C]=b.useState(!1),N=w!==void 0?w:k,M=x||C,D=g??a??new Date,L=B=>{B&&(!a||B.getTime()!==a.getTime())&&(s==null||s(B),M(!1))};return da.locale(p),f.jsxs("div",{className:q("space-y-1",i),...S,children:[e&&f.jsxs(tn,{className:"text-sm font-medium text-gray-700",children:[e,o&&f.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),f.jsxs(jc,{open:N,onOpenChange:M,children:[f.jsx($c,{asChild:!0,children:f.jsxs(Kt,{variant:"outline",className:q("w-full flex justify-between items-center font-normal",!a&&"text-muted-foreground",r&&"border-red-500 focus:ring-red-500"),disabled:m,"aria-readonly":c,onClick:()=>M(!N),children:[f.jsx("span",{className:q("text-left",!a&&"text-gray-400"),children:a?da(a).locale(p).format("LL"):t}),f.jsx(Ep,{strokeWidth:1.2,className:"ml-6 h-6 w-6 shrink-0 text-foreground"})]})}),f.jsx(Ia,{className:"w-auto p-0",align:"start",children:f.jsxs("div",{className:"bg-white rounded-md border shadow-md",children:[f.jsx(kx,{month:D,onMonthChange:y??(()=>{})}),f.jsx("div",{className:"p-3",children:f.jsx(vx,{mode:"single",selected:a,onSelect:L,month:D,onMonthChange:y,fromDate:l,toDate:u,showOutsideDays:h,className:"p-0",classNames:{months:"flex flex-col sm:flex-row space-y-4 sm:space-x-4 sm:space-y-0",month:"space-y-4",caption:"hidden",caption_label:"text-sm font-medium",nav:"hidden",nav_button:"h-7 w-7 bg-transparent p-0 opacity-50 hover:opacity-100",nav_button_previous:"absolute left-1 top-1",nav_button_next:"absolute right-1 top-1",table:"w-full border-collapse space-y-1",head_row:"flex",head_cell:"text-muted-foreground rounded-md w-9 font-normal text-[0.8rem]",row:"flex w-full mt-2",cell:"h-9 w-9 text-center text-sm p-0 relative [&:has([aria-selected].day-range-end)]:rounded-r-md [&:has([aria-selected].day-outside)]:bg-accent/50 [&:has([aria-selected])]:bg-accent first:[&:has([aria-selected])]:rounded-l-md last:[&:has([aria-selected])]:rounded-r-md focus-within:relative focus-within:z-20",day:"h-9 w-9 p-0 font-normal aria-selected:opacity-100 hover:bg-accent hover:text-accent-foreground rounded-md transition-colors",day_range_end:"day-range-end",day_selected:"bg-primary text-primary-foreground hover:bg-primary hover:text-primary-foreground focus:bg-primary focus:text-primary-foreground",day_today:"bg-accent text-accent-foreground",day_outside:"day-outside text-muted-foreground opacity-50 aria-selected:bg-accent/50 aria-selected:text-muted-foreground aria-selected:opacity-30",day_disabled:"text-muted-foreground opacity-50",day_range_middle:"aria-selected:bg-accent aria-selected:text-accent-foreground",day_hidden:"invisible"},...v})})]})})]}),(n||r)&&f.jsx("p",{className:q("text-xs",r?"text-red-500":"text-gray-500"),children:r||n})]})}function wn({label:e,placeholder:t="Select option",options:n,leadingIcon:r,helperText:o,error:a,required:s,onValueChange:i,className:l,variant:u="default",disabled:m=!1}){return f.jsxs("div",{className:q("space-y-1",l),children:[e&&f.jsxs(tn,{className:q("text-sm font-medium",m?"text-gray-400":"text-gray-700"),children:[e,s&&f.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),f.jsxs(ca,{onValueChange:i,disabled:m,children:[f.jsx(Wr,{className:q(a&&"border-red-500 focus:ring-red-500",u==="gray"&&"bg-gray-100 border-gray-300 text-gray-700",m&&"opacity-50 cursor-not-allowed"),children:f.jsxs("div",{className:"flex items-center gap-2 w-full",children:[r&&f.jsx("div",{className:"text-gray-400",children:r}),f.jsx(la,{placeholder:t})]})}),f.jsx(Br,{children:n.map(c=>f.jsx(Yr,{value:c.value,children:c.label},c.value))})]}),(o||a)&&f.jsx("p",{className:q("text-xs",a?"text-red-500":m?"text-gray-400":"text-gray-500"),children:a||o})]})}const Nx=({label:e,variant:t="filled",color:n="default",size:r="medium",deletable:o=!1,onDelete:a,onClick:s,icon:i,avatar:l,disabled:u=!1,className:m="",...c})=>{const p="inline-flex items-center gap-1 font-medium transition-all duration-200 focus:outline-none focus:ring-2 focus:ring-offset-2",h={small:"px-2 py-0.5 text-xs rounded-full",medium:"px-3 py-1 text-sm rounded-full",large:"px-4 py-1.5 text-base rounded-lg"},v={default:{filled:"bg-gray-200 text-gray-800 hover:bg-gray-300",outlined:"border border-gray-300 text-gray-700 hover:bg-gray-50"},primary:{filled:"bg-blue-500 text-white hover:bg-blue-600",outlined:"border border-blue-500 text-blue-600 hover:bg-blue-50"},secondary:{filled:"bg-purple-500 text-white hover:bg-purple-600",outlined:"border border-purple-500 text-purple-600 hover:bg-purple-50"},success:{filled:"bg-green-500 text-white hover:bg-green-600",outlined:"border border-green-500 text-green-600 hover:bg-green-50"},warning:{filled:"bg-yellow-500 text-white hover:bg-yellow-600",outlined:"border border-yellow-500 text-yellow-600 hover:bg-yellow-50"},error:{filled:"bg-red-500 text-white hover:bg-red-600",outlined:"border border-red-500 text-red-600 hover:bg-red-50"}},g=u?"opacity-50 cursor-not-allowed":"cursor-pointer",y=s&&!u?"hover:shadow-md":"",w=`
145
147
  ${p}
146
- ${v}
147
- ${f}
148
- `.trim(),y=w=>{!l&&i&&i(w)},x=w=>{w.stopPropagation(),!l&&s&&s(w)},O=r==="small"?12:r==="large"?18:14;return m.jsxs("div",{className:S,onClick:y,...u,children:[c&&m.jsx("div",{className:`rounded-full overflow-hidden ${r==="small"?"w-4 h-4":r==="large"?"w-6 h-6":"w-5 h-5"}`,children:typeof c=="string"?m.jsx("img",{src:c,alt:"",className:"w-full h-full object-cover"}):c}),a&&!c&&m.jsx("div",{className:"flex items-center",children:N.isValidElement(a)?N.cloneElement(a,{size:O}):a}),m.jsx("span",{children:e}),o&&m.jsx("button",{onClick:x,className:`ml-1 rounded-full p-0.5 hover:bg-black hover:bg-opacity-10 transition-colors ${l?"cursor-not-allowed":"cursor-pointer"}`,disabled:l,children:m.jsx(Br,{size:O})})]})},qg={small:"h-8 text-sm",medium:"h-10",large:"h-12 text-base"},Ug={white:"bg-white border-gray-300",grey:"bg-gray-100 border-gray-300"};function Wi({size:e="medium",variant:t="white",placeholder:n="Search here",className:r,onChange:o,query:s=""}){return m.jsx(m.Fragment,{children:m.jsxs("div",{className:"relative",children:[m.jsx(Es,{strokeWidth:1.5,className:"absolute left-3 top-1/2 transform -translate-y-1/2 text-gray-900 h-4 w-4"}),m.jsx(Zt,{placeholder:n,className:U("pl-10 rounded-full",qg[e],Ug[t],r),onChange:o,value:s})]})})}const Gg=[{value:"all",label:"All Categories"},{value:"electronics",label:"Electronics"},{value:"clothing",label:"Clothing"},{value:"books",label:"Books"}],Kg=[{value:"newest",label:"Newest First"},{value:"oldest",label:"Oldest First"},{value:"name-asc",label:"Name A-Z"},{value:"name-desc",label:"Name Z-A"}];function Vg({className:e,searchPlaceholder:t="Search...",categories:n=Gg,sortOptions:r=Kg,showDateFilter:o=!1,onSearch:s,onFilter:i,onClear:a,defaultFilters:c}){const[l,f]=N.useState({category:(c==null?void 0:c.category)??"",sort:(c==null?void 0:c.sort)??"",dateFrom:c==null?void 0:c.dateFrom,dateTo:c==null?void 0:c.dateTo}),[u,h]=N.useState(!1),[g,b]=N.useState(!1),[p,v]=N.useState(l.dateFrom??new Date),[S,y]=N.useState(l.dateTo??new Date),x=(M,C)=>{const D={...l,[M]:C};f(D),i==null||i(D)},O=()=>{f({category:"",sort:"",dateFrom:void 0,dateTo:void 0}),a==null||a()},w=Object.values(l).some(M=>M!==""&&M!==void 0);return m.jsxs("div",{className:U("space-y-4",e),children:[m.jsx(Wi,{size:"medium",placeholder:t,onChange:M=>s==null?void 0:s(M.target.value)}),m.jsxs("div",{className:"flex flex-wrap items-center gap-4",children:[m.jsxs("div",{className:"flex items-center gap-2",children:[m.jsx(Vl,{className:"h-4 w-4 text-gray-500"}),m.jsx("span",{className:"text-sm font-medium text-gray-700",children:"Filters:"})]}),m.jsx(Tt,{placeholder:"Category",options:n,onValueChange:M=>x("category",M),className:"min-w-[140px]"}),m.jsx(Tt,{placeholder:"Sort by",options:r,onValueChange:M=>x("sort",M),className:"min-w-[140px]"}),o&&m.jsxs(m.Fragment,{children:[m.jsx(Pn,{placeholder:"From date",value:l.dateFrom,onSelect:M=>{x("dateFrom",M),v(M??p)},className:"min-w-[140px]",open:u,onOpenChange:h,month:p,onMonthChange:v}),m.jsx(Pn,{placeholder:"To date",value:l.dateTo,onSelect:M=>{x("dateTo",M),y(M??S)},className:"min-w-[140px]",open:g,onOpenChange:b,month:S,onMonthChange:y})]}),w&&m.jsxs(dt,{variant:"outline",size:"small",onClick:O,className:"flex items-center gap-1",children:[m.jsx(Br,{className:"h-3 w-3"}),"Clear"]})]})]})}const Xg=[{value:"personal",label:"Personal Account"},{value:"business",label:"Business Account"},{value:"developer",label:"Developer Account"}];function Zg({className:e,showDateOfBirth:t=!0,accountTypes:n=Xg,onValueChange:r}){const[o,s]=N.useState(),[i,a]=N.useState(!1),[c,l]=N.useState(!1),[f,u]=N.useState(!1),[h,g]=N.useState(o??new Date),[b,p]=N.useState(""),[v,S]=N.useState("");return m.jsxs("div",{className:U("space-y-4",e),children:[m.jsx(Ne,{label:"Username",placeholder:"Choose a username",helperText:"Must be at least 3 characters long",required:!0,onChange:y=>r==null?void 0:r("username",y.target.value)}),m.jsx(Ne,{label:"Email Address",type:"email",placeholder:"Enter your email",icon:m.jsx(Os,{className:"h-4 w-4"}),required:!0,onChange:y=>r==null?void 0:r("email",y.target.value)}),m.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:[m.jsx(Sr,{label:"Password",helperText:"Must be at least 8 characters",required:!0,value:b,onChange:y=>{p(y),r==null||r("password",y)},showPassword:i,onShowPasswordChange:a}),m.jsx(Sr,{label:"Confirm Password",placeholder:"Confirm your password",required:!0,value:v,onChange:y=>{S(y),r==null||r("confirmPassword",y)},showPassword:c,onShowPasswordChange:l})]}),m.jsx(Tt,{label:"Account Type",placeholder:"Select account type",options:n,leadingIcon:m.jsx(ru,{className:"h-4 w-4"}),required:!0,onValueChange:y=>r==null?void 0:r("accountType",y)}),t&&m.jsx(Pn,{label:"Date of Birth",placeholder:"Select your birth date",helperText:"Must be 18 or older",value:o,maxDate:new Date,onSelect:y=>{s(y),g(y??h),y&&(r==null||r("dateOfBirth",y))},open:f,onOpenChange:u,month:h,onMonthChange:g})]})}const Qg=[{value:"us",label:"United States"},{value:"ca",label:"Canada"},{value:"uk",label:"United Kingdom"},{value:"au",label:"Australia"},{value:"de",label:"Germany"},{value:"fr",label:"France"}];function Jg({className:e,countries:t=Qg,onValueChange:n}){return m.jsxs("div",{className:U("space-y-4",e),children:[m.jsx(Ne,{label:"Street Address",placeholder:"Enter street address",required:!0,onChange:r=>n==null?void 0:n("streetAddress",r.target.value)}),m.jsx(Ne,{label:"Apartment, suite, etc.",placeholder:"Apartment, suite, etc. (optional)",onChange:r=>n==null?void 0:n("addressLine2",r.target.value)}),m.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-4",children:[m.jsx(Ne,{label:"City",placeholder:"Enter city",required:!0,onChange:r=>n==null?void 0:n("city",r.target.value)}),m.jsx(Ne,{label:"State/Province",placeholder:"Enter state",required:!0,onChange:r=>n==null?void 0:n("state",r.target.value)}),m.jsx(Ne,{label:"ZIP/Postal Code",placeholder:"Enter ZIP code",required:!0,onChange:r=>n==null?void 0:n("zipCode",r.target.value)})]}),m.jsx(Tt,{label:"Country",placeholder:"Select country",options:t,leadingIcon:m.jsx(Ql,{className:"h-4 w-4"}),required:!0,onValueChange:r=>n==null?void 0:n("country",r)})]})}const ev=[{value:"sales",label:"Sales"},{value:"support",label:"Support"},{value:"general",label:"General Inquiry"}];function tv({className:e,showDepartment:t=!0,departmentOptions:n=ev,onValueChange:r}){return m.jsxs("div",{className:U("space-y-4",e),children:[m.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:[m.jsx(Ne,{label:"First Name",placeholder:"Enter first name",required:!0,onChange:o=>r==null?void 0:r("firstName",o.target.value)}),m.jsx(Ne,{label:"Last Name",placeholder:"Enter last name",required:!0,onChange:o=>r==null?void 0:r("lastName",o.target.value)})]}),m.jsx(Ne,{label:"Email Address",type:"email",placeholder:"Enter your email",icon:m.jsx(Os,{className:"h-4 w-4"}),required:!0,onChange:o=>r==null?void 0:r("email",o.target.value)}),m.jsx(Ne,{label:"Phone Number",type:"tel",placeholder:"+1 (555) 000-0000",icon:m.jsx(eu,{className:"h-4 w-4"}),onChange:o=>r==null?void 0:r("phone",o.target.value)}),t&&m.jsx(Tt,{label:"Department",placeholder:"Select department",options:n,leadingIcon:m.jsx(Rl,{className:"h-4 w-4"}),onValueChange:o=>r==null?void 0:r("department",o)}),m.jsx(As,{label:"Message",placeholder:"How can we help you?",required:!0,onChange:o=>r==null?void 0:r("message",o.target.value)})]})}var ss=1,nv=.9,rv=.8,ov=.17,gr=.1,vr=.999,sv=.9999,av=.99,iv=/[\\\/_+.#"@\[\(\{&]/,cv=/[\\\/_+.#"@\[\(\{&]/g,lv=/[\s-]/,$i=/[\s-]/g;function Wr(e,t,n,r,o,s,i){if(s===t.length)return o===e.length?ss:av;var a=`${o},${s}`;if(i[a]!==void 0)return i[a];for(var c=r.charAt(s),l=n.indexOf(c,o),f=0,u,h,g,b;l>=0;)u=Wr(e,t,n,r,l+1,s+1,i),u>f&&(l===o?u*=ss:iv.test(e.charAt(l-1))?(u*=rv,g=e.slice(o,l-1).match(cv),g&&o>0&&(u*=Math.pow(vr,g.length))):lv.test(e.charAt(l-1))?(u*=nv,b=e.slice(o,l-1).match($i),b&&o>0&&(u*=Math.pow(vr,b.length))):(u*=ov,o>0&&(u*=Math.pow(vr,l-o))),e.charAt(l)!==t.charAt(s)&&(u*=sv)),(u<gr&&n.charAt(l-1)===r.charAt(s+1)||r.charAt(s+1)===r.charAt(s)&&n.charAt(l-1)!==r.charAt(s))&&(h=Wr(e,t,n,r,l+1,s+2,i),h*gr>u&&(u=h*gr)),u>f&&(f=u),l=n.indexOf(c,l+1);return i[a]=f,f}function as(e){return e.toLowerCase().replace($i," ")}function uv(e,t,n){return e=n&&n.length>0?`${e+" "+n.join(" ")}`:e,Wr(e,t,as(e),as(t),0,0,{})}var Gn="Dialog",[Fi,ey]=Qt(Gn),[dv,Te]=Fi(Gn),Li=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:o,onOpenChange:s,modal:i=!0}=e,a=d.useRef(null),c=d.useRef(null),[l,f]=Cn({prop:r,defaultProp:o??!1,onChange:s,caller:Gn});return m.jsx(dv,{scope:t,triggerRef:a,contentRef:c,contentId:Me(),titleId:Me(),descriptionId:Me(),open:l,onOpenChange:f,onOpenToggle:d.useCallback(()=>f(u=>!u),[f]),modal:i,children:n})};Li.displayName=Gn;var Bi="DialogTrigger",fv=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=Te(Bi,n),s=fe(t,o.triggerRef);return m.jsx(oe.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":ao(o.open),...r,ref:s,onClick:ae(e.onClick,o.onOpenToggle)})});fv.displayName=Bi;var oo="DialogPortal",[mv,Yi]=Fi(oo,{forceMount:void 0}),zi=e=>{const{__scopeDialog:t,forceMount:n,children:r,container:o}=e,s=Te(oo,t);return m.jsx(mv,{scope:t,forceMount:n,children:d.Children.map(r,i=>m.jsx(Wt,{present:n||s.open,children:m.jsx(Fn,{asChild:!0,container:o,children:i})}))})};zi.displayName=oo;var An="DialogOverlay",Hi=d.forwardRef((e,t)=>{const n=Yi(An,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,s=Te(An,e.__scopeDialog);return s.modal?m.jsx(Wt,{present:r||s.open,children:m.jsx(pv,{...o,ref:t})}):null});Hi.displayName=An;var hv=ut("DialogOverlay.RemoveScroll"),pv=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=Te(An,n);return m.jsx(Bn,{as:hv,allowPinchZoom:!0,shards:[o.contentRef],children:m.jsx(oe.div,{"data-state":ao(o.open),...r,ref:t,style:{pointerEvents:"auto",...r.style}})})}),gt="DialogContent",qi=d.forwardRef((e,t)=>{const n=Yi(gt,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,s=Te(gt,e.__scopeDialog);return m.jsx(Wt,{present:r||s.open,children:s.modal?m.jsx(gv,{...o,ref:t}):m.jsx(vv,{...o,ref:t})})});qi.displayName=gt;var gv=d.forwardRef((e,t)=>{const n=Te(gt,e.__scopeDialog),r=d.useRef(null),o=fe(t,n.contentRef,r);return d.useEffect(()=>{const s=r.current;if(s)return Jr(s)},[]),m.jsx(Ui,{...e,ref:o,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:ae(e.onCloseAutoFocus,s=>{var i;s.preventDefault(),(i=n.triggerRef.current)==null||i.focus()}),onPointerDownOutside:ae(e.onPointerDownOutside,s=>{const i=s.detail.originalEvent,a=i.button===0&&i.ctrlKey===!0;(i.button===2||a)&&s.preventDefault()}),onFocusOutside:ae(e.onFocusOutside,s=>s.preventDefault())})}),vv=d.forwardRef((e,t)=>{const n=Te(gt,e.__scopeDialog),r=d.useRef(!1),o=d.useRef(!1);return m.jsx(Ui,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:s=>{var i,a;(i=e.onCloseAutoFocus)==null||i.call(e,s),s.defaultPrevented||(r.current||(a=n.triggerRef.current)==null||a.focus(),s.preventDefault()),r.current=!1,o.current=!1},onInteractOutside:s=>{var c,l;(c=e.onInteractOutside)==null||c.call(e,s),s.defaultPrevented||(r.current=!0,s.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const i=s.target;((l=n.triggerRef.current)==null?void 0:l.contains(i))&&s.preventDefault(),s.detail.originalEvent.type==="focusin"&&o.current&&s.preventDefault()}})}),Ui=d.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:o,onCloseAutoFocus:s,...i}=e,a=Te(gt,n),c=d.useRef(null),l=fe(t,c);return Yr(),m.jsxs(m.Fragment,{children:[m.jsx(_n,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:o,onUnmountAutoFocus:s,children:m.jsx(Rn,{role:"dialog",id:a.contentId,"aria-describedby":a.descriptionId,"aria-labelledby":a.titleId,"data-state":ao(a.open),...i,ref:l,onDismiss:()=>a.onOpenChange(!1)})}),m.jsxs(m.Fragment,{children:[m.jsx(yv,{titleId:a.titleId}),m.jsx(wv,{contentRef:c,descriptionId:a.descriptionId})]})]})}),so="DialogTitle",Gi=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=Te(so,n);return m.jsx(oe.h2,{id:o.titleId,...r,ref:t})});Gi.displayName=so;var Ki="DialogDescription",Vi=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=Te(Ki,n);return m.jsx(oe.p,{id:o.descriptionId,...r,ref:t})});Vi.displayName=Ki;var Xi="DialogClose",Zi=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=Te(Xi,n);return m.jsx(oe.button,{type:"button",...r,ref:t,onClick:ae(e.onClick,()=>o.onOpenChange(!1))})});Zi.displayName=Xi;function ao(e){return e?"open":"closed"}var Qi="DialogTitleWarning",[ty,Ji]=su(Qi,{contentName:gt,titleName:so,docsSlug:"dialog"}),yv=({titleId:e})=>{const t=Ji(Qi),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
148
+ ${h[r]}
149
+ ${v[n][t]}
150
+ ${g}
151
+ ${y}
152
+ ${m}
153
+ `.trim(),x=C=>{!u&&s&&s(C)},S=C=>{C.stopPropagation(),!u&&a&&a(C)},k=r==="small"?12:r==="large"?18:14;return f.jsxs("div",{className:w,onClick:x,...c,children:[l&&f.jsx("div",{className:`rounded-full overflow-hidden ${r==="small"?"w-4 h-4":r==="large"?"w-6 h-6":"w-5 h-5"}`,children:typeof l=="string"?f.jsx("img",{src:l,alt:"",className:"w-full h-full object-cover"}):l}),i&&!l&&f.jsx("div",{className:"flex items-center",children:b.isValidElement(i)?b.cloneElement(i,{size:k}):i}),f.jsx("span",{children:e}),o&&f.jsx("button",{onClick:S,className:`ml-1 rounded-full p-0.5 hover:bg-black hover:bg-opacity-10 transition-colors ${u?"cursor-not-allowed":"cursor-pointer"}`,disabled:u,children:f.jsx(En,{size:k})})]})},Dx={small:"h-8 text-sm",medium:"h-10",large:"h-12 text-base"},Rx={white:"bg-white border-gray-300",grey:"bg-gray-100 border-gray-300"};function Zl({size:e="medium",variant:t="white",placeholder:n="Search here",className:r,onChange:o,query:a=""}){return f.jsx(f.Fragment,{children:f.jsxs("div",{className:"relative",children:[f.jsx(zi,{strokeWidth:1.5,className:"absolute left-3 top-1/2 transform -translate-y-1/2 text-gray-900 h-4 w-4"}),f.jsx(Mn,{placeholder:n,className:q("pl-10 rounded-full",Dx[e],Rx[t],r),onChange:o,value:a})]})})}const Tx=[{value:"all",label:"All Categories"},{value:"electronics",label:"Electronics"},{value:"clothing",label:"Clothing"},{value:"books",label:"Books"}],Ox=[{value:"newest",label:"Newest First"},{value:"oldest",label:"Oldest First"},{value:"name-asc",label:"Name A-Z"},{value:"name-desc",label:"Name Z-A"}];function _x({className:e,searchPlaceholder:t="Search...",categories:n=Tx,sortOptions:r=Ox,showDateFilter:o=!1,onSearch:a,onFilter:s,onClear:i,defaultFilters:l}){const[u,m]=b.useState({category:(l==null?void 0:l.category)??"",sort:(l==null?void 0:l.sort)??"",dateFrom:l==null?void 0:l.dateFrom,dateTo:l==null?void 0:l.dateTo}),[c,p]=b.useState(!1),[h,v]=b.useState(!1),[g,y]=b.useState(u.dateFrom??new Date),[w,x]=b.useState(u.dateTo??new Date),S=(N,M)=>{const D={...u,[N]:M};m(D),s==null||s(D)},k=()=>{m({category:"",sort:"",dateFrom:void 0,dateTo:void 0}),i==null||i()},C=Object.values(u).some(N=>N!==""&&N!==void 0);return f.jsxs("div",{className:q("space-y-4",e),children:[f.jsx(Zl,{size:"medium",placeholder:t,onChange:N=>a==null?void 0:a(N.target.value)}),f.jsxs("div",{className:"flex flex-wrap items-center gap-4",children:[f.jsxs("div",{className:"flex items-center gap-2",children:[f.jsx(Fp,{className:"h-4 w-4 text-gray-500"}),f.jsx("span",{className:"text-sm font-medium text-gray-700",children:"Filters:"})]}),f.jsx(wn,{placeholder:"Category",options:n,onValueChange:N=>S("category",N),className:"min-w-[140px]"}),f.jsx(wn,{placeholder:"Sort by",options:r,onValueChange:N=>S("sort",N),className:"min-w-[140px]"}),o&&f.jsxs(f.Fragment,{children:[f.jsx(Hr,{placeholder:"From date",value:u.dateFrom,onSelect:N=>{S("dateFrom",N),y(N??g)},className:"min-w-[140px]",open:c,onOpenChange:p,month:g,onMonthChange:y}),f.jsx(Hr,{placeholder:"To date",value:u.dateTo,onSelect:N=>{S("dateTo",N),x(N??w)},className:"min-w-[140px]",open:h,onOpenChange:v,month:w,onMonthChange:x})]}),C&&f.jsxs(Kt,{variant:"outline",size:"small",onClick:k,className:"flex items-center gap-1",children:[f.jsx(En,{className:"h-3 w-3"}),"Clear"]})]})]})}const Px=[{value:"personal",label:"Personal Account"},{value:"business",label:"Business Account"},{value:"developer",label:"Developer Account"}];function Ax({className:e,showDateOfBirth:t=!0,accountTypes:n=Px,onValueChange:r}){const[o,a]=b.useState(),[s,i]=b.useState(!1),[l,u]=b.useState(!1),[m,c]=b.useState(!1),[p,h]=b.useState(o??new Date),[v,g]=b.useState(""),[y,w]=b.useState("");return f.jsxs("div",{className:q("space-y-4",e),children:[f.jsx(Qe,{label:"Username",placeholder:"Choose a username",helperText:"Must be at least 3 characters long",required:!0,onChange:x=>r==null?void 0:r("username",x.target.value)}),f.jsx(Qe,{label:"Email Address",type:"email",placeholder:"Enter your email",icon:f.jsx(Hi,{className:"h-4 w-4"}),required:!0,onChange:x=>r==null?void 0:r("email",x.target.value)}),f.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:[f.jsx(Zo,{label:"Password",helperText:"Must be at least 8 characters",required:!0,value:v,onChange:x=>{g(x),r==null||r("password",x)},showPassword:s,onShowPasswordChange:i}),f.jsx(Zo,{label:"Confirm Password",placeholder:"Confirm your password",required:!0,value:y,onChange:x=>{w(x),r==null||r("confirmPassword",x)},showPassword:l,onShowPasswordChange:u})]}),f.jsx(wn,{label:"Account Type",placeholder:"Select account type",options:n,leadingIcon:f.jsx(qp,{className:"h-4 w-4"}),required:!0,onValueChange:x=>r==null?void 0:r("accountType",x)}),t&&f.jsx(Hr,{label:"Date of Birth",placeholder:"Select your birth date",helperText:"Must be 18 or older",value:o,maxDate:new Date,onSelect:x=>{a(x),h(x??p),x&&(r==null||r("dateOfBirth",x))},open:m,onOpenChange:c,month:p,onMonthChange:h})]})}const Ix=[{value:"us",label:"United States"},{value:"ca",label:"Canada"},{value:"uk",label:"United Kingdom"},{value:"au",label:"Australia"},{value:"de",label:"Germany"},{value:"fr",label:"France"}];function jx({className:e,countries:t=Ix,onValueChange:n}){return f.jsxs("div",{className:q("space-y-4",e),children:[f.jsx(Qe,{label:"Street Address",placeholder:"Enter street address",required:!0,onChange:r=>n==null?void 0:n("streetAddress",r.target.value)}),f.jsx(Qe,{label:"Apartment, suite, etc.",placeholder:"Apartment, suite, etc. (optional)",onChange:r=>n==null?void 0:n("addressLine2",r.target.value)}),f.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-4",children:[f.jsx(Qe,{label:"City",placeholder:"Enter city",required:!0,onChange:r=>n==null?void 0:n("city",r.target.value)}),f.jsx(Qe,{label:"State/Province",placeholder:"Enter state",required:!0,onChange:r=>n==null?void 0:n("state",r.target.value)}),f.jsx(Qe,{label:"ZIP/Postal Code",placeholder:"Enter ZIP code",required:!0,onChange:r=>n==null?void 0:n("zipCode",r.target.value)})]}),f.jsx(wn,{label:"Country",placeholder:"Select country",options:t,leadingIcon:f.jsx(Yp,{className:"h-4 w-4"}),required:!0,onValueChange:r=>n==null?void 0:n("country",r)})]})}const $x=[{value:"sales",label:"Sales"},{value:"support",label:"Support"},{value:"general",label:"General Inquiry"}];function Lx({className:e,showDepartment:t=!0,departmentOptions:n=$x,onValueChange:r}){return f.jsxs("div",{className:q("space-y-4",e),children:[f.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:[f.jsx(Qe,{label:"First Name",placeholder:"Enter first name",required:!0,onChange:o=>r==null?void 0:r("firstName",o.target.value)}),f.jsx(Qe,{label:"Last Name",placeholder:"Enter last name",required:!0,onChange:o=>r==null?void 0:r("lastName",o.target.value)})]}),f.jsx(Qe,{label:"Email Address",type:"email",placeholder:"Enter your email",icon:f.jsx(Hi,{className:"h-4 w-4"}),required:!0,onChange:o=>r==null?void 0:r("email",o.target.value)}),f.jsx(Qe,{label:"Phone Number",type:"tel",placeholder:"+1 (555) 000-0000",icon:f.jsx(zp,{className:"h-4 w-4"}),onChange:o=>r==null?void 0:r("phone",o.target.value)}),t&&f.jsx(wn,{label:"Department",placeholder:"Select department",options:n,leadingIcon:f.jsx(Cp,{className:"h-4 w-4"}),onValueChange:o=>r==null?void 0:r("department",o)}),f.jsx(Ui,{label:"Message",placeholder:"How can we help you?",required:!0,onChange:o=>r==null?void 0:r("message",o.target.value)})]})}var ci=1,Fx=.9,Wx=.8,Bx=.17,Lo=.1,Fo=.999,Yx=.9999,Hx=.99,zx=/[\\\/_+.#"@\[\(\{&]/,Gx=/[\\\/_+.#"@\[\(\{&]/g,Ux=/[\s-]/,Ql=/[\s-]/g;function fa(e,t,n,r,o,a,s){if(a===t.length)return o===e.length?ci:Hx;var i=`${o},${a}`;if(s[i]!==void 0)return s[i];for(var l=r.charAt(a),u=n.indexOf(l,o),m=0,c,p,h,v;u>=0;)c=fa(e,t,n,r,u+1,a+1,s),c>m&&(u===o?c*=ci:zx.test(e.charAt(u-1))?(c*=Wx,h=e.slice(o,u-1).match(Gx),h&&o>0&&(c*=Math.pow(Fo,h.length))):Ux.test(e.charAt(u-1))?(c*=Fx,v=e.slice(o,u-1).match(Ql),v&&o>0&&(c*=Math.pow(Fo,v.length))):(c*=Bx,o>0&&(c*=Math.pow(Fo,u-o))),e.charAt(u)!==t.charAt(a)&&(c*=Yx)),(c<Lo&&n.charAt(u-1)===r.charAt(a+1)||r.charAt(a+1)===r.charAt(a)&&n.charAt(u-1)!==r.charAt(a))&&(p=fa(e,t,n,r,u+1,a+2,s),p*Lo>c&&(c=p*Lo)),c>m&&(m=c),u=n.indexOf(l,u+1);return s[i]=m,m}function li(e){return e.toLowerCase().replace(Ql," ")}function qx(e,t,n){return e=n&&n.length>0?`${e+" "+n.join(" ")}`:e,fa(e,t,li(e),li(t),0,0,{})}var co="Dialog",[Jl,MM]=Ye(co),[Vx,ct]=Jl(co),eu=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:o,onOpenChange:a,modal:s=!0}=e,i=d.useRef(null),l=d.useRef(null),[u,m]=tt({prop:r,defaultProp:o??!1,onChange:a,caller:co});return f.jsx(Vx,{scope:t,triggerRef:i,contentRef:l,contentId:ke(),titleId:ke(),descriptionId:ke(),open:u,onOpenChange:m,onOpenToggle:d.useCallback(()=>m(c=>!c),[m]),modal:s,children:n})};eu.displayName=co;var tu="DialogTrigger",nu=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=ct(tu,n),a=he(t,o.triggerRef);return f.jsx(te.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":Ha(o.open),...r,ref:a,onClick:K(e.onClick,o.onOpenToggle)})});nu.displayName=tu;var Ba="DialogPortal",[Kx,ru]=Jl(Ba,{forceMount:void 0}),ou=e=>{const{__scopeDialog:t,forceMount:n,children:r,container:o}=e,a=ct(Ba,t);return f.jsx(Kx,{scope:t,forceMount:n,children:d.Children.map(r,s=>f.jsx(He,{present:n||a.open,children:f.jsx(or,{asChild:!0,container:o,children:s})}))})};ou.displayName=Ba;var zr="DialogOverlay",au=d.forwardRef((e,t)=>{const n=ru(zr,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,a=ct(zr,e.__scopeDialog);return a.modal?f.jsx(He,{present:r||a.open,children:f.jsx(Zx,{...o,ref:t})}):null});au.displayName=zr;var Xx=Pt("DialogOverlay.RemoveScroll"),Zx=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=ct(zr,n);return f.jsx(ar,{as:Xx,allowPinchZoom:!0,shards:[o.contentRef],children:f.jsx(te.div,{"data-state":Ha(o.open),...r,ref:t,style:{pointerEvents:"auto",...r.style}})})}),Jt="DialogContent",su=d.forwardRef((e,t)=>{const n=ru(Jt,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,a=ct(Jt,e.__scopeDialog);return f.jsx(He,{present:r||a.open,children:a.modal?f.jsx(Qx,{...o,ref:t}):f.jsx(Jx,{...o,ref:t})})});su.displayName=Jt;var Qx=d.forwardRef((e,t)=>{const n=ct(Jt,e.__scopeDialog),r=d.useRef(null),o=he(t,n.contentRef,r);return d.useEffect(()=>{const a=r.current;if(a)return to(a)},[]),f.jsx(iu,{...e,ref:o,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:K(e.onCloseAutoFocus,a=>{var s;a.preventDefault(),(s=n.triggerRef.current)==null||s.focus()}),onPointerDownOutside:K(e.onPointerDownOutside,a=>{const s=a.detail.originalEvent,i=s.button===0&&s.ctrlKey===!0;(s.button===2||i)&&a.preventDefault()}),onFocusOutside:K(e.onFocusOutside,a=>a.preventDefault())})}),Jx=d.forwardRef((e,t)=>{const n=ct(Jt,e.__scopeDialog),r=d.useRef(!1),o=d.useRef(!1);return f.jsx(iu,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:a=>{var s,i;(s=e.onCloseAutoFocus)==null||s.call(e,a),a.defaultPrevented||(r.current||(i=n.triggerRef.current)==null||i.focus(),a.preventDefault()),r.current=!1,o.current=!1},onInteractOutside:a=>{var l,u;(l=e.onInteractOutside)==null||l.call(e,a),a.defaultPrevented||(r.current=!0,a.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const s=a.target;((u=n.triggerRef.current)==null?void 0:u.contains(s))&&a.preventDefault(),a.detail.originalEvent.type==="focusin"&&o.current&&a.preventDefault()}})}),iu=d.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:o,onCloseAutoFocus:a,...s}=e,i=ct(Jt,n),l=d.useRef(null),u=he(t,l);return Kr(),f.jsxs(f.Fragment,{children:[f.jsx(er,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:o,onUnmountAutoFocus:a,children:f.jsx(kn,{role:"dialog",id:i.contentId,"aria-describedby":i.descriptionId,"aria-labelledby":i.titleId,"data-state":Ha(i.open),...s,ref:u,onDismiss:()=>i.onOpenChange(!1)})}),f.jsxs(f.Fragment,{children:[f.jsx(e0,{titleId:i.titleId}),f.jsx(n0,{contentRef:l,descriptionId:i.descriptionId})]})]})}),Ya="DialogTitle",cu=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=ct(Ya,n);return f.jsx(te.h2,{id:o.titleId,...r,ref:t})});cu.displayName=Ya;var lu="DialogDescription",uu=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=ct(lu,n);return f.jsx(te.p,{id:o.descriptionId,...r,ref:t})});uu.displayName=lu;var du="DialogClose",fu=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=ct(du,n);return f.jsx(te.button,{type:"button",...r,ref:t,onClick:K(e.onClick,()=>o.onOpenChange(!1))})});fu.displayName=du;function Ha(e){return e?"open":"closed"}var mu="DialogTitleWarning",[EM,pu]=Kp(mu,{contentName:Jt,titleName:Ya,docsSlug:"dialog"}),e0=({titleId:e})=>{const t=pu(mu),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
149
154
 
150
155
  If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
151
156
 
152
- For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return d.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},bv="DialogDescriptionWarning",wv=({contentRef:e,descriptionId:t})=>{const r=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${Ji(bv).contentName}}.`;return d.useEffect(()=>{var s;const o=(s=e.current)==null?void 0:s.getAttribute("aria-describedby");t&&o&&(document.getElementById(t)||console.warn(r))},[r,e,t]),null},xv=Li,ec=zi,io=Hi,co=qi,tc=Gi,nc=Vi,Sv=Zi,zt='[cmdk-group=""]',yr='[cmdk-group-items=""]',kv='[cmdk-group-heading=""]',rc='[cmdk-item=""]',is=`${rc}:not([aria-disabled="true"])`,$r="cmdk-item-select",Ct="data-value",Mv=(e,t,n)=>uv(e,t,n),oc=d.createContext(void 0),on=()=>d.useContext(oc),sc=d.createContext(void 0),lo=()=>d.useContext(sc),ac=d.createContext(void 0),ic=d.forwardRef((e,t)=>{let n=Nt(()=>{var E,j;return{search:"",value:(j=(E=e.value)!=null?E:e.defaultValue)!=null?j:"",selectedItemId:void 0,filtered:{count:0,items:new Map,groups:new Set}}}),r=Nt(()=>new Set),o=Nt(()=>new Map),s=Nt(()=>new Map),i=Nt(()=>new Set),a=cc(e),{label:c,children:l,value:f,onValueChange:u,filter:h,shouldFilter:g,loop:b,disablePointerSelection:p=!1,vimBindings:v=!0,...S}=e,y=Me(),x=Me(),O=Me(),w=d.useRef(null),M=jv();vt(()=>{if(f!==void 0){let E=f.trim();n.current.value=E,C.emit()}},[f]),vt(()=>{M(6,J)},[]);let C=d.useMemo(()=>({subscribe:E=>(i.current.add(E),()=>i.current.delete(E)),snapshot:()=>n.current,setState:(E,j,F)=>{var W,X,R,V;if(!Object.is(n.current[E],j)){if(n.current[E]=j,E==="search")K(),L(),M(1,$);else if(E==="value"){if(document.activeElement.hasAttribute("cmdk-input")||document.activeElement.hasAttribute("cmdk-root")){let Z=document.getElementById(O);Z?Z.focus():(W=document.getElementById(y))==null||W.focus()}if(M(7,()=>{var Z;n.current.selectedItemId=(Z=_())==null?void 0:Z.id,C.emit()}),F||M(5,J),((X=a.current)==null?void 0:X.value)!==void 0){let Z=j??"";(V=(R=a.current).onValueChange)==null||V.call(R,Z);return}}C.emit()}},emit:()=>{i.current.forEach(E=>E())}}),[]),D=d.useMemo(()=>({value:(E,j,F)=>{var W;j!==((W=s.current.get(E))==null?void 0:W.value)&&(s.current.set(E,{value:j,keywords:F}),n.current.filtered.items.set(E,Y(j,F)),M(2,()=>{L(),C.emit()}))},item:(E,j)=>(r.current.add(E),j&&(o.current.has(j)?o.current.get(j).add(E):o.current.set(j,new Set([E]))),M(3,()=>{K(),L(),n.current.value||$(),C.emit()}),()=>{s.current.delete(E),r.current.delete(E),n.current.filtered.items.delete(E);let F=_();M(4,()=>{K(),(F==null?void 0:F.getAttribute("id"))===E&&$(),C.emit()})}),group:E=>(o.current.has(E)||o.current.set(E,new Set),()=>{s.current.delete(E),o.current.delete(E)}),filter:()=>a.current.shouldFilter,label:c||e["aria-label"],getDisablePointerSelection:()=>a.current.disablePointerSelection,listId:y,inputId:O,labelId:x,listInnerRef:w}),[]);function Y(E,j){var F,W;let X=(W=(F=a.current)==null?void 0:F.filter)!=null?W:Mv;return E?X(E,n.current.search,j):0}function L(){if(!n.current.search||a.current.shouldFilter===!1)return;let E=n.current.filtered.items,j=[];n.current.filtered.groups.forEach(W=>{let X=o.current.get(W),R=0;X.forEach(V=>{let Z=E.get(V);R=Math.max(Z,R)}),j.push([W,R])});let F=w.current;A().sort((W,X)=>{var R,V;let Z=W.getAttribute("id"),G=X.getAttribute("id");return((R=E.get(G))!=null?R:0)-((V=E.get(Z))!=null?V:0)}).forEach(W=>{let X=W.closest(yr);X?X.appendChild(W.parentElement===X?W:W.closest(`${yr} > *`)):F.appendChild(W.parentElement===F?W:W.closest(`${yr} > *`))}),j.sort((W,X)=>X[1]-W[1]).forEach(W=>{var X;let R=(X=w.current)==null?void 0:X.querySelector(`${zt}[${Ct}="${encodeURIComponent(W[0])}"]`);R==null||R.parentElement.appendChild(R)})}function $(){let E=A().find(F=>F.getAttribute("aria-disabled")!=="true"),j=E==null?void 0:E.getAttribute(Ct);C.setState("value",j||void 0)}function K(){var E,j,F,W;if(!n.current.search||a.current.shouldFilter===!1){n.current.filtered.count=r.current.size;return}n.current.filtered.groups=new Set;let X=0;for(let R of r.current){let V=(j=(E=s.current.get(R))==null?void 0:E.value)!=null?j:"",Z=(W=(F=s.current.get(R))==null?void 0:F.keywords)!=null?W:[],G=Y(V,Z);n.current.filtered.items.set(R,G),G>0&&X++}for(let[R,V]of o.current)for(let Z of V)if(n.current.filtered.items.get(Z)>0){n.current.filtered.groups.add(R);break}n.current.filtered.count=X}function J(){var E,j,F;let W=_();W&&(((E=W.parentElement)==null?void 0:E.firstChild)===W&&((F=(j=W.closest(zt))==null?void 0:j.querySelector(kv))==null||F.scrollIntoView({block:"nearest"})),W.scrollIntoView({block:"nearest"}))}function _(){var E;return(E=w.current)==null?void 0:E.querySelector(`${rc}[aria-selected="true"]`)}function A(){var E;return Array.from(((E=w.current)==null?void 0:E.querySelectorAll(is))||[])}function P(E){let j=A()[E];j&&C.setState("value",j.getAttribute(Ct))}function T(E){var j;let F=_(),W=A(),X=W.findIndex(V=>V===F),R=W[X+E];(j=a.current)!=null&&j.loop&&(R=X+E<0?W[W.length-1]:X+E===W.length?W[0]:W[X+E]),R&&C.setState("value",R.getAttribute(Ct))}function k(E){let j=_(),F=j==null?void 0:j.closest(zt),W;for(;F&&!W;)F=E>0?Rv(F,zt):_v(F,zt),W=F==null?void 0:F.querySelector(is);W?C.setState("value",W.getAttribute(Ct)):T(E)}let I=()=>P(A().length-1),B=E=>{E.preventDefault(),E.metaKey?I():E.altKey?k(1):T(1)},Q=E=>{E.preventDefault(),E.metaKey?P(0):E.altKey?k(-1):T(-1)};return d.createElement(oe.div,{ref:t,tabIndex:-1,...S,"cmdk-root":"",onKeyDown:E=>{var j;(j=S.onKeyDown)==null||j.call(S,E);let F=E.nativeEvent.isComposing||E.keyCode===229;if(!(E.defaultPrevented||F))switch(E.key){case"n":case"j":{v&&E.ctrlKey&&B(E);break}case"ArrowDown":{B(E);break}case"p":case"k":{v&&E.ctrlKey&&Q(E);break}case"ArrowUp":{Q(E);break}case"Home":{E.preventDefault(),P(0);break}case"End":{E.preventDefault(),I();break}case"Enter":{E.preventDefault();let W=_();if(W){let X=new Event($r);W.dispatchEvent(X)}}}}},d.createElement("label",{"cmdk-label":"",htmlFor:D.inputId,id:D.labelId,style:Wv},c),Kn(e,E=>d.createElement(sc.Provider,{value:C},d.createElement(oc.Provider,{value:D},E))))}),Cv=d.forwardRef((e,t)=>{var n,r;let o=Me(),s=d.useRef(null),i=d.useContext(ac),a=on(),c=cc(e),l=(r=(n=c.current)==null?void 0:n.forceMount)!=null?r:i==null?void 0:i.forceMount;vt(()=>{if(!l)return a.item(o,i==null?void 0:i.id)},[l]);let f=lc(o,s,[e.value,e.children,s],e.keywords),u=lo(),h=et(M=>M.value&&M.value===f.current),g=et(M=>l||a.filter()===!1?!0:M.search?M.filtered.items.get(o)>0:!0);d.useEffect(()=>{let M=s.current;if(!(!M||e.disabled))return M.addEventListener($r,b),()=>M.removeEventListener($r,b)},[g,e.onSelect,e.disabled]);function b(){var M,C;p(),(C=(M=c.current).onSelect)==null||C.call(M,f.current)}function p(){u.setState("value",f.current,!0)}if(!g)return null;let{disabled:v,value:S,onSelect:y,forceMount:x,keywords:O,...w}=e;return d.createElement(oe.div,{ref:lt(s,t),...w,id:o,"cmdk-item":"",role:"option","aria-disabled":!!v,"aria-selected":!!h,"data-disabled":!!v,"data-selected":!!h,onPointerMove:v||a.getDisablePointerSelection()?void 0:p,onClick:v?void 0:b},e.children)}),Nv=d.forwardRef((e,t)=>{let{heading:n,children:r,forceMount:o,...s}=e,i=Me(),a=d.useRef(null),c=d.useRef(null),l=Me(),f=on(),u=et(g=>o||f.filter()===!1?!0:g.search?g.filtered.groups.has(i):!0);vt(()=>f.group(i),[]),lc(i,a,[e.value,e.heading,c]);let h=d.useMemo(()=>({id:i,forceMount:o}),[o]);return d.createElement(oe.div,{ref:lt(a,t),...s,"cmdk-group":"",role:"presentation",hidden:u?void 0:!0},n&&d.createElement("div",{ref:c,"cmdk-group-heading":"","aria-hidden":!0,id:l},n),Kn(e,g=>d.createElement("div",{"cmdk-group-items":"",role:"group","aria-labelledby":n?l:void 0},d.createElement(ac.Provider,{value:h},g))))}),Dv=d.forwardRef((e,t)=>{let{alwaysRender:n,...r}=e,o=d.useRef(null),s=et(i=>!i.search);return!n&&!s?null:d.createElement(oe.div,{ref:lt(o,t),...r,"cmdk-separator":"",role:"separator"})}),Ov=d.forwardRef((e,t)=>{let{onValueChange:n,...r}=e,o=e.value!=null,s=lo(),i=et(l=>l.search),a=et(l=>l.selectedItemId),c=on();return d.useEffect(()=>{e.value!=null&&s.setState("search",e.value)},[e.value]),d.createElement(oe.input,{ref:t,...r,"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":a,id:c.inputId,type:"text",value:o?e.value:i,onChange:l=>{o||s.setState("search",l.target.value),n==null||n(l.target.value)}})}),Ev=d.forwardRef((e,t)=>{let{children:n,label:r="Suggestions",...o}=e,s=d.useRef(null),i=d.useRef(null),a=et(l=>l.selectedItemId),c=on();return d.useEffect(()=>{if(i.current&&s.current){let l=i.current,f=s.current,u,h=new ResizeObserver(()=>{u=requestAnimationFrame(()=>{let g=l.offsetHeight;f.style.setProperty("--cmdk-list-height",g.toFixed(1)+"px")})});return h.observe(l),()=>{cancelAnimationFrame(u),h.unobserve(l)}}},[]),d.createElement(oe.div,{ref:lt(s,t),...o,"cmdk-list":"",role:"listbox",tabIndex:-1,"aria-activedescendant":a,"aria-label":r,id:c.listId},Kn(e,l=>d.createElement("div",{ref:lt(i,c.listInnerRef),"cmdk-list-sizer":""},l)))}),Pv=d.forwardRef((e,t)=>{let{open:n,onOpenChange:r,overlayClassName:o,contentClassName:s,container:i,...a}=e;return d.createElement(xv,{open:n,onOpenChange:r},d.createElement(ec,{container:i},d.createElement(io,{"cmdk-overlay":"",className:o}),d.createElement(co,{"aria-label":e.label,"cmdk-dialog":"",className:s},d.createElement(ic,{ref:t,...a}))))}),Av=d.forwardRef((e,t)=>et(n=>n.filtered.count===0)?d.createElement(oe.div,{ref:t,...e,"cmdk-empty":"",role:"presentation"}):null),Tv=d.forwardRef((e,t)=>{let{progress:n,children:r,label:o="Loading...",...s}=e;return d.createElement(oe.div,{ref:t,...s,"cmdk-loading":"",role:"progressbar","aria-valuenow":n,"aria-valuemin":0,"aria-valuemax":100,"aria-label":o},Kn(e,i=>d.createElement("div",{"aria-hidden":!0},i)))}),ge=Object.assign(ic,{List:Ev,Item:Cv,Input:Ov,Group:Nv,Separator:Dv,Dialog:Pv,Empty:Av,Loading:Tv});function Rv(e,t){let n=e.nextElementSibling;for(;n;){if(n.matches(t))return n;n=n.nextElementSibling}}function _v(e,t){let n=e.previousElementSibling;for(;n;){if(n.matches(t))return n;n=n.previousElementSibling}}function cc(e){let t=d.useRef(e);return vt(()=>{t.current=e}),t}var vt=typeof window>"u"?d.useEffect:d.useLayoutEffect;function Nt(e){let t=d.useRef();return t.current===void 0&&(t.current=e()),t}function et(e){let t=lo(),n=()=>e(t.snapshot());return d.useSyncExternalStore(t.subscribe,n,n)}function lc(e,t,n,r=[]){let o=d.useRef(),s=on();return vt(()=>{var i;let a=(()=>{var l;for(let f of n){if(typeof f=="string")return f.trim();if(typeof f=="object"&&"current"in f)return f.current?(l=f.current.textContent)==null?void 0:l.trim():o.current}})(),c=r.map(l=>l.trim());s.value(e,a,c),(i=t.current)==null||i.setAttribute(Ct,a),o.current=a}),o}var jv=()=>{let[e,t]=d.useState(),n=Nt(()=>new Map);return vt(()=>{n.current.forEach(r=>r()),n.current=new Map},[e]),(r,o)=>{n.current.set(r,o),t({})}};function Iv(e){let t=e.type;return typeof t=="function"?t(e.props):"render"in t?t.render(e.props):e}function Kn({asChild:e,children:t},n){return e&&d.isValidElement(t)?d.cloneElement(Iv(t),{ref:t.ref},n(t.props.children)):n(t)}var Wv={position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0"};const $v=ec,uc=d.forwardRef(({className:e,...t},n)=>m.jsx(io,{ref:n,className:U("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t}));uc.displayName=io.displayName;const Fv=d.forwardRef(({className:e,children:t,...n},r)=>m.jsxs($v,{children:[m.jsx(uc,{}),m.jsxs(co,{ref:r,className:U("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg",e),...n,children:[t,m.jsxs(Sv,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground",children:[m.jsx(Br,{className:"h-4 w-4"}),m.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));Fv.displayName=co.displayName;const Lv=d.forwardRef(({className:e,...t},n)=>m.jsx(tc,{ref:n,className:U("text-lg font-semibold leading-none tracking-tight",e),...t}));Lv.displayName=tc.displayName;const Bv=d.forwardRef(({className:e,...t},n)=>m.jsx(nc,{ref:n,className:U("text-sm text-muted-foreground",e),...t}));Bv.displayName=nc.displayName;const Yv=d.forwardRef(({className:e,...t},n)=>m.jsx(ge,{ref:n,className:U("flex h-full w-full flex-col overflow-hidden rounded-md bg-popover text-popover-foreground",e),...t}));Yv.displayName=ge.displayName;const dc=d.forwardRef(({className:e,...t},n)=>m.jsxs("div",{className:"flex items-center h-auto px-3","cmdk-input-wrapper":"",children:[m.jsx(Es,{strokeWidth:1.25,className:"mr-2 h-4 w-4 shrink-0"}),m.jsx(ge.Input,{ref:n,className:U("flex h-11 w-full rounded-md bg-transparent py-3 text-sm outline-none placeholder:text-gray-400 disabled:cursor-not-allowed disabled:opacity-50",e),...t})]}));dc.displayName=ge.Input.displayName;const fc=d.forwardRef(({className:e,...t},n)=>m.jsx(ge.List,{ref:n,className:U("max-h-[300px] overflow-y-auto overflow-x-hidden",e),...t}));fc.displayName=ge.List.displayName;const zv=d.forwardRef((e,t)=>m.jsx(ge.Empty,{ref:t,className:"py-6 text-center text-sm",...e}));zv.displayName=ge.Empty.displayName;const mc=d.forwardRef(({className:e,...t},n)=>m.jsx(ge.Group,{ref:n,className:U("overflow-hidden p-1 text-foreground [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground",e),...t}));mc.displayName=ge.Group.displayName;const Hv=d.forwardRef(({className:e,...t},n)=>m.jsx(ge.Separator,{ref:n,className:U("-mx-1 h-px bg-border",e),...t}));Hv.displayName=ge.Separator.displayName;const hc=d.forwardRef(({className:e,...t},n)=>m.jsx(ge.Item,{ref:n,className:U("relative flex cursor-default gap-2 select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none data-[disabled=true]:pointer-events-none data-[selected='true']:bg-accent data-[selected=true]:text-accent-foreground data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",e),...t}));hc.displayName=ge.Item.displayName;function qv({className:e,...t}){return m.jsx("div",{className:U("animate-pulse rounded-md bg-muted",e),...t})}function Uv(e="medium",t="white"){const n={small:"text-sm py-1 px-2 h-8",medium:"text-base py-2 px-3 h-10",large:"text-lg py-3 px-4 h-12"},r={white:"bg-background text-foreground border-border",grey:"bg-muted text-muted-foreground border-border"};return{sizeClasses:n[e],variantClasses:r[t],combined:`${n[e]} ${r[t]}`}}const Gv=({options:e,placeholder:t,emptyMessage:n,value:r,onValueChange:o,disabled:s,isLoading:i=!1,className:a,size:c,variant:l})=>{const{variantClasses:f,combined:u}=Uv(c,l),h=N.useRef(null),[g,b]=N.useState(!1),[p,v]=N.useState(r),[S,y]=N.useState((r==null?void 0:r.label)||""),x=N.useCallback(M=>{const C=h.current;if(C){if(g||b(!0),M.key==="Enter"&&C.value!==""){const D=e.find(Y=>Y.label===C.value);D&&(v(D),o==null||o(D))}M.key==="Escape"&&C.blur()}},[g,e,o]),O=N.useCallback(()=>{b(!1),y((p==null?void 0:p.label)||"")},[p]),w=N.useCallback(M=>{y(M.label),v(M),o==null||o(M),setTimeout(()=>{var C;(C=h==null?void 0:h.current)==null||C.blur()},0)},[o]);return m.jsxs(ge,{onKeyDown:x,children:[m.jsxs("div",{className:U("rounded-full border bg-gray-100",f,a),children:[" ",m.jsx(dc,{ref:h,value:S,onValueChange:i?void 0:y,onBlur:O,onFocus:()=>b(!0),placeholder:t,disabled:s,className:u})]}),m.jsx("div",{className:"relative mt-1",children:m.jsx("div",{className:U("animate-in fade-in-0 zoom-in-95 absolute top-0 z-10 w-full rounded-xl bg-white dark:bg-gray-800 outline-none",g?"block":"hidden",a),children:m.jsxs(fc,{className:"rounded-lg ring-1 ring-slate-200 dark:ring-gray-700",children:[i?m.jsx(ge.Loading,{children:m.jsx("div",{className:"p-1",children:m.jsx(qv,{className:"h-8 w-full"})})}):null,e.length>0&&!i?m.jsx(mc,{children:e.map(M=>{const C=(p==null?void 0:p.value)===M.value;return m.jsxs(hc,{value:M.label,onMouseDown:D=>{D.preventDefault(),D.stopPropagation()},onSelect:()=>w(M),className:U("flex w-full items-center gap-2 dark:text-white",C?null:"pl-8"),children:[C?m.jsx(Ns,{className:"w-4"}):null,M.label]},M.value)})}):null,i?null:m.jsx(ge.Empty,{className:"select-none rounded-sm px-2 py-3 text-center text-sm dark:text-gray-400",children:n})]})})})]})};function Kv({title:e,children:t,className:n}){return m.jsxs("section",{className:U("space-y-6",n),children:[m.jsx("div",{className:"border-b border-gray-200 pb-3",children:m.jsx("h2",{className:"text-sm font-semibold text-gray-900 tracking-wide uppercase",children:e})}),t]})}const pc=N.forwardRef(({className:e,type:t,label:n,helperText:r,startAdornment:o,endAdornment:s,...i},a)=>m.jsxs("div",{className:"flex flex-col",children:[n&&m.jsx("label",{className:"mb-1 text-sm text-gray-700",children:n}),m.jsxs("div",{className:U("flex items-center h-10 w-full rounded-md border border-input bg-background text-sm ring-offset-background disabled:cursor-not-allowed disabled:opacity-50",e),children:[o&&m.jsx("span",{className:"px-3 text-sm text-muted-foreground",children:o}),m.jsx("input",{type:t,className:U("flex-1 px-3 py-2 placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-primary focus:ring-offset-2 disabled:opacity-50"),ref:a,...i}),s&&m.jsx("span",{className:"px-3 text-sm text-muted-foreground",children:s})]}),r&&m.jsx("span",{className:"mt-1 text-xs text-muted-foreground",children:r})]}));pc.displayName="CurrencyInput";const Vv=Fr("relative w-full rounded-lg border p-4 [&>svg~*]:pl-7 [&>svg+div]:translate-y-[-3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg]:text-foreground",{variants:{variant:{default:"bg-background text-foreground",destructive:"border-destructive/50 text-destructive dark:border-destructive [&>svg]:text-destructive"}},defaultVariants:{variant:"default"}}),gc=d.forwardRef(({className:e,variant:t,...n},r)=>m.jsx("div",{ref:r,role:"alert",className:U(Vv({variant:t}),e),...n}));gc.displayName="Alert";const Xv=d.forwardRef(({className:e,...t},n)=>m.jsx("h5",{ref:n,className:U("mb-1 font-medium leading-none tracking-tight",e),...t}));Xv.displayName="AlertTitle";const Zv=d.forwardRef(({className:e,...t},n)=>m.jsx("p",{ref:n,className:U("text-sm [&_p]:leading-relaxed",e),...t}));Zv.displayName="AlertDescription";exports.AddressFormSection=Jg;exports.Alert=gc;exports.AutoComplete=Gv;exports.ComponentSection=Kv;exports.ContactFormSection=tv;exports.CurrencyInput=pc;exports.DatePickerField=Pn;exports.DoctAnimationLoader=kl;exports.DoctButton=dt;exports.DoctButtonVariants=Ss;exports.DoctChip=Hg;exports.DoctTypography=Sl;exports.LabeledInput=Ne;exports.OtpInput=Ol;exports.PasswordInput=Sr;exports.SearchFilterSection=Vg;exports.SearchInput=Wi;exports.SelectField=Tt;exports.TextareaField=As;exports.UserRegistrationSection=Zg;
157
+ For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return d.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},t0="DialogDescriptionWarning",n0=({contentRef:e,descriptionId:t})=>{const r=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${pu(t0).contentName}}.`;return d.useEffect(()=>{var a;const o=(a=e.current)==null?void 0:a.getAttribute("aria-describedby");t&&o&&(document.getElementById(t)||console.warn(r))},[r,e,t]),null},za=eu,hu=nu,Ga=ou,lo=au,uo=su,Ua=cu,qa=uu,Va=fu,Ln='[cmdk-group=""]',Wo='[cmdk-group-items=""]',r0='[cmdk-group-heading=""]',gu='[cmdk-item=""]',ui=`${gu}:not([aria-disabled="true"])`,ma="cmdk-item-select",mn="data-value",o0=(e,t,n)=>qx(e,t,n),vu=d.createContext(void 0),dr=()=>d.useContext(vu),yu=d.createContext(void 0),Ka=()=>d.useContext(yu),bu=d.createContext(void 0),wu=d.forwardRef((e,t)=>{let n=pn(()=>{var T,A;return{search:"",value:(A=(T=e.value)!=null?T:e.defaultValue)!=null?A:"",selectedItemId:void 0,filtered:{count:0,items:new Map,groups:new Set}}}),r=pn(()=>new Set),o=pn(()=>new Map),a=pn(()=>new Map),s=pn(()=>new Set),i=xu(e),{label:l,children:u,value:m,onValueChange:c,filter:p,shouldFilter:h,loop:v,disablePointerSelection:g=!1,vimBindings:y=!0,...w}=e,x=ke(),S=ke(),k=ke(),C=d.useRef(null),N=h0();en(()=>{if(m!==void 0){let T=m.trim();n.current.value=T,M.emit()}},[m]),en(()=>{N(6,$)},[]);let M=d.useMemo(()=>({subscribe:T=>(s.current.add(T),()=>s.current.delete(T)),snapshot:()=>n.current,setState:(T,A,W)=>{var H,U,j,Z;if(!Object.is(n.current[T],A)){if(n.current[T]=A,T==="search")V(),B(),N(1,F);else if(T==="value"){if(document.activeElement.hasAttribute("cmdk-input")||document.activeElement.hasAttribute("cmdk-root")){let X=document.getElementById(k);X?X.focus():(H=document.getElementById(x))==null||H.focus()}if(N(7,()=>{var X;n.current.selectedItemId=(X=I())==null?void 0:X.id,M.emit()}),W||N(5,$),((U=i.current)==null?void 0:U.value)!==void 0){let X=A??"";(Z=(j=i.current).onValueChange)==null||Z.call(j,X);return}}M.emit()}},emit:()=>{s.current.forEach(T=>T())}}),[]),D=d.useMemo(()=>({value:(T,A,W)=>{var H;A!==((H=a.current.get(T))==null?void 0:H.value)&&(a.current.set(T,{value:A,keywords:W}),n.current.filtered.items.set(T,L(A,W)),N(2,()=>{B(),M.emit()}))},item:(T,A)=>(r.current.add(T),A&&(o.current.has(A)?o.current.get(A).add(T):o.current.set(A,new Set([T]))),N(3,()=>{V(),B(),n.current.value||F(),M.emit()}),()=>{a.current.delete(T),r.current.delete(T),n.current.filtered.items.delete(T);let W=I();N(4,()=>{V(),(W==null?void 0:W.getAttribute("id"))===T&&F(),M.emit()})}),group:T=>(o.current.has(T)||o.current.set(T,new Set),()=>{a.current.delete(T),o.current.delete(T)}),filter:()=>i.current.shouldFilter,label:l||e["aria-label"],getDisablePointerSelection:()=>i.current.disablePointerSelection,listId:x,inputId:k,labelId:S,listInnerRef:C}),[]);function L(T,A){var W,H;let U=(H=(W=i.current)==null?void 0:W.filter)!=null?H:o0;return T?U(T,n.current.search,A):0}function B(){if(!n.current.search||i.current.shouldFilter===!1)return;let T=n.current.filtered.items,A=[];n.current.filtered.groups.forEach(H=>{let U=o.current.get(H),j=0;U.forEach(Z=>{let X=T.get(Z);j=Math.max(X,j)}),A.push([H,j])});let W=C.current;_().sort((H,U)=>{var j,Z;let X=H.getAttribute("id"),Q=U.getAttribute("id");return((j=T.get(Q))!=null?j:0)-((Z=T.get(X))!=null?Z:0)}).forEach(H=>{let U=H.closest(Wo);U?U.appendChild(H.parentElement===U?H:H.closest(`${Wo} > *`)):W.appendChild(H.parentElement===W?H:H.closest(`${Wo} > *`))}),A.sort((H,U)=>U[1]-H[1]).forEach(H=>{var U;let j=(U=C.current)==null?void 0:U.querySelector(`${Ln}[${mn}="${encodeURIComponent(H[0])}"]`);j==null||j.parentElement.appendChild(j)})}function F(){let T=_().find(W=>W.getAttribute("aria-disabled")!=="true"),A=T==null?void 0:T.getAttribute(mn);M.setState("value",A||void 0)}function V(){var T,A,W,H;if(!n.current.search||i.current.shouldFilter===!1){n.current.filtered.count=r.current.size;return}n.current.filtered.groups=new Set;let U=0;for(let j of r.current){let Z=(A=(T=a.current.get(j))==null?void 0:T.value)!=null?A:"",X=(H=(W=a.current.get(j))==null?void 0:W.keywords)!=null?H:[],Q=L(Z,X);n.current.filtered.items.set(j,Q),Q>0&&U++}for(let[j,Z]of o.current)for(let X of Z)if(n.current.filtered.items.get(X)>0){n.current.filtered.groups.add(j);break}n.current.filtered.count=U}function $(){var T,A,W;let H=I();H&&(((T=H.parentElement)==null?void 0:T.firstChild)===H&&((W=(A=H.closest(Ln))==null?void 0:A.querySelector(r0))==null||W.scrollIntoView({block:"nearest"})),H.scrollIntoView({block:"nearest"}))}function I(){var T;return(T=C.current)==null?void 0:T.querySelector(`${gu}[aria-selected="true"]`)}function _(){var T;return Array.from(((T=C.current)==null?void 0:T.querySelectorAll(ui))||[])}function R(T){let A=_()[T];A&&M.setState("value",A.getAttribute(mn))}function P(T){var A;let W=I(),H=_(),U=H.findIndex(Z=>Z===W),j=H[U+T];(A=i.current)!=null&&A.loop&&(j=U+T<0?H[H.length-1]:U+T===H.length?H[0]:H[U+T]),j&&M.setState("value",j.getAttribute(mn))}function E(T){let A=I(),W=A==null?void 0:A.closest(Ln),H;for(;W&&!H;)W=T>0?m0(W,Ln):p0(W,Ln),H=W==null?void 0:W.querySelector(ui);H?M.setState("value",H.getAttribute(mn)):P(T)}let O=()=>R(_().length-1),Y=T=>{T.preventDefault(),T.metaKey?O():T.altKey?E(1):P(1)},G=T=>{T.preventDefault(),T.metaKey?R(0):T.altKey?E(-1):P(-1)};return d.createElement(te.div,{ref:t,tabIndex:-1,...w,"cmdk-root":"",onKeyDown:T=>{var A;(A=w.onKeyDown)==null||A.call(w,T);let W=T.nativeEvent.isComposing||T.keyCode===229;if(!(T.defaultPrevented||W))switch(T.key){case"n":case"j":{y&&T.ctrlKey&&Y(T);break}case"ArrowDown":{Y(T);break}case"p":case"k":{y&&T.ctrlKey&&G(T);break}case"ArrowUp":{G(T);break}case"Home":{T.preventDefault(),R(0);break}case"End":{T.preventDefault(),O();break}case"Enter":{T.preventDefault();let H=I();if(H){let U=new Event(ma);H.dispatchEvent(U)}}}}},d.createElement("label",{"cmdk-label":"",htmlFor:D.inputId,id:D.labelId,style:v0},l),fo(e,T=>d.createElement(yu.Provider,{value:M},d.createElement(vu.Provider,{value:D},T))))}),a0=d.forwardRef((e,t)=>{var n,r;let o=ke(),a=d.useRef(null),s=d.useContext(bu),i=dr(),l=xu(e),u=(r=(n=l.current)==null?void 0:n.forceMount)!=null?r:s==null?void 0:s.forceMount;en(()=>{if(!u)return i.item(o,s==null?void 0:s.id)},[u]);let m=Su(o,a,[e.value,e.children,a],e.keywords),c=Ka(),p=jt(N=>N.value&&N.value===m.current),h=jt(N=>u||i.filter()===!1?!0:N.search?N.filtered.items.get(o)>0:!0);d.useEffect(()=>{let N=a.current;if(!(!N||e.disabled))return N.addEventListener(ma,v),()=>N.removeEventListener(ma,v)},[h,e.onSelect,e.disabled]);function v(){var N,M;g(),(M=(N=l.current).onSelect)==null||M.call(N,m.current)}function g(){c.setState("value",m.current,!0)}if(!h)return null;let{disabled:y,value:w,onSelect:x,forceMount:S,keywords:k,...C}=e;return d.createElement(te.div,{ref:Ct(a,t),...C,id:o,"cmdk-item":"",role:"option","aria-disabled":!!y,"aria-selected":!!p,"data-disabled":!!y,"data-selected":!!p,onPointerMove:y||i.getDisablePointerSelection()?void 0:g,onClick:y?void 0:v},e.children)}),s0=d.forwardRef((e,t)=>{let{heading:n,children:r,forceMount:o,...a}=e,s=ke(),i=d.useRef(null),l=d.useRef(null),u=ke(),m=dr(),c=jt(h=>o||m.filter()===!1?!0:h.search?h.filtered.groups.has(s):!0);en(()=>m.group(s),[]),Su(s,i,[e.value,e.heading,l]);let p=d.useMemo(()=>({id:s,forceMount:o}),[o]);return d.createElement(te.div,{ref:Ct(i,t),...a,"cmdk-group":"",role:"presentation",hidden:c?void 0:!0},n&&d.createElement("div",{ref:l,"cmdk-group-heading":"","aria-hidden":!0,id:u},n),fo(e,h=>d.createElement("div",{"cmdk-group-items":"",role:"group","aria-labelledby":n?u:void 0},d.createElement(bu.Provider,{value:p},h))))}),i0=d.forwardRef((e,t)=>{let{alwaysRender:n,...r}=e,o=d.useRef(null),a=jt(s=>!s.search);return!n&&!a?null:d.createElement(te.div,{ref:Ct(o,t),...r,"cmdk-separator":"",role:"separator"})}),c0=d.forwardRef((e,t)=>{let{onValueChange:n,...r}=e,o=e.value!=null,a=Ka(),s=jt(u=>u.search),i=jt(u=>u.selectedItemId),l=dr();return d.useEffect(()=>{e.value!=null&&a.setState("search",e.value)},[e.value]),d.createElement(te.input,{ref:t,...r,"cmdk-input":"",autoComplete:"off",autoCorrect:"off",spellCheck:!1,"aria-autocomplete":"list",role:"combobox","aria-expanded":!0,"aria-controls":l.listId,"aria-labelledby":l.labelId,"aria-activedescendant":i,id:l.inputId,type:"text",value:o?e.value:s,onChange:u=>{o||a.setState("search",u.target.value),n==null||n(u.target.value)}})}),l0=d.forwardRef((e,t)=>{let{children:n,label:r="Suggestions",...o}=e,a=d.useRef(null),s=d.useRef(null),i=jt(u=>u.selectedItemId),l=dr();return d.useEffect(()=>{if(s.current&&a.current){let u=s.current,m=a.current,c,p=new ResizeObserver(()=>{c=requestAnimationFrame(()=>{let h=u.offsetHeight;m.style.setProperty("--cmdk-list-height",h.toFixed(1)+"px")})});return p.observe(u),()=>{cancelAnimationFrame(c),p.unobserve(u)}}},[]),d.createElement(te.div,{ref:Ct(a,t),...o,"cmdk-list":"",role:"listbox",tabIndex:-1,"aria-activedescendant":i,"aria-label":r,id:l.listId},fo(e,u=>d.createElement("div",{ref:Ct(s,l.listInnerRef),"cmdk-list-sizer":""},u)))}),u0=d.forwardRef((e,t)=>{let{open:n,onOpenChange:r,overlayClassName:o,contentClassName:a,container:s,...i}=e;return d.createElement(za,{open:n,onOpenChange:r},d.createElement(Ga,{container:s},d.createElement(lo,{"cmdk-overlay":"",className:o}),d.createElement(uo,{"aria-label":e.label,"cmdk-dialog":"",className:a},d.createElement(wu,{ref:t,...i}))))}),d0=d.forwardRef((e,t)=>jt(n=>n.filtered.count===0)?d.createElement(te.div,{ref:t,...e,"cmdk-empty":"",role:"presentation"}):null),f0=d.forwardRef((e,t)=>{let{progress:n,children:r,label:o="Loading...",...a}=e;return d.createElement(te.div,{ref:t,...a,"cmdk-loading":"",role:"progressbar","aria-valuenow":n,"aria-valuemin":0,"aria-valuemax":100,"aria-label":o},fo(e,s=>d.createElement("div",{"aria-hidden":!0},s)))}),Ae=Object.assign(wu,{List:l0,Item:a0,Input:c0,Group:s0,Separator:i0,Dialog:u0,Empty:d0,Loading:f0});function m0(e,t){let n=e.nextElementSibling;for(;n;){if(n.matches(t))return n;n=n.nextElementSibling}}function p0(e,t){let n=e.previousElementSibling;for(;n;){if(n.matches(t))return n;n=n.previousElementSibling}}function xu(e){let t=d.useRef(e);return en(()=>{t.current=e}),t}var en=typeof window>"u"?d.useEffect:d.useLayoutEffect;function pn(e){let t=d.useRef();return t.current===void 0&&(t.current=e()),t}function jt(e){let t=Ka(),n=()=>e(t.snapshot());return d.useSyncExternalStore(t.subscribe,n,n)}function Su(e,t,n,r=[]){let o=d.useRef(),a=dr();return en(()=>{var s;let i=(()=>{var u;for(let m of n){if(typeof m=="string")return m.trim();if(typeof m=="object"&&"current"in m)return m.current?(u=m.current.textContent)==null?void 0:u.trim():o.current}})(),l=r.map(u=>u.trim());a.value(e,i,l),(s=t.current)==null||s.setAttribute(mn,i),o.current=i}),o}var h0=()=>{let[e,t]=d.useState(),n=pn(()=>new Map);return en(()=>{n.current.forEach(r=>r()),n.current=new Map},[e]),(r,o)=>{n.current.set(r,o),t({})}};function g0(e){let t=e.type;return typeof t=="function"?t(e.props):"render"in t?t.render(e.props):e}function fo({asChild:e,children:t},n){return e&&d.isValidElement(t)?d.cloneElement(g0(t),{ref:t.ref},n(t.props.children)):n(t)}var v0={position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0"};const y0=za,b0=hu,w0=Ga,x0=Va,Cu=d.forwardRef(({className:e,...t},n)=>f.jsx(lo,{ref:n,className:q("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t}));Cu.displayName=lo.displayName;const Mu=d.forwardRef(({className:e,children:t,...n},r)=>f.jsxs(w0,{children:[f.jsx(Cu,{}),f.jsxs(uo,{ref:r,className:q("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg",e),...n,children:[t,f.jsxs(Va,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground",children:[f.jsx(En,{className:"h-4 w-4"}),f.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));Mu.displayName=uo.displayName;const Eu=({className:e,...t})=>f.jsx("div",{className:q("flex flex-col space-y-1.5 text-center sm:text-left",e),...t});Eu.displayName="DialogHeader";const ku=({className:e,...t})=>f.jsx("div",{className:q("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...t});ku.displayName="DialogFooter";const Nu=d.forwardRef(({className:e,...t},n)=>f.jsx(Ua,{ref:n,className:q("text-lg font-semibold leading-none tracking-tight",e),...t}));Nu.displayName=Ua.displayName;const Du=d.forwardRef(({className:e,...t},n)=>f.jsx(qa,{ref:n,className:q("text-sm text-muted-foreground",e),...t}));Du.displayName=qa.displayName;const S0=d.forwardRef(({className:e,...t},n)=>f.jsx(Ae,{ref:n,className:q("flex h-full w-full flex-col overflow-hidden rounded-md bg-popover text-popover-foreground",e),...t}));S0.displayName=Ae.displayName;const Ru=d.forwardRef(({className:e,...t},n)=>f.jsxs("div",{className:"flex items-center h-auto px-3","cmdk-input-wrapper":"",children:[f.jsx(zi,{strokeWidth:1.25,className:"mr-2 h-4 w-4 shrink-0"}),f.jsx(Ae.Input,{ref:n,className:q("flex h-11 w-full rounded-md bg-transparent py-3 text-sm outline-none placeholder:text-gray-400 disabled:cursor-not-allowed disabled:opacity-50",e),...t})]}));Ru.displayName=Ae.Input.displayName;const Tu=d.forwardRef(({className:e,...t},n)=>f.jsx(Ae.List,{ref:n,className:q("max-h-[300px] overflow-y-auto overflow-x-hidden",e),...t}));Tu.displayName=Ae.List.displayName;const C0=d.forwardRef((e,t)=>f.jsx(Ae.Empty,{ref:t,className:"py-6 text-center text-sm",...e}));C0.displayName=Ae.Empty.displayName;const Ou=d.forwardRef(({className:e,...t},n)=>f.jsx(Ae.Group,{ref:n,className:q("overflow-hidden p-1 text-foreground [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground",e),...t}));Ou.displayName=Ae.Group.displayName;const M0=d.forwardRef(({className:e,...t},n)=>f.jsx(Ae.Separator,{ref:n,className:q("-mx-1 h-px bg-border",e),...t}));M0.displayName=Ae.Separator.displayName;const _u=d.forwardRef(({className:e,...t},n)=>f.jsx(Ae.Item,{ref:n,className:q("relative flex cursor-default gap-2 select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none data-[disabled=true]:pointer-events-none data-[selected='true']:bg-accent data-[selected=true]:text-accent-foreground data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",e),...t}));_u.displayName=Ae.Item.displayName;function E0({className:e,...t}){return f.jsx("div",{className:q("animate-pulse rounded-md bg-muted",e),...t})}function k0(e="medium",t="white"){const n={small:"text-sm py-1 px-2 h-8",medium:"text-base py-2 px-3 h-10",large:"text-lg py-3 px-4 h-12"},r={white:"bg-background text-foreground border-border",grey:"bg-muted text-muted-foreground border-border"};return{sizeClasses:n[e],variantClasses:r[t],combined:`${n[e]} ${r[t]}`}}const N0=({options:e,placeholder:t,emptyMessage:n,value:r,onValueChange:o,disabled:a,isLoading:s=!1,className:i,size:l,variant:u})=>{const{variantClasses:m,combined:c}=k0(l,u),p=b.useRef(null),[h,v]=b.useState(!1),[g,y]=b.useState(r),[w,x]=b.useState((r==null?void 0:r.label)||""),S=b.useCallback(N=>{const M=p.current;if(M){if(h||v(!0),N.key==="Enter"&&M.value!==""){const D=e.find(L=>L.label===M.value);D&&(y(D),o==null||o(D))}N.key==="Escape"&&M.blur()}},[h,e,o]),k=b.useCallback(()=>{v(!1),x((g==null?void 0:g.label)||"")},[g]),C=b.useCallback(N=>{x(N.label),y(N),o==null||o(N),setTimeout(()=>{var M;(M=p==null?void 0:p.current)==null||M.blur()},0)},[o]);return f.jsxs(Ae,{onKeyDown:S,children:[f.jsxs("div",{className:q("rounded-full border bg-gray-100",m,i),children:[" ",f.jsx(Ru,{ref:p,value:w,onValueChange:s?void 0:x,onBlur:k,onFocus:()=>v(!0),placeholder:t,disabled:a,className:c})]}),f.jsx("div",{className:"relative mt-1",children:f.jsx("div",{className:q("animate-in fade-in-0 zoom-in-95 absolute top-0 z-10 w-full rounded-xl bg-white dark:bg-gray-800 outline-none",h?"block":"hidden",i),children:f.jsxs(Tu,{className:"rounded-lg ring-1 ring-slate-200 dark:ring-gray-700",children:[s?f.jsx(Ae.Loading,{children:f.jsx("div",{className:"p-1",children:f.jsx(E0,{className:"h-8 w-full"})})}):null,e.length>0&&!s?f.jsx(Ou,{children:e.map(N=>{const M=(g==null?void 0:g.value)===N.value;return f.jsxs(_u,{value:N.label,onMouseDown:D=>{D.preventDefault(),D.stopPropagation()},onSelect:()=>C(N),className:q("flex w-full items-center gap-2 dark:text-white",M?null:"pl-8"),children:[M?f.jsx(Jn,{className:"w-4"}):null,N.label]},N.value)})}):null,s?null:f.jsx(Ae.Empty,{className:"select-none rounded-sm px-2 py-3 text-center text-sm dark:text-gray-400",children:n})]})})})]})};function D0({title:e,children:t,className:n}){return f.jsxs("section",{className:q("space-y-6",n),children:[f.jsx("div",{className:"border-b border-gray-200 pb-3",children:f.jsx("h2",{className:"text-sm font-semibold text-gray-900 tracking-wide uppercase",children:e})}),t]})}const Pu=b.forwardRef(({className:e,type:t,label:n,helperText:r,startAdornment:o,endAdornment:a,...s},i)=>f.jsxs("div",{className:"flex flex-col",children:[n&&f.jsx("label",{className:"mb-1 text-sm text-gray-700",children:n}),f.jsxs("div",{className:q("flex items-center h-10 w-full rounded-md border border-input bg-background text-sm ring-offset-background disabled:cursor-not-allowed disabled:opacity-50",e),children:[o&&f.jsx("span",{className:"px-3 text-sm text-muted-foreground",children:o}),f.jsx("input",{type:t,className:q("flex-1 px-3 py-2 placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-primary focus:ring-offset-2 disabled:opacity-50"),ref:i,...s}),a&&f.jsx("span",{className:"px-3 text-sm text-muted-foreground",children:a})]}),r&&f.jsx("span",{className:"mt-1 text-xs text-muted-foreground",children:r})]}));Pu.displayName="CurrencyInput";const Au=b.memo(({className:e="",variant:t="default",children:n,...r})=>{const o={default:"border-transparent bg-primary text-primary-foreground hover:bg-primary/80",secondary:"border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",destructive:"border-transparent bg-destructive text-destructive-foreground hover:bg-destructive/80",outline:"text-foreground border-border bg-background hover:bg-accent hover:text-accent-foreground"};return f.jsx("div",{className:`inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 ${o[t]} ${e}`,...r,children:n})});Au.displayName="Badge";const R0={small:"h-8 text-xs px-2",medium:"h-10 text-sm px-3",large:"h-12 text-base px-4"},T0={outlined:"border border-input",filled:"border-0 bg-accent",standard:"border-0 border-b border-input rounded-none"},O0=e=>typeof e=="string"?e:(e==null?void 0:e.label)||"",_0=e=>typeof e=="string"?e:(e==null?void 0:e.value)||e,P0=(e,t,n)=>n(e)===n(t),A0=(e,t,n)=>{if(!t)return e;const r=t.toLowerCase();return e.filter(o=>n(o).toLowerCase().includes(r))},Iu=e=>{const{option:t,index:n,isSelected:r,isHighlighted:o,onSelect:a,getOptionLabel:s,renderOption:i}=e,l=b.useCallback(()=>{a(t)},[t,a]);return f.jsx("div",{onClick:l,className:`
158
+ px-3 py-2 cursor-pointer flex items-center justify-between
159
+ text-sm transition-colors mb-[0.4vh]
160
+ ${o?"bg-accent text-accent-foreground":""}
161
+ ${r?"bg-primary/10":""}
162
+ hover:bg-accent hover:text-accent-foreground
163
+ `,children:i?i(t,n):f.jsxs(f.Fragment,{children:[f.jsx("span",{children:s(t)}),r&&f.jsx(Jn,{className:"h-4 w-4 text-primary"})]})})};Iu.displayName="AutocompleteOption";const ju=e=>{const{tag:t,index:n,getOptionLabel:r,onRemove:o}=e,a=b.useCallback(()=>{o(t)},[t,o]);return f.jsxs(Au,{variant:"secondary",className:"text-xs",children:[r(t),f.jsx("button",{type:"button",onClick:a,className:"ml-1 hover:bg-secondary-foreground/20 rounded-full p-0.5",children:f.jsx(En,{className:"h-3 w-3"})})]},n)};ju.displayName="AutocompleteTag";const I0=({options:e=[],value:t=null,onChange:n,onInputChange:r,placeholder:o="Search...",multiple:a=!1,freeSolo:s=!1,disabled:i=!1,loading:l=!1,size:u="medium",variant:m="outlined",label:c="",helperText:p="",error:h=!1,required:v=!1,fullWidth:g=!0,clearable:y=!0,disableCloseOnSelect:w=!1,filterOptions:x,getOptionLabel:S=O0,getOptionValue:k=_0,isOptionEqualToValue:C,renderOption:N,renderTags:M,noOptionsText:D="No options",emptyMessage:L,className:B="",popupClassName:F="",...V})=>{const[$,I]=b.useState(!1),[_,R]=b.useState(""),[P,E]=b.useState(-1),O=b.useRef(null),Y=b.useRef(null),G=b.useRef(null),T=b.useId(),A=b.useMemo(()=>C||((ie,pe)=>P0(ie,pe,k)),[C,k]),W=b.useMemo(()=>{let ie=e;return a&&Array.isArray(t)&&(ie=e.filter(pe=>!t.some(Se=>A(pe,Se)))),x?x(ie,{inputValue:_}):A0(ie,_,S)},[e,t,_,x,S,a,A]),H=b.useCallback(ie=>{const pe=ie.target.value;R(pe),r==null||r(ie,pe),!$&&pe&&I(!0)},[$,r]),U=b.useCallback(ie=>{if(a){const pe=Array.isArray(t)?t:[],Se=pe.some(Be=>A(ie,Be));let je;Se?je=pe.filter(Be=>!A(ie,Be)):je=[...pe,ie],n==null||n(null,je),R(""),setTimeout(()=>{var Be;(Be=O.current)==null||Be.focus(),I(!0)},0)}else n==null||n(null,ie),R(S(ie)),I(!1);E(-1)},[a,t,A,n,w,S]),j=b.useCallback(ie=>{if(a&&Array.isArray(t)){const pe=t.filter(Se=>!A(ie,Se));n==null||n(null,pe)}},[a,t,A,n]),Z=b.useCallback(ie=>{ie.stopPropagation(),n==null||n(null,a?[]:null),R(""),setTimeout(()=>{O.current&&(O.current.value="",O.current.focus())},0),I(!1)},[n,a]),X=b.useCallback(ie=>{if(!$&&(ie.key==="ArrowDown"||ie.key==="ArrowUp")){I(!0);return}if($)switch(ie.key){case"ArrowDown":ie.preventDefault(),E(pe=>pe<W.length-1?pe+1:0);break;case"ArrowUp":ie.preventDefault(),E(pe=>pe>0?pe-1:W.length-1);break;case"Enter":ie.preventDefault(),P>=0&&W[P]?U(W[P]):s&&_&&U(_);break;case"Escape":I(!1),E(-1);break;case"Tab":I(!1);break}},[$,W,P,U,s,_]),Q=b.useCallback(()=>{I(!$)},[$]),le=b.useCallback(()=>{I(!0)},[]);b.useEffect(()=>{const ie=pe=>{G.current&&!G.current.contains(pe.target)&&I(!1)};return document.addEventListener("mousedown",ie),()=>document.removeEventListener("mousedown",ie)},[]),b.useEffect(()=>{if($&&P>=0&&Y.current){const ie=Y.current.children[P];ie&&ie.scrollIntoView({block:"nearest"})}},[P,$]);const de=b.useMemo(()=>!a||!Array.isArray(t)||t.length===0?null:M?M(t,j):f.jsx("div",{className:"flex flex-wrap gap-1 mb-1",children:t.map((ie,pe)=>f.jsx(ju,{tag:ie,index:pe,getOptionLabel:S,onRemove:j},pe))}),[a,t,M,j,S]),xe=b.useMemo(()=>a?Array.isArray(t)&&t.length>0:t!=null,[a,t]),re=y&&xe&&!i,ze=b.useMemo(()=>`
164
+ relative flex items-center rounded-md
165
+ ${T0[m]}
166
+ ${R0[u]}
167
+ ${h?"border-destructive focus-within:ring-destructive":""}
168
+ ${i?"opacity-50 cursor-not-allowed":"cursor-text"}
169
+ focus-within:ring-2 focus-within:ring-ring focus-within:ring-offset-2
170
+ transition-colors
171
+ `,[m,u,h,i]),We=L??D;return f.jsxs("div",{className:`relative ${g?"w-full":"w-auto"} ${B}`,ref:G,children:[c&&f.jsxs("label",{htmlFor:T,className:`block text-sm font-medium mb-1 ${h?"text-destructive":"text-foreground"}`,children:[c,v&&f.jsx("span",{className:"text-destructive ml-1",children:"*"})]}),f.jsxs("div",{className:"relative",children:[de,f.jsxs("div",{className:ze,children:[f.jsx(Mn,{id:T,ref:O,value:_,onChange:H,onKeyDown:X,onFocus:le,placeholder:o,disabled:i,className:"border-0 shadow-none focus-visible:ring-0 focus-visible:ring-offset-0 bg-transparent",...V}),f.jsxs("div",{className:"flex items-center gap-1 ml-auto",children:[l&&f.jsx("div",{className:"animate-spin rounded-full h-4 w-4 border-2 border-muted-foreground border-t-transparent"}),re&&f.jsx("button",{type:"button",onClick:Z,className:"p-1 hover:bg-accent rounded-sm transition-colors",tabIndex:-1,children:f.jsx(En,{className:"h-4 w-4 text-muted-foreground"})}),f.jsx("button",{type:"button",onClick:Q,className:"p-1 hover:bg-accent rounded-sm transition-colors",tabIndex:-1,children:f.jsx(Vr,{className:`h-4 w-4 text-muted-foreground transition-transform ${$?"rotate-180":""}`})})]})]}),$&&f.jsx("div",{className:`
172
+ absolute top-full left-0 right-0 z-50 mt-1
173
+ bg-popover border border-border rounded-md shadow-lg
174
+ max-h-60 overflow-auto
175
+ ${F}
176
+ `,ref:Y,children:W.length===0?f.jsx("div",{className:"p-3 text-sm text-muted-foreground text-center",children:We}):W.map((ie,pe)=>{const Se=a?Array.isArray(t)&&t.some(Be=>A(ie,Be)):A(ie,t),je=pe===P;return f.jsx(Iu,{option:ie,index:pe,isSelected:Se,isHighlighted:je,onSelect:U,getOptionLabel:S,renderOption:N},pe)})})]}),p&&f.jsx("p",{className:`mt-1 text-xs ${h?"text-destructive":"text-muted-foreground"}`,children:p})]})};var mo="Collapsible",[j0,kM]=Ye(mo),[$0,Xa]=j0(mo),$u=d.forwardRef((e,t)=>{const{__scopeCollapsible:n,open:r,defaultOpen:o,disabled:a,onOpenChange:s,...i}=e,[l,u]=tt({prop:r,defaultProp:o??!1,onChange:s,caller:mo});return f.jsx($0,{scope:n,disabled:a,contentId:ke(),open:l,onOpenToggle:d.useCallback(()=>u(m=>!m),[u]),children:f.jsx(te.div,{"data-state":Qa(l),"data-disabled":a?"":void 0,...i,ref:t})})});$u.displayName=mo;var Lu="CollapsibleTrigger",Fu=d.forwardRef((e,t)=>{const{__scopeCollapsible:n,...r}=e,o=Xa(Lu,n);return f.jsx(te.button,{type:"button","aria-controls":o.contentId,"aria-expanded":o.open||!1,"data-state":Qa(o.open),"data-disabled":o.disabled?"":void 0,disabled:o.disabled,...r,ref:t,onClick:K(e.onClick,o.onOpenToggle)})});Fu.displayName=Lu;var Za="CollapsibleContent",Wu=d.forwardRef((e,t)=>{const{forceMount:n,...r}=e,o=Xa(Za,e.__scopeCollapsible);return f.jsx(He,{present:n||o.open,children:({present:a})=>f.jsx(L0,{...r,ref:t,present:a})})});Wu.displayName=Za;var L0=d.forwardRef((e,t)=>{const{__scopeCollapsible:n,present:r,children:o,...a}=e,s=Xa(Za,n),[i,l]=d.useState(r),u=d.useRef(null),m=he(t,u),c=d.useRef(0),p=c.current,h=d.useRef(0),v=h.current,g=s.open||i,y=d.useRef(g),w=d.useRef(void 0);return d.useEffect(()=>{const x=requestAnimationFrame(()=>y.current=!1);return()=>cancelAnimationFrame(x)},[]),De(()=>{const x=u.current;if(x){w.current=w.current||{transitionDuration:x.style.transitionDuration,animationName:x.style.animationName},x.style.transitionDuration="0s",x.style.animationName="none";const S=x.getBoundingClientRect();c.current=S.height,h.current=S.width,y.current||(x.style.transitionDuration=w.current.transitionDuration,x.style.animationName=w.current.animationName),l(r)}},[s.open,r]),f.jsx(te.div,{"data-state":Qa(s.open),"data-disabled":s.disabled?"":void 0,id:s.contentId,hidden:!g,...a,ref:m,style:{"--radix-collapsible-content-height":p?`${p}px`:void 0,"--radix-collapsible-content-width":v?`${v}px`:void 0,...e.style},children:g&&o})});function Qa(e){return e?"open":"closed"}var F0=$u,W0=Fu,B0=Wu;function Y0({title:e,content:t,defaultOpen:n=!1}){const[r,o]=d.useState(n);return f.jsxs(F0,{open:r,onOpenChange:o,className:"rounded-md border p-4 shadow-sm w-full max-w-md",children:[f.jsxs("div",{className:"flex items-center justify-between",children:[f.jsx("h3",{className:"text-lg font-medium",children:e}),f.jsx(W0,{asChild:!0,children:f.jsx("button",{className:q("transition-transform duration-200",r?"rotate-180":"rotate-0"),children:f.jsx(Vr,{className:"h-5 w-5"})})})]}),f.jsx(B0,{className:"mt-4 CollapsibleContent data-[state=closed]:animate-collapsible-up data-[state=open]:animate-collapsible-down",children:f.jsx("div",{className:"text-sm text-muted-foreground",children:t})})]})}const H0=Sa("relative w-full rounded-lg border p-4 [&>svg~*]:pl-7 [&>svg+div]:translate-y-[-3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg]:text-foreground",{variants:{variant:{default:"bg-background text-foreground",destructive:"border-destructive/50 text-destructive dark:border-destructive [&>svg]:text-destructive"}},defaultVariants:{variant:"default"}}),Bu=d.forwardRef(({className:e,variant:t,...n},r)=>f.jsx("div",{ref:r,role:"alert",className:q(H0({variant:t}),e),...n}));Bu.displayName="Alert";const z0=d.forwardRef(({className:e,...t},n)=>f.jsx("h5",{ref:n,className:q("mb-1 font-medium leading-none tracking-tight",e),...t}));z0.displayName="AlertTitle";const G0=d.forwardRef(({className:e,...t},n)=>f.jsx("p",{ref:n,className:q("text-sm [&_p]:leading-relaxed",e),...t}));G0.displayName="AlertDescription";var Er={exports:{}},Bo={};/**
177
+ * @license React
178
+ * use-sync-external-store-shim.production.js
179
+ *
180
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
181
+ *
182
+ * This source code is licensed under the MIT license found in the
183
+ * LICENSE file in the root directory of this source tree.
184
+ */var di;function U0(){if(di)return Bo;di=1;var e=b;function t(c,p){return c===p&&(c!==0||1/c===1/p)||c!==c&&p!==p}var n=typeof Object.is=="function"?Object.is:t,r=e.useState,o=e.useEffect,a=e.useLayoutEffect,s=e.useDebugValue;function i(c,p){var h=p(),v=r({inst:{value:h,getSnapshot:p}}),g=v[0].inst,y=v[1];return a(function(){g.value=h,g.getSnapshot=p,l(g)&&y({inst:g})},[c,h,p]),o(function(){return l(g)&&y({inst:g}),c(function(){l(g)&&y({inst:g})})},[c]),s(h),h}function l(c){var p=c.getSnapshot;c=c.value;try{var h=p();return!n(c,h)}catch{return!0}}function u(c,p){return p()}var m=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?u:i;return Bo.useSyncExternalStore=e.useSyncExternalStore!==void 0?e.useSyncExternalStore:m,Bo}var Yo={};/**
185
+ * @license React
186
+ * use-sync-external-store-shim.development.js
187
+ *
188
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
189
+ *
190
+ * This source code is licensed under the MIT license found in the
191
+ * LICENSE file in the root directory of this source tree.
192
+ */var fi;function q0(){return fi||(fi=1,process.env.NODE_ENV!=="production"&&function(){function e(h,v){return h===v&&(h!==0||1/h===1/v)||h!==h&&v!==v}function t(h,v){m||o.startTransition===void 0||(m=!0,console.error("You are using an outdated, pre-release alpha of React 18 that does not support useSyncExternalStore. The use-sync-external-store shim will not work correctly. Upgrade to a newer pre-release."));var g=v();if(!c){var y=v();a(g,y)||(console.error("The result of getSnapshot should be cached to avoid an infinite loop"),c=!0)}y=s({inst:{value:g,getSnapshot:v}});var w=y[0].inst,x=y[1];return l(function(){w.value=g,w.getSnapshot=v,n(w)&&x({inst:w})},[h,g,v]),i(function(){return n(w)&&x({inst:w}),h(function(){n(w)&&x({inst:w})})},[h]),u(g),g}function n(h){var v=h.getSnapshot;h=h.value;try{var g=v();return!a(h,g)}catch{return!0}}function r(h,v){return v()}typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var o=b,a=typeof Object.is=="function"?Object.is:e,s=o.useState,i=o.useEffect,l=o.useLayoutEffect,u=o.useDebugValue,m=!1,c=!1,p=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?r:t;Yo.useSyncExternalStore=o.useSyncExternalStore!==void 0?o.useSyncExternalStore:p,typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())}()),Yo}var mi;function V0(){return mi||(mi=1,process.env.NODE_ENV==="production"?Er.exports=U0():Er.exports=q0()),Er.exports}var K0=V0();function X0(){return K0.useSyncExternalStore(Z0,()=>!0,()=>!1)}function Z0(){return()=>{}}var Ja="Avatar",[Q0,NM]=Ye(Ja),[J0,Yu]=Q0(Ja),Hu=d.forwardRef((e,t)=>{const{__scopeAvatar:n,...r}=e,[o,a]=d.useState("idle");return f.jsx(J0,{scope:n,imageLoadingStatus:o,onImageLoadingStatusChange:a,children:f.jsx(te.span,{...r,ref:t})})});Hu.displayName=Ja;var zu="AvatarImage",Gu=d.forwardRef((e,t)=>{const{__scopeAvatar:n,src:r,onLoadingStatusChange:o=()=>{},...a}=e,s=Yu(zu,n),i=eS(r,a),l=et(u=>{o(u),s.onImageLoadingStatusChange(u)});return De(()=>{i!=="idle"&&l(i)},[i,l]),i==="loaded"?f.jsx(te.img,{...a,ref:t,src:r}):null});Gu.displayName=zu;var Uu="AvatarFallback",qu=d.forwardRef((e,t)=>{const{__scopeAvatar:n,delayMs:r,...o}=e,a=Yu(Uu,n),[s,i]=d.useState(r===void 0);return d.useEffect(()=>{if(r!==void 0){const l=window.setTimeout(()=>i(!0),r);return()=>window.clearTimeout(l)}},[r]),s&&a.imageLoadingStatus!=="loaded"?f.jsx(te.span,{...o,ref:t}):null});qu.displayName=Uu;function pi(e,t){return e?t?(e.src!==t&&(e.src=t),e.complete&&e.naturalWidth>0?"loaded":"loading"):"error":"idle"}function eS(e,{referrerPolicy:t,crossOrigin:n}){const r=X0(),o=d.useRef(null),a=r?(o.current||(o.current=new window.Image),o.current):null,[s,i]=d.useState(()=>pi(a,e));return De(()=>{i(pi(a,e))},[a,e]),De(()=>{const l=c=>()=>{i(c)};if(!a)return;const u=l("loaded"),m=l("error");return a.addEventListener("load",u),a.addEventListener("error",m),t&&(a.referrerPolicy=t),typeof n=="string"&&(a.crossOrigin=n),()=>{a.removeEventListener("load",u),a.removeEventListener("error",m)}},[a,n,t]),s}var Vu=Hu,Ku=Gu,Xu=qu;const Zu=d.forwardRef(({className:e,...t},n)=>f.jsx(Vu,{ref:n,className:q("relative flex h-10 w-10 shrink-0 overflow-hidden rounded-full",e),...t}));Zu.displayName=Vu.displayName;const Qu=d.forwardRef(({className:e,...t},n)=>f.jsx(Ku,{ref:n,className:q("aspect-square h-full w-full",e),...t}));Qu.displayName=Ku.displayName;const Ju=d.forwardRef(({className:e,...t},n)=>f.jsx(Xu,{ref:n,className:q("flex h-full w-full items-center justify-center rounded-full bg-muted",e),...t}));Ju.displayName=Xu.displayName;var po="Checkbox",[tS,DM]=Ye(po),[nS,es]=tS(po);function rS(e){const{__scopeCheckbox:t,checked:n,children:r,defaultChecked:o,disabled:a,form:s,name:i,onCheckedChange:l,required:u,value:m="on",internal_do_not_use_render:c}=e,[p,h]=tt({prop:n,defaultProp:o??!1,onChange:l,caller:po}),[v,g]=d.useState(null),[y,w]=d.useState(null),x=d.useRef(!1),S=v?!!s||!!v.closest("form"):!0,k={checked:p,disabled:a,setChecked:h,control:v,setControl:g,name:i,form:s,value:m,hasConsumerStoppedPropagationRef:x,required:u,defaultChecked:_t(o)?!1:o,isFormControl:S,bubbleInput:y,setBubbleInput:w};return f.jsx(nS,{scope:t,...k,children:oS(c)?c(k):r})}var ed="CheckboxTrigger",td=d.forwardRef(({__scopeCheckbox:e,onKeyDown:t,onClick:n,...r},o)=>{const{control:a,value:s,disabled:i,checked:l,required:u,setControl:m,setChecked:c,hasConsumerStoppedPropagationRef:p,isFormControl:h,bubbleInput:v}=es(ed,e),g=he(o,m),y=d.useRef(l);return d.useEffect(()=>{const w=a==null?void 0:a.form;if(w){const x=()=>c(y.current);return w.addEventListener("reset",x),()=>w.removeEventListener("reset",x)}},[a,c]),f.jsx(te.button,{type:"button",role:"checkbox","aria-checked":_t(l)?"mixed":l,"aria-required":u,"data-state":sd(l),"data-disabled":i?"":void 0,disabled:i,value:s,...r,ref:g,onKeyDown:K(t,w=>{w.key==="Enter"&&w.preventDefault()}),onClick:K(n,w=>{c(x=>_t(x)?!0:!x),v&&h&&(p.current=w.isPropagationStopped(),p.current||w.stopPropagation())})})});td.displayName=ed;var ts=d.forwardRef((e,t)=>{const{__scopeCheckbox:n,name:r,checked:o,defaultChecked:a,required:s,disabled:i,value:l,onCheckedChange:u,form:m,...c}=e;return f.jsx(rS,{__scopeCheckbox:n,checked:o,defaultChecked:a,disabled:i,required:s,onCheckedChange:u,name:r,form:m,value:l,internal_do_not_use_render:({isFormControl:p})=>f.jsxs(f.Fragment,{children:[f.jsx(td,{...c,ref:t,__scopeCheckbox:n}),p&&f.jsx(ad,{__scopeCheckbox:n})]})})});ts.displayName=po;var nd="CheckboxIndicator",rd=d.forwardRef((e,t)=>{const{__scopeCheckbox:n,forceMount:r,...o}=e,a=es(nd,n);return f.jsx(He,{present:r||_t(a.checked)||a.checked===!0,children:f.jsx(te.span,{"data-state":sd(a.checked),"data-disabled":a.disabled?"":void 0,...o,ref:t,style:{pointerEvents:"none",...e.style}})})});rd.displayName=nd;var od="CheckboxBubbleInput",ad=d.forwardRef(({__scopeCheckbox:e,...t},n)=>{const{control:r,hasConsumerStoppedPropagationRef:o,checked:a,defaultChecked:s,required:i,disabled:l,name:u,value:m,form:c,bubbleInput:p,setBubbleInput:h}=es(od,e),v=he(n,h),g=$a(a),y=Oa(r);d.useEffect(()=>{const x=p;if(!x)return;const S=window.HTMLInputElement.prototype,C=Object.getOwnPropertyDescriptor(S,"checked").set,N=!o.current;if(g!==a&&C){const M=new Event("click",{bubbles:N});x.indeterminate=_t(a),C.call(x,_t(a)?!1:a),x.dispatchEvent(M)}},[p,g,a,o]);const w=d.useRef(_t(a)?!1:a);return f.jsx(te.input,{type:"checkbox","aria-hidden":!0,defaultChecked:s??w.current,required:i,disabled:l,name:u,value:m,form:c,...t,tabIndex:-1,ref:v,style:{...t.style,...y,position:"absolute",pointerEvents:"none",opacity:0,margin:0,transform:"translateX(-100%)"}})});ad.displayName=od;function oS(e){return typeof e=="function"}function _t(e){return e==="indeterminate"}function sd(e){return _t(e)?"indeterminate":e?"checked":"unchecked"}const id=d.forwardRef(({className:e,...t},n)=>f.jsx(ts,{ref:n,className:q("peer h-4 w-4 shrink-0 rounded-sm border border-customBlue ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-customBlue data-[state=checked]:text-primary-foreground",e),...t,children:f.jsx(rd,{className:q("flex items-center justify-center text-current"),children:f.jsx(Jn,{className:"h-4 w-4"})})}));id.displayName=ts.displayName;function aS(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 cd=b.createContext({drawerRef:{current:null},overlayRef:{current:null},onPress:()=>{},onRelease:()=>{},onDrag:()=>{},onNestedDrag:()=>{},onNestedOpenChange:()=>{},onNestedRelease:()=>{},openProp:void 0,dismissible:!1,isOpen:!1,isDragging:!1,keyboardIsOpen:{current:!1},snapPointsOffset:null,snapPoints:null,handleOnly:!1,modal:!1,shouldFade:!1,activeSnapPoint:null,onOpenChange:()=>{},setActiveSnapPoint:()=>{},closeDrawer:()=>{},direction:"bottom",shouldAnimate:{current:!0},shouldScaleBackground:!1,setBackgroundColorOnScale:!0,noBodyStyles:!1,container:null,autoFocus:!1}),fr=()=>{const e=b.useContext(cd);if(!e)throw new Error("useDrawerContext must be used within a Drawer.Root");return e};aS(`[data-vaul-drawer]{touch-action:none;will-change:transform;transition:transform .5s cubic-bezier(.32, .72, 0, 1);animation-duration:.5s;animation-timing-function:cubic-bezier(0.32,0.72,0,1)}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=bottom][data-state=open]{animation-name:slideFromBottom}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=bottom][data-state=closed]{animation-name:slideToBottom}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=top][data-state=open]{animation-name:slideFromTop}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=top][data-state=closed]{animation-name:slideToTop}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=left][data-state=open]{animation-name:slideFromLeft}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=left][data-state=closed]{animation-name:slideToLeft}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=right][data-state=open]{animation-name:slideFromRight}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=right][data-state=closed]{animation-name:slideToRight}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=bottom]{transform:translate3d(0,var(--initial-transform,100%),0)}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=top]{transform:translate3d(0,calc(var(--initial-transform,100%) * -1),0)}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=left]{transform:translate3d(calc(var(--initial-transform,100%) * -1),0,0)}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=right]{transform:translate3d(var(--initial-transform,100%),0,0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=top]{transform:translate3d(0,var(--snap-point-height,0),0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=bottom]{transform:translate3d(0,var(--snap-point-height,0),0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=left]{transform:translate3d(var(--snap-point-height,0),0,0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=right]{transform:translate3d(var(--snap-point-height,0),0,0)}[data-vaul-overlay][data-vaul-snap-points=false]{animation-duration:.5s;animation-timing-function:cubic-bezier(0.32,0.72,0,1)}[data-vaul-overlay][data-vaul-snap-points=false][data-state=open]{animation-name:fadeIn}[data-vaul-overlay][data-state=closed]{animation-name:fadeOut}[data-vaul-animate=false]{animation:none!important}[data-vaul-overlay][data-vaul-snap-points=true]{opacity:0;transition:opacity .5s cubic-bezier(.32, .72, 0, 1)}[data-vaul-overlay][data-vaul-snap-points=true]{opacity:1}[data-vaul-drawer]:not([data-vaul-custom-container=true])::after{content:'';position:absolute;background:inherit;background-color:inherit}[data-vaul-drawer][data-vaul-drawer-direction=top]::after{top:initial;bottom:100%;left:0;right:0;height:200%}[data-vaul-drawer][data-vaul-drawer-direction=bottom]::after{top:100%;bottom:initial;left:0;right:0;height:200%}[data-vaul-drawer][data-vaul-drawer-direction=left]::after{left:initial;right:100%;top:0;bottom:0;width:200%}[data-vaul-drawer][data-vaul-drawer-direction=right]::after{left:100%;right:initial;top:0;bottom:0;width:200%}[data-vaul-overlay][data-vaul-snap-points=true]:not([data-vaul-snap-points-overlay=true]):not(
193
+ [data-state=closed]
194
+ ){opacity:0}[data-vaul-overlay][data-vaul-snap-points-overlay=true]{opacity:1}[data-vaul-handle]{display:block;position:relative;opacity:.7;background:#e2e2e4;margin-left:auto;margin-right:auto;height:5px;width:32px;border-radius:1rem;touch-action:pan-y}[data-vaul-handle]:active,[data-vaul-handle]:hover{opacity:1}[data-vaul-handle-hitarea]{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);width:max(100%,2.75rem);height:max(100%,2.75rem);touch-action:inherit}@media (hover:hover) and (pointer:fine){[data-vaul-drawer]{user-select:none}}@media (pointer:fine){[data-vaul-handle-hitarea]:{width:100%;height:100%}}@keyframes fadeIn{from{opacity:0}to{opacity:1}}@keyframes fadeOut{to{opacity:0}}@keyframes slideFromBottom{from{transform:translate3d(0,var(--initial-transform,100%),0)}to{transform:translate3d(0,0,0)}}@keyframes slideToBottom{to{transform:translate3d(0,var(--initial-transform,100%),0)}}@keyframes slideFromTop{from{transform:translate3d(0,calc(var(--initial-transform,100%) * -1),0)}to{transform:translate3d(0,0,0)}}@keyframes slideToTop{to{transform:translate3d(0,calc(var(--initial-transform,100%) * -1),0)}}@keyframes slideFromLeft{from{transform:translate3d(calc(var(--initial-transform,100%) * -1),0,0)}to{transform:translate3d(0,0,0)}}@keyframes slideToLeft{to{transform:translate3d(calc(var(--initial-transform,100%) * -1),0,0)}}@keyframes slideFromRight{from{transform:translate3d(var(--initial-transform,100%),0,0)}to{transform:translate3d(0,0,0)}}@keyframes slideToRight{to{transform:translate3d(var(--initial-transform,100%),0,0)}}`);function sS(){const e=navigator.userAgent;return typeof window<"u"&&(/Firefox/.test(e)&&/Mobile/.test(e)||/FxiOS/.test(e))}function iS(){return ns(/^Mac/)}function cS(){return ns(/^iPhone/)}function hi(){return/^((?!chrome|android).)*safari/i.test(navigator.userAgent)}function lS(){return ns(/^iPad/)||iS()&&navigator.maxTouchPoints>1}function ld(){return cS()||lS()}function ns(e){return typeof window<"u"&&window.navigator!=null?e.test(window.navigator.platform):void 0}const uS=24,dS=typeof window<"u"?b.useLayoutEffect:b.useEffect;function gi(...e){return(...t)=>{for(let n of e)typeof n=="function"&&n(...t)}}const Ho=typeof document<"u"&&window.visualViewport;function vi(e){let t=window.getComputedStyle(e);return/(auto|scroll)/.test(t.overflow+t.overflowX+t.overflowY)}function ud(e){for(vi(e)&&(e=e.parentElement);e&&!vi(e);)e=e.parentElement;return e||document.scrollingElement||document.documentElement}const fS=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]);let kr=0,zo;function mS(e={}){let{isDisabled:t}=e;dS(()=>{if(!t)return kr++,kr===1&&ld()&&(zo=pS()),()=>{kr--,kr===0&&(zo==null||zo())}},[t])}function pS(){let e,t=0,n=c=>{e=ud(c.target),!(e===document.documentElement&&e===document.body)&&(t=c.changedTouches[0].pageY)},r=c=>{if(!e||e===document.documentElement||e===document.body){c.preventDefault();return}let p=c.changedTouches[0].pageY,h=e.scrollTop,v=e.scrollHeight-e.clientHeight;v!==0&&((h<=0&&p>t||h>=v&&p<t)&&c.preventDefault(),t=p)},o=c=>{let p=c.target;pa(p)&&p!==document.activeElement&&(c.preventDefault(),p.style.transform="translateY(-2000px)",p.focus(),requestAnimationFrame(()=>{p.style.transform=""}))},a=c=>{let p=c.target;pa(p)&&(p.style.transform="translateY(-2000px)",requestAnimationFrame(()=>{p.style.transform="",Ho&&(Ho.height<window.innerHeight?requestAnimationFrame(()=>{yi(p)}):Ho.addEventListener("resize",()=>yi(p),{once:!0}))}))},s=()=>{window.scrollTo(0,0)},i=window.pageXOffset,l=window.pageYOffset,u=gi(hS(document.documentElement,"paddingRight",`${window.innerWidth-document.documentElement.clientWidth}px`));window.scrollTo(0,0);let m=gi(Fn(document,"touchstart",n,{passive:!1,capture:!0}),Fn(document,"touchmove",r,{passive:!1,capture:!0}),Fn(document,"touchend",o,{passive:!1,capture:!0}),Fn(document,"focus",a,!0),Fn(window,"scroll",s));return()=>{u(),m(),window.scrollTo(i,l)}}function hS(e,t,n){let r=e.style[t];return e.style[t]=n,()=>{e.style[t]=r}}function Fn(e,t,n,r){return e.addEventListener(t,n,r),()=>{e.removeEventListener(t,n,r)}}function yi(e){let t=document.scrollingElement||document.documentElement;for(;e&&e!==t;){let n=ud(e);if(n!==document.documentElement&&n!==document.body&&n!==e){let r=n.getBoundingClientRect().top,o=e.getBoundingClientRect().top,a=e.getBoundingClientRect().bottom;const s=n.getBoundingClientRect().bottom+uS;a>s&&(n.scrollTop+=o-r)}e=n.parentElement}}function pa(e){return e instanceof HTMLInputElement&&!fS.has(e.type)||e instanceof HTMLTextAreaElement||e instanceof HTMLElement&&e.isContentEditable}function gS(e,t){typeof e=="function"?e(t):e!=null&&(e.current=t)}function vS(...e){return t=>e.forEach(n=>gS(n,t))}function dd(...e){return d.useCallback(vS(...e),e)}const fd=new WeakMap;function Te(e,t,n=!1){if(!e||!(e instanceof HTMLElement))return;let r={};Object.entries(t).forEach(([o,a])=>{if(o.startsWith("--")){e.style.setProperty(o,a);return}r[o]=e.style[o],e.style[o]=a}),!n&&fd.set(e,r)}function yS(e,t){if(!e||!(e instanceof HTMLElement))return;let n=fd.get(e);n&&(e.style[t]=n[t])}const Ne=e=>{switch(e){case"top":case"bottom":return!0;case"left":case"right":return!1;default:return e}};function Nr(e,t){if(!e)return null;const n=window.getComputedStyle(e),r=n.transform||n.webkitTransform||n.mozTransform;let o=r.match(/^matrix3d\((.+)\)$/);return o?parseFloat(o[1].split(", ")[Ne(t)?13:12]):(o=r.match(/^matrix\((.+)\)$/),o?parseFloat(o[1].split(", ")[Ne(t)?5:4]):null)}function bS(e){return 8*(Math.log(e+1)-2)}function Go(e,t){if(!e)return()=>{};const n=e.style.cssText;return Object.assign(e.style,t),()=>{e.style.cssText=n}}function wS(...e){return(...t)=>{for(const n of e)typeof n=="function"&&n(...t)}}const Me={DURATION:.5,EASE:[.32,.72,0,1]},md=.4,xS=.25,SS=100,pd=8,qt=16,ha=26,Uo="vaul-dragging";function hd(e){const t=b.useRef(e);return b.useEffect(()=>{t.current=e}),b.useMemo(()=>(...n)=>t.current==null?void 0:t.current.call(t,...n),[])}function CS({defaultProp:e,onChange:t}){const n=b.useState(e),[r]=n,o=b.useRef(r),a=hd(t);return b.useEffect(()=>{o.current!==r&&(a(r),o.current=r)},[r,o,a]),n}function gd({prop:e,defaultProp:t,onChange:n=()=>{}}){const[r,o]=CS({defaultProp:t,onChange:n}),a=e!==void 0,s=a?e:r,i=hd(n),l=b.useCallback(u=>{if(a){const c=typeof u=="function"?u(e):u;c!==e&&i(c)}else o(u)},[a,e,o,i]);return[s,l]}function MS({activeSnapPointProp:e,setActiveSnapPointProp:t,snapPoints:n,drawerRef:r,overlayRef:o,fadeFromIndex:a,onSnapPointChange:s,direction:i="bottom",container:l,snapToSequentialPoint:u}){const[m,c]=gd({prop:e,defaultProp:n==null?void 0:n[0],onChange:t}),[p,h]=b.useState(typeof window<"u"?{innerWidth:window.innerWidth,innerHeight:window.innerHeight}:void 0);b.useEffect(()=>{function M(){h({innerWidth:window.innerWidth,innerHeight:window.innerHeight})}return window.addEventListener("resize",M),()=>window.removeEventListener("resize",M)},[]);const v=b.useMemo(()=>m===(n==null?void 0:n[n.length-1])||null,[n,m]),g=b.useMemo(()=>{var M;return(M=n==null?void 0:n.findIndex(D=>D===m))!=null?M:null},[n,m]),y=n&&n.length>0&&(a||a===0)&&!Number.isNaN(a)&&n[a]===m||!n,w=b.useMemo(()=>{const M=l?{width:l.getBoundingClientRect().width,height:l.getBoundingClientRect().height}:typeof window<"u"?{width:window.innerWidth,height:window.innerHeight}:{width:0,height:0};var D;return(D=n==null?void 0:n.map(L=>{const B=typeof L=="string";let F=0;if(B&&(F=parseInt(L,10)),Ne(i)){const $=B?F:p?L*M.height:0;return p?i==="bottom"?M.height-$:-M.height+$:$}const V=B?F:p?L*M.width:0;return p?i==="right"?M.width-V:-M.width+V:V}))!=null?D:[]},[n,p,l]),x=b.useMemo(()=>g!==null?w==null?void 0:w[g]:null,[w,g]),S=b.useCallback(M=>{var D;const L=(D=w==null?void 0:w.findIndex(B=>B===M))!=null?D:null;s(L),Te(r.current,{transition:`transform ${Me.DURATION}s cubic-bezier(${Me.EASE.join(",")})`,transform:Ne(i)?`translate3d(0, ${M}px, 0)`:`translate3d(${M}px, 0, 0)`}),w&&L!==w.length-1&&a!==void 0&&L!==a&&L<a?Te(o.current,{transition:`opacity ${Me.DURATION}s cubic-bezier(${Me.EASE.join(",")})`,opacity:"0"}):Te(o.current,{transition:`opacity ${Me.DURATION}s cubic-bezier(${Me.EASE.join(",")})`,opacity:"1"}),c(n==null?void 0:n[Math.max(L,0)])},[r.current,n,w,a,o,c]);b.useEffect(()=>{if(m||e){var M;const D=(M=n==null?void 0:n.findIndex(L=>L===e||L===m))!=null?M:-1;w&&D!==-1&&typeof w[D]=="number"&&S(w[D])}},[m,e,n,w,S]);function k({draggedDistance:M,closeDrawer:D,velocity:L,dismissible:B}){if(a===void 0)return;const F=i==="bottom"||i==="right"?(x??0)-M:(x??0)+M,V=g===a-1,$=g===0,I=M>0;if(V&&Te(o.current,{transition:`opacity ${Me.DURATION}s cubic-bezier(${Me.EASE.join(",")})`}),!u&&L>2&&!I){B?D():S(w[0]);return}if(!u&&L>2&&I&&w&&n){S(w[n.length-1]);return}const _=w==null?void 0:w.reduce((P,E)=>typeof P!="number"||typeof E!="number"?P:Math.abs(E-F)<Math.abs(P-F)?E:P),R=Ne(i)?window.innerHeight:window.innerWidth;if(L>md&&Math.abs(M)<R*.4){const P=I?1:-1;if(P>0&&v&&n){S(w[n.length-1]);return}if($&&P<0&&B&&D(),g===null)return;S(w[g+P]);return}S(_)}function C({draggedDistance:M}){if(x===null)return;const D=i==="bottom"||i==="right"?x-M:x+M;(i==="bottom"||i==="right")&&D<w[w.length-1]||(i==="top"||i==="left")&&D>w[w.length-1]||Te(r.current,{transform:Ne(i)?`translate3d(0, ${D}px, 0)`:`translate3d(${D}px, 0, 0)`})}function N(M,D){if(!n||typeof g!="number"||!w||a===void 0)return null;const L=g===a-1;if(g>=a&&D)return 0;if(L&&!D)return 1;if(!y&&!L)return null;const F=L?g+1:g-1,V=L?w[F]-w[F-1]:w[F+1]-w[F],$=M/Math.abs(V);return L?1-$:$}return{isLastSnapPoint:v,activeSnapPoint:m,shouldFade:y,getPercentageDragged:N,setActiveSnapPoint:c,activeSnapPointIndex:g,onRelease:k,onDrag:C,snapPointsOffset:w}}const ES=()=>()=>{};function kS(){const{direction:e,isOpen:t,shouldScaleBackground:n,setBackgroundColorOnScale:r,noBodyStyles:o}=fr(),a=b.useRef(null),s=b.useMemo(()=>document.body.style.backgroundColor,[]);function i(){return(window.innerWidth-ha)/window.innerWidth}b.useEffect(()=>{if(t&&n){a.current&&clearTimeout(a.current);const l=document.querySelector("[data-vaul-drawer-wrapper]")||document.querySelector("[vaul-drawer-wrapper]");if(!l)return;wS(r&&!o?Go(document.body,{background:"black"}):ES,Go(l,{transformOrigin:Ne(e)?"top":"left",transitionProperty:"transform, border-radius",transitionDuration:`${Me.DURATION}s`,transitionTimingFunction:`cubic-bezier(${Me.EASE.join(",")})`}));const u=Go(l,{borderRadius:`${pd}px`,overflow:"hidden",...Ne(e)?{transform:`scale(${i()}) translate3d(0, calc(env(safe-area-inset-top) + 14px), 0)`}:{transform:`scale(${i()}) translate3d(calc(env(safe-area-inset-top) + 14px), 0, 0)`}});return()=>{u(),a.current=window.setTimeout(()=>{s?document.body.style.background=s:document.body.style.removeProperty("background")},Me.DURATION*1e3)}}},[t,n,s])}let Wn=null;function NS({isOpen:e,modal:t,nested:n,hasBeenOpened:r,preventScrollRestoration:o,noBodyStyles:a}){const[s,i]=b.useState(()=>typeof window<"u"?window.location.href:""),l=b.useRef(0),u=b.useCallback(()=>{if(hi()&&Wn===null&&e&&!a){Wn={position:document.body.style.position,top:document.body.style.top,left:document.body.style.left,height:document.body.style.height,right:"unset"};const{scrollX:c,innerHeight:p}=window;document.body.style.setProperty("position","fixed","important"),Object.assign(document.body.style,{top:`${-l.current}px`,left:`${-c}px`,right:"0px",height:"auto"}),window.setTimeout(()=>window.requestAnimationFrame(()=>{const h=p-window.innerHeight;h&&l.current>=p&&(document.body.style.top=`${-(l.current+h)}px`)}),300)}},[e]),m=b.useCallback(()=>{if(hi()&&Wn!==null&&!a){const c=-parseInt(document.body.style.top,10),p=-parseInt(document.body.style.left,10);Object.assign(document.body.style,Wn),window.requestAnimationFrame(()=>{if(o&&s!==window.location.href){i(window.location.href);return}window.scrollTo(p,c)}),Wn=null}},[s]);return b.useEffect(()=>{function c(){l.current=window.scrollY}return c(),window.addEventListener("scroll",c),()=>{window.removeEventListener("scroll",c)}},[]),b.useEffect(()=>{if(t)return()=>{typeof document>"u"||document.querySelector("[data-vaul-drawer]")||m()}},[t,m]),b.useEffect(()=>{n||!r||(e?(!window.matchMedia("(display-mode: standalone)").matches&&u(),t||window.setTimeout(()=>{m()},500)):m())},[e,r,s,t,n,u,m]),{restorePositionSetting:m}}function DS({open:e,onOpenChange:t,children:n,onDrag:r,onRelease:o,snapPoints:a,shouldScaleBackground:s=!1,setBackgroundColorOnScale:i=!0,closeThreshold:l=xS,scrollLockTimeout:u=SS,dismissible:m=!0,handleOnly:c=!1,fadeFromIndex:p=a&&a.length-1,activeSnapPoint:h,setActiveSnapPoint:v,fixed:g,modal:y=!0,onClose:w,nested:x,noBodyStyles:S=!1,direction:k="bottom",defaultOpen:C=!1,disablePreventScroll:N=!0,snapToSequentialPoint:M=!1,preventScrollRestoration:D=!1,repositionInputs:L=!0,onAnimationEnd:B,container:F,autoFocus:V=!1}){var $,I;const[_=!1,R]=gd({defaultProp:C,prop:e,onChange:z=>{t==null||t(z),!z&&!x&&_n(),setTimeout(()=>{B==null||B(z)},Me.DURATION*1e3),z&&!y&&typeof window<"u"&&window.requestAnimationFrame(()=>{document.body.style.pointerEvents="auto"}),z||(document.body.style.pointerEvents="auto")}}),[P,E]=b.useState(!1),[O,Y]=b.useState(!1),[G,T]=b.useState(!1),A=b.useRef(null),W=b.useRef(null),H=b.useRef(null),U=b.useRef(null),j=b.useRef(null),Z=b.useRef(!1),X=b.useRef(null),Q=b.useRef(0),le=b.useRef(!1),de=b.useRef(!C),xe=b.useRef(0),re=b.useRef(null),ze=b.useRef((($=re.current)==null?void 0:$.getBoundingClientRect().height)||0),We=b.useRef(((I=re.current)==null?void 0:I.getBoundingClientRect().width)||0),ie=b.useRef(0),pe=b.useCallback(z=>{a&&z===$e.length-1&&(W.current=new Date)},[]),{activeSnapPoint:Se,activeSnapPointIndex:je,setActiveSnapPoint:Be,onRelease:_e,snapPointsOffset:$e,onDrag:Yt,shouldFade:rn,getPercentageDragged:Nt}=MS({snapPoints:a,activeSnapPointProp:h,setActiveSnapPointProp:v,drawerRef:re,fadeFromIndex:p,overlayRef:A,onSnapPointChange:pe,direction:k,container:F,snapToSequentialPoint:M});mS({isDisabled:!_||O||!y||G||!P||!L||!N});const{restorePositionSetting:_n}=NS({isOpen:_,modal:y,nested:x??!1,hasBeenOpened:P,preventScrollRestoration:D,noBodyStyles:S});function bt(){return(window.innerWidth-ha)/window.innerWidth}function Ht(z){var ae,oe;!m&&!a||re.current&&!re.current.contains(z.target)||(ze.current=((ae=re.current)==null?void 0:ae.getBoundingClientRect().height)||0,We.current=((oe=re.current)==null?void 0:oe.getBoundingClientRect().width)||0,Y(!0),H.current=new Date,ld()&&window.addEventListener("touchend",()=>Z.current=!1,{once:!0}),z.target.setPointerCapture(z.pointerId),Q.current=Ne(k)?z.pageY:z.pageX)}function nt(z,ae){var oe;let fe=z;const ge=(oe=window.getSelection())==null?void 0:oe.toString(),ne=re.current?Nr(re.current,k):null,ue=new Date;if(fe.tagName==="SELECT"||fe.hasAttribute("data-vaul-no-drag")||fe.closest("[data-vaul-no-drag]"))return!1;if(k==="right"||k==="left")return!0;if(W.current&&ue.getTime()-W.current.getTime()<500)return!1;if(ne!==null&&(k==="bottom"?ne>0:ne<0))return!0;if(ge&&ge.length>0)return!1;if(j.current&&ue.getTime()-j.current.getTime()<u&&ne===0||ae)return j.current=ue,!1;for(;fe;){if(fe.scrollHeight>fe.clientHeight){if(fe.scrollTop!==0)return j.current=new Date,!1;if(fe.getAttribute("role")==="dialog")return!0}fe=fe.parentNode}return!0}function on(z){if(re.current&&O){const ae=k==="bottom"||k==="right"?1:-1,oe=(Q.current-(Ne(k)?z.pageY:z.pageX))*ae,fe=oe>0,ge=a&&!m&&!fe;if(ge&&je===0)return;const ne=Math.abs(oe),ue=document.querySelector("[data-vaul-drawer-wrapper]"),ve=k==="bottom"||k==="top"?ze.current:We.current;let ce=ne/ve;const Ue=Nt(ne,fe);if(Ue!==null&&(ce=Ue),ge&&ce>=1||!Z.current&&!nt(z.target,fe))return;if(re.current.classList.add(Uo),Z.current=!0,Te(re.current,{transition:"none"}),Te(A.current,{transition:"none"}),a&&Yt({draggedDistance:oe}),fe&&!a){const Ce=bS(oe),Ve=Math.min(Ce*-1,0)*ae;Te(re.current,{transform:Ne(k)?`translate3d(0, ${Ve}px, 0)`:`translate3d(${Ve}px, 0, 0)`});return}const be=1-ce;if((rn||p&&je===p-1)&&(r==null||r(z,ce),Te(A.current,{opacity:`${be}`,transition:"none"},!0)),ue&&A.current&&s){const Ce=Math.min(bt()+ce*(1-bt()),1),Ve=8-ce*8,Pe=Math.max(0,14-ce*14);Te(ue,{borderRadius:`${Ve}px`,transform:Ne(k)?`scale(${Ce}) translate3d(0, ${Pe}px, 0)`:`scale(${Ce}) translate3d(${Pe}px, 0, 0)`,transition:"none"},!0)}if(!a){const Ce=ne*ae;Te(re.current,{transform:Ne(k)?`translate3d(0, ${Ce}px, 0)`:`translate3d(${Ce}px, 0, 0)`})}}}b.useEffect(()=>{window.requestAnimationFrame(()=>{de.current=!0})},[]),b.useEffect(()=>{var z;function ae(){if(!re.current||!L)return;const oe=document.activeElement;if(pa(oe)||le.current){var fe;const ge=((fe=window.visualViewport)==null?void 0:fe.height)||0,ne=window.innerHeight;let ue=ne-ge;const ve=re.current.getBoundingClientRect().height||0,ce=ve>ne*.8;ie.current||(ie.current=ve);const Ue=re.current.getBoundingClientRect().top;if(Math.abs(xe.current-ue)>60&&(le.current=!le.current),a&&a.length>0&&$e&&je){const be=$e[je]||0;ue+=be}if(xe.current=ue,ve>ge||le.current){const be=re.current.getBoundingClientRect().height;let Ce=be;be>ge&&(Ce=ge-(ce?Ue:ha)),g?re.current.style.height=`${be-Math.max(ue,0)}px`:re.current.style.height=`${Math.max(Ce,ge-Ue)}px`}else sS()||(re.current.style.height=`${ie.current}px`);a&&a.length>0&&!le.current?re.current.style.bottom="0px":re.current.style.bottom=`${Math.max(ue,0)}px`}}return(z=window.visualViewport)==null||z.addEventListener("resize",ae),()=>{var oe;return(oe=window.visualViewport)==null?void 0:oe.removeEventListener("resize",ae)}},[je,a,$e]);function Ge(z){Pn(),w==null||w(),z||R(!1),setTimeout(()=>{a&&Be(a[0])},Me.DURATION*1e3)}function an(){if(!re.current)return;const z=document.querySelector("[data-vaul-drawer-wrapper]"),ae=Nr(re.current,k);Te(re.current,{transform:"translate3d(0, 0, 0)",transition:`transform ${Me.DURATION}s cubic-bezier(${Me.EASE.join(",")})`}),Te(A.current,{transition:`opacity ${Me.DURATION}s cubic-bezier(${Me.EASE.join(",")})`,opacity:"1"}),s&&ae&&ae>0&&_&&Te(z,{borderRadius:`${pd}px`,overflow:"hidden",...Ne(k)?{transform:`scale(${bt()}) translate3d(0, calc(env(safe-area-inset-top) + 14px), 0)`,transformOrigin:"top"}:{transform:`scale(${bt()}) translate3d(calc(env(safe-area-inset-top) + 14px), 0, 0)`,transformOrigin:"left"},transitionProperty:"transform, border-radius",transitionDuration:`${Me.DURATION}s`,transitionTimingFunction:`cubic-bezier(${Me.EASE.join(",")})`},!0)}function Pn(){!O||!re.current||(re.current.classList.remove(Uo),Z.current=!1,Y(!1),U.current=new Date)}function sn(z){if(!O||!re.current)return;re.current.classList.remove(Uo),Z.current=!1,Y(!1),U.current=new Date;const ae=Nr(re.current,k);if(!z||!nt(z.target,!1)||!ae||Number.isNaN(ae)||H.current===null)return;const oe=U.current.getTime()-H.current.getTime(),fe=Q.current-(Ne(k)?z.pageY:z.pageX),ge=Math.abs(fe)/oe;if(ge>.05&&(T(!0),setTimeout(()=>{T(!1)},200)),a){_e({draggedDistance:fe*(k==="bottom"||k==="right"?1:-1),closeDrawer:Ge,velocity:ge,dismissible:m}),o==null||o(z,!0);return}if(k==="bottom"||k==="right"?fe>0:fe<0){an(),o==null||o(z,!0);return}if(ge>md){Ge(),o==null||o(z,!1);return}var ne;const ue=Math.min((ne=re.current.getBoundingClientRect().height)!=null?ne:0,window.innerHeight);var ve;const ce=Math.min((ve=re.current.getBoundingClientRect().width)!=null?ve:0,window.innerWidth),Ue=k==="left"||k==="right";if(Math.abs(ae)>=(Ue?ce:ue)*l){Ge(),o==null||o(z,!1);return}o==null||o(z,!0),an()}b.useEffect(()=>(_&&(Te(document.documentElement,{scrollBehavior:"auto"}),W.current=new Date),()=>{yS(document.documentElement,"scrollBehavior")}),[_]);function zt(z){const ae=z?(window.innerWidth-qt)/window.innerWidth:1,oe=z?-qt:0;X.current&&window.clearTimeout(X.current),Te(re.current,{transition:`transform ${Me.DURATION}s cubic-bezier(${Me.EASE.join(",")})`,transform:Ne(k)?`scale(${ae}) translate3d(0, ${oe}px, 0)`:`scale(${ae}) translate3d(${oe}px, 0, 0)`}),!z&&re.current&&(X.current=setTimeout(()=>{const fe=Nr(re.current,k);Te(re.current,{transition:"none",transform:Ne(k)?`translate3d(0, ${fe}px, 0)`:`translate3d(${fe}px, 0, 0)`})},500))}function An(z,ae){if(ae<0)return;const oe=(window.innerWidth-qt)/window.innerWidth,fe=oe+ae*(1-oe),ge=-qt+ae*qt;Te(re.current,{transform:Ne(k)?`scale(${fe}) translate3d(0, ${ge}px, 0)`:`scale(${fe}) translate3d(${ge}px, 0, 0)`,transition:"none"})}function Dt(z,ae){const oe=Ne(k)?window.innerHeight:window.innerWidth,fe=ae?(oe-qt)/oe:1,ge=ae?-qt:0;ae&&Te(re.current,{transition:`transform ${Me.DURATION}s cubic-bezier(${Me.EASE.join(",")})`,transform:Ne(k)?`scale(${fe}) translate3d(0, ${ge}px, 0)`:`scale(${fe}) translate3d(${ge}px, 0, 0)`})}return b.useEffect(()=>{y||window.requestAnimationFrame(()=>{document.body.style.pointerEvents="auto"})},[y]),b.createElement(za,{defaultOpen:C,onOpenChange:z=>{!m&&!z||(z?E(!0):Ge(!0),R(z))},open:_},b.createElement(cd.Provider,{value:{activeSnapPoint:Se,snapPoints:a,setActiveSnapPoint:Be,drawerRef:re,overlayRef:A,onOpenChange:t,onPress:Ht,onRelease:sn,onDrag:on,dismissible:m,shouldAnimate:de,handleOnly:c,isOpen:_,isDragging:O,shouldFade:rn,closeDrawer:Ge,onNestedDrag:An,onNestedOpenChange:zt,onNestedRelease:Dt,keyboardIsOpen:le,modal:y,snapPointsOffset:$e,activeSnapPointIndex:je,direction:k,shouldScaleBackground:s,setBackgroundColorOnScale:i,noBodyStyles:S,container:F,autoFocus:V}},n))}const vd=b.forwardRef(function({...e},t){const{overlayRef:n,snapPoints:r,onRelease:o,shouldFade:a,isOpen:s,modal:i,shouldAnimate:l}=fr(),u=dd(t,n),m=r&&r.length>0;if(!i)return null;const c=b.useCallback(p=>o(p),[o]);return b.createElement(lo,{onMouseUp:c,ref:u,"data-vaul-overlay":"","data-vaul-snap-points":s&&m?"true":"false","data-vaul-snap-points-overlay":s&&a?"true":"false","data-vaul-animate":l!=null&&l.current?"true":"false",...e})});vd.displayName="Drawer.Overlay";const yd=b.forwardRef(function({onPointerDownOutside:e,style:t,onOpenAutoFocus:n,...r},o){const{drawerRef:a,onPress:s,onRelease:i,onDrag:l,keyboardIsOpen:u,snapPointsOffset:m,activeSnapPointIndex:c,modal:p,isOpen:h,direction:v,snapPoints:g,container:y,handleOnly:w,shouldAnimate:x,autoFocus:S}=fr(),[k,C]=b.useState(!1),N=dd(o,a),M=b.useRef(null),D=b.useRef(null),L=b.useRef(!1),B=g&&g.length>0;kS();const F=($,I,_=0)=>{if(L.current)return!0;const R=Math.abs($.y),P=Math.abs($.x),E=P>R,O=["bottom","right"].includes(I)?1:-1;if(I==="left"||I==="right"){if(!($.x*O<0)&&P>=0&&P<=_)return E}else if(!($.y*O<0)&&R>=0&&R<=_)return!E;return L.current=!0,!0};b.useEffect(()=>{B&&window.requestAnimationFrame(()=>{C(!0)})},[]);function V($){M.current=null,L.current=!1,i($)}return b.createElement(uo,{"data-vaul-drawer-direction":v,"data-vaul-drawer":"","data-vaul-delayed-snap-points":k?"true":"false","data-vaul-snap-points":h&&B?"true":"false","data-vaul-custom-container":y?"true":"false","data-vaul-animate":x!=null&&x.current?"true":"false",...r,ref:N,style:m&&m.length>0?{"--snap-point-height":`${m[c??0]}px`,...t}:t,onPointerDown:$=>{w||(r.onPointerDown==null||r.onPointerDown.call(r,$),M.current={x:$.pageX,y:$.pageY},s($))},onOpenAutoFocus:$=>{n==null||n($),S||$.preventDefault()},onPointerDownOutside:$=>{if(e==null||e($),!p||$.defaultPrevented){$.preventDefault();return}u.current&&(u.current=!1)},onFocusOutside:$=>{if(!p){$.preventDefault();return}},onPointerMove:$=>{if(D.current=$,w||(r.onPointerMove==null||r.onPointerMove.call(r,$),!M.current))return;const I=$.pageY-M.current.y,_=$.pageX-M.current.x,R=$.pointerType==="touch"?10:2;F({x:_,y:I},v,R)?l($):(Math.abs(_)>R||Math.abs(I)>R)&&(M.current=null)},onPointerUp:$=>{r.onPointerUp==null||r.onPointerUp.call(r,$),M.current=null,L.current=!1,i($)},onPointerOut:$=>{r.onPointerOut==null||r.onPointerOut.call(r,$),V(D.current)},onContextMenu:$=>{r.onContextMenu==null||r.onContextMenu.call(r,$),D.current&&V(D.current)}})});yd.displayName="Drawer.Content";const RS=250,TS=120,OS=b.forwardRef(function({preventCycle:e=!1,children:t,...n},r){const{closeDrawer:o,isDragging:a,snapPoints:s,activeSnapPoint:i,setActiveSnapPoint:l,dismissible:u,handleOnly:m,isOpen:c,onPress:p,onDrag:h}=fr(),v=b.useRef(null),g=b.useRef(!1);function y(){if(g.current){S();return}window.setTimeout(()=>{w()},TS)}function w(){if(a||e||g.current){S();return}if(S(),!s||s.length===0){u||o();return}if(i===s[s.length-1]&&u){o();return}const C=s.findIndex(M=>M===i);if(C===-1)return;const N=s[C+1];l(N)}function x(){v.current=window.setTimeout(()=>{g.current=!0},RS)}function S(){v.current&&window.clearTimeout(v.current),g.current=!1}return b.createElement("div",{onClick:y,onPointerCancel:S,onPointerDown:k=>{m&&p(k),x()},onPointerMove:k=>{m&&h(k)},ref:r,"data-vaul-drawer-visible":c?"true":"false","data-vaul-handle":"","aria-hidden":"true",...n},b.createElement("span",{"data-vaul-handle-hitarea":"","aria-hidden":"true"},t))});OS.displayName="Drawer.Handle";function _S(e){const t=fr(),{container:n=t.container,...r}=e;return b.createElement(Ga,{container:n,...r})}const lt={Root:DS,Content:yd,Overlay:vd,Trigger:hu,Portal:_S,Close:Va,Title:Ua,Description:qa},bd=({shouldScaleBackground:e=!0,...t})=>f.jsx(lt.Root,{shouldScaleBackground:e,...t});bd.displayName="Drawer";const PS=lt.Trigger,AS=lt.Portal,IS=lt.Close,wd=d.forwardRef(({className:e,...t},n)=>f.jsx(lt.Overlay,{ref:n,className:q("fixed inset-0 z-50 bg-black/80",e),...t}));wd.displayName=lt.Overlay.displayName;const xd=d.forwardRef(({className:e,children:t,...n},r)=>f.jsxs(AS,{children:[f.jsx(wd,{}),f.jsxs(lt.Content,{ref:r,className:q("fixed inset-x-0 bottom-0 z-50 mt-24 flex h-auto flex-col rounded-t-[10px] border bg-background",e),...n,children:[f.jsx("div",{className:"mx-auto mt-4 h-2 w-[100px] rounded-full bg-muted"}),t]})]}));xd.displayName="DrawerContent";const Sd=({className:e,...t})=>f.jsx("div",{className:q("grid gap-1.5 p-4 text-center sm:text-left",e),...t});Sd.displayName="DrawerHeader";const Cd=({className:e,...t})=>f.jsx("div",{className:q("mt-auto flex flex-col gap-2 p-4",e),...t});Cd.displayName="DrawerFooter";const Md=d.forwardRef(({className:e,...t},n)=>f.jsx(lt.Title,{ref:n,className:q("text-lg font-semibold leading-none tracking-tight",e),...t}));Md.displayName=lt.Title.displayName;const Ed=d.forwardRef(({className:e,...t},n)=>f.jsx(lt.Description,{ref:n,className:q("text-sm text-muted-foreground",e),...t}));Ed.displayName=lt.Description.displayName;var qo="rovingFocusGroup.onEntryFocus",jS={bubbles:!1,cancelable:!0},mr="RovingFocusGroup",[ga,kd,$S]=ja(mr),[LS,On]=Ye(mr,[$S]),[FS,WS]=LS(mr),Nd=d.forwardRef((e,t)=>f.jsx(ga.Provider,{scope:e.__scopeRovingFocusGroup,children:f.jsx(ga.Slot,{scope:e.__scopeRovingFocusGroup,children:f.jsx(BS,{...e,ref:t})})}));Nd.displayName=mr;var BS=d.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:o=!1,dir:a,currentTabStopId:s,defaultCurrentTabStopId:i,onCurrentTabStopIdChange:l,onEntryFocus:u,preventScrollOnEntryFocus:m=!1,...c}=e,p=d.useRef(null),h=he(t,p),v=ir(a),[g,y]=tt({prop:s,defaultProp:i??null,onChange:l,caller:mr}),[w,x]=d.useState(!1),S=et(u),k=kd(n),C=d.useRef(!1),[N,M]=d.useState(0);return d.useEffect(()=>{const D=p.current;if(D)return D.addEventListener(qo,S),()=>D.removeEventListener(qo,S)},[S]),f.jsx(FS,{scope:n,orientation:r,dir:v,loop:o,currentTabStopId:g,onItemFocus:d.useCallback(D=>y(D),[y]),onItemShiftTab:d.useCallback(()=>x(!0),[]),onFocusableItemAdd:d.useCallback(()=>M(D=>D+1),[]),onFocusableItemRemove:d.useCallback(()=>M(D=>D-1),[]),children:f.jsx(te.div,{tabIndex:w||N===0?-1:0,"data-orientation":r,...c,ref:h,style:{outline:"none",...e.style},onMouseDown:K(e.onMouseDown,()=>{C.current=!0}),onFocus:K(e.onFocus,D=>{const L=!C.current;if(D.target===D.currentTarget&&L&&!w){const B=new CustomEvent(qo,jS);if(D.currentTarget.dispatchEvent(B),!B.defaultPrevented){const F=k().filter(R=>R.focusable),V=F.find(R=>R.active),$=F.find(R=>R.id===g),_=[V,$,...F].filter(Boolean).map(R=>R.ref.current);Td(_,m)}}C.current=!1}),onBlur:K(e.onBlur,()=>x(!1))})})}),Dd="RovingFocusGroupItem",Rd=d.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:o=!1,tabStopId:a,children:s,...i}=e,l=ke(),u=a||l,m=WS(Dd,n),c=m.currentTabStopId===u,p=kd(n),{onFocusableItemAdd:h,onFocusableItemRemove:v,currentTabStopId:g}=m;return d.useEffect(()=>{if(r)return h(),()=>v()},[r,h,v]),f.jsx(ga.ItemSlot,{scope:n,id:u,focusable:r,active:o,children:f.jsx(te.span,{tabIndex:c?0:-1,"data-orientation":m.orientation,...i,ref:t,onMouseDown:K(e.onMouseDown,y=>{r?m.onItemFocus(u):y.preventDefault()}),onFocus:K(e.onFocus,()=>m.onItemFocus(u)),onKeyDown:K(e.onKeyDown,y=>{if(y.key==="Tab"&&y.shiftKey){m.onItemShiftTab();return}if(y.target!==y.currentTarget)return;const w=zS(y,m.orientation,m.dir);if(w!==void 0){if(y.metaKey||y.ctrlKey||y.altKey||y.shiftKey)return;y.preventDefault();let S=p().filter(k=>k.focusable).map(k=>k.ref.current);if(w==="last")S.reverse();else if(w==="prev"||w==="next"){w==="prev"&&S.reverse();const k=S.indexOf(y.currentTarget);S=m.loop?GS(S,k+1):S.slice(k+1)}setTimeout(()=>Td(S))}}),children:typeof s=="function"?s({isCurrentTabStop:c,hasTabStop:g!=null}):s})})});Rd.displayName=Dd;var YS={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function HS(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function zS(e,t,n){const r=HS(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(r))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(r)))return YS[r]}function Td(e,t=!1){const n=document.activeElement;for(const r of e)if(r===n||(r.focus({preventScroll:t}),document.activeElement!==n))return}function GS(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var rs=Nd,os=Rd,va=["Enter"," "],US=["ArrowDown","PageUp","Home"],Od=["ArrowUp","PageDown","End"],qS=[...US,...Od],VS={ltr:[...va,"ArrowRight"],rtl:[...va,"ArrowLeft"]},KS={ltr:["ArrowLeft"],rtl:["ArrowRight"]},pr="Menu",[Xn,XS,ZS]=ja(pr),[nn,_d]=Ye(pr,[ZS,$t,On]),hr=$t(),Pd=On(),[Ad,Bt]=nn(pr),[QS,gr]=nn(pr),Id=e=>{const{__scopeMenu:t,open:n=!1,children:r,dir:o,onOpenChange:a,modal:s=!0}=e,i=hr(t),[l,u]=d.useState(null),m=d.useRef(!1),c=et(a),p=ir(o);return d.useEffect(()=>{const h=()=>{m.current=!0,document.addEventListener("pointerdown",v,{capture:!0,once:!0}),document.addEventListener("pointermove",v,{capture:!0,once:!0})},v=()=>m.current=!1;return document.addEventListener("keydown",h,{capture:!0}),()=>{document.removeEventListener("keydown",h,{capture:!0}),document.removeEventListener("pointerdown",v,{capture:!0}),document.removeEventListener("pointermove",v,{capture:!0})}},[]),f.jsx(nr,{...i,children:f.jsx(Ad,{scope:t,open:n,onOpenChange:c,content:l,onContentChange:u,children:f.jsx(QS,{scope:t,onClose:d.useCallback(()=>c(!1),[c]),isUsingKeyboardRef:m,dir:p,modal:s,children:r})})})};Id.displayName=pr;var JS="MenuAnchor",as=d.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e,o=hr(n);return f.jsx(rr,{...o,...r,ref:t})});as.displayName=JS;var ss="MenuPortal",[e1,jd]=nn(ss,{forceMount:void 0}),$d=e=>{const{__scopeMenu:t,forceMount:n,children:r,container:o}=e,a=Bt(ss,t);return f.jsx(e1,{scope:t,forceMount:n,children:f.jsx(He,{present:n||a.open,children:f.jsx(or,{asChild:!0,container:o,children:r})})})};$d.displayName=ss;var Je="MenuContent",[t1,is]=nn(Je),Ld=d.forwardRef((e,t)=>{const n=jd(Je,e.__scopeMenu),{forceMount:r=n.forceMount,...o}=e,a=Bt(Je,e.__scopeMenu),s=gr(Je,e.__scopeMenu);return f.jsx(Xn.Provider,{scope:e.__scopeMenu,children:f.jsx(He,{present:r||a.open,children:f.jsx(Xn.Slot,{scope:e.__scopeMenu,children:s.modal?f.jsx(n1,{...o,ref:t}):f.jsx(r1,{...o,ref:t})})})})}),n1=d.forwardRef((e,t)=>{const n=Bt(Je,e.__scopeMenu),r=d.useRef(null),o=he(t,r);return d.useEffect(()=>{const a=r.current;if(a)return to(a)},[]),f.jsx(cs,{...e,ref:o,trapFocus:n.open,disableOutsidePointerEvents:n.open,disableOutsideScroll:!0,onFocusOutside:K(e.onFocusOutside,a=>a.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>n.onOpenChange(!1)})}),r1=d.forwardRef((e,t)=>{const n=Bt(Je,e.__scopeMenu);return f.jsx(cs,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>n.onOpenChange(!1)})}),o1=Pt("MenuContent.ScrollLock"),cs=d.forwardRef((e,t)=>{const{__scopeMenu:n,loop:r=!1,trapFocus:o,onOpenAutoFocus:a,onCloseAutoFocus:s,disableOutsidePointerEvents:i,onEntryFocus:l,onEscapeKeyDown:u,onPointerDownOutside:m,onFocusOutside:c,onInteractOutside:p,onDismiss:h,disableOutsideScroll:v,...g}=e,y=Bt(Je,n),w=gr(Je,n),x=hr(n),S=Pd(n),k=XS(n),[C,N]=d.useState(null),M=d.useRef(null),D=he(t,M,y.onContentChange),L=d.useRef(0),B=d.useRef(""),F=d.useRef(0),V=d.useRef(null),$=d.useRef("right"),I=d.useRef(0),_=v?ar:d.Fragment,R=v?{as:o1,allowPinchZoom:!0}:void 0,P=O=>{var j,Z;const Y=B.current+O,G=k().filter(X=>!X.disabled),T=document.activeElement,A=(j=G.find(X=>X.ref.current===T))==null?void 0:j.textValue,W=G.map(X=>X.textValue),H=g1(W,Y,A),U=(Z=G.find(X=>X.textValue===H))==null?void 0:Z.ref.current;(function X(Q){B.current=Q,window.clearTimeout(L.current),Q!==""&&(L.current=window.setTimeout(()=>X(""),1e3))})(Y),U&&setTimeout(()=>U.focus())};d.useEffect(()=>()=>window.clearTimeout(L.current),[]),Kr();const E=d.useCallback(O=>{var G,T;return $.current===((G=V.current)==null?void 0:G.side)&&y1(O,(T=V.current)==null?void 0:T.area)},[]);return f.jsx(t1,{scope:n,searchRef:B,onItemEnter:d.useCallback(O=>{E(O)&&O.preventDefault()},[E]),onItemLeave:d.useCallback(O=>{var Y;E(O)||((Y=M.current)==null||Y.focus(),N(null))},[E]),onTriggerLeave:d.useCallback(O=>{E(O)&&O.preventDefault()},[E]),pointerGraceTimerRef:F,onPointerGraceIntentChange:d.useCallback(O=>{V.current=O},[]),children:f.jsx(_,{...R,children:f.jsx(er,{asChild:!0,trapped:o,onMountAutoFocus:K(a,O=>{var Y;O.preventDefault(),(Y=M.current)==null||Y.focus({preventScroll:!0})}),onUnmountAutoFocus:s,children:f.jsx(kn,{asChild:!0,disableOutsidePointerEvents:i,onEscapeKeyDown:u,onPointerDownOutside:m,onFocusOutside:c,onInteractOutside:p,onDismiss:h,children:f.jsx(rs,{asChild:!0,...S,dir:w.dir,orientation:"vertical",loop:r,currentTabStopId:C,onCurrentTabStopIdChange:N,onEntryFocus:K(l,O=>{w.isUsingKeyboardRef.current||O.preventDefault()}),preventScrollOnEntryFocus:!0,children:f.jsx(Jr,{role:"menu","aria-orientation":"vertical","data-state":tf(y.open),"data-radix-menu-content":"",dir:w.dir,...x,...g,ref:D,style:{outline:"none",...g.style},onKeyDown:K(g.onKeyDown,O=>{const G=O.target.closest("[data-radix-menu-content]")===O.currentTarget,T=O.ctrlKey||O.altKey||O.metaKey,A=O.key.length===1;G&&(O.key==="Tab"&&O.preventDefault(),!T&&A&&P(O.key));const W=M.current;if(O.target!==W||!qS.includes(O.key))return;O.preventDefault();const U=k().filter(j=>!j.disabled).map(j=>j.ref.current);Od.includes(O.key)&&U.reverse(),p1(U)}),onBlur:K(e.onBlur,O=>{O.currentTarget.contains(O.target)||(window.clearTimeout(L.current),B.current="")}),onPointerMove:K(e.onPointerMove,Zn(O=>{const Y=O.target,G=I.current!==O.clientX;if(O.currentTarget.contains(Y)&&G){const T=O.clientX>I.current?"right":"left";$.current=T,I.current=O.clientX}}))})})})})})})});Ld.displayName=Je;var a1="MenuGroup",ls=d.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return f.jsx(te.div,{role:"group",...r,ref:t})});ls.displayName=a1;var s1="MenuLabel",Fd=d.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return f.jsx(te.div,{...r,ref:t})});Fd.displayName=s1;var Gr="MenuItem",bi="menu.itemSelect",ho=d.forwardRef((e,t)=>{const{disabled:n=!1,onSelect:r,...o}=e,a=d.useRef(null),s=gr(Gr,e.__scopeMenu),i=is(Gr,e.__scopeMenu),l=he(t,a),u=d.useRef(!1),m=()=>{const c=a.current;if(!n&&c){const p=new CustomEvent(bi,{bubbles:!0,cancelable:!0});c.addEventListener(bi,h=>r==null?void 0:r(h),{once:!0}),$i(c,p),p.defaultPrevented?u.current=!1:s.onClose()}};return f.jsx(Wd,{...o,ref:l,disabled:n,onClick:K(e.onClick,m),onPointerDown:c=>{var p;(p=e.onPointerDown)==null||p.call(e,c),u.current=!0},onPointerUp:K(e.onPointerUp,c=>{var p;u.current||(p=c.currentTarget)==null||p.click()}),onKeyDown:K(e.onKeyDown,c=>{const p=i.searchRef.current!=="";n||p&&c.key===" "||va.includes(c.key)&&(c.currentTarget.click(),c.preventDefault())})})});ho.displayName=Gr;var Wd=d.forwardRef((e,t)=>{const{__scopeMenu:n,disabled:r=!1,textValue:o,...a}=e,s=is(Gr,n),i=Pd(n),l=d.useRef(null),u=he(t,l),[m,c]=d.useState(!1),[p,h]=d.useState("");return d.useEffect(()=>{const v=l.current;v&&h((v.textContent??"").trim())},[a.children]),f.jsx(Xn.ItemSlot,{scope:n,disabled:r,textValue:o??p,children:f.jsx(os,{asChild:!0,...i,focusable:!r,children:f.jsx(te.div,{role:"menuitem","data-highlighted":m?"":void 0,"aria-disabled":r||void 0,"data-disabled":r?"":void 0,...a,ref:u,onPointerMove:K(e.onPointerMove,Zn(v=>{r?s.onItemLeave(v):(s.onItemEnter(v),v.defaultPrevented||v.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:K(e.onPointerLeave,Zn(v=>s.onItemLeave(v))),onFocus:K(e.onFocus,()=>c(!0)),onBlur:K(e.onBlur,()=>c(!1))})})})}),i1="MenuCheckboxItem",Bd=d.forwardRef((e,t)=>{const{checked:n=!1,onCheckedChange:r,...o}=e;return f.jsx(Ud,{scope:e.__scopeMenu,checked:n,children:f.jsx(ho,{role:"menuitemcheckbox","aria-checked":Ur(n)?"mixed":n,...o,ref:t,"data-state":fs(n),onSelect:K(o.onSelect,()=>r==null?void 0:r(Ur(n)?!0:!n),{checkForDefaultPrevented:!1})})})});Bd.displayName=i1;var Yd="MenuRadioGroup",[c1,l1]=nn(Yd,{value:void 0,onValueChange:()=>{}}),Hd=d.forwardRef((e,t)=>{const{value:n,onValueChange:r,...o}=e,a=et(r);return f.jsx(c1,{scope:e.__scopeMenu,value:n,onValueChange:a,children:f.jsx(ls,{...o,ref:t})})});Hd.displayName=Yd;var zd="MenuRadioItem",Gd=d.forwardRef((e,t)=>{const{value:n,...r}=e,o=l1(zd,e.__scopeMenu),a=n===o.value;return f.jsx(Ud,{scope:e.__scopeMenu,checked:a,children:f.jsx(ho,{role:"menuitemradio","aria-checked":a,...r,ref:t,"data-state":fs(a),onSelect:K(r.onSelect,()=>{var s;return(s=o.onValueChange)==null?void 0:s.call(o,n)},{checkForDefaultPrevented:!1})})})});Gd.displayName=zd;var us="MenuItemIndicator",[Ud,u1]=nn(us,{checked:!1}),qd=d.forwardRef((e,t)=>{const{__scopeMenu:n,forceMount:r,...o}=e,a=u1(us,n);return f.jsx(He,{present:r||Ur(a.checked)||a.checked===!0,children:f.jsx(te.span,{...o,ref:t,"data-state":fs(a.checked)})})});qd.displayName=us;var d1="MenuSeparator",Vd=d.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return f.jsx(te.div,{role:"separator","aria-orientation":"horizontal",...r,ref:t})});Vd.displayName=d1;var f1="MenuArrow",Kd=d.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e,o=hr(n);return f.jsx(eo,{...o,...r,ref:t})});Kd.displayName=f1;var ds="MenuSub",[m1,Xd]=nn(ds),Zd=e=>{const{__scopeMenu:t,children:n,open:r=!1,onOpenChange:o}=e,a=Bt(ds,t),s=hr(t),[i,l]=d.useState(null),[u,m]=d.useState(null),c=et(o);return d.useEffect(()=>(a.open===!1&&c(!1),()=>c(!1)),[a.open,c]),f.jsx(nr,{...s,children:f.jsx(Ad,{scope:t,open:r,onOpenChange:c,content:u,onContentChange:m,children:f.jsx(m1,{scope:t,contentId:ke(),triggerId:ke(),trigger:i,onTriggerChange:l,children:n})})})};Zd.displayName=ds;var zn="MenuSubTrigger",Qd=d.forwardRef((e,t)=>{const n=Bt(zn,e.__scopeMenu),r=gr(zn,e.__scopeMenu),o=Xd(zn,e.__scopeMenu),a=is(zn,e.__scopeMenu),s=d.useRef(null),{pointerGraceTimerRef:i,onPointerGraceIntentChange:l}=a,u={__scopeMenu:e.__scopeMenu},m=d.useCallback(()=>{s.current&&window.clearTimeout(s.current),s.current=null},[]);return d.useEffect(()=>m,[m]),d.useEffect(()=>{const c=i.current;return()=>{window.clearTimeout(c),l(null)}},[i,l]),f.jsx(as,{asChild:!0,...u,children:f.jsx(Wd,{id:o.triggerId,"aria-haspopup":"menu","aria-expanded":n.open,"aria-controls":o.contentId,"data-state":tf(n.open),...e,ref:Ct(t,o.onTriggerChange),onClick:c=>{var p;(p=e.onClick)==null||p.call(e,c),!(e.disabled||c.defaultPrevented)&&(c.currentTarget.focus(),n.open||n.onOpenChange(!0))},onPointerMove:K(e.onPointerMove,Zn(c=>{a.onItemEnter(c),!c.defaultPrevented&&!e.disabled&&!n.open&&!s.current&&(a.onPointerGraceIntentChange(null),s.current=window.setTimeout(()=>{n.onOpenChange(!0),m()},100))})),onPointerLeave:K(e.onPointerLeave,Zn(c=>{var h,v;m();const p=(h=n.content)==null?void 0:h.getBoundingClientRect();if(p){const g=(v=n.content)==null?void 0:v.dataset.side,y=g==="right",w=y?-5:5,x=p[y?"left":"right"],S=p[y?"right":"left"];a.onPointerGraceIntentChange({area:[{x:c.clientX+w,y:c.clientY},{x,y:p.top},{x:S,y:p.top},{x:S,y:p.bottom},{x,y:p.bottom}],side:g}),window.clearTimeout(i.current),i.current=window.setTimeout(()=>a.onPointerGraceIntentChange(null),300)}else{if(a.onTriggerLeave(c),c.defaultPrevented)return;a.onPointerGraceIntentChange(null)}})),onKeyDown:K(e.onKeyDown,c=>{var h;const p=a.searchRef.current!=="";e.disabled||p&&c.key===" "||VS[r.dir].includes(c.key)&&(n.onOpenChange(!0),(h=n.content)==null||h.focus(),c.preventDefault())})})})});Qd.displayName=zn;var Jd="MenuSubContent",ef=d.forwardRef((e,t)=>{const n=jd(Je,e.__scopeMenu),{forceMount:r=n.forceMount,...o}=e,a=Bt(Je,e.__scopeMenu),s=gr(Je,e.__scopeMenu),i=Xd(Jd,e.__scopeMenu),l=d.useRef(null),u=he(t,l);return f.jsx(Xn.Provider,{scope:e.__scopeMenu,children:f.jsx(He,{present:r||a.open,children:f.jsx(Xn.Slot,{scope:e.__scopeMenu,children:f.jsx(cs,{id:i.contentId,"aria-labelledby":i.triggerId,...o,ref:u,align:"start",side:s.dir==="rtl"?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:m=>{var c;s.isUsingKeyboardRef.current&&((c=l.current)==null||c.focus()),m.preventDefault()},onCloseAutoFocus:m=>m.preventDefault(),onFocusOutside:K(e.onFocusOutside,m=>{m.target!==i.trigger&&a.onOpenChange(!1)}),onEscapeKeyDown:K(e.onEscapeKeyDown,m=>{s.onClose(),m.preventDefault()}),onKeyDown:K(e.onKeyDown,m=>{var h;const c=m.currentTarget.contains(m.target),p=KS[s.dir].includes(m.key);c&&p&&(a.onOpenChange(!1),(h=i.trigger)==null||h.focus(),m.preventDefault())})})})})})});ef.displayName=Jd;function tf(e){return e?"open":"closed"}function Ur(e){return e==="indeterminate"}function fs(e){return Ur(e)?"indeterminate":e?"checked":"unchecked"}function p1(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function h1(e,t){return e.map((n,r)=>e[(t+r)%e.length])}function g1(e,t,n){const o=t.length>1&&Array.from(t).every(u=>u===t[0])?t[0]:t,a=n?e.indexOf(n):-1;let s=h1(e,Math.max(a,0));o.length===1&&(s=s.filter(u=>u!==n));const l=s.find(u=>u.toLowerCase().startsWith(o.toLowerCase()));return l!==n?l:void 0}function v1(e,t){const{x:n,y:r}=e;let o=!1;for(let a=0,s=t.length-1;a<t.length;s=a++){const i=t[a],l=t[s],u=i.x,m=i.y,c=l.x,p=l.y;m>r!=p>r&&n<(c-u)*(r-m)/(p-m)+u&&(o=!o)}return o}function y1(e,t){if(!t)return!1;const n={x:e.clientX,y:e.clientY};return v1(n,t)}function Zn(e){return t=>t.pointerType==="mouse"?e(t):void 0}var b1=Id,w1=as,x1=$d,S1=Ld,C1=ls,M1=Fd,E1=ho,k1=Bd,N1=Hd,D1=Gd,R1=qd,T1=Vd,O1=Kd,_1=Zd,P1=Qd,A1=ef,go="DropdownMenu",[I1,RM]=Ye(go,[_d]),Fe=_d(),[j1,nf]=I1(go),rf=e=>{const{__scopeDropdownMenu:t,children:n,dir:r,open:o,defaultOpen:a,onOpenChange:s,modal:i=!0}=e,l=Fe(t),u=d.useRef(null),[m,c]=tt({prop:o,defaultProp:a??!1,onChange:s,caller:go});return f.jsx(j1,{scope:t,triggerId:ke(),triggerRef:u,contentId:ke(),open:m,onOpenChange:c,onOpenToggle:d.useCallback(()=>c(p=>!p),[c]),modal:i,children:f.jsx(b1,{...l,open:m,onOpenChange:c,dir:r,modal:i,children:n})})};rf.displayName=go;var of="DropdownMenuTrigger",af=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,disabled:r=!1,...o}=e,a=nf(of,n),s=Fe(n);return f.jsx(w1,{asChild:!0,...s,children:f.jsx(te.button,{type:"button",id:a.triggerId,"aria-haspopup":"menu","aria-expanded":a.open,"aria-controls":a.open?a.contentId:void 0,"data-state":a.open?"open":"closed","data-disabled":r?"":void 0,disabled:r,...o,ref:Ct(t,a.triggerRef),onPointerDown:K(e.onPointerDown,i=>{!r&&i.button===0&&i.ctrlKey===!1&&(a.onOpenToggle(),a.open||i.preventDefault())}),onKeyDown:K(e.onKeyDown,i=>{r||(["Enter"," "].includes(i.key)&&a.onOpenToggle(),i.key==="ArrowDown"&&a.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(i.key)&&i.preventDefault())})})})});af.displayName=of;var $1="DropdownMenuPortal",sf=e=>{const{__scopeDropdownMenu:t,...n}=e,r=Fe(t);return f.jsx(x1,{...r,...n})};sf.displayName=$1;var cf="DropdownMenuContent",lf=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=nf(cf,n),a=Fe(n),s=d.useRef(!1);return f.jsx(S1,{id:o.contentId,"aria-labelledby":o.triggerId,...a,...r,ref:t,onCloseAutoFocus:K(e.onCloseAutoFocus,i=>{var l;s.current||(l=o.triggerRef.current)==null||l.focus(),s.current=!1,i.preventDefault()}),onInteractOutside:K(e.onInteractOutside,i=>{const l=i.detail.originalEvent,u=l.button===0&&l.ctrlKey===!0,m=l.button===2||u;(!o.modal||m)&&(s.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)"}})});lf.displayName=cf;var L1="DropdownMenuGroup",uf=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Fe(n);return f.jsx(C1,{...o,...r,ref:t})});uf.displayName=L1;var F1="DropdownMenuLabel",df=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Fe(n);return f.jsx(M1,{...o,...r,ref:t})});df.displayName=F1;var W1="DropdownMenuItem",ff=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Fe(n);return f.jsx(E1,{...o,...r,ref:t})});ff.displayName=W1;var B1="DropdownMenuCheckboxItem",mf=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Fe(n);return f.jsx(k1,{...o,...r,ref:t})});mf.displayName=B1;var Y1="DropdownMenuRadioGroup",pf=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Fe(n);return f.jsx(N1,{...o,...r,ref:t})});pf.displayName=Y1;var H1="DropdownMenuRadioItem",hf=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Fe(n);return f.jsx(D1,{...o,...r,ref:t})});hf.displayName=H1;var z1="DropdownMenuItemIndicator",gf=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Fe(n);return f.jsx(R1,{...o,...r,ref:t})});gf.displayName=z1;var G1="DropdownMenuSeparator",vf=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Fe(n);return f.jsx(T1,{...o,...r,ref:t})});vf.displayName=G1;var U1="DropdownMenuArrow",q1=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Fe(n);return f.jsx(O1,{...o,...r,ref:t})});q1.displayName=U1;var V1=e=>{const{__scopeDropdownMenu:t,children:n,open:r,onOpenChange:o,defaultOpen:a}=e,s=Fe(t),[i,l]=tt({prop:r,defaultProp:a??!1,onChange:o,caller:"DropdownMenuSub"});return f.jsx(_1,{...s,open:i,onOpenChange:l,children:n})},K1="DropdownMenuSubTrigger",yf=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Fe(n);return f.jsx(P1,{...o,...r,ref:t})});yf.displayName=K1;var X1="DropdownMenuSubContent",bf=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Fe(n);return f.jsx(A1,{...o,...r,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)"}})});bf.displayName=X1;var Z1=rf,Q1=af,J1=sf,wf=lf,eC=uf,xf=df,Sf=ff,Cf=mf,tC=pf,Mf=hf,Ef=gf,kf=vf,nC=V1,Nf=yf,Df=bf;const rC=Z1,oC=Q1,aC=eC,sC=nC,iC=tC,Rf=d.forwardRef(({className:e,inset:t,children:n,...r},o)=>f.jsxs(Nf,{ref:o,className:q("flex cursor-default select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-none focus:bg-accent data-[state=open]:bg-accent [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",t&&"pl-8",e),...r,children:[n,f.jsx(Bi,{className:"ml-auto"})]}));Rf.displayName=Nf.displayName;const Tf=d.forwardRef(({className:e,...t},n)=>f.jsx(Df,{ref:n,className:q("z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-lg data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-dropdown-menu-content-transform-origin]",e),...t}));Tf.displayName=Df.displayName;const Of=d.forwardRef(({className:e,sideOffset:t=4,...n},r)=>f.jsx(J1,{children:f.jsx(wf,{ref:r,sideOffset:t,className:q("z-50 max-h-[var(--radix-dropdown-menu-content-available-height)] min-w-[8rem] overflow-y-auto overflow-x-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-dropdown-menu-content-transform-origin]",e),...n})}));Of.displayName=wf.displayName;const _f=d.forwardRef(({className:e,inset:t,...n},r)=>f.jsx(Sf,{ref:r,className:q("relative flex cursor-default select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",t&&"pl-8",e),...n}));_f.displayName=Sf.displayName;const Pf=d.forwardRef(({className:e,children:t,checked:n,...r},o)=>f.jsxs(Cf,{ref:o,className:q("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),checked:n,...r,children:[f.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:f.jsx(Ef,{children:f.jsx(Jn,{className:"h-4 w-4"})})}),t]}));Pf.displayName=Cf.displayName;const Af=d.forwardRef(({className:e,children:t,...n},r)=>f.jsxs(Mf,{ref:r,className:q("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...n,children:[f.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:f.jsx(Ef,{children:f.jsx(Yi,{className:"h-2 w-2 fill-current"})})}),t]}));Af.displayName=Mf.displayName;const If=d.forwardRef(({className:e,inset:t,...n},r)=>f.jsx(xf,{ref:r,className:q("px-2 py-1.5 text-sm font-semibold",t&&"pl-8",e),...n}));If.displayName=xf.displayName;const jf=d.forwardRef(({className:e,...t},n)=>f.jsx(kf,{ref:n,className:q("-mx-1 my-1 h-px bg-muted",e),...t}));jf.displayName=kf.displayName;const $f=({className:e,...t})=>f.jsx("span",{className:q("ml-auto text-xs tracking-widest opacity-60",e),...t});$f.displayName="DropdownMenuShortcut";var ms="Radio",[cC,Lf]=Ye(ms),[lC,uC]=cC(ms),Ff=d.forwardRef((e,t)=>{const{__scopeRadio:n,name:r,checked:o=!1,required:a,disabled:s,value:i="on",onCheck:l,form:u,...m}=e,[c,p]=d.useState(null),h=he(t,y=>p(y)),v=d.useRef(!1),g=c?u||!!c.closest("form"):!0;return f.jsxs(lC,{scope:n,checked:o,disabled:s,children:[f.jsx(te.button,{type:"button",role:"radio","aria-checked":o,"data-state":Hf(o),"data-disabled":s?"":void 0,disabled:s,value:i,...m,ref:h,onClick:K(e.onClick,y=>{o||l==null||l(),g&&(v.current=y.isPropagationStopped(),v.current||y.stopPropagation())})}),g&&f.jsx(Yf,{control:c,bubbles:!v.current,name:r,value:i,checked:o,required:a,disabled:s,form:u,style:{transform:"translateX(-100%)"}})]})});Ff.displayName=ms;var Wf="RadioIndicator",Bf=d.forwardRef((e,t)=>{const{__scopeRadio:n,forceMount:r,...o}=e,a=uC(Wf,n);return f.jsx(He,{present:r||a.checked,children:f.jsx(te.span,{"data-state":Hf(a.checked),"data-disabled":a.disabled?"":void 0,...o,ref:t})})});Bf.displayName=Wf;var dC="RadioBubbleInput",Yf=d.forwardRef(({__scopeRadio:e,control:t,checked:n,bubbles:r=!0,...o},a)=>{const s=d.useRef(null),i=he(s,a),l=$a(n),u=Oa(t);return d.useEffect(()=>{const m=s.current;if(!m)return;const c=window.HTMLInputElement.prototype,h=Object.getOwnPropertyDescriptor(c,"checked").set;if(l!==n&&h){const v=new Event("click",{bubbles:r});h.call(m,n),m.dispatchEvent(v)}},[l,n,r]),f.jsx(te.input,{type:"radio","aria-hidden":!0,defaultChecked:n,...o,tabIndex:-1,ref:i,style:{...o.style,...u,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});Yf.displayName=dC;function Hf(e){return e?"checked":"unchecked"}var fC=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],vo="RadioGroup",[mC,TM]=Ye(vo,[On,Lf]),zf=On(),Gf=Lf(),[pC,hC]=mC(vo),Uf=d.forwardRef((e,t)=>{const{__scopeRadioGroup:n,name:r,defaultValue:o,value:a,required:s=!1,disabled:i=!1,orientation:l,dir:u,loop:m=!0,onValueChange:c,...p}=e,h=zf(n),v=ir(u),[g,y]=tt({prop:a,defaultProp:o??null,onChange:c,caller:vo});return f.jsx(pC,{scope:n,name:r,required:s,disabled:i,value:g,onValueChange:y,children:f.jsx(rs,{asChild:!0,...h,orientation:l,dir:v,loop:m,children:f.jsx(te.div,{role:"radiogroup","aria-required":s,"aria-orientation":l,"data-disabled":i?"":void 0,dir:v,...p,ref:t})})})});Uf.displayName=vo;var qf="RadioGroupItem",Vf=d.forwardRef((e,t)=>{const{__scopeRadioGroup:n,disabled:r,...o}=e,a=hC(qf,n),s=a.disabled||r,i=zf(n),l=Gf(n),u=d.useRef(null),m=he(t,u),c=a.value===o.value,p=d.useRef(!1);return d.useEffect(()=>{const h=g=>{fC.includes(g.key)&&(p.current=!0)},v=()=>p.current=!1;return document.addEventListener("keydown",h),document.addEventListener("keyup",v),()=>{document.removeEventListener("keydown",h),document.removeEventListener("keyup",v)}},[]),f.jsx(os,{asChild:!0,...i,focusable:!s,active:c,children:f.jsx(Ff,{disabled:s,required:a.required,checked:c,...l,...o,name:a.name,ref:m,onCheck:()=>a.onValueChange(o.value),onKeyDown:K(h=>{h.key==="Enter"&&h.preventDefault()}),onFocus:K(o.onFocus,()=>{var h;p.current&&((h=u.current)==null||h.click())})})})});Vf.displayName=qf;var gC="RadioGroupIndicator",Kf=d.forwardRef((e,t)=>{const{__scopeRadioGroup:n,...r}=e,o=Gf(n);return f.jsx(Bf,{...o,...r,ref:t})});Kf.displayName=gC;var Xf=Uf,Zf=Vf,vC=Kf;const Qf=d.forwardRef(({className:e,...t},n)=>f.jsx(Xf,{ref:n,className:q("grid gap-2",e),...t}));Qf.displayName=Xf.displayName;const Jf=d.forwardRef(({className:e,...t},n)=>f.jsx(Zf,{ref:n,className:q(`
195
+ aspect-square h-4 w-4 rounded-full border border-primary text-primary ring-offset-background
196
+ focus:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2
197
+ disabled:cursor-not-allowed disabled:opacity-50
198
+ `,e),...t,children:f.jsx(vC,{className:"flex items-center justify-center",children:f.jsx(Yi,{className:"h-2.5 w-2.5 fill-current text-current"})})}));Jf.displayName=Zf.displayName;var yo="Tabs",[yC,OM]=Ye(yo,[On]),em=On(),[bC,ps]=yC(yo),tm=d.forwardRef((e,t)=>{const{__scopeTabs:n,value:r,onValueChange:o,defaultValue:a,orientation:s="horizontal",dir:i,activationMode:l="automatic",...u}=e,m=ir(i),[c,p]=tt({prop:r,onChange:o,defaultProp:a??"",caller:yo});return f.jsx(bC,{scope:n,baseId:ke(),value:c,onValueChange:p,orientation:s,dir:m,activationMode:l,children:f.jsx(te.div,{dir:m,"data-orientation":s,...u,ref:t})})});tm.displayName=yo;var nm="TabsList",rm=d.forwardRef((e,t)=>{const{__scopeTabs:n,loop:r=!0,...o}=e,a=ps(nm,n),s=em(n);return f.jsx(rs,{asChild:!0,...s,orientation:a.orientation,dir:a.dir,loop:r,children:f.jsx(te.div,{role:"tablist","aria-orientation":a.orientation,...o,ref:t})})});rm.displayName=nm;var om="TabsTrigger",am=d.forwardRef((e,t)=>{const{__scopeTabs:n,value:r,disabled:o=!1,...a}=e,s=ps(om,n),i=em(n),l=cm(s.baseId,r),u=lm(s.baseId,r),m=r===s.value;return f.jsx(os,{asChild:!0,...i,focusable:!o,active:m,children:f.jsx(te.button,{type:"button",role:"tab","aria-selected":m,"aria-controls":u,"data-state":m?"active":"inactive","data-disabled":o?"":void 0,disabled:o,id:l,...a,ref:t,onMouseDown:K(e.onMouseDown,c=>{!o&&c.button===0&&c.ctrlKey===!1?s.onValueChange(r):c.preventDefault()}),onKeyDown:K(e.onKeyDown,c=>{[" ","Enter"].includes(c.key)&&s.onValueChange(r)}),onFocus:K(e.onFocus,()=>{const c=s.activationMode!=="manual";!m&&!o&&c&&s.onValueChange(r)})})})});am.displayName=om;var sm="TabsContent",im=d.forwardRef((e,t)=>{const{__scopeTabs:n,value:r,forceMount:o,children:a,...s}=e,i=ps(sm,n),l=cm(i.baseId,r),u=lm(i.baseId,r),m=r===i.value,c=d.useRef(m);return d.useEffect(()=>{const p=requestAnimationFrame(()=>c.current=!1);return()=>cancelAnimationFrame(p)},[]),f.jsx(He,{present:o||m,children:({present:p})=>f.jsx(te.div,{"data-state":m?"active":"inactive","data-orientation":i.orientation,role:"tabpanel","aria-labelledby":l,hidden:!p,id:u,tabIndex:0,...s,ref:t,style:{...e.style,animationDuration:c.current?"0s":void 0},children:p&&a})})});im.displayName=sm;function cm(e,t){return`${e}-trigger-${t}`}function lm(e,t){return`${e}-content-${t}`}var wC=tm,um=rm,dm=am,fm=im;const xC=wC,mm=d.forwardRef(({className:e,...t},n)=>f.jsx(um,{ref:n,className:q("inline-flex h-10 items-center justify-center rounded-md bg-muted p-1 text-muted-foreground",e),...t}));mm.displayName=um.displayName;const pm=d.forwardRef(({className:e,...t},n)=>f.jsx(dm,{ref:n,className:q("inline-flex items-center justify-center whitespace-nowrap rounded-sm px-3 py-1.5 text-sm font-medium ring-offset-background transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-sm",e),...t}));pm.displayName=dm.displayName;const hm=d.forwardRef(({className:e,...t},n)=>f.jsx(fm,{ref:n,className:q("mt-2 ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",e),...t}));hm.displayName=fm.displayName;function SC(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 CC=e=>{switch(e){case"success":return kC;case"info":return DC;case"warning":return NC;case"error":return RC;default:return null}},MC=Array(12).fill(0),EC=({visible:e,className:t})=>b.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},b.createElement("div",{className:"sonner-spinner"},MC.map((n,r)=>b.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${r}`})))),kC=b.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},b.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"})),NC=b.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},b.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"})),DC=b.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},b.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"})),RC=b.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},b.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"})),TC=b.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"},b.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),b.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),OC=()=>{const[e,t]=b.useState(document.hidden);return b.useEffect(()=>{const n=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",n),()=>window.removeEventListener("visibilitychange",n)},[]),e};let ya=1;class _C{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:r,...o}=t,a=typeof(t==null?void 0:t.id)=="number"||((n=t.id)==null?void 0:n.length)>0?t.id:ya++,s=this.toasts.find(l=>l.id===a),i=t.dismissible===void 0?!0:t.dismissible;return this.dismissedToasts.has(a)&&this.dismissedToasts.delete(a),s?this.toasts=this.toasts.map(l=>l.id===a?(this.publish({...l,...t,id:a,title:r}),{...l,...t,id:a,dismissible:i,title:r}):l):this.addToast({title:r,...o,dismissible:i,id:a}),a},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(r=>r({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 r;n.loading!==void 0&&(r=this.create({...n,promise:t,type:"loading",message:n.loading,description:typeof n.description!="function"?n.description:void 0}));const o=Promise.resolve(t instanceof Function?t():t);let a=r!==void 0,s;const i=o.then(async u=>{if(s=["resolve",u],b.isValidElement(u))a=!1,this.create({id:r,type:"default",message:u});else if(AC(u)&&!u.ok){a=!1;const c=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,v=typeof c=="object"&&!b.isValidElement(c)?c:{message:c};this.create({id:r,type:"error",description:p,...v})}else if(u instanceof Error){a=!1;const c=typeof n.error=="function"?await n.error(u):n.error,p=typeof n.description=="function"?await n.description(u):n.description,v=typeof c=="object"&&!b.isValidElement(c)?c:{message:c};this.create({id:r,type:"error",description:p,...v})}else if(n.success!==void 0){a=!1;const c=typeof n.success=="function"?await n.success(u):n.success,p=typeof n.description=="function"?await n.description(u):n.description,v=typeof c=="object"&&!b.isValidElement(c)?c:{message:c};this.create({id:r,type:"success",description:p,...v})}}).catch(async u=>{if(s=["reject",u],n.error!==void 0){a=!1;const m=typeof n.error=="function"?await n.error(u):n.error,c=typeof n.description=="function"?await n.description(u):n.description,h=typeof m=="object"&&!b.isValidElement(m)?m:{message:m};this.create({id:r,type:"error",description:c,...h})}}).finally(()=>{a&&(this.dismiss(r),r=void 0),n.finally==null||n.finally.call(n)}),l=()=>new Promise((u,m)=>i.then(()=>s[0]==="reject"?m(s[1]):u(s[1])).catch(m));return typeof r!="string"&&typeof r!="number"?{unwrap:l}:Object.assign(r,{unwrap:l})},this.custom=(t,n)=>{const r=(n==null?void 0:n.id)||ya++;return this.create({jsx:t(r),id:r,...n}),r},this.getActiveToasts=()=>this.toasts.filter(t=>!this.dismissedToasts.has(t.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}}const qe=new _C,PC=(e,t)=>{const n=(t==null?void 0:t.id)||ya++;return qe.addToast({title:e,...t,id:n}),n},AC=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",IC=PC,jC=()=>qe.toasts,$C=()=>qe.getActiveToasts(),Bn=Object.assign(IC,{success:qe.success,info:qe.info,warning:qe.warning,error:qe.error,custom:qe.custom,message:qe.message,promise:qe.promise,dismiss:qe.dismiss,loading:qe.loading},{getHistory:jC,getToasts:$C});SC("[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;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);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 Dr(e){return e.label!==void 0}const LC=3,FC="24px",WC="16px",wi=4e3,BC=356,YC=14,HC=45,zC=200;function ut(...e){return e.filter(Boolean).join(" ")}function GC(e){const[t,n]=e.split("-"),r=[];return t&&r.push(t),n&&r.push(n),r}const UC=e=>{var t,n,r,o,a,s,i,l,u;const{invert:m,toast:c,unstyled:p,interacting:h,setHeights:v,visibleToasts:g,heights:y,index:w,toasts:x,expanded:S,removeToast:k,defaultRichColors:C,closeButton:N,style:M,cancelButtonStyle:D,actionButtonStyle:L,className:B="",descriptionClassName:F="",duration:V,position:$,gap:I,expandByDefault:_,classNames:R,icons:P,closeButtonAriaLabel:E="Close toast"}=e,[O,Y]=b.useState(null),[G,T]=b.useState(null),[A,W]=b.useState(!1),[H,U]=b.useState(!1),[j,Z]=b.useState(!1),[X,Q]=b.useState(!1),[le,de]=b.useState(!1),[xe,re]=b.useState(0),[ze,We]=b.useState(0),ie=b.useRef(c.duration||V||wi),pe=b.useRef(null),Se=b.useRef(null),je=w===0,Be=w+1<=g,_e=c.type,$e=c.dismissible!==!1,Yt=c.className||"",rn=c.descriptionClassName||"",Nt=b.useMemo(()=>y.findIndex(ne=>ne.toastId===c.id)||0,[y,c.id]),_n=b.useMemo(()=>{var ne;return(ne=c.closeButton)!=null?ne:N},[c.closeButton,N]),bt=b.useMemo(()=>c.duration||V||wi,[c.duration,V]),Ht=b.useRef(0),nt=b.useRef(0),on=b.useRef(0),Ge=b.useRef(null),[an,Pn]=$.split("-"),sn=b.useMemo(()=>y.reduce((ne,ue,ve)=>ve>=Nt?ne:ne+ue.height,0),[y,Nt]),zt=OC(),An=c.invert||m,Dt=_e==="loading";nt.current=b.useMemo(()=>Nt*I+sn,[Nt,sn]),b.useEffect(()=>{ie.current=bt},[bt]),b.useEffect(()=>{W(!0)},[]),b.useEffect(()=>{const ne=Se.current;if(ne){const ue=ne.getBoundingClientRect().height;return We(ue),v(ve=>[{toastId:c.id,height:ue,position:c.position},...ve]),()=>v(ve=>ve.filter(ce=>ce.toastId!==c.id))}},[v,c.id]),b.useLayoutEffect(()=>{if(!A)return;const ne=Se.current,ue=ne.style.height;ne.style.height="auto";const ve=ne.getBoundingClientRect().height;ne.style.height=ue,We(ve),v(ce=>ce.find(be=>be.toastId===c.id)?ce.map(be=>be.toastId===c.id?{...be,height:ve}:be):[{toastId:c.id,height:ve,position:c.position},...ce])},[A,c.title,c.description,v,c.id,c.jsx,c.action,c.cancel]);const z=b.useCallback(()=>{U(!0),re(nt.current),v(ne=>ne.filter(ue=>ue.toastId!==c.id)),setTimeout(()=>{k(c)},zC)},[c,k,v,nt]);b.useEffect(()=>{if(c.promise&&_e==="loading"||c.duration===1/0||c.type==="loading")return;let ne;return S||h||zt?(()=>{if(on.current<Ht.current){const ce=new Date().getTime()-Ht.current;ie.current=ie.current-ce}on.current=new Date().getTime()})():(()=>{ie.current!==1/0&&(Ht.current=new Date().getTime(),ne=setTimeout(()=>{c.onAutoClose==null||c.onAutoClose.call(c,c),z()},ie.current))})(),()=>clearTimeout(ne)},[S,h,c,_e,zt,z]),b.useEffect(()=>{c.delete&&(z(),c.onDismiss==null||c.onDismiss.call(c,c))},[z,c.delete]);function ae(){var ne;if(P!=null&&P.loading){var ue;return b.createElement("div",{className:ut(R==null?void 0:R.loader,c==null||(ue=c.classNames)==null?void 0:ue.loader,"sonner-loader"),"data-visible":_e==="loading"},P.loading)}return b.createElement(EC,{className:ut(R==null?void 0:R.loader,c==null||(ne=c.classNames)==null?void 0:ne.loader),visible:_e==="loading"})}const oe=c.icon||(P==null?void 0:P[_e])||CC(_e);var fe,ge;return b.createElement("li",{tabIndex:0,ref:Se,className:ut(B,Yt,R==null?void 0:R.toast,c==null||(t=c.classNames)==null?void 0:t.toast,R==null?void 0:R.default,R==null?void 0:R[_e],c==null||(n=c.classNames)==null?void 0:n[_e]),"data-sonner-toast":"","data-rich-colors":(fe=c.richColors)!=null?fe:C,"data-styled":!(c.jsx||c.unstyled||p),"data-mounted":A,"data-promise":!!c.promise,"data-swiped":le,"data-removed":H,"data-visible":Be,"data-y-position":an,"data-x-position":Pn,"data-index":w,"data-front":je,"data-swiping":j,"data-dismissible":$e,"data-type":_e,"data-invert":An,"data-swipe-out":X,"data-swipe-direction":G,"data-expanded":!!(S||_&&A),style:{"--index":w,"--toasts-before":w,"--z-index":x.length-w,"--offset":`${H?xe:nt.current}px`,"--initial-height":_?"auto":`${ze}px`,...M,...c.style},onDragEnd:()=>{Z(!1),Y(null),Ge.current=null},onPointerDown:ne=>{ne.button!==2&&(Dt||!$e||(pe.current=new Date,re(nt.current),ne.target.setPointerCapture(ne.pointerId),ne.target.tagName!=="BUTTON"&&(Z(!0),Ge.current={x:ne.clientX,y:ne.clientY})))},onPointerUp:()=>{var ne,ue,ve;if(X||!$e)return;Ge.current=null;const ce=Number(((ne=Se.current)==null?void 0:ne.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),Ue=Number(((ue=Se.current)==null?void 0:ue.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),be=new Date().getTime()-((ve=pe.current)==null?void 0:ve.getTime()),Ce=O==="x"?ce:Ue,Ve=Math.abs(Ce)/be;if(Math.abs(Ce)>=HC||Ve>.11){re(nt.current),c.onDismiss==null||c.onDismiss.call(c,c),T(O==="x"?ce>0?"right":"left":Ue>0?"down":"up"),z(),Q(!0);return}else{var Pe,rt;(Pe=Se.current)==null||Pe.style.setProperty("--swipe-amount-x","0px"),(rt=Se.current)==null||rt.style.setProperty("--swipe-amount-y","0px")}de(!1),Z(!1),Y(null)},onPointerMove:ne=>{var ue,ve,ce;if(!Ge.current||!$e||((ue=window.getSelection())==null?void 0:ue.toString().length)>0)return;const be=ne.clientY-Ge.current.y,Ce=ne.clientX-Ge.current.x;var Ve;const Pe=(Ve=e.swipeDirections)!=null?Ve:GC($);!O&&(Math.abs(Ce)>1||Math.abs(be)>1)&&Y(Math.abs(Ce)>Math.abs(be)?"x":"y");let rt={x:0,y:0};const gs=Gt=>1/(1.5+Math.abs(Gt)/20);if(O==="y"){if(Pe.includes("top")||Pe.includes("bottom"))if(Pe.includes("top")&&be<0||Pe.includes("bottom")&&be>0)rt.y=be;else{const Gt=be*gs(be);rt.y=Math.abs(Gt)<Math.abs(be)?Gt:be}}else if(O==="x"&&(Pe.includes("left")||Pe.includes("right")))if(Pe.includes("left")&&Ce<0||Pe.includes("right")&&Ce>0)rt.x=Ce;else{const Gt=Ce*gs(Ce);rt.x=Math.abs(Gt)<Math.abs(Ce)?Gt:Ce}(Math.abs(rt.x)>0||Math.abs(rt.y)>0)&&de(!0),(ve=Se.current)==null||ve.style.setProperty("--swipe-amount-x",`${rt.x}px`),(ce=Se.current)==null||ce.style.setProperty("--swipe-amount-y",`${rt.y}px`)}},_n&&!c.jsx&&_e!=="loading"?b.createElement("button",{"aria-label":E,"data-disabled":Dt,"data-close-button":!0,onClick:Dt||!$e?()=>{}:()=>{z(),c.onDismiss==null||c.onDismiss.call(c,c)},className:ut(R==null?void 0:R.closeButton,c==null||(r=c.classNames)==null?void 0:r.closeButton)},(ge=P==null?void 0:P.close)!=null?ge:TC):null,(_e||c.icon||c.promise)&&c.icon!==null&&((P==null?void 0:P[_e])!==null||c.icon)?b.createElement("div",{"data-icon":"",className:ut(R==null?void 0:R.icon,c==null||(o=c.classNames)==null?void 0:o.icon)},c.promise||c.type==="loading"&&!c.icon?c.icon||ae():null,c.type!=="loading"?oe:null):null,b.createElement("div",{"data-content":"",className:ut(R==null?void 0:R.content,c==null||(a=c.classNames)==null?void 0:a.content)},b.createElement("div",{"data-title":"",className:ut(R==null?void 0:R.title,c==null||(s=c.classNames)==null?void 0:s.title)},c.jsx?c.jsx:typeof c.title=="function"?c.title():c.title),c.description?b.createElement("div",{"data-description":"",className:ut(F,rn,R==null?void 0:R.description,c==null||(i=c.classNames)==null?void 0:i.description)},typeof c.description=="function"?c.description():c.description):null),b.isValidElement(c.cancel)?c.cancel:c.cancel&&Dr(c.cancel)?b.createElement("button",{"data-button":!0,"data-cancel":!0,style:c.cancelButtonStyle||D,onClick:ne=>{Dr(c.cancel)&&$e&&(c.cancel.onClick==null||c.cancel.onClick.call(c.cancel,ne),z())},className:ut(R==null?void 0:R.cancelButton,c==null||(l=c.classNames)==null?void 0:l.cancelButton)},c.cancel.label):null,b.isValidElement(c.action)?c.action:c.action&&Dr(c.action)?b.createElement("button",{"data-button":!0,"data-action":!0,style:c.actionButtonStyle||L,onClick:ne=>{Dr(c.action)&&(c.action.onClick==null||c.action.onClick.call(c.action,ne),!ne.defaultPrevented&&z())},className:ut(R==null?void 0:R.actionButton,c==null||(u=c.classNames)==null?void 0:u.actionButton)},c.action.label):null)};function xi(){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 qC(e,t){const n={};return[e,t].forEach((r,o)=>{const a=o===1,s=a?"--mobile-offset":"--offset",i=a?WC:FC;function l(u){["top","right","bottom","left"].forEach(m=>{n[`${s}-${m}`]=typeof u=="number"?`${u}px`:u})}typeof r=="number"||typeof r=="string"?l(r):typeof r=="object"?["top","right","bottom","left"].forEach(u=>{r[u]===void 0?n[`${s}-${u}`]=i:n[`${s}-${u}`]=typeof r[u]=="number"?`${r[u]}px`:r[u]}):l(i)}),n}const VC=b.forwardRef(function(t,n){const{invert:r,position:o="bottom-right",hotkey:a=["altKey","KeyT"],expand:s,closeButton:i,className:l,offset:u,mobileOffset:m,theme:c="light",richColors:p,duration:h,style:v,visibleToasts:g=LC,toastOptions:y,dir:w=xi(),gap:x=YC,icons:S,containerAriaLabel:k="Notifications"}=t,[C,N]=b.useState([]),M=b.useMemo(()=>Array.from(new Set([o].concat(C.filter(G=>G.position).map(G=>G.position)))),[C,o]),[D,L]=b.useState([]),[B,F]=b.useState(!1),[V,$]=b.useState(!1),[I,_]=b.useState(c!=="system"?c:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),R=b.useRef(null),P=a.join("+").replace(/Key/g,"").replace(/Digit/g,""),E=b.useRef(null),O=b.useRef(!1),Y=b.useCallback(G=>{N(T=>{var A;return(A=T.find(W=>W.id===G.id))!=null&&A.delete||qe.dismiss(G.id),T.filter(({id:W})=>W!==G.id)})},[]);return b.useEffect(()=>qe.subscribe(G=>{if(G.dismiss){requestAnimationFrame(()=>{N(T=>T.map(A=>A.id===G.id?{...A,delete:!0}:A))});return}setTimeout(()=>{xa.flushSync(()=>{N(T=>{const A=T.findIndex(W=>W.id===G.id);return A!==-1?[...T.slice(0,A),{...T[A],...G},...T.slice(A+1)]:[G,...T]})})})}),[C]),b.useEffect(()=>{if(c!=="system"){_(c);return}if(c==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?_("dark"):_("light")),typeof window>"u")return;const G=window.matchMedia("(prefers-color-scheme: dark)");try{G.addEventListener("change",({matches:T})=>{_(T?"dark":"light")})}catch{G.addListener(({matches:A})=>{try{_(A?"dark":"light")}catch(W){console.error(W)}})}},[c]),b.useEffect(()=>{C.length<=1&&F(!1)},[C]),b.useEffect(()=>{const G=T=>{var A;if(a.every(U=>T[U]||T.code===U)){var H;F(!0),(H=R.current)==null||H.focus()}T.code==="Escape"&&(document.activeElement===R.current||(A=R.current)!=null&&A.contains(document.activeElement))&&F(!1)};return document.addEventListener("keydown",G),()=>document.removeEventListener("keydown",G)},[a]),b.useEffect(()=>{if(R.current)return()=>{E.current&&(E.current.focus({preventScroll:!0}),E.current=null,O.current=!1)}},[R.current]),b.createElement("section",{ref:n,"aria-label":`${k} ${P}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},M.map((G,T)=>{var A;const[W,H]=G.split("-");return C.length?b.createElement("ol",{key:G,dir:w==="auto"?xi():w,tabIndex:-1,ref:R,className:l,"data-sonner-toaster":!0,"data-sonner-theme":I,"data-y-position":W,"data-x-position":H,style:{"--front-toast-height":`${((A=D[0])==null?void 0:A.height)||0}px`,"--width":`${BC}px`,"--gap":`${x}px`,...v,...qC(u,m)},onBlur:U=>{O.current&&!U.currentTarget.contains(U.relatedTarget)&&(O.current=!1,E.current&&(E.current.focus({preventScroll:!0}),E.current=null))},onFocus:U=>{U.target instanceof HTMLElement&&U.target.dataset.dismissible==="false"||O.current||(O.current=!0,E.current=U.relatedTarget)},onMouseEnter:()=>F(!0),onMouseMove:()=>F(!0),onMouseLeave:()=>{V||F(!1)},onDragEnd:()=>F(!1),onPointerDown:U=>{U.target instanceof HTMLElement&&U.target.dataset.dismissible==="false"||$(!0)},onPointerUp:()=>$(!1)},C.filter(U=>!U.position&&T===0||U.position===G).map((U,j)=>{var Z,X;return b.createElement(UC,{key:U.id,icons:S,index:j,toast:U,defaultRichColors:p,duration:(Z=y==null?void 0:y.duration)!=null?Z:h,className:y==null?void 0:y.className,descriptionClassName:y==null?void 0:y.descriptionClassName,invert:r,visibleToasts:g,closeButton:(X=y==null?void 0:y.closeButton)!=null?X:i,interacting:V,position:G,style:y==null?void 0:y.style,unstyled:y==null?void 0:y.unstyled,classNames:y==null?void 0:y.classNames,cancelButtonStyle:y==null?void 0:y.cancelButtonStyle,actionButtonStyle:y==null?void 0:y.actionButtonStyle,closeButtonAriaLabel:y==null?void 0:y.closeButtonAriaLabel,removeToast:Y,toasts:C.filter(Q=>Q.position==U.position),heights:D.filter(Q=>Q.position==U.position),setHeights:L,expandByDefault:s,gap:x,expanded:B,swipeDirections:t.swipeDirections})})):null}))}),KC={error:{background:"#ef4444",color:"#fff"},info:{background:"#2563eb",color:"#fff"},warning:{background:"#f59e42",color:"#fff"},success:{background:"#22c55e",color:"#fff"}},XC={error:5e3,info:4e3,warning:5e3,success:4e3},ZC=(e,t)=>{const n=(t==null?void 0:t.variant)||"info",r={display:"flex",alignItems:"center",gap:"0.5rem",padding:"0.5rem 0.75rem",borderRadius:"0.375rem",...KC[n],...t==null?void 0:t.style},o=(t==null?void 0:t.duration)??XC[n],a=f.jsxs("div",{className:"flex items-center w-full",children:[f.jsxs("div",{className:"flex-1 space-y-1",children:[f.jsx("h3",{className:"text-sm font-medium text-white",children:e}),(t==null?void 0:t.description)&&f.jsx("p",{className:"text-sm text-gray-200",children:t.description})]}),f.jsx(En,{className:"w-4 h-4 ml-8 cursor-pointer text-white transition-opacity hover:opacity-80 active:opacity-60",strokeWidth:3,onClick:()=>Bn.dismiss()})]}),s={unstyled:!0,duration:o,style:r};switch(n){case"success":return Bn.success(a,s);case"error":return Bn.error(a,s);case"warning":return Bn.warning(a,s);case"info":default:return Bn(a,s)}};function QC(e){return f.jsx(VC,{...e})}var[bo,_M]=Ye("Tooltip",[$t]),wo=$t(),gm="TooltipProvider",JC=700,ba="tooltip.open",[eM,hs]=bo(gm),vm=e=>{const{__scopeTooltip:t,delayDuration:n=JC,skipDelayDuration:r=300,disableHoverableContent:o=!1,children:a}=e,s=d.useRef(!0),i=d.useRef(!1),l=d.useRef(0);return d.useEffect(()=>{const u=l.current;return()=>window.clearTimeout(u)},[]),f.jsx(eM,{scope:t,isOpenDelayedRef:s,delayDuration:n,onOpen:d.useCallback(()=>{window.clearTimeout(l.current),s.current=!1},[]),onClose:d.useCallback(()=>{window.clearTimeout(l.current),l.current=window.setTimeout(()=>s.current=!0,r)},[r]),isPointerInTransitRef:i,onPointerInTransitChange:d.useCallback(u=>{i.current=u},[]),disableHoverableContent:o,children:a})};vm.displayName=gm;var Qn="Tooltip",[tM,xo]=bo(Qn),ym=e=>{const{__scopeTooltip:t,children:n,open:r,defaultOpen:o,onOpenChange:a,disableHoverableContent:s,delayDuration:i}=e,l=hs(Qn,e.__scopeTooltip),u=wo(t),[m,c]=d.useState(null),p=ke(),h=d.useRef(0),v=s??l.disableHoverableContent,g=i??l.delayDuration,y=d.useRef(!1),[w,x]=tt({prop:r,defaultProp:o??!1,onChange:M=>{M?(l.onOpen(),document.dispatchEvent(new CustomEvent(ba))):l.onClose(),a==null||a(M)},caller:Qn}),S=d.useMemo(()=>w?y.current?"delayed-open":"instant-open":"closed",[w]),k=d.useCallback(()=>{window.clearTimeout(h.current),h.current=0,y.current=!1,x(!0)},[x]),C=d.useCallback(()=>{window.clearTimeout(h.current),h.current=0,x(!1)},[x]),N=d.useCallback(()=>{window.clearTimeout(h.current),h.current=window.setTimeout(()=>{y.current=!0,x(!0),h.current=0},g)},[g,x]);return d.useEffect(()=>()=>{h.current&&(window.clearTimeout(h.current),h.current=0)},[]),f.jsx(nr,{...u,children:f.jsx(tM,{scope:t,contentId:p,open:w,stateAttribute:S,trigger:m,onTriggerChange:c,onTriggerEnter:d.useCallback(()=>{l.isOpenDelayedRef.current?N():k()},[l.isOpenDelayedRef,N,k]),onTriggerLeave:d.useCallback(()=>{v?C():(window.clearTimeout(h.current),h.current=0)},[C,v]),onOpen:k,onClose:C,disableHoverableContent:v,children:n})})};ym.displayName=Qn;var wa="TooltipTrigger",bm=d.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=xo(wa,n),a=hs(wa,n),s=wo(n),i=d.useRef(null),l=he(t,i,o.onTriggerChange),u=d.useRef(!1),m=d.useRef(!1),c=d.useCallback(()=>u.current=!1,[]);return d.useEffect(()=>()=>document.removeEventListener("pointerup",c),[c]),f.jsx(rr,{asChild:!0,...s,children:f.jsx(te.button,{"aria-describedby":o.open?o.contentId:void 0,"data-state":o.stateAttribute,...r,ref:l,onPointerMove:K(e.onPointerMove,p=>{p.pointerType!=="touch"&&!m.current&&!a.isPointerInTransitRef.current&&(o.onTriggerEnter(),m.current=!0)}),onPointerLeave:K(e.onPointerLeave,()=>{o.onTriggerLeave(),m.current=!1}),onPointerDown:K(e.onPointerDown,()=>{o.open&&o.onClose(),u.current=!0,document.addEventListener("pointerup",c,{once:!0})}),onFocus:K(e.onFocus,()=>{u.current||o.onOpen()}),onBlur:K(e.onBlur,o.onClose),onClick:K(e.onClick,o.onClose)})})});bm.displayName=wa;var nM="TooltipPortal",[PM,rM]=bo(nM,{forceMount:void 0}),xn="TooltipContent",wm=d.forwardRef((e,t)=>{const n=rM(xn,e.__scopeTooltip),{forceMount:r=n.forceMount,side:o="top",...a}=e,s=xo(xn,e.__scopeTooltip);return f.jsx(He,{present:r||s.open,children:s.disableHoverableContent?f.jsx(xm,{side:o,...a,ref:t}):f.jsx(oM,{side:o,...a,ref:t})})}),oM=d.forwardRef((e,t)=>{const n=xo(xn,e.__scopeTooltip),r=hs(xn,e.__scopeTooltip),o=d.useRef(null),a=he(t,o),[s,i]=d.useState(null),{trigger:l,onClose:u}=n,m=o.current,{onPointerInTransitChange:c}=r,p=d.useCallback(()=>{i(null),c(!1)},[c]),h=d.useCallback((v,g)=>{const y=v.currentTarget,w={x:v.clientX,y:v.clientY},x=lM(w,y.getBoundingClientRect()),S=uM(w,x),k=dM(g.getBoundingClientRect()),C=mM([...S,...k]);i(C),c(!0)},[c]);return d.useEffect(()=>()=>p(),[p]),d.useEffect(()=>{if(l&&m){const v=y=>h(y,m),g=y=>h(y,l);return l.addEventListener("pointerleave",v),m.addEventListener("pointerleave",g),()=>{l.removeEventListener("pointerleave",v),m.removeEventListener("pointerleave",g)}}},[l,m,h,p]),d.useEffect(()=>{if(s){const v=g=>{const y=g.target,w={x:g.clientX,y:g.clientY},x=(l==null?void 0:l.contains(y))||(m==null?void 0:m.contains(y)),S=!fM(w,s);x?p():S&&(p(),u())};return document.addEventListener("pointermove",v),()=>document.removeEventListener("pointermove",v)}},[l,m,s,u,p]),f.jsx(xm,{...e,ref:a})}),[aM,sM]=bo(Qn,{isInside:!1}),iM=Nm("TooltipContent"),xm=d.forwardRef((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":o,onEscapeKeyDown:a,onPointerDownOutside:s,...i}=e,l=xo(xn,n),u=wo(n),{onClose:m}=l;return d.useEffect(()=>(document.addEventListener(ba,m),()=>document.removeEventListener(ba,m)),[m]),d.useEffect(()=>{if(l.trigger){const c=p=>{const h=p.target;h!=null&&h.contains(l.trigger)&&m()};return window.addEventListener("scroll",c,{capture:!0}),()=>window.removeEventListener("scroll",c,{capture:!0})}},[l.trigger,m]),f.jsx(kn,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:a,onPointerDownOutside:s,onFocusOutside:c=>c.preventDefault(),onDismiss:m,children:f.jsxs(Jr,{"data-state":l.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:[f.jsx(iM,{children:r}),f.jsx(aM,{scope:n,isInside:!0,children:f.jsx(Fv,{id:l.contentId,role:"tooltip",children:o||r})})]})})});wm.displayName=xn;var Sm="TooltipArrow",cM=d.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=wo(n);return sM(Sm,n).isInside?null:f.jsx(eo,{...o,...r,ref:t})});cM.displayName=Sm;function lM(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),o=Math.abs(t.right-e.x),a=Math.abs(t.left-e.x);switch(Math.min(n,r,o,a)){case a:return"left";case o:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function uM(e,t,n=5){const r=[];switch(t){case"top":r.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":r.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":r.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":r.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n});break}return r}function dM(e){const{top:t,right:n,bottom:r,left:o}=e;return[{x:o,y:t},{x:n,y:t},{x:n,y:r},{x:o,y:r}]}function fM(e,t){const{x:n,y:r}=e;let o=!1;for(let a=0,s=t.length-1;a<t.length;s=a++){const i=t[a],l=t[s],u=i.x,m=i.y,c=l.x,p=l.y;m>r!=p>r&&n<(c-u)*(r-m)/(p-m)+u&&(o=!o)}return o}function mM(e){const t=e.slice();return t.sort((n,r)=>n.x<r.x?-1:n.x>r.x?1:n.y<r.y?-1:n.y>r.y?1:0),pM(t)}function pM(e){if(e.length<=1)return e.slice();const t=[];for(let r=0;r<e.length;r++){const o=e[r];for(;t.length>=2;){const a=t[t.length-1],s=t[t.length-2];if((a.x-s.x)*(o.y-s.y)>=(a.y-s.y)*(o.x-s.x))t.pop();else break}t.push(o)}t.pop();const n=[];for(let r=e.length-1;r>=0;r--){const o=e[r];for(;n.length>=2;){const a=n[n.length-1],s=n[n.length-2];if((a.x-s.x)*(o.y-s.y)>=(a.y-s.y)*(o.x-s.x))n.pop();else break}n.push(o)}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 hM=vm,gM=ym,vM=bm,Cm=wm;const yM=hM,bM=gM,wM=vM,Mm=d.forwardRef(({className:e,sideOffset:t=4,...n},r)=>f.jsx(Cm,{ref:r,sideOffset:t,className:q("z-50 overflow-hidden rounded-md border bg-popover px-3 py-1.5 text-sm text-popover-foreground shadow-md animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-tooltip-content-transform-origin]",e),...n}));Mm.displayName=Cm.displayName;exports.AddressFormSection=jx;exports.Alert=Bu;exports.AutoComplete=N0;exports.Avatar=Zu;exports.AvatarFallback=Ju;exports.AvatarImage=Qu;exports.Checkbox=id;exports.ComponentSection=D0;exports.ContactFormSection=Lx;exports.CurrencyInput=Pu;exports.DatePickerField=Hr;exports.Dialog=y0;exports.DialogClose=x0;exports.DialogContent=Mu;exports.DialogDescription=Du;exports.DialogFooter=ku;exports.DialogHeader=Eu;exports.DialogTitle=Nu;exports.DialogTrigger=b0;exports.DoctAnimationLoader=pp;exports.DoctAutocomplete=I0;exports.DoctButton=Kt;exports.DoctButtonVariants=ji;exports.DoctChip=Nx;exports.DoctTypography=mp;exports.Drawer=bd;exports.DrawerClose=IS;exports.DrawerContent=xd;exports.DrawerDescription=Ed;exports.DrawerFooter=Cd;exports.DrawerHeader=Sd;exports.DrawerTitle=Md;exports.DrawerTrigger=PS;exports.DropdownMenu=rC;exports.DropdownMenuCheckboxItem=Pf;exports.DropdownMenuContent=Of;exports.DropdownMenuGroup=aC;exports.DropdownMenuItem=_f;exports.DropdownMenuLabel=If;exports.DropdownMenuRadioGroup=iC;exports.DropdownMenuRadioItem=Af;exports.DropdownMenuSeparator=jf;exports.DropdownMenuShortcut=$f;exports.DropdownMenuSub=sC;exports.DropdownMenuSubContent=Tf;exports.DropdownMenuSubTrigger=Rf;exports.DropdownMenuTrigger=oC;exports.ExpandableCard=Y0;exports.LabeledInput=Qe;exports.OtpInput=yp;exports.PasswordInput=Zo;exports.Popover=jc;exports.PopoverContent=Ia;exports.PopoverTrigger=$c;exports.RadioGroup=Qf;exports.RadioGroupItem=Jf;exports.SearchFilterSection=_x;exports.SearchInput=Zl;exports.SelectField=wn;exports.Tabs=xC;exports.TabsContent=hm;exports.TabsList=mm;exports.TabsTrigger=pm;exports.TextareaField=Ui;exports.Toaster=QC;exports.Tooltip=bM;exports.TooltipContent=Mm;exports.TooltipProvider=yM;exports.TooltipTrigger=wM;exports.UserRegistrationSection=Ax;exports.toast=ZC;