@zuzjs/ui 1.0.57 → 1.0.59

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -1,14 +1,14 @@
1
- 'use strict';var chunkCKUNYZUA_cjs=require('./chunk-CKUNYZUA.cjs'),react=require('react'),hooks=require('@zuzjs/hooks'),reactDom=require('react-dom'),core=require('@zuzjs/core'),jsxRuntime=require('react/jsx-runtime'),react$1=require('@zuzjs/core/react'),dateFns=require('date-fns');/* ZuzJS UI CLI */
2
- var Cr={Circle:"CIRCLE",Square:"SQUARE"},af={Default:"DEFAULT",Circle:"CIRCLE"},lf={Light:"light",Dark:"dark",System:"system"},Oe={Default:"DEFAULT",Switch:"SWITCH"},pt={Auto:"auto",Top:"top",Bottom:"bottom",Left:"left",Right:"right"},de=pt,ut=hooks.AnchorType,cf=ut,W={XSmall:"xs",Small:"sm",Medium:"md",Large:"lg",XLarge:"xl"},mf={Asc:"ASC",Desc:"DESC"},pf={String:"STRING",Number:"NUMBER",Boolean:"BOOLEAN",Array:"ARRAY",Object:"OBJECT",Date:"DATE",Time:"TIME",DateTime:"DATETIME",File:"FILE"},uf={Dots:"DOTS"},Ke={IPV4:"IPV4",IPV6:"IPV6",Email:"EMAIL",Uri:"URI",Password:"PASSWORD",MatchField:"MATCHFIELD",Pattern:"*",GreaterThan:"GREATER_THAN",NotEmpty:"NOT_EMPTY",NotMinusOne:"NOT_MINUS_ONE"},Pe={Success:"success",Error:"error",Warning:"warning",Info:"info"},te={Spring:"SPRING",Liquid:"LIQUID",EaseInOut:"EASEINOUT",EaseOutBack:"EASEOUTBACK",Bounce:"BOUNCE"},j={FadeIn:"FADE_IN",ScaleIn:"SCALE_IN",SlideInTop:"SLIDE_FROM_TOP",SlideInRight:"SLIDE_FROM_RIGHT",SlideInBottom:"SLIDE_FROM_BOTTOM",SlideInTopScale:"SLIDE_FROM_BOTTOM_SCALE",SlideInBottomScale:"SLIDE_FROM_BOTTOM_SCALE",SlideInLeft:"SLIDE_FROM_LEFT"},ff={Success:"success",Error:"error",Idle:"idle",Dead:"dead"},Re={Dialog:"DIALOG",Default:"DEFAULT",Error:"ERROR",Success:"SUCCESS",Warn:"WARN",Promise:"PROMISE"},et=Re,lo={Left:"LEFT",Right:"RIGHT",Center:"CENTER"},Tr=lo,df={Bar:"BAR",Ring:"RING"},co={Default:"range",Text:"number"},mo={Default:"DEFAULT",Card:"CARD"},kt={Gooey:"gooey"},ve={Left:"LEFT",Right:"RIGHT",Top:"TOP",Bottom:"BOTTOM"};var Pr=Symbol.for("zuz.global.map"),Rr=e=>{globalThis[Pr]=e;},Ma=()=>globalThis[Pr]||{},po=e=>{let r=Array.isArray(e)?e.join(" "):e;if(!r||typeof r!="string")return "";let t=Ma();return process.env.NODE_ENV==="development"&&Object.keys(t).length===0&&console.warn(`[${chunkCKUNYZUA_cjs.f}] No utility map detected. Classes will not be hashed. `,"Ensure you call setZuzMap() or use <ThemeProvider zuzMap={...} />."),chunkCKUNYZUA_cjs.h(r).filter(Boolean).map(o=>{let s=o.match(/^([&@][\w-]+)\((.*)\)$/);if(s){let[a,i,f]=s;return chunkCKUNYZUA_cjs.h(f).map(c=>{let l=`${i}(${c})`;return t[l]||c}).join(" ")}return t[o]||o}).join(" ")},Mf=e=>{let r=Array.isArray(e)?e.join(" "):e;return !r||typeof r!="string"?"":po(r)},Ir=e=>{let r={};for(let t in e){let n=e[t];if(t.startsWith("--")){r[t]=n;continue}let o=chunkCKUNYZUA_cjs.e[t]?.toString()??t;if(o==="x"||o==="translateX"){let s=r.translate?.split(" ")??["0px","0px"];r.translate=`${chunkCKUNYZUA_cjs.i.addUnitsSafely(t,n)} ${s[1]??"0px"}`;}else if(o==="y"||o==="translateY"){let s=r.translate?.split(" ")??["0px","0px"];r.translate=`${s[0]??"0px"} ${chunkCKUNYZUA_cjs.i.addUnitsSafely(t,n)}`;}else chunkCKUNYZUA_cjs.d.includes(o)?r[o]=chunkCKUNYZUA_cjs.i.addUnitsSafely(t,n):r[o]=n;}return r},uo=e=>{if(!e)return "linear";switch(e.toUpperCase()){case te.Bounce:return "var(--bounce)";case te.Liquid:return "var(--liquid)";case te.Spring:return "var(--spring)";case te.EaseInOut:return "ease-in-out";case te.EaseOutBack:return "ease-out-back";default:return "linear"}},ft=(e,r=0,t=0)=>{let n={},o={},s=r||20,a=t||0;switch(e){case j.SlideInLeft:case j.SlideInRight:n={"--fx-x":e===j.SlideInLeft?`-${s}px`:`${s}px`,opacity:0},o={"--fx-x":`${a}px`,opacity:1};break;case j.SlideInTop:case j.SlideInBottom:n={"--fx-y":e===j.SlideInTop?`-${s}px`:`${s}px`,opacity:0},o={"--fx-y":`${a}px`,opacity:1};break;case j.SlideInTopScale:case j.SlideInBottomScale:n={"--fx-y":e===j.SlideInTopScale?`-${s}px`:`${s}px`,scale:1.1},o={"--fx-y":`${a}px`,scale:1};break;case j.ScaleIn:n={scale:0,opacity:0},o={scale:1,opacity:1};break;case j.FadeIn:n={opacity:0},o={opacity:1};break}return {from:n,to:o}},Of=(e,r,t)=>{let{from:n,to:o}=ft(e);return r?{...n,...o}:t?n:o};var Va=(e,r)=>{let t=react.useRef([]),n=react.useRef(false);return react.useEffect(()=>{e?.when||(n.current=false);},[e?.transition]),react.useEffect(()=>{let o=r?.current;if(!o||!e||!e.clearAtEnd)return;let s=a=>{t.current.includes(a.propertyName)&&e.clearAtEnd===true&&(o.style.transform="",o.style.filter="",t.current.forEach(i=>o.style.removeProperty(i)));};return o.addEventListener("transitionend",s),()=>o.removeEventListener("transitionend",s)},[e,r]),react.useEffect(()=>{if(typeof window>"u"||!r?.current)return;let o=r.current;(e?.scroll||e?.mouse)&&(o.style.willChange="transform",o.style.translate="var(--fx-x, 0px) var(--fx-y, 0px)",o.style.transition=`translate 0.1s ${e.curve?uo(e.curve):"var(--spring)"}`);},[e,r]),react.useMemo(()=>{if(!e)return {style:{}};let{transition:o,from:s,to:a,exit:i,when:f,duration:c=.3,delay:l=0,curve:d,margin:p=0,offset:u=20,watch:y=[]}=e,C=f===false&&!n.current;f===true&&(n.current=true);let x={},{from:T,to:S}=o?ft(o,u,p):{from:s||{},to:a||{}};x=f===void 0?{...T,...S}:f?{...S}:i||T;let P=uo(d),g=[],v=Ir(x);t.current=Object.keys(v);let h={...v};return Object.keys(v).forEach(b=>{let I=b.startsWith("--")?"all":b;g.includes(I)||g.push(`${I} ${c}s ${P} ${l}s`);}),y.forEach(b=>{g.includes(b)||g.push(`${b} 0.1s ${P} 0s`);}),{style:{...h,transition:C?"none":g.join(", "),opacity:C?0:h.opacity,pointerEvents:C?"none":h.pointerEvents}}},[e,e?.when,e?.watch])},ge=Va;var Lt=null,Da=(e,r)=>{let{as:t,fx:n,busy:o=false,stripes:s,transition:a,skeleton:i,className:f,propsToRemove:c,draggable:l,dragOptions:d,style:p,...u}=e||{},y=typeof window<"u",C={},x={};if(l&&y&&!Lt&&(import('@zuzjs/hooks').then(v=>{Lt=v.useDrag;}).catch(v=>{console.error("Error loading useDrag:",v);}),Lt)){let v=Lt(d);C={onMouseDown:v.onMouseDown},x={transform:`translate(${v.position.x}px, ${v.position.y}px)`};}let T=[f,o===true?"--is-busy":"",s?`--has-stripes --stripes-${s}`:""].filter(Boolean).join(" "),S=a?{transition:a,duration:.3}:n||{},{style:P}=ge(S,r),g=po(t??"");return {style:{...p,...P,...x},className:[T,g||"",i?.enabled?"--skeleton":"",l?"--draggable":""].join(" ").trim(),rest:{...C,...chunkCKUNYZUA_cjs.g(u,c?[...c,"skeleton"]:["skeleton"])}}},N=Da;var Er="(prefers-color-scheme: dark)",$a=typeof window>"u",Lr=react.createContext(void 0),yo=e=>{let r=react.useContext(Lr);if(!r){if(e===true)return;throw new Error("useColorScheme must be used within a ThemeProvider")}return r},Q=yo,za=({children:e,storageKey:r="--ucs",forceTheme:t,zuzMap:n,...o})=>(n&&Rr(n),jsxRuntime.jsx(Fa,{storageKey:r,forceTheme:t,...o,children:e})),Fa=({children:e,storageKey:r,forceTheme:t,...n})=>{let[o,s]=react.useState(()=>t||kr(r,"system")),[a,i]=react.useState(()=>t||kr(r)),f=p=>(p||(p=window.matchMedia(Er)),p.matches?"dark":"light"),c=react.useCallback(p=>{let u=p=="system"?f():p,y=document.documentElement;y.setAttribute("color-scheme",u),y.style.colorScheme=u,i(u);},[f]),l=react.useCallback(p=>{s(p),localStorage.setItem(r,p),c(p);},[o]),d=react.useCallback(p=>{let u=f(p);i(u),o==="system"&&c("system");},[o]);return react.useEffect(()=>{o==null&&window.localStorage.getItem(r);},[o]),react.useEffect(()=>{window.matchMedia(Er).addEventListener("change",d);},[d]),react.useEffect(()=>{let p=u=>{u.key==r&&(u.newValue?l(u.newValue):l("system"));};return window.addEventListener("storage",p),()=>window.removeEventListener("storage",p)},[l]),react.useEffect(()=>{c(t||o||"system");},[o]),jsxRuntime.jsxs(Lr,{value:{colorScheme:o,resolvedScheme:a,setColorScheme:l,...n},children:[t?null:jsxRuntime.jsx("script",{suppressHydrationWarning:true,dangerouslySetInnerHTML:{__html:`const el = document.documentElement
1
+ 'use strict';var chunkT2RBNOBB_cjs=require('./chunk-T2RBNOBB.cjs'),react=require('react'),hooks=require('@zuzjs/hooks'),reactDom=require('react-dom'),core=require('@zuzjs/core'),jsxRuntime=require('react/jsx-runtime'),react$1=require('@zuzjs/core/react'),dateFns=require('date-fns');/* ZuzJS UI CLI */
2
+ var kr={Circle:"CIRCLE",Square:"SQUARE"},bf={Default:"DEFAULT",Circle:"CIRCLE"},vf={Light:"light",Dark:"dark",System:"system"},$e={Default:"DEFAULT",Switch:"SWITCH"},xt={Auto:"auto",Top:"top",Bottom:"bottom",Left:"left",Right:"right"},he=xt,bt=hooks.AnchorType,Sf=bt,U={XSmall:"xs",Small:"sm",Medium:"md",Large:"lg",XLarge:"xl"},wf={Asc:"ASC",Desc:"DESC"},Cf={String:"STRING",Number:"NUMBER",Boolean:"BOOLEAN",Array:"ARRAY",Object:"OBJECT",Date:"DATE",Time:"TIME",DateTime:"DATETIME",File:"FILE"},Tf={Dots:"DOTS"},Xe={IPV4:"IPV4",IPV6:"IPV6",Email:"EMAIL",Uri:"URI",Password:"PASSWORD",MatchField:"MATCHFIELD",Pattern:"*",GreaterThan:"GREATER_THAN",NotEmpty:"NOT_EMPTY",NotMinusOne:"NOT_MINUS_ONE"},Ie={Success:"success",Error:"error",Warning:"warning",Info:"info"},ee={Spring:"SPRING",Liquid:"LIQUID",EaseInOut:"EASEINOUT",EaseOutBack:"EASEOUTBACK",Bounce:"BOUNCE"},Y={FadeIn:"FADE_IN",ScaleIn:"SCALE_IN",SlideInTop:"SLIDE_FROM_TOP",SlideInRight:"SLIDE_FROM_RIGHT",SlideInBottom:"SLIDE_FROM_BOTTOM",SlideInTopScale:"SLIDE_FROM_BOTTOM_SCALE",SlideInBottomScale:"SLIDE_FROM_BOTTOM_SCALE",SlideInLeft:"SLIDE_FROM_LEFT"},Pf={Success:"success",Error:"error",Idle:"idle",Dead:"dead"},Ne={Dialog:"DIALOG",Default:"DEFAULT",Error:"ERROR",Success:"SUCCESS",Warn:"WARN",Promise:"PROMISE"},st=Ne,xo={Left:"LEFT",Right:"RIGHT",Center:"CENTER"},Lr=xo,Rf={Bar:"BAR",Ring:"RING"},bo={Default:"range",Text:"number"},vo={Default:"DEFAULT",Card:"CARD"},At={Gooey:"gooey"},Se={Left:"LEFT",Right:"RIGHT",Top:"TOP",Bottom:"BOTTOM"};var Mr=Symbol.for("zuz.global.map"),Or=e=>{globalThis[Mr]=e;},qa=()=>globalThis[Mr]||{},So=e=>{let r=Array.isArray(e)?e.join(" "):e;if(!r||typeof r!="string")return "";let t=qa();return process.env.NODE_ENV==="development"&&Object.keys(t).length===0&&console.warn(`[${chunkT2RBNOBB_cjs.f}] No utility map detected. Classes will not be hashed. `,"Ensure you call setZuzMap() or use <ThemeProvider zuzMap={...} />."),chunkT2RBNOBB_cjs.h(r).filter(Boolean).map(o=>{let s=o.match(/^([&@][\w-]+)\((.*)\)$/);if(s){let[a,l,f]=s;return chunkT2RBNOBB_cjs.h(f).map(c=>{let i=`${l}(${c})`;return t[i]||c}).join(" ")}return t[o]||o}).join(" ")},Wf=e=>{let r=Array.isArray(e)?e.join(" "):e;return !r||typeof r!="string"?"":So(r)},Vr=e=>{let r={};for(let t in e){let n=e[t];if(t.startsWith("--")){r[t]=n;continue}let o=chunkT2RBNOBB_cjs.e[t]?.toString()??t;if(o==="x"||o==="translateX"){let s=r.translate?.split(" ")??["0px","0px"];r.translate=`${chunkT2RBNOBB_cjs.i.addUnitsSafely(t,n)} ${s[1]??"0px"}`;}else if(o==="y"||o==="translateY"){let s=r.translate?.split(" ")??["0px","0px"];r.translate=`${s[0]??"0px"} ${chunkT2RBNOBB_cjs.i.addUnitsSafely(t,n)}`;}else chunkT2RBNOBB_cjs.d.includes(o)?r[o]=chunkT2RBNOBB_cjs.i.addUnitsSafely(t,n):r[o]=n;}return r},wo=e=>{if(!e)return "linear";switch(e.toUpperCase()){case ee.Bounce:return "var(--bounce)";case ee.Liquid:return "var(--liquid)";case ee.Spring:return "var(--spring)";case ee.EaseInOut:return "ease-in-out";case ee.EaseOutBack:return "ease-out-back";default:return "linear"}},vt=(e,r=0,t=0)=>{let n={},o={},s=r||20,a=t||0;switch(e){case Y.SlideInLeft:case Y.SlideInRight:n={"--fx-x":e===Y.SlideInLeft?`-${s}px`:`${s}px`,opacity:0},o={"--fx-x":`${a}px`,opacity:1};break;case Y.SlideInTop:case Y.SlideInBottom:n={"--fx-y":e===Y.SlideInTop?`-${s}px`:`${s}px`,opacity:0},o={"--fx-y":`${a}px`,opacity:1};break;case Y.SlideInTopScale:case Y.SlideInBottomScale:n={"--fx-y":e===Y.SlideInTopScale?`-${s}px`:`${s}px`,scale:1.1},o={"--fx-y":`${a}px`,scale:1};break;case Y.ScaleIn:n={scale:0,opacity:0},o={scale:1,opacity:1};break;case Y.FadeIn:n={opacity:0},o={opacity:1};break}return {from:n,to:o}},Gf=(e,r,t)=>{let{from:n,to:o}=vt(e);return r?{...n,...o}:t?n:o};var Ya=(e,r)=>{let t=react.useRef([]),n=react.useRef(false);return react.useEffect(()=>{e?.when||(n.current=false);},[e?.transition]),react.useEffect(()=>{let o=r?.current;if(!o||!e||!e.clearAtEnd)return;let s=a=>{t.current.includes(a.propertyName)&&e.clearAtEnd===true&&(o.style.transform="",o.style.filter="",t.current.forEach(l=>o.style.removeProperty(l)));};return o.addEventListener("transitionend",s),()=>o.removeEventListener("transitionend",s)},[e,r]),react.useEffect(()=>{if(typeof window>"u"||!r?.current)return;let o=r.current;(e?.scroll||e?.mouse)&&(o.style.willChange="transform",o.style.translate="var(--fx-x, 0px) var(--fx-y, 0px)",o.style.transition=`translate 0.1s ${e.curve?wo(e.curve):"var(--spring)"}`);},[e,r]),react.useMemo(()=>{if(!e)return {style:{}};let{transition:o,from:s,to:a,exit:l,when:f,duration:c=.3,delay:i=0,curve:d,margin:u=0,offset:m=20,watch:h=[]}=e,C=f===false&&!n.current;f===true&&(n.current=true);let x={},{from:T,to:S}=o?vt(o,m,u):{from:s||{},to:a||{}};x=f===void 0?{...T,...S}:f?{...S}:l||T;let P=wo(d),g=[],v=Vr(x);t.current=Object.keys(v);let y={...v};return Object.keys(v).forEach(b=>{let I=b.startsWith("--")?"all":b;g.includes(I)||g.push(`${I} ${c}s ${P} ${i}s`);}),h.forEach(b=>{g.includes(b)||g.push(`${b} 0.1s ${P} 0s`);}),{style:{...y,transition:C?"none":g.join(", "),opacity:C?0:y.opacity,pointerEvents:C?"none":y.pointerEvents}}},[e,e?.when,e?.watch])},ye=Ya;var $t=null,ja=(e,r)=>{let{as:t,fx:n,busy:o=false,stripes:s,transition:a,skeleton:l,className:f,propsToRemove:c,draggable:i,dragOptions:d,style:u,...m}=e||{},h=typeof window<"u",C={},x={};if(i&&h&&!$t&&(import('@zuzjs/hooks').then(v=>{$t=v.useDrag;}).catch(v=>{console.error("Error loading useDrag:",v);}),$t)){let v=$t(d);C={onMouseDown:v.onMouseDown},x={transform:`translate(${v.position.x}px, ${v.position.y}px)`};}let T=[f,o===true?"--is-busy":"",s?`--has-stripes --stripes-${s}`:""].filter(Boolean).join(" "),S=a?{transition:a,duration:.3}:n||{},{style:P}=ye(S,r),g=So(t??"");return {style:{...u,...P,...x},className:[T,g||"",l?.enabled?"--skeleton":"",i?"--draggable":""].join(" ").trim(),rest:{...C,...chunkT2RBNOBB_cjs.g(m,c?[...c,"skeleton"]:["skeleton"])}}},E=ja;var Ar="(prefers-color-scheme: dark)",ei=typeof window>"u",zr=react.createContext(void 0),Ro=e=>{let r=react.useContext(zr);if(!r){if(e===true)return;throw new Error("useColorScheme must be used within a ThemeProvider")}return r},j=Ro,ti=({children:e,storageKey:r="--ucs",forceTheme:t,zuzMap:n,...o})=>(n&&Or(n),jsxRuntime.jsx(oi,{storageKey:r,forceTheme:t,...o,children:e})),oi=({children:e,storageKey:r,forceTheme:t,...n})=>{let[o,s]=react.useState(()=>t||$r(r,"system")),[a,l]=react.useState(()=>t||$r(r)),f=u=>(u||(u=window.matchMedia(Ar)),u.matches?"dark":"light"),c=react.useCallback(u=>{let m=u=="system"?f():u,h=document.documentElement;h.setAttribute("color-scheme",m),h.style.colorScheme=m,l(m);},[f]),i=react.useCallback(u=>{s(u),localStorage.setItem(r,u),c(u);},[o]),d=react.useCallback(u=>{let m=f(u);l(m),o==="system"&&c("system");},[o]);return react.useEffect(()=>{o==null&&window.localStorage.getItem(r);},[o]),react.useEffect(()=>{window.matchMedia(Ar).addEventListener("change",d);},[d]),react.useEffect(()=>{let u=m=>{m.key==r&&(m.newValue?i(m.newValue):i("system"));};return window.addEventListener("storage",u),()=>window.removeEventListener("storage",u)},[i]),react.useEffect(()=>{c(t||o||"system");},[o]),jsxRuntime.jsxs(zr,{value:{colorScheme:o,resolvedScheme:a,setColorScheme:i,...n},children:[t?null:jsxRuntime.jsx("script",{suppressHydrationWarning:true,dangerouslySetInnerHTML:{__html:`const el = document.documentElement
3
3
  const themes = ['light', 'dark']
4
4
  let theme = localStorage.getItem(\`${r}\`) || "system";
5
5
  if (theme === "system") {
6
6
  theme = window.matchMedia("(prefers-color-scheme: dark)").matches ? "dark" : "light";
7
7
  }
8
8
  document.documentElement.setAttribute("color-scheme", theme);
9
- document.documentElement.style.colorScheme = theme;`}}),jsxRuntime.jsx(xo,{children:e})]})},kr=(e,r)=>{if($a)return;let t;try{t=localStorage.getItem(e)||void 0;}catch{}return t||r};var Mr=({ref:e,...r})=>{let{style:t,...n}=r,{style:o,className:s,rest:a}=N(n);return jsxRuntime.jsx("span",{ref:e,style:t,className:s,...a})};Mr.displayName="Zuz.Span";var ae=Mr;var Vr=react.forwardRef((e,r)=>{let{name:t,pathCount:n,variant:o,color:s,size:a,...i}=e,{variant:f}=Q(true),{className:c,style:l,rest:d}=N(i);return jsxRuntime.jsx("div",{style:{color:s,...l,...a?{fontSize:a}:{}},className:`icon-${t} --icon --${o||f||W.Small} ${c}`.trim(),ref:r,...d,children:Array(n||0).fill(0).map((p,u)=>jsxRuntime.jsx(ae,{className:`path${u+1}`},`${t}-layer-${u}`))})});Vr.displayName="Zuz.Icon";var oe=Vr;var he={Simple:"SIMPLE",Roller:"ROLLER",Wave:"Wave"};var Dr=e=>{let{type:r,variant:t,color:n,...o}=e,{className:s,style:a,rest:i}=N(o),{spinner:f}=Q(true),c=()=>{switch(r||f?.type||he.Simple){case he.Simple:return null;case he.Wave:return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(m,{as:"--bar --bar1"}),jsxRuntime.jsx(m,{as:"--bar --bar2"}),jsxRuntime.jsx(m,{as:"--bar --bar3"})]});case he.Roller:return null}};return jsxRuntime.jsx(m,{className:`${s} --spinner --${(r||f?.type||he.Simple).toLowerCase()} --${t||f?.variant||W.Small}`.trim(),style:{...a},...i,children:c()})};Dr.displayName="Zuz.Spinner";var Se=Dr;var Vt={Loading:"loading",Normal:"normal"};var Ar=({ref:e,...r})=>{let{reset:t,kind:n="solid",variant:o,icon:s,iconSize:a,children:i,withLabel:f,spinner:c,state:l,disabled:d,...p}=r,{style:u,className:y,rest:C}=N(p),{variant:x}=Q(true);return jsxRuntime.jsxs("button",{className:core.removeDuplicateWords(`--button --${n} --${o||x} flex aic ${t?"":"jcc"} ${s?"--with-icon":""} ${y}`).trim().replace(/\s+/g," "),style:u,ref:e,disabled:l==Vt.Loading||r.skeleton?.enabled||d,...C,children:[l==Vt.Loading&&jsxRuntime.jsx(Se,{variant:o||x,type:c||he.Simple}),(!l||l==Vt.Normal)&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[s&&jsxRuntime.jsx(oe,{variant:a,name:s}),f===true?jsxRuntime.jsx(ae,{children:i}):i]})]})};Ar.displayName="Zuz.Button";var Z=Ar;var $r=({ref:e,...r})=>{let{h:t,html:n,children:o,lines:s,tfx:a,delay:i=0,duration:f=.5,stagger:c=.05,repeat:l=true,reveal:d=false,hover:p=false,...u}=r,{style:y,className:C,rest:x}=N(u),T=react.useRef(null),[S,P]=react.useState(false),[g]=hooks.useIntersectionObserver([T],{threshold:[1]}),v=react.useMemo(()=>{if(y?.opacity!==void 0)return y.opacity;if(typeof r.as=="string"){let H=r.as.match(/opacity:([\d.]+)/);if(H)return H[1]}return 1},[r.as,y?.opacity]),h=react.useMemo(()=>a?p?S:d?g===1:true:false,[a,p,S,d,g]);react.useEffect(()=>{e&&(typeof e=="function"?e(T.current):e.current=T.current);},[e]);let b=`h${r.h||1}`,I=react.useMemo(()=>typeof o=="string"?o:Array.isArray(o)&&o.length===1&&typeof o[0]=="string"?o[0]:null,[o]),z=react.useMemo(()=>{let H=Array.isArray(r.as)?r.as.join(" "):r.as||"";return typeof H=="string"&&H.includes("text-clip")},[r.as]);react.useLayoutEffect(()=>{if(!z||!T.current||I===null)return;let H=T.current,k=0,M=0,L=()=>{let B=H.getBoundingClientRect(),G=getComputedStyle(H).backgroundImage,U=B.width;H.querySelectorAll(".--fx-char").forEach(A=>{let K=A.getBoundingClientRect().left-B.left;A.style.backgroundImage=G,A.style.backgroundRepeat="no-repeat",A.style.backgroundSize=`${U}px 100%`,A.style.backgroundPosition=`-${K}px 0`,A.style.backgroundClip="text",A.style.webkitBackgroundClip="text",A.style.color="transparent";});},F=()=>{cancelAnimationFrame(k),cancelAnimationFrame(M),k=requestAnimationFrame(()=>{M=requestAnimationFrame(L);});};F();let R=new ResizeObserver(F);return R.observe(H),typeof document<"u"&&"fonts"in document&&document.fonts?.ready.then(F),window.addEventListener("resize",F),()=>{cancelAnimationFrame(k),cancelAnimationFrame(M),R.disconnect(),window.removeEventListener("resize",F);}},[z,I,a,h]);let E=react.useMemo(()=>n?jsxRuntime.jsx(ae,{dangerouslySetInnerHTML:{__html:n}}):a&&I!==null?I.split("").map((H,k)=>{let M=H===" ",F=["typewriter","reveal","fog","slide","pop"].includes(a)?"1":l?"infinite":"1";return jsxRuntime.jsx(ae,{"data-char":H,className:`--fx-char -fx ${h?`--fx-${a}`:""}`,style:{"--delay":`${i+k*c}s`,"--duration":`${f}s`,"--iteration":F,"--target-opacity":v,display:M?"inline":"inline-block",whiteSpace:"pre",opacity:!h&&a==="typewriter"?0:void 0},children:H},k)}):o,[o,n,a,I,h,i,c,f,l]);return jsxRuntime.jsx(b,{ref:T,onMouseEnter:()=>p&&P(true),onMouseLeave:()=>p&&P(false),style:a?{...y,display:a?"flex":y?.display,flexWrap:a?"wrap":y?.flexWrap,opacity:a&&!h?0:a?1:y?.opacity,transition:a?"opacity 0.4s ease":void 0}:y,className:`${C} ${a?"--text-fx -fx":""}`.trim(),...x,children:E})};$r.displayName="Zuz.Text";var _=$r;var ei=e=>{let{label:r,labelColor:t,icon:n,iconColor:o,index:s,className:a,onSelect:i}=e;return r=="-"?jsxRuntime.jsx(m,{className:"--line"}):jsxRuntime.jsxs(Z,{reset:true,onClick:f=>i?.(e),className:`--item ${a||""}`.trim(),children:[jsxRuntime.jsx(m,{as:"--icon",children:jsxRuntime.jsx(oe,{name:n,className:"--ico",style:o?{color:o}:{}})}),jsxRuntime.jsx(_,{className:"--lbl flex aic",style:t?{color:t}:{},children:r})]})},zr=ei;var Zr=({ref:e,...r})=>{let{id:t,as:n,fx:o,offsetX:s,offsetY:a,parent:i,event:f,arrow:c,when:l,items:d,header:p,footer:u,origin:y=ut.TopRight,...C}=r,[x,T]=react.useState(false),[S,P]=react.useState(d||[]),{position:g,targetRef:v,calculatedAnchor:h}=hooks.useAnchorPosition(i?.current,f,{offsetX:s,offsetY:a,preferredAnchor:y}),I=i&&g.top>i.current.getBoundingClientRect().bottom?"--arrow-top":"--arrow-bottom",z=react.useMemo(()=>{let F=h.toLowerCase();return F.includes("left")?"--arrow-left":F.includes("right")?"--arrow-right":"--arrow-center"},[h]),E=g.top!==0||g.left!==0;react.useEffect(()=>{l&&E?T(true):l||T(false);},[l,E]);let{className:H,style:k,rest:M}=N(C),L=ge({...o?.transition?{transition:o.transition??j.SlideInBottom}:{from:{opacity:0,scale:.8,y:-10},to:{opacity:1,scale:1,y:0}},curve:o?.curve??te.EaseInOut,duration:o?.duration??.05,when:x&&E});return jsxRuntime.jsxs(m,{ref:v,className:`--contextmenu ${c||i!=null?`--has-arrow ${I} ${z}`:""} abs flex cols ${H}`.trim(),"aria-hidden":!x,style:{...k,...L.style,top:g.top,left:g.left,visibility:E?"visible":"hidden",transformOrigin:h},...M,children:[typeof p=="function"?react.createElement(p):p,S.map((F,R)=>jsxRuntime.jsx(zr,{...F,index:R},`context-${F.label.toLowerCase()}-${R}`)),typeof u=="function"?react.createElement(u):u]})};Zr.displayName="Zuz.ContextMenu";var So=Zr;var Kr=react.forwardRef((e,r)=>{let{children:t,fx:n,when:o,fxDelay:s,fxStep:a,classToIgnore:i,...f}=e,c=Q(true),l=hooks.useDelayed(),d=n||c?.group?.fx,p=s||c?.group?.fxDelay,u=a||c?.group?.fxStep,y=i||c?.group?.classToIgnore||"-fx",C=react.useMemo(()=>d?react$1.addPropsToChildren(t,x=>{if(x.type===react.Fragment)return false;let T=x.props||{},S="fx"in T,P="tfx"in T,g=T.as?Array.isArray(T.as)?T.as.join(" "):T.as:T.className||"";return !(typeof g=="string"&&g.includes(y))&&(!S||P)},(x,T)=>{let S=(p??0)+x*(u??.1),P=T.props||{};return "tfx"in P?{delay:(P.delay??0)+S}:{fx:{...d,delay:S,when:o??(n?.when||l)}}}):t,[t,o,l,d,p,u,y,n]);return jsxRuntime.jsx(m,{className:"--group",ref:r,...f,children:C})});Kr.displayName="Zuz.Group";var wo=Kr;var Gr=react.forwardRef((e,r)=>{let{message:t,spinner:n,spinnerSize:o,color:s,when:a,hideMessage:i,...f}=e,{className:c,style:l,rest:d}=N(f),{spinner:p}=Q(true);return "when"in e&&e.when==false?null:jsxRuntime.jsxs(wo,{fx:{transition:j.SlideInBottom,curve:te.Liquid,duration:.5},fxDelay:.1,fxStep:.05,className:`--cover flex aic jcc cols abs fill nope nous ${c}`.trim(),style:{...l,backgroundColor:"var(--cover-bg)"},...d,children:[jsxRuntime.jsx(Se,{variant:o||p?.variant||W.Small,type:n||p?.type||he.Simple}),!i&&jsxRuntime.jsx(_,{className:"--label",tfx:"fade",style:{color:"var(--cover-label)"},children:t||"loading"})]})});Gr.displayName="Zuz.Cover";var Ee=Gr;var Co=class{stack=[];SCROLL_CLASS="--no-scroll";updateScrollLock(){typeof window>"u"||(this.stack.length>0?document.body.classList.add(this.SCROLL_CLASS):document.body.classList.remove(this.SCROLL_CLASS));}isTop(r){return this.stack[this.stack.length-1]===r}push(r){this.stack.includes(r)||(this.stack.push(r),this.updateScrollLock());}pop(r){this.stack=this.stack.filter(t=>t!==r),this.updateScrollLock();}handleEscape(){let r=this.stack[this.stack.length-1];return r?(r(),true):false}get count(){return this.stack.length}},Ie=new Co;var Ur=react.forwardRef((e,r)=>{let{when:t,...n}=e;return jsxRuntime.jsx(m,{ref:r,"aria-hidden":!t,className:"--overlay fixed fill",fx:{transition:j.FadeIn,when:t},...n})});Ur.displayName="Zuz.Overlay";var We=Ur;var yi=({action:e,render:r=true,message:t=""})=>jsxRuntime.jsx(m,{as:`--body flex aic rel ${e?"":"--no-action"}`.trim(),children:r?t:null}),qr=yi;var bi=({action:e,actionPosition:r,dialogID:t,variant:n})=>jsxRuntime.jsx(m,{as:`--footer flex aic rel ${r?r==Tr.Center?"jcc":"":"jce"}`.trim(),children:e.map((o,s)=>jsxRuntime.jsx(Z,{variant:n,onClick:a=>o.handler?o.handler():o.onClick?o.onClick():console.log("onClick Handler missing"),as:"--action",children:o.label},`dialog-${t}-action-${o.key}`))}),Yr=bi;var vi={colorSchemeLight:jsxRuntime.jsxs("svg",{width:"24",height:"24",fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5",color:"currentcolor",shapeRendering:"geometricPrecision",viewBox:"0 0 24 24",children:[jsxRuntime.jsx("circle",{cx:"12",cy:"12",r:"5"}),jsxRuntime.jsx("path",{d:"M12 1v2M12 21v2M4.22 4.22l1.42 1.42M18.36 18.36l1.42 1.42M1 12h2M21 12h2M4.22 19.78l1.42-1.42M18.36 5.64l1.42-1.42"})]}),colorSchemeSystem:jsxRuntime.jsxs("svg",{width:"24",height:"24",fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5",color:"currentcolor",shapeRendering:"geometricPrecision",viewBox:"0 0 24 24",children:[jsxRuntime.jsx("rect",{width:"20",height:"14",x:"2",y:"3",rx:"2",ry:"2"}),jsxRuntime.jsx("path",{d:"M8 21h8M12 17v4"})]}),colorSchemeDark:jsxRuntime.jsx("svg",{width:"24",height:"24",fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5",color:"currentcolor",shapeRendering:"geometricPrecision",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M21 12.79A9 9 0 1 1 11.21 3 7 7 0 0 0 21 12.79"})}),arrowDown:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M17.919 8.18H6.079c-.96 0-1.44 1.16-.76 1.84l5.18 5.18c.83.83 2.18.83 3.01 0l1.97-1.97 3.21-3.21c.67-.68.19-1.84-.77-1.84z"})}),arrowUp:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M18.68 13.978l-3.21-3.21-1.96-1.97a2.13 2.13 0 00-3.01 0l-5.18 5.18c-.68.68-.19 1.84.76 1.84h11.84c.96 0 1.44-1.16.76-1.84z"})}),search:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 34 34",children:jsxRuntime.jsx("path",{d:"M27.414,24.586l-5.077-5.077C23.386,17.928,24,16.035,24,14c0-5.514-4.486-10-10-10S4,8.486,4,14 s4.486,10,10,10c2.035,0,3.928-0.614,5.509-1.663l5.077,5.077c0.78,0.781,2.048,0.781,2.828,0 C28.195,26.633,28.195,25.367,27.414,24.586z M7,14c0-3.86,3.14-7,7-7s7,3.14,7,7s-3.14,7-7,7S7,17.86,7,14z"})}),close:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"})}),eye:jsxRuntime.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:[jsxRuntime.jsx("path",{fill:"#333",d:"M12 20.5c-4.299 0-8.24-3.023-10.544-8.086a1 1 0 010-.828C3.759 6.523 7.701 3.5 12 3.5s8.24 3.023 10.544 8.086a1.001 1.001 0 010 .828 18.14 18.14 0 01-1.391 2.52 1 1 0 11-1.666-1.106A15.87 15.87 0 0020.529 12C18.543 7.92 15.379 5.5 12 5.5S5.457 7.92 3.471 12c1.986 4.08 5.15 6.5 8.529 6.5a7.964 7.964 0 005.036-1.92 1 1 0 111.265 1.55A9.94 9.94 0 0112 20.5z"}),jsxRuntime.jsx("path",{fill:"#333",d:"M12 16a4.004 4.004 0 01-3.929-4.756 1 1 0 011.965.375A2 2 0 1014 12a2.034 2.034 0 00-2.053-1.999 1.04 1.04 0 01-1.043-.947.963.963 0 01.902-1.05L12 8a4 4 0 010 8z"})]}),eyeSlash:jsxRuntime.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:[jsxRuntime.jsx("path",{fill:"#333",d:"M12 15c-4.132 0-7.98-1.214-10.294-3.249a1 1 0 111.32-1.502C4.986 11.972 8.34 13 12 13s7.014-1.028 8.974-2.751a1 1 0 111.32 1.502C19.98 13.786 16.132 15 12 15z"}),jsxRuntime.jsx("path",{fill:"#333",d:"M12 18a1 1 0 01-1-1v-3a1 1 0 012 0v3a1 1 0 01-1 1zM7.749 17.667a.964.964 0 01-.17-.014 1 1 0 01-.817-1.155l.505-2.935a1 1 0 111.97.339l-.504 2.935a1 1 0 01-.984.83zM3.636 16.306a1.001 1.001 0 01-.942-1.336l.978-2.745a1 1 0 111.884.672l-.978 2.745a1 1 0 01-.942.664zM16.251 17.667a1 1 0 01-.984-.83l-.505-2.935a1 1 0 011.97-.339l.506 2.935a1 1 0 01-.816 1.155.964.964 0 01-.17.014zM20.364 16.306a1 1 0 01-.942-.664l-.978-2.745a1 1 0 111.884-.672l.978 2.745a1.001 1.001 0 01-.942 1.336z"})]}),check:jsxRuntime.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:[" ",jsxRuntime.jsx("path",{d:"M9 16.17 4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z"})," "]}),[Pe.Info]:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",children:jsxRuntime.jsx("path",{fill:"#292D32",d:"M21.56 10.738l-1.35-1.58c-.25-.3-.46-.86-.46-1.26v-1.7c0-1.06-.87-1.93-1.93-1.93h-1.7c-.4 0-.97-.21-1.27-.46l-1.58-1.35c-.69-.59-1.82-.59-2.51 0l-1.6 1.35c-.3.25-.86.46-1.26.46H6.17c-1.06 0-1.93.87-1.93 1.93v1.7c0 .39-.2.95-.45 1.25l-1.35 1.59c-.58.7-.58 1.82 0 2.5l1.35 1.59c.25.29.45.86.45 1.25v1.71c0 1.06.87 1.93 1.93 1.93h1.74c.39 0 .96.21 1.26.46l1.58 1.35c.69.59 1.82.59 2.51 0l1.58-1.35c.3-.25.86-.46 1.26-.46h1.7c1.06 0 1.93-.87 1.93-1.93v-1.7c0-.4.21-.96.46-1.26l1.35-1.58c.61-.68.61-1.81.02-2.51zm-10.31-2.61c0-.41.34-.75.75-.75s.75.34.75.75v4.83c0 .41-.34.75-.75.75s-.75-.34-.75-.75v-4.83zm.75 8.74c-.55 0-1-.45-1-1s.44-1 1-1c.55 0 1 .45 1 1s-.44 1-1 1z"})}),[Pe.Warning]:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",children:jsxRuntime.jsx("path",{fill:"#292D32",d:"M19.51 5.85l-5.94-3.43c-.97-.56-2.17-.56-3.15 0L4.49 5.85a3.15 3.15 0 00-1.57 2.73v6.84c0 1.12.6 2.16 1.57 2.73l5.94 3.43c.97.56 2.17.56 3.15 0l5.94-3.43a3.15 3.15 0 001.57-2.73V8.58a3.192 3.192 0 00-1.58-2.73zm-8.26 1.9c0-.41.34-.75.75-.75s.75.34.75.75V13c0 .41-.34.75-.75.75s-.75-.34-.75-.75V7.75zm1.67 8.88c-.05.12-.12.23-.21.33a.99.99 0 01-1.09.21c-.13-.05-.23-.12-.33-.21-.09-.1-.16-.21-.22-.33a.986.986 0 01-.07-.38c0-.26.1-.52.29-.71.1-.09.2-.16.33-.21.37-.16.81-.07 1.09.21.09.1.16.2.21.33.05.12.08.25.08.38s-.03.26-.08.38z"})}),[Pe.Error]:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",children:jsxRuntime.jsx("path",{d:"M1 21h22L12 2 1 21zm12-3h-2v-2h2v2zm0-4h-2v-4h2v4z"})}),[Pe.Success]:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",children:jsxRuntime.jsx("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-2 15l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z"})}),layers:jsxRuntime.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"100%",height:"100%",viewBox:"0 0 24 24",fill:"none",children:[jsxRuntime.jsx("path",{d:"M19.3697 4.89109L13.5097 2.28109C12.6497 1.90109 11.3497 1.90109 10.4897 2.28109L4.62969 4.89109C3.14969 5.55109 2.92969 6.45109 2.92969 6.93109C2.92969 7.41109 3.14969 8.31109 4.62969 8.97109L10.4897 11.5811C10.9197 11.7711 11.4597 11.8711 11.9997 11.8711C12.5397 11.8711 13.0797 11.7711 13.5097 11.5811L19.3697 8.97109C20.8497 8.31109 21.0697 7.41109 21.0697 6.93109C21.0697 6.45109 20.8597 5.55109 19.3697 4.89109Z",fill:"#292D32"}),jsxRuntime.jsx("path",{d:"M12.0003 17.04C11.6203 17.04 11.2403 16.96 10.8903 16.81L4.15031 13.81C3.12031 13.35 2.32031 12.12 2.32031 10.99C2.32031 10.58 2.65031 10.25 3.06031 10.25C3.47031 10.25 3.80031 10.58 3.80031 10.99C3.80031 11.53 4.25031 12.23 4.75031 12.45L11.4903 15.45C11.8103 15.59 12.1803 15.59 12.5003 15.45L19.2403 12.45C19.7403 12.23 20.1903 11.54 20.1903 10.99C20.1903 10.58 20.5203 10.25 20.9303 10.25C21.3403 10.25 21.6703 10.58 21.6703 10.99C21.6703 12.11 20.8703 13.35 19.8403 13.81L13.1003 16.81C12.7603 16.96 12.3803 17.04 12.0003 17.04Z",fill:"#292D32"}),jsxRuntime.jsx("path",{d:"M12.0003 22.0009C11.6203 22.0009 11.2403 21.9209 10.8903 21.7709L4.15031 18.7709C3.04031 18.2809 2.32031 17.1709 2.32031 15.9509C2.32031 15.5409 2.65031 15.2109 3.06031 15.2109C3.47031 15.2109 3.80031 15.5409 3.80031 15.9509C3.80031 16.5809 4.17031 17.1509 4.75031 17.4109L11.4903 20.4109C11.8103 20.5509 12.1803 20.5509 12.5003 20.4109L19.2403 17.4109C19.8103 17.1609 20.1903 16.5809 20.1903 15.9509C20.1903 15.5409 20.5203 15.2109 20.9303 15.2109C21.3403 15.2109 21.6703 15.5409 21.6703 15.9509C21.6703 17.1709 20.9503 18.2709 19.8403 18.7709L13.1003 21.7709C12.7603 21.9209 12.3803 22.0009 12.0003 22.0009Z",fill:"#292D32"})]}),play:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M8 5v14l11-7z"})}),pause:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M6 19h4V5H6zm8-14v14h4V5z"})}),next:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"m6 18 8.5-6L6 6zM16 6v12h2V6z"})}),prev:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M6 6h2v12H6zm3.5 6 8.5 6V6z"})}),volumeHigh:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{fill:"#292D32",d:"M22 11.25h-1.25V10c0-.41-.34-.75-.75-.75s-.75.34-.75.75v1.25H18c-.41 0-.75.34-.75.75s.34.75.75.75h1.25V14c0 .41.34.75.75.75s.75-.34.75-.75v-1.25H22c.41 0 .75-.34.75-.75s-.34-.75-.75-.75M14.02 3.782c-1.12-.62-2.55-.46-4.01.45l-2.92 1.83c-.2.12-.43.19-.66.19H5c-2.42 0-3.75 1.33-3.75 3.75v4c0 2.42 1.33 3.75 3.75 3.75h1.4300000000000002c.23 0 .46.07.66.19l2.92 1.83c.88.55 1.74.82 2.54.82a3 3 0 0 0 1.47-.37c1.11-.62 1.73-1.91 1.73-3.63v-9.18c0-1.72-.62-3.01-1.73-3.63"})}),volumeMute:jsxRuntime.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:[jsxRuntime.jsx("path",{fill:"#292D32",d:"M18 16.75a.75.75 0 0 1-.6-1.2 5.93 5.93 0 0 0 .72-5.84.75.75 0 0 1 .4-.98c.38-.16.82.02.98.4 1.02 2.42.67 5.23-.9 7.33-.15.19-.37.29-.6.29"}),jsxRuntime.jsx("path",{fill:"#292D32",d:"M19.828 19.25a.75.75 0 0 1-.6-1.2c2.14-2.85 2.61-6.67 1.23-9.96a.75.75 0 0 1 .4-.98c.38-.16.82.02.98.4 1.59 3.78 1.05 8.16-1.41 11.44-.14.2-.37.3-.6.3M14.04 12.958c.63-.63 1.71-.18 1.71.71v2.93c0 1.72-.62 3.01-1.73 3.63a3 3 0 0 1-1.47.37c-.8 0-1.66-.27-2.54-.82l-.64-.4c-.54-.34-.63-1.1-.18-1.55zM21.77 2.229c-.3-.3-.79-.3-1.09 0l-4.95 4.95c-.06-1.6-.66-2.8-1.72-3.39-1.12-.62-2.55-.46-4.01.45l-2.91 1.82c-.2.12-.43.19-.66.19H5c-2.42 0-3.75 1.33-3.75 3.75v4c0 2.42 1.33 3.75 3.75 3.75h.16l-2.94 2.94c-.3.3-.3.79 0 1.09.16.14.35.22.55.22s.39-.08.54-.23l18.46-18.46c.31-.3.31-.78 0-1.08"})]}),plus:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",children:jsxRuntime.jsx("path",{d:"M28 14H18V4a2 2 0 0 0-4 0v10H4a2 2 0 0 0 0 4h10v10a2 2 0 0 0 4 0V18h10a2 2 0 0 0 0-4"})}),add:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M12 2C6.49 2 2 6.49 2 12s4.49 10 10 10 10-4.49 10-10S17.51 2 12 2m4 10.75h-3.25V16c0 .41-.34.75-.75.75s-.75-.34-.75-.75v-3.25H8c-.41 0-.75-.34-.75-.75s.34-.75.75-.75h3.25V8c0-.41.34-.75.75-.75s.75.34.75.75v3.25H16c.41 0 .75.34.75.75s-.34.75-.75.75"})}),chevronUp:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"100%",height:"100%",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"m7 14 5-5 5 5z"})}),chevronBottom:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"100%",height:"100%",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"m7 10 5 5 5-5z"})}),chevronRight:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"100%",height:"100%",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"m10 17 5-5-5-5v10z"})}),chevronLeft:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"100%",height:"100%",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"m14 7-5 5 5 5V7z"})}),chevronRightOutline:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"100%",height:"100%",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M8.59 16.59 13.17 12 8.59 7.41 10 6l6 6-6 6-1.41-1.41z"})}),chevronLeftOutline:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"100%",height:"100%",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M15.41 16.59 10.83 12l4.58-4.59L14 6l-6 6 6 6 1.41-1.41z"})}),chevronUpOutline:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"100%",height:"100%",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M7.41 15.41 12 10.83l4.59 4.58L18 14l-6-6-6 6z"})}),chevronDownOutline:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"100%",height:"100%",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M7.41 8.59 12 13.17l4.59-4.58L18 10l-6 6-6-6 1.41-1.41z"})}),bezier:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"100%",height:"100%",viewBox:"0 0 24 24",fill:"none",children:jsxRuntime.jsx("path",{d:"M19.14 7.72C19.43 8.47 20.15 9 21 9C22.1 9 23 8.1 23 7C23 5.9 22.1 5 21 5C20.15 5 19.43 5.53 19.14 6.28C19.09 6.27 19.05 6.25 19 6.25H15V5.5C15 4.68 14.32 4 13.5 4H10.5C9.68 4 9 4.68 9 5.5V6.25H5C4.95 6.25 4.91 6.27 4.86 6.28C4.57 5.53 3.85 5 3 5C1.9 5 1 5.9 1 7C1 8.1 1.9 9 3 9C3.85 9 4.57 8.47 4.86 7.72C4.91 7.73 4.95 7.75 5 7.75H7.57C5.52 9.27 4.25 11.79 4.25 14.5C4.25 14.67 4.26 14.83 4.28 15H4C3.17 15 2.5 15.67 2.5 16.5V18.5C2.5 19.33 3.17 20 4 20H6C6.22 20 6.42 19.95 6.61 19.86C7.13 19.64 7.5 19.11 7.5 18.5V16.5C7.5 15.67 6.83 15 6 15H5.77C5.77 14.97 5.78 14.94 5.78 14.91C5.76 14.77 5.76 14.64 5.76 14.5C5.76 12.03 7.03 9.77 9.02 8.6C9.06 9.37 9.71 10 10.5 10H13.5C14.29 10 14.94 9.37 14.99 8.6C16.98 9.77 18.25 12.04 18.25 14.5C18.25 14.64 18.24 14.77 18.23 14.91C18.23 14.94 18.24 14.97 18.24 15H18C17.17 15 16.5 15.67 16.5 16.5V18.5C16.5 19.11 16.87 19.64 17.39 19.86C17.58 19.95 17.78 20 18 20H20C20.83 20 21.5 19.33 21.5 18.5V16.5C21.5 15.67 20.83 15 20 15H19.72C19.74 14.83 19.75 14.67 19.75 14.5C19.75 11.79 18.48 9.27 16.43 7.75H19C19.05 7.75 19.09 7.73 19.14 7.72Z",fill:"#292D32"})}),mouse:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"100%",height:"100%",viewBox:"0 0 24 24",fill:"none",children:jsxRuntime.jsx("path",{d:"M13.2978 2.11468C13.0064 2.06339 12.75 2.29593 12.75 2.59185V5.45262C12.75 5.65098 12.8709 5.82564 13.0359 5.93583C13.5391 6.27202 13.87 6.84597 13.87 7.49906V9.49906C13.87 10.5291 13.03 11.3791 12 11.3791C10.96 11.3791 10.12 10.5291 10.12 9.49906V7.49906C10.12 6.84578 10.4583 6.27168 10.9639 5.93554C11.1291 5.82572 11.25 5.65098 11.25 5.45262V2.59249C11.25 2.29634 10.9935 2.0637 10.7019 2.11513C9.15243 2.38834 7.76579 3.13327 6.7 4.19906C5.34 5.55906 4.5 7.43906 4.5 9.49906V14.4991C4.5 18.6291 7.87 21.9991 12 21.9991C16.13 21.9991 19.5 18.6291 19.5 14.4991V9.49906C19.5 5.80857 16.813 2.73328 13.2978 2.11468Z",fill:"#292D32"})}),addKey:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"100%",height:"100%",viewBox:"0 0 24 24",fill:"none",children:jsxRuntime.jsx("path",{d:"M20.9498 14.55L14.5598 20.94C13.1598 22.34 10.8598 22.34 9.44977 20.94L3.05977 14.55C1.65977 13.15 1.65977 10.85 3.05977 9.44L9.44977 3.05C10.8498 1.65 13.1498 1.65 14.5598 3.05L20.9498 9.44C22.3498 10.85 22.3498 13.15 20.9498 14.55Z",fill:"#292D32"})}),calendar:jsxRuntime.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:[jsxRuntime.jsx("path",{fill:"#292D32",d:"M8.25 5.75c-.41 0-.75-.34-.75-.75V2c0-.41.34-.75.75-.75S9 1.59 9 2v3c0 .41-.34.75-.75.75M15.75 5.75c-.41 0-.75-.34-.75-.75V2c0-.41.34-.75.75-.75s.75.34.75.75v3c0 .41-.34.75-.75.75M12 14.09c.52 0 .9-.31.9-.8 0-.5-.38-.79-.9-.79s-.9.29-.9.79c0 .49.38.8.9.8M12 17c.629 0 1.14-.416 1.14-.93 0-.513-.511-.93-1.14-.93-.63 0-1.14.417-1.14.93s.51.93 1.14.93"}),jsxRuntime.jsx("path",{fill:"#292D32",d:"M19.57 4.5c-.66-.49-1.61-.02-1.61.81v.1c0 1.17-.84 2.25-2.01 2.37-1.35.14-2.49-.92-2.49-2.24V4.5c0-.55-.45-1-1-1h-.92c-.55 0-1 .45-1 1v1.04c0 .79-.41 1.49-1.03 1.88-.09.06-.19.11-.29.16q-.135.075-.3.12c-.12.04-.25.07-.39.08q-.24.03-.48 0c-.14-.01-.27-.04-.39-.08q-.15-.045-.3-.12c-.1-.05-.2-.1-.29-.16-.63-.44-1.03-1.2-1.03-2.01v-.1c0-.77-.82-1.23-1.47-.9-.01.01-.02.01-.03.02-.04.02-.07.04-.11.07-.03.03-.07.05-.1.08-.28.22-.53.47-.74.74-.11.12-.2.25-.28.38a3.498 3.498 0 0 0-.27.46c-.02.02-.03.03-.03.05-.06.12-.12.24-.16.37-.03.05-.04.09-.06.14-.06.15-.1.3-.14.45-.04.14-.07.29-.09.44a5.902 5.902 0 0 0-.06.76v8.76A4.87 4.87 0 0 0 7.37 22h9.26a4.87 4.87 0 0 0 4.87-4.87V8.37c0-1.59-.76-2.98-1.93-3.87M12 18.25c-1.55 0-2.5-.77-2.5-2.01 0-.68.35-1.27.96-1.62-.44-.31-.73-.77-.73-1.4 0-1.3 1.04-1.97 2.27-1.97s2.26.67 2.26 1.97c0 .63-.28 1.09-.73 1.4.62.35.97.94.97 1.62 0 1.24-.96 2.01-2.5 2.01"})]}),done:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M9 16.2 4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4z"})}),doneAll:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"m18 7-1.41-1.41-6.34 6.34 1.41 1.41zm4.24-1.41L11.66 16.17 7.48 12l-1.41 1.41L11.66 19l12-12zM.41 13.41 6 19l1.41-1.41L1.83 12z"})}),pending:jsxRuntime.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:[jsxRuntime.jsx("path",{d:"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2M12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8"}),jsxRuntime.jsx("path",{d:"M12.5 7H11v6l5.25 3.15.75-1.23-4.5-2.67z"})]})},O=vi;var Si=({title:e="Alert",onClose:r})=>jsxRuntime.jsxs(m,{as:"--head flex aic rel",children:[jsxRuntime.jsx(m,{as:`--${e?"title":"dot"} flex aic jcc rel`,children:e}),jsxRuntime.jsx(Z,{onClick:t=>r(),className:"--closer abs center-v",children:O.close})]}),Qr=Si;var tn=({ref:e,...r})=>{let{index:t,id:n,title:o,message:s,transition:a,curve:i,speed:f,type:c,action:l,actionPosition:d,spinner:p,loadingMessage:u,variant:y,inBackground:C,forceClose:x,forceLoading:T,onClose:S,onShow:P,onHide:g,...v}=r,h=react.useMemo(()=>core.uuid(12),[]),[b,I]=react.useState(o||""),[z,E]=react.useState(s||""),[H,k]=react.useState(c||et.Dialog),[M,L]=react.useState(false),[F,R]=react.useState(true),[B,G]=react.useState(l||null),[U,D]=react.useState(false),{variant:A,spinner:q,dialog:K}=Q(true),J=y||K?.variant||A||W.Small,{style:ee,className:ie,rest:me}=N(v),ye=react.useRef(null),se=ge({when:M,duration:f||K?.speed||.3,delay:K?.delay||.1,transition:a||K?.transition||j.SlideInBottom,curve:i||K?.curve||te.EaseInOut,watch:["scale","filter","transform"]}),le=()=>{L(false),S(n);},Y=react.useMemo(()=>[{keys:[hooks.KeyCode.Escape],callback:()=>{Ie.isTop(le)&&le();}}],[M]);hooks.useShortcuts(Y),react.useEffect(()=>{k(et.Dialog),E(s),I(b),B&&G(B.reduce((ne,ue)=>(ne.push({...ue,key:ue.key||core.uuid(12)}),ne),[])),L(true),setTimeout(()=>P?P():()=>{},500);},[]),react.useEffect(()=>{x&&le();},[x]),react.useEffect(()=>{T!=null&&D(T);},[T]),react.useEffect(()=>(M?Ie.push(le):Ie.pop(le),()=>Ie.pop(le)),[M]);let re=react.useMemo(()=>1e4+t*10,[t]);return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(We,{style:{zIndex:re},when:M}),jsxRuntime.jsxs(m,{as:`--dialog --${(c??et.Default).toLowerCase()} ${M?"--visible":""} ${ie} fixed abc`.trim(),style:{...se.style,zIndex:re+1,pointerEvents:C==true?"none":"auto",...C==true?{scale:"0.92",filter:"blur(2px)"}:{}},...me,ref:ye,children:[jsxRuntime.jsx(Qr,{title:b,onClose:le}),jsxRuntime.jsx(qr,{message:z,render:F,action:B}),B&&B.length>0&&jsxRuntime.jsx(Yr,{variant:J,action:B,dialogID:h,actionPosition:d}),jsxRuntime.jsx(Ee,{when:U,spinner:p||K?.spinner||q?.type||he.Simple,message:u||K?.loadingMessage})]})]})};tn.displayName="Zuz.Dialog";var Po=tn;var on=react.forwardRef((e,r)=>{let{speed:t,smooth:n=false,breakpoints:o={},style:s,...a}=e,{rootRef:i,containerRef:f,thumbY:c,thumbX:l,onScrollY:d,onScrollX:p}=hooks.useScrollbar(t||1,o,n),{style:u,className:y,rest:C}=N(a);return react.useEffect(()=>{let x=f.current;if(!x)return;let T=()=>{window.dispatchEvent(new Event("resize"));},S=P=>{let g=P.target;if(g.closest(".--allow-scroll")){let h=g.closest(".--allow-scroll"),{scrollTop:b,scrollHeight:I,clientHeight:z}=h,E=P.deltaY<0,H=P.deltaY>0;(E&&b>0||H&&b+z<I)&&P.stopPropagation();}};return x.addEventListener("scroll",T),x.addEventListener("wheel",S,{passive:true}),()=>{x.removeEventListener("scroll",T),x.removeEventListener("wheel",S);}},[f]),jsxRuntime.jsxs(m,{ref:i,className:y.trim(),as:"--scrollview rel",children:[jsxRuntime.jsx(m,{as:`--scroll-content ${y}`.trim(),ref:f,style:s||{},children:C.children}),jsxRuntime.jsx(m,{as:"--scroll-track --track-y --abs",children:jsxRuntime.jsx(m,{as:"--scroll-thumb --abs",ref:c,onMouseDown:d})}),jsxRuntime.jsx(m,{as:"--scroll-track --track-x --abs",children:jsxRuntime.jsx(m,{as:"--scroll-thumb --abs",ref:l,onMouseDown:p})})]})});on.displayName="Zuz.ScrollView";var Ro=on;var rn=({ref:e,...r})=>{let{id:t,index:n,from:o,speed:s,children:a,margin:i,animation:f,prerender:c,inBackground:l,forceClose:d,forceLoading:p,onClose:u,...y}=r,{drawer:C}=Q(true),[x,T]=react.useState(a),[S,P]=react.useState(false),[g,v]=react.useState(c??(C?.prerender||true)),[h,b]=react.useState(false),I=()=>{P(false),u?.(t??-1);},{className:z,style:E,rest:H}=N(y),k=react.useMemo(()=>[{keys:[hooks.KeyCode.Escape],callback:()=>{Ie.isTop(I)&&I();}}],[S]);hooks.useShortcuts(k),react.useEffect(()=>{T(a);},[a]),react.useEffect(()=>(S?Ie.push(I):Ie.pop(I),()=>Ie.pop(I)),[S]),react.useEffect(()=>{P(true);},[]),react.useEffect(()=>{d&&I();},[d]),react.useEffect(()=>{p!=null&&b(p);},[p]);let M=o||C?.from||ve.Left,L=react.useMemo(()=>{switch(M){case ve.Left:return {from:{x:"-100vw"},to:{x:0}};case ve.Right:return {from:{x:"100vw"},to:{x:0}};case ve.Top:return {from:{y:"-100vh"},to:{y:0}};case ve.Bottom:return {from:{y:"100vh"},to:{y:0}};default:return {from:{x:"-100vw"},to:{x:0}}}},[o,C?.from]),F=ge({from:{...L.from,opacity:0},to:{...L.to,opacity:1},when:S,curve:f||C?.animation||te.EaseInOut,duration:s||C?.speed||.5,watch:["scale","filter"]}),R=react.useMemo(()=>1e4+(n||1)*10,[n]);return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(We,{onClick:B=>{S&&I();},when:S,style:{zIndex:R}}),jsxRuntime.jsxs(m,{ref:e,"aria-hidden":!S,className:`--drawer flex cols ${z} --${M.toLowerCase()} fixed`,style:{...E,...F.style,"--m":`${i||C?.margin||0}px`,zIndex:R+1,pointerEvents:l==true?"none":"auto",...l==true?{scale:"0.92",filter:"blur(2px)"}:{}},...H,children:[o==ve.Top||o==ve.Bottom?jsxRuntime.jsx(m,{className:"--handle"}):null,jsxRuntime.jsx(Z,{as:"--close-drawer --abs",onClick:I,children:O.close}),jsxRuntime.jsxs(Ro,{as:"rel",children:[g||S?x:null,jsxRuntime.jsx(Ee,{when:h})]})]})]})};rn.displayName="Zuz.Drawer";var Bo=rn;var sn=react.forwardRef((e,r)=>{let{progress:t,type:n,animated:o,...s}=e,a=react.useRef(null);react.useImperativeHandle(r,()=>({setProgress:l=>{a.current.style.width=`${l*100}%`,a.current.setAttribute("data-value",l+"");},getProgress:()=>+(a.current.getAttribute("data-value")||0)}),[]),react.useEffect(()=>{t&&a.current&&(o?setTimeout(()=>a.current.style.width=`${t*100}%`,500):a.current.style.width=`${t*100}%`,a.current.setAttribute("data-value",t+""));},[t,a.current]);let{className:i,style:f,rest:c}=N(s);return jsxRuntime.jsx(m,{className:`--progress ${o?"--animated":""} flex rel ${i}`.trim(),style:f,...c,children:jsxRuntime.jsx(m,{ref:a,className:"--bar rel"})})});sn.displayName="Zuz.ProgressBar";var Ue=sn;var zt=(s=>(s.Default="default",s.Success="success",s.Error="error",s.Warn="warn",s.Promise="promise",s))(zt||{}),Ft=(a=>(a.TopLeft="TopLeft",a.TopCenter="TopCenter",a.TopRight="TopRight",a.BottomLeft="BottomLeft",a.BottomCenter="BottomCenter",a.BottomRight="BottomRight",a))(Ft||{}),an=(t=>(t.Stack="stack",t.Individual="individual",t))(an||{}),ln={success:"Action Successful",error:"Something Went Wrong",warn:"Heads Up",default:"Notice"};var Ai=e=>{let{index:r,id:t,type:n,icon:o,busy:s,width:a,title:i,message:f,duration:c,sticky:l=false,actions:d=[],position:p,style:u,isHovered:y,total:C,progress:x,progressValue:T,forceClose:S,variant:P,onClick:g,onClose:v}=e,[h,b]=react.useState(false),[I,z]=react.useState(false),{toast:E}=Q(true),H=typeof T=="number",k=H?Math.max(0,Math.min(1,T)):void 0,M=I||S,L=p??E?.position??"TopCenter",F=n??E?.type??"default",R=u??E?.style??"stack",B=c??E?.duration??4,G=x??E?.progress??false,U=react.useRef(B*1e3),D=react.useRef(void 0),A=react.useRef(void 0),q=react.useRef(null),K=ge({when:h&&!M,duration:.3,transition:E?.transition||(L.includes("Top")?j.SlideInTop:L.includes("Bottom")?j.SlideInBottom:L.includes("Left")?j.SlideInLeft:j.SlideInRight),curve:E?.curve||te.EaseInOut,watch:["transform","opacity","scale","filter"]});react.useEffect(()=>{b(true);let Y=re=>{if(A.current!==void 0){let ne=re-A.current;if(!H&&!y&&!l&&!M&&(U.current-=ne,q.current)){let ue=Math.max(0,U.current/(B*1e3)*100);q.current?.setProgress?.(ue/100);}}A.current=re,U.current<=0?z(true):D.current=requestAnimationFrame(Y);};return D.current=requestAnimationFrame(Y),()=>{D.current&&cancelAnimationFrame(D.current);}},[y,l,M,B]),react.useEffect(()=>{if(M){let Y=setTimeout(()=>{v?.(t);},350);return ()=>clearTimeout(Y)}},[M,t]);let J=R==="stack",ee=y?r*65:r*8,ie=y?1:Math.max(.85,1-r*.05),me=y?1:Math.max(.4,1-r*.2),ye=Y=>{g?g(Y):s!==true&&(!d||d.length===0)&&z(true);},se=K.style.transform||"translate(0, 0)",le=M?se:`${se} translateY(${L.includes("Top")?ee:-ee}px) scale(${ie})`;return jsxRuntime.jsxs(m,{onClick:ye,as:`--snack --${M?"hidden":"visible"} --${P||E?.variant||W.Medium} --${F} --${L.toLowerCase()} abs flex aic`,style:{...K.style,zIndex:1e3-r,pointerEvents:M?"none":"auto",opacity:M?K.style.opacity:me,transform:le,filter:!M&&J&&!y&&r>0?"blur(1px)":"none",cursor:!d||d.length===0?"pointer":"default",transition:`${K.style.transition}, transform 0.3s ease, opacity 0.3s ease`},children:[jsxRuntime.jsxs(m,{as:"--ico flex aic jcc rel",children:[o?jsxRuntime.jsx(oe,{name:o}):jsxRuntime.jsx(m,{as:"--no-icon"}),s===true&&jsxRuntime.jsx(Se,{as:"abs abc"})]}),jsxRuntime.jsxs(m,{as:"--meta flex cols",style:a?{width:a,minWidth:a,maxWidth:a}:void 0,children:[jsxRuntime.jsx(_,{as:"--tt",children:i||ln[n]}),jsxRuntime.jsx(_,{as:"--tm",children:f})]}),d&&d.length>0&&jsxRuntime.jsx(m,{as:"--actions flex gap:5",children:d.map((Y,re)=>jsxRuntime.jsx(Z,{as:"--snack-btn bold",variant:W.XSmall,onClick:ne=>{ne.stopPropagation(),Y.onClick(ne);},children:Y.label},re))}),(G||H)&&jsxRuntime.jsx(Ue,{as:"abs",progress:k,ref:q})]})},ko=Ai;var we=react.createContext(null),Ki=({ref:e,...r})=>{let n=react.useContext(we)?.depth??0,[o,s]=react.useState(null),[a,i]=react.useState(null),[f,c]=react.useState(false),[l,d]=react.useState([]),p=hooks.useDelayed(),u=react.useRef(0),y=()=>++u.current,C=()=>{c(false),setTimeout(()=>i(null),200);};react.useImperativeHandle(e,()=>({add(g){let v=y(),h={id:v,...g};return d(b=>[...b,h]),v},openMenu(g){c(false),setTimeout(()=>{i({id:y(),type:"menu",props:g}),c(true);},16);},update(g,v){d(h=>h.map(b=>b.id!==g?b:{...b,props:{...b.props,...v}}));},remove(g){d(v=>v.map(h=>h.id===g?{...h,props:{...h.props,forceClose:true}}:h)),a?.id===g&&C();},loading(g,v){d(h=>h.map(b=>b.id===g?{...b,props:{...b.props,forceLoading:v}}:b)),a?.id===g&&C();},clear(g){d(l.filter(v=>v.type!=g));}})),react.useEffect(()=>{if(a&&f){let g=()=>C();return document.addEventListener("click",g),()=>document.removeEventListener("click",g)}},[a,f,C]);let x=g=>{setTimeout(()=>{d(v=>v.filter(h=>h.id!==g)),a?.id===g&&i(null);},250);},T=react.useMemo(()=>[...l.filter(g=>g.type!="toast")],[l]);if(!p)return null;let S=l.filter(g=>g.type=="toast").reverse(),P=Object.values(Ft);return reactDom.createPortal(jsxRuntime.jsxs(m,{as:"--zuz-layers-wrapper fixed fill nope",style:{zIndex:9999+n},children:[T.map((g,v)=>{let h=v<T.length-1;return g.type==="dialog"?jsxRuntime.jsx(Po,{onClose:x,index:v,id:g.id,...g.props,inBackground:h},`layer-${g.type}-${g.id}`):g.type==="drawer"?jsxRuntime.jsx(Bo,{onClose:x,index:v,id:g.id,...g.props,inBackground:h},`layer-${g.type}-${g.id}`):null}),P.map(g=>{let v=S.filter(h=>(h.props.position||"TopCenter")===g);return v.length===0?null:jsxRuntime.jsx(m,{onMouseEnter:()=>s(g),onMouseLeave:()=>s(null),as:`--toast-container fixed --${g.toLowerCase()} flex cols`,style:{pointerEvents:"auto",zIndex:"var(--max-z-index)"},children:v.map((h,b)=>jsxRuntime.jsx(ko,{index:b,total:v.length,isHovered:o===g,onClose:x,id:h.id,...h.props},h.id))},g)}),a&&jsxRuntime.jsx(m,{as:"--zuz-layer-menus fixed fill nope",style:{zIndex:"var(--max-z-index)"},children:jsxRuntime.jsx(So,{onClose:C,when:f,...a.props},`menu-${a.id}`)})]}),document.body)},Wi=({children:e})=>{let r=react.useContext(we),t=r?r.depth+1:0,n=react.useRef(null),o=react.useMemo(()=>({add:s=>n.current?.add(s),openMenu:s=>n.current?.openMenu(s),update:(s,a)=>n.current?.update(s,a),remove:s=>n.current?.remove(s),loading:(s,a)=>n.current?.loading(s,a),clear:s=>n.current?.clear(s),depth:t,isSubLayer:!!r}),[r]);return jsxRuntime.jsxs(we.Provider,{value:o,children:[e,jsxRuntime.jsx(Ki,{ref:n})]})},xo=Wi;var Ui=()=>{let e=react.useContext(we);if(!e)throw new Error("useContextMenu must be used inside <LayersProvider>");return {showContextMenu:(n,o,s)=>{n.preventDefault(),e.openMenu({event:n,items:o,origin:s});},showMenu:(n,{items:o,origin:s,offsetX:a,offsetY:i,transition:f,curve:c,arrow:l,duration:d,header:p,footer:u})=>{e.openMenu({fx:{transition:f,curve:c,duration:d},parent:n,items:o,origin:s||ut.TopCenter,offsetX:a,offsetY:i,arrow:l,header:p,footer:u});},hide:e.clear}},qi=Ui;var Yi=()=>{let e=react.useContext(we);if(!e)throw new Error("useDialog must be used inside <LayersProvider>");let r=()=>e.clear("dialog"),t=s=>e.remove(s),n=(s,a)=>e.loading(s,a);return {clearAll:r,show:s=>{let a=e.add({type:"dialog",props:{...s,type:et.Dialog}});return {id:a,setLoading:i=>n(a,i),hide:()=>t(a)}},hide:t}},ji=Yi;var Ji=()=>{let e=react.useContext(we);if(!e)throw new Error("useDialog must be used inside <LayersProvider>");let r=()=>e.clear("drawer"),t=s=>e.remove(s),n=(s,a)=>e.loading(s,a),o=s=>{let a=e.add({type:"drawer",props:s});return {id:a,setLoading:i=>n(a,i),close:()=>t(a)}};return {clearAll:r,open:s=>o({children:s}),right:s=>o({children:s,from:ve.Right}),left:s=>o({children:s,from:ve.Left}),top:s=>o({children:s,from:ve.Top}),bottom:s=>o({children:s,from:ve.Bottom}),close:t}},el=Ji;var ol=(e,r,t={})=>{let[n,o]=react.useState(null),[s,a]=react.useState(false),{duration:i=.25,curve:f=te.EaseOutBack,borderRadius:c={from:40,to:24},targetWidth:l=320}=t;return react.useLayoutEffect(()=>{r&&e.current?(o(e.current.getBoundingClientRect()),a(true)):r||a(false);},[r,e]),{style:ge({from:{opacity:0,width:n?.width,height:n?.height,borderRadius:c.from},to:{opacity:1,width:l,height:"auto",borderRadius:c.to},curve:f,duration:i,when:s&&r}).style,isMeasured:s,sourceRect:n}},rl=ol;var il=(e,r={})=>{let{offset:t=8,direction:n="bottom",container:o=null,triggerRef:s=null}=r,a=react.useRef(null),i=react.useCallback(()=>{let f=e.current;if(!f)return;let c=s?.current||f.parentElement;if(!c){console.warn("usePosition: No trigger element found. Positioning may not work.");return}let l=f.getBoundingClientRect(),d=c.getBoundingClientRect(),p,u;o?(p=o.getBoundingClientRect(),u="absolute"):(window.getComputedStyle(f).position==="fixed"?u="fixed":u="absolute",u==="fixed"?p={top:0,left:0,right:window.innerWidth,bottom:window.innerHeight,width:window.innerWidth,height:window.innerHeight}:p={top:0,left:0,right:window.innerWidth,bottom:window.innerHeight,width:window.innerWidth,height:window.innerHeight}),f.style.position!==u&&(f.style.position=u),a.current=u;let x=0,T=0;switch(n){case "top":x=d.top-l.height-t,T=d.left,x<p.top&&d.bottom+l.height+t<=p.bottom&&(x=d.bottom+t);break;case "bottom":x=d.bottom+t,T=d.left,x+l.height>p.bottom&&d.top-l.height-t>=p.top&&(x=d.top-l.height-t);break;case "left":x=d.top,T=d.left-l.width-t,T<p.left&&d.right+l.width+t<=p.right&&(T=d.right+t);break;case "right":x=d.top,T=d.right+t,T+l.width>p.right&&d.left-l.width-t>=p.left&&(T=d.left-l.width-t);break}if(x=Math.max(p.top,Math.min(x,p.bottom-l.height)),T=Math.max(p.left,Math.min(T,p.right-l.width)),a.current==="fixed")f.style.top=`${x}px`,f.style.left=`${T}px`;else {let S;f.offsetParent?S=f.offsetParent.getBoundingClientRect():S={top:0,left:0};let P=x-S.top+window.scrollY,g=T-S.left+window.scrollX;f.style.top=`${P}px`,f.style.left=`${g}px`;}},[e,s,t,n,o]);return react.useEffect(()=>{let f=e.current;if(!f)return;let c=s?.current||f.parentElement;if(!c){console.warn("usePosition: No trigger element found. Positioning may not work.");return}let l=new ResizeObserver(i);return l.observe(f),c&&l.observe(c),i(),window.addEventListener("resize",i),window.addEventListener("scroll",i,true),()=>{l.disconnect(),c&&l.disconnect(),window.removeEventListener("resize",i),window.removeEventListener("scroll",i,true);}},[e,n,t,o,s]),{postion:a.current,reposition:i}},xt=il;var cl=()=>{let e=react.useContext(we);if(!e)throw new Error("useToast must be used inside <LayersProvider>");let r=(u,y)=>e.add({type:"toast",props:{...y,type:u}}),t=()=>e.clear("toast"),n=u=>e.remove(u),o=(u,y)=>e.update(u,y),s=u=>({id:u,update:y=>o(u,y),setType:y=>o(u,{type:y}),setProgress:y=>o(u,{progress:true,progressValue:y}),setBusy:y=>o(u,{busy:y}),success:()=>o(u,{type:"success"}),error:()=>o(u,{type:"error"}),warn:()=>o(u,{type:"warn"}),promise:()=>o(u,{type:"promise"}),default:()=>o(u,{type:"default"}),hide:()=>n(u)}),a=u=>s(r("default",u)),i=u=>s(r("success",u)),f=u=>s(r("error",u)),c=u=>s(r("warn",u)),l=u=>s(r("promise",u)),d=(u,y,C)=>{let x=r(u,{...y,sticky:y.sticky??false,actions:[{label:C?.label||"Ok",onClick:T=>{C?.onClick?.(T),n(x);}}]});return s(x)},p=(u,y,C,x)=>{let T=r(u,{...y,sticky:true,actions:[{label:C?.label||"Ok",onClick:S=>{C?.onClick?.(S),(C?.hide??false)===true&&n(T);}},{label:x?.label||"Cancel",onClick:S=>{x?.onClick?.(S),(x?.hide??true)===true&&n(T);}}]});return s(T)};return {show:a,hide:n,promise:l,clearAll:t,ok:(u,y)=>d("default",u,y),success:(u,y)=>y?d("success",u,y):i(u),error:(u,y)=>y?d("error",u,y):f(u),confirm:(u,y,C)=>p("default",u,y,C),warn:(u,y)=>y?d("warn",u,y):c(u),succes:(u,y)=>y?d("success",u,y):i(u)}},ml=cl;var ul=()=>{let e=react.useContext(we);if(!e)throw new Error("useToast must be used inside <LayersProvider>");let r=(c,l)=>e.add({type:"toast",props:{...l,type:c}});return {show:(c,l,d,p)=>r("default",{title:c,message:l,icon:d,duration:p}),hide:c=>e.remove(c),success:(c,l,d,p)=>r("success",{title:c,message:l,icon:d,duration:p}),error:(c,l,d,p)=>r("error",{title:c,message:l,icon:d,duration:p}),warn:(c,l,d,p)=>r("warn",{title:c,message:l,icon:d,duration:p}),promise:(c,l,d,p)=>r("promise",{title:c,message:l,icon:d,duration:p}),clearAll:()=>e.clear("toast")}},Lo=ul;var hn=({ref:e,style:r,...t})=>{let n=react.useRef(null),o=react.useMemo(()=>e&&typeof e!="function"&&e.current?e:n,[e]),{style:s,className:a,rest:i}=N(t,o);return jsxRuntime.jsx("div",{ref:e||n,style:{...s,...r||{}},className:a,...i})};hn.displayName="Zuz.Box";var m=hn;var xn=react.forwardRef((e,r)=>{let{title:t,message:n,...o}=e,[s,a]=react.useState(false);return jsxRuntime.jsxs(m,{className:"--accordion flex cols",...o,children:[jsxRuntime.jsxs(Z,{onClick:i=>a(!s),className:`--toggle flex aic ${s?"--open":""}`.trim(),children:[jsxRuntime.jsx(_,{className:"--label flex",children:t}),jsxRuntime.jsx(m,{className:"--arrow flex",children:s?O.arrowUp:O.arrowDown})]}),s&&jsxRuntime.jsx(m,{className:"--detail",children:n})]})});xn.displayName="Zuz.Accordion";var xl=xn;var bl=({label:e,icon:r,onClick:t,idx:n,selected:o})=>jsxRuntime.jsx(Z,{onClick:t,onMouseMove:s=>document.documentElement.style.setProperty("--tip-m",`${n}`),className:`--action ${o?"--selected":""} aic jcc rel`.trim(),children:typeof r=="string"?jsxRuntime.jsx(oe,{name:r}):r}),vn=bl;var Sn=react.forwardRef((e,r)=>{let{items:t,name:n,selected:o,position:s,...a}=e,i=react.useRef(null),[f,c]=react.useState(o||t[0].tag||0),l=react.useCallback(({x,y:T})=>{if(i.current){let S=i.current.getBoundingClientRect();document.documentElement.style.setProperty("--tip-x",`${x-S.left}`),document.documentElement.style.setProperty("--tip-y",`${T-S.top}`),document.documentElement.style.setProperty("--tip-s","1");}},[]),d=react.useCallback(()=>{i.current&&(i.current.removeEventListener("pointerleave",d),i.current.removeEventListener("pointermove",l),document.documentElement.style.setProperty("--tip-s","0"));},[]),p=react.useCallback(()=>{i.current&&(i.current.addEventListener("pointerleave",d),i.current.addEventListener("pointermove",l));},[]);react.useEffect(()=>{i.current&&(document.documentElement.style.setProperty("--tip-w",t.reduce((x,T)=>T.label.length>x.length?T.label:x,"").length.toString()),document.documentElement.style.setProperty("--tip-s","0"),document.documentElement.style.setProperty("--tip-l",`${t.length}`),i.current?.addEventListener("pointerenter",p));},[]);let{className:u,style:y,rest:C}=N(a);return jsxRuntime.jsxs(m,{ref:i,style:y,className:[`--actionbar flex aic ${u}`,`${!s||s==de.Auto?"rel":`--${s}`}`].join(" ").trim(),...C,children:[t.map((x,T)=>jsxRuntime.jsx(vn,{selected:f===x.tag||o==T,...x,idx:T},`actionbar-action-${x.label.toLowerCase().replace(/\s+/g,"-")}`)),jsxRuntime.jsx(m,{className:"--tip abs",children:jsxRuntime.jsx(m,{className:"--track flex aic",children:t.map(({label:x})=>jsxRuntime.jsx(m,{className:"--lb",children:x},`tool-tip-${x.toLowerCase().replace(/\s+/g,"-")}`))})})]})});Sn.displayName="Zuz.ActionBar";var Tl=Sn;var Cn=react.forwardRef((e,r)=>{let{type:t,icon:n,title:o,message:s,iconSize:a,...i}=e,{className:f,style:c,rest:l}=N(i);return jsxRuntime.jsxs(m,{className:`--alert --${t||Pe.Info} flex aic ${f}`.trim(),style:c,...l,children:[jsxRuntime.jsx(m,{className:`--icon icon-${n||"auto-matic"}`,style:a?{fontSize:a,width:a,height:a}:{},children:!n&&O[t||Pe.Info]}),jsxRuntime.jsxs(m,{className:"--meta flex cols",children:[jsxRuntime.jsx(_,{className:`--title ${s?"--tm":""}`,children:o||"Lorem ipsum dolor sit amet, consectetur adipiscing elit."}),s&&jsxRuntime.jsx(_,{className:"--message",h:2,children:s})]})]})});Cn.displayName="Zuz.Alert";var Il=Cn;var Ho=react.createContext(null),Ao=()=>{let e=react.useContext(Ho);return e?react.useSyncExternalStore(e.subscribe,e.getSnapshot,e.getSnapshot):null},$o=()=>react.useContext(Ho),De=()=>{let e=$o(),r=Ao();return {...e,...r}},Rn=({children:e,initialValues:r={}})=>{let t=react.useRef({values:r,errors:{},touched:{}}),n=react.useRef(new Set(Object.keys(r))),o=react.useRef(new Set),s=react.useCallback(()=>t.current,[]),a=react.useCallback(c=>(o.current.add(c),()=>o.current.delete(c)),[]),i=()=>{o.current.forEach(c=>c());};react.useEffect(()=>{if(r&&Object.keys(r).length>0){let c=new Set(Object.keys(r)),l=[...n.current].filter(p=>!c.has(p)),d={...t.current.values};l.forEach(p=>delete d[p]),t.current={...t.current,values:{...d,...r}},n.current=c,i();}},[r]);let f=react.useMemo(()=>({subscribe:a,getSnapshot:s,setFieldValue:(c,l)=>{t.current.values[c]!==l&&(t.current={...t.current,values:{...t.current.values,[c]:l}},i());},deleteFieldValue:c=>{if(!(c in t.current.values))return;let{[c]:l,...d}=t.current.values;t.current={...t.current,values:d},i();},setFieldError:(c,l)=>{t.current={...t.current,errors:{...t.current.errors,[c]:l}},i();},reset:()=>{t.current={values:{},errors:{},touched:{}},i();}}),[]);return jsxRuntime.jsx(Ho.Provider,{value:f,children:e})};var Nn=({ref:e,...r})=>{let{variant:t,numeric:n,name:o,onConfirm:s,...a}=r,{style:i,className:f,rest:c}=N(a),{variant:l}=Q(true),d=react.useRef(null),p=De(),u=o?p.errors?.[o]:null,y=o&&p.values&&p.setFieldValue,C=y?p.values?.[o]:void 0,x=hooks.useDebounce(S=>{y&&p.setFieldValue?.(o,S);},500),T=S=>{let P=S.currentTarget.value;n&&(P=P.replace(/[^0-9.]/g,"").replace(/(\..*?)\..*/g,"$1"),S.currentTarget.value=P),x(P),r.onInput?.(S);};return react.useEffect(()=>{d.current&&o&&C!==void 0&&d.current.value!==String(C)&&(d.current.value=String(C));},[C,o]),react.useEffect(()=>()=>{y&&p.deleteFieldValue?.(o);},[]),jsxRuntime.jsx("input",{name:o,className:`--input --${t||l} ${u?"--has-error":""} --flex ${f}`.trim(),style:i,defaultValue:C??r.defaultValue??"",onInput:T,onKeyDown:S=>{S.key=="Enter"&&s?.(S.currentTarget.value);},ref:S=>{d.current=S,typeof e=="function"?e(S):e&&(e.current=S);},...c})};Nn.displayName="Zuz.Input";var pe=Nn;var En=e=>{let{meta:r,children:t}=e,n=hooks.useDelayed(),{label:o,icon:s,...a}=react.isValidElement(r)?{}:r,{className:i,style:f,rest:c}=N({...a,...a.animate?{animate:{...a.animate,when:n}}:{}});return react.isValidElement(r)?jsxRuntime.jsx("li",{style:f,className:i,children:r}):jsxRuntime.jsxs("li",{style:f,className:i,...c,children:[t,typeof r=="string"?r:o]})};En.displayName="Zuz.ListItem";var kn=En;var Mn=react.forwardRef((e,r)=>{let{items:t,variant:n,direction:o,seperator:s,ol:a,...i}=e,{className:f,style:c,rest:l}=N(i),d=a==true?"ol":"ul";return react.createElement(d,{className:`--list --${n||W.Small} flex ${o??"cols"} ${f}`.trim(),style:c,ref:r,...l,children:t.map((p,u,y)=>{let C=`${typeof p=="string"?`li-${String(p)}`:react.isValidElement(p)?`li-${p.key}`||`${u}-${core.MD5(p.toString())}`:p.label}-${u}`;return jsxRuntime.jsxs(react.Fragment,{children:[jsxRuntime.jsx(kn,{meta:p}),s&&y[u+1]?jsxRuntime.jsx("li",{className:"--list-seperator",children:s},`spt-${u+1}-${C}`):null]},C)})})});Mn.displayName="Zuz.List";var Xe=Mn;var Vn=react.forwardRef((e,r)=>{let{fx:t,action:n,data:o,withStyle:s,onChange:a,...i}=e,{className:f}=N({as:s||""}),{style:c}=N(i),[l,d]=react.useState(false),[p,u]=react.useState(o||[]),y=react.useRef(null),C=react.useRef(null),x=react.useRef(null),T=react.useMemo(()=>i.name||core.uuid(12),[]),[S,P]=react.useState(null),[g,v]=react.useState(null),[h,b]=react.useState([]),z=hooks.useDebounce(R=>{R.target.value==""?(d(false),u([])):n&&R.target.value.trim()!=""&&core.withPost(n,{query:R.target.value}).then(B=>{"items"in B&&core._(B.items).isArray()?(u(B.items),v(R.target.value),b(B.items)):console.error("Action Response should contain items array"),P(null);}).catch(B=>{P(null),u([]);});},250),E=()=>{if(C.current){let R=C.current.getBoundingClientRect(),B=window.innerHeight-R.bottom,G=R.top;if(x.current){let U=x.current;B<U.offsetHeight&&G>B?(U.style.top="auto",U.style.bottom=`${R.height}px`,U.style.maxHeight=`${G-150}px`):(U.style.top=`${R.height+5}px`,U.style.bottom="auto",U.style.maxHeight=`${B-150}px`);}}},H=R=>{if(p.length>0){if((R.key==="ArrowDown"||R.key==="ArrowUp")&&(R.preventDefault(),R.stopPropagation()),R.key==="Escape")P(null),d(false),u([]);else if(R.key==="ArrowDown")P(B=>{let G=B===null||B===p.length-1?0:B+1;return M(G),G});else if(R.key==="ArrowUp")P(B=>{let G=B===null||B===0?p.length-1:B-1;return M(G),G});else if(R.key==="Enter"&&S!==null){let B=p[S];y.current&&(y.current.value=B,d(false),u([]));}}},k=R=>{y.current&&(y.current.value=R,d(false),u([]));},M=R=>{let B=p[R];if(B&&y.current&&(y.current.value=B,y.current.setSelectionRange(B.length,B.length)),x.current){let U=x.current.children[R];U&&U.scrollIntoView({block:"nearest"});}},L=R=>{C.current&&!C.current.contains(R.target)&&(d(false),u([]));},F=()=>{y.current&&y.current.value===g&&(u(h),P(null),E());};return react.useEffect(()=>(window.addEventListener("resize",E),window.addEventListener("scroll",E,true),document.addEventListener("mousedown",L),()=>{window.removeEventListener("resize",E),window.removeEventListener("scroll",E,true),document.removeEventListener("mousedown",L);}),[]),react.useEffect(()=>{E();},[p]),jsxRuntime.jsxs(m,{style:c,ref:C,className:`--autocomplete --${e.size||W.Small} flex aic rel ${f}`.trim(),children:[jsxRuntime.jsx(pe,{ref:y,autoComplete:"off",onChange:z,onKeyDown:H,onFocus:F,...i}),jsxRuntime.jsx(m,{className:"--arrow rel flex aic jcc",children:p.length>0?O.arrowUp:O.arrowDown}),p.length>0&&jsxRuntime.jsx(Xe,{id:T,ref:x,className:"--suggestion-list flex cols abs",items:p.map((R,B)=>({label:R,onClick:G=>{G.preventDefault(),G.stopPropagation(),k(R);},className:S===B?"--current":"",animate:{transition:j.SlideInBottom,curve:te.EaseInOut,delay:core.clamp(.02*B,.02,.5)}}))})]})});Vn.displayName="Zuz.AutoComplete";var Ql=Vn;var Dn=react.forwardRef((e,r)=>{let t=react.useRef(null),n=react.useMemo(()=>r&&typeof r!="function"&&r.current?r:t,[r]),{style:o,className:s,rest:a}=N(e,n);return !a.src||a.src==""?null:jsxRuntime.jsx("img",{ref:n,style:o,className:`${s} flex`,...a})});Dn.displayName="Zuz.Image";var Ye=Dn;var Hn=react.forwardRef((e,r)=>{let{src:t,variant:n,type:o,crossOrigin:s,referrerPolicy:a,fx:i,as:f,alt:c,color:l,style:d,...p}=e,[u,y,C]=hooks.useImage(t??"",s,a),{className:x,style:T,rest:S}=N({fx:i,as:f});return jsxRuntime.jsx(m,{className:`--avatar --${n||W.Small} --${(o||Cr.Circle).toLowerCase()} rel flex aic jcc ${x}`.trim(),style:{background:l||"var(--avatar-bg, var(--primary))",...d,...T},...S,children:t?jsxRuntime.jsx(Ye,{src:u,crossOrigin:s,referrerPolicy:a,...p}):jsxRuntime.jsx(_,{className:"--avatar-label",children:(c?c.charAt(0):"A").toUpperCase()})})});Hn.displayName="Zuz.Avatar";var ac=Hn;var ic=({size:e=5,type:r="dead",label:t="",variant:n=W.Small,loading:o=false,spinner:s,...a})=>{let{style:i,className:f,rest:c}=N(a);return jsxRuntime.jsxs(m,{style:{...core._(t).isEmpty()?{"--badge-size":e}:{},...i},as:`--badge --${n} --${r} rel flex aic jcc ${f}`.trim(),children:[jsxRuntime.jsx(m,{fx:{transition:j.FadeIn,curve:te.Liquid,duration:.5,when:o},as:"abs abc",children:jsxRuntime.jsx(Se,{type:s})}),core._(t).isEmpty()?jsxRuntime.jsx(m,{as:`--dot --${r}`}):jsxRuntime.jsx(_,{as:"--label",children:t})]})},lc=ic;var wc=[{label:"Today",getDate:()=>new Date,getDateFormat:()=>dateFns.format(new Date,"EEE")},{label:"Later",getDate:()=>new Date,getDateFormat:()=>dateFns.format(dateFns.addHours(new Date,2),"hh:mm a")},{label:"Tomorrow",getDate:()=>dateFns.addDays(new Date,1),getDateFormat:()=>dateFns.format(dateFns.addDays(new Date,1),"EEE")},{label:"This weekend",getDate:()=>{let e=new Date,r=e.getDay();return dateFns.addDays(e,(6-r)%7||6)},getDateFormat:()=>{let e=new Date,r=e.getDay();return dateFns.format(dateFns.addDays(e,(6-r)%7||6),"EEE, MMM d")}},{label:"Next week",getDateFormat:()=>dateFns.format(dateFns.addWeeks(new Date,1),"EEE, MMM d"),getDate:()=>dateFns.addWeeks(new Date,1)},{label:"Next weekend",getDateFormat:()=>dateFns.format(dateFns.addWeeks(new Date,1),"d MMM"),getDate:()=>dateFns.addWeeks(new Date,1)},{label:"2 weeks",getDateFormat:()=>dateFns.format(dateFns.addWeeks(new Date,2),"d MMM"),getDate:()=>dateFns.addWeeks(new Date,2)},{label:"4 weeks",getDateFormat:()=>dateFns.format(dateFns.addWeeks(new Date,4),"d MMM"),getDate:()=>dateFns.addWeeks(new Date,4)}],Cc=e=>{let r=new Set;return e.filter(t=>{if(t.label=="Later")return true;let n=t.getDate().toISOString().split("T")[0];return r.has(n)?false:(r.add(n),true)})},$n=react.forwardRef((e,r)=>{let{defaultValue:t,variant:n,onChange:o,...s}=e,{style:a,className:i,rest:f}=N(s),[c,l]=react.useState(t||new Date),d=dateFns.startOfMonth(c),p=dateFns.endOfMonth(c),u=dateFns.startOfWeek(d),y=dateFns.endOfWeek(p),C=react.useMemo(()=>dateFns.eachDayOfInterval({start:u,end:y}),[u,y]),x=P=>{o?.(P),l(P);},T=()=>{l(P=>new Date(P.getFullYear(),P.getMonth()-1));},S=()=>{l(P=>new Date(P.getFullYear(),P.getMonth()+1));};return jsxRuntime.jsxs(m,{as:`--calendar flex --${n||"sm"} ${i}`,style:a,children:[jsxRuntime.jsx(m,{as:"--calendar-quick-select flex cols flex:1",children:Cc(wc).map(P=>{let g=P.getDate();return jsxRuntime.jsxs(Z,{onClick:()=>x(g),as:["--calendar-quick-option flex aic gap:5"],children:[jsxRuntime.jsx(_,{as:"flex:1",children:P.label}),jsxRuntime.jsx(_,{as:"tar",children:P.getDateFormat()})]},`--dtp-option-label-${P.label}`)})}),jsxRuntime.jsxs(m,{as:"--calendar-selector flex cols flex:1",children:[jsxRuntime.jsxs(m,{as:"--calendar-head flex aic jcc gap:4",children:[jsxRuntime.jsx(_,{as:"flex:1 --calendar-cm bold",children:dateFns.format(c,"MMMM yyyy")}),jsxRuntime.jsx(Z,{onClick:T,as:"--calendar-chevron",children:O.chevronUpOutline}),jsxRuntime.jsx(Z,{onClick:S,as:"--calendar-chevron",children:O.chevronDownOutline})]}),jsxRuntime.jsxs(m,{as:"--calendar-days gap:4",children:[["Su","Mo","Tu","We","Th","Fr","Sa"].map(P=>jsxRuntime.jsx(_,{as:"--calendar-day",children:P},`--calendar-hd-${P}`)),C.map((P,g)=>{let v=dateFns.isSameMonth(P,c),h=dateFns.isSameDay(P,c),b=dateFns.isToday(P);return jsxRuntime.jsx(Z,{disabled:!v,onClick:()=>x(P),as:["--calendar-day --calendar-dd",`${h?"--calendar-dd-selected":""}`,`${b?"--calendar-dd-current":""}`],children:dateFns.format(P,"d")},`--calendar-day-${g}-${P.getFullYear()}-${P.getMonth()}-${P.getDay()}`)})]})]})]})});$n.displayName="Zuz.Calendar";var Zo=$n;var Ut=(t=>(t.Table="table",t.Gooey="gooey",t))(Ut||{});var Zn=({ref:e,...r})=>{let{itemCount:t,itemsPerPage:n,startPage:o,pageRange:s,paginationStyle:a,breakLabel:i,prevLabel:f,nextLabel:c,hash:l,loading:d,seperator:p,renderOnZeroPageCount:u,asDots:y,progressBar:C,onPageChange:x,...T}=r,S=react.useRef(null),P=react.useMemo(()=>core.toHash(core.numberInRange(4,8)),[]),g=react.useCallback(R=>`${core.toHash(R,l||6,P)}${p||""}${P}`,[P]),v=react.useMemo(()=>i||"...",[i]),h=react.useRef(null),[b,I]=react.useState({id:l?o?typeof o=="number"?g(o):o:1:o||1,label:o||1});react.useImperativeHandle(e,()=>({setPage:R=>I(R),getPage:R=>b,setProgress:R=>h.current?.setProgress?.(R),getProgress:()=>h.current?.getProgress?.()??0}),[h.current]);let{style:z,className:E,rest:H}=N(T),k=react.useCallback(R=>typeof R=="number"?R:+R.label,[]);if(!t)throw new Error('"itemCount" prop is required');let M=react.useMemo(()=>Math.ceil(t/n),[t,n]),L=react.useMemo(()=>{let R=[],B=Math.max(k(b)-(s||2),1),G=Math.min(k(b)+(s||2),M);B>1&&R.push({id:l?g(1):1,label:1}),B>2&&R.push({id:-1,label:v});for(let U=B;U<=G;U++)R.push({id:l?g(U):U,label:U});return G<M-1&&R.push({id:-1,label:v}),G<M&&R.push({id:l?g(M):M,label:M}),R},[b]),F=react.useCallback(R=>{let B=R;+B.label<1||+B.label>M||(I(B),x?.(B));},[t,n,b]);return L.length<=1&&(u??false)===false?null:jsxRuntime.jsxs(m,{ref:S,as:`--pagination ${y===true?"--as-dots":""} --pgt-${a||"table"} flex aic w:100% jcc ${E}`,children:[jsxRuntime.jsx(m,{as:"flex flex:1 aic --pgt-btns",children:(L.length>1?L:[{id:1,label:1},{id:-1,label:v}]).map((R,B,G)=>{let U=(typeof R=="string"?R:R.label)==k(b);return jsxRuntime.jsx(Z,{disabled:R.id==-1||k(b)==+R.label,className:U?"--current-page":"",onClick:D=>F(R),children:y===true?C===true&&U?jsxRuntime.jsx(Ue,{ref:h}):"":typeof R=="string"?R:R.label},`--pg-${B}-${R.id}`)})}),jsxRuntime.jsx(m,{as:"flex aic jcc flex:1 --pagination-label",children:[`Showing ${(k(b)-1)*n+1} - `,`${Math.min(k(b)*n,t)} of ${t} items`].join(" ")}),jsxRuntime.jsxs(m,{as:"flex aic jce flex:1 --pgt-btns --pgt-nav",children:[jsxRuntime.jsx(Z,{disabled:k(b)<=1,onClick:R=>F({id:l?g(k(b)-1):k(b)-1,label:k(b)-1}),children:O.chevronLeftOutline}),jsxRuntime.jsx(Z,{disabled:L.length<=1||k(b)==k(L[L.length-1]),onClick:R=>F({id:l?g(k(b)+1):k(b)+1,label:k(b)+1}),children:O.chevronRightOutline})]})]})};Zn.displayName="Zuz.Pagination";var St=Zn;function kc(e,r){let{items:t,renderItem:n,effect:o="slide",loop:s=true,loopMode:a="infinite",startIndex:i=0,useKeys:f=true,useWheel:c=true,spacing:l=160,rotation:d=20,scaleStep:p=.15,blur:u=4,animation:y="power",showDots:C=false,autoPlay:x=false,autoPlaySpeed:T=3,onChange:S,...P}=e,{className:g,style:v}=N(P),h=react.useRef(null),b=T/(T>=1e3?1e3:1),I=hooks.useCarousel({total:t.length,initialIndex:i,loop:s,useKeys:f,useWheel:c,onChange:M=>{h.current?.setPage({id:M+1,label:M+1}),h.current?.setProgress(0),S?.(M);}}),{pause:z,resume:E,reset:H}=hooks.useTimer({duration:b,autoStart:x===true,onProgress:M=>{x===true&&h.current?.setProgress(1-M);},onExpired:()=>{x===true&&I.next(),H();}}),k={...v,"--carousel-spacing":`${l}px`,"--carousel-rotation":`${d}deg`,"--carousel-blur":`${u}px`,"--carousel-scale-step":p,"--active-index":I.index,"--carousel-transition":`var(--${y})`};return jsxRuntime.jsxs(m,{ref:r,className:`--carousel --effect-${o} --loop-${a} flex cols aic jcc ${g}`.trim(),style:k,children:[jsxRuntime.jsx(m,{className:"--carousel-stage rel fill flex aic jcc",children:t.map((M,L)=>{let F=L-I.index;if(a==="infinite"){let B=t.length;F=((F+B/2)%B+B)%B-B/2;}let R=L===I.index;return jsxRuntime.jsx(m,{onMouseEnter:()=>R&&z(),onMouseLeave:()=>R&&E(),className:`--carousel-item-wrapper abs ${R?"--is-active":""}`,style:{"--offset":F,zIndex:R?100:100-Math.abs(F),display:Math.abs(F)>5?"none":"flex"},children:n(M,L,I.index)},L)})}),C&&jsxRuntime.jsx(St,{ref:h,itemCount:t.length,itemsPerPage:1,startPage:i+1,pageRange:t.length,paginationStyle:"gooey",onPageChange:M=>I.goTo(+M.label-1),asDots:true,progressBar:true})]})}var Lc=react.forwardRef(kc),Mc=Lc;var Kn=(r=>(r.Line="line",r))(Kn||{});var Un=react.forwardRef((e,r)=>{let{data:t,width:n,height:o,lineColor:s,strokeWidth:a=2,gradientStartColor:i,gradientEndColor:f,animated:c,animDuration:l=2,animDelay:d=0,padding:p=0,type:u,...y}=e,{className:C,style:x,rest:T}=N(y),S=react.useRef(null),P=hooks.useResizeObserver(S.current?.parentElement||S),g=typeof n=="number"?n:P.width,v=typeof o=="number"?o:P.height,h={width:g,height:v},b=react.useId(),{pathD:I,areaPathD:z}=hooks.useLineChart(t,h,p+(a||2)),E=react.useRef(null),H=react.useRef(null),[k,M]=react.useState(0),[L,F]=react.useState(0);return react.useEffect(()=>{c&&(E.current&&M(E.current.getTotalLength()),H.current&&F(H.current.getTotalLength()));},[c,I,z,g,v]),jsxRuntime.jsx(m,{ref:S,as:`--chart --${u||"line"}-chart ${C}`.trim(),style:{...x,width:n,height:o},...T,children:g>0&&v>0&&jsxRuntime.jsxs("svg",{viewBox:`0 0 ${g} ${v}`,preserveAspectRatio:"xMidYMid meet",children:[jsxRuntime.jsx("defs",{children:jsxRuntime.jsxs("linearGradient",{id:b,x1:"0%",y1:"0%",x2:"0%",y2:"100%",children:[jsxRuntime.jsx("stop",{offset:"0%",stopColor:i}),jsxRuntime.jsx("stop",{offset:"100%",stopColor:f})]})}),jsxRuntime.jsx("path",{ref:H,d:z,fill:`url(#${b})`,stroke:"none",style:c?{strokeDasharray:L,strokeDashoffset:L}:{},children:c&&jsxRuntime.jsx("animate",{attributeName:"stroke-dashoffset",from:L,to:"0",dur:`${l||2}s`,begin:`${d||0}s`,fill:"freeze"})}),jsxRuntime.jsx("path",{ref:E,d:I,fill:"none",stroke:s,strokeWidth:a,strokeLinecap:"round",strokeLinejoin:"round",style:c?{strokeDasharray:k,strokeDashoffset:k}:{},children:c&&jsxRuntime.jsx("animate",{attributeName:"stroke-dashoffset",from:k,to:"0",dur:`${l||2}s`,begin:`${d||0}s`,fill:"freeze"})})]})})});Un.displayName="Zuz.Chart";var zc=Un;var qn=(o=>(o[o.Sending=0]="Sending",o[o.Sent=1]="Sent",o[o.Delivered=2]="Delivered",o[o.Read=3]="Read",o))(qn||{}),Xn=(c=>(c.Image="img",c.Video="vid",c.Audio="audio",c.Link="link",c.Document="doc",c.Location="loc",c.Contact="contact",c.Event="event",c.Poll="poll",c))(Xn||{});var Yn=react.forwardRef((e,r)=>{let{text:t,media:n,side:o="me",status:s=1,timeStamp:a=Date.now(),arrow:i=true,...f}=e,{className:c,style:l,rest:d}=N(f);return jsxRuntime.jsx(m,{className:`--bubble-wrapper flex --bw-${o}`.trim(),children:jsxRuntime.jsxs(m,{className:`--bubble --bubble-${o} ${n?`--with-media --bma-${n.type}`:""} rel flex cols ${i==true?"--b-arrow":""} ${c}`.trim(),style:{...l},...d,children:[t&&jsxRuntime.jsx(_,{className:"--bubble-text",children:t}),n?n.type=="audio"?jsxRuntime.jsxs(m,{as:"flex aic --bubble-audio",children:[jsxRuntime.jsx(ae,{className:"--bm-action",children:O.play}),jsxRuntime.jsx(Ue,{progress:.7}),jsxRuntime.jsx(_,{className:"--bm-dur",children:n.duration??"00:13"})]}):n.type=="img"?jsxRuntime.jsx(m,{as:"--bubble-image",children:jsxRuntime.jsx(Ye,{src:n.source})}):null:null,jsxRuntime.jsxs(m,{as:"flex aie jce --bubble-stats",children:[jsxRuntime.jsx(_,{className:"--bubble-stamp tar",children:core.timeSince(a)}),o=="me"&&jsxRuntime.jsx(ae,{className:`--bubble-status --bs-${s}`,children:s==0?O.pending:s==1?O.done:s==2?O.doneAll:O.doneAll})]})]})})});Yn.displayName="Zuz.Bubble";var Zc=Yn;var jn=react.forwardRef((e,r)=>{let{style:t,className:n,rest:o}=N(e);return jsxRuntime.jsx("label",{ref:r,style:t,className:n,...o})});jn.displayName="Zuz.Label";var wt=jn;var Jn=({ref:e,...r})=>{let {name:t,required:n,type:o,value:s,size:a,variant:i,checked:f,disabled:c,onSwitch:l,...d}=r,p=De(),u=!!(t&&p.values);u?p.errors?.[t]:null;let C=u?p.values?.[t]:void 0,[x,T]=react.useState(f||false),S=react.useRef(null),{variant:P}=Q(true),g=react.useMemo(()=>u&&C!=null?typeof C=="string"?C.toLowerCase()!=="false"&&C!=="":!!C:x,[C,x,u]);react.useEffect(()=>{S.current&&S.current.checked!==g&&(S.current.checked=g);},[g]),react.useEffect(()=>{f!==void 0&&T(f);},[f]);let v=h=>{let b=!!h;u&&p.setFieldValue?.(t,b),T(b),l?.(b,s||"cb");};return react.useImperativeHandle(e,()=>({setChecked(h,b=true){v(h);},toggle(h=true){v(!g);}})),jsxRuntime.jsxs(wt,{"aria-hidden":c,className:[`--${(o||Oe.Default).toLowerCase()}`,`${!o||o===Oe.Default?"--checkbox":"--switch"}`,`--${i||P||W.Small}`,`flex aic jcc ${g?"is-checked":""} rel`,`${c?"--disabled":""}`].join(" ").trim(),...d,children:[(!o||o==Oe.Default)&&O.check,jsxRuntime.jsx(pe,{ref:h=>{S.current=h,e&&(e.current=h);},defaultChecked:g,type:"checkbox",className:"abs",name:t,required:n||false,onChange:h=>{h.stopPropagation(),v(h.target.checked);},disabled:c})]})};Jn.displayName="Zuz.CheckBox";var Ct=Jn;var em=({ref:e,...r})=>{let{code:t,copy:n,lang:o="tsx",showLines:s=false,highlight:a="",as:i,fx:f,...c}=r,l=react.useRef(null),{className:d,style:p,rest:u}=N({as:`rel p:20 br:8 bg:shade-1 overflow:auto font:mono ${i}`,fx:f},l),y=react.useMemo(()=>{let x=new Set;return a.split(",").forEach(T=>{if(T.includes("-")){let[S,P]=T.split("-").map(Number);for(let g=S;g<=P;g++)x.add(g);}else T&&x.add(Number(T));}),x},[a]),C=react.useMemo(()=>{let x=t.split(`
10
- `);for(;x.length>0&&x[0].trim()==="";)x.shift();for(;x.length>0&&x[x.length-1].trim()==="";)x.pop();let T=x[0]?.match(/^\s*/)?.[0].length||0,S=x.map(g=>{let v=g.match(/^\s*/)?.[0].length||0,h=Math.min(v,T);return g.slice(h)}),P=[{name:"comm",re:/\/\/.*/g},{name:"str",re:/(["'`])(?:(?=(\\?))\2.)*?\1/g},{name:"key",re:/\b(const|let|var|export|default|import|from|return|if|else|switch|case|break|as|type|interface|class|extends|await|async|new|void|typeof)\b/g},{name:"tag",re:/(&lt;\/?[A-Z][\w\.]*|&gt;)/g},{name:"var",re:/(?<!&lt;\/|&lt;)\b[A-Z]\w*\b/g},{name:"fn",re:/\b([a-z_]\w*)(?=\s*\()/gi},{name:"prop",re:/\.([a-z_]\w*)\b/gi},{name:"num",re:/\b\d+\b(?![#|A-Z|a-z|_|ZUZ])/g}];return S.map((g,v)=>{let h=g.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;"),b=y.has(v+1);if(o!="plain"){let I=[];P.forEach(z=>{h=h.replace(z.re,E=>{let H=`ZUZ_ID_${I.length}_ZUZ`;return I.push(`<span class="--token-${z.name}">${E}</span>`),H});});for(let z=I.length-1;z>=0;z--)h=h.replace(`ZUZ_ID_${z}_ZUZ`,I[z]);}return `<div class="--code-line ${s==true?"--with-ln":""} ${b?"--is-highlighted":""}">
9
+ document.documentElement.style.colorScheme = theme;`}}),jsxRuntime.jsx(Io,{children:e})]})},$r=(e,r)=>{if(ei)return;let t;try{t=localStorage.getItem(e)||void 0;}catch{}return t||r};var Fr=({ref:e,...r})=>{let{style:t,...n}=r,{style:o,className:s,rest:a}=E(n);return jsxRuntime.jsx("span",{ref:e,style:t,className:s,...a})};Fr.displayName="Zuz.Span";var ce=Fr;var Kr=react.forwardRef((e,r)=>{let{name:t,pathCount:n,variant:o,color:s,size:a,...l}=e,{variant:f}=j(true),{className:c,style:i,rest:d}=E(l);return jsxRuntime.jsx("div",{style:{color:s,...i,...a?{fontSize:a}:{}},className:`icon-${t} --icon --${o||f||U.Small} ${c}`.trim(),ref:r,...d,children:Array(n||0).fill(0).map((u,m)=>jsxRuntime.jsx(ce,{className:`path${m+1}`},`${t}-layer-${m}`))})});Kr.displayName="Zuz.Icon";var J=Kr;var xe={Simple:"SIMPLE",Roller:"ROLLER",Wave:"Wave"};var Zr=e=>{let{type:r,variant:t,color:n,...o}=e,{className:s,style:a,rest:l}=E(o),{spinner:f}=j(true),c=()=>{switch(r||f?.type||xe.Simple){case xe.Simple:return null;case xe.Wave:return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(p,{as:"--bar --bar1"}),jsxRuntime.jsx(p,{as:"--bar --bar2"}),jsxRuntime.jsx(p,{as:"--bar --bar3"})]});case xe.Roller:return null}};return jsxRuntime.jsx(p,{className:`${s} --spinner --${(r||f?.type||xe.Simple).toLowerCase()} --${t||f?.variant||U.Small}`.trim(),style:{...a},...l,children:c()})};Zr.displayName="Zuz.Spinner";var we=Zr;var _t={Loading:"loading",Normal:"normal"};var Gr=({ref:e,...r})=>{let{reset:t,kind:n="solid",variant:o,icon:s,iconSize:a,children:l,withLabel:f,spinner:c,state:i,disabled:d,...u}=r,{style:m,className:h,rest:C}=E(u),{variant:x}=j(true);return jsxRuntime.jsxs("button",{className:core.removeDuplicateWords(`--button --${n} --${o||x} flex aic ${t?"":"jcc"} ${s?"--with-icon":""} ${h}`).trim().replace(/\s+/g," "),style:m,ref:e,disabled:i==_t.Loading||r.skeleton?.enabled||d,...C,children:[i==_t.Loading&&jsxRuntime.jsx(we,{variant:o||x,type:c||xe.Simple}),(!i||i==_t.Normal)&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[s&&jsxRuntime.jsx(J,{variant:a,name:s}),f===true?jsxRuntime.jsx(ce,{children:l}):l]})]})};Gr.displayName="Zuz.Button";var F=Gr;var Ur=({ref:e,...r})=>{let{h:t,html:n,children:o,lines:s,tfx:a,delay:l=0,duration:f=.5,stagger:c=.05,repeat:i=true,reveal:d=false,hover:u=false,...m}=r,{style:h,className:C,rest:x}=E(m),T=react.useRef(null),[S,P]=react.useState(false),[g]=hooks.useIntersectionObserver([T],{threshold:[1]}),v=react.useMemo(()=>{if(h?.opacity!==void 0)return h.opacity;if(typeof r.as=="string"){let A=r.as.match(/opacity:([\d.]+)/);if(A)return A[1]}return 1},[r.as,h?.opacity]),y=react.useMemo(()=>a?u?S:d?g===1:true:false,[a,u,S,d,g]);react.useEffect(()=>{e&&(typeof e=="function"?e(T.current):e.current=T.current);},[e]);let b=`h${r.h||1}`,I=react.useMemo(()=>typeof o=="string"?o:Array.isArray(o)&&o.length===1&&typeof o[0]=="string"?o[0]:null,[o]),D=react.useMemo(()=>{let A=Array.isArray(r.as)?r.as.join(" "):r.as||"";return typeof A=="string"&&A.includes("text-clip")},[r.as]);react.useLayoutEffect(()=>{if(!D||!T.current||I===null)return;let A=T.current,L=0,M=0,$=()=>{let B=A.getBoundingClientRect(),q=getComputedStyle(A).backgroundImage,X=B.width;A.querySelectorAll(".--fx-char").forEach(z=>{let Z=z.getBoundingClientRect().left-B.left;z.style.backgroundImage=q,z.style.backgroundRepeat="no-repeat",z.style.backgroundSize=`${X}px 100%`,z.style.backgroundPosition=`-${Z}px 0`,z.style.backgroundClip="text",z.style.webkitBackgroundClip="text",z.style.color="transparent";});},K=()=>{cancelAnimationFrame(L),cancelAnimationFrame(M),L=requestAnimationFrame(()=>{M=requestAnimationFrame($);});};K();let R=new ResizeObserver(K);return R.observe(A),typeof document<"u"&&"fonts"in document&&document.fonts?.ready.then(K),window.addEventListener("resize",K),()=>{cancelAnimationFrame(L),cancelAnimationFrame(M),R.disconnect(),window.removeEventListener("resize",K);}},[D,I,a,y]);let N=react.useMemo(()=>n?jsxRuntime.jsx(ce,{dangerouslySetInnerHTML:{__html:n}}):a&&I!==null?I.split("").map((A,L)=>{let M=A===" ",K=["typewriter","reveal","fog","slide","pop"].includes(a)?"1":i?"infinite":"1";return jsxRuntime.jsx(ce,{"data-char":A,className:`--fx-char -fx ${y?`--fx-${a}`:""}`,style:{"--delay":`${l+L*c}s`,"--duration":`${f}s`,"--iteration":K,"--target-opacity":v,display:M?"inline":"inline-block",whiteSpace:"pre",opacity:!y&&a==="typewriter"?0:void 0},children:A},L)}):o,[o,n,a,I,y,l,c,f,i]);return jsxRuntime.jsx(b,{ref:T,onMouseEnter:()=>u&&P(true),onMouseLeave:()=>u&&P(false),style:a?{...h,display:a?"flex":h?.display,flexWrap:a?"wrap":h?.flexWrap,opacity:a&&!y?0:a?1:h?.opacity,transition:a?"opacity 0.4s ease":void 0}:h,className:`${C} ${a?"--text-fx -fx":""}`.trim(),...x,children:N})};Ur.displayName="Zuz.Text";var _=Ur;var gi=e=>{let{label:r,labelColor:t,icon:n,iconColor:o,index:s,className:a,onSelect:l}=e;return r=="-"?jsxRuntime.jsx(p,{className:"--line"}):jsxRuntime.jsxs(F,{reset:true,onClick:f=>l?.(e),className:`--item ${a||""}`.trim(),children:[jsxRuntime.jsx(p,{as:"--icon",children:jsxRuntime.jsx(J,{name:n,className:"--ico",style:o?{color:o}:{}})}),jsxRuntime.jsx(_,{className:"--lbl flex aic",style:t?{color:t}:{},children:r})]})},qr=gi;var jr=({ref:e,...r})=>{let{id:t,as:n,fx:o,offsetX:s,offsetY:a,parent:l,event:f,arrow:c,when:i,items:d,header:u,footer:m,origin:h=bt.TopRight,...C}=r,[x,T]=react.useState(false),[S,P]=react.useState(d||[]),{position:g,targetRef:v,calculatedAnchor:y}=hooks.useAnchorPosition(l?.current,f,{offsetX:s,offsetY:a,preferredAnchor:h}),I=l&&g.top>l.current.getBoundingClientRect().bottom?"--arrow-top":"--arrow-bottom",D=react.useMemo(()=>{let K=y.toLowerCase();return K.includes("left")?"--arrow-left":K.includes("right")?"--arrow-right":"--arrow-center"},[y]),N=g.top!==0||g.left!==0;react.useEffect(()=>{i&&N?T(true):i||T(false);},[i,N]);let{className:A,style:L,rest:M}=E(C),$=ye({...o?.transition?{transition:o.transition??Y.SlideInBottom}:{from:{opacity:0,scale:.8,y:-10},to:{opacity:1,scale:1,y:0}},curve:o?.curve??ee.EaseInOut,duration:o?.duration??.05,when:x&&N});return jsxRuntime.jsxs(p,{ref:v,className:`--contextmenu ${c||l!=null?`--has-arrow ${I} ${D}`:""} abs flex cols ${A}`.trim(),"aria-hidden":!x,style:{...L,...$.style,top:g.top,left:g.left,visibility:N?"visible":"hidden",transformOrigin:y},...M,children:[typeof u=="function"?react.createElement(u):u,S.map((K,R)=>jsxRuntime.jsx(qr,{...K,index:R},`context-${K.label.toLowerCase()}-${R}`)),typeof m=="function"?react.createElement(m):m]})};jr.displayName="Zuz.ContextMenu";var Bo=jr;var Qr=react.forwardRef((e,r)=>{let{children:t,fx:n,when:o,fxDelay:s,fxStep:a,classToIgnore:l,...f}=e,c=j(true),i=hooks.useDelayed(),d=n||c?.group?.fx,u=s||c?.group?.fxDelay,m=a||c?.group?.fxStep,h=l||c?.group?.classToIgnore||"-fx",C=react.useMemo(()=>d?react$1.addPropsToChildren(t,x=>{if(x.type===react.Fragment)return false;let T=x.props||{},S="fx"in T,P="tfx"in T,g=T.as?Array.isArray(T.as)?T.as.join(" "):T.as:T.className||"";return !(typeof g=="string"&&g.includes(h))&&(!S||P)},(x,T)=>{let S=(u??0)+x*(m??.1),P=T.props||{};return "tfx"in P?{delay:(P.delay??0)+S}:{fx:{...d,delay:S,when:o??(n?.when||i)}}}):t,[t,o,i,d,u,m,h,n]);return jsxRuntime.jsx(p,{className:"--group",ref:r,...f,children:C})});Qr.displayName="Zuz.Group";var ko=Qr;var en=react.forwardRef((e,r)=>{let{message:t,spinner:n,spinnerSize:o,color:s,when:a,hideMessage:l,...f}=e,{className:c,style:i,rest:d}=E(f),{spinner:u}=j(true);return "when"in e&&e.when==false?null:jsxRuntime.jsxs(ko,{fx:{transition:Y.SlideInBottom,curve:ee.Liquid,duration:.5},fxDelay:.1,fxStep:.05,className:`--cover flex aic jcc cols abs fill nope nous ${c}`.trim(),style:{...i,backgroundColor:"var(--cover-bg)"},...d,children:[jsxRuntime.jsx(we,{variant:o||u?.variant||U.Small,type:n||u?.type||xe.Simple}),!l&&jsxRuntime.jsx(_,{className:"--label",tfx:"fade",style:{color:"var(--cover-label)"},children:t||"loading"})]})});en.displayName="Zuz.Cover";var Le=en;var Lo=class{stack=[];SCROLL_CLASS="--no-scroll";updateScrollLock(){typeof window>"u"||(this.stack.length>0?document.body.classList.add(this.SCROLL_CLASS):document.body.classList.remove(this.SCROLL_CLASS));}isTop(r){return this.stack[this.stack.length-1]===r}push(r){this.stack.includes(r)||(this.stack.push(r),this.updateScrollLock());}pop(r){this.stack=this.stack.filter(t=>t!==r),this.updateScrollLock();}handleEscape(){let r=this.stack[this.stack.length-1];return r?(r(),true):false}get count(){return this.stack.length}},Ee=new Lo;var tn=react.forwardRef((e,r)=>{let{when:t,...n}=e;return jsxRuntime.jsx(p,{ref:r,"aria-hidden":!t,className:"--overlay fixed fill",fx:{transition:Y.FadeIn,when:t},...n})});tn.displayName="Zuz.Overlay";var Ye=tn;var Li=({action:e,render:r=true,message:t=""})=>jsxRuntime.jsx(p,{as:`--body flex aic rel ${e?"":"--no-action"}`.trim(),children:r?t:null}),on=Li;var Oi=({action:e,actionPosition:r,dialogID:t,variant:n})=>jsxRuntime.jsx(p,{as:`--footer flex aic rel ${r?r==Lr.Center?"jcc":"":"jce"}`.trim(),children:e.map((o,s)=>jsxRuntime.jsx(F,{variant:n,onClick:a=>o.handler?o.handler():o.onClick?o.onClick():console.log("onClick Handler missing"),as:"--action",children:o.label},`dialog-${t}-action-${o.key}`))}),nn=Oi;var Vi={colorSchemeLight:jsxRuntime.jsxs("svg",{width:"24",height:"24",fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5",color:"currentcolor",shapeRendering:"geometricPrecision",viewBox:"0 0 24 24",children:[jsxRuntime.jsx("circle",{cx:"12",cy:"12",r:"5"}),jsxRuntime.jsx("path",{d:"M12 1v2M12 21v2M4.22 4.22l1.42 1.42M18.36 18.36l1.42 1.42M1 12h2M21 12h2M4.22 19.78l1.42-1.42M18.36 5.64l1.42-1.42"})]}),colorSchemeSystem:jsxRuntime.jsxs("svg",{width:"24",height:"24",fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5",color:"currentcolor",shapeRendering:"geometricPrecision",viewBox:"0 0 24 24",children:[jsxRuntime.jsx("rect",{width:"20",height:"14",x:"2",y:"3",rx:"2",ry:"2"}),jsxRuntime.jsx("path",{d:"M8 21h8M12 17v4"})]}),colorSchemeDark:jsxRuntime.jsx("svg",{width:"24",height:"24",fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5",color:"currentcolor",shapeRendering:"geometricPrecision",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M21 12.79A9 9 0 1 1 11.21 3 7 7 0 0 0 21 12.79"})}),arrowDown:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M17.919 8.18H6.079c-.96 0-1.44 1.16-.76 1.84l5.18 5.18c.83.83 2.18.83 3.01 0l1.97-1.97 3.21-3.21c.67-.68.19-1.84-.77-1.84z"})}),arrowUp:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M18.68 13.978l-3.21-3.21-1.96-1.97a2.13 2.13 0 00-3.01 0l-5.18 5.18c-.68.68-.19 1.84.76 1.84h11.84c.96 0 1.44-1.16.76-1.84z"})}),search:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 34 34",children:jsxRuntime.jsx("path",{d:"M27.414,24.586l-5.077-5.077C23.386,17.928,24,16.035,24,14c0-5.514-4.486-10-10-10S4,8.486,4,14 s4.486,10,10,10c2.035,0,3.928-0.614,5.509-1.663l5.077,5.077c0.78,0.781,2.048,0.781,2.828,0 C28.195,26.633,28.195,25.367,27.414,24.586z M7,14c0-3.86,3.14-7,7-7s7,3.14,7,7s-3.14,7-7,7S7,17.86,7,14z"})}),close:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"})}),eye:jsxRuntime.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:[jsxRuntime.jsx("path",{fill:"#333",d:"M12 20.5c-4.299 0-8.24-3.023-10.544-8.086a1 1 0 010-.828C3.759 6.523 7.701 3.5 12 3.5s8.24 3.023 10.544 8.086a1.001 1.001 0 010 .828 18.14 18.14 0 01-1.391 2.52 1 1 0 11-1.666-1.106A15.87 15.87 0 0020.529 12C18.543 7.92 15.379 5.5 12 5.5S5.457 7.92 3.471 12c1.986 4.08 5.15 6.5 8.529 6.5a7.964 7.964 0 005.036-1.92 1 1 0 111.265 1.55A9.94 9.94 0 0112 20.5z"}),jsxRuntime.jsx("path",{fill:"#333",d:"M12 16a4.004 4.004 0 01-3.929-4.756 1 1 0 011.965.375A2 2 0 1014 12a2.034 2.034 0 00-2.053-1.999 1.04 1.04 0 01-1.043-.947.963.963 0 01.902-1.05L12 8a4 4 0 010 8z"})]}),eyeSlash:jsxRuntime.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:[jsxRuntime.jsx("path",{fill:"#333",d:"M12 15c-4.132 0-7.98-1.214-10.294-3.249a1 1 0 111.32-1.502C4.986 11.972 8.34 13 12 13s7.014-1.028 8.974-2.751a1 1 0 111.32 1.502C19.98 13.786 16.132 15 12 15z"}),jsxRuntime.jsx("path",{fill:"#333",d:"M12 18a1 1 0 01-1-1v-3a1 1 0 012 0v3a1 1 0 01-1 1zM7.749 17.667a.964.964 0 01-.17-.014 1 1 0 01-.817-1.155l.505-2.935a1 1 0 111.97.339l-.504 2.935a1 1 0 01-.984.83zM3.636 16.306a1.001 1.001 0 01-.942-1.336l.978-2.745a1 1 0 111.884.672l-.978 2.745a1 1 0 01-.942.664zM16.251 17.667a1 1 0 01-.984-.83l-.505-2.935a1 1 0 011.97-.339l.506 2.935a1 1 0 01-.816 1.155.964.964 0 01-.17.014zM20.364 16.306a1 1 0 01-.942-.664l-.978-2.745a1 1 0 111.884-.672l.978 2.745a1.001 1.001 0 01-.942 1.336z"})]}),check:jsxRuntime.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:[" ",jsxRuntime.jsx("path",{d:"M9 16.17 4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z"})," "]}),[Ie.Info]:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",children:jsxRuntime.jsx("path",{fill:"#292D32",d:"M21.56 10.738l-1.35-1.58c-.25-.3-.46-.86-.46-1.26v-1.7c0-1.06-.87-1.93-1.93-1.93h-1.7c-.4 0-.97-.21-1.27-.46l-1.58-1.35c-.69-.59-1.82-.59-2.51 0l-1.6 1.35c-.3.25-.86.46-1.26.46H6.17c-1.06 0-1.93.87-1.93 1.93v1.7c0 .39-.2.95-.45 1.25l-1.35 1.59c-.58.7-.58 1.82 0 2.5l1.35 1.59c.25.29.45.86.45 1.25v1.71c0 1.06.87 1.93 1.93 1.93h1.74c.39 0 .96.21 1.26.46l1.58 1.35c.69.59 1.82.59 2.51 0l1.58-1.35c.3-.25.86-.46 1.26-.46h1.7c1.06 0 1.93-.87 1.93-1.93v-1.7c0-.4.21-.96.46-1.26l1.35-1.58c.61-.68.61-1.81.02-2.51zm-10.31-2.61c0-.41.34-.75.75-.75s.75.34.75.75v4.83c0 .41-.34.75-.75.75s-.75-.34-.75-.75v-4.83zm.75 8.74c-.55 0-1-.45-1-1s.44-1 1-1c.55 0 1 .45 1 1s-.44 1-1 1z"})}),[Ie.Warning]:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",children:jsxRuntime.jsx("path",{fill:"#292D32",d:"M19.51 5.85l-5.94-3.43c-.97-.56-2.17-.56-3.15 0L4.49 5.85a3.15 3.15 0 00-1.57 2.73v6.84c0 1.12.6 2.16 1.57 2.73l5.94 3.43c.97.56 2.17.56 3.15 0l5.94-3.43a3.15 3.15 0 001.57-2.73V8.58a3.192 3.192 0 00-1.58-2.73zm-8.26 1.9c0-.41.34-.75.75-.75s.75.34.75.75V13c0 .41-.34.75-.75.75s-.75-.34-.75-.75V7.75zm1.67 8.88c-.05.12-.12.23-.21.33a.99.99 0 01-1.09.21c-.13-.05-.23-.12-.33-.21-.09-.1-.16-.21-.22-.33a.986.986 0 01-.07-.38c0-.26.1-.52.29-.71.1-.09.2-.16.33-.21.37-.16.81-.07 1.09.21.09.1.16.2.21.33.05.12.08.25.08.38s-.03.26-.08.38z"})}),[Ie.Error]:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",children:jsxRuntime.jsx("path",{d:"M1 21h22L12 2 1 21zm12-3h-2v-2h2v2zm0-4h-2v-4h2v4z"})}),[Ie.Success]:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",children:jsxRuntime.jsx("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-2 15l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z"})}),layers:jsxRuntime.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"100%",height:"100%",viewBox:"0 0 24 24",fill:"none",children:[jsxRuntime.jsx("path",{d:"M19.3697 4.89109L13.5097 2.28109C12.6497 1.90109 11.3497 1.90109 10.4897 2.28109L4.62969 4.89109C3.14969 5.55109 2.92969 6.45109 2.92969 6.93109C2.92969 7.41109 3.14969 8.31109 4.62969 8.97109L10.4897 11.5811C10.9197 11.7711 11.4597 11.8711 11.9997 11.8711C12.5397 11.8711 13.0797 11.7711 13.5097 11.5811L19.3697 8.97109C20.8497 8.31109 21.0697 7.41109 21.0697 6.93109C21.0697 6.45109 20.8597 5.55109 19.3697 4.89109Z",fill:"#292D32"}),jsxRuntime.jsx("path",{d:"M12.0003 17.04C11.6203 17.04 11.2403 16.96 10.8903 16.81L4.15031 13.81C3.12031 13.35 2.32031 12.12 2.32031 10.99C2.32031 10.58 2.65031 10.25 3.06031 10.25C3.47031 10.25 3.80031 10.58 3.80031 10.99C3.80031 11.53 4.25031 12.23 4.75031 12.45L11.4903 15.45C11.8103 15.59 12.1803 15.59 12.5003 15.45L19.2403 12.45C19.7403 12.23 20.1903 11.54 20.1903 10.99C20.1903 10.58 20.5203 10.25 20.9303 10.25C21.3403 10.25 21.6703 10.58 21.6703 10.99C21.6703 12.11 20.8703 13.35 19.8403 13.81L13.1003 16.81C12.7603 16.96 12.3803 17.04 12.0003 17.04Z",fill:"#292D32"}),jsxRuntime.jsx("path",{d:"M12.0003 22.0009C11.6203 22.0009 11.2403 21.9209 10.8903 21.7709L4.15031 18.7709C3.04031 18.2809 2.32031 17.1709 2.32031 15.9509C2.32031 15.5409 2.65031 15.2109 3.06031 15.2109C3.47031 15.2109 3.80031 15.5409 3.80031 15.9509C3.80031 16.5809 4.17031 17.1509 4.75031 17.4109L11.4903 20.4109C11.8103 20.5509 12.1803 20.5509 12.5003 20.4109L19.2403 17.4109C19.8103 17.1609 20.1903 16.5809 20.1903 15.9509C20.1903 15.5409 20.5203 15.2109 20.9303 15.2109C21.3403 15.2109 21.6703 15.5409 21.6703 15.9509C21.6703 17.1709 20.9503 18.2709 19.8403 18.7709L13.1003 21.7709C12.7603 21.9209 12.3803 22.0009 12.0003 22.0009Z",fill:"#292D32"})]}),play:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M8 5v14l11-7z"})}),pause:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M6 19h4V5H6zm8-14v14h4V5z"})}),next:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"m6 18 8.5-6L6 6zM16 6v12h2V6z"})}),prev:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M6 6h2v12H6zm3.5 6 8.5 6V6z"})}),volumeHigh:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{fill:"#292D32",d:"M22 11.25h-1.25V10c0-.41-.34-.75-.75-.75s-.75.34-.75.75v1.25H18c-.41 0-.75.34-.75.75s.34.75.75.75h1.25V14c0 .41.34.75.75.75s.75-.34.75-.75v-1.25H22c.41 0 .75-.34.75-.75s-.34-.75-.75-.75M14.02 3.782c-1.12-.62-2.55-.46-4.01.45l-2.92 1.83c-.2.12-.43.19-.66.19H5c-2.42 0-3.75 1.33-3.75 3.75v4c0 2.42 1.33 3.75 3.75 3.75h1.4300000000000002c.23 0 .46.07.66.19l2.92 1.83c.88.55 1.74.82 2.54.82a3 3 0 0 0 1.47-.37c1.11-.62 1.73-1.91 1.73-3.63v-9.18c0-1.72-.62-3.01-1.73-3.63"})}),volumeMute:jsxRuntime.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:[jsxRuntime.jsx("path",{fill:"#292D32",d:"M18 16.75a.75.75 0 0 1-.6-1.2 5.93 5.93 0 0 0 .72-5.84.75.75 0 0 1 .4-.98c.38-.16.82.02.98.4 1.02 2.42.67 5.23-.9 7.33-.15.19-.37.29-.6.29"}),jsxRuntime.jsx("path",{fill:"#292D32",d:"M19.828 19.25a.75.75 0 0 1-.6-1.2c2.14-2.85 2.61-6.67 1.23-9.96a.75.75 0 0 1 .4-.98c.38-.16.82.02.98.4 1.59 3.78 1.05 8.16-1.41 11.44-.14.2-.37.3-.6.3M14.04 12.958c.63-.63 1.71-.18 1.71.71v2.93c0 1.72-.62 3.01-1.73 3.63a3 3 0 0 1-1.47.37c-.8 0-1.66-.27-2.54-.82l-.64-.4c-.54-.34-.63-1.1-.18-1.55zM21.77 2.229c-.3-.3-.79-.3-1.09 0l-4.95 4.95c-.06-1.6-.66-2.8-1.72-3.39-1.12-.62-2.55-.46-4.01.45l-2.91 1.82c-.2.12-.43.19-.66.19H5c-2.42 0-3.75 1.33-3.75 3.75v4c0 2.42 1.33 3.75 3.75 3.75h.16l-2.94 2.94c-.3.3-.3.79 0 1.09.16.14.35.22.55.22s.39-.08.54-.23l18.46-18.46c.31-.3.31-.78 0-1.08"})]}),plus:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",children:jsxRuntime.jsx("path",{d:"M28 14H18V4a2 2 0 0 0-4 0v10H4a2 2 0 0 0 0 4h10v10a2 2 0 0 0 4 0V18h10a2 2 0 0 0 0-4"})}),add:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M12 2C6.49 2 2 6.49 2 12s4.49 10 10 10 10-4.49 10-10S17.51 2 12 2m4 10.75h-3.25V16c0 .41-.34.75-.75.75s-.75-.34-.75-.75v-3.25H8c-.41 0-.75-.34-.75-.75s.34-.75.75-.75h3.25V8c0-.41.34-.75.75-.75s.75.34.75.75v3.25H16c.41 0 .75.34.75.75s-.34.75-.75.75"})}),chevronUp:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"100%",height:"100%",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"m7 14 5-5 5 5z"})}),chevronBottom:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"100%",height:"100%",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"m7 10 5 5 5-5z"})}),chevronRight:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"100%",height:"100%",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"m10 17 5-5-5-5v10z"})}),chevronLeft:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"100%",height:"100%",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"m14 7-5 5 5 5V7z"})}),chevronRightOutline:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"100%",height:"100%",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M8.59 16.59 13.17 12 8.59 7.41 10 6l6 6-6 6-1.41-1.41z"})}),chevronLeftOutline:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"100%",height:"100%",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M15.41 16.59 10.83 12l4.58-4.59L14 6l-6 6 6 6 1.41-1.41z"})}),chevronUpOutline:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"100%",height:"100%",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M7.41 15.41 12 10.83l4.59 4.58L18 14l-6-6-6 6z"})}),chevronDownOutline:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"100%",height:"100%",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M7.41 8.59 12 13.17l4.59-4.58L18 10l-6 6-6-6 1.41-1.41z"})}),bezier:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"100%",height:"100%",viewBox:"0 0 24 24",fill:"none",children:jsxRuntime.jsx("path",{d:"M19.14 7.72C19.43 8.47 20.15 9 21 9C22.1 9 23 8.1 23 7C23 5.9 22.1 5 21 5C20.15 5 19.43 5.53 19.14 6.28C19.09 6.27 19.05 6.25 19 6.25H15V5.5C15 4.68 14.32 4 13.5 4H10.5C9.68 4 9 4.68 9 5.5V6.25H5C4.95 6.25 4.91 6.27 4.86 6.28C4.57 5.53 3.85 5 3 5C1.9 5 1 5.9 1 7C1 8.1 1.9 9 3 9C3.85 9 4.57 8.47 4.86 7.72C4.91 7.73 4.95 7.75 5 7.75H7.57C5.52 9.27 4.25 11.79 4.25 14.5C4.25 14.67 4.26 14.83 4.28 15H4C3.17 15 2.5 15.67 2.5 16.5V18.5C2.5 19.33 3.17 20 4 20H6C6.22 20 6.42 19.95 6.61 19.86C7.13 19.64 7.5 19.11 7.5 18.5V16.5C7.5 15.67 6.83 15 6 15H5.77C5.77 14.97 5.78 14.94 5.78 14.91C5.76 14.77 5.76 14.64 5.76 14.5C5.76 12.03 7.03 9.77 9.02 8.6C9.06 9.37 9.71 10 10.5 10H13.5C14.29 10 14.94 9.37 14.99 8.6C16.98 9.77 18.25 12.04 18.25 14.5C18.25 14.64 18.24 14.77 18.23 14.91C18.23 14.94 18.24 14.97 18.24 15H18C17.17 15 16.5 15.67 16.5 16.5V18.5C16.5 19.11 16.87 19.64 17.39 19.86C17.58 19.95 17.78 20 18 20H20C20.83 20 21.5 19.33 21.5 18.5V16.5C21.5 15.67 20.83 15 20 15H19.72C19.74 14.83 19.75 14.67 19.75 14.5C19.75 11.79 18.48 9.27 16.43 7.75H19C19.05 7.75 19.09 7.73 19.14 7.72Z",fill:"#292D32"})}),mouse:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"100%",height:"100%",viewBox:"0 0 24 24",fill:"none",children:jsxRuntime.jsx("path",{d:"M13.2978 2.11468C13.0064 2.06339 12.75 2.29593 12.75 2.59185V5.45262C12.75 5.65098 12.8709 5.82564 13.0359 5.93583C13.5391 6.27202 13.87 6.84597 13.87 7.49906V9.49906C13.87 10.5291 13.03 11.3791 12 11.3791C10.96 11.3791 10.12 10.5291 10.12 9.49906V7.49906C10.12 6.84578 10.4583 6.27168 10.9639 5.93554C11.1291 5.82572 11.25 5.65098 11.25 5.45262V2.59249C11.25 2.29634 10.9935 2.0637 10.7019 2.11513C9.15243 2.38834 7.76579 3.13327 6.7 4.19906C5.34 5.55906 4.5 7.43906 4.5 9.49906V14.4991C4.5 18.6291 7.87 21.9991 12 21.9991C16.13 21.9991 19.5 18.6291 19.5 14.4991V9.49906C19.5 5.80857 16.813 2.73328 13.2978 2.11468Z",fill:"#292D32"})}),addKey:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"100%",height:"100%",viewBox:"0 0 24 24",fill:"none",children:jsxRuntime.jsx("path",{d:"M20.9498 14.55L14.5598 20.94C13.1598 22.34 10.8598 22.34 9.44977 20.94L3.05977 14.55C1.65977 13.15 1.65977 10.85 3.05977 9.44L9.44977 3.05C10.8498 1.65 13.1498 1.65 14.5598 3.05L20.9498 9.44C22.3498 10.85 22.3498 13.15 20.9498 14.55Z",fill:"#292D32"})}),calendar:jsxRuntime.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:[jsxRuntime.jsx("path",{fill:"#292D32",d:"M8.25 5.75c-.41 0-.75-.34-.75-.75V2c0-.41.34-.75.75-.75S9 1.59 9 2v3c0 .41-.34.75-.75.75M15.75 5.75c-.41 0-.75-.34-.75-.75V2c0-.41.34-.75.75-.75s.75.34.75.75v3c0 .41-.34.75-.75.75M12 14.09c.52 0 .9-.31.9-.8 0-.5-.38-.79-.9-.79s-.9.29-.9.79c0 .49.38.8.9.8M12 17c.629 0 1.14-.416 1.14-.93 0-.513-.511-.93-1.14-.93-.63 0-1.14.417-1.14.93s.51.93 1.14.93"}),jsxRuntime.jsx("path",{fill:"#292D32",d:"M19.57 4.5c-.66-.49-1.61-.02-1.61.81v.1c0 1.17-.84 2.25-2.01 2.37-1.35.14-2.49-.92-2.49-2.24V4.5c0-.55-.45-1-1-1h-.92c-.55 0-1 .45-1 1v1.04c0 .79-.41 1.49-1.03 1.88-.09.06-.19.11-.29.16q-.135.075-.3.12c-.12.04-.25.07-.39.08q-.24.03-.48 0c-.14-.01-.27-.04-.39-.08q-.15-.045-.3-.12c-.1-.05-.2-.1-.29-.16-.63-.44-1.03-1.2-1.03-2.01v-.1c0-.77-.82-1.23-1.47-.9-.01.01-.02.01-.03.02-.04.02-.07.04-.11.07-.03.03-.07.05-.1.08-.28.22-.53.47-.74.74-.11.12-.2.25-.28.38a3.498 3.498 0 0 0-.27.46c-.02.02-.03.03-.03.05-.06.12-.12.24-.16.37-.03.05-.04.09-.06.14-.06.15-.1.3-.14.45-.04.14-.07.29-.09.44a5.902 5.902 0 0 0-.06.76v8.76A4.87 4.87 0 0 0 7.37 22h9.26a4.87 4.87 0 0 0 4.87-4.87V8.37c0-1.59-.76-2.98-1.93-3.87M12 18.25c-1.55 0-2.5-.77-2.5-2.01 0-.68.35-1.27.96-1.62-.44-.31-.73-.77-.73-1.4 0-1.3 1.04-1.97 2.27-1.97s2.26.67 2.26 1.97c0 .63-.28 1.09-.73 1.4.62.35.97.94.97 1.62 0 1.24-.96 2.01-2.5 2.01"})]}),done:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"M9 16.2 4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4z"})}),doneAll:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{d:"m18 7-1.41-1.41-6.34 6.34 1.41 1.41zm4.24-1.41L11.66 16.17 7.48 12l-1.41 1.41L11.66 19l12-12zM.41 13.41 6 19l1.41-1.41L1.83 12z"})}),pending:jsxRuntime.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:[jsxRuntime.jsx("path",{d:"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2M12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8"}),jsxRuntime.jsx("path",{d:"M12.5 7H11v6l5.25 3.15.75-1.23-4.5-2.67z"})]})},O=Vi;var Di=({title:e="Alert",onClose:r})=>jsxRuntime.jsxs(p,{as:"--head flex aic rel",children:[jsxRuntime.jsx(p,{as:`--${e?"title":"dot"} flex aic jcc rel`,children:e}),jsxRuntime.jsx(F,{onClick:t=>r(),className:"--closer abs center-v",children:O.close})]}),an=Di;var mn=({ref:e,...r})=>{let{index:t,id:n,title:o,message:s,transition:a,curve:l,speed:f,type:c,action:i,actionPosition:d,spinner:u,loadingMessage:m,variant:h,inBackground:C,forceClose:x,forceLoading:T,onClose:S,onShow:P,onHide:g,...v}=r,y=react.useMemo(()=>core.uuid(12),[]),[b,I]=react.useState(o||""),[D,N]=react.useState(s||""),[A,L]=react.useState(c||st.Dialog),[M,$]=react.useState(false),[K,R]=react.useState(true),[B,q]=react.useState(i||null),[X,H]=react.useState(false),{variant:z,spinner:W,dialog:Z}=j(true),re=h||Z?.variant||z||U.Small,{style:Q,className:se,rest:me}=E(v),ge=react.useRef(null),ae=ye({when:M,duration:f||Z?.speed||.3,delay:Z?.delay||.1,transition:a||Z?.transition||Y.SlideInBottom,curve:l||Z?.curve||ee.EaseInOut,watch:["scale","filter","transform"]}),le=()=>{$(false),S(n);},G=react.useMemo(()=>[{keys:[hooks.KeyCode.Escape],callback:()=>{Ee.isTop(le)&&le();}}],[M]);hooks.useShortcuts(G),react.useEffect(()=>{L(st.Dialog),N(s),I(b),B&&q(B.reduce((ie,ue)=>(ie.push({...ue,key:ue.key||core.uuid(12)}),ie),[])),$(true),setTimeout(()=>P?P():()=>{},500);},[]),react.useEffect(()=>{x&&le();},[x]),react.useEffect(()=>{T!=null&&H(T);},[T]),react.useEffect(()=>(M?Ee.push(le):Ee.pop(le),()=>Ee.pop(le)),[M]);let te=react.useMemo(()=>1e4+t*10,[t]);return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(Ye,{style:{zIndex:te},when:M}),jsxRuntime.jsxs(p,{as:`--dialog --${(c??st.Default).toLowerCase()} ${M?"--visible":""} ${se} fixed abc`.trim(),style:{...ae.style,zIndex:te+1,pointerEvents:C==true?"none":"auto",...C==true?{scale:"0.92",filter:"blur(2px)"}:{}},...me,ref:ge,children:[jsxRuntime.jsx(an,{title:b,onClose:le}),jsxRuntime.jsx(on,{message:D,render:K,action:B}),B&&B.length>0&&jsxRuntime.jsx(nn,{variant:re,action:B,dialogID:y,actionPosition:d}),jsxRuntime.jsx(Le,{when:X,spinner:u||Z?.spinner||W?.type||xe.Simple,message:m||Z?.loadingMessage})]})]})};mn.displayName="Zuz.Dialog";var Oo=mn;var pn=react.forwardRef((e,r)=>{let{speed:t,smooth:n=false,breakpoints:o={},style:s,...a}=e,{rootRef:l,containerRef:f,thumbY:c,thumbX:i,onScrollY:d,onScrollX:u}=hooks.useScrollbar(t||1,o,n),{style:m,className:h,rest:C}=E(a);return react.useEffect(()=>{let x=f.current;if(!x)return;let T=()=>{window.dispatchEvent(new Event("resize"));},S=P=>{let g=P.target;if(g.closest(".--allow-scroll")){let y=g.closest(".--allow-scroll"),{scrollTop:b,scrollHeight:I,clientHeight:D}=y,N=P.deltaY<0,A=P.deltaY>0;(N&&b>0||A&&b+D<I)&&P.stopPropagation();}};return x.addEventListener("scroll",T),x.addEventListener("wheel",S,{passive:true}),()=>{x.removeEventListener("scroll",T),x.removeEventListener("wheel",S);}},[f]),jsxRuntime.jsxs(p,{ref:l,className:h.trim(),as:"--scrollview rel",children:[jsxRuntime.jsx(p,{as:`--scroll-content ${h}`.trim(),ref:f,style:s||{},children:C.children}),jsxRuntime.jsx(p,{as:"--scroll-track --track-y --abs",children:jsxRuntime.jsx(p,{as:"--scroll-thumb --abs",ref:c,onMouseDown:d})}),jsxRuntime.jsx(p,{as:"--scroll-track --track-x --abs",children:jsxRuntime.jsx(p,{as:"--scroll-thumb --abs",ref:i,onMouseDown:u})})]})});pn.displayName="Zuz.ScrollView";var Vo=pn;var un=({ref:e,...r})=>{let{id:t,index:n,from:o,speed:s,children:a,margin:l,animation:f,prerender:c,inBackground:i,forceClose:d,forceLoading:u,onClose:m,...h}=r,{drawer:C}=j(true),[x,T]=react.useState(a),[S,P]=react.useState(false),[g,v]=react.useState(c??(C?.prerender||true)),[y,b]=react.useState(false),I=()=>{P(false),m?.(t??-1);},{className:D,style:N,rest:A}=E(h),L=react.useMemo(()=>[{keys:[hooks.KeyCode.Escape],callback:()=>{Ee.isTop(I)&&I();}}],[S]);hooks.useShortcuts(L),react.useEffect(()=>{T(a);},[a]),react.useEffect(()=>(S?Ee.push(I):Ee.pop(I),()=>Ee.pop(I)),[S]),react.useEffect(()=>{P(true);},[]),react.useEffect(()=>{d&&I();},[d]),react.useEffect(()=>{u!=null&&b(u);},[u]);let M=o||C?.from||Se.Left,$=react.useMemo(()=>{switch(M){case Se.Left:return {from:{x:"-100vw"},to:{x:0}};case Se.Right:return {from:{x:"100vw"},to:{x:0}};case Se.Top:return {from:{y:"-100vh"},to:{y:0}};case Se.Bottom:return {from:{y:"100vh"},to:{y:0}};default:return {from:{x:"-100vw"},to:{x:0}}}},[o,C?.from]),K=ye({from:{...$.from,opacity:0},to:{...$.to,opacity:1},when:S,curve:f||C?.animation||ee.EaseInOut,duration:s||C?.speed||.5,watch:["scale","filter"]}),R=react.useMemo(()=>1e4+(n||1)*10,[n]);return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(Ye,{onClick:B=>{S&&I();},when:S,style:{zIndex:R}}),jsxRuntime.jsxs(p,{ref:e,"aria-hidden":!S,className:`--drawer flex cols ${D} --${M.toLowerCase()} fixed`,style:{...N,...K.style,"--m":`${l||C?.margin||0}px`,zIndex:R+1,pointerEvents:i==true?"none":"auto",...i==true?{scale:"0.92",filter:"blur(2px)"}:{}},...A,children:[o==Se.Top||o==Se.Bottom?jsxRuntime.jsx(p,{className:"--handle"}):null,jsxRuntime.jsx(F,{as:"--close-drawer --abs",onClick:I,children:O.close}),jsxRuntime.jsxs(Vo,{as:"rel",children:[g||S?x:null,jsxRuntime.jsx(Le,{when:y})]})]})]})};un.displayName="Zuz.Drawer";var Ao=un;var dn=react.forwardRef((e,r)=>{let{progress:t,type:n,animated:o,...s}=e,a=react.useRef(null);react.useImperativeHandle(r,()=>({setProgress:i=>{a.current.style.width=`${i*100}%`,a.current.setAttribute("data-value",i+"");},getProgress:()=>+(a.current.getAttribute("data-value")||0)}),[]),react.useEffect(()=>{t&&a.current&&(o?setTimeout(()=>a.current.style.width=`${t*100}%`,500):a.current.style.width=`${t*100}%`,a.current.setAttribute("data-value",t+""));},[t,a.current]);let{className:l,style:f,rest:c}=E(s);return jsxRuntime.jsx(p,{className:`--progress ${o?"--animated":""} flex rel ${l}`.trim(),style:f,...c,children:jsxRuntime.jsx(p,{ref:a,className:"--bar rel"})})});dn.displayName="Zuz.ProgressBar";var Qe=dn;var Ut=(s=>(s.Default="default",s.Success="success",s.Error="error",s.Warn="warn",s.Promise="promise",s))(Ut||{}),qt=(a=>(a.TopLeft="TopLeft",a.TopCenter="TopCenter",a.TopRight="TopRight",a.BottomLeft="BottomLeft",a.BottomCenter="BottomCenter",a.BottomRight="BottomRight",a))(qt||{}),gn=(t=>(t.Stack="stack",t.Individual="individual",t))(gn||{}),hn={success:"Action Successful",error:"Something Went Wrong",warn:"Heads Up",default:"Notice"};var Ji=e=>{let{index:r,id:t,type:n,icon:o,busy:s,width:a,title:l,message:f,duration:c,sticky:i=false,actions:d=[],position:u,style:m,isHovered:h,total:C,progress:x,progressValue:T,forceClose:S,variant:P,onClick:g,onClose:v}=e,[y,b]=react.useState(false),[I,D]=react.useState(false),{toast:N}=j(true),A=typeof T=="number",L=A?Math.max(0,Math.min(1,T)):void 0,M=I||S,$=u??N?.position??"TopCenter",K=n??N?.type??"default",R=m??N?.style??"stack",B=c??N?.duration??4,q=x??N?.progress??false,X=react.useRef(B*1e3),H=react.useRef(void 0),z=react.useRef(void 0),W=react.useRef(null),Z=ye({when:y&&!M,duration:.3,transition:N?.transition||($.includes("Top")?Y.SlideInTop:$.includes("Bottom")?Y.SlideInBottom:$.includes("Left")?Y.SlideInLeft:Y.SlideInRight),curve:N?.curve||ee.EaseInOut,watch:["transform","opacity","scale","filter"]});react.useEffect(()=>{b(true);let G=te=>{if(z.current!==void 0){let ie=te-z.current;if(!A&&!h&&!i&&!M&&(X.current-=ie,W.current)){let ue=Math.max(0,X.current/(B*1e3)*100);W.current?.setProgress?.(ue/100);}}z.current=te,X.current<=0?D(true):H.current=requestAnimationFrame(G);};return H.current=requestAnimationFrame(G),()=>{H.current&&cancelAnimationFrame(H.current);}},[h,i,M,B]),react.useEffect(()=>{if(M){let G=setTimeout(()=>{v?.(t);},350);return ()=>clearTimeout(G)}},[M,t]);let re=R==="stack",Q=h?r*65:r*8,se=h?1:Math.max(.85,1-r*.05),me=h?1:Math.max(.4,1-r*.2),ge=G=>{g?g(G):s!==true&&(!d||d.length===0)&&D(true);},ae=Z.style.transform||"translate(0, 0)",le=M?ae:`${ae} translateY(${$.includes("Top")?Q:-Q}px) scale(${se})`;return jsxRuntime.jsxs(p,{onClick:ge,as:`--snack --${M?"hidden":"visible"} --${P||N?.variant||U.Medium} --${K} --${$.toLowerCase()} abs flex aic`,style:{...Z.style,zIndex:1e3-r,pointerEvents:M?"none":"auto",opacity:M?Z.style.opacity:me,transform:le,filter:!M&&re&&!h&&r>0?"blur(1px)":"none",cursor:!d||d.length===0?"pointer":"default",transition:`${Z.style.transition}, transform 0.3s ease, opacity 0.3s ease`},children:[jsxRuntime.jsxs(p,{as:"--ico flex aic jcc rel",children:[o?jsxRuntime.jsx(J,{name:o}):jsxRuntime.jsx(p,{as:"--no-icon"}),s===true&&jsxRuntime.jsx(we,{as:"abs abc"})]}),jsxRuntime.jsxs(p,{as:"--meta flex cols",style:a?{width:a,minWidth:a,maxWidth:a}:void 0,children:[jsxRuntime.jsx(_,{as:"--tt",children:l||hn[n]}),jsxRuntime.jsx(_,{as:"--tm",children:f})]}),d&&d.length>0&&jsxRuntime.jsx(p,{as:"--actions flex gap:5",children:d.map((G,te)=>jsxRuntime.jsx(F,{as:"--snack-btn bold",variant:U.XSmall,onClick:ie=>{ie.stopPropagation(),G.onClick(ie);},children:G.label},te))}),(q||A)&&jsxRuntime.jsx(Qe,{as:"abs",progress:L,ref:W})]})},zo=Ji;var Ce=react.createContext(null),sl=({ref:e,...r})=>{let n=react.useContext(Ce)?.depth??0,[o,s]=react.useState(null),[a,l]=react.useState(null),[f,c]=react.useState(false),[i,d]=react.useState([]),u=hooks.useDelayed(),m=react.useRef(0),h=()=>++m.current,C=()=>{c(false),setTimeout(()=>l(null),200);};react.useImperativeHandle(e,()=>({add(g){let v=h(),y={id:v,...g};return d(b=>[...b,y]),v},openMenu(g){c(false),setTimeout(()=>{l({id:h(),type:"menu",props:g}),c(true);},16);},update(g,v){d(y=>y.map(b=>b.id!==g?b:{...b,props:{...b.props,...v}}));},remove(g){d(v=>v.map(y=>y.id===g?{...y,props:{...y.props,forceClose:true}}:y)),a?.id===g&&C();},loading(g,v){d(y=>y.map(b=>b.id===g?{...b,props:{...b.props,forceLoading:v}}:b)),a?.id===g&&C();},clear(g){d(i.filter(v=>v.type!=g));}})),react.useEffect(()=>{if(a&&f){let g=()=>C();return document.addEventListener("click",g),()=>document.removeEventListener("click",g)}},[a,f,C]);let x=g=>{setTimeout(()=>{d(v=>v.filter(y=>y.id!==g)),a?.id===g&&l(null);},250);},T=react.useMemo(()=>[...i.filter(g=>g.type!="toast")],[i]);if(!u)return null;let S=i.filter(g=>g.type=="toast").reverse(),P=Object.values(qt);return reactDom.createPortal(jsxRuntime.jsxs(p,{as:"--zuz-layers-wrapper fixed fill nope",style:{zIndex:9999+n},children:[T.map((g,v)=>{let y=v<T.length-1;return g.type==="dialog"?jsxRuntime.jsx(Oo,{onClose:x,index:v,id:g.id,...g.props,inBackground:y},`layer-${g.type}-${g.id}`):g.type==="drawer"?jsxRuntime.jsx(Ao,{onClose:x,index:v,id:g.id,...g.props,inBackground:y},`layer-${g.type}-${g.id}`):null}),P.map(g=>{let v=S.filter(y=>(y.props.position||"TopCenter")===g);return v.length===0?null:jsxRuntime.jsx(p,{onMouseEnter:()=>s(g),onMouseLeave:()=>s(null),as:`--toast-container fixed --${g.toLowerCase()} flex cols`,style:{pointerEvents:"auto",zIndex:"var(--max-z-index)"},children:v.map((y,b)=>jsxRuntime.jsx(zo,{index:b,total:v.length,isHovered:o===g,onClose:x,id:y.id,...y.props},y.id))},g)}),a&&jsxRuntime.jsx(p,{as:"--zuz-layer-menus fixed fill nope",style:{zIndex:"var(--max-z-index)"},children:jsxRuntime.jsx(Bo,{onClose:C,when:f,...a.props},`menu-${a.id}`)})]}),document.body)},al=({children:e})=>{let r=react.useContext(Ce),t=r?r.depth+1:0,n=react.useRef(null),o=react.useMemo(()=>({add:s=>n.current?.add(s),openMenu:s=>n.current?.openMenu(s),update:(s,a)=>n.current?.update(s,a),remove:s=>n.current?.remove(s),loading:(s,a)=>n.current?.loading(s,a),clear:s=>n.current?.clear(s),depth:t,isSubLayer:!!r}),[r]);return jsxRuntime.jsxs(Ce.Provider,{value:o,children:[e,jsxRuntime.jsx(sl,{ref:n})]})},Io=al;var ll=()=>{let e=react.useContext(Ce);if(!e)throw new Error("useContextMenu must be used inside <LayersProvider>");return {showContextMenu:(n,o,s)=>{n.preventDefault(),e.openMenu({event:n,items:o,origin:s});},showMenu:(n,{items:o,origin:s,offsetX:a,offsetY:l,transition:f,curve:c,arrow:i,duration:d,header:u,footer:m})=>{e.openMenu({fx:{transition:f,curve:c,duration:d},parent:n,items:o,origin:s||bt.TopCenter,offsetX:a,offsetY:l,arrow:i,header:u,footer:m});},hide:e.clear}},cl=ll;var pl=()=>{let e=react.useContext(Ce);if(!e)throw new Error("useDialog must be used inside <LayersProvider>");let r=()=>e.clear("dialog"),t=s=>e.remove(s),n=(s,a)=>e.loading(s,a);return {clearAll:r,show:s=>{let a=e.add({type:"dialog",props:{...s,type:st.Dialog}});return {id:a,setLoading:l=>n(a,l),hide:()=>t(a)}},hide:t}},ul=pl;var dl=()=>{let e=react.useContext(Ce);if(!e)throw new Error("useDialog must be used inside <LayersProvider>");let r=()=>e.clear("drawer"),t=s=>e.remove(s),n=(s,a)=>e.loading(s,a),o=s=>{let a=e.add({type:"drawer",props:s});return {id:a,setLoading:l=>n(a,l),close:()=>t(a)}};return {clearAll:r,open:s=>o({children:s}),right:s=>o({children:s,from:Se.Right}),left:s=>o({children:s,from:Se.Left}),top:s=>o({children:s,from:Se.Top}),bottom:s=>o({children:s,from:Se.Bottom}),close:t}},gl=dl;var yl=(e,r,t={})=>{let[n,o]=react.useState(null),[s,a]=react.useState(false),{duration:l=.25,curve:f=ee.EaseOutBack,borderRadius:c={from:40,to:24},targetWidth:i=320}=t;return react.useLayoutEffect(()=>{r&&e.current?(o(e.current.getBoundingClientRect()),a(true)):r||a(false);},[r,e]),{style:ye({from:{opacity:0,width:n?.width,height:n?.height,borderRadius:c.from},to:{opacity:1,width:i,height:"auto",borderRadius:c.to},curve:f,duration:l,when:s&&r}).style,isMeasured:s,sourceRect:n}},xl=yl;var wl=(e,r={})=>{let{offset:t=8,direction:n="bottom",container:o=null,triggerRef:s=null}=r,a=react.useRef(null),l=react.useCallback(()=>{let f=e.current;if(!f)return;let c=s?.current||f.parentElement;if(!c){console.warn("usePosition: No trigger element found. Positioning may not work.");return}let i=f.getBoundingClientRect(),d=c.getBoundingClientRect(),u,m;o?(u=o.getBoundingClientRect(),m="absolute"):(window.getComputedStyle(f).position==="fixed"?m="fixed":m="absolute",m==="fixed"?u={top:0,left:0,right:window.innerWidth,bottom:window.innerHeight,width:window.innerWidth,height:window.innerHeight}:u={top:0,left:0,right:window.innerWidth,bottom:window.innerHeight,width:window.innerWidth,height:window.innerHeight}),f.style.position!==m&&(f.style.position=m),a.current=m;let x=0,T=0;switch(n){case "top":x=d.top-i.height-t,T=d.left,x<u.top&&d.bottom+i.height+t<=u.bottom&&(x=d.bottom+t);break;case "bottom":x=d.bottom+t,T=d.left,x+i.height>u.bottom&&d.top-i.height-t>=u.top&&(x=d.top-i.height-t);break;case "left":x=d.top,T=d.left-i.width-t,T<u.left&&d.right+i.width+t<=u.right&&(T=d.right+t);break;case "right":x=d.top,T=d.right+t,T+i.width>u.right&&d.left-i.width-t>=u.left&&(T=d.left-i.width-t);break}if(x=Math.max(u.top,Math.min(x,u.bottom-i.height)),T=Math.max(u.left,Math.min(T,u.right-i.width)),a.current==="fixed")f.style.top=`${x}px`,f.style.left=`${T}px`;else {let S;f.offsetParent?S=f.offsetParent.getBoundingClientRect():S={top:0,left:0};let P=x-S.top+window.scrollY,g=T-S.left+window.scrollX;f.style.top=`${P}px`,f.style.left=`${g}px`;}},[e,s,t,n,o]);return react.useEffect(()=>{let f=e.current;if(!f)return;let c=s?.current||f.parentElement;if(!c){console.warn("usePosition: No trigger element found. Positioning may not work.");return}let i=new ResizeObserver(l);return i.observe(f),c&&i.observe(c),l(),window.addEventListener("resize",l),window.addEventListener("scroll",l,true),()=>{i.disconnect(),c&&i.disconnect(),window.removeEventListener("resize",l),window.removeEventListener("scroll",l,true);}},[e,n,t,o,s]),{postion:a.current,reposition:l}},Pt=wl;var Tl=()=>{let e=react.useContext(Ce);if(!e)throw new Error("useToast must be used inside <LayersProvider>");let r=(m,h)=>e.add({type:"toast",props:{...h,type:m}}),t=()=>e.clear("toast"),n=m=>e.remove(m),o=(m,h)=>e.update(m,h),s=m=>({id:m,update:h=>o(m,h),setType:h=>o(m,{type:h}),setProgress:h=>o(m,{progress:true,progressValue:h}),setBusy:h=>o(m,{busy:h}),success:()=>o(m,{type:"success"}),error:()=>o(m,{type:"error"}),warn:()=>o(m,{type:"warn"}),promise:()=>o(m,{type:"promise"}),default:()=>o(m,{type:"default"}),hide:()=>n(m)}),a=m=>s(r("default",m)),l=m=>s(r("success",m)),f=m=>s(r("error",m)),c=m=>s(r("warn",m)),i=m=>s(r("promise",m)),d=(m,h,C)=>{let x=r(m,{...h,sticky:h.sticky??false,actions:[{label:C?.label||"Ok",onClick:T=>{C?.onClick?.(T),n(x);}}]});return s(x)},u=(m,h,C,x)=>{let T=r(m,{...h,sticky:true,actions:[{label:C?.label||"Ok",onClick:S=>{C?.onClick?.(S),(C?.hide??false)===true&&n(T);}},{label:x?.label||"Cancel",onClick:S=>{x?.onClick?.(S),(x?.hide??true)===true&&n(T);}}]});return s(T)};return {show:a,hide:n,promise:i,clearAll:t,ok:(m,h)=>d("default",m,h),success:(m,h)=>h?d("success",m,h):l(m),error:(m,h)=>h?d("error",m,h):f(m),confirm:(m,h,C)=>u("default",m,h,C),warn:(m,h)=>h?d("warn",m,h):c(m),succes:(m,h)=>h?d("success",m,h):l(m)}},Pl=Tl;var Il=()=>{let e=react.useContext(Ce);if(!e)throw new Error("useToast must be used inside <LayersProvider>");let r=(c,i)=>e.add({type:"toast",props:{...i,type:c}});return {show:(c,i,d,u)=>r("default",{title:c,message:i,icon:d,duration:u}),hide:c=>e.remove(c),success:(c,i,d,u)=>r("success",{title:c,message:i,icon:d,duration:u}),error:(c,i,d,u)=>r("error",{title:c,message:i,icon:d,duration:u}),warn:(c,i,d,u)=>r("warn",{title:c,message:i,icon:d,duration:u}),promise:(c,i,d,u)=>r("promise",{title:c,message:i,icon:d,duration:u}),clearAll:()=>e.clear("toast")}},Fo=Il;var Tn=({ref:e,style:r,...t})=>{let n=react.useRef(null),o=react.useMemo(()=>e&&typeof e!="function"&&e.current?e:n,[e]),{style:s,className:a,rest:l}=E(t,o);return jsxRuntime.jsx("div",{ref:e||n,style:{...s,...r||{}},className:a,...l})};Tn.displayName="Zuz.Box";var p=Tn;var Rn=react.forwardRef((e,r)=>{let{title:t,message:n,...o}=e,[s,a]=react.useState(false);return jsxRuntime.jsxs(p,{className:"--accordion flex cols",...o,children:[jsxRuntime.jsxs(F,{onClick:l=>a(!s),className:`--toggle flex aic ${s?"--open":""}`.trim(),children:[jsxRuntime.jsx(_,{className:"--label flex",children:t}),jsxRuntime.jsx(p,{className:"--arrow flex",children:s?O.arrowUp:O.arrowDown})]}),s&&jsxRuntime.jsx(p,{className:"--detail",children:n})]})});Rn.displayName="Zuz.Accordion";var Ml=Rn;var Ol=({label:e,icon:r,onClick:t,idx:n,selected:o})=>jsxRuntime.jsx(F,{onClick:t,onMouseMove:s=>document.documentElement.style.setProperty("--tip-m",`${n}`),className:`--action ${o?"--selected":""} aic jcc rel`.trim(),children:typeof r=="string"?jsxRuntime.jsx(J,{name:r}):r}),Nn=Ol;var En=react.forwardRef((e,r)=>{let{items:t,name:n,selected:o,position:s,...a}=e,l=react.useRef(null),[f,c]=react.useState(o||t[0].tag||0),i=react.useCallback(({x,y:T})=>{if(l.current){let S=l.current.getBoundingClientRect();document.documentElement.style.setProperty("--tip-x",`${x-S.left}`),document.documentElement.style.setProperty("--tip-y",`${T-S.top}`),document.documentElement.style.setProperty("--tip-s","1");}},[]),d=react.useCallback(()=>{l.current&&(l.current.removeEventListener("pointerleave",d),l.current.removeEventListener("pointermove",i),document.documentElement.style.setProperty("--tip-s","0"));},[]),u=react.useCallback(()=>{l.current&&(l.current.addEventListener("pointerleave",d),l.current.addEventListener("pointermove",i));},[]);react.useEffect(()=>{l.current&&(document.documentElement.style.setProperty("--tip-w",t.reduce((x,T)=>T.label.length>x.length?T.label:x,"").length.toString()),document.documentElement.style.setProperty("--tip-s","0"),document.documentElement.style.setProperty("--tip-l",`${t.length}`),l.current?.addEventListener("pointerenter",u));},[]);let{className:m,style:h,rest:C}=E(a);return jsxRuntime.jsxs(p,{ref:l,style:h,className:[`--actionbar flex aic ${m}`,`${!s||s==he.Auto?"rel":`--${s}`}`].join(" ").trim(),...C,children:[t.map((x,T)=>jsxRuntime.jsx(Nn,{selected:f===x.tag||o==T,...x,idx:T},`actionbar-action-${x.label.toLowerCase().replace(/\s+/g,"-")}`)),jsxRuntime.jsx(p,{className:"--tip abs",children:jsxRuntime.jsx(p,{className:"--track flex aic",children:t.map(({label:x})=>jsxRuntime.jsx(p,{className:"--lb",children:x},`tool-tip-${x.toLowerCase().replace(/\s+/g,"-")}`))})})]})});En.displayName="Zuz.ActionBar";var $l=En;var kn=react.forwardRef((e,r)=>{let{type:t,icon:n,title:o,message:s,iconSize:a,...l}=e,{className:f,style:c,rest:i}=E(l);return jsxRuntime.jsxs(p,{className:`--alert --${t||Ie.Info} flex aic ${f}`.trim(),style:c,...i,children:[jsxRuntime.jsx(p,{className:`--icon icon-${n||"auto-matic"}`,style:a?{fontSize:a,width:a,height:a}:{},children:!n&&O[t||Ie.Info]}),jsxRuntime.jsxs(p,{className:"--meta flex cols",children:[jsxRuntime.jsx(_,{className:`--title ${s?"--tm":""}`,children:o||"Lorem ipsum dolor sit amet, consectetur adipiscing elit."}),s&&jsxRuntime.jsx(_,{className:"--message",h:2,children:s})]})]})});kn.displayName="Zuz.Alert";var _l=kn;var Go=react.createContext(null),Uo=()=>{let e=react.useContext(Go);return e?react.useSyncExternalStore(e.subscribe,e.getSnapshot,e.getSnapshot):null},qo=()=>react.useContext(Go),Fe=()=>{let e=qo(),r=Uo();return {...e,...r}},On=({children:e,initialValues:r={}})=>{let t=react.useRef({values:r,errors:{},touched:{}}),n=react.useRef(new Set(Object.keys(r))),o=react.useRef(new Set),s=react.useCallback(()=>t.current,[]),a=react.useCallback(c=>(o.current.add(c),()=>o.current.delete(c)),[]),l=()=>{o.current.forEach(c=>c());};react.useEffect(()=>{if(r&&Object.keys(r).length>0){let c=new Set(Object.keys(r)),i=[...n.current].filter(u=>!c.has(u)),d={...t.current.values};i.forEach(u=>delete d[u]),t.current={...t.current,values:{...d,...r}},n.current=c,l();}},[r]);let f=react.useMemo(()=>({subscribe:a,getSnapshot:s,setFieldValue:(c,i)=>{t.current.values[c]!==i&&(t.current={...t.current,values:{...t.current.values,[c]:i}},l());},deleteFieldValue:c=>{if(!(c in t.current.values))return;let{[c]:i,...d}=t.current.values;t.current={...t.current,values:d},l();},setFieldError:(c,i)=>{t.current={...t.current,errors:{...t.current.errors,[c]:i}},l();},reset:()=>{t.current={values:{},errors:{},touched:{}},l();}}),[]);return jsxRuntime.jsx(Go.Provider,{value:f,children:e})};var Dn=({ref:e,...r})=>{let{variant:t,numeric:n,name:o,onConfirm:s,...a}=r,{style:l,className:f,rest:c}=E(a),{variant:i}=j(true),d=react.useRef(null),u=Fe(),m=o?u.errors?.[o]:null,h=o&&u.values&&u.setFieldValue,C=h?u.values?.[o]:void 0,x=hooks.useDebounce(S=>{h&&u.setFieldValue?.(o,S);},500),T=S=>{let P=S.currentTarget.value;n&&(P=P.replace(/[^0-9.]/g,"").replace(/(\..*?)\..*/g,"$1"),S.currentTarget.value=P),x(P),r.onInput?.(S);};return react.useEffect(()=>{d.current&&o&&C!==void 0&&d.current.value!==String(C)&&(d.current.value=String(C));},[C,o]),react.useEffect(()=>()=>{h&&u.deleteFieldValue?.(o);},[]),jsxRuntime.jsx("input",{name:o,className:`--input --${t||i} ${m?"--has-error":""} --flex ${f}`.trim(),style:l,defaultValue:C??r.defaultValue??"",onInput:T,onKeyDown:S=>{S.key=="Enter"&&s?.(S.currentTarget.value);},ref:S=>{d.current=S,typeof e=="function"?e(S):e&&(e.current=S);},...c})};Dn.displayName="Zuz.Input";var fe=Dn;var An=e=>{let{meta:r,children:t}=e,n=hooks.useDelayed(),{label:o,icon:s,...a}=react.isValidElement(r)?{}:r,{className:l,style:f,rest:c}=E({...a,...a.animate?{animate:{...a.animate,when:n}}:{}});return react.isValidElement(r)?jsxRuntime.jsx("li",{style:f,className:l,children:r}):jsxRuntime.jsxs("li",{style:f,className:l,...c,children:[t,typeof r=="string"?r:o]})};An.displayName="Zuz.ListItem";var $n=An;var Fn=react.forwardRef((e,r)=>{let{items:t,variant:n,direction:o,seperator:s,ol:a,...l}=e,{className:f,style:c,rest:i}=E(l),d=a==true?"ol":"ul";return react.createElement(d,{className:`--list --${n||U.Small} flex ${o??"cols"} ${f}`.trim(),style:c,ref:r,...i,children:t.map((u,m,h)=>{let C=`${typeof u=="string"?`li-${String(u)}`:react.isValidElement(u)?`li-${u.key}`||`${m}-${core.MD5(u.toString())}`:u.label}-${m}`;return jsxRuntime.jsxs(react.Fragment,{children:[jsxRuntime.jsx($n,{meta:u}),s&&h[m+1]?jsxRuntime.jsx("li",{className:"--list-seperator",children:s},`spt-${m+1}-${C}`):null]},C)})})});Fn.displayName="Zuz.List";var et=Fn;var Kn=react.forwardRef((e,r)=>{let{fx:t,action:n,data:o,withStyle:s,onChange:a,...l}=e,{className:f}=E({as:s||""}),{style:c}=E(l),[i,d]=react.useState(false),[u,m]=react.useState(o||[]),h=react.useRef(null),C=react.useRef(null),x=react.useRef(null),T=react.useMemo(()=>l.name||core.uuid(12),[]),[S,P]=react.useState(null),[g,v]=react.useState(null),[y,b]=react.useState([]),D=hooks.useDebounce(R=>{R.target.value==""?(d(false),m([])):n&&R.target.value.trim()!=""&&core.withPost(n,{query:R.target.value}).then(B=>{"items"in B&&core._(B.items).isArray()?(m(B.items),v(R.target.value),b(B.items)):console.error("Action Response should contain items array"),P(null);}).catch(B=>{P(null),m([]);});},250),N=()=>{if(C.current){let R=C.current.getBoundingClientRect(),B=window.innerHeight-R.bottom,q=R.top;if(x.current){let X=x.current;B<X.offsetHeight&&q>B?(X.style.top="auto",X.style.bottom=`${R.height}px`,X.style.maxHeight=`${q-150}px`):(X.style.top=`${R.height+5}px`,X.style.bottom="auto",X.style.maxHeight=`${B-150}px`);}}},A=R=>{if(u.length>0){if((R.key==="ArrowDown"||R.key==="ArrowUp")&&(R.preventDefault(),R.stopPropagation()),R.key==="Escape")P(null),d(false),m([]);else if(R.key==="ArrowDown")P(B=>{let q=B===null||B===u.length-1?0:B+1;return M(q),q});else if(R.key==="ArrowUp")P(B=>{let q=B===null||B===0?u.length-1:B-1;return M(q),q});else if(R.key==="Enter"&&S!==null){let B=u[S];h.current&&(h.current.value=B,d(false),m([]));}}},L=R=>{h.current&&(h.current.value=R,d(false),m([]));},M=R=>{let B=u[R];if(B&&h.current&&(h.current.value=B,h.current.setSelectionRange(B.length,B.length)),x.current){let X=x.current.children[R];X&&X.scrollIntoView({block:"nearest"});}},$=R=>{C.current&&!C.current.contains(R.target)&&(d(false),m([]));},K=()=>{h.current&&h.current.value===g&&(m(y),P(null),N());};return react.useEffect(()=>(window.addEventListener("resize",N),window.addEventListener("scroll",N,true),document.addEventListener("mousedown",$),()=>{window.removeEventListener("resize",N),window.removeEventListener("scroll",N,true),document.removeEventListener("mousedown",$);}),[]),react.useEffect(()=>{N();},[u]),jsxRuntime.jsxs(p,{style:c,ref:C,className:`--autocomplete --${e.size||U.Small} flex aic rel ${f}`.trim(),children:[jsxRuntime.jsx(fe,{ref:h,autoComplete:"off",onChange:D,onKeyDown:A,onFocus:K,...l}),jsxRuntime.jsx(p,{className:"--arrow rel flex aic jcc",children:u.length>0?O.arrowUp:O.arrowDown}),u.length>0&&jsxRuntime.jsx(et,{id:T,ref:x,className:"--suggestion-list flex cols abs",items:u.map((R,B)=>({label:R,onClick:q=>{q.preventDefault(),q.stopPropagation(),L(R);},className:S===B?"--current":"",animate:{transition:Y.SlideInBottom,curve:ee.EaseInOut,delay:core.clamp(.02*B,.02,.5)}}))})]})});Kn.displayName="Zuz.AutoComplete";var fc=Kn;var Zn=react.forwardRef((e,r)=>{let t=react.useRef(null),n=react.useMemo(()=>r&&typeof r!="function"&&r.current?r:t,[r]),{style:o,className:s,rest:a}=E(e,n);return !a.src||a.src==""?null:jsxRuntime.jsx("img",{ref:n,style:o,className:`${s} flex`,...a})});Zn.displayName="Zuz.Image";var tt=Zn;var Wn=react.forwardRef((e,r)=>{let{src:t,variant:n,type:o,crossOrigin:s,referrerPolicy:a,fx:l,as:f,alt:c,color:i,style:d,...u}=e,[m,h,C]=hooks.useImage(t??"",s,a),{className:x,style:T,rest:S}=E({fx:l,as:f});return jsxRuntime.jsx(p,{className:`--avatar --${n||U.Small} --${(o||kr.Circle).toLowerCase()} rel flex aic jcc ${x}`.trim(),style:{background:i||"var(--avatar-bg, var(--primary))",...d,...T},...S,children:t?jsxRuntime.jsx(tt,{src:m,crossOrigin:s,referrerPolicy:a,...u}):jsxRuntime.jsx(_,{className:"--avatar-label",children:(c?c.charAt(0):"A").toUpperCase()})})});Wn.displayName="Zuz.Avatar";var Sc=Wn;var wc=({size:e=5,type:r="dead",label:t="",variant:n=U.Small,loading:o=false,spinner:s,...a})=>{let{style:l,className:f,rest:c}=E(a);return jsxRuntime.jsxs(p,{style:{...core._(t).isEmpty()?{"--badge-size":e}:{},...l},as:`--badge --${n} --${r} rel flex aic jcc ${f}`.trim(),children:[jsxRuntime.jsx(p,{fx:{transition:Y.FadeIn,curve:ee.Liquid,duration:.5,when:o},as:"abs abc",children:jsxRuntime.jsx(we,{type:s})}),core._(t).isEmpty()?jsxRuntime.jsx(p,{as:`--dot --${r}`}):jsxRuntime.jsx(_,{as:"--label",children:t})]})},Cc=wc;var Hc=[{label:"Today",getDate:()=>new Date,getDateFormat:()=>dateFns.format(new Date,"EEE")},{label:"Later",getDate:()=>new Date,getDateFormat:()=>dateFns.format(dateFns.addHours(new Date,2),"hh:mm a")},{label:"Tomorrow",getDate:()=>dateFns.addDays(new Date,1),getDateFormat:()=>dateFns.format(dateFns.addDays(new Date,1),"EEE")},{label:"This weekend",getDate:()=>{let e=new Date,r=e.getDay();return dateFns.addDays(e,(6-r)%7||6)},getDateFormat:()=>{let e=new Date,r=e.getDay();return dateFns.format(dateFns.addDays(e,(6-r)%7||6),"EEE, MMM d")}},{label:"Next week",getDateFormat:()=>dateFns.format(dateFns.addWeeks(new Date,1),"EEE, MMM d"),getDate:()=>dateFns.addWeeks(new Date,1)},{label:"Next weekend",getDateFormat:()=>dateFns.format(dateFns.addWeeks(new Date,1),"d MMM"),getDate:()=>dateFns.addWeeks(new Date,1)},{label:"2 weeks",getDateFormat:()=>dateFns.format(dateFns.addWeeks(new Date,2),"d MMM"),getDate:()=>dateFns.addWeeks(new Date,2)},{label:"4 weeks",getDateFormat:()=>dateFns.format(dateFns.addWeeks(new Date,4),"d MMM"),getDate:()=>dateFns.addWeeks(new Date,4)}],Ac=e=>{let r=new Set;return e.filter(t=>{if(t.label=="Later")return true;let n=t.getDate().toISOString().split("T")[0];return r.has(n)?false:(r.add(n),true)})},Un=react.forwardRef((e,r)=>{let{defaultValue:t,variant:n,onChange:o,...s}=e,{style:a,className:l,rest:f}=E(s),[c,i]=react.useState(t||new Date),d=dateFns.startOfMonth(c),u=dateFns.endOfMonth(c),m=dateFns.startOfWeek(d),h=dateFns.endOfWeek(u),C=react.useMemo(()=>dateFns.eachDayOfInterval({start:m,end:h}),[m,h]),x=P=>{o?.(P),i(P);},T=()=>{i(P=>new Date(P.getFullYear(),P.getMonth()-1));},S=()=>{i(P=>new Date(P.getFullYear(),P.getMonth()+1));};return jsxRuntime.jsxs(p,{as:`--calendar flex --${n||"sm"} ${l}`,style:a,children:[jsxRuntime.jsx(p,{as:"--calendar-quick-select flex cols flex:1",children:Ac(Hc).map(P=>{let g=P.getDate();return jsxRuntime.jsxs(F,{onClick:()=>x(g),as:["--calendar-quick-option flex aic gap:5"],children:[jsxRuntime.jsx(_,{as:"flex:1",children:P.label}),jsxRuntime.jsx(_,{as:"tar",children:P.getDateFormat()})]},`--dtp-option-label-${P.label}`)})}),jsxRuntime.jsxs(p,{as:"--calendar-selector flex cols flex:1",children:[jsxRuntime.jsxs(p,{as:"--calendar-head flex aic jcc gap:4",children:[jsxRuntime.jsx(_,{as:"flex:1 --calendar-cm bold",children:dateFns.format(c,"MMMM yyyy")}),jsxRuntime.jsx(F,{onClick:T,as:"--calendar-chevron",children:O.chevronUpOutline}),jsxRuntime.jsx(F,{onClick:S,as:"--calendar-chevron",children:O.chevronDownOutline})]}),jsxRuntime.jsxs(p,{as:"--calendar-days gap:4",children:[["Su","Mo","Tu","We","Th","Fr","Sa"].map(P=>jsxRuntime.jsx(_,{as:"--calendar-day",children:P},`--calendar-hd-${P}`)),C.map((P,g)=>{let v=dateFns.isSameMonth(P,c),y=dateFns.isSameDay(P,c),b=dateFns.isToday(P);return jsxRuntime.jsx(F,{disabled:!v,onClick:()=>x(P),as:["--calendar-day --calendar-dd",`${y?"--calendar-dd-selected":""}`,`${b?"--calendar-dd-current":""}`],children:dateFns.format(P,"d")},`--calendar-day-${g}-${P.getFullYear()}-${P.getMonth()}-${P.getDay()}`)})]})]})]})});Un.displayName="Zuz.Calendar";var Qo=Un;var eo=(t=>(t.Table="table",t.Gooey="gooey",t))(eo||{});var jn=({ref:e,...r})=>{let{itemCount:t,itemsPerPage:n,startPage:o,pageRange:s,paginationStyle:a,breakLabel:l,prevLabel:f,nextLabel:c,hash:i,loading:d,seperator:u,renderOnZeroPageCount:m,asDots:h,progressBar:C,onPageChange:x,...T}=r,S=react.useRef(null),P=react.useMemo(()=>core.toHash(core.numberInRange(4,8)),[]),g=react.useCallback(R=>`${core.toHash(R,i||6,P)}${u||""}${P}`,[P]),v=react.useMemo(()=>l||"...",[l]),y=react.useRef(null),[b,I]=react.useState({id:i?o?typeof o=="number"?g(o):o:1:o||1,label:o||1});react.useImperativeHandle(e,()=>({setPage:R=>I(R),getPage:R=>b,setProgress:R=>y.current?.setProgress?.(R),getProgress:()=>y.current?.getProgress?.()??0}),[y.current]);let{style:D,className:N,rest:A}=E(T),L=react.useCallback(R=>typeof R=="number"?R:+R.label,[]);if(!t)throw new Error('"itemCount" prop is required');let M=react.useMemo(()=>Math.ceil(t/n),[t,n]),$=react.useMemo(()=>{let R=[],B=Math.max(L(b)-(s||2),1),q=Math.min(L(b)+(s||2),M);B>1&&R.push({id:i?g(1):1,label:1}),B>2&&R.push({id:-1,label:v});for(let X=B;X<=q;X++)R.push({id:i?g(X):X,label:X});return q<M-1&&R.push({id:-1,label:v}),q<M&&R.push({id:i?g(M):M,label:M}),R},[b]),K=react.useCallback(R=>{let B=R;+B.label<1||+B.label>M||(I(B),x?.(B));},[t,n,b]);return $.length<=1&&(m??false)===false?null:jsxRuntime.jsxs(p,{ref:S,as:`--pagination ${h===true?"--as-dots":""} --pgt-${a||"table"} flex aic w:100% jcc ${N}`,children:[jsxRuntime.jsx(p,{as:"flex flex:1 aic --pgt-btns",children:($.length>1?$:[{id:1,label:1},{id:-1,label:v}]).map((R,B,q)=>{let X=(typeof R=="string"?R:R.label)==L(b);return jsxRuntime.jsx(F,{disabled:R.id==-1||L(b)==+R.label,className:X?"--current-page":"",onClick:H=>K(R),children:h===true?C===true&&X?jsxRuntime.jsx(Qe,{ref:y}):"":typeof R=="string"?R:R.label},`--pg-${B}-${R.id}`)})}),jsxRuntime.jsx(p,{as:"flex aic jcc flex:1 --pagination-label",children:[`Showing ${(L(b)-1)*n+1} - `,`${Math.min(L(b)*n,t)} of ${t} items`].join(" ")}),jsxRuntime.jsxs(p,{as:"flex aic jce flex:1 --pgt-btns --pgt-nav",children:[jsxRuntime.jsx(F,{disabled:L(b)<=1,onClick:R=>K({id:i?g(L(b)-1):L(b)-1,label:L(b)-1}),children:O.chevronLeftOutline}),jsxRuntime.jsx(F,{disabled:$.length<=1||L(b)==L($[$.length-1]),onClick:R=>K({id:i?g(L(b)+1):L(b)+1,label:L(b)+1}),children:O.chevronRightOutline})]})]})};jn.displayName="Zuz.Pagination";var Nt=jn;function Gc(e,r){let{items:t,renderItem:n,effect:o="slide",loop:s=true,loopMode:a="infinite",startIndex:l=0,useKeys:f=true,useWheel:c=true,spacing:i=160,rotation:d=20,scaleStep:u=.15,blur:m=4,animation:h="power",showDots:C=false,autoPlay:x=false,autoPlaySpeed:T=3,onChange:S,...P}=e,{className:g,style:v}=E(P),y=react.useRef(null),b=T/(T>=1e3?1e3:1),I=hooks.useCarousel({total:t.length,initialIndex:l,loop:s,useKeys:f,useWheel:c,onChange:M=>{y.current?.setPage({id:M+1,label:M+1}),y.current?.setProgress(0),S?.(M);}}),{pause:D,resume:N,reset:A}=hooks.useTimer({duration:b,autoStart:x===true,onProgress:M=>{x===true&&y.current?.setProgress(1-M);},onExpired:()=>{x===true&&I.next(),A();}}),L={...v,"--carousel-spacing":`${i}px`,"--carousel-rotation":`${d}deg`,"--carousel-blur":`${m}px`,"--carousel-scale-step":u,"--active-index":I.index,"--carousel-transition":`var(--${h})`};return jsxRuntime.jsxs(p,{ref:r,className:`--carousel --effect-${o} --loop-${a} flex cols aic jcc ${g}`.trim(),style:L,children:[jsxRuntime.jsx(p,{className:"--carousel-stage rel fill flex aic jcc",children:t.map((M,$)=>{let K=$-I.index;if(a==="infinite"){let B=t.length;K=((K+B/2)%B+B)%B-B/2;}let R=$===I.index;return jsxRuntime.jsx(p,{onMouseEnter:()=>R&&D(),onMouseLeave:()=>R&&N(),className:`--carousel-item-wrapper abs ${R?"--is-active":""}`,style:{"--offset":K,zIndex:R?100:100-Math.abs(K),display:Math.abs(K)>5?"none":"flex"},children:n(M,$,I.index)},$)})}),C&&jsxRuntime.jsx(Nt,{ref:y,itemCount:t.length,itemsPerPage:1,startPage:l+1,pageRange:t.length,paginationStyle:"gooey",onPageChange:M=>I.goTo(+M.label-1),asDots:true,progressBar:true})]})}var Uc=react.forwardRef(Gc),qc=Uc;var Qn=(r=>(r.Line="line",r))(Qn||{});var ts=react.forwardRef((e,r)=>{let{data:t,width:n,height:o,lineColor:s,strokeWidth:a=2,gradientStartColor:l,gradientEndColor:f,animated:c,animDuration:i=2,animDelay:d=0,padding:u=0,type:m,...h}=e,{className:C,style:x,rest:T}=E(h),S=react.useRef(null),P=hooks.useResizeObserver(S.current?.parentElement||S),g=typeof n=="number"?n:P.width,v=typeof o=="number"?o:P.height,y={width:g,height:v},b=react.useId(),{pathD:I,areaPathD:D}=hooks.useLineChart(t,y,u+(a||2)),N=react.useRef(null),A=react.useRef(null),[L,M]=react.useState(0),[$,K]=react.useState(0);return react.useEffect(()=>{c&&(N.current&&M(N.current.getTotalLength()),A.current&&K(A.current.getTotalLength()));},[c,I,D,g,v]),jsxRuntime.jsx(p,{ref:S,as:`--chart --${m||"line"}-chart ${C}`.trim(),style:{...x,width:n,height:o},...T,children:g>0&&v>0&&jsxRuntime.jsxs("svg",{viewBox:`0 0 ${g} ${v}`,preserveAspectRatio:"xMidYMid meet",children:[jsxRuntime.jsx("defs",{children:jsxRuntime.jsxs("linearGradient",{id:b,x1:"0%",y1:"0%",x2:"0%",y2:"100%",children:[jsxRuntime.jsx("stop",{offset:"0%",stopColor:l}),jsxRuntime.jsx("stop",{offset:"100%",stopColor:f})]})}),jsxRuntime.jsx("path",{ref:A,d:D,fill:`url(#${b})`,stroke:"none",style:c?{strokeDasharray:$,strokeDashoffset:$}:{},children:c&&jsxRuntime.jsx("animate",{attributeName:"stroke-dashoffset",from:$,to:"0",dur:`${i||2}s`,begin:`${d||0}s`,fill:"freeze"})}),jsxRuntime.jsx("path",{ref:N,d:I,fill:"none",stroke:s,strokeWidth:a,strokeLinecap:"round",strokeLinejoin:"round",style:c?{strokeDasharray:L,strokeDashoffset:L}:{},children:c&&jsxRuntime.jsx("animate",{attributeName:"stroke-dashoffset",from:L,to:"0",dur:`${i||2}s`,begin:`${d||0}s`,fill:"freeze"})})]})})});ts.displayName="Zuz.Chart";var tm=ts;var os=(o=>(o[o.Sending=0]="Sending",o[o.Sent=1]="Sent",o[o.Delivered=2]="Delivered",o[o.Read=3]="Read",o))(os||{}),rs=(c=>(c.Image="img",c.Video="vid",c.Audio="audio",c.Link="link",c.Document="doc",c.Location="loc",c.Contact="contact",c.Event="event",c.Poll="poll",c))(rs||{});var ns=react.forwardRef((e,r)=>{let{text:t,media:n,side:o="me",status:s=1,timeStamp:a=Date.now(),arrow:l=true,...f}=e,{className:c,style:i,rest:d}=E(f);return jsxRuntime.jsx(p,{className:`--bubble-wrapper flex --bw-${o}`.trim(),children:jsxRuntime.jsxs(p,{className:`--bubble --bubble-${o} ${n?`--with-media --bma-${n.type}`:""} rel flex cols ${l==true?"--b-arrow":""} ${c}`.trim(),style:{...i},...d,children:[t&&jsxRuntime.jsx(_,{className:"--bubble-text",children:t}),n?n.type=="audio"?jsxRuntime.jsxs(p,{as:"flex aic --bubble-audio",children:[jsxRuntime.jsx(ce,{className:"--bm-action",children:O.play}),jsxRuntime.jsx(Qe,{progress:.7}),jsxRuntime.jsx(_,{className:"--bm-dur",children:n.duration??"00:13"})]}):n.type=="img"?jsxRuntime.jsx(p,{as:"--bubble-image",children:jsxRuntime.jsx(tt,{src:n.source})}):null:null,jsxRuntime.jsxs(p,{as:"flex aie jce --bubble-stats",children:[jsxRuntime.jsx(_,{className:"--bubble-stamp tar",children:core.timeSince(a)}),o=="me"&&jsxRuntime.jsx(ce,{className:`--bubble-status --bs-${s}`,children:s==0?O.pending:s==1?O.done:s==2?O.doneAll:O.doneAll})]})]})})});ns.displayName="Zuz.Bubble";var nm=ns;var ss=react.forwardRef((e,r)=>{let{style:t,className:n,rest:o}=E(e);return jsxRuntime.jsx("label",{ref:r,style:t,className:n,...o})});ss.displayName="Zuz.Label";var Et=ss;var is=({ref:e,...r})=>{let {name:t,required:n,type:o,value:s,size:a,variant:l,checked:f,disabled:c,onSwitch:i,...d}=r,u=Fe(),m=!!(t&&u.values);m?u.errors?.[t]:null;let C=m?u.values?.[t]:void 0,[x,T]=react.useState(f||false),S=react.useRef(null),{variant:P}=j(true),g=react.useMemo(()=>m&&C!=null?typeof C=="string"?C.toLowerCase()!=="false"&&C!=="":!!C:x,[C,x,m]);react.useEffect(()=>{S.current&&S.current.checked!==g&&(S.current.checked=g);},[g]),react.useEffect(()=>{f!==void 0&&T(f);},[f]);let v=y=>{let b=!!y;m&&u.setFieldValue?.(t,b),T(b),i?.(b,s||"cb");};return react.useImperativeHandle(e,()=>({setChecked(y,b=true){v(y);},toggle(y=true){v(!g);}})),jsxRuntime.jsxs(Et,{"aria-hidden":c,className:[`--${(o||$e.Default).toLowerCase()}`,`${!o||o===$e.Default?"--checkbox":"--switch"}`,`--${l||P||U.Small}`,`flex aic jcc ${g?"is-checked":""} rel`,`${c?"--disabled":""}`].join(" ").trim(),...d,children:[(!o||o==$e.Default)&&O.check,jsxRuntime.jsx(fe,{ref:y=>{S.current=y,e&&(e.current=y);},defaultChecked:g,type:"checkbox",className:"abs",name:t,required:n||false,onChange:y=>{y.stopPropagation(),v(y.target.checked);},disabled:c})]})};is.displayName="Zuz.CheckBox";var Bt=is;var gm=({ref:e,...r})=>{let{code:t,copy:n,lang:o="tsx",showLines:s=false,highlight:a="",as:l,fx:f,...c}=r,i=react.useRef(null),{className:d,style:u,rest:m}=E({as:`rel p:20 br:8 bg:shade-1 overflow:auto font:mono ${l}`,fx:f},i),h=react.useMemo(()=>{let x=new Set;return a.split(",").forEach(T=>{if(T.includes("-")){let[S,P]=T.split("-").map(Number);for(let g=S;g<=P;g++)x.add(g);}else T&&x.add(Number(T));}),x},[a]),C=react.useMemo(()=>{let x=t.split(`
10
+ `);for(;x.length>0&&x[0].trim()==="";)x.shift();for(;x.length>0&&x[x.length-1].trim()==="";)x.pop();let T=x[0]?.match(/^\s*/)?.[0].length||0,S=x.map(g=>{let v=g.match(/^\s*/)?.[0].length||0,y=Math.min(v,T);return g.slice(y)}),P=[{name:"comm",re:/\/\/.*/g},{name:"str",re:/(["'`])(?:(?=(\\?))\2.)*?\1/g},{name:"key",re:/\b(const|let|var|export|default|import|from|return|if|else|switch|case|break|as|type|interface|class|extends|await|async|new|void|typeof)\b/g},{name:"tag",re:/(&lt;\/?[A-Z][\w\.]*|&gt;)/g},{name:"var",re:/(?<!&lt;\/|&lt;)\b[A-Z]\w*\b/g},{name:"fn",re:/\b([a-z_]\w*)(?=\s*\()/gi},{name:"prop",re:/\.([a-z_]\w*)\b/gi},{name:"num",re:/\b\d+\b(?![#|A-Z|a-z|_|ZUZ])/g}];return S.map((g,v)=>{let y=g.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;"),b=h.has(v+1);if(o!="plain"){let I=[];P.forEach(D=>{y=y.replace(D.re,N=>{let A=`ZUZ_ID_${I.length}_ZUZ`;return I.push(`<span class="--token-${D.name}">${N}</span>`),A});});for(let D=I.length-1;D>=0;D--)y=y.replace(`ZUZ_ID_${D}_ZUZ`,I[D]);}return `<div class="--code-line ${s==true?"--with-ln":""} ${b?"--is-highlighted":""}">
11
11
  ${s==true?`<span class="--line-number">${v+1}</span>`:""}
12
- <span class="--line-content">${h||" "}</span>
13
- </div>`}).join("")},[t,y]);return jsxRuntime.jsxs(m,{as:`--code-block rel ${d}`,style:p,...c,children:[jsxRuntime.jsx("pre",{ref:e,children:jsxRuntime.jsx("code",{className:`--code --lang-${o}`,dangerouslySetInnerHTML:{__html:C}})}),n&&jsxRuntime.jsx(Z,{as:"--copy-code abs",onClick:()=>{core.copyToClipboard(t),n.onCopy?.();},children:"Copy"})]})},tm=em;var ts=({onSelect:e,meta:r,selected:t,disabled:n=false})=>{let o=react.useRef(null),{index:s,icon:a,label:i}=r,[f,c]=react.useState({x:0,width:0}),l=hooks.useDelayed();return react.useLayoutEffect(()=>{if(l&&o.current){let{width:d,x:p}=o.current.getBoundingClientRect();c({x:p,width:d}),t&&e(s,d,p,r,true);}},[l,o.current]),react.useEffect(()=>{t&&e(s,f.width,f.x,r,false);},[t]),jsxRuntime.jsxs(Z,{disabled:n,onClick:()=>e(s,f.width,f.x,r,false),ref:o,className:`--segment-item flex aic rel ${t?"--segment-active":""}`.trim(),children:[a?typeof a=="string"?jsxRuntime.jsx(oe,{name:a,as:"--segment-icon"}):jsxRuntime.jsx(m,{as:"--segment-icon flex aic jcc",children:a}):null,i&&String(i).trim()!=""&&jsxRuntime.jsx(m,{className:"--segment-label",children:i||`Item ${s}`})]})};ts.displayName="SelectTabItem";var os=ts;var ns=react.forwardRef((e,r)=>{let{fx:t,items:n,selected:o,variant:s,disabled:a=false,onSwitch:i,...f}=e,[c,l]=react.useState(o||0),d=hooks.useDelayed(50),p=react.useRef(c),{className:u,style:y,rest:C}=N(f),x=react.useRef(null),T=react.useRef(null),{variant:S}=Q(true),P=(g,v,h,b,I)=>{if((I||c!=g&&c!=-2)&&(l(g),p.current=c,queueMicrotask(()=>{d&&i?.(b);})),x.current){let z=T.current?.getBoundingClientRect();x.current.style.setProperty("--w",`${v}px`),x.current.style.setProperty("--x",`${z?h-z.left:h}px`);}};return react.useImperativeHandle(r,()=>({setSelected:g=>{typeof g=="number"&&g!=c&&l(g);}}),[c]),jsxRuntime.jsxs(m,{ref:T,"data-selected":c,className:`${u} --segmented --${s||S||W.Medium} flex aic rel`,style:y,...C,children:[jsxRuntime.jsx(m,{ref:x,className:`--segment-tab --${a?"disabled":"abled"} abs`}),n.map((g,v)=>jsxRuntime.jsx(os,{disabled:a,onSelect:P,selected:c==v,meta:{...g,index:v}},`segment-${g.label}-${v}`))]})});ns.displayName="Zuz.SelectTabs";var Tt=ns;var is=react.forwardRef((e,r)=>{let{type:t,variant:n,...o}=e,s=hooks.useDelayed(),{colorScheme:a,setColorScheme:i}=yo(),f=react.useCallback(()=>{i(a=="dark"?"light":a=="light"?"system":"dark");},[a]),{variant:c}=Q(true),{className:l,style:d}=N(o),p=react.useMemo(()=>t=="system"?[{tag:"light",index:0,label:"",icon:O.colorSchemeLight},{tag:"system",index:1,label:"",icon:O.colorSchemeSystem},{tag:"dark",index:2,label:"",icon:O.colorSchemeDark}]:[{tag:"light",index:0,label:"",icon:O.colorSchemeLight},{tag:"dark",index:2,label:"",icon:O.colorSchemeDark}],[]),u=react.useMemo(()=>["light","system","dark"].indexOf(a),[a]);return !s||u==-1?null:t=="system"||t=="switch"?jsxRuntime.jsx(Tt,{className:`--color-scheme --${t}`,onSwitch:({tag:y})=>{i(y);},selected:u,items:p,...o}):jsxRuntime.jsx(Z,{onClick:f,style:d,variant:n,as:`--color-scheme-switch ${l}`.trim(),children:a=="system"?O.colorSchemeSystem:a=="light"?O.colorSchemeLight:O.colorSchemeDark})});is.displayName="Zuz.ColorScheme";var ym=is;var cs=react.forwardRef((e,r)=>{let[t,n]=react.useState("wait"),{title:o,message:s,acceptLabel:a,rejectLabel:i,position:f}=e,c=async l=>{n(l==1?"accepted":"rejected"),localStorage.setItem("--ccnt",String(l));};return react.useEffect(()=>{let l=localStorage.getItem("--ccnt");n(l?l=="1"?"accepted":"rejected":"pending");},[]),jsxRuntime.jsxs(m,{fx:{from:{x:-1e3},to:{x:0},when:t=="pending",curve:te.EaseInOut,duration:.5,delay:t=="accepted"?0:3},as:`--cookie-consent --${t} --${f||de.Left} flex cols`,children:[jsxRuntime.jsx(_,{as:"--title",children:o||"This site uses cookies"}),jsxRuntime.jsx(_,{as:"--message",children:s||"We and selected third parties use cookies (or similar technologies) for technical purposes, to enhance and analyze site usage, to support our marketing efforts"}),jsxRuntime.jsxs(m,{as:"--footer flex aic",children:[jsxRuntime.jsx(Z,{onClick:l=>c(1),as:"--accept",children:a||"Accept All"}),jsxRuntime.jsx(Z,{onClick:l=>c(0),as:"--reject",children:i||"Cancel"})]})]})});cs.displayName="Zuz.CookiesConsent";var Sm=cs;var us=({ref:e,...r})=>{let {title:t,position:n,margin:o=4,anchorName:s="--tooltip-anchor",children:a,show:i,variant:f,...c}=r,{style:l,className:d,rest:p}=N(c),u=n||de.Top;react.useRef(null);let [C,x]=react.useState(false);react.useRef(6);let S=i===true||C,g=`--anchor-${react.useId().replace(/:/g,"")}`,{tooltip:v}=Q(true),h=react.useMemo(()=>{let I=false;return react$1.addPropsToChildren(a,z=>{let E=z.props.className?.includes(s);return E&&(I=true),E||!I},(z,E)=>{let H=E.props.className?.includes(s),k=z===0,M={};return (H||k)&&(M.style={...E.props.style,anchorName:g}),k&&(M.onMouseEnter=L=>{x(true),E.props.onMouseEnter?.(L);},M.onMouseLeave=L=>{x(false),E.props.onMouseLeave?.(L);}),M})},[a,s,g]),b=ge({transition:u==de.Top?j.SlideInTop:u==de.Bottom?j.SlideInBottom:u==de.Left?j.SlideInLeft:j.SlideInRight,when:S,duration:.2,offset:o+6,margin:u==de.Top||u==de.Left?-o:o,curve:v?.curve||te.EaseInOut});return react.useImperativeHandle(e,()=>({show:()=>x(true),hide:()=>x(false),setPosition:()=>{}})),jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[h,jsxRuntime.jsx(m,{style:{positionAnchor:g,...b.style,...u===de.Top||u===de.Bottom?{"--fx-x":"-50%"}:{"--fx-y":"-50%"}},as:`--tooltip --visb-${S} --${f||v?.variant||W.Small} --${u} abs ${d}`.trim(),children:typeof t=="string"?jsxRuntime.jsx(_,{as:"--text rel",children:t}):t})]})};us.displayName="Zuz.ToolTip";var jo=us;var fs=({ref:e,...r})=>{let {type:t,value:n=0,min:o=0,max:s=1,step:a=.01,onChange:i,showGhostBar:f,showKnobOnHover:c,showToolTip:l,roundValue:d,formatValue:p,...u}=r,{className:y,style:C,rest:x}=N(u),T=react.useRef(a||.01).current,S=react.useRef(o||0).current,P=react.useRef(s||1).current,g=react.useRef(n||0).current,v=react.useRef(null),h=react.useRef(null),b=react.useRef(null),I=react.useRef(null);react.useRef(null);let E=react.useRef(null),H=react.useRef(null),k=react.useRef(null),M=react.useRef(null),L=(re,ne,ue)=>(re-ne)/(ue-ne)*100,F=re=>{if(h.current){let ne=parseFloat(re.currentTarget.value);J(ne);let ue=L(ne,parseFloat(re.currentTarget.min),parseFloat(re.currentTarget.max));h.current.style.setProperty("--value",`${ue}`),h.current.setAttribute("data-value",`${ne}`),i&&i(d?+ne.toFixed(2):ne);}},[R,B]=react.useState(false),[G,U]=react.useState(0),[D,A]=react.useState(0),[q,K]=react.useState(false),J=async re=>{let ne=p?p(+re):d?(+re).toFixed(2):Math.round(+re);k.current&&(k.current.textContent=String(ne));},ie=re=>{if(R){let ne=re.clientX-G,ue=P-S,$=ne/200*ue,X=Math.max(S,Math.min(D+$,P));if(X=Math.round(X/T)*T,J(X),h.current){let ce=L(X,S,P);h.current.style.setProperty("--value",`${ce}`),h.current.setAttribute("data-value",`${X}`),H.current&&(H.current.textContent=d?X.toFixed(2):X.toString()),i&&i(X);}}},me=()=>{B(false),document.body.style.cursor="auto";},ye=re=>(re-S)/(P-S)*100,se=re=>{if(!h.current)return;let ne=h.current.getBoundingClientRect(),ue=re.clientX-ne.left,Be=Math.max(0,Math.min(100,ue/ne.width*100));if(l&&k.current){let $=v.current?+v.current.value:n;J($*100);}if(f){let $=ye(v.current?+v.current.value:n),X=Math.min($,Be),ce=Math.abs(Be-$);h.current.style.setProperty("--ghost-start",`${X}`),h.current.style.setProperty("--ghost-width",`${ce}`);}};react.useEffect(()=>{h.current&&h.current.style.setProperty("--value",v.current?`${L(parseFloat(v.current.value),parseFloat(v.current.min),parseFloat(v.current.max))}`:g.toString());},[]),react.useEffect(()=>(R?(document.addEventListener("mousemove",ie),document.addEventListener("mouseup",me)):(document.removeEventListener("mousemove",ie),document.removeEventListener("mouseup",me)),()=>{document.removeEventListener("mousemove",ie),document.removeEventListener("mouseup",me);}),[R]),react.useEffect(()=>{let re=L(n,S,P);h.current?.style.setProperty("--value",`${re}`),J(n);},[n,S,P,k.current]);let Y=()=>jsxRuntime.jsxs(m,{ref:h,onMouseEnter:()=>K(true),onMouseLeave:()=>K(false),onMouseMove:se,className:`--slider --${t||co.Default} ${c?"--knob-hover":""} flex rel ${y}`.trim(),style:{...C},children:[jsxRuntime.jsx(m,{ref:E,className:"--slider-track abs fill"}),f&&jsxRuntime.jsx(m,{ref:I,className:"--slider-ghost abs fill"}),jsxRuntime.jsx(m,{className:"--slider-track-filled abs fill",style:{width:"calc(var(--value) * 1%)"}}),jsxRuntime.jsx(m,{ref:b,className:"--slider-knob --tooltip-knob abs"}),jsxRuntime.jsx(pe,{ref:v,onInput:F,className:"abs fill",tabIndex:0,type:t||co.Default,defaultValue:g||0,step:T,max:P,min:S})]});if(l===true){let re=p?p(n):d?n.toFixed(2):n;return jsxRuntime.jsx(jo,{ref:M,show:R,position:pt.Top,margin:15,anchorName:"--tooltip-knob",title:jsxRuntime.jsx(ae,{ref:k,children:re}),children:Y()})}return Y()};fs.displayName="Zuz.Slider";var ot=fs;var gs=react.forwardRef((e,r)=>{let{src:t,shape:n,size:o,...s}=e,{style:a,className:i,rest:f}=N(s),{canvasRef:c,crop:l,setScale:d,handleMouseDown:p,handleMouseUp:u,handleMouseMove:y}=hooks.useImageCropper(t,o||200,n||hooks.CropShape.Circle);return react.useImperativeHandle(r,()=>({getCropped(){return l()},setScale(C){d(C);}})),jsxRuntime.jsxs(m,{as:`--cropper --${n||hooks.CropShape.Circle} ${i}`,style:a,...f,children:[jsxRuntime.jsx("canvas",{ref:c,width:o||200,height:o||200,onMouseDown:p,onMouseUp:u,onMouseLeave:u,onMouseMove:y}),jsxRuntime.jsx(m,{as:"--cropper-slider",children:jsxRuntime.jsx(ot,{onChange:C=>d(C),min:0,max:1,step:.01,value:1})})]})});gs.displayName="Zuz.Cropper";var Mm=gs;var Vm=(t=>(t.Circle="circle",t.Square="square",t))(Vm||{});var ys=react.forwardRef((e,r)=>{let{items:t,maxItems:n}=e,o=react.useMemo(()=>{let i=typeof t=="string",f=i?[]:t;return i&&t.split(",").forEach(c=>{f.push({label:c});}),f},[t]),a=react.useMemo(()=>n&&n>0&&o.length>n-1,[o,n])?[...o.slice(0,2),{ID:".",label:"...",icon:"ellipsis",action:()=>{}},...o.slice(-n)]:o;return jsxRuntime.jsx(Xe,{ref:r,className:"--crumb flex aic",direction:"rows",seperator:jsxRuntime.jsx(m,{as:"--crumb-chevron",children:O.chevronRightOutline}),items:a.map((i,f,c)=>i.ID=="."?jsxRuntime.jsx(m,{as:"flex aic gap:3",children:Array(3).fill(null).map(()=>jsxRuntime.jsx(m,{as:"w:4 h:4 bg:$text r:10"},`--crumb-placeholder-${f}`))}):jsxRuntime.jsxs(Z,{onClick:()=>i.action?.(),className:"--crumb-item",disabled:!c[f+1],children:[i.icon&&jsxRuntime.jsx(oe,{as:"--crumb-icon",name:i.icon}),jsxRuntime.jsx(_,{as:"--crumb-label",children:i.label})]},`${i.label.replace(/\s+/g,"-").toLowerCase()}-${f}`))})});ys.displayName="Zuz.Crumb";var Hm=ys;var vs=react.forwardRef((e,r)=>{let{icon:t,defaultValue:n,value:o,size:s,variant:a,numeric:i,type:f,onConfirm:c,...l}=e,[d,p]=react.useState(false),[u,y]=react.useState(n||null),{style:C,className:x,rest:T}=N(l),S=react.useRef(null),P=react.useRef(null),{reposition:g}=xt(P,{direction:de.Bottom,offset:2}),v=b=>{i&&(b.currentTarget.value=b.currentTarget.value.replace(/[^0-9.]/g,"").replace(/(\..*?)\..*/g,"$1"));};react.useEffect(()=>{let b=I=>{let z=I.target,E=S.current?.contains(z),H=P.current?.contains(z);!E&&!H&&p(false);};return d&&document.addEventListener("mousedown",b),()=>{document.removeEventListener("mousedown",b);}},[d]),react.useEffect(()=>{let b=I=>{I.key==="Escape"&&d&&(p(false),S.current?.focus());};return document.addEventListener("keydown",b),()=>document.removeEventListener("keydown",b)},[d]);let h=()=>{p(true);};return react.useEffect(()=>{d&&g();},[d,g]),jsxRuntime.jsx(jsxRuntime.Fragment,{children:jsxRuntime.jsxs(m,{as:`--date-picker ${a?`--${a}`:""} rel flex aic ${x}`,"data-value":u?u.toISOString():"",children:[t?typeof t=="string"?jsxRuntime.jsx(oe,{as:"mr:10 c:#666",name:t}):t:jsxRuntime.jsx(ae,{as:"--date-picker-icon flex aic jcc",children:O.calendar}),jsxRuntime.jsx("input",{ref:S,value:u?dateFns.format(u,"EEE, MMM d YYY hh:mm a"):o||"",className:`--input ${a?`--${a}`:""} flex`.trim(),style:C,onFocus:h,onInput:v,autoComplete:"new-password",onKeyDown:b=>{b.key=="Enter"&&c?.(b.currentTarget.value);},...T}),jsxRuntime.jsx(m,{"aria-hidden":!d,ref:P,fx:{from:{y:5,opacity:0},to:{y:0,opacity:1},when:d,duration:.05},as:`--date-picker-chooser flex aic ${a?`--${a}`:""}`,children:jsxRuntime.jsx(Zo,{defaultValue:u,onChange:b=>{y(b),p(false);}})})]})})});vs.displayName="Zuz.DatePicker";var Fm=vs;var Ss=react.forwardRef((e,r)=>{let{icon:t,variant:n,position:o}=e;return jsxRuntime.jsx(Z,{className:`--fab fixed --${n||W.Large} --${o||"bottomright"}`,children:t||O.plus})});Ss.displayName="Zuz.Fab";var Wm=Ss;var ws=e=>{let{names:r,strength:t}=e,n={[kt.Gooey]:o=>jsxRuntime.jsxs("filter",{id:"gooey",children:[jsxRuntime.jsx("feGaussianBlur",{in:"SourceGraphic",stdDeviation:o||10,result:"blur"}),jsxRuntime.jsx("feColorMatrix",{in:"blur",mode:"matrix",values:"1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 18 -7",result:"goo"}),jsxRuntime.jsx("feBlend",{in:"SourceGraphic",in2:"goo"})]},`filter-${kt.Gooey}`)};return react.useEffect(()=>{},[r]),jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",version:"1.1",children:jsxRuntime.jsx("defs",{children:(r||[kt.Gooey]).map(o=>n[o](t))})})};ws.displayName="Zuz.Filters";var qm=ws;var Cs=({cols:e,gap:r,ais:t,aic:n,aie:o,jcs:s,jcc:a,jce:i,className:f="",style:c,...l})=>{let d=["--flex",e?"--cols":"",t?"--ais":"",n?"--aic":"",o?"--aie":"",s?"--jcs":"",a?"--jcc":"",i?"--jce":"",f].filter(Boolean).join(" "),p={...c,gap:typeof r=="number"?`${r}px`:r};return jsxRuntime.jsx(m,{...l,className:d,style:p})};Cs.displayName="Zuz.FlexBox";var ze=Cs;var Fe=null,Te=null,Ps=react.forwardRef((e,r)=>{let{title:t,message:n,transition:o,curve:s,speed:a,type:i,actionPosition:f,spinner:c,loadingMessage:l,onShow:d,onHide:p,...u}=e,{className:y,style:C,rest:x}=N(u),[T,S]=react.useState(t||""),[P,g]=react.useState(n||""),[v,h]=react.useState(null),[b,I]=react.useState(i||Re.Default),z=react.useMemo(()=>core.uuid(12),[]),[E,H]=react.useState(false),k=react.useRef(null),M=react.useRef(null),[L,F]=react.useState(false),[R,B]=react.useState(true),G=react.useRef(null),U=P;react.useImperativeHandle(r,()=>({setLoading(A){F(A);},showDialog(A,q,K,J){Fe&&(clearTimeout(Fe),Te&&clearTimeout(Te),k.current.classList.remove("--wobble"),setTimeout(()=>k.current.classList.add("--wobble"),50),Te=setTimeout(()=>{k.current.classList.remove("--wobble"),Te=null;},500)),I(Re.Dialog),q&&g(q),A&&S(A),K&&h(K.reduce((ee,ie)=>(ee.push({...ie,key:ie.key||core.uuid(12)}),ee),[])),H(true),setTimeout(()=>J?J():()=>{},1e3);},dialog(A,q,K,J){Fe&&(clearTimeout(Fe),Te&&clearTimeout(Te),k.current.classList.remove("--wobble"),setTimeout(()=>k.current.classList.add("--wobble"),50),Te=setTimeout(()=>{k.current.classList.remove("--wobble"),Te=null;},500)),I(Re.Dialog),g(q),S(A),K&&h(K.reduce((ee,ie)=>(ee.push({...ie,key:ie.key||core.uuid(12)}),ee),[])),H(true),setTimeout(()=>J?J():()=>{},1e3);},error(A,q){this.show(A,q,Re.Error);},warn(A,q){this.show(A,q,Re.Warn);},success(A,q){this.show(A,q,Re.Success);},show(A,q,K){Fe&&(clearTimeout(Fe),Te&&clearTimeout(Te),M.current=k.current.style.transform,k.current.style.transform="",k.current.classList.remove("--wobble"),setTimeout(()=>{k.current.classList.add("--wobble"),k.current.style.transform=`${M.current} scale(.9)`.trim();},50),Te=setTimeout(()=>{k.current.classList.remove("--wobble"),k.current.style.transform=M.current||"",Te=null;},500)),Fe=setTimeout(()=>{H(false),Fe=null,Te=null;},(q||4)*1e3),I(K||Re.Default),g(A),H(true),d?.();},hide(){H(false),p?.();}}));let D=react.useMemo(()=>{let A={when:E,duration:a||.3,delay:.1};if(b==Re.Dialog){if(o){let{from:q,to:K}=ft(o,20);return {from:q,to:K,curve:s||te.EaseInOut,...A}}return {from:{scale:0,x:"-50%",y:"-50%",opacity:0},to:{scale:1,x:"-50%",y:"-50%",opacity:1},curve:te.Spring,...A}}else return {from:{scale:0,x:"-50%",y:"-10vh",opacity:0},to:{scale:1,x:"-50%",y:0,opacity:1},curve:te.Spring,...A}},[E,b]);return react.useEffect(()=>{G.current&&clearTimeout(G.current),E?B(true):G.current=setTimeout(()=>B(false),1e3);},[E]),b==Re.Dialog?jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(We,{when:E}),jsxRuntime.jsxs(m,{className:`--sheet --sheet-${b.toLowerCase()} ${E?"is-visible":""} ${y} fixed`.trim(),style:C,fx:D,...x,ref:k,children:[jsxRuntime.jsx(Ee,{when:L,spinner:c,message:l}),jsxRuntime.jsxs(m,{className:"--head flex aic rel",children:[jsxRuntime.jsx(m,{className:`--${T?"title":"dot"} flex aic rel`,children:T||""}),jsxRuntime.jsx(Z,{onClick:A=>H(false),className:"--closer abs",children:"\xD7"})]}),jsxRuntime.jsx(m,{className:`--body flex aic rel ${v?"":"--no-action"}`.trim(),children:R?U:null}),v&&jsxRuntime.jsx(m,{className:`--footer flex aic rel ${f?f==lo.Center?"jcc":"":"jce"}`.trim(),children:v.map((A,q)=>jsxRuntime.jsx(Z,{onClick:K=>A.handler?A.handler():A.onClick?A.onClick():console.log("onClick Handler missing"),className:"--action",children:A.label},`sheet-${z}-action-${A.key}`))})]})]}):jsxRuntime.jsx(m,{className:`--sheet --sheet-${b.toLowerCase()} ${y} abs`.trim(),style:C,...x,fx:D,ref:k,children:E?P:null})}),Rs=e=>typeof e=="object"&&e!=null&&"setLoading"in e&&"success"in e&&"error"in e;Ps.displayName="Zuz.Sheet";var ep=Ps;var lp=e=>{let r={};for(let t in e){let n=t.split(/[\[\]]+/).filter(Boolean);n.reduce((o,s,a)=>{if(a===n.length-1)o[s]=e[t];else {let i=!isNaN(Number(n[a+1]));o[s]=o[s]||(i?[]:{});}return o[s]},r);}return r},Is=({ref:e,...r})=>{let {schema:t,name:n,cover:o,spinner:s,errors:a,action:i,children:f,withData:c,beforeSubmit:l,onSubmit:d,onError:p,onSuccess:u,resetOnSuccess:y,...C}=r,{className:x,style:T,rest:S}=N(C),[P,g]=react.useState(false),v=react.useRef(null),h=Lo(),b=$o();Ao();let z=react.useRef(null),E=react.useCallback(D=>v.current?v.current.querySelectorAll(D):[],[v.current]),H=D=>({name:D.name||D.getAttribute("name")||D.getAttribute("data-name"),required:D.required?true:D.getAttribute("data-required")?D.getAttribute("data-required")=="true":false,with:D.with||D.getAttribute("with")}),k=D=>{let A=[];return D.querySelectorAll(".--input").forEach(q=>{A.push(q.value);}),A.join("")},M=D=>D.classList.contains("--otp")?k(D):D.classList.contains("--select")?D.querySelector("button.--selected")?.dataset.value:D.classList.contains("--checkbox")||D.getAttribute("type")==="checkbox"?D.checked:D.value,L=react.useCallback(D=>{let{name:A,required:q,with:K}=H(D),J=M(D);if(t&&t[A]&&b?.getSnapshot()){let ee=t[A](J,b.getSnapshot().values);if(ee===false||typeof ee=="string")return typeof ee=="string"&&b?.setFieldError(A,ee),false}if(q&&(D.type==="checkbox"&&!D.checked||D.classList.contains("--select")&&(J==="-1"||!J)||!J||J===""))return false;if(K)switch((K.includes("@")?K.split("@")[0]=="match"?Ke.MatchField:K.split("@")[0]:K).toUpperCase()){case Ke.IPV4:return core._(J).isIPv4();case Ke.IPV6:return core._(J).isIPv6();case Ke.Email:return core._(J).isEmail();case Ke.Uri:try{return new URL(J),!0}catch{return false}case Ke.MatchField:let[ie,me,ye]=K.split("@"),se=document.querySelector(`[name=${me.trim()}]`);if(!se)return false;switch(ye||"direct-match"){case "if-not-empty":if(se&&!core._(se.value).isEmpty()&&se.value!=D.value)return false;break;case "direct-match":if(se&&se.classList.contains("--otp")&&D.classList.contains("--otp")&&k(se)!=k(D))return false;if(se&&se.value!=D.value)return false;break}break}return true},[t,b]),F=react.useCallback(()=>{let D={},A={...b?.getSnapshot().values||{}},q=null,K=null;if(E("[name]").forEach(ee=>{let{name:ie,required:me,with:ye}=H(ee),se=me||ye?L(ee):true,le=M(ee);D[ie]={valid:se,value:le},A[ie]=le,b?.setFieldError(ie,se?null:a?.[ie]||"Invalid"),se?ee.classList.remove("--with-error"):(ee.classList.add("--with-error"),q||(q=ee),K=a?.[ie]);}),q){let ee=q;if(ee.classList.contains("--otp"))for(let ie of Array.from(ee.querySelectorAll(".--input"))){let me=ie;if(me.value==""){me.focus();break}}else ee.focus();}let J=lp(A);return {error:q!=null,errorMsg:K||"Fix errors to continue...",data:D,payload:J}},[v.current,b]),R=react.useCallback((D={})=>{let{error:A,errorMsg:q,payload:K,data:J}=F();if(A){h.error(q);return}i?react.startTransition(async()=>{g(true),core.withPost(i,{...c,...K,...D}).then(ee=>{g(false),y&&b?.reset(),u?.(ee,{...c,...K,...D}),u||h.success(ee.message||"Redirecting...");}).catch(ee=>{g(false),p?p(ee):h.error(ee.message);});}):d?.(K,J);},[F,i,c,u,p,y,d]),B=react.useCallback(()=>{let D=E("[type=submit]");!D||D.length==0?console.warn("You should add at least 1 button with type=`SUBMIT`"):D.forEach(A=>{A.addEventListener("click",R);});},[v.current]),G=react.useMemo(()=>react$1.addPropsToChildren(f,D=>D.props.type=="submit",D=>({ref:z})),[f]),U=react.useRef(R);return react.useImperativeHandle(e,()=>({setLoading:D=>g(D),submit:D=>U.current(D),init:B,hideError:()=>h.clearAll()}),[R,B]),react.useEffect(B,[]),react.useEffect(()=>{U.current=R;},[R]),react.useEffect(()=>{let D=E("[type=submit]"),A=Array.from(D).map(q=>{let K=q;return K.addEventListener("click",R),()=>K.removeEventListener("click",R)});return ()=>A.forEach(q=>q())},[R,E]),jsxRuntime.jsxs(m,{ref:v,style:T,className:`--form flex rel ${x}`,children:[!Rs(o)&&jsxRuntime.jsx(Ee,{when:P,spinner:s,...o}),G]})};Is.displayName="Zuz.FormInternal";var Ns=e=>jsxRuntime.jsx(Rn,{initialValues:e.withData,children:jsxRuntime.jsx(Is,{...e})});Ns.displayName="Zuz.Form";var cp=Ns;var Bs=e=>{let {ref:r,cols:t,rows:n,gap:o,gapX:s,gapY:a,align:i,justify:f,inline:c,flow:l,autoCols:d,autoRows:p,template:u,...y}=e;react.useRef(null);let {className:x,style:T,rest:S}=N(y),P=v=>typeof v=="number"?`repeat(${v}, 1fr)`:v,g={display:c?"inline-grid":"grid",gridTemplateColumns:P(t),gridTemplateRows:P(n),gap:o,columnGap:s,rowGap:a,alignItems:i,justifyContent:f==="between"?"space-between":f==="around"?"space-around":f,gridAutoFlow:l,gridAutoColumns:d,gridAutoRows:p,gridTemplateAreas:u,...T};return jsxRuntime.jsx(m,{ref:r,as:`--grid ${x}`.trim(),style:g,...S})};Bs.displayName="Zuz.Grid";var up=Bs;var Es=e=>typeof e=="string"&&e.includes("+"),ks={command:"\u2318",shift:"\u21E7",ctrl:"\u2303",option:"\u2325",enter:"\u21B5",delete:"\u232B",escape:"\u238B",tab:"\u21E5",capslock:"\u21EA",up:"\u2191",right:"\u2192",down:"\u2193",left:"\u2190",pageup:"\u21DE",pagedown:"\u21DF",home:"\u2196",end:"\u2198",help:"?",space:"\u2423",fn:"Fn",win:"\u2318",alt:"\u2325"},Ls={command:"Command",shift:"Shift",ctrl:"Control",option:"Option",enter:"Enter",delete:"Delete",escape:"Escape",tab:"Tab",capslock:"Caps Lock",up:"Up",right:"Right",down:"Down",left:"Left",pageup:"Page Up",pagedown:"Page Down",home:"Home",end:"End",help:"Help",space:"Space",fn:"Fn",win:"Win",alt:"Alt"};var Os=react.forwardRef(({children:e,keys:r,as:t,className:n,variant:o},s)=>{let{variant:a}=Q(true),i=react.useMemo(()=>{if(Es(r)){let f=null;return {keys:String(r).split("+").reduce((l,d,p,u)=>(u[p+1]?l.push(d):f=d.toUpperCase(),l),[]),children:f}}return {keys:r,children:String(e).toUpperCase()}},[r]);return jsxRuntime.jsxs(m,{as:`--keyboard-keys --${o||a||W.Small} flex aic ${t} ${n}`.trim(),children:[(Array.isArray(i.keys)?i.keys:[i.keys]).map(f=>jsxRuntime.jsx("abbr",{title:Ls[f],children:ks[f]},f)),jsxRuntime.jsx(ae,{children:i?.children??e})]})});Os.displayName="Zuz.KeyboardKeys";var ir=Os;var Hs=react.createContext(null),st=()=>{let e=react.useContext(Hs);if(!e)throw new Error("MediaPlayer sub-components must be used within <MediaPlayer />");return e},vp=({ref:e,icons:r,children:t,...n})=>{let{playlist:o=[],mode:s="audio",defaultArtist:a="Artist",defaultTitle:i="No Track",defaultCover:f,onTrackChange:c,...l}=n,{className:d,style:p,rest:u}=N(l),y=hooks.useMediaPlayer(o,o[0]??void 0),C=react.useMemo(()=>({play:O.play,pause:O.pause,prev:O.prev,next:O.next,volumeHigh:O.volumeHigh,volumeMute:O.volumeMute,...r}),[r]),x=react.useMemo(()=>({...y,mode:s,icons:C}),[y,C]);return jsxRuntime.jsx(Hs.Provider,{value:x,children:jsxRuntime.jsx(m,{className:`--zuz-media-player ${d}`,style:p,children:t})})},As=vp;var $s=e=>{if(!e||isNaN(e))return "0:00";let r=Math.floor(e/60),t=Math.floor(e%60);return `${r}:${t.toString().padStart(2,"0")}`},Qt=e=>typeof e=="string"?jsxRuntime.jsx(oe,{name:e}):e,zs=()=>{let{mediaRef:e,state:r,controls:t,mode:n}=st();return jsxRuntime.jsxs(m,{as:`--mediaplayer-stage rel --mode-${n}`,children:[n==="video"?jsxRuntime.jsx("video",{ref:e,className:"fill",onClick:t.togglePlay}):jsxRuntime.jsx("audio",{ref:e}),r.isLoading&&jsxRuntime.jsx(m,{as:"abs fill aic jcc --mediaplayer-spinner",children:jsxRuntime.jsx(Se,{})})]})},Fs=()=>{let{state:e,defaultArtist:r,defaultTitle:t,defaultCover:n}=st();return jsxRuntime.jsxs(m,{as:"--track-info flex aic",children:[jsxRuntime.jsx(Ye,{src:e.currentItem?.cover||n||"",as:"--track-cover"}),jsxRuntime.jsxs(m,{as:"flex cols",children:[jsxRuntime.jsx(m,{as:"--track-title",children:e.currentItem?.title||t||"Choose Track"}),jsxRuntime.jsx(m,{as:"--track-artist",children:e.currentItem?.artist||r||"..."})]})]})},_s=()=>{let{state:e,controls:r,icons:t}=st();return jsxRuntime.jsxs(m,{as:"--mediaplayer-controls flex aic",children:[jsxRuntime.jsx(Z,{onClick:r.prev,as:"--prev",children:Qt(t?.prev??O.prev)}),jsxRuntime.jsx(Z,{onClick:r.togglePlay,as:"--play-pause",children:Qt(e.isPlaying?t?.pause??O.pause:t?.play??O.play)}),jsxRuntime.jsx(Z,{onClick:r.next,as:"--next",children:Qt(t?.next??O.next)})]})},Zs=()=>{let{state:e,controls:r,mediaRef:t}=st(),n=e.progress*(e.duration||0);return jsxRuntime.jsxs(m,{as:"--track-progress flex aic",children:[jsxRuntime.jsx(m,{as:"--track-current-duration",children:$s(n)}),jsxRuntime.jsx(ot,{value:e.progress,onClick:o=>{let s=o.currentTarget.getBoundingClientRect(),a=(o.clientX-s.left)/s.width;r.seek(a);}}),jsxRuntime.jsx(m,{as:"--track-total-duration",children:$s(e.duration)})]})},Ks=()=>{let{state:e,controls:r,icons:t}=st();return jsxRuntime.jsxs(m,{as:"--volume-control flex aic gap:8 w:120",children:[jsxRuntime.jsx(Z,{onClick:()=>r.setIsMuted(),children:Qt(e.isMuted?t?.volumeMute??O.volumeMute:t?.volumeHigh??O.volumeHigh)}),jsxRuntime.jsx(ot,{value:e.volume,className:"h:3 flex:1",onClick:n=>{let o=n.currentTarget.getBoundingClientRect();r.setVolume((n.clientX-o.left)/o.width);}})]})};var Sp=({ref:e,...r})=>jsxRuntime.jsx(As,{...r,ref:e}),wp=Object.assign(Sp,{Stage:zs,TrackInfo:Fs,Controls:_s,Progress:Zs,Volume:Ks}),Cp=wp;var Gs=react.forwardRef((e,r)=>{let t=hooks.useNetworkStatus(),{onlineMessage:n,offlineMessage:o,variant:s}=e;return jsxRuntime.jsxs(m,{fx:{from:{x:"-50%",y:200,opacity:0},to:{x:"-50%",y:0,opacity:1},when:t==false,curve:te.Spring,duration:.5,delay:2},className:`--network-manager --${t==true?"online":"offline"} --${s||W.Small} fixed flex`,children:[jsxRuntime.jsx(m,{className:"--ico",children:t?O[Pe.Success]:O[Pe.Error]}),jsxRuntime.jsx(_,{as:"--message",children:t?n||"internet connection restored :)":o||"no internet connection"})]})});Gs.displayName="Zuz.NetWorkManager";var Ip=Gs;var qs=react.forwardRef((e,r)=>{let{strenthMeter:t,onChange:n,...o}=e;"type"in o&&delete o.type;let{style:s,className:a,rest:i}=N(o),[f,c]=react.useState(false),[l,d]=react.useState(""),p=react.useMemo(()=>core.checkPasswordStrength(l),[l]),u=hooks.useDebounce(y=>{t&&d(y.target.value),n&&n(y);},100);return react.useEffect(()=>{},[]),jsxRuntime.jsxs(m,{as:"w:100% flex cols",children:[jsxRuntime.jsxs(m,{style:s,className:"--password flex aic rel",children:[jsxRuntime.jsx(pe,{ref:r,type:f?"text":"password",className:a,onChange:u,...i}),jsxRuntime.jsx(Z,{tabIndex:-1,onClick:()=>c(y=>!y),className:"--toggle flex aic jcc abs",children:f?O.eye:O.eyeSlash})]}),t&&jsxRuntime.jsxs(m,{as:`flex aic --password-meter --pb-score-${p.score}`,style:s,children:[jsxRuntime.jsxs(m,{as:"--password-bars flex aic",children:[jsxRuntime.jsx(m,{as:`--pbar ${p.score>=1?"--pb-on":""}`.trim()}),jsxRuntime.jsx(m,{as:`--pbar ${p.score>=2?"--pb-on":""}`.trim()}),jsxRuntime.jsx(m,{as:`--pbar ${p.score>=3?"--pb-on":""}`.trim()}),jsxRuntime.jsx(m,{as:`--pbar ${p.score>=4?"--pb-on":""}`.trim()}),jsxRuntime.jsx(m,{as:`--pbar ${p.score>=5?"--pb-on":""}`.trim()})]}),jsxRuntime.jsx(_,{as:"--password-meter-label","aria-hidden":true,children:p.result})]})]})});qs.displayName="Zuz.Password";var Op=qs;var Ys=react.forwardRef((e,r)=>{let{size:t,length:n,mask:o,...s}=e,a=react.useRef([]),i="pinput",f=false,c={};"with"in s&&(c={with:s.with},delete s.with),"type"in s&&delete s.type,"name"in s&&(i=s.name,delete s.name),"required"in s&&(f=true,delete s.required);let{style:l}=N(s),d=u=>{let y=u.currentTarget,C=a.current[parseInt(y.dataset.index)+1],x=a.current[parseInt(y.dataset.index)-1];y.value.length===1&&C?C.focus():y.value.length===0&&x&&x.focus();},{variant:p}=Q(true);return react.useEffect(()=>{a.current=a.current.slice(0,t||n);},[t||n]),jsxRuntime.jsx(m,{name:i,style:l,className:`--otp --${s.variant??p??W.Medium} flex aic rel`,"data-required":f,"data-size":t||n||4,...c,children:Array(t||n||4).fill(1).map((u,y)=>jsxRuntime.jsx(pe,{autoComplete:"new-password","data-index":y,ref:C=>{a.current[y]=C;},numeric:true,onChange:d,maxLength:1,placeholder:o?"\xB7":"0",type:o?"password":"text",...s},`pin-${y}`))})});Ys.displayName="Zuz.PinInput";var Ap=Ys;var js=react.forwardRef((e,r)=>{let{children:t,className:n,name:o,required:s,type:a,value:i,variant:f,checked:c,onSwitch:l,...d}=e,[p,u]=react.useState(c||false),{variant:y}=Q(true),C=react.useRef(null);return jsxRuntime.jsxs(wt,{className:`${n} --${(a||mo.Default).toLowerCase()} --radio${!a||a==mo.Default?"":"card"} --${f||y||W.Small} flex aic rel`.trim(),...d,children:[jsxRuntime.jsx(pe,{ref:C,defaultChecked:p,value:i||"rd",type:"radio",className:"abs",name:o,required:s||false,onChange:x=>{l&&l(x.target.checked,i||"cb"),u(x.target.checked);}}),jsxRuntime.jsx(m,{className:"--dot rel",children:jsxRuntime.jsx(m,{className:"--rod abs abc"})}),jsxRuntime.jsx(m,{className:"--value",children:t})]})});js.displayName="Zuz.Radio";var _p=js;var Qs=react.forwardRef((e,r)=>{let{fx:t,withStyle:n,as:o,reverse:s=false,searchIcon:a=O.search,hideSearchIcon:i=false,clearIcon:f=O.close,hideClearIcon:c=false,onChange:l,onClear:d,...p}=e,{style:u,className:y}=N({as:e.as}),[C,x]=react.useState(""),{variant:T}=Q(true),S=react.useRef(null);"type"in e&&delete e.type;let P=v=>{x(v.target.value),l?.(v.target.value);},g=v=>{C.trim()!==""&&(x(""),l?.(""),S.current&&(S.current.value="",e.onConfirm?.("")));};return react.useImperativeHandle(r,()=>({focus:()=>S.current?.focus(),value:()=>S.current?.value})),react.useEffect(()=>{},[]),jsxRuntime.jsxs(m,{style:u,className:`--search --no-shrink ${s?"--search-rev":""} --${e.variant||T||W.Medium} flex aic ${typeof e.as=="string"&&e.as.includes("abs")?"":"rel"} ${y}`.trim(),children:[jsxRuntime.jsx(pe,{ref:S,onChange:P,...p}),e.shortcut&&jsxRuntime.jsx(ir,{keys:e.shortcut,as:"abs"}),jsxRuntime.jsx(Z,{tabIndex:-1,onClick:v=>g(),className:"--send flex aic jcc",variant:e.variant||W.Medium,children:C!==""?!c&&(typeof f=="string"?jsxRuntime.jsx(oe,{name:f,as:"--search-action"}):f):!i&&(typeof a=="string"?jsxRuntime.jsx(oe,{name:a,as:"--search-action"}):a)})]})});Qs.displayName="Zuz.Search";var lr=Qs;var Yp=({label:e,icon:r})=>jsxRuntime.jsxs(m,{as:"--select-options-head --no-shrink --disabled".trim(),"aria-hidden":"true",children:[r&&jsxRuntime.jsx(oe,{name:r}),jsxRuntime.jsx(_,{as:"--select-group-label",children:e})]}),ea=Yp;var oa=({checkIcon:e,selected:r,updateValue:t,o:n})=>{let o=e?typeof e=="string"?jsxRuntime.jsx(oe,{name:"checkIcon"}):e:O.check,s=n.disabled===true;return jsxRuntime.jsxs(Z,{onClick:a=>{s||(a.stopPropagation(),t(n));},disabled:s,as:`--select-option-item --no-shrink ${r?"--selected":""} ${s?"--disabled":""} rel`.trim(),children:[jsxRuntime.jsxs(ze,{as:"--option-item-meta --aic",children:[n.icon&&jsxRuntime.jsx(oe,{name:n.icon,as:`--select-option-icon --icon-${n.value}`,color:n.iconColor}),jsxRuntime.jsx(_,{suppressHydrationWarning:true,children:typeof n=="string"?n:n.label})]}),r&&jsxRuntime.jsx(ze,{aic:true,jcc:true,as:"--select-option-check --abs",children:o})]})};oa.displayName="Option";var ra=oa;var na=({ref:e,...r})=>{let{selected:t,options:n,label:o,name:s,variant:a,search:i,searchPlaceholder:f,maxHeight:c,arrowDownIcon:l=O.arrowDown,arrowUpIcon:d=O.arrowUp,expanded:p,multiple:u,tokenizer:y,wrapTokens:C,disabled:x,checkIcon:T,closeIcon:S,onChange:P,required:g,with:v,...h}=r,b=De(),I=s&&b.values&&b.setFieldValue,z=I?b.errors?.[s]:null,E=I?b.values?.[s]:void 0,H=$=>!$&&$!==0?null:u||y?(Array.isArray($)?$:[$]).map(ce=>typeof ce=="string"||typeof ce=="number"?n.find(xe=>String(xe.value)===String(ce)):ce).filter(Boolean):typeof $=="string"||typeof $=="number"?n.find(X=>String(X.value)===String($)):$,[k,M]=react.useState(()=>t?H(t):n.find(X=>String(X.value)==="-1")||null),L=react.useMemo(()=>E?H(E):k,[E,k]),[F,R]=react.useState(false),[B,G]=react.useState(null),U=react.useRef(null),D=react.useRef(null),A=react.useRef(null),q=react.useId(),K=react.useMemo(()=>s||q,[]),{reposition:J}=xt(A,{direction:pt.Bottom,offset:2}),{variant:ee}=Q(true),ie=S?typeof S=="string"?jsxRuntime.jsx(oe,{name:S}):S:O.close,{className:me,style:ye,rest:se}=N(h,void 0),le=$=>Array.isArray(L)?L.some(X=>X.value===$.value):L?.value===$.value,Y=$=>{if(!(x||$.disabled))if(u||y){let X=Array.isArray(L)?L:[],xe=X.find(ao=>ao.value===$.value)?X.filter(ao=>ao.value!==$.value):[...X,$];M(xe),P?.(xe);}else M($),R(false),P?.($);},re=($,X)=>{if($.stopPropagation(),x)return;let ce=L.filter(xe=>xe.value!==X.value);I?b.setFieldValue?.(s,ce.map(xe=>xe.value)):M(ce),R(false),P?.(ce);},ne=$=>{let X=$.currentTarget,ce=X.scrollTop===0&&$.deltaY<0,xe=X.scrollHeight-X.scrollTop===X.clientHeight&&$.deltaY>0;!ce&&!xe||$.preventDefault(),$.stopPropagation();};react.useImperativeHandle(e,()=>({setSelected:$=>{let X=H($);if(I){let ce=Array.isArray(X)?X.map(xe=>xe.value):X?.value;b.setFieldValue?.(s,ce);}else M(X);},getValue:()=>L||null}),[L,n]),react.useEffect(()=>{if(!F)return;let $=()=>{J();};return window.addEventListener("scroll",$,true),window.addEventListener("resize",J),()=>{window.removeEventListener("scroll",J,true),window.removeEventListener("resize",J);}},[F,J]),react.useEffect(()=>{if(!F){D.current&&(D.current.value=""),G(null);return}D.current?.focus(),J();let $=ce=>{A.current&&!A.current.contains(ce.target)&&R(false);},X=setTimeout(()=>{document.addEventListener("click",$);},0);return ()=>{clearTimeout(X),document.removeEventListener("click",$);}},[F,J]),react.useEffect(()=>()=>{I&&b.deleteFieldValue?.(s);},[]);let ue=hooks.useDebounce($=>G($==""?null:$),300),Be=react.useMemo(()=>{if(L)return core._(L).isArray()?L.length>0?L[0]:void 0:L},[L]);return console.log(z),jsxRuntime.jsxs(m,{"data-required":g?"true":void 0,with:v,className:[`--select ${p==true?"--expanded":""}`,`--${a||ee}`,`${s?`--${s}`:""}`,`${x?"--disabled":""} rel`].join(" ").trim(),name:K,children:[jsxRuntime.jsxs(Z,{ref:U,disabled:x,variant:a||ee,"data-value":Be?.value??"-1",className:`--select-display --selected flex aic rel ${me}`.trim(),withLabel:false,style:ye,onClick:$=>{$.stopPropagation(),x||R(X=>!X);},...se,children:[Be?.icon&&jsxRuntime.jsx(oe,{as:"--selected-icon",name:Be.icon}),jsxRuntime.jsx(ze,{aic:true,as:"--label-wrapper",children:y&&Array.isArray(L)&&L.length>0?jsxRuntime.jsxs(ze,{as:`--tokens-wrap${C===true?" --wrap":""}`,children:[L?.map($=>jsxRuntime.jsxs(ze,{aic:true,as:"--token",children:[jsxRuntime.jsx(_,{as:"--token-label",children:$.label}),jsxRuntime.jsx(m,{as:"--token-remove",onClick:X=>re(X,$),children:ie})]},$.value)),L.length<n.length&&jsxRuntime.jsx(_,{as:"--label",children:o||"Choose"})]}):jsxRuntime.jsx(_,{as:"--label",children:Array.isArray(L)?L.length>0?`${L.length} selected`:o||"Choose":L?.label||o||"Choose"})}),jsxRuntime.jsx(m,{className:"--svg-arrow rel flex aic jcc",children:F?typeof d=="string"?jsxRuntime.jsx(oe,{name:d,as:"--search-action"}):d:typeof l=="string"?jsxRuntime.jsx(oe,{name:l,as:"--search-action"}):l})]}),jsxRuntime.jsxs(m,{id:K,className:"--options-list --allow-scroll -fx flex cols abs zIndex:var(--max-z-index)","aria-hidden":!F,onWheel:ne,style:{maxHeight:c||"auto"},ref:A,fx:{from:{y:5,opacity:0},to:{y:0,opacity:1},when:F,duration:.05},children:[i&&jsxRuntime.jsx(m,{as:"--select-search --no-shrink flex --sticky",children:jsxRuntime.jsx(lr,{ref:D,variant:W.Small,placeholder:f||"Search...",onChange:ue})}),o&&jsxRuntime.jsx(ea,{label:o}),n?.filter($=>!B||$.label.toLowerCase().includes(B.toLowerCase()))?.map($=>jsxRuntime.jsx(ra,{updateValue:Y,checkIcon:T,selected:le($),o:$},`option-${(typeof $=="string"?$:$.label).replace(/\s+/g,"-")}-${typeof $=="string"?$:$.value}`))]})]})};na.displayName="Zuz.Select";var ou=na;var sa=({ref:e,...r})=>jsxRuntime.jsx(Ct,{type:Oe.Switch,...r,ref:e});sa.displayName="Zuz.Switch";var ru=sa;var ia=e=>{let{idx:r,id:t,as:n,weight:o,style:s,value:a,render:i,resize:f,sortBy:c,sortable:l,onSort:d}=e,[p,u]=react.useState(0),y=()=>{l&&(d?.(String(t),p==1?-1:1),u(C=>C==1?-1:1));};return jsxRuntime.jsxs(m,{style:{flex:o||1,...s},as:`--col flex aic ${n||""} ${l?"--sortable":""}`,onClick:y,children:[jsxRuntime.jsx(m,{as:"--colv",children:a}),r==-1&&l&&c==t&&jsxRuntime.jsx(m,{as:"--arrow flex aib",children:p==1?O.arrowUp:O.arrowDown})]})};ia.displayName="Zuz.Column";var oo=ia;var ca=e=>{let{index:r,pubsub:t,schema:n,data:o,ids:s,styles:a,animate:i,sortBy:f,selectable:c,tableRef:l,loading:d,rowClassName:p,onSort:u,onRowClick:y,onSelect:C,onContextMenu:x}=e,T=hooks.useDelayed(),S=react.useMemo(()=>({transition:j.SlideInBottom,curve:te.EaseInOut,delay:.02*(r+1)}),[]),P=react.useRef(null),g=(h,b)=>{r==-1?t.emit(`ALL_ROWS_${h?"CHECKED":"UNCHECKED"}`,h):(C&&C(o,h),t.emit(`ROW_${h?"CHECKED":"UNCHECKED"}`,h,b));},v=(h,b,I)=>jsxRuntime.jsx(oo,{idx:h,id:b,as:"--selector",pubsub:t,value:jsxRuntime.jsx(Ct,{value:I,ref:P,onSwitch:g,type:Oe.Default})});return react.useEffect(()=>{let h=(E,H)=>{P.current?.setChecked(E,false);},b=(E,H)=>{let k=false;l?.current&&l.current.querySelectorAll(".--row").forEach(M=>{let L=M;if(!L.classList.contains("--row-head")){let F=L.querySelector(".--selector input[type=checkbox]");F&&F.checked&&!k&&(k=F.checked);}}),P.current.setChecked(k,false);},I=E=>{P.current?.setChecked(E,false),C&&C(o,E);},z=E=>{P.current?.setChecked(E,false),C&&C(o,E);};return r==-1?(t.on("ROW_CHECKED",h),t.on("ROW_UNCHECKED",b),()=>{t.off("ROW_CHECKED",h),t.off("ROW_UNCHECKED",b);}):(t.on("ALL_ROWS_CHECKED",I),t.on("ALL_ROWS_UNCHECKED",z),()=>{t.off("ALL_ROWS_CHECKED",I),t.off("ALL_ROWS_UNCHECKED",z);})},[]),jsxRuntime.jsxs(m,{onContextMenu:h=>x?x(h,o):null,onClick:h=>y?y(h,e.data):()=>{},...i?{fx:{...S,when:T}}:{},as:`--row flex aic ${y?"--row-clickable":""} ${r==-1?"--row-head":""} ${p||""}`,children:[r==-1&&n.map((h,b)=>{let{renderWhenHeader:I,render:z,value:E,...H}=h;return jsxRuntime.jsxs(react.Fragment,{children:[c&&b==0&&v(-1,`--selector-${h.id}`,"all"),jsxRuntime.jsx(oo,{idx:-1,onSort:u,sortBy:f,value:E,...H,pubsub:t,style:a[h.id]})]},`--col-${h.id}`)}),d&&r>-1&&jsxRuntime.jsx(m,{as:"--col",children:jsxRuntime.jsx(_,{as:"opacity:0",children:"..."})}),!d&&r>-1&&s&&o&&n.map((h,b)=>jsxRuntime.jsxs(react.Fragment,{children:[c&&b==0&&v(b,`--selector-${h.id}`,h.id.toString()),s.includes(String(h.id))?jsxRuntime.jsx(oo,{pubsub:t,idx:b,id:String(h.id),style:a[String(h.id)],value:h.render?h.render(o,r):o[String(h.id).includes(".")?String(h.id).split(".").reverse()[0]:h.id]}):null]},`--${String(h.id)}-val-${b}`))]})};ca.displayName="Zuz.Row";var ro=ca;var fa=(e,r)=>{let{schema:t,rows:n,rowCount:o,rowsPerPage:s,currentPage:a,pagination:i,paginationHash:f,showPaginationOnZeroPageCount:c,animateRows:l,header:d,rowClassName:p,selectableRows:u,hoverable:y,sortBy:C,loading:x,loadingRowCount:T,loadingMessage:S,spinner:P,emptyMessage:g,onSort:v,onRowClick:h,onRowSelectToggle:b,onPageChange:I,onRowContextMenu:z,...E}=e,H=react.useRef(null),k=react.useMemo(()=>t.reduce((le,Y)=>(le[Y.id]={flex:Y.weight||1,...Y.w&&{width:Y.w},...Y.maxW&&{maxWidth:Y.maxW},...Y.minW&&{minWidth:Y.minW},...Y.h&&{height:Y.h},...Y.maxH&&{maxHeight:Y.maxH},...Y.minH&&{minHeight:Y.minH}},le),{}),[t]),M=react.useMemo(()=>Object.keys(k),[t]),L=react.useMemo(()=>d??true,[d]),{style:F,className:R,rest:B}=N(E),G=react.useRef(null),U=react.useMemo(()=>new core.PubSub,[]),D=react.useRef(n.map(()=>core.uuid(8))),[A,q]=react.useState(C||null),[K,J]=react.useState(S||"loading"),ee=react.useMemo(()=>!x&&n&&n.length==0,[x,n]),ie=react.useCallback(()=>g?typeof g=="function"?jsxRuntime.jsx(g,{}):g:jsxRuntime.jsx(_,{as:"tac s:18 mt:75",children:"No Record Found"}),[x,n]);react.useEffect(()=>{n.length&&!D.current&&(D.current=n.map(()=>core.uuid(8)));},[n]);let me=(le,Y)=>{q(le),v?.(le,Y);},ye=(o||(n?n.length:0))/(s||10),se=react.useMemo(()=>c||ye>1?jsxRuntime.jsx(St,{hash:f,ref:H,renderOnZeroPageCount:c,onPageChange:I,paginationStyle:"table",startPage:a,itemCount:o||(n?n.length:0),itemsPerPage:s||10}):null,[a,o]);return react.useImperativeHandle(r,()=>({setLoading(le){}})),jsxRuntime.jsxs(m,{as:`--table ${y??true?"--hoverable":""} flex cols rel ${R}`,ref:G,children:[L==true&&jsxRuntime.jsx(ro,{sortBy:A,onSort:me,tableRef:G,pubsub:U,selectable:u,index:-1,schema:t,loading:true,styles:k}),x&&jsxRuntime.jsxs(m,{as:"center-x flex aic --table-spinner",children:[jsxRuntime.jsx(Se,{type:P||he.Simple}),K&&jsxRuntime.jsx(_,{as:"--table-loading-message",children:K})]}),x&&Array(T||5).fill({}).map((le,Y)=>jsxRuntime.jsx(ro,{tableRef:G,index:Y,pubsub:U,schema:t,styles:k,loading:true,animate:l,onRowClick:h},`--trow-loading-${Y}-${t[0].id}`)),!x&&n&&n.map((le,Y)=>jsxRuntime.jsx(ro,{tableRef:G,pubsub:U,loading:false,index:Y,schema:t,ids:M,styles:k,animate:l,data:le,onRowClick:h,rowClassName:p,selectable:u,onSelect:b,onContextMenu:z},`--trow-${D.current[Y]||Y}-${t[0].id}`)),ee&&ie(),i&&se&&jsxRuntime.jsx(m,{"aria-hidden":!i||!se,...l?{fx:{transition:j.SlideInBottom,curve:te.EaseInOut,delay:.02*(n.length+1),when:!x&&n&&i&&se!=null}}:{},as:"--row flex aic --row-footer",children:se})]})};fa.displayName="Zuz.Table";var hu=react.forwardRef(fa),yu=hu;var bu=({ref:e,...r})=>{let{title:t,items:n}=r,[o,s]=react.useState(0),a=(i,f,c)=>{i.preventDefault(),s(f),document.getElementById(c)?.scrollIntoView({behavior:"smooth"});};return jsxRuntime.jsxs(m,{ref:e,as:"--table-of-contents rel flex cols",children:[jsxRuntime.jsx(_,{as:"--toc-title",children:t}),jsxRuntime.jsx(Xe,{items:n.map((i,f)=>jsxRuntime.jsx("a",{className:o==f?"--toc-active":"",style:{anchorName:o===f?"--toc-active":"none",color:o==f?"var(--table-of-contents-color-active)":"var(--table-of-contents-color)"},onClick:c=>a(c,f,i.tag),href:`#${i.tag}`,children:i.label}))})]})},vu=bu;var da=({isActive:e,transitionType:r,speed:t,width:n,render:o,content:s,onHeightChange:a})=>{let i=react.useRef(null),f=hooks.useResizeObserver(i);react.useEffect(()=>{e&&f.height>0&&a(f.height);},[e,f.height]);let l=react.useMemo(()=>{let d={width:n>0?`${n}px`:"100%",minWidth:n>0?`${n}px`:"100%",flexShrink:0,height:"fit-content",boxSizing:"border-box"};return r==="fade"?{...d,gridArea:"1 / 1 / 2 / 2",opacity:e?1:0,visibility:e?"visible":"hidden",transition:`opacity ${t}s ease-in-out`,zIndex:e?1:0}:r==="scale"?{...d,gridArea:"1 / 1 / 2 / 2",opacity:e?1:0,transform:`scale(${e?1:.95})`,transition:`all ${t}s cubic-bezier(0.34, 1.56, 0.64, 1)`,zIndex:e?1:0}:d},[e,r,n,t]);return jsxRuntime.jsx(m,{ref:i,style:{...l},className:"--content",children:o||e?s:null})};da.displayName="Zuz.TabBody";var ga=da;var xa=({ref:e,...r})=>{let{tabs:t,speed:n=.3,prerender:o=true,variant:s,tabStyle:a="fixed",onChange:i,transitionType:f="slide",...c}=r,[l,d]=react.useState(0),p=react.useRef(null),u=hooks.useResizeObserver(p),y=react.useMemo(()=>core.uuid(8),[]),[C,x]=react.useState("auto"),T=react.useMemo(()=>u.width>0,[u.width]);react.useImperativeHandle(e,()=>({setTab:b=>d(b)}));let S=react.useMemo(()=>t.map(b=>({...b,key:b.key||core.uuid(8)})),[t]),{style:P,className:g,rest:v}=N({as:`flex cols w-full no-overflow ${c.as||""}`,...c}),h=()=>{if(!T)return {opacity:0};switch(f){case "fade":case "scale":return {display:"grid",gridTemplateColumns:"1fr",width:"100%"};default:return {width:`${S.length*100}%`,alignItems:"flex-start",display:"flex",transform:`translate3d(-${l*u.width}px, 0, 0)`,transition:`transform ${n}s cubic-bezier(0.4, 0, 0.2, 1)`}}};return jsxRuntime.jsxs(m,{ref:p,style:P,className:`--tabview --${a} flex cols ${g}`,children:[jsxRuntime.jsx(Tt,{as:"--tabview-head",onSwitch:b=>{d(b.index);let I=S.find(z=>z.tag==b.tag);I&&I.onSelect&&(I.onSelect(I,b.index),i?.(I,b.index));},selected:l,items:S.reduce((b,I,z)=>(b.push({icon:I.icon,index:z,label:I.label,tag:I.tag}),b),[])}),jsxRuntime.jsx(m,{className:"--tabview-body",as:"rel no-overflow w-full",style:{height:C,transition:T?`height ${n}s cubic-bezier(0.4, 0, 0.2, 1)`:"none",opacity:T?1:0},children:jsxRuntime.jsx(m,{className:"--track",style:{...h()},children:S.map((b,I)=>jsxRuntime.jsx(ga,{isActive:I===l,transitionType:f,speed:n,width:u.width,render:o||I===l,onHeightChange:z=>I===l&&x(z),content:b.body},`tab-body-${b.key||I}-${y}`))})})]})};xa.displayName="Zuz.TabView";var Eu=xa;var Ou=({ref:e,commands:r,onCommand:t,welcomeMessage:n="Welcome to Zuz Terminal v1.0.0",prompt:o="zuz ~ ",variant:s,...a})=>{let[i,f]=react.useState([{type:"output",content:n}]),[c,l]=react.useState(""),d=react.useRef(null),p=react.useRef(null),{variant:u}=Q(true);react.useEffect(()=>{d.current&&(d.current.scrollTop=d.current.scrollHeight);},[i]);let y=g=>{let v=typeof g=="string"?{type:"output",content:g}:g;f(h=>{let b=[...h,v];return b.length>1e3?b.slice(-1e3):b});},C=()=>f([]);react.useImperativeHandle(e,()=>({write:y,clear:C}));let x=async g=>{let[v,...h]=g.split(" "),b=v.toLowerCase();return r&&r[b]?await r[b](h):t?await t(g):`command not found: ${v}`},T=g=>{let v=/\u001b\[(\d+)m/g,h=[],b={31:"#ff5f56",32:"#27c93f",33:"#ffbd2e",34:"#007aff",35:"#ff79c6",36:"#8be9fd",39:"#d4d4d4"},I=0,z="#d4d4d4",E=false,H;for(;(H=v.exec(g))!==null;){let M=g.slice(I,H.index);M&&h.push({text:M,color:z,bold:E});let L=H[1];L==="0"?(z="#d4d4d4",E=false):L==="1"?E=true:b[L]&&(z=b[L]),I=v.lastIndex;}let k=g.slice(I);return k&&h.push({text:k,color:z,bold:E}),h},S=(g,v)=>g.includes("\x1B")?T(g).map((h,b)=>jsxRuntime.jsx(ae,{style:{color:h.color||"#d4d4d4",fontWeight:h.bold?"bold":"normal"},children:h.text},`--terminal-msg-${b}-${h.text.replace(/\S+/g,"-")}`)):jsxRuntime.jsx(ae,{style:{color:v==="error"?"#ff5f56":v==="command"?"#00ff00":"#d4d4d4"},children:g}),P=async g=>{if(g.key==="Enter"&&c.trim()){let v=c.trim(),h=[...i,{type:"command",content:`${o}${v}`}];l(""),f(h);let b=await x(v);f(I=>[...I,{type:"output",content:b}]);}};return jsxRuntime.jsxs(m,{as:`--zuz-terminal --${s||u||W.Medium} flex cols ${a.className}`,onClick:()=>p.current?.focus(),children:[jsxRuntime.jsx(m,{ref:d,className:"--terminal-log",children:i.map((g,v)=>jsxRuntime.jsx(m,{children:jsxRuntime.jsx(_,{children:S(g.content,g.type)})},v))}),jsxRuntime.jsxs(m,{as:"flex aic --terminal-input",children:[jsxRuntime.jsx(_,{as:"--terminal-prompt",children:o}),jsxRuntime.jsx(pe,{ref:p,className:"--zuz-term-input",autoFocus:true,value:c,variant:s||u||W.Medium,onChange:g=>l(g.target.value),onKeyDown:P})]})]})},Vu=Ou;var Du=({meta:e})=>jsxRuntime.jsxs(Z,{as:"flex aic --command-item",children:[e.icon&&jsxRuntime.jsx(oe,{name:e.icon,as:"--command-icon"}),jsxRuntime.jsx(_,{children:e.label})]}),Hu=({position:e,onSelect:r,commands:t,visible:n})=>jsxRuntime.jsx(m,{"aria-hidden":!n,fx:{transition:j.SlideInBottom,duration:.1,when:n},className:"--command-box abs grid",style:{...e},children:t.map(o=>jsxRuntime.jsx(Du,{meta:o},`cmd-${o.label.replace(/\s+/,"-")}`))}),wa=Hu;var Pa=({ref:e,...r})=>{let {autoResize:t,maxHeight:n,variant:o,resize:s="none",command:a,commands:i,name:f,onInput:c,cmd:l,renderDropdown:d,value:p,defaultValue:u,...y}=r,C=react.useRef(null),x=react.useRef(null),{variant:T}=Q(true),{style:S,className:P,rest:g}=N(y),v=De();f?v.errors?.[f]:null;let b=f&&v.values&&v.setFieldValue,I=b?v.values?.[f]:void 0,z=hooks.useDebounce(B=>{b&&v.setFieldValue?.(f,B);},500),{showDropdown:E,dropdownPosition:H,handleKeyDown:k,handleInput:M,handleCommandSelect:L}=hooks.useCommandActions({command:a,commands:i,cmd:l,ref:C}),F=react.useCallback(()=>{let B=C.current;!B||!t||(x.current&&cancelAnimationFrame(x.current),x.current=requestAnimationFrame(()=>{B.style.height="auto";let G=B.scrollHeight;if(n){let U=parseInt(n.toString(),10);isNaN(U)||(G=Math.min(G,U));}B.style.height=`${G}px`,B.style.overflowY=n&&G>=parseInt(n.toString(),10)?"auto":"hidden";}));},[t,n]),R=B=>{z(B.currentTarget.value),c?.(B),M(B),F();};return react.useEffect(()=>{C.current&&f&&I!==void 0&&C.current.value!==String(I)&&(C.current.value=String(I));},[I,f]),react.useEffect(()=>{F();},[p,u,F]),react.useEffect(()=>{t&&C.current&&F();},[t,F]),react.useEffect(()=>()=>{x.current&&cancelAnimationFrame(x.current);},[]),react.useEffect(()=>()=>{b&&v.deleteFieldValue?.(f);},[]),jsxRuntime.jsxs(m,{as:"rel",children:[jsxRuntime.jsx("textarea",{name:f,className:`--input --textarea --${o||T||W.Medium} flex ${P}`.trim(),style:{...S,resize:s,height:t?"auto":S?.height,overflow:"hidden",transition:t?"none":void 0},onKeyDown:k,onInput:R,ref:B=>{C.current=B,typeof e=="function"?e(B):e&&(e.current=B);},value:p,defaultValue:u,...g}),d?d({show:E,position:H,commands:i||[],onSelect:L}):i&&i.length>0&&jsxRuntime.jsx(wa,{visible:E,commands:i,onSelect:L,position:H})]})};Pa.displayName="Zuz.TextArea";var _u=Pa;var Ia=react.forwardRef((e,r)=>{let{as:t,value:n,color:o,direction:s,...a}=e,i=react.useRef(null),[f,c]=react.useState(n||0);return react.useImperativeHandle(r,()=>({updateValue(l){f.toString().length!==l.toString().length&&c(l);},setValue(l){if(this.updateValue(l),i.current){let d=l.toString().split("");i.current.querySelectorAll(".--wheel-char").forEach((p,u)=>{let y=d[u];if(p instanceof HTMLElement){p.setAttribute("data-value",y);let C=p.querySelector(".--wheel-char-track");C instanceof HTMLElement&&(C.style.setProperty("--v",y),C.offsetWidth);}});}}})),react.useEffect(()=>{c(n||0);},[n]),jsxRuntime.jsxs(m,{className:"--text-wheel flex aic rel","aria-hidden":true,as:t,ref:i,...a,children:[(f||0).toString().split("").map((l,d)=>isNaN(parseInt(l,10))?jsxRuntime.jsx(ae,{className:"--wheel-char wheel-char-symbol grid",children:l},`wheel-char-symbol-${d}`):jsxRuntime.jsx(ae,{"data-value":l,className:`--wheel-char grid ${d>(f||0).toString().length-3?"--wheel-fraction":""}`.trim(),children:jsxRuntime.jsxs(ae,{className:`--wheel-char-track --wheel-track-${s||"down"} grid`,style:{"--v":l},children:[jsxRuntime.jsx(ae,{children:!s||s==="down"?0:9}),(!s||s==="down"?[9,8,7,6,5,4,3,2,1,0]:[0,1,2,3,4,5,6,7,8,9]).map((p,u)=>jsxRuntime.jsx(ae,{children:p},`${d}--${u}`)),jsxRuntime.jsx(ae,{children:!s||s==="down"?9:0})]})},`wheel-char-${d}`)),o&&jsxRuntime.jsx(m,{className:"abs fillx",style:{zIndex:1,background:`linear-gradient(0deg, ${o}, transparent, transparent, transparent, ${o})`}})]})});Ia.displayName="Zuz.TextWheel";var Xu=Ia;var xr=react.forwardRef((e,r)=>{let{as:t,meta:n,nodes:o,icons:s,onSelect:a,treeTag:i,selected:f,roots:c,expanded:l,...d}=e,{tag:p,label:u,icon:y,under:C,isHead:x}=n,T=react.useMemo(()=>c.includes(p),[c]),[S,P]=react.useState(l),g=()=>{localStorage.setItem(`--tn${i}-${p}`,S?"0":"1"),P(!S);};react.useEffect(()=>{l||T&&!localStorage.getItem(`--tn${i}-${p}`)?(localStorage.setItem(`--tn${i}-${p}`,"1"),P(true)):P(localStorage.getItem(`--tn${i}-${p}`)=="1");},[]);let v=react.useMemo(()=>o.filter(h=>h.under==p),[o,p]);return jsxRuntime.jsxs(m,{className:`--treenode ${T?"--is-root":""} --treenode-${p} flex cols`,children:[jsxRuntime.jsxs(m,{className:`--node --node-${p} flex aic ${f==p?" --selected":""}`,children:[jsxRuntime.jsx(Z,{skeleton:d.skeleton,onClick:g,className:"--node-aro-btn",disabled:v.length==0,children:s?.arrowClose&&s?.arrowOpen?jsxRuntime.jsx(oe,{skeleton:d.skeleton,className:"--node-aro-icon",name:v.length==0?s?.arrowDisabled||s?.arrowClose:S?s?.arrowOpen:s?.arrowClose}):v.length==0?O.chevronBottom:S?O.chevronBottom:O.chevronRight}),jsxRuntime.jsxs(Z,{className:"--node-meta flex aic",onClick:h=>a(p),children:[(s?.nodeOpen&&s?.nodeClose||T&&s?.rootOpen&&s?.rootClose)&&jsxRuntime.jsx(oe,{skeleton:d.skeleton,className:`--node-icon ${T?"--icon-root":""}`,name:y||(S?T&&s?.rootOpen||s.nodeOpen:T&&s?.rootClose||s?.nodeClose)}),jsxRuntime.jsx(_,{className:`--node-label ${T?"--node-label-root":""}`.trim(),skeleton:d.skeleton,children:u})]})]}),S&&v.length>0&&jsxRuntime.jsx(m,{className:`--sub-node tree-sub-node-${p} flex cols`,children:v.map(h=>jsxRuntime.jsx(xr,{treeTag:i,selected:f,onSelect:a,icons:s,roots:c,expanded:h.expanded||false,meta:h,nodes:o},`--node-${h.tag}`))})]})});xr.displayName="TreeItem";var Ba=xr;var ka=react.forwardRef((e,r)=>{let{as:t,nodes:n,onNodeSelect:o,tag:s,icons:a,roots:i,selected:f,...c}=e,[l,d]=react.useState(f);react.useImperativeHandle(r,()=>({getSelected:()=>l}),[o]);let p=u=>{d(u),o&&o(u);};return react.useEffect(()=>{l!=f&&d(f);},[f]),jsxRuntime.jsx(m,{className:"--treeview flex cols",children:n.filter(u=>i.includes(u.tag)).map(u=>jsxRuntime.jsx(Ba,{treeTag:s?`-${s}`:"",selected:l,onSelect:y=>p(y),icons:a,meta:u,roots:i,expanded:u.expanded||false,skeleton:c.skeleton,nodes:n},`--node-${u.tag}`))})});ka.displayName="Zuz.TreeView";var rf=ka;String.prototype.trim=function(){return this.replace(/^\s+|\s+$/g,"").replace(/\s+/g," ")};
14
- Object.defineProperty(exports,"PACKAGE_NAME",{enumerable:true,get:function(){return chunkCKUNYZUA_cjs.f}});Object.defineProperty(exports,"cleanProps",{enumerable:true,get:function(){return chunkCKUNYZUA_cjs.g}});Object.defineProperty(exports,"splitAtoms",{enumerable:true,get:function(){return chunkCKUNYZUA_cjs.h}});exports.ALERT=Pe;exports.AVATAR=Cr;exports.Accordion=xl;exports.ActionBar=Tl;exports.Alert=Il;exports.AutoComplete=Ql;exports.Avatar=ac;exports.Badge=lc;exports.Box=m;exports.Bubble=Zc;exports.BubbleMediaType=Xn;exports.BubbleStatus=qn;exports.Button=Z;exports.CHART=Kn;exports.CHECKBOX=Oe;exports.COLORTHEME=lf;exports.Calendar=Zo;exports.Carousel=Mc;exports.Chart=zc;exports.CheckBox=Ct;exports.CodeBlock=tm;exports.ColorScheme=ym;exports.ContextMenu=So;exports.CookiesConsent=Sm;exports.Cover=Ee;exports.CropShape=Vm;exports.Cropper=Mm;exports.Crumb=Hm;exports.DATATYPE=pf;exports.DIALOG=et;exports.DIALOG_ACTION_POSITION=Tr;exports.DRAWER_SIDE=ve;exports.DatePicker=Fm;exports.Dialog=Po;exports.Drawer=Bo;exports.FILTER=kt;exports.FORMVALIDATION=Ke;exports.FORMVALIDATION_STYLE=uf;exports.Fab=Wm;exports.Filters=qm;exports.Flex=ze;exports.Form=cp;exports.Grid=up;exports.Group=wo;exports.Icon=oe;exports.Image=Ye;exports.Input=pe;exports.KeyboardKeys=ir;exports.KeysLabelMap=Ls;exports.KeysMap=ks;exports.Label=wt;exports.LayersProvider=xo;exports.List=Xe;exports.MediaPlayer=Cp;exports.NetworkStatus=Ip;exports.ORIGIN=ut;exports.OriginType=cf;exports.Overlay=We;exports.POSITION=pt;exports.PROGRESS=df;exports.Pagination=St;exports.PaginationStyle=Ut;exports.Password=Op;exports.PinInput=Ap;exports.Position=de;exports.ProgressBar=Ue;exports.RADIO=mo;exports.Radio=_p;exports.SHEET=Re;exports.SHEET_ACTION_POSITION=lo;exports.SKELETON=af;exports.SLIDER=co;exports.SORT=mf;exports.SPINNER=he;exports.ScrollView=Ro;exports.Search=lr;exports.Select=ou;exports.SelectTabs=Tt;exports.Sheet=ep;exports.Slider=ot;exports.SnackPosition=Ft;exports.SnackStyle=an;exports.SnackType=zt;exports.Span=ae;exports.Spinner=Se;exports.Status=ff;exports.Switch=ru;exports.TRANSITIONS=j;exports.TRANSITION_CURVES=te;exports.TabView=Eu;exports.Table=yu;exports.TableOfContents=vu;exports.Terminal=Vu;exports.Text=_;exports.TextWheel=Xu;exports.Textarea=_u;exports.ThemeProvider=za;exports.ToastDefaultTitle=ln;exports.ToastPosition=Ft;exports.ToastProvider=ko;exports.ToastStyle=an;exports.ToastType=zt;exports.ToolTip=jo;exports.TreeView=rf;exports.Variant=W;exports.animationTransition=ft;exports.buildClassString=po;exports.buildWithStyles=Ir;exports.css=Mf;exports.getAnimationCurve=uo;exports.getAnimationTransition=Of;exports.getZuzMap=Ma;exports.isKeyCombination=Es;exports.setZuzMap=Rr;exports.useBase=N;exports.useContextMenu=qi;exports.useDialog=ji;exports.useDrawer=el;exports.useFx=ge;exports.useMorph=rl;exports.usePosition=xt;exports.useSnack=ml;exports.useToast=Lo;
12
+ <span class="--line-content">${y||" "}</span>
13
+ </div>`}).join("")},[t,h]);return jsxRuntime.jsxs(p,{as:`--code-block rel ${d}`,style:u,...c,children:[jsxRuntime.jsx("pre",{ref:e,children:jsxRuntime.jsx("code",{className:`--code --lang-${o}`,dangerouslySetInnerHTML:{__html:C}})}),n&&jsxRuntime.jsx(F,{as:"--copy-code abs",onClick:()=>{core.copyToClipboard(t),n.onCopy?.();},children:"Copy"})]})},hm=gm;var cs=({onSelect:e,meta:r,selected:t,disabled:n=false})=>{let o=react.useRef(null),{index:s,icon:a,label:l}=r,[f,c]=react.useState({x:0,width:0}),i=hooks.useDelayed();return react.useLayoutEffect(()=>{if(i&&o.current){let{width:d,x:u}=o.current.getBoundingClientRect();c({x:u,width:d}),t&&e(s,d,u,r,true);}},[i,o.current]),react.useEffect(()=>{t&&e(s,f.width,f.x,r,false);},[t]),jsxRuntime.jsxs(F,{disabled:n,onClick:()=>e(s,f.width,f.x,r,false),ref:o,className:`--segment-item flex aic rel ${t?"--segment-active":""}`.trim(),children:[a?typeof a=="string"?jsxRuntime.jsx(J,{name:a,as:"--segment-icon"}):jsxRuntime.jsx(p,{as:"--segment-icon flex aic jcc",children:a}):null,l&&String(l).trim()!=""&&jsxRuntime.jsx(p,{className:"--segment-label",children:l||`Item ${s}`})]})};cs.displayName="SelectTabItem";var ms=cs;var us=react.forwardRef((e,r)=>{let{fx:t,items:n,selected:o,variant:s,disabled:a=false,onSwitch:l,...f}=e,[c,i]=react.useState(o||0),d=hooks.useDelayed(50),u=react.useRef(c),{className:m,style:h,rest:C}=E(f),x=react.useRef(null),T=react.useRef(null),{variant:S}=j(true),P=(g,v,y,b,I)=>{if((I||c!=g&&c!=-2)&&(i(g),u.current=c,queueMicrotask(()=>{d&&l?.(b);})),x.current){let D=T.current?.getBoundingClientRect();x.current.style.setProperty("--w",`${v}px`),x.current.style.setProperty("--x",`${D?y-D.left:y}px`);}};return react.useImperativeHandle(r,()=>({setSelected:g=>{typeof g=="number"&&g!=c&&i(g);}}),[c]),jsxRuntime.jsxs(p,{ref:T,"data-selected":c,className:`${m} --segmented --${s||S||U.Medium} flex aic rel`,style:h,...C,children:[jsxRuntime.jsx(p,{ref:x,className:`--segment-tab --${a?"disabled":"abled"} abs`}),n.map((g,v)=>jsxRuntime.jsx(ms,{disabled:a,onSelect:P,selected:c==v,meta:{...g,index:v}},`segment-${g.label}-${v}`))]})});us.displayName="Zuz.SelectTabs";var kt=us;var gs=react.forwardRef((e,r)=>{let{type:t,variant:n,...o}=e,s=hooks.useDelayed(),{colorScheme:a,setColorScheme:l}=Ro(),f=react.useCallback(()=>{l(a=="dark"?"light":a=="light"?"system":"dark");},[a]),{variant:c}=j(true),{className:i,style:d}=E(o),u=react.useMemo(()=>t=="system"?[{tag:"light",index:0,label:"",icon:O.colorSchemeLight},{tag:"system",index:1,label:"",icon:O.colorSchemeSystem},{tag:"dark",index:2,label:"",icon:O.colorSchemeDark}]:[{tag:"light",index:0,label:"",icon:O.colorSchemeLight},{tag:"dark",index:2,label:"",icon:O.colorSchemeDark}],[]),m=react.useMemo(()=>["light","system","dark"].indexOf(a),[a]);return !s||m==-1?null:t=="system"||t=="switch"?jsxRuntime.jsx(kt,{className:`--color-scheme --${t}`,onSwitch:({tag:h})=>{l(h);},selected:m,items:u,...o}):jsxRuntime.jsx(F,{onClick:f,style:d,variant:n,as:`--color-scheme-switch ${i}`.trim(),children:a=="system"?O.colorSchemeSystem:a=="light"?O.colorSchemeLight:O.colorSchemeDark})});gs.displayName="Zuz.ColorScheme";var Lm=gs;var ys=react.forwardRef((e,r)=>{let[t,n]=react.useState("wait"),{title:o,message:s,acceptLabel:a,rejectLabel:l,position:f}=e,c=async i=>{n(i==1?"accepted":"rejected"),localStorage.setItem("--ccnt",String(i));};return react.useEffect(()=>{let i=localStorage.getItem("--ccnt");n(i?i=="1"?"accepted":"rejected":"pending");},[]),jsxRuntime.jsxs(p,{fx:{from:{x:-1e3},to:{x:0},when:t=="pending",curve:ee.EaseInOut,duration:.5,delay:t=="accepted"?0:3},as:`--cookie-consent --${t} --${f||he.Left} flex cols`,children:[jsxRuntime.jsx(_,{as:"--title",children:o||"This site uses cookies"}),jsxRuntime.jsx(_,{as:"--message",children:s||"We and selected third parties use cookies (or similar technologies) for technical purposes, to enhance and analyze site usage, to support our marketing efforts"}),jsxRuntime.jsxs(p,{as:"--footer flex aic",children:[jsxRuntime.jsx(F,{onClick:i=>c(1),as:"--accept",children:a||"Accept All"}),jsxRuntime.jsx(F,{onClick:i=>c(0),as:"--reject",children:l||"Cancel"})]})]})});ys.displayName="Zuz.CookiesConsent";var Dm=ys;var vs=({ref:e,...r})=>{let {title:t,position:n,margin:o=4,anchorName:s="--tooltip-anchor",children:a,show:l,variant:f,...c}=r,{style:i,className:d,rest:u}=E(c),m=n||he.Top;react.useRef(null);let [C,x]=react.useState(false);react.useRef(6);let S=l===true||C,g=`--anchor-${react.useId().replace(/:/g,"")}`,{tooltip:v}=j(true),y=react.useMemo(()=>{let I=false;return react$1.addPropsToChildren(a,D=>{let N=D.props.className?.includes(s);return N&&(I=true),N||!I},(D,N)=>{let A=N.props.className?.includes(s),L=D===0,M={};return (A||L)&&(M.style={...N.props.style,anchorName:g}),L&&(M.onMouseEnter=$=>{x(true),N.props.onMouseEnter?.($);},M.onMouseLeave=$=>{x(false),N.props.onMouseLeave?.($);}),M})},[a,s,g]),b=ye({transition:m==he.Top?Y.SlideInTop:m==he.Bottom?Y.SlideInBottom:m==he.Left?Y.SlideInLeft:Y.SlideInRight,when:S,duration:.2,offset:o+6,margin:m==he.Top||m==he.Left?-o:o,curve:v?.curve||ee.EaseInOut});return react.useImperativeHandle(e,()=>({show:()=>x(true),hide:()=>x(false),setPosition:()=>{}})),jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[y,jsxRuntime.jsx(p,{style:{positionAnchor:g,...b.style,...m===he.Top||m===he.Bottom?{"--fx-x":"-50%"}:{"--fx-y":"-50%"}},as:`--tooltip --visb-${S} --${f||v?.variant||U.Small} --${m} abs ${d}`.trim(),children:typeof t=="string"?jsxRuntime.jsx(_,{as:"--text rel",children:t}):t})]})};vs.displayName="Zuz.ToolTip";var ar=vs;var Ss=({ref:e,...r})=>{let {type:t,value:n=0,min:o=0,max:s=1,step:a=.01,onChange:l,showGhostBar:f,showKnobOnHover:c,showToolTip:i,roundValue:d,formatValue:u,...m}=r,{className:h,style:C,rest:x}=E(m),T=react.useRef(a||.01).current,S=react.useRef(o||0).current,P=react.useRef(s||1).current,g=react.useRef(n||0).current,v=react.useRef(null),y=react.useRef(null),b=react.useRef(null),I=react.useRef(null);react.useRef(null);let N=react.useRef(null),A=react.useRef(null),L=react.useRef(null),M=react.useRef(null),$=(te,ie,ue)=>(te-ie)/(ue-ie)*100,K=te=>{if(y.current){let ie=parseFloat(te.currentTarget.value);re(ie);let ue=$(ie,parseFloat(te.currentTarget.min),parseFloat(te.currentTarget.max));y.current.style.setProperty("--value",`${ue}`),y.current.setAttribute("data-value",`${ie}`),l&&l(d?+ie.toFixed(2):ie);}},[R,B]=react.useState(false),[q,X]=react.useState(0),[H,z]=react.useState(0),[W,Z]=react.useState(false),re=async te=>{let ie=u?u(+te):d?(+te).toFixed(2):Math.round(+te);L.current&&(L.current.textContent=String(ie));},se=te=>{if(R){let ie=te.clientX-q,ue=P-S,Re=ie/200*ue,be=Math.max(S,Math.min(H+Re,P));if(be=Math.round(be/T)*T,re(be),y.current){let Ae=$(be,S,P);y.current.style.setProperty("--value",`${Ae}`),y.current.setAttribute("data-value",`${be}`),A.current&&(A.current.textContent=d?be.toFixed(2):be.toString()),l&&l(be);}}},me=()=>{B(false),document.body.style.cursor="auto";},ge=te=>(te-S)/(P-S)*100,ae=te=>{if(!y.current)return;let ie=y.current.getBoundingClientRect(),ue=te.clientX-ie.left,He=Math.max(0,Math.min(100,ue/ie.width*100));if(i&&L.current){let Re=v.current?+v.current.value:n;re(Re*100);}if(f){let Re=ge(v.current?+v.current.value:n),be=Math.min(Re,He),Ae=Math.abs(He-Re);y.current.style.setProperty("--ghost-start",`${be}`),y.current.style.setProperty("--ghost-width",`${Ae}`);}};react.useEffect(()=>{y.current&&y.current.style.setProperty("--value",v.current?`${$(parseFloat(v.current.value),parseFloat(v.current.min),parseFloat(v.current.max))}`:g.toString());},[]),react.useEffect(()=>(R?(document.addEventListener("mousemove",se),document.addEventListener("mouseup",me)):(document.removeEventListener("mousemove",se),document.removeEventListener("mouseup",me)),()=>{document.removeEventListener("mousemove",se),document.removeEventListener("mouseup",me);}),[R]),react.useEffect(()=>{let te=$(n,S,P);y.current?.style.setProperty("--value",`${te}`),re(n);},[n,S,P,L.current]);let G=()=>jsxRuntime.jsxs(p,{ref:y,onMouseEnter:()=>Z(true),onMouseLeave:()=>Z(false),onMouseMove:ae,className:`--slider --${t||bo.Default} ${c?"--knob-hover":""} flex rel ${h}`.trim(),style:{...C},children:[jsxRuntime.jsx(p,{ref:N,className:"--slider-track abs fill"}),f&&jsxRuntime.jsx(p,{ref:I,className:"--slider-ghost abs fill"}),jsxRuntime.jsx(p,{className:"--slider-track-filled abs fill",style:{width:"calc(var(--value) * 1%)"}}),jsxRuntime.jsx(p,{ref:b,className:"--slider-knob --tooltip-knob abs"}),jsxRuntime.jsx(fe,{ref:v,onInput:K,className:"abs fill",tabIndex:0,type:t||bo.Default,defaultValue:g||0,step:T,max:P,min:S})]});if(i===true){let te=u?u(n):d?n.toFixed(2):n;return jsxRuntime.jsx(ar,{ref:M,show:R,position:xt.Top,margin:15,anchorName:"--tooltip-knob",title:jsxRuntime.jsx(ce,{ref:L,children:te}),children:G()})}return G()};Ss.displayName="Zuz.Slider";var it=Ss;var Cs=react.forwardRef((e,r)=>{let{src:t,shape:n,size:o,...s}=e,{style:a,className:l,rest:f}=E(s),{canvasRef:c,crop:i,setScale:d,handleMouseDown:u,handleMouseUp:m,handleMouseMove:h}=hooks.useImageCropper(t,o||200,n||hooks.CropShape.Circle);return react.useImperativeHandle(r,()=>({getCropped(){return i()},setScale(C){d(C);}})),jsxRuntime.jsxs(p,{as:`--cropper --${n||hooks.CropShape.Circle} ${l}`,style:a,...f,children:[jsxRuntime.jsx("canvas",{ref:c,width:o||200,height:o||200,onMouseDown:u,onMouseUp:m,onMouseLeave:m,onMouseMove:h}),jsxRuntime.jsx(p,{as:"--cropper-slider",children:jsxRuntime.jsx(it,{onChange:C=>d(C),min:0,max:1,step:.01,value:1})})]})});Cs.displayName="Zuz.Cropper";var qm=Cs;var Ym=(t=>(t.Circle="circle",t.Square="square",t))(Ym||{});var Ps=react.forwardRef((e,r)=>{let{items:t,maxItems:n}=e,o=react.useMemo(()=>{let l=typeof t=="string",f=l?[]:t;return l&&t.split(",").forEach(c=>{f.push({label:c});}),f},[t]),a=react.useMemo(()=>n&&n>0&&o.length>n-1,[o,n])?[...o.slice(0,2),{ID:".",label:"...",icon:"ellipsis",action:()=>{}},...o.slice(-n)]:o;return jsxRuntime.jsx(et,{ref:r,className:"--crumb flex aic",direction:"rows",seperator:jsxRuntime.jsx(p,{as:"--crumb-chevron",children:O.chevronRightOutline}),items:a.map((l,f,c)=>l.ID=="."?jsxRuntime.jsx(p,{as:"flex aic gap:3",children:Array(3).fill(null).map(()=>jsxRuntime.jsx(p,{as:"w:4 h:4 bg:$text r:10"},`--crumb-placeholder-${f}`))}):jsxRuntime.jsxs(F,{onClick:()=>l.action?.(),className:"--crumb-item",disabled:!c[f+1],children:[l.icon&&jsxRuntime.jsx(J,{as:"--crumb-icon",name:l.icon}),jsxRuntime.jsx(_,{as:"--crumb-label",children:l.label})]},`${l.label.replace(/\s+/g,"-").toLowerCase()}-${f}`))})});Ps.displayName="Zuz.Crumb";var Qm=Ps;var Ns=react.forwardRef((e,r)=>{let{icon:t,defaultValue:n,value:o,size:s,variant:a,numeric:l,type:f,onConfirm:c,...i}=e,[d,u]=react.useState(false),[m,h]=react.useState(n||null),{style:C,className:x,rest:T}=E(i),S=react.useRef(null),P=react.useRef(null),{reposition:g}=Pt(P,{direction:he.Bottom,offset:2}),v=b=>{l&&(b.currentTarget.value=b.currentTarget.value.replace(/[^0-9.]/g,"").replace(/(\..*?)\..*/g,"$1"));};react.useEffect(()=>{let b=I=>{let D=I.target,N=S.current?.contains(D),A=P.current?.contains(D);!N&&!A&&u(false);};return d&&document.addEventListener("mousedown",b),()=>{document.removeEventListener("mousedown",b);}},[d]),react.useEffect(()=>{let b=I=>{I.key==="Escape"&&d&&(u(false),S.current?.focus());};return document.addEventListener("keydown",b),()=>document.removeEventListener("keydown",b)},[d]);let y=()=>{u(true);};return react.useEffect(()=>{d&&g();},[d,g]),jsxRuntime.jsx(jsxRuntime.Fragment,{children:jsxRuntime.jsxs(p,{as:`--date-picker ${a?`--${a}`:""} rel flex aic ${x}`,"data-value":m?m.toISOString():"",children:[t?typeof t=="string"?jsxRuntime.jsx(J,{as:"mr:10 c:#666",name:t}):t:jsxRuntime.jsx(ce,{as:"--date-picker-icon flex aic jcc",children:O.calendar}),jsxRuntime.jsx("input",{ref:S,value:m?dateFns.format(m,"EEE, MMM d YYY hh:mm a"):o||"",className:`--input ${a?`--${a}`:""} flex`.trim(),style:C,onFocus:y,onInput:v,autoComplete:"new-password",onKeyDown:b=>{b.key=="Enter"&&c?.(b.currentTarget.value);},...T}),jsxRuntime.jsx(p,{"aria-hidden":!d,ref:P,fx:{from:{y:5,opacity:0},to:{y:0,opacity:1},when:d,duration:.05},as:`--date-picker-chooser flex aic ${a?`--${a}`:""}`,children:jsxRuntime.jsx(Qo,{defaultValue:m,onChange:b=>{h(b),u(false);}})})]})})});Ns.displayName="Zuz.DatePicker";var op=Ns;var Es=react.forwardRef((e,r)=>{let{icon:t,variant:n,position:o}=e;return jsxRuntime.jsx(F,{className:`--fab fixed --${n||U.Large} --${o||"bottomright"}`,children:t||O.plus})});Es.displayName="Zuz.Fab";var ap=Es;var Bs=e=>{let{names:r,strength:t}=e,n={[At.Gooey]:o=>jsxRuntime.jsxs("filter",{id:"gooey",children:[jsxRuntime.jsx("feGaussianBlur",{in:"SourceGraphic",stdDeviation:o||10,result:"blur"}),jsxRuntime.jsx("feColorMatrix",{in:"blur",mode:"matrix",values:"1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 18 -7",result:"goo"}),jsxRuntime.jsx("feBlend",{in:"SourceGraphic",in2:"goo"})]},`filter-${At.Gooey}`)};return react.useEffect(()=>{},[r]),jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",version:"1.1",children:jsxRuntime.jsx("defs",{children:(r||[At.Gooey]).map(o=>n[o](t))})})};Bs.displayName="Zuz.Filters";var cp=Bs;var ks=({cols:e,gap:r,ais:t,aic:n,aie:o,jcs:s,jcc:a,jce:l,className:f="",style:c,...i})=>{let d=["--flex",e?"--cols":"",t?"--ais":"",n?"--aic":"",o?"--aie":"",s?"--jcs":"",a?"--jcc":"",l?"--jce":"",f].filter(Boolean).join(" "),u={...c,gap:typeof r=="number"?`${r}px`:r};return jsxRuntime.jsx(p,{...i,className:d,style:u})};ks.displayName="Zuz.FlexBox";var Ve=ks;var We=null,Pe=null,Ms=react.forwardRef((e,r)=>{let{title:t,message:n,transition:o,curve:s,speed:a,type:l,actionPosition:f,spinner:c,loadingMessage:i,onShow:d,onHide:u,...m}=e,{className:h,style:C,rest:x}=E(m),[T,S]=react.useState(t||""),[P,g]=react.useState(n||""),[v,y]=react.useState(null),[b,I]=react.useState(l||Ne.Default),D=react.useMemo(()=>core.uuid(12),[]),[N,A]=react.useState(false),L=react.useRef(null),M=react.useRef(null),[$,K]=react.useState(false),[R,B]=react.useState(true),q=react.useRef(null),X=P;react.useImperativeHandle(r,()=>({setLoading(z){K(z);},showDialog(z,W,Z,re){We&&(clearTimeout(We),Pe&&clearTimeout(Pe),L.current.classList.remove("--wobble"),setTimeout(()=>L.current.classList.add("--wobble"),50),Pe=setTimeout(()=>{L.current.classList.remove("--wobble"),Pe=null;},500)),I(Ne.Dialog),W&&g(W),z&&S(z),Z&&y(Z.reduce((Q,se)=>(Q.push({...se,key:se.key||core.uuid(12)}),Q),[])),A(true),setTimeout(()=>re?re():()=>{},1e3);},dialog(z,W,Z,re){We&&(clearTimeout(We),Pe&&clearTimeout(Pe),L.current.classList.remove("--wobble"),setTimeout(()=>L.current.classList.add("--wobble"),50),Pe=setTimeout(()=>{L.current.classList.remove("--wobble"),Pe=null;},500)),I(Ne.Dialog),g(W),S(z),Z&&y(Z.reduce((Q,se)=>(Q.push({...se,key:se.key||core.uuid(12)}),Q),[])),A(true),setTimeout(()=>re?re():()=>{},1e3);},error(z,W){this.show(z,W,Ne.Error);},warn(z,W){this.show(z,W,Ne.Warn);},success(z,W){this.show(z,W,Ne.Success);},show(z,W,Z){We&&(clearTimeout(We),Pe&&clearTimeout(Pe),M.current=L.current.style.transform,L.current.style.transform="",L.current.classList.remove("--wobble"),setTimeout(()=>{L.current.classList.add("--wobble"),L.current.style.transform=`${M.current} scale(.9)`.trim();},50),Pe=setTimeout(()=>{L.current.classList.remove("--wobble"),L.current.style.transform=M.current||"",Pe=null;},500)),We=setTimeout(()=>{A(false),We=null,Pe=null;},(W||4)*1e3),I(Z||Ne.Default),g(z),A(true),d?.();},hide(){A(false),u?.();}}));let H=react.useMemo(()=>{let z={when:N,duration:a||.3,delay:.1};if(b==Ne.Dialog){if(o){let{from:W,to:Z}=vt(o,20);return {from:W,to:Z,curve:s||ee.EaseInOut,...z}}return {from:{scale:0,x:"-50%",y:"-50%",opacity:0},to:{scale:1,x:"-50%",y:"-50%",opacity:1},curve:ee.Spring,...z}}else return {from:{scale:0,x:"-50%",y:"-10vh",opacity:0},to:{scale:1,x:"-50%",y:0,opacity:1},curve:ee.Spring,...z}},[N,b]);return react.useEffect(()=>{q.current&&clearTimeout(q.current),N?B(true):q.current=setTimeout(()=>B(false),1e3);},[N]),b==Ne.Dialog?jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(Ye,{when:N}),jsxRuntime.jsxs(p,{className:`--sheet --sheet-${b.toLowerCase()} ${N?"is-visible":""} ${h} fixed`.trim(),style:C,fx:H,...x,ref:L,children:[jsxRuntime.jsx(Le,{when:$,spinner:c,message:i}),jsxRuntime.jsxs(p,{className:"--head flex aic rel",children:[jsxRuntime.jsx(p,{className:`--${T?"title":"dot"} flex aic rel`,children:T||""}),jsxRuntime.jsx(F,{onClick:z=>A(false),className:"--closer abs",children:"\xD7"})]}),jsxRuntime.jsx(p,{className:`--body flex aic rel ${v?"":"--no-action"}`.trim(),children:R?X:null}),v&&jsxRuntime.jsx(p,{className:`--footer flex aic rel ${f?f==xo.Center?"jcc":"":"jce"}`.trim(),children:v.map((z,W)=>jsxRuntime.jsx(F,{onClick:Z=>z.handler?z.handler():z.onClick?z.onClick():console.log("onClick Handler missing"),className:"--action",children:z.label},`sheet-${D}-action-${z.key}`))})]})]}):jsxRuntime.jsx(p,{className:`--sheet --sheet-${b.toLowerCase()} ${h} abs`.trim(),style:C,...x,fx:H,ref:L,children:N?P:null})}),Os=e=>typeof e=="object"&&e!=null&&"setLoading"in e&&"success"in e&&"error"in e;Ms.displayName="Zuz.Sheet";var gp=Ms;var Cp=e=>{let r={};for(let t in e){let n=t.split(/[\[\]]+/).filter(Boolean);n.reduce((o,s,a)=>{if(a===n.length-1)o[s]=e[t];else {let l=!isNaN(Number(n[a+1]));o[s]=o[s]||(l?[]:{});}return o[s]},r);}return r},Vs=({ref:e,...r})=>{let {schema:t,name:n,cover:o,spinner:s,errors:a,action:l,children:f,withData:c,beforeSubmit:i,onSubmit:d,onError:u,onSuccess:m,resetOnSuccess:h,...C}=r,{className:x,style:T,rest:S}=E(C),[P,g]=react.useState(false),v=react.useRef(null),y=Fo(),b=qo();Uo();let D=react.useRef(null),N=react.useCallback(H=>v.current?v.current.querySelectorAll(H):[],[v.current]),A=H=>({name:H.name||H.getAttribute("name")||H.getAttribute("data-name"),required:H.required?true:H.getAttribute("data-required")?H.getAttribute("data-required")=="true":false,with:H.with||H.getAttribute("with")}),L=H=>{let z=[];return H.querySelectorAll(".--input").forEach(W=>{z.push(W.value);}),z.join("")},M=H=>H.classList.contains("--otp")?L(H):H.classList.contains("--select")?H.querySelector("button.--selected")?.dataset.value:H.classList.contains("--checkbox")||H.getAttribute("type")==="checkbox"?H.checked:H.value,$=react.useCallback(H=>{let{name:z,required:W,with:Z}=A(H),re=M(H);if(t&&t[z]&&b?.getSnapshot()){let Q=t[z](re,b.getSnapshot().values);if(Q===false||typeof Q=="string")return typeof Q=="string"&&b?.setFieldError(z,Q),false}if(W&&(H.type==="checkbox"&&!H.checked||H.classList.contains("--select")&&(re==="-1"||!re)||!re||re===""))return false;if(Z)switch((Z.includes("@")?Z.split("@")[0]=="match"?Xe.MatchField:Z.split("@")[0]:Z).toUpperCase()){case Xe.IPV4:return core._(re).isIPv4();case Xe.IPV6:return core._(re).isIPv6();case Xe.Email:return core._(re).isEmail();case Xe.Uri:try{return new URL(re),!0}catch{return false}case Xe.MatchField:let[se,me,ge]=Z.split("@"),ae=document.querySelector(`[name=${me.trim()}]`);if(!ae)return false;switch(ge||"direct-match"){case "if-not-empty":if(ae&&!core._(ae.value).isEmpty()&&ae.value!=H.value)return false;break;case "direct-match":if(ae&&ae.classList.contains("--otp")&&H.classList.contains("--otp")&&L(ae)!=L(H))return false;if(ae&&ae.value!=H.value)return false;break}break}return true},[t,b]),K=react.useCallback(()=>{let H={},z={...b?.getSnapshot().values||{}},W=null,Z=null;if(N("[name]").forEach(Q=>{let{name:se,required:me,with:ge}=A(Q),ae=me||ge?$(Q):true,le=M(Q);H[se]={valid:ae,value:le},z[se]=le,b?.setFieldError(se,ae?null:a?.[se]||"Invalid"),ae?Q.classList.remove("--with-error"):(Q.classList.add("--with-error"),W||(W=Q),Z=a?.[se]);}),W){let Q=W;if(Q.classList.contains("--otp"))for(let se of Array.from(Q.querySelectorAll(".--input"))){let me=se;if(me.value==""){me.focus();break}}else Q.focus();}let re=Cp(z);return {error:W!=null,errorMsg:Z||"Fix errors to continue...",data:H,payload:re}},[v.current,b]),R=react.useCallback((H={})=>{let{error:z,errorMsg:W,payload:Z,data:re}=K();if(z){y.error(W);return}l?react.startTransition(async()=>{g(true),core.withPost(l,{...c,...Z,...H}).then(Q=>{g(false),h&&b?.reset(),m?.(Q,{...c,...Z,...H}),m||y.success(Q.message||"Redirecting...");}).catch(Q=>{g(false),u?u(Q):y.error(Q.message);});}):d?.(Z,re);},[K,l,c,m,u,h,d]),B=react.useCallback(()=>{let H=N("[type=submit]");!H||H.length==0?console.warn("You should add at least 1 button with type=`SUBMIT`"):H.forEach(z=>{z.addEventListener("click",R);});},[v.current]),q=react.useMemo(()=>react$1.addPropsToChildren(f,H=>H.props.type=="submit",H=>({ref:D})),[f]),X=react.useRef(R);return react.useImperativeHandle(e,()=>({setLoading:H=>g(H),submit:H=>X.current(H),init:B,hideError:()=>y.clearAll()}),[R,B]),react.useEffect(B,[]),react.useEffect(()=>{X.current=R;},[R]),react.useEffect(()=>{let H=N("[type=submit]"),z=Array.from(H).map(W=>{let Z=W;return Z.addEventListener("click",R),()=>Z.removeEventListener("click",R)});return ()=>z.forEach(W=>W())},[R,N]),jsxRuntime.jsxs(p,{ref:v,style:T,className:`--form flex rel ${x}`,children:[!Os(o)&&jsxRuntime.jsx(Le,{when:P,spinner:s,...o}),q]})};Vs.displayName="Zuz.FormInternal";var Ds=e=>jsxRuntime.jsx(On,{initialValues:e.withData,children:jsxRuntime.jsx(Vs,{...e})});Ds.displayName="Zuz.Form";var Tp=Ds;var Hs=e=>{let {ref:r,cols:t,rows:n,gap:o,gapX:s,gapY:a,align:l,justify:f,inline:c,flow:i,autoCols:d,autoRows:u,template:m,...h}=e;react.useRef(null);let {className:x,style:T,rest:S}=E(h),P=v=>typeof v=="number"?`repeat(${v}, 1fr)`:v,g={display:c?"inline-grid":"grid",gridTemplateColumns:P(t),gridTemplateRows:P(n),gap:o,columnGap:s,rowGap:a,alignItems:l,justifyContent:f==="between"?"space-between":f==="around"?"space-around":f,gridAutoFlow:i,gridAutoColumns:d,gridAutoRows:u,gridTemplateAreas:m,...T};return jsxRuntime.jsx(p,{ref:r,as:`--grid ${x}`.trim(),style:g,...S})};Hs.displayName="Zuz.Grid";var Ip=Hs;var As=e=>typeof e=="string"&&e.includes("+"),$s={command:"\u2318",shift:"\u21E7",ctrl:"\u2303",option:"\u2325",enter:"\u21B5",delete:"\u232B",escape:"\u238B",tab:"\u21E5",capslock:"\u21EA",up:"\u2191",right:"\u2192",down:"\u2193",left:"\u2190",pageup:"\u21DE",pagedown:"\u21DF",home:"\u2196",end:"\u2198",help:"?",space:"\u2423",fn:"Fn",win:"\u2318",alt:"\u2325"},zs={command:"Command",shift:"Shift",ctrl:"Control",option:"Option",enter:"Enter",delete:"Delete",escape:"Escape",tab:"Tab",capslock:"Caps Lock",up:"Up",right:"Right",down:"Down",left:"Left",pageup:"Page Up",pagedown:"Page Down",home:"Home",end:"End",help:"Help",space:"Space",fn:"Fn",win:"Win",alt:"Alt"};var _s=react.forwardRef(({children:e,keys:r,as:t,className:n,variant:o},s)=>{let{variant:a}=j(true),l=react.useMemo(()=>{if(As(r)){let f=null;return {keys:String(r).split("+").reduce((i,d,u,m)=>(m[u+1]?i.push(d):f=d.toUpperCase(),i),[]),children:f}}return {keys:r,children:String(e).toUpperCase()}},[r]);return jsxRuntime.jsxs(p,{as:`--keyboard-keys --${o||a||U.Small} flex aic ${t} ${n}`.trim(),children:[(Array.isArray(l.keys)?l.keys:[l.keys]).map(f=>jsxRuntime.jsx("abbr",{title:zs[f],children:$s[f]},f)),jsxRuntime.jsx(ce,{children:l?.children??e})]})});_s.displayName="Zuz.KeyboardKeys";var hr=_s;var Ws=react.createContext(null),mt=()=>{let e=react.useContext(Ws);if(!e)throw new Error("MediaPlayer sub-components must be used within <MediaPlayer />");return e},Vp=({ref:e,icons:r,children:t,...n})=>{let{playlist:o=[],mode:s="audio",defaultArtist:a="Artist",defaultTitle:l="No Track",defaultCover:f,onTrackChange:c,...i}=n,{className:d,style:u,rest:m}=E(i),h=hooks.useMediaPlayer(o,o[0]??void 0),C=react.useMemo(()=>({play:O.play,pause:O.pause,prev:O.prev,next:O.next,volumeHigh:O.volumeHigh,volumeMute:O.volumeMute,...r}),[r]),x=react.useMemo(()=>({...h,mode:s,icons:C}),[h,C]);return jsxRuntime.jsx(Ws.Provider,{value:x,children:jsxRuntime.jsx(p,{className:`--zuz-media-player ${d}`,style:u,children:t})})},Gs=Vp;var Us=e=>{if(!e||isNaN(e))return "0:00";let r=Math.floor(e/60),t=Math.floor(e%60);return `${r}:${t.toString().padStart(2,"0")}`},so=e=>typeof e=="string"?jsxRuntime.jsx(J,{name:e}):e,qs=()=>{let{mediaRef:e,state:r,controls:t,mode:n}=mt();return jsxRuntime.jsxs(p,{as:`--mediaplayer-stage rel --mode-${n}`,children:[n==="video"?jsxRuntime.jsx("video",{ref:e,className:"fill",onClick:t.togglePlay}):jsxRuntime.jsx("audio",{ref:e}),r.isLoading&&jsxRuntime.jsx(p,{as:"abs fill aic jcc --mediaplayer-spinner",children:jsxRuntime.jsx(we,{})})]})},Xs=()=>{let{state:e,defaultArtist:r,defaultTitle:t,defaultCover:n}=mt();return jsxRuntime.jsxs(p,{as:"--track-info flex aic",children:[jsxRuntime.jsx(tt,{src:e.currentItem?.cover||n||"",as:"--track-cover"}),jsxRuntime.jsxs(p,{as:"flex cols",children:[jsxRuntime.jsx(p,{as:"--track-title",children:e.currentItem?.title||t||"Choose Track"}),jsxRuntime.jsx(p,{as:"--track-artist",children:e.currentItem?.artist||r||"..."})]})]})},Ys=()=>{let{state:e,controls:r,icons:t}=mt();return jsxRuntime.jsxs(p,{as:"--mediaplayer-controls flex aic",children:[jsxRuntime.jsx(F,{onClick:r.prev,as:"--prev",children:so(t?.prev??O.prev)}),jsxRuntime.jsx(F,{onClick:r.togglePlay,as:"--play-pause",children:so(e.isPlaying?t?.pause??O.pause:t?.play??O.play)}),jsxRuntime.jsx(F,{onClick:r.next,as:"--next",children:so(t?.next??O.next)})]})},js=()=>{let{state:e,controls:r,mediaRef:t}=mt(),n=e.progress*(e.duration||0);return jsxRuntime.jsxs(p,{as:"--track-progress flex aic",children:[jsxRuntime.jsx(p,{as:"--track-current-duration",children:Us(n)}),jsxRuntime.jsx(it,{value:e.progress,onClick:o=>{let s=o.currentTarget.getBoundingClientRect(),a=(o.clientX-s.left)/s.width;r.seek(a);}}),jsxRuntime.jsx(p,{as:"--track-total-duration",children:Us(e.duration)})]})},Qs=()=>{let{state:e,controls:r,icons:t}=mt();return jsxRuntime.jsxs(p,{as:"--volume-control flex aic gap:8 w:120",children:[jsxRuntime.jsx(F,{onClick:()=>r.setIsMuted(),children:so(e.isMuted?t?.volumeMute??O.volumeMute:t?.volumeHigh??O.volumeHigh)}),jsxRuntime.jsx(it,{value:e.volume,className:"h:3 flex:1",onClick:n=>{let o=n.currentTarget.getBoundingClientRect();r.setVolume((n.clientX-o.left)/o.width);}})]})};var Dp=Object.assign(Gs,{Stage:qs,TrackInfo:Xs,Controls:Ys,Progress:js,Volume:Qs}),Hp=Dp;var ea=react.forwardRef((e,r)=>{let t=hooks.useNetworkStatus(),{onlineMessage:n,offlineMessage:o,variant:s}=e;return jsxRuntime.jsxs(p,{fx:{from:{x:"-50%",y:200,opacity:0},to:{x:"-50%",y:0,opacity:1},when:t==false,curve:ee.Spring,duration:.5,delay:2},className:`--network-manager --${t==true?"online":"offline"} --${s||U.Small} fixed flex`,children:[jsxRuntime.jsx(p,{className:"--ico",children:t?O[Ie.Success]:O[Ie.Error]}),jsxRuntime.jsx(_,{as:"--message",children:t?n||"internet connection restored :)":o||"no internet connection"})]})});ea.displayName="Zuz.NetWorkManager";var zp=ea;var oa=react.forwardRef((e,r)=>{let{strenthMeter:t,onChange:n,...o}=e;"type"in o&&delete o.type;let{style:s,className:a,rest:l}=E(o),[f,c]=react.useState(false),[i,d]=react.useState(""),u=react.useMemo(()=>core.checkPasswordStrength(i),[i]),m=hooks.useDebounce(h=>{t&&d(h.target.value),n&&n(h);},100);return react.useEffect(()=>{},[]),jsxRuntime.jsxs(p,{as:"w:100% flex cols",children:[jsxRuntime.jsxs(p,{style:s,className:"--password flex aic rel",children:[jsxRuntime.jsx(fe,{ref:r,type:f?"text":"password",className:a,onChange:m,...l}),jsxRuntime.jsx(F,{tabIndex:-1,onClick:()=>c(h=>!h),className:"--toggle flex aic jcc abs",children:f?O.eye:O.eyeSlash})]}),t&&jsxRuntime.jsxs(p,{as:`flex aic --password-meter --pb-score-${u.score}`,style:s,children:[jsxRuntime.jsxs(p,{as:"--password-bars flex aic",children:[jsxRuntime.jsx(p,{as:`--pbar ${u.score>=1?"--pb-on":""}`.trim()}),jsxRuntime.jsx(p,{as:`--pbar ${u.score>=2?"--pb-on":""}`.trim()}),jsxRuntime.jsx(p,{as:`--pbar ${u.score>=3?"--pb-on":""}`.trim()}),jsxRuntime.jsx(p,{as:`--pbar ${u.score>=4?"--pb-on":""}`.trim()}),jsxRuntime.jsx(p,{as:`--pbar ${u.score>=5?"--pb-on":""}`.trim()})]}),jsxRuntime.jsx(_,{as:"--password-meter-label","aria-hidden":true,children:u.result})]})]})});oa.displayName="Zuz.Password";var Up=oa;var na=react.forwardRef((e,r)=>{let{size:t,length:n,mask:o,...s}=e,a=react.useRef([]),l="pinput",f=false,c={};"with"in s&&(c={with:s.with},delete s.with),"type"in s&&delete s.type,"name"in s&&(l=s.name,delete s.name),"required"in s&&(f=true,delete s.required);let{style:i}=E(s),d=m=>{let h=m.currentTarget,C=a.current[parseInt(h.dataset.index)+1],x=a.current[parseInt(h.dataset.index)-1];h.value.length===1&&C?C.focus():h.value.length===0&&x&&x.focus();},{variant:u}=j(true);return react.useEffect(()=>{a.current=a.current.slice(0,t||n);},[t||n]),jsxRuntime.jsx(p,{name:l,style:i,className:`--otp --${s.variant??u??U.Medium} flex aic rel`,"data-required":f,"data-size":t||n||4,...c,children:Array(t||n||4).fill(1).map((m,h)=>jsxRuntime.jsx(fe,{autoComplete:"new-password","data-index":h,ref:C=>{a.current[h]=C;},numeric:true,onChange:d,maxLength:1,placeholder:o?"\xB7":"0",type:o?"password":"text",...s},`pin-${h}`))})});na.displayName="Zuz.PinInput";var jp=na;var sa=react.forwardRef((e,r)=>{let{children:t,className:n,name:o,required:s,type:a,value:l,variant:f,checked:c,onSwitch:i,...d}=e,[u,m]=react.useState(c||false),{variant:h}=j(true),C=react.useRef(null);return jsxRuntime.jsxs(Et,{className:`${n} --${(a||vo.Default).toLowerCase()} --radio${!a||a==vo.Default?"":"card"} --${f||h||U.Small} flex aic rel`.trim(),...d,children:[jsxRuntime.jsx(fe,{ref:C,defaultChecked:u,value:l||"rd",type:"radio",className:"abs",name:o,required:s||false,onChange:x=>{i&&i(x.target.checked,l||"cb"),m(x.target.checked);}}),jsxRuntime.jsx(p,{className:"--dot rel",children:jsxRuntime.jsx(p,{className:"--rod abs abc"})}),jsxRuntime.jsx(p,{className:"--value",children:t})]})});sa.displayName="Zuz.Radio";var tu=sa;var aa=react.forwardRef((e,r)=>{let{fx:t,withStyle:n,as:o,reverse:s=false,searchIcon:a=O.search,hideSearchIcon:l=false,clearIcon:f=O.close,hideClearIcon:c=false,onChange:i,onClear:d,...u}=e,{style:m,className:h}=E({as:e.as}),[C,x]=react.useState(""),{variant:T}=j(true),S=react.useRef(null);"type"in e&&delete e.type;let P=v=>{x(v.target.value),i?.(v.target.value);},g=v=>{C.trim()!==""&&(x(""),i?.(""),S.current&&(S.current.value="",e.onConfirm?.("")));};return react.useImperativeHandle(r,()=>({focus:()=>S.current?.focus(),value:()=>S.current?.value})),react.useEffect(()=>{},[]),jsxRuntime.jsxs(p,{style:m,className:`--search --no-shrink ${s?"--search-rev":""} --${e.variant||T||U.Medium} flex aic ${typeof e.as=="string"&&e.as.includes("abs")?"":"rel"} ${h}`.trim(),children:[jsxRuntime.jsx(fe,{ref:S,onChange:P,...u}),e.shortcut&&jsxRuntime.jsx(hr,{keys:e.shortcut,as:"abs"}),jsxRuntime.jsx(F,{tabIndex:-1,onClick:v=>g(),className:"--send flex aic jcc",variant:e.variant||U.Medium,children:C!==""?!c&&(typeof f=="string"?jsxRuntime.jsx(J,{name:f,as:"--search-action"}):f):!l&&(typeof a=="string"?jsxRuntime.jsx(J,{name:a,as:"--search-action"}):a)})]})});aa.displayName="Zuz.Search";var yr=aa;var cu=({label:e,icon:r})=>jsxRuntime.jsxs(p,{as:"--select-options-head --no-shrink --disabled".trim(),"aria-hidden":"true",children:[r&&jsxRuntime.jsx(J,{name:r}),jsxRuntime.jsx(_,{as:"--select-group-label",children:e})]}),la=cu;var ma=({checkIcon:e,selected:r,updateValue:t,o:n})=>{let o=e?typeof e=="string"?jsxRuntime.jsx(J,{name:"checkIcon"}):e:O.check,s=n.disabled===true;return jsxRuntime.jsxs(F,{onClick:a=>{s||(a.stopPropagation(),t(n));},disabled:s,as:`--select-option-item --no-shrink ${r?"--selected":""} ${s?"--disabled":""} rel`.trim(),children:[jsxRuntime.jsxs(Ve,{as:"--option-item-meta --aic",children:[n.icon&&jsxRuntime.jsx(J,{name:n.icon,as:`--select-option-icon --icon-${n.value}`,color:n.iconColor}),jsxRuntime.jsx(_,{suppressHydrationWarning:true,children:typeof n=="string"?n:n.label})]}),r&&jsxRuntime.jsx(Ve,{aic:true,jcc:true,as:"--select-option-check --abs",children:o})]})};ma.displayName="Option";var pa=ma;var ua=(({ref:e,...r})=>{let{selected:t,options:n,label:o,name:s,variant:a,search:l,searchPlaceholder:f,maxHeight:c,arrowDownIcon:i=O.arrowDown,arrowUpIcon:d=O.arrowUp,expanded:u,multiple:m,tokenizer:h,wrapTokens:C,disabled:x,checkIcon:T,closeIcon:S,editable:P,editablePlaceholder:g,onChange:v,required:y,with:b,...I}=r,D=Fe(),N=s&&D.values&&D.setFieldValue,A=N?D.errors?.[s]:null,L=N?D.values?.[s]:void 0,M=P===true&&m!==true&&h!==true,$=k=>typeof k=="string"||typeof k=="number",K=k=>typeof k=="object"&&k!==null&&!Array.isArray(k)&&"value"in k&&"label"in k,R=k=>n.find(oe=>String(oe.value)===String(k)),B=k=>{if(k==null)return null;if(M&&k==="")return "";if(m||h)return (Array.isArray(k)?k:[k]).map(ve=>$(ve)?R(ve):ve).filter(ve=>K(ve));if($(k)){let oe=R(k);return oe||(M?String(k):null)}return K(k)?k:null},q=()=>{if(t!==void 0)return B(t);let k=n.find(oe=>String(oe.value)==="-1");return k||(M?"":null)},X=k=>Array.isArray(k)?k.map(oe=>oe.value):K(k)?k.value:k,[H,z]=react.useState(()=>q()),[W,Z]=react.useState(false),[re,Q]=react.useState(null),se=react.useRef(null),me=react.useRef(null),ge=react.useRef(null),ae=react.useId(),le=react.useMemo(()=>s||ae,[s,ae]),{reposition:G}=Pt(ge,{direction:xt.Bottom,offset:2}),{variant:te}=j(true),ie=S?typeof S=="string"?jsxRuntime.jsx(J,{name:S}):S:O.close,{className:ue,style:He,rest:Re}=E(I,void 0),{onClick:be,...Ae}=Re||{},ne=react.useMemo(()=>L!==void 0?B(L):H,[L,H,n,M,m,h]),qe=react.useMemo(()=>{if(!(!ne||Array.isArray(ne)||!K(ne)))return ne},[ne]),Rr=react.useMemo(()=>M?K(ne)?String(ne.value??""):$(ne)?String(ne):"":"",[M,ne]),za=k=>Array.isArray(ne)?ne.some(oe=>oe.value===k.value):K(ne)?ne.value===k.value:M&&$(ne)?String(ne)===String(k.value):false,yt=k=>{if(N){D.setFieldValue?.(s,X(k));return}z(k);},Dt=k=>{v?.(k);},Fa=k=>{if(!(x||k.disabled)){if(m||h){let oe=Array.isArray(ne)?ne:[],ke=oe.find(ho=>ho.value===k.value)?oe.filter(ho=>ho.value!==k.value):[...oe,k];yt(ke),Dt(ke);return}yt(k),Z(false),Dt(k);}},_a=k=>{let oe=k.currentTarget.value,ke=(oe===""?null:R(oe))??oe;yt(ke),Dt(ke);},Ka=k=>{k.key==="Enter"&&(k.preventDefault(),M&&Z(false));},Za=(k,oe)=>{if(k.stopPropagation(),x)return;let ve=ne.filter(ke=>ke.value!==oe.value);yt(ve),Z(false),Dt(ve);},Wa=k=>{let oe=k.currentTarget,ve=oe.scrollTop===0&&k.deltaY<0,ke=oe.scrollHeight-oe.scrollTop===oe.clientHeight&&k.deltaY>0;!ve&&!ke||k.preventDefault(),k.stopPropagation();};react.useImperativeHandle(e,()=>({setSelected:k=>{yt(B(k));},getValue:()=>ne??null}),[ne,n,M,m,h,N,s]),react.useEffect(()=>{N||t===void 0||z(B(t));},[t,N,n,M,m,h]),react.useEffect(()=>{if(!W)return;let k=()=>{G();};return window.addEventListener("scroll",k,true),window.addEventListener("resize",G),()=>{window.removeEventListener("scroll",k,true),window.removeEventListener("resize",G);}},[W,G]),react.useEffect(()=>{if(!W){me.current&&(me.current.value=""),Q(null);return}me.current?.focus(),G();let k=ve=>{se.current&&!se.current.contains(ve.target)&&Z(false);},oe=setTimeout(()=>{document.addEventListener("click",k);},0);return ()=>{clearTimeout(oe),document.removeEventListener("click",k);}},[W,G]),react.useEffect(()=>()=>{N&&D.deleteFieldValue?.(s);},[D,N,s]);let Ga=hooks.useDebounce(k=>Q(k===""?null:k),300);return jsxRuntime.jsxs(p,{ref:se,"data-required":y?"true":void 0,with:b,className:[`--select ${u==true?"--expanded":""}`,`--${a||te}`,`${s?`--${s}`:""}`,`${A?"--has-error":""}`,`${x?"--disabled":""} rel`].join(" ").trim(),name:le,children:[M?jsxRuntime.jsxs(p,{"data-value":qe?.value??(Rr||"-1"),className:`--select-display --selected --editable flex aic rel ${ue}`.trim(),style:He,onClick:k=>k.stopPropagation(),...Ae,children:[qe?.icon&&jsxRuntime.jsx(J,{as:"--selected-icon",name:qe.icon}),jsxRuntime.jsx(Ve,{aic:true,as:"--label-wrapper",children:jsxRuntime.jsx("input",{"aria-expanded":W,className:"--select-input",disabled:x,onChange:_a,onClick:k=>{k.stopPropagation(),x||Z(true);},onKeyDown:Ka,placeholder:g||o||"Choose",type:"text",value:Rr})}),jsxRuntime.jsx(F,{className:"--select-toggle rel flex aic jcc",disabled:x,onClick:k=>{k.stopPropagation(),x||Z(oe=>!oe);},tabIndex:-1,withLabel:false,children:W?typeof d=="string"?jsxRuntime.jsx(J,{name:d,as:"--search-action"}):d:typeof i=="string"?jsxRuntime.jsx(J,{name:i,as:"--search-action"}):i})]}):jsxRuntime.jsxs(F,{disabled:x,variant:a||te,"data-value":qe?.value??"-1",className:`--select-display --selected flex aic rel ${ue}`.trim(),withLabel:false,style:He,onClick:k=>{k.stopPropagation(),x||Z(oe=>!oe);},...Ae,children:[qe?.icon&&jsxRuntime.jsx(J,{as:"--selected-icon",name:qe.icon}),jsxRuntime.jsx(Ve,{aic:true,as:"--label-wrapper",children:h&&Array.isArray(ne)&&ne.length>0?jsxRuntime.jsxs(Ve,{as:`--tokens-wrap${C===true?" --wrap":""}`,children:[ne.map(k=>jsxRuntime.jsxs(Ve,{aic:true,as:"--token",children:[jsxRuntime.jsx(_,{as:"--token-label",children:k.label}),jsxRuntime.jsx(p,{as:"--token-remove",onClick:oe=>Za(oe,k),children:ie})]},k.value)),ne.length<n.length&&jsxRuntime.jsx(_,{as:"--label",children:o||"Choose"})]}):jsxRuntime.jsx(_,{as:"--label",children:Array.isArray(ne)?ne.length>0?`${ne.length} selected`:o||"Choose":qe?.label||o||"Choose"})}),jsxRuntime.jsx(p,{className:"--svg-arrow rel flex aic jcc",children:W?typeof d=="string"?jsxRuntime.jsx(J,{name:d,as:"--search-action"}):d:typeof i=="string"?jsxRuntime.jsx(J,{name:i,as:"--search-action"}):i})]}),jsxRuntime.jsxs(p,{id:le,className:"--options-list --allow-scroll -fx flex cols abs zIndex:var(--max-z-index)","aria-hidden":!W,onWheel:Wa,style:{maxHeight:c||"auto"},ref:ge,fx:{from:{y:5,opacity:0},to:{y:0,opacity:1},when:W,duration:.05},children:[l&&jsxRuntime.jsx(p,{as:"--select-search --no-shrink flex --sticky",children:jsxRuntime.jsx(yr,{ref:me,variant:U.Small,placeholder:f||"Search...",onChange:Ga})}),o&&jsxRuntime.jsx(la,{label:o}),n?.filter(k=>!re||k.label.toLowerCase().includes(re.toLowerCase()))?.map(k=>jsxRuntime.jsx(pa,{updateValue:Fa,checkIcon:T,selected:za(k),o:k},`option-${k.label.replace(/\s+/g,"-")}-${k.value}`))]})]})});ua.displayName="Zuz.Select";var du=ua;var fa=({ref:e,...r})=>jsxRuntime.jsx(Bt,{type:$e.Switch,...r,ref:e});fa.displayName="Zuz.Switch";var gu=fa;var ga=e=>{let{idx:r,id:t,as:n,weight:o,style:s,value:a,render:l,resize:f,sortBy:c,sortable:i,onSort:d}=e,[u,m]=react.useState(0),h=()=>{i&&(d?.(String(t),u==1?-1:1),m(C=>C==1?-1:1));};return jsxRuntime.jsxs(p,{style:{flex:o||1,...s},as:`--col flex aic ${n||""} ${i?"--sortable":""}`,onClick:h,children:[jsxRuntime.jsx(p,{as:"--colv",children:a}),r==-1&&i&&c==t&&jsxRuntime.jsx(p,{as:"--arrow flex aib",children:u==1?O.arrowUp:O.arrowDown})]})};ga.displayName="Zuz.Column";var po=ga;var ya=e=>{let{index:r,pubsub:t,schema:n,data:o,ids:s,styles:a,animate:l,sortBy:f,selectable:c,tableRef:i,loading:d,rowClassName:u,onSort:m,onRowClick:h,onSelect:C,onContextMenu:x}=e,T=hooks.useDelayed(),S=react.useMemo(()=>({transition:Y.SlideInBottom,curve:ee.EaseInOut,delay:.02*(r+1)}),[]),P=react.useRef(null),g=(y,b)=>{r==-1?t.emit(`ALL_ROWS_${y?"CHECKED":"UNCHECKED"}`,y):(C&&C(o,y),t.emit(`ROW_${y?"CHECKED":"UNCHECKED"}`,y,b));},v=(y,b,I)=>jsxRuntime.jsx(po,{idx:y,id:b,as:"--selector",pubsub:t,value:jsxRuntime.jsx(Bt,{value:I,ref:P,onSwitch:g,type:$e.Default})});return react.useEffect(()=>{let y=(N,A)=>{P.current?.setChecked(N,false);},b=(N,A)=>{let L=false;i?.current&&i.current.querySelectorAll(".--row").forEach(M=>{let $=M;if(!$.classList.contains("--row-head")){let K=$.querySelector(".--selector input[type=checkbox]");K&&K.checked&&!L&&(L=K.checked);}}),P.current.setChecked(L,false);},I=N=>{P.current?.setChecked(N,false),C&&C(o,N);},D=N=>{P.current?.setChecked(N,false),C&&C(o,N);};return r==-1?(t.on("ROW_CHECKED",y),t.on("ROW_UNCHECKED",b),()=>{t.off("ROW_CHECKED",y),t.off("ROW_UNCHECKED",b);}):(t.on("ALL_ROWS_CHECKED",I),t.on("ALL_ROWS_UNCHECKED",D),()=>{t.off("ALL_ROWS_CHECKED",I),t.off("ALL_ROWS_UNCHECKED",D);})},[]),jsxRuntime.jsxs(p,{onContextMenu:y=>x?x(y,o):null,onClick:y=>h?h(y,e.data):()=>{},...l?{fx:{...S,when:T}}:{},as:`--row flex aic ${h?"--row-clickable":""} ${r==-1?"--row-head":""} ${u||""}`,children:[r==-1&&n.map((y,b)=>{let{renderWhenHeader:I,render:D,value:N,...A}=y;return jsxRuntime.jsxs(react.Fragment,{children:[c&&b==0&&v(-1,`--selector-${y.id}`,"all"),jsxRuntime.jsx(po,{idx:-1,onSort:m,sortBy:f,value:N,...A,pubsub:t,style:a[y.id]})]},`--col-${y.id}`)}),d&&r>-1&&jsxRuntime.jsx(p,{as:"--col",children:jsxRuntime.jsx(_,{as:"opacity:0",children:"..."})}),!d&&r>-1&&s&&o&&n.map((y,b)=>jsxRuntime.jsxs(react.Fragment,{children:[c&&b==0&&v(b,`--selector-${y.id}`,y.id.toString()),s.includes(String(y.id))?jsxRuntime.jsx(po,{pubsub:t,idx:b,id:String(y.id),style:a[String(y.id)],value:y.render?y.render(o,r):o[String(y.id).includes(".")?String(y.id).split(".").reverse()[0]:y.id]}):null]},`--${String(y.id)}-val-${b}`))]})};ya.displayName="Zuz.Row";var uo=ya;var Sa=(e,r)=>{let{schema:t,rows:n,rowCount:o,rowsPerPage:s,currentPage:a,pagination:l,paginationHash:f,showPaginationOnZeroPageCount:c,animateRows:i,header:d,rowClassName:u,selectableRows:m,hoverable:h,sortBy:C,loading:x,loadingRowCount:T,loadingMessage:S,spinner:P,emptyMessage:g,onSort:v,onRowClick:y,onRowSelectToggle:b,onPageChange:I,onRowContextMenu:D,...N}=e,A=react.useRef(null),L=react.useMemo(()=>t.reduce((le,G)=>(le[G.id]={flex:G.weight||1,...G.w&&{width:G.w},...G.maxW&&{maxWidth:G.maxW},...G.minW&&{minWidth:G.minW},...G.h&&{height:G.h},...G.maxH&&{maxHeight:G.maxH},...G.minH&&{minHeight:G.minH}},le),{}),[t]),M=react.useMemo(()=>Object.keys(L),[t]),$=react.useMemo(()=>d??true,[d]),{style:K,className:R,rest:B}=E(N),q=react.useRef(null),X=react.useMemo(()=>new core.PubSub,[]),H=react.useRef(n.map(()=>core.uuid(8))),[z,W]=react.useState(C||null),[Z,re]=react.useState(S||"loading"),Q=react.useMemo(()=>!x&&n&&n.length==0,[x,n]),se=react.useCallback(()=>g?typeof g=="function"?jsxRuntime.jsx(g,{}):g:jsxRuntime.jsx(_,{as:"tac s:18 mt:75",children:"No Record Found"}),[x,n]);react.useEffect(()=>{n.length&&!H.current&&(H.current=n.map(()=>core.uuid(8)));},[n]);let me=(le,G)=>{W(le),v?.(le,G);},ge=(o||(n?n.length:0))/(s||10),ae=react.useMemo(()=>c||ge>1?jsxRuntime.jsx(Nt,{hash:f,ref:A,renderOnZeroPageCount:c,onPageChange:I,paginationStyle:"table",startPage:a,itemCount:o||(n?n.length:0),itemsPerPage:s||10}):null,[a,o]);return react.useImperativeHandle(r,()=>({setLoading(le){}})),jsxRuntime.jsxs(p,{as:`--table ${h??true?"--hoverable":""} flex cols rel ${R}`,ref:q,children:[$==true&&jsxRuntime.jsx(uo,{sortBy:z,onSort:me,tableRef:q,pubsub:X,selectable:m,index:-1,schema:t,loading:true,styles:L}),x&&jsxRuntime.jsxs(p,{as:"center-x flex aic --table-spinner",children:[jsxRuntime.jsx(we,{type:P||xe.Simple}),Z&&jsxRuntime.jsx(_,{as:"--table-loading-message",children:Z})]}),x&&Array(T||5).fill({}).map((le,G)=>jsxRuntime.jsx(uo,{tableRef:q,index:G,pubsub:X,schema:t,styles:L,loading:true,animate:i,onRowClick:y},`--trow-loading-${G}-${t[0].id}`)),!x&&n&&n.map((le,G)=>jsxRuntime.jsx(uo,{tableRef:q,pubsub:X,loading:false,index:G,schema:t,ids:M,styles:L,animate:i,data:le,onRowClick:y,rowClassName:u,selectable:m,onSelect:b,onContextMenu:D},`--trow-${H.current[G]||G}-${t[0].id}`)),Q&&se(),l&&ae&&jsxRuntime.jsx(p,{"aria-hidden":!l||!ae,...i?{fx:{transition:Y.SlideInBottom,curve:ee.EaseInOut,delay:.02*(n.length+1),when:!x&&n&&l&&ae!=null}}:{},as:"--row flex aic --row-footer",children:ae})]})};Sa.displayName="Zuz.Table";var Nu=react.forwardRef(Sa),Eu=Nu;var ku=({ref:e,...r})=>{let{title:t,items:n}=r,[o,s]=react.useState(0),a=(l,f,c)=>{l.preventDefault(),s(f),document.getElementById(c)?.scrollIntoView({behavior:"smooth"});};return jsxRuntime.jsxs(p,{ref:e,as:"--table-of-contents rel flex cols",children:[jsxRuntime.jsx(_,{as:"--toc-title",children:t}),jsxRuntime.jsx(et,{items:n.map((l,f)=>jsxRuntime.jsx("a",{className:o==f?"--toc-active":"",style:{anchorName:o===f?"--toc-active":"none",color:o==f?"var(--table-of-contents-color-active)":"var(--table-of-contents-color)"},onClick:c=>a(c,f,l.tag),href:`#${l.tag}`,children:l.label}))})]})},Lu=ku;var wa=({isActive:e,transitionType:r,speed:t,width:n,render:o,content:s,onHeightChange:a})=>{let l=react.useRef(null),f=hooks.useResizeObserver(l);react.useEffect(()=>{e&&f.height>0&&a(f.height);},[e,f.height]);let i=react.useMemo(()=>{let d={width:n>0?`${n}px`:"100%",minWidth:n>0?`${n}px`:"100%",flexShrink:0,height:"fit-content",boxSizing:"border-box"};return r==="fade"?{...d,gridArea:"1 / 1 / 2 / 2",opacity:e?1:0,visibility:e?"visible":"hidden",transition:`opacity ${t}s ease-in-out`,zIndex:e?1:0}:r==="scale"?{...d,gridArea:"1 / 1 / 2 / 2",opacity:e?1:0,transform:`scale(${e?1:.95})`,transition:`all ${t}s cubic-bezier(0.34, 1.56, 0.64, 1)`,zIndex:e?1:0}:d},[e,r,n,t]);return jsxRuntime.jsx(p,{ref:l,style:{...i},className:"--content",children:o||e?s:null})};wa.displayName="Zuz.TabBody";var Ca=wa;var Ra=({ref:e,...r})=>{let{tabs:t,speed:n=.3,prerender:o=true,variant:s,tabStyle:a="fixed",onChange:l,transitionType:f="slide",...c}=r,[i,d]=react.useState(0),u=react.useRef(null),m=hooks.useResizeObserver(u),h=react.useMemo(()=>core.uuid(8),[]),[C,x]=react.useState("auto"),T=react.useMemo(()=>m.width>0,[m.width]);react.useImperativeHandle(e,()=>({setTab:b=>d(b)}));let S=react.useMemo(()=>t.map(b=>({...b,key:b.key||core.uuid(8)})),[t]),{style:P,className:g,rest:v}=E({as:`flex cols w-full no-overflow ${c.as||""}`,...c}),y=()=>{if(!T)return {opacity:0};switch(f){case "fade":case "scale":return {display:"grid",gridTemplateColumns:"1fr",width:"100%"};default:return {width:`${S.length*100}%`,alignItems:"flex-start",display:"flex",transform:`translate3d(-${i*m.width}px, 0, 0)`,transition:`transform ${n}s cubic-bezier(0.4, 0, 0.2, 1)`}}};return jsxRuntime.jsxs(p,{ref:u,style:P,className:`--tabview --${a} flex cols ${g}`,children:[jsxRuntime.jsx(kt,{as:"--tabview-head",onSwitch:b=>{d(b.index);let I=S.find(D=>D.tag==b.tag);I&&I.onSelect&&(I.onSelect(I,b.index),l?.(I,b.index));},selected:i,items:S.reduce((b,I,D)=>(b.push({icon:I.icon,index:D,label:I.label,tag:I.tag}),b),[])}),jsxRuntime.jsx(p,{className:"--tabview-body",as:"rel no-overflow w-full",style:{height:C,transition:T?`height ${n}s cubic-bezier(0.4, 0, 0.2, 1)`:"none",opacity:T?1:0},children:jsxRuntime.jsx(p,{className:"--track",style:{...y()},children:S.map((b,I)=>jsxRuntime.jsx(Ca,{isActive:I===i,transitionType:f,speed:n,width:m.width,render:o||I===i,onHeightChange:D=>I===i&&x(D),content:b.body},`tab-body-${b.key||I}-${h}`))})})]})};Ra.displayName="Zuz.TabView";var _u=Ra;var Gu=({ref:e,commands:r,onCommand:t,welcomeMessage:n="Welcome to Zuz Terminal v1.0.0",prompt:o="zuz ~ ",variant:s,...a})=>{let[l,f]=react.useState([{type:"output",content:n}]),[c,i]=react.useState(""),d=react.useRef(null),u=react.useRef(null),{variant:m}=j(true);react.useEffect(()=>{d.current&&(d.current.scrollTop=d.current.scrollHeight);},[l]);let h=g=>{let v=typeof g=="string"?{type:"output",content:g}:g;f(y=>{let b=[...y,v];return b.length>1e3?b.slice(-1e3):b});},C=()=>f([]);react.useImperativeHandle(e,()=>({write:h,clear:C}));let x=async g=>{let[v,...y]=g.split(" "),b=v.toLowerCase();return r&&r[b]?await r[b](y):t?await t(g):`command not found: ${v}`},T=g=>{let v=/\u001b\[(\d+)m/g,y=[],b={31:"#ff5f56",32:"#27c93f",33:"#ffbd2e",34:"#007aff",35:"#ff79c6",36:"#8be9fd",39:"#d4d4d4"},I=0,D="#d4d4d4",N=false,A;for(;(A=v.exec(g))!==null;){let M=g.slice(I,A.index);M&&y.push({text:M,color:D,bold:N});let $=A[1];$==="0"?(D="#d4d4d4",N=false):$==="1"?N=true:b[$]&&(D=b[$]),I=v.lastIndex;}let L=g.slice(I);return L&&y.push({text:L,color:D,bold:N}),y},S=(g,v)=>g.includes("\x1B")?T(g).map((y,b)=>jsxRuntime.jsx(ce,{style:{color:y.color||"#d4d4d4",fontWeight:y.bold?"bold":"normal"},children:y.text},`--terminal-msg-${b}-${y.text.replace(/\S+/g,"-")}`)):jsxRuntime.jsx(ce,{style:{color:v==="error"?"#ff5f56":v==="command"?"#00ff00":"#d4d4d4"},children:g}),P=async g=>{if(g.key==="Enter"&&c.trim()){let v=c.trim(),y=[...l,{type:"command",content:`${o}${v}`}];i(""),f(y);let b=await x(v);f(I=>[...I,{type:"output",content:b}]);}};return jsxRuntime.jsxs(p,{as:`--zuz-terminal --${s||m||U.Medium} flex cols ${a.className}`,onClick:()=>u.current?.focus(),children:[jsxRuntime.jsx(p,{ref:d,className:"--terminal-log",children:l.map((g,v)=>jsxRuntime.jsx(p,{children:jsxRuntime.jsx(_,{children:S(g.content,g.type)})},v))}),jsxRuntime.jsxs(p,{as:"flex aic --terminal-input",children:[jsxRuntime.jsx(_,{as:"--terminal-prompt",children:o}),jsxRuntime.jsx(fe,{ref:u,className:"--zuz-term-input",autoFocus:true,value:c,variant:s||m||U.Medium,onChange:g=>i(g.target.value),onKeyDown:P})]})]})},Uu=Gu;var qu=({meta:e})=>jsxRuntime.jsxs(F,{as:"flex aic --command-item",children:[e.icon&&jsxRuntime.jsx(J,{name:e.icon,as:"--command-icon"}),jsxRuntime.jsx(_,{children:e.label})]}),Xu=({position:e,onSelect:r,commands:t,visible:n})=>jsxRuntime.jsx(p,{"aria-hidden":!n,fx:{transition:Y.SlideInBottom,duration:.1,when:n},className:"--command-box abs grid",style:{...e},children:t.map(o=>jsxRuntime.jsx(qu,{meta:o},`cmd-${o.label.replace(/\s+/,"-")}`))}),Ba=Xu;var Ma=({ref:e,...r})=>{let {autoResize:t,maxHeight:n,variant:o,resize:s="none",command:a,commands:l,name:f,onInput:c,cmd:i,renderDropdown:d,value:u,defaultValue:m,...h}=r,C=react.useRef(null),x=react.useRef(null),{variant:T}=j(true),{style:S,className:P,rest:g}=E(h),v=Fe();f?v.errors?.[f]:null;let b=f&&v.values&&v.setFieldValue,I=b?v.values?.[f]:void 0,D=hooks.useDebounce(B=>{b&&v.setFieldValue?.(f,B);},500),{showDropdown:N,dropdownPosition:A,handleKeyDown:L,handleInput:M,handleCommandSelect:$}=hooks.useCommandActions({command:a,commands:l,cmd:i,ref:C}),K=react.useCallback(()=>{let B=C.current;!B||!t||(x.current&&cancelAnimationFrame(x.current),x.current=requestAnimationFrame(()=>{B.style.height="auto";let q=B.scrollHeight;if(n){let X=parseInt(n.toString(),10);isNaN(X)||(q=Math.min(q,X));}B.style.height=`${q}px`,B.style.overflowY=n&&q>=parseInt(n.toString(),10)?"auto":"hidden";}));},[t,n]),R=B=>{D(B.currentTarget.value),c?.(B),M(B),K();};return react.useEffect(()=>{C.current&&f&&I!==void 0&&C.current.value!==String(I)&&(C.current.value=String(I));},[I,f]),react.useEffect(()=>{K();},[u,m,K]),react.useEffect(()=>{t&&C.current&&K();},[t,K]),react.useEffect(()=>()=>{x.current&&cancelAnimationFrame(x.current);},[]),react.useEffect(()=>()=>{b&&v.deleteFieldValue?.(f);},[]),jsxRuntime.jsxs(p,{as:"rel",children:[jsxRuntime.jsx("textarea",{name:f,className:`--input --textarea --${o||T||U.Medium} flex ${P}`.trim(),style:{...S,resize:s,height:t?"auto":S?.height,overflow:"hidden",transition:t?"none":void 0},onKeyDown:L,onInput:R,ref:B=>{C.current=B,typeof e=="function"?e(B):e&&(e.current=B);},value:u,defaultValue:m,...g}),d?d({show:N,position:A,commands:l||[],onSelect:$}):l&&l.length>0&&jsxRuntime.jsx(Ba,{visible:N,commands:l,onSelect:$,position:A})]})};Ma.displayName="Zuz.TextArea";var ef=Ma;var Va=react.forwardRef((e,r)=>{let{as:t,value:n,color:o,direction:s,...a}=e,l=react.useRef(null),[f,c]=react.useState(n||0);return react.useImperativeHandle(r,()=>({updateValue(i){f.toString().length!==i.toString().length&&c(i);},setValue(i){if(this.updateValue(i),l.current){let d=i.toString().split("");l.current.querySelectorAll(".--wheel-char").forEach((u,m)=>{let h=d[m];if(u instanceof HTMLElement){u.setAttribute("data-value",h);let C=u.querySelector(".--wheel-char-track");C instanceof HTMLElement&&(C.style.setProperty("--v",h),C.offsetWidth);}});}}})),react.useEffect(()=>{c(n||0);},[n]),jsxRuntime.jsxs(p,{className:"--text-wheel flex aic rel","aria-hidden":true,as:t,ref:l,...a,children:[(f||0).toString().split("").map((i,d)=>isNaN(parseInt(i,10))?jsxRuntime.jsx(ce,{className:"--wheel-char wheel-char-symbol grid",children:i},`wheel-char-symbol-${d}`):jsxRuntime.jsx(ce,{"data-value":i,className:`--wheel-char grid ${d>(f||0).toString().length-3?"--wheel-fraction":""}`.trim(),children:jsxRuntime.jsxs(ce,{className:`--wheel-char-track --wheel-track-${s||"down"} grid`,style:{"--v":i},children:[jsxRuntime.jsx(ce,{children:!s||s==="down"?0:9}),(!s||s==="down"?[9,8,7,6,5,4,3,2,1,0]:[0,1,2,3,4,5,6,7,8,9]).map((u,m)=>jsxRuntime.jsx(ce,{children:u},`${d}--${m}`)),jsxRuntime.jsx(ce,{children:!s||s==="down"?9:0})]})},`wheel-char-${d}`)),o&&jsxRuntime.jsx(p,{className:"abs fillx",style:{zIndex:1,background:`linear-gradient(0deg, ${o}, transparent, transparent, transparent, ${o})`}})]})});Va.displayName="Zuz.TextWheel";var lf=Va;var Pr=react.forwardRef((e,r)=>{let{as:t,meta:n,nodes:o,icons:s,onSelect:a,treeTag:l,selected:f,roots:c,expanded:i,...d}=e,{tag:u,label:m,icon:h,under:C,isHead:x}=n,T=react.useMemo(()=>c.includes(u),[c]),[S,P]=react.useState(i),g=()=>{localStorage.setItem(`--tn${l}-${u}`,S?"0":"1"),P(!S);};react.useEffect(()=>{i||T&&!localStorage.getItem(`--tn${l}-${u}`)?(localStorage.setItem(`--tn${l}-${u}`,"1"),P(true)):P(localStorage.getItem(`--tn${l}-${u}`)=="1");},[]);let v=react.useMemo(()=>o.filter(y=>y.under==u),[o,u]);return jsxRuntime.jsxs(p,{className:`--treenode ${T?"--is-root":""} --treenode-${u} flex cols`,children:[jsxRuntime.jsxs(p,{className:`--node --node-${u} flex aic ${f==u?" --selected":""}`,children:[jsxRuntime.jsx(F,{skeleton:d.skeleton,onClick:g,className:"--node-aro-btn",disabled:v.length==0,children:s?.arrowClose&&s?.arrowOpen?jsxRuntime.jsx(J,{skeleton:d.skeleton,className:"--node-aro-icon",name:v.length==0?s?.arrowDisabled||s?.arrowClose:S?s?.arrowOpen:s?.arrowClose}):v.length==0?O.chevronBottom:S?O.chevronBottom:O.chevronRight}),jsxRuntime.jsxs(F,{className:"--node-meta flex aic",onClick:y=>a(u),children:[(s?.nodeOpen&&s?.nodeClose||T&&s?.rootOpen&&s?.rootClose)&&jsxRuntime.jsx(J,{skeleton:d.skeleton,className:`--node-icon ${T?"--icon-root":""}`,name:h||(S?T&&s?.rootOpen||s.nodeOpen:T&&s?.rootClose||s?.nodeClose)}),jsxRuntime.jsx(_,{className:`--node-label ${T?"--node-label-root":""}`.trim(),skeleton:d.skeleton,children:m})]})]}),S&&v.length>0&&jsxRuntime.jsx(p,{className:`--sub-node tree-sub-node-${u} flex cols`,children:v.map(y=>jsxRuntime.jsx(Pr,{treeTag:l,selected:f,onSelect:a,icons:s,roots:c,expanded:y.expanded||false,meta:y,nodes:o},`--node-${y.tag}`))})]})});Pr.displayName="TreeItem";var Ha=Pr;var $a=react.forwardRef((e,r)=>{let{as:t,nodes:n,onNodeSelect:o,tag:s,icons:a,roots:l,selected:f,...c}=e,[i,d]=react.useState(f);react.useImperativeHandle(r,()=>({getSelected:()=>i}),[o]);let u=m=>{d(m),o&&o(m);};return react.useEffect(()=>{i!=f&&d(f);},[f]),jsxRuntime.jsx(p,{className:"--treeview flex cols",children:n.filter(m=>l.includes(m.tag)).map(m=>jsxRuntime.jsx(Ha,{treeTag:s?`-${s}`:"",selected:i,onSelect:h=>u(h),icons:a,meta:m,roots:l,expanded:m.expanded||false,skeleton:c.skeleton,nodes:n},`--node-${m.tag}`))})});$a.displayName="Zuz.TreeView";var hf=$a;String.prototype.trim=function(){return this.replace(/^\s+|\s+$/g,"").replace(/\s+/g," ")};
14
+ Object.defineProperty(exports,"PACKAGE_NAME",{enumerable:true,get:function(){return chunkT2RBNOBB_cjs.f}});Object.defineProperty(exports,"cleanProps",{enumerable:true,get:function(){return chunkT2RBNOBB_cjs.g}});Object.defineProperty(exports,"splitAtoms",{enumerable:true,get:function(){return chunkT2RBNOBB_cjs.h}});exports.ALERT=Ie;exports.AVATAR=kr;exports.Accordion=Ml;exports.ActionBar=$l;exports.Alert=_l;exports.AutoComplete=fc;exports.Avatar=Sc;exports.Badge=Cc;exports.Box=p;exports.Bubble=nm;exports.BubbleMediaType=rs;exports.BubbleStatus=os;exports.Button=F;exports.CHART=Qn;exports.CHECKBOX=$e;exports.COLORTHEME=vf;exports.Calendar=Qo;exports.Carousel=qc;exports.Chart=tm;exports.CheckBox=Bt;exports.CodeBlock=hm;exports.ColorScheme=Lm;exports.ContextMenu=Bo;exports.CookiesConsent=Dm;exports.Cover=Le;exports.CropShape=Ym;exports.Cropper=qm;exports.Crumb=Qm;exports.DATATYPE=Cf;exports.DIALOG=st;exports.DIALOG_ACTION_POSITION=Lr;exports.DRAWER_SIDE=Se;exports.DatePicker=op;exports.Dialog=Oo;exports.Drawer=Ao;exports.FILTER=At;exports.FORMVALIDATION=Xe;exports.FORMVALIDATION_STYLE=Tf;exports.Fab=ap;exports.Filters=cp;exports.Flex=Ve;exports.Form=Tp;exports.Grid=Ip;exports.Group=ko;exports.Icon=J;exports.Image=tt;exports.Input=fe;exports.KeyboardKeys=hr;exports.KeysLabelMap=zs;exports.KeysMap=$s;exports.Label=Et;exports.LayersProvider=Io;exports.List=et;exports.MediaPlayer=Hp;exports.NetworkStatus=zp;exports.ORIGIN=bt;exports.OriginType=Sf;exports.Overlay=Ye;exports.POSITION=xt;exports.PROGRESS=Rf;exports.Pagination=Nt;exports.PaginationStyle=eo;exports.Password=Up;exports.PinInput=jp;exports.Position=he;exports.ProgressBar=Qe;exports.RADIO=vo;exports.Radio=tu;exports.SHEET=Ne;exports.SHEET_ACTION_POSITION=xo;exports.SKELETON=bf;exports.SLIDER=bo;exports.SORT=wf;exports.SPINNER=xe;exports.ScrollView=Vo;exports.Search=yr;exports.Select=du;exports.SelectTabs=kt;exports.Sheet=gp;exports.Slider=it;exports.SnackPosition=qt;exports.SnackStyle=gn;exports.SnackType=Ut;exports.Span=ce;exports.Spinner=we;exports.Status=Pf;exports.Switch=gu;exports.TRANSITIONS=Y;exports.TRANSITION_CURVES=ee;exports.TabView=_u;exports.Table=Eu;exports.TableOfContents=Lu;exports.Terminal=Uu;exports.Text=_;exports.TextWheel=lf;exports.Textarea=ef;exports.ThemeProvider=ti;exports.ToastDefaultTitle=hn;exports.ToastPosition=qt;exports.ToastProvider=zo;exports.ToastStyle=gn;exports.ToastType=Ut;exports.ToolTip=ar;exports.TreeView=hf;exports.Variant=U;exports.animationTransition=vt;exports.buildClassString=So;exports.buildWithStyles=Vr;exports.css=Wf;exports.getAnimationCurve=wo;exports.getAnimationTransition=Gf;exports.getZuzMap=qa;exports.isKeyCombination=As;exports.setZuzMap=Or;exports.useBase=E;exports.useContextMenu=cl;exports.useDialog=ul;exports.useDrawer=gl;exports.useFx=ye;exports.useMorph=xl;exports.usePosition=Pt;exports.useSnack=Pl;exports.useToast=Fo;