Files
boc/landvex-site/assets/select-Dcsz1esX.js
T
Bernt 48ea61cdcc docs: add quixzoom-auth-core product to AAMOS
- Product documentation in docs/products/
- Updated MEMORY.md with product info
- quiXzoom Auth Core as AAMOS Identity product
2026-07-14 09:58:53 +00:00

8 lines
22 KiB
JavaScript

import{x as dt,j as r,r as o,O as V,av as z,P as j,e as ut,c as Me,at as Ie,aA as pt,aa as ft,bi as mt,aB as ht,d as b,aD as vt,au as gt,bj as Oe,aC as De,aE as xt,az as St,g as wt,aF as yt,aH as Ct,aI as It,aJ as Nt,aK as Tt,aM as Pt,aL as bt,bh as Ae,aN as Rt,i as G}from"./index-CZD3_4lD.js";import{C as Le}from"./chevron-down-DA--jGG2.js";import{C as _t}from"./check-CCL32zXH.js";/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/const Et=dt("ChevronUp",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]);var jt=[" ","Enter","ArrowUp","ArrowDown"],Mt=[" ","Enter"],te="Select",[pe,fe,At]=xt(te),[oe]=wt(te,[At,De]),me=De(),[Ot,Y]=oe(te),[Dt,Lt]=oe(te),kt="SelectProvider";function ke(t){const{__scopeSelect:n,children:e,open:s,defaultOpen:a,onOpenChange:f,value:c,defaultValue:i,onValueChange:l,dir:p,name:g,autoComplete:w,disabled:C,required:P,form:N,internal_do_not_use_render:d}=t,v=me(n),[S,u]=o.useState(null),[m,M]=o.useState(null),[R,X]=o.useState(!1),_=ut(p),[O,ne]=Me({prop:s,defaultProp:a??!1,onChange:f,caller:te}),[re,B]=Me({prop:c,defaultProp:i,onChange:l,caller:te}),H=o.useRef(null),Z=S?!!N||!!S.closest("form"):!0,[F,D]=o.useState(new Set),U=Ie(),W=Array.from(F).map(k=>k.props.value).join(";"),K=o.useCallback(k=>{D(J=>new Set(J).add(k))},[]),L=o.useCallback(k=>{D(J=>{const ae=new Set(J);return ae.delete(k),ae})},[]),se={required:P,trigger:S,onTriggerChange:u,valueNode:m,onValueNodeChange:M,valueNodeHasChildren:R,onValueNodeHasChildrenChange:X,contentId:U,value:re,onValueChange:B,open:O,onOpenChange:ne,dir:_,triggerPointerDownPosRef:H,disabled:C,name:g,autoComplete:w,form:N,nativeOptions:F,nativeSelectKey:W,isFormControl:Z};return r.jsx(pt,{...v,children:r.jsx(Ot,{scope:n,...se,children:r.jsx(pe.Provider,{scope:n,children:r.jsx(Dt,{scope:n,onNativeOptionAdd:K,onNativeOptionRemove:L,children:Jt(d)?d(se):e})})})})}ke.displayName=kt;var Ve=t=>{const{__scopeSelect:n,children:e,...s}=t;return r.jsx(ke,{__scopeSelect:n,...s,internal_do_not_use_render:({isFormControl:a})=>r.jsxs(r.Fragment,{children:[e,a?r.jsx(st,{__scopeSelect:n}):null]})})};Ve.displayName=te;var Be="SelectTrigger",Ne=o.forwardRef((t,n)=>{const{__scopeSelect:e,disabled:s=!1,...a}=t,f=me(e),c=Y(Be,e),i=c.disabled||s,l=V(n,c.onTriggerChange),p=fe(e),g=o.useRef("touch"),[w,C,P]=at(d=>{const v=p().filter(m=>!m.disabled),S=v.find(m=>m.value===c.value),u=lt(v,d,S);u!==void 0&&c.onValueChange(u.value)}),N=d=>{i||(c.onOpenChange(!0),P()),d&&(c.triggerPointerDownPosRef.current={x:Math.round(d.pageX),y:Math.round(d.pageY)})};return r.jsx(ht,{asChild:!0,...f,children:r.jsx(j.button,{type:"button",role:"combobox","aria-controls":c.open?c.contentId:void 0,"aria-expanded":c.open,"aria-required":c.required,"aria-autocomplete":"none",dir:c.dir,"data-state":c.open?"open":"closed",disabled:i,"data-disabled":i?"":void 0,"data-placeholder":he(c.value)?"":void 0,...a,ref:l,onClick:b(a.onClick,d=>{d.currentTarget.focus(),g.current!=="mouse"&&N(d)}),onPointerDown:b(a.onPointerDown,d=>{g.current=d.pointerType;const v=d.target;v.hasPointerCapture(d.pointerId)&&v.releasePointerCapture(d.pointerId),d.button===0&&d.ctrlKey===!1&&d.pointerType==="mouse"&&(N(d),d.preventDefault())}),onKeyDown:b(a.onKeyDown,d=>{const v=w.current!=="";!(d.ctrlKey||d.altKey||d.metaKey)&&d.key.length===1&&C(d.key),!(v&&d.key===" ")&&jt.includes(d.key)&&(N(),d.preventDefault())})})})});Ne.displayName=Be;var He="SelectValue",Fe=o.forwardRef((t,n)=>{const{__scopeSelect:e,className:s,style:a,children:f,placeholder:c="",...i}=t,l=Y(He,e),{onValueNodeHasChildrenChange:p}=l,g=f!==void 0,w=V(n,l.onValueNodeChange);z(()=>{p(g)},[p,g]);const C=he(l.value);return r.jsx(j.span,{...i,asChild:C?!1:i.asChild,ref:w,style:{pointerEvents:"none"},children:r.jsx(o.Fragment,{children:C?c:f},C?"placeholder":"value")})});Fe.displayName=He;var Vt="SelectIcon",Ue=o.forwardRef((t,n)=>{const{__scopeSelect:e,children:s,...a}=t;return r.jsx(j.span,{"aria-hidden":!0,...a,ref:n,children:s||"▼"})});Ue.displayName=Vt;var We="SelectPortal",[Bt,Ht]=oe(We,{forceMount:void 0}),Ke=t=>{const{__scopeSelect:n,forceMount:e,...s}=t;return r.jsx(Bt,{scope:t.__scopeSelect,forceMount:e,children:r.jsx(vt,{asChild:!0,...s})})};Ke.displayName=We;var $="SelectContent",Te=o.forwardRef((t,n)=>{const e=Ht($,t.__scopeSelect),{forceMount:s=e.forceMount,...a}=t,f=Y($,t.__scopeSelect),[c,i]=o.useState();return z(()=>{i(new DocumentFragment)},[]),r.jsx(gt,{present:s||f.open,children:({present:l})=>l?r.jsx($e,{...a,ref:n}):r.jsx(ze,{...a,fragment:c})})});Te.displayName=$;var ze=o.forwardRef((t,n)=>{const{__scopeSelect:e,children:s,fragment:a}=t;return a?Oe.createPortal(r.jsx(Ge,{scope:e,children:r.jsx(pe.Slot,{scope:e,children:r.jsx("div",{ref:n,children:s})})}),a):null});ze.displayName="SelectContentFragment";var A=10,[Ge,q]=oe($),Ft="SelectContentImpl",Ut=Pt("SelectContent.RemoveScroll"),$e=o.forwardRef((t,n)=>{const{__scopeSelect:e}=t,{position:s="item-aligned",onCloseAutoFocus:a,onEscapeKeyDown:f,onPointerDownOutside:c,side:i,sideOffset:l,align:p,alignOffset:g,arrowPadding:w,collisionBoundary:C,collisionPadding:P,sticky:N,hideWhenDetached:d,avoidCollisions:v,...S}=t,u=Y($,e),[m,M]=o.useState(null),[R,X]=o.useState(null),_=V(n,h=>M(h)),[O,ne]=o.useState(null),[re,B]=o.useState(null),H=fe(e),[Z,F]=o.useState(!1),D=o.useRef(!1);o.useEffect(()=>{if(m)return yt(m)},[m]),Ct();const U=o.useCallback(h=>{const[T,...E]=H().map(y=>y.ref.current),[I]=E.slice(-1),x=document.activeElement;for(const y of h)if(y===x||(y==null||y.scrollIntoView({block:"nearest"}),y===T&&R&&(R.scrollTop=0),y===I&&R&&(R.scrollTop=R.scrollHeight),y==null||y.focus(),document.activeElement!==x))return},[H,R]),W=o.useCallback(()=>U([O,m]),[U,O,m]);o.useEffect(()=>{Z&&W()},[Z,W]);const{onOpenChange:K,triggerPointerDownPosRef:L}=u;o.useEffect(()=>{if(m){let h={x:0,y:0};const T=I=>{var x,y;h={x:Math.abs(Math.round(I.pageX)-(((x=L.current)==null?void 0:x.x)??0)),y:Math.abs(Math.round(I.pageY)-(((y=L.current)==null?void 0:y.y)??0))}},E=I=>{h.x<=10&&h.y<=10?I.preventDefault():I.composedPath().includes(m)||K(!1),document.removeEventListener("pointermove",T),L.current=null};return L.current!==null&&(document.addEventListener("pointermove",T),document.addEventListener("pointerup",E,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",T),document.removeEventListener("pointerup",E,{capture:!0})}}},[m,K,L]),o.useEffect(()=>{const h=()=>K(!1);return window.addEventListener("blur",h),window.addEventListener("resize",h),()=>{window.removeEventListener("blur",h),window.removeEventListener("resize",h)}},[K]);const[se,k]=at(h=>{const T=H().filter(x=>!x.disabled),E=T.find(x=>x.ref.current===document.activeElement),I=lt(T,h,E);I&&setTimeout(()=>{var x;return(x=I.ref.current)==null?void 0:x.focus()})}),J=o.useCallback((h,T,E)=>{const I=!D.current&&!E;(u.value!==void 0&&u.value===T||I)&&(ne(h),I&&(D.current=!0))},[u.value]),ae=o.useCallback(()=>m==null?void 0:m.focus(),[m]),le=o.useCallback((h,T,E)=>{const I=!D.current&&!E;(u.value!==void 0&&u.value===T||I)&&B(h)},[u.value]),de=s==="popper"?Se:Ye,ce=de===Se?{side:i,sideOffset:l,align:p,alignOffset:g,arrowPadding:w,collisionBoundary:C,collisionPadding:P,sticky:N,hideWhenDetached:d,avoidCollisions:v}:{};return r.jsx(Ge,{scope:e,content:m,viewport:R,onViewportChange:X,itemRefCallback:J,selectedItem:O,onItemLeave:ae,itemTextRefCallback:le,focusSelectedItem:W,selectedItemText:re,position:s,isPositioned:Z,searchRef:se,children:r.jsx(It,{as:Ut,allowPinchZoom:!0,children:r.jsx(Nt,{asChild:!0,trapped:u.open,onMountAutoFocus:h=>{h.preventDefault()},onUnmountAutoFocus:b(a,h=>{var T;(T=u.trigger)==null||T.focus({preventScroll:!0}),h.preventDefault()}),children:r.jsx(Tt,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:f,onPointerDownOutside:c,onFocusOutside:h=>h.preventDefault(),onDismiss:()=>u.onOpenChange(!1),children:r.jsx(de,{role:"listbox",id:u.contentId,"data-state":u.open?"open":"closed",dir:u.dir,onContextMenu:h=>h.preventDefault(),...S,...ce,onPlaced:()=>F(!0),ref:_,style:{display:"flex",flexDirection:"column",outline:"none",...S.style},onKeyDown:b(S.onKeyDown,h=>{const T=h.ctrlKey||h.altKey||h.metaKey;if(h.key==="Tab"&&h.preventDefault(),!T&&h.key.length===1&&k(h.key),["ArrowUp","ArrowDown","Home","End"].includes(h.key)){let I=H().filter(x=>!x.disabled).map(x=>x.ref.current);if(["ArrowUp","End"].includes(h.key)&&(I=I.slice().reverse()),["ArrowUp","ArrowDown"].includes(h.key)){const x=h.target,y=I.indexOf(x);I=I.slice(y+1)}setTimeout(()=>U(I)),h.preventDefault()}})})})})})})});$e.displayName=Ft;var Wt="SelectItemAlignedPosition",Ye=o.forwardRef((t,n)=>{const{__scopeSelect:e,onPlaced:s,...a}=t,f=Y($,e),c=q($,e),[i,l]=o.useState(null),[p,g]=o.useState(null),w=V(n,_=>g(_)),C=fe(e),P=o.useRef(!1),N=o.useRef(!0),{viewport:d,selectedItem:v,selectedItemText:S,focusSelectedItem:u}=c,m=o.useCallback(()=>{if(f.trigger&&f.valueNode&&i&&p&&d&&v&&S){const _=f.trigger.getBoundingClientRect(),O=p.getBoundingClientRect(),ne=f.valueNode.getBoundingClientRect(),re=S.getBoundingClientRect();if(f.dir!=="rtl"){const x=re.left-O.left,y=ne.left-x,Q=_.left-y,ee=_.width+Q,ve=Math.max(ee,O.width),ge=window.innerWidth-A,xe=Ae(y,[A,Math.max(A,ge-ve)]);i.style.minWidth=ee+"px",i.style.left=xe+"px"}else{const x=O.right-re.right,y=window.innerWidth-ne.right-x,Q=window.innerWidth-_.right-y,ee=_.width+Q,ve=Math.max(ee,O.width),ge=window.innerWidth-A,xe=Ae(y,[A,Math.max(A,ge-ve)]);i.style.minWidth=ee+"px",i.style.right=xe+"px"}const B=C(),H=window.innerHeight-A*2,Z=d.scrollHeight,F=window.getComputedStyle(p),D=parseInt(F.borderTopWidth,10),U=parseInt(F.paddingTop,10),W=parseInt(F.borderBottomWidth,10),K=parseInt(F.paddingBottom,10),L=D+U+Z+K+W,se=Math.min(v.offsetHeight*5,L),k=window.getComputedStyle(d),J=parseInt(k.paddingTop,10),ae=parseInt(k.paddingBottom,10),le=_.top+_.height/2-A,de=H-le,ce=v.offsetHeight/2,h=v.offsetTop+ce,T=D+U+h,E=L-T;if(T<=le){const x=B.length>0&&v===B[B.length-1].ref.current;i.style.bottom="0px";const y=p.clientHeight-d.offsetTop-d.offsetHeight,Q=Math.max(de,ce+(x?ae:0)+y+W),ee=T+Q;i.style.height=ee+"px"}else{const x=B.length>0&&v===B[0].ref.current;i.style.top="0px";const Q=Math.max(le,D+d.offsetTop+(x?J:0)+ce)+E;i.style.height=Q+"px",d.scrollTop=T-le+d.offsetTop}i.style.margin=`${A}px 0`,i.style.minHeight=se+"px",i.style.maxHeight=H+"px",s==null||s(),requestAnimationFrame(()=>P.current=!0)}},[C,f.trigger,f.valueNode,i,p,d,v,S,f.dir,s]);z(()=>m(),[m]);const[M,R]=o.useState();z(()=>{p&&R(window.getComputedStyle(p).zIndex)},[p]);const X=o.useCallback(_=>{_&&N.current===!0&&(m(),u==null||u(),N.current=!1)},[m,u]);return r.jsx(zt,{scope:e,contentWrapper:i,shouldExpandOnScrollRef:P,onScrollButtonChange:X,children:r.jsx("div",{ref:l,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:M},children:r.jsx(j.div,{...a,ref:w,style:{boxSizing:"border-box",maxHeight:"100%",...a.style}})})})});Ye.displayName=Wt;var Kt="SelectPopperPosition",Se=o.forwardRef((t,n)=>{const{__scopeSelect:e,align:s="start",collisionPadding:a=A,...f}=t,c=me(e);return r.jsx(bt,{...c,...f,ref:n,align:s,collisionPadding:a,style:{boxSizing:"border-box",...f.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}})});Se.displayName=Kt;var[zt,Pe]=oe($,{}),we="SelectViewport",qe=o.forwardRef((t,n)=>{const{__scopeSelect:e,nonce:s,...a}=t,f=q(we,e),c=Pe(we,e),i=V(n,f.onViewportChange),l=o.useRef(0);return r.jsxs(r.Fragment,{children:[r.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"},nonce:s}),r.jsx(pe.Slot,{scope:e,children:r.jsx(j.div,{"data-radix-select-viewport":"",role:"presentation",...a,ref:i,style:{position:"relative",flex:1,overflow:"hidden auto",...a.style},onScroll:b(a.onScroll,p=>{const g=p.currentTarget,{contentWrapper:w,shouldExpandOnScrollRef:C}=c;if(C!=null&&C.current&&w){const P=Math.abs(l.current-g.scrollTop);if(P>0){const N=window.innerHeight-A*2,d=parseFloat(w.style.minHeight),v=parseFloat(w.style.height),S=Math.max(d,v);if(S<N){const u=S+P,m=Math.min(N,u),M=u-m;w.style.height=m+"px",w.style.bottom==="0px"&&(g.scrollTop=M>0?M:0,w.style.justifyContent="flex-end")}}}l.current=g.scrollTop})})})]})});qe.displayName=we;var Xe="SelectGroup",[Gt,$t]=oe(Xe),Yt=o.forwardRef((t,n)=>{const{__scopeSelect:e,...s}=t,a=Ie();return r.jsx(Gt,{scope:e,id:a,children:r.jsx(j.div,{role:"group","aria-labelledby":a,...s,ref:n})})});Yt.displayName=Xe;var Ze="SelectLabel",be=o.forwardRef((t,n)=>{const{__scopeSelect:e,...s}=t,a=$t(Ze,e);return r.jsx(j.div,{id:a.id,...s,ref:n})});be.displayName=Ze;var ue="SelectItem",[qt,Je]=oe(ue),Re=o.forwardRef((t,n)=>{const{__scopeSelect:e,value:s,disabled:a=!1,textValue:f,...c}=t,i=Y(ue,e),l=q(ue,e),p=i.value===s,[g,w]=o.useState(f??""),[C,P]=o.useState(!1),N=V(n,u=>{var m;return(m=l.itemRefCallback)==null?void 0:m.call(l,u,s,a)}),d=Ie(),v=o.useRef("touch"),S=()=>{a||(i.onValueChange(s),i.onOpenChange(!1))};return r.jsx(qt,{scope:e,value:s,disabled:a,textId:d,isSelected:p,onItemTextChange:o.useCallback(u=>{w(m=>m||((u==null?void 0:u.textContent)??"").trim())},[]),children:r.jsx(pe.ItemSlot,{scope:e,value:s,disabled:a,textValue:g,children:r.jsx(j.div,{role:"option","aria-labelledby":d,"data-highlighted":C?"":void 0,"aria-selected":p&&C,"data-state":p?"checked":"unchecked","aria-disabled":a||void 0,"data-disabled":a?"":void 0,tabIndex:a?void 0:-1,...c,ref:N,onFocus:b(c.onFocus,()=>P(!0)),onBlur:b(c.onBlur,()=>P(!1)),onClick:b(c.onClick,()=>{v.current!=="mouse"&&S()}),onPointerUp:b(c.onPointerUp,()=>{v.current==="mouse"&&S()}),onPointerDown:b(c.onPointerDown,u=>{v.current=u.pointerType}),onPointerMove:b(c.onPointerMove,u=>{var m;v.current=u.pointerType,a?(m=l.onItemLeave)==null||m.call(l):v.current==="mouse"&&u.currentTarget.focus({preventScroll:!0})}),onPointerLeave:b(c.onPointerLeave,u=>{var m;u.currentTarget===document.activeElement&&((m=l.onItemLeave)==null||m.call(l))}),onKeyDown:b(c.onKeyDown,u=>{var M;((M=l.searchRef)==null?void 0:M.current)!==""&&u.key===" "||(Mt.includes(u.key)&&S(),u.key===" "&&u.preventDefault())})})})})});Re.displayName=ue;var ie="SelectItemText",Qe=o.forwardRef((t,n)=>{const{__scopeSelect:e,className:s,style:a,...f}=t,c=Y(ie,e),i=q(ie,e),l=Je(ie,e),p=Lt(ie,e),[g,w]=o.useState(null),C=V(n,S=>w(S),l.onItemTextChange,S=>{var u;return(u=i.itemTextRefCallback)==null?void 0:u.call(i,S,l.value,l.disabled)}),P=g==null?void 0:g.textContent,N=o.useMemo(()=>r.jsx("option",{value:l.value,disabled:l.disabled,children:P},l.value),[l.disabled,l.value,P]),{onNativeOptionAdd:d,onNativeOptionRemove:v}=p;return z(()=>(d(N),()=>v(N)),[d,v,N]),r.jsxs(r.Fragment,{children:[r.jsx(j.span,{id:l.textId,...f,ref:C}),l.isSelected&&c.valueNode&&!c.valueNodeHasChildren&&!he(c.value)?Oe.createPortal(f.children,c.valueNode):null]})});Qe.displayName=ie;var et="SelectItemIndicator",tt=o.forwardRef((t,n)=>{const{__scopeSelect:e,...s}=t;return Je(et,e).isSelected?r.jsx(j.span,{"aria-hidden":!0,...s,ref:n}):null});tt.displayName=et;var ye="SelectScrollUpButton",_e=o.forwardRef((t,n)=>{const e=q(ye,t.__scopeSelect),s=Pe(ye,t.__scopeSelect),[a,f]=o.useState(!1),c=V(n,s.onScrollButtonChange);return z(()=>{if(e.viewport&&e.isPositioned){let i=function(){const p=l.scrollTop>0;f(p)};const l=e.viewport;return i(),l.addEventListener("scroll",i),()=>l.removeEventListener("scroll",i)}},[e.viewport,e.isPositioned]),a?r.jsx(ot,{...t,ref:c,onAutoScroll:()=>{const{viewport:i,selectedItem:l}=e;i&&l&&(i.scrollTop=i.scrollTop-l.offsetHeight)}}):null});_e.displayName=ye;var Ce="SelectScrollDownButton",Ee=o.forwardRef((t,n)=>{const e=q(Ce,t.__scopeSelect),s=Pe(Ce,t.__scopeSelect),[a,f]=o.useState(!1),c=V(n,s.onScrollButtonChange);return z(()=>{if(e.viewport&&e.isPositioned){let i=function(){const p=l.scrollHeight-l.clientHeight,g=Math.ceil(l.scrollTop)<p;f(g)};const l=e.viewport;return i(),l.addEventListener("scroll",i),()=>l.removeEventListener("scroll",i)}},[e.viewport,e.isPositioned]),a?r.jsx(ot,{...t,ref:c,onAutoScroll:()=>{const{viewport:i,selectedItem:l}=e;i&&l&&(i.scrollTop=i.scrollTop+l.offsetHeight)}}):null});Ee.displayName=Ce;var ot=o.forwardRef((t,n)=>{const{__scopeSelect:e,onAutoScroll:s,...a}=t,f=q("SelectScrollButton",e),c=o.useRef(null),i=fe(e),l=o.useCallback(()=>{c.current!==null&&(window.clearInterval(c.current),c.current=null)},[]);return o.useEffect(()=>()=>l(),[l]),z(()=>{var g;const p=i().find(w=>w.ref.current===document.activeElement);(g=p==null?void 0:p.ref.current)==null||g.scrollIntoView({block:"nearest"})},[i]),r.jsx(j.div,{"aria-hidden":!0,...a,ref:n,style:{flexShrink:0,...a.style},onPointerDown:b(a.onPointerDown,()=>{c.current===null&&(c.current=window.setInterval(s,50))}),onPointerMove:b(a.onPointerMove,()=>{var p;(p=f.onItemLeave)==null||p.call(f),c.current===null&&(c.current=window.setInterval(s,50))}),onPointerLeave:b(a.onPointerLeave,()=>{l()})})}),Xt="SelectSeparator",je=o.forwardRef((t,n)=>{const{__scopeSelect:e,...s}=t;return r.jsx(j.div,{"aria-hidden":!0,...s,ref:n})});je.displayName=Xt;var nt="SelectArrow",Zt=o.forwardRef((t,n)=>{const{__scopeSelect:e,...s}=t,a=me(e);return q(nt,e).position==="popper"?r.jsx(Rt,{...a,...s,ref:n}):null});Zt.displayName=nt;var rt="SelectBubbleInput",st=o.forwardRef(({__scopeSelect:t,...n},e)=>{const s=Y(rt,t),{value:a,onValueChange:f,required:c,disabled:i,name:l,autoComplete:p,form:g}=s,{nativeOptions:w,nativeSelectKey:C}=s,P=o.useRef(null),N=V(e,P),d=a??"",v=ft(d),S=Array.from(w).some(u=>(u.props.value??"")==="");return o.useEffect(()=>{const u=P.current;if(!u)return;const m=window.HTMLSelectElement.prototype,R=Object.getOwnPropertyDescriptor(m,"value").set;if(v!==d&&R){const X=new Event("change",{bubbles:!0});R.call(u,d),u.dispatchEvent(X)}},[v,d]),r.jsxs(j.select,{"aria-hidden":!0,required:c,tabIndex:-1,name:l,autoComplete:p,disabled:i,form:g,onChange:u=>f(u.target.value),...n,style:{...mt,...n.style},ref:N,defaultValue:d,children:[he(a)&&!S?r.jsx("option",{value:""}):null,Array.from(w)]},C)});st.displayName=rt;function Jt(t){return typeof t=="function"}function he(t){return t===""||t===void 0}function at(t){const n=St(t),e=o.useRef(""),s=o.useRef(0),a=o.useCallback(c=>{const i=e.current+c;n(i),function l(p){e.current=p,window.clearTimeout(s.current),p!==""&&(s.current=window.setTimeout(()=>l(""),1e3))}(i)},[n]),f=o.useCallback(()=>{e.current="",window.clearTimeout(s.current)},[]);return o.useEffect(()=>()=>window.clearTimeout(s.current),[]),[e,a,f]}function lt(t,n,e){const a=n.length>1&&Array.from(n).every(p=>p===n[0])?n[0]:n,f=e?t.indexOf(e):-1;let c=Qt(t,Math.max(f,0));a.length===1&&(c=c.filter(p=>p!==e));const l=c.find(p=>p.textValue.toLowerCase().startsWith(a.toLowerCase()));return l!==e?l:void 0}function Qt(t,n){return t.map((e,s)=>t[(n+s)%t.length])}const co=Ve,io=Fe,eo=o.forwardRef(({className:t,children:n,...e},s)=>r.jsxs(Ne,{ref:s,className:G("flex h-10 w-full items-center justify-between rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1",t),...e,children:[n,r.jsx(Ue,{asChild:!0,children:r.jsx(Le,{className:"h-4 w-4 opacity-50"})})]}));eo.displayName=Ne.displayName;const ct=o.forwardRef(({className:t,...n},e)=>r.jsx(_e,{ref:e,className:G("flex cursor-default items-center justify-center py-1",t),...n,children:r.jsx(Et,{className:"h-4 w-4"})}));ct.displayName=_e.displayName;const it=o.forwardRef(({className:t,...n},e)=>r.jsx(Ee,{ref:e,className:G("flex cursor-default items-center justify-center py-1",t),...n,children:r.jsx(Le,{className:"h-4 w-4"})}));it.displayName=Ee.displayName;const to=o.forwardRef(({className:t,children:n,position:e="popper",...s},a)=>r.jsx(Ke,{children:r.jsxs(Te,{ref:a,className:G("relative z-50 max-h-96 min-w-[8rem] overflow-hidden rounded-md border bg-popover text-popover-foreground shadow-md data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e==="popper"&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",t),position:e,...s,children:[r.jsx(ct,{}),r.jsx(qe,{className:G("p-1",e==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"),children:n}),r.jsx(it,{})]})}));to.displayName=Te.displayName;const oo=o.forwardRef(({className:t,...n},e)=>r.jsx(be,{ref:e,className:G("py-1.5 pl-8 pr-2 text-sm font-semibold",t),...n}));oo.displayName=be.displayName;const no=o.forwardRef(({className:t,children:n,...e},s)=>r.jsxs(Re,{ref:s,className:G("relative flex w-full cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 focus:bg-accent focus:text-accent-foreground",t),...e,children:[r.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:r.jsx(tt,{children:r.jsx(_t,{className:"h-4 w-4"})})}),r.jsx(Qe,{children:n})]}));no.displayName=Re.displayName;const ro=o.forwardRef(({className:t,...n},e)=>r.jsx(je,{ref:e,className:G("-mx-1 my-1 h-px bg-muted",t),...n}));ro.displayName=je.displayName;export{Et as C,co as S,eo as a,io as b,to as c,no as d};
//# sourceMappingURL=select-Dcsz1esX.js.map