@prefecthq/prefect-design
Version:
A collection of low-level Vue components.
8 lines • 2.14 MB
JavaScript
(function(B,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue"),require("vue-router")):typeof define=="function"&&define.amd?define(["exports","vue","vue-router"],e):(B=typeof globalThis<"u"?globalThis:B||self,e(B.PrefectDesign={},B.Vue,B.vueRouter))})(this,function(B,e,Da){"use strict";var TK=Object.defineProperty;var kK=(B,e,Da)=>e in B?TK(B,e,{enumerable:!0,configurable:!0,writable:!0,value:Da}):B[e]=Da;var ge=(B,e,Da)=>kK(B,typeof e!="symbol"?e+"":e,Da);function K3(n){const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(n){for(const o in n)if(o!=="default"){const l=Object.getOwnPropertyDescriptor(n,o);Object.defineProperty(r,o,l.get?l:{enumerable:!0,get:()=>n[o]})}}return r.default=n,Object.freeze(r)}const vh=K3(e),Q3=["top","right","bottom","left"],Ea=Math.min,gr=Math.max,iu=Math.round,lu=Math.floor,Uo=n=>({x:n,y:n}),X3={left:"right",right:"left",bottom:"top",top:"bottom"},J3={start:"end",end:"start"};function p0(n,r,o){return gr(n,Ea(r,o))}function Ba(n,r){return typeof n=="function"?n(r):n}function Pa(n){return n.split("-")[0]}function Gl(n){return n.split("-")[1]}function m0(n){return n==="x"?"y":"x"}function _0(n){return n==="y"?"height":"width"}function $o(n){return["top","bottom"].includes(Pa(n))?"y":"x"}function g0(n){return m0($o(n))}function eb(n,r,o){o===void 0&&(o=!1);const l=Gl(n),s=g0(n),d=_0(s);let u=s==="x"?l===(o?"end":"start")?"right":"left":l==="start"?"bottom":"top";return r.reference[d]>r.floating[d]&&(u=su(u)),[u,su(u)]}function tb(n){const r=su(n);return[f0(n),r,f0(r)]}function f0(n){return n.replace(/start|end/g,r=>J3[r])}function nb(n,r,o){const l=["left","right"],s=["right","left"],d=["top","bottom"],u=["bottom","top"];switch(n){case"top":case"bottom":return o?r?s:l:r?l:s;case"left":case"right":return r?d:u;default:return[]}}function rb(n,r,o,l){const s=Gl(n);let d=nb(Pa(n),o==="start",l);return s&&(d=d.map(u=>u+"-"+s),r&&(d=d.concat(d.map(f0)))),d}function su(n){return n.replace(/left|right|bottom|top/g,r=>X3[r])}function ab(n){return{top:0,right:0,bottom:0,left:0,...n}}function Eh(n){return typeof n!="number"?ab(n):{top:n,right:n,bottom:n,left:n}}function cu(n){const{x:r,y:o,width:l,height:s}=n;return{width:l,height:s,top:o,left:r,right:r+l,bottom:o+s,x:r,y:o}}function bh(n,r,o){let{reference:l,floating:s}=n;const d=$o(r),u=g0(r),m=_0(u),f=Pa(r),g=d==="y",_=l.x+l.width/2-s.width/2,v=l.y+l.height/2-s.height/2,b=l[m]/2-s[m]/2;let C;switch(f){case"top":C={x:_,y:l.y-s.height};break;case"bottom":C={x:_,y:l.y+l.height};break;case"right":C={x:l.x+l.width,y:v};break;case"left":C={x:l.x-s.width,y:v};break;default:C={x:l.x,y:l.y}}switch(Gl(r)){case"start":C[u]-=b*(o&&g?-1:1);break;case"end":C[u]+=b*(o&&g?-1:1);break}return C}const ob=async(n,r,o)=>{const{placement:l="bottom",strategy:s="absolute",middleware:d=[],platform:u}=o,m=d.filter(Boolean),f=await(u.isRTL==null?void 0:u.isRTL(r));let g=await u.getElementRects({reference:n,floating:r,strategy:s}),{x:_,y:v}=bh(g,l,f),b=l,C={},y=0;for(let R=0;R<m.length;R++){const{name:M,fn:L}=m[R],{x:$,y:A,data:x,reset:D}=await L({x:_,y:v,initialPlacement:l,placement:b,strategy:s,middlewareData:C,rects:g,platform:u,elements:{reference:n,floating:r}});_=$??_,v=A??v,C={...C,[M]:{...C[M],...x}},D&&y<=50&&(y++,typeof D=="object"&&(D.placement&&(b=D.placement),D.rects&&(g=D.rects===!0?await u.getElementRects({reference:n,floating:r,strategy:s}):D.rects),{x:_,y:v}=bh(g,b,f)),R=-1)}return{x:_,y:v,placement:b,strategy:s,middlewareData:C}};async function Ss(n,r){var o;r===void 0&&(r={});const{x:l,y:s,platform:d,rects:u,elements:m,strategy:f}=n,{boundary:g="clippingAncestors",rootBoundary:_="viewport",elementContext:v="floating",altBoundary:b=!1,padding:C=0}=Ba(r,n),y=Eh(C),M=m[b?v==="floating"?"reference":"floating":v],L=cu(await d.getClippingRect({element:(o=await(d.isElement==null?void 0:d.isElement(M)))==null||o?M:M.contextElement||await(d.getDocumentElement==null?void 0:d.getDocumentElement(m.floating)),boundary:g,rootBoundary:_,strategy:f})),$=v==="floating"?{x:l,y:s,width:u.floating.width,height:u.floating.height}:u.reference,A=await(d.getOffsetParent==null?void 0:d.getOffsetParent(m.floating)),x=await(d.isElement==null?void 0:d.isElement(A))?await(d.getScale==null?void 0:d.getScale(A))||{x:1,y:1}:{x:1,y:1},D=cu(d.convertOffsetParentRelativeRectToViewportRelativeRect?await d.convertOffsetParentRelativeRectToViewportRelativeRect({elements:m,rect:$,offsetParent:A,strategy:f}):$);return{top:(L.top-D.top+y.top)/x.y,bottom:(D.bottom-L.bottom+y.bottom)/x.y,left:(L.left-D.left+y.left)/x.x,right:(D.right-L.right+y.right)/x.x}}const ib=n=>({name:"arrow",options:n,async fn(r){const{x:o,y:l,placement:s,rects:d,platform:u,elements:m,middlewareData:f}=r,{element:g,padding:_=0}=Ba(n,r)||{};if(g==null)return{};const v=Eh(_),b={x:o,y:l},C=g0(s),y=_0(C),R=await u.getDimensions(g),M=C==="y",L=M?"top":"left",$=M?"bottom":"right",A=M?"clientHeight":"clientWidth",x=d.reference[y]+d.reference[C]-b[C]-d.floating[y],D=b[C]-d.reference[C],N=await(u.getOffsetParent==null?void 0:u.getOffsetParent(g));let Z=N?N[A]:0;(!Z||!await(u.isElement==null?void 0:u.isElement(N)))&&(Z=m.floating[A]||d.floating[y]);const H=x/2-D/2,W=Z/2-R[y]/2-1,z=Ea(v[L],W),te=Ea(v[$],W),ie=z,ce=Z-R[y]-te,he=Z/2-R[y]/2+H,De=p0(ie,he,ce),mt=!f.arrow&&Gl(s)!=null&&he!==De&&d.reference[y]/2-(he<ie?z:te)-R[y]/2<0,_t=mt?he<ie?he-ie:he-ce:0;return{[C]:b[C]+_t,data:{[C]:De,centerOffset:he-De-_t,...mt&&{alignmentOffset:_t}},reset:mt}}}),lb=function(n){return n===void 0&&(n={}),{name:"flip",options:n,async fn(r){var o,l;const{placement:s,middlewareData:d,rects:u,initialPlacement:m,platform:f,elements:g}=r,{mainAxis:_=!0,crossAxis:v=!0,fallbackPlacements:b,fallbackStrategy:C="bestFit",fallbackAxisSideDirection:y="none",flipAlignment:R=!0,...M}=Ba(n,r);if((o=d.arrow)!=null&&o.alignmentOffset)return{};const L=Pa(s),$=$o(m),A=Pa(m)===m,x=await(f.isRTL==null?void 0:f.isRTL(g.floating)),D=b||(A||!R?[su(m)]:tb(m)),N=y!=="none";!b&&N&&D.push(...rb(m,R,y,x));const Z=[m,...D],H=await Ss(r,M),W=[];let z=((l=d.flip)==null?void 0:l.overflows)||[];if(_&&W.push(H[L]),v){const he=eb(s,u,x);W.push(H[he[0]],H[he[1]])}if(z=[...z,{placement:s,overflows:W}],!W.every(he=>he<=0)){var te,ie;const he=(((te=d.flip)==null?void 0:te.index)||0)+1,De=Z[he];if(De)return{data:{index:he,overflows:z},reset:{placement:De}};let mt=(ie=z.filter(_t=>_t.overflows[0]<=0).sort((_t,it)=>_t.overflows[1]-it.overflows[1])[0])==null?void 0:ie.placement;if(!mt)switch(C){case"bestFit":{var ce;const _t=(ce=z.filter(it=>{if(N){const Ee=$o(it.placement);return Ee===$||Ee==="y"}return!0}).map(it=>[it.placement,it.overflows.filter(Ee=>Ee>0).reduce((Ee,Pe)=>Ee+Pe,0)]).sort((it,Ee)=>it[1]-Ee[1])[0])==null?void 0:ce[0];_t&&(mt=_t);break}case"initialPlacement":mt=m;break}if(s!==mt)return{reset:{placement:mt}}}return{}}}};function Sh(n,r){return{top:n.top-r.height,right:n.right-r.width,bottom:n.bottom-r.height,left:n.left-r.width}}function wh(n){return Q3.some(r=>n[r]>=0)}const sb=function(n){return n===void 0&&(n={}),{name:"hide",options:n,async fn(r){const{rects:o}=r,{strategy:l="referenceHidden",...s}=Ba(n,r);switch(l){case"referenceHidden":{const d=await Ss(r,{...s,elementContext:"reference"}),u=Sh(d,o.reference);return{data:{referenceHiddenOffsets:u,referenceHidden:wh(u)}}}case"escaped":{const d=await Ss(r,{...s,altBoundary:!0}),u=Sh(d,o.floating);return{data:{escapedOffsets:u,escaped:wh(u)}}}default:return{}}}}};async function cb(n,r){const{placement:o,platform:l,elements:s}=n,d=await(l.isRTL==null?void 0:l.isRTL(s.floating)),u=Pa(o),m=Gl(o),f=$o(o)==="y",g=["left","top"].includes(u)?-1:1,_=d&&f?-1:1,v=Ba(r,n);let{mainAxis:b,crossAxis:C,alignmentAxis:y}=typeof v=="number"?{mainAxis:v,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...v};return m&&typeof y=="number"&&(C=m==="end"?y*-1:y),f?{x:C*_,y:b*g}:{x:b*g,y:C*_}}const db=function(n){return n===void 0&&(n=0),{name:"offset",options:n,async fn(r){var o,l;const{x:s,y:d,placement:u,middlewareData:m}=r,f=await cb(r,n);return u===((o=m.offset)==null?void 0:o.placement)&&(l=m.arrow)!=null&&l.alignmentOffset?{}:{x:s+f.x,y:d+f.y,data:{...f,placement:u}}}}},ub=function(n){return n===void 0&&(n={}),{name:"shift",options:n,async fn(r){const{x:o,y:l,placement:s}=r,{mainAxis:d=!0,crossAxis:u=!1,limiter:m={fn:M=>{let{x:L,y:$}=M;return{x:L,y:$}}},...f}=Ba(n,r),g={x:o,y:l},_=await Ss(r,f),v=$o(Pa(s)),b=m0(v);let C=g[b],y=g[v];if(d){const M=b==="y"?"top":"left",L=b==="y"?"bottom":"right",$=C+_[M],A=C-_[L];C=p0($,C,A)}if(u){const M=v==="y"?"top":"left",L=v==="y"?"bottom":"right",$=y+_[M],A=y-_[L];y=p0($,y,A)}const R=m.fn({...r,[b]:C,[v]:y});return{...R,data:{x:R.x-o,y:R.y-l}}}}},pb=function(n){return n===void 0&&(n={}),{options:n,fn(r){const{x:o,y:l,placement:s,rects:d,middlewareData:u}=r,{offset:m=0,mainAxis:f=!0,crossAxis:g=!0}=Ba(n,r),_={x:o,y:l},v=$o(s),b=m0(v);let C=_[b],y=_[v];const R=Ba(m,r),M=typeof R=="number"?{mainAxis:R,crossAxis:0}:{mainAxis:0,crossAxis:0,...R};if(f){const A=b==="y"?"height":"width",x=d.reference[b]-d.floating[A]+M.mainAxis,D=d.reference[b]+d.reference[A]-M.mainAxis;C<x?C=x:C>D&&(C=D)}if(g){var L,$;const A=b==="y"?"width":"height",x=["top","left"].includes(Pa(s)),D=d.reference[v]-d.floating[A]+(x&&((L=u.offset)==null?void 0:L[v])||0)+(x?0:M.crossAxis),N=d.reference[v]+d.reference[A]+(x?0:(($=u.offset)==null?void 0:$[v])||0)-(x?M.crossAxis:0);y<D?y=D:y>N&&(y=N)}return{[b]:C,[v]:y}}}},mb=function(n){return n===void 0&&(n={}),{name:"size",options:n,async fn(r){const{placement:o,rects:l,platform:s,elements:d}=r,{apply:u=()=>{},...m}=Ba(n,r),f=await Ss(r,m),g=Pa(o),_=Gl(o),v=$o(o)==="y",{width:b,height:C}=l.floating;let y,R;g==="top"||g==="bottom"?(y=g,R=_===(await(s.isRTL==null?void 0:s.isRTL(d.floating))?"start":"end")?"left":"right"):(R=g,y=_==="end"?"top":"bottom");const M=C-f.top-f.bottom,L=b-f.left-f.right,$=Ea(C-f[y],M),A=Ea(b-f[R],L),x=!r.middlewareData.shift;let D=$,N=A;if(v?N=_||x?Ea(A,L):L:D=_||x?Ea($,M):M,x&&!_){const H=gr(f.left,0),W=gr(f.right,0),z=gr(f.top,0),te=gr(f.bottom,0);v?N=b-2*(H!==0||W!==0?H+W:gr(f.left,f.right)):D=C-2*(z!==0||te!==0?z+te:gr(f.top,f.bottom))}await u({...r,availableWidth:N,availableHeight:D});const Z=await s.getDimensions(d.floating);return b!==Z.width||C!==Z.height?{reset:{rects:!0}}:{}}}};function si(n){return h0(n)?(n.nodeName||"").toLowerCase():"#document"}function fr(n){var r;return(n==null||(r=n.ownerDocument)==null?void 0:r.defaultView)||window}function La(n){var r;return(r=(h0(n)?n.ownerDocument:n.document)||window.document)==null?void 0:r.documentElement}function h0(n){return n instanceof Node||n instanceof fr(n).Node}function ba(n){return n instanceof Element||n instanceof fr(n).Element}function Sa(n){return n instanceof HTMLElement||n instanceof fr(n).HTMLElement}function Ch(n){return typeof ShadowRoot>"u"?!1:n instanceof ShadowRoot||n instanceof fr(n).ShadowRoot}function ws(n){const{overflow:r,overflowX:o,overflowY:l,display:s}=Wr(n);return/auto|scroll|overlay|hidden|clip/.test(r+l+o)&&!["inline","contents"].includes(s)}function _b(n){return["table","td","th"].includes(si(n))}function du(n){return[":popover-open",":modal"].some(r=>{try{return n.matches(r)}catch{return!1}})}function v0(n){const r=E0(),o=Wr(n);return o.transform!=="none"||o.perspective!=="none"||(o.containerType?o.containerType!=="normal":!1)||!r&&(o.backdropFilter?o.backdropFilter!=="none":!1)||!r&&(o.filter?o.filter!=="none":!1)||["transform","perspective","filter"].some(l=>(o.willChange||"").includes(l))||["paint","layout","strict","content"].some(l=>(o.contain||"").includes(l))}function gb(n){let r=Go(n);for(;Sa(r)&&!Hl(r);){if(du(r))return null;if(v0(r))return r;r=Go(r)}return null}function E0(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function Hl(n){return["html","body","#document"].includes(si(n))}function Wr(n){return fr(n).getComputedStyle(n)}function uu(n){return ba(n)?{scrollLeft:n.scrollLeft,scrollTop:n.scrollTop}:{scrollLeft:n.scrollX,scrollTop:n.scrollY}}function Go(n){if(si(n)==="html")return n;const r=n.assignedSlot||n.parentNode||Ch(n)&&n.host||La(n);return Ch(r)?r.host:r}function yh(n){const r=Go(n);return Hl(r)?n.ownerDocument?n.ownerDocument.body:n.body:Sa(r)&&ws(r)?r:yh(r)}function Cs(n,r,o){var l;r===void 0&&(r=[]),o===void 0&&(o=!0);const s=yh(n),d=s===((l=n.ownerDocument)==null?void 0:l.body),u=fr(s);return d?r.concat(u,u.visualViewport||[],ws(s)?s:[],u.frameElement&&o?Cs(u.frameElement):[]):r.concat(s,Cs(s,[],o))}function Th(n){const r=Wr(n);let o=parseFloat(r.width)||0,l=parseFloat(r.height)||0;const s=Sa(n),d=s?n.offsetWidth:o,u=s?n.offsetHeight:l,m=iu(o)!==d||iu(l)!==u;return m&&(o=d,l=u),{width:o,height:l,$:m}}function b0(n){return ba(n)?n:n.contextElement}function zl(n){const r=b0(n);if(!Sa(r))return Uo(1);const o=r.getBoundingClientRect(),{width:l,height:s,$:d}=Th(r);let u=(d?iu(o.width):o.width)/l,m=(d?iu(o.height):o.height)/s;return(!u||!Number.isFinite(u))&&(u=1),(!m||!Number.isFinite(m))&&(m=1),{x:u,y:m}}const fb=Uo(0);function kh(n){const r=fr(n);return!E0()||!r.visualViewport?fb:{x:r.visualViewport.offsetLeft,y:r.visualViewport.offsetTop}}function hb(n,r,o){return r===void 0&&(r=!1),!o||r&&o!==fr(n)?!1:r}function ci(n,r,o,l){r===void 0&&(r=!1),o===void 0&&(o=!1);const s=n.getBoundingClientRect(),d=b0(n);let u=Uo(1);r&&(l?ba(l)&&(u=zl(l)):u=zl(n));const m=hb(d,o,l)?kh(d):Uo(0);let f=(s.left+m.x)/u.x,g=(s.top+m.y)/u.y,_=s.width/u.x,v=s.height/u.y;if(d){const b=fr(d),C=l&&ba(l)?fr(l):l;let y=b,R=y.frameElement;for(;R&&l&&C!==y;){const M=zl(R),L=R.getBoundingClientRect(),$=Wr(R),A=L.left+(R.clientLeft+parseFloat($.paddingLeft))*M.x,x=L.top+(R.clientTop+parseFloat($.paddingTop))*M.y;f*=M.x,g*=M.y,_*=M.x,v*=M.y,f+=A,g+=x,y=fr(R),R=y.frameElement}}return cu({width:_,height:v,x:f,y:g})}function vb(n){let{elements:r,rect:o,offsetParent:l,strategy:s}=n;const d=s==="fixed",u=La(l),m=r?du(r.floating):!1;if(l===u||m&&d)return o;let f={scrollLeft:0,scrollTop:0},g=Uo(1);const _=Uo(0),v=Sa(l);if((v||!v&&!d)&&((si(l)!=="body"||ws(u))&&(f=uu(l)),Sa(l))){const b=ci(l);g=zl(l),_.x=b.x+l.clientLeft,_.y=b.y+l.clientTop}return{width:o.width*g.x,height:o.height*g.y,x:o.x*g.x-f.scrollLeft*g.x+_.x,y:o.y*g.y-f.scrollTop*g.y+_.y}}function Eb(n){return Array.from(n.getClientRects())}function xh(n){return ci(La(n)).left+uu(n).scrollLeft}function bb(n){const r=La(n),o=uu(n),l=n.ownerDocument.body,s=gr(r.scrollWidth,r.clientWidth,l.scrollWidth,l.clientWidth),d=gr(r.scrollHeight,r.clientHeight,l.scrollHeight,l.clientHeight);let u=-o.scrollLeft+xh(n);const m=-o.scrollTop;return Wr(l).direction==="rtl"&&(u+=gr(r.clientWidth,l.clientWidth)-s),{width:s,height:d,x:u,y:m}}function Sb(n,r){const o=fr(n),l=La(n),s=o.visualViewport;let d=l.clientWidth,u=l.clientHeight,m=0,f=0;if(s){d=s.width,u=s.height;const g=E0();(!g||g&&r==="fixed")&&(m=s.offsetLeft,f=s.offsetTop)}return{width:d,height:u,x:m,y:f}}function wb(n,r){const o=ci(n,!0,r==="fixed"),l=o.top+n.clientTop,s=o.left+n.clientLeft,d=Sa(n)?zl(n):Uo(1),u=n.clientWidth*d.x,m=n.clientHeight*d.y,f=s*d.x,g=l*d.y;return{width:u,height:m,x:f,y:g}}function Rh(n,r,o){let l;if(r==="viewport")l=Sb(n,o);else if(r==="document")l=bb(La(n));else if(ba(r))l=wb(r,o);else{const s=kh(n);l={...r,x:r.x-s.x,y:r.y-s.y}}return cu(l)}function Ah(n,r){const o=Go(n);return o===r||!ba(o)||Hl(o)?!1:Wr(o).position==="fixed"||Ah(o,r)}function Cb(n,r){const o=r.get(n);if(o)return o;let l=Cs(n,[],!1).filter(m=>ba(m)&&si(m)!=="body"),s=null;const d=Wr(n).position==="fixed";let u=d?Go(n):n;for(;ba(u)&&!Hl(u);){const m=Wr(u),f=v0(u);!f&&m.position==="fixed"&&(s=null),(d?!f&&!s:!f&&m.position==="static"&&!!s&&["absolute","fixed"].includes(s.position)||ws(u)&&!f&&Ah(n,u))?l=l.filter(_=>_!==u):s=m,u=Go(u)}return r.set(n,l),l}function yb(n){let{element:r,boundary:o,rootBoundary:l,strategy:s}=n;const u=[...o==="clippingAncestors"?du(r)?[]:Cb(r,this._c):[].concat(o),l],m=u[0],f=u.reduce((g,_)=>{const v=Rh(r,_,s);return g.top=gr(v.top,g.top),g.right=Ea(v.right,g.right),g.bottom=Ea(v.bottom,g.bottom),g.left=gr(v.left,g.left),g},Rh(r,m,s));return{width:f.right-f.left,height:f.bottom-f.top,x:f.left,y:f.top}}function Tb(n){const{width:r,height:o}=Th(n);return{width:r,height:o}}function kb(n,r,o){const l=Sa(r),s=La(r),d=o==="fixed",u=ci(n,!0,d,r);let m={scrollLeft:0,scrollTop:0};const f=Uo(0);if(l||!l&&!d)if((si(r)!=="body"||ws(s))&&(m=uu(r)),l){const v=ci(r,!0,d,r);f.x=v.x+r.clientLeft,f.y=v.y+r.clientTop}else s&&(f.x=xh(s));const g=u.left+m.scrollLeft-f.x,_=u.top+m.scrollTop-f.y;return{x:g,y:_,width:u.width,height:u.height}}function S0(n){return Wr(n).position==="static"}function Oh(n,r){return!Sa(n)||Wr(n).position==="fixed"?null:r?r(n):n.offsetParent}function Ih(n,r){const o=fr(n);if(du(n))return o;if(!Sa(n)){let s=Go(n);for(;s&&!Hl(s);){if(ba(s)&&!S0(s))return s;s=Go(s)}return o}let l=Oh(n,r);for(;l&&_b(l)&&S0(l);)l=Oh(l,r);return l&&Hl(l)&&S0(l)&&!v0(l)?o:l||gb(n)||o}const xb=async function(n){const r=this.getOffsetParent||Ih,o=this.getDimensions,l=await o(n.floating);return{reference:kb(n.reference,await r(n.floating),n.strategy),floating:{x:0,y:0,width:l.width,height:l.height}}};function Rb(n){return Wr(n).direction==="rtl"}const Ab={convertOffsetParentRelativeRectToViewportRelativeRect:vb,getDocumentElement:La,getClippingRect:yb,getOffsetParent:Ih,getElementRects:xb,getClientRects:Eb,getDimensions:Tb,getScale:zl,isElement:ba,isRTL:Rb};function Ob(n,r){let o=null,l;const s=La(n);function d(){var m;clearTimeout(l),(m=o)==null||m.disconnect(),o=null}function u(m,f){m===void 0&&(m=!1),f===void 0&&(f=1),d();const{left:g,top:_,width:v,height:b}=n.getBoundingClientRect();if(m||r(),!v||!b)return;const C=lu(_),y=lu(s.clientWidth-(g+v)),R=lu(s.clientHeight-(_+b)),M=lu(g),$={rootMargin:-C+"px "+-y+"px "+-R+"px "+-M+"px",threshold:gr(0,Ea(1,f))||1};let A=!0;function x(D){const N=D[0].intersectionRatio;if(N!==f){if(!A)return u();N?u(!1,N):l=setTimeout(()=>{u(!1,1e-7)},1e3)}A=!1}try{o=new IntersectionObserver(x,{...$,root:s.ownerDocument})}catch{o=new IntersectionObserver(x,$)}o.observe(n)}return u(!0),d}function Ib(n,r,o,l){l===void 0&&(l={});const{ancestorScroll:s=!0,ancestorResize:d=!0,elementResize:u=typeof ResizeObserver=="function",layoutShift:m=typeof IntersectionObserver=="function",animationFrame:f=!1}=l,g=b0(n),_=s||d?[...g?Cs(g):[],...Cs(r)]:[];_.forEach(L=>{s&&L.addEventListener("scroll",o,{passive:!0}),d&&L.addEventListener("resize",o)});const v=g&&m?Ob(g,o):null;let b=-1,C=null;u&&(C=new ResizeObserver(L=>{let[$]=L;$&&$.target===g&&C&&(C.unobserve(r),cancelAnimationFrame(b),b=requestAnimationFrame(()=>{var A;(A=C)==null||A.observe(r)})),o()}),g&&!f&&C.observe(g),C.observe(r));let y,R=f?ci(n):null;f&&M();function M(){const L=ci(n);R&&(L.x!==R.x||L.y!==R.y||L.width!==R.width||L.height!==R.height)&&o(),R=L,y=requestAnimationFrame(M)}return o(),()=>{var L;_.forEach($=>{s&&$.removeEventListener("scroll",o),d&&$.removeEventListener("resize",o)}),v==null||v(),(L=C)==null||L.disconnect(),C=null,f&&cancelAnimationFrame(y)}}const Mb=db,Db=ub,Mh=lb,Bb=mb,Pb=sb,Lb=ib,Vb=pb,Fb=(n,r,o)=>{const l=new Map,s={platform:Ab,...o},d={...s.platform,_c:l};return ob(n,r,{...s,platform:d})};function Nb(n){return n!=null&&typeof n=="object"&&"$el"in n}function w0(n){if(Nb(n)){const r=n.$el;return h0(r)&&si(r)==="#comment"?null:r}return n}function Yl(n){return typeof n=="function"?n():e.unref(n)}function Ub(n){return{name:"arrow",options:n,fn(r){const o=w0(Yl(n.element));return o==null?{}:Lb({element:o,padding:n.padding}).fn(r)}}}function Dh(n){return typeof window>"u"?1:(n.ownerDocument.defaultView||window).devicePixelRatio||1}function Bh(n,r){const o=Dh(n);return Math.round(r*o)/o}function $b(n,r,o){o===void 0&&(o={});const l=o.whileElementsMounted,s=e.computed(()=>{var Z;return(Z=Yl(o.open))!=null?Z:!0}),d=e.computed(()=>Yl(o.middleware)),u=e.computed(()=>{var Z;return(Z=Yl(o.placement))!=null?Z:"bottom"}),m=e.computed(()=>{var Z;return(Z=Yl(o.strategy))!=null?Z:"absolute"}),f=e.computed(()=>{var Z;return(Z=Yl(o.transform))!=null?Z:!0}),g=e.computed(()=>w0(n.value)),_=e.computed(()=>w0(r.value)),v=e.ref(0),b=e.ref(0),C=e.ref(m.value),y=e.ref(u.value),R=e.shallowRef({}),M=e.ref(!1),L=e.computed(()=>{const Z={position:C.value,left:"0",top:"0"};if(!_.value)return Z;const H=Bh(_.value,v.value),W=Bh(_.value,b.value);return f.value?{...Z,transform:"translate("+H+"px, "+W+"px)",...Dh(_.value)>=1.5&&{willChange:"transform"}}:{position:C.value,left:H+"px",top:W+"px"}});let $;function A(){g.value==null||_.value==null||Fb(g.value,_.value,{middleware:d.value,placement:u.value,strategy:m.value}).then(Z=>{v.value=Z.x,b.value=Z.y,C.value=Z.strategy,y.value=Z.placement,R.value=Z.middlewareData,M.value=!0})}function x(){typeof $=="function"&&($(),$=void 0)}function D(){if(x(),l===void 0){A();return}if(g.value!=null&&_.value!=null){$=l(g.value,_.value,A);return}}function N(){s.value||(M.value=!1)}return e.watch([d,u,m],A,{flush:"sync"}),e.watch([g,_],D,{flush:"sync"}),e.watch(s,N,{flush:"sync"}),e.getCurrentScope()&&e.onScopeDispose(x),{x:e.shallowReadonly(v),y:e.shallowReadonly(b),strategy:e.shallowReadonly(C),placement:e.shallowReadonly(y),middlewareData:e.shallowReadonly(R),isPositioned:e.shallowReadonly(M),floatingStyles:L,update:A}}function Jt(n,r){const o=typeof n=="string"&&!r?`${n}Context`:r,l=Symbol(o);return[s=>{const d=e.inject(l,s);if(d||d===null)return d;throw new Error(`Injection \`${l.toString()}\` not found. Component must be used within ${Array.isArray(n)?`one of the following components: ${n.join(", ")}`:`\`${n}\``}`)},s=>(e.provide(l,s),s)]}function C0(n,r,o){const l=o.originalEvent.target,s=new CustomEvent(n,{bubbles:!1,cancelable:!0,detail:o});r&&l.addEventListener(n,r,{once:!0}),l.dispatchEvent(s)}function Gb(n){return n&&n.__esModule&&Object.prototype.hasOwnProperty.call(n,"default")?n.default:n}var Hb=function n(r,o){if(r===o)return!0;if(r&&o&&typeof r=="object"&&typeof o=="object"){if(r.constructor!==o.constructor)return!1;var l,s,d;if(Array.isArray(r)){if(l=r.length,l!=o.length)return!1;for(s=l;s--!==0;)if(!n(r[s],o[s]))return!1;return!0}if(r.constructor===RegExp)return r.source===o.source&&r.flags===o.flags;if(r.valueOf!==Object.prototype.valueOf)return r.valueOf()===o.valueOf();if(r.toString!==Object.prototype.toString)return r.toString()===o.toString();if(d=Object.keys(r),l=d.length,l!==Object.keys(o).length)return!1;for(s=l;s--!==0;)if(!Object.prototype.hasOwnProperty.call(o,d[s]))return!1;for(s=l;s--!==0;){var u=d[s];if(!n(r[u],o[u]))return!1}return!0}return r!==r&&o!==o};const di=Gb(Hb);function y0(n){return n==null}function zb(n,r){var o;const l=e.shallowRef();return e.watchEffect(()=>{l.value=n()},{...r,flush:(o=void 0)!=null?o:"sync"}),e.readonly(l)}function Zl(n){return e.getCurrentScope()?(e.onScopeDispose(n),!0):!1}function Yb(){const n=new Set,r=o=>{n.delete(o)};return{on:o=>{n.add(o);const l=()=>r(o);return Zl(l),{off:l}},off:r,trigger:(...o)=>Promise.all(Array.from(n).map(l=>l(...o)))}}function Zb(n){let r=!1,o;const l=e.effectScope(!0);return(...s)=>(r||(o=l.run(()=>n(...s)),r=!0),o)}function Ph(n){let r=0,o,l;const s=()=>{r-=1,l&&r<=0&&(l.stop(),o=void 0,l=void 0)};return(...d)=>(r+=1,o||(l=e.effectScope(!0),o=l.run(()=>n(...d))),Zl(s),o)}function Va(n){return typeof n=="function"?n():e.unref(n)}const Fa=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const qb=n=>typeof n<"u",Wb=n=>n!=null,jb=Object.prototype.toString,Kb=n=>jb.call(n)==="[object Object]",Qb=()=>{},Lh=Xb();function Xb(){var n,r;return Fa&&((n=window==null?void 0:window.navigator)==null?void 0:n.userAgent)&&(/iP(?:ad|hone|od)/.test(window.navigator.userAgent)||((r=window==null?void 0:window.navigator)==null?void 0:r.maxTouchPoints)>2&&/iPad|Macintosh/.test(window==null?void 0:window.navigator.userAgent))}function Jb(n){return e.getCurrentInstance()}function Vh(n,r=1e4){return e.customRef((o,l)=>{let s=Va(n),d;const u=()=>setTimeout(()=>{s=Va(n),l()},Va(r));return Zl(()=>{clearTimeout(d)}),{get(){return o(),s},set(m){s=m,l(),clearTimeout(d),d=u()}}})}function eS(n,r){Jb()&&e.onBeforeUnmount(n,r)}function Fh(n,r,o={}){const{immediate:l=!0}=o,s=e.ref(!1);let d=null;function u(){d&&(clearTimeout(d),d=null)}function m(){s.value=!1,u()}function f(...g){u(),s.value=!0,d=setTimeout(()=>{s.value=!1,d=null,n(...g)},Va(r))}return l&&(s.value=!0,Fa&&f()),Zl(m),{isPending:e.readonly(s),start:f,stop:m}}function Na(n){var r;const o=Va(n);return(r=o==null?void 0:o.$el)!=null?r:o}const pu=Fa?window:void 0;function ql(...n){let r,o,l,s;if(typeof n[0]=="string"||Array.isArray(n[0])?([o,l,s]=n,r=pu):[r,o,l,s]=n,!r)return Qb;Array.isArray(o)||(o=[o]),Array.isArray(l)||(l=[l]);const d=[],u=()=>{d.forEach(_=>_()),d.length=0},m=(_,v,b,C)=>(_.addEventListener(v,b,C),()=>_.removeEventListener(v,b,C)),f=e.watch(()=>[Na(r),Va(s)],([_,v])=>{if(u(),!_)return;const b=Kb(v)?{...v}:v;d.push(...o.flatMap(C=>l.map(y=>m(_,C,y,b))))},{immediate:!0,flush:"post"}),g=()=>{f(),u()};return Zl(g),g}function tS(n){return typeof n=="function"?n:typeof n=="string"?r=>r.key===n:Array.isArray(n)?r=>n.includes(r.key):()=>!0}function nS(...n){let r,o,l={};n.length===3?(r=n[0],o=n[1],l=n[2]):n.length===2?typeof n[1]=="object"?(r=!0,o=n[0],l=n[1]):(r=n[0],o=n[1]):(r=!0,o=n[0]);const{target:s=pu,eventName:d="keydown",passive:u=!1,dedupe:m=!1}=l,f=tS(r);return ql(s,d,g=>{g.repeat&&Va(m)||f(g)&&o(g)},u)}function Nh(){const n=e.ref(!1),r=e.getCurrentInstance();return r&&e.onMounted(()=>{n.value=!0},r),n}function rS(n){const r=Nh();return e.computed(()=>(r.value,!!n()))}function aS(n,r,o={}){const{window:l=pu,...s}=o;let d;const u=rS(()=>l&&"MutationObserver"in l),m=()=>{d&&(d.disconnect(),d=void 0)},f=e.computed(()=>{const b=Va(n),C=(Array.isArray(b)?b:[b]).map(Na).filter(Wb);return new Set(C)}),g=e.watch(()=>f.value,b=>{m(),u.value&&b.size&&(d=new MutationObserver(r),b.forEach(C=>d.observe(C,s)))},{immediate:!0,flush:"post"}),_=()=>d==null?void 0:d.takeRecords(),v=()=>{m(),g()};return Zl(v),{isSupported:u,stop:v,takeRecords:_}}function oS(n){return JSON.parse(JSON.stringify(n))}function hr(n,r,o,l={}){var s,d,u;const{clone:m=!1,passive:f=!1,eventName:g,deep:_=!1,defaultValue:v,shouldEmit:b}=l,C=e.getCurrentInstance(),y=o||(C==null?void 0:C.emit)||((s=C==null?void 0:C.$emit)==null?void 0:s.bind(C))||((u=(d=C==null?void 0:C.proxy)==null?void 0:d.$emit)==null?void 0:u.bind(C==null?void 0:C.proxy));let R=g;r||(r="modelValue"),R=R||`update:${r.toString()}`;const M=A=>m?typeof m=="function"?m(A):oS(A):A,L=()=>qb(n[r])?M(n[r]):v,$=A=>{b?b(A)&&y(R,A):y(R,A)};if(f){const A=L(),x=e.ref(A);let D=!1;return e.watch(()=>n[r],N=>{D||(D=!0,x.value=M(N),e.nextTick(()=>D=!1))}),e.watch(x,N=>{!D&&(N!==n[r]||_)&&$(N)},{deep:_}),x}else return e.computed({get(){return L()},set(A){$(A)}})}function T0(n){return n?n.flatMap(r=>r.type===e.Fragment?T0(r.children):[r]):[]}function or(){let n=document.activeElement;if(n==null)return null;for(;n!=null&&n.shadowRoot!=null&&n.shadowRoot.activeElement!=null;)n=n.shadowRoot.activeElement;return n}const iS=["INPUT","TEXTAREA"];function Uh(n,r,o,l={}){if(!r||l.enableIgnoredElement&&iS.includes(r.nodeName))return null;const{arrowKeyOptions:s="both",attributeName:d="[data-radix-vue-collection-item]",itemsArray:u=[],loop:m=!0,dir:f="ltr",preventScroll:g=!0,focus:_=!1}=l,[v,b,C,y,R,M]=[n.key==="ArrowRight",n.key==="ArrowLeft",n.key==="ArrowUp",n.key==="ArrowDown",n.key==="Home",n.key==="End"],L=C||y,$=v||b;if(!R&&!M&&(!L&&!$||s==="vertical"&&$||s==="horizontal"&&L))return null;const A=o?Array.from(o.querySelectorAll(d)):u;if(!A.length)return null;g&&n.preventDefault();let x=null;return $||L?x=$h(A,r,{goForward:L?y:f==="ltr"?v:b,loop:m}):R?x=A.at(0)||null:M&&(x=A.at(-1)||null),_&&(x==null||x.focus()),x}function $h(n,r,o,l=n.length){if(--l===0)return null;const s=n.indexOf(r),d=o.goForward?s+1:s-1;if(!o.loop&&(d<0||d>=n.length))return null;const u=(d+n.length)%n.length,m=n[u];return m?m.hasAttribute("disabled")&&m.getAttribute("disabled")!=="false"?$h(n,m,o,l):m:null}function k0(n){if(n===null||typeof n!="object")return!1;const r=Object.getPrototypeOf(n);return r!==null&&r!==Object.prototype&&Object.getPrototypeOf(r)!==null||Symbol.iterator in n?!1:Symbol.toStringTag in n?Object.prototype.toString.call(n)==="[object Module]":!0}function x0(n,r,o=".",l){if(!k0(r))return x0(n,{},o);const s=Object.assign({},r);for(const d in n){if(d==="__proto__"||d==="constructor")continue;const u=n[d];u!=null&&(Array.isArray(u)&&Array.isArray(s[d])?s[d]=[...u,...s[d]]:k0(u)&&k0(s[d])?s[d]=x0(u,s[d],(o?`${o}.`:"")+d.toString()):s[d]=u)}return s}function lS(n){return(...r)=>r.reduce((o,l)=>x0(o,l,""),{})}const sS=lS(),[R0,xK]=Jt("ConfigProvider");let cS="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict",dS=(n=21)=>{let r="",o=n;for(;o--;)r+=cS[Math.random()*64|0];return r};const uS=Ph(()=>{const n=e.ref(new Map),r=e.ref(),o=e.computed(()=>{for(const u of n.value.values())if(u)return!0;return!1}),l=R0({scrollBody:e.ref(!0)});let s=null;const d=()=>{document.body.style.paddingRight="",document.body.style.marginRight="",document.body.style.pointerEvents="",document.body.style.removeProperty("--scrollbar-width"),document.body.style.overflow=r.value??"",Lh&&(s==null||s()),r.value=void 0};return e.watch(o,(u,m)=>{var f;if(!Fa)return;if(!u){m&&d();return}r.value===void 0&&(r.value=document.body.style.overflow);const g=window.innerWidth-document.documentElement.clientWidth,_={padding:g,margin:0},v=(f=l.scrollBody)!=null&&f.value?typeof l.scrollBody.value=="object"?sS({padding:l.scrollBody.value.padding===!0?g:l.scrollBody.value.padding,margin:l.scrollBody.value.margin===!0?g:l.scrollBody.value.margin},_):_:{padding:0,margin:0};g>0&&(document.body.style.paddingRight=typeof v.padding=="number"?`${v.padding}px`:String(v.padding),document.body.style.marginRight=typeof v.margin=="number"?`${v.margin}px`:String(v.margin),document.body.style.setProperty("--scrollbar-width",`${g}px`),document.body.style.overflow="hidden"),Lh&&(s=ql(document,"touchmove",b=>pS(b),{passive:!1})),e.nextTick(()=>{document.body.style.pointerEvents="none",document.body.style.overflow="hidden"})},{immediate:!0,flush:"sync"}),n});function A0(n){const r=dS(6),o=uS();o.value.set(r,n??!1);const l=e.computed({get:()=>o.value.get(r)??!1,set:s=>o.value.set(r,s)});return eS(()=>{o.value.delete(r)}),l}function Gh(n){const r=window.getComputedStyle(n);if(r.overflowX==="scroll"||r.overflowY==="scroll"||r.overflowX==="auto"&&n.clientWidth<n.scrollWidth||r.overflowY==="auto"&&n.clientHeight<n.scrollHeight)return!0;{const o=n.parentNode;return!(o instanceof Element)||o.tagName==="BODY"?!1:Gh(o)}}function pS(n){const r=n||window.event,o=r.target;return o instanceof Element&&Gh(o)?!1:r.touches.length>1?!0:(r.preventDefault&&r.cancelable&&r.preventDefault(),!1)}const mS="data-radix-vue-collection-item";function _S(n,r=mS){const o=Symbol();return{createCollection:l=>{const s=e.ref([]);function d(){const u=Na(l);return u?s.value=Array.from(u.querySelectorAll(`[${r}]:not([data-disabled])`)):s.value=[]}return e.onBeforeUpdate(()=>{s.value=[]}),e.onMounted(d),e.onUpdated(d),e.watch(()=>l==null?void 0:l.value,d,{immediate:!0}),e.provide(o,s),s},injectCollection:()=>e.inject(o,e.ref([]))}}function Wl(n){const r=R0({dir:e.ref("ltr")});return e.computed(()=>{var o;return(n==null?void 0:n.value)||((o=r.dir)==null?void 0:o.value)||"ltr"})}function ys(n){const r=e.getCurrentInstance(),o=r==null?void 0:r.type.emits,l={};return o!=null&&o.length||console.warn(`No emitted event found. Please check component: ${r==null?void 0:r.type.__name}`),o==null||o.forEach(s=>{l[e.toHandlerKey(e.camelize(s))]=(...d)=>n(s,...d)}),l}let O0=0;function gS(){e.watchEffect(n=>{if(!Fa)return;const r=document.querySelectorAll("[data-radix-focus-guard]");document.body.insertAdjacentElement("afterbegin",r[0]??Hh()),document.body.insertAdjacentElement("beforeend",r[1]??Hh()),O0++,n(()=>{O0===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(o=>o.remove()),O0--})})}function Hh(){const n=document.createElement("span");return n.setAttribute("data-radix-focus-guard",""),n.tabIndex=0,n.style.outline="none",n.style.opacity="0",n.style.position="fixed",n.style.pointerEvents="none",n}function fS(n){return e.computed(()=>{var r;return Va(n)?!!((r=Na(n))!=null&&r.closest("form")):!0})}function ui(n){const r=e.getCurrentInstance(),o=Object.keys((r==null?void 0:r.type.props)??{}).reduce((s,d)=>{const u=(r==null?void 0:r.type.props[d]).default;return u!==void 0&&(s[d]=u),s},{}),l=e.toRef(n);return e.computed(()=>{const s={},d=(r==null?void 0:r.vnode.props)??{};return Object.keys(d).forEach(u=>{s[e.camelize(u)]=d[u]}),Object.keys({...o,...s}).reduce((u,m)=>(l.value[m]!==void 0&&(u[m]=l.value[m]),u),{})})}function dn(n,r){const o=ui(n),l=r?ys(r):{};return e.computed(()=>({...o.value,...l}))}function Oe(){const n=e.getCurrentInstance(),r=e.ref(),o=e.computed(()=>{var u,m;return["#text","#comment"].includes((u=r.value)==null?void 0:u.$el.nodeName)?(m=r.value)==null?void 0:m.$el.nextElementSibling:Na(r)}),l=Object.assign({},n.exposed),s={};for(const u in n.props)Object.defineProperty(s,u,{enumerable:!0,configurable:!0,get:()=>n.props[u]});if(Object.keys(l).length>0)for(const u in l)Object.defineProperty(s,u,{enumerable:!0,configurable:!0,get:()=>l[u]});Object.defineProperty(s,"$el",{enumerable:!0,configurable:!0,get:()=>n.vnode.el}),n.exposed=s;function d(u){r.value=u,u&&(Object.defineProperty(s,"$el",{enumerable:!0,configurable:!0,get:()=>u instanceof Element?u:u.$el}),n.exposed=s)}return{forwardRef:d,currentRef:r,currentElement:o}}function hS(n,r){const o=Vh(!1,300),l=e.ref(null),s=Yb();function d(){l.value=null,o.value=!1}function u(m,f){const g=m.currentTarget,_={x:m.clientX,y:m.clientY},v=vS(_,g.getBoundingClientRect()),b=ES(_,v),C=bS(f.getBoundingClientRect()),y=wS([...b,...C]);l.value=y,o.value=!0}return e.watchEffect(m=>{if(n.value&&r.value){const f=_=>u(_,r.value),g=_=>u(_,n.value);n.value.addEventListener("pointerleave",f),r.value.addEventListener("pointerleave",g),m(()=>{var _,v;(_=n.value)==null||_.removeEventListener("pointerleave",f),(v=r.value)==null||v.removeEventListener("pointerleave",g)})}}),e.watchEffect(m=>{var f;if(l.value){const g=_=>{var v,b;if(!l.value)return;const C=_.target,y={x:_.clientX,y:_.clientY},R=((v=n.value)==null?void 0:v.contains(C))||((b=r.value)==null?void 0:b.contains(C)),M=!SS(y,l.value),L=!!C.closest("[data-grace-area-trigger]");R?d():(M||L)&&(d(),s.trigger())};(f=n.value)==null||f.ownerDocument.addEventListener("pointermove",g),m(()=>{var _;return(_=n.value)==null?void 0:_.ownerDocument.removeEventListener("pointermove",g)})}}),{isPointerInTransit:o,onPointerExit:s.on}}function vS(n,r){const o=Math.abs(r.top-n.y),l=Math.abs(r.bottom-n.y),s=Math.abs(r.right-n.x),d=Math.abs(r.left-n.x);switch(Math.min(o,l,s,d)){case d:return"left";case s:return"right";case o:return"top";case l:return"bottom";default:throw new Error("unreachable")}}function ES(n,r,o=5){const l=[];switch(r){case"top":l.push({x:n.x-o,y:n.y+o},{x:n.x+o,y:n.y+o});break;case"bottom":l.push({x:n.x-o,y:n.y-o},{x:n.x+o,y:n.y-o});break;case"left":l.push({x:n.x+o,y:n.y-o},{x:n.x+o,y:n.y+o});break;case"right":l.push({x:n.x-o,y:n.y-o},{x:n.x-o,y:n.y+o});break}return l}function bS(n){const{top:r,right:o,bottom:l,left:s}=n;return[{x:s,y:r},{x:o,y:r},{x:o,y:l},{x:s,y:l}]}function SS(n,r){const{x:o,y:l}=n;let s=!1;for(let d=0,u=r.length-1;d<r.length;u=d++){const m=r[d].x,f=r[d].y,g=r[u].x,_=r[u].y;f>l!=_>l&&o<(g-m)*(l-f)/(_-f)+m&&(s=!s)}return s}function wS(n){const r=n.slice();return r.sort((o,l)=>o.x<l.x?-1:o.x>l.x?1:o.y<l.y?-1:o.y>l.y?1:0),CS(r)}function CS(n){if(n.length<=1)return n.slice();const r=[];for(let l=0;l<n.length;l++){const s=n[l];for(;r.length>=2;){const d=r[r.length-1],u=r[r.length-2];if((d.x-u.x)*(s.y-u.y)>=(d.y-u.y)*(s.x-u.x))r.pop();else break}r.push(s)}r.pop();const o=[];for(let l=n.length-1;l>=0;l--){const s=n[l];for(;o.length>=2;){const d=o[o.length-1],u=o[o.length-2];if((d.x-u.x)*(s.y-u.y)>=(d.y-u.y)*(s.x-u.x))o.pop();else break}o.push(s)}return o.pop(),r.length===1&&o.length===1&&r[0].x===o[0].x&&r[0].y===o[0].y?r:r.concat(o)}var yS=function(n){if(typeof document>"u")return null;var r=Array.isArray(n)?n[0]:n;return r.ownerDocument.body},jl=new WeakMap,mu=new WeakMap,_u={},I0=0,zh=function(n){return n&&(n.host||zh(n.parentNode))},TS=function(n,r){return r.map(function(o){if(n.contains(o))return o;var l=zh(o);return l&&n.contains(l)?l:(console.error("aria-hidden",o,"in not contained inside",n,". Doing nothing"),null)}).filter(function(o){return!!o})},kS=function(n,r,o,l){var s=TS(r,Array.isArray(n)?n:[n]);_u[o]||(_u[o]=new WeakMap);var d=_u[o],u=[],m=new Set,f=new Set(s),g=function(v){!v||m.has(v)||(m.add(v),g(v.parentNode))};s.forEach(g);var _=function(v){!v||f.has(v)||Array.prototype.forEach.call(v.children,function(b){if(m.has(b))_(b);else try{var C=b.getAttribute(l),y=C!==null&&C!=="false",R=(jl.get(b)||0)+1,M=(d.get(b)||0)+1;jl.set(b,R),d.set(b,M),u.push(b),R===1&&y&&mu.set(b,!0),M===1&&b.setAttribute(o,"true"),y||b.setAttribute(l,"true")}catch(L){console.error("aria-hidden: cannot operate on ",b,L)}})};return _(r),m.clear(),I0++,function(){u.forEach(function(v){var b=jl.get(v)-1,C=d.get(v)-1;jl.set(v,b),d.set(v,C),b||(mu.has(v)||v.removeAttribute(l),mu.delete(v)),C||v.removeAttribute(o)}),I0--,I0||(jl=new WeakMap,jl=new WeakMap,mu=new WeakMap,_u={})}},xS=function(n,r,o){o===void 0&&(o="data-aria-hidden");var l=Array.from(Array.isArray(n)?n:[n]),s=yS(n);return s?(l.push.apply(l,Array.from(s.querySelectorAll("[aria-live]"))),kS(l,s,o,"aria-hidden")):function(){return null}};function M0(n){let r;e.watch(()=>Na(n),o=>{o?r=xS(o):r&&r()}),e.onUnmounted(()=>{r&&r()})}let RS=0;function vr(n,r="radix"){const o=R0({useId:void 0});return vh.useId?`${r}-${vh.useId()}`:o.useId?`${r}-${o.useId()}`:`${r}-${++RS}`}function AS(n){const r=e.ref(),o=e.computed(()=>{var s;return((s=r.value)==null?void 0:s.width)??0}),l=e.computed(()=>{var s;return((s=r.value)==null?void 0:s.height)??0});return e.onMounted(()=>{const s=Na(n);if(s){r.value={width:s.offsetWidth,height:s.offsetHeight};const d=new ResizeObserver(u=>{if(!Array.isArray(u)||!u.length)return;const m=u[0];let f,g;if("borderBoxSize"in m){const _=m.borderBoxSize,v=Array.isArray(_)?_[0]:_;f=v.inlineSize,g=v.blockSize}else f=s.offsetWidth,g=s.offsetHeight;r.value={width:f,height:g}});return d.observe(s,{box:"border-box"}),()=>d.unobserve(s)}else r.value=void 0}),{width:o,height:l}}function OS(n,r){const o=e.ref(n);function l(s){return r[o.value][s]??o.value}return{state:o,dispatch:s=>{o.value=l(s)}}}const IS="data-item-text";function MS(n){const r=Vh("",1e3);return{search:r,handleTypeaheadSearch:(o,l)=>{if(!(n!=null&&n.value)&&!l)return;r.value=r.value+o;const s=(n==null?void 0:n.value)??l,d=or(),u=s.map(v=>{var b;return{ref:v,textValue:((b=(v.querySelector(`[${IS}]`)??v).textContent)==null?void 0:b.trim())??""}}),m=u.find(v=>v.ref===d),f=u.map(v=>v.textValue),g=BS(f,r.value,m==null?void 0:m.textValue),_=u.find(v=>v.textValue===g);return _&&_.ref.focus(),_==null?void 0:_.ref},resetTypeahead:()=>{r.value=""}}}function DS(n,r){return n.map((o,l)=>n[(r+l)%n.length])}function BS(n,r,o){const l=r.length>1&&Array.from(r).every(m=>m===r[0])?r[0]:r,s=o?n.indexOf(o):-1;let d=DS(n,Math.max(s,0));l.length===1&&(d=d.filter(m=>m!==o));const u=d.find(m=>m.toLowerCase().startsWith(l.toLowerCase()));return u!==o?u:void 0}const D0=e.defineComponent({name:"PrimitiveSlot",inheritAttrs:!1,setup(n,{attrs:r,slots:o}){return()=>{var l,s;if(!o.default)return null;const d=T0(o.default()),u=d.findIndex(_=>_.type!==e.Comment);if(u===-1)return d;const m=d[u];(l=m.props)==null||delete l.ref;const f=m.props?e.mergeProps(r,m.props):r;r.class&&(s=m.props)!=null&&s.class&&delete m.props.class;const g=e.cloneVNode(m,f);for(const _ in f)_.startsWith("on")&&(g.props||(g.props={}),g.props[_]=f[_]);return d.length===1?g:(d[u]=g,d)}}}),Ke=e.defineComponent({name:"Primitive",inheritAttrs:!1,props:{asChild:{type:Boolean,default:!1},as:{type:[String,Object],default:"div"}},setup(n,{attrs:r,slots:o}){const l=n.asChild?"template":n.as;return typeof l=="string"&&["area","img","input"].includes(l)?()=>e.h(l,r):l!=="template"?()=>e.h(n.as,r,{default:o.default}):()=>e.h(D0,r,{default:o.default})}});function Yh(){const n=e.ref(),r=e.computed(()=>{var o,l;return["#text","#comment"].includes((o=n.value)==null?void 0:o.$el.nodeName)?(l=n.value)==null?void 0:l.$el.nextElementSibling:Na(n)});return{primitiveElement:n,currentElement:r}}const[Zh,PS]=Jt("CollapsibleRoot"),LS=e.defineComponent({__name:"CollapsibleRoot",props:{defaultOpen:{type:Boolean,default:!1},open:{type:Boolean,default:void 0},disabled:{type:Boolean},asChild:{type:Boolean},as:{}},emits:["update:open"],setup(n,{expose:r,emit:o}){const l=n,s=hr(l,"open",o,{defaultValue:l.defaultOpen,passive:l.open===void 0}),d=hr(l,"disabled");return PS({contentId:"",disabled:d,open:s,onOpenToggle:()=>{s.value=!s.value}}),r({open:s}),Oe(),(u,m)=>(e.openBlock(),e.createBlock(e.unref(Ke),{as:u.as,"as-child":l.asChild,"data-state":e.unref(s)?"open":"closed","data-disabled":e.unref(d)?"":void 0},{default:e.withCtx(()=>[e.renderSlot(u.$slots,"default",{open:e.unref(s)})]),_:3},8,["as","as-child","data-state","data-disabled"]))}}),VS=e.defineComponent({__name:"CollapsibleTrigger",props:{asChild:{type:Boolean},as:{default:"button"}},setup(n){const r=n;Oe();const o=Zh();return(l,s)=>{var d,u;return e.openBlock(),e.createBlock(e.unref(Ke),{type:l.as==="button"?"button":void 0,as:l.as,"as-child":r.asChild,"aria-controls":e.unref(o).contentId,"aria-expanded":e.unref(o).open.value,"data-state":e.unref(o).open.value?"open":"closed","data-disabled":(d=e.unref(o).disabled)!=null&&d.value?"":void 0,disabled:(u=e.unref(o).disabled)==null?void 0:u.value,onClick:e.unref(o).onOpenToggle},{default:e.withCtx(()=>[e.renderSlot(l.$slots,"default")]),_:3},8,["type","as","as-child","aria-controls","aria-expanded","data-state","data-disabled","disabled","onClick"])}}});function FS(n,r){var o;const l=e.ref({}),s=e.ref("none"),d=e.ref(n),u=n.value?"mounted":"unmounted";let m;const f=((o=r.value)==null?void 0:o.ownerDocument.defaultView)??pu,{state:g,dispatch:_}=OS(u,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}}),v=M=>{var L;if(Fa){const $=new CustomEvent(M,{bubbles:!1,cancelable:!1});(L=r.value)==null||L.dispatchEvent($)}};e.watch(n,async(M,L)=>{var $;const A=L!==M;if(await e.nextTick(),A){const x=s.value,D=gu(r.value);M?(_("MOUNT"),v("enter"),D==="none"&&v("after-enter")):D==="none"||(($=l.value)==null?void 0:$.display)==="none"?(_("UNMOUNT"),v("leave"),v("after-leave")):L&&x!==D?(_("ANIMATION_OUT"),v("leave")):(_("UNMOUNT"),v("after-leave"))}},{immediate:!0});const b=M=>{const L=gu(r.value),$=L.includes(M.animationName),A=g.value==="mounted"?"enter":"leave";if(M.target===r.value&&$&&(v(`after-${A}`),_("ANIMATION_END"),!d.value)){const x=r.value.style.animationFillMode;r.value.style.animationFillMode="forwards",m=f==null?void 0:f.setTimeout(()=>{var D;((D=r.value)==null?void 0:D.style.animationFillMode)==="forwards"&&(r.value.style.animationFillMode=x)})}M.target===r.value&&L==="none"&&_("ANIMATION_END")},C=M=>{M.target===r.value&&(s.value=gu(r.value))},y=e.watch(r,(M,L)=>{M?(l.value=getComputedStyle(M),M.addEventListener("animationstart",C),M.addEventListener("animationcancel",b),M.addEventListener("animationend",b)):(_("ANIMATION_END"),m!==void 0&&(f==null||f.clearTimeout(m)),L==null||L.removeEventListener("animationstart",C),L==null||L.removeEventListener("animationcancel",b),L==null||L.removeEventListener("animationend",b))},{immediate:!0}),R=e.watch(g,()=>{const M=gu(r.value);s.value=g.value==="mounted"?M:"none"});return e.onUnmounted(()=>{y(),R()}),{isPresent:e.computed(()=>["mounted","unmountSuspended"].includes(g.value))}}function gu(n){return n&&getComputedStyle(n).animationName||"none"}const pi=e.defineComponent({name:"Presence",props:{present:{type:Boolean,required:!0},forceMount:{type:Boolean}},slots:{},setup(n,{slots:r,expose:o}){var l;const{present:s,forceMount:d}=e.toRefs(n),u=e.ref(),{isPresent:m}=FS(s,u);o({present:m});let f=r.default({present:m});f=T0(f||[]);const g=e.getCurrentInstance();if(f&&(f==null?void 0:f.length)>1){const _=(l=g==null?void 0:g.parent)!=null&&l.type.name?`<${g.parent.type.name} />`:"component";throw new Error([`Detected an invalid children for \`${_}\` for \`Presence\` component.`,"","Note: Presence works similarly to `v-if` directly, but it waits for animation/transition to finished before unmounting. So it expect only one direct child of valid VNode type.","You can apply a few solutions:",["Provide a single child element so that `presence` directive attach correctly.","Ensure the first child is an actual element instead of a raw text node or comment node."].map(v=>` - ${v}`).join(`
`)].join(`
`))}return()=>d.value||s.value||m.value?e.h(r.default({present:m})[0],{ref:_=>{const v=Na(_);return typeof(v==null?void 0:v.hasAttribute)>"u"||(v!=null&&v.hasAttribute("data-radix-popper-content-wrapper")?u.value=v.firstElementChild:u.value=v),v}}):null}}),NS=e.defineComponent({inheritAttrs:!1,__name:"CollapsibleContent",props:{forceMount:{type:Boolean},asChild:{type:Boolean},as:{}},setup(n){const r=n,o=Zh();o.contentId||(o.contentId=vr(void 0,"radix-vue-collapsible-content"));const l=e.ref(),{forwardRef:s,currentElement:d}=Oe(),u=e.ref(0),m=e.ref(0),f=e.computed(()=>o.open.value),g=e.ref(f.value),_=e.ref();return e.watch(()=>{var v;return[f.value,(v=l.value)==null?void 0:v.present]},async()=>{await e.nextTick();const v=d.value;if(!v)return;_.value=_.value||{transitionDuration:v.style.transitionDuration,animationName:v.style.animationName},v.style.transitionDuration="0s",v.style.animationName="none";const b=v.getBoundingClientRect();m.value=b.height,u.value=b.width,g.value||(v.style.transitionDuration=_.value.transitionDuration,v.style.animationName=_.value.animationName)},{immediate:!0}),e.onMounted(()=>{requestAnimationFrame(()=>{g.value=!1})}),(v,b)=>(e.openBlock(),e.createBlock(e.unref(pi),{ref_key:"presentRef",ref:l,present:v.forceMount||e.unref(o).open.value,"force-mount":!0},{default:e.withCtx(()=>{var C,y;return[e.createVNode(e.unref(Ke),e.mergeProps(v.$attrs,{id:e.unref(o).contentId,ref:e.unref(s),"as-child":r.asChild,as:v.as,"data-state":e.unref(o).open.value?"open":"closed","data-disabled":(C=e.unref(o).disabled)!=null&&C.value?"":void 0,hidden:!((y=l.value)!=null&&y.present),style:{"--radix-collapsible-content-height":`${m.value}px`,"--radix-collapsible-content-width":`${u.value}px`}}),{default:e.withCtx(()=>{var R;return[(R=l.value)!=null&&R.present?e.renderSlot(v.$slots,"default",{key:0}):e.createCommentVNode("",!0)]}),_:3},16,["id","as-child","as","data-state","data-disabled","hidden","style"])]}),_:3},8,["present"]))}});function qh({type:n,defaultValue:r,modelValue:o}){const l=o||r;if(y0(n)&&y0(o)&&y0(r))throw new Error("Either the `type` or the `value` or `default-value` prop must be defined.");if(o!==void 0&&r!==void 0&&typeof o!=typeof r)throw new Error(`Invalid prop \`value\` of value \`${o}\` supplied, should be the same type as the \`defaultValue\` prop, which is \`${r}\`. The \`value\` prop must be:
${n==="single"?"- a string":n==="multiple"?"- an array of strings":`- a string
- an array of strings`}
- \`undefined\``);const s=o!==void 0||r!==void 0;if(n&&s){const d=Array.isArray(o)||Array.isArray(r),u=o!==void 0?"modelValue":"defaultValue",m=u==="modelValue"?typeof o:typeof r;if(n==="single"&&d)return console.error(`Invalid prop \`${u}\` of type ${m} supplied with type \`single\`. The \`modelValue\` prop must be a string or \`undefined\`.
You can remove the \`type\` prop to let the component infer the type from the ${u} prop.`),"multiple";if(n==="multiple"&&!d)return console.error(`Invalid prop \`${u}\` of type ${m} supplied with type \`multiple\`. The \`modelValue\` prop must be an array of strings or \`undefined\`.
You can remove the \`type\` prop to let the component infer the type from the ${u} prop.`),"single"}return s?Array.isArray(l)?"multiple":"single":n}function US({type:n,defaultValue:r,modelValue:o}){return n||qh({type:n,defaultValue:r,modelValue:o})}function $S({type:n,defaultValue:r}){return r!==void 0?r:n==="single"?void 0:[]}function GS(n,r){const o=e.ref(US(n)),l=hr(n,"modelValue",r,{defaultValue:$S(n),passive:n.modelValue===void 0,deep:!0});e.watch(()=>[n.type,n.modelValue,n.defaultValue],()=>{const u=qh(n);o.value!==u&&(o.value=u)},{immediate:!0});function s(u){if(o.value==="single")l.value=u===l.value?void 0:u;else{const m=[...l.value||[]];if(m.includes(u)){const f=m.findIndex(g=>g===u);m.splice(f,1)}else m.push(u);l.value=m}}const d=e.computed(()=>o.value==="single");return{modelValue:l,type:o,changeModelValue:s,isSingle:d}}const[fu,HS]=Jt("AccordionRoot"),zS=e.defineComponent({__name:"AccordionRoot",props:{collapsible:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},dir:{},orientation:{default:"vertical"},asChild:{type:Boolean},as:{},type:{},modelValue:{},defaultValue:{}},emits:["update:modelValue"],setup(n,{emit:r}){const o=n,l=r,{dir:s,disabled:d}=e.toRefs(o),u=Wl(s),{modelValue:m,changeModelValue:f,isSingle:g}=GS(o,l),{forwardRef:_,currentElement:v}=Oe();return HS({disabled:d,direction:u,orientation:o.orientation,parentElement:v,isSingle:g,collapsible:o.collapsible,modelValue:m,changeModelValue:f}),(b,C)=>(e.openBlock(),e.createBlock(e.unref(Ke),{ref:e.unref(_),"as-child":b.asChild,as:b.as},{default:e.withCtx(()=>[e.renderSlot(b.$slots,"default",{modelValue:e.unref(m)})]),_:3},8,["as-child","as"]))}}),[B0,YS]=Jt("AccordionItem"),ZS=e.defineComponent({__name:"AccordionItem",props:{disabled:{type:Boolean},value:{},asChild:{type:Boolean},as:{}},setup(n,{expose:r}){const o=n,l=fu(),s=e.computed(()=>l.isSingle.value?o.value===l.modelValue.value:Array.isArray(l.modelValue.value)&&l.modelValu