@memoreco/ui 0.2.10 → 0.2.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.js CHANGED
@@ -1,4 +1,4 @@
1
- "use strict";var rc=Object.defineProperty;var nc=(e,t,r)=>t in e?rc(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var Je=(e,t,r)=>nc(e,typeof t!="symbol"?t+"":t,r);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const m=require("react/jsx-runtime"),E=require("react"),ir=require("react-dom");function ts(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const r in e)if(r!=="default"){const n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:()=>e[r]})}}return t.default=e,Object.freeze(t)}const f=ts(E),ar=ts(ir);function $n(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function rs(...e){return t=>{let r=!1;const n=e.map(o=>{const s=$n(o,t);return!r&&typeof s=="function"&&(r=!0),s});if(r)return()=>{for(let o=0;o<n.length;o++){const s=n[o];typeof s=="function"?s():$n(e[o],null)}}}}function ee(...e){return f.useCallback(rs(...e),e)}function bt(e){const t=sc(e),r=f.forwardRef((n,o)=>{const{children:s,...i}=n,a=f.Children.toArray(s),c=a.find(ac);if(c){const l=c.props.children,u=a.map(d=>d===c?f.Children.count(l)>1?f.Children.only(null):f.isValidElement(l)?l.props.children:null:d);return m.jsx(t,{...i,ref:o,children:f.isValidElement(l)?f.cloneElement(l,void 0,u):null})}return m.jsx(t,{...i,ref:o,children:s})});return r.displayName=`${e}.Slot`,r}var oc=bt("Slot");function sc(e){const t=f.forwardRef((r,n)=>{const{children:o,...s}=r;if(f.isValidElement(o)){const i=cc(o),a=lc(s,o.props);return o.type!==f.Fragment&&(a.ref=n?rs(n,i):i),f.cloneElement(o,a)}return f.Children.count(o)>1?f.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var ns=Symbol("radix.slottable");function ic(e){const t=({children:r})=>m.jsx(m.Fragment,{children:r});return t.displayName=`${e}.Slottable`,t.__radixId=ns,t}function ac(e){return f.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===ns}function lc(e,t){const r={...t};for(const n in t){const o=e[n],s=t[n];/^on[A-Z]/.test(n)?o&&s?r[n]=(...a)=>{const c=s(...a);return o(...a),c}:o&&(r[n]=o):n==="style"?r[n]={...o,...s}:n==="className"&&(r[n]=[o,s].filter(Boolean).join(" "))}return{...e,...r}}function cc(e){var n,o;let t=(n=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:n.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}function os(e){var t,r,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(r=os(e[t]))&&(n&&(n+=" "),n+=r)}else for(r in e)e[r]&&(n&&(n+=" "),n+=r);return n}function Zr(){for(var e,t,r=0,n="",o=arguments.length;r<o;r++)(e=arguments[r])&&(t=os(e))&&(n&&(n+=" "),n+=t);return n}const zn=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,Bn=Zr,Ot=(e,t)=>r=>{var n;if((t==null?void 0:t.variants)==null)return Bn(e,r==null?void 0:r.class,r==null?void 0:r.className);const{variants:o,defaultVariants:s}=t,i=Object.keys(o).map(l=>{const u=r==null?void 0:r[l],d=s==null?void 0:s[l];if(u===null)return null;const p=zn(u)||zn(d);return o[l][p]}),a=r&&Object.entries(r).reduce((l,u)=>{let[d,p]=u;return p===void 0||(l[d]=p),l},{}),c=t==null||(n=t.compoundVariants)===null||n===void 0?void 0:n.reduce((l,u)=>{let{class:d,className:p,...g}=u;return Object.entries(g).every(v=>{let[h,b]=v;return Array.isArray(b)?b.includes({...s,...a}[h]):{...s,...a}[h]===b})?[...l,d,p]:l},[]);return Bn(e,i,c,r==null?void 0:r.class,r==null?void 0:r.className)},Qr="-",dc=e=>{const t=fc(e),{conflictingClassGroups:r,conflictingClassGroupModifiers:n}=e;return{getClassGroupId:i=>{const a=i.split(Qr);return a[0]===""&&a.length!==1&&a.shift(),ss(a,t)||uc(i)},getConflictingClassGroupIds:(i,a)=>{const c=r[i]||[];return a&&n[i]?[...c,...n[i]]:c}}},ss=(e,t)=>{var i;if(e.length===0)return t.classGroupId;const r=e[0],n=t.nextPart.get(r),o=n?ss(e.slice(1),n):void 0;if(o)return o;if(t.validators.length===0)return;const s=e.join(Qr);return(i=t.validators.find(({validator:a})=>a(s)))==null?void 0:i.classGroupId},Fn=/^\[(.+)\]$/,uc=e=>{if(Fn.test(e)){const t=Fn.exec(e)[1],r=t==null?void 0:t.substring(0,t.indexOf(":"));if(r)return"arbitrary.."+r}},fc=e=>{const{theme:t,prefix:r}=e,n={nextPart:new Map,validators:[]};return hc(Object.entries(e.classGroups),r).forEach(([s,i])=>{Lr(i,n,s,t)}),n},Lr=(e,t,r,n)=>{e.forEach(o=>{if(typeof o=="string"){const s=o===""?t:Vn(t,o);s.classGroupId=r;return}if(typeof o=="function"){if(pc(o)){Lr(o(n),t,r,n);return}t.validators.push({validator:o,classGroupId:r});return}Object.entries(o).forEach(([s,i])=>{Lr(i,Vn(t,s),r,n)})})},Vn=(e,t)=>{let r=e;return t.split(Qr).forEach(n=>{r.nextPart.has(n)||r.nextPart.set(n,{nextPart:new Map,validators:[]}),r=r.nextPart.get(n)}),r},pc=e=>e.isThemeGetter,hc=(e,t)=>t?e.map(([r,n])=>{const o=n.map(s=>typeof s=="string"?t+s:typeof s=="object"?Object.fromEntries(Object.entries(s).map(([i,a])=>[t+i,a])):s);return[r,o]}):e,mc=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,r=new Map,n=new Map;const o=(s,i)=>{r.set(s,i),t++,t>e&&(t=0,n=r,r=new Map)};return{get(s){let i=r.get(s);if(i!==void 0)return i;if((i=n.get(s))!==void 0)return o(s,i),i},set(s,i){r.has(s)?r.set(s,i):o(s,i)}}},is="!",gc=e=>{const{separator:t,experimentalParseClassName:r}=e,n=t.length===1,o=t[0],s=t.length,i=a=>{const c=[];let l=0,u=0,d;for(let b=0;b<a.length;b++){let y=a[b];if(l===0){if(y===o&&(n||a.slice(b,b+s)===t)){c.push(a.slice(u,b)),u=b+s;continue}if(y==="/"){d=b;continue}}y==="["?l++:y==="]"&&l--}const p=c.length===0?a:a.substring(u),g=p.startsWith(is),v=g?p.substring(1):p,h=d&&d>u?d-u:void 0;return{modifiers:c,hasImportantModifier:g,baseClassName:v,maybePostfixModifierPosition:h}};return r?a=>r({className:a,parseClassName:i}):i},vc=e=>{if(e.length<=1)return e;const t=[];let r=[];return e.forEach(n=>{n[0]==="["?(t.push(...r.sort(),n),r=[]):r.push(n)}),t.push(...r.sort()),t},yc=e=>({cache:mc(e.cacheSize),parseClassName:gc(e),...dc(e)}),bc=/\s+/,xc=(e,t)=>{const{parseClassName:r,getClassGroupId:n,getConflictingClassGroupIds:o}=t,s=[],i=e.trim().split(bc);let a="";for(let c=i.length-1;c>=0;c-=1){const l=i[c],{modifiers:u,hasImportantModifier:d,baseClassName:p,maybePostfixModifierPosition:g}=r(l);let v=!!g,h=n(v?p.substring(0,g):p);if(!h){if(!v){a=l+(a.length>0?" "+a:a);continue}if(h=n(p),!h){a=l+(a.length>0?" "+a:a);continue}v=!1}const b=vc(u).join(":"),y=d?b+is:b,x=y+h;if(s.includes(x))continue;s.push(x);const w=o(h,v);for(let C=0;C<w.length;++C){const S=w[C];s.push(y+S)}a=l+(a.length>0?" "+a:a)}return a};function wc(){let e=0,t,r,n="";for(;e<arguments.length;)(t=arguments[e++])&&(r=as(t))&&(n&&(n+=" "),n+=r);return n}const as=e=>{if(typeof e=="string")return e;let t,r="";for(let n=0;n<e.length;n++)e[n]&&(t=as(e[n]))&&(r&&(r+=" "),r+=t);return r};function Cc(e,...t){let r,n,o,s=i;function i(c){const l=t.reduce((u,d)=>d(u),e());return r=yc(l),n=r.cache.get,o=r.cache.set,s=a,a(c)}function a(c){const l=n(c);if(l)return l;const u=xc(c,r);return o(c,u),u}return function(){return s(wc.apply(null,arguments))}}const te=e=>{const t=r=>r[e]||[];return t.isThemeGetter=!0,t},ls=/^\[(?:([a-z-]+):)?(.+)\]$/i,Sc=/^\d+\/\d+$/,Ec=new Set(["px","full","screen"]),Rc=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,Ac=/\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$/,Nc=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,Pc=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,Tc=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Oe=e=>mt(e)||Ec.has(e)||Sc.test(e),Fe=e=>wt(e,"length",Lc),mt=e=>!!e&&!Number.isNaN(Number(e)),Nr=e=>wt(e,"number",mt),Pt=e=>!!e&&Number.isInteger(Number(e)),kc=e=>e.endsWith("%")&&mt(e.slice(0,-1)),H=e=>ls.test(e),Ve=e=>Rc.test(e),Dc=new Set(["length","size","percentage"]),Mc=e=>wt(e,Dc,cs),Ic=e=>wt(e,"position",cs),Oc=new Set(["image","url"]),_c=e=>wt(e,Oc,zc),jc=e=>wt(e,"",$c),Tt=()=>!0,wt=(e,t,r)=>{const n=ls.exec(e);return n?n[1]?typeof t=="string"?n[1]===t:t.has(n[1]):r(n[2]):!1},Lc=e=>Ac.test(e)&&!Nc.test(e),cs=()=>!1,$c=e=>Pc.test(e),zc=e=>Tc.test(e),Bc=()=>{const e=te("colors"),t=te("spacing"),r=te("blur"),n=te("brightness"),o=te("borderColor"),s=te("borderRadius"),i=te("borderSpacing"),a=te("borderWidth"),c=te("contrast"),l=te("grayscale"),u=te("hueRotate"),d=te("invert"),p=te("gap"),g=te("gradientColorStops"),v=te("gradientColorStopPositions"),h=te("inset"),b=te("margin"),y=te("opacity"),x=te("padding"),w=te("saturate"),C=te("scale"),S=te("sepia"),A=te("skew"),R=te("space"),O=te("translate"),$=()=>["auto","contain","none"],L=()=>["auto","hidden","clip","visible","scroll"],k=()=>["auto",H,t],P=()=>[H,t],_=()=>["",Oe,Fe],I=()=>["auto",mt,H],D=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],N=()=>["solid","dashed","dotted","double","none"],M=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],T=()=>["start","end","center","between","around","evenly","stretch"],j=()=>["","0",H],U=()=>["auto","avoid","all","avoid-page","page","left","right","column"],V=()=>[mt,H];return{cacheSize:500,separator:":",theme:{colors:[Tt],spacing:[Oe,Fe],blur:["none","",Ve,H],brightness:V(),borderColor:[e],borderRadius:["none","","full",Ve,H],borderSpacing:P(),borderWidth:_(),contrast:V(),grayscale:j(),hueRotate:V(),invert:j(),gap:P(),gradientColorStops:[e],gradientColorStopPositions:[kc,Fe],inset:k(),margin:k(),opacity:V(),padding:P(),saturate:V(),scale:V(),sepia:j(),skew:V(),space:P(),translate:P()},classGroups:{aspect:[{aspect:["auto","square","video",H]}],container:["container"],columns:[{columns:[Ve]}],"break-after":[{"break-after":U()}],"break-before":[{"break-before":U()}],"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"],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:[...D(),H]}],overflow:[{overflow:L()}],"overflow-x":[{"overflow-x":L()}],"overflow-y":[{"overflow-y":L()}],overscroll:[{overscroll:$()}],"overscroll-x":[{"overscroll-x":$()}],"overscroll-y":[{"overscroll-y":$()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[h]}],"inset-x":[{"inset-x":[h]}],"inset-y":[{"inset-y":[h]}],start:[{start:[h]}],end:[{end:[h]}],top:[{top:[h]}],right:[{right:[h]}],bottom:[{bottom:[h]}],left:[{left:[h]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",Pt,H]}],basis:[{basis:k()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",H]}],grow:[{grow:j()}],shrink:[{shrink:j()}],order:[{order:["first","last","none",Pt,H]}],"grid-cols":[{"grid-cols":[Tt]}],"col-start-end":[{col:["auto",{span:["full",Pt,H]},H]}],"col-start":[{"col-start":I()}],"col-end":[{"col-end":I()}],"grid-rows":[{"grid-rows":[Tt]}],"row-start-end":[{row:["auto",{span:[Pt,H]},H]}],"row-start":[{"row-start":I()}],"row-end":[{"row-end":I()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",H]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",H]}],gap:[{gap:[p]}],"gap-x":[{"gap-x":[p]}],"gap-y":[{"gap-y":[p]}],"justify-content":[{justify:["normal",...T()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...T(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...T(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[x]}],px:[{px:[x]}],py:[{py:[x]}],ps:[{ps:[x]}],pe:[{pe:[x]}],pt:[{pt:[x]}],pr:[{pr:[x]}],pb:[{pb:[x]}],pl:[{pl:[x]}],m:[{m:[b]}],mx:[{mx:[b]}],my:[{my:[b]}],ms:[{ms:[b]}],me:[{me:[b]}],mt:[{mt:[b]}],mr:[{mr:[b]}],mb:[{mb:[b]}],ml:[{ml:[b]}],"space-x":[{"space-x":[R]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[R]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",H,t]}],"min-w":[{"min-w":[H,t,"min","max","fit"]}],"max-w":[{"max-w":[H,t,"none","full","min","max","fit","prose",{screen:[Ve]},Ve]}],h:[{h:[H,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[H,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[H,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[H,t,"auto","min","max","fit"]}],"font-size":[{text:["base",Ve,Fe]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",Nr]}],"font-family":[{font:[Tt]}],"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:["tighter","tight","normal","wide","wider","widest",H]}],"line-clamp":[{"line-clamp":["none",mt,Nr]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Oe,H]}],"list-image":[{"list-image":["none",H]}],"list-style-type":[{list:["none","disc","decimal",H]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[y]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[y]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...N(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Oe,Fe]}],"underline-offset":[{"underline-offset":["auto",Oe,H]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:P()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",H]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",H]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[y]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...D(),Ic]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",Mc]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},_c]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[v]}],"gradient-via-pos":[{via:[v]}],"gradient-to-pos":[{to:[v]}],"gradient-from":[{from:[g]}],"gradient-via":[{via:[g]}],"gradient-to":[{to:[g]}],rounded:[{rounded:[s]}],"rounded-s":[{"rounded-s":[s]}],"rounded-e":[{"rounded-e":[s]}],"rounded-t":[{"rounded-t":[s]}],"rounded-r":[{"rounded-r":[s]}],"rounded-b":[{"rounded-b":[s]}],"rounded-l":[{"rounded-l":[s]}],"rounded-ss":[{"rounded-ss":[s]}],"rounded-se":[{"rounded-se":[s]}],"rounded-ee":[{"rounded-ee":[s]}],"rounded-es":[{"rounded-es":[s]}],"rounded-tl":[{"rounded-tl":[s]}],"rounded-tr":[{"rounded-tr":[s]}],"rounded-br":[{"rounded-br":[s]}],"rounded-bl":[{"rounded-bl":[s]}],"border-w":[{border:[a]}],"border-w-x":[{"border-x":[a]}],"border-w-y":[{"border-y":[a]}],"border-w-s":[{"border-s":[a]}],"border-w-e":[{"border-e":[a]}],"border-w-t":[{"border-t":[a]}],"border-w-r":[{"border-r":[a]}],"border-w-b":[{"border-b":[a]}],"border-w-l":[{"border-l":[a]}],"border-opacity":[{"border-opacity":[y]}],"border-style":[{border:[...N(),"hidden"]}],"divide-x":[{"divide-x":[a]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[a]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[y]}],"divide-style":[{divide:N()}],"border-color":[{border:[o]}],"border-color-x":[{"border-x":[o]}],"border-color-y":[{"border-y":[o]}],"border-color-s":[{"border-s":[o]}],"border-color-e":[{"border-e":[o]}],"border-color-t":[{"border-t":[o]}],"border-color-r":[{"border-r":[o]}],"border-color-b":[{"border-b":[o]}],"border-color-l":[{"border-l":[o]}],"divide-color":[{divide:[o]}],"outline-style":[{outline:["",...N()]}],"outline-offset":[{"outline-offset":[Oe,H]}],"outline-w":[{outline:[Oe,Fe]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:_()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[y]}],"ring-offset-w":[{"ring-offset":[Oe,Fe]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",Ve,jc]}],"shadow-color":[{shadow:[Tt]}],opacity:[{opacity:[y]}],"mix-blend":[{"mix-blend":[...M(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":M()}],filter:[{filter:["","none"]}],blur:[{blur:[r]}],brightness:[{brightness:[n]}],contrast:[{contrast:[c]}],"drop-shadow":[{"drop-shadow":["","none",Ve,H]}],grayscale:[{grayscale:[l]}],"hue-rotate":[{"hue-rotate":[u]}],invert:[{invert:[d]}],saturate:[{saturate:[w]}],sepia:[{sepia:[S]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[r]}],"backdrop-brightness":[{"backdrop-brightness":[n]}],"backdrop-contrast":[{"backdrop-contrast":[c]}],"backdrop-grayscale":[{"backdrop-grayscale":[l]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[u]}],"backdrop-invert":[{"backdrop-invert":[d]}],"backdrop-opacity":[{"backdrop-opacity":[y]}],"backdrop-saturate":[{"backdrop-saturate":[w]}],"backdrop-sepia":[{"backdrop-sepia":[S]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[i]}],"border-spacing-x":[{"border-spacing-x":[i]}],"border-spacing-y":[{"border-spacing-y":[i]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",H]}],duration:[{duration:V()}],ease:[{ease:["linear","in","out","in-out",H]}],delay:[{delay:V()}],animate:[{animate:["none","spin","ping","pulse","bounce",H]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[C]}],"scale-x":[{"scale-x":[C]}],"scale-y":[{"scale-y":[C]}],rotate:[{rotate:[Pt,H]}],"translate-x":[{"translate-x":[O]}],"translate-y":[{"translate-y":[O]}],"skew-x":[{"skew-x":[A]}],"skew-y":[{"skew-y":[A]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",H]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],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]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":P()}],"scroll-mx":[{"scroll-mx":P()}],"scroll-my":[{"scroll-my":P()}],"scroll-ms":[{"scroll-ms":P()}],"scroll-me":[{"scroll-me":P()}],"scroll-mt":[{"scroll-mt":P()}],"scroll-mr":[{"scroll-mr":P()}],"scroll-mb":[{"scroll-mb":P()}],"scroll-ml":[{"scroll-ml":P()}],"scroll-p":[{"scroll-p":P()}],"scroll-px":[{"scroll-px":P()}],"scroll-py":[{"scroll-py":P()}],"scroll-ps":[{"scroll-ps":P()}],"scroll-pe":[{"scroll-pe":P()}],"scroll-pt":[{"scroll-pt":P()}],"scroll-pr":[{"scroll-pr":P()}],"scroll-pb":[{"scroll-pb":P()}],"scroll-pl":[{"scroll-pl":P()}],"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]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[Oe,Fe,Nr]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"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-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-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"],"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"]}}},ds=Cc(Bc);var Fc=Object.defineProperty,Vc=(e,t,r)=>t in e?Fc(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,_e=(e,t,r)=>Vc(e,typeof t!="symbol"?t+"":t,r);function it(...e){return ds(Zr(e))}process.env.NEXT_PUBLIC_API_BASE_URL;process.env.NEXT_PUBLIC_SUPABASE_URL;process.env.NEXT_PUBLIC_SUPABASE_PUBLISHABLE_KEY;const Wc=class us{constructor(t){_e(this,"el"),_e(this,"primed",!1),_e(this,"timer",null),_e(this,"resetTimer",null),_e(this,"opts"),_e(this,"inGroup",!1),_e(this,"currentTarget",null),_e(this,"obstacleSelector",null);var r,n;this.opts={initialDelayMs:(t==null?void 0:t.initialDelayMs)??350,resetDelayMs:(t==null?void 0:t.resetDelayMs)??400};const o=globalThis.document;this.el=o?o.createElement("div"):{};const s=this.getDesiredZIndex();this.el.style.cssText=`
1
+ "use strict";var rc=Object.defineProperty;var nc=(e,t,r)=>t in e?rc(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var Je=(e,t,r)=>nc(e,typeof t!="symbol"?t+"":t,r);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const m=require("react/jsx-runtime"),E=require("react"),ir=require("react-dom");function ts(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const r in e)if(r!=="default"){const n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:()=>e[r]})}}return t.default=e,Object.freeze(t)}const f=ts(E),ar=ts(ir);function $n(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function rs(...e){return t=>{let r=!1;const n=e.map(o=>{const s=$n(o,t);return!r&&typeof s=="function"&&(r=!0),s});if(r)return()=>{for(let o=0;o<n.length;o++){const s=n[o];typeof s=="function"?s():$n(e[o],null)}}}}function ee(...e){return f.useCallback(rs(...e),e)}function bt(e){const t=sc(e),r=f.forwardRef((n,o)=>{const{children:s,...i}=n,a=f.Children.toArray(s),c=a.find(ac);if(c){const l=c.props.children,u=a.map(d=>d===c?f.Children.count(l)>1?f.Children.only(null):f.isValidElement(l)?l.props.children:null:d);return m.jsx(t,{...i,ref:o,children:f.isValidElement(l)?f.cloneElement(l,void 0,u):null})}return m.jsx(t,{...i,ref:o,children:s})});return r.displayName=`${e}.Slot`,r}var oc=bt("Slot");function sc(e){const t=f.forwardRef((r,n)=>{const{children:o,...s}=r;if(f.isValidElement(o)){const i=cc(o),a=lc(s,o.props);return o.type!==f.Fragment&&(a.ref=n?rs(n,i):i),f.cloneElement(o,a)}return f.Children.count(o)>1?f.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var ns=Symbol("radix.slottable");function ic(e){const t=({children:r})=>m.jsx(m.Fragment,{children:r});return t.displayName=`${e}.Slottable`,t.__radixId=ns,t}function ac(e){return f.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===ns}function lc(e,t){const r={...t};for(const n in t){const o=e[n],s=t[n];/^on[A-Z]/.test(n)?o&&s?r[n]=(...a)=>{const c=s(...a);return o(...a),c}:o&&(r[n]=o):n==="style"?r[n]={...o,...s}:n==="className"&&(r[n]=[o,s].filter(Boolean).join(" "))}return{...e,...r}}function cc(e){var n,o;let t=(n=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:n.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}function os(e){var t,r,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(r=os(e[t]))&&(n&&(n+=" "),n+=r)}else for(r in e)e[r]&&(n&&(n+=" "),n+=r);return n}function Zr(){for(var e,t,r=0,n="",o=arguments.length;r<o;r++)(e=arguments[r])&&(t=os(e))&&(n&&(n+=" "),n+=t);return n}const zn=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,Fn=Zr,Ot=(e,t)=>r=>{var n;if((t==null?void 0:t.variants)==null)return Fn(e,r==null?void 0:r.class,r==null?void 0:r.className);const{variants:o,defaultVariants:s}=t,i=Object.keys(o).map(l=>{const u=r==null?void 0:r[l],d=s==null?void 0:s[l];if(u===null)return null;const p=zn(u)||zn(d);return o[l][p]}),a=r&&Object.entries(r).reduce((l,u)=>{let[d,p]=u;return p===void 0||(l[d]=p),l},{}),c=t==null||(n=t.compoundVariants)===null||n===void 0?void 0:n.reduce((l,u)=>{let{class:d,className:p,...g}=u;return Object.entries(g).every(v=>{let[h,b]=v;return Array.isArray(b)?b.includes({...s,...a}[h]):{...s,...a}[h]===b})?[...l,d,p]:l},[]);return Fn(e,i,c,r==null?void 0:r.class,r==null?void 0:r.className)},Qr="-",dc=e=>{const t=fc(e),{conflictingClassGroups:r,conflictingClassGroupModifiers:n}=e;return{getClassGroupId:i=>{const a=i.split(Qr);return a[0]===""&&a.length!==1&&a.shift(),ss(a,t)||uc(i)},getConflictingClassGroupIds:(i,a)=>{const c=r[i]||[];return a&&n[i]?[...c,...n[i]]:c}}},ss=(e,t)=>{var i;if(e.length===0)return t.classGroupId;const r=e[0],n=t.nextPart.get(r),o=n?ss(e.slice(1),n):void 0;if(o)return o;if(t.validators.length===0)return;const s=e.join(Qr);return(i=t.validators.find(({validator:a})=>a(s)))==null?void 0:i.classGroupId},Bn=/^\[(.+)\]$/,uc=e=>{if(Bn.test(e)){const t=Bn.exec(e)[1],r=t==null?void 0:t.substring(0,t.indexOf(":"));if(r)return"arbitrary.."+r}},fc=e=>{const{theme:t,prefix:r}=e,n={nextPart:new Map,validators:[]};return hc(Object.entries(e.classGroups),r).forEach(([s,i])=>{Lr(i,n,s,t)}),n},Lr=(e,t,r,n)=>{e.forEach(o=>{if(typeof o=="string"){const s=o===""?t:Vn(t,o);s.classGroupId=r;return}if(typeof o=="function"){if(pc(o)){Lr(o(n),t,r,n);return}t.validators.push({validator:o,classGroupId:r});return}Object.entries(o).forEach(([s,i])=>{Lr(i,Vn(t,s),r,n)})})},Vn=(e,t)=>{let r=e;return t.split(Qr).forEach(n=>{r.nextPart.has(n)||r.nextPart.set(n,{nextPart:new Map,validators:[]}),r=r.nextPart.get(n)}),r},pc=e=>e.isThemeGetter,hc=(e,t)=>t?e.map(([r,n])=>{const o=n.map(s=>typeof s=="string"?t+s:typeof s=="object"?Object.fromEntries(Object.entries(s).map(([i,a])=>[t+i,a])):s);return[r,o]}):e,mc=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,r=new Map,n=new Map;const o=(s,i)=>{r.set(s,i),t++,t>e&&(t=0,n=r,r=new Map)};return{get(s){let i=r.get(s);if(i!==void 0)return i;if((i=n.get(s))!==void 0)return o(s,i),i},set(s,i){r.has(s)?r.set(s,i):o(s,i)}}},is="!",gc=e=>{const{separator:t,experimentalParseClassName:r}=e,n=t.length===1,o=t[0],s=t.length,i=a=>{const c=[];let l=0,u=0,d;for(let b=0;b<a.length;b++){let y=a[b];if(l===0){if(y===o&&(n||a.slice(b,b+s)===t)){c.push(a.slice(u,b)),u=b+s;continue}if(y==="/"){d=b;continue}}y==="["?l++:y==="]"&&l--}const p=c.length===0?a:a.substring(u),g=p.startsWith(is),v=g?p.substring(1):p,h=d&&d>u?d-u:void 0;return{modifiers:c,hasImportantModifier:g,baseClassName:v,maybePostfixModifierPosition:h}};return r?a=>r({className:a,parseClassName:i}):i},vc=e=>{if(e.length<=1)return e;const t=[];let r=[];return e.forEach(n=>{n[0]==="["?(t.push(...r.sort(),n),r=[]):r.push(n)}),t.push(...r.sort()),t},yc=e=>({cache:mc(e.cacheSize),parseClassName:gc(e),...dc(e)}),bc=/\s+/,xc=(e,t)=>{const{parseClassName:r,getClassGroupId:n,getConflictingClassGroupIds:o}=t,s=[],i=e.trim().split(bc);let a="";for(let c=i.length-1;c>=0;c-=1){const l=i[c],{modifiers:u,hasImportantModifier:d,baseClassName:p,maybePostfixModifierPosition:g}=r(l);let v=!!g,h=n(v?p.substring(0,g):p);if(!h){if(!v){a=l+(a.length>0?" "+a:a);continue}if(h=n(p),!h){a=l+(a.length>0?" "+a:a);continue}v=!1}const b=vc(u).join(":"),y=d?b+is:b,x=y+h;if(s.includes(x))continue;s.push(x);const w=o(h,v);for(let C=0;C<w.length;++C){const S=w[C];s.push(y+S)}a=l+(a.length>0?" "+a:a)}return a};function wc(){let e=0,t,r,n="";for(;e<arguments.length;)(t=arguments[e++])&&(r=as(t))&&(n&&(n+=" "),n+=r);return n}const as=e=>{if(typeof e=="string")return e;let t,r="";for(let n=0;n<e.length;n++)e[n]&&(t=as(e[n]))&&(r&&(r+=" "),r+=t);return r};function Cc(e,...t){let r,n,o,s=i;function i(c){const l=t.reduce((u,d)=>d(u),e());return r=yc(l),n=r.cache.get,o=r.cache.set,s=a,a(c)}function a(c){const l=n(c);if(l)return l;const u=xc(c,r);return o(c,u),u}return function(){return s(wc.apply(null,arguments))}}const te=e=>{const t=r=>r[e]||[];return t.isThemeGetter=!0,t},ls=/^\[(?:([a-z-]+):)?(.+)\]$/i,Sc=/^\d+\/\d+$/,Ec=new Set(["px","full","screen"]),Rc=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,Ac=/\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$/,Nc=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,Pc=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,Tc=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Oe=e=>mt(e)||Ec.has(e)||Sc.test(e),Be=e=>wt(e,"length",Lc),mt=e=>!!e&&!Number.isNaN(Number(e)),Nr=e=>wt(e,"number",mt),Pt=e=>!!e&&Number.isInteger(Number(e)),kc=e=>e.endsWith("%")&&mt(e.slice(0,-1)),H=e=>ls.test(e),Ve=e=>Rc.test(e),Dc=new Set(["length","size","percentage"]),Mc=e=>wt(e,Dc,cs),Ic=e=>wt(e,"position",cs),Oc=new Set(["image","url"]),_c=e=>wt(e,Oc,zc),jc=e=>wt(e,"",$c),Tt=()=>!0,wt=(e,t,r)=>{const n=ls.exec(e);return n?n[1]?typeof t=="string"?n[1]===t:t.has(n[1]):r(n[2]):!1},Lc=e=>Ac.test(e)&&!Nc.test(e),cs=()=>!1,$c=e=>Pc.test(e),zc=e=>Tc.test(e),Fc=()=>{const e=te("colors"),t=te("spacing"),r=te("blur"),n=te("brightness"),o=te("borderColor"),s=te("borderRadius"),i=te("borderSpacing"),a=te("borderWidth"),c=te("contrast"),l=te("grayscale"),u=te("hueRotate"),d=te("invert"),p=te("gap"),g=te("gradientColorStops"),v=te("gradientColorStopPositions"),h=te("inset"),b=te("margin"),y=te("opacity"),x=te("padding"),w=te("saturate"),C=te("scale"),S=te("sepia"),A=te("skew"),R=te("space"),O=te("translate"),$=()=>["auto","contain","none"],L=()=>["auto","hidden","clip","visible","scroll"],k=()=>["auto",H,t],P=()=>[H,t],_=()=>["",Oe,Be],I=()=>["auto",mt,H],D=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],N=()=>["solid","dashed","dotted","double","none"],M=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],T=()=>["start","end","center","between","around","evenly","stretch"],j=()=>["","0",H],U=()=>["auto","avoid","all","avoid-page","page","left","right","column"],V=()=>[mt,H];return{cacheSize:500,separator:":",theme:{colors:[Tt],spacing:[Oe,Be],blur:["none","",Ve,H],brightness:V(),borderColor:[e],borderRadius:["none","","full",Ve,H],borderSpacing:P(),borderWidth:_(),contrast:V(),grayscale:j(),hueRotate:V(),invert:j(),gap:P(),gradientColorStops:[e],gradientColorStopPositions:[kc,Be],inset:k(),margin:k(),opacity:V(),padding:P(),saturate:V(),scale:V(),sepia:j(),skew:V(),space:P(),translate:P()},classGroups:{aspect:[{aspect:["auto","square","video",H]}],container:["container"],columns:[{columns:[Ve]}],"break-after":[{"break-after":U()}],"break-before":[{"break-before":U()}],"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"],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:[...D(),H]}],overflow:[{overflow:L()}],"overflow-x":[{"overflow-x":L()}],"overflow-y":[{"overflow-y":L()}],overscroll:[{overscroll:$()}],"overscroll-x":[{"overscroll-x":$()}],"overscroll-y":[{"overscroll-y":$()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[h]}],"inset-x":[{"inset-x":[h]}],"inset-y":[{"inset-y":[h]}],start:[{start:[h]}],end:[{end:[h]}],top:[{top:[h]}],right:[{right:[h]}],bottom:[{bottom:[h]}],left:[{left:[h]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",Pt,H]}],basis:[{basis:k()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",H]}],grow:[{grow:j()}],shrink:[{shrink:j()}],order:[{order:["first","last","none",Pt,H]}],"grid-cols":[{"grid-cols":[Tt]}],"col-start-end":[{col:["auto",{span:["full",Pt,H]},H]}],"col-start":[{"col-start":I()}],"col-end":[{"col-end":I()}],"grid-rows":[{"grid-rows":[Tt]}],"row-start-end":[{row:["auto",{span:[Pt,H]},H]}],"row-start":[{"row-start":I()}],"row-end":[{"row-end":I()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",H]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",H]}],gap:[{gap:[p]}],"gap-x":[{"gap-x":[p]}],"gap-y":[{"gap-y":[p]}],"justify-content":[{justify:["normal",...T()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...T(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...T(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[x]}],px:[{px:[x]}],py:[{py:[x]}],ps:[{ps:[x]}],pe:[{pe:[x]}],pt:[{pt:[x]}],pr:[{pr:[x]}],pb:[{pb:[x]}],pl:[{pl:[x]}],m:[{m:[b]}],mx:[{mx:[b]}],my:[{my:[b]}],ms:[{ms:[b]}],me:[{me:[b]}],mt:[{mt:[b]}],mr:[{mr:[b]}],mb:[{mb:[b]}],ml:[{ml:[b]}],"space-x":[{"space-x":[R]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[R]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",H,t]}],"min-w":[{"min-w":[H,t,"min","max","fit"]}],"max-w":[{"max-w":[H,t,"none","full","min","max","fit","prose",{screen:[Ve]},Ve]}],h:[{h:[H,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[H,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[H,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[H,t,"auto","min","max","fit"]}],"font-size":[{text:["base",Ve,Be]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",Nr]}],"font-family":[{font:[Tt]}],"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:["tighter","tight","normal","wide","wider","widest",H]}],"line-clamp":[{"line-clamp":["none",mt,Nr]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Oe,H]}],"list-image":[{"list-image":["none",H]}],"list-style-type":[{list:["none","disc","decimal",H]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[y]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[y]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...N(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Oe,Be]}],"underline-offset":[{"underline-offset":["auto",Oe,H]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:P()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",H]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",H]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[y]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...D(),Ic]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",Mc]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},_c]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[v]}],"gradient-via-pos":[{via:[v]}],"gradient-to-pos":[{to:[v]}],"gradient-from":[{from:[g]}],"gradient-via":[{via:[g]}],"gradient-to":[{to:[g]}],rounded:[{rounded:[s]}],"rounded-s":[{"rounded-s":[s]}],"rounded-e":[{"rounded-e":[s]}],"rounded-t":[{"rounded-t":[s]}],"rounded-r":[{"rounded-r":[s]}],"rounded-b":[{"rounded-b":[s]}],"rounded-l":[{"rounded-l":[s]}],"rounded-ss":[{"rounded-ss":[s]}],"rounded-se":[{"rounded-se":[s]}],"rounded-ee":[{"rounded-ee":[s]}],"rounded-es":[{"rounded-es":[s]}],"rounded-tl":[{"rounded-tl":[s]}],"rounded-tr":[{"rounded-tr":[s]}],"rounded-br":[{"rounded-br":[s]}],"rounded-bl":[{"rounded-bl":[s]}],"border-w":[{border:[a]}],"border-w-x":[{"border-x":[a]}],"border-w-y":[{"border-y":[a]}],"border-w-s":[{"border-s":[a]}],"border-w-e":[{"border-e":[a]}],"border-w-t":[{"border-t":[a]}],"border-w-r":[{"border-r":[a]}],"border-w-b":[{"border-b":[a]}],"border-w-l":[{"border-l":[a]}],"border-opacity":[{"border-opacity":[y]}],"border-style":[{border:[...N(),"hidden"]}],"divide-x":[{"divide-x":[a]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[a]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[y]}],"divide-style":[{divide:N()}],"border-color":[{border:[o]}],"border-color-x":[{"border-x":[o]}],"border-color-y":[{"border-y":[o]}],"border-color-s":[{"border-s":[o]}],"border-color-e":[{"border-e":[o]}],"border-color-t":[{"border-t":[o]}],"border-color-r":[{"border-r":[o]}],"border-color-b":[{"border-b":[o]}],"border-color-l":[{"border-l":[o]}],"divide-color":[{divide:[o]}],"outline-style":[{outline:["",...N()]}],"outline-offset":[{"outline-offset":[Oe,H]}],"outline-w":[{outline:[Oe,Be]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:_()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[y]}],"ring-offset-w":[{"ring-offset":[Oe,Be]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",Ve,jc]}],"shadow-color":[{shadow:[Tt]}],opacity:[{opacity:[y]}],"mix-blend":[{"mix-blend":[...M(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":M()}],filter:[{filter:["","none"]}],blur:[{blur:[r]}],brightness:[{brightness:[n]}],contrast:[{contrast:[c]}],"drop-shadow":[{"drop-shadow":["","none",Ve,H]}],grayscale:[{grayscale:[l]}],"hue-rotate":[{"hue-rotate":[u]}],invert:[{invert:[d]}],saturate:[{saturate:[w]}],sepia:[{sepia:[S]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[r]}],"backdrop-brightness":[{"backdrop-brightness":[n]}],"backdrop-contrast":[{"backdrop-contrast":[c]}],"backdrop-grayscale":[{"backdrop-grayscale":[l]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[u]}],"backdrop-invert":[{"backdrop-invert":[d]}],"backdrop-opacity":[{"backdrop-opacity":[y]}],"backdrop-saturate":[{"backdrop-saturate":[w]}],"backdrop-sepia":[{"backdrop-sepia":[S]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[i]}],"border-spacing-x":[{"border-spacing-x":[i]}],"border-spacing-y":[{"border-spacing-y":[i]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",H]}],duration:[{duration:V()}],ease:[{ease:["linear","in","out","in-out",H]}],delay:[{delay:V()}],animate:[{animate:["none","spin","ping","pulse","bounce",H]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[C]}],"scale-x":[{"scale-x":[C]}],"scale-y":[{"scale-y":[C]}],rotate:[{rotate:[Pt,H]}],"translate-x":[{"translate-x":[O]}],"translate-y":[{"translate-y":[O]}],"skew-x":[{"skew-x":[A]}],"skew-y":[{"skew-y":[A]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",H]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],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]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":P()}],"scroll-mx":[{"scroll-mx":P()}],"scroll-my":[{"scroll-my":P()}],"scroll-ms":[{"scroll-ms":P()}],"scroll-me":[{"scroll-me":P()}],"scroll-mt":[{"scroll-mt":P()}],"scroll-mr":[{"scroll-mr":P()}],"scroll-mb":[{"scroll-mb":P()}],"scroll-ml":[{"scroll-ml":P()}],"scroll-p":[{"scroll-p":P()}],"scroll-px":[{"scroll-px":P()}],"scroll-py":[{"scroll-py":P()}],"scroll-ps":[{"scroll-ps":P()}],"scroll-pe":[{"scroll-pe":P()}],"scroll-pt":[{"scroll-pt":P()}],"scroll-pr":[{"scroll-pr":P()}],"scroll-pb":[{"scroll-pb":P()}],"scroll-pl":[{"scroll-pl":P()}],"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]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[Oe,Be,Nr]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"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-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-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"],"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"]}}},ds=Cc(Fc);var Bc=Object.defineProperty,Vc=(e,t,r)=>t in e?Bc(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,_e=(e,t,r)=>Vc(e,typeof t!="symbol"?t+"":t,r);function it(...e){return ds(Zr(e))}process.env.NEXT_PUBLIC_API_BASE_URL;process.env.NEXT_PUBLIC_SUPABASE_URL;process.env.NEXT_PUBLIC_SUPABASE_PUBLISHABLE_KEY;const Wc=class us{constructor(t){_e(this,"el"),_e(this,"primed",!1),_e(this,"timer",null),_e(this,"resetTimer",null),_e(this,"opts"),_e(this,"inGroup",!1),_e(this,"currentTarget",null),_e(this,"obstacleSelector",null);var r,n;this.opts={initialDelayMs:(t==null?void 0:t.initialDelayMs)??350,resetDelayMs:(t==null?void 0:t.resetDelayMs)??400};const o=globalThis.document;this.el=o?o.createElement("div"):{};const s=this.getDesiredZIndex();this.el.style.cssText=`
2
2
  position: fixed; z-index: ${s}; background: rgba(17,17,17,0.95);
3
3
  color: #fff; padding: 6px 8px; border-radius: 6px; font-size: 12px;
4
4
  line-height: 1; pointer-events: none; opacity: 0; transition: opacity 60ms ease;
@@ -16,7 +16,7 @@
16
16
  position: relative;
17
17
  width: ${s}px;
18
18
  height: ${i}px;
19
- `;const u=document.createElement("canvas");u.width=s,u.height=i,u.style.cssText="border-radius: 8px;",l.appendChild(u);let d=null,p=[],g=null,v=!1;const h=()=>{if(v)return;d=new Ao.Illustration({element:u,zoom:1,rotate:{y:0}});const y=(k,P,_)=>{const I=new Ao.Ellipse({addTo:d,diameter:a,stroke:!1,fill:!0,color:"#5e0f1a"});p.push({shape:I,id:_,group:k,offset:P})};let x=0;for(let k=0;k<6;k++)y("left",k/6,x++);for(let k=0;k<6;k++)y("right",k/6,x++);const w=k=>1-Math.pow(1-k,2),C=(k,P,_)=>k+(P-k)*_,S=k=>({r:parseInt(k.slice(1,3),16),g:parseInt(k.slice(3,5),16),b:parseInt(k.slice(5,7),16)}),A=["#5e0f1a","#c22a2f","#e0392b","#f05a24","#f39c12","#fde68a"].map(S),R=[...A].reverse(),O=(k,P)=>{if(P<=0)return k[0];if(P>=1)return k[k.length-1];const _=P*(k.length-1),I=Math.floor(_),D=_-I,N=k[I],M=k[I+1];return{r:Math.round(C(N.r,M.r,D)),g:Math.round(C(N.g,M.g,D)),b:Math.round(C(N.b,M.b,D))}};p.forEach(({shape:k,group:P,offset:_,id:I})=>{let D,N,M,T=1;if(P==="left"){const j=_,U=w(j);D=-c+c*U,N=Math.PI/2*U,M=300+(100-Math.abs(D))-I*.01;const{r:V,g:se,b:F}=O(A,j);k.color=`rgba(${V}, ${se}, ${F}, ${T})`}else{const j=_,U=w(j);D=0+c*U,N=Math.PI/2+Math.PI/2*U,M=300+(100-Math.abs(D))-I*.01;const{r:V,g:se,b:F}=O(R,j);k.color=`rgba(${V}, ${se}, ${F}, ${T})`}k.translate.x=D,k.translate.z=M,k.rotate.y=N}),d.updateRenderGraph();const $=(k,P,_,I)=>{let D,N,M,T;const j=Math.min(_,1),U=V=>V<.5?2*V*V:1-Math.pow(-2*V+2,2)/2;if(P==="left"){const V=U(j);D=-c+c*V,N=Math.PI/2*V,M=1,T=300+(100-Math.abs(D))-I*.01;const{r:se,g:F,b:X}=O(A,j);k.color=`rgba(${se}, ${F}, ${X}, ${M})`}else{const V=U(j);D=0+c*V,N=Math.PI/2+Math.PI/2*V,M=1,T=300+(100-Math.abs(D))-I*.01;const{r:se,g:F,b:X}=O(R,j);k.color=`rgba(${se}, ${F}, ${X}, ${M})`}k.translate.x=D,k.translate.z=T,k.rotate.y=N},L=k=>{if(v||!d||!p.length)return;const P=k%r/r;for(let _=0;_<p.length;_++){const I=p[_];let D=(P+I.offset)%1;if(D<.02){const N=D/.02;$(I.shape,I.group,0,I.id);const M=I.shape.color.match(/rgba?\((\d+),\s*(\d+),\s*(\d+),\s*([^)]+)\)/);if(M){const T=parseFloat(M[4]);I.shape.color=`rgba(${M[1]}, ${M[2]}, ${M[3]}, ${T*N})`}I.shape.translate.z=100-I.id*.01}else if(D>.98){const N=(1-D)/.02,M=(.98-.02)/.96;$(I.shape,I.group,M,I.id);const T=I.shape.color.match(/rgba?\((\d+),\s*(\d+),\s*(\d+),\s*([^)]+)\)/);if(T){const j=parseFloat(T[4]);I.shape.color=`rgba(${T[1]}, ${T[2]}, ${T[3]}, ${j*N})`}}else{const N=(D-.02)/.96;$(I.shape,I.group,N,I.id)}}d.updateRenderGraph(),v||(g=requestAnimationFrame(L))};g=requestAnimationFrame(L)},b=()=>{v=!0,g&&(cancelAnimationFrame(g),g=null),p=[],d=null};return h(),{element:l,destroy:b}}const Jr=Ot("inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium ring-offset-background 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-primary text-primary-foreground hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground hover:bg-destructive/90",outline:"border border-input bg-background hover:bg-[#EDEBEB]",secondary:"bg-secondary text-secondary-foreground hover:bg-[#EDEBEB]",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-10 px-4 py-2",sm:"h-9 rounded-md px-3",lg:"h-11 rounded-md px-8",icon:"h-10 w-10"}},defaultVariants:{variant:"default",size:"default"}}),ys=f.forwardRef(({className:e,variant:t,size:r,asChild:n=!1,...o},s)=>{const i=n?oc:"button";return m.jsx(i,{className:it(Jr({variant:t,size:r,className:e})),ref:s,...o})});ys.displayName="Button";const bs=f.forwardRef(({className:e,...t},r)=>m.jsx("div",{ref:r,className:it("rounded-lg border bg-card text-card-foreground shadow-sm",e),...t}));bs.displayName="Card";const xs=f.forwardRef(({className:e,...t},r)=>m.jsx("div",{ref:r,className:it("flex flex-col space-y-1.5 p-6",e),...t}));xs.displayName="CardHeader";const ws=f.forwardRef(({className:e,...t},r)=>m.jsx("h3",{ref:r,className:it("text-2xl font-semibold leading-none tracking-tight",e),...t}));ws.displayName="CardTitle";const Cs=f.forwardRef(({className:e,...t},r)=>m.jsx("p",{ref:r,className:it("text-sm text-muted-foreground",e),...t}));Cs.displayName="CardDescription";const Ss=f.forwardRef(({className:e,...t},r)=>m.jsx("div",{ref:r,className:it("p-6 pt-0",e),...t}));Ss.displayName="CardContent";function G(...e){return ds(Zr(e))}const Es=f.forwardRef(({className:e,type:t,error:r,...n},o)=>m.jsx("input",{type:t,className:G("flex h-10 w-full rounded-md border border-gray-300 bg-white px-3 py-2 text-sm ring-offset-white file:border-0 file:bg-transparent file:text-sm file:font-medium placeholder:text-gray-500 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-blue-500 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",r&&"border-red-500 focus-visible:ring-red-500",e),ref:o,...n}));Es.displayName="Input";var Qc=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],K=Qc.reduce((e,t)=>{const r=bt(`Primitive.${t}`),n=f.forwardRef((o,s)=>{const{asChild:i,...a}=o,c=i?r:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),m.jsx(c,{...a,ref:s})});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function Jc(e,t){e&&ar.flushSync(()=>e.dispatchEvent(t))}var ed="Label",Rs=f.forwardRef((e,t)=>m.jsx(K.label,{...e,ref:t,onMouseDown:r=>{var o;r.target.closest("button, input, select, textarea")||((o=e.onMouseDown)==null||o.call(e,r),!r.defaultPrevented&&r.detail>1&&r.preventDefault())}}));Rs.displayName=ed;var As=Rs;const td=Ot("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),Ns=f.forwardRef(({className:e,...t},r)=>m.jsx(As,{ref:r,className:G(td(),e),...t}));Ns.displayName=As.displayName;const rd=Ot("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-white text-gray-900 border-gray-200",destructive:"border-red-500/50 text-red-900 dark:border-red-500 [&>svg]:text-red-500 bg-red-50",success:"border-green-500/50 text-green-900 dark:border-green-500 [&>svg]:text-green-500 bg-green-50",warning:"border-yellow-500/50 text-yellow-900 dark:border-yellow-500 [&>svg]:text-yellow-500 bg-yellow-50"}},defaultVariants:{variant:"default"}}),Ps=f.forwardRef(({className:e,variant:t,...r},n)=>m.jsx("div",{ref:n,role:"alert",className:G(rd({variant:t}),e),...r}));Ps.displayName="Alert";const Ts=f.forwardRef(({className:e,...t},r)=>m.jsx("div",{ref:r,className:G("text-sm [&_p]:leading-relaxed",e),...t}));Ts.displayName="AlertDescription";const ks=f.forwardRef(({className:e,...t},r)=>m.jsx("h5",{ref:r,className:G("mb-1 font-medium leading-none tracking-tight",e),...t}));ks.displayName="AlertTitle";const Ds=f.forwardRef(({className:e,error:t,...r},n)=>m.jsx("textarea",{className:G("flex min-h-[80px] w-full rounded-md border border-gray-300 bg-white px-3 py-2 text-sm ring-offset-white placeholder:text-gray-500 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-blue-500 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",t&&"border-red-500 focus-visible:ring-red-500",e),ref:n,...r}));Ds.displayName="Textarea";const nd=Ot("animate-spin rounded-full border-2 border-current border-t-transparent",{variants:{size:{sm:"h-4 w-4",md:"h-6 w-6",lg:"h-8 w-8",xl:"h-12 w-12"}},defaultVariants:{size:"md"}}),Ms=f.forwardRef(({className:e,size:t,...r},n)=>m.jsx("div",{ref:n,className:G(nd({size:t}),e),...r}));Ms.displayName="Spinner";const od=Ot("relative",{variants:{size:{sm:"w-[140px] h-[105px]",md:"w-[300px] h-[200px]",lg:"w-[400px] h-[250px]",xl:"w-[500px] h-[300px]"}},defaultVariants:{size:"md"}}),Is=E.forwardRef(({className:e,size:t,cycleDuration:r=3e3,...n},o)=>{const s=E.useRef(null),i=E.useRef(null);return E.useEffect(()=>{if(s.current)return i.current&&i.current.destroy(),i.current=Zc({size:t||"md",cycleDuration:r,className:""}),s.current.innerHTML="",s.current.appendChild(i.current.element),()=>{i.current&&(i.current.destroy(),i.current=null)}},[t,r]),m.jsx("div",{ref:a=>{s.current=a,typeof o=="function"?o(a):o&&(o.current=a)},className:G(od({size:t}),e),...n})});Is.displayName="DiscLoader";function sd(e){if(typeof document>"u")return;let t=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",t.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}const id=e=>{switch(e){case"success":return cd;case"info":return ud;case"warning":return dd;case"error":return fd;default:return null}},ad=Array(12).fill(0),ld=({visible:e,className:t})=>E.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},E.createElement("div",{className:"sonner-spinner"},ad.map((r,n)=>E.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${n}`})))),cd=E.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},E.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"})),dd=E.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},E.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"})),ud=E.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},E.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"})),fd=E.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},E.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"})),pd=E.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"},E.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),E.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),hd=()=>{const[e,t]=E.useState(document.hidden);return E.useEffect(()=>{const r=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",r),()=>window.removeEventListener("visibilitychange",r)},[]),e};let $r=1;class md{constructor(){this.subscribe=t=>(this.subscribers.push(t),()=>{const r=this.subscribers.indexOf(t);this.subscribers.splice(r,1)}),this.publish=t=>{this.subscribers.forEach(r=>r(t))},this.addToast=t=>{this.publish(t),this.toasts=[...this.toasts,t]},this.create=t=>{var r;const{message:n,...o}=t,s=typeof(t==null?void 0:t.id)=="number"||((r=t.id)==null?void 0:r.length)>0?t.id:$r++,i=this.toasts.find(c=>c.id===s),a=t.dismissible===void 0?!0:t.dismissible;return this.dismissedToasts.has(s)&&this.dismissedToasts.delete(s),i?this.toasts=this.toasts.map(c=>c.id===s?(this.publish({...c,...t,id:s,title:n}),{...c,...t,id:s,dismissible:a,title:n}):c):this.addToast({title:n,...o,dismissible:a,id:s}),s},this.dismiss=t=>(t?(this.dismissedToasts.add(t),requestAnimationFrame(()=>this.subscribers.forEach(r=>r({id:t,dismiss:!0})))):this.toasts.forEach(r=>{this.subscribers.forEach(n=>n({id:r.id,dismiss:!0}))}),t),this.message=(t,r)=>this.create({...r,message:t}),this.error=(t,r)=>this.create({...r,message:t,type:"error"}),this.success=(t,r)=>this.create({...r,type:"success",message:t}),this.info=(t,r)=>this.create({...r,type:"info",message:t}),this.warning=(t,r)=>this.create({...r,type:"warning",message:t}),this.loading=(t,r)=>this.create({...r,type:"loading",message:t}),this.promise=(t,r)=>{if(!r)return;let n;r.loading!==void 0&&(n=this.create({...r,promise:t,type:"loading",message:r.loading,description:typeof r.description!="function"?r.description:void 0}));const o=Promise.resolve(t instanceof Function?t():t);let s=n!==void 0,i;const a=o.then(async l=>{if(i=["resolve",l],E.isValidElement(l))s=!1,this.create({id:n,type:"default",message:l});else if(vd(l)&&!l.ok){s=!1;const d=typeof r.error=="function"?await r.error(`HTTP error! status: ${l.status}`):r.error,p=typeof r.description=="function"?await r.description(`HTTP error! status: ${l.status}`):r.description,v=typeof d=="object"&&!E.isValidElement(d)?d:{message:d};this.create({id:n,type:"error",description:p,...v})}else if(l instanceof Error){s=!1;const d=typeof r.error=="function"?await r.error(l):r.error,p=typeof r.description=="function"?await r.description(l):r.description,v=typeof d=="object"&&!E.isValidElement(d)?d:{message:d};this.create({id:n,type:"error",description:p,...v})}else if(r.success!==void 0){s=!1;const d=typeof r.success=="function"?await r.success(l):r.success,p=typeof r.description=="function"?await r.description(l):r.description,v=typeof d=="object"&&!E.isValidElement(d)?d:{message:d};this.create({id:n,type:"success",description:p,...v})}}).catch(async l=>{if(i=["reject",l],r.error!==void 0){s=!1;const u=typeof r.error=="function"?await r.error(l):r.error,d=typeof r.description=="function"?await r.description(l):r.description,g=typeof u=="object"&&!E.isValidElement(u)?u:{message:u};this.create({id:n,type:"error",description:d,...g})}}).finally(()=>{s&&(this.dismiss(n),n=void 0),r.finally==null||r.finally.call(r)}),c=()=>new Promise((l,u)=>a.then(()=>i[0]==="reject"?u(i[1]):l(i[1])).catch(u));return typeof n!="string"&&typeof n!="number"?{unwrap:c}:Object.assign(n,{unwrap:c})},this.custom=(t,r)=>{const n=(r==null?void 0:r.id)||$r++;return this.create({jsx:t(n),id:n,...r}),n},this.getActiveToasts=()=>this.toasts.filter(t=>!this.dismissedToasts.has(t.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}}const pe=new md,gd=(e,t)=>{const r=(t==null?void 0:t.id)||$r++;return pe.addToast({title:e,...t,id:r}),r},vd=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",yd=gd,bd=()=>pe.toasts,xd=()=>pe.getActiveToasts(),Dt=Object.assign(yd,{success:pe.success,info:pe.info,warning:pe.warning,error:pe.error,custom:pe.custom,message:pe.message,promise:pe.promise,dismiss:pe.dismiss,loading:pe.loading},{getHistory:bd,getToasts:xd});sd("[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 Bt(e){return e.label!==void 0}const wd=3,Cd="24px",Sd="16px",No=4e3,Ed=356,Rd=14,Ad=45,Nd=200;function Ne(...e){return e.filter(Boolean).join(" ")}function Pd(e){const[t,r]=e.split("-"),n=[];return t&&n.push(t),r&&n.push(r),n}const Td=e=>{var t,r,n,o,s,i,a,c,l;const{invert:u,toast:d,unstyled:p,interacting:g,setHeights:v,visibleToasts:h,heights:b,index:y,toasts:x,expanded:w,removeToast:C,defaultRichColors:S,closeButton:A,style:R,cancelButtonStyle:O,actionButtonStyle:$,className:L="",descriptionClassName:k="",duration:P,position:_,gap:I,expandByDefault:D,classNames:N,icons:M,closeButtonAriaLabel:T="Close toast"}=e,[j,U]=E.useState(null),[V,se]=E.useState(null),[F,X]=E.useState(!1),[J,ne]=E.useState(!1),[z,B]=E.useState(!1),[re,Z]=E.useState(!1),[q,Y]=E.useState(!1),[de,ue]=E.useState(0),[Ze,ze]=E.useState(0),be=E.useRef(d.duration||P||No),jt=E.useRef(null),fe=E.useRef(null),Ul=y===0,Yl=y+1<=h,he=d.type,ct=d.dismissible!==!1,Kl=d.className||"",Xl=d.descriptionClassName||"",Lt=E.useMemo(()=>b.findIndex(W=>W.toastId===d.id)||0,[b,d.id]),ql=E.useMemo(()=>{var W;return(W=d.closeButton)!=null?W:A},[d.closeButton,A]),Dn=E.useMemo(()=>d.duration||P||No,[d.duration,P]),Rr=E.useRef(0),dt=E.useRef(0),Mn=E.useRef(0),ut=E.useRef(null),[Zl,Ql]=_.split("-"),In=E.useMemo(()=>b.reduce((W,ie,ce)=>ce>=Lt?W:W+ie.height,0),[b,Lt]),On=hd(),Jl=d.invert||u,Ar=he==="loading";dt.current=E.useMemo(()=>Lt*I+In,[Lt,In]),E.useEffect(()=>{be.current=Dn},[Dn]),E.useEffect(()=>{X(!0)},[]),E.useEffect(()=>{const W=fe.current;if(W){const ie=W.getBoundingClientRect().height;return ze(ie),v(ce=>[{toastId:d.id,height:ie,position:d.position},...ce]),()=>v(ce=>ce.filter(me=>me.toastId!==d.id))}},[v,d.id]),E.useLayoutEffect(()=>{if(!F)return;const W=fe.current,ie=W.style.height;W.style.height="auto";const ce=W.getBoundingClientRect().height;W.style.height=ie,ze(ce),v(me=>me.find(ae=>ae.toastId===d.id)?me.map(ae=>ae.toastId===d.id?{...ae,height:ce}:ae):[{toastId:d.id,height:ce,position:d.position},...me])},[F,d.title,d.description,v,d.id,d.jsx,d.action,d.cancel]);const Be=E.useCallback(()=>{ne(!0),ue(dt.current),v(W=>W.filter(ie=>ie.toastId!==d.id)),setTimeout(()=>{C(d)},Nd)},[d,C,v,dt]);E.useEffect(()=>{if(d.promise&&he==="loading"||d.duration===1/0||d.type==="loading")return;let W;return w||g||On?(()=>{if(Mn.current<Rr.current){const me=new Date().getTime()-Rr.current;be.current=be.current-me}Mn.current=new Date().getTime()})():(()=>{be.current!==1/0&&(Rr.current=new Date().getTime(),W=setTimeout(()=>{d.onAutoClose==null||d.onAutoClose.call(d,d),Be()},be.current))})(),()=>clearTimeout(W)},[w,g,d,he,On,Be]),E.useEffect(()=>{d.delete&&(Be(),d.onDismiss==null||d.onDismiss.call(d,d))},[Be,d.delete]);function ec(){var W;if(M!=null&&M.loading){var ie;return E.createElement("div",{className:Ne(N==null?void 0:N.loader,d==null||(ie=d.classNames)==null?void 0:ie.loader,"sonner-loader"),"data-visible":he==="loading"},M.loading)}return E.createElement(ld,{className:Ne(N==null?void 0:N.loader,d==null||(W=d.classNames)==null?void 0:W.loader),visible:he==="loading"})}const tc=d.icon||(M==null?void 0:M[he])||id(he);var _n,jn;return E.createElement("li",{tabIndex:0,ref:fe,className:Ne(L,Kl,N==null?void 0:N.toast,d==null||(t=d.classNames)==null?void 0:t.toast,N==null?void 0:N.default,N==null?void 0:N[he],d==null||(r=d.classNames)==null?void 0:r[he]),"data-sonner-toast":"","data-rich-colors":(_n=d.richColors)!=null?_n:S,"data-styled":!(d.jsx||d.unstyled||p),"data-mounted":F,"data-promise":!!d.promise,"data-swiped":q,"data-removed":J,"data-visible":Yl,"data-y-position":Zl,"data-x-position":Ql,"data-index":y,"data-front":Ul,"data-swiping":z,"data-dismissible":ct,"data-type":he,"data-invert":Jl,"data-swipe-out":re,"data-swipe-direction":V,"data-expanded":!!(w||D&&F),"data-testid":d.testId,style:{"--index":y,"--toasts-before":y,"--z-index":x.length-y,"--offset":`${J?de:dt.current}px`,"--initial-height":D?"auto":`${Ze}px`,...R,...d.style},onDragEnd:()=>{B(!1),U(null),ut.current=null},onPointerDown:W=>{W.button!==2&&(Ar||!ct||(jt.current=new Date,ue(dt.current),W.target.setPointerCapture(W.pointerId),W.target.tagName!=="BUTTON"&&(B(!0),ut.current={x:W.clientX,y:W.clientY})))},onPointerUp:()=>{var W,ie,ce;if(re||!ct)return;ut.current=null;const me=Number(((W=fe.current)==null?void 0:W.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),$t=Number(((ie=fe.current)==null?void 0:ie.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),ae=new Date().getTime()-((ce=jt.current)==null?void 0:ce.getTime()),ye=j==="x"?me:$t,zt=Math.abs(ye)/ae;if(Math.abs(ye)>=Ad||zt>.11){ue(dt.current),d.onDismiss==null||d.onDismiss.call(d,d),se(j==="x"?me>0?"right":"left":$t>0?"down":"up"),Be(),Z(!0);return}else{var xe,we;(xe=fe.current)==null||xe.style.setProperty("--swipe-amount-x","0px"),(we=fe.current)==null||we.style.setProperty("--swipe-amount-y","0px")}Y(!1),B(!1),U(null)},onPointerMove:W=>{var ie,ce,me;if(!ut.current||!ct||((ie=window.getSelection())==null?void 0:ie.toString().length)>0)return;const ae=W.clientY-ut.current.y,ye=W.clientX-ut.current.x;var zt;const xe=(zt=e.swipeDirections)!=null?zt:Pd(_);!j&&(Math.abs(ye)>1||Math.abs(ae)>1)&&U(Math.abs(ye)>Math.abs(ae)?"x":"y");let we={x:0,y:0};const Ln=Qe=>1/(1.5+Math.abs(Qe)/20);if(j==="y"){if(xe.includes("top")||xe.includes("bottom"))if(xe.includes("top")&&ae<0||xe.includes("bottom")&&ae>0)we.y=ae;else{const Qe=ae*Ln(ae);we.y=Math.abs(Qe)<Math.abs(ae)?Qe:ae}}else if(j==="x"&&(xe.includes("left")||xe.includes("right")))if(xe.includes("left")&&ye<0||xe.includes("right")&&ye>0)we.x=ye;else{const Qe=ye*Ln(ye);we.x=Math.abs(Qe)<Math.abs(ye)?Qe:ye}(Math.abs(we.x)>0||Math.abs(we.y)>0)&&Y(!0),(ce=fe.current)==null||ce.style.setProperty("--swipe-amount-x",`${we.x}px`),(me=fe.current)==null||me.style.setProperty("--swipe-amount-y",`${we.y}px`)}},ql&&!d.jsx&&he!=="loading"?E.createElement("button",{"aria-label":T,"data-disabled":Ar,"data-close-button":!0,onClick:Ar||!ct?()=>{}:()=>{Be(),d.onDismiss==null||d.onDismiss.call(d,d)},className:Ne(N==null?void 0:N.closeButton,d==null||(n=d.classNames)==null?void 0:n.closeButton)},(jn=M==null?void 0:M.close)!=null?jn:pd):null,(he||d.icon||d.promise)&&d.icon!==null&&((M==null?void 0:M[he])!==null||d.icon)?E.createElement("div",{"data-icon":"",className:Ne(N==null?void 0:N.icon,d==null||(o=d.classNames)==null?void 0:o.icon)},d.promise||d.type==="loading"&&!d.icon?d.icon||ec():null,d.type!=="loading"?tc:null):null,E.createElement("div",{"data-content":"",className:Ne(N==null?void 0:N.content,d==null||(s=d.classNames)==null?void 0:s.content)},E.createElement("div",{"data-title":"",className:Ne(N==null?void 0:N.title,d==null||(i=d.classNames)==null?void 0:i.title)},d.jsx?d.jsx:typeof d.title=="function"?d.title():d.title),d.description?E.createElement("div",{"data-description":"",className:Ne(k,Xl,N==null?void 0:N.description,d==null||(a=d.classNames)==null?void 0:a.description)},typeof d.description=="function"?d.description():d.description):null),E.isValidElement(d.cancel)?d.cancel:d.cancel&&Bt(d.cancel)?E.createElement("button",{"data-button":!0,"data-cancel":!0,style:d.cancelButtonStyle||O,onClick:W=>{Bt(d.cancel)&&ct&&(d.cancel.onClick==null||d.cancel.onClick.call(d.cancel,W),Be())},className:Ne(N==null?void 0:N.cancelButton,d==null||(c=d.classNames)==null?void 0:c.cancelButton)},d.cancel.label):null,E.isValidElement(d.action)?d.action:d.action&&Bt(d.action)?E.createElement("button",{"data-button":!0,"data-action":!0,style:d.actionButtonStyle||$,onClick:W=>{Bt(d.action)&&(d.action.onClick==null||d.action.onClick.call(d.action,W),!W.defaultPrevented&&Be())},className:Ne(N==null?void 0:N.actionButton,d==null||(l=d.classNames)==null?void 0:l.actionButton)},d.action.label):null)};function Po(){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 kd(e,t){const r={};return[e,t].forEach((n,o)=>{const s=o===1,i=s?"--mobile-offset":"--offset",a=s?Sd:Cd;function c(l){["top","right","bottom","left"].forEach(u=>{r[`${i}-${u}`]=typeof l=="number"?`${l}px`:l})}typeof n=="number"||typeof n=="string"?c(n):typeof n=="object"?["top","right","bottom","left"].forEach(l=>{n[l]===void 0?r[`${i}-${l}`]=a:r[`${i}-${l}`]=typeof n[l]=="number"?`${n[l]}px`:n[l]}):c(a)}),r}const Dd=E.forwardRef(function(t,r){const{id:n,invert:o,position:s="bottom-right",hotkey:i=["altKey","KeyT"],expand:a,closeButton:c,className:l,offset:u,mobileOffset:d,theme:p="light",richColors:g,duration:v,style:h,visibleToasts:b=wd,toastOptions:y,dir:x=Po(),gap:w=Rd,icons:C,containerAriaLabel:S="Notifications"}=t,[A,R]=E.useState([]),O=E.useMemo(()=>n?A.filter(F=>F.toasterId===n):A.filter(F=>!F.toasterId),[A,n]),$=E.useMemo(()=>Array.from(new Set([s].concat(O.filter(F=>F.position).map(F=>F.position)))),[O,s]),[L,k]=E.useState([]),[P,_]=E.useState(!1),[I,D]=E.useState(!1),[N,M]=E.useState(p!=="system"?p:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),T=E.useRef(null),j=i.join("+").replace(/Key/g,"").replace(/Digit/g,""),U=E.useRef(null),V=E.useRef(!1),se=E.useCallback(F=>{R(X=>{var J;return(J=X.find(ne=>ne.id===F.id))!=null&&J.delete||pe.dismiss(F.id),X.filter(({id:ne})=>ne!==F.id)})},[]);return E.useEffect(()=>pe.subscribe(F=>{if(F.dismiss){requestAnimationFrame(()=>{R(X=>X.map(J=>J.id===F.id?{...J,delete:!0}:J))});return}setTimeout(()=>{ir.flushSync(()=>{R(X=>{const J=X.findIndex(ne=>ne.id===F.id);return J!==-1?[...X.slice(0,J),{...X[J],...F},...X.slice(J+1)]:[F,...X]})})})}),[A]),E.useEffect(()=>{if(p!=="system"){M(p);return}if(p==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?M("dark"):M("light")),typeof window>"u")return;const F=window.matchMedia("(prefers-color-scheme: dark)");try{F.addEventListener("change",({matches:X})=>{M(X?"dark":"light")})}catch{F.addListener(({matches:J})=>{try{M(J?"dark":"light")}catch(ne){console.error(ne)}})}},[p]),E.useEffect(()=>{A.length<=1&&_(!1)},[A]),E.useEffect(()=>{const F=X=>{var J;if(i.every(B=>X[B]||X.code===B)){var z;_(!0),(z=T.current)==null||z.focus()}X.code==="Escape"&&(document.activeElement===T.current||(J=T.current)!=null&&J.contains(document.activeElement))&&_(!1)};return document.addEventListener("keydown",F),()=>document.removeEventListener("keydown",F)},[i]),E.useEffect(()=>{if(T.current)return()=>{U.current&&(U.current.focus({preventScroll:!0}),U.current=null,V.current=!1)}},[T.current]),E.createElement("section",{ref:r,"aria-label":`${S} ${j}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},$.map((F,X)=>{var J;const[ne,z]=F.split("-");return O.length?E.createElement("ol",{key:F,dir:x==="auto"?Po():x,tabIndex:-1,ref:T,className:l,"data-sonner-toaster":!0,"data-sonner-theme":N,"data-y-position":ne,"data-x-position":z,style:{"--front-toast-height":`${((J=L[0])==null?void 0:J.height)||0}px`,"--width":`${Ed}px`,"--gap":`${w}px`,...h,...kd(u,d)},onBlur:B=>{V.current&&!B.currentTarget.contains(B.relatedTarget)&&(V.current=!1,U.current&&(U.current.focus({preventScroll:!0}),U.current=null))},onFocus:B=>{B.target instanceof HTMLElement&&B.target.dataset.dismissible==="false"||V.current||(V.current=!0,U.current=B.relatedTarget)},onMouseEnter:()=>_(!0),onMouseMove:()=>_(!0),onMouseLeave:()=>{I||_(!1)},onDragEnd:()=>_(!1),onPointerDown:B=>{B.target instanceof HTMLElement&&B.target.dataset.dismissible==="false"||D(!0)},onPointerUp:()=>D(!1)},O.filter(B=>!B.position&&X===0||B.position===F).map((B,re)=>{var Z,q;return E.createElement(Td,{key:B.id,icons:C,index:re,toast:B,defaultRichColors:g,duration:(Z=y==null?void 0:y.duration)!=null?Z:v,className:y==null?void 0:y.className,descriptionClassName:y==null?void 0:y.descriptionClassName,invert:o,visibleToasts:b,closeButton:(q=y==null?void 0:y.closeButton)!=null?q:c,interacting:I,position:F,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:se,toasts:O.filter(Y=>Y.position==B.position),heights:L.filter(Y=>Y.position==B.position),setHeights:k,expandByDefault:a,gap:w,expanded:P,swipeDirections:t.swipeDirections})})):null}))}),Md=({...e})=>m.jsx(Dd,{className:"toaster group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-white group-[.toaster]:text-[#2C2825] group-[.toaster]:border-white/20 group-[.toaster]:shadow-xl group-[.toaster]:backdrop-blur-md group-[.toaster]:rounded-2xl font-sans-body",description:"group-[.toast]:text-[#7A7570] font-sans-body",actionButton:"group-[.toast]:bg-[#FF6B4A] group-[.toast]:text-white group-[.toast]:rounded-xl font-medium",cancelButton:"group-[.toast]:bg-[#F4F4F1] group-[.toast]:text-[#7A7570] group-[.toast]:rounded-xl"}},...e}),Os=f.forwardRef(({className:e,...t},r)=>m.jsx("form",{ref:r,className:G("space-y-4",e),...t}));Os.displayName="Form";const _s=f.forwardRef(({className:e,error:t,children:r,...n},o)=>m.jsxs("div",{ref:o,className:G("space-y-2",e),...n,children:[r,t&&m.jsx("p",{className:"text-sm text-red-600",role:"alert",children:t})]}));_s.displayName="FormField";const js=f.forwardRef(({className:e,variant:t="default",size:r="md",...n},o)=>m.jsx("div",{className:G("inline-flex items-center rounded-full border font-medium text-center whitespace-nowrap",{"px-2 py-0.5 text-xs":r==="sm","px-2.5 py-0.5 text-sm":r==="md","px-3 py-1 text-sm":r==="lg","bg-blue-600 border-blue-600 text-white":t==="default","bg-gray-100 border-gray-300 text-gray-800":t==="secondary","bg-transparent border-gray-300 text-gray-700":t==="outline","bg-green-100 border-green-300 text-green-800":t==="success","bg-yellow-100 border-yellow-300 text-yellow-800":t==="warning","bg-red-100 border-red-300 text-red-800":t==="error"},e),ref:o,...n}));js.displayName="Badge";const Ls=f.forwardRef(({className:e,orientation:t="horizontal",decorative:r=!0,...n},o)=>m.jsx("div",{ref:o,role:r?"none":"separator","aria-orientation":t,className:it("shrink-0 bg-border",t==="horizontal"?"h-[1px] w-full":"h-full w-[1px]",e),...n}));Ls.displayName="Separator";function Id(e,t){const r=f.createContext(t),n=s=>{const{children:i,...a}=s,c=f.useMemo(()=>a,Object.values(a));return m.jsx(r.Provider,{value:c,children:i})};n.displayName=e+"Provider";function o(s){const i=f.useContext(r);if(i)return i;if(t!==void 0)return t;throw new Error(`\`${s}\` must be used within \`${e}\``)}return[n,o]}function Ke(e,t=[]){let r=[];function n(s,i){const a=f.createContext(i),c=r.length;r=[...r,i];const l=d=>{var y;const{scope:p,children:g,...v}=d,h=((y=p==null?void 0:p[e])==null?void 0:y[c])||a,b=f.useMemo(()=>v,Object.values(v));return m.jsx(h.Provider,{value:b,children:g})};l.displayName=s+"Provider";function u(d,p){var h;const g=((h=p==null?void 0:p[e])==null?void 0:h[c])||a,v=f.useContext(g);if(v)return v;if(i!==void 0)return i;throw new Error(`\`${d}\` must be used within \`${s}\``)}return[l,u]}const o=()=>{const s=r.map(i=>f.createContext(i));return function(a){const c=(a==null?void 0:a[e])||s;return f.useMemo(()=>({[`__scope${e}`]:{...a,[e]:c}}),[a,c])}};return o.scopeName=e,[n,Od(o,...t)]}function Od(...e){const t=e[0];if(e.length===1)return t;const r=()=>{const n=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(s){const i=n.reduce((a,{useScope:c,scopeName:l})=>{const d=c(s)[`__scope${l}`];return{...a,...d}},{});return f.useMemo(()=>({[`__scope${t.scopeName}`]:i}),[i])}};return r.scopeName=t.scopeName,r}function $s(e){const t=e+"CollectionProvider",[r,n]=Ke(t),[o,s]=r(t,{collectionRef:{current:null},itemMap:new Map}),i=h=>{const{scope:b,children:y}=h,x=E.useRef(null),w=E.useRef(new Map).current;return m.jsx(o,{scope:b,itemMap:w,collectionRef:x,children:y})};i.displayName=t;const a=e+"CollectionSlot",c=bt(a),l=E.forwardRef((h,b)=>{const{scope:y,children:x}=h,w=s(a,y),C=ee(b,w.collectionRef);return m.jsx(c,{ref:C,children:x})});l.displayName=a;const u=e+"CollectionItemSlot",d="data-radix-collection-item",p=bt(u),g=E.forwardRef((h,b)=>{const{scope:y,children:x,...w}=h,C=E.useRef(null),S=ee(b,C),A=s(u,y);return E.useEffect(()=>(A.itemMap.set(C,{ref:C,...w}),()=>void A.itemMap.delete(C))),m.jsx(p,{[d]:"",ref:S,children:x})});g.displayName=u;function v(h){const b=s(e+"CollectionConsumer",h);return E.useCallback(()=>{const x=b.collectionRef.current;if(!x)return[];const w=Array.from(x.querySelectorAll(`[${d}]`));return Array.from(b.itemMap.values()).sort((A,R)=>w.indexOf(A.ref.current)-w.indexOf(R.ref.current))},[b.collectionRef,b.itemMap])}return[{Provider:i,Slot:l,ItemSlot:g},v,n]}function Q(e,t,{checkForDefaultPrevented:r=!0}={}){return function(o){if(e==null||e(o),r===!1||!o.defaultPrevented)return t==null?void 0:t(o)}}var le=globalThis!=null&&globalThis.document?f.useLayoutEffect:()=>{},_d=f[" useInsertionEffect ".trim().toString()]||le;function et({prop:e,defaultProp:t,onChange:r=()=>{},caller:n}){const[o,s,i]=jd({defaultProp:t,onChange:r}),a=e!==void 0,c=a?e:o;{const u=f.useRef(e!==void 0);f.useEffect(()=>{const d=u.current;d!==a&&console.warn(`${n} is changing from ${d?"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.`),u.current=a},[a,n])}const l=f.useCallback(u=>{var d;if(a){const p=Ld(u)?u(e):u;p!==e&&((d=i.current)==null||d.call(i,p))}else s(u)},[a,e,s,i]);return[c,l]}function jd({defaultProp:e,onChange:t}){const[r,n]=f.useState(e),o=f.useRef(r),s=f.useRef(t);return _d(()=>{s.current=t},[t]),f.useEffect(()=>{var i;o.current!==r&&((i=s.current)==null||i.call(s,r),o.current=r)},[r,o]),[r,n,s]}function Ld(e){return typeof e=="function"}function $d(e,t){return f.useReducer((r,n)=>t[r][n]??r,e)}var St=e=>{const{present:t,children:r}=e,n=zd(t),o=typeof r=="function"?r({present:n.isPresent}):f.Children.only(r),s=ee(n.ref,Bd(o));return typeof r=="function"||n.isPresent?f.cloneElement(o,{ref:s}):null};St.displayName="Presence";function zd(e){const[t,r]=f.useState(),n=f.useRef(null),o=f.useRef(e),s=f.useRef("none"),i=e?"mounted":"unmounted",[a,c]=$d(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return f.useEffect(()=>{const l=Ft(n.current);s.current=a==="mounted"?l:"none"},[a]),le(()=>{const l=n.current,u=o.current;if(u!==e){const p=s.current,g=Ft(l);e?c("MOUNT"):g==="none"||(l==null?void 0:l.display)==="none"?c("UNMOUNT"):c(u&&p!==g?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,c]),le(()=>{if(t){let l;const u=t.ownerDocument.defaultView??window,d=g=>{const h=Ft(n.current).includes(CSS.escape(g.animationName));if(g.target===t&&h&&(c("ANIMATION_END"),!o.current)){const b=t.style.animationFillMode;t.style.animationFillMode="forwards",l=u.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=b)})}},p=g=>{g.target===t&&(s.current=Ft(n.current))};return t.addEventListener("animationstart",p),t.addEventListener("animationcancel",d),t.addEventListener("animationend",d),()=>{u.clearTimeout(l),t.removeEventListener("animationstart",p),t.removeEventListener("animationcancel",d),t.removeEventListener("animationend",d)}}else c("ANIMATION_END")},[t,c]),{isPresent:["mounted","unmountSuspended"].includes(a),ref:f.useCallback(l=>{n.current=l?getComputedStyle(l):null,r(l)},[])}}function Ft(e){return(e==null?void 0:e.animationName)||"none"}function Bd(e){var n,o;let t=(n=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:n.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}var Fd=f[" useId ".trim().toString()]||(()=>{}),Vd=0;function He(e){const[t,r]=f.useState(Fd());return le(()=>{r(n=>n??String(Vd++))},[e]),e||(t?`radix-${t}`:"")}var dr="Collapsible",[Wd,zs]=Ke(dr),[Hd,en]=Wd(dr),Bs=f.forwardRef((e,t)=>{const{__scopeCollapsible:r,open:n,defaultOpen:o,disabled:s,onOpenChange:i,...a}=e,[c,l]=et({prop:n,defaultProp:o??!1,onChange:i,caller:dr});return m.jsx(Hd,{scope:r,disabled:s,contentId:He(),open:c,onOpenToggle:f.useCallback(()=>l(u=>!u),[l]),children:m.jsx(K.div,{"data-state":rn(c),"data-disabled":s?"":void 0,...a,ref:t})})});Bs.displayName=dr;var Fs="CollapsibleTrigger",Vs=f.forwardRef((e,t)=>{const{__scopeCollapsible:r,...n}=e,o=en(Fs,r);return m.jsx(K.button,{type:"button","aria-controls":o.contentId,"aria-expanded":o.open||!1,"data-state":rn(o.open),"data-disabled":o.disabled?"":void 0,disabled:o.disabled,...n,ref:t,onClick:Q(e.onClick,o.onOpenToggle)})});Vs.displayName=Fs;var tn="CollapsibleContent",Ws=f.forwardRef((e,t)=>{const{forceMount:r,...n}=e,o=en(tn,e.__scopeCollapsible);return m.jsx(St,{present:r||o.open,children:({present:s})=>m.jsx(Gd,{...n,ref:t,present:s})})});Ws.displayName=tn;var Gd=f.forwardRef((e,t)=>{const{__scopeCollapsible:r,present:n,children:o,...s}=e,i=en(tn,r),[a,c]=f.useState(n),l=f.useRef(null),u=ee(t,l),d=f.useRef(0),p=d.current,g=f.useRef(0),v=g.current,h=i.open||a,b=f.useRef(h),y=f.useRef(void 0);return f.useEffect(()=>{const x=requestAnimationFrame(()=>b.current=!1);return()=>cancelAnimationFrame(x)},[]),le(()=>{const x=l.current;if(x){y.current=y.current||{transitionDuration:x.style.transitionDuration,animationName:x.style.animationName},x.style.transitionDuration="0s",x.style.animationName="none";const w=x.getBoundingClientRect();d.current=w.height,g.current=w.width,b.current||(x.style.transitionDuration=y.current.transitionDuration,x.style.animationName=y.current.animationName),c(n)}},[i.open,n]),m.jsx(K.div,{"data-state":rn(i.open),"data-disabled":i.disabled?"":void 0,id:i.contentId,hidden:!h,...s,ref:u,style:{"--radix-collapsible-content-height":p?`${p}px`:void 0,"--radix-collapsible-content-width":v?`${v}px`:void 0,...e.style},children:h&&o})});function rn(e){return e?"open":"closed"}var Ud=Bs,Yd=Vs,Kd=Ws,Xd=f.createContext(void 0);function Hs(e){const t=f.useContext(Xd);return e||t||"ltr"}var Re="Accordion",qd=["Home","End","ArrowDown","ArrowUp","ArrowLeft","ArrowRight"],[nn,Zd,Qd]=$s(Re),[ur]=Ke(Re,[Qd,zs]),on=zs(),Gs=E.forwardRef((e,t)=>{const{type:r,...n}=e,o=n,s=n;return m.jsx(nn.Provider,{scope:e.__scopeAccordion,children:r==="multiple"?m.jsx(ru,{...s,ref:t}):m.jsx(tu,{...o,ref:t})})});Gs.displayName=Re;var[Us,Jd]=ur(Re),[Ys,eu]=ur(Re,{collapsible:!1}),tu=E.forwardRef((e,t)=>{const{value:r,defaultValue:n,onValueChange:o=()=>{},collapsible:s=!1,...i}=e,[a,c]=et({prop:r,defaultProp:n??"",onChange:o,caller:Re});return m.jsx(Us,{scope:e.__scopeAccordion,value:E.useMemo(()=>a?[a]:[],[a]),onItemOpen:c,onItemClose:E.useCallback(()=>s&&c(""),[s,c]),children:m.jsx(Ys,{scope:e.__scopeAccordion,collapsible:s,children:m.jsx(Ks,{...i,ref:t})})})}),ru=E.forwardRef((e,t)=>{const{value:r,defaultValue:n,onValueChange:o=()=>{},...s}=e,[i,a]=et({prop:r,defaultProp:n??[],onChange:o,caller:Re}),c=E.useCallback(u=>a((d=[])=>[...d,u]),[a]),l=E.useCallback(u=>a((d=[])=>d.filter(p=>p!==u)),[a]);return m.jsx(Us,{scope:e.__scopeAccordion,value:i,onItemOpen:c,onItemClose:l,children:m.jsx(Ys,{scope:e.__scopeAccordion,collapsible:!0,children:m.jsx(Ks,{...s,ref:t})})})}),[nu,fr]=ur(Re),Ks=E.forwardRef((e,t)=>{const{__scopeAccordion:r,disabled:n,dir:o,orientation:s="vertical",...i}=e,a=E.useRef(null),c=ee(a,t),l=Zd(r),d=Hs(o)==="ltr",p=Q(e.onKeyDown,g=>{var O;if(!qd.includes(g.key))return;const v=g.target,h=l().filter($=>{var L;return!((L=$.ref.current)!=null&&L.disabled)}),b=h.findIndex($=>$.ref.current===v),y=h.length;if(b===-1)return;g.preventDefault();let x=b;const w=0,C=y-1,S=()=>{x=b+1,x>C&&(x=w)},A=()=>{x=b-1,x<w&&(x=C)};switch(g.key){case"Home":x=w;break;case"End":x=C;break;case"ArrowRight":s==="horizontal"&&(d?S():A());break;case"ArrowDown":s==="vertical"&&S();break;case"ArrowLeft":s==="horizontal"&&(d?A():S());break;case"ArrowUp":s==="vertical"&&A();break}const R=x%y;(O=h[R].ref.current)==null||O.focus()});return m.jsx(nu,{scope:r,disabled:n,direction:o,orientation:s,children:m.jsx(nn.Slot,{scope:r,children:m.jsx(K.div,{...i,"data-orientation":s,ref:c,onKeyDown:n?void 0:p})})})}),Jt="AccordionItem",[ou,sn]=ur(Jt),Xs=E.forwardRef((e,t)=>{const{__scopeAccordion:r,value:n,...o}=e,s=fr(Jt,r),i=Jd(Jt,r),a=on(r),c=He(),l=n&&i.value.includes(n)||!1,u=s.disabled||e.disabled;return m.jsx(ou,{scope:r,open:l,disabled:u,triggerId:c,children:m.jsx(Ud,{"data-orientation":s.orientation,"data-state":ti(l),...a,...o,ref:t,disabled:u,open:l,onOpenChange:d=>{d?i.onItemOpen(n):i.onItemClose(n)}})})});Xs.displayName=Jt;var qs="AccordionHeader",Zs=E.forwardRef((e,t)=>{const{__scopeAccordion:r,...n}=e,o=fr(Re,r),s=sn(qs,r);return m.jsx(K.h3,{"data-orientation":o.orientation,"data-state":ti(s.open),"data-disabled":s.disabled?"":void 0,...n,ref:t})});Zs.displayName=qs;var zr="AccordionTrigger",Qs=E.forwardRef((e,t)=>{const{__scopeAccordion:r,...n}=e,o=fr(Re,r),s=sn(zr,r),i=eu(zr,r),a=on(r);return m.jsx(nn.ItemSlot,{scope:r,children:m.jsx(Yd,{"aria-disabled":s.open&&!i.collapsible||void 0,"data-orientation":o.orientation,id:s.triggerId,...a,...n,ref:t})})});Qs.displayName=zr;var Js="AccordionContent",ei=E.forwardRef((e,t)=>{const{__scopeAccordion:r,...n}=e,o=fr(Re,r),s=sn(Js,r),i=on(r);return m.jsx(Kd,{role:"region","aria-labelledby":s.triggerId,"data-orientation":o.orientation,...i,...n,ref:t,style:{"--radix-accordion-content-height":"var(--radix-collapsible-content-height)","--radix-accordion-content-width":"var(--radix-collapsible-content-width)",...e.style}})});ei.displayName=Js;function ti(e){return e?"open":"closed"}var su=Gs,iu=Xs,au=Zs,ri=Qs,ni=ei;const lu=su,oi=f.forwardRef(({className:e,...t},r)=>m.jsx(iu,{ref:r,className:G("border rounded-lg",e),...t}));oi.displayName="AccordionItem";const si=f.forwardRef(({className:e,children:t,...r},n)=>m.jsx(au,{className:"flex",children:m.jsxs(ri,{ref:n,className:G("flex flex-1 items-center justify-between py-4 px-4 text-left text-sm font-medium transition-all hover:underline",e),...r,children:[t,m.jsx("span",{className:"ml-2",children:"▾"})]})}));si.displayName=ri.displayName;const ii=f.forwardRef(({className:e,children:t,...r},n)=>m.jsx(ni,{ref:n,className:G("px-4 pb-4 text-sm text-muted-foreground",e),...r,children:t}));ii.displayName=ni.displayName;function tt(e){const t=f.useRef(e);return f.useEffect(()=>{t.current=e}),f.useMemo(()=>(...r)=>{var n;return(n=t.current)==null?void 0:n.call(t,...r)},[])}function cu(e,t=globalThis==null?void 0:globalThis.document){const r=tt(e);f.useEffect(()=>{const n=o=>{o.key==="Escape"&&r(o)};return t.addEventListener("keydown",n,{capture:!0}),()=>t.removeEventListener("keydown",n,{capture:!0})},[r,t])}var du="DismissableLayer",Br="dismissableLayer.update",uu="dismissableLayer.pointerDownOutside",fu="dismissableLayer.focusOutside",To,ai=f.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),an=f.forwardRef((e,t)=>{const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:n,onPointerDownOutside:o,onFocusOutside:s,onInteractOutside:i,onDismiss:a,...c}=e,l=f.useContext(ai),[u,d]=f.useState(null),p=(u==null?void 0:u.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,g]=f.useState({}),v=ee(t,R=>d(R)),h=Array.from(l.layers),[b]=[...l.layersWithOutsidePointerEventsDisabled].slice(-1),y=h.indexOf(b),x=u?h.indexOf(u):-1,w=l.layersWithOutsidePointerEventsDisabled.size>0,C=x>=y,S=mu(R=>{const O=R.target,$=[...l.branches].some(L=>L.contains(O));!C||$||(o==null||o(R),i==null||i(R),R.defaultPrevented||a==null||a())},p),A=gu(R=>{const O=R.target;[...l.branches].some(L=>L.contains(O))||(s==null||s(R),i==null||i(R),R.defaultPrevented||a==null||a())},p);return cu(R=>{x===l.layers.size-1&&(n==null||n(R),!R.defaultPrevented&&a&&(R.preventDefault(),a()))},p),f.useEffect(()=>{if(u)return r&&(l.layersWithOutsidePointerEventsDisabled.size===0&&(To=p.body.style.pointerEvents,p.body.style.pointerEvents="none"),l.layersWithOutsidePointerEventsDisabled.add(u)),l.layers.add(u),ko(),()=>{r&&l.layersWithOutsidePointerEventsDisabled.size===1&&(p.body.style.pointerEvents=To)}},[u,p,r,l]),f.useEffect(()=>()=>{u&&(l.layers.delete(u),l.layersWithOutsidePointerEventsDisabled.delete(u),ko())},[u,l]),f.useEffect(()=>{const R=()=>g({});return document.addEventListener(Br,R),()=>document.removeEventListener(Br,R)},[]),m.jsx(K.div,{...c,ref:v,style:{pointerEvents:w?C?"auto":"none":void 0,...e.style},onFocusCapture:Q(e.onFocusCapture,A.onFocusCapture),onBlurCapture:Q(e.onBlurCapture,A.onBlurCapture),onPointerDownCapture:Q(e.onPointerDownCapture,S.onPointerDownCapture)})});an.displayName=du;var pu="DismissableLayerBranch",hu=f.forwardRef((e,t)=>{const r=f.useContext(ai),n=f.useRef(null),o=ee(t,n);return f.useEffect(()=>{const s=n.current;if(s)return r.branches.add(s),()=>{r.branches.delete(s)}},[r.branches]),m.jsx(K.div,{...e,ref:o})});hu.displayName=pu;function mu(e,t=globalThis==null?void 0:globalThis.document){const r=tt(e),n=f.useRef(!1),o=f.useRef(()=>{});return f.useEffect(()=>{const s=a=>{if(a.target&&!n.current){let c=function(){li(uu,r,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);n.current=!1},i=window.setTimeout(()=>{t.addEventListener("pointerdown",s)},0);return()=>{window.clearTimeout(i),t.removeEventListener("pointerdown",s),t.removeEventListener("click",o.current)}},[t,r]),{onPointerDownCapture:()=>n.current=!0}}function gu(e,t=globalThis==null?void 0:globalThis.document){const r=tt(e),n=f.useRef(!1);return f.useEffect(()=>{const o=s=>{s.target&&!n.current&&li(fu,r,{originalEvent:s},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,r]),{onFocusCapture:()=>n.current=!0,onBlurCapture:()=>n.current=!1}}function ko(){const e=new CustomEvent(Br);document.dispatchEvent(e)}function li(e,t,r,{discrete:n}){const o=r.originalEvent.target,s=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:r});t&&o.addEventListener(e,t,{once:!0}),n?Jc(o,s):o.dispatchEvent(s)}var Pr="focusScope.autoFocusOnMount",Tr="focusScope.autoFocusOnUnmount",Do={bubbles:!1,cancelable:!0},vu="FocusScope",ln=f.forwardRef((e,t)=>{const{loop:r=!1,trapped:n=!1,onMountAutoFocus:o,onUnmountAutoFocus:s,...i}=e,[a,c]=f.useState(null),l=tt(o),u=tt(s),d=f.useRef(null),p=ee(t,h=>c(h)),g=f.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;f.useEffect(()=>{if(n){let h=function(w){if(g.paused||!a)return;const C=w.target;a.contains(C)?d.current=C:We(d.current,{select:!0})},b=function(w){if(g.paused||!a)return;const C=w.relatedTarget;C!==null&&(a.contains(C)||We(d.current,{select:!0}))},y=function(w){if(document.activeElement===document.body)for(const S of w)S.removedNodes.length>0&&We(a)};document.addEventListener("focusin",h),document.addEventListener("focusout",b);const x=new MutationObserver(y);return a&&x.observe(a,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",h),document.removeEventListener("focusout",b),x.disconnect()}}},[n,a,g.paused]),f.useEffect(()=>{if(a){Io.add(g);const h=document.activeElement;if(!a.contains(h)){const y=new CustomEvent(Pr,Do);a.addEventListener(Pr,l),a.dispatchEvent(y),y.defaultPrevented||(yu(Su(ci(a)),{select:!0}),document.activeElement===h&&We(a))}return()=>{a.removeEventListener(Pr,l),setTimeout(()=>{const y=new CustomEvent(Tr,Do);a.addEventListener(Tr,u),a.dispatchEvent(y),y.defaultPrevented||We(h??document.body,{select:!0}),a.removeEventListener(Tr,u),Io.remove(g)},0)}}},[a,l,u,g]);const v=f.useCallback(h=>{if(!r&&!n||g.paused)return;const b=h.key==="Tab"&&!h.altKey&&!h.ctrlKey&&!h.metaKey,y=document.activeElement;if(b&&y){const x=h.currentTarget,[w,C]=bu(x);w&&C?!h.shiftKey&&y===C?(h.preventDefault(),r&&We(w,{select:!0})):h.shiftKey&&y===w&&(h.preventDefault(),r&&We(C,{select:!0})):y===x&&h.preventDefault()}},[r,n,g.paused]);return m.jsx(K.div,{tabIndex:-1,...i,ref:p,onKeyDown:v})});ln.displayName=vu;function yu(e,{select:t=!1}={}){const r=document.activeElement;for(const n of e)if(We(n,{select:t}),document.activeElement!==r)return}function bu(e){const t=ci(e),r=Mo(t,e),n=Mo(t.reverse(),e);return[r,n]}function ci(e){const t=[],r=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:n=>{const o=n.tagName==="INPUT"&&n.type==="hidden";return n.disabled||n.hidden||o?NodeFilter.FILTER_SKIP:n.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;r.nextNode();)t.push(r.currentNode);return t}function Mo(e,t){for(const r of e)if(!xu(r,{upTo:t}))return r}function xu(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 wu(e){return e instanceof HTMLInputElement&&"select"in e}function We(e,{select:t=!1}={}){if(e&&e.focus){const r=document.activeElement;e.focus({preventScroll:!0}),e!==r&&wu(e)&&t&&e.select()}}var Io=Cu();function Cu(){let e=[];return{add(t){const r=e[0];t!==r&&(r==null||r.pause()),e=Oo(e,t),e.unshift(t)},remove(t){var r;e=Oo(e,t),(r=e[0])==null||r.resume()}}}function Oo(e,t){const r=[...e],n=r.indexOf(t);return n!==-1&&r.splice(n,1),r}function Su(e){return e.filter(t=>t.tagName!=="A")}var Eu="Portal",cn=f.forwardRef((e,t)=>{var a;const{container:r,...n}=e,[o,s]=f.useState(!1);le(()=>s(!0),[]);const i=r||o&&((a=globalThis==null?void 0:globalThis.document)==null?void 0:a.body);return i?ir.createPortal(m.jsx(K.div,{...n,ref:t}),i):null});cn.displayName=Eu;var kr=0;function di(){f.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??_o()),document.body.insertAdjacentElement("beforeend",e[1]??_o()),kr++,()=>{kr===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),kr--}},[])}function _o(){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 Pe=function(){return Pe=Object.assign||function(t){for(var r,n=1,o=arguments.length;n<o;n++){r=arguments[n];for(var s in r)Object.prototype.hasOwnProperty.call(r,s)&&(t[s]=r[s])}return t},Pe.apply(this,arguments)};function ui(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r}function Ru(e,t,r){if(r||arguments.length===2)for(var n=0,o=t.length,s;n<o;n++)(s||!(n in t))&&(s||(s=Array.prototype.slice.call(t,0,n)),s[n]=t[n]);return e.concat(s||Array.prototype.slice.call(t))}var Xt="right-scroll-bar-position",qt="width-before-scroll-bar",Au="with-scroll-bars-hidden",Nu="--removed-body-scroll-bar-size";function Dr(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function Pu(e,t){var r=E.useState(function(){return{value:e,callback:t,facade:{get current(){return r.value},set current(n){var o=r.value;o!==n&&(r.value=n,r.callback(n,o))}}}})[0];return r.callback=t,r.facade}var Tu=typeof window<"u"?f.useLayoutEffect:f.useEffect,jo=new WeakMap;function ku(e,t){var r=Pu(null,function(n){return e.forEach(function(o){return Dr(o,n)})});return Tu(function(){var n=jo.get(r);if(n){var o=new Set(n),s=new Set(e),i=r.current;o.forEach(function(a){s.has(a)||Dr(a,null)}),s.forEach(function(a){o.has(a)||Dr(a,i)})}jo.set(r,e)},[e]),r}function Du(e){return e}function Mu(e,t){t===void 0&&(t=Du);var r=[],n=!1,o={read:function(){if(n)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return r.length?r[r.length-1]:e},useMedium:function(s){var i=t(s,n);return r.push(i),function(){r=r.filter(function(a){return a!==i})}},assignSyncMedium:function(s){for(n=!0;r.length;){var i=r;r=[],i.forEach(s)}r={push:function(a){return s(a)},filter:function(){return r}}},assignMedium:function(s){n=!0;var i=[];if(r.length){var a=r;r=[],a.forEach(s),i=r}var c=function(){var u=i;i=[],u.forEach(s)},l=function(){return Promise.resolve().then(c)};l(),r={push:function(u){i.push(u),l()},filter:function(u){return i=i.filter(u),r}}}};return o}function Iu(e){e===void 0&&(e={});var t=Mu(null);return t.options=Pe({async:!0,ssr:!1},e),t}var fi=function(e){var t=e.sideCar,r=ui(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var n=t.read();if(!n)throw new Error("Sidecar medium not found");return f.createElement(n,Pe({},r))};fi.isSideCarExport=!0;function Ou(e,t){return e.useMedium(t),fi}var pi=Iu(),Mr=function(){},pr=f.forwardRef(function(e,t){var r=f.useRef(null),n=f.useState({onScrollCapture:Mr,onWheelCapture:Mr,onTouchMoveCapture:Mr}),o=n[0],s=n[1],i=e.forwardProps,a=e.children,c=e.className,l=e.removeScrollBar,u=e.enabled,d=e.shards,p=e.sideCar,g=e.noRelative,v=e.noIsolation,h=e.inert,b=e.allowPinchZoom,y=e.as,x=y===void 0?"div":y,w=e.gapMode,C=ui(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),S=p,A=ku([r,t]),R=Pe(Pe({},C),o);return f.createElement(f.Fragment,null,u&&f.createElement(S,{sideCar:pi,removeScrollBar:l,shards:d,noRelative:g,noIsolation:v,inert:h,setCallbacks:s,allowPinchZoom:!!b,lockRef:r,gapMode:w}),i?f.cloneElement(f.Children.only(a),Pe(Pe({},R),{ref:A})):f.createElement(x,Pe({},R,{className:c,ref:A}),a))});pr.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};pr.classNames={fullWidth:qt,zeroRight:Xt};var _u=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function ju(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=_u();return t&&e.setAttribute("nonce",t),e}function Lu(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function $u(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var zu=function(){var e=0,t=null;return{add:function(r){e==0&&(t=ju())&&(Lu(t,r),$u(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},Bu=function(){var e=zu();return function(t,r){f.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&r])}},hi=function(){var e=Bu(),t=function(r){var n=r.styles,o=r.dynamic;return e(n,o),null};return t},Fu={left:0,top:0,right:0,gap:0},Ir=function(e){return parseInt(e||"",10)||0},Vu=function(e){var t=window.getComputedStyle(document.body),r=t[e==="padding"?"paddingLeft":"marginLeft"],n=t[e==="padding"?"paddingTop":"marginTop"],o=t[e==="padding"?"paddingRight":"marginRight"];return[Ir(r),Ir(n),Ir(o)]},Wu=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return Fu;var t=Vu(e),r=document.documentElement.clientWidth,n=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,n-r+t[2]-t[0])}},Hu=hi(),gt="data-scroll-locked",Gu=function(e,t,r,n){var o=e.left,s=e.top,i=e.right,a=e.gap;return r===void 0&&(r="margin"),`
19
+ `;const u=document.createElement("canvas");u.width=s,u.height=i,u.style.cssText="border-radius: 8px;",l.appendChild(u);let d=null,p=[],g=null,v=!1;const h=()=>{if(v)return;d=new Ao.Illustration({element:u,zoom:1,rotate:{y:0}});const y=(k,P,_)=>{const I=new Ao.Ellipse({addTo:d,diameter:a,stroke:!1,fill:!0,color:"#5e0f1a"});p.push({shape:I,id:_,group:k,offset:P})};let x=0;for(let k=0;k<6;k++)y("left",k/6,x++);for(let k=0;k<6;k++)y("right",k/6,x++);const w=k=>1-Math.pow(1-k,2),C=(k,P,_)=>k+(P-k)*_,S=k=>({r:parseInt(k.slice(1,3),16),g:parseInt(k.slice(3,5),16),b:parseInt(k.slice(5,7),16)}),A=["#5e0f1a","#c22a2f","#e0392b","#f05a24","#f39c12","#fde68a"].map(S),R=[...A].reverse(),O=(k,P)=>{if(P<=0)return k[0];if(P>=1)return k[k.length-1];const _=P*(k.length-1),I=Math.floor(_),D=_-I,N=k[I],M=k[I+1];return{r:Math.round(C(N.r,M.r,D)),g:Math.round(C(N.g,M.g,D)),b:Math.round(C(N.b,M.b,D))}};p.forEach(({shape:k,group:P,offset:_,id:I})=>{let D,N,M,T=1;if(P==="left"){const j=_,U=w(j);D=-c+c*U,N=Math.PI/2*U,M=300+(100-Math.abs(D))-I*.01;const{r:V,g:se,b:B}=O(A,j);k.color=`rgba(${V}, ${se}, ${B}, ${T})`}else{const j=_,U=w(j);D=0+c*U,N=Math.PI/2+Math.PI/2*U,M=300+(100-Math.abs(D))-I*.01;const{r:V,g:se,b:B}=O(R,j);k.color=`rgba(${V}, ${se}, ${B}, ${T})`}k.translate.x=D,k.translate.z=M,k.rotate.y=N}),d.updateRenderGraph();const $=(k,P,_,I)=>{let D,N,M,T;const j=Math.min(_,1),U=V=>V<.5?2*V*V:1-Math.pow(-2*V+2,2)/2;if(P==="left"){const V=U(j);D=-c+c*V,N=Math.PI/2*V,M=1,T=300+(100-Math.abs(D))-I*.01;const{r:se,g:B,b:X}=O(A,j);k.color=`rgba(${se}, ${B}, ${X}, ${M})`}else{const V=U(j);D=0+c*V,N=Math.PI/2+Math.PI/2*V,M=1,T=300+(100-Math.abs(D))-I*.01;const{r:se,g:B,b:X}=O(R,j);k.color=`rgba(${se}, ${B}, ${X}, ${M})`}k.translate.x=D,k.translate.z=T,k.rotate.y=N},L=k=>{if(v||!d||!p.length)return;const P=k%r/r;for(let _=0;_<p.length;_++){const I=p[_];let D=(P+I.offset)%1;if(D<.02){const N=D/.02;$(I.shape,I.group,0,I.id);const M=I.shape.color.match(/rgba?\((\d+),\s*(\d+),\s*(\d+),\s*([^)]+)\)/);if(M){const T=parseFloat(M[4]);I.shape.color=`rgba(${M[1]}, ${M[2]}, ${M[3]}, ${T*N})`}I.shape.translate.z=100-I.id*.01}else if(D>.98){const N=(1-D)/.02,M=(.98-.02)/.96;$(I.shape,I.group,M,I.id);const T=I.shape.color.match(/rgba?\((\d+),\s*(\d+),\s*(\d+),\s*([^)]+)\)/);if(T){const j=parseFloat(T[4]);I.shape.color=`rgba(${T[1]}, ${T[2]}, ${T[3]}, ${j*N})`}}else{const N=(D-.02)/.96;$(I.shape,I.group,N,I.id)}}d.updateRenderGraph(),v||(g=requestAnimationFrame(L))};g=requestAnimationFrame(L)},b=()=>{v=!0,g&&(cancelAnimationFrame(g),g=null),p=[],d=null};return h(),{element:l,destroy:b}}const Jr=Ot("inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium ring-offset-background 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-primary text-primary-foreground hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground hover:bg-destructive/90",outline:"border border-input bg-background hover:bg-[#EDEBEB]",secondary:"bg-secondary text-secondary-foreground hover:bg-[#EDEBEB]",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-10 px-4 py-2",sm:"h-9 rounded-md px-3",lg:"h-11 rounded-md px-8",icon:"h-10 w-10"}},defaultVariants:{variant:"default",size:"default"}}),ys=f.forwardRef(({className:e,variant:t,size:r,asChild:n=!1,...o},s)=>{const i=n?oc:"button";return m.jsx(i,{className:it(Jr({variant:t,size:r,className:e})),ref:s,...o})});ys.displayName="Button";const bs=f.forwardRef(({className:e,...t},r)=>m.jsx("div",{ref:r,className:it("rounded-lg border bg-card text-card-foreground shadow-sm",e),...t}));bs.displayName="Card";const xs=f.forwardRef(({className:e,...t},r)=>m.jsx("div",{ref:r,className:it("flex flex-col space-y-1.5 p-6",e),...t}));xs.displayName="CardHeader";const ws=f.forwardRef(({className:e,...t},r)=>m.jsx("h3",{ref:r,className:it("text-2xl font-semibold leading-none tracking-tight",e),...t}));ws.displayName="CardTitle";const Cs=f.forwardRef(({className:e,...t},r)=>m.jsx("p",{ref:r,className:it("text-sm text-muted-foreground",e),...t}));Cs.displayName="CardDescription";const Ss=f.forwardRef(({className:e,...t},r)=>m.jsx("div",{ref:r,className:it("p-6 pt-0",e),...t}));Ss.displayName="CardContent";function G(...e){return ds(Zr(e))}const Es=f.forwardRef(({className:e,type:t,error:r,...n},o)=>m.jsx("input",{type:t,className:G("flex h-10 w-full rounded-md border border-gray-300 bg-white px-3 py-2 text-sm ring-offset-white file:border-0 file:bg-transparent file:text-sm file:font-medium placeholder:text-gray-500 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-blue-500 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",r&&"border-red-500 focus-visible:ring-red-500",e),ref:o,...n}));Es.displayName="Input";var Qc=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],K=Qc.reduce((e,t)=>{const r=bt(`Primitive.${t}`),n=f.forwardRef((o,s)=>{const{asChild:i,...a}=o,c=i?r:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),m.jsx(c,{...a,ref:s})});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function Jc(e,t){e&&ar.flushSync(()=>e.dispatchEvent(t))}var ed="Label",Rs=f.forwardRef((e,t)=>m.jsx(K.label,{...e,ref:t,onMouseDown:r=>{var o;r.target.closest("button, input, select, textarea")||((o=e.onMouseDown)==null||o.call(e,r),!r.defaultPrevented&&r.detail>1&&r.preventDefault())}}));Rs.displayName=ed;var As=Rs;const td=Ot("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),Ns=f.forwardRef(({className:e,...t},r)=>m.jsx(As,{ref:r,className:G(td(),e),...t}));Ns.displayName=As.displayName;const rd=Ot("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-white text-gray-900 border-gray-200",destructive:"border-red-500/50 text-red-900 dark:border-red-500 [&>svg]:text-red-500 bg-red-50",success:"border-green-500/50 text-green-900 dark:border-green-500 [&>svg]:text-green-500 bg-green-50",warning:"border-yellow-500/50 text-yellow-900 dark:border-yellow-500 [&>svg]:text-yellow-500 bg-yellow-50"}},defaultVariants:{variant:"default"}}),Ps=f.forwardRef(({className:e,variant:t,...r},n)=>m.jsx("div",{ref:n,role:"alert",className:G(rd({variant:t}),e),...r}));Ps.displayName="Alert";const Ts=f.forwardRef(({className:e,...t},r)=>m.jsx("div",{ref:r,className:G("text-sm [&_p]:leading-relaxed",e),...t}));Ts.displayName="AlertDescription";const ks=f.forwardRef(({className:e,...t},r)=>m.jsx("h5",{ref:r,className:G("mb-1 font-medium leading-none tracking-tight",e),...t}));ks.displayName="AlertTitle";const Ds=f.forwardRef(({className:e,error:t,...r},n)=>m.jsx("textarea",{className:G("flex min-h-[80px] w-full rounded-md border border-gray-300 bg-white px-3 py-2 text-sm ring-offset-white placeholder:text-gray-500 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-blue-500 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",t&&"border-red-500 focus-visible:ring-red-500",e),ref:n,...r}));Ds.displayName="Textarea";const nd=Ot("animate-spin rounded-full border-2 border-current border-t-transparent",{variants:{size:{sm:"h-4 w-4",md:"h-6 w-6",lg:"h-8 w-8",xl:"h-12 w-12"}},defaultVariants:{size:"md"}}),Ms=f.forwardRef(({className:e,size:t,...r},n)=>m.jsx("div",{ref:n,className:G(nd({size:t}),e),...r}));Ms.displayName="Spinner";const od=Ot("relative",{variants:{size:{sm:"w-[140px] h-[105px]",md:"w-[300px] h-[200px]",lg:"w-[400px] h-[250px]",xl:"w-[500px] h-[300px]"}},defaultVariants:{size:"md"}}),Is=E.forwardRef(({className:e,size:t,cycleDuration:r=3e3,...n},o)=>{const s=E.useRef(null),i=E.useRef(null);return E.useEffect(()=>{if(s.current)return i.current&&i.current.destroy(),i.current=Zc({size:t||"md",cycleDuration:r,className:""}),s.current.innerHTML="",s.current.appendChild(i.current.element),()=>{i.current&&(i.current.destroy(),i.current=null)}},[t,r]),m.jsx("div",{ref:a=>{s.current=a,typeof o=="function"?o(a):o&&(o.current=a)},className:G(od({size:t}),e),...n})});Is.displayName="DiscLoader";function sd(e){if(typeof document>"u")return;let t=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",t.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}const id=e=>{switch(e){case"success":return cd;case"info":return ud;case"warning":return dd;case"error":return fd;default:return null}},ad=Array(12).fill(0),ld=({visible:e,className:t})=>E.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},E.createElement("div",{className:"sonner-spinner"},ad.map((r,n)=>E.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${n}`})))),cd=E.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},E.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"})),dd=E.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},E.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"})),ud=E.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},E.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"})),fd=E.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},E.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"})),pd=E.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"},E.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),E.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),hd=()=>{const[e,t]=E.useState(document.hidden);return E.useEffect(()=>{const r=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",r),()=>window.removeEventListener("visibilitychange",r)},[]),e};let $r=1;class md{constructor(){this.subscribe=t=>(this.subscribers.push(t),()=>{const r=this.subscribers.indexOf(t);this.subscribers.splice(r,1)}),this.publish=t=>{this.subscribers.forEach(r=>r(t))},this.addToast=t=>{this.publish(t),this.toasts=[...this.toasts,t]},this.create=t=>{var r;const{message:n,...o}=t,s=typeof(t==null?void 0:t.id)=="number"||((r=t.id)==null?void 0:r.length)>0?t.id:$r++,i=this.toasts.find(c=>c.id===s),a=t.dismissible===void 0?!0:t.dismissible;return this.dismissedToasts.has(s)&&this.dismissedToasts.delete(s),i?this.toasts=this.toasts.map(c=>c.id===s?(this.publish({...c,...t,id:s,title:n}),{...c,...t,id:s,dismissible:a,title:n}):c):this.addToast({title:n,...o,dismissible:a,id:s}),s},this.dismiss=t=>(t?(this.dismissedToasts.add(t),requestAnimationFrame(()=>this.subscribers.forEach(r=>r({id:t,dismiss:!0})))):this.toasts.forEach(r=>{this.subscribers.forEach(n=>n({id:r.id,dismiss:!0}))}),t),this.message=(t,r)=>this.create({...r,message:t}),this.error=(t,r)=>this.create({...r,message:t,type:"error"}),this.success=(t,r)=>this.create({...r,type:"success",message:t}),this.info=(t,r)=>this.create({...r,type:"info",message:t}),this.warning=(t,r)=>this.create({...r,type:"warning",message:t}),this.loading=(t,r)=>this.create({...r,type:"loading",message:t}),this.promise=(t,r)=>{if(!r)return;let n;r.loading!==void 0&&(n=this.create({...r,promise:t,type:"loading",message:r.loading,description:typeof r.description!="function"?r.description:void 0}));const o=Promise.resolve(t instanceof Function?t():t);let s=n!==void 0,i;const a=o.then(async l=>{if(i=["resolve",l],E.isValidElement(l))s=!1,this.create({id:n,type:"default",message:l});else if(vd(l)&&!l.ok){s=!1;const d=typeof r.error=="function"?await r.error(`HTTP error! status: ${l.status}`):r.error,p=typeof r.description=="function"?await r.description(`HTTP error! status: ${l.status}`):r.description,v=typeof d=="object"&&!E.isValidElement(d)?d:{message:d};this.create({id:n,type:"error",description:p,...v})}else if(l instanceof Error){s=!1;const d=typeof r.error=="function"?await r.error(l):r.error,p=typeof r.description=="function"?await r.description(l):r.description,v=typeof d=="object"&&!E.isValidElement(d)?d:{message:d};this.create({id:n,type:"error",description:p,...v})}else if(r.success!==void 0){s=!1;const d=typeof r.success=="function"?await r.success(l):r.success,p=typeof r.description=="function"?await r.description(l):r.description,v=typeof d=="object"&&!E.isValidElement(d)?d:{message:d};this.create({id:n,type:"success",description:p,...v})}}).catch(async l=>{if(i=["reject",l],r.error!==void 0){s=!1;const u=typeof r.error=="function"?await r.error(l):r.error,d=typeof r.description=="function"?await r.description(l):r.description,g=typeof u=="object"&&!E.isValidElement(u)?u:{message:u};this.create({id:n,type:"error",description:d,...g})}}).finally(()=>{s&&(this.dismiss(n),n=void 0),r.finally==null||r.finally.call(r)}),c=()=>new Promise((l,u)=>a.then(()=>i[0]==="reject"?u(i[1]):l(i[1])).catch(u));return typeof n!="string"&&typeof n!="number"?{unwrap:c}:Object.assign(n,{unwrap:c})},this.custom=(t,r)=>{const n=(r==null?void 0:r.id)||$r++;return this.create({jsx:t(n),id:n,...r}),n},this.getActiveToasts=()=>this.toasts.filter(t=>!this.dismissedToasts.has(t.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}}const pe=new md,gd=(e,t)=>{const r=(t==null?void 0:t.id)||$r++;return pe.addToast({title:e,...t,id:r}),r},vd=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",yd=gd,bd=()=>pe.toasts,xd=()=>pe.getActiveToasts(),Dt=Object.assign(yd,{success:pe.success,info:pe.info,warning:pe.warning,error:pe.error,custom:pe.custom,message:pe.message,promise:pe.promise,dismiss:pe.dismiss,loading:pe.loading},{getHistory:bd,getToasts:xd});sd("[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 Ft(e){return e.label!==void 0}const wd=3,Cd="24px",Sd="16px",No=4e3,Ed=356,Rd=14,Ad=45,Nd=200;function Ne(...e){return e.filter(Boolean).join(" ")}function Pd(e){const[t,r]=e.split("-"),n=[];return t&&n.push(t),r&&n.push(r),n}const Td=e=>{var t,r,n,o,s,i,a,c,l;const{invert:u,toast:d,unstyled:p,interacting:g,setHeights:v,visibleToasts:h,heights:b,index:y,toasts:x,expanded:w,removeToast:C,defaultRichColors:S,closeButton:A,style:R,cancelButtonStyle:O,actionButtonStyle:$,className:L="",descriptionClassName:k="",duration:P,position:_,gap:I,expandByDefault:D,classNames:N,icons:M,closeButtonAriaLabel:T="Close toast"}=e,[j,U]=E.useState(null),[V,se]=E.useState(null),[B,X]=E.useState(!1),[J,ne]=E.useState(!1),[z,F]=E.useState(!1),[re,Z]=E.useState(!1),[q,Y]=E.useState(!1),[de,ue]=E.useState(0),[Ze,ze]=E.useState(0),be=E.useRef(d.duration||P||No),jt=E.useRef(null),fe=E.useRef(null),Ul=y===0,Yl=y+1<=h,he=d.type,ct=d.dismissible!==!1,Kl=d.className||"",Xl=d.descriptionClassName||"",Lt=E.useMemo(()=>b.findIndex(W=>W.toastId===d.id)||0,[b,d.id]),ql=E.useMemo(()=>{var W;return(W=d.closeButton)!=null?W:A},[d.closeButton,A]),Dn=E.useMemo(()=>d.duration||P||No,[d.duration,P]),Rr=E.useRef(0),dt=E.useRef(0),Mn=E.useRef(0),ut=E.useRef(null),[Zl,Ql]=_.split("-"),In=E.useMemo(()=>b.reduce((W,ie,ce)=>ce>=Lt?W:W+ie.height,0),[b,Lt]),On=hd(),Jl=d.invert||u,Ar=he==="loading";dt.current=E.useMemo(()=>Lt*I+In,[Lt,In]),E.useEffect(()=>{be.current=Dn},[Dn]),E.useEffect(()=>{X(!0)},[]),E.useEffect(()=>{const W=fe.current;if(W){const ie=W.getBoundingClientRect().height;return ze(ie),v(ce=>[{toastId:d.id,height:ie,position:d.position},...ce]),()=>v(ce=>ce.filter(me=>me.toastId!==d.id))}},[v,d.id]),E.useLayoutEffect(()=>{if(!B)return;const W=fe.current,ie=W.style.height;W.style.height="auto";const ce=W.getBoundingClientRect().height;W.style.height=ie,ze(ce),v(me=>me.find(ae=>ae.toastId===d.id)?me.map(ae=>ae.toastId===d.id?{...ae,height:ce}:ae):[{toastId:d.id,height:ce,position:d.position},...me])},[B,d.title,d.description,v,d.id,d.jsx,d.action,d.cancel]);const Fe=E.useCallback(()=>{ne(!0),ue(dt.current),v(W=>W.filter(ie=>ie.toastId!==d.id)),setTimeout(()=>{C(d)},Nd)},[d,C,v,dt]);E.useEffect(()=>{if(d.promise&&he==="loading"||d.duration===1/0||d.type==="loading")return;let W;return w||g||On?(()=>{if(Mn.current<Rr.current){const me=new Date().getTime()-Rr.current;be.current=be.current-me}Mn.current=new Date().getTime()})():(()=>{be.current!==1/0&&(Rr.current=new Date().getTime(),W=setTimeout(()=>{d.onAutoClose==null||d.onAutoClose.call(d,d),Fe()},be.current))})(),()=>clearTimeout(W)},[w,g,d,he,On,Fe]),E.useEffect(()=>{d.delete&&(Fe(),d.onDismiss==null||d.onDismiss.call(d,d))},[Fe,d.delete]);function ec(){var W;if(M!=null&&M.loading){var ie;return E.createElement("div",{className:Ne(N==null?void 0:N.loader,d==null||(ie=d.classNames)==null?void 0:ie.loader,"sonner-loader"),"data-visible":he==="loading"},M.loading)}return E.createElement(ld,{className:Ne(N==null?void 0:N.loader,d==null||(W=d.classNames)==null?void 0:W.loader),visible:he==="loading"})}const tc=d.icon||(M==null?void 0:M[he])||id(he);var _n,jn;return E.createElement("li",{tabIndex:0,ref:fe,className:Ne(L,Kl,N==null?void 0:N.toast,d==null||(t=d.classNames)==null?void 0:t.toast,N==null?void 0:N.default,N==null?void 0:N[he],d==null||(r=d.classNames)==null?void 0:r[he]),"data-sonner-toast":"","data-rich-colors":(_n=d.richColors)!=null?_n:S,"data-styled":!(d.jsx||d.unstyled||p),"data-mounted":B,"data-promise":!!d.promise,"data-swiped":q,"data-removed":J,"data-visible":Yl,"data-y-position":Zl,"data-x-position":Ql,"data-index":y,"data-front":Ul,"data-swiping":z,"data-dismissible":ct,"data-type":he,"data-invert":Jl,"data-swipe-out":re,"data-swipe-direction":V,"data-expanded":!!(w||D&&B),"data-testid":d.testId,style:{"--index":y,"--toasts-before":y,"--z-index":x.length-y,"--offset":`${J?de:dt.current}px`,"--initial-height":D?"auto":`${Ze}px`,...R,...d.style},onDragEnd:()=>{F(!1),U(null),ut.current=null},onPointerDown:W=>{W.button!==2&&(Ar||!ct||(jt.current=new Date,ue(dt.current),W.target.setPointerCapture(W.pointerId),W.target.tagName!=="BUTTON"&&(F(!0),ut.current={x:W.clientX,y:W.clientY})))},onPointerUp:()=>{var W,ie,ce;if(re||!ct)return;ut.current=null;const me=Number(((W=fe.current)==null?void 0:W.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),$t=Number(((ie=fe.current)==null?void 0:ie.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),ae=new Date().getTime()-((ce=jt.current)==null?void 0:ce.getTime()),ye=j==="x"?me:$t,zt=Math.abs(ye)/ae;if(Math.abs(ye)>=Ad||zt>.11){ue(dt.current),d.onDismiss==null||d.onDismiss.call(d,d),se(j==="x"?me>0?"right":"left":$t>0?"down":"up"),Fe(),Z(!0);return}else{var xe,we;(xe=fe.current)==null||xe.style.setProperty("--swipe-amount-x","0px"),(we=fe.current)==null||we.style.setProperty("--swipe-amount-y","0px")}Y(!1),F(!1),U(null)},onPointerMove:W=>{var ie,ce,me;if(!ut.current||!ct||((ie=window.getSelection())==null?void 0:ie.toString().length)>0)return;const ae=W.clientY-ut.current.y,ye=W.clientX-ut.current.x;var zt;const xe=(zt=e.swipeDirections)!=null?zt:Pd(_);!j&&(Math.abs(ye)>1||Math.abs(ae)>1)&&U(Math.abs(ye)>Math.abs(ae)?"x":"y");let we={x:0,y:0};const Ln=Qe=>1/(1.5+Math.abs(Qe)/20);if(j==="y"){if(xe.includes("top")||xe.includes("bottom"))if(xe.includes("top")&&ae<0||xe.includes("bottom")&&ae>0)we.y=ae;else{const Qe=ae*Ln(ae);we.y=Math.abs(Qe)<Math.abs(ae)?Qe:ae}}else if(j==="x"&&(xe.includes("left")||xe.includes("right")))if(xe.includes("left")&&ye<0||xe.includes("right")&&ye>0)we.x=ye;else{const Qe=ye*Ln(ye);we.x=Math.abs(Qe)<Math.abs(ye)?Qe:ye}(Math.abs(we.x)>0||Math.abs(we.y)>0)&&Y(!0),(ce=fe.current)==null||ce.style.setProperty("--swipe-amount-x",`${we.x}px`),(me=fe.current)==null||me.style.setProperty("--swipe-amount-y",`${we.y}px`)}},ql&&!d.jsx&&he!=="loading"?E.createElement("button",{"aria-label":T,"data-disabled":Ar,"data-close-button":!0,onClick:Ar||!ct?()=>{}:()=>{Fe(),d.onDismiss==null||d.onDismiss.call(d,d)},className:Ne(N==null?void 0:N.closeButton,d==null||(n=d.classNames)==null?void 0:n.closeButton)},(jn=M==null?void 0:M.close)!=null?jn:pd):null,(he||d.icon||d.promise)&&d.icon!==null&&((M==null?void 0:M[he])!==null||d.icon)?E.createElement("div",{"data-icon":"",className:Ne(N==null?void 0:N.icon,d==null||(o=d.classNames)==null?void 0:o.icon)},d.promise||d.type==="loading"&&!d.icon?d.icon||ec():null,d.type!=="loading"?tc:null):null,E.createElement("div",{"data-content":"",className:Ne(N==null?void 0:N.content,d==null||(s=d.classNames)==null?void 0:s.content)},E.createElement("div",{"data-title":"",className:Ne(N==null?void 0:N.title,d==null||(i=d.classNames)==null?void 0:i.title)},d.jsx?d.jsx:typeof d.title=="function"?d.title():d.title),d.description?E.createElement("div",{"data-description":"",className:Ne(k,Xl,N==null?void 0:N.description,d==null||(a=d.classNames)==null?void 0:a.description)},typeof d.description=="function"?d.description():d.description):null),E.isValidElement(d.cancel)?d.cancel:d.cancel&&Ft(d.cancel)?E.createElement("button",{"data-button":!0,"data-cancel":!0,style:d.cancelButtonStyle||O,onClick:W=>{Ft(d.cancel)&&ct&&(d.cancel.onClick==null||d.cancel.onClick.call(d.cancel,W),Fe())},className:Ne(N==null?void 0:N.cancelButton,d==null||(c=d.classNames)==null?void 0:c.cancelButton)},d.cancel.label):null,E.isValidElement(d.action)?d.action:d.action&&Ft(d.action)?E.createElement("button",{"data-button":!0,"data-action":!0,style:d.actionButtonStyle||$,onClick:W=>{Ft(d.action)&&(d.action.onClick==null||d.action.onClick.call(d.action,W),!W.defaultPrevented&&Fe())},className:Ne(N==null?void 0:N.actionButton,d==null||(l=d.classNames)==null?void 0:l.actionButton)},d.action.label):null)};function Po(){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 kd(e,t){const r={};return[e,t].forEach((n,o)=>{const s=o===1,i=s?"--mobile-offset":"--offset",a=s?Sd:Cd;function c(l){["top","right","bottom","left"].forEach(u=>{r[`${i}-${u}`]=typeof l=="number"?`${l}px`:l})}typeof n=="number"||typeof n=="string"?c(n):typeof n=="object"?["top","right","bottom","left"].forEach(l=>{n[l]===void 0?r[`${i}-${l}`]=a:r[`${i}-${l}`]=typeof n[l]=="number"?`${n[l]}px`:n[l]}):c(a)}),r}const Dd=E.forwardRef(function(t,r){const{id:n,invert:o,position:s="bottom-right",hotkey:i=["altKey","KeyT"],expand:a,closeButton:c,className:l,offset:u,mobileOffset:d,theme:p="light",richColors:g,duration:v,style:h,visibleToasts:b=wd,toastOptions:y,dir:x=Po(),gap:w=Rd,icons:C,containerAriaLabel:S="Notifications"}=t,[A,R]=E.useState([]),O=E.useMemo(()=>n?A.filter(B=>B.toasterId===n):A.filter(B=>!B.toasterId),[A,n]),$=E.useMemo(()=>Array.from(new Set([s].concat(O.filter(B=>B.position).map(B=>B.position)))),[O,s]),[L,k]=E.useState([]),[P,_]=E.useState(!1),[I,D]=E.useState(!1),[N,M]=E.useState(p!=="system"?p:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),T=E.useRef(null),j=i.join("+").replace(/Key/g,"").replace(/Digit/g,""),U=E.useRef(null),V=E.useRef(!1),se=E.useCallback(B=>{R(X=>{var J;return(J=X.find(ne=>ne.id===B.id))!=null&&J.delete||pe.dismiss(B.id),X.filter(({id:ne})=>ne!==B.id)})},[]);return E.useEffect(()=>pe.subscribe(B=>{if(B.dismiss){requestAnimationFrame(()=>{R(X=>X.map(J=>J.id===B.id?{...J,delete:!0}:J))});return}setTimeout(()=>{ir.flushSync(()=>{R(X=>{const J=X.findIndex(ne=>ne.id===B.id);return J!==-1?[...X.slice(0,J),{...X[J],...B},...X.slice(J+1)]:[B,...X]})})})}),[A]),E.useEffect(()=>{if(p!=="system"){M(p);return}if(p==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?M("dark"):M("light")),typeof window>"u")return;const B=window.matchMedia("(prefers-color-scheme: dark)");try{B.addEventListener("change",({matches:X})=>{M(X?"dark":"light")})}catch{B.addListener(({matches:J})=>{try{M(J?"dark":"light")}catch(ne){console.error(ne)}})}},[p]),E.useEffect(()=>{A.length<=1&&_(!1)},[A]),E.useEffect(()=>{const B=X=>{var J;if(i.every(F=>X[F]||X.code===F)){var z;_(!0),(z=T.current)==null||z.focus()}X.code==="Escape"&&(document.activeElement===T.current||(J=T.current)!=null&&J.contains(document.activeElement))&&_(!1)};return document.addEventListener("keydown",B),()=>document.removeEventListener("keydown",B)},[i]),E.useEffect(()=>{if(T.current)return()=>{U.current&&(U.current.focus({preventScroll:!0}),U.current=null,V.current=!1)}},[T.current]),E.createElement("section",{ref:r,"aria-label":`${S} ${j}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},$.map((B,X)=>{var J;const[ne,z]=B.split("-");return O.length?E.createElement("ol",{key:B,dir:x==="auto"?Po():x,tabIndex:-1,ref:T,className:l,"data-sonner-toaster":!0,"data-sonner-theme":N,"data-y-position":ne,"data-x-position":z,style:{"--front-toast-height":`${((J=L[0])==null?void 0:J.height)||0}px`,"--width":`${Ed}px`,"--gap":`${w}px`,...h,...kd(u,d)},onBlur:F=>{V.current&&!F.currentTarget.contains(F.relatedTarget)&&(V.current=!1,U.current&&(U.current.focus({preventScroll:!0}),U.current=null))},onFocus:F=>{F.target instanceof HTMLElement&&F.target.dataset.dismissible==="false"||V.current||(V.current=!0,U.current=F.relatedTarget)},onMouseEnter:()=>_(!0),onMouseMove:()=>_(!0),onMouseLeave:()=>{I||_(!1)},onDragEnd:()=>_(!1),onPointerDown:F=>{F.target instanceof HTMLElement&&F.target.dataset.dismissible==="false"||D(!0)},onPointerUp:()=>D(!1)},O.filter(F=>!F.position&&X===0||F.position===B).map((F,re)=>{var Z,q;return E.createElement(Td,{key:F.id,icons:C,index:re,toast:F,defaultRichColors:g,duration:(Z=y==null?void 0:y.duration)!=null?Z:v,className:y==null?void 0:y.className,descriptionClassName:y==null?void 0:y.descriptionClassName,invert:o,visibleToasts:b,closeButton:(q=y==null?void 0:y.closeButton)!=null?q:c,interacting:I,position:B,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:se,toasts:O.filter(Y=>Y.position==F.position),heights:L.filter(Y=>Y.position==F.position),setHeights:k,expandByDefault:a,gap:w,expanded:P,swipeDirections:t.swipeDirections})})):null}))}),Md=({closeButton:e=!0,...t})=>m.jsx(Dd,{className:"toaster group",closeButton:e,toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-white group-[.toaster]:text-[#2C2825] group-[.toaster]:border-white/20 group-[.toaster]:shadow-xl group-[.toaster]:backdrop-blur-md group-[.toaster]:rounded-2xl font-sans-body",description:"group-[.toast]:text-[#7A7570] font-sans-body",actionButton:"group-[.toast]:bg-[#FF6B4A] group-[.toast]:text-white group-[.toast]:rounded-xl font-medium",cancelButton:"group-[.toast]:bg-[#F4F4F1] group-[.toast]:text-[#7A7570] group-[.toast]:rounded-xl",closeButton:"group-[.toast]:text-[#7A7570] group-[.toast]:hover:text-[#2C2825] group-[.toast]:hover:bg-[#F4F4F1] group-[.toast]:rounded-lg"}},...t}),Os=f.forwardRef(({className:e,...t},r)=>m.jsx("form",{ref:r,className:G("space-y-4",e),...t}));Os.displayName="Form";const _s=f.forwardRef(({className:e,error:t,children:r,...n},o)=>m.jsxs("div",{ref:o,className:G("space-y-2",e),...n,children:[r,t&&m.jsx("p",{className:"text-sm text-red-600",role:"alert",children:t})]}));_s.displayName="FormField";const js=f.forwardRef(({className:e,variant:t="default",size:r="md",...n},o)=>m.jsx("div",{className:G("inline-flex items-center rounded-full border font-medium text-center whitespace-nowrap",{"px-2 py-0.5 text-xs":r==="sm","px-2.5 py-0.5 text-sm":r==="md","px-3 py-1 text-sm":r==="lg","bg-blue-600 border-blue-600 text-white":t==="default","bg-gray-100 border-gray-300 text-gray-800":t==="secondary","bg-transparent border-gray-300 text-gray-700":t==="outline","bg-green-100 border-green-300 text-green-800":t==="success","bg-yellow-100 border-yellow-300 text-yellow-800":t==="warning","bg-red-100 border-red-300 text-red-800":t==="error"},e),ref:o,...n}));js.displayName="Badge";const Ls=f.forwardRef(({className:e,orientation:t="horizontal",decorative:r=!0,...n},o)=>m.jsx("div",{ref:o,role:r?"none":"separator","aria-orientation":t,className:it("shrink-0 bg-border",t==="horizontal"?"h-[1px] w-full":"h-full w-[1px]",e),...n}));Ls.displayName="Separator";function Id(e,t){const r=f.createContext(t),n=s=>{const{children:i,...a}=s,c=f.useMemo(()=>a,Object.values(a));return m.jsx(r.Provider,{value:c,children:i})};n.displayName=e+"Provider";function o(s){const i=f.useContext(r);if(i)return i;if(t!==void 0)return t;throw new Error(`\`${s}\` must be used within \`${e}\``)}return[n,o]}function Ke(e,t=[]){let r=[];function n(s,i){const a=f.createContext(i),c=r.length;r=[...r,i];const l=d=>{var y;const{scope:p,children:g,...v}=d,h=((y=p==null?void 0:p[e])==null?void 0:y[c])||a,b=f.useMemo(()=>v,Object.values(v));return m.jsx(h.Provider,{value:b,children:g})};l.displayName=s+"Provider";function u(d,p){var h;const g=((h=p==null?void 0:p[e])==null?void 0:h[c])||a,v=f.useContext(g);if(v)return v;if(i!==void 0)return i;throw new Error(`\`${d}\` must be used within \`${s}\``)}return[l,u]}const o=()=>{const s=r.map(i=>f.createContext(i));return function(a){const c=(a==null?void 0:a[e])||s;return f.useMemo(()=>({[`__scope${e}`]:{...a,[e]:c}}),[a,c])}};return o.scopeName=e,[n,Od(o,...t)]}function Od(...e){const t=e[0];if(e.length===1)return t;const r=()=>{const n=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(s){const i=n.reduce((a,{useScope:c,scopeName:l})=>{const d=c(s)[`__scope${l}`];return{...a,...d}},{});return f.useMemo(()=>({[`__scope${t.scopeName}`]:i}),[i])}};return r.scopeName=t.scopeName,r}function $s(e){const t=e+"CollectionProvider",[r,n]=Ke(t),[o,s]=r(t,{collectionRef:{current:null},itemMap:new Map}),i=h=>{const{scope:b,children:y}=h,x=E.useRef(null),w=E.useRef(new Map).current;return m.jsx(o,{scope:b,itemMap:w,collectionRef:x,children:y})};i.displayName=t;const a=e+"CollectionSlot",c=bt(a),l=E.forwardRef((h,b)=>{const{scope:y,children:x}=h,w=s(a,y),C=ee(b,w.collectionRef);return m.jsx(c,{ref:C,children:x})});l.displayName=a;const u=e+"CollectionItemSlot",d="data-radix-collection-item",p=bt(u),g=E.forwardRef((h,b)=>{const{scope:y,children:x,...w}=h,C=E.useRef(null),S=ee(b,C),A=s(u,y);return E.useEffect(()=>(A.itemMap.set(C,{ref:C,...w}),()=>void A.itemMap.delete(C))),m.jsx(p,{[d]:"",ref:S,children:x})});g.displayName=u;function v(h){const b=s(e+"CollectionConsumer",h);return E.useCallback(()=>{const x=b.collectionRef.current;if(!x)return[];const w=Array.from(x.querySelectorAll(`[${d}]`));return Array.from(b.itemMap.values()).sort((A,R)=>w.indexOf(A.ref.current)-w.indexOf(R.ref.current))},[b.collectionRef,b.itemMap])}return[{Provider:i,Slot:l,ItemSlot:g},v,n]}function Q(e,t,{checkForDefaultPrevented:r=!0}={}){return function(o){if(e==null||e(o),r===!1||!o.defaultPrevented)return t==null?void 0:t(o)}}var le=globalThis!=null&&globalThis.document?f.useLayoutEffect:()=>{},_d=f[" useInsertionEffect ".trim().toString()]||le;function et({prop:e,defaultProp:t,onChange:r=()=>{},caller:n}){const[o,s,i]=jd({defaultProp:t,onChange:r}),a=e!==void 0,c=a?e:o;{const u=f.useRef(e!==void 0);f.useEffect(()=>{const d=u.current;d!==a&&console.warn(`${n} is changing from ${d?"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.`),u.current=a},[a,n])}const l=f.useCallback(u=>{var d;if(a){const p=Ld(u)?u(e):u;p!==e&&((d=i.current)==null||d.call(i,p))}else s(u)},[a,e,s,i]);return[c,l]}function jd({defaultProp:e,onChange:t}){const[r,n]=f.useState(e),o=f.useRef(r),s=f.useRef(t);return _d(()=>{s.current=t},[t]),f.useEffect(()=>{var i;o.current!==r&&((i=s.current)==null||i.call(s,r),o.current=r)},[r,o]),[r,n,s]}function Ld(e){return typeof e=="function"}function $d(e,t){return f.useReducer((r,n)=>t[r][n]??r,e)}var St=e=>{const{present:t,children:r}=e,n=zd(t),o=typeof r=="function"?r({present:n.isPresent}):f.Children.only(r),s=ee(n.ref,Fd(o));return typeof r=="function"||n.isPresent?f.cloneElement(o,{ref:s}):null};St.displayName="Presence";function zd(e){const[t,r]=f.useState(),n=f.useRef(null),o=f.useRef(e),s=f.useRef("none"),i=e?"mounted":"unmounted",[a,c]=$d(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return f.useEffect(()=>{const l=Bt(n.current);s.current=a==="mounted"?l:"none"},[a]),le(()=>{const l=n.current,u=o.current;if(u!==e){const p=s.current,g=Bt(l);e?c("MOUNT"):g==="none"||(l==null?void 0:l.display)==="none"?c("UNMOUNT"):c(u&&p!==g?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,c]),le(()=>{if(t){let l;const u=t.ownerDocument.defaultView??window,d=g=>{const h=Bt(n.current).includes(CSS.escape(g.animationName));if(g.target===t&&h&&(c("ANIMATION_END"),!o.current)){const b=t.style.animationFillMode;t.style.animationFillMode="forwards",l=u.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=b)})}},p=g=>{g.target===t&&(s.current=Bt(n.current))};return t.addEventListener("animationstart",p),t.addEventListener("animationcancel",d),t.addEventListener("animationend",d),()=>{u.clearTimeout(l),t.removeEventListener("animationstart",p),t.removeEventListener("animationcancel",d),t.removeEventListener("animationend",d)}}else c("ANIMATION_END")},[t,c]),{isPresent:["mounted","unmountSuspended"].includes(a),ref:f.useCallback(l=>{n.current=l?getComputedStyle(l):null,r(l)},[])}}function Bt(e){return(e==null?void 0:e.animationName)||"none"}function Fd(e){var n,o;let t=(n=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:n.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}var Bd=f[" useId ".trim().toString()]||(()=>{}),Vd=0;function He(e){const[t,r]=f.useState(Bd());return le(()=>{r(n=>n??String(Vd++))},[e]),e||(t?`radix-${t}`:"")}var dr="Collapsible",[Wd,zs]=Ke(dr),[Hd,en]=Wd(dr),Fs=f.forwardRef((e,t)=>{const{__scopeCollapsible:r,open:n,defaultOpen:o,disabled:s,onOpenChange:i,...a}=e,[c,l]=et({prop:n,defaultProp:o??!1,onChange:i,caller:dr});return m.jsx(Hd,{scope:r,disabled:s,contentId:He(),open:c,onOpenToggle:f.useCallback(()=>l(u=>!u),[l]),children:m.jsx(K.div,{"data-state":rn(c),"data-disabled":s?"":void 0,...a,ref:t})})});Fs.displayName=dr;var Bs="CollapsibleTrigger",Vs=f.forwardRef((e,t)=>{const{__scopeCollapsible:r,...n}=e,o=en(Bs,r);return m.jsx(K.button,{type:"button","aria-controls":o.contentId,"aria-expanded":o.open||!1,"data-state":rn(o.open),"data-disabled":o.disabled?"":void 0,disabled:o.disabled,...n,ref:t,onClick:Q(e.onClick,o.onOpenToggle)})});Vs.displayName=Bs;var tn="CollapsibleContent",Ws=f.forwardRef((e,t)=>{const{forceMount:r,...n}=e,o=en(tn,e.__scopeCollapsible);return m.jsx(St,{present:r||o.open,children:({present:s})=>m.jsx(Gd,{...n,ref:t,present:s})})});Ws.displayName=tn;var Gd=f.forwardRef((e,t)=>{const{__scopeCollapsible:r,present:n,children:o,...s}=e,i=en(tn,r),[a,c]=f.useState(n),l=f.useRef(null),u=ee(t,l),d=f.useRef(0),p=d.current,g=f.useRef(0),v=g.current,h=i.open||a,b=f.useRef(h),y=f.useRef(void 0);return f.useEffect(()=>{const x=requestAnimationFrame(()=>b.current=!1);return()=>cancelAnimationFrame(x)},[]),le(()=>{const x=l.current;if(x){y.current=y.current||{transitionDuration:x.style.transitionDuration,animationName:x.style.animationName},x.style.transitionDuration="0s",x.style.animationName="none";const w=x.getBoundingClientRect();d.current=w.height,g.current=w.width,b.current||(x.style.transitionDuration=y.current.transitionDuration,x.style.animationName=y.current.animationName),c(n)}},[i.open,n]),m.jsx(K.div,{"data-state":rn(i.open),"data-disabled":i.disabled?"":void 0,id:i.contentId,hidden:!h,...s,ref:u,style:{"--radix-collapsible-content-height":p?`${p}px`:void 0,"--radix-collapsible-content-width":v?`${v}px`:void 0,...e.style},children:h&&o})});function rn(e){return e?"open":"closed"}var Ud=Fs,Yd=Vs,Kd=Ws,Xd=f.createContext(void 0);function Hs(e){const t=f.useContext(Xd);return e||t||"ltr"}var Re="Accordion",qd=["Home","End","ArrowDown","ArrowUp","ArrowLeft","ArrowRight"],[nn,Zd,Qd]=$s(Re),[ur]=Ke(Re,[Qd,zs]),on=zs(),Gs=E.forwardRef((e,t)=>{const{type:r,...n}=e,o=n,s=n;return m.jsx(nn.Provider,{scope:e.__scopeAccordion,children:r==="multiple"?m.jsx(ru,{...s,ref:t}):m.jsx(tu,{...o,ref:t})})});Gs.displayName=Re;var[Us,Jd]=ur(Re),[Ys,eu]=ur(Re,{collapsible:!1}),tu=E.forwardRef((e,t)=>{const{value:r,defaultValue:n,onValueChange:o=()=>{},collapsible:s=!1,...i}=e,[a,c]=et({prop:r,defaultProp:n??"",onChange:o,caller:Re});return m.jsx(Us,{scope:e.__scopeAccordion,value:E.useMemo(()=>a?[a]:[],[a]),onItemOpen:c,onItemClose:E.useCallback(()=>s&&c(""),[s,c]),children:m.jsx(Ys,{scope:e.__scopeAccordion,collapsible:s,children:m.jsx(Ks,{...i,ref:t})})})}),ru=E.forwardRef((e,t)=>{const{value:r,defaultValue:n,onValueChange:o=()=>{},...s}=e,[i,a]=et({prop:r,defaultProp:n??[],onChange:o,caller:Re}),c=E.useCallback(u=>a((d=[])=>[...d,u]),[a]),l=E.useCallback(u=>a((d=[])=>d.filter(p=>p!==u)),[a]);return m.jsx(Us,{scope:e.__scopeAccordion,value:i,onItemOpen:c,onItemClose:l,children:m.jsx(Ys,{scope:e.__scopeAccordion,collapsible:!0,children:m.jsx(Ks,{...s,ref:t})})})}),[nu,fr]=ur(Re),Ks=E.forwardRef((e,t)=>{const{__scopeAccordion:r,disabled:n,dir:o,orientation:s="vertical",...i}=e,a=E.useRef(null),c=ee(a,t),l=Zd(r),d=Hs(o)==="ltr",p=Q(e.onKeyDown,g=>{var O;if(!qd.includes(g.key))return;const v=g.target,h=l().filter($=>{var L;return!((L=$.ref.current)!=null&&L.disabled)}),b=h.findIndex($=>$.ref.current===v),y=h.length;if(b===-1)return;g.preventDefault();let x=b;const w=0,C=y-1,S=()=>{x=b+1,x>C&&(x=w)},A=()=>{x=b-1,x<w&&(x=C)};switch(g.key){case"Home":x=w;break;case"End":x=C;break;case"ArrowRight":s==="horizontal"&&(d?S():A());break;case"ArrowDown":s==="vertical"&&S();break;case"ArrowLeft":s==="horizontal"&&(d?A():S());break;case"ArrowUp":s==="vertical"&&A();break}const R=x%y;(O=h[R].ref.current)==null||O.focus()});return m.jsx(nu,{scope:r,disabled:n,direction:o,orientation:s,children:m.jsx(nn.Slot,{scope:r,children:m.jsx(K.div,{...i,"data-orientation":s,ref:c,onKeyDown:n?void 0:p})})})}),Jt="AccordionItem",[ou,sn]=ur(Jt),Xs=E.forwardRef((e,t)=>{const{__scopeAccordion:r,value:n,...o}=e,s=fr(Jt,r),i=Jd(Jt,r),a=on(r),c=He(),l=n&&i.value.includes(n)||!1,u=s.disabled||e.disabled;return m.jsx(ou,{scope:r,open:l,disabled:u,triggerId:c,children:m.jsx(Ud,{"data-orientation":s.orientation,"data-state":ti(l),...a,...o,ref:t,disabled:u,open:l,onOpenChange:d=>{d?i.onItemOpen(n):i.onItemClose(n)}})})});Xs.displayName=Jt;var qs="AccordionHeader",Zs=E.forwardRef((e,t)=>{const{__scopeAccordion:r,...n}=e,o=fr(Re,r),s=sn(qs,r);return m.jsx(K.h3,{"data-orientation":o.orientation,"data-state":ti(s.open),"data-disabled":s.disabled?"":void 0,...n,ref:t})});Zs.displayName=qs;var zr="AccordionTrigger",Qs=E.forwardRef((e,t)=>{const{__scopeAccordion:r,...n}=e,o=fr(Re,r),s=sn(zr,r),i=eu(zr,r),a=on(r);return m.jsx(nn.ItemSlot,{scope:r,children:m.jsx(Yd,{"aria-disabled":s.open&&!i.collapsible||void 0,"data-orientation":o.orientation,id:s.triggerId,...a,...n,ref:t})})});Qs.displayName=zr;var Js="AccordionContent",ei=E.forwardRef((e,t)=>{const{__scopeAccordion:r,...n}=e,o=fr(Re,r),s=sn(Js,r),i=on(r);return m.jsx(Kd,{role:"region","aria-labelledby":s.triggerId,"data-orientation":o.orientation,...i,...n,ref:t,style:{"--radix-accordion-content-height":"var(--radix-collapsible-content-height)","--radix-accordion-content-width":"var(--radix-collapsible-content-width)",...e.style}})});ei.displayName=Js;function ti(e){return e?"open":"closed"}var su=Gs,iu=Xs,au=Zs,ri=Qs,ni=ei;const lu=su,oi=f.forwardRef(({className:e,...t},r)=>m.jsx(iu,{ref:r,className:G("border rounded-lg",e),...t}));oi.displayName="AccordionItem";const si=f.forwardRef(({className:e,children:t,...r},n)=>m.jsx(au,{className:"flex",children:m.jsxs(ri,{ref:n,className:G("flex flex-1 items-center justify-between py-4 px-4 text-left text-sm font-medium transition-all hover:underline",e),...r,children:[t,m.jsx("span",{className:"ml-2",children:"▾"})]})}));si.displayName=ri.displayName;const ii=f.forwardRef(({className:e,children:t,...r},n)=>m.jsx(ni,{ref:n,className:G("px-4 pb-4 text-sm text-muted-foreground",e),...r,children:t}));ii.displayName=ni.displayName;function tt(e){const t=f.useRef(e);return f.useEffect(()=>{t.current=e}),f.useMemo(()=>(...r)=>{var n;return(n=t.current)==null?void 0:n.call(t,...r)},[])}function cu(e,t=globalThis==null?void 0:globalThis.document){const r=tt(e);f.useEffect(()=>{const n=o=>{o.key==="Escape"&&r(o)};return t.addEventListener("keydown",n,{capture:!0}),()=>t.removeEventListener("keydown",n,{capture:!0})},[r,t])}var du="DismissableLayer",Fr="dismissableLayer.update",uu="dismissableLayer.pointerDownOutside",fu="dismissableLayer.focusOutside",To,ai=f.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),an=f.forwardRef((e,t)=>{const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:n,onPointerDownOutside:o,onFocusOutside:s,onInteractOutside:i,onDismiss:a,...c}=e,l=f.useContext(ai),[u,d]=f.useState(null),p=(u==null?void 0:u.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,g]=f.useState({}),v=ee(t,R=>d(R)),h=Array.from(l.layers),[b]=[...l.layersWithOutsidePointerEventsDisabled].slice(-1),y=h.indexOf(b),x=u?h.indexOf(u):-1,w=l.layersWithOutsidePointerEventsDisabled.size>0,C=x>=y,S=mu(R=>{const O=R.target,$=[...l.branches].some(L=>L.contains(O));!C||$||(o==null||o(R),i==null||i(R),R.defaultPrevented||a==null||a())},p),A=gu(R=>{const O=R.target;[...l.branches].some(L=>L.contains(O))||(s==null||s(R),i==null||i(R),R.defaultPrevented||a==null||a())},p);return cu(R=>{x===l.layers.size-1&&(n==null||n(R),!R.defaultPrevented&&a&&(R.preventDefault(),a()))},p),f.useEffect(()=>{if(u)return r&&(l.layersWithOutsidePointerEventsDisabled.size===0&&(To=p.body.style.pointerEvents,p.body.style.pointerEvents="none"),l.layersWithOutsidePointerEventsDisabled.add(u)),l.layers.add(u),ko(),()=>{r&&l.layersWithOutsidePointerEventsDisabled.size===1&&(p.body.style.pointerEvents=To)}},[u,p,r,l]),f.useEffect(()=>()=>{u&&(l.layers.delete(u),l.layersWithOutsidePointerEventsDisabled.delete(u),ko())},[u,l]),f.useEffect(()=>{const R=()=>g({});return document.addEventListener(Fr,R),()=>document.removeEventListener(Fr,R)},[]),m.jsx(K.div,{...c,ref:v,style:{pointerEvents:w?C?"auto":"none":void 0,...e.style},onFocusCapture:Q(e.onFocusCapture,A.onFocusCapture),onBlurCapture:Q(e.onBlurCapture,A.onBlurCapture),onPointerDownCapture:Q(e.onPointerDownCapture,S.onPointerDownCapture)})});an.displayName=du;var pu="DismissableLayerBranch",hu=f.forwardRef((e,t)=>{const r=f.useContext(ai),n=f.useRef(null),o=ee(t,n);return f.useEffect(()=>{const s=n.current;if(s)return r.branches.add(s),()=>{r.branches.delete(s)}},[r.branches]),m.jsx(K.div,{...e,ref:o})});hu.displayName=pu;function mu(e,t=globalThis==null?void 0:globalThis.document){const r=tt(e),n=f.useRef(!1),o=f.useRef(()=>{});return f.useEffect(()=>{const s=a=>{if(a.target&&!n.current){let c=function(){li(uu,r,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);n.current=!1},i=window.setTimeout(()=>{t.addEventListener("pointerdown",s)},0);return()=>{window.clearTimeout(i),t.removeEventListener("pointerdown",s),t.removeEventListener("click",o.current)}},[t,r]),{onPointerDownCapture:()=>n.current=!0}}function gu(e,t=globalThis==null?void 0:globalThis.document){const r=tt(e),n=f.useRef(!1);return f.useEffect(()=>{const o=s=>{s.target&&!n.current&&li(fu,r,{originalEvent:s},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,r]),{onFocusCapture:()=>n.current=!0,onBlurCapture:()=>n.current=!1}}function ko(){const e=new CustomEvent(Fr);document.dispatchEvent(e)}function li(e,t,r,{discrete:n}){const o=r.originalEvent.target,s=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:r});t&&o.addEventListener(e,t,{once:!0}),n?Jc(o,s):o.dispatchEvent(s)}var Pr="focusScope.autoFocusOnMount",Tr="focusScope.autoFocusOnUnmount",Do={bubbles:!1,cancelable:!0},vu="FocusScope",ln=f.forwardRef((e,t)=>{const{loop:r=!1,trapped:n=!1,onMountAutoFocus:o,onUnmountAutoFocus:s,...i}=e,[a,c]=f.useState(null),l=tt(o),u=tt(s),d=f.useRef(null),p=ee(t,h=>c(h)),g=f.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;f.useEffect(()=>{if(n){let h=function(w){if(g.paused||!a)return;const C=w.target;a.contains(C)?d.current=C:We(d.current,{select:!0})},b=function(w){if(g.paused||!a)return;const C=w.relatedTarget;C!==null&&(a.contains(C)||We(d.current,{select:!0}))},y=function(w){if(document.activeElement===document.body)for(const S of w)S.removedNodes.length>0&&We(a)};document.addEventListener("focusin",h),document.addEventListener("focusout",b);const x=new MutationObserver(y);return a&&x.observe(a,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",h),document.removeEventListener("focusout",b),x.disconnect()}}},[n,a,g.paused]),f.useEffect(()=>{if(a){Io.add(g);const h=document.activeElement;if(!a.contains(h)){const y=new CustomEvent(Pr,Do);a.addEventListener(Pr,l),a.dispatchEvent(y),y.defaultPrevented||(yu(Su(ci(a)),{select:!0}),document.activeElement===h&&We(a))}return()=>{a.removeEventListener(Pr,l),setTimeout(()=>{const y=new CustomEvent(Tr,Do);a.addEventListener(Tr,u),a.dispatchEvent(y),y.defaultPrevented||We(h??document.body,{select:!0}),a.removeEventListener(Tr,u),Io.remove(g)},0)}}},[a,l,u,g]);const v=f.useCallback(h=>{if(!r&&!n||g.paused)return;const b=h.key==="Tab"&&!h.altKey&&!h.ctrlKey&&!h.metaKey,y=document.activeElement;if(b&&y){const x=h.currentTarget,[w,C]=bu(x);w&&C?!h.shiftKey&&y===C?(h.preventDefault(),r&&We(w,{select:!0})):h.shiftKey&&y===w&&(h.preventDefault(),r&&We(C,{select:!0})):y===x&&h.preventDefault()}},[r,n,g.paused]);return m.jsx(K.div,{tabIndex:-1,...i,ref:p,onKeyDown:v})});ln.displayName=vu;function yu(e,{select:t=!1}={}){const r=document.activeElement;for(const n of e)if(We(n,{select:t}),document.activeElement!==r)return}function bu(e){const t=ci(e),r=Mo(t,e),n=Mo(t.reverse(),e);return[r,n]}function ci(e){const t=[],r=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:n=>{const o=n.tagName==="INPUT"&&n.type==="hidden";return n.disabled||n.hidden||o?NodeFilter.FILTER_SKIP:n.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;r.nextNode();)t.push(r.currentNode);return t}function Mo(e,t){for(const r of e)if(!xu(r,{upTo:t}))return r}function xu(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 wu(e){return e instanceof HTMLInputElement&&"select"in e}function We(e,{select:t=!1}={}){if(e&&e.focus){const r=document.activeElement;e.focus({preventScroll:!0}),e!==r&&wu(e)&&t&&e.select()}}var Io=Cu();function Cu(){let e=[];return{add(t){const r=e[0];t!==r&&(r==null||r.pause()),e=Oo(e,t),e.unshift(t)},remove(t){var r;e=Oo(e,t),(r=e[0])==null||r.resume()}}}function Oo(e,t){const r=[...e],n=r.indexOf(t);return n!==-1&&r.splice(n,1),r}function Su(e){return e.filter(t=>t.tagName!=="A")}var Eu="Portal",cn=f.forwardRef((e,t)=>{var a;const{container:r,...n}=e,[o,s]=f.useState(!1);le(()=>s(!0),[]);const i=r||o&&((a=globalThis==null?void 0:globalThis.document)==null?void 0:a.body);return i?ir.createPortal(m.jsx(K.div,{...n,ref:t}),i):null});cn.displayName=Eu;var kr=0;function di(){f.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??_o()),document.body.insertAdjacentElement("beforeend",e[1]??_o()),kr++,()=>{kr===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),kr--}},[])}function _o(){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 Pe=function(){return Pe=Object.assign||function(t){for(var r,n=1,o=arguments.length;n<o;n++){r=arguments[n];for(var s in r)Object.prototype.hasOwnProperty.call(r,s)&&(t[s]=r[s])}return t},Pe.apply(this,arguments)};function ui(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r}function Ru(e,t,r){if(r||arguments.length===2)for(var n=0,o=t.length,s;n<o;n++)(s||!(n in t))&&(s||(s=Array.prototype.slice.call(t,0,n)),s[n]=t[n]);return e.concat(s||Array.prototype.slice.call(t))}var Xt="right-scroll-bar-position",qt="width-before-scroll-bar",Au="with-scroll-bars-hidden",Nu="--removed-body-scroll-bar-size";function Dr(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function Pu(e,t){var r=E.useState(function(){return{value:e,callback:t,facade:{get current(){return r.value},set current(n){var o=r.value;o!==n&&(r.value=n,r.callback(n,o))}}}})[0];return r.callback=t,r.facade}var Tu=typeof window<"u"?f.useLayoutEffect:f.useEffect,jo=new WeakMap;function ku(e,t){var r=Pu(null,function(n){return e.forEach(function(o){return Dr(o,n)})});return Tu(function(){var n=jo.get(r);if(n){var o=new Set(n),s=new Set(e),i=r.current;o.forEach(function(a){s.has(a)||Dr(a,null)}),s.forEach(function(a){o.has(a)||Dr(a,i)})}jo.set(r,e)},[e]),r}function Du(e){return e}function Mu(e,t){t===void 0&&(t=Du);var r=[],n=!1,o={read:function(){if(n)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return r.length?r[r.length-1]:e},useMedium:function(s){var i=t(s,n);return r.push(i),function(){r=r.filter(function(a){return a!==i})}},assignSyncMedium:function(s){for(n=!0;r.length;){var i=r;r=[],i.forEach(s)}r={push:function(a){return s(a)},filter:function(){return r}}},assignMedium:function(s){n=!0;var i=[];if(r.length){var a=r;r=[],a.forEach(s),i=r}var c=function(){var u=i;i=[],u.forEach(s)},l=function(){return Promise.resolve().then(c)};l(),r={push:function(u){i.push(u),l()},filter:function(u){return i=i.filter(u),r}}}};return o}function Iu(e){e===void 0&&(e={});var t=Mu(null);return t.options=Pe({async:!0,ssr:!1},e),t}var fi=function(e){var t=e.sideCar,r=ui(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var n=t.read();if(!n)throw new Error("Sidecar medium not found");return f.createElement(n,Pe({},r))};fi.isSideCarExport=!0;function Ou(e,t){return e.useMedium(t),fi}var pi=Iu(),Mr=function(){},pr=f.forwardRef(function(e,t){var r=f.useRef(null),n=f.useState({onScrollCapture:Mr,onWheelCapture:Mr,onTouchMoveCapture:Mr}),o=n[0],s=n[1],i=e.forwardProps,a=e.children,c=e.className,l=e.removeScrollBar,u=e.enabled,d=e.shards,p=e.sideCar,g=e.noRelative,v=e.noIsolation,h=e.inert,b=e.allowPinchZoom,y=e.as,x=y===void 0?"div":y,w=e.gapMode,C=ui(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),S=p,A=ku([r,t]),R=Pe(Pe({},C),o);return f.createElement(f.Fragment,null,u&&f.createElement(S,{sideCar:pi,removeScrollBar:l,shards:d,noRelative:g,noIsolation:v,inert:h,setCallbacks:s,allowPinchZoom:!!b,lockRef:r,gapMode:w}),i?f.cloneElement(f.Children.only(a),Pe(Pe({},R),{ref:A})):f.createElement(x,Pe({},R,{className:c,ref:A}),a))});pr.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};pr.classNames={fullWidth:qt,zeroRight:Xt};var _u=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function ju(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=_u();return t&&e.setAttribute("nonce",t),e}function Lu(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function $u(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var zu=function(){var e=0,t=null;return{add:function(r){e==0&&(t=ju())&&(Lu(t,r),$u(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},Fu=function(){var e=zu();return function(t,r){f.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&r])}},hi=function(){var e=Fu(),t=function(r){var n=r.styles,o=r.dynamic;return e(n,o),null};return t},Bu={left:0,top:0,right:0,gap:0},Ir=function(e){return parseInt(e||"",10)||0},Vu=function(e){var t=window.getComputedStyle(document.body),r=t[e==="padding"?"paddingLeft":"marginLeft"],n=t[e==="padding"?"paddingTop":"marginTop"],o=t[e==="padding"?"paddingRight":"marginRight"];return[Ir(r),Ir(n),Ir(o)]},Wu=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return Bu;var t=Vu(e),r=document.documentElement.clientWidth,n=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,n-r+t[2]-t[0])}},Hu=hi(),gt="data-scroll-locked",Gu=function(e,t,r,n){var o=e.left,s=e.top,i=e.right,a=e.gap;return r===void 0&&(r="margin"),`
20
20
  .`.concat(Au,` {
21
21
  overflow: hidden `).concat(n,`;
22
22
  padding-right: `).concat(a,"px ").concat(n,`;
@@ -53,10 +53,10 @@
53
53
  body[`).concat(gt,`] {
54
54
  `).concat(Nu,": ").concat(a,`px;
55
55
  }
56
- `)},Lo=function(){var e=parseInt(document.body.getAttribute(gt)||"0",10);return isFinite(e)?e:0},Uu=function(){f.useEffect(function(){return document.body.setAttribute(gt,(Lo()+1).toString()),function(){var e=Lo()-1;e<=0?document.body.removeAttribute(gt):document.body.setAttribute(gt,e.toString())}},[])},Yu=function(e){var t=e.noRelative,r=e.noImportant,n=e.gapMode,o=n===void 0?"margin":n;Uu();var s=f.useMemo(function(){return Wu(o)},[o]);return f.createElement(Hu,{styles:Gu(s,!t,o,r?"":"!important")})},Fr=!1;if(typeof window<"u")try{var Vt=Object.defineProperty({},"passive",{get:function(){return Fr=!0,!0}});window.addEventListener("test",Vt,Vt),window.removeEventListener("test",Vt,Vt)}catch{Fr=!1}var ft=Fr?{passive:!1}:!1,Ku=function(e){return e.tagName==="TEXTAREA"},mi=function(e,t){if(!(e instanceof Element))return!1;var r=window.getComputedStyle(e);return r[t]!=="hidden"&&!(r.overflowY===r.overflowX&&!Ku(e)&&r[t]==="visible")},Xu=function(e){return mi(e,"overflowY")},qu=function(e){return mi(e,"overflowX")},$o=function(e,t){var r=t.ownerDocument,n=t;do{typeof ShadowRoot<"u"&&n instanceof ShadowRoot&&(n=n.host);var o=gi(e,n);if(o){var s=vi(e,n),i=s[1],a=s[2];if(i>a)return!0}n=n.parentNode}while(n&&n!==r.body);return!1},Zu=function(e){var t=e.scrollTop,r=e.scrollHeight,n=e.clientHeight;return[t,r,n]},Qu=function(e){var t=e.scrollLeft,r=e.scrollWidth,n=e.clientWidth;return[t,r,n]},gi=function(e,t){return e==="v"?Xu(t):qu(t)},vi=function(e,t){return e==="v"?Zu(t):Qu(t)},Ju=function(e,t){return e==="h"&&t==="rtl"?-1:1},ef=function(e,t,r,n,o){var s=Ju(e,window.getComputedStyle(t).direction),i=s*n,a=r.target,c=t.contains(a),l=!1,u=i>0,d=0,p=0;do{if(!a)break;var g=vi(e,a),v=g[0],h=g[1],b=g[2],y=h-b-s*v;(v||y)&&gi(e,a)&&(d+=y,p+=v);var x=a.parentNode;a=x&&x.nodeType===Node.DOCUMENT_FRAGMENT_NODE?x.host:x}while(!c&&a!==document.body||c&&(t.contains(a)||t===a));return(u&&Math.abs(d)<1||!u&&Math.abs(p)<1)&&(l=!0),l},Wt=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},zo=function(e){return[e.deltaX,e.deltaY]},Bo=function(e){return e&&"current"in e?e.current:e},tf=function(e,t){return e[0]===t[0]&&e[1]===t[1]},rf=function(e){return`
56
+ `)},Lo=function(){var e=parseInt(document.body.getAttribute(gt)||"0",10);return isFinite(e)?e:0},Uu=function(){f.useEffect(function(){return document.body.setAttribute(gt,(Lo()+1).toString()),function(){var e=Lo()-1;e<=0?document.body.removeAttribute(gt):document.body.setAttribute(gt,e.toString())}},[])},Yu=function(e){var t=e.noRelative,r=e.noImportant,n=e.gapMode,o=n===void 0?"margin":n;Uu();var s=f.useMemo(function(){return Wu(o)},[o]);return f.createElement(Hu,{styles:Gu(s,!t,o,r?"":"!important")})},Br=!1;if(typeof window<"u")try{var Vt=Object.defineProperty({},"passive",{get:function(){return Br=!0,!0}});window.addEventListener("test",Vt,Vt),window.removeEventListener("test",Vt,Vt)}catch{Br=!1}var ft=Br?{passive:!1}:!1,Ku=function(e){return e.tagName==="TEXTAREA"},mi=function(e,t){if(!(e instanceof Element))return!1;var r=window.getComputedStyle(e);return r[t]!=="hidden"&&!(r.overflowY===r.overflowX&&!Ku(e)&&r[t]==="visible")},Xu=function(e){return mi(e,"overflowY")},qu=function(e){return mi(e,"overflowX")},$o=function(e,t){var r=t.ownerDocument,n=t;do{typeof ShadowRoot<"u"&&n instanceof ShadowRoot&&(n=n.host);var o=gi(e,n);if(o){var s=vi(e,n),i=s[1],a=s[2];if(i>a)return!0}n=n.parentNode}while(n&&n!==r.body);return!1},Zu=function(e){var t=e.scrollTop,r=e.scrollHeight,n=e.clientHeight;return[t,r,n]},Qu=function(e){var t=e.scrollLeft,r=e.scrollWidth,n=e.clientWidth;return[t,r,n]},gi=function(e,t){return e==="v"?Xu(t):qu(t)},vi=function(e,t){return e==="v"?Zu(t):Qu(t)},Ju=function(e,t){return e==="h"&&t==="rtl"?-1:1},ef=function(e,t,r,n,o){var s=Ju(e,window.getComputedStyle(t).direction),i=s*n,a=r.target,c=t.contains(a),l=!1,u=i>0,d=0,p=0;do{if(!a)break;var g=vi(e,a),v=g[0],h=g[1],b=g[2],y=h-b-s*v;(v||y)&&gi(e,a)&&(d+=y,p+=v);var x=a.parentNode;a=x&&x.nodeType===Node.DOCUMENT_FRAGMENT_NODE?x.host:x}while(!c&&a!==document.body||c&&(t.contains(a)||t===a));return(u&&Math.abs(d)<1||!u&&Math.abs(p)<1)&&(l=!0),l},Wt=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},zo=function(e){return[e.deltaX,e.deltaY]},Fo=function(e){return e&&"current"in e?e.current:e},tf=function(e,t){return e[0]===t[0]&&e[1]===t[1]},rf=function(e){return`
57
57
  .block-interactivity-`.concat(e,` {pointer-events: none;}
58
58
  .allow-interactivity-`).concat(e,` {pointer-events: all;}
59
- `)},nf=0,pt=[];function of(e){var t=f.useRef([]),r=f.useRef([0,0]),n=f.useRef(),o=f.useState(nf++)[0],s=f.useState(hi)[0],i=f.useRef(e);f.useEffect(function(){i.current=e},[e]),f.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var h=Ru([e.lockRef.current],(e.shards||[]).map(Bo),!0).filter(Boolean);return h.forEach(function(b){return b.classList.add("allow-interactivity-".concat(o))}),function(){document.body.classList.remove("block-interactivity-".concat(o)),h.forEach(function(b){return b.classList.remove("allow-interactivity-".concat(o))})}}},[e.inert,e.lockRef.current,e.shards]);var a=f.useCallback(function(h,b){if("touches"in h&&h.touches.length===2||h.type==="wheel"&&h.ctrlKey)return!i.current.allowPinchZoom;var y=Wt(h),x=r.current,w="deltaX"in h?h.deltaX:x[0]-y[0],C="deltaY"in h?h.deltaY:x[1]-y[1],S,A=h.target,R=Math.abs(w)>Math.abs(C)?"h":"v";if("touches"in h&&R==="h"&&A.type==="range")return!1;var O=$o(R,A);if(!O)return!0;if(O?S=R:(S=R==="v"?"h":"v",O=$o(R,A)),!O)return!1;if(!n.current&&"changedTouches"in h&&(w||C)&&(n.current=S),!S)return!0;var $=n.current||S;return ef($,b,h,$==="h"?w:C)},[]),c=f.useCallback(function(h){var b=h;if(!(!pt.length||pt[pt.length-1]!==s)){var y="deltaY"in b?zo(b):Wt(b),x=t.current.filter(function(S){return S.name===b.type&&(S.target===b.target||b.target===S.shadowParent)&&tf(S.delta,y)})[0];if(x&&x.should){b.cancelable&&b.preventDefault();return}if(!x){var w=(i.current.shards||[]).map(Bo).filter(Boolean).filter(function(S){return S.contains(b.target)}),C=w.length>0?a(b,w[0]):!i.current.noIsolation;C&&b.cancelable&&b.preventDefault()}}},[]),l=f.useCallback(function(h,b,y,x){var w={name:h,delta:b,target:y,should:x,shadowParent:sf(y)};t.current.push(w),setTimeout(function(){t.current=t.current.filter(function(C){return C!==w})},1)},[]),u=f.useCallback(function(h){r.current=Wt(h),n.current=void 0},[]),d=f.useCallback(function(h){l(h.type,zo(h),h.target,a(h,e.lockRef.current))},[]),p=f.useCallback(function(h){l(h.type,Wt(h),h.target,a(h,e.lockRef.current))},[]);f.useEffect(function(){return pt.push(s),e.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:p}),document.addEventListener("wheel",c,ft),document.addEventListener("touchmove",c,ft),document.addEventListener("touchstart",u,ft),function(){pt=pt.filter(function(h){return h!==s}),document.removeEventListener("wheel",c,ft),document.removeEventListener("touchmove",c,ft),document.removeEventListener("touchstart",u,ft)}},[]);var g=e.removeScrollBar,v=e.inert;return f.createElement(f.Fragment,null,v?f.createElement(s,{styles:rf(o)}):null,g?f.createElement(Yu,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function sf(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const af=Ou(pi,of);var dn=f.forwardRef(function(e,t){return f.createElement(pr,Pe({},e,{ref:t,sideCar:af}))});dn.classNames=pr.classNames;var lf=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},ht=new WeakMap,Ht=new WeakMap,Gt={},Or=0,yi=function(e){return e&&(e.host||yi(e.parentNode))},cf=function(e,t){return t.map(function(r){if(e.contains(r))return r;var n=yi(r);return n&&e.contains(n)?n:(console.error("aria-hidden",r,"in not contained inside",e,". Doing nothing"),null)}).filter(function(r){return!!r})},df=function(e,t,r,n){var o=cf(t,Array.isArray(e)?e:[e]);Gt[r]||(Gt[r]=new WeakMap);var s=Gt[r],i=[],a=new Set,c=new Set(o),l=function(d){!d||a.has(d)||(a.add(d),l(d.parentNode))};o.forEach(l);var u=function(d){!d||c.has(d)||Array.prototype.forEach.call(d.children,function(p){if(a.has(p))u(p);else try{var g=p.getAttribute(n),v=g!==null&&g!=="false",h=(ht.get(p)||0)+1,b=(s.get(p)||0)+1;ht.set(p,h),s.set(p,b),i.push(p),h===1&&v&&Ht.set(p,!0),b===1&&p.setAttribute(r,"true"),v||p.setAttribute(n,"true")}catch(y){console.error("aria-hidden: cannot operate on ",p,y)}})};return u(t),a.clear(),Or++,function(){i.forEach(function(d){var p=ht.get(d)-1,g=s.get(d)-1;ht.set(d,p),s.set(d,g),p||(Ht.has(d)||d.removeAttribute(n),Ht.delete(d)),g||d.removeAttribute(r)}),Or--,Or||(ht=new WeakMap,ht=new WeakMap,Ht=new WeakMap,Gt={})}},bi=function(e,t,r){r===void 0&&(r="data-aria-hidden");var n=Array.from(Array.isArray(e)?e:[e]),o=lf(e);return o?(n.push.apply(n,Array.from(o.querySelectorAll("[aria-live], script"))),df(n,o,r,"aria-hidden")):function(){return null}},hr="Dialog",[xi,wi]=Ke(hr),[uf,Ae]=xi(hr),Ci=e=>{const{__scopeDialog:t,children:r,open:n,defaultOpen:o,onOpenChange:s,modal:i=!0}=e,a=f.useRef(null),c=f.useRef(null),[l,u]=et({prop:n,defaultProp:o??!1,onChange:s,caller:hr});return m.jsx(uf,{scope:t,triggerRef:a,contentRef:c,contentId:He(),titleId:He(),descriptionId:He(),open:l,onOpenChange:u,onOpenToggle:f.useCallback(()=>u(d=>!d),[u]),modal:i,children:r})};Ci.displayName=hr;var Si="DialogTrigger",Ei=f.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,o=Ae(Si,r),s=ee(t,o.triggerRef);return m.jsx(K.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":pn(o.open),...n,ref:s,onClick:Q(e.onClick,o.onOpenToggle)})});Ei.displayName=Si;var un="DialogPortal",[ff,Ri]=xi(un,{forceMount:void 0}),Ai=e=>{const{__scopeDialog:t,forceMount:r,children:n,container:o}=e,s=Ae(un,t);return m.jsx(ff,{scope:t,forceMount:r,children:f.Children.map(n,i=>m.jsx(St,{present:r||s.open,children:m.jsx(cn,{asChild:!0,container:o,children:i})}))})};Ai.displayName=un;var er="DialogOverlay",Ni=f.forwardRef((e,t)=>{const r=Ri(er,e.__scopeDialog),{forceMount:n=r.forceMount,...o}=e,s=Ae(er,e.__scopeDialog);return s.modal?m.jsx(St,{present:n||s.open,children:m.jsx(hf,{...o,ref:t})}):null});Ni.displayName=er;var pf=bt("DialogOverlay.RemoveScroll"),hf=f.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,o=Ae(er,r);return m.jsx(dn,{as:pf,allowPinchZoom:!0,shards:[o.contentRef],children:m.jsx(K.div,{"data-state":pn(o.open),...n,ref:t,style:{pointerEvents:"auto",...n.style}})})}),rt="DialogContent",Pi=f.forwardRef((e,t)=>{const r=Ri(rt,e.__scopeDialog),{forceMount:n=r.forceMount,...o}=e,s=Ae(rt,e.__scopeDialog);return m.jsx(St,{present:n||s.open,children:s.modal?m.jsx(mf,{...o,ref:t}):m.jsx(gf,{...o,ref:t})})});Pi.displayName=rt;var mf=f.forwardRef((e,t)=>{const r=Ae(rt,e.__scopeDialog),n=f.useRef(null),o=ee(t,r.contentRef,n);return f.useEffect(()=>{const s=n.current;if(s)return bi(s)},[]),m.jsx(Ti,{...e,ref:o,trapFocus:r.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:Q(e.onCloseAutoFocus,s=>{var i;s.preventDefault(),(i=r.triggerRef.current)==null||i.focus()}),onPointerDownOutside:Q(e.onPointerDownOutside,s=>{const i=s.detail.originalEvent,a=i.button===0&&i.ctrlKey===!0;(i.button===2||a)&&s.preventDefault()}),onFocusOutside:Q(e.onFocusOutside,s=>s.preventDefault())})}),gf=f.forwardRef((e,t)=>{const r=Ae(rt,e.__scopeDialog),n=f.useRef(!1),o=f.useRef(!1);return m.jsx(Ti,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:s=>{var i,a;(i=e.onCloseAutoFocus)==null||i.call(e,s),s.defaultPrevented||(n.current||(a=r.triggerRef.current)==null||a.focus(),s.preventDefault()),n.current=!1,o.current=!1},onInteractOutside:s=>{var c,l;(c=e.onInteractOutside)==null||c.call(e,s),s.defaultPrevented||(n.current=!0,s.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const i=s.target;((l=r.triggerRef.current)==null?void 0:l.contains(i))&&s.preventDefault(),s.detail.originalEvent.type==="focusin"&&o.current&&s.preventDefault()}})}),Ti=f.forwardRef((e,t)=>{const{__scopeDialog:r,trapFocus:n,onOpenAutoFocus:o,onCloseAutoFocus:s,...i}=e,a=Ae(rt,r),c=f.useRef(null),l=ee(t,c);return di(),m.jsxs(m.Fragment,{children:[m.jsx(ln,{asChild:!0,loop:!0,trapped:n,onMountAutoFocus:o,onUnmountAutoFocus:s,children:m.jsx(an,{role:"dialog",id:a.contentId,"aria-describedby":a.descriptionId,"aria-labelledby":a.titleId,"data-state":pn(a.open),...i,ref:l,onDismiss:()=>a.onOpenChange(!1)})}),m.jsxs(m.Fragment,{children:[m.jsx(yf,{titleId:a.titleId}),m.jsx(xf,{contentRef:c,descriptionId:a.descriptionId})]})]})}),fn="DialogTitle",ki=f.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,o=Ae(fn,r);return m.jsx(K.h2,{id:o.titleId,...n,ref:t})});ki.displayName=fn;var Di="DialogDescription",Mi=f.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,o=Ae(Di,r);return m.jsx(K.p,{id:o.descriptionId,...n,ref:t})});Mi.displayName=Di;var Ii="DialogClose",Oi=f.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,o=Ae(Ii,r);return m.jsx(K.button,{type:"button",...n,ref:t,onClick:Q(e.onClick,()=>o.onOpenChange(!1))})});Oi.displayName=Ii;function pn(e){return e?"open":"closed"}var _i="DialogTitleWarning",[vf,ji]=Id(_i,{contentName:rt,titleName:fn,docsSlug:"dialog"}),yf=({titleId:e})=>{const t=ji(_i),r=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
59
+ `)},nf=0,pt=[];function of(e){var t=f.useRef([]),r=f.useRef([0,0]),n=f.useRef(),o=f.useState(nf++)[0],s=f.useState(hi)[0],i=f.useRef(e);f.useEffect(function(){i.current=e},[e]),f.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var h=Ru([e.lockRef.current],(e.shards||[]).map(Fo),!0).filter(Boolean);return h.forEach(function(b){return b.classList.add("allow-interactivity-".concat(o))}),function(){document.body.classList.remove("block-interactivity-".concat(o)),h.forEach(function(b){return b.classList.remove("allow-interactivity-".concat(o))})}}},[e.inert,e.lockRef.current,e.shards]);var a=f.useCallback(function(h,b){if("touches"in h&&h.touches.length===2||h.type==="wheel"&&h.ctrlKey)return!i.current.allowPinchZoom;var y=Wt(h),x=r.current,w="deltaX"in h?h.deltaX:x[0]-y[0],C="deltaY"in h?h.deltaY:x[1]-y[1],S,A=h.target,R=Math.abs(w)>Math.abs(C)?"h":"v";if("touches"in h&&R==="h"&&A.type==="range")return!1;var O=$o(R,A);if(!O)return!0;if(O?S=R:(S=R==="v"?"h":"v",O=$o(R,A)),!O)return!1;if(!n.current&&"changedTouches"in h&&(w||C)&&(n.current=S),!S)return!0;var $=n.current||S;return ef($,b,h,$==="h"?w:C)},[]),c=f.useCallback(function(h){var b=h;if(!(!pt.length||pt[pt.length-1]!==s)){var y="deltaY"in b?zo(b):Wt(b),x=t.current.filter(function(S){return S.name===b.type&&(S.target===b.target||b.target===S.shadowParent)&&tf(S.delta,y)})[0];if(x&&x.should){b.cancelable&&b.preventDefault();return}if(!x){var w=(i.current.shards||[]).map(Fo).filter(Boolean).filter(function(S){return S.contains(b.target)}),C=w.length>0?a(b,w[0]):!i.current.noIsolation;C&&b.cancelable&&b.preventDefault()}}},[]),l=f.useCallback(function(h,b,y,x){var w={name:h,delta:b,target:y,should:x,shadowParent:sf(y)};t.current.push(w),setTimeout(function(){t.current=t.current.filter(function(C){return C!==w})},1)},[]),u=f.useCallback(function(h){r.current=Wt(h),n.current=void 0},[]),d=f.useCallback(function(h){l(h.type,zo(h),h.target,a(h,e.lockRef.current))},[]),p=f.useCallback(function(h){l(h.type,Wt(h),h.target,a(h,e.lockRef.current))},[]);f.useEffect(function(){return pt.push(s),e.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:p}),document.addEventListener("wheel",c,ft),document.addEventListener("touchmove",c,ft),document.addEventListener("touchstart",u,ft),function(){pt=pt.filter(function(h){return h!==s}),document.removeEventListener("wheel",c,ft),document.removeEventListener("touchmove",c,ft),document.removeEventListener("touchstart",u,ft)}},[]);var g=e.removeScrollBar,v=e.inert;return f.createElement(f.Fragment,null,v?f.createElement(s,{styles:rf(o)}):null,g?f.createElement(Yu,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function sf(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const af=Ou(pi,of);var dn=f.forwardRef(function(e,t){return f.createElement(pr,Pe({},e,{ref:t,sideCar:af}))});dn.classNames=pr.classNames;var lf=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},ht=new WeakMap,Ht=new WeakMap,Gt={},Or=0,yi=function(e){return e&&(e.host||yi(e.parentNode))},cf=function(e,t){return t.map(function(r){if(e.contains(r))return r;var n=yi(r);return n&&e.contains(n)?n:(console.error("aria-hidden",r,"in not contained inside",e,". Doing nothing"),null)}).filter(function(r){return!!r})},df=function(e,t,r,n){var o=cf(t,Array.isArray(e)?e:[e]);Gt[r]||(Gt[r]=new WeakMap);var s=Gt[r],i=[],a=new Set,c=new Set(o),l=function(d){!d||a.has(d)||(a.add(d),l(d.parentNode))};o.forEach(l);var u=function(d){!d||c.has(d)||Array.prototype.forEach.call(d.children,function(p){if(a.has(p))u(p);else try{var g=p.getAttribute(n),v=g!==null&&g!=="false",h=(ht.get(p)||0)+1,b=(s.get(p)||0)+1;ht.set(p,h),s.set(p,b),i.push(p),h===1&&v&&Ht.set(p,!0),b===1&&p.setAttribute(r,"true"),v||p.setAttribute(n,"true")}catch(y){console.error("aria-hidden: cannot operate on ",p,y)}})};return u(t),a.clear(),Or++,function(){i.forEach(function(d){var p=ht.get(d)-1,g=s.get(d)-1;ht.set(d,p),s.set(d,g),p||(Ht.has(d)||d.removeAttribute(n),Ht.delete(d)),g||d.removeAttribute(r)}),Or--,Or||(ht=new WeakMap,ht=new WeakMap,Ht=new WeakMap,Gt={})}},bi=function(e,t,r){r===void 0&&(r="data-aria-hidden");var n=Array.from(Array.isArray(e)?e:[e]),o=lf(e);return o?(n.push.apply(n,Array.from(o.querySelectorAll("[aria-live], script"))),df(n,o,r,"aria-hidden")):function(){return null}},hr="Dialog",[xi,wi]=Ke(hr),[uf,Ae]=xi(hr),Ci=e=>{const{__scopeDialog:t,children:r,open:n,defaultOpen:o,onOpenChange:s,modal:i=!0}=e,a=f.useRef(null),c=f.useRef(null),[l,u]=et({prop:n,defaultProp:o??!1,onChange:s,caller:hr});return m.jsx(uf,{scope:t,triggerRef:a,contentRef:c,contentId:He(),titleId:He(),descriptionId:He(),open:l,onOpenChange:u,onOpenToggle:f.useCallback(()=>u(d=>!d),[u]),modal:i,children:r})};Ci.displayName=hr;var Si="DialogTrigger",Ei=f.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,o=Ae(Si,r),s=ee(t,o.triggerRef);return m.jsx(K.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":pn(o.open),...n,ref:s,onClick:Q(e.onClick,o.onOpenToggle)})});Ei.displayName=Si;var un="DialogPortal",[ff,Ri]=xi(un,{forceMount:void 0}),Ai=e=>{const{__scopeDialog:t,forceMount:r,children:n,container:o}=e,s=Ae(un,t);return m.jsx(ff,{scope:t,forceMount:r,children:f.Children.map(n,i=>m.jsx(St,{present:r||s.open,children:m.jsx(cn,{asChild:!0,container:o,children:i})}))})};Ai.displayName=un;var er="DialogOverlay",Ni=f.forwardRef((e,t)=>{const r=Ri(er,e.__scopeDialog),{forceMount:n=r.forceMount,...o}=e,s=Ae(er,e.__scopeDialog);return s.modal?m.jsx(St,{present:n||s.open,children:m.jsx(hf,{...o,ref:t})}):null});Ni.displayName=er;var pf=bt("DialogOverlay.RemoveScroll"),hf=f.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,o=Ae(er,r);return m.jsx(dn,{as:pf,allowPinchZoom:!0,shards:[o.contentRef],children:m.jsx(K.div,{"data-state":pn(o.open),...n,ref:t,style:{pointerEvents:"auto",...n.style}})})}),rt="DialogContent",Pi=f.forwardRef((e,t)=>{const r=Ri(rt,e.__scopeDialog),{forceMount:n=r.forceMount,...o}=e,s=Ae(rt,e.__scopeDialog);return m.jsx(St,{present:n||s.open,children:s.modal?m.jsx(mf,{...o,ref:t}):m.jsx(gf,{...o,ref:t})})});Pi.displayName=rt;var mf=f.forwardRef((e,t)=>{const r=Ae(rt,e.__scopeDialog),n=f.useRef(null),o=ee(t,r.contentRef,n);return f.useEffect(()=>{const s=n.current;if(s)return bi(s)},[]),m.jsx(Ti,{...e,ref:o,trapFocus:r.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:Q(e.onCloseAutoFocus,s=>{var i;s.preventDefault(),(i=r.triggerRef.current)==null||i.focus()}),onPointerDownOutside:Q(e.onPointerDownOutside,s=>{const i=s.detail.originalEvent,a=i.button===0&&i.ctrlKey===!0;(i.button===2||a)&&s.preventDefault()}),onFocusOutside:Q(e.onFocusOutside,s=>s.preventDefault())})}),gf=f.forwardRef((e,t)=>{const r=Ae(rt,e.__scopeDialog),n=f.useRef(!1),o=f.useRef(!1);return m.jsx(Ti,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:s=>{var i,a;(i=e.onCloseAutoFocus)==null||i.call(e,s),s.defaultPrevented||(n.current||(a=r.triggerRef.current)==null||a.focus(),s.preventDefault()),n.current=!1,o.current=!1},onInteractOutside:s=>{var c,l;(c=e.onInteractOutside)==null||c.call(e,s),s.defaultPrevented||(n.current=!0,s.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const i=s.target;((l=r.triggerRef.current)==null?void 0:l.contains(i))&&s.preventDefault(),s.detail.originalEvent.type==="focusin"&&o.current&&s.preventDefault()}})}),Ti=f.forwardRef((e,t)=>{const{__scopeDialog:r,trapFocus:n,onOpenAutoFocus:o,onCloseAutoFocus:s,...i}=e,a=Ae(rt,r),c=f.useRef(null),l=ee(t,c);return di(),m.jsxs(m.Fragment,{children:[m.jsx(ln,{asChild:!0,loop:!0,trapped:n,onMountAutoFocus:o,onUnmountAutoFocus:s,children:m.jsx(an,{role:"dialog",id:a.contentId,"aria-describedby":a.descriptionId,"aria-labelledby":a.titleId,"data-state":pn(a.open),...i,ref:l,onDismiss:()=>a.onOpenChange(!1)})}),m.jsxs(m.Fragment,{children:[m.jsx(yf,{titleId:a.titleId}),m.jsx(xf,{contentRef:c,descriptionId:a.descriptionId})]})]})}),fn="DialogTitle",ki=f.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,o=Ae(fn,r);return m.jsx(K.h2,{id:o.titleId,...n,ref:t})});ki.displayName=fn;var Di="DialogDescription",Mi=f.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,o=Ae(Di,r);return m.jsx(K.p,{id:o.descriptionId,...n,ref:t})});Mi.displayName=Di;var Ii="DialogClose",Oi=f.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,o=Ae(Ii,r);return m.jsx(K.button,{type:"button",...n,ref:t,onClick:Q(e.onClick,()=>o.onOpenChange(!1))})});Oi.displayName=Ii;function pn(e){return e?"open":"closed"}var _i="DialogTitleWarning",[vf,ji]=Id(_i,{contentName:rt,titleName:fn,docsSlug:"dialog"}),yf=({titleId:e})=>{const t=ji(_i),r=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
60
60
 
61
61
  If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
62
62
 
@@ -65,7 +65,7 @@ For more information, see https://radix-ui.com/primitives/docs/components/${t.do
65
65
  *
66
66
  * This source code is licensed under the ISC license.
67
67
  * See the LICENSE file in the root directory of this source tree.
68
- */const wf=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),Cf=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(t,r,n)=>n?n.toUpperCase():r.toLowerCase()),Fo=e=>{const t=Cf(e);return t.charAt(0).toUpperCase()+t.slice(1)},Bi=(...e)=>e.filter((t,r,n)=>!!t&&t.trim()!==""&&n.indexOf(t)===r).join(" ").trim(),Sf=e=>{for(const t in e)if(t.startsWith("aria-")||t==="role"||t==="title")return!0};/**
68
+ */const wf=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),Cf=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(t,r,n)=>n?n.toUpperCase():r.toLowerCase()),Bo=e=>{const t=Cf(e);return t.charAt(0).toUpperCase()+t.slice(1)},Fi=(...e)=>e.filter((t,r,n)=>!!t&&t.trim()!==""&&n.indexOf(t)===r).join(" ").trim(),Sf=e=>{for(const t in e)if(t.startsWith("aria-")||t==="role"||t==="title")return!0};/**
69
69
  * @license lucide-react v0.542.0 - ISC
70
70
  *
71
71
  * This source code is licensed under the ISC license.
@@ -75,12 +75,12 @@ For more information, see https://radix-ui.com/primitives/docs/components/${t.do
75
75
  *
76
76
  * This source code is licensed under the ISC license.
77
77
  * See the LICENSE file in the root directory of this source tree.
78
- */const Rf=E.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:r=2,absoluteStrokeWidth:n,className:o="",children:s,iconNode:i,...a},c)=>E.createElement("svg",{ref:c,...Ef,width:t,height:t,stroke:e,strokeWidth:n?Number(r)*24/Number(t):r,className:Bi("lucide",o),...!s&&!Sf(a)&&{"aria-hidden":"true"},...a},[...i.map(([l,u])=>E.createElement(l,u)),...Array.isArray(s)?s:[s]]));/**
78
+ */const Rf=E.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:r=2,absoluteStrokeWidth:n,className:o="",children:s,iconNode:i,...a},c)=>E.createElement("svg",{ref:c,...Ef,width:t,height:t,stroke:e,strokeWidth:n?Number(r)*24/Number(t):r,className:Fi("lucide",o),...!s&&!Sf(a)&&{"aria-hidden":"true"},...a},[...i.map(([l,u])=>E.createElement(l,u)),...Array.isArray(s)?s:[s]]));/**
79
79
  * @license lucide-react v0.542.0 - ISC
80
80
  *
81
81
  * This source code is licensed under the ISC license.
82
82
  * See the LICENSE file in the root directory of this source tree.
83
- */const Et=(e,t)=>{const r=E.forwardRef(({className:n,...o},s)=>E.createElement(Rf,{ref:s,iconNode:t,className:Bi(`lucide-${wf(Fo(e))}`,`lucide-${e}`,n),...o}));return r.displayName=Fo(e),r};/**
83
+ */const Et=(e,t)=>{const r=E.forwardRef(({className:n,...o},s)=>E.createElement(Rf,{ref:s,iconNode:t,className:Fi(`lucide-${wf(Bo(e))}`,`lucide-${e}`,n),...o}));return r.displayName=Bo(e),r};/**
84
84
  * @license lucide-react v0.542.0 - ISC
85
85
  *
86
86
  * This source code is licensed under the ISC license.
@@ -90,7 +90,7 @@ For more information, see https://radix-ui.com/primitives/docs/components/${t.do
90
90
  *
91
91
  * This source code is licensed under the ISC license.
92
92
  * See the LICENSE file in the root directory of this source tree.
93
- */const Nf=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],Fi=Et("chevron-down",Nf);/**
93
+ */const Nf=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],Bi=Et("chevron-down",Nf);/**
94
94
  * @license lucide-react v0.542.0 - ISC
95
95
  *
96
96
  * This source code is licensed under the ISC license.
@@ -110,13 +110,13 @@ For more information, see https://radix-ui.com/primitives/docs/components/${t.do
110
110
  *
111
111
  * This source code is licensed under the ISC license.
112
112
  * See the LICENSE file in the root directory of this source tree.
113
- */const Of=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],_f=Et("x",Of),jf=Li,Lf=$i,Vi=zi,$f=mr,yn=f.forwardRef(({className:e,...t},r)=>m.jsx(hn,{ref:r,className:G("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}));yn.displayName=hn.displayName;const Wi=f.forwardRef(({className:e,children:t,...r},n)=>m.jsxs(Vi,{children:[m.jsx(yn,{}),m.jsxs(mn,{ref:n,className:G("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-white 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),...r,children:[t,m.jsxs(mr,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-white transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-gray-950 focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-gray-100 data-[state=open]:text-gray-500 cursor-pointer",children:[m.jsx(_f,{className:"h-4 w-4"}),m.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));Wi.displayName=mn.displayName;const Hi=({className:e,...t})=>m.jsx("div",{className:G("flex flex-col space-y-1.5 text-center sm:text-left",e),...t});Hi.displayName="DialogHeader";const Gi=({className:e,...t})=>m.jsx("div",{className:G("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...t});Gi.displayName="DialogFooter";const Ui=f.forwardRef(({className:e,...t},r)=>m.jsx(gn,{ref:r,className:G("text-lg font-semibold leading-none tracking-tight",e),...t}));Ui.displayName=gn.displayName;const Yi=f.forwardRef(({className:e,...t},r)=>m.jsx(vn,{ref:r,className:G("text-sm text-gray-500",e),...t}));Yi.displayName=vn.displayName;function Vo(e,[t,r]){return Math.min(r,Math.max(t,e))}const zf=["top","right","bottom","left"],Ue=Math.min,ge=Math.max,tr=Math.round,Ut=Math.floor,ke=e=>({x:e,y:e}),Bf={left:"right",right:"left",bottom:"top",top:"bottom"},Ff={start:"end",end:"start"};function Vr(e,t,r){return ge(e,Ue(t,r))}function je(e,t){return typeof e=="function"?e(t):e}function Le(e){return e.split("-")[0]}function Rt(e){return e.split("-")[1]}function bn(e){return e==="x"?"y":"x"}function xn(e){return e==="y"?"height":"width"}const Vf=new Set(["top","bottom"]);function Te(e){return Vf.has(Le(e))?"y":"x"}function wn(e){return bn(Te(e))}function Wf(e,t,r){r===void 0&&(r=!1);const n=Rt(e),o=wn(e),s=xn(o);let i=o==="x"?n===(r?"end":"start")?"right":"left":n==="start"?"bottom":"top";return t.reference[s]>t.floating[s]&&(i=rr(i)),[i,rr(i)]}function Hf(e){const t=rr(e);return[Wr(e),t,Wr(t)]}function Wr(e){return e.replace(/start|end/g,t=>Ff[t])}const Wo=["left","right"],Ho=["right","left"],Gf=["top","bottom"],Uf=["bottom","top"];function Yf(e,t,r){switch(e){case"top":case"bottom":return r?t?Ho:Wo:t?Wo:Ho;case"left":case"right":return t?Gf:Uf;default:return[]}}function Kf(e,t,r,n){const o=Rt(e);let s=Yf(Le(e),r==="start",n);return o&&(s=s.map(i=>i+"-"+o),t&&(s=s.concat(s.map(Wr)))),s}function rr(e){return e.replace(/left|right|bottom|top/g,t=>Bf[t])}function Xf(e){return{top:0,right:0,bottom:0,left:0,...e}}function Ki(e){return typeof e!="number"?Xf(e):{top:e,right:e,bottom:e,left:e}}function nr(e){const{x:t,y:r,width:n,height:o}=e;return{width:n,height:o,top:r,left:t,right:t+n,bottom:r+o,x:t,y:r}}function Go(e,t,r){let{reference:n,floating:o}=e;const s=Te(t),i=wn(t),a=xn(i),c=Le(t),l=s==="y",u=n.x+n.width/2-o.width/2,d=n.y+n.height/2-o.height/2,p=n[a]/2-o[a]/2;let g;switch(c){case"top":g={x:u,y:n.y-o.height};break;case"bottom":g={x:u,y:n.y+n.height};break;case"right":g={x:n.x+n.width,y:d};break;case"left":g={x:n.x-o.width,y:d};break;default:g={x:n.x,y:n.y}}switch(Rt(t)){case"start":g[i]-=p*(r&&l?-1:1);break;case"end":g[i]+=p*(r&&l?-1:1);break}return g}const qf=async(e,t,r)=>{const{placement:n="bottom",strategy:o="absolute",middleware:s=[],platform:i}=r,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:u,y:d}=Go(l,n,c),p=n,g={},v=0;for(let h=0;h<a.length;h++){const{name:b,fn:y}=a[h],{x,y:w,data:C,reset:S}=await y({x:u,y:d,initialPlacement:n,placement:p,strategy:o,middlewareData:g,rects:l,platform:i,elements:{reference:e,floating:t}});u=x??u,d=w??d,g={...g,[b]:{...g[b],...C}},S&&v<=50&&(v++,typeof S=="object"&&(S.placement&&(p=S.placement),S.rects&&(l=S.rects===!0?await i.getElementRects({reference:e,floating:t,strategy:o}):S.rects),{x:u,y:d}=Go(l,p,c)),h=-1)}return{x:u,y:d,placement:p,strategy:o,middlewareData:g}};async function Mt(e,t){var r;t===void 0&&(t={});const{x:n,y:o,platform:s,rects:i,elements:a,strategy:c}=e,{boundary:l="clippingAncestors",rootBoundary:u="viewport",elementContext:d="floating",altBoundary:p=!1,padding:g=0}=je(t,e),v=Ki(g),b=a[p?d==="floating"?"reference":"floating":d],y=nr(await s.getClippingRect({element:(r=await(s.isElement==null?void 0:s.isElement(b)))==null||r?b:b.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(a.floating)),boundary:l,rootBoundary:u,strategy:c})),x=d==="floating"?{x:n,y:o,width:i.floating.width,height:i.floating.height}:i.reference,w=await(s.getOffsetParent==null?void 0:s.getOffsetParent(a.floating)),C=await(s.isElement==null?void 0:s.isElement(w))?await(s.getScale==null?void 0:s.getScale(w))||{x:1,y:1}:{x:1,y:1},S=nr(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:x,offsetParent:w,strategy:c}):x);return{top:(y.top-S.top+v.top)/C.y,bottom:(S.bottom-y.bottom+v.bottom)/C.y,left:(y.left-S.left+v.left)/C.x,right:(S.right-y.right+v.right)/C.x}}const Zf=e=>({name:"arrow",options:e,async fn(t){const{x:r,y:n,placement:o,rects:s,platform:i,elements:a,middlewareData:c}=t,{element:l,padding:u=0}=je(e,t)||{};if(l==null)return{};const d=Ki(u),p={x:r,y:n},g=wn(o),v=xn(g),h=await i.getDimensions(l),b=g==="y",y=b?"top":"left",x=b?"bottom":"right",w=b?"clientHeight":"clientWidth",C=s.reference[v]+s.reference[g]-p[g]-s.floating[v],S=p[g]-s.reference[g],A=await(i.getOffsetParent==null?void 0:i.getOffsetParent(l));let R=A?A[w]:0;(!R||!await(i.isElement==null?void 0:i.isElement(A)))&&(R=a.floating[w]||s.floating[v]);const O=C/2-S/2,$=R/2-h[v]/2-1,L=Ue(d[y],$),k=Ue(d[x],$),P=L,_=R-h[v]-k,I=R/2-h[v]/2+O,D=Vr(P,I,_),N=!c.arrow&&Rt(o)!=null&&I!==D&&s.reference[v]/2-(I<P?L:k)-h[v]/2<0,M=N?I<P?I-P:I-_:0;return{[g]:p[g]+M,data:{[g]:D,centerOffset:I-D-M,...N&&{alignmentOffset:M}},reset:N}}}),Qf=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var r,n;const{placement:o,middlewareData:s,rects:i,initialPlacement:a,platform:c,elements:l}=t,{mainAxis:u=!0,crossAxis:d=!0,fallbackPlacements:p,fallbackStrategy:g="bestFit",fallbackAxisSideDirection:v="none",flipAlignment:h=!0,...b}=je(e,t);if((r=s.arrow)!=null&&r.alignmentOffset)return{};const y=Le(o),x=Te(a),w=Le(a)===a,C=await(c.isRTL==null?void 0:c.isRTL(l.floating)),S=p||(w||!h?[rr(a)]:Hf(a)),A=v!=="none";!p&&A&&S.push(...Kf(a,h,v,C));const R=[a,...S],O=await Mt(t,b),$=[];let L=((n=s.flip)==null?void 0:n.overflows)||[];if(u&&$.push(O[y]),d){const I=Wf(o,i,C);$.push(O[I[0]],O[I[1]])}if(L=[...L,{placement:o,overflows:$}],!$.every(I=>I<=0)){var k,P;const I=(((k=s.flip)==null?void 0:k.index)||0)+1,D=R[I];if(D&&(!(d==="alignment"?x!==Te(D):!1)||L.every(T=>Te(T.placement)===x?T.overflows[0]>0:!0)))return{data:{index:I,overflows:L},reset:{placement:D}};let N=(P=L.filter(M=>M.overflows[0]<=0).sort((M,T)=>M.overflows[1]-T.overflows[1])[0])==null?void 0:P.placement;if(!N)switch(g){case"bestFit":{var _;const M=(_=L.filter(T=>{if(A){const j=Te(T.placement);return j===x||j==="y"}return!0}).map(T=>[T.placement,T.overflows.filter(j=>j>0).reduce((j,U)=>j+U,0)]).sort((T,j)=>T[1]-j[1])[0])==null?void 0:_[0];M&&(N=M);break}case"initialPlacement":N=a;break}if(o!==N)return{reset:{placement:N}}}return{}}}};function Uo(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Yo(e){return zf.some(t=>e[t]>=0)}const Jf=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:r}=t,{strategy:n="referenceHidden",...o}=je(e,t);switch(n){case"referenceHidden":{const s=await Mt(t,{...o,elementContext:"reference"}),i=Uo(s,r.reference);return{data:{referenceHiddenOffsets:i,referenceHidden:Yo(i)}}}case"escaped":{const s=await Mt(t,{...o,altBoundary:!0}),i=Uo(s,r.floating);return{data:{escapedOffsets:i,escaped:Yo(i)}}}default:return{}}}}},Xi=new Set(["left","top"]);async function ep(e,t){const{placement:r,platform:n,elements:o}=e,s=await(n.isRTL==null?void 0:n.isRTL(o.floating)),i=Le(r),a=Rt(r),c=Te(r)==="y",l=Xi.has(i)?-1:1,u=s&&c?-1:1,d=je(t,e);let{mainAxis:p,crossAxis:g,alignmentAxis:v}=typeof d=="number"?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return a&&typeof v=="number"&&(g=a==="end"?v*-1:v),c?{x:g*u,y:p*l}:{x:p*l,y:g*u}}const tp=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var r,n;const{x:o,y:s,placement:i,middlewareData:a}=t,c=await ep(t,e);return i===((r=a.offset)==null?void 0:r.placement)&&(n=a.arrow)!=null&&n.alignmentOffset?{}:{x:o+c.x,y:s+c.y,data:{...c,placement:i}}}}},rp=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:r,y:n,placement:o}=t,{mainAxis:s=!0,crossAxis:i=!1,limiter:a={fn:b=>{let{x:y,y:x}=b;return{x:y,y:x}}},...c}=je(e,t),l={x:r,y:n},u=await Mt(t,c),d=Te(Le(o)),p=bn(d);let g=l[p],v=l[d];if(s){const b=p==="y"?"top":"left",y=p==="y"?"bottom":"right",x=g+u[b],w=g-u[y];g=Vr(x,g,w)}if(i){const b=d==="y"?"top":"left",y=d==="y"?"bottom":"right",x=v+u[b],w=v-u[y];v=Vr(x,v,w)}const h=a.fn({...t,[p]:g,[d]:v});return{...h,data:{x:h.x-r,y:h.y-n,enabled:{[p]:s,[d]:i}}}}}},np=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:r,y:n,placement:o,rects:s,middlewareData:i}=t,{offset:a=0,mainAxis:c=!0,crossAxis:l=!0}=je(e,t),u={x:r,y:n},d=Te(o),p=bn(d);let g=u[p],v=u[d];const h=je(a,t),b=typeof h=="number"?{mainAxis:h,crossAxis:0}:{mainAxis:0,crossAxis:0,...h};if(c){const w=p==="y"?"height":"width",C=s.reference[p]-s.floating[w]+b.mainAxis,S=s.reference[p]+s.reference[w]-b.mainAxis;g<C?g=C:g>S&&(g=S)}if(l){var y,x;const w=p==="y"?"width":"height",C=Xi.has(Le(o)),S=s.reference[d]-s.floating[w]+(C&&((y=i.offset)==null?void 0:y[d])||0)+(C?0:b.crossAxis),A=s.reference[d]+s.reference[w]+(C?0:((x=i.offset)==null?void 0:x[d])||0)-(C?b.crossAxis:0);v<S?v=S:v>A&&(v=A)}return{[p]:g,[d]:v}}}},op=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var r,n;const{placement:o,rects:s,platform:i,elements:a}=t,{apply:c=()=>{},...l}=je(e,t),u=await Mt(t,l),d=Le(o),p=Rt(o),g=Te(o)==="y",{width:v,height:h}=s.floating;let b,y;d==="top"||d==="bottom"?(b=d,y=p===(await(i.isRTL==null?void 0:i.isRTL(a.floating))?"start":"end")?"left":"right"):(y=d,b=p==="end"?"top":"bottom");const x=h-u.top-u.bottom,w=v-u.left-u.right,C=Ue(h-u[b],x),S=Ue(v-u[y],w),A=!t.middlewareData.shift;let R=C,O=S;if((r=t.middlewareData.shift)!=null&&r.enabled.x&&(O=w),(n=t.middlewareData.shift)!=null&&n.enabled.y&&(R=x),A&&!p){const L=ge(u.left,0),k=ge(u.right,0),P=ge(u.top,0),_=ge(u.bottom,0);g?O=v-2*(L!==0||k!==0?L+k:ge(u.left,u.right)):R=h-2*(P!==0||_!==0?P+_:ge(u.top,u.bottom))}await c({...t,availableWidth:O,availableHeight:R});const $=await i.getDimensions(a.floating);return v!==$.width||h!==$.height?{reset:{rects:!0}}:{}}}};function vr(){return typeof window<"u"}function At(e){return qi(e)?(e.nodeName||"").toLowerCase():"#document"}function ve(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Ie(e){var t;return(t=(qi(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function qi(e){return vr()?e instanceof Node||e instanceof ve(e).Node:!1}function Se(e){return vr()?e instanceof Element||e instanceof ve(e).Element:!1}function De(e){return vr()?e instanceof HTMLElement||e instanceof ve(e).HTMLElement:!1}function Ko(e){return!vr()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof ve(e).ShadowRoot}const sp=new Set(["inline","contents"]);function _t(e){const{overflow:t,overflowX:r,overflowY:n,display:o}=Ee(e);return/auto|scroll|overlay|hidden|clip/.test(t+n+r)&&!sp.has(o)}const ip=new Set(["table","td","th"]);function ap(e){return ip.has(At(e))}const lp=[":popover-open",":modal"];function yr(e){return lp.some(t=>{try{return e.matches(t)}catch{return!1}})}const cp=["transform","translate","scale","rotate","perspective"],dp=["transform","translate","scale","rotate","perspective","filter"],up=["paint","layout","strict","content"];function Cn(e){const t=Sn(),r=Se(e)?Ee(e):e;return cp.some(n=>r[n]?r[n]!=="none":!1)||(r.containerType?r.containerType!=="normal":!1)||!t&&(r.backdropFilter?r.backdropFilter!=="none":!1)||!t&&(r.filter?r.filter!=="none":!1)||dp.some(n=>(r.willChange||"").includes(n))||up.some(n=>(r.contain||"").includes(n))}function fp(e){let t=Ye(e);for(;De(t)&&!xt(t);){if(Cn(t))return t;if(yr(t))return null;t=Ye(t)}return null}function Sn(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const pp=new Set(["html","body","#document"]);function xt(e){return pp.has(At(e))}function Ee(e){return ve(e).getComputedStyle(e)}function br(e){return Se(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Ye(e){if(At(e)==="html")return e;const t=e.assignedSlot||e.parentNode||Ko(e)&&e.host||Ie(e);return Ko(t)?t.host:t}function Zi(e){const t=Ye(e);return xt(t)?e.ownerDocument?e.ownerDocument.body:e.body:De(t)&&_t(t)?t:Zi(t)}function It(e,t,r){var n;t===void 0&&(t=[]),r===void 0&&(r=!0);const o=Zi(e),s=o===((n=e.ownerDocument)==null?void 0:n.body),i=ve(o);if(s){const a=Hr(i);return t.concat(i,i.visualViewport||[],_t(o)?o:[],a&&r?It(a):[])}return t.concat(o,It(o,[],r))}function Hr(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Qi(e){const t=Ee(e);let r=parseFloat(t.width)||0,n=parseFloat(t.height)||0;const o=De(e),s=o?e.offsetWidth:r,i=o?e.offsetHeight:n,a=tr(r)!==s||tr(n)!==i;return a&&(r=s,n=i),{width:r,height:n,$:a}}function En(e){return Se(e)?e:e.contextElement}function vt(e){const t=En(e);if(!De(t))return ke(1);const r=t.getBoundingClientRect(),{width:n,height:o,$:s}=Qi(t);let i=(s?tr(r.width):r.width)/n,a=(s?tr(r.height):r.height)/o;return(!i||!Number.isFinite(i))&&(i=1),(!a||!Number.isFinite(a))&&(a=1),{x:i,y:a}}const hp=ke(0);function Ji(e){const t=ve(e);return!Sn()||!t.visualViewport?hp:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function mp(e,t,r){return t===void 0&&(t=!1),!r||t&&r!==ve(e)?!1:t}function nt(e,t,r,n){t===void 0&&(t=!1),r===void 0&&(r=!1);const o=e.getBoundingClientRect(),s=En(e);let i=ke(1);t&&(n?Se(n)&&(i=vt(n)):i=vt(e));const a=mp(s,r,n)?Ji(s):ke(0);let c=(o.left+a.x)/i.x,l=(o.top+a.y)/i.y,u=o.width/i.x,d=o.height/i.y;if(s){const p=ve(s),g=n&&Se(n)?ve(n):n;let v=p,h=Hr(v);for(;h&&n&&g!==v;){const b=vt(h),y=h.getBoundingClientRect(),x=Ee(h),w=y.left+(h.clientLeft+parseFloat(x.paddingLeft))*b.x,C=y.top+(h.clientTop+parseFloat(x.paddingTop))*b.y;c*=b.x,l*=b.y,u*=b.x,d*=b.y,c+=w,l+=C,v=ve(h),h=Hr(v)}}return nr({width:u,height:d,x:c,y:l})}function xr(e,t){const r=br(e).scrollLeft;return t?t.left+r:nt(Ie(e)).left+r}function ea(e,t){const r=e.getBoundingClientRect(),n=r.left+t.scrollLeft-xr(e,r),o=r.top+t.scrollTop;return{x:n,y:o}}function gp(e){let{elements:t,rect:r,offsetParent:n,strategy:o}=e;const s=o==="fixed",i=Ie(n),a=t?yr(t.floating):!1;if(n===i||a&&s)return r;let c={scrollLeft:0,scrollTop:0},l=ke(1);const u=ke(0),d=De(n);if((d||!d&&!s)&&((At(n)!=="body"||_t(i))&&(c=br(n)),De(n))){const g=nt(n);l=vt(n),u.x=g.x+n.clientLeft,u.y=g.y+n.clientTop}const p=i&&!d&&!s?ea(i,c):ke(0);return{width:r.width*l.x,height:r.height*l.y,x:r.x*l.x-c.scrollLeft*l.x+u.x+p.x,y:r.y*l.y-c.scrollTop*l.y+u.y+p.y}}function vp(e){return Array.from(e.getClientRects())}function yp(e){const t=Ie(e),r=br(e),n=e.ownerDocument.body,o=ge(t.scrollWidth,t.clientWidth,n.scrollWidth,n.clientWidth),s=ge(t.scrollHeight,t.clientHeight,n.scrollHeight,n.clientHeight);let i=-r.scrollLeft+xr(e);const a=-r.scrollTop;return Ee(n).direction==="rtl"&&(i+=ge(t.clientWidth,n.clientWidth)-o),{width:o,height:s,x:i,y:a}}const Xo=25;function bp(e,t){const r=ve(e),n=Ie(e),o=r.visualViewport;let s=n.clientWidth,i=n.clientHeight,a=0,c=0;if(o){s=o.width,i=o.height;const u=Sn();(!u||u&&t==="fixed")&&(a=o.offsetLeft,c=o.offsetTop)}const l=xr(n);if(l<=0){const u=n.ownerDocument,d=u.body,p=getComputedStyle(d),g=u.compatMode==="CSS1Compat"&&parseFloat(p.marginLeft)+parseFloat(p.marginRight)||0,v=Math.abs(n.clientWidth-d.clientWidth-g);v<=Xo&&(s-=v)}else l<=Xo&&(s+=l);return{width:s,height:i,x:a,y:c}}const xp=new Set(["absolute","fixed"]);function wp(e,t){const r=nt(e,!0,t==="fixed"),n=r.top+e.clientTop,o=r.left+e.clientLeft,s=De(e)?vt(e):ke(1),i=e.clientWidth*s.x,a=e.clientHeight*s.y,c=o*s.x,l=n*s.y;return{width:i,height:a,x:c,y:l}}function qo(e,t,r){let n;if(t==="viewport")n=bp(e,r);else if(t==="document")n=yp(Ie(e));else if(Se(t))n=wp(t,r);else{const o=Ji(e);n={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return nr(n)}function ta(e,t){const r=Ye(e);return r===t||!Se(r)||xt(r)?!1:Ee(r).position==="fixed"||ta(r,t)}function Cp(e,t){const r=t.get(e);if(r)return r;let n=It(e,[],!1).filter(a=>Se(a)&&At(a)!=="body"),o=null;const s=Ee(e).position==="fixed";let i=s?Ye(e):e;for(;Se(i)&&!xt(i);){const a=Ee(i),c=Cn(i);!c&&a.position==="fixed"&&(o=null),(s?!c&&!o:!c&&a.position==="static"&&!!o&&xp.has(o.position)||_t(i)&&!c&&ta(e,i))?n=n.filter(u=>u!==i):o=a,i=Ye(i)}return t.set(e,n),n}function Sp(e){let{element:t,boundary:r,rootBoundary:n,strategy:o}=e;const i=[...r==="clippingAncestors"?yr(t)?[]:Cp(t,this._c):[].concat(r),n],a=i[0],c=i.reduce((l,u)=>{const d=qo(t,u,o);return l.top=ge(d.top,l.top),l.right=Ue(d.right,l.right),l.bottom=Ue(d.bottom,l.bottom),l.left=ge(d.left,l.left),l},qo(t,a,o));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function Ep(e){const{width:t,height:r}=Qi(e);return{width:t,height:r}}function Rp(e,t,r){const n=De(t),o=Ie(t),s=r==="fixed",i=nt(e,!0,s,t);let a={scrollLeft:0,scrollTop:0};const c=ke(0);function l(){c.x=xr(o)}if(n||!n&&!s)if((At(t)!=="body"||_t(o))&&(a=br(t)),n){const g=nt(t,!0,s,t);c.x=g.x+t.clientLeft,c.y=g.y+t.clientTop}else o&&l();s&&!n&&o&&l();const u=o&&!n&&!s?ea(o,a):ke(0),d=i.left+a.scrollLeft-c.x-u.x,p=i.top+a.scrollTop-c.y-u.y;return{x:d,y:p,width:i.width,height:i.height}}function _r(e){return Ee(e).position==="static"}function Zo(e,t){if(!De(e)||Ee(e).position==="fixed")return null;if(t)return t(e);let r=e.offsetParent;return Ie(e)===r&&(r=r.ownerDocument.body),r}function ra(e,t){const r=ve(e);if(yr(e))return r;if(!De(e)){let o=Ye(e);for(;o&&!xt(o);){if(Se(o)&&!_r(o))return o;o=Ye(o)}return r}let n=Zo(e,t);for(;n&&ap(n)&&_r(n);)n=Zo(n,t);return n&&xt(n)&&_r(n)&&!Cn(n)?r:n||fp(e)||r}const Ap=async function(e){const t=this.getOffsetParent||ra,r=this.getDimensions,n=await r(e.floating);return{reference:Rp(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:n.width,height:n.height}}};function Np(e){return Ee(e).direction==="rtl"}const Pp={convertOffsetParentRelativeRectToViewportRelativeRect:gp,getDocumentElement:Ie,getClippingRect:Sp,getOffsetParent:ra,getElementRects:Ap,getClientRects:vp,getDimensions:Ep,getScale:vt,isElement:Se,isRTL:Np};function na(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function Tp(e,t){let r=null,n;const o=Ie(e);function s(){var a;clearTimeout(n),(a=r)==null||a.disconnect(),r=null}function i(a,c){a===void 0&&(a=!1),c===void 0&&(c=1),s();const l=e.getBoundingClientRect(),{left:u,top:d,width:p,height:g}=l;if(a||t(),!p||!g)return;const v=Ut(d),h=Ut(o.clientWidth-(u+p)),b=Ut(o.clientHeight-(d+g)),y=Ut(u),w={rootMargin:-v+"px "+-h+"px "+-b+"px "+-y+"px",threshold:ge(0,Ue(1,c))||1};let C=!0;function S(A){const R=A[0].intersectionRatio;if(R!==c){if(!C)return i();R?i(!1,R):n=setTimeout(()=>{i(!1,1e-7)},1e3)}R===1&&!na(l,e.getBoundingClientRect())&&i(),C=!1}try{r=new IntersectionObserver(S,{...w,root:o.ownerDocument})}catch{r=new IntersectionObserver(S,w)}r.observe(e)}return i(!0),s}function kp(e,t,r,n){n===void 0&&(n={});const{ancestorScroll:o=!0,ancestorResize:s=!0,elementResize:i=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:c=!1}=n,l=En(e),u=o||s?[...l?It(l):[],...It(t)]:[];u.forEach(y=>{o&&y.addEventListener("scroll",r,{passive:!0}),s&&y.addEventListener("resize",r)});const d=l&&a?Tp(l,r):null;let p=-1,g=null;i&&(g=new ResizeObserver(y=>{let[x]=y;x&&x.target===l&&g&&(g.unobserve(t),cancelAnimationFrame(p),p=requestAnimationFrame(()=>{var w;(w=g)==null||w.observe(t)})),r()}),l&&!c&&g.observe(l),g.observe(t));let v,h=c?nt(e):null;c&&b();function b(){const y=nt(e);h&&!na(h,y)&&r(),h=y,v=requestAnimationFrame(b)}return r(),()=>{var y;u.forEach(x=>{o&&x.removeEventListener("scroll",r),s&&x.removeEventListener("resize",r)}),d==null||d(),(y=g)==null||y.disconnect(),g=null,c&&cancelAnimationFrame(v)}}const Dp=tp,Mp=rp,Ip=Qf,Op=op,_p=Jf,Qo=Zf,jp=np,Lp=(e,t,r)=>{const n=new Map,o={platform:Pp,...r},s={...o.platform,_c:n};return qf(e,t,{...o,platform:s})};var $p=typeof document<"u",zp=function(){},Zt=$p?E.useLayoutEffect:zp;function or(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 r,n,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(r=e.length,r!==t.length)return!1;for(n=r;n--!==0;)if(!or(e[n],t[n]))return!1;return!0}if(o=Object.keys(e),r=o.length,r!==Object.keys(t).length)return!1;for(n=r;n--!==0;)if(!{}.hasOwnProperty.call(t,o[n]))return!1;for(n=r;n--!==0;){const s=o[n];if(!(s==="_owner"&&e.$$typeof)&&!or(e[s],t[s]))return!1}return!0}return e!==e&&t!==t}function oa(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Jo(e,t){const r=oa(e);return Math.round(t*r)/r}function jr(e){const t=f.useRef(e);return Zt(()=>{t.current=e}),t}function Bp(e){e===void 0&&(e={});const{placement:t="bottom",strategy:r="absolute",middleware:n=[],platform:o,elements:{reference:s,floating:i}={},transform:a=!0,whileElementsMounted:c,open:l}=e,[u,d]=f.useState({x:0,y:0,strategy:r,placement:t,middlewareData:{},isPositioned:!1}),[p,g]=f.useState(n);or(p,n)||g(n);const[v,h]=f.useState(null),[b,y]=f.useState(null),x=f.useCallback(T=>{T!==A.current&&(A.current=T,h(T))},[]),w=f.useCallback(T=>{T!==R.current&&(R.current=T,y(T))},[]),C=s||v,S=i||b,A=f.useRef(null),R=f.useRef(null),O=f.useRef(u),$=c!=null,L=jr(c),k=jr(o),P=jr(l),_=f.useCallback(()=>{if(!A.current||!R.current)return;const T={placement:t,strategy:r,middleware:p};k.current&&(T.platform=k.current),Lp(A.current,R.current,T).then(j=>{const U={...j,isPositioned:P.current!==!1};I.current&&!or(O.current,U)&&(O.current=U,ar.flushSync(()=>{d(U)}))})},[p,t,r,k,P]);Zt(()=>{l===!1&&O.current.isPositioned&&(O.current.isPositioned=!1,d(T=>({...T,isPositioned:!1})))},[l]);const I=f.useRef(!1);Zt(()=>(I.current=!0,()=>{I.current=!1}),[]),Zt(()=>{if(C&&(A.current=C),S&&(R.current=S),C&&S){if(L.current)return L.current(C,S,_);_()}},[C,S,_,L,$]);const D=f.useMemo(()=>({reference:A,floating:R,setReference:x,setFloating:w}),[x,w]),N=f.useMemo(()=>({reference:C,floating:S}),[C,S]),M=f.useMemo(()=>{const T={position:r,left:0,top:0};if(!N.floating)return T;const j=Jo(N.floating,u.x),U=Jo(N.floating,u.y);return a?{...T,transform:"translate("+j+"px, "+U+"px)",...oa(N.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:j,top:U}},[r,a,N.floating,u.x,u.y]);return f.useMemo(()=>({...u,update:_,refs:D,elements:N,floatingStyles:M}),[u,_,D,N,M])}const Fp=e=>{function t(r){return{}.hasOwnProperty.call(r,"current")}return{name:"arrow",options:e,fn(r){const{element:n,padding:o}=typeof e=="function"?e(r):e;return n&&t(n)?n.current!=null?Qo({element:n.current,padding:o}).fn(r):{}:n?Qo({element:n,padding:o}).fn(r):{}}}},Vp=(e,t)=>({...Dp(e),options:[e,t]}),Wp=(e,t)=>({...Mp(e),options:[e,t]}),Hp=(e,t)=>({...jp(e),options:[e,t]}),Gp=(e,t)=>({...Ip(e),options:[e,t]}),Up=(e,t)=>({...Op(e),options:[e,t]}),Yp=(e,t)=>({..._p(e),options:[e,t]}),Kp=(e,t)=>({...Fp(e),options:[e,t]});var Xp="Arrow",sa=f.forwardRef((e,t)=>{const{children:r,width:n=10,height:o=5,...s}=e;return m.jsx(K.svg,{...s,ref:t,width:n,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?r:m.jsx("polygon",{points:"0,0 30,0 15,10"})})});sa.displayName=Xp;var qp=sa;function ia(e){const[t,r]=f.useState(void 0);return le(()=>{if(e){r({width:e.offsetWidth,height:e.offsetHeight});const n=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;r({width:i,height:a})});return n.observe(e,{box:"border-box"}),()=>n.unobserve(e)}else r(void 0)},[e]),t}var Rn="Popper",[aa,la]=Ke(Rn),[Zp,ca]=aa(Rn),da=e=>{const{__scopePopper:t,children:r}=e,[n,o]=f.useState(null);return m.jsx(Zp,{scope:t,anchor:n,onAnchorChange:o,children:r})};da.displayName=Rn;var ua="PopperAnchor",fa=f.forwardRef((e,t)=>{const{__scopePopper:r,virtualRef:n,...o}=e,s=ca(ua,r),i=f.useRef(null),a=ee(t,i),c=f.useRef(null);return f.useEffect(()=>{const l=c.current;c.current=(n==null?void 0:n.current)||i.current,l!==c.current&&s.onAnchorChange(c.current)}),n?null:m.jsx(K.div,{...o,ref:a})});fa.displayName=ua;var An="PopperContent",[Qp,Jp]=aa(An),pa=f.forwardRef((e,t)=>{var z,B,re,Z,q,Y;const{__scopePopper:r,side:n="bottom",sideOffset:o=0,align:s="center",alignOffset:i=0,arrowPadding:a=0,avoidCollisions:c=!0,collisionBoundary:l=[],collisionPadding:u=0,sticky:d="partial",hideWhenDetached:p=!1,updatePositionStrategy:g="optimized",onPlaced:v,...h}=e,b=ca(An,r),[y,x]=f.useState(null),w=ee(t,de=>x(de)),[C,S]=f.useState(null),A=ia(C),R=(A==null?void 0:A.width)??0,O=(A==null?void 0:A.height)??0,$=n+(s!=="center"?"-"+s:""),L=typeof u=="number"?u:{top:0,right:0,bottom:0,left:0,...u},k=Array.isArray(l)?l:[l],P=k.length>0,_={padding:L,boundary:k.filter(th),altBoundary:P},{refs:I,floatingStyles:D,placement:N,isPositioned:M,middlewareData:T}=Bp({strategy:"fixed",placement:$,whileElementsMounted:(...de)=>kp(...de,{animationFrame:g==="always"}),elements:{reference:b.anchor},middleware:[Vp({mainAxis:o+O,alignmentAxis:i}),c&&Wp({mainAxis:!0,crossAxis:!1,limiter:d==="partial"?Hp():void 0,..._}),c&&Gp({..._}),Up({..._,apply:({elements:de,rects:ue,availableWidth:Ze,availableHeight:ze})=>{const{width:be,height:jt}=ue.reference,fe=de.floating.style;fe.setProperty("--radix-popper-available-width",`${Ze}px`),fe.setProperty("--radix-popper-available-height",`${ze}px`),fe.setProperty("--radix-popper-anchor-width",`${be}px`),fe.setProperty("--radix-popper-anchor-height",`${jt}px`)}}),C&&Kp({element:C,padding:a}),rh({arrowWidth:R,arrowHeight:O}),p&&Yp({strategy:"referenceHidden",..._})]}),[j,U]=ga(N),V=tt(v);le(()=>{M&&(V==null||V())},[M,V]);const se=(z=T.arrow)==null?void 0:z.x,F=(B=T.arrow)==null?void 0:B.y,X=((re=T.arrow)==null?void 0:re.centerOffset)!==0,[J,ne]=f.useState();return le(()=>{y&&ne(window.getComputedStyle(y).zIndex)},[y]),m.jsx("div",{ref:I.setFloating,"data-radix-popper-content-wrapper":"",style:{...D,transform:M?D.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:J,"--radix-popper-transform-origin":[(Z=T.transformOrigin)==null?void 0:Z.x,(q=T.transformOrigin)==null?void 0:q.y].join(" "),...((Y=T.hide)==null?void 0:Y.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:m.jsx(Qp,{scope:r,placedSide:j,onArrowChange:S,arrowX:se,arrowY:F,shouldHideArrow:X,children:m.jsx(K.div,{"data-side":j,"data-align":U,...h,ref:w,style:{...h.style,animation:M?void 0:"none"}})})})});pa.displayName=An;var ha="PopperArrow",eh={top:"bottom",right:"left",bottom:"top",left:"right"},ma=f.forwardRef(function(t,r){const{__scopePopper:n,...o}=t,s=Jp(ha,n),i=eh[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(qp,{...o,ref:r,style:{...o.style,display:"block"}})})});ma.displayName=ha;function th(e){return e!==null}var rh=e=>({name:"transformOrigin",options:e,fn(t){var b,y,x;const{placement:r,rects:n,middlewareData:o}=t,i=((b=o.arrow)==null?void 0:b.centerOffset)!==0,a=i?0:e.arrowWidth,c=i?0:e.arrowHeight,[l,u]=ga(r),d={start:"0%",center:"50%",end:"100%"}[u],p=(((y=o.arrow)==null?void 0:y.x)??0)+a/2,g=(((x=o.arrow)==null?void 0:x.y)??0)+c/2;let v="",h="";return l==="bottom"?(v=i?d:`${p}px`,h=`${-c}px`):l==="top"?(v=i?d:`${p}px`,h=`${n.floating.height+c}px`):l==="right"?(v=`${-c}px`,h=i?d:`${g}px`):l==="left"&&(v=`${n.floating.width+c}px`,h=i?d:`${g}px`),{data:{x:v,y:h}}}});function ga(e){const[t,r="center"]=e.split("-");return[t,r]}var nh=da,oh=fa,sh=pa,ih=ma;function va(e){const t=f.useRef({value:e,previous:e});return f.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}var ya=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"}),ah="VisuallyHidden",lh=f.forwardRef((e,t)=>m.jsx(K.span,{...e,ref:t,style:{...ya,...e.style}}));lh.displayName=ah;var ch=[" ","Enter","ArrowUp","ArrowDown"],dh=[" ","Enter"],ot="Select",[wr,Cr,uh]=$s(ot),[Nt]=Ke(ot,[uh,la]),Sr=la(),[fh,Xe]=Nt(ot),[ph,hh]=Nt(ot),ba=e=>{const{__scopeSelect:t,children:r,open:n,defaultOpen:o,onOpenChange:s,value:i,defaultValue:a,onValueChange:c,dir:l,name:u,autoComplete:d,disabled:p,required:g,form:v}=e,h=Sr(t),[b,y]=f.useState(null),[x,w]=f.useState(null),[C,S]=f.useState(!1),A=Hs(l),[R,O]=et({prop:n,defaultProp:o??!1,onChange:s,caller:ot}),[$,L]=et({prop:i,defaultProp:a,onChange:c,caller:ot}),k=f.useRef(null),P=b?v||!!b.closest("form"):!0,[_,I]=f.useState(new Set),D=Array.from(_).map(N=>N.props.value).join(";");return m.jsx(nh,{...h,children:m.jsxs(fh,{required:g,scope:t,trigger:b,onTriggerChange:y,valueNode:x,onValueNodeChange:w,valueNodeHasChildren:C,onValueNodeHasChildrenChange:S,contentId:He(),value:$,onValueChange:L,open:R,onOpenChange:O,dir:A,triggerPointerDownPosRef:k,disabled:p,children:[m.jsx(wr.Provider,{scope:t,children:m.jsx(ph,{scope:e.__scopeSelect,onNativeOptionAdd:f.useCallback(N=>{I(M=>new Set(M).add(N))},[]),onNativeOptionRemove:f.useCallback(N=>{I(M=>{const T=new Set(M);return T.delete(N),T})},[]),children:r})}),P?m.jsxs(Ha,{"aria-hidden":!0,required:g,tabIndex:-1,name:u,autoComplete:d,value:$,onChange:N=>L(N.target.value),disabled:p,form:v,children:[$===void 0?m.jsx("option",{value:""}):null,Array.from(_)]},D):null]})})};ba.displayName=ot;var xa="SelectTrigger",wa=f.forwardRef((e,t)=>{const{__scopeSelect:r,disabled:n=!1,...o}=e,s=Sr(r),i=Xe(xa,r),a=i.disabled||n,c=ee(t,i.onTriggerChange),l=Cr(r),u=f.useRef("touch"),[d,p,g]=Ua(h=>{const b=l().filter(w=>!w.disabled),y=b.find(w=>w.value===i.value),x=Ya(b,h,y);x!==void 0&&i.onValueChange(x.value)}),v=h=>{a||(i.onOpenChange(!0),g()),h&&(i.triggerPointerDownPosRef.current={x:Math.round(h.pageX),y:Math.round(h.pageY)})};return m.jsx(oh,{asChild:!0,...s,children:m.jsx(K.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":Ga(i.value)?"":void 0,...o,ref:c,onClick:Q(o.onClick,h=>{h.currentTarget.focus(),u.current!=="mouse"&&v(h)}),onPointerDown:Q(o.onPointerDown,h=>{u.current=h.pointerType;const b=h.target;b.hasPointerCapture(h.pointerId)&&b.releasePointerCapture(h.pointerId),h.button===0&&h.ctrlKey===!1&&h.pointerType==="mouse"&&(v(h),h.preventDefault())}),onKeyDown:Q(o.onKeyDown,h=>{const b=d.current!=="";!(h.ctrlKey||h.altKey||h.metaKey)&&h.key.length===1&&p(h.key),!(b&&h.key===" ")&&ch.includes(h.key)&&(v(),h.preventDefault())})})})});wa.displayName=xa;var Ca="SelectValue",Sa=f.forwardRef((e,t)=>{const{__scopeSelect:r,className:n,style:o,children:s,placeholder:i="",...a}=e,c=Xe(Ca,r),{onValueNodeHasChildrenChange:l}=c,u=s!==void 0,d=ee(t,c.onValueNodeChange);return le(()=>{l(u)},[l,u]),m.jsx(K.span,{...a,ref:d,style:{pointerEvents:"none"},children:Ga(c.value)?m.jsx(m.Fragment,{children:i}):s})});Sa.displayName=Ca;var mh="SelectIcon",Ea=f.forwardRef((e,t)=>{const{__scopeSelect:r,children:n,...o}=e;return m.jsx(K.span,{"aria-hidden":!0,...o,ref:t,children:n||"▼"})});Ea.displayName=mh;var gh="SelectPortal",Ra=e=>m.jsx(cn,{asChild:!0,...e});Ra.displayName=gh;var st="SelectContent",Aa=f.forwardRef((e,t)=>{const r=Xe(st,e.__scopeSelect),[n,o]=f.useState();if(le(()=>{o(new DocumentFragment)},[]),!r.open){const s=n;return s?ar.createPortal(m.jsx(Na,{scope:e.__scopeSelect,children:m.jsx(wr.Slot,{scope:e.__scopeSelect,children:m.jsx("div",{children:e.children})})}),s):null}return m.jsx(Pa,{...e,ref:t})});Aa.displayName=st;var Ce=10,[Na,qe]=Nt(st),vh="SelectContentImpl",yh=bt("SelectContent.RemoveScroll"),Pa=f.forwardRef((e,t)=>{const{__scopeSelect:r,position:n="item-aligned",onCloseAutoFocus:o,onEscapeKeyDown:s,onPointerDownOutside:i,side:a,sideOffset:c,align:l,alignOffset:u,arrowPadding:d,collisionBoundary:p,collisionPadding:g,sticky:v,hideWhenDetached:h,avoidCollisions:b,...y}=e,x=Xe(st,r),[w,C]=f.useState(null),[S,A]=f.useState(null),R=ee(t,z=>C(z)),[O,$]=f.useState(null),[L,k]=f.useState(null),P=Cr(r),[_,I]=f.useState(!1),D=f.useRef(!1);f.useEffect(()=>{if(w)return bi(w)},[w]),di();const N=f.useCallback(z=>{const[B,...re]=P().map(Y=>Y.ref.current),[Z]=re.slice(-1),q=document.activeElement;for(const Y of z)if(Y===q||(Y==null||Y.scrollIntoView({block:"nearest"}),Y===B&&S&&(S.scrollTop=0),Y===Z&&S&&(S.scrollTop=S.scrollHeight),Y==null||Y.focus(),document.activeElement!==q))return},[P,S]),M=f.useCallback(()=>N([O,w]),[N,O,w]);f.useEffect(()=>{_&&M()},[_,M]);const{onOpenChange:T,triggerPointerDownPosRef:j}=x;f.useEffect(()=>{if(w){let z={x:0,y:0};const B=Z=>{var q,Y;z={x:Math.abs(Math.round(Z.pageX)-(((q=j.current)==null?void 0:q.x)??0)),y:Math.abs(Math.round(Z.pageY)-(((Y=j.current)==null?void 0:Y.y)??0))}},re=Z=>{z.x<=10&&z.y<=10?Z.preventDefault():w.contains(Z.target)||T(!1),document.removeEventListener("pointermove",B),j.current=null};return j.current!==null&&(document.addEventListener("pointermove",B),document.addEventListener("pointerup",re,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",B),document.removeEventListener("pointerup",re,{capture:!0})}}},[w,T,j]),f.useEffect(()=>{const z=()=>T(!1);return window.addEventListener("blur",z),window.addEventListener("resize",z),()=>{window.removeEventListener("blur",z),window.removeEventListener("resize",z)}},[T]);const[U,V]=Ua(z=>{const B=P().filter(q=>!q.disabled),re=B.find(q=>q.ref.current===document.activeElement),Z=Ya(B,z,re);Z&&setTimeout(()=>Z.ref.current.focus())}),se=f.useCallback((z,B,re)=>{const Z=!D.current&&!re;(x.value!==void 0&&x.value===B||Z)&&($(z),Z&&(D.current=!0))},[x.value]),F=f.useCallback(()=>w==null?void 0:w.focus(),[w]),X=f.useCallback((z,B,re)=>{const Z=!D.current&&!re;(x.value!==void 0&&x.value===B||Z)&&k(z)},[x.value]),J=n==="popper"?Gr:Ta,ne=J===Gr?{side:a,sideOffset:c,align:l,alignOffset:u,arrowPadding:d,collisionBoundary:p,collisionPadding:g,sticky:v,hideWhenDetached:h,avoidCollisions:b}:{};return m.jsx(Na,{scope:r,content:w,viewport:S,onViewportChange:A,itemRefCallback:se,selectedItem:O,onItemLeave:F,itemTextRefCallback:X,focusSelectedItem:M,selectedItemText:L,position:n,isPositioned:_,searchRef:U,children:m.jsx(dn,{as:yh,allowPinchZoom:!0,children:m.jsx(ln,{asChild:!0,trapped:x.open,onMountAutoFocus:z=>{z.preventDefault()},onUnmountAutoFocus:Q(o,z=>{var B;(B=x.trigger)==null||B.focus({preventScroll:!0}),z.preventDefault()}),children:m.jsx(an,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:s,onPointerDownOutside:i,onFocusOutside:z=>z.preventDefault(),onDismiss:()=>x.onOpenChange(!1),children:m.jsx(J,{role:"listbox",id:x.contentId,"data-state":x.open?"open":"closed",dir:x.dir,onContextMenu:z=>z.preventDefault(),...y,...ne,onPlaced:()=>I(!0),ref:R,style:{display:"flex",flexDirection:"column",outline:"none",...y.style},onKeyDown:Q(y.onKeyDown,z=>{const B=z.ctrlKey||z.altKey||z.metaKey;if(z.key==="Tab"&&z.preventDefault(),!B&&z.key.length===1&&V(z.key),["ArrowUp","ArrowDown","Home","End"].includes(z.key)){let Z=P().filter(q=>!q.disabled).map(q=>q.ref.current);if(["ArrowUp","End"].includes(z.key)&&(Z=Z.slice().reverse()),["ArrowUp","ArrowDown"].includes(z.key)){const q=z.target,Y=Z.indexOf(q);Z=Z.slice(Y+1)}setTimeout(()=>N(Z)),z.preventDefault()}})})})})})})});Pa.displayName=vh;var bh="SelectItemAlignedPosition",Ta=f.forwardRef((e,t)=>{const{__scopeSelect:r,onPlaced:n,...o}=e,s=Xe(st,r),i=qe(st,r),[a,c]=f.useState(null),[l,u]=f.useState(null),d=ee(t,R=>u(R)),p=Cr(r),g=f.useRef(!1),v=f.useRef(!0),{viewport:h,selectedItem:b,selectedItemText:y,focusSelectedItem:x}=i,w=f.useCallback(()=>{if(s.trigger&&s.valueNode&&a&&l&&h&&b&&y){const R=s.trigger.getBoundingClientRect(),O=l.getBoundingClientRect(),$=s.valueNode.getBoundingClientRect(),L=y.getBoundingClientRect();if(s.dir!=="rtl"){const q=L.left-O.left,Y=$.left-q,de=R.left-Y,ue=R.width+de,Ze=Math.max(ue,O.width),ze=window.innerWidth-Ce,be=Vo(Y,[Ce,Math.max(Ce,ze-Ze)]);a.style.minWidth=ue+"px",a.style.left=be+"px"}else{const q=O.right-L.right,Y=window.innerWidth-$.right-q,de=window.innerWidth-R.right-Y,ue=R.width+de,Ze=Math.max(ue,O.width),ze=window.innerWidth-Ce,be=Vo(Y,[Ce,Math.max(Ce,ze-Ze)]);a.style.minWidth=ue+"px",a.style.right=be+"px"}const k=p(),P=window.innerHeight-Ce*2,_=h.scrollHeight,I=window.getComputedStyle(l),D=parseInt(I.borderTopWidth,10),N=parseInt(I.paddingTop,10),M=parseInt(I.borderBottomWidth,10),T=parseInt(I.paddingBottom,10),j=D+N+_+T+M,U=Math.min(b.offsetHeight*5,j),V=window.getComputedStyle(h),se=parseInt(V.paddingTop,10),F=parseInt(V.paddingBottom,10),X=R.top+R.height/2-Ce,J=P-X,ne=b.offsetHeight/2,z=b.offsetTop+ne,B=D+N+z,re=j-B;if(B<=X){const q=k.length>0&&b===k[k.length-1].ref.current;a.style.bottom="0px";const Y=l.clientHeight-h.offsetTop-h.offsetHeight,de=Math.max(J,ne+(q?F:0)+Y+M),ue=B+de;a.style.height=ue+"px"}else{const q=k.length>0&&b===k[0].ref.current;a.style.top="0px";const de=Math.max(X,D+h.offsetTop+(q?se:0)+ne)+re;a.style.height=de+"px",h.scrollTop=B-X+h.offsetTop}a.style.margin=`${Ce}px 0`,a.style.minHeight=U+"px",a.style.maxHeight=P+"px",n==null||n(),requestAnimationFrame(()=>g.current=!0)}},[p,s.trigger,s.valueNode,a,l,h,b,y,s.dir,n]);le(()=>w(),[w]);const[C,S]=f.useState();le(()=>{l&&S(window.getComputedStyle(l).zIndex)},[l]);const A=f.useCallback(R=>{R&&v.current===!0&&(w(),x==null||x(),v.current=!1)},[w,x]);return m.jsx(wh,{scope:r,contentWrapper:a,shouldExpandOnScrollRef:g,onScrollButtonChange:A,children:m.jsx("div",{ref:c,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:C},children:m.jsx(K.div,{...o,ref:d,style:{boxSizing:"border-box",maxHeight:"100%",...o.style}})})})});Ta.displayName=bh;var xh="SelectPopperPosition",Gr=f.forwardRef((e,t)=>{const{__scopeSelect:r,align:n="start",collisionPadding:o=Ce,...s}=e,i=Sr(r);return m.jsx(sh,{...i,...s,ref:t,align:n,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)"}})});Gr.displayName=xh;var[wh,Nn]=Nt(st,{}),Ur="SelectViewport",ka=f.forwardRef((e,t)=>{const{__scopeSelect:r,nonce:n,...o}=e,s=qe(Ur,r),i=Nn(Ur,r),a=ee(t,s.onViewportChange),c=f.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:n}),m.jsx(wr.Slot,{scope:r,children:m.jsx(K.div,{"data-radix-select-viewport":"",role:"presentation",...o,ref:a,style:{position:"relative",flex:1,overflow:"hidden auto",...o.style},onScroll:Q(o.onScroll,l=>{const u=l.currentTarget,{contentWrapper:d,shouldExpandOnScrollRef:p}=i;if(p!=null&&p.current&&d){const g=Math.abs(c.current-u.scrollTop);if(g>0){const v=window.innerHeight-Ce*2,h=parseFloat(d.style.minHeight),b=parseFloat(d.style.height),y=Math.max(h,b);if(y<v){const x=y+g,w=Math.min(v,x),C=x-w;d.style.height=w+"px",d.style.bottom==="0px"&&(u.scrollTop=C>0?C:0,d.style.justifyContent="flex-end")}}}c.current=u.scrollTop})})})]})});ka.displayName=Ur;var Da="SelectGroup",[Ch,Sh]=Nt(Da),Ma=f.forwardRef((e,t)=>{const{__scopeSelect:r,...n}=e,o=He();return m.jsx(Ch,{scope:r,id:o,children:m.jsx(K.div,{role:"group","aria-labelledby":o,...n,ref:t})})});Ma.displayName=Da;var Ia="SelectLabel",Oa=f.forwardRef((e,t)=>{const{__scopeSelect:r,...n}=e,o=Sh(Ia,r);return m.jsx(K.div,{id:o.id,...n,ref:t})});Oa.displayName=Ia;var sr="SelectItem",[Eh,_a]=Nt(sr),ja=f.forwardRef((e,t)=>{const{__scopeSelect:r,value:n,disabled:o=!1,textValue:s,...i}=e,a=Xe(sr,r),c=qe(sr,r),l=a.value===n,[u,d]=f.useState(s??""),[p,g]=f.useState(!1),v=ee(t,x=>{var w;return(w=c.itemRefCallback)==null?void 0:w.call(c,x,n,o)}),h=He(),b=f.useRef("touch"),y=()=>{o||(a.onValueChange(n),a.onOpenChange(!1))};if(n==="")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(Eh,{scope:r,value:n,disabled:o,textId:h,isSelected:l,onItemTextChange:f.useCallback(x=>{d(w=>w||((x==null?void 0:x.textContent)??"").trim())},[]),children:m.jsx(wr.ItemSlot,{scope:r,value:n,disabled:o,textValue:u,children:m.jsx(K.div,{role:"option","aria-labelledby":h,"data-highlighted":p?"":void 0,"aria-selected":l&&p,"data-state":l?"checked":"unchecked","aria-disabled":o||void 0,"data-disabled":o?"":void 0,tabIndex:o?void 0:-1,...i,ref:v,onFocus:Q(i.onFocus,()=>g(!0)),onBlur:Q(i.onBlur,()=>g(!1)),onClick:Q(i.onClick,()=>{b.current!=="mouse"&&y()}),onPointerUp:Q(i.onPointerUp,()=>{b.current==="mouse"&&y()}),onPointerDown:Q(i.onPointerDown,x=>{b.current=x.pointerType}),onPointerMove:Q(i.onPointerMove,x=>{var w;b.current=x.pointerType,o?(w=c.onItemLeave)==null||w.call(c):b.current==="mouse"&&x.currentTarget.focus({preventScroll:!0})}),onPointerLeave:Q(i.onPointerLeave,x=>{var w;x.currentTarget===document.activeElement&&((w=c.onItemLeave)==null||w.call(c))}),onKeyDown:Q(i.onKeyDown,x=>{var C;((C=c.searchRef)==null?void 0:C.current)!==""&&x.key===" "||(dh.includes(x.key)&&y(),x.key===" "&&x.preventDefault())})})})})});ja.displayName=sr;var kt="SelectItemText",La=f.forwardRef((e,t)=>{const{__scopeSelect:r,className:n,style:o,...s}=e,i=Xe(kt,r),a=qe(kt,r),c=_a(kt,r),l=hh(kt,r),[u,d]=f.useState(null),p=ee(t,y=>d(y),c.onItemTextChange,y=>{var x;return(x=a.itemTextRefCallback)==null?void 0:x.call(a,y,c.value,c.disabled)}),g=u==null?void 0:u.textContent,v=f.useMemo(()=>m.jsx("option",{value:c.value,disabled:c.disabled,children:g},c.value),[c.disabled,c.value,g]),{onNativeOptionAdd:h,onNativeOptionRemove:b}=l;return le(()=>(h(v),()=>b(v)),[h,b,v]),m.jsxs(m.Fragment,{children:[m.jsx(K.span,{id:c.textId,...s,ref:p}),c.isSelected&&i.valueNode&&!i.valueNodeHasChildren?ar.createPortal(s.children,i.valueNode):null]})});La.displayName=kt;var $a="SelectItemIndicator",za=f.forwardRef((e,t)=>{const{__scopeSelect:r,...n}=e;return _a($a,r).isSelected?m.jsx(K.span,{"aria-hidden":!0,...n,ref:t}):null});za.displayName=$a;var Yr="SelectScrollUpButton",Ba=f.forwardRef((e,t)=>{const r=qe(Yr,e.__scopeSelect),n=Nn(Yr,e.__scopeSelect),[o,s]=f.useState(!1),i=ee(t,n.onScrollButtonChange);return le(()=>{if(r.viewport&&r.isPositioned){let a=function(){const l=c.scrollTop>0;s(l)};const c=r.viewport;return a(),c.addEventListener("scroll",a),()=>c.removeEventListener("scroll",a)}},[r.viewport,r.isPositioned]),o?m.jsx(Va,{...e,ref:i,onAutoScroll:()=>{const{viewport:a,selectedItem:c}=r;a&&c&&(a.scrollTop=a.scrollTop-c.offsetHeight)}}):null});Ba.displayName=Yr;var Kr="SelectScrollDownButton",Fa=f.forwardRef((e,t)=>{const r=qe(Kr,e.__scopeSelect),n=Nn(Kr,e.__scopeSelect),[o,s]=f.useState(!1),i=ee(t,n.onScrollButtonChange);return le(()=>{if(r.viewport&&r.isPositioned){let a=function(){const l=c.scrollHeight-c.clientHeight,u=Math.ceil(c.scrollTop)<l;s(u)};const c=r.viewport;return a(),c.addEventListener("scroll",a),()=>c.removeEventListener("scroll",a)}},[r.viewport,r.isPositioned]),o?m.jsx(Va,{...e,ref:i,onAutoScroll:()=>{const{viewport:a,selectedItem:c}=r;a&&c&&(a.scrollTop=a.scrollTop+c.offsetHeight)}}):null});Fa.displayName=Kr;var Va=f.forwardRef((e,t)=>{const{__scopeSelect:r,onAutoScroll:n,...o}=e,s=qe("SelectScrollButton",r),i=f.useRef(null),a=Cr(r),c=f.useCallback(()=>{i.current!==null&&(window.clearInterval(i.current),i.current=null)},[]);return f.useEffect(()=>()=>c(),[c]),le(()=>{var u;const l=a().find(d=>d.ref.current===document.activeElement);(u=l==null?void 0:l.ref.current)==null||u.scrollIntoView({block:"nearest"})},[a]),m.jsx(K.div,{"aria-hidden":!0,...o,ref:t,style:{flexShrink:0,...o.style},onPointerDown:Q(o.onPointerDown,()=>{i.current===null&&(i.current=window.setInterval(n,50))}),onPointerMove:Q(o.onPointerMove,()=>{var l;(l=s.onItemLeave)==null||l.call(s),i.current===null&&(i.current=window.setInterval(n,50))}),onPointerLeave:Q(o.onPointerLeave,()=>{c()})})}),Rh="SelectSeparator",Wa=f.forwardRef((e,t)=>{const{__scopeSelect:r,...n}=e;return m.jsx(K.div,{"aria-hidden":!0,...n,ref:t})});Wa.displayName=Rh;var Xr="SelectArrow",Ah=f.forwardRef((e,t)=>{const{__scopeSelect:r,...n}=e,o=Sr(r),s=Xe(Xr,r),i=qe(Xr,r);return s.open&&i.position==="popper"?m.jsx(ih,{...o,...n,ref:t}):null});Ah.displayName=Xr;var Nh="SelectBubbleInput",Ha=f.forwardRef(({__scopeSelect:e,value:t,...r},n)=>{const o=f.useRef(null),s=ee(n,o),i=va(t);return f.useEffect(()=>{const a=o.current;if(!a)return;const c=window.HTMLSelectElement.prototype,u=Object.getOwnPropertyDescriptor(c,"value").set;if(i!==t&&u){const d=new Event("change",{bubbles:!0});u.call(a,t),a.dispatchEvent(d)}},[i,t]),m.jsx(K.select,{...r,style:{...ya,...r.style},ref:s,defaultValue:t})});Ha.displayName=Nh;function Ga(e){return e===""||e===void 0}function Ua(e){const t=tt(e),r=f.useRef(""),n=f.useRef(0),o=f.useCallback(i=>{const a=r.current+i;t(a),function c(l){r.current=l,window.clearTimeout(n.current),l!==""&&(n.current=window.setTimeout(()=>c(""),1e3))}(a)},[t]),s=f.useCallback(()=>{r.current="",window.clearTimeout(n.current)},[]);return f.useEffect(()=>()=>window.clearTimeout(n.current),[]),[r,o,s]}function Ya(e,t,r){const o=t.length>1&&Array.from(t).every(l=>l===t[0])?t[0]:t,s=r?e.indexOf(r):-1;let i=Ph(e,Math.max(s,0));o.length===1&&(i=i.filter(l=>l!==r));const c=i.find(l=>l.textValue.toLowerCase().startsWith(o.toLowerCase()));return c!==r?c:void 0}function Ph(e,t){return e.map((r,n)=>e[(t+n)%e.length])}var Th=ba,Ka=wa,kh=Sa,Dh=Ea,Mh=Ra,Xa=Aa,Ih=ka,Oh=Ma,qa=Oa,Za=ja,_h=La,jh=za,Qa=Ba,Ja=Fa,el=Wa;const Lh=Th,$h=Oh,zh=kh,tl=f.forwardRef(({className:e,children:t,...r},n)=>m.jsxs(Ka,{ref:n,className:G("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 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),...r,children:[t,m.jsx(Dh,{asChild:!0,children:m.jsx(Fi,{className:"h-4 w-4 opacity-50"})})]}));tl.displayName=Ka.displayName;const rl=f.forwardRef(({className:e,...t},r)=>m.jsx(Qa,{ref:r,className:G("flex cursor-default items-center justify-center py-1",e),...t,children:m.jsx(Tf,{className:"h-4 w-4"})}));rl.displayName=Qa.displayName;const nl=f.forwardRef(({className:e,...t},r)=>m.jsx(Ja,{ref:r,className:G("flex cursor-default items-center justify-center py-1",e),...t,children:m.jsx(Fi,{className:"h-4 w-4"})}));nl.displayName=Ja.displayName;const ol=f.forwardRef(({className:e,children:t,position:r="popper",...n},o)=>m.jsx(Mh,{children:m.jsxs(Xa,{ref:o,className:G("relative z-50 max-h-96 min-w-[8rem] overflow-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",r==="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:r,...n,children:[m.jsx(rl,{}),m.jsx(Ih,{className:G("p-1",r==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"),children:t}),m.jsx(nl,{})]})}));ol.displayName=Xa.displayName;const sl=f.forwardRef(({className:e,...t},r)=>m.jsx(qa,{ref:r,className:G("py-1.5 pl-8 pr-2 text-sm font-semibold",e),...t}));sl.displayName=qa.displayName;const il=f.forwardRef(({className:e,children:t,...r},n)=>m.jsxs(Za,{ref:n,className:G("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),...r,children:[m.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:m.jsx(jh,{children:m.jsx(gr,{className:"h-4 w-4"})})}),m.jsx(_h,{children:t})]}));il.displayName=Za.displayName;const al=f.forwardRef(({className:e,...t},r)=>m.jsx(el,{ref:r,className:G("-mx-1 my-1 h-px bg-muted",e),...t}));al.displayName=el.displayName;var Er="Checkbox",[Bh]=Ke(Er),[Fh,Pn]=Bh(Er);function Vh(e){const{__scopeCheckbox:t,checked:r,children:n,defaultChecked:o,disabled:s,form:i,name:a,onCheckedChange:c,required:l,value:u="on",internal_do_not_use_render:d}=e,[p,g]=et({prop:r,defaultProp:o??!1,onChange:c,caller:Er}),[v,h]=f.useState(null),[b,y]=f.useState(null),x=f.useRef(!1),w=v?!!i||!!v.closest("form"):!0,C={checked:p,disabled:s,setChecked:g,control:v,setControl:h,name:a,form:i,value:u,hasConsumerStoppedPropagationRef:x,required:l,defaultChecked:Ge(o)?!1:o,isFormControl:w,bubbleInput:b,setBubbleInput:y};return m.jsx(Fh,{scope:t,...C,children:Wh(d)?d(C):n})}var ll="CheckboxTrigger",cl=f.forwardRef(({__scopeCheckbox:e,onKeyDown:t,onClick:r,...n},o)=>{const{control:s,value:i,disabled:a,checked:c,required:l,setControl:u,setChecked:d,hasConsumerStoppedPropagationRef:p,isFormControl:g,bubbleInput:v}=Pn(ll,e),h=ee(o,u),b=f.useRef(c);return f.useEffect(()=>{const y=s==null?void 0:s.form;if(y){const x=()=>d(b.current);return y.addEventListener("reset",x),()=>y.removeEventListener("reset",x)}},[s,d]),m.jsx(K.button,{type:"button",role:"checkbox","aria-checked":Ge(c)?"mixed":c,"aria-required":l,"data-state":hl(c),"data-disabled":a?"":void 0,disabled:a,value:i,...n,ref:h,onKeyDown:Q(t,y=>{y.key==="Enter"&&y.preventDefault()}),onClick:Q(r,y=>{d(x=>Ge(x)?!0:!x),v&&g&&(p.current=y.isPropagationStopped(),p.current||y.stopPropagation())})})});cl.displayName=ll;var Tn=f.forwardRef((e,t)=>{const{__scopeCheckbox:r,name:n,checked:o,defaultChecked:s,required:i,disabled:a,value:c,onCheckedChange:l,form:u,...d}=e;return m.jsx(Vh,{__scopeCheckbox:r,checked:o,defaultChecked:s,disabled:a,required:i,onCheckedChange:l,name:n,form:u,value:c,internal_do_not_use_render:({isFormControl:p})=>m.jsxs(m.Fragment,{children:[m.jsx(cl,{...d,ref:t,__scopeCheckbox:r}),p&&m.jsx(pl,{__scopeCheckbox:r})]})})});Tn.displayName=Er;var dl="CheckboxIndicator",ul=f.forwardRef((e,t)=>{const{__scopeCheckbox:r,forceMount:n,...o}=e,s=Pn(dl,r);return m.jsx(St,{present:n||Ge(s.checked)||s.checked===!0,children:m.jsx(K.span,{"data-state":hl(s.checked),"data-disabled":s.disabled?"":void 0,...o,ref:t,style:{pointerEvents:"none",...e.style}})})});ul.displayName=dl;var fl="CheckboxBubbleInput",pl=f.forwardRef(({__scopeCheckbox:e,...t},r)=>{const{control:n,hasConsumerStoppedPropagationRef:o,checked:s,defaultChecked:i,required:a,disabled:c,name:l,value:u,form:d,bubbleInput:p,setBubbleInput:g}=Pn(fl,e),v=ee(r,g),h=va(s),b=ia(n);f.useEffect(()=>{const x=p;if(!x)return;const w=window.HTMLInputElement.prototype,S=Object.getOwnPropertyDescriptor(w,"checked").set,A=!o.current;if(h!==s&&S){const R=new Event("click",{bubbles:A});x.indeterminate=Ge(s),S.call(x,Ge(s)?!1:s),x.dispatchEvent(R)}},[p,h,s,o]);const y=f.useRef(Ge(s)?!1:s);return m.jsx(K.input,{type:"checkbox","aria-hidden":!0,defaultChecked:i??y.current,required:a,disabled:c,name:l,value:u,form:d,...t,tabIndex:-1,ref:v,style:{...t.style,...b,position:"absolute",pointerEvents:"none",opacity:0,margin:0,transform:"translateX(-100%)"}})});pl.displayName=fl;function Wh(e){return typeof e=="function"}function Ge(e){return e==="indeterminate"}function hl(e){return Ge(e)?"indeterminate":e?"checked":"unchecked"}const ml=f.forwardRef(({className:e,...t},r)=>m.jsx(Tn,{ref:r,className:G("peer h-4 w-4 shrink-0 rounded-sm border border-gray-200 border-gray-900 ring-offset-white focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-gray-950 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-gray-900 data-[state=checked]:text-gray-50 dark:border-gray-800 dark:border-gray-50 dark:ring-offset-gray-950 dark:focus-visible:ring-gray-300 dark:data-[state=checked]:bg-gray-50 dark:data-[state=checked]:text-gray-900",e),...t,children:m.jsx(ul,{className:G("flex items-center justify-center text-current"),children:m.jsx(gr,{className:"h-4 w-4"})})}));ml.displayName=Tn.displayName;var gl="AlertDialog",[Hh]=Ke(gl,[wi]),$e=wi(),vl=e=>{const{__scopeAlertDialog:t,...r}=e,n=$e(t);return m.jsx(Li,{...n,...r,modal:!0})};vl.displayName=gl;var Gh="AlertDialogTrigger",yl=f.forwardRef((e,t)=>{const{__scopeAlertDialog:r,...n}=e,o=$e(r);return m.jsx($i,{...o,...n,ref:t})});yl.displayName=Gh;var Uh="AlertDialogPortal",bl=e=>{const{__scopeAlertDialog:t,...r}=e,n=$e(t);return m.jsx(zi,{...n,...r})};bl.displayName=Uh;var Yh="AlertDialogOverlay",xl=f.forwardRef((e,t)=>{const{__scopeAlertDialog:r,...n}=e,o=$e(r);return m.jsx(hn,{...o,...n,ref:t})});xl.displayName=Yh;var yt="AlertDialogContent",[Kh,Xh]=Hh(yt),qh=ic("AlertDialogContent"),wl=f.forwardRef((e,t)=>{const{__scopeAlertDialog:r,children:n,...o}=e,s=$e(r),i=f.useRef(null),a=ee(t,i),c=f.useRef(null);return m.jsx(vf,{contentName:yt,titleName:Cl,docsSlug:"alert-dialog",children:m.jsx(Kh,{scope:r,cancelRef:c,children:m.jsxs(mn,{role:"alertdialog",...s,...o,ref:a,onOpenAutoFocus:Q(o.onOpenAutoFocus,l=>{var u;l.preventDefault(),(u=c.current)==null||u.focus({preventScroll:!0})}),onPointerDownOutside:l=>l.preventDefault(),onInteractOutside:l=>l.preventDefault(),children:[m.jsx(qh,{children:n}),m.jsx(Qh,{contentRef:i})]})})})});wl.displayName=yt;var Cl="AlertDialogTitle",Sl=f.forwardRef((e,t)=>{const{__scopeAlertDialog:r,...n}=e,o=$e(r);return m.jsx(gn,{...o,...n,ref:t})});Sl.displayName=Cl;var El="AlertDialogDescription",Rl=f.forwardRef((e,t)=>{const{__scopeAlertDialog:r,...n}=e,o=$e(r);return m.jsx(vn,{...o,...n,ref:t})});Rl.displayName=El;var Zh="AlertDialogAction",Al=f.forwardRef((e,t)=>{const{__scopeAlertDialog:r,...n}=e,o=$e(r);return m.jsx(mr,{...o,...n,ref:t})});Al.displayName=Zh;var Nl="AlertDialogCancel",Pl=f.forwardRef((e,t)=>{const{__scopeAlertDialog:r,...n}=e,{cancelRef:o}=Xh(Nl,r),s=$e(r),i=ee(t,o);return m.jsx(mr,{...s,...n,ref:i})});Pl.displayName=Nl;var Qh=({contentRef:e})=>{const t=`\`${yt}\` requires a description for the component to be accessible for screen reader users.
113
+ */const Of=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],_f=Et("x",Of),jf=Li,Lf=$i,Vi=zi,$f=mr,yn=f.forwardRef(({className:e,...t},r)=>m.jsx(hn,{ref:r,className:G("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}));yn.displayName=hn.displayName;const Wi=f.forwardRef(({className:e,children:t,...r},n)=>m.jsxs(Vi,{children:[m.jsx(yn,{}),m.jsxs(mn,{ref:n,className:G("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-white 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),...r,children:[t,m.jsxs(mr,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-white transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-gray-950 focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-gray-100 data-[state=open]:text-gray-500 cursor-pointer",children:[m.jsx(_f,{className:"h-4 w-4"}),m.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));Wi.displayName=mn.displayName;const Hi=({className:e,...t})=>m.jsx("div",{className:G("flex flex-col space-y-1.5 text-center sm:text-left",e),...t});Hi.displayName="DialogHeader";const Gi=({className:e,...t})=>m.jsx("div",{className:G("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...t});Gi.displayName="DialogFooter";const Ui=f.forwardRef(({className:e,...t},r)=>m.jsx(gn,{ref:r,className:G("text-lg font-semibold leading-none tracking-tight",e),...t}));Ui.displayName=gn.displayName;const Yi=f.forwardRef(({className:e,...t},r)=>m.jsx(vn,{ref:r,className:G("text-sm text-gray-500",e),...t}));Yi.displayName=vn.displayName;function Vo(e,[t,r]){return Math.min(r,Math.max(t,e))}const zf=["top","right","bottom","left"],Ue=Math.min,ge=Math.max,tr=Math.round,Ut=Math.floor,ke=e=>({x:e,y:e}),Ff={left:"right",right:"left",bottom:"top",top:"bottom"},Bf={start:"end",end:"start"};function Vr(e,t,r){return ge(e,Ue(t,r))}function je(e,t){return typeof e=="function"?e(t):e}function Le(e){return e.split("-")[0]}function Rt(e){return e.split("-")[1]}function bn(e){return e==="x"?"y":"x"}function xn(e){return e==="y"?"height":"width"}const Vf=new Set(["top","bottom"]);function Te(e){return Vf.has(Le(e))?"y":"x"}function wn(e){return bn(Te(e))}function Wf(e,t,r){r===void 0&&(r=!1);const n=Rt(e),o=wn(e),s=xn(o);let i=o==="x"?n===(r?"end":"start")?"right":"left":n==="start"?"bottom":"top";return t.reference[s]>t.floating[s]&&(i=rr(i)),[i,rr(i)]}function Hf(e){const t=rr(e);return[Wr(e),t,Wr(t)]}function Wr(e){return e.replace(/start|end/g,t=>Bf[t])}const Wo=["left","right"],Ho=["right","left"],Gf=["top","bottom"],Uf=["bottom","top"];function Yf(e,t,r){switch(e){case"top":case"bottom":return r?t?Ho:Wo:t?Wo:Ho;case"left":case"right":return t?Gf:Uf;default:return[]}}function Kf(e,t,r,n){const o=Rt(e);let s=Yf(Le(e),r==="start",n);return o&&(s=s.map(i=>i+"-"+o),t&&(s=s.concat(s.map(Wr)))),s}function rr(e){return e.replace(/left|right|bottom|top/g,t=>Ff[t])}function Xf(e){return{top:0,right:0,bottom:0,left:0,...e}}function Ki(e){return typeof e!="number"?Xf(e):{top:e,right:e,bottom:e,left:e}}function nr(e){const{x:t,y:r,width:n,height:o}=e;return{width:n,height:o,top:r,left:t,right:t+n,bottom:r+o,x:t,y:r}}function Go(e,t,r){let{reference:n,floating:o}=e;const s=Te(t),i=wn(t),a=xn(i),c=Le(t),l=s==="y",u=n.x+n.width/2-o.width/2,d=n.y+n.height/2-o.height/2,p=n[a]/2-o[a]/2;let g;switch(c){case"top":g={x:u,y:n.y-o.height};break;case"bottom":g={x:u,y:n.y+n.height};break;case"right":g={x:n.x+n.width,y:d};break;case"left":g={x:n.x-o.width,y:d};break;default:g={x:n.x,y:n.y}}switch(Rt(t)){case"start":g[i]-=p*(r&&l?-1:1);break;case"end":g[i]+=p*(r&&l?-1:1);break}return g}const qf=async(e,t,r)=>{const{placement:n="bottom",strategy:o="absolute",middleware:s=[],platform:i}=r,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:u,y:d}=Go(l,n,c),p=n,g={},v=0;for(let h=0;h<a.length;h++){const{name:b,fn:y}=a[h],{x,y:w,data:C,reset:S}=await y({x:u,y:d,initialPlacement:n,placement:p,strategy:o,middlewareData:g,rects:l,platform:i,elements:{reference:e,floating:t}});u=x??u,d=w??d,g={...g,[b]:{...g[b],...C}},S&&v<=50&&(v++,typeof S=="object"&&(S.placement&&(p=S.placement),S.rects&&(l=S.rects===!0?await i.getElementRects({reference:e,floating:t,strategy:o}):S.rects),{x:u,y:d}=Go(l,p,c)),h=-1)}return{x:u,y:d,placement:p,strategy:o,middlewareData:g}};async function Mt(e,t){var r;t===void 0&&(t={});const{x:n,y:o,platform:s,rects:i,elements:a,strategy:c}=e,{boundary:l="clippingAncestors",rootBoundary:u="viewport",elementContext:d="floating",altBoundary:p=!1,padding:g=0}=je(t,e),v=Ki(g),b=a[p?d==="floating"?"reference":"floating":d],y=nr(await s.getClippingRect({element:(r=await(s.isElement==null?void 0:s.isElement(b)))==null||r?b:b.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(a.floating)),boundary:l,rootBoundary:u,strategy:c})),x=d==="floating"?{x:n,y:o,width:i.floating.width,height:i.floating.height}:i.reference,w=await(s.getOffsetParent==null?void 0:s.getOffsetParent(a.floating)),C=await(s.isElement==null?void 0:s.isElement(w))?await(s.getScale==null?void 0:s.getScale(w))||{x:1,y:1}:{x:1,y:1},S=nr(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:x,offsetParent:w,strategy:c}):x);return{top:(y.top-S.top+v.top)/C.y,bottom:(S.bottom-y.bottom+v.bottom)/C.y,left:(y.left-S.left+v.left)/C.x,right:(S.right-y.right+v.right)/C.x}}const Zf=e=>({name:"arrow",options:e,async fn(t){const{x:r,y:n,placement:o,rects:s,platform:i,elements:a,middlewareData:c}=t,{element:l,padding:u=0}=je(e,t)||{};if(l==null)return{};const d=Ki(u),p={x:r,y:n},g=wn(o),v=xn(g),h=await i.getDimensions(l),b=g==="y",y=b?"top":"left",x=b?"bottom":"right",w=b?"clientHeight":"clientWidth",C=s.reference[v]+s.reference[g]-p[g]-s.floating[v],S=p[g]-s.reference[g],A=await(i.getOffsetParent==null?void 0:i.getOffsetParent(l));let R=A?A[w]:0;(!R||!await(i.isElement==null?void 0:i.isElement(A)))&&(R=a.floating[w]||s.floating[v]);const O=C/2-S/2,$=R/2-h[v]/2-1,L=Ue(d[y],$),k=Ue(d[x],$),P=L,_=R-h[v]-k,I=R/2-h[v]/2+O,D=Vr(P,I,_),N=!c.arrow&&Rt(o)!=null&&I!==D&&s.reference[v]/2-(I<P?L:k)-h[v]/2<0,M=N?I<P?I-P:I-_:0;return{[g]:p[g]+M,data:{[g]:D,centerOffset:I-D-M,...N&&{alignmentOffset:M}},reset:N}}}),Qf=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var r,n;const{placement:o,middlewareData:s,rects:i,initialPlacement:a,platform:c,elements:l}=t,{mainAxis:u=!0,crossAxis:d=!0,fallbackPlacements:p,fallbackStrategy:g="bestFit",fallbackAxisSideDirection:v="none",flipAlignment:h=!0,...b}=je(e,t);if((r=s.arrow)!=null&&r.alignmentOffset)return{};const y=Le(o),x=Te(a),w=Le(a)===a,C=await(c.isRTL==null?void 0:c.isRTL(l.floating)),S=p||(w||!h?[rr(a)]:Hf(a)),A=v!=="none";!p&&A&&S.push(...Kf(a,h,v,C));const R=[a,...S],O=await Mt(t,b),$=[];let L=((n=s.flip)==null?void 0:n.overflows)||[];if(u&&$.push(O[y]),d){const I=Wf(o,i,C);$.push(O[I[0]],O[I[1]])}if(L=[...L,{placement:o,overflows:$}],!$.every(I=>I<=0)){var k,P;const I=(((k=s.flip)==null?void 0:k.index)||0)+1,D=R[I];if(D&&(!(d==="alignment"?x!==Te(D):!1)||L.every(T=>Te(T.placement)===x?T.overflows[0]>0:!0)))return{data:{index:I,overflows:L},reset:{placement:D}};let N=(P=L.filter(M=>M.overflows[0]<=0).sort((M,T)=>M.overflows[1]-T.overflows[1])[0])==null?void 0:P.placement;if(!N)switch(g){case"bestFit":{var _;const M=(_=L.filter(T=>{if(A){const j=Te(T.placement);return j===x||j==="y"}return!0}).map(T=>[T.placement,T.overflows.filter(j=>j>0).reduce((j,U)=>j+U,0)]).sort((T,j)=>T[1]-j[1])[0])==null?void 0:_[0];M&&(N=M);break}case"initialPlacement":N=a;break}if(o!==N)return{reset:{placement:N}}}return{}}}};function Uo(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Yo(e){return zf.some(t=>e[t]>=0)}const Jf=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:r}=t,{strategy:n="referenceHidden",...o}=je(e,t);switch(n){case"referenceHidden":{const s=await Mt(t,{...o,elementContext:"reference"}),i=Uo(s,r.reference);return{data:{referenceHiddenOffsets:i,referenceHidden:Yo(i)}}}case"escaped":{const s=await Mt(t,{...o,altBoundary:!0}),i=Uo(s,r.floating);return{data:{escapedOffsets:i,escaped:Yo(i)}}}default:return{}}}}},Xi=new Set(["left","top"]);async function ep(e,t){const{placement:r,platform:n,elements:o}=e,s=await(n.isRTL==null?void 0:n.isRTL(o.floating)),i=Le(r),a=Rt(r),c=Te(r)==="y",l=Xi.has(i)?-1:1,u=s&&c?-1:1,d=je(t,e);let{mainAxis:p,crossAxis:g,alignmentAxis:v}=typeof d=="number"?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return a&&typeof v=="number"&&(g=a==="end"?v*-1:v),c?{x:g*u,y:p*l}:{x:p*l,y:g*u}}const tp=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var r,n;const{x:o,y:s,placement:i,middlewareData:a}=t,c=await ep(t,e);return i===((r=a.offset)==null?void 0:r.placement)&&(n=a.arrow)!=null&&n.alignmentOffset?{}:{x:o+c.x,y:s+c.y,data:{...c,placement:i}}}}},rp=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:r,y:n,placement:o}=t,{mainAxis:s=!0,crossAxis:i=!1,limiter:a={fn:b=>{let{x:y,y:x}=b;return{x:y,y:x}}},...c}=je(e,t),l={x:r,y:n},u=await Mt(t,c),d=Te(Le(o)),p=bn(d);let g=l[p],v=l[d];if(s){const b=p==="y"?"top":"left",y=p==="y"?"bottom":"right",x=g+u[b],w=g-u[y];g=Vr(x,g,w)}if(i){const b=d==="y"?"top":"left",y=d==="y"?"bottom":"right",x=v+u[b],w=v-u[y];v=Vr(x,v,w)}const h=a.fn({...t,[p]:g,[d]:v});return{...h,data:{x:h.x-r,y:h.y-n,enabled:{[p]:s,[d]:i}}}}}},np=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:r,y:n,placement:o,rects:s,middlewareData:i}=t,{offset:a=0,mainAxis:c=!0,crossAxis:l=!0}=je(e,t),u={x:r,y:n},d=Te(o),p=bn(d);let g=u[p],v=u[d];const h=je(a,t),b=typeof h=="number"?{mainAxis:h,crossAxis:0}:{mainAxis:0,crossAxis:0,...h};if(c){const w=p==="y"?"height":"width",C=s.reference[p]-s.floating[w]+b.mainAxis,S=s.reference[p]+s.reference[w]-b.mainAxis;g<C?g=C:g>S&&(g=S)}if(l){var y,x;const w=p==="y"?"width":"height",C=Xi.has(Le(o)),S=s.reference[d]-s.floating[w]+(C&&((y=i.offset)==null?void 0:y[d])||0)+(C?0:b.crossAxis),A=s.reference[d]+s.reference[w]+(C?0:((x=i.offset)==null?void 0:x[d])||0)-(C?b.crossAxis:0);v<S?v=S:v>A&&(v=A)}return{[p]:g,[d]:v}}}},op=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var r,n;const{placement:o,rects:s,platform:i,elements:a}=t,{apply:c=()=>{},...l}=je(e,t),u=await Mt(t,l),d=Le(o),p=Rt(o),g=Te(o)==="y",{width:v,height:h}=s.floating;let b,y;d==="top"||d==="bottom"?(b=d,y=p===(await(i.isRTL==null?void 0:i.isRTL(a.floating))?"start":"end")?"left":"right"):(y=d,b=p==="end"?"top":"bottom");const x=h-u.top-u.bottom,w=v-u.left-u.right,C=Ue(h-u[b],x),S=Ue(v-u[y],w),A=!t.middlewareData.shift;let R=C,O=S;if((r=t.middlewareData.shift)!=null&&r.enabled.x&&(O=w),(n=t.middlewareData.shift)!=null&&n.enabled.y&&(R=x),A&&!p){const L=ge(u.left,0),k=ge(u.right,0),P=ge(u.top,0),_=ge(u.bottom,0);g?O=v-2*(L!==0||k!==0?L+k:ge(u.left,u.right)):R=h-2*(P!==0||_!==0?P+_:ge(u.top,u.bottom))}await c({...t,availableWidth:O,availableHeight:R});const $=await i.getDimensions(a.floating);return v!==$.width||h!==$.height?{reset:{rects:!0}}:{}}}};function vr(){return typeof window<"u"}function At(e){return qi(e)?(e.nodeName||"").toLowerCase():"#document"}function ve(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Ie(e){var t;return(t=(qi(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function qi(e){return vr()?e instanceof Node||e instanceof ve(e).Node:!1}function Se(e){return vr()?e instanceof Element||e instanceof ve(e).Element:!1}function De(e){return vr()?e instanceof HTMLElement||e instanceof ve(e).HTMLElement:!1}function Ko(e){return!vr()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof ve(e).ShadowRoot}const sp=new Set(["inline","contents"]);function _t(e){const{overflow:t,overflowX:r,overflowY:n,display:o}=Ee(e);return/auto|scroll|overlay|hidden|clip/.test(t+n+r)&&!sp.has(o)}const ip=new Set(["table","td","th"]);function ap(e){return ip.has(At(e))}const lp=[":popover-open",":modal"];function yr(e){return lp.some(t=>{try{return e.matches(t)}catch{return!1}})}const cp=["transform","translate","scale","rotate","perspective"],dp=["transform","translate","scale","rotate","perspective","filter"],up=["paint","layout","strict","content"];function Cn(e){const t=Sn(),r=Se(e)?Ee(e):e;return cp.some(n=>r[n]?r[n]!=="none":!1)||(r.containerType?r.containerType!=="normal":!1)||!t&&(r.backdropFilter?r.backdropFilter!=="none":!1)||!t&&(r.filter?r.filter!=="none":!1)||dp.some(n=>(r.willChange||"").includes(n))||up.some(n=>(r.contain||"").includes(n))}function fp(e){let t=Ye(e);for(;De(t)&&!xt(t);){if(Cn(t))return t;if(yr(t))return null;t=Ye(t)}return null}function Sn(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const pp=new Set(["html","body","#document"]);function xt(e){return pp.has(At(e))}function Ee(e){return ve(e).getComputedStyle(e)}function br(e){return Se(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Ye(e){if(At(e)==="html")return e;const t=e.assignedSlot||e.parentNode||Ko(e)&&e.host||Ie(e);return Ko(t)?t.host:t}function Zi(e){const t=Ye(e);return xt(t)?e.ownerDocument?e.ownerDocument.body:e.body:De(t)&&_t(t)?t:Zi(t)}function It(e,t,r){var n;t===void 0&&(t=[]),r===void 0&&(r=!0);const o=Zi(e),s=o===((n=e.ownerDocument)==null?void 0:n.body),i=ve(o);if(s){const a=Hr(i);return t.concat(i,i.visualViewport||[],_t(o)?o:[],a&&r?It(a):[])}return t.concat(o,It(o,[],r))}function Hr(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Qi(e){const t=Ee(e);let r=parseFloat(t.width)||0,n=parseFloat(t.height)||0;const o=De(e),s=o?e.offsetWidth:r,i=o?e.offsetHeight:n,a=tr(r)!==s||tr(n)!==i;return a&&(r=s,n=i),{width:r,height:n,$:a}}function En(e){return Se(e)?e:e.contextElement}function vt(e){const t=En(e);if(!De(t))return ke(1);const r=t.getBoundingClientRect(),{width:n,height:o,$:s}=Qi(t);let i=(s?tr(r.width):r.width)/n,a=(s?tr(r.height):r.height)/o;return(!i||!Number.isFinite(i))&&(i=1),(!a||!Number.isFinite(a))&&(a=1),{x:i,y:a}}const hp=ke(0);function Ji(e){const t=ve(e);return!Sn()||!t.visualViewport?hp:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function mp(e,t,r){return t===void 0&&(t=!1),!r||t&&r!==ve(e)?!1:t}function nt(e,t,r,n){t===void 0&&(t=!1),r===void 0&&(r=!1);const o=e.getBoundingClientRect(),s=En(e);let i=ke(1);t&&(n?Se(n)&&(i=vt(n)):i=vt(e));const a=mp(s,r,n)?Ji(s):ke(0);let c=(o.left+a.x)/i.x,l=(o.top+a.y)/i.y,u=o.width/i.x,d=o.height/i.y;if(s){const p=ve(s),g=n&&Se(n)?ve(n):n;let v=p,h=Hr(v);for(;h&&n&&g!==v;){const b=vt(h),y=h.getBoundingClientRect(),x=Ee(h),w=y.left+(h.clientLeft+parseFloat(x.paddingLeft))*b.x,C=y.top+(h.clientTop+parseFloat(x.paddingTop))*b.y;c*=b.x,l*=b.y,u*=b.x,d*=b.y,c+=w,l+=C,v=ve(h),h=Hr(v)}}return nr({width:u,height:d,x:c,y:l})}function xr(e,t){const r=br(e).scrollLeft;return t?t.left+r:nt(Ie(e)).left+r}function ea(e,t){const r=e.getBoundingClientRect(),n=r.left+t.scrollLeft-xr(e,r),o=r.top+t.scrollTop;return{x:n,y:o}}function gp(e){let{elements:t,rect:r,offsetParent:n,strategy:o}=e;const s=o==="fixed",i=Ie(n),a=t?yr(t.floating):!1;if(n===i||a&&s)return r;let c={scrollLeft:0,scrollTop:0},l=ke(1);const u=ke(0),d=De(n);if((d||!d&&!s)&&((At(n)!=="body"||_t(i))&&(c=br(n)),De(n))){const g=nt(n);l=vt(n),u.x=g.x+n.clientLeft,u.y=g.y+n.clientTop}const p=i&&!d&&!s?ea(i,c):ke(0);return{width:r.width*l.x,height:r.height*l.y,x:r.x*l.x-c.scrollLeft*l.x+u.x+p.x,y:r.y*l.y-c.scrollTop*l.y+u.y+p.y}}function vp(e){return Array.from(e.getClientRects())}function yp(e){const t=Ie(e),r=br(e),n=e.ownerDocument.body,o=ge(t.scrollWidth,t.clientWidth,n.scrollWidth,n.clientWidth),s=ge(t.scrollHeight,t.clientHeight,n.scrollHeight,n.clientHeight);let i=-r.scrollLeft+xr(e);const a=-r.scrollTop;return Ee(n).direction==="rtl"&&(i+=ge(t.clientWidth,n.clientWidth)-o),{width:o,height:s,x:i,y:a}}const Xo=25;function bp(e,t){const r=ve(e),n=Ie(e),o=r.visualViewport;let s=n.clientWidth,i=n.clientHeight,a=0,c=0;if(o){s=o.width,i=o.height;const u=Sn();(!u||u&&t==="fixed")&&(a=o.offsetLeft,c=o.offsetTop)}const l=xr(n);if(l<=0){const u=n.ownerDocument,d=u.body,p=getComputedStyle(d),g=u.compatMode==="CSS1Compat"&&parseFloat(p.marginLeft)+parseFloat(p.marginRight)||0,v=Math.abs(n.clientWidth-d.clientWidth-g);v<=Xo&&(s-=v)}else l<=Xo&&(s+=l);return{width:s,height:i,x:a,y:c}}const xp=new Set(["absolute","fixed"]);function wp(e,t){const r=nt(e,!0,t==="fixed"),n=r.top+e.clientTop,o=r.left+e.clientLeft,s=De(e)?vt(e):ke(1),i=e.clientWidth*s.x,a=e.clientHeight*s.y,c=o*s.x,l=n*s.y;return{width:i,height:a,x:c,y:l}}function qo(e,t,r){let n;if(t==="viewport")n=bp(e,r);else if(t==="document")n=yp(Ie(e));else if(Se(t))n=wp(t,r);else{const o=Ji(e);n={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return nr(n)}function ta(e,t){const r=Ye(e);return r===t||!Se(r)||xt(r)?!1:Ee(r).position==="fixed"||ta(r,t)}function Cp(e,t){const r=t.get(e);if(r)return r;let n=It(e,[],!1).filter(a=>Se(a)&&At(a)!=="body"),o=null;const s=Ee(e).position==="fixed";let i=s?Ye(e):e;for(;Se(i)&&!xt(i);){const a=Ee(i),c=Cn(i);!c&&a.position==="fixed"&&(o=null),(s?!c&&!o:!c&&a.position==="static"&&!!o&&xp.has(o.position)||_t(i)&&!c&&ta(e,i))?n=n.filter(u=>u!==i):o=a,i=Ye(i)}return t.set(e,n),n}function Sp(e){let{element:t,boundary:r,rootBoundary:n,strategy:o}=e;const i=[...r==="clippingAncestors"?yr(t)?[]:Cp(t,this._c):[].concat(r),n],a=i[0],c=i.reduce((l,u)=>{const d=qo(t,u,o);return l.top=ge(d.top,l.top),l.right=Ue(d.right,l.right),l.bottom=Ue(d.bottom,l.bottom),l.left=ge(d.left,l.left),l},qo(t,a,o));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function Ep(e){const{width:t,height:r}=Qi(e);return{width:t,height:r}}function Rp(e,t,r){const n=De(t),o=Ie(t),s=r==="fixed",i=nt(e,!0,s,t);let a={scrollLeft:0,scrollTop:0};const c=ke(0);function l(){c.x=xr(o)}if(n||!n&&!s)if((At(t)!=="body"||_t(o))&&(a=br(t)),n){const g=nt(t,!0,s,t);c.x=g.x+t.clientLeft,c.y=g.y+t.clientTop}else o&&l();s&&!n&&o&&l();const u=o&&!n&&!s?ea(o,a):ke(0),d=i.left+a.scrollLeft-c.x-u.x,p=i.top+a.scrollTop-c.y-u.y;return{x:d,y:p,width:i.width,height:i.height}}function _r(e){return Ee(e).position==="static"}function Zo(e,t){if(!De(e)||Ee(e).position==="fixed")return null;if(t)return t(e);let r=e.offsetParent;return Ie(e)===r&&(r=r.ownerDocument.body),r}function ra(e,t){const r=ve(e);if(yr(e))return r;if(!De(e)){let o=Ye(e);for(;o&&!xt(o);){if(Se(o)&&!_r(o))return o;o=Ye(o)}return r}let n=Zo(e,t);for(;n&&ap(n)&&_r(n);)n=Zo(n,t);return n&&xt(n)&&_r(n)&&!Cn(n)?r:n||fp(e)||r}const Ap=async function(e){const t=this.getOffsetParent||ra,r=this.getDimensions,n=await r(e.floating);return{reference:Rp(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:n.width,height:n.height}}};function Np(e){return Ee(e).direction==="rtl"}const Pp={convertOffsetParentRelativeRectToViewportRelativeRect:gp,getDocumentElement:Ie,getClippingRect:Sp,getOffsetParent:ra,getElementRects:Ap,getClientRects:vp,getDimensions:Ep,getScale:vt,isElement:Se,isRTL:Np};function na(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function Tp(e,t){let r=null,n;const o=Ie(e);function s(){var a;clearTimeout(n),(a=r)==null||a.disconnect(),r=null}function i(a,c){a===void 0&&(a=!1),c===void 0&&(c=1),s();const l=e.getBoundingClientRect(),{left:u,top:d,width:p,height:g}=l;if(a||t(),!p||!g)return;const v=Ut(d),h=Ut(o.clientWidth-(u+p)),b=Ut(o.clientHeight-(d+g)),y=Ut(u),w={rootMargin:-v+"px "+-h+"px "+-b+"px "+-y+"px",threshold:ge(0,Ue(1,c))||1};let C=!0;function S(A){const R=A[0].intersectionRatio;if(R!==c){if(!C)return i();R?i(!1,R):n=setTimeout(()=>{i(!1,1e-7)},1e3)}R===1&&!na(l,e.getBoundingClientRect())&&i(),C=!1}try{r=new IntersectionObserver(S,{...w,root:o.ownerDocument})}catch{r=new IntersectionObserver(S,w)}r.observe(e)}return i(!0),s}function kp(e,t,r,n){n===void 0&&(n={});const{ancestorScroll:o=!0,ancestorResize:s=!0,elementResize:i=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:c=!1}=n,l=En(e),u=o||s?[...l?It(l):[],...It(t)]:[];u.forEach(y=>{o&&y.addEventListener("scroll",r,{passive:!0}),s&&y.addEventListener("resize",r)});const d=l&&a?Tp(l,r):null;let p=-1,g=null;i&&(g=new ResizeObserver(y=>{let[x]=y;x&&x.target===l&&g&&(g.unobserve(t),cancelAnimationFrame(p),p=requestAnimationFrame(()=>{var w;(w=g)==null||w.observe(t)})),r()}),l&&!c&&g.observe(l),g.observe(t));let v,h=c?nt(e):null;c&&b();function b(){const y=nt(e);h&&!na(h,y)&&r(),h=y,v=requestAnimationFrame(b)}return r(),()=>{var y;u.forEach(x=>{o&&x.removeEventListener("scroll",r),s&&x.removeEventListener("resize",r)}),d==null||d(),(y=g)==null||y.disconnect(),g=null,c&&cancelAnimationFrame(v)}}const Dp=tp,Mp=rp,Ip=Qf,Op=op,_p=Jf,Qo=Zf,jp=np,Lp=(e,t,r)=>{const n=new Map,o={platform:Pp,...r},s={...o.platform,_c:n};return qf(e,t,{...o,platform:s})};var $p=typeof document<"u",zp=function(){},Zt=$p?E.useLayoutEffect:zp;function or(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 r,n,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(r=e.length,r!==t.length)return!1;for(n=r;n--!==0;)if(!or(e[n],t[n]))return!1;return!0}if(o=Object.keys(e),r=o.length,r!==Object.keys(t).length)return!1;for(n=r;n--!==0;)if(!{}.hasOwnProperty.call(t,o[n]))return!1;for(n=r;n--!==0;){const s=o[n];if(!(s==="_owner"&&e.$$typeof)&&!or(e[s],t[s]))return!1}return!0}return e!==e&&t!==t}function oa(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Jo(e,t){const r=oa(e);return Math.round(t*r)/r}function jr(e){const t=f.useRef(e);return Zt(()=>{t.current=e}),t}function Fp(e){e===void 0&&(e={});const{placement:t="bottom",strategy:r="absolute",middleware:n=[],platform:o,elements:{reference:s,floating:i}={},transform:a=!0,whileElementsMounted:c,open:l}=e,[u,d]=f.useState({x:0,y:0,strategy:r,placement:t,middlewareData:{},isPositioned:!1}),[p,g]=f.useState(n);or(p,n)||g(n);const[v,h]=f.useState(null),[b,y]=f.useState(null),x=f.useCallback(T=>{T!==A.current&&(A.current=T,h(T))},[]),w=f.useCallback(T=>{T!==R.current&&(R.current=T,y(T))},[]),C=s||v,S=i||b,A=f.useRef(null),R=f.useRef(null),O=f.useRef(u),$=c!=null,L=jr(c),k=jr(o),P=jr(l),_=f.useCallback(()=>{if(!A.current||!R.current)return;const T={placement:t,strategy:r,middleware:p};k.current&&(T.platform=k.current),Lp(A.current,R.current,T).then(j=>{const U={...j,isPositioned:P.current!==!1};I.current&&!or(O.current,U)&&(O.current=U,ar.flushSync(()=>{d(U)}))})},[p,t,r,k,P]);Zt(()=>{l===!1&&O.current.isPositioned&&(O.current.isPositioned=!1,d(T=>({...T,isPositioned:!1})))},[l]);const I=f.useRef(!1);Zt(()=>(I.current=!0,()=>{I.current=!1}),[]),Zt(()=>{if(C&&(A.current=C),S&&(R.current=S),C&&S){if(L.current)return L.current(C,S,_);_()}},[C,S,_,L,$]);const D=f.useMemo(()=>({reference:A,floating:R,setReference:x,setFloating:w}),[x,w]),N=f.useMemo(()=>({reference:C,floating:S}),[C,S]),M=f.useMemo(()=>{const T={position:r,left:0,top:0};if(!N.floating)return T;const j=Jo(N.floating,u.x),U=Jo(N.floating,u.y);return a?{...T,transform:"translate("+j+"px, "+U+"px)",...oa(N.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:j,top:U}},[r,a,N.floating,u.x,u.y]);return f.useMemo(()=>({...u,update:_,refs:D,elements:N,floatingStyles:M}),[u,_,D,N,M])}const Bp=e=>{function t(r){return{}.hasOwnProperty.call(r,"current")}return{name:"arrow",options:e,fn(r){const{element:n,padding:o}=typeof e=="function"?e(r):e;return n&&t(n)?n.current!=null?Qo({element:n.current,padding:o}).fn(r):{}:n?Qo({element:n,padding:o}).fn(r):{}}}},Vp=(e,t)=>({...Dp(e),options:[e,t]}),Wp=(e,t)=>({...Mp(e),options:[e,t]}),Hp=(e,t)=>({...jp(e),options:[e,t]}),Gp=(e,t)=>({...Ip(e),options:[e,t]}),Up=(e,t)=>({...Op(e),options:[e,t]}),Yp=(e,t)=>({..._p(e),options:[e,t]}),Kp=(e,t)=>({...Bp(e),options:[e,t]});var Xp="Arrow",sa=f.forwardRef((e,t)=>{const{children:r,width:n=10,height:o=5,...s}=e;return m.jsx(K.svg,{...s,ref:t,width:n,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?r:m.jsx("polygon",{points:"0,0 30,0 15,10"})})});sa.displayName=Xp;var qp=sa;function ia(e){const[t,r]=f.useState(void 0);return le(()=>{if(e){r({width:e.offsetWidth,height:e.offsetHeight});const n=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;r({width:i,height:a})});return n.observe(e,{box:"border-box"}),()=>n.unobserve(e)}else r(void 0)},[e]),t}var Rn="Popper",[aa,la]=Ke(Rn),[Zp,ca]=aa(Rn),da=e=>{const{__scopePopper:t,children:r}=e,[n,o]=f.useState(null);return m.jsx(Zp,{scope:t,anchor:n,onAnchorChange:o,children:r})};da.displayName=Rn;var ua="PopperAnchor",fa=f.forwardRef((e,t)=>{const{__scopePopper:r,virtualRef:n,...o}=e,s=ca(ua,r),i=f.useRef(null),a=ee(t,i),c=f.useRef(null);return f.useEffect(()=>{const l=c.current;c.current=(n==null?void 0:n.current)||i.current,l!==c.current&&s.onAnchorChange(c.current)}),n?null:m.jsx(K.div,{...o,ref:a})});fa.displayName=ua;var An="PopperContent",[Qp,Jp]=aa(An),pa=f.forwardRef((e,t)=>{var z,F,re,Z,q,Y;const{__scopePopper:r,side:n="bottom",sideOffset:o=0,align:s="center",alignOffset:i=0,arrowPadding:a=0,avoidCollisions:c=!0,collisionBoundary:l=[],collisionPadding:u=0,sticky:d="partial",hideWhenDetached:p=!1,updatePositionStrategy:g="optimized",onPlaced:v,...h}=e,b=ca(An,r),[y,x]=f.useState(null),w=ee(t,de=>x(de)),[C,S]=f.useState(null),A=ia(C),R=(A==null?void 0:A.width)??0,O=(A==null?void 0:A.height)??0,$=n+(s!=="center"?"-"+s:""),L=typeof u=="number"?u:{top:0,right:0,bottom:0,left:0,...u},k=Array.isArray(l)?l:[l],P=k.length>0,_={padding:L,boundary:k.filter(th),altBoundary:P},{refs:I,floatingStyles:D,placement:N,isPositioned:M,middlewareData:T}=Fp({strategy:"fixed",placement:$,whileElementsMounted:(...de)=>kp(...de,{animationFrame:g==="always"}),elements:{reference:b.anchor},middleware:[Vp({mainAxis:o+O,alignmentAxis:i}),c&&Wp({mainAxis:!0,crossAxis:!1,limiter:d==="partial"?Hp():void 0,..._}),c&&Gp({..._}),Up({..._,apply:({elements:de,rects:ue,availableWidth:Ze,availableHeight:ze})=>{const{width:be,height:jt}=ue.reference,fe=de.floating.style;fe.setProperty("--radix-popper-available-width",`${Ze}px`),fe.setProperty("--radix-popper-available-height",`${ze}px`),fe.setProperty("--radix-popper-anchor-width",`${be}px`),fe.setProperty("--radix-popper-anchor-height",`${jt}px`)}}),C&&Kp({element:C,padding:a}),rh({arrowWidth:R,arrowHeight:O}),p&&Yp({strategy:"referenceHidden",..._})]}),[j,U]=ga(N),V=tt(v);le(()=>{M&&(V==null||V())},[M,V]);const se=(z=T.arrow)==null?void 0:z.x,B=(F=T.arrow)==null?void 0:F.y,X=((re=T.arrow)==null?void 0:re.centerOffset)!==0,[J,ne]=f.useState();return le(()=>{y&&ne(window.getComputedStyle(y).zIndex)},[y]),m.jsx("div",{ref:I.setFloating,"data-radix-popper-content-wrapper":"",style:{...D,transform:M?D.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:J,"--radix-popper-transform-origin":[(Z=T.transformOrigin)==null?void 0:Z.x,(q=T.transformOrigin)==null?void 0:q.y].join(" "),...((Y=T.hide)==null?void 0:Y.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:m.jsx(Qp,{scope:r,placedSide:j,onArrowChange:S,arrowX:se,arrowY:B,shouldHideArrow:X,children:m.jsx(K.div,{"data-side":j,"data-align":U,...h,ref:w,style:{...h.style,animation:M?void 0:"none"}})})})});pa.displayName=An;var ha="PopperArrow",eh={top:"bottom",right:"left",bottom:"top",left:"right"},ma=f.forwardRef(function(t,r){const{__scopePopper:n,...o}=t,s=Jp(ha,n),i=eh[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(qp,{...o,ref:r,style:{...o.style,display:"block"}})})});ma.displayName=ha;function th(e){return e!==null}var rh=e=>({name:"transformOrigin",options:e,fn(t){var b,y,x;const{placement:r,rects:n,middlewareData:o}=t,i=((b=o.arrow)==null?void 0:b.centerOffset)!==0,a=i?0:e.arrowWidth,c=i?0:e.arrowHeight,[l,u]=ga(r),d={start:"0%",center:"50%",end:"100%"}[u],p=(((y=o.arrow)==null?void 0:y.x)??0)+a/2,g=(((x=o.arrow)==null?void 0:x.y)??0)+c/2;let v="",h="";return l==="bottom"?(v=i?d:`${p}px`,h=`${-c}px`):l==="top"?(v=i?d:`${p}px`,h=`${n.floating.height+c}px`):l==="right"?(v=`${-c}px`,h=i?d:`${g}px`):l==="left"&&(v=`${n.floating.width+c}px`,h=i?d:`${g}px`),{data:{x:v,y:h}}}});function ga(e){const[t,r="center"]=e.split("-");return[t,r]}var nh=da,oh=fa,sh=pa,ih=ma;function va(e){const t=f.useRef({value:e,previous:e});return f.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}var ya=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"}),ah="VisuallyHidden",lh=f.forwardRef((e,t)=>m.jsx(K.span,{...e,ref:t,style:{...ya,...e.style}}));lh.displayName=ah;var ch=[" ","Enter","ArrowUp","ArrowDown"],dh=[" ","Enter"],ot="Select",[wr,Cr,uh]=$s(ot),[Nt]=Ke(ot,[uh,la]),Sr=la(),[fh,Xe]=Nt(ot),[ph,hh]=Nt(ot),ba=e=>{const{__scopeSelect:t,children:r,open:n,defaultOpen:o,onOpenChange:s,value:i,defaultValue:a,onValueChange:c,dir:l,name:u,autoComplete:d,disabled:p,required:g,form:v}=e,h=Sr(t),[b,y]=f.useState(null),[x,w]=f.useState(null),[C,S]=f.useState(!1),A=Hs(l),[R,O]=et({prop:n,defaultProp:o??!1,onChange:s,caller:ot}),[$,L]=et({prop:i,defaultProp:a,onChange:c,caller:ot}),k=f.useRef(null),P=b?v||!!b.closest("form"):!0,[_,I]=f.useState(new Set),D=Array.from(_).map(N=>N.props.value).join(";");return m.jsx(nh,{...h,children:m.jsxs(fh,{required:g,scope:t,trigger:b,onTriggerChange:y,valueNode:x,onValueNodeChange:w,valueNodeHasChildren:C,onValueNodeHasChildrenChange:S,contentId:He(),value:$,onValueChange:L,open:R,onOpenChange:O,dir:A,triggerPointerDownPosRef:k,disabled:p,children:[m.jsx(wr.Provider,{scope:t,children:m.jsx(ph,{scope:e.__scopeSelect,onNativeOptionAdd:f.useCallback(N=>{I(M=>new Set(M).add(N))},[]),onNativeOptionRemove:f.useCallback(N=>{I(M=>{const T=new Set(M);return T.delete(N),T})},[]),children:r})}),P?m.jsxs(Ha,{"aria-hidden":!0,required:g,tabIndex:-1,name:u,autoComplete:d,value:$,onChange:N=>L(N.target.value),disabled:p,form:v,children:[$===void 0?m.jsx("option",{value:""}):null,Array.from(_)]},D):null]})})};ba.displayName=ot;var xa="SelectTrigger",wa=f.forwardRef((e,t)=>{const{__scopeSelect:r,disabled:n=!1,...o}=e,s=Sr(r),i=Xe(xa,r),a=i.disabled||n,c=ee(t,i.onTriggerChange),l=Cr(r),u=f.useRef("touch"),[d,p,g]=Ua(h=>{const b=l().filter(w=>!w.disabled),y=b.find(w=>w.value===i.value),x=Ya(b,h,y);x!==void 0&&i.onValueChange(x.value)}),v=h=>{a||(i.onOpenChange(!0),g()),h&&(i.triggerPointerDownPosRef.current={x:Math.round(h.pageX),y:Math.round(h.pageY)})};return m.jsx(oh,{asChild:!0,...s,children:m.jsx(K.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":Ga(i.value)?"":void 0,...o,ref:c,onClick:Q(o.onClick,h=>{h.currentTarget.focus(),u.current!=="mouse"&&v(h)}),onPointerDown:Q(o.onPointerDown,h=>{u.current=h.pointerType;const b=h.target;b.hasPointerCapture(h.pointerId)&&b.releasePointerCapture(h.pointerId),h.button===0&&h.ctrlKey===!1&&h.pointerType==="mouse"&&(v(h),h.preventDefault())}),onKeyDown:Q(o.onKeyDown,h=>{const b=d.current!=="";!(h.ctrlKey||h.altKey||h.metaKey)&&h.key.length===1&&p(h.key),!(b&&h.key===" ")&&ch.includes(h.key)&&(v(),h.preventDefault())})})})});wa.displayName=xa;var Ca="SelectValue",Sa=f.forwardRef((e,t)=>{const{__scopeSelect:r,className:n,style:o,children:s,placeholder:i="",...a}=e,c=Xe(Ca,r),{onValueNodeHasChildrenChange:l}=c,u=s!==void 0,d=ee(t,c.onValueNodeChange);return le(()=>{l(u)},[l,u]),m.jsx(K.span,{...a,ref:d,style:{pointerEvents:"none"},children:Ga(c.value)?m.jsx(m.Fragment,{children:i}):s})});Sa.displayName=Ca;var mh="SelectIcon",Ea=f.forwardRef((e,t)=>{const{__scopeSelect:r,children:n,...o}=e;return m.jsx(K.span,{"aria-hidden":!0,...o,ref:t,children:n||"▼"})});Ea.displayName=mh;var gh="SelectPortal",Ra=e=>m.jsx(cn,{asChild:!0,...e});Ra.displayName=gh;var st="SelectContent",Aa=f.forwardRef((e,t)=>{const r=Xe(st,e.__scopeSelect),[n,o]=f.useState();if(le(()=>{o(new DocumentFragment)},[]),!r.open){const s=n;return s?ar.createPortal(m.jsx(Na,{scope:e.__scopeSelect,children:m.jsx(wr.Slot,{scope:e.__scopeSelect,children:m.jsx("div",{children:e.children})})}),s):null}return m.jsx(Pa,{...e,ref:t})});Aa.displayName=st;var Ce=10,[Na,qe]=Nt(st),vh="SelectContentImpl",yh=bt("SelectContent.RemoveScroll"),Pa=f.forwardRef((e,t)=>{const{__scopeSelect:r,position:n="item-aligned",onCloseAutoFocus:o,onEscapeKeyDown:s,onPointerDownOutside:i,side:a,sideOffset:c,align:l,alignOffset:u,arrowPadding:d,collisionBoundary:p,collisionPadding:g,sticky:v,hideWhenDetached:h,avoidCollisions:b,...y}=e,x=Xe(st,r),[w,C]=f.useState(null),[S,A]=f.useState(null),R=ee(t,z=>C(z)),[O,$]=f.useState(null),[L,k]=f.useState(null),P=Cr(r),[_,I]=f.useState(!1),D=f.useRef(!1);f.useEffect(()=>{if(w)return bi(w)},[w]),di();const N=f.useCallback(z=>{const[F,...re]=P().map(Y=>Y.ref.current),[Z]=re.slice(-1),q=document.activeElement;for(const Y of z)if(Y===q||(Y==null||Y.scrollIntoView({block:"nearest"}),Y===F&&S&&(S.scrollTop=0),Y===Z&&S&&(S.scrollTop=S.scrollHeight),Y==null||Y.focus(),document.activeElement!==q))return},[P,S]),M=f.useCallback(()=>N([O,w]),[N,O,w]);f.useEffect(()=>{_&&M()},[_,M]);const{onOpenChange:T,triggerPointerDownPosRef:j}=x;f.useEffect(()=>{if(w){let z={x:0,y:0};const F=Z=>{var q,Y;z={x:Math.abs(Math.round(Z.pageX)-(((q=j.current)==null?void 0:q.x)??0)),y:Math.abs(Math.round(Z.pageY)-(((Y=j.current)==null?void 0:Y.y)??0))}},re=Z=>{z.x<=10&&z.y<=10?Z.preventDefault():w.contains(Z.target)||T(!1),document.removeEventListener("pointermove",F),j.current=null};return j.current!==null&&(document.addEventListener("pointermove",F),document.addEventListener("pointerup",re,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",F),document.removeEventListener("pointerup",re,{capture:!0})}}},[w,T,j]),f.useEffect(()=>{const z=()=>T(!1);return window.addEventListener("blur",z),window.addEventListener("resize",z),()=>{window.removeEventListener("blur",z),window.removeEventListener("resize",z)}},[T]);const[U,V]=Ua(z=>{const F=P().filter(q=>!q.disabled),re=F.find(q=>q.ref.current===document.activeElement),Z=Ya(F,z,re);Z&&setTimeout(()=>Z.ref.current.focus())}),se=f.useCallback((z,F,re)=>{const Z=!D.current&&!re;(x.value!==void 0&&x.value===F||Z)&&($(z),Z&&(D.current=!0))},[x.value]),B=f.useCallback(()=>w==null?void 0:w.focus(),[w]),X=f.useCallback((z,F,re)=>{const Z=!D.current&&!re;(x.value!==void 0&&x.value===F||Z)&&k(z)},[x.value]),J=n==="popper"?Gr:Ta,ne=J===Gr?{side:a,sideOffset:c,align:l,alignOffset:u,arrowPadding:d,collisionBoundary:p,collisionPadding:g,sticky:v,hideWhenDetached:h,avoidCollisions:b}:{};return m.jsx(Na,{scope:r,content:w,viewport:S,onViewportChange:A,itemRefCallback:se,selectedItem:O,onItemLeave:B,itemTextRefCallback:X,focusSelectedItem:M,selectedItemText:L,position:n,isPositioned:_,searchRef:U,children:m.jsx(dn,{as:yh,allowPinchZoom:!0,children:m.jsx(ln,{asChild:!0,trapped:x.open,onMountAutoFocus:z=>{z.preventDefault()},onUnmountAutoFocus:Q(o,z=>{var F;(F=x.trigger)==null||F.focus({preventScroll:!0}),z.preventDefault()}),children:m.jsx(an,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:s,onPointerDownOutside:i,onFocusOutside:z=>z.preventDefault(),onDismiss:()=>x.onOpenChange(!1),children:m.jsx(J,{role:"listbox",id:x.contentId,"data-state":x.open?"open":"closed",dir:x.dir,onContextMenu:z=>z.preventDefault(),...y,...ne,onPlaced:()=>I(!0),ref:R,style:{display:"flex",flexDirection:"column",outline:"none",...y.style},onKeyDown:Q(y.onKeyDown,z=>{const F=z.ctrlKey||z.altKey||z.metaKey;if(z.key==="Tab"&&z.preventDefault(),!F&&z.key.length===1&&V(z.key),["ArrowUp","ArrowDown","Home","End"].includes(z.key)){let Z=P().filter(q=>!q.disabled).map(q=>q.ref.current);if(["ArrowUp","End"].includes(z.key)&&(Z=Z.slice().reverse()),["ArrowUp","ArrowDown"].includes(z.key)){const q=z.target,Y=Z.indexOf(q);Z=Z.slice(Y+1)}setTimeout(()=>N(Z)),z.preventDefault()}})})})})})})});Pa.displayName=vh;var bh="SelectItemAlignedPosition",Ta=f.forwardRef((e,t)=>{const{__scopeSelect:r,onPlaced:n,...o}=e,s=Xe(st,r),i=qe(st,r),[a,c]=f.useState(null),[l,u]=f.useState(null),d=ee(t,R=>u(R)),p=Cr(r),g=f.useRef(!1),v=f.useRef(!0),{viewport:h,selectedItem:b,selectedItemText:y,focusSelectedItem:x}=i,w=f.useCallback(()=>{if(s.trigger&&s.valueNode&&a&&l&&h&&b&&y){const R=s.trigger.getBoundingClientRect(),O=l.getBoundingClientRect(),$=s.valueNode.getBoundingClientRect(),L=y.getBoundingClientRect();if(s.dir!=="rtl"){const q=L.left-O.left,Y=$.left-q,de=R.left-Y,ue=R.width+de,Ze=Math.max(ue,O.width),ze=window.innerWidth-Ce,be=Vo(Y,[Ce,Math.max(Ce,ze-Ze)]);a.style.minWidth=ue+"px",a.style.left=be+"px"}else{const q=O.right-L.right,Y=window.innerWidth-$.right-q,de=window.innerWidth-R.right-Y,ue=R.width+de,Ze=Math.max(ue,O.width),ze=window.innerWidth-Ce,be=Vo(Y,[Ce,Math.max(Ce,ze-Ze)]);a.style.minWidth=ue+"px",a.style.right=be+"px"}const k=p(),P=window.innerHeight-Ce*2,_=h.scrollHeight,I=window.getComputedStyle(l),D=parseInt(I.borderTopWidth,10),N=parseInt(I.paddingTop,10),M=parseInt(I.borderBottomWidth,10),T=parseInt(I.paddingBottom,10),j=D+N+_+T+M,U=Math.min(b.offsetHeight*5,j),V=window.getComputedStyle(h),se=parseInt(V.paddingTop,10),B=parseInt(V.paddingBottom,10),X=R.top+R.height/2-Ce,J=P-X,ne=b.offsetHeight/2,z=b.offsetTop+ne,F=D+N+z,re=j-F;if(F<=X){const q=k.length>0&&b===k[k.length-1].ref.current;a.style.bottom="0px";const Y=l.clientHeight-h.offsetTop-h.offsetHeight,de=Math.max(J,ne+(q?B:0)+Y+M),ue=F+de;a.style.height=ue+"px"}else{const q=k.length>0&&b===k[0].ref.current;a.style.top="0px";const de=Math.max(X,D+h.offsetTop+(q?se:0)+ne)+re;a.style.height=de+"px",h.scrollTop=F-X+h.offsetTop}a.style.margin=`${Ce}px 0`,a.style.minHeight=U+"px",a.style.maxHeight=P+"px",n==null||n(),requestAnimationFrame(()=>g.current=!0)}},[p,s.trigger,s.valueNode,a,l,h,b,y,s.dir,n]);le(()=>w(),[w]);const[C,S]=f.useState();le(()=>{l&&S(window.getComputedStyle(l).zIndex)},[l]);const A=f.useCallback(R=>{R&&v.current===!0&&(w(),x==null||x(),v.current=!1)},[w,x]);return m.jsx(wh,{scope:r,contentWrapper:a,shouldExpandOnScrollRef:g,onScrollButtonChange:A,children:m.jsx("div",{ref:c,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:C},children:m.jsx(K.div,{...o,ref:d,style:{boxSizing:"border-box",maxHeight:"100%",...o.style}})})})});Ta.displayName=bh;var xh="SelectPopperPosition",Gr=f.forwardRef((e,t)=>{const{__scopeSelect:r,align:n="start",collisionPadding:o=Ce,...s}=e,i=Sr(r);return m.jsx(sh,{...i,...s,ref:t,align:n,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)"}})});Gr.displayName=xh;var[wh,Nn]=Nt(st,{}),Ur="SelectViewport",ka=f.forwardRef((e,t)=>{const{__scopeSelect:r,nonce:n,...o}=e,s=qe(Ur,r),i=Nn(Ur,r),a=ee(t,s.onViewportChange),c=f.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:n}),m.jsx(wr.Slot,{scope:r,children:m.jsx(K.div,{"data-radix-select-viewport":"",role:"presentation",...o,ref:a,style:{position:"relative",flex:1,overflow:"hidden auto",...o.style},onScroll:Q(o.onScroll,l=>{const u=l.currentTarget,{contentWrapper:d,shouldExpandOnScrollRef:p}=i;if(p!=null&&p.current&&d){const g=Math.abs(c.current-u.scrollTop);if(g>0){const v=window.innerHeight-Ce*2,h=parseFloat(d.style.minHeight),b=parseFloat(d.style.height),y=Math.max(h,b);if(y<v){const x=y+g,w=Math.min(v,x),C=x-w;d.style.height=w+"px",d.style.bottom==="0px"&&(u.scrollTop=C>0?C:0,d.style.justifyContent="flex-end")}}}c.current=u.scrollTop})})})]})});ka.displayName=Ur;var Da="SelectGroup",[Ch,Sh]=Nt(Da),Ma=f.forwardRef((e,t)=>{const{__scopeSelect:r,...n}=e,o=He();return m.jsx(Ch,{scope:r,id:o,children:m.jsx(K.div,{role:"group","aria-labelledby":o,...n,ref:t})})});Ma.displayName=Da;var Ia="SelectLabel",Oa=f.forwardRef((e,t)=>{const{__scopeSelect:r,...n}=e,o=Sh(Ia,r);return m.jsx(K.div,{id:o.id,...n,ref:t})});Oa.displayName=Ia;var sr="SelectItem",[Eh,_a]=Nt(sr),ja=f.forwardRef((e,t)=>{const{__scopeSelect:r,value:n,disabled:o=!1,textValue:s,...i}=e,a=Xe(sr,r),c=qe(sr,r),l=a.value===n,[u,d]=f.useState(s??""),[p,g]=f.useState(!1),v=ee(t,x=>{var w;return(w=c.itemRefCallback)==null?void 0:w.call(c,x,n,o)}),h=He(),b=f.useRef("touch"),y=()=>{o||(a.onValueChange(n),a.onOpenChange(!1))};if(n==="")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(Eh,{scope:r,value:n,disabled:o,textId:h,isSelected:l,onItemTextChange:f.useCallback(x=>{d(w=>w||((x==null?void 0:x.textContent)??"").trim())},[]),children:m.jsx(wr.ItemSlot,{scope:r,value:n,disabled:o,textValue:u,children:m.jsx(K.div,{role:"option","aria-labelledby":h,"data-highlighted":p?"":void 0,"aria-selected":l&&p,"data-state":l?"checked":"unchecked","aria-disabled":o||void 0,"data-disabled":o?"":void 0,tabIndex:o?void 0:-1,...i,ref:v,onFocus:Q(i.onFocus,()=>g(!0)),onBlur:Q(i.onBlur,()=>g(!1)),onClick:Q(i.onClick,()=>{b.current!=="mouse"&&y()}),onPointerUp:Q(i.onPointerUp,()=>{b.current==="mouse"&&y()}),onPointerDown:Q(i.onPointerDown,x=>{b.current=x.pointerType}),onPointerMove:Q(i.onPointerMove,x=>{var w;b.current=x.pointerType,o?(w=c.onItemLeave)==null||w.call(c):b.current==="mouse"&&x.currentTarget.focus({preventScroll:!0})}),onPointerLeave:Q(i.onPointerLeave,x=>{var w;x.currentTarget===document.activeElement&&((w=c.onItemLeave)==null||w.call(c))}),onKeyDown:Q(i.onKeyDown,x=>{var C;((C=c.searchRef)==null?void 0:C.current)!==""&&x.key===" "||(dh.includes(x.key)&&y(),x.key===" "&&x.preventDefault())})})})})});ja.displayName=sr;var kt="SelectItemText",La=f.forwardRef((e,t)=>{const{__scopeSelect:r,className:n,style:o,...s}=e,i=Xe(kt,r),a=qe(kt,r),c=_a(kt,r),l=hh(kt,r),[u,d]=f.useState(null),p=ee(t,y=>d(y),c.onItemTextChange,y=>{var x;return(x=a.itemTextRefCallback)==null?void 0:x.call(a,y,c.value,c.disabled)}),g=u==null?void 0:u.textContent,v=f.useMemo(()=>m.jsx("option",{value:c.value,disabled:c.disabled,children:g},c.value),[c.disabled,c.value,g]),{onNativeOptionAdd:h,onNativeOptionRemove:b}=l;return le(()=>(h(v),()=>b(v)),[h,b,v]),m.jsxs(m.Fragment,{children:[m.jsx(K.span,{id:c.textId,...s,ref:p}),c.isSelected&&i.valueNode&&!i.valueNodeHasChildren?ar.createPortal(s.children,i.valueNode):null]})});La.displayName=kt;var $a="SelectItemIndicator",za=f.forwardRef((e,t)=>{const{__scopeSelect:r,...n}=e;return _a($a,r).isSelected?m.jsx(K.span,{"aria-hidden":!0,...n,ref:t}):null});za.displayName=$a;var Yr="SelectScrollUpButton",Fa=f.forwardRef((e,t)=>{const r=qe(Yr,e.__scopeSelect),n=Nn(Yr,e.__scopeSelect),[o,s]=f.useState(!1),i=ee(t,n.onScrollButtonChange);return le(()=>{if(r.viewport&&r.isPositioned){let a=function(){const l=c.scrollTop>0;s(l)};const c=r.viewport;return a(),c.addEventListener("scroll",a),()=>c.removeEventListener("scroll",a)}},[r.viewport,r.isPositioned]),o?m.jsx(Va,{...e,ref:i,onAutoScroll:()=>{const{viewport:a,selectedItem:c}=r;a&&c&&(a.scrollTop=a.scrollTop-c.offsetHeight)}}):null});Fa.displayName=Yr;var Kr="SelectScrollDownButton",Ba=f.forwardRef((e,t)=>{const r=qe(Kr,e.__scopeSelect),n=Nn(Kr,e.__scopeSelect),[o,s]=f.useState(!1),i=ee(t,n.onScrollButtonChange);return le(()=>{if(r.viewport&&r.isPositioned){let a=function(){const l=c.scrollHeight-c.clientHeight,u=Math.ceil(c.scrollTop)<l;s(u)};const c=r.viewport;return a(),c.addEventListener("scroll",a),()=>c.removeEventListener("scroll",a)}},[r.viewport,r.isPositioned]),o?m.jsx(Va,{...e,ref:i,onAutoScroll:()=>{const{viewport:a,selectedItem:c}=r;a&&c&&(a.scrollTop=a.scrollTop+c.offsetHeight)}}):null});Ba.displayName=Kr;var Va=f.forwardRef((e,t)=>{const{__scopeSelect:r,onAutoScroll:n,...o}=e,s=qe("SelectScrollButton",r),i=f.useRef(null),a=Cr(r),c=f.useCallback(()=>{i.current!==null&&(window.clearInterval(i.current),i.current=null)},[]);return f.useEffect(()=>()=>c(),[c]),le(()=>{var u;const l=a().find(d=>d.ref.current===document.activeElement);(u=l==null?void 0:l.ref.current)==null||u.scrollIntoView({block:"nearest"})},[a]),m.jsx(K.div,{"aria-hidden":!0,...o,ref:t,style:{flexShrink:0,...o.style},onPointerDown:Q(o.onPointerDown,()=>{i.current===null&&(i.current=window.setInterval(n,50))}),onPointerMove:Q(o.onPointerMove,()=>{var l;(l=s.onItemLeave)==null||l.call(s),i.current===null&&(i.current=window.setInterval(n,50))}),onPointerLeave:Q(o.onPointerLeave,()=>{c()})})}),Rh="SelectSeparator",Wa=f.forwardRef((e,t)=>{const{__scopeSelect:r,...n}=e;return m.jsx(K.div,{"aria-hidden":!0,...n,ref:t})});Wa.displayName=Rh;var Xr="SelectArrow",Ah=f.forwardRef((e,t)=>{const{__scopeSelect:r,...n}=e,o=Sr(r),s=Xe(Xr,r),i=qe(Xr,r);return s.open&&i.position==="popper"?m.jsx(ih,{...o,...n,ref:t}):null});Ah.displayName=Xr;var Nh="SelectBubbleInput",Ha=f.forwardRef(({__scopeSelect:e,value:t,...r},n)=>{const o=f.useRef(null),s=ee(n,o),i=va(t);return f.useEffect(()=>{const a=o.current;if(!a)return;const c=window.HTMLSelectElement.prototype,u=Object.getOwnPropertyDescriptor(c,"value").set;if(i!==t&&u){const d=new Event("change",{bubbles:!0});u.call(a,t),a.dispatchEvent(d)}},[i,t]),m.jsx(K.select,{...r,style:{...ya,...r.style},ref:s,defaultValue:t})});Ha.displayName=Nh;function Ga(e){return e===""||e===void 0}function Ua(e){const t=tt(e),r=f.useRef(""),n=f.useRef(0),o=f.useCallback(i=>{const a=r.current+i;t(a),function c(l){r.current=l,window.clearTimeout(n.current),l!==""&&(n.current=window.setTimeout(()=>c(""),1e3))}(a)},[t]),s=f.useCallback(()=>{r.current="",window.clearTimeout(n.current)},[]);return f.useEffect(()=>()=>window.clearTimeout(n.current),[]),[r,o,s]}function Ya(e,t,r){const o=t.length>1&&Array.from(t).every(l=>l===t[0])?t[0]:t,s=r?e.indexOf(r):-1;let i=Ph(e,Math.max(s,0));o.length===1&&(i=i.filter(l=>l!==r));const c=i.find(l=>l.textValue.toLowerCase().startsWith(o.toLowerCase()));return c!==r?c:void 0}function Ph(e,t){return e.map((r,n)=>e[(t+n)%e.length])}var Th=ba,Ka=wa,kh=Sa,Dh=Ea,Mh=Ra,Xa=Aa,Ih=ka,Oh=Ma,qa=Oa,Za=ja,_h=La,jh=za,Qa=Fa,Ja=Ba,el=Wa;const Lh=Th,$h=Oh,zh=kh,tl=f.forwardRef(({className:e,children:t,...r},n)=>m.jsxs(Ka,{ref:n,className:G("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 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),...r,children:[t,m.jsx(Dh,{asChild:!0,children:m.jsx(Bi,{className:"h-4 w-4 opacity-50"})})]}));tl.displayName=Ka.displayName;const rl=f.forwardRef(({className:e,...t},r)=>m.jsx(Qa,{ref:r,className:G("flex cursor-default items-center justify-center py-1",e),...t,children:m.jsx(Tf,{className:"h-4 w-4"})}));rl.displayName=Qa.displayName;const nl=f.forwardRef(({className:e,...t},r)=>m.jsx(Ja,{ref:r,className:G("flex cursor-default items-center justify-center py-1",e),...t,children:m.jsx(Bi,{className:"h-4 w-4"})}));nl.displayName=Ja.displayName;const ol=f.forwardRef(({className:e,children:t,position:r="popper",...n},o)=>m.jsx(Mh,{children:m.jsxs(Xa,{ref:o,className:G("relative z-50 max-h-96 min-w-[8rem] overflow-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",r==="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:r,...n,children:[m.jsx(rl,{}),m.jsx(Ih,{className:G("p-1",r==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"),children:t}),m.jsx(nl,{})]})}));ol.displayName=Xa.displayName;const sl=f.forwardRef(({className:e,...t},r)=>m.jsx(qa,{ref:r,className:G("py-1.5 pl-8 pr-2 text-sm font-semibold",e),...t}));sl.displayName=qa.displayName;const il=f.forwardRef(({className:e,children:t,...r},n)=>m.jsxs(Za,{ref:n,className:G("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),...r,children:[m.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:m.jsx(jh,{children:m.jsx(gr,{className:"h-4 w-4"})})}),m.jsx(_h,{children:t})]}));il.displayName=Za.displayName;const al=f.forwardRef(({className:e,...t},r)=>m.jsx(el,{ref:r,className:G("-mx-1 my-1 h-px bg-muted",e),...t}));al.displayName=el.displayName;var Er="Checkbox",[Fh]=Ke(Er),[Bh,Pn]=Fh(Er);function Vh(e){const{__scopeCheckbox:t,checked:r,children:n,defaultChecked:o,disabled:s,form:i,name:a,onCheckedChange:c,required:l,value:u="on",internal_do_not_use_render:d}=e,[p,g]=et({prop:r,defaultProp:o??!1,onChange:c,caller:Er}),[v,h]=f.useState(null),[b,y]=f.useState(null),x=f.useRef(!1),w=v?!!i||!!v.closest("form"):!0,C={checked:p,disabled:s,setChecked:g,control:v,setControl:h,name:a,form:i,value:u,hasConsumerStoppedPropagationRef:x,required:l,defaultChecked:Ge(o)?!1:o,isFormControl:w,bubbleInput:b,setBubbleInput:y};return m.jsx(Bh,{scope:t,...C,children:Wh(d)?d(C):n})}var ll="CheckboxTrigger",cl=f.forwardRef(({__scopeCheckbox:e,onKeyDown:t,onClick:r,...n},o)=>{const{control:s,value:i,disabled:a,checked:c,required:l,setControl:u,setChecked:d,hasConsumerStoppedPropagationRef:p,isFormControl:g,bubbleInput:v}=Pn(ll,e),h=ee(o,u),b=f.useRef(c);return f.useEffect(()=>{const y=s==null?void 0:s.form;if(y){const x=()=>d(b.current);return y.addEventListener("reset",x),()=>y.removeEventListener("reset",x)}},[s,d]),m.jsx(K.button,{type:"button",role:"checkbox","aria-checked":Ge(c)?"mixed":c,"aria-required":l,"data-state":hl(c),"data-disabled":a?"":void 0,disabled:a,value:i,...n,ref:h,onKeyDown:Q(t,y=>{y.key==="Enter"&&y.preventDefault()}),onClick:Q(r,y=>{d(x=>Ge(x)?!0:!x),v&&g&&(p.current=y.isPropagationStopped(),p.current||y.stopPropagation())})})});cl.displayName=ll;var Tn=f.forwardRef((e,t)=>{const{__scopeCheckbox:r,name:n,checked:o,defaultChecked:s,required:i,disabled:a,value:c,onCheckedChange:l,form:u,...d}=e;return m.jsx(Vh,{__scopeCheckbox:r,checked:o,defaultChecked:s,disabled:a,required:i,onCheckedChange:l,name:n,form:u,value:c,internal_do_not_use_render:({isFormControl:p})=>m.jsxs(m.Fragment,{children:[m.jsx(cl,{...d,ref:t,__scopeCheckbox:r}),p&&m.jsx(pl,{__scopeCheckbox:r})]})})});Tn.displayName=Er;var dl="CheckboxIndicator",ul=f.forwardRef((e,t)=>{const{__scopeCheckbox:r,forceMount:n,...o}=e,s=Pn(dl,r);return m.jsx(St,{present:n||Ge(s.checked)||s.checked===!0,children:m.jsx(K.span,{"data-state":hl(s.checked),"data-disabled":s.disabled?"":void 0,...o,ref:t,style:{pointerEvents:"none",...e.style}})})});ul.displayName=dl;var fl="CheckboxBubbleInput",pl=f.forwardRef(({__scopeCheckbox:e,...t},r)=>{const{control:n,hasConsumerStoppedPropagationRef:o,checked:s,defaultChecked:i,required:a,disabled:c,name:l,value:u,form:d,bubbleInput:p,setBubbleInput:g}=Pn(fl,e),v=ee(r,g),h=va(s),b=ia(n);f.useEffect(()=>{const x=p;if(!x)return;const w=window.HTMLInputElement.prototype,S=Object.getOwnPropertyDescriptor(w,"checked").set,A=!o.current;if(h!==s&&S){const R=new Event("click",{bubbles:A});x.indeterminate=Ge(s),S.call(x,Ge(s)?!1:s),x.dispatchEvent(R)}},[p,h,s,o]);const y=f.useRef(Ge(s)?!1:s);return m.jsx(K.input,{type:"checkbox","aria-hidden":!0,defaultChecked:i??y.current,required:a,disabled:c,name:l,value:u,form:d,...t,tabIndex:-1,ref:v,style:{...t.style,...b,position:"absolute",pointerEvents:"none",opacity:0,margin:0,transform:"translateX(-100%)"}})});pl.displayName=fl;function Wh(e){return typeof e=="function"}function Ge(e){return e==="indeterminate"}function hl(e){return Ge(e)?"indeterminate":e?"checked":"unchecked"}const ml=f.forwardRef(({className:e,...t},r)=>m.jsx(Tn,{ref:r,className:G("peer h-4 w-4 shrink-0 rounded-sm border border-gray-200 border-gray-900 ring-offset-white focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-gray-950 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-gray-900 data-[state=checked]:text-gray-50 dark:border-gray-800 dark:border-gray-50 dark:ring-offset-gray-950 dark:focus-visible:ring-gray-300 dark:data-[state=checked]:bg-gray-50 dark:data-[state=checked]:text-gray-900",e),...t,children:m.jsx(ul,{className:G("flex items-center justify-center text-current"),children:m.jsx(gr,{className:"h-4 w-4"})})}));ml.displayName=Tn.displayName;var gl="AlertDialog",[Hh]=Ke(gl,[wi]),$e=wi(),vl=e=>{const{__scopeAlertDialog:t,...r}=e,n=$e(t);return m.jsx(Li,{...n,...r,modal:!0})};vl.displayName=gl;var Gh="AlertDialogTrigger",yl=f.forwardRef((e,t)=>{const{__scopeAlertDialog:r,...n}=e,o=$e(r);return m.jsx($i,{...o,...n,ref:t})});yl.displayName=Gh;var Uh="AlertDialogPortal",bl=e=>{const{__scopeAlertDialog:t,...r}=e,n=$e(t);return m.jsx(zi,{...n,...r})};bl.displayName=Uh;var Yh="AlertDialogOverlay",xl=f.forwardRef((e,t)=>{const{__scopeAlertDialog:r,...n}=e,o=$e(r);return m.jsx(hn,{...o,...n,ref:t})});xl.displayName=Yh;var yt="AlertDialogContent",[Kh,Xh]=Hh(yt),qh=ic("AlertDialogContent"),wl=f.forwardRef((e,t)=>{const{__scopeAlertDialog:r,children:n,...o}=e,s=$e(r),i=f.useRef(null),a=ee(t,i),c=f.useRef(null);return m.jsx(vf,{contentName:yt,titleName:Cl,docsSlug:"alert-dialog",children:m.jsx(Kh,{scope:r,cancelRef:c,children:m.jsxs(mn,{role:"alertdialog",...s,...o,ref:a,onOpenAutoFocus:Q(o.onOpenAutoFocus,l=>{var u;l.preventDefault(),(u=c.current)==null||u.focus({preventScroll:!0})}),onPointerDownOutside:l=>l.preventDefault(),onInteractOutside:l=>l.preventDefault(),children:[m.jsx(qh,{children:n}),m.jsx(Qh,{contentRef:i})]})})})});wl.displayName=yt;var Cl="AlertDialogTitle",Sl=f.forwardRef((e,t)=>{const{__scopeAlertDialog:r,...n}=e,o=$e(r);return m.jsx(gn,{...o,...n,ref:t})});Sl.displayName=Cl;var El="AlertDialogDescription",Rl=f.forwardRef((e,t)=>{const{__scopeAlertDialog:r,...n}=e,o=$e(r);return m.jsx(vn,{...o,...n,ref:t})});Rl.displayName=El;var Zh="AlertDialogAction",Al=f.forwardRef((e,t)=>{const{__scopeAlertDialog:r,...n}=e,o=$e(r);return m.jsx(mr,{...o,...n,ref:t})});Al.displayName=Zh;var Nl="AlertDialogCancel",Pl=f.forwardRef((e,t)=>{const{__scopeAlertDialog:r,...n}=e,{cancelRef:o}=Xh(Nl,r),s=$e(r),i=ee(t,o);return m.jsx(mr,{...s,...n,ref:i})});Pl.displayName=Nl;var Qh=({contentRef:e})=>{const t=`\`${yt}\` requires a description for the component to be accessible for screen reader users.
114
114
 
115
115
  You can add a description to the \`${yt}\` by passing a \`${El}\` component as a child, which also benefits sighted users by adding visible context to the dialog.
116
116
 
117
117
  Alternatively, you can use your own component as a description by assigning it an \`id\` and passing the same value to the \`aria-describedby\` prop in \`${yt}\`. If the description is confusing or duplicative for sighted users, you can use the \`@radix-ui/react-visually-hidden\` primitive as a wrapper around your description component.
118
118
 
119
- For more information, see https://radix-ui.com/primitives/docs/components/alert-dialog`;return f.useEffect(()=>{var n;document.getElementById((n=e.current)==null?void 0:n.getAttribute("aria-describedby"))||console.warn(t)},[t,e]),null},Jh=vl,em=yl,tm=bl,Tl=xl,kl=wl,Dl=Al,Ml=Pl,Il=Sl,Ol=Rl;const rm=Jh,nm=em,_l=tm,kn=f.forwardRef(({className:e,...t},r)=>m.jsx(Tl,{className:G("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,ref:r}));kn.displayName=Tl.displayName;const jl=f.forwardRef(({className:e,...t},r)=>m.jsxs(_l,{children:[m.jsx(kn,{}),m.jsx(kl,{ref:r,className:G("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border border-gray-200 bg-white 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 dark:border-gray-800 dark:bg-gray-950",e),...t})]}));jl.displayName=kl.displayName;const Ll=({className:e,...t})=>m.jsx("div",{className:G("flex flex-col space-y-2 text-center sm:text-left",e),...t});Ll.displayName="AlertDialogHeader";const $l=({className:e,...t})=>m.jsx("div",{className:G("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...t});$l.displayName="AlertDialogFooter";const zl=f.forwardRef(({className:e,...t},r)=>m.jsx(Il,{ref:r,className:G("text-lg font-semibold",e),...t}));zl.displayName=Il.displayName;const Bl=f.forwardRef(({className:e,...t},r)=>m.jsx(Ol,{ref:r,className:G("text-sm text-gray-500 dark:text-gray-400",e),...t}));Bl.displayName=Ol.displayName;const Fl=f.forwardRef(({className:e,...t},r)=>m.jsx(Dl,{ref:r,className:G(Jr(),e),...t}));Fl.displayName=Dl.displayName;const Vl=f.forwardRef(({className:e,...t},r)=>m.jsx(Ml,{ref:r,className:G(Jr({variant:"outline"}),"mt-2 sm:mt-0",e),...t}));Vl.displayName=Ml.displayName;function om({caption:e,children:t,plainText:r,enableSpacebar:n=!1,showToast:o=!0,maxHeight:s="60vh",className:i=""}){const[a,c]=E.useState(!1),[l,u]=E.useState(!1),[d,p]=E.useState(!1),[g,v]=E.useState(!1),[h,b]=E.useState(null),y=E.useRef(null),x=E.useRef(null),w=E.useRef(null),C=E.useRef(null),S=E.useRef(!1),A=E.useCallback(()=>{x.current&&clearTimeout(x.current),x.current=window.setTimeout(()=>{w.current&&(b(w.current.getBoundingClientRect()),v(!0))},500)},[]),R=E.useCallback(()=>{x.current&&(clearTimeout(x.current),x.current=null),v(!1),b(null)},[]),O=L=>{const k=L.split(`
119
+ For more information, see https://radix-ui.com/primitives/docs/components/alert-dialog`;return f.useEffect(()=>{var n;document.getElementById((n=e.current)==null?void 0:n.getAttribute("aria-describedby"))||console.warn(t)},[t,e]),null},Jh=vl,em=yl,tm=bl,Tl=xl,kl=wl,Dl=Al,Ml=Pl,Il=Sl,Ol=Rl;const rm=Jh,nm=em,_l=tm,kn=f.forwardRef(({className:e,...t},r)=>m.jsx(Tl,{className:G("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,ref:r}));kn.displayName=Tl.displayName;const jl=f.forwardRef(({className:e,...t},r)=>m.jsxs(_l,{children:[m.jsx(kn,{}),m.jsx(kl,{ref:r,className:G("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border border-gray-200 bg-white 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 dark:border-gray-800 dark:bg-gray-950",e),...t})]}));jl.displayName=kl.displayName;const Ll=({className:e,...t})=>m.jsx("div",{className:G("flex flex-col space-y-2 text-center sm:text-left",e),...t});Ll.displayName="AlertDialogHeader";const $l=({className:e,...t})=>m.jsx("div",{className:G("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...t});$l.displayName="AlertDialogFooter";const zl=f.forwardRef(({className:e,...t},r)=>m.jsx(Il,{ref:r,className:G("text-lg font-semibold",e),...t}));zl.displayName=Il.displayName;const Fl=f.forwardRef(({className:e,...t},r)=>m.jsx(Ol,{ref:r,className:G("text-sm text-gray-500 dark:text-gray-400",e),...t}));Fl.displayName=Ol.displayName;const Bl=f.forwardRef(({className:e,...t},r)=>m.jsx(Dl,{ref:r,className:G(Jr(),e),...t}));Bl.displayName=Dl.displayName;const Vl=f.forwardRef(({className:e,...t},r)=>m.jsx(Ml,{ref:r,className:G(Jr({variant:"outline"}),"mt-2 sm:mt-0",e),...t}));Vl.displayName=Ml.displayName;function om({caption:e,children:t,plainText:r,enableSpacebar:n=!1,showToast:o=!0,maxHeight:s="60vh",className:i=""}){const[a,c]=E.useState(!1),[l,u]=E.useState(!1),[d,p]=E.useState(!1),[g,v]=E.useState(!1),[h,b]=E.useState(null),y=E.useRef(null),x=E.useRef(null),w=E.useRef(null),C=E.useRef(null),S=E.useRef(!1),A=E.useCallback(()=>{x.current&&clearTimeout(x.current),x.current=window.setTimeout(()=>{w.current&&(b(w.current.getBoundingClientRect()),v(!0))},500)},[]),R=E.useCallback(()=>{x.current&&(clearTimeout(x.current),x.current=null),v(!1),b(null)},[]),O=L=>{const k=L.split(`
120
120
  `),P=[];return k.forEach((_,I)=>{if(I>0&&P.push(`
121
121
  `),_.trim().startsWith("//")){P.push(m.jsx("span",{className:"text-gray-400",children:_},`line-${I}`));return}let D=_,N=0;for(;D.length>0;){let M=!1;if(D[0]==='"'){const T=D.indexOf('"',1);if(T!==-1){const j=D.substring(0,T+1);P.push(m.jsx("span",{className:"text-green-400",children:j},`line-${I}-${N}`)),D=D.substring(T+1),N+=T+1,M=!0}}if(!M&&D[0]==="'"){const T=D.indexOf("'",1);if(T!==-1){const j=D.substring(0,T+1);P.push(m.jsx("span",{className:"text-green-400",children:j},`line-${I}-${N}`)),D=D.substring(T+1),N+=T+1,M=!0}}if(!M&&D[0]==="`"){const T=D.indexOf("`",1);if(T!==-1){const j=D.substring(0,T+1);P.push(m.jsx("span",{className:"text-green-400",children:j},`line-${I}-${N}`)),D=D.substring(T+1),N+=T+1,M=!0}}if(!M&&/[a-zA-Z_]/.test(D[0])){const T=D.match(/^[a-zA-Z_][a-zA-Z0-9_]*/);if(T){const j=T[0];["import","export","from","const","let","var","function","return","await","async","if","else","try","catch","finally","for","while","switch","case","break","continue","default","class","interface","type","enum","extends","implements","new","this","super","void","true","false","null","undefined"].includes(j)?P.push(m.jsx("span",{className:"text-purple-400",children:j},`line-${I}-${N}`)):P.push(j),D=D.substring(j.length),N+=j.length,M=!0}}if(!M&&/\d/.test(D[0])){const T=D.match(/^\d+\.?\d*/);if(T){const j=T[0];P.push(m.jsx("span",{className:"text-orange-400",children:j},`line-${I}-${N}`)),D=D.substring(j.length),N+=j.length,M=!0}}!M&&/[{}\[\]()]/.test(D[0])&&(P.push(m.jsx("span",{className:"text-yellow-300",children:D[0]},`line-${I}-${N}`)),D=D.substring(1),N+=1,M=!0),M||(P.push(D[0]),D=D.substring(1),N+=1)}}),P},$=E.useCallback(async()=>{if(C.current)try{c(!0);const L=r||C.current.innerText||C.current.textContent||"";await navigator.clipboard.writeText(L),o&&Dt.success("Code copied to clipboard"),y.current&&window.clearTimeout(y.current),p(!0),y.current=window.setTimeout(()=>{p(!1)},2e3)}catch(L){console.error("Failed to copy code",L),o&&Dt.error("Failed to copy code")}finally{c(!1)}},[r,o]);return E.useEffect(()=>{if(!n)return;const L=P=>{const _=P.target;P.code==="Space"&&!a&&!S.current&&_.tagName!=="INPUT"&&_.tagName!=="TEXTAREA"&&!_.isContentEditable&&!_.closest("input")&&!_.closest("textarea")&&(P.preventDefault(),S.current=!0,u(!0),w.current&&w.current.blur(),$())},k=P=>{P.code==="Space"&&(S.current=!1,u(!1))};return window.addEventListener("keydown",L),window.addEventListener("keyup",k),()=>{window.removeEventListener("keydown",L),window.removeEventListener("keyup",k)}},[n,a,$]),E.useEffect(()=>()=>{y.current&&window.clearTimeout(y.current),x.current&&window.clearTimeout(x.current)},[]),m.jsxs("figure",{className:`space-y-3 ${i}`,children:[e&&m.jsx("figcaption",{className:"text-xs font-semibold uppercase tracking-[0.2em] text-[#6B6766]",children:e}),m.jsxs("div",{className:"relative group",children:[m.jsx("button",{ref:w,onClick:$,onMouseEnter:A,onMouseLeave:()=>{R(),u(!1)},onMouseDown:()=>u(!0),onMouseUp:()=>u(!1),onTouchStart:()=>u(!0),onTouchEnd:()=>u(!1),disabled:a,className:"absolute top-3 right-3 w-8 h-8 hidden md:flex items-center justify-center rounded-md bg-gray-800/70 hover:bg-gray-700 text-gray-200 transition-colors cursor-pointer select-none focus:outline-none z-10 disabled:opacity-50 disabled:cursor-not-allowed","aria-label":"Copy code",children:d?m.jsx(gr,{className:`h-4 w-4 text-green-400 transition-transform duration-150 ${l?"scale-90":"scale-100"}`}):m.jsx(Df,{className:`h-4 w-4 transition-transform duration-150 ${l?"scale-90":"scale-100"}`})}),m.jsx("pre",{ref:C,className:"overflow-x-auto rounded-2xl bg-gray-900 px-6 py-8 font-mono text-sm leading-relaxed text-gray-100 shadow-sm whitespace-pre",style:{maxHeight:s},children:m.jsx("code",{className:"block",children:typeof t=="string"?O(t):t})})]}),g&&h&&typeof window<"u"&&ir.createPortal(m.jsx("div",{className:"fixed px-2 py-1 text-xs rounded bg-gray-800 text-white whitespace-nowrap shadow-lg z-[9999] pointer-events-none",style:{left:h.left+h.width/2,top:h.top-40,transform:"translateX(-50%)"},children:"Copy"}),document.body)]})}function sm({url:e,ariaLabel:t="Copy link",showToast:r=!0,className:n=""}){const[o,s]=E.useState(!1),[i,a]=E.useState(!1),[c,l]=E.useState(!1),u=E.useRef(null),d=E.useCallback(async()=>{if(!(!e||o))try{s(!0),await navigator.clipboard.writeText(e),r&&Dt.success("Link copied to clipboard"),u.current&&window.clearTimeout(u.current),l(!0),u.current=window.setTimeout(()=>{l(!1)},2e3)}catch(p){console.error("[LinkCopyButton] Failed to copy link",p),r&&Dt.error("Failed to copy link")}finally{s(!1)}},[e,o,r]);return E.useEffect(()=>()=>{u.current&&window.clearTimeout(u.current)},[]),m.jsx("button",{type:"button","aria-label":t,onClick:d,onMouseDown:()=>a(!0),onMouseUp:()=>a(!1),onMouseLeave:()=>a(!1),onTouchStart:()=>a(!0),onTouchEnd:()=>a(!1),disabled:o||!e,className:["inline-flex h-9 w-9 items-center justify-center rounded-md bg-gray-100 hover:bg-gray-200 text-gray-700 transition-colors cursor-pointer select-none focus:outline-none disabled:opacity-50 disabled:cursor-not-allowed",n].join(" "),children:c?m.jsx(gr,{className:["h-4 w-4 text-green-600 transition-transform duration-150",i?"scale-90":"scale-100"].join(" ")}):m.jsx(If,{className:["h-4 w-4 transition-transform duration-150",i?"scale-90":"scale-100"].join(" ")})})}function Wl({url:e,imageUrl:t,status:r,onClick:n,className:o="",size:s="md",showHostname:i=!0}){const a={sm:"w-20 h-20",md:"w-24 h-24",lg:"w-32 h-32"};return m.jsxs("button",{type:"button",onClick:n,style:{cursor:"pointer"},className:`
122
122
  relative
@@ -145,4 +145,4 @@ For more information, see https://radix-ui.com/primitives/docs/components/alert-
145
145
  text-gray-500
146
146
  font-medium
147
147
  text-sm
148
- `,children:["+",a]})]})}var Qt=new class{constructor(){Je(this,"elements");Je(this,"observer");Je(this,"rafID",null);Je(this,"queue",[]);Je(this,"resizePrecisionPower",1);Je(this,"getDrawOptions",e=>{var t,r;return((r=(t=this.elements)==null?void 0:t.get(e))==null?void 0:r.cornerOptions)??null});this.elements=null,this.observer=null}onElementResize(e){this.queue.push(...e),this.rafID||(this.rafID=requestAnimationFrame(()=>this.flushQueue()))}flushQueue(){const e=new Map;for(const t of this.queue)e.set(t.target,t);this.queue=[],e.forEach((t,r)=>{var u;if(!r.isConnected)return void this.unobserve(r);const n=(u=this.elements)==null?void 0:u.get(r);if(!n)return;let{inlineSize:o,blockSize:s}=t.borderBoxSize[0];n.cornerOptions.isRounded&&(o=Math.round(o),s=Math.round(s));const{previousW:i,previousH:a,draw:c,onResize:l}=n;i===o&&a===s||(c==null||c({width:o,height:s}),l==null||l({width:o,height:s},t.target),n.previousW=o,n.previousH=s)}),this.rafID=null}setCornerOptions(e,t){var n,o;const r=(n=this.elements)==null?void 0:n.get(e);r&&(r.cornerOptions=t,(o=this.elements)==null||o.set(e,r))}addElement(e,t,r){this.elements||(this.elements=new Map),this.observer||(this.observer=new ResizeObserver(s=>this.onElementResize(s))),this.unobserve(e);const{observe:n=!0,onResize:o}=t;return n&&(this.elements.set(e,{draw:r,cornerOptions:t,onResize:o,previousW:null,previousH:null,element:e}),this.observer.observe(e)),r}draw(e,t){var n,o;const r=s=>{var c;if(!s.element.isConnected)return;let{previousW:i,previousH:a}=s;i!==null&&a!==null||(i=s.element.offsetWidth,a=s.element.offsetHeight,s.previousW=i,s.previousH=a),(c=s.draw)==null||c.call(s,{width:i,height:a})};if(e){t&&this.setCornerOptions(e,t);const s=(n=this.elements)==null?void 0:n.get(e);s&&r(s)}else(o=this.elements)==null||o.forEach(r)}unobserve(e){var r;const t=n=>{var o,s;(o=this.observer)==null||o.unobserve(n),(s=this.elements)==null||s.delete(n)};e?t(e):(r=this.elements)==null||r.keys().forEach(n=>t(n))}};function Yt(e,t,r,n,o,s,i,a){if(r){const c=[];return e&&c.push(["c",...n]),o&&c.push(["a",r,r,0,0,t,...s.map(l=>l*o)]),e&&c.push(["c",...i]),c}return[["l",...a]]}const Hl=({width:e,height:t,radii:r,offsets:n,smoothing:o=1,preserveSmoothing:s=!0,sweepFlag:i=1})=>{const[a,,,c]=n,[l,u,d,p]=r.map(g=>function(v,h,b,y){let x=(1+h)*v;b||(h=Math.min(h,y/v-1),x=Math.min(x,y));const w=.5*Math.PI*(1-h),C=Math.sin(w/2)*v*2**.5,S=.25*Math.PI*h,A=v*Math.tan(.25*(.5*Math.PI-w))*Math.cos(S),R=A*Math.tan(S);let O=(x-C-A-R)/3,$=2*O;if(b&&x>y){const L=y-R-C-A,k=L-L/6;O=Math.min(O,k),$=L-O,x=Math.min(x,y)}return{a:$,b:O,c:A,d:R,p:x,arcLength:C,radius:v,ab:$+O,bc:O+A,abc:$+O+A}}(g,o,s,Math.max(g,.5*Math.min(e,t))));return[["M",e-u.p+c,a],...Yt(o,i,u.radius,[u.a,0,u.ab,0,u.abc,u.d],u.arcLength,[1,1],[u.d,u.c,u.d,u.bc,u.d,u.abc],[u.p,0]),["L",e+c,t-d.p+a],...Yt(o,i,d.radius,[0,d.a,0,d.ab,-d.d,d.abc],d.arcLength,[-1,1],[-d.c,d.d,-d.bc,d.d,-d.abc,d.d],[0,d.p]),["L",p.p+c,t+a],...Yt(o,i,p.radius,[-p.a,0,-p.ab,0,-p.abc,-p.d],p.arcLength,[-1,-1],[-p.d,-p.c,-p.d,-p.bc,-p.d,-p.abc],[-p.p,0]),["L",c,l.p+a],...Yt(o,i,l.radius,[0,-l.a,0,-l.ab,l.d,-l.abc],l.arcLength,[1,-1],[l.c,-l.d,l.bc,-l.d,l.abc,-l.d],[0,-l.p]),["Z"]]},lm=e=>Hl({...e,preserveSmoothing:!1,sweepFlag:1}),qr=e=>{const t=10**e;return r=>Math.round(r*t)/t};function cm({id:e,angle:t,colors:r,precision:n}){const o=qr(n),s=t*(Math.PI/180),i=Math.sin(s),a=-Math.cos(s),c=(i>=0?1:0)-.5,l=(a>=0?1:0)-.5,u=Math.abs(c*i+l*a);return`<linearGradient id="${e}" x1="${o(.5-u*i)}" y1="${o(.5-u*a)}" x2="${o(.5+u*i)}" y2="${o(.5+u*a)}" gradientUnits="objectBoundingBox">${function(d,p){const g=qr(p),v=d.map(y=>{const x=y.trim().split(/\s+/),w=x[0];let C=null;if(x.length>1){const S=x[1];C=S.includes("%")?parseFloat(S)/100:parseFloat(S)}return{color:w,val:C}}),h=v.length;v[0].val===null&&(v[0].val=0),v[h-1].val===null&&(v[h-1].val=1);let b=0;for(;b<h-1;){let y=b+1;for(;y<h&&v[y].val===null;)y++;if(y>b+1){const x=v[b].val,w=y-b,C=(v[y].val-x)/w;for(let S=1;S<w;S++)v[b+S].val=x+C*S}b=y}return v.map(y=>`<stop offset="${g(y.val)}" stop-color="${y.color}" />`).join("")}(r,n)}</linearGradient>`}const dm=/[\r\n"%#()<>?[\\\]^`{|}\s']/g,es={"\r":"","\n":""};function Kt({width:e=0,height:t=0,borderRadius:r=0,offset:n=0,smoothing:o=1,cornerType:s=Hl,precision:i=3,isArray:a=!1}){if(!e||!t)return a?[]:"";const c=Array.isArray(n)?n:[n,n,n,n],[l,u,d,p]=c,g=e-p-u,v=t-l-d;let h,b;if(Array.isArray(r)){const w=r.map((S,A)=>S+r[(A+1)%4]),C=Math.min(...w.map((S,A)=>(A%2==0?g:v)/S));h=C<1?r.map(S=>S*C):r}else h=[r,r,r,r].map((w,C)=>Math.max(0,Math.min(w-c[C],.5*Math.min(g,v))));b=s?s({width:g,height:v,radii:h,offsets:c,smoothing:o}):[[]];const y=qr(i);if(a)return b.filter(w=>w[0]).map(([w,...C])=>[w,...C.map(S=>typeof S=="number"?y(S):S)]);let x="";for(let w=0;w<b.length;w++){const C=b[w];if(C[0]){x+=C[0];for(let S=1;S<C.length;S++){const A=C[S];x+=(typeof A=="number"?y(A):A)+" "}}}return x.trim()}function um(e,t){Qt.setCornerOptions(e,t);const r=n=>{const o=Qt.getDrawOptions(e)??{},s={...o,...n};s.isRounded&&(s.width=s.width?Math.round(s.width):void 0,s.height=s.height?Math.round(s.height):void 0),s.width&&s.height&&(e.style.clipPath=o.clip?`path('${Kt(s)}')`:"",(o.background||o.border)&&(e.style.backgroundImage=function(i){const{border:a=[],offset:c=0,strokeDrawType:l=0,background:u,clip:d,idPrefix:p="m",width:g,height:v,precision:h=3}=i,b=[],y=Array.isArray(a==null?void 0:a[0])?a:[a],x=Array.isArray(c)?c:[c,c,c,c],w=d?null:Kt(i);let C;if(y!=null&&y.length){let S=0;const A=[];for(let R=0;R<y.length;R++)if(typeof y[R][1]=="number"){const[O,$,L]=y[R];if(O){const k=`${p}g${R}`;C||(C=[]),C.push(cm({id:k,angle:$,colors:L,precision:h}));const P=l===0?2*(S+O):O;A.push(`<path d="${Kt({...i,offset:l===0?c:x.map(_=>_+S+.5*O)})}" fill="none" stroke="url(#${k})" stroke-width="${P}" />`),S+=O}}else{const[O,$]=y[R];if(O){const L=l===0?2*(S+O):O;A.push(`<path d="${Kt({...i,offset:l===0?c:x.map(k=>k+S+.5*O)})}" fill="none" stroke="${$}" stroke-width="${L}" />`),S+=O}}u&&(d?b.push(`<rect width="${g}" height="${v}" fill="${u}" />`):b.push(`<path d="${w}" fill="${u}" />`)),b.push(...A.reverse())}return b.length?(({paths:S,gradients:A,clipPath:R,idPrefix:O})=>{const $=`${O}c`,L=[],k=[];return A&&A.forEach(_=>{L.push(_)}),R&&L.push(`<clipPath id="${$}"><path d="${R}" /></clipPath>`),L.length&&k.push(`<defs>${L.join("")}</defs>`),R?k.push(`<g clip-path="url(#${$})">${S.join("")}</g>`):k.push(...S),`url('data:image/svg+xml,${(_=>_.replace(dm,I=>es[I]??(es[I]=`%${I.charCodeAt(0).toString(16).toUpperCase()}`)))((P=k.join(""),`<svg xmlns="http://www.w3.org/2000/svg">${P}</svg>`))}')`;var P})({paths:b,clipPath:w,gradients:C,idPrefix:p}):"none"}(s)))};return r(),Qt.addElement(e,t,r)}function fm(e){Qt.unobserve(e)}const Gl=E.forwardRef(({cornerRadius:e=12,cornerSmoothing:t=1,borderWidth:r,borderColor:n="transparent",className:o,children:s,...i},a)=>{const c=E.useRef(null),l=u=>{c.current=u,typeof a=="function"?a(u):a&&(a.current=u)};return E.useEffect(()=>{const u=c.current;if(!u)return;const d={borderRadius:e,smoothing:t,cornerType:lm,clip:!0,observe:!0};return r&&(d.border=[r,n]),um(u,d),()=>{fm(u)}},[e,t,r,n]),m.jsx("div",{ref:l,className:G("overflow-hidden",o),...i,children:s})});Gl.displayName="Squircle";const pm="0.2.10";exports.Accordion=lu;exports.AccordionContent=ii;exports.AccordionItem=oi;exports.AccordionTrigger=si;exports.Alert=Ps;exports.AlertDescription=Ts;exports.AlertDialog=rm;exports.AlertDialogAction=Fl;exports.AlertDialogCancel=Vl;exports.AlertDialogContent=jl;exports.AlertDialogDescription=Bl;exports.AlertDialogFooter=$l;exports.AlertDialogHeader=Ll;exports.AlertDialogOverlay=kn;exports.AlertDialogPortal=_l;exports.AlertDialogTitle=zl;exports.AlertDialogTrigger=nm;exports.AlertTitle=ks;exports.Badge=js;exports.Button=ys;exports.Card=bs;exports.CardContent=Ss;exports.CardDescription=Cs;exports.CardHeader=xs;exports.CardTitle=ws;exports.Checkbox=ml;exports.CodeSample=om;exports.Dialog=jf;exports.DialogClose=$f;exports.DialogContent=Wi;exports.DialogDescription=Yi;exports.DialogFooter=Gi;exports.DialogHeader=Hi;exports.DialogOverlay=yn;exports.DialogPortal=Vi;exports.DialogTitle=Ui;exports.DialogTrigger=Lf;exports.DiscLoader=Is;exports.Form=Os;exports.FormField=_s;exports.Input=Es;exports.Label=Ns;exports.LinkCopyButton=sm;exports.Select=Lh;exports.SelectContent=ol;exports.SelectGroup=$h;exports.SelectItem=il;exports.SelectLabel=sl;exports.SelectSeparator=al;exports.SelectTrigger=tl;exports.SelectValue=zh;exports.Separator=Ls;exports.Spinner=Ms;exports.Squircle=Gl;exports.Textarea=Ds;exports.ThumbnailCard=Wl;exports.ThumbnailPreviewOverlay=im;exports.ThumbnailStrip=am;exports.Toaster=Md;exports.UI_LIBRARY_VERSION=pm;exports.cn=G;exports.toast=Dt;
148
+ `,children:["+",a]})]})}var Qt=new class{constructor(){Je(this,"elements");Je(this,"observer");Je(this,"rafID",null);Je(this,"queue",[]);Je(this,"resizePrecisionPower",1);Je(this,"getDrawOptions",e=>{var t,r;return((r=(t=this.elements)==null?void 0:t.get(e))==null?void 0:r.cornerOptions)??null});this.elements=null,this.observer=null}onElementResize(e){this.queue.push(...e),this.rafID||(this.rafID=requestAnimationFrame(()=>this.flushQueue()))}flushQueue(){const e=new Map;for(const t of this.queue)e.set(t.target,t);this.queue=[],e.forEach((t,r)=>{var u;if(!r.isConnected)return void this.unobserve(r);const n=(u=this.elements)==null?void 0:u.get(r);if(!n)return;let{inlineSize:o,blockSize:s}=t.borderBoxSize[0];n.cornerOptions.isRounded&&(o=Math.round(o),s=Math.round(s));const{previousW:i,previousH:a,draw:c,onResize:l}=n;i===o&&a===s||(c==null||c({width:o,height:s}),l==null||l({width:o,height:s},t.target),n.previousW=o,n.previousH=s)}),this.rafID=null}setCornerOptions(e,t){var n,o;const r=(n=this.elements)==null?void 0:n.get(e);r&&(r.cornerOptions=t,(o=this.elements)==null||o.set(e,r))}addElement(e,t,r){this.elements||(this.elements=new Map),this.observer||(this.observer=new ResizeObserver(s=>this.onElementResize(s))),this.unobserve(e);const{observe:n=!0,onResize:o}=t;return n&&(this.elements.set(e,{draw:r,cornerOptions:t,onResize:o,previousW:null,previousH:null,element:e}),this.observer.observe(e)),r}draw(e,t){var n,o;const r=s=>{var c;if(!s.element.isConnected)return;let{previousW:i,previousH:a}=s;i!==null&&a!==null||(i=s.element.offsetWidth,a=s.element.offsetHeight,s.previousW=i,s.previousH=a),(c=s.draw)==null||c.call(s,{width:i,height:a})};if(e){t&&this.setCornerOptions(e,t);const s=(n=this.elements)==null?void 0:n.get(e);s&&r(s)}else(o=this.elements)==null||o.forEach(r)}unobserve(e){var r;const t=n=>{var o,s;(o=this.observer)==null||o.unobserve(n),(s=this.elements)==null||s.delete(n)};e?t(e):(r=this.elements)==null||r.keys().forEach(n=>t(n))}};function Yt(e,t,r,n,o,s,i,a){if(r){const c=[];return e&&c.push(["c",...n]),o&&c.push(["a",r,r,0,0,t,...s.map(l=>l*o)]),e&&c.push(["c",...i]),c}return[["l",...a]]}const Hl=({width:e,height:t,radii:r,offsets:n,smoothing:o=1,preserveSmoothing:s=!0,sweepFlag:i=1})=>{const[a,,,c]=n,[l,u,d,p]=r.map(g=>function(v,h,b,y){let x=(1+h)*v;b||(h=Math.min(h,y/v-1),x=Math.min(x,y));const w=.5*Math.PI*(1-h),C=Math.sin(w/2)*v*2**.5,S=.25*Math.PI*h,A=v*Math.tan(.25*(.5*Math.PI-w))*Math.cos(S),R=A*Math.tan(S);let O=(x-C-A-R)/3,$=2*O;if(b&&x>y){const L=y-R-C-A,k=L-L/6;O=Math.min(O,k),$=L-O,x=Math.min(x,y)}return{a:$,b:O,c:A,d:R,p:x,arcLength:C,radius:v,ab:$+O,bc:O+A,abc:$+O+A}}(g,o,s,Math.max(g,.5*Math.min(e,t))));return[["M",e-u.p+c,a],...Yt(o,i,u.radius,[u.a,0,u.ab,0,u.abc,u.d],u.arcLength,[1,1],[u.d,u.c,u.d,u.bc,u.d,u.abc],[u.p,0]),["L",e+c,t-d.p+a],...Yt(o,i,d.radius,[0,d.a,0,d.ab,-d.d,d.abc],d.arcLength,[-1,1],[-d.c,d.d,-d.bc,d.d,-d.abc,d.d],[0,d.p]),["L",p.p+c,t+a],...Yt(o,i,p.radius,[-p.a,0,-p.ab,0,-p.abc,-p.d],p.arcLength,[-1,-1],[-p.d,-p.c,-p.d,-p.bc,-p.d,-p.abc],[-p.p,0]),["L",c,l.p+a],...Yt(o,i,l.radius,[0,-l.a,0,-l.ab,l.d,-l.abc],l.arcLength,[1,-1],[l.c,-l.d,l.bc,-l.d,l.abc,-l.d],[0,-l.p]),["Z"]]},lm=e=>Hl({...e,preserveSmoothing:!1,sweepFlag:1}),qr=e=>{const t=10**e;return r=>Math.round(r*t)/t};function cm({id:e,angle:t,colors:r,precision:n}){const o=qr(n),s=t*(Math.PI/180),i=Math.sin(s),a=-Math.cos(s),c=(i>=0?1:0)-.5,l=(a>=0?1:0)-.5,u=Math.abs(c*i+l*a);return`<linearGradient id="${e}" x1="${o(.5-u*i)}" y1="${o(.5-u*a)}" x2="${o(.5+u*i)}" y2="${o(.5+u*a)}" gradientUnits="objectBoundingBox">${function(d,p){const g=qr(p),v=d.map(y=>{const x=y.trim().split(/\s+/),w=x[0];let C=null;if(x.length>1){const S=x[1];C=S.includes("%")?parseFloat(S)/100:parseFloat(S)}return{color:w,val:C}}),h=v.length;v[0].val===null&&(v[0].val=0),v[h-1].val===null&&(v[h-1].val=1);let b=0;for(;b<h-1;){let y=b+1;for(;y<h&&v[y].val===null;)y++;if(y>b+1){const x=v[b].val,w=y-b,C=(v[y].val-x)/w;for(let S=1;S<w;S++)v[b+S].val=x+C*S}b=y}return v.map(y=>`<stop offset="${g(y.val)}" stop-color="${y.color}" />`).join("")}(r,n)}</linearGradient>`}const dm=/[\r\n"%#()<>?[\\\]^`{|}\s']/g,es={"\r":"","\n":""};function Kt({width:e=0,height:t=0,borderRadius:r=0,offset:n=0,smoothing:o=1,cornerType:s=Hl,precision:i=3,isArray:a=!1}){if(!e||!t)return a?[]:"";const c=Array.isArray(n)?n:[n,n,n,n],[l,u,d,p]=c,g=e-p-u,v=t-l-d;let h,b;if(Array.isArray(r)){const w=r.map((S,A)=>S+r[(A+1)%4]),C=Math.min(...w.map((S,A)=>(A%2==0?g:v)/S));h=C<1?r.map(S=>S*C):r}else h=[r,r,r,r].map((w,C)=>Math.max(0,Math.min(w-c[C],.5*Math.min(g,v))));b=s?s({width:g,height:v,radii:h,offsets:c,smoothing:o}):[[]];const y=qr(i);if(a)return b.filter(w=>w[0]).map(([w,...C])=>[w,...C.map(S=>typeof S=="number"?y(S):S)]);let x="";for(let w=0;w<b.length;w++){const C=b[w];if(C[0]){x+=C[0];for(let S=1;S<C.length;S++){const A=C[S];x+=(typeof A=="number"?y(A):A)+" "}}}return x.trim()}function um(e,t){Qt.setCornerOptions(e,t);const r=n=>{const o=Qt.getDrawOptions(e)??{},s={...o,...n};s.isRounded&&(s.width=s.width?Math.round(s.width):void 0,s.height=s.height?Math.round(s.height):void 0),s.width&&s.height&&(e.style.clipPath=o.clip?`path('${Kt(s)}')`:"",(o.background||o.border)&&(e.style.backgroundImage=function(i){const{border:a=[],offset:c=0,strokeDrawType:l=0,background:u,clip:d,idPrefix:p="m",width:g,height:v,precision:h=3}=i,b=[],y=Array.isArray(a==null?void 0:a[0])?a:[a],x=Array.isArray(c)?c:[c,c,c,c],w=d?null:Kt(i);let C;if(y!=null&&y.length){let S=0;const A=[];for(let R=0;R<y.length;R++)if(typeof y[R][1]=="number"){const[O,$,L]=y[R];if(O){const k=`${p}g${R}`;C||(C=[]),C.push(cm({id:k,angle:$,colors:L,precision:h}));const P=l===0?2*(S+O):O;A.push(`<path d="${Kt({...i,offset:l===0?c:x.map(_=>_+S+.5*O)})}" fill="none" stroke="url(#${k})" stroke-width="${P}" />`),S+=O}}else{const[O,$]=y[R];if(O){const L=l===0?2*(S+O):O;A.push(`<path d="${Kt({...i,offset:l===0?c:x.map(k=>k+S+.5*O)})}" fill="none" stroke="${$}" stroke-width="${L}" />`),S+=O}}u&&(d?b.push(`<rect width="${g}" height="${v}" fill="${u}" />`):b.push(`<path d="${w}" fill="${u}" />`)),b.push(...A.reverse())}return b.length?(({paths:S,gradients:A,clipPath:R,idPrefix:O})=>{const $=`${O}c`,L=[],k=[];return A&&A.forEach(_=>{L.push(_)}),R&&L.push(`<clipPath id="${$}"><path d="${R}" /></clipPath>`),L.length&&k.push(`<defs>${L.join("")}</defs>`),R?k.push(`<g clip-path="url(#${$})">${S.join("")}</g>`):k.push(...S),`url('data:image/svg+xml,${(_=>_.replace(dm,I=>es[I]??(es[I]=`%${I.charCodeAt(0).toString(16).toUpperCase()}`)))((P=k.join(""),`<svg xmlns="http://www.w3.org/2000/svg">${P}</svg>`))}')`;var P})({paths:b,clipPath:w,gradients:C,idPrefix:p}):"none"}(s)))};return r(),Qt.addElement(e,t,r)}function fm(e){Qt.unobserve(e)}const Gl=E.forwardRef(({cornerRadius:e=12,cornerSmoothing:t=1,borderWidth:r,borderColor:n="transparent",className:o,children:s,...i},a)=>{const c=E.useRef(null),l=u=>{c.current=u,typeof a=="function"?a(u):a&&(a.current=u)};return E.useEffect(()=>{const u=c.current;if(!u)return;const d={borderRadius:e,smoothing:t,cornerType:lm,clip:!0,observe:!0};return r&&(d.border=[r,n]),um(u,d),()=>{fm(u)}},[e,t,r,n]),m.jsx("div",{ref:l,className:G("overflow-hidden",o),...i,children:s})});Gl.displayName="Squircle";const pm="0.2.11";exports.Accordion=lu;exports.AccordionContent=ii;exports.AccordionItem=oi;exports.AccordionTrigger=si;exports.Alert=Ps;exports.AlertDescription=Ts;exports.AlertDialog=rm;exports.AlertDialogAction=Bl;exports.AlertDialogCancel=Vl;exports.AlertDialogContent=jl;exports.AlertDialogDescription=Fl;exports.AlertDialogFooter=$l;exports.AlertDialogHeader=Ll;exports.AlertDialogOverlay=kn;exports.AlertDialogPortal=_l;exports.AlertDialogTitle=zl;exports.AlertDialogTrigger=nm;exports.AlertTitle=ks;exports.Badge=js;exports.Button=ys;exports.Card=bs;exports.CardContent=Ss;exports.CardDescription=Cs;exports.CardHeader=xs;exports.CardTitle=ws;exports.Checkbox=ml;exports.CodeSample=om;exports.Dialog=jf;exports.DialogClose=$f;exports.DialogContent=Wi;exports.DialogDescription=Yi;exports.DialogFooter=Gi;exports.DialogHeader=Hi;exports.DialogOverlay=yn;exports.DialogPortal=Vi;exports.DialogTitle=Ui;exports.DialogTrigger=Lf;exports.DiscLoader=Is;exports.Form=Os;exports.FormField=_s;exports.Input=Es;exports.Label=Ns;exports.LinkCopyButton=sm;exports.Select=Lh;exports.SelectContent=ol;exports.SelectGroup=$h;exports.SelectItem=il;exports.SelectLabel=sl;exports.SelectSeparator=al;exports.SelectTrigger=tl;exports.SelectValue=zh;exports.Separator=Ls;exports.Spinner=Ms;exports.Squircle=Gl;exports.Textarea=Ds;exports.ThumbnailCard=Wl;exports.ThumbnailPreviewOverlay=im;exports.ThumbnailStrip=am;exports.Toaster=Md;exports.UI_LIBRARY_VERSION=pm;exports.cn=G;exports.toast=Dt;
package/dist/index.mjs CHANGED
@@ -4792,19 +4792,21 @@ const ud = /* @__PURE__ */ R.forwardRef(function(t, r) {
4792
4792
  });
4793
4793
  })) : null;
4794
4794
  }));
4795
- }), pm = ({ ...e }) => /* @__PURE__ */ b(
4795
+ }), pm = ({ closeButton: e = !0, ...t }) => /* @__PURE__ */ b(
4796
4796
  ud,
4797
4797
  {
4798
4798
  className: "toaster group",
4799
+ closeButton: e,
4799
4800
  toastOptions: {
4800
4801
  classNames: {
4801
4802
  toast: "group toast group-[.toaster]:bg-white group-[.toaster]:text-[#2C2825] group-[.toaster]:border-white/20 group-[.toaster]:shadow-xl group-[.toaster]:backdrop-blur-md group-[.toaster]:rounded-2xl font-sans-body",
4802
4803
  description: "group-[.toast]:text-[#7A7570] font-sans-body",
4803
4804
  actionButton: "group-[.toast]:bg-[#FF6B4A] group-[.toast]:text-white group-[.toast]:rounded-xl font-medium",
4804
- cancelButton: "group-[.toast]:bg-[#F4F4F1] group-[.toast]:text-[#7A7570] group-[.toast]:rounded-xl"
4805
+ cancelButton: "group-[.toast]:bg-[#F4F4F1] group-[.toast]:text-[#7A7570] group-[.toast]:rounded-xl",
4806
+ closeButton: "group-[.toast]:text-[#7A7570] group-[.toast]:hover:text-[#2C2825] group-[.toast]:hover:bg-[#F4F4F1] group-[.toast]:rounded-lg"
4805
4807
  }
4806
4808
  },
4807
- ...e
4809
+ ...t
4808
4810
  }
4809
4811
  ), fd = f.forwardRef(
4810
4812
  ({ className: e, ...t }, r) => /* @__PURE__ */ b(
@@ -10204,7 +10206,7 @@ const am = R.forwardRef(
10204
10206
  }
10205
10207
  );
10206
10208
  am.displayName = "Squircle";
10207
- const Nm = "0.2.10";
10209
+ const Nm = "0.2.11";
10208
10210
  export {
10209
10211
  hm as Accordion,
10210
10212
  Yd as AccordionContent,
@@ -2,5 +2,5 @@ import { Toaster as Sonner, toast } from 'sonner';
2
2
 
3
3
  import * as React from "react";
4
4
  type ToasterProps = React.ComponentProps<typeof Sonner>;
5
- declare const Toaster: ({ ...props }: ToasterProps) => import("react/jsx-runtime").JSX.Element;
5
+ declare const Toaster: ({ closeButton, ...props }: ToasterProps) => import("react/jsx-runtime").JSX.Element;
6
6
  export { Toaster, toast };
@@ -36,4 +36,4 @@ export type { ThumbnailCardProps } from './components/thumbnail-card';
36
36
  export type { ThumbnailPreviewOverlayProps } from './components/thumbnail-preview';
37
37
  export type { ThumbnailStripProps, ThumbnailData as UIThumbnailData } from './components/thumbnail-strip';
38
38
  export { cn } from './lib/utils';
39
- export declare const UI_LIBRARY_VERSION = "0.2.10";
39
+ export declare const UI_LIBRARY_VERSION = "0.2.11";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@memoreco/ui",
3
- "version": "0.2.10",
3
+ "version": "0.2.11",
4
4
  "description": "Memoreco shared UI components with Shadcn",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.mjs",
@@ -16,19 +16,6 @@
16
16
  "files": [
17
17
  "dist"
18
18
  ],
19
- "scripts": {
20
- "dev": "vite build --watch",
21
- "build": "vite build",
22
- "lint": "eslint src/ --ext .ts,.tsx",
23
- "lint:fix": "eslint src/ --ext .ts,.tsx --fix",
24
- "type-check": "tsc --noEmit",
25
- "test": "vitest --run --passWithNoTests",
26
- "test:ui": "vitest --ui",
27
- "clean": "rimraf dist",
28
- "release:check": "pnpm run lint && pnpm run type-check && pnpm run test && pnpm run build",
29
- "release:publish": "node scripts/publish.mjs",
30
- "prepublishOnly": "pnpm run release:check"
31
- },
32
19
  "dependencies": {
33
20
  "@monokai/monoco": "^0.3.2",
34
21
  "@radix-ui/react-accordion": "^1.2.11",
@@ -45,8 +32,6 @@
45
32
  "tailwind-merge": "^2.2.1"
46
33
  },
47
34
  "devDependencies": {
48
- "@memoreco/types": "workspace:*",
49
- "@memoreco/utils": "workspace:*",
50
35
  "@types/node": "^20.19.17",
51
36
  "@types/react": "^19.1.12",
52
37
  "@types/react-dom": "^19.1.9",
@@ -60,11 +45,25 @@
60
45
  "typescript": "^5.9.2",
61
46
  "vite": "^5.0.12",
62
47
  "vite-plugin-dts": "^3.7.2",
63
- "vitest": "^1.2.2"
48
+ "vitest": "^1.2.2",
49
+ "@memoreco/types": "0.2.0",
50
+ "@memoreco/utils": "0.2.0"
64
51
  },
65
52
  "peerDependencies": {
66
53
  "react": ">=18.0.0",
67
54
  "react-dom": ">=18.0.0"
68
55
  },
69
- "sideEffects": false
56
+ "sideEffects": false,
57
+ "scripts": {
58
+ "dev": "vite build --watch",
59
+ "build": "vite build",
60
+ "lint": "eslint src/ --ext .ts,.tsx",
61
+ "lint:fix": "eslint src/ --ext .ts,.tsx --fix",
62
+ "type-check": "tsc --noEmit",
63
+ "test": "vitest --run --passWithNoTests",
64
+ "test:ui": "vitest --ui",
65
+ "clean": "rimraf dist",
66
+ "release:check": "pnpm run lint && pnpm run type-check && pnpm run test && pnpm run build",
67
+ "release:publish": "node scripts/publish.mjs"
68
+ }
70
69
  }