1import{a as e}from"./chunk-BEqpzyXh.js";import{n as t}from"./jsx-runtime-CCEf19KK.js";import{t as n}from"./react-dom-CqxOlz69.js";var r=e(t());function i({controlled:e,default:t,name:n,state:i=`value`}){let{current:a}=r.useRef(e!==void 0),[o,s]=r.useState(t);return[a?e:o,r.useCallback(e=>{a||s(e)},[])]}var a={};function o(e,t){let n=r.useRef(a);return n.current===a&&(n.current=e(t)),n}var s=r[`useInsertionEffect${Math.random().toFixed(1)}`.slice(0,-3)],c=s&&s!==r.useLayoutEffect?s:e=>e();function l(e){let t=o(u).current;return t.next=e,c(t.effect),t.trampoline}function u(){let e={next:void 0,callback:d,trampoline:(...t)=>e.callback?.(...t),effect:()=>{e.callback=e.next}};return e}function d(){}var f=typeof document<`u`?r.useLayoutEffect:()=>{};function p(e,...t){let n=new URL(`https://base-ui.com/production-error`);return n.searchParams.set(`code`,e.toString()),t.forEach(e=>n.searchParams.append(`args[]`,e)),`Base UI error #${e}; visit ${n} for the full message.`}function m(e,t,n,r){let i=o(g).current;return ee(i,e,t,n,r)&&_(i,[e,t,n,r]),i.callback}function h(e){let t=o(g).current;return te(t,e)&&_(t,e),t.callback}function g(){return{callback:null,cleanup:null,refs:[]}}function ee(e,t,n,r,i){return e.refs[0]!==t||e.refs[1]!==n||e.refs[2]!==r||e.refs[3]!==i}function te(e,t){return e.refs.length!==t.length||e.refs.some((e,n)=>e!==t[n])}function _(e,t){if(e.refs=t,t.every(e=>e==null)){e.callback=null;return}e.callback=n=>{if(e.cleanup&&=(e.cleanup(),null),n!=null){let r=Array(t.length).fill(null);for(let e=0;e<t.length;e+=1){let i=t[e];if(i!=null)switch(typeof i){case`function`:{let t=i(n);typeof t==`function`&&(r[e]=t);break}case`object`:i.current=n;break;default:}}e.cleanup=()=>{for(let e=0;e<t.length;e+=1){let n=t[e];if(n!=null)switch(typeof n){case`function`:{let t=r[e];typeof t==`function`?t():n(null);break}case`object`:n.current=null;break;default:}}}}}}var ne=19;function re(e){return ne>=e}function v(e){if(!r.isValidElement(e))return null;let t=e,n=t.props;return(re(19)?n?.ref:t.ref)??null}function y(e,t){if(e&&!t)return e;if(!e&&t)return t;if(e||t)return{...e,...t}}function ie(e,t){let n={};for(let r in e){let i=e[r];if(t?.hasOwnProperty(r)){let e=t[r](i);e!=null&&Object.assign(n,e);continue}i===!0?n[`data-${r.toLowerCase()}`]=``:i&&(n[`data-${r.toLowerCase()}`]=i.toString())}return n}function ae(e,t){return typeof e==`function`?e(t):e}function oe(e,t){return typeof e==`function`?e(t):e}var b={};function x(e,t,n,r,i){let a={...w(e,b)};return t&&(a=S(a,t)),n&&(a=S(a,n)),r&&(a=S(a,r)),i&&(a=S(a,i)),a}function se(e){if(e.length===0)return b;if(e.length===1)return w(e[0],b);let t={...w(e[0],b)};for(let n=1;n<e.length;n+=1)t=S(t,e[n]);return t}function S(e,t){return C(t)?t(e):ce(e,t)}function ce(e,t){if(!t)return e;for(let n in t){let r=t[n];switch(n){case`style`:e[n]=y(e.style,r);break;case`className`:e[n]=E(e.className,r);break;default:le(n,r)?e[n]=ue(e[n],r):e[n]=r}}return e}function le(e,t){let n=e.charCodeAt(0),r=e.charCodeAt(1),i=e.charCodeAt(2);return n===111&&r===110&&i>=65&&i<=90&&(typeof t==`function`||t===void 0)}function C(e){return typeof e==`function`}function w(e,t){return C(e)?e(t):e??b}function ue(e,t){return t?e?n=>{if(de(n)){let r=n;T(r);let i=t(r);return r.baseUIHandlerPrevented||e?.(r),i}let r=t(n);return e?.(n),r}:t:e}function T(e){return e.preventBaseUIHandler=()=>{e.baseUIHandlerPrevented=!0},e}function E(e,t){return t?e?t+` `+e:t:e}function de(e){return typeof e==`object`&&!!e&&`nativeEvent`in e}function D(){}var fe=Object.freeze([]),O=Object.freeze({}),pe={style:{transition:`none`}},me=`data-base-ui-click-trigger`,he={fallbackAxisSide:`none`},ge={fallbackAxisSide:`end`},_e={clipPath:`inset(50%)`,position:`fixed`,top:0,left:0};function ve(e,t,n={}){let r=t.render,i=ye(t,n);return n.enabled===!1?null:xe(e,r,i,n.state??O)}function ye(e,t={}){let{className:n,style:r,render:i}=e,{state:a=O,ref:o,props:s,stateAttributesMapping:c,enabled:l=!0}=t,u=l?ae(n,a):void 0,d=l?oe(r,a):void 0,f=l?ie(a,c):O,p=l?y(f,Array.isArray(s)?se(s):s)??O:O;return typeof document<`u`&&(l?Array.isArray(o)?p.ref=h([p.ref,v(i),...o]):p.ref=m(p.ref,v(i),o):m(null,null)),l?(u!==void 0&&(p.className=E(p.className,u)),d!==void 0&&(p.style=y(p.style,d)),p):O}var be=Symbol.for(`react.lazy`);function xe(e,t,n,i){if(t){if(typeof t==`function`)return t(n,i);let e=x(n,t.props);e.ref=n.ref;let a=t;return a?.$$typeof===be&&(a=r.Children.toArray(t)[0]),r.cloneElement(a,e)}if(e&&typeof e==`string`)return Se(e,n);throw Error(p(8))}function Se(e,t){return e===`button`?(0,r.createElement)(`button`,{type:`button`,...t,key:t.key}):e===`img`?(0,r.createElement)(`img`,{alt:``,...t,key:t.key}):r.createElement(e,t)}var Ce=`none`,we=`trigger-press`,Te=`trigger-hover`,Ee=`trigger-focus`,De=`outside-press`,Oe=`item-press`,ke=`close-press`,Ae=`track-press`,je=`input-change`,Me=`focu
1s-out`,Ne=`escape-key`,Pe=`close-watcher`,Fe=`list-navigation`,Ie=`keyboard`,Le=`drag`,Re=`cancel-open`,ze=`sibling-open`,Be=`imperative-action`,Ve=`swipe`,He=`window-resize`;function Ue(e,t,n,r){let i=!1,a=!1,o=r??O;return{reason:e,event:t??new Event(`base-ui`),cancel(){i=!0},allowPropagation(){a=!0},get isCanceled(){return i},get isPropagationAllowed(){return a},trigger:n,...o}}function We(e,t,n){let r=n??O;return{reason:e,event:t??new Event(`base-ui`),...r}}var Ge={...r},k=0;function Ke(e,t=`mui`){let[n,i]=r.useState(e),a=e||n;return r.useEffect(()=>{n??(k+=1,i(`${t}-${k}`))},[n,t]),a}var A=Ge.useId;function j(e,t){if(A!==void 0){let n=A();return e??(t?`${t}-${n}`:n)}return Ke(e,t)}function M(e){return j(e,`base-ui`)}function N(){return typeof window<`u`}function P(e){return L(e)?(e.nodeName||``).toLowerCase():`#document`}function F(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function I(e){return((L(e)?e.ownerDocument:e.document)||window.document)?.documentElement}function L(e){return N()?e instanceof Node||e instanceof F(e).Node:!1}function R(e){return N()?e instanceof Element||e instanceof F(e).Element:!1}function z(e){return N()?e instanceof HTMLElement||e instanceof F(e).HTMLElement:!1}function B(e){return!N()||typeof ShadowRoot>`u`?!1:e instanceof ShadowRoot||e instanceof F(e).ShadowRoot}var qe=new Set([`inline`,`contents`]);function V(e){let{overflow:t,overflowX:n,overflowY:r,display:i}=K(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!qe.has(i)}var Je=new Set([`table`,`td`,`th`]);function Ye(e){return Je.has(P(e))}var Xe=[`:popover-open`,`:modal`];function H(e){return Xe.some(t=>{try{return e.matches(t)}catch{return!1}})}var Ze=[`transform`,`translate`,`scale`,`rotate`,`perspective`],Qe=[`transform`,`translate`,`scale`,`rotate`,`perspective`,`filter`],$e=[`paint`,`layout`,`strict`,`content`];function U(e){let t=W(),n=R(e)?K(e):e;return Ze.some(e=>n[e]?n[e]!==`none`:!1)||(n.containerType?n.containerType!==`normal`:!1)||!t&&(n.backdropFilter?n.backdropFilter!==`none`:!1)||!t&&(n.filter?n.filter!==`none`:!1)||Qe.some(e=>(n.willChange||``).includes(e))||$e.some(e=>(n.contain||``).includes(e))}function et(e){let t=q(e);for(;z(t)&&!G(t);){if(U(t))return t;if(H(t))return null;t=q(t)}return null}function W(){return typeof CSS>`u`||!CSS.supports?!1:CSS.supports(`-webkit-backdrop-filter`,`none`)}var tt=new Set([`html`,`body`,`#document`]);function G(e){return tt.has(P(e))}function K(e){return F(e).getComputedStyle(e)}function nt(e){return R(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function q(e){if(P(e)===`html`)return e;let t=e.assignedSlot||e.parentNode||B(e)&&e.host||I(e);return B(t)?t.host:t}function J(e){let t=q(e);return G(t)?e.ownerDocument?e.ownerDocument.body:e.body:z(t)&&V(t)?t:J(t)}function Y(e,t,n){t===void 0&&(t=[]),n===void 0&&(n=!0);let r=J(e),i=r===e.ownerDocument?.body,a=F(r);if(i){let e=X(a);return t.concat(a,a.visualViewport||[],V(r)?r:[],e&&n?Y(e):[])}return t.concat(r,Y(r,[],n))}function X(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}var Z=r.createContext(void 0);function Q(e=!1){let t=r.useContext(Z);if(t===void 0&&!e)throw Error(p(16));return t}function rt(e){let{focusableWhenDisabled:t,disabled:n,composite:i=!1,tabIndex:a=0,isNativeButton:o}=e,s=i&&t!==!1,c=i&&t===!1;return{props:r.useMemo(()=>{let e={onKeyDown(e){n&&t&&e.key!==`Tab`&&e.preventDefault()}};return i||(e.tabIndex=a,!o&&n&&(e.tabIndex=t?a:-1)),(o&&(t||s)||!o&&n)&&(e[`aria-disabled`]=n),o&&(!t||c)&&(e.disabled=n),e},[i,n,t,s,c,o,a])}}function it(e={}){let{disabled:t=!1,focusableWhenDisabled:n,tabIndex:i=0,native:a=!0}=e,o=r.useRef(null),s=Q(!0)!==void 0,c=l(()=>{let e=o.current;return!!(e?.tagName===`A`&&e?.href)}),{props:u}=rt({focusableWhenDisabled:n,disabled:t,composite:s,tabIndex:i,isNativeButton:a}),d=r.useCallback(()=>{let e=o.current;at(e)&&s&&t&&u.disabled===void 0&&e.disabled&&(e.disabled=!1)},[t,u.disabled,s]);return f(d,[d]),{getButtonProps:r.useCallback((e={})=>{let{onClick:n,onMouseDown:r,onKeyUp:i,onKeyDown:o,onPointerDown:s,...l}=e;return x({type:a?`button`:void 0,onClick(e){if(t){e.preventDefault();return}n?.(e)},onMouseDown(e){t||r?.(e)},onKeyDown(e){if(t||(T(e),o?.(e)),e.baseUIHandlerPrevented)return;let r=e.target===e.currentTarget&&!a&&!c()&&!t,i=e.key===`Enter`,s=e.key===` `;r&&((s||i)&&e.preventDefault(),i&&n?.(e))},onKeyUp(e){t||(T(e),i?.(e)),!e.baseUIHandlerPrevented&&e.target===e.currentTarget&&!a&&!t&&e.key===` `&&n?.(e)},onPointerDown(e){if(t){e.preventDefault();return}s?.(e)}},a?void 0:{role:`button`},u,l)},[t,u,a,c]),buttonRef:l(e=>{o.current=e,d()})}}function at(e){return z(e)&&e.tagName===`BUTTON`}var $={clipPath:`inset(50%)`,overflow:`hidden`,whiteSpace:`nowrap`,border:0,padding:0,width:1,height:1,margin:-1},ot={...$,position:`fixed`,top:0,left:0},st={...$,position:`absolute`},ct=function(e){return e.disabled=`data-disabled`,e.valid=`data-valid`,e.invali
1d=`data-invalid`,e.touched=`data-touched`,e.dirty=`data-dirty`,e.filled=`data-filled`,e.focused=`data-focused`,e}({}),lt={badInput:!1,customError:!1,patternMismatch:!1,rangeOverflow:!1,rangeUnderflow:!1,stepMismatch:!1,tooLong:!1,tooShort:!1,typeMismatch:!1,valid:null,valueMissing:!1},ut={valid(e){return e===null?null:e?{[ct.valid]:``}:{[ct.invalid]:``}}},dt=r.createContext({invalid:void 0,name:void 0,validityData:{state:lt,errors:[],error:``,value:``,initialValue:null},setValidityData:D,disabled:void 0,touched:!1,setTouched:D,dirty:!1,setDirty:D,filled:!1,setFilled:D,focused:!1,setFocused:D,validate:()=>null,validationMode:`onSubmit`,validationDebounceTime:0,shouldValidateOnChange:()=>!1,state:{disabled:!1,valid:null,touched:!1,dirty:!1,filled:!1,focused:!1},markedDirtyRef:{current:!1},validation:{getValidationProps:(e=O)=>e,getInputValidationProps:(e=O)=>e,inputRef:{current:null},commit:async()=>{}}});function ft(e=!0){let t=r.useContext(dt);if(t.setValidityData===D&&!e)throw Error(p(28));return t}function pt(e,t){return{...e,state:{...e.state,valid:!t&&e.state.valid}}}var mt=r.createContext({formRef:{current:{fields:new Map}},errors:{},clearErrors:D,validationMode:`onSubmit`,submitAttemptedRef:{current:!1}});function ht(){return r.useContext(mt)}var gt=e(n());function _t(e){let{enabled:t=!0,value:n,id:r,name:i,controlRef:a,commit:o}=e,{formRef:s}=ht(),{invalid:c,markedDirtyRef:u,validityData:d,setValidityData:p}=ft(),m=l(e.getValue);f(()=>{if(!t)return;let e=n;e===void 0&&(e=m()),d.initialValue===null&&e!==null&&p(t=>({...t,initialValue:e}))},[t,p,n,d.initialValue,m]),f(()=>{!t||!r||s.current.fields.set(r,{getValue:m,name:i,controlRef:a,validityData:pt(d,c),validate(e=!0){let t=n;t===void 0&&(t=m()),u.current=!0,e?gt.flushSync(()=>o(t)):o(t)}})},[o,a,t,s,m,r,c,u,i,d,n]),f(()=>{let e=s.current.fields;return()=>{r&&e.delete(r)}},[s,r])}var vt=r.createContext({controlId:void 0,registerControlId:D,labelId:void 0,setLabelId:D,messageIds:[],setMessageIds:D,getDescriptionProps:e=>e});function yt(){return r.useContext(vt)}function bt(e={}){let{id:t,implicit:n=!1,controlRef:i}=e,{controlId:a,registerControlId:s}=yt(),c=M(t),u=n?a:void 0,d=o(()=>Symbol(`labelable-control`)),p=r.useRef(!1),m=r.useRef(t!=null),h=l(()=>{!p.current||s===D||(p.current=!1,s(d.current,void 0))});return f(()=>{if(s===D)return;let e;if(n){let n=i?.current;e=R(n)&&n.closest(`label`)!=null?t??null:u??c}else if(t!=null)m.current=!0,e=t;else if(m.current)e=c;else{h();return}if(e===void 0){h();return}p.current=!0,s(d.current,e)},[t,i,u,s,n,c,d,h]),r.useEffect(()=>h,[h]),a??c}function xt(e,t){let n=r.useRef(e),i=l(t);f(()=>{n.current!==e&&i(n.current)},[e,i]),f(()=>{n.current=e},[e])}export{Te as $,H as A,Ne as B,R as C,V as D,L as E,We as F,Ie as G,Be as H,Re as I,De as J,Fe as K,ke as L,M,j as N,B as O,Ue as P,Ee as Q,Pe as R,U as S,G as T,je as U,Me as V,Oe as W,Ve as X,ze as Y,Ae as Z,P as _,o as _t,ht as a,he as at,q as b,ot as c,fe as ct,Z as d,x as dt,we as et,Q as f,re as ft,X as g,l as gt,I as h,f as ht,_t as i,pe as it,W as j,Ye as k,st as l,O as lt,et as m,p as mt,bt as n,ve as nt,ft as o,ge as ot,K as p,m as pt,Ce as q,yt as r,me as rt,ut as s,_e as st,xt as t,He as tt,it as u,D as ut,nt as v,i as vt,z as w,F as x,Y as y,Le as z};
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.