@mesh.ai/rabbit 1.4.0 → 1.4.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -4795,7 +4795,7 @@ const Ew = Y(
4795
4795
  ({ className: e, ...t }, n) => /* @__PURE__ */ g("p", { ref: n, className: ve("text-sm text-font-secondary", e), ...t })
4796
4796
  );
4797
4797
  Ew.displayName = "CardDescription";
4798
- const Tw = Y(({ className: e, ...t }, n) => /* @__PURE__ */ g("div", { ref: n, className: ve("text-sm", e), ...t }));
4798
+ const Tw = Y(({ className: e, ...t }, n) => /* @__PURE__ */ g("div", { ref: n, className: ve("text-sm w-full", e), ...t }));
4799
4799
  Tw.displayName = "CardContent";
4800
4800
  const Pw = Ke(
4801
4801
  "rabbit-ds box-border inline-flex h-auto min-h-8 w-full flex-row items-center justify-start gap-1 rounded-lg bg-white p-1 text-xs",
@@ -3,7 +3,7 @@
3
3
  - less than the value passed to \`max\` (or ${ka} if no \`max\` prop is set)
4
4
  - \`null\` if the progress is indeterminate.
5
5
 
6
- Defaulting to \`null\`.`}const o2=jf,a2=e2;var yo=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function kr(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function Or(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var Na={},Aa={};Object.defineProperty(Aa,"__esModule",{value:!0}),Aa.defaultOptions=void 0,Aa.defaultOptions={lowercase:!1,precision:1,space:!1,units:["","K","M","B","T","P","E"]};var Qt={};Object.defineProperty(Qt,"__esModule",{value:!0}),Qt.getLocales=Qt.getFractionDigits=Qt.roundTo=Qt.parseValue=void 0;function i2(e){const t=parseFloat(e==null?void 0:e.toString());if(isNaN(t))throw new Error("Input value is not a number");if(t>Number.MAX_SAFE_INTEGER||t<Number.MIN_SAFE_INTEGER)throw new RangeError("Input value is outside of safe integer range");return t}Qt.parseValue=i2;function s2(e,t){if(!Number.isFinite(e))throw new Error("Input value is not a finite number");if(!Number.isInteger(t)||t<0)throw new Error("Precision is not a positive integer");return Number.isInteger(e)?e:parseFloat(e.toFixed(t))}Qt.roundTo=s2;function l2(e){var t;if(Number.isInteger(e))return 0;const n=e.toString().split(".")[1];return(t=n==null?void 0:n.length)!==null&&t!==void 0?t:0}Qt.getFractionDigits=l2;function c2(){var e;return typeof navigator>"u"?[]:Array.from((e=navigator.languages)!==null&&e!==void 0?e:[])}Qt.getLocales=c2,Object.defineProperty(Na,"__esModule",{value:!0}),Na.millify=void 0;const Vf=Aa,Da=Qt,Hf=1e3;function*Gf(e){let t=Hf;for(;;){const n=e/t;if(n<1)return;yield n,t*=Hf}}function Uf(e,t){var n,r;const o=t?{...Vf.defaultOptions,...t}:Vf.defaultOptions;if(!Array.isArray(o.units)||!o.units.length)throw new Error("Option `units` must be a non-empty array");let a;try{a=Da.parseValue(e)}catch(h){return h instanceof Error&&console.warn(`WARN: ${h.message} (millify)`),String(e)}const i=a<0?"-":"";a=Math.abs(a);let s=0;for(const h of Gf(a))a=h,s+=1;if(s>=o.units.length)return e.toString();let c=Da.roundTo(a,o.precision);for(const h of Gf(c))c=h,s+=1;const f=(n=o.units[s])!==null&&n!==void 0?n:"",d=o.lowercase?f.toLowerCase():f,p=o.space?" ":"",v=c.toLocaleString((r=o.locales)!==null&&r!==void 0?r:Da.getLocales(),{minimumFractionDigits:Da.getFractionDigits(c)});return`${i}${v}${p}${d}`}Na.millify=Uf;var _a=Na.default=Uf,Ze=(e=>(e.CLOSED_ACHIEVED="CLOSED_ACHIEVED",e.CLOSED_DROPPED="CLOSED_DROPPED",e.CLOSED_NOT_ACHIEVED="CLOSED_NOT_ACHIEVED",e.ON_TRACK="ON_TRACK",e.OFF_TRACK="OFF_TRACK",e.AT_RISK="AT_RISK",e))(Ze||{});const Nr={[Ze.ON_TRACK]:{backgroundColor:"#EAEAEA",indicatorColor:"#EFFFEA",textColor:"#44812F"},[Ze.OFF_TRACK]:{backgroundColor:"#EAEAEA",indicatorColor:"#FFF6D3",textColor:"#8C6A00"},[Ze.AT_RISK]:{backgroundColor:"#EAEAEA",indicatorColor:"#FFF1E4",textColor:"#C62C02"},[Ze.CLOSED_ACHIEVED]:{backgroundColor:"#EAEAEA",indicatorColor:"#DBF2D3",textColor:"#1A5724"},[Ze.CLOSED_DROPPED]:{backgroundColor:"#EAEAEA",indicatorColor:"#CCCCCC",textColor:"#666666"},[Ze.CLOSED_NOT_ACHIEVED]:{backgroundColor:"#EAEAEA",indicatorColor:"#FFE1D9",textColor:"#A12402"}},Xs={[Ze.ON_TRACK]:"On-track",[Ze.OFF_TRACK]:"Off-track",[Ze.AT_RISK]:"At-risk",[Ze.CLOSED_ACHIEVED]:"Closed & achieved",[Ze.CLOSED_DROPPED]:"Closed & dropped",[Ze.CLOSED_NOT_ACHIEVED]:"Closed & not achieved"};function Yf({progressInPercentage:e=0,status:t=Ze.ON_TRACK}){const{backgroundColor:n,indicatorColor:r,textColor:o}=Nr[t]?Nr[t]:Nr[Ze.ON_TRACK];return m.jsxs(o2,{className:"rabbit-ds relative box-border inline-flex h-5 w-full min-w-[210px] items-start justify-start overflow-hidden rounded-md",style:{transform:"translateZ(0)",backgroundColor:n},value:e,children:[m.jsx(a2,{className:"duration-[660ms] ease-[cubic-bezier(0.65,0,0.35,1)] h-full w-full transition-transform",style:{transform:`translateX(-${100-e>100?100:100-e}%)`,backgroundColor:r}}),m.jsx("div",{className:"absolute left-0 top-0 inline-flex items-center justify-start",children:m.jsx("div",{className:"inline-flex items-center justify-start px-1 py-0.5",children:m.jsx("div",{className:"text-xs font-semibold",style:{color:o},children:Xs[t]?Xs[t]:Xs[Ze.ON_TRACK]})})}),m.jsx("div",{className:"absolute right-0 top-0 inline-flex items-center justify-start px-1 py-0.5",children:m.jsxs("div",{className:"text-right text-xs font-semibold",style:{color:o},children:[_a(e),"%"]})})]})}function Ia(e,[t,n]){return Math.min(n,Math.max(t,e))}const u2=u.createContext(void 0);function Pn(e){const t=u.useContext(u2);return e||t||"ltr"}function ar(e){const t=e+"CollectionProvider",[n,r]=it(t),[o,a]=n(t,{collectionRef:{current:null},itemMap:new Map}),i=v=>{const{scope:h,children:g}=v,w=u.useRef(null),x=u.useRef(new Map).current;return u.createElement(o,{scope:h,itemMap:x,collectionRef:w},g)},s=e+"CollectionSlot",l=u.forwardRef((v,h)=>{const{scope:g,children:w}=v,x=a(s,g),y=Ee(h,x.collectionRef);return u.createElement(Mn,{ref:y},w)}),c=e+"CollectionItemSlot",f="data-radix-collection-item",d=u.forwardRef((v,h)=>{const{scope:g,children:w,...x}=v,y=u.useRef(null),b=Ee(h,y),S=a(c,g);return u.useEffect(()=>(S.itemMap.set(y,{ref:y,...x}),()=>void S.itemMap.delete(y))),u.createElement(Mn,{[f]:"",ref:b},w)});function p(v){const h=a(e+"CollectionConsumer",v);return u.useCallback(()=>{const w=h.collectionRef.current;if(!w)return[];const x=Array.from(w.querySelectorAll(`[${f}]`));return Array.from(h.itemMap.values()).sort((S,$)=>x.indexOf(S.ref.current)-x.indexOf($.ref.current))},[h.collectionRef,h.itemMap])}return[{Provider:i,Slot:l,ItemSlot:d},p,r]}const qf=["PageUp","PageDown"],Kf=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],Xf={"from-left":["Home","PageDown","ArrowDown","ArrowLeft"],"from-right":["Home","PageDown","ArrowDown","ArrowRight"],"from-bottom":["Home","PageDown","ArrowDown","ArrowLeft"],"from-top":["Home","PageDown","ArrowUp","ArrowLeft"]},xo="Slider",[Qs,d2,f2]=ar(xo),[Qf,NI]=it(xo,[f2]),[p2,La]=Qf(xo),h2=u.forwardRef((e,t)=>{const{name:n,min:r=0,max:o=100,step:a=1,orientation:i="horizontal",disabled:s=!1,minStepsBetweenThumbs:l=0,defaultValue:c=[r],value:f,onValueChange:d=()=>{},onValueCommit:p=()=>{},inverted:v=!1,...h}=e,[g,w]=u.useState(null),x=Ee(t,F=>w(F)),y=u.useRef(new Set),b=u.useRef(0),S=i==="horizontal",$=g?!!g.closest("form"):!0,M=S?m2:g2,[k=[],P]=st({prop:f,defaultProp:c,onChange:F=>{var E;(E=[...y.current][b.current])===null||E===void 0||E.focus(),d(F)}}),T=u.useRef(k);function I(F){const E=E2(k,F);B(F,E)}function j(F){B(F,b.current)}function z(){const F=T.current[b.current];k[b.current]!==F&&p(k)}function B(F,E,{commit:A}={commit:!1}){const W=k2(a),G=O2(Math.round((F-r)/a)*a+r,W),D=Ia(G,[r,o]);P((_=[])=>{const V=C2(_,D,E);if(P2(V,l*a)){b.current=V.indexOf(D);const te=String(V)!==String(_);return te&&A&&p(V),te?V:_}else return _})}return u.createElement(p2,{scope:e.__scopeSlider,disabled:s,min:r,max:o,valueIndexToChangeRef:b,thumbs:y.current,values:k,orientation:i},u.createElement(Qs.Provider,{scope:e.__scopeSlider},u.createElement(Qs.Slot,{scope:e.__scopeSlider},u.createElement(M,K({"aria-disabled":s,"data-disabled":s?"":void 0},h,{ref:x,onPointerDown:de(h.onPointerDown,()=>{s||(T.current=k)}),min:r,max:o,inverted:v,onSlideStart:s?void 0:I,onSlideMove:s?void 0:j,onSlideEnd:s?void 0:z,onHomeKeyDown:()=>!s&&B(r,0,{commit:!0}),onEndKeyDown:()=>!s&&B(o,k.length-1,{commit:!0}),onStepKeyDown:({event:F,direction:E})=>{if(!s){const G=qf.includes(F.key)||F.shiftKey&&Kf.includes(F.key)?10:1,D=b.current,_=k[D],V=a*G*E;B(_+V,D,{commit:!0})}}})))),$&&k.map((F,E)=>u.createElement($2,{key:E,name:n?n+(k.length>1?"[]":""):void 0,value:F})))}),[Zf,Jf]=Qf(xo,{startEdge:"left",endEdge:"right",size:"width",direction:1}),m2=u.forwardRef((e,t)=>{const{min:n,max:r,dir:o,inverted:a,onSlideStart:i,onSlideMove:s,onSlideEnd:l,onStepKeyDown:c,...f}=e,[d,p]=u.useState(null),v=Ee(t,b=>p(b)),h=u.useRef(),g=Pn(o),w=g==="ltr",x=w&&!a||!w&&a;function y(b){const S=h.current||d.getBoundingClientRect(),$=[0,S.width],k=Zs($,x?[n,r]:[r,n]);return h.current=S,k(b-S.left)}return u.createElement(Zf,{scope:e.__scopeSlider,startEdge:x?"left":"right",endEdge:x?"right":"left",direction:x?1:-1,size:"width"},u.createElement(Rf,K({dir:g,"data-orientation":"horizontal"},f,{ref:v,style:{...f.style,"--radix-slider-thumb-transform":"translateX(-50%)"},onSlideStart:b=>{const S=y(b.clientX);i==null||i(S)},onSlideMove:b=>{const S=y(b.clientX);s==null||s(S)},onSlideEnd:()=>{h.current=void 0,l==null||l()},onStepKeyDown:b=>{const $=Xf[x?"from-left":"from-right"].includes(b.key);c==null||c({event:b,direction:$?-1:1})}})))}),g2=u.forwardRef((e,t)=>{const{min:n,max:r,inverted:o,onSlideStart:a,onSlideMove:i,onSlideEnd:s,onStepKeyDown:l,...c}=e,f=u.useRef(null),d=Ee(t,f),p=u.useRef(),v=!o;function h(g){const w=p.current||f.current.getBoundingClientRect(),x=[0,w.height],b=Zs(x,v?[r,n]:[n,r]);return p.current=w,b(g-w.top)}return u.createElement(Zf,{scope:e.__scopeSlider,startEdge:v?"bottom":"top",endEdge:v?"top":"bottom",size:"height",direction:v?1:-1},u.createElement(Rf,K({"data-orientation":"vertical"},c,{ref:d,style:{...c.style,"--radix-slider-thumb-transform":"translateY(50%)"},onSlideStart:g=>{const w=h(g.clientY);a==null||a(w)},onSlideMove:g=>{const w=h(g.clientY);i==null||i(w)},onSlideEnd:()=>{p.current=void 0,s==null||s()},onStepKeyDown:g=>{const x=Xf[v?"from-bottom":"from-top"].includes(g.key);l==null||l({event:g,direction:x?-1:1})}})))}),Rf=u.forwardRef((e,t)=>{const{__scopeSlider:n,onSlideStart:r,onSlideMove:o,onSlideEnd:a,onHomeKeyDown:i,onEndKeyDown:s,onStepKeyDown:l,...c}=e,f=La(xo,n);return u.createElement(ve.span,K({},c,{ref:t,onKeyDown:de(e.onKeyDown,d=>{d.key==="Home"?(i(d),d.preventDefault()):d.key==="End"?(s(d),d.preventDefault()):qf.concat(Kf).includes(d.key)&&(l(d),d.preventDefault())}),onPointerDown:de(e.onPointerDown,d=>{const p=d.target;p.setPointerCapture(d.pointerId),d.preventDefault(),f.thumbs.has(p)?p.focus():r(d)}),onPointerMove:de(e.onPointerMove,d=>{d.target.hasPointerCapture(d.pointerId)&&o(d)}),onPointerUp:de(e.onPointerUp,d=>{const p=d.target;p.hasPointerCapture(d.pointerId)&&(p.releasePointerCapture(d.pointerId),a(d))})}))}),v2="SliderTrack",b2=u.forwardRef((e,t)=>{const{__scopeSlider:n,...r}=e,o=La(v2,n);return u.createElement(ve.span,K({"data-disabled":o.disabled?"":void 0,"data-orientation":o.orientation},r,{ref:t}))}),ep="SliderRange",y2=u.forwardRef((e,t)=>{const{__scopeSlider:n,...r}=e,o=La(ep,n),a=Jf(ep,n),i=u.useRef(null),s=Ee(t,i),l=o.values.length,c=o.values.map(p=>np(p,o.min,o.max)),f=l>1?Math.min(...c):0,d=100-Math.max(...c);return u.createElement(ve.span,K({"data-orientation":o.orientation,"data-disabled":o.disabled?"":void 0},r,{ref:s,style:{...e.style,[a.startEdge]:f+"%",[a.endEdge]:d+"%"}}))}),tp="SliderThumb",x2=u.forwardRef((e,t)=>{const n=d2(e.__scopeSlider),[r,o]=u.useState(null),a=Ee(t,s=>o(s)),i=u.useMemo(()=>r?n().findIndex(s=>s.ref.current===r):-1,[n,r]);return u.createElement(w2,K({},e,{ref:a,index:i}))}),w2=u.forwardRef((e,t)=>{const{__scopeSlider:n,index:r,...o}=e,a=La(tp,n),i=Jf(tp,n),[s,l]=u.useState(null),c=Ee(t,w=>l(w)),f=Vs(s),d=a.values[r],p=d===void 0?0:np(d,a.min,a.max),v=S2(r,a.values.length),h=f==null?void 0:f[i.size],g=h?M2(h,p,i.direction):0;return u.useEffect(()=>{if(s)return a.thumbs.add(s),()=>{a.thumbs.delete(s)}},[s,a.thumbs]),u.createElement("span",{style:{transform:"var(--radix-slider-thumb-transform)",position:"absolute",[i.startEdge]:`calc(${p}% + ${g}px)`}},u.createElement(Qs.ItemSlot,{scope:e.__scopeSlider},u.createElement(ve.span,K({role:"slider","aria-label":e["aria-label"]||v,"aria-valuemin":a.min,"aria-valuenow":d,"aria-valuemax":a.max,"aria-orientation":a.orientation,"data-orientation":a.orientation,"data-disabled":a.disabled?"":void 0,tabIndex:a.disabled?void 0:0},o,{ref:c,style:d===void 0?{display:"none"}:e.style,onFocus:de(e.onFocus,()=>{a.valueIndexToChangeRef.current=r})}))))}),$2=e=>{const{value:t,...n}=e,r=u.useRef(null),o=Sa(t);return u.useEffect(()=>{const a=r.current,i=window.HTMLInputElement.prototype,l=Object.getOwnPropertyDescriptor(i,"value").set;if(o!==t&&l){const c=new Event("input",{bubbles:!0});l.call(a,t),a.dispatchEvent(c)}},[o,t]),u.createElement("input",K({style:{display:"none"}},n,{ref:r,defaultValue:t}))};function C2(e=[],t,n){const r=[...e];return r[n]=t,r.sort((o,a)=>o-a)}function np(e,t,n){const a=100/(n-t)*(e-t);return Ia(a,[0,100])}function S2(e,t){return t>2?`Value ${e+1} of ${t}`:t===2?["Minimum","Maximum"][e]:void 0}function E2(e,t){if(e.length===1)return 0;const n=e.map(o=>Math.abs(o-t)),r=Math.min(...n);return n.indexOf(r)}function M2(e,t,n){const r=e/2,a=Zs([0,50],[0,r]);return(r-a(t)*n)*n}function T2(e){return e.slice(0,-1).map((t,n)=>e[n+1]-t)}function P2(e,t){if(t>0){const n=T2(e);return Math.min(...n)>=t}return!0}function Zs(e,t){return n=>{if(e[0]===e[1]||t[0]===t[1])return t[0];const r=(t[1]-t[0])/(e[1]-e[0]);return t[0]+r*(n-e[0])}}function k2(e){return(String(e).split(".")[1]||"").length}function O2(e,t){const n=Math.pow(10,t);return Math.round(e*n)/n}const N2=h2,A2=b2,D2=y2,_2=x2;function I2({startValue:e=0,targetValue:t=100,achievedValue:n=0,isReadOnly:r=!1,status:o=Ze.ON_TRACK,onChangeEnd:a=()=>{},onChange:i=()=>{},onThumbClick:s=()=>{}}){const[l,c]=u.useState(n),[f,d]=u.useState(n),p=u.useRef(!0),v=e>t,h=v?t:e,g=v?e:t,w=v?-1:1;u.useEffect(()=>{n!==l&&c(n)},[n]),u.useEffect(()=>{p.current?p.current=!1:a(f)},[f]),u.useEffect(()=>{i(l)},[l]);const x=S=>{c(v?t+e-S:S)},y=S=>{d(v?t+e-S:S)},b=Nr[o]?Nr[o]:Nr[Ze.ON_TRACK];return m.jsxs(N2,{className:"rabbit-ds relative box-border flex w-full min-w-[200px] touch-none select-none items-center",value:[v?t+e-l:l],min:h,max:g,step:w,inverted:h>g,disabled:r,onValueCommit:S=>y(S[0]),onValueChange:S=>x(S[0]),onLostPointerCapture:()=>{f!==l&&d(l)},children:[m.jsx(A2,{className:"relative h-7 grow rounded bg-[#EAEAEA]",children:m.jsx(D2,{className:"absolute h-full rounded-l bg-white",style:{backgroundColor:b.indicatorColor}})}),m.jsx(_2,{className:"block h-7 w-7 rounded-2xl bg-primary p-0.5 focus:outline-none ","aria-label":"Volume",style:{pointerEvents:r?"none":"auto"},onClick:s,children:m.jsx(Ve,{IconSVG:Pf,className:"text-white"})})]})}const L2=be["useId".toString()]||(()=>{});let F2=0;function $t(e){const[t,n]=be.useState(L2());return lt(()=>{e||n(r=>r??String(F2++))},[e]),e||(t?`radix-${t}`:"")}const rp="Collapsible",[z2,op]=it(rp),[j2,Js]=z2(rp),B2=u.forwardRef((e,t)=>{const{__scopeCollapsible:n,open:r,defaultOpen:o,disabled:a,onOpenChange:i,...s}=e,[l=!1,c]=st({prop:r,defaultProp:o,onChange:i});return u.createElement(j2,{scope:n,disabled:a,contentId:$t(),open:l,onOpenToggle:u.useCallback(()=>c(f=>!f),[c])},u.createElement(ve.div,K({"data-state":Rs(l),"data-disabled":a?"":void 0},s,{ref:t})))}),W2="CollapsibleTrigger",V2=u.forwardRef((e,t)=>{const{__scopeCollapsible:n,...r}=e,o=Js(W2,n);return u.createElement(ve.button,K({type:"button","aria-controls":o.contentId,"aria-expanded":o.open||!1,"data-state":Rs(o.open),"data-disabled":o.disabled?"":void 0,disabled:o.disabled},r,{ref:t,onClick:de(e.onClick,o.onOpenToggle)}))}),ap="CollapsibleContent",H2=u.forwardRef((e,t)=>{const{forceMount:n,...r}=e,o=Js(ap,e.__scopeCollapsible);return u.createElement(jt,{present:n||o.open},({present:a})=>u.createElement(G2,K({},r,{ref:t,present:a})))}),G2=u.forwardRef((e,t)=>{const{__scopeCollapsible:n,present:r,children:o,...a}=e,i=Js(ap,n),[s,l]=u.useState(r),c=u.useRef(null),f=Ee(t,c),d=u.useRef(0),p=d.current,v=u.useRef(0),h=v.current,g=i.open||s,w=u.useRef(g),x=u.useRef();return u.useEffect(()=>{const y=requestAnimationFrame(()=>w.current=!1);return()=>cancelAnimationFrame(y)},[]),lt(()=>{const y=c.current;if(y){x.current=x.current||{transitionDuration:y.style.transitionDuration,animationName:y.style.animationName},y.style.transitionDuration="0s",y.style.animationName="none";const b=y.getBoundingClientRect();d.current=b.height,v.current=b.width,w.current||(y.style.transitionDuration=x.current.transitionDuration,y.style.animationName=x.current.animationName),l(r)}},[i.open,r]),u.createElement(ve.div,K({"data-state":Rs(i.open),"data-disabled":i.disabled?"":void 0,id:i.contentId,hidden:!g},a,{ref:f,style:{"--radix-collapsible-content-height":p?`${p}px`:void 0,"--radix-collapsible-content-width":h?`${h}px`:void 0,...e.style}}),g&&o)});function Rs(e){return e?"open":"closed"}const U2=B2,Y2=V2,q2=H2,kn="Accordion",K2=["Home","End","ArrowDown","ArrowUp","ArrowLeft","ArrowRight"],[el,X2,Q2]=ar(kn),[Fa,AI]=it(kn,[Q2,op]),tl=op(),ip=u.forwardRef((e,t)=>{const{type:n,...r}=e,o=r,a=r;return u.createElement(el.Provider,{scope:e.__scopeAccordion},n==="multiple"?u.createElement(ew,K({},a,{ref:t})):u.createElement(R2,K({},o,{ref:t})))});ip.propTypes={type(e){const t=e.value||e.defaultValue;return e.type&&!["single","multiple"].includes(e.type)?new Error("Invalid prop `type` supplied to `Accordion`. Expected one of `single | multiple`."):e.type==="multiple"&&typeof t=="string"?new Error("Invalid prop `type` supplied to `Accordion`. Expected `single` when `defaultValue` or `value` is type `string`."):e.type==="single"&&Array.isArray(t)?new Error("Invalid prop `type` supplied to `Accordion`. Expected `multiple` when `defaultValue` or `value` is type `string[]`."):null}};const[sp,Z2]=Fa(kn),[lp,J2]=Fa(kn,{collapsible:!1}),R2=u.forwardRef((e,t)=>{const{value:n,defaultValue:r,onValueChange:o=()=>{},collapsible:a=!1,...i}=e,[s,l]=st({prop:n,defaultProp:r,onChange:o});return u.createElement(sp,{scope:e.__scopeAccordion,value:s?[s]:[],onItemOpen:l,onItemClose:u.useCallback(()=>a&&l(""),[a,l])},u.createElement(lp,{scope:e.__scopeAccordion,collapsible:a},u.createElement(cp,K({},i,{ref:t}))))}),ew=u.forwardRef((e,t)=>{const{value:n,defaultValue:r,onValueChange:o=()=>{},...a}=e,[i=[],s]=st({prop:n,defaultProp:r,onChange:o}),l=u.useCallback(f=>s((d=[])=>[...d,f]),[s]),c=u.useCallback(f=>s((d=[])=>d.filter(p=>p!==f)),[s]);return u.createElement(sp,{scope:e.__scopeAccordion,value:i,onItemOpen:l,onItemClose:c},u.createElement(lp,{scope:e.__scopeAccordion,collapsible:!0},u.createElement(cp,K({},a,{ref:t}))))}),[tw,za]=Fa(kn),cp=u.forwardRef((e,t)=>{const{__scopeAccordion:n,disabled:r,dir:o,orientation:a="vertical",...i}=e,s=u.useRef(null),l=Ee(s,t),c=X2(n),d=Pn(o)==="ltr",p=de(e.onKeyDown,v=>{var h;if(!K2.includes(v.key))return;const g=v.target,w=c().filter(T=>{var I;return!((I=T.ref.current)!==null&&I!==void 0&&I.disabled)}),x=w.findIndex(T=>T.ref.current===g),y=w.length;if(x===-1)return;v.preventDefault();let b=x;const S=0,$=y-1,M=()=>{b=x+1,b>$&&(b=S)},k=()=>{b=x-1,b<S&&(b=$)};switch(v.key){case"Home":b=S;break;case"End":b=$;break;case"ArrowRight":a==="horizontal"&&(d?M():k());break;case"ArrowDown":a==="vertical"&&M();break;case"ArrowLeft":a==="horizontal"&&(d?k():M());break;case"ArrowUp":a==="vertical"&&k();break}const P=b%y;(h=w[P].ref.current)===null||h===void 0||h.focus()});return u.createElement(tw,{scope:n,disabled:r,direction:o,orientation:a},u.createElement(el.Slot,{scope:n},u.createElement(ve.div,K({},i,{"data-orientation":a,ref:l,onKeyDown:r?void 0:p}))))}),nl="AccordionItem",[nw,rl]=Fa(nl),rw=u.forwardRef((e,t)=>{const{__scopeAccordion:n,value:r,...o}=e,a=za(nl,n),i=Z2(nl,n),s=tl(n),l=$t(),c=r&&i.value.includes(r)||!1,f=a.disabled||e.disabled;return u.createElement(nw,{scope:n,open:c,disabled:f,triggerId:l},u.createElement(U2,K({"data-orientation":a.orientation,"data-state":dp(c)},s,o,{ref:t,disabled:f,open:c,onOpenChange:d=>{d?i.onItemOpen(r):i.onItemClose(r)}})))}),ow="AccordionHeader",aw=u.forwardRef((e,t)=>{const{__scopeAccordion:n,...r}=e,o=za(kn,n),a=rl(ow,n);return u.createElement(ve.h3,K({"data-orientation":o.orientation,"data-state":dp(a.open),"data-disabled":a.disabled?"":void 0},r,{ref:t}))}),up="AccordionTrigger",iw=u.forwardRef((e,t)=>{const{__scopeAccordion:n,...r}=e,o=za(kn,n),a=rl(up,n),i=J2(up,n),s=tl(n);return u.createElement(el.ItemSlot,{scope:n},u.createElement(Y2,K({"aria-disabled":a.open&&!i.collapsible||void 0,"data-orientation":o.orientation,id:a.triggerId},s,r,{ref:t})))}),sw="AccordionContent",lw=u.forwardRef((e,t)=>{const{__scopeAccordion:n,...r}=e,o=za(kn,n),a=rl(sw,n),i=tl(n);return u.createElement(q2,K({role:"region","aria-labelledby":a.triggerId,"data-orientation":o.orientation},i,r,{ref:t,style:{"--radix-accordion-content-height":"var(--radix-collapsible-content-height)","--radix-accordion-content-width":"var(--radix-collapsible-content-width)",...e.style}}))});function dp(e){return e?"open":"closed"}const fp=ip,pp=rw,cw=aw,hp=iw,mp=lw,gp=u.forwardRef(({children:e,...t},n)=>m.jsx(fp,{ref:n,...t,className:pe("rabbit-ds",t.className),children:e})),vp=u.forwardRef(({children:e,...t},n)=>m.jsx(pp,{ref:n,...t,className:pe("rabbit-ds",t.className),children:e})),bp=u.forwardRef(({children:e,icon:t,...n},r)=>m.jsx(cw,{className:"flex",children:m.jsxs(hp,{ref:r,...n,className:pe("rabbit-ds flex group items-center bg-transparent",n.className),children:[t?m.jsx(Ve,{"aria-hidden":!0,className:"mr-2 group-data-[state=open]:rotate-90",IconSVG:t}):null,e]})})),yp=u.forwardRef(({children:e,...t},n)=>m.jsx(mp,{ref:n,...t,className:pe("rabbit-ds",t.className),children:m.jsx("div",{className:"rabbit-ds pl-9",children:e})}));gp.displayName=fp.displayName,vp.displayName=pp.displayName,bp.displayName=hp.displayName,yp.displayName=mp.displayName;const xp="Avatar",[uw,DI]=it(xp),[dw,wp]=uw(xp),fw=u.forwardRef((e,t)=>{const{__scopeAvatar:n,...r}=e,[o,a]=u.useState("idle");return u.createElement(dw,{scope:n,imageLoadingStatus:o,onImageLoadingStatusChange:a},u.createElement(ve.span,K({},r,{ref:t})))}),pw="AvatarImage",hw=u.forwardRef((e,t)=>{const{__scopeAvatar:n,src:r,onLoadingStatusChange:o=()=>{},...a}=e,i=wp(pw,n),s=vw(r),l=qe(c=>{o(c),i.onImageLoadingStatusChange(c)});return lt(()=>{s!=="idle"&&l(s)},[s,l]),s==="loaded"?u.createElement(ve.img,K({},a,{ref:t,src:r})):null}),mw="AvatarFallback",gw=u.forwardRef((e,t)=>{const{__scopeAvatar:n,delayMs:r,...o}=e,a=wp(mw,n),[i,s]=u.useState(r===void 0);return u.useEffect(()=>{if(r!==void 0){const l=window.setTimeout(()=>s(!0),r);return()=>window.clearTimeout(l)}},[r]),i&&a.imageLoadingStatus!=="loaded"?u.createElement(ve.span,K({},o,{ref:t})):null});function vw(e){const[t,n]=u.useState("idle");return lt(()=>{if(!e){n("error");return}let r=!0;const o=new window.Image,a=i=>()=>{r&&n(i)};return n("loading"),o.onload=a("loaded"),o.onerror=a("error"),o.src=e,()=>{r=!1}},[e]),t}const $p=fw,Cp=hw,Sp=gw,bw=Be("rabbit-ds relative flex shrink-0 overflow-hidden rounded-full bg-accent",{variants:{size:{xs:"h-3 w-3 text-[4px]",sm:"h-4 w-4 text-[6px]",md:"h-6 w-6 text-[10px]",lg:"h-8 w-8 text-xs",xl:"h-10 w-10 text-sm"}},defaultVariants:{size:"md"}}),On=be.forwardRef(({className:e,size:t,...n},r)=>m.jsx($p,{ref:r,className:pe(bw({size:t}),"relative flex shrink-0 overflow-hidden rounded-full",e),...n}));On.displayName=$p.displayName;const Nn=be.forwardRef(({className:e,...t},n)=>m.jsx(Cp,{ref:n,className:pe("aspect-square h-full w-full object-cover",e),...t}));Nn.displayName=Cp.displayName;const ol=be.forwardRef(({className:e,...t},n)=>m.jsx(Sp,{ref:n,className:pe("flex h-full w-full items-center justify-center rounded-full font-medium text-[1em]",e),...t}));ol.displayName=Sp.displayName;const yw=Be("rabbit-ds inline-flex items-center justify-center gap-1 rounded px-4 py-2 font-sans text-sm font-semibold transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:pointer-events-none",{variants:{variant:{filled:"",outline:"",text:""},status:{default:"",error:""},size:{normal:"h-10",small:"h-7",icon:"h-10 w-10 p-2",smallIcon:"h-7 w-7 p-1"}},compoundVariants:[{variant:"filled",status:"default",className:"bg-primary text-white hover:bg-primary-hover focus:bg-primary-focus disabled:bg-primary-disabled"},{variant:"filled",status:"error",className:"bg-[#C62C02] text-white hover:bg-[#AA2602] focus:bg-[#A12402] disabled:bg-[#F6B9B9]"},{variant:"outline",status:"default",className:"border border-primary bg-white text-primary hover:border-primary-hover hover:text-primary-hover focus:border-primary-focus focus:text-primary-focus disabled:border-primary-focus disabled:text-primary-focus"},{variant:"outline",status:"error",className:"border border-[#C62C02] bg-white text-[#C62C02] hover:border-[#AA2602] hover:text-[#AA2602] focus:border-[#A12402] focus:text-[#A12402] disabled:border-[#F6B9B9] disabled:text-[#F6B9B9]"},{variant:"text",status:"default",className:"border-0 bg-white text-primary hover:text-primary-hover focus:text-primary-focus disabled:text-primary-focus"},{variant:"text",status:"error",className:"border-0 bg-white text-[#C62C02] hover:text-[#AA2602] focus:text-[#A12402] disabled:text-[#F6B9B9]"}],defaultVariants:{variant:"filled",status:"default",size:"normal"}}),Ep=Be("",{variants:{size:{normal:"default",small:"small",icon:"default",smallIcon:"small"}},defaultVariants:{size:"normal"}}),Zt=u.forwardRef(({className:e,variant:t,iconLeft:n=void 0,iconRight:r=void 0,status:o,size:a,asChild:i=!1,children:s,...l},c)=>{const f=i?Mn:"button";return m.jsx("div",{className:"rabbit-ds",children:m.jsxs(f,{"data-deer-btn":!0,className:pe(yw({variant:t,className:e,size:a,status:o})),ref:c,...l,children:[n?m.jsx(Ve,{IconSVG:n,size:pe(Ep({size:a}))}):null,s,r?m.jsx(Ve,{IconSVG:r,size:pe(Ep({size:a}))}):null]})})});Zt.displayName="Button";const xw=Be("rabbit-ds box-border inline-flex h-auto w-full flex-col items-start justify-start rounded-lg bg-white",{variants:{size:{default:"p-4",small:"px-3 py-2"}},defaultVariants:{size:"default"}}),al=u.forwardRef(({className:e,size:t,noShadow:n,...r},o)=>m.jsx("div",{ref:o,className:pe(xw({size:t}),n?"":"shadow-card",e),...r}));al.defaultProps={noShadow:!1,size:"default"},al.displayName="Card";const Mp=u.forwardRef(({className:e,...t},n)=>m.jsx("div",{ref:n,className:pe("flex h-auto flex-col items-start justify-start self-stretch px-1 pb-3",e),...t}));Mp.displayName="CardHeader";const Tp=u.forwardRef(({className:e,children:t,...n},r)=>m.jsx("h3",{ref:r,className:pe("text-sm font-semibold leading-5 text-font-primary",e),...n,children:t}));Tp.displayName="CardTitle";const Pp=u.forwardRef(({className:e,...t},n)=>m.jsx("p",{ref:n,className:pe("text-sm text-font-secondary",e),...t}));Pp.displayName="CardDescription";const kp=u.forwardRef(({className:e,...t},n)=>m.jsx("div",{ref:n,className:pe("text-sm",e),...t}));kp.displayName="CardContent";const ww=Be("rabbit-ds box-border inline-flex h-auto min-h-8 w-full flex-row items-center justify-start gap-1 rounded-lg bg-white p-1 text-xs",{variants:{color:{success:"bg-success-bg text-success-primary",warning:"bg-warning-bg text-warning-primary"}},defaultVariants:{color:"success"}}),il=u.forwardRef(({className:e,color:t,icon:n,children:r,...o},a)=>m.jsx("div",{className:"rabbit-ds",children:m.jsxs("div",{ref:a,className:pe(ww({color:t}),e),...o,children:[n?m.jsx(Ve,{IconSVG:n}):null,r]})}));il.defaultProps={color:"success",icon:void 0},il.displayName="Caption";function De(e){const t=Object.prototype.toString.call(e);return e instanceof Date||typeof e=="object"&&t==="[object Date]"?new e.constructor(+e):typeof e=="number"||t==="[object Number]"||typeof e=="string"||t==="[object String]"?new Date(e):new Date(NaN)}function An(e,t){return e instanceof Date?new e.constructor(t):new Date(t)}function $w(e,t){const n=+De(e);return An(e,n+t)}const Op=6048e5,Cw=864e5,Sw=6e4,ja=43200,Np=1440;let Ew={};function wo(){return Ew}function $o(e,t){var s,l,c,f;const n=wo(),r=(t==null?void 0:t.weekStartsOn)??((l=(s=t==null?void 0:t.locale)==null?void 0:s.options)==null?void 0:l.weekStartsOn)??n.weekStartsOn??((f=(c=n.locale)==null?void 0:c.options)==null?void 0:f.weekStartsOn)??0,o=De(e),a=o.getDay(),i=(a<r?7:0)+a-r;return o.setDate(o.getDate()-i),o.setHours(0,0,0,0),o}function Ba(e){return $o(e,{weekStartsOn:1})}function Ap(e){const t=De(e),n=t.getFullYear(),r=An(e,0);r.setFullYear(n+1,0,4),r.setHours(0,0,0,0);const o=Ba(r),a=An(e,0);a.setFullYear(n,0,4),a.setHours(0,0,0,0);const i=Ba(a);return t.getTime()>=o.getTime()?n+1:t.getTime()>=i.getTime()?n:n-1}function Wa(e){const t=De(e);return t.setHours(0,0,0,0),t}function Va(e){const t=new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()));return t.setUTCFullYear(e.getFullYear()),e.getTime()-t.getTime()}function Mw(e,t){const n=Wa(e),r=Wa(t),o=n.getTime()-Va(n),a=r.getTime()-Va(r);return Math.round((o-a)/Cw)}function Tw(e){const t=Ap(e),n=An(e,0);return n.setFullYear(t,0,4),n.setHours(0,0,0,0),Ba(n)}function Pw(e,t){return $w(e,t*Sw)}function Ha(e,t){const n=De(e),r=De(t),o=n.getTime()-r.getTime();return o<0?-1:o>0?1:o}function kw(e,t){const n=Wa(e),r=Wa(t);return+n==+r}function Ow(e){return e instanceof Date||typeof e=="object"&&Object.prototype.toString.call(e)==="[object Date]"}function Nw(e){if(!Ow(e)&&typeof e!="number")return!1;const t=De(e);return!isNaN(Number(t))}function Aw(e,t){const n=De(e),r=De(t),o=n.getFullYear()-r.getFullYear(),a=n.getMonth()-r.getMonth();return o*12+a}function Dw(e,t){return De(e).getTime()-De(t).getTime()}function _w(e){return e?Math[e]:Math.trunc}function Iw(e){const t=De(e);return t.setHours(23,59,59,999),t}function Lw(e){const t=De(e),n=t.getMonth();return t.setFullYear(t.getFullYear(),n+1,0),t.setHours(23,59,59,999),t}function Fw(e){const t=De(e);return+Iw(t)==+Lw(t)}function zw(e,t){const n=De(e),r=De(t),o=Ha(n,r),a=Math.abs(Aw(n,r));let i;if(a<1)i=0;else{n.getMonth()===1&&n.getDate()>27&&n.setDate(30),n.setMonth(n.getMonth()-o*a);let s=Ha(n,r)===-o;Fw(De(e))&&a===1&&Ha(e,r)===1&&(s=!1),i=o*(a-Number(s))}return i===0?0:i}function jw(e,t,n){const r=Dw(e,t)/1e3;return _w(n==null?void 0:n.roundingMethod)(r)}function Bw(e){const t=De(e),n=An(e,0);return n.setFullYear(t.getFullYear(),0,1),n.setHours(0,0,0,0),n}const Ww={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},Vw=(e,t,n)=>{let r;const o=Ww[e];return typeof o=="string"?r=o:t===1?r=o.one:r=o.other.replace("{{count}}",t.toString()),n!=null&&n.addSuffix?n.comparison&&n.comparison>0?"in "+r:r+" ago":r};function sl(e){return(t={})=>{const n=t.width?String(t.width):e.defaultWidth;return e.formats[n]||e.formats[e.defaultWidth]}}const Hw={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},Gw={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},Uw={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},Yw={date:sl({formats:Hw,defaultWidth:"full"}),time:sl({formats:Gw,defaultWidth:"full"}),dateTime:sl({formats:Uw,defaultWidth:"full"})},qw={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},Kw=(e,t,n,r)=>qw[e];function Co(e){return(t,n)=>{const r=n!=null&&n.context?String(n.context):"standalone";let o;if(r==="formatting"&&e.formattingValues){const i=e.defaultFormattingWidth||e.defaultWidth,s=n!=null&&n.width?String(n.width):i;o=e.formattingValues[s]||e.formattingValues[i]}else{const i=e.defaultWidth,s=n!=null&&n.width?String(n.width):e.defaultWidth;o=e.values[s]||e.values[i]}const a=e.argumentCallback?e.argumentCallback(t):t;return o[a]}}const Xw={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},Qw={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},Zw={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},Jw={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},Rw={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},e3={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},t3={ordinalNumber:(e,t)=>{const n=Number(e),r=n%100;if(r>20||r<10)switch(r%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"},era:Co({values:Xw,defaultWidth:"wide"}),quarter:Co({values:Qw,defaultWidth:"wide",argumentCallback:e=>e-1}),month:Co({values:Zw,defaultWidth:"wide"}),day:Co({values:Jw,defaultWidth:"wide"}),dayPeriod:Co({values:Rw,defaultWidth:"wide",formattingValues:e3,defaultFormattingWidth:"wide"})};function So(e){return(t,n={})=>{const r=n.width,o=r&&e.matchPatterns[r]||e.matchPatterns[e.defaultMatchWidth],a=t.match(o);if(!a)return null;const i=a[0],s=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],l=Array.isArray(s)?r3(s,d=>d.test(i)):n3(s,d=>d.test(i));let c;c=e.valueCallback?e.valueCallback(l):l,c=n.valueCallback?n.valueCallback(c):c;const f=t.slice(i.length);return{value:c,rest:f}}}function n3(e,t){for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t(e[n]))return n}function r3(e,t){for(let n=0;n<e.length;n++)if(t(e[n]))return n}function o3(e){return(t,n={})=>{const r=t.match(e.matchPattern);if(!r)return null;const o=r[0],a=t.match(e.parsePattern);if(!a)return null;let i=e.valueCallback?e.valueCallback(a[0]):a[0];i=n.valueCallback?n.valueCallback(i):i;const s=t.slice(o.length);return{value:i,rest:s}}}const a3=/^(\d+)(th|st|nd|rd)?/i,i3=/\d+/i,s3={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},l3={any:[/^b/i,/^(a|c)/i]},c3={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},u3={any:[/1/i,/2/i,/3/i,/4/i]},d3={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},f3={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},p3={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},h3={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},m3={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},g3={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},v3={ordinalNumber:o3({matchPattern:a3,parsePattern:i3,valueCallback:e=>parseInt(e,10)}),era:So({matchPatterns:s3,defaultMatchWidth:"wide",parsePatterns:l3,defaultParseWidth:"any"}),quarter:So({matchPatterns:c3,defaultMatchWidth:"wide",parsePatterns:u3,defaultParseWidth:"any",valueCallback:e=>e+1}),month:So({matchPatterns:d3,defaultMatchWidth:"wide",parsePatterns:f3,defaultParseWidth:"any"}),day:So({matchPatterns:p3,defaultMatchWidth:"wide",parsePatterns:h3,defaultParseWidth:"any"}),dayPeriod:So({matchPatterns:m3,defaultMatchWidth:"any",parsePatterns:g3,defaultParseWidth:"any"})},Dp={code:"en-US",formatDistance:Vw,formatLong:Yw,formatRelative:Kw,localize:t3,match:v3,options:{weekStartsOn:0,firstWeekContainsDate:1}};function b3(e){const t=De(e);return Mw(t,Bw(t))+1}function y3(e){const t=De(e),n=Ba(t).getTime()-Tw(t).getTime();return Math.round(n/Op)+1}function _p(e,t){var f,d,p,v;const n=De(e),r=n.getFullYear(),o=wo(),a=(t==null?void 0:t.firstWeekContainsDate)??((d=(f=t==null?void 0:t.locale)==null?void 0:f.options)==null?void 0:d.firstWeekContainsDate)??o.firstWeekContainsDate??((v=(p=o.locale)==null?void 0:p.options)==null?void 0:v.firstWeekContainsDate)??1,i=An(e,0);i.setFullYear(r+1,0,a),i.setHours(0,0,0,0);const s=$o(i,t),l=An(e,0);l.setFullYear(r,0,a),l.setHours(0,0,0,0);const c=$o(l,t);return n.getTime()>=s.getTime()?r+1:n.getTime()>=c.getTime()?r:r-1}function x3(e,t){var s,l,c,f;const n=wo(),r=(t==null?void 0:t.firstWeekContainsDate)??((l=(s=t==null?void 0:t.locale)==null?void 0:s.options)==null?void 0:l.firstWeekContainsDate)??n.firstWeekContainsDate??((f=(c=n.locale)==null?void 0:c.options)==null?void 0:f.firstWeekContainsDate)??1,o=_p(e,t),a=An(e,0);return a.setFullYear(o,0,r),a.setHours(0,0,0,0),$o(a,t)}function w3(e,t){const n=De(e),r=$o(n,t).getTime()-x3(n,t).getTime();return Math.round(r/Op)+1}function _e(e,t){const n=e<0?"-":"",r=Math.abs(e).toString().padStart(t,"0");return n+r}const Dn={y(e,t){const n=e.getFullYear(),r=n>0?n:1-n;return _e(t==="yy"?r%100:r,t.length)},M(e,t){const n=e.getMonth();return t==="M"?String(n+1):_e(n+1,2)},d(e,t){return _e(e.getDate(),t.length)},a(e,t){const n=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.toUpperCase();case"aaa":return n;case"aaaaa":return n[0];case"aaaa":default:return n==="am"?"a.m.":"p.m."}},h(e,t){return _e(e.getHours()%12||12,t.length)},H(e,t){return _e(e.getHours(),t.length)},m(e,t){return _e(e.getMinutes(),t.length)},s(e,t){return _e(e.getSeconds(),t.length)},S(e,t){const n=t.length,r=e.getMilliseconds(),o=Math.floor(r*Math.pow(10,n-3));return _e(o,t.length)}},Ar={am:"am",pm:"pm",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},$3={G:function(e,t,n){const r=e.getFullYear()>0?1:0;switch(t){case"G":case"GG":case"GGG":return n.era(r,{width:"abbreviated"});case"GGGGG":return n.era(r,{width:"narrow"});case"GGGG":default:return n.era(r,{width:"wide"})}},y:function(e,t,n){if(t==="yo"){const r=e.getFullYear(),o=r>0?r:1-r;return n.ordinalNumber(o,{unit:"year"})}return Dn.y(e,t)},Y:function(e,t,n,r){const o=_p(e,r),a=o>0?o:1-o;if(t==="YY"){const i=a%100;return _e(i,2)}return t==="Yo"?n.ordinalNumber(a,{unit:"year"}):_e(a,t.length)},R:function(e,t){const n=Ap(e);return _e(n,t.length)},u:function(e,t){const n=e.getFullYear();return _e(n,t.length)},Q:function(e,t,n){const r=Math.ceil((e.getMonth()+1)/3);switch(t){case"Q":return String(r);case"QQ":return _e(r,2);case"Qo":return n.ordinalNumber(r,{unit:"quarter"});case"QQQ":return n.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return n.quarter(r,{width:"narrow",context:"formatting"});case"QQQQ":default:return n.quarter(r,{width:"wide",context:"formatting"})}},q:function(e,t,n){const r=Math.ceil((e.getMonth()+1)/3);switch(t){case"q":return String(r);case"qq":return _e(r,2);case"qo":return n.ordinalNumber(r,{unit:"quarter"});case"qqq":return n.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return n.quarter(r,{width:"narrow",context:"standalone"});case"qqqq":default:return n.quarter(r,{width:"wide",context:"standalone"})}},M:function(e,t,n){const r=e.getMonth();switch(t){case"M":case"MM":return Dn.M(e,t);case"Mo":return n.ordinalNumber(r+1,{unit:"month"});case"MMM":return n.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return n.month(r,{width:"narrow",context:"formatting"});case"MMMM":default:return n.month(r,{width:"wide",context:"formatting"})}},L:function(e,t,n){const r=e.getMonth();switch(t){case"L":return String(r+1);case"LL":return _e(r+1,2);case"Lo":return n.ordinalNumber(r+1,{unit:"month"});case"LLL":return n.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return n.month(r,{width:"narrow",context:"standalone"});case"LLLL":default:return n.month(r,{width:"wide",context:"standalone"})}},w:function(e,t,n,r){const o=w3(e,r);return t==="wo"?n.ordinalNumber(o,{unit:"week"}):_e(o,t.length)},I:function(e,t,n){const r=y3(e);return t==="Io"?n.ordinalNumber(r,{unit:"week"}):_e(r,t.length)},d:function(e,t,n){return t==="do"?n.ordinalNumber(e.getDate(),{unit:"date"}):Dn.d(e,t)},D:function(e,t,n){const r=b3(e);return t==="Do"?n.ordinalNumber(r,{unit:"dayOfYear"}):_e(r,t.length)},E:function(e,t,n){const r=e.getDay();switch(t){case"E":case"EE":case"EEE":return n.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return n.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(r,{width:"short",context:"formatting"});case"EEEE":default:return n.day(r,{width:"wide",context:"formatting"})}},e:function(e,t,n,r){const o=e.getDay(),a=(o-r.weekStartsOn+8)%7||7;switch(t){case"e":return String(a);case"ee":return _e(a,2);case"eo":return n.ordinalNumber(a,{unit:"day"});case"eee":return n.day(o,{width:"abbreviated",context:"formatting"});case"eeeee":return n.day(o,{width:"narrow",context:"formatting"});case"eeeeee":return n.day(o,{width:"short",context:"formatting"});case"eeee":default:return n.day(o,{width:"wide",context:"formatting"})}},c:function(e,t,n,r){const o=e.getDay(),a=(o-r.weekStartsOn+8)%7||7;switch(t){case"c":return String(a);case"cc":return _e(a,t.length);case"co":return n.ordinalNumber(a,{unit:"day"});case"ccc":return n.day(o,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(o,{width:"narrow",context:"standalone"});case"cccccc":return n.day(o,{width:"short",context:"standalone"});case"cccc":default:return n.day(o,{width:"wide",context:"standalone"})}},i:function(e,t,n){const r=e.getDay(),o=r===0?7:r;switch(t){case"i":return String(o);case"ii":return _e(o,t.length);case"io":return n.ordinalNumber(o,{unit:"day"});case"iii":return n.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return n.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return n.day(r,{width:"short",context:"formatting"});case"iiii":default:return n.day(r,{width:"wide",context:"formatting"})}},a:function(e,t,n){const o=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"aaa":return n.dayPeriod(o,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return n.dayPeriod(o,{width:"narrow",context:"formatting"});case"aaaa":default:return n.dayPeriod(o,{width:"wide",context:"formatting"})}},b:function(e,t,n){const r=e.getHours();let o;switch(r===12?o=Ar.noon:r===0?o=Ar.midnight:o=r/12>=1?"pm":"am",t){case"b":case"bb":return n.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"bbb":return n.dayPeriod(o,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return n.dayPeriod(o,{width:"narrow",context:"formatting"});case"bbbb":default:return n.dayPeriod(o,{width:"wide",context:"formatting"})}},B:function(e,t,n){const r=e.getHours();let o;switch(r>=17?o=Ar.evening:r>=12?o=Ar.afternoon:r>=4?o=Ar.morning:o=Ar.night,t){case"B":case"BB":case"BBB":return n.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"BBBBB":return n.dayPeriod(o,{width:"narrow",context:"formatting"});case"BBBB":default:return n.dayPeriod(o,{width:"wide",context:"formatting"})}},h:function(e,t,n){if(t==="ho"){let r=e.getHours()%12;return r===0&&(r=12),n.ordinalNumber(r,{unit:"hour"})}return Dn.h(e,t)},H:function(e,t,n){return t==="Ho"?n.ordinalNumber(e.getHours(),{unit:"hour"}):Dn.H(e,t)},K:function(e,t,n){const r=e.getHours()%12;return t==="Ko"?n.ordinalNumber(r,{unit:"hour"}):_e(r,t.length)},k:function(e,t,n){let r=e.getHours();return r===0&&(r=24),t==="ko"?n.ordinalNumber(r,{unit:"hour"}):_e(r,t.length)},m:function(e,t,n){return t==="mo"?n.ordinalNumber(e.getMinutes(),{unit:"minute"}):Dn.m(e,t)},s:function(e,t,n){return t==="so"?n.ordinalNumber(e.getSeconds(),{unit:"second"}):Dn.s(e,t)},S:function(e,t){return Dn.S(e,t)},X:function(e,t,n,r){const a=(r._originalDate||e).getTimezoneOffset();if(a===0)return"Z";switch(t){case"X":return Lp(a);case"XXXX":case"XX":return ir(a);case"XXXXX":case"XXX":default:return ir(a,":")}},x:function(e,t,n,r){const a=(r._originalDate||e).getTimezoneOffset();switch(t){case"x":return Lp(a);case"xxxx":case"xx":return ir(a);case"xxxxx":case"xxx":default:return ir(a,":")}},O:function(e,t,n,r){const a=(r._originalDate||e).getTimezoneOffset();switch(t){case"O":case"OO":case"OOO":return"GMT"+Ip(a,":");case"OOOO":default:return"GMT"+ir(a,":")}},z:function(e,t,n,r){const a=(r._originalDate||e).getTimezoneOffset();switch(t){case"z":case"zz":case"zzz":return"GMT"+Ip(a,":");case"zzzz":default:return"GMT"+ir(a,":")}},t:function(e,t,n,r){const o=r._originalDate||e,a=Math.floor(o.getTime()/1e3);return _e(a,t.length)},T:function(e,t,n,r){const a=(r._originalDate||e).getTime();return _e(a,t.length)}};function Ip(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),o=Math.floor(r/60),a=r%60;return a===0?n+String(o):n+String(o)+t+_e(a,2)}function Lp(e,t){return e%60===0?(e>0?"-":"+")+_e(Math.abs(e)/60,2):ir(e,t)}function ir(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),o=_e(Math.floor(r/60),2),a=_e(r%60,2);return n+o+t+a}const Fp=(e,t)=>{switch(e){case"P":return t.date({width:"short"});case"PP":return t.date({width:"medium"});case"PPP":return t.date({width:"long"});case"PPPP":default:return t.date({width:"full"})}},zp=(e,t)=>{switch(e){case"p":return t.time({width:"short"});case"pp":return t.time({width:"medium"});case"ppp":return t.time({width:"long"});case"pppp":default:return t.time({width:"full"})}},C3={p:zp,P:(e,t)=>{const n=e.match(/(P+)(p+)?/)||[],r=n[1],o=n[2];if(!o)return Fp(e,t);let a;switch(r){case"P":a=t.dateTime({width:"short"});break;case"PP":a=t.dateTime({width:"medium"});break;case"PPP":a=t.dateTime({width:"long"});break;case"PPPP":default:a=t.dateTime({width:"full"});break}return a.replace("{{date}}",Fp(r,t)).replace("{{time}}",zp(o,t))}},S3=["D","DD"],E3=["YY","YYYY"];function M3(e){return S3.indexOf(e)!==-1}function T3(e){return E3.indexOf(e)!==-1}function jp(e,t,n){if(e==="YYYY")throw new RangeError(`Use \`yyyy\` instead of \`YYYY\` (in \`${t}\`) for formatting years to the input \`${n}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`);if(e==="YY")throw new RangeError(`Use \`yy\` instead of \`YY\` (in \`${t}\`) for formatting years to the input \`${n}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`);if(e==="D")throw new RangeError(`Use \`d\` instead of \`D\` (in \`${t}\`) for formatting days of the month to the input \`${n}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`);if(e==="DD")throw new RangeError(`Use \`dd\` instead of \`DD\` (in \`${t}\`) for formatting days of the month to the input \`${n}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`)}const P3=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,k3=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,O3=/^'([^]*?)'?$/,N3=/''/g,A3=/[a-zA-Z]/;function ll(e,t,n){var f,d,p,v,h,g,w,x;const r=wo(),o=(n==null?void 0:n.locale)??r.locale??Dp,a=(n==null?void 0:n.firstWeekContainsDate)??((d=(f=n==null?void 0:n.locale)==null?void 0:f.options)==null?void 0:d.firstWeekContainsDate)??r.firstWeekContainsDate??((v=(p=r.locale)==null?void 0:p.options)==null?void 0:v.firstWeekContainsDate)??1,i=(n==null?void 0:n.weekStartsOn)??((g=(h=n==null?void 0:n.locale)==null?void 0:h.options)==null?void 0:g.weekStartsOn)??r.weekStartsOn??((x=(w=r.locale)==null?void 0:w.options)==null?void 0:x.weekStartsOn)??0,s=De(e);if(!Nw(s))throw new RangeError("Invalid time value");const l={firstWeekContainsDate:a,weekStartsOn:i,locale:o,_originalDate:s};return t.match(k3).map(function(y){const b=y[0];if(b==="p"||b==="P"){const S=C3[b];return S(y,o.formatLong)}return y}).join("").match(P3).map(function(y){if(y==="''")return"'";const b=y[0];if(b==="'")return D3(y);const S=$3[b];if(S)return!(n!=null&&n.useAdditionalWeekYearTokens)&&T3(y)&&jp(y,t,String(e)),!(n!=null&&n.useAdditionalDayOfYearTokens)&&M3(y)&&jp(y,t,String(e)),S(s,y,o.localize,l);if(b.match(A3))throw new RangeError("Format string contains an unescaped latin alphabet character `"+b+"`");return y}).join("")}function D3(e){const t=e.match(O3);return t?t[1].replace(N3,"'"):e}function _3(e,t,n){const r=wo(),o=(n==null?void 0:n.locale)??r.locale??Dp,a=2520,i=Ha(e,t);if(isNaN(i))throw new RangeError("Invalid time value");const s=Object.assign({},n,{addSuffix:n==null?void 0:n.addSuffix,comparison:i});let l,c;i>0?(l=De(t),c=De(e)):(l=De(e),c=De(t));const f=jw(c,l),d=(Va(c)-Va(l))/1e3,p=Math.round((f-d)/60);let v;if(p<2)return n!=null&&n.includeSeconds?f<5?o.formatDistance("lessThanXSeconds",5,s):f<10?o.formatDistance("lessThanXSeconds",10,s):f<20?o.formatDistance("lessThanXSeconds",20,s):f<40?o.formatDistance("halfAMinute",0,s):f<60?o.formatDistance("lessThanXMinutes",1,s):o.formatDistance("xMinutes",1,s):p===0?o.formatDistance("lessThanXMinutes",1,s):o.formatDistance("xMinutes",p,s);if(p<45)return o.formatDistance("xMinutes",p,s);if(p<90)return o.formatDistance("aboutXHours",1,s);if(p<Np){const h=Math.round(p/60);return o.formatDistance("aboutXHours",h,s)}else{if(p<a)return o.formatDistance("xDays",1,s);if(p<ja){const h=Math.round(p/Np);return o.formatDistance("xDays",h,s)}else if(p<ja*2)return v=Math.round(p/ja),o.formatDistance("aboutXMonths",v,s)}if(v=zw(c,l),v<12){const h=Math.round(p/ja);return o.formatDistance("xMonths",h,s)}else{const h=v%12,g=Math.floor(v/12);return h<3?o.formatDistance("aboutXYears",g,s):h<9?o.formatDistance("overXYears",g,s):o.formatDistance("almostXYears",g+1,s)}}function I3(e,t){return _3(e,Date.now(),t)}function L3(e,t){const n=De(e),r=De(t);return n.getTime()>r.getTime()}function cl({date:e,duration:t,showRelativeTime:n=!1,showTime:r=!1,dateFormat:o="MMM dd, yyyy",timeFormat:a="HH:mm",highlightDate:i=n,className:s}){const l=new Date,c=kw(e,l)||L3(e,l);let f="";n?(f=I3(e,{addSuffix:!0}),f=zx(f)):f=ll(e,o);const d=c?"text-functional-warn font-semibold":"";return m.jsx("div",{className:"rabbit-ds",children:m.jsxs("span",{className:pe("text-sm",i&&d,s),children:[f,r&&" • ",r&&ll(e,a),r&&t&&` - ${ll(Pw(e,t),a)}`]})})}function F3(e,t=globalThis==null?void 0:globalThis.document){const n=qe(e);u.useEffect(()=>{const r=o=>{o.key==="Escape"&&n(o)};return t.addEventListener("keydown",r),()=>t.removeEventListener("keydown",r)},[n,t])}const ul="dismissableLayer.update",z3="dismissableLayer.pointerDownOutside",j3="dismissableLayer.focusOutside";let Bp;const B3=u.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Ga=u.forwardRef((e,t)=>{var n;const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:o,onPointerDownOutside:a,onFocusOutside:i,onInteractOutside:s,onDismiss:l,...c}=e,f=u.useContext(B3),[d,p]=u.useState(null),v=(n=d==null?void 0:d.ownerDocument)!==null&&n!==void 0?n:globalThis==null?void 0:globalThis.document,[,h]=u.useState({}),g=Ee(t,P=>p(P)),w=Array.from(f.layers),[x]=[...f.layersWithOutsidePointerEventsDisabled].slice(-1),y=w.indexOf(x),b=d?w.indexOf(d):-1,S=f.layersWithOutsidePointerEventsDisabled.size>0,$=b>=y,M=W3(P=>{const T=P.target,I=[...f.branches].some(j=>j.contains(T));!$||I||(a==null||a(P),s==null||s(P),P.defaultPrevented||l==null||l())},v),k=V3(P=>{const T=P.target;[...f.branches].some(j=>j.contains(T))||(i==null||i(P),s==null||s(P),P.defaultPrevented||l==null||l())},v);return F3(P=>{b===f.layers.size-1&&(o==null||o(P),!P.defaultPrevented&&l&&(P.preventDefault(),l()))},v),u.useEffect(()=>{if(d)return r&&(f.layersWithOutsidePointerEventsDisabled.size===0&&(Bp=v.body.style.pointerEvents,v.body.style.pointerEvents="none"),f.layersWithOutsidePointerEventsDisabled.add(d)),f.layers.add(d),Wp(),()=>{r&&f.layersWithOutsidePointerEventsDisabled.size===1&&(v.body.style.pointerEvents=Bp)}},[d,v,r,f]),u.useEffect(()=>()=>{d&&(f.layers.delete(d),f.layersWithOutsidePointerEventsDisabled.delete(d),Wp())},[d,f]),u.useEffect(()=>{const P=()=>h({});return document.addEventListener(ul,P),()=>document.removeEventListener(ul,P)},[]),u.createElement(ve.div,K({},c,{ref:g,style:{pointerEvents:S?$?"auto":"none":void 0,...e.style},onFocusCapture:de(e.onFocusCapture,k.onFocusCapture),onBlurCapture:de(e.onBlurCapture,k.onBlurCapture),onPointerDownCapture:de(e.onPointerDownCapture,M.onPointerDownCapture)}))});function W3(e,t=globalThis==null?void 0:globalThis.document){const n=qe(e),r=u.useRef(!1),o=u.useRef(()=>{});return u.useEffect(()=>{const a=s=>{if(s.target&&!r.current){let c=function(){Vp(z3,n,l,{discrete:!0})};const l={originalEvent:s};s.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=c,t.addEventListener("click",o.current,{once:!0})):c()}else t.removeEventListener("click",o.current);r.current=!1},i=window.setTimeout(()=>{t.addEventListener("pointerdown",a)},0);return()=>{window.clearTimeout(i),t.removeEventListener("pointerdown",a),t.removeEventListener("click",o.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function V3(e,t=globalThis==null?void 0:globalThis.document){const n=qe(e),r=u.useRef(!1);return u.useEffect(()=>{const o=a=>{a.target&&!r.current&&Vp(j3,n,{originalEvent:a},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function Wp(){const e=new CustomEvent(ul);document.dispatchEvent(e)}function Vp(e,t,n,{discrete:r}){const o=n.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?Ma(o,a):o.dispatchEvent(a)}let dl=0;function Hp(){u.useEffect(()=>{var e,t;const n=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",(e=n[0])!==null&&e!==void 0?e:Gp()),document.body.insertAdjacentElement("beforeend",(t=n[1])!==null&&t!==void 0?t:Gp()),dl++,()=>{dl===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(r=>r.remove()),dl--}},[])}function Gp(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.cssText="outline: none; opacity: 0; position: fixed; pointer-events: none",e}const fl="focusScope.autoFocusOnMount",pl="focusScope.autoFocusOnUnmount",Up={bubbles:!1,cancelable:!0},Yp=u.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:o,onUnmountAutoFocus:a,...i}=e,[s,l]=u.useState(null),c=qe(o),f=qe(a),d=u.useRef(null),p=Ee(t,g=>l(g)),v=u.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;u.useEffect(()=>{if(r){let g=function(b){if(v.paused||!s)return;const S=b.target;s.contains(S)?d.current=S:_n(d.current,{select:!0})},w=function(b){if(v.paused||!s)return;const S=b.relatedTarget;S!==null&&(s.contains(S)||_n(d.current,{select:!0}))},x=function(b){if(document.activeElement===document.body)for(const $ of b)$.removedNodes.length>0&&_n(s)};document.addEventListener("focusin",g),document.addEventListener("focusout",w);const y=new MutationObserver(x);return s&&y.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",g),document.removeEventListener("focusout",w),y.disconnect()}}},[r,s,v.paused]),u.useEffect(()=>{if(s){Xp.add(v);const g=document.activeElement;if(!s.contains(g)){const x=new CustomEvent(fl,Up);s.addEventListener(fl,c),s.dispatchEvent(x),x.defaultPrevented||(H3(K3(qp(s)),{select:!0}),document.activeElement===g&&_n(s))}return()=>{s.removeEventListener(fl,c),setTimeout(()=>{const x=new CustomEvent(pl,Up);s.addEventListener(pl,f),s.dispatchEvent(x),x.defaultPrevented||_n(g??document.body,{select:!0}),s.removeEventListener(pl,f),Xp.remove(v)},0)}}},[s,c,f,v]);const h=u.useCallback(g=>{if(!n&&!r||v.paused)return;const w=g.key==="Tab"&&!g.altKey&&!g.ctrlKey&&!g.metaKey,x=document.activeElement;if(w&&x){const y=g.currentTarget,[b,S]=G3(y);b&&S?!g.shiftKey&&x===S?(g.preventDefault(),n&&_n(b,{select:!0})):g.shiftKey&&x===b&&(g.preventDefault(),n&&_n(S,{select:!0})):x===y&&g.preventDefault()}},[n,r,v.paused]);return u.createElement(ve.div,K({tabIndex:-1},i,{ref:p,onKeyDown:h}))});function H3(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(_n(r,{select:t}),document.activeElement!==n)return}function G3(e){const t=qp(e),n=Kp(t,e),r=Kp(t.reverse(),e);return[n,r]}function qp(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function Kp(e,t){for(const n of e)if(!U3(n,{upTo:t}))return n}function U3(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 Y3(e){return e instanceof HTMLInputElement&&"select"in e}function _n(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&Y3(e)&&t&&e.select()}}const Xp=q3();function q3(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=Qp(e,t),e.unshift(t)},remove(t){var n;e=Qp(e,t),(n=e[0])===null||n===void 0||n.resume()}}}function Qp(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function K3(e){return e.filter(t=>t.tagName!=="A")}const X3=["top","right","bottom","left"],In=Math.min,Pt=Math.max,Ua=Math.round,Ya=Math.floor,Ln=e=>({x:e,y:e}),Q3={left:"right",right:"left",bottom:"top",top:"bottom"},Z3={start:"end",end:"start"};function hl(e,t,n){return Pt(e,In(t,n))}function cn(e,t){return typeof e=="function"?e(t):e}function un(e){return e.split("-")[0]}function Dr(e){return e.split("-")[1]}function ml(e){return e==="x"?"y":"x"}function gl(e){return e==="y"?"height":"width"}function _r(e){return["top","bottom"].includes(un(e))?"y":"x"}function vl(e){return ml(_r(e))}function J3(e,t,n){n===void 0&&(n=!1);const r=Dr(e),o=vl(e),a=gl(o);let i=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[a]>t.floating[a]&&(i=qa(i)),[i,qa(i)]}function R3(e){const t=qa(e);return[bl(e),t,bl(t)]}function bl(e){return e.replace(/start|end/g,t=>Z3[t])}function e$(e,t,n){const r=["left","right"],o=["right","left"],a=["top","bottom"],i=["bottom","top"];switch(e){case"top":case"bottom":return n?t?o:r:t?r:o;case"left":case"right":return t?a:i;default:return[]}}function t$(e,t,n,r){const o=Dr(e);let a=e$(un(e),n==="start",r);return o&&(a=a.map(i=>i+"-"+o),t&&(a=a.concat(a.map(bl)))),a}function qa(e){return e.replace(/left|right|bottom|top/g,t=>Q3[t])}function n$(e){return{top:0,right:0,bottom:0,left:0,...e}}function Zp(e){return typeof e!="number"?n$(e):{top:e,right:e,bottom:e,left:e}}function Ka(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}function Jp(e,t,n){let{reference:r,floating:o}=e;const a=_r(t),i=vl(t),s=gl(i),l=un(t),c=a==="y",f=r.x+r.width/2-o.width/2,d=r.y+r.height/2-o.height/2,p=r[s]/2-o[s]/2;let v;switch(l){case"top":v={x:f,y:r.y-o.height};break;case"bottom":v={x:f,y:r.y+r.height};break;case"right":v={x:r.x+r.width,y:d};break;case"left":v={x:r.x-o.width,y:d};break;default:v={x:r.x,y:r.y}}switch(Dr(t)){case"start":v[i]-=p*(n&&c?-1:1);break;case"end":v[i]+=p*(n&&c?-1:1);break}return v}const r$=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:a=[],platform:i}=n,s=a.filter(Boolean),l=await(i.isRTL==null?void 0:i.isRTL(t));let c=await i.getElementRects({reference:e,floating:t,strategy:o}),{x:f,y:d}=Jp(c,r,l),p=r,v={},h=0;for(let g=0;g<s.length;g++){const{name:w,fn:x}=s[g],{x:y,y:b,data:S,reset:$}=await x({x:f,y:d,initialPlacement:r,placement:p,strategy:o,middlewareData:v,rects:c,platform:i,elements:{reference:e,floating:t}});if(f=y??f,d=b??d,v={...v,[w]:{...v[w],...S}},$&&h<=50){h++,typeof $=="object"&&($.placement&&(p=$.placement),$.rects&&(c=$.rects===!0?await i.getElementRects({reference:e,floating:t,strategy:o}):$.rects),{x:f,y:d}=Jp(c,p,l)),g=-1;continue}}return{x:f,y:d,placement:p,strategy:o,middlewareData:v}};async function Eo(e,t){var n;t===void 0&&(t={});const{x:r,y:o,platform:a,rects:i,elements:s,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:f="viewport",elementContext:d="floating",altBoundary:p=!1,padding:v=0}=cn(t,e),h=Zp(v),w=s[p?d==="floating"?"reference":"floating":d],x=Ka(await a.getClippingRect({element:(n=await(a.isElement==null?void 0:a.isElement(w)))==null||n?w:w.contextElement||await(a.getDocumentElement==null?void 0:a.getDocumentElement(s.floating)),boundary:c,rootBoundary:f,strategy:l})),y=d==="floating"?{...i.floating,x:r,y:o}:i.reference,b=await(a.getOffsetParent==null?void 0:a.getOffsetParent(s.floating)),S=await(a.isElement==null?void 0:a.isElement(b))?await(a.getScale==null?void 0:a.getScale(b))||{x:1,y:1}:{x:1,y:1},$=Ka(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({rect:y,offsetParent:b,strategy:l}):y);return{top:(x.top-$.top+h.top)/S.y,bottom:($.bottom-x.bottom+h.bottom)/S.y,left:(x.left-$.left+h.left)/S.x,right:($.right-x.right+h.right)/S.x}}const Rp=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:o,rects:a,platform:i,elements:s,middlewareData:l}=t,{element:c,padding:f=0}=cn(e,t)||{};if(c==null)return{};const d=Zp(f),p={x:n,y:r},v=vl(o),h=gl(v),g=await i.getDimensions(c),w=v==="y",x=w?"top":"left",y=w?"bottom":"right",b=w?"clientHeight":"clientWidth",S=a.reference[h]+a.reference[v]-p[v]-a.floating[h],$=p[v]-a.reference[v],M=await(i.getOffsetParent==null?void 0:i.getOffsetParent(c));let k=M?M[b]:0;(!k||!await(i.isElement==null?void 0:i.isElement(M)))&&(k=s.floating[b]||a.floating[h]);const P=S/2-$/2,T=k/2-g[h]/2-1,I=In(d[x],T),j=In(d[y],T),z=I,B=k-g[h]-j,F=k/2-g[h]/2+P,E=hl(z,F,B),A=!l.arrow&&Dr(o)!=null&&F!=E&&a.reference[h]/2-(F<z?I:j)-g[h]/2<0,W=A?F<z?F-z:F-B:0;return{[v]:p[v]+W,data:{[v]:E,centerOffset:F-E-W,...A&&{alignmentOffset:W}},reset:A}}}),o$=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:o,middlewareData:a,rects:i,initialPlacement:s,platform:l,elements:c}=t,{mainAxis:f=!0,crossAxis:d=!0,fallbackPlacements:p,fallbackStrategy:v="bestFit",fallbackAxisSideDirection:h="none",flipAlignment:g=!0,...w}=cn(e,t);if((n=a.arrow)!=null&&n.alignmentOffset)return{};const x=un(o),y=un(s)===s,b=await(l.isRTL==null?void 0:l.isRTL(c.floating)),S=p||(y||!g?[qa(s)]:R3(s));!p&&h!=="none"&&S.push(...t$(s,g,h,b));const $=[s,...S],M=await Eo(t,w),k=[];let P=((r=a.flip)==null?void 0:r.overflows)||[];if(f&&k.push(M[x]),d){const z=J3(o,i,b);k.push(M[z[0]],M[z[1]])}if(P=[...P,{placement:o,overflows:k}],!k.every(z=>z<=0)){var T,I;const z=(((T=a.flip)==null?void 0:T.index)||0)+1,B=$[z];if(B)return{data:{index:z,overflows:P},reset:{placement:B}};let F=(I=P.filter(E=>E.overflows[0]<=0).sort((E,A)=>E.overflows[1]-A.overflows[1])[0])==null?void 0:I.placement;if(!F)switch(v){case"bestFit":{var j;const E=(j=P.map(A=>[A.placement,A.overflows.filter(W=>W>0).reduce((W,G)=>W+G,0)]).sort((A,W)=>A[1]-W[1])[0])==null?void 0:j[0];E&&(F=E);break}case"initialPlacement":F=s;break}if(o!==F)return{reset:{placement:F}}}return{}}}};function eh(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function th(e){return X3.some(t=>e[t]>=0)}const a$=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...o}=cn(e,t);switch(r){case"referenceHidden":{const a=await Eo(t,{...o,elementContext:"reference"}),i=eh(a,n.reference);return{data:{referenceHiddenOffsets:i,referenceHidden:th(i)}}}case"escaped":{const a=await Eo(t,{...o,altBoundary:!0}),i=eh(a,n.floating);return{data:{escapedOffsets:i,escaped:th(i)}}}default:return{}}}}};async function i$(e,t){const{placement:n,platform:r,elements:o}=e,a=await(r.isRTL==null?void 0:r.isRTL(o.floating)),i=un(n),s=Dr(n),l=_r(n)==="y",c=["left","top"].includes(i)?-1:1,f=a&&l?-1:1,d=cn(t,e);let{mainAxis:p,crossAxis:v,alignmentAxis:h}=typeof d=="number"?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...d};return s&&typeof h=="number"&&(v=s==="end"?h*-1:h),l?{x:v*f,y:p*c}:{x:p*c,y:v*f}}const s$=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){const{x:n,y:r}=t,o=await i$(t,e);return{x:n+o.x,y:r+o.y,data:o}}}},l$=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:a=!0,crossAxis:i=!1,limiter:s={fn:w=>{let{x,y}=w;return{x,y}}},...l}=cn(e,t),c={x:n,y:r},f=await Eo(t,l),d=_r(un(o)),p=ml(d);let v=c[p],h=c[d];if(a){const w=p==="y"?"top":"left",x=p==="y"?"bottom":"right",y=v+f[w],b=v-f[x];v=hl(y,v,b)}if(i){const w=d==="y"?"top":"left",x=d==="y"?"bottom":"right",y=h+f[w],b=h-f[x];h=hl(y,h,b)}const g=s.fn({...t,[p]:v,[d]:h});return{...g,data:{x:g.x-n,y:g.y-r}}}}},c$=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:a,middlewareData:i}=t,{offset:s=0,mainAxis:l=!0,crossAxis:c=!0}=cn(e,t),f={x:n,y:r},d=_r(o),p=ml(d);let v=f[p],h=f[d];const g=cn(s,t),w=typeof g=="number"?{mainAxis:g,crossAxis:0}:{mainAxis:0,crossAxis:0,...g};if(l){const b=p==="y"?"height":"width",S=a.reference[p]-a.floating[b]+w.mainAxis,$=a.reference[p]+a.reference[b]-w.mainAxis;v<S?v=S:v>$&&(v=$)}if(c){var x,y;const b=p==="y"?"width":"height",S=["top","left"].includes(un(o)),$=a.reference[d]-a.floating[b]+(S&&((x=i.offset)==null?void 0:x[d])||0)+(S?0:w.crossAxis),M=a.reference[d]+a.reference[b]+(S?0:((y=i.offset)==null?void 0:y[d])||0)-(S?w.crossAxis:0);h<$?h=$:h>M&&(h=M)}return{[p]:v,[d]:h}}}},u$=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){const{placement:n,rects:r,platform:o,elements:a}=t,{apply:i=()=>{},...s}=cn(e,t),l=await Eo(t,s),c=un(n),f=Dr(n),d=_r(n)==="y",{width:p,height:v}=r.floating;let h,g;c==="top"||c==="bottom"?(h=c,g=f===(await(o.isRTL==null?void 0:o.isRTL(a.floating))?"start":"end")?"left":"right"):(g=c,h=f==="end"?"top":"bottom");const w=v-l[h],x=p-l[g],y=!t.middlewareData.shift;let b=w,S=x;if(d){const M=p-l.left-l.right;S=f||y?In(x,M):M}else{const M=v-l.top-l.bottom;b=f||y?In(w,M):M}if(y&&!f){const M=Pt(l.left,0),k=Pt(l.right,0),P=Pt(l.top,0),T=Pt(l.bottom,0);d?S=p-2*(M!==0||k!==0?M+k:Pt(l.left,l.right)):b=v-2*(P!==0||T!==0?P+T:Pt(l.top,l.bottom))}await i({...t,availableWidth:S,availableHeight:b});const $=await o.getDimensions(a.floating);return p!==$.width||v!==$.height?{reset:{rects:!0}}:{}}}};function Fn(e){return nh(e)?(e.nodeName||"").toLowerCase():"#document"}function kt(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function dn(e){var t;return(t=(nh(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function nh(e){return e instanceof Node||e instanceof kt(e).Node}function fn(e){return e instanceof Element||e instanceof kt(e).Element}function Jt(e){return e instanceof HTMLElement||e instanceof kt(e).HTMLElement}function rh(e){return typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof kt(e).ShadowRoot}function Mo(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=At(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(o)}function d$(e){return["table","td","th"].includes(Fn(e))}function yl(e){const t=xl(),n=At(e);return n.transform!=="none"||n.perspective!=="none"||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||["transform","perspective","filter"].some(r=>(n.willChange||"").includes(r))||["paint","layout","strict","content"].some(r=>(n.contain||"").includes(r))}function f$(e){let t=Ir(e);for(;Jt(t)&&!Xa(t);){if(yl(t))return t;t=Ir(t)}return null}function xl(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function Xa(e){return["html","body","#document"].includes(Fn(e))}function At(e){return kt(e).getComputedStyle(e)}function Qa(e){return fn(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function Ir(e){if(Fn(e)==="html")return e;const t=e.assignedSlot||e.parentNode||rh(e)&&e.host||dn(e);return rh(t)?t.host:t}function oh(e){const t=Ir(e);return Xa(t)?e.ownerDocument?e.ownerDocument.body:e.body:Jt(t)&&Mo(t)?t:oh(t)}function To(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=oh(e),a=o===((r=e.ownerDocument)==null?void 0:r.body),i=kt(o);return a?t.concat(i,i.visualViewport||[],Mo(o)?o:[],i.frameElement&&n?To(i.frameElement):[]):t.concat(o,To(o,[],n))}function ah(e){const t=At(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=Jt(e),a=o?e.offsetWidth:n,i=o?e.offsetHeight:r,s=Ua(n)!==a||Ua(r)!==i;return s&&(n=a,r=i),{width:n,height:r,$:s}}function wl(e){return fn(e)?e:e.contextElement}function Lr(e){const t=wl(e);if(!Jt(t))return Ln(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:a}=ah(t);let i=(a?Ua(n.width):n.width)/r,s=(a?Ua(n.height):n.height)/o;return(!i||!Number.isFinite(i))&&(i=1),(!s||!Number.isFinite(s))&&(s=1),{x:i,y:s}}const p$=Ln(0);function ih(e){const t=kt(e);return!xl()||!t.visualViewport?p$:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function h$(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==kt(e)?!1:t}function sr(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),a=wl(e);let i=Ln(1);t&&(r?fn(r)&&(i=Lr(r)):i=Lr(e));const s=h$(a,n,r)?ih(a):Ln(0);let l=(o.left+s.x)/i.x,c=(o.top+s.y)/i.y,f=o.width/i.x,d=o.height/i.y;if(a){const p=kt(a),v=r&&fn(r)?kt(r):r;let h=p.frameElement;for(;h&&r&&v!==p;){const g=Lr(h),w=h.getBoundingClientRect(),x=At(h),y=w.left+(h.clientLeft+parseFloat(x.paddingLeft))*g.x,b=w.top+(h.clientTop+parseFloat(x.paddingTop))*g.y;l*=g.x,c*=g.y,f*=g.x,d*=g.y,l+=y,c+=b,h=kt(h).frameElement}}return Ka({width:f,height:d,x:l,y:c})}function m$(e){let{rect:t,offsetParent:n,strategy:r}=e;const o=Jt(n),a=dn(n);if(n===a)return t;let i={scrollLeft:0,scrollTop:0},s=Ln(1);const l=Ln(0);if((o||!o&&r!=="fixed")&&((Fn(n)!=="body"||Mo(a))&&(i=Qa(n)),Jt(n))){const c=sr(n);s=Lr(n),l.x=c.x+n.clientLeft,l.y=c.y+n.clientTop}return{width:t.width*s.x,height:t.height*s.y,x:t.x*s.x-i.scrollLeft*s.x+l.x,y:t.y*s.y-i.scrollTop*s.y+l.y}}function g$(e){return Array.from(e.getClientRects())}function sh(e){return sr(dn(e)).left+Qa(e).scrollLeft}function v$(e){const t=dn(e),n=Qa(e),r=e.ownerDocument.body,o=Pt(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=Pt(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let i=-n.scrollLeft+sh(e);const s=-n.scrollTop;return At(r).direction==="rtl"&&(i+=Pt(t.clientWidth,r.clientWidth)-o),{width:o,height:a,x:i,y:s}}function b$(e,t){const n=kt(e),r=dn(e),o=n.visualViewport;let a=r.clientWidth,i=r.clientHeight,s=0,l=0;if(o){a=o.width,i=o.height;const c=xl();(!c||c&&t==="fixed")&&(s=o.offsetLeft,l=o.offsetTop)}return{width:a,height:i,x:s,y:l}}function y$(e,t){const n=sr(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,a=Jt(e)?Lr(e):Ln(1),i=e.clientWidth*a.x,s=e.clientHeight*a.y,l=o*a.x,c=r*a.y;return{width:i,height:s,x:l,y:c}}function lh(e,t,n){let r;if(t==="viewport")r=b$(e,n);else if(t==="document")r=v$(dn(e));else if(fn(t))r=y$(t,n);else{const o=ih(e);r={...t,x:t.x-o.x,y:t.y-o.y}}return Ka(r)}function ch(e,t){const n=Ir(e);return n===t||!fn(n)||Xa(n)?!1:At(n).position==="fixed"||ch(n,t)}function x$(e,t){const n=t.get(e);if(n)return n;let r=To(e,[],!1).filter(s=>fn(s)&&Fn(s)!=="body"),o=null;const a=At(e).position==="fixed";let i=a?Ir(e):e;for(;fn(i)&&!Xa(i);){const s=At(i),l=yl(i);!l&&s.position==="fixed"&&(o=null),(a?!l&&!o:!l&&s.position==="static"&&!!o&&["absolute","fixed"].includes(o.position)||Mo(i)&&!l&&ch(e,i))?r=r.filter(f=>f!==i):o=s,i=Ir(i)}return t.set(e,r),r}function w$(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const i=[...n==="clippingAncestors"?x$(t,this._c):[].concat(n),r],s=i[0],l=i.reduce((c,f)=>{const d=lh(t,f,o);return c.top=Pt(d.top,c.top),c.right=In(d.right,c.right),c.bottom=In(d.bottom,c.bottom),c.left=Pt(d.left,c.left),c},lh(t,s,o));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function $$(e){return ah(e)}function C$(e,t,n){const r=Jt(t),o=dn(t),a=n==="fixed",i=sr(e,!0,a,t);let s={scrollLeft:0,scrollTop:0};const l=Ln(0);if(r||!r&&!a)if((Fn(t)!=="body"||Mo(o))&&(s=Qa(t)),r){const c=sr(t,!0,a,t);l.x=c.x+t.clientLeft,l.y=c.y+t.clientTop}else o&&(l.x=sh(o));return{x:i.left+s.scrollLeft-l.x,y:i.top+s.scrollTop-l.y,width:i.width,height:i.height}}function uh(e,t){return!Jt(e)||At(e).position==="fixed"?null:t?t(e):e.offsetParent}function dh(e,t){const n=kt(e);if(!Jt(e))return n;let r=uh(e,t);for(;r&&d$(r)&&At(r).position==="static";)r=uh(r,t);return r&&(Fn(r)==="html"||Fn(r)==="body"&&At(r).position==="static"&&!yl(r))?n:r||f$(e)||n}const S$=async function(e){let{reference:t,floating:n,strategy:r}=e;const o=this.getOffsetParent||dh,a=this.getDimensions;return{reference:C$(t,await o(n),r),floating:{x:0,y:0,...await a(n)}}};function E$(e){return At(e).direction==="rtl"}const M$={convertOffsetParentRelativeRectToViewportRelativeRect:m$,getDocumentElement:dn,getClippingRect:w$,getOffsetParent:dh,getElementRects:S$,getClientRects:g$,getDimensions:$$,getScale:Lr,isElement:fn,isRTL:E$};function T$(e,t){let n=null,r;const o=dn(e);function a(){clearTimeout(r),n&&n.disconnect(),n=null}function i(s,l){s===void 0&&(s=!1),l===void 0&&(l=1),a();const{left:c,top:f,width:d,height:p}=e.getBoundingClientRect();if(s||t(),!d||!p)return;const v=Ya(f),h=Ya(o.clientWidth-(c+d)),g=Ya(o.clientHeight-(f+p)),w=Ya(c),y={rootMargin:-v+"px "+-h+"px "+-g+"px "+-w+"px",threshold:Pt(0,In(1,l))||1};let b=!0;function S($){const M=$[0].intersectionRatio;if(M!==l){if(!b)return i();M?i(!1,M):r=setTimeout(()=>{i(!1,1e-7)},100)}b=!1}try{n=new IntersectionObserver(S,{...y,root:o.ownerDocument})}catch{n=new IntersectionObserver(S,y)}n.observe(e)}return i(!0),a}function P$(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:a=!0,elementResize:i=typeof ResizeObserver=="function",layoutShift:s=typeof IntersectionObserver=="function",animationFrame:l=!1}=r,c=wl(e),f=o||a?[...c?To(c):[],...To(t)]:[];f.forEach(x=>{o&&x.addEventListener("scroll",n,{passive:!0}),a&&x.addEventListener("resize",n)});const d=c&&s?T$(c,n):null;let p=-1,v=null;i&&(v=new ResizeObserver(x=>{let[y]=x;y&&y.target===c&&v&&(v.unobserve(t),cancelAnimationFrame(p),p=requestAnimationFrame(()=>{v&&v.observe(t)})),n()}),c&&!l&&v.observe(c),v.observe(t));let h,g=l?sr(e):null;l&&w();function w(){const x=sr(e);g&&(x.x!==g.x||x.y!==g.y||x.width!==g.width||x.height!==g.height)&&n(),g=x,h=requestAnimationFrame(w)}return n(),()=>{f.forEach(x=>{o&&x.removeEventListener("scroll",n),a&&x.removeEventListener("resize",n)}),d&&d(),v&&v.disconnect(),v=null,l&&cancelAnimationFrame(h)}}const k$=(e,t,n)=>{const r=new Map,o={platform:M$,...n},a={...o.platform,_c:r};return r$(e,t,{...o,platform:a})},O$=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:o}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?Rp({element:r.current,padding:o}).fn(n):{}:r?Rp({element:r,padding:o}).fn(n):{}}}};var Za=typeof document<"u"?u.useLayoutEffect:u.useEffect;function Ja(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(r=n;r--!==0;)if(!Ja(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,o[r]))return!1;for(r=n;r--!==0;){const a=o[r];if(!(a==="_owner"&&e.$$typeof)&&!Ja(e[a],t[a]))return!1}return!0}return e!==e&&t!==t}function fh(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function ph(e,t){const n=fh(e);return Math.round(t*n)/n}function hh(e){const t=be.useRef(e);return Za(()=>{t.current=e}),t}function N$(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:a,floating:i}={},transform:s=!0,whileElementsMounted:l,open:c}=e,[f,d]=be.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[p,v]=be.useState(r);Ja(p,r)||v(r);const[h,g]=be.useState(null),[w,x]=be.useState(null),y=be.useCallback(A=>{A!=M.current&&(M.current=A,g(A))},[g]),b=be.useCallback(A=>{A!==k.current&&(k.current=A,x(A))},[x]),S=a||h,$=i||w,M=be.useRef(null),k=be.useRef(null),P=be.useRef(f),T=hh(l),I=hh(o),j=be.useCallback(()=>{if(!M.current||!k.current)return;const A={placement:t,strategy:n,middleware:p};I.current&&(A.platform=I.current),k$(M.current,k.current,A).then(W=>{const G={...W,isPositioned:!0};z.current&&!Ja(P.current,G)&&(P.current=G,Ky.flushSync(()=>{d(G)}))})},[p,t,n,I]);Za(()=>{c===!1&&P.current.isPositioned&&(P.current.isPositioned=!1,d(A=>({...A,isPositioned:!1})))},[c]);const z=be.useRef(!1);Za(()=>(z.current=!0,()=>{z.current=!1}),[]),Za(()=>{if(S&&(M.current=S),$&&(k.current=$),S&&$){if(T.current)return T.current(S,$,j);j()}},[S,$,j,T]);const B=be.useMemo(()=>({reference:M,floating:k,setReference:y,setFloating:b}),[y,b]),F=be.useMemo(()=>({reference:S,floating:$}),[S,$]),E=be.useMemo(()=>{const A={position:n,left:0,top:0};if(!F.floating)return A;const W=ph(F.floating,f.x),G=ph(F.floating,f.y);return s?{...A,transform:"translate("+W+"px, "+G+"px)",...fh(F.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:W,top:G}},[n,s,F.floating,f.x,f.y]);return be.useMemo(()=>({...f,update:j,refs:B,elements:F,floatingStyles:E}),[f,j,B,F,E])}const mh="Popper",[gh,Fr]=it(mh),[A$,vh]=gh(mh),D$=e=>{const{__scopePopper:t,children:n}=e,[r,o]=u.useState(null);return u.createElement(A$,{scope:t,anchor:r,onAnchorChange:o},n)},_$="PopperAnchor",I$=u.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...o}=e,a=vh(_$,n),i=u.useRef(null),s=Ee(t,i);return u.useEffect(()=>{a.onAnchorChange((r==null?void 0:r.current)||i.current)}),r?null:u.createElement(ve.div,K({},o,{ref:s}))}),bh="PopperContent",[L$,LI]=gh(bh),F$=u.forwardRef((e,t)=>{var n,r,o,a,i,s,l,c;const{__scopePopper:f,side:d="bottom",sideOffset:p=0,align:v="center",alignOffset:h=0,arrowPadding:g=0,avoidCollisions:w=!0,collisionBoundary:x=[],collisionPadding:y=0,sticky:b="partial",hideWhenDetached:S=!1,updatePositionStrategy:$="optimized",onPlaced:M,...k}=e,P=vh(bh,f),[T,I]=u.useState(null),j=Ee(t,ge=>I(ge)),[z,B]=u.useState(null),F=Vs(z),E=(n=F==null?void 0:F.width)!==null&&n!==void 0?n:0,A=(r=F==null?void 0:F.height)!==null&&r!==void 0?r:0,W=d+(v!=="center"?"-"+v:""),G=typeof y=="number"?y:{top:0,right:0,bottom:0,left:0,...y},D=Array.isArray(x)?x:[x],_=D.length>0,V={padding:G,boundary:D.filter(z$),altBoundary:_},{refs:te,floatingStyles:R,placement:ne,isPositioned:ae,middlewareData:le}=N$({strategy:"fixed",placement:W,whileElementsMounted:(...ge)=>P$(...ge,{animationFrame:$==="always"}),elements:{reference:P.anchor},middleware:[s$({mainAxis:p+A,alignmentAxis:h}),w&&l$({mainAxis:!0,crossAxis:!1,limiter:b==="partial"?c$():void 0,...V}),w&&o$({...V}),u$({...V,apply:({elements:ge,rects:xe,availableWidth:Se,availableHeight:He})=>{const{width:Ge,height:ot}=xe.reference,bt=ge.floating.style;bt.setProperty("--radix-popper-available-width",`${Se}px`),bt.setProperty("--radix-popper-available-height",`${He}px`),bt.setProperty("--radix-popper-anchor-width",`${Ge}px`),bt.setProperty("--radix-popper-anchor-height",`${ot}px`)}}),z&&O$({element:z,padding:g}),j$({arrowWidth:E,arrowHeight:A}),S&&a$({strategy:"referenceHidden",...V})]}),[Q,ie]=yh(ne),U=qe(M);lt(()=>{ae&&(U==null||U())},[ae,U]);const Z=(o=le.arrow)===null||o===void 0?void 0:o.x,ce=(a=le.arrow)===null||a===void 0?void 0:a.y,N=((i=le.arrow)===null||i===void 0?void 0:i.centerOffset)!==0,[oe,se]=u.useState();return lt(()=>{T&&se(window.getComputedStyle(T).zIndex)},[T]),u.createElement("div",{ref:te.setFloating,"data-radix-popper-content-wrapper":"",style:{...R,transform:ae?R.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:oe,"--radix-popper-transform-origin":[(s=le.transformOrigin)===null||s===void 0?void 0:s.x,(l=le.transformOrigin)===null||l===void 0?void 0:l.y].join(" ")},dir:e.dir},u.createElement(L$,{scope:f,placedSide:Q,onArrowChange:B,arrowX:Z,arrowY:ce,shouldHideArrow:N},u.createElement(ve.div,K({"data-side":Q,"data-align":ie},k,{ref:j,style:{...k.style,animation:ae?void 0:"none",opacity:(c=le.hide)!==null&&c!==void 0&&c.referenceHidden?0:void 0}}))))});function z$(e){return e!==null}const j$=e=>({name:"transformOrigin",options:e,fn(t){var n,r,o,a,i;const{placement:s,rects:l,middlewareData:c}=t,d=((n=c.arrow)===null||n===void 0?void 0:n.centerOffset)!==0,p=d?0:e.arrowWidth,v=d?0:e.arrowHeight,[h,g]=yh(s),w={start:"0%",center:"50%",end:"100%"}[g],x=((r=(o=c.arrow)===null||o===void 0?void 0:o.x)!==null&&r!==void 0?r:0)+p/2,y=((a=(i=c.arrow)===null||i===void 0?void 0:i.y)!==null&&a!==void 0?a:0)+v/2;let b="",S="";return h==="bottom"?(b=d?w:`${x}px`,S=`${-v}px`):h==="top"?(b=d?w:`${x}px`,S=`${l.floating.height+v}px`):h==="right"?(b=`${-v}px`,S=d?w:`${y}px`):h==="left"&&(b=`${l.floating.width+v}px`,S=d?w:`${y}px`),{data:{x:b,y:S}}}});function yh(e){const[t,n="center"]=e.split("-");return[t,n]}const Ra=D$,$l=I$,Cl=F$,Sl=u.forwardRef((e,t)=>{var n;const{container:r=globalThis==null||(n=globalThis.document)===null||n===void 0?void 0:n.body,...o}=e;return r?En.createPortal(u.createElement(ve.div,K({},o,{ref:t})),r):null}),El="rovingFocusGroup.onEntryFocus",B$={bubbles:!1,cancelable:!0},Ml="RovingFocusGroup",[Tl,xh,W$]=ar(Ml),[V$,zr]=it(Ml,[W$]),[H$,G$]=V$(Ml),U$=u.forwardRef((e,t)=>u.createElement(Tl.Provider,{scope:e.__scopeRovingFocusGroup},u.createElement(Tl.Slot,{scope:e.__scopeRovingFocusGroup},u.createElement(Y$,K({},e,{ref:t}))))),Y$=u.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:o=!1,dir:a,currentTabStopId:i,defaultCurrentTabStopId:s,onCurrentTabStopIdChange:l,onEntryFocus:c,...f}=e,d=u.useRef(null),p=Ee(t,d),v=Pn(a),[h=null,g]=st({prop:i,defaultProp:s,onChange:l}),[w,x]=u.useState(!1),y=qe(c),b=xh(n),S=u.useRef(!1),[$,M]=u.useState(0);return u.useEffect(()=>{const k=d.current;if(k)return k.addEventListener(El,y),()=>k.removeEventListener(El,y)},[y]),u.createElement(H$,{scope:n,orientation:r,dir:v,loop:o,currentTabStopId:h,onItemFocus:u.useCallback(k=>g(k),[g]),onItemShiftTab:u.useCallback(()=>x(!0),[]),onFocusableItemAdd:u.useCallback(()=>M(k=>k+1),[]),onFocusableItemRemove:u.useCallback(()=>M(k=>k-1),[])},u.createElement(ve.div,K({tabIndex:w||$===0?-1:0,"data-orientation":r},f,{ref:p,style:{outline:"none",...e.style},onMouseDown:de(e.onMouseDown,()=>{S.current=!0}),onFocus:de(e.onFocus,k=>{const P=!S.current;if(k.target===k.currentTarget&&P&&!w){const T=new CustomEvent(El,B$);if(k.currentTarget.dispatchEvent(T),!T.defaultPrevented){const I=b().filter(E=>E.focusable),j=I.find(E=>E.active),z=I.find(E=>E.id===h),F=[j,z,...I].filter(Boolean).map(E=>E.ref.current);wh(F)}}S.current=!1}),onBlur:de(e.onBlur,()=>x(!1))})))}),q$="RovingFocusGroupItem",K$=u.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:o=!1,tabStopId:a,...i}=e,s=$t(),l=a||s,c=G$(q$,n),f=c.currentTabStopId===l,d=xh(n),{onFocusableItemAdd:p,onFocusableItemRemove:v}=c;return u.useEffect(()=>{if(r)return p(),()=>v()},[r,p,v]),u.createElement(Tl.ItemSlot,{scope:n,id:l,focusable:r,active:o},u.createElement(ve.span,K({tabIndex:f?0:-1,"data-orientation":c.orientation},i,{ref:t,onMouseDown:de(e.onMouseDown,h=>{r?c.onItemFocus(l):h.preventDefault()}),onFocus:de(e.onFocus,()=>c.onItemFocus(l)),onKeyDown:de(e.onKeyDown,h=>{if(h.key==="Tab"&&h.shiftKey){c.onItemShiftTab();return}if(h.target!==h.currentTarget)return;const g=Z$(h,c.orientation,c.dir);if(g!==void 0){h.preventDefault();let x=d().filter(y=>y.focusable).map(y=>y.ref.current);if(g==="last")x.reverse();else if(g==="prev"||g==="next"){g==="prev"&&x.reverse();const y=x.indexOf(h.currentTarget);x=c.loop?J$(x,y+1):x.slice(y+1)}setTimeout(()=>wh(x))}})})))}),X$={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function Q$(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function Z$(e,t,n){const r=Q$(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(r))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(r)))return X$[r]}function wh(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function J$(e,t){return e.map((n,r)=>e[(t+r)%e.length])}const Pl=U$,kl=K$;var R$=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},jr=new WeakMap,ei=new WeakMap,ti={},Ol=0,$h=function(e){return e&&(e.host||$h(e.parentNode))},e5=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=$h(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},t5=function(e,t,n,r){var o=e5(t,Array.isArray(e)?e:[e]);ti[n]||(ti[n]=new WeakMap);var a=ti[n],i=[],s=new Set,l=new Set(o),c=function(d){!d||s.has(d)||(s.add(d),c(d.parentNode))};o.forEach(c);var f=function(d){!d||l.has(d)||Array.prototype.forEach.call(d.children,function(p){if(s.has(p))f(p);else{var v=p.getAttribute(r),h=v!==null&&v!=="false",g=(jr.get(p)||0)+1,w=(a.get(p)||0)+1;jr.set(p,g),a.set(p,w),i.push(p),g===1&&h&&ei.set(p,!0),w===1&&p.setAttribute(n,"true"),h||p.setAttribute(r,"true")}})};return f(t),s.clear(),Ol++,function(){i.forEach(function(d){var p=jr.get(d)-1,v=a.get(d)-1;jr.set(d,p),a.set(d,v),p||(ei.has(d)||d.removeAttribute(r),ei.delete(d)),v||d.removeAttribute(n)}),Ol--,Ol||(jr=new WeakMap,jr=new WeakMap,ei=new WeakMap,ti={})}},Ch=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),o=t||R$(e);return o?(r.push.apply(r,Array.from(o.querySelectorAll("[aria-live]"))),t5(r,o,n,"aria-hidden")):function(){return null}},Rt=function(){return Rt=Object.assign||function(t){for(var n,r=1,o=arguments.length;r<o;r++){n=arguments[r];for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(t[a]=n[a])}return t},Rt.apply(this,arguments)};function Sh(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n}function n5(e,t,n){if(n||arguments.length===2)for(var r=0,o=t.length,a;r<o;r++)(a||!(r in t))&&(a||(a=Array.prototype.slice.call(t,0,r)),a[r]=t[r]);return e.concat(a||Array.prototype.slice.call(t))}typeof SuppressedError=="function"&&SuppressedError;var ni="right-scroll-bar-position",ri="width-before-scroll-bar",r5="with-scroll-bars-hidden",o5="--removed-body-scroll-bar-size";function a5(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function i5(e,t){var n=u.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var o=n.value;o!==r&&(n.value=r,n.callback(r,o))}}}})[0];return n.callback=t,n.facade}function s5(e,t){return i5(t||null,function(n){return e.forEach(function(r){return a5(r,n)})})}function l5(e){return e}function c5(e,t){t===void 0&&(t=l5);var n=[],r=!1,o={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(a){var i=t(a,r);return n.push(i),function(){n=n.filter(function(s){return s!==i})}},assignSyncMedium:function(a){for(r=!0;n.length;){var i=n;n=[],i.forEach(a)}n={push:function(s){return a(s)},filter:function(){return n}}},assignMedium:function(a){r=!0;var i=[];if(n.length){var s=n;n=[],s.forEach(a),i=n}var l=function(){var f=i;i=[],f.forEach(a)},c=function(){return Promise.resolve().then(l)};c(),n={push:function(f){i.push(f),c()},filter:function(f){return i=i.filter(f),n}}}};return o}function u5(e){e===void 0&&(e={});var t=c5(null);return t.options=Rt({async:!0,ssr:!1},e),t}var Eh=function(e){var t=e.sideCar,n=Sh(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return be.createElement(r,Rt({},n))};Eh.isSideCarExport=!0;function d5(e,t){return e.useMedium(t),Eh}var Mh=u5(),Nl=function(){},oi=be.forwardRef(function(e,t){var n=be.useRef(null),r=be.useState({onScrollCapture:Nl,onWheelCapture:Nl,onTouchMoveCapture:Nl}),o=r[0],a=r[1],i=e.forwardProps,s=e.children,l=e.className,c=e.removeScrollBar,f=e.enabled,d=e.shards,p=e.sideCar,v=e.noIsolation,h=e.inert,g=e.allowPinchZoom,w=e.as,x=w===void 0?"div":w,y=Sh(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as"]),b=p,S=s5([n,t]),$=Rt(Rt({},y),o);return be.createElement(be.Fragment,null,f&&be.createElement(b,{sideCar:Mh,removeScrollBar:c,shards:d,noIsolation:v,inert:h,setCallbacks:a,allowPinchZoom:!!g,lockRef:n}),i?be.cloneElement(be.Children.only(s),Rt(Rt({},$),{ref:S})):be.createElement(x,Rt({},$,{className:l,ref:S}),s))});oi.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},oi.classNames={fullWidth:ri,zeroRight:ni};var Th,f5=function(){if(Th)return Th;if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function p5(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=f5();return t&&e.setAttribute("nonce",t),e}function h5(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function m5(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var g5=function(){var e=0,t=null;return{add:function(n){e==0&&(t=p5())&&(h5(t,n),m5(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},v5=function(){var e=g5();return function(t,n){be.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},Ph=function(){var e=v5(),t=function(n){var r=n.styles,o=n.dynamic;return e(r,o),null};return t},b5={left:0,top:0,right:0,gap:0},Al=function(e){return parseInt(e||"",10)||0},y5=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],o=t[e==="padding"?"paddingRight":"marginRight"];return[Al(n),Al(r),Al(o)]},x5=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return b5;var t=y5(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},w5=Ph(),$5=function(e,t,n,r){var o=e.left,a=e.top,i=e.right,s=e.gap;return n===void 0&&(n="margin"),`
6
+ Defaulting to \`null\`.`}const o2=jf,a2=e2;var yo=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function kr(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function Or(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var Na={},Aa={};Object.defineProperty(Aa,"__esModule",{value:!0}),Aa.defaultOptions=void 0,Aa.defaultOptions={lowercase:!1,precision:1,space:!1,units:["","K","M","B","T","P","E"]};var Qt={};Object.defineProperty(Qt,"__esModule",{value:!0}),Qt.getLocales=Qt.getFractionDigits=Qt.roundTo=Qt.parseValue=void 0;function i2(e){const t=parseFloat(e==null?void 0:e.toString());if(isNaN(t))throw new Error("Input value is not a number");if(t>Number.MAX_SAFE_INTEGER||t<Number.MIN_SAFE_INTEGER)throw new RangeError("Input value is outside of safe integer range");return t}Qt.parseValue=i2;function s2(e,t){if(!Number.isFinite(e))throw new Error("Input value is not a finite number");if(!Number.isInteger(t)||t<0)throw new Error("Precision is not a positive integer");return Number.isInteger(e)?e:parseFloat(e.toFixed(t))}Qt.roundTo=s2;function l2(e){var t;if(Number.isInteger(e))return 0;const n=e.toString().split(".")[1];return(t=n==null?void 0:n.length)!==null&&t!==void 0?t:0}Qt.getFractionDigits=l2;function c2(){var e;return typeof navigator>"u"?[]:Array.from((e=navigator.languages)!==null&&e!==void 0?e:[])}Qt.getLocales=c2,Object.defineProperty(Na,"__esModule",{value:!0}),Na.millify=void 0;const Vf=Aa,Da=Qt,Hf=1e3;function*Gf(e){let t=Hf;for(;;){const n=e/t;if(n<1)return;yield n,t*=Hf}}function Uf(e,t){var n,r;const o=t?{...Vf.defaultOptions,...t}:Vf.defaultOptions;if(!Array.isArray(o.units)||!o.units.length)throw new Error("Option `units` must be a non-empty array");let a;try{a=Da.parseValue(e)}catch(h){return h instanceof Error&&console.warn(`WARN: ${h.message} (millify)`),String(e)}const i=a<0?"-":"";a=Math.abs(a);let s=0;for(const h of Gf(a))a=h,s+=1;if(s>=o.units.length)return e.toString();let c=Da.roundTo(a,o.precision);for(const h of Gf(c))c=h,s+=1;const f=(n=o.units[s])!==null&&n!==void 0?n:"",d=o.lowercase?f.toLowerCase():f,p=o.space?" ":"",v=c.toLocaleString((r=o.locales)!==null&&r!==void 0?r:Da.getLocales(),{minimumFractionDigits:Da.getFractionDigits(c)});return`${i}${v}${p}${d}`}Na.millify=Uf;var _a=Na.default=Uf,Ze=(e=>(e.CLOSED_ACHIEVED="CLOSED_ACHIEVED",e.CLOSED_DROPPED="CLOSED_DROPPED",e.CLOSED_NOT_ACHIEVED="CLOSED_NOT_ACHIEVED",e.ON_TRACK="ON_TRACK",e.OFF_TRACK="OFF_TRACK",e.AT_RISK="AT_RISK",e))(Ze||{});const Nr={[Ze.ON_TRACK]:{backgroundColor:"#EAEAEA",indicatorColor:"#EFFFEA",textColor:"#44812F"},[Ze.OFF_TRACK]:{backgroundColor:"#EAEAEA",indicatorColor:"#FFF6D3",textColor:"#8C6A00"},[Ze.AT_RISK]:{backgroundColor:"#EAEAEA",indicatorColor:"#FFF1E4",textColor:"#C62C02"},[Ze.CLOSED_ACHIEVED]:{backgroundColor:"#EAEAEA",indicatorColor:"#DBF2D3",textColor:"#1A5724"},[Ze.CLOSED_DROPPED]:{backgroundColor:"#EAEAEA",indicatorColor:"#CCCCCC",textColor:"#666666"},[Ze.CLOSED_NOT_ACHIEVED]:{backgroundColor:"#EAEAEA",indicatorColor:"#FFE1D9",textColor:"#A12402"}},Xs={[Ze.ON_TRACK]:"On-track",[Ze.OFF_TRACK]:"Off-track",[Ze.AT_RISK]:"At-risk",[Ze.CLOSED_ACHIEVED]:"Closed & achieved",[Ze.CLOSED_DROPPED]:"Closed & dropped",[Ze.CLOSED_NOT_ACHIEVED]:"Closed & not achieved"};function Yf({progressInPercentage:e=0,status:t=Ze.ON_TRACK}){const{backgroundColor:n,indicatorColor:r,textColor:o}=Nr[t]?Nr[t]:Nr[Ze.ON_TRACK];return m.jsxs(o2,{className:"rabbit-ds relative box-border inline-flex h-5 w-full min-w-[210px] items-start justify-start overflow-hidden rounded-md",style:{transform:"translateZ(0)",backgroundColor:n},value:e,children:[m.jsx(a2,{className:"duration-[660ms] ease-[cubic-bezier(0.65,0,0.35,1)] h-full w-full transition-transform",style:{transform:`translateX(-${100-e>100?100:100-e}%)`,backgroundColor:r}}),m.jsx("div",{className:"absolute left-0 top-0 inline-flex items-center justify-start",children:m.jsx("div",{className:"inline-flex items-center justify-start px-1 py-0.5",children:m.jsx("div",{className:"text-xs font-semibold",style:{color:o},children:Xs[t]?Xs[t]:Xs[Ze.ON_TRACK]})})}),m.jsx("div",{className:"absolute right-0 top-0 inline-flex items-center justify-start px-1 py-0.5",children:m.jsxs("div",{className:"text-right text-xs font-semibold",style:{color:o},children:[_a(e),"%"]})})]})}function Ia(e,[t,n]){return Math.min(n,Math.max(t,e))}const u2=u.createContext(void 0);function Pn(e){const t=u.useContext(u2);return e||t||"ltr"}function ar(e){const t=e+"CollectionProvider",[n,r]=it(t),[o,a]=n(t,{collectionRef:{current:null},itemMap:new Map}),i=v=>{const{scope:h,children:g}=v,w=u.useRef(null),x=u.useRef(new Map).current;return u.createElement(o,{scope:h,itemMap:x,collectionRef:w},g)},s=e+"CollectionSlot",l=u.forwardRef((v,h)=>{const{scope:g,children:w}=v,x=a(s,g),y=Ee(h,x.collectionRef);return u.createElement(Mn,{ref:y},w)}),c=e+"CollectionItemSlot",f="data-radix-collection-item",d=u.forwardRef((v,h)=>{const{scope:g,children:w,...x}=v,y=u.useRef(null),b=Ee(h,y),S=a(c,g);return u.useEffect(()=>(S.itemMap.set(y,{ref:y,...x}),()=>void S.itemMap.delete(y))),u.createElement(Mn,{[f]:"",ref:b},w)});function p(v){const h=a(e+"CollectionConsumer",v);return u.useCallback(()=>{const w=h.collectionRef.current;if(!w)return[];const x=Array.from(w.querySelectorAll(`[${f}]`));return Array.from(h.itemMap.values()).sort((S,$)=>x.indexOf(S.ref.current)-x.indexOf($.ref.current))},[h.collectionRef,h.itemMap])}return[{Provider:i,Slot:l,ItemSlot:d},p,r]}const qf=["PageUp","PageDown"],Kf=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],Xf={"from-left":["Home","PageDown","ArrowDown","ArrowLeft"],"from-right":["Home","PageDown","ArrowDown","ArrowRight"],"from-bottom":["Home","PageDown","ArrowDown","ArrowLeft"],"from-top":["Home","PageDown","ArrowUp","ArrowLeft"]},xo="Slider",[Qs,d2,f2]=ar(xo),[Qf,NI]=it(xo,[f2]),[p2,La]=Qf(xo),h2=u.forwardRef((e,t)=>{const{name:n,min:r=0,max:o=100,step:a=1,orientation:i="horizontal",disabled:s=!1,minStepsBetweenThumbs:l=0,defaultValue:c=[r],value:f,onValueChange:d=()=>{},onValueCommit:p=()=>{},inverted:v=!1,...h}=e,[g,w]=u.useState(null),x=Ee(t,F=>w(F)),y=u.useRef(new Set),b=u.useRef(0),S=i==="horizontal",$=g?!!g.closest("form"):!0,M=S?m2:g2,[k=[],P]=st({prop:f,defaultProp:c,onChange:F=>{var E;(E=[...y.current][b.current])===null||E===void 0||E.focus(),d(F)}}),T=u.useRef(k);function I(F){const E=E2(k,F);B(F,E)}function j(F){B(F,b.current)}function z(){const F=T.current[b.current];k[b.current]!==F&&p(k)}function B(F,E,{commit:A}={commit:!1}){const W=k2(a),G=O2(Math.round((F-r)/a)*a+r,W),D=Ia(G,[r,o]);P((_=[])=>{const V=C2(_,D,E);if(P2(V,l*a)){b.current=V.indexOf(D);const te=String(V)!==String(_);return te&&A&&p(V),te?V:_}else return _})}return u.createElement(p2,{scope:e.__scopeSlider,disabled:s,min:r,max:o,valueIndexToChangeRef:b,thumbs:y.current,values:k,orientation:i},u.createElement(Qs.Provider,{scope:e.__scopeSlider},u.createElement(Qs.Slot,{scope:e.__scopeSlider},u.createElement(M,K({"aria-disabled":s,"data-disabled":s?"":void 0},h,{ref:x,onPointerDown:de(h.onPointerDown,()=>{s||(T.current=k)}),min:r,max:o,inverted:v,onSlideStart:s?void 0:I,onSlideMove:s?void 0:j,onSlideEnd:s?void 0:z,onHomeKeyDown:()=>!s&&B(r,0,{commit:!0}),onEndKeyDown:()=>!s&&B(o,k.length-1,{commit:!0}),onStepKeyDown:({event:F,direction:E})=>{if(!s){const G=qf.includes(F.key)||F.shiftKey&&Kf.includes(F.key)?10:1,D=b.current,_=k[D],V=a*G*E;B(_+V,D,{commit:!0})}}})))),$&&k.map((F,E)=>u.createElement($2,{key:E,name:n?n+(k.length>1?"[]":""):void 0,value:F})))}),[Zf,Jf]=Qf(xo,{startEdge:"left",endEdge:"right",size:"width",direction:1}),m2=u.forwardRef((e,t)=>{const{min:n,max:r,dir:o,inverted:a,onSlideStart:i,onSlideMove:s,onSlideEnd:l,onStepKeyDown:c,...f}=e,[d,p]=u.useState(null),v=Ee(t,b=>p(b)),h=u.useRef(),g=Pn(o),w=g==="ltr",x=w&&!a||!w&&a;function y(b){const S=h.current||d.getBoundingClientRect(),$=[0,S.width],k=Zs($,x?[n,r]:[r,n]);return h.current=S,k(b-S.left)}return u.createElement(Zf,{scope:e.__scopeSlider,startEdge:x?"left":"right",endEdge:x?"right":"left",direction:x?1:-1,size:"width"},u.createElement(Rf,K({dir:g,"data-orientation":"horizontal"},f,{ref:v,style:{...f.style,"--radix-slider-thumb-transform":"translateX(-50%)"},onSlideStart:b=>{const S=y(b.clientX);i==null||i(S)},onSlideMove:b=>{const S=y(b.clientX);s==null||s(S)},onSlideEnd:()=>{h.current=void 0,l==null||l()},onStepKeyDown:b=>{const $=Xf[x?"from-left":"from-right"].includes(b.key);c==null||c({event:b,direction:$?-1:1})}})))}),g2=u.forwardRef((e,t)=>{const{min:n,max:r,inverted:o,onSlideStart:a,onSlideMove:i,onSlideEnd:s,onStepKeyDown:l,...c}=e,f=u.useRef(null),d=Ee(t,f),p=u.useRef(),v=!o;function h(g){const w=p.current||f.current.getBoundingClientRect(),x=[0,w.height],b=Zs(x,v?[r,n]:[n,r]);return p.current=w,b(g-w.top)}return u.createElement(Zf,{scope:e.__scopeSlider,startEdge:v?"bottom":"top",endEdge:v?"top":"bottom",size:"height",direction:v?1:-1},u.createElement(Rf,K({"data-orientation":"vertical"},c,{ref:d,style:{...c.style,"--radix-slider-thumb-transform":"translateY(50%)"},onSlideStart:g=>{const w=h(g.clientY);a==null||a(w)},onSlideMove:g=>{const w=h(g.clientY);i==null||i(w)},onSlideEnd:()=>{p.current=void 0,s==null||s()},onStepKeyDown:g=>{const x=Xf[v?"from-bottom":"from-top"].includes(g.key);l==null||l({event:g,direction:x?-1:1})}})))}),Rf=u.forwardRef((e,t)=>{const{__scopeSlider:n,onSlideStart:r,onSlideMove:o,onSlideEnd:a,onHomeKeyDown:i,onEndKeyDown:s,onStepKeyDown:l,...c}=e,f=La(xo,n);return u.createElement(ve.span,K({},c,{ref:t,onKeyDown:de(e.onKeyDown,d=>{d.key==="Home"?(i(d),d.preventDefault()):d.key==="End"?(s(d),d.preventDefault()):qf.concat(Kf).includes(d.key)&&(l(d),d.preventDefault())}),onPointerDown:de(e.onPointerDown,d=>{const p=d.target;p.setPointerCapture(d.pointerId),d.preventDefault(),f.thumbs.has(p)?p.focus():r(d)}),onPointerMove:de(e.onPointerMove,d=>{d.target.hasPointerCapture(d.pointerId)&&o(d)}),onPointerUp:de(e.onPointerUp,d=>{const p=d.target;p.hasPointerCapture(d.pointerId)&&(p.releasePointerCapture(d.pointerId),a(d))})}))}),v2="SliderTrack",b2=u.forwardRef((e,t)=>{const{__scopeSlider:n,...r}=e,o=La(v2,n);return u.createElement(ve.span,K({"data-disabled":o.disabled?"":void 0,"data-orientation":o.orientation},r,{ref:t}))}),ep="SliderRange",y2=u.forwardRef((e,t)=>{const{__scopeSlider:n,...r}=e,o=La(ep,n),a=Jf(ep,n),i=u.useRef(null),s=Ee(t,i),l=o.values.length,c=o.values.map(p=>np(p,o.min,o.max)),f=l>1?Math.min(...c):0,d=100-Math.max(...c);return u.createElement(ve.span,K({"data-orientation":o.orientation,"data-disabled":o.disabled?"":void 0},r,{ref:s,style:{...e.style,[a.startEdge]:f+"%",[a.endEdge]:d+"%"}}))}),tp="SliderThumb",x2=u.forwardRef((e,t)=>{const n=d2(e.__scopeSlider),[r,o]=u.useState(null),a=Ee(t,s=>o(s)),i=u.useMemo(()=>r?n().findIndex(s=>s.ref.current===r):-1,[n,r]);return u.createElement(w2,K({},e,{ref:a,index:i}))}),w2=u.forwardRef((e,t)=>{const{__scopeSlider:n,index:r,...o}=e,a=La(tp,n),i=Jf(tp,n),[s,l]=u.useState(null),c=Ee(t,w=>l(w)),f=Vs(s),d=a.values[r],p=d===void 0?0:np(d,a.min,a.max),v=S2(r,a.values.length),h=f==null?void 0:f[i.size],g=h?M2(h,p,i.direction):0;return u.useEffect(()=>{if(s)return a.thumbs.add(s),()=>{a.thumbs.delete(s)}},[s,a.thumbs]),u.createElement("span",{style:{transform:"var(--radix-slider-thumb-transform)",position:"absolute",[i.startEdge]:`calc(${p}% + ${g}px)`}},u.createElement(Qs.ItemSlot,{scope:e.__scopeSlider},u.createElement(ve.span,K({role:"slider","aria-label":e["aria-label"]||v,"aria-valuemin":a.min,"aria-valuenow":d,"aria-valuemax":a.max,"aria-orientation":a.orientation,"data-orientation":a.orientation,"data-disabled":a.disabled?"":void 0,tabIndex:a.disabled?void 0:0},o,{ref:c,style:d===void 0?{display:"none"}:e.style,onFocus:de(e.onFocus,()=>{a.valueIndexToChangeRef.current=r})}))))}),$2=e=>{const{value:t,...n}=e,r=u.useRef(null),o=Sa(t);return u.useEffect(()=>{const a=r.current,i=window.HTMLInputElement.prototype,l=Object.getOwnPropertyDescriptor(i,"value").set;if(o!==t&&l){const c=new Event("input",{bubbles:!0});l.call(a,t),a.dispatchEvent(c)}},[o,t]),u.createElement("input",K({style:{display:"none"}},n,{ref:r,defaultValue:t}))};function C2(e=[],t,n){const r=[...e];return r[n]=t,r.sort((o,a)=>o-a)}function np(e,t,n){const a=100/(n-t)*(e-t);return Ia(a,[0,100])}function S2(e,t){return t>2?`Value ${e+1} of ${t}`:t===2?["Minimum","Maximum"][e]:void 0}function E2(e,t){if(e.length===1)return 0;const n=e.map(o=>Math.abs(o-t)),r=Math.min(...n);return n.indexOf(r)}function M2(e,t,n){const r=e/2,a=Zs([0,50],[0,r]);return(r-a(t)*n)*n}function T2(e){return e.slice(0,-1).map((t,n)=>e[n+1]-t)}function P2(e,t){if(t>0){const n=T2(e);return Math.min(...n)>=t}return!0}function Zs(e,t){return n=>{if(e[0]===e[1]||t[0]===t[1])return t[0];const r=(t[1]-t[0])/(e[1]-e[0]);return t[0]+r*(n-e[0])}}function k2(e){return(String(e).split(".")[1]||"").length}function O2(e,t){const n=Math.pow(10,t);return Math.round(e*n)/n}const N2=h2,A2=b2,D2=y2,_2=x2;function I2({startValue:e=0,targetValue:t=100,achievedValue:n=0,isReadOnly:r=!1,status:o=Ze.ON_TRACK,onChangeEnd:a=()=>{},onChange:i=()=>{},onThumbClick:s=()=>{}}){const[l,c]=u.useState(n),[f,d]=u.useState(n),p=u.useRef(!0),v=e>t,h=v?t:e,g=v?e:t,w=v?-1:1;u.useEffect(()=>{n!==l&&c(n)},[n]),u.useEffect(()=>{p.current?p.current=!1:a(f)},[f]),u.useEffect(()=>{i(l)},[l]);const x=S=>{c(v?t+e-S:S)},y=S=>{d(v?t+e-S:S)},b=Nr[o]?Nr[o]:Nr[Ze.ON_TRACK];return m.jsxs(N2,{className:"rabbit-ds relative box-border flex w-full min-w-[200px] touch-none select-none items-center",value:[v?t+e-l:l],min:h,max:g,step:w,inverted:h>g,disabled:r,onValueCommit:S=>y(S[0]),onValueChange:S=>x(S[0]),onLostPointerCapture:()=>{f!==l&&d(l)},children:[m.jsx(A2,{className:"relative h-7 grow rounded bg-[#EAEAEA]",children:m.jsx(D2,{className:"absolute h-full rounded-l bg-white",style:{backgroundColor:b.indicatorColor}})}),m.jsx(_2,{className:"block h-7 w-7 rounded-2xl bg-primary p-0.5 focus:outline-none ","aria-label":"Volume",style:{pointerEvents:r?"none":"auto"},onClick:s,children:m.jsx(Ve,{IconSVG:Pf,className:"text-white"})})]})}const L2=be["useId".toString()]||(()=>{});let F2=0;function $t(e){const[t,n]=be.useState(L2());return lt(()=>{e||n(r=>r??String(F2++))},[e]),e||(t?`radix-${t}`:"")}const rp="Collapsible",[z2,op]=it(rp),[j2,Js]=z2(rp),B2=u.forwardRef((e,t)=>{const{__scopeCollapsible:n,open:r,defaultOpen:o,disabled:a,onOpenChange:i,...s}=e,[l=!1,c]=st({prop:r,defaultProp:o,onChange:i});return u.createElement(j2,{scope:n,disabled:a,contentId:$t(),open:l,onOpenToggle:u.useCallback(()=>c(f=>!f),[c])},u.createElement(ve.div,K({"data-state":Rs(l),"data-disabled":a?"":void 0},s,{ref:t})))}),W2="CollapsibleTrigger",V2=u.forwardRef((e,t)=>{const{__scopeCollapsible:n,...r}=e,o=Js(W2,n);return u.createElement(ve.button,K({type:"button","aria-controls":o.contentId,"aria-expanded":o.open||!1,"data-state":Rs(o.open),"data-disabled":o.disabled?"":void 0,disabled:o.disabled},r,{ref:t,onClick:de(e.onClick,o.onOpenToggle)}))}),ap="CollapsibleContent",H2=u.forwardRef((e,t)=>{const{forceMount:n,...r}=e,o=Js(ap,e.__scopeCollapsible);return u.createElement(jt,{present:n||o.open},({present:a})=>u.createElement(G2,K({},r,{ref:t,present:a})))}),G2=u.forwardRef((e,t)=>{const{__scopeCollapsible:n,present:r,children:o,...a}=e,i=Js(ap,n),[s,l]=u.useState(r),c=u.useRef(null),f=Ee(t,c),d=u.useRef(0),p=d.current,v=u.useRef(0),h=v.current,g=i.open||s,w=u.useRef(g),x=u.useRef();return u.useEffect(()=>{const y=requestAnimationFrame(()=>w.current=!1);return()=>cancelAnimationFrame(y)},[]),lt(()=>{const y=c.current;if(y){x.current=x.current||{transitionDuration:y.style.transitionDuration,animationName:y.style.animationName},y.style.transitionDuration="0s",y.style.animationName="none";const b=y.getBoundingClientRect();d.current=b.height,v.current=b.width,w.current||(y.style.transitionDuration=x.current.transitionDuration,y.style.animationName=x.current.animationName),l(r)}},[i.open,r]),u.createElement(ve.div,K({"data-state":Rs(i.open),"data-disabled":i.disabled?"":void 0,id:i.contentId,hidden:!g},a,{ref:f,style:{"--radix-collapsible-content-height":p?`${p}px`:void 0,"--radix-collapsible-content-width":h?`${h}px`:void 0,...e.style}}),g&&o)});function Rs(e){return e?"open":"closed"}const U2=B2,Y2=V2,q2=H2,kn="Accordion",K2=["Home","End","ArrowDown","ArrowUp","ArrowLeft","ArrowRight"],[el,X2,Q2]=ar(kn),[Fa,AI]=it(kn,[Q2,op]),tl=op(),ip=u.forwardRef((e,t)=>{const{type:n,...r}=e,o=r,a=r;return u.createElement(el.Provider,{scope:e.__scopeAccordion},n==="multiple"?u.createElement(ew,K({},a,{ref:t})):u.createElement(R2,K({},o,{ref:t})))});ip.propTypes={type(e){const t=e.value||e.defaultValue;return e.type&&!["single","multiple"].includes(e.type)?new Error("Invalid prop `type` supplied to `Accordion`. Expected one of `single | multiple`."):e.type==="multiple"&&typeof t=="string"?new Error("Invalid prop `type` supplied to `Accordion`. Expected `single` when `defaultValue` or `value` is type `string`."):e.type==="single"&&Array.isArray(t)?new Error("Invalid prop `type` supplied to `Accordion`. Expected `multiple` when `defaultValue` or `value` is type `string[]`."):null}};const[sp,Z2]=Fa(kn),[lp,J2]=Fa(kn,{collapsible:!1}),R2=u.forwardRef((e,t)=>{const{value:n,defaultValue:r,onValueChange:o=()=>{},collapsible:a=!1,...i}=e,[s,l]=st({prop:n,defaultProp:r,onChange:o});return u.createElement(sp,{scope:e.__scopeAccordion,value:s?[s]:[],onItemOpen:l,onItemClose:u.useCallback(()=>a&&l(""),[a,l])},u.createElement(lp,{scope:e.__scopeAccordion,collapsible:a},u.createElement(cp,K({},i,{ref:t}))))}),ew=u.forwardRef((e,t)=>{const{value:n,defaultValue:r,onValueChange:o=()=>{},...a}=e,[i=[],s]=st({prop:n,defaultProp:r,onChange:o}),l=u.useCallback(f=>s((d=[])=>[...d,f]),[s]),c=u.useCallback(f=>s((d=[])=>d.filter(p=>p!==f)),[s]);return u.createElement(sp,{scope:e.__scopeAccordion,value:i,onItemOpen:l,onItemClose:c},u.createElement(lp,{scope:e.__scopeAccordion,collapsible:!0},u.createElement(cp,K({},a,{ref:t}))))}),[tw,za]=Fa(kn),cp=u.forwardRef((e,t)=>{const{__scopeAccordion:n,disabled:r,dir:o,orientation:a="vertical",...i}=e,s=u.useRef(null),l=Ee(s,t),c=X2(n),d=Pn(o)==="ltr",p=de(e.onKeyDown,v=>{var h;if(!K2.includes(v.key))return;const g=v.target,w=c().filter(T=>{var I;return!((I=T.ref.current)!==null&&I!==void 0&&I.disabled)}),x=w.findIndex(T=>T.ref.current===g),y=w.length;if(x===-1)return;v.preventDefault();let b=x;const S=0,$=y-1,M=()=>{b=x+1,b>$&&(b=S)},k=()=>{b=x-1,b<S&&(b=$)};switch(v.key){case"Home":b=S;break;case"End":b=$;break;case"ArrowRight":a==="horizontal"&&(d?M():k());break;case"ArrowDown":a==="vertical"&&M();break;case"ArrowLeft":a==="horizontal"&&(d?k():M());break;case"ArrowUp":a==="vertical"&&k();break}const P=b%y;(h=w[P].ref.current)===null||h===void 0||h.focus()});return u.createElement(tw,{scope:n,disabled:r,direction:o,orientation:a},u.createElement(el.Slot,{scope:n},u.createElement(ve.div,K({},i,{"data-orientation":a,ref:l,onKeyDown:r?void 0:p}))))}),nl="AccordionItem",[nw,rl]=Fa(nl),rw=u.forwardRef((e,t)=>{const{__scopeAccordion:n,value:r,...o}=e,a=za(nl,n),i=Z2(nl,n),s=tl(n),l=$t(),c=r&&i.value.includes(r)||!1,f=a.disabled||e.disabled;return u.createElement(nw,{scope:n,open:c,disabled:f,triggerId:l},u.createElement(U2,K({"data-orientation":a.orientation,"data-state":dp(c)},s,o,{ref:t,disabled:f,open:c,onOpenChange:d=>{d?i.onItemOpen(r):i.onItemClose(r)}})))}),ow="AccordionHeader",aw=u.forwardRef((e,t)=>{const{__scopeAccordion:n,...r}=e,o=za(kn,n),a=rl(ow,n);return u.createElement(ve.h3,K({"data-orientation":o.orientation,"data-state":dp(a.open),"data-disabled":a.disabled?"":void 0},r,{ref:t}))}),up="AccordionTrigger",iw=u.forwardRef((e,t)=>{const{__scopeAccordion:n,...r}=e,o=za(kn,n),a=rl(up,n),i=J2(up,n),s=tl(n);return u.createElement(el.ItemSlot,{scope:n},u.createElement(Y2,K({"aria-disabled":a.open&&!i.collapsible||void 0,"data-orientation":o.orientation,id:a.triggerId},s,r,{ref:t})))}),sw="AccordionContent",lw=u.forwardRef((e,t)=>{const{__scopeAccordion:n,...r}=e,o=za(kn,n),a=rl(sw,n),i=tl(n);return u.createElement(q2,K({role:"region","aria-labelledby":a.triggerId,"data-orientation":o.orientation},i,r,{ref:t,style:{"--radix-accordion-content-height":"var(--radix-collapsible-content-height)","--radix-accordion-content-width":"var(--radix-collapsible-content-width)",...e.style}}))});function dp(e){return e?"open":"closed"}const fp=ip,pp=rw,cw=aw,hp=iw,mp=lw,gp=u.forwardRef(({children:e,...t},n)=>m.jsx(fp,{ref:n,...t,className:pe("rabbit-ds",t.className),children:e})),vp=u.forwardRef(({children:e,...t},n)=>m.jsx(pp,{ref:n,...t,className:pe("rabbit-ds",t.className),children:e})),bp=u.forwardRef(({children:e,icon:t,...n},r)=>m.jsx(cw,{className:"flex",children:m.jsxs(hp,{ref:r,...n,className:pe("rabbit-ds flex group items-center bg-transparent",n.className),children:[t?m.jsx(Ve,{"aria-hidden":!0,className:"mr-2 group-data-[state=open]:rotate-90",IconSVG:t}):null,e]})})),yp=u.forwardRef(({children:e,...t},n)=>m.jsx(mp,{ref:n,...t,className:pe("rabbit-ds",t.className),children:m.jsx("div",{className:"rabbit-ds pl-9",children:e})}));gp.displayName=fp.displayName,vp.displayName=pp.displayName,bp.displayName=hp.displayName,yp.displayName=mp.displayName;const xp="Avatar",[uw,DI]=it(xp),[dw,wp]=uw(xp),fw=u.forwardRef((e,t)=>{const{__scopeAvatar:n,...r}=e,[o,a]=u.useState("idle");return u.createElement(dw,{scope:n,imageLoadingStatus:o,onImageLoadingStatusChange:a},u.createElement(ve.span,K({},r,{ref:t})))}),pw="AvatarImage",hw=u.forwardRef((e,t)=>{const{__scopeAvatar:n,src:r,onLoadingStatusChange:o=()=>{},...a}=e,i=wp(pw,n),s=vw(r),l=qe(c=>{o(c),i.onImageLoadingStatusChange(c)});return lt(()=>{s!=="idle"&&l(s)},[s,l]),s==="loaded"?u.createElement(ve.img,K({},a,{ref:t,src:r})):null}),mw="AvatarFallback",gw=u.forwardRef((e,t)=>{const{__scopeAvatar:n,delayMs:r,...o}=e,a=wp(mw,n),[i,s]=u.useState(r===void 0);return u.useEffect(()=>{if(r!==void 0){const l=window.setTimeout(()=>s(!0),r);return()=>window.clearTimeout(l)}},[r]),i&&a.imageLoadingStatus!=="loaded"?u.createElement(ve.span,K({},o,{ref:t})):null});function vw(e){const[t,n]=u.useState("idle");return lt(()=>{if(!e){n("error");return}let r=!0;const o=new window.Image,a=i=>()=>{r&&n(i)};return n("loading"),o.onload=a("loaded"),o.onerror=a("error"),o.src=e,()=>{r=!1}},[e]),t}const $p=fw,Cp=hw,Sp=gw,bw=Be("rabbit-ds relative flex shrink-0 overflow-hidden rounded-full bg-accent",{variants:{size:{xs:"h-3 w-3 text-[4px]",sm:"h-4 w-4 text-[6px]",md:"h-6 w-6 text-[10px]",lg:"h-8 w-8 text-xs",xl:"h-10 w-10 text-sm"}},defaultVariants:{size:"md"}}),On=be.forwardRef(({className:e,size:t,...n},r)=>m.jsx($p,{ref:r,className:pe(bw({size:t}),"relative flex shrink-0 overflow-hidden rounded-full",e),...n}));On.displayName=$p.displayName;const Nn=be.forwardRef(({className:e,...t},n)=>m.jsx(Cp,{ref:n,className:pe("aspect-square h-full w-full object-cover",e),...t}));Nn.displayName=Cp.displayName;const ol=be.forwardRef(({className:e,...t},n)=>m.jsx(Sp,{ref:n,className:pe("flex h-full w-full items-center justify-center rounded-full font-medium text-[1em]",e),...t}));ol.displayName=Sp.displayName;const yw=Be("rabbit-ds inline-flex items-center justify-center gap-1 rounded px-4 py-2 font-sans text-sm font-semibold transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:pointer-events-none",{variants:{variant:{filled:"",outline:"",text:""},status:{default:"",error:""},size:{normal:"h-10",small:"h-7",icon:"h-10 w-10 p-2",smallIcon:"h-7 w-7 p-1"}},compoundVariants:[{variant:"filled",status:"default",className:"bg-primary text-white hover:bg-primary-hover focus:bg-primary-focus disabled:bg-primary-disabled"},{variant:"filled",status:"error",className:"bg-[#C62C02] text-white hover:bg-[#AA2602] focus:bg-[#A12402] disabled:bg-[#F6B9B9]"},{variant:"outline",status:"default",className:"border border-primary bg-white text-primary hover:border-primary-hover hover:text-primary-hover focus:border-primary-focus focus:text-primary-focus disabled:border-primary-focus disabled:text-primary-focus"},{variant:"outline",status:"error",className:"border border-[#C62C02] bg-white text-[#C62C02] hover:border-[#AA2602] hover:text-[#AA2602] focus:border-[#A12402] focus:text-[#A12402] disabled:border-[#F6B9B9] disabled:text-[#F6B9B9]"},{variant:"text",status:"default",className:"border-0 bg-white text-primary hover:text-primary-hover focus:text-primary-focus disabled:text-primary-focus"},{variant:"text",status:"error",className:"border-0 bg-white text-[#C62C02] hover:text-[#AA2602] focus:text-[#A12402] disabled:text-[#F6B9B9]"}],defaultVariants:{variant:"filled",status:"default",size:"normal"}}),Ep=Be("",{variants:{size:{normal:"default",small:"small",icon:"default",smallIcon:"small"}},defaultVariants:{size:"normal"}}),Zt=u.forwardRef(({className:e,variant:t,iconLeft:n=void 0,iconRight:r=void 0,status:o,size:a,asChild:i=!1,children:s,...l},c)=>{const f=i?Mn:"button";return m.jsx("div",{className:"rabbit-ds",children:m.jsxs(f,{"data-deer-btn":!0,className:pe(yw({variant:t,className:e,size:a,status:o})),ref:c,...l,children:[n?m.jsx(Ve,{IconSVG:n,size:pe(Ep({size:a}))}):null,s,r?m.jsx(Ve,{IconSVG:r,size:pe(Ep({size:a}))}):null]})})});Zt.displayName="Button";const xw=Be("rabbit-ds box-border inline-flex h-auto w-full flex-col items-start justify-start rounded-lg bg-white",{variants:{size:{default:"p-4",small:"px-3 py-2"}},defaultVariants:{size:"default"}}),al=u.forwardRef(({className:e,size:t,noShadow:n,...r},o)=>m.jsx("div",{ref:o,className:pe(xw({size:t}),n?"":"shadow-card",e),...r}));al.defaultProps={noShadow:!1,size:"default"},al.displayName="Card";const Mp=u.forwardRef(({className:e,...t},n)=>m.jsx("div",{ref:n,className:pe("flex h-auto flex-col items-start justify-start self-stretch px-1 pb-3",e),...t}));Mp.displayName="CardHeader";const Tp=u.forwardRef(({className:e,children:t,...n},r)=>m.jsx("h3",{ref:r,className:pe("text-sm font-semibold leading-5 text-font-primary",e),...n,children:t}));Tp.displayName="CardTitle";const Pp=u.forwardRef(({className:e,...t},n)=>m.jsx("p",{ref:n,className:pe("text-sm text-font-secondary",e),...t}));Pp.displayName="CardDescription";const kp=u.forwardRef(({className:e,...t},n)=>m.jsx("div",{ref:n,className:pe("text-sm w-full",e),...t}));kp.displayName="CardContent";const ww=Be("rabbit-ds box-border inline-flex h-auto min-h-8 w-full flex-row items-center justify-start gap-1 rounded-lg bg-white p-1 text-xs",{variants:{color:{success:"bg-success-bg text-success-primary",warning:"bg-warning-bg text-warning-primary"}},defaultVariants:{color:"success"}}),il=u.forwardRef(({className:e,color:t,icon:n,children:r,...o},a)=>m.jsx("div",{className:"rabbit-ds",children:m.jsxs("div",{ref:a,className:pe(ww({color:t}),e),...o,children:[n?m.jsx(Ve,{IconSVG:n}):null,r]})}));il.defaultProps={color:"success",icon:void 0},il.displayName="Caption";function De(e){const t=Object.prototype.toString.call(e);return e instanceof Date||typeof e=="object"&&t==="[object Date]"?new e.constructor(+e):typeof e=="number"||t==="[object Number]"||typeof e=="string"||t==="[object String]"?new Date(e):new Date(NaN)}function An(e,t){return e instanceof Date?new e.constructor(t):new Date(t)}function $w(e,t){const n=+De(e);return An(e,n+t)}const Op=6048e5,Cw=864e5,Sw=6e4,ja=43200,Np=1440;let Ew={};function wo(){return Ew}function $o(e,t){var s,l,c,f;const n=wo(),r=(t==null?void 0:t.weekStartsOn)??((l=(s=t==null?void 0:t.locale)==null?void 0:s.options)==null?void 0:l.weekStartsOn)??n.weekStartsOn??((f=(c=n.locale)==null?void 0:c.options)==null?void 0:f.weekStartsOn)??0,o=De(e),a=o.getDay(),i=(a<r?7:0)+a-r;return o.setDate(o.getDate()-i),o.setHours(0,0,0,0),o}function Ba(e){return $o(e,{weekStartsOn:1})}function Ap(e){const t=De(e),n=t.getFullYear(),r=An(e,0);r.setFullYear(n+1,0,4),r.setHours(0,0,0,0);const o=Ba(r),a=An(e,0);a.setFullYear(n,0,4),a.setHours(0,0,0,0);const i=Ba(a);return t.getTime()>=o.getTime()?n+1:t.getTime()>=i.getTime()?n:n-1}function Wa(e){const t=De(e);return t.setHours(0,0,0,0),t}function Va(e){const t=new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()));return t.setUTCFullYear(e.getFullYear()),e.getTime()-t.getTime()}function Mw(e,t){const n=Wa(e),r=Wa(t),o=n.getTime()-Va(n),a=r.getTime()-Va(r);return Math.round((o-a)/Cw)}function Tw(e){const t=Ap(e),n=An(e,0);return n.setFullYear(t,0,4),n.setHours(0,0,0,0),Ba(n)}function Pw(e,t){return $w(e,t*Sw)}function Ha(e,t){const n=De(e),r=De(t),o=n.getTime()-r.getTime();return o<0?-1:o>0?1:o}function kw(e,t){const n=Wa(e),r=Wa(t);return+n==+r}function Ow(e){return e instanceof Date||typeof e=="object"&&Object.prototype.toString.call(e)==="[object Date]"}function Nw(e){if(!Ow(e)&&typeof e!="number")return!1;const t=De(e);return!isNaN(Number(t))}function Aw(e,t){const n=De(e),r=De(t),o=n.getFullYear()-r.getFullYear(),a=n.getMonth()-r.getMonth();return o*12+a}function Dw(e,t){return De(e).getTime()-De(t).getTime()}function _w(e){return e?Math[e]:Math.trunc}function Iw(e){const t=De(e);return t.setHours(23,59,59,999),t}function Lw(e){const t=De(e),n=t.getMonth();return t.setFullYear(t.getFullYear(),n+1,0),t.setHours(23,59,59,999),t}function Fw(e){const t=De(e);return+Iw(t)==+Lw(t)}function zw(e,t){const n=De(e),r=De(t),o=Ha(n,r),a=Math.abs(Aw(n,r));let i;if(a<1)i=0;else{n.getMonth()===1&&n.getDate()>27&&n.setDate(30),n.setMonth(n.getMonth()-o*a);let s=Ha(n,r)===-o;Fw(De(e))&&a===1&&Ha(e,r)===1&&(s=!1),i=o*(a-Number(s))}return i===0?0:i}function jw(e,t,n){const r=Dw(e,t)/1e3;return _w(n==null?void 0:n.roundingMethod)(r)}function Bw(e){const t=De(e),n=An(e,0);return n.setFullYear(t.getFullYear(),0,1),n.setHours(0,0,0,0),n}const Ww={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},Vw=(e,t,n)=>{let r;const o=Ww[e];return typeof o=="string"?r=o:t===1?r=o.one:r=o.other.replace("{{count}}",t.toString()),n!=null&&n.addSuffix?n.comparison&&n.comparison>0?"in "+r:r+" ago":r};function sl(e){return(t={})=>{const n=t.width?String(t.width):e.defaultWidth;return e.formats[n]||e.formats[e.defaultWidth]}}const Hw={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},Gw={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},Uw={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},Yw={date:sl({formats:Hw,defaultWidth:"full"}),time:sl({formats:Gw,defaultWidth:"full"}),dateTime:sl({formats:Uw,defaultWidth:"full"})},qw={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},Kw=(e,t,n,r)=>qw[e];function Co(e){return(t,n)=>{const r=n!=null&&n.context?String(n.context):"standalone";let o;if(r==="formatting"&&e.formattingValues){const i=e.defaultFormattingWidth||e.defaultWidth,s=n!=null&&n.width?String(n.width):i;o=e.formattingValues[s]||e.formattingValues[i]}else{const i=e.defaultWidth,s=n!=null&&n.width?String(n.width):e.defaultWidth;o=e.values[s]||e.values[i]}const a=e.argumentCallback?e.argumentCallback(t):t;return o[a]}}const Xw={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},Qw={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},Zw={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},Jw={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},Rw={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},e3={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},t3={ordinalNumber:(e,t)=>{const n=Number(e),r=n%100;if(r>20||r<10)switch(r%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"},era:Co({values:Xw,defaultWidth:"wide"}),quarter:Co({values:Qw,defaultWidth:"wide",argumentCallback:e=>e-1}),month:Co({values:Zw,defaultWidth:"wide"}),day:Co({values:Jw,defaultWidth:"wide"}),dayPeriod:Co({values:Rw,defaultWidth:"wide",formattingValues:e3,defaultFormattingWidth:"wide"})};function So(e){return(t,n={})=>{const r=n.width,o=r&&e.matchPatterns[r]||e.matchPatterns[e.defaultMatchWidth],a=t.match(o);if(!a)return null;const i=a[0],s=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],l=Array.isArray(s)?r3(s,d=>d.test(i)):n3(s,d=>d.test(i));let c;c=e.valueCallback?e.valueCallback(l):l,c=n.valueCallback?n.valueCallback(c):c;const f=t.slice(i.length);return{value:c,rest:f}}}function n3(e,t){for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t(e[n]))return n}function r3(e,t){for(let n=0;n<e.length;n++)if(t(e[n]))return n}function o3(e){return(t,n={})=>{const r=t.match(e.matchPattern);if(!r)return null;const o=r[0],a=t.match(e.parsePattern);if(!a)return null;let i=e.valueCallback?e.valueCallback(a[0]):a[0];i=n.valueCallback?n.valueCallback(i):i;const s=t.slice(o.length);return{value:i,rest:s}}}const a3=/^(\d+)(th|st|nd|rd)?/i,i3=/\d+/i,s3={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},l3={any:[/^b/i,/^(a|c)/i]},c3={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},u3={any:[/1/i,/2/i,/3/i,/4/i]},d3={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},f3={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},p3={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},h3={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},m3={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},g3={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},v3={ordinalNumber:o3({matchPattern:a3,parsePattern:i3,valueCallback:e=>parseInt(e,10)}),era:So({matchPatterns:s3,defaultMatchWidth:"wide",parsePatterns:l3,defaultParseWidth:"any"}),quarter:So({matchPatterns:c3,defaultMatchWidth:"wide",parsePatterns:u3,defaultParseWidth:"any",valueCallback:e=>e+1}),month:So({matchPatterns:d3,defaultMatchWidth:"wide",parsePatterns:f3,defaultParseWidth:"any"}),day:So({matchPatterns:p3,defaultMatchWidth:"wide",parsePatterns:h3,defaultParseWidth:"any"}),dayPeriod:So({matchPatterns:m3,defaultMatchWidth:"any",parsePatterns:g3,defaultParseWidth:"any"})},Dp={code:"en-US",formatDistance:Vw,formatLong:Yw,formatRelative:Kw,localize:t3,match:v3,options:{weekStartsOn:0,firstWeekContainsDate:1}};function b3(e){const t=De(e);return Mw(t,Bw(t))+1}function y3(e){const t=De(e),n=Ba(t).getTime()-Tw(t).getTime();return Math.round(n/Op)+1}function _p(e,t){var f,d,p,v;const n=De(e),r=n.getFullYear(),o=wo(),a=(t==null?void 0:t.firstWeekContainsDate)??((d=(f=t==null?void 0:t.locale)==null?void 0:f.options)==null?void 0:d.firstWeekContainsDate)??o.firstWeekContainsDate??((v=(p=o.locale)==null?void 0:p.options)==null?void 0:v.firstWeekContainsDate)??1,i=An(e,0);i.setFullYear(r+1,0,a),i.setHours(0,0,0,0);const s=$o(i,t),l=An(e,0);l.setFullYear(r,0,a),l.setHours(0,0,0,0);const c=$o(l,t);return n.getTime()>=s.getTime()?r+1:n.getTime()>=c.getTime()?r:r-1}function x3(e,t){var s,l,c,f;const n=wo(),r=(t==null?void 0:t.firstWeekContainsDate)??((l=(s=t==null?void 0:t.locale)==null?void 0:s.options)==null?void 0:l.firstWeekContainsDate)??n.firstWeekContainsDate??((f=(c=n.locale)==null?void 0:c.options)==null?void 0:f.firstWeekContainsDate)??1,o=_p(e,t),a=An(e,0);return a.setFullYear(o,0,r),a.setHours(0,0,0,0),$o(a,t)}function w3(e,t){const n=De(e),r=$o(n,t).getTime()-x3(n,t).getTime();return Math.round(r/Op)+1}function _e(e,t){const n=e<0?"-":"",r=Math.abs(e).toString().padStart(t,"0");return n+r}const Dn={y(e,t){const n=e.getFullYear(),r=n>0?n:1-n;return _e(t==="yy"?r%100:r,t.length)},M(e,t){const n=e.getMonth();return t==="M"?String(n+1):_e(n+1,2)},d(e,t){return _e(e.getDate(),t.length)},a(e,t){const n=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.toUpperCase();case"aaa":return n;case"aaaaa":return n[0];case"aaaa":default:return n==="am"?"a.m.":"p.m."}},h(e,t){return _e(e.getHours()%12||12,t.length)},H(e,t){return _e(e.getHours(),t.length)},m(e,t){return _e(e.getMinutes(),t.length)},s(e,t){return _e(e.getSeconds(),t.length)},S(e,t){const n=t.length,r=e.getMilliseconds(),o=Math.floor(r*Math.pow(10,n-3));return _e(o,t.length)}},Ar={am:"am",pm:"pm",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},$3={G:function(e,t,n){const r=e.getFullYear()>0?1:0;switch(t){case"G":case"GG":case"GGG":return n.era(r,{width:"abbreviated"});case"GGGGG":return n.era(r,{width:"narrow"});case"GGGG":default:return n.era(r,{width:"wide"})}},y:function(e,t,n){if(t==="yo"){const r=e.getFullYear(),o=r>0?r:1-r;return n.ordinalNumber(o,{unit:"year"})}return Dn.y(e,t)},Y:function(e,t,n,r){const o=_p(e,r),a=o>0?o:1-o;if(t==="YY"){const i=a%100;return _e(i,2)}return t==="Yo"?n.ordinalNumber(a,{unit:"year"}):_e(a,t.length)},R:function(e,t){const n=Ap(e);return _e(n,t.length)},u:function(e,t){const n=e.getFullYear();return _e(n,t.length)},Q:function(e,t,n){const r=Math.ceil((e.getMonth()+1)/3);switch(t){case"Q":return String(r);case"QQ":return _e(r,2);case"Qo":return n.ordinalNumber(r,{unit:"quarter"});case"QQQ":return n.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return n.quarter(r,{width:"narrow",context:"formatting"});case"QQQQ":default:return n.quarter(r,{width:"wide",context:"formatting"})}},q:function(e,t,n){const r=Math.ceil((e.getMonth()+1)/3);switch(t){case"q":return String(r);case"qq":return _e(r,2);case"qo":return n.ordinalNumber(r,{unit:"quarter"});case"qqq":return n.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return n.quarter(r,{width:"narrow",context:"standalone"});case"qqqq":default:return n.quarter(r,{width:"wide",context:"standalone"})}},M:function(e,t,n){const r=e.getMonth();switch(t){case"M":case"MM":return Dn.M(e,t);case"Mo":return n.ordinalNumber(r+1,{unit:"month"});case"MMM":return n.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return n.month(r,{width:"narrow",context:"formatting"});case"MMMM":default:return n.month(r,{width:"wide",context:"formatting"})}},L:function(e,t,n){const r=e.getMonth();switch(t){case"L":return String(r+1);case"LL":return _e(r+1,2);case"Lo":return n.ordinalNumber(r+1,{unit:"month"});case"LLL":return n.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return n.month(r,{width:"narrow",context:"standalone"});case"LLLL":default:return n.month(r,{width:"wide",context:"standalone"})}},w:function(e,t,n,r){const o=w3(e,r);return t==="wo"?n.ordinalNumber(o,{unit:"week"}):_e(o,t.length)},I:function(e,t,n){const r=y3(e);return t==="Io"?n.ordinalNumber(r,{unit:"week"}):_e(r,t.length)},d:function(e,t,n){return t==="do"?n.ordinalNumber(e.getDate(),{unit:"date"}):Dn.d(e,t)},D:function(e,t,n){const r=b3(e);return t==="Do"?n.ordinalNumber(r,{unit:"dayOfYear"}):_e(r,t.length)},E:function(e,t,n){const r=e.getDay();switch(t){case"E":case"EE":case"EEE":return n.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return n.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(r,{width:"short",context:"formatting"});case"EEEE":default:return n.day(r,{width:"wide",context:"formatting"})}},e:function(e,t,n,r){const o=e.getDay(),a=(o-r.weekStartsOn+8)%7||7;switch(t){case"e":return String(a);case"ee":return _e(a,2);case"eo":return n.ordinalNumber(a,{unit:"day"});case"eee":return n.day(o,{width:"abbreviated",context:"formatting"});case"eeeee":return n.day(o,{width:"narrow",context:"formatting"});case"eeeeee":return n.day(o,{width:"short",context:"formatting"});case"eeee":default:return n.day(o,{width:"wide",context:"formatting"})}},c:function(e,t,n,r){const o=e.getDay(),a=(o-r.weekStartsOn+8)%7||7;switch(t){case"c":return String(a);case"cc":return _e(a,t.length);case"co":return n.ordinalNumber(a,{unit:"day"});case"ccc":return n.day(o,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(o,{width:"narrow",context:"standalone"});case"cccccc":return n.day(o,{width:"short",context:"standalone"});case"cccc":default:return n.day(o,{width:"wide",context:"standalone"})}},i:function(e,t,n){const r=e.getDay(),o=r===0?7:r;switch(t){case"i":return String(o);case"ii":return _e(o,t.length);case"io":return n.ordinalNumber(o,{unit:"day"});case"iii":return n.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return n.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return n.day(r,{width:"short",context:"formatting"});case"iiii":default:return n.day(r,{width:"wide",context:"formatting"})}},a:function(e,t,n){const o=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"aaa":return n.dayPeriod(o,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return n.dayPeriod(o,{width:"narrow",context:"formatting"});case"aaaa":default:return n.dayPeriod(o,{width:"wide",context:"formatting"})}},b:function(e,t,n){const r=e.getHours();let o;switch(r===12?o=Ar.noon:r===0?o=Ar.midnight:o=r/12>=1?"pm":"am",t){case"b":case"bb":return n.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"bbb":return n.dayPeriod(o,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return n.dayPeriod(o,{width:"narrow",context:"formatting"});case"bbbb":default:return n.dayPeriod(o,{width:"wide",context:"formatting"})}},B:function(e,t,n){const r=e.getHours();let o;switch(r>=17?o=Ar.evening:r>=12?o=Ar.afternoon:r>=4?o=Ar.morning:o=Ar.night,t){case"B":case"BB":case"BBB":return n.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"BBBBB":return n.dayPeriod(o,{width:"narrow",context:"formatting"});case"BBBB":default:return n.dayPeriod(o,{width:"wide",context:"formatting"})}},h:function(e,t,n){if(t==="ho"){let r=e.getHours()%12;return r===0&&(r=12),n.ordinalNumber(r,{unit:"hour"})}return Dn.h(e,t)},H:function(e,t,n){return t==="Ho"?n.ordinalNumber(e.getHours(),{unit:"hour"}):Dn.H(e,t)},K:function(e,t,n){const r=e.getHours()%12;return t==="Ko"?n.ordinalNumber(r,{unit:"hour"}):_e(r,t.length)},k:function(e,t,n){let r=e.getHours();return r===0&&(r=24),t==="ko"?n.ordinalNumber(r,{unit:"hour"}):_e(r,t.length)},m:function(e,t,n){return t==="mo"?n.ordinalNumber(e.getMinutes(),{unit:"minute"}):Dn.m(e,t)},s:function(e,t,n){return t==="so"?n.ordinalNumber(e.getSeconds(),{unit:"second"}):Dn.s(e,t)},S:function(e,t){return Dn.S(e,t)},X:function(e,t,n,r){const a=(r._originalDate||e).getTimezoneOffset();if(a===0)return"Z";switch(t){case"X":return Lp(a);case"XXXX":case"XX":return ir(a);case"XXXXX":case"XXX":default:return ir(a,":")}},x:function(e,t,n,r){const a=(r._originalDate||e).getTimezoneOffset();switch(t){case"x":return Lp(a);case"xxxx":case"xx":return ir(a);case"xxxxx":case"xxx":default:return ir(a,":")}},O:function(e,t,n,r){const a=(r._originalDate||e).getTimezoneOffset();switch(t){case"O":case"OO":case"OOO":return"GMT"+Ip(a,":");case"OOOO":default:return"GMT"+ir(a,":")}},z:function(e,t,n,r){const a=(r._originalDate||e).getTimezoneOffset();switch(t){case"z":case"zz":case"zzz":return"GMT"+Ip(a,":");case"zzzz":default:return"GMT"+ir(a,":")}},t:function(e,t,n,r){const o=r._originalDate||e,a=Math.floor(o.getTime()/1e3);return _e(a,t.length)},T:function(e,t,n,r){const a=(r._originalDate||e).getTime();return _e(a,t.length)}};function Ip(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),o=Math.floor(r/60),a=r%60;return a===0?n+String(o):n+String(o)+t+_e(a,2)}function Lp(e,t){return e%60===0?(e>0?"-":"+")+_e(Math.abs(e)/60,2):ir(e,t)}function ir(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),o=_e(Math.floor(r/60),2),a=_e(r%60,2);return n+o+t+a}const Fp=(e,t)=>{switch(e){case"P":return t.date({width:"short"});case"PP":return t.date({width:"medium"});case"PPP":return t.date({width:"long"});case"PPPP":default:return t.date({width:"full"})}},zp=(e,t)=>{switch(e){case"p":return t.time({width:"short"});case"pp":return t.time({width:"medium"});case"ppp":return t.time({width:"long"});case"pppp":default:return t.time({width:"full"})}},C3={p:zp,P:(e,t)=>{const n=e.match(/(P+)(p+)?/)||[],r=n[1],o=n[2];if(!o)return Fp(e,t);let a;switch(r){case"P":a=t.dateTime({width:"short"});break;case"PP":a=t.dateTime({width:"medium"});break;case"PPP":a=t.dateTime({width:"long"});break;case"PPPP":default:a=t.dateTime({width:"full"});break}return a.replace("{{date}}",Fp(r,t)).replace("{{time}}",zp(o,t))}},S3=["D","DD"],E3=["YY","YYYY"];function M3(e){return S3.indexOf(e)!==-1}function T3(e){return E3.indexOf(e)!==-1}function jp(e,t,n){if(e==="YYYY")throw new RangeError(`Use \`yyyy\` instead of \`YYYY\` (in \`${t}\`) for formatting years to the input \`${n}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`);if(e==="YY")throw new RangeError(`Use \`yy\` instead of \`YY\` (in \`${t}\`) for formatting years to the input \`${n}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`);if(e==="D")throw new RangeError(`Use \`d\` instead of \`D\` (in \`${t}\`) for formatting days of the month to the input \`${n}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`);if(e==="DD")throw new RangeError(`Use \`dd\` instead of \`DD\` (in \`${t}\`) for formatting days of the month to the input \`${n}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`)}const P3=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,k3=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,O3=/^'([^]*?)'?$/,N3=/''/g,A3=/[a-zA-Z]/;function ll(e,t,n){var f,d,p,v,h,g,w,x;const r=wo(),o=(n==null?void 0:n.locale)??r.locale??Dp,a=(n==null?void 0:n.firstWeekContainsDate)??((d=(f=n==null?void 0:n.locale)==null?void 0:f.options)==null?void 0:d.firstWeekContainsDate)??r.firstWeekContainsDate??((v=(p=r.locale)==null?void 0:p.options)==null?void 0:v.firstWeekContainsDate)??1,i=(n==null?void 0:n.weekStartsOn)??((g=(h=n==null?void 0:n.locale)==null?void 0:h.options)==null?void 0:g.weekStartsOn)??r.weekStartsOn??((x=(w=r.locale)==null?void 0:w.options)==null?void 0:x.weekStartsOn)??0,s=De(e);if(!Nw(s))throw new RangeError("Invalid time value");const l={firstWeekContainsDate:a,weekStartsOn:i,locale:o,_originalDate:s};return t.match(k3).map(function(y){const b=y[0];if(b==="p"||b==="P"){const S=C3[b];return S(y,o.formatLong)}return y}).join("").match(P3).map(function(y){if(y==="''")return"'";const b=y[0];if(b==="'")return D3(y);const S=$3[b];if(S)return!(n!=null&&n.useAdditionalWeekYearTokens)&&T3(y)&&jp(y,t,String(e)),!(n!=null&&n.useAdditionalDayOfYearTokens)&&M3(y)&&jp(y,t,String(e)),S(s,y,o.localize,l);if(b.match(A3))throw new RangeError("Format string contains an unescaped latin alphabet character `"+b+"`");return y}).join("")}function D3(e){const t=e.match(O3);return t?t[1].replace(N3,"'"):e}function _3(e,t,n){const r=wo(),o=(n==null?void 0:n.locale)??r.locale??Dp,a=2520,i=Ha(e,t);if(isNaN(i))throw new RangeError("Invalid time value");const s=Object.assign({},n,{addSuffix:n==null?void 0:n.addSuffix,comparison:i});let l,c;i>0?(l=De(t),c=De(e)):(l=De(e),c=De(t));const f=jw(c,l),d=(Va(c)-Va(l))/1e3,p=Math.round((f-d)/60);let v;if(p<2)return n!=null&&n.includeSeconds?f<5?o.formatDistance("lessThanXSeconds",5,s):f<10?o.formatDistance("lessThanXSeconds",10,s):f<20?o.formatDistance("lessThanXSeconds",20,s):f<40?o.formatDistance("halfAMinute",0,s):f<60?o.formatDistance("lessThanXMinutes",1,s):o.formatDistance("xMinutes",1,s):p===0?o.formatDistance("lessThanXMinutes",1,s):o.formatDistance("xMinutes",p,s);if(p<45)return o.formatDistance("xMinutes",p,s);if(p<90)return o.formatDistance("aboutXHours",1,s);if(p<Np){const h=Math.round(p/60);return o.formatDistance("aboutXHours",h,s)}else{if(p<a)return o.formatDistance("xDays",1,s);if(p<ja){const h=Math.round(p/Np);return o.formatDistance("xDays",h,s)}else if(p<ja*2)return v=Math.round(p/ja),o.formatDistance("aboutXMonths",v,s)}if(v=zw(c,l),v<12){const h=Math.round(p/ja);return o.formatDistance("xMonths",h,s)}else{const h=v%12,g=Math.floor(v/12);return h<3?o.formatDistance("aboutXYears",g,s):h<9?o.formatDistance("overXYears",g,s):o.formatDistance("almostXYears",g+1,s)}}function I3(e,t){return _3(e,Date.now(),t)}function L3(e,t){const n=De(e),r=De(t);return n.getTime()>r.getTime()}function cl({date:e,duration:t,showRelativeTime:n=!1,showTime:r=!1,dateFormat:o="MMM dd, yyyy",timeFormat:a="HH:mm",highlightDate:i=n,className:s}){const l=new Date,c=kw(e,l)||L3(e,l);let f="";n?(f=I3(e,{addSuffix:!0}),f=zx(f)):f=ll(e,o);const d=c?"text-functional-warn font-semibold":"";return m.jsx("div",{className:"rabbit-ds",children:m.jsxs("span",{className:pe("text-sm",i&&d,s),children:[f,r&&" • ",r&&ll(e,a),r&&t&&` - ${ll(Pw(e,t),a)}`]})})}function F3(e,t=globalThis==null?void 0:globalThis.document){const n=qe(e);u.useEffect(()=>{const r=o=>{o.key==="Escape"&&n(o)};return t.addEventListener("keydown",r),()=>t.removeEventListener("keydown",r)},[n,t])}const ul="dismissableLayer.update",z3="dismissableLayer.pointerDownOutside",j3="dismissableLayer.focusOutside";let Bp;const B3=u.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Ga=u.forwardRef((e,t)=>{var n;const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:o,onPointerDownOutside:a,onFocusOutside:i,onInteractOutside:s,onDismiss:l,...c}=e,f=u.useContext(B3),[d,p]=u.useState(null),v=(n=d==null?void 0:d.ownerDocument)!==null&&n!==void 0?n:globalThis==null?void 0:globalThis.document,[,h]=u.useState({}),g=Ee(t,P=>p(P)),w=Array.from(f.layers),[x]=[...f.layersWithOutsidePointerEventsDisabled].slice(-1),y=w.indexOf(x),b=d?w.indexOf(d):-1,S=f.layersWithOutsidePointerEventsDisabled.size>0,$=b>=y,M=W3(P=>{const T=P.target,I=[...f.branches].some(j=>j.contains(T));!$||I||(a==null||a(P),s==null||s(P),P.defaultPrevented||l==null||l())},v),k=V3(P=>{const T=P.target;[...f.branches].some(j=>j.contains(T))||(i==null||i(P),s==null||s(P),P.defaultPrevented||l==null||l())},v);return F3(P=>{b===f.layers.size-1&&(o==null||o(P),!P.defaultPrevented&&l&&(P.preventDefault(),l()))},v),u.useEffect(()=>{if(d)return r&&(f.layersWithOutsidePointerEventsDisabled.size===0&&(Bp=v.body.style.pointerEvents,v.body.style.pointerEvents="none"),f.layersWithOutsidePointerEventsDisabled.add(d)),f.layers.add(d),Wp(),()=>{r&&f.layersWithOutsidePointerEventsDisabled.size===1&&(v.body.style.pointerEvents=Bp)}},[d,v,r,f]),u.useEffect(()=>()=>{d&&(f.layers.delete(d),f.layersWithOutsidePointerEventsDisabled.delete(d),Wp())},[d,f]),u.useEffect(()=>{const P=()=>h({});return document.addEventListener(ul,P),()=>document.removeEventListener(ul,P)},[]),u.createElement(ve.div,K({},c,{ref:g,style:{pointerEvents:S?$?"auto":"none":void 0,...e.style},onFocusCapture:de(e.onFocusCapture,k.onFocusCapture),onBlurCapture:de(e.onBlurCapture,k.onBlurCapture),onPointerDownCapture:de(e.onPointerDownCapture,M.onPointerDownCapture)}))});function W3(e,t=globalThis==null?void 0:globalThis.document){const n=qe(e),r=u.useRef(!1),o=u.useRef(()=>{});return u.useEffect(()=>{const a=s=>{if(s.target&&!r.current){let c=function(){Vp(z3,n,l,{discrete:!0})};const l={originalEvent:s};s.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=c,t.addEventListener("click",o.current,{once:!0})):c()}else t.removeEventListener("click",o.current);r.current=!1},i=window.setTimeout(()=>{t.addEventListener("pointerdown",a)},0);return()=>{window.clearTimeout(i),t.removeEventListener("pointerdown",a),t.removeEventListener("click",o.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function V3(e,t=globalThis==null?void 0:globalThis.document){const n=qe(e),r=u.useRef(!1);return u.useEffect(()=>{const o=a=>{a.target&&!r.current&&Vp(j3,n,{originalEvent:a},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function Wp(){const e=new CustomEvent(ul);document.dispatchEvent(e)}function Vp(e,t,n,{discrete:r}){const o=n.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?Ma(o,a):o.dispatchEvent(a)}let dl=0;function Hp(){u.useEffect(()=>{var e,t;const n=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",(e=n[0])!==null&&e!==void 0?e:Gp()),document.body.insertAdjacentElement("beforeend",(t=n[1])!==null&&t!==void 0?t:Gp()),dl++,()=>{dl===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(r=>r.remove()),dl--}},[])}function Gp(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.cssText="outline: none; opacity: 0; position: fixed; pointer-events: none",e}const fl="focusScope.autoFocusOnMount",pl="focusScope.autoFocusOnUnmount",Up={bubbles:!1,cancelable:!0},Yp=u.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:o,onUnmountAutoFocus:a,...i}=e,[s,l]=u.useState(null),c=qe(o),f=qe(a),d=u.useRef(null),p=Ee(t,g=>l(g)),v=u.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;u.useEffect(()=>{if(r){let g=function(b){if(v.paused||!s)return;const S=b.target;s.contains(S)?d.current=S:_n(d.current,{select:!0})},w=function(b){if(v.paused||!s)return;const S=b.relatedTarget;S!==null&&(s.contains(S)||_n(d.current,{select:!0}))},x=function(b){if(document.activeElement===document.body)for(const $ of b)$.removedNodes.length>0&&_n(s)};document.addEventListener("focusin",g),document.addEventListener("focusout",w);const y=new MutationObserver(x);return s&&y.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",g),document.removeEventListener("focusout",w),y.disconnect()}}},[r,s,v.paused]),u.useEffect(()=>{if(s){Xp.add(v);const g=document.activeElement;if(!s.contains(g)){const x=new CustomEvent(fl,Up);s.addEventListener(fl,c),s.dispatchEvent(x),x.defaultPrevented||(H3(K3(qp(s)),{select:!0}),document.activeElement===g&&_n(s))}return()=>{s.removeEventListener(fl,c),setTimeout(()=>{const x=new CustomEvent(pl,Up);s.addEventListener(pl,f),s.dispatchEvent(x),x.defaultPrevented||_n(g??document.body,{select:!0}),s.removeEventListener(pl,f),Xp.remove(v)},0)}}},[s,c,f,v]);const h=u.useCallback(g=>{if(!n&&!r||v.paused)return;const w=g.key==="Tab"&&!g.altKey&&!g.ctrlKey&&!g.metaKey,x=document.activeElement;if(w&&x){const y=g.currentTarget,[b,S]=G3(y);b&&S?!g.shiftKey&&x===S?(g.preventDefault(),n&&_n(b,{select:!0})):g.shiftKey&&x===b&&(g.preventDefault(),n&&_n(S,{select:!0})):x===y&&g.preventDefault()}},[n,r,v.paused]);return u.createElement(ve.div,K({tabIndex:-1},i,{ref:p,onKeyDown:h}))});function H3(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(_n(r,{select:t}),document.activeElement!==n)return}function G3(e){const t=qp(e),n=Kp(t,e),r=Kp(t.reverse(),e);return[n,r]}function qp(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function Kp(e,t){for(const n of e)if(!U3(n,{upTo:t}))return n}function U3(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 Y3(e){return e instanceof HTMLInputElement&&"select"in e}function _n(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&Y3(e)&&t&&e.select()}}const Xp=q3();function q3(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=Qp(e,t),e.unshift(t)},remove(t){var n;e=Qp(e,t),(n=e[0])===null||n===void 0||n.resume()}}}function Qp(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function K3(e){return e.filter(t=>t.tagName!=="A")}const X3=["top","right","bottom","left"],In=Math.min,Pt=Math.max,Ua=Math.round,Ya=Math.floor,Ln=e=>({x:e,y:e}),Q3={left:"right",right:"left",bottom:"top",top:"bottom"},Z3={start:"end",end:"start"};function hl(e,t,n){return Pt(e,In(t,n))}function cn(e,t){return typeof e=="function"?e(t):e}function un(e){return e.split("-")[0]}function Dr(e){return e.split("-")[1]}function ml(e){return e==="x"?"y":"x"}function gl(e){return e==="y"?"height":"width"}function _r(e){return["top","bottom"].includes(un(e))?"y":"x"}function vl(e){return ml(_r(e))}function J3(e,t,n){n===void 0&&(n=!1);const r=Dr(e),o=vl(e),a=gl(o);let i=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[a]>t.floating[a]&&(i=qa(i)),[i,qa(i)]}function R3(e){const t=qa(e);return[bl(e),t,bl(t)]}function bl(e){return e.replace(/start|end/g,t=>Z3[t])}function e$(e,t,n){const r=["left","right"],o=["right","left"],a=["top","bottom"],i=["bottom","top"];switch(e){case"top":case"bottom":return n?t?o:r:t?r:o;case"left":case"right":return t?a:i;default:return[]}}function t$(e,t,n,r){const o=Dr(e);let a=e$(un(e),n==="start",r);return o&&(a=a.map(i=>i+"-"+o),t&&(a=a.concat(a.map(bl)))),a}function qa(e){return e.replace(/left|right|bottom|top/g,t=>Q3[t])}function n$(e){return{top:0,right:0,bottom:0,left:0,...e}}function Zp(e){return typeof e!="number"?n$(e):{top:e,right:e,bottom:e,left:e}}function Ka(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}function Jp(e,t,n){let{reference:r,floating:o}=e;const a=_r(t),i=vl(t),s=gl(i),l=un(t),c=a==="y",f=r.x+r.width/2-o.width/2,d=r.y+r.height/2-o.height/2,p=r[s]/2-o[s]/2;let v;switch(l){case"top":v={x:f,y:r.y-o.height};break;case"bottom":v={x:f,y:r.y+r.height};break;case"right":v={x:r.x+r.width,y:d};break;case"left":v={x:r.x-o.width,y:d};break;default:v={x:r.x,y:r.y}}switch(Dr(t)){case"start":v[i]-=p*(n&&c?-1:1);break;case"end":v[i]+=p*(n&&c?-1:1);break}return v}const r$=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:a=[],platform:i}=n,s=a.filter(Boolean),l=await(i.isRTL==null?void 0:i.isRTL(t));let c=await i.getElementRects({reference:e,floating:t,strategy:o}),{x:f,y:d}=Jp(c,r,l),p=r,v={},h=0;for(let g=0;g<s.length;g++){const{name:w,fn:x}=s[g],{x:y,y:b,data:S,reset:$}=await x({x:f,y:d,initialPlacement:r,placement:p,strategy:o,middlewareData:v,rects:c,platform:i,elements:{reference:e,floating:t}});if(f=y??f,d=b??d,v={...v,[w]:{...v[w],...S}},$&&h<=50){h++,typeof $=="object"&&($.placement&&(p=$.placement),$.rects&&(c=$.rects===!0?await i.getElementRects({reference:e,floating:t,strategy:o}):$.rects),{x:f,y:d}=Jp(c,p,l)),g=-1;continue}}return{x:f,y:d,placement:p,strategy:o,middlewareData:v}};async function Eo(e,t){var n;t===void 0&&(t={});const{x:r,y:o,platform:a,rects:i,elements:s,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:f="viewport",elementContext:d="floating",altBoundary:p=!1,padding:v=0}=cn(t,e),h=Zp(v),w=s[p?d==="floating"?"reference":"floating":d],x=Ka(await a.getClippingRect({element:(n=await(a.isElement==null?void 0:a.isElement(w)))==null||n?w:w.contextElement||await(a.getDocumentElement==null?void 0:a.getDocumentElement(s.floating)),boundary:c,rootBoundary:f,strategy:l})),y=d==="floating"?{...i.floating,x:r,y:o}:i.reference,b=await(a.getOffsetParent==null?void 0:a.getOffsetParent(s.floating)),S=await(a.isElement==null?void 0:a.isElement(b))?await(a.getScale==null?void 0:a.getScale(b))||{x:1,y:1}:{x:1,y:1},$=Ka(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({rect:y,offsetParent:b,strategy:l}):y);return{top:(x.top-$.top+h.top)/S.y,bottom:($.bottom-x.bottom+h.bottom)/S.y,left:(x.left-$.left+h.left)/S.x,right:($.right-x.right+h.right)/S.x}}const Rp=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:o,rects:a,platform:i,elements:s,middlewareData:l}=t,{element:c,padding:f=0}=cn(e,t)||{};if(c==null)return{};const d=Zp(f),p={x:n,y:r},v=vl(o),h=gl(v),g=await i.getDimensions(c),w=v==="y",x=w?"top":"left",y=w?"bottom":"right",b=w?"clientHeight":"clientWidth",S=a.reference[h]+a.reference[v]-p[v]-a.floating[h],$=p[v]-a.reference[v],M=await(i.getOffsetParent==null?void 0:i.getOffsetParent(c));let k=M?M[b]:0;(!k||!await(i.isElement==null?void 0:i.isElement(M)))&&(k=s.floating[b]||a.floating[h]);const P=S/2-$/2,T=k/2-g[h]/2-1,I=In(d[x],T),j=In(d[y],T),z=I,B=k-g[h]-j,F=k/2-g[h]/2+P,E=hl(z,F,B),A=!l.arrow&&Dr(o)!=null&&F!=E&&a.reference[h]/2-(F<z?I:j)-g[h]/2<0,W=A?F<z?F-z:F-B:0;return{[v]:p[v]+W,data:{[v]:E,centerOffset:F-E-W,...A&&{alignmentOffset:W}},reset:A}}}),o$=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:o,middlewareData:a,rects:i,initialPlacement:s,platform:l,elements:c}=t,{mainAxis:f=!0,crossAxis:d=!0,fallbackPlacements:p,fallbackStrategy:v="bestFit",fallbackAxisSideDirection:h="none",flipAlignment:g=!0,...w}=cn(e,t);if((n=a.arrow)!=null&&n.alignmentOffset)return{};const x=un(o),y=un(s)===s,b=await(l.isRTL==null?void 0:l.isRTL(c.floating)),S=p||(y||!g?[qa(s)]:R3(s));!p&&h!=="none"&&S.push(...t$(s,g,h,b));const $=[s,...S],M=await Eo(t,w),k=[];let P=((r=a.flip)==null?void 0:r.overflows)||[];if(f&&k.push(M[x]),d){const z=J3(o,i,b);k.push(M[z[0]],M[z[1]])}if(P=[...P,{placement:o,overflows:k}],!k.every(z=>z<=0)){var T,I;const z=(((T=a.flip)==null?void 0:T.index)||0)+1,B=$[z];if(B)return{data:{index:z,overflows:P},reset:{placement:B}};let F=(I=P.filter(E=>E.overflows[0]<=0).sort((E,A)=>E.overflows[1]-A.overflows[1])[0])==null?void 0:I.placement;if(!F)switch(v){case"bestFit":{var j;const E=(j=P.map(A=>[A.placement,A.overflows.filter(W=>W>0).reduce((W,G)=>W+G,0)]).sort((A,W)=>A[1]-W[1])[0])==null?void 0:j[0];E&&(F=E);break}case"initialPlacement":F=s;break}if(o!==F)return{reset:{placement:F}}}return{}}}};function eh(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function th(e){return X3.some(t=>e[t]>=0)}const a$=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...o}=cn(e,t);switch(r){case"referenceHidden":{const a=await Eo(t,{...o,elementContext:"reference"}),i=eh(a,n.reference);return{data:{referenceHiddenOffsets:i,referenceHidden:th(i)}}}case"escaped":{const a=await Eo(t,{...o,altBoundary:!0}),i=eh(a,n.floating);return{data:{escapedOffsets:i,escaped:th(i)}}}default:return{}}}}};async function i$(e,t){const{placement:n,platform:r,elements:o}=e,a=await(r.isRTL==null?void 0:r.isRTL(o.floating)),i=un(n),s=Dr(n),l=_r(n)==="y",c=["left","top"].includes(i)?-1:1,f=a&&l?-1:1,d=cn(t,e);let{mainAxis:p,crossAxis:v,alignmentAxis:h}=typeof d=="number"?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...d};return s&&typeof h=="number"&&(v=s==="end"?h*-1:h),l?{x:v*f,y:p*c}:{x:p*c,y:v*f}}const s$=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){const{x:n,y:r}=t,o=await i$(t,e);return{x:n+o.x,y:r+o.y,data:o}}}},l$=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:a=!0,crossAxis:i=!1,limiter:s={fn:w=>{let{x,y}=w;return{x,y}}},...l}=cn(e,t),c={x:n,y:r},f=await Eo(t,l),d=_r(un(o)),p=ml(d);let v=c[p],h=c[d];if(a){const w=p==="y"?"top":"left",x=p==="y"?"bottom":"right",y=v+f[w],b=v-f[x];v=hl(y,v,b)}if(i){const w=d==="y"?"top":"left",x=d==="y"?"bottom":"right",y=h+f[w],b=h-f[x];h=hl(y,h,b)}const g=s.fn({...t,[p]:v,[d]:h});return{...g,data:{x:g.x-n,y:g.y-r}}}}},c$=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:a,middlewareData:i}=t,{offset:s=0,mainAxis:l=!0,crossAxis:c=!0}=cn(e,t),f={x:n,y:r},d=_r(o),p=ml(d);let v=f[p],h=f[d];const g=cn(s,t),w=typeof g=="number"?{mainAxis:g,crossAxis:0}:{mainAxis:0,crossAxis:0,...g};if(l){const b=p==="y"?"height":"width",S=a.reference[p]-a.floating[b]+w.mainAxis,$=a.reference[p]+a.reference[b]-w.mainAxis;v<S?v=S:v>$&&(v=$)}if(c){var x,y;const b=p==="y"?"width":"height",S=["top","left"].includes(un(o)),$=a.reference[d]-a.floating[b]+(S&&((x=i.offset)==null?void 0:x[d])||0)+(S?0:w.crossAxis),M=a.reference[d]+a.reference[b]+(S?0:((y=i.offset)==null?void 0:y[d])||0)-(S?w.crossAxis:0);h<$?h=$:h>M&&(h=M)}return{[p]:v,[d]:h}}}},u$=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){const{placement:n,rects:r,platform:o,elements:a}=t,{apply:i=()=>{},...s}=cn(e,t),l=await Eo(t,s),c=un(n),f=Dr(n),d=_r(n)==="y",{width:p,height:v}=r.floating;let h,g;c==="top"||c==="bottom"?(h=c,g=f===(await(o.isRTL==null?void 0:o.isRTL(a.floating))?"start":"end")?"left":"right"):(g=c,h=f==="end"?"top":"bottom");const w=v-l[h],x=p-l[g],y=!t.middlewareData.shift;let b=w,S=x;if(d){const M=p-l.left-l.right;S=f||y?In(x,M):M}else{const M=v-l.top-l.bottom;b=f||y?In(w,M):M}if(y&&!f){const M=Pt(l.left,0),k=Pt(l.right,0),P=Pt(l.top,0),T=Pt(l.bottom,0);d?S=p-2*(M!==0||k!==0?M+k:Pt(l.left,l.right)):b=v-2*(P!==0||T!==0?P+T:Pt(l.top,l.bottom))}await i({...t,availableWidth:S,availableHeight:b});const $=await o.getDimensions(a.floating);return p!==$.width||v!==$.height?{reset:{rects:!0}}:{}}}};function Fn(e){return nh(e)?(e.nodeName||"").toLowerCase():"#document"}function kt(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function dn(e){var t;return(t=(nh(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function nh(e){return e instanceof Node||e instanceof kt(e).Node}function fn(e){return e instanceof Element||e instanceof kt(e).Element}function Jt(e){return e instanceof HTMLElement||e instanceof kt(e).HTMLElement}function rh(e){return typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof kt(e).ShadowRoot}function Mo(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=At(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(o)}function d$(e){return["table","td","th"].includes(Fn(e))}function yl(e){const t=xl(),n=At(e);return n.transform!=="none"||n.perspective!=="none"||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||["transform","perspective","filter"].some(r=>(n.willChange||"").includes(r))||["paint","layout","strict","content"].some(r=>(n.contain||"").includes(r))}function f$(e){let t=Ir(e);for(;Jt(t)&&!Xa(t);){if(yl(t))return t;t=Ir(t)}return null}function xl(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function Xa(e){return["html","body","#document"].includes(Fn(e))}function At(e){return kt(e).getComputedStyle(e)}function Qa(e){return fn(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function Ir(e){if(Fn(e)==="html")return e;const t=e.assignedSlot||e.parentNode||rh(e)&&e.host||dn(e);return rh(t)?t.host:t}function oh(e){const t=Ir(e);return Xa(t)?e.ownerDocument?e.ownerDocument.body:e.body:Jt(t)&&Mo(t)?t:oh(t)}function To(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=oh(e),a=o===((r=e.ownerDocument)==null?void 0:r.body),i=kt(o);return a?t.concat(i,i.visualViewport||[],Mo(o)?o:[],i.frameElement&&n?To(i.frameElement):[]):t.concat(o,To(o,[],n))}function ah(e){const t=At(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=Jt(e),a=o?e.offsetWidth:n,i=o?e.offsetHeight:r,s=Ua(n)!==a||Ua(r)!==i;return s&&(n=a,r=i),{width:n,height:r,$:s}}function wl(e){return fn(e)?e:e.contextElement}function Lr(e){const t=wl(e);if(!Jt(t))return Ln(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:a}=ah(t);let i=(a?Ua(n.width):n.width)/r,s=(a?Ua(n.height):n.height)/o;return(!i||!Number.isFinite(i))&&(i=1),(!s||!Number.isFinite(s))&&(s=1),{x:i,y:s}}const p$=Ln(0);function ih(e){const t=kt(e);return!xl()||!t.visualViewport?p$:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function h$(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==kt(e)?!1:t}function sr(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),a=wl(e);let i=Ln(1);t&&(r?fn(r)&&(i=Lr(r)):i=Lr(e));const s=h$(a,n,r)?ih(a):Ln(0);let l=(o.left+s.x)/i.x,c=(o.top+s.y)/i.y,f=o.width/i.x,d=o.height/i.y;if(a){const p=kt(a),v=r&&fn(r)?kt(r):r;let h=p.frameElement;for(;h&&r&&v!==p;){const g=Lr(h),w=h.getBoundingClientRect(),x=At(h),y=w.left+(h.clientLeft+parseFloat(x.paddingLeft))*g.x,b=w.top+(h.clientTop+parseFloat(x.paddingTop))*g.y;l*=g.x,c*=g.y,f*=g.x,d*=g.y,l+=y,c+=b,h=kt(h).frameElement}}return Ka({width:f,height:d,x:l,y:c})}function m$(e){let{rect:t,offsetParent:n,strategy:r}=e;const o=Jt(n),a=dn(n);if(n===a)return t;let i={scrollLeft:0,scrollTop:0},s=Ln(1);const l=Ln(0);if((o||!o&&r!=="fixed")&&((Fn(n)!=="body"||Mo(a))&&(i=Qa(n)),Jt(n))){const c=sr(n);s=Lr(n),l.x=c.x+n.clientLeft,l.y=c.y+n.clientTop}return{width:t.width*s.x,height:t.height*s.y,x:t.x*s.x-i.scrollLeft*s.x+l.x,y:t.y*s.y-i.scrollTop*s.y+l.y}}function g$(e){return Array.from(e.getClientRects())}function sh(e){return sr(dn(e)).left+Qa(e).scrollLeft}function v$(e){const t=dn(e),n=Qa(e),r=e.ownerDocument.body,o=Pt(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=Pt(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let i=-n.scrollLeft+sh(e);const s=-n.scrollTop;return At(r).direction==="rtl"&&(i+=Pt(t.clientWidth,r.clientWidth)-o),{width:o,height:a,x:i,y:s}}function b$(e,t){const n=kt(e),r=dn(e),o=n.visualViewport;let a=r.clientWidth,i=r.clientHeight,s=0,l=0;if(o){a=o.width,i=o.height;const c=xl();(!c||c&&t==="fixed")&&(s=o.offsetLeft,l=o.offsetTop)}return{width:a,height:i,x:s,y:l}}function y$(e,t){const n=sr(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,a=Jt(e)?Lr(e):Ln(1),i=e.clientWidth*a.x,s=e.clientHeight*a.y,l=o*a.x,c=r*a.y;return{width:i,height:s,x:l,y:c}}function lh(e,t,n){let r;if(t==="viewport")r=b$(e,n);else if(t==="document")r=v$(dn(e));else if(fn(t))r=y$(t,n);else{const o=ih(e);r={...t,x:t.x-o.x,y:t.y-o.y}}return Ka(r)}function ch(e,t){const n=Ir(e);return n===t||!fn(n)||Xa(n)?!1:At(n).position==="fixed"||ch(n,t)}function x$(e,t){const n=t.get(e);if(n)return n;let r=To(e,[],!1).filter(s=>fn(s)&&Fn(s)!=="body"),o=null;const a=At(e).position==="fixed";let i=a?Ir(e):e;for(;fn(i)&&!Xa(i);){const s=At(i),l=yl(i);!l&&s.position==="fixed"&&(o=null),(a?!l&&!o:!l&&s.position==="static"&&!!o&&["absolute","fixed"].includes(o.position)||Mo(i)&&!l&&ch(e,i))?r=r.filter(f=>f!==i):o=s,i=Ir(i)}return t.set(e,r),r}function w$(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const i=[...n==="clippingAncestors"?x$(t,this._c):[].concat(n),r],s=i[0],l=i.reduce((c,f)=>{const d=lh(t,f,o);return c.top=Pt(d.top,c.top),c.right=In(d.right,c.right),c.bottom=In(d.bottom,c.bottom),c.left=Pt(d.left,c.left),c},lh(t,s,o));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function $$(e){return ah(e)}function C$(e,t,n){const r=Jt(t),o=dn(t),a=n==="fixed",i=sr(e,!0,a,t);let s={scrollLeft:0,scrollTop:0};const l=Ln(0);if(r||!r&&!a)if((Fn(t)!=="body"||Mo(o))&&(s=Qa(t)),r){const c=sr(t,!0,a,t);l.x=c.x+t.clientLeft,l.y=c.y+t.clientTop}else o&&(l.x=sh(o));return{x:i.left+s.scrollLeft-l.x,y:i.top+s.scrollTop-l.y,width:i.width,height:i.height}}function uh(e,t){return!Jt(e)||At(e).position==="fixed"?null:t?t(e):e.offsetParent}function dh(e,t){const n=kt(e);if(!Jt(e))return n;let r=uh(e,t);for(;r&&d$(r)&&At(r).position==="static";)r=uh(r,t);return r&&(Fn(r)==="html"||Fn(r)==="body"&&At(r).position==="static"&&!yl(r))?n:r||f$(e)||n}const S$=async function(e){let{reference:t,floating:n,strategy:r}=e;const o=this.getOffsetParent||dh,a=this.getDimensions;return{reference:C$(t,await o(n),r),floating:{x:0,y:0,...await a(n)}}};function E$(e){return At(e).direction==="rtl"}const M$={convertOffsetParentRelativeRectToViewportRelativeRect:m$,getDocumentElement:dn,getClippingRect:w$,getOffsetParent:dh,getElementRects:S$,getClientRects:g$,getDimensions:$$,getScale:Lr,isElement:fn,isRTL:E$};function T$(e,t){let n=null,r;const o=dn(e);function a(){clearTimeout(r),n&&n.disconnect(),n=null}function i(s,l){s===void 0&&(s=!1),l===void 0&&(l=1),a();const{left:c,top:f,width:d,height:p}=e.getBoundingClientRect();if(s||t(),!d||!p)return;const v=Ya(f),h=Ya(o.clientWidth-(c+d)),g=Ya(o.clientHeight-(f+p)),w=Ya(c),y={rootMargin:-v+"px "+-h+"px "+-g+"px "+-w+"px",threshold:Pt(0,In(1,l))||1};let b=!0;function S($){const M=$[0].intersectionRatio;if(M!==l){if(!b)return i();M?i(!1,M):r=setTimeout(()=>{i(!1,1e-7)},100)}b=!1}try{n=new IntersectionObserver(S,{...y,root:o.ownerDocument})}catch{n=new IntersectionObserver(S,y)}n.observe(e)}return i(!0),a}function P$(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:a=!0,elementResize:i=typeof ResizeObserver=="function",layoutShift:s=typeof IntersectionObserver=="function",animationFrame:l=!1}=r,c=wl(e),f=o||a?[...c?To(c):[],...To(t)]:[];f.forEach(x=>{o&&x.addEventListener("scroll",n,{passive:!0}),a&&x.addEventListener("resize",n)});const d=c&&s?T$(c,n):null;let p=-1,v=null;i&&(v=new ResizeObserver(x=>{let[y]=x;y&&y.target===c&&v&&(v.unobserve(t),cancelAnimationFrame(p),p=requestAnimationFrame(()=>{v&&v.observe(t)})),n()}),c&&!l&&v.observe(c),v.observe(t));let h,g=l?sr(e):null;l&&w();function w(){const x=sr(e);g&&(x.x!==g.x||x.y!==g.y||x.width!==g.width||x.height!==g.height)&&n(),g=x,h=requestAnimationFrame(w)}return n(),()=>{f.forEach(x=>{o&&x.removeEventListener("scroll",n),a&&x.removeEventListener("resize",n)}),d&&d(),v&&v.disconnect(),v=null,l&&cancelAnimationFrame(h)}}const k$=(e,t,n)=>{const r=new Map,o={platform:M$,...n},a={...o.platform,_c:r};return r$(e,t,{...o,platform:a})},O$=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:o}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?Rp({element:r.current,padding:o}).fn(n):{}:r?Rp({element:r,padding:o}).fn(n):{}}}};var Za=typeof document<"u"?u.useLayoutEffect:u.useEffect;function Ja(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(r=n;r--!==0;)if(!Ja(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,o[r]))return!1;for(r=n;r--!==0;){const a=o[r];if(!(a==="_owner"&&e.$$typeof)&&!Ja(e[a],t[a]))return!1}return!0}return e!==e&&t!==t}function fh(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function ph(e,t){const n=fh(e);return Math.round(t*n)/n}function hh(e){const t=be.useRef(e);return Za(()=>{t.current=e}),t}function N$(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:a,floating:i}={},transform:s=!0,whileElementsMounted:l,open:c}=e,[f,d]=be.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[p,v]=be.useState(r);Ja(p,r)||v(r);const[h,g]=be.useState(null),[w,x]=be.useState(null),y=be.useCallback(A=>{A!=M.current&&(M.current=A,g(A))},[g]),b=be.useCallback(A=>{A!==k.current&&(k.current=A,x(A))},[x]),S=a||h,$=i||w,M=be.useRef(null),k=be.useRef(null),P=be.useRef(f),T=hh(l),I=hh(o),j=be.useCallback(()=>{if(!M.current||!k.current)return;const A={placement:t,strategy:n,middleware:p};I.current&&(A.platform=I.current),k$(M.current,k.current,A).then(W=>{const G={...W,isPositioned:!0};z.current&&!Ja(P.current,G)&&(P.current=G,Ky.flushSync(()=>{d(G)}))})},[p,t,n,I]);Za(()=>{c===!1&&P.current.isPositioned&&(P.current.isPositioned=!1,d(A=>({...A,isPositioned:!1})))},[c]);const z=be.useRef(!1);Za(()=>(z.current=!0,()=>{z.current=!1}),[]),Za(()=>{if(S&&(M.current=S),$&&(k.current=$),S&&$){if(T.current)return T.current(S,$,j);j()}},[S,$,j,T]);const B=be.useMemo(()=>({reference:M,floating:k,setReference:y,setFloating:b}),[y,b]),F=be.useMemo(()=>({reference:S,floating:$}),[S,$]),E=be.useMemo(()=>{const A={position:n,left:0,top:0};if(!F.floating)return A;const W=ph(F.floating,f.x),G=ph(F.floating,f.y);return s?{...A,transform:"translate("+W+"px, "+G+"px)",...fh(F.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:W,top:G}},[n,s,F.floating,f.x,f.y]);return be.useMemo(()=>({...f,update:j,refs:B,elements:F,floatingStyles:E}),[f,j,B,F,E])}const mh="Popper",[gh,Fr]=it(mh),[A$,vh]=gh(mh),D$=e=>{const{__scopePopper:t,children:n}=e,[r,o]=u.useState(null);return u.createElement(A$,{scope:t,anchor:r,onAnchorChange:o},n)},_$="PopperAnchor",I$=u.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...o}=e,a=vh(_$,n),i=u.useRef(null),s=Ee(t,i);return u.useEffect(()=>{a.onAnchorChange((r==null?void 0:r.current)||i.current)}),r?null:u.createElement(ve.div,K({},o,{ref:s}))}),bh="PopperContent",[L$,LI]=gh(bh),F$=u.forwardRef((e,t)=>{var n,r,o,a,i,s,l,c;const{__scopePopper:f,side:d="bottom",sideOffset:p=0,align:v="center",alignOffset:h=0,arrowPadding:g=0,avoidCollisions:w=!0,collisionBoundary:x=[],collisionPadding:y=0,sticky:b="partial",hideWhenDetached:S=!1,updatePositionStrategy:$="optimized",onPlaced:M,...k}=e,P=vh(bh,f),[T,I]=u.useState(null),j=Ee(t,ge=>I(ge)),[z,B]=u.useState(null),F=Vs(z),E=(n=F==null?void 0:F.width)!==null&&n!==void 0?n:0,A=(r=F==null?void 0:F.height)!==null&&r!==void 0?r:0,W=d+(v!=="center"?"-"+v:""),G=typeof y=="number"?y:{top:0,right:0,bottom:0,left:0,...y},D=Array.isArray(x)?x:[x],_=D.length>0,V={padding:G,boundary:D.filter(z$),altBoundary:_},{refs:te,floatingStyles:R,placement:ne,isPositioned:ae,middlewareData:le}=N$({strategy:"fixed",placement:W,whileElementsMounted:(...ge)=>P$(...ge,{animationFrame:$==="always"}),elements:{reference:P.anchor},middleware:[s$({mainAxis:p+A,alignmentAxis:h}),w&&l$({mainAxis:!0,crossAxis:!1,limiter:b==="partial"?c$():void 0,...V}),w&&o$({...V}),u$({...V,apply:({elements:ge,rects:xe,availableWidth:Se,availableHeight:He})=>{const{width:Ge,height:ot}=xe.reference,bt=ge.floating.style;bt.setProperty("--radix-popper-available-width",`${Se}px`),bt.setProperty("--radix-popper-available-height",`${He}px`),bt.setProperty("--radix-popper-anchor-width",`${Ge}px`),bt.setProperty("--radix-popper-anchor-height",`${ot}px`)}}),z&&O$({element:z,padding:g}),j$({arrowWidth:E,arrowHeight:A}),S&&a$({strategy:"referenceHidden",...V})]}),[Q,ie]=yh(ne),U=qe(M);lt(()=>{ae&&(U==null||U())},[ae,U]);const Z=(o=le.arrow)===null||o===void 0?void 0:o.x,ce=(a=le.arrow)===null||a===void 0?void 0:a.y,N=((i=le.arrow)===null||i===void 0?void 0:i.centerOffset)!==0,[oe,se]=u.useState();return lt(()=>{T&&se(window.getComputedStyle(T).zIndex)},[T]),u.createElement("div",{ref:te.setFloating,"data-radix-popper-content-wrapper":"",style:{...R,transform:ae?R.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:oe,"--radix-popper-transform-origin":[(s=le.transformOrigin)===null||s===void 0?void 0:s.x,(l=le.transformOrigin)===null||l===void 0?void 0:l.y].join(" ")},dir:e.dir},u.createElement(L$,{scope:f,placedSide:Q,onArrowChange:B,arrowX:Z,arrowY:ce,shouldHideArrow:N},u.createElement(ve.div,K({"data-side":Q,"data-align":ie},k,{ref:j,style:{...k.style,animation:ae?void 0:"none",opacity:(c=le.hide)!==null&&c!==void 0&&c.referenceHidden?0:void 0}}))))});function z$(e){return e!==null}const j$=e=>({name:"transformOrigin",options:e,fn(t){var n,r,o,a,i;const{placement:s,rects:l,middlewareData:c}=t,d=((n=c.arrow)===null||n===void 0?void 0:n.centerOffset)!==0,p=d?0:e.arrowWidth,v=d?0:e.arrowHeight,[h,g]=yh(s),w={start:"0%",center:"50%",end:"100%"}[g],x=((r=(o=c.arrow)===null||o===void 0?void 0:o.x)!==null&&r!==void 0?r:0)+p/2,y=((a=(i=c.arrow)===null||i===void 0?void 0:i.y)!==null&&a!==void 0?a:0)+v/2;let b="",S="";return h==="bottom"?(b=d?w:`${x}px`,S=`${-v}px`):h==="top"?(b=d?w:`${x}px`,S=`${l.floating.height+v}px`):h==="right"?(b=`${-v}px`,S=d?w:`${y}px`):h==="left"&&(b=`${l.floating.width+v}px`,S=d?w:`${y}px`),{data:{x:b,y:S}}}});function yh(e){const[t,n="center"]=e.split("-");return[t,n]}const Ra=D$,$l=I$,Cl=F$,Sl=u.forwardRef((e,t)=>{var n;const{container:r=globalThis==null||(n=globalThis.document)===null||n===void 0?void 0:n.body,...o}=e;return r?En.createPortal(u.createElement(ve.div,K({},o,{ref:t})),r):null}),El="rovingFocusGroup.onEntryFocus",B$={bubbles:!1,cancelable:!0},Ml="RovingFocusGroup",[Tl,xh,W$]=ar(Ml),[V$,zr]=it(Ml,[W$]),[H$,G$]=V$(Ml),U$=u.forwardRef((e,t)=>u.createElement(Tl.Provider,{scope:e.__scopeRovingFocusGroup},u.createElement(Tl.Slot,{scope:e.__scopeRovingFocusGroup},u.createElement(Y$,K({},e,{ref:t}))))),Y$=u.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:o=!1,dir:a,currentTabStopId:i,defaultCurrentTabStopId:s,onCurrentTabStopIdChange:l,onEntryFocus:c,...f}=e,d=u.useRef(null),p=Ee(t,d),v=Pn(a),[h=null,g]=st({prop:i,defaultProp:s,onChange:l}),[w,x]=u.useState(!1),y=qe(c),b=xh(n),S=u.useRef(!1),[$,M]=u.useState(0);return u.useEffect(()=>{const k=d.current;if(k)return k.addEventListener(El,y),()=>k.removeEventListener(El,y)},[y]),u.createElement(H$,{scope:n,orientation:r,dir:v,loop:o,currentTabStopId:h,onItemFocus:u.useCallback(k=>g(k),[g]),onItemShiftTab:u.useCallback(()=>x(!0),[]),onFocusableItemAdd:u.useCallback(()=>M(k=>k+1),[]),onFocusableItemRemove:u.useCallback(()=>M(k=>k-1),[])},u.createElement(ve.div,K({tabIndex:w||$===0?-1:0,"data-orientation":r},f,{ref:p,style:{outline:"none",...e.style},onMouseDown:de(e.onMouseDown,()=>{S.current=!0}),onFocus:de(e.onFocus,k=>{const P=!S.current;if(k.target===k.currentTarget&&P&&!w){const T=new CustomEvent(El,B$);if(k.currentTarget.dispatchEvent(T),!T.defaultPrevented){const I=b().filter(E=>E.focusable),j=I.find(E=>E.active),z=I.find(E=>E.id===h),F=[j,z,...I].filter(Boolean).map(E=>E.ref.current);wh(F)}}S.current=!1}),onBlur:de(e.onBlur,()=>x(!1))})))}),q$="RovingFocusGroupItem",K$=u.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:o=!1,tabStopId:a,...i}=e,s=$t(),l=a||s,c=G$(q$,n),f=c.currentTabStopId===l,d=xh(n),{onFocusableItemAdd:p,onFocusableItemRemove:v}=c;return u.useEffect(()=>{if(r)return p(),()=>v()},[r,p,v]),u.createElement(Tl.ItemSlot,{scope:n,id:l,focusable:r,active:o},u.createElement(ve.span,K({tabIndex:f?0:-1,"data-orientation":c.orientation},i,{ref:t,onMouseDown:de(e.onMouseDown,h=>{r?c.onItemFocus(l):h.preventDefault()}),onFocus:de(e.onFocus,()=>c.onItemFocus(l)),onKeyDown:de(e.onKeyDown,h=>{if(h.key==="Tab"&&h.shiftKey){c.onItemShiftTab();return}if(h.target!==h.currentTarget)return;const g=Z$(h,c.orientation,c.dir);if(g!==void 0){h.preventDefault();let x=d().filter(y=>y.focusable).map(y=>y.ref.current);if(g==="last")x.reverse();else if(g==="prev"||g==="next"){g==="prev"&&x.reverse();const y=x.indexOf(h.currentTarget);x=c.loop?J$(x,y+1):x.slice(y+1)}setTimeout(()=>wh(x))}})})))}),X$={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function Q$(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function Z$(e,t,n){const r=Q$(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(r))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(r)))return X$[r]}function wh(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function J$(e,t){return e.map((n,r)=>e[(t+r)%e.length])}const Pl=U$,kl=K$;var R$=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},jr=new WeakMap,ei=new WeakMap,ti={},Ol=0,$h=function(e){return e&&(e.host||$h(e.parentNode))},e5=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=$h(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},t5=function(e,t,n,r){var o=e5(t,Array.isArray(e)?e:[e]);ti[n]||(ti[n]=new WeakMap);var a=ti[n],i=[],s=new Set,l=new Set(o),c=function(d){!d||s.has(d)||(s.add(d),c(d.parentNode))};o.forEach(c);var f=function(d){!d||l.has(d)||Array.prototype.forEach.call(d.children,function(p){if(s.has(p))f(p);else{var v=p.getAttribute(r),h=v!==null&&v!=="false",g=(jr.get(p)||0)+1,w=(a.get(p)||0)+1;jr.set(p,g),a.set(p,w),i.push(p),g===1&&h&&ei.set(p,!0),w===1&&p.setAttribute(n,"true"),h||p.setAttribute(r,"true")}})};return f(t),s.clear(),Ol++,function(){i.forEach(function(d){var p=jr.get(d)-1,v=a.get(d)-1;jr.set(d,p),a.set(d,v),p||(ei.has(d)||d.removeAttribute(r),ei.delete(d)),v||d.removeAttribute(n)}),Ol--,Ol||(jr=new WeakMap,jr=new WeakMap,ei=new WeakMap,ti={})}},Ch=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),o=t||R$(e);return o?(r.push.apply(r,Array.from(o.querySelectorAll("[aria-live]"))),t5(r,o,n,"aria-hidden")):function(){return null}},Rt=function(){return Rt=Object.assign||function(t){for(var n,r=1,o=arguments.length;r<o;r++){n=arguments[r];for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(t[a]=n[a])}return t},Rt.apply(this,arguments)};function Sh(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n}function n5(e,t,n){if(n||arguments.length===2)for(var r=0,o=t.length,a;r<o;r++)(a||!(r in t))&&(a||(a=Array.prototype.slice.call(t,0,r)),a[r]=t[r]);return e.concat(a||Array.prototype.slice.call(t))}typeof SuppressedError=="function"&&SuppressedError;var ni="right-scroll-bar-position",ri="width-before-scroll-bar",r5="with-scroll-bars-hidden",o5="--removed-body-scroll-bar-size";function a5(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function i5(e,t){var n=u.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var o=n.value;o!==r&&(n.value=r,n.callback(r,o))}}}})[0];return n.callback=t,n.facade}function s5(e,t){return i5(t||null,function(n){return e.forEach(function(r){return a5(r,n)})})}function l5(e){return e}function c5(e,t){t===void 0&&(t=l5);var n=[],r=!1,o={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(a){var i=t(a,r);return n.push(i),function(){n=n.filter(function(s){return s!==i})}},assignSyncMedium:function(a){for(r=!0;n.length;){var i=n;n=[],i.forEach(a)}n={push:function(s){return a(s)},filter:function(){return n}}},assignMedium:function(a){r=!0;var i=[];if(n.length){var s=n;n=[],s.forEach(a),i=n}var l=function(){var f=i;i=[],f.forEach(a)},c=function(){return Promise.resolve().then(l)};c(),n={push:function(f){i.push(f),c()},filter:function(f){return i=i.filter(f),n}}}};return o}function u5(e){e===void 0&&(e={});var t=c5(null);return t.options=Rt({async:!0,ssr:!1},e),t}var Eh=function(e){var t=e.sideCar,n=Sh(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return be.createElement(r,Rt({},n))};Eh.isSideCarExport=!0;function d5(e,t){return e.useMedium(t),Eh}var Mh=u5(),Nl=function(){},oi=be.forwardRef(function(e,t){var n=be.useRef(null),r=be.useState({onScrollCapture:Nl,onWheelCapture:Nl,onTouchMoveCapture:Nl}),o=r[0],a=r[1],i=e.forwardProps,s=e.children,l=e.className,c=e.removeScrollBar,f=e.enabled,d=e.shards,p=e.sideCar,v=e.noIsolation,h=e.inert,g=e.allowPinchZoom,w=e.as,x=w===void 0?"div":w,y=Sh(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as"]),b=p,S=s5([n,t]),$=Rt(Rt({},y),o);return be.createElement(be.Fragment,null,f&&be.createElement(b,{sideCar:Mh,removeScrollBar:c,shards:d,noIsolation:v,inert:h,setCallbacks:a,allowPinchZoom:!!g,lockRef:n}),i?be.cloneElement(be.Children.only(s),Rt(Rt({},$),{ref:S})):be.createElement(x,Rt({},$,{className:l,ref:S}),s))});oi.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},oi.classNames={fullWidth:ri,zeroRight:ni};var Th,f5=function(){if(Th)return Th;if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function p5(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=f5();return t&&e.setAttribute("nonce",t),e}function h5(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function m5(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var g5=function(){var e=0,t=null;return{add:function(n){e==0&&(t=p5())&&(h5(t,n),m5(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},v5=function(){var e=g5();return function(t,n){be.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},Ph=function(){var e=v5(),t=function(n){var r=n.styles,o=n.dynamic;return e(r,o),null};return t},b5={left:0,top:0,right:0,gap:0},Al=function(e){return parseInt(e||"",10)||0},y5=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],o=t[e==="padding"?"paddingRight":"marginRight"];return[Al(n),Al(r),Al(o)]},x5=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return b5;var t=y5(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},w5=Ph(),$5=function(e,t,n,r){var o=e.left,a=e.top,i=e.right,s=e.gap;return n===void 0&&(n="margin"),`
7
7
  .`.concat(r5,` {
8
8
  overflow: hidden `).concat(r,`;
9
9
  padding-right: `).concat(s,"px ").concat(r,`;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@mesh.ai/rabbit",
3
3
  "private": false,
4
- "version": "1.4.0",
4
+ "version": "1.4.1",
5
5
  "packageManager": "pnpm@8.6.0",
6
6
  "main": "./dist/@mesh.ai/rabbit.umd.js",
7
7
  "module": "./dist/@mesh.ai/rabbit.es.js ",