1import{bD as qe,aK as z,aG as l,aH as V,aU as q,aP as y,aO as g,aN as B,bt as $,bk as F,by as ae,bn as de,aS as P,bb as he,aY as te,bg as U,bu as Q,aX as ge,bE as at,ba as oe,bd as Oe,bF as ot,br as lt,bG as nt,bH as ze,bI as st,a$ as Se,bJ as it,aM as ee,b1 as $e,bv as He,bh as rt,bq as ut,b8 as We,b0 as je,a_ as Ce,bz as me,bA as ve,bw as Ee,bB as dt,bC as Me,b4 as ct,aZ as Re}from"./DVF5nq-Z.js";import{u as j,a as ue,c as we,r as Ue,b as ft,d as pt}from"./KlWhGmVl.js";import{P as N,c as be}from"./DThbKxkQ.js";import{P as ht,u as mt,h as vt,g as gt,a as bt,b as yt,c as _t,D as xt,d as Ct,T as wt,e as It}from"./BGfBJ9xf.js";import{b as ce,c as ye,d as ke,g as qt,e as Te,M as St,f as Et,a as Ve,u as Ge,P as Vt}from"./DKeiebv1.js";import{u as Ye,_ as Ot}from"./Bol_u4hj.js";import{V as Xe}from"./DLlesWt3.js";import{u as kt,C as Tt}from"./DGup7lwH.js";import{i as Bt}from"./BpEQLgb9.js";import{X as Ft}from"./BFxC_7P2.js";(function(){try{var s=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{};s.SENTRY_RELEASE={id:"cedec4e72c707051492cafe38cb06638eefaff72"}}catch{}})();try{(function(){var s=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},i=new s.Error().stack;i&&(s._sentryDebugIds=s._sentryDebugIds||{},s._sentryDebugIds[i]="d96e4a61-e3b9-43fc-9348-be2297cd7367",s._sentryDebugIdIdentifier="sentry-dbid-d96e4a61-e3b9-43fc-9348-be2297cd7367")})()}catch{}function Ie(s,i,e){const t=s.findIndex(n=>qe(n,i)),a=s.findIndex(n=>qe(n,e));if(t===-1||a===-1)return[];const[o,r]=[t,a].sort((n,u)=>n-u);return s.slice(o,r+1)}function Qe(s){const i=z(()=>l(s)),e=z(()=>new Intl.Collator("en",{usage:"search",...i.value}));return{startsWith:(r,n)=>n.length===0?!0:(r=r.normalize("NFC"),n=n.normalize("NFC"),e.value.compare(r.slice(0,n.length),n)===0),endsWith:(r,n)=>n.length===0?!0:(r=r.normalize("NFC"),n=n.normalize("NFC"),e.value.compare(r.slice(-n.length),n)===0),contains:(r,n)=>{if(n.length===0)return!0;r=r.normalize("NFC"),n=n.normalize("NFC");let u=0;const m=n.length;for(;u+m<=r.length;u++){const f=r.slice(u,u+m);if(e.value.compare(n,f)===0)return!0}return!1}}}function At(){return{ALT:"Alt",ARROW_DOWN:"ArrowDown",ARROW_LEFT:"ArrowLeft",ARROW_RIGHT:"ArrowRight",ARROW_UP:"ArrowUp",BACKSPACE:"Backspace",CAPS_LOCK:"CapsLock",CONTROL:"Control",DELETE:"Delete",END:"End",ENTER:"Enter",ESCAPE:"Escape",F1:"F1",F10:"F10",F11:"F11",F12:"F12",F2:"F2",F3:"F3",F4:"F4",F5:"F5",F6:"F6",F7:"F7",F8:"F8",F9:"F9",HOME:"Home",META:"Meta",PAGE_DOWN:"PageDown",PAGE_UP:"PageUp",SHIFT:"Shift",SPACE:" ",TAB:"Tab",CTRL:"Control",ASTERISK:"*",SPACE_CODE:"Space"}}var zt=V({__name:"ComboboxAnchor",props:{reference:{type:null,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1}},setup(s){const{forwardRef:i}=j();return(e,t)=>(y(),q(l(ht),{"as-child":"",reference:e.reference},{default:g(()=>[B(l(N),$({ref:l(i),"as-child":e.asChild,as:e.as},e.$attrs),{default:g(()=>[F(e.$slots,"default")]),_:3},16,["as-child","as"])]),_:3},8,["reference"]))}}),Mt=zt;function De(s){return s?.querySelector("[data-state=checked]")}function Rt(s,i,e){return s===void 0?!1:Array.isArray(s)?s.some(t=>Z(t,i,e)):Z(s,i,e)}function Z(s,i,e){return s===void 0||i===void 0?!1:typeof s=="string"?s===i:typeof e=="function"?e(s,i):typeof e=="string"?s?.[e]===i?.[e]:qe(s,i)}const[_e,Dt]=ae("ListboxRoot");var Pt=V({__name:"ListboxRoot",props:{modelValue:{type:null,required:!1},defaultValue:{type:null,required:!1},multiple:{type:Boolean,required:!1},orientation:{type:String,required:!1,default:"vertical"},dir:{type:String,required:!1},disabled:{type:Boolean,required:!1},selectionBehavior:{type:String,required:!1,default:"toggle"},highlightOnHover:{type:Boolean,required:!1},by:{type:[String,Function],required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1},name:{type:String,required:!1},required:{type:Boolean,required:!1}},emits:["update:modelValue","highlight","entryFocus","leave"],setup(s,{expose:i,emit:e}){const t=s,a=e,{multiple:o,highlightOnHover:r,orientation:n,disabled:u,selectionBehavior:m,dir:f}=de(t),{getItems:b}=ce({isProvider:!0}),{handleTypeaheadSearch:p}=mt(),{primitiveElement:c,currentElement:d}=ye(),v=At(),w=ke(f),S=Ye(d),k=P(),H=P(!1),E=P(!0),I=ue(t,"modelValue",a,{defaultValue:t.defaultValue??(o.value?[]:void 0),passive:t.modelValue===void 0,deep:!0});function ne(h){if(H.value=!0,t.multiple){const _=Array.isArray(I.value)?[...I.value]:[],C=_.f
1indIndex(D=>Z(D,h,t.by));t.selectionBehavior==="toggle"?(C===-1?_.push(h):_.splice(C,1),I.value=_):(I.value=[h],k.value=h)}else t.selectionBehavior==="toggle"&&Z(I.value,h,t.by)?I.value=void 0:I.value=h;setTimeout(()=>{H.value=!1},1)}const A=P(null),x=P(null),O=P(!1),M=P(!1),L=we(),T=we(),W=we();function G(){return b().map(h=>h.ref).filter(h=>h.dataset.disabled!=="")}function K(h,_=!0){if(!h)return;A.value=h,E.value&&A.value.focus(),_&&A.value.scrollIntoView({block:"nearest"});const C=b().find(D=>D.ref===h);a("highlight",C)}function R(h){if(O.value)W.trigger(h);else{const _=b().find(C=>Z(C.value,h,t.by));_&&(A.value=_.ref,K(_.ref))}}function Y(h){A.value&&A.value.isConnected&&(h.preventDefault(),h.stopPropagation(),M.value||A.value.click())}function X(h){if(E.value){if(H.value=!0,O.value)T.trigger(h);else{const _=h.altKey||h.ctrlKey||h.metaKey;if(_&&h.key==="a"&&o.value){const C=b(),D=C.map(ie=>ie.value);I.value=[...D],h.preventDefault(),K(C[C.length-1].ref)}else if(!_){const C=p(h.key,b());C&&K(C)}}setTimeout(()=>{H.value=!1},1)}}function xe(){M.value=!0}function fe(){U(()=>{M.value=!1})}function se(){U(()=>{const h=new KeyboardEvent("keydown",{key:"PageUp"});Fe(h)})}function J(h){const _=A.value;_?.isConnected&&(x.value=_),A.value=null,a("leave",h)}function Ze(h){const _=new CustomEvent("listbox.entryFocus",{bubbles:!1,cancelable:!0});if(h.currentTarget?.dispatchEvent(_),a("entryFocus",_),!_.defaultPrevented)if(x.value)K(x.value);else{const C=G()?.[0];K(C)}}function Fe(h){const _=qt(h,n.value,w.value);if(!_)return;let C=G();if(A.value){if(_==="last")C.reverse();else if(_==="prev"||_==="next"){_==="prev"&&C.reverse();const D=C.indexOf(A.value);C=C.slice(D+1)}et(h,C[0])}if(C.length){const D=!A.value&&_==="prev"?C.length-1:0;K(C[D])}if(O.value)return T.trigger(h)}function et(h,_){if(!(O.value||t.selectionBehavior!=="replace"||!o.value||!Array.isArray(I.value)||(h.altKey||h.ctrlKey||h.metaKey)&&!h.shiftKey)&&h.shiftKey){const D=b().filter(pe=>pe.ref.dataset.disabled!=="");let ie=D.find(pe=>pe.ref===_)?.value;if(h.key===v.END?ie=D[D.length-1].value:h.key===v.HOME&&(ie=D[0].value),!ie||!k.value)return;const tt=Ie(D.map(pe=>pe.value),k.value,ie);I.value=tt}}async function Ae(h){if(await U(),O.value)L.trigger(h);else{const _=G(),C=_.find(D=>D.dataset.state==="checked");C?K(C):_.length&&K(_[0])}}return he(I,()=>{H.value||U(()=>{Ae()})},{immediate:!0,deep:!0}),i({highlightedElement:A,highlightItem:R,highlightFirstItem:se,highlightSelected:Ae,getItems:b}),Dt({modelValue:I,onValueChange:ne,multiple:o,orientation:n,dir:w,disabled:u,highlightOnHover:r,highlightedElement:A,isVirtual:O,virtualFocusHook:L,virtualKeydownHook:T,virtualHighlightHook:W,by:t.by,firstValue:k,selectionBehavior:m,focusable:E,onLeave:J,onEnter:Ze,changeHighlight:K,onKeydownEnter:Y,onKeydownNavigation:Fe,onKeydownTypeAhead:X,onCompositionStart:xe,onCompositionEnd:fe,highlightFirstItem:se}),(h,_)=>(y(),q(l(N),{ref_key:"primitiveElement",ref:c,as:h.as,"as-child":h.asChild,dir:l(w),"data-disabled":l(u)?"":void 0,onPointerleave:J,onFocusout:_[0]||(_[0]=async C=>{const D=C.relatedTarget||C.target;await U(),A.value&&l(d)&&!l(d).contains(D)&&J(C)})},{default:g(()=>[F(h.$slots,"default",{modelValue:l(I)}),l(S)&&h.name?(y(),q(l(Xe),{key:0,name:h.name,value:l(I),disabled:l(u),required:h.required},null,8,["name","value","disabled","required"])):te("v-if",!0)]),_:3},8,["as","as-child","dir","data-disabled"]))}}),Lt=Pt,Kt=V({__name:"ListboxContent",props:{asChild:{type:Boolean,required:!1},as:{type:null,required:!1}},setup(s){const{CollectionSlot:i}=ce(),e=_e(),t=Ue(!1,10);return(a,o)=>(y(),q(l(i),null,{default:g(()=>[B(l(N),{role:"listbox",as:a.as,"as-child":a.asChild,tabindex:l(e).focusable.value?l(e).highlightedElement.value?"-1":"0":"-1","aria-orientation":l(e).orientation.value,"aria-multiselectable":!!l(e).multiple.value,"data-orientation":l(e).orientation.value,onMousedown:o[0]||(o[0]=ge(r=>t.value=!0,["left"])),onFocus:o[1]||(o[1]=r=>{l(t)||l(e).onEnter(r)}),onKeydown:[o[2]||(o[2]=Q(r=>{l(e).orientation.value==="vertical"&&(r.key==="ArrowLeft"||r.key==="ArrowRight")||l(e).orientation.value==="horizontal"&&(r.key==="ArrowUp"||r.ke
1y==="ArrowDown")||(r.preventDefault(),l(e).focusable.value&&l(e).onKeydownNavigation(r))},["down","up","left","right","home","end"])),Q(l(e).onKeydownEnter,["enter"]),l(e).onKeydownTypeAhead]},{default:g(()=>[F(a.$slots,"default")]),_:3},8,["as","as-child","tabindex","aria-orientation","aria-multiselectable","data-orientation","onKeydown"])]),_:3}))}}),Nt=Kt,$t=V({__name:"ListboxFilter",props:{modelValue:{type:String,required:!1},autoFocus:{type:Boolean,required:!1},disabled:{type:Boolean,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1,default:"input"}},emits:["update:modelValue"],setup(s,{emit:i}){const e=s,a=ue(e,"modelValue",i,{defaultValue:"",passive:e.modelValue===void 0}),o=_e(),{primitiveElement:r,currentElement:n}=ye(),u=z(()=>e.disabled||o.disabled.value||!1),m=P();return at(()=>m.value=o.highlightedElement.value?.id),oe(()=>{o.focusable.value=!1,setTimeout(()=>{e.autoFocus&&n.value?.focus()},1)}),Oe(()=>{o.focusable.value=!0}),(f,b)=>(y(),q(l(N),{ref_key:"primitiveElement",ref:r,as:f.as,"as-child":f.asChild,value:l(a),disabled:u.value?"":void 0,"data-disabled":u.value?"":void 0,"aria-disabled":u.value??void 0,"aria-activedescendant":m.value,type:"text",onKeydown:[Q(ge(l(o).onKeydownNavigation,["prevent"]),["down","up","home","end"]),Q(l(o).onKeydownEnter,["enter"])],onInput:b[0]||(b[0]=p=>{a.value=p.target.value,l(o).highlightFirstItem()}),onCompositionstart:l(o).onCompositionStart,onCompositionend:l(o).onCompositionEnd},{default:g(()=>[F(f.$slots,"default",{modelValue:l(a)})]),_:3},8,["as","as-child","value","disabled","data-disabled","aria-disabled","aria-activedescendant","onKeydown","onCompositionstart","onCompositionend"]))}}),Ht=$t;const Wt="listbox.select",[jt,Ut]=ae("ListboxItem");var Gt=V({__name:"ListboxItem",props:{value:{type:null,required:!0},disabled:{type:Boolean,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1,default:"div"}},emits:["select"],setup(s,{emit:i}){const e=s,t=i,a=Te(void 0,"reka-listbox-item"),{CollectionItem:o}=ce(),{forwardRef:r,currentElement:n}=j(),u=_e(),m=z(()=>n.value===u.highlightedElement.value),f=z(()=>Rt(u.modelValue.value,e.value,u.by)),b=z(()=>u.disabled.value||e.disabled);async function p(d){t("select",d),!d?.defaultPrevented&&!b.value&&d&&(u.onValueChange(e.value),u.changeHighlight(n.value))}function c(d){const v={originalEvent:d,value:e.value};vt(Wt,p,v)}return Ut({isSelected:f}),(d,v)=>(y(),q(l(o),{value:d.value},{default:g(()=>[ot([m.value,f.value],()=>B(l(N),$({id:l(a)},d.$attrs,{ref:l(r),role:"option",tabindex:l(u).focusable.value?m.value?"0":"-1":-1,"aria-selected":f.value,as:d.as,"as-child":d.asChild,disabled:b.value?"":void 0,"data-disabled":b.value?"":void 0,"data-highlighted":m.value?"":void 0,"data-state":f.value?"checked":"unchecked",onClick:c,onKeydown:Q(ge(c,["prevent"]),["space"]),onPointermove:v[0]||(v[0]=()=>{l(u).highlightedElement.value!==l(n)&&l(u).highlightOnHover.value&&!l(u).focusable.value&&l(u).changeHighlight(l(n),!1)})}),{default:g(()=>[F(d.$slots,"default")]),_:3},16,["id","tabindex","aria-selected","as","as-child","disabled","data-disabled","data-highlighted","data-state","onKeydown"]),v,1)]),_:3},8,["value"]))}}),Yt=Gt,Xt=V({__name:"ListboxItemIndicator",props:{asChild:{type:Boolean,required:!1},as:{type:null,required:!1,default:"span"}},setup(s){const i=s;j();const e=jt();return(t,a)=>l(e).isSelected.value?(y(),q(l(N),$({key:0,"aria-hidden":"true"},i),{default:g(()=>[F(t.$slots,"default")]),_:3},16)):te("v-if",!0)}}),Qt=Xt;function re(s,i,e){let t=e.initialDeps??[],a;function o(){var r,n,u,m;let f;e.key&&((r=e.debug)!=null&&r.call(e))&&(f=Date.now());const b=s();if(!(b.length!==t.length||b.some((d,v)=>t[v]!==d)))return a;t=b;let c;if(e.key&&((n=e.debug)!=null&&n.call(e))&&(c=Date.now()),a=i(...b),e.key&&((u=e.debug)!=null&&u.call(e))){const d=Math.round((Date.now()-f)*100)/100,v=Math.round((Date.now()-c)*100)/100,w=v/16,S=(k,H)=>{for(k=String(k);k.length<H;)k=" "+k;return k};console.info(`%câ± ${S(v,5)} /${S(d,5)} ms`,` 2 font-size: .6rem; 3 font-weight: bold; 4 color: hsl(${Math.max(0,Math.min(120-120*w,120))}deg 100% 31%);`,e?.key)}return(m=e?.onChange)==null||m.call(e,a),a}return o.updateDeps=r=>{t=r},o}function Pe(s,i){if(s===void 0)throw new Error("Unexpected undefined");return s}const Jt=(s,i)=>Math.abs(s-i)<1.01,Zt=(s,i,e)=>{let t;return function(...a){s.clearTimeout(t),t=s.setTimeout(()=>i.apply(this,a),e)}},Le=s=>{const{offsetWidth:i,offsetHeight:e}=s;return{width:i,height:e}},ea=s=>s,ta=s=>{const i=Math.max(s.startIndex-s.overscan,0),e=Math.min(s.endIndex+s.overscan,s.c
vendor: 4,134 bytes, line 4
4ount-1),t=[];for(let a=i;a<=e;a++)t.push(a);return t},aa=(s,i)=>{const e=s.scrollElement;if(!e)return;const t=s.targetWindow;if(!t)return;const a=r=>{const{width:n,height:u}=r;i({width:Math.round(n),height:Math.round(u)})};if(a(Le(e)),!t.ResizeObserver)return()=>{};const o=new t.ResizeObserver(r=>{const n=()=>{const u=r[0];if(u?.borderBoxSize){const m=u.borderBoxSize[0];if(m){a({width:m.inlineSize,height:m.blockSize});return}}a(Le(e))};s.options.useAnimationFrameWithResizeObserver?requestAnimationFrame(n):n()});return o.observe(e,{box:"border-box"}),()=>{o.unobserve(e)}},Ke={passive:!0},Ne=typeof window>"u"?!0:"onscrollend"in window,oa=(s,i)=>{const e=s.scrollElement;if(!e)return;const t=s.targetWindow;if(!t)return;let a=0;const o=s.options.useScrollendEvent&&Ne?()=>{}:Zt(t,()=>{i(a,!1)},s.options.isScrollingResetDelay),r=f=>()=>{const{horizontal:b,isRtl:p}=s.options;a=b?e.scrollLeft*(p&&-1||1):e.scrollTop,o(),i(a,f)},n=r(!0),u=r(!1);u(),e.addEventListener("scroll",n,Ke);const m=s.options.useScrollendEvent&&Ne;return m&&e.addEventListener("scrollend",u,Ke),()=>{e.removeEventListener("scroll",n),m&&e.removeEventListener("scrollend",u)}},la=(s,i,e)=>{if(i?.borderBoxSize){const t=i.borderBoxSize[0];if(t)return Math.round(t[e.options.horizontal?"inlineSize":"blockSize"])}return s[e.options.horizontal?"offsetWidth":"offsetHeight"]},na=(s,{adjustments:i=0,behavior:e},t)=>{var a,o;const r=s+i;(o=(a=t.scrollElement)==null?void 0:a.scrollTo)==null||o.call(a,{[t.options.horizontal?"left":"top"]:r,behavior:e})};class sa{constructor(i){this.unsubs=[],this.scrollElement=null,this.targetWindow=null,this.isScrolling=!1,this.measurementsCache=[],this.itemSizeCache=new Map,this.pendingMeasuredCacheIndexes=[],this.scrollRect=null,this.scrollOffset=null,this.scrollDirection=null,this.scrollAdjustments=0,this.elementsCache=new Map,this.observer=(()=>{let e=null;const t=()=>e||(!this.targetWindow||!this.targetWindow.ResizeObserver?null:e=new this.targetWindow.ResizeObserver(a=>{a.forEach(o=>{const r=()=>{this._measureElement(o.target,o)};this.options.useAnimationFrameWithResizeObserver?requestAnimationFrame(r):r()})}));return{disconnect:()=>{var a;(a=t())==null||a.disconnect(),e=null},observe:a=>{var o;return(o=t())==null?void 0:o.observe(a,{box:"border-box"})},unobserve:a=>{var o;return(o=t())==null?void 0:o.unobserve(a)}}})(),this.range=null,this.setOptions=e=>{Object.entries(e).forEach(([t,a])=>{typeof a>"u"&&delete e[t]}),this.options={debug:!1,initialOffset:0,overscan:1,paddingStart:0,paddingEnd:0,scrollPaddingStart:0,scrollPaddingEnd:0,horizontal:!1,getItemKey:ea,rangeExtractor:ta,onChange:()=>{},measureElement:la,initialRect:{width:0,height:0},scrollMargin:0,gap:0,indexAttribute:"data-index",initialMeasurementsCache:[],lanes:1,isScrollingResetDelay:150,enabled:!0,isRtl:!1,useScrollendEvent:!1,useAnimationFrameWithResizeObserver:!1,...e}},this.notify=e=>{var t,a;(a=(t=this.options).onChange)==null||a.call(t,this,e)},this.maybeNotify=re(()=>(this.calculateRange(),[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]),e=>{this.notify(e)},{key:!1,debug:()=>this.options.debug,initialDeps:[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]}),this.cleanup=()=>{this.unsubs.filter(Boolean).forEach(e=>e()),this.unsubs=[],this.observer.disconnect(),this.scrollElement=null,this.targetWindow=null},this._didMount=()=>()=>{this.cleanup()},this._willUpdate=()=>{var e;const t=this.options.enabled?this.options.getScrollElement():null;if(this.scrollElement!==t){if(this.cleanup(),!t){this.maybeNotify();return}this.scrollElement=t,this.scrollElement&&"ownerDocument"in this.scrollElement?this.targetWindow=this.scrollElement.ownerDocument.defaultView:this.targetWindow=((e=this.scrollElement)==null?void 0:e.window)??null,this.elementsCache.forEach(a=>{this.observer.observe(a)}),this._scrollToOffset(this.getScrollOffset(),{adjustments:void 0,behavior:void 0}),this.unsubs.push(this.options.observeElementRect(this,a=>{this.scrollRect=a,this.maybeNotify()})),this.unsubs.push(this.options.observeElementOffset(this,(a,o)=>
vendor: 3,997 bytes, line 4
4{this.scrollAdjustments=0,this.scrollDirection=o?this.getScrollOffset()<a?"forward":"backward":null,this.scrollOffset=a,this.isScrolling=o,this.maybeNotify()}))}},this.getSize=()=>this.options.enabled?(this.scrollRect=this.scrollRect??this.options.initialRect,this.scrollRect[this.options.horizontal?"width":"height"]):(this.scrollRect=null,0),this.getScrollOffset=()=>this.options.enabled?(this.scrollOffset=this.scrollOffset??(typeof this.options.initialOffset=="function"?this.options.initialOffset():this.options.initialOffset),this.scrollOffset):(this.scrollOffset=null,0),this.getFurthestMeasurement=(e,t)=>{const a=new Map,o=new Map;for(let r=t-1;r>=0;r--){const n=e[r];if(a.has(n.lane))continue;const u=o.get(n.lane);if(u==null||n.end>u.end?o.set(n.lane,n):n.end<u.end&&a.set(n.lane,!0),a.size===this.options.lanes)break}return o.size===this.options.lanes?Array.from(o.values()).sort((r,n)=>r.end===n.end?r.index-n.index:r.end-n.end)[0]:void 0},this.getMeasurementOptions=re(()=>[this.options.count,this.options.paddingStart,this.options.scrollMargin,this.options.getItemKey,this.options.enabled],(e,t,a,o,r)=>(this.pendingMeasuredCacheIndexes=[],{count:e,paddingStart:t,scrollMargin:a,getItemKey:o,enabled:r}),{key:!1}),this.getMeasurements=re(()=>[this.getMeasurementOptions(),this.itemSizeCache],({count:e,paddingStart:t,scrollMargin:a,getItemKey:o,enabled:r},n)=>{if(!r)return this.measurementsCache=[],this.itemSizeCache.clear(),[];this.measurementsCache.length===0&&(this.measurementsCache=this.options.initialMeasurementsCache,this.measurementsCache.forEach(f=>{this.itemSizeCache.set(f.key,f.size)}));const u=this.pendingMeasuredCacheIndexes.length>0?Math.min(...this.pendingMeasuredCacheIndexes):0;this.pendingMeasuredCacheIndexes=[];const m=this.measurementsCache.slice(0,u);for(let f=u;f<e;f++){const b=o(f),p=this.options.lanes===1?m[f-1]:this.getFurthestMeasurement(m,f),c=p?p.end+this.options.gap:t+a,d=n.get(b),v=typeof d=="number"?d:this.options.estimateSize(f),w=c+v,S=p?p.lane:f%this.options.lanes;m[f]={index:f,start:c,size:v,end:w,key:b,lane:S}}return this.measurementsCache=m,m},{key:!1,debug:()=>this.options.debug}),this.calculateRange=re(()=>[this.getMeasurements(),this.getSize(),this.getScrollOffset(),this.options.lanes],(e,t,a,o)=>this.range=e.length>0&&t>0?ia({measurements:e,outerSize:t,scrollOffset:a,lanes:o}):null,{key:!1,debug:()=>this.options.debug}),this.getVirtualIndexes=re(()=>{let e=null,t=null;const a=this.calculateRange();return a&&(e=a.startIndex,t=a.endIndex),this.maybeNotify.updateDeps([this.isScrolling,e,t]),[this.options.rangeExtractor,this.options.overscan,this.options.count,e,t]},(e,t,a,o,r)=>o===null||r===null?[]:e({startIndex:o,endIndex:r,overscan:t,count:a}),{key:!1,debug:()=>this.options.debug}),this.indexFromElement=e=>{const t=this.options.indexAttribute,a=e.getAttribute(t);return a?parseInt(a,10):(console.warn(`Missing attribute name '${t}={index}' on measured element.`),-1)},this._measureElement=(e,t)=>{const a=this.indexFromElement(e),o=this.measurementsCache[a];if(!o)return;const r=o.key,n=this.elementsCache.get(r);n!==e&&(n&&this.observer.unobserve(n),this.observer.observe(e),this.elementsCache.set(r,e)),e.isConnected&&this.resizeItem(a,this.options.measureElement(e,t,this))},this.resizeItem=(e,t)=>{const a=this.measurementsCache[e];if(!a)return;const o=this.itemSizeCache.get(a.key)??a.size,r=t-o;r!==0&&((this.shouldAdjustScrollPositionOnItemSizeChange!==void 0?this.shouldAdjustScrollPositionOnItemSizeChange(a,r,this):a.start<this.getScrollOffset()+this.scrollAdjustments)&&this._scrollToOffset(this.getScrollOffset(),{adjustments:this.scrollAdjustments+=r,behavior:void 0}),this.pendingMeasuredCacheIndexes.push(a.index),this.itemSizeCache=new Map(this.itemSizeCache.set(a.key,t)),this.notify(!1))},this.measureElement=e=>{if(!e){this.elementsCache.forEach((t,a)=>{t.isConnected||(this.observer.unobserve(t),this.elementsCache.delete(a))});return}this._measureElement(e,void 0)},this.getVirtualItems=re(()=>
4[this.getVirtualIndexes(),this.getMeasurements()],(e,t)=>{const a=[];for(let o=0,r=e.length;o<r;o++){const n=e[o],u=t[n];a.push(u)}return a},{key:!1,debug:()=>this.options.debug}),this.getVirtualItemForOffset=e=>{const t=this.getMeasurements();if(t.length!==0)return Pe(t[Je(0,t.length-1,a=>Pe(t[a]).start,e)])},this.getOffsetForAlignment=(e,t,a=0)=>{const o=this.getSize(),r=this.getScrollOffset();t==="auto"&&(t=e>=r+o?"end":"start"),t==="center"?e+=(a-o)/2:t==="end"&&(e-=o);const n=this.getTotalSize()+this.options.scrollMargin-o;return Math.max(Math.min(n,e),0)},this.getOffsetForIndex=(e,t="auto")=>{e=Math.max(0,Math.min(e,this.options.count-1));const a=this.measurementsCache[e];if(!a)return;const o=this.getSize(),r=this.getScrollOffset();if(t==="auto")if(a.end>=r+o-this.options.scrollPaddingEnd)t="end";else if(a.start<=r+this.options.scrollPaddingStart)t="start";else return[r,t];const n=t==="end"?a.end+this.options.scrollPaddingEnd:a.start-this.options.scrollPaddingStart;return[this.getOffsetForAlignment(n,t,a.size),t]},this.isDynamicMode=()=>this.elementsCache.size>0,this.scrollToOffset=(e,{align:t="start",behavior:a}={})=>{a==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),this._scrollToOffset(this.getOffsetForAlignment(e,t),{adjustments:void 0,behavior:a})},this.scrollToIndex=(e,{align:t="auto",behavior:a}={})=>{a==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),e=Math.max(0,Math.min(e,this.options.count-1));let o=0;const r=10,n=m=>{if(!this.targetWindow)return;const f=this.getOffsetForIndex(e,m);if(!f){console.warn("Failed to get offset for index:",e);return}const[b,p]=f;this._scrollToOffset(b,{adjustments:void 0,behavior:a}),this.targetWindow.requestAnimationFrame(()=>{const c=this.getScrollOffset(),d=this.getOffsetForIndex(e,p);if(!d){console.warn("Failed to get offset for index:",e);return}Jt(d[0],c)||u(p)})},u=m=>{this.targetWindow&&(o++,o<r?this.targetWindow.requestAnimationFrame(()=>n(m)):console.warn(`Failed to scroll to index ${e} after ${r} attempts.`))};n(t)},this.scrollBy=(e,{behavior:t}={})=>{t==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),this._scrollToOffset(this.getScrollOffset()+e,{adju
4stments:void 0,behavior:t})},this.getTotalSize=()=>{var e;const t=this.getMeasurements();let a;if(t.length===0)a=this.options.paddingStart;else if(this.options.lanes===1)a=((e=t[t.length-1])==null?void 0:e.end)??0;else{const o=Array(this.options.lanes).fill(null);let r=t.length-1;for(;r>=0&&o.some(n=>n===null);){const n=t[r];o[n.lane]===null&&(o[n.lane]=n.end),r--}a=Math.max(...o.filter(n=>n!==null))}return Math.max(a-this.options.scrollMargin+this.options.paddingEnd,0)},this._scrollToOffset=(e,{adjustments:t,behavior:a})=>{this.options.scrollToFn(e,{behavior:a,adjustments:t},this)},this.measure=()=>{this.itemSizeCache=new Map,this.notify(!1)},this.setOptions(i)}}const Je=(s,i,e,t)=>{for(;s<=i;){const a=(s+i)/2|0,o=e(a);if(o<t)s=a+1;else if(o>t)i=a-1;else return a}return s>0?s-1:0};function ia({measurements:s,outerSize:i,scrollOffset:e,lanes:t}){const a=s.length-1,o=u=>s[u].start;if(s.length<=t)return{startIndex:0,endIndex:a};let r=Je(0,a,o,e),n=r;if(t===1)for(;n<a&&s[n].end<e+i;)n++;else if(t>1){const u=Array(t).fill(0);for(;n<a&&u.some(f=>f<e+i);){const f=s[n];u[f.lane]=f.end,n++}const m=Array(t).fill(e+i);for(;r>=0&&m.some(f=>f>=e);){const f=s[r];m[f.lane]=f.start,r--}r=Math.max(0,r-r%t),n=Math.min(a,n+(t-1-n%t))}return{startIndex:r,endIndex:n}}function ra(s){const i=new sa(l(s)),e=lt(i),t=i._didMount();return he(()=>l(s).getScrollElement(),a=>{a&&i._willUpdate()},{immediate:!0}),he(()=>l(s),a=>{i.setOptions({...a,onChange:(o,r)=>{var n;ze(e),(n=a.onChange)==null||n.call(a,o,r)}}),i._willUpdate(),ze(e)},{immediate:!0}),nt(t),e}function ua(s){return ra(z(()=>({observeElementRect:aa,observeElementOffset:oa,scrollToFn:na,...l(s)})))}var da=V({__name:"ListboxVirtualizer",props:{options:{type:Array,required:!0},overscan:{type:Number,required:!1},estimateSize:{type:Number,required:!1},textContent:{type:Function,required:!1}},setup(s){const i=s,e=st(),t=_e(),a=ft(),{getItems:o}=ce();t.isVirtual.value=!0;const r=z(()=>{const p=a.value;if(p){const c=window.getComputedStyle(p);return{start:Number.parseFloat(c.paddingBlockStart||c.paddingTop),end:Number.parseFloat(c.paddingBlockEnd||c.paddingBottom)}}else return{start:0,end:0}}),n=ua({get scrollPaddingStart(){return r.value.start},get scrollPaddingEnd(){return r.value.end},get count(){return i.options.length},get horizontal(){return t.orientation.value==="horizontal"},estimateSize(){return i.estimateSize??28},getScrollElement(){return a.value},overscan:i.overscan??12}),u=z(()=>n.value.getVirtualItems().map(p=>{const c=e.default({option:i.options[p.index],virtualizer:n.value,virtualItem:p})[0],d=c.type===Se&&Array.isArray(c.children)?c.children[0]:c;return{item:p,is:it(d,{key:`${p.key}`,"data-index":p.index,"aria-setsize":i.options.length,"aria-posinset":p.index+1,style:{position:"absolute",top:0,left:0,transform:`translateY(${p.start}px)`,overflowAnchor:"none"}})}}));t.virtualFocusHook.on(p=>{const c=i.options.findIndex(d=>Array.isArray(t.modelValue.value)?Z(d,t.modelValue.value[0],t.by):Z(d,t.modelValue.value,t.by));c!==-1?(p?.preventDefault(),n.value.scrollToIndex(c,{align:"start"}),requestAnimationFrame(()=>{const d=De(a.value);d&&(t.changeHighlight(d),p&&d?.focus())})):t.highlightFirstItem()}),t.virtualHighlightHook.on(p=>{const c=i.options.findIndex(d=>Z(d,p,t.by));n.value.scrollToIndex(c,{align:"start"}),requestAnimationFrame(()=>{const d=De(a.value);d&&t.changeHighlight(d)})});const m=Ue("",1e3),f=z(()=>{const p=c=>i.textContent?i.textContent(c):c?.toString().toLowerCase();return i.options.map((c,d)=>({index:d,textContent:p(c)}))});function b(p,c){if(!t.firstValue?.value||!t.multiple.value||!Array.isArray(t.modelValue.value))return;const v=o().filter(S=>S.ref.dataset.disabled!=="").find(S=>S.ref===t.highlightedElement.value)?.value;if(!v)return;let w=null;switch(c){case"prev":case"next":{w=Ie(i.options,t.firstValue.value,v);break}case"first":{w=Ie(i.options,t.firstValue.value,i.options?.[0]);break}case"last":{w=Ie(i.options,t.firstValue.value,i.options?.[i.options.length-1]);break}}t.modelValue.value=w}return t.virtualKeydownHook.on(p=>{const c=p.altKey||p.ctrlKey||p.metaKey;if(p.key==="Tab"&&!c)return;let v=St[p.key];if(c&&p.key==="a"&&t.multiple.value?(p.preventDefault(),t.modelValue.value=[...i.options],v="last"):p.shift
4Key&&v&&b(p,v),["first","last"].includes(v)){p.preventDefault();const w=v==="first"?0:i.options.length-1;n.value.scrollToIndex(w),requestAnimationFrame(()=>{const S=o(),k=v==="first"?S[0]:S[S.length-1];k&&t.changeHighlight(k.ref)})}else if(!v&&!c){m.value+=p.key;const w=Number(Et()?.getAttribute("data-index")),S=f.value[w].textContent,k=f.value.map(I=>I.textContent??""),H=gt(k,m.value,S),E=f.value.find(I=>I.textContent===H);E&&(n.value.scrollToIndex(E.index,{align:"start"}),requestAnimationFrame(()=>{const I=a.value.querySelector(`[data-index="${E.index}"]`);I instanceof HTMLElement&&t.changeHighlight(I)}))}}),(p,c)=>(y(),ee("div",{"data-reka-virtualizer":"",style:rt({position:"relative",width:"100%",height:`${l(n).getTotalSize()}px`})},[(y(!0),ee(Se,null,$e(u.value,({is:d,item:v})=>(y(),q(He(d),{key:v.index}))),128))],4))}}),ca=da;const[le,fa]=ae("ComboboxRoot");var pa=V({__name:"ComboboxRoot",props:{open:{type:Boolean,required:!1,default:void 0},defaultOpen:{type:Boolean,required:!1},resetSearchTermOnBlur:{type:Boolean,required:!1,default:!0},resetSearchTermOnSelect:{type:Boolean,required:!1,default:!0},openOnFocus:{type:Boolean,required:!1,default:!1},openOnClick:{type:Boolean,required:!1,default:!1},ignoreFilter:{type:Boolean,required:!1},resetModelValueOnClear:{type:Boolean,required:!1,default:!1},modelValue:{type:null,required:!1},defaultValue:{type:null,required:!1},multiple:{type:Boolean,required:!1},dir:{type:String,required:!1},disabled:{type:Boolean,required:!1},highlightOnHover:{type:Boolean,required:!1,default:!0},by:{type:[String,Function],required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1},name:{type:String,required:!1},required:{type:Boolean,required:!1}},emits:["update:modelValue","highlight","update:open"],setup(s,{expose:i,emit:e}){const t=s,a=e,{primitiveElement:o,currentElement:r}=ye(),{multiple:n,disabled:u,ignoreFilter:m,resetSearchTermOnSelect:f,openOnFocus:b,openOnClick:p,dir:c,resetModelValueOnClear:d,highlightOnHover:v}=de(t),w=ke(c),S=ue(t,"modelValue",a,{defaultValue:t.defaultValue??(n.value?[]:void 0),passive:t.modelValue===void 0,deep:!0}),k=ue(t,"open",a,{defaultValue:t.defaultOpen,passive:t.open===void 0});async function H(R){k.value=R,W.value="",R?(await U(),o.value?.highlightSelected(),I.value=!0):I.value=!1,A.value?.focus(),setTimeout(()=>{!R&&t.resetSearchTermOnBlur&&E.trigger()},1)}const E=we(),I=P(!1),ne=P(!1),A=P(),x=P(),O=z(()=>o.value?.highlightedElement??void 0),M=P(new Map),L=P(new Map),{contains:T}=Qe({sensitivity:"base"}),W=P(""),G=z(R=>{if(!W.value||t.ignoreFilter||ne.value)return{count:M.value.size,items:R?.items??new Map,groups:R?.groups??new Set(L.value.keys())};let Y=0;const X=new Map,xe=new Set;for(const[fe,se]of M.value){const J=T(se,W.value);X.set(fe,J?1:0),J&&Y++}for(const[fe,se]of L.value)for(const J of se)if(X.get(J)>0){xe.add(fe);break}return{count:Y,items:X,groups:xe}}),K=ut();return oe(()=>{K?.exposed&&(K.exposed.highlightItem=o.value?.highlightItem,K.exposed.highlightFirstItem=o.value?.highlightFirstItem,K.exposed.highlightSelected=o.value?.highlightSelected)}),i({filtered:G,highlightedElement:O,highlightItem:o.value?.highlightItem,highlightFirstItem:o.value?.highlightFirstItem,highlightSelected:o.value?.highlightSelected}),fa({modelValue:S,multiple:n,disabled:u,open:k,onOpenChange:H,contentId:"",isUserInputted:I,isVirtual:ne,inputElement:A,highlightedElement:O,onInputElementChange:R=>A.value=R,triggerElement:x,onTriggerElementChange:R=>x.value=R,parentElement:r,resetSearchTermOnSelect:f,onResetSearchTerm:E.on,allItems:M,allGroups:L,filterSearch:W,filterState:G,ignoreFilter:m,openOnFocus:b,openOnClick:p,resetModelValueOnClear:d}),(R,Y)=>(y(),q(l(bt),null,{default:g(()=>[B(l(Lt),$({ref_key:"primitiveElement",ref:o},R.$attrs,{modelValue:l(S),"onUpdate:modelValue":Y[0]||(Y[0]=X=>We(S)?S.value=X:null),style:{pointerEvents:l(k)?"auto":void 0},as:R.as,"as-child":R.asChild,dir:l(w),multiple:l(n),name:R.name,required:R.required,disabled:l(u),"highlight-on-hover":l(v),by:t.by,onHighlight:Y[1]||(Y[1]=X=>a("highlight",X))}),{default:g(()=>[F(R.$slots,"default",{open:l(k),modelValue:l(S)})]),_:3},16,["modelValue","style","as","as-child","dir","multiple","name","required","disabled","highlight-on-hover","by"])]),_:3}))}}),ha=pa;const[fo,ma]=ae("ComboboxContent");var va=V({__name:"ComboboxContentImpl",props:{position:{type:String,required:!1,default:"inline"},bodyLock:{type:Boolean,required:!1},side:{type:null,required:!1},sideOffset:{type:Number,required:!1},sideFlip:{type:Boolean,required:!1},align:{type:null,required:!1},alignOffset:{type:Number,required:!1},alignFlip:{type:Boolean,required:!1},avoidCollisions:{type:Boolean,required:!1},collisionBoundary:{type:null,required:!1},collisionPadding:{type:[Number,Object],required:!1},arrowPadding:{type:Number,required:!1},sticky:{type:String,required:!1},hideWhenDetached:{type:Boolean,required:!1},positionStrategy:{type:String,required:!1},updatePositionStrategy:{type:String,required:!1},disableUpdateOnLayoutShift:{type:Boolean,required:!1},prioritizePosition:{type:Boolean,required:!1},reference:{type:null,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1},disableOutsidePointerEvents:{type:Boolean,required:!1}},emits:["escapeKeyDown","pointerDownOutside","focusOutside","interactOutside"],setup(s,{emit:i}){const e=s,t=i,{position:a}=de(e),o=le(),{forwardRef:r,currentElement:n}=j();yt(e.bodyLock),_t(o.parentElement);const u=z(()=>e.position==="popper"?e:{}),m=Ve(u.value),f={boxSizing:"border-box","--reka-combobox-content-transform-origin":"var(--reka-popper-transform-origin)","--reka-combobox-content-available-width":"var(--reka-popper-available-width)","--reka-combobox-content-available-height":"var(--reka-popper-available-height)","--reka-combobox-trigger-width":"var(--reka-popper-anchor-width)","--reka-combobox-trigger-height":"var(--reka-popper-anchor-height)"};ma({position:a});const b=P(!1);return oe(()=>{o.inputElement.value&&(b.value=n.value.contains(o.inputElement.value),b.value&&o.inputElement.value.focus())}),Oe(()=>{b.value&&o.triggerElement.value?.focus()}
4),(p,c)=>(y(),q(l(Nt),{"as-child":""},{default:g(()=>[B(l(xt),{"as-child":"","disable-outside-pointer-events":p.disableOutsidePointerEvents,onDismiss:c[0]||(c[0]=d=>l(o).onOpenChange(!1)),onFocusOutside:c[1]||(c[1]=d=>{l(o).parentElement.value?.contains(d.target)&&d.preventDefault(),t("focusOutside",d)}),onInteractOutside:c[2]||(c[2]=d=>t("interactOutside",d)),onEscapeKeyDown:c[3]||(c[3]=d=>t("escapeKeyDown",d)),onPointerDownOutside:c[4]||(c[4]=d=>{l(o).parentElement.value?.contains(d.target)&&d.preventDefault(),t("pointerDownOutside",d)})},{default:g(()=>[(y(),q(He(l(a)==="popper"?l(Ct):l(N)),$({...p.$attrs,...l(m)},{id:l(o).contentId,ref:l(r),"data-state":l(o).open.value?"open":"closed",style:{display:"flex",flexDirection:"column",outline:"none",...l(a)==="popper"?f:{}}}),{default:g(()=>[F(p.$slots,"default")]),_:3},16,["id","data-state","style"]))]),_:3},8,["disable-outside-pointer-events"])]),_:3}))}}),ga=va,ba=V({__name:"ComboboxContent",props:{forceMount:{type:Boolean,required:!1},position:{type:String,required:!1},bodyLock:{type:Boolean,required:!1},side:{type:null,required:!1},sideOffset:{type:Number,required:!1},sideFlip:{type:Boolean,required:!1},align:{type:null,required:!1},alignOffset:{type:Number,required:!1},alignFlip:{type:Boolean,required:!1},avoidCollisions:{type:Boolean,required:!1},collisionBoundary:{type:null,required:!1},collisionPadding:{type:[Number,Object],required:!1},arrowPadding:{type:Number,required:!1},sticky:{type:String,required:!1},hideWhenDetached:{type:Boolean,required:!1},positionStrategy:{type:String,required:!1},updatePositionStrategy:{type:String,required:!1},disableUpdateOnLayoutShift:{type:Boolean,required:!1},prioritizePosition:{type:Boolean,required:!1},reference:{type:null,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1},disableOutsidePointerEvents:{type:Boolean,required:!1}},emits:["escapeKeyDown","pointerDownOutside","focusOutside","interactOutside"],setup(s,{emit:i}){const a=Ge(s,i),{forwardRef:o}=j(),r=le();return r.contentId||=Te(void 0,"reka-combobox-content"),(n,u)=>(y(),q(l(Vt),{present:n.forceMount||l(r).open.value},{default:g(()=>[B(ga,$({...l(a),...n.$attrs},{ref:l(o)}),{default:g(()=>[F(n.$slots,"default")]),_:3},16)]),_:3},8,["present"]))}}),ya=ba;const[_a]=ae("ComboboxGroup");var xa=V({__name:"ComboboxInput",props:{displayValue:{type:Function,required:!1},modelValue:{type:String,required:!1},autoFocus:{type:Boolean,required:!1},disabled:{type:Boolean,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1,default:"input"}},emits:["update:modelValue"],setup(s,{emit:i}){const e=s,t=i,a=le(),o=_e(),{primitiveElement:r,currentElement:n}=ye(),u=ue(e,"modelValue",t,{passive:e.modelValue===void 0});oe(()=>{n.value&&a.onInputElementChange(n.value)});function m(d){a.open.value||a.onOpenChange(!0)}function f(d){const v=d.target;a.open.value?a.filterSearch.value=v.value:(a.onOpenChange(!0),U(()=>{v.value&&(a.filterSearch.value=v.value,o.highlightFirstItem())}))}function b(){a.openOnFocus.value&&!a.open.value&&a.onOpenChange(!0)}function p(){a.openOnClick.value&&!a.open.value&&a.onOpenChange(!0)}function c(){const d=a.modelValue.value;e.displayValue?u.value=e.displayValue(d):!a.multiple.value&&d&&!Array.isArray(d)&&typeof d!="object"?u.value=d.toString():u.value="",U(()=>{u.value=u.value})}return a.onResetSearchTerm(()=>{c()}),he(a.modelValue,async()=>{!a.isUserInputted.value&&a.resetSearchTermOnSelect.value&&c()},{immediate:!0,deep:!0}),he(a.filterState,()=>{!a.isVirtual.value&&!a.highlightedElement.value&&o.highlightFirstItem()}),(d,v)=>(y(),q(l(Ht),{ref_key:"primitiveElement",ref:r,modelValue:l(u),"onUpdate:modelValue":v[0]||(v[0]=w=>We(u)?u.value=w:null),as:d.as,"as-child":d.asChild,"auto-focus":d.autoFocus,disabled:d.disabled,"aria-expanded":l(a).open.value,"aria-controls":l(a).contentId,"aria-autocomplete":"list",role:"combobox",autocomplete:"off",onClick:p,onInput:f,onKeydown:Q(ge(m,["prevent"]),["down","up"]),onFocus:b},{default:g(()=>[F(d.$slots,"default")]),_:3},8,["modelValue","as","as-child","auto-focus","disabled","aria-expanded","aria-controls","onKeydown"]))}}),Ca=xa,wa=V({__name:"ComboboxItem",props:{textValue:{type:String,required:!1},value:{type:null,required:!0},disabled:{type:Boolean,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1}},emits:["select"],setup(s,{emit:i}){const e=s,t=i,a=Te(void 0,"reka-combobox-item"),o=le(),r=_a(null),{primitiveElement:n,currentElement:u}=ye();if(e.value==="")throw new Error("A <ComboboxItem /> must have a value prop that is not an empty string. This is because the Combobox value can be set to an empty string to clear the selection and show the placeholder.");const m=z(()=>{if(o.isVirtual.value||o.ignoreFilter.value||!o.filterSearch.value)return!0;{const f=o.filterState.value.items.get(a);return f===void 0?!0:f>0}});return oe(()=>{o.allItems.value.set(a,e.textValue||u.value.textContent||u.value.innerText);
4const f=r?.id;f&&(o.allGroups.value.has(f)?o.allGroups.value.get(f)?.add(a):o.allGroups.value.set(f,new Set([a])))}),Oe(()=>{o.allItems.value.delete(a)}),(f,b)=>m.value?(y(),q(l(Yt),$({key:0},e,{id:l(a),ref_key:"primitiveElement",ref:n,disabled:l(o).disabled.value||f.disabled,onSelect:b[0]||(b[0]=p=>{t("select",p),!p.defaultPrevented&&!l(o).multiple.value&&!f.disabled&&!l(o).disabled.value&&(p.preventDefault(),l(o).onOpenChange(!1),l(o).modelValue.value=e.value)})}),{default:g(()=>[F(f.$slots,"default",{},()=>[je(Ce(f.value),1)])]),_:3},16,["id","disabled"])):te("v-if",!0)}}),Ia=wa,qa=V({__name:"ComboboxItemIndicator",props:{asChild:{type:Boolean,required:!1},as:{type:null,required:!1,default:"span"}},setup(s){const i=s;return(e,t)=>(y(),q(l(Qt),me(ve(i)),{default:g(()=>[F(e.$slots,"default")]),_:3},16))}}),Sa=qa,Ea=V({__name:"ComboboxPortal",props:{to:{type:null,required:!1},disabled:{type:Boolean,required:!1},defer:{type:Boolean,required:!1},forceMount:{type:Boolean,required:!1}},setup(s){const i=s;return(e,t)=>(y(),q(l(wt),me(ve(i)),{default:g(()=>[F(e.$slots,"default")]),_:3},16))}}),Va=Ea,Oa=V({__name:"ComboboxTrigger",props:{disabled:{type:Boolean,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1,default:"button"}},setup(s){const i=s,{forwardRef:e,currentElement:t}=j(),a=le(),o=z(()=>i.disabled||a.disabled.value||!1);return oe(()=>{t.value&&a.onTriggerElementChange(t.value)}),(r,n)=>(y(),q(l(N),$(i,{ref:l(e),type:r.as==="button"?"button":void 0,tabindex:"-1","aria-label":"Show popup","aria-haspopup":"listbox","aria-expanded":l(a).open.value,"aria-controls":l(a).contentId,"data-state":l(a).open.value?"open":"closed",disabled:o.value,"data-disabled":o.value?"":void 0,"aria-disabled":o.value??void 0,onClick:n[0]||(n[0]=u=>l(a).onOpenChange(!l(a).open.value))}),{default:g(()=>[F(r.$slots,"default")]),_:3},16,["type","aria-expanded","aria-controls","data-state","disabled","data-disabled","aria-disabled"]))}}),ka=Oa,Ta=V({__name:"ComboboxViewport",props:{nonce:{type:String,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1}},setup(s){const i=s,{forwardRef:e}=j(),{nonce:t}=de(i),a=kt(t),o=le();return(r,n)=>(y(),ee(Se,null,[B(l(N),$({...r.$attrs,...i},{ref:l(e),"data-reka-combobox-viewport":"",role:"presentation",style:{position:"relative",flex:l(o).isVirtual.value?void 0:1,overflow:"auto"}}),{default:g(()=>[F(r.$slots,"default")]),_:3},16,["style"]),B(l(N),{as:"style",nonce:l(a)},{default:g(()=>n[0]||(n[0]=[je(" /* Hide scrollbars cross-browser and enable momentum scroll for touch devices */ [data-reka-combobox-viewport] { scrollbar-width:none; -ms-overflow-style: none; -webkit-overflow-scrolling: touch; } [data-reka-combobox-viewport]::-webkit-scrollbar { display: none; } ")])),_:1,__:[0]},8,["nonce"])],64))}}),Ba=Ta,Fa=V({__name:"ComboboxVirtualizer",props:{options:{type:Array,required:!0},overscan:{type:Number,required:!1},estimateSize:{type:Number,required:!1},textContent:{type:Function,required:!1}},setup(s){const i=s,e=le();return e.isVirtual.value=!0,(t,a)=>(y(),q(ca,me(ve(i)),{default:g(o=>[F(t.$slots,"default",me(ve(o)))]),_:3},16))}}),Aa=Fa;const[Be,za]=ae("TagsInputRoot");var Ma=V({__name:"TagsInputRoot",props:{modelValue:{type:[Array,null],required:!1},defaultValue:{type:Array,required:!1,default:()=>[]},addOnPaste:{type:Boolean,required:!1},addOnTab:{type:Boolean,required:!1},addOnBlur:{type:Boolean,required:!1},duplicate:{type:Boolean,required:!1},disabled:{type:Boolean,required:!1},delimiter:{type:null,required:!1,default:","},dir:{type:String,required:!1},max:{type:Number,required:!1,default:0},id:{type:String,required:!1},convertValue:{type:Function,required:!1},displayValue:{type:Function,required:!1,default:s=>s.toString()},asChild:{type:Boolean,required:!1},as:{type:null,required:!1},name:{type:String,required:!1},required:{type:Boolean,required:!1}},emits:["update:modelValue","invalid","addTag","removeTag"],setup(s,{emit:i}){const e=s,t=i,{addOnPaste:a,disabled:o,delimiter:r,max:n,id:u,dir:m,addOnBlur:f,addOnTab:b}=de(e),p=ke(m),c=ue(e,"modelValue",t,{defaultValue:e.defaultValue,passive:!0,deep:!0}),{forwardRef:d,currentElement:v}=j(),{focused:w}=pt(v),S=Ye(v),{getItems:k,CollectionSlot:H}=ce({isProvider:!0}),E=P(),I=P(!1),ne=z(()=>Array.isArray(c.value)?[...c.value]:[]);function A(x){if(x!==-1){const O=k().filter(M=>M.ref.dataset.disabled!=="");c.value=c.value.filter((M,L)=>L!==x),t("removeTag",O[x].value)}}return za({modelValue:c,onAddValue:x=>{const O=[...ne.value],M=O.length>0&&typeof O[0]=="object",L=O.length>0&&typeof e.defaultValue[0]=="object";if((M||L)&&typeof e.convertValue!="function")throw new Error("You must provide a `convertValue` function when using objects as values.");const T=e.convertValue?e.convertValue(x):x;if(O.length>=n.value&&n.value)return t("invalid",T),!1;if(e.duplicate)return c.value=[...O,T],t("addTag",T),!0;if(O.includes(T))I.value=!0;else return c.value=[...O,T],t("addTag",T),!0;return t("invalid",T),!1},onRemoveValue:A,onInputKeydown:x=>{const O=x.target,M=k().map(T=>T.ref).filter(T=>T.dataset.disabled!=="");if(!M.length)return;const L=M.at(-1);switch(x.key){case"Delete":case"Backspace":{if(O.selectionStart!==0||O.selectionEnd!==0)break;if(E.value){const T=M.findIndex(W=>W===E.value);A(T),E.value=E.value===L?M.at(T-1):M.at(T+1),x.preventDefault()}else x.key==="Backspace"&&(E.value=L,x.preventDefault());break}case"Home":case"End":case"ArrowRight":case"ArrowLeft":{const T=x.key==="ArrowRight"&&p.value==="ltr"||x.key==="ArrowLeft"&&p.value==="rtl",W=!T;if(O.selectionStart!==0||O.selectionEnd!==0)break;if(W&&!E.value)E.value=L,x.preventDefault();else if(T&&L&&E.value===L)E.value=void 0,x.preventDefault();else if(E.value){const G=It(x,E.value,void 0,{itemsArray:M,loop:!1,dir:p.value});G&&(E.value=G),x.preventDefault()}break}case"ArrowUp":case"ArrowDown":{E.value&&x.preventDefault();break}default:E.value=void 0}},selectedElement:E,isInvalidInput:I,addOnPaste:a,addOnBlur:f,addOnTab:b,dir:p,disabled:o,delimiter:r,max:n,id:u,displayValue:e.displayValue}),(x,O)=>(y(),q(l(H),null,{default:g(()=>[B(l(N),{ref:l(d),dir:l(p),as:x.as,"as-child":x.asChild,"data-invalid":I.value?"":void 0,"data-disabled":l(o)?"":void 0,"data-focused":l(w)?"":void 0},{default:g(()=>[F(x.$slots,"default",{modelValue:l(c)}),l(S)&&x.name?(y(),q(l(Xe),{key:0,name:x.name,value:l(c),required:x.required,disabled:l(o)},null,8,["name","value","required","disabled"])):te("v-if",!0)]),_:3},8,["dir","as","as-child","data-invalid","data-disabled","data-focused"])]),_:3}))}}),Ra=Ma,Da=V({__name:"TagsInputInput",props:{placeholder:{type:String,required:!1},autoFocus:{type:Boolean,required:!1},maxLength:{type:Number,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1,default:"input"}},setup(s){const i=s,e=Be(),{forwardRef:t,currentElement:a}=j();function o(c){if(e.selectedElement.value=void 0,!e.addOnBlur.value)return;const d=c.target;if(!d.value)return;e.onAddValue(d.value)&&(d.value="")}function r(c){e.addOnTab.value&&f(c)}const n=P(!1);function u(){n.value=!0}function m(){U(()=>{n.value=!1})}async function f(c){if(n.value||(await U(),c.defaultPrevented))return;const d=c.target;if(!d.value)return;e.onAddValue(d.value)&&(d.value=""),c.preventDefault()}function b(c){if(e.isInvalidInput.value=!1,c.data===null)return;const d=e.delimiter.value;if(d===c.data||d instanceof RegExp&&d.test(c.data)){const w=c.target;if(w.value=w.value.replace(d,""),w.value.trim()===""){w.value="";return}e.onAddValue(w.value)&&(w.value="")}}function p(c){if(e.addOnPaste.value){c.preventDefault();const d=c.clipboardData;if(!d)return;const v=d.getData("text");e.delimiter.value?v.split(e.delimiter.value).forEach(S=>{e.onAddValue(S)}):e.onAddValue(v)}}return oe(()=>{const c=a.value.nodeName==="INPUT"?a.value:a.value.querySelector("input");c&&setTimeout(()=>{i.autoFocus&&c?.focus()},1)}),(c,d)=>(y(),q(l(N),{id:l(e).id?.value,ref:l(t),type:"text",autocomplete:"off",autocorrect:"off",autocapitalize:"off",as:c.as,"as-child":c.asChild,maxlength:c.maxLength,placeholder:c.placeholder,disabled:l(e).disabled.value,"data-invalid":l(e).isInvalidInput.value?"":void 0,onInput:b,onKeydown:[Q(f,["enter"]),Q(r,["tab"]),l(e).onInputKeydown],onBlur:o,onCompositionstart:u,onCompositionend:m,onPaste:p},{default:g(()=>[F(c.$slots,"default")]),_:3},8,["id","as","as-child","maxlength","placeholder","disabled","data-invalid","onKeydown"]))}}),Pa=Da;const[La,Ka]=ae("TagsInputItem");var Na=V({__name:"TagsInputItem",props:{value:{type:null,required:!0},disabled:{type:Boolean,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1}},setup(s){const i=s,{value:e}=de(i),t=Be(),{forwardRef:a,currentElement:o}=j(),{CollectionItem:r}=ce(),n=z(()=>t.selectedElement.value===o.value),u=z(()=>i.disabled||t.disabled.value),m=Ka({value:e,isSelected:n,disabled:u,textId:"",displayValue:z(()=>t.displayValue(e.value))});return(f,b)=>(y(),q(l(r),{value:l(e)},{default:g(()=>[B(l(N),{ref:l(a),as:f.as,"as-child":f.asChild,"aria-labelledby":l(m).textId,"aria-current":n.value,"data-disabled":u.value?"":void 0,"data-state":n.value?"active":"inactive"},{default:g(()=>[F(f.$slots,"default")]),_:3},8,["as","as-child","aria-labelledby","aria-current","data-disabled","data-state"])]),_:3},8,["value"]))}}),$a=Na,Ha=V({__name:"TagsInputItemDelete",props:{asChild:{type:Boolean,required:!1},as:{type:null,required:!1,default:"button"}},setup(s){const i=s;j();const e=Be(),t=La(),a=z(()=>t.disabled?.value||e.disabled.value);function o(){if(a.value)return;const r=e.modelValue.value.findIndex(n=>qe(n,t.value.value));e.onRemoveValue(r)}return(r,n)=>(y(),q(l(N),$({tabindex:"-1"},i,{"aria-labelledby":l(t).textId,"aria-current":l(t).isSelected.value,"data-state":l(t).isSelected.value?"active":"inactive","data-disabled":a.value?"":void 0,type:r.as==="button"?"button":void 0,onClick:o}),{default:g(()=>[F(r.$slots,"default")]),_:3},16,["aria-labelledby","aria-current","data-state","data-disabled","type"]))}}),Wa=Ha;const ja=V({__name:"TagsInput",props:{modelValue:{},defaultValue:{},addOnPaste:{type:Boolean},addOnTab:{type:Boolean},addOnBlur:{type:Boolean},duplicate:{type:Boolean},disabled:{type:Boolean},delimiter:{},dir:{},max:{},id:{},convertValue:{},displayValue:{},asChild:{type:Boolean},as:{},name:{},required:{type:Boolean},class:{},withPattern:{type:Boolean,default:!1}}
4,emits:["update:modelValue","invalid","addTag","removeTag"],setup(s,{emit:i}){const e=s,t=i,a=Ee(e,"class"),o=Ge(a,t);return(r,n)=>(y(),q(l(Ra),$(l(o),{"data-slot":"tags-input",class:l(be)("flex flex-wrap gap-2 items-center rounded-md border border-input bg-background px-2 py-1 text-sm shadow-xs transition-[color,box-shadow] outline-none","focus-within:border-ring focus-within:ring-ring/50 focus-within:ring-[3px]","aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive","bg-no-repeat bg-right bg-contain",e.class),style:{backgroundImage:s.withPattern?`url(${l(Bt)})`:void 0}}),{default:g(u=>[F(r.$slots,"default",me(ve(u)))]),_:3},16,["class","style"]))}}),Ua=V({__name:"TagsInputInput",props:{placeholder:{},autoFocus:{type:Boolean},maxLength:{},asChild:{type:Boolean},as:{},class:{}},setup(s){const i=s,e=Ee(i,"class"),t=Ve(e);return(a,o)=>(y(),q(l(Pa),$(l(t),{class:l(be)("text-sm min-h-5 focus:outline-none flex-1 bg-transparent px-1 bg-no-repeat bg-right bg-contain",i.class)}),null,16,["class"]))}}),Ga=V({__name:"TagsInputItem",props:{value:{},disabled:{type:Boolean},asChild:{type:Boolean},as:{},class:{}},setup(s){const i=s,e=Ee(i,"class"),t=Ve(e);return(a,o)=>(y(),q(l($a),$(l(t),{class:l(be)("flex h-5 items-center rounded-md bg-secondary data-[state=active]:ring-ring data-[state=active]:ring-2 data-[state=active]:ring-offset-2 ring-offset-background",i.class)}),{default:g(()=>[F(a.$slots,"default")]),_:3},16,["class"]))}}),Ya=V({__name:"TagsInputItemDelete",props:{asChild:{type:Boolean},as:{},class:{}},setup(s){const i=s,e=Ee(i,"class"),t=Ve(e);return(a,o)=>(y(),q(l(Wa),$(l(t),{class:l(be)("flex rounded bg-transparent mr-1",i.class)}),{default:g(()=>[F(a.$slots,"default",{},()=>[B(l(Ft),{class:"w-4 h-4"})])]),_:3},16,["class"]))}}),Xa={class:"py-0.5 px-2 text-sm rounded bg-transparent"},Qa={key:0,class:"px-2 py-1.5 text-sm text-muted-foreground"},Ja=["src","alt"],Za={class:"truncate"},eo={key:1,class:"shrink-0 text-[10px] leading-none px-1.5 py-0.5 rounded bg-muted text-muted-foreground"},po=V({__name:"SearchableTagsInput",props:dt({options:{},placeholder:{},class:{},displayTags:{type:Boolean,default:!0},withPattern:{type:Boolean,default:!1},clearQueryOnSelect:{type:Boolean,default:!0},withSearch:{type:Boolean,default:!1}},{query:{default:""},queryModifiers:{},modelValue:{default:[]},modelModifiers:{}}),emits:["update:query","update:modelValue"],setup(s){const i=s,{contains:e}=Qe({sensitivity:"base"}),t=Me(s,"query"),a=Me(s,"modelValue"),o=z(()=>{const r={value:"search:"+t.value,label:t.value,icon:null,category:"Search"};if(t.value==="")return i.options;const n=i.options.filter(u=>e(u.label,t.value)||u.category&&e(u.category,t.value));return i.withSearch?[r,...n]:n});return(r,n)=>(y(),q(l(ha),{modelValue:a.value,"onUpdate:modelValue":n[4]||(n[4]=u=>a.value=u),multiple:"","ignore-filter":"","open-on-click":"",class:ct(l(be)("relative",i.class))},{default:g(()=>[B(l(Mt),null,{default:g(()=>[B(l(ja),{modelValue:a.value,"onUpdate:modelValue":n[2]||(n[2]=u=>a.value=u),delimiter:"","with-pattern":i.withPattern,class:"px-3 py-2 min-h-10.5 [&_svg:not([class*='text-'])]:text-muted-foreground"},{default:g(()=>[i.displayTags?(y(!0),ee(Se,{key:0},$e(a.value,u=>(y(),q(l(Ga),{key:u.toString(),value:u.toString()},{default:g(()=>[Re("span",Xa,Ce(i.options.find(m=>m.value===u)?.label??u),1),B(l(Ya))]),_:2},1032,["value"]))),128)):te("",!0),B(l(Ca),{modelValue:t.value,"onUpdate:modelValue":n[1]||(n[1]=u=>t.value=u),"as-child":""},{default:g(()=>[B(l(Ua),{placeholder:s.placeholder??"Search...",class:"focus:outline-none flex-1 bg-transparent px-0 placeholder:text-muted-foreground",onKeydown:n[0]||(n[0]=Q(ge(()=>{},["prevent"]),["enter"]))},null,8,["placeholder"])]),_:1},8,["modelValue"]),B(l(ka),{class:"group order-last self-center ml-auto shrink-0",tabindex:"-1"},{default:g(()=>[B(l(Tt),{class:"size-4 opacity-50 transition-transform duration-150 group-data-[state=open]:rotate-180"})]),_:1})]),_:1},8,["modelValue","with-pattern"])]),_:1}),B(l(Va),null,{default:g(()=>[B(l(ya),{position:"popper","body-lock":"","disable-outside-pointer-events":"",class:"z-50 w-[var(--reka-combobox-trigger-width)] bg-popover text-popover-foreground rounded-none border py-1 shadow-md overflow-hidden","side-offset":4},{default:g(()=>[B(l(Ba),{class:"max-h-[300px] scroll-py-1 px-1 overflow-x-hidden overflow-y-auto",style:{"scrollbar-width":"thin"}},{default:g(()=>[o.value.length?(y(),q(l(Aa),{key:1,options:o.value,"text-content":u=>u.label,"estimate-size":36},{default:g(({option:u})=>[B(l(Ia),{class:"w-full data-[highlighted]:bg-accent data-[highlighted]:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex cursor-pointer items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",value:u.value,onSelect:n[3]||(n[3]=()=>{i.clearQueryOnSelect&&(t.value="")}
4)},{default:g(()=>[u.icon?(y(),ee("img",{key:0,src:u.icon,alt:u.label,class:"size-6 object-contain rounded-sm"},null,8,Ja)):te("",!0),Re("span",Za,Ce(u.label),1),u.category?(y(),ee("span",eo,Ce(u.category),1)):te("",!0),B(l(Sa),{class:"ml-auto inline-flex items-center justify-center"},{default:g(()=>[B(Ot)]),_:1})]),_:2},1032,["value"])]),_:1},8,["options","text-content"])):(y(),ee("p",Qa," No results "))]),_:1})]),_:1})]),_:1})]),_:1},8,["modelValue","class"]))}});export{po as _};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.