@udixio/ui-react 2.10.16 → 2.10.17

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -1,10 +1,10 @@
1
- "use strict";var Dn=Object.defineProperty;var An=(e,t,n)=>t in e?Dn(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var H=(e,t,n)=>An(e,typeof t!="symbol"?t+"":t,n);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("react/jsx-runtime"),o=require("react"),Ve=require("react-dom"),Y=require("motion/react"),ht=require("clsx"),Fn=require("tailwind-merge"),we=require("@udixio/theme"),Be=require("@udixio/tailwind"),Pn=require("react-textarea-autosize");var Pe=typeof document<"u"?document.currentScript:null;const mt=({colorName:e="on-surface",triggerRef:t})=>{const n={initial:{opacity:1,"--r":"25%"},animate:{opacity:1,"--r":"100%",transition:{duration:.5}},exit:{opacity:0,"--r":"100%",transition:{duration:.3}}},[s,r]=o.useState(!0),[u,c]=o.useState(!1),[a,d]=o.useState({x:50,y:50});o.useEffect(()=>{u&&(r(!0),r(!1))},[u]),o.useEffect(()=>{const p=t==null?void 0:t.current;if(p)return p.addEventListener("mousedown",i),p.addEventListener("mouseup",x),p.addEventListener("mouseleave",f),()=>{p.removeEventListener("mousedown",i),p.removeEventListener("mouseup",x),p.removeEventListener("mouseleave",f)}},[t]);const i=p=>{const b=t==null?void 0:t.current,w=b.getBoundingClientRect();c(!0),d({x:(p.clientX-w.left)/b.clientWidth*100,y:(p.clientY-w.top)/b.clientHeight*100})},f=p=>{c(!1)},x=p=>{c(!1)},h=`color-mix(in srgb, var(--state-color,_var(--color-${e})) 10%, transparent)`,m={position:"absolute",inset:0,width:"100%",height:"100%","--x":a.x+"%","--y":a.y+"%","--r":"0%",background:`radial-gradient(ellipse at var(--x) var(--y), ${h} var(--r), transparent calc(var(--r) * 2))`,pointerEvents:"none"};return l.jsx(Y.AnimatePresence,{mode:"wait",children:(u||!u&&!s)&&l.jsx(Y.motion.div,{style:m,variants:n,initial:"initial",animate:"animate",exit:"exit",onAnimationComplete:()=>r(!0)})})},pt=Fn.extendTailwindMerge({override:{classGroups:{"text-color":[{text:[e=>!e.startsWith("display-")&&!e.startsWith("headline-")&&!e.startsWith("title-")&&!e.startsWith("body-")&&!e.startsWith("label-")]}]}},extend:{classGroups:{font:[{text:[e=>e.startsWith("display-")||e.startsWith("headline-")||e.startsWith("title-")||e.startsWith("body-")||e.startsWith("label-")]}]},conflictingClassGroups:{font:["font"]}}}),y=(...e)=>pt(ht.clsx(e)),yt=(...e)=>pt(ht.clsx(e));function $n(e){return e.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase().normalize("NFD").replace(/[\u0300-\u036f]/g,"").replace(/[^a-z0-9]+/g,"-").replace(/^-+|-+$/g,"")}const Re=e=>{const t={};e.classNameList.forEach(s=>{var r;if(s)if(typeof s=="string")(t[r=e.default]??(t[r]=[])).push(s);else{const u=s(e.states);Object.entries(u).map(c=>{const[a,d]=c;(t[a]??(t[a]=[])).push(d)})}});const n=t;return Object.entries(t).map(s=>{let[r,u]=s;u=u.reverse(),r==e.default&&u.unshift("relative"),u.unshift($n(r)),n[r]=yt(...u)}),n},ne=(e,t)=>n=>Re({classNameList:[n.className,t],default:e,states:n}),Z=(e,t)=>n=>o.useMemo(()=>Re({classNameList:[n.className,t],default:e,states:n}),[n]);function Tn(e,t,n){return o.useMemo(()=>Re({classNameList:[n==null?void 0:n.className,t],default:e,states:n}),[e,t,n])}const xt=ne("customScroll",({orientation:e,draggable:t,isDragging:n})=>({customScroll:y("flex h-full w-full",t&&["[&::-webkit-scrollbar-track]:rounded-full","[&::-webkit-scrollbar-track]:bg-transparent","[&::-webkit-scrollbar-thumb]:rounded-full",{"[&::-webkit-scrollbar-thumb]:bg-outline":n,"[&::-webkit-scrollbar-thumb]:bg-transparent":!n},{"[&::-webkit-scrollbar]:h-2":e==="horizontal"},{"[&::-webkit-scrollbar]:w-2":e==="vertical"}],{"overflow-y-scroll flex-col":e==="vertical","overflow-x-scroll flex-row":e==="horizontal","cursor-grab":t&&!n,"cursor-grabbing":t&&n}),track:y("overflow-hidden flex-none sticky",{"left-0 h-full":e==="horizontal","top-0 w-full":e==="vertical"})}));function Wn(e,t){let n=0,s=null,r=null;const u=(c,a)=>{n=Date.now(),t(c,a)};return(c,a)=>{const d=Date.now(),i=e-(d-n);i<=0?(s&&(clearTimeout(s),s=null),u(c,a)):(r={v:c,o:a},s||(s=setTimeout(()=>{s=null;const f=r;r=null,f&&u(f.v,f.o)},i)))}}const vt=({children:e,orientation:t="vertical",scrollSize:n,onScroll:s,className:r,draggable:u=!1,throttleDuration:c=75,scroll:a,setScroll:d})=>{var G,S;const i=o.useRef(null),f=o.useRef(null),[x,h]=o.useState({width:null,height:null});o.useEffect(()=>{if(!i.current)return;const k=new ResizeObserver(C=>{for(const q of C)q.target===i.current&&h({width:q.contentRect.width,height:q.contentRect.height})});return k.observe(i.current),()=>{k.disconnect()}},[i]);const m=o.useRef(null),p=o.useRef(null),b=()=>{const k=f.current;return k?{width:n??k.scrollWidth,height:n??k.scrollHeight}:null},w=()=>{const k=i.current;return k?{width:k.clientWidth,height:k.clientHeight}:null},{scrollYProgress:L,scrollXProgress:E}=Y.useScroll({container:i}),g=o.useRef(null);g.current||(g.current=Wn(c,(k,C)=>{!p.current||!m.current||!i.current||(C===(t==="horizontal"?"x":"y")&&(d==null||d(k)),s&&(t==="horizontal"&&C==="x"&&s({scrollProgress:k,scroll:k*(m.current.width-i.current.clientWidth),scrollTotal:m.current.width-i.current.clientWidth,scrollVisible:p.current.width}),t==="vertical"&&C==="y"&&s({scrollProgress:k,scroll:k*(m.current.height-i.current.clientHeight),scrollTotal:m.current.height-i.current.clientHeight,scrollVisible:p.current.height})))}));const F=(k,C)=>{g.current&&g.current(k,C)};o.useEffect(()=>{x.width&&F(E.get(),"x"),x.height&&F(L.get(),"y")},[x]),o.useEffect(()=>{const k=i.current,C=f.current;if(!k||!C||typeof a!="number")return;const q=(U,J,te)=>Math.min(te,Math.max(J,U));if(t==="horizontal"){const U=Math.max(0,(n??C.scrollWidth)-k.clientWidth);k.scrollLeft=q(a*U,0,U)}else{const U=Math.max(0,(n??C.scrollHeight)-k.clientHeight);k.scrollTop=q(a*U,0,U)}},[a,t,n]),Y.useMotionValueEvent(E,"change",k=>{F(k,"x")}),Y.useMotionValueEvent(L,"change",k=>{F(k,"y")});const[I,v]=o.useState(!1);o.useLayoutEffect(()=>{I||!p.current||!m.current||!s||(s({scrollProgress:0,scroll:0,scrollTotal:t=="vertical"?m.current.height:m.current.width,scrollVisible:t=="vertical"?p.current.height:p.current.width}),v(!0))},[p,m,s]),m.current=b(),p.current=w();const[N,R]=o.useState(!1),M=xt({isDragging:N,children:e,className:r,onScroll:s,orientation:t,scrollSize:n,draggable:u,throttleDuration:c}),[W,j]=o.useState(0),[X,V]=o.useState(0),Q=k=>{if(!u)return;const C=i.current;if(!C||W==null)return;const U=(k.pageX-C.offsetLeft-W)*1.5;C.scrollLeft=X-U},z=k=>{const C=i.current;C&&(R(!0),j(k.pageX-C.offsetLeft),V(C.scrollLeft))},$=k=>{N&&(k.preventDefault(),Q(k))},D=()=>{R(!1)},B=()=>{R(!1)},A=k=>{k.preventDefault()},T=o.useRef(null);return o.useEffect(()=>()=>{T.current&&clearTimeout(T.current)},[]),o.useEffect(()=>{const k=i.current;if(!k)return;const C=q=>{var se,P,_,O;const U=q.detail,J=i.current;if(!J||!U)return;const te=U.orientation??t;if(typeof U.progress=="number")if(te==="horizontal"){const ee=Math.max(0,(((se=m.current)==null?void 0:se.width)??0)-J.clientWidth);J.scrollLeft=Math.min(ee,Math.max(0,U.progress*ee))}else{const ee=Math.max(0,(((P=m.current)==null?void 0:P.height)??0)-J.clientHeight);J.scrollTop=Math.min(ee,Math.max(0,U.progress*ee))}else if(typeof U.scroll=="number")if(te==="horizontal"){const ee=Math.max(0,(((_=m.current)==null?void 0:_.width)??0)-J.clientWidth);J.scrollLeft=Math.min(ee,Math.max(0,U.scroll))}else{const ee=Math.max(0,(((O=m.current)==null?void 0:O.height)??0)-J.clientHeight);J.scrollTop=Math.min(ee,Math.max(0,U.scroll))}};return k.addEventListener("udx:customScroll:set",C),()=>{k.removeEventListener("udx:customScroll:set",C)}},[t]),l.jsxs("div",{className:M.customScroll,ref:i,onMouseDown:z,onMouseMove:$,onMouseUp:D,onMouseLeave:B,onDragStart:A,onScroll:k=>{N||(j(null),R(!0),T.current&&clearTimeout(T.current),T.current=setTimeout(()=>{R(!1)},1e3))},children:[l.jsx("div",{ref:f,style:t==="vertical"?{height:((G=p==null?void 0:p.current)==null?void 0:G.height)??"100%"}:{width:((S=p==null?void 0:p.current)==null?void 0:S.width)??"100%"},className:M.track,children:e}),p.current&&m.current&&l.jsxs(l.Fragment,{children:[t==="vertical"&&m.current.height>p.current.height&&l.jsx(Y.motion.div,{className:"flex-none",style:{height:m.current.height-p.current.height}}),t==="horizontal"&&m.current.width>p.current.width&&l.jsx(Y.motion.div,{className:"flex-none",style:{width:m.current.width-p.current.width}})]})]})};var Bn="1.3.17";function gt(e,t,n){return Math.max(e,Math.min(t,n))}function On(e,t,n){return(1-n)*e+n*t}function Hn(e,t,n,s){return On(e,t,1-Math.exp(-n*s))}function Vn(e,t){return(e%t+t)%t}var zn=class{constructor(){H(this,"isRunning",!1);H(this,"value",0);H(this,"from",0);H(this,"to",0);H(this,"currentTime",0);H(this,"lerp");H(this,"duration");H(this,"easing");H(this,"onUpdate")}advance(e){var n;if(!this.isRunning)return;let t=!1;if(this.duration&&this.easing){this.currentTime+=e;const s=gt(0,this.currentTime/this.duration,1);t=s>=1;const r=t?1:this.easing(s);this.value=this.from+(this.to-this.from)*r}else this.lerp?(this.value=Hn(this.value,this.to,this.lerp*60,e),Math.round(this.value)===this.to&&(this.value=this.to,t=!0)):(this.value=this.to,t=!0);t&&this.stop(),(n=this.onUpdate)==null||n.call(this,this.value,t)}stop(){this.isRunning=!1}fromTo(e,t,{lerp:n,duration:s,easing:r,onStart:u,onUpdate:c}){this.from=this.value=e,this.to=t,this.lerp=n,this.duration=s,this.easing=r,this.currentTime=0,this.isRunning=!0,u==null||u(),this.onUpdate=c}};function _n(e,t){let n;return function(...s){let r=this;clearTimeout(n),n=setTimeout(()=>{n=void 0,e.apply(r,s)},t)}}var Yn=class{constructor(e,t,{autoResize:n=!0,debounce:s=250}={}){H(this,"width",0);H(this,"height",0);H(this,"scrollHeight",0);H(this,"scrollWidth",0);H(this,"debouncedResize");H(this,"wrapperResizeObserver");H(this,"contentResizeObserver");H(this,"resize",()=>{this.onWrapperResize(),this.onContentResize()});H(this,"onWrapperResize",()=>{this.wrapper instanceof Window?(this.width=window.innerWidth,this.height=window.innerHeight):(this.width=this.wrapper.clientWidth,this.height=this.wrapper.clientHeight)});H(this,"onContentResize",()=>{this.wrapper instanceof Window?(this.scrollHeight=this.content.scrollHeight,this.scrollWidth=this.content.scrollWidth):(this.scrollHeight=this.wrapper.scrollHeight,this.scrollWidth=this.wrapper.scrollWidth)});this.wrapper=e,this.content=t,n&&(this.debouncedResize=_n(this.resize,s),this.wrapper instanceof Window?window.addEventListener("resize",this.debouncedResize,!1):(this.wrapperResizeObserver=new ResizeObserver(this.debouncedResize),this.wrapperResizeObserver.observe(this.wrapper)),this.contentResizeObserver=new ResizeObserver(this.debouncedResize),this.contentResizeObserver.observe(this.content)),this.resize()}destroy(){var e,t;(e=this.wrapperResizeObserver)==null||e.disconnect(),(t=this.contentResizeObserver)==null||t.disconnect(),this.wrapper===window&&this.debouncedResize&&window.removeEventListener("resize",this.debouncedResize,!1)}get limit(){return{x:this.scrollWidth-this.width,y:this.scrollHeight-this.height}}},wt=class{constructor(){H(this,"events",{})}emit(e,...t){var s;let n=this.events[e]||[];for(let r=0,u=n.length;r<u;r++)(s=n[r])==null||s.call(n,...t)}on(e,t){var n;return(n=this.events[e])!=null&&n.push(t)||(this.events[e]=[t]),()=>{var s;this.events[e]=(s=this.events[e])==null?void 0:s.filter(r=>t!==r)}}off(e,t){var n;this.events[e]=(n=this.events[e])==null?void 0:n.filter(s=>t!==s)}destroy(){this.events={}}},ot=100/6,he={passive:!1},qn=class{constructor(e,t={wheelMultiplier:1,touchMultiplier:1}){H(this,"touchStart",{x:0,y:0});H(this,"lastDelta",{x:0,y:0});H(this,"window",{width:0,height:0});H(this,"emitter",new wt);H(this,"onTouchStart",e=>{const{clientX:t,clientY:n}=e.targetTouches?e.targetTouches[0]:e;this.touchStart.x=t,this.touchStart.y=n,this.lastDelta={x:0,y:0},this.emitter.emit("scroll",{deltaX:0,deltaY:0,event:e})});H(this,"onTouchMove",e=>{const{clientX:t,clientY:n}=e.targetTouches?e.targetTouches[0]:e,s=-(t-this.touchStart.x)*this.options.touchMultiplier,r=-(n-this.touchStart.y)*this.options.touchMultiplier;this.touchStart.x=t,this.touchStart.y=n,this.lastDelta={x:s,y:r},this.emitter.emit("scroll",{deltaX:s,deltaY:r,event:e})});H(this,"onTouchEnd",e=>{this.emitter.emit("scroll",{deltaX:this.lastDelta.x,deltaY:this.lastDelta.y,event:e})});H(this,"onWheel",e=>{let{deltaX:t,deltaY:n,deltaMode:s}=e;const r=s===1?ot:s===2?this.window.width:1,u=s===1?ot:s===2?this.window.height:1;t*=r,n*=u,t*=this.options.wheelMultiplier,n*=this.options.wheelMultiplier,this.emitter.emit("scroll",{deltaX:t,deltaY:n,event:e})});H(this,"onWindowResize",()=>{this.window={width:window.innerWidth,height:window.innerHeight}});this.element=e,this.options=t,window.addEventListener("resize",this.onWindowResize,!1),this.onWindowResize(),this.element.addEventListener("wheel",this.onWheel,he),this.element.addEventListener("touchstart",this.onTouchStart,he),this.element.addEventListener("touchmove",this.onTouchMove,he),this.element.addEventListener("touchend",this.onTouchEnd,he)}on(e,t){return this.emitter.on(e,t)}destroy(){this.emitter.destroy(),window.removeEventListener("resize",this.onWindowResize,!1),this.element.removeEventListener("wheel",this.onWheel,he),this.element.removeEventListener("touchstart",this.onTouchStart,he),this.element.removeEventListener("touchmove",this.onTouchMove,he),this.element.removeEventListener("touchend",this.onTouchEnd,he)}},it=e=>Math.min(1,1.001-Math.pow(2,-10*e)),Un=class{constructor({wrapper:e=window,content:t=document.documentElement,eventsTarget:n=e,smoothWheel:s=!0,syncTouch:r=!1,syncTouchLerp:u=.075,touchInertiaExponent:c=1.7,duration:a,easing:d,lerp:i=.1,infinite:f=!1,orientation:x="vertical",gestureOrientation:h=x==="horizontal"?"both":"vertical",touchMultiplier:m=1,wheelMultiplier:p=1,autoResize:b=!0,prevent:w,virtualScroll:L,overscroll:E=!0,autoRaf:g=!1,anchors:F=!1,autoToggle:I=!1,allowNestedScroll:v=!1,__experimental__naiveDimensions:N=!1,naiveDimensions:R=N,stopInertiaOnNavigate:M=!1}={}){H(this,"_isScrolling",!1);H(this,"_isStopped",!1);H(this,"_isLocked",!1);H(this,"_preventNextNativeScrollEvent",!1);H(this,"_resetVelocityTimeout",null);H(this,"_rafId",null);H(this,"isTouching");H(this,"time",0);H(this,"userData",{});H(this,"lastVelocity",0);H(this,"velocity",0);H(this,"direction",0);H(this,"options");H(this,"targetScroll");H(this,"animatedScroll");H(this,"animate",new zn);H(this,"emitter",new wt);H(this,"dimensions");H(this,"virtualScroll");H(this,"onScrollEnd",e=>{e instanceof CustomEvent||(this.isScrolling==="smooth"||this.isScrolling===!1)&&e.stopPropagation()});H(this,"dispatchScrollendEvent",()=>{this.options.wrapper.dispatchEvent(new CustomEvent("scrollend",{bubbles:this.options.wrapper===window,detail:{lenisScrollEnd:!0}}))});H(this,"onTransitionEnd",e=>{e.propertyName.includes("overflow")&&this.checkOverflow()});H(this,"onClick",e=>{const n=e.composedPath().filter(s=>s instanceof HTMLAnchorElement&&s.getAttribute("href"));if(this.options.anchors){const s=n.find(r=>{var u;return(u=r.getAttribute("href"))==null?void 0:u.includes("#")});if(s){const r=s.getAttribute("href");if(r){const u=typeof this.options.anchors=="object"&&this.options.anchors?this.options.anchors:void 0,c=`#${r.split("#")[1]}`;this.scrollTo(c,u)}}}this.options.stopInertiaOnNavigate&&n.find(r=>r.host===window.location.host)&&this.reset()});H(this,"onPointerDown",e=>{e.button===1&&this.reset()});H(this,"onVirtualScroll",e=>{if(typeof this.options.virtualScroll=="function"&&this.options.virtualScroll(e)===!1)return;const{deltaX:t,deltaY:n,event:s}=e;if(this.emitter.emit("virtual-scroll",{deltaX:t,deltaY:n,event:s}),s.ctrlKey||s.lenisStopPropagation)return;const r=s.type.includes("touch"),u=s.type.includes("wheel");this.isTouching=s.type==="touchstart"||s.type==="touchmove";const c=t===0&&n===0;if(this.options.syncTouch&&r&&s.type==="touchstart"&&c&&!this.isStopped&&!this.isLocked){this.reset();return}const d=this.options.gestureOrientation==="vertical"&&n===0||this.options.gestureOrientation==="horizontal"&&t===0;if(c||d)return;let i=s.composedPath();i=i.slice(0,i.indexOf(this.rootElement));const f=this.options.prevent;if(i.find(w=>{var L,E,g;return w instanceof HTMLElement&&(typeof f=="function"&&(f==null?void 0:f(w))||((L=w.hasAttribute)==null?void 0:L.call(w,"data-lenis-prevent"))||r&&((E=w.hasAttribute)==null?void 0:E.call(w,"data-lenis-prevent-touch"))||u&&((g=w.hasAttribute)==null?void 0:g.call(w,"data-lenis-prevent-wheel"))||this.options.allowNestedScroll&&this.checkNestedScroll(w,{deltaX:t,deltaY:n}))}))return;if(this.isStopped||this.isLocked){s.cancelable&&s.preventDefault();return}if(!(this.options.syncTouch&&r||this.options.smoothWheel&&u)){this.isScrolling="native",this.animate.stop(),s.lenisStopPropagation=!0;return}let h=n;this.options.gestureOrientation==="both"?h=Math.abs(n)>Math.abs(t)?n:t:this.options.gestureOrientation==="horizontal"&&(h=t),(!this.options.overscroll||this.options.infinite||this.options.wrapper!==window&&this.limit>0&&(this.animatedScroll>0&&this.animatedScroll<this.limit||this.animatedScroll===0&&n>0||this.animatedScroll===this.limit&&n<0))&&(s.lenisStopPropagation=!0),s.cancelable&&s.preventDefault();const m=r&&this.options.syncTouch,b=r&&s.type==="touchend";b&&(h=Math.sign(this.velocity)*Math.pow(Math.abs(this.velocity),this.options.touchInertiaExponent)),this.scrollTo(this.targetScroll+h,{programmatic:!1,...m?{lerp:b?this.options.syncTouchLerp:1}:{lerp:this.options.lerp,duration:this.options.duration,easing:this.options.easing}})});H(this,"onNativeScroll",()=>{if(this._resetVelocityTimeout!==null&&(clearTimeout(this._resetVelocityTimeout),this._resetVelocityTimeout=null),this._preventNextNativeScrollEvent){this._preventNextNativeScrollEvent=!1;return}if(this.isScrolling===!1||this.isScrolling==="native"){const e=this.animatedScroll;this.animatedScroll=this.targetScroll=this.actualScroll,this.lastVelocity=this.velocity,this.velocity=this.animatedScroll-e,this.direction=Math.sign(this.animatedScroll-e),this.isStopped||(this.isScrolling="native"),this.emit(),this.velocity!==0&&(this._resetVelocityTimeout=setTimeout(()=>{this.lastVelocity=this.velocity,this.velocity=0,this.isScrolling=!1,this.emit()},400))}});H(this,"raf",e=>{const t=e-(this.time||e);this.time=e,this.animate.advance(t*.001),this.options.autoRaf&&(this._rafId=requestAnimationFrame(this.raf))});window.lenisVersion=Bn,(!e||e===document.documentElement)&&(e=window),typeof a=="number"&&typeof d!="function"?d=it:typeof d=="function"&&typeof a!="number"&&(a=1),this.options={wrapper:e,content:t,eventsTarget:n,smoothWheel:s,syncTouch:r,syncTouchLerp:u,touchInertiaExponent:c,duration:a,easing:d,lerp:i,infinite:f,gestureOrientation:h,orientation:x,touchMultiplier:m,wheelMultiplier:p,autoResize:b,prevent:w,virtualScroll:L,overscroll:E,autoRaf:g,anchors:F,autoToggle:I,allowNestedScroll:v,naiveDimensions:R,stopInertiaOnNavigate:M},this.dimensions=new Yn(e,t,{autoResize:b}),this.updateClassName(),this.targetScroll=this.animatedScroll=this.actualScroll,this.options.wrapper.addEventListener("scroll",this.onNativeScroll,!1),this.options.wrapper.addEventListener("scrollend",this.onScrollEnd,{capture:!0}),(this.options.anchors||this.options.stopInertiaOnNavigate)&&this.options.wrapper.addEventListener("click",this.onClick,!1),this.options.wrapper.addEventListener("pointerdown",this.onPointerDown,!1),this.virtualScroll=new qn(n,{touchMultiplier:m,wheelMultiplier:p}),this.virtualScroll.on("scroll",this.onVirtualScroll),this.options.autoToggle&&(this.checkOverflow(),this.rootElement.addEventListener("transitionend",this.onTransitionEnd,{passive:!0})),this.options.autoRaf&&(this._rafId=requestAnimationFrame(this.raf))}destroy(){this.emitter.destroy(),this.options.wrapper.removeEventListener("scroll",this.onNativeScroll,!1),this.options.wrapper.removeEventListener("scrollend",this.onScrollEnd,{capture:!0}),this.options.wrapper.removeEventListener("pointerdown",this.onPointerDown,!1),(this.options.anchors||this.options.stopInertiaOnNavigate)&&this.options.wrapper.removeEventListener("click",this.onClick,!1),this.virtualScroll.destroy(),this.dimensions.destroy(),this.cleanUpClassName(),this._rafId&&cancelAnimationFrame(this._rafId)}on(e,t){return this.emitter.on(e,t)}off(e,t){return this.emitter.off(e,t)}get overflow(){const e=this.isHorizontal?"overflow-x":"overflow-y";return getComputedStyle(this.rootElement)[e]}checkOverflow(){["hidden","clip"].includes(this.overflow)?this.internalStop():this.internalStart()}setScroll(e){this.isHorizontal?this.options.wrapper.scrollTo({left:e,behavior:"instant"}):this.options.wrapper.scrollTo({top:e,behavior:"instant"})}resize(){this.dimensions.resize(),this.animatedScroll=this.targetScroll=this.actualScroll,this.emit()}emit(){this.emitter.emit("scroll",this)}reset(){this.isLocked=!1,this.isScrolling=!1,this.animatedScroll=this.targetScroll=this.actualScroll,this.lastVelocity=this.velocity=0,this.animate.stop()}start(){if(this.isStopped){if(this.options.autoToggle){this.rootElement.style.removeProperty("overflow");return}this.internalStart()}}internalStart(){this.isStopped&&(this.reset(),this.isStopped=!1,this.emit())}stop(){if(!this.isStopped){if(this.options.autoToggle){this.rootElement.style.setProperty("overflow","clip");return}this.internalStop()}}internalStop(){this.isStopped||(this.reset(),this.isStopped=!0,this.emit())}scrollTo(e,{offset:t=0,immediate:n=!1,lock:s=!1,programmatic:r=!0,lerp:u=r?this.options.lerp:void 0,duration:c=r?this.options.duration:void 0,easing:a=r?this.options.easing:void 0,onStart:d,onComplete:i,force:f=!1,userData:x}={}){if(!((this.isStopped||this.isLocked)&&!f)){if(typeof e=="string"&&["top","left","start","#"].includes(e))e=0;else if(typeof e=="string"&&["bottom","right","end"].includes(e))e=this.limit;else{let h;if(typeof e=="string"?(h=document.querySelector(e),h||(e==="#top"?e=0:console.warn("Lenis: Target not found",e))):e instanceof HTMLElement&&(e!=null&&e.nodeType)&&(h=e),h){if(this.options.wrapper!==window){const p=this.rootElement.getBoundingClientRect();t-=this.isHorizontal?p.left:p.top}const m=h.getBoundingClientRect();e=(this.isHorizontal?m.left:m.top)+this.animatedScroll}}if(typeof e=="number"){if(e+=t,e=Math.round(e),this.options.infinite){if(r){this.targetScroll=this.animatedScroll=this.scroll;const h=e-this.animatedScroll;h>this.limit/2?e=e-this.limit:h<-this.limit/2&&(e=e+this.limit)}}else e=gt(0,e,this.limit);if(e===this.targetScroll){d==null||d(this),i==null||i(this);return}if(this.userData=x??{},n){this.animatedScroll=this.targetScroll=e,this.setScroll(this.scroll),this.reset(),this.preventNextNativeScrollEvent(),this.emit(),i==null||i(this),this.userData={},requestAnimationFrame(()=>{this.dispatchScrollendEvent()});return}r||(this.targetScroll=e),typeof c=="number"&&typeof a!="function"?a=it:typeof a=="function"&&typeof c!="number"&&(c=1),this.animate.fromTo(this.animatedScroll,e,{duration:c,easing:a,lerp:u,onStart:()=>{s&&(this.isLocked=!0),this.isScrolling="smooth",d==null||d(this)},onUpdate:(h,m)=>{this.isScrolling="smooth",this.lastVelocity=this.velocity,this.velocity=h-this.animatedScroll,this.direction=Math.sign(this.velocity),this.animatedScroll=h,this.setScroll(this.scroll),r&&(this.targetScroll=h),m||this.emit(),m&&(this.reset(),this.emit(),i==null||i(this),this.userData={},requestAnimationFrame(()=>{this.dispatchScrollendEvent()}),this.preventNextNativeScrollEvent())}})}}}preventNextNativeScrollEvent(){this._preventNextNativeScrollEvent=!0,requestAnimationFrame(()=>{this._preventNextNativeScrollEvent=!1})}checkNestedScroll(e,{deltaX:t,deltaY:n}){const s=Date.now(),r=e._lenis??(e._lenis={});let u,c,a,d,i,f,x,h;const m=this.options.gestureOrientation;if(s-(r.time??0)>2e3){r.time=Date.now();const I=window.getComputedStyle(e);r.computedStyle=I;const v=I.overflowX,N=I.overflowY;if(u=["auto","overlay","scroll"].includes(v),c=["auto","overlay","scroll"].includes(N),r.hasOverflowX=u,r.hasOverflowY=c,!u&&!c||m==="vertical"&&!c||m==="horizontal"&&!u)return!1;i=e.scrollWidth,f=e.scrollHeight,x=e.clientWidth,h=e.clientHeight,a=i>x,d=f>h,r.isScrollableX=a,r.isScrollableY=d,r.scrollWidth=i,r.scrollHeight=f,r.clientWidth=x,r.clientHeight=h}else a=r.isScrollableX,d=r.isScrollableY,u=r.hasOverflowX,c=r.hasOverflowY,i=r.scrollWidth,f=r.scrollHeight,x=r.clientWidth,h=r.clientHeight;if(!u&&!c||!a&&!d||m==="vertical"&&(!c||!d)||m==="horizontal"&&(!u||!a))return!1;let p;if(m==="horizontal")p="x";else if(m==="vertical")p="y";else{const I=t!==0,v=n!==0;I&&u&&a&&(p="x"),v&&c&&d&&(p="y")}if(!p)return!1;let b,w,L,E,g;if(p==="x")b=e.scrollLeft,w=i-x,L=t,E=u,g=a;else if(p==="y")b=e.scrollTop,w=f-h,L=n,E=c,g=d;else return!1;return(L>0?b<w:b>0)&&E&&g}get rootElement(){return this.options.wrapper===window?document.documentElement:this.options.wrapper}get limit(){return this.options.naiveDimensions?this.isHorizontal?this.rootElement.scrollWidth-this.rootElement.clientWidth:this.rootElement.scrollHeight-this.rootElement.clientHeight:this.dimensions.limit[this.isHorizontal?"x":"y"]}get isHorizontal(){return this.options.orientation==="horizontal"}get actualScroll(){const e=this.options.wrapper;return this.isHorizontal?e.scrollX??e.scrollLeft:e.scrollY??e.scrollTop}get scroll(){return this.options.infinite?Vn(this.animatedScroll,this.limit):this.animatedScroll}get progress(){return this.limit===0?1:this.scroll/this.limit}get isScrolling(){return this._isScrolling}set isScrolling(e){this._isScrolling!==e&&(this._isScrolling=e,this.updateClassName())}get isStopped(){return this._isStopped}set isStopped(e){this._isStopped!==e&&(this._isStopped=e,this.updateClassName())}get isLocked(){return this._isLocked}set isLocked(e){this._isLocked!==e&&(this._isLocked=e,this.updateClassName())}get isSmooth(){return this.isScrolling==="smooth"}get className(){let e="lenis";return this.options.autoToggle&&(e+=" lenis-autoToggle"),this.isStopped&&(e+=" lenis-stopped"),this.isLocked&&(e+=" lenis-locked"),this.isScrolling&&(e+=" lenis-scrolling"),this.isScrolling==="smooth"&&(e+=" lenis-smooth"),e}updateClassName(){this.cleanUpClassName(),this.rootElement.className=`${this.rootElement.className} ${this.className}`.trim()}cleanUpClassName(){this.rootElement.className=this.rootElement.className.replace(/lenis(-\w+)?/g,"").trim()}};const Xn=({transition:e=1.2,easing:t,orientation:n="vertical",smoothTouch:s=!1,touchMultiplier:r=2,children:u})=>{const c=o.useRef(null),a=o.useRef(null);return o.useEffect(()=>{let d;typeof e=="string"?e.endsWith("ms")?d=parseFloat(e)/1e3:e.endsWith("s")?d=parseFloat(e):d=parseFloat(e)||1.2:d=e;const i=x=>1-Math.pow(1-x,5);c.current=new Un({duration:d,easing:t??i,orientation:n,smoothWheel:!0,touchMultiplier:r,syncTouch:s});const f=x=>{var h;(h=c.current)==null||h.raf(x),a.current=requestAnimationFrame(f)};return a.current=requestAnimationFrame(f),()=>{var x;a.current!==null&&cancelAnimationFrame(a.current),(x=c.current)==null||x.destroy(),c.current=null}},[e,t,n,s,r]),u?l.jsx(l.Fragment,{children:u}):null},ue=({style:e,colorName:t,stateClassName:n="state-ripple-group",children:s,className:r})=>{const u=o.useRef(null),c=o.useRef(null),[a,d]=o.useState(!1),i=bt({isClient:a,stateClassName:n,className:r,colorName:t});return o.useEffect(()=>{if(u.current&&n!=="state-layer"){const x=(n.includes("[")?"group/"+n.split("[")[1].split("]")[0]:"group").replace(/\//g,"\\/"),h=u.current.closest(`.${x}:not(.${x} .${x})`);c.current=h}d(!0)},[]),l.jsxs("div",{ref:u,className:i.stateLayer,style:{"--state-color":`var(--default-color, var(--color-${t}))`,...e},children:[a&&l.jsx(mt,{triggerRef:c}),s]})},Gn=({isClient:e,stateClassName:t})=>({stateLayer:y(["w-full top-0 left-0 h-full absolute pointer-events-none overflow-hidden",t])}),bt=Z("stateLayer",Gn),St=({targetRef:e,children:t})=>{const[n,s]=o.useState(null),r=o.useRef(null),u=()=>{const c=e.current;if(!c)return;const a=c.getBoundingClientRect();s({position:"fixed",top:a.top,left:a.left,width:a.width,height:a.height,pointerEvents:"none",zIndex:999})};return o.useEffect(()=>{const c=e.current;if(c)return u(),window.addEventListener("scroll",u,!0),window.addEventListener("resize",u),r.current=new ResizeObserver(u),r.current.observe(c),()=>{var a;window.removeEventListener("scroll",u,!0),window.removeEventListener("resize",u),(a=r.current)==null||a.disconnect()}},[e]),n?Ve.createPortal(l.jsx("div",{style:n,children:t}),document.body):null};function Kn(e){return/^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$/.test(e)}const Jn=({config:e,throttleDelay:t=100,onLoad:n,loadTheme:s=!1})=>{const[r,u]=o.useState(null),[c,a]=o.useState(null),d=o.useRef(null),i=o.useRef(0),f=o.useRef(0),x=o.useRef(null),h=o.useRef(!1),m=o.useRef(n);o.useEffect(()=>{m.current=n},[n]),o.useEffect(()=>{let E=!1;return(async()=>{const g=await we.loader(e,s);if(E)return;x.current=g,u(g);const F=new Worker(new URL(""+(typeof document>"u"?require("url").pathToFileURL(__dirname+"/theme.worker.js").href:new URL("theme.worker.js",document.currentScript&&document.currentScript.tagName.toUpperCase()==="SCRIPT"&&document.currentScript.src||document.baseURI).href),typeof document>"u"?require("url").pathToFileURL(__filename).href:Pe&&Pe.tagName.toUpperCase()==="SCRIPT"&&Pe.src||new URL("index.cjs",document.baseURI).href),{type:"module"});d.current=F,F.onmessage=I=>{var v;I.data.id>f.current&&(f.current=I.data.id,h.current=!0,a(I.data.css),(v=m.current)==null||v.call(m,x.current))}})(),()=>{var g;E=!0,(g=d.current)==null||g.terminate(),d.current=null}},[]);const p=o.useRef(null),b=o.useRef(0),w=o.useRef(null);o.useEffect(()=>{if(!r)return;const E={...e,sourceColor:e.sourceColor},g=Date.now(),F=g-b.current,I=async v=>{await L(v)};if(b.current===0||F>=t)p.current&&(clearTimeout(p.current),p.current=null),w.current=null,b.current=g,I(E);else if(w.current=E,!p.current){const v=Math.max(0,t-F);p.current=setTimeout(async()=>{p.current=null;const N=w.current;w.current=null,N&&(b.current=Date.now(),await I(N))},v)}return()=>{}},[e,t,r]);const L=async E=>{if(typeof E.sourceColor=="string"&&!Kn(E.sourceColor))throw new Error("Invalid hex color");const g=x.current;if(!g)return;g.context.update(E),g.palettes.sync(E.palettes);const F=d.current;if(!F||!h.current){await g.load();const R=g.plugins.getPlugin(Be.TailwindPlugin).getInstance().outputCss;a(R),h.current=!0,n==null||n(g);return}const I=++i.current,v=g.plugins.getPlugin(Be.TailwindPlugin).options,N=g.plugins.getPlugin(we.FontPlugin).options;F.postMessage({id:I,snapshot:we.serializeThemeContext(g),tailwindOptions:{darkMode:v.darkMode,dynamicSelector:v.dynamicSelector,darkSelector:v.darkSelector,responsiveBreakPoints:v.responsiveBreakPoints,styleFilePath:v.styleFilePath,subThemes:v.subThemes},fontOptions:{fontFamily:N.fontFamily,fontStyles:N.fontStyles}})};return o.useEffect(()=>()=>{p.current&&(clearTimeout(p.current),p.current=null)},[]),c?l.jsx("style",{dangerouslySetInnerHTML:{__html:c}}):null};function Zn(){if(typeof window>"u")return!1;try{if(window.CSS&&typeof window.CSS.supports=="function")return CSS.supports("animation-timeline: view()")||CSS.supports("animation-timeline: scroll()")||CSS.supports("view-timeline-name: --a")}catch{}return!1}function Qn(){return typeof window>"u"||!("matchMedia"in window)?!1:window.matchMedia("(prefers-reduced-motion: reduce)").matches}function ze(e){if(!(e instanceof HTMLElement))return!1;const t=e.classList;return Array.from(t).some(n=>n.startsWith("anim-")&&n.includes("scroll"))}function lt(e){if(!(e instanceof HTMLElement))return!1;const t=e.classList;return Array.from(t).some(n=>n.startsWith("anim-"))}function $e(e,t){if(!ze(e))return;if(e.hasAttribute(`data-${t}-scroll`)){const c=(e.getAttribute(`data-${t}-scroll`)||"").trim().toLowerCase(),a=c==="x"||c==="inline"?"inline":c==="y"||c==="block"?"block":"auto";e.classList.contains(`${t}-timeline`)||e.classList.contains(`${t}-timeline-inline`)||e.classList.contains(`${t}-timeline-block`)||e.classList.contains(`${t}-timeline-x`)||e.classList.contains(`${t}-timeline-y`)||(a==="inline"?e.classList.add(`${t}-timeline-inline`):a==="block"?e.classList.add(`${t}-timeline-block`):e.classList.add(`${t}-scroll`))}const n=e.getAttribute(`data-${t}-start`);n&&e.style.setProperty(`--${t}-range-start`,n);const s=e.getAttribute(`data-${t}-end`);s&&e.style.setProperty(`--${t}-range-end`,s);const r=e.hasAttribute(`data-${t}-paused`)||e.classList.contains(`${t}-paused`),u=e.hasAttribute(`data-${t}-run`)||e.classList.contains(`${t}-run`);!r&&!u&&e.setAttribute(`data-${t}-run`,"")}function Te(e=document,t){return Array.from(e.querySelectorAll(`[class*="${t}-"][class*="-scroll"]`)).filter(s=>ze(s))}function es(e=document,t){const n=Array.from(e.querySelectorAll(`[class*="${t}-"]`)),s=new Set([`${t}-run`,`${t}-in`,`${t}-out`,`${t}-in-run`,`${t}-out-run`,`${t}-paused`,`${t}-timeline`,`${t}-timeline-inline`,`${t}-timeline-block`,`${t}-timeline-x`,`${t}-timeline-y`,`${t}-scroll`]);return n.filter(r=>{if(!(r instanceof HTMLElement))return!1;const u=r.classList;return u.contains(`${t}-in`)||u.contains(`${t}-out`)||Array.from(u).some(d=>d.startsWith(`${t}-`)&&!d.includes("scroll")&&!s.has(d))?!0:!ze(r)})}function ts(e,t){return Array.from(e).some(n=>n.startsWith(t)&&n.includes("-out"))}function at(e,t,n){e.setAttribute(`data-${t}-run`,""),e.setAttribute(`data-${t}-${n}-run`,"")}function ct(e,t,n){const s=e.style.animationName;e.style.animationName="none",e.removeAttribute(`data-${t}-run`),n?e.removeAttribute(`data-${t}-${n}-run`):(e.removeAttribute(`data-${t}-in-run`),e.removeAttribute(`data-${t}-out-run`)),e.offsetWidth,e.style.animationName=s}const ns=[0,.2],ut=new WeakSet;function dt(e,t){if(ut.has(e))return;ut.add(e);const n=r=>{r.target===e&&(e.hasAttribute(`data-${t}-in-run`)||e.hasAttribute(`data-${t}-out-run`))&&e.setAttribute(`data-${t}-animating`,"")},s=r=>{r.target===e&&e.removeAttribute(`data-${t}-animating`)};e.addEventListener("animationstart",n),e.addEventListener("animationend",s),e.addEventListener("animationcancel",s)}function _e(e={}){const{prefix:t="anim",once:n=!0}=e;if(Qn())return()=>{};const s=Zn(),r=new WeakSet;let u=typeof window<"u"&&(window.pageYOffset||window.scrollY)||0,c=!0;const a=()=>{const m=window.pageYOffset||window.scrollY||0;c=m>=u,u=m};typeof window<"u"&&window.addEventListener("scroll",a,{passive:!0});const d=new IntersectionObserver(m=>{for(const p of m){const b=p.target;if(!lt(b)||b.hasAttribute(`data-${t}-animating`))continue;const w=ts(b.classList,t);p.isIntersecting?(w&&ct(b,t,"out"),at(b,t,"in"),n&&d.unobserve(b)):n||(c||ct(b,t,"in"),w&&at(b,t,"out"))}},{threshold:ns}),i=m=>{const p=es(m||document,t);for(const b of p)r.has(b)||(r.add(b),d.observe(b),dt(b,t))};i();let f,x=null,h=null;if(s)(()=>{h==null&&(h=requestAnimationFrame(()=>{h=null;const p=Te(void 0,t);for(const b of p)$e(b,t)}))})(),x=new MutationObserver(p=>{for(const b of p)if(b.type==="attributes"){const w=b.target;w instanceof HTMLElement&&($e(w,t),lt(w)&&(r.has(w)||(r.add(w),d.observe(w),dt(w,t))))}else if(b.type==="childList"&&b.addedNodes&&b.addedNodes.length){for(const w of Array.from(b.addedNodes))if(w instanceof HTMLElement){const L=Te(w,t);for(const E of L)$e(E,t);i(w)}}}),x.observe(document.documentElement,{subtree:!0,childList:!0,attributes:!0,attributeFilter:["class",`data-${t}-scroll`,`data-${t}-start`,`data-${t}-end`,`data-${t}-paused`,`data-${t}-run`]}),f=()=>{h!=null&&cancelAnimationFrame(h),x&&x.disconnect()};else{let m;Te(void 0,t).length>0&&Promise.resolve().then(()=>require("./scrollDriven.js")).then(b=>{m=b.initScrollViewFallback({once:n})}),f=()=>{typeof m=="function"&&m()}}return()=>{f&&f(),typeof window<"u"&&window.removeEventListener("scroll",a),d.disconnect()}}const ss=_e,rs=_e,be=({anchorRef:e,position:t="bottom",children:n,style:s,...r})=>{const c=`--anchor-${o.useId().replace(/:/g,"")}`,[a,d]=o.useState(!1);if(o.useLayoutEffect(()=>{typeof CSS<"u"&&CSS.supports("anchor-name","--a")&&d(!0)},[]),o.useLayoutEffect(()=>{if(a&&e.current){const f=e.current;return f.style.anchorName=c,()=>{e.current&&(e.current.style.anchorName="")}}},[a,e,c]),a){const f={position:"fixed",margin:0,zIndex:9999,positionAnchor:c,positionArea:t,positionTryFallbacks:"flip-block, flip-inline",...s};return Ve.createPortal(l.jsx("div",{style:f,...r,children:n}),document.body)}const i={position:"absolute",pointerEvents:"auto",...s};switch(t){case"top":i.bottom="100%",i.left="50%",i.transform="translateX(-50%)";break;case"top-left":i.bottom="100%",i.left=0;break;case"top-right":i.bottom="100%",i.right=0;break;case"bottom":i.top="100%",i.left="50%",i.transform="translateX(-50%)";break;case"bottom-left":i.top="100%",i.left=0;break;case"bottom-right":i.top="100%",i.right=0;break;case"left":i.right="100%",i.top="50%",i.transform="translateY(-50%)";break;case"right":i.left="100%",i.top="50%",i.transform="translateY(-50%)";break}return l.jsx(St,{targetRef:e,children:l.jsx("div",{style:i,...r,children:n})})},Et=({variant:e,disableTextMargins:t,disabled:n,iconPosition:s,icon:r,isActive:u,loading:c,shape:a,onToggle:d,size:i,allowShapeTransformation:f})=>({button:y(" relative cursor-pointer group/button outline-none inline-block flex w-fit justify-center items-center ",i==="xSmall"&&"text-label-large px-3 py-1.5 gap-1",i==="small"&&"text-label-large px-4 py-2.5 gap-2",i==="medium"&&"text-title-medium px-6 py-4 gap-2",i==="large"&&"text-headline-small px-12 py-8 gap-3",i==="xLarge"&&"text-headline-large px-16 py-12 gap-4",a==="rounded"&&{"rounded-[30px]":i==="xSmall"||i=="small","rounded-[40px]":i==="medium","rounded-[70px]":i==="large"||i=="xLarge"},(a==="squared"||f&&u)&&{"rounded-[12px]":i==="xSmall"||i=="small","rounded-[16px]":i==="medium","rounded-[28px]":i==="large"||i=="xLarge"},f&&!n&&{"active:rounded-[12px]":i==="xSmall"||i=="small","active:rounded-[16px]":i==="medium","active:rounded-[28px]":i==="large"||i=="xLarge"},e==="elevated"&&{"shadow-1 hover:shadow-2":!n,"bg-surface-container-low text-primary":!n&&!u,"bg-primary text-on-primary":!n&&u,"text-on-surface/[38%]":n},e==="filled"&&{"hover:shadow-1":!n,"bg-surface-container text-on-surface-variant":!n&&!u&&d,"bg-primary text-on-primary":!n&&(u&&d||!d),"text-on-surface/[38%]":n},e==="tonal"&&{"hover:shadow-1":!n,"bg-secondary-container text-on-secondary-container":!n&&!u,"bg-secondary text-on-secondary":!n&&u,"text-on-surface/[0.38]":n},e==="outlined"&&[" border",{"border-on-surface/[0.12] text-on-surface/[0.38]":n,"text-primary border-outline focus:border-primary":!n&&!u,"text-inverse-on-surface bg-inverse-surface border-inverse-surface":!n&&u}],e==="text"&&["w-fit",{"text-primary":!n,"text-on-surface/[0.38]":n},t&&[i==="xSmall"&&"-mx-3 ",i==="small"&&"-mx-4 ",i==="medium"&&"-mx-6 ",i==="large"&&"-mx-12",i==="xLarge"&&"-mx-16 "]],n&&"cursor-default"),touchTarget:y("absolute -translate-x-1/2 -translate-y-1/2 left-1/2 top-1/2 h-12 w-full"),stateLayer:y("overflow-hidden",a==="rounded"&&{"rounded-[30px]":i==="xSmall"||i=="small","rounded-[40px]":i==="medium","rounded-[70px]":i==="large"||i=="xLarge"},(a==="squared"||f&&u)&&{"rounded-[12px]":i==="xSmall"||i=="small","rounded-[16px]":i==="medium","rounded-[28px]":i==="large"||i=="xLarge"},f&&!n&&{"group-active/button:rounded-[12px]":i==="xSmall"||i=="small","group-active/button:rounded-[16px]":i==="medium","group-active/button:rounded-[28px]":i==="large"||i=="xLarge"}),label:y({invisible:c}),icon:y({invisible:c},i==="xSmall"&&"size-5",i==="small"&&"size-5",i==="medium"&&"size-6",i==="large"&&"size-8",i==="xLarge"&&"size-10")}),os=ne("button",Et),Nt=Z("button",Et),kt=({variant:e,interactive:t})=>({card:y(" rounded-xl overflow-hidden ",e==="outlined"&&"bg-surface border border-outline-variant",e==="elevated"&&"bg-surface-container-low shadow-1",e==="filled"&&"bg-surface-container-highest",{"group/card cursor-pointer":t})}),is=ne("card",kt),jt=Z("card",kt),Ye=()=>({carouselItem:y("rounded-[28px] overflow-hidden flex-none",{})}),ls=ne("carouselItem",Ye),Lt=Z("carouselItem",Ye),Mt=()=>({carousel:y(["w-full h-[400px]"]),track:y("flex h-full w-full")}),as=ne("carousel",Mt),It=Z("carousel",Mt),Ct=({isChecked:e,isIndeterminate:t,isDisabled:n,isError:s,isFocused:r,isHovered:u})=>({checkbox:y("inline-flex items-center justify-center relative size-4.5 ",{"pointer-events-none opacity-[0.38]":n}),input:y("absolute inset-0 w-full h-full opacity-0 z-10 cursor-pointer"),container:y("relative flex items-center justify-center w-[18px] h-[18px] "),box:y("absolute left-1/2 top-1/2 -translate-1/2 to rounded-[2px] size-4 border-2 transition-colors duration-200",!e&&!t&&{"border-on-surface-variant":!s&&!n,"border-error":s&&!n,"border-on-surface":n},(e||t)&&{"bg-primary border-primary":!s&&!n,"bg-error border-error":s&&!n,"bg-on-surface border-on-surface":n}),icon:y("z-10 relative text-on-primary w-full h-full flex items-center justify-center pointer-events-none",{"text-on-error":s&&!n,"text-surface":n}),stateLayer:"size-10 state-ripple-group-[checkbox] rounded-full cursor-pointer pointer-events-auto absolute left-1/2 top-1/2 -translate-x-1/2 -translate-y-1/2"}),cs=ne("checkbox",Ct),Rt=Z("checkbox",Ct),Dt=({variant:e,disabled:t,trailingIcon:n,icon:s,isActive:r,isInteractive:u,activated:c,isFocused:a,isDragging:d,isEditing:i})=>({chip:y(" group/chip px-3 py-1.5 rounded-lg flex items-center gap-2 outline-none",{"pl-2":s,"pr-2":n,"cursor-pointer":!t&&u},{" text-on-surface-variant":!c&&!a||i,"bg-secondary-container text-on-secondary-container":(c||a)&&!i},d&&["opacity-100 cursor-grabbing shadow-3"],e==="outlined"&&["border border-outline-variant",{"border-transparent":i}],e==="elevated"&&!i&&["shadow-1 bg-surface-container-low","border border-outline-variant"]),stateLayer:y("rounded-lg overflow-hidden",{}),label:y("outline-none text-nowrap",{"opacity-[0.38]":t}),leadingIcon:y("text-primary size-[18px]",{"opacity-[0.38]":t}),trailingIcon:y("cursor-pointer size-[18px]",{"opacity-[0.38]":t})}),us=ne("chip",Dt),At=Z("chip",Dt),Ft=({scrollable:e})=>({chips:y(" flex gap-3 outline-none",{"flex-wrap":!e,"overflow-x-auto":e})}),ds=ne("chips",Ft),Pt=Z("chips",Ft),$t=({orientation:e})=>({divider:y("border-outline-variant ",{"h-fit w-full border-t":e==="horizontal"},{"h-auto self-stretch w-fit border-l":e==="vertical"})}),fs=ne("divider",$t),Tt=Z("divider",$t),Wt=({size:e,variant:t,extended:n})=>({fab:y("flex shadow-3 hover:shadow-4 group/fab overflow-hidden outline-none items-center cursor-pointer",{"rounded-[12px]":e=="small","rounded-[16px]":e=="medium","rounded-[28px]":e=="large"},{"p-2":e=="small","p-4":e=="medium","p-[30px]":e=="large"},t==="primary"&&"bg-primary text-on-primary",t==="secondary"&&"bg-secondary text-on-secondary",t==="tertiary"&&"bg-tertiary text-on-tertiary",t==="primaryContainer"&&"bg-primary-container text-on-primary-container",t==="secondaryContainer"&&"bg-secondary-container text-on-secondary-container",t==="tertiaryContainer"&&"bg-tertiary-container text-on-tertiary-container"),icon:y({"size-6":e=="small"||e=="medium","size-9":e=="large"}),label:y("text-nowrap",{"text-title-medium":e=="small","text-title-large":e=="medium","text-headline-small":e=="large"})}),hs=ne("fab",Wt),Bt=Z("fab",Wt),Ot=({size:e,variant:t,open:n})=>({fabMenu:y("relative inline-flex flex-col items-end"),actions:y("flex flex-col gap-1 items-end absolute bottom-[calc(100%_+_8px)] right-0"),label:y("text-nowrap")}),ms=ne("fabMenu",Ot),Ht=Z("fabMenu",Ot),Vt=({variant:e,disabled:t,onToggle:n,isActive:s,size:r,width:u,shape:c,allowShapeTransformation:a})=>({iconButton:y("rounded-full relative flex transition-all duration-300","group/icon-button cursor-pointer",{"cursor-default":t},c==="rounded"&&{"rounded-[30px]":r==="xSmall"||r=="small","rounded-[40px]":r==="medium","rounded-[70px]":r==="large"||r=="xLarge"},(c==="squared"||a&&s)&&{"rounded-[12px]":r==="xSmall"||r=="small","rounded-[16px]":r==="medium","rounded-[28px]":r==="large"||r=="xLarge"},a&&!t&&{"active:rounded-[12px]":r==="xSmall"||r=="small","active:rounded-[16px]":r==="medium","active:rounded-[28px]":r==="large"||r=="xLarge"},e==="filled"&&[!t&&{"bg-surface-container":!s&&!!n,"bg-primary":s||!n},!!t&&"bg-on-surface/[0.12]"],e==="tonal"&&[!t&&{"bg-secondary-container text-on-secondary-container":!s&&!!n,"bg-secondary text-on-secondary":s||!n},!!t&&"bg-on-surface/[0.12]"],e==="outlined"&&[!t&&{"border border-outline":!s,"border border-transparent bg-inverse-surface":s},!!t&&{"border border-on-surface/[0.12]":!s,"border border-transparent bg-on-surface/[0.12]":s}]),touchTarget:y("absolute -translate-x-1/2 -translate-y-1/2 left-1/2 top-1/2 h-12 w-full"),stateLayer:y("absolute top-0 left-0 h-full w-full overflow-hidden",(c==="rounded"||c==="squared"&&n&&!t&&s&&a)&&{"rounded-[30px]":r==="xSmall"||r=="small","rounded-[40px]":r==="medium","rounded-[70px]":r==="large"||r=="xLarge"},(c==="squared"||c==="rounded"&&n&&!t&&s&&a)&&{"rounded-[12px]":r==="xSmall"||r=="small","rounded-[16px]":r==="medium","rounded-[28px]":r==="large"||r=="xLarge"},a&&!t&&{"group-active/icon-button:rounded-[12px]":r==="xSmall"||r=="small","group-active/icon-button:rounded-[16px]":r==="medium","group-active/icon-button:rounded-[28px]":r==="large"||r=="xLarge"},!t&&[e==="standard"&&{"state-on-surface-variant":!s,"state-primary":s},e==="filled"&&{"state-primary":!s&&!!n,"state-inverse-on-surface":s||!n},e==="tonal"&&{"state-on-surface-variant":!s&&!!n,"state-on-secondary-container":s||!n},e==="outlined"&&{"state-on-surface-variant":!s,"state-on-primary":s}]),icon:y(" transition-all duration-300",{"size-5 p-1.5":r==="xSmall"},{"size-6 p-2":r==="small"},{"size-6 p-4":r==="medium"},{"size-8 p-8":r==="large"},{"size-10 p-12":r==="xLarge"},u=="narrow"&&[{"px-1":r==="xSmall"},{"px-1":r==="small"},{"px-3":r==="medium"},{"px-4":r==="large"},{"px-8":r==="xLarge"}],u=="wide"&&[{"px-2.5":r==="xSmall"},{"px-3.5":r==="small"},{"px-6":r==="medium"},{"px-12":r==="large"},{"px-[72px]":r==="xLarge"}],!t&&[e==="standard"&&{"text-on-surface-variant":!s,"text-primary":s},e==="filled"&&{"text-primary":!s&&!!n,"text-on-primary":s||!n},e==="outlined"&&{"text-on-surface-variant":!s,"text-inverse-on-surface":s}],!!t&&"text-on-surface/[0.38]")}),ps=ne("iconButton",Vt),zt=Z("iconButton",Vt),_t=({variant:e,hasGroups:t})=>({menu:y("z-50 min-w-[112px] max-w-[280px] max-h-[300px] ","flex flex-col",{"overflow-y-auto":!t},{"bg-surface-container":!e||e==="standard","bg-tertiary-container text-on-tertiary-container":e==="vibrant","py-0.5 shadow-2 px-1 rounded-2xl":!t,"bg-transparent ":t})}),ys=ne("menu",_t),Yt=Z("menu",_t),qt=({variant:e})=>({menuGroup:y("flex flex-col gap-0.5 mb-0.5 last:mb-0","rounded-lg py-0.5 px-1 shadow-2 first:rounded-t-2xl last:rounded-b-2xl",{"bg-surface-container":e==="standard","bg-tertiary-container text-on-tertiary-container":e==="vibrant"}),groupLabel:y("px-3 pt-2 text-label-small tracking-wide ",{"text-on-surface-variant":e==="standard","text-on-tertiary-container opacity-80":e==="vibrant"})}),xs=ne("menuGroup",qt),Ut=Z("menuGroup",qt),Xt=({variant:e,isVisible:t})=>({progressIndicator:y((e==="linear-determinate"||e=="linear-indeterminate")&&"flex w-full h-1",e==="linear-indeterminate"&&"relative overflow-hidden rounded-full"),firstTrack:y((e==="linear-determinate"||e==="linear-indeterminate")&&"h-full rounded-full bg-primary-container",{"max-h-0":!t,"max-h-full":t}),activeIndicator:y("h-full rounded-full bg-primary",e==="linear-determinate"&&{"rounded-l-full":!0},(e==="linear-indeterminate"||e==="linear-determinate")&&{"max-h-0":!t,"max-h-full":t},(e==="circular-determinate"||e=="circular-indeterminate")&&["stroke-primary fill-transparent ",{"stroke-[4px]":t,"stroke-[0px]":!t}]),lastTrack:y((e==="linear-determinate"||e=="linear-indeterminate")&&"h-full flex-1 rounded-full bg-primary-container",{"max-h-0":!t,"max-h-full":t}),stop:y("absolute top-1/2 -translate-y-1/2 right-0 bg-primary rounded-full size-1",{"max-h-0":!t,"max-h-full":t})}),vs=ne("progressIndicator",Xt),Gt=Z("progressIndicator",Xt),qe=({variant:e,position:t})=>({sideSheet:y("bg-surface flex justify-between max-w-xs z-10",{"flex-row-reverse":t=="right","h-full":e=="standard"},e=="modal"&&["rounded-2xl fixed top-0 m-[1rem] h-[calc(100dvh-2rem)]",{"right-0":t=="right","left-0":t=="left"}]),container:y("w-full overflow-hidden flex flex-col",{}),header:y("p-4 flex items-center gap-2"),content:y("flex-1 overflow-y-auto"),title:y("text-on-surface-variant text-title-large"),closeButton:y("ml-auto"),divider:y({hidden:e=="modal"}),overlay:y("bg-[black]/[0.32] fixed top-0 left-0 w-screen h-screen")}),Kt=ne("sideSheet",qe),gs=Z("sideSheet",qe),Ue=({isChanging:e})=>({slider:y(["relative w-full h-11 flex items-center rounded gap-x-1.5 cursor-pointer min-w-32"]),activeTrack:y(["h-4 relative transition-all duration-100 bg-primary overflow-hidden rounded-l-full "]),inactiveTrack:y(["h-4 relative transition-all duration-100 bg-primary-container rounded-r-full overflow-hidden"]),handle:y(["transform relative transition-all duration-100 bg-primary h-full rounded-full ",{"w-0.5":e,"w-1":!e}]),valueIndicator:y(["absolute select-none bg-inverse-surface text-inverse-on-surface py-3 px-4 text-label-large rounded-full bottom-[calc(100%+4px)] transform left-1/2 -translate-x-1/2"]),dot:y(["h-1 w-1 absolute transform -translate-y-1/2 -translate-x-1/2 top-1/2 rounded-full"])}),ws=ne("slider",Ue),Jt=Z("slider",Ue),Zt=()=>({snackbar:y(" rounded bg-inverse-surface "),container:y("pl-4 pr-2 max-w-full py-1 flex items-center flex-wrap"),supportingText:y("text-body-medium text-inverse-on-surface "),icon:y(" ml-auto mr-0 text-inverse-on-surface block dark")}),bs=ne("snackbar",Zt),Qt=Z("snackbar",Zt),en=({isSelected:e,disabled:t,inactiveIcon:n})=>({switch:y("group/switch w-[52px] h-[32px] outline-none rounded-full border-2 flex items-center",{"bg-on-surface/[0.12] border-transparent":t},!t&&["cursor-pointer ",{"bg-primary border-primary":e},{"bg-surface-container border-outline":!e}]),handleContainer:y("flex items-center justify-center absolute",{"left-[14px]":!e},{"right-[14px]":e}),handle:y("transition-all duration-100 z-10 rounded-full flex items-center justify-center",{"w-[16px] h-[16px]":!e&&!n},{"w-[24px] h-[24px]":!(!e&&!n)},!t&&["cursor-pointer group-active/switch:h-[28px] group-active/switch:w-[28px]",{"bg-on-primary group-hover/switch:bg-primary-container":e},{"bg-outline group-hover/switch:bg-on-surface-variant":!e}],{"bg-surface":t}),handleStateLayer:y("w-[40px] h-[40px] -z-10 rounded-full absolute",{"group-state-primary":!t}),icon:y("w-[16px] h-[16px]",!t&&[{"text-on-primary-container":e},{"text-on-primary":!e}],{"text-on-surface/[0.38]":t})}),Ss=ne("switch",en),tn=Z("switch",en),nn=({isSelected:e,icon:t,label:n,variant:s})=>({tab:y("flex-1 group/tab outline-none flex px-4 justify-center items-center cursor-pointer",{"z-10":e},!!(t&&n)&&s==="primary"&&"h-16",!(t&&n&&s==="primary")&&"h-12"),stateLayer:y("absolute w-full h-full overflow-hidden left-1/2 top-1/2 transform -translate-y-1/2 -translate-x-1/2",s==="primary"&&{"group-hover/tab:hover-state-on-surface group-focus-visible/tab:focus-state-on-surface":!e,"group-hover/tab:hover-state-primary group-focus-visible/tab:focus-state-primary":e},s==="secondary"&&"group-hover/tab:hover-state-on-surface group-focus-visible/tab:focus-state-on-surface"),content:y("flex gap-0.5 h-full justify-center",{relative:s=="primary"},{"":!!(n&&!t)},s==="primary"&&"flex-col items-center",s==="secondary"&&{"flex-col items-center":!(n&&t),"flex-row items-center gap-2":!!(n&&t)}),icon:y("h-6 w-6 p-0.5 !box-border",s==="primary"&&{"text-on-surface-variant":!e,"text-primary":e},s==="secondary"&&{"text-on-surface-variant":!e,"text-on-surface":e}),label:y("text-title-small text-nowrap",s==="primary"&&{"text-on-surface-variant":!e,"text-primary":e},s==="secondary"&&{"text-on-surface-variant":!e,"text-on-surface":e}),underline:y("bg-primary absolute w-full left-0 bottom-0",s==="primary"&&"h-[3px] rounded-t",s==="secondary"&&"h-0.5")}),Es=ne("tab",nn),sn=Z("tab",nn),rn=({scrollable:e})=>({tabs:y("border-b border-surface-container-highest bg-surface","flex relative ",{"overflow-x-auto":e})}),Ns=ne("tabs",rn),on=Z("tabs",rn),ln=()=>({tabPanels:y("overflow-hidden")}),ks=ne("tabPanels",ln),an=Z("tabPanels",ln),cn=()=>({tabPanel:y("")}),js=ne("tabPanel",cn),un=Z("tabPanel",cn),dn=({disabled:e,leadingIcon:t,trailingIcon:n,variant:s,errorText:r,isFocused:u,value:c,suffix:a,multiline:d})=>({textField:y({"opacity-[.38]":e}),content:y("group/text-field transition-border duration-200 relative flex items-center ",{"h-14":!d},{"border-on-surface-variant":!(r!=null&&r.length)&&!u&&s=="filled","border-outline":!(r!=null&&r.length)&&!u&&s=="outlined","border-primary":!(r!=null&&r.length)&&u,"border-error":!!(r!=null&&r.length)},{"bg-on-surface/[0.04]":e},s=="filled"&&["rounded-t overflow-hidden border-b",{"bg-surface-container-highest":!e}],s=="outlined"&&["border rounded box-border",{"border-[3px]":u}]),stateLayer:y("absolute -z-10 w-full h-full top-0 left-0",{hidden:s=="outlined"},{"group-state-on-surface":!e,"focus-state-on-surface":u}),label:y("inline-flex outline-none whitespace-nowrap",{"text-on-surface-variant":!e&&!(r!=null&&r.length)},{"text-on-surface":e},{"text-error":!!(r!=null&&r.length)},{"text-primary":!(r!=null&&r.length)&&u}),input:y("w-full resize-none px-4 text-body-large bg-[inherit] outline-none autofill:transition-colors autofill:duration-[5000000ms]",{" text-on-surface placeholder:text-on-surface-variant":!e,"placeholder:text-on-surface text-on-surface":e},{"pr-0":!!a},s=="filled"&&" pb-2 pt-6",s=="outlined"&&"py-4 relative z-10"),activeIndicator:y("absolute w-0 inset-x-0 border-rounded mx-auto bottom-0",s=="filled"&&["h-[2px] transition-all duration-300",{"bg-primary":!(r!=null&&r.length)},{"bg-error":!!(r!=null&&r.length)},{"!w-full":u}]),supportingText:y(" text-body-small px-4 pt-1",{"text-on-surface-variant":!e&&!(r!=null&&r.length)},{"text-on-surface":e},{"!w-full":u},{"text-error":!!(r!=null&&r.length)}),leadingIcon:y(["h-12 ml-3 flex items-center justify-center",{"cursor-text":!o.isValidElement(t)}]),trailingIcon:y("h-12 w-12 flex items-center justify-center",{"cursor-text":!o.isValidElement(n)}),suffix:y("text-on-surface-variant pl-0 pr-4",s=="filled"&&" pb-2 pt-6",s=="outlined"&&"py-4 relative z-10")}),Ls=ne("textField",dn),fn=Z("textField",dn),hn=({position:e,variant:t})=>({toolTip:y(" pointer-events-auto w-max z-10 absolute m-1 w-max-content max-w-[312px]",t=="rich"&&"bg-surface-container rounded-2xl text-on-surface-container shadow-2",t=="plain"&&"bg-inverse-surface rounded text-inverse-on-surface ",{"bottom-full left-1/2 -translate-x-1/2":e=="top","top-full left-1/2 -translate-x-1/2":e=="bottom","right-full top-1/2 -translate-y-1/2":e=="left","left-full top-1/2 -translate-y-1/2":e=="right","bottom-full right-full":e=="top-left","bottom-full left-full":e=="top-right","top-full right-full":e=="bottom-left","top-full left-full":e=="bottom-right"}),container:y("pb-2",t=="rich"&&"px-4 pt-3 ",t=="plain"&&"px-2 py-1"),actions:y("flex gap-10 px-1 mt-2",t=="plain"&&"hidden"),subHead:y("text-title-small mb-1",t=="plain"&&"hidden"),supportingText:y(""),content:y("w-full")}),Ms=ne("toolTip",hn),mn=Z("toolTip",hn),le=({icon:e,colors:t=[],className:n,...s})=>{if(typeof e=="string"){let f=e,x="";return t[0]&&(x=` fill="${t[0]}" color="${t[0]}"`,f=f.replace(/<path([^>]*?)>/g,'<path$1 fill="currentColor">')),f=f.replace(/<svg([^>]*)>/,(h,m)=>`<svg${m.replace(/\s+(width|height)=["'][^"']*["']/g,"")} width="100%" height="100%"${x}>`),l.jsx("div",{className:y("size-5 box-content inline-flex fill-current",n),style:{color:t[0]||""},dangerouslySetInnerHTML:{__html:f}})}if(e&&typeof e=="object"&&"src"in e){const f=e;return l.jsx("img",{src:f.src,width:f.width,height:f.height,className:y("size-5 box-content",n),style:{filter:t[0]?"brightness(0) saturate(100%) invert(1)":void 0},alt:"","aria-hidden":"true"})}const r=e;if(!(r!=null&&r.prefix))throw new Error(`Invalid icon type: ${typeof e}`);const{icon:u}=r,[c,a,,,d]=u||[],i=f=>{switch(f.length){case 2:return{"--fa-primary-color":f[0]||"inherit","--fa-secondary-color":f[1]||"inherit"};case 1:return{color:f[0]};default:return{}}};return l.jsx("svg",{className:y("size-5 box-content",n),style:{...i(t)},xmlns:"http://www.w3.org/2000/svg",viewBox:`0 0 ${c} ${a}`,role:"img","aria-hidden":"true",...s,children:typeof d=="string"?l.jsx("path",{className:"fill-current",d}):d.map((f,x)=>l.jsx("path",{d:f},x))})},pn=({variant:e="linear-determinate",value:t=0,transitionDuration:n=1e3,className:s,...r})=>{const[u,c]=o.useState(t),[a]=o.useState(1.5);o.useEffect(()=>{t>100&&(t=100),t<0&&(t=0),c(t)},[t]);const[d,i]=o.useState(!0),f=()=>d?a:a*.5;o.useEffect(()=>{if(e==="circular-indeterminate"&&u!==100){const p=setInterval(()=>{c(d?20:40),i(!d)},f()*1e3);return()=>clearInterval(p)}},[e,d,u]);const[x,h]=o.useState(!1);o.useEffect(()=>{if(u>=100){const p=setTimeout(()=>{h(!1)},n);return()=>{clearTimeout(p)}}else h(!0)},[u,n]);const m=Gt({className:s,variant:e,value:t,transitionDuration:n,isVisible:x});return l.jsxs(l.Fragment,{children:[e==="linear-indeterminate"&&l.jsxs("div",{className:m.progressIndicator,...r,children:[l.jsx(Y.motion.div,{animate:{width:["0%","0%","0%","20%"],marginLeft:["0px","0px","6px","6px"],marginRight:["0px","0px","6px","6px"]},transition:{duration:1.5,repeat:1/0,ease:"easeInOut",times:[0,.499,.5,1]},style:{flexShrink:0},className:m.activeIndicator}),l.jsx(Y.motion.div,{animate:{width:["0%","40%","100%"]},transition:{duration:1.5,repeat:1/0,ease:"easeInOut"},style:{flexShrink:0},className:m.firstTrack}),l.jsx(Y.motion.div,{animate:{width:["20%","60%","20%"]},transition:{duration:1.5,repeat:1/0,ease:"easeInOut",times:[0,.5,1]},style:{flexShrink:0,marginLeft:"6px"},className:m.activeIndicator}),l.jsx("div",{style:{marginLeft:"6px"},className:m.lastTrack})]}),e==="linear-determinate"&&l.jsxs("div",{className:m.progressIndicator,...r,children:[l.jsx("div",{style:{width:`${u}%`,transition:`width ${n}ms ease-in-out ${u==100?", max-height 200ms 0.5s ease-in-out":""}`},className:m.activeIndicator}),l.jsx("div",{style:{marginLeft:u!=100?"6px":"0px",transition:`width ${n}ms ease-in-out ${u==100?`, max-height 200ms 0.5s ease-in-out, margin-left ${n}ms ${n/1.5}ms`:""}`},className:m.lastTrack}),l.jsx("div",{style:{width:"4px",transition:`width ${n}ms ease-in-out, max-height 200ms 0.5s ease-in-out`},className:m.stop})]}),(e==="circular-determinate"||e=="circular-indeterminate")&&l.jsx(Y.motion.svg,{width:"48",height:"48",viewBox:"0 0 48 48",initial:{rotate:-90},animate:{rotate:e==="circular-indeterminate"?270:-90},transition:e==="circular-indeterminate"?{repeat:1/0,duration:f(),ease:"linear"}:{duration:n/1e3},className:m.progressIndicator,...r,children:l.jsx(Y.motion.circle,{cx:"50%",cy:"50%",r:x?"calc(50% - 2px)":"50%",style:{strokeLinecap:"round"},initial:e==="circular-indeterminate"?"hidden":"determinate",animate:e==="circular-indeterminate"?"visible":"determinate",className:m.activeIndicator,variants:{hidden:{pathLength:d?10/100:90/100},visible:{pathLength:d?90/100:10/100},determinate:{pathLength:u/100}},transition:{pathLength:e==="circular-indeterminate"?{type:"tween",ease:"linear",duration:f(),bounce:0}:{type:"tween",ease:"easeInOut",duration:n/1e3}}})},e==="circular-indeterminate"?d+"":"static")]})};function Is(e){const t={primary:"filled",secondary:"tonal"};return e&&e in t?t[e]:e||"filled"}const me=({variant:e="filled",disabled:t=!1,icon:n,href:s,label:r,disableTextMargins:u,className:c,iconPosition:a="left",loading:d=!1,shape:i="rounded",onClick:f,onToggle:x,activated:h,ref:m,size:p="medium",allowShapeTransformation:b=!0,transition:w,children:L,...E})=>{if(L&&(r=L),!r)throw new Error("Button component requires either a label prop or children content");e=Is(e);const g=s?"a":"button",F=o.useRef(null),I=m||F,[v,N]=o.useState(h);o.useEffect(()=>{N(h)},[h]),w={duration:.3,...w};const R=j=>{t&&j.preventDefault(),x?(N(!v),x(!v)):f&&f(j)},M=Nt({allowShapeTransformation:b,size:p,disableTextMargins:u,shape:i,href:s,disabled:t,icon:n,iconPosition:a,loading:d,variant:e,transition:w,className:c,isActive:v??!1,onToggle:x,activated:v,label:r,children:r}),W=n?l.jsx(le,{icon:n,className:M.icon}):l.jsx(l.Fragment,{});return l.jsxs(g,{ref:I,href:s,className:M.button,...E,onClick:R,disabled:t,"aria-pressed":x?v:void 0,style:{transition:w.duration+"s"},children:[l.jsx("div",{className:M.touchTarget}),l.jsx(ue,{style:{transition:w.duration+"s"},className:M.stateLayer,colorName:y(e==="filled"&&{"on-surface-variant":!v&&!!x,"on-primary":v||!x},e==="elevated"&&{"on-primary":v&&!!x,primary:!v||!x},e==="tonal"&&{"on-secondary":v&&!!x,"on-secondary-container":!v||!x},e==="outlined"&&{"inverse-on-surface":v&&!!x,"on-surface-variant":!v||!x},e==="text"&&"primary"),stateClassName:"state-ripple-group-[button]"}),a==="left"&&W,d&&l.jsx("div",{className:"!absolute left-1/2 -translate-x-1/2 top-1/2 -translate-y-1/2",children:l.jsx(pn,{className:()=>({progressIndicator:"h-6 w-6",activeIndicator:y({"!stroke-primary":e==="elevated"&&!t,"!stroke-on-surface/[38%]":e==="elevated"&&t},{"!stroke-on-primary":e==="filled"&&!t,"!stroke-on-surface/[38%]":e==="filled"&&t},{"!stroke-on-secondary-container":e==="tonal"&&!t,"!stroke-on-surface/[38%]":e==="tonal"&&t},{"!stroke-primary":e==="outlined"&&!t,"!stroke-on-surface/[38%]":e==="outlined"&&t},{"!stroke-primary":e==="text"&&!t,"!stroke-on-surface/[38%]":e==="text"&&t})}),variant:"circular-indeterminate"})}),l.jsx("span",{className:M.label,children:r}),a==="right"&&W]})},Cs=({variant:e="outlined",className:t,children:n,interactive:s=!1,ref:r,...u})=>{const c=jt({className:t,interactive:s,variant:e,children:n}),a=o.useRef(null),d=r||a;return l.jsxs("div",{...u,ref:d,className:c.card,children:[s&&l.jsx(ue,{className:c.stateLayer,colorName:"on-surface",stateClassName:"state-ripple-group-[card]"}),n]})},ve=(e,t,n=[0,1])=>{const[s,r]=t,[u,c]=n,d=(Math.max(s,Math.min(e,r))-s)/(r-s);return u+d*(c-u)},yn=({className:e,children:t,width:n,index:s=0,outputRange:r,ref:u,...c})=>{const a=o.useRef(null),d=u||a,i=Lt({className:e,index:s,children:t});return l.jsx("div",{ref:d,style:{width:"var(--carousel-item-width, 100%)",maxWidth:r?r[1]+"px":void 0,minWidth:r?r[0]+"px":void 0},className:i.carouselItem,...c,children:t})},Rs=({variant:e="hero",className:t,children:n,ref:s,marginPourcent:r=0,inputRange:u=[.21,.65],outputRange:c=[42,300],gap:a=8,onChange:d,onMetricsChange:i,index:f,scrollSensitivity:x=1.25,...h})=>{const m=o.useRef(null),p=s||m,b=It({index:f,className:t,children:n,variant:e,inputRange:u,outputRange:c,marginPourcent:r,onChange:d,gap:a,scrollSensitivity:x,onMetricsChange:i}),w=o.Children.toArray(n).filter(A=>o.isValidElement(A)&&A.type===yn),L=o.useRef(null),E=o.useRef({scrollProgress:0,scrollTotal:0,scrollVisible:0,scroll:0}),g=o.useRef(0),F=o.useRef(null),I=o.useRef([]).current,[v,N]=o.useState(0);I.length!==w.length&&(I.length=0,w.forEach((A,T)=>{I[T]=o.createRef()}));const R=o.useCallback(()=>{if(!L.current||!p.current)return;const A=g.current,T=E.current.scrollVisible||p.current.clientWidth||0;function G(O,ee){return O.map((oe,pe)=>{const Se=(oe-ee)/Math.abs(O[1]-O[0]);return{itemScrollXCenter:oe,relativeIndex:Se,index:pe,width:0}})}const S=w.map((O,ee)=>{const oe=ee/Math.max(1,w.length-1);return ve(oe,[0,1],[0,1])}),k=G(S,A).sort((O,ee)=>O.index-ee.index);let C=T+a+c[0]+a,q=v;const U=k.sort((O,ee)=>Math.abs(O.relativeIndex)-Math.abs(ee.relativeIndex)).map((O,ee)=>{if(!(C<=0)){if(ee===0&&(q=O.index),O.width=ve(C-a,[c[0],c[1]],[c[0],c[1]]),C-=O.width+a,C!==0&&C<(c[0]+a)*2){const oe=O.width-((c[0]+a)*2-C);C+=O.width,O.width=oe,C-=O.width}else if(C===0&&O.width>=c[0]*2+a){const oe=O.width-(c[0]+a-C);C+=O.width,O.width=oe,C-=O.width}return O}}).filter(Boolean),J=[...U].reverse(),te=[...U].sort((O,ee)=>Math.abs(O.index)-Math.abs(ee.index));J.forEach((O,ee)=>{const oe=J[ee+1];if(!oe)return;const pe=1-(Math.abs(O.relativeIndex)-Math.abs(oe.relativeIndex)),Se=ve(pe,[0,2],[O.width+C,oe.width]);C+=O.width,O.width=Se,C-=O.width});const se=U.length/2,P=ve(Math.abs(te[0].relativeIndex),[te[0].index===0?0:se-1,se],[0,1]),_=ve(P,[0,1],[0,1])*-(c[0]+a);I.forEach((O,ee)=>{if(O.current){const oe=U.find(pe=>pe.index===ee);oe?(O.current.style.setProperty("--carousel-item-width",`${oe.width}px`),O.current.style.display="block"):(O.current.style.setProperty("--carousel-item-width",`${c[0]}px`),O.current.style.display="none")}}),L.current.style.transform=`translateX(${_}px)`,q!==v&&N(q)},[w.length,c,a,v]);o.useLayoutEffect(()=>{R()},[R,w.length]),o.useEffect(()=>{d&&d(v)},[v,d]);const[M,W]=o.useState(0);o.useEffect(()=>{W(v)},[v]);const j=(A,T={})=>{if(!w.length)return 0;const G=I[A];if(!G||!G.current||!L.current)return 0;const S=ve(A/Math.max(1,w.length-1),[0,1],[0,1]);return W(A),L.current.dispatchEvent(new CustomEvent("udx:customScroll:set",{bubbles:!0,detail:{progress:S,orientation:"horizontal",animate:T.animate!==!1}})),S};o.useEffect(()=>{typeof f=="number"&&w.length>0&&f!==v&&j(f)},[f,w.length]);const X=A=>{var T;if(E.current=A,A.scrollTotal>0){(T=F.current)==null||T.stop();const G=g.current??0,S=A.scrollProgress??0;F.current=Y.animate(G,S,{type:"spring",stiffness:260,damping:32,mass:.6,restDelta:5e-4,onUpdate:k=>{g.current=k,requestAnimationFrame(()=>{R()})}})}},V=o.useRef(i);o.useEffect(()=>{V.current=i},[i]);const Q=o.useRef(null);o.useEffect(()=>{const A=V.current;if(!A||!(p!=null&&p.current)||w.length<=0)return;const T=w.length,G=p.current.clientWidth||0,S=c[1],k=g.current,C=(G+a)/(S+a),q=Math.max(1,Math.floor(C)),U=Math.max(1,Math.round(q*(2/3))),J=Math.min(Math.max(0,v),Math.max(0,T-1)),te={total:T,selectedIndex:J,visibleApprox:C,visibleFull:q,stepHalf:U,canPrev:J>0,canNext:J<T-1,scrollProgress:k,viewportWidth:G,itemMaxWidth:S,gap:a},se=Q.current;let P=!se;if(!P){for(const _ in te)if(te[_]!==se[_]){P=!0;break}}P&&(Q.current=te,A(te))},[p,w.length,v,a,c]),o.useEffect(()=>()=>{var A;(A=F.current)==null||A.stop()},[]);const[z,$]=o.useState(0);o.useLayoutEffect(()=>{let A=c[1];const T=E.current;T&&A>T.scrollVisible&&T.scrollVisible>0&&(A=T.scrollVisible);const G=(A+a)*w.length/x;$(G||400)},[p,w.length,a,c,x]);const D=A=>{if(!w.length)return;const T=M??v;switch(A.key){case"ArrowLeft":A.preventDefault(),j(Math.max(0,T-1));break;case"ArrowRight":A.preventDefault(),j(Math.min(w.length-1,T+1));break;case"Home":A.preventDefault(),j(0);break;case"End":A.preventDefault(),j(w.length-1);break;case"Enter":case" ":A.preventDefault(),j(T);break}};o.useEffect(()=>{const A=p.current;if(!A)return;const T=G=>{const S=G.detail;S&&typeof S.index=="number"&&j(S.index)};return A.addEventListener("udx:carousel:centerIndex",T),()=>{A.removeEventListener("udx:carousel:centerIndex",T)}},[p,w.length]);const B=w.map((A,T)=>{var k;const G=(k=A.props)==null?void 0:k.onClick,S=C=>{G==null||G(C)};return o.cloneElement(A,{outputRange:c,ref:I[T],key:T,index:T,role:"option","aria-selected":v===T,tabIndex:v===T?0:-1,onClick:S,onFocus:()=>W(T)})});return l.jsx("div",{className:b.carousel,ref:p,role:"listbox","aria-orientation":"horizontal",onKeyDown:D,...h,children:l.jsx(vt,{draggable:!0,orientation:"horizontal",onScroll:X,scrollSize:z,children:l.jsx("div",{className:b.track,ref:L,style:{gap:`${a}px`,willChange:"transform"},children:B})})})};/*!
1
+ "use strict";var Dn=Object.defineProperty;var An=(e,t,n)=>t in e?Dn(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var H=(e,t,n)=>An(e,typeof t!="symbol"?t+"":t,n);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("react/jsx-runtime"),o=require("react"),Ve=require("react-dom"),Y=require("motion/react"),ht=require("clsx"),Fn=require("tailwind-merge"),we=require("@udixio/theme"),Oe=require("@udixio/tailwind"),Pn=require("react-textarea-autosize");var Pe=typeof document<"u"?document.currentScript:null;const mt=({colorName:e="on-surface",triggerRef:t})=>{const n={initial:{opacity:1,"--r":"25%"},animate:{opacity:1,"--r":"100%",transition:{duration:.5}},exit:{opacity:0,"--r":"100%",transition:{duration:.3}}},[s,r]=o.useState(!0),[u,c]=o.useState(!1),[a,d]=o.useState({x:50,y:50});o.useEffect(()=>{u&&(r(!0),r(!1))},[u]),o.useEffect(()=>{const p=t==null?void 0:t.current;if(p)return p.addEventListener("mousedown",i),p.addEventListener("mouseup",x),p.addEventListener("mouseleave",f),()=>{p.removeEventListener("mousedown",i),p.removeEventListener("mouseup",x),p.removeEventListener("mouseleave",f)}},[t]);const i=p=>{const b=t==null?void 0:t.current,w=b.getBoundingClientRect();c(!0),d({x:(p.clientX-w.left)/b.clientWidth*100,y:(p.clientY-w.top)/b.clientHeight*100})},f=p=>{c(!1)},x=p=>{c(!1)},h=`color-mix(in srgb, var(--state-color,_var(--color-${e})) 10%, transparent)`,m={position:"absolute",inset:0,width:"100%",height:"100%","--x":a.x+"%","--y":a.y+"%","--r":"0%",background:`radial-gradient(ellipse at var(--x) var(--y), ${h} var(--r), transparent calc(var(--r) * 2))`,pointerEvents:"none"};return l.jsx(Y.AnimatePresence,{mode:"wait",children:(u||!u&&!s)&&l.jsx(Y.motion.div,{style:m,variants:n,initial:"initial",animate:"animate",exit:"exit",onAnimationComplete:()=>r(!0)})})},pt=Fn.extendTailwindMerge({override:{classGroups:{"text-color":[{text:[e=>!e.startsWith("display-")&&!e.startsWith("headline-")&&!e.startsWith("title-")&&!e.startsWith("body-")&&!e.startsWith("label-")]}]}},extend:{classGroups:{font:[{text:[e=>e.startsWith("display-")||e.startsWith("headline-")||e.startsWith("title-")||e.startsWith("body-")||e.startsWith("label-")]}]},conflictingClassGroups:{font:["font"]}}}),y=(...e)=>pt(ht.clsx(e)),yt=(...e)=>pt(ht.clsx(e));function $n(e){return e.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase().normalize("NFD").replace(/[\u0300-\u036f]/g,"").replace(/[^a-z0-9]+/g,"-").replace(/^-+|-+$/g,"")}const Re=e=>{const t={};e.classNameList.forEach(s=>{var r;if(s)if(typeof s=="string")(t[r=e.default]??(t[r]=[])).push(s);else{const u=s(e.states);Object.entries(u).map(c=>{const[a,d]=c;(t[a]??(t[a]=[])).push(d)})}});const n=t;return Object.entries(t).map(s=>{let[r,u]=s;u=u.reverse(),r==e.default&&u.unshift("relative"),u.unshift($n(r)),n[r]=yt(...u)}),n},ne=(e,t)=>n=>Re({classNameList:[n.className,t],default:e,states:n}),Z=(e,t)=>n=>o.useMemo(()=>Re({classNameList:[n.className,t],default:e,states:n}),[n]);function Wn(e,t,n){return o.useMemo(()=>Re({classNameList:[n==null?void 0:n.className,t],default:e,states:n}),[e,t,n])}const xt=ne("customScroll",({orientation:e,draggable:t,isDragging:n})=>({customScroll:y("flex h-full w-full",t&&["[&::-webkit-scrollbar-track]:rounded-full","[&::-webkit-scrollbar-track]:bg-transparent","[&::-webkit-scrollbar-thumb]:rounded-full",{"[&::-webkit-scrollbar-thumb]:bg-outline":n,"[&::-webkit-scrollbar-thumb]:bg-transparent":!n},{"[&::-webkit-scrollbar]:h-2":e==="horizontal"},{"[&::-webkit-scrollbar]:w-2":e==="vertical"}],{"overflow-y-scroll flex-col":e==="vertical","overflow-x-scroll flex-row":e==="horizontal","cursor-grab":t&&!n,"cursor-grabbing":t&&n}),track:y("overflow-hidden flex-none sticky",{"left-0 h-full":e==="horizontal","top-0 w-full":e==="vertical"})}));function Tn(e,t){let n=0,s=null,r=null;const u=(c,a)=>{n=Date.now(),t(c,a)};return(c,a)=>{const d=Date.now(),i=e-(d-n);i<=0?(s&&(clearTimeout(s),s=null),u(c,a)):(r={v:c,o:a},s||(s=setTimeout(()=>{s=null;const f=r;r=null,f&&u(f.v,f.o)},i)))}}const vt=({children:e,orientation:t="vertical",scrollSize:n,onScroll:s,className:r,draggable:u=!1,throttleDuration:c=75,scroll:a,setScroll:d})=>{var G,S;const i=o.useRef(null),f=o.useRef(null),[x,h]=o.useState({width:null,height:null});o.useEffect(()=>{if(!i.current)return;const N=new ResizeObserver(C=>{for(const q of C)q.target===i.current&&h({width:q.contentRect.width,height:q.contentRect.height})});return N.observe(i.current),()=>{N.disconnect()}},[i]);const m=o.useRef(null),p=o.useRef(null),b=()=>{const N=f.current;return N?{width:n??N.scrollWidth,height:n??N.scrollHeight}:null},w=()=>{const N=i.current;return N?{width:N.clientWidth,height:N.clientHeight}:null},{scrollYProgress:L,scrollXProgress:E}=Y.useScroll({container:i}),g=o.useRef(null);g.current||(g.current=Tn(c,(N,C)=>{!p.current||!m.current||!i.current||(C===(t==="horizontal"?"x":"y")&&(d==null||d(N)),s&&(t==="horizontal"&&C==="x"&&s({scrollProgress:N,scroll:N*(m.current.width-i.current.clientWidth),scrollTotal:m.current.width-i.current.clientWidth,scrollVisible:p.current.width}),t==="vertical"&&C==="y"&&s({scrollProgress:N,scroll:N*(m.current.height-i.current.clientHeight),scrollTotal:m.current.height-i.current.clientHeight,scrollVisible:p.current.height})))}));const F=(N,C)=>{g.current&&g.current(N,C)};o.useEffect(()=>{x.width&&F(E.get(),"x"),x.height&&F(L.get(),"y")},[x]),o.useEffect(()=>{const N=i.current,C=f.current;if(!N||!C||typeof a!="number")return;const q=(U,J,te)=>Math.min(te,Math.max(J,U));if(t==="horizontal"){const U=Math.max(0,(n??C.scrollWidth)-N.clientWidth);N.scrollLeft=q(a*U,0,U)}else{const U=Math.max(0,(n??C.scrollHeight)-N.clientHeight);N.scrollTop=q(a*U,0,U)}},[a,t,n]),Y.useMotionValueEvent(E,"change",N=>{F(N,"x")}),Y.useMotionValueEvent(L,"change",N=>{F(N,"y")});const[I,v]=o.useState(!1);o.useLayoutEffect(()=>{I||!p.current||!m.current||!s||(s({scrollProgress:0,scroll:0,scrollTotal:t=="vertical"?m.current.height:m.current.width,scrollVisible:t=="vertical"?p.current.height:p.current.width}),v(!0))},[p,m,s]),m.current=b(),p.current=w();const[k,D]=o.useState(!1),M=xt({isDragging:k,children:e,className:r,onScroll:s,orientation:t,scrollSize:n,draggable:u,throttleDuration:c}),[T,j]=o.useState(0),[X,V]=o.useState(0),Q=N=>{if(!u)return;const C=i.current;if(!C||T==null)return;const U=(N.pageX-C.offsetLeft-T)*1.5;C.scrollLeft=X-U},z=N=>{const C=i.current;C&&(D(!0),j(N.pageX-C.offsetLeft),V(C.scrollLeft))},$=N=>{k&&(N.preventDefault(),Q(N))},R=()=>{D(!1)},O=()=>{D(!1)},A=N=>{N.preventDefault()},W=o.useRef(null);return o.useEffect(()=>()=>{W.current&&clearTimeout(W.current)},[]),o.useEffect(()=>{const N=i.current;if(!N)return;const C=q=>{var se,P,_,B;const U=q.detail,J=i.current;if(!J||!U)return;const te=U.orientation??t;if(typeof U.progress=="number")if(te==="horizontal"){const ee=Math.max(0,(((se=m.current)==null?void 0:se.width)??0)-J.clientWidth);J.scrollLeft=Math.min(ee,Math.max(0,U.progress*ee))}else{const ee=Math.max(0,(((P=m.current)==null?void 0:P.height)??0)-J.clientHeight);J.scrollTop=Math.min(ee,Math.max(0,U.progress*ee))}else if(typeof U.scroll=="number")if(te==="horizontal"){const ee=Math.max(0,(((_=m.current)==null?void 0:_.width)??0)-J.clientWidth);J.scrollLeft=Math.min(ee,Math.max(0,U.scroll))}else{const ee=Math.max(0,(((B=m.current)==null?void 0:B.height)??0)-J.clientHeight);J.scrollTop=Math.min(ee,Math.max(0,U.scroll))}};return N.addEventListener("udx:customScroll:set",C),()=>{N.removeEventListener("udx:customScroll:set",C)}},[t]),l.jsxs("div",{className:M.customScroll,ref:i,onMouseDown:z,onMouseMove:$,onMouseUp:R,onMouseLeave:O,onDragStart:A,onScroll:N=>{k||(j(null),D(!0),W.current&&clearTimeout(W.current),W.current=setTimeout(()=>{D(!1)},1e3))},children:[l.jsx("div",{ref:f,style:t==="vertical"?{height:((G=p==null?void 0:p.current)==null?void 0:G.height)??"100%"}:{width:((S=p==null?void 0:p.current)==null?void 0:S.width)??"100%"},className:M.track,children:e}),p.current&&m.current&&l.jsxs(l.Fragment,{children:[t==="vertical"&&m.current.height>p.current.height&&l.jsx(Y.motion.div,{className:"flex-none",style:{height:m.current.height-p.current.height}}),t==="horizontal"&&m.current.width>p.current.width&&l.jsx(Y.motion.div,{className:"flex-none",style:{width:m.current.width-p.current.width}})]})]})};var On="1.3.17";function gt(e,t,n){return Math.max(e,Math.min(t,n))}function Bn(e,t,n){return(1-n)*e+n*t}function Hn(e,t,n,s){return Bn(e,t,1-Math.exp(-n*s))}function Vn(e,t){return(e%t+t)%t}var zn=class{constructor(){H(this,"isRunning",!1);H(this,"value",0);H(this,"from",0);H(this,"to",0);H(this,"currentTime",0);H(this,"lerp");H(this,"duration");H(this,"easing");H(this,"onUpdate")}advance(e){var n;if(!this.isRunning)return;let t=!1;if(this.duration&&this.easing){this.currentTime+=e;const s=gt(0,this.currentTime/this.duration,1);t=s>=1;const r=t?1:this.easing(s);this.value=this.from+(this.to-this.from)*r}else this.lerp?(this.value=Hn(this.value,this.to,this.lerp*60,e),Math.round(this.value)===this.to&&(this.value=this.to,t=!0)):(this.value=this.to,t=!0);t&&this.stop(),(n=this.onUpdate)==null||n.call(this,this.value,t)}stop(){this.isRunning=!1}fromTo(e,t,{lerp:n,duration:s,easing:r,onStart:u,onUpdate:c}){this.from=this.value=e,this.to=t,this.lerp=n,this.duration=s,this.easing=r,this.currentTime=0,this.isRunning=!0,u==null||u(),this.onUpdate=c}};function _n(e,t){let n;return function(...s){let r=this;clearTimeout(n),n=setTimeout(()=>{n=void 0,e.apply(r,s)},t)}}var Yn=class{constructor(e,t,{autoResize:n=!0,debounce:s=250}={}){H(this,"width",0);H(this,"height",0);H(this,"scrollHeight",0);H(this,"scrollWidth",0);H(this,"debouncedResize");H(this,"wrapperResizeObserver");H(this,"contentResizeObserver");H(this,"resize",()=>{this.onWrapperResize(),this.onContentResize()});H(this,"onWrapperResize",()=>{this.wrapper instanceof Window?(this.width=window.innerWidth,this.height=window.innerHeight):(this.width=this.wrapper.clientWidth,this.height=this.wrapper.clientHeight)});H(this,"onContentResize",()=>{this.wrapper instanceof Window?(this.scrollHeight=this.content.scrollHeight,this.scrollWidth=this.content.scrollWidth):(this.scrollHeight=this.wrapper.scrollHeight,this.scrollWidth=this.wrapper.scrollWidth)});this.wrapper=e,this.content=t,n&&(this.debouncedResize=_n(this.resize,s),this.wrapper instanceof Window?window.addEventListener("resize",this.debouncedResize,!1):(this.wrapperResizeObserver=new ResizeObserver(this.debouncedResize),this.wrapperResizeObserver.observe(this.wrapper)),this.contentResizeObserver=new ResizeObserver(this.debouncedResize),this.contentResizeObserver.observe(this.content)),this.resize()}destroy(){var e,t;(e=this.wrapperResizeObserver)==null||e.disconnect(),(t=this.contentResizeObserver)==null||t.disconnect(),this.wrapper===window&&this.debouncedResize&&window.removeEventListener("resize",this.debouncedResize,!1)}get limit(){return{x:this.scrollWidth-this.width,y:this.scrollHeight-this.height}}},wt=class{constructor(){H(this,"events",{})}emit(e,...t){var s;let n=this.events[e]||[];for(let r=0,u=n.length;r<u;r++)(s=n[r])==null||s.call(n,...t)}on(e,t){var n;return(n=this.events[e])!=null&&n.push(t)||(this.events[e]=[t]),()=>{var s;this.events[e]=(s=this.events[e])==null?void 0:s.filter(r=>t!==r)}}off(e,t){var n;this.events[e]=(n=this.events[e])==null?void 0:n.filter(s=>t!==s)}destroy(){this.events={}}},ot=100/6,he={passive:!1},qn=class{constructor(e,t={wheelMultiplier:1,touchMultiplier:1}){H(this,"touchStart",{x:0,y:0});H(this,"lastDelta",{x:0,y:0});H(this,"window",{width:0,height:0});H(this,"emitter",new wt);H(this,"onTouchStart",e=>{const{clientX:t,clientY:n}=e.targetTouches?e.targetTouches[0]:e;this.touchStart.x=t,this.touchStart.y=n,this.lastDelta={x:0,y:0},this.emitter.emit("scroll",{deltaX:0,deltaY:0,event:e})});H(this,"onTouchMove",e=>{const{clientX:t,clientY:n}=e.targetTouches?e.targetTouches[0]:e,s=-(t-this.touchStart.x)*this.options.touchMultiplier,r=-(n-this.touchStart.y)*this.options.touchMultiplier;this.touchStart.x=t,this.touchStart.y=n,this.lastDelta={x:s,y:r},this.emitter.emit("scroll",{deltaX:s,deltaY:r,event:e})});H(this,"onTouchEnd",e=>{this.emitter.emit("scroll",{deltaX:this.lastDelta.x,deltaY:this.lastDelta.y,event:e})});H(this,"onWheel",e=>{let{deltaX:t,deltaY:n,deltaMode:s}=e;const r=s===1?ot:s===2?this.window.width:1,u=s===1?ot:s===2?this.window.height:1;t*=r,n*=u,t*=this.options.wheelMultiplier,n*=this.options.wheelMultiplier,this.emitter.emit("scroll",{deltaX:t,deltaY:n,event:e})});H(this,"onWindowResize",()=>{this.window={width:window.innerWidth,height:window.innerHeight}});this.element=e,this.options=t,window.addEventListener("resize",this.onWindowResize,!1),this.onWindowResize(),this.element.addEventListener("wheel",this.onWheel,he),this.element.addEventListener("touchstart",this.onTouchStart,he),this.element.addEventListener("touchmove",this.onTouchMove,he),this.element.addEventListener("touchend",this.onTouchEnd,he)}on(e,t){return this.emitter.on(e,t)}destroy(){this.emitter.destroy(),window.removeEventListener("resize",this.onWindowResize,!1),this.element.removeEventListener("wheel",this.onWheel,he),this.element.removeEventListener("touchstart",this.onTouchStart,he),this.element.removeEventListener("touchmove",this.onTouchMove,he),this.element.removeEventListener("touchend",this.onTouchEnd,he)}},it=e=>Math.min(1,1.001-Math.pow(2,-10*e)),Un=class{constructor({wrapper:e=window,content:t=document.documentElement,eventsTarget:n=e,smoothWheel:s=!0,syncTouch:r=!1,syncTouchLerp:u=.075,touchInertiaExponent:c=1.7,duration:a,easing:d,lerp:i=.1,infinite:f=!1,orientation:x="vertical",gestureOrientation:h=x==="horizontal"?"both":"vertical",touchMultiplier:m=1,wheelMultiplier:p=1,autoResize:b=!0,prevent:w,virtualScroll:L,overscroll:E=!0,autoRaf:g=!1,anchors:F=!1,autoToggle:I=!1,allowNestedScroll:v=!1,__experimental__naiveDimensions:k=!1,naiveDimensions:D=k,stopInertiaOnNavigate:M=!1}={}){H(this,"_isScrolling",!1);H(this,"_isStopped",!1);H(this,"_isLocked",!1);H(this,"_preventNextNativeScrollEvent",!1);H(this,"_resetVelocityTimeout",null);H(this,"_rafId",null);H(this,"isTouching");H(this,"time",0);H(this,"userData",{});H(this,"lastVelocity",0);H(this,"velocity",0);H(this,"direction",0);H(this,"options");H(this,"targetScroll");H(this,"animatedScroll");H(this,"animate",new zn);H(this,"emitter",new wt);H(this,"dimensions");H(this,"virtualScroll");H(this,"onScrollEnd",e=>{e instanceof CustomEvent||(this.isScrolling==="smooth"||this.isScrolling===!1)&&e.stopPropagation()});H(this,"dispatchScrollendEvent",()=>{this.options.wrapper.dispatchEvent(new CustomEvent("scrollend",{bubbles:this.options.wrapper===window,detail:{lenisScrollEnd:!0}}))});H(this,"onTransitionEnd",e=>{e.propertyName.includes("overflow")&&this.checkOverflow()});H(this,"onClick",e=>{const n=e.composedPath().filter(s=>s instanceof HTMLAnchorElement&&s.getAttribute("href"));if(this.options.anchors){const s=n.find(r=>{var u;return(u=r.getAttribute("href"))==null?void 0:u.includes("#")});if(s){const r=s.getAttribute("href");if(r){const u=typeof this.options.anchors=="object"&&this.options.anchors?this.options.anchors:void 0,c=`#${r.split("#")[1]}`;this.scrollTo(c,u)}}}this.options.stopInertiaOnNavigate&&n.find(r=>r.host===window.location.host)&&this.reset()});H(this,"onPointerDown",e=>{e.button===1&&this.reset()});H(this,"onVirtualScroll",e=>{if(typeof this.options.virtualScroll=="function"&&this.options.virtualScroll(e)===!1)return;const{deltaX:t,deltaY:n,event:s}=e;if(this.emitter.emit("virtual-scroll",{deltaX:t,deltaY:n,event:s}),s.ctrlKey||s.lenisStopPropagation)return;const r=s.type.includes("touch"),u=s.type.includes("wheel");this.isTouching=s.type==="touchstart"||s.type==="touchmove";const c=t===0&&n===0;if(this.options.syncTouch&&r&&s.type==="touchstart"&&c&&!this.isStopped&&!this.isLocked){this.reset();return}const d=this.options.gestureOrientation==="vertical"&&n===0||this.options.gestureOrientation==="horizontal"&&t===0;if(c||d)return;let i=s.composedPath();i=i.slice(0,i.indexOf(this.rootElement));const f=this.options.prevent;if(i.find(w=>{var L,E,g;return w instanceof HTMLElement&&(typeof f=="function"&&(f==null?void 0:f(w))||((L=w.hasAttribute)==null?void 0:L.call(w,"data-lenis-prevent"))||r&&((E=w.hasAttribute)==null?void 0:E.call(w,"data-lenis-prevent-touch"))||u&&((g=w.hasAttribute)==null?void 0:g.call(w,"data-lenis-prevent-wheel"))||this.options.allowNestedScroll&&this.checkNestedScroll(w,{deltaX:t,deltaY:n}))}))return;if(this.isStopped||this.isLocked){s.cancelable&&s.preventDefault();return}if(!(this.options.syncTouch&&r||this.options.smoothWheel&&u)){this.isScrolling="native",this.animate.stop(),s.lenisStopPropagation=!0;return}let h=n;this.options.gestureOrientation==="both"?h=Math.abs(n)>Math.abs(t)?n:t:this.options.gestureOrientation==="horizontal"&&(h=t),(!this.options.overscroll||this.options.infinite||this.options.wrapper!==window&&this.limit>0&&(this.animatedScroll>0&&this.animatedScroll<this.limit||this.animatedScroll===0&&n>0||this.animatedScroll===this.limit&&n<0))&&(s.lenisStopPropagation=!0),s.cancelable&&s.preventDefault();const m=r&&this.options.syncTouch,b=r&&s.type==="touchend";b&&(h=Math.sign(this.velocity)*Math.pow(Math.abs(this.velocity),this.options.touchInertiaExponent)),this.scrollTo(this.targetScroll+h,{programmatic:!1,...m?{lerp:b?this.options.syncTouchLerp:1}:{lerp:this.options.lerp,duration:this.options.duration,easing:this.options.easing}})});H(this,"onNativeScroll",()=>{if(this._resetVelocityTimeout!==null&&(clearTimeout(this._resetVelocityTimeout),this._resetVelocityTimeout=null),this._preventNextNativeScrollEvent){this._preventNextNativeScrollEvent=!1;return}if(this.isScrolling===!1||this.isScrolling==="native"){const e=this.animatedScroll;this.animatedScroll=this.targetScroll=this.actualScroll,this.lastVelocity=this.velocity,this.velocity=this.animatedScroll-e,this.direction=Math.sign(this.animatedScroll-e),this.isStopped||(this.isScrolling="native"),this.emit(),this.velocity!==0&&(this._resetVelocityTimeout=setTimeout(()=>{this.lastVelocity=this.velocity,this.velocity=0,this.isScrolling=!1,this.emit()},400))}});H(this,"raf",e=>{const t=e-(this.time||e);this.time=e,this.animate.advance(t*.001),this.options.autoRaf&&(this._rafId=requestAnimationFrame(this.raf))});window.lenisVersion=On,(!e||e===document.documentElement)&&(e=window),typeof a=="number"&&typeof d!="function"?d=it:typeof d=="function"&&typeof a!="number"&&(a=1),this.options={wrapper:e,content:t,eventsTarget:n,smoothWheel:s,syncTouch:r,syncTouchLerp:u,touchInertiaExponent:c,duration:a,easing:d,lerp:i,infinite:f,gestureOrientation:h,orientation:x,touchMultiplier:m,wheelMultiplier:p,autoResize:b,prevent:w,virtualScroll:L,overscroll:E,autoRaf:g,anchors:F,autoToggle:I,allowNestedScroll:v,naiveDimensions:D,stopInertiaOnNavigate:M},this.dimensions=new Yn(e,t,{autoResize:b}),this.updateClassName(),this.targetScroll=this.animatedScroll=this.actualScroll,this.options.wrapper.addEventListener("scroll",this.onNativeScroll,!1),this.options.wrapper.addEventListener("scrollend",this.onScrollEnd,{capture:!0}),(this.options.anchors||this.options.stopInertiaOnNavigate)&&this.options.wrapper.addEventListener("click",this.onClick,!1),this.options.wrapper.addEventListener("pointerdown",this.onPointerDown,!1),this.virtualScroll=new qn(n,{touchMultiplier:m,wheelMultiplier:p}),this.virtualScroll.on("scroll",this.onVirtualScroll),this.options.autoToggle&&(this.checkOverflow(),this.rootElement.addEventListener("transitionend",this.onTransitionEnd,{passive:!0})),this.options.autoRaf&&(this._rafId=requestAnimationFrame(this.raf))}destroy(){this.emitter.destroy(),this.options.wrapper.removeEventListener("scroll",this.onNativeScroll,!1),this.options.wrapper.removeEventListener("scrollend",this.onScrollEnd,{capture:!0}),this.options.wrapper.removeEventListener("pointerdown",this.onPointerDown,!1),(this.options.anchors||this.options.stopInertiaOnNavigate)&&this.options.wrapper.removeEventListener("click",this.onClick,!1),this.virtualScroll.destroy(),this.dimensions.destroy(),this.cleanUpClassName(),this._rafId&&cancelAnimationFrame(this._rafId)}on(e,t){return this.emitter.on(e,t)}off(e,t){return this.emitter.off(e,t)}get overflow(){const e=this.isHorizontal?"overflow-x":"overflow-y";return getComputedStyle(this.rootElement)[e]}checkOverflow(){["hidden","clip"].includes(this.overflow)?this.internalStop():this.internalStart()}setScroll(e){this.isHorizontal?this.options.wrapper.scrollTo({left:e,behavior:"instant"}):this.options.wrapper.scrollTo({top:e,behavior:"instant"})}resize(){this.dimensions.resize(),this.animatedScroll=this.targetScroll=this.actualScroll,this.emit()}emit(){this.emitter.emit("scroll",this)}reset(){this.isLocked=!1,this.isScrolling=!1,this.animatedScroll=this.targetScroll=this.actualScroll,this.lastVelocity=this.velocity=0,this.animate.stop()}start(){if(this.isStopped){if(this.options.autoToggle){this.rootElement.style.removeProperty("overflow");return}this.internalStart()}}internalStart(){this.isStopped&&(this.reset(),this.isStopped=!1,this.emit())}stop(){if(!this.isStopped){if(this.options.autoToggle){this.rootElement.style.setProperty("overflow","clip");return}this.internalStop()}}internalStop(){this.isStopped||(this.reset(),this.isStopped=!0,this.emit())}scrollTo(e,{offset:t=0,immediate:n=!1,lock:s=!1,programmatic:r=!0,lerp:u=r?this.options.lerp:void 0,duration:c=r?this.options.duration:void 0,easing:a=r?this.options.easing:void 0,onStart:d,onComplete:i,force:f=!1,userData:x}={}){if(!((this.isStopped||this.isLocked)&&!f)){if(typeof e=="string"&&["top","left","start","#"].includes(e))e=0;else if(typeof e=="string"&&["bottom","right","end"].includes(e))e=this.limit;else{let h;if(typeof e=="string"?(h=document.querySelector(e),h||(e==="#top"?e=0:console.warn("Lenis: Target not found",e))):e instanceof HTMLElement&&(e!=null&&e.nodeType)&&(h=e),h){if(this.options.wrapper!==window){const p=this.rootElement.getBoundingClientRect();t-=this.isHorizontal?p.left:p.top}const m=h.getBoundingClientRect();e=(this.isHorizontal?m.left:m.top)+this.animatedScroll}}if(typeof e=="number"){if(e+=t,e=Math.round(e),this.options.infinite){if(r){this.targetScroll=this.animatedScroll=this.scroll;const h=e-this.animatedScroll;h>this.limit/2?e=e-this.limit:h<-this.limit/2&&(e=e+this.limit)}}else e=gt(0,e,this.limit);if(e===this.targetScroll){d==null||d(this),i==null||i(this);return}if(this.userData=x??{},n){this.animatedScroll=this.targetScroll=e,this.setScroll(this.scroll),this.reset(),this.preventNextNativeScrollEvent(),this.emit(),i==null||i(this),this.userData={},requestAnimationFrame(()=>{this.dispatchScrollendEvent()});return}r||(this.targetScroll=e),typeof c=="number"&&typeof a!="function"?a=it:typeof a=="function"&&typeof c!="number"&&(c=1),this.animate.fromTo(this.animatedScroll,e,{duration:c,easing:a,lerp:u,onStart:()=>{s&&(this.isLocked=!0),this.isScrolling="smooth",d==null||d(this)},onUpdate:(h,m)=>{this.isScrolling="smooth",this.lastVelocity=this.velocity,this.velocity=h-this.animatedScroll,this.direction=Math.sign(this.velocity),this.animatedScroll=h,this.setScroll(this.scroll),r&&(this.targetScroll=h),m||this.emit(),m&&(this.reset(),this.emit(),i==null||i(this),this.userData={},requestAnimationFrame(()=>{this.dispatchScrollendEvent()}),this.preventNextNativeScrollEvent())}})}}}preventNextNativeScrollEvent(){this._preventNextNativeScrollEvent=!0,requestAnimationFrame(()=>{this._preventNextNativeScrollEvent=!1})}checkNestedScroll(e,{deltaX:t,deltaY:n}){const s=Date.now(),r=e._lenis??(e._lenis={});let u,c,a,d,i,f,x,h;const m=this.options.gestureOrientation;if(s-(r.time??0)>2e3){r.time=Date.now();const I=window.getComputedStyle(e);r.computedStyle=I;const v=I.overflowX,k=I.overflowY;if(u=["auto","overlay","scroll"].includes(v),c=["auto","overlay","scroll"].includes(k),r.hasOverflowX=u,r.hasOverflowY=c,!u&&!c||m==="vertical"&&!c||m==="horizontal"&&!u)return!1;i=e.scrollWidth,f=e.scrollHeight,x=e.clientWidth,h=e.clientHeight,a=i>x,d=f>h,r.isScrollableX=a,r.isScrollableY=d,r.scrollWidth=i,r.scrollHeight=f,r.clientWidth=x,r.clientHeight=h}else a=r.isScrollableX,d=r.isScrollableY,u=r.hasOverflowX,c=r.hasOverflowY,i=r.scrollWidth,f=r.scrollHeight,x=r.clientWidth,h=r.clientHeight;if(!u&&!c||!a&&!d||m==="vertical"&&(!c||!d)||m==="horizontal"&&(!u||!a))return!1;let p;if(m==="horizontal")p="x";else if(m==="vertical")p="y";else{const I=t!==0,v=n!==0;I&&u&&a&&(p="x"),v&&c&&d&&(p="y")}if(!p)return!1;let b,w,L,E,g;if(p==="x")b=e.scrollLeft,w=i-x,L=t,E=u,g=a;else if(p==="y")b=e.scrollTop,w=f-h,L=n,E=c,g=d;else return!1;return(L>0?b<w:b>0)&&E&&g}get rootElement(){return this.options.wrapper===window?document.documentElement:this.options.wrapper}get limit(){return this.options.naiveDimensions?this.isHorizontal?this.rootElement.scrollWidth-this.rootElement.clientWidth:this.rootElement.scrollHeight-this.rootElement.clientHeight:this.dimensions.limit[this.isHorizontal?"x":"y"]}get isHorizontal(){return this.options.orientation==="horizontal"}get actualScroll(){const e=this.options.wrapper;return this.isHorizontal?e.scrollX??e.scrollLeft:e.scrollY??e.scrollTop}get scroll(){return this.options.infinite?Vn(this.animatedScroll,this.limit):this.animatedScroll}get progress(){return this.limit===0?1:this.scroll/this.limit}get isScrolling(){return this._isScrolling}set isScrolling(e){this._isScrolling!==e&&(this._isScrolling=e,this.updateClassName())}get isStopped(){return this._isStopped}set isStopped(e){this._isStopped!==e&&(this._isStopped=e,this.updateClassName())}get isLocked(){return this._isLocked}set isLocked(e){this._isLocked!==e&&(this._isLocked=e,this.updateClassName())}get isSmooth(){return this.isScrolling==="smooth"}get className(){let e="lenis";return this.options.autoToggle&&(e+=" lenis-autoToggle"),this.isStopped&&(e+=" lenis-stopped"),this.isLocked&&(e+=" lenis-locked"),this.isScrolling&&(e+=" lenis-scrolling"),this.isScrolling==="smooth"&&(e+=" lenis-smooth"),e}updateClassName(){this.cleanUpClassName(),this.rootElement.className=`${this.rootElement.className} ${this.className}`.trim()}cleanUpClassName(){this.rootElement.className=this.rootElement.className.replace(/lenis(-\w+)?/g,"").trim()}};const Xn=({transition:e=1.2,easing:t,orientation:n="vertical",smoothTouch:s=!1,touchMultiplier:r=2,children:u})=>{const c=o.useRef(null),a=o.useRef(null);return o.useEffect(()=>{let d;typeof e=="string"?e.endsWith("ms")?d=parseFloat(e)/1e3:e.endsWith("s")?d=parseFloat(e):d=parseFloat(e)||1.2:d=e;const i=x=>1-Math.pow(1-x,5);c.current=new Un({duration:d,easing:t??i,orientation:n,smoothWheel:!0,touchMultiplier:r,syncTouch:s});const f=x=>{var h;(h=c.current)==null||h.raf(x),a.current=requestAnimationFrame(f)};return a.current=requestAnimationFrame(f),()=>{var x;a.current!==null&&cancelAnimationFrame(a.current),(x=c.current)==null||x.destroy(),c.current=null}},[e,t,n,s,r]),u?l.jsx(l.Fragment,{children:u}):null},ue=({style:e,colorName:t,stateClassName:n="state-ripple-group",children:s,className:r})=>{const u=o.useRef(null),c=o.useRef(null),[a,d]=o.useState(!1),i=bt({isClient:a,stateClassName:n,className:r,colorName:t});return o.useEffect(()=>{if(u.current&&n!=="state-layer"){const x=(n.includes("[")?"group/"+n.split("[")[1].split("]")[0]:"group").replace(/\//g,"\\/"),h=u.current.closest(`.${x}:not(.${x} .${x})`);c.current=h}d(!0)},[]),l.jsxs("div",{ref:u,className:i.stateLayer,style:{"--state-color":`var(--default-color, var(--color-${t}))`,...e},children:[a&&l.jsx(mt,{triggerRef:c}),s]})},Gn=({isClient:e,stateClassName:t})=>({stateLayer:y(["w-full top-0 left-0 h-full absolute pointer-events-none overflow-hidden",t])}),bt=Z("stateLayer",Gn),St=({targetRef:e,children:t})=>{const[n,s]=o.useState(null),r=o.useRef(null),u=()=>{const c=e.current;if(!c)return;const a=c.getBoundingClientRect();s({position:"fixed",top:a.top,left:a.left,width:a.width,height:a.height,pointerEvents:"none",zIndex:999})};return o.useEffect(()=>{const c=e.current;if(c)return u(),window.addEventListener("scroll",u,!0),window.addEventListener("resize",u),r.current=new ResizeObserver(u),r.current.observe(c),()=>{var a;window.removeEventListener("scroll",u,!0),window.removeEventListener("resize",u),(a=r.current)==null||a.disconnect()}},[e]),n?Ve.createPortal(l.jsx("div",{style:n,children:t}),document.body):null};function Kn(e){return/^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$/.test(e)}const Jn=({config:e,throttleDelay:t=100,onLoad:n,loadTheme:s=!1})=>{const[r,u]=o.useState(null),[c,a]=o.useState(null),d=o.useRef(null),i=o.useRef(0),f=o.useRef(0),x=o.useRef(null),h=o.useRef(!1),m=o.useRef(n);o.useEffect(()=>{m.current=n},[n]),o.useEffect(()=>{let E=!1;return(async()=>{const g=await we.loader(e,s);if(E)return;x.current=g,u(g);const F=new Worker(new URL(""+(typeof document>"u"?require("url").pathToFileURL(__dirname+"/theme.worker.js").href:new URL("theme.worker.js",document.currentScript&&document.currentScript.tagName.toUpperCase()==="SCRIPT"&&document.currentScript.src||document.baseURI).href),typeof document>"u"?require("url").pathToFileURL(__filename).href:Pe&&Pe.tagName.toUpperCase()==="SCRIPT"&&Pe.src||new URL("index.cjs",document.baseURI).href),{type:"module"});d.current=F,F.onmessage=I=>{var v;I.data.id>f.current&&(f.current=I.data.id,h.current=!0,a(I.data.css),(v=m.current)==null||v.call(m,x.current))}})(),()=>{var g;E=!0,(g=d.current)==null||g.terminate(),d.current=null}},[]);const p=o.useRef(null),b=o.useRef(0),w=o.useRef(null);o.useEffect(()=>{if(!r)return;const E={...e,sourceColor:e.sourceColor},g=Date.now(),F=g-b.current,I=async v=>{await L(v)};if(b.current===0||F>=t)p.current&&(clearTimeout(p.current),p.current=null),w.current=null,b.current=g,I(E);else if(w.current=E,!p.current){const v=Math.max(0,t-F);p.current=setTimeout(async()=>{p.current=null;const k=w.current;w.current=null,k&&(b.current=Date.now(),await I(k))},v)}return()=>{}},[e,t,r]);const L=async E=>{if(typeof E.sourceColor=="string"&&!Kn(E.sourceColor))throw new Error("Invalid hex color");const g=x.current;if(!g)return;g.context.update(E),g.palettes.sync(E.palettes);const F=d.current;if(!F||!h.current){await g.load();const v=g.plugins.getPlugin(Oe.TailwindPlugin).getInstance().outputCss;a(v),h.current=!0,n==null||n(g);return}const I=++i.current;F.postMessage({id:I,snapshot:we.serializeThemeContext(g),tailwindOptions:g.plugins.getPlugin(Oe.TailwindPlugin).toSerializable(),fontOptions:g.plugins.getPlugin(we.FontPlugin).toSerializable()})};return o.useEffect(()=>()=>{p.current&&(clearTimeout(p.current),p.current=null)},[]),c?l.jsx("style",{dangerouslySetInnerHTML:{__html:c}}):null};function Zn(){if(typeof window>"u")return!1;try{if(window.CSS&&typeof window.CSS.supports=="function")return CSS.supports("animation-timeline: view()")||CSS.supports("animation-timeline: scroll()")||CSS.supports("view-timeline-name: --a")}catch{}return!1}function Qn(){return typeof window>"u"||!("matchMedia"in window)?!1:window.matchMedia("(prefers-reduced-motion: reduce)").matches}function ze(e){if(!(e instanceof HTMLElement))return!1;const t=e.classList;return Array.from(t).some(n=>n.startsWith("anim-")&&n.includes("scroll"))}function lt(e){if(!(e instanceof HTMLElement))return!1;const t=e.classList;return Array.from(t).some(n=>n.startsWith("anim-"))}function $e(e,t){if(!ze(e))return;if(e.hasAttribute(`data-${t}-scroll`)){const c=(e.getAttribute(`data-${t}-scroll`)||"").trim().toLowerCase(),a=c==="x"||c==="inline"?"inline":c==="y"||c==="block"?"block":"auto";e.classList.contains(`${t}-timeline`)||e.classList.contains(`${t}-timeline-inline`)||e.classList.contains(`${t}-timeline-block`)||e.classList.contains(`${t}-timeline-x`)||e.classList.contains(`${t}-timeline-y`)||(a==="inline"?e.classList.add(`${t}-timeline-inline`):a==="block"?e.classList.add(`${t}-timeline-block`):e.classList.add(`${t}-scroll`))}const n=e.getAttribute(`data-${t}-start`);n&&e.style.setProperty(`--${t}-range-start`,n);const s=e.getAttribute(`data-${t}-end`);s&&e.style.setProperty(`--${t}-range-end`,s);const r=e.hasAttribute(`data-${t}-paused`)||e.classList.contains(`${t}-paused`),u=e.hasAttribute(`data-${t}-run`)||e.classList.contains(`${t}-run`);!r&&!u&&e.setAttribute(`data-${t}-run`,"")}function We(e=document,t){return Array.from(e.querySelectorAll(`[class*="${t}-"][class*="-scroll"]`)).filter(s=>ze(s))}function es(e=document,t){const n=Array.from(e.querySelectorAll(`[class*="${t}-"]`)),s=new Set([`${t}-run`,`${t}-in`,`${t}-out`,`${t}-in-run`,`${t}-out-run`,`${t}-paused`,`${t}-timeline`,`${t}-timeline-inline`,`${t}-timeline-block`,`${t}-timeline-x`,`${t}-timeline-y`,`${t}-scroll`]);return n.filter(r=>{if(!(r instanceof HTMLElement))return!1;const u=r.classList;return u.contains(`${t}-in`)||u.contains(`${t}-out`)||Array.from(u).some(d=>d.startsWith(`${t}-`)&&!d.includes("scroll")&&!s.has(d))?!0:!ze(r)})}function ts(e,t){return Array.from(e).some(n=>n.startsWith(t)&&n.includes("-out"))}function at(e,t,n){e.setAttribute(`data-${t}-run`,""),e.setAttribute(`data-${t}-${n}-run`,"")}function ct(e,t,n){const s=e.style.animationName;e.style.animationName="none",e.removeAttribute(`data-${t}-run`),n?e.removeAttribute(`data-${t}-${n}-run`):(e.removeAttribute(`data-${t}-in-run`),e.removeAttribute(`data-${t}-out-run`)),e.offsetWidth,e.style.animationName=s}const ns=[0,.2],ut=new WeakSet;function dt(e,t){if(ut.has(e))return;ut.add(e);const n=r=>{r.target===e&&(e.hasAttribute(`data-${t}-in-run`)||e.hasAttribute(`data-${t}-out-run`))&&e.setAttribute(`data-${t}-animating`,"")},s=r=>{r.target===e&&e.removeAttribute(`data-${t}-animating`)};e.addEventListener("animationstart",n),e.addEventListener("animationend",s),e.addEventListener("animationcancel",s)}function _e(e={}){const{prefix:t="anim",once:n=!0}=e;if(Qn())return()=>{};const s=Zn(),r=new WeakSet;let u=typeof window<"u"&&(window.pageYOffset||window.scrollY)||0,c=!0;const a=()=>{const m=window.pageYOffset||window.scrollY||0;c=m>=u,u=m};typeof window<"u"&&window.addEventListener("scroll",a,{passive:!0});const d=new IntersectionObserver(m=>{for(const p of m){const b=p.target;if(!lt(b)||b.hasAttribute(`data-${t}-animating`))continue;const w=ts(b.classList,t);p.isIntersecting?(w&&ct(b,t,"out"),at(b,t,"in"),n&&d.unobserve(b)):n||(c||ct(b,t,"in"),w&&at(b,t,"out"))}},{threshold:ns}),i=m=>{const p=es(m||document,t);for(const b of p)r.has(b)||(r.add(b),d.observe(b),dt(b,t))};i();let f,x=null,h=null;if(s)(()=>{h==null&&(h=requestAnimationFrame(()=>{h=null;const p=We(void 0,t);for(const b of p)$e(b,t)}))})(),x=new MutationObserver(p=>{for(const b of p)if(b.type==="attributes"){const w=b.target;w instanceof HTMLElement&&($e(w,t),lt(w)&&(r.has(w)||(r.add(w),d.observe(w),dt(w,t))))}else if(b.type==="childList"&&b.addedNodes&&b.addedNodes.length){for(const w of Array.from(b.addedNodes))if(w instanceof HTMLElement){const L=We(w,t);for(const E of L)$e(E,t);i(w)}}}),x.observe(document.documentElement,{subtree:!0,childList:!0,attributes:!0,attributeFilter:["class",`data-${t}-scroll`,`data-${t}-start`,`data-${t}-end`,`data-${t}-paused`,`data-${t}-run`]}),f=()=>{h!=null&&cancelAnimationFrame(h),x&&x.disconnect()};else{let m;We(void 0,t).length>0&&Promise.resolve().then(()=>require("./scrollDriven.js")).then(b=>{m=b.initScrollViewFallback({once:n})}),f=()=>{typeof m=="function"&&m()}}return()=>{f&&f(),typeof window<"u"&&window.removeEventListener("scroll",a),d.disconnect()}}const ss=_e,rs=_e,be=({anchorRef:e,position:t="bottom",children:n,style:s,...r})=>{const c=`--anchor-${o.useId().replace(/:/g,"")}`,[a,d]=o.useState(!1);if(o.useLayoutEffect(()=>{typeof CSS<"u"&&CSS.supports("anchor-name","--a")&&d(!0)},[]),o.useLayoutEffect(()=>{if(a&&e.current){const f=e.current;return f.style.anchorName=c,()=>{e.current&&(e.current.style.anchorName="")}}},[a,e,c]),a){const f={position:"fixed",margin:0,zIndex:9999,positionAnchor:c,positionArea:t,positionTryFallbacks:"flip-block, flip-inline",...s};return Ve.createPortal(l.jsx("div",{style:f,...r,children:n}),document.body)}const i={position:"absolute",pointerEvents:"auto",...s};switch(t){case"top":i.bottom="100%",i.left="50%",i.transform="translateX(-50%)";break;case"top-left":i.bottom="100%",i.left=0;break;case"top-right":i.bottom="100%",i.right=0;break;case"bottom":i.top="100%",i.left="50%",i.transform="translateX(-50%)";break;case"bottom-left":i.top="100%",i.left=0;break;case"bottom-right":i.top="100%",i.right=0;break;case"left":i.right="100%",i.top="50%",i.transform="translateY(-50%)";break;case"right":i.left="100%",i.top="50%",i.transform="translateY(-50%)";break}return l.jsx(St,{targetRef:e,children:l.jsx("div",{style:i,...r,children:n})})},Et=({variant:e,disableTextMargins:t,disabled:n,iconPosition:s,icon:r,isActive:u,loading:c,shape:a,onToggle:d,size:i,allowShapeTransformation:f})=>({button:y(" relative cursor-pointer group/button outline-none inline-block flex w-fit justify-center items-center ",i==="xSmall"&&"text-label-large px-3 py-1.5 gap-1",i==="small"&&"text-label-large px-4 py-2.5 gap-2",i==="medium"&&"text-title-medium px-6 py-4 gap-2",i==="large"&&"text-headline-small px-12 py-8 gap-3",i==="xLarge"&&"text-headline-large px-16 py-12 gap-4",a==="rounded"&&{"rounded-[30px]":i==="xSmall"||i=="small","rounded-[40px]":i==="medium","rounded-[70px]":i==="large"||i=="xLarge"},(a==="squared"||f&&u)&&{"rounded-[12px]":i==="xSmall"||i=="small","rounded-[16px]":i==="medium","rounded-[28px]":i==="large"||i=="xLarge"},f&&!n&&{"active:rounded-[12px]":i==="xSmall"||i=="small","active:rounded-[16px]":i==="medium","active:rounded-[28px]":i==="large"||i=="xLarge"},e==="elevated"&&{"shadow-1 hover:shadow-2":!n,"bg-surface-container-low text-primary":!n&&!u,"bg-primary text-on-primary":!n&&u,"text-on-surface/[38%]":n},e==="filled"&&{"hover:shadow-1":!n,"bg-surface-container text-on-surface-variant":!n&&!u&&d,"bg-primary text-on-primary":!n&&(u&&d||!d),"text-on-surface/[38%]":n},e==="tonal"&&{"hover:shadow-1":!n,"bg-secondary-container text-on-secondary-container":!n&&!u,"bg-secondary text-on-secondary":!n&&u,"text-on-surface/[0.38]":n},e==="outlined"&&[" border",{"border-on-surface/[0.12] text-on-surface/[0.38]":n,"text-primary border-outline focus:border-primary":!n&&!u,"text-inverse-on-surface bg-inverse-surface border-inverse-surface":!n&&u}],e==="text"&&["w-fit",{"text-primary":!n,"text-on-surface/[0.38]":n},t&&[i==="xSmall"&&"-mx-3 ",i==="small"&&"-mx-4 ",i==="medium"&&"-mx-6 ",i==="large"&&"-mx-12",i==="xLarge"&&"-mx-16 "]],n&&"cursor-default"),touchTarget:y("absolute -translate-x-1/2 -translate-y-1/2 left-1/2 top-1/2 h-12 w-full"),stateLayer:y("overflow-hidden",a==="rounded"&&{"rounded-[30px]":i==="xSmall"||i=="small","rounded-[40px]":i==="medium","rounded-[70px]":i==="large"||i=="xLarge"},(a==="squared"||f&&u)&&{"rounded-[12px]":i==="xSmall"||i=="small","rounded-[16px]":i==="medium","rounded-[28px]":i==="large"||i=="xLarge"},f&&!n&&{"group-active/button:rounded-[12px]":i==="xSmall"||i=="small","group-active/button:rounded-[16px]":i==="medium","group-active/button:rounded-[28px]":i==="large"||i=="xLarge"}),label:y({invisible:c}),icon:y({invisible:c},i==="xSmall"&&"size-5",i==="small"&&"size-5",i==="medium"&&"size-6",i==="large"&&"size-8",i==="xLarge"&&"size-10")}),os=ne("button",Et),Nt=Z("button",Et),kt=({variant:e,interactive:t})=>({card:y(" rounded-xl overflow-hidden ",e==="outlined"&&"bg-surface border border-outline-variant",e==="elevated"&&"bg-surface-container-low shadow-1",e==="filled"&&"bg-surface-container-highest",{"group/card cursor-pointer":t})}),is=ne("card",kt),jt=Z("card",kt),Ye=()=>({carouselItem:y("rounded-[28px] overflow-hidden flex-none",{})}),ls=ne("carouselItem",Ye),Lt=Z("carouselItem",Ye),Mt=()=>({carousel:y(["w-full h-[400px]"]),track:y("flex h-full w-full")}),as=ne("carousel",Mt),It=Z("carousel",Mt),Ct=({isChecked:e,isIndeterminate:t,isDisabled:n,isError:s,isFocused:r,isHovered:u})=>({checkbox:y("inline-flex items-center justify-center relative size-4.5 ",{"pointer-events-none opacity-[0.38]":n}),input:y("absolute inset-0 w-full h-full opacity-0 z-10 cursor-pointer"),container:y("relative flex items-center justify-center w-[18px] h-[18px] "),box:y("absolute left-1/2 top-1/2 -translate-1/2 to rounded-[2px] size-4 border-2 transition-colors duration-200",!e&&!t&&{"border-on-surface-variant":!s&&!n,"border-error":s&&!n,"border-on-surface":n},(e||t)&&{"bg-primary border-primary":!s&&!n,"bg-error border-error":s&&!n,"bg-on-surface border-on-surface":n}),icon:y("z-10 relative text-on-primary w-full h-full flex items-center justify-center pointer-events-none",{"text-on-error":s&&!n,"text-surface":n}),stateLayer:"size-10 state-ripple-group-[checkbox] rounded-full cursor-pointer pointer-events-auto absolute left-1/2 top-1/2 -translate-x-1/2 -translate-y-1/2"}),cs=ne("checkbox",Ct),Rt=Z("checkbox",Ct),Dt=({variant:e,disabled:t,trailingIcon:n,icon:s,isActive:r,isInteractive:u,activated:c,isFocused:a,isDragging:d,isEditing:i})=>({chip:y(" group/chip px-3 py-1.5 rounded-lg flex items-center gap-2 outline-none",{"pl-2":s,"pr-2":n,"cursor-pointer":!t&&u},{" text-on-surface-variant":!c&&!a||i,"bg-secondary-container text-on-secondary-container":(c||a)&&!i},d&&["opacity-100 cursor-grabbing shadow-3"],e==="outlined"&&["border border-outline-variant",{"border-transparent":i}],e==="elevated"&&!i&&["shadow-1 bg-surface-container-low","border border-outline-variant"]),stateLayer:y("rounded-lg overflow-hidden",{}),label:y("outline-none text-nowrap",{"opacity-[0.38]":t}),leadingIcon:y("text-primary size-[18px]",{"opacity-[0.38]":t}),trailingIcon:y("cursor-pointer size-[18px]",{"opacity-[0.38]":t})}),us=ne("chip",Dt),At=Z("chip",Dt),Ft=({scrollable:e})=>({chips:y(" flex gap-3 outline-none",{"flex-wrap":!e,"overflow-x-auto":e})}),ds=ne("chips",Ft),Pt=Z("chips",Ft),$t=({orientation:e})=>({divider:y("border-outline-variant ",{"h-fit w-full border-t":e==="horizontal"},{"h-auto self-stretch w-fit border-l":e==="vertical"})}),fs=ne("divider",$t),Wt=Z("divider",$t),Tt=({size:e,variant:t,extended:n})=>({fab:y("flex shadow-3 hover:shadow-4 group/fab overflow-hidden outline-none items-center cursor-pointer",{"rounded-[12px]":e=="small","rounded-[16px]":e=="medium","rounded-[28px]":e=="large"},{"p-2":e=="small","p-4":e=="medium","p-[30px]":e=="large"},t==="primary"&&"bg-primary text-on-primary",t==="secondary"&&"bg-secondary text-on-secondary",t==="tertiary"&&"bg-tertiary text-on-tertiary",t==="primaryContainer"&&"bg-primary-container text-on-primary-container",t==="secondaryContainer"&&"bg-secondary-container text-on-secondary-container",t==="tertiaryContainer"&&"bg-tertiary-container text-on-tertiary-container"),icon:y({"size-6":e=="small"||e=="medium","size-9":e=="large"}),label:y("text-nowrap",{"text-title-medium":e=="small","text-title-large":e=="medium","text-headline-small":e=="large"})}),hs=ne("fab",Tt),Ot=Z("fab",Tt),Bt=({size:e,variant:t,open:n})=>({fabMenu:y("relative inline-flex flex-col items-end"),actions:y("flex flex-col gap-1 items-end absolute bottom-[calc(100%_+_8px)] right-0"),label:y("text-nowrap")}),ms=ne("fabMenu",Bt),Ht=Z("fabMenu",Bt),Vt=({variant:e,disabled:t,onToggle:n,isActive:s,size:r,width:u,shape:c,allowShapeTransformation:a})=>({iconButton:y("rounded-full relative flex transition-all duration-300","group/icon-button cursor-pointer",{"cursor-default":t},c==="rounded"&&{"rounded-[30px]":r==="xSmall"||r=="small","rounded-[40px]":r==="medium","rounded-[70px]":r==="large"||r=="xLarge"},(c==="squared"||a&&s)&&{"rounded-[12px]":r==="xSmall"||r=="small","rounded-[16px]":r==="medium","rounded-[28px]":r==="large"||r=="xLarge"},a&&!t&&{"active:rounded-[12px]":r==="xSmall"||r=="small","active:rounded-[16px]":r==="medium","active:rounded-[28px]":r==="large"||r=="xLarge"},e==="filled"&&[!t&&{"bg-surface-container":!s&&!!n,"bg-primary":s||!n},!!t&&"bg-on-surface/[0.12]"],e==="tonal"&&[!t&&{"bg-secondary-container text-on-secondary-container":!s&&!!n,"bg-secondary text-on-secondary":s||!n},!!t&&"bg-on-surface/[0.12]"],e==="outlined"&&[!t&&{"border border-outline":!s,"border border-transparent bg-inverse-surface":s},!!t&&{"border border-on-surface/[0.12]":!s,"border border-transparent bg-on-surface/[0.12]":s}]),touchTarget:y("absolute -translate-x-1/2 -translate-y-1/2 left-1/2 top-1/2 h-12 w-full"),stateLayer:y("absolute top-0 left-0 h-full w-full overflow-hidden",(c==="rounded"||c==="squared"&&n&&!t&&s&&a)&&{"rounded-[30px]":r==="xSmall"||r=="small","rounded-[40px]":r==="medium","rounded-[70px]":r==="large"||r=="xLarge"},(c==="squared"||c==="rounded"&&n&&!t&&s&&a)&&{"rounded-[12px]":r==="xSmall"||r=="small","rounded-[16px]":r==="medium","rounded-[28px]":r==="large"||r=="xLarge"},a&&!t&&{"group-active/icon-button:rounded-[12px]":r==="xSmall"||r=="small","group-active/icon-button:rounded-[16px]":r==="medium","group-active/icon-button:rounded-[28px]":r==="large"||r=="xLarge"},!t&&[e==="standard"&&{"state-on-surface-variant":!s,"state-primary":s},e==="filled"&&{"state-primary":!s&&!!n,"state-inverse-on-surface":s||!n},e==="tonal"&&{"state-on-surface-variant":!s&&!!n,"state-on-secondary-container":s||!n},e==="outlined"&&{"state-on-surface-variant":!s,"state-on-primary":s}]),icon:y(" transition-all duration-300",{"size-5 p-1.5":r==="xSmall"},{"size-6 p-2":r==="small"},{"size-6 p-4":r==="medium"},{"size-8 p-8":r==="large"},{"size-10 p-12":r==="xLarge"},u=="narrow"&&[{"px-1":r==="xSmall"},{"px-1":r==="small"},{"px-3":r==="medium"},{"px-4":r==="large"},{"px-8":r==="xLarge"}],u=="wide"&&[{"px-2.5":r==="xSmall"},{"px-3.5":r==="small"},{"px-6":r==="medium"},{"px-12":r==="large"},{"px-[72px]":r==="xLarge"}],!t&&[e==="standard"&&{"text-on-surface-variant":!s,"text-primary":s},e==="filled"&&{"text-primary":!s&&!!n,"text-on-primary":s||!n},e==="outlined"&&{"text-on-surface-variant":!s,"text-inverse-on-surface":s}],!!t&&"text-on-surface/[0.38]")}),ps=ne("iconButton",Vt),zt=Z("iconButton",Vt),_t=({variant:e,hasGroups:t})=>({menu:y("z-50 min-w-[112px] max-w-[280px] max-h-[300px] ","flex flex-col",{"overflow-y-auto":!t},{"bg-surface-container":!e||e==="standard","bg-tertiary-container text-on-tertiary-container":e==="vibrant","py-0.5 shadow-2 px-1 rounded-2xl":!t,"bg-transparent ":t})}),ys=ne("menu",_t),Yt=Z("menu",_t),qt=({variant:e})=>({menuGroup:y("flex flex-col gap-0.5 mb-0.5 last:mb-0","rounded-lg py-0.5 px-1 shadow-2 first:rounded-t-2xl last:rounded-b-2xl",{"bg-surface-container":e==="standard","bg-tertiary-container text-on-tertiary-container":e==="vibrant"}),groupLabel:y("px-3 pt-2 text-label-small tracking-wide ",{"text-on-surface-variant":e==="standard","text-on-tertiary-container opacity-80":e==="vibrant"})}),xs=ne("menuGroup",qt),Ut=Z("menuGroup",qt),Xt=({variant:e,isVisible:t})=>({progressIndicator:y((e==="linear-determinate"||e=="linear-indeterminate")&&"flex w-full h-1",e==="linear-indeterminate"&&"relative overflow-hidden rounded-full"),firstTrack:y((e==="linear-determinate"||e==="linear-indeterminate")&&"h-full rounded-full bg-primary-container",{"max-h-0":!t,"max-h-full":t}),activeIndicator:y("h-full rounded-full bg-primary",e==="linear-determinate"&&{"rounded-l-full":!0},(e==="linear-indeterminate"||e==="linear-determinate")&&{"max-h-0":!t,"max-h-full":t},(e==="circular-determinate"||e=="circular-indeterminate")&&["stroke-primary fill-transparent ",{"stroke-[4px]":t,"stroke-[0px]":!t}]),lastTrack:y((e==="linear-determinate"||e=="linear-indeterminate")&&"h-full flex-1 rounded-full bg-primary-container",{"max-h-0":!t,"max-h-full":t}),stop:y("absolute top-1/2 -translate-y-1/2 right-0 bg-primary rounded-full size-1",{"max-h-0":!t,"max-h-full":t})}),vs=ne("progressIndicator",Xt),Gt=Z("progressIndicator",Xt),qe=({variant:e,position:t})=>({sideSheet:y("bg-surface flex justify-between max-w-xs z-10",{"flex-row-reverse":t=="right","h-full":e=="standard"},e=="modal"&&["rounded-2xl fixed top-0 m-[1rem] h-[calc(100dvh-2rem)]",{"right-0":t=="right","left-0":t=="left"}]),container:y("w-full overflow-hidden flex flex-col",{}),header:y("p-4 flex items-center gap-2"),content:y("flex-1 overflow-y-auto"),title:y("text-on-surface-variant text-title-large"),closeButton:y("ml-auto"),divider:y({hidden:e=="modal"}),overlay:y("bg-[black]/[0.32] fixed top-0 left-0 w-screen h-screen")}),Kt=ne("sideSheet",qe),gs=Z("sideSheet",qe),Ue=({isChanging:e})=>({slider:y(["relative w-full h-11 flex items-center rounded gap-x-1.5 cursor-pointer min-w-32"]),activeTrack:y(["h-4 relative transition-all duration-100 bg-primary overflow-hidden rounded-l-full "]),inactiveTrack:y(["h-4 relative transition-all duration-100 bg-primary-container rounded-r-full overflow-hidden"]),handle:y(["transform relative transition-all duration-100 bg-primary h-full rounded-full ",{"w-0.5":e,"w-1":!e}]),valueIndicator:y(["absolute select-none bg-inverse-surface text-inverse-on-surface py-3 px-4 text-label-large rounded-full bottom-[calc(100%+4px)] transform left-1/2 -translate-x-1/2"]),dot:y(["h-1 w-1 absolute transform -translate-y-1/2 -translate-x-1/2 top-1/2 rounded-full"])}),ws=ne("slider",Ue),Jt=Z("slider",Ue),Zt=()=>({snackbar:y(" rounded bg-inverse-surface "),container:y("pl-4 pr-2 max-w-full py-1 flex items-center flex-wrap"),supportingText:y("text-body-medium text-inverse-on-surface "),icon:y(" ml-auto mr-0 text-inverse-on-surface block dark")}),bs=ne("snackbar",Zt),Qt=Z("snackbar",Zt),en=({isSelected:e,disabled:t,inactiveIcon:n})=>({switch:y("group/switch w-[52px] h-[32px] outline-none rounded-full border-2 flex items-center",{"bg-on-surface/[0.12] border-transparent":t},!t&&["cursor-pointer ",{"bg-primary border-primary":e},{"bg-surface-container border-outline":!e}]),handleContainer:y("flex items-center justify-center absolute",{"left-[14px]":!e},{"right-[14px]":e}),handle:y("transition-all duration-100 z-10 rounded-full flex items-center justify-center",{"w-[16px] h-[16px]":!e&&!n},{"w-[24px] h-[24px]":!(!e&&!n)},!t&&["cursor-pointer group-active/switch:h-[28px] group-active/switch:w-[28px]",{"bg-on-primary group-hover/switch:bg-primary-container":e},{"bg-outline group-hover/switch:bg-on-surface-variant":!e}],{"bg-surface":t}),handleStateLayer:y("w-[40px] h-[40px] -z-10 rounded-full absolute",{"group-state-primary":!t}),icon:y("w-[16px] h-[16px]",!t&&[{"text-on-primary-container":e},{"text-on-primary":!e}],{"text-on-surface/[0.38]":t})}),Ss=ne("switch",en),tn=Z("switch",en),nn=({isSelected:e,icon:t,label:n,variant:s})=>({tab:y("flex-1 group/tab outline-none flex px-4 justify-center items-center cursor-pointer",{"z-10":e},!!(t&&n)&&s==="primary"&&"h-16",!(t&&n&&s==="primary")&&"h-12"),stateLayer:y("absolute w-full h-full overflow-hidden left-1/2 top-1/2 transform -translate-y-1/2 -translate-x-1/2",s==="primary"&&{"group-hover/tab:hover-state-on-surface group-focus-visible/tab:focus-state-on-surface":!e,"group-hover/tab:hover-state-primary group-focus-visible/tab:focus-state-primary":e},s==="secondary"&&"group-hover/tab:hover-state-on-surface group-focus-visible/tab:focus-state-on-surface"),content:y("flex gap-0.5 h-full justify-center",{relative:s=="primary"},{"":!!(n&&!t)},s==="primary"&&"flex-col items-center",s==="secondary"&&{"flex-col items-center":!(n&&t),"flex-row items-center gap-2":!!(n&&t)}),icon:y("h-6 w-6 p-0.5 !box-border",s==="primary"&&{"text-on-surface-variant":!e,"text-primary":e},s==="secondary"&&{"text-on-surface-variant":!e,"text-on-surface":e}),label:y("text-title-small text-nowrap",s==="primary"&&{"text-on-surface-variant":!e,"text-primary":e},s==="secondary"&&{"text-on-surface-variant":!e,"text-on-surface":e}),underline:y("bg-primary absolute w-full left-0 bottom-0",s==="primary"&&"h-[3px] rounded-t",s==="secondary"&&"h-0.5")}),Es=ne("tab",nn),sn=Z("tab",nn),rn=({scrollable:e})=>({tabs:y("border-b border-surface-container-highest bg-surface","flex relative ",{"overflow-x-auto":e})}),Ns=ne("tabs",rn),on=Z("tabs",rn),ln=()=>({tabPanels:y("overflow-hidden")}),ks=ne("tabPanels",ln),an=Z("tabPanels",ln),cn=()=>({tabPanel:y("")}),js=ne("tabPanel",cn),un=Z("tabPanel",cn),dn=({disabled:e,leadingIcon:t,trailingIcon:n,variant:s,errorText:r,isFocused:u,value:c,suffix:a,multiline:d})=>({textField:y({"opacity-[.38]":e}),content:y("group/text-field transition-border duration-200 relative flex items-center ",{"h-14":!d},{"border-on-surface-variant":!(r!=null&&r.length)&&!u&&s=="filled","border-outline":!(r!=null&&r.length)&&!u&&s=="outlined","border-primary":!(r!=null&&r.length)&&u,"border-error":!!(r!=null&&r.length)},{"bg-on-surface/[0.04]":e},s=="filled"&&["rounded-t overflow-hidden border-b",{"bg-surface-container-highest":!e}],s=="outlined"&&["border rounded box-border",{"border-[3px]":u}]),stateLayer:y("absolute -z-10 w-full h-full top-0 left-0",{hidden:s=="outlined"},{"group-state-on-surface":!e,"focus-state-on-surface":u}),label:y("inline-flex outline-none whitespace-nowrap",{"text-on-surface-variant":!e&&!(r!=null&&r.length)},{"text-on-surface":e},{"text-error":!!(r!=null&&r.length)},{"text-primary":!(r!=null&&r.length)&&u}),input:y("w-full resize-none px-4 text-body-large bg-[inherit] outline-none autofill:transition-colors autofill:duration-[5000000ms]",{" text-on-surface placeholder:text-on-surface-variant":!e,"placeholder:text-on-surface text-on-surface":e},{"pr-0":!!a},s=="filled"&&" pb-2 pt-6",s=="outlined"&&"py-4 relative z-10"),activeIndicator:y("absolute w-0 inset-x-0 border-rounded mx-auto bottom-0",s=="filled"&&["h-[2px] transition-all duration-300",{"bg-primary":!(r!=null&&r.length)},{"bg-error":!!(r!=null&&r.length)},{"!w-full":u}]),supportingText:y(" text-body-small px-4 pt-1",{"text-on-surface-variant":!e&&!(r!=null&&r.length)},{"text-on-surface":e},{"!w-full":u},{"text-error":!!(r!=null&&r.length)}),leadingIcon:y(["h-12 ml-3 flex items-center justify-center",{"cursor-text":!o.isValidElement(t)}]),trailingIcon:y("h-12 w-12 flex items-center justify-center",{"cursor-text":!o.isValidElement(n)}),suffix:y("text-on-surface-variant pl-0 pr-4",s=="filled"&&" pb-2 pt-6",s=="outlined"&&"py-4 relative z-10")}),Ls=ne("textField",dn),fn=Z("textField",dn),hn=({position:e,variant:t})=>({toolTip:y(" pointer-events-auto w-max z-10 absolute m-1 w-max-content max-w-[312px]",t=="rich"&&"bg-surface-container rounded-2xl text-on-surface-container shadow-2",t=="plain"&&"bg-inverse-surface rounded text-inverse-on-surface ",{"bottom-full left-1/2 -translate-x-1/2":e=="top","top-full left-1/2 -translate-x-1/2":e=="bottom","right-full top-1/2 -translate-y-1/2":e=="left","left-full top-1/2 -translate-y-1/2":e=="right","bottom-full right-full":e=="top-left","bottom-full left-full":e=="top-right","top-full right-full":e=="bottom-left","top-full left-full":e=="bottom-right"}),container:y("pb-2",t=="rich"&&"px-4 pt-3 ",t=="plain"&&"px-2 py-1"),actions:y("flex gap-10 px-1 mt-2",t=="plain"&&"hidden"),subHead:y("text-title-small mb-1",t=="plain"&&"hidden"),supportingText:y(""),content:y("w-full")}),Ms=ne("toolTip",hn),mn=Z("toolTip",hn),le=({icon:e,colors:t=[],className:n,...s})=>{if(typeof e=="string"){let f=e,x="";return t[0]&&(x=` fill="${t[0]}" color="${t[0]}"`,f=f.replace(/<path([^>]*?)>/g,'<path$1 fill="currentColor">')),f=f.replace(/<svg([^>]*)>/,(h,m)=>`<svg${m.replace(/\s+(width|height)=["'][^"']*["']/g,"")} width="100%" height="100%"${x}>`),l.jsx("div",{className:y("size-5 box-content inline-flex fill-current",n),style:{color:t[0]||""},dangerouslySetInnerHTML:{__html:f}})}if(e&&typeof e=="object"&&"src"in e){const f=e;return l.jsx("img",{src:f.src,width:f.width,height:f.height,className:y("size-5 box-content",n),style:{filter:t[0]?"brightness(0) saturate(100%) invert(1)":void 0},alt:"","aria-hidden":"true"})}const r=e;if(!(r!=null&&r.prefix))throw new Error(`Invalid icon type: ${typeof e}`);const{icon:u}=r,[c,a,,,d]=u||[],i=f=>{switch(f.length){case 2:return{"--fa-primary-color":f[0]||"inherit","--fa-secondary-color":f[1]||"inherit"};case 1:return{color:f[0]};default:return{}}};return l.jsx("svg",{className:y("size-5 box-content",n),style:{...i(t)},xmlns:"http://www.w3.org/2000/svg",viewBox:`0 0 ${c} ${a}`,role:"img","aria-hidden":"true",...s,children:typeof d=="string"?l.jsx("path",{className:"fill-current",d}):d.map((f,x)=>l.jsx("path",{d:f},x))})},pn=({variant:e="linear-determinate",value:t=0,transitionDuration:n=1e3,className:s,...r})=>{const[u,c]=o.useState(t),[a]=o.useState(1.5);o.useEffect(()=>{t>100&&(t=100),t<0&&(t=0),c(t)},[t]);const[d,i]=o.useState(!0),f=()=>d?a:a*.5;o.useEffect(()=>{if(e==="circular-indeterminate"&&u!==100){const p=setInterval(()=>{c(d?20:40),i(!d)},f()*1e3);return()=>clearInterval(p)}},[e,d,u]);const[x,h]=o.useState(!1);o.useEffect(()=>{if(u>=100){const p=setTimeout(()=>{h(!1)},n);return()=>{clearTimeout(p)}}else h(!0)},[u,n]);const m=Gt({className:s,variant:e,value:t,transitionDuration:n,isVisible:x});return l.jsxs(l.Fragment,{children:[e==="linear-indeterminate"&&l.jsxs("div",{className:m.progressIndicator,...r,children:[l.jsx(Y.motion.div,{animate:{width:["0%","0%","0%","20%"],marginLeft:["0px","0px","6px","6px"],marginRight:["0px","0px","6px","6px"]},transition:{duration:1.5,repeat:1/0,ease:"easeInOut",times:[0,.499,.5,1]},style:{flexShrink:0},className:m.activeIndicator}),l.jsx(Y.motion.div,{animate:{width:["0%","40%","100%"]},transition:{duration:1.5,repeat:1/0,ease:"easeInOut"},style:{flexShrink:0},className:m.firstTrack}),l.jsx(Y.motion.div,{animate:{width:["20%","60%","20%"]},transition:{duration:1.5,repeat:1/0,ease:"easeInOut",times:[0,.5,1]},style:{flexShrink:0,marginLeft:"6px"},className:m.activeIndicator}),l.jsx("div",{style:{marginLeft:"6px"},className:m.lastTrack})]}),e==="linear-determinate"&&l.jsxs("div",{className:m.progressIndicator,...r,children:[l.jsx("div",{style:{width:`${u}%`,transition:`width ${n}ms ease-in-out ${u==100?", max-height 200ms 0.5s ease-in-out":""}`},className:m.activeIndicator}),l.jsx("div",{style:{marginLeft:u!=100?"6px":"0px",transition:`width ${n}ms ease-in-out ${u==100?`, max-height 200ms 0.5s ease-in-out, margin-left ${n}ms ${n/1.5}ms`:""}`},className:m.lastTrack}),l.jsx("div",{style:{width:"4px",transition:`width ${n}ms ease-in-out, max-height 200ms 0.5s ease-in-out`},className:m.stop})]}),(e==="circular-determinate"||e=="circular-indeterminate")&&l.jsx(Y.motion.svg,{width:"48",height:"48",viewBox:"0 0 48 48",initial:{rotate:-90},animate:{rotate:e==="circular-indeterminate"?270:-90},transition:e==="circular-indeterminate"?{repeat:1/0,duration:f(),ease:"linear"}:{duration:n/1e3},className:m.progressIndicator,...r,children:l.jsx(Y.motion.circle,{cx:"50%",cy:"50%",r:x?"calc(50% - 2px)":"50%",style:{strokeLinecap:"round"},initial:e==="circular-indeterminate"?"hidden":"determinate",animate:e==="circular-indeterminate"?"visible":"determinate",className:m.activeIndicator,variants:{hidden:{pathLength:d?10/100:90/100},visible:{pathLength:d?90/100:10/100},determinate:{pathLength:u/100}},transition:{pathLength:e==="circular-indeterminate"?{type:"tween",ease:"linear",duration:f(),bounce:0}:{type:"tween",ease:"easeInOut",duration:n/1e3}}})},e==="circular-indeterminate"?d+"":"static")]})};function Is(e){const t={primary:"filled",secondary:"tonal"};return e&&e in t?t[e]:e||"filled"}const me=({variant:e="filled",disabled:t=!1,icon:n,href:s,label:r,disableTextMargins:u,className:c,iconPosition:a="left",loading:d=!1,shape:i="rounded",onClick:f,onToggle:x,activated:h,ref:m,size:p="medium",allowShapeTransformation:b=!0,transition:w,children:L,...E})=>{if(L&&(r=L),!r)throw new Error("Button component requires either a label prop or children content");e=Is(e);const g=s?"a":"button",F=o.useRef(null),I=m||F,[v,k]=o.useState(h);o.useEffect(()=>{k(h)},[h]),w={duration:.3,...w};const D=j=>{t&&j.preventDefault(),x?(k(!v),x(!v)):f&&f(j)},M=Nt({allowShapeTransformation:b,size:p,disableTextMargins:u,shape:i,href:s,disabled:t,icon:n,iconPosition:a,loading:d,variant:e,transition:w,className:c,isActive:v??!1,onToggle:x,activated:v,label:r,children:r}),T=n?l.jsx(le,{icon:n,className:M.icon}):l.jsx(l.Fragment,{});return l.jsxs(g,{ref:I,href:s,className:M.button,...E,onClick:D,disabled:t,"aria-pressed":x?v:void 0,style:{transition:w.duration+"s"},children:[l.jsx("div",{className:M.touchTarget}),l.jsx(ue,{style:{transition:w.duration+"s"},className:M.stateLayer,colorName:y(e==="filled"&&{"on-surface-variant":!v&&!!x,"on-primary":v||!x},e==="elevated"&&{"on-primary":v&&!!x,primary:!v||!x},e==="tonal"&&{"on-secondary":v&&!!x,"on-secondary-container":!v||!x},e==="outlined"&&{"inverse-on-surface":v&&!!x,"on-surface-variant":!v||!x},e==="text"&&"primary"),stateClassName:"state-ripple-group-[button]"}),a==="left"&&T,d&&l.jsx("div",{className:"!absolute left-1/2 -translate-x-1/2 top-1/2 -translate-y-1/2",children:l.jsx(pn,{className:()=>({progressIndicator:"h-6 w-6",activeIndicator:y({"!stroke-primary":e==="elevated"&&!t,"!stroke-on-surface/[38%]":e==="elevated"&&t},{"!stroke-on-primary":e==="filled"&&!t,"!stroke-on-surface/[38%]":e==="filled"&&t},{"!stroke-on-secondary-container":e==="tonal"&&!t,"!stroke-on-surface/[38%]":e==="tonal"&&t},{"!stroke-primary":e==="outlined"&&!t,"!stroke-on-surface/[38%]":e==="outlined"&&t},{"!stroke-primary":e==="text"&&!t,"!stroke-on-surface/[38%]":e==="text"&&t})}),variant:"circular-indeterminate"})}),l.jsx("span",{className:M.label,children:r}),a==="right"&&T]})},Cs=({variant:e="outlined",className:t,children:n,interactive:s=!1,ref:r,...u})=>{const c=jt({className:t,interactive:s,variant:e,children:n}),a=o.useRef(null),d=r||a;return l.jsxs("div",{...u,ref:d,className:c.card,children:[s&&l.jsx(ue,{className:c.stateLayer,colorName:"on-surface",stateClassName:"state-ripple-group-[card]"}),n]})},ve=(e,t,n=[0,1])=>{const[s,r]=t,[u,c]=n,d=(Math.max(s,Math.min(e,r))-s)/(r-s);return u+d*(c-u)},yn=({className:e,children:t,width:n,index:s=0,outputRange:r,ref:u,...c})=>{const a=o.useRef(null),d=u||a,i=Lt({className:e,index:s,children:t});return l.jsx("div",{ref:d,style:{width:"var(--carousel-item-width, 100%)",maxWidth:r?r[1]+"px":void 0,minWidth:r?r[0]+"px":void 0},className:i.carouselItem,...c,children:t})},Rs=({variant:e="hero",className:t,children:n,ref:s,marginPourcent:r=0,inputRange:u=[.21,.65],outputRange:c=[42,300],gap:a=8,onChange:d,onMetricsChange:i,index:f,scrollSensitivity:x=1.25,...h})=>{const m=o.useRef(null),p=s||m,b=It({index:f,className:t,children:n,variant:e,inputRange:u,outputRange:c,marginPourcent:r,onChange:d,gap:a,scrollSensitivity:x,onMetricsChange:i}),w=o.Children.toArray(n).filter(A=>o.isValidElement(A)&&A.type===yn),L=o.useRef(null),E=o.useRef({scrollProgress:0,scrollTotal:0,scrollVisible:0,scroll:0}),g=o.useRef(0),F=o.useRef(null),I=o.useRef([]).current,[v,k]=o.useState(0);I.length!==w.length&&(I.length=0,w.forEach((A,W)=>{I[W]=o.createRef()}));const D=o.useCallback(()=>{if(!L.current||!p.current)return;const A=g.current,W=E.current.scrollVisible||p.current.clientWidth||0;function G(B,ee){return B.map((oe,pe)=>{const Se=(oe-ee)/Math.abs(B[1]-B[0]);return{itemScrollXCenter:oe,relativeIndex:Se,index:pe,width:0}})}const S=w.map((B,ee)=>{const oe=ee/Math.max(1,w.length-1);return ve(oe,[0,1],[0,1])}),N=G(S,A).sort((B,ee)=>B.index-ee.index);let C=W+a+c[0]+a,q=v;const U=N.sort((B,ee)=>Math.abs(B.relativeIndex)-Math.abs(ee.relativeIndex)).map((B,ee)=>{if(!(C<=0)){if(ee===0&&(q=B.index),B.width=ve(C-a,[c[0],c[1]],[c[0],c[1]]),C-=B.width+a,C!==0&&C<(c[0]+a)*2){const oe=B.width-((c[0]+a)*2-C);C+=B.width,B.width=oe,C-=B.width}else if(C===0&&B.width>=c[0]*2+a){const oe=B.width-(c[0]+a-C);C+=B.width,B.width=oe,C-=B.width}return B}}).filter(Boolean),J=[...U].reverse(),te=[...U].sort((B,ee)=>Math.abs(B.index)-Math.abs(ee.index));J.forEach((B,ee)=>{const oe=J[ee+1];if(!oe)return;const pe=1-(Math.abs(B.relativeIndex)-Math.abs(oe.relativeIndex)),Se=ve(pe,[0,2],[B.width+C,oe.width]);C+=B.width,B.width=Se,C-=B.width});const se=U.length/2,P=ve(Math.abs(te[0].relativeIndex),[te[0].index===0?0:se-1,se],[0,1]),_=ve(P,[0,1],[0,1])*-(c[0]+a);I.forEach((B,ee)=>{if(B.current){const oe=U.find(pe=>pe.index===ee);oe?(B.current.style.setProperty("--carousel-item-width",`${oe.width}px`),B.current.style.display="block"):(B.current.style.setProperty("--carousel-item-width",`${c[0]}px`),B.current.style.display="none")}}),L.current.style.transform=`translateX(${_}px)`,q!==v&&k(q)},[w.length,c,a,v]);o.useLayoutEffect(()=>{D()},[D,w.length]),o.useEffect(()=>{d&&d(v)},[v,d]);const[M,T]=o.useState(0);o.useEffect(()=>{T(v)},[v]);const j=(A,W={})=>{if(!w.length)return 0;const G=I[A];if(!G||!G.current||!L.current)return 0;const S=ve(A/Math.max(1,w.length-1),[0,1],[0,1]);return T(A),L.current.dispatchEvent(new CustomEvent("udx:customScroll:set",{bubbles:!0,detail:{progress:S,orientation:"horizontal",animate:W.animate!==!1}})),S};o.useEffect(()=>{typeof f=="number"&&w.length>0&&f!==v&&j(f)},[f,w.length]);const X=A=>{var W;if(E.current=A,A.scrollTotal>0){(W=F.current)==null||W.stop();const G=g.current??0,S=A.scrollProgress??0;F.current=Y.animate(G,S,{type:"spring",stiffness:260,damping:32,mass:.6,restDelta:5e-4,onUpdate:N=>{g.current=N,requestAnimationFrame(()=>{D()})}})}},V=o.useRef(i);o.useEffect(()=>{V.current=i},[i]);const Q=o.useRef(null);o.useEffect(()=>{const A=V.current;if(!A||!(p!=null&&p.current)||w.length<=0)return;const W=w.length,G=p.current.clientWidth||0,S=c[1],N=g.current,C=(G+a)/(S+a),q=Math.max(1,Math.floor(C)),U=Math.max(1,Math.round(q*(2/3))),J=Math.min(Math.max(0,v),Math.max(0,W-1)),te={total:W,selectedIndex:J,visibleApprox:C,visibleFull:q,stepHalf:U,canPrev:J>0,canNext:J<W-1,scrollProgress:N,viewportWidth:G,itemMaxWidth:S,gap:a},se=Q.current;let P=!se;if(!P){for(const _ in te)if(te[_]!==se[_]){P=!0;break}}P&&(Q.current=te,A(te))},[p,w.length,v,a,c]),o.useEffect(()=>()=>{var A;(A=F.current)==null||A.stop()},[]);const[z,$]=o.useState(0);o.useLayoutEffect(()=>{let A=c[1];const W=E.current;W&&A>W.scrollVisible&&W.scrollVisible>0&&(A=W.scrollVisible);const G=(A+a)*w.length/x;$(G||400)},[p,w.length,a,c,x]);const R=A=>{if(!w.length)return;const W=M??v;switch(A.key){case"ArrowLeft":A.preventDefault(),j(Math.max(0,W-1));break;case"ArrowRight":A.preventDefault(),j(Math.min(w.length-1,W+1));break;case"Home":A.preventDefault(),j(0);break;case"End":A.preventDefault(),j(w.length-1);break;case"Enter":case" ":A.preventDefault(),j(W);break}};o.useEffect(()=>{const A=p.current;if(!A)return;const W=G=>{const S=G.detail;S&&typeof S.index=="number"&&j(S.index)};return A.addEventListener("udx:carousel:centerIndex",W),()=>{A.removeEventListener("udx:carousel:centerIndex",W)}},[p,w.length]);const O=w.map((A,W)=>{var N;const G=(N=A.props)==null?void 0:N.onClick,S=C=>{G==null||G(C)};return o.cloneElement(A,{outputRange:c,ref:I[W],key:W,index:W,role:"option","aria-selected":v===W,tabIndex:v===W?0:-1,onClick:S,onFocus:()=>T(W)})});return l.jsx("div",{className:b.carousel,ref:p,role:"listbox","aria-orientation":"horizontal",onKeyDown:R,...h,children:l.jsx(vt,{draggable:!0,orientation:"horizontal",onScroll:X,scrollSize:z,children:l.jsx("div",{className:b.track,ref:L,style:{gap:`${a}px`,willChange:"transform"},children:O})})})};/*!
2
2
  * Font Awesome Free 7.2.0 by @fontawesome - https://fontawesome.com
3
3
  * License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License)
4
4
  * Copyright 2026 Fonticons, Inc.
5
- */var Ds={prefix:"fas",iconName:"minus",icon:[448,512,[8211,8722,10134,"subtract"],"f068","M0 256c0-17.7 14.3-32 32-32l384 0c17.7 0 32 14.3 32 32s-14.3 32-32 32L32 288c-17.7 0-32-14.3-32-32z"]},As={prefix:"fas",iconName:"calendar-days",icon:[448,512,["calendar-alt"],"f073","M128 0c17.7 0 32 14.3 32 32l0 32 128 0 0-32c0-17.7 14.3-32 32-32s32 14.3 32 32l0 32 32 0c35.3 0 64 28.7 64 64l0 288c0 35.3-28.7 64-64 64L64 480c-35.3 0-64-28.7-64-64L0 128C0 92.7 28.7 64 64 64l32 0 0-32c0-17.7 14.3-32 32-32zM64 240l0 32c0 8.8 7.2 16 16 16l32 0c8.8 0 16-7.2 16-16l0-32c0-8.8-7.2-16-16-16l-32 0c-8.8 0-16 7.2-16 16zm128 0l0 32c0 8.8 7.2 16 16 16l32 0c8.8 0 16-7.2 16-16l0-32c0-8.8-7.2-16-16-16l-32 0c-8.8 0-16 7.2-16 16zm144-16c-8.8 0-16 7.2-16 16l0 32c0 8.8 7.2 16 16 16l32 0c8.8 0 16-7.2 16-16l0-32c0-8.8-7.2-16-16-16l-32 0zM64 368l0 32c0 8.8 7.2 16 16 16l32 0c8.8 0 16-7.2 16-16l0-32c0-8.8-7.2-16-16-16l-32 0c-8.8 0-16 7.2-16 16zm144-16c-8.8 0-16 7.2-16 16l0 32c0 8.8 7.2 16 16 16l32 0c8.8 0 16-7.2 16-16l0-32c0-8.8-7.2-16-16-16l-32 0zm112 16l0 32c0 8.8 7.2 16 16 16l32 0c8.8 0 16-7.2 16-16l0-32c0-8.8-7.2-16-16-16l-32 0c-8.8 0-16 7.2-16 16z"]},Fs={prefix:"fas",iconName:"chevron-up",icon:[448,512,[],"f077","M201.4 105.4c12.5-12.5 32.8-12.5 45.3 0l192 192c12.5 12.5 12.5 32.8 0 45.3s-32.8 12.5-45.3 0L224 173.3 54.6 342.6c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3l192-192z"]},xn={prefix:"fas",iconName:"chevron-right",icon:[320,512,[9002],"f054","M311.1 233.4c12.5 12.5 12.5 32.8 0 45.3l-192 192c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3L243.2 256 73.9 86.6c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0l192 192z"]},Ps={prefix:"fas",iconName:"circle-exclamation",icon:[512,512,["exclamation-circle"],"f06a","M256 512a256 256 0 1 1 0-512 256 256 0 1 1 0 512zm0-192a32 32 0 1 0 0 64 32 32 0 1 0 0-64zm0-192c-18.2 0-32.7 15.5-31.4 33.7l7.4 104c.9 12.6 11.4 22.3 23.9 22.3 12.6 0 23-9.7 23.9-22.3l7.4-104c1.3-18.2-13.1-33.7-31.4-33.7z"]},Xe={prefix:"fas",iconName:"check",icon:[448,512,[10003,10004],"f00c","M434.8 70.1c14.3 10.4 17.5 30.4 7.1 44.7l-256 352c-5.5 7.6-14 12.3-23.4 13.1s-18.5-2.7-25.1-9.3l-128-128c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0l101.5 101.5 234-321.7c10.4-14.3 30.4-17.5 44.7-7.1z"]},ke={prefix:"fas",iconName:"xmark",icon:[384,512,[128473,10005,10006,10060,215,"close","multiply","remove","times"],"f00d","M55.1 73.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L147.2 256 9.9 393.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L192.5 301.3 329.9 438.6c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L237.8 256 375.1 118.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L192.5 210.7 55.1 73.4z"]},$s=ke,vn={prefix:"fas",iconName:"chevron-down",icon:[448,512,[],"f078","M201.4 406.6c12.5 12.5 32.8 12.5 45.3 0l192-192c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L224 338.7 54.6 169.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l192 192z"]},Ts={prefix:"fas",iconName:"chevron-left",icon:[320,512,[9001],"f053","M9.4 233.4c-12.5 12.5-12.5 32.8 0 45.3l192 192c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L77.3 256 246.6 86.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0l-192 192z"]},Ws={prefix:"fas",iconName:"bars",icon:[448,512,["navicon"],"f0c9","M0 96C0 78.3 14.3 64 32 64l384 0c17.7 0 32 14.3 32 32s-14.3 32-32 32L32 128C14.3 128 0 113.7 0 96zM0 256c0-17.7 14.3-32 32-32l384 0c17.7 0 32 14.3 32 32s-14.3 32-32 32L32 288c-17.7 0-32-14.3-32-32zM448 416c0 17.7-14.3 32-32 32L32 448c-17.7 0-32-14.3-32-32s14.3-32 32-32l384 0c17.7 0 32 14.3 32 32z"]};const Bs=({checked:e,defaultChecked:t,indeterminate:n=!1,disabled:s=!1,error:r=!1,onChange:u,id:c,name:a,value:d,style:i,className:f,...x})=>{const h=o.useId(),m=c||h,p=e!==void 0,[b,w]=o.useState(t??!1),L=p?e:b,[E,g]=o.useState(!1),F=o.useRef(null);o.useEffect(()=>{F.current&&(F.current.indeterminate=n)},[n]);const I=N=>{s||(p||w(N.target.checked),u&&u(N))},v=Rt({isChecked:!!L,isIndeterminate:n,isDisabled:s,isError:r,isFocused:E,isHovered:!1});return l.jsx("div",{className:y(v.checkbox,f,"group/checkbox"),style:i,children:l.jsxs(ue,{stateClassName:v.stateLayer,colorName:L||n?"primary":"on-surface",children:[l.jsx("input",{ref:F,type:"checkbox",id:m,name:a,value:d,checked:L,disabled:s,onChange:I,onFocus:()=>g(!0),onBlur:()=>g(!1),className:v.input,...x}),l.jsx("div",{className:v.box}),l.jsx(Y.AnimatePresence,{children:(L||n)&&l.jsx(Y.motion.div,{initial:{opacity:0,scale:.5},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.5},transition:{duration:.15},className:v.icon,children:l.jsx(le,{icon:n?Ds:Xe,className:"size-3.5"})})})]})})},Oe=({variant:e="outlined",disabled:t=!1,icon:n,href:s,label:r,className:u,onClick:c,onToggle:a,activated:d,ref:i,onRemove:f,editable:x,onEditStart:h,onEditCommit:m,onEditCancel:p,onChange:b,transition:w,children:L,editing:E,...g})=>{if(L&&(r=L),r===void 0&&!x)throw new Error("Chip component requires either a label prop or children content");const F=s?"a":"button",I=o.useRef(null),v=i||I,[N,R]=o.useState(d),[M,W]=o.useState(!1),[j,X]=o.useState(E&&x),[V,Q]=o.useState(!1),[z,$]=o.useState(typeof r=="string"?r:""),D=o.useRef(null);o.useEffect(()=>{R(d)},[d]),o.useEffect(()=>{if(E&&X(E),x&&M){const P=setTimeout(()=>{g!=null&&g.draggable&&V||X(!0)},1e3);return()=>clearTimeout(P)}else M||X(!1)},[M,x,V,g,z]),o.useEffect(()=>{if(j){$(typeof r=="string"?r:"");const P=te.current||D.current;if(P){P.focus();const _=document.createRange();_.selectNodeContents(P),_.collapse(!1);const O=window.getSelection();O==null||O.removeAllRanges(),O==null||O.addRange(_)}}},[j]),w={duration:.3,...w};const B=P=>{t&&P.preventDefault(),a?(R(!N),a(!N)):c&&c(P)},A=!!a||!!f||!!c||!!s||!!x;d&&(n=Xe);const{onFocus:T,onBlur:G,onKeyDown:S,onDragStart:k,onDragEnd:C,onDoubleClick:q,...U}=g??{},J=At({href:s,disabled:t,icon:n,variant:e,transition:w,className:u,isActive:N??!1,onToggle:a,activated:N,label:r,isInteractive:A,children:r,isFocused:M,isDragging:V,onEditCommit:m,isEditing:j}),te=o.useRef(null),se=()=>{const P=(z??"").trim();if(!P){f&&f();return}m==null||m(P)};return l.jsxs(F,{contentEditable:!1,ref:v,href:s,className:J.chip,...U,onClick:P=>{j||B(P)},draggable:!t&&!!(g!=null&&g.draggable),onDragStart:P=>{!t&&(g!=null&&g.draggable)&&Q(!0),k==null||k(P)},onDragEnd:P=>{g!=null&&g.draggable&&Q(!1),C==null||C(P)},onDoubleClick:P=>{!t&&x&&!j&&(h==null||h(),P.preventDefault(),P.stopPropagation()),q==null||q(P)},onFocus:P=>{A&&W(!0),T==null||T(P)},onBlur:P=>{W(!1),G==null||G(P)},onKeyDown:P=>{const _=P.key;if(!t&&j){_==="Enter"?(P.preventDefault(),se()):_==="Escape"?(P.preventDefault(),p==null||p()):f&&(z==null?void 0:z.trim())===""&&(_==="Backspace"||_==="Delete"||_==="Del")&&(P.preventDefault(),P.stopPropagation(),f());return}if(!t&&M){if(x&&!a&&(_==="F2"||_==="Enter")){P.preventDefault(),h==null||h();return}if(a&&(_==="Enter"||_===" "||_==="Spacebar")){P.preventDefault();const O=!N;R(O),a(O)}f&&(_==="Backspace"||_==="Delete"||_==="Del")&&(P.preventDefault(),P.stopPropagation(),f())}S==null||S(P)},disabled:t,"aria-pressed":a?N:void 0,style:{transition:w.duration+"s"},children:[A&&!t&&!j&&l.jsx(ue,{style:{transition:w.duration+"s"},className:J.stateLayer,colorName:y({"on-surface-variant":!N,"on-secondary-container":N}),stateClassName:"state-ripple-group-[chip]"}),n&&l.jsx(le,{icon:n,className:J.leadingIcon}),l.jsx("span",{ref:te,contentEditable:!!x&&!!j,suppressContentEditableWarning:!0,className:J.label,role:x?"textbox":void 0,spellCheck:!1,onInput:P=>{const _=P.currentTarget.innerText;$(_),b==null||b(_)},onBlur:P=>{x&&j&&se()},onKeyDown:P=>{if(x&&j&&P.key==="Enter"){P.preventDefault(),P.stopPropagation(),se();return}x&&j&&P.key==="Escape"&&(P.preventDefault(),P.stopPropagation(),p==null||p())},children:r}),f&&!j&&l.jsx(le,{icon:ke,className:J.trailingIcon,onMouseDown:P=>{P.preventDefault(),P.stopPropagation()},onClick:P=>{P.stopPropagation(),t||f()}})]})},Os=({variant:e,disabled:t,isActive:n})=>({menuItem:y("group/menu-item text-start overflow-hidden flex items-center h-12 px-3 cursor-pointer outline-none select-none shrink-0 ","text-label-large","transition-colors duration-200","rounded-xl",{"text-on-surface":!e||e==="standard","opacity-38 pointer-events-none":t},(e==="vibrant"||n)&&["bg-secondary-container text-on-secondary-container"]),itemLabel:y("flex-1 truncate"),itemIcon:y("w-6 h-6 flex items-center justify-center menu-item-icon"),leadingIcon:y("mr-3"),trailingIcon:y("ml-3")}),Hs=Z("menuItem",Os),Ie=({label:e,children:t,leadingIcon:n,trailingIcon:s,disabled:r,variant:u="standard",href:c,onClick:a,onToggle:d,activated:i=!1,className:f,...x})=>{let h=null;const m=[];o.Children.forEach(t,j=>{var X,V;o.isValidElement(j)&&(((X=j.type)==null?void 0:X.name)==="Menu"||((V=j.type)==null?void 0:V.displayName)==="Menu")?h=j:m.push(j)});const p=m.length>0?m:e,[b,w]=o.useState(!1),[L,E]=o.useState(i);L&&(n=Xe);const g=o.useRef(null),F=o.useRef(null);o.useEffect(()=>{E(i)},[i]);const I=Hs({variant:u,disabled:r,className:f,activated:L,isActive:L}),v=j=>{if(console.log("refrefd",r,h,d),r){j.preventDefault();return}if(h){j.stopPropagation();return}d?(E(!L),d(!L)):(console.log("click",a),a==null||a(j))},N=()=>{F.current&&(clearTimeout(F.current),F.current=null),!r&&h&&w(!0)},R=()=>{h&&(F.current=setTimeout(()=>{w(!1)},150))};o.useEffect(()=>()=>{F.current&&clearTimeout(F.current)},[]);const M=s??(h?xn:void 0),W=c?"a":"button";return l.jsxs(W,{ref:g,href:c,className:I.menuItem,onClick:v,onMouseEnter:N,onMouseLeave:R,role:"option","aria-haspopup":!!h,"aria-expanded":b,"aria-pressed":d?L:void 0,tabIndex:r?-1:0,disabled:c?void 0:r,onKeyDown:j=>{(j.key==="Enter"||j.key===" ")&&(j.preventDefault(),h?w(!b):v(j)),j.key==="ArrowRight"&&h&&(w(!0),j.stopPropagation()),j.key==="ArrowLeft"&&b&&(w(!1),j.stopPropagation())},...x,children:[l.jsx(ue,{className:"absolute inset-0 pointer-events-none",colorName:y(u==="vibrant"||L?"on-tertiary-container":"on-secondary-container"),stateClassName:"state-ripple-group-[menu-item]"}),n&&l.jsx("div",{className:y(I.itemIcon,I.leadingIcon,"z-10 relative"),children:o.isValidElement(n)?n:l.jsx(le,{icon:n})}),l.jsx("span",{className:y(I.itemLabel,"z-10 relative"),children:p}),M&&l.jsx("div",{className:y(I.itemIcon,I.trailingIcon,"z-10 relative"),children:o.isValidElement(M)?M:l.jsx(le,{icon:M})}),h&&b&&l.jsx(be,{anchorRef:g,position:"inline-end span-block-end",hoverOpen:!0,children:l.jsx("div",{onMouseEnter:N,onMouseLeave:R,children:h})})]})},je=({orientation:e="horizontal",className:t,...n})=>{const s=Tt({orientation:e,className:t});return l.jsx("hr",{className:s.divider,...n})},Vs=({props:e})=>({headline:y("px-3 py-1 text-label-small opacity-60 mt-1",{"text-on-surface-variant":!(e!=null&&e.variant)||e.variant==="standard"})}),zs=Z("menu-headline",Vs),Ge=({label:e,children:t,variant:n,className:s,...r})=>{const u=zs({variant:n,className:s});return l.jsx("div",{className:u.headline,role:"group","aria-label":e,...r,children:t??e})},He=({children:e,className:t,variant:n,label:s,...r})=>{const u=Ut({children:e,className:t,variant:n,label:s,...r});return l.jsxs("div",{className:u.menuGroup,role:"group",...r,children:[s&&l.jsx("div",{className:u.groupLabel,children:s}),e]})},Ke=({children:e,className:t,variant:n="standard",...s})=>{const r=o.Children.toArray(e).some(d=>o.isValidElement(d)&&d.type===He),u=Yt({children:e,className:t,variant:n,hasGroups:r,...s}),c=o.useRef(null),a=d=>o.Children.map(d,i=>{if(!o.isValidElement(i))return i;if(i.type===He){const f=a(i.props.children);return o.cloneElement(i,{children:f,variant:n})}return i.type===Ie?o.cloneElement(i,{variant:i.props.variant??n}):i.type===Ge?o.cloneElement(i,{variant:n}):i.type===je?o.cloneElement(i,{className:y("my-1",i.props.className)}):i});return l.jsxs("div",{ref:c,className:u.menu,role:"listbox",...s,children:[a(e),o.Children.count(e)===0&&l.jsx("div",{className:"px-4 py-3 text-on-surface-variant opacity-60 italic text-body-medium",children:"No options"})]})},_s=({trigger:e,children:t,...n})=>{const[s,r]=o.useState(null),u=o.useRef(null),c=f=>{f.preventDefault(),r({mouseX:f.clientX,mouseY:f.clientY})},a=()=>{r(null)},d=()=>{a()};o.useEffect(()=>{if(!s)return;const f=()=>r(null);return window.addEventListener("click",f),window.addEventListener("scroll",f,!0),()=>{window.removeEventListener("click",f),window.removeEventListener("scroll",f,!0)}},[s]);const i=o.isValidElement(e)?o.cloneElement(e,{onContextMenu:f=>{var x,h;c(f),(h=(x=e.props).onContextMenu)==null||h.call(x,f)}}):l.jsx("div",{onContextMenu:c,className:"inline-block",children:e});return l.jsxs(l.Fragment,{children:[i,l.jsx("div",{ref:u,style:{position:"fixed",top:(s==null?void 0:s.mouseY)??0,left:(s==null?void 0:s.mouseX)??0,width:1,height:1,pointerEvents:"none",visibility:"hidden"}}),s&&l.jsx(be,{anchorRef:u,position:"bottom right",onClick:f=>f.stopPropagation(),children:l.jsx(Ke,{onClick:d,...n,children:t})})]})},ie=[];for(let e=0;e<256;++e)ie.push((e+256).toString(16).slice(1));function Ys(e,t=0){return(ie[e[t+0]]+ie[e[t+1]]+ie[e[t+2]]+ie[e[t+3]]+"-"+ie[e[t+4]]+ie[e[t+5]]+"-"+ie[e[t+6]]+ie[e[t+7]]+"-"+ie[e[t+8]]+ie[e[t+9]]+"-"+ie[e[t+10]]+ie[e[t+11]]+ie[e[t+12]]+ie[e[t+13]]+ie[e[t+14]]+ie[e[t+15]]).toLowerCase()}let We;const qs=new Uint8Array(16);function Us(){if(!We){if(typeof crypto>"u"||!crypto.getRandomValues)throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");We=crypto.getRandomValues.bind(crypto)}return We(qs)}const Xs=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),ft={randomUUID:Xs};function gn(e,t,n){var r;if(ft.randomUUID&&!e)return ft.randomUUID();e=e||{};const s=e.random??((r=e.rng)==null?void 0:r.call(e))??Us();if(s.length<16)throw new Error("Random bytes length must be >= 16");return s[6]=s[6]&15|64,s[8]=s[8]&63|128,Ys(s)}const Gs=({variant:e="input",className:t,scrollable:n=!0,draggable:s=!1,items:r,onItemsChange:u})=>{const c=r??[],a=o.useRef(null),[d,i]=o.useState(!1),f=o.useRef(new WeakMap),x=o.useCallback(v=>{const N=f.current;let R=N.get(v);return R||(R=gn(),N.set(v,R)),R},[]);o.useEffect(()=>{var v,N;d&&(e=="input"?(v=F.current)==null||v.focus():(N=a.current)==null||N.focus())},[d]);const h=o.useRef([]),m=o.useRef(!1),p=o.useCallback(v=>{u==null||u(v(c))},[u,c]),b=o.useCallback(v=>{p(N=>N.filter((R,M)=>M!==v))},[p]),w=Pt({scrollable:n,className:t,variant:e}),L=o.useCallback((v="")=>{if(e!=="input"||m.current)return;m.current=!0;const N={label:v},R=x(N),M=[...c,N];u==null||u(M),requestAnimationFrame(()=>{g(R),m.current=!1})},[e,u,c,x]),[E,g]=o.useState(null);o.useEffect(()=>{var v;if(E){const N=c.findIndex(R=>x(R)===E);if(N!==-1){const R=h.current[N];(v=R==null?void 0:R.focus)==null||v.call(R);const M=a.current,W=R.offsetLeft+R.offsetWidth/2-M.offsetWidth/2;M.scrollTo({left:W,behavior:"smooth"})}}},[E,c,x]);const F=o.useRef(null),I=(d||c.length===0)&&e==="input";return l.jsxs("div",{ref:a,role:"list","aria-label":"Chips",className:w.chips,tabIndex:e==="input"?0:void 0,onFocus:v=>{v.target===v.currentTarget&&i(!0)},onBlur:()=>{i(!1)},onKeyDown:v=>{var X;if(e!=="input")return;const N=v.key,M=v.target===v.currentTarget;if(!d)return;const W=document.activeElement,j=h.current.findIndex(V=>V===W);if(N==="ArrowLeft"){v.preventDefault();const V=j>0?j-1:c.length-1,Q=x(c[V]);g(Q);return}if(N==="ArrowRight"){v.preventDefault();const V=j>=0?(j+1)%Math.max(1,c.length):0,Q=x(c[V]);g(Q);return}if(N==="Home"){v.preventDefault();const V=x(c[0]);g(V);return}if(N==="End"){v.preventDefault();const V=x(c[c.length-1]);g(V);return}if(M&&N==="Backspace"){if(v.preventDefault(),c.length>0){const V=h.current[c.length-1];(X=V==null?void 0:V.focus)==null||X.call(V)}return}},children:[c.map((v,N)=>{const R=x(v),M=e==="input",W=M?{editable:!0,editing:E===R,onEditCommit:j=>{i(!0),p(X=>X.map((V,Q)=>Q===N?{...V,label:j}:V))},onEditCancel:()=>{i(!0)},onChange:()=>{if(h.current.length==N+1){const j=a.current;requestAnimationFrame(()=>{j.scrollTo({left:j.scrollWidth,behavior:"smooth"})})}}}:{};return l.jsx(Oe,{ref:j=>h.current[N]=j,label:v.label??"",icon:v.icon,activated:v.activated,disabled:v.disabled,variant:v.variant,href:v.href,draggable:s,...W,onToggle:v.activated===void 0?void 0:j=>p(X=>X.map((V,Q)=>Q===N?{...V,activated:j}:V)),onBlur:()=>{E===R&&g(null)},onRemove:M?()=>{i(!0),b(N)}:void 0},R)}),d&&l.jsxs(l.Fragment,{children:[l.jsx(je,{orientation:"vertical",className:"animate-[var(--animate-blink)] border-outline",style:{"--animate-blink":"blink 1s cubic-bezier(0.4, 0, 0.6, 1) infinite"}}),l.jsx("style",{children:`
5
+ */var Ds={prefix:"fas",iconName:"minus",icon:[448,512,[8211,8722,10134,"subtract"],"f068","M0 256c0-17.7 14.3-32 32-32l384 0c17.7 0 32 14.3 32 32s-14.3 32-32 32L32 288c-17.7 0-32-14.3-32-32z"]},As={prefix:"fas",iconName:"calendar-days",icon:[448,512,["calendar-alt"],"f073","M128 0c17.7 0 32 14.3 32 32l0 32 128 0 0-32c0-17.7 14.3-32 32-32s32 14.3 32 32l0 32 32 0c35.3 0 64 28.7 64 64l0 288c0 35.3-28.7 64-64 64L64 480c-35.3 0-64-28.7-64-64L0 128C0 92.7 28.7 64 64 64l32 0 0-32c0-17.7 14.3-32 32-32zM64 240l0 32c0 8.8 7.2 16 16 16l32 0c8.8 0 16-7.2 16-16l0-32c0-8.8-7.2-16-16-16l-32 0c-8.8 0-16 7.2-16 16zm128 0l0 32c0 8.8 7.2 16 16 16l32 0c8.8 0 16-7.2 16-16l0-32c0-8.8-7.2-16-16-16l-32 0c-8.8 0-16 7.2-16 16zm144-16c-8.8 0-16 7.2-16 16l0 32c0 8.8 7.2 16 16 16l32 0c8.8 0 16-7.2 16-16l0-32c0-8.8-7.2-16-16-16l-32 0zM64 368l0 32c0 8.8 7.2 16 16 16l32 0c8.8 0 16-7.2 16-16l0-32c0-8.8-7.2-16-16-16l-32 0c-8.8 0-16 7.2-16 16zm144-16c-8.8 0-16 7.2-16 16l0 32c0 8.8 7.2 16 16 16l32 0c8.8 0 16-7.2 16-16l0-32c0-8.8-7.2-16-16-16l-32 0zm112 16l0 32c0 8.8 7.2 16 16 16l32 0c8.8 0 16-7.2 16-16l0-32c0-8.8-7.2-16-16-16l-32 0c-8.8 0-16 7.2-16 16z"]},Fs={prefix:"fas",iconName:"chevron-up",icon:[448,512,[],"f077","M201.4 105.4c12.5-12.5 32.8-12.5 45.3 0l192 192c12.5 12.5 12.5 32.8 0 45.3s-32.8 12.5-45.3 0L224 173.3 54.6 342.6c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3l192-192z"]},xn={prefix:"fas",iconName:"chevron-right",icon:[320,512,[9002],"f054","M311.1 233.4c12.5 12.5 12.5 32.8 0 45.3l-192 192c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3L243.2 256 73.9 86.6c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0l192 192z"]},Ps={prefix:"fas",iconName:"circle-exclamation",icon:[512,512,["exclamation-circle"],"f06a","M256 512a256 256 0 1 1 0-512 256 256 0 1 1 0 512zm0-192a32 32 0 1 0 0 64 32 32 0 1 0 0-64zm0-192c-18.2 0-32.7 15.5-31.4 33.7l7.4 104c.9 12.6 11.4 22.3 23.9 22.3 12.6 0 23-9.7 23.9-22.3l7.4-104c1.3-18.2-13.1-33.7-31.4-33.7z"]},Xe={prefix:"fas",iconName:"check",icon:[448,512,[10003,10004],"f00c","M434.8 70.1c14.3 10.4 17.5 30.4 7.1 44.7l-256 352c-5.5 7.6-14 12.3-23.4 13.1s-18.5-2.7-25.1-9.3l-128-128c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0l101.5 101.5 234-321.7c10.4-14.3 30.4-17.5 44.7-7.1z"]},ke={prefix:"fas",iconName:"xmark",icon:[384,512,[128473,10005,10006,10060,215,"close","multiply","remove","times"],"f00d","M55.1 73.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L147.2 256 9.9 393.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L192.5 301.3 329.9 438.6c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L237.8 256 375.1 118.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L192.5 210.7 55.1 73.4z"]},$s=ke,vn={prefix:"fas",iconName:"chevron-down",icon:[448,512,[],"f078","M201.4 406.6c12.5 12.5 32.8 12.5 45.3 0l192-192c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L224 338.7 54.6 169.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l192 192z"]},Ws={prefix:"fas",iconName:"chevron-left",icon:[320,512,[9001],"f053","M9.4 233.4c-12.5 12.5-12.5 32.8 0 45.3l192 192c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L77.3 256 246.6 86.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0l-192 192z"]},Ts={prefix:"fas",iconName:"bars",icon:[448,512,["navicon"],"f0c9","M0 96C0 78.3 14.3 64 32 64l384 0c17.7 0 32 14.3 32 32s-14.3 32-32 32L32 128C14.3 128 0 113.7 0 96zM0 256c0-17.7 14.3-32 32-32l384 0c17.7 0 32 14.3 32 32s-14.3 32-32 32L32 288c-17.7 0-32-14.3-32-32zM448 416c0 17.7-14.3 32-32 32L32 448c-17.7 0-32-14.3-32-32s14.3-32 32-32l384 0c17.7 0 32 14.3 32 32z"]};const Os=({checked:e,defaultChecked:t,indeterminate:n=!1,disabled:s=!1,error:r=!1,onChange:u,id:c,name:a,value:d,style:i,className:f,...x})=>{const h=o.useId(),m=c||h,p=e!==void 0,[b,w]=o.useState(t??!1),L=p?e:b,[E,g]=o.useState(!1),F=o.useRef(null);o.useEffect(()=>{F.current&&(F.current.indeterminate=n)},[n]);const I=k=>{s||(p||w(k.target.checked),u&&u(k))},v=Rt({isChecked:!!L,isIndeterminate:n,isDisabled:s,isError:r,isFocused:E,isHovered:!1});return l.jsx("div",{className:y(v.checkbox,f,"group/checkbox"),style:i,children:l.jsxs(ue,{stateClassName:v.stateLayer,colorName:L||n?"primary":"on-surface",children:[l.jsx("input",{ref:F,type:"checkbox",id:m,name:a,value:d,checked:L,disabled:s,onChange:I,onFocus:()=>g(!0),onBlur:()=>g(!1),className:v.input,...x}),l.jsx("div",{className:v.box}),l.jsx(Y.AnimatePresence,{children:(L||n)&&l.jsx(Y.motion.div,{initial:{opacity:0,scale:.5},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.5},transition:{duration:.15},className:v.icon,children:l.jsx(le,{icon:n?Ds:Xe,className:"size-3.5"})})})]})})},Be=({variant:e="outlined",disabled:t=!1,icon:n,href:s,label:r,className:u,onClick:c,onToggle:a,activated:d,ref:i,onRemove:f,editable:x,onEditStart:h,onEditCommit:m,onEditCancel:p,onChange:b,transition:w,children:L,editing:E,...g})=>{if(L&&(r=L),r===void 0&&!x)throw new Error("Chip component requires either a label prop or children content");const F=s?"a":"button",I=o.useRef(null),v=i||I,[k,D]=o.useState(d),[M,T]=o.useState(!1),[j,X]=o.useState(E&&x),[V,Q]=o.useState(!1),[z,$]=o.useState(typeof r=="string"?r:""),R=o.useRef(null);o.useEffect(()=>{D(d)},[d]),o.useEffect(()=>{if(E&&X(E),x&&M){const P=setTimeout(()=>{g!=null&&g.draggable&&V||X(!0)},1e3);return()=>clearTimeout(P)}else M||X(!1)},[M,x,V,g,z]),o.useEffect(()=>{if(j){$(typeof r=="string"?r:"");const P=te.current||R.current;if(P){P.focus();const _=document.createRange();_.selectNodeContents(P),_.collapse(!1);const B=window.getSelection();B==null||B.removeAllRanges(),B==null||B.addRange(_)}}},[j]),w={duration:.3,...w};const O=P=>{t&&P.preventDefault(),a?(D(!k),a(!k)):c&&c(P)},A=!!a||!!f||!!c||!!s||!!x;d&&(n=Xe);const{onFocus:W,onBlur:G,onKeyDown:S,onDragStart:N,onDragEnd:C,onDoubleClick:q,...U}=g??{},J=At({href:s,disabled:t,icon:n,variant:e,transition:w,className:u,isActive:k??!1,onToggle:a,activated:k,label:r,isInteractive:A,children:r,isFocused:M,isDragging:V,onEditCommit:m,isEditing:j}),te=o.useRef(null),se=()=>{const P=(z??"").trim();if(!P){f&&f();return}m==null||m(P)};return l.jsxs(F,{contentEditable:!1,ref:v,href:s,className:J.chip,...U,onClick:P=>{j||O(P)},draggable:!t&&!!(g!=null&&g.draggable),onDragStart:P=>{!t&&(g!=null&&g.draggable)&&Q(!0),N==null||N(P)},onDragEnd:P=>{g!=null&&g.draggable&&Q(!1),C==null||C(P)},onDoubleClick:P=>{!t&&x&&!j&&(h==null||h(),P.preventDefault(),P.stopPropagation()),q==null||q(P)},onFocus:P=>{A&&T(!0),W==null||W(P)},onBlur:P=>{T(!1),G==null||G(P)},onKeyDown:P=>{const _=P.key;if(!t&&j){_==="Enter"?(P.preventDefault(),se()):_==="Escape"?(P.preventDefault(),p==null||p()):f&&(z==null?void 0:z.trim())===""&&(_==="Backspace"||_==="Delete"||_==="Del")&&(P.preventDefault(),P.stopPropagation(),f());return}if(!t&&M){if(x&&!a&&(_==="F2"||_==="Enter")){P.preventDefault(),h==null||h();return}if(a&&(_==="Enter"||_===" "||_==="Spacebar")){P.preventDefault();const B=!k;D(B),a(B)}f&&(_==="Backspace"||_==="Delete"||_==="Del")&&(P.preventDefault(),P.stopPropagation(),f())}S==null||S(P)},disabled:t,"aria-pressed":a?k:void 0,style:{transition:w.duration+"s"},children:[A&&!t&&!j&&l.jsx(ue,{style:{transition:w.duration+"s"},className:J.stateLayer,colorName:y({"on-surface-variant":!k,"on-secondary-container":k}),stateClassName:"state-ripple-group-[chip]"}),n&&l.jsx(le,{icon:n,className:J.leadingIcon}),l.jsx("span",{ref:te,contentEditable:!!x&&!!j,suppressContentEditableWarning:!0,className:J.label,role:x?"textbox":void 0,spellCheck:!1,onInput:P=>{const _=P.currentTarget.innerText;$(_),b==null||b(_)},onBlur:P=>{x&&j&&se()},onKeyDown:P=>{if(x&&j&&P.key==="Enter"){P.preventDefault(),P.stopPropagation(),se();return}x&&j&&P.key==="Escape"&&(P.preventDefault(),P.stopPropagation(),p==null||p())},children:r}),f&&!j&&l.jsx(le,{icon:ke,className:J.trailingIcon,onMouseDown:P=>{P.preventDefault(),P.stopPropagation()},onClick:P=>{P.stopPropagation(),t||f()}})]})},Bs=({variant:e,disabled:t,isActive:n})=>({menuItem:y("group/menu-item text-start overflow-hidden flex items-center h-12 px-3 cursor-pointer outline-none select-none shrink-0 ","text-label-large","transition-colors duration-200","rounded-xl",{"text-on-surface":!e||e==="standard","opacity-38 pointer-events-none":t},(e==="vibrant"||n)&&["bg-secondary-container text-on-secondary-container"]),itemLabel:y("flex-1 truncate"),itemIcon:y("w-6 h-6 flex items-center justify-center menu-item-icon"),leadingIcon:y("mr-3"),trailingIcon:y("ml-3")}),Hs=Z("menuItem",Bs),Ie=({label:e,children:t,leadingIcon:n,trailingIcon:s,disabled:r,variant:u="standard",href:c,onClick:a,onToggle:d,activated:i=!1,className:f,...x})=>{let h=null;const m=[];o.Children.forEach(t,j=>{var X,V;o.isValidElement(j)&&(((X=j.type)==null?void 0:X.name)==="Menu"||((V=j.type)==null?void 0:V.displayName)==="Menu")?h=j:m.push(j)});const p=m.length>0?m:e,[b,w]=o.useState(!1),[L,E]=o.useState(i);L&&(n=Xe);const g=o.useRef(null),F=o.useRef(null);o.useEffect(()=>{E(i)},[i]);const I=Hs({variant:u,disabled:r,className:f,activated:L,isActive:L}),v=j=>{if(console.log("refrefd",r,h,d),r){j.preventDefault();return}if(h){j.stopPropagation();return}d?(E(!L),d(!L)):(console.log("click",a),a==null||a(j))},k=()=>{F.current&&(clearTimeout(F.current),F.current=null),!r&&h&&w(!0)},D=()=>{h&&(F.current=setTimeout(()=>{w(!1)},150))};o.useEffect(()=>()=>{F.current&&clearTimeout(F.current)},[]);const M=s??(h?xn:void 0),T=c?"a":"button";return l.jsxs(T,{ref:g,href:c,className:I.menuItem,onClick:v,onMouseEnter:k,onMouseLeave:D,role:"option","aria-haspopup":!!h,"aria-expanded":b,"aria-pressed":d?L:void 0,tabIndex:r?-1:0,disabled:c?void 0:r,onKeyDown:j=>{(j.key==="Enter"||j.key===" ")&&(j.preventDefault(),h?w(!b):v(j)),j.key==="ArrowRight"&&h&&(w(!0),j.stopPropagation()),j.key==="ArrowLeft"&&b&&(w(!1),j.stopPropagation())},...x,children:[l.jsx(ue,{className:"absolute inset-0 pointer-events-none",colorName:y(u==="vibrant"||L?"on-tertiary-container":"on-secondary-container"),stateClassName:"state-ripple-group-[menu-item]"}),n&&l.jsx("div",{className:y(I.itemIcon,I.leadingIcon,"z-10 relative"),children:o.isValidElement(n)?n:l.jsx(le,{icon:n})}),l.jsx("span",{className:y(I.itemLabel,"z-10 relative"),children:p}),M&&l.jsx("div",{className:y(I.itemIcon,I.trailingIcon,"z-10 relative"),children:o.isValidElement(M)?M:l.jsx(le,{icon:M})}),h&&b&&l.jsx(be,{anchorRef:g,position:"inline-end span-block-end",hoverOpen:!0,children:l.jsx("div",{onMouseEnter:k,onMouseLeave:D,children:h})})]})},je=({orientation:e="horizontal",className:t,...n})=>{const s=Wt({orientation:e,className:t});return l.jsx("hr",{className:s.divider,...n})},Vs=({props:e})=>({headline:y("px-3 py-1 text-label-small opacity-60 mt-1",{"text-on-surface-variant":!(e!=null&&e.variant)||e.variant==="standard"})}),zs=Z("menu-headline",Vs),Ge=({label:e,children:t,variant:n,className:s,...r})=>{const u=zs({variant:n,className:s});return l.jsx("div",{className:u.headline,role:"group","aria-label":e,...r,children:t??e})},He=({children:e,className:t,variant:n,label:s,...r})=>{const u=Ut({children:e,className:t,variant:n,label:s,...r});return l.jsxs("div",{className:u.menuGroup,role:"group",...r,children:[s&&l.jsx("div",{className:u.groupLabel,children:s}),e]})},Ke=({children:e,className:t,variant:n="standard",...s})=>{const r=o.Children.toArray(e).some(d=>o.isValidElement(d)&&d.type===He),u=Yt({children:e,className:t,variant:n,hasGroups:r,...s}),c=o.useRef(null),a=d=>o.Children.map(d,i=>{if(!o.isValidElement(i))return i;if(i.type===He){const f=a(i.props.children);return o.cloneElement(i,{children:f,variant:n})}return i.type===Ie?o.cloneElement(i,{variant:i.props.variant??n}):i.type===Ge?o.cloneElement(i,{variant:n}):i.type===je?o.cloneElement(i,{className:y("my-1",i.props.className)}):i});return l.jsxs("div",{ref:c,className:u.menu,role:"listbox",...s,children:[a(e),o.Children.count(e)===0&&l.jsx("div",{className:"px-4 py-3 text-on-surface-variant opacity-60 italic text-body-medium",children:"No options"})]})},_s=({trigger:e,children:t,...n})=>{const[s,r]=o.useState(null),u=o.useRef(null),c=f=>{f.preventDefault(),r({mouseX:f.clientX,mouseY:f.clientY})},a=()=>{r(null)},d=()=>{a()};o.useEffect(()=>{if(!s)return;const f=()=>r(null);return window.addEventListener("click",f),window.addEventListener("scroll",f,!0),()=>{window.removeEventListener("click",f),window.removeEventListener("scroll",f,!0)}},[s]);const i=o.isValidElement(e)?o.cloneElement(e,{onContextMenu:f=>{var x,h;c(f),(h=(x=e.props).onContextMenu)==null||h.call(x,f)}}):l.jsx("div",{onContextMenu:c,className:"inline-block",children:e});return l.jsxs(l.Fragment,{children:[i,l.jsx("div",{ref:u,style:{position:"fixed",top:(s==null?void 0:s.mouseY)??0,left:(s==null?void 0:s.mouseX)??0,width:1,height:1,pointerEvents:"none",visibility:"hidden"}}),s&&l.jsx(be,{anchorRef:u,position:"bottom right",onClick:f=>f.stopPropagation(),children:l.jsx(Ke,{onClick:d,...n,children:t})})]})},ie=[];for(let e=0;e<256;++e)ie.push((e+256).toString(16).slice(1));function Ys(e,t=0){return(ie[e[t+0]]+ie[e[t+1]]+ie[e[t+2]]+ie[e[t+3]]+"-"+ie[e[t+4]]+ie[e[t+5]]+"-"+ie[e[t+6]]+ie[e[t+7]]+"-"+ie[e[t+8]]+ie[e[t+9]]+"-"+ie[e[t+10]]+ie[e[t+11]]+ie[e[t+12]]+ie[e[t+13]]+ie[e[t+14]]+ie[e[t+15]]).toLowerCase()}let Te;const qs=new Uint8Array(16);function Us(){if(!Te){if(typeof crypto>"u"||!crypto.getRandomValues)throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");Te=crypto.getRandomValues.bind(crypto)}return Te(qs)}const Xs=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),ft={randomUUID:Xs};function gn(e,t,n){var r;if(ft.randomUUID&&!e)return ft.randomUUID();e=e||{};const s=e.random??((r=e.rng)==null?void 0:r.call(e))??Us();if(s.length<16)throw new Error("Random bytes length must be >= 16");return s[6]=s[6]&15|64,s[8]=s[8]&63|128,Ys(s)}const Gs=({variant:e="input",className:t,scrollable:n=!0,draggable:s=!1,items:r,onItemsChange:u})=>{const c=r??[],a=o.useRef(null),[d,i]=o.useState(!1),f=o.useRef(new WeakMap),x=o.useCallback(v=>{const k=f.current;let D=k.get(v);return D||(D=gn(),k.set(v,D)),D},[]);o.useEffect(()=>{var v,k;d&&(e=="input"?(v=F.current)==null||v.focus():(k=a.current)==null||k.focus())},[d]);const h=o.useRef([]),m=o.useRef(!1),p=o.useCallback(v=>{u==null||u(v(c))},[u,c]),b=o.useCallback(v=>{p(k=>k.filter((D,M)=>M!==v))},[p]),w=Pt({scrollable:n,className:t,variant:e}),L=o.useCallback((v="")=>{if(e!=="input"||m.current)return;m.current=!0;const k={label:v},D=x(k),M=[...c,k];u==null||u(M),requestAnimationFrame(()=>{g(D),m.current=!1})},[e,u,c,x]),[E,g]=o.useState(null);o.useEffect(()=>{var v;if(E){const k=c.findIndex(D=>x(D)===E);if(k!==-1){const D=h.current[k];(v=D==null?void 0:D.focus)==null||v.call(D);const M=a.current,T=D.offsetLeft+D.offsetWidth/2-M.offsetWidth/2;M.scrollTo({left:T,behavior:"smooth"})}}},[E,c,x]);const F=o.useRef(null),I=(d||c.length===0)&&e==="input";return l.jsxs("div",{ref:a,role:"list","aria-label":"Chips",className:w.chips,tabIndex:e==="input"?0:void 0,onFocus:v=>{v.target===v.currentTarget&&i(!0)},onBlur:()=>{i(!1)},onKeyDown:v=>{var X;if(e!=="input")return;const k=v.key,M=v.target===v.currentTarget;if(!d)return;const T=document.activeElement,j=h.current.findIndex(V=>V===T);if(k==="ArrowLeft"){v.preventDefault();const V=j>0?j-1:c.length-1,Q=x(c[V]);g(Q);return}if(k==="ArrowRight"){v.preventDefault();const V=j>=0?(j+1)%Math.max(1,c.length):0,Q=x(c[V]);g(Q);return}if(k==="Home"){v.preventDefault();const V=x(c[0]);g(V);return}if(k==="End"){v.preventDefault();const V=x(c[c.length-1]);g(V);return}if(M&&k==="Backspace"){if(v.preventDefault(),c.length>0){const V=h.current[c.length-1];(X=V==null?void 0:V.focus)==null||X.call(V)}return}},children:[c.map((v,k)=>{const D=x(v),M=e==="input",T=M?{editable:!0,editing:E===D,onEditCommit:j=>{i(!0),p(X=>X.map((V,Q)=>Q===k?{...V,label:j}:V))},onEditCancel:()=>{i(!0)},onChange:()=>{if(h.current.length==k+1){const j=a.current;requestAnimationFrame(()=>{j.scrollTo({left:j.scrollWidth,behavior:"smooth"})})}}}:{};return l.jsx(Be,{ref:j=>h.current[k]=j,label:v.label??"",icon:v.icon,activated:v.activated,disabled:v.disabled,variant:v.variant,href:v.href,draggable:s,...T,onToggle:v.activated===void 0?void 0:j=>p(X=>X.map((V,Q)=>Q===k?{...V,activated:j}:V)),onBlur:()=>{E===D&&g(null)},onRemove:M?()=>{i(!0),b(k)}:void 0},D)}),d&&l.jsxs(l.Fragment,{children:[l.jsx(je,{orientation:"vertical",className:"animate-[var(--animate-blink)] border-outline",style:{"--animate-blink":"blink 1s cubic-bezier(0.4, 0, 0.6, 1) infinite"}}),l.jsx("style",{children:`
6
6
  @keyframes blink {
7
7
  0%, 50% { opacity: 1; }
8
8
  50.01%, 100% { opacity: 0; }
9
9
  }
10
- `})]}),I&&l.jsx(Oe,{ref:F,className:"opacity-0",draggable:s,editable:!0,editing:!0,onChange:v=>{var N;if(v=v.replace(/(&nbsp;)+/g," ").trim(),console.log("Ghost chip onChange",v,!!v),v)L(v);else if(c.length>0){const R=h.current[c.length-1];(N=R==null?void 0:R.focus)==null||N.call(R)}},onEditCommit:()=>{},onBlur:()=>{i(!1)},onFocus:v=>{i(!0),v.stopPropagation()},children:" "})]})};function wn({trigger:e=["hover","focus"],isOpen:t,defaultOpen:n=!1,onOpenChange:s,openDelay:r=400,closeDelay:u=150,id:c}={}){const a=o.useId(),d=c??`tooltip-${a}`,i=Array.isArray(e)?e:[e],f=typeof t=="boolean",[x,h]=o.useState(n?"hovered":"hidden"),[m,p]=o.useState(!1),b=o.useRef(null),w=o.useRef(null),L=o.useCallback(()=>{b.current&&(clearTimeout(b.current),b.current=null),w.current&&(clearTimeout(w.current),w.current=null)},[]);o.useEffect(()=>()=>L(),[L]);const E=o.useCallback($=>{if(f){const D=$!=="hidden";s==null||s(D)}else{h($);const D=$!=="hidden";s==null||s(D)}},[f,s]),g=f?t?"hovered":"hidden":x,F=g!=="hidden",I=$=>{switch($){case"hidden":return 0;case"hovered":return 1;case"focused":return 2;case"clicked":return 3;default:return 0}},v=o.useCallback($=>{L(),!(I($)<=I(g))&&(b.current=setTimeout(()=>{E($)},r))},[L,r,g,E]),N=o.useCallback($=>{L(),w.current=setTimeout(()=>{(!f&&I(x)<=I($)||f)&&E("hidden")},u)},[L,u,x,f,E]),R=o.useCallback(()=>{i.includes("hover")&&v("hovered")},[i,v]),M=o.useCallback(()=>{i.includes("hover")&&(g==="focused"||g==="clicked"||m||N("hovered"))},[i,g,m,N]),W=o.useCallback(()=>{i.includes("focus")&&(L(),E("focused"))},[i,L,E]),j=o.useCallback(()=>{if(i.includes("focus")&&g!=="clicked"){if(i.includes("hover")&&m){E("hovered");return}N("focused")}},[i,g,m,N,E]),X=o.useCallback(()=>{i.includes("click")&&(L(),E(g==="clicked"?"hidden":"clicked"))},[i,g,L,E]),V=o.useCallback($=>{$.key==="Escape"&&F&&(L(),E("hidden"),$.preventDefault())},[F,L,E]),Q=o.useCallback(()=>{p(!0),L()},[L]),z=o.useCallback(()=>{p(!1),i.includes("hover")&&g==="hovered"&&N("hovered")},[i,g,N]);return{triggerProps:{"aria-describedby":F?d:void 0,onMouseEnter:R,onMouseLeave:M,onFocus:W,onBlur:j,onClick:X,onKeyDown:V},tooltipProps:{id:d,role:"tooltip","aria-hidden":!F,onMouseEnter:Q,onMouseLeave:z},isOpen:F,state:g}}const Je=({variant:e="plain",buttons:t,className:n,children:s,title:r,text:u,content:c,position:a,targetRef:d,ref:i,trigger:f=["hover","focus"],transition:x,openDelay:h=400,closeDelay:m=150,isOpen:p,defaultOpen:b=!1,onOpenChange:w,id:L,anchorRef:E,...g})=>{const I=a||(e==="rich"?"bottom-right":"bottom");if(x={duration:.3,...x},!s&&!d)throw new Error("Tooltip must have a child or a targetRef");t&&!Array.isArray(t)&&(t=[t]);const v=o.useRef(null),R=E||(d||v),{triggerProps:M,tooltipProps:W,isOpen:j}=wn({trigger:f,isOpen:p,defaultOpen:b,onOpenChange:w,openDelay:h,closeDelay:m,id:L}),X=!d&&o.isValidElement(s)?o.cloneElement(s,{ref:v,...M,onMouseEnter:z=>{var $,D;M.onMouseEnter(),(D=($=s.props)==null?void 0:$.onMouseEnter)==null||D.call($,z)},onMouseLeave:z=>{var $,D;M.onMouseLeave(),(D=($=s.props)==null?void 0:$.onMouseLeave)==null||D.call($,z)},onFocus:z=>{var $,D;M.onFocus(),(D=($=s.props)==null?void 0:$.onFocus)==null||D.call($,z)},onBlur:z=>{var $,D;M.onBlur(),(D=($=s.props)==null?void 0:$.onBlur)==null||D.call($,z)},onClick:z=>{var $,D;M.onClick(),(D=($=s.props)==null?void 0:$.onClick)==null||D.call($,z)},onKeyDown:z=>{var $,D;M.onKeyDown(z),(D=($=s.props)==null?void 0:$.onKeyDown)==null||D.call($,z)}}):s;o.useEffect(()=>{if(!d)return;const z=d.current;if(!z)return;const $=()=>M.onMouseEnter(),D=()=>M.onMouseLeave(),B=()=>M.onFocus(),A=()=>M.onBlur(),T=()=>M.onClick(),G=S=>M.onKeyDown(S);return z.addEventListener("mouseenter",$),z.addEventListener("mouseleave",D),z.addEventListener("focus",B,!0),z.addEventListener("blur",A,!0),z.addEventListener("click",T),z.addEventListener("keydown",G),M["aria-describedby"]?z.setAttribute("aria-describedby",M["aria-describedby"]):z.removeAttribute("aria-describedby"),()=>{z.removeEventListener("mouseenter",$),z.removeEventListener("mouseleave",D),z.removeEventListener("focus",B,!0),z.removeEventListener("blur",A,!0),z.removeEventListener("click",T),z.removeEventListener("keydown",G)}},[d,M]);const V=mn({variant:e,buttons:t,className:n,title:r,text:u,position:I,trigger:f,targetRef:d,children:s}),Q={open:{opacity:1,height:"auto"},close:{opacity:0,height:16}};return l.jsxs(l.Fragment,{children:[X,l.jsx(Y.AnimatePresence,{children:j&&l.jsx(be,{anchorRef:R,position:I,children:l.jsx(Y.motion.div,{initial:"close",variants:Q,animate:"open",transition:{duration:x.duration},exit:"close",className:V.toolTip,...g,...W,children:l.jsx("div",{className:V.container,children:c?l.jsx("div",{className:V.content,children:c}):l.jsxs(l.Fragment,{children:[r&&l.jsx("div",{className:V.subHead,children:r}),u&&l.jsx("div",{className:V.supportingText,children:u}),t&&l.jsx("div",{className:V.actions,children:Array.isArray(t)&&t.map((z,$)=>l.jsx(me,{size:"small",variant:"text",...z},$))})]})})})})})]})},Ce=({className:e,label:t,variant:n="primary",size:s="medium",href:r,type:u,icon:c,extended:a=!1,ref:d,transition:i,children:f,...x})=>{if(f&&(t=f),!t)throw new Error("FAB component requires either a label prop or children content");const h=r?"a":"button",m=Bt({href:r,icon:c,extended:a,label:t,size:s,variant:n,className:e,transition:i,children:t});i={duration:.3,...i};const p=o.useRef(null),b=d||p,w={visible:{width:"auto",marginLeft:12,opacity:1,transition:{...i,opacity:{duration:i.duration/2,delay:i.duration-i.duration/2}}},hidden:{width:0,marginLeft:0,opacity:0,transition:{...i,marginLeft:{duration:i.duration/2,delay:i.duration-i.duration/2}}}};return l.jsxs(h,{...x,ref:b,href:r,"aria-label":a?void 0:t,className:m.fab,children:[l.jsx(Je,{trigger:a?null:void 0,text:t,targetRef:b}),l.jsx(ue,{style:{transition:i.duration+"s"},className:m.stateLayer,colorName:y({"on-primary":n=="primary","on-secondary":n=="secondary","on-tertiary":n=="tertiary","on-primary-container":n=="primaryContainer","on-secondary-container":n=="secondaryContainer","on-tertiary-container":n=="tertiaryContainer"}),stateClassName:"state-ripple-group-[fab]"}),l.jsx(le,{icon:c,className:m.icon}),l.jsx(Y.AnimatePresence,{children:a&&l.jsx(Y.motion.span,{variants:w,initial:"hidden",animate:"visible",exit:"hidden",className:m.label,children:t})})]})},ge=({variant:e="standard",href:t,disabled:n=!1,title:s,label:r,onToggle:u,activated:c=!1,onClick:a,icon:d,size:i="medium",iconSelected:f,className:x,ref:h,width:m="default",shape:p="rounded",allowShapeTransformation:b=!0,transition:w,children:L,...E})=>{if(L&&(r=L),!r)throw new Error("IconButton component requires either a label prop or children content to provide an accessible aria-label");!s&&s!==null&&(s=r);const[g,F]=o.useState(c),I=W=>{n&&W.preventDefault(),u?(F(!g),u(!g)):a&&a(W)};o.useEffect(()=>{F(c)},[c]);const v=t?"a":"button",N=zt({transition:w,shape:p,allowShapeTransformation:b,width:m,href:t,activated:g,label:r,iconSelected:f,isActive:g,onToggle:u,disabled:n,icon:d,variant:e,className:x,size:i,children:r,...E}),R=o.useRef(null),M=h||R;return w={duration:.3,...w},l.jsxs(v,{disabled:n,href:t,style:{transition:w.duration+"s"},className:N.iconButton,"aria-label":r,...E,title:void 0,onClick:I,ref:M,children:[s!==null&&l.jsx(Je,{targetRef:M,trigger:n?null:void 0,text:s}),l.jsx("div",{className:N.touchTarget}),l.jsx(ue,{style:{transition:w.duration+"s"},className:N.stateLayer,colorName:y(e==="standard"&&{"on-surface-variant":!g,"on-primary":g},e==="filled"&&{"on-surface-variant":!g&&!!u,"on-primary":g||!u},e==="tonal"&&{"on-secondary":g&&!!u,"on-secondary-container":!g||!u},e==="outlined"&&{"inverse-on-surface":g&&!!u,"on-surface-variant":!g||!u}),stateClassName:"state-ripple-group-[icon-button]"}),d?l.jsx(le,{icon:d,className:N.icon}):L]})},Ks=({className:e,label:t,variant:n="primary",size:s="medium",href:r,icon:u,extended:c=!1,ref:a,transition:d,children:i,open:f,defaultOpen:x=!1,onOpenChange:h,...m})=>{d={duration:.3,ease:"easeInOut",...d};const p=o.useRef(null),b=a||p,w=typeof f=="boolean",[L,E]=o.useState(x),g=w?f:L,F=j=>{w||E(j),h==null||h(j)},I=o.Children.toArray(i).filter(j=>o.isValidElement(j)&&j.type===me),v=Ht({href:r,icon:u,extended:c,label:t,size:s,variant:n,className:e,transition:d,children:t,open:g}),N=Y.motion.create(Ce),R=Y.motion.create(ge),M=j=>l.jsx(N,{icon:u,extended:c,label:t,variant:n+"Container",size:s,className:v.fab+" "+(e??""),"aria-expanded":g,onClick:()=>F(!0),style:{transition:"border-radius 0.3s ease-in-out"},transition:{duration:d.duration,ease:"easeInOut",borderRadius:{duration:d.duration,ease:"easeInOut"},background:{duration:d.duration,ease:"easeInOut"},...d},...j}),W=o.useId();return l.jsxs("div",{className:v.fabMenu,ref:b,...m,children:[l.jsx(Y.AnimatePresence,{children:g&&l.jsx("div",{className:v.actions,role:"menu","aria-hidden":!g,children:(()=>{const j=I.length;return I.map((X,V)=>{X.props;const Q=j-1-V,z=((d==null?void 0:d.delay)??0)+Q*.06,$={open:{overflow:"visible",opacity:1,width:"auto",transition:{...d,delay:z,opacity:{delay:(d==null?void 0:d.duration)/2+z}}},close:{overflow:"hidden",opacity:0,width:0,transition:{...d,delay:z,opacity:{duration:(d==null?void 0:d.duration)/1.5}}}};return l.jsx(Y.motion.div,{initial:"close",animate:"open",variants:$,transition:d,exit:"close",children:o.cloneElement(X,{key:V,shape:"rounded",variant:"filled",className:()=>({button:y("max-w-full overflow-hidden text-nowrap",{"px-0":!g,"bg-primary-container text-on-primary-container ":n==="primary","bg-secondary-container text-on-secondary-container":n==="secondary","bg-tertiary-container text-on-tertiary-container":n==="tertiary"}),stateLayer:y({"state-on-primary-container":n==="primary","state-on-secondary-container":n==="secondary","state-on-tertiary-container":n==="tertiary"})})})})})})()})}),M({className:"invisible pointer-events-none"}),l.jsxs("div",{className:"absolute right-0 top-0",children:[!g&&M({className:"",layout:!0,layoutId:"fab-menu"+W}),g&&l.jsx(l.Fragment,{children:l.jsx(R,{layout:!0,layoutId:"fab-menu"+W,variant:"filled",className:()=>({iconButton:y({"bg-primary text-on-primary":n==="primary","bg-secondary text-on-secondary":n==="secondary","bg-tertiary text-on-tertiary":n==="tertiary"}),stateLayer:y({"[--default-color:var(--color-on-primary)]":n==="primary","[--default-color:var(--color-on-secondary)]":n==="secondary","[--default-color:var(--color-on-tertiary)]":n==="tertiary"})}),style:{transition:"border-radius 0.3s ease-in-out"},transition:{duration:d.duration,ease:"easeInOut",borderRadius:{duration:d.duration,ease:"easeInOut"},background:{duration:d.duration,ease:"easeInOut"},...d},icon:$s,onClick:()=>F(!1),children:"Close"})})]})]})},Js=({className:e,valueFormatter:t,step:n=10,name:s,value:r=0,min:u=0,max:c=100,marks:a=[{value:0,label:"0"},{value:100,label:"100"}],ref:d,onChange:i,...f})=>{const x=D=>{const B=m(),A=h();return D===1/0?100:D===-1/0?0:(D-B)/(A-B)*100},h=(D=!1)=>D?c:c==1/0?a[(a==null?void 0:a.length)-1].value:c,m=(D=!1)=>D?u:u==-1/0?a[0].value:u,p=D=>{const B=m(!1);return(h(!1)-B)*D/100+B},[b,w]=o.useState(!1),L=o.useRef(null),E=d||L,[g,F]=o.useState(r),[I,v]=o.useState(x(r)),[N,R]=o.useState(!1);o.useEffect(()=>{F(r),v(x(r))},[r]);const M=D=>{R(!0),w(!0),X(D)},W=()=>{R(!1),w(!1)};o.useEffect(()=>(N?(window.addEventListener("mouseup",W),window.addEventListener("mousemove",X),window.addEventListener("touchend",W),window.addEventListener("touchmove",X)):(window.removeEventListener("mouseup",W),window.removeEventListener("mousemove",X),window.removeEventListener("touchend",W),window.removeEventListener("touchmove",X)),()=>{window.removeEventListener("mouseup",W),window.removeEventListener("mousemove",X),window.removeEventListener("touchend",W),window.removeEventListener("touchmove",X)}),[N]);const j=Jt({className:e,isChanging:b,marks:a,max:c,min:u,name:s,step:n,value:g,valueFormatter:t,onChange:i}),X=D=>{const B=E==null?void 0:E.current;if(B){const A=B.getBoundingClientRect().left,G=((D.type==="touchmove"||D.type==="touchstart"?D.touches[0].clientX:D.clientX)-A)/B.offsetWidth*100;V({percent:G})}},V=({percent:D,value:B})=>{if(D){if(D>=100){F(h(!0)),v(100);return}if(D<=0){F(m(!0)),v(0);return}B=p(D),B==m()&&(B=m(!0)),B==h()&&(B=h(!0))}else if(B!=null){if(B>=h()){F(h(!0)),v(100);return}if(B<=m()){F(m(!0)),v(0);return}D=x(B)}else return;n!=null?B=Math.round((B-m())/n)*n+m():a&&(B=a.reduce((A,T,G)=>{let S=T.value===1/0?h():T.value===-1/0?m():T.value,k=A.value===1/0?h():A.value===-1/0?m():A.value;return S=Math.abs(S-B),k=Math.abs(k-B),S<k?T:A}).value),B>=h()&&(B=h(!0)),B<=m()&&(B=m(!0)),D=x(B),F(B),v(D),i&&i(B)},[Q,z]=o.useState(0);o.useEffect(()=>{const D=()=>{E.current&&z(E.current.offsetWidth)};return D(),window.addEventListener("resize",D),()=>{window.removeEventListener("resize",D)}},[]);const $=D=>{switch(D.key){case"ArrowRight":if(n)V({value:g+n});else if(a){const B=a.find(A=>A.value>g);B&&V({value:B.value})}break;case"ArrowLeft":if(n)V({value:g-n});else if(a){const B=a.slice(0).reverse().find((A,T,G)=>g===1/0?T===1:A.value<g);B&&V({value:B.value})}break;default:return}};return l.jsxs("div",{tabIndex:0,onKeyDown:$,role:"slider","aria-valuemin":m(!0),"aria-valuemax":h(!0),"aria-valuenow":g,"aria-valuetext":g.toString(),className:j.slider,onMouseDown:M,onClick:X,ref:E,onTouchStart:M,onDragStart:D=>D.preventDefault(),...f,children:[l.jsx("input",{type:"hidden",name:s,value:g}),l.jsx("div",{className:j.activeTrack,style:{flex:I/100}}),l.jsx("div",{className:j.handle,children:l.jsx(Y.AnimatePresence,{children:b&&l.jsx(Y.motion.div,{className:j.valueIndicator,initial:"hidden",animate:"visible",exit:"hidden",style:{translate:"-50%",transformOrigin:"center bottom",textWrap:"nowrap"},variants:{visible:{opacity:1,scale:1},hidden:{opacity:1,scale:0}},transition:{duration:.1},children:t?t(g):g})})}),l.jsx("div",{className:j.inactiveTrack,style:{flex:1-I/100}}),l.jsx("div",{className:"w-[calc(100%-12px)] h-full absolute -translate-x-1/2 transform left-1/2",children:a&&a.map((D,B)=>{let A=null;const T=(b?9:10)/Q*100,G=x(D.value);return G<=I-T?A=!0:G>=I+T&&(A=!1),l.jsx("div",{className:y(j.dot,{"bg-primary-container":A!=null&&A,"bg-primary":A!=null&&!A}),style:{left:`${x(D.value)}%`}},B)})})]})},Zs=({variant:e="standard",className:t,children:n,title:s,position:r="right",extended:u,divider:c,onExtendedChange:a,closeIcon:d=ke,transition:i,...f})=>{i={duration:.3,...i};const[x,h]=o.useState(u??!0),m=Kt({transition:i,title:s,position:r,closeIcon:d,className:t,children:n,onExtendedChange:a,divider:c,isExtended:x,extended:x,variant:e});o.useEffect(()=>{a==null||a(x??!1)},[x]),o.useEffect(()=>{u!=null&&h(u)},[u]);const p={close:{width:0},open:{width:"auto"}},b=()=>l.jsxs(l.Fragment,{children:[l.jsx(Y.AnimatePresence,{children:e=="modal"&&x&&l.jsx(Y.motion.div,{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:i,onClick:()=>h(!1),className:m.overlay})}),l.jsx(Y.AnimatePresence,{children:x&&l.jsxs("div",{...f,className:m.sideSheet,style:{transition:i.duration+"s"},children:[l.jsxs(Y.motion.div,{variants:p,initial:u===!1?"open":"close",animate:"open",exit:"close",className:m.container,children:[l.jsxs("div",{className:m.header,children:[s&&l.jsx("p",{className:m.title,children:s}),l.jsx(ge,{size:"small",label:"close",icon:d,onClick:()=>h(!1),className:m.closeButton})]}),l.jsx("div",{className:m.content,style:{transition:i.duration+"s"},children:n})]}),(c==null&&e=="standard"?!0:c)&&l.jsx(je,{className:m.divider,orientation:"vertical"})]})})]});return e=="modal"?Ve.createPortal(b(),document.body):b()},Qs=({message:e,className:t,duration:n,closeIcon:s=ke,onClose:r,...u})=>{const[c,a]=o.useState(!0),d=Qt({className:t,closeIcon:s,duration:n,isVisible:c,onClose:r,message:e});o.useEffect(()=>{n&&setTimeout(()=>{i()},n)},[n]);const i=()=>{a(!1),r==null||r()};return l.jsx(Y.AnimatePresence,{children:c&&l.jsx(Y.motion.div,{initial:{height:0},animate:{height:"auto"},exit:{height:0},transition:{duration:.1},className:d.snackbar,...u,children:l.jsxs("div",{className:d.container,children:[l.jsx("p",{className:d.supportingText,children:e}),l.jsx(ge,{onClick:()=>i(),className:d.icon,icon:s,label:"close the snackbar"})]})})})},er=({selected:e=!1,className:t,activeIcon:n,disabled:s=!1,inactiveIcon:r,onChange:u,onClick:c,onKeyDown:a,ref:d,...i})=>{const[f,x]=o.useState(e);o.useEffect(()=>{x(e)},[e]);const h=E=>{s||(p(),c&&c(E))},m=E=>{s||((E.key===" "||E.key==="Enter")&&(E.preventDefault(),p()),a&&a(E))},p=()=>{x(!f),u==null||u(!f)},b=tn({className:t,isSelected:f,activeIcon:n,inactiveIcon:r,disabled:s,selected:f,onChange:u}),w=o.useRef(null),L=d||w;return l.jsxs(Y.motion.div,{role:"switch","aria-checked":f,tabIndex:s?-1:0,onKeyDown:m,onClick:h,ref:L,className:b.switch,...i,children:[l.jsx("input",{type:"hidden",value:f?"1":"0"}),l.jsxs(Y.motion.div,{layout:!0,style:{translate:f?"50%":"-50%"},transition:{type:"spring",stiffness:700,damping:30},className:b.handleContainer,children:[l.jsx("div",{className:b.handle,children:(f?n:r)&&l.jsx(le,{className:b.icon,icon:f?n:r})}),l.jsx("div",{className:b.handleStateLayer})]})]})},bn=({className:e,onClick:t,label:n,variant:s="primary",href:r,icon:u,selectedTab:c,setSelectedTab:a,tabsId:d,index:i,onTabSelected:f,scrollable:x=!1,selected:h=!1,children:m,ref:p,...b})=>{const w=o.useRef(null),L=p||w,E=n??(typeof m=="string"?m:void 0),[g,F]=o.useState(h);o.useEffect(()=>{h&&c==null?F(!0):F(c==i&&i!=null)},[c]),o.useEffect(()=>{c==i&&f&&f({ref:L,index:i||0,label:E,icon:u})},[c]);const I=r?"a":"button",v=R=>{a&&a(i??null),t&&t(R)},N=sn({className:e,onTabSelected:f,scrollable:x,selectedTab:c,index:i,tabsId:d,selected:g,variant:s,icon:u,label:E,isSelected:g,setSelectedTab:a,href:r});return l.jsxs(I,{...b,role:"tab","aria-selected":g,ref:L,href:r,className:N.tab,onClick:v,...b,children:[l.jsx(ue,{style:{transition:.3+"s"},className:N.stateLayer,colorName:s==="primary"&&g?"primary":"on-surface",stateClassName:"state-ripple-group-[tab]"}),l.jsxs("span",{className:N.content,children:[u&&l.jsx(le,{icon:u,className:N.icon}),l.jsx("span",{className:N.label,children:E}),g&&l.jsx(Y.motion.span,{layoutId:`underline-${d}`,className:N.underline,transition:{duration:.3}})]})]})},Ze=o.createContext(null),tr=({variant:e="primary",onTabSelected:t,children:n,className:s,selectedTab:r,setSelectedTab:u,scrollable:c=!1})=>{const a=o.useContext(Ze),[d,i]=o.useState(null);let f;r===0||r!=null?f=r:a?f=a.selectedTab:f=d;const x=u??(a==null?void 0:a.setSelectedTab)??i,h=o.Children.toArray(n).filter(L=>o.isValidElement(L)&&L.type===bn),m=o.useRef(null),p=L=>{if(t==null||t(L),c){const E=m.current,g=L.ref.current;if(E&&g){const F=g.offsetLeft+g.offsetWidth/2-E.offsetWidth/2;E.scrollTo({left:F,behavior:"smooth"})}}},b=o.useMemo(()=>(a==null?void 0:a.tabsId)??gn(),[a==null?void 0:a.tabsId]),w=on({children:n,onTabSelected:t,scrollable:c,selectedTab:f,setSelectedTab:x,className:s,variant:e});return l.jsx("div",{ref:m,role:"tablist",className:w.tabs,children:h.map((L,E)=>o.cloneElement(L,{key:E,index:E,variant:e,selectedTab:f,setSelectedTab:x,tabsId:b,onTabSelected:p,scrollable:c}))})},nr=({children:e,selectedTab:t,setSelectedTab:n,defaultTab:s=0})=>{const[r,u]=o.useState(s),c=o.useRef(null),a=t!==void 0?t:r,d=n??u,i=c.current!==null&&a!==null?a>c.current?1:-1:0;a!==c.current&&(c.current=a);const f=o.useId(),x=o.useMemo(()=>({selectedTab:a,setSelectedTab:d,previousTab:c.current,direction:i,tabsId:f}),[a,d,i,f]);return l.jsx(Ze.Provider,{value:x,children:e})},Sn=({children:e,className:t,isSelected:n=!1})=>{const s=un({children:e,className:t,isSelected:n});return l.jsx("div",{className:s.tabPanel,children:e})},sr=({children:e,className:t})=>{const n=o.useContext(Ze);if(!n)return console.warn("TabPanels must be used within a TabGroup"),null;const{selectedTab:s,direction:r,tabsId:u}=n,c=o.Children.toArray(e).filter(d=>o.isValidElement(d)&&d.type===Sn),a=an({children:e,className:t});return l.jsx("div",{className:a.tabPanels,children:l.jsx(Y.AnimatePresence,{initial:!1,custom:r,mode:"popLayout",children:c.map((d,i)=>s===i&&l.jsx(Y.motion.div,{custom:r,variants:{enter:f=>({x:f*100+"%",opacity:1}),center:{x:0,opacity:1},exit:f=>({x:f*-100+"%",opacity:1})},initial:"enter",animate:"center",exit:"exit",transition:{type:"spring",stiffness:400,damping:40},role:"tabpanel","aria-labelledby":`tab-${u}-${i}`,children:o.cloneElement(d,{isSelected:!0})},i))})})},rr=({hasSelected:e})=>({datePicker:y("inline-flex flex-col bg-surface-container-high rounded-[28px] p-3 select-none","min-w-[320px]"),header:y("flex items-center justify-between h-12 mb-2 px-2"),monthNav:y("flex items-center justify-center w-10 h-10 rounded-full text-on-surface-variant hover:bg-on-surface-variant/8 transition-colors cursor-pointer"),monthLabel:y("text-label-large text-on-surface font-bold capitalize"),weekDays:y("grid grid-cols-7 mb-2"),weekDay:y("h-10 flex items-center justify-center text-body-small text-on-surface-variant"),daysGrid:y("grid grid-cols-7 row-auto gap-y-2"),dayCell:y("flex items-center justify-center h-10 p-0 relative"),dayButton:y("w-10 h-10 rounded-full flex items-center justify-center text-body-large transition-all duration-200 relative overflow-hidden z-10 outline-none")}),or=Z("datePicker",rr),En=({value:e,defaultValue:t,onChange:n,minDate:s,maxDate:r,shouldDisableDate:u,locale:c="default",weekStartDay:a=0,className:d,style:i,mode:f="single",...x})=>{const[h,m]=o.useState(()=>{const S=C=>C instanceof Date?C:Array.isArray(C)&&C[0]?C[0]:null,k=S(e)||S(t)||new Date;return new Date(k.getFullYear(),k.getMonth(),1)}),[p,b]=o.useState(0),[w,L]=o.useState("day"),E=e!==void 0,[g,F]=o.useState(t||null),I=E?e||null:g,v=(S,k)=>new Date(S,k+1,0).getDate(),N=o.useMemo(()=>{const S=h.getFullYear(),k=h.getMonth(),C=v(S,k),U=(new Date(S,k,1).getDay()-a+7)%7,J=[],te=v(S,k-1);for(let _=U-1;_>=0;_--)J.push({date:new Date(S,k-1,te-_),isCurrentMonth:!1});for(let _=1;_<=C;_++)J.push({date:new Date(S,k,_),isCurrentMonth:!0});const P=42-J.length;for(let _=1;_<=P;_++)J.push({date:new Date(S,k+1,_),isCurrentMonth:!1});return J},[h,a]),R=o.useMemo(()=>{const S=new Date().getFullYear(),k=S-100,C=S+100,q=[];for(let U=k;U<=C;U++)q.push(U);return q},[]),M=o.useRef(null);o.useEffect(()=>{if(w==="year"&&M.current){const S=M.current.querySelector('[data-selected="true"]');S&&S.scrollIntoView({block:"center"})}},[w]);const W=o.useMemo(()=>new Intl.DateTimeFormat(c,{month:"long",year:"numeric"}),[c]),j=o.useMemo(()=>new Intl.DateTimeFormat(c,{weekday:"narrow"}),[c]),X=o.useMemo(()=>{const S=new Date(2023,0,1+a);return Array.from({length:7}).map((k,C)=>{const q=new Date(S);return q.setDate(S.getDate()+C),j.format(q).charAt(0).toUpperCase()})},[j,a]),V=()=>{b(-1),m(S=>new Date(S.getFullYear(),S.getMonth()-1,1))},Q=()=>{b(1),m(S=>new Date(S.getFullYear(),S.getMonth()+1,1))},z=S=>{m(k=>new Date(S,k.getMonth(),1)),L("day")},$=(S,k)=>S?S.getDate()===k.getDate()&&S.getMonth()===k.getMonth()&&S.getFullYear()===k.getFullYear():!1,D=S=>$(new Date,S),B=S=>{let k=S;if(f==="single")k=S;else{const C=I,[q,U]=Array.isArray(C)?C:[null,null];!q||q&&U?k=[S,null]:S<q?k=[S,q]:k=[q,S]}E||F(k),n&&n(k)},A=S=>{if(f==="single")return{isSelected:$(I,S),isStart:!1,isEnd:!1,isInRange:!1};const k=Array.isArray(I)?I:[I,null],[C,q]=k,U=$(C,S),J=$(q,S);let te=!1;if(C&&q){const se=new Date(C.getFullYear(),C.getMonth(),C.getDate()).getTime(),P=new Date(q.getFullYear(),q.getMonth(),q.getDate()).getTime(),_=new Date(S.getFullYear(),S.getMonth(),S.getDate()).getTime();te=_>se&&_<P}return{isSelected:U||J,isStart:U,isEnd:J,isInRange:te}},T=or({hasSelected:!!I}),G={enter:S=>({x:S>0?"100%":"-100%",opacity:0}),center:{x:0,opacity:1},exit:S=>({x:S<0?"100%":"-100%",opacity:0})};return l.jsxs("div",{className:y(T.datePicker,d),style:i,...x,children:[l.jsxs("div",{className:T.header,children:[l.jsxs(me,{variant:"text",disableTextMargins:!0,size:"small",onClick:()=>L(S=>S==="day"?"year":"day"),className:"text-label-large font-bold capitalize text-on-surface hover:bg-surface-container-highest",children:[l.jsx("span",{className:"mr-2",children:w==="day"?W.format(h):h.getFullYear()}),l.jsx(le,{icon:vn,className:y("w-3 h-3 transition-transform duration-200 inline",w==="year"&&"rotate-180")})]}),w==="day"&&l.jsxs("div",{className:"flex items-center",children:[l.jsx(ge,{size:"xSmall",allowShapeTransformation:!1,onClick:V,icon:Ts,label:"Previous month",title:null}),l.jsx(ge,{size:"xSmall",allowShapeTransformation:!1,onClick:Q,icon:xn,label:"Next month",title:null})]})]}),w==="year"?l.jsx("div",{className:"h-[280px] overflow-y-auto grid grid-cols-3 gap-2 p-2 scrollbar-hide",ref:M,children:R.map(S=>l.jsx(me,{size:"small",variant:S===h.getFullYear()?"filled":"text",onClick:()=>z(S),"data-selected":S===h.getFullYear(),className:y("w-full",{"text-on-surface":S!==h.getFullYear()}),label:S.toString(),children:S},S))}):l.jsxs(l.Fragment,{children:[l.jsx("div",{className:T.weekDays,children:X.map((S,k)=>l.jsx("div",{className:T.weekDay,children:S},k))}),l.jsx("div",{className:"overflow-hidden relative min-h-[240px]",children:l.jsx(Y.AnimatePresence,{mode:"popLayout",initial:!1,custom:p,children:l.jsx(Y.motion.div,{custom:p,variants:G,initial:"enter",animate:"center",exit:"exit",transition:{type:"spring",bounce:0,duration:.3},className:T.daysGrid,children:N.map((S,k)=>{if(!S.isCurrentMonth)return l.jsx("div",{className:T.dayCell},k);const{isSelected:C,isStart:q,isEnd:U,isInRange:J}=A(S.date),te=D(S.date),se=s&&S.date<s||r&&S.date>r||(u==null?void 0:u(S.date));return l.jsx("div",{className:y(T.dayCell,J&&"bg-primary/20",q&&(I==null?void 0:I[1])&&"bg-gradient-to-r from-transparent to-primary/20",U&&(I==null?void 0:I[0])&&"bg-gradient-to-l from-transparent to-primary/20"),children:l.jsx(me,{className:()=>({button:y("aspect-square h-[40px] p-0",{"text-on-surface":!C&&!te,"opacity-50":se}),stateLayer:y({"!bg-transparent":se})}),size:"small",allowShapeTransformation:!1,variant:y({filled:C,outlined:te,text:!C&&!te}),label:S.date.getDate().toString(),onClick:()=>B(S.date),disabled:se,children:S.date.getDate().toString()})},k)})},h.toISOString())})})]})]})},ir=({variant:e="filled",autoFocus:t,disabled:n=!1,errorText:s,placeholder:r,suffix:u,name:c,label:a,className:d,supportingText:i,trailingIcon:f,leadingIcon:x,type:h="text",multiline:m=!1,autoComplete:p="on",onChange:b,value:w,defaultValue:L,showSupportingText:E,id:g,style:F,ref:I,onFocus:v,onBlur:N,options:R,children:M,...W})=>{var nt;const j=o.useId(),X=g||j,V=`${X}-helper`,Q=w!==void 0,[z,$]=o.useState(L??""),D=Q?w:z,[B,A]=o.useState(!1),[T,G]=o.useState(!!(s!=null&&s.length)),S=o.useRef(null),k=I||S,C=o.useRef(null),q=o.useRef(null),U=o.useRef(null),J=E??(!!(s!=null&&s.length)||!!(i!=null&&i.length));o.useEffect(()=>{G(!!(s!=null&&s.length))},[s]);const te=()=>{k.current&&!B&&!n&&h!=="select"&&k.current.focus()};o.useEffect(()=>{if(!(!t||n)&&h!=="select"){const K=window.requestAnimationFrame(()=>{te()});return()=>window.cancelAnimationFrame(K)}},[t,n,k,h]),o.useEffect(()=>{B?(G(!1),v==null||v()):(s!=null&&s.length&&G(!0),N==null||N())},[B]);const se=K=>{const re=K.target.value;Q||$(re),G(!1),b&&b(K)},P=h==="date",[_,O]=o.useState(!1),[ee,oe]=o.useState(null),pe=o.useMemo(()=>{const K=String(D);if(!K)return null;const[re,xe,Ee]=K.split("-").map(Number);return re&&xe&&Ee?new Date(re,xe-1,Ee):null},[D]),Se=()=>{n||(_?O(!1):(oe(pe),O(!0)))};o.useEffect(()=>{_?A(!0):(!ae||!de)&&A(!1)},[_]),o.useEffect(()=>{if(!_)return;const K=fe=>{var Ne,Me;return fe?((Ne=C.current)==null?void 0:Ne.contains(fe))||((Me=U.current)==null?void 0:Me.contains(fe)):!1},re=fe=>{var st,rt;const Ne=fe.target,Me=(st=U.current)==null?void 0:st.contains(Ne),Rn=(rt=q.current)==null?void 0:rt.contains(Ne);!Me&&!Rn&&O(!1)},xe=fe=>{K(fe.target)||O(!1)},Ee=fe=>{fe.key==="Escape"&&O(!1)};return document.addEventListener("pointerdown",re),document.addEventListener("focusin",xe),document.addEventListener("keydown",Ee),()=>{document.removeEventListener("pointerdown",re),document.removeEventListener("focusin",xe),document.removeEventListener("keydown",Ee)}},[_]);const jn=()=>{const K=ee?ee.toLocaleDateString("en-CA"):"";Q||$(K),b&&b({target:{value:K,name:c,type:h}}),O(!1)},ae=h==="select",[de,De]=o.useState(!1),Ae=o.useRef(null),Qe=o.useMemo(()=>{if(ae&&R){const K=R.find(re=>String(re.value)===String(D));return K?K.label:D}return D},[D,ae,R]),et=()=>{n||(De(!de),A(!de))},tt=K=>{if(Q||$(String(K)),b){const re={target:{value:String(K),name:c,type:h}};b(re)}De(!1),A(!1)};o.useEffect(()=>{if(!de)return;const K=re=>{C.current&&!C.current.contains(re.target)&&Ae.current&&!Ae.current.contains(re.target)&&(De(!1),A(!1))};return document.addEventListener("mousedown",K),()=>{document.removeEventListener("mousedown",K)}},[de]);const ye=o.useMemo(()=>{if(f)return f;if(P)return As;if(ae)return de?Fs:vn},[f,P,ae,de]),Ln=P||ae?"[&::-webkit-calendar-picker-indicator]:hidden cursor-pointer selection:bg-transparent":"",ce=fn({showSupportingText:J,isFocused:B,showErrorIcon:T,disabled:n,name:c,label:a,autoComplete:p,className:d,onChange:b,placeholder:r,supportingText:i,type:h,leadingIcon:x,trailingIcon:ye,variant:e,errorText:s,value:String(Qe),suffix:u,multiline:m}),Mn=m?Pn:"input",In=m?{}:{type:ae?"text":h,readOnly:ae},Fe=B||typeof D=="string"&&D.length>0||h=="date"||ae&&de,Le=Fe&&e==="outlined",Cn=!Le;return l.jsxs("div",{ref:C,className:ce.textField,style:F,children:[l.jsxs("fieldset",{onClick:()=>{ae?et():te()},className:ce.content,role:"presentation",children:[l.jsx("div",{className:ce.stateLayer}),x&&l.jsx("div",{className:ce.leadingIcon,children:o.isValidElement(x)?x:l.jsx(le,{className:"w-5 h-5",icon:x})}),l.jsx(Y.motion.legend,{"aria-hidden":"true",variants:{hidden:{width:0,padding:0},visible:{width:"auto",padding:"0 8px"}},initial:Le?"visible":"hidden",animate:Le?"visible":"hidden",className:"max-w-full ml-2 px-2 text-body-small h-0 overflow-hidden whitespace-nowrap",transition:{duration:.2},children:l.jsx("span",{className:"transform inline-flex -translate-y-1/2 opacity-0",children:a})}),l.jsxs("div",{className:"flex-1 relative",children:[Cn&&l.jsx(Y.motion.label,{htmlFor:X,className:y("absolute left-4 transition-all duration-300 pointer-events-none",{"text-body-small top-2":e=="filled"&&Fe,"text-body-large top-1/2 transform -translate-y-1/2":!(e=="filled"&&Fe)}),transition:{duration:.3},layoutId:e==="outlined"?`${X}-label`:void 0,children:l.jsx("span",{className:ce.label,children:a})}),Le&&l.jsx(Y.motion.label,{htmlFor:X,className:y("absolute left-2 -top-3 px-1 text-body-small z-10",ce.label),layoutId:`${X}-label`,transition:{duration:.3},children:a}),l.jsx(Mn,{...W,ref:k,value:Qe,onChange:se,className:y(ce.input,Ln),id:X,name:c,placeholder:B?r??void 0:"",onFocus:()=>{ae||A(!0)},onBlur:()=>{ae||A(!1)},disabled:n,autoComplete:p,"aria-invalid":!!(s!=null&&s.length),"aria-describedby":J?V:void 0,...In})]}),l.jsx("div",{className:ce.activeIndicator}),!T&&l.jsxs(l.Fragment,{children:[ye&&l.jsx("div",{ref:P?q:void 0,onClick:K=>{K.stopPropagation(),P&&Se(),ae&&et()},className:y(ce.trailingIcon,(P||ae)&&"cursor-pointer"),children:l.jsx("div",{className:"flex items-center justify-center w-full h-full",children:o.isValidElement(ye)?ye:l.jsx(le,{className:"h-5",icon:ye})})}),!ye&&u&&l.jsx("span",{className:ce.suffix,children:u})]}),T&&l.jsx("div",{className:y(ce.trailingIcon,{" absolute right-0":!ye}),children:l.jsx(le,{className:"h-5 text-error",icon:Ps})})]}),J&&l.jsx("p",{className:ce.supportingText,id:V,children:s!=null&&s.length?s:i!=null&&i.length?i:" "}),P&&_&&l.jsx(l.Fragment,{children:l.jsx(be,{anchorRef:C,position:"bottom",children:l.jsxs("div",{ref:U,className:"z-50 shadow-xl rounded-[28px] bg-surface-container-high overflow-hidden",children:[l.jsx(En,{className:"",value:ee,onChange:oe}),l.jsxs("div",{className:"flex justify-end gap-2 p-4 pt-0",children:[l.jsx(me,{variant:"text",size:"small",onClick:()=>O(!1),children:"Cancel"}),l.jsx(me,{variant:"filled",size:"small",onClick:jn,children:"OK"})]})]})})}),ae&&de&&l.jsx(be,{anchorRef:C,position:"bottom",style:{width:(nt=C.current)==null?void 0:nt.offsetWidth},children:l.jsx("div",{ref:Ae,children:l.jsx(Ke,{className:"max-w-full",selected:D,children:M?o.Children.map(M,K=>o.isValidElement(K)&&K.type===Ie?o.cloneElement(K,{onClick:re=>{K.props.onClick&&K.props.onClick(re),tt(K.props.value??"")}}):K):R==null?void 0:R.map((K,re)=>K.type==="divider"?l.jsx(je,{className:"my-1"},re):K.type==="headline"?l.jsx(Ge,{label:K.label},re):l.jsx(Ie,{onClick:xe=>{K.onClick&&K.onClick(xe),tt(K.value??"")},...K,children:K.label},K.value??re))})})})]})},lr=({isSelected:e,icon:t,label:n,variant:s})=>({navigationRailItem:y(" group/navigation-rail-item flex flex-col pt-1 pb-1.5 cursor-pointer",{"text-on-surface-variant":!e,"text-on-secondary-container":e,"gap-2 h-[68px]":s=="vertical","gap-0 h-[66px]":s=="horizontal"}),container:y(" w-fit flex justify-center relative rounded-full items-center mx-5",{"bg-secondary-container overflow-hidden":e,"gap-2 ":s=="horizontal","gap-0 ":s=="vertical","p-4":!n},n&&["px-4",{"py-1 ":s=="vertical","py-4 ":s=="horizontal"}]),stateLayer:y("rounded-full"),icon:y("size-6 flex"),label:y("w-fit mx-auto text-nowrap",{"text-label-large ":s=="horizontal","text-label-medium":s=="vertical"})}),ar=Z("navigationRailItem",lr),Nn=({label:e})=>l.jsx("div",{className:" h-9 flex items-center mx-9 mt-3",children:l.jsx("p",{className:"text-label-large text-on-surface-variant",children:e})}),kn=({className:e,onClick:t,label:n,variant:s="vertical",href:r,icon:u,selectedItem:c,setSelectedItem:a,index:d,onItemSelected:i,selected:f=!1,ref:x,transition:h,isExtended:m,iconSelected:p,style:b,extendedOnly:w,children:L,...E})=>{L&&(n=L);const g=o.useRef(null),F=x||g,[I,v]=o.useState(f);o.useEffect(()=>{f&&c==null?v(!0):v(c==d&&d!=null)},[c]),o.useEffect(()=>{c==d&&i&&i({ref:F,index:d||0,label:n,icon:u})},[c]);const N=r?"a":"button",R=W=>{a&&a(d??null),t&&t(W)},M=ar({isExtended:m,extendedOnly:w,className:e,onItemSelected:i,selectedItem:c,index:d,transition:h,selected:I,variant:s,icon:u,label:n,isSelected:I,setSelectedItem:a,href:r,children:n,iconSelected:p});return h={duration:.3,...h},w&&!m?null:l.jsxs(N,{...E,role:"tab","aria-selected":I,ref:F,href:r,className:M.navigationRailItem,onClick:R,style:{transition:h.duration+"s",...b},children:[l.jsxs(Y.motion.div,{style:{transition:s=="horizontal"?h.duration+`s, gap ${h.duration/2}s ${h.duration-h.duration/2}s`:h.duration+`s, gap ${h.duration/3}s ${h.duration-h.duration/3}s`},transition:h,className:M.container,children:[l.jsx(ue,{style:{transition:h.duration+"s"},className:M.stateLayer,colorName:y({"on-surface":!I,"on-secondary-container":I}),stateClassName:"state-ripple-group-[navigation-rail-item]"}),u&&l.jsx(le,{icon:I?p:u,className:M.icon}),l.jsx(Y.AnimatePresence,{children:s=="horizontal"&&(()=>{const W={width:0,opacity:0,transition:{...h}},j={width:"auto",opacity:1,transition:{...h,opacity:{duration:h.duration/2,delay:h.duration-h.duration/2}}};return l.jsx(Y.motion.span,{initial:W,animate:j,exit:W,className:M.label,children:n})})()})]}),l.jsx(Y.AnimatePresence,{children:s=="vertical"&&(()=>{const W={height:0,opacity:0,transition:{...h,opacity:{duration:0}}},j={height:"auto",opacity:1,transition:{...h,opacity:{duration:h.duration/3,delay:h.duration-h.duration/3}}};return l.jsx(Y.motion.span,{initial:j,animate:j,exit:W,className:M.label,transition:h,children:n})})()})]})},cr=({isExtended:e,alignment:t})=>({navigationRail:y("flex flex-col left-0 h-full top-0 pt-11",{"w-fit max-w-24":!e,"w-fit min-w-[220px] max-w-[360px]":e,"justify-between":t=="middle","justify-start":t=="top"}),header:y("flex flex-col gap-1 items-start"),menuIcon:"mx-5",segments:y(" flex flex-col overflow-auto min-w-full mt-10",{"w-full":!e,"w-fit items-start":e})}),ur=Z("navigationRail",cr),dr=({variant:e="standard",onItemSelected:t,children:n,className:s,selectedItem:r,extended:u,alignment:c="top",menu:a={closed:{icon:Ws,label:"Open menu"},opened:{icon:ke,label:"Close menu"}},style:d,onExtendedChange:i,transition:f,setSelectedItem:x})=>{const[h,m]=o.useState(null),[p,b]=o.useState(u);let w;r==0||r!=null?w=r:w=h;const L=x||m,E=o.useRef(null),g=M=>{t==null||t(M)};function F(M){const W=[];return o.Children.forEach(M,j=>{o.isValidElement(j)&&j.type===o.Fragment?W.push(...F(j.props.children)):W.push(j)}),W}const I=F(n),v=I.filter(M=>o.isValidElement(M)&&M.type===Ce),N=ur({children:n,onItemSelected:t,selectedItem:w,setSelectedItem:L,className:s,variant:e,extended:p,isExtended:p,alignment:c,menu:a,transition:f,onExtendedChange:i});f={duration:.3,...f};const R=o.useRef(!1);return R.current=!1,o.useEffect(()=>{i==null||i(p??!1)},[p]),l.jsxs("div",{style:{transition:f.duration+"s",...d},ref:E,className:N.navigationRail,children:[l.jsxs("div",{className:N.header,children:[l.jsx(ge,{onClick:()=>b(!p),label:p?a==null?void 0:a.opened.label:a==null?void 0:a.closed.label,className:N.menuIcon,icon:p?a.opened.icon:a==null?void 0:a.closed.icon}),v.length>0&&o.cloneElement(v[0],{transition:f,isExtended:p,className:"!shadow-none mx-5 "+v[0].props.className})]}),l.jsx("div",{className:N.segments,children:(()=>{let M=0;return I.map(W=>o.isValidElement(W)&&W.type===kn?o.cloneElement(W,{key:M,index:M++,variant:p?"horizontal":"vertical",selectedItem:w,setSelectedItem:L,onItemSelected:g,transition:f,extendedOnly:R.current,isExtended:p}):o.isValidElement(W)&&W.type===Ce?null:o.isValidElement(W)&&W.type===Nn?(R.current=!0,p?o.cloneElement(W,{}):null):W)})()}),l.jsx("div",{className:"flex-1 max-h-[160px]"})]})};function fr(e){return we.defineConfig({variant:we.Variants.Udixio,...e,plugins:[new we.FontPlugin(e),new Be.TailwindPlugin(e)]})}exports.AnchorPositioner=be;exports.AnimateOnScrollInit=ss;exports.Button=me;exports.Card=Cs;exports.Carousel=Rs;exports.CarouselItem=yn;exports.Checkbox=Bs;exports.Chip=Oe;exports.Chips=Gs;exports.ContextMenu=_s;exports.CustomScroll=vt;exports.DatePicker=En;exports.Divider=je;exports.Fab=Ce;exports.FabMenu=Ks;exports.Icon=le;exports.IconButton=ge;exports.Menu=Ke;exports.MenuGroup=He;exports.MenuHeadline=Ge;exports.MenuItem=Ie;exports.NavigationRail=dr;exports.NavigationRailItem=kn;exports.NavigationRailSection=Nn;exports.ProgressIndicator=pn;exports.RippleEffect=mt;exports.SideSheet=Zs;exports.Slider=Js;exports.SmoothScroll=Xn;exports.Snackbar=Qs;exports.State=ue;exports.Switch=er;exports.SyncedFixedWrapper=St;exports.Tab=bn;exports.TabGroup=nr;exports.TabPanel=Sn;exports.TabPanels=sr;exports.Tabs=tr;exports.TextField=ir;exports.ThemeProvider=Jn;exports.Tooltip=Je;exports.animateOnScroll=rs;exports.buttonStyle=os;exports.cardStyle=is;exports.carouselItemConfig=Ye;exports.carouselItemStyle=ls;exports.carouselStyle=as;exports.checkboxStyle=cs;exports.chipStyle=us;exports.chipsStyle=ds;exports.classNames=y;exports.classnames=yt;exports.createUseClassNames=Z;exports.customScrollStyle=xt;exports.defaultClassNames=ne;exports.defineConfig=fr;exports.dividerStyle=fs;exports.fabMenuStyle=ms;exports.fabStyle=hs;exports.getClassNames=Re;exports.iconButtonStyle=ps;exports.initAnimateOnScroll=_e;exports.menuGroupStyle=xs;exports.menuStyle=ys;exports.normalize=ve;exports.progressIndicatorStyle=vs;exports.sideSheetConfig=qe;exports.sideSheetStyle=Kt;exports.sliderConfig=Ue;exports.sliderStyle=ws;exports.snackbarStyle=bs;exports.switchStyle=Ss;exports.tabPanelStyle=js;exports.tabPanelsStyle=ks;exports.tabStyle=Es;exports.tabsStyle=Ns;exports.textFieldStyle=Ls;exports.toolStyle=Ms;exports.useButtonStyle=Nt;exports.useCardStyle=jt;exports.useCarouselItemStyle=Lt;exports.useCarouselStyle=It;exports.useCheckboxStyle=Rt;exports.useChipStyle=At;exports.useChipsStyle=Pt;exports.useClassNames=Tn;exports.useDividerStyle=Tt;exports.useFabMenuStyle=Ht;exports.useFabStyle=Bt;exports.useIconButtonStyle=zt;exports.useMenuGroupStyle=Ut;exports.useMenuStyle=Yt;exports.useProgressIndicatorStyle=Gt;exports.useSideSheetStyle=gs;exports.useSliderStyle=Jt;exports.useSnackbarStyle=Qt;exports.useStateStyle=bt;exports.useSwitchStyle=tn;exports.useTabPanelStyle=un;exports.useTabPanelsStyle=an;exports.useTabStyle=sn;exports.useTabsStyle=on;exports.useTextFieldStyle=fn;exports.useToolTipStyle=mn;exports.useTooltipTrigger=wn;
10
+ `})]}),I&&l.jsx(Be,{ref:F,className:"opacity-0",draggable:s,editable:!0,editing:!0,onChange:v=>{var k;if(v=v.replace(/(&nbsp;)+/g," ").trim(),console.log("Ghost chip onChange",v,!!v),v)L(v);else if(c.length>0){const D=h.current[c.length-1];(k=D==null?void 0:D.focus)==null||k.call(D)}},onEditCommit:()=>{},onBlur:()=>{i(!1)},onFocus:v=>{i(!0),v.stopPropagation()},children:" "})]})};function wn({trigger:e=["hover","focus"],isOpen:t,defaultOpen:n=!1,onOpenChange:s,openDelay:r=400,closeDelay:u=150,id:c}={}){const a=o.useId(),d=c??`tooltip-${a}`,i=Array.isArray(e)?e:[e],f=typeof t=="boolean",[x,h]=o.useState(n?"hovered":"hidden"),[m,p]=o.useState(!1),b=o.useRef(null),w=o.useRef(null),L=o.useCallback(()=>{b.current&&(clearTimeout(b.current),b.current=null),w.current&&(clearTimeout(w.current),w.current=null)},[]);o.useEffect(()=>()=>L(),[L]);const E=o.useCallback($=>{if(f){const R=$!=="hidden";s==null||s(R)}else{h($);const R=$!=="hidden";s==null||s(R)}},[f,s]),g=f?t?"hovered":"hidden":x,F=g!=="hidden",I=$=>{switch($){case"hidden":return 0;case"hovered":return 1;case"focused":return 2;case"clicked":return 3;default:return 0}},v=o.useCallback($=>{L(),!(I($)<=I(g))&&(b.current=setTimeout(()=>{E($)},r))},[L,r,g,E]),k=o.useCallback($=>{L(),w.current=setTimeout(()=>{(!f&&I(x)<=I($)||f)&&E("hidden")},u)},[L,u,x,f,E]),D=o.useCallback(()=>{i.includes("hover")&&v("hovered")},[i,v]),M=o.useCallback(()=>{i.includes("hover")&&(g==="focused"||g==="clicked"||m||k("hovered"))},[i,g,m,k]),T=o.useCallback(()=>{i.includes("focus")&&(L(),E("focused"))},[i,L,E]),j=o.useCallback(()=>{if(i.includes("focus")&&g!=="clicked"){if(i.includes("hover")&&m){E("hovered");return}k("focused")}},[i,g,m,k,E]),X=o.useCallback(()=>{i.includes("click")&&(L(),E(g==="clicked"?"hidden":"clicked"))},[i,g,L,E]),V=o.useCallback($=>{$.key==="Escape"&&F&&(L(),E("hidden"),$.preventDefault())},[F,L,E]),Q=o.useCallback(()=>{p(!0),L()},[L]),z=o.useCallback(()=>{p(!1),i.includes("hover")&&g==="hovered"&&k("hovered")},[i,g,k]);return{triggerProps:{"aria-describedby":F?d:void 0,onMouseEnter:D,onMouseLeave:M,onFocus:T,onBlur:j,onClick:X,onKeyDown:V},tooltipProps:{id:d,role:"tooltip","aria-hidden":!F,onMouseEnter:Q,onMouseLeave:z},isOpen:F,state:g}}const Je=({variant:e="plain",buttons:t,className:n,children:s,title:r,text:u,content:c,position:a,targetRef:d,ref:i,trigger:f=["hover","focus"],transition:x,openDelay:h=400,closeDelay:m=150,isOpen:p,defaultOpen:b=!1,onOpenChange:w,id:L,anchorRef:E,...g})=>{const I=a||(e==="rich"?"bottom-right":"bottom");if(x={duration:.3,...x},!s&&!d)throw new Error("Tooltip must have a child or a targetRef");t&&!Array.isArray(t)&&(t=[t]);const v=o.useRef(null),D=E||(d||v),{triggerProps:M,tooltipProps:T,isOpen:j}=wn({trigger:f,isOpen:p,defaultOpen:b,onOpenChange:w,openDelay:h,closeDelay:m,id:L}),X=!d&&o.isValidElement(s)?o.cloneElement(s,{ref:v,...M,onMouseEnter:z=>{var $,R;M.onMouseEnter(),(R=($=s.props)==null?void 0:$.onMouseEnter)==null||R.call($,z)},onMouseLeave:z=>{var $,R;M.onMouseLeave(),(R=($=s.props)==null?void 0:$.onMouseLeave)==null||R.call($,z)},onFocus:z=>{var $,R;M.onFocus(),(R=($=s.props)==null?void 0:$.onFocus)==null||R.call($,z)},onBlur:z=>{var $,R;M.onBlur(),(R=($=s.props)==null?void 0:$.onBlur)==null||R.call($,z)},onClick:z=>{var $,R;M.onClick(),(R=($=s.props)==null?void 0:$.onClick)==null||R.call($,z)},onKeyDown:z=>{var $,R;M.onKeyDown(z),(R=($=s.props)==null?void 0:$.onKeyDown)==null||R.call($,z)}}):s;o.useEffect(()=>{if(!d)return;const z=d.current;if(!z)return;const $=()=>M.onMouseEnter(),R=()=>M.onMouseLeave(),O=()=>M.onFocus(),A=()=>M.onBlur(),W=()=>M.onClick(),G=S=>M.onKeyDown(S);return z.addEventListener("mouseenter",$),z.addEventListener("mouseleave",R),z.addEventListener("focus",O,!0),z.addEventListener("blur",A,!0),z.addEventListener("click",W),z.addEventListener("keydown",G),M["aria-describedby"]?z.setAttribute("aria-describedby",M["aria-describedby"]):z.removeAttribute("aria-describedby"),()=>{z.removeEventListener("mouseenter",$),z.removeEventListener("mouseleave",R),z.removeEventListener("focus",O,!0),z.removeEventListener("blur",A,!0),z.removeEventListener("click",W),z.removeEventListener("keydown",G)}},[d,M]);const V=mn({variant:e,buttons:t,className:n,title:r,text:u,position:I,trigger:f,targetRef:d,children:s}),Q={open:{opacity:1,height:"auto"},close:{opacity:0,height:16}};return l.jsxs(l.Fragment,{children:[X,l.jsx(Y.AnimatePresence,{children:j&&l.jsx(be,{anchorRef:D,position:I,children:l.jsx(Y.motion.div,{initial:"close",variants:Q,animate:"open",transition:{duration:x.duration},exit:"close",className:V.toolTip,...g,...T,children:l.jsx("div",{className:V.container,children:c?l.jsx("div",{className:V.content,children:c}):l.jsxs(l.Fragment,{children:[r&&l.jsx("div",{className:V.subHead,children:r}),u&&l.jsx("div",{className:V.supportingText,children:u}),t&&l.jsx("div",{className:V.actions,children:Array.isArray(t)&&t.map((z,$)=>l.jsx(me,{size:"small",variant:"text",...z},$))})]})})})})})]})},Ce=({className:e,label:t,variant:n="primary",size:s="medium",href:r,type:u,icon:c,extended:a=!1,ref:d,transition:i,children:f,...x})=>{if(f&&(t=f),!t)throw new Error("FAB component requires either a label prop or children content");const h=r?"a":"button",m=Ot({href:r,icon:c,extended:a,label:t,size:s,variant:n,className:e,transition:i,children:t});i={duration:.3,...i};const p=o.useRef(null),b=d||p,w={visible:{width:"auto",marginLeft:12,opacity:1,transition:{...i,opacity:{duration:i.duration/2,delay:i.duration-i.duration/2}}},hidden:{width:0,marginLeft:0,opacity:0,transition:{...i,marginLeft:{duration:i.duration/2,delay:i.duration-i.duration/2}}}};return l.jsxs(h,{...x,ref:b,href:r,"aria-label":a?void 0:t,className:m.fab,children:[l.jsx(Je,{trigger:a?null:void 0,text:t,targetRef:b}),l.jsx(ue,{style:{transition:i.duration+"s"},className:m.stateLayer,colorName:y({"on-primary":n=="primary","on-secondary":n=="secondary","on-tertiary":n=="tertiary","on-primary-container":n=="primaryContainer","on-secondary-container":n=="secondaryContainer","on-tertiary-container":n=="tertiaryContainer"}),stateClassName:"state-ripple-group-[fab]"}),l.jsx(le,{icon:c,className:m.icon}),l.jsx(Y.AnimatePresence,{children:a&&l.jsx(Y.motion.span,{variants:w,initial:"hidden",animate:"visible",exit:"hidden",className:m.label,children:t})})]})},ge=({variant:e="standard",href:t,disabled:n=!1,title:s,label:r,onToggle:u,activated:c=!1,onClick:a,icon:d,size:i="medium",iconSelected:f,className:x,ref:h,width:m="default",shape:p="rounded",allowShapeTransformation:b=!0,transition:w,children:L,...E})=>{if(L&&(r=L),!r)throw new Error("IconButton component requires either a label prop or children content to provide an accessible aria-label");!s&&s!==null&&(s=r);const[g,F]=o.useState(c),I=T=>{n&&T.preventDefault(),u?(F(!g),u(!g)):a&&a(T)};o.useEffect(()=>{F(c)},[c]);const v=t?"a":"button",k=zt({transition:w,shape:p,allowShapeTransformation:b,width:m,href:t,activated:g,label:r,iconSelected:f,isActive:g,onToggle:u,disabled:n,icon:d,variant:e,className:x,size:i,children:r,...E}),D=o.useRef(null),M=h||D;return w={duration:.3,...w},l.jsxs(v,{disabled:n,href:t,style:{transition:w.duration+"s"},className:k.iconButton,"aria-label":r,...E,title:void 0,onClick:I,ref:M,children:[s!==null&&l.jsx(Je,{targetRef:M,trigger:n?null:void 0,text:s}),l.jsx("div",{className:k.touchTarget}),l.jsx(ue,{style:{transition:w.duration+"s"},className:k.stateLayer,colorName:y(e==="standard"&&{"on-surface-variant":!g,"on-primary":g},e==="filled"&&{"on-surface-variant":!g&&!!u,"on-primary":g||!u},e==="tonal"&&{"on-secondary":g&&!!u,"on-secondary-container":!g||!u},e==="outlined"&&{"inverse-on-surface":g&&!!u,"on-surface-variant":!g||!u}),stateClassName:"state-ripple-group-[icon-button]"}),d?l.jsx(le,{icon:d,className:k.icon}):L]})},Ks=({className:e,label:t,variant:n="primary",size:s="medium",href:r,icon:u,extended:c=!1,ref:a,transition:d,children:i,open:f,defaultOpen:x=!1,onOpenChange:h,...m})=>{d={duration:.3,ease:"easeInOut",...d};const p=o.useRef(null),b=a||p,w=typeof f=="boolean",[L,E]=o.useState(x),g=w?f:L,F=j=>{w||E(j),h==null||h(j)},I=o.Children.toArray(i).filter(j=>o.isValidElement(j)&&j.type===me),v=Ht({href:r,icon:u,extended:c,label:t,size:s,variant:n,className:e,transition:d,children:t,open:g}),k=Y.motion.create(Ce),D=Y.motion.create(ge),M=j=>l.jsx(k,{icon:u,extended:c,label:t,variant:n+"Container",size:s,className:v.fab+" "+(e??""),"aria-expanded":g,onClick:()=>F(!0),style:{transition:"border-radius 0.3s ease-in-out"},transition:{duration:d.duration,ease:"easeInOut",borderRadius:{duration:d.duration,ease:"easeInOut"},background:{duration:d.duration,ease:"easeInOut"},...d},...j}),T=o.useId();return l.jsxs("div",{className:v.fabMenu,ref:b,...m,children:[l.jsx(Y.AnimatePresence,{children:g&&l.jsx("div",{className:v.actions,role:"menu","aria-hidden":!g,children:(()=>{const j=I.length;return I.map((X,V)=>{X.props;const Q=j-1-V,z=((d==null?void 0:d.delay)??0)+Q*.06,$={open:{overflow:"visible",opacity:1,width:"auto",transition:{...d,delay:z,opacity:{delay:(d==null?void 0:d.duration)/2+z}}},close:{overflow:"hidden",opacity:0,width:0,transition:{...d,delay:z,opacity:{duration:(d==null?void 0:d.duration)/1.5}}}};return l.jsx(Y.motion.div,{initial:"close",animate:"open",variants:$,transition:d,exit:"close",children:o.cloneElement(X,{key:V,shape:"rounded",variant:"filled",className:()=>({button:y("max-w-full overflow-hidden text-nowrap",{"px-0":!g,"bg-primary-container text-on-primary-container ":n==="primary","bg-secondary-container text-on-secondary-container":n==="secondary","bg-tertiary-container text-on-tertiary-container":n==="tertiary"}),stateLayer:y({"state-on-primary-container":n==="primary","state-on-secondary-container":n==="secondary","state-on-tertiary-container":n==="tertiary"})})})})})})()})}),M({className:"invisible pointer-events-none"}),l.jsxs("div",{className:"absolute right-0 top-0",children:[!g&&M({className:"",layout:!0,layoutId:"fab-menu"+T}),g&&l.jsx(l.Fragment,{children:l.jsx(D,{layout:!0,layoutId:"fab-menu"+T,variant:"filled",className:()=>({iconButton:y({"bg-primary text-on-primary":n==="primary","bg-secondary text-on-secondary":n==="secondary","bg-tertiary text-on-tertiary":n==="tertiary"}),stateLayer:y({"[--default-color:var(--color-on-primary)]":n==="primary","[--default-color:var(--color-on-secondary)]":n==="secondary","[--default-color:var(--color-on-tertiary)]":n==="tertiary"})}),style:{transition:"border-radius 0.3s ease-in-out"},transition:{duration:d.duration,ease:"easeInOut",borderRadius:{duration:d.duration,ease:"easeInOut"},background:{duration:d.duration,ease:"easeInOut"},...d},icon:$s,onClick:()=>F(!1),children:"Close"})})]})]})},Js=({className:e,valueFormatter:t,step:n=10,name:s,value:r=0,min:u=0,max:c=100,marks:a=[{value:0,label:"0"},{value:100,label:"100"}],ref:d,onChange:i,...f})=>{const x=R=>{const O=m(),A=h();return R===1/0?100:R===-1/0?0:(R-O)/(A-O)*100},h=(R=!1)=>R?c:c==1/0?a[(a==null?void 0:a.length)-1].value:c,m=(R=!1)=>R?u:u==-1/0?a[0].value:u,p=R=>{const O=m(!1);return(h(!1)-O)*R/100+O},[b,w]=o.useState(!1),L=o.useRef(null),E=d||L,[g,F]=o.useState(r),[I,v]=o.useState(x(r)),[k,D]=o.useState(!1);o.useEffect(()=>{F(r),v(x(r))},[r]);const M=R=>{D(!0),w(!0),X(R)},T=()=>{D(!1),w(!1)};o.useEffect(()=>(k?(window.addEventListener("mouseup",T),window.addEventListener("mousemove",X),window.addEventListener("touchend",T),window.addEventListener("touchmove",X)):(window.removeEventListener("mouseup",T),window.removeEventListener("mousemove",X),window.removeEventListener("touchend",T),window.removeEventListener("touchmove",X)),()=>{window.removeEventListener("mouseup",T),window.removeEventListener("mousemove",X),window.removeEventListener("touchend",T),window.removeEventListener("touchmove",X)}),[k]);const j=Jt({className:e,isChanging:b,marks:a,max:c,min:u,name:s,step:n,value:g,valueFormatter:t,onChange:i}),X=R=>{const O=E==null?void 0:E.current;if(O){const A=O.getBoundingClientRect().left,G=((R.type==="touchmove"||R.type==="touchstart"?R.touches[0].clientX:R.clientX)-A)/O.offsetWidth*100;V({percent:G})}},V=({percent:R,value:O})=>{if(R){if(R>=100){F(h(!0)),v(100);return}if(R<=0){F(m(!0)),v(0);return}O=p(R),O==m()&&(O=m(!0)),O==h()&&(O=h(!0))}else if(O!=null){if(O>=h()){F(h(!0)),v(100);return}if(O<=m()){F(m(!0)),v(0);return}R=x(O)}else return;n!=null?O=Math.round((O-m())/n)*n+m():a&&(O=a.reduce((A,W,G)=>{let S=W.value===1/0?h():W.value===-1/0?m():W.value,N=A.value===1/0?h():A.value===-1/0?m():A.value;return S=Math.abs(S-O),N=Math.abs(N-O),S<N?W:A}).value),O>=h()&&(O=h(!0)),O<=m()&&(O=m(!0)),R=x(O),F(O),v(R),i&&i(O)},[Q,z]=o.useState(0);o.useEffect(()=>{const R=()=>{E.current&&z(E.current.offsetWidth)};return R(),window.addEventListener("resize",R),()=>{window.removeEventListener("resize",R)}},[]);const $=R=>{switch(R.key){case"ArrowRight":if(n)V({value:g+n});else if(a){const O=a.find(A=>A.value>g);O&&V({value:O.value})}break;case"ArrowLeft":if(n)V({value:g-n});else if(a){const O=a.slice(0).reverse().find((A,W,G)=>g===1/0?W===1:A.value<g);O&&V({value:O.value})}break;default:return}};return l.jsxs("div",{tabIndex:0,onKeyDown:$,role:"slider","aria-valuemin":m(!0),"aria-valuemax":h(!0),"aria-valuenow":g,"aria-valuetext":g.toString(),className:j.slider,onMouseDown:M,onClick:X,ref:E,onTouchStart:M,onDragStart:R=>R.preventDefault(),...f,children:[l.jsx("input",{type:"hidden",name:s,value:g}),l.jsx("div",{className:j.activeTrack,style:{flex:I/100}}),l.jsx("div",{className:j.handle,children:l.jsx(Y.AnimatePresence,{children:b&&l.jsx(Y.motion.div,{className:j.valueIndicator,initial:"hidden",animate:"visible",exit:"hidden",style:{translate:"-50%",transformOrigin:"center bottom",textWrap:"nowrap"},variants:{visible:{opacity:1,scale:1},hidden:{opacity:1,scale:0}},transition:{duration:.1},children:t?t(g):g})})}),l.jsx("div",{className:j.inactiveTrack,style:{flex:1-I/100}}),l.jsx("div",{className:"w-[calc(100%-12px)] h-full absolute -translate-x-1/2 transform left-1/2",children:a&&a.map((R,O)=>{let A=null;const W=(b?9:10)/Q*100,G=x(R.value);return G<=I-W?A=!0:G>=I+W&&(A=!1),l.jsx("div",{className:y(j.dot,{"bg-primary-container":A!=null&&A,"bg-primary":A!=null&&!A}),style:{left:`${x(R.value)}%`}},O)})})]})},Zs=({variant:e="standard",className:t,children:n,title:s,position:r="right",extended:u,divider:c,onExtendedChange:a,closeIcon:d=ke,transition:i,...f})=>{i={duration:.3,...i};const[x,h]=o.useState(u??!0),m=Kt({transition:i,title:s,position:r,closeIcon:d,className:t,children:n,onExtendedChange:a,divider:c,isExtended:x,extended:x,variant:e});o.useEffect(()=>{a==null||a(x??!1)},[x]),o.useEffect(()=>{u!=null&&h(u)},[u]);const p={close:{width:0},open:{width:"auto"}},b=()=>l.jsxs(l.Fragment,{children:[l.jsx(Y.AnimatePresence,{children:e=="modal"&&x&&l.jsx(Y.motion.div,{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:i,onClick:()=>h(!1),className:m.overlay})}),l.jsx(Y.AnimatePresence,{children:x&&l.jsxs("div",{...f,className:m.sideSheet,style:{transition:i.duration+"s"},children:[l.jsxs(Y.motion.div,{variants:p,initial:u===!1?"open":"close",animate:"open",exit:"close",className:m.container,children:[l.jsxs("div",{className:m.header,children:[s&&l.jsx("p",{className:m.title,children:s}),l.jsx(ge,{size:"small",label:"close",icon:d,onClick:()=>h(!1),className:m.closeButton})]}),l.jsx("div",{className:m.content,style:{transition:i.duration+"s"},children:n})]}),(c==null&&e=="standard"?!0:c)&&l.jsx(je,{className:m.divider,orientation:"vertical"})]})})]});return e=="modal"?Ve.createPortal(b(),document.body):b()},Qs=({message:e,className:t,duration:n,closeIcon:s=ke,onClose:r,...u})=>{const[c,a]=o.useState(!0),d=Qt({className:t,closeIcon:s,duration:n,isVisible:c,onClose:r,message:e});o.useEffect(()=>{n&&setTimeout(()=>{i()},n)},[n]);const i=()=>{a(!1),r==null||r()};return l.jsx(Y.AnimatePresence,{children:c&&l.jsx(Y.motion.div,{initial:{height:0},animate:{height:"auto"},exit:{height:0},transition:{duration:.1},className:d.snackbar,...u,children:l.jsxs("div",{className:d.container,children:[l.jsx("p",{className:d.supportingText,children:e}),l.jsx(ge,{onClick:()=>i(),className:d.icon,icon:s,label:"close the snackbar"})]})})})},er=({selected:e=!1,className:t,activeIcon:n,disabled:s=!1,inactiveIcon:r,onChange:u,onClick:c,onKeyDown:a,ref:d,...i})=>{const[f,x]=o.useState(e);o.useEffect(()=>{x(e)},[e]);const h=E=>{s||(p(),c&&c(E))},m=E=>{s||((E.key===" "||E.key==="Enter")&&(E.preventDefault(),p()),a&&a(E))},p=()=>{x(!f),u==null||u(!f)},b=tn({className:t,isSelected:f,activeIcon:n,inactiveIcon:r,disabled:s,selected:f,onChange:u}),w=o.useRef(null),L=d||w;return l.jsxs(Y.motion.div,{role:"switch","aria-checked":f,tabIndex:s?-1:0,onKeyDown:m,onClick:h,ref:L,className:b.switch,...i,children:[l.jsx("input",{type:"hidden",value:f?"1":"0"}),l.jsxs(Y.motion.div,{layout:!0,style:{translate:f?"50%":"-50%"},transition:{type:"spring",stiffness:700,damping:30},className:b.handleContainer,children:[l.jsx("div",{className:b.handle,children:(f?n:r)&&l.jsx(le,{className:b.icon,icon:f?n:r})}),l.jsx("div",{className:b.handleStateLayer})]})]})},bn=({className:e,onClick:t,label:n,variant:s="primary",href:r,icon:u,selectedTab:c,setSelectedTab:a,tabsId:d,index:i,onTabSelected:f,scrollable:x=!1,selected:h=!1,children:m,ref:p,...b})=>{const w=o.useRef(null),L=p||w,E=n??(typeof m=="string"?m:void 0),[g,F]=o.useState(h);o.useEffect(()=>{h&&c==null?F(!0):F(c==i&&i!=null)},[c]),o.useEffect(()=>{c==i&&f&&f({ref:L,index:i||0,label:E,icon:u})},[c]);const I=r?"a":"button",v=D=>{a&&a(i??null),t&&t(D)},k=sn({className:e,onTabSelected:f,scrollable:x,selectedTab:c,index:i,tabsId:d,selected:g,variant:s,icon:u,label:E,isSelected:g,setSelectedTab:a,href:r});return l.jsxs(I,{...b,role:"tab","aria-selected":g,ref:L,href:r,className:k.tab,onClick:v,...b,children:[l.jsx(ue,{style:{transition:.3+"s"},className:k.stateLayer,colorName:s==="primary"&&g?"primary":"on-surface",stateClassName:"state-ripple-group-[tab]"}),l.jsxs("span",{className:k.content,children:[u&&l.jsx(le,{icon:u,className:k.icon}),l.jsx("span",{className:k.label,children:E}),g&&l.jsx(Y.motion.span,{layoutId:`underline-${d}`,className:k.underline,transition:{duration:.3}})]})]})},Ze=o.createContext(null),tr=({variant:e="primary",onTabSelected:t,children:n,className:s,selectedTab:r,setSelectedTab:u,scrollable:c=!1})=>{const a=o.useContext(Ze),[d,i]=o.useState(null);let f;r===0||r!=null?f=r:a?f=a.selectedTab:f=d;const x=u??(a==null?void 0:a.setSelectedTab)??i,h=o.Children.toArray(n).filter(L=>o.isValidElement(L)&&L.type===bn),m=o.useRef(null),p=L=>{if(t==null||t(L),c){const E=m.current,g=L.ref.current;if(E&&g){const F=g.offsetLeft+g.offsetWidth/2-E.offsetWidth/2;E.scrollTo({left:F,behavior:"smooth"})}}},b=o.useMemo(()=>(a==null?void 0:a.tabsId)??gn(),[a==null?void 0:a.tabsId]),w=on({children:n,onTabSelected:t,scrollable:c,selectedTab:f,setSelectedTab:x,className:s,variant:e});return l.jsx("div",{ref:m,role:"tablist",className:w.tabs,children:h.map((L,E)=>o.cloneElement(L,{key:E,index:E,variant:e,selectedTab:f,setSelectedTab:x,tabsId:b,onTabSelected:p,scrollable:c}))})},nr=({children:e,selectedTab:t,setSelectedTab:n,defaultTab:s=0})=>{const[r,u]=o.useState(s),c=o.useRef(null),a=t!==void 0?t:r,d=n??u,i=c.current!==null&&a!==null?a>c.current?1:-1:0;a!==c.current&&(c.current=a);const f=o.useId(),x=o.useMemo(()=>({selectedTab:a,setSelectedTab:d,previousTab:c.current,direction:i,tabsId:f}),[a,d,i,f]);return l.jsx(Ze.Provider,{value:x,children:e})},Sn=({children:e,className:t,isSelected:n=!1})=>{const s=un({children:e,className:t,isSelected:n});return l.jsx("div",{className:s.tabPanel,children:e})},sr=({children:e,className:t})=>{const n=o.useContext(Ze);if(!n)return console.warn("TabPanels must be used within a TabGroup"),null;const{selectedTab:s,direction:r,tabsId:u}=n,c=o.Children.toArray(e).filter(d=>o.isValidElement(d)&&d.type===Sn),a=an({children:e,className:t});return l.jsx("div",{className:a.tabPanels,children:l.jsx(Y.AnimatePresence,{initial:!1,custom:r,mode:"popLayout",children:c.map((d,i)=>s===i&&l.jsx(Y.motion.div,{custom:r,variants:{enter:f=>({x:f*100+"%",opacity:1}),center:{x:0,opacity:1},exit:f=>({x:f*-100+"%",opacity:1})},initial:"enter",animate:"center",exit:"exit",transition:{type:"spring",stiffness:400,damping:40},role:"tabpanel","aria-labelledby":`tab-${u}-${i}`,children:o.cloneElement(d,{isSelected:!0})},i))})})},rr=({hasSelected:e})=>({datePicker:y("inline-flex flex-col bg-surface-container-high rounded-[28px] p-3 select-none","min-w-[320px]"),header:y("flex items-center justify-between h-12 mb-2 px-2"),monthNav:y("flex items-center justify-center w-10 h-10 rounded-full text-on-surface-variant hover:bg-on-surface-variant/8 transition-colors cursor-pointer"),monthLabel:y("text-label-large text-on-surface font-bold capitalize"),weekDays:y("grid grid-cols-7 mb-2"),weekDay:y("h-10 flex items-center justify-center text-body-small text-on-surface-variant"),daysGrid:y("grid grid-cols-7 row-auto gap-y-2"),dayCell:y("flex items-center justify-center h-10 p-0 relative"),dayButton:y("w-10 h-10 rounded-full flex items-center justify-center text-body-large transition-all duration-200 relative overflow-hidden z-10 outline-none")}),or=Z("datePicker",rr),En=({value:e,defaultValue:t,onChange:n,minDate:s,maxDate:r,shouldDisableDate:u,locale:c="default",weekStartDay:a=0,className:d,style:i,mode:f="single",...x})=>{const[h,m]=o.useState(()=>{const S=C=>C instanceof Date?C:Array.isArray(C)&&C[0]?C[0]:null,N=S(e)||S(t)||new Date;return new Date(N.getFullYear(),N.getMonth(),1)}),[p,b]=o.useState(0),[w,L]=o.useState("day"),E=e!==void 0,[g,F]=o.useState(t||null),I=E?e||null:g,v=(S,N)=>new Date(S,N+1,0).getDate(),k=o.useMemo(()=>{const S=h.getFullYear(),N=h.getMonth(),C=v(S,N),U=(new Date(S,N,1).getDay()-a+7)%7,J=[],te=v(S,N-1);for(let _=U-1;_>=0;_--)J.push({date:new Date(S,N-1,te-_),isCurrentMonth:!1});for(let _=1;_<=C;_++)J.push({date:new Date(S,N,_),isCurrentMonth:!0});const P=42-J.length;for(let _=1;_<=P;_++)J.push({date:new Date(S,N+1,_),isCurrentMonth:!1});return J},[h,a]),D=o.useMemo(()=>{const S=new Date().getFullYear(),N=S-100,C=S+100,q=[];for(let U=N;U<=C;U++)q.push(U);return q},[]),M=o.useRef(null);o.useEffect(()=>{if(w==="year"&&M.current){const S=M.current.querySelector('[data-selected="true"]');S&&S.scrollIntoView({block:"center"})}},[w]);const T=o.useMemo(()=>new Intl.DateTimeFormat(c,{month:"long",year:"numeric"}),[c]),j=o.useMemo(()=>new Intl.DateTimeFormat(c,{weekday:"narrow"}),[c]),X=o.useMemo(()=>{const S=new Date(2023,0,1+a);return Array.from({length:7}).map((N,C)=>{const q=new Date(S);return q.setDate(S.getDate()+C),j.format(q).charAt(0).toUpperCase()})},[j,a]),V=()=>{b(-1),m(S=>new Date(S.getFullYear(),S.getMonth()-1,1))},Q=()=>{b(1),m(S=>new Date(S.getFullYear(),S.getMonth()+1,1))},z=S=>{m(N=>new Date(S,N.getMonth(),1)),L("day")},$=(S,N)=>S?S.getDate()===N.getDate()&&S.getMonth()===N.getMonth()&&S.getFullYear()===N.getFullYear():!1,R=S=>$(new Date,S),O=S=>{let N=S;if(f==="single")N=S;else{const C=I,[q,U]=Array.isArray(C)?C:[null,null];!q||q&&U?N=[S,null]:S<q?N=[S,q]:N=[q,S]}E||F(N),n&&n(N)},A=S=>{if(f==="single")return{isSelected:$(I,S),isStart:!1,isEnd:!1,isInRange:!1};const N=Array.isArray(I)?I:[I,null],[C,q]=N,U=$(C,S),J=$(q,S);let te=!1;if(C&&q){const se=new Date(C.getFullYear(),C.getMonth(),C.getDate()).getTime(),P=new Date(q.getFullYear(),q.getMonth(),q.getDate()).getTime(),_=new Date(S.getFullYear(),S.getMonth(),S.getDate()).getTime();te=_>se&&_<P}return{isSelected:U||J,isStart:U,isEnd:J,isInRange:te}},W=or({hasSelected:!!I}),G={enter:S=>({x:S>0?"100%":"-100%",opacity:0}),center:{x:0,opacity:1},exit:S=>({x:S<0?"100%":"-100%",opacity:0})};return l.jsxs("div",{className:y(W.datePicker,d),style:i,...x,children:[l.jsxs("div",{className:W.header,children:[l.jsxs(me,{variant:"text",disableTextMargins:!0,size:"small",onClick:()=>L(S=>S==="day"?"year":"day"),className:"text-label-large font-bold capitalize text-on-surface hover:bg-surface-container-highest",children:[l.jsx("span",{className:"mr-2",children:w==="day"?T.format(h):h.getFullYear()}),l.jsx(le,{icon:vn,className:y("w-3 h-3 transition-transform duration-200 inline",w==="year"&&"rotate-180")})]}),w==="day"&&l.jsxs("div",{className:"flex items-center",children:[l.jsx(ge,{size:"xSmall",allowShapeTransformation:!1,onClick:V,icon:Ws,label:"Previous month",title:null}),l.jsx(ge,{size:"xSmall",allowShapeTransformation:!1,onClick:Q,icon:xn,label:"Next month",title:null})]})]}),w==="year"?l.jsx("div",{className:"h-[280px] overflow-y-auto grid grid-cols-3 gap-2 p-2 scrollbar-hide",ref:M,children:D.map(S=>l.jsx(me,{size:"small",variant:S===h.getFullYear()?"filled":"text",onClick:()=>z(S),"data-selected":S===h.getFullYear(),className:y("w-full",{"text-on-surface":S!==h.getFullYear()}),label:S.toString(),children:S},S))}):l.jsxs(l.Fragment,{children:[l.jsx("div",{className:W.weekDays,children:X.map((S,N)=>l.jsx("div",{className:W.weekDay,children:S},N))}),l.jsx("div",{className:"overflow-hidden relative min-h-[240px]",children:l.jsx(Y.AnimatePresence,{mode:"popLayout",initial:!1,custom:p,children:l.jsx(Y.motion.div,{custom:p,variants:G,initial:"enter",animate:"center",exit:"exit",transition:{type:"spring",bounce:0,duration:.3},className:W.daysGrid,children:k.map((S,N)=>{if(!S.isCurrentMonth)return l.jsx("div",{className:W.dayCell},N);const{isSelected:C,isStart:q,isEnd:U,isInRange:J}=A(S.date),te=R(S.date),se=s&&S.date<s||r&&S.date>r||(u==null?void 0:u(S.date));return l.jsx("div",{className:y(W.dayCell,J&&"bg-primary/20",q&&(I==null?void 0:I[1])&&"bg-gradient-to-r from-transparent to-primary/20",U&&(I==null?void 0:I[0])&&"bg-gradient-to-l from-transparent to-primary/20"),children:l.jsx(me,{className:()=>({button:y("aspect-square h-[40px] p-0",{"text-on-surface":!C&&!te,"opacity-50":se}),stateLayer:y({"!bg-transparent":se})}),size:"small",allowShapeTransformation:!1,variant:y({filled:C,outlined:te,text:!C&&!te}),label:S.date.getDate().toString(),onClick:()=>O(S.date),disabled:se,children:S.date.getDate().toString()})},N)})},h.toISOString())})})]})]})},ir=({variant:e="filled",autoFocus:t,disabled:n=!1,errorText:s,placeholder:r,suffix:u,name:c,label:a,className:d,supportingText:i,trailingIcon:f,leadingIcon:x,type:h="text",multiline:m=!1,autoComplete:p="on",onChange:b,value:w,defaultValue:L,showSupportingText:E,id:g,style:F,ref:I,onFocus:v,onBlur:k,options:D,children:M,...T})=>{var nt;const j=o.useId(),X=g||j,V=`${X}-helper`,Q=w!==void 0,[z,$]=o.useState(L??""),R=Q?w:z,[O,A]=o.useState(!1),[W,G]=o.useState(!!(s!=null&&s.length)),S=o.useRef(null),N=I||S,C=o.useRef(null),q=o.useRef(null),U=o.useRef(null),J=E??(!!(s!=null&&s.length)||!!(i!=null&&i.length));o.useEffect(()=>{G(!!(s!=null&&s.length))},[s]);const te=()=>{N.current&&!O&&!n&&h!=="select"&&N.current.focus()};o.useEffect(()=>{if(!(!t||n)&&h!=="select"){const K=window.requestAnimationFrame(()=>{te()});return()=>window.cancelAnimationFrame(K)}},[t,n,N,h]),o.useEffect(()=>{O?(G(!1),v==null||v()):(s!=null&&s.length&&G(!0),k==null||k())},[O]);const se=K=>{const re=K.target.value;Q||$(re),G(!1),b&&b(K)},P=h==="date",[_,B]=o.useState(!1),[ee,oe]=o.useState(null),pe=o.useMemo(()=>{const K=String(R);if(!K)return null;const[re,xe,Ee]=K.split("-").map(Number);return re&&xe&&Ee?new Date(re,xe-1,Ee):null},[R]),Se=()=>{n||(_?B(!1):(oe(pe),B(!0)))};o.useEffect(()=>{_?A(!0):(!ae||!de)&&A(!1)},[_]),o.useEffect(()=>{if(!_)return;const K=fe=>{var Ne,Me;return fe?((Ne=C.current)==null?void 0:Ne.contains(fe))||((Me=U.current)==null?void 0:Me.contains(fe)):!1},re=fe=>{var st,rt;const Ne=fe.target,Me=(st=U.current)==null?void 0:st.contains(Ne),Rn=(rt=q.current)==null?void 0:rt.contains(Ne);!Me&&!Rn&&B(!1)},xe=fe=>{K(fe.target)||B(!1)},Ee=fe=>{fe.key==="Escape"&&B(!1)};return document.addEventListener("pointerdown",re),document.addEventListener("focusin",xe),document.addEventListener("keydown",Ee),()=>{document.removeEventListener("pointerdown",re),document.removeEventListener("focusin",xe),document.removeEventListener("keydown",Ee)}},[_]);const jn=()=>{const K=ee?ee.toLocaleDateString("en-CA"):"";Q||$(K),b&&b({target:{value:K,name:c,type:h}}),B(!1)},ae=h==="select",[de,De]=o.useState(!1),Ae=o.useRef(null),Qe=o.useMemo(()=>{if(ae&&D){const K=D.find(re=>String(re.value)===String(R));return K?K.label:R}return R},[R,ae,D]),et=()=>{n||(De(!de),A(!de))},tt=K=>{if(Q||$(String(K)),b){const re={target:{value:String(K),name:c,type:h}};b(re)}De(!1),A(!1)};o.useEffect(()=>{if(!de)return;const K=re=>{C.current&&!C.current.contains(re.target)&&Ae.current&&!Ae.current.contains(re.target)&&(De(!1),A(!1))};return document.addEventListener("mousedown",K),()=>{document.removeEventListener("mousedown",K)}},[de]);const ye=o.useMemo(()=>{if(f)return f;if(P)return As;if(ae)return de?Fs:vn},[f,P,ae,de]),Ln=P||ae?"[&::-webkit-calendar-picker-indicator]:hidden cursor-pointer selection:bg-transparent":"",ce=fn({showSupportingText:J,isFocused:O,showErrorIcon:W,disabled:n,name:c,label:a,autoComplete:p,className:d,onChange:b,placeholder:r,supportingText:i,type:h,leadingIcon:x,trailingIcon:ye,variant:e,errorText:s,value:String(Qe),suffix:u,multiline:m}),Mn=m?Pn:"input",In=m?{}:{type:ae?"text":h,readOnly:ae},Fe=O||typeof R=="string"&&R.length>0||h=="date"||ae&&de,Le=Fe&&e==="outlined",Cn=!Le;return l.jsxs("div",{ref:C,className:ce.textField,style:F,children:[l.jsxs("fieldset",{onClick:()=>{ae?et():te()},className:ce.content,role:"presentation",children:[l.jsx("div",{className:ce.stateLayer}),x&&l.jsx("div",{className:ce.leadingIcon,children:o.isValidElement(x)?x:l.jsx(le,{className:"w-5 h-5",icon:x})}),l.jsx(Y.motion.legend,{"aria-hidden":"true",variants:{hidden:{width:0,padding:0},visible:{width:"auto",padding:"0 8px"}},initial:Le?"visible":"hidden",animate:Le?"visible":"hidden",className:"max-w-full ml-2 px-2 text-body-small h-0 overflow-hidden whitespace-nowrap",transition:{duration:.2},children:l.jsx("span",{className:"transform inline-flex -translate-y-1/2 opacity-0",children:a})}),l.jsxs("div",{className:"flex-1 relative",children:[Cn&&l.jsx(Y.motion.label,{htmlFor:X,className:y("absolute left-4 transition-all duration-300 pointer-events-none",{"text-body-small top-2":e=="filled"&&Fe,"text-body-large top-1/2 transform -translate-y-1/2":!(e=="filled"&&Fe)}),transition:{duration:.3},layoutId:e==="outlined"?`${X}-label`:void 0,children:l.jsx("span",{className:ce.label,children:a})}),Le&&l.jsx(Y.motion.label,{htmlFor:X,className:y("absolute left-2 -top-3 px-1 text-body-small z-10",ce.label),layoutId:`${X}-label`,transition:{duration:.3},children:a}),l.jsx(Mn,{...T,ref:N,value:Qe,onChange:se,className:y(ce.input,Ln),id:X,name:c,placeholder:O?r??void 0:"",onFocus:()=>{ae||A(!0)},onBlur:()=>{ae||A(!1)},disabled:n,autoComplete:p,"aria-invalid":!!(s!=null&&s.length),"aria-describedby":J?V:void 0,...In})]}),l.jsx("div",{className:ce.activeIndicator}),!W&&l.jsxs(l.Fragment,{children:[ye&&l.jsx("div",{ref:P?q:void 0,onClick:K=>{K.stopPropagation(),P&&Se(),ae&&et()},className:y(ce.trailingIcon,(P||ae)&&"cursor-pointer"),children:l.jsx("div",{className:"flex items-center justify-center w-full h-full",children:o.isValidElement(ye)?ye:l.jsx(le,{className:"h-5",icon:ye})})}),!ye&&u&&l.jsx("span",{className:ce.suffix,children:u})]}),W&&l.jsx("div",{className:y(ce.trailingIcon,{" absolute right-0":!ye}),children:l.jsx(le,{className:"h-5 text-error",icon:Ps})})]}),J&&l.jsx("p",{className:ce.supportingText,id:V,children:s!=null&&s.length?s:i!=null&&i.length?i:" "}),P&&_&&l.jsx(l.Fragment,{children:l.jsx(be,{anchorRef:C,position:"bottom",children:l.jsxs("div",{ref:U,className:"z-50 shadow-xl rounded-[28px] bg-surface-container-high overflow-hidden",children:[l.jsx(En,{className:"",value:ee,onChange:oe}),l.jsxs("div",{className:"flex justify-end gap-2 p-4 pt-0",children:[l.jsx(me,{variant:"text",size:"small",onClick:()=>B(!1),children:"Cancel"}),l.jsx(me,{variant:"filled",size:"small",onClick:jn,children:"OK"})]})]})})}),ae&&de&&l.jsx(be,{anchorRef:C,position:"bottom",style:{width:(nt=C.current)==null?void 0:nt.offsetWidth},children:l.jsx("div",{ref:Ae,children:l.jsx(Ke,{className:"max-w-full",selected:R,children:M?o.Children.map(M,K=>o.isValidElement(K)&&K.type===Ie?o.cloneElement(K,{onClick:re=>{K.props.onClick&&K.props.onClick(re),tt(K.props.value??"")}}):K):D==null?void 0:D.map((K,re)=>K.type==="divider"?l.jsx(je,{className:"my-1"},re):K.type==="headline"?l.jsx(Ge,{label:K.label},re):l.jsx(Ie,{onClick:xe=>{K.onClick&&K.onClick(xe),tt(K.value??"")},...K,children:K.label},K.value??re))})})})]})},lr=({isSelected:e,icon:t,label:n,variant:s})=>({navigationRailItem:y(" group/navigation-rail-item flex flex-col pt-1 pb-1.5 cursor-pointer",{"text-on-surface-variant":!e,"text-on-secondary-container":e,"gap-2 h-[68px]":s=="vertical","gap-0 h-[66px]":s=="horizontal"}),container:y(" w-fit flex justify-center relative rounded-full items-center mx-5",{"bg-secondary-container overflow-hidden":e,"gap-2 ":s=="horizontal","gap-0 ":s=="vertical","p-4":!n},n&&["px-4",{"py-1 ":s=="vertical","py-4 ":s=="horizontal"}]),stateLayer:y("rounded-full"),icon:y("size-6 flex"),label:y("w-fit mx-auto text-nowrap",{"text-label-large ":s=="horizontal","text-label-medium":s=="vertical"})}),ar=Z("navigationRailItem",lr),Nn=({label:e})=>l.jsx("div",{className:" h-9 flex items-center mx-9 mt-3",children:l.jsx("p",{className:"text-label-large text-on-surface-variant",children:e})}),kn=({className:e,onClick:t,label:n,variant:s="vertical",href:r,icon:u,selectedItem:c,setSelectedItem:a,index:d,onItemSelected:i,selected:f=!1,ref:x,transition:h,isExtended:m,iconSelected:p,style:b,extendedOnly:w,children:L,...E})=>{L&&(n=L);const g=o.useRef(null),F=x||g,[I,v]=o.useState(f);o.useEffect(()=>{f&&c==null?v(!0):v(c==d&&d!=null)},[c]),o.useEffect(()=>{c==d&&i&&i({ref:F,index:d||0,label:n,icon:u})},[c]);const k=r?"a":"button",D=T=>{a&&a(d??null),t&&t(T)},M=ar({isExtended:m,extendedOnly:w,className:e,onItemSelected:i,selectedItem:c,index:d,transition:h,selected:I,variant:s,icon:u,label:n,isSelected:I,setSelectedItem:a,href:r,children:n,iconSelected:p});return h={duration:.3,...h},w&&!m?null:l.jsxs(k,{...E,role:"tab","aria-selected":I,ref:F,href:r,className:M.navigationRailItem,onClick:D,style:{transition:h.duration+"s",...b},children:[l.jsxs(Y.motion.div,{style:{transition:s=="horizontal"?h.duration+`s, gap ${h.duration/2}s ${h.duration-h.duration/2}s`:h.duration+`s, gap ${h.duration/3}s ${h.duration-h.duration/3}s`},transition:h,className:M.container,children:[l.jsx(ue,{style:{transition:h.duration+"s"},className:M.stateLayer,colorName:y({"on-surface":!I,"on-secondary-container":I}),stateClassName:"state-ripple-group-[navigation-rail-item]"}),u&&l.jsx(le,{icon:I?p:u,className:M.icon}),l.jsx(Y.AnimatePresence,{children:s=="horizontal"&&(()=>{const T={width:0,opacity:0,transition:{...h}},j={width:"auto",opacity:1,transition:{...h,opacity:{duration:h.duration/2,delay:h.duration-h.duration/2}}};return l.jsx(Y.motion.span,{initial:T,animate:j,exit:T,className:M.label,children:n})})()})]}),l.jsx(Y.AnimatePresence,{children:s=="vertical"&&(()=>{const T={height:0,opacity:0,transition:{...h,opacity:{duration:0}}},j={height:"auto",opacity:1,transition:{...h,opacity:{duration:h.duration/3,delay:h.duration-h.duration/3}}};return l.jsx(Y.motion.span,{initial:j,animate:j,exit:T,className:M.label,transition:h,children:n})})()})]})},cr=({isExtended:e,alignment:t})=>({navigationRail:y("flex flex-col left-0 h-full top-0 pt-11",{"w-fit max-w-24":!e,"w-fit min-w-[220px] max-w-[360px]":e,"justify-between":t=="middle","justify-start":t=="top"}),header:y("flex flex-col gap-1 items-start"),menuIcon:"mx-5",segments:y(" flex flex-col overflow-auto min-w-full mt-10",{"w-full":!e,"w-fit items-start":e})}),ur=Z("navigationRail",cr),dr=({variant:e="standard",onItemSelected:t,children:n,className:s,selectedItem:r,extended:u,alignment:c="top",menu:a={closed:{icon:Ts,label:"Open menu"},opened:{icon:ke,label:"Close menu"}},style:d,onExtendedChange:i,transition:f,setSelectedItem:x})=>{const[h,m]=o.useState(null),[p,b]=o.useState(u);let w;r==0||r!=null?w=r:w=h;const L=x||m,E=o.useRef(null),g=M=>{t==null||t(M)};function F(M){const T=[];return o.Children.forEach(M,j=>{o.isValidElement(j)&&j.type===o.Fragment?T.push(...F(j.props.children)):T.push(j)}),T}const I=F(n),v=I.filter(M=>o.isValidElement(M)&&M.type===Ce),k=ur({children:n,onItemSelected:t,selectedItem:w,setSelectedItem:L,className:s,variant:e,extended:p,isExtended:p,alignment:c,menu:a,transition:f,onExtendedChange:i});f={duration:.3,...f};const D=o.useRef(!1);return D.current=!1,o.useEffect(()=>{i==null||i(p??!1)},[p]),l.jsxs("div",{style:{transition:f.duration+"s",...d},ref:E,className:k.navigationRail,children:[l.jsxs("div",{className:k.header,children:[l.jsx(ge,{onClick:()=>b(!p),label:p?a==null?void 0:a.opened.label:a==null?void 0:a.closed.label,className:k.menuIcon,icon:p?a.opened.icon:a==null?void 0:a.closed.icon}),v.length>0&&o.cloneElement(v[0],{transition:f,isExtended:p,className:"!shadow-none mx-5 "+v[0].props.className})]}),l.jsx("div",{className:k.segments,children:(()=>{let M=0;return I.map(T=>o.isValidElement(T)&&T.type===kn?o.cloneElement(T,{key:M,index:M++,variant:p?"horizontal":"vertical",selectedItem:w,setSelectedItem:L,onItemSelected:g,transition:f,extendedOnly:D.current,isExtended:p}):o.isValidElement(T)&&T.type===Ce?null:o.isValidElement(T)&&T.type===Nn?(D.current=!0,p?o.cloneElement(T,{}):null):T)})()}),l.jsx("div",{className:"flex-1 max-h-[160px]"})]})};function fr(e){return we.defineConfig({variant:we.Variants.Udixio,...e,plugins:[new we.FontPlugin(e),new Oe.TailwindPlugin(e)]})}exports.AnchorPositioner=be;exports.AnimateOnScrollInit=ss;exports.Button=me;exports.Card=Cs;exports.Carousel=Rs;exports.CarouselItem=yn;exports.Checkbox=Os;exports.Chip=Be;exports.Chips=Gs;exports.ContextMenu=_s;exports.CustomScroll=vt;exports.DatePicker=En;exports.Divider=je;exports.Fab=Ce;exports.FabMenu=Ks;exports.Icon=le;exports.IconButton=ge;exports.Menu=Ke;exports.MenuGroup=He;exports.MenuHeadline=Ge;exports.MenuItem=Ie;exports.NavigationRail=dr;exports.NavigationRailItem=kn;exports.NavigationRailSection=Nn;exports.ProgressIndicator=pn;exports.RippleEffect=mt;exports.SideSheet=Zs;exports.Slider=Js;exports.SmoothScroll=Xn;exports.Snackbar=Qs;exports.State=ue;exports.Switch=er;exports.SyncedFixedWrapper=St;exports.Tab=bn;exports.TabGroup=nr;exports.TabPanel=Sn;exports.TabPanels=sr;exports.Tabs=tr;exports.TextField=ir;exports.ThemeProvider=Jn;exports.Tooltip=Je;exports.animateOnScroll=rs;exports.buttonStyle=os;exports.cardStyle=is;exports.carouselItemConfig=Ye;exports.carouselItemStyle=ls;exports.carouselStyle=as;exports.checkboxStyle=cs;exports.chipStyle=us;exports.chipsStyle=ds;exports.classNames=y;exports.classnames=yt;exports.createUseClassNames=Z;exports.customScrollStyle=xt;exports.defaultClassNames=ne;exports.defineConfig=fr;exports.dividerStyle=fs;exports.fabMenuStyle=ms;exports.fabStyle=hs;exports.getClassNames=Re;exports.iconButtonStyle=ps;exports.initAnimateOnScroll=_e;exports.menuGroupStyle=xs;exports.menuStyle=ys;exports.normalize=ve;exports.progressIndicatorStyle=vs;exports.sideSheetConfig=qe;exports.sideSheetStyle=Kt;exports.sliderConfig=Ue;exports.sliderStyle=ws;exports.snackbarStyle=bs;exports.switchStyle=Ss;exports.tabPanelStyle=js;exports.tabPanelsStyle=ks;exports.tabStyle=Es;exports.tabsStyle=Ns;exports.textFieldStyle=Ls;exports.toolStyle=Ms;exports.useButtonStyle=Nt;exports.useCardStyle=jt;exports.useCarouselItemStyle=Lt;exports.useCarouselStyle=It;exports.useCheckboxStyle=Rt;exports.useChipStyle=At;exports.useChipsStyle=Pt;exports.useClassNames=Wn;exports.useDividerStyle=Wt;exports.useFabMenuStyle=Ht;exports.useFabStyle=Ot;exports.useIconButtonStyle=zt;exports.useMenuGroupStyle=Ut;exports.useMenuStyle=Yt;exports.useProgressIndicatorStyle=Gt;exports.useSideSheetStyle=gs;exports.useSliderStyle=Jt;exports.useSnackbarStyle=Qt;exports.useStateStyle=bt;exports.useSwitchStyle=tn;exports.useTabPanelStyle=un;exports.useTabPanelsStyle=an;exports.useTabStyle=sn;exports.useTabsStyle=on;exports.useTextFieldStyle=fn;exports.useToolTipStyle=mn;exports.useTooltipTrigger=wn;