@udixio/ui-react 2.9.21 → 2.9.23
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/CHANGELOG.md +20 -0
- package/dist/index.cjs +3 -3
- package/dist/index.js +755 -750
- package/dist/lib/components/TextField.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/lib/components/TextField.tsx +52 -17
package/dist/index.cjs
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
"use strict";var rn=Object.defineProperty;var on=(e,t,n)=>t in e?rn(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var T=(e,t,n)=>on(e,typeof t!="symbol"?t+"":t,n);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),i=require("react"),X=require("motion/react"),Ke=require("clsx"),ln=require("tailwind-merge"),Me=require("react-dom"),Se=require("@udixio/theme"),Ge=require("@udixio/tailwind"),an=require("react-textarea-autosize"),Je=({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]=i.useState(!0),[u,c]=i.useState(!1),[l,d]=i.useState({x:50,y:50});i.useEffect(()=>{u&&(r(!0),r(!1))},[u]),i.useEffect(()=>{const p=t==null?void 0:t.current;if(p)return p.addEventListener("mousedown",o),p.addEventListener("mouseup",y),p.addEventListener("mouseleave",f),()=>{p.removeEventListener("mousedown",o),p.removeEventListener("mouseup",y),p.removeEventListener("mouseleave",f)}},[t]);const o=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)},y=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":l.x+"%","--y":l.y+"%","--r":"0%",background:`radial-gradient(ellipse at var(--x) var(--y), ${h} var(--r), transparent calc(var(--r) * 2))`,pointerEvents:"none"};return a.jsx(X.AnimatePresence,{mode:"wait",children:(u||!u&&!s)&&a.jsx(X.motion.div,{style:m,variants:n,initial:"initial",animate:"animate",exit:"exit",onAnimationComplete:()=>r(!0)})})},Ze=ln.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"]}}}),x=(...e)=>Ze(Ke.clsx(e)),Qe=(...e)=>Ze(Ke.clsx(e));function cn(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 Ee=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[l,d]=c;(t[l]??(t[l]=[])).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(cn(r)),n[r]=Qe(...u)}),n},ne=(e,t)=>n=>Ee({classNameList:[n.className,t],default:e,states:n}),ee=(e,t)=>n=>i.useMemo(()=>Ee({classNameList:[n.className,t],default:e,states:n}),[n]);function un(e,t,n){return i.useMemo(()=>Ee({classNameList:[n==null?void 0:n.className,t],default:e,states:n}),[e,t,n])}const et=ne("customScroll",({orientation:e,draggable:t,isDragging:n})=>({customScroll:x("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:x("overflow-hidden flex-none sticky",{"left-0 h-full":e==="horizontal","top-0 w-full":e==="vertical"})}));function dn(e,t){let n=0,s=null,r=null;const u=(c,l)=>{n=Date.now(),t(c,l)};return(c,l)=>{const d=Date.now(),o=e-(d-n);o<=0?(s&&(clearTimeout(s),s=null),u(c,l)):(r={v:c,o:l},s||(s=setTimeout(()=>{s=null;const f=r;r=null,f&&u(f.v,f.o)},o)))}}const tt=({children:e,orientation:t="vertical",scrollSize:n,onScroll:s,className:r,draggable:u=!1,throttleDuration:c=75,scroll:l,setScroll:d})=>{var te,E;const o=i.useRef(null),f=i.useRef(null),[y,h]=i.useState({width:null,height:null});i.useEffect(()=>{if(!o.current)return;const L=new ResizeObserver(N=>{for(const A of N)A.target===o.current&&h({width:A.contentRect.width,height:A.contentRect.height})});return L.observe(o.current),()=>{L.disconnect()}},[o]);const m=i.useRef(null),p=i.useRef(null),b=()=>{const L=f.current;return L?{width:n??L.scrollWidth,height:n??L.scrollHeight}:null},w=()=>{const L=o.current;return L?{width:L.clientWidth,height:L.clientHeight}:null},{scrollYProgress:I,scrollXProgress:S}=X.useScroll({container:o}),g=i.useRef(null);g.current||(g.current=dn(c,(L,N)=>{!p.current||!m.current||!o.current||(N===(t==="horizontal"?"x":"y")&&(d==null||d(L)),s&&(t==="horizontal"&&N==="x"&&s({scrollProgress:L,scroll:L*(m.current.width-o.current.clientWidth),scrollTotal:m.current.width-o.current.clientWidth,scrollVisible:p.current.width}),t==="vertical"&&N==="y"&&s({scrollProgress:L,scroll:L*(m.current.height-o.current.clientHeight),scrollTotal:m.current.height-o.current.clientHeight,scrollVisible:p.current.height})))}));const B=(L,N)=>{g.current&&g.current(L,N)};i.useEffect(()=>{y.width&&B(S.get(),"x"),y.height&&B(I.get(),"y")},[y]),i.useEffect(()=>{const L=o.current,N=f.current;if(!L||!N||typeof l!="number")return;const A=(O,_,z)=>Math.min(z,Math.max(_,O));if(t==="horizontal"){const O=Math.max(0,(n??N.scrollWidth)-L.clientWidth);L.scrollLeft=A(l*O,0,O)}else{const O=Math.max(0,(n??N.scrollHeight)-L.clientHeight);L.scrollTop=A(l*O,0,O)}},[l,t,n]),X.useMotionValueEvent(S,"change",L=>{B(L,"x")}),X.useMotionValueEvent(I,"change",L=>{B(L,"y")});const[$,v]=i.useState(!1);i.useLayoutEffect(()=>{$||!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,F]=i.useState(!1),j=et({isDragging:k,children:e,className:r,onScroll:s,orientation:t,scrollSize:n,draggable:u,throttleDuration:c}),[P,M]=i.useState(0),[q,V]=i.useState(0),Q=L=>{if(!u)return;const N=o.current;if(!N||P==null)return;const O=(L.pageX-N.offsetLeft-P)*1.5;N.scrollLeft=q-O},W=L=>{const N=o.current;N&&(F(!0),M(L.pageX-N.offsetLeft),V(N.scrollLeft))},C=L=>{k&&(L.preventDefault(),Q(L))},R=()=>{F(!1)},H=()=>{F(!1)},U=L=>{L.preventDefault()},G=i.useRef(null);return i.useEffect(()=>()=>{G.current&&clearTimeout(G.current)},[]),i.useEffect(()=>{const L=o.current;if(!L)return;const N=A=>{var Z,D,Y,se;const O=A.detail,_=o.current;if(!_||!O)return;const z=O.orientation??t;if(typeof O.progress=="number")if(z==="horizontal"){const ie=Math.max(0,(((Z=m.current)==null?void 0:Z.width)??0)-_.clientWidth);_.scrollLeft=Math.min(ie,Math.max(0,O.progress*ie))}else{const ie=Math.max(0,(((D=m.current)==null?void 0:D.height)??0)-_.clientHeight);_.scrollTop=Math.min(ie,Math.max(0,O.progress*ie))}else if(typeof O.scroll=="number")if(z==="horizontal"){const ie=Math.max(0,(((Y=m.current)==null?void 0:Y.width)??0)-_.clientWidth);_.scrollLeft=Math.min(ie,Math.max(0,O.scroll))}else{const ie=Math.max(0,(((se=m.current)==null?void 0:se.height)??0)-_.clientHeight);_.scrollTop=Math.min(ie,Math.max(0,O.scroll))}};return L.addEventListener("udx:customScroll:set",N),()=>{L.removeEventListener("udx:customScroll:set",N)}},[t]),a.jsxs("div",{className:j.customScroll,ref:o,onMouseDown:W,onMouseMove:C,onMouseUp:R,onMouseLeave:H,onDragStart:U,onScroll:L=>{k||(M(null),F(!0),G.current&&clearTimeout(G.current),G.current=setTimeout(()=>{F(!1)},1e3))},children:[a.jsx("div",{ref:f,style:t==="vertical"?{height:((te=p==null?void 0:p.current)==null?void 0:te.height)??"100%"}:{width:((E=p==null?void 0:p.current)==null?void 0:E.width)??"100%"},className:j.track,children:e}),p.current&&m.current&&a.jsxs(a.Fragment,{children:[t==="vertical"&&m.current.height>p.current.height&&a.jsx(X.motion.div,{className:"flex-none",style:{height:m.current.height-p.current.height}}),t==="horizontal"&&m.current.width>p.current.width&&a.jsx(X.motion.div,{className:"flex-none",style:{width:m.current.width-p.current.width}})]})]})};var fn="1.3.17";function nt(e,t,n){return Math.max(e,Math.min(t,n))}function hn(e,t,n){return(1-n)*e+n*t}function mn(e,t,n,s){return hn(e,t,1-Math.exp(-n*s))}function pn(e,t){return(e%t+t)%t}var yn=class{constructor(){T(this,"isRunning",!1);T(this,"value",0);T(this,"from",0);T(this,"to",0);T(this,"currentTime",0);T(this,"lerp");T(this,"duration");T(this,"easing");T(this,"onUpdate")}advance(e){var n;if(!this.isRunning)return;let t=!1;if(this.duration&&this.easing){this.currentTime+=e;const s=nt(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=mn(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 xn(e,t){let n;return function(...s){let r=this;clearTimeout(n),n=setTimeout(()=>{n=void 0,e.apply(r,s)},t)}}var vn=class{constructor(e,t,{autoResize:n=!0,debounce:s=250}={}){T(this,"width",0);T(this,"height",0);T(this,"scrollHeight",0);T(this,"scrollWidth",0);T(this,"debouncedResize");T(this,"wrapperResizeObserver");T(this,"contentResizeObserver");T(this,"resize",()=>{this.onWrapperResize(),this.onContentResize()});T(this,"onWrapperResize",()=>{this.wrapper instanceof Window?(this.width=window.innerWidth,this.height=window.innerHeight):(this.width=this.wrapper.clientWidth,this.height=this.wrapper.clientHeight)});T(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=xn(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}}},st=class{constructor(){T(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={}}},Oe=100/6,he={passive:!1},gn=class{constructor(e,t={wheelMultiplier:1,touchMultiplier:1}){T(this,"touchStart",{x:0,y:0});T(this,"lastDelta",{x:0,y:0});T(this,"window",{width:0,height:0});T(this,"emitter",new st);T(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})});T(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})});T(this,"onTouchEnd",e=>{this.emitter.emit("scroll",{deltaX:this.lastDelta.x,deltaY:this.lastDelta.y,event:e})});T(this,"onWheel",e=>{let{deltaX:t,deltaY:n,deltaMode:s}=e;const r=s===1?Oe:s===2?this.window.width:1,u=s===1?Oe: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})});T(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)}},Ve=e=>Math.min(1,1.001-Math.pow(2,-10*e)),wn=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:l,easing:d,lerp:o=.1,infinite:f=!1,orientation:y="vertical",gestureOrientation:h=y==="horizontal"?"both":"vertical",touchMultiplier:m=1,wheelMultiplier:p=1,autoResize:b=!0,prevent:w,virtualScroll:I,overscroll:S=!0,autoRaf:g=!1,anchors:B=!1,autoToggle:$=!1,allowNestedScroll:v=!1,__experimental__naiveDimensions:k=!1,naiveDimensions:F=k,stopInertiaOnNavigate:j=!1}={}){T(this,"_isScrolling",!1);T(this,"_isStopped",!1);T(this,"_isLocked",!1);T(this,"_preventNextNativeScrollEvent",!1);T(this,"_resetVelocityTimeout",null);T(this,"_rafId",null);T(this,"isTouching");T(this,"time",0);T(this,"userData",{});T(this,"lastVelocity",0);T(this,"velocity",0);T(this,"direction",0);T(this,"options");T(this,"targetScroll");T(this,"animatedScroll");T(this,"animate",new yn);T(this,"emitter",new st);T(this,"dimensions");T(this,"virtualScroll");T(this,"onScrollEnd",e=>{e instanceof CustomEvent||(this.isScrolling==="smooth"||this.isScrolling===!1)&&e.stopPropagation()});T(this,"dispatchScrollendEvent",()=>{this.options.wrapper.dispatchEvent(new CustomEvent("scrollend",{bubbles:this.options.wrapper===window,detail:{lenisScrollEnd:!0}}))});T(this,"onTransitionEnd",e=>{e.propertyName.includes("overflow")&&this.checkOverflow()});T(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()});T(this,"onPointerDown",e=>{e.button===1&&this.reset()});T(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 o=s.composedPath();o=o.slice(0,o.indexOf(this.rootElement));const f=this.options.prevent;if(o.find(w=>{var I,S,g;return w instanceof HTMLElement&&(typeof f=="function"&&(f==null?void 0:f(w))||((I=w.hasAttribute)==null?void 0:I.call(w,"data-lenis-prevent"))||r&&((S=w.hasAttribute)==null?void 0:S.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}})});T(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))}});T(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=fn,(!e||e===document.documentElement)&&(e=window),typeof l=="number"&&typeof d!="function"?d=Ve:typeof d=="function"&&typeof l!="number"&&(l=1),this.options={wrapper:e,content:t,eventsTarget:n,smoothWheel:s,syncTouch:r,syncTouchLerp:u,touchInertiaExponent:c,duration:l,easing:d,lerp:o,infinite:f,gestureOrientation:h,orientation:y,touchMultiplier:m,wheelMultiplier:p,autoResize:b,prevent:w,virtualScroll:I,overscroll:S,autoRaf:g,anchors:B,autoToggle:$,allowNestedScroll:v,naiveDimensions:F,stopInertiaOnNavigate:j},this.dimensions=new vn(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 gn(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:l=r?this.options.easing:void 0,onStart:d,onComplete:o,force:f=!1,userData:y}={}){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=nt(0,e,this.limit);if(e===this.targetScroll){d==null||d(this),o==null||o(this);return}if(this.userData=y??{},n){this.animatedScroll=this.targetScroll=e,this.setScroll(this.scroll),this.reset(),this.preventNextNativeScrollEvent(),this.emit(),o==null||o(this),this.userData={},requestAnimationFrame(()=>{this.dispatchScrollendEvent()});return}r||(this.targetScroll=e),typeof c=="number"&&typeof l!="function"?l=Ve:typeof l=="function"&&typeof c!="number"&&(c=1),this.animate.fromTo(this.animatedScroll,e,{duration:c,easing:l,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(),o==null||o(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,l,d,o,f,y,h;const m=this.options.gestureOrientation;if(s-(r.time??0)>2e3){r.time=Date.now();const $=window.getComputedStyle(e);r.computedStyle=$;const v=$.overflowX,k=$.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;o=e.scrollWidth,f=e.scrollHeight,y=e.clientWidth,h=e.clientHeight,l=o>y,d=f>h,r.isScrollableX=l,r.isScrollableY=d,r.scrollWidth=o,r.scrollHeight=f,r.clientWidth=y,r.clientHeight=h}else l=r.isScrollableX,d=r.isScrollableY,u=r.hasOverflowX,c=r.hasOverflowY,o=r.scrollWidth,f=r.scrollHeight,y=r.clientWidth,h=r.clientHeight;if(!u&&!c||!l&&!d||m==="vertical"&&(!c||!d)||m==="horizontal"&&(!u||!l))return!1;let p;if(m==="horizontal")p="x";else if(m==="vertical")p="y";else{const $=t!==0,v=n!==0;$&&u&&l&&(p="x"),v&&c&&d&&(p="y")}if(!p)return!1;let b,w,I,S,g;if(p==="x")b=e.scrollLeft,w=o-y,I=t,S=u,g=l;else if(p==="y")b=e.scrollTop,w=f-h,I=n,S=c,g=d;else return!1;return(I>0?b<w:b>0)&&S&&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?pn(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 bn=({transition:e=1.2,easing:t,orientation:n="vertical",smoothTouch:s=!1,touchMultiplier:r=2,children:u})=>{const c=i.useRef(null),l=i.useRef(null);return i.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 o=y=>1-Math.pow(1-y,5);c.current=new wn({duration:d,easing:t??o,orientation:n,smoothWheel:!0,touchMultiplier:r,syncTouch:s});const f=y=>{var h;(h=c.current)==null||h.raf(y),l.current=requestAnimationFrame(f)};return l.current=requestAnimationFrame(f),()=>{var y;l.current!==null&&cancelAnimationFrame(l.current),(y=c.current)==null||y.destroy(),c.current=null}},[e,t,n,s,r]),u?a.jsx(a.Fragment,{children:u}):null},de=({style:e,colorName:t,stateClassName:n="state-ripple-group",children:s,className:r})=>{const u=i.useRef(null),c=i.useRef(null),[l,d]=i.useState(!1),o=rt({isClient:l,stateClassName:n,className:r,colorName:t});return i.useEffect(()=>{if(u.current&&n!=="state-layer"){const y=(n.includes("[")?"group/"+n.split("[")[1].split("]")[0]:"group").replace(/\//g,"\\/"),h=u.current.closest(`.${y}:not(.${y} .${y})`);c.current=h}d(!0)},[]),a.jsxs("div",{ref:u,className:o.stateLayer,style:{"--state-color":`var(--default-color, var(--color-${t}))`,...e},children:[l&&a.jsx(Je,{triggerRef:c}),s]})},Sn=({isClient:e,stateClassName:t})=>({stateLayer:x(["w-full top-0 left-0 h-full absolute pointer-events-none overflow-hidden",t])}),rt=ee("stateLayer",Sn),ot=({targetRef:e,children:t})=>{const[n,s]=i.useState(null),r=i.useRef(null),u=()=>{const c=e.current;if(!c)return;const l=c.getBoundingClientRect();s({position:"fixed",top:l.top,left:l.left,width:l.width,height:l.height,pointerEvents:"none",zIndex:999})};return i.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 l;window.removeEventListener("scroll",u,!0),window.removeEventListener("resize",u),(l=r.current)==null||l.disconnect()}},[e]),n?Me.createPortal(a.jsx("div",{style:n,children:t}),document.body):null};function Nn(e){return/^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$/.test(e)}const En=({config:e,throttleDelay:t=100,onLoad:n,loadTheme:s=!1})=>{const[r,u]=i.useState(null);i.useEffect(()=>{(async()=>{const h=await Se.loader(e,s);u(h)})()},[]);const[c,l]=i.useState(null),d=i.useRef(null),o=i.useRef(0),f=i.useRef(null);i.useEffect(()=>{if(!r)return;const h={...e,sourceColor:e.sourceColor},m=Date.now(),p=m-o.current,b=async w=>{await y(w)};if(o.current===0||p>=t)d.current&&(clearTimeout(d.current),d.current=null),f.current=null,o.current=m,b(h);else if(f.current=h,!d.current){const w=Math.max(0,t-p);d.current=setTimeout(async()=>{d.current=null;const I=f.current;f.current=null,I&&(o.current=Date.now(),await b(I))},w)}return()=>{}},[e,t,r]);const y=async h=>{if(typeof h.sourceColor=="string"&&!Nn(h.sourceColor))throw new Error("Invalid hex color");if(!r)return;r.context.update(h),await r.load();const m=r==null?void 0:r.plugins.getPlugin(Ge.TailwindPlugin).getInstance().outputCss;l(m),n==null||n(r)};return i.useEffect(()=>()=>{d.current&&(clearTimeout(d.current),d.current=null)},[]),c?a.jsx("style",{dangerouslySetInnerHTML:{__html:c}}):null};function kn(){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 Ln(){return typeof window>"u"||!("matchMedia"in window)?!1:window.matchMedia("(prefers-reduced-motion: reduce)").matches}function Ce(e){if(!(e instanceof HTMLElement))return!1;const t=e.classList;return Array.from(t).some(n=>n.startsWith("anim-")&&n.includes("scroll"))}function ze(e){if(!(e instanceof HTMLElement))return!1;const t=e.classList;return Array.from(t).some(n=>n.startsWith("anim-"))}function ke(e,t){if(!Ce(e))return;if(e.hasAttribute(`data-${t}-scroll`)){const c=(e.getAttribute(`data-${t}-scroll`)||"").trim().toLowerCase(),l=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`)||(l==="inline"?e.classList.add(`${t}-timeline-inline`):l==="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 Le(e=document,t){return Array.from(e.querySelectorAll(`[class*="${t}-"][class*="-scroll"]`)).filter(s=>Ce(s))}function jn(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:!Ce(r)})}function In(e,t){return Array.from(e).some(n=>n.startsWith(t)&&n.includes("-out"))}function Ye(e,t,n){e.setAttribute(`data-${t}-run`,""),e.setAttribute(`data-${t}-${n}-run`,"")}function _e(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 Mn=[0,.2],qe=new WeakSet;function Xe(e,t){if(qe.has(e))return;qe.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 Re(e={}){const{prefix:t="anim",once:n=!0}=e;if(Ln())return()=>{};const s=kn(),r=new WeakSet;let u=typeof window<"u"&&(window.pageYOffset||window.scrollY)||0,c=!0;const l=()=>{const m=window.pageYOffset||window.scrollY||0;c=m>=u,u=m};typeof window<"u"&&window.addEventListener("scroll",l,{passive:!0});const d=new IntersectionObserver(m=>{for(const p of m){const b=p.target;if(!ze(b)||b.hasAttribute(`data-${t}-animating`))continue;const w=In(b.classList,t);p.isIntersecting?(w&&_e(b,t,"out"),Ye(b,t,"in"),n&&d.unobserve(b)):n||(c||_e(b,t,"in"),w&&Ye(b,t,"out"))}},{threshold:Mn}),o=m=>{const p=jn(m||document,t);for(const b of p)r.has(b)||(r.add(b),d.observe(b),Xe(b,t))};o();let f,y=null,h=null;if(s)(()=>{h==null&&(h=requestAnimationFrame(()=>{h=null;const p=Le(void 0,t);for(const b of p)ke(b,t)}))})(),y=new MutationObserver(p=>{for(const b of p)if(b.type==="attributes"){const w=b.target;w instanceof HTMLElement&&(ke(w,t),ze(w)&&(r.has(w)||(r.add(w),d.observe(w),Xe(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 I=Le(w,t);for(const S of I)ke(S,t);o(w)}}}),y.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),y&&y.disconnect()};else{let m;Le(void 0,t).length>0&&Promise.resolve().then(()=>require("./scrollDriven-DWAu7CR0.cjs")).then(b=>{m=b.initScrollViewFallback({once:n})}),f=()=>{typeof m=="function"&&m()}}return()=>{f&&f(),typeof window<"u"&&window.removeEventListener("scroll",l),d.disconnect()}}const Cn=Re,Rn=Re,De=({anchorRef:e,position:t="bottom",children:n,style:s,...r})=>{const c=`--anchor-${i.useId().replace(/:/g,"")}`,[l,d]=i.useState(!1);if(i.useLayoutEffect(()=>{typeof CSS<"u"&&CSS.supports("anchor-name","--a")&&d(!0)},[]),i.useLayoutEffect(()=>{if(l&&e.current){const f=e.current;return f.style.anchorName=c,()=>{e.current&&(e.current.style.anchorName="")}}},[l,e,c]),l){const y={position:"fixed",margin:0,zIndex:9999,positionAnchor:c,positionArea:{top:"top",bottom:"bottom",left:"left",right:"right","top-left":"top left","top-right":"top right","bottom-left":"bottom left","bottom-right":"bottom right"}[t],positionTryFallbacks:"flip-block, flip-inline",...s};return Me.createPortal(a.jsx("div",{style:y,...r,children:n}),document.body)}const o={position:"absolute",pointerEvents:"auto",...s};switch(t){case"top":o.bottom="100%",o.left="50%",o.transform="translateX(-50%)";break;case"top-left":o.bottom="100%",o.left=0;break;case"top-right":o.bottom="100%",o.right=0;break;case"bottom":o.top="100%",o.left="50%",o.transform="translateX(-50%)";break;case"bottom-left":o.top="100%",o.left=0;break;case"bottom-right":o.top="100%",o.right=0;break;case"left":o.right="100%",o.top="50%",o.transform="translateY(-50%)";break;case"right":o.left="100%",o.top="50%",o.transform="translateY(-50%)";break}return a.jsx(ot,{targetRef:e,children:a.jsx("div",{style:o,...r,children:n})})},it=({variant:e,disableTextMargins:t,disabled:n,iconPosition:s,icon:r,isActive:u,loading:c,shape:l,onToggle:d,size:o,allowShapeTransformation:f})=>({button:x(" relative cursor-pointer group/button outline-none inline-block flex justify-center items-center ",o==="xSmall"&&"text-label-large px-3 py-1.5 gap-1",o==="small"&&"text-label-large px-4 py-2.5 gap-2",o==="medium"&&"text-title-medium px-6 py-4 gap-2",o==="large"&&"text-headline-small px-12 py-8 gap-3",o==="xLarge"&&"text-headline-large px-16 py-12 gap-4",l==="rounded"&&{"rounded-[30px]":o==="xSmall"||o=="small","rounded-[40px]":o==="medium","rounded-[70px]":o==="large"||o=="xLarge"},(l==="squared"||f&&u)&&{"rounded-[12px]":o==="xSmall"||o=="small","rounded-[16px]":o==="medium","rounded-[28px]":o==="large"||o=="xLarge"},f&&!n&&{"active:rounded-[12px]":o==="xSmall"||o=="small","active:rounded-[16px]":o==="medium","active:rounded-[28px]":o==="large"||o=="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&&[o==="xSmall"&&"-mx-3 ",o==="small"&&"-mx-4 ",o==="medium"&&"-mx-6 ",o==="large"&&"-mx-12",o==="xLarge"&&"-mx-16 "]],n&&"cursor-default"),touchTarget:x("absolute -translate-x-1/2 -translate-y-1/2 left-1/2 top-1/2 h-12 w-full"),stateLayer:x("overflow-hidden",l==="rounded"&&{"rounded-[30px]":o==="xSmall"||o=="small","rounded-[40px]":o==="medium","rounded-[70px]":o==="large"||o=="xLarge"},(l==="squared"||f&&u)&&{"rounded-[12px]":o==="xSmall"||o=="small","rounded-[16px]":o==="medium","rounded-[28px]":o==="large"||o=="xLarge"},f&&!n&&{"group-active/button:rounded-[12px]":o==="xSmall"||o=="small","group-active/button:rounded-[16px]":o==="medium","group-active/button:rounded-[28px]":o==="large"||o=="xLarge"}),label:x({invisible:c}),icon:x({invisible:c},o==="xSmall"&&"size-5",o==="small"&&"size-5",o==="medium"&&"size-6",o==="large"&&"size-8",o==="xLarge"&&"size-10")}),Dn=ne("button",it),lt=ee("button",it),at=({variant:e,isInteractive:t})=>({card:x(" 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":t})}),An=ne("card",at),ct=ee("card",at),Ae=({width:e})=>({carouselItem:x("rounded-[28px] overflow-hidden flex-none",{hidden:e===void 0,"flex-1":e==null})}),Fn=ne("carouselItem",Ae),ut=ee("carouselItem",Ae),dt=()=>({carousel:x(["w-full h-[400px]"]),track:x("flex h-full w-full")}),$n=ne("carousel",dt),ft=ee("carousel",dt),ht=({isChecked:e,isIndeterminate:t,isDisabled:n,isError:s,isFocused:r,isHovered:u})=>({checkbox:x("inline-flex items-center justify-center relative size-4.5 ",{"pointer-events-none opacity-[0.38]":n}),input:x("absolute inset-0 w-full h-full opacity-0 z-10 cursor-pointer"),container:x("relative flex items-center justify-center w-[18px] h-[18px] "),box:x("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:x("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"}),Pn=ne("checkbox",ht),mt=ee("checkbox",ht),pt=({variant:e,disabled:t,trailingIcon:n,icon:s,isActive:r,isInteractive:u,activated:c,isFocused:l,isDragging:d,isEditing:o})=>({chip:x(" 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&&!l||o,"bg-secondary-container text-on-secondary-container":(c||l)&&!o},d&&["opacity-100 cursor-grabbing shadow-3"],e==="outlined"&&["border border-outline-variant",{"border-transparent":o}],e==="elevated"&&!o&&["shadow-1 bg-surface-container-low","border border-outline-variant"]),stateLayer:x("rounded-lg overflow-hidden",{}),label:x("outline-none text-nowrap",{"opacity-[0.38]":t}),leadingIcon:x("text-primary size-[18px]",{"opacity-[0.38]":t}),trailingIcon:x("cursor-pointer size-[18px]",{"opacity-[0.38]":t})}),Wn=ne("chip",pt),yt=ee("chip",pt),xt=({scrollable:e})=>({chips:x(" flex gap-3 outline-none",{"flex-wrap":!e,"overflow-x-auto":e})}),Tn=ne("chips",xt),vt=ee("chips",xt),gt=({orientation:e})=>({divider:x("border-outline-variant ",{"h-fit w-full border-t":e==="horizontal"},{"h-auto self-stretch w-fit border-l":e==="vertical"})}),Bn=ne("divider",gt),wt=ee("divider",gt),bt=({size:e,variant:t,extended:n})=>({fab:x("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:x({"size-6":e=="small"||e=="medium","size-9":e=="large"}),label:x("text-nowrap",{"text-title-medium":e=="small","text-title-large":e=="medium","text-headline-small":e=="large"})}),Hn=ne("fab",bt),St=ee("fab",bt),Nt=({size:e,variant:t,open:n})=>({fabMenu:x("relative inline-flex flex-col items-end"),actions:x("flex flex-col gap-1 items-end absolute bottom-[calc(100%_+_8px)] right-0"),label:x("text-nowrap")}),On=ne("fabMenu",Nt),Et=ee("fabMenu",Nt),kt=({variant:e,disabled:t,onToggle:n,isActive:s,size:r,width:u,shape:c,allowShapeTransformation:l})=>({iconButton:x("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"||l&&s)&&{"rounded-[12px]":r==="xSmall"||r=="small","rounded-[16px]":r==="medium","rounded-[28px]":r==="large"||r=="xLarge"},l&&!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:x("absolute -translate-x-1/2 -translate-y-1/2 left-1/2 top-1/2 h-12 w-full"),stateLayer:x("absolute top-0 left-0 h-full w-full overflow-hidden",(c==="rounded"||c==="squared"&&n&&!t&&s&&l)&&{"rounded-[30px]":r==="xSmall"||r=="small","rounded-[40px]":r==="medium","rounded-[70px]":r==="large"||r=="xLarge"},(c==="squared"||c==="rounded"&&n&&!t&&s&&l)&&{"rounded-[12px]":r==="xSmall"||r=="small","rounded-[16px]":r==="medium","rounded-[28px]":r==="large"||r=="xLarge"},l&&!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:x(" 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]")}),Vn=ne("iconButton",kt),Lt=ee("iconButton",kt),jt=({variant:e,isVisible:t})=>({progressIndicator:x((e==="linear-determinate"||e=="linear-indeterminate")&&"flex w-full h-1"),track:x("h-full rounded-full bg-primary rounded-l-full",{"max-h-0":!t,"max-h-full":t}),activeIndicator:x({"max-h-0":!t,"max-h-full":t},(e==="linear-determinate"||e=="linear-indeterminate")&&"h-full flex-1 rounded-full bg-primary-container",(e==="circular-determinate"||e=="circular-indeterminate")&&["stroke-primary fill-transparent ",{"stroke-[4px]":t,"stroke-[0px]":!t}]),stop:x("absolute top-1/2 -translate-y-1/2 right-0 bg-primary rounded-full size-1",{"max-h-0":!t,"max-h-full":t})}),zn=ne("progressIndicator",jt),It=ee("progressIndicator",jt),Fe=({variant:e,position:t})=>({sideSheet:x("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:x("w-full overflow-hidden flex flex-col",{}),header:x("p-4 flex items-center gap-2"),content:x("flex-1 overflow-y-auto"),title:x("text-on-surface-variant text-title-large"),closeButton:x("ml-auto"),divider:x({hidden:e=="modal"}),overlay:x("bg-[black]/[0.32] fixed top-0 left-0 w-screen h-screen")}),Mt=ne("sideSheet",Fe),Yn=ee("sideSheet",Fe),$e=({isChanging:e})=>({slider:x(["relative w-full h-11 flex items-center rounded gap-x-1.5 cursor-pointer min-w-32"]),activeTrack:x(["h-4 relative transition-all duration-100 bg-primary overflow-hidden rounded-l-full "]),inactiveTrack:x(["h-4 relative transition-all duration-100 bg-primary-container rounded-r-full overflow-hidden"]),handle:x(["transform relative transition-all duration-100 bg-primary h-full rounded-full ",{"w-0.5":e,"w-1":!e}]),valueIndicator:x(["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:x(["h-1 w-1 absolute transform -translate-y-1/2 -translate-x-1/2 top-1/2 rounded-full"])}),_n=ne("slider",$e),Ct=ee("slider",$e),Rt=()=>({snackbar:x(" rounded bg-inverse-surface "),container:x("pl-4 pr-2 max-w-full py-1 flex items-center flex-wrap"),supportingText:x("text-body-medium text-inverse-on-surface "),icon:x(" ml-auto mr-0 text-inverse-on-surface block dark")}),qn=ne("snackbar",Rt),Dt=ee("snackbar",Rt),At=({isSelected:e,disabled:t,inactiveIcon:n})=>({switch:x("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:x("flex items-center justify-center absolute",{"left-[14px]":!e},{"right-[14px]":e}),handle:x("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:x("w-[40px] h-[40px] -z-10 rounded-full absolute",{"group-state-primary":!t}),icon:x("w-[16px] h-[16px]",!t&&[{"text-on-primary-container":e},{"text-on-primary":!e}],{"text-on-surface/[0.38]":t})}),Xn=ne("switch",At),Ft=ee("switch",At),$t=({isSelected:e,icon:t,label:n,variant:s})=>({tab:x("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:x("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:x("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:x("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:x("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:x("bg-primary absolute w-full left-0 bottom-0",s==="primary"&&"h-[3px] rounded-t",s==="secondary"&&"h-0.5")}),Un=ne("tab",$t),Pt=ee("tab",$t),Wt=({scrollable:e})=>({tabs:x("border-b border-surface-container-highest bg-surface","flex relative ",{"overflow-x-auto":e})}),Kn=ne("tabs",Wt),Tt=ee("tabs",Wt),Bt=()=>({tabPanels:x("overflow-hidden")}),Gn=ne("tabPanels",Bt),Ht=ee("tabPanels",Bt),Ot=()=>({tabPanel:x("")}),Jn=ne("tabPanel",Ot),Vt=ee("tabPanel",Ot),zt=({disabled:e,leadingIcon:t,trailingIcon:n,variant:s,errorText:r,isFocused:u,value:c,suffix:l,multiline:d})=>({textField:x({"opacity-[.38]":e}),content:x("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:x("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:x("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:x("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":!!l},s=="filled"&&" pb-2 pt-6",s=="outlined"&&"py-4 relative z-10"),activeIndicator:x("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:x(" 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:x(["h-12 ml-3 flex items-center justify-center",{"cursor-text":!i.isValidElement(t)}]),trailingIcon:x("h-12 w-12 flex items-center justify-center",{"cursor-text":!i.isValidElement(n)}),suffix:x("text-on-surface-variant pl-0 pr-4",s=="filled"&&" pb-2 pt-6",s=="outlined"&&"py-4 relative z-10")}),Zn=ne("textField",zt),Yt=ee("textField",zt),_t=({position:e,variant:t})=>({toolTip:x(" 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:x("pb-2",t=="rich"&&"px-4 pt-3 ",t=="plain"&&"px-2 py-1"),actions:x("flex gap-10 px-1 mt-2",t=="plain"&&"hidden"),subHead:x("text-title-small mb-1",t=="plain"&&"hidden"),supportingText:x(""),content:x("w-full")}),Qn=ne("toolTip",_t),qt=ee("toolTip",_t),ae=({icon:e,colors:t=[],className:n,...s})=>{if(typeof e=="string"){let f=e;return t[0]&&(f=f.replace(/<svg([^>]*)>/,`<svg$1 fill="${t[0]}" color="${t[0]}">`),f=f.replace(/<path([^>]*?)>/g,'<path$1 fill="currentColor">')),a.jsx("div",{className:x("size-5 box-content inline-flex fill-current",n),style:{color:t[0]||"inherit"},dangerouslySetInnerHTML:{__html:f}})}if(e&&typeof e=="object"&&"src"in e){const f=e;return a.jsx("img",{src:f.src,width:f.width,height:f.height,className:x("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,l,,,d]=u||[],o=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 a.jsx("svg",{className:x("size-5 box-content",n),style:{...o(t)},xmlns:"http://www.w3.org/2000/svg",viewBox:`0 0 ${c} ${l}`,role:"img","aria-hidden":"true",...s,children:typeof d=="string"?a.jsx("path",{className:"fill-current",d}):d.map((f,y)=>a.jsx("path",{d:f},y))})},Xt=({variant:e="linear-determinate",value:t=0,transitionDuration:n=1e3,className:s,...r})=>{const[u,c]=i.useState(t),[l]=i.useState(1.5);i.useEffect(()=>{t>100&&(t=100),t<0&&(t=0),c(t)},[t]);const[d,o]=i.useState(!0),f=()=>d?l:l*.5;i.useEffect(()=>{if((e==="circular-indeterminate"||e==="linear-indeterminate")&&u!==100){const p=setInterval(()=>{c(d?10:90),o(!d)},f()*1e3);return()=>clearInterval(p)}},[e,d,u]);const[y,h]=i.useState(!1);i.useEffect(()=>{if(u>=100){const p=setTimeout(()=>{h(!1)},n);return()=>{clearTimeout(p)}}else h(!0)},[u,n]);const m=It({className:s,variant:e,value:t,transitionDuration:n,isVisible:y});return a.jsxs(a.Fragment,{children:[(e==="linear-determinate"||e=="linear-indeterminate")&&a.jsxs("div",{className:m.progressIndicator,...r,children:[a.jsx("div",{style:{width:`${u}%`,transition:`width ${n}ms ease-in-out ${u==100?", max-height 200ms 0.5s ease-in-out":""}`},className:m.track}),a.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.activeIndicator}),a.jsx("div",{style:{width:"4 px",transition:`width ${n}ms ease-in-out, max-height 200ms 0.5s ease-in-out`},className:m.stop})]}),(e==="circular-determinate"||e=="circular-indeterminate")&&a.jsx(X.motion.svg,{width:"48",height:"48",viewBox:"0 0 48 48",initial:{rotate:-90},animate:{rotate:270},transition:{repeat:1/0,duration:f(),ease:"linear"},className:m.progressIndicator,...r,children:a.jsx(X.motion.circle,{cx:"50%",cy:"50%",r:y?"calc(50% - 2px)":"50%",style:{strokeLinecap:"round"},initial:"hidden",animate:"visible",className:m.activeIndicator,variants:{hidden:{pathLength:d?10/100:90/100},visible:{pathLength:d?90/100:10/100}},transition:{pathLength:{type:"tween",ease:"linear",duration:f(),bounce:0}}})},d+"")]})};function es(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:l="left",loading:d=!1,shape:o="rounded",onClick:f,onToggle:y,activated:h,ref:m,size:p="medium",allowShapeTransformation:b=!0,transition:w,children:I,...S})=>{if(I&&(r=I),!r)throw new Error("Button component requires either a label prop or children content");e=es(e);const g=s?"a":"button",B=i.useRef(null),$=m||B,[v,k]=i.useState(h);i.useEffect(()=>{k(h)},[h]),w={duration:.3,...w};const F=M=>{t&&M.preventDefault(),y?(k(!v),y(!v)):f&&f(M)},j=lt({allowShapeTransformation:b,size:p,disableTextMargins:u,shape:o,href:s,disabled:t,icon:n,iconPosition:l,loading:d,variant:e,transition:w,className:c,isActive:v??!1,onToggle:y,activated:v,label:r,children:r}),P=n?a.jsx(ae,{icon:n,className:j.icon}):a.jsx(a.Fragment,{});return a.jsxs(g,{ref:$,href:s,className:j.button,...S,onClick:F,disabled:t,"aria-pressed":y?v:void 0,style:{transition:w.duration+"s"},children:[a.jsx("div",{className:j.touchTarget}),a.jsx(de,{style:{transition:w.duration+"s"},className:j.stateLayer,colorName:x(e==="filled"&&{"on-surface-variant":!v&&!!y,"on-primary":v||!y},e==="elevated"&&{"on-primary":v&&!!y,primary:!v||!y},e==="tonal"&&{"on-secondary":v&&!!y,"on-secondary-container":!v||!y},e==="outlined"&&{"inverse-on-surface":v&&!!y,"on-surface-variant":!v||!y},e==="text"&&"primary"),stateClassName:"state-ripple-group-[button]"}),l==="left"&&P,d&&a.jsx("div",{className:"!absolute left-1/2 -translate-x-1/2 top-1/2 -translate-y-1/2",children:a.jsx(Xt,{className:()=>({progressIndicator:"h-6 w-6",activeIndicator:x({"!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"})}),a.jsx("span",{className:j.label,children:r}),l==="right"&&P]})},ts=({variant:e="outlined",className:t,children:n,interactive:s=!1,ref:r,...u})=>{const c=ct({className:t,isInteractive:s,variant:e,children:n}),l=i.useRef(null),d=r||l;return a.jsxs("div",{...u,ref:d,className:c.card,children:[s&&a.jsx(de,{className:c.stateLayer,colorName:"on-surface",stateClassName:"state-ripple-group-[card]"}),n]})},xe=(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)},Ut=({className:e,children:t,width:n,index:s=0,outputRange:r,ref:u,...c})=>{const l=i.useRef(null),d=u||l,o=ut({className:e,index:s,width:n,children:t,outputRange:r});return a.jsx("div",{ref:d,style:{width:n+"px",maxWidth:r[1]+"px",minWidth:r[0]+"px",willChange:"width"},transition:{duration:.5,ease:"linear"},className:o.carouselItem,...c,children:t})},ns=({variant:e="hero",className:t,children:n,ref:s,marginPourcent:r=0,inputRange:u=[.21,.65],outputRange:c=[42,300],gap:l=8,onChange:d,onMetricsChange:o,index:f,scrollSensitivity:y=1.25,...h})=>{const m=i.useRef(null),p=s||m,[b,w]=i.useState(0),I=ft({index:f,className:t,children:n,variant:e,inputRange:u,outputRange:c,marginPourcent:r,onChange:d,gap:l,scrollSensitivity:y,onMetricsChange:o}),S=i.Children.toArray(n).filter(N=>i.isValidElement(N)&&N.type===Ut),g=i.useRef(null),[B,$]=i.useState({}),[v,k]=i.useState(null),F=i.useRef(0),j=i.useRef(null),P=()=>{var ue,ce;if(!g.current||!p.current||(v==null?void 0:v.scrollProgress)===void 0)return[];const N=(v==null?void 0:v.scrollVisible)??((ue=p.current)==null?void 0:ue.clientWidth)??0;function A(K,J){return K.map((re,pe)=>{const ye=(re-J)/Math.abs(K[1]-K[0]);return{itemScrollXCenter:re,relativeIndex:ye,index:pe,width:0}})}const O=S.map((K,J)=>{if(!M[J].current||!g.current)return 0;const pe=J/(S.length-1);return xe(pe,[0,1],[0,1])}),_=A(O,(v==null?void 0:v.scrollProgress)??0).sort((K,J)=>K.index-J.index);let z=(((ce=p.current)==null?void 0:ce.clientWidth)??N)+l+c[0]+l;const Z=_.sort((K,J)=>Math.abs(K.relativeIndex)-Math.abs(J.relativeIndex)).map((K,J)=>{if(!(z<=0)){if(J==0&&V(K.index),K.width=xe(z-l,[c[0],c[1]],[c[0],c[1]]),z-=K.width+l,z!=0&&z<(c[0]+l)*2){const re=K.width-((c[0]+l)*2-z);z+=K.width,K.width=re,z-=K.width}else if(z==0&&K.width>=c[0]*2+l){const re=K.width-(c[0]+l-z);z+=K.width,K.width=re,z-=K.width}return K}}).filter(Boolean),D=Z.reverse(),Y=[...Z].sort((K,J)=>Math.abs(K.index)-Math.abs(J.index));D.forEach((K,J)=>{const re=D[J+1];if(!re)return;const pe=1-(Math.abs(K.relativeIndex)-Math.abs(re==null?void 0:re.relativeIndex)),ye=xe(pe,[0,2],[K.width+z,re.width]);z+=K.width,K.width=ye,z-=K.width});const se=Z.length/2,ie=xe(Math.abs(Y[0].relativeIndex),[Y[0].index==0?0:se-1,se],[0,1]),ge=xe(ie,[0,1],[0,1])*-(c[0]+l);return w(ge),Object.fromEntries(Z.map(K=>[K.index,K.width]))},M=i.useRef([]).current,[q,V]=i.useState(0);i.useEffect(()=>{d&&d(q)},[q]),i.useEffect(()=>{typeof f=="number"&&S.length>0&&f!==q&&C(f)},[f,S.length]),i.useEffect(()=>{W(q)},[q]),M.length!==S.length&&S.forEach((N,A)=>{M[A]||(M[A]=i.createRef())});const[Q,W]=i.useState(0),C=(N,A={})=>{if(!S.length)return 0;const O=M[N];if(!O||!O.current||!g.current)return 0;const _=xe(N/Math.max(1,S.length-1),[0,1],[0,1]);return W(N),g.current.dispatchEvent(new CustomEvent("udx:customScroll:set",{bubbles:!0,detail:{progress:_,orientation:"horizontal",animate:A.animate!==!1}})),_},R=S.map((N,A)=>{var Z;const O=(Z=N.props)==null?void 0:Z.onClick,_=D=>{O==null||O(D)},z=()=>W(A);return i.cloneElement(N,{width:B[A],outputRange:c,ref:M[A],key:A,index:A,role:"option","aria-selected":q===A,tabIndex:q===A?0:-1,onClick:_,onFocus:z})}),H=N=>{var A;if(N.scrollTotal>0){(A=j.current)==null||A.stop();const O=F.current??0,_=N.scrollProgress??0;j.current=X.animate(O,_,{type:"spring",stiffness:260,damping:32,mass:.6,restDelta:5e-4,onUpdate:z=>{F.current=z,k({...N,scrollProgress:z})}})}};i.useEffect(()=>{const N=P();$(N)},[v]);const U=i.useRef(o);i.useEffect(()=>{U.current=o},[o]);const G=i.useRef(null);i.useEffect(()=>{var J;const N=U.current;if(!N||!(p!=null&&p.current))return;const A=S.length;if(A<=0)return;const O=((J=p.current)==null?void 0:J.clientWidth)??0,_=c[1],z=F.current??(v==null?void 0:v.scrollProgress)??0,Z=(O+l)/(_+l),D=Math.max(1,Math.floor(Z)),Y=Math.max(1,Math.round(D*(2/3))),se=Math.min(Math.max(0,q),Math.max(0,A-1)),ie=se>0,ge=se<A-1,ue={total:A,selectedIndex:se,visibleApprox:Z,visibleFull:D,stepHalf:Y,canPrev:ie,canNext:ge,scrollProgress:z,viewportWidth:O,itemMaxWidth:_,gap:l},ce=G.current;let K=!ce;if(!K){for(const re in ue)if(ue[re]!==ce[re]){K=!0;break}}K&&(G.current=ue,N(ue))},[p,S.length,q,v,l,c]),i.useEffect(()=>()=>{var N;(N=j.current)==null||N.stop()},[]);const[te,E]=i.useState(0);i.useLayoutEffect(()=>{let N=c[1];v&&N>v.scrollVisible&&(N=v.scrollVisible);const A=(N+l)*R.length/y;E(A)},[p,M,v]);const L=N=>{if(!S.length)return;const A=Q??q;switch(N.key){case"ArrowLeft":N.preventDefault(),C(Math.max(0,A-1));break;case"ArrowRight":N.preventDefault(),C(Math.min(S.length-1,A+1));break;case"Home":N.preventDefault(),C(0);break;case"End":N.preventDefault(),C(S.length-1);break;case"Enter":case" ":N.preventDefault(),C(A);break}};return i.useEffect(()=>{const N=p.current;if(!N)return;const A=O=>{const _=O.detail;_&&typeof _.index=="number"&&C(_.index)};return N.addEventListener("udx:carousel:centerIndex",A),()=>{N.removeEventListener("udx:carousel:centerIndex",A)}},[p,S.length]),a.jsx("div",{className:I.carousel,ref:p,role:"listbox","aria-orientation":"horizontal",onKeyDown:L,...h,children:a.jsx(tt,{draggable:!0,orientation:"horizontal",onScroll:H,scrollSize:te,children:a.jsx("div",{className:I.track,ref:g,style:{gap:`${l}px`,translate:b,willChange:"translate"},children:R})})})};/*!
|
|
1
|
+
"use strict";var dn=Object.defineProperty;var fn=(e,t,n)=>t in e?dn(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var T=(e,t,n)=>fn(e,typeof t!="symbol"?t+"":t,n);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),i=require("react"),X=require("motion/react"),et=require("clsx"),hn=require("tailwind-merge"),Fe=require("react-dom"),je=require("@udixio/theme"),tt=require("@udixio/tailwind"),mn=require("react-textarea-autosize"),nt=({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]=i.useState(!0),[u,c]=i.useState(!1),[l,d]=i.useState({x:50,y:50});i.useEffect(()=>{u&&(r(!0),r(!1))},[u]),i.useEffect(()=>{const p=t==null?void 0:t.current;if(p)return p.addEventListener("mousedown",o),p.addEventListener("mouseup",y),p.addEventListener("mouseleave",f),()=>{p.removeEventListener("mousedown",o),p.removeEventListener("mouseup",y),p.removeEventListener("mouseleave",f)}},[t]);const o=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)},y=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":l.x+"%","--y":l.y+"%","--r":"0%",background:`radial-gradient(ellipse at var(--x) var(--y), ${h} var(--r), transparent calc(var(--r) * 2))`,pointerEvents:"none"};return a.jsx(X.AnimatePresence,{mode:"wait",children:(u||!u&&!s)&&a.jsx(X.motion.div,{style:m,variants:n,initial:"initial",animate:"animate",exit:"exit",onAnimationComplete:()=>r(!0)})})},st=hn.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"]}}}),x=(...e)=>st(et.clsx(e)),rt=(...e)=>st(et.clsx(e));function pn(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 Me=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[l,d]=c;(t[l]??(t[l]=[])).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(pn(r)),n[r]=rt(...u)}),n},ne=(e,t)=>n=>Me({classNameList:[n.className,t],default:e,states:n}),ee=(e,t)=>n=>i.useMemo(()=>Me({classNameList:[n.className,t],default:e,states:n}),[n]);function yn(e,t,n){return i.useMemo(()=>Me({classNameList:[n==null?void 0:n.className,t],default:e,states:n}),[e,t,n])}const ot=ne("customScroll",({orientation:e,draggable:t,isDragging:n})=>({customScroll:x("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:x("overflow-hidden flex-none sticky",{"left-0 h-full":e==="horizontal","top-0 w-full":e==="vertical"})}));function xn(e,t){let n=0,s=null,r=null;const u=(c,l)=>{n=Date.now(),t(c,l)};return(c,l)=>{const d=Date.now(),o=e-(d-n);o<=0?(s&&(clearTimeout(s),s=null),u(c,l)):(r={v:c,o:l},s||(s=setTimeout(()=>{s=null;const f=r;r=null,f&&u(f.v,f.o)},o)))}}const it=({children:e,orientation:t="vertical",scrollSize:n,onScroll:s,className:r,draggable:u=!1,throttleDuration:c=75,scroll:l,setScroll:d})=>{var te,E;const o=i.useRef(null),f=i.useRef(null),[y,h]=i.useState({width:null,height:null});i.useEffect(()=>{if(!o.current)return;const L=new ResizeObserver(N=>{for(const A of N)A.target===o.current&&h({width:A.contentRect.width,height:A.contentRect.height})});return L.observe(o.current),()=>{L.disconnect()}},[o]);const m=i.useRef(null),p=i.useRef(null),b=()=>{const L=f.current;return L?{width:n??L.scrollWidth,height:n??L.scrollHeight}:null},w=()=>{const L=o.current;return L?{width:L.clientWidth,height:L.clientHeight}:null},{scrollYProgress:I,scrollXProgress:S}=X.useScroll({container:o}),g=i.useRef(null);g.current||(g.current=xn(c,(L,N)=>{!p.current||!m.current||!o.current||(N===(t==="horizontal"?"x":"y")&&(d==null||d(L)),s&&(t==="horizontal"&&N==="x"&&s({scrollProgress:L,scroll:L*(m.current.width-o.current.clientWidth),scrollTotal:m.current.width-o.current.clientWidth,scrollVisible:p.current.width}),t==="vertical"&&N==="y"&&s({scrollProgress:L,scroll:L*(m.current.height-o.current.clientHeight),scrollTotal:m.current.height-o.current.clientHeight,scrollVisible:p.current.height})))}));const B=(L,N)=>{g.current&&g.current(L,N)};i.useEffect(()=>{y.width&&B(S.get(),"x"),y.height&&B(I.get(),"y")},[y]),i.useEffect(()=>{const L=o.current,N=f.current;if(!L||!N||typeof l!="number")return;const A=(O,_,z)=>Math.min(z,Math.max(_,O));if(t==="horizontal"){const O=Math.max(0,(n??N.scrollWidth)-L.clientWidth);L.scrollLeft=A(l*O,0,O)}else{const O=Math.max(0,(n??N.scrollHeight)-L.clientHeight);L.scrollTop=A(l*O,0,O)}},[l,t,n]),X.useMotionValueEvent(S,"change",L=>{B(L,"x")}),X.useMotionValueEvent(I,"change",L=>{B(L,"y")});const[P,v]=i.useState(!1);i.useLayoutEffect(()=>{P||!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,F]=i.useState(!1),j=ot({isDragging:k,children:e,className:r,onScroll:s,orientation:t,scrollSize:n,draggable:u,throttleDuration:c}),[$,M]=i.useState(0),[q,V]=i.useState(0),Q=L=>{if(!u)return;const N=o.current;if(!N||$==null)return;const O=(L.pageX-N.offsetLeft-$)*1.5;N.scrollLeft=q-O},W=L=>{const N=o.current;N&&(F(!0),M(L.pageX-N.offsetLeft),V(N.scrollLeft))},C=L=>{k&&(L.preventDefault(),Q(L))},R=()=>{F(!1)},H=()=>{F(!1)},U=L=>{L.preventDefault()},G=i.useRef(null);return i.useEffect(()=>()=>{G.current&&clearTimeout(G.current)},[]),i.useEffect(()=>{const L=o.current;if(!L)return;const N=A=>{var J,D,Y,se;const O=A.detail,_=o.current;if(!_||!O)return;const z=O.orientation??t;if(typeof O.progress=="number")if(z==="horizontal"){const ie=Math.max(0,(((J=m.current)==null?void 0:J.width)??0)-_.clientWidth);_.scrollLeft=Math.min(ie,Math.max(0,O.progress*ie))}else{const ie=Math.max(0,(((D=m.current)==null?void 0:D.height)??0)-_.clientHeight);_.scrollTop=Math.min(ie,Math.max(0,O.progress*ie))}else if(typeof O.scroll=="number")if(z==="horizontal"){const ie=Math.max(0,(((Y=m.current)==null?void 0:Y.width)??0)-_.clientWidth);_.scrollLeft=Math.min(ie,Math.max(0,O.scroll))}else{const ie=Math.max(0,(((se=m.current)==null?void 0:se.height)??0)-_.clientHeight);_.scrollTop=Math.min(ie,Math.max(0,O.scroll))}};return L.addEventListener("udx:customScroll:set",N),()=>{L.removeEventListener("udx:customScroll:set",N)}},[t]),a.jsxs("div",{className:j.customScroll,ref:o,onMouseDown:W,onMouseMove:C,onMouseUp:R,onMouseLeave:H,onDragStart:U,onScroll:L=>{k||(M(null),F(!0),G.current&&clearTimeout(G.current),G.current=setTimeout(()=>{F(!1)},1e3))},children:[a.jsx("div",{ref:f,style:t==="vertical"?{height:((te=p==null?void 0:p.current)==null?void 0:te.height)??"100%"}:{width:((E=p==null?void 0:p.current)==null?void 0:E.width)??"100%"},className:j.track,children:e}),p.current&&m.current&&a.jsxs(a.Fragment,{children:[t==="vertical"&&m.current.height>p.current.height&&a.jsx(X.motion.div,{className:"flex-none",style:{height:m.current.height-p.current.height}}),t==="horizontal"&&m.current.width>p.current.width&&a.jsx(X.motion.div,{className:"flex-none",style:{width:m.current.width-p.current.width}})]})]})};var vn="1.3.17";function lt(e,t,n){return Math.max(e,Math.min(t,n))}function gn(e,t,n){return(1-n)*e+n*t}function wn(e,t,n,s){return gn(e,t,1-Math.exp(-n*s))}function bn(e,t){return(e%t+t)%t}var Sn=class{constructor(){T(this,"isRunning",!1);T(this,"value",0);T(this,"from",0);T(this,"to",0);T(this,"currentTime",0);T(this,"lerp");T(this,"duration");T(this,"easing");T(this,"onUpdate")}advance(e){var n;if(!this.isRunning)return;let t=!1;if(this.duration&&this.easing){this.currentTime+=e;const s=lt(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=wn(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 Nn(e,t){let n;return function(...s){let r=this;clearTimeout(n),n=setTimeout(()=>{n=void 0,e.apply(r,s)},t)}}var En=class{constructor(e,t,{autoResize:n=!0,debounce:s=250}={}){T(this,"width",0);T(this,"height",0);T(this,"scrollHeight",0);T(this,"scrollWidth",0);T(this,"debouncedResize");T(this,"wrapperResizeObserver");T(this,"contentResizeObserver");T(this,"resize",()=>{this.onWrapperResize(),this.onContentResize()});T(this,"onWrapperResize",()=>{this.wrapper instanceof Window?(this.width=window.innerWidth,this.height=window.innerHeight):(this.width=this.wrapper.clientWidth,this.height=this.wrapper.clientHeight)});T(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=Nn(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}}},at=class{constructor(){T(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={}}},qe=100/6,me={passive:!1},kn=class{constructor(e,t={wheelMultiplier:1,touchMultiplier:1}){T(this,"touchStart",{x:0,y:0});T(this,"lastDelta",{x:0,y:0});T(this,"window",{width:0,height:0});T(this,"emitter",new at);T(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})});T(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})});T(this,"onTouchEnd",e=>{this.emitter.emit("scroll",{deltaX:this.lastDelta.x,deltaY:this.lastDelta.y,event:e})});T(this,"onWheel",e=>{let{deltaX:t,deltaY:n,deltaMode:s}=e;const r=s===1?qe:s===2?this.window.width:1,u=s===1?qe: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})});T(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,me),this.element.addEventListener("touchstart",this.onTouchStart,me),this.element.addEventListener("touchmove",this.onTouchMove,me),this.element.addEventListener("touchend",this.onTouchEnd,me)}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,me),this.element.removeEventListener("touchstart",this.onTouchStart,me),this.element.removeEventListener("touchmove",this.onTouchMove,me),this.element.removeEventListener("touchend",this.onTouchEnd,me)}},Xe=e=>Math.min(1,1.001-Math.pow(2,-10*e)),Ln=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:l,easing:d,lerp:o=.1,infinite:f=!1,orientation:y="vertical",gestureOrientation:h=y==="horizontal"?"both":"vertical",touchMultiplier:m=1,wheelMultiplier:p=1,autoResize:b=!0,prevent:w,virtualScroll:I,overscroll:S=!0,autoRaf:g=!1,anchors:B=!1,autoToggle:P=!1,allowNestedScroll:v=!1,__experimental__naiveDimensions:k=!1,naiveDimensions:F=k,stopInertiaOnNavigate:j=!1}={}){T(this,"_isScrolling",!1);T(this,"_isStopped",!1);T(this,"_isLocked",!1);T(this,"_preventNextNativeScrollEvent",!1);T(this,"_resetVelocityTimeout",null);T(this,"_rafId",null);T(this,"isTouching");T(this,"time",0);T(this,"userData",{});T(this,"lastVelocity",0);T(this,"velocity",0);T(this,"direction",0);T(this,"options");T(this,"targetScroll");T(this,"animatedScroll");T(this,"animate",new Sn);T(this,"emitter",new at);T(this,"dimensions");T(this,"virtualScroll");T(this,"onScrollEnd",e=>{e instanceof CustomEvent||(this.isScrolling==="smooth"||this.isScrolling===!1)&&e.stopPropagation()});T(this,"dispatchScrollendEvent",()=>{this.options.wrapper.dispatchEvent(new CustomEvent("scrollend",{bubbles:this.options.wrapper===window,detail:{lenisScrollEnd:!0}}))});T(this,"onTransitionEnd",e=>{e.propertyName.includes("overflow")&&this.checkOverflow()});T(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()});T(this,"onPointerDown",e=>{e.button===1&&this.reset()});T(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 o=s.composedPath();o=o.slice(0,o.indexOf(this.rootElement));const f=this.options.prevent;if(o.find(w=>{var I,S,g;return w instanceof HTMLElement&&(typeof f=="function"&&(f==null?void 0:f(w))||((I=w.hasAttribute)==null?void 0:I.call(w,"data-lenis-prevent"))||r&&((S=w.hasAttribute)==null?void 0:S.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}})});T(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))}});T(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=vn,(!e||e===document.documentElement)&&(e=window),typeof l=="number"&&typeof d!="function"?d=Xe:typeof d=="function"&&typeof l!="number"&&(l=1),this.options={wrapper:e,content:t,eventsTarget:n,smoothWheel:s,syncTouch:r,syncTouchLerp:u,touchInertiaExponent:c,duration:l,easing:d,lerp:o,infinite:f,gestureOrientation:h,orientation:y,touchMultiplier:m,wheelMultiplier:p,autoResize:b,prevent:w,virtualScroll:I,overscroll:S,autoRaf:g,anchors:B,autoToggle:P,allowNestedScroll:v,naiveDimensions:F,stopInertiaOnNavigate:j},this.dimensions=new En(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 kn(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:l=r?this.options.easing:void 0,onStart:d,onComplete:o,force:f=!1,userData:y}={}){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=lt(0,e,this.limit);if(e===this.targetScroll){d==null||d(this),o==null||o(this);return}if(this.userData=y??{},n){this.animatedScroll=this.targetScroll=e,this.setScroll(this.scroll),this.reset(),this.preventNextNativeScrollEvent(),this.emit(),o==null||o(this),this.userData={},requestAnimationFrame(()=>{this.dispatchScrollendEvent()});return}r||(this.targetScroll=e),typeof c=="number"&&typeof l!="function"?l=Xe:typeof l=="function"&&typeof c!="number"&&(c=1),this.animate.fromTo(this.animatedScroll,e,{duration:c,easing:l,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(),o==null||o(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,l,d,o,f,y,h;const m=this.options.gestureOrientation;if(s-(r.time??0)>2e3){r.time=Date.now();const P=window.getComputedStyle(e);r.computedStyle=P;const v=P.overflowX,k=P.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;o=e.scrollWidth,f=e.scrollHeight,y=e.clientWidth,h=e.clientHeight,l=o>y,d=f>h,r.isScrollableX=l,r.isScrollableY=d,r.scrollWidth=o,r.scrollHeight=f,r.clientWidth=y,r.clientHeight=h}else l=r.isScrollableX,d=r.isScrollableY,u=r.hasOverflowX,c=r.hasOverflowY,o=r.scrollWidth,f=r.scrollHeight,y=r.clientWidth,h=r.clientHeight;if(!u&&!c||!l&&!d||m==="vertical"&&(!c||!d)||m==="horizontal"&&(!u||!l))return!1;let p;if(m==="horizontal")p="x";else if(m==="vertical")p="y";else{const P=t!==0,v=n!==0;P&&u&&l&&(p="x"),v&&c&&d&&(p="y")}if(!p)return!1;let b,w,I,S,g;if(p==="x")b=e.scrollLeft,w=o-y,I=t,S=u,g=l;else if(p==="y")b=e.scrollTop,w=f-h,I=n,S=c,g=d;else return!1;return(I>0?b<w:b>0)&&S&&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?bn(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 jn=({transition:e=1.2,easing:t,orientation:n="vertical",smoothTouch:s=!1,touchMultiplier:r=2,children:u})=>{const c=i.useRef(null),l=i.useRef(null);return i.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 o=y=>1-Math.pow(1-y,5);c.current=new Ln({duration:d,easing:t??o,orientation:n,smoothWheel:!0,touchMultiplier:r,syncTouch:s});const f=y=>{var h;(h=c.current)==null||h.raf(y),l.current=requestAnimationFrame(f)};return l.current=requestAnimationFrame(f),()=>{var y;l.current!==null&&cancelAnimationFrame(l.current),(y=c.current)==null||y.destroy(),c.current=null}},[e,t,n,s,r]),u?a.jsx(a.Fragment,{children:u}):null},fe=({style:e,colorName:t,stateClassName:n="state-ripple-group",children:s,className:r})=>{const u=i.useRef(null),c=i.useRef(null),[l,d]=i.useState(!1),o=ct({isClient:l,stateClassName:n,className:r,colorName:t});return i.useEffect(()=>{if(u.current&&n!=="state-layer"){const y=(n.includes("[")?"group/"+n.split("[")[1].split("]")[0]:"group").replace(/\//g,"\\/"),h=u.current.closest(`.${y}:not(.${y} .${y})`);c.current=h}d(!0)},[]),a.jsxs("div",{ref:u,className:o.stateLayer,style:{"--state-color":`var(--default-color, var(--color-${t}))`,...e},children:[l&&a.jsx(nt,{triggerRef:c}),s]})},In=({isClient:e,stateClassName:t})=>({stateLayer:x(["w-full top-0 left-0 h-full absolute pointer-events-none overflow-hidden",t])}),ct=ee("stateLayer",In),ut=({targetRef:e,children:t})=>{const[n,s]=i.useState(null),r=i.useRef(null),u=()=>{const c=e.current;if(!c)return;const l=c.getBoundingClientRect();s({position:"fixed",top:l.top,left:l.left,width:l.width,height:l.height,pointerEvents:"none",zIndex:999})};return i.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 l;window.removeEventListener("scroll",u,!0),window.removeEventListener("resize",u),(l=r.current)==null||l.disconnect()}},[e]),n?Fe.createPortal(a.jsx("div",{style:n,children:t}),document.body):null};function Mn(e){return/^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$/.test(e)}const Cn=({config:e,throttleDelay:t=100,onLoad:n,loadTheme:s=!1})=>{const[r,u]=i.useState(null);i.useEffect(()=>{(async()=>{const h=await je.loader(e,s);u(h)})()},[]);const[c,l]=i.useState(null),d=i.useRef(null),o=i.useRef(0),f=i.useRef(null);i.useEffect(()=>{if(!r)return;const h={...e,sourceColor:e.sourceColor},m=Date.now(),p=m-o.current,b=async w=>{await y(w)};if(o.current===0||p>=t)d.current&&(clearTimeout(d.current),d.current=null),f.current=null,o.current=m,b(h);else if(f.current=h,!d.current){const w=Math.max(0,t-p);d.current=setTimeout(async()=>{d.current=null;const I=f.current;f.current=null,I&&(o.current=Date.now(),await b(I))},w)}return()=>{}},[e,t,r]);const y=async h=>{if(typeof h.sourceColor=="string"&&!Mn(h.sourceColor))throw new Error("Invalid hex color");if(!r)return;r.context.update(h),await r.load();const m=r==null?void 0:r.plugins.getPlugin(tt.TailwindPlugin).getInstance().outputCss;l(m),n==null||n(r)};return i.useEffect(()=>()=>{d.current&&(clearTimeout(d.current),d.current=null)},[]),c?a.jsx("style",{dangerouslySetInnerHTML:{__html:c}}):null};function Rn(){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 Dn(){return typeof window>"u"||!("matchMedia"in window)?!1:window.matchMedia("(prefers-reduced-motion: reduce)").matches}function Pe(e){if(!(e instanceof HTMLElement))return!1;const t=e.classList;return Array.from(t).some(n=>n.startsWith("anim-")&&n.includes("scroll"))}function Ue(e){if(!(e instanceof HTMLElement))return!1;const t=e.classList;return Array.from(t).some(n=>n.startsWith("anim-"))}function Ce(e,t){if(!Pe(e))return;if(e.hasAttribute(`data-${t}-scroll`)){const c=(e.getAttribute(`data-${t}-scroll`)||"").trim().toLowerCase(),l=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`)||(l==="inline"?e.classList.add(`${t}-timeline-inline`):l==="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 Re(e=document,t){return Array.from(e.querySelectorAll(`[class*="${t}-"][class*="-scroll"]`)).filter(s=>Pe(s))}function An(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:!Pe(r)})}function Fn(e,t){return Array.from(e).some(n=>n.startsWith(t)&&n.includes("-out"))}function Ke(e,t,n){e.setAttribute(`data-${t}-run`,""),e.setAttribute(`data-${t}-${n}-run`,"")}function Ge(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 Pn=[0,.2],Je=new WeakSet;function Ze(e,t){if(Je.has(e))return;Je.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(Dn())return()=>{};const s=Rn(),r=new WeakSet;let u=typeof window<"u"&&(window.pageYOffset||window.scrollY)||0,c=!0;const l=()=>{const m=window.pageYOffset||window.scrollY||0;c=m>=u,u=m};typeof window<"u"&&window.addEventListener("scroll",l,{passive:!0});const d=new IntersectionObserver(m=>{for(const p of m){const b=p.target;if(!Ue(b)||b.hasAttribute(`data-${t}-animating`))continue;const w=Fn(b.classList,t);p.isIntersecting?(w&&Ge(b,t,"out"),Ke(b,t,"in"),n&&d.unobserve(b)):n||(c||Ge(b,t,"in"),w&&Ke(b,t,"out"))}},{threshold:Pn}),o=m=>{const p=An(m||document,t);for(const b of p)r.has(b)||(r.add(b),d.observe(b),Ze(b,t))};o();let f,y=null,h=null;if(s)(()=>{h==null&&(h=requestAnimationFrame(()=>{h=null;const p=Re(void 0,t);for(const b of p)Ce(b,t)}))})(),y=new MutationObserver(p=>{for(const b of p)if(b.type==="attributes"){const w=b.target;w instanceof HTMLElement&&(Ce(w,t),Ue(w)&&(r.has(w)||(r.add(w),d.observe(w),Ze(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 I=Re(w,t);for(const S of I)Ce(S,t);o(w)}}}),y.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),y&&y.disconnect()};else{let m;Re(void 0,t).length>0&&Promise.resolve().then(()=>require("./scrollDriven-DWAu7CR0.cjs")).then(b=>{m=b.initScrollViewFallback({once:n})}),f=()=>{typeof m=="function"&&m()}}return()=>{f&&f(),typeof window<"u"&&window.removeEventListener("scroll",l),d.disconnect()}}const $n=$e,Wn=$e,We=({anchorRef:e,position:t="bottom",children:n,style:s,...r})=>{const c=`--anchor-${i.useId().replace(/:/g,"")}`,[l,d]=i.useState(!1);if(i.useLayoutEffect(()=>{typeof CSS<"u"&&CSS.supports("anchor-name","--a")&&d(!0)},[]),i.useLayoutEffect(()=>{if(l&&e.current){const f=e.current;return f.style.anchorName=c,()=>{e.current&&(e.current.style.anchorName="")}}},[l,e,c]),l){const y={position:"fixed",margin:0,zIndex:9999,positionAnchor:c,positionArea:{top:"top",bottom:"bottom",left:"left",right:"right","top-left":"top left","top-right":"top right","bottom-left":"bottom left","bottom-right":"bottom right"}[t],positionTryFallbacks:"flip-block, flip-inline",...s};return Fe.createPortal(a.jsx("div",{style:y,...r,children:n}),document.body)}const o={position:"absolute",pointerEvents:"auto",...s};switch(t){case"top":o.bottom="100%",o.left="50%",o.transform="translateX(-50%)";break;case"top-left":o.bottom="100%",o.left=0;break;case"top-right":o.bottom="100%",o.right=0;break;case"bottom":o.top="100%",o.left="50%",o.transform="translateX(-50%)";break;case"bottom-left":o.top="100%",o.left=0;break;case"bottom-right":o.top="100%",o.right=0;break;case"left":o.right="100%",o.top="50%",o.transform="translateY(-50%)";break;case"right":o.left="100%",o.top="50%",o.transform="translateY(-50%)";break}return a.jsx(ut,{targetRef:e,children:a.jsx("div",{style:o,...r,children:n})})},dt=({variant:e,disableTextMargins:t,disabled:n,iconPosition:s,icon:r,isActive:u,loading:c,shape:l,onToggle:d,size:o,allowShapeTransformation:f})=>({button:x(" relative cursor-pointer group/button outline-none inline-block flex justify-center items-center ",o==="xSmall"&&"text-label-large px-3 py-1.5 gap-1",o==="small"&&"text-label-large px-4 py-2.5 gap-2",o==="medium"&&"text-title-medium px-6 py-4 gap-2",o==="large"&&"text-headline-small px-12 py-8 gap-3",o==="xLarge"&&"text-headline-large px-16 py-12 gap-4",l==="rounded"&&{"rounded-[30px]":o==="xSmall"||o=="small","rounded-[40px]":o==="medium","rounded-[70px]":o==="large"||o=="xLarge"},(l==="squared"||f&&u)&&{"rounded-[12px]":o==="xSmall"||o=="small","rounded-[16px]":o==="medium","rounded-[28px]":o==="large"||o=="xLarge"},f&&!n&&{"active:rounded-[12px]":o==="xSmall"||o=="small","active:rounded-[16px]":o==="medium","active:rounded-[28px]":o==="large"||o=="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&&[o==="xSmall"&&"-mx-3 ",o==="small"&&"-mx-4 ",o==="medium"&&"-mx-6 ",o==="large"&&"-mx-12",o==="xLarge"&&"-mx-16 "]],n&&"cursor-default"),touchTarget:x("absolute -translate-x-1/2 -translate-y-1/2 left-1/2 top-1/2 h-12 w-full"),stateLayer:x("overflow-hidden",l==="rounded"&&{"rounded-[30px]":o==="xSmall"||o=="small","rounded-[40px]":o==="medium","rounded-[70px]":o==="large"||o=="xLarge"},(l==="squared"||f&&u)&&{"rounded-[12px]":o==="xSmall"||o=="small","rounded-[16px]":o==="medium","rounded-[28px]":o==="large"||o=="xLarge"},f&&!n&&{"group-active/button:rounded-[12px]":o==="xSmall"||o=="small","group-active/button:rounded-[16px]":o==="medium","group-active/button:rounded-[28px]":o==="large"||o=="xLarge"}),label:x({invisible:c}),icon:x({invisible:c},o==="xSmall"&&"size-5",o==="small"&&"size-5",o==="medium"&&"size-6",o==="large"&&"size-8",o==="xLarge"&&"size-10")}),Tn=ne("button",dt),ft=ee("button",dt),ht=({variant:e,isInteractive:t})=>({card:x(" 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":t})}),Bn=ne("card",ht),mt=ee("card",ht),Te=({width:e})=>({carouselItem:x("rounded-[28px] overflow-hidden flex-none",{hidden:e===void 0,"flex-1":e==null})}),Hn=ne("carouselItem",Te),pt=ee("carouselItem",Te),yt=()=>({carousel:x(["w-full h-[400px]"]),track:x("flex h-full w-full")}),On=ne("carousel",yt),xt=ee("carousel",yt),vt=({isChecked:e,isIndeterminate:t,isDisabled:n,isError:s,isFocused:r,isHovered:u})=>({checkbox:x("inline-flex items-center justify-center relative size-4.5 ",{"pointer-events-none opacity-[0.38]":n}),input:x("absolute inset-0 w-full h-full opacity-0 z-10 cursor-pointer"),container:x("relative flex items-center justify-center w-[18px] h-[18px] "),box:x("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:x("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"}),Vn=ne("checkbox",vt),gt=ee("checkbox",vt),wt=({variant:e,disabled:t,trailingIcon:n,icon:s,isActive:r,isInteractive:u,activated:c,isFocused:l,isDragging:d,isEditing:o})=>({chip:x(" 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&&!l||o,"bg-secondary-container text-on-secondary-container":(c||l)&&!o},d&&["opacity-100 cursor-grabbing shadow-3"],e==="outlined"&&["border border-outline-variant",{"border-transparent":o}],e==="elevated"&&!o&&["shadow-1 bg-surface-container-low","border border-outline-variant"]),stateLayer:x("rounded-lg overflow-hidden",{}),label:x("outline-none text-nowrap",{"opacity-[0.38]":t}),leadingIcon:x("text-primary size-[18px]",{"opacity-[0.38]":t}),trailingIcon:x("cursor-pointer size-[18px]",{"opacity-[0.38]":t})}),zn=ne("chip",wt),bt=ee("chip",wt),St=({scrollable:e})=>({chips:x(" flex gap-3 outline-none",{"flex-wrap":!e,"overflow-x-auto":e})}),Yn=ne("chips",St),Nt=ee("chips",St),Et=({orientation:e})=>({divider:x("border-outline-variant ",{"h-fit w-full border-t":e==="horizontal"},{"h-auto self-stretch w-fit border-l":e==="vertical"})}),_n=ne("divider",Et),kt=ee("divider",Et),Lt=({size:e,variant:t,extended:n})=>({fab:x("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:x({"size-6":e=="small"||e=="medium","size-9":e=="large"}),label:x("text-nowrap",{"text-title-medium":e=="small","text-title-large":e=="medium","text-headline-small":e=="large"})}),qn=ne("fab",Lt),jt=ee("fab",Lt),It=({size:e,variant:t,open:n})=>({fabMenu:x("relative inline-flex flex-col items-end"),actions:x("flex flex-col gap-1 items-end absolute bottom-[calc(100%_+_8px)] right-0"),label:x("text-nowrap")}),Xn=ne("fabMenu",It),Mt=ee("fabMenu",It),Ct=({variant:e,disabled:t,onToggle:n,isActive:s,size:r,width:u,shape:c,allowShapeTransformation:l})=>({iconButton:x("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"||l&&s)&&{"rounded-[12px]":r==="xSmall"||r=="small","rounded-[16px]":r==="medium","rounded-[28px]":r==="large"||r=="xLarge"},l&&!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:x("absolute -translate-x-1/2 -translate-y-1/2 left-1/2 top-1/2 h-12 w-full"),stateLayer:x("absolute top-0 left-0 h-full w-full overflow-hidden",(c==="rounded"||c==="squared"&&n&&!t&&s&&l)&&{"rounded-[30px]":r==="xSmall"||r=="small","rounded-[40px]":r==="medium","rounded-[70px]":r==="large"||r=="xLarge"},(c==="squared"||c==="rounded"&&n&&!t&&s&&l)&&{"rounded-[12px]":r==="xSmall"||r=="small","rounded-[16px]":r==="medium","rounded-[28px]":r==="large"||r=="xLarge"},l&&!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:x(" 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]")}),Un=ne("iconButton",Ct),Rt=ee("iconButton",Ct),Dt=({variant:e,isVisible:t})=>({progressIndicator:x((e==="linear-determinate"||e=="linear-indeterminate")&&"flex w-full h-1"),track:x("h-full rounded-full bg-primary rounded-l-full",{"max-h-0":!t,"max-h-full":t}),activeIndicator:x({"max-h-0":!t,"max-h-full":t},(e==="linear-determinate"||e=="linear-indeterminate")&&"h-full flex-1 rounded-full bg-primary-container",(e==="circular-determinate"||e=="circular-indeterminate")&&["stroke-primary fill-transparent ",{"stroke-[4px]":t,"stroke-[0px]":!t}]),stop:x("absolute top-1/2 -translate-y-1/2 right-0 bg-primary rounded-full size-1",{"max-h-0":!t,"max-h-full":t})}),Kn=ne("progressIndicator",Dt),At=ee("progressIndicator",Dt),Be=({variant:e,position:t})=>({sideSheet:x("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:x("w-full overflow-hidden flex flex-col",{}),header:x("p-4 flex items-center gap-2"),content:x("flex-1 overflow-y-auto"),title:x("text-on-surface-variant text-title-large"),closeButton:x("ml-auto"),divider:x({hidden:e=="modal"}),overlay:x("bg-[black]/[0.32] fixed top-0 left-0 w-screen h-screen")}),Ft=ne("sideSheet",Be),Gn=ee("sideSheet",Be),He=({isChanging:e})=>({slider:x(["relative w-full h-11 flex items-center rounded gap-x-1.5 cursor-pointer min-w-32"]),activeTrack:x(["h-4 relative transition-all duration-100 bg-primary overflow-hidden rounded-l-full "]),inactiveTrack:x(["h-4 relative transition-all duration-100 bg-primary-container rounded-r-full overflow-hidden"]),handle:x(["transform relative transition-all duration-100 bg-primary h-full rounded-full ",{"w-0.5":e,"w-1":!e}]),valueIndicator:x(["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:x(["h-1 w-1 absolute transform -translate-y-1/2 -translate-x-1/2 top-1/2 rounded-full"])}),Jn=ne("slider",He),Pt=ee("slider",He),$t=()=>({snackbar:x(" rounded bg-inverse-surface "),container:x("pl-4 pr-2 max-w-full py-1 flex items-center flex-wrap"),supportingText:x("text-body-medium text-inverse-on-surface "),icon:x(" ml-auto mr-0 text-inverse-on-surface block dark")}),Zn=ne("snackbar",$t),Wt=ee("snackbar",$t),Tt=({isSelected:e,disabled:t,inactiveIcon:n})=>({switch:x("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:x("flex items-center justify-center absolute",{"left-[14px]":!e},{"right-[14px]":e}),handle:x("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:x("w-[40px] h-[40px] -z-10 rounded-full absolute",{"group-state-primary":!t}),icon:x("w-[16px] h-[16px]",!t&&[{"text-on-primary-container":e},{"text-on-primary":!e}],{"text-on-surface/[0.38]":t})}),Qn=ne("switch",Tt),Bt=ee("switch",Tt),Ht=({isSelected:e,icon:t,label:n,variant:s})=>({tab:x("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:x("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:x("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:x("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:x("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:x("bg-primary absolute w-full left-0 bottom-0",s==="primary"&&"h-[3px] rounded-t",s==="secondary"&&"h-0.5")}),es=ne("tab",Ht),Ot=ee("tab",Ht),Vt=({scrollable:e})=>({tabs:x("border-b border-surface-container-highest bg-surface","flex relative ",{"overflow-x-auto":e})}),ts=ne("tabs",Vt),zt=ee("tabs",Vt),Yt=()=>({tabPanels:x("overflow-hidden")}),ns=ne("tabPanels",Yt),_t=ee("tabPanels",Yt),qt=()=>({tabPanel:x("")}),ss=ne("tabPanel",qt),Xt=ee("tabPanel",qt),Ut=({disabled:e,leadingIcon:t,trailingIcon:n,variant:s,errorText:r,isFocused:u,value:c,suffix:l,multiline:d})=>({textField:x({"opacity-[.38]":e}),content:x("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:x("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:x("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:x("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":!!l},s=="filled"&&" pb-2 pt-6",s=="outlined"&&"py-4 relative z-10"),activeIndicator:x("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:x(" 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:x(["h-12 ml-3 flex items-center justify-center",{"cursor-text":!i.isValidElement(t)}]),trailingIcon:x("h-12 w-12 flex items-center justify-center",{"cursor-text":!i.isValidElement(n)}),suffix:x("text-on-surface-variant pl-0 pr-4",s=="filled"&&" pb-2 pt-6",s=="outlined"&&"py-4 relative z-10")}),rs=ne("textField",Ut),Kt=ee("textField",Ut),Gt=({position:e,variant:t})=>({toolTip:x(" 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:x("pb-2",t=="rich"&&"px-4 pt-3 ",t=="plain"&&"px-2 py-1"),actions:x("flex gap-10 px-1 mt-2",t=="plain"&&"hidden"),subHead:x("text-title-small mb-1",t=="plain"&&"hidden"),supportingText:x(""),content:x("w-full")}),os=ne("toolTip",Gt),Jt=ee("toolTip",Gt),ae=({icon:e,colors:t=[],className:n,...s})=>{if(typeof e=="string"){let f=e;return t[0]&&(f=f.replace(/<svg([^>]*)>/,`<svg$1 fill="${t[0]}" color="${t[0]}">`),f=f.replace(/<path([^>]*?)>/g,'<path$1 fill="currentColor">')),a.jsx("div",{className:x("size-5 box-content inline-flex fill-current",n),style:{color:t[0]||"inherit"},dangerouslySetInnerHTML:{__html:f}})}if(e&&typeof e=="object"&&"src"in e){const f=e;return a.jsx("img",{src:f.src,width:f.width,height:f.height,className:x("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,l,,,d]=u||[],o=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 a.jsx("svg",{className:x("size-5 box-content",n),style:{...o(t)},xmlns:"http://www.w3.org/2000/svg",viewBox:`0 0 ${c} ${l}`,role:"img","aria-hidden":"true",...s,children:typeof d=="string"?a.jsx("path",{className:"fill-current",d}):d.map((f,y)=>a.jsx("path",{d:f},y))})},Zt=({variant:e="linear-determinate",value:t=0,transitionDuration:n=1e3,className:s,...r})=>{const[u,c]=i.useState(t),[l]=i.useState(1.5);i.useEffect(()=>{t>100&&(t=100),t<0&&(t=0),c(t)},[t]);const[d,o]=i.useState(!0),f=()=>d?l:l*.5;i.useEffect(()=>{if((e==="circular-indeterminate"||e==="linear-indeterminate")&&u!==100){const p=setInterval(()=>{c(d?10:90),o(!d)},f()*1e3);return()=>clearInterval(p)}},[e,d,u]);const[y,h]=i.useState(!1);i.useEffect(()=>{if(u>=100){const p=setTimeout(()=>{h(!1)},n);return()=>{clearTimeout(p)}}else h(!0)},[u,n]);const m=At({className:s,variant:e,value:t,transitionDuration:n,isVisible:y});return a.jsxs(a.Fragment,{children:[(e==="linear-determinate"||e=="linear-indeterminate")&&a.jsxs("div",{className:m.progressIndicator,...r,children:[a.jsx("div",{style:{width:`${u}%`,transition:`width ${n}ms ease-in-out ${u==100?", max-height 200ms 0.5s ease-in-out":""}`},className:m.track}),a.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.activeIndicator}),a.jsx("div",{style:{width:"4 px",transition:`width ${n}ms ease-in-out, max-height 200ms 0.5s ease-in-out`},className:m.stop})]}),(e==="circular-determinate"||e=="circular-indeterminate")&&a.jsx(X.motion.svg,{width:"48",height:"48",viewBox:"0 0 48 48",initial:{rotate:-90},animate:{rotate:270},transition:{repeat:1/0,duration:f(),ease:"linear"},className:m.progressIndicator,...r,children:a.jsx(X.motion.circle,{cx:"50%",cy:"50%",r:y?"calc(50% - 2px)":"50%",style:{strokeLinecap:"round"},initial:"hidden",animate:"visible",className:m.activeIndicator,variants:{hidden:{pathLength:d?10/100:90/100},visible:{pathLength:d?90/100:10/100}},transition:{pathLength:{type:"tween",ease:"linear",duration:f(),bounce:0}}})},d+"")]})};function is(e){const t={primary:"filled",secondary:"tonal"};return e&&e in t?t[e]:e||"filled"}const pe=({variant:e="filled",disabled:t=!1,icon:n,href:s,label:r,disableTextMargins:u,className:c,iconPosition:l="left",loading:d=!1,shape:o="rounded",onClick:f,onToggle:y,activated:h,ref:m,size:p="medium",allowShapeTransformation:b=!0,transition:w,children:I,...S})=>{if(I&&(r=I),!r)throw new Error("Button component requires either a label prop or children content");e=is(e);const g=s?"a":"button",B=i.useRef(null),P=m||B,[v,k]=i.useState(h);i.useEffect(()=>{k(h)},[h]),w={duration:.3,...w};const F=M=>{t&&M.preventDefault(),y?(k(!v),y(!v)):f&&f(M)},j=ft({allowShapeTransformation:b,size:p,disableTextMargins:u,shape:o,href:s,disabled:t,icon:n,iconPosition:l,loading:d,variant:e,transition:w,className:c,isActive:v??!1,onToggle:y,activated:v,label:r,children:r}),$=n?a.jsx(ae,{icon:n,className:j.icon}):a.jsx(a.Fragment,{});return a.jsxs(g,{ref:P,href:s,className:j.button,...S,onClick:F,disabled:t,"aria-pressed":y?v:void 0,style:{transition:w.duration+"s"},children:[a.jsx("div",{className:j.touchTarget}),a.jsx(fe,{style:{transition:w.duration+"s"},className:j.stateLayer,colorName:x(e==="filled"&&{"on-surface-variant":!v&&!!y,"on-primary":v||!y},e==="elevated"&&{"on-primary":v&&!!y,primary:!v||!y},e==="tonal"&&{"on-secondary":v&&!!y,"on-secondary-container":!v||!y},e==="outlined"&&{"inverse-on-surface":v&&!!y,"on-surface-variant":!v||!y},e==="text"&&"primary"),stateClassName:"state-ripple-group-[button]"}),l==="left"&&$,d&&a.jsx("div",{className:"!absolute left-1/2 -translate-x-1/2 top-1/2 -translate-y-1/2",children:a.jsx(Zt,{className:()=>({progressIndicator:"h-6 w-6",activeIndicator:x({"!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"})}),a.jsx("span",{className:j.label,children:r}),l==="right"&&$]})},ls=({variant:e="outlined",className:t,children:n,interactive:s=!1,ref:r,...u})=>{const c=mt({className:t,isInteractive:s,variant:e,children:n}),l=i.useRef(null),d=r||l;return a.jsxs("div",{...u,ref:d,className:c.card,children:[s&&a.jsx(fe,{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)},Qt=({className:e,children:t,width:n,index:s=0,outputRange:r,ref:u,...c})=>{const l=i.useRef(null),d=u||l,o=pt({className:e,index:s,width:n,children:t,outputRange:r});return a.jsx("div",{ref:d,style:{width:n+"px",maxWidth:r[1]+"px",minWidth:r[0]+"px",willChange:"width"},transition:{duration:.5,ease:"linear"},className:o.carouselItem,...c,children:t})},as=({variant:e="hero",className:t,children:n,ref:s,marginPourcent:r=0,inputRange:u=[.21,.65],outputRange:c=[42,300],gap:l=8,onChange:d,onMetricsChange:o,index:f,scrollSensitivity:y=1.25,...h})=>{const m=i.useRef(null),p=s||m,[b,w]=i.useState(0),I=xt({index:f,className:t,children:n,variant:e,inputRange:u,outputRange:c,marginPourcent:r,onChange:d,gap:l,scrollSensitivity:y,onMetricsChange:o}),S=i.Children.toArray(n).filter(N=>i.isValidElement(N)&&N.type===Qt),g=i.useRef(null),[B,P]=i.useState({}),[v,k]=i.useState(null),F=i.useRef(0),j=i.useRef(null),$=()=>{var ue,ce;if(!g.current||!p.current||(v==null?void 0:v.scrollProgress)===void 0)return[];const N=(v==null?void 0:v.scrollVisible)??((ue=p.current)==null?void 0:ue.clientWidth)??0;function A(K,Z){return K.map((re,ye)=>{const xe=(re-Z)/Math.abs(K[1]-K[0]);return{itemScrollXCenter:re,relativeIndex:xe,index:ye,width:0}})}const O=S.map((K,Z)=>{if(!M[Z].current||!g.current)return 0;const ye=Z/(S.length-1);return ve(ye,[0,1],[0,1])}),_=A(O,(v==null?void 0:v.scrollProgress)??0).sort((K,Z)=>K.index-Z.index);let z=(((ce=p.current)==null?void 0:ce.clientWidth)??N)+l+c[0]+l;const J=_.sort((K,Z)=>Math.abs(K.relativeIndex)-Math.abs(Z.relativeIndex)).map((K,Z)=>{if(!(z<=0)){if(Z==0&&V(K.index),K.width=ve(z-l,[c[0],c[1]],[c[0],c[1]]),z-=K.width+l,z!=0&&z<(c[0]+l)*2){const re=K.width-((c[0]+l)*2-z);z+=K.width,K.width=re,z-=K.width}else if(z==0&&K.width>=c[0]*2+l){const re=K.width-(c[0]+l-z);z+=K.width,K.width=re,z-=K.width}return K}}).filter(Boolean),D=J.reverse(),Y=[...J].sort((K,Z)=>Math.abs(K.index)-Math.abs(Z.index));D.forEach((K,Z)=>{const re=D[Z+1];if(!re)return;const ye=1-(Math.abs(K.relativeIndex)-Math.abs(re==null?void 0:re.relativeIndex)),xe=ve(ye,[0,2],[K.width+z,re.width]);z+=K.width,K.width=xe,z-=K.width});const se=J.length/2,ie=ve(Math.abs(Y[0].relativeIndex),[Y[0].index==0?0:se-1,se],[0,1]),we=ve(ie,[0,1],[0,1])*-(c[0]+l);return w(we),Object.fromEntries(J.map(K=>[K.index,K.width]))},M=i.useRef([]).current,[q,V]=i.useState(0);i.useEffect(()=>{d&&d(q)},[q]),i.useEffect(()=>{typeof f=="number"&&S.length>0&&f!==q&&C(f)},[f,S.length]),i.useEffect(()=>{W(q)},[q]),M.length!==S.length&&S.forEach((N,A)=>{M[A]||(M[A]=i.createRef())});const[Q,W]=i.useState(0),C=(N,A={})=>{if(!S.length)return 0;const O=M[N];if(!O||!O.current||!g.current)return 0;const _=ve(N/Math.max(1,S.length-1),[0,1],[0,1]);return W(N),g.current.dispatchEvent(new CustomEvent("udx:customScroll:set",{bubbles:!0,detail:{progress:_,orientation:"horizontal",animate:A.animate!==!1}})),_},R=S.map((N,A)=>{var J;const O=(J=N.props)==null?void 0:J.onClick,_=D=>{O==null||O(D)},z=()=>W(A);return i.cloneElement(N,{width:B[A],outputRange:c,ref:M[A],key:A,index:A,role:"option","aria-selected":q===A,tabIndex:q===A?0:-1,onClick:_,onFocus:z})}),H=N=>{var A;if(N.scrollTotal>0){(A=j.current)==null||A.stop();const O=F.current??0,_=N.scrollProgress??0;j.current=X.animate(O,_,{type:"spring",stiffness:260,damping:32,mass:.6,restDelta:5e-4,onUpdate:z=>{F.current=z,k({...N,scrollProgress:z})}})}};i.useEffect(()=>{const N=$();P(N)},[v]);const U=i.useRef(o);i.useEffect(()=>{U.current=o},[o]);const G=i.useRef(null);i.useEffect(()=>{var Z;const N=U.current;if(!N||!(p!=null&&p.current))return;const A=S.length;if(A<=0)return;const O=((Z=p.current)==null?void 0:Z.clientWidth)??0,_=c[1],z=F.current??(v==null?void 0:v.scrollProgress)??0,J=(O+l)/(_+l),D=Math.max(1,Math.floor(J)),Y=Math.max(1,Math.round(D*(2/3))),se=Math.min(Math.max(0,q),Math.max(0,A-1)),ie=se>0,we=se<A-1,ue={total:A,selectedIndex:se,visibleApprox:J,visibleFull:D,stepHalf:Y,canPrev:ie,canNext:we,scrollProgress:z,viewportWidth:O,itemMaxWidth:_,gap:l},ce=G.current;let K=!ce;if(!K){for(const re in ue)if(ue[re]!==ce[re]){K=!0;break}}K&&(G.current=ue,N(ue))},[p,S.length,q,v,l,c]),i.useEffect(()=>()=>{var N;(N=j.current)==null||N.stop()},[]);const[te,E]=i.useState(0);i.useLayoutEffect(()=>{let N=c[1];v&&N>v.scrollVisible&&(N=v.scrollVisible);const A=(N+l)*R.length/y;E(A)},[p,M,v]);const L=N=>{if(!S.length)return;const A=Q??q;switch(N.key){case"ArrowLeft":N.preventDefault(),C(Math.max(0,A-1));break;case"ArrowRight":N.preventDefault(),C(Math.min(S.length-1,A+1));break;case"Home":N.preventDefault(),C(0);break;case"End":N.preventDefault(),C(S.length-1);break;case"Enter":case" ":N.preventDefault(),C(A);break}};return i.useEffect(()=>{const N=p.current;if(!N)return;const A=O=>{const _=O.detail;_&&typeof _.index=="number"&&C(_.index)};return N.addEventListener("udx:carousel:centerIndex",A),()=>{N.removeEventListener("udx:carousel:centerIndex",A)}},[p,S.length]),a.jsx("div",{className:I.carousel,ref:p,role:"listbox","aria-orientation":"horizontal",onKeyDown:L,...h,children:a.jsx(it,{draggable:!0,orientation:"horizontal",onScroll:H,scrollSize:te,children:a.jsx("div",{className:I.track,ref:g,style:{gap:`${l}px`,translate:b,willChange:"translate"},children:R})})})};/*!
|
|
2
2
|
* Font Awesome Free 7.1.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 2025 Fonticons, Inc.
|
|
5
|
-
*/var ss={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"]},rs={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"]},os={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"]},is={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"]},Kt={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"]},we={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"]},ls=we,as={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"]},cs={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"]},us={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 ds=({checked:e,defaultChecked:t,indeterminate:n=!1,disabled:s=!1,error:r=!1,onChange:u,id:c,name:l,value:d,style:o,className:f,...y})=>{const h=i.useId(),m=c||h,p=e!==void 0,[b,w]=i.useState(t??!1),I=p?e:b,[S,g]=i.useState(!1),B=i.useRef(null);i.useEffect(()=>{B.current&&(B.current.indeterminate=n)},[n]);const $=k=>{s||(p||w(k.target.checked),u&&u(k))},v=mt({isChecked:!!I,isIndeterminate:n,isDisabled:s,isError:r,isFocused:S,isHovered:!1});return a.jsx("div",{className:x(v.checkbox,f,"group/checkbox"),style:o,children:a.jsxs(de,{stateClassName:v.stateLayer,colorName:I||n?"primary":"on-surface",children:[a.jsx("input",{ref:B,type:"checkbox",id:m,name:l,value:d,checked:I,disabled:s,onChange:$,onFocus:()=>g(!0),onBlur:()=>g(!1),className:v.input,...y}),a.jsx("div",{className:v.box}),a.jsx(X.AnimatePresence,{children:(I||n)&&a.jsx(X.motion.div,{initial:{opacity:0,scale:.5},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.5},transition:{duration:.15},className:v.icon,children:a.jsx(ae,{icon:n?ss:Kt,className:"size-3.5"})})})]})})},Ie=({variant:e="outlined",disabled:t=!1,icon:n,href:s,label:r,className:u,onClick:c,onToggle:l,activated:d,ref:o,onRemove:f,editable:y,onEditStart:h,onEditCommit:m,onEditCancel:p,onChange:b,transition:w,children:I,editing:S,...g})=>{if(I&&(r=I),r===void 0&&!y)throw new Error("Chip component requires either a label prop or children content");const B=s?"a":"button",$=i.useRef(null),v=o||$,[k,F]=i.useState(d),[j,P]=i.useState(!1),[M,q]=i.useState(S&&y),[V,Q]=i.useState(!1),[W,C]=i.useState(typeof r=="string"?r:""),R=i.useRef(null);i.useEffect(()=>{F(d)},[d]),i.useEffect(()=>{if(S&&q(S),y&&j){const D=setTimeout(()=>{g!=null&&g.draggable&&V||q(!0)},1e3);return()=>clearTimeout(D)}else j||q(!1)},[j,y,V,g,W]),i.useEffect(()=>{if(M){C(typeof r=="string"?r:"");const D=z.current||R.current;if(D){D.focus();const Y=document.createRange();Y.selectNodeContents(D),Y.collapse(!1);const se=window.getSelection();se==null||se.removeAllRanges(),se==null||se.addRange(Y)}}},[M]),w={duration:.3,...w};const H=D=>{t&&D.preventDefault(),l?(F(!k),l(!k)):c&&c(D)},U=!!l||!!f||!!c||!!s||!!y;d&&(n=Kt);const{onFocus:G,onBlur:te,onKeyDown:E,onDragStart:L,onDragEnd:N,onDoubleClick:A,...O}=g??{},_=yt({href:s,disabled:t,icon:n,variant:e,transition:w,className:u,isActive:k??!1,onToggle:l,activated:k,label:r,isInteractive:U,children:r,isFocused:j,isDragging:V,onEditCommit:m,isEditing:M}),z=i.useRef(null),Z=()=>{const D=(W??"").trim();if(!D){f&&f();return}m==null||m(D)};return a.jsxs(B,{contentEditable:!1,ref:v,href:s,className:_.chip,...O,onClick:D=>{M||H(D)},draggable:!t&&!!(g!=null&&g.draggable),onDragStart:D=>{!t&&(g!=null&&g.draggable)&&Q(!0),L==null||L(D)},onDragEnd:D=>{g!=null&&g.draggable&&Q(!1),N==null||N(D)},onDoubleClick:D=>{!t&&y&&!M&&(h==null||h(),D.preventDefault(),D.stopPropagation()),A==null||A(D)},onFocus:D=>{U&&P(!0),G==null||G(D)},onBlur:D=>{P(!1),te==null||te(D)},onKeyDown:D=>{const Y=D.key;if(!t&&M){Y==="Enter"?(D.preventDefault(),Z()):Y==="Escape"?(D.preventDefault(),p==null||p()):f&&(W==null?void 0:W.trim())===""&&(Y==="Backspace"||Y==="Delete"||Y==="Del")&&(D.preventDefault(),D.stopPropagation(),f());return}if(!t&&j){if(y&&!l&&(Y==="F2"||Y==="Enter")){D.preventDefault(),h==null||h();return}if(l&&(Y==="Enter"||Y===" "||Y==="Spacebar")){D.preventDefault();const se=!k;F(se),l(se)}f&&(Y==="Backspace"||Y==="Delete"||Y==="Del")&&(D.preventDefault(),D.stopPropagation(),f())}E==null||E(D)},disabled:t,"aria-pressed":l?k:void 0,style:{transition:w.duration+"s"},children:[U&&!t&&!M&&a.jsx(de,{style:{transition:w.duration+"s"},className:_.stateLayer,colorName:x({"on-surface-variant":!k,"on-secondary-container":k}),stateClassName:"state-ripple-group-[chip]"}),n&&a.jsx(ae,{icon:n,className:_.leadingIcon}),a.jsx("span",{ref:z,contentEditable:!!y&&!!M,suppressContentEditableWarning:!0,className:_.label,role:y?"textbox":void 0,spellCheck:!1,onInput:D=>{const Y=D.currentTarget.innerText;C(Y),b==null||b(Y)},onBlur:D=>{y&&M&&Z()},onKeyDown:D=>{if(y&&M&&D.key==="Enter"){D.preventDefault(),D.stopPropagation(),Z();return}y&&M&&D.key==="Escape"&&(D.preventDefault(),D.stopPropagation(),p==null||p())},children:r}),f&&!M&&a.jsx(ae,{icon:we,className:_.trailingIcon,onMouseDown:D=>{D.preventDefault(),D.stopPropagation()},onClick:D=>{D.stopPropagation(),t||f()}})]})},Pe=({orientation:e="horizontal",className:t,...n})=>{const s=wt({orientation:e,className:t});return a.jsx("hr",{className:s.divider,...n})},oe=[];for(let e=0;e<256;++e)oe.push((e+256).toString(16).slice(1));function fs(e,t=0){return(oe[e[t+0]]+oe[e[t+1]]+oe[e[t+2]]+oe[e[t+3]]+"-"+oe[e[t+4]]+oe[e[t+5]]+"-"+oe[e[t+6]]+oe[e[t+7]]+"-"+oe[e[t+8]]+oe[e[t+9]]+"-"+oe[e[t+10]]+oe[e[t+11]]+oe[e[t+12]]+oe[e[t+13]]+oe[e[t+14]]+oe[e[t+15]]).toLowerCase()}let je;const hs=new Uint8Array(16);function ms(){if(!je){if(typeof crypto>"u"||!crypto.getRandomValues)throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");je=crypto.getRandomValues.bind(crypto)}return je(hs)}const ps=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),Ue={randomUUID:ps};function Gt(e,t,n){var r;if(Ue.randomUUID&&!e)return Ue.randomUUID();e=e||{};const s=e.random??((r=e.rng)==null?void 0:r.call(e))??ms();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,fs(s)}const ys=({variant:e="input",className:t,scrollable:n=!0,draggable:s=!1,items:r,onItemsChange:u})=>{const c=r??[],l=i.useRef(null),[d,o]=i.useState(!1),f=i.useRef(new WeakMap),y=i.useCallback(v=>{const k=f.current;let F=k.get(v);return F||(F=Gt(),k.set(v,F)),F},[]);i.useEffect(()=>{var v,k;d&&(e=="input"?(v=B.current)==null||v.focus():(k=l.current)==null||k.focus())},[d]);const h=i.useRef([]),m=i.useRef(!1),p=i.useCallback(v=>{u==null||u(v(c))},[u,c]),b=i.useCallback(v=>{p(k=>k.filter((F,j)=>j!==v))},[p]),w=vt({scrollable:n,className:t,variant:e}),I=i.useCallback((v="")=>{if(e!=="input"||m.current)return;m.current=!0;const k={label:v},F=y(k),j=[...c,k];u==null||u(j),requestAnimationFrame(()=>{g(F),m.current=!1})},[e,u,c,y]),[S,g]=i.useState(null);i.useEffect(()=>{var v;if(S){const k=c.findIndex(F=>y(F)===S);if(k!==-1){const F=h.current[k];(v=F==null?void 0:F.focus)==null||v.call(F);const j=l.current,P=F.offsetLeft+F.offsetWidth/2-j.offsetWidth/2;j.scrollTo({left:P,behavior:"smooth"})}}},[S,c,y]);const B=i.useRef(null),$=(d||c.length===0)&&e==="input";return a.jsxs("div",{ref:l,role:"list","aria-label":"Chips",className:w.chips,tabIndex:e==="input"?0:void 0,onFocus:v=>{v.target===v.currentTarget&&o(!0)},onBlur:()=>{o(!1)},onKeyDown:v=>{var q;if(e!=="input")return;const k=v.key,j=v.target===v.currentTarget;if(!d)return;const P=document.activeElement,M=h.current.findIndex(V=>V===P);if(k==="ArrowLeft"){v.preventDefault();const V=M>0?M-1:c.length-1,Q=y(c[V]);g(Q);return}if(k==="ArrowRight"){v.preventDefault();const V=M>=0?(M+1)%Math.max(1,c.length):0,Q=y(c[V]);g(Q);return}if(k==="Home"){v.preventDefault();const V=y(c[0]);g(V);return}if(k==="End"){v.preventDefault();const V=y(c[c.length-1]);g(V);return}if(j&&k==="Backspace"){if(v.preventDefault(),c.length>0){const V=h.current[c.length-1];(q=V==null?void 0:V.focus)==null||q.call(V)}return}},children:[c.map((v,k)=>{const F=y(v),j=e==="input",P=j?{editable:!0,editing:S===F,onEditCommit:M=>{o(!0),p(q=>q.map((V,Q)=>Q===k?{...V,label:M}:V))},onEditCancel:()=>{o(!0)},onChange:()=>{if(h.current.length==k+1){const M=l.current;requestAnimationFrame(()=>{M.scrollTo({left:M.scrollWidth,behavior:"smooth"})})}}}:{};return a.jsx(Ie,{ref:M=>h.current[k]=M,label:v.label??"",icon:v.icon,activated:v.activated,disabled:v.disabled,variant:v.variant,href:v.href,draggable:s,...P,onToggle:v.activated===void 0?void 0:M=>p(q=>q.map((V,Q)=>Q===k?{...V,activated:M}:V)),onBlur:()=>{S===F&&g(null)},onRemove:j?()=>{o(!0),b(k)}:void 0},F)}),d&&a.jsxs(a.Fragment,{children:[a.jsx(Pe,{orientation:"vertical",className:"animate-[var(--animate-blink)] border-outline",style:{"--animate-blink":"blink 1s cubic-bezier(0.4, 0, 0.6, 1) infinite"}}),a.jsx("style",{children:`
|
|
5
|
+
*/var cs={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"]},us={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"]},ds={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"]},fs={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"]},en={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"]},Ee={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"]},hs=Ee,ms={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"]},ps={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"]},ys={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 xs=({checked:e,defaultChecked:t,indeterminate:n=!1,disabled:s=!1,error:r=!1,onChange:u,id:c,name:l,value:d,style:o,className:f,...y})=>{const h=i.useId(),m=c||h,p=e!==void 0,[b,w]=i.useState(t??!1),I=p?e:b,[S,g]=i.useState(!1),B=i.useRef(null);i.useEffect(()=>{B.current&&(B.current.indeterminate=n)},[n]);const P=k=>{s||(p||w(k.target.checked),u&&u(k))},v=gt({isChecked:!!I,isIndeterminate:n,isDisabled:s,isError:r,isFocused:S,isHovered:!1});return a.jsx("div",{className:x(v.checkbox,f,"group/checkbox"),style:o,children:a.jsxs(fe,{stateClassName:v.stateLayer,colorName:I||n?"primary":"on-surface",children:[a.jsx("input",{ref:B,type:"checkbox",id:m,name:l,value:d,checked:I,disabled:s,onChange:P,onFocus:()=>g(!0),onBlur:()=>g(!1),className:v.input,...y}),a.jsx("div",{className:v.box}),a.jsx(X.AnimatePresence,{children:(I||n)&&a.jsx(X.motion.div,{initial:{opacity:0,scale:.5},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.5},transition:{duration:.15},className:v.icon,children:a.jsx(ae,{icon:n?cs:en,className:"size-3.5"})})})]})})},Ae=({variant:e="outlined",disabled:t=!1,icon:n,href:s,label:r,className:u,onClick:c,onToggle:l,activated:d,ref:o,onRemove:f,editable:y,onEditStart:h,onEditCommit:m,onEditCancel:p,onChange:b,transition:w,children:I,editing:S,...g})=>{if(I&&(r=I),r===void 0&&!y)throw new Error("Chip component requires either a label prop or children content");const B=s?"a":"button",P=i.useRef(null),v=o||P,[k,F]=i.useState(d),[j,$]=i.useState(!1),[M,q]=i.useState(S&&y),[V,Q]=i.useState(!1),[W,C]=i.useState(typeof r=="string"?r:""),R=i.useRef(null);i.useEffect(()=>{F(d)},[d]),i.useEffect(()=>{if(S&&q(S),y&&j){const D=setTimeout(()=>{g!=null&&g.draggable&&V||q(!0)},1e3);return()=>clearTimeout(D)}else j||q(!1)},[j,y,V,g,W]),i.useEffect(()=>{if(M){C(typeof r=="string"?r:"");const D=z.current||R.current;if(D){D.focus();const Y=document.createRange();Y.selectNodeContents(D),Y.collapse(!1);const se=window.getSelection();se==null||se.removeAllRanges(),se==null||se.addRange(Y)}}},[M]),w={duration:.3,...w};const H=D=>{t&&D.preventDefault(),l?(F(!k),l(!k)):c&&c(D)},U=!!l||!!f||!!c||!!s||!!y;d&&(n=en);const{onFocus:G,onBlur:te,onKeyDown:E,onDragStart:L,onDragEnd:N,onDoubleClick:A,...O}=g??{},_=bt({href:s,disabled:t,icon:n,variant:e,transition:w,className:u,isActive:k??!1,onToggle:l,activated:k,label:r,isInteractive:U,children:r,isFocused:j,isDragging:V,onEditCommit:m,isEditing:M}),z=i.useRef(null),J=()=>{const D=(W??"").trim();if(!D){f&&f();return}m==null||m(D)};return a.jsxs(B,{contentEditable:!1,ref:v,href:s,className:_.chip,...O,onClick:D=>{M||H(D)},draggable:!t&&!!(g!=null&&g.draggable),onDragStart:D=>{!t&&(g!=null&&g.draggable)&&Q(!0),L==null||L(D)},onDragEnd:D=>{g!=null&&g.draggable&&Q(!1),N==null||N(D)},onDoubleClick:D=>{!t&&y&&!M&&(h==null||h(),D.preventDefault(),D.stopPropagation()),A==null||A(D)},onFocus:D=>{U&&$(!0),G==null||G(D)},onBlur:D=>{$(!1),te==null||te(D)},onKeyDown:D=>{const Y=D.key;if(!t&&M){Y==="Enter"?(D.preventDefault(),J()):Y==="Escape"?(D.preventDefault(),p==null||p()):f&&(W==null?void 0:W.trim())===""&&(Y==="Backspace"||Y==="Delete"||Y==="Del")&&(D.preventDefault(),D.stopPropagation(),f());return}if(!t&&j){if(y&&!l&&(Y==="F2"||Y==="Enter")){D.preventDefault(),h==null||h();return}if(l&&(Y==="Enter"||Y===" "||Y==="Spacebar")){D.preventDefault();const se=!k;F(se),l(se)}f&&(Y==="Backspace"||Y==="Delete"||Y==="Del")&&(D.preventDefault(),D.stopPropagation(),f())}E==null||E(D)},disabled:t,"aria-pressed":l?k:void 0,style:{transition:w.duration+"s"},children:[U&&!t&&!M&&a.jsx(fe,{style:{transition:w.duration+"s"},className:_.stateLayer,colorName:x({"on-surface-variant":!k,"on-secondary-container":k}),stateClassName:"state-ripple-group-[chip]"}),n&&a.jsx(ae,{icon:n,className:_.leadingIcon}),a.jsx("span",{ref:z,contentEditable:!!y&&!!M,suppressContentEditableWarning:!0,className:_.label,role:y?"textbox":void 0,spellCheck:!1,onInput:D=>{const Y=D.currentTarget.innerText;C(Y),b==null||b(Y)},onBlur:D=>{y&&M&&J()},onKeyDown:D=>{if(y&&M&&D.key==="Enter"){D.preventDefault(),D.stopPropagation(),J();return}y&&M&&D.key==="Escape"&&(D.preventDefault(),D.stopPropagation(),p==null||p())},children:r}),f&&!M&&a.jsx(ae,{icon:Ee,className:_.trailingIcon,onMouseDown:D=>{D.preventDefault(),D.stopPropagation()},onClick:D=>{D.stopPropagation(),t||f()}})]})},Oe=({orientation:e="horizontal",className:t,...n})=>{const s=kt({orientation:e,className:t});return a.jsx("hr",{className:s.divider,...n})},oe=[];for(let e=0;e<256;++e)oe.push((e+256).toString(16).slice(1));function vs(e,t=0){return(oe[e[t+0]]+oe[e[t+1]]+oe[e[t+2]]+oe[e[t+3]]+"-"+oe[e[t+4]]+oe[e[t+5]]+"-"+oe[e[t+6]]+oe[e[t+7]]+"-"+oe[e[t+8]]+oe[e[t+9]]+"-"+oe[e[t+10]]+oe[e[t+11]]+oe[e[t+12]]+oe[e[t+13]]+oe[e[t+14]]+oe[e[t+15]]).toLowerCase()}let De;const gs=new Uint8Array(16);function ws(){if(!De){if(typeof crypto>"u"||!crypto.getRandomValues)throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");De=crypto.getRandomValues.bind(crypto)}return De(gs)}const bs=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),Qe={randomUUID:bs};function tn(e,t,n){var r;if(Qe.randomUUID&&!e)return Qe.randomUUID();e=e||{};const s=e.random??((r=e.rng)==null?void 0:r.call(e))??ws();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,vs(s)}const Ss=({variant:e="input",className:t,scrollable:n=!0,draggable:s=!1,items:r,onItemsChange:u})=>{const c=r??[],l=i.useRef(null),[d,o]=i.useState(!1),f=i.useRef(new WeakMap),y=i.useCallback(v=>{const k=f.current;let F=k.get(v);return F||(F=tn(),k.set(v,F)),F},[]);i.useEffect(()=>{var v,k;d&&(e=="input"?(v=B.current)==null||v.focus():(k=l.current)==null||k.focus())},[d]);const h=i.useRef([]),m=i.useRef(!1),p=i.useCallback(v=>{u==null||u(v(c))},[u,c]),b=i.useCallback(v=>{p(k=>k.filter((F,j)=>j!==v))},[p]),w=Nt({scrollable:n,className:t,variant:e}),I=i.useCallback((v="")=>{if(e!=="input"||m.current)return;m.current=!0;const k={label:v},F=y(k),j=[...c,k];u==null||u(j),requestAnimationFrame(()=>{g(F),m.current=!1})},[e,u,c,y]),[S,g]=i.useState(null);i.useEffect(()=>{var v;if(S){const k=c.findIndex(F=>y(F)===S);if(k!==-1){const F=h.current[k];(v=F==null?void 0:F.focus)==null||v.call(F);const j=l.current,$=F.offsetLeft+F.offsetWidth/2-j.offsetWidth/2;j.scrollTo({left:$,behavior:"smooth"})}}},[S,c,y]);const B=i.useRef(null),P=(d||c.length===0)&&e==="input";return a.jsxs("div",{ref:l,role:"list","aria-label":"Chips",className:w.chips,tabIndex:e==="input"?0:void 0,onFocus:v=>{v.target===v.currentTarget&&o(!0)},onBlur:()=>{o(!1)},onKeyDown:v=>{var q;if(e!=="input")return;const k=v.key,j=v.target===v.currentTarget;if(!d)return;const $=document.activeElement,M=h.current.findIndex(V=>V===$);if(k==="ArrowLeft"){v.preventDefault();const V=M>0?M-1:c.length-1,Q=y(c[V]);g(Q);return}if(k==="ArrowRight"){v.preventDefault();const V=M>=0?(M+1)%Math.max(1,c.length):0,Q=y(c[V]);g(Q);return}if(k==="Home"){v.preventDefault();const V=y(c[0]);g(V);return}if(k==="End"){v.preventDefault();const V=y(c[c.length-1]);g(V);return}if(j&&k==="Backspace"){if(v.preventDefault(),c.length>0){const V=h.current[c.length-1];(q=V==null?void 0:V.focus)==null||q.call(V)}return}},children:[c.map((v,k)=>{const F=y(v),j=e==="input",$=j?{editable:!0,editing:S===F,onEditCommit:M=>{o(!0),p(q=>q.map((V,Q)=>Q===k?{...V,label:M}:V))},onEditCancel:()=>{o(!0)},onChange:()=>{if(h.current.length==k+1){const M=l.current;requestAnimationFrame(()=>{M.scrollTo({left:M.scrollWidth,behavior:"smooth"})})}}}:{};return a.jsx(Ae,{ref:M=>h.current[k]=M,label:v.label??"",icon:v.icon,activated:v.activated,disabled:v.disabled,variant:v.variant,href:v.href,draggable:s,...$,onToggle:v.activated===void 0?void 0:M=>p(q=>q.map((V,Q)=>Q===k?{...V,activated:M}:V)),onBlur:()=>{S===F&&g(null)},onRemove:j?()=>{o(!0),b(k)}:void 0},F)}),d&&a.jsxs(a.Fragment,{children:[a.jsx(Oe,{orientation:"vertical",className:"animate-[var(--animate-blink)] border-outline",style:{"--animate-blink":"blink 1s cubic-bezier(0.4, 0, 0.6, 1) infinite"}}),a.jsx("style",{children:`
|
|
6
6
|
@keyframes blink {
|
|
7
7
|
0%, 50% { opacity: 1; }
|
|
8
8
|
50.01%, 100% { opacity: 0; }
|
|
9
9
|
}
|
|
10
|
-
`})]}),$&&a.jsx(Ie,{ref:B,className:"opacity-0",draggable:s,editable:!0,editing:!0,onChange:v=>{var k;if(v=v.replace(/( )+/g," ").trim(),console.log("Ghost chip onChange",v,!!v),v)I(v);else if(c.length>0){const F=h.current[c.length-1];(k=F==null?void 0:F.focus)==null||k.call(F)}},onEditCommit:()=>{},onBlur:()=>{o(!1)},onFocus:v=>{o(!0),v.stopPropagation()},children:" "})]})};function Jt({trigger:e=["hover","focus"],isOpen:t,defaultOpen:n=!1,onOpenChange:s,openDelay:r=400,closeDelay:u=150,id:c}={}){const l=i.useId(),d=c??`tooltip-${l}`,o=Array.isArray(e)?e:[e],f=typeof t=="boolean",[y,h]=i.useState(n?"hovered":"hidden"),[m,p]=i.useState(!1),b=i.useRef(null),w=i.useRef(null),I=i.useCallback(()=>{b.current&&(clearTimeout(b.current),b.current=null),w.current&&(clearTimeout(w.current),w.current=null)},[]);i.useEffect(()=>()=>I(),[I]);const S=i.useCallback(C=>{if(f){const R=C!=="hidden";s==null||s(R)}else{h(C);const R=C!=="hidden";s==null||s(R)}},[f,s]),g=f?t?"hovered":"hidden":y,B=g!=="hidden",$=C=>{switch(C){case"hidden":return 0;case"hovered":return 1;case"focused":return 2;case"clicked":return 3;default:return 0}},v=i.useCallback(C=>{I(),!($(C)<=$(g))&&(b.current=setTimeout(()=>{S(C)},r))},[I,r,g,S]),k=i.useCallback(C=>{I(),w.current=setTimeout(()=>{(!f&&$(y)<=$(C)||f)&&S("hidden")},u)},[I,u,y,f,S]),F=i.useCallback(()=>{o.includes("hover")&&v("hovered")},[o,v]),j=i.useCallback(()=>{o.includes("hover")&&(g==="focused"||g==="clicked"||m||k("hovered"))},[o,g,m,k]),P=i.useCallback(()=>{o.includes("focus")&&(I(),S("focused"))},[o,I,S]),M=i.useCallback(()=>{if(o.includes("focus")&&g!=="clicked"){if(o.includes("hover")&&m){S("hovered");return}k("focused")}},[o,g,m,k,S]),q=i.useCallback(()=>{o.includes("click")&&(I(),S(g==="clicked"?"hidden":"clicked"))},[o,g,I,S]),V=i.useCallback(C=>{C.key==="Escape"&&B&&(I(),S("hidden"),C.preventDefault())},[B,I,S]),Q=i.useCallback(()=>{p(!0),I()},[I]),W=i.useCallback(()=>{p(!1),o.includes("hover")&&g==="hovered"&&k("hovered")},[o,g,k]);return{triggerProps:{"aria-describedby":B?d:void 0,onMouseEnter:F,onMouseLeave:j,onFocus:P,onBlur:M,onClick:q,onKeyDown:V},tooltipProps:{id:d,role:"tooltip","aria-hidden":!B,onMouseEnter:Q,onMouseLeave:W},isOpen:B,state:g}}const We=({variant:e="plain",buttons:t,className:n,children:s,title:r,text:u,content:c,position:l,targetRef:d,ref:o,trigger:f=["hover","focus"],transition:y,openDelay:h=400,closeDelay:m=150,isOpen:p,defaultOpen:b=!1,onOpenChange:w,id:I,anchorRef:S,...g})=>{const $=l||(e==="rich"?"bottom-right":"bottom");if(y={duration:.3,...y},!s&&!d)throw new Error("Tooltip must have a child or a targetRef");t&&!Array.isArray(t)&&(t=[t]);const v=i.useRef(null),F=S||(d||v),{triggerProps:j,tooltipProps:P,isOpen:M}=Jt({trigger:f,isOpen:p,defaultOpen:b,onOpenChange:w,openDelay:h,closeDelay:m,id:I}),q=!d&&i.isValidElement(s)?i.cloneElement(s,{ref:v,...j,onMouseEnter:W=>{var C,R;j.onMouseEnter(),(R=(C=s.props)==null?void 0:C.onMouseEnter)==null||R.call(C,W)},onMouseLeave:W=>{var C,R;j.onMouseLeave(),(R=(C=s.props)==null?void 0:C.onMouseLeave)==null||R.call(C,W)},onFocus:W=>{var C,R;j.onFocus(),(R=(C=s.props)==null?void 0:C.onFocus)==null||R.call(C,W)},onBlur:W=>{var C,R;j.onBlur(),(R=(C=s.props)==null?void 0:C.onBlur)==null||R.call(C,W)},onClick:W=>{var C,R;j.onClick(),(R=(C=s.props)==null?void 0:C.onClick)==null||R.call(C,W)},onKeyDown:W=>{var C,R;j.onKeyDown(W),(R=(C=s.props)==null?void 0:C.onKeyDown)==null||R.call(C,W)}}):s;i.useEffect(()=>{if(!d)return;const W=d.current;if(!W)return;const C=()=>j.onMouseEnter(),R=()=>j.onMouseLeave(),H=()=>j.onFocus(),U=()=>j.onBlur(),G=()=>j.onClick(),te=E=>j.onKeyDown(E);return W.addEventListener("mouseenter",C),W.addEventListener("mouseleave",R),W.addEventListener("focus",H,!0),W.addEventListener("blur",U,!0),W.addEventListener("click",G),W.addEventListener("keydown",te),j["aria-describedby"]?W.setAttribute("aria-describedby",j["aria-describedby"]):W.removeAttribute("aria-describedby"),()=>{W.removeEventListener("mouseenter",C),W.removeEventListener("mouseleave",R),W.removeEventListener("focus",H,!0),W.removeEventListener("blur",U,!0),W.removeEventListener("click",G),W.removeEventListener("keydown",te)}},[d,j]);const V=qt({variant:e,buttons:t,className:n,title:r,text:u,position:$,trigger:f,targetRef:d,children:s}),Q={open:{opacity:1,height:"auto"},close:{opacity:0,height:16}};return a.jsxs(a.Fragment,{children:[q,a.jsx(X.AnimatePresence,{children:M&&a.jsx(De,{anchorRef:F,position:$,children:a.jsx(X.motion.div,{initial:"close",variants:Q,animate:"open",transition:{duration:y.duration},exit:"close",className:V.toolTip,...g,...P,children:a.jsx("div",{className:V.container,children:c?a.jsx("div",{className:V.content,children:c}):a.jsxs(a.Fragment,{children:[r&&a.jsx("div",{className:V.subHead,children:r}),u&&a.jsx("div",{className:V.supportingText,children:u}),t&&a.jsx("div",{className:V.actions,children:Array.isArray(t)&&t.map((W,C)=>a.jsx(me,{size:"small",variant:"text",...W},C))})]})})})})})]})},Ne=({className:e,label:t,variant:n="primary",size:s="medium",href:r,type:u,icon:c,extended:l=!1,ref:d,transition:o,children:f,...y})=>{if(f&&(t=f),!t)throw new Error("FAB component requires either a label prop or children content");const h=r?"a":"button",m=St({href:r,icon:c,extended:l,label:t,size:s,variant:n,className:e,transition:o,children:t});o={duration:.3,...o};const p=i.useRef(null),b=d||p,w={visible:{width:"auto",marginLeft:12,opacity:1,transition:{...o,opacity:{duration:o.duration/2,delay:o.duration-o.duration/2}}},hidden:{width:0,marginLeft:0,opacity:0,transition:{...o,marginLeft:{duration:o.duration/2,delay:o.duration-o.duration/2}}}};return a.jsxs(h,{...y,ref:b,href:r,"aria-label":l?void 0:t,className:m.fab,children:[a.jsx(We,{trigger:l?null:void 0,text:t,targetRef:b}),a.jsx(de,{style:{transition:o.duration+"s"},className:m.stateLayer,colorName:x({"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]"}),a.jsx(ae,{icon:c,className:m.icon}),a.jsx(X.AnimatePresence,{children:l&&a.jsx(X.motion.span,{variants:w,initial:"hidden",animate:"visible",exit:"hidden",className:m.label,children:t})})]})},ve=({variant:e="standard",href:t,disabled:n=!1,title:s,label:r,onToggle:u,activated:c=!1,onClick:l,icon:d,size:o="medium",iconSelected:f,className:y,ref:h,width:m="default",shape:p="rounded",allowShapeTransformation:b=!0,transition:w,children:I,...S})=>{if(I&&(r=I),!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,B]=i.useState(c),$=P=>{n&&P.preventDefault(),u?(B(!g),u(!g)):l&&l(P)};i.useEffect(()=>{B(c)},[c]);const v=t?"a":"button",k=Lt({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:y,size:o,children:r,...S}),F=i.useRef(null),j=h||F;return w={duration:.3,...w},a.jsxs(v,{disabled:n,href:t,style:{transition:w.duration+"s"},className:k.iconButton,"aria-label":r,...S,title:void 0,onClick:$,ref:j,children:[s!==null&&a.jsx(We,{targetRef:j,trigger:n?null:void 0,text:s}),a.jsx("div",{className:k.touchTarget}),a.jsx(de,{style:{transition:w.duration+"s"},className:k.stateLayer,colorName:x(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?a.jsx(ae,{icon:d,className:k.icon}):I]})},xs=({className:e,label:t,variant:n="primary",size:s="medium",href:r,icon:u,extended:c=!1,ref:l,transition:d,children:o,open:f,defaultOpen:y=!1,onOpenChange:h,...m})=>{d={duration:.3,ease:"easeInOut",...d};const p=i.useRef(null),b=l||p,w=typeof f=="boolean",[I,S]=i.useState(y),g=w?f:I,B=M=>{w||S(M),h==null||h(M)},$=i.Children.toArray(o).filter(M=>i.isValidElement(M)&&M.type===me),v=Et({href:r,icon:u,extended:c,label:t,size:s,variant:n,className:e,transition:d,children:t,open:g}),k=X.motion.create(Ne),F=X.motion.create(ve),j=M=>a.jsx(k,{icon:u,extended:c,label:t,variant:n+"Container",size:s,className:v.fab+" "+(e??""),"aria-expanded":g,onClick:()=>B(!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},...M}),P=i.useId();return a.jsxs("div",{className:v.fabMenu,ref:b,...m,children:[a.jsx(X.AnimatePresence,{children:g&&a.jsx("div",{className:v.actions,role:"menu","aria-hidden":!g,children:(()=>{const M=$.length;return $.map((q,V)=>{q.props;const Q=M-1-V,W=((d==null?void 0:d.delay)??0)+Q*.06,C={open:{overflow:"visible",opacity:1,width:"auto",transition:{...d,delay:W,opacity:{delay:(d==null?void 0:d.duration)/2+W}}},close:{overflow:"hidden",opacity:0,width:0,transition:{...d,delay:W,opacity:{duration:(d==null?void 0:d.duration)/1.5}}}};return a.jsx(X.motion.div,{initial:"close",animate:"open",variants:C,transition:d,exit:"close",children:i.cloneElement(q,{key:V,shape:"rounded",variant:"filled",className:()=>({button:x("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:x({"state-on-primary-container":n==="primary","state-on-secondary-container":n==="secondary","state-on-tertiary-container":n==="tertiary"})})})})})})()})}),j({className:"invisible pointer-events-none"}),a.jsxs("div",{className:"absolute right-0 top-0",children:[!g&&j({className:"",layout:!0,layoutId:"fab-menu"+P}),g&&a.jsx(a.Fragment,{children:a.jsx(F,{layout:!0,layoutId:"fab-menu"+P,variant:"filled",className:()=>({iconButton:x({"bg-primary text-on-primary":n==="primary","bg-secondary text-on-secondary":n==="secondary","bg-tertiary text-on-tertiary":n==="tertiary"}),stateLayer:x({"[--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:ls,onClick:()=>B(!1),children:"Close"})})]})]})},vs=({className:e,valueFormatter:t,step:n=10,name:s,value:r=0,min:u=0,max:c=100,marks:l=[{value:0,label:"0"},{value:100,label:"100"}],ref:d,onChange:o,...f})=>{const y=R=>{const H=m(),U=h();return R===1/0?100:R===-1/0?0:(R-H)/(U-H)*100},h=(R=!1)=>R?c:c==1/0?l[(l==null?void 0:l.length)-1].value:c,m=(R=!1)=>R?u:u==-1/0?l[0].value:u,p=R=>{const H=m(!1);return(h(!1)-H)*R/100+H},[b,w]=i.useState(!1),I=i.useRef(null),S=d||I,[g,B]=i.useState(r),[$,v]=i.useState(y(r)),[k,F]=i.useState(!1);i.useEffect(()=>{B(r),v(y(r))},[r]);const j=R=>{F(!0),w(!0),q(R)},P=()=>{F(!1),w(!1)};i.useEffect(()=>(k?(window.addEventListener("mouseup",P),window.addEventListener("mousemove",q),window.addEventListener("touchend",P),window.addEventListener("touchmove",q)):(window.removeEventListener("mouseup",P),window.removeEventListener("mousemove",q),window.removeEventListener("touchend",P),window.removeEventListener("touchmove",q)),()=>{window.removeEventListener("mouseup",P),window.removeEventListener("mousemove",q),window.removeEventListener("touchend",P),window.removeEventListener("touchmove",q)}),[k]);const M=Ct({className:e,isChanging:b,marks:l,max:c,min:u,name:s,step:n,value:g,valueFormatter:t,onChange:o}),q=R=>{const H=S==null?void 0:S.current;if(H){const U=H.getBoundingClientRect().left,te=((R.type==="touchmove"||R.type==="touchstart"?R.touches[0].clientX:R.clientX)-U)/H.offsetWidth*100;V({percent:te})}},V=({percent:R,value:H})=>{if(R){if(R>=100){B(h(!0)),v(100);return}if(R<=0){B(m(!0)),v(0);return}H=p(R),H==m()&&(H=m(!0)),H==h()&&(H=h(!0))}else if(H!=null){if(H>=h()){B(h(!0)),v(100);return}if(H<=m()){B(m(!0)),v(0);return}R=y(H)}else return;n!=null?H=Math.round((H-m())/n)*n+m():l&&(H=l.reduce((U,G,te)=>{let E=G.value===1/0?h():G.value===-1/0?m():G.value,L=U.value===1/0?h():U.value===-1/0?m():U.value;return E=Math.abs(E-H),L=Math.abs(L-H),E<L?G:U}).value),H>=h()&&(H=h(!0)),H<=m()&&(H=m(!0)),R=y(H),B(H),v(R),o&&o(H)},[Q,W]=i.useState(0);i.useEffect(()=>{const R=()=>{S.current&&W(S.current.offsetWidth)};return R(),window.addEventListener("resize",R),()=>{window.removeEventListener("resize",R)}},[]);const C=R=>{switch(R.key){case"ArrowRight":if(n)V({value:g+n});else if(l){const H=l.find(U=>U.value>g);H&&V({value:H.value})}break;case"ArrowLeft":if(n)V({value:g-n});else if(l){const H=l.slice(0).reverse().find((U,G,te)=>g===1/0?G===1:U.value<g);H&&V({value:H.value})}break;default:return}};return a.jsxs("div",{tabIndex:0,onKeyDown:C,role:"slider","aria-valuemin":m(!0),"aria-valuemax":h(!0),"aria-valuenow":g,"aria-valuetext":g.toString(),className:M.slider,onMouseDown:j,onClick:q,ref:S,onTouchStart:j,onDragStart:R=>R.preventDefault(),...f,children:[a.jsx("input",{type:"hidden",name:s,value:g}),a.jsx("div",{className:M.activeTrack,style:{flex:$/100}}),a.jsx("div",{className:M.handle,children:a.jsx(X.AnimatePresence,{children:b&&a.jsx(X.motion.div,{className:M.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})})}),a.jsx("div",{className:M.inactiveTrack,style:{flex:1-$/100}}),a.jsx("div",{className:"w-[calc(100%-12px)] h-full absolute -translate-x-1/2 transform left-1/2",children:l&&l.map((R,H)=>{let U=null;const G=(b?9:10)/Q*100,te=y(R.value);return te<=$-G?U=!0:te>=$+G&&(U=!1),a.jsx("div",{className:x(M.dot,{"bg-primary-container":U!=null&&U,"bg-primary":U!=null&&!U}),style:{left:`${y(R.value)}%`}},H)})})]})},gs=({variant:e="standard",className:t,children:n,title:s,position:r="right",extended:u,divider:c,onExtendedChange:l,closeIcon:d=we,transition:o,...f})=>{o={duration:.3,...o};const[y,h]=i.useState(u??!0),m=Mt({transition:o,title:s,position:r,closeIcon:d,className:t,children:n,onExtendedChange:l,divider:c,isExtended:y,extended:y,variant:e});i.useEffect(()=>{l==null||l(y??!1)},[y]),i.useEffect(()=>{u!=null&&h(u)},[u]);const p={close:{width:0},open:{width:"auto"}},b=()=>a.jsxs(a.Fragment,{children:[a.jsx(X.AnimatePresence,{children:e=="modal"&&y&&a.jsx(X.motion.div,{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:o,onClick:()=>h(!1),className:m.overlay})}),a.jsx(X.AnimatePresence,{children:y&&a.jsxs("div",{...f,className:m.sideSheet,style:{transition:o.duration+"s"},children:[a.jsxs(X.motion.div,{variants:p,initial:u===!1?"open":"close",animate:"open",exit:"close",className:m.container,children:[a.jsxs("div",{className:m.header,children:[s&&a.jsx("p",{className:m.title,children:s}),a.jsx(ve,{size:"small",label:"close",icon:d,onClick:()=>h(!1),className:m.closeButton})]}),a.jsx("div",{className:m.content,style:{transition:o.duration+"s"},children:n})]}),(c==null&&e=="standard"?!0:c)&&a.jsx(Pe,{className:m.divider,orientation:"vertical"})]})})]});return e=="modal"?Me.createPortal(b(),document.body):b()},ws=({message:e,className:t,duration:n,closeIcon:s=we,onClose:r,...u})=>{const[c,l]=i.useState(!0),d=Dt({className:t,closeIcon:s,duration:n,isVisible:c,onClose:r,message:e});i.useEffect(()=>{n&&setTimeout(()=>{o()},n)},[n]);const o=()=>{l(!1),r==null||r()};return a.jsx(X.AnimatePresence,{children:c&&a.jsx(X.motion.div,{initial:{height:0},animate:{height:"auto"},exit:{height:0},transition:{duration:.1},className:d.snackbar,...u,children:a.jsxs("div",{className:d.container,children:[a.jsx("p",{className:d.supportingText,children:e}),a.jsx(ve,{onClick:()=>o(),className:d.icon,icon:s,label:"close the snackbar"})]})})})},bs=({selected:e=!1,className:t,activeIcon:n,disabled:s=!1,inactiveIcon:r,onChange:u,onClick:c,onKeyDown:l,ref:d,...o})=>{const[f,y]=i.useState(e);i.useEffect(()=>{y(e)},[e]);const h=S=>{s||(p(),c&&c(S))},m=S=>{s||((S.key===" "||S.key==="Enter")&&(S.preventDefault(),p()),l&&l(S))},p=()=>{y(!f),u==null||u(!f)},b=Ft({className:t,isSelected:f,activeIcon:n,inactiveIcon:r,disabled:s,selected:f,onChange:u}),w=i.useRef(null),I=d||w;return a.jsxs(X.motion.div,{role:"switch","aria-checked":f,tabIndex:s?-1:0,onKeyDown:m,onClick:h,ref:I,className:b.switch,...o,children:[a.jsx("input",{type:"hidden",value:f?"1":"0"}),a.jsxs(X.motion.div,{layout:!0,style:{translate:f?"50%":"-50%"},transition:{type:"spring",stiffness:700,damping:30},className:b.handleContainer,children:[a.jsx("div",{className:b.handle,children:(f?n:r)&&a.jsx(ae,{className:b.icon,icon:f?n:r})}),a.jsx("div",{className:b.handleStateLayer})]})]})},Zt=({className:e,onClick:t,label:n,variant:s="primary",href:r,icon:u,selectedTab:c,setSelectedTab:l,tabsId:d,index:o,onTabSelected:f,scrollable:y=!1,selected:h=!1,children:m,ref:p,...b})=>{const w=i.useRef(null),I=p||w,S=n??(typeof m=="string"?m:void 0),[g,B]=i.useState(h);i.useEffect(()=>{h&&c==null?B(!0):B(c==o&&o!=null)},[c]),i.useEffect(()=>{c==o&&f&&f({ref:I,index:o||0,label:S,icon:u})},[c]);const $=r?"a":"button",v=F=>{l&&l(o??null),t&&t(F)},k=Pt({className:e,onTabSelected:f,scrollable:y,selectedTab:c,index:o,tabsId:d,selected:g,variant:s,icon:u,label:S,isSelected:g,setSelectedTab:l,href:r});return a.jsxs($,{...b,role:"tab","aria-selected":g,ref:I,href:r,className:k.tab,onClick:v,...b,children:[a.jsx(de,{style:{transition:.3+"s"},className:k.stateLayer,colorName:s==="primary"&&g?"primary":"on-surface",stateClassName:"state-ripple-group-[tab]"}),a.jsxs("span",{className:k.content,children:[u&&a.jsx(ae,{icon:u,className:k.icon}),a.jsx("span",{className:k.label,children:S}),g&&a.jsx(X.motion.span,{layoutId:`underline-${d}`,className:k.underline,transition:{duration:.3}})]})]})},Te=i.createContext(null),Ss=({variant:e="primary",onTabSelected:t,children:n,className:s,selectedTab:r,setSelectedTab:u,scrollable:c=!1})=>{const l=i.useContext(Te),[d,o]=i.useState(null);let f;r===0||r!=null?f=r:l?f=l.selectedTab:f=d;const y=u??(l==null?void 0:l.setSelectedTab)??o,h=i.Children.toArray(n).filter(I=>i.isValidElement(I)&&I.type===Zt),m=i.useRef(null),p=I=>{if(t==null||t(I),c){const S=m.current,g=I.ref.current;if(S&&g){const B=g.offsetLeft+g.offsetWidth/2-S.offsetWidth/2;S.scrollTo({left:B,behavior:"smooth"})}}},b=i.useMemo(()=>(l==null?void 0:l.tabsId)??Gt(),[l==null?void 0:l.tabsId]),w=Tt({children:n,onTabSelected:t,scrollable:c,selectedTab:f,setSelectedTab:y,className:s,variant:e});return a.jsx("div",{ref:m,role:"tablist",className:w.tabs,children:h.map((I,S)=>i.cloneElement(I,{key:S,index:S,variant:e,selectedTab:f,setSelectedTab:y,tabsId:b,onTabSelected:p,scrollable:c}))})},Ns=({children:e,selectedTab:t,setSelectedTab:n,defaultTab:s=0})=>{const[r,u]=i.useState(s),c=i.useRef(null),l=t!==void 0?t:r,d=n??u,o=c.current!==null&&l!==null?l>c.current?1:-1:0;l!==c.current&&(c.current=l);const f=i.useId(),y=i.useMemo(()=>({selectedTab:l,setSelectedTab:d,previousTab:c.current,direction:o,tabsId:f}),[l,d,o,f]);return a.jsx(Te.Provider,{value:y,children:e})},Qt=({children:e,className:t,isSelected:n=!1})=>{const s=Vt({children:e,className:t,isSelected:n});return a.jsx("div",{className:s.tabPanel,children:e})},Es=({children:e,className:t})=>{const n=i.useContext(Te);if(!n)return console.warn("TabPanels must be used within a TabGroup"),null;const{selectedTab:s,direction:r,tabsId:u}=n,c=i.Children.toArray(e).filter(d=>i.isValidElement(d)&&d.type===Qt),l=Ht({children:e,className:t});return a.jsx("div",{className:l.tabPanels,children:a.jsx(X.AnimatePresence,{initial:!1,custom:r,mode:"popLayout",children:c.map((d,o)=>s===o&&a.jsx(X.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}-${o}`,children:i.cloneElement(d,{isSelected:!0})},o))})})},ks=({hasSelected:e})=>({datePicker:x("inline-flex flex-col bg-surface-container-high rounded-[28px] p-3 select-none","min-w-[320px]"),header:x("flex items-center justify-between h-12 mb-2 px-2"),monthNav:x("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:x("text-label-large text-on-surface font-bold capitalize"),weekDays:x("grid grid-cols-7 mb-2"),weekDay:x("h-10 flex items-center justify-center text-body-small text-on-surface-variant"),daysGrid:x("grid grid-cols-7 row-auto gap-y-2"),dayCell:x("flex items-center justify-center h-10 p-0 relative"),dayButton:x("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")}),Ls=ee("datePicker",ks),en=({value:e,defaultValue:t,onChange:n,minDate:s,maxDate:r,shouldDisableDate:u,locale:c="default",weekStartDay:l=0,className:d,style:o,mode:f="single",...y})=>{const[h,m]=i.useState(()=>{const E=N=>N instanceof Date?N:Array.isArray(N)&&N[0]?N[0]:null,L=E(e)||E(t)||new Date;return new Date(L.getFullYear(),L.getMonth(),1)}),[p,b]=i.useState(0),[w,I]=i.useState("day"),S=e!==void 0,[g,B]=i.useState(t||null),$=S?e||null:g,v=(E,L)=>new Date(E,L+1,0).getDate(),k=i.useMemo(()=>{const E=h.getFullYear(),L=h.getMonth(),N=v(E,L),O=(new Date(E,L,1).getDay()-l+7)%7,_=[],z=v(E,L-1);for(let Y=O-1;Y>=0;Y--)_.push({date:new Date(E,L-1,z-Y),isCurrentMonth:!1});for(let Y=1;Y<=N;Y++)_.push({date:new Date(E,L,Y),isCurrentMonth:!0});const D=42-_.length;for(let Y=1;Y<=D;Y++)_.push({date:new Date(E,L+1,Y),isCurrentMonth:!1});return _},[h,l]),F=i.useMemo(()=>{const E=new Date().getFullYear(),L=E-100,N=E+100,A=[];for(let O=L;O<=N;O++)A.push(O);return A},[]),j=i.useRef(null);i.useEffect(()=>{if(w==="year"&&j.current){const E=j.current.querySelector('[data-selected="true"]');E&&E.scrollIntoView({block:"center"})}},[w]);const P=i.useMemo(()=>new Intl.DateTimeFormat(c,{month:"long",year:"numeric"}),[c]),M=i.useMemo(()=>new Intl.DateTimeFormat(c,{weekday:"narrow"}),[c]),q=i.useMemo(()=>{const E=new Date(2023,0,1+l);return Array.from({length:7}).map((L,N)=>{const A=new Date(E);return A.setDate(E.getDate()+N),M.format(A).charAt(0).toUpperCase()})},[M,l]),V=()=>{b(-1),m(E=>new Date(E.getFullYear(),E.getMonth()-1,1))},Q=()=>{b(1),m(E=>new Date(E.getFullYear(),E.getMonth()+1,1))},W=E=>{m(L=>new Date(E,L.getMonth(),1)),I("day")},C=(E,L)=>E?E.getDate()===L.getDate()&&E.getMonth()===L.getMonth()&&E.getFullYear()===L.getFullYear():!1,R=E=>C(new Date,E),H=E=>{let L=E;if(f==="single")L=E;else{const N=$,[A,O]=Array.isArray(N)?N:[null,null];!A||A&&O?L=[E,null]:E<A?L=[E,A]:L=[A,E]}S||B(L),n&&n(L)},U=E=>{if(f==="single")return{isSelected:C($,E),isStart:!1,isEnd:!1,isInRange:!1};const L=Array.isArray($)?$:[$,null],[N,A]=L,O=C(N,E),_=C(A,E);let z=!1;if(N&&A){const Z=new Date(N.getFullYear(),N.getMonth(),N.getDate()).getTime(),D=new Date(A.getFullYear(),A.getMonth(),A.getDate()).getTime(),Y=new Date(E.getFullYear(),E.getMonth(),E.getDate()).getTime();z=Y>Z&&Y<D}return{isSelected:O||_,isStart:O,isEnd:_,isInRange:z}},G=Ls({hasSelected:!!$}),te={enter:E=>({x:E>0?"100%":"-100%",opacity:0}),center:{x:0,opacity:1},exit:E=>({x:E<0?"100%":"-100%",opacity:0})};return a.jsxs("div",{className:x(G.datePicker,d),style:o,...y,children:[a.jsxs("div",{className:G.header,children:[a.jsxs(me,{variant:"text",disableTextMargins:!0,size:"small",onClick:()=>I(E=>E==="day"?"year":"day"),className:"text-label-large font-bold capitalize text-on-surface hover:bg-surface-container-highest",children:[a.jsx("span",{className:"mr-2",children:w==="day"?P.format(h):h.getFullYear()}),a.jsx(ae,{icon:as,className:x("w-3 h-3 transition-transform duration-200 inline",w==="year"&&"rotate-180")})]}),w==="day"&&a.jsxs("div",{className:"flex items-center",children:[a.jsx(ve,{size:"xSmall",allowShapeTransformation:!1,onClick:V,icon:cs,label:"Previous month",title:null}),a.jsx(ve,{size:"xSmall",allowShapeTransformation:!1,onClick:Q,icon:os,label:"Next month",title:null})]})]}),w==="year"?a.jsx("div",{className:"h-[280px] overflow-y-auto grid grid-cols-3 gap-2 p-2 scrollbar-hide",ref:j,children:F.map(E=>a.jsx(me,{size:"small",variant:E===h.getFullYear()?"filled":"text",onClick:()=>W(E),"data-selected":E===h.getFullYear(),className:x("w-full",{"text-on-surface":E!==h.getFullYear()}),label:E.toString(),children:E},E))}):a.jsxs(a.Fragment,{children:[a.jsx("div",{className:G.weekDays,children:q.map((E,L)=>a.jsx("div",{className:G.weekDay,children:E},L))}),a.jsx("div",{className:"overflow-hidden relative min-h-[240px]",children:a.jsx(X.AnimatePresence,{mode:"popLayout",initial:!1,custom:p,children:a.jsx(X.motion.div,{custom:p,variants:te,initial:"enter",animate:"center",exit:"exit",transition:{type:"spring",bounce:0,duration:.3},className:G.daysGrid,children:k.map((E,L)=>{if(!E.isCurrentMonth)return a.jsx("div",{className:G.dayCell},L);const{isSelected:N,isStart:A,isEnd:O,isInRange:_}=U(E.date),z=R(E.date),Z=s&&E.date<s||r&&E.date>r||(u==null?void 0:u(E.date));return a.jsx("div",{className:x(G.dayCell,_&&"bg-primary/20",A&&($==null?void 0:$[1])&&"bg-gradient-to-r from-transparent to-primary/20",O&&($==null?void 0:$[0])&&"bg-gradient-to-l from-transparent to-primary/20"),children:a.jsx(me,{className:()=>({button:x("aspect-square h-[40px] p-0",{"text-on-surface":!N&&!z,"opacity-50":Z}),stateLayer:x({"!bg-transparent":Z})}),size:"small",allowShapeTransformation:!1,variant:x({filled:N,outlined:z,text:!N&&!z}),label:E.date.getDate().toString(),onClick:()=>H(E.date),disabled:Z,children:E.date.getDate().toString()})},L)})},h.toISOString())})})]})]})},js=({variant:e="filled",autoFocus:t,disabled:n=!1,errorText:s,placeholder:r,suffix:u,name:c,label:l,className:d,supportingText:o,trailingIcon:f,leadingIcon:y,type:h="text",multiline:m=!1,autoComplete:p="on",onChange:b,value:w,defaultValue:I,showSupportingText:S,id:g,style:B,ref:$,onFocus:v,onBlur:k,...F})=>{const j=i.useId(),P=g||j,M=`${P}-helper`,q=w!==void 0,[V,Q]=i.useState(I??""),W=q?w:V,[C,R]=i.useState(!1),[H,U]=i.useState(!!(s!=null&&s.length)),G=i.useRef(null),te=$||G,E=i.useRef(null),L=i.useRef(null),N=i.useRef(null),A=S??(!!(s!=null&&s.length)||!!(o!=null&&o.length));i.useEffect(()=>{U(!!(s!=null&&s.length))},[s]);const O=()=>{te.current&&!C&&te.current.focus()};i.useEffect(()=>{if(!t||n)return;const le=window.requestAnimationFrame(()=>{O()});return()=>window.cancelAnimationFrame(le)},[t,n,te]),i.useEffect(()=>{C?(U(!1),v==null||v()):(s!=null&&s.length&&U(!0),k==null||k())},[C]);const _=le=>{const fe=le.target.value;q||Q(fe),U(!1),b&&b(le)},z=h==="date",[Z,D]=i.useState(!1),[Y,se]=i.useState(null),ie=i.useMemo(()=>{const le=String(W);if(!le)return null;const[fe,Be,He]=le.split("-").map(Number);return fe&&Be&&He?new Date(fe,Be-1,He):null},[W]),ge=()=>{n||(se(ie),D(!0))};i.useEffect(()=>{R(!!Z)},[Z]);const ue=()=>{const le=Y?Y.toLocaleDateString("en-CA"):"";q||Q(le),b&&b({target:{value:le,name:c,type:h}}),D(!1)},ce=z&&!f?rs:f,K=z?"[&::-webkit-calendar-picker-indicator]:hidden cursor-pointer":"",J=Yt({showSupportingText:A,isFocused:C,showErrorIcon:H,disabled:n,name:c,label:l,autoComplete:p,className:d,onChange:b,placeholder:r,supportingText:o,type:h,leadingIcon:y,trailingIcon:ce,variant:e,errorText:s,value:String(W),suffix:u,multiline:m}),re=m?an:"input",pe=m?{}:{type:h},ye=C||typeof W=="string"&&W.length>0||h=="date",be=ye&&e==="outlined",sn=!be;return a.jsxs("div",{ref:E,className:J.textField,style:B,children:[a.jsxs("fieldset",{onClick:O,className:J.content,role:"presentation",children:[a.jsx("div",{className:J.stateLayer}),y&&a.jsx("div",{className:J.leadingIcon,children:i.isValidElement(y)?y:a.jsx(ae,{className:"w-5 h-5",icon:y})}),a.jsx(X.motion.legend,{"aria-hidden":"true",variants:{hidden:{width:0,padding:0},visible:{width:"auto",padding:"0 8px"}},initial:be?"visible":"hidden",animate:be?"visible":"hidden",className:"max-w-full ml-2 px-2 text-body-small h-0 overflow-hidden whitespace-nowrap",transition:{duration:.2},children:a.jsx("span",{className:"transform inline-flex -translate-y-1/2 opacity-0",children:l})}),a.jsxs("div",{className:"flex-1 relative",children:[sn&&a.jsx(X.motion.label,{htmlFor:P,className:x("absolute left-4 transition-all duration-300 pointer-events-none",{"text-body-small top-2":e=="filled"&&ye,"text-body-large top-1/2 transform -translate-y-1/2":!(e=="filled"&&ye)}),transition:{duration:.3},layoutId:e==="outlined"?`${P}-label`:void 0,children:a.jsx("span",{className:J.label,children:l})}),be&&a.jsx(X.motion.label,{htmlFor:P,className:x("absolute left-2 -top-3 px-1 text-body-small z-10",J.label),layoutId:`${P}-label`,transition:{duration:.3},children:l}),a.jsx(re,{...F,ref:te,value:W,onChange:_,className:x(J.input,K),id:P,name:c,placeholder:C?r??void 0:"",onFocus:()=>R(!0),onBlur:()=>R(!1),disabled:n,autoComplete:p,"aria-invalid":!!(s!=null&&s.length),"aria-describedby":A?M:void 0,autoFocus:t,...pe})]}),a.jsx("div",{className:J.activeIndicator}),!H&&a.jsxs(a.Fragment,{children:[ce&&a.jsx("div",{ref:z?L:void 0,onClick:le=>{le.stopPropagation(),z&&ge()},className:x(J.trailingIcon,z&&"cursor-pointer"),children:a.jsx("div",{className:"flex items-center justify-center w-full h-full",children:i.isValidElement(ce)?ce:a.jsx(ae,{className:"h-5",icon:ce})})}),!ce&&u&&a.jsx("span",{className:J.suffix,children:u})]}),H&&a.jsx("div",{className:x(J.trailingIcon,{" absolute right-0":!ce}),children:a.jsx(ae,{className:"h-5 text-error",icon:is})})]}),A&&a.jsx("p",{className:J.supportingText,id:M,children:s!=null&&s.length?s:o!=null&&o.length?o:" "}),z&&Z&&a.jsx(a.Fragment,{children:a.jsx(De,{onBlur:le=>{var fe;N.current&&!((fe=N.current)!=null&&fe.contains(le.relatedTarget))&&D(!1)},anchorRef:E,position:"bottom",children:a.jsxs("div",{ref:N,className:"z-50 shadow-xl rounded-[28px] bg-surface-container-high overflow-hidden",children:[a.jsx(en,{className:"",value:Y,onChange:se}),a.jsxs("div",{className:"flex justify-end gap-2 p-4 pt-0",children:[a.jsx(me,{variant:"text",size:"small",onClick:()=>D(!1),children:"Cancel"}),a.jsx(me,{variant:"filled",size:"small",onClick:ue,children:"OK"})]})]})})})]})},Is=({isSelected:e,icon:t,label:n,variant:s})=>({navigationRailItem:x(" 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:x(" 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:x("rounded-full"),icon:x("size-6 flex"),label:x("w-fit mx-auto text-nowrap",{"text-label-large ":s=="horizontal","text-label-medium":s=="vertical"})}),Ms=ee("navigationRailItem",Is),tn=({label:e})=>a.jsx("div",{className:" h-9 flex items-center mx-9 mt-3",children:a.jsx("p",{className:"text-label-large text-on-surface-variant",children:e})}),nn=({className:e,onClick:t,label:n,variant:s="vertical",href:r,icon:u,selectedItem:c,setSelectedItem:l,index:d,onItemSelected:o,selected:f=!1,ref:y,transition:h,isExtended:m,iconSelected:p,style:b,extendedOnly:w,children:I,...S})=>{I&&(n=I);const g=i.useRef(null),B=y||g,[$,v]=i.useState(f);i.useEffect(()=>{f&&c==null?v(!0):v(c==d&&d!=null)},[c]),i.useEffect(()=>{c==d&&o&&o({ref:B,index:d||0,label:n,icon:u})},[c]);const k=r?"a":"button",F=P=>{l&&l(d??null),t&&t(P)},j=Ms({isExtended:m,extendedOnly:w,className:e,onItemSelected:o,selectedItem:c,index:d,transition:h,selected:$,variant:s,icon:u,label:n,isSelected:$,setSelectedItem:l,href:r,children:n,iconSelected:p});return h={duration:.3,...h},w&&!m?null:a.jsxs(k,{...S,role:"tab","aria-selected":$,ref:B,href:r,className:j.navigationRailItem,onClick:F,style:{transition:h.duration+"s",...b},children:[a.jsxs(X.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:j.container,children:[a.jsx(de,{style:{transition:h.duration+"s"},className:j.stateLayer,colorName:x({"on-surface":!$,"on-secondary-container":$}),stateClassName:"state-ripple-group-[navigation-rail-item]"}),u&&a.jsx(ae,{icon:$?p:u,className:j.icon}),a.jsx(X.AnimatePresence,{children:s=="horizontal"&&(()=>{const P={width:0,opacity:0,transition:{...h}},M={width:"auto",opacity:1,transition:{...h,opacity:{duration:h.duration/2,delay:h.duration-h.duration/2}}};return a.jsx(X.motion.span,{initial:P,animate:M,exit:P,className:j.label,children:n})})()})]}),a.jsx(X.AnimatePresence,{children:s=="vertical"&&(()=>{const P={height:0,opacity:0,transition:{...h,opacity:{duration:0}}},M={height:"auto",opacity:1,transition:{...h,opacity:{duration:h.duration/3,delay:h.duration-h.duration/3}}};return a.jsx(X.motion.span,{initial:M,animate:M,exit:P,className:j.label,transition:h,children:n})})()})]})},Cs=({isExtended:e,alignment:t})=>({navigationRail:x("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:x("flex flex-col gap-1 items-start"),menuIcon:"mx-5",segments:x(" flex flex-col overflow-auto min-w-full mt-10",{"w-full":!e,"w-fit items-start":e})}),Rs=ee("navigationRail",Cs),Ds=({variant:e="standard",onItemSelected:t,children:n,className:s,selectedItem:r,extended:u,alignment:c="top",menu:l={closed:{icon:us,label:"Open menu"},opened:{icon:we,label:"Close menu"}},style:d,onExtendedChange:o,transition:f,setSelectedItem:y})=>{const[h,m]=i.useState(null),[p,b]=i.useState(u);let w;r==0||r!=null?w=r:w=h;const I=y||m,S=i.useRef(null),g=j=>{t==null||t(j)};function B(j){const P=[];return i.Children.forEach(j,M=>{i.isValidElement(M)&&M.type===i.Fragment?P.push(...B(M.props.children)):P.push(M)}),P}const $=B(n),v=$.filter(j=>i.isValidElement(j)&&j.type===Ne),k=Rs({children:n,onItemSelected:t,selectedItem:w,setSelectedItem:I,className:s,variant:e,extended:p,isExtended:p,alignment:c,menu:l,transition:f,onExtendedChange:o});f={duration:.3,...f};const F=i.useRef(!1);return F.current=!1,i.useEffect(()=>{o==null||o(p??!1)},[p]),a.jsxs("div",{style:{transition:f.duration+"s",...d},ref:S,className:k.navigationRail,children:[a.jsxs("div",{className:k.header,children:[a.jsx(ve,{onClick:()=>b(!p),label:p?l==null?void 0:l.opened.label:l==null?void 0:l.closed.label,className:k.menuIcon,icon:p?l.opened.icon:l==null?void 0:l.closed.icon}),v.length>0&&i.cloneElement(v[0],{transition:f,isExtended:p,className:"!shadow-none mx-5 "+v[0].props.className})]}),a.jsx("div",{className:k.segments,children:(()=>{let j=0;return $.map(P=>i.isValidElement(P)&&P.type===nn?i.cloneElement(P,{key:j,index:j++,variant:p?"horizontal":"vertical",selectedItem:w,setSelectedItem:I,onItemSelected:g,transition:f,extendedOnly:F.current,isExtended:p}):i.isValidElement(P)&&P.type===Ne?null:i.isValidElement(P)&&P.type===tn?(F.current=!0,p?i.cloneElement(P,{}):null):P)})()}),a.jsx("div",{className:"flex-1 max-h-[160px]"})]})};function As(e){return Se.defineConfig({variant:Se.Variants.Udixio,...e,plugins:[new Se.FontPlugin(e),new Ge.TailwindPlugin(e)]})}exports.AnchorPositioner=De;exports.AnimateOnScrollInit=Cn;exports.Button=me;exports.Card=ts;exports.Carousel=ns;exports.CarouselItem=Ut;exports.Checkbox=ds;exports.Chip=Ie;exports.Chips=ys;exports.CustomScroll=tt;exports.DatePicker=en;exports.Divider=Pe;exports.Fab=Ne;exports.FabMenu=xs;exports.Icon=ae;exports.IconButton=ve;exports.NavigationRail=Ds;exports.NavigationRailItem=nn;exports.NavigationRailSection=tn;exports.ProgressIndicator=Xt;exports.RippleEffect=Je;exports.SideSheet=gs;exports.Slider=vs;exports.SmoothScroll=bn;exports.Snackbar=ws;exports.State=de;exports.Switch=bs;exports.SyncedFixedWrapper=ot;exports.Tab=Zt;exports.TabGroup=Ns;exports.TabPanel=Qt;exports.TabPanels=Es;exports.Tabs=Ss;exports.TextField=js;exports.ThemeProvider=En;exports.Tooltip=We;exports.animateOnScroll=Rn;exports.buttonStyle=Dn;exports.cardStyle=An;exports.carouselItemConfig=Ae;exports.carouselItemStyle=Fn;exports.carouselStyle=$n;exports.checkboxStyle=Pn;exports.chipStyle=Wn;exports.chipsStyle=Tn;exports.classNames=x;exports.classnames=Qe;exports.createUseClassNames=ee;exports.customScrollStyle=et;exports.defaultClassNames=ne;exports.defineConfig=As;exports.dividerStyle=Bn;exports.fabMenuStyle=On;exports.fabStyle=Hn;exports.getClassNames=Ee;exports.iconButtonStyle=Vn;exports.initAnimateOnScroll=Re;exports.normalize=xe;exports.progressIndicatorStyle=zn;exports.sideSheetConfig=Fe;exports.sideSheetStyle=Mt;exports.sliderConfig=$e;exports.sliderStyle=_n;exports.snackbarStyle=qn;exports.switchStyle=Xn;exports.tabPanelStyle=Jn;exports.tabPanelsStyle=Gn;exports.tabStyle=Un;exports.tabsStyle=Kn;exports.textFieldStyle=Zn;exports.toolStyle=Qn;exports.useButtonStyle=lt;exports.useCardStyle=ct;exports.useCarouselItemStyle=ut;exports.useCarouselStyle=ft;exports.useCheckboxStyle=mt;exports.useChipStyle=yt;exports.useChipsStyle=vt;exports.useClassNames=un;exports.useDividerStyle=wt;exports.useFabMenuStyle=Et;exports.useFabStyle=St;exports.useIconButtonStyle=Lt;exports.useProgressIndicatorStyle=It;exports.useSideSheetStyle=Yn;exports.useSliderStyle=Ct;exports.useSnackbarStyle=Dt;exports.useStateStyle=rt;exports.useSwitchStyle=Ft;exports.useTabPanelStyle=Vt;exports.useTabPanelsStyle=Ht;exports.useTabStyle=Pt;exports.useTabsStyle=Tt;exports.useTextFieldStyle=Yt;exports.useToolTipStyle=qt;exports.useTooltipTrigger=Jt;
|
|
10
|
+
`})]}),P&&a.jsx(Ae,{ref:B,className:"opacity-0",draggable:s,editable:!0,editing:!0,onChange:v=>{var k;if(v=v.replace(/( )+/g," ").trim(),console.log("Ghost chip onChange",v,!!v),v)I(v);else if(c.length>0){const F=h.current[c.length-1];(k=F==null?void 0:F.focus)==null||k.call(F)}},onEditCommit:()=>{},onBlur:()=>{o(!1)},onFocus:v=>{o(!0),v.stopPropagation()},children:" "})]})};function nn({trigger:e=["hover","focus"],isOpen:t,defaultOpen:n=!1,onOpenChange:s,openDelay:r=400,closeDelay:u=150,id:c}={}){const l=i.useId(),d=c??`tooltip-${l}`,o=Array.isArray(e)?e:[e],f=typeof t=="boolean",[y,h]=i.useState(n?"hovered":"hidden"),[m,p]=i.useState(!1),b=i.useRef(null),w=i.useRef(null),I=i.useCallback(()=>{b.current&&(clearTimeout(b.current),b.current=null),w.current&&(clearTimeout(w.current),w.current=null)},[]);i.useEffect(()=>()=>I(),[I]);const S=i.useCallback(C=>{if(f){const R=C!=="hidden";s==null||s(R)}else{h(C);const R=C!=="hidden";s==null||s(R)}},[f,s]),g=f?t?"hovered":"hidden":y,B=g!=="hidden",P=C=>{switch(C){case"hidden":return 0;case"hovered":return 1;case"focused":return 2;case"clicked":return 3;default:return 0}},v=i.useCallback(C=>{I(),!(P(C)<=P(g))&&(b.current=setTimeout(()=>{S(C)},r))},[I,r,g,S]),k=i.useCallback(C=>{I(),w.current=setTimeout(()=>{(!f&&P(y)<=P(C)||f)&&S("hidden")},u)},[I,u,y,f,S]),F=i.useCallback(()=>{o.includes("hover")&&v("hovered")},[o,v]),j=i.useCallback(()=>{o.includes("hover")&&(g==="focused"||g==="clicked"||m||k("hovered"))},[o,g,m,k]),$=i.useCallback(()=>{o.includes("focus")&&(I(),S("focused"))},[o,I,S]),M=i.useCallback(()=>{if(o.includes("focus")&&g!=="clicked"){if(o.includes("hover")&&m){S("hovered");return}k("focused")}},[o,g,m,k,S]),q=i.useCallback(()=>{o.includes("click")&&(I(),S(g==="clicked"?"hidden":"clicked"))},[o,g,I,S]),V=i.useCallback(C=>{C.key==="Escape"&&B&&(I(),S("hidden"),C.preventDefault())},[B,I,S]),Q=i.useCallback(()=>{p(!0),I()},[I]),W=i.useCallback(()=>{p(!1),o.includes("hover")&&g==="hovered"&&k("hovered")},[o,g,k]);return{triggerProps:{"aria-describedby":B?d:void 0,onMouseEnter:F,onMouseLeave:j,onFocus:$,onBlur:M,onClick:q,onKeyDown:V},tooltipProps:{id:d,role:"tooltip","aria-hidden":!B,onMouseEnter:Q,onMouseLeave:W},isOpen:B,state:g}}const Ve=({variant:e="plain",buttons:t,className:n,children:s,title:r,text:u,content:c,position:l,targetRef:d,ref:o,trigger:f=["hover","focus"],transition:y,openDelay:h=400,closeDelay:m=150,isOpen:p,defaultOpen:b=!1,onOpenChange:w,id:I,anchorRef:S,...g})=>{const P=l||(e==="rich"?"bottom-right":"bottom");if(y={duration:.3,...y},!s&&!d)throw new Error("Tooltip must have a child or a targetRef");t&&!Array.isArray(t)&&(t=[t]);const v=i.useRef(null),F=S||(d||v),{triggerProps:j,tooltipProps:$,isOpen:M}=nn({trigger:f,isOpen:p,defaultOpen:b,onOpenChange:w,openDelay:h,closeDelay:m,id:I}),q=!d&&i.isValidElement(s)?i.cloneElement(s,{ref:v,...j,onMouseEnter:W=>{var C,R;j.onMouseEnter(),(R=(C=s.props)==null?void 0:C.onMouseEnter)==null||R.call(C,W)},onMouseLeave:W=>{var C,R;j.onMouseLeave(),(R=(C=s.props)==null?void 0:C.onMouseLeave)==null||R.call(C,W)},onFocus:W=>{var C,R;j.onFocus(),(R=(C=s.props)==null?void 0:C.onFocus)==null||R.call(C,W)},onBlur:W=>{var C,R;j.onBlur(),(R=(C=s.props)==null?void 0:C.onBlur)==null||R.call(C,W)},onClick:W=>{var C,R;j.onClick(),(R=(C=s.props)==null?void 0:C.onClick)==null||R.call(C,W)},onKeyDown:W=>{var C,R;j.onKeyDown(W),(R=(C=s.props)==null?void 0:C.onKeyDown)==null||R.call(C,W)}}):s;i.useEffect(()=>{if(!d)return;const W=d.current;if(!W)return;const C=()=>j.onMouseEnter(),R=()=>j.onMouseLeave(),H=()=>j.onFocus(),U=()=>j.onBlur(),G=()=>j.onClick(),te=E=>j.onKeyDown(E);return W.addEventListener("mouseenter",C),W.addEventListener("mouseleave",R),W.addEventListener("focus",H,!0),W.addEventListener("blur",U,!0),W.addEventListener("click",G),W.addEventListener("keydown",te),j["aria-describedby"]?W.setAttribute("aria-describedby",j["aria-describedby"]):W.removeAttribute("aria-describedby"),()=>{W.removeEventListener("mouseenter",C),W.removeEventListener("mouseleave",R),W.removeEventListener("focus",H,!0),W.removeEventListener("blur",U,!0),W.removeEventListener("click",G),W.removeEventListener("keydown",te)}},[d,j]);const V=Jt({variant:e,buttons:t,className:n,title:r,text:u,position:P,trigger:f,targetRef:d,children:s}),Q={open:{opacity:1,height:"auto"},close:{opacity:0,height:16}};return a.jsxs(a.Fragment,{children:[q,a.jsx(X.AnimatePresence,{children:M&&a.jsx(We,{anchorRef:F,position:P,children:a.jsx(X.motion.div,{initial:"close",variants:Q,animate:"open",transition:{duration:y.duration},exit:"close",className:V.toolTip,...g,...$,children:a.jsx("div",{className:V.container,children:c?a.jsx("div",{className:V.content,children:c}):a.jsxs(a.Fragment,{children:[r&&a.jsx("div",{className:V.subHead,children:r}),u&&a.jsx("div",{className:V.supportingText,children:u}),t&&a.jsx("div",{className:V.actions,children:Array.isArray(t)&&t.map((W,C)=>a.jsx(pe,{size:"small",variant:"text",...W},C))})]})})})})})]})},Ie=({className:e,label:t,variant:n="primary",size:s="medium",href:r,type:u,icon:c,extended:l=!1,ref:d,transition:o,children:f,...y})=>{if(f&&(t=f),!t)throw new Error("FAB component requires either a label prop or children content");const h=r?"a":"button",m=jt({href:r,icon:c,extended:l,label:t,size:s,variant:n,className:e,transition:o,children:t});o={duration:.3,...o};const p=i.useRef(null),b=d||p,w={visible:{width:"auto",marginLeft:12,opacity:1,transition:{...o,opacity:{duration:o.duration/2,delay:o.duration-o.duration/2}}},hidden:{width:0,marginLeft:0,opacity:0,transition:{...o,marginLeft:{duration:o.duration/2,delay:o.duration-o.duration/2}}}};return a.jsxs(h,{...y,ref:b,href:r,"aria-label":l?void 0:t,className:m.fab,children:[a.jsx(Ve,{trigger:l?null:void 0,text:t,targetRef:b}),a.jsx(fe,{style:{transition:o.duration+"s"},className:m.stateLayer,colorName:x({"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]"}),a.jsx(ae,{icon:c,className:m.icon}),a.jsx(X.AnimatePresence,{children:l&&a.jsx(X.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:l,icon:d,size:o="medium",iconSelected:f,className:y,ref:h,width:m="default",shape:p="rounded",allowShapeTransformation:b=!0,transition:w,children:I,...S})=>{if(I&&(r=I),!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,B]=i.useState(c),P=$=>{n&&$.preventDefault(),u?(B(!g),u(!g)):l&&l($)};i.useEffect(()=>{B(c)},[c]);const v=t?"a":"button",k=Rt({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:y,size:o,children:r,...S}),F=i.useRef(null),j=h||F;return w={duration:.3,...w},a.jsxs(v,{disabled:n,href:t,style:{transition:w.duration+"s"},className:k.iconButton,"aria-label":r,...S,title:void 0,onClick:P,ref:j,children:[s!==null&&a.jsx(Ve,{targetRef:j,trigger:n?null:void 0,text:s}),a.jsx("div",{className:k.touchTarget}),a.jsx(fe,{style:{transition:w.duration+"s"},className:k.stateLayer,colorName:x(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?a.jsx(ae,{icon:d,className:k.icon}):I]})},Ns=({className:e,label:t,variant:n="primary",size:s="medium",href:r,icon:u,extended:c=!1,ref:l,transition:d,children:o,open:f,defaultOpen:y=!1,onOpenChange:h,...m})=>{d={duration:.3,ease:"easeInOut",...d};const p=i.useRef(null),b=l||p,w=typeof f=="boolean",[I,S]=i.useState(y),g=w?f:I,B=M=>{w||S(M),h==null||h(M)},P=i.Children.toArray(o).filter(M=>i.isValidElement(M)&&M.type===pe),v=Mt({href:r,icon:u,extended:c,label:t,size:s,variant:n,className:e,transition:d,children:t,open:g}),k=X.motion.create(Ie),F=X.motion.create(ge),j=M=>a.jsx(k,{icon:u,extended:c,label:t,variant:n+"Container",size:s,className:v.fab+" "+(e??""),"aria-expanded":g,onClick:()=>B(!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},...M}),$=i.useId();return a.jsxs("div",{className:v.fabMenu,ref:b,...m,children:[a.jsx(X.AnimatePresence,{children:g&&a.jsx("div",{className:v.actions,role:"menu","aria-hidden":!g,children:(()=>{const M=P.length;return P.map((q,V)=>{q.props;const Q=M-1-V,W=((d==null?void 0:d.delay)??0)+Q*.06,C={open:{overflow:"visible",opacity:1,width:"auto",transition:{...d,delay:W,opacity:{delay:(d==null?void 0:d.duration)/2+W}}},close:{overflow:"hidden",opacity:0,width:0,transition:{...d,delay:W,opacity:{duration:(d==null?void 0:d.duration)/1.5}}}};return a.jsx(X.motion.div,{initial:"close",animate:"open",variants:C,transition:d,exit:"close",children:i.cloneElement(q,{key:V,shape:"rounded",variant:"filled",className:()=>({button:x("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:x({"state-on-primary-container":n==="primary","state-on-secondary-container":n==="secondary","state-on-tertiary-container":n==="tertiary"})})})})})})()})}),j({className:"invisible pointer-events-none"}),a.jsxs("div",{className:"absolute right-0 top-0",children:[!g&&j({className:"",layout:!0,layoutId:"fab-menu"+$}),g&&a.jsx(a.Fragment,{children:a.jsx(F,{layout:!0,layoutId:"fab-menu"+$,variant:"filled",className:()=>({iconButton:x({"bg-primary text-on-primary":n==="primary","bg-secondary text-on-secondary":n==="secondary","bg-tertiary text-on-tertiary":n==="tertiary"}),stateLayer:x({"[--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:hs,onClick:()=>B(!1),children:"Close"})})]})]})},Es=({className:e,valueFormatter:t,step:n=10,name:s,value:r=0,min:u=0,max:c=100,marks:l=[{value:0,label:"0"},{value:100,label:"100"}],ref:d,onChange:o,...f})=>{const y=R=>{const H=m(),U=h();return R===1/0?100:R===-1/0?0:(R-H)/(U-H)*100},h=(R=!1)=>R?c:c==1/0?l[(l==null?void 0:l.length)-1].value:c,m=(R=!1)=>R?u:u==-1/0?l[0].value:u,p=R=>{const H=m(!1);return(h(!1)-H)*R/100+H},[b,w]=i.useState(!1),I=i.useRef(null),S=d||I,[g,B]=i.useState(r),[P,v]=i.useState(y(r)),[k,F]=i.useState(!1);i.useEffect(()=>{B(r),v(y(r))},[r]);const j=R=>{F(!0),w(!0),q(R)},$=()=>{F(!1),w(!1)};i.useEffect(()=>(k?(window.addEventListener("mouseup",$),window.addEventListener("mousemove",q),window.addEventListener("touchend",$),window.addEventListener("touchmove",q)):(window.removeEventListener("mouseup",$),window.removeEventListener("mousemove",q),window.removeEventListener("touchend",$),window.removeEventListener("touchmove",q)),()=>{window.removeEventListener("mouseup",$),window.removeEventListener("mousemove",q),window.removeEventListener("touchend",$),window.removeEventListener("touchmove",q)}),[k]);const M=Pt({className:e,isChanging:b,marks:l,max:c,min:u,name:s,step:n,value:g,valueFormatter:t,onChange:o}),q=R=>{const H=S==null?void 0:S.current;if(H){const U=H.getBoundingClientRect().left,te=((R.type==="touchmove"||R.type==="touchstart"?R.touches[0].clientX:R.clientX)-U)/H.offsetWidth*100;V({percent:te})}},V=({percent:R,value:H})=>{if(R){if(R>=100){B(h(!0)),v(100);return}if(R<=0){B(m(!0)),v(0);return}H=p(R),H==m()&&(H=m(!0)),H==h()&&(H=h(!0))}else if(H!=null){if(H>=h()){B(h(!0)),v(100);return}if(H<=m()){B(m(!0)),v(0);return}R=y(H)}else return;n!=null?H=Math.round((H-m())/n)*n+m():l&&(H=l.reduce((U,G,te)=>{let E=G.value===1/0?h():G.value===-1/0?m():G.value,L=U.value===1/0?h():U.value===-1/0?m():U.value;return E=Math.abs(E-H),L=Math.abs(L-H),E<L?G:U}).value),H>=h()&&(H=h(!0)),H<=m()&&(H=m(!0)),R=y(H),B(H),v(R),o&&o(H)},[Q,W]=i.useState(0);i.useEffect(()=>{const R=()=>{S.current&&W(S.current.offsetWidth)};return R(),window.addEventListener("resize",R),()=>{window.removeEventListener("resize",R)}},[]);const C=R=>{switch(R.key){case"ArrowRight":if(n)V({value:g+n});else if(l){const H=l.find(U=>U.value>g);H&&V({value:H.value})}break;case"ArrowLeft":if(n)V({value:g-n});else if(l){const H=l.slice(0).reverse().find((U,G,te)=>g===1/0?G===1:U.value<g);H&&V({value:H.value})}break;default:return}};return a.jsxs("div",{tabIndex:0,onKeyDown:C,role:"slider","aria-valuemin":m(!0),"aria-valuemax":h(!0),"aria-valuenow":g,"aria-valuetext":g.toString(),className:M.slider,onMouseDown:j,onClick:q,ref:S,onTouchStart:j,onDragStart:R=>R.preventDefault(),...f,children:[a.jsx("input",{type:"hidden",name:s,value:g}),a.jsx("div",{className:M.activeTrack,style:{flex:P/100}}),a.jsx("div",{className:M.handle,children:a.jsx(X.AnimatePresence,{children:b&&a.jsx(X.motion.div,{className:M.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})})}),a.jsx("div",{className:M.inactiveTrack,style:{flex:1-P/100}}),a.jsx("div",{className:"w-[calc(100%-12px)] h-full absolute -translate-x-1/2 transform left-1/2",children:l&&l.map((R,H)=>{let U=null;const G=(b?9:10)/Q*100,te=y(R.value);return te<=P-G?U=!0:te>=P+G&&(U=!1),a.jsx("div",{className:x(M.dot,{"bg-primary-container":U!=null&&U,"bg-primary":U!=null&&!U}),style:{left:`${y(R.value)}%`}},H)})})]})},ks=({variant:e="standard",className:t,children:n,title:s,position:r="right",extended:u,divider:c,onExtendedChange:l,closeIcon:d=Ee,transition:o,...f})=>{o={duration:.3,...o};const[y,h]=i.useState(u??!0),m=Ft({transition:o,title:s,position:r,closeIcon:d,className:t,children:n,onExtendedChange:l,divider:c,isExtended:y,extended:y,variant:e});i.useEffect(()=>{l==null||l(y??!1)},[y]),i.useEffect(()=>{u!=null&&h(u)},[u]);const p={close:{width:0},open:{width:"auto"}},b=()=>a.jsxs(a.Fragment,{children:[a.jsx(X.AnimatePresence,{children:e=="modal"&&y&&a.jsx(X.motion.div,{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:o,onClick:()=>h(!1),className:m.overlay})}),a.jsx(X.AnimatePresence,{children:y&&a.jsxs("div",{...f,className:m.sideSheet,style:{transition:o.duration+"s"},children:[a.jsxs(X.motion.div,{variants:p,initial:u===!1?"open":"close",animate:"open",exit:"close",className:m.container,children:[a.jsxs("div",{className:m.header,children:[s&&a.jsx("p",{className:m.title,children:s}),a.jsx(ge,{size:"small",label:"close",icon:d,onClick:()=>h(!1),className:m.closeButton})]}),a.jsx("div",{className:m.content,style:{transition:o.duration+"s"},children:n})]}),(c==null&&e=="standard"?!0:c)&&a.jsx(Oe,{className:m.divider,orientation:"vertical"})]})})]});return e=="modal"?Fe.createPortal(b(),document.body):b()},Ls=({message:e,className:t,duration:n,closeIcon:s=Ee,onClose:r,...u})=>{const[c,l]=i.useState(!0),d=Wt({className:t,closeIcon:s,duration:n,isVisible:c,onClose:r,message:e});i.useEffect(()=>{n&&setTimeout(()=>{o()},n)},[n]);const o=()=>{l(!1),r==null||r()};return a.jsx(X.AnimatePresence,{children:c&&a.jsx(X.motion.div,{initial:{height:0},animate:{height:"auto"},exit:{height:0},transition:{duration:.1},className:d.snackbar,...u,children:a.jsxs("div",{className:d.container,children:[a.jsx("p",{className:d.supportingText,children:e}),a.jsx(ge,{onClick:()=>o(),className:d.icon,icon:s,label:"close the snackbar"})]})})})},js=({selected:e=!1,className:t,activeIcon:n,disabled:s=!1,inactiveIcon:r,onChange:u,onClick:c,onKeyDown:l,ref:d,...o})=>{const[f,y]=i.useState(e);i.useEffect(()=>{y(e)},[e]);const h=S=>{s||(p(),c&&c(S))},m=S=>{s||((S.key===" "||S.key==="Enter")&&(S.preventDefault(),p()),l&&l(S))},p=()=>{y(!f),u==null||u(!f)},b=Bt({className:t,isSelected:f,activeIcon:n,inactiveIcon:r,disabled:s,selected:f,onChange:u}),w=i.useRef(null),I=d||w;return a.jsxs(X.motion.div,{role:"switch","aria-checked":f,tabIndex:s?-1:0,onKeyDown:m,onClick:h,ref:I,className:b.switch,...o,children:[a.jsx("input",{type:"hidden",value:f?"1":"0"}),a.jsxs(X.motion.div,{layout:!0,style:{translate:f?"50%":"-50%"},transition:{type:"spring",stiffness:700,damping:30},className:b.handleContainer,children:[a.jsx("div",{className:b.handle,children:(f?n:r)&&a.jsx(ae,{className:b.icon,icon:f?n:r})}),a.jsx("div",{className:b.handleStateLayer})]})]})},sn=({className:e,onClick:t,label:n,variant:s="primary",href:r,icon:u,selectedTab:c,setSelectedTab:l,tabsId:d,index:o,onTabSelected:f,scrollable:y=!1,selected:h=!1,children:m,ref:p,...b})=>{const w=i.useRef(null),I=p||w,S=n??(typeof m=="string"?m:void 0),[g,B]=i.useState(h);i.useEffect(()=>{h&&c==null?B(!0):B(c==o&&o!=null)},[c]),i.useEffect(()=>{c==o&&f&&f({ref:I,index:o||0,label:S,icon:u})},[c]);const P=r?"a":"button",v=F=>{l&&l(o??null),t&&t(F)},k=Ot({className:e,onTabSelected:f,scrollable:y,selectedTab:c,index:o,tabsId:d,selected:g,variant:s,icon:u,label:S,isSelected:g,setSelectedTab:l,href:r});return a.jsxs(P,{...b,role:"tab","aria-selected":g,ref:I,href:r,className:k.tab,onClick:v,...b,children:[a.jsx(fe,{style:{transition:.3+"s"},className:k.stateLayer,colorName:s==="primary"&&g?"primary":"on-surface",stateClassName:"state-ripple-group-[tab]"}),a.jsxs("span",{className:k.content,children:[u&&a.jsx(ae,{icon:u,className:k.icon}),a.jsx("span",{className:k.label,children:S}),g&&a.jsx(X.motion.span,{layoutId:`underline-${d}`,className:k.underline,transition:{duration:.3}})]})]})},ze=i.createContext(null),Is=({variant:e="primary",onTabSelected:t,children:n,className:s,selectedTab:r,setSelectedTab:u,scrollable:c=!1})=>{const l=i.useContext(ze),[d,o]=i.useState(null);let f;r===0||r!=null?f=r:l?f=l.selectedTab:f=d;const y=u??(l==null?void 0:l.setSelectedTab)??o,h=i.Children.toArray(n).filter(I=>i.isValidElement(I)&&I.type===sn),m=i.useRef(null),p=I=>{if(t==null||t(I),c){const S=m.current,g=I.ref.current;if(S&&g){const B=g.offsetLeft+g.offsetWidth/2-S.offsetWidth/2;S.scrollTo({left:B,behavior:"smooth"})}}},b=i.useMemo(()=>(l==null?void 0:l.tabsId)??tn(),[l==null?void 0:l.tabsId]),w=zt({children:n,onTabSelected:t,scrollable:c,selectedTab:f,setSelectedTab:y,className:s,variant:e});return a.jsx("div",{ref:m,role:"tablist",className:w.tabs,children:h.map((I,S)=>i.cloneElement(I,{key:S,index:S,variant:e,selectedTab:f,setSelectedTab:y,tabsId:b,onTabSelected:p,scrollable:c}))})},Ms=({children:e,selectedTab:t,setSelectedTab:n,defaultTab:s=0})=>{const[r,u]=i.useState(s),c=i.useRef(null),l=t!==void 0?t:r,d=n??u,o=c.current!==null&&l!==null?l>c.current?1:-1:0;l!==c.current&&(c.current=l);const f=i.useId(),y=i.useMemo(()=>({selectedTab:l,setSelectedTab:d,previousTab:c.current,direction:o,tabsId:f}),[l,d,o,f]);return a.jsx(ze.Provider,{value:y,children:e})},rn=({children:e,className:t,isSelected:n=!1})=>{const s=Xt({children:e,className:t,isSelected:n});return a.jsx("div",{className:s.tabPanel,children:e})},Cs=({children:e,className:t})=>{const n=i.useContext(ze);if(!n)return console.warn("TabPanels must be used within a TabGroup"),null;const{selectedTab:s,direction:r,tabsId:u}=n,c=i.Children.toArray(e).filter(d=>i.isValidElement(d)&&d.type===rn),l=_t({children:e,className:t});return a.jsx("div",{className:l.tabPanels,children:a.jsx(X.AnimatePresence,{initial:!1,custom:r,mode:"popLayout",children:c.map((d,o)=>s===o&&a.jsx(X.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}-${o}`,children:i.cloneElement(d,{isSelected:!0})},o))})})},Rs=({hasSelected:e})=>({datePicker:x("inline-flex flex-col bg-surface-container-high rounded-[28px] p-3 select-none","min-w-[320px]"),header:x("flex items-center justify-between h-12 mb-2 px-2"),monthNav:x("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:x("text-label-large text-on-surface font-bold capitalize"),weekDays:x("grid grid-cols-7 mb-2"),weekDay:x("h-10 flex items-center justify-center text-body-small text-on-surface-variant"),daysGrid:x("grid grid-cols-7 row-auto gap-y-2"),dayCell:x("flex items-center justify-center h-10 p-0 relative"),dayButton:x("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")}),Ds=ee("datePicker",Rs),on=({value:e,defaultValue:t,onChange:n,minDate:s,maxDate:r,shouldDisableDate:u,locale:c="default",weekStartDay:l=0,className:d,style:o,mode:f="single",...y})=>{const[h,m]=i.useState(()=>{const E=N=>N instanceof Date?N:Array.isArray(N)&&N[0]?N[0]:null,L=E(e)||E(t)||new Date;return new Date(L.getFullYear(),L.getMonth(),1)}),[p,b]=i.useState(0),[w,I]=i.useState("day"),S=e!==void 0,[g,B]=i.useState(t||null),P=S?e||null:g,v=(E,L)=>new Date(E,L+1,0).getDate(),k=i.useMemo(()=>{const E=h.getFullYear(),L=h.getMonth(),N=v(E,L),O=(new Date(E,L,1).getDay()-l+7)%7,_=[],z=v(E,L-1);for(let Y=O-1;Y>=0;Y--)_.push({date:new Date(E,L-1,z-Y),isCurrentMonth:!1});for(let Y=1;Y<=N;Y++)_.push({date:new Date(E,L,Y),isCurrentMonth:!0});const D=42-_.length;for(let Y=1;Y<=D;Y++)_.push({date:new Date(E,L+1,Y),isCurrentMonth:!1});return _},[h,l]),F=i.useMemo(()=>{const E=new Date().getFullYear(),L=E-100,N=E+100,A=[];for(let O=L;O<=N;O++)A.push(O);return A},[]),j=i.useRef(null);i.useEffect(()=>{if(w==="year"&&j.current){const E=j.current.querySelector('[data-selected="true"]');E&&E.scrollIntoView({block:"center"})}},[w]);const $=i.useMemo(()=>new Intl.DateTimeFormat(c,{month:"long",year:"numeric"}),[c]),M=i.useMemo(()=>new Intl.DateTimeFormat(c,{weekday:"narrow"}),[c]),q=i.useMemo(()=>{const E=new Date(2023,0,1+l);return Array.from({length:7}).map((L,N)=>{const A=new Date(E);return A.setDate(E.getDate()+N),M.format(A).charAt(0).toUpperCase()})},[M,l]),V=()=>{b(-1),m(E=>new Date(E.getFullYear(),E.getMonth()-1,1))},Q=()=>{b(1),m(E=>new Date(E.getFullYear(),E.getMonth()+1,1))},W=E=>{m(L=>new Date(E,L.getMonth(),1)),I("day")},C=(E,L)=>E?E.getDate()===L.getDate()&&E.getMonth()===L.getMonth()&&E.getFullYear()===L.getFullYear():!1,R=E=>C(new Date,E),H=E=>{let L=E;if(f==="single")L=E;else{const N=P,[A,O]=Array.isArray(N)?N:[null,null];!A||A&&O?L=[E,null]:E<A?L=[E,A]:L=[A,E]}S||B(L),n&&n(L)},U=E=>{if(f==="single")return{isSelected:C(P,E),isStart:!1,isEnd:!1,isInRange:!1};const L=Array.isArray(P)?P:[P,null],[N,A]=L,O=C(N,E),_=C(A,E);let z=!1;if(N&&A){const J=new Date(N.getFullYear(),N.getMonth(),N.getDate()).getTime(),D=new Date(A.getFullYear(),A.getMonth(),A.getDate()).getTime(),Y=new Date(E.getFullYear(),E.getMonth(),E.getDate()).getTime();z=Y>J&&Y<D}return{isSelected:O||_,isStart:O,isEnd:_,isInRange:z}},G=Ds({hasSelected:!!P}),te={enter:E=>({x:E>0?"100%":"-100%",opacity:0}),center:{x:0,opacity:1},exit:E=>({x:E<0?"100%":"-100%",opacity:0})};return a.jsxs("div",{className:x(G.datePicker,d),style:o,...y,children:[a.jsxs("div",{className:G.header,children:[a.jsxs(pe,{variant:"text",disableTextMargins:!0,size:"small",onClick:()=>I(E=>E==="day"?"year":"day"),className:"text-label-large font-bold capitalize text-on-surface hover:bg-surface-container-highest",children:[a.jsx("span",{className:"mr-2",children:w==="day"?$.format(h):h.getFullYear()}),a.jsx(ae,{icon:ms,className:x("w-3 h-3 transition-transform duration-200 inline",w==="year"&&"rotate-180")})]}),w==="day"&&a.jsxs("div",{className:"flex items-center",children:[a.jsx(ge,{size:"xSmall",allowShapeTransformation:!1,onClick:V,icon:ps,label:"Previous month",title:null}),a.jsx(ge,{size:"xSmall",allowShapeTransformation:!1,onClick:Q,icon:ds,label:"Next month",title:null})]})]}),w==="year"?a.jsx("div",{className:"h-[280px] overflow-y-auto grid grid-cols-3 gap-2 p-2 scrollbar-hide",ref:j,children:F.map(E=>a.jsx(pe,{size:"small",variant:E===h.getFullYear()?"filled":"text",onClick:()=>W(E),"data-selected":E===h.getFullYear(),className:x("w-full",{"text-on-surface":E!==h.getFullYear()}),label:E.toString(),children:E},E))}):a.jsxs(a.Fragment,{children:[a.jsx("div",{className:G.weekDays,children:q.map((E,L)=>a.jsx("div",{className:G.weekDay,children:E},L))}),a.jsx("div",{className:"overflow-hidden relative min-h-[240px]",children:a.jsx(X.AnimatePresence,{mode:"popLayout",initial:!1,custom:p,children:a.jsx(X.motion.div,{custom:p,variants:te,initial:"enter",animate:"center",exit:"exit",transition:{type:"spring",bounce:0,duration:.3},className:G.daysGrid,children:k.map((E,L)=>{if(!E.isCurrentMonth)return a.jsx("div",{className:G.dayCell},L);const{isSelected:N,isStart:A,isEnd:O,isInRange:_}=U(E.date),z=R(E.date),J=s&&E.date<s||r&&E.date>r||(u==null?void 0:u(E.date));return a.jsx("div",{className:x(G.dayCell,_&&"bg-primary/20",A&&(P==null?void 0:P[1])&&"bg-gradient-to-r from-transparent to-primary/20",O&&(P==null?void 0:P[0])&&"bg-gradient-to-l from-transparent to-primary/20"),children:a.jsx(pe,{className:()=>({button:x("aspect-square h-[40px] p-0",{"text-on-surface":!N&&!z,"opacity-50":J}),stateLayer:x({"!bg-transparent":J})}),size:"small",allowShapeTransformation:!1,variant:x({filled:N,outlined:z,text:!N&&!z}),label:E.date.getDate().toString(),onClick:()=>H(E.date),disabled:J,children:E.date.getDate().toString()})},L)})},h.toISOString())})})]})]})},As=({variant:e="filled",autoFocus:t,disabled:n=!1,errorText:s,placeholder:r,suffix:u,name:c,label:l,className:d,supportingText:o,trailingIcon:f,leadingIcon:y,type:h="text",multiline:m=!1,autoComplete:p="on",onChange:b,value:w,defaultValue:I,showSupportingText:S,id:g,style:B,ref:P,onFocus:v,onBlur:k,...F})=>{const j=i.useId(),$=g||j,M=`${$}-helper`,q=w!==void 0,[V,Q]=i.useState(I??""),W=q?w:V,[C,R]=i.useState(!1),[H,U]=i.useState(!!(s!=null&&s.length)),G=i.useRef(null),te=P||G,E=i.useRef(null),L=i.useRef(null),N=i.useRef(null),A=S??(!!(s!=null&&s.length)||!!(o!=null&&o.length));i.useEffect(()=>{U(!!(s!=null&&s.length))},[s]);const O=()=>{te.current&&!C&&te.current.focus()};i.useEffect(()=>{if(!t||n)return;const le=window.requestAnimationFrame(()=>{O()});return()=>window.cancelAnimationFrame(le)},[t,n,te]),i.useEffect(()=>{C?(U(!1),v==null||v()):(s!=null&&s.length&&U(!0),k==null||k())},[C]);const _=le=>{const he=le.target.value;q||Q(he),U(!1),b&&b(le)},z=h==="date",[J,D]=i.useState(!1),[Y,se]=i.useState(null),ie=i.useMemo(()=>{const le=String(W);if(!le)return null;const[he,be,Se]=le.split("-").map(Number);return he&&be&&Se?new Date(he,be-1,Se):null},[W]),we=()=>{n||(J?D(!1):(se(ie),D(!0)))};i.useEffect(()=>{R(!!J)},[J]),i.useEffect(()=>{if(!J)return;const le=de=>{var Ne,Le;return de?((Ne=E.current)==null?void 0:Ne.contains(de))||((Le=N.current)==null?void 0:Le.contains(de)):!1},he=de=>{var Ye,_e;const Ne=de.target,Le=(Ye=N.current)==null?void 0:Ye.contains(Ne),un=(_e=L.current)==null?void 0:_e.contains(Ne);!Le&&!un&&D(!1)},be=de=>{le(de.target)||D(!1)},Se=de=>{de.key==="Escape"&&D(!1)};return document.addEventListener("pointerdown",he),document.addEventListener("focusin",be),document.addEventListener("keydown",Se),()=>{document.removeEventListener("pointerdown",he),document.removeEventListener("focusin",be),document.removeEventListener("keydown",Se)}},[J]);const ue=()=>{const le=Y?Y.toLocaleDateString("en-CA"):"";q||Q(le),b&&b({target:{value:le,name:c,type:h}}),D(!1)},ce=z&&!f?us:f,K=z?"[&::-webkit-calendar-picker-indicator]:hidden cursor-pointer":"",Z=Kt({showSupportingText:A,isFocused:C,showErrorIcon:H,disabled:n,name:c,label:l,autoComplete:p,className:d,onChange:b,placeholder:r,supportingText:o,type:h,leadingIcon:y,trailingIcon:ce,variant:e,errorText:s,value:String(W),suffix:u,multiline:m}),re=m?mn:"input",ye=m?{}:{type:h},xe=C||typeof W=="string"&&W.length>0||h=="date",ke=xe&&e==="outlined",cn=!ke;return a.jsxs("div",{ref:E,className:Z.textField,style:B,children:[a.jsxs("fieldset",{onClick:O,className:Z.content,role:"presentation",children:[a.jsx("div",{className:Z.stateLayer}),y&&a.jsx("div",{className:Z.leadingIcon,children:i.isValidElement(y)?y:a.jsx(ae,{className:"w-5 h-5",icon:y})}),a.jsx(X.motion.legend,{"aria-hidden":"true",variants:{hidden:{width:0,padding:0},visible:{width:"auto",padding:"0 8px"}},initial:ke?"visible":"hidden",animate:ke?"visible":"hidden",className:"max-w-full ml-2 px-2 text-body-small h-0 overflow-hidden whitespace-nowrap",transition:{duration:.2},children:a.jsx("span",{className:"transform inline-flex -translate-y-1/2 opacity-0",children:l})}),a.jsxs("div",{className:"flex-1 relative",children:[cn&&a.jsx(X.motion.label,{htmlFor:$,className:x("absolute left-4 transition-all duration-300 pointer-events-none",{"text-body-small top-2":e=="filled"&&xe,"text-body-large top-1/2 transform -translate-y-1/2":!(e=="filled"&&xe)}),transition:{duration:.3},layoutId:e==="outlined"?`${$}-label`:void 0,children:a.jsx("span",{className:Z.label,children:l})}),ke&&a.jsx(X.motion.label,{htmlFor:$,className:x("absolute left-2 -top-3 px-1 text-body-small z-10",Z.label),layoutId:`${$}-label`,transition:{duration:.3},children:l}),a.jsx(re,{...F,ref:te,value:W,onChange:_,className:x(Z.input,K),id:$,name:c,placeholder:C?r??void 0:"",onFocus:()=>R(!0),onBlur:()=>R(!1),disabled:n,autoComplete:p,"aria-invalid":!!(s!=null&&s.length),"aria-describedby":A?M:void 0,...ye})]}),a.jsx("div",{className:Z.activeIndicator}),!H&&a.jsxs(a.Fragment,{children:[ce&&a.jsx("div",{ref:z?L:void 0,onClick:le=>{le.stopPropagation(),z&&we()},className:x(Z.trailingIcon,z&&"cursor-pointer"),children:a.jsx("div",{className:"flex items-center justify-center w-full h-full",children:i.isValidElement(ce)?ce:a.jsx(ae,{className:"h-5",icon:ce})})}),!ce&&u&&a.jsx("span",{className:Z.suffix,children:u})]}),H&&a.jsx("div",{className:x(Z.trailingIcon,{" absolute right-0":!ce}),children:a.jsx(ae,{className:"h-5 text-error",icon:fs})})]}),A&&a.jsx("p",{className:Z.supportingText,id:M,children:s!=null&&s.length?s:o!=null&&o.length?o:" "}),z&&J&&a.jsx(a.Fragment,{children:a.jsx(We,{anchorRef:E,position:"bottom",children:a.jsxs("div",{ref:N,className:"z-50 shadow-xl rounded-[28px] bg-surface-container-high overflow-hidden",children:[a.jsx(on,{className:"",value:Y,onChange:se}),a.jsxs("div",{className:"flex justify-end gap-2 p-4 pt-0",children:[a.jsx(pe,{variant:"text",size:"small",onClick:()=>D(!1),children:"Cancel"}),a.jsx(pe,{variant:"filled",size:"small",onClick:ue,children:"OK"})]})]})})})]})},Fs=({isSelected:e,icon:t,label:n,variant:s})=>({navigationRailItem:x(" 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:x(" 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:x("rounded-full"),icon:x("size-6 flex"),label:x("w-fit mx-auto text-nowrap",{"text-label-large ":s=="horizontal","text-label-medium":s=="vertical"})}),Ps=ee("navigationRailItem",Fs),ln=({label:e})=>a.jsx("div",{className:" h-9 flex items-center mx-9 mt-3",children:a.jsx("p",{className:"text-label-large text-on-surface-variant",children:e})}),an=({className:e,onClick:t,label:n,variant:s="vertical",href:r,icon:u,selectedItem:c,setSelectedItem:l,index:d,onItemSelected:o,selected:f=!1,ref:y,transition:h,isExtended:m,iconSelected:p,style:b,extendedOnly:w,children:I,...S})=>{I&&(n=I);const g=i.useRef(null),B=y||g,[P,v]=i.useState(f);i.useEffect(()=>{f&&c==null?v(!0):v(c==d&&d!=null)},[c]),i.useEffect(()=>{c==d&&o&&o({ref:B,index:d||0,label:n,icon:u})},[c]);const k=r?"a":"button",F=$=>{l&&l(d??null),t&&t($)},j=Ps({isExtended:m,extendedOnly:w,className:e,onItemSelected:o,selectedItem:c,index:d,transition:h,selected:P,variant:s,icon:u,label:n,isSelected:P,setSelectedItem:l,href:r,children:n,iconSelected:p});return h={duration:.3,...h},w&&!m?null:a.jsxs(k,{...S,role:"tab","aria-selected":P,ref:B,href:r,className:j.navigationRailItem,onClick:F,style:{transition:h.duration+"s",...b},children:[a.jsxs(X.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:j.container,children:[a.jsx(fe,{style:{transition:h.duration+"s"},className:j.stateLayer,colorName:x({"on-surface":!P,"on-secondary-container":P}),stateClassName:"state-ripple-group-[navigation-rail-item]"}),u&&a.jsx(ae,{icon:P?p:u,className:j.icon}),a.jsx(X.AnimatePresence,{children:s=="horizontal"&&(()=>{const $={width:0,opacity:0,transition:{...h}},M={width:"auto",opacity:1,transition:{...h,opacity:{duration:h.duration/2,delay:h.duration-h.duration/2}}};return a.jsx(X.motion.span,{initial:$,animate:M,exit:$,className:j.label,children:n})})()})]}),a.jsx(X.AnimatePresence,{children:s=="vertical"&&(()=>{const $={height:0,opacity:0,transition:{...h,opacity:{duration:0}}},M={height:"auto",opacity:1,transition:{...h,opacity:{duration:h.duration/3,delay:h.duration-h.duration/3}}};return a.jsx(X.motion.span,{initial:M,animate:M,exit:$,className:j.label,transition:h,children:n})})()})]})},$s=({isExtended:e,alignment:t})=>({navigationRail:x("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:x("flex flex-col gap-1 items-start"),menuIcon:"mx-5",segments:x(" flex flex-col overflow-auto min-w-full mt-10",{"w-full":!e,"w-fit items-start":e})}),Ws=ee("navigationRail",$s),Ts=({variant:e="standard",onItemSelected:t,children:n,className:s,selectedItem:r,extended:u,alignment:c="top",menu:l={closed:{icon:ys,label:"Open menu"},opened:{icon:Ee,label:"Close menu"}},style:d,onExtendedChange:o,transition:f,setSelectedItem:y})=>{const[h,m]=i.useState(null),[p,b]=i.useState(u);let w;r==0||r!=null?w=r:w=h;const I=y||m,S=i.useRef(null),g=j=>{t==null||t(j)};function B(j){const $=[];return i.Children.forEach(j,M=>{i.isValidElement(M)&&M.type===i.Fragment?$.push(...B(M.props.children)):$.push(M)}),$}const P=B(n),v=P.filter(j=>i.isValidElement(j)&&j.type===Ie),k=Ws({children:n,onItemSelected:t,selectedItem:w,setSelectedItem:I,className:s,variant:e,extended:p,isExtended:p,alignment:c,menu:l,transition:f,onExtendedChange:o});f={duration:.3,...f};const F=i.useRef(!1);return F.current=!1,i.useEffect(()=>{o==null||o(p??!1)},[p]),a.jsxs("div",{style:{transition:f.duration+"s",...d},ref:S,className:k.navigationRail,children:[a.jsxs("div",{className:k.header,children:[a.jsx(ge,{onClick:()=>b(!p),label:p?l==null?void 0:l.opened.label:l==null?void 0:l.closed.label,className:k.menuIcon,icon:p?l.opened.icon:l==null?void 0:l.closed.icon}),v.length>0&&i.cloneElement(v[0],{transition:f,isExtended:p,className:"!shadow-none mx-5 "+v[0].props.className})]}),a.jsx("div",{className:k.segments,children:(()=>{let j=0;return P.map($=>i.isValidElement($)&&$.type===an?i.cloneElement($,{key:j,index:j++,variant:p?"horizontal":"vertical",selectedItem:w,setSelectedItem:I,onItemSelected:g,transition:f,extendedOnly:F.current,isExtended:p}):i.isValidElement($)&&$.type===Ie?null:i.isValidElement($)&&$.type===ln?(F.current=!0,p?i.cloneElement($,{}):null):$)})()}),a.jsx("div",{className:"flex-1 max-h-[160px]"})]})};function Bs(e){return je.defineConfig({variant:je.Variants.Udixio,...e,plugins:[new je.FontPlugin(e),new tt.TailwindPlugin(e)]})}exports.AnchorPositioner=We;exports.AnimateOnScrollInit=$n;exports.Button=pe;exports.Card=ls;exports.Carousel=as;exports.CarouselItem=Qt;exports.Checkbox=xs;exports.Chip=Ae;exports.Chips=Ss;exports.CustomScroll=it;exports.DatePicker=on;exports.Divider=Oe;exports.Fab=Ie;exports.FabMenu=Ns;exports.Icon=ae;exports.IconButton=ge;exports.NavigationRail=Ts;exports.NavigationRailItem=an;exports.NavigationRailSection=ln;exports.ProgressIndicator=Zt;exports.RippleEffect=nt;exports.SideSheet=ks;exports.Slider=Es;exports.SmoothScroll=jn;exports.Snackbar=Ls;exports.State=fe;exports.Switch=js;exports.SyncedFixedWrapper=ut;exports.Tab=sn;exports.TabGroup=Ms;exports.TabPanel=rn;exports.TabPanels=Cs;exports.Tabs=Is;exports.TextField=As;exports.ThemeProvider=Cn;exports.Tooltip=Ve;exports.animateOnScroll=Wn;exports.buttonStyle=Tn;exports.cardStyle=Bn;exports.carouselItemConfig=Te;exports.carouselItemStyle=Hn;exports.carouselStyle=On;exports.checkboxStyle=Vn;exports.chipStyle=zn;exports.chipsStyle=Yn;exports.classNames=x;exports.classnames=rt;exports.createUseClassNames=ee;exports.customScrollStyle=ot;exports.defaultClassNames=ne;exports.defineConfig=Bs;exports.dividerStyle=_n;exports.fabMenuStyle=Xn;exports.fabStyle=qn;exports.getClassNames=Me;exports.iconButtonStyle=Un;exports.initAnimateOnScroll=$e;exports.normalize=ve;exports.progressIndicatorStyle=Kn;exports.sideSheetConfig=Be;exports.sideSheetStyle=Ft;exports.sliderConfig=He;exports.sliderStyle=Jn;exports.snackbarStyle=Zn;exports.switchStyle=Qn;exports.tabPanelStyle=ss;exports.tabPanelsStyle=ns;exports.tabStyle=es;exports.tabsStyle=ts;exports.textFieldStyle=rs;exports.toolStyle=os;exports.useButtonStyle=ft;exports.useCardStyle=mt;exports.useCarouselItemStyle=pt;exports.useCarouselStyle=xt;exports.useCheckboxStyle=gt;exports.useChipStyle=bt;exports.useChipsStyle=Nt;exports.useClassNames=yn;exports.useDividerStyle=kt;exports.useFabMenuStyle=Mt;exports.useFabStyle=jt;exports.useIconButtonStyle=Rt;exports.useProgressIndicatorStyle=At;exports.useSideSheetStyle=Gn;exports.useSliderStyle=Pt;exports.useSnackbarStyle=Wt;exports.useStateStyle=ct;exports.useSwitchStyle=Bt;exports.useTabPanelStyle=Xt;exports.useTabPanelsStyle=_t;exports.useTabStyle=Ot;exports.useTabsStyle=zt;exports.useTextFieldStyle=Kt;exports.useToolTipStyle=Jt;exports.useTooltipTrigger=nn;
|