tcce-design-system-test 0.3.35 → 0.3.36

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.
@@ -1,4 +1,4 @@
1
- (function(S,g){typeof exports=="object"&&typeof module<"u"?g(exports,require("styled-components"),require("react/jsx-runtime"),require("react"),require("react-dom"),require("formik")):typeof define=="function"&&define.amd?define(["exports","styled-components","react/jsx-runtime","react","react-dom","formik"],g):(S=typeof globalThis<"u"?globalThis:S||self,g(S["tcce-design-system-components"]={},S.styled,S["react/jsx-runtime"],S.React,S.ReactDOM,S.Formik))})(this,(function(S,g,p,m,_r,Cc){"use strict";function Tc(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const o=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,o.get?o:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const Ue=Tc(m),kn={80:g.css`
1
+ (function(S,g){typeof exports=="object"&&typeof module<"u"?g(exports,require("styled-components"),require("react/jsx-runtime"),require("react"),require("react-dom"),require("formik")):typeof define=="function"&&define.amd?define(["exports","styled-components","react/jsx-runtime","react","react-dom","formik"],g):(S=typeof globalThis<"u"?globalThis:S||self,g(S["tcce-design-system-components"]={},S.styled,S["react/jsx-runtime"],S.React,S.ReactDOM,S.Formik))})(this,(function(S,g,p,m,Rr,xc){"use strict";function Sc(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const o=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,o.get?o:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const Ue=Sc(m),Vn={80:g.css`
2
2
  font-family: 'Dax', serif;
3
3
  font-size: 5em;
4
4
  font-style: normal;
@@ -40,7 +40,7 @@
40
40
  font-style: normal;
41
41
  font-weight: 700;
42
42
  line-height: 161.76%;
43
- `},Br={80:g.css`
43
+ `},_r={80:g.css`
44
44
  font-family: 'Dax', serif;
45
45
  font-size: 5em;
46
46
  font-style: normal;
@@ -143,18 +143,18 @@
143
143
  font-weight: 400;
144
144
  line-height: 133%;
145
145
  `},Nr=g.h1`
146
- ${({size:e=24})=>kn[e]}
146
+ ${({size:e=24})=>Vn[e]}
147
147
  margin: 0;
148
148
  color: ${({color:e})=>e||"var(--color-main-blue-primary)"};
149
- `,$c=g.h2`
150
- ${({size:e=24})=>Br[e]}
149
+ `,Cc=g.h2`
150
+ ${({size:e=24})=>_r[e]}
151
151
  margin: 0;
152
152
  color: ${({color:e})=>e||"var(--color-main-blue-primary)"};
153
153
  `,Ve=g.span`
154
154
  ${({size:e=16})=>E[e]}
155
155
  margin: 0;
156
156
  color: ${({color:e})=>e||"var(--color-main-blue-primary)"};
157
- `,Pc=g.span`
157
+ `,Tc=g.span`
158
158
  display: inline-flex;
159
159
  align-items: center;
160
160
  justify-content: center;
@@ -164,7 +164,7 @@
164
164
  outline: none;
165
165
  box-shadow: var(--shadow-hover-black-card);
166
166
  }
167
- `,zr={tn:"1rem",sm:"1.5rem",md:"2rem",lg:"3rem"},H=({component:e,size:t="1.5rem",color:n="currentColor",className:o,iconProps:r={}})=>{const i=typeof t=="string"&&t in zr?zr[t]:t;return p.jsx(Pc,{$color:n,className:o,children:typeof e=="function"?p.jsx(e,{size:i,...r}):e})},Vn=m.createContext({});function En(e){const t=m.useRef(null);return t.current===null&&(t.current=e()),t.current}const Or=typeof window<"u",Hr=Or?m.useLayoutEffect:m.useEffect,Ut=m.createContext(null);function Dn(e,t){e.indexOf(t)===-1&&e.push(t)}function Fn(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}const $e=(e,t,n)=>n>t?t:n<e?e:n;function An(e,t){return t?`${e}. For more information and steps for solving, visit https://motion.dev/troubleshooting/${t}`:e}let et=()=>{},Ee=()=>{};typeof process<"u"&&process.env?.NODE_ENV!=="production"&&(et=(e,t,n)=>{!e&&typeof console<"u"&&console.warn(An(t,n))},Ee=(e,t,n)=>{if(!e)throw new Error(An(t,n))});const De={},jr=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);function Gr(e){return typeof e=="object"&&e!==null}const Ur=e=>/^0[^.\s]+$/u.test(e);function In(e){let t;return()=>(t===void 0&&(t=e()),t)}const me=e=>e,Mc=(e,t)=>n=>t(e(n)),xt=(...e)=>e.reduce(Mc),St=(e,t,n)=>{const o=t-e;return o===0?1:(n-e)/o};class Ln{constructor(){this.subscriptions=[]}add(t){return Dn(this.subscriptions,t),()=>Fn(this.subscriptions,t)}notify(t,n,o){const r=this.subscriptions.length;if(r)if(r===1)this.subscriptions[0](t,n,o);else for(let i=0;i<r;i++){const s=this.subscriptions[i];s&&s(t,n,o)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const Pe=e=>e*1e3,pe=e=>e/1e3;function Kr(e,t){return t?e*(1e3/t):0}const Wr=new Set;function Rn(e,t,n){e||Wr.has(t)||(console.warn(An(t,n)),Wr.add(t))}const qr=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,kc=1e-7,Vc=12;function Ec(e,t,n,o,r){let i,s,a=0;do s=t+(n-t)/2,i=qr(s,o,r)-e,i>0?n=s:t=s;while(Math.abs(i)>kc&&++a<Vc);return s}function Ct(e,t,n,o){if(e===t&&n===o)return me;const r=i=>Ec(i,0,1,e,n);return i=>i===0||i===1?i:qr(r(i),t,o)}const Yr=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,Xr=e=>t=>1-e(1-t),Zr=Ct(.33,1.53,.69,.99),_n=Xr(Zr),Jr=Yr(_n),Qr=e=>(e*=2)<1?.5*_n(e):.5*(2-Math.pow(2,-10*(e-1))),Bn=e=>1-Math.sin(Math.acos(e)),ei=Xr(Bn),ti=Yr(Bn),Dc=Ct(.42,0,1,1),Fc=Ct(0,0,.58,1),ni=Ct(.42,0,.58,1),Ac=e=>Array.isArray(e)&&typeof e[0]!="number",oi=e=>Array.isArray(e)&&typeof e[0]=="number",ri={linear:me,easeIn:Dc,easeInOut:ni,easeOut:Fc,circIn:Bn,circInOut:ti,circOut:ei,backIn:_n,backInOut:Jr,backOut:Zr,anticipate:Qr},Ic=e=>typeof e=="string",ii=e=>{if(oi(e)){Ee(e.length===4,"Cubic bezier arrays must contain four numerical values.","cubic-bezier-length");const[t,n,o,r]=e;return Ct(t,n,o,r)}else if(Ic(e))return Ee(ri[e]!==void 0,`Invalid easing type '${e}'`,"invalid-easing-type"),ri[e];return e},Kt=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function Lc(e,t){let n=new Set,o=new Set,r=!1,i=!1;const s=new WeakSet;let a={delta:0,timestamp:0,isProcessing:!1};function l(d){s.has(d)&&(c.schedule(d),e()),d(a)}const c={schedule:(d,u=!1,h=!1)=>{const v=h&&r?n:o;return u&&s.add(d),v.has(d)||v.add(d),d},cancel:d=>{o.delete(d),s.delete(d)},process:d=>{if(a=d,r){i=!0;return}r=!0,[n,o]=[o,n],n.forEach(l),n.clear(),r=!1,i&&(i=!1,c.process(d))}};return c}const Rc=40;function si(e,t){let n=!1,o=!0;const r={delta:0,timestamp:0,isProcessing:!1},i=()=>n=!0,s=Kt.reduce((C,M)=>(C[M]=Lc(i),C),{}),{setup:a,read:l,resolveKeyframes:c,preUpdate:d,update:u,preRender:h,render:f,postRender:v}=s,y=()=>{const C=De.useManualTiming?r.timestamp:performance.now();n=!1,De.useManualTiming||(r.delta=o?1e3/60:Math.max(Math.min(C-r.timestamp,Rc),1)),r.timestamp=C,r.isProcessing=!0,a.process(r),l.process(r),c.process(r),d.process(r),u.process(r),h.process(r),f.process(r),v.process(r),r.isProcessing=!1,n&&t&&(o=!1,e(y))},b=()=>{n=!0,o=!0,r.isProcessing||e(y)};return{schedule:Kt.reduce((C,M)=>{const x=s[M];return C[M]=(P,V=!1,$=!1)=>(n||b(),x.schedule(P,V,$)),C},{}),cancel:C=>{for(let M=0;M<Kt.length;M++)s[Kt[M]].cancel(C)},state:r,steps:s}}const{schedule:U,cancel:Le,state:ne,steps:Nn}=si(typeof requestAnimationFrame<"u"?requestAnimationFrame:me,!0);let Wt;function _c(){Wt=void 0}const le={now:()=>(Wt===void 0&&le.set(ne.isProcessing||De.useManualTiming?ne.timestamp:performance.now()),Wt),set:e=>{Wt=e,queueMicrotask(_c)}},ai=e=>t=>typeof t=="string"&&t.startsWith(e),li=ai("--"),Bc=ai("var(--"),zn=e=>Bc(e)?Nc.test(e.split("/*")[0].trim()):!1,Nc=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function ci(e){return typeof e!="string"?!1:e.split("/*")[0].includes("var(--")}const tt={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},Tt={...tt,transform:e=>$e(0,1,e)},qt={...tt,default:1},$t=e=>Math.round(e*1e5)/1e5,On=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function zc(e){return e==null}const Oc=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,Hn=(e,t)=>n=>!!(typeof n=="string"&&Oc.test(n)&&n.startsWith(e)||t&&!zc(n)&&Object.prototype.hasOwnProperty.call(n,t)),ui=(e,t,n)=>o=>{if(typeof o!="string")return o;const[r,i,s,a]=o.match(On);return{[e]:parseFloat(r),[t]:parseFloat(i),[n]:parseFloat(s),alpha:a!==void 0?parseFloat(a):1}},Hc=e=>$e(0,255,e),jn={...tt,transform:e=>Math.round(Hc(e))},Ke={test:Hn("rgb","red"),parse:ui("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:o=1})=>"rgba("+jn.transform(e)+", "+jn.transform(t)+", "+jn.transform(n)+", "+$t(Tt.transform(o))+")"};function jc(e){let t="",n="",o="",r="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),o=e.substring(5,7),r=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),o=e.substring(3,4),r=e.substring(4,5),t+=t,n+=n,o+=o,r+=r),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(o,16),alpha:r?parseInt(r,16)/255:1}}const Gn={test:Hn("#"),parse:jc,transform:Ke.transform},Pt=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),Re=Pt("deg"),Me=Pt("%"),k=Pt("px"),Gc=Pt("vh"),Uc=Pt("vw"),di={...Me,parse:e=>Me.parse(e)/100,transform:e=>Me.transform(e*100)},nt={test:Hn("hsl","hue"),parse:ui("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:o=1})=>"hsla("+Math.round(e)+", "+Me.transform($t(t))+", "+Me.transform($t(n))+", "+$t(Tt.transform(o))+")"},J={test:e=>Ke.test(e)||Gn.test(e)||nt.test(e),parse:e=>Ke.test(e)?Ke.parse(e):nt.test(e)?nt.parse(e):Gn.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?Ke.transform(e):nt.transform(e),getAnimatableNone:e=>{const t=J.parse(e);return t.alpha=0,J.transform(t)}},Kc=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function Wc(e){return isNaN(e)&&typeof e=="string"&&(e.match(On)?.length||0)+(e.match(Kc)?.length||0)>0}const fi="number",hi="color",qc="var",Yc="var(",mi="${}",Xc=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function Mt(e){const t=e.toString(),n=[],o={color:[],number:[],var:[]},r=[];let i=0;const a=t.replace(Xc,l=>(J.test(l)?(o.color.push(i),r.push(hi),n.push(J.parse(l))):l.startsWith(Yc)?(o.var.push(i),r.push(qc),n.push(l)):(o.number.push(i),r.push(fi),n.push(parseFloat(l))),++i,mi)).split(mi);return{values:n,split:a,indexes:o,types:r}}function pi(e){return Mt(e).values}function gi(e){const{split:t,types:n}=Mt(e),o=t.length;return r=>{let i="";for(let s=0;s<o;s++)if(i+=t[s],r[s]!==void 0){const a=n[s];a===fi?i+=$t(r[s]):a===hi?i+=J.transform(r[s]):i+=r[s]}return i}}const Zc=e=>typeof e=="number"?0:J.test(e)?J.getAnimatableNone(e):e;function Jc(e){const t=pi(e);return gi(e)(t.map(Zc))}const _e={test:Wc,parse:pi,createTransformer:gi,getAnimatableNone:Jc};function Un(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function Qc({hue:e,saturation:t,lightness:n,alpha:o}){e/=360,t/=100,n/=100;let r=0,i=0,s=0;if(!t)r=i=s=n;else{const a=n<.5?n*(1+t):n+t-n*t,l=2*n-a;r=Un(l,a,e+1/3),i=Un(l,a,e),s=Un(l,a,e-1/3)}return{red:Math.round(r*255),green:Math.round(i*255),blue:Math.round(s*255),alpha:o}}function Yt(e,t){return n=>n>0?t:e}const q=(e,t,n)=>e+(t-e)*n,Kn=(e,t,n)=>{const o=e*e,r=n*(t*t-o)+o;return r<0?0:Math.sqrt(r)},eu=[Gn,Ke,nt],tu=e=>eu.find(t=>t.test(e));function vi(e){const t=tu(e);if(et(!!t,`'${e}' is not an animatable color. Use the equivalent color code instead.`,"color-not-animatable"),!t)return!1;let n=t.parse(e);return t===nt&&(n=Qc(n)),n}const yi=(e,t)=>{const n=vi(e),o=vi(t);if(!n||!o)return Yt(e,t);const r={...n};return i=>(r.red=Kn(n.red,o.red,i),r.green=Kn(n.green,o.green,i),r.blue=Kn(n.blue,o.blue,i),r.alpha=q(n.alpha,o.alpha,i),Ke.transform(r))},Wn=new Set(["none","hidden"]);function nu(e,t){return Wn.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function ou(e,t){return n=>q(e,t,n)}function qn(e){return typeof e=="number"?ou:typeof e=="string"?zn(e)?Yt:J.test(e)?yi:su:Array.isArray(e)?wi:typeof e=="object"?J.test(e)?yi:ru:Yt}function wi(e,t){const n=[...e],o=n.length,r=e.map((i,s)=>qn(i)(i,t[s]));return i=>{for(let s=0;s<o;s++)n[s]=r[s](i);return n}}function ru(e,t){const n={...e,...t},o={};for(const r in n)e[r]!==void 0&&t[r]!==void 0&&(o[r]=qn(e[r])(e[r],t[r]));return r=>{for(const i in o)n[i]=o[i](r);return n}}function iu(e,t){const n=[],o={color:0,var:0,number:0};for(let r=0;r<t.values.length;r++){const i=t.types[r],s=e.indexes[i][o[i]],a=e.values[s]??0;n[r]=a,o[i]++}return n}const su=(e,t)=>{const n=_e.createTransformer(t),o=Mt(e),r=Mt(t);return o.indexes.var.length===r.indexes.var.length&&o.indexes.color.length===r.indexes.color.length&&o.indexes.number.length>=r.indexes.number.length?Wn.has(e)&&!r.values.length||Wn.has(t)&&!o.values.length?nu(e,t):xt(wi(iu(o,r),r.values),n):(et(!0,`Complex values '${e}' and '${t}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`,"complex-values-different"),Yt(e,t))};function bi(e,t,n){return typeof e=="number"&&typeof t=="number"&&typeof n=="number"?q(e,t,n):qn(e)(e,t)}const au=e=>{const t=({timestamp:n})=>e(n);return{start:(n=!0)=>U.update(t,n),stop:()=>Le(t),now:()=>ne.isProcessing?ne.timestamp:le.now()}},xi=(e,t,n=10)=>{let o="";const r=Math.max(Math.round(t/n),2);for(let i=0;i<r;i++)o+=Math.round(e(i/(r-1))*1e4)/1e4+", ";return`linear(${o.substring(0,o.length-2)})`},Xt=2e4;function Yn(e){let t=0;const n=50;let o=e.next(t);for(;!o.done&&t<Xt;)t+=n,o=e.next(t);return t>=Xt?1/0:t}function lu(e,t=100,n){const o=n({...e,keyframes:[0,t]}),r=Math.min(Yn(o),Xt);return{type:"keyframes",ease:i=>o.next(r*i).value/t,duration:pe(r)}}const cu=5;function Si(e,t,n){const o=Math.max(t-cu,0);return Kr(n-e(o),t-o)}const Y={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1},Xn=.001;function uu({duration:e=Y.duration,bounce:t=Y.bounce,velocity:n=Y.velocity,mass:o=Y.mass}){let r,i;et(e<=Pe(Y.maxDuration),"Spring duration must be 10 seconds or less","spring-duration-limit");let s=1-t;s=$e(Y.minDamping,Y.maxDamping,s),e=$e(Y.minDuration,Y.maxDuration,pe(e)),s<1?(r=c=>{const d=c*s,u=d*e,h=d-n,f=Zn(c,s),v=Math.exp(-u);return Xn-h/f*v},i=c=>{const u=c*s*e,h=u*n+n,f=Math.pow(s,2)*Math.pow(c,2)*e,v=Math.exp(-u),y=Zn(Math.pow(c,2),s);return(-r(c)+Xn>0?-1:1)*((h-f)*v)/y}):(r=c=>{const d=Math.exp(-c*e),u=(c-n)*e+1;return-Xn+d*u},i=c=>{const d=Math.exp(-c*e),u=(n-c)*(e*e);return d*u});const a=5/e,l=fu(r,i,a);if(e=Pe(e),isNaN(l))return{stiffness:Y.stiffness,damping:Y.damping,duration:e};{const c=Math.pow(l,2)*o;return{stiffness:c,damping:s*2*Math.sqrt(o*c),duration:e}}}const du=12;function fu(e,t,n){let o=n;for(let r=1;r<du;r++)o=o-e(o)/t(o);return o}function Zn(e,t){return e*Math.sqrt(1-t*t)}const hu=["duration","bounce"],mu=["stiffness","damping","mass"];function Ci(e,t){return t.some(n=>e[n]!==void 0)}function pu(e){let t={velocity:Y.velocity,stiffness:Y.stiffness,damping:Y.damping,mass:Y.mass,isResolvedFromDuration:!1,...e};if(!Ci(e,mu)&&Ci(e,hu))if(e.visualDuration){const n=e.visualDuration,o=2*Math.PI/(n*1.2),r=o*o,i=2*$e(.05,1,1-(e.bounce||0))*Math.sqrt(r);t={...t,mass:Y.mass,stiffness:r,damping:i}}else{const n=uu(e);t={...t,...n,mass:Y.mass},t.isResolvedFromDuration=!0}return t}function Zt(e=Y.visualDuration,t=Y.bounce){const n=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:o,restDelta:r}=n;const i=n.keyframes[0],s=n.keyframes[n.keyframes.length-1],a={done:!1,value:i},{stiffness:l,damping:c,mass:d,duration:u,velocity:h,isResolvedFromDuration:f}=pu({...n,velocity:-pe(n.velocity||0)}),v=h||0,y=c/(2*Math.sqrt(l*d)),b=s-i,w=pe(Math.sqrt(l/d)),T=Math.abs(b)<5;o||(o=T?Y.restSpeed.granular:Y.restSpeed.default),r||(r=T?Y.restDelta.granular:Y.restDelta.default);let C;if(y<1){const x=Zn(w,y);C=P=>{const V=Math.exp(-y*w*P);return s-V*((v+y*w*b)/x*Math.sin(x*P)+b*Math.cos(x*P))}}else if(y===1)C=x=>s-Math.exp(-w*x)*(b+(v+w*b)*x);else{const x=w*Math.sqrt(y*y-1);C=P=>{const V=Math.exp(-y*w*P),$=Math.min(x*P,300);return s-V*((v+y*w*b)*Math.sinh($)+x*b*Math.cosh($))/x}}const M={calculatedDuration:f&&u||null,next:x=>{const P=C(x);if(f)a.done=x>=u;else{let V=x===0?v:0;y<1&&(V=x===0?Pe(v):Si(C,x,P));const $=Math.abs(V)<=o,F=Math.abs(s-P)<=r;a.done=$&&F}return a.value=a.done?s:P,a},toString:()=>{const x=Math.min(Yn(M),Xt),P=xi(V=>M.next(x*V).value,x,30);return x+"ms "+P},toTransition:()=>{}};return M}Zt.applyToOptions=e=>{const t=lu(e,100,Zt);return e.ease=t.ease,e.duration=Pe(t.duration),e.type="keyframes",e};function Jn({keyframes:e,velocity:t=0,power:n=.8,timeConstant:o=325,bounceDamping:r=10,bounceStiffness:i=500,modifyTarget:s,min:a,max:l,restDelta:c=.5,restSpeed:d}){const u=e[0],h={done:!1,value:u},f=$=>a!==void 0&&$<a||l!==void 0&&$>l,v=$=>a===void 0?l:l===void 0||Math.abs(a-$)<Math.abs(l-$)?a:l;let y=n*t;const b=u+y,w=s===void 0?b:s(b);w!==b&&(y=w-u);const T=$=>-y*Math.exp(-$/o),C=$=>w+T($),M=$=>{const F=T($),D=C($);h.done=Math.abs(F)<=c,h.value=h.done?w:D};let x,P;const V=$=>{f(h.value)&&(x=$,P=Zt({keyframes:[h.value,v(h.value)],velocity:Si(C,$,h.value),damping:r,stiffness:i,restDelta:c,restSpeed:d}))};return V(0),{calculatedDuration:null,next:$=>{let F=!1;return!P&&x===void 0&&(F=!0,M($),V($)),x!==void 0&&$>=x?P.next($-x):(!F&&M($),h)}}}function gu(e,t,n){const o=[],r=n||De.mix||bi,i=e.length-1;for(let s=0;s<i;s++){let a=r(e[s],e[s+1]);if(t){const l=Array.isArray(t)?t[s]||me:t;a=xt(l,a)}o.push(a)}return o}function vu(e,t,{clamp:n=!0,ease:o,mixer:r}={}){const i=e.length;if(Ee(i===t.length,"Both input and output ranges must be the same length","range-length"),i===1)return()=>t[0];if(i===2&&t[0]===t[1])return()=>t[1];const s=e[0]===e[1];e[0]>e[i-1]&&(e=[...e].reverse(),t=[...t].reverse());const a=gu(t,o,r),l=a.length,c=d=>{if(s&&d<e[0])return t[0];let u=0;if(l>1)for(;u<e.length-2&&!(d<e[u+1]);u++);const h=St(e[u],e[u+1],d);return a[u](h)};return n?d=>c($e(e[0],e[i-1],d)):c}function yu(e,t){const n=e[e.length-1];for(let o=1;o<=t;o++){const r=St(0,t,o);e.push(q(n,1,r))}}function wu(e){const t=[0];return yu(t,e.length-1),t}function bu(e,t){return e.map(n=>n*t)}function xu(e,t){return e.map(()=>t||ni).splice(0,e.length-1)}function ot({duration:e=300,keyframes:t,times:n,ease:o="easeInOut"}){const r=Ac(o)?o.map(ii):ii(o),i={done:!1,value:t[0]},s=bu(n&&n.length===t.length?n:wu(t),e),a=vu(s,t,{ease:Array.isArray(r)?r:xu(t,r)});return{calculatedDuration:e,next:l=>(i.value=a(l),i.done=l>=e,i)}}const Su=e=>e!==null;function Qn(e,{repeat:t,repeatType:n="loop"},o,r=1){const i=e.filter(Su),a=r<0||t&&n!=="loop"&&t%2===1?0:i.length-1;return!a||o===void 0?i[a]:o}const Cu={decay:Jn,inertia:Jn,tween:ot,keyframes:ot,spring:Zt};function Ti(e){typeof e.type=="string"&&(e.type=Cu[e.type])}class eo{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(t=>{this.resolve=t})}notifyFinished(){this.resolve()}then(t,n){return this.finished.then(t,n)}}const Tu=e=>e/100;class to extends eo{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.stop=()=>{const{motionValue:n}=this.options;n&&n.updatedAt!==le.now()&&this.tick(le.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),this.options.onStop?.())},this.options=t,this.initAnimation(),this.play(),t.autoplay===!1&&this.pause()}initAnimation(){const{options:t}=this;Ti(t);const{type:n=ot,repeat:o=0,repeatDelay:r=0,repeatType:i,velocity:s=0}=t;let{keyframes:a}=t;const l=n||ot;process.env.NODE_ENV!=="production"&&l!==ot&&Ee(a.length<=2,`Only two keyframes currently supported with spring and inertia animations. Trying to animate ${a}`,"spring-two-frames"),l!==ot&&typeof a[0]!="number"&&(this.mixKeyframes=xt(Tu,bi(a[0],a[1])),a=[0,100]);const c=l({...t,keyframes:a});i==="mirror"&&(this.mirroredGenerator=l({...t,keyframes:[...a].reverse(),velocity:-s})),c.calculatedDuration===null&&(c.calculatedDuration=Yn(c));const{calculatedDuration:d}=c;this.calculatedDuration=d,this.resolvedDuration=d+r,this.totalDuration=this.resolvedDuration*(o+1)-r,this.generator=c}updateTime(t){const n=Math.round(t-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=n}tick(t,n=!1){const{generator:o,totalDuration:r,mixKeyframes:i,mirroredGenerator:s,resolvedDuration:a,calculatedDuration:l}=this;if(this.startTime===null)return o.next(0);const{delay:c=0,keyframes:d,repeat:u,repeatType:h,repeatDelay:f,type:v,onUpdate:y,finalKeyframe:b}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-r/this.speed,this.startTime)),n?this.currentTime=t:this.updateTime(t);const w=this.currentTime-c*(this.playbackSpeed>=0?1:-1),T=this.playbackSpeed>=0?w<0:w>r;this.currentTime=Math.max(w,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=r);let C=this.currentTime,M=o;if(u){const $=Math.min(this.currentTime,r)/a;let F=Math.floor($),D=$%1;!D&&$>=1&&(D=1),D===1&&F--,F=Math.min(F,u+1),F%2&&(h==="reverse"?(D=1-D,f&&(D-=f/a)):h==="mirror"&&(M=s)),C=$e(0,1,D)*a}const x=T?{done:!1,value:d[0]}:M.next(C);i&&(x.value=i(x.value));let{done:P}=x;!T&&l!==null&&(P=this.playbackSpeed>=0?this.currentTime>=r:this.currentTime<=0);const V=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&P);return V&&v!==Jn&&(x.value=Qn(d,this.options,b,this.speed)),y&&y(x.value),V&&this.finish(),x}then(t,n){return this.finished.then(t,n)}get duration(){return pe(this.calculatedDuration)}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+pe(t)}get time(){return pe(this.currentTime)}set time(t){t=Pe(t),this.currentTime=t,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),this.driver?.start(!1)}get speed(){return this.playbackSpeed}set speed(t){this.updateTime(le.now());const n=this.playbackSpeed!==t;this.playbackSpeed=t,n&&(this.time=pe(this.currentTime))}play(){if(this.isStopped)return;const{driver:t=au,startTime:n}=this.options;this.driver||(this.driver=t(r=>this.tick(r))),this.options.onPlay?.();const o=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=o):this.holdTime!==null?this.startTime=o-this.holdTime:this.startTime||(this.startTime=n??o),this.state==="finished"&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(le.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){this.notifyFinished(),this.teardown(),this.state="finished",this.options.onComplete?.()}cancel(){this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),this.options.onCancel?.()}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}attachTimeline(t){return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),this.driver?.stop(),t.observe(this)}}function $u(e){for(let t=1;t<e.length;t++)e[t]??(e[t]=e[t-1])}const We=e=>e*180/Math.PI,no=e=>{const t=We(Math.atan2(e[1],e[0]));return oo(t)},Pu={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:no,rotateZ:no,skewX:e=>We(Math.atan(e[1])),skewY:e=>We(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},oo=e=>(e=e%360,e<0&&(e+=360),e),$i=no,Pi=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),Mi=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),Mu={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:Pi,scaleY:Mi,scale:e=>(Pi(e)+Mi(e))/2,rotateX:e=>oo(We(Math.atan2(e[6],e[5]))),rotateY:e=>oo(We(Math.atan2(-e[2],e[0]))),rotateZ:$i,rotate:$i,skewX:e=>We(Math.atan(e[4])),skewY:e=>We(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function ro(e){return e.includes("scale")?1:0}function io(e,t){if(!e||e==="none")return ro(t);const n=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let o,r;if(n)o=Mu,r=n;else{const a=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);o=Pu,r=a}if(!r)return ro(t);const i=o[t],s=r[1].split(",").map(Vu);return typeof i=="function"?i(s):s[i]}const ku=(e,t)=>{const{transform:n="none"}=getComputedStyle(e);return io(n,t)};function Vu(e){return parseFloat(e.trim())}const rt=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],it=new Set(rt),ki=e=>e===tt||e===k,Eu=new Set(["x","y","z"]),Du=rt.filter(e=>!Eu.has(e));function Fu(e){const t=[];return Du.forEach(n=>{const o=e.getValue(n);o!==void 0&&(t.push([n,o.get()]),o.set(n.startsWith("scale")?1:0))}),t}const Be={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:(e,{transform:t})=>io(t,"x"),y:(e,{transform:t})=>io(t,"y")};Be.translateX=Be.x,Be.translateY=Be.y;const qe=new Set;let so=!1,ao=!1,lo=!1;function Vi(){if(ao){const e=Array.from(qe).filter(o=>o.needsMeasurement),t=new Set(e.map(o=>o.element)),n=new Map;t.forEach(o=>{const r=Fu(o);r.length&&(n.set(o,r),o.render())}),e.forEach(o=>o.measureInitialState()),t.forEach(o=>{o.render();const r=n.get(o);r&&r.forEach(([i,s])=>{o.getValue(i)?.set(s)})}),e.forEach(o=>o.measureEndState()),e.forEach(o=>{o.suspendedScrollY!==void 0&&window.scrollTo(0,o.suspendedScrollY)})}ao=!1,so=!1,qe.forEach(e=>e.complete(lo)),qe.clear()}function Ei(){qe.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(ao=!0)})}function Au(){lo=!0,Ei(),Vi(),lo=!1}class co{constructor(t,n,o,r,i,s=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=n,this.name=o,this.motionValue=r,this.element=i,this.isAsync=s}scheduleResolve(){this.state="scheduled",this.isAsync?(qe.add(this),so||(so=!0,U.read(Ei),U.resolveKeyframes(Vi))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:n,element:o,motionValue:r}=this;if(t[0]===null){const i=r?.get(),s=t[t.length-1];if(i!==void 0)t[0]=i;else if(o&&n){const a=o.readValue(n,s);a!=null&&(t[0]=a)}t[0]===void 0&&(t[0]=s),r&&i===void 0&&r.set(t[0])}$u(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),qe.delete(this)}cancel(){this.state==="scheduled"&&(qe.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const Iu=e=>e.startsWith("--");function Lu(e,t,n){Iu(t)?e.style.setProperty(t,n):e.style[t]=n}const Ru=In(()=>window.ScrollTimeline!==void 0),_u={};function Bu(e,t){const n=In(e);return()=>_u[t]??n()}const Di=Bu(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),kt=([e,t,n,o])=>`cubic-bezier(${e}, ${t}, ${n}, ${o})`,Fi={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:kt([0,.65,.55,1]),circOut:kt([.55,0,1,.45]),backIn:kt([.31,.01,.66,-.59]),backOut:kt([.33,1.53,.69,.99])};function Ai(e,t){if(e)return typeof e=="function"?Di()?xi(e,t):"ease-out":oi(e)?kt(e):Array.isArray(e)?e.map(n=>Ai(n,t)||Fi.easeOut):Fi[e]}function Nu(e,t,n,{delay:o=0,duration:r=300,repeat:i=0,repeatType:s="loop",ease:a="easeOut",times:l}={},c=void 0){const d={[t]:n};l&&(d.offset=l);const u=Ai(a,r);Array.isArray(u)&&(d.easing=u);const h={delay:o,duration:r,easing:Array.isArray(u)?"linear":u,fill:"both",iterations:i+1,direction:s==="reverse"?"alternate":"normal"};return c&&(h.pseudoElement=c),e.animate(d,h)}function Ii(e){return typeof e=="function"&&"applyToOptions"in e}function zu({type:e,...t}){return Ii(e)&&Di()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}class Ou extends eo{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,this.manualStartTime=null,!t)return;const{element:n,name:o,keyframes:r,pseudoElement:i,allowFlatten:s=!1,finalKeyframe:a,onComplete:l}=t;this.isPseudoElement=!!i,this.allowFlatten=s,this.options=t,Ee(typeof t.type!="string",`Mini animate() doesn't support "type" as a string.`,"mini-spring");const c=zu(t);this.animation=Nu(n,o,r,c,i),c.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!i){const d=Qn(r,this.options,a,this.speed);this.updateMotionValue?this.updateMotionValue(d):Lu(n,o,d),this.animation.cancel()}l?.(),this.notifyFinished()}}play(){this.isStopped||(this.manualStartTime=null,this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){this.animation.finish?.()}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;const{state:t}=this;t==="idle"||t==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){this.isPseudoElement||this.animation.commitStyles?.()}get duration(){const t=this.animation.effect?.getComputedTiming?.().duration||0;return pe(Number(t))}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+pe(t)}get time(){return pe(Number(this.animation.currentTime)||0)}set time(t){this.manualStartTime=null,this.finishedTime=null,this.animation.currentTime=Pe(t)}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return this.manualStartTime??Number(this.animation.startTime)}set startTime(t){this.manualStartTime=this.animation.startTime=t}attachTimeline({timeline:t,observe:n}){return this.allowFlatten&&this.animation.effect?.updateTiming({easing:"linear"}),this.animation.onfinish=null,t&&Ru()?(this.animation.timeline=t,me):n(this)}}const Li={anticipate:Qr,backInOut:Jr,circInOut:ti};function Hu(e){return e in Li}function ju(e){typeof e.ease=="string"&&Hu(e.ease)&&(e.ease=Li[e.ease])}const uo=10;class Gu extends Ou{constructor(t){ju(t),Ti(t),super(t),t.startTime!==void 0&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){const{motionValue:n,onUpdate:o,onComplete:r,element:i,...s}=this.options;if(!n)return;if(t!==void 0){n.set(t);return}const a=new to({...s,autoplay:!1}),l=Math.max(uo,le.now()-this.startTime),c=$e(0,uo,l-uo);n.setWithVelocity(a.sample(Math.max(0,l-c)).value,a.sample(l).value,c),a.stop()}}const Ri=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(_e.test(e)||e==="0")&&!e.startsWith("url("));function Uu(e){const t=e[0];if(e.length===1)return!0;for(let n=0;n<e.length;n++)if(e[n]!==t)return!0}function Ku(e,t,n,o){const r=e[0];if(r===null)return!1;if(t==="display"||t==="visibility")return!0;const i=e[e.length-1],s=Ri(r,t),a=Ri(i,t);return et(s===a,`You are trying to animate ${t} from "${r}" to "${i}". "${s?i:r}" is not an animatable value.`,"value-not-animatable"),!s||!a?!1:Uu(e)||(n==="spring"||Ii(n))&&o}function fo(e){e.duration=0,e.type="keyframes"}const Wu=new Set(["opacity","clipPath","filter","transform"]),qu=In(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function Yu(e){const{motionValue:t,name:n,repeatDelay:o,repeatType:r,damping:i,type:s}=e;if(!(t?.owner?.current instanceof HTMLElement))return!1;const{onUpdate:l,transformTemplate:c}=t.owner.getProps();return qu()&&n&&Wu.has(n)&&(n!=="transform"||!c)&&!l&&!o&&r!=="mirror"&&i!==0&&s!=="inertia"}const Xu=40;class Zu extends eo{constructor({autoplay:t=!0,delay:n=0,type:o="keyframes",repeat:r=0,repeatDelay:i=0,repeatType:s="loop",keyframes:a,name:l,motionValue:c,element:d,...u}){super(),this.stop=()=>{this._animation&&(this._animation.stop(),this.stopTimeline?.()),this.keyframeResolver?.cancel()},this.createdAt=le.now();const h={autoplay:t,delay:n,type:o,repeat:r,repeatDelay:i,repeatType:s,name:l,motionValue:c,element:d,...u},f=d?.KeyframeResolver||co;this.keyframeResolver=new f(a,(v,y,b)=>this.onKeyframesResolved(v,y,h,!b),l,c,d),this.keyframeResolver?.scheduleResolve()}onKeyframesResolved(t,n,o,r){this.keyframeResolver=void 0;const{name:i,type:s,velocity:a,delay:l,isHandoff:c,onUpdate:d}=o;this.resolvedAt=le.now(),Ku(t,i,s,a)||((De.instantAnimations||!l)&&d?.(Qn(t,o,n)),t[0]=t[t.length-1],fo(o),o.repeat=0);const h={startTime:r?this.resolvedAt?this.resolvedAt-this.createdAt>Xu?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:n,...o,keyframes:t},f=!c&&Yu(h)?new Gu({...h,element:h.motionValue.owner.current}):new to(h);f.finished.then(()=>this.notifyFinished()).catch(me),this.pendingTimeline&&(this.stopTimeline=f.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=f}get finished(){return this._animation?this.animation.finished:this._finished}then(t,n){return this.finished.finally(t).then(()=>{})}get animation(){return this._animation||(this.keyframeResolver?.resume(),Au()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(t){this.animation.time=t}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){this._animation&&this.animation.cancel(),this.keyframeResolver?.cancel()}}const Ju=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function Qu(e){const t=Ju.exec(e);if(!t)return[,];const[,n,o,r]=t;return[`--${n??o}`,r]}const ed=4;function _i(e,t,n=1){Ee(n<=ed,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`,"max-css-var-depth");const[o,r]=Qu(e);if(!o)return;const i=window.getComputedStyle(t).getPropertyValue(o);if(i){const s=i.trim();return jr(s)?parseFloat(s):s}return zn(r)?_i(r,t,n+1):r}function ho(e,t){return e?.[t]??e?.default??e}const td={type:"spring",stiffness:500,damping:25,restSpeed:10},nd=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),od={type:"keyframes",duration:.8},rd={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},id=(e,{keyframes:t})=>t.length>2?od:it.has(e)?e.startsWith("scale")?nd(t[1]):td:rd;function sd({when:e,delay:t,delayChildren:n,staggerChildren:o,staggerDirection:r,repeat:i,repeatType:s,repeatDelay:a,from:l,elapsed:c,...d}){return!!Object.keys(d).length}const ad=e=>e!==null;function ld(e,{repeat:t,repeatType:n="loop"},o){const r=e.filter(ad),i=t&&n!=="loop"&&t%2===1?0:r.length-1;return r[i]}function Bi(e,t,n,o=0,r=1){const i=Array.from(e).sort((c,d)=>c.sortNodePosition(d)).indexOf(t),s=e.size,a=(s-1)*o;return typeof n=="function"?n(i,s):r===1?i*o:a-i*o}const mo=(e,t,n,o={},r,i)=>s=>{const a=ho(o,e)||{},l=a.delay||o.delay||0;let{elapsed:c=0}=o;c=c-Pe(l);const d={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...a,delay:-c,onUpdate:h=>{t.set(h),a.onUpdate&&a.onUpdate(h)},onComplete:()=>{s(),a.onComplete&&a.onComplete()},name:e,motionValue:t,element:i?void 0:r};sd(a)||Object.assign(d,id(e,d)),d.duration&&(d.duration=Pe(d.duration)),d.repeatDelay&&(d.repeatDelay=Pe(d.repeatDelay)),d.from!==void 0&&(d.keyframes[0]=d.from);let u=!1;if((d.type===!1||d.duration===0&&!d.repeatDelay)&&(fo(d),d.delay===0&&(u=!0)),(De.instantAnimations||De.skipAnimations)&&(u=!0,fo(d),d.delay=0),d.allowFlatten=!a.type&&!a.ease,u&&!i&&t.get()!==void 0){const h=ld(d.keyframes,a);if(h!==void 0){U.update(()=>{d.onUpdate(h),d.onComplete()});return}}return a.isSync?new to(d):new Zu(d)},Ni=new Set(["width","height","top","left","right","bottom",...rt]),zi=30,cd=e=>!isNaN(parseFloat(e));class ud{constructor(t,n={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=o=>{const r=le.now();if(this.updatedAt!==r&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(o),this.current!==this.prev&&(this.events.change?.notify(this.current),this.dependents))for(const i of this.dependents)i.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=n.owner}setCurrent(t){this.current=t,this.updatedAt=le.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=cd(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return process.env.NODE_ENV!=="production"&&Rn(!1,'value.onChange(callback) is deprecated. Switch to value.on("change", callback).'),this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new Ln);const o=this.events[t].add(n);return t==="change"?()=>{o(),U.read(()=>{this.events.change.getSize()||this.stop()})}:o}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t)}setWithVelocity(t,n,o){this.set(n),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-o}jump(t,n=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){this.events.change?.notify(this.current)}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t)}removeDependent(t){this.dependents&&this.dependents.delete(t)}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const t=le.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>zi)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,zi);return Kr(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.dependents?.clear(),this.events.destroy?.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function st(e,t){return new ud(e,t)}function Oi(e){const t=[{},{}];return e?.values.forEach((n,o)=>{t[0][o]=n.get(),t[1][o]=n.getVelocity()}),t}function po(e,t,n,o){if(typeof t=="function"){const[r,i]=Oi(o);t=t(n!==void 0?n:e.custom,r,i)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[r,i]=Oi(o);t=t(n!==void 0?n:e.custom,r,i)}return t}function at(e,t,n){const o=e.getProps();return po(o,t,n!==void 0?n:o.custom,e)}const go=e=>Array.isArray(e);function dd(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,st(n))}function fd(e){return go(e)?e[e.length-1]||0:e}function hd(e,t){const n=at(e,t);let{transitionEnd:o={},transition:r={},...i}=n||{};i={...i,...o};for(const s in i){const a=fd(i[s]);dd(e,s,a)}}const ie=e=>!!(e&&e.getVelocity);function md(e){return!!(ie(e)&&e.add)}function vo(e,t){const n=e.getValue("willChange");if(md(n))return n.add(t);if(!n&&De.WillChange){const o=new De.WillChange("auto");e.addValue("willChange",o),o.add(t)}}function yo(e){return e.replace(/([A-Z])/g,t=>`-${t.toLowerCase()}`)}const Hi="data-"+yo("framerAppearId");function ji(e){return e.props[Hi]}function pd({protectedKeys:e,needsAnimating:t},n){const o=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,o}function Gi(e,t,{delay:n=0,transitionOverride:o,type:r}={}){let{transition:i=e.getDefaultTransition(),transitionEnd:s,...a}=t;o&&(i=o);const l=[],c=r&&e.animationState&&e.animationState.getState()[r];for(const d in a){const u=e.getValue(d,e.latestValues[d]??null),h=a[d];if(h===void 0||c&&pd(c,d))continue;const f={delay:n,...ho(i||{},d)},v=u.get();if(v!==void 0&&!u.isAnimating&&!Array.isArray(h)&&h===v&&!f.velocity)continue;let y=!1;if(window.MotionHandoffAnimation){const w=ji(e);if(w){const T=window.MotionHandoffAnimation(w,d,U);T!==null&&(f.startTime=T,y=!0)}}vo(e,d),u.start(mo(d,u,h,e.shouldReduceMotion&&Ni.has(d)?{type:!1}:f,e,y));const b=u.animation;b&&l.push(b)}return s&&Promise.all(l).then(()=>{U.update(()=>{s&&hd(e,s)})}),l}function wo(e,t,n={}){const o=at(e,t,n.type==="exit"?e.presenceContext?.custom:void 0);let{transition:r=e.getDefaultTransition()||{}}=o||{};n.transitionOverride&&(r=n.transitionOverride);const i=o?()=>Promise.all(Gi(e,o,n)):()=>Promise.resolve(),s=e.variantChildren&&e.variantChildren.size?(l=0)=>{const{delayChildren:c=0,staggerChildren:d,staggerDirection:u}=r;return gd(e,t,l,c,d,u,n)}:()=>Promise.resolve(),{when:a}=r;if(a){const[l,c]=a==="beforeChildren"?[i,s]:[s,i];return l().then(()=>c())}else return Promise.all([i(),s(n.delay)])}function gd(e,t,n=0,o=0,r=0,i=1,s){const a=[];for(const l of e.variantChildren)l.notify("AnimationStart",t),a.push(wo(l,t,{...s,delay:n+(typeof o=="function"?0:o)+Bi(e.variantChildren,l,o,r,i)}).then(()=>l.notify("AnimationComplete",t)));return Promise.all(a)}function vd(e,t,n={}){e.notify("AnimationStart",t);let o;if(Array.isArray(t)){const r=t.map(i=>wo(e,i,n));o=Promise.all(r)}else if(typeof t=="string")o=wo(e,t,n);else{const r=typeof t=="function"?at(e,t,n.custom):t;o=Promise.all(Gi(e,r,n))}return o.then(()=>{e.notify("AnimationComplete",t)})}const yd={test:e=>e==="auto",parse:e=>e},Ui=e=>t=>t.test(e),Ki=[tt,k,Me,Re,Uc,Gc,yd],Wi=e=>Ki.find(Ui(e));function wd(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||Ur(e):!0}const bd=new Set(["brightness","contrast","saturate","opacity"]);function xd(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[o]=n.match(On)||[];if(!o)return e;const r=n.replace(o,"");let i=bd.has(t)?1:0;return o!==n&&(i*=100),t+"("+i+r+")"}const Sd=/\b([a-z-]*)\(.*?\)/gu,bo={..._e,getAnimatableNone:e=>{const t=e.match(Sd);return t?t.map(xd).join(" "):e}},qi={...tt,transform:Math.round},xo={borderWidth:k,borderTopWidth:k,borderRightWidth:k,borderBottomWidth:k,borderLeftWidth:k,borderRadius:k,radius:k,borderTopLeftRadius:k,borderTopRightRadius:k,borderBottomRightRadius:k,borderBottomLeftRadius:k,width:k,maxWidth:k,height:k,maxHeight:k,top:k,right:k,bottom:k,left:k,inset:k,insetBlock:k,insetBlockStart:k,insetBlockEnd:k,insetInline:k,insetInlineStart:k,insetInlineEnd:k,padding:k,paddingTop:k,paddingRight:k,paddingBottom:k,paddingLeft:k,paddingBlock:k,paddingBlockStart:k,paddingBlockEnd:k,paddingInline:k,paddingInlineStart:k,paddingInlineEnd:k,margin:k,marginTop:k,marginRight:k,marginBottom:k,marginLeft:k,marginBlock:k,marginBlockStart:k,marginBlockEnd:k,marginInline:k,marginInlineStart:k,marginInlineEnd:k,backgroundPositionX:k,backgroundPositionY:k,...{rotate:Re,rotateX:Re,rotateY:Re,rotateZ:Re,scale:qt,scaleX:qt,scaleY:qt,scaleZ:qt,skew:Re,skewX:Re,skewY:Re,distance:k,translateX:k,translateY:k,translateZ:k,x:k,y:k,z:k,perspective:k,transformPerspective:k,opacity:Tt,originX:di,originY:di,originZ:k},zIndex:qi,fillOpacity:Tt,strokeOpacity:Tt,numOctaves:qi},Cd={...xo,color:J,backgroundColor:J,outlineColor:J,fill:J,stroke:J,borderColor:J,borderTopColor:J,borderRightColor:J,borderBottomColor:J,borderLeftColor:J,filter:bo,WebkitFilter:bo},Yi=e=>Cd[e];function Xi(e,t){let n=Yi(e);return n!==bo&&(n=_e),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const Td=new Set(["auto","none","0"]);function $d(e,t,n){let o=0,r;for(;o<e.length&&!r;){const i=e[o];typeof i=="string"&&!Td.has(i)&&Mt(i).values.length&&(r=e[o]),o++}if(r&&n)for(const i of t)e[i]=Xi(n,r)}class Pd extends co{constructor(t,n,o,r,i){super(t,n,o,r,i,!0)}readKeyframes(){const{unresolvedKeyframes:t,element:n,name:o}=this;if(!n||!n.current)return;super.readKeyframes();for(let d=0;d<t.length;d++){let u=t[d];if(typeof u=="string"&&(u=u.trim(),zn(u))){const h=_i(u,n.current);h!==void 0&&(t[d]=h),d===t.length-1&&(this.finalKeyframe=u)}}if(this.resolveNoneKeyframes(),!Ni.has(o)||t.length!==2)return;const[r,i]=t,s=Wi(r),a=Wi(i),l=ci(r),c=ci(i);if(l!==c&&Be[o]){this.needsMeasurement=!0;return}if(s!==a)if(ki(s)&&ki(a))for(let d=0;d<t.length;d++){const u=t[d];typeof u=="string"&&(t[d]=parseFloat(u))}else Be[o]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){const{unresolvedKeyframes:t,name:n}=this,o=[];for(let r=0;r<t.length;r++)(t[r]===null||wd(t[r]))&&o.push(r);o.length&&$d(t,o,n)}measureInitialState(){const{element:t,unresolvedKeyframes:n,name:o}=this;if(!t||!t.current)return;o==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=Be[o](t.measureViewportBox(),window.getComputedStyle(t.current)),n[0]=this.measuredOrigin;const r=n[n.length-1];r!==void 0&&t.getValue(o,r).jump(r,!1)}measureEndState(){const{element:t,name:n,unresolvedKeyframes:o}=this;if(!t||!t.current)return;const r=t.getValue(n);r&&r.jump(this.measuredOrigin,!1);const i=o.length-1,s=o[i];o[i]=Be[n](t.measureViewportBox(),window.getComputedStyle(t.current)),s!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=s),this.removedTransforms?.length&&this.removedTransforms.forEach(([a,l])=>{t.getValue(a).set(l)}),this.resolveNoneKeyframes()}}function Md(e,t,n){if(e instanceof EventTarget)return[e];if(typeof e=="string"){let o=document;const r=n?.[e]??o.querySelectorAll(e);return r?Array.from(r):[]}return Array.from(e)}const Zi=(e,t)=>t&&typeof e=="number"?t.transform(e):e;function Ji(e){return Gr(e)&&"offsetHeight"in e}const{schedule:So}=si(queueMicrotask,!1),we={x:!1,y:!1};function Qi(){return we.x||we.y}function kd(e){return e==="x"||e==="y"?we[e]?null:(we[e]=!0,()=>{we[e]=!1}):we.x||we.y?null:(we.x=we.y=!0,()=>{we.x=we.y=!1})}function es(e,t){const n=Md(e),o=new AbortController,r={passive:!0,...t,signal:o.signal};return[n,r,()=>o.abort()]}function ts(e){return!(e.pointerType==="touch"||Qi())}function Vd(e,t,n={}){const[o,r,i]=es(e,n),s=a=>{if(!ts(a))return;const{target:l}=a,c=t(l,a);if(typeof c!="function"||!l)return;const d=u=>{ts(u)&&(c(u),l.removeEventListener("pointerleave",d))};l.addEventListener("pointerleave",d,r)};return o.forEach(a=>{a.addEventListener("pointerenter",s,r)}),i}const ns=(e,t)=>t?e===t?!0:ns(e,t.parentElement):!1,Co=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1,Ed=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function os(e){return Ed.has(e.tagName)||e.isContentEditable===!0}const Jt=new WeakSet;function rs(e){return t=>{t.key==="Enter"&&e(t)}}function To(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}const Dd=(e,t)=>{const n=e.currentTarget;if(!n)return;const o=rs(()=>{if(Jt.has(n))return;To(n,"down");const r=rs(()=>{To(n,"up")}),i=()=>To(n,"cancel");n.addEventListener("keyup",r,t),n.addEventListener("blur",i,t)});n.addEventListener("keydown",o,t),n.addEventListener("blur",()=>n.removeEventListener("keydown",o),t)};function is(e){return Co(e)&&!Qi()}function Fd(e,t,n={}){const[o,r,i]=es(e,n),s=a=>{const l=a.currentTarget;if(!is(a))return;Jt.add(l);const c=t(l,a),d=(f,v)=>{window.removeEventListener("pointerup",u),window.removeEventListener("pointercancel",h),Jt.has(l)&&Jt.delete(l),is(f)&&typeof c=="function"&&c(f,{success:v})},u=f=>{d(f,l===window||l===document||n.useGlobalTarget||ns(l,f.target))},h=f=>{d(f,!1)};window.addEventListener("pointerup",u,r),window.addEventListener("pointercancel",h,r)};return o.forEach(a=>{(n.useGlobalTarget?window:a).addEventListener("pointerdown",s,r),Ji(a)&&(a.addEventListener("focus",c=>Dd(c,r)),!os(a)&&!a.hasAttribute("tabindex")&&(a.tabIndex=0))}),i}function ss(e){return Gr(e)&&"ownerSVGElement"in e}function Ad(e){return ss(e)&&e.tagName==="svg"}const Id=[...Ki,J,_e],Ld=e=>Id.find(Ui(e)),as=()=>({translate:0,scale:1,origin:0,originPoint:0}),lt=()=>({x:as(),y:as()}),ls=()=>({min:0,max:0}),ee=()=>({x:ls(),y:ls()}),$o={current:null},cs={current:!1},Rd=typeof window<"u";function _d(){if(cs.current=!0,!!Rd)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>$o.current=e.matches;e.addEventListener("change",t),t()}else $o.current=!1}const Bd=new WeakMap;function Qt(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function Vt(e){return typeof e=="string"||Array.isArray(e)}const Po=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],Mo=["initial",...Po];function en(e){return Qt(e.animate)||Mo.some(t=>Vt(e[t]))}function us(e){return!!(en(e)||e.variants)}function Nd(e,t,n){for(const o in t){const r=t[o],i=n[o];if(ie(r))e.addValue(o,r);else if(ie(i))e.addValue(o,st(r,{owner:e}));else if(i!==r)if(e.hasValue(o)){const s=e.getValue(o);s.liveStyle===!0?s.jump(r):s.hasAnimated||s.set(r)}else{const s=e.getStaticValue(o);e.addValue(o,st(s!==void 0?s:r,{owner:e}))}}for(const o in n)t[o]===void 0&&e.removeValue(o);return t}const ds=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];let tn={};function fs(e){tn=e}function zd(){return tn}class Od{scrapeMotionValuesFromProps(t,n,o){return{}}constructor({parent:t,props:n,presenceContext:o,reducedMotionConfig:r,blockInitialAnimation:i,visualState:s},a={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=co,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const h=le.now();this.renderScheduledAt<h&&(this.renderScheduledAt=h,U.render(this.render,!1,!0))};const{latestValues:l,renderState:c}=s;this.latestValues=l,this.baseTarget={...l},this.initialValues=n.initial?{...l}:{},this.renderState=c,this.parent=t,this.props=n,this.presenceContext=o,this.depth=t?t.depth+1:0,this.reducedMotionConfig=r,this.options=a,this.blockInitialAnimation=!!i,this.isControllingVariants=en(n),this.isVariantNode=us(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:d,...u}=this.scrapeMotionValuesFromProps(n,{},this);for(const h in u){const f=u[h];l[h]!==void 0&&ie(f)&&f.set(l[h])}}mount(t){this.current=t,Bd.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((n,o)=>this.bindToMotionValue(o,n)),this.reducedMotionConfig==="never"?this.shouldReduceMotion=!1:this.reducedMotionConfig==="always"?this.shouldReduceMotion=!0:(cs.current||_d(),this.shouldReduceMotion=$o.current),process.env.NODE_ENV!=="production"&&Rn(this.shouldReduceMotion!==!0,"You have Reduced Motion enabled on your device. Animations may not appear as expected.","reduced-motion-disabled"),this.parent?.addChild(this),this.update(this.props,this.presenceContext)}unmount(){this.projection&&this.projection.unmount(),Le(this.notifyUpdate),Le(this.render),this.valueSubscriptions.forEach(t=>t()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent?.removeChild(this);for(const t in this.events)this.events[t].clear();for(const t in this.features){const n=this.features[t];n&&(n.unmount(),n.isMounted=!1)}this.current=null}addChild(t){this.children.add(t),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(t)}removeChild(t){this.children.delete(t),this.enteringChildren&&this.enteringChildren.delete(t)}bindToMotionValue(t,n){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();const o=it.has(t);o&&this.onBindTransform&&this.onBindTransform();const r=n.on("change",s=>{this.latestValues[t]=s,this.props.onUpdate&&U.preRender(this.notifyUpdate),o&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let i;typeof window<"u"&&window.MotionCheckAppearSync&&(i=window.MotionCheckAppearSync(this,t,n)),this.valueSubscriptions.set(t,()=>{r(),i&&i(),n.owner&&n.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in tn){const n=tn[t];if(!n)continue;const{isEnabled:o,Feature:r}=n;if(!this.features[t]&&r&&o(this.props)&&(this.features[t]=new r(this)),this.features[t]){const i=this.features[t];i.isMounted?i.update():(i.mount(),i.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):ee()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let o=0;o<ds.length;o++){const r=ds[o];this.propEventSubscriptions[r]&&(this.propEventSubscriptions[r](),delete this.propEventSubscriptions[r]);const i="on"+r,s=t[i];s&&(this.propEventSubscriptions[r]=this.on(r,s))}this.prevMotionValues=Nd(this,this.scrapeMotionValuesFromProps(t,this.prevProps||{},this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(t){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(t),()=>n.variantChildren.delete(t)}addValue(t,n){const o=this.values.get(t);n!==o&&(o&&this.removeValue(t),this.bindToMotionValue(t,n),this.values.set(t,n),this.latestValues[t]=n.get())}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let o=this.values.get(t);return o===void 0&&n!==void 0&&(o=st(n===null?void 0:n,{owner:this}),this.addValue(t,o)),o}readValue(t,n){let o=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options);return o!=null&&(typeof o=="string"&&(jr(o)||Ur(o))?o=parseFloat(o):!Ld(o)&&_e.test(n)&&(o=Xi(t,n)),this.setBaseTarget(t,ie(o)?o.get():o)),ie(o)?o.get():o}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){const{initial:n}=this.props;let o;if(typeof n=="string"||typeof n=="object"){const i=po(this.props,n,this.presenceContext?.custom);i&&(o=i[t])}if(n&&o!==void 0)return o;const r=this.getBaseTargetFromProps(this.props,t);return r!==void 0&&!ie(r)?r:this.initialValues[t]!==void 0&&o===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new Ln),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}scheduleRenderMicrotask(){So.render(this.render)}}class Ne{constructor(t){this.isMounted=!1,this.node=t}update(){}}class hs extends Od{constructor(){super(...arguments),this.KeyframeResolver=Pd}sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){const o=t.style;return o?o[n]:void 0}removeValueFromRenderState(t,{vars:n,style:o}){delete n[t],delete o[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;ie(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}function ms({top:e,left:t,right:n,bottom:o}){return{x:{min:t,max:n},y:{min:e,max:o}}}function Hd({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function jd(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),o=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:o.y,right:o.x}}function ko(e){return e===void 0||e===1}function Vo({scale:e,scaleX:t,scaleY:n}){return!ko(e)||!ko(t)||!ko(n)}function Ye(e){return Vo(e)||ps(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function ps(e){return gs(e.x)||gs(e.y)}function gs(e){return e&&e!=="0%"}function nn(e,t,n){const o=e-n,r=t*o;return n+r}function vs(e,t,n,o,r){return r!==void 0&&(e=nn(e,r,o)),nn(e,n,o)+t}function Eo(e,t=0,n=1,o,r){e.min=vs(e.min,t,n,o,r),e.max=vs(e.max,t,n,o,r)}function ys(e,{x:t,y:n}){Eo(e.x,t.translate,t.scale,t.originPoint),Eo(e.y,n.translate,n.scale,n.originPoint)}const ws=.999999999999,bs=1.0000000000001;function Gd(e,t,n,o=!1){const r=n.length;if(!r)return;t.x=t.y=1;let i,s;for(let a=0;a<r;a++){i=n[a],s=i.projectionDelta;const{visualElement:l}=i.options;l&&l.props.style&&l.props.style.display==="contents"||(o&&i.options.layoutScroll&&i.scroll&&i!==i.root&&ut(e,{x:-i.scroll.offset.x,y:-i.scroll.offset.y}),s&&(t.x*=s.x.scale,t.y*=s.y.scale,ys(e,s)),o&&Ye(i.latestValues)&&ut(e,i.latestValues))}t.x<bs&&t.x>ws&&(t.x=1),t.y<bs&&t.y>ws&&(t.y=1)}function ct(e,t){e.min=e.min+t,e.max=e.max+t}function xs(e,t,n,o,r=.5){const i=q(e.min,e.max,r);Eo(e,t,n,i,o)}function ut(e,t){xs(e.x,t.x,t.scaleX,t.scale,t.originX),xs(e.y,t.y,t.scaleY,t.scale,t.originY)}function Ss(e,t){return ms(jd(e.getBoundingClientRect(),t))}function Ud(e,t,n){const o=Ss(e,n),{scroll:r}=t;return r&&(ct(o.x,r.offset.x),ct(o.y,r.offset.y)),o}const Kd={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},Wd=rt.length;function qd(e,t,n){let o="",r=!0;for(let i=0;i<Wd;i++){const s=rt[i],a=e[s];if(a===void 0)continue;let l=!0;if(typeof a=="number"?l=a===(s.startsWith("scale")?1:0):l=parseFloat(a)===0,!l||n){const c=Zi(a,xo[s]);if(!l){r=!1;const d=Kd[s]||s;o+=`${d}(${c}) `}n&&(t[s]=c)}}return o=o.trim(),n?o=n(t,r?"":o):r&&(o="none"),o}function Do(e,t,n){const{style:o,vars:r,transformOrigin:i}=e;let s=!1,a=!1;for(const l in t){const c=t[l];if(it.has(l)){s=!0;continue}else if(li(l)){r[l]=c;continue}else{const d=Zi(c,xo[l]);l.startsWith("origin")?(a=!0,i[l]=d):o[l]=d}}if(t.transform||(s||n?o.transform=qd(t,e.transform,n):o.transform&&(o.transform="none")),a){const{originX:l="50%",originY:c="50%",originZ:d=0}=i;o.transformOrigin=`${l} ${c} ${d}`}}function Cs(e,{style:t,vars:n},o,r){const i=e.style;let s;for(s in t)i[s]=t[s];r?.applyProjectionStyles(i,o);for(s in n)i.setProperty(s,n[s])}function Ts(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const Et={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(k.test(e))e=parseFloat(e);else return e;const n=Ts(e,t.target.x),o=Ts(e,t.target.y);return`${n}% ${o}%`}},Yd={correct:(e,{treeScale:t,projectionDelta:n})=>{const o=e,r=_e.parse(e);if(r.length>5)return o;const i=_e.createTransformer(e),s=typeof r[0]!="number"?1:0,a=n.x.scale*t.x,l=n.y.scale*t.y;r[0+s]/=a,r[1+s]/=l;const c=q(a,l,.5);return typeof r[2+s]=="number"&&(r[2+s]/=c),typeof r[3+s]=="number"&&(r[3+s]/=c),i(r)}},Fo={borderRadius:{...Et,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:Et,borderTopRightRadius:Et,borderBottomLeftRadius:Et,borderBottomRightRadius:Et,boxShadow:Yd};function $s(e,{layout:t,layoutId:n}){return it.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!Fo[e]||e==="opacity")}function Ao(e,t,n){const o=e.style,r=t?.style,i={};if(!o)return i;for(const s in o)(ie(o[s])||r&&ie(r[s])||$s(s,e)||n?.getValue(s)?.liveStyle!==void 0)&&(i[s]=o[s]);return i}function Xd(e){return window.getComputedStyle(e)}class Zd extends hs{constructor(){super(...arguments),this.type="html",this.renderInstance=Cs}readValueFromInstance(t,n){if(it.has(n))return this.projection?.isProjecting?ro(n):ku(t,n);{const o=Xd(t),r=(li(n)?o.getPropertyValue(n):o[n])||0;return typeof r=="string"?r.trim():r}}measureInstanceViewportBox(t,{transformPagePoint:n}){return Ss(t,n)}build(t,n,o){Do(t,n,o.transformTemplate)}scrapeMotionValuesFromProps(t,n,o){return Ao(t,n,o)}}const Jd={offset:"stroke-dashoffset",array:"stroke-dasharray"},Qd={offset:"strokeDashoffset",array:"strokeDasharray"};function ef(e,t,n=1,o=0,r=!0){e.pathLength=1;const i=r?Jd:Qd;e[i.offset]=k.transform(-o);const s=k.transform(t),a=k.transform(n);e[i.array]=`${s} ${a}`}const tf=["offsetDistance","offsetPath","offsetRotate","offsetAnchor"];function Ps(e,{attrX:t,attrY:n,attrScale:o,pathLength:r,pathSpacing:i=1,pathOffset:s=0,...a},l,c,d){if(Do(e,a,c),l){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:u,style:h}=e;u.transform&&(h.transform=u.transform,delete u.transform),(h.transform||u.transformOrigin)&&(h.transformOrigin=u.transformOrigin??"50% 50%",delete u.transformOrigin),h.transform&&(h.transformBox=d?.transformBox??"fill-box",delete u.transformBox);for(const f of tf)u[f]!==void 0&&(h[f]=u[f],delete u[f]);t!==void 0&&(u.x=t),n!==void 0&&(u.y=n),o!==void 0&&(u.scale=o),r!==void 0&&ef(u,r,i,s,!1)}const Ms=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]),ks=e=>typeof e=="string"&&e.toLowerCase()==="svg";function nf(e,t,n,o){Cs(e,t,void 0,o);for(const r in t.attrs)e.setAttribute(Ms.has(r)?r:yo(r),t.attrs[r])}function Vs(e,t,n){const o=Ao(e,t,n);for(const r in e)if(ie(e[r])||ie(t[r])){const i=rt.indexOf(r)!==-1?"attr"+r.charAt(0).toUpperCase()+r.substring(1):r;o[i]=e[r]}return o}class of extends hs{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=ee}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(it.has(n)){const o=Yi(n);return o&&o.default||0}return n=Ms.has(n)?n:yo(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,o){return Vs(t,n,o)}build(t,n,o){Ps(t,n,this.isSVGTag,o.transformTemplate,o.style)}renderInstance(t,n,o,r){nf(t,n,o,r)}mount(t){this.isSVGTag=ks(t.tagName),super.mount(t)}}const rf=Mo.length;function Es(e){if(!e)return;if(!e.isControllingVariants){const n=e.parent?Es(e.parent)||{}:{};return e.props.initial!==void 0&&(n.initial=e.props.initial),n}const t={};for(let n=0;n<rf;n++){const o=Mo[n],r=e.props[o];(Vt(r)||r===!1)&&(t[o]=r)}return t}function Ds(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let o=0;o<n;o++)if(t[o]!==e[o])return!1;return!0}const sf=[...Po].reverse(),af=Po.length;function lf(e){return t=>Promise.all(t.map(({animation:n,options:o})=>vd(e,n,o)))}function cf(e){let t=lf(e),n=Fs(),o=!0;const r=l=>(c,d)=>{const u=at(e,d,l==="exit"?e.presenceContext?.custom:void 0);if(u){const{transition:h,transitionEnd:f,...v}=u;c={...c,...v,...f}}return c};function i(l){t=l(e)}function s(l){const{props:c}=e,d=Es(e.parent)||{},u=[],h=new Set;let f={},v=1/0;for(let b=0;b<af;b++){const w=sf[b],T=n[w],C=c[w]!==void 0?c[w]:d[w],M=Vt(C),x=w===l?T.isActive:null;x===!1&&(v=b);let P=C===d[w]&&C!==c[w]&&M;if(P&&o&&e.manuallyAnimateOnMount&&(P=!1),T.protectedKeys={...f},!T.isActive&&x===null||!C&&!T.prevProp||Qt(C)||typeof C=="boolean")continue;const V=uf(T.prevProp,C);let $=V||w===l&&T.isActive&&!P&&M||b>v&&M,F=!1;const D=Array.isArray(C)?C:[C];let _=D.reduce(r(w),{});x===!1&&(_={});const{prevResolvedValues:N={}}=T,O={...N,..._},j=L=>{$=!0,h.has(L)&&(F=!0,h.delete(L)),T.needsAnimating[L]=!0;const G=e.getValue(L);G&&(G.liveStyle=!1)};for(const L in O){const G=_[L],oe=N[L];if(f.hasOwnProperty(L))continue;let Q=!1;go(G)&&go(oe)?Q=!Ds(G,oe):Q=G!==oe,Q?G!=null?j(L):h.add(L):G!==void 0&&h.has(L)?j(L):T.protectedKeys[L]=!0}T.prevProp=C,T.prevResolvedValues=_,T.isActive&&(f={...f,..._}),o&&e.blockInitialAnimation&&($=!1);const K=P&&V;$&&(!K||F)&&u.push(...D.map(L=>{const G={type:w};if(typeof L=="string"&&o&&!K&&e.manuallyAnimateOnMount&&e.parent){const{parent:oe}=e,Q=at(oe,L);if(oe.enteringChildren&&Q){const{delayChildren:Se}=Q.transition||{};G.delay=Bi(oe.enteringChildren,e,Se)}}return{animation:L,options:G}}))}if(h.size){const b={};if(typeof c.initial!="boolean"){const w=at(e,Array.isArray(c.initial)?c.initial[0]:c.initial);w&&w.transition&&(b.transition=w.transition)}h.forEach(w=>{const T=e.getBaseTarget(w),C=e.getValue(w);C&&(C.liveStyle=!0),b[w]=T??null}),u.push({animation:b})}let y=!!u.length;return o&&(c.initial===!1||c.initial===c.animate)&&!e.manuallyAnimateOnMount&&(y=!1),o=!1,y?t(u):Promise.resolve()}function a(l,c){if(n[l].isActive===c)return Promise.resolve();e.variantChildren?.forEach(u=>u.animationState?.setActive(l,c)),n[l].isActive=c;const d=s(l);for(const u in n)n[u].protectedKeys={};return d}return{animateChanges:s,setActive:a,setAnimateFunction:i,getState:()=>n,reset:()=>{n=Fs()}}}function uf(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!Ds(t,e):!1}function Xe(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function Fs(){return{animate:Xe(!0),whileInView:Xe(),whileHover:Xe(),whileTap:Xe(),whileDrag:Xe(),whileFocus:Xe(),exit:Xe()}}const As=1e-4,df=1-As,ff=1+As,Is=.01,hf=0-Is,mf=0+Is;function ce(e){return e.max-e.min}function pf(e,t,n){return Math.abs(e-t)<=n}function Ls(e,t,n,o=.5){e.origin=o,e.originPoint=q(t.min,t.max,e.origin),e.scale=ce(n)/ce(t),e.translate=q(n.min,n.max,e.origin)-e.originPoint,(e.scale>=df&&e.scale<=ff||isNaN(e.scale))&&(e.scale=1),(e.translate>=hf&&e.translate<=mf||isNaN(e.translate))&&(e.translate=0)}function Dt(e,t,n,o){Ls(e.x,t.x,n.x,o?o.originX:void 0),Ls(e.y,t.y,n.y,o?o.originY:void 0)}function Rs(e,t,n){e.min=n.min+t.min,e.max=e.min+ce(t)}function gf(e,t,n){Rs(e.x,t.x,n.x),Rs(e.y,t.y,n.y)}function _s(e,t,n){e.min=t.min-n.min,e.max=e.min+ce(t)}function on(e,t,n){_s(e.x,t.x,n.x),_s(e.y,t.y,n.y)}function Bs(e,t,n,o,r){return e-=t,e=nn(e,1/n,o),r!==void 0&&(e=nn(e,1/r,o)),e}function vf(e,t=0,n=1,o=.5,r,i=e,s=e){if(Me.test(t)&&(t=parseFloat(t),t=q(s.min,s.max,t/100)-s.min),typeof t!="number")return;let a=q(i.min,i.max,o);e===i&&(a-=t),e.min=Bs(e.min,t,n,a,r),e.max=Bs(e.max,t,n,a,r)}function Ns(e,t,[n,o,r],i,s){vf(e,t[n],t[o],t[r],t.scale,i,s)}const yf=["x","scaleX","originX"],wf=["y","scaleY","originY"];function zs(e,t,n,o){Ns(e.x,t,yf,n?n.x:void 0,o?o.x:void 0),Ns(e.y,t,wf,n?n.y:void 0,o?o.y:void 0)}function Os(e,t){e.min=t.min,e.max=t.max}function be(e,t){Os(e.x,t.x),Os(e.y,t.y)}function Hs(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function js(e){return e.translate===0&&e.scale===1}function Gs(e){return js(e.x)&&js(e.y)}function Us(e,t){return e.min===t.min&&e.max===t.max}function bf(e,t){return Us(e.x,t.x)&&Us(e.y,t.y)}function Ks(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function Ws(e,t){return Ks(e.x,t.x)&&Ks(e.y,t.y)}function qs(e){return ce(e.x)/ce(e.y)}function Ys(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}function ge(e){return[e("x"),e("y")]}function xf(e,t,n){let o="";const r=e.x.translate/t.x,i=e.y.translate/t.y,s=n?.z||0;if((r||i||s)&&(o=`translate3d(${r}px, ${i}px, ${s}px) `),(t.x!==1||t.y!==1)&&(o+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:c,rotate:d,rotateX:u,rotateY:h,skewX:f,skewY:v}=n;c&&(o=`perspective(${c}px) ${o}`),d&&(o+=`rotate(${d}deg) `),u&&(o+=`rotateX(${u}deg) `),h&&(o+=`rotateY(${h}deg) `),f&&(o+=`skewX(${f}deg) `),v&&(o+=`skewY(${v}deg) `)}const a=e.x.scale*t.x,l=e.y.scale*t.y;return(a!==1||l!==1)&&(o+=`scale(${a}, ${l})`),o||"none"}const Xs=["TopLeft","TopRight","BottomLeft","BottomRight"],Sf=Xs.length,Zs=e=>typeof e=="string"?parseFloat(e):e,Js=e=>typeof e=="number"||k.test(e);function Cf(e,t,n,o,r,i){r?(e.opacity=q(0,n.opacity??1,Tf(o)),e.opacityExit=q(t.opacity??1,0,$f(o))):i&&(e.opacity=q(t.opacity??1,n.opacity??1,o));for(let s=0;s<Sf;s++){const a=`border${Xs[s]}Radius`;let l=Qs(t,a),c=Qs(n,a);if(l===void 0&&c===void 0)continue;l||(l=0),c||(c=0),l===0||c===0||Js(l)===Js(c)?(e[a]=Math.max(q(Zs(l),Zs(c),o),0),(Me.test(c)||Me.test(l))&&(e[a]+="%")):e[a]=c}(t.rotate||n.rotate)&&(e.rotate=q(t.rotate||0,n.rotate||0,o))}function Qs(e,t){return e[t]!==void 0?e[t]:e.borderRadius}const Tf=ea(0,.5,ei),$f=ea(.5,.95,me);function ea(e,t,n){return o=>o<e?0:o>t?1:n(St(e,t,o))}function Pf(e,t){const n=le.now(),o=({timestamp:r})=>{const i=r-n;i>=t&&(Le(o),e(i-t))};return U.setup(o,!0),()=>Le(o)}function Ft(e,t,n,o={passive:!0}){return e.addEventListener(t,n,o),()=>e.removeEventListener(t,n)}function rn(e){return ie(e)?e.get():e}function Mf(e,t,n){const o=ie(e)?e:st(e);return o.start(mo("",o,t,n)),o.animation}const kf=(e,t)=>e.depth-t.depth;class Vf{constructor(){this.children=[],this.isDirty=!1}add(t){Dn(this.children,t),this.isDirty=!0}remove(t){Fn(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(kf),this.isDirty=!1,this.children.forEach(t)}}class Ef{constructor(){this.members=[]}add(t){Dn(this.members,t),t.scheduleRender()}remove(t){if(Fn(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){const n=this.members.findIndex(r=>t===r);if(n===0)return!1;let o;for(let r=n;r>=0;r--){const i=this.members[r];if(i.isPresent!==!1){o=i;break}}return o?(this.promote(o),!0):!1}promote(t,n){const o=this.lead;if(t!==o&&(this.prevLead=o,this.lead=t,t.show(),o)){o.instance&&o.scheduleRender(),t.scheduleRender(),t.resumeFrom=o,n&&(t.resumeFrom.preserveOpacity=!0),o.snapshot&&(t.snapshot=o.snapshot,t.snapshot.latestValues=o.animationValues||o.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);const{crossfade:r}=t.options;r===!1&&o.hide()}}exitAnimationComplete(){this.members.forEach(t=>{const{options:n,resumingFrom:o}=t;n.onExitComplete&&n.onExitComplete(),o&&o.options.onExitComplete&&o.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}const sn={hasAnimatedSinceResize:!0,hasEverUpdated:!1},Io=["","X","Y","Z"],Df=1e3;let Ff=0;function Lo(e,t,n,o){const{latestValues:r}=t;r[e]&&(n[e]=r[e],t.setStaticValue(e,0),o&&(o[e]=0))}function ta(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=ji(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:r,layoutId:i}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",U,!(r||i))}const{parent:o}=e;o&&!o.hasCheckedOptimisedAppear&&ta(o)}function na({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:o,resetTransform:r}){return class{constructor(s={},a=t?.()){this.id=Ff++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.layoutVersion=0,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(Lf),this.nodes.forEach(Nf),this.nodes.forEach(zf),this.nodes.forEach(Rf)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=s,this.root=a?a.root||a:this,this.path=a?[...a.path,a]:[],this.parent=a,this.depth=a?a.depth+1:0;for(let l=0;l<this.path.length;l++)this.path[l].shouldResetTransform=!0;this.root===this&&(this.nodes=new Vf)}addEventListener(s,a){return this.eventHandlers.has(s)||this.eventHandlers.set(s,new Ln),this.eventHandlers.get(s).add(a)}notifyListeners(s,...a){const l=this.eventHandlers.get(s);l&&l.notify(...a)}hasListeners(s){return this.eventHandlers.has(s)}mount(s){if(this.instance)return;this.isSVG=ss(s)&&!Ad(s),this.instance=s;const{layoutId:a,layout:l,visualElement:c}=this.options;if(c&&!c.current&&c.mount(s),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(l||a)&&(this.isLayoutDirty=!0),e){let d,u=0;const h=()=>this.root.updateBlockedByResize=!1;U.read(()=>{u=window.innerWidth}),e(s,()=>{const f=window.innerWidth;f!==u&&(u=f,this.root.updateBlockedByResize=!0,d&&d(),d=Pf(h,250),sn.hasAnimatedSinceResize&&(sn.hasAnimatedSinceResize=!1,this.nodes.forEach(ia)))})}a&&this.root.registerSharedNode(a,this),this.options.animate!==!1&&c&&(a||l)&&this.addEventListener("didUpdate",({delta:d,hasLayoutChanged:u,hasRelativeLayoutChanged:h,layout:f})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const v=this.options.transition||c.getDefaultTransition()||Uf,{onLayoutAnimationStart:y,onLayoutAnimationComplete:b}=c.getProps(),w=!this.targetLayout||!Ws(this.targetLayout,f),T=!u&&h;if(this.options.layoutRoot||this.resumeFrom||T||u&&(w||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const C={...ho(v,"layout"),onPlay:y,onComplete:b};(c.shouldReduceMotion||this.options.layoutRoot)&&(C.delay=0,C.type=!1),this.startAnimation(C),this.setAnimationOrigin(d,T)}else u||ia(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=f})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const s=this.getStack();s&&s.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),Le(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(Of),this.animationId++)}getTransformTemplate(){const{visualElement:s}=this.options;return s&&s.getProps().transformTemplate}willUpdate(s=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&ta(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let d=0;d<this.path.length;d++){const u=this.path[d];u.shouldResetTransform=!0,u.updateScroll("snapshot"),u.options.layoutRoot&&u.willUpdate(!1)}const{layoutId:a,layout:l}=this.options;if(a===void 0&&!l)return;const c=this.getTransformTemplate();this.prevTransformTemplateValue=c?c(this.latestValues,""):void 0,this.updateSnapshot(),s&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(oa);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(ra);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(Bf),this.nodes.forEach(Af),this.nodes.forEach(If)):this.nodes.forEach(ra),this.clearAllSnapshots();const a=le.now();ne.delta=$e(0,1e3/60,a-ne.timestamp),ne.timestamp=a,ne.isProcessing=!0,Nn.update.process(ne),Nn.preRender.process(ne),Nn.render.process(ne),ne.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,So.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(_f),this.sharedNodes.forEach(Hf)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,U.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){U.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!ce(this.snapshot.measuredBox.x)&&!ce(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let l=0;l<this.path.length;l++)this.path[l].updateScroll();const s=this.layout;this.layout=this.measure(!1),this.layoutVersion++,this.layoutCorrected=ee(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:a}=this.options;a&&a.notify("LayoutMeasure",this.layout.layoutBox,s?s.layoutBox:void 0)}updateScroll(s="measure"){let a=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===s&&(a=!1),a&&this.instance){const l=o(this.instance);this.scroll={animationId:this.root.animationId,phase:s,isRoot:l,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:l}}}resetTransform(){if(!r)return;const s=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,a=this.projectionDelta&&!Gs(this.projectionDelta),l=this.getTransformTemplate(),c=l?l(this.latestValues,""):void 0,d=c!==this.prevTransformTemplateValue;s&&this.instance&&(a||Ye(this.latestValues)||d)&&(r(this.instance,c),this.shouldResetTransform=!1,this.scheduleRender())}measure(s=!0){const a=this.measurePageBox();let l=this.removeElementScroll(a);return s&&(l=this.removeTransform(l)),Kf(l),{animationId:this.root.animationId,measuredBox:a,layoutBox:l,latestValues:{},source:this.id}}measurePageBox(){const{visualElement:s}=this.options;if(!s)return ee();const a=s.measureViewportBox();if(!(this.scroll?.wasRoot||this.path.some(Wf))){const{scroll:c}=this.root;c&&(ct(a.x,c.offset.x),ct(a.y,c.offset.y))}return a}removeElementScroll(s){const a=ee();if(be(a,s),this.scroll?.wasRoot)return a;for(let l=0;l<this.path.length;l++){const c=this.path[l],{scroll:d,options:u}=c;c!==this.root&&d&&u.layoutScroll&&(d.wasRoot&&be(a,s),ct(a.x,d.offset.x),ct(a.y,d.offset.y))}return a}applyTransform(s,a=!1){const l=ee();be(l,s);for(let c=0;c<this.path.length;c++){const d=this.path[c];!a&&d.options.layoutScroll&&d.scroll&&d!==d.root&&ut(l,{x:-d.scroll.offset.x,y:-d.scroll.offset.y}),Ye(d.latestValues)&&ut(l,d.latestValues)}return Ye(this.latestValues)&&ut(l,this.latestValues),l}removeTransform(s){const a=ee();be(a,s);for(let l=0;l<this.path.length;l++){const c=this.path[l];if(!c.instance||!Ye(c.latestValues))continue;Vo(c.latestValues)&&c.updateSnapshot();const d=ee(),u=c.measurePageBox();be(d,u),zs(a,c.latestValues,c.snapshot?c.snapshot.layoutBox:void 0,d)}return Ye(this.latestValues)&&zs(a,this.latestValues),a}setTargetDelta(s){this.targetDelta=s,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(s){this.options={...this.options,...s,crossfade:s.crossfade!==void 0?s.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==ne.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(s=!1){const a=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=a.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=a.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=a.isSharedProjectionDirty);const l=!!this.resumingFrom||this!==a;if(!(s||l&&this.isSharedProjectionDirty||this.isProjectionDirty||this.parent?.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:d,layoutId:u}=this.options;if(!this.layout||!(d||u))return;this.resolvedRelativeTargetAt=ne.timestamp;const h=this.getClosestProjectingParent();h&&this.linkedParentVersion!==h.layoutVersion&&!h.options.layoutRoot&&this.removeRelativeTarget(),!this.targetDelta&&!this.relativeTarget&&(h&&h.layout?this.createRelativeTarget(h,this.layout.layoutBox,h.layout.layoutBox):this.removeRelativeTarget()),!(!this.relativeTarget&&!this.targetDelta)&&(this.target||(this.target=ee(),this.targetWithTransforms=ee()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),gf(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):be(this.target,this.layout.layoutBox),ys(this.target,this.targetDelta)):be(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=!1,h&&!!h.resumingFrom==!!this.resumingFrom&&!h.options.layoutScroll&&h.target&&this.animationProgress!==1?this.createRelativeTarget(h,this.target,h.target):this.relativeParent=this.relativeTarget=void 0))}getClosestProjectingParent(){if(!(!this.parent||Vo(this.parent.latestValues)||ps(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(s,a,l){this.relativeParent=s,this.linkedParentVersion=s.layoutVersion,this.forceRelativeParentToResolveTarget(),this.relativeTarget=ee(),this.relativeTargetOrigin=ee(),on(this.relativeTargetOrigin,a,l),be(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){const s=this.getLead(),a=!!this.resumingFrom||this!==s;let l=!0;if((this.isProjectionDirty||this.parent?.isProjectionDirty)&&(l=!1),a&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(l=!1),this.resolvedRelativeTargetAt===ne.timestamp&&(l=!1),l)return;const{layout:c,layoutId:d}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(c||d))return;be(this.layoutCorrected,this.layout.layoutBox);const u=this.treeScale.x,h=this.treeScale.y;Gd(this.layoutCorrected,this.treeScale,this.path,a),s.layout&&!s.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(s.target=s.layout.layoutBox,s.targetWithTransforms=ee());const{target:f}=s;if(!f){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(Hs(this.prevProjectionDelta.x,this.projectionDelta.x),Hs(this.prevProjectionDelta.y,this.projectionDelta.y)),Dt(this.projectionDelta,this.layoutCorrected,f,this.latestValues),(this.treeScale.x!==u||this.treeScale.y!==h||!Ys(this.projectionDelta.x,this.prevProjectionDelta.x)||!Ys(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",f))}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(s=!0){if(this.options.visualElement?.scheduleRender(),s){const a=this.getStack();a&&a.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=lt(),this.projectionDelta=lt(),this.projectionDeltaWithTransform=lt()}setAnimationOrigin(s,a=!1){const l=this.snapshot,c=l?l.latestValues:{},d={...this.latestValues},u=lt();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!a;const h=ee(),f=l?l.source:void 0,v=this.layout?this.layout.source:void 0,y=f!==v,b=this.getStack(),w=!b||b.members.length<=1,T=!!(y&&!w&&this.options.crossfade===!0&&!this.path.some(Gf));this.animationProgress=0;let C;this.mixTargetDelta=M=>{const x=M/1e3;sa(u.x,s.x,x),sa(u.y,s.y,x),this.setTargetDelta(u),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(on(h,this.layout.layoutBox,this.relativeParent.layout.layoutBox),jf(this.relativeTarget,this.relativeTargetOrigin,h,x),C&&bf(this.relativeTarget,C)&&(this.isProjectionDirty=!1),C||(C=ee()),be(C,this.relativeTarget)),y&&(this.animationValues=d,Cf(d,c,this.latestValues,x,T,w)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=x},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(s){this.notifyListeners("animationStart"),this.currentAnimation?.stop(),this.resumingFrom?.currentAnimation?.stop(),this.pendingAnimation&&(Le(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=U.update(()=>{sn.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=st(0)),this.currentAnimation=Mf(this.motionValue,[0,1e3],{...s,velocity:0,isSync:!0,onUpdate:a=>{this.mixTargetDelta(a),s.onUpdate&&s.onUpdate(a)},onStop:()=>{},onComplete:()=>{s.onComplete&&s.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const s=this.getStack();s&&s.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(Df),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const s=this.getLead();let{targetWithTransforms:a,target:l,layout:c,latestValues:d}=s;if(!(!a||!l||!c)){if(this!==s&&this.layout&&c&&da(this.options.animationType,this.layout.layoutBox,c.layoutBox)){l=this.target||ee();const u=ce(this.layout.layoutBox.x);l.x.min=s.target.x.min,l.x.max=l.x.min+u;const h=ce(this.layout.layoutBox.y);l.y.min=s.target.y.min,l.y.max=l.y.min+h}be(a,l),ut(a,d),Dt(this.projectionDeltaWithTransform,this.layoutCorrected,a,d)}}registerSharedNode(s,a){this.sharedNodes.has(s)||this.sharedNodes.set(s,new Ef),this.sharedNodes.get(s).add(a);const c=a.options.initialPromotionConfig;a.promote({transition:c?c.transition:void 0,preserveFollowOpacity:c&&c.shouldPreserveFollowOpacity?c.shouldPreserveFollowOpacity(a):void 0})}isLead(){const s=this.getStack();return s?s.lead===this:!0}getLead(){const{layoutId:s}=this.options;return s?this.getStack()?.lead||this:this}getPrevLead(){const{layoutId:s}=this.options;return s?this.getStack()?.prevLead:void 0}getStack(){const{layoutId:s}=this.options;if(s)return this.root.sharedNodes.get(s)}promote({needsReset:s,transition:a,preserveFollowOpacity:l}={}){const c=this.getStack();c&&c.promote(this,l),s&&(this.projectionDelta=void 0,this.needsReset=!0),a&&this.setOptions({transition:a})}relegate(){const s=this.getStack();return s?s.relegate(this):!1}resetSkewAndRotation(){const{visualElement:s}=this.options;if(!s)return;let a=!1;const{latestValues:l}=s;if((l.z||l.rotate||l.rotateX||l.rotateY||l.rotateZ||l.skewX||l.skewY)&&(a=!0),!a)return;const c={};l.z&&Lo("z",s,c,this.animationValues);for(let d=0;d<Io.length;d++)Lo(`rotate${Io[d]}`,s,c,this.animationValues),Lo(`skew${Io[d]}`,s,c,this.animationValues);s.render();for(const d in c)s.setStaticValue(d,c[d]),this.animationValues&&(this.animationValues[d]=c[d]);s.scheduleRender()}applyProjectionStyles(s,a){if(!this.instance||this.isSVG)return;if(!this.isVisible){s.visibility="hidden";return}const l=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,s.visibility="",s.opacity="",s.pointerEvents=rn(a?.pointerEvents)||"",s.transform=l?l(this.latestValues,""):"none";return}const c=this.getLead();if(!this.projectionDelta||!this.layout||!c.target){this.options.layoutId&&(s.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,s.pointerEvents=rn(a?.pointerEvents)||""),this.hasProjected&&!Ye(this.latestValues)&&(s.transform=l?l({},""):"none",this.hasProjected=!1);return}s.visibility="";const d=c.animationValues||c.latestValues;this.applyTransformsToTarget();let u=xf(this.projectionDeltaWithTransform,this.treeScale,d);l&&(u=l(d,u)),s.transform=u;const{x:h,y:f}=this.projectionDelta;s.transformOrigin=`${h.origin*100}% ${f.origin*100}% 0`,c.animationValues?s.opacity=c===this?d.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:d.opacityExit:s.opacity=c===this?d.opacity!==void 0?d.opacity:"":d.opacityExit!==void 0?d.opacityExit:0;for(const v in Fo){if(d[v]===void 0)continue;const{correct:y,applyTo:b,isCSSVariable:w}=Fo[v],T=u==="none"?d[v]:y(d[v],c);if(b){const C=b.length;for(let M=0;M<C;M++)s[b[M]]=T}else w?this.options.visualElement.renderState.vars[v]=T:s[v]=T}this.options.layoutId&&(s.pointerEvents=c===this?rn(a?.pointerEvents)||"":"none")}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(s=>s.currentAnimation?.stop()),this.root.nodes.forEach(oa),this.root.sharedNodes.clear()}}}function Af(e){e.updateLayout()}function If(e){const t=e.resumeFrom?.snapshot||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners("didUpdate")){const{layoutBox:n,measuredBox:o}=e.layout,{animationType:r}=e.options,i=t.source!==e.layout.source;r==="size"?ge(d=>{const u=i?t.measuredBox[d]:t.layoutBox[d],h=ce(u);u.min=n[d].min,u.max=u.min+h}):da(r,t.layoutBox,n)&&ge(d=>{const u=i?t.measuredBox[d]:t.layoutBox[d],h=ce(n[d]);u.max=u.min+h,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[d].max=e.relativeTarget[d].min+h)});const s=lt();Dt(s,n,t.layoutBox);const a=lt();i?Dt(a,e.applyTransform(o,!0),t.measuredBox):Dt(a,n,t.layoutBox);const l=!Gs(s);let c=!1;if(!e.resumeFrom){const d=e.getClosestProjectingParent();if(d&&!d.resumeFrom){const{snapshot:u,layout:h}=d;if(u&&h){const f=ee();on(f,t.layoutBox,u.layoutBox);const v=ee();on(v,n,h.layoutBox),Ws(f,v)||(c=!0),d.options.layoutRoot&&(e.relativeTarget=v,e.relativeTargetOrigin=f,e.relativeParent=d)}}}e.notifyListeners("didUpdate",{layout:n,snapshot:t,delta:a,layoutDelta:s,hasLayoutChanged:l,hasRelativeLayoutChanged:c})}else if(e.isLead()){const{onExitComplete:n}=e.options;n&&n()}e.options.transition=void 0}function Lf(e){e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function Rf(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function _f(e){e.clearSnapshot()}function oa(e){e.clearMeasurements()}function ra(e){e.isLayoutDirty=!1}function Bf(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function ia(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function Nf(e){e.resolveTargetDelta()}function zf(e){e.calcProjection()}function Of(e){e.resetSkewAndRotation()}function Hf(e){e.removeLeadSnapshot()}function sa(e,t,n){e.translate=q(t.translate,0,n),e.scale=q(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function aa(e,t,n,o){e.min=q(t.min,n.min,o),e.max=q(t.max,n.max,o)}function jf(e,t,n,o){aa(e.x,t.x,n.x,o),aa(e.y,t.y,n.y,o)}function Gf(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const Uf={duration:.45,ease:[.4,0,.1,1]},la=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),ca=la("applewebkit/")&&!la("chrome/")?Math.round:me;function ua(e){e.min=ca(e.min),e.max=ca(e.max)}function Kf(e){ua(e.x),ua(e.y)}function da(e,t,n){return e==="position"||e==="preserve-aspect"&&!pf(qs(t),qs(n),.2)}function Wf(e){return e!==e.root&&e.scroll?.wasRoot}const qf=na({attachResizeListener:(e,t)=>Ft(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),Ro={current:void 0},fa=na({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!Ro.current){const e=new qf({});e.mount(window),e.setOptions({layoutScroll:!0}),Ro.current=e}return Ro.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),_o=m.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});function ha(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function Yf(...e){return t=>{let n=!1;const o=e.map(r=>{const i=ha(r,t);return!n&&typeof i=="function"&&(n=!0),i});if(n)return()=>{for(let r=0;r<o.length;r++){const i=o[r];typeof i=="function"?i():ha(e[r],null)}}}}function Xf(...e){return Ue.useCallback(Yf(...e),e)}class Zf extends Ue.Component{getSnapshotBeforeUpdate(t){const n=this.props.childRef.current;if(n&&t.isPresent&&!this.props.isPresent){const o=n.offsetParent,r=Ji(o)&&o.offsetWidth||0,i=this.props.sizeRef.current;i.height=n.offsetHeight||0,i.width=n.offsetWidth||0,i.top=n.offsetTop,i.left=n.offsetLeft,i.right=r-i.width-i.left}return null}componentDidUpdate(){}render(){return this.props.children}}function Jf({children:e,isPresent:t,anchorX:n,root:o}){const r=m.useId(),i=m.useRef(null),s=m.useRef({width:0,height:0,top:0,left:0,right:0}),{nonce:a}=m.useContext(_o),l=e.props?.ref??e?.ref,c=Xf(i,l);return m.useInsertionEffect(()=>{const{width:d,height:u,top:h,left:f,right:v}=s.current;if(t||!i.current||!d||!u)return;const y=n==="left"?`left: ${f}`:`right: ${v}`;i.current.dataset.motionPopId=r;const b=document.createElement("style");a&&(b.nonce=a);const w=o??document.head;return w.appendChild(b),b.sheet&&b.sheet.insertRule(`
167
+ `,Br={tn:"1rem",sm:"1.5rem",md:"2rem",lg:"3rem"},U=({component:e,size:t="1.5rem",color:n="currentColor",className:o,iconProps:r={}})=>{const i=typeof t=="string"&&t in Br?Br[t]:t;return p.jsx(Tc,{$color:n,className:o,children:typeof e=="function"?p.jsx(e,{size:i,...r}):e})},En=m.createContext({});function Dn(e){const t=m.useRef(null);return t.current===null&&(t.current=e()),t.current}const zr=typeof window<"u",Or=zr?m.useLayoutEffect:m.useEffect,Ut=m.createContext(null);function Fn(e,t){e.indexOf(t)===-1&&e.push(t)}function An(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}const $e=(e,t,n)=>n>t?t:n<e?e:n;function In(e,t){return t?`${e}. For more information and steps for solving, visit https://motion.dev/troubleshooting/${t}`:e}let tt=()=>{},Ee=()=>{};typeof process<"u"&&process.env?.NODE_ENV!=="production"&&(tt=(e,t,n)=>{!e&&typeof console<"u"&&console.warn(In(t,n))},Ee=(e,t,n)=>{if(!e)throw new Error(In(t,n))});const De={},Hr=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);function jr(e){return typeof e=="object"&&e!==null}const Gr=e=>/^0[^.\s]+$/u.test(e);function Ln(e){let t;return()=>(t===void 0&&(t=e()),t)}const me=e=>e,$c=(e,t)=>n=>t(e(n)),St=(...e)=>e.reduce($c),Ct=(e,t,n)=>{const o=t-e;return o===0?1:(n-e)/o};class Rn{constructor(){this.subscriptions=[]}add(t){return Fn(this.subscriptions,t),()=>An(this.subscriptions,t)}notify(t,n,o){const r=this.subscriptions.length;if(r)if(r===1)this.subscriptions[0](t,n,o);else for(let i=0;i<r;i++){const s=this.subscriptions[i];s&&s(t,n,o)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const Pe=e=>e*1e3,pe=e=>e/1e3;function Ur(e,t){return t?e*(1e3/t):0}const Kr=new Set;function _n(e,t,n){e||Kr.has(t)||(console.warn(In(t,n)),Kr.add(t))}const Wr=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,Pc=1e-7,kc=12;function Mc(e,t,n,o,r){let i,s,a=0;do s=t+(n-t)/2,i=Wr(s,o,r)-e,i>0?n=s:t=s;while(Math.abs(i)>Pc&&++a<kc);return s}function Tt(e,t,n,o){if(e===t&&n===o)return me;const r=i=>Mc(i,0,1,e,n);return i=>i===0||i===1?i:Wr(r(i),t,o)}const qr=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,Yr=e=>t=>1-e(1-t),Xr=Tt(.33,1.53,.69,.99),Nn=Yr(Xr),Zr=qr(Nn),Jr=e=>(e*=2)<1?.5*Nn(e):.5*(2-Math.pow(2,-10*(e-1))),Bn=e=>1-Math.sin(Math.acos(e)),Qr=Yr(Bn),ei=qr(Bn),Vc=Tt(.42,0,1,1),Ec=Tt(0,0,.58,1),ti=Tt(.42,0,.58,1),Dc=e=>Array.isArray(e)&&typeof e[0]!="number",ni=e=>Array.isArray(e)&&typeof e[0]=="number",oi={linear:me,easeIn:Vc,easeInOut:ti,easeOut:Ec,circIn:Bn,circInOut:ei,circOut:Qr,backIn:Nn,backInOut:Zr,backOut:Xr,anticipate:Jr},Fc=e=>typeof e=="string",ri=e=>{if(ni(e)){Ee(e.length===4,"Cubic bezier arrays must contain four numerical values.","cubic-bezier-length");const[t,n,o,r]=e;return Tt(t,n,o,r)}else if(Fc(e))return Ee(oi[e]!==void 0,`Invalid easing type '${e}'`,"invalid-easing-type"),oi[e];return e},Kt=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function Ac(e,t){let n=new Set,o=new Set,r=!1,i=!1;const s=new WeakSet;let a={delta:0,timestamp:0,isProcessing:!1};function l(d){s.has(d)&&(c.schedule(d),e()),d(a)}const c={schedule:(d,u=!1,h=!1)=>{const v=h&&r?n:o;return u&&s.add(d),v.has(d)||v.add(d),d},cancel:d=>{o.delete(d),s.delete(d)},process:d=>{if(a=d,r){i=!0;return}r=!0,[n,o]=[o,n],n.forEach(l),n.clear(),r=!1,i&&(i=!1,c.process(d))}};return c}const Ic=40;function ii(e,t){let n=!1,o=!0;const r={delta:0,timestamp:0,isProcessing:!1},i=()=>n=!0,s=Kt.reduce((C,k)=>(C[k]=Ac(i),C),{}),{setup:a,read:l,resolveKeyframes:c,preUpdate:d,update:u,preRender:h,render:f,postRender:v}=s,y=()=>{const C=De.useManualTiming?r.timestamp:performance.now();n=!1,De.useManualTiming||(r.delta=o?1e3/60:Math.max(Math.min(C-r.timestamp,Ic),1)),r.timestamp=C,r.isProcessing=!0,a.process(r),l.process(r),c.process(r),d.process(r),u.process(r),h.process(r),f.process(r),v.process(r),r.isProcessing=!1,n&&t&&(o=!1,e(y))},b=()=>{n=!0,o=!0,r.isProcessing||e(y)};return{schedule:Kt.reduce((C,k)=>{const x=s[k];return C[k]=(P,V=!1,$=!1)=>(n||b(),x.schedule(P,V,$)),C},{}),cancel:C=>{for(let k=0;k<Kt.length;k++)s[Kt[k]].cancel(C)},state:r,steps:s}}const{schedule:K,cancel:Le,state:ne,steps:zn}=ii(typeof requestAnimationFrame<"u"?requestAnimationFrame:me,!0);let Wt;function Lc(){Wt=void 0}const le={now:()=>(Wt===void 0&&le.set(ne.isProcessing||De.useManualTiming?ne.timestamp:performance.now()),Wt),set:e=>{Wt=e,queueMicrotask(Lc)}},si=e=>t=>typeof t=="string"&&t.startsWith(e),ai=si("--"),Rc=si("var(--"),On=e=>Rc(e)?_c.test(e.split("/*")[0].trim()):!1,_c=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function li(e){return typeof e!="string"?!1:e.split("/*")[0].includes("var(--")}const nt={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},$t={...nt,transform:e=>$e(0,1,e)},qt={...nt,default:1},Pt=e=>Math.round(e*1e5)/1e5,Hn=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function Nc(e){return e==null}const Bc=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,jn=(e,t)=>n=>!!(typeof n=="string"&&Bc.test(n)&&n.startsWith(e)||t&&!Nc(n)&&Object.prototype.hasOwnProperty.call(n,t)),ci=(e,t,n)=>o=>{if(typeof o!="string")return o;const[r,i,s,a]=o.match(Hn);return{[e]:parseFloat(r),[t]:parseFloat(i),[n]:parseFloat(s),alpha:a!==void 0?parseFloat(a):1}},zc=e=>$e(0,255,e),Gn={...nt,transform:e=>Math.round(zc(e))},Ke={test:jn("rgb","red"),parse:ci("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:o=1})=>"rgba("+Gn.transform(e)+", "+Gn.transform(t)+", "+Gn.transform(n)+", "+Pt($t.transform(o))+")"};function Oc(e){let t="",n="",o="",r="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),o=e.substring(5,7),r=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),o=e.substring(3,4),r=e.substring(4,5),t+=t,n+=n,o+=o,r+=r),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(o,16),alpha:r?parseInt(r,16)/255:1}}const Un={test:jn("#"),parse:Oc,transform:Ke.transform},kt=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),Re=kt("deg"),ke=kt("%"),M=kt("px"),Hc=kt("vh"),jc=kt("vw"),ui={...ke,parse:e=>ke.parse(e)/100,transform:e=>ke.transform(e*100)},ot={test:jn("hsl","hue"),parse:ci("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:o=1})=>"hsla("+Math.round(e)+", "+ke.transform(Pt(t))+", "+ke.transform(Pt(n))+", "+Pt($t.transform(o))+")"},J={test:e=>Ke.test(e)||Un.test(e)||ot.test(e),parse:e=>Ke.test(e)?Ke.parse(e):ot.test(e)?ot.parse(e):Un.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?Ke.transform(e):ot.transform(e),getAnimatableNone:e=>{const t=J.parse(e);return t.alpha=0,J.transform(t)}},Gc=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function Uc(e){return isNaN(e)&&typeof e=="string"&&(e.match(Hn)?.length||0)+(e.match(Gc)?.length||0)>0}const di="number",fi="color",Kc="var",Wc="var(",hi="${}",qc=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function Mt(e){const t=e.toString(),n=[],o={color:[],number:[],var:[]},r=[];let i=0;const a=t.replace(qc,l=>(J.test(l)?(o.color.push(i),r.push(fi),n.push(J.parse(l))):l.startsWith(Wc)?(o.var.push(i),r.push(Kc),n.push(l)):(o.number.push(i),r.push(di),n.push(parseFloat(l))),++i,hi)).split(hi);return{values:n,split:a,indexes:o,types:r}}function mi(e){return Mt(e).values}function pi(e){const{split:t,types:n}=Mt(e),o=t.length;return r=>{let i="";for(let s=0;s<o;s++)if(i+=t[s],r[s]!==void 0){const a=n[s];a===di?i+=Pt(r[s]):a===fi?i+=J.transform(r[s]):i+=r[s]}return i}}const Yc=e=>typeof e=="number"?0:J.test(e)?J.getAnimatableNone(e):e;function Xc(e){const t=mi(e);return pi(e)(t.map(Yc))}const _e={test:Uc,parse:mi,createTransformer:pi,getAnimatableNone:Xc};function Kn(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function Zc({hue:e,saturation:t,lightness:n,alpha:o}){e/=360,t/=100,n/=100;let r=0,i=0,s=0;if(!t)r=i=s=n;else{const a=n<.5?n*(1+t):n+t-n*t,l=2*n-a;r=Kn(l,a,e+1/3),i=Kn(l,a,e),s=Kn(l,a,e-1/3)}return{red:Math.round(r*255),green:Math.round(i*255),blue:Math.round(s*255),alpha:o}}function Yt(e,t){return n=>n>0?t:e}const Y=(e,t,n)=>e+(t-e)*n,Wn=(e,t,n)=>{const o=e*e,r=n*(t*t-o)+o;return r<0?0:Math.sqrt(r)},Jc=[Un,Ke,ot],Qc=e=>Jc.find(t=>t.test(e));function gi(e){const t=Qc(e);if(tt(!!t,`'${e}' is not an animatable color. Use the equivalent color code instead.`,"color-not-animatable"),!t)return!1;let n=t.parse(e);return t===ot&&(n=Zc(n)),n}const vi=(e,t)=>{const n=gi(e),o=gi(t);if(!n||!o)return Yt(e,t);const r={...n};return i=>(r.red=Wn(n.red,o.red,i),r.green=Wn(n.green,o.green,i),r.blue=Wn(n.blue,o.blue,i),r.alpha=Y(n.alpha,o.alpha,i),Ke.transform(r))},qn=new Set(["none","hidden"]);function eu(e,t){return qn.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function tu(e,t){return n=>Y(e,t,n)}function Yn(e){return typeof e=="number"?tu:typeof e=="string"?On(e)?Yt:J.test(e)?vi:ru:Array.isArray(e)?yi:typeof e=="object"?J.test(e)?vi:nu:Yt}function yi(e,t){const n=[...e],o=n.length,r=e.map((i,s)=>Yn(i)(i,t[s]));return i=>{for(let s=0;s<o;s++)n[s]=r[s](i);return n}}function nu(e,t){const n={...e,...t},o={};for(const r in n)e[r]!==void 0&&t[r]!==void 0&&(o[r]=Yn(e[r])(e[r],t[r]));return r=>{for(const i in o)n[i]=o[i](r);return n}}function ou(e,t){const n=[],o={color:0,var:0,number:0};for(let r=0;r<t.values.length;r++){const i=t.types[r],s=e.indexes[i][o[i]],a=e.values[s]??0;n[r]=a,o[i]++}return n}const ru=(e,t)=>{const n=_e.createTransformer(t),o=Mt(e),r=Mt(t);return o.indexes.var.length===r.indexes.var.length&&o.indexes.color.length===r.indexes.color.length&&o.indexes.number.length>=r.indexes.number.length?qn.has(e)&&!r.values.length||qn.has(t)&&!o.values.length?eu(e,t):St(yi(ou(o,r),r.values),n):(tt(!0,`Complex values '${e}' and '${t}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`,"complex-values-different"),Yt(e,t))};function wi(e,t,n){return typeof e=="number"&&typeof t=="number"&&typeof n=="number"?Y(e,t,n):Yn(e)(e,t)}const iu=e=>{const t=({timestamp:n})=>e(n);return{start:(n=!0)=>K.update(t,n),stop:()=>Le(t),now:()=>ne.isProcessing?ne.timestamp:le.now()}},bi=(e,t,n=10)=>{let o="";const r=Math.max(Math.round(t/n),2);for(let i=0;i<r;i++)o+=Math.round(e(i/(r-1))*1e4)/1e4+", ";return`linear(${o.substring(0,o.length-2)})`},Xt=2e4;function Xn(e){let t=0;const n=50;let o=e.next(t);for(;!o.done&&t<Xt;)t+=n,o=e.next(t);return t>=Xt?1/0:t}function su(e,t=100,n){const o=n({...e,keyframes:[0,t]}),r=Math.min(Xn(o),Xt);return{type:"keyframes",ease:i=>o.next(r*i).value/t,duration:pe(r)}}const au=5;function xi(e,t,n){const o=Math.max(t-au,0);return Ur(n-e(o),t-o)}const X={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1},Zn=.001;function lu({duration:e=X.duration,bounce:t=X.bounce,velocity:n=X.velocity,mass:o=X.mass}){let r,i;tt(e<=Pe(X.maxDuration),"Spring duration must be 10 seconds or less","spring-duration-limit");let s=1-t;s=$e(X.minDamping,X.maxDamping,s),e=$e(X.minDuration,X.maxDuration,pe(e)),s<1?(r=c=>{const d=c*s,u=d*e,h=d-n,f=Jn(c,s),v=Math.exp(-u);return Zn-h/f*v},i=c=>{const u=c*s*e,h=u*n+n,f=Math.pow(s,2)*Math.pow(c,2)*e,v=Math.exp(-u),y=Jn(Math.pow(c,2),s);return(-r(c)+Zn>0?-1:1)*((h-f)*v)/y}):(r=c=>{const d=Math.exp(-c*e),u=(c-n)*e+1;return-Zn+d*u},i=c=>{const d=Math.exp(-c*e),u=(n-c)*(e*e);return d*u});const a=5/e,l=uu(r,i,a);if(e=Pe(e),isNaN(l))return{stiffness:X.stiffness,damping:X.damping,duration:e};{const c=Math.pow(l,2)*o;return{stiffness:c,damping:s*2*Math.sqrt(o*c),duration:e}}}const cu=12;function uu(e,t,n){let o=n;for(let r=1;r<cu;r++)o=o-e(o)/t(o);return o}function Jn(e,t){return e*Math.sqrt(1-t*t)}const du=["duration","bounce"],fu=["stiffness","damping","mass"];function Si(e,t){return t.some(n=>e[n]!==void 0)}function hu(e){let t={velocity:X.velocity,stiffness:X.stiffness,damping:X.damping,mass:X.mass,isResolvedFromDuration:!1,...e};if(!Si(e,fu)&&Si(e,du))if(e.visualDuration){const n=e.visualDuration,o=2*Math.PI/(n*1.2),r=o*o,i=2*$e(.05,1,1-(e.bounce||0))*Math.sqrt(r);t={...t,mass:X.mass,stiffness:r,damping:i}}else{const n=lu(e);t={...t,...n,mass:X.mass},t.isResolvedFromDuration=!0}return t}function Zt(e=X.visualDuration,t=X.bounce){const n=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:o,restDelta:r}=n;const i=n.keyframes[0],s=n.keyframes[n.keyframes.length-1],a={done:!1,value:i},{stiffness:l,damping:c,mass:d,duration:u,velocity:h,isResolvedFromDuration:f}=hu({...n,velocity:-pe(n.velocity||0)}),v=h||0,y=c/(2*Math.sqrt(l*d)),b=s-i,w=pe(Math.sqrt(l/d)),T=Math.abs(b)<5;o||(o=T?X.restSpeed.granular:X.restSpeed.default),r||(r=T?X.restDelta.granular:X.restDelta.default);let C;if(y<1){const x=Jn(w,y);C=P=>{const V=Math.exp(-y*w*P);return s-V*((v+y*w*b)/x*Math.sin(x*P)+b*Math.cos(x*P))}}else if(y===1)C=x=>s-Math.exp(-w*x)*(b+(v+w*b)*x);else{const x=w*Math.sqrt(y*y-1);C=P=>{const V=Math.exp(-y*w*P),$=Math.min(x*P,300);return s-V*((v+y*w*b)*Math.sinh($)+x*b*Math.cosh($))/x}}const k={calculatedDuration:f&&u||null,next:x=>{const P=C(x);if(f)a.done=x>=u;else{let V=x===0?v:0;y<1&&(V=x===0?Pe(v):xi(C,x,P));const $=Math.abs(V)<=o,D=Math.abs(s-P)<=r;a.done=$&&D}return a.value=a.done?s:P,a},toString:()=>{const x=Math.min(Xn(k),Xt),P=bi(V=>k.next(x*V).value,x,30);return x+"ms "+P},toTransition:()=>{}};return k}Zt.applyToOptions=e=>{const t=su(e,100,Zt);return e.ease=t.ease,e.duration=Pe(t.duration),e.type="keyframes",e};function Qn({keyframes:e,velocity:t=0,power:n=.8,timeConstant:o=325,bounceDamping:r=10,bounceStiffness:i=500,modifyTarget:s,min:a,max:l,restDelta:c=.5,restSpeed:d}){const u=e[0],h={done:!1,value:u},f=$=>a!==void 0&&$<a||l!==void 0&&$>l,v=$=>a===void 0?l:l===void 0||Math.abs(a-$)<Math.abs(l-$)?a:l;let y=n*t;const b=u+y,w=s===void 0?b:s(b);w!==b&&(y=w-u);const T=$=>-y*Math.exp(-$/o),C=$=>w+T($),k=$=>{const D=T($),F=C($);h.done=Math.abs(D)<=c,h.value=h.done?w:F};let x,P;const V=$=>{f(h.value)&&(x=$,P=Zt({keyframes:[h.value,v(h.value)],velocity:xi(C,$,h.value),damping:r,stiffness:i,restDelta:c,restSpeed:d}))};return V(0),{calculatedDuration:null,next:$=>{let D=!1;return!P&&x===void 0&&(D=!0,k($),V($)),x!==void 0&&$>=x?P.next($-x):(!D&&k($),h)}}}function mu(e,t,n){const o=[],r=n||De.mix||wi,i=e.length-1;for(let s=0;s<i;s++){let a=r(e[s],e[s+1]);if(t){const l=Array.isArray(t)?t[s]||me:t;a=St(l,a)}o.push(a)}return o}function pu(e,t,{clamp:n=!0,ease:o,mixer:r}={}){const i=e.length;if(Ee(i===t.length,"Both input and output ranges must be the same length","range-length"),i===1)return()=>t[0];if(i===2&&t[0]===t[1])return()=>t[1];const s=e[0]===e[1];e[0]>e[i-1]&&(e=[...e].reverse(),t=[...t].reverse());const a=mu(t,o,r),l=a.length,c=d=>{if(s&&d<e[0])return t[0];let u=0;if(l>1)for(;u<e.length-2&&!(d<e[u+1]);u++);const h=Ct(e[u],e[u+1],d);return a[u](h)};return n?d=>c($e(e[0],e[i-1],d)):c}function gu(e,t){const n=e[e.length-1];for(let o=1;o<=t;o++){const r=Ct(0,t,o);e.push(Y(n,1,r))}}function vu(e){const t=[0];return gu(t,e.length-1),t}function yu(e,t){return e.map(n=>n*t)}function wu(e,t){return e.map(()=>t||ti).splice(0,e.length-1)}function rt({duration:e=300,keyframes:t,times:n,ease:o="easeInOut"}){const r=Dc(o)?o.map(ri):ri(o),i={done:!1,value:t[0]},s=yu(n&&n.length===t.length?n:vu(t),e),a=pu(s,t,{ease:Array.isArray(r)?r:wu(t,r)});return{calculatedDuration:e,next:l=>(i.value=a(l),i.done=l>=e,i)}}const bu=e=>e!==null;function eo(e,{repeat:t,repeatType:n="loop"},o,r=1){const i=e.filter(bu),a=r<0||t&&n!=="loop"&&t%2===1?0:i.length-1;return!a||o===void 0?i[a]:o}const xu={decay:Qn,inertia:Qn,tween:rt,keyframes:rt,spring:Zt};function Ci(e){typeof e.type=="string"&&(e.type=xu[e.type])}class to{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(t=>{this.resolve=t})}notifyFinished(){this.resolve()}then(t,n){return this.finished.then(t,n)}}const Su=e=>e/100;class no extends to{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.stop=()=>{const{motionValue:n}=this.options;n&&n.updatedAt!==le.now()&&this.tick(le.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),this.options.onStop?.())},this.options=t,this.initAnimation(),this.play(),t.autoplay===!1&&this.pause()}initAnimation(){const{options:t}=this;Ci(t);const{type:n=rt,repeat:o=0,repeatDelay:r=0,repeatType:i,velocity:s=0}=t;let{keyframes:a}=t;const l=n||rt;process.env.NODE_ENV!=="production"&&l!==rt&&Ee(a.length<=2,`Only two keyframes currently supported with spring and inertia animations. Trying to animate ${a}`,"spring-two-frames"),l!==rt&&typeof a[0]!="number"&&(this.mixKeyframes=St(Su,wi(a[0],a[1])),a=[0,100]);const c=l({...t,keyframes:a});i==="mirror"&&(this.mirroredGenerator=l({...t,keyframes:[...a].reverse(),velocity:-s})),c.calculatedDuration===null&&(c.calculatedDuration=Xn(c));const{calculatedDuration:d}=c;this.calculatedDuration=d,this.resolvedDuration=d+r,this.totalDuration=this.resolvedDuration*(o+1)-r,this.generator=c}updateTime(t){const n=Math.round(t-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=n}tick(t,n=!1){const{generator:o,totalDuration:r,mixKeyframes:i,mirroredGenerator:s,resolvedDuration:a,calculatedDuration:l}=this;if(this.startTime===null)return o.next(0);const{delay:c=0,keyframes:d,repeat:u,repeatType:h,repeatDelay:f,type:v,onUpdate:y,finalKeyframe:b}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-r/this.speed,this.startTime)),n?this.currentTime=t:this.updateTime(t);const w=this.currentTime-c*(this.playbackSpeed>=0?1:-1),T=this.playbackSpeed>=0?w<0:w>r;this.currentTime=Math.max(w,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=r);let C=this.currentTime,k=o;if(u){const $=Math.min(this.currentTime,r)/a;let D=Math.floor($),F=$%1;!F&&$>=1&&(F=1),F===1&&D--,D=Math.min(D,u+1),D%2&&(h==="reverse"?(F=1-F,f&&(F-=f/a)):h==="mirror"&&(k=s)),C=$e(0,1,F)*a}const x=T?{done:!1,value:d[0]}:k.next(C);i&&(x.value=i(x.value));let{done:P}=x;!T&&l!==null&&(P=this.playbackSpeed>=0?this.currentTime>=r:this.currentTime<=0);const V=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&P);return V&&v!==Qn&&(x.value=eo(d,this.options,b,this.speed)),y&&y(x.value),V&&this.finish(),x}then(t,n){return this.finished.then(t,n)}get duration(){return pe(this.calculatedDuration)}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+pe(t)}get time(){return pe(this.currentTime)}set time(t){t=Pe(t),this.currentTime=t,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),this.driver?.start(!1)}get speed(){return this.playbackSpeed}set speed(t){this.updateTime(le.now());const n=this.playbackSpeed!==t;this.playbackSpeed=t,n&&(this.time=pe(this.currentTime))}play(){if(this.isStopped)return;const{driver:t=iu,startTime:n}=this.options;this.driver||(this.driver=t(r=>this.tick(r))),this.options.onPlay?.();const o=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=o):this.holdTime!==null?this.startTime=o-this.holdTime:this.startTime||(this.startTime=n??o),this.state==="finished"&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(le.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){this.notifyFinished(),this.teardown(),this.state="finished",this.options.onComplete?.()}cancel(){this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),this.options.onCancel?.()}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}attachTimeline(t){return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),this.driver?.stop(),t.observe(this)}}function Cu(e){for(let t=1;t<e.length;t++)e[t]??(e[t]=e[t-1])}const We=e=>e*180/Math.PI,oo=e=>{const t=We(Math.atan2(e[1],e[0]));return ro(t)},Tu={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:oo,rotateZ:oo,skewX:e=>We(Math.atan(e[1])),skewY:e=>We(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},ro=e=>(e=e%360,e<0&&(e+=360),e),Ti=oo,$i=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),Pi=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),$u={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:$i,scaleY:Pi,scale:e=>($i(e)+Pi(e))/2,rotateX:e=>ro(We(Math.atan2(e[6],e[5]))),rotateY:e=>ro(We(Math.atan2(-e[2],e[0]))),rotateZ:Ti,rotate:Ti,skewX:e=>We(Math.atan(e[4])),skewY:e=>We(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function io(e){return e.includes("scale")?1:0}function so(e,t){if(!e||e==="none")return io(t);const n=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let o,r;if(n)o=$u,r=n;else{const a=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);o=Tu,r=a}if(!r)return io(t);const i=o[t],s=r[1].split(",").map(ku);return typeof i=="function"?i(s):s[i]}const Pu=(e,t)=>{const{transform:n="none"}=getComputedStyle(e);return so(n,t)};function ku(e){return parseFloat(e.trim())}const it=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],st=new Set(it),ki=e=>e===nt||e===M,Mu=new Set(["x","y","z"]),Vu=it.filter(e=>!Mu.has(e));function Eu(e){const t=[];return Vu.forEach(n=>{const o=e.getValue(n);o!==void 0&&(t.push([n,o.get()]),o.set(n.startsWith("scale")?1:0))}),t}const Ne={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:(e,{transform:t})=>so(t,"x"),y:(e,{transform:t})=>so(t,"y")};Ne.translateX=Ne.x,Ne.translateY=Ne.y;const qe=new Set;let ao=!1,lo=!1,co=!1;function Mi(){if(lo){const e=Array.from(qe).filter(o=>o.needsMeasurement),t=new Set(e.map(o=>o.element)),n=new Map;t.forEach(o=>{const r=Eu(o);r.length&&(n.set(o,r),o.render())}),e.forEach(o=>o.measureInitialState()),t.forEach(o=>{o.render();const r=n.get(o);r&&r.forEach(([i,s])=>{o.getValue(i)?.set(s)})}),e.forEach(o=>o.measureEndState()),e.forEach(o=>{o.suspendedScrollY!==void 0&&window.scrollTo(0,o.suspendedScrollY)})}lo=!1,ao=!1,qe.forEach(e=>e.complete(co)),qe.clear()}function Vi(){qe.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(lo=!0)})}function Du(){co=!0,Vi(),Mi(),co=!1}class uo{constructor(t,n,o,r,i,s=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=n,this.name=o,this.motionValue=r,this.element=i,this.isAsync=s}scheduleResolve(){this.state="scheduled",this.isAsync?(qe.add(this),ao||(ao=!0,K.read(Vi),K.resolveKeyframes(Mi))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:n,element:o,motionValue:r}=this;if(t[0]===null){const i=r?.get(),s=t[t.length-1];if(i!==void 0)t[0]=i;else if(o&&n){const a=o.readValue(n,s);a!=null&&(t[0]=a)}t[0]===void 0&&(t[0]=s),r&&i===void 0&&r.set(t[0])}Cu(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),qe.delete(this)}cancel(){this.state==="scheduled"&&(qe.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const Fu=e=>e.startsWith("--");function Au(e,t,n){Fu(t)?e.style.setProperty(t,n):e.style[t]=n}const Iu=Ln(()=>window.ScrollTimeline!==void 0),Lu={};function Ru(e,t){const n=Ln(e);return()=>Lu[t]??n()}const Ei=Ru(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),Vt=([e,t,n,o])=>`cubic-bezier(${e}, ${t}, ${n}, ${o})`,Di={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:Vt([0,.65,.55,1]),circOut:Vt([.55,0,1,.45]),backIn:Vt([.31,.01,.66,-.59]),backOut:Vt([.33,1.53,.69,.99])};function Fi(e,t){if(e)return typeof e=="function"?Ei()?bi(e,t):"ease-out":ni(e)?Vt(e):Array.isArray(e)?e.map(n=>Fi(n,t)||Di.easeOut):Di[e]}function _u(e,t,n,{delay:o=0,duration:r=300,repeat:i=0,repeatType:s="loop",ease:a="easeOut",times:l}={},c=void 0){const d={[t]:n};l&&(d.offset=l);const u=Fi(a,r);Array.isArray(u)&&(d.easing=u);const h={delay:o,duration:r,easing:Array.isArray(u)?"linear":u,fill:"both",iterations:i+1,direction:s==="reverse"?"alternate":"normal"};return c&&(h.pseudoElement=c),e.animate(d,h)}function Ai(e){return typeof e=="function"&&"applyToOptions"in e}function Nu({type:e,...t}){return Ai(e)&&Ei()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}class Bu extends to{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,this.manualStartTime=null,!t)return;const{element:n,name:o,keyframes:r,pseudoElement:i,allowFlatten:s=!1,finalKeyframe:a,onComplete:l}=t;this.isPseudoElement=!!i,this.allowFlatten=s,this.options=t,Ee(typeof t.type!="string",`Mini animate() doesn't support "type" as a string.`,"mini-spring");const c=Nu(t);this.animation=_u(n,o,r,c,i),c.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!i){const d=eo(r,this.options,a,this.speed);this.updateMotionValue?this.updateMotionValue(d):Au(n,o,d),this.animation.cancel()}l?.(),this.notifyFinished()}}play(){this.isStopped||(this.manualStartTime=null,this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){this.animation.finish?.()}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;const{state:t}=this;t==="idle"||t==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){this.isPseudoElement||this.animation.commitStyles?.()}get duration(){const t=this.animation.effect?.getComputedTiming?.().duration||0;return pe(Number(t))}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+pe(t)}get time(){return pe(Number(this.animation.currentTime)||0)}set time(t){this.manualStartTime=null,this.finishedTime=null,this.animation.currentTime=Pe(t)}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return this.manualStartTime??Number(this.animation.startTime)}set startTime(t){this.manualStartTime=this.animation.startTime=t}attachTimeline({timeline:t,observe:n}){return this.allowFlatten&&this.animation.effect?.updateTiming({easing:"linear"}),this.animation.onfinish=null,t&&Iu()?(this.animation.timeline=t,me):n(this)}}const Ii={anticipate:Jr,backInOut:Zr,circInOut:ei};function zu(e){return e in Ii}function Ou(e){typeof e.ease=="string"&&zu(e.ease)&&(e.ease=Ii[e.ease])}const fo=10;class Hu extends Bu{constructor(t){Ou(t),Ci(t),super(t),t.startTime!==void 0&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){const{motionValue:n,onUpdate:o,onComplete:r,element:i,...s}=this.options;if(!n)return;if(t!==void 0){n.set(t);return}const a=new no({...s,autoplay:!1}),l=Math.max(fo,le.now()-this.startTime),c=$e(0,fo,l-fo);n.setWithVelocity(a.sample(Math.max(0,l-c)).value,a.sample(l).value,c),a.stop()}}const Li=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(_e.test(e)||e==="0")&&!e.startsWith("url("));function ju(e){const t=e[0];if(e.length===1)return!0;for(let n=0;n<e.length;n++)if(e[n]!==t)return!0}function Gu(e,t,n,o){const r=e[0];if(r===null)return!1;if(t==="display"||t==="visibility")return!0;const i=e[e.length-1],s=Li(r,t),a=Li(i,t);return tt(s===a,`You are trying to animate ${t} from "${r}" to "${i}". "${s?i:r}" is not an animatable value.`,"value-not-animatable"),!s||!a?!1:ju(e)||(n==="spring"||Ai(n))&&o}function ho(e){e.duration=0,e.type="keyframes"}const Uu=new Set(["opacity","clipPath","filter","transform"]),Ku=Ln(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function Wu(e){const{motionValue:t,name:n,repeatDelay:o,repeatType:r,damping:i,type:s}=e;if(!(t?.owner?.current instanceof HTMLElement))return!1;const{onUpdate:l,transformTemplate:c}=t.owner.getProps();return Ku()&&n&&Uu.has(n)&&(n!=="transform"||!c)&&!l&&!o&&r!=="mirror"&&i!==0&&s!=="inertia"}const qu=40;class Yu extends to{constructor({autoplay:t=!0,delay:n=0,type:o="keyframes",repeat:r=0,repeatDelay:i=0,repeatType:s="loop",keyframes:a,name:l,motionValue:c,element:d,...u}){super(),this.stop=()=>{this._animation&&(this._animation.stop(),this.stopTimeline?.()),this.keyframeResolver?.cancel()},this.createdAt=le.now();const h={autoplay:t,delay:n,type:o,repeat:r,repeatDelay:i,repeatType:s,name:l,motionValue:c,element:d,...u},f=d?.KeyframeResolver||uo;this.keyframeResolver=new f(a,(v,y,b)=>this.onKeyframesResolved(v,y,h,!b),l,c,d),this.keyframeResolver?.scheduleResolve()}onKeyframesResolved(t,n,o,r){this.keyframeResolver=void 0;const{name:i,type:s,velocity:a,delay:l,isHandoff:c,onUpdate:d}=o;this.resolvedAt=le.now(),Gu(t,i,s,a)||((De.instantAnimations||!l)&&d?.(eo(t,o,n)),t[0]=t[t.length-1],ho(o),o.repeat=0);const h={startTime:r?this.resolvedAt?this.resolvedAt-this.createdAt>qu?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:n,...o,keyframes:t},f=!c&&Wu(h)?new Hu({...h,element:h.motionValue.owner.current}):new no(h);f.finished.then(()=>this.notifyFinished()).catch(me),this.pendingTimeline&&(this.stopTimeline=f.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=f}get finished(){return this._animation?this.animation.finished:this._finished}then(t,n){return this.finished.finally(t).then(()=>{})}get animation(){return this._animation||(this.keyframeResolver?.resume(),Du()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(t){this.animation.time=t}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){this._animation&&this.animation.cancel(),this.keyframeResolver?.cancel()}}const Xu=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function Zu(e){const t=Xu.exec(e);if(!t)return[,];const[,n,o,r]=t;return[`--${n??o}`,r]}const Ju=4;function Ri(e,t,n=1){Ee(n<=Ju,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`,"max-css-var-depth");const[o,r]=Zu(e);if(!o)return;const i=window.getComputedStyle(t).getPropertyValue(o);if(i){const s=i.trim();return Hr(s)?parseFloat(s):s}return On(r)?Ri(r,t,n+1):r}function mo(e,t){return e?.[t]??e?.default??e}const Qu={type:"spring",stiffness:500,damping:25,restSpeed:10},ed=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),td={type:"keyframes",duration:.8},nd={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},od=(e,{keyframes:t})=>t.length>2?td:st.has(e)?e.startsWith("scale")?ed(t[1]):Qu:nd;function rd({when:e,delay:t,delayChildren:n,staggerChildren:o,staggerDirection:r,repeat:i,repeatType:s,repeatDelay:a,from:l,elapsed:c,...d}){return!!Object.keys(d).length}const id=e=>e!==null;function sd(e,{repeat:t,repeatType:n="loop"},o){const r=e.filter(id),i=t&&n!=="loop"&&t%2===1?0:r.length-1;return r[i]}function _i(e,t,n,o=0,r=1){const i=Array.from(e).sort((c,d)=>c.sortNodePosition(d)).indexOf(t),s=e.size,a=(s-1)*o;return typeof n=="function"?n(i,s):r===1?i*o:a-i*o}const po=(e,t,n,o={},r,i)=>s=>{const a=mo(o,e)||{},l=a.delay||o.delay||0;let{elapsed:c=0}=o;c=c-Pe(l);const d={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...a,delay:-c,onUpdate:h=>{t.set(h),a.onUpdate&&a.onUpdate(h)},onComplete:()=>{s(),a.onComplete&&a.onComplete()},name:e,motionValue:t,element:i?void 0:r};rd(a)||Object.assign(d,od(e,d)),d.duration&&(d.duration=Pe(d.duration)),d.repeatDelay&&(d.repeatDelay=Pe(d.repeatDelay)),d.from!==void 0&&(d.keyframes[0]=d.from);let u=!1;if((d.type===!1||d.duration===0&&!d.repeatDelay)&&(ho(d),d.delay===0&&(u=!0)),(De.instantAnimations||De.skipAnimations)&&(u=!0,ho(d),d.delay=0),d.allowFlatten=!a.type&&!a.ease,u&&!i&&t.get()!==void 0){const h=sd(d.keyframes,a);if(h!==void 0){K.update(()=>{d.onUpdate(h),d.onComplete()});return}}return a.isSync?new no(d):new Yu(d)},Ni=new Set(["width","height","top","left","right","bottom",...it]),Bi=30,ad=e=>!isNaN(parseFloat(e));class ld{constructor(t,n={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=o=>{const r=le.now();if(this.updatedAt!==r&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(o),this.current!==this.prev&&(this.events.change?.notify(this.current),this.dependents))for(const i of this.dependents)i.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=n.owner}setCurrent(t){this.current=t,this.updatedAt=le.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=ad(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return process.env.NODE_ENV!=="production"&&_n(!1,'value.onChange(callback) is deprecated. Switch to value.on("change", callback).'),this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new Rn);const o=this.events[t].add(n);return t==="change"?()=>{o(),K.read(()=>{this.events.change.getSize()||this.stop()})}:o}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t)}setWithVelocity(t,n,o){this.set(n),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-o}jump(t,n=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){this.events.change?.notify(this.current)}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t)}removeDependent(t){this.dependents&&this.dependents.delete(t)}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const t=le.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>Bi)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,Bi);return Ur(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.dependents?.clear(),this.events.destroy?.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function at(e,t){return new ld(e,t)}function zi(e){const t=[{},{}];return e?.values.forEach((n,o)=>{t[0][o]=n.get(),t[1][o]=n.getVelocity()}),t}function go(e,t,n,o){if(typeof t=="function"){const[r,i]=zi(o);t=t(n!==void 0?n:e.custom,r,i)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[r,i]=zi(o);t=t(n!==void 0?n:e.custom,r,i)}return t}function lt(e,t,n){const o=e.getProps();return go(o,t,n!==void 0?n:o.custom,e)}const vo=e=>Array.isArray(e);function cd(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,at(n))}function ud(e){return vo(e)?e[e.length-1]||0:e}function dd(e,t){const n=lt(e,t);let{transitionEnd:o={},transition:r={},...i}=n||{};i={...i,...o};for(const s in i){const a=ud(i[s]);cd(e,s,a)}}const ie=e=>!!(e&&e.getVelocity);function fd(e){return!!(ie(e)&&e.add)}function yo(e,t){const n=e.getValue("willChange");if(fd(n))return n.add(t);if(!n&&De.WillChange){const o=new De.WillChange("auto");e.addValue("willChange",o),o.add(t)}}function wo(e){return e.replace(/([A-Z])/g,t=>`-${t.toLowerCase()}`)}const Oi="data-"+wo("framerAppearId");function Hi(e){return e.props[Oi]}function hd({protectedKeys:e,needsAnimating:t},n){const o=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,o}function ji(e,t,{delay:n=0,transitionOverride:o,type:r}={}){let{transition:i=e.getDefaultTransition(),transitionEnd:s,...a}=t;o&&(i=o);const l=[],c=r&&e.animationState&&e.animationState.getState()[r];for(const d in a){const u=e.getValue(d,e.latestValues[d]??null),h=a[d];if(h===void 0||c&&hd(c,d))continue;const f={delay:n,...mo(i||{},d)},v=u.get();if(v!==void 0&&!u.isAnimating&&!Array.isArray(h)&&h===v&&!f.velocity)continue;let y=!1;if(window.MotionHandoffAnimation){const w=Hi(e);if(w){const T=window.MotionHandoffAnimation(w,d,K);T!==null&&(f.startTime=T,y=!0)}}yo(e,d),u.start(po(d,u,h,e.shouldReduceMotion&&Ni.has(d)?{type:!1}:f,e,y));const b=u.animation;b&&l.push(b)}return s&&Promise.all(l).then(()=>{K.update(()=>{s&&dd(e,s)})}),l}function bo(e,t,n={}){const o=lt(e,t,n.type==="exit"?e.presenceContext?.custom:void 0);let{transition:r=e.getDefaultTransition()||{}}=o||{};n.transitionOverride&&(r=n.transitionOverride);const i=o?()=>Promise.all(ji(e,o,n)):()=>Promise.resolve(),s=e.variantChildren&&e.variantChildren.size?(l=0)=>{const{delayChildren:c=0,staggerChildren:d,staggerDirection:u}=r;return md(e,t,l,c,d,u,n)}:()=>Promise.resolve(),{when:a}=r;if(a){const[l,c]=a==="beforeChildren"?[i,s]:[s,i];return l().then(()=>c())}else return Promise.all([i(),s(n.delay)])}function md(e,t,n=0,o=0,r=0,i=1,s){const a=[];for(const l of e.variantChildren)l.notify("AnimationStart",t),a.push(bo(l,t,{...s,delay:n+(typeof o=="function"?0:o)+_i(e.variantChildren,l,o,r,i)}).then(()=>l.notify("AnimationComplete",t)));return Promise.all(a)}function pd(e,t,n={}){e.notify("AnimationStart",t);let o;if(Array.isArray(t)){const r=t.map(i=>bo(e,i,n));o=Promise.all(r)}else if(typeof t=="string")o=bo(e,t,n);else{const r=typeof t=="function"?lt(e,t,n.custom):t;o=Promise.all(ji(e,r,n))}return o.then(()=>{e.notify("AnimationComplete",t)})}const gd={test:e=>e==="auto",parse:e=>e},Gi=e=>t=>t.test(e),Ui=[nt,M,ke,Re,jc,Hc,gd],Ki=e=>Ui.find(Gi(e));function vd(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||Gr(e):!0}const yd=new Set(["brightness","contrast","saturate","opacity"]);function wd(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[o]=n.match(Hn)||[];if(!o)return e;const r=n.replace(o,"");let i=yd.has(t)?1:0;return o!==n&&(i*=100),t+"("+i+r+")"}const bd=/\b([a-z-]*)\(.*?\)/gu,xo={..._e,getAnimatableNone:e=>{const t=e.match(bd);return t?t.map(wd).join(" "):e}},Wi={...nt,transform:Math.round},So={borderWidth:M,borderTopWidth:M,borderRightWidth:M,borderBottomWidth:M,borderLeftWidth:M,borderRadius:M,radius:M,borderTopLeftRadius:M,borderTopRightRadius:M,borderBottomRightRadius:M,borderBottomLeftRadius:M,width:M,maxWidth:M,height:M,maxHeight:M,top:M,right:M,bottom:M,left:M,inset:M,insetBlock:M,insetBlockStart:M,insetBlockEnd:M,insetInline:M,insetInlineStart:M,insetInlineEnd:M,padding:M,paddingTop:M,paddingRight:M,paddingBottom:M,paddingLeft:M,paddingBlock:M,paddingBlockStart:M,paddingBlockEnd:M,paddingInline:M,paddingInlineStart:M,paddingInlineEnd:M,margin:M,marginTop:M,marginRight:M,marginBottom:M,marginLeft:M,marginBlock:M,marginBlockStart:M,marginBlockEnd:M,marginInline:M,marginInlineStart:M,marginInlineEnd:M,backgroundPositionX:M,backgroundPositionY:M,...{rotate:Re,rotateX:Re,rotateY:Re,rotateZ:Re,scale:qt,scaleX:qt,scaleY:qt,scaleZ:qt,skew:Re,skewX:Re,skewY:Re,distance:M,translateX:M,translateY:M,translateZ:M,x:M,y:M,z:M,perspective:M,transformPerspective:M,opacity:$t,originX:ui,originY:ui,originZ:M},zIndex:Wi,fillOpacity:$t,strokeOpacity:$t,numOctaves:Wi},xd={...So,color:J,backgroundColor:J,outlineColor:J,fill:J,stroke:J,borderColor:J,borderTopColor:J,borderRightColor:J,borderBottomColor:J,borderLeftColor:J,filter:xo,WebkitFilter:xo},qi=e=>xd[e];function Yi(e,t){let n=qi(e);return n!==xo&&(n=_e),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const Sd=new Set(["auto","none","0"]);function Cd(e,t,n){let o=0,r;for(;o<e.length&&!r;){const i=e[o];typeof i=="string"&&!Sd.has(i)&&Mt(i).values.length&&(r=e[o]),o++}if(r&&n)for(const i of t)e[i]=Yi(n,r)}class Td extends uo{constructor(t,n,o,r,i){super(t,n,o,r,i,!0)}readKeyframes(){const{unresolvedKeyframes:t,element:n,name:o}=this;if(!n||!n.current)return;super.readKeyframes();for(let d=0;d<t.length;d++){let u=t[d];if(typeof u=="string"&&(u=u.trim(),On(u))){const h=Ri(u,n.current);h!==void 0&&(t[d]=h),d===t.length-1&&(this.finalKeyframe=u)}}if(this.resolveNoneKeyframes(),!Ni.has(o)||t.length!==2)return;const[r,i]=t,s=Ki(r),a=Ki(i),l=li(r),c=li(i);if(l!==c&&Ne[o]){this.needsMeasurement=!0;return}if(s!==a)if(ki(s)&&ki(a))for(let d=0;d<t.length;d++){const u=t[d];typeof u=="string"&&(t[d]=parseFloat(u))}else Ne[o]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){const{unresolvedKeyframes:t,name:n}=this,o=[];for(let r=0;r<t.length;r++)(t[r]===null||vd(t[r]))&&o.push(r);o.length&&Cd(t,o,n)}measureInitialState(){const{element:t,unresolvedKeyframes:n,name:o}=this;if(!t||!t.current)return;o==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=Ne[o](t.measureViewportBox(),window.getComputedStyle(t.current)),n[0]=this.measuredOrigin;const r=n[n.length-1];r!==void 0&&t.getValue(o,r).jump(r,!1)}measureEndState(){const{element:t,name:n,unresolvedKeyframes:o}=this;if(!t||!t.current)return;const r=t.getValue(n);r&&r.jump(this.measuredOrigin,!1);const i=o.length-1,s=o[i];o[i]=Ne[n](t.measureViewportBox(),window.getComputedStyle(t.current)),s!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=s),this.removedTransforms?.length&&this.removedTransforms.forEach(([a,l])=>{t.getValue(a).set(l)}),this.resolveNoneKeyframes()}}function $d(e,t,n){if(e instanceof EventTarget)return[e];if(typeof e=="string"){let o=document;const r=n?.[e]??o.querySelectorAll(e);return r?Array.from(r):[]}return Array.from(e)}const Xi=(e,t)=>t&&typeof e=="number"?t.transform(e):e;function Zi(e){return jr(e)&&"offsetHeight"in e}const{schedule:Co}=ii(queueMicrotask,!1),we={x:!1,y:!1};function Ji(){return we.x||we.y}function Pd(e){return e==="x"||e==="y"?we[e]?null:(we[e]=!0,()=>{we[e]=!1}):we.x||we.y?null:(we.x=we.y=!0,()=>{we.x=we.y=!1})}function Qi(e,t){const n=$d(e),o=new AbortController,r={passive:!0,...t,signal:o.signal};return[n,r,()=>o.abort()]}function es(e){return!(e.pointerType==="touch"||Ji())}function kd(e,t,n={}){const[o,r,i]=Qi(e,n),s=a=>{if(!es(a))return;const{target:l}=a,c=t(l,a);if(typeof c!="function"||!l)return;const d=u=>{es(u)&&(c(u),l.removeEventListener("pointerleave",d))};l.addEventListener("pointerleave",d,r)};return o.forEach(a=>{a.addEventListener("pointerenter",s,r)}),i}const ts=(e,t)=>t?e===t?!0:ts(e,t.parentElement):!1,To=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1,Md=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function ns(e){return Md.has(e.tagName)||e.isContentEditable===!0}const Jt=new WeakSet;function os(e){return t=>{t.key==="Enter"&&e(t)}}function $o(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}const Vd=(e,t)=>{const n=e.currentTarget;if(!n)return;const o=os(()=>{if(Jt.has(n))return;$o(n,"down");const r=os(()=>{$o(n,"up")}),i=()=>$o(n,"cancel");n.addEventListener("keyup",r,t),n.addEventListener("blur",i,t)});n.addEventListener("keydown",o,t),n.addEventListener("blur",()=>n.removeEventListener("keydown",o),t)};function rs(e){return To(e)&&!Ji()}function Ed(e,t,n={}){const[o,r,i]=Qi(e,n),s=a=>{const l=a.currentTarget;if(!rs(a))return;Jt.add(l);const c=t(l,a),d=(f,v)=>{window.removeEventListener("pointerup",u),window.removeEventListener("pointercancel",h),Jt.has(l)&&Jt.delete(l),rs(f)&&typeof c=="function"&&c(f,{success:v})},u=f=>{d(f,l===window||l===document||n.useGlobalTarget||ts(l,f.target))},h=f=>{d(f,!1)};window.addEventListener("pointerup",u,r),window.addEventListener("pointercancel",h,r)};return o.forEach(a=>{(n.useGlobalTarget?window:a).addEventListener("pointerdown",s,r),Zi(a)&&(a.addEventListener("focus",c=>Vd(c,r)),!ns(a)&&!a.hasAttribute("tabindex")&&(a.tabIndex=0))}),i}function is(e){return jr(e)&&"ownerSVGElement"in e}function Dd(e){return is(e)&&e.tagName==="svg"}const Fd=[...Ui,J,_e],Ad=e=>Fd.find(Gi(e)),ss=()=>({translate:0,scale:1,origin:0,originPoint:0}),ct=()=>({x:ss(),y:ss()}),as=()=>({min:0,max:0}),ee=()=>({x:as(),y:as()}),Po={current:null},ls={current:!1},Id=typeof window<"u";function Ld(){if(ls.current=!0,!!Id)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>Po.current=e.matches;e.addEventListener("change",t),t()}else Po.current=!1}const Rd=new WeakMap;function Qt(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function Et(e){return typeof e=="string"||Array.isArray(e)}const ko=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],Mo=["initial",...ko];function en(e){return Qt(e.animate)||Mo.some(t=>Et(e[t]))}function cs(e){return!!(en(e)||e.variants)}function _d(e,t,n){for(const o in t){const r=t[o],i=n[o];if(ie(r))e.addValue(o,r);else if(ie(i))e.addValue(o,at(r,{owner:e}));else if(i!==r)if(e.hasValue(o)){const s=e.getValue(o);s.liveStyle===!0?s.jump(r):s.hasAnimated||s.set(r)}else{const s=e.getStaticValue(o);e.addValue(o,at(s!==void 0?s:r,{owner:e}))}}for(const o in n)t[o]===void 0&&e.removeValue(o);return t}const us=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];let tn={};function ds(e){tn=e}function Nd(){return tn}class Bd{scrapeMotionValuesFromProps(t,n,o){return{}}constructor({parent:t,props:n,presenceContext:o,reducedMotionConfig:r,blockInitialAnimation:i,visualState:s},a={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=uo,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const h=le.now();this.renderScheduledAt<h&&(this.renderScheduledAt=h,K.render(this.render,!1,!0))};const{latestValues:l,renderState:c}=s;this.latestValues=l,this.baseTarget={...l},this.initialValues=n.initial?{...l}:{},this.renderState=c,this.parent=t,this.props=n,this.presenceContext=o,this.depth=t?t.depth+1:0,this.reducedMotionConfig=r,this.options=a,this.blockInitialAnimation=!!i,this.isControllingVariants=en(n),this.isVariantNode=cs(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:d,...u}=this.scrapeMotionValuesFromProps(n,{},this);for(const h in u){const f=u[h];l[h]!==void 0&&ie(f)&&f.set(l[h])}}mount(t){this.current=t,Rd.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((n,o)=>this.bindToMotionValue(o,n)),this.reducedMotionConfig==="never"?this.shouldReduceMotion=!1:this.reducedMotionConfig==="always"?this.shouldReduceMotion=!0:(ls.current||Ld(),this.shouldReduceMotion=Po.current),process.env.NODE_ENV!=="production"&&_n(this.shouldReduceMotion!==!0,"You have Reduced Motion enabled on your device. Animations may not appear as expected.","reduced-motion-disabled"),this.parent?.addChild(this),this.update(this.props,this.presenceContext)}unmount(){this.projection&&this.projection.unmount(),Le(this.notifyUpdate),Le(this.render),this.valueSubscriptions.forEach(t=>t()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent?.removeChild(this);for(const t in this.events)this.events[t].clear();for(const t in this.features){const n=this.features[t];n&&(n.unmount(),n.isMounted=!1)}this.current=null}addChild(t){this.children.add(t),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(t)}removeChild(t){this.children.delete(t),this.enteringChildren&&this.enteringChildren.delete(t)}bindToMotionValue(t,n){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();const o=st.has(t);o&&this.onBindTransform&&this.onBindTransform();const r=n.on("change",s=>{this.latestValues[t]=s,this.props.onUpdate&&K.preRender(this.notifyUpdate),o&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let i;typeof window<"u"&&window.MotionCheckAppearSync&&(i=window.MotionCheckAppearSync(this,t,n)),this.valueSubscriptions.set(t,()=>{r(),i&&i(),n.owner&&n.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in tn){const n=tn[t];if(!n)continue;const{isEnabled:o,Feature:r}=n;if(!this.features[t]&&r&&o(this.props)&&(this.features[t]=new r(this)),this.features[t]){const i=this.features[t];i.isMounted?i.update():(i.mount(),i.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):ee()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let o=0;o<us.length;o++){const r=us[o];this.propEventSubscriptions[r]&&(this.propEventSubscriptions[r](),delete this.propEventSubscriptions[r]);const i="on"+r,s=t[i];s&&(this.propEventSubscriptions[r]=this.on(r,s))}this.prevMotionValues=_d(this,this.scrapeMotionValuesFromProps(t,this.prevProps||{},this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(t){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(t),()=>n.variantChildren.delete(t)}addValue(t,n){const o=this.values.get(t);n!==o&&(o&&this.removeValue(t),this.bindToMotionValue(t,n),this.values.set(t,n),this.latestValues[t]=n.get())}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let o=this.values.get(t);return o===void 0&&n!==void 0&&(o=at(n===null?void 0:n,{owner:this}),this.addValue(t,o)),o}readValue(t,n){let o=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options);return o!=null&&(typeof o=="string"&&(Hr(o)||Gr(o))?o=parseFloat(o):!Ad(o)&&_e.test(n)&&(o=Yi(t,n)),this.setBaseTarget(t,ie(o)?o.get():o)),ie(o)?o.get():o}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){const{initial:n}=this.props;let o;if(typeof n=="string"||typeof n=="object"){const i=go(this.props,n,this.presenceContext?.custom);i&&(o=i[t])}if(n&&o!==void 0)return o;const r=this.getBaseTargetFromProps(this.props,t);return r!==void 0&&!ie(r)?r:this.initialValues[t]!==void 0&&o===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new Rn),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}scheduleRenderMicrotask(){Co.render(this.render)}}class Be{constructor(t){this.isMounted=!1,this.node=t}update(){}}class fs extends Bd{constructor(){super(...arguments),this.KeyframeResolver=Td}sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){const o=t.style;return o?o[n]:void 0}removeValueFromRenderState(t,{vars:n,style:o}){delete n[t],delete o[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;ie(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}function hs({top:e,left:t,right:n,bottom:o}){return{x:{min:t,max:n},y:{min:e,max:o}}}function zd({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function Od(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),o=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:o.y,right:o.x}}function Vo(e){return e===void 0||e===1}function Eo({scale:e,scaleX:t,scaleY:n}){return!Vo(e)||!Vo(t)||!Vo(n)}function Ye(e){return Eo(e)||ms(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function ms(e){return ps(e.x)||ps(e.y)}function ps(e){return e&&e!=="0%"}function nn(e,t,n){const o=e-n,r=t*o;return n+r}function gs(e,t,n,o,r){return r!==void 0&&(e=nn(e,r,o)),nn(e,n,o)+t}function Do(e,t=0,n=1,o,r){e.min=gs(e.min,t,n,o,r),e.max=gs(e.max,t,n,o,r)}function vs(e,{x:t,y:n}){Do(e.x,t.translate,t.scale,t.originPoint),Do(e.y,n.translate,n.scale,n.originPoint)}const ys=.999999999999,ws=1.0000000000001;function Hd(e,t,n,o=!1){const r=n.length;if(!r)return;t.x=t.y=1;let i,s;for(let a=0;a<r;a++){i=n[a],s=i.projectionDelta;const{visualElement:l}=i.options;l&&l.props.style&&l.props.style.display==="contents"||(o&&i.options.layoutScroll&&i.scroll&&i!==i.root&&dt(e,{x:-i.scroll.offset.x,y:-i.scroll.offset.y}),s&&(t.x*=s.x.scale,t.y*=s.y.scale,vs(e,s)),o&&Ye(i.latestValues)&&dt(e,i.latestValues))}t.x<ws&&t.x>ys&&(t.x=1),t.y<ws&&t.y>ys&&(t.y=1)}function ut(e,t){e.min=e.min+t,e.max=e.max+t}function bs(e,t,n,o,r=.5){const i=Y(e.min,e.max,r);Do(e,t,n,i,o)}function dt(e,t){bs(e.x,t.x,t.scaleX,t.scale,t.originX),bs(e.y,t.y,t.scaleY,t.scale,t.originY)}function xs(e,t){return hs(Od(e.getBoundingClientRect(),t))}function jd(e,t,n){const o=xs(e,n),{scroll:r}=t;return r&&(ut(o.x,r.offset.x),ut(o.y,r.offset.y)),o}const Gd={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},Ud=it.length;function Kd(e,t,n){let o="",r=!0;for(let i=0;i<Ud;i++){const s=it[i],a=e[s];if(a===void 0)continue;let l=!0;if(typeof a=="number"?l=a===(s.startsWith("scale")?1:0):l=parseFloat(a)===0,!l||n){const c=Xi(a,So[s]);if(!l){r=!1;const d=Gd[s]||s;o+=`${d}(${c}) `}n&&(t[s]=c)}}return o=o.trim(),n?o=n(t,r?"":o):r&&(o="none"),o}function Fo(e,t,n){const{style:o,vars:r,transformOrigin:i}=e;let s=!1,a=!1;for(const l in t){const c=t[l];if(st.has(l)){s=!0;continue}else if(ai(l)){r[l]=c;continue}else{const d=Xi(c,So[l]);l.startsWith("origin")?(a=!0,i[l]=d):o[l]=d}}if(t.transform||(s||n?o.transform=Kd(t,e.transform,n):o.transform&&(o.transform="none")),a){const{originX:l="50%",originY:c="50%",originZ:d=0}=i;o.transformOrigin=`${l} ${c} ${d}`}}function Ss(e,{style:t,vars:n},o,r){const i=e.style;let s;for(s in t)i[s]=t[s];r?.applyProjectionStyles(i,o);for(s in n)i.setProperty(s,n[s])}function Cs(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const Dt={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(M.test(e))e=parseFloat(e);else return e;const n=Cs(e,t.target.x),o=Cs(e,t.target.y);return`${n}% ${o}%`}},Wd={correct:(e,{treeScale:t,projectionDelta:n})=>{const o=e,r=_e.parse(e);if(r.length>5)return o;const i=_e.createTransformer(e),s=typeof r[0]!="number"?1:0,a=n.x.scale*t.x,l=n.y.scale*t.y;r[0+s]/=a,r[1+s]/=l;const c=Y(a,l,.5);return typeof r[2+s]=="number"&&(r[2+s]/=c),typeof r[3+s]=="number"&&(r[3+s]/=c),i(r)}},Ao={borderRadius:{...Dt,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:Dt,borderTopRightRadius:Dt,borderBottomLeftRadius:Dt,borderBottomRightRadius:Dt,boxShadow:Wd};function Ts(e,{layout:t,layoutId:n}){return st.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!Ao[e]||e==="opacity")}function Io(e,t,n){const o=e.style,r=t?.style,i={};if(!o)return i;for(const s in o)(ie(o[s])||r&&ie(r[s])||Ts(s,e)||n?.getValue(s)?.liveStyle!==void 0)&&(i[s]=o[s]);return i}function qd(e){return window.getComputedStyle(e)}class Yd extends fs{constructor(){super(...arguments),this.type="html",this.renderInstance=Ss}readValueFromInstance(t,n){if(st.has(n))return this.projection?.isProjecting?io(n):Pu(t,n);{const o=qd(t),r=(ai(n)?o.getPropertyValue(n):o[n])||0;return typeof r=="string"?r.trim():r}}measureInstanceViewportBox(t,{transformPagePoint:n}){return xs(t,n)}build(t,n,o){Fo(t,n,o.transformTemplate)}scrapeMotionValuesFromProps(t,n,o){return Io(t,n,o)}}const Xd={offset:"stroke-dashoffset",array:"stroke-dasharray"},Zd={offset:"strokeDashoffset",array:"strokeDasharray"};function Jd(e,t,n=1,o=0,r=!0){e.pathLength=1;const i=r?Xd:Zd;e[i.offset]=M.transform(-o);const s=M.transform(t),a=M.transform(n);e[i.array]=`${s} ${a}`}const Qd=["offsetDistance","offsetPath","offsetRotate","offsetAnchor"];function $s(e,{attrX:t,attrY:n,attrScale:o,pathLength:r,pathSpacing:i=1,pathOffset:s=0,...a},l,c,d){if(Fo(e,a,c),l){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:u,style:h}=e;u.transform&&(h.transform=u.transform,delete u.transform),(h.transform||u.transformOrigin)&&(h.transformOrigin=u.transformOrigin??"50% 50%",delete u.transformOrigin),h.transform&&(h.transformBox=d?.transformBox??"fill-box",delete u.transformBox);for(const f of Qd)u[f]!==void 0&&(h[f]=u[f],delete u[f]);t!==void 0&&(u.x=t),n!==void 0&&(u.y=n),o!==void 0&&(u.scale=o),r!==void 0&&Jd(u,r,i,s,!1)}const Ps=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]),ks=e=>typeof e=="string"&&e.toLowerCase()==="svg";function ef(e,t,n,o){Ss(e,t,void 0,o);for(const r in t.attrs)e.setAttribute(Ps.has(r)?r:wo(r),t.attrs[r])}function Ms(e,t,n){const o=Io(e,t,n);for(const r in e)if(ie(e[r])||ie(t[r])){const i=it.indexOf(r)!==-1?"attr"+r.charAt(0).toUpperCase()+r.substring(1):r;o[i]=e[r]}return o}class tf extends fs{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=ee}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(st.has(n)){const o=qi(n);return o&&o.default||0}return n=Ps.has(n)?n:wo(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,o){return Ms(t,n,o)}build(t,n,o){$s(t,n,this.isSVGTag,o.transformTemplate,o.style)}renderInstance(t,n,o,r){ef(t,n,o,r)}mount(t){this.isSVGTag=ks(t.tagName),super.mount(t)}}const nf=Mo.length;function Vs(e){if(!e)return;if(!e.isControllingVariants){const n=e.parent?Vs(e.parent)||{}:{};return e.props.initial!==void 0&&(n.initial=e.props.initial),n}const t={};for(let n=0;n<nf;n++){const o=Mo[n],r=e.props[o];(Et(r)||r===!1)&&(t[o]=r)}return t}function Es(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let o=0;o<n;o++)if(t[o]!==e[o])return!1;return!0}const of=[...ko].reverse(),rf=ko.length;function sf(e){return t=>Promise.all(t.map(({animation:n,options:o})=>pd(e,n,o)))}function af(e){let t=sf(e),n=Ds(),o=!0;const r=l=>(c,d)=>{const u=lt(e,d,l==="exit"?e.presenceContext?.custom:void 0);if(u){const{transition:h,transitionEnd:f,...v}=u;c={...c,...v,...f}}return c};function i(l){t=l(e)}function s(l){const{props:c}=e,d=Vs(e.parent)||{},u=[],h=new Set;let f={},v=1/0;for(let b=0;b<rf;b++){const w=of[b],T=n[w],C=c[w]!==void 0?c[w]:d[w],k=Et(C),x=w===l?T.isActive:null;x===!1&&(v=b);let P=C===d[w]&&C!==c[w]&&k;if(P&&o&&e.manuallyAnimateOnMount&&(P=!1),T.protectedKeys={...f},!T.isActive&&x===null||!C&&!T.prevProp||Qt(C)||typeof C=="boolean")continue;const V=lf(T.prevProp,C);let $=V||w===l&&T.isActive&&!P&&k||b>v&&k,D=!1;const F=Array.isArray(C)?C:[C];let _=F.reduce(r(w),{});x===!1&&(_={});const{prevResolvedValues:B={}}=T,H={...B,..._},z=L=>{$=!0,h.has(L)&&(D=!0,h.delete(L)),T.needsAnimating[L]=!0;const j=e.getValue(L);j&&(j.liveStyle=!1)};for(const L in H){const j=_[L],oe=B[L];if(f.hasOwnProperty(L))continue;let Q=!1;vo(j)&&vo(oe)?Q=!Es(j,oe):Q=j!==oe,Q?j!=null?z(L):h.add(L):j!==void 0&&h.has(L)?z(L):T.protectedKeys[L]=!0}T.prevProp=C,T.prevResolvedValues=_,T.isActive&&(f={...f,..._}),o&&e.blockInitialAnimation&&($=!1);const G=P&&V;$&&(!G||D)&&u.push(...F.map(L=>{const j={type:w};if(typeof L=="string"&&o&&!G&&e.manuallyAnimateOnMount&&e.parent){const{parent:oe}=e,Q=lt(oe,L);if(oe.enteringChildren&&Q){const{delayChildren:Se}=Q.transition||{};j.delay=_i(oe.enteringChildren,e,Se)}}return{animation:L,options:j}}))}if(h.size){const b={};if(typeof c.initial!="boolean"){const w=lt(e,Array.isArray(c.initial)?c.initial[0]:c.initial);w&&w.transition&&(b.transition=w.transition)}h.forEach(w=>{const T=e.getBaseTarget(w),C=e.getValue(w);C&&(C.liveStyle=!0),b[w]=T??null}),u.push({animation:b})}let y=!!u.length;return o&&(c.initial===!1||c.initial===c.animate)&&!e.manuallyAnimateOnMount&&(y=!1),o=!1,y?t(u):Promise.resolve()}function a(l,c){if(n[l].isActive===c)return Promise.resolve();e.variantChildren?.forEach(u=>u.animationState?.setActive(l,c)),n[l].isActive=c;const d=s(l);for(const u in n)n[u].protectedKeys={};return d}return{animateChanges:s,setActive:a,setAnimateFunction:i,getState:()=>n,reset:()=>{n=Ds()}}}function lf(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!Es(t,e):!1}function Xe(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function Ds(){return{animate:Xe(!0),whileInView:Xe(),whileHover:Xe(),whileTap:Xe(),whileDrag:Xe(),whileFocus:Xe(),exit:Xe()}}const Fs=1e-4,cf=1-Fs,uf=1+Fs,As=.01,df=0-As,ff=0+As;function ce(e){return e.max-e.min}function hf(e,t,n){return Math.abs(e-t)<=n}function Is(e,t,n,o=.5){e.origin=o,e.originPoint=Y(t.min,t.max,e.origin),e.scale=ce(n)/ce(t),e.translate=Y(n.min,n.max,e.origin)-e.originPoint,(e.scale>=cf&&e.scale<=uf||isNaN(e.scale))&&(e.scale=1),(e.translate>=df&&e.translate<=ff||isNaN(e.translate))&&(e.translate=0)}function Ft(e,t,n,o){Is(e.x,t.x,n.x,o?o.originX:void 0),Is(e.y,t.y,n.y,o?o.originY:void 0)}function Ls(e,t,n){e.min=n.min+t.min,e.max=e.min+ce(t)}function mf(e,t,n){Ls(e.x,t.x,n.x),Ls(e.y,t.y,n.y)}function Rs(e,t,n){e.min=t.min-n.min,e.max=e.min+ce(t)}function on(e,t,n){Rs(e.x,t.x,n.x),Rs(e.y,t.y,n.y)}function _s(e,t,n,o,r){return e-=t,e=nn(e,1/n,o),r!==void 0&&(e=nn(e,1/r,o)),e}function pf(e,t=0,n=1,o=.5,r,i=e,s=e){if(ke.test(t)&&(t=parseFloat(t),t=Y(s.min,s.max,t/100)-s.min),typeof t!="number")return;let a=Y(i.min,i.max,o);e===i&&(a-=t),e.min=_s(e.min,t,n,a,r),e.max=_s(e.max,t,n,a,r)}function Ns(e,t,[n,o,r],i,s){pf(e,t[n],t[o],t[r],t.scale,i,s)}const gf=["x","scaleX","originX"],vf=["y","scaleY","originY"];function Bs(e,t,n,o){Ns(e.x,t,gf,n?n.x:void 0,o?o.x:void 0),Ns(e.y,t,vf,n?n.y:void 0,o?o.y:void 0)}function zs(e,t){e.min=t.min,e.max=t.max}function be(e,t){zs(e.x,t.x),zs(e.y,t.y)}function Os(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function Hs(e){return e.translate===0&&e.scale===1}function js(e){return Hs(e.x)&&Hs(e.y)}function Gs(e,t){return e.min===t.min&&e.max===t.max}function yf(e,t){return Gs(e.x,t.x)&&Gs(e.y,t.y)}function Us(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function Ks(e,t){return Us(e.x,t.x)&&Us(e.y,t.y)}function Ws(e){return ce(e.x)/ce(e.y)}function qs(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}function ge(e){return[e("x"),e("y")]}function wf(e,t,n){let o="";const r=e.x.translate/t.x,i=e.y.translate/t.y,s=n?.z||0;if((r||i||s)&&(o=`translate3d(${r}px, ${i}px, ${s}px) `),(t.x!==1||t.y!==1)&&(o+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:c,rotate:d,rotateX:u,rotateY:h,skewX:f,skewY:v}=n;c&&(o=`perspective(${c}px) ${o}`),d&&(o+=`rotate(${d}deg) `),u&&(o+=`rotateX(${u}deg) `),h&&(o+=`rotateY(${h}deg) `),f&&(o+=`skewX(${f}deg) `),v&&(o+=`skewY(${v}deg) `)}const a=e.x.scale*t.x,l=e.y.scale*t.y;return(a!==1||l!==1)&&(o+=`scale(${a}, ${l})`),o||"none"}const Ys=["TopLeft","TopRight","BottomLeft","BottomRight"],bf=Ys.length,Xs=e=>typeof e=="string"?parseFloat(e):e,Zs=e=>typeof e=="number"||M.test(e);function xf(e,t,n,o,r,i){r?(e.opacity=Y(0,n.opacity??1,Sf(o)),e.opacityExit=Y(t.opacity??1,0,Cf(o))):i&&(e.opacity=Y(t.opacity??1,n.opacity??1,o));for(let s=0;s<bf;s++){const a=`border${Ys[s]}Radius`;let l=Js(t,a),c=Js(n,a);if(l===void 0&&c===void 0)continue;l||(l=0),c||(c=0),l===0||c===0||Zs(l)===Zs(c)?(e[a]=Math.max(Y(Xs(l),Xs(c),o),0),(ke.test(c)||ke.test(l))&&(e[a]+="%")):e[a]=c}(t.rotate||n.rotate)&&(e.rotate=Y(t.rotate||0,n.rotate||0,o))}function Js(e,t){return e[t]!==void 0?e[t]:e.borderRadius}const Sf=Qs(0,.5,Qr),Cf=Qs(.5,.95,me);function Qs(e,t,n){return o=>o<e?0:o>t?1:n(Ct(e,t,o))}function Tf(e,t){const n=le.now(),o=({timestamp:r})=>{const i=r-n;i>=t&&(Le(o),e(i-t))};return K.setup(o,!0),()=>Le(o)}function At(e,t,n,o={passive:!0}){return e.addEventListener(t,n,o),()=>e.removeEventListener(t,n)}function rn(e){return ie(e)?e.get():e}function $f(e,t,n){const o=ie(e)?e:at(e);return o.start(po("",o,t,n)),o.animation}const Pf=(e,t)=>e.depth-t.depth;class kf{constructor(){this.children=[],this.isDirty=!1}add(t){Fn(this.children,t),this.isDirty=!0}remove(t){An(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(Pf),this.isDirty=!1,this.children.forEach(t)}}class Mf{constructor(){this.members=[]}add(t){Fn(this.members,t),t.scheduleRender()}remove(t){if(An(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){const n=this.members.findIndex(r=>t===r);if(n===0)return!1;let o;for(let r=n;r>=0;r--){const i=this.members[r];if(i.isPresent!==!1){o=i;break}}return o?(this.promote(o),!0):!1}promote(t,n){const o=this.lead;if(t!==o&&(this.prevLead=o,this.lead=t,t.show(),o)){o.instance&&o.scheduleRender(),t.scheduleRender(),t.resumeFrom=o,n&&(t.resumeFrom.preserveOpacity=!0),o.snapshot&&(t.snapshot=o.snapshot,t.snapshot.latestValues=o.animationValues||o.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);const{crossfade:r}=t.options;r===!1&&o.hide()}}exitAnimationComplete(){this.members.forEach(t=>{const{options:n,resumingFrom:o}=t;n.onExitComplete&&n.onExitComplete(),o&&o.options.onExitComplete&&o.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}const sn={hasAnimatedSinceResize:!0,hasEverUpdated:!1},Lo=["","X","Y","Z"],Vf=1e3;let Ef=0;function Ro(e,t,n,o){const{latestValues:r}=t;r[e]&&(n[e]=r[e],t.setStaticValue(e,0),o&&(o[e]=0))}function ea(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=Hi(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:r,layoutId:i}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",K,!(r||i))}const{parent:o}=e;o&&!o.hasCheckedOptimisedAppear&&ea(o)}function ta({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:o,resetTransform:r}){return class{constructor(s={},a=t?.()){this.id=Ef++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.layoutVersion=0,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(Af),this.nodes.forEach(_f),this.nodes.forEach(Nf),this.nodes.forEach(If)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=s,this.root=a?a.root||a:this,this.path=a?[...a.path,a]:[],this.parent=a,this.depth=a?a.depth+1:0;for(let l=0;l<this.path.length;l++)this.path[l].shouldResetTransform=!0;this.root===this&&(this.nodes=new kf)}addEventListener(s,a){return this.eventHandlers.has(s)||this.eventHandlers.set(s,new Rn),this.eventHandlers.get(s).add(a)}notifyListeners(s,...a){const l=this.eventHandlers.get(s);l&&l.notify(...a)}hasListeners(s){return this.eventHandlers.has(s)}mount(s){if(this.instance)return;this.isSVG=is(s)&&!Dd(s),this.instance=s;const{layoutId:a,layout:l,visualElement:c}=this.options;if(c&&!c.current&&c.mount(s),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(l||a)&&(this.isLayoutDirty=!0),e){let d,u=0;const h=()=>this.root.updateBlockedByResize=!1;K.read(()=>{u=window.innerWidth}),e(s,()=>{const f=window.innerWidth;f!==u&&(u=f,this.root.updateBlockedByResize=!0,d&&d(),d=Tf(h,250),sn.hasAnimatedSinceResize&&(sn.hasAnimatedSinceResize=!1,this.nodes.forEach(ra)))})}a&&this.root.registerSharedNode(a,this),this.options.animate!==!1&&c&&(a||l)&&this.addEventListener("didUpdate",({delta:d,hasLayoutChanged:u,hasRelativeLayoutChanged:h,layout:f})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const v=this.options.transition||c.getDefaultTransition()||jf,{onLayoutAnimationStart:y,onLayoutAnimationComplete:b}=c.getProps(),w=!this.targetLayout||!Ks(this.targetLayout,f),T=!u&&h;if(this.options.layoutRoot||this.resumeFrom||T||u&&(w||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const C={...mo(v,"layout"),onPlay:y,onComplete:b};(c.shouldReduceMotion||this.options.layoutRoot)&&(C.delay=0,C.type=!1),this.startAnimation(C),this.setAnimationOrigin(d,T)}else u||ra(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=f})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const s=this.getStack();s&&s.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),Le(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(Bf),this.animationId++)}getTransformTemplate(){const{visualElement:s}=this.options;return s&&s.getProps().transformTemplate}willUpdate(s=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&ea(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let d=0;d<this.path.length;d++){const u=this.path[d];u.shouldResetTransform=!0,u.updateScroll("snapshot"),u.options.layoutRoot&&u.willUpdate(!1)}const{layoutId:a,layout:l}=this.options;if(a===void 0&&!l)return;const c=this.getTransformTemplate();this.prevTransformTemplateValue=c?c(this.latestValues,""):void 0,this.updateSnapshot(),s&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(na);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(oa);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(Rf),this.nodes.forEach(Df),this.nodes.forEach(Ff)):this.nodes.forEach(oa),this.clearAllSnapshots();const a=le.now();ne.delta=$e(0,1e3/60,a-ne.timestamp),ne.timestamp=a,ne.isProcessing=!0,zn.update.process(ne),zn.preRender.process(ne),zn.render.process(ne),ne.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,Co.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(Lf),this.sharedNodes.forEach(zf)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,K.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){K.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!ce(this.snapshot.measuredBox.x)&&!ce(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let l=0;l<this.path.length;l++)this.path[l].updateScroll();const s=this.layout;this.layout=this.measure(!1),this.layoutVersion++,this.layoutCorrected=ee(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:a}=this.options;a&&a.notify("LayoutMeasure",this.layout.layoutBox,s?s.layoutBox:void 0)}updateScroll(s="measure"){let a=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===s&&(a=!1),a&&this.instance){const l=o(this.instance);this.scroll={animationId:this.root.animationId,phase:s,isRoot:l,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:l}}}resetTransform(){if(!r)return;const s=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,a=this.projectionDelta&&!js(this.projectionDelta),l=this.getTransformTemplate(),c=l?l(this.latestValues,""):void 0,d=c!==this.prevTransformTemplateValue;s&&this.instance&&(a||Ye(this.latestValues)||d)&&(r(this.instance,c),this.shouldResetTransform=!1,this.scheduleRender())}measure(s=!0){const a=this.measurePageBox();let l=this.removeElementScroll(a);return s&&(l=this.removeTransform(l)),Gf(l),{animationId:this.root.animationId,measuredBox:a,layoutBox:l,latestValues:{},source:this.id}}measurePageBox(){const{visualElement:s}=this.options;if(!s)return ee();const a=s.measureViewportBox();if(!(this.scroll?.wasRoot||this.path.some(Uf))){const{scroll:c}=this.root;c&&(ut(a.x,c.offset.x),ut(a.y,c.offset.y))}return a}removeElementScroll(s){const a=ee();if(be(a,s),this.scroll?.wasRoot)return a;for(let l=0;l<this.path.length;l++){const c=this.path[l],{scroll:d,options:u}=c;c!==this.root&&d&&u.layoutScroll&&(d.wasRoot&&be(a,s),ut(a.x,d.offset.x),ut(a.y,d.offset.y))}return a}applyTransform(s,a=!1){const l=ee();be(l,s);for(let c=0;c<this.path.length;c++){const d=this.path[c];!a&&d.options.layoutScroll&&d.scroll&&d!==d.root&&dt(l,{x:-d.scroll.offset.x,y:-d.scroll.offset.y}),Ye(d.latestValues)&&dt(l,d.latestValues)}return Ye(this.latestValues)&&dt(l,this.latestValues),l}removeTransform(s){const a=ee();be(a,s);for(let l=0;l<this.path.length;l++){const c=this.path[l];if(!c.instance||!Ye(c.latestValues))continue;Eo(c.latestValues)&&c.updateSnapshot();const d=ee(),u=c.measurePageBox();be(d,u),Bs(a,c.latestValues,c.snapshot?c.snapshot.layoutBox:void 0,d)}return Ye(this.latestValues)&&Bs(a,this.latestValues),a}setTargetDelta(s){this.targetDelta=s,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(s){this.options={...this.options,...s,crossfade:s.crossfade!==void 0?s.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==ne.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(s=!1){const a=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=a.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=a.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=a.isSharedProjectionDirty);const l=!!this.resumingFrom||this!==a;if(!(s||l&&this.isSharedProjectionDirty||this.isProjectionDirty||this.parent?.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:d,layoutId:u}=this.options;if(!this.layout||!(d||u))return;this.resolvedRelativeTargetAt=ne.timestamp;const h=this.getClosestProjectingParent();h&&this.linkedParentVersion!==h.layoutVersion&&!h.options.layoutRoot&&this.removeRelativeTarget(),!this.targetDelta&&!this.relativeTarget&&(h&&h.layout?this.createRelativeTarget(h,this.layout.layoutBox,h.layout.layoutBox):this.removeRelativeTarget()),!(!this.relativeTarget&&!this.targetDelta)&&(this.target||(this.target=ee(),this.targetWithTransforms=ee()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),mf(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):be(this.target,this.layout.layoutBox),vs(this.target,this.targetDelta)):be(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=!1,h&&!!h.resumingFrom==!!this.resumingFrom&&!h.options.layoutScroll&&h.target&&this.animationProgress!==1?this.createRelativeTarget(h,this.target,h.target):this.relativeParent=this.relativeTarget=void 0))}getClosestProjectingParent(){if(!(!this.parent||Eo(this.parent.latestValues)||ms(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(s,a,l){this.relativeParent=s,this.linkedParentVersion=s.layoutVersion,this.forceRelativeParentToResolveTarget(),this.relativeTarget=ee(),this.relativeTargetOrigin=ee(),on(this.relativeTargetOrigin,a,l),be(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){const s=this.getLead(),a=!!this.resumingFrom||this!==s;let l=!0;if((this.isProjectionDirty||this.parent?.isProjectionDirty)&&(l=!1),a&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(l=!1),this.resolvedRelativeTargetAt===ne.timestamp&&(l=!1),l)return;const{layout:c,layoutId:d}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(c||d))return;be(this.layoutCorrected,this.layout.layoutBox);const u=this.treeScale.x,h=this.treeScale.y;Hd(this.layoutCorrected,this.treeScale,this.path,a),s.layout&&!s.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(s.target=s.layout.layoutBox,s.targetWithTransforms=ee());const{target:f}=s;if(!f){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(Os(this.prevProjectionDelta.x,this.projectionDelta.x),Os(this.prevProjectionDelta.y,this.projectionDelta.y)),Ft(this.projectionDelta,this.layoutCorrected,f,this.latestValues),(this.treeScale.x!==u||this.treeScale.y!==h||!qs(this.projectionDelta.x,this.prevProjectionDelta.x)||!qs(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",f))}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(s=!0){if(this.options.visualElement?.scheduleRender(),s){const a=this.getStack();a&&a.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=ct(),this.projectionDelta=ct(),this.projectionDeltaWithTransform=ct()}setAnimationOrigin(s,a=!1){const l=this.snapshot,c=l?l.latestValues:{},d={...this.latestValues},u=ct();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!a;const h=ee(),f=l?l.source:void 0,v=this.layout?this.layout.source:void 0,y=f!==v,b=this.getStack(),w=!b||b.members.length<=1,T=!!(y&&!w&&this.options.crossfade===!0&&!this.path.some(Hf));this.animationProgress=0;let C;this.mixTargetDelta=k=>{const x=k/1e3;ia(u.x,s.x,x),ia(u.y,s.y,x),this.setTargetDelta(u),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(on(h,this.layout.layoutBox,this.relativeParent.layout.layoutBox),Of(this.relativeTarget,this.relativeTargetOrigin,h,x),C&&yf(this.relativeTarget,C)&&(this.isProjectionDirty=!1),C||(C=ee()),be(C,this.relativeTarget)),y&&(this.animationValues=d,xf(d,c,this.latestValues,x,T,w)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=x},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(s){this.notifyListeners("animationStart"),this.currentAnimation?.stop(),this.resumingFrom?.currentAnimation?.stop(),this.pendingAnimation&&(Le(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=K.update(()=>{sn.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=at(0)),this.currentAnimation=$f(this.motionValue,[0,1e3],{...s,velocity:0,isSync:!0,onUpdate:a=>{this.mixTargetDelta(a),s.onUpdate&&s.onUpdate(a)},onStop:()=>{},onComplete:()=>{s.onComplete&&s.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const s=this.getStack();s&&s.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(Vf),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const s=this.getLead();let{targetWithTransforms:a,target:l,layout:c,latestValues:d}=s;if(!(!a||!l||!c)){if(this!==s&&this.layout&&c&&ua(this.options.animationType,this.layout.layoutBox,c.layoutBox)){l=this.target||ee();const u=ce(this.layout.layoutBox.x);l.x.min=s.target.x.min,l.x.max=l.x.min+u;const h=ce(this.layout.layoutBox.y);l.y.min=s.target.y.min,l.y.max=l.y.min+h}be(a,l),dt(a,d),Ft(this.projectionDeltaWithTransform,this.layoutCorrected,a,d)}}registerSharedNode(s,a){this.sharedNodes.has(s)||this.sharedNodes.set(s,new Mf),this.sharedNodes.get(s).add(a);const c=a.options.initialPromotionConfig;a.promote({transition:c?c.transition:void 0,preserveFollowOpacity:c&&c.shouldPreserveFollowOpacity?c.shouldPreserveFollowOpacity(a):void 0})}isLead(){const s=this.getStack();return s?s.lead===this:!0}getLead(){const{layoutId:s}=this.options;return s?this.getStack()?.lead||this:this}getPrevLead(){const{layoutId:s}=this.options;return s?this.getStack()?.prevLead:void 0}getStack(){const{layoutId:s}=this.options;if(s)return this.root.sharedNodes.get(s)}promote({needsReset:s,transition:a,preserveFollowOpacity:l}={}){const c=this.getStack();c&&c.promote(this,l),s&&(this.projectionDelta=void 0,this.needsReset=!0),a&&this.setOptions({transition:a})}relegate(){const s=this.getStack();return s?s.relegate(this):!1}resetSkewAndRotation(){const{visualElement:s}=this.options;if(!s)return;let a=!1;const{latestValues:l}=s;if((l.z||l.rotate||l.rotateX||l.rotateY||l.rotateZ||l.skewX||l.skewY)&&(a=!0),!a)return;const c={};l.z&&Ro("z",s,c,this.animationValues);for(let d=0;d<Lo.length;d++)Ro(`rotate${Lo[d]}`,s,c,this.animationValues),Ro(`skew${Lo[d]}`,s,c,this.animationValues);s.render();for(const d in c)s.setStaticValue(d,c[d]),this.animationValues&&(this.animationValues[d]=c[d]);s.scheduleRender()}applyProjectionStyles(s,a){if(!this.instance||this.isSVG)return;if(!this.isVisible){s.visibility="hidden";return}const l=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,s.visibility="",s.opacity="",s.pointerEvents=rn(a?.pointerEvents)||"",s.transform=l?l(this.latestValues,""):"none";return}const c=this.getLead();if(!this.projectionDelta||!this.layout||!c.target){this.options.layoutId&&(s.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,s.pointerEvents=rn(a?.pointerEvents)||""),this.hasProjected&&!Ye(this.latestValues)&&(s.transform=l?l({},""):"none",this.hasProjected=!1);return}s.visibility="";const d=c.animationValues||c.latestValues;this.applyTransformsToTarget();let u=wf(this.projectionDeltaWithTransform,this.treeScale,d);l&&(u=l(d,u)),s.transform=u;const{x:h,y:f}=this.projectionDelta;s.transformOrigin=`${h.origin*100}% ${f.origin*100}% 0`,c.animationValues?s.opacity=c===this?d.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:d.opacityExit:s.opacity=c===this?d.opacity!==void 0?d.opacity:"":d.opacityExit!==void 0?d.opacityExit:0;for(const v in Ao){if(d[v]===void 0)continue;const{correct:y,applyTo:b,isCSSVariable:w}=Ao[v],T=u==="none"?d[v]:y(d[v],c);if(b){const C=b.length;for(let k=0;k<C;k++)s[b[k]]=T}else w?this.options.visualElement.renderState.vars[v]=T:s[v]=T}this.options.layoutId&&(s.pointerEvents=c===this?rn(a?.pointerEvents)||"":"none")}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(s=>s.currentAnimation?.stop()),this.root.nodes.forEach(na),this.root.sharedNodes.clear()}}}function Df(e){e.updateLayout()}function Ff(e){const t=e.resumeFrom?.snapshot||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners("didUpdate")){const{layoutBox:n,measuredBox:o}=e.layout,{animationType:r}=e.options,i=t.source!==e.layout.source;r==="size"?ge(d=>{const u=i?t.measuredBox[d]:t.layoutBox[d],h=ce(u);u.min=n[d].min,u.max=u.min+h}):ua(r,t.layoutBox,n)&&ge(d=>{const u=i?t.measuredBox[d]:t.layoutBox[d],h=ce(n[d]);u.max=u.min+h,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[d].max=e.relativeTarget[d].min+h)});const s=ct();Ft(s,n,t.layoutBox);const a=ct();i?Ft(a,e.applyTransform(o,!0),t.measuredBox):Ft(a,n,t.layoutBox);const l=!js(s);let c=!1;if(!e.resumeFrom){const d=e.getClosestProjectingParent();if(d&&!d.resumeFrom){const{snapshot:u,layout:h}=d;if(u&&h){const f=ee();on(f,t.layoutBox,u.layoutBox);const v=ee();on(v,n,h.layoutBox),Ks(f,v)||(c=!0),d.options.layoutRoot&&(e.relativeTarget=v,e.relativeTargetOrigin=f,e.relativeParent=d)}}}e.notifyListeners("didUpdate",{layout:n,snapshot:t,delta:a,layoutDelta:s,hasLayoutChanged:l,hasRelativeLayoutChanged:c})}else if(e.isLead()){const{onExitComplete:n}=e.options;n&&n()}e.options.transition=void 0}function Af(e){e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function If(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function Lf(e){e.clearSnapshot()}function na(e){e.clearMeasurements()}function oa(e){e.isLayoutDirty=!1}function Rf(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function ra(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function _f(e){e.resolveTargetDelta()}function Nf(e){e.calcProjection()}function Bf(e){e.resetSkewAndRotation()}function zf(e){e.removeLeadSnapshot()}function ia(e,t,n){e.translate=Y(t.translate,0,n),e.scale=Y(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function sa(e,t,n,o){e.min=Y(t.min,n.min,o),e.max=Y(t.max,n.max,o)}function Of(e,t,n,o){sa(e.x,t.x,n.x,o),sa(e.y,t.y,n.y,o)}function Hf(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const jf={duration:.45,ease:[.4,0,.1,1]},aa=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),la=aa("applewebkit/")&&!aa("chrome/")?Math.round:me;function ca(e){e.min=la(e.min),e.max=la(e.max)}function Gf(e){ca(e.x),ca(e.y)}function ua(e,t,n){return e==="position"||e==="preserve-aspect"&&!hf(Ws(t),Ws(n),.2)}function Uf(e){return e!==e.root&&e.scroll?.wasRoot}const Kf=ta({attachResizeListener:(e,t)=>At(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),_o={current:void 0},da=ta({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!_o.current){const e=new Kf({});e.mount(window),e.setOptions({layoutScroll:!0}),_o.current=e}return _o.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),No=m.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});function fa(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function Wf(...e){return t=>{let n=!1;const o=e.map(r=>{const i=fa(r,t);return!n&&typeof i=="function"&&(n=!0),i});if(n)return()=>{for(let r=0;r<o.length;r++){const i=o[r];typeof i=="function"?i():fa(e[r],null)}}}}function qf(...e){return Ue.useCallback(Wf(...e),e)}class Yf extends Ue.Component{getSnapshotBeforeUpdate(t){const n=this.props.childRef.current;if(n&&t.isPresent&&!this.props.isPresent){const o=n.offsetParent,r=Zi(o)&&o.offsetWidth||0,i=this.props.sizeRef.current;i.height=n.offsetHeight||0,i.width=n.offsetWidth||0,i.top=n.offsetTop,i.left=n.offsetLeft,i.right=r-i.width-i.left}return null}componentDidUpdate(){}render(){return this.props.children}}function Xf({children:e,isPresent:t,anchorX:n,root:o}){const r=m.useId(),i=m.useRef(null),s=m.useRef({width:0,height:0,top:0,left:0,right:0}),{nonce:a}=m.useContext(No),l=e.props?.ref??e?.ref,c=qf(i,l);return m.useInsertionEffect(()=>{const{width:d,height:u,top:h,left:f,right:v}=s.current;if(t||!i.current||!d||!u)return;const y=n==="left"?`left: ${f}`:`right: ${v}`;i.current.dataset.motionPopId=r;const b=document.createElement("style");a&&(b.nonce=a);const w=o??document.head;return w.appendChild(b),b.sheet&&b.sheet.insertRule(`
168
168
  [data-motion-pop-id="${r}"] {
169
169
  position: absolute !important;
170
170
  width: ${d}px !important;
@@ -172,7 +172,7 @@
172
172
  ${y}px !important;
173
173
  top: ${h}px !important;
174
174
  }
175
- `),()=>{w.contains(b)&&w.removeChild(b)}},[t]),p.jsx(Zf,{isPresent:t,childRef:i,sizeRef:s,children:Ue.cloneElement(e,{ref:c})})}const Qf=({children:e,initial:t,isPresent:n,onExitComplete:o,custom:r,presenceAffectsLayout:i,mode:s,anchorX:a,root:l})=>{const c=En(eh),d=m.useId();let u=!0,h=m.useMemo(()=>(u=!1,{id:d,initial:t,isPresent:n,custom:r,onExitComplete:f=>{c.set(f,!0);for(const v of c.values())if(!v)return;o&&o()},register:f=>(c.set(f,!1),()=>c.delete(f))}),[n,c,o]);return i&&u&&(h={...h}),m.useMemo(()=>{c.forEach((f,v)=>c.set(v,!1))},[n]),Ue.useEffect(()=>{!n&&!c.size&&o&&o()},[n]),s==="popLayout"&&(e=p.jsx(Jf,{isPresent:n,anchorX:a,root:l,children:e})),p.jsx(Ut.Provider,{value:h,children:e})};function eh(){return new Map}function ma(e=!0){const t=m.useContext(Ut);if(t===null)return[!0,null];const{isPresent:n,onExitComplete:o,register:r}=t,i=m.useId();m.useEffect(()=>{if(e)return r(i)},[e]);const s=m.useCallback(()=>e&&o&&o(i),[i,o,e]);return!n&&o?[!1,s]:[!0]}const an=e=>e.key||"";function pa(e){const t=[];return m.Children.forEach(e,n=>{m.isValidElement(n)&&t.push(n)}),t}const At=({children:e,custom:t,initial:n=!0,onExitComplete:o,presenceAffectsLayout:r=!0,mode:i="sync",propagate:s=!1,anchorX:a="left",root:l})=>{const[c,d]=ma(s),u=m.useMemo(()=>pa(e),[e]),h=s&&!c?[]:u.map(an),f=m.useRef(!0),v=m.useRef(u),y=En(()=>new Map),b=m.useRef(new Set),[w,T]=m.useState(u),[C,M]=m.useState(u);Hr(()=>{f.current=!1,v.current=u;for(let V=0;V<C.length;V++){const $=an(C[V]);h.includes($)?(y.delete($),b.current.delete($)):y.get($)!==!0&&y.set($,!1)}},[C,h.length,h.join("-")]);const x=[];if(u!==w){let V=[...u];for(let $=0;$<C.length;$++){const F=C[$],D=an(F);h.includes(D)||(V.splice($,0,F),x.push(F))}return i==="wait"&&x.length&&(V=x),M(pa(V)),T(u),null}process.env.NODE_ENV!=="production"&&i==="wait"&&C.length>1&&console.warn(`You're attempting to animate multiple children within AnimatePresence, but its mode is set to "wait". This will lead to odd visual behaviour.`);const{forceRender:P}=m.useContext(Vn);return p.jsx(p.Fragment,{children:C.map(V=>{const $=an(V),F=s&&!c?!1:u===C||h.includes($),D=()=>{if(b.current.has($))return;if(b.current.add($),y.has($))y.set($,!0);else return;let _=!0;y.forEach(N=>{N||(_=!1)}),_&&(P?.(),M(v.current),s&&d?.(),o&&o())};return p.jsx(Qf,{isPresent:F,initial:!f.current||n?void 0:!1,custom:t,presenceAffectsLayout:r,mode:i,root:l,onExitComplete:F?void 0:D,anchorX:a,children:V},$)})})},ga=m.createContext({strict:!1}),va={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]};let ya=!1;function th(){if(ya)return;const e={};for(const t in va)e[t]={isEnabled:n=>va[t].some(o=>!!n[o])};fs(e),ya=!0}function wa(){return th(),zd()}function nh(e){const t=wa();for(const n in e)t[n]={...t[n],...e[n]};fs(t)}const oh=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function ln(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||oh.has(e)}let ba=e=>!ln(e);function rh(e){typeof e=="function"&&(ba=t=>t.startsWith("on")?!ln(t):e(t))}try{rh(require("@emotion/is-prop-valid").default)}catch{}function ih(e,t,n){const o={};for(const r in e)r==="values"&&typeof e.values=="object"||(ba(r)||n===!0&&ln(r)||!t&&!ln(r)||e.draggable&&r.startsWith("onDrag"))&&(o[r]=e[r]);return o}const cn=m.createContext({});function sh(e,t){if(en(e)){const{initial:n,animate:o}=e;return{initial:n===!1||Vt(n)?n:void 0,animate:Vt(o)?o:void 0}}return e.inherit!==!1?t:{}}function ah(e){const{initial:t,animate:n}=sh(e,m.useContext(cn));return m.useMemo(()=>({initial:t,animate:n}),[xa(t),xa(n)])}function xa(e){return Array.isArray(e)?e.join(" "):e}const Bo=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function Sa(e,t,n){for(const o in t)!ie(t[o])&&!$s(o,n)&&(e[o]=t[o])}function lh({transformTemplate:e},t){return m.useMemo(()=>{const n=Bo();return Do(n,t,e),Object.assign({},n.vars,n.style)},[t])}function ch(e,t){const n=e.style||{},o={};return Sa(o,n,e),Object.assign(o,lh(e,t)),o}function uh(e,t){const n={},o=ch(e,t);return e.drag&&e.dragListener!==!1&&(n.draggable=!1,o.userSelect=o.WebkitUserSelect=o.WebkitTouchCallout="none",o.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=o,n}const Ca=()=>({...Bo(),attrs:{}});function dh(e,t,n,o){const r=m.useMemo(()=>{const i=Ca();return Ps(i,t,ks(o),e.transformTemplate,e.style),{...i.attrs,style:{...i.style}}},[t]);if(e.style){const i={};Sa(i,e.style,e),r.style={...i,...r.style}}return r}const fh=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function No(e){return typeof e!="string"||e.includes("-")?!1:!!(fh.indexOf(e)>-1||/[A-Z]/u.test(e))}function hh(e,t,n,{latestValues:o},r,i=!1,s){const l=(s??No(e)?dh:uh)(t,o,r,e),c=ih(t,typeof e=="string",i),d=e!==m.Fragment?{...c,...l,ref:n}:{},{children:u}=t,h=m.useMemo(()=>ie(u)?u.get():u,[u]);return m.createElement(e,{...d,children:h})}function mh({scrapeMotionValuesFromProps:e,createRenderState:t},n,o,r){return{latestValues:ph(n,o,r,e),renderState:t()}}function ph(e,t,n,o){const r={},i=o(e,{});for(const h in i)r[h]=rn(i[h]);let{initial:s,animate:a}=e;const l=en(e),c=us(e);t&&c&&!l&&e.inherit!==!1&&(s===void 0&&(s=t.initial),a===void 0&&(a=t.animate));let d=n?n.initial===!1:!1;d=d||s===!1;const u=d?a:s;if(u&&typeof u!="boolean"&&!Qt(u)){const h=Array.isArray(u)?u:[u];for(let f=0;f<h.length;f++){const v=po(e,h[f]);if(v){const{transitionEnd:y,transition:b,...w}=v;for(const T in w){let C=w[T];if(Array.isArray(C)){const M=d?C.length-1:0;C=C[M]}C!==null&&(r[T]=C)}for(const T in y)r[T]=y[T]}}}return r}const Ta=e=>(t,n)=>{const o=m.useContext(cn),r=m.useContext(Ut),i=()=>mh(e,t,o,r);return n?i():En(i)},gh=Ta({scrapeMotionValuesFromProps:Ao,createRenderState:Bo}),vh=Ta({scrapeMotionValuesFromProps:Vs,createRenderState:Ca}),yh=Symbol.for("motionComponentSymbol");function wh(e,t,n){const o=m.useRef(n);m.useInsertionEffect(()=>{o.current=n});const r=m.useRef(null);return m.useCallback(i=>{i&&e.onMount?.(i),t&&(i?t.mount(i):t.unmount());const s=o.current;if(typeof s=="function")if(i){const a=s(i);typeof a=="function"&&(r.current=a)}else r.current?(r.current(),r.current=null):s(i);else s&&(s.current=i)},[t])}const $a=m.createContext({});function It(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function bh(e,t,n,o,r,i){const{visualElement:s}=m.useContext(cn),a=m.useContext(ga),l=m.useContext(Ut),c=m.useContext(_o).reducedMotion,d=m.useRef(null);o=o||a.renderer,!d.current&&o&&(d.current=o(e,{visualState:t,parent:s,props:n,presenceContext:l,blockInitialAnimation:l?l.initial===!1:!1,reducedMotionConfig:c,isSVG:i}));const u=d.current,h=m.useContext($a);u&&!u.projection&&r&&(u.type==="html"||u.type==="svg")&&xh(d.current,n,r,h);const f=m.useRef(!1);m.useInsertionEffect(()=>{u&&f.current&&u.update(n,l)});const v=n[Hi],y=m.useRef(!!v&&!window.MotionHandoffIsComplete?.(v)&&window.MotionHasOptimisedAnimation?.(v));return Hr(()=>{u&&(f.current=!0,window.MotionIsMounted=!0,u.updateFeatures(),u.scheduleRenderMicrotask(),y.current&&u.animationState&&u.animationState.animateChanges())}),m.useEffect(()=>{u&&(!y.current&&u.animationState&&u.animationState.animateChanges(),y.current&&(queueMicrotask(()=>{window.MotionHandoffMarkAsComplete?.(v)}),y.current=!1),u.enteringChildren=void 0)}),u}function xh(e,t,n,o){const{layoutId:r,layout:i,drag:s,dragConstraints:a,layoutScroll:l,layoutRoot:c,layoutCrossfade:d}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:Pa(e.parent)),e.projection.setOptions({layoutId:r,layout:i,alwaysMeasureLayout:!!s||a&&It(a),visualElement:e,animationType:typeof i=="string"?i:"both",initialPromotionConfig:o,crossfade:d,layoutScroll:l,layoutRoot:c})}function Pa(e){if(e)return e.options.allowProjection!==!1?e.projection:Pa(e.parent)}function zo(e,{forwardMotionProps:t=!1,type:n}={},o,r){o&&nh(o);const i=n?n==="svg":No(e),s=i?vh:gh;function a(c,d){let u;const h={...m.useContext(_o),...c,layoutId:Sh(c)},{isStatic:f}=h,v=ah(c),y=s(c,f);if(!f&&Or){Ch(h,o);const b=Th(h);u=b.MeasureLayout,v.visualElement=bh(e,y,h,r,b.ProjectionNode,i)}return p.jsxs(cn.Provider,{value:v,children:[u&&v.visualElement?p.jsx(u,{visualElement:v.visualElement,...h}):null,hh(e,c,wh(y,v.visualElement,d),y,f,t,i)]})}a.displayName=`motion.${typeof e=="string"?e:`create(${e.displayName??e.name??""})`}`;const l=m.forwardRef(a);return l[yh]=e,l}function Sh({layoutId:e}){const t=m.useContext(Vn).id;return t&&e!==void 0?t+"-"+e:e}function Ch(e,t){const n=m.useContext(ga).strict;if(process.env.NODE_ENV!=="production"&&t&&n){const o="You have rendered a `motion` component within a `LazyMotion` component. This will break tree shaking. Import and render a `m` component instead.";e.ignoreStrict?et(!1,o,"lazy-strict-mode"):Ee(!1,o,"lazy-strict-mode")}}function Th(e){const t=wa(),{drag:n,layout:o}=t;if(!n&&!o)return{};const r={...n,...o};return{MeasureLayout:n?.isEnabled(e)||o?.isEnabled(e)?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}function $h(e,t){if(typeof Proxy>"u")return zo;const n=new Map,o=(i,s)=>zo(i,s,e,t),r=(i,s)=>(process.env.NODE_ENV!=="production"&&Rn(!1,"motion() is deprecated. Use motion.create() instead."),o(i,s));return new Proxy(r,{get:(i,s)=>s==="create"?o:(n.has(s)||n.set(s,zo(s,void 0,e,t)),n.get(s))})}const Ph=(e,t)=>t.isSVG??No(e)?new of(t):new Zd(t,{allowProjection:e!==m.Fragment});class Mh extends Ne{constructor(t){super(t),t.animationState||(t.animationState=cf(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();Qt(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){this.node.animationState.reset(),this.unmountControls?.()}}let kh=0;class Vh extends Ne{constructor(){super(...arguments),this.id=kh++}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n}=this.node.presenceContext,{isPresent:o}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===o)return;const r=this.node.animationState.setActive("exit",!t);n&&!t&&r.then(()=>{n(this.id)})}mount(){const{register:t,onExitComplete:n}=this.node.presenceContext||{};n&&n(this.id),t&&(this.unmount=t(this.id))}unmount(){}}const Eh={animation:{Feature:Mh},exit:{Feature:Vh}};function Lt(e){return{point:{x:e.pageX,y:e.pageY}}}const Dh=e=>t=>Co(t)&&e(t,Lt(t));function Rt(e,t,n,o){return Ft(e,t,Dh(n),o)}const Ma=({current:e})=>e?e.ownerDocument.defaultView:null,ka=(e,t)=>Math.abs(e-t);function Fh(e,t){const n=ka(e.x,t.x),o=ka(e.y,t.y);return Math.sqrt(n**2+o**2)}const Va=new Set(["auto","scroll"]);class Ea{constructor(t,n,{transformPagePoint:o,contextWindow:r=window,dragSnapToOrigin:i=!1,distanceThreshold:s=3,element:a}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.scrollPositions=new Map,this.removeScrollListeners=null,this.onElementScroll=f=>{this.handleScroll(f.target)},this.onWindowScroll=()=>{this.handleScroll(window)},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const f=Ho(this.lastMoveEventInfo,this.history),v=this.startEvent!==null,y=Fh(f.offset,{x:0,y:0})>=this.distanceThreshold;if(!v&&!y)return;const{point:b}=f,{timestamp:w}=ne;this.history.push({...b,timestamp:w});const{onStart:T,onMove:C}=this.handlers;v||(T&&T(this.lastMoveEvent,f),this.startEvent=this.lastMoveEvent),C&&C(this.lastMoveEvent,f)},this.handlePointerMove=(f,v)=>{this.lastMoveEvent=f,this.lastMoveEventInfo=Oo(v,this.transformPagePoint),U.update(this.updatePoint,!0)},this.handlePointerUp=(f,v)=>{this.end();const{onEnd:y,onSessionEnd:b,resumeAnimation:w}=this.handlers;if((this.dragSnapToOrigin||!this.startEvent)&&w&&w(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const T=Ho(f.type==="pointercancel"?this.lastMoveEventInfo:Oo(v,this.transformPagePoint),this.history);this.startEvent&&y&&y(f,T),b&&b(f,T)},!Co(t))return;this.dragSnapToOrigin=i,this.handlers=n,this.transformPagePoint=o,this.distanceThreshold=s,this.contextWindow=r||window;const l=Lt(t),c=Oo(l,this.transformPagePoint),{point:d}=c,{timestamp:u}=ne;this.history=[{...d,timestamp:u}];const{onSessionStart:h}=n;h&&h(t,Ho(c,this.history)),this.removeListeners=xt(Rt(this.contextWindow,"pointermove",this.handlePointerMove),Rt(this.contextWindow,"pointerup",this.handlePointerUp),Rt(this.contextWindow,"pointercancel",this.handlePointerUp)),a&&this.startScrollTracking(a)}startScrollTracking(t){let n=t.parentElement;for(;n;){const o=getComputedStyle(n);(Va.has(o.overflowX)||Va.has(o.overflowY))&&this.scrollPositions.set(n,{x:n.scrollLeft,y:n.scrollTop}),n=n.parentElement}this.scrollPositions.set(window,{x:window.scrollX,y:window.scrollY}),window.addEventListener("scroll",this.onElementScroll,{capture:!0,passive:!0}),window.addEventListener("scroll",this.onWindowScroll,{passive:!0}),this.removeScrollListeners=()=>{window.removeEventListener("scroll",this.onElementScroll,{capture:!0}),window.removeEventListener("scroll",this.onWindowScroll)}}handleScroll(t){const n=this.scrollPositions.get(t);if(!n)return;const o=t===window,r=o?{x:window.scrollX,y:window.scrollY}:{x:t.scrollLeft,y:t.scrollTop},i={x:r.x-n.x,y:r.y-n.y};i.x===0&&i.y===0||(o?this.lastMoveEventInfo&&(this.lastMoveEventInfo.point.x+=i.x,this.lastMoveEventInfo.point.y+=i.y):this.history.length>0&&(this.history[0].x-=i.x,this.history[0].y-=i.y),this.scrollPositions.set(t,r),U.update(this.updatePoint,!0))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),this.removeScrollListeners&&this.removeScrollListeners(),this.scrollPositions.clear(),Le(this.updatePoint)}}function Oo(e,t){return t?{point:t(e.point)}:e}function Da(e,t){return{x:e.x-t.x,y:e.y-t.y}}function Ho({point:e},t){return{point:e,delta:Da(e,Fa(t)),offset:Da(e,Ah(t)),velocity:Ih(t,.1)}}function Ah(e){return e[0]}function Fa(e){return e[e.length-1]}function Ih(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,o=null;const r=Fa(e);for(;n>=0&&(o=e[n],!(r.timestamp-o.timestamp>Pe(t)));)n--;if(!o)return{x:0,y:0};const i=pe(r.timestamp-o.timestamp);if(i===0)return{x:0,y:0};const s={x:(r.x-o.x)/i,y:(r.y-o.y)/i};return s.x===1/0&&(s.x=0),s.y===1/0&&(s.y=0),s}function Lh(e,{min:t,max:n},o){return t!==void 0&&e<t?e=o?q(t,e,o.min):Math.max(e,t):n!==void 0&&e>n&&(e=o?q(n,e,o.max):Math.min(e,n)),e}function Aa(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function Rh(e,{top:t,left:n,bottom:o,right:r}){return{x:Aa(e.x,n,r),y:Aa(e.y,t,o)}}function Ia(e,t){let n=t.min-e.min,o=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,o]=[o,n]),{min:n,max:o}}function _h(e,t){return{x:Ia(e.x,t.x),y:Ia(e.y,t.y)}}function Bh(e,t){let n=.5;const o=ce(e),r=ce(t);return r>o?n=St(t.min,t.max-o,e.min):o>r&&(n=St(e.min,e.max-r,t.min)),$e(0,1,n)}function Nh(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const jo=.35;function zh(e=jo){return e===!1?e=0:e===!0&&(e=jo),{x:La(e,"left","right"),y:La(e,"top","bottom")}}function La(e,t,n){return{min:Ra(e,t),max:Ra(e,n)}}function Ra(e,t){return typeof e=="number"?e:e[t]||0}const Oh=new WeakMap;class Hh{constructor(t){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=ee(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=t}start(t,{snapToCursor:n=!1,distanceThreshold:o}={}){const{presenceContext:r}=this.visualElement;if(r&&r.isPresent===!1)return;const i=u=>{n?(this.stopAnimation(),this.snapToCursor(Lt(u).point)):this.pauseAnimation()},s=(u,h)=>{this.stopAnimation();const{drag:f,dragPropagation:v,onDragStart:y}=this.getProps();if(f&&!v&&(this.openDragLock&&this.openDragLock(),this.openDragLock=kd(f),!this.openDragLock))return;this.latestPointerEvent=u,this.latestPanInfo=h,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),ge(w=>{let T=this.getAxisMotionValue(w).get()||0;if(Me.test(T)){const{projection:C}=this.visualElement;if(C&&C.layout){const M=C.layout.layoutBox[w];M&&(T=ce(M)*(parseFloat(T)/100))}}this.originPoint[w]=T}),y&&U.postRender(()=>y(u,h)),vo(this.visualElement,"transform");const{animationState:b}=this.visualElement;b&&b.setActive("whileDrag",!0)},a=(u,h)=>{this.latestPointerEvent=u,this.latestPanInfo=h;const{dragPropagation:f,dragDirectionLock:v,onDirectionLock:y,onDrag:b}=this.getProps();if(!f&&!this.openDragLock)return;const{offset:w}=h;if(v&&this.currentDirection===null){this.currentDirection=jh(w),this.currentDirection!==null&&y&&y(this.currentDirection);return}this.updateAxis("x",h.point,w),this.updateAxis("y",h.point,w),this.visualElement.render(),b&&b(u,h)},l=(u,h)=>{this.latestPointerEvent=u,this.latestPanInfo=h,this.stop(u,h),this.latestPointerEvent=null,this.latestPanInfo=null},c=()=>ge(u=>this.getAnimationState(u)==="paused"&&this.getAxisMotionValue(u).animation?.play()),{dragSnapToOrigin:d}=this.getProps();this.panSession=new Ea(t,{onSessionStart:i,onStart:s,onMove:a,onSessionEnd:l,resumeAnimation:c},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:d,distanceThreshold:o,contextWindow:Ma(this.visualElement),element:this.visualElement.current})}stop(t,n){const o=t||this.latestPointerEvent,r=n||this.latestPanInfo,i=this.isDragging;if(this.cancel(),!i||!r||!o)return;const{velocity:s}=r;this.startAnimation(s);const{onDragEnd:a}=this.getProps();a&&U.postRender(()=>a(o,r))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:o}=this.getProps();!o&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",!1)}updateAxis(t,n,o){const{drag:r}=this.getProps();if(!o||!un(t,r,this.currentDirection))return;const i=this.getAxisMotionValue(t);let s=this.originPoint[t]+o[t];this.constraints&&this.constraints[t]&&(s=Lh(s,this.constraints[t],this.elastic[t])),i.set(s)}resolveConstraints(){const{dragConstraints:t,dragElastic:n}=this.getProps(),o=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):this.visualElement.projection?.layout,r=this.constraints;t&&It(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&o?this.constraints=Rh(o.layoutBox,t):this.constraints=!1,this.elastic=zh(n),r!==this.constraints&&o&&this.constraints&&!this.hasMutatedConstraints&&ge(i=>{this.constraints!==!1&&this.getAxisMotionValue(i)&&(this.constraints[i]=Nh(o.layoutBox[i],this.constraints[i]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!It(t))return!1;const o=t.current;Ee(o!==null,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.","drag-constraints-ref");const{projection:r}=this.visualElement;if(!r||!r.layout)return!1;const i=Ud(o,r.root,this.visualElement.getTransformPagePoint());let s=_h(r.layout.layoutBox,i);if(n){const a=n(Hd(s));this.hasMutatedConstraints=!!a,a&&(s=ms(a))}return s}startAnimation(t){const{drag:n,dragMomentum:o,dragElastic:r,dragTransition:i,dragSnapToOrigin:s,onDragTransitionEnd:a}=this.getProps(),l=this.constraints||{},c=ge(d=>{if(!un(d,n,this.currentDirection))return;let u=l&&l[d]||{};s&&(u={min:0,max:0});const h=r?200:1e6,f=r?40:1e7,v={type:"inertia",velocity:o?t[d]:0,bounceStiffness:h,bounceDamping:f,timeConstant:750,restDelta:1,restSpeed:10,...i,...u};return this.startAxisValueAnimation(d,v)});return Promise.all(c).then(a)}startAxisValueAnimation(t,n){const o=this.getAxisMotionValue(t);return vo(this.visualElement,t),o.start(mo(t,o,0,n,this.visualElement,!1))}stopAnimation(){ge(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){ge(t=>this.getAxisMotionValue(t).animation?.pause())}getAnimationState(t){return this.getAxisMotionValue(t).animation?.state}getAxisMotionValue(t){const n=`_drag${t.toUpperCase()}`,o=this.visualElement.getProps(),r=o[n];return r||this.visualElement.getValue(t,(o.initial?o.initial[t]:void 0)||0)}snapToCursor(t){ge(n=>{const{drag:o}=this.getProps();if(!un(n,o,this.currentDirection))return;const{projection:r}=this.visualElement,i=this.getAxisMotionValue(n);if(r&&r.layout){const{min:s,max:a}=r.layout.layoutBox[n],l=i.get()||0;i.set(t[n]-q(s,a,.5)+l)}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:o}=this.visualElement;if(!It(n)||!o||!this.constraints)return;this.stopAnimation();const r={x:0,y:0};ge(s=>{const a=this.getAxisMotionValue(s);if(a&&this.constraints!==!1){const l=a.get();r[s]=Bh({min:l,max:l},this.constraints[s])}});const{transformTemplate:i}=this.visualElement.getProps();this.visualElement.current.style.transform=i?i({},""):"none",o.root&&o.root.updateScroll(),o.updateLayout(),this.resolveConstraints(),ge(s=>{if(!un(s,t,null))return;const a=this.getAxisMotionValue(s),{min:l,max:c}=this.constraints[s];a.set(q(l,c,r[s]))})}addListeners(){if(!this.visualElement.current)return;Oh.set(this.visualElement,this);const t=this.visualElement.current,n=Rt(t,"pointerdown",l=>{const{drag:c,dragListener:d=!0}=this.getProps();c&&d&&!os(l.target)&&this.start(l)}),o=()=>{const{dragConstraints:l}=this.getProps();It(l)&&l.current&&(this.constraints=this.resolveRefConstraints())},{projection:r}=this.visualElement,i=r.addEventListener("measure",o);r&&!r.layout&&(r.root&&r.root.updateScroll(),r.updateLayout()),U.read(o);const s=Ft(window,"resize",()=>this.scalePositionWithinConstraints()),a=r.addEventListener("didUpdate",(({delta:l,hasLayoutChanged:c})=>{this.isDragging&&c&&(ge(d=>{const u=this.getAxisMotionValue(d);u&&(this.originPoint[d]+=l[d].translate,u.set(u.get()+l[d].translate))}),this.visualElement.render())}));return()=>{s(),n(),i(),a&&a()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:o=!1,dragPropagation:r=!1,dragConstraints:i=!1,dragElastic:s=jo,dragMomentum:a=!0}=t;return{...t,drag:n,dragDirectionLock:o,dragPropagation:r,dragConstraints:i,dragElastic:s,dragMomentum:a}}}function un(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function jh(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class Gh extends Ne{constructor(t){super(t),this.removeGroupControls=me,this.removeListeners=me,this.controls=new Hh(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||me}update(){const{dragControls:t}=this.node.getProps(),{dragControls:n}=this.node.prevProps||{};t!==n&&(this.removeGroupControls(),t&&(this.removeGroupControls=t.subscribe(this.controls)))}unmount(){this.removeGroupControls(),this.removeListeners()}}const _a=e=>(t,n)=>{e&&U.postRender(()=>e(t,n))};class Uh extends Ne{constructor(){super(...arguments),this.removePointerDownListener=me}onPointerDown(t){this.session=new Ea(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:Ma(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:o,onPanEnd:r}=this.node.getProps();return{onSessionStart:_a(t),onStart:_a(n),onMove:o,onEnd:(i,s)=>{delete this.session,r&&U.postRender(()=>r(i,s))}}}mount(){this.removePointerDownListener=Rt(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}let Go=!1;class Kh extends m.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:o,layoutId:r}=this.props,{projection:i}=t;i&&(n.group&&n.group.add(i),o&&o.register&&r&&o.register(i),Go&&i.root.didUpdate(),i.addEventListener("animationComplete",()=>{this.safeToRemove()}),i.setOptions({...i.options,onExitComplete:()=>this.safeToRemove()})),sn.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:o,drag:r,isPresent:i}=this.props,{projection:s}=o;return s&&(s.isPresent=i,Go=!0,r||t.layoutDependency!==n||n===void 0||t.isPresent!==i?s.willUpdate():this.safeToRemove(),t.isPresent!==i&&(i?s.promote():s.relegate()||U.postRender(()=>{const a=s.getStack();(!a||!a.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),So.postRender(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:o}=this.props,{projection:r}=t;Go=!0,r&&(r.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(r),o&&o.deregister&&o.deregister(r))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function Ba(e){const[t,n]=ma(),o=m.useContext(Vn);return p.jsx(Kh,{...e,layoutGroup:o,switchLayoutGroup:m.useContext($a),isPresent:t,safeToRemove:n})}const Wh={pan:{Feature:Uh},drag:{Feature:Gh,ProjectionNode:fa,MeasureLayout:Ba}};function Na(e,t,n){const{props:o}=e;e.animationState&&o.whileHover&&e.animationState.setActive("whileHover",n==="Start");const r="onHover"+n,i=o[r];i&&U.postRender(()=>i(t,Lt(t)))}class qh extends Ne{mount(){const{current:t}=this.node;t&&(this.unmount=Vd(t,(n,o)=>(Na(this.node,o,"Start"),r=>Na(this.node,r,"End"))))}unmount(){}}class Yh extends Ne{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=xt(Ft(this.node.current,"focus",()=>this.onFocus()),Ft(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function za(e,t,n){const{props:o}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&o.whileTap&&e.animationState.setActive("whileTap",n==="Start");const r="onTap"+(n==="End"?"":n),i=o[r];i&&U.postRender(()=>i(t,Lt(t)))}class Xh extends Ne{mount(){const{current:t}=this.node;t&&(this.unmount=Fd(t,(n,o)=>(za(this.node,o,"Start"),(r,{success:i})=>za(this.node,r,i?"End":"Cancel")),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}const Uo=new WeakMap,Ko=new WeakMap,Zh=e=>{const t=Uo.get(e.target);t&&t(e)},Jh=e=>{e.forEach(Zh)};function Qh({root:e,...t}){const n=e||document;Ko.has(n)||Ko.set(n,{});const o=Ko.get(n),r=JSON.stringify(t);return o[r]||(o[r]=new IntersectionObserver(Jh,{root:e,...t})),o[r]}function em(e,t,n){const o=Qh(t);return Uo.set(e,n),o.observe(e),()=>{Uo.delete(e),o.unobserve(e)}}const tm={some:0,all:1};class nm extends Ne{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:n,margin:o,amount:r="some",once:i}=t,s={root:n?n.current:void 0,rootMargin:o,threshold:typeof r=="number"?r:tm[r]},a=l=>{const{isIntersecting:c}=l;if(this.isInView===c||(this.isInView=c,i&&!c&&this.hasEnteredView))return;c&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",c);const{onViewportEnter:d,onViewportLeave:u}=this.node.getProps(),h=c?d:u;h&&h(l)};return em(this.node.current,s,a)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(om(t,n))&&this.startObserver()}unmount(){}}function om({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const rm={...Eh,...{inView:{Feature:nm},tap:{Feature:Xh},focus:{Feature:Yh},hover:{Feature:qh}},...Wh,...{layout:{ProjectionNode:fa,MeasureLayout:Ba}}},Fe=$h(rm,Ph),im={sm:g.css`
175
+ `),()=>{w.contains(b)&&w.removeChild(b)}},[t]),p.jsx(Yf,{isPresent:t,childRef:i,sizeRef:s,children:Ue.cloneElement(e,{ref:c})})}const Zf=({children:e,initial:t,isPresent:n,onExitComplete:o,custom:r,presenceAffectsLayout:i,mode:s,anchorX:a,root:l})=>{const c=Dn(Jf),d=m.useId();let u=!0,h=m.useMemo(()=>(u=!1,{id:d,initial:t,isPresent:n,custom:r,onExitComplete:f=>{c.set(f,!0);for(const v of c.values())if(!v)return;o&&o()},register:f=>(c.set(f,!1),()=>c.delete(f))}),[n,c,o]);return i&&u&&(h={...h}),m.useMemo(()=>{c.forEach((f,v)=>c.set(v,!1))},[n]),Ue.useEffect(()=>{!n&&!c.size&&o&&o()},[n]),s==="popLayout"&&(e=p.jsx(Xf,{isPresent:n,anchorX:a,root:l,children:e})),p.jsx(Ut.Provider,{value:h,children:e})};function Jf(){return new Map}function ha(e=!0){const t=m.useContext(Ut);if(t===null)return[!0,null];const{isPresent:n,onExitComplete:o,register:r}=t,i=m.useId();m.useEffect(()=>{if(e)return r(i)},[e]);const s=m.useCallback(()=>e&&o&&o(i),[i,o,e]);return!n&&o?[!1,s]:[!0]}const an=e=>e.key||"";function ma(e){const t=[];return m.Children.forEach(e,n=>{m.isValidElement(n)&&t.push(n)}),t}const It=({children:e,custom:t,initial:n=!0,onExitComplete:o,presenceAffectsLayout:r=!0,mode:i="sync",propagate:s=!1,anchorX:a="left",root:l})=>{const[c,d]=ha(s),u=m.useMemo(()=>ma(e),[e]),h=s&&!c?[]:u.map(an),f=m.useRef(!0),v=m.useRef(u),y=Dn(()=>new Map),b=m.useRef(new Set),[w,T]=m.useState(u),[C,k]=m.useState(u);Or(()=>{f.current=!1,v.current=u;for(let V=0;V<C.length;V++){const $=an(C[V]);h.includes($)?(y.delete($),b.current.delete($)):y.get($)!==!0&&y.set($,!1)}},[C,h.length,h.join("-")]);const x=[];if(u!==w){let V=[...u];for(let $=0;$<C.length;$++){const D=C[$],F=an(D);h.includes(F)||(V.splice($,0,D),x.push(D))}return i==="wait"&&x.length&&(V=x),k(ma(V)),T(u),null}process.env.NODE_ENV!=="production"&&i==="wait"&&C.length>1&&console.warn(`You're attempting to animate multiple children within AnimatePresence, but its mode is set to "wait". This will lead to odd visual behaviour.`);const{forceRender:P}=m.useContext(En);return p.jsx(p.Fragment,{children:C.map(V=>{const $=an(V),D=s&&!c?!1:u===C||h.includes($),F=()=>{if(b.current.has($))return;if(b.current.add($),y.has($))y.set($,!0);else return;let _=!0;y.forEach(B=>{B||(_=!1)}),_&&(P?.(),k(v.current),s&&d?.(),o&&o())};return p.jsx(Zf,{isPresent:D,initial:!f.current||n?void 0:!1,custom:t,presenceAffectsLayout:r,mode:i,root:l,onExitComplete:D?void 0:F,anchorX:a,children:V},$)})})},pa=m.createContext({strict:!1}),ga={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]};let va=!1;function Qf(){if(va)return;const e={};for(const t in ga)e[t]={isEnabled:n=>ga[t].some(o=>!!n[o])};ds(e),va=!0}function ya(){return Qf(),Nd()}function eh(e){const t=ya();for(const n in e)t[n]={...t[n],...e[n]};ds(t)}const th=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function ln(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||th.has(e)}let wa=e=>!ln(e);function nh(e){typeof e=="function"&&(wa=t=>t.startsWith("on")?!ln(t):e(t))}try{nh(require("@emotion/is-prop-valid").default)}catch{}function oh(e,t,n){const o={};for(const r in e)r==="values"&&typeof e.values=="object"||(wa(r)||n===!0&&ln(r)||!t&&!ln(r)||e.draggable&&r.startsWith("onDrag"))&&(o[r]=e[r]);return o}const cn=m.createContext({});function rh(e,t){if(en(e)){const{initial:n,animate:o}=e;return{initial:n===!1||Et(n)?n:void 0,animate:Et(o)?o:void 0}}return e.inherit!==!1?t:{}}function ih(e){const{initial:t,animate:n}=rh(e,m.useContext(cn));return m.useMemo(()=>({initial:t,animate:n}),[ba(t),ba(n)])}function ba(e){return Array.isArray(e)?e.join(" "):e}const Bo=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function xa(e,t,n){for(const o in t)!ie(t[o])&&!Ts(o,n)&&(e[o]=t[o])}function sh({transformTemplate:e},t){return m.useMemo(()=>{const n=Bo();return Fo(n,t,e),Object.assign({},n.vars,n.style)},[t])}function ah(e,t){const n=e.style||{},o={};return xa(o,n,e),Object.assign(o,sh(e,t)),o}function lh(e,t){const n={},o=ah(e,t);return e.drag&&e.dragListener!==!1&&(n.draggable=!1,o.userSelect=o.WebkitUserSelect=o.WebkitTouchCallout="none",o.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=o,n}const Sa=()=>({...Bo(),attrs:{}});function ch(e,t,n,o){const r=m.useMemo(()=>{const i=Sa();return $s(i,t,ks(o),e.transformTemplate,e.style),{...i.attrs,style:{...i.style}}},[t]);if(e.style){const i={};xa(i,e.style,e),r.style={...i,...r.style}}return r}const uh=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function zo(e){return typeof e!="string"||e.includes("-")?!1:!!(uh.indexOf(e)>-1||/[A-Z]/u.test(e))}function dh(e,t,n,{latestValues:o},r,i=!1,s){const l=(s??zo(e)?ch:lh)(t,o,r,e),c=oh(t,typeof e=="string",i),d=e!==m.Fragment?{...c,...l,ref:n}:{},{children:u}=t,h=m.useMemo(()=>ie(u)?u.get():u,[u]);return m.createElement(e,{...d,children:h})}function fh({scrapeMotionValuesFromProps:e,createRenderState:t},n,o,r){return{latestValues:hh(n,o,r,e),renderState:t()}}function hh(e,t,n,o){const r={},i=o(e,{});for(const h in i)r[h]=rn(i[h]);let{initial:s,animate:a}=e;const l=en(e),c=cs(e);t&&c&&!l&&e.inherit!==!1&&(s===void 0&&(s=t.initial),a===void 0&&(a=t.animate));let d=n?n.initial===!1:!1;d=d||s===!1;const u=d?a:s;if(u&&typeof u!="boolean"&&!Qt(u)){const h=Array.isArray(u)?u:[u];for(let f=0;f<h.length;f++){const v=go(e,h[f]);if(v){const{transitionEnd:y,transition:b,...w}=v;for(const T in w){let C=w[T];if(Array.isArray(C)){const k=d?C.length-1:0;C=C[k]}C!==null&&(r[T]=C)}for(const T in y)r[T]=y[T]}}}return r}const Ca=e=>(t,n)=>{const o=m.useContext(cn),r=m.useContext(Ut),i=()=>fh(e,t,o,r);return n?i():Dn(i)},mh=Ca({scrapeMotionValuesFromProps:Io,createRenderState:Bo}),ph=Ca({scrapeMotionValuesFromProps:Ms,createRenderState:Sa}),gh=Symbol.for("motionComponentSymbol");function vh(e,t,n){const o=m.useRef(n);m.useInsertionEffect(()=>{o.current=n});const r=m.useRef(null);return m.useCallback(i=>{i&&e.onMount?.(i),t&&(i?t.mount(i):t.unmount());const s=o.current;if(typeof s=="function")if(i){const a=s(i);typeof a=="function"&&(r.current=a)}else r.current?(r.current(),r.current=null):s(i);else s&&(s.current=i)},[t])}const Ta=m.createContext({});function Lt(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function yh(e,t,n,o,r,i){const{visualElement:s}=m.useContext(cn),a=m.useContext(pa),l=m.useContext(Ut),c=m.useContext(No).reducedMotion,d=m.useRef(null);o=o||a.renderer,!d.current&&o&&(d.current=o(e,{visualState:t,parent:s,props:n,presenceContext:l,blockInitialAnimation:l?l.initial===!1:!1,reducedMotionConfig:c,isSVG:i}));const u=d.current,h=m.useContext(Ta);u&&!u.projection&&r&&(u.type==="html"||u.type==="svg")&&wh(d.current,n,r,h);const f=m.useRef(!1);m.useInsertionEffect(()=>{u&&f.current&&u.update(n,l)});const v=n[Oi],y=m.useRef(!!v&&!window.MotionHandoffIsComplete?.(v)&&window.MotionHasOptimisedAnimation?.(v));return Or(()=>{u&&(f.current=!0,window.MotionIsMounted=!0,u.updateFeatures(),u.scheduleRenderMicrotask(),y.current&&u.animationState&&u.animationState.animateChanges())}),m.useEffect(()=>{u&&(!y.current&&u.animationState&&u.animationState.animateChanges(),y.current&&(queueMicrotask(()=>{window.MotionHandoffMarkAsComplete?.(v)}),y.current=!1),u.enteringChildren=void 0)}),u}function wh(e,t,n,o){const{layoutId:r,layout:i,drag:s,dragConstraints:a,layoutScroll:l,layoutRoot:c,layoutCrossfade:d}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:$a(e.parent)),e.projection.setOptions({layoutId:r,layout:i,alwaysMeasureLayout:!!s||a&&Lt(a),visualElement:e,animationType:typeof i=="string"?i:"both",initialPromotionConfig:o,crossfade:d,layoutScroll:l,layoutRoot:c})}function $a(e){if(e)return e.options.allowProjection!==!1?e.projection:$a(e.parent)}function Oo(e,{forwardMotionProps:t=!1,type:n}={},o,r){o&&eh(o);const i=n?n==="svg":zo(e),s=i?ph:mh;function a(c,d){let u;const h={...m.useContext(No),...c,layoutId:bh(c)},{isStatic:f}=h,v=ih(c),y=s(c,f);if(!f&&zr){xh(h,o);const b=Sh(h);u=b.MeasureLayout,v.visualElement=yh(e,y,h,r,b.ProjectionNode,i)}return p.jsxs(cn.Provider,{value:v,children:[u&&v.visualElement?p.jsx(u,{visualElement:v.visualElement,...h}):null,dh(e,c,vh(y,v.visualElement,d),y,f,t,i)]})}a.displayName=`motion.${typeof e=="string"?e:`create(${e.displayName??e.name??""})`}`;const l=m.forwardRef(a);return l[gh]=e,l}function bh({layoutId:e}){const t=m.useContext(En).id;return t&&e!==void 0?t+"-"+e:e}function xh(e,t){const n=m.useContext(pa).strict;if(process.env.NODE_ENV!=="production"&&t&&n){const o="You have rendered a `motion` component within a `LazyMotion` component. This will break tree shaking. Import and render a `m` component instead.";e.ignoreStrict?tt(!1,o,"lazy-strict-mode"):Ee(!1,o,"lazy-strict-mode")}}function Sh(e){const t=ya(),{drag:n,layout:o}=t;if(!n&&!o)return{};const r={...n,...o};return{MeasureLayout:n?.isEnabled(e)||o?.isEnabled(e)?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}function Ch(e,t){if(typeof Proxy>"u")return Oo;const n=new Map,o=(i,s)=>Oo(i,s,e,t),r=(i,s)=>(process.env.NODE_ENV!=="production"&&_n(!1,"motion() is deprecated. Use motion.create() instead."),o(i,s));return new Proxy(r,{get:(i,s)=>s==="create"?o:(n.has(s)||n.set(s,Oo(s,void 0,e,t)),n.get(s))})}const Th=(e,t)=>t.isSVG??zo(e)?new tf(t):new Yd(t,{allowProjection:e!==m.Fragment});class $h extends Be{constructor(t){super(t),t.animationState||(t.animationState=af(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();Qt(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){this.node.animationState.reset(),this.unmountControls?.()}}let Ph=0;class kh extends Be{constructor(){super(...arguments),this.id=Ph++}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n}=this.node.presenceContext,{isPresent:o}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===o)return;const r=this.node.animationState.setActive("exit",!t);n&&!t&&r.then(()=>{n(this.id)})}mount(){const{register:t,onExitComplete:n}=this.node.presenceContext||{};n&&n(this.id),t&&(this.unmount=t(this.id))}unmount(){}}const Mh={animation:{Feature:$h},exit:{Feature:kh}};function Rt(e){return{point:{x:e.pageX,y:e.pageY}}}const Vh=e=>t=>To(t)&&e(t,Rt(t));function _t(e,t,n,o){return At(e,t,Vh(n),o)}const Pa=({current:e})=>e?e.ownerDocument.defaultView:null,ka=(e,t)=>Math.abs(e-t);function Eh(e,t){const n=ka(e.x,t.x),o=ka(e.y,t.y);return Math.sqrt(n**2+o**2)}const Ma=new Set(["auto","scroll"]);class Va{constructor(t,n,{transformPagePoint:o,contextWindow:r=window,dragSnapToOrigin:i=!1,distanceThreshold:s=3,element:a}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.scrollPositions=new Map,this.removeScrollListeners=null,this.onElementScroll=f=>{this.handleScroll(f.target)},this.onWindowScroll=()=>{this.handleScroll(window)},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const f=jo(this.lastMoveEventInfo,this.history),v=this.startEvent!==null,y=Eh(f.offset,{x:0,y:0})>=this.distanceThreshold;if(!v&&!y)return;const{point:b}=f,{timestamp:w}=ne;this.history.push({...b,timestamp:w});const{onStart:T,onMove:C}=this.handlers;v||(T&&T(this.lastMoveEvent,f),this.startEvent=this.lastMoveEvent),C&&C(this.lastMoveEvent,f)},this.handlePointerMove=(f,v)=>{this.lastMoveEvent=f,this.lastMoveEventInfo=Ho(v,this.transformPagePoint),K.update(this.updatePoint,!0)},this.handlePointerUp=(f,v)=>{this.end();const{onEnd:y,onSessionEnd:b,resumeAnimation:w}=this.handlers;if((this.dragSnapToOrigin||!this.startEvent)&&w&&w(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const T=jo(f.type==="pointercancel"?this.lastMoveEventInfo:Ho(v,this.transformPagePoint),this.history);this.startEvent&&y&&y(f,T),b&&b(f,T)},!To(t))return;this.dragSnapToOrigin=i,this.handlers=n,this.transformPagePoint=o,this.distanceThreshold=s,this.contextWindow=r||window;const l=Rt(t),c=Ho(l,this.transformPagePoint),{point:d}=c,{timestamp:u}=ne;this.history=[{...d,timestamp:u}];const{onSessionStart:h}=n;h&&h(t,jo(c,this.history)),this.removeListeners=St(_t(this.contextWindow,"pointermove",this.handlePointerMove),_t(this.contextWindow,"pointerup",this.handlePointerUp),_t(this.contextWindow,"pointercancel",this.handlePointerUp)),a&&this.startScrollTracking(a)}startScrollTracking(t){let n=t.parentElement;for(;n;){const o=getComputedStyle(n);(Ma.has(o.overflowX)||Ma.has(o.overflowY))&&this.scrollPositions.set(n,{x:n.scrollLeft,y:n.scrollTop}),n=n.parentElement}this.scrollPositions.set(window,{x:window.scrollX,y:window.scrollY}),window.addEventListener("scroll",this.onElementScroll,{capture:!0,passive:!0}),window.addEventListener("scroll",this.onWindowScroll,{passive:!0}),this.removeScrollListeners=()=>{window.removeEventListener("scroll",this.onElementScroll,{capture:!0}),window.removeEventListener("scroll",this.onWindowScroll)}}handleScroll(t){const n=this.scrollPositions.get(t);if(!n)return;const o=t===window,r=o?{x:window.scrollX,y:window.scrollY}:{x:t.scrollLeft,y:t.scrollTop},i={x:r.x-n.x,y:r.y-n.y};i.x===0&&i.y===0||(o?this.lastMoveEventInfo&&(this.lastMoveEventInfo.point.x+=i.x,this.lastMoveEventInfo.point.y+=i.y):this.history.length>0&&(this.history[0].x-=i.x,this.history[0].y-=i.y),this.scrollPositions.set(t,r),K.update(this.updatePoint,!0))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),this.removeScrollListeners&&this.removeScrollListeners(),this.scrollPositions.clear(),Le(this.updatePoint)}}function Ho(e,t){return t?{point:t(e.point)}:e}function Ea(e,t){return{x:e.x-t.x,y:e.y-t.y}}function jo({point:e},t){return{point:e,delta:Ea(e,Da(t)),offset:Ea(e,Dh(t)),velocity:Fh(t,.1)}}function Dh(e){return e[0]}function Da(e){return e[e.length-1]}function Fh(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,o=null;const r=Da(e);for(;n>=0&&(o=e[n],!(r.timestamp-o.timestamp>Pe(t)));)n--;if(!o)return{x:0,y:0};const i=pe(r.timestamp-o.timestamp);if(i===0)return{x:0,y:0};const s={x:(r.x-o.x)/i,y:(r.y-o.y)/i};return s.x===1/0&&(s.x=0),s.y===1/0&&(s.y=0),s}function Ah(e,{min:t,max:n},o){return t!==void 0&&e<t?e=o?Y(t,e,o.min):Math.max(e,t):n!==void 0&&e>n&&(e=o?Y(n,e,o.max):Math.min(e,n)),e}function Fa(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function Ih(e,{top:t,left:n,bottom:o,right:r}){return{x:Fa(e.x,n,r),y:Fa(e.y,t,o)}}function Aa(e,t){let n=t.min-e.min,o=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,o]=[o,n]),{min:n,max:o}}function Lh(e,t){return{x:Aa(e.x,t.x),y:Aa(e.y,t.y)}}function Rh(e,t){let n=.5;const o=ce(e),r=ce(t);return r>o?n=Ct(t.min,t.max-o,e.min):o>r&&(n=Ct(e.min,e.max-r,t.min)),$e(0,1,n)}function _h(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const Go=.35;function Nh(e=Go){return e===!1?e=0:e===!0&&(e=Go),{x:Ia(e,"left","right"),y:Ia(e,"top","bottom")}}function Ia(e,t,n){return{min:La(e,t),max:La(e,n)}}function La(e,t){return typeof e=="number"?e:e[t]||0}const Bh=new WeakMap;class zh{constructor(t){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=ee(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=t}start(t,{snapToCursor:n=!1,distanceThreshold:o}={}){const{presenceContext:r}=this.visualElement;if(r&&r.isPresent===!1)return;const i=u=>{n?(this.stopAnimation(),this.snapToCursor(Rt(u).point)):this.pauseAnimation()},s=(u,h)=>{this.stopAnimation();const{drag:f,dragPropagation:v,onDragStart:y}=this.getProps();if(f&&!v&&(this.openDragLock&&this.openDragLock(),this.openDragLock=Pd(f),!this.openDragLock))return;this.latestPointerEvent=u,this.latestPanInfo=h,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),ge(w=>{let T=this.getAxisMotionValue(w).get()||0;if(ke.test(T)){const{projection:C}=this.visualElement;if(C&&C.layout){const k=C.layout.layoutBox[w];k&&(T=ce(k)*(parseFloat(T)/100))}}this.originPoint[w]=T}),y&&K.postRender(()=>y(u,h)),yo(this.visualElement,"transform");const{animationState:b}=this.visualElement;b&&b.setActive("whileDrag",!0)},a=(u,h)=>{this.latestPointerEvent=u,this.latestPanInfo=h;const{dragPropagation:f,dragDirectionLock:v,onDirectionLock:y,onDrag:b}=this.getProps();if(!f&&!this.openDragLock)return;const{offset:w}=h;if(v&&this.currentDirection===null){this.currentDirection=Oh(w),this.currentDirection!==null&&y&&y(this.currentDirection);return}this.updateAxis("x",h.point,w),this.updateAxis("y",h.point,w),this.visualElement.render(),b&&b(u,h)},l=(u,h)=>{this.latestPointerEvent=u,this.latestPanInfo=h,this.stop(u,h),this.latestPointerEvent=null,this.latestPanInfo=null},c=()=>ge(u=>this.getAnimationState(u)==="paused"&&this.getAxisMotionValue(u).animation?.play()),{dragSnapToOrigin:d}=this.getProps();this.panSession=new Va(t,{onSessionStart:i,onStart:s,onMove:a,onSessionEnd:l,resumeAnimation:c},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:d,distanceThreshold:o,contextWindow:Pa(this.visualElement),element:this.visualElement.current})}stop(t,n){const o=t||this.latestPointerEvent,r=n||this.latestPanInfo,i=this.isDragging;if(this.cancel(),!i||!r||!o)return;const{velocity:s}=r;this.startAnimation(s);const{onDragEnd:a}=this.getProps();a&&K.postRender(()=>a(o,r))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:o}=this.getProps();!o&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",!1)}updateAxis(t,n,o){const{drag:r}=this.getProps();if(!o||!un(t,r,this.currentDirection))return;const i=this.getAxisMotionValue(t);let s=this.originPoint[t]+o[t];this.constraints&&this.constraints[t]&&(s=Ah(s,this.constraints[t],this.elastic[t])),i.set(s)}resolveConstraints(){const{dragConstraints:t,dragElastic:n}=this.getProps(),o=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):this.visualElement.projection?.layout,r=this.constraints;t&&Lt(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&o?this.constraints=Ih(o.layoutBox,t):this.constraints=!1,this.elastic=Nh(n),r!==this.constraints&&o&&this.constraints&&!this.hasMutatedConstraints&&ge(i=>{this.constraints!==!1&&this.getAxisMotionValue(i)&&(this.constraints[i]=_h(o.layoutBox[i],this.constraints[i]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!Lt(t))return!1;const o=t.current;Ee(o!==null,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.","drag-constraints-ref");const{projection:r}=this.visualElement;if(!r||!r.layout)return!1;const i=jd(o,r.root,this.visualElement.getTransformPagePoint());let s=Lh(r.layout.layoutBox,i);if(n){const a=n(zd(s));this.hasMutatedConstraints=!!a,a&&(s=hs(a))}return s}startAnimation(t){const{drag:n,dragMomentum:o,dragElastic:r,dragTransition:i,dragSnapToOrigin:s,onDragTransitionEnd:a}=this.getProps(),l=this.constraints||{},c=ge(d=>{if(!un(d,n,this.currentDirection))return;let u=l&&l[d]||{};s&&(u={min:0,max:0});const h=r?200:1e6,f=r?40:1e7,v={type:"inertia",velocity:o?t[d]:0,bounceStiffness:h,bounceDamping:f,timeConstant:750,restDelta:1,restSpeed:10,...i,...u};return this.startAxisValueAnimation(d,v)});return Promise.all(c).then(a)}startAxisValueAnimation(t,n){const o=this.getAxisMotionValue(t);return yo(this.visualElement,t),o.start(po(t,o,0,n,this.visualElement,!1))}stopAnimation(){ge(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){ge(t=>this.getAxisMotionValue(t).animation?.pause())}getAnimationState(t){return this.getAxisMotionValue(t).animation?.state}getAxisMotionValue(t){const n=`_drag${t.toUpperCase()}`,o=this.visualElement.getProps(),r=o[n];return r||this.visualElement.getValue(t,(o.initial?o.initial[t]:void 0)||0)}snapToCursor(t){ge(n=>{const{drag:o}=this.getProps();if(!un(n,o,this.currentDirection))return;const{projection:r}=this.visualElement,i=this.getAxisMotionValue(n);if(r&&r.layout){const{min:s,max:a}=r.layout.layoutBox[n],l=i.get()||0;i.set(t[n]-Y(s,a,.5)+l)}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:o}=this.visualElement;if(!Lt(n)||!o||!this.constraints)return;this.stopAnimation();const r={x:0,y:0};ge(s=>{const a=this.getAxisMotionValue(s);if(a&&this.constraints!==!1){const l=a.get();r[s]=Rh({min:l,max:l},this.constraints[s])}});const{transformTemplate:i}=this.visualElement.getProps();this.visualElement.current.style.transform=i?i({},""):"none",o.root&&o.root.updateScroll(),o.updateLayout(),this.resolveConstraints(),ge(s=>{if(!un(s,t,null))return;const a=this.getAxisMotionValue(s),{min:l,max:c}=this.constraints[s];a.set(Y(l,c,r[s]))})}addListeners(){if(!this.visualElement.current)return;Bh.set(this.visualElement,this);const t=this.visualElement.current,n=_t(t,"pointerdown",l=>{const{drag:c,dragListener:d=!0}=this.getProps();c&&d&&!ns(l.target)&&this.start(l)}),o=()=>{const{dragConstraints:l}=this.getProps();Lt(l)&&l.current&&(this.constraints=this.resolveRefConstraints())},{projection:r}=this.visualElement,i=r.addEventListener("measure",o);r&&!r.layout&&(r.root&&r.root.updateScroll(),r.updateLayout()),K.read(o);const s=At(window,"resize",()=>this.scalePositionWithinConstraints()),a=r.addEventListener("didUpdate",(({delta:l,hasLayoutChanged:c})=>{this.isDragging&&c&&(ge(d=>{const u=this.getAxisMotionValue(d);u&&(this.originPoint[d]+=l[d].translate,u.set(u.get()+l[d].translate))}),this.visualElement.render())}));return()=>{s(),n(),i(),a&&a()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:o=!1,dragPropagation:r=!1,dragConstraints:i=!1,dragElastic:s=Go,dragMomentum:a=!0}=t;return{...t,drag:n,dragDirectionLock:o,dragPropagation:r,dragConstraints:i,dragElastic:s,dragMomentum:a}}}function un(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function Oh(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class Hh extends Be{constructor(t){super(t),this.removeGroupControls=me,this.removeListeners=me,this.controls=new zh(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||me}update(){const{dragControls:t}=this.node.getProps(),{dragControls:n}=this.node.prevProps||{};t!==n&&(this.removeGroupControls(),t&&(this.removeGroupControls=t.subscribe(this.controls)))}unmount(){this.removeGroupControls(),this.removeListeners()}}const Ra=e=>(t,n)=>{e&&K.postRender(()=>e(t,n))};class jh extends Be{constructor(){super(...arguments),this.removePointerDownListener=me}onPointerDown(t){this.session=new Va(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:Pa(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:o,onPanEnd:r}=this.node.getProps();return{onSessionStart:Ra(t),onStart:Ra(n),onMove:o,onEnd:(i,s)=>{delete this.session,r&&K.postRender(()=>r(i,s))}}}mount(){this.removePointerDownListener=_t(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}let Uo=!1;class Gh extends m.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:o,layoutId:r}=this.props,{projection:i}=t;i&&(n.group&&n.group.add(i),o&&o.register&&r&&o.register(i),Uo&&i.root.didUpdate(),i.addEventListener("animationComplete",()=>{this.safeToRemove()}),i.setOptions({...i.options,onExitComplete:()=>this.safeToRemove()})),sn.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:o,drag:r,isPresent:i}=this.props,{projection:s}=o;return s&&(s.isPresent=i,Uo=!0,r||t.layoutDependency!==n||n===void 0||t.isPresent!==i?s.willUpdate():this.safeToRemove(),t.isPresent!==i&&(i?s.promote():s.relegate()||K.postRender(()=>{const a=s.getStack();(!a||!a.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),Co.postRender(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:o}=this.props,{projection:r}=t;Uo=!0,r&&(r.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(r),o&&o.deregister&&o.deregister(r))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function _a(e){const[t,n]=ha(),o=m.useContext(En);return p.jsx(Gh,{...e,layoutGroup:o,switchLayoutGroup:m.useContext(Ta),isPresent:t,safeToRemove:n})}const Uh={pan:{Feature:jh},drag:{Feature:Hh,ProjectionNode:da,MeasureLayout:_a}};function Na(e,t,n){const{props:o}=e;e.animationState&&o.whileHover&&e.animationState.setActive("whileHover",n==="Start");const r="onHover"+n,i=o[r];i&&K.postRender(()=>i(t,Rt(t)))}class Kh extends Be{mount(){const{current:t}=this.node;t&&(this.unmount=kd(t,(n,o)=>(Na(this.node,o,"Start"),r=>Na(this.node,r,"End"))))}unmount(){}}class Wh extends Be{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=St(At(this.node.current,"focus",()=>this.onFocus()),At(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function Ba(e,t,n){const{props:o}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&o.whileTap&&e.animationState.setActive("whileTap",n==="Start");const r="onTap"+(n==="End"?"":n),i=o[r];i&&K.postRender(()=>i(t,Rt(t)))}class qh extends Be{mount(){const{current:t}=this.node;t&&(this.unmount=Ed(t,(n,o)=>(Ba(this.node,o,"Start"),(r,{success:i})=>Ba(this.node,r,i?"End":"Cancel")),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}const Ko=new WeakMap,Wo=new WeakMap,Yh=e=>{const t=Ko.get(e.target);t&&t(e)},Xh=e=>{e.forEach(Yh)};function Zh({root:e,...t}){const n=e||document;Wo.has(n)||Wo.set(n,{});const o=Wo.get(n),r=JSON.stringify(t);return o[r]||(o[r]=new IntersectionObserver(Xh,{root:e,...t})),o[r]}function Jh(e,t,n){const o=Zh(t);return Ko.set(e,n),o.observe(e),()=>{Ko.delete(e),o.unobserve(e)}}const Qh={some:0,all:1};class em extends Be{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:n,margin:o,amount:r="some",once:i}=t,s={root:n?n.current:void 0,rootMargin:o,threshold:typeof r=="number"?r:Qh[r]},a=l=>{const{isIntersecting:c}=l;if(this.isInView===c||(this.isInView=c,i&&!c&&this.hasEnteredView))return;c&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",c);const{onViewportEnter:d,onViewportLeave:u}=this.node.getProps(),h=c?d:u;h&&h(l)};return Jh(this.node.current,s,a)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(tm(t,n))&&this.startObserver()}unmount(){}}function tm({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const nm={...Mh,...{inView:{Feature:em},tap:{Feature:qh},focus:{Feature:Wh},hover:{Feature:Kh}},...Uh,...{layout:{ProjectionNode:da,MeasureLayout:_a}}},Fe=Ch(nm,Th),om={sm:g.css`
176
176
  width: 1.25rem;
177
177
  height: 1.25rem;
178
178
  `,md:g.css`
@@ -184,7 +184,7 @@
184
184
  `,xl:g.css`
185
185
  width: 4rem;
186
186
  height: 4rem;
187
- `},Oa={primary:g.css`
187
+ `},za={primary:g.css`
188
188
  color: var(--color-main-blue-primary);
189
189
  `,orange:g.css`
190
190
  color: var(--color-main-orange-primary);
@@ -192,29 +192,29 @@
192
192
  color: var(--color-main-white);
193
193
  `,gray:g.css`
194
194
  color: var(--color-main-grey);
195
- `},sm=g.div`
195
+ `},rm=g.div`
196
196
  position: relative;
197
197
  display: block;
198
- ${({$size:e="md"})=>im[e]}
199
- ${({$color:e="primary"})=>Oa[e]}
198
+ ${({$size:e="md"})=>om[e]}
199
+ ${({$color:e="primary"})=>za[e]}
200
200
  user-select: none;
201
- `,am=g.div`
201
+ `,im=g.div`
202
202
  display: flex;
203
203
  flex-direction: column;
204
204
  align-items: center;
205
205
  gap: 0.5rem;
206
206
  padding: 2.5px 2.5px 2.5px 0px;
207
- `,lm=g.div`
207
+ `,sm=g.div`
208
208
  display: flex;
209
209
  align-items: center;
210
210
  justify-content: center;
211
211
  min-height: 12.5rem;
212
212
  width: 100%;
213
- `,cm=g(Fe.p)`
213
+ `,am=g(Fe.p)`
214
214
  ${E[16]}
215
- ${({$color:e="primary"})=>Oa[e]}
215
+ ${({$color:e="primary"})=>za[e]}
216
216
  margin: 0;
217
- `,um=({variant:e,title:t})=>p.jsxs(Fe.svg,{width:"100%",height:"100%",viewBox:"0 0 50 50",style:{position:"absolute",top:0,left:0,zIndex:1,padding:"2.1px 2.5px 2.5px 0px"},animate:e==="rotate"?{rotate:[0,360]}:{scale:[1,.7,1]},transition:e==="rotate"?{repeat:1/0,duration:2,ease:"linear"}:{repeat:1/0,duration:2,ease:"easeInOut"},children:[p.jsx("g",{transform:"scale(0.15) translate(-10, -1)",children:p.jsx("path",{fill:"currentColor",d:`M67.251411,286.749390
217
+ `,lm=({variant:e,title:t})=>p.jsxs(Fe.svg,{width:"100%",height:"100%",viewBox:"0 0 50 50",style:{position:"absolute",top:0,left:0,zIndex:1,padding:"2.1px 2.5px 2.5px 0px"},animate:e==="rotate"?{rotate:[0,360]}:{scale:[1,.7,1]},transition:e==="rotate"?{repeat:1/0,duration:2,ease:"linear"}:{repeat:1/0,duration:2,ease:"easeInOut"},children:[p.jsx("g",{transform:"scale(0.15) translate(-10, -1)",children:p.jsx("path",{fill:"currentColor",d:`M67.251411,286.749390
218
218
  C42.999393,262.534088 27.711603,233.886490 21.140957,200.638245
219
219
  C20.527918,197.536194 19.462318,196.344513 16.327942,196.535400
220
220
  C12.711285,196.755646 9.070918,196.586609 4.251685,196.586609
@@ -231,7 +231,7 @@
231
231
  C231.681030,-17.750278 329.482361,42.974667 346.823608,138.519577
232
232
  C363.551025,230.682480 301.903687,318.479523 209.509521,332.564972
233
233
  C155.049683,340.867371 107.495514,325.072021 67.251411,286.749390
234
- z`})}),t&&p.jsx("title",{children:t})]}),dn=({size:e="md",color:t="primary",centered:n=!0,message:o,title:r,variant:i="rotate"})=>{const s=p.jsxs(am,{children:[p.jsx(sm,{$size:e,$color:t,$variant:i,children:p.jsx(um,{variant:i,title:r})}),o&&p.jsx(cm,{$color:t,animate:{opacity:[1,.5,1]},transition:{repeat:1/0,duration:2,ease:"easeInOut"},children:o})]});return n?p.jsx(lm,{children:s}):s},dm=g.div`
234
+ z`})}),t&&p.jsx("title",{children:t})]}),dn=({size:e="md",color:t="primary",centered:n=!0,message:o,title:r,variant:i="rotate"})=>{const s=p.jsxs(im,{children:[p.jsx(rm,{$size:e,$color:t,$variant:i,children:p.jsx(lm,{variant:i,title:r})}),o&&p.jsx(am,{$color:t,animate:{opacity:[1,.5,1]},transition:{repeat:1/0,duration:2,ease:"easeInOut"},children:o})]});return n?p.jsx(sm,{children:s}):s},cm=g.div`
235
235
  position: fixed;
236
236
  inset: 0;
237
237
  background-color: rgba(255, 255, 255, 0.8);
@@ -240,7 +240,7 @@
240
240
  align-items: center;
241
241
  justify-content: center;
242
242
  z-index: 50;
243
- `,fm=g.div`
243
+ `,um=g.div`
244
244
  background-color: var(--color-main-white);
245
245
  border-radius: var(--border-radius-card);
246
246
  box-shadow: var(--shadow-black-card);
@@ -251,18 +251,18 @@
251
251
  gap: 1rem;
252
252
  width: 90%;
253
253
  max-width: 24rem;
254
- `,hm=g.h2`
255
- ${kn[30]}
254
+ `,dm=g.h2`
255
+ ${Vn[30]}
256
256
  color: var(--color-main-blue-primary);
257
257
  margin: 0 auto;
258
258
  text-align: center;
259
- `,mm=({message:e="Loading...",color:t="primary",variant:n="rotate"})=>p.jsx(dm,{role:"status","aria-live":"polite",children:p.jsxs(fm,{children:[p.jsx(dn,{size:"xl",color:t,centered:!1,title:e,variant:n}),p.jsx(hm,{children:e})]})}),pm=g.div`
259
+ `,fm=({message:e="Loading...",color:t="primary",variant:n="rotate"})=>p.jsx(cm,{role:"status","aria-live":"polite",children:p.jsxs(um,{children:[p.jsx(dn,{size:"xl",color:t,centered:!1,title:e,variant:n}),p.jsx(dm,{children:e})]})}),hm=g.div`
260
260
  display: flex;
261
261
  flex-direction: column;
262
262
  align-items: center;
263
263
  justify-content: center;
264
264
  padding: 3rem 1rem;
265
- `,Ha=({message:e,color:t="primary",variant:n="rotate"})=>p.jsx(pm,{role:"status","aria-live":"polite",children:p.jsx(dn,{size:"lg",color:t,centered:!1,message:e,title:e,variant:n})}),gm={primary:g.css`
265
+ `,mm=({message:e,color:t="primary",variant:n="rotate"})=>p.jsx(hm,{role:"status","aria-live":"polite",children:p.jsx(dn,{size:"lg",color:t,centered:!1,message:e,title:e,variant:n})}),pm={primary:g.css`
266
266
  background-color: var(--color-main-blue-primary);
267
267
  color: var(--color-main-white);
268
268
 
@@ -322,12 +322,12 @@
322
322
  border-color: var(--color-dark-200);
323
323
  background-color: transparent;
324
324
  }
325
- `},vm=g.css`
325
+ `},gm=g.css`
326
326
  background-color: var(--color-main-grey);
327
327
  color: var(--color-dark-200);
328
328
  cursor: not-allowed;
329
329
  box-shadow: none;
330
- `,ym={sm:g.css`
330
+ `,vm={sm:g.css`
331
331
  padding: 0.375rem 0.75rem;
332
332
  min-height: 2.75rem;
333
333
  ${E[12]}
@@ -339,7 +339,7 @@
339
339
  padding: 0.75rem 1.5rem;
340
340
  min-height: 3.5rem;
341
341
  ${E[20]}
342
- `},wm=g.button`
342
+ `},ym=g.button`
343
343
  border: none;
344
344
  border-radius: var(--border-radius-button);
345
345
  transition:
@@ -354,13 +354,13 @@
354
354
  outline: 2px solid transparent;
355
355
  outline-offset: 2px;
356
356
 
357
- ${({$variant:e})=>gm[e]}
358
- ${({$size:e})=>ym[e]}
357
+ ${({$variant:e})=>pm[e]}
358
+ ${({$size:e})=>vm[e]}
359
359
 
360
360
  &:disabled {
361
- ${vm}
361
+ ${gm}
362
362
  }
363
- `,dt=({children:e,variant:t="primary",size:n="md",isLoading:o,disabled:r,leftIcon:i,rightIcon:s,iconSize:a="md",iconColor:l="currentColor",...c})=>p.jsxs(wm,{$variant:t,$size:n,disabled:r||o,"aria-busy":o,...c,children:[i&&p.jsx(H,{color:l,size:a,component:i}),o?"Loading...":e,s&&p.jsx(H,{color:l,size:a,component:s})]}),bm={sm:g.css`
363
+ `,ft=({children:e,variant:t="primary",size:n="md",isLoading:o,disabled:r,leftIcon:i,rightIcon:s,iconSize:a="md",iconColor:l="currentColor",...c})=>p.jsxs(ym,{$variant:t,$size:n,disabled:r||o,"aria-busy":o,...c,children:[i&&p.jsx(U,{color:l,size:a,component:i}),o?"Loading...":e,s&&p.jsx(U,{color:l,size:a,component:s})]}),wm={sm:g.css`
364
364
  padding: 0.25rem 0.625rem;
365
365
  border-radius: var(--border-radius-button);
366
366
  ${E[12]}
@@ -372,7 +372,7 @@
372
372
  padding: 0.5rem 1rem;
373
373
  border-radius: var(--border-radius-button);
374
374
  ${E[16]}
375
- `},xm={primary:g.css`
375
+ `},bm={primary:g.css`
376
376
  background-color: var(--color-main-blue-primary);
377
377
  color: var(--color-main-white);
378
378
  `,secondary:g.css`
@@ -390,7 +390,7 @@
390
390
  `,neutral:g.css`
391
391
  background-color: var(--color-light-200);
392
392
  color: var(--color-main-grey);
393
- `,outline:g.css``},Sm=g.span`
393
+ `,outline:g.css``},xm=g.span`
394
394
  display: inline-flex;
395
395
  align-items: center;
396
396
  gap: 0.375rem;
@@ -398,15 +398,15 @@
398
398
  white-space: nowrap;
399
399
  user-select: none;
400
400
 
401
- ${({$size:e})=>bm[e]}
402
- ${({$variant:e})=>xm[e]}
401
+ ${({$size:e})=>wm[e]}
402
+ ${({$variant:e})=>bm[e]}
403
403
 
404
404
  ${({$variant:e,$outlineColor:t})=>e==="outline"?g.css`
405
405
  background-color: transparent;
406
406
  color: ${t||"var(--color-main-blue-primary)"};
407
407
  border: 1px solid ${t||"var(--color-main-blue-primary)"};
408
408
  `:""}
409
- `,Cm=({children:e,variant:t="neutral",size:n="md",color:o,leftIcon:r,rightIcon:i,iconColor:s="currentColor",iconSize:a="sm",...l})=>p.jsxs(Sm,{$variant:t,$size:n,$outlineColor:o,...l,children:[r&&p.jsx(H,{color:s,size:a,component:r}),e,i&&p.jsx(H,{color:s,size:a,component:i})]}),Tm=g.div`
409
+ `,Sm=({children:e,variant:t="neutral",size:n="md",color:o,leftIcon:r,rightIcon:i,iconColor:s="currentColor",iconSize:a="sm",...l})=>p.jsxs(xm,{$variant:t,$size:n,$outlineColor:o,...l,children:[r&&p.jsx(U,{color:s,size:a,component:r}),e,i&&p.jsx(U,{color:s,size:a,component:i})]}),Cm=g.div`
410
410
  background-color: ${({$color:e})=>e};
411
411
  ${({$orientation:e,$length:t,$thickness:n})=>e==="horizontal"?`
412
412
  height: ${n||"1px"};
@@ -415,10 +415,10 @@
415
415
  width: ${n||"1px"};
416
416
  height: ${t||"100%"};
417
417
  `}
418
- `,$m=({orientation:e="horizontal",color:t="var(--color-dark-300)",length:n,thickness:o,className:r=""})=>p.jsx(Tm,{$orientation:e,$color:t,$length:n,$thickness:o,className:r,role:"separator","aria-orientation":e}),Pm=g.span`
418
+ `,Tm=({orientation:e="horizontal",color:t="var(--color-dark-300)",length:n,thickness:o,className:r=""})=>p.jsx(Cm,{$orientation:e,$color:t,$length:n,$thickness:o,className:r,role:"separator","aria-orientation":e}),$m=g.span`
419
419
  ${({$size:e})=>E[e]}
420
420
  color: ${({$color:e})=>e||"var(--color-main-grey)"};
421
- `,_t=({children:e,size:t=16,color:n,className:o,style:r})=>p.jsx(Pm,{$size:t,$color:n,className:o,style:r,children:e});function Mm(e){if(typeof document>"u")return;let t=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css",t.appendChild(n),n.styleSheet?n.styleSheet.cssText=e:n.appendChild(document.createTextNode(e))}const km=e=>{switch(e){case"success":return Dm;case"info":return Am;case"warning":return Fm;case"error":return Im;default:return null}},Vm=Array(12).fill(0),Em=({visible:e,className:t})=>m.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},m.createElement("div",{className:"sonner-spinner"},Vm.map((n,o)=>m.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${o}`})))),Dm=m.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},m.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),Fm=m.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},m.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),Am=m.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},m.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),Im=m.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},m.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),Lm=m.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},m.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),m.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),Rm=()=>{const[e,t]=m.useState(document.hidden);return m.useEffect(()=>{const n=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",n),()=>window.removeEventListener("visibilitychange",n)},[]),e};let Wo=1;class _m{constructor(){this.subscribe=t=>(this.subscribers.push(t),()=>{const n=this.subscribers.indexOf(t);this.subscribers.splice(n,1)}),this.publish=t=>{this.subscribers.forEach(n=>n(t))},this.addToast=t=>{this.publish(t),this.toasts=[...this.toasts,t]},this.create=t=>{var n;const{message:o,...r}=t,i=typeof t?.id=="number"||((n=t.id)==null?void 0:n.length)>0?t.id:Wo++,s=this.toasts.find(l=>l.id===i),a=t.dismissible===void 0?!0:t.dismissible;return this.dismissedToasts.has(i)&&this.dismissedToasts.delete(i),s?this.toasts=this.toasts.map(l=>l.id===i?(this.publish({...l,...t,id:i,title:o}),{...l,...t,id:i,dismissible:a,title:o}):l):this.addToast({title:o,...r,dismissible:a,id:i}),i},this.dismiss=t=>(t?(this.dismissedToasts.add(t),requestAnimationFrame(()=>this.subscribers.forEach(n=>n({id:t,dismiss:!0})))):this.toasts.forEach(n=>{this.subscribers.forEach(o=>o({id:n.id,dismiss:!0}))}),t),this.message=(t,n)=>this.create({...n,message:t}),this.error=(t,n)=>this.create({...n,message:t,type:"error"}),this.success=(t,n)=>this.create({...n,type:"success",message:t}),this.info=(t,n)=>this.create({...n,type:"info",message:t}),this.warning=(t,n)=>this.create({...n,type:"warning",message:t}),this.loading=(t,n)=>this.create({...n,type:"loading",message:t}),this.promise=(t,n)=>{if(!n)return;let o;n.loading!==void 0&&(o=this.create({...n,promise:t,type:"loading",message:n.loading,description:typeof n.description!="function"?n.description:void 0}));const r=Promise.resolve(t instanceof Function?t():t);let i=o!==void 0,s;const a=r.then(async c=>{if(s=["resolve",c],m.isValidElement(c))i=!1,this.create({id:o,type:"default",message:c});else if(Nm(c)&&!c.ok){i=!1;const u=typeof n.error=="function"?await n.error(`HTTP error! status: ${c.status}`):n.error,h=typeof n.description=="function"?await n.description(`HTTP error! status: ${c.status}`):n.description,v=typeof u=="object"&&!m.isValidElement(u)?u:{message:u};this.create({id:o,type:"error",description:h,...v})}else if(c instanceof Error){i=!1;const u=typeof n.error=="function"?await n.error(c):n.error,h=typeof n.description=="function"?await n.description(c):n.description,v=typeof u=="object"&&!m.isValidElement(u)?u:{message:u};this.create({id:o,type:"error",description:h,...v})}else if(n.success!==void 0){i=!1;const u=typeof n.success=="function"?await n.success(c):n.success,h=typeof n.description=="function"?await n.description(c):n.description,v=typeof u=="object"&&!m.isValidElement(u)?u:{message:u};this.create({id:o,type:"success",description:h,...v})}}).catch(async c=>{if(s=["reject",c],n.error!==void 0){i=!1;const d=typeof n.error=="function"?await n.error(c):n.error,u=typeof n.description=="function"?await n.description(c):n.description,f=typeof d=="object"&&!m.isValidElement(d)?d:{message:d};this.create({id:o,type:"error",description:u,...f})}}).finally(()=>{i&&(this.dismiss(o),o=void 0),n.finally==null||n.finally.call(n)}),l=()=>new Promise((c,d)=>a.then(()=>s[0]==="reject"?d(s[1]):c(s[1])).catch(d));return typeof o!="string"&&typeof o!="number"?{unwrap:l}:Object.assign(o,{unwrap:l})},this.custom=(t,n)=>{const o=n?.id||Wo++;return this.create({jsx:t(o),id:o,...n}),o},this.getActiveToasts=()=>this.toasts.filter(t=>!this.dismissedToasts.has(t.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}}const ue=new _m,Bm=(e,t)=>{const n=t?.id||Wo++;return ue.addToast({title:e,...t,id:n}),n},Nm=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",zm=Bm,Om=()=>ue.toasts,Hm=()=>ue.getActiveToasts(),jm=Object.assign(zm,{success:ue.success,info:ue.info,warning:ue.warning,error:ue.error,custom:ue.custom,message:ue.message,promise:ue.promise,dismiss:ue.dismiss,loading:ue.loading},{getHistory:Om,getToasts:Hm});Mm("[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-rich-colors=true][data-sonner-toast][data-styled=true] [data-description]{color:inherit}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);background:var(--normal-bg);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast][data-expanded=true]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}");function fn(e){return e.label!==void 0}const Gm=3,Um="24px",Km="16px",ja=4e3,Wm=356,qm=14,Ym=45,Xm=200;function ke(...e){return e.filter(Boolean).join(" ")}function Zm(e){const[t,n]=e.split("-"),o=[];return t&&o.push(t),n&&o.push(n),o}const Jm=e=>{var t,n,o,r,i,s,a,l,c;const{invert:d,toast:u,unstyled:h,interacting:f,setHeights:v,visibleToasts:y,heights:b,index:w,toasts:T,expanded:C,removeToast:M,defaultRichColors:x,closeButton:P,style:V,cancelButtonStyle:$,actionButtonStyle:F,className:D="",descriptionClassName:_="",duration:N,position:O,gap:j,expandByDefault:K,classNames:R,icons:L,closeButtonAriaLabel:G="Close toast"}=e,[oe,Q]=m.useState(null),[Se,mt]=m.useState(null),[z,Z]=m.useState(!1),[X,ve]=m.useState(!1),[pt,W]=m.useState(!1),[gt,Cn]=m.useState(!1),[Tn,vt]=m.useState(!1),[yy,Ir]=m.useState(0),[wy,mc]=m.useState(0),Gt=m.useRef(u.duration||N||ja),pc=m.useRef(null),Ie=m.useRef(null),by=w===0,xy=w+1<=y,fe=u.type,yt=u.dismissible!==!1,Sy=u.className||"",Cy=u.descriptionClassName||"",$n=m.useMemo(()=>b.findIndex(B=>B.toastId===u.id)||0,[b,u.id]),Ty=m.useMemo(()=>{var B;return(B=u.closeButton)!=null?B:P},[u.closeButton,P]),gc=m.useMemo(()=>u.duration||N||ja,[u.duration,N]),Lr=m.useRef(0),wt=m.useRef(0),vc=m.useRef(0),bt=m.useRef(null),[$y,Py]=O.split("-"),yc=m.useMemo(()=>b.reduce((B,te,ae)=>ae>=$n?B:B+te.height,0),[b,$n]),wc=Rm(),My=u.invert||d,Rr=fe==="loading";wt.current=m.useMemo(()=>$n*j+yc,[$n,yc]),m.useEffect(()=>{Gt.current=gc},[gc]),m.useEffect(()=>{Z(!0)},[]),m.useEffect(()=>{const B=Ie.current;if(B){const te=B.getBoundingClientRect().height;return mc(te),v(ae=>[{toastId:u.id,height:te,position:u.position},...ae]),()=>v(ae=>ae.filter(he=>he.toastId!==u.id))}},[v,u.id]),m.useLayoutEffect(()=>{if(!z)return;const B=Ie.current,te=B.style.height;B.style.height="auto";const ae=B.getBoundingClientRect().height;B.style.height=te,mc(ae),v(he=>he.find(re=>re.toastId===u.id)?he.map(re=>re.toastId===u.id?{...re,height:ae}:re):[{toastId:u.id,height:ae,position:u.position},...he])},[z,u.title,u.description,v,u.id,u.jsx,u.action,u.cancel]);const Ge=m.useCallback(()=>{ve(!0),Ir(wt.current),v(B=>B.filter(te=>te.toastId!==u.id)),setTimeout(()=>{M(u)},Xm)},[u,M,v,wt]);m.useEffect(()=>{if(u.promise&&fe==="loading"||u.duration===1/0||u.type==="loading")return;let B;return C||f||wc?(()=>{if(vc.current<Lr.current){const he=new Date().getTime()-Lr.current;Gt.current=Gt.current-he}vc.current=new Date().getTime()})():Gt.current!==1/0&&(Lr.current=new Date().getTime(),B=setTimeout(()=>{u.onAutoClose==null||u.onAutoClose.call(u,u),Ge()},Gt.current)),()=>clearTimeout(B)},[C,f,u,fe,wc,Ge]),m.useEffect(()=>{u.delete&&(Ge(),u.onDismiss==null||u.onDismiss.call(u,u))},[Ge,u.delete]);function ky(){var B;if(L?.loading){var te;return m.createElement("div",{className:ke(R?.loader,u==null||(te=u.classNames)==null?void 0:te.loader,"sonner-loader"),"data-visible":fe==="loading"},L.loading)}return m.createElement(Em,{className:ke(R?.loader,u==null||(B=u.classNames)==null?void 0:B.loader),visible:fe==="loading"})}const Vy=u.icon||L?.[fe]||km(fe);var bc,xc;return m.createElement("li",{tabIndex:0,ref:Ie,className:ke(D,Sy,R?.toast,u==null||(t=u.classNames)==null?void 0:t.toast,R?.default,R?.[fe],u==null||(n=u.classNames)==null?void 0:n[fe]),"data-sonner-toast":"","data-rich-colors":(bc=u.richColors)!=null?bc:x,"data-styled":!(u.jsx||u.unstyled||h),"data-mounted":z,"data-promise":!!u.promise,"data-swiped":Tn,"data-removed":X,"data-visible":xy,"data-y-position":$y,"data-x-position":Py,"data-index":w,"data-front":by,"data-swiping":pt,"data-dismissible":yt,"data-type":fe,"data-invert":My,"data-swipe-out":gt,"data-swipe-direction":Se,"data-expanded":!!(C||K&&z),"data-testid":u.testId,style:{"--index":w,"--toasts-before":w,"--z-index":T.length-w,"--offset":`${X?yy:wt.current}px`,"--initial-height":K?"auto":`${wy}px`,...V,...u.style},onDragEnd:()=>{W(!1),Q(null),bt.current=null},onPointerDown:B=>{B.button!==2&&(Rr||!yt||(pc.current=new Date,Ir(wt.current),B.target.setPointerCapture(B.pointerId),B.target.tagName!=="BUTTON"&&(W(!0),bt.current={x:B.clientX,y:B.clientY})))},onPointerUp:()=>{var B,te,ae;if(gt||!yt)return;bt.current=null;const he=Number(((B=Ie.current)==null?void 0:B.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),Pn=Number(((te=Ie.current)==null?void 0:te.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),re=new Date().getTime()-((ae=pc.current)==null?void 0:ae.getTime()),ye=oe==="x"?he:Pn,Mn=Math.abs(ye)/re;if(Math.abs(ye)>=Ym||Mn>.11){Ir(wt.current),u.onDismiss==null||u.onDismiss.call(u,u),mt(oe==="x"?he>0?"right":"left":Pn>0?"down":"up"),Ge(),Cn(!0);return}else{var Ce,Te;(Ce=Ie.current)==null||Ce.style.setProperty("--swipe-amount-x","0px"),(Te=Ie.current)==null||Te.style.setProperty("--swipe-amount-y","0px")}vt(!1),W(!1),Q(null)},onPointerMove:B=>{var te,ae,he;if(!bt.current||!yt||((te=window.getSelection())==null?void 0:te.toString().length)>0)return;const re=B.clientY-bt.current.y,ye=B.clientX-bt.current.x;var Mn;const Ce=(Mn=e.swipeDirections)!=null?Mn:Zm(O);!oe&&(Math.abs(ye)>1||Math.abs(re)>1)&&Q(Math.abs(ye)>Math.abs(re)?"x":"y");let Te={x:0,y:0};const Sc=Qe=>1/(1.5+Math.abs(Qe)/20);if(oe==="y"){if(Ce.includes("top")||Ce.includes("bottom"))if(Ce.includes("top")&&re<0||Ce.includes("bottom")&&re>0)Te.y=re;else{const Qe=re*Sc(re);Te.y=Math.abs(Qe)<Math.abs(re)?Qe:re}}else if(oe==="x"&&(Ce.includes("left")||Ce.includes("right")))if(Ce.includes("left")&&ye<0||Ce.includes("right")&&ye>0)Te.x=ye;else{const Qe=ye*Sc(ye);Te.x=Math.abs(Qe)<Math.abs(ye)?Qe:ye}(Math.abs(Te.x)>0||Math.abs(Te.y)>0)&&vt(!0),(ae=Ie.current)==null||ae.style.setProperty("--swipe-amount-x",`${Te.x}px`),(he=Ie.current)==null||he.style.setProperty("--swipe-amount-y",`${Te.y}px`)}},Ty&&!u.jsx&&fe!=="loading"?m.createElement("button",{"aria-label":G,"data-disabled":Rr,"data-close-button":!0,onClick:Rr||!yt?()=>{}:()=>{Ge(),u.onDismiss==null||u.onDismiss.call(u,u)},className:ke(R?.closeButton,u==null||(o=u.classNames)==null?void 0:o.closeButton)},(xc=L?.close)!=null?xc:Lm):null,(fe||u.icon||u.promise)&&u.icon!==null&&(L?.[fe]!==null||u.icon)?m.createElement("div",{"data-icon":"",className:ke(R?.icon,u==null||(r=u.classNames)==null?void 0:r.icon)},u.promise||u.type==="loading"&&!u.icon?u.icon||ky():null,u.type!=="loading"?Vy:null):null,m.createElement("div",{"data-content":"",className:ke(R?.content,u==null||(i=u.classNames)==null?void 0:i.content)},m.createElement("div",{"data-title":"",className:ke(R?.title,u==null||(s=u.classNames)==null?void 0:s.title)},u.jsx?u.jsx:typeof u.title=="function"?u.title():u.title),u.description?m.createElement("div",{"data-description":"",className:ke(_,Cy,R?.description,u==null||(a=u.classNames)==null?void 0:a.description)},typeof u.description=="function"?u.description():u.description):null),m.isValidElement(u.cancel)?u.cancel:u.cancel&&fn(u.cancel)?m.createElement("button",{"data-button":!0,"data-cancel":!0,style:u.cancelButtonStyle||$,onClick:B=>{fn(u.cancel)&&yt&&(u.cancel.onClick==null||u.cancel.onClick.call(u.cancel,B),Ge())},className:ke(R?.cancelButton,u==null||(l=u.classNames)==null?void 0:l.cancelButton)},u.cancel.label):null,m.isValidElement(u.action)?u.action:u.action&&fn(u.action)?m.createElement("button",{"data-button":!0,"data-action":!0,style:u.actionButtonStyle||F,onClick:B=>{fn(u.action)&&(u.action.onClick==null||u.action.onClick.call(u.action,B),!B.defaultPrevented&&Ge())},className:ke(R?.actionButton,u==null||(c=u.classNames)==null?void 0:c.actionButton)},u.action.label):null)};function Ga(){if(typeof window>"u"||typeof document>"u")return"ltr";const e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}function Qm(e,t){const n={};return[e,t].forEach((o,r)=>{const i=r===1,s=i?"--mobile-offset":"--offset",a=i?Km:Um;function l(c){["top","right","bottom","left"].forEach(d=>{n[`${s}-${d}`]=typeof c=="number"?`${c}px`:c})}typeof o=="number"||typeof o=="string"?l(o):typeof o=="object"?["top","right","bottom","left"].forEach(c=>{o[c]===void 0?n[`${s}-${c}`]=a:n[`${s}-${c}`]=typeof o[c]=="number"?`${o[c]}px`:o[c]}):l(a)}),n}const ep=m.forwardRef(function(t,n){const{id:o,invert:r,position:i="bottom-right",hotkey:s=["altKey","KeyT"],expand:a,closeButton:l,className:c,offset:d,mobileOffset:u,theme:h="light",richColors:f,duration:v,style:y,visibleToasts:b=Gm,toastOptions:w,dir:T=Ga(),gap:C=qm,icons:M,containerAriaLabel:x="Notifications"}=t,[P,V]=m.useState([]),$=m.useMemo(()=>o?P.filter(z=>z.toasterId===o):P.filter(z=>!z.toasterId),[P,o]),F=m.useMemo(()=>Array.from(new Set([i].concat($.filter(z=>z.position).map(z=>z.position)))),[$,i]),[D,_]=m.useState([]),[N,O]=m.useState(!1),[j,K]=m.useState(!1),[R,L]=m.useState(h!=="system"?h:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),G=m.useRef(null),oe=s.join("+").replace(/Key/g,"").replace(/Digit/g,""),Q=m.useRef(null),Se=m.useRef(!1),mt=m.useCallback(z=>{V(Z=>{var X;return(X=Z.find(ve=>ve.id===z.id))!=null&&X.delete||ue.dismiss(z.id),Z.filter(({id:ve})=>ve!==z.id)})},[]);return m.useEffect(()=>ue.subscribe(z=>{if(z.dismiss){requestAnimationFrame(()=>{V(Z=>Z.map(X=>X.id===z.id?{...X,delete:!0}:X))});return}setTimeout(()=>{_r.flushSync(()=>{V(Z=>{const X=Z.findIndex(ve=>ve.id===z.id);return X!==-1?[...Z.slice(0,X),{...Z[X],...z},...Z.slice(X+1)]:[z,...Z]})})})}),[P]),m.useEffect(()=>{if(h!=="system"){L(h);return}if(h==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?L("dark"):L("light")),typeof window>"u")return;const z=window.matchMedia("(prefers-color-scheme: dark)");try{z.addEventListener("change",({matches:Z})=>{L(Z?"dark":"light")})}catch{z.addListener(({matches:X})=>{try{L(X?"dark":"light")}catch(ve){console.error(ve)}})}},[h]),m.useEffect(()=>{P.length<=1&&O(!1)},[P]),m.useEffect(()=>{const z=Z=>{var X;if(s.every(W=>Z[W]||Z.code===W)){var pt;O(!0),(pt=G.current)==null||pt.focus()}Z.code==="Escape"&&(document.activeElement===G.current||(X=G.current)!=null&&X.contains(document.activeElement))&&O(!1)};return document.addEventListener("keydown",z),()=>document.removeEventListener("keydown",z)},[s]),m.useEffect(()=>{if(G.current)return()=>{Q.current&&(Q.current.focus({preventScroll:!0}),Q.current=null,Se.current=!1)}},[G.current]),m.createElement("section",{ref:n,"aria-label":`${x} ${oe}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},F.map((z,Z)=>{var X;const[ve,pt]=z.split("-");return $.length?m.createElement("ol",{key:z,dir:T==="auto"?Ga():T,tabIndex:-1,ref:G,className:c,"data-sonner-toaster":!0,"data-sonner-theme":R,"data-y-position":ve,"data-x-position":pt,style:{"--front-toast-height":`${((X=D[0])==null?void 0:X.height)||0}px`,"--width":`${Wm}px`,"--gap":`${C}px`,...y,...Qm(d,u)},onBlur:W=>{Se.current&&!W.currentTarget.contains(W.relatedTarget)&&(Se.current=!1,Q.current&&(Q.current.focus({preventScroll:!0}),Q.current=null))},onFocus:W=>{W.target instanceof HTMLElement&&W.target.dataset.dismissible==="false"||Se.current||(Se.current=!0,Q.current=W.relatedTarget)},onMouseEnter:()=>O(!0),onMouseMove:()=>O(!0),onMouseLeave:()=>{j||O(!1)},onDragEnd:()=>O(!1),onPointerDown:W=>{W.target instanceof HTMLElement&&W.target.dataset.dismissible==="false"||K(!0)},onPointerUp:()=>K(!1)},$.filter(W=>!W.position&&Z===0||W.position===z).map((W,gt)=>{var Cn,Tn;return m.createElement(Jm,{key:W.id,icons:M,index:gt,toast:W,defaultRichColors:f,duration:(Cn=w?.duration)!=null?Cn:v,className:w?.className,descriptionClassName:w?.descriptionClassName,invert:r,visibleToasts:b,closeButton:(Tn=w?.closeButton)!=null?Tn:l,interacting:j,position:z,style:w?.style,unstyled:w?.unstyled,classNames:w?.classNames,cancelButtonStyle:w?.cancelButtonStyle,actionButtonStyle:w?.actionButtonStyle,closeButtonAriaLabel:w?.closeButtonAriaLabel,removeToast:mt,toasts:$.filter(vt=>vt.position==W.position),heights:D.filter(vt=>vt.position==W.position),setHeights:_,expandByDefault:a,gap:C,expanded:N,swipeDirections:t.swipeDirections})})):null}))}),tp=({spinnerColor:e="orange",...t})=>p.jsx(ep,{position:"bottom-center",theme:"light",richColors:!0,visibleToasts:3,closeButton:!0,duration:3e3,mobileOffset:{bottom:"16px"},toastOptions:{className:"my-toast"},icons:{loading:p.jsx(dn,{color:e,size:"sm"})},...t}),np={elevated:g.css`
421
+ `,Nt=({children:e,size:t=16,color:n,className:o,style:r})=>p.jsx($m,{$size:t,$color:n,className:o,style:r,children:e});function Pm(e){if(typeof document>"u")return;let t=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css",t.appendChild(n),n.styleSheet?n.styleSheet.cssText=e:n.appendChild(document.createTextNode(e))}const km=e=>{switch(e){case"success":return Em;case"info":return Fm;case"warning":return Dm;case"error":return Am;default:return null}},Mm=Array(12).fill(0),Vm=({visible:e,className:t})=>m.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},m.createElement("div",{className:"sonner-spinner"},Mm.map((n,o)=>m.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${o}`})))),Em=m.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},m.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),Dm=m.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},m.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),Fm=m.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},m.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),Am=m.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},m.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),Im=m.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},m.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),m.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),Lm=()=>{const[e,t]=m.useState(document.hidden);return m.useEffect(()=>{const n=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",n),()=>window.removeEventListener("visibilitychange",n)},[]),e};let qo=1;class Rm{constructor(){this.subscribe=t=>(this.subscribers.push(t),()=>{const n=this.subscribers.indexOf(t);this.subscribers.splice(n,1)}),this.publish=t=>{this.subscribers.forEach(n=>n(t))},this.addToast=t=>{this.publish(t),this.toasts=[...this.toasts,t]},this.create=t=>{var n;const{message:o,...r}=t,i=typeof t?.id=="number"||((n=t.id)==null?void 0:n.length)>0?t.id:qo++,s=this.toasts.find(l=>l.id===i),a=t.dismissible===void 0?!0:t.dismissible;return this.dismissedToasts.has(i)&&this.dismissedToasts.delete(i),s?this.toasts=this.toasts.map(l=>l.id===i?(this.publish({...l,...t,id:i,title:o}),{...l,...t,id:i,dismissible:a,title:o}):l):this.addToast({title:o,...r,dismissible:a,id:i}),i},this.dismiss=t=>(t?(this.dismissedToasts.add(t),requestAnimationFrame(()=>this.subscribers.forEach(n=>n({id:t,dismiss:!0})))):this.toasts.forEach(n=>{this.subscribers.forEach(o=>o({id:n.id,dismiss:!0}))}),t),this.message=(t,n)=>this.create({...n,message:t}),this.error=(t,n)=>this.create({...n,message:t,type:"error"}),this.success=(t,n)=>this.create({...n,type:"success",message:t}),this.info=(t,n)=>this.create({...n,type:"info",message:t}),this.warning=(t,n)=>this.create({...n,type:"warning",message:t}),this.loading=(t,n)=>this.create({...n,type:"loading",message:t}),this.promise=(t,n)=>{if(!n)return;let o;n.loading!==void 0&&(o=this.create({...n,promise:t,type:"loading",message:n.loading,description:typeof n.description!="function"?n.description:void 0}));const r=Promise.resolve(t instanceof Function?t():t);let i=o!==void 0,s;const a=r.then(async c=>{if(s=["resolve",c],m.isValidElement(c))i=!1,this.create({id:o,type:"default",message:c});else if(Nm(c)&&!c.ok){i=!1;const u=typeof n.error=="function"?await n.error(`HTTP error! status: ${c.status}`):n.error,h=typeof n.description=="function"?await n.description(`HTTP error! status: ${c.status}`):n.description,v=typeof u=="object"&&!m.isValidElement(u)?u:{message:u};this.create({id:o,type:"error",description:h,...v})}else if(c instanceof Error){i=!1;const u=typeof n.error=="function"?await n.error(c):n.error,h=typeof n.description=="function"?await n.description(c):n.description,v=typeof u=="object"&&!m.isValidElement(u)?u:{message:u};this.create({id:o,type:"error",description:h,...v})}else if(n.success!==void 0){i=!1;const u=typeof n.success=="function"?await n.success(c):n.success,h=typeof n.description=="function"?await n.description(c):n.description,v=typeof u=="object"&&!m.isValidElement(u)?u:{message:u};this.create({id:o,type:"success",description:h,...v})}}).catch(async c=>{if(s=["reject",c],n.error!==void 0){i=!1;const d=typeof n.error=="function"?await n.error(c):n.error,u=typeof n.description=="function"?await n.description(c):n.description,f=typeof d=="object"&&!m.isValidElement(d)?d:{message:d};this.create({id:o,type:"error",description:u,...f})}}).finally(()=>{i&&(this.dismiss(o),o=void 0),n.finally==null||n.finally.call(n)}),l=()=>new Promise((c,d)=>a.then(()=>s[0]==="reject"?d(s[1]):c(s[1])).catch(d));return typeof o!="string"&&typeof o!="number"?{unwrap:l}:Object.assign(o,{unwrap:l})},this.custom=(t,n)=>{const o=n?.id||qo++;return this.create({jsx:t(o),id:o,...n}),o},this.getActiveToasts=()=>this.toasts.filter(t=>!this.dismissedToasts.has(t.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}}const ue=new Rm,_m=(e,t)=>{const n=t?.id||qo++;return ue.addToast({title:e,...t,id:n}),n},Nm=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",Bm=_m,zm=()=>ue.toasts,Om=()=>ue.getActiveToasts(),Hm=Object.assign(Bm,{success:ue.success,info:ue.info,warning:ue.warning,error:ue.error,custom:ue.custom,message:ue.message,promise:ue.promise,dismiss:ue.dismiss,loading:ue.loading},{getHistory:zm,getToasts:Om});Pm("[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-rich-colors=true][data-sonner-toast][data-styled=true] [data-description]{color:inherit}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);background:var(--normal-bg);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast][data-expanded=true]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}");function fn(e){return e.label!==void 0}const jm=3,Gm="24px",Um="16px",Oa=4e3,Km=356,Wm=14,qm=45,Ym=200;function Me(...e){return e.filter(Boolean).join(" ")}function Xm(e){const[t,n]=e.split("-"),o=[];return t&&o.push(t),n&&o.push(n),o}const Zm=e=>{var t,n,o,r,i,s,a,l,c;const{invert:d,toast:u,unstyled:h,interacting:f,setHeights:v,visibleToasts:y,heights:b,index:w,toasts:T,expanded:C,removeToast:k,defaultRichColors:x,closeButton:P,style:V,cancelButtonStyle:$,actionButtonStyle:D,className:F="",descriptionClassName:_="",duration:B,position:H,gap:z,expandByDefault:G,classNames:R,icons:L,closeButtonAriaLabel:j="Close toast"}=e,[oe,Q]=m.useState(null),[Se,pt]=m.useState(null),[O,Z]=m.useState(!1),[W,ve]=m.useState(!1),[gt,q]=m.useState(!1),[vt,Tn]=m.useState(!1),[$n,yt]=m.useState(!1),[Cy,Ar]=m.useState(0),[Ty,fc]=m.useState(0),Gt=m.useRef(u.duration||B||Oa),hc=m.useRef(null),Ie=m.useRef(null),$y=w===0,Py=w+1<=y,fe=u.type,wt=u.dismissible!==!1,ky=u.className||"",My=u.descriptionClassName||"",Pn=m.useMemo(()=>b.findIndex(N=>N.toastId===u.id)||0,[b,u.id]),Vy=m.useMemo(()=>{var N;return(N=u.closeButton)!=null?N:P},[u.closeButton,P]),mc=m.useMemo(()=>u.duration||B||Oa,[u.duration,B]),Ir=m.useRef(0),bt=m.useRef(0),pc=m.useRef(0),xt=m.useRef(null),[Ey,Dy]=H.split("-"),gc=m.useMemo(()=>b.reduce((N,te,ae)=>ae>=Pn?N:N+te.height,0),[b,Pn]),vc=Lm(),Fy=u.invert||d,Lr=fe==="loading";bt.current=m.useMemo(()=>Pn*z+gc,[Pn,gc]),m.useEffect(()=>{Gt.current=mc},[mc]),m.useEffect(()=>{Z(!0)},[]),m.useEffect(()=>{const N=Ie.current;if(N){const te=N.getBoundingClientRect().height;return fc(te),v(ae=>[{toastId:u.id,height:te,position:u.position},...ae]),()=>v(ae=>ae.filter(he=>he.toastId!==u.id))}},[v,u.id]),m.useLayoutEffect(()=>{if(!O)return;const N=Ie.current,te=N.style.height;N.style.height="auto";const ae=N.getBoundingClientRect().height;N.style.height=te,fc(ae),v(he=>he.find(re=>re.toastId===u.id)?he.map(re=>re.toastId===u.id?{...re,height:ae}:re):[{toastId:u.id,height:ae,position:u.position},...he])},[O,u.title,u.description,v,u.id,u.jsx,u.action,u.cancel]);const Ge=m.useCallback(()=>{ve(!0),Ar(bt.current),v(N=>N.filter(te=>te.toastId!==u.id)),setTimeout(()=>{k(u)},Ym)},[u,k,v,bt]);m.useEffect(()=>{if(u.promise&&fe==="loading"||u.duration===1/0||u.type==="loading")return;let N;return C||f||vc?(()=>{if(pc.current<Ir.current){const he=new Date().getTime()-Ir.current;Gt.current=Gt.current-he}pc.current=new Date().getTime()})():Gt.current!==1/0&&(Ir.current=new Date().getTime(),N=setTimeout(()=>{u.onAutoClose==null||u.onAutoClose.call(u,u),Ge()},Gt.current)),()=>clearTimeout(N)},[C,f,u,fe,vc,Ge]),m.useEffect(()=>{u.delete&&(Ge(),u.onDismiss==null||u.onDismiss.call(u,u))},[Ge,u.delete]);function Ay(){var N;if(L?.loading){var te;return m.createElement("div",{className:Me(R?.loader,u==null||(te=u.classNames)==null?void 0:te.loader,"sonner-loader"),"data-visible":fe==="loading"},L.loading)}return m.createElement(Vm,{className:Me(R?.loader,u==null||(N=u.classNames)==null?void 0:N.loader),visible:fe==="loading"})}const Iy=u.icon||L?.[fe]||km(fe);var yc,wc;return m.createElement("li",{tabIndex:0,ref:Ie,className:Me(F,ky,R?.toast,u==null||(t=u.classNames)==null?void 0:t.toast,R?.default,R?.[fe],u==null||(n=u.classNames)==null?void 0:n[fe]),"data-sonner-toast":"","data-rich-colors":(yc=u.richColors)!=null?yc:x,"data-styled":!(u.jsx||u.unstyled||h),"data-mounted":O,"data-promise":!!u.promise,"data-swiped":$n,"data-removed":W,"data-visible":Py,"data-y-position":Ey,"data-x-position":Dy,"data-index":w,"data-front":$y,"data-swiping":gt,"data-dismissible":wt,"data-type":fe,"data-invert":Fy,"data-swipe-out":vt,"data-swipe-direction":Se,"data-expanded":!!(C||G&&O),"data-testid":u.testId,style:{"--index":w,"--toasts-before":w,"--z-index":T.length-w,"--offset":`${W?Cy:bt.current}px`,"--initial-height":G?"auto":`${Ty}px`,...V,...u.style},onDragEnd:()=>{q(!1),Q(null),xt.current=null},onPointerDown:N=>{N.button!==2&&(Lr||!wt||(hc.current=new Date,Ar(bt.current),N.target.setPointerCapture(N.pointerId),N.target.tagName!=="BUTTON"&&(q(!0),xt.current={x:N.clientX,y:N.clientY})))},onPointerUp:()=>{var N,te,ae;if(vt||!wt)return;xt.current=null;const he=Number(((N=Ie.current)==null?void 0:N.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),kn=Number(((te=Ie.current)==null?void 0:te.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),re=new Date().getTime()-((ae=hc.current)==null?void 0:ae.getTime()),ye=oe==="x"?he:kn,Mn=Math.abs(ye)/re;if(Math.abs(ye)>=qm||Mn>.11){Ar(bt.current),u.onDismiss==null||u.onDismiss.call(u,u),pt(oe==="x"?he>0?"right":"left":kn>0?"down":"up"),Ge(),Tn(!0);return}else{var Ce,Te;(Ce=Ie.current)==null||Ce.style.setProperty("--swipe-amount-x","0px"),(Te=Ie.current)==null||Te.style.setProperty("--swipe-amount-y","0px")}yt(!1),q(!1),Q(null)},onPointerMove:N=>{var te,ae,he;if(!xt.current||!wt||((te=window.getSelection())==null?void 0:te.toString().length)>0)return;const re=N.clientY-xt.current.y,ye=N.clientX-xt.current.x;var Mn;const Ce=(Mn=e.swipeDirections)!=null?Mn:Xm(H);!oe&&(Math.abs(ye)>1||Math.abs(re)>1)&&Q(Math.abs(ye)>Math.abs(re)?"x":"y");let Te={x:0,y:0};const bc=et=>1/(1.5+Math.abs(et)/20);if(oe==="y"){if(Ce.includes("top")||Ce.includes("bottom"))if(Ce.includes("top")&&re<0||Ce.includes("bottom")&&re>0)Te.y=re;else{const et=re*bc(re);Te.y=Math.abs(et)<Math.abs(re)?et:re}}else if(oe==="x"&&(Ce.includes("left")||Ce.includes("right")))if(Ce.includes("left")&&ye<0||Ce.includes("right")&&ye>0)Te.x=ye;else{const et=ye*bc(ye);Te.x=Math.abs(et)<Math.abs(ye)?et:ye}(Math.abs(Te.x)>0||Math.abs(Te.y)>0)&&yt(!0),(ae=Ie.current)==null||ae.style.setProperty("--swipe-amount-x",`${Te.x}px`),(he=Ie.current)==null||he.style.setProperty("--swipe-amount-y",`${Te.y}px`)}},Vy&&!u.jsx&&fe!=="loading"?m.createElement("button",{"aria-label":j,"data-disabled":Lr,"data-close-button":!0,onClick:Lr||!wt?()=>{}:()=>{Ge(),u.onDismiss==null||u.onDismiss.call(u,u)},className:Me(R?.closeButton,u==null||(o=u.classNames)==null?void 0:o.closeButton)},(wc=L?.close)!=null?wc:Im):null,(fe||u.icon||u.promise)&&u.icon!==null&&(L?.[fe]!==null||u.icon)?m.createElement("div",{"data-icon":"",className:Me(R?.icon,u==null||(r=u.classNames)==null?void 0:r.icon)},u.promise||u.type==="loading"&&!u.icon?u.icon||Ay():null,u.type!=="loading"?Iy:null):null,m.createElement("div",{"data-content":"",className:Me(R?.content,u==null||(i=u.classNames)==null?void 0:i.content)},m.createElement("div",{"data-title":"",className:Me(R?.title,u==null||(s=u.classNames)==null?void 0:s.title)},u.jsx?u.jsx:typeof u.title=="function"?u.title():u.title),u.description?m.createElement("div",{"data-description":"",className:Me(_,My,R?.description,u==null||(a=u.classNames)==null?void 0:a.description)},typeof u.description=="function"?u.description():u.description):null),m.isValidElement(u.cancel)?u.cancel:u.cancel&&fn(u.cancel)?m.createElement("button",{"data-button":!0,"data-cancel":!0,style:u.cancelButtonStyle||$,onClick:N=>{fn(u.cancel)&&wt&&(u.cancel.onClick==null||u.cancel.onClick.call(u.cancel,N),Ge())},className:Me(R?.cancelButton,u==null||(l=u.classNames)==null?void 0:l.cancelButton)},u.cancel.label):null,m.isValidElement(u.action)?u.action:u.action&&fn(u.action)?m.createElement("button",{"data-button":!0,"data-action":!0,style:u.actionButtonStyle||D,onClick:N=>{fn(u.action)&&(u.action.onClick==null||u.action.onClick.call(u.action,N),!N.defaultPrevented&&Ge())},className:Me(R?.actionButton,u==null||(c=u.classNames)==null?void 0:c.actionButton)},u.action.label):null)};function Ha(){if(typeof window>"u"||typeof document>"u")return"ltr";const e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}function Jm(e,t){const n={};return[e,t].forEach((o,r)=>{const i=r===1,s=i?"--mobile-offset":"--offset",a=i?Um:Gm;function l(c){["top","right","bottom","left"].forEach(d=>{n[`${s}-${d}`]=typeof c=="number"?`${c}px`:c})}typeof o=="number"||typeof o=="string"?l(o):typeof o=="object"?["top","right","bottom","left"].forEach(c=>{o[c]===void 0?n[`${s}-${c}`]=a:n[`${s}-${c}`]=typeof o[c]=="number"?`${o[c]}px`:o[c]}):l(a)}),n}const Qm=m.forwardRef(function(t,n){const{id:o,invert:r,position:i="bottom-right",hotkey:s=["altKey","KeyT"],expand:a,closeButton:l,className:c,offset:d,mobileOffset:u,theme:h="light",richColors:f,duration:v,style:y,visibleToasts:b=jm,toastOptions:w,dir:T=Ha(),gap:C=Wm,icons:k,containerAriaLabel:x="Notifications"}=t,[P,V]=m.useState([]),$=m.useMemo(()=>o?P.filter(O=>O.toasterId===o):P.filter(O=>!O.toasterId),[P,o]),D=m.useMemo(()=>Array.from(new Set([i].concat($.filter(O=>O.position).map(O=>O.position)))),[$,i]),[F,_]=m.useState([]),[B,H]=m.useState(!1),[z,G]=m.useState(!1),[R,L]=m.useState(h!=="system"?h:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),j=m.useRef(null),oe=s.join("+").replace(/Key/g,"").replace(/Digit/g,""),Q=m.useRef(null),Se=m.useRef(!1),pt=m.useCallback(O=>{V(Z=>{var W;return(W=Z.find(ve=>ve.id===O.id))!=null&&W.delete||ue.dismiss(O.id),Z.filter(({id:ve})=>ve!==O.id)})},[]);return m.useEffect(()=>ue.subscribe(O=>{if(O.dismiss){requestAnimationFrame(()=>{V(Z=>Z.map(W=>W.id===O.id?{...W,delete:!0}:W))});return}setTimeout(()=>{Rr.flushSync(()=>{V(Z=>{const W=Z.findIndex(ve=>ve.id===O.id);return W!==-1?[...Z.slice(0,W),{...Z[W],...O},...Z.slice(W+1)]:[O,...Z]})})})}),[P]),m.useEffect(()=>{if(h!=="system"){L(h);return}if(h==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?L("dark"):L("light")),typeof window>"u")return;const O=window.matchMedia("(prefers-color-scheme: dark)");try{O.addEventListener("change",({matches:Z})=>{L(Z?"dark":"light")})}catch{O.addListener(({matches:W})=>{try{L(W?"dark":"light")}catch(ve){console.error(ve)}})}},[h]),m.useEffect(()=>{P.length<=1&&H(!1)},[P]),m.useEffect(()=>{const O=Z=>{var W;if(s.every(q=>Z[q]||Z.code===q)){var gt;H(!0),(gt=j.current)==null||gt.focus()}Z.code==="Escape"&&(document.activeElement===j.current||(W=j.current)!=null&&W.contains(document.activeElement))&&H(!1)};return document.addEventListener("keydown",O),()=>document.removeEventListener("keydown",O)},[s]),m.useEffect(()=>{if(j.current)return()=>{Q.current&&(Q.current.focus({preventScroll:!0}),Q.current=null,Se.current=!1)}},[j.current]),m.createElement("section",{ref:n,"aria-label":`${x} ${oe}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},D.map((O,Z)=>{var W;const[ve,gt]=O.split("-");return $.length?m.createElement("ol",{key:O,dir:T==="auto"?Ha():T,tabIndex:-1,ref:j,className:c,"data-sonner-toaster":!0,"data-sonner-theme":R,"data-y-position":ve,"data-x-position":gt,style:{"--front-toast-height":`${((W=F[0])==null?void 0:W.height)||0}px`,"--width":`${Km}px`,"--gap":`${C}px`,...y,...Jm(d,u)},onBlur:q=>{Se.current&&!q.currentTarget.contains(q.relatedTarget)&&(Se.current=!1,Q.current&&(Q.current.focus({preventScroll:!0}),Q.current=null))},onFocus:q=>{q.target instanceof HTMLElement&&q.target.dataset.dismissible==="false"||Se.current||(Se.current=!0,Q.current=q.relatedTarget)},onMouseEnter:()=>H(!0),onMouseMove:()=>H(!0),onMouseLeave:()=>{z||H(!1)},onDragEnd:()=>H(!1),onPointerDown:q=>{q.target instanceof HTMLElement&&q.target.dataset.dismissible==="false"||G(!0)},onPointerUp:()=>G(!1)},$.filter(q=>!q.position&&Z===0||q.position===O).map((q,vt)=>{var Tn,$n;return m.createElement(Zm,{key:q.id,icons:k,index:vt,toast:q,defaultRichColors:f,duration:(Tn=w?.duration)!=null?Tn:v,className:w?.className,descriptionClassName:w?.descriptionClassName,invert:r,visibleToasts:b,closeButton:($n=w?.closeButton)!=null?$n:l,interacting:z,position:O,style:w?.style,unstyled:w?.unstyled,classNames:w?.classNames,cancelButtonStyle:w?.cancelButtonStyle,actionButtonStyle:w?.actionButtonStyle,closeButtonAriaLabel:w?.closeButtonAriaLabel,removeToast:pt,toasts:$.filter(yt=>yt.position==q.position),heights:F.filter(yt=>yt.position==q.position),setHeights:_,expandByDefault:a,gap:C,expanded:B,swipeDirections:t.swipeDirections})})):null}))}),ep=({spinnerColor:e="orange",...t})=>p.jsx(Qm,{position:"bottom-center",theme:"light",richColors:!0,visibleToasts:3,closeButton:!0,duration:3e3,mobileOffset:{bottom:"16px"},toastOptions:{className:"my-toast"},icons:{loading:p.jsx(dn,{color:e,size:"sm"})},...t}),tp={elevated:g.css`
422
422
  background-color: var(--color-main-white);
423
423
  box-shadow: var(--shadow-black-card);
424
424
  border: none;
@@ -445,7 +445,7 @@
445
445
  &:active {
446
446
  border: none;
447
447
  }
448
- `},op={sm:g.css`
448
+ `},np={sm:g.css`
449
449
  padding: 0.75rem;
450
450
  gap: 0.5rem;
451
451
  `,md:g.css`
@@ -454,7 +454,7 @@
454
454
  `,lg:g.css`
455
455
  padding: 1.25rem;
456
456
  gap: 0.5rem;
457
- `},rp=g.css`
457
+ `},op=g.css`
458
458
  transition:
459
459
  box-shadow 0.3s ease-out,
460
460
  background-color 0.3s ease-out,
@@ -474,7 +474,7 @@
474
474
  &:focus-visible {
475
475
  outline-color: var(--color-main-blue-primary);
476
476
  }
477
- `,ip=g.css`
477
+ `,rp=g.css`
478
478
  opacity: 0.6;
479
479
  cursor: not-allowed;
480
480
  pointer-events: none;
@@ -483,7 +483,7 @@
483
483
  transform: none;
484
484
  box-shadow: inherit;
485
485
  }
486
- `,sp=g.div`
486
+ `,ip=g.div`
487
487
  display: flex;
488
488
  flex-direction: column;
489
489
  border-radius: var(--border-radius-card);
@@ -491,11 +491,11 @@
491
491
  height: 100%;
492
492
  outline: 2px solid transparent;
493
493
  outline-offset: -1px;
494
- ${({$variant:e})=>np[e]}
495
- ${({$clickable:e})=>e&&rp}
496
- ${({$disabled:e})=>e&&ip}
497
- ${({$size:e})=>op[e]}
498
- `,ap=({variant:e="elevated",size:t="md",disabled:n=!1,onClick:o=void 0,children:r,...i})=>{const s=a=>{n||o&&o(a)};return p.jsx(sp,{$variant:e,$size:t,$disabled:n,$clickable:!!o,onClick:s,role:o?"button":void 0,tabIndex:o&&!n?0:void 0,onKeyDown:o&&!n?a=>{(a.key==="Enter"||a.key===" ")&&(a.preventDefault(),s(a))}:void 0,...i,children:r})},lp=g.div`
494
+ ${({$variant:e})=>tp[e]}
495
+ ${({$clickable:e})=>e&&op}
496
+ ${({$disabled:e})=>e&&rp}
497
+ ${({$size:e})=>np[e]}
498
+ `,sp=({variant:e="elevated",size:t="md",disabled:n=!1,onClick:o=void 0,children:r,...i})=>{const s=a=>{n||o&&o(a)};return p.jsx(ip,{$variant:e,$size:t,$disabled:n,$clickable:!!o,onClick:s,role:o?"button":void 0,tabIndex:o&&!n?0:void 0,onKeyDown:o&&!n?a=>{(a.key==="Enter"||a.key===" ")&&(a.preventDefault(),s(a))}:void 0,...i,children:r})},ap=g.div`
499
499
  display: flex;
500
500
  align-items: center;
501
501
  align-self: stretch;
@@ -505,16 +505,16 @@
505
505
  border-bottom: 1px solid var(--color-divider);
506
506
  padding-bottom: 0.5rem;
507
507
  `}
508
- `,cp=({children:e,showDivider:t=!1,...n})=>p.jsx(lp,{$showDivider:t,...n,children:e}),up=g.div`
508
+ `,lp=({children:e,showDivider:t=!1,...n})=>p.jsx(ap,{$showDivider:t,...n,children:e}),cp=g.div`
509
509
  flex: 1;
510
510
  display: flex;
511
511
  flex-direction: column;
512
- `,dp=({children:e,showDivider:t=!1,...n})=>p.jsx(up,{$showDivider:t,...n,children:e}),fp=g.div`
512
+ `,up=({children:e,showDivider:t=!1,...n})=>p.jsx(cp,{$showDivider:t,...n,children:e}),dp=g.div`
513
513
  display: flex;
514
514
  align-items: center;
515
515
  align-self: stretch;
516
516
  gap: 0.5rem;
517
- `,hp=({children:e,...t})=>p.jsx(fp,{...t,children:e}),mp={xs:g.css`
517
+ `,fp=({children:e,...t})=>p.jsx(dp,{...t,children:e}),hp={xs:g.css`
518
518
  ${E[12]}
519
519
  `,sm:g.css`
520
520
  ${E[12]}
@@ -522,15 +522,15 @@
522
522
  ${E[16]}
523
523
  `,lg:g.css`
524
524
  ${E[18]}
525
- `},pp=g.div`
525
+ `},mp=g.div`
526
526
  color: var(--color-main-warning-state);
527
- ${({$size:e})=>mp[e]}
527
+ ${({$size:e})=>hp[e]}
528
528
  font-weight: 400;
529
529
  margin-top: 0.25rem;
530
530
  display: flex;
531
531
  align-items: flex-start;
532
532
  gap: 0.25rem;
533
- `,qo=({children:e,className:t,size:n="md",...o})=>p.jsx(pp,{className:t,$size:n,...o,children:e}),gp={xs:g.css`
533
+ `,Yo=({children:e,className:t,size:n="md",...o})=>p.jsx(mp,{className:t,$size:n,...o,children:e}),pp={xs:g.css`
534
534
  ${E[14]}
535
535
  `,sm:g.css`
536
536
  ${E[16]}
@@ -538,15 +538,15 @@
538
538
  ${E[24]}
539
539
  `,lg:g.css`
540
540
  ${E[30]}
541
- `},vp=g.label`
541
+ `},gp=g.label`
542
542
  color: var(--color-main-blue-primary);
543
- ${({$size:e})=>gp[e]}
544
- ${({$disabled:e})=>e&&yp}
543
+ ${({$size:e})=>pp[e]}
544
+ ${({$disabled:e})=>e&&vp}
545
545
  cursor: ${({$disabled:e,$htmlFor:t})=>e||!t?"default":"pointer"};
546
- `,yp=g.css`
546
+ `,vp=g.css`
547
547
  cursor: not-allowed;
548
548
  opacity: 0.6;
549
- `,hn=({children:e,htmlFor:t,className:n,required:o,disabled:r=!1,size:i="md",...s})=>p.jsxs(vp,{className:n,htmlFor:t,$htmlFor:t,$size:i,$disabled:r,...s,children:[e,o&&p.jsx("span",{style:{color:"var(--color-main-warning-state)"},children:"*"})]}),Ua=["text","email","password","number","tel","url","date","datetime-local","time","search","textarea","select","checkbox","radio","pin"],Ka=e=>Ua.includes(e),ze=e=>e.map(t=>({name:t.name||"",label:t.label||"",type:t.type&&Ka(t.type)?t.type:"text",placeholder:t.placeholder,required:t.required||!1,disabled:t.disabled||!1,options:t.options||[],validation:t.validation,checkboxLabel:t.checkboxLabel,radioName:t.radioName,pinLength:t.pinLength||6,pinType:t.pinType||"number",rows:t.rows||4,size:t.size||"md",inputClassName:t.inputClassName,labelClassName:t.labelClassName,messageErrorClassName:t.messageErrorClassName})),wp=e=>e.map(t=>({value:t.value,label:t.label})),bp={text:(e,t,n)=>ze([{name:e,label:t,type:"text",...n}])[0],email:(e,t,n)=>ze([{name:e,label:t,type:"email",required:!0,...n}])[0],password:(e,t,n)=>ze([{name:e,label:t,type:"password",required:!0,validation:{pattern:"^(?=.*[a-z])(?=.*[A-Z])(?=.*\\d)[a-zA-Z\\d@$!%*?&]{8,}$",custom:o=>{if(o&&o.length<8)return"Password must be at least 8 characters long"}},...n}])[0],select:(e,t,n,o)=>ze([{name:e,label:t,type:"select",options:n,required:!0,...o}])[0],checkbox:(e,t,n)=>ze([{name:e,label:t,type:"checkbox",checkboxLabel:t,...n}])[0],radio:(e,t,n,o)=>ze([{name:e,label:t,type:"radio",options:n,radioName:e,required:!0,...o}])[0],pin:(e,t,n=6,o)=>ze([{name:e,label:t,type:"pin",pinLength:n,pinType:"number",required:!0,validation:{custom:r=>{if(r&&r.length!==n)return`${t} must be ${n} digits long`}},...o}])[0]},xp=(e,t,n,o,r,i,s,a)=>{const{field:l,...c}=t,d={...l,...c,size:c.size,hasError:c.hasError,disabled:c.disabled,placeholder:c.placeholder,className:c.className};switch(e){case"textarea":return{component:"textarea",props:{...d,rows:s?.rows||4}};case"select":return{component:"select",props:{...d,options:n?.options||[],onOptionSelect:n?.onOptionSelect,placeholder:t.placeholder||"Selecciona una opción"}};case"checkbox":return{component:"checkbox",props:{...d,label:o?.checkboxLabel||o?.label,checked:t.field.value||o?.checked||!1}};case"radio":return{component:"radio",props:{...d,options:r?.options||[],radioName:r?.radioName||t.name,onRadioChange:r?.onRadioChange}};case"pin":return{component:"pin",props:{...d,length:i?.pinLength||6,type:i?.pinType||"number",onComplete:i?.onPinComplete}};case"password":return{component:"password",props:{...d,type:"password"}};case"search":return{component:"search",props:{...d,onSearch:a?.onSearch}};default:return{component:"base",props:{...d,type:t.type||e||"text"}}}},Ze=g.css`
549
+ `,hn=({children:e,htmlFor:t,className:n,required:o,disabled:r=!1,size:i="md",...s})=>p.jsxs(gp,{className:n,htmlFor:t,$htmlFor:t,$size:i,$disabled:r,...s,children:[e,o&&p.jsx("span",{style:{color:"var(--color-main-warning-state)"},children:"*"})]}),ja=["text","email","password","number","tel","url","date","datetime-local","time","search","textarea","select","checkbox","radio","pin"],Ga=e=>ja.includes(e),ze=e=>e.map(t=>({name:t.name||"",label:t.label||"",type:t.type&&Ga(t.type)?t.type:"text",placeholder:t.placeholder,required:t.required||!1,disabled:t.disabled||!1,options:t.options||[],validation:t.validation,checkboxLabel:t.checkboxLabel,radioName:t.radioName,pinLength:t.pinLength||6,pinType:t.pinType||"number",rows:t.rows||4,size:t.size||"md",inputClassName:t.inputClassName,labelClassName:t.labelClassName,messageErrorClassName:t.messageErrorClassName})),yp=e=>e.map(t=>({value:t.value,label:t.label})),wp={text:(e,t,n)=>ze([{name:e,label:t,type:"text",...n}])[0],email:(e,t,n)=>ze([{name:e,label:t,type:"email",required:!0,...n}])[0],password:(e,t,n)=>ze([{name:e,label:t,type:"password",required:!0,validation:{pattern:"^(?=.*[a-z])(?=.*[A-Z])(?=.*\\d)[a-zA-Z\\d@$!%*?&]{8,}$",custom:o=>{if(o&&o.length<8)return"Password must be at least 8 characters long"}},...n}])[0],select:(e,t,n,o)=>ze([{name:e,label:t,type:"select",options:n,required:!0,...o}])[0],checkbox:(e,t,n)=>ze([{name:e,label:t,type:"checkbox",checkboxLabel:t,...n}])[0],radio:(e,t,n,o)=>ze([{name:e,label:t,type:"radio",options:n,radioName:e,required:!0,...o}])[0],pin:(e,t,n=6,o)=>ze([{name:e,label:t,type:"pin",pinLength:n,pinType:"number",required:!0,validation:{custom:r=>{if(r&&r.length!==n)return`${t} must be ${n} digits long`}},...o}])[0]},bp=(e,t,n,o,r,i,s,a)=>{const{field:l,...c}=t,d={...l,...c,size:c.size,hasError:c.hasError,disabled:c.disabled,placeholder:c.placeholder,className:c.className};switch(e){case"textarea":return{component:"textarea",props:{...d,rows:s?.rows||4}};case"select":return{component:"select",props:{...d,options:n?.options||[],onOptionSelect:n?.onOptionSelect,placeholder:t.placeholder||"Selecciona una opción"}};case"checkbox":return{component:"checkbox",props:{...d,label:o?.checkboxLabel||o?.label,checked:t.field.value||o?.checked||!1}};case"radio":return{component:"radio",props:{...d,options:r?.options||[],radioName:r?.radioName||t.name,onRadioChange:r?.onRadioChange}};case"pin":return{component:"pin",props:{...d,length:i?.pinLength||6,type:i?.pinType||"number",onComplete:i?.onPinComplete}};case"password":return{component:"password",props:{...d,type:"password"}};case"search":return{component:"search",props:{...d,onSearch:a?.onSearch}};default:return{component:"base",props:{...d,type:t.type||e||"text"}}}},Ze=g.css`
550
550
  display: flex;
551
551
  justify-content: space-between;
552
552
  align-items: center;
@@ -604,7 +604,7 @@
604
604
  border: var(--border-input-disabled) !important;
605
605
  cursor: not-allowed;
606
606
  opacity: 0.6;
607
- `,Wa=g.css`
607
+ `,Ua=g.css`
608
608
  border: none;
609
609
  border-top: 0;
610
610
  border-right: 0;
@@ -652,29 +652,29 @@
652
652
  justify-content: center;
653
653
  flex-shrink: 0;
654
654
  user-select: none;
655
- `,Sp=g.div`
655
+ `,xp=g.div`
656
656
  ${Ze}
657
657
  ${({$size:e})=>Bt[e]}
658
658
  ${({$hasError:e})=>e&&Je}
659
659
  ${({$disabled:e})=>e&&Oe}
660
- ${({$isFlushed:e})=>e&&Wa}
661
- `,Cp=g.input`
660
+ ${({$isFlushed:e})=>e&&Ua}
661
+ `,Sp=g.input`
662
662
  ${mn}
663
- `,Yo=m.forwardRef(({size:e="md",hasError:t=!1,disabled:n=!1,type:o="text",flushed:r=!1,leftIcon:i,rightIcon:s,iconSize:a="md",iconColor:l="currentColor",className:c,...d},u)=>p.jsxs(Sp,{$size:e,$hasError:t,className:c,$isFlushed:r,children:[i&&p.jsx(H,{component:i,size:a,color:n?"var(--color-dark-200)":l}),p.jsx(Cp,{ref:u,type:o,$hasError:t,disabled:n,...d}),s&&p.jsx(H,{component:s,size:a,color:n?"var(--color-dark-200)":l})]}));Yo.displayName="BaseInput";const Tp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M13.0001 16.1716L18.3641 10.8076L19.7783 12.2218L12.0001 20L4.22192 12.2218L5.63614 10.8076L11.0001 16.1716V4H13.0001V16.1716Z"})),qa=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M11.9999 13.1714L16.9497 8.22168L18.3639 9.63589L11.9999 15.9999L5.63599 9.63589L7.0502 8.22168L11.9999 13.1714Z"})),$p=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M13.1717 12.0007L8.22192 7.05093L9.63614 5.63672L16.0001 12.0007L9.63614 18.3646L8.22192 16.9504L13.1717 12.0007Z"})),Pp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M11.9498 7.94975L10.5356 9.36396L8.00079 6.828L8.00004 20H6.00004L6.00079 6.828L3.46451 9.36396L2.05029 7.94975L7.00004 3L11.9498 7.94975ZM21.9498 16.0503L17 21L12.0503 16.0503L13.4645 14.636L16.0008 17.172L16 4H18L18.0008 17.172L20.5356 14.636L21.9498 16.0503Z"})),Ya=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M11.9997 10.5865L16.9495 5.63672L18.3637 7.05093L13.4139 12.0007L18.3637 16.9504L16.9495 18.3646L11.9997 13.4149L7.04996 18.3646L5.63574 16.9504L10.5855 12.0007L5.63574 7.05093L7.04996 5.63672L11.9997 10.5865Z"})),Mp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M10 6V8H5V19H16V14H18V20C18 20.5523 17.5523 21 17 21H4C3.44772 21 3 20.5523 3 20V7C3 6.44772 3.44772 6 4 6H10ZM21 3V11H19L18.9999 6.413L11.2071 14.2071L9.79289 12.7929L17.5849 5H13V3H21Z"})),kp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M12.0003 3C17.3924 3 21.8784 6.87976 22.8189 12C21.8784 17.1202 17.3924 21 12.0003 21C6.60812 21 2.12215 17.1202 1.18164 12C2.12215 6.87976 6.60812 3 12.0003 3ZM12.0003 19C16.2359 19 19.8603 16.052 20.7777 12C19.8603 7.94803 16.2359 5 12.0003 5C7.7646 5 4.14022 7.94803 3.22278 12C4.14022 16.052 7.7646 19 12.0003 19ZM12.0003 16.5C9.51498 16.5 7.50026 14.4853 7.50026 12C7.50026 9.51472 9.51498 7.5 12.0003 7.5C14.4855 7.5 16.5003 9.51472 16.5003 12C16.5003 14.4853 14.4855 16.5 12.0003 16.5ZM12.0003 14.5C13.381 14.5 14.5003 13.3807 14.5003 12C14.5003 10.6193 13.381 9.5 12.0003 9.5C10.6196 9.5 9.50026 10.6193 9.50026 12C9.50026 13.3807 10.6196 14.5 12.0003 14.5Z"})),Vp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M17.8827 19.2968C16.1814 20.3755 14.1638 21.0002 12.0003 21.0002C6.60812 21.0002 2.12215 17.1204 1.18164 12.0002C1.61832 9.62282 2.81932 7.5129 4.52047 5.93457L1.39366 2.80777L2.80788 1.39355L22.6069 21.1925L21.1927 22.6068L17.8827 19.2968ZM5.9356 7.3497C4.60673 8.56015 3.6378 10.1672 3.22278 12.0002C4.14022 16.0521 7.7646 19.0002 12.0003 19.0002C13.5997 19.0002 15.112 18.5798 16.4243 17.8384L14.396 15.8101C13.7023 16.2472 12.8808 16.5002 12.0003 16.5002C9.51498 16.5002 7.50026 14.4854 7.50026 12.0002C7.50026 11.1196 7.75317 10.2981 8.19031 9.60442L5.9356 7.3497ZM12.9139 14.328L9.67246 11.0866C9.5613 11.3696 9.50026 11.6777 9.50026 12.0002C9.50026 13.3809 10.6196 14.5002 12.0003 14.5002C12.3227 14.5002 12.6309 14.4391 12.9139 14.328ZM20.8068 16.5925L19.376 15.1617C20.0319 14.2268 20.5154 13.1586 20.7777 12.0002C19.8603 7.94818 16.2359 5.00016 12.0003 5.00016C11.1544 5.00016 10.3329 5.11773 9.55249 5.33818L7.97446 3.76015C9.22127 3.26959 10.5793 3.00016 12.0003 3.00016C17.3924 3.00016 21.8784 6.87992 22.8189 12.0002C22.5067 13.6998 21.8038 15.2628 20.8068 16.5925ZM11.7229 7.50857C11.8146 7.50299 11.9071 7.50016 12.0003 7.50016C14.4855 7.50016 16.5003 9.51488 16.5003 12.0002C16.5003 12.0933 16.4974 12.1858 16.4919 12.2775L11.7229 7.50857Z"})),Ep=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M21 4V6H20L14 15V22H10V15L4 6H3V4H21Z"})),Dp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M21 4V6H20L15 13.5V22H9V13.5L4 6H3V4H21ZM6.4037 6L11 12.8944V20H13V12.8944L17.5963 6H6.4037Z"})),Fp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M5 22C4.44772 22 4 21.5523 4 21V3C4 2.44772 4.44772 2 5 2H19C19.5523 2 20 2.44772 20 3V6H18V4H6V20H18V18H20V21C20 21.5523 19.5523 22 19 22H5ZM18 16V13H11V11H18V8L23 12L18 16Z"})),Xa=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M3 4H21V6H3V4ZM3 11H21V13H3V11ZM3 18H21V20H3V18Z"})),Ap=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M20 17H22V19H2V17H4V10C4 5.58172 7.58172 2 12 2C16.4183 2 20 5.58172 20 10V17ZM9 21H15V23H9V21Z"})),Ip=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M20 17H22V19H2V17H4V10C4 5.58172 7.58172 2 12 2C16.4183 2 20 5.58172 20 10V17ZM18 17V10C18 6.68629 15.3137 4 12 4C8.68629 4 6 6.68629 6 10V17H18ZM9 21H15V23H9V21Z"})),Za=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M18.031 16.6168L22.3137 20.8995L20.8995 22.3137L16.6168 18.031C15.0769 19.263 13.124 20 11 20C6.032 20 2 15.968 2 11C2 6.032 6.032 2 11 2C15.968 2 20 6.032 20 11C20 13.124 19.263 15.0769 18.031 16.6168ZM16.0247 15.8748C17.2475 14.6146 18 12.8956 18 11C18 7.1325 14.8675 4 11 4C7.1325 4 4 7.1325 4 11C4 14.8675 7.1325 18 11 18C12.8956 18 14.6146 17.2475 15.8748 16.0247L16.0247 15.8748Z"})),Lp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M12 12.5858L16.2426 16.8284L14.8284 18.2426L13 16.415V22H11V16.413L9.17157 18.2426L7.75736 16.8284L12 12.5858ZM12 2C15.5934 2 18.5544 4.70761 18.9541 8.19395C21.2858 8.83154 23 10.9656 23 13.5C23 16.3688 20.8036 18.7246 18.0006 18.9776L18.0009 16.9644C19.6966 16.7214 21 15.2629 21 13.5C21 11.567 19.433 10 17.5 10C17.2912 10 17.0867 10.0183 16.8887 10.054C16.9616 9.7142 17 9.36158 17 9C17 6.23858 14.7614 4 12 4C9.23858 4 7 6.23858 7 9C7 9.36158 7.03838 9.7142 7.11205 10.0533C6.91331 10.0183 6.70879 10 6.5 10C4.567 10 3 11.567 3 13.5C3 15.2003 4.21241 16.6174 5.81986 16.934L6.00005 16.9646L6.00039 18.9776C3.19696 18.7252 1 16.3692 1 13.5C1 10.9656 2.71424 8.83154 5.04648 8.19411C5.44561 4.70761 8.40661 2 12 2Z"})),Rp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M20 22H18V20C18 18.3431 16.6569 17 15 17H9C7.34315 17 6 18.3431 6 20V22H4V20C4 17.2386 6.23858 15 9 15H15C17.7614 15 20 17.2386 20 20V22ZM12 13C8.68629 13 6 10.3137 6 7C6 3.68629 8.68629 1 12 1C15.3137 1 18 3.68629 18 7C18 10.3137 15.3137 13 12 13ZM12 11C14.2091 11 16 9.20914 16 7C16 4.79086 14.2091 3 12 3C9.79086 3 8 4.79086 8 7C8 9.20914 9.79086 11 12 11Z"})),_p=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M22.0003 13.0001L22.0004 11.0002L5.82845 11.0002L9.77817 7.05044L8.36396 5.63623L2 12.0002L8.36396 18.3642L9.77817 16.9499L5.8284 13.0002L22.0003 13.0001Z"})),Bp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M1.99974 13.0001L1.9996 11.0002L18.1715 11.0002L14.2218 7.05044L15.636 5.63623L22 12.0002L15.636 18.3642L14.2218 16.9499L18.1716 13.0002L1.99974 13.0001Z"})),Np=g.div`
663
+ `,Xo=m.forwardRef(({size:e="md",hasError:t=!1,disabled:n=!1,type:o="text",flushed:r=!1,leftIcon:i,rightIcon:s,iconSize:a="md",iconColor:l="currentColor",className:c,...d},u)=>p.jsxs(xp,{$size:e,$hasError:t,className:c,$isFlushed:r,children:[i&&p.jsx(U,{component:i,size:a,color:n?"var(--color-dark-200)":l}),p.jsx(Sp,{ref:u,type:o,$hasError:t,disabled:n,...d}),s&&p.jsx(U,{component:s,size:a,color:n?"var(--color-dark-200)":l})]}));Xo.displayName="BaseInput";const Cp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M13.0001 16.1716L18.3641 10.8076L19.7783 12.2218L12.0001 20L4.22192 12.2218L5.63614 10.8076L11.0001 16.1716V4H13.0001V16.1716Z"})),Ka=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M11.9999 13.1714L16.9497 8.22168L18.3639 9.63589L11.9999 15.9999L5.63599 9.63589L7.0502 8.22168L11.9999 13.1714Z"})),Tp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M13.1717 12.0007L8.22192 7.05093L9.63614 5.63672L16.0001 12.0007L9.63614 18.3646L8.22192 16.9504L13.1717 12.0007Z"})),$p=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M11.9498 7.94975L10.5356 9.36396L8.00079 6.828L8.00004 20H6.00004L6.00079 6.828L3.46451 9.36396L2.05029 7.94975L7.00004 3L11.9498 7.94975ZM21.9498 16.0503L17 21L12.0503 16.0503L13.4645 14.636L16.0008 17.172L16 4H18L18.0008 17.172L20.5356 14.636L21.9498 16.0503Z"})),Wa=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M11.9997 10.5865L16.9495 5.63672L18.3637 7.05093L13.4139 12.0007L18.3637 16.9504L16.9495 18.3646L11.9997 13.4149L7.04996 18.3646L5.63574 16.9504L10.5855 12.0007L5.63574 7.05093L7.04996 5.63672L11.9997 10.5865Z"})),Pp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M10 6V8H5V19H16V14H18V20C18 20.5523 17.5523 21 17 21H4C3.44772 21 3 20.5523 3 20V7C3 6.44772 3.44772 6 4 6H10ZM21 3V11H19L18.9999 6.413L11.2071 14.2071L9.79289 12.7929L17.5849 5H13V3H21Z"})),kp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M12.0003 3C17.3924 3 21.8784 6.87976 22.8189 12C21.8784 17.1202 17.3924 21 12.0003 21C6.60812 21 2.12215 17.1202 1.18164 12C2.12215 6.87976 6.60812 3 12.0003 3ZM12.0003 19C16.2359 19 19.8603 16.052 20.7777 12C19.8603 7.94803 16.2359 5 12.0003 5C7.7646 5 4.14022 7.94803 3.22278 12C4.14022 16.052 7.7646 19 12.0003 19ZM12.0003 16.5C9.51498 16.5 7.50026 14.4853 7.50026 12C7.50026 9.51472 9.51498 7.5 12.0003 7.5C14.4855 7.5 16.5003 9.51472 16.5003 12C16.5003 14.4853 14.4855 16.5 12.0003 16.5ZM12.0003 14.5C13.381 14.5 14.5003 13.3807 14.5003 12C14.5003 10.6193 13.381 9.5 12.0003 9.5C10.6196 9.5 9.50026 10.6193 9.50026 12C9.50026 13.3807 10.6196 14.5 12.0003 14.5Z"})),Mp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M17.8827 19.2968C16.1814 20.3755 14.1638 21.0002 12.0003 21.0002C6.60812 21.0002 2.12215 17.1204 1.18164 12.0002C1.61832 9.62282 2.81932 7.5129 4.52047 5.93457L1.39366 2.80777L2.80788 1.39355L22.6069 21.1925L21.1927 22.6068L17.8827 19.2968ZM5.9356 7.3497C4.60673 8.56015 3.6378 10.1672 3.22278 12.0002C4.14022 16.0521 7.7646 19.0002 12.0003 19.0002C13.5997 19.0002 15.112 18.5798 16.4243 17.8384L14.396 15.8101C13.7023 16.2472 12.8808 16.5002 12.0003 16.5002C9.51498 16.5002 7.50026 14.4854 7.50026 12.0002C7.50026 11.1196 7.75317 10.2981 8.19031 9.60442L5.9356 7.3497ZM12.9139 14.328L9.67246 11.0866C9.5613 11.3696 9.50026 11.6777 9.50026 12.0002C9.50026 13.3809 10.6196 14.5002 12.0003 14.5002C12.3227 14.5002 12.6309 14.4391 12.9139 14.328ZM20.8068 16.5925L19.376 15.1617C20.0319 14.2268 20.5154 13.1586 20.7777 12.0002C19.8603 7.94818 16.2359 5.00016 12.0003 5.00016C11.1544 5.00016 10.3329 5.11773 9.55249 5.33818L7.97446 3.76015C9.22127 3.26959 10.5793 3.00016 12.0003 3.00016C17.3924 3.00016 21.8784 6.87992 22.8189 12.0002C22.5067 13.6998 21.8038 15.2628 20.8068 16.5925ZM11.7229 7.50857C11.8146 7.50299 11.9071 7.50016 12.0003 7.50016C14.4855 7.50016 16.5003 9.51488 16.5003 12.0002C16.5003 12.0933 16.4974 12.1858 16.4919 12.2775L11.7229 7.50857Z"})),Vp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M21 4V6H20L14 15V22H10V15L4 6H3V4H21Z"})),Ep=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M21 4V6H20L15 13.5V22H9V13.5L4 6H3V4H21ZM6.4037 6L11 12.8944V20H13V12.8944L17.5963 6H6.4037Z"})),Dp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M5 22C4.44772 22 4 21.5523 4 21V3C4 2.44772 4.44772 2 5 2H19C19.5523 2 20 2.44772 20 3V6H18V4H6V20H18V18H20V21C20 21.5523 19.5523 22 19 22H5ZM18 16V13H11V11H18V8L23 12L18 16Z"})),qa=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M3 4H21V6H3V4ZM3 11H21V13H3V11ZM3 18H21V20H3V18Z"})),Fp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M20 17H22V19H2V17H4V10C4 5.58172 7.58172 2 12 2C16.4183 2 20 5.58172 20 10V17ZM9 21H15V23H9V21Z"})),Ap=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M20 17H22V19H2V17H4V10C4 5.58172 7.58172 2 12 2C16.4183 2 20 5.58172 20 10V17ZM18 17V10C18 6.68629 15.3137 4 12 4C8.68629 4 6 6.68629 6 10V17H18ZM9 21H15V23H9V21Z"})),Ya=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M18.031 16.6168L22.3137 20.8995L20.8995 22.3137L16.6168 18.031C15.0769 19.263 13.124 20 11 20C6.032 20 2 15.968 2 11C2 6.032 6.032 2 11 2C15.968 2 20 6.032 20 11C20 13.124 19.263 15.0769 18.031 16.6168ZM16.0247 15.8748C17.2475 14.6146 18 12.8956 18 11C18 7.1325 14.8675 4 11 4C7.1325 4 4 7.1325 4 11C4 14.8675 7.1325 18 11 18C12.8956 18 14.6146 17.2475 15.8748 16.0247L16.0247 15.8748Z"})),Ip=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M12 12.5858L16.2426 16.8284L14.8284 18.2426L13 16.415V22H11V16.413L9.17157 18.2426L7.75736 16.8284L12 12.5858ZM12 2C15.5934 2 18.5544 4.70761 18.9541 8.19395C21.2858 8.83154 23 10.9656 23 13.5C23 16.3688 20.8036 18.7246 18.0006 18.9776L18.0009 16.9644C19.6966 16.7214 21 15.2629 21 13.5C21 11.567 19.433 10 17.5 10C17.2912 10 17.0867 10.0183 16.8887 10.054C16.9616 9.7142 17 9.36158 17 9C17 6.23858 14.7614 4 12 4C9.23858 4 7 6.23858 7 9C7 9.36158 7.03838 9.7142 7.11205 10.0533C6.91331 10.0183 6.70879 10 6.5 10C4.567 10 3 11.567 3 13.5C3 15.2003 4.21241 16.6174 5.81986 16.934L6.00005 16.9646L6.00039 18.9776C3.19696 18.7252 1 16.3692 1 13.5C1 10.9656 2.71424 8.83154 5.04648 8.19411C5.44561 4.70761 8.40661 2 12 2Z"})),Lp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M20 22H18V20C18 18.3431 16.6569 17 15 17H9C7.34315 17 6 18.3431 6 20V22H4V20C4 17.2386 6.23858 15 9 15H15C17.7614 15 20 17.2386 20 20V22ZM12 13C8.68629 13 6 10.3137 6 7C6 3.68629 8.68629 1 12 1C15.3137 1 18 3.68629 18 7C18 10.3137 15.3137 13 12 13ZM12 11C14.2091 11 16 9.20914 16 7C16 4.79086 14.2091 3 12 3C9.79086 3 8 4.79086 8 7C8 9.20914 9.79086 11 12 11Z"})),Rp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M22.0003 13.0001L22.0004 11.0002L5.82845 11.0002L9.77817 7.05044L8.36396 5.63623L2 12.0002L8.36396 18.3642L9.77817 16.9499L5.8284 13.0002L22.0003 13.0001Z"})),_p=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M1.99974 13.0001L1.9996 11.0002L18.1715 11.0002L14.2218 7.05044L15.636 5.63623L22 12.0002L15.636 18.3642L14.2218 16.9499L18.1716 13.0002L1.99974 13.0001Z"})),Np=g.div`
664
664
  ${Ze}
665
665
  ${({$size:e})=>Bt[e??"md"]}
666
666
  ${({$hasError:e})=>e&&Je}
667
667
  ${({$disabled:e})=>e&&Oe}
668
668
  position: relative;
669
- `,zp=g.input`
669
+ `,Bp=g.input`
670
670
  ${mn}
671
- `,Op=g.span`
671
+ `,zp=g.span`
672
672
  ${pn}
673
673
  cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
674
- `,Ja=({size:e="md",leftIcon:t,iconSize:n="sm",iconColor:o="currentColor",placeholder:r="Contraseña...",hasError:i=!1,disabled:s=!1,className:a,...l})=>{const[c,d]=m.useState(!1),u=()=>d(h=>!h);return p.jsxs(Np,{$size:e,$hasError:i,$disabled:s,className:a,children:[t&&p.jsx(H,{component:t,size:n,color:s?"var(--color-dark-200)":o}),p.jsx(zp,{type:c?"text":"password",placeholder:r,disabled:s,...l}),p.jsx(Op,{$disabled:s,onClick:s?void 0:u,children:p.jsx(H,{component:c?Vp:kp,size:n,color:s?"var(--color-dark-200)":o})})]})},Qa=e=>{const t=e.findIndex(n=>!n.disabled);return t!==-1?t:0},Hp=e=>{for(let t=e.length-1;t>=0;t--)if(!e[t].disabled)return t;return e.length-1},jp=(e,t,n)=>{let o=e;do o=(o+t+n.length)%n.length;while(n[o]?.disabled&&o!==e);return o},Gp=(e,t)=>({target:{value:String(e),name:t},currentTarget:{value:String(e),name:t}}),Up=(e,t)=>{if(t>=0&&e.current){const n=e.current.children[t];n&&n.scrollIntoView({block:"nearest",behavior:"smooth"})}},Kp=(e,t)=>{if(typeof e=="string"||typeof e=="number"){const n=t.findIndex(o=>o.value===e);if(n!==-1&&!t[n].disabled)return n}return Qa(t)},Wp=({options:e,value:t,name:n,disabled:o=!1,onChange:r,onOptionSelect:i})=>{const s=m.useRef(null),a=m.useRef(null),l=m.useRef(null),c=m.useRef(null),d=m.useRef(!1),u=m.useId(),[h,f]=m.useState(!1),[v,y]=m.useState(-1),b=e.find(x=>x.value===t);m.useEffect(()=>{h&&a.current&&(a.current.focus(),y(Kp(t,e)))},[h,e,t]),m.useEffect(()=>{Up(l,v)},[v]),m.useEffect(()=>{if(!h)return;const x=P=>{s.current&&(s.current.contains(P.target)||f(!1))};return document.addEventListener("mousedown",x),()=>document.removeEventListener("mousedown",x)},[h]),m.useEffect(()=>{h?d.current=!0:d.current&&requestAnimationFrame(()=>{c.current?.focus()})},[h]);const w=x=>{x.disabled||(i?.(x),r&&r(Gp(x.value,n)),f(!1),y(-1))};return{open:h,activeIndex:v,selected:b,containerRef:s,menuRef:a,menuContentRef:l,buttonRef:c,id:u,setOpen:f,setActiveIndex:y,commitSelection:w,handleKeyDownButton:x=>{o||(x.key==="ArrowDown"||x.key==="ArrowUp"?(x.preventDefault(),f(!0)):(x.key==="Enter"||x.key===" ")&&(x.preventDefault(),f(P=>!P)))},handleKeyDownMenu:x=>{if(x.key==="Escape"){x.preventDefault(),f(!1),y(-1);return}if(x.key==="ArrowDown"||x.key==="ArrowUp"){x.preventDefault();const P=x.key==="ArrowDown"?1:-1;y(jp(v,P,e))}else if(x.key==="Enter"){x.preventDefault();const P=e[v];P&&!P.disabled&&w(P)}else x.key==="Home"?(x.preventDefault(),y(Qa(e))):x.key==="End"&&(x.preventDefault(),y(Hp(e)))},handleToggle:()=>{o||f(x=>!x)}}},qp=g.div`
674
+ `,Xa=({size:e="md",leftIcon:t,iconSize:n="sm",iconColor:o="currentColor",placeholder:r="Contraseña...",hasError:i=!1,disabled:s=!1,className:a,...l})=>{const[c,d]=m.useState(!1),u=()=>d(h=>!h);return p.jsxs(Np,{$size:e,$hasError:i,$disabled:s,className:a,children:[t&&p.jsx(U,{component:t,size:n,color:s?"var(--color-dark-200)":o}),p.jsx(Bp,{type:c?"text":"password",placeholder:r,disabled:s,...l}),p.jsx(zp,{$disabled:s,onClick:s?void 0:u,children:p.jsx(U,{component:c?Mp:kp,size:n,color:s?"var(--color-dark-200)":o})})]})},Za=e=>{const t=e.findIndex(n=>!n.disabled);return t!==-1?t:0},Op=e=>{for(let t=e.length-1;t>=0;t--)if(!e[t].disabled)return t;return e.length-1},Hp=(e,t,n)=>{let o=e;do o=(o+t+n.length)%n.length;while(n[o]?.disabled&&o!==e);return o},jp=(e,t)=>({target:{value:String(e),name:t},currentTarget:{value:String(e),name:t}}),Gp=(e,t)=>{if(t>=0&&e.current){const n=e.current.children[t];n&&n.scrollIntoView({block:"nearest",behavior:"smooth"})}},Up=(e,t)=>{if(typeof e=="string"||typeof e=="number"){const n=t.findIndex(o=>o.value===e);if(n!==-1&&!t[n].disabled)return n}return Za(t)},Kp=({options:e,value:t,name:n,disabled:o=!1,onChange:r,onOptionSelect:i})=>{const s=m.useRef(null),a=m.useRef(null),l=m.useRef(null),c=m.useRef(null),d=m.useRef(!1),u=m.useId(),[h,f]=m.useState(!1),[v,y]=m.useState(-1),b=e.find(x=>x.value===t);m.useEffect(()=>{h&&a.current&&(a.current.focus(),y(Up(t,e)))},[h,e,t]),m.useEffect(()=>{Gp(l,v)},[v]),m.useEffect(()=>{if(!h)return;const x=P=>{s.current&&(s.current.contains(P.target)||f(!1))};return document.addEventListener("mousedown",x),()=>document.removeEventListener("mousedown",x)},[h]),m.useEffect(()=>{h?d.current=!0:d.current&&requestAnimationFrame(()=>{c.current?.focus()})},[h]);const w=x=>{x.disabled||(i?.(x),r&&r(jp(x.value,n)),f(!1),y(-1))};return{open:h,activeIndex:v,selected:b,containerRef:s,menuRef:a,menuContentRef:l,buttonRef:c,id:u,setOpen:f,setActiveIndex:y,commitSelection:w,handleKeyDownButton:x=>{o||(x.key==="ArrowDown"||x.key==="ArrowUp"?(x.preventDefault(),f(!0)):(x.key==="Enter"||x.key===" ")&&(x.preventDefault(),f(P=>!P)))},handleKeyDownMenu:x=>{if(x.key==="Escape"){x.preventDefault(),f(!1),y(-1);return}if(x.key==="ArrowDown"||x.key==="ArrowUp"){x.preventDefault();const P=x.key==="ArrowDown"?1:-1;y(Hp(v,P,e))}else if(x.key==="Enter"){x.preventDefault();const P=e[v];P&&!P.disabled&&w(P)}else x.key==="Home"?(x.preventDefault(),y(Za(e))):x.key==="End"&&(x.preventDefault(),y(Op(e)))},handleToggle:()=>{o||f(x=>!x)}}},Wp=g.div`
675
675
  position: relative;
676
676
  width: 100%;
677
- `,Yp=g.div`
677
+ `,qp=g.div`
678
678
  ${pn};
679
679
  position: absolute;
680
680
  right: 1rem;
@@ -682,7 +682,7 @@
682
682
  transform: translateY(-50%) rotate(${({$open:e})=>e?"-180deg":"0deg"});
683
683
  pointer-events: none;
684
684
  transition: transform 0.3s ease-out;
685
- `,Xp=g.button`
685
+ `,Yp=g.button`
686
686
  ${Ze}
687
687
  ${({$size:e})=>Bt[e]}
688
688
  ${({$hasError:e})=>e&&Je}
@@ -704,7 +704,7 @@
704
704
  &:hover {
705
705
  background-color: var(--color-main-alternative-secondary);
706
706
  }
707
- `,Zp=g(Fe.ul)`
707
+ `,Xp=g(Fe.ul)`
708
708
  position: absolute;
709
709
  z-index: 50;
710
710
  left: 0;
@@ -726,11 +726,11 @@
726
726
  border: var(--border-input-focus);
727
727
  outline: none;
728
728
  }
729
- `,Jp=g.div`
729
+ `,Zp=g.div`
730
730
  max-height: 15rem;
731
731
  overflow-y: auto;
732
732
  outline: none;
733
- `,Qp=g.li`
733
+ `,Jp=g.li`
734
734
  display: flex;
735
735
  align-items: center;
736
736
  gap: 0.5rem;
@@ -740,11 +740,11 @@
740
740
  cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
741
741
  user-select: none;
742
742
 
743
- ${({$size:e})=>eg[e??"md"]}
743
+ ${({$size:e})=>Qp[e??"md"]}
744
744
 
745
745
  background-color: ${({$active:e})=>e?"var(--color-main-alternative-secondary)":"transparent"};
746
746
  color: ${({$disabled:e})=>e?"var(--color-dark-200)":"var(--color-main-blue-primary)"};
747
- `,eg={xs:g.css`
747
+ `,Qp={xs:g.css`
748
748
  ${E[14]}
749
749
  `,sm:g.css`
750
750
  ${E[16]}
@@ -752,9 +752,9 @@
752
752
  ${E[18]}
753
753
  `,lg:g.css`
754
754
  ${E[18]}
755
- `},el=m.forwardRef(({size:e,hasError:t,disabled:n,hasValue:o,displayText:r,open:i,inputClassName:s,onClick:a,onKeyDown:l,ariaHaspopup:c,ariaExpanded:d,ariaControls:u,ariaInvalid:h,title:f},v)=>p.jsxs(p.Fragment,{children:[p.jsx(Xp,{type:"button",$size:e,$hasError:t,$hasValue:o,$disabled:n,disabled:n,className:s,ref:v,onClick:a,onKeyDown:l,"aria-haspopup":c,"aria-expanded":d,"aria-controls":u,"aria-invalid":h,title:f,children:r}),p.jsx(Yp,{$size:e,$disabled:n,$open:i,children:p.jsx(H,{component:qa,size:e==="sm"||e==="md"?"sm":"md",color:n?"var(--color-dark-200)":"var(--color-main-blue-primary)"})})]}));el.displayName="SelectTrigger";const tl=({option:e,size:t,active:n,selected:o,id:r,className:i,onMouseEnter:s,onClick:a})=>p.jsx(Qp,{id:r,className:i,role:"option",$size:t,"aria-selected":o,$active:n,$disabled:e.disabled,onMouseEnter:s,onClick:a,children:e.label});tl.displayName="SelectOption";const nl=({open:e,options:t,size:n,activeIndex:o,selectedValue:r,menuRef:i,menuContentRef:s,id:a,optionsClassName:l,optionClassName:c,onKeyDown:d,onOptionClick:u,onOptionMouseEnter:h})=>p.jsx(At,{children:e&&p.jsx(Zp,{ref:i,className:"custom-scrollbar",id:`${a}-listbox`,role:"listbox",tabIndex:0,"aria-activedescendant":o>=0?`${a}-option-${o}`:void 0,initial:{opacity:0,height:0,scaleY:.8},animate:{opacity:1,height:"auto",scaleY:1},exit:{opacity:0,height:0,scaleY:.8},transition:{duration:.25,ease:[.4,0,.2,1]},onKeyDown:d,children:p.jsx(Jp,{ref:s,className:l,children:t.map((f,v)=>{const y=v===o;return p.jsx(tl,{option:f,size:n,active:y,selected:r===f.value,id:`${a}-option-${v}`,className:c,onMouseEnter:()=>{!f.disabled&&e&&h(v)},onClick:()=>u(f)},f.value)})})})});nl.displayName="SelectMenu";const gn=m.forwardRef(({size:e="md",hasError:t=!1,disabled:n=!1,options:o=[],placeholder:r,onOptionSelect:i,onChange:s,value:a,name:l,className:c,inputClassName:d,optionsClassName:u,optionClassName:h},f)=>{const{open:v,activeIndex:y,selected:b,containerRef:w,menuRef:T,menuContentRef:C,buttonRef:M,id:x,setActiveIndex:P,commitSelection:V,handleKeyDownButton:$,handleKeyDownMenu:F,handleToggle:D}=Wp({options:o,value:a,name:l,disabled:n,onChange:s,onOptionSelect:i}),_=N=>{M.current=N,typeof f=="function"?f(N):f&&"current"in f&&(f.current=N)};return p.jsxs(qp,{ref:w,className:c,children:[l&&p.jsx("input",{type:"hidden",name:l,value:b?.value??""}),p.jsx(el,{ref:_,size:e,hasError:t,disabled:n,hasValue:!!b,displayText:b?.label??r??"",open:v,inputClassName:d,onClick:D,onKeyDown:$,ariaHaspopup:"listbox",ariaExpanded:v,ariaControls:`${x}-listbox`,ariaInvalid:t||void 0,title:b?.label??r??"Select an option"}),p.jsx(nl,{open:v,options:o,size:e,activeIndex:y,selectedValue:a,menuRef:T,menuContentRef:C,id:x,optionsClassName:u,optionClassName:h,onKeyDown:F,onOptionClick:V,onOptionMouseEnter:P})]})});gn.displayName="SelectInput";const tg=g.textarea`
755
+ `},Ja=m.forwardRef(({size:e,hasError:t,disabled:n,hasValue:o,displayText:r,open:i,inputClassName:s,onClick:a,onKeyDown:l,ariaHaspopup:c,ariaExpanded:d,ariaControls:u,ariaInvalid:h,title:f},v)=>p.jsxs(p.Fragment,{children:[p.jsx(Yp,{type:"button",$size:e,$hasError:t,$hasValue:o,$disabled:n,disabled:n,className:s,ref:v,onClick:a,onKeyDown:l,"aria-haspopup":c,"aria-expanded":d,"aria-controls":u,"aria-invalid":h,title:f,children:r}),p.jsx(qp,{$size:e,$disabled:n,$open:i,children:p.jsx(U,{component:Ka,size:e==="sm"||e==="md"?"sm":"md",color:n?"var(--color-dark-200)":"var(--color-main-blue-primary)"})})]}));Ja.displayName="SelectTrigger";const Qa=({option:e,size:t,active:n,selected:o,id:r,className:i,onMouseEnter:s,onClick:a})=>p.jsx(Jp,{id:r,className:i,role:"option",$size:t,"aria-selected":o,$active:n,$disabled:e.disabled,onMouseEnter:s,onClick:a,children:e.label});Qa.displayName="SelectOption";const el=({open:e,options:t,size:n,activeIndex:o,selectedValue:r,menuRef:i,menuContentRef:s,id:a,optionsClassName:l,optionClassName:c,onKeyDown:d,onOptionClick:u,onOptionMouseEnter:h})=>p.jsx(It,{children:e&&p.jsx(Xp,{ref:i,className:"custom-scrollbar",id:`${a}-listbox`,role:"listbox",tabIndex:0,"aria-activedescendant":o>=0?`${a}-option-${o}`:void 0,initial:{opacity:0,height:0,scaleY:.8},animate:{opacity:1,height:"auto",scaleY:1},exit:{opacity:0,height:0,scaleY:.8},transition:{duration:.25,ease:[.4,0,.2,1]},onKeyDown:d,children:p.jsx(Zp,{ref:s,className:l,children:t.map((f,v)=>{const y=v===o;let b=f.className??(typeof c=="string"?c:void 0);if(typeof c=="function")try{const w=c(f);w&&(b=w)}catch{}return p.jsx(Qa,{option:f,size:n,active:y,selected:r===f.value,id:`${a}-option-${v}`,className:b,onMouseEnter:()=>{!f.disabled&&e&&h(v)},onClick:()=>u(f)},f.value)})})})});el.displayName="SelectMenu";const gn=m.forwardRef(({size:e="md",hasError:t=!1,disabled:n=!1,options:o=[],placeholder:r,onOptionSelect:i,onChange:s,value:a,name:l,className:c,inputClassName:d,optionsClassName:u,optionClassName:h},f)=>{const{open:v,activeIndex:y,selected:b,containerRef:w,menuRef:T,menuContentRef:C,buttonRef:k,id:x,setActiveIndex:P,commitSelection:V,handleKeyDownButton:$,handleKeyDownMenu:D,handleToggle:F}=Kp({options:o,value:a,name:l,disabled:n,onChange:s,onOptionSelect:i}),_=B=>{k.current=B,typeof f=="function"?f(B):f&&"current"in f&&(f.current=B)};return p.jsxs(Wp,{ref:w,className:c,children:[l&&p.jsx("input",{type:"hidden",name:l,value:b?.value??""}),p.jsx(Ja,{ref:_,size:e,hasError:t,disabled:n,hasValue:!!b,displayText:b?.label??r??"",open:v,inputClassName:d,onClick:F,onKeyDown:$,ariaHaspopup:"listbox",ariaExpanded:v,ariaControls:`${x}-listbox`,ariaInvalid:t||void 0,title:b?.label??r??"Select an option"}),p.jsx(el,{open:v,options:o,size:e,activeIndex:y,selectedValue:a,menuRef:T,menuContentRef:C,id:x,optionsClassName:u,optionClassName:h,onKeyDown:D,onOptionClick:V,onOptionMouseEnter:P})]})});gn.displayName="SelectInput";const eg=g.textarea`
756
756
  ${Ze}
757
- ${({$size:e})=>ng[e]}
757
+ ${({$size:e})=>tg[e]}
758
758
  ${({$hasError:e})=>e&&Je}
759
759
  ${({$disabled:e})=>e&&Oe}
760
760
  ${E[20]}
@@ -770,7 +770,7 @@
770
770
  color: var(--color-dark-200);
771
771
  opacity: 1;
772
772
  }
773
- `,ng={xs:`
773
+ `,tg={xs:`
774
774
  ${E[16]}
775
775
  height: 4rem;
776
776
  max-height: 8rem;
@@ -790,19 +790,19 @@
790
790
  height:12rem;
791
791
  max-height: 20rem;
792
792
  padding: 1rem 1.25rem;
793
- `},Xo=m.forwardRef(({size:e="md",hasError:t=!1,disabled:n=!1,resize:o="vertical",autoResize:r=!1,minRows:i=3,maxRows:s,className:a,onChange:l,...c},d)=>{const u=h=>{if(r){const f=h.target;f.style.height="auto";const v=f.scrollHeight,y=i*24,b=s?s*24:v;v>b?(f.style.height=`${b}px`,f.style.overflowY="scroll"):(f.style.height=`${Math.max(v,y)}px`,f.style.overflowY="hidden")}l?.(h)};return p.jsx(tg,{ref:d,$size:e,$hasError:t,$disabled:n,$resize:o,$autoResize:r,disabled:n,rows:i,className:a,onChange:u,...c})});Xo.displayName="TextAreaInput";const og=g.div`
793
+ `},Zo=m.forwardRef(({size:e="md",hasError:t=!1,disabled:n=!1,resize:o="vertical",autoResize:r=!1,minRows:i=3,maxRows:s,className:a,onChange:l,...c},d)=>{const u=h=>{if(r){const f=h.target;f.style.height="auto";const v=f.scrollHeight,y=i*24,b=s?s*24:v;v>b?(f.style.height=`${b}px`,f.style.overflowY="scroll"):(f.style.height=`${Math.max(v,y)}px`,f.style.overflowY="hidden")}l?.(h)};return p.jsx(eg,{ref:d,$size:e,$hasError:t,$disabled:n,$resize:o,$autoResize:r,disabled:n,rows:i,className:a,onChange:u,...c})});Zo.displayName="TextAreaInput";const ng=g.div`
794
794
  ${Ze}
795
795
  ${({$size:e})=>Bt[e??"md"]}
796
- `,rg=g.input`
796
+ `,og=g.input`
797
797
  ${mn}
798
- `,Zo=({size:e="md",leftIcon:t,rightIcon:n=Za,iconSize:o="sm",iconColor:r="currentColor",placeholder:i="Buscar...",onSearch:s,className:a,...l})=>{const c=d=>{s?.(d.target.value)};return p.jsxs(og,{$size:e,className:a,children:[t&&p.jsx(H,{component:t,size:o,color:r}),p.jsx(rg,{placeholder:i,onChange:c,...l}),n?p.jsx(H,{component:n,size:o,color:r}):p.jsx(H,{component:Za,size:o,color:r})]})},ig={default:g.css`
798
+ `,Jo=({size:e="md",leftIcon:t,rightIcon:n=Ya,iconSize:o="sm",iconColor:r="currentColor",placeholder:i="Buscar...",onSearch:s,className:a,...l})=>{const c=d=>{s?.(d.target.value)};return p.jsxs(ng,{$size:e,className:a,children:[t&&p.jsx(U,{component:t,size:o,color:r}),p.jsx(og,{placeholder:i,onChange:c,...l}),n?p.jsx(U,{component:n,size:o,color:r}):p.jsx(U,{component:Ya,size:o,color:r})]})},rg={default:g.css`
799
799
  min-height: 18rem;
800
800
  padding: 2rem;
801
801
  `,compact:g.css`
802
802
  min-height: 6rem;
803
803
  padding: 1rem;
804
804
  flex-direction: row;
805
- `},sg={xs:g.css`
805
+ `},ig={xs:g.css`
806
806
  ${E[12]}
807
807
  `,sm:g.css`
808
808
  ${E[12]}
@@ -810,28 +810,28 @@
810
810
  ${E[16]}
811
811
  `,lg:g.css`
812
812
  ${E[20]}
813
- `},ag=g.css`
813
+ `},sg=g.css`
814
814
  border: 2px dashed var(--color-main-input-borders);
815
815
  background-color: var(--color-main-white);
816
- `,lg=g.css`
816
+ `,ag=g.css`
817
817
  border-color: var(--color-main-blue-primary);
818
818
  background-color: var(--color-main-alternative-secondary);
819
- `,cg=g.css`
819
+ `,lg=g.css`
820
820
  border: 2px dashed var(--color-main-positive-state);
821
821
  background-color: var(--color-green-100);
822
- `,ug=g.css`
822
+ `,cg=g.css`
823
823
  border-color: var(--color-main-warning-state);
824
824
  background-color: var(--color-red-100);
825
- `,dg=g.css`
825
+ `,ug=g.css`
826
826
  border-color: var(--color-dark-200);
827
827
  cursor: not-allowed;
828
828
  opacity: 0.6;
829
- `,fg=g.div`
829
+ `,dg=g.div`
830
830
  display: flex;
831
831
  flex-direction: column;
832
832
  width: 100%;
833
- ${({$size:e})=>sg[e]}
834
- `,hg=g.div`
833
+ ${({$size:e})=>ig[e]}
834
+ `,fg=g.div`
835
835
  display: flex;
836
836
  flex-direction: column;
837
837
  align-items: center;
@@ -847,35 +847,35 @@
847
847
  outline: 2px solid transparent;
848
848
  outline-offset: 2px;
849
849
 
850
- ${({$variant:e})=>ig[e]}
851
- ${ag}
850
+ ${({$variant:e})=>rg[e]}
851
+ ${sg}
852
852
 
853
- ${({$disabled:e})=>e?dg:g.css`
853
+ ${({$disabled:e})=>e?ug:g.css`
854
854
  &:hover {
855
- ${lg}
855
+ ${ag}
856
856
  }
857
857
  `}
858
858
 
859
- ${({$isDragging:e,$disabled:t})=>e&&!t&&cg}
860
- ${({$hasError:e,$disabled:t})=>e&&!t&&ug}
859
+ ${({$isDragging:e,$disabled:t})=>e&&!t&&lg}
860
+ ${({$hasError:e,$disabled:t})=>e&&!t&&cg}
861
861
 
862
862
  &:focus-visible {
863
863
  outline-color: var(--color-main-blue-primary);
864
864
  outline-offset: 2px;
865
865
  }
866
- `,mg=g.div`
866
+ `,hg=g.div`
867
867
  color: ${({$disabled:e})=>e?"var(--color-dark-200)":"var(--color-main-blue-primary)"};
868
868
 
869
869
  strong {
870
870
  color: ${({$disabled:e})=>e?"var(--color-dark-200)":"var(--color-main-blue-primary)"};
871
871
  font-weight: 700;
872
872
  }
873
- `,pg=g.div`
873
+ `,mg=g.div`
874
874
  display: flex;
875
875
  flex-direction: column;
876
876
  gap: 0.5rem;
877
877
  margin-top: 1rem;
878
- `,gg=g.div`
878
+ `,pg=g.div`
879
879
  display: flex;
880
880
  align-items: center;
881
881
  justify-content: space-between;
@@ -892,12 +892,12 @@
892
892
  &:hover {
893
893
  background-color: var(--color-main-alternative-secondary);
894
894
  }
895
- `,vg=g(Ve)`
895
+ `,gg=g(Ve)`
896
896
  font-weight: 500;
897
897
  overflow: hidden;
898
898
  text-overflow: ellipsis;
899
899
  white-space: nowrap;
900
- `,yg=g.button`
900
+ `,vg=g.button`
901
901
  background: none;
902
902
  border: none;
903
903
  color: var(--color-dark-400);
@@ -924,12 +924,12 @@
924
924
  cursor: not-allowed;
925
925
  opacity: 0.5;
926
926
  }
927
- `,wg=(e,t)=>{const[n,o]=m.useState(!1),r=m.useCallback(l=>{l.preventDefault(),l.stopPropagation(),t||o(!0)},[t]),i=m.useCallback(l=>{l.preventDefault(),l.stopPropagation(),t||o(!1)},[t]),s=m.useCallback(l=>{l.preventDefault(),l.stopPropagation()},[]),a=m.useCallback(l=>{l.preventDefault(),l.stopPropagation(),t||(o(!1),e(l.dataTransfer.files))},[t,e]);return m.useEffect(()=>()=>{n&&o(!1)},[n]),{isDragging:n,dragHandlers:{onDragEnter:r,onDragLeave:i,onDragOver:s,onDrop:a}}},bg=({maxFileSize:e,accept:t,multiple:n,onError:o})=>{const[r,i]=m.useState(""),s=m.useCallback(l=>{i(l),o?.(l)},[o]),a=m.useCallback(l=>{if(e&&l.some(c=>c.size>e)){const c=e/1048576,d=c>=1?`File size exceeds maximum of ${c.toFixed(1)}MB`:`File size exceeds maximum of ${Math.round(e/1024)}KB`;return s(d),!1}if(t){const c=t.split(",").map(u=>u.trim().toLowerCase());if(l.find(u=>{const h=u.type.toLowerCase(),f=`.${u.name.split(".").pop()?.toLowerCase()}`;return!c.some(v=>{if(v===h||v===f)return!0;if(v.endsWith("/*")){const y=v.slice(0,-2);return h.startsWith(`${y}/`)}return!1})})){const u=`File type not accepted. Allowed: ${t}`;return s(u),!1}}return!n&&l.length>1?(s("Only one file is allowed"),!1):(i(""),!0)},[e,t,n,s]);return{error:r,validateFiles:a,clearError:()=>i("")}},xg=e=>{const t=["Bytes","KB","MB"],n=Math.floor(Math.log(e)/Math.log(1024));return`${(e/Math.pow(1024,n)).toFixed(2)} ${t[n]}`},ol=({files:e,onRemove:t,disabled:n})=>e.length===0?null:p.jsx(pg,{children:e.map((o,r)=>p.jsxs(gg,{children:[p.jsxs("div",{className:"flex min-w-[0] flex-col gap-1",children:[p.jsx(vg,{size:14,children:o.name}),p.jsx(_t,{size:12,children:xg(o.size)})]}),p.jsx(yg,{type:"button",onClick:()=>t(r),"aria-label":`Remove ${o.name}`,disabled:n,children:p.jsx(Ya,{})})]},`${o.name}-${r}`))}),Sg=({variant:e="default",multiple:t=!1,maxFileSize:n=10,accept:o="image/*,application/pdf",helperText:r="Upload files here",value:i,defaultValue:s,onChange:a,onError:l,onFileRemove:c,disabled:d=!1,hasError:u=!1,errorMessage:h="",className:f="",dropZoneContainerClassName:v="",size:y="md"})=>{const b=i!==void 0,[w,T]=m.useState(s||[]),C=b?i:w,M=n*1024*1024,{error:x,validateFiles:P,clearError:V}=bg({maxFileSize:M,accept:o,multiple:t,onError:l}),$=(j,K)=>{if(!j||j.length===0)return;const R=Array.from(j);if(!P(R))return;const L=t?[...C,...R]:R;b||T(L),a?.(L,K)},F=j=>{const K=C[j],R=C.filter((L,G)=>G!==j);b||T(R),c?.(K,j),a?.(R),R.length===0&&V()},{isDragging:D,dragHandlers:_}=wg($,d),N=u||!!x,O=h||x;return p.jsxs(fg,{$size:y,className:f,children:[p.jsxs("label",{"aria-label":"File upload area",className:`p-4 ${v}`,children:[p.jsxs(hg,{$variant:e,$isDragging:D,$hasError:N,$disabled:d,role:"button",tabIndex:d?-1:0,"aria-disabled":d,onKeyDown:j=>{(j.key==="Enter"||j.key===" ")&&(j.preventDefault(),j.currentTarget.querySelector("input")?.click())},..._,children:[p.jsx(H,{component:Lp,size:"lg",color:d?"var(--color-dark-200)":"var(--color-main-blue-primary)",className:"!text-[5rem]"}),p.jsxs(mg,{$disabled:d,children:[p.jsx("strong",{children:"Click to upload"})," or drag and drop"]}),r&&!N&&p.jsx(Ve,{size:14,color:"var(--color-main-grey)",children:r})]}),p.jsx("input",{type:"file",multiple:t,accept:o,disabled:d,onChange:j=>$(j.target.files,j.nativeEvent),style:{display:"none"},"aria-label":"File input"})]}),N&&O&&p.jsx(qo,{size:"sm",children:O}),p.jsx(ol,{files:C,onRemove:F,disabled:d})]})},ft={xs:"1rem",sm:"1.25rem",md:"1.5rem",lg:"1.75rem"},Cg=g.div`
927
+ `,yg=(e,t)=>{const[n,o]=m.useState(!1),r=m.useCallback(l=>{l.preventDefault(),l.stopPropagation(),t||o(!0)},[t]),i=m.useCallback(l=>{l.preventDefault(),l.stopPropagation(),t||o(!1)},[t]),s=m.useCallback(l=>{l.preventDefault(),l.stopPropagation()},[]),a=m.useCallback(l=>{l.preventDefault(),l.stopPropagation(),t||(o(!1),e(l.dataTransfer.files))},[t,e]);return m.useEffect(()=>()=>{n&&o(!1)},[n]),{isDragging:n,dragHandlers:{onDragEnter:r,onDragLeave:i,onDragOver:s,onDrop:a}}},wg=({maxFileSize:e,accept:t,multiple:n,onError:o})=>{const[r,i]=m.useState(""),s=m.useCallback(l=>{i(l),o?.(l)},[o]),a=m.useCallback(l=>{if(e&&l.some(c=>c.size>e)){const c=e/1048576,d=c>=1?`File size exceeds maximum of ${c.toFixed(1)}MB`:`File size exceeds maximum of ${Math.round(e/1024)}KB`;return s(d),!1}if(t){const c=t.split(",").map(u=>u.trim().toLowerCase());if(l.find(u=>{const h=u.type.toLowerCase(),f=`.${u.name.split(".").pop()?.toLowerCase()}`;return!c.some(v=>{if(v===h||v===f)return!0;if(v.endsWith("/*")){const y=v.slice(0,-2);return h.startsWith(`${y}/`)}return!1})})){const u=`File type not accepted. Allowed: ${t}`;return s(u),!1}}return!n&&l.length>1?(s("Only one file is allowed"),!1):(i(""),!0)},[e,t,n,s]);return{error:r,validateFiles:a,clearError:()=>i("")}},bg=e=>{const t=["Bytes","KB","MB"],n=Math.floor(Math.log(e)/Math.log(1024));return`${(e/Math.pow(1024,n)).toFixed(2)} ${t[n]}`},tl=({files:e,onRemove:t,disabled:n})=>e.length===0?null:p.jsx(mg,{children:e.map((o,r)=>p.jsxs(pg,{children:[p.jsxs("div",{className:"flex min-w-[0] flex-col gap-1",children:[p.jsx(gg,{size:14,children:o.name}),p.jsx(Nt,{size:12,children:bg(o.size)})]}),p.jsx(vg,{type:"button",onClick:()=>t(r),"aria-label":`Remove ${o.name}`,disabled:n,children:p.jsx(Wa,{})})]},`${o.name}-${r}`))}),xg=({variant:e="default",multiple:t=!1,maxFileSize:n=10,accept:o="image/*,application/pdf",helperText:r="Upload files here",value:i,defaultValue:s,onChange:a,onError:l,onFileRemove:c,disabled:d=!1,hasError:u=!1,errorMessage:h="",className:f="",dropZoneContainerClassName:v="",size:y="md"})=>{const b=i!==void 0,[w,T]=m.useState(s||[]),C=b?i:w,k=n*1024*1024,{error:x,validateFiles:P,clearError:V}=wg({maxFileSize:k,accept:o,multiple:t,onError:l}),$=(z,G)=>{if(!z||z.length===0)return;const R=Array.from(z);if(!P(R))return;const L=t?[...C,...R]:R;b||T(L),a?.(L,G)},D=z=>{const G=C[z],R=C.filter((L,j)=>j!==z);b||T(R),c?.(G,z),a?.(R),R.length===0&&V()},{isDragging:F,dragHandlers:_}=yg($,d),B=u||!!x,H=h||x;return p.jsxs(dg,{$size:y,className:f,children:[p.jsxs("label",{"aria-label":"File upload area",className:`p-4 ${v}`,children:[p.jsxs(fg,{$variant:e,$isDragging:F,$hasError:B,$disabled:d,role:"button",tabIndex:d?-1:0,"aria-disabled":d,onKeyDown:z=>{(z.key==="Enter"||z.key===" ")&&(z.preventDefault(),z.currentTarget.querySelector("input")?.click())},..._,children:[p.jsx(U,{component:Ip,size:"lg",color:d?"var(--color-dark-200)":"var(--color-main-blue-primary)",className:"!text-[5rem]"}),p.jsxs(hg,{$disabled:d,children:[p.jsx("strong",{children:"Click to upload"})," or drag and drop"]}),r&&!B&&p.jsx(Ve,{size:14,color:"var(--color-main-grey)",children:r})]}),p.jsx("input",{type:"file",multiple:t,accept:o,disabled:d,onChange:z=>$(z.target.files,z.nativeEvent),style:{display:"none"},"aria-label":"File input"})]}),B&&H&&p.jsx(Yo,{size:"sm",children:H}),p.jsx(tl,{files:C,onRemove:D,disabled:d})]})},ht={xs:"1rem",sm:"1.25rem",md:"1.5rem",lg:"1.75rem"},Sg=g.div`
928
928
  position: relative;
929
- `,Tg=g.input`
929
+ `,Cg=g.input`
930
930
  position: absolute;
931
- height: ${({$size:e})=>ft[e]};
932
- width: ${({$size:e})=>ft[e]};
931
+ height: ${({$size:e})=>ht[e]};
932
+ width: ${({$size:e})=>ht[e]};
933
933
  inset: 0;
934
934
  cursor: pointer;
935
935
  opacity: 0;
@@ -943,9 +943,9 @@
943
943
  outline-color: var(--color-main-orange-primary);
944
944
  outline-offset: 2px;
945
945
  }
946
- `,$g=g.div`
947
- height: ${({$size:e})=>ft[e]};
948
- width: ${({$size:e})=>ft[e]};
946
+ `,Tg=g.div`
947
+ height: ${({$size:e})=>ht[e]};
948
+ width: ${({$size:e})=>ht[e]};
949
949
  border: 2px solid;
950
950
  border-radius: 0.25rem;
951
951
  display: flex;
@@ -964,13 +964,13 @@
964
964
 
965
965
  ${({$hasError:e})=>e&&Je}
966
966
  ${({$disabled:e})=>e&&Oe}
967
- ${({$checked:e})=>e&&Pg}
968
- `,Pg=g.css`
967
+ ${({$checked:e})=>e&&$g}
968
+ `,$g=g.css`
969
969
  background-color: var(--color-main-orange-primary);
970
970
  border-color: var(--color-main-orange-primary);
971
- `,Mg=g.svg`
972
- height: ${({$size:e})=>ft[e]};
973
- width: ${({$size:e})=>ft[e]};
971
+ `,Pg=g.svg`
972
+ height: ${({$size:e})=>ht[e]};
973
+ width: ${({$size:e})=>ht[e]};
974
974
  color: ${({$disabled:e})=>e?"var(--color-dark-200)":"white"};
975
975
  fill: none;
976
976
  stroke: currentColor;
@@ -980,15 +980,15 @@
980
980
  height: ${({$size:e})=>e==="xs"?"1.5px":"2px"};
981
981
  background-color: white;
982
982
  border-radius: 1px;
983
- `,Jo=m.forwardRef(({size:e="md",hasError:t=!1,indeterminate:n=!1,checked:o,disabled:r=!1,onChange:i,className:s,checkboxClassName:a,...l},c)=>{const d=m.useId(),u=l.id??d,h=!!o,f=m.useRef(null),v=m.useCallback(y=>{if(f.current=y,!!c)if(typeof c=="function")try{c(y)}catch{}else c.current=y},[c]);return m.useEffect(()=>{f.current&&(f.current.indeterminate=!!n)},[n]),p.jsxs(Cg,{className:s,children:[p.jsx(Tg,{ref:v,type:"checkbox",checked:h||!1,disabled:r,onChange:i,id:u,name:l.name,"aria-invalid":t||void 0,"aria-disabled":r||void 0,"aria-checked":n?"mixed":h?"true":"false",$size:e,...l}),p.jsxs($g,{$checked:!!h||!!n,$hasError:t,$disabled:r,$size:e,className:a,children:[h&&!n&&p.jsx(Mg,{$disabled:r,$size:e,viewBox:"0 0 24 24",children:p.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:e==="xs"?2.5:3,d:"M5 13l4 4L19 7"})}),n&&p.jsx(kg,{$size:e})]})]})});Jo.displayName="CheckboxInput";const rl=({children:e,size:t="md",disabled:n=!1,htmlFor:o,onLabelClick:r,className:i,onClick:s,...a})=>{const l=c=>{n||(r&&r(),s&&s(c))};return p.jsx(hn,{size:t,disabled:n,htmlFor:o,onClick:l,className:i,...a,children:e})},Vg=g.section`
983
+ `,Qo=m.forwardRef(({size:e="md",hasError:t=!1,indeterminate:n=!1,checked:o,disabled:r=!1,onChange:i,className:s,checkboxClassName:a,...l},c)=>{const d=m.useId(),u=l.id??d,h=!!o,f=m.useRef(null),v=m.useCallback(y=>{if(f.current=y,!!c)if(typeof c=="function")try{c(y)}catch{}else c.current=y},[c]);return m.useEffect(()=>{f.current&&(f.current.indeterminate=!!n)},[n]),p.jsxs(Sg,{className:s,children:[p.jsx(Cg,{ref:v,type:"checkbox",checked:h||!1,disabled:r,onChange:i,id:u,name:l.name,"aria-invalid":t||void 0,"aria-disabled":r||void 0,"aria-checked":n?"mixed":h?"true":"false",$size:e,...l}),p.jsxs(Tg,{$checked:!!h||!!n,$hasError:t,$disabled:r,$size:e,className:a,children:[h&&!n&&p.jsx(Pg,{$disabled:r,$size:e,viewBox:"0 0 24 24",children:p.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:e==="xs"?2.5:3,d:"M5 13l4 4L19 7"})}),n&&p.jsx(kg,{$size:e})]})]})});Qo.displayName="CheckboxInput";const nl=({children:e,size:t="md",disabled:n=!1,htmlFor:o,onLabelClick:r,className:i,onClick:s,...a})=>{const l=c=>{n||(r&&r(),s&&s(c))};return p.jsx(hn,{size:t,disabled:n,htmlFor:o,onClick:l,className:i,...a,children:e})},Mg=g.section`
984
984
  display: flex;
985
985
  align-items: center;
986
986
  justify-content: center;
987
987
  gap: 1rem;
988
- `,Nt=m.forwardRef(({size:e="md",label:t,hasError:n=!1,indeterminate:o=!1,checked:r,disabled:i=!1,onChange:s,onLabelClick:a,className:l,checkboxClassName:c,labelClassName:d,...u},h)=>{const f=m.useId(),v=u.id??f;return p.jsxs(Vg,{className:l,children:[p.jsx(Jo,{ref:h,size:e,hasError:n,indeterminate:o,checked:r,disabled:i,onChange:s,checkboxClassName:c,id:v,...u}),t&&p.jsx(rl,{size:e,disabled:i,htmlFor:v,onLabelClick:a,className:d,children:t})]})});Nt.displayName="Checkbox";const Eg=g.div`
988
+ `,zt=m.forwardRef(({size:e="md",label:t,hasError:n=!1,indeterminate:o=!1,checked:r,disabled:i=!1,onChange:s,onLabelClick:a,className:l,checkboxClassName:c,labelClassName:d,...u},h)=>{const f=m.useId(),v=u.id??f;return p.jsxs(Mg,{className:l,children:[p.jsx(Qo,{ref:h,size:e,hasError:n,indeterminate:o,checked:r,disabled:i,onChange:s,checkboxClassName:c,id:v,...u}),t&&p.jsx(nl,{size:e,disabled:i,htmlFor:v,onLabelClick:a,className:d,children:t})]})});zt.displayName="Checkbox";const Vg=g.div`
989
989
  position: relative;
990
990
  display: inline-block;
991
- `,Dg=g.input`
991
+ `,Eg=g.input`
992
992
  ${Ze}
993
993
  text-align: center;
994
994
  padding: 0;
@@ -1002,15 +1002,15 @@
1002
1002
  &[type='number'] {
1003
1003
  -moz-appearance: textfield;
1004
1004
  }
1005
- ${({$size:e})=>Ag[e]}
1006
- ${({$variant:e})=>e&&Fg[e??"outlined"]}
1005
+ ${({$size:e})=>Fg[e]}
1006
+ ${({$variant:e})=>e&&Dg[e??"outlined"]}
1007
1007
  ${({$hasError:e})=>e&&Je}
1008
1008
  ${({$disabled:e})=>e&&Oe}
1009
1009
 
1010
1010
  &:focus {
1011
1011
  border: 2px solid var(--color-main-blue-primary);
1012
1012
  }
1013
- `,Fg={outlined:`
1013
+ `,Dg={outlined:`
1014
1014
  background-color: var(--color-main-white);
1015
1015
  border: 2px solid var(--color-main-input-borders);
1016
1016
 
@@ -1029,7 +1029,7 @@
1029
1029
  background-color: var(--color-main-white);
1030
1030
  border: 2px solid var(--color-main-blue-primary);
1031
1031
  }
1032
- `},Ag={xs:`
1032
+ `},Fg={xs:`
1033
1033
  padding: 0.25rem;
1034
1034
  width: 2rem;
1035
1035
  height: 2rem;
@@ -1049,13 +1049,13 @@
1049
1049
  width: 3.5rem;
1050
1050
  height: 4rem;
1051
1051
  ${E[40]}
1052
- `},Qo=m.forwardRef(({size:e="md",hasError:t=!1,variant:n="outlined",disabled:o=!1,className:r,maxLength:i=1,type:s="text",...a},l)=>{const c=m.useId(),d=a.id??c;return p.jsx(Eg,{children:p.jsx(Dg,{ref:l,$size:e,$hasError:t,$disabled:o,$variant:n,className:r,maxLength:i,type:s,disabled:o,id:d,"aria-invalid":t||void 0,"aria-disabled":o||void 0,...a})})});Qo.displayName="PinInput";const il=(e,t,n,o,r,i,s="text",a,l)=>{const c=e.target.value;if(c.length>1)return;const d=i??r.length;if(s==="number"&&c&&!/^\d$/.test(c))return;const u=[...n];u[t]=c,o(u);const h=u.join("");a?.(h),c&&t<i-1&&r[t+1].current?.focus(),u.every(f=>f!=="")&&u.length>=d&&l?.(h)},sl=(e,t,n,o,r,i)=>{if(e.key==="Backspace"&&!n[t]&&t>0){if(n[t]){if(r){o[t-1].current?.focus();const s=[...n];s[t-1]="",r(s),i?.(s.join(""))}return}if(t>0&&(o[t-1].current?.focus(),r)){const s=[...n];s[t-1]="",r(s),i?.(s.join(""))}}e.key==="ArrowLeft"&&t>0&&o[t-1]?.current?.focus(),e.key==="ArrowRight"&&t<o.length-1&&o[t+1]?.current?.focus()},al=(e,t,n,o,r,i,s="text",a,l)=>{e.preventDefault();const c=e.clipboardData.getData("text");if(!c)return;const d=i??r.length,u=[...n];for(let y=0;y<c.length;y++){const b=t+y;if(b>=d)break;const w=c[y];s==="number"&&!/^\d$/.test(w)||(u[b]=w)}o(u),a?.(u.join(""));const h=u.findIndex(y=>y===""),f=h!==-1?Math.min(Math.max(h,t),d-1):d-1;r[f].current?.focus();const v=u.join("");u.every(y=>y!=="")&&u.length>=d&&l?.(v)},ll=e=>Array(e).fill(null).map(()=>m.createRef()),Ig=(e,t,n="text")=>!(e.length!==t||n==="number"&&!/^\d+$/.test(e)),Lg=g.div`
1052
+ `},er=m.forwardRef(({size:e="md",hasError:t=!1,variant:n="outlined",disabled:o=!1,className:r,maxLength:i=1,type:s="text",...a},l)=>{const c=m.useId(),d=a.id??c;return p.jsx(Vg,{children:p.jsx(Eg,{ref:l,$size:e,$hasError:t,$disabled:o,$variant:n,className:r,maxLength:i,type:s,disabled:o,id:d,"aria-invalid":t||void 0,"aria-disabled":o||void 0,...a})})});er.displayName="PinInput";const ol=(e,t,n,o,r,i,s="text",a,l)=>{const c=e.target.value;if(c.length>1)return;const d=i??r.length;if(s==="number"&&c&&!/^\d$/.test(c))return;const u=[...n];u[t]=c,o(u);const h=u.join("");a?.(h),c&&t<i-1&&r[t+1].current?.focus(),u.every(f=>f!=="")&&u.length>=d&&l?.(h)},rl=(e,t,n,o,r,i)=>{if(e.key==="Backspace"&&!n[t]&&t>0){if(n[t]){if(r){o[t-1].current?.focus();const s=[...n];s[t-1]="",r(s),i?.(s.join(""))}return}if(t>0&&(o[t-1].current?.focus(),r)){const s=[...n];s[t-1]="",r(s),i?.(s.join(""))}}e.key==="ArrowLeft"&&t>0&&o[t-1]?.current?.focus(),e.key==="ArrowRight"&&t<o.length-1&&o[t+1]?.current?.focus()},il=(e,t,n,o,r,i,s="text",a,l)=>{e.preventDefault();const c=e.clipboardData.getData("text");if(!c)return;const d=i??r.length,u=[...n];for(let y=0;y<c.length;y++){const b=t+y;if(b>=d)break;const w=c[y];s==="number"&&!/^\d$/.test(w)||(u[b]=w)}o(u),a?.(u.join(""));const h=u.findIndex(y=>y===""),f=h!==-1?Math.min(Math.max(h,t),d-1):d-1;r[f].current?.focus();const v=u.join("");u.every(y=>y!=="")&&u.length>=d&&l?.(v)},sl=e=>Array(e).fill(null).map(()=>m.createRef()),Ag=(e,t,n="text")=>!(e.length!==t||n==="number"&&!/^\d+$/.test(e)),Ig=g.div`
1053
1053
  display: flex;
1054
1054
  gap: 8px;
1055
1055
  align-items: center;
1056
- `,er=({length:e=6,size:t="md",variant:n="outlined",hasError:o=!1,type:r="number",onChange:i,onComplete:s,className:a,pinInputClassName:l})=>{const[c,d]=m.useState(Array(e).fill("")),u=m.useMemo(()=>ll(e),[e]);return p.jsx(Lg,{className:a,children:Array.from({length:e},(h,f)=>p.jsx(Qo,{className:l,size:t,variant:n,hasError:o,value:c[f],onChange:v=>il(v,f,c,d,u,e,r,i,s),onKeyDown:v=>sl(v,f,c,u,d,i),onPaste:v=>al(v,f,c,d,u,e,r,i,s),ref:u[f]},f))})};er.displayName="PinInputGroup";const Rg=g.div`
1056
+ `,tr=({length:e=6,size:t="md",variant:n="outlined",hasError:o=!1,type:r="number",onChange:i,onComplete:s,className:a,pinInputClassName:l})=>{const[c,d]=m.useState(Array(e).fill("")),u=m.useMemo(()=>sl(e),[e]);return p.jsx(Ig,{className:a,children:Array.from({length:e},(h,f)=>p.jsx(er,{className:l,size:t,variant:n,hasError:o,value:c[f],onChange:v=>ol(v,f,c,d,u,e,r,i,s),onKeyDown:v=>rl(v,f,c,u,d,i),onPaste:v=>il(v,f,c,d,u,e,r,i,s),ref:u[f]},f))})};tr.displayName="PinInputGroup";const Lg=g.div`
1057
1057
  position: relative;
1058
- `,_g=g.input`
1058
+ `,Rg=g.input`
1059
1059
  position: absolute;
1060
1060
  height: 1.5rem;
1061
1061
  width: 1.5rem;
@@ -1073,7 +1073,7 @@
1073
1073
  outline-color: var(--color-main-orange-primary);
1074
1074
  outline-offset: 2px;
1075
1075
  }
1076
- `,Bg=g.css`
1076
+ `,_g=g.css`
1077
1077
  border-color: var(--color-main-orange-primary);
1078
1078
  `,Ng=g.div`
1079
1079
  height: 1.5rem;
@@ -1096,8 +1096,8 @@
1096
1096
  ${Oe}
1097
1097
  border: 2px solid var(--color-dark-200) !important;
1098
1098
  `}
1099
- ${({$checked:e})=>e&&Bg}
1100
- `,zg=g.span`
1099
+ ${({$checked:e})=>e&&_g}
1100
+ `,Bg=g.span`
1101
1101
  display: block;
1102
1102
  height: 0.625rem;
1103
1103
  width: 0.625rem;
@@ -1106,21 +1106,21 @@
1106
1106
  background-color: ${({$disabled:e})=>e?"var(--color-dark-200)":"var(--color-main-orange-primary)"};
1107
1107
  opacity: ${({$checked:e})=>e?1:0};
1108
1108
  transform: ${({$checked:e})=>e?"scale(1)":"scale(0.6)"};
1109
- `,tr=m.forwardRef(({hasError:e=!1,checked:t,disabled:n=!1,onChange:o,className:r,dotClassName:i,...s},a)=>{const l=m.useId(),c=s.id??l,d=!!t,{size:u,...h}=s;return p.jsxs(Rg,{className:r,children:[p.jsx(_g,{ref:a,type:"radio",id:c,checked:d||!1,disabled:n,onChange:o,"aria-invalid":e||void 0,"aria-disabled":n||void 0,"aria-checked":d?"true":"false",...h}),p.jsx(Ng,{$checked:!!d,$hasError:e,$disabled:n,className:i,children:p.jsx(zg,{$disabled:n,$checked:d})})]})});tr.displayName="RadioInputDot";const nr=({children:e,htmlFor:t,className:n,disabled:o=!1,size:r="md",...i})=>p.jsx(hn,{className:n,htmlFor:t,size:r,disabled:o,...i,children:e});nr.displayName="RadioInputLabel";const Og=g.section`
1109
+ `,nr=m.forwardRef(({hasError:e=!1,checked:t,disabled:n=!1,onChange:o,className:r,dotClassName:i,...s},a)=>{const l=m.useId(),c=s.id??l,d=!!t,{size:u,...h}=s;return p.jsxs(Lg,{className:r,children:[p.jsx(Rg,{ref:a,type:"radio",id:c,checked:d||!1,disabled:n,onChange:o,"aria-invalid":e||void 0,"aria-disabled":n||void 0,"aria-checked":d?"true":"false",...h}),p.jsx(Ng,{$checked:!!d,$hasError:e,$disabled:n,className:i,children:p.jsx(Bg,{$disabled:n,$checked:d})})]})});nr.displayName="RadioInputDot";const or=({children:e,htmlFor:t,className:n,disabled:o=!1,size:r="md",...i})=>p.jsx(hn,{className:n,htmlFor:t,size:r,disabled:o,...i,children:e});or.displayName="RadioInputLabel";const zg=g.section`
1110
1110
  display: flex;
1111
1111
  align-items: center;
1112
1112
  justify-content: center;
1113
1113
  gap: 1rem;
1114
- `,or=m.forwardRef(({size:e="md",label:t,hasError:n=!1,checked:o,disabled:r=!1,onChange:i,className:s,dotClassName:a,labelClassName:l,...c},d)=>{const u=m.useId(),h=c.id??u;return p.jsxs(Og,{className:s,children:[p.jsx(tr,{ref:d,size:e,hasError:n,checked:o,disabled:r,onChange:i,dotClassName:a,id:h,...c}),t&&p.jsx(nr,{size:e,disabled:r,htmlFor:h,className:l,children:t})]})});or.displayName="RadioInput";const Hg=({name:e,required:t=!1,onChange:n,onOptionSelect:o,onRadioChange:r,onPinComplete:i,options:s=[]})=>{const[a,l,c]=Cc.useField(e),d=m.useMemo(()=>!!(l.error&&(l.touched||l.value)),[l.error,l.touched,l.value]),u=m.useMemo(()=>d?l.error:void 0,[d,l.error]),h=m.useMemo(()=>a.name||e,[a.name,e]),f=m.useMemo(()=>({required:t||void 0,"aria-required":t||void 0,"aria-invalid":d||void 0,"aria-describedby":d?`${h}-error`:void 0}),[t,d,h]),v=m.useCallback(x=>{n?n(x):a.onChange(x)},[n,a]),y=m.useCallback(x=>{n?n(x):a.onChange(x)},[n,a]),b=m.useCallback(x=>{c.setValue(x.target.checked)},[c]),w=m.useCallback(x=>{a.onChange(x);const P=s.find(V=>String(V.value)===x.target.value);P&&o?.(P)},[a,s,o]),T=m.useCallback((x,P)=>{const V=x.target.value,$=typeof P=="number"?Number(V):V;c.setValue($),r?.(x)},[c,r]),C=m.useCallback(x=>{c.setValue(x)},[c]),M=m.useCallback(x=>{c.setValue(x),i?.(x)},[c,i]);return{field:a,meta:l,helpers:c,hasError:d,errorMessage:u,inputId:h,ariaProps:f,handleStandardChange:v,handleTextAreaChange:y,handleCheckboxChange:b,handleSelectChange:w,handleRadioChange:T,handlePinChange:C,handlePinComplete:M}},jg=["text","email","number","tel","url","date","datetime-local","time"],Gg=g.div`
1114
+ `,rr=m.forwardRef(({size:e="md",label:t,hasError:n=!1,checked:o,disabled:r=!1,onChange:i,className:s,dotClassName:a,labelClassName:l,...c},d)=>{const u=m.useId(),h=c.id??u;return p.jsxs(zg,{className:s,children:[p.jsx(nr,{ref:d,size:e,hasError:n,checked:o,disabled:r,onChange:i,dotClassName:a,id:h,...c}),t&&p.jsx(or,{size:e,disabled:r,htmlFor:h,className:l,children:t})]})});rr.displayName="RadioInput";const Og=({name:e,required:t=!1,onChange:n,onOptionSelect:o,onRadioChange:r,onPinComplete:i,options:s=[]})=>{const[a,l,c]=xc.useField(e),d=m.useMemo(()=>!!(l.error&&(l.touched||l.value)),[l.error,l.touched,l.value]),u=m.useMemo(()=>d?l.error:void 0,[d,l.error]),h=m.useMemo(()=>a.name||e,[a.name,e]),f=m.useMemo(()=>({required:t||void 0,"aria-required":t||void 0,"aria-invalid":d||void 0,"aria-describedby":d?`${h}-error`:void 0}),[t,d,h]),v=m.useCallback(x=>{n?n(x):a.onChange(x)},[n,a]),y=m.useCallback(x=>{n?n(x):a.onChange(x)},[n,a]),b=m.useCallback(x=>{c.setValue(x.target.checked)},[c]),w=m.useCallback(x=>{a.onChange(x);const P=s.find(V=>String(V.value)===x.target.value);P&&o?.(P)},[a,s,o]),T=m.useCallback((x,P)=>{const V=x.target.value,$=typeof P=="number"?Number(V):V;c.setValue($),r?.(x)},[c,r]),C=m.useCallback(x=>{c.setValue(x)},[c]),k=m.useCallback(x=>{c.setValue(x),i?.(x)},[c,i]);return{field:a,meta:l,helpers:c,hasError:d,errorMessage:u,inputId:h,ariaProps:f,handleStandardChange:v,handleTextAreaChange:y,handleCheckboxChange:b,handleSelectChange:w,handleRadioChange:T,handlePinChange:C,handlePinComplete:k}},Hg=["text","email","number","tel","url","date","datetime-local","time"],jg=g.div`
1115
1115
  display: flex;
1116
1116
  flex-direction: column;
1117
1117
  gap: 0.75rem;
1118
- `,cl=({type:e,inputId:t,name:n,size:o,hasError:r,disabled:i,placeholder:s,inputClassName:a,fieldValue:l,ariaProps:c,options:d=[],onSelectChange:u,checkboxLabel:h,onCheckboxChange:f,radioName:v,onRadioChange:y,pinLength:b=6,pinType:w="number",onPinChange:T,onPinComplete:C,onStandardChange:M,onTextAreaChange:x,leftIcon:P,rightIcon:V,iconSize:$,iconColor:F,additionalProps:D={}})=>{switch(e){case"textarea":return p.jsx(Xo,{id:t,name:n,className:a,hasError:r,disabled:i,value:l??"",size:o,placeholder:s,onChange:x,...D,...c});case"select":return p.jsx(gn,{id:t,name:n,className:a,hasError:r,disabled:i,size:o,value:l??"",onChange:u,options:d,placeholder:s||"Selecciona una opción",...D,...c});case"checkbox":return p.jsx(Nt,{id:t,name:n,className:a,hasError:r,disabled:i,size:o,checked:!!l,label:h,onChange:f,...D,...c});case"radio":{const _=d;return p.jsx(Gg,{children:_.map(N=>p.jsx(or,{name:v||n,value:N.value,label:N.label,size:o,hasError:r,disabled:i,checked:l===N.value,onChange:O=>y?.(O,N.value),...c},N.value))})}case"pin":return p.jsx(er,{length:b,type:w,size:o,hasError:r,onChange:T,onComplete:C,...D,...c});case"password":{const{..._}=D;return p.jsx(Ja,{id:t,name:n,className:a,hasError:r,disabled:i,size:o,placeholder:s,leftIcon:P,iconSize:$,iconColor:F,onChange:M,..._,...c})}case"search":return p.jsx(Zo,{className:a,size:o,placeholder:s,leftIcon:P,rightIcon:V,iconSize:$,iconColor:F,onSearch:D.onSearch,...c});default:return p.jsx(Yo,{id:t,name:n,className:a,hasError:r,disabled:i,size:o,placeholder:s,type:jg.includes(e)?e:"text",leftIcon:P,rightIcon:V,iconSize:$,iconColor:F,value:l??"",onChange:M,...D,...c})}};cl.displayName="FieldRenderer";const Ug=g.div`
1118
+ `,al=({type:e,inputId:t,name:n,size:o,hasError:r,disabled:i,placeholder:s,inputClassName:a,fieldValue:l,ariaProps:c,options:d=[],onSelectChange:u,optionClassName:h,optionsClassName:f,checkboxLabel:v,onCheckboxChange:y,radioName:b,onRadioChange:w,pinLength:T=6,pinType:C="number",onPinChange:k,onPinComplete:x,onStandardChange:P,onTextAreaChange:V,leftIcon:$,rightIcon:D,iconSize:F,iconColor:_,additionalProps:B={}})=>{switch(e){case"textarea":return p.jsx(Zo,{id:t,name:n,className:a,hasError:r,disabled:i,value:l??"",size:o,placeholder:s,onChange:V,...B,...c});case"select":{const H=B,{optionClassName:z,optionsClassName:G,...R}=H,L=z??h,j=G??f;return p.jsx(gn,{id:t,name:n,className:a,hasError:r,disabled:i,size:o,value:l??"",onChange:u,options:d,placeholder:s||"Select",optionsClassName:j,optionClassName:L,...R,...c})}case"checkbox":return p.jsx(zt,{id:t,name:n,className:a,hasError:r,disabled:i,size:o,checked:!!l,label:v,onChange:y,...B,...c});case"radio":{const H=d;return p.jsx(jg,{children:H.map(z=>p.jsx(rr,{name:b||n,value:z.value,label:z.label,size:o,hasError:r,disabled:i,checked:l===z.value,onChange:G=>w?.(G,z.value),...c},z.value))})}case"pin":return p.jsx(tr,{length:T,type:C,size:o,hasError:r,onChange:k,onComplete:x,...B,...c});case"password":{const{...H}=B;return p.jsx(Xa,{id:t,name:n,className:a,hasError:r,disabled:i,size:o,placeholder:s,leftIcon:$,iconSize:F,iconColor:_,onChange:P,...H,...c})}case"search":return p.jsx(Jo,{className:a,size:o,placeholder:s,leftIcon:$,rightIcon:D,iconSize:F,iconColor:_,onSearch:B.onSearch,...c});default:return p.jsx(Xo,{id:t,name:n,className:a,hasError:r,disabled:i,size:o,placeholder:s,type:Hg.includes(e)?e:"text",leftIcon:$,rightIcon:D,iconSize:F,iconColor:_,value:l??"",onChange:P,...B,...c})}};al.displayName="FieldRenderer";const Gg=g.div`
1119
1119
  display: flex;
1120
1120
  flex-direction: column;
1121
1121
  gap: 0.5rem;
1122
1122
  width: 100%;
1123
- `,Kg=m.memo(({inputId:e,label:t,size:n,required:o,disabled:r,hasError:i,errorMessage:s,isCheckbox:a=!1,className:l,labelClassName:c,messageErrorClassName:d,children:u})=>p.jsxs(Ug,{className:l,children:[t&&!a&&p.jsx(hn,{htmlFor:e,size:n,required:o,disabled:r,className:c,children:t}),u,i&&s&&p.jsx(qo,{id:`${e}-error`,size:n,className:d,children:s})]})),Wg=({id:e,name:t,label:n,type:o="text",size:r="md",placeholder:i,disabled:s=!1,required:a=!1,options:l=[],checkboxLabel:c,radioName:d,pinLength:u=6,pinType:h="number",rows:f=4,className:v,inputClassName:y,labelClassName:b,messageErrorClassName:w,leftIcon:T,rightIcon:C,iconSize:M,iconColor:x,onOptionSelect:P,onRadioChange:V,onPinComplete:$,onChange:F,...D})=>{const{field:_,hasError:N,errorMessage:O,inputId:j,ariaProps:K,handleStandardChange:R,handleTextAreaChange:L,handleCheckboxChange:G,handleSelectChange:oe,handleRadioChange:Q,handlePinChange:Se,handlePinComplete:mt}=Hg({name:t,required:a,onChange:F,onOptionSelect:P,onRadioChange:V,onPinComplete:$,options:l}),z=e?.toString?.()||j;return p.jsx(Kg,{inputId:z,label:n,size:r,required:a,disabled:s,hasError:N,errorMessage:O,isCheckbox:o==="checkbox",className:v,labelClassName:b,messageErrorClassName:w,children:p.jsx(cl,{type:o,inputId:z,name:t,size:r,hasError:N,disabled:s,placeholder:i,inputClassName:y,fieldValue:_.value,ariaProps:K,options:l,onSelectChange:oe,checkboxLabel:c,onCheckboxChange:G,radioName:d,onRadioChange:Q,pinLength:u,pinType:h,rows:f,onPinChange:Se,onPinComplete:mt,onStandardChange:R,onTextAreaChange:L,leftIcon:T,rightIcon:C,iconSize:M,iconColor:x,additionalProps:D})})},ul={initial:{opacity:0,scale:.95},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.95},transition:{duration:.2,ease:"easeInOut"},layout:!1},rr={initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:{duration:.3,ease:"easeInOut"}},qg={fromBottom:{initial:{opacity:0,y:20},animate:{opacity:1,y:0},exit:{opacity:0,y:20},transition:{duration:.2,ease:"easeInOut"}},fromTop:{initial:{opacity:0,y:-20},animate:{opacity:1,y:0},exit:{opacity:0,y:-20},transition:{duration:.2,ease:"easeInOut"}},fromLeft:{initial:{opacity:0,x:-20},animate:{opacity:1,x:0},exit:{opacity:0,x:-20},transition:{duration:.2,ease:"easeInOut"}},fromRight:{initial:{opacity:0,x:20},animate:{opacity:1,x:0},exit:{opacity:0,x:20},transition:{duration:.2,ease:"easeInOut"}}},dl={initial:{height:0,opacity:0,y:-6},animate:{height:"auto",opacity:1,y:0},exit:{height:0,opacity:0,y:-6},transition:{duration:.2,ease:"easeInOut"}},Yg=g(Fe.div)`
1123
+ `,Ug=m.memo(({inputId:e,label:t,size:n,required:o,disabled:r,hasError:i,errorMessage:s,isCheckbox:a=!1,className:l,labelClassName:c,messageErrorClassName:d,children:u})=>p.jsxs(Gg,{className:l,children:[t&&!a&&p.jsx(hn,{htmlFor:e,size:n,required:o,disabled:r,className:c,children:t}),u,i&&s&&p.jsx(Yo,{id:`${e}-error`,size:n,className:d,children:s})]})),Kg=({id:e,name:t,label:n,type:o="text",size:r="md",placeholder:i,disabled:s=!1,required:a=!1,options:l=[],checkboxLabel:c,radioName:d,pinLength:u=6,pinType:h="number",rows:f=4,className:v,inputClassName:y,labelClassName:b,messageErrorClassName:w,leftIcon:T,rightIcon:C,iconSize:k,iconColor:x,onOptionSelect:P,onRadioChange:V,onPinComplete:$,onChange:D,optionsClassName:F,optionClassName:_,...B})=>{const{field:H,hasError:z,errorMessage:G,inputId:R,ariaProps:L,handleStandardChange:j,handleTextAreaChange:oe,handleCheckboxChange:Q,handleSelectChange:Se,handleRadioChange:pt,handlePinChange:O,handlePinComplete:Z}=Og({name:t,required:a,onChange:D,onOptionSelect:P,onRadioChange:V,onPinComplete:$,options:l}),W=e?.toString?.()||R;return p.jsx(Ug,{inputId:W,label:n,size:r,required:a,disabled:s,hasError:z,errorMessage:G,isCheckbox:o==="checkbox",className:v,labelClassName:b,messageErrorClassName:w,children:p.jsx(al,{type:o,inputId:W,name:t,size:r,hasError:z,disabled:s,placeholder:i,inputClassName:y,fieldValue:H.value,ariaProps:L,options:l,onSelectChange:Se,checkboxLabel:c,onCheckboxChange:Q,radioName:d,onRadioChange:pt,pinLength:u,pinType:h,rows:f,onPinChange:O,onPinComplete:Z,onStandardChange:j,onTextAreaChange:oe,leftIcon:T,rightIcon:C,iconSize:k,iconColor:x,optionsClassName:F,optionClassName:_,additionalProps:B})})},ll={initial:{opacity:0,scale:.95},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.95},transition:{duration:.2,ease:"easeInOut"},layout:!1},ir={initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:{duration:.3,ease:"easeInOut"}},Wg={fromBottom:{initial:{opacity:0,y:20},animate:{opacity:1,y:0},exit:{opacity:0,y:20},transition:{duration:.2,ease:"easeInOut"}},fromTop:{initial:{opacity:0,y:-20},animate:{opacity:1,y:0},exit:{opacity:0,y:-20},transition:{duration:.2,ease:"easeInOut"}},fromLeft:{initial:{opacity:0,x:-20},animate:{opacity:1,x:0},exit:{opacity:0,x:-20},transition:{duration:.2,ease:"easeInOut"}},fromRight:{initial:{opacity:0,x:20},animate:{opacity:1,x:0},exit:{opacity:0,x:20},transition:{duration:.2,ease:"easeInOut"}}},cl={initial:{height:0,opacity:0,y:-6},animate:{height:"auto",opacity:1,y:0},exit:{height:0,opacity:0,y:-6},transition:{duration:.2,ease:"easeInOut"}},qg=g(Fe.div)`
1124
1124
  position: fixed;
1125
1125
  inset: 0;
1126
1126
  z-index: 50;
@@ -1134,7 +1134,7 @@
1134
1134
  @media (max-width: 768px) {
1135
1135
  padding: 0.5rem;
1136
1136
  }
1137
- `,Xg=g(Fe.div)`
1137
+ `,Yg=g(Fe.div)`
1138
1138
  position: relative;
1139
1139
  display: flex;
1140
1140
  flex-direction: column;
@@ -1161,7 +1161,7 @@
1161
1161
  outline: none;
1162
1162
  box-shadow: var(--shadow-hover-black-card);
1163
1163
  }
1164
- `,Zg=g.button`
1164
+ `,Xg=g.button`
1165
1165
  position: absolute;
1166
1166
  top: 1rem;
1167
1167
  right: 1rem;
@@ -1180,7 +1180,7 @@
1180
1180
  transform: scale(1.1);
1181
1181
  outline: none;
1182
1182
  }
1183
- `,Jg=e=>{const t=m.useRef(null),n=m.useRef(null);return m.useEffect(()=>{if(!e)return;n.current=document.activeElement;const o=t.current,r=()=>{o&&(o.hasAttribute("tabindex")||o.setAttribute("tabindex","-1"),o.focus())},i=window.setTimeout(r,0),s=l=>{const c=["a[href]","area[href]","button:not([disabled])",'input:not([disabled]):not([type="hidden"])',"select:not([disabled])","textarea:not([disabled])","iframe","object","embed",'[tabindex]:not([tabindex="-1"])','[contenteditable="true"]'];return Array.from(l.querySelectorAll(c.join(","))).filter(d=>!!(d.offsetWidth||d.offsetHeight||d.getClientRects().length))},a=l=>{if(l.key!=="Tab"||!o)return;const c=s(o);if(c.length===0){l.preventDefault(),o.focus();return}const d=c[0],u=c[c.length-1],h=document.activeElement;!l.shiftKey&&h===u?(l.preventDefault(),d.focus()):l.shiftKey&&h===d&&(l.preventDefault(),u.focus())};return document.addEventListener("keydown",a),()=>{window.clearTimeout(i),document.removeEventListener("keydown",a),n.current&&n.current.focus()}},[e]),t},Qg=(e,t,n=!0)=>{m.useEffect(()=>{if(!e||!n)return;const o=r=>{r.key==="Escape"&&t()};return document.addEventListener("keydown",o),()=>document.removeEventListener("keydown",o)},[e,t,n])},e0=e=>{m.useEffect(()=>(e?document.body.style.overflow="hidden":document.body.style.overflow="",()=>{document.body.style.overflow=""}),[e])},fl=({isOpen:e,onClose:t,children:n,className:o,closeOnBackdropClick:r=!0,showCloseButton:i=!1,size:s="md",fullScreen:a=!1,closeOnEsc:l=!0,ariaLabel:c,ariaLabelledBy:d,ariaDescribedBy:u})=>{const h=Jg(e);Qg(e,t,l),e0(e);const f=y=>{r&&y.target===y.currentTarget&&t()},v=p.jsx(At,{children:e&&p.jsx(Yg,{...rr,onClick:f,children:p.jsxs(Xg,{...ul,ref:h,$size:s,$fullScreen:a,className:o,onClick:y=>y.stopPropagation(),role:"dialog","aria-modal":"true","aria-label":c,"aria-labelledby":c?void 0:d,"aria-describedby":u,children:[i&&p.jsx(Zg,{className:`${pn} cursor-pointer`,onClick:t,"aria-label":"Close dialog",children:p.jsx(H,{component:Ya,size:"sm"})}),n]})})});return typeof document>"u"?v:_r.createPortal(v,document.body)},t0=g.div`
1183
+ `,Zg=e=>{const t=m.useRef(null),n=m.useRef(null);return m.useEffect(()=>{if(!e)return;n.current=document.activeElement;const o=t.current,r=()=>{o&&(o.hasAttribute("tabindex")||o.setAttribute("tabindex","-1"),o.focus())},i=window.setTimeout(r,0),s=l=>{const c=["a[href]","area[href]","button:not([disabled])",'input:not([disabled]):not([type="hidden"])',"select:not([disabled])","textarea:not([disabled])","iframe","object","embed",'[tabindex]:not([tabindex="-1"])','[contenteditable="true"]'];return Array.from(l.querySelectorAll(c.join(","))).filter(d=>!!(d.offsetWidth||d.offsetHeight||d.getClientRects().length))},a=l=>{if(l.key!=="Tab"||!o)return;const c=s(o);if(c.length===0){l.preventDefault(),o.focus();return}const d=c[0],u=c[c.length-1],h=document.activeElement;!l.shiftKey&&h===u?(l.preventDefault(),d.focus()):l.shiftKey&&h===d&&(l.preventDefault(),u.focus())};return document.addEventListener("keydown",a),()=>{window.clearTimeout(i),document.removeEventListener("keydown",a),n.current&&n.current.focus()}},[e]),t},Jg=(e,t,n=!0)=>{m.useEffect(()=>{if(!e||!n)return;const o=r=>{r.key==="Escape"&&t()};return document.addEventListener("keydown",o),()=>document.removeEventListener("keydown",o)},[e,t,n])},Qg=e=>{m.useEffect(()=>(e?document.body.style.overflow="hidden":document.body.style.overflow="",()=>{document.body.style.overflow=""}),[e])},ul=({isOpen:e,onClose:t,children:n,className:o,closeOnBackdropClick:r=!0,showCloseButton:i=!1,size:s="md",fullScreen:a=!1,closeOnEsc:l=!0,ariaLabel:c,ariaLabelledBy:d,ariaDescribedBy:u})=>{const h=Zg(e);Jg(e,t,l),Qg(e);const f=y=>{r&&y.target===y.currentTarget&&t()},v=p.jsx(It,{children:e&&p.jsx(qg,{...ir,onClick:f,children:p.jsxs(Yg,{...ll,ref:h,$size:s,$fullScreen:a,className:o,onClick:y=>y.stopPropagation(),role:"dialog","aria-modal":"true","aria-label":c,"aria-labelledby":c?void 0:d,"aria-describedby":u,children:[i&&p.jsx(Xg,{className:`${pn} cursor-pointer`,onClick:t,"aria-label":"Close dialog",children:p.jsx(U,{component:Wa,size:"sm"})}),n]})})});return typeof document>"u"?v:Rr.createPortal(v,document.body)},e0=g.div`
1184
1184
  display: flex;
1185
1185
  align-items: center;
1186
1186
  justify-content: space-between;
@@ -1213,7 +1213,7 @@
1213
1213
  flex-shrink: 0;
1214
1214
  margin-left: auto;
1215
1215
  }
1216
- `,hl=({showDivider:e=!1,variant:t="default",children:n,className:o,...r})=>p.jsx(t0,{$showDivider:e,$variant:t,className:o,...r,children:n}),n0=g.div`
1216
+ `,dl=({showDivider:e=!1,variant:t="default",children:n,className:o,...r})=>p.jsx(e0,{$showDivider:e,$variant:t,className:o,...r,children:n}),t0=g.div`
1217
1217
  position: relative;
1218
1218
  display: flex;
1219
1219
  flex-direction: column;
@@ -1226,7 +1226,7 @@
1226
1226
  ${({$showTopDivider:e})=>e&&"border-top: 1px solid var(--color-main-light-borders);"}
1227
1227
 
1228
1228
  ${({$showBottomDivider:e})=>e&&"border-bottom: 1px solid var(--color-main-light-borders);"}
1229
- `,ml=({children:e,padded:t=!0,showTopDivider:n=!1,showBottomDivider:o=!1,className:r,...i})=>p.jsx(n0,{$padded:t,$showTopDivider:n,$showBottomDivider:o,className:r,...i,children:e}),o0=g.div`
1229
+ `,fl=({children:e,padded:t=!0,showTopDivider:n=!1,showBottomDivider:o=!1,className:r,...i})=>p.jsx(t0,{$padded:t,$showTopDivider:n,$showBottomDivider:o,className:r,...i,children:e}),n0=g.div`
1230
1230
  display: flex;
1231
1231
  align-items: center;
1232
1232
  width: 100%;
@@ -1242,20 +1242,20 @@
1242
1242
  bottom: 0;
1243
1243
  background: var(--color-main-white);
1244
1244
  `}
1245
- `,pl=({align:e="end",showDivider:t=!1,gap:n=8,sticky:o=!1,children:r,className:i,...s})=>p.jsx(o0,{$align:e,$showDivider:t,$gap:n,$sticky:o,className:i,...s,children:r}),r0=({isOpen:e,onAccept:t,onCancel:n,title:o,subtitle:r,content:i,bodyFooter:s,confirmationLabel:a="I have read and agree to the Terms and Conditions",acceptLabel:l="Accept",cancelLabel:c="Cancel",size:d="md",fullScreen:u=!1,showCloseButton:h=!0,closeOnBackdropClick:f=!1,containerClassName:v,headerClassName:y,bodyClassName:b,footerClassName:w,initiallyConfirmed:T=!1,onConfirmChange:C})=>{const[M,x]=m.useState(T);m.useEffect(()=>{e||x(T)},[e,T]);const P=V=>{x(V),C?.(V)};return p.jsxs(fl,{isOpen:e,onClose:n,size:d,fullScreen:u,showCloseButton:h,closeOnBackdropClick:f,ariaLabelledBy:"tac-title",ariaDescribedBy:"tac-subtitle",className:`${v} !h-fit !max-w-[60rem]`,children:[p.jsx(hl,{showDivider:!0,className:y,children:p.jsx(Nr,{id:"tac-title",size:20,children:o})}),p.jsxs(ml,{padded:!0,showBottomDivider:!0,className:b,children:[r&&p.jsx(Ve,{id:"tac-subtitle",size:16,children:r}),i,s]}),p.jsxs(pl,{showDivider:!0,align:"space-between",className:w,children:[p.jsx(Nt,{label:a,checked:M,onChange:V=>P(V.target.checked)}),p.jsxs("div",{style:{display:"flex",gap:"0.5rem"},children:[p.jsx(dt,{variant:"secondary",onClick:n,children:c}),p.jsx(dt,{variant:"primary",onClick:t,disabled:!M,children:l})]})]})]})},i0=g.keyframes`
1245
+ `,hl=({align:e="end",showDivider:t=!1,gap:n=8,sticky:o=!1,children:r,className:i,...s})=>p.jsx(n0,{$align:e,$showDivider:t,$gap:n,$sticky:o,className:i,...s,children:r}),o0=({isOpen:e,onAccept:t,onCancel:n,title:o,subtitle:r,content:i,bodyFooter:s,confirmationLabel:a="I have read and agree to the Terms and Conditions",acceptLabel:l="Accept",cancelLabel:c="Cancel",size:d="md",fullScreen:u=!1,showCloseButton:h=!0,closeOnBackdropClick:f=!1,containerClassName:v,headerClassName:y,bodyClassName:b,footerClassName:w,initiallyConfirmed:T=!1,onConfirmChange:C})=>{const[k,x]=m.useState(T);m.useEffect(()=>{e||x(T)},[e,T]);const P=V=>{x(V),C?.(V)};return p.jsxs(ul,{isOpen:e,onClose:n,size:d,fullScreen:u,showCloseButton:h,closeOnBackdropClick:f,ariaLabelledBy:"tac-title",ariaDescribedBy:"tac-subtitle",className:`${v} !h-fit !max-w-[60rem]`,children:[p.jsx(dl,{showDivider:!0,className:y,children:p.jsx(Nr,{id:"tac-title",size:20,children:o})}),p.jsxs(fl,{padded:!0,showBottomDivider:!0,className:b,children:[r&&p.jsx(Ve,{id:"tac-subtitle",size:16,children:r}),i,s]}),p.jsxs(hl,{showDivider:!0,align:"space-between",className:w,children:[p.jsx(zt,{label:a,checked:k,onChange:V=>P(V.target.checked)}),p.jsxs("div",{style:{display:"flex",gap:"0.5rem"},children:[p.jsx(ft,{variant:"secondary",onClick:n,children:c}),p.jsx(ft,{variant:"primary",onClick:t,disabled:!k,children:l})]})]})]})},r0=g.keyframes`
1246
1246
  from {
1247
1247
  opacity: 0;
1248
1248
  }
1249
1249
  to {
1250
1250
  opacity: 1;
1251
1251
  }
1252
- `,s0=g.div`
1252
+ `,i0=g.div`
1253
1253
  position: relative;
1254
1254
  display: inline-block;
1255
- `,a0=g.div`
1255
+ `,s0=g.div`
1256
1256
  display: inline-block;
1257
1257
  cursor: pointer;
1258
- `,l0=e=>{switch(e){case"top":return g.css`
1258
+ `,a0=e=>{switch(e){case"top":return g.css`
1259
1259
  bottom: 100%;
1260
1260
  left: 50%;
1261
1261
  transform: translateX(-50%);
@@ -1275,7 +1275,7 @@
1275
1275
  top: 50%;
1276
1276
  transform: translateY(-50%);
1277
1277
  margin-left: 0.5rem;
1278
- `;default:return g.css``}},c0=g.div`
1278
+ `;default:return g.css``}},l0=g.div`
1279
1279
  position: absolute;
1280
1280
  z-index: 9999;
1281
1281
  pointer-events: auto;
@@ -1292,11 +1292,11 @@
1292
1292
  word-wrap: break-word;
1293
1293
 
1294
1294
  /* Animation */
1295
- animation: ${i0} 0.2s ease-in-out;
1295
+ animation: ${r0} 0.2s ease-in-out;
1296
1296
 
1297
1297
  /* Position based on placement */
1298
- ${({$placement:e})=>l0(e)}
1299
- `,u0=e=>{switch(e){case"top":return g.css`
1298
+ ${({$placement:e})=>a0(e)}
1299
+ `,c0=e=>{switch(e){case"top":return g.css`
1300
1300
  bottom: -0.25rem;
1301
1301
  left: 50%;
1302
1302
  transform: translateX(-50%) rotate(45deg);
@@ -1312,20 +1312,20 @@
1312
1312
  left: -0.25rem;
1313
1313
  top: 50%;
1314
1314
  transform: translateY(-50%) rotate(45deg);
1315
- `;default:return g.css``}},d0=g.div`
1315
+ `;default:return g.css``}},u0=g.div`
1316
1316
  position: absolute;
1317
1317
  width: 0.5rem;
1318
1318
  height: 0.5rem;
1319
1319
  background-color: var(--color-dark-600);
1320
1320
 
1321
- ${({$placement:e})=>u0(e)}
1322
- `,gl=({content:e,children:t,placement:n="bottom",trigger:o="hover",className:r="",arrowClassName:i="",delay:s=200,showArrow:a=!0})=>{const[l,c]=m.useState(!1),d=m.useRef(null),u=m.useRef(null),h=m.useRef(null);m.useEffect(()=>{if(o!=="click"||!l)return;const w=T=>{u.current&&!u.current.contains(T.target)&&h.current&&!h.current.contains(T.target)&&c(!1)};return document.addEventListener("mousedown",w),()=>document.removeEventListener("mousedown",w)},[l,o]),m.useEffect(()=>()=>{d.current&&clearTimeout(d.current)},[]);const b=o==="hover"?{onMouseEnter:()=>{d.current&&clearTimeout(d.current),d.current=setTimeout(()=>c(!0),s)},onMouseLeave:()=>{d.current&&clearTimeout(d.current),d.current=setTimeout(()=>c(!1),100)}}:{onClick:()=>{c(w=>!w)}};return p.jsxs(s0,{children:[p.jsx(a0,{ref:h,...b,children:t}),l&&p.jsxs(c0,{ref:u,$placement:n,className:r,role:"tooltip","aria-hidden":!l,children:[e,a&&p.jsx(d0,{$placement:n,className:i})]})]})};gl.displayName="Tooltip";const ir=m.createContext(void 0),vl=({children:e})=>{const[t,n]=m.useState(!1),[o,r]=m.useState(!1);return p.jsx(ir.Provider,{value:{isCollapsed:t,setIsCollapsed:n,isMobileOpen:o,setIsMobileOpen:r},children:e})},sr=()=>{const e=m.useContext(ir);if(!e)throw new Error("useSidebar must be used within a SidebarProvider");return e},ar=(e=[],t=[])=>!t||t.length===0?!1:t.includes("all")?!0:t.some(n=>e.includes(n)),f0=g.css`
1321
+ ${({$placement:e})=>c0(e)}
1322
+ `,ml=({content:e,children:t,placement:n="bottom",trigger:o="hover",className:r="",arrowClassName:i="",delay:s=200,showArrow:a=!0})=>{const[l,c]=m.useState(!1),d=m.useRef(null),u=m.useRef(null),h=m.useRef(null);m.useEffect(()=>{if(o!=="click"||!l)return;const w=T=>{u.current&&!u.current.contains(T.target)&&h.current&&!h.current.contains(T.target)&&c(!1)};return document.addEventListener("mousedown",w),()=>document.removeEventListener("mousedown",w)},[l,o]),m.useEffect(()=>()=>{d.current&&clearTimeout(d.current)},[]);const b=o==="hover"?{onMouseEnter:()=>{d.current&&clearTimeout(d.current),d.current=setTimeout(()=>c(!0),s)},onMouseLeave:()=>{d.current&&clearTimeout(d.current),d.current=setTimeout(()=>c(!1),100)}}:{onClick:()=>{c(w=>!w)}};return p.jsxs(i0,{children:[p.jsx(s0,{ref:h,...b,children:t}),l&&p.jsxs(l0,{ref:u,$placement:n,className:r,role:"tooltip","aria-hidden":!l,children:[e,a&&p.jsx(u0,{$placement:n,className:i})]})]})};ml.displayName="Tooltip";const sr=m.createContext(void 0),pl=({children:e})=>{const[t,n]=m.useState(!1),[o,r]=m.useState(!1);return p.jsx(sr.Provider,{value:{isCollapsed:t,setIsCollapsed:n,isMobileOpen:o,setIsMobileOpen:r},children:e})},ar=()=>{const e=m.useContext(sr);if(!e)throw new Error("useSidebar must be used within a SidebarProvider");return e},lr=(e=[],t=[])=>!t||t.length===0?!1:t.includes("all")?!0:t.some(n=>e.includes(n)),d0=g.css`
1323
1323
  display: flex;
1324
1324
  align-items: center;
1325
1325
  justify-content: center;
1326
1326
  flex-shrink: 0;
1327
1327
  user-select: none;
1328
- `,yl=`
1328
+ `,gl=`
1329
1329
  width: 100%;
1330
1330
  display: flex;
1331
1331
  align-items: center;
@@ -1342,8 +1342,8 @@
1342
1342
  outline-color: var(--color-main-blue-primary);
1343
1343
  outline-offset: -2px;
1344
1344
  }
1345
- `,h0=g.button`
1346
- ${yl}
1345
+ `,f0=g.button`
1346
+ ${gl}
1347
1347
 
1348
1348
  // Level-based padding
1349
1349
  padding: ${({$level:e})=>e===0?"0.75rem 0.875rem":"0.55rem 0.75rem"};
@@ -1362,8 +1362,8 @@
1362
1362
  }
1363
1363
 
1364
1364
  ${({$collapsed:e})=>e?"justify-content: center;":""}
1365
- `,m0=g.button`
1366
- ${yl}
1365
+ `,h0=g.button`
1366
+ ${gl}
1367
1367
 
1368
1368
  // Level-based padding
1369
1369
  padding: ${({$level:e})=>e===0?"0.75rem 0.875rem":"0.55rem 0.75rem"};
@@ -1382,36 +1382,36 @@
1382
1382
  }
1383
1383
 
1384
1384
  ${({$collapsed:e})=>e?"justify-content: center;":""}
1385
- `,p0=g.span`
1385
+ `,m0=g.span`
1386
1386
  display: inline-flex;
1387
1387
  align-items: center;
1388
1388
  gap: 0.75rem;
1389
1389
  min-width: 0;
1390
- `,g0=g(Ve)`
1390
+ `,p0=g(Ve)`
1391
1391
  font-weight: ${({$level:e})=>e===0?600:500};
1392
1392
  color: var(--color-main-blue-primary);
1393
1393
  white-space: nowrap;
1394
1394
  overflow: hidden;
1395
1395
  text-overflow: ellipsis;
1396
- `,v0=g(Fe.div)`
1396
+ `,g0=g(Fe.div)`
1397
1397
  background-color: transparent;
1398
1398
  overflow: hidden;
1399
1399
  will-change: height, opacity, transform;
1400
- `,y0=g.div`
1400
+ `,v0=g.div`
1401
1401
  width: 100%;
1402
1402
  ${({$level:e})=>e>0?"border-top: 1px solid var(--color-light-200);":""}
1403
- `,w0=g.span`
1403
+ `,y0=g.span`
1404
1404
  width: 0.625rem;
1405
1405
  height: 0.125rem;
1406
1406
  background: var(--color-main-blue-primary);
1407
1407
  border-radius: 1px;
1408
1408
  flex: 0 0 auto;
1409
- `,b0=g.div`
1410
- ${f0}
1409
+ `,w0=g.div`
1410
+ ${d0}
1411
1411
  transform: rotate(${({$open:e})=>e?"90deg":"0deg"});
1412
1412
  pointer-events: none;
1413
1413
  transition: transform 0.3s ease-out;
1414
- `,wl=({item:e,userRoles:t,level:n=0,activePath:o,onNavigate:r})=>{const[i,s]=m.useState(!1),{isCollapsed:a,setIsMobileOpen:l,setIsCollapsed:c}=sr(),d=m.useMemo(()=>(e.children||[]).filter(C=>ar(t,C.permissions)),[e.children,t]);if(!m.useMemo(()=>ar(t,e.permissions),[t,e.permissions]))return null;const h=d.length>0,f=e.href||e.path||"",v=!!(f&&o&&o.startsWith(f)),y=()=>{a&&c(!1),s(C=>!C)},b=()=>{a&&c(!1),e.href&&r?.(e.href)},w=async()=>{if(a&&c(!1),!e.path)return;const C=e.target||"_blank";try{typeof window<"u"&&(C==="_blank"?window.open(e.path,"_blank","noopener,noreferrer"):window.location.href=e.path),l&&l(!1)}catch(M){console.error("Error al navegar a microservicio:",M)}},T=()=>p.jsxs(p.Fragment,{children:[p.jsxs(p0,{children:[n>0&&!a&&p.jsx(w0,{}),e.icon&&p.jsx(H,{component:e.icon,size:n===0?"md":"sm",color:"var(--color-main-blue-primary)"}),!a&&p.jsx(g0,{$level:n,size:n===0?16:n===1?14:12,color:"var(--color-dark-700, #374151)",children:e.label})]}),!a&&h&&p.jsx(b0,{$disabled:a,$open:i,children:p.jsx(H,{component:$p,size:"sm",color:"var(--color-main-blue-primary)"})})]});return p.jsxs(y0,{$level:n,children:[e.href&&!e.path&&!h?p.jsx(h0,{type:"button",onClick:b,$level:n,$collapsed:a,$active:v,title:a?e.label:"",children:T()}):p.jsx(m0,{type:"button",onClick:h?y:e.path?w:b,$level:n,$collapsed:a,$active:v,$expanded:i&&h,title:a?e.label:"",children:T()}),p.jsx(At,{initial:!1,children:!a&&i&&h&&p.jsx(v0,{$level:n+1,...dl,children:d.map(C=>p.jsx(wl,{item:C,userRoles:t,level:n+1,onNavigate:r,activePath:o},C.id))})})]})},bl=g(Fe.div)`
1414
+ `,vl=({item:e,userRoles:t,level:n=0,activePath:o,onNavigate:r})=>{const[i,s]=m.useState(!1),{isCollapsed:a,setIsMobileOpen:l,setIsCollapsed:c}=ar(),d=m.useMemo(()=>(e.children||[]).filter(C=>lr(t,C.permissions)),[e.children,t]);if(!m.useMemo(()=>lr(t,e.permissions),[t,e.permissions]))return null;const h=d.length>0,f=e.href||e.path||"",v=!!(f&&o&&o.startsWith(f)),y=()=>{a&&c(!1),s(C=>!C)},b=()=>{a&&c(!1),e.href&&r?.(e.href)},w=async()=>{if(a&&c(!1),!e.path)return;const C=e.target||"_blank";try{typeof window<"u"&&(C==="_blank"?window.open(e.path,"_blank","noopener,noreferrer"):window.location.href=e.path),l&&l(!1)}catch(k){console.error("Error al navegar a microservicio:",k)}},T=()=>p.jsxs(p.Fragment,{children:[p.jsxs(m0,{children:[n>0&&!a&&p.jsx(y0,{}),e.icon&&p.jsx(U,{component:e.icon,size:n===0?"md":"sm",color:"var(--color-main-blue-primary)"}),!a&&p.jsx(p0,{$level:n,size:n===0?16:n===1?14:12,color:"var(--color-dark-700, #374151)",children:e.label})]}),!a&&h&&p.jsx(w0,{$disabled:a,$open:i,children:p.jsx(U,{component:Tp,size:"sm",color:"var(--color-main-blue-primary)"})})]});return p.jsxs(v0,{$level:n,children:[e.href&&!e.path&&!h?p.jsx(f0,{type:"button",onClick:b,$level:n,$collapsed:a,$active:v,title:a?e.label:"",children:T()}):p.jsx(h0,{type:"button",onClick:h?y:e.path?w:b,$level:n,$collapsed:a,$active:v,$expanded:i&&h,title:a?e.label:"",children:T()}),p.jsx(It,{initial:!1,children:!a&&i&&h&&p.jsx(g0,{$level:n+1,...cl,children:d.map(C=>p.jsx(vl,{item:C,userRoles:t,level:n+1,onNavigate:r,activePath:o},C.id))})})]})},yl=g(Fe.div)`
1415
1415
  position: fixed;
1416
1416
  inset: 0;
1417
1417
  background: rgba(0, 0, 0, 0.5);
@@ -1420,7 +1420,7 @@
1420
1420
  @media (max-width: 767px) {
1421
1421
  display: block;
1422
1422
  }
1423
- `,xl=g.aside`
1423
+ `,wl=g.aside`
1424
1424
  position: fixed;
1425
1425
  left: 0;
1426
1426
  top: 0;
@@ -1439,7 +1439,7 @@
1439
1439
  @media (min-width: 768px) {
1440
1440
  transform: translateX(0);
1441
1441
  }
1442
- `,Sl=g.div`
1442
+ `,bl=g.div`
1443
1443
  display: flex;
1444
1444
  align-items: center;
1445
1445
  justify-content: space-between;
@@ -1447,11 +1447,11 @@
1447
1447
  padding: 1rem;
1448
1448
 
1449
1449
  ${({$collapsed:e})=>e?"flex-direction: column":""};
1450
- `,Cl=g.div`
1450
+ `,xl=g.div`
1451
1451
  display: flex;
1452
1452
  align-items: center;
1453
1453
  gap: 0.5rem;
1454
- `,Tl=g.nav`
1454
+ `,Sl=g.nav`
1455
1455
  display: flex;
1456
1456
  flex-direction: column;
1457
1457
  justify-content: flex-start;
@@ -1459,7 +1459,7 @@
1459
1459
  flex: 1;
1460
1460
  overflow-y: auto;
1461
1461
  padding: 0.25rem 0;
1462
- `,$l=g.button`
1462
+ `,Cl=g.button`
1463
1463
  display: flex;
1464
1464
  align-items: center;
1465
1465
  justify-content: center;
@@ -1485,7 +1485,7 @@
1485
1485
  @media (max-width: 767px) {
1486
1486
  display: none;
1487
1487
  }
1488
- `,Pl=g.button`
1488
+ `,Tl=g.button`
1489
1489
  position: fixed;
1490
1490
  top: 0.5rem;
1491
1491
  left: 1rem;
@@ -1496,7 +1496,7 @@
1496
1496
  @media (min-width: 768px) {
1497
1497
  display: none;
1498
1498
  }
1499
- `,lr=({navigationConfig:e,userRoles:t=[],activePath:n,logoImgExpanded:o,logoImgCollapsed:r,onNavigate:i=()=>{}})=>{const{isCollapsed:s,setIsCollapsed:a,isMobileOpen:l,setIsMobileOpen:c}=sr(),d=u=>{i(u),typeof window<"u"&&window.innerWidth<768&&c(!1)};return p.jsxs(p.Fragment,{children:[p.jsx(At,{children:l&&p.jsx(bl,{...rr,onClick:()=>c(!1)})}),p.jsxs(xl,{$collapsed:l?!1:s,$open:l,children:[p.jsxs(Sl,{$collapsed:s,children:[p.jsx(Cl,{children:s?r:o}),p.jsx($l,{onClick:()=>a(!s),"aria-label":"Toggle collapse",children:p.jsx(H,{component:Xa,size:"md",color:"var(--color-main-blue-primary)"})})]}),p.jsx(Tl,{children:e.map(u=>p.jsx(wl,{item:u,userRoles:t,onNavigate:d,activePath:n},u.id))})]}),p.jsx(Pl,{onClick:()=>{c(!0),a(!1)},$hidden:l,children:p.jsx(H,{component:Xa,size:30})})]})};lr.displayName="Sidebar";const Ml={underlined:g.css`
1499
+ `,cr=({navigationConfig:e,userRoles:t=[],activePath:n,logoImgExpanded:o,logoImgCollapsed:r,onNavigate:i=()=>{}})=>{const{isCollapsed:s,setIsCollapsed:a,isMobileOpen:l,setIsMobileOpen:c}=ar(),d=u=>{i(u),typeof window<"u"&&window.innerWidth<768&&c(!1)};return p.jsxs(p.Fragment,{children:[p.jsx(It,{children:l&&p.jsx(yl,{...ir,onClick:()=>c(!1)})}),p.jsxs(wl,{$collapsed:l?!1:s,$open:l,children:[p.jsxs(bl,{$collapsed:s,children:[p.jsx(xl,{children:s?r:o}),p.jsx(Cl,{onClick:()=>a(!s),"aria-label":"Toggle collapse",children:p.jsx(U,{component:qa,size:"md",color:"var(--color-main-blue-primary)"})})]}),p.jsx(Sl,{children:e.map(u=>p.jsx(vl,{item:u,userRoles:t,onNavigate:d,activePath:n},u.id))})]}),p.jsx(Tl,{onClick:()=>{c(!0),a(!1)},$hidden:l,children:p.jsx(U,{component:qa,size:30})})]})};cr.displayName="Sidebar";const $l={underlined:g.css`
1500
1500
  color: var(--color-main-orange-primary);
1501
1501
  text-decoration-thickness: 1px;
1502
1502
  text-underline-offset: 2px;
@@ -1556,7 +1556,7 @@
1556
1556
  text-decoration-thickness: 1px;
1557
1557
  text-underline-offset: 2px;
1558
1558
  }
1559
- `},kl=g.css`
1559
+ `},Pl=g.css`
1560
1560
  color: var(--color-dark-200);
1561
1561
  cursor: not-allowed;
1562
1562
  pointer-events: none;
@@ -1574,7 +1574,7 @@
1574
1574
  text-decoration: none;
1575
1575
  transform: none;
1576
1576
  }
1577
- `,Vl={sm:g.css`
1577
+ `,kl={sm:g.css`
1578
1578
  gap: 0.25rem;
1579
1579
  ${E[14]}
1580
1580
  `,md:g.css`
@@ -1583,7 +1583,7 @@
1583
1583
  `,lg:g.css`
1584
1584
  gap: 0.75rem;
1585
1585
  ${E[20]}
1586
- `},x0=g.a`
1586
+ `},b0=g.a`
1587
1587
  display: inline-flex;
1588
1588
  align-items: center;
1589
1589
  border-radius: 0.25rem;
@@ -1595,10 +1595,10 @@
1595
1595
 
1596
1596
  cursor: pointer;
1597
1597
 
1598
- ${({$size:e})=>Vl[e]}
1599
- ${({$variant:e})=>Ml[e]}
1600
- ${({$disabled:e})=>e&&kl}
1601
- `,S0=g.styled.span`
1598
+ ${({$size:e})=>kl[e]}
1599
+ ${({$variant:e})=>$l[e]}
1600
+ ${({$disabled:e})=>e&&Pl}
1601
+ `,x0=g.styled.span`
1602
1602
  flex: 1 1 auto;
1603
1603
  min-width: 0;
1604
1604
  max-width: 18ch;
@@ -1607,10 +1607,10 @@
1607
1607
  text-overflow: ellipsis;
1608
1608
  white-space: nowrap;
1609
1609
  `}
1610
- `,El=m.forwardRef(({id:e,size:t="md",variant:n="underlined",children:o,href:r,target:i,rel:s,className:a,disabled:l=!1,tabIndex:c,leftIcon:d,rightIcon:u,iconSize:h="tn",iconColor:f="currentColor",truncate:v=!1,"aria-label":y,"aria-describedby":b,onClick:w,...T},C)=>{const M=m.useCallback(P=>{if(l){P.preventDefault();return}w?.(P)},[l,w]),x={href:l?void 0:r,target:i||void 0,rel:s??(i==="_blank"?"noopener noreferrer":void 0),onClick:M,"aria-label":y??o,"aria-describedby":b,"aria-disabled":l,tabIndex:l?-1:c??0,...T};return p.jsxs(x0,{id:e,$variant:n,$size:t,$disabled:l,className:a,ref:C,...x,children:[d&&p.jsx(H,{component:d,size:h,color:f}),p.jsx(S0,{$truncate:v,children:o}),p.jsx(H,{component:u||Mp,size:t==="lg"?"sm":h,color:f})]})});El.displayName="Link";function C0(){return{accessor:(e,t)=>typeof e=="function"?{...t,accessorFn:e}:{...t,accessorKey:e},display:e=>e,group:e=>e}}function He(e,t){return typeof e=="function"?e(t):e}function de(e,t){return n=>{t.setState(o=>({...o,[e]:He(n,o[e])}))}}function vn(e){return e instanceof Function}function T0(e){return Array.isArray(e)&&e.every(t=>typeof t=="number")}function $0(e,t){const n=[],o=r=>{r.forEach(i=>{n.push(i);const s=t(i);s!=null&&s.length&&o(s)})};return o(e),n}function A(e,t,n){let o=[],r;return i=>{let s;n.key&&n.debug&&(s=Date.now());const a=e(i);if(!(a.length!==o.length||a.some((d,u)=>o[u]!==d)))return r;o=a;let c;if(n.key&&n.debug&&(c=Date.now()),r=t(...a),n==null||n.onChange==null||n.onChange(r),n.key&&n.debug&&n!=null&&n.debug()){const d=Math.round((Date.now()-s)*100)/100,u=Math.round((Date.now()-c)*100)/100,h=u/16,f=(v,y)=>{for(v=String(v);v.length<y;)v=" "+v;return v};console.info(`%c⏱ ${f(u,5)} /${f(d,5)} ms`,`
1610
+ `,Ml=m.forwardRef(({id:e,size:t="md",variant:n="underlined",children:o,href:r,target:i,rel:s,className:a,disabled:l=!1,tabIndex:c,leftIcon:d,rightIcon:u,iconSize:h="tn",iconColor:f="currentColor",truncate:v=!1,"aria-label":y,"aria-describedby":b,onClick:w,...T},C)=>{const k=m.useCallback(P=>{if(l){P.preventDefault();return}w?.(P)},[l,w]),x={href:l?void 0:r,target:i||void 0,rel:s??(i==="_blank"?"noopener noreferrer":void 0),onClick:k,"aria-label":y??o,"aria-describedby":b,"aria-disabled":l,tabIndex:l?-1:c??0,...T};return p.jsxs(b0,{id:e,$variant:n,$size:t,$disabled:l,className:a,ref:C,...x,children:[d&&p.jsx(U,{component:d,size:h,color:f}),p.jsx(x0,{$truncate:v,children:o}),p.jsx(U,{component:u||Pp,size:t==="lg"?"sm":h,color:f})]})});Ml.displayName="Link";function S0(){return{accessor:(e,t)=>typeof e=="function"?{...t,accessorFn:e}:{...t,accessorKey:e},display:e=>e,group:e=>e}}function He(e,t){return typeof e=="function"?e(t):e}function de(e,t){return n=>{t.setState(o=>({...o,[e]:He(n,o[e])}))}}function vn(e){return e instanceof Function}function C0(e){return Array.isArray(e)&&e.every(t=>typeof t=="number")}function T0(e,t){const n=[],o=r=>{r.forEach(i=>{n.push(i);const s=t(i);s!=null&&s.length&&o(s)})};return o(e),n}function A(e,t,n){let o=[],r;return i=>{let s;n.key&&n.debug&&(s=Date.now());const a=e(i);if(!(a.length!==o.length||a.some((d,u)=>o[u]!==d)))return r;o=a;let c;if(n.key&&n.debug&&(c=Date.now()),r=t(...a),n==null||n.onChange==null||n.onChange(r),n.key&&n.debug&&n!=null&&n.debug()){const d=Math.round((Date.now()-s)*100)/100,u=Math.round((Date.now()-c)*100)/100,h=u/16,f=(v,y)=>{for(v=String(v);v.length<y;)v=" "+v;return v};console.info(`%c⏱ ${f(u,5)} /${f(d,5)} ms`,`
1611
1611
  font-size: .6rem;
1612
1612
  font-weight: bold;
1613
- color: hsl(${Math.max(0,Math.min(120-120*h,120))}deg 100% 31%);`,n?.key)}return r}}function I(e,t,n,o){return{debug:()=>{var r;return(r=e?.debugAll)!=null?r:e[t]},key:process.env.NODE_ENV==="development"&&n,onChange:o}}function P0(e,t,n,o){const r=()=>{var s;return(s=i.getValue())!=null?s:e.options.renderFallbackValue},i={id:`${t.id}_${n.id}`,row:t,column:n,getValue:()=>t.getValue(o),renderValue:r,getContext:A(()=>[e,n,t,i],(s,a,l,c)=>({table:s,column:a,row:l,cell:c,getValue:c.getValue,renderValue:c.renderValue}),I(e.options,"debugCells","cell.getContext"))};return e._features.forEach(s=>{s.createCell==null||s.createCell(i,n,t,e)},{}),i}function M0(e,t,n,o){var r,i;const a={...e._getDefaultColumnDef(),...t},l=a.accessorKey;let c=(r=(i=a.id)!=null?i:l?typeof String.prototype.replaceAll=="function"?l.replaceAll(".","_"):l.replace(/\./g,"_"):void 0)!=null?r:typeof a.header=="string"?a.header:void 0,d;if(a.accessorFn?d=a.accessorFn:l&&(l.includes(".")?d=h=>{let f=h;for(const y of l.split(".")){var v;f=(v=f)==null?void 0:v[y],process.env.NODE_ENV!=="production"&&f===void 0&&console.warn(`"${y}" in deeply nested key "${l}" returned undefined.`)}return f}:d=h=>h[a.accessorKey]),!c)throw process.env.NODE_ENV!=="production"?new Error(a.accessorFn?"Columns require an id when using an accessorFn":"Columns require an id when using a non-string header"):new Error;let u={id:`${String(c)}`,accessorFn:d,parent:o,depth:n,columnDef:a,columns:[],getFlatColumns:A(()=>[!0],()=>{var h;return[u,...(h=u.columns)==null?void 0:h.flatMap(f=>f.getFlatColumns())]},I(e.options,"debugColumns","column.getFlatColumns")),getLeafColumns:A(()=>[e._getOrderColumnsFn()],h=>{var f;if((f=u.columns)!=null&&f.length){let v=u.columns.flatMap(y=>y.getLeafColumns());return h(v)}return[u]},I(e.options,"debugColumns","column.getLeafColumns"))};for(const h of e._features)h.createColumn==null||h.createColumn(u,e);return u}const se="debugHeaders";function Dl(e,t,n){var o;let i={id:(o=n.id)!=null?o:t.id,column:t,index:n.index,isPlaceholder:!!n.isPlaceholder,placeholderId:n.placeholderId,depth:n.depth,subHeaders:[],colSpan:0,rowSpan:0,headerGroup:null,getLeafHeaders:()=>{const s=[],a=l=>{l.subHeaders&&l.subHeaders.length&&l.subHeaders.map(a),s.push(l)};return a(i),s},getContext:()=>({table:e,header:i,column:t})};return e._features.forEach(s=>{s.createHeader==null||s.createHeader(i,e)}),i}const k0={createTable:e=>{e.getHeaderGroups=A(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,o,r)=>{var i,s;const a=(i=o?.map(u=>n.find(h=>h.id===u)).filter(Boolean))!=null?i:[],l=(s=r?.map(u=>n.find(h=>h.id===u)).filter(Boolean))!=null?s:[],c=n.filter(u=>!(o!=null&&o.includes(u.id))&&!(r!=null&&r.includes(u.id)));return yn(t,[...a,...c,...l],e)},I(e.options,se,"getHeaderGroups")),e.getCenterHeaderGroups=A(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,o,r)=>(n=n.filter(i=>!(o!=null&&o.includes(i.id))&&!(r!=null&&r.includes(i.id))),yn(t,n,e,"center")),I(e.options,se,"getCenterHeaderGroups")),e.getLeftHeaderGroups=A(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left],(t,n,o)=>{var r;const i=(r=o?.map(s=>n.find(a=>a.id===s)).filter(Boolean))!=null?r:[];return yn(t,i,e,"left")},I(e.options,se,"getLeftHeaderGroups")),e.getRightHeaderGroups=A(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.right],(t,n,o)=>{var r;const i=(r=o?.map(s=>n.find(a=>a.id===s)).filter(Boolean))!=null?r:[];return yn(t,i,e,"right")},I(e.options,se,"getRightHeaderGroups")),e.getFooterGroups=A(()=>[e.getHeaderGroups()],t=>[...t].reverse(),I(e.options,se,"getFooterGroups")),e.getLeftFooterGroups=A(()=>[e.getLeftHeaderGroups()],t=>[...t].reverse(),I(e.options,se,"getLeftFooterGroups")),e.getCenterFooterGroups=A(()=>[e.getCenterHeaderGroups()],t=>[...t].reverse(),I(e.options,se,"getCenterFooterGroups")),e.getRightFooterGroups=A(()=>[e.getRightHeaderGroups()],t=>[...t].reverse(),I(e.options,se,"getRightFooterGroups")),e.getFlatHeaders=A(()=>[e.getHeaderGroups()],t=>t.map(n=>n.headers).flat(),I(e.options,se,"getFlatHeaders")),e.getLeftFlatHeaders=A(()=>[e.getLeftHeaderGroups()],t=>t.map(n=>n.headers).flat(),I(e.options,se,"getLeftFlatHeaders")),e.getCenterFlatHeaders=A(()=>[e.getCenterHeaderGroups()],t=>t.map(n=>n.headers).flat(),I(e.options,se,"getCenterFlatHeaders")),e.getRightFlatHeaders=A(()=>[e.getRightHeaderGroups()],t=>t.map(n=>n.headers).flat(),I(e.options,se,"getRightFlatHeaders")),e.getCenterLeafHeaders=A(()=>[e.getCenterFlatHeaders()],t=>t.filter(n=>{var o;return!((o=n.subHeaders)!=null&&o.length)}),I(e.options,se,"getCenterLeafHeaders")),e.getLeftLeafHeaders=A(()=>[e.getLeftFlatHeaders()],t=>t.filter(n=>{var o;return!((o=n.subHeaders)!=null&&o.length)}),I(e.options,se,"getLeftLeafHeaders")),e.getRightLeafHeaders=A(()=>[e.getRightFlatHeaders()],t=>t.filter(n=>{var o;return!((o=n.subHeaders)!=null&&o.length)}),I(e.options,se,"getRightLeafHeaders")),e.getLeafHeaders=A(()=>[e.getLeftHeaderGroups(),e.getCenterHeaderGroups(),e.getRightHeaderGroups()],(t,n,o)=>{var r,i,s,a,l,c;return[...(r=(i=t[0])==null?void 0:i.headers)!=null?r:[],...(s=(a=n[0])==null?void 0:a.headers)!=null?s:[],...(l=(c=o[0])==null?void 0:c.headers)!=null?l:[]].map(d=>d.getLeafHeaders()).flat()},I(e.options,se,"getLeafHeaders"))}};function yn(e,t,n,o){var r,i;let s=0;const a=function(h,f){f===void 0&&(f=1),s=Math.max(s,f),h.filter(v=>v.getIsVisible()).forEach(v=>{var y;(y=v.columns)!=null&&y.length&&a(v.columns,f+1)},0)};a(e);let l=[];const c=(h,f)=>{const v={depth:f,id:[o,`${f}`].filter(Boolean).join("_"),headers:[]},y=[];h.forEach(b=>{const w=[...y].reverse()[0],T=b.column.depth===v.depth;let C,M=!1;if(T&&b.column.parent?C=b.column.parent:(C=b.column,M=!0),w&&w?.column===C)w.subHeaders.push(b);else{const x=Dl(n,C,{id:[o,f,C.id,b?.id].filter(Boolean).join("_"),isPlaceholder:M,placeholderId:M?`${y.filter(P=>P.column===C).length}`:void 0,depth:f,index:y.length});x.subHeaders.push(b),y.push(x)}v.headers.push(b),b.headerGroup=v}),l.push(v),f>0&&c(y,f-1)},d=t.map((h,f)=>Dl(n,h,{depth:s,index:f}));c(d,s-1),l.reverse();const u=h=>h.filter(v=>v.column.getIsVisible()).map(v=>{let y=0,b=0,w=[0];v.subHeaders&&v.subHeaders.length?(w=[],u(v.subHeaders).forEach(C=>{let{colSpan:M,rowSpan:x}=C;y+=M,w.push(x)})):y=1;const T=Math.min(...w);return b=b+T,v.colSpan=y,v.rowSpan=b,{colSpan:y,rowSpan:b}});return u((r=(i=l[0])==null?void 0:i.headers)!=null?r:[]),l}const cr=(e,t,n,o,r,i,s)=>{let a={id:t,index:o,original:n,depth:r,parentId:s,_valuesCache:{},_uniqueValuesCache:{},getValue:l=>{if(a._valuesCache.hasOwnProperty(l))return a._valuesCache[l];const c=e.getColumn(l);if(c!=null&&c.accessorFn)return a._valuesCache[l]=c.accessorFn(a.original,o),a._valuesCache[l]},getUniqueValues:l=>{if(a._uniqueValuesCache.hasOwnProperty(l))return a._uniqueValuesCache[l];const c=e.getColumn(l);if(c!=null&&c.accessorFn)return c.columnDef.getUniqueValues?(a._uniqueValuesCache[l]=c.columnDef.getUniqueValues(a.original,o),a._uniqueValuesCache[l]):(a._uniqueValuesCache[l]=[a.getValue(l)],a._uniqueValuesCache[l])},renderValue:l=>{var c;return(c=a.getValue(l))!=null?c:e.options.renderFallbackValue},subRows:[],getLeafRows:()=>$0(a.subRows,l=>l.subRows),getParentRow:()=>a.parentId?e.getRow(a.parentId,!0):void 0,getParentRows:()=>{let l=[],c=a;for(;;){const d=c.getParentRow();if(!d)break;l.push(d),c=d}return l.reverse()},getAllCells:A(()=>[e.getAllLeafColumns()],l=>l.map(c=>P0(e,a,c,c.id)),I(e.options,"debugRows","getAllCells")),_getAllCellsByColumnId:A(()=>[a.getAllCells()],l=>l.reduce((c,d)=>(c[d.column.id]=d,c),{}),I(e.options,"debugRows","getAllCellsByColumnId"))};for(let l=0;l<e._features.length;l++){const c=e._features[l];c==null||c.createRow==null||c.createRow(a,e)}return a},V0={createColumn:(e,t)=>{e._getFacetedRowModel=t.options.getFacetedRowModel&&t.options.getFacetedRowModel(t,e.id),e.getFacetedRowModel=()=>e._getFacetedRowModel?e._getFacetedRowModel():t.getPreFilteredRowModel(),e._getFacetedUniqueValues=t.options.getFacetedUniqueValues&&t.options.getFacetedUniqueValues(t,e.id),e.getFacetedUniqueValues=()=>e._getFacetedUniqueValues?e._getFacetedUniqueValues():new Map,e._getFacetedMinMaxValues=t.options.getFacetedMinMaxValues&&t.options.getFacetedMinMaxValues(t,e.id),e.getFacetedMinMaxValues=()=>{if(e._getFacetedMinMaxValues)return e._getFacetedMinMaxValues()}}},Fl=(e,t,n)=>{var o,r;const i=n==null||(o=n.toString())==null?void 0:o.toLowerCase();return!!(!((r=e.getValue(t))==null||(r=r.toString())==null||(r=r.toLowerCase())==null)&&r.includes(i))};Fl.autoRemove=e=>xe(e);const Al=(e,t,n)=>{var o;return!!(!((o=e.getValue(t))==null||(o=o.toString())==null)&&o.includes(n))};Al.autoRemove=e=>xe(e);const Il=(e,t,n)=>{var o;return((o=e.getValue(t))==null||(o=o.toString())==null?void 0:o.toLowerCase())===n?.toLowerCase()};Il.autoRemove=e=>xe(e);const Ll=(e,t,n)=>{var o;return(o=e.getValue(t))==null?void 0:o.includes(n)};Ll.autoRemove=e=>xe(e);const Rl=(e,t,n)=>!n.some(o=>{var r;return!((r=e.getValue(t))!=null&&r.includes(o))});Rl.autoRemove=e=>xe(e)||!(e!=null&&e.length);const _l=(e,t,n)=>n.some(o=>{var r;return(r=e.getValue(t))==null?void 0:r.includes(o)});_l.autoRemove=e=>xe(e)||!(e!=null&&e.length);const Bl=(e,t,n)=>e.getValue(t)===n;Bl.autoRemove=e=>xe(e);const Nl=(e,t,n)=>e.getValue(t)==n;Nl.autoRemove=e=>xe(e);const ur=(e,t,n)=>{let[o,r]=n;const i=e.getValue(t);return i>=o&&i<=r};ur.resolveFilterValue=e=>{let[t,n]=e,o=typeof t!="number"?parseFloat(t):t,r=typeof n!="number"?parseFloat(n):n,i=t===null||Number.isNaN(o)?-1/0:o,s=n===null||Number.isNaN(r)?1/0:r;if(i>s){const a=i;i=s,s=a}return[i,s]},ur.autoRemove=e=>xe(e)||xe(e[0])&&xe(e[1]);const Ae={includesString:Fl,includesStringSensitive:Al,equalsString:Il,arrIncludes:Ll,arrIncludesAll:Rl,arrIncludesSome:_l,equals:Bl,weakEquals:Nl,inNumberRange:ur};function xe(e){return e==null||e===""}const E0={getDefaultColumnDef:()=>({filterFn:"auto"}),getInitialState:e=>({columnFilters:[],...e}),getDefaultOptions:e=>({onColumnFiltersChange:de("columnFilters",e),filterFromLeafRows:!1,maxLeafRowFilterDepth:100}),createColumn:(e,t)=>{e.getAutoFilterFn=()=>{const n=t.getCoreRowModel().flatRows[0],o=n?.getValue(e.id);return typeof o=="string"?Ae.includesString:typeof o=="number"?Ae.inNumberRange:typeof o=="boolean"||o!==null&&typeof o=="object"?Ae.equals:Array.isArray(o)?Ae.arrIncludes:Ae.weakEquals},e.getFilterFn=()=>{var n,o;return vn(e.columnDef.filterFn)?e.columnDef.filterFn:e.columnDef.filterFn==="auto"?e.getAutoFilterFn():(n=(o=t.options.filterFns)==null?void 0:o[e.columnDef.filterFn])!=null?n:Ae[e.columnDef.filterFn]},e.getCanFilter=()=>{var n,o,r;return((n=e.columnDef.enableColumnFilter)!=null?n:!0)&&((o=t.options.enableColumnFilters)!=null?o:!0)&&((r=t.options.enableFilters)!=null?r:!0)&&!!e.accessorFn},e.getIsFiltered=()=>e.getFilterIndex()>-1,e.getFilterValue=()=>{var n;return(n=t.getState().columnFilters)==null||(n=n.find(o=>o.id===e.id))==null?void 0:n.value},e.getFilterIndex=()=>{var n,o;return(n=(o=t.getState().columnFilters)==null?void 0:o.findIndex(r=>r.id===e.id))!=null?n:-1},e.setFilterValue=n=>{t.setColumnFilters(o=>{const r=e.getFilterFn(),i=o?.find(d=>d.id===e.id),s=He(n,i?i.value:void 0);if(zl(r,s,e)){var a;return(a=o?.filter(d=>d.id!==e.id))!=null?a:[]}const l={id:e.id,value:s};if(i){var c;return(c=o?.map(d=>d.id===e.id?l:d))!=null?c:[]}return o!=null&&o.length?[...o,l]:[l]})}},createRow:(e,t)=>{e.columnFilters={},e.columnFiltersMeta={}},createTable:e=>{e.setColumnFilters=t=>{const n=e.getAllLeafColumns(),o=r=>{var i;return(i=He(t,r))==null?void 0:i.filter(s=>{const a=n.find(l=>l.id===s.id);if(a){const l=a.getFilterFn();if(zl(l,s.value,a))return!1}return!0})};e.options.onColumnFiltersChange==null||e.options.onColumnFiltersChange(o)},e.resetColumnFilters=t=>{var n,o;e.setColumnFilters(t?[]:(n=(o=e.initialState)==null?void 0:o.columnFilters)!=null?n:[])},e.getPreFilteredRowModel=()=>e.getCoreRowModel(),e.getFilteredRowModel=()=>(!e._getFilteredRowModel&&e.options.getFilteredRowModel&&(e._getFilteredRowModel=e.options.getFilteredRowModel(e)),e.options.manualFiltering||!e._getFilteredRowModel?e.getPreFilteredRowModel():e._getFilteredRowModel())}};function zl(e,t,n){return(e&&e.autoRemove?e.autoRemove(t,n):!1)||typeof t>"u"||typeof t=="string"&&!t}const dr={sum:(e,t,n)=>n.reduce((o,r)=>{const i=r.getValue(e);return o+(typeof i=="number"?i:0)},0),min:(e,t,n)=>{let o;return n.forEach(r=>{const i=r.getValue(e);i!=null&&(o>i||o===void 0&&i>=i)&&(o=i)}),o},max:(e,t,n)=>{let o;return n.forEach(r=>{const i=r.getValue(e);i!=null&&(o<i||o===void 0&&i>=i)&&(o=i)}),o},extent:(e,t,n)=>{let o,r;return n.forEach(i=>{const s=i.getValue(e);s!=null&&(o===void 0?s>=s&&(o=r=s):(o>s&&(o=s),r<s&&(r=s)))}),[o,r]},mean:(e,t)=>{let n=0,o=0;if(t.forEach(r=>{let i=r.getValue(e);i!=null&&(i=+i)>=i&&(++n,o+=i)}),n)return o/n},median:(e,t)=>{if(!t.length)return;const n=t.map(i=>i.getValue(e));if(!T0(n))return;if(n.length===1)return n[0];const o=Math.floor(n.length/2),r=n.sort((i,s)=>i-s);return n.length%2!==0?r[o]:(r[o-1]+r[o])/2},unique:(e,t)=>Array.from(new Set(t.map(n=>n.getValue(e))).values()),uniqueCount:(e,t)=>new Set(t.map(n=>n.getValue(e))).size,count:(e,t)=>t.length},D0={getDefaultColumnDef:()=>({aggregatedCell:e=>{var t,n;return(t=(n=e.getValue())==null||n.toString==null?void 0:n.toString())!=null?t:null},aggregationFn:"auto"}),getInitialState:e=>({grouping:[],...e}),getDefaultOptions:e=>({onGroupingChange:de("grouping",e),groupedColumnMode:"reorder"}),createColumn:(e,t)=>{e.toggleGrouping=()=>{t.setGrouping(n=>n!=null&&n.includes(e.id)?n.filter(o=>o!==e.id):[...n??[],e.id])},e.getCanGroup=()=>{var n,o;return((n=e.columnDef.enableGrouping)!=null?n:!0)&&((o=t.options.enableGrouping)!=null?o:!0)&&(!!e.accessorFn||!!e.columnDef.getGroupingValue)},e.getIsGrouped=()=>{var n;return(n=t.getState().grouping)==null?void 0:n.includes(e.id)},e.getGroupedIndex=()=>{var n;return(n=t.getState().grouping)==null?void 0:n.indexOf(e.id)},e.getToggleGroupingHandler=()=>{const n=e.getCanGroup();return()=>{n&&e.toggleGrouping()}},e.getAutoAggregationFn=()=>{const n=t.getCoreRowModel().flatRows[0],o=n?.getValue(e.id);if(typeof o=="number")return dr.sum;if(Object.prototype.toString.call(o)==="[object Date]")return dr.extent},e.getAggregationFn=()=>{var n,o;if(!e)throw new Error;return vn(e.columnDef.aggregationFn)?e.columnDef.aggregationFn:e.columnDef.aggregationFn==="auto"?e.getAutoAggregationFn():(n=(o=t.options.aggregationFns)==null?void 0:o[e.columnDef.aggregationFn])!=null?n:dr[e.columnDef.aggregationFn]}},createTable:e=>{e.setGrouping=t=>e.options.onGroupingChange==null?void 0:e.options.onGroupingChange(t),e.resetGrouping=t=>{var n,o;e.setGrouping(t?[]:(n=(o=e.initialState)==null?void 0:o.grouping)!=null?n:[])},e.getPreGroupedRowModel=()=>e.getFilteredRowModel(),e.getGroupedRowModel=()=>(!e._getGroupedRowModel&&e.options.getGroupedRowModel&&(e._getGroupedRowModel=e.options.getGroupedRowModel(e)),e.options.manualGrouping||!e._getGroupedRowModel?e.getPreGroupedRowModel():e._getGroupedRowModel())},createRow:(e,t)=>{e.getIsGrouped=()=>!!e.groupingColumnId,e.getGroupingValue=n=>{if(e._groupingValuesCache.hasOwnProperty(n))return e._groupingValuesCache[n];const o=t.getColumn(n);return o!=null&&o.columnDef.getGroupingValue?(e._groupingValuesCache[n]=o.columnDef.getGroupingValue(e.original),e._groupingValuesCache[n]):e.getValue(n)},e._groupingValuesCache={}},createCell:(e,t,n,o)=>{e.getIsGrouped=()=>t.getIsGrouped()&&t.id===n.groupingColumnId,e.getIsPlaceholder=()=>!e.getIsGrouped()&&t.getIsGrouped(),e.getIsAggregated=()=>{var r;return!e.getIsGrouped()&&!e.getIsPlaceholder()&&!!((r=n.subRows)!=null&&r.length)}}};function F0(e,t,n){if(!(t!=null&&t.length)||!n)return e;const o=e.filter(i=>!t.includes(i.id));return n==="remove"?o:[...t.map(i=>e.find(s=>s.id===i)).filter(Boolean),...o]}const A0={getInitialState:e=>({columnOrder:[],...e}),getDefaultOptions:e=>({onColumnOrderChange:de("columnOrder",e)}),createColumn:(e,t)=>{e.getIndex=A(n=>[zt(t,n)],n=>n.findIndex(o=>o.id===e.id),I(t.options,"debugColumns","getIndex")),e.getIsFirstColumn=n=>{var o;return((o=zt(t,n)[0])==null?void 0:o.id)===e.id},e.getIsLastColumn=n=>{var o;const r=zt(t,n);return((o=r[r.length-1])==null?void 0:o.id)===e.id}},createTable:e=>{e.setColumnOrder=t=>e.options.onColumnOrderChange==null?void 0:e.options.onColumnOrderChange(t),e.resetColumnOrder=t=>{var n;e.setColumnOrder(t?[]:(n=e.initialState.columnOrder)!=null?n:[])},e._getOrderColumnsFn=A(()=>[e.getState().columnOrder,e.getState().grouping,e.options.groupedColumnMode],(t,n,o)=>r=>{let i=[];if(!(t!=null&&t.length))i=r;else{const s=[...t],a=[...r];for(;a.length&&s.length;){const l=s.shift(),c=a.findIndex(d=>d.id===l);c>-1&&i.push(a.splice(c,1)[0])}i=[...i,...a]}return F0(i,n,o)},I(e.options,"debugTable","_getOrderColumnsFn"))}},fr=()=>({left:[],right:[]}),I0={getInitialState:e=>({columnPinning:fr(),...e}),getDefaultOptions:e=>({onColumnPinningChange:de("columnPinning",e)}),createColumn:(e,t)=>{e.pin=n=>{const o=e.getLeafColumns().map(r=>r.id).filter(Boolean);t.setColumnPinning(r=>{var i,s;if(n==="right"){var a,l;return{left:((a=r?.left)!=null?a:[]).filter(u=>!(o!=null&&o.includes(u))),right:[...((l=r?.right)!=null?l:[]).filter(u=>!(o!=null&&o.includes(u))),...o]}}if(n==="left"){var c,d;return{left:[...((c=r?.left)!=null?c:[]).filter(u=>!(o!=null&&o.includes(u))),...o],right:((d=r?.right)!=null?d:[]).filter(u=>!(o!=null&&o.includes(u)))}}return{left:((i=r?.left)!=null?i:[]).filter(u=>!(o!=null&&o.includes(u))),right:((s=r?.right)!=null?s:[]).filter(u=>!(o!=null&&o.includes(u)))}})},e.getCanPin=()=>e.getLeafColumns().some(o=>{var r,i,s;return((r=o.columnDef.enablePinning)!=null?r:!0)&&((i=(s=t.options.enableColumnPinning)!=null?s:t.options.enablePinning)!=null?i:!0)}),e.getIsPinned=()=>{const n=e.getLeafColumns().map(a=>a.id),{left:o,right:r}=t.getState().columnPinning,i=n.some(a=>o?.includes(a)),s=n.some(a=>r?.includes(a));return i?"left":s?"right":!1},e.getPinnedIndex=()=>{var n,o;const r=e.getIsPinned();return r?(n=(o=t.getState().columnPinning)==null||(o=o[r])==null?void 0:o.indexOf(e.id))!=null?n:-1:0}},createRow:(e,t)=>{e.getCenterVisibleCells=A(()=>[e._getAllVisibleCells(),t.getState().columnPinning.left,t.getState().columnPinning.right],(n,o,r)=>{const i=[...o??[],...r??[]];return n.filter(s=>!i.includes(s.column.id))},I(t.options,"debugRows","getCenterVisibleCells")),e.getLeftVisibleCells=A(()=>[e._getAllVisibleCells(),t.getState().columnPinning.left],(n,o)=>(o??[]).map(i=>n.find(s=>s.column.id===i)).filter(Boolean).map(i=>({...i,position:"left"})),I(t.options,"debugRows","getLeftVisibleCells")),e.getRightVisibleCells=A(()=>[e._getAllVisibleCells(),t.getState().columnPinning.right],(n,o)=>(o??[]).map(i=>n.find(s=>s.column.id===i)).filter(Boolean).map(i=>({...i,position:"right"})),I(t.options,"debugRows","getRightVisibleCells"))},createTable:e=>{e.setColumnPinning=t=>e.options.onColumnPinningChange==null?void 0:e.options.onColumnPinningChange(t),e.resetColumnPinning=t=>{var n,o;return e.setColumnPinning(t?fr():(n=(o=e.initialState)==null?void 0:o.columnPinning)!=null?n:fr())},e.getIsSomeColumnsPinned=t=>{var n;const o=e.getState().columnPinning;if(!t){var r,i;return!!((r=o.left)!=null&&r.length||(i=o.right)!=null&&i.length)}return!!((n=o[t])!=null&&n.length)},e.getLeftLeafColumns=A(()=>[e.getAllLeafColumns(),e.getState().columnPinning.left],(t,n)=>(n??[]).map(o=>t.find(r=>r.id===o)).filter(Boolean),I(e.options,"debugColumns","getLeftLeafColumns")),e.getRightLeafColumns=A(()=>[e.getAllLeafColumns(),e.getState().columnPinning.right],(t,n)=>(n??[]).map(o=>t.find(r=>r.id===o)).filter(Boolean),I(e.options,"debugColumns","getRightLeafColumns")),e.getCenterLeafColumns=A(()=>[e.getAllLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,o)=>{const r=[...n??[],...o??[]];return t.filter(i=>!r.includes(i.id))},I(e.options,"debugColumns","getCenterLeafColumns"))}};function L0(e){return e||(typeof document<"u"?document:null)}const wn={size:150,minSize:20,maxSize:Number.MAX_SAFE_INTEGER},hr=()=>({startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,isResizingColumn:!1,columnSizingStart:[]}),R0={getDefaultColumnDef:()=>wn,getInitialState:e=>({columnSizing:{},columnSizingInfo:hr(),...e}),getDefaultOptions:e=>({columnResizeMode:"onEnd",columnResizeDirection:"ltr",onColumnSizingChange:de("columnSizing",e),onColumnSizingInfoChange:de("columnSizingInfo",e)}),createColumn:(e,t)=>{e.getSize=()=>{var n,o,r;const i=t.getState().columnSizing[e.id];return Math.min(Math.max((n=e.columnDef.minSize)!=null?n:wn.minSize,(o=i??e.columnDef.size)!=null?o:wn.size),(r=e.columnDef.maxSize)!=null?r:wn.maxSize)},e.getStart=A(n=>[n,zt(t,n),t.getState().columnSizing],(n,o)=>o.slice(0,e.getIndex(n)).reduce((r,i)=>r+i.getSize(),0),I(t.options,"debugColumns","getStart")),e.getAfter=A(n=>[n,zt(t,n),t.getState().columnSizing],(n,o)=>o.slice(e.getIndex(n)+1).reduce((r,i)=>r+i.getSize(),0),I(t.options,"debugColumns","getAfter")),e.resetSize=()=>{t.setColumnSizing(n=>{let{[e.id]:o,...r}=n;return r})},e.getCanResize=()=>{var n,o;return((n=e.columnDef.enableResizing)!=null?n:!0)&&((o=t.options.enableColumnResizing)!=null?o:!0)},e.getIsResizing=()=>t.getState().columnSizingInfo.isResizingColumn===e.id},createHeader:(e,t)=>{e.getSize=()=>{let n=0;const o=r=>{if(r.subHeaders.length)r.subHeaders.forEach(o);else{var i;n+=(i=r.column.getSize())!=null?i:0}};return o(e),n},e.getStart=()=>{if(e.index>0){const n=e.headerGroup.headers[e.index-1];return n.getStart()+n.getSize()}return 0},e.getResizeHandler=n=>{const o=t.getColumn(e.column.id),r=o?.getCanResize();return i=>{if(!o||!r||(i.persist==null||i.persist(),mr(i)&&i.touches&&i.touches.length>1))return;const s=e.getSize(),a=e?e.getLeafHeaders().map(w=>[w.column.id,w.column.getSize()]):[[o.id,o.getSize()]],l=mr(i)?Math.round(i.touches[0].clientX):i.clientX,c={},d=(w,T)=>{typeof T=="number"&&(t.setColumnSizingInfo(C=>{var M,x;const P=t.options.columnResizeDirection==="rtl"?-1:1,V=(T-((M=C?.startOffset)!=null?M:0))*P,$=Math.max(V/((x=C?.startSize)!=null?x:0),-.999999);return C.columnSizingStart.forEach(F=>{let[D,_]=F;c[D]=Math.round(Math.max(_+_*$,0)*100)/100}),{...C,deltaOffset:V,deltaPercentage:$}}),(t.options.columnResizeMode==="onChange"||w==="end")&&t.setColumnSizing(C=>({...C,...c})))},u=w=>d("move",w),h=w=>{d("end",w),t.setColumnSizingInfo(T=>({...T,isResizingColumn:!1,startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,columnSizingStart:[]}))},f=L0(n),v={moveHandler:w=>u(w.clientX),upHandler:w=>{f?.removeEventListener("mousemove",v.moveHandler),f?.removeEventListener("mouseup",v.upHandler),h(w.clientX)}},y={moveHandler:w=>(w.cancelable&&(w.preventDefault(),w.stopPropagation()),u(w.touches[0].clientX),!1),upHandler:w=>{var T;f?.removeEventListener("touchmove",y.moveHandler),f?.removeEventListener("touchend",y.upHandler),w.cancelable&&(w.preventDefault(),w.stopPropagation()),h((T=w.touches[0])==null?void 0:T.clientX)}},b=_0()?{passive:!1}:!1;mr(i)?(f?.addEventListener("touchmove",y.moveHandler,b),f?.addEventListener("touchend",y.upHandler,b)):(f?.addEventListener("mousemove",v.moveHandler,b),f?.addEventListener("mouseup",v.upHandler,b)),t.setColumnSizingInfo(w=>({...w,startOffset:l,startSize:s,deltaOffset:0,deltaPercentage:0,columnSizingStart:a,isResizingColumn:o.id}))}}},createTable:e=>{e.setColumnSizing=t=>e.options.onColumnSizingChange==null?void 0:e.options.onColumnSizingChange(t),e.setColumnSizingInfo=t=>e.options.onColumnSizingInfoChange==null?void 0:e.options.onColumnSizingInfoChange(t),e.resetColumnSizing=t=>{var n;e.setColumnSizing(t?{}:(n=e.initialState.columnSizing)!=null?n:{})},e.resetHeaderSizeInfo=t=>{var n;e.setColumnSizingInfo(t?hr():(n=e.initialState.columnSizingInfo)!=null?n:hr())},e.getTotalSize=()=>{var t,n;return(t=(n=e.getHeaderGroups()[0])==null?void 0:n.headers.reduce((o,r)=>o+r.getSize(),0))!=null?t:0},e.getLeftTotalSize=()=>{var t,n;return(t=(n=e.getLeftHeaderGroups()[0])==null?void 0:n.headers.reduce((o,r)=>o+r.getSize(),0))!=null?t:0},e.getCenterTotalSize=()=>{var t,n;return(t=(n=e.getCenterHeaderGroups()[0])==null?void 0:n.headers.reduce((o,r)=>o+r.getSize(),0))!=null?t:0},e.getRightTotalSize=()=>{var t,n;return(t=(n=e.getRightHeaderGroups()[0])==null?void 0:n.headers.reduce((o,r)=>o+r.getSize(),0))!=null?t:0}}};let bn=null;function _0(){if(typeof bn=="boolean")return bn;let e=!1;try{const t={get passive(){return e=!0,!1}},n=()=>{};window.addEventListener("test",n,t),window.removeEventListener("test",n)}catch{e=!1}return bn=e,bn}function mr(e){return e.type==="touchstart"}const B0={getInitialState:e=>({columnVisibility:{},...e}),getDefaultOptions:e=>({onColumnVisibilityChange:de("columnVisibility",e)}),createColumn:(e,t)=>{e.toggleVisibility=n=>{e.getCanHide()&&t.setColumnVisibility(o=>({...o,[e.id]:n??!e.getIsVisible()}))},e.getIsVisible=()=>{var n,o;const r=e.columns;return(n=r.length?r.some(i=>i.getIsVisible()):(o=t.getState().columnVisibility)==null?void 0:o[e.id])!=null?n:!0},e.getCanHide=()=>{var n,o;return((n=e.columnDef.enableHiding)!=null?n:!0)&&((o=t.options.enableHiding)!=null?o:!0)},e.getToggleVisibilityHandler=()=>n=>{e.toggleVisibility==null||e.toggleVisibility(n.target.checked)}},createRow:(e,t)=>{e._getAllVisibleCells=A(()=>[e.getAllCells(),t.getState().columnVisibility],n=>n.filter(o=>o.column.getIsVisible()),I(t.options,"debugRows","_getAllVisibleCells")),e.getVisibleCells=A(()=>[e.getLeftVisibleCells(),e.getCenterVisibleCells(),e.getRightVisibleCells()],(n,o,r)=>[...n,...o,...r],I(t.options,"debugRows","getVisibleCells"))},createTable:e=>{const t=(n,o)=>A(()=>[o(),o().filter(r=>r.getIsVisible()).map(r=>r.id).join("_")],r=>r.filter(i=>i.getIsVisible==null?void 0:i.getIsVisible()),I(e.options,"debugColumns",n));e.getVisibleFlatColumns=t("getVisibleFlatColumns",()=>e.getAllFlatColumns()),e.getVisibleLeafColumns=t("getVisibleLeafColumns",()=>e.getAllLeafColumns()),e.getLeftVisibleLeafColumns=t("getLeftVisibleLeafColumns",()=>e.getLeftLeafColumns()),e.getRightVisibleLeafColumns=t("getRightVisibleLeafColumns",()=>e.getRightLeafColumns()),e.getCenterVisibleLeafColumns=t("getCenterVisibleLeafColumns",()=>e.getCenterLeafColumns()),e.setColumnVisibility=n=>e.options.onColumnVisibilityChange==null?void 0:e.options.onColumnVisibilityChange(n),e.resetColumnVisibility=n=>{var o;e.setColumnVisibility(n?{}:(o=e.initialState.columnVisibility)!=null?o:{})},e.toggleAllColumnsVisible=n=>{var o;n=(o=n)!=null?o:!e.getIsAllColumnsVisible(),e.setColumnVisibility(e.getAllLeafColumns().reduce((r,i)=>({...r,[i.id]:n||!(i.getCanHide!=null&&i.getCanHide())}),{}))},e.getIsAllColumnsVisible=()=>!e.getAllLeafColumns().some(n=>!(n.getIsVisible!=null&&n.getIsVisible())),e.getIsSomeColumnsVisible=()=>e.getAllLeafColumns().some(n=>n.getIsVisible==null?void 0:n.getIsVisible()),e.getToggleAllColumnsVisibilityHandler=()=>n=>{var o;e.toggleAllColumnsVisible((o=n.target)==null?void 0:o.checked)}}};function zt(e,t){return t?t==="center"?e.getCenterVisibleLeafColumns():t==="left"?e.getLeftVisibleLeafColumns():e.getRightVisibleLeafColumns():e.getVisibleLeafColumns()}const N0={createTable:e=>{e._getGlobalFacetedRowModel=e.options.getFacetedRowModel&&e.options.getFacetedRowModel(e,"__global__"),e.getGlobalFacetedRowModel=()=>e.options.manualFiltering||!e._getGlobalFacetedRowModel?e.getPreFilteredRowModel():e._getGlobalFacetedRowModel(),e._getGlobalFacetedUniqueValues=e.options.getFacetedUniqueValues&&e.options.getFacetedUniqueValues(e,"__global__"),e.getGlobalFacetedUniqueValues=()=>e._getGlobalFacetedUniqueValues?e._getGlobalFacetedUniqueValues():new Map,e._getGlobalFacetedMinMaxValues=e.options.getFacetedMinMaxValues&&e.options.getFacetedMinMaxValues(e,"__global__"),e.getGlobalFacetedMinMaxValues=()=>{if(e._getGlobalFacetedMinMaxValues)return e._getGlobalFacetedMinMaxValues()}}},z0={getInitialState:e=>({globalFilter:void 0,...e}),getDefaultOptions:e=>({onGlobalFilterChange:de("globalFilter",e),globalFilterFn:"auto",getColumnCanGlobalFilter:t=>{var n;const o=(n=e.getCoreRowModel().flatRows[0])==null||(n=n._getAllCellsByColumnId()[t.id])==null?void 0:n.getValue();return typeof o=="string"||typeof o=="number"}}),createColumn:(e,t)=>{e.getCanGlobalFilter=()=>{var n,o,r,i;return((n=e.columnDef.enableGlobalFilter)!=null?n:!0)&&((o=t.options.enableGlobalFilter)!=null?o:!0)&&((r=t.options.enableFilters)!=null?r:!0)&&((i=t.options.getColumnCanGlobalFilter==null?void 0:t.options.getColumnCanGlobalFilter(e))!=null?i:!0)&&!!e.accessorFn}},createTable:e=>{e.getGlobalAutoFilterFn=()=>Ae.includesString,e.getGlobalFilterFn=()=>{var t,n;const{globalFilterFn:o}=e.options;return vn(o)?o:o==="auto"?e.getGlobalAutoFilterFn():(t=(n=e.options.filterFns)==null?void 0:n[o])!=null?t:Ae[o]},e.setGlobalFilter=t=>{e.options.onGlobalFilterChange==null||e.options.onGlobalFilterChange(t)},e.resetGlobalFilter=t=>{e.setGlobalFilter(t?void 0:e.initialState.globalFilter)}}},O0={getInitialState:e=>({expanded:{},...e}),getDefaultOptions:e=>({onExpandedChange:de("expanded",e),paginateExpandedRows:!0}),createTable:e=>{let t=!1,n=!1;e._autoResetExpanded=()=>{var o,r;if(!t){e._queue(()=>{t=!0});return}if((o=(r=e.options.autoResetAll)!=null?r:e.options.autoResetExpanded)!=null?o:!e.options.manualExpanding){if(n)return;n=!0,e._queue(()=>{e.resetExpanded(),n=!1})}},e.setExpanded=o=>e.options.onExpandedChange==null?void 0:e.options.onExpandedChange(o),e.toggleAllRowsExpanded=o=>{o??!e.getIsAllRowsExpanded()?e.setExpanded(!0):e.setExpanded({})},e.resetExpanded=o=>{var r,i;e.setExpanded(o?{}:(r=(i=e.initialState)==null?void 0:i.expanded)!=null?r:{})},e.getCanSomeRowsExpand=()=>e.getPrePaginationRowModel().flatRows.some(o=>o.getCanExpand()),e.getToggleAllRowsExpandedHandler=()=>o=>{o.persist==null||o.persist(),e.toggleAllRowsExpanded()},e.getIsSomeRowsExpanded=()=>{const o=e.getState().expanded;return o===!0||Object.values(o).some(Boolean)},e.getIsAllRowsExpanded=()=>{const o=e.getState().expanded;return typeof o=="boolean"?o===!0:!(!Object.keys(o).length||e.getRowModel().flatRows.some(r=>!r.getIsExpanded()))},e.getExpandedDepth=()=>{let o=0;return(e.getState().expanded===!0?Object.keys(e.getRowModel().rowsById):Object.keys(e.getState().expanded)).forEach(i=>{const s=i.split(".");o=Math.max(o,s.length)}),o},e.getPreExpandedRowModel=()=>e.getSortedRowModel(),e.getExpandedRowModel=()=>(!e._getExpandedRowModel&&e.options.getExpandedRowModel&&(e._getExpandedRowModel=e.options.getExpandedRowModel(e)),e.options.manualExpanding||!e._getExpandedRowModel?e.getPreExpandedRowModel():e._getExpandedRowModel())},createRow:(e,t)=>{e.toggleExpanded=n=>{t.setExpanded(o=>{var r;const i=o===!0?!0:!!(o!=null&&o[e.id]);let s={};if(o===!0?Object.keys(t.getRowModel().rowsById).forEach(a=>{s[a]=!0}):s=o,n=(r=n)!=null?r:!i,!i&&n)return{...s,[e.id]:!0};if(i&&!n){const{[e.id]:a,...l}=s;return l}return o})},e.getIsExpanded=()=>{var n;const o=t.getState().expanded;return!!((n=t.options.getIsRowExpanded==null?void 0:t.options.getIsRowExpanded(e))!=null?n:o===!0||o?.[e.id])},e.getCanExpand=()=>{var n,o,r;return(n=t.options.getRowCanExpand==null?void 0:t.options.getRowCanExpand(e))!=null?n:((o=t.options.enableExpanding)!=null?o:!0)&&!!((r=e.subRows)!=null&&r.length)},e.getIsAllParentsExpanded=()=>{let n=!0,o=e;for(;n&&o.parentId;)o=t.getRow(o.parentId,!0),n=o.getIsExpanded();return n},e.getToggleExpandedHandler=()=>{const n=e.getCanExpand();return()=>{n&&e.toggleExpanded()}}}},pr=0,gr=10,vr=()=>({pageIndex:pr,pageSize:gr}),H0={getInitialState:e=>({...e,pagination:{...vr(),...e?.pagination}}),getDefaultOptions:e=>({onPaginationChange:de("pagination",e)}),createTable:e=>{let t=!1,n=!1;e._autoResetPageIndex=()=>{var o,r;if(!t){e._queue(()=>{t=!0});return}if((o=(r=e.options.autoResetAll)!=null?r:e.options.autoResetPageIndex)!=null?o:!e.options.manualPagination){if(n)return;n=!0,e._queue(()=>{e.resetPageIndex(),n=!1})}},e.setPagination=o=>{const r=i=>He(o,i);return e.options.onPaginationChange==null?void 0:e.options.onPaginationChange(r)},e.resetPagination=o=>{var r;e.setPagination(o?vr():(r=e.initialState.pagination)!=null?r:vr())},e.setPageIndex=o=>{e.setPagination(r=>{let i=He(o,r.pageIndex);const s=typeof e.options.pageCount>"u"||e.options.pageCount===-1?Number.MAX_SAFE_INTEGER:e.options.pageCount-1;return i=Math.max(0,Math.min(i,s)),{...r,pageIndex:i}})},e.resetPageIndex=o=>{var r,i;e.setPageIndex(o?pr:(r=(i=e.initialState)==null||(i=i.pagination)==null?void 0:i.pageIndex)!=null?r:pr)},e.resetPageSize=o=>{var r,i;e.setPageSize(o?gr:(r=(i=e.initialState)==null||(i=i.pagination)==null?void 0:i.pageSize)!=null?r:gr)},e.setPageSize=o=>{e.setPagination(r=>{const i=Math.max(1,He(o,r.pageSize)),s=r.pageSize*r.pageIndex,a=Math.floor(s/i);return{...r,pageIndex:a,pageSize:i}})},e.setPageCount=o=>e.setPagination(r=>{var i;let s=He(o,(i=e.options.pageCount)!=null?i:-1);return typeof s=="number"&&(s=Math.max(-1,s)),{...r,pageCount:s}}),e.getPageOptions=A(()=>[e.getPageCount()],o=>{let r=[];return o&&o>0&&(r=[...new Array(o)].fill(null).map((i,s)=>s)),r},I(e.options,"debugTable","getPageOptions")),e.getCanPreviousPage=()=>e.getState().pagination.pageIndex>0,e.getCanNextPage=()=>{const{pageIndex:o}=e.getState().pagination,r=e.getPageCount();return r===-1?!0:r===0?!1:o<r-1},e.previousPage=()=>e.setPageIndex(o=>o-1),e.nextPage=()=>e.setPageIndex(o=>o+1),e.firstPage=()=>e.setPageIndex(0),e.lastPage=()=>e.setPageIndex(e.getPageCount()-1),e.getPrePaginationRowModel=()=>e.getExpandedRowModel(),e.getPaginationRowModel=()=>(!e._getPaginationRowModel&&e.options.getPaginationRowModel&&(e._getPaginationRowModel=e.options.getPaginationRowModel(e)),e.options.manualPagination||!e._getPaginationRowModel?e.getPrePaginationRowModel():e._getPaginationRowModel()),e.getPageCount=()=>{var o;return(o=e.options.pageCount)!=null?o:Math.ceil(e.getRowCount()/e.getState().pagination.pageSize)},e.getRowCount=()=>{var o;return(o=e.options.rowCount)!=null?o:e.getPrePaginationRowModel().rows.length}}},yr=()=>({top:[],bottom:[]}),j0={getInitialState:e=>({rowPinning:yr(),...e}),getDefaultOptions:e=>({onRowPinningChange:de("rowPinning",e)}),createRow:(e,t)=>{e.pin=(n,o,r)=>{const i=o?e.getLeafRows().map(l=>{let{id:c}=l;return c}):[],s=r?e.getParentRows().map(l=>{let{id:c}=l;return c}):[],a=new Set([...s,e.id,...i]);t.setRowPinning(l=>{var c,d;if(n==="bottom"){var u,h;return{top:((u=l?.top)!=null?u:[]).filter(y=>!(a!=null&&a.has(y))),bottom:[...((h=l?.bottom)!=null?h:[]).filter(y=>!(a!=null&&a.has(y))),...Array.from(a)]}}if(n==="top"){var f,v;return{top:[...((f=l?.top)!=null?f:[]).filter(y=>!(a!=null&&a.has(y))),...Array.from(a)],bottom:((v=l?.bottom)!=null?v:[]).filter(y=>!(a!=null&&a.has(y)))}}return{top:((c=l?.top)!=null?c:[]).filter(y=>!(a!=null&&a.has(y))),bottom:((d=l?.bottom)!=null?d:[]).filter(y=>!(a!=null&&a.has(y)))}})},e.getCanPin=()=>{var n;const{enableRowPinning:o,enablePinning:r}=t.options;return typeof o=="function"?o(e):(n=o??r)!=null?n:!0},e.getIsPinned=()=>{const n=[e.id],{top:o,bottom:r}=t.getState().rowPinning,i=n.some(a=>o?.includes(a)),s=n.some(a=>r?.includes(a));return i?"top":s?"bottom":!1},e.getPinnedIndex=()=>{var n,o;const r=e.getIsPinned();if(!r)return-1;const i=(n=r==="top"?t.getTopRows():t.getBottomRows())==null?void 0:n.map(s=>{let{id:a}=s;return a});return(o=i?.indexOf(e.id))!=null?o:-1}},createTable:e=>{e.setRowPinning=t=>e.options.onRowPinningChange==null?void 0:e.options.onRowPinningChange(t),e.resetRowPinning=t=>{var n,o;return e.setRowPinning(t?yr():(n=(o=e.initialState)==null?void 0:o.rowPinning)!=null?n:yr())},e.getIsSomeRowsPinned=t=>{var n;const o=e.getState().rowPinning;if(!t){var r,i;return!!((r=o.top)!=null&&r.length||(i=o.bottom)!=null&&i.length)}return!!((n=o[t])!=null&&n.length)},e._getPinnedRows=(t,n,o)=>{var r;return((r=e.options.keepPinnedRows)==null||r?(n??[]).map(s=>{const a=e.getRow(s,!0);return a.getIsAllParentsExpanded()?a:null}):(n??[]).map(s=>t.find(a=>a.id===s))).filter(Boolean).map(s=>({...s,position:o}))},e.getTopRows=A(()=>[e.getRowModel().rows,e.getState().rowPinning.top],(t,n)=>e._getPinnedRows(t,n,"top"),I(e.options,"debugRows","getTopRows")),e.getBottomRows=A(()=>[e.getRowModel().rows,e.getState().rowPinning.bottom],(t,n)=>e._getPinnedRows(t,n,"bottom"),I(e.options,"debugRows","getBottomRows")),e.getCenterRows=A(()=>[e.getRowModel().rows,e.getState().rowPinning.top,e.getState().rowPinning.bottom],(t,n,o)=>{const r=new Set([...n??[],...o??[]]);return t.filter(i=>!r.has(i.id))},I(e.options,"debugRows","getCenterRows"))}},G0={getInitialState:e=>({rowSelection:{},...e}),getDefaultOptions:e=>({onRowSelectionChange:de("rowSelection",e),enableRowSelection:!0,enableMultiRowSelection:!0,enableSubRowSelection:!0}),createTable:e=>{e.setRowSelection=t=>e.options.onRowSelectionChange==null?void 0:e.options.onRowSelectionChange(t),e.resetRowSelection=t=>{var n;return e.setRowSelection(t?{}:(n=e.initialState.rowSelection)!=null?n:{})},e.toggleAllRowsSelected=t=>{e.setRowSelection(n=>{t=typeof t<"u"?t:!e.getIsAllRowsSelected();const o={...n},r=e.getPreGroupedRowModel().flatRows;return t?r.forEach(i=>{i.getCanSelect()&&(o[i.id]=!0)}):r.forEach(i=>{delete o[i.id]}),o})},e.toggleAllPageRowsSelected=t=>e.setRowSelection(n=>{const o=typeof t<"u"?t:!e.getIsAllPageRowsSelected(),r={...n};return e.getRowModel().rows.forEach(i=>{wr(r,i.id,o,!0,e)}),r}),e.getPreSelectedRowModel=()=>e.getCoreRowModel(),e.getSelectedRowModel=A(()=>[e.getState().rowSelection,e.getCoreRowModel()],(t,n)=>Object.keys(t).length?br(e,n):{rows:[],flatRows:[],rowsById:{}},I(e.options,"debugTable","getSelectedRowModel")),e.getFilteredSelectedRowModel=A(()=>[e.getState().rowSelection,e.getFilteredRowModel()],(t,n)=>Object.keys(t).length?br(e,n):{rows:[],flatRows:[],rowsById:{}},I(e.options,"debugTable","getFilteredSelectedRowModel")),e.getGroupedSelectedRowModel=A(()=>[e.getState().rowSelection,e.getSortedRowModel()],(t,n)=>Object.keys(t).length?br(e,n):{rows:[],flatRows:[],rowsById:{}},I(e.options,"debugTable","getGroupedSelectedRowModel")),e.getIsAllRowsSelected=()=>{const t=e.getFilteredRowModel().flatRows,{rowSelection:n}=e.getState();let o=!!(t.length&&Object.keys(n).length);return o&&t.some(r=>r.getCanSelect()&&!n[r.id])&&(o=!1),o},e.getIsAllPageRowsSelected=()=>{const t=e.getPaginationRowModel().flatRows.filter(r=>r.getCanSelect()),{rowSelection:n}=e.getState();let o=!!t.length;return o&&t.some(r=>!n[r.id])&&(o=!1),o},e.getIsSomeRowsSelected=()=>{var t;const n=Object.keys((t=e.getState().rowSelection)!=null?t:{}).length;return n>0&&n<e.getFilteredRowModel().flatRows.length},e.getIsSomePageRowsSelected=()=>{const t=e.getPaginationRowModel().flatRows;return e.getIsAllPageRowsSelected()?!1:t.filter(n=>n.getCanSelect()).some(n=>n.getIsSelected()||n.getIsSomeSelected())},e.getToggleAllRowsSelectedHandler=()=>t=>{e.toggleAllRowsSelected(t.target.checked)},e.getToggleAllPageRowsSelectedHandler=()=>t=>{e.toggleAllPageRowsSelected(t.target.checked)}},createRow:(e,t)=>{e.toggleSelected=(n,o)=>{const r=e.getIsSelected();t.setRowSelection(i=>{var s;if(n=typeof n<"u"?n:!r,e.getCanSelect()&&r===n)return i;const a={...i};return wr(a,e.id,n,(s=o?.selectChildren)!=null?s:!0,t),a})},e.getIsSelected=()=>{const{rowSelection:n}=t.getState();return xr(e,n)},e.getIsSomeSelected=()=>{const{rowSelection:n}=t.getState();return Sr(e,n)==="some"},e.getIsAllSubRowsSelected=()=>{const{rowSelection:n}=t.getState();return Sr(e,n)==="all"},e.getCanSelect=()=>{var n;return typeof t.options.enableRowSelection=="function"?t.options.enableRowSelection(e):(n=t.options.enableRowSelection)!=null?n:!0},e.getCanSelectSubRows=()=>{var n;return typeof t.options.enableSubRowSelection=="function"?t.options.enableSubRowSelection(e):(n=t.options.enableSubRowSelection)!=null?n:!0},e.getCanMultiSelect=()=>{var n;return typeof t.options.enableMultiRowSelection=="function"?t.options.enableMultiRowSelection(e):(n=t.options.enableMultiRowSelection)!=null?n:!0},e.getToggleSelectedHandler=()=>{const n=e.getCanSelect();return o=>{var r;n&&e.toggleSelected((r=o.target)==null?void 0:r.checked)}}}},wr=(e,t,n,o,r)=>{var i;const s=r.getRow(t,!0);n?(s.getCanMultiSelect()||Object.keys(e).forEach(a=>delete e[a]),s.getCanSelect()&&(e[t]=!0)):delete e[t],o&&(i=s.subRows)!=null&&i.length&&s.getCanSelectSubRows()&&s.subRows.forEach(a=>wr(e,a.id,n,o,r))};function br(e,t){const n=e.getState().rowSelection,o=[],r={},i=function(s,a){return s.map(l=>{var c;const d=xr(l,n);if(d&&(o.push(l),r[l.id]=l),(c=l.subRows)!=null&&c.length&&(l={...l,subRows:i(l.subRows)}),d)return l}).filter(Boolean)};return{rows:i(t.rows),flatRows:o,rowsById:r}}function xr(e,t){var n;return(n=t[e.id])!=null?n:!1}function Sr(e,t,n){var o;if(!((o=e.subRows)!=null&&o.length))return!1;let r=!0,i=!1;return e.subRows.forEach(s=>{if(!(i&&!r)&&(s.getCanSelect()&&(xr(s,t)?i=!0:r=!1),s.subRows&&s.subRows.length)){const a=Sr(s,t);a==="all"?i=!0:(a==="some"&&(i=!0),r=!1)}}),r?"all":i?"some":!1}const Cr=/([0-9]+)/gm,U0=(e,t,n)=>Ol(je(e.getValue(n)).toLowerCase(),je(t.getValue(n)).toLowerCase()),K0=(e,t,n)=>Ol(je(e.getValue(n)),je(t.getValue(n))),W0=(e,t,n)=>Tr(je(e.getValue(n)).toLowerCase(),je(t.getValue(n)).toLowerCase()),q0=(e,t,n)=>Tr(je(e.getValue(n)),je(t.getValue(n))),Y0=(e,t,n)=>{const o=e.getValue(n),r=t.getValue(n);return o>r?1:o<r?-1:0},X0=(e,t,n)=>Tr(e.getValue(n),t.getValue(n));function Tr(e,t){return e===t?0:e>t?1:-1}function je(e){return typeof e=="number"?isNaN(e)||e===1/0||e===-1/0?"":String(e):typeof e=="string"?e:""}function Ol(e,t){const n=e.split(Cr).filter(Boolean),o=t.split(Cr).filter(Boolean);for(;n.length&&o.length;){const r=n.shift(),i=o.shift(),s=parseInt(r,10),a=parseInt(i,10),l=[s,a].sort();if(isNaN(l[0])){if(r>i)return 1;if(i>r)return-1;continue}if(isNaN(l[1]))return isNaN(s)?-1:1;if(s>a)return 1;if(a>s)return-1}return n.length-o.length}const Ot={alphanumeric:U0,alphanumericCaseSensitive:K0,text:W0,textCaseSensitive:q0,datetime:Y0,basic:X0},Z0=[k0,B0,A0,I0,V0,E0,N0,z0,{getInitialState:e=>({sorting:[],...e}),getDefaultColumnDef:()=>({sortingFn:"auto",sortUndefined:1}),getDefaultOptions:e=>({onSortingChange:de("sorting",e),isMultiSortEvent:t=>t.shiftKey}),createColumn:(e,t)=>{e.getAutoSortingFn=()=>{const n=t.getFilteredRowModel().flatRows.slice(10);let o=!1;for(const r of n){const i=r?.getValue(e.id);if(Object.prototype.toString.call(i)==="[object Date]")return Ot.datetime;if(typeof i=="string"&&(o=!0,i.split(Cr).length>1))return Ot.alphanumeric}return o?Ot.text:Ot.basic},e.getAutoSortDir=()=>{const n=t.getFilteredRowModel().flatRows[0];return typeof n?.getValue(e.id)=="string"?"asc":"desc"},e.getSortingFn=()=>{var n,o;if(!e)throw new Error;return vn(e.columnDef.sortingFn)?e.columnDef.sortingFn:e.columnDef.sortingFn==="auto"?e.getAutoSortingFn():(n=(o=t.options.sortingFns)==null?void 0:o[e.columnDef.sortingFn])!=null?n:Ot[e.columnDef.sortingFn]},e.toggleSorting=(n,o)=>{const r=e.getNextSortingOrder(),i=typeof n<"u"&&n!==null;t.setSorting(s=>{const a=s?.find(f=>f.id===e.id),l=s?.findIndex(f=>f.id===e.id);let c=[],d,u=i?n:r==="desc";if(s!=null&&s.length&&e.getCanMultiSort()&&o?a?d="toggle":d="add":s!=null&&s.length&&l!==s.length-1?d="replace":a?d="toggle":d="replace",d==="toggle"&&(i||r||(d="remove")),d==="add"){var h;c=[...s,{id:e.id,desc:u}],c.splice(0,c.length-((h=t.options.maxMultiSortColCount)!=null?h:Number.MAX_SAFE_INTEGER))}else d==="toggle"?c=s.map(f=>f.id===e.id?{...f,desc:u}:f):d==="remove"?c=s.filter(f=>f.id!==e.id):c=[{id:e.id,desc:u}];return c})},e.getFirstSortDir=()=>{var n,o;return((n=(o=e.columnDef.sortDescFirst)!=null?o:t.options.sortDescFirst)!=null?n:e.getAutoSortDir()==="desc")?"desc":"asc"},e.getNextSortingOrder=n=>{var o,r;const i=e.getFirstSortDir(),s=e.getIsSorted();return s?s!==i&&((o=t.options.enableSortingRemoval)==null||o)&&(!(n&&(r=t.options.enableMultiRemove)!=null)||r)?!1:s==="desc"?"asc":"desc":i},e.getCanSort=()=>{var n,o;return((n=e.columnDef.enableSorting)!=null?n:!0)&&((o=t.options.enableSorting)!=null?o:!0)&&!!e.accessorFn},e.getCanMultiSort=()=>{var n,o;return(n=(o=e.columnDef.enableMultiSort)!=null?o:t.options.enableMultiSort)!=null?n:!!e.accessorFn},e.getIsSorted=()=>{var n;const o=(n=t.getState().sorting)==null?void 0:n.find(r=>r.id===e.id);return o?o.desc?"desc":"asc":!1},e.getSortIndex=()=>{var n,o;return(n=(o=t.getState().sorting)==null?void 0:o.findIndex(r=>r.id===e.id))!=null?n:-1},e.clearSorting=()=>{t.setSorting(n=>n!=null&&n.length?n.filter(o=>o.id!==e.id):[])},e.getToggleSortingHandler=()=>{const n=e.getCanSort();return o=>{n&&(o.persist==null||o.persist(),e.toggleSorting==null||e.toggleSorting(void 0,e.getCanMultiSort()?t.options.isMultiSortEvent==null?void 0:t.options.isMultiSortEvent(o):!1))}}},createTable:e=>{e.setSorting=t=>e.options.onSortingChange==null?void 0:e.options.onSortingChange(t),e.resetSorting=t=>{var n,o;e.setSorting(t?[]:(n=(o=e.initialState)==null?void 0:o.sorting)!=null?n:[])},e.getPreSortedRowModel=()=>e.getGroupedRowModel(),e.getSortedRowModel=()=>(!e._getSortedRowModel&&e.options.getSortedRowModel&&(e._getSortedRowModel=e.options.getSortedRowModel(e)),e.options.manualSorting||!e._getSortedRowModel?e.getPreSortedRowModel():e._getSortedRowModel())}},D0,O0,H0,j0,G0,R0];function J0(e){var t,n;process.env.NODE_ENV!=="production"&&(e.debugAll||e.debugTable)&&console.info("Creating Table Instance...");const o=[...Z0,...(t=e._features)!=null?t:[]];let r={_features:o};const i=r._features.reduce((h,f)=>Object.assign(h,f.getDefaultOptions==null?void 0:f.getDefaultOptions(r)),{}),s=h=>r.options.mergeOptions?r.options.mergeOptions(i,h):{...i,...h};let l={...{},...(n=e.initialState)!=null?n:{}};r._features.forEach(h=>{var f;l=(f=h.getInitialState==null?void 0:h.getInitialState(l))!=null?f:l});const c=[];let d=!1;const u={_features:o,options:{...i,...e},initialState:l,_queue:h=>{c.push(h),d||(d=!0,Promise.resolve().then(()=>{for(;c.length;)c.shift()();d=!1}).catch(f=>setTimeout(()=>{throw f})))},reset:()=>{r.setState(r.initialState)},setOptions:h=>{const f=He(h,r.options);r.options=s(f)},getState:()=>r.options.state,setState:h=>{r.options.onStateChange==null||r.options.onStateChange(h)},_getRowId:(h,f,v)=>{var y;return(y=r.options.getRowId==null?void 0:r.options.getRowId(h,f,v))!=null?y:`${v?[v.id,f].join("."):f}`},getCoreRowModel:()=>(r._getCoreRowModel||(r._getCoreRowModel=r.options.getCoreRowModel(r)),r._getCoreRowModel()),getRowModel:()=>r.getPaginationRowModel(),getRow:(h,f)=>{let v=(f?r.getPrePaginationRowModel():r.getRowModel()).rowsById[h];if(!v&&(v=r.getCoreRowModel().rowsById[h],!v))throw process.env.NODE_ENV!=="production"?new Error(`getRow could not find row with ID: ${h}`):new Error;return v},_getDefaultColumnDef:A(()=>[r.options.defaultColumn],h=>{var f;return h=(f=h)!=null?f:{},{header:v=>{const y=v.header.column.columnDef;return y.accessorKey?y.accessorKey:y.accessorFn?y.id:null},cell:v=>{var y,b;return(y=(b=v.renderValue())==null||b.toString==null?void 0:b.toString())!=null?y:null},...r._features.reduce((v,y)=>Object.assign(v,y.getDefaultColumnDef==null?void 0:y.getDefaultColumnDef()),{}),...h}},I(e,"debugColumns","_getDefaultColumnDef")),_getColumnDefs:()=>r.options.columns,getAllColumns:A(()=>[r._getColumnDefs()],h=>{const f=function(v,y,b){return b===void 0&&(b=0),v.map(w=>{const T=M0(r,w,b,y),C=w;return T.columns=C.columns?f(C.columns,T,b+1):[],T})};return f(h)},I(e,"debugColumns","getAllColumns")),getAllFlatColumns:A(()=>[r.getAllColumns()],h=>h.flatMap(f=>f.getFlatColumns()),I(e,"debugColumns","getAllFlatColumns")),_getAllFlatColumnsById:A(()=>[r.getAllFlatColumns()],h=>h.reduce((f,v)=>(f[v.id]=v,f),{}),I(e,"debugColumns","getAllFlatColumnsById")),getAllLeafColumns:A(()=>[r.getAllColumns(),r._getOrderColumnsFn()],(h,f)=>{let v=h.flatMap(y=>y.getLeafColumns());return f(v)},I(e,"debugColumns","getAllLeafColumns")),getColumn:h=>{const f=r._getAllFlatColumnsById()[h];return process.env.NODE_ENV!=="production"&&!f&&console.error(`[Table] Column with id '${h}' does not exist.`),f}};Object.assign(r,u);for(let h=0;h<r._features.length;h++){const f=r._features[h];f==null||f.createTable==null||f.createTable(r)}return r}function Q0(){return e=>A(()=>[e.options.data],t=>{const n={rows:[],flatRows:[],rowsById:{}},o=function(r,i,s){i===void 0&&(i=0);const a=[];for(let c=0;c<r.length;c++){const d=cr(e,e._getRowId(r[c],c,s),r[c],c,i,void 0,s?.id);if(n.flatRows.push(d),n.rowsById[d.id]=d,a.push(d),e.options.getSubRows){var l;d.originalSubRows=e.options.getSubRows(r[c],c),(l=d.originalSubRows)!=null&&l.length&&(d.subRows=o(d.originalSubRows,i+1,d))}}return a};return n.rows=o(t),n},I(e.options,"debugTable","getRowModel",()=>e._autoResetPageIndex()))}function ev(e,t,n){return n.options.filterFromLeafRows?tv(e,t,n):nv(e,t,n)}function tv(e,t,n){var o;const r=[],i={},s=(o=n.options.maxLeafRowFilterDepth)!=null?o:100,a=function(l,c){c===void 0&&(c=0);const d=[];for(let h=0;h<l.length;h++){var u;let f=l[h];const v=cr(n,f.id,f.original,f.index,f.depth,void 0,f.parentId);if(v.columnFilters=f.columnFilters,(u=f.subRows)!=null&&u.length&&c<s){if(v.subRows=a(f.subRows,c+1),f=v,t(f)&&!v.subRows.length){d.push(f),i[f.id]=f,r.push(f);continue}if(t(f)||v.subRows.length){d.push(f),i[f.id]=f,r.push(f);continue}}else f=v,t(f)&&(d.push(f),i[f.id]=f,r.push(f))}return d};return{rows:a(e),flatRows:r,rowsById:i}}function nv(e,t,n){var o;const r=[],i={},s=(o=n.options.maxLeafRowFilterDepth)!=null?o:100,a=function(l,c){c===void 0&&(c=0);const d=[];for(let h=0;h<l.length;h++){let f=l[h];if(t(f)){var u;if((u=f.subRows)!=null&&u.length&&c<s){const y=cr(n,f.id,f.original,f.index,f.depth,void 0,f.parentId);y.subRows=a(f.subRows,c+1),f=y}d.push(f),r.push(f),i[f.id]=f}}return d};return{rows:a(e),flatRows:r,rowsById:i}}function ov(){return e=>A(()=>[e.getPreFilteredRowModel(),e.getState().columnFilters,e.getState().globalFilter],(t,n,o)=>{if(!t.rows.length||!(n!=null&&n.length)&&!o){for(let h=0;h<t.flatRows.length;h++)t.flatRows[h].columnFilters={},t.flatRows[h].columnFiltersMeta={};return t}const r=[],i=[];(n??[]).forEach(h=>{var f;const v=e.getColumn(h.id);if(!v)return;const y=v.getFilterFn();if(!y){process.env.NODE_ENV!=="production"&&console.warn(`Could not find a valid 'column.filterFn' for column with the ID: ${v.id}.`);return}r.push({id:h.id,filterFn:y,resolvedValue:(f=y.resolveFilterValue==null?void 0:y.resolveFilterValue(h.value))!=null?f:h.value})});const s=(n??[]).map(h=>h.id),a=e.getGlobalFilterFn(),l=e.getAllLeafColumns().filter(h=>h.getCanGlobalFilter());o&&a&&l.length&&(s.push("__global__"),l.forEach(h=>{var f;i.push({id:h.id,filterFn:a,resolvedValue:(f=a.resolveFilterValue==null?void 0:a.resolveFilterValue(o))!=null?f:o})}));let c,d;for(let h=0;h<t.flatRows.length;h++){const f=t.flatRows[h];if(f.columnFilters={},r.length)for(let v=0;v<r.length;v++){c=r[v];const y=c.id;f.columnFilters[y]=c.filterFn(f,y,c.resolvedValue,b=>{f.columnFiltersMeta[y]=b})}if(i.length){for(let v=0;v<i.length;v++){d=i[v];const y=d.id;if(d.filterFn(f,y,d.resolvedValue,b=>{f.columnFiltersMeta[y]=b})){f.columnFilters.__global__=!0;break}}f.columnFilters.__global__!==!0&&(f.columnFilters.__global__=!1)}}const u=h=>{for(let f=0;f<s.length;f++)if(h.columnFilters[s[f]]===!1)return!1;return!0};return ev(t.rows,u,e)},I(e.options,"debugTable","getFilteredRowModel",()=>e._autoResetPageIndex()))}function rv(){return e=>A(()=>[e.getState().sorting,e.getPreSortedRowModel()],(t,n)=>{if(!n.rows.length||!(t!=null&&t.length))return n;const o=e.getState().sorting,r=[],i=o.filter(l=>{var c;return(c=e.getColumn(l.id))==null?void 0:c.getCanSort()}),s={};i.forEach(l=>{const c=e.getColumn(l.id);c&&(s[l.id]={sortUndefined:c.columnDef.sortUndefined,invertSorting:c.columnDef.invertSorting,sortingFn:c.getSortingFn()})});const a=l=>{const c=l.map(d=>({...d}));return c.sort((d,u)=>{for(let f=0;f<i.length;f+=1){var h;const v=i[f],y=s[v.id],b=y.sortUndefined,w=(h=v?.desc)!=null?h:!1;let T=0;if(b){const C=d.getValue(v.id),M=u.getValue(v.id),x=C===void 0,P=M===void 0;if(x||P){if(b==="first")return x?-1:1;if(b==="last")return x?1:-1;T=x&&P?0:x?b:-b}}if(T===0&&(T=y.sortingFn(d,u,v.id)),T!==0)return w&&(T*=-1),y.invertSorting&&(T*=-1),T}return d.index-u.index}),c.forEach(d=>{var u;r.push(d),(u=d.subRows)!=null&&u.length&&(d.subRows=a(d.subRows))}),c};return{rows:a(n.rows),flatRows:r,rowsById:n.rowsById}},I(e.options,"debugTable","getSortedRowModel",()=>e._autoResetPageIndex()))}function xn(e,t){return e?iv(e)?Ue.createElement(e,t):e:null}function iv(e){return sv(e)||typeof e=="function"||av(e)}function sv(e){return typeof e=="function"&&(()=>{const t=Object.getPrototypeOf(e);return t.prototype&&t.prototype.isReactComponent})()}function av(e){return typeof e=="object"&&typeof e.$$typeof=="symbol"&&["react.memo","react.forward_ref"].includes(e.$$typeof.description)}function lv(e){const t={state:{},onStateChange:()=>{},renderFallbackValue:null,...e},[n]=Ue.useState(()=>({current:J0(t)})),[o,r]=Ue.useState(()=>n.current.initialState);return n.current.setOptions(i=>({...i,...e,state:{...o,...e.state},onStateChange:s=>{r(s),e.onStateChange==null||e.onStateChange(s)}})),n.current}const cv=g.css`
1613
+ color: hsl(${Math.max(0,Math.min(120-120*h,120))}deg 100% 31%);`,n?.key)}return r}}function I(e,t,n,o){return{debug:()=>{var r;return(r=e?.debugAll)!=null?r:e[t]},key:process.env.NODE_ENV==="development"&&n,onChange:o}}function $0(e,t,n,o){const r=()=>{var s;return(s=i.getValue())!=null?s:e.options.renderFallbackValue},i={id:`${t.id}_${n.id}`,row:t,column:n,getValue:()=>t.getValue(o),renderValue:r,getContext:A(()=>[e,n,t,i],(s,a,l,c)=>({table:s,column:a,row:l,cell:c,getValue:c.getValue,renderValue:c.renderValue}),I(e.options,"debugCells","cell.getContext"))};return e._features.forEach(s=>{s.createCell==null||s.createCell(i,n,t,e)},{}),i}function P0(e,t,n,o){var r,i;const a={...e._getDefaultColumnDef(),...t},l=a.accessorKey;let c=(r=(i=a.id)!=null?i:l?typeof String.prototype.replaceAll=="function"?l.replaceAll(".","_"):l.replace(/\./g,"_"):void 0)!=null?r:typeof a.header=="string"?a.header:void 0,d;if(a.accessorFn?d=a.accessorFn:l&&(l.includes(".")?d=h=>{let f=h;for(const y of l.split(".")){var v;f=(v=f)==null?void 0:v[y],process.env.NODE_ENV!=="production"&&f===void 0&&console.warn(`"${y}" in deeply nested key "${l}" returned undefined.`)}return f}:d=h=>h[a.accessorKey]),!c)throw process.env.NODE_ENV!=="production"?new Error(a.accessorFn?"Columns require an id when using an accessorFn":"Columns require an id when using a non-string header"):new Error;let u={id:`${String(c)}`,accessorFn:d,parent:o,depth:n,columnDef:a,columns:[],getFlatColumns:A(()=>[!0],()=>{var h;return[u,...(h=u.columns)==null?void 0:h.flatMap(f=>f.getFlatColumns())]},I(e.options,"debugColumns","column.getFlatColumns")),getLeafColumns:A(()=>[e._getOrderColumnsFn()],h=>{var f;if((f=u.columns)!=null&&f.length){let v=u.columns.flatMap(y=>y.getLeafColumns());return h(v)}return[u]},I(e.options,"debugColumns","column.getLeafColumns"))};for(const h of e._features)h.createColumn==null||h.createColumn(u,e);return u}const se="debugHeaders";function Vl(e,t,n){var o;let i={id:(o=n.id)!=null?o:t.id,column:t,index:n.index,isPlaceholder:!!n.isPlaceholder,placeholderId:n.placeholderId,depth:n.depth,subHeaders:[],colSpan:0,rowSpan:0,headerGroup:null,getLeafHeaders:()=>{const s=[],a=l=>{l.subHeaders&&l.subHeaders.length&&l.subHeaders.map(a),s.push(l)};return a(i),s},getContext:()=>({table:e,header:i,column:t})};return e._features.forEach(s=>{s.createHeader==null||s.createHeader(i,e)}),i}const k0={createTable:e=>{e.getHeaderGroups=A(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,o,r)=>{var i,s;const a=(i=o?.map(u=>n.find(h=>h.id===u)).filter(Boolean))!=null?i:[],l=(s=r?.map(u=>n.find(h=>h.id===u)).filter(Boolean))!=null?s:[],c=n.filter(u=>!(o!=null&&o.includes(u.id))&&!(r!=null&&r.includes(u.id)));return yn(t,[...a,...c,...l],e)},I(e.options,se,"getHeaderGroups")),e.getCenterHeaderGroups=A(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,o,r)=>(n=n.filter(i=>!(o!=null&&o.includes(i.id))&&!(r!=null&&r.includes(i.id))),yn(t,n,e,"center")),I(e.options,se,"getCenterHeaderGroups")),e.getLeftHeaderGroups=A(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left],(t,n,o)=>{var r;const i=(r=o?.map(s=>n.find(a=>a.id===s)).filter(Boolean))!=null?r:[];return yn(t,i,e,"left")},I(e.options,se,"getLeftHeaderGroups")),e.getRightHeaderGroups=A(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.right],(t,n,o)=>{var r;const i=(r=o?.map(s=>n.find(a=>a.id===s)).filter(Boolean))!=null?r:[];return yn(t,i,e,"right")},I(e.options,se,"getRightHeaderGroups")),e.getFooterGroups=A(()=>[e.getHeaderGroups()],t=>[...t].reverse(),I(e.options,se,"getFooterGroups")),e.getLeftFooterGroups=A(()=>[e.getLeftHeaderGroups()],t=>[...t].reverse(),I(e.options,se,"getLeftFooterGroups")),e.getCenterFooterGroups=A(()=>[e.getCenterHeaderGroups()],t=>[...t].reverse(),I(e.options,se,"getCenterFooterGroups")),e.getRightFooterGroups=A(()=>[e.getRightHeaderGroups()],t=>[...t].reverse(),I(e.options,se,"getRightFooterGroups")),e.getFlatHeaders=A(()=>[e.getHeaderGroups()],t=>t.map(n=>n.headers).flat(),I(e.options,se,"getFlatHeaders")),e.getLeftFlatHeaders=A(()=>[e.getLeftHeaderGroups()],t=>t.map(n=>n.headers).flat(),I(e.options,se,"getLeftFlatHeaders")),e.getCenterFlatHeaders=A(()=>[e.getCenterHeaderGroups()],t=>t.map(n=>n.headers).flat(),I(e.options,se,"getCenterFlatHeaders")),e.getRightFlatHeaders=A(()=>[e.getRightHeaderGroups()],t=>t.map(n=>n.headers).flat(),I(e.options,se,"getRightFlatHeaders")),e.getCenterLeafHeaders=A(()=>[e.getCenterFlatHeaders()],t=>t.filter(n=>{var o;return!((o=n.subHeaders)!=null&&o.length)}),I(e.options,se,"getCenterLeafHeaders")),e.getLeftLeafHeaders=A(()=>[e.getLeftFlatHeaders()],t=>t.filter(n=>{var o;return!((o=n.subHeaders)!=null&&o.length)}),I(e.options,se,"getLeftLeafHeaders")),e.getRightLeafHeaders=A(()=>[e.getRightFlatHeaders()],t=>t.filter(n=>{var o;return!((o=n.subHeaders)!=null&&o.length)}),I(e.options,se,"getRightLeafHeaders")),e.getLeafHeaders=A(()=>[e.getLeftHeaderGroups(),e.getCenterHeaderGroups(),e.getRightHeaderGroups()],(t,n,o)=>{var r,i,s,a,l,c;return[...(r=(i=t[0])==null?void 0:i.headers)!=null?r:[],...(s=(a=n[0])==null?void 0:a.headers)!=null?s:[],...(l=(c=o[0])==null?void 0:c.headers)!=null?l:[]].map(d=>d.getLeafHeaders()).flat()},I(e.options,se,"getLeafHeaders"))}};function yn(e,t,n,o){var r,i;let s=0;const a=function(h,f){f===void 0&&(f=1),s=Math.max(s,f),h.filter(v=>v.getIsVisible()).forEach(v=>{var y;(y=v.columns)!=null&&y.length&&a(v.columns,f+1)},0)};a(e);let l=[];const c=(h,f)=>{const v={depth:f,id:[o,`${f}`].filter(Boolean).join("_"),headers:[]},y=[];h.forEach(b=>{const w=[...y].reverse()[0],T=b.column.depth===v.depth;let C,k=!1;if(T&&b.column.parent?C=b.column.parent:(C=b.column,k=!0),w&&w?.column===C)w.subHeaders.push(b);else{const x=Vl(n,C,{id:[o,f,C.id,b?.id].filter(Boolean).join("_"),isPlaceholder:k,placeholderId:k?`${y.filter(P=>P.column===C).length}`:void 0,depth:f,index:y.length});x.subHeaders.push(b),y.push(x)}v.headers.push(b),b.headerGroup=v}),l.push(v),f>0&&c(y,f-1)},d=t.map((h,f)=>Vl(n,h,{depth:s,index:f}));c(d,s-1),l.reverse();const u=h=>h.filter(v=>v.column.getIsVisible()).map(v=>{let y=0,b=0,w=[0];v.subHeaders&&v.subHeaders.length?(w=[],u(v.subHeaders).forEach(C=>{let{colSpan:k,rowSpan:x}=C;y+=k,w.push(x)})):y=1;const T=Math.min(...w);return b=b+T,v.colSpan=y,v.rowSpan=b,{colSpan:y,rowSpan:b}});return u((r=(i=l[0])==null?void 0:i.headers)!=null?r:[]),l}const ur=(e,t,n,o,r,i,s)=>{let a={id:t,index:o,original:n,depth:r,parentId:s,_valuesCache:{},_uniqueValuesCache:{},getValue:l=>{if(a._valuesCache.hasOwnProperty(l))return a._valuesCache[l];const c=e.getColumn(l);if(c!=null&&c.accessorFn)return a._valuesCache[l]=c.accessorFn(a.original,o),a._valuesCache[l]},getUniqueValues:l=>{if(a._uniqueValuesCache.hasOwnProperty(l))return a._uniqueValuesCache[l];const c=e.getColumn(l);if(c!=null&&c.accessorFn)return c.columnDef.getUniqueValues?(a._uniqueValuesCache[l]=c.columnDef.getUniqueValues(a.original,o),a._uniqueValuesCache[l]):(a._uniqueValuesCache[l]=[a.getValue(l)],a._uniqueValuesCache[l])},renderValue:l=>{var c;return(c=a.getValue(l))!=null?c:e.options.renderFallbackValue},subRows:[],getLeafRows:()=>T0(a.subRows,l=>l.subRows),getParentRow:()=>a.parentId?e.getRow(a.parentId,!0):void 0,getParentRows:()=>{let l=[],c=a;for(;;){const d=c.getParentRow();if(!d)break;l.push(d),c=d}return l.reverse()},getAllCells:A(()=>[e.getAllLeafColumns()],l=>l.map(c=>$0(e,a,c,c.id)),I(e.options,"debugRows","getAllCells")),_getAllCellsByColumnId:A(()=>[a.getAllCells()],l=>l.reduce((c,d)=>(c[d.column.id]=d,c),{}),I(e.options,"debugRows","getAllCellsByColumnId"))};for(let l=0;l<e._features.length;l++){const c=e._features[l];c==null||c.createRow==null||c.createRow(a,e)}return a},M0={createColumn:(e,t)=>{e._getFacetedRowModel=t.options.getFacetedRowModel&&t.options.getFacetedRowModel(t,e.id),e.getFacetedRowModel=()=>e._getFacetedRowModel?e._getFacetedRowModel():t.getPreFilteredRowModel(),e._getFacetedUniqueValues=t.options.getFacetedUniqueValues&&t.options.getFacetedUniqueValues(t,e.id),e.getFacetedUniqueValues=()=>e._getFacetedUniqueValues?e._getFacetedUniqueValues():new Map,e._getFacetedMinMaxValues=t.options.getFacetedMinMaxValues&&t.options.getFacetedMinMaxValues(t,e.id),e.getFacetedMinMaxValues=()=>{if(e._getFacetedMinMaxValues)return e._getFacetedMinMaxValues()}}},El=(e,t,n)=>{var o,r;const i=n==null||(o=n.toString())==null?void 0:o.toLowerCase();return!!(!((r=e.getValue(t))==null||(r=r.toString())==null||(r=r.toLowerCase())==null)&&r.includes(i))};El.autoRemove=e=>xe(e);const Dl=(e,t,n)=>{var o;return!!(!((o=e.getValue(t))==null||(o=o.toString())==null)&&o.includes(n))};Dl.autoRemove=e=>xe(e);const Fl=(e,t,n)=>{var o;return((o=e.getValue(t))==null||(o=o.toString())==null?void 0:o.toLowerCase())===n?.toLowerCase()};Fl.autoRemove=e=>xe(e);const Al=(e,t,n)=>{var o;return(o=e.getValue(t))==null?void 0:o.includes(n)};Al.autoRemove=e=>xe(e);const Il=(e,t,n)=>!n.some(o=>{var r;return!((r=e.getValue(t))!=null&&r.includes(o))});Il.autoRemove=e=>xe(e)||!(e!=null&&e.length);const Ll=(e,t,n)=>n.some(o=>{var r;return(r=e.getValue(t))==null?void 0:r.includes(o)});Ll.autoRemove=e=>xe(e)||!(e!=null&&e.length);const Rl=(e,t,n)=>e.getValue(t)===n;Rl.autoRemove=e=>xe(e);const _l=(e,t,n)=>e.getValue(t)==n;_l.autoRemove=e=>xe(e);const dr=(e,t,n)=>{let[o,r]=n;const i=e.getValue(t);return i>=o&&i<=r};dr.resolveFilterValue=e=>{let[t,n]=e,o=typeof t!="number"?parseFloat(t):t,r=typeof n!="number"?parseFloat(n):n,i=t===null||Number.isNaN(o)?-1/0:o,s=n===null||Number.isNaN(r)?1/0:r;if(i>s){const a=i;i=s,s=a}return[i,s]},dr.autoRemove=e=>xe(e)||xe(e[0])&&xe(e[1]);const Ae={includesString:El,includesStringSensitive:Dl,equalsString:Fl,arrIncludes:Al,arrIncludesAll:Il,arrIncludesSome:Ll,equals:Rl,weakEquals:_l,inNumberRange:dr};function xe(e){return e==null||e===""}const V0={getDefaultColumnDef:()=>({filterFn:"auto"}),getInitialState:e=>({columnFilters:[],...e}),getDefaultOptions:e=>({onColumnFiltersChange:de("columnFilters",e),filterFromLeafRows:!1,maxLeafRowFilterDepth:100}),createColumn:(e,t)=>{e.getAutoFilterFn=()=>{const n=t.getCoreRowModel().flatRows[0],o=n?.getValue(e.id);return typeof o=="string"?Ae.includesString:typeof o=="number"?Ae.inNumberRange:typeof o=="boolean"||o!==null&&typeof o=="object"?Ae.equals:Array.isArray(o)?Ae.arrIncludes:Ae.weakEquals},e.getFilterFn=()=>{var n,o;return vn(e.columnDef.filterFn)?e.columnDef.filterFn:e.columnDef.filterFn==="auto"?e.getAutoFilterFn():(n=(o=t.options.filterFns)==null?void 0:o[e.columnDef.filterFn])!=null?n:Ae[e.columnDef.filterFn]},e.getCanFilter=()=>{var n,o,r;return((n=e.columnDef.enableColumnFilter)!=null?n:!0)&&((o=t.options.enableColumnFilters)!=null?o:!0)&&((r=t.options.enableFilters)!=null?r:!0)&&!!e.accessorFn},e.getIsFiltered=()=>e.getFilterIndex()>-1,e.getFilterValue=()=>{var n;return(n=t.getState().columnFilters)==null||(n=n.find(o=>o.id===e.id))==null?void 0:n.value},e.getFilterIndex=()=>{var n,o;return(n=(o=t.getState().columnFilters)==null?void 0:o.findIndex(r=>r.id===e.id))!=null?n:-1},e.setFilterValue=n=>{t.setColumnFilters(o=>{const r=e.getFilterFn(),i=o?.find(d=>d.id===e.id),s=He(n,i?i.value:void 0);if(Nl(r,s,e)){var a;return(a=o?.filter(d=>d.id!==e.id))!=null?a:[]}const l={id:e.id,value:s};if(i){var c;return(c=o?.map(d=>d.id===e.id?l:d))!=null?c:[]}return o!=null&&o.length?[...o,l]:[l]})}},createRow:(e,t)=>{e.columnFilters={},e.columnFiltersMeta={}},createTable:e=>{e.setColumnFilters=t=>{const n=e.getAllLeafColumns(),o=r=>{var i;return(i=He(t,r))==null?void 0:i.filter(s=>{const a=n.find(l=>l.id===s.id);if(a){const l=a.getFilterFn();if(Nl(l,s.value,a))return!1}return!0})};e.options.onColumnFiltersChange==null||e.options.onColumnFiltersChange(o)},e.resetColumnFilters=t=>{var n,o;e.setColumnFilters(t?[]:(n=(o=e.initialState)==null?void 0:o.columnFilters)!=null?n:[])},e.getPreFilteredRowModel=()=>e.getCoreRowModel(),e.getFilteredRowModel=()=>(!e._getFilteredRowModel&&e.options.getFilteredRowModel&&(e._getFilteredRowModel=e.options.getFilteredRowModel(e)),e.options.manualFiltering||!e._getFilteredRowModel?e.getPreFilteredRowModel():e._getFilteredRowModel())}};function Nl(e,t,n){return(e&&e.autoRemove?e.autoRemove(t,n):!1)||typeof t>"u"||typeof t=="string"&&!t}const fr={sum:(e,t,n)=>n.reduce((o,r)=>{const i=r.getValue(e);return o+(typeof i=="number"?i:0)},0),min:(e,t,n)=>{let o;return n.forEach(r=>{const i=r.getValue(e);i!=null&&(o>i||o===void 0&&i>=i)&&(o=i)}),o},max:(e,t,n)=>{let o;return n.forEach(r=>{const i=r.getValue(e);i!=null&&(o<i||o===void 0&&i>=i)&&(o=i)}),o},extent:(e,t,n)=>{let o,r;return n.forEach(i=>{const s=i.getValue(e);s!=null&&(o===void 0?s>=s&&(o=r=s):(o>s&&(o=s),r<s&&(r=s)))}),[o,r]},mean:(e,t)=>{let n=0,o=0;if(t.forEach(r=>{let i=r.getValue(e);i!=null&&(i=+i)>=i&&(++n,o+=i)}),n)return o/n},median:(e,t)=>{if(!t.length)return;const n=t.map(i=>i.getValue(e));if(!C0(n))return;if(n.length===1)return n[0];const o=Math.floor(n.length/2),r=n.sort((i,s)=>i-s);return n.length%2!==0?r[o]:(r[o-1]+r[o])/2},unique:(e,t)=>Array.from(new Set(t.map(n=>n.getValue(e))).values()),uniqueCount:(e,t)=>new Set(t.map(n=>n.getValue(e))).size,count:(e,t)=>t.length},E0={getDefaultColumnDef:()=>({aggregatedCell:e=>{var t,n;return(t=(n=e.getValue())==null||n.toString==null?void 0:n.toString())!=null?t:null},aggregationFn:"auto"}),getInitialState:e=>({grouping:[],...e}),getDefaultOptions:e=>({onGroupingChange:de("grouping",e),groupedColumnMode:"reorder"}),createColumn:(e,t)=>{e.toggleGrouping=()=>{t.setGrouping(n=>n!=null&&n.includes(e.id)?n.filter(o=>o!==e.id):[...n??[],e.id])},e.getCanGroup=()=>{var n,o;return((n=e.columnDef.enableGrouping)!=null?n:!0)&&((o=t.options.enableGrouping)!=null?o:!0)&&(!!e.accessorFn||!!e.columnDef.getGroupingValue)},e.getIsGrouped=()=>{var n;return(n=t.getState().grouping)==null?void 0:n.includes(e.id)},e.getGroupedIndex=()=>{var n;return(n=t.getState().grouping)==null?void 0:n.indexOf(e.id)},e.getToggleGroupingHandler=()=>{const n=e.getCanGroup();return()=>{n&&e.toggleGrouping()}},e.getAutoAggregationFn=()=>{const n=t.getCoreRowModel().flatRows[0],o=n?.getValue(e.id);if(typeof o=="number")return fr.sum;if(Object.prototype.toString.call(o)==="[object Date]")return fr.extent},e.getAggregationFn=()=>{var n,o;if(!e)throw new Error;return vn(e.columnDef.aggregationFn)?e.columnDef.aggregationFn:e.columnDef.aggregationFn==="auto"?e.getAutoAggregationFn():(n=(o=t.options.aggregationFns)==null?void 0:o[e.columnDef.aggregationFn])!=null?n:fr[e.columnDef.aggregationFn]}},createTable:e=>{e.setGrouping=t=>e.options.onGroupingChange==null?void 0:e.options.onGroupingChange(t),e.resetGrouping=t=>{var n,o;e.setGrouping(t?[]:(n=(o=e.initialState)==null?void 0:o.grouping)!=null?n:[])},e.getPreGroupedRowModel=()=>e.getFilteredRowModel(),e.getGroupedRowModel=()=>(!e._getGroupedRowModel&&e.options.getGroupedRowModel&&(e._getGroupedRowModel=e.options.getGroupedRowModel(e)),e.options.manualGrouping||!e._getGroupedRowModel?e.getPreGroupedRowModel():e._getGroupedRowModel())},createRow:(e,t)=>{e.getIsGrouped=()=>!!e.groupingColumnId,e.getGroupingValue=n=>{if(e._groupingValuesCache.hasOwnProperty(n))return e._groupingValuesCache[n];const o=t.getColumn(n);return o!=null&&o.columnDef.getGroupingValue?(e._groupingValuesCache[n]=o.columnDef.getGroupingValue(e.original),e._groupingValuesCache[n]):e.getValue(n)},e._groupingValuesCache={}},createCell:(e,t,n,o)=>{e.getIsGrouped=()=>t.getIsGrouped()&&t.id===n.groupingColumnId,e.getIsPlaceholder=()=>!e.getIsGrouped()&&t.getIsGrouped(),e.getIsAggregated=()=>{var r;return!e.getIsGrouped()&&!e.getIsPlaceholder()&&!!((r=n.subRows)!=null&&r.length)}}};function D0(e,t,n){if(!(t!=null&&t.length)||!n)return e;const o=e.filter(i=>!t.includes(i.id));return n==="remove"?o:[...t.map(i=>e.find(s=>s.id===i)).filter(Boolean),...o]}const F0={getInitialState:e=>({columnOrder:[],...e}),getDefaultOptions:e=>({onColumnOrderChange:de("columnOrder",e)}),createColumn:(e,t)=>{e.getIndex=A(n=>[Ot(t,n)],n=>n.findIndex(o=>o.id===e.id),I(t.options,"debugColumns","getIndex")),e.getIsFirstColumn=n=>{var o;return((o=Ot(t,n)[0])==null?void 0:o.id)===e.id},e.getIsLastColumn=n=>{var o;const r=Ot(t,n);return((o=r[r.length-1])==null?void 0:o.id)===e.id}},createTable:e=>{e.setColumnOrder=t=>e.options.onColumnOrderChange==null?void 0:e.options.onColumnOrderChange(t),e.resetColumnOrder=t=>{var n;e.setColumnOrder(t?[]:(n=e.initialState.columnOrder)!=null?n:[])},e._getOrderColumnsFn=A(()=>[e.getState().columnOrder,e.getState().grouping,e.options.groupedColumnMode],(t,n,o)=>r=>{let i=[];if(!(t!=null&&t.length))i=r;else{const s=[...t],a=[...r];for(;a.length&&s.length;){const l=s.shift(),c=a.findIndex(d=>d.id===l);c>-1&&i.push(a.splice(c,1)[0])}i=[...i,...a]}return D0(i,n,o)},I(e.options,"debugTable","_getOrderColumnsFn"))}},hr=()=>({left:[],right:[]}),A0={getInitialState:e=>({columnPinning:hr(),...e}),getDefaultOptions:e=>({onColumnPinningChange:de("columnPinning",e)}),createColumn:(e,t)=>{e.pin=n=>{const o=e.getLeafColumns().map(r=>r.id).filter(Boolean);t.setColumnPinning(r=>{var i,s;if(n==="right"){var a,l;return{left:((a=r?.left)!=null?a:[]).filter(u=>!(o!=null&&o.includes(u))),right:[...((l=r?.right)!=null?l:[]).filter(u=>!(o!=null&&o.includes(u))),...o]}}if(n==="left"){var c,d;return{left:[...((c=r?.left)!=null?c:[]).filter(u=>!(o!=null&&o.includes(u))),...o],right:((d=r?.right)!=null?d:[]).filter(u=>!(o!=null&&o.includes(u)))}}return{left:((i=r?.left)!=null?i:[]).filter(u=>!(o!=null&&o.includes(u))),right:((s=r?.right)!=null?s:[]).filter(u=>!(o!=null&&o.includes(u)))}})},e.getCanPin=()=>e.getLeafColumns().some(o=>{var r,i,s;return((r=o.columnDef.enablePinning)!=null?r:!0)&&((i=(s=t.options.enableColumnPinning)!=null?s:t.options.enablePinning)!=null?i:!0)}),e.getIsPinned=()=>{const n=e.getLeafColumns().map(a=>a.id),{left:o,right:r}=t.getState().columnPinning,i=n.some(a=>o?.includes(a)),s=n.some(a=>r?.includes(a));return i?"left":s?"right":!1},e.getPinnedIndex=()=>{var n,o;const r=e.getIsPinned();return r?(n=(o=t.getState().columnPinning)==null||(o=o[r])==null?void 0:o.indexOf(e.id))!=null?n:-1:0}},createRow:(e,t)=>{e.getCenterVisibleCells=A(()=>[e._getAllVisibleCells(),t.getState().columnPinning.left,t.getState().columnPinning.right],(n,o,r)=>{const i=[...o??[],...r??[]];return n.filter(s=>!i.includes(s.column.id))},I(t.options,"debugRows","getCenterVisibleCells")),e.getLeftVisibleCells=A(()=>[e._getAllVisibleCells(),t.getState().columnPinning.left],(n,o)=>(o??[]).map(i=>n.find(s=>s.column.id===i)).filter(Boolean).map(i=>({...i,position:"left"})),I(t.options,"debugRows","getLeftVisibleCells")),e.getRightVisibleCells=A(()=>[e._getAllVisibleCells(),t.getState().columnPinning.right],(n,o)=>(o??[]).map(i=>n.find(s=>s.column.id===i)).filter(Boolean).map(i=>({...i,position:"right"})),I(t.options,"debugRows","getRightVisibleCells"))},createTable:e=>{e.setColumnPinning=t=>e.options.onColumnPinningChange==null?void 0:e.options.onColumnPinningChange(t),e.resetColumnPinning=t=>{var n,o;return e.setColumnPinning(t?hr():(n=(o=e.initialState)==null?void 0:o.columnPinning)!=null?n:hr())},e.getIsSomeColumnsPinned=t=>{var n;const o=e.getState().columnPinning;if(!t){var r,i;return!!((r=o.left)!=null&&r.length||(i=o.right)!=null&&i.length)}return!!((n=o[t])!=null&&n.length)},e.getLeftLeafColumns=A(()=>[e.getAllLeafColumns(),e.getState().columnPinning.left],(t,n)=>(n??[]).map(o=>t.find(r=>r.id===o)).filter(Boolean),I(e.options,"debugColumns","getLeftLeafColumns")),e.getRightLeafColumns=A(()=>[e.getAllLeafColumns(),e.getState().columnPinning.right],(t,n)=>(n??[]).map(o=>t.find(r=>r.id===o)).filter(Boolean),I(e.options,"debugColumns","getRightLeafColumns")),e.getCenterLeafColumns=A(()=>[e.getAllLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,o)=>{const r=[...n??[],...o??[]];return t.filter(i=>!r.includes(i.id))},I(e.options,"debugColumns","getCenterLeafColumns"))}};function I0(e){return e||(typeof document<"u"?document:null)}const wn={size:150,minSize:20,maxSize:Number.MAX_SAFE_INTEGER},mr=()=>({startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,isResizingColumn:!1,columnSizingStart:[]}),L0={getDefaultColumnDef:()=>wn,getInitialState:e=>({columnSizing:{},columnSizingInfo:mr(),...e}),getDefaultOptions:e=>({columnResizeMode:"onEnd",columnResizeDirection:"ltr",onColumnSizingChange:de("columnSizing",e),onColumnSizingInfoChange:de("columnSizingInfo",e)}),createColumn:(e,t)=>{e.getSize=()=>{var n,o,r;const i=t.getState().columnSizing[e.id];return Math.min(Math.max((n=e.columnDef.minSize)!=null?n:wn.minSize,(o=i??e.columnDef.size)!=null?o:wn.size),(r=e.columnDef.maxSize)!=null?r:wn.maxSize)},e.getStart=A(n=>[n,Ot(t,n),t.getState().columnSizing],(n,o)=>o.slice(0,e.getIndex(n)).reduce((r,i)=>r+i.getSize(),0),I(t.options,"debugColumns","getStart")),e.getAfter=A(n=>[n,Ot(t,n),t.getState().columnSizing],(n,o)=>o.slice(e.getIndex(n)+1).reduce((r,i)=>r+i.getSize(),0),I(t.options,"debugColumns","getAfter")),e.resetSize=()=>{t.setColumnSizing(n=>{let{[e.id]:o,...r}=n;return r})},e.getCanResize=()=>{var n,o;return((n=e.columnDef.enableResizing)!=null?n:!0)&&((o=t.options.enableColumnResizing)!=null?o:!0)},e.getIsResizing=()=>t.getState().columnSizingInfo.isResizingColumn===e.id},createHeader:(e,t)=>{e.getSize=()=>{let n=0;const o=r=>{if(r.subHeaders.length)r.subHeaders.forEach(o);else{var i;n+=(i=r.column.getSize())!=null?i:0}};return o(e),n},e.getStart=()=>{if(e.index>0){const n=e.headerGroup.headers[e.index-1];return n.getStart()+n.getSize()}return 0},e.getResizeHandler=n=>{const o=t.getColumn(e.column.id),r=o?.getCanResize();return i=>{if(!o||!r||(i.persist==null||i.persist(),pr(i)&&i.touches&&i.touches.length>1))return;const s=e.getSize(),a=e?e.getLeafHeaders().map(w=>[w.column.id,w.column.getSize()]):[[o.id,o.getSize()]],l=pr(i)?Math.round(i.touches[0].clientX):i.clientX,c={},d=(w,T)=>{typeof T=="number"&&(t.setColumnSizingInfo(C=>{var k,x;const P=t.options.columnResizeDirection==="rtl"?-1:1,V=(T-((k=C?.startOffset)!=null?k:0))*P,$=Math.max(V/((x=C?.startSize)!=null?x:0),-.999999);return C.columnSizingStart.forEach(D=>{let[F,_]=D;c[F]=Math.round(Math.max(_+_*$,0)*100)/100}),{...C,deltaOffset:V,deltaPercentage:$}}),(t.options.columnResizeMode==="onChange"||w==="end")&&t.setColumnSizing(C=>({...C,...c})))},u=w=>d("move",w),h=w=>{d("end",w),t.setColumnSizingInfo(T=>({...T,isResizingColumn:!1,startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,columnSizingStart:[]}))},f=I0(n),v={moveHandler:w=>u(w.clientX),upHandler:w=>{f?.removeEventListener("mousemove",v.moveHandler),f?.removeEventListener("mouseup",v.upHandler),h(w.clientX)}},y={moveHandler:w=>(w.cancelable&&(w.preventDefault(),w.stopPropagation()),u(w.touches[0].clientX),!1),upHandler:w=>{var T;f?.removeEventListener("touchmove",y.moveHandler),f?.removeEventListener("touchend",y.upHandler),w.cancelable&&(w.preventDefault(),w.stopPropagation()),h((T=w.touches[0])==null?void 0:T.clientX)}},b=R0()?{passive:!1}:!1;pr(i)?(f?.addEventListener("touchmove",y.moveHandler,b),f?.addEventListener("touchend",y.upHandler,b)):(f?.addEventListener("mousemove",v.moveHandler,b),f?.addEventListener("mouseup",v.upHandler,b)),t.setColumnSizingInfo(w=>({...w,startOffset:l,startSize:s,deltaOffset:0,deltaPercentage:0,columnSizingStart:a,isResizingColumn:o.id}))}}},createTable:e=>{e.setColumnSizing=t=>e.options.onColumnSizingChange==null?void 0:e.options.onColumnSizingChange(t),e.setColumnSizingInfo=t=>e.options.onColumnSizingInfoChange==null?void 0:e.options.onColumnSizingInfoChange(t),e.resetColumnSizing=t=>{var n;e.setColumnSizing(t?{}:(n=e.initialState.columnSizing)!=null?n:{})},e.resetHeaderSizeInfo=t=>{var n;e.setColumnSizingInfo(t?mr():(n=e.initialState.columnSizingInfo)!=null?n:mr())},e.getTotalSize=()=>{var t,n;return(t=(n=e.getHeaderGroups()[0])==null?void 0:n.headers.reduce((o,r)=>o+r.getSize(),0))!=null?t:0},e.getLeftTotalSize=()=>{var t,n;return(t=(n=e.getLeftHeaderGroups()[0])==null?void 0:n.headers.reduce((o,r)=>o+r.getSize(),0))!=null?t:0},e.getCenterTotalSize=()=>{var t,n;return(t=(n=e.getCenterHeaderGroups()[0])==null?void 0:n.headers.reduce((o,r)=>o+r.getSize(),0))!=null?t:0},e.getRightTotalSize=()=>{var t,n;return(t=(n=e.getRightHeaderGroups()[0])==null?void 0:n.headers.reduce((o,r)=>o+r.getSize(),0))!=null?t:0}}};let bn=null;function R0(){if(typeof bn=="boolean")return bn;let e=!1;try{const t={get passive(){return e=!0,!1}},n=()=>{};window.addEventListener("test",n,t),window.removeEventListener("test",n)}catch{e=!1}return bn=e,bn}function pr(e){return e.type==="touchstart"}const _0={getInitialState:e=>({columnVisibility:{},...e}),getDefaultOptions:e=>({onColumnVisibilityChange:de("columnVisibility",e)}),createColumn:(e,t)=>{e.toggleVisibility=n=>{e.getCanHide()&&t.setColumnVisibility(o=>({...o,[e.id]:n??!e.getIsVisible()}))},e.getIsVisible=()=>{var n,o;const r=e.columns;return(n=r.length?r.some(i=>i.getIsVisible()):(o=t.getState().columnVisibility)==null?void 0:o[e.id])!=null?n:!0},e.getCanHide=()=>{var n,o;return((n=e.columnDef.enableHiding)!=null?n:!0)&&((o=t.options.enableHiding)!=null?o:!0)},e.getToggleVisibilityHandler=()=>n=>{e.toggleVisibility==null||e.toggleVisibility(n.target.checked)}},createRow:(e,t)=>{e._getAllVisibleCells=A(()=>[e.getAllCells(),t.getState().columnVisibility],n=>n.filter(o=>o.column.getIsVisible()),I(t.options,"debugRows","_getAllVisibleCells")),e.getVisibleCells=A(()=>[e.getLeftVisibleCells(),e.getCenterVisibleCells(),e.getRightVisibleCells()],(n,o,r)=>[...n,...o,...r],I(t.options,"debugRows","getVisibleCells"))},createTable:e=>{const t=(n,o)=>A(()=>[o(),o().filter(r=>r.getIsVisible()).map(r=>r.id).join("_")],r=>r.filter(i=>i.getIsVisible==null?void 0:i.getIsVisible()),I(e.options,"debugColumns",n));e.getVisibleFlatColumns=t("getVisibleFlatColumns",()=>e.getAllFlatColumns()),e.getVisibleLeafColumns=t("getVisibleLeafColumns",()=>e.getAllLeafColumns()),e.getLeftVisibleLeafColumns=t("getLeftVisibleLeafColumns",()=>e.getLeftLeafColumns()),e.getRightVisibleLeafColumns=t("getRightVisibleLeafColumns",()=>e.getRightLeafColumns()),e.getCenterVisibleLeafColumns=t("getCenterVisibleLeafColumns",()=>e.getCenterLeafColumns()),e.setColumnVisibility=n=>e.options.onColumnVisibilityChange==null?void 0:e.options.onColumnVisibilityChange(n),e.resetColumnVisibility=n=>{var o;e.setColumnVisibility(n?{}:(o=e.initialState.columnVisibility)!=null?o:{})},e.toggleAllColumnsVisible=n=>{var o;n=(o=n)!=null?o:!e.getIsAllColumnsVisible(),e.setColumnVisibility(e.getAllLeafColumns().reduce((r,i)=>({...r,[i.id]:n||!(i.getCanHide!=null&&i.getCanHide())}),{}))},e.getIsAllColumnsVisible=()=>!e.getAllLeafColumns().some(n=>!(n.getIsVisible!=null&&n.getIsVisible())),e.getIsSomeColumnsVisible=()=>e.getAllLeafColumns().some(n=>n.getIsVisible==null?void 0:n.getIsVisible()),e.getToggleAllColumnsVisibilityHandler=()=>n=>{var o;e.toggleAllColumnsVisible((o=n.target)==null?void 0:o.checked)}}};function Ot(e,t){return t?t==="center"?e.getCenterVisibleLeafColumns():t==="left"?e.getLeftVisibleLeafColumns():e.getRightVisibleLeafColumns():e.getVisibleLeafColumns()}const N0={createTable:e=>{e._getGlobalFacetedRowModel=e.options.getFacetedRowModel&&e.options.getFacetedRowModel(e,"__global__"),e.getGlobalFacetedRowModel=()=>e.options.manualFiltering||!e._getGlobalFacetedRowModel?e.getPreFilteredRowModel():e._getGlobalFacetedRowModel(),e._getGlobalFacetedUniqueValues=e.options.getFacetedUniqueValues&&e.options.getFacetedUniqueValues(e,"__global__"),e.getGlobalFacetedUniqueValues=()=>e._getGlobalFacetedUniqueValues?e._getGlobalFacetedUniqueValues():new Map,e._getGlobalFacetedMinMaxValues=e.options.getFacetedMinMaxValues&&e.options.getFacetedMinMaxValues(e,"__global__"),e.getGlobalFacetedMinMaxValues=()=>{if(e._getGlobalFacetedMinMaxValues)return e._getGlobalFacetedMinMaxValues()}}},B0={getInitialState:e=>({globalFilter:void 0,...e}),getDefaultOptions:e=>({onGlobalFilterChange:de("globalFilter",e),globalFilterFn:"auto",getColumnCanGlobalFilter:t=>{var n;const o=(n=e.getCoreRowModel().flatRows[0])==null||(n=n._getAllCellsByColumnId()[t.id])==null?void 0:n.getValue();return typeof o=="string"||typeof o=="number"}}),createColumn:(e,t)=>{e.getCanGlobalFilter=()=>{var n,o,r,i;return((n=e.columnDef.enableGlobalFilter)!=null?n:!0)&&((o=t.options.enableGlobalFilter)!=null?o:!0)&&((r=t.options.enableFilters)!=null?r:!0)&&((i=t.options.getColumnCanGlobalFilter==null?void 0:t.options.getColumnCanGlobalFilter(e))!=null?i:!0)&&!!e.accessorFn}},createTable:e=>{e.getGlobalAutoFilterFn=()=>Ae.includesString,e.getGlobalFilterFn=()=>{var t,n;const{globalFilterFn:o}=e.options;return vn(o)?o:o==="auto"?e.getGlobalAutoFilterFn():(t=(n=e.options.filterFns)==null?void 0:n[o])!=null?t:Ae[o]},e.setGlobalFilter=t=>{e.options.onGlobalFilterChange==null||e.options.onGlobalFilterChange(t)},e.resetGlobalFilter=t=>{e.setGlobalFilter(t?void 0:e.initialState.globalFilter)}}},z0={getInitialState:e=>({expanded:{},...e}),getDefaultOptions:e=>({onExpandedChange:de("expanded",e),paginateExpandedRows:!0}),createTable:e=>{let t=!1,n=!1;e._autoResetExpanded=()=>{var o,r;if(!t){e._queue(()=>{t=!0});return}if((o=(r=e.options.autoResetAll)!=null?r:e.options.autoResetExpanded)!=null?o:!e.options.manualExpanding){if(n)return;n=!0,e._queue(()=>{e.resetExpanded(),n=!1})}},e.setExpanded=o=>e.options.onExpandedChange==null?void 0:e.options.onExpandedChange(o),e.toggleAllRowsExpanded=o=>{o??!e.getIsAllRowsExpanded()?e.setExpanded(!0):e.setExpanded({})},e.resetExpanded=o=>{var r,i;e.setExpanded(o?{}:(r=(i=e.initialState)==null?void 0:i.expanded)!=null?r:{})},e.getCanSomeRowsExpand=()=>e.getPrePaginationRowModel().flatRows.some(o=>o.getCanExpand()),e.getToggleAllRowsExpandedHandler=()=>o=>{o.persist==null||o.persist(),e.toggleAllRowsExpanded()},e.getIsSomeRowsExpanded=()=>{const o=e.getState().expanded;return o===!0||Object.values(o).some(Boolean)},e.getIsAllRowsExpanded=()=>{const o=e.getState().expanded;return typeof o=="boolean"?o===!0:!(!Object.keys(o).length||e.getRowModel().flatRows.some(r=>!r.getIsExpanded()))},e.getExpandedDepth=()=>{let o=0;return(e.getState().expanded===!0?Object.keys(e.getRowModel().rowsById):Object.keys(e.getState().expanded)).forEach(i=>{const s=i.split(".");o=Math.max(o,s.length)}),o},e.getPreExpandedRowModel=()=>e.getSortedRowModel(),e.getExpandedRowModel=()=>(!e._getExpandedRowModel&&e.options.getExpandedRowModel&&(e._getExpandedRowModel=e.options.getExpandedRowModel(e)),e.options.manualExpanding||!e._getExpandedRowModel?e.getPreExpandedRowModel():e._getExpandedRowModel())},createRow:(e,t)=>{e.toggleExpanded=n=>{t.setExpanded(o=>{var r;const i=o===!0?!0:!!(o!=null&&o[e.id]);let s={};if(o===!0?Object.keys(t.getRowModel().rowsById).forEach(a=>{s[a]=!0}):s=o,n=(r=n)!=null?r:!i,!i&&n)return{...s,[e.id]:!0};if(i&&!n){const{[e.id]:a,...l}=s;return l}return o})},e.getIsExpanded=()=>{var n;const o=t.getState().expanded;return!!((n=t.options.getIsRowExpanded==null?void 0:t.options.getIsRowExpanded(e))!=null?n:o===!0||o?.[e.id])},e.getCanExpand=()=>{var n,o,r;return(n=t.options.getRowCanExpand==null?void 0:t.options.getRowCanExpand(e))!=null?n:((o=t.options.enableExpanding)!=null?o:!0)&&!!((r=e.subRows)!=null&&r.length)},e.getIsAllParentsExpanded=()=>{let n=!0,o=e;for(;n&&o.parentId;)o=t.getRow(o.parentId,!0),n=o.getIsExpanded();return n},e.getToggleExpandedHandler=()=>{const n=e.getCanExpand();return()=>{n&&e.toggleExpanded()}}}},gr=0,vr=10,yr=()=>({pageIndex:gr,pageSize:vr}),O0={getInitialState:e=>({...e,pagination:{...yr(),...e?.pagination}}),getDefaultOptions:e=>({onPaginationChange:de("pagination",e)}),createTable:e=>{let t=!1,n=!1;e._autoResetPageIndex=()=>{var o,r;if(!t){e._queue(()=>{t=!0});return}if((o=(r=e.options.autoResetAll)!=null?r:e.options.autoResetPageIndex)!=null?o:!e.options.manualPagination){if(n)return;n=!0,e._queue(()=>{e.resetPageIndex(),n=!1})}},e.setPagination=o=>{const r=i=>He(o,i);return e.options.onPaginationChange==null?void 0:e.options.onPaginationChange(r)},e.resetPagination=o=>{var r;e.setPagination(o?yr():(r=e.initialState.pagination)!=null?r:yr())},e.setPageIndex=o=>{e.setPagination(r=>{let i=He(o,r.pageIndex);const s=typeof e.options.pageCount>"u"||e.options.pageCount===-1?Number.MAX_SAFE_INTEGER:e.options.pageCount-1;return i=Math.max(0,Math.min(i,s)),{...r,pageIndex:i}})},e.resetPageIndex=o=>{var r,i;e.setPageIndex(o?gr:(r=(i=e.initialState)==null||(i=i.pagination)==null?void 0:i.pageIndex)!=null?r:gr)},e.resetPageSize=o=>{var r,i;e.setPageSize(o?vr:(r=(i=e.initialState)==null||(i=i.pagination)==null?void 0:i.pageSize)!=null?r:vr)},e.setPageSize=o=>{e.setPagination(r=>{const i=Math.max(1,He(o,r.pageSize)),s=r.pageSize*r.pageIndex,a=Math.floor(s/i);return{...r,pageIndex:a,pageSize:i}})},e.setPageCount=o=>e.setPagination(r=>{var i;let s=He(o,(i=e.options.pageCount)!=null?i:-1);return typeof s=="number"&&(s=Math.max(-1,s)),{...r,pageCount:s}}),e.getPageOptions=A(()=>[e.getPageCount()],o=>{let r=[];return o&&o>0&&(r=[...new Array(o)].fill(null).map((i,s)=>s)),r},I(e.options,"debugTable","getPageOptions")),e.getCanPreviousPage=()=>e.getState().pagination.pageIndex>0,e.getCanNextPage=()=>{const{pageIndex:o}=e.getState().pagination,r=e.getPageCount();return r===-1?!0:r===0?!1:o<r-1},e.previousPage=()=>e.setPageIndex(o=>o-1),e.nextPage=()=>e.setPageIndex(o=>o+1),e.firstPage=()=>e.setPageIndex(0),e.lastPage=()=>e.setPageIndex(e.getPageCount()-1),e.getPrePaginationRowModel=()=>e.getExpandedRowModel(),e.getPaginationRowModel=()=>(!e._getPaginationRowModel&&e.options.getPaginationRowModel&&(e._getPaginationRowModel=e.options.getPaginationRowModel(e)),e.options.manualPagination||!e._getPaginationRowModel?e.getPrePaginationRowModel():e._getPaginationRowModel()),e.getPageCount=()=>{var o;return(o=e.options.pageCount)!=null?o:Math.ceil(e.getRowCount()/e.getState().pagination.pageSize)},e.getRowCount=()=>{var o;return(o=e.options.rowCount)!=null?o:e.getPrePaginationRowModel().rows.length}}},wr=()=>({top:[],bottom:[]}),H0={getInitialState:e=>({rowPinning:wr(),...e}),getDefaultOptions:e=>({onRowPinningChange:de("rowPinning",e)}),createRow:(e,t)=>{e.pin=(n,o,r)=>{const i=o?e.getLeafRows().map(l=>{let{id:c}=l;return c}):[],s=r?e.getParentRows().map(l=>{let{id:c}=l;return c}):[],a=new Set([...s,e.id,...i]);t.setRowPinning(l=>{var c,d;if(n==="bottom"){var u,h;return{top:((u=l?.top)!=null?u:[]).filter(y=>!(a!=null&&a.has(y))),bottom:[...((h=l?.bottom)!=null?h:[]).filter(y=>!(a!=null&&a.has(y))),...Array.from(a)]}}if(n==="top"){var f,v;return{top:[...((f=l?.top)!=null?f:[]).filter(y=>!(a!=null&&a.has(y))),...Array.from(a)],bottom:((v=l?.bottom)!=null?v:[]).filter(y=>!(a!=null&&a.has(y)))}}return{top:((c=l?.top)!=null?c:[]).filter(y=>!(a!=null&&a.has(y))),bottom:((d=l?.bottom)!=null?d:[]).filter(y=>!(a!=null&&a.has(y)))}})},e.getCanPin=()=>{var n;const{enableRowPinning:o,enablePinning:r}=t.options;return typeof o=="function"?o(e):(n=o??r)!=null?n:!0},e.getIsPinned=()=>{const n=[e.id],{top:o,bottom:r}=t.getState().rowPinning,i=n.some(a=>o?.includes(a)),s=n.some(a=>r?.includes(a));return i?"top":s?"bottom":!1},e.getPinnedIndex=()=>{var n,o;const r=e.getIsPinned();if(!r)return-1;const i=(n=r==="top"?t.getTopRows():t.getBottomRows())==null?void 0:n.map(s=>{let{id:a}=s;return a});return(o=i?.indexOf(e.id))!=null?o:-1}},createTable:e=>{e.setRowPinning=t=>e.options.onRowPinningChange==null?void 0:e.options.onRowPinningChange(t),e.resetRowPinning=t=>{var n,o;return e.setRowPinning(t?wr():(n=(o=e.initialState)==null?void 0:o.rowPinning)!=null?n:wr())},e.getIsSomeRowsPinned=t=>{var n;const o=e.getState().rowPinning;if(!t){var r,i;return!!((r=o.top)!=null&&r.length||(i=o.bottom)!=null&&i.length)}return!!((n=o[t])!=null&&n.length)},e._getPinnedRows=(t,n,o)=>{var r;return((r=e.options.keepPinnedRows)==null||r?(n??[]).map(s=>{const a=e.getRow(s,!0);return a.getIsAllParentsExpanded()?a:null}):(n??[]).map(s=>t.find(a=>a.id===s))).filter(Boolean).map(s=>({...s,position:o}))},e.getTopRows=A(()=>[e.getRowModel().rows,e.getState().rowPinning.top],(t,n)=>e._getPinnedRows(t,n,"top"),I(e.options,"debugRows","getTopRows")),e.getBottomRows=A(()=>[e.getRowModel().rows,e.getState().rowPinning.bottom],(t,n)=>e._getPinnedRows(t,n,"bottom"),I(e.options,"debugRows","getBottomRows")),e.getCenterRows=A(()=>[e.getRowModel().rows,e.getState().rowPinning.top,e.getState().rowPinning.bottom],(t,n,o)=>{const r=new Set([...n??[],...o??[]]);return t.filter(i=>!r.has(i.id))},I(e.options,"debugRows","getCenterRows"))}},j0={getInitialState:e=>({rowSelection:{},...e}),getDefaultOptions:e=>({onRowSelectionChange:de("rowSelection",e),enableRowSelection:!0,enableMultiRowSelection:!0,enableSubRowSelection:!0}),createTable:e=>{e.setRowSelection=t=>e.options.onRowSelectionChange==null?void 0:e.options.onRowSelectionChange(t),e.resetRowSelection=t=>{var n;return e.setRowSelection(t?{}:(n=e.initialState.rowSelection)!=null?n:{})},e.toggleAllRowsSelected=t=>{e.setRowSelection(n=>{t=typeof t<"u"?t:!e.getIsAllRowsSelected();const o={...n},r=e.getPreGroupedRowModel().flatRows;return t?r.forEach(i=>{i.getCanSelect()&&(o[i.id]=!0)}):r.forEach(i=>{delete o[i.id]}),o})},e.toggleAllPageRowsSelected=t=>e.setRowSelection(n=>{const o=typeof t<"u"?t:!e.getIsAllPageRowsSelected(),r={...n};return e.getRowModel().rows.forEach(i=>{br(r,i.id,o,!0,e)}),r}),e.getPreSelectedRowModel=()=>e.getCoreRowModel(),e.getSelectedRowModel=A(()=>[e.getState().rowSelection,e.getCoreRowModel()],(t,n)=>Object.keys(t).length?xr(e,n):{rows:[],flatRows:[],rowsById:{}},I(e.options,"debugTable","getSelectedRowModel")),e.getFilteredSelectedRowModel=A(()=>[e.getState().rowSelection,e.getFilteredRowModel()],(t,n)=>Object.keys(t).length?xr(e,n):{rows:[],flatRows:[],rowsById:{}},I(e.options,"debugTable","getFilteredSelectedRowModel")),e.getGroupedSelectedRowModel=A(()=>[e.getState().rowSelection,e.getSortedRowModel()],(t,n)=>Object.keys(t).length?xr(e,n):{rows:[],flatRows:[],rowsById:{}},I(e.options,"debugTable","getGroupedSelectedRowModel")),e.getIsAllRowsSelected=()=>{const t=e.getFilteredRowModel().flatRows,{rowSelection:n}=e.getState();let o=!!(t.length&&Object.keys(n).length);return o&&t.some(r=>r.getCanSelect()&&!n[r.id])&&(o=!1),o},e.getIsAllPageRowsSelected=()=>{const t=e.getPaginationRowModel().flatRows.filter(r=>r.getCanSelect()),{rowSelection:n}=e.getState();let o=!!t.length;return o&&t.some(r=>!n[r.id])&&(o=!1),o},e.getIsSomeRowsSelected=()=>{var t;const n=Object.keys((t=e.getState().rowSelection)!=null?t:{}).length;return n>0&&n<e.getFilteredRowModel().flatRows.length},e.getIsSomePageRowsSelected=()=>{const t=e.getPaginationRowModel().flatRows;return e.getIsAllPageRowsSelected()?!1:t.filter(n=>n.getCanSelect()).some(n=>n.getIsSelected()||n.getIsSomeSelected())},e.getToggleAllRowsSelectedHandler=()=>t=>{e.toggleAllRowsSelected(t.target.checked)},e.getToggleAllPageRowsSelectedHandler=()=>t=>{e.toggleAllPageRowsSelected(t.target.checked)}},createRow:(e,t)=>{e.toggleSelected=(n,o)=>{const r=e.getIsSelected();t.setRowSelection(i=>{var s;if(n=typeof n<"u"?n:!r,e.getCanSelect()&&r===n)return i;const a={...i};return br(a,e.id,n,(s=o?.selectChildren)!=null?s:!0,t),a})},e.getIsSelected=()=>{const{rowSelection:n}=t.getState();return Sr(e,n)},e.getIsSomeSelected=()=>{const{rowSelection:n}=t.getState();return Cr(e,n)==="some"},e.getIsAllSubRowsSelected=()=>{const{rowSelection:n}=t.getState();return Cr(e,n)==="all"},e.getCanSelect=()=>{var n;return typeof t.options.enableRowSelection=="function"?t.options.enableRowSelection(e):(n=t.options.enableRowSelection)!=null?n:!0},e.getCanSelectSubRows=()=>{var n;return typeof t.options.enableSubRowSelection=="function"?t.options.enableSubRowSelection(e):(n=t.options.enableSubRowSelection)!=null?n:!0},e.getCanMultiSelect=()=>{var n;return typeof t.options.enableMultiRowSelection=="function"?t.options.enableMultiRowSelection(e):(n=t.options.enableMultiRowSelection)!=null?n:!0},e.getToggleSelectedHandler=()=>{const n=e.getCanSelect();return o=>{var r;n&&e.toggleSelected((r=o.target)==null?void 0:r.checked)}}}},br=(e,t,n,o,r)=>{var i;const s=r.getRow(t,!0);n?(s.getCanMultiSelect()||Object.keys(e).forEach(a=>delete e[a]),s.getCanSelect()&&(e[t]=!0)):delete e[t],o&&(i=s.subRows)!=null&&i.length&&s.getCanSelectSubRows()&&s.subRows.forEach(a=>br(e,a.id,n,o,r))};function xr(e,t){const n=e.getState().rowSelection,o=[],r={},i=function(s,a){return s.map(l=>{var c;const d=Sr(l,n);if(d&&(o.push(l),r[l.id]=l),(c=l.subRows)!=null&&c.length&&(l={...l,subRows:i(l.subRows)}),d)return l}).filter(Boolean)};return{rows:i(t.rows),flatRows:o,rowsById:r}}function Sr(e,t){var n;return(n=t[e.id])!=null?n:!1}function Cr(e,t,n){var o;if(!((o=e.subRows)!=null&&o.length))return!1;let r=!0,i=!1;return e.subRows.forEach(s=>{if(!(i&&!r)&&(s.getCanSelect()&&(Sr(s,t)?i=!0:r=!1),s.subRows&&s.subRows.length)){const a=Cr(s,t);a==="all"?i=!0:(a==="some"&&(i=!0),r=!1)}}),r?"all":i?"some":!1}const Tr=/([0-9]+)/gm,G0=(e,t,n)=>Bl(je(e.getValue(n)).toLowerCase(),je(t.getValue(n)).toLowerCase()),U0=(e,t,n)=>Bl(je(e.getValue(n)),je(t.getValue(n))),K0=(e,t,n)=>$r(je(e.getValue(n)).toLowerCase(),je(t.getValue(n)).toLowerCase()),W0=(e,t,n)=>$r(je(e.getValue(n)),je(t.getValue(n))),q0=(e,t,n)=>{const o=e.getValue(n),r=t.getValue(n);return o>r?1:o<r?-1:0},Y0=(e,t,n)=>$r(e.getValue(n),t.getValue(n));function $r(e,t){return e===t?0:e>t?1:-1}function je(e){return typeof e=="number"?isNaN(e)||e===1/0||e===-1/0?"":String(e):typeof e=="string"?e:""}function Bl(e,t){const n=e.split(Tr).filter(Boolean),o=t.split(Tr).filter(Boolean);for(;n.length&&o.length;){const r=n.shift(),i=o.shift(),s=parseInt(r,10),a=parseInt(i,10),l=[s,a].sort();if(isNaN(l[0])){if(r>i)return 1;if(i>r)return-1;continue}if(isNaN(l[1]))return isNaN(s)?-1:1;if(s>a)return 1;if(a>s)return-1}return n.length-o.length}const Ht={alphanumeric:G0,alphanumericCaseSensitive:U0,text:K0,textCaseSensitive:W0,datetime:q0,basic:Y0},X0=[k0,_0,F0,A0,M0,V0,N0,B0,{getInitialState:e=>({sorting:[],...e}),getDefaultColumnDef:()=>({sortingFn:"auto",sortUndefined:1}),getDefaultOptions:e=>({onSortingChange:de("sorting",e),isMultiSortEvent:t=>t.shiftKey}),createColumn:(e,t)=>{e.getAutoSortingFn=()=>{const n=t.getFilteredRowModel().flatRows.slice(10);let o=!1;for(const r of n){const i=r?.getValue(e.id);if(Object.prototype.toString.call(i)==="[object Date]")return Ht.datetime;if(typeof i=="string"&&(o=!0,i.split(Tr).length>1))return Ht.alphanumeric}return o?Ht.text:Ht.basic},e.getAutoSortDir=()=>{const n=t.getFilteredRowModel().flatRows[0];return typeof n?.getValue(e.id)=="string"?"asc":"desc"},e.getSortingFn=()=>{var n,o;if(!e)throw new Error;return vn(e.columnDef.sortingFn)?e.columnDef.sortingFn:e.columnDef.sortingFn==="auto"?e.getAutoSortingFn():(n=(o=t.options.sortingFns)==null?void 0:o[e.columnDef.sortingFn])!=null?n:Ht[e.columnDef.sortingFn]},e.toggleSorting=(n,o)=>{const r=e.getNextSortingOrder(),i=typeof n<"u"&&n!==null;t.setSorting(s=>{const a=s?.find(f=>f.id===e.id),l=s?.findIndex(f=>f.id===e.id);let c=[],d,u=i?n:r==="desc";if(s!=null&&s.length&&e.getCanMultiSort()&&o?a?d="toggle":d="add":s!=null&&s.length&&l!==s.length-1?d="replace":a?d="toggle":d="replace",d==="toggle"&&(i||r||(d="remove")),d==="add"){var h;c=[...s,{id:e.id,desc:u}],c.splice(0,c.length-((h=t.options.maxMultiSortColCount)!=null?h:Number.MAX_SAFE_INTEGER))}else d==="toggle"?c=s.map(f=>f.id===e.id?{...f,desc:u}:f):d==="remove"?c=s.filter(f=>f.id!==e.id):c=[{id:e.id,desc:u}];return c})},e.getFirstSortDir=()=>{var n,o;return((n=(o=e.columnDef.sortDescFirst)!=null?o:t.options.sortDescFirst)!=null?n:e.getAutoSortDir()==="desc")?"desc":"asc"},e.getNextSortingOrder=n=>{var o,r;const i=e.getFirstSortDir(),s=e.getIsSorted();return s?s!==i&&((o=t.options.enableSortingRemoval)==null||o)&&(!(n&&(r=t.options.enableMultiRemove)!=null)||r)?!1:s==="desc"?"asc":"desc":i},e.getCanSort=()=>{var n,o;return((n=e.columnDef.enableSorting)!=null?n:!0)&&((o=t.options.enableSorting)!=null?o:!0)&&!!e.accessorFn},e.getCanMultiSort=()=>{var n,o;return(n=(o=e.columnDef.enableMultiSort)!=null?o:t.options.enableMultiSort)!=null?n:!!e.accessorFn},e.getIsSorted=()=>{var n;const o=(n=t.getState().sorting)==null?void 0:n.find(r=>r.id===e.id);return o?o.desc?"desc":"asc":!1},e.getSortIndex=()=>{var n,o;return(n=(o=t.getState().sorting)==null?void 0:o.findIndex(r=>r.id===e.id))!=null?n:-1},e.clearSorting=()=>{t.setSorting(n=>n!=null&&n.length?n.filter(o=>o.id!==e.id):[])},e.getToggleSortingHandler=()=>{const n=e.getCanSort();return o=>{n&&(o.persist==null||o.persist(),e.toggleSorting==null||e.toggleSorting(void 0,e.getCanMultiSort()?t.options.isMultiSortEvent==null?void 0:t.options.isMultiSortEvent(o):!1))}}},createTable:e=>{e.setSorting=t=>e.options.onSortingChange==null?void 0:e.options.onSortingChange(t),e.resetSorting=t=>{var n,o;e.setSorting(t?[]:(n=(o=e.initialState)==null?void 0:o.sorting)!=null?n:[])},e.getPreSortedRowModel=()=>e.getGroupedRowModel(),e.getSortedRowModel=()=>(!e._getSortedRowModel&&e.options.getSortedRowModel&&(e._getSortedRowModel=e.options.getSortedRowModel(e)),e.options.manualSorting||!e._getSortedRowModel?e.getPreSortedRowModel():e._getSortedRowModel())}},E0,z0,O0,H0,j0,L0];function Z0(e){var t,n;process.env.NODE_ENV!=="production"&&(e.debugAll||e.debugTable)&&console.info("Creating Table Instance...");const o=[...X0,...(t=e._features)!=null?t:[]];let r={_features:o};const i=r._features.reduce((h,f)=>Object.assign(h,f.getDefaultOptions==null?void 0:f.getDefaultOptions(r)),{}),s=h=>r.options.mergeOptions?r.options.mergeOptions(i,h):{...i,...h};let l={...{},...(n=e.initialState)!=null?n:{}};r._features.forEach(h=>{var f;l=(f=h.getInitialState==null?void 0:h.getInitialState(l))!=null?f:l});const c=[];let d=!1;const u={_features:o,options:{...i,...e},initialState:l,_queue:h=>{c.push(h),d||(d=!0,Promise.resolve().then(()=>{for(;c.length;)c.shift()();d=!1}).catch(f=>setTimeout(()=>{throw f})))},reset:()=>{r.setState(r.initialState)},setOptions:h=>{const f=He(h,r.options);r.options=s(f)},getState:()=>r.options.state,setState:h=>{r.options.onStateChange==null||r.options.onStateChange(h)},_getRowId:(h,f,v)=>{var y;return(y=r.options.getRowId==null?void 0:r.options.getRowId(h,f,v))!=null?y:`${v?[v.id,f].join("."):f}`},getCoreRowModel:()=>(r._getCoreRowModel||(r._getCoreRowModel=r.options.getCoreRowModel(r)),r._getCoreRowModel()),getRowModel:()=>r.getPaginationRowModel(),getRow:(h,f)=>{let v=(f?r.getPrePaginationRowModel():r.getRowModel()).rowsById[h];if(!v&&(v=r.getCoreRowModel().rowsById[h],!v))throw process.env.NODE_ENV!=="production"?new Error(`getRow could not find row with ID: ${h}`):new Error;return v},_getDefaultColumnDef:A(()=>[r.options.defaultColumn],h=>{var f;return h=(f=h)!=null?f:{},{header:v=>{const y=v.header.column.columnDef;return y.accessorKey?y.accessorKey:y.accessorFn?y.id:null},cell:v=>{var y,b;return(y=(b=v.renderValue())==null||b.toString==null?void 0:b.toString())!=null?y:null},...r._features.reduce((v,y)=>Object.assign(v,y.getDefaultColumnDef==null?void 0:y.getDefaultColumnDef()),{}),...h}},I(e,"debugColumns","_getDefaultColumnDef")),_getColumnDefs:()=>r.options.columns,getAllColumns:A(()=>[r._getColumnDefs()],h=>{const f=function(v,y,b){return b===void 0&&(b=0),v.map(w=>{const T=P0(r,w,b,y),C=w;return T.columns=C.columns?f(C.columns,T,b+1):[],T})};return f(h)},I(e,"debugColumns","getAllColumns")),getAllFlatColumns:A(()=>[r.getAllColumns()],h=>h.flatMap(f=>f.getFlatColumns()),I(e,"debugColumns","getAllFlatColumns")),_getAllFlatColumnsById:A(()=>[r.getAllFlatColumns()],h=>h.reduce((f,v)=>(f[v.id]=v,f),{}),I(e,"debugColumns","getAllFlatColumnsById")),getAllLeafColumns:A(()=>[r.getAllColumns(),r._getOrderColumnsFn()],(h,f)=>{let v=h.flatMap(y=>y.getLeafColumns());return f(v)},I(e,"debugColumns","getAllLeafColumns")),getColumn:h=>{const f=r._getAllFlatColumnsById()[h];return process.env.NODE_ENV!=="production"&&!f&&console.error(`[Table] Column with id '${h}' does not exist.`),f}};Object.assign(r,u);for(let h=0;h<r._features.length;h++){const f=r._features[h];f==null||f.createTable==null||f.createTable(r)}return r}function J0(){return e=>A(()=>[e.options.data],t=>{const n={rows:[],flatRows:[],rowsById:{}},o=function(r,i,s){i===void 0&&(i=0);const a=[];for(let c=0;c<r.length;c++){const d=ur(e,e._getRowId(r[c],c,s),r[c],c,i,void 0,s?.id);if(n.flatRows.push(d),n.rowsById[d.id]=d,a.push(d),e.options.getSubRows){var l;d.originalSubRows=e.options.getSubRows(r[c],c),(l=d.originalSubRows)!=null&&l.length&&(d.subRows=o(d.originalSubRows,i+1,d))}}return a};return n.rows=o(t),n},I(e.options,"debugTable","getRowModel",()=>e._autoResetPageIndex()))}function Q0(e,t,n){return n.options.filterFromLeafRows?ev(e,t,n):tv(e,t,n)}function ev(e,t,n){var o;const r=[],i={},s=(o=n.options.maxLeafRowFilterDepth)!=null?o:100,a=function(l,c){c===void 0&&(c=0);const d=[];for(let h=0;h<l.length;h++){var u;let f=l[h];const v=ur(n,f.id,f.original,f.index,f.depth,void 0,f.parentId);if(v.columnFilters=f.columnFilters,(u=f.subRows)!=null&&u.length&&c<s){if(v.subRows=a(f.subRows,c+1),f=v,t(f)&&!v.subRows.length){d.push(f),i[f.id]=f,r.push(f);continue}if(t(f)||v.subRows.length){d.push(f),i[f.id]=f,r.push(f);continue}}else f=v,t(f)&&(d.push(f),i[f.id]=f,r.push(f))}return d};return{rows:a(e),flatRows:r,rowsById:i}}function tv(e,t,n){var o;const r=[],i={},s=(o=n.options.maxLeafRowFilterDepth)!=null?o:100,a=function(l,c){c===void 0&&(c=0);const d=[];for(let h=0;h<l.length;h++){let f=l[h];if(t(f)){var u;if((u=f.subRows)!=null&&u.length&&c<s){const y=ur(n,f.id,f.original,f.index,f.depth,void 0,f.parentId);y.subRows=a(f.subRows,c+1),f=y}d.push(f),r.push(f),i[f.id]=f}}return d};return{rows:a(e),flatRows:r,rowsById:i}}function nv(){return e=>A(()=>[e.getPreFilteredRowModel(),e.getState().columnFilters,e.getState().globalFilter],(t,n,o)=>{if(!t.rows.length||!(n!=null&&n.length)&&!o){for(let h=0;h<t.flatRows.length;h++)t.flatRows[h].columnFilters={},t.flatRows[h].columnFiltersMeta={};return t}const r=[],i=[];(n??[]).forEach(h=>{var f;const v=e.getColumn(h.id);if(!v)return;const y=v.getFilterFn();if(!y){process.env.NODE_ENV!=="production"&&console.warn(`Could not find a valid 'column.filterFn' for column with the ID: ${v.id}.`);return}r.push({id:h.id,filterFn:y,resolvedValue:(f=y.resolveFilterValue==null?void 0:y.resolveFilterValue(h.value))!=null?f:h.value})});const s=(n??[]).map(h=>h.id),a=e.getGlobalFilterFn(),l=e.getAllLeafColumns().filter(h=>h.getCanGlobalFilter());o&&a&&l.length&&(s.push("__global__"),l.forEach(h=>{var f;i.push({id:h.id,filterFn:a,resolvedValue:(f=a.resolveFilterValue==null?void 0:a.resolveFilterValue(o))!=null?f:o})}));let c,d;for(let h=0;h<t.flatRows.length;h++){const f=t.flatRows[h];if(f.columnFilters={},r.length)for(let v=0;v<r.length;v++){c=r[v];const y=c.id;f.columnFilters[y]=c.filterFn(f,y,c.resolvedValue,b=>{f.columnFiltersMeta[y]=b})}if(i.length){for(let v=0;v<i.length;v++){d=i[v];const y=d.id;if(d.filterFn(f,y,d.resolvedValue,b=>{f.columnFiltersMeta[y]=b})){f.columnFilters.__global__=!0;break}}f.columnFilters.__global__!==!0&&(f.columnFilters.__global__=!1)}}const u=h=>{for(let f=0;f<s.length;f++)if(h.columnFilters[s[f]]===!1)return!1;return!0};return Q0(t.rows,u,e)},I(e.options,"debugTable","getFilteredRowModel",()=>e._autoResetPageIndex()))}function ov(){return e=>A(()=>[e.getState().sorting,e.getPreSortedRowModel()],(t,n)=>{if(!n.rows.length||!(t!=null&&t.length))return n;const o=e.getState().sorting,r=[],i=o.filter(l=>{var c;return(c=e.getColumn(l.id))==null?void 0:c.getCanSort()}),s={};i.forEach(l=>{const c=e.getColumn(l.id);c&&(s[l.id]={sortUndefined:c.columnDef.sortUndefined,invertSorting:c.columnDef.invertSorting,sortingFn:c.getSortingFn()})});const a=l=>{const c=l.map(d=>({...d}));return c.sort((d,u)=>{for(let f=0;f<i.length;f+=1){var h;const v=i[f],y=s[v.id],b=y.sortUndefined,w=(h=v?.desc)!=null?h:!1;let T=0;if(b){const C=d.getValue(v.id),k=u.getValue(v.id),x=C===void 0,P=k===void 0;if(x||P){if(b==="first")return x?-1:1;if(b==="last")return x?1:-1;T=x&&P?0:x?b:-b}}if(T===0&&(T=y.sortingFn(d,u,v.id)),T!==0)return w&&(T*=-1),y.invertSorting&&(T*=-1),T}return d.index-u.index}),c.forEach(d=>{var u;r.push(d),(u=d.subRows)!=null&&u.length&&(d.subRows=a(d.subRows))}),c};return{rows:a(n.rows),flatRows:r,rowsById:n.rowsById}},I(e.options,"debugTable","getSortedRowModel",()=>e._autoResetPageIndex()))}function xn(e,t){return e?rv(e)?Ue.createElement(e,t):e:null}function rv(e){return iv(e)||typeof e=="function"||sv(e)}function iv(e){return typeof e=="function"&&(()=>{const t=Object.getPrototypeOf(e);return t.prototype&&t.prototype.isReactComponent})()}function sv(e){return typeof e=="object"&&typeof e.$$typeof=="symbol"&&["react.memo","react.forward_ref"].includes(e.$$typeof.description)}function av(e){const t={state:{},onStateChange:()=>{},renderFallbackValue:null,...e},[n]=Ue.useState(()=>({current:Z0(t)})),[o,r]=Ue.useState(()=>n.current.initialState);return n.current.setOptions(i=>({...i,...e,state:{...o,...e.state},onStateChange:s=>{r(s),e.onStateChange==null||e.onStateChange(s)}})),n.current}const lv=g.css`
1614
1614
  @media (max-width: 768px) {
1615
1615
  font-size: 0.875rem;
1616
1616
 
@@ -1619,7 +1619,7 @@
1619
1619
  padding: 0.5rem 0.75rem;
1620
1620
  }
1621
1621
  }
1622
- `,uv={default:g.css`
1622
+ `,cv={default:g.css`
1623
1623
  thead tr:last-child th:first-child {
1624
1624
  border-top-left-radius: var(--border-radius-article);
1625
1625
  }
@@ -1656,7 +1656,7 @@
1656
1656
  tbody tr:last-child td:last-child {
1657
1657
  border-bottom-right-radius: var(--border-radius-article);
1658
1658
  }
1659
- `},ht={sm:g.css`
1659
+ `},Qe={sm:g.css`
1660
1660
  padding: 0.5rem 1rem;
1661
1661
  min-height: 2.25rem;
1662
1662
  `,md:g.css`
@@ -1665,17 +1665,17 @@
1665
1665
  `,lg:g.css`
1666
1666
  padding: 0.75rem 1.5rem;
1667
1667
  min-height: 2.75rem;
1668
- `},Hl=g.css`
1668
+ `},zl=g.css`
1669
1669
  display: flex;
1670
1670
  align-items: center;
1671
1671
  gap: 0.5rem;
1672
1672
  width: 100%;
1673
- `,dv=g.div`
1673
+ `,uv=g.div`
1674
1674
  position: relative;
1675
1675
  border-radius: var(--border-radius-article);
1676
1676
  overflow: ${({$maxHeight:e})=>e?"auto":"visible"};
1677
1677
  max-height: ${({$maxHeight:e})=>e?typeof e=="number"?`${e}px`:e:"none"};
1678
- `,jl=g.table`
1678
+ `,dv=g.table`
1679
1679
  width: 100%;
1680
1680
  border-collapse: separate;
1681
1681
  border-spacing: 0;
@@ -1683,15 +1683,15 @@
1683
1683
  border-radius: var(--border-radius-article);
1684
1684
  border: 1px solid var(--color-main-light-borders);
1685
1685
 
1686
- ${({$variant:e})=>uv[e]}
1687
- ${cv}
1686
+ ${({$variant:e})=>cv[e]}
1687
+ ${lv}
1688
1688
  `,fv=g.thead`
1689
1689
  ${({$sticky:e})=>e&&g.css`
1690
1690
  position: sticky;
1691
1691
  top: 0;
1692
1692
  z-index: 10;
1693
1693
  `}
1694
- `,Gl=g.tr`
1694
+ `,Ol=g.tr`
1695
1695
  &:hover {
1696
1696
  background-color: var(--color-main-alternative-secondary);
1697
1697
  }
@@ -1706,13 +1706,13 @@
1706
1706
  opacity: ${({$direction:e})=>e==="none"?.5:1};
1707
1707
  transform: ${({$direction:e})=>e==="asc"?"rotate(180deg)":"none"};
1708
1708
  `;const hv={sm:g.css`
1709
- ${ht.sm}
1709
+ ${Qe.sm}
1710
1710
  ${E[12]}
1711
1711
  `,md:g.css`
1712
- ${ht.md}
1712
+ ${Qe.md}
1713
1713
  ${E[16]}
1714
1714
  `,lg:g.css`
1715
- ${ht.lg}
1715
+ ${Qe.lg}
1716
1716
  ${E[16]}
1717
1717
  `},mv=g.th`
1718
1718
  background-color: var(--color-main-blue-primary);
@@ -1727,12 +1727,12 @@
1727
1727
  }
1728
1728
 
1729
1729
  ${({$active:e})=>e&&g.css`
1730
- background-color: var(--color-blue-400);
1730
+ background-color: var(--color-blue-600);
1731
1731
  `}
1732
- `,Ul=g.div`
1733
- ${Hl};
1732
+ `,Hl=g.div`
1733
+ ${zl};
1734
1734
  justify-content: ${({$align:e})=>e||"space-between"};
1735
- `,Kl=g.button`
1735
+ `,jl=g.button`
1736
1736
  all: unset;
1737
1737
  display: inline-flex;
1738
1738
  align-items: center;
@@ -1761,7 +1761,7 @@
1761
1761
  transform 0.25s ease-out,
1762
1762
  opacity 0.2s ease-out;
1763
1763
 
1764
- ${Kl}:hover & {
1764
+ ${jl}:hover & {
1765
1765
  opacity: 1;
1766
1766
  }
1767
1767
  `,gv=g.div`
@@ -1779,7 +1779,7 @@
1779
1779
  &:active {
1780
1780
  background-color: var(--color-neutral-200);
1781
1781
  }
1782
- `,$r=m.memo(({value:e,label:t,checked:n,onChange:o})=>{const r=i=>{o(e,i.target.checked)};return p.jsx(gv,{children:p.jsx(Nt,{checked:n,onChange:r,size:"xs",checkboxClassName:"filter-option-checkbox",label:t})})});$r.displayName="FilterOption";function Pr(e,t,n){const o=new Set;return e.forEach((r,i)=>{let s;n?s=n(r,i):s=r[t],s!=null&&o.add(String(s))}),Array.from(o).sort((r,i)=>r.localeCompare(i))}function Wl(e,t,n){const o=n;if(!o||o.length===0)return!0;const r=e.getValue(t);return r!=null?o.includes(String(r)):!1}function ql(e,t){if(!t||t.trim()==="")return e;const n=t.toLowerCase().trim();return e.filter(o=>o.toLowerCase().includes(n))}function vv(e,t,n){const o={};return e.forEach((r,i)=>{let s;if(n?s=n(r,i):s=r[t],s!=null){const a=String(s);o[a]=(o[a]||0)+1}}),o}function yv(e,t){const n=e.find(o=>o.id===t);return n?n.value?.length>0:!1}function Yl(e,t){const n=e.find(o=>o.id===t);return n?n.value||[]:[]}function wv(e){return e.reduce((t,n)=>{const o=n.value;return t+(o?.length||0)},0)}const bv=g.div`
1782
+ `,Pr=m.memo(({value:e,label:t,checked:n,onChange:o})=>{const r=i=>{o(e,i.target.checked)};return p.jsx(gv,{children:p.jsx(zt,{checked:n,onChange:r,size:"xs",checkboxClassName:"filter-option-checkbox",label:t})})});Pr.displayName="FilterOption";function kr(e,t,n){const o=new Set;return e.forEach((r,i)=>{let s;n?s=n(r,i):s=r[t],s!=null&&o.add(String(s))}),Array.from(o).sort((r,i)=>r.localeCompare(i))}function Gl(e,t,n){const o=n;if(!o||o.length===0)return!0;const r=e.getValue(t);return r!=null?o.includes(String(r)):!1}function Ul(e,t){if(!t||t.trim()==="")return e;const n=t.toLowerCase().trim();return e.filter(o=>o.toLowerCase().includes(n))}function vv(e,t,n){const o={};return e.forEach((r,i)=>{let s;if(n?s=n(r,i):s=r[t],s!=null){const a=String(s);o[a]=(o[a]||0)+1}}),o}function yv(e,t){const n=e.find(o=>o.id===t);return n?n.value?.length>0:!1}function Kl(e,t){const n=e.find(o=>o.id===t);return n?n.value||[]:[]}function wv(e){return e.reduce((t,n)=>{const o=n.value;return t+(o?.length||0)},0)}const bv=g.div`
1783
1783
  position: absolute;
1784
1784
  top: 100%;
1785
1785
  right: 0;
@@ -1831,10 +1831,10 @@
1831
1831
  &:active {
1832
1832
  transform: scale(0.98);
1833
1833
  }
1834
- `,Mr=({options:e,selectedValues:t,onChange:n,onClose:o,searchPlaceholder:r="Search..."})=>{const[i,s]=m.useState(""),a=m.useMemo(()=>ql(e,i),[e,i]),l=m.useMemo(()=>a.length===0?!1:a.every(v=>t.includes(v)),[a,t]),c=m.useCallback((v,y)=>{n(y?[...t,v]:t.filter(b=>b!==v))},[t,n]),d=m.useCallback(()=>{const v=[...new Set([...t,...a])];n(v)},[t,a,n]),u=m.useCallback(()=>{const v=t.filter(y=>!a.includes(y));n(v)},[t,a,n]),h=m.useCallback(()=>{n([])},[n]),f=m.useCallback(()=>{o()},[o]);return p.jsx(p.Fragment,{children:p.jsxs(bv,{onClick:v=>v.stopPropagation(),children:[p.jsx("div",{className:"p-2",children:p.jsx(Zo,{value:i,onSearch:s,placeholder:r,size:"xs"})}),a.length>0&&p.jsx(Cv,{children:p.jsx(Tv,{onClick:l?u:d,type:"button",children:l?"Deselect All":"Select All"})}),p.jsx(xv,{children:a.length>0?a.map(v=>p.jsx($r,{value:v,label:v,checked:t.includes(v),onChange:c},v)):p.jsx(_t,{children:i?"No matching options":"No options available"})}),p.jsxs(Sv,{children:[p.jsx(dt,{variant:"outline",size:"sm",onClick:h,disabled:t.length===0,className:"flex-1",children:"Clear"}),p.jsx(dt,{variant:"primary",size:"sm",onClick:f,className:"flex-1",children:"Close"})]})]})})};Mr.displayName="ColumnFilterMenu";function $v(e,t,n=!0){m.useEffect(()=>{if(!n)return;const o=r=>{const i=r.target;e.current&&!e.current.contains(i)&&t()};return document.addEventListener("mousedown",o),()=>{document.removeEventListener("mousedown",o)}},[e,t,n])}const Pv=g.div`
1834
+ `,Mr=({options:e,selectedValues:t,onChange:n,onClose:o,searchPlaceholder:r="Search..."})=>{const[i,s]=m.useState(""),a=m.useMemo(()=>Ul(e,i),[e,i]),l=m.useMemo(()=>a.length===0?!1:a.every(v=>t.includes(v)),[a,t]),c=m.useCallback((v,y)=>{n(y?[...t,v]:t.filter(b=>b!==v))},[t,n]),d=m.useCallback(()=>{const v=[...new Set([...t,...a])];n(v)},[t,a,n]),u=m.useCallback(()=>{const v=t.filter(y=>!a.includes(y));n(v)},[t,a,n]),h=m.useCallback(()=>{n([])},[n]),f=m.useCallback(()=>{o()},[o]);return p.jsx(p.Fragment,{children:p.jsxs(bv,{onClick:v=>v.stopPropagation(),children:[p.jsx("div",{className:"p-2",children:p.jsx(Jo,{value:i,onSearch:s,placeholder:r,size:"xs"})}),a.length>0&&p.jsx(Cv,{children:p.jsx(Tv,{onClick:l?u:d,type:"button",children:l?"Deselect All":"Select All"})}),p.jsx(xv,{children:a.length>0?a.map(v=>p.jsx(Pr,{value:v,label:v,checked:t.includes(v),onChange:c},v)):p.jsx(Nt,{children:i?"No matching options":"No options available"})}),p.jsxs(Sv,{children:[p.jsx(ft,{variant:"outline",size:"sm",onClick:h,disabled:t.length===0,className:"flex-1",children:"Clear"}),p.jsx(ft,{variant:"primary",size:"sm",onClick:f,className:"flex-1",children:"Close"})]})]})})};Mr.displayName="ColumnFilterMenu";function $v(e,t,n=!0){m.useEffect(()=>{if(!n)return;const o=r=>{const i=r.target;e.current&&!e.current.contains(i)&&t()};return document.addEventListener("mousedown",o),()=>{document.removeEventListener("mousedown",o)}},[e,t,n])}const Pv=g.div`
1835
1835
  position: relative;
1836
1836
  display: inline-flex;
1837
- `,Mv=g(dt)`
1837
+ `,kv=g(ft)`
1838
1838
  min-height: auto;
1839
1839
  padding: 0.25rem;
1840
1840
  border: none;
@@ -1857,19 +1857,19 @@
1857
1857
  ${({$isActive:e})=>e&&`
1858
1858
  opacity: 1;
1859
1859
  `}
1860
- `,Sn=({column:e,uniqueValues:t,selectedValues:n,onChange:o})=>{const[r,i]=m.useState(!1),s=m.useRef(null),a=n.length>0,l=()=>{i(u=>!u)},c=()=>{i(!1)},d=u=>{o(u)};return m.useEffect(()=>{const u=h=>{h.key==="Escape"&&r&&c()};return document.addEventListener("keydown",u),()=>document.removeEventListener("keydown",u)},[r]),$v(s,c,r),p.jsx(p.Fragment,{children:p.jsxs(Pv,{ref:s,onClick:u=>u.stopPropagation(),children:[p.jsx(Mv,{size:"sm",onClick:l,"aria-label":`Filter ${e.id}`,"aria-expanded":r,$isActive:a,leftIcon:p.jsx(H,{component:a?Ep:Dp,size:16,"aria-hidden":"true",color:"white"})}),r&&p.jsx(Mr,{options:t,selectedValues:n,onChange:d,onClose:c,searchPlaceholder:`Search ${e.id}...`})]})})};Sn.displayName="ColumnFilter";const Xl=e=>{const{columnFilters:t,setColumnFilters:n}=Ht(),o=Yl(t,e),r=m.useCallback(i=>{const s=[...t],a=s.findIndex(l=>l.id===e);i.length>0?a>=0?s[a]={id:e,value:i}:s.push({id:e,value:i}):a>=0&&s.splice(a,1),n(s)},[t,e,n]);return{selectedValues:o,handleChange:r}},Zl=g.div`
1860
+ `,Sn=({column:e,uniqueValues:t,selectedValues:n,onChange:o})=>{const[r,i]=m.useState(!1),s=m.useRef(null),a=n.length>0,l=()=>{i(u=>!u)},c=()=>{i(!1)},d=u=>{o(u)};return m.useEffect(()=>{const u=h=>{h.key==="Escape"&&r&&c()};return document.addEventListener("keydown",u),()=>document.removeEventListener("keydown",u)},[r]),$v(s,c,r),p.jsx(p.Fragment,{children:p.jsxs(Pv,{ref:s,onClick:u=>u.stopPropagation(),children:[p.jsx(kv,{size:"sm",onClick:l,"aria-label":`Filter ${e.id}`,"aria-expanded":r,$isActive:a,leftIcon:p.jsx(U,{component:a?Vp:Ep,size:16,"aria-hidden":"true",color:"white"})}),r&&p.jsx(Mr,{options:t,selectedValues:n,onChange:d,onClose:c,searchPlaceholder:`Search ${e.id}...`})]})})};Sn.displayName="ColumnFilter";const Wl=e=>{const{columnFilters:t,setColumnFilters:n}=mt(),o=Kl(t,e),r=m.useCallback(i=>{const s=[...t],a=s.findIndex(l=>l.id===e);i.length>0?a>=0?s[a]={id:e,value:i}:s.push({id:e,value:i}):a>=0&&s.splice(a,1),n(s)},[t,e,n]);return{selectedValues:o,handleChange:r}},ql=g.div`
1861
1861
  display: flex;
1862
1862
  align-items: center;
1863
1863
  gap: 0.25rem;
1864
1864
  width: 100%;
1865
- `,Jl=({header:e})=>{const{size:t,getUniqueValues:n}=Ht(),{selectedValues:o,handleChange:r}=Xl(e.column.id),i=e.column.columnDef.meta,s=e.column.getCanSort()&&i?.sortable!==!1,a=i?.filterable!==!1&&e.column.getCanFilter(),l=e.column.getIsSorted(),c=l||"none",d=e.column.id,u=a?n(d):[];return p.jsx(mv,{$size:i?.size||t,$active:!!l,colSpan:e.colSpan,$width:e.getSize(),children:s?p.jsxs("section",{className:"flex",onClick:e.column.getToggleSortingHandler(),children:[p.jsx(Kl,{onClick:e.column.getToggleSortingHandler(),type:"button","aria-label":`Sort by ${xn(e.column.columnDef.header,e.getContext())}`,"aria-sort":c==="asc"?"ascending":c==="desc"?"descending":"none",children:p.jsx(Ul,{$align:i?.align,children:p.jsxs(Zl,{children:[xn(e.column.columnDef.header,e.getContext()),p.jsx(pv,{$direction:c,children:c==="none"?p.jsx(H,{component:Pp,size:"tn"}):p.jsx(H,{component:Tp,size:"tn"})})]})})}),a&&p.jsx(Sn,{column:e.column,uniqueValues:u,selectedValues:o,onChange:r})]}):p.jsx(Ul,{$align:i?.align,children:p.jsxs(Zl,{children:[xn(e.column.columnDef.header,e.getContext()),a&&p.jsx(Sn,{column:e.column,uniqueValues:u,selectedValues:o,onChange:r})]})})})},Ql=({headerGroup:e})=>p.jsx(Gl,{children:e.headers.map(t=>p.jsx(Jl,{header:t},t.id))}),kr=({headerGroups:e,stickyHeader:t,className:n})=>p.jsx(fv,{$sticky:t,className:n,children:e.map(o=>p.jsx(Ql,{headerGroup:o},o.id))}),kv={sm:g.css`
1866
- ${ht.sm}
1865
+ `,Yl=({header:e})=>{const{size:t,getUniqueValues:n}=mt(),{selectedValues:o,handleChange:r}=Wl(e.column.id),i=e.column.columnDef.meta,s=e.column.getCanSort()&&i?.sortable!==!1,a=i?.filterable!==!1&&e.column.getCanFilter(),l=e.column.getIsSorted(),c=l||"none",d=e.column.id,u=a?n(d):[];return p.jsx(mv,{$size:i?.size||t,$active:!!l,colSpan:e.colSpan,$width:e.getSize(),children:s?p.jsxs("section",{className:"flex",onClick:e.column.getToggleSortingHandler(),children:[p.jsx(jl,{onClick:e.column.getToggleSortingHandler(),type:"button","aria-label":`Sort by ${xn(e.column.columnDef.header,e.getContext())}`,"aria-sort":c==="asc"?"ascending":c==="desc"?"descending":"none",children:p.jsx(Hl,{$align:i?.align,children:p.jsxs(ql,{children:[xn(e.column.columnDef.header,e.getContext()),p.jsx(pv,{$direction:c,children:c==="none"?p.jsx(U,{component:$p,size:"tn"}):p.jsx(U,{component:Cp,size:"tn"})})]})})}),a&&p.jsx(Sn,{column:e.column,uniqueValues:u,selectedValues:o,onChange:r})]}):p.jsx(Hl,{$align:i?.align,children:p.jsxs(ql,{children:[xn(e.column.columnDef.header,e.getContext()),a&&p.jsx(Sn,{column:e.column,uniqueValues:u,selectedValues:o,onChange:r})]})})})},Xl=({headerGroup:e})=>p.jsx(Ol,{children:e.headers.map(t=>p.jsx(Yl,{header:t},t.id))}),Zl=({headerGroups:e,stickyHeader:t,className:n})=>p.jsx(fv,{$sticky:t,className:n,children:e.map(o=>p.jsx(Xl,{headerGroup:o},o.id))}),Mv={sm:g.css`
1866
+ ${Qe.sm}
1867
1867
  ${E[14]}
1868
1868
  `,md:g.css`
1869
- ${ht.md}
1869
+ ${Qe.md}
1870
1870
  ${E[14]}
1871
1871
  `,lg:g.css`
1872
- ${ht.lg}
1872
+ ${Qe.lg}
1873
1873
  ${E[16]}
1874
1874
  `},Vv=g.td`
1875
1875
  min-width: 0;
@@ -1886,13 +1886,13 @@
1886
1886
 
1887
1887
  vertical-align: middle;
1888
1888
  color: var(--color-main-blue-primary);
1889
- ${({$size:e})=>kv[e]}
1889
+ ${({$size:e})=>Mv[e]}
1890
1890
  text-align: ${({$align:e})=>e||"left"};
1891
1891
  border-left: 1px solid var(--color-main-light-borders);
1892
1892
  border-top: 1px solid var(--color-main-light-borders);
1893
1893
  transition: background-color 0.3s ease-out;
1894
1894
  `,Ev=g.section`
1895
- ${Hl};
1895
+ ${zl};
1896
1896
  justify-content: ${({$align:e})=>e==="center"?"center":e==="right"?"flex-end":"flex-start"};
1897
1897
 
1898
1898
  width: 100%;
@@ -1904,7 +1904,38 @@
1904
1904
  text-overflow: ellipsis;
1905
1905
  white-space: nowrap;
1906
1906
  `}
1907
- `,ec=({cell:e,rowClassName:t})=>{const{size:n}=Ht(),o=e.column.columnDef.meta,r=e.getValue(),i=typeof r=="string"||typeof r=="number"?String(r):void 0,s=[o?.className||"",t||""].filter(Boolean).join(" ");return p.jsx(Vv,{$size:o?.size||n,$align:o?.align,$width:e.column.getSize(),title:o?.ellipsis&&i?i:void 0,className:s,children:p.jsx(Ev,{$align:o?.align,children:p.jsx(Dv,{$ellipsis:o?.ellipsis,children:xn(e.column.columnDef.cell,e.getContext())})})})};function Fv({row:e,className:t,cellClassName:n}){const{onRowClick:o}=Ht(),r=!!o;return p.jsx(Gl,{$clickable:r,onClick:()=>r&&o(e.original),role:r?"button":void 0,tabIndex:r?0:void 0,className:t,children:e.getVisibleCells().map(i=>p.jsx(ec,{cell:i,rowClassName:n},i.id))})}const tc=m.memo(Fv),Vr=({rows:e,className:t,rowClassName:n,cellClassName:o})=>p.jsxs("tbody",{className:t,children:[e.map(r=>{const i=typeof n=="function"?n(r):n,s=typeof o=="function"?o(r):o;return p.jsx(tc,{row:r,className:i,cellClassName:s},r.id)}),e.length===0&&p.jsx("tr",{children:p.jsx("td",{colSpan:100,className:"py-4 text-center text-[var(--color-main-grey)]",children:"No results found"})})]}),Av=g.section`
1907
+ `,Jl=({cell:e,rowClassName:t})=>{const{size:n}=mt(),o=e.column.columnDef.meta,r=e.getValue(),i=typeof r=="string"||typeof r=="number"?String(r):void 0,s=[o?.className||"",t||""].filter(Boolean).join(" ");return p.jsx(Vv,{$size:o?.size||n,$align:o?.align,$width:e.column.getSize(),title:o?.ellipsis&&i?i:void 0,className:s,children:p.jsx(Ev,{$align:o?.align,children:p.jsx(Dv,{$ellipsis:o?.ellipsis,children:xn(e.column.columnDef.cell,e.getContext())})})})};function Fv({row:e,className:t,cellClassName:n}){const{onRowClick:o}=mt(),r=!!o;return p.jsx(Ol,{$clickable:r,onClick:()=>r&&o(e.original),role:r?"button":void 0,tabIndex:r?0:void 0,className:t,children:e.getVisibleCells().map(i=>p.jsx(Jl,{cell:i,rowClassName:n},i.id))})}const Ql=m.memo(Fv),Av=g.keyframes`
1908
+ 0% {
1909
+ background-position: -1000px 0;
1910
+ }
1911
+ 100% {
1912
+ background-position: 1000px 0;
1913
+ }
1914
+ `,Iv=g.td`
1915
+ ${({$size:e="md"})=>Qe[e]}
1916
+ background: linear-gradient(
1917
+ 90deg,
1918
+ var(--color-light-200) 0%,
1919
+ var(--color-light-100) 50%,
1920
+ var(--color-light-200) 100%
1921
+ );
1922
+ background-size: 1000px 100%;
1923
+ animation: ${Av} 2s ease-in-out infinite;
1924
+ border-bottom: 1px solid var(--color-light-200);
1925
+
1926
+ &::before {
1927
+ content: '';
1928
+ display: block;
1929
+ height: 14px;
1930
+ width: ${e=>e.$width||"75%"};
1931
+ border-radius: var(--border-radius-sm, 4px);
1932
+ background-color: var(--color-light-300);
1933
+ }
1934
+ `,Lv=g.tr`
1935
+ &:hover {
1936
+ background-color: transparent;
1937
+ }
1938
+ `,Rv=e=>{const t=["60%","75%","85%","70%","80%"];return t[e%t.length]},_v=({columnCount:e,cellWidths:t,size:n="md"})=>p.jsx(Lv,{role:"row","aria-busy":"true",children:Array.from({length:e}).map((o,r)=>p.jsx(Iv,{$width:t?.[r]||Rv(r),$size:n},r))}),Cn=({rows:e,className:t,rowClassName:n,cellClassName:o,isLoading:r=!1,rowCount:i=5,columnCount:s=3})=>{const{size:a}=mt();return p.jsx("tbody",{className:t,"aria-busy":r,children:r?Array.from({length:i}).map((l,c)=>p.jsx(_v,{columnCount:s,size:a},`skeleton-${c}`)):p.jsxs(p.Fragment,{children:[e.map(l=>{const c=typeof n=="function"?n(l):n,d=typeof o=="function"?o(l):o;return p.jsx(Ql,{row:l,className:c,cellClassName:d},l.id)}),e.length===0&&p.jsx("tr",{children:p.jsx("td",{colSpan:100,className:"py-4 text-center text-[var(--color-main-grey)]",children:"No results found"})})]})})},Nv=g.section`
1908
1939
  display: flex;
1909
1940
  align-items: center;
1910
1941
  gap: 0.5rem;
@@ -1915,7 +1946,7 @@
1915
1946
  justify-content: center;
1916
1947
  gap: 0.25rem;
1917
1948
  }
1918
- `,nc=g.button`
1949
+ `,ec=g.button`
1919
1950
  ${E[14]}
1920
1951
  display: flex;
1921
1952
  align-items: center;
@@ -1935,8 +1966,8 @@
1935
1966
  opacity: ${({$disabled:e})=>e?.5:1};
1936
1967
 
1937
1968
  &:hover:not(:disabled) {
1938
- background-color: ${({$active:e})=>e?"var(--color-blue-400)":"var(--color-main-alternative-secondary)"};
1939
- border-color: ${({$active:e})=>e?"var(--color-blue-400)":"var(--color-main-blue-primary)"};
1969
+ background-color: ${({$active:e})=>e?"var(--color-blue-600)":"var(--color-main-alternative-secondary)"};
1970
+ border-color: ${({$active:e})=>e?"var(--color-blue-600)":"var(--color-main-blue-primary)"};
1940
1971
  }
1941
1972
 
1942
1973
  outline: 2px solid transparent;
@@ -1945,7 +1976,7 @@
1945
1976
  outline-color: var(--color-main-blue-primary);
1946
1977
  outline-offset: 2px;
1947
1978
  }
1948
- `,oc=g(nc)`
1979
+ `,tc=g(ec)`
1949
1980
  gap: 0.25rem;
1950
1981
  padding: 0 0.75rem;
1951
1982
  font-weight: 400;
@@ -1959,9 +1990,9 @@
1959
1990
  height: 1rem;
1960
1991
  }
1961
1992
  }
1962
- `,Iv=g(nc)`
1993
+ `,Bv=g(ec)`
1963
1994
  min-width: 2rem;
1964
- `,Lv=g.span`
1995
+ `,zv=g.span`
1965
1996
  ${E[14]}
1966
1997
  display: flex;
1967
1998
  align-items: center;
@@ -1970,7 +2001,7 @@
1970
2001
  height: 2rem;
1971
2002
  color: var(--color-main-blue-primary);
1972
2003
  user-select: none;
1973
- `,Rv=g.div`
2004
+ `,Ov=g.div`
1974
2005
  display: flex;
1975
2006
  align-items: center;
1976
2007
  gap: 0.5rem;
@@ -1989,7 +2020,7 @@
1989
2020
  justify-content: center;
1990
2021
  order: 10; /* Move to bottom on mobile */
1991
2022
  }
1992
- `,_v=g(gn)`
2023
+ `,Hv=g(gn)`
1993
2024
  button {
1994
2025
  ${E[14]}
1995
2026
  height: 2rem;
@@ -2005,7 +2036,7 @@
2005
2036
  div {
2006
2037
  right: 10%;
2007
2038
  }
2008
- `,Bv=({onPageChange:e,onPerPageChange:t,perPage:n=10,page:o=1,totalPages:r,totalRecords:i,rowsPerPageOptions:s})=>{const l=(()=>{const f=[];if(r<=7)for(let y=1;y<=r;y++)f.push(y);else{f.push(1),o>3&&f.push("...");const y=Math.max(2,o-1),b=Math.min(r-1,o+1);for(let w=y;w<=b;w++)f.push(w);o<r-2&&f.push("..."),f.push(r)}return f})(),c=[{value:10,label:"10"},{value:25,label:"25"},{value:50,label:"50"},{value:100,label:"100"}],d=i!==void 0&&i>0,u=d?(o-1)*n+1:0,h=d?Math.min(o*n,i):0;return p.jsxs(Av,{children:[d&&p.jsxs(_t,{size:14,children:["Showing ",u,"-",h," of ",i]}),p.jsxs(oc,{onClick:()=>e(o-1),$disabled:o===1,disabled:o===1,"aria-label":"Previous page",children:[p.jsx(_p,{size:24}),"Previous"]}),l.map((f,v)=>f==="..."?p.jsx(Lv,{children:"..."},`ellipsis-${v}`):p.jsx(Iv,{onClick:()=>e(f),$active:o===f,"aria-label":`Go to page ${f}`,"aria-current":o===f?"page":void 0,children:f},f)),p.jsxs(oc,{onClick:()=>e(o+1),$disabled:o===r,disabled:o===r,"aria-label":"Next page",children:["Next",p.jsx(Bp,{size:24})]}),p.jsxs(Rv,{children:[p.jsx(_v,{size:"sm",value:n,options:s||c,onOptionSelect:f=>t(Number(f.value))}),p.jsx(_t,{size:12,children:"Rows per page"})]})]})},rc=({sorting:e,defaultSorting:t=[],onSortingChange:n})=>{const[o,r]=m.useState(t),i=e!==void 0,s=i?e:o,a=m.useCallback(c=>{const d=typeof c=="function"?c(s):c;i||r(d),n?.(d)},[i,s,n]),l=m.useCallback(c=>{i||r(c),n?.(c)},[i,n]);return{sortingState:s,handleSortingChange:a,isControlled:i,setSorting:l}},ic=({columnFilters:e,defaultColumnFilters:t=[],onColumnFiltersChange:n})=>{const[o,r]=m.useState(t),i=e!==void 0,s=i?e:o,a=m.useCallback(c=>{const d=typeof c=="function"?c(s):c;i||r(d),n?.(d)},[i,s,n]),l=m.useCallback(c=>{i||r(c),n?.(c)},[i,n]);return{columnFiltersState:s,handleColumnFiltersChange:a,isControlled:i,setColumnFilters:l}},sc=m.createContext(void 0),Ht=()=>{const e=m.useContext(sc);if(!e)throw new Error("useTableContext debe usarse dentro de Table");return e},ac=({data:e,columns:t,size:n="md",variant:o="default",stickyHeader:r=!1,maxHeight:i,sorting:s,defaultSorting:a,onSortingChange:l,columnFilters:c,defaultColumnFilters:d,onColumnFiltersChange:u,onRowClick:h,classNames:f,enableSorting:v=!0,manualSorting:y=!1,enableFiltering:b=!0,manualFiltering:w=!1,isLoading:T=!1,getUniqueValues:C})=>{const{sortingState:M,handleSortingChange:x,setSorting:P}=rc({sorting:s,defaultSorting:a,onSortingChange:l}),{columnFiltersState:V,handleColumnFiltersChange:$,setColumnFilters:F}=ic({columnFilters:c,defaultColumnFilters:d,onColumnFiltersChange:u}),D=m.useMemo(()=>{if(C)return null;const K=new Map;return t.forEach(R=>{const L=R.id??("accessorKey"in R&&R.accessorKey?String(R.accessorKey):void 0);if(!L)return;const G="accessorFn"in R?R.accessorFn:void 0;K.set(L,Pr(e,L,G))}),K},[e,t,C]),_=m.useMemo(()=>C||(K=>D?.get(K)||[]),[D,C]),N=m.useMemo(()=>t.map(K=>{const L=K.meta?.filterable!==!1;return b&&L&&!K.filterFn?{...K,filterFn:"multiSelect"}:K}),[t,b]),O=lv({data:e,columns:N,state:{sorting:M,columnFilters:V},onSortingChange:x,onColumnFiltersChange:$,getCoreRowModel:Q0(),getSortedRowModel:y?void 0:rv(),getFilteredRowModel:w?void 0:ov(),enableSorting:v,enableSortingRemoval:!0,manualSorting:y,enableColumnFilters:b,manualFiltering:w,filterFns:{multiSelect:Wl},globalFilterFn:"includesString"}),j={size:n,variant:o,sorting:M,setSorting:P,columnFilters:V,setColumnFilters:F,getUniqueValues:_,onRowClick:h};return p.jsx(sc.Provider,{value:j,children:p.jsx(dv,{$maxHeight:i,$stickyHeader:r,className:f?.wrapper,children:T?p.jsx(Ha,{message:"Loading data..."}):e.length===0?p.jsxs(jl,{$variant:o,className:f?.table,children:[p.jsx(kr,{headerGroups:O.getHeaderGroups(),stickyHeader:r,className:f?.header}),p.jsx(Vr,{rows:[],className:f?.body,rowClassName:f?.row})]}):p.jsxs(jl,{$variant:o,className:f?.table,children:[p.jsx(kr,{headerGroups:O.getHeaderGroups(),stickyHeader:r,className:f?.header}),p.jsx(Vr,{rows:O.getRowModel().rows,className:f?.body,rowClassName:f?.row,cellClassName:f?.cell})]})})})};ac.displayName="Table";function lc(e){const t={};for(const n of e)t[n.id]=n.desc?"desc":"asc";return t}function Nv(e){return Object.entries(e).map(([t,n])=>({id:t,desc:n==="desc"}))}function cc(e){return e.length===0?"":JSON.stringify(lc(e))}function zv(e){const t=new URLSearchParams;return e.sorting&&e.sorting.length>0&&t.append("sorts",cc(e.sorting)),e.perPage&&t.append("perPage",e.perPage.toString()),e.genericSearch&&t.append("genericSearch",e.genericSearch),e.filters&&Object.keys(e.filters).length>0&&t.append("filters",JSON.stringify(e.filters)),t}const Ov=({data:e,columns:t,initialPage:n=1,initialPerPage:o=10,initialSorting:r=[],initialColumnFilters:i=[]})=>{const[s,a]=m.useState(n),[l,c]=m.useState(o),[d,u]=m.useState(r),[h,f]=m.useState(i),v=m.useMemo(()=>{const $=new Map;return t.forEach(F=>{const D=F.id??("accessorKey"in F&&F.accessorKey?String(F.accessorKey):void 0);if(!D)return;const _="accessorFn"in F?F.accessorFn:void 0;$.set(D,Pr(e,D,_))}),$},[e,t]),y=m.useMemo(()=>$=>v.get($)||[],[v]),b=m.useMemo(()=>h.length===0?e:e.filter($=>h.every(F=>{const D=F.value;if(!D||D.length===0)return!0;const _=$[F.id];return _==null?!1:D.includes(String(_))})),[e,h]),w=m.useMemo(()=>d.length===0?b:[...b].sort(($,F)=>{for(const D of d){const _=$[D.id],N=F[D.id];if(_==null&&N==null)continue;if(_==null)return D.desc?-1:1;if(N==null)return D.desc?1:-1;let O=0;if(typeof _=="string"&&typeof N=="string"?O=_.localeCompare(N):typeof _=="number"&&typeof N=="number"?O=_-N:O=String(_).localeCompare(String(N)),O!==0)return D.desc?-O:O}return 0}),[b,d]),T=m.useMemo(()=>{const $=(s-1)*l,F=$+l;return w.slice($,F)},[w,s,l]),C=e.length,M=w.length,x=Math.max(1,Math.ceil(M/l)),P=m.useCallback($=>{a(Math.min($,x))},[x]),V=m.useCallback($=>{c($),a(1)},[]);return m.useMemo(()=>{s>x&&a(1)},[s,x]),{paginatedData:T,processedData:w,page:s,perPage:l,totalPages:x,totalRecords:C,filteredRecords:M,setPage:P,setPerPage:V,sorting:d,setSorting:u,columnFilters:h,setColumnFilters:f,getUniqueValues:y}};function uc(e){const t={};return e.forEach(n=>{t[n.id]=n.value}),t}function dc(e){return JSON.stringify(uc(e))}function Hv(e,t=","){const n={};return e.forEach(o=>{const r=o.value;r&&r.length>0&&(n[`filter[${o.id}]`]=r.join(t))}),n}function jv(e){const t={};return e.forEach(n=>{const o=n.value;o&&o.length>0&&(t[`filter[${n.id}]`]=o)}),t}function Gv({filters:e,sorts:t,page:n,perPage:o}){const r={};if(n!==void 0&&(r.page=n),o!==void 0&&(r.per_page=o),t&&t.length>0){const i=t.map(a=>a.id).join(","),s=t.map(a=>a.desc?"desc":"asc").join(",");r.sort_by=i,r.sort_order=s}return e&&e.length>0&&(r.filters=dc(e)),r}function Uv(e,t=","){const n=typeof e=="string"?new URLSearchParams(e):e,o=[];return n.forEach((r,i)=>{const s=i.match(/^filter\[(.+)\]$/);if(s){const a=s[1],l=r.split(t).filter(Boolean);l.length>0&&o.push({id:a,value:l})}}),o}function Kv(e){try{const t=JSON.parse(e);return Object.entries(t).map(([n,o])=>({id:n,value:o}))}catch{return[]}}function Wv(...e){const t=new Map;return e.forEach(n=>{n.forEach(o=>{t.set(o.id,o.value)})}),Array.from(t.entries()).map(([n,o])=>({id:n,value:o}))}const qv=g.div`
2039
+ `,jv=({onPageChange:e,onPerPageChange:t,perPage:n=10,page:o=1,totalPages:r,totalRecords:i,rowsPerPageOptions:s})=>{const l=(()=>{const f=[];if(r<=7)for(let y=1;y<=r;y++)f.push(y);else{f.push(1),o>3&&f.push("...");const y=Math.max(2,o-1),b=Math.min(r-1,o+1);for(let w=y;w<=b;w++)f.push(w);o<r-2&&f.push("..."),f.push(r)}return f})(),c=[{value:10,label:"10"},{value:25,label:"25"},{value:50,label:"50"},{value:100,label:"100"}],d=i!==void 0&&i>0,u=d?(o-1)*n+1:0,h=d?Math.min(o*n,i):0;return p.jsxs(Nv,{children:[d&&p.jsxs(Nt,{size:14,children:["Showing ",u,"-",h," of ",i]}),p.jsxs(tc,{onClick:()=>e(o-1),$disabled:o===1,disabled:o===1,"aria-label":"Previous page",children:[p.jsx(Rp,{size:24}),"Previous"]}),l.map((f,v)=>f==="..."?p.jsx(zv,{children:"..."},`ellipsis-${v}`):p.jsx(Bv,{onClick:()=>e(f),$active:o===f,"aria-label":`Go to page ${f}`,"aria-current":o===f?"page":void 0,children:f},f)),p.jsxs(tc,{onClick:()=>e(o+1),$disabled:o===r,disabled:o===r,"aria-label":"Next page",children:["Next",p.jsx(_p,{size:24})]}),p.jsxs(Ov,{children:[p.jsx(Hv,{size:"sm",value:n,options:s||c,onOptionSelect:f=>t(Number(f.value))}),p.jsx(Nt,{size:12,children:"Rows per page"})]})]})},nc=({sorting:e,defaultSorting:t=[],onSortingChange:n})=>{const[o,r]=m.useState(t),i=e!==void 0,s=i?e:o,a=m.useCallback(c=>{const d=typeof c=="function"?c(s):c;i||r(d),n?.(d)},[i,s,n]),l=m.useCallback(c=>{i||r(c),n?.(c)},[i,n]);return{sortingState:s,handleSortingChange:a,isControlled:i,setSorting:l}},oc=({columnFilters:e,defaultColumnFilters:t=[],onColumnFiltersChange:n})=>{const[o,r]=m.useState(t),i=e!==void 0,s=i?e:o,a=m.useCallback(c=>{const d=typeof c=="function"?c(s):c;i||r(d),n?.(d)},[i,s,n]),l=m.useCallback(c=>{i||r(c),n?.(c)},[i,n]);return{columnFiltersState:s,handleColumnFiltersChange:a,isControlled:i,setColumnFilters:l}},rc=m.createContext(void 0),mt=()=>{const e=m.useContext(rc);if(!e)throw new Error("useTableContext debe usarse dentro de Table");return e},ic=({data:e,columns:t,size:n="md",variant:o="default",stickyHeader:r=!1,maxHeight:i,sorting:s,defaultSorting:a,onSortingChange:l,columnFilters:c,defaultColumnFilters:d,onColumnFiltersChange:u,onRowClick:h,classNames:f,enableSorting:v=!0,manualSorting:y=!1,enableFiltering:b=!0,manualFiltering:w=!1,isLoading:T=!1,getUniqueValues:C})=>{const{sortingState:k,handleSortingChange:x,setSorting:P}=nc({sorting:s,defaultSorting:a,onSortingChange:l}),{columnFiltersState:V,handleColumnFiltersChange:$,setColumnFilters:D}=oc({columnFilters:c,defaultColumnFilters:d,onColumnFiltersChange:u}),F=m.useMemo(()=>{if(C)return null;const G=new Map;return t.forEach(R=>{const L=R.id??("accessorKey"in R&&R.accessorKey?String(R.accessorKey):void 0);if(!L)return;const j="accessorFn"in R?R.accessorFn:void 0;G.set(L,kr(e,L,j))}),G},[e,t,C]),_=m.useMemo(()=>C||(G=>F?.get(G)||[]),[F,C]),B=m.useMemo(()=>t.map(G=>{const L=G.meta?.filterable!==!1;return b&&L&&!G.filterFn?{...G,filterFn:"multiSelect"}:G}),[t,b]),H=av({data:e,columns:B,state:{sorting:k,columnFilters:V},onSortingChange:x,onColumnFiltersChange:$,getCoreRowModel:J0(),getSortedRowModel:y?void 0:ov(),getFilteredRowModel:w?void 0:nv(),enableSorting:v,enableSortingRemoval:!0,manualSorting:y,enableColumnFilters:b,manualFiltering:w,filterFns:{multiSelect:Gl},globalFilterFn:"includesString"}),z={size:n,variant:o,sorting:k,setSorting:P,columnFilters:V,setColumnFilters:D,getUniqueValues:_,onRowClick:h};return p.jsx(rc.Provider,{value:z,children:p.jsx(uv,{$maxHeight:i,$stickyHeader:r,className:f?.wrapper,children:p.jsxs(dv,{$variant:o,className:f?.table,children:[p.jsx(Zl,{headerGroups:H.getHeaderGroups(),stickyHeader:r,className:f?.header}),T?p.jsx(Cn,{rows:[],isLoading:!0,rowCount:5,columnCount:t.length,className:f?.body}):e.length===0?p.jsx(Cn,{rows:[],className:f?.body,rowClassName:f?.row}):p.jsx(Cn,{rows:H.getRowModel().rows,className:f?.body,rowClassName:f?.row,cellClassName:f?.cell})]})})})};ic.displayName="Table";function sc(e){const t={};for(const n of e)t[n.id]=n.desc?"desc":"asc";return t}function Gv(e){return Object.entries(e).map(([t,n])=>({id:t,desc:n==="desc"}))}function ac(e){return e.length===0?"":JSON.stringify(sc(e))}function Uv(e){const t=new URLSearchParams;return e.sorting&&e.sorting.length>0&&t.append("sorts",ac(e.sorting)),e.perPage&&t.append("perPage",e.perPage.toString()),e.genericSearch&&t.append("genericSearch",e.genericSearch),e.filters&&Object.keys(e.filters).length>0&&t.append("filters",JSON.stringify(e.filters)),t}const Kv=({data:e,columns:t,initialPage:n=1,initialPerPage:o=10,initialSorting:r=[],initialColumnFilters:i=[]})=>{const[s,a]=m.useState(n),[l,c]=m.useState(o),[d,u]=m.useState(r),[h,f]=m.useState(i),v=m.useMemo(()=>{const $=new Map;return t.forEach(D=>{const F=D.id??("accessorKey"in D&&D.accessorKey?String(D.accessorKey):void 0);if(!F)return;const _="accessorFn"in D?D.accessorFn:void 0;$.set(F,kr(e,F,_))}),$},[e,t]),y=m.useMemo(()=>$=>v.get($)||[],[v]),b=m.useMemo(()=>h.length===0?e:e.filter($=>h.every(D=>{const F=D.value;if(!F||F.length===0)return!0;const _=$[D.id];return _==null?!1:F.includes(String(_))})),[e,h]),w=m.useMemo(()=>d.length===0?b:[...b].sort(($,D)=>{for(const F of d){const _=$[F.id],B=D[F.id];if(_==null&&B==null)continue;if(_==null)return F.desc?-1:1;if(B==null)return F.desc?1:-1;let H=0;if(typeof _=="string"&&typeof B=="string"?H=_.localeCompare(B):typeof _=="number"&&typeof B=="number"?H=_-B:H=String(_).localeCompare(String(B)),H!==0)return F.desc?-H:H}return 0}),[b,d]),T=m.useMemo(()=>{const $=(s-1)*l,D=$+l;return w.slice($,D)},[w,s,l]),C=e.length,k=w.length,x=Math.max(1,Math.ceil(k/l)),P=m.useCallback($=>{a(Math.min($,x))},[x]),V=m.useCallback($=>{c($),a(1)},[]);return m.useMemo(()=>{s>x&&a(1)},[s,x]),{paginatedData:T,processedData:w,page:s,perPage:l,totalPages:x,totalRecords:C,filteredRecords:k,setPage:P,setPerPage:V,sorting:d,setSorting:u,columnFilters:h,setColumnFilters:f,getUniqueValues:y}};function lc(e){const t={};return e.forEach(n=>{t[n.id]=n.value}),t}function cc(e){return JSON.stringify(lc(e))}function Wv(e,t=","){const n={};return e.forEach(o=>{const r=o.value;r&&r.length>0&&(n[`filter[${o.id}]`]=r.join(t))}),n}function qv(e){const t={};return e.forEach(n=>{const o=n.value;o&&o.length>0&&(t[`filter[${n.id}]`]=o)}),t}function Yv({filters:e,sorts:t,page:n,perPage:o}){const r={};if(n!==void 0&&(r.page=n),o!==void 0&&(r.per_page=o),t&&t.length>0){const i=t.map(a=>a.id).join(","),s=t.map(a=>a.desc?"desc":"asc").join(",");r.sort_by=i,r.sort_order=s}return e&&e.length>0&&(r.filters=cc(e)),r}function Xv(e,t=","){const n=typeof e=="string"?new URLSearchParams(e):e,o=[];return n.forEach((r,i)=>{const s=i.match(/^filter\[(.+)\]$/);if(s){const a=s[1],l=r.split(t).filter(Boolean);l.length>0&&o.push({id:a,value:l})}}),o}function Zv(e){try{const t=JSON.parse(e);return Object.entries(t).map(([n,o])=>({id:n,value:o}))}catch{return[]}}function Jv(...e){const t=new Map;return e.forEach(n=>{n.forEach(o=>{t.set(o.id,o.value)})}),Array.from(t.entries()).map(([n,o])=>({id:n,value:o}))}const Qv=g.div`
2009
2040
  position: relative;
2010
2041
  display: flex;
2011
2042
  align-items: center;
@@ -2023,7 +2054,7 @@
2023
2054
  outline: 2px solid var(--color-main-blue-primary);
2024
2055
  outline-offset: 2px;
2025
2056
  }
2026
- `,Yv=g.div`
2057
+ `,ey=g.div`
2027
2058
  width: 2rem;
2028
2059
  height: 2rem;
2029
2060
  border-radius: 50%;
@@ -2031,7 +2062,7 @@
2031
2062
  display: flex;
2032
2063
  align-items: center;
2033
2064
  justify-content: center;
2034
- `,Xv=g.div`
2065
+ `,ty=g.div`
2035
2066
  display: flex;
2036
2067
  flex-direction: column;
2037
2068
  align-items: flex-start;
@@ -2039,7 +2070,7 @@
2039
2070
  @media (max-width: 640px) {
2040
2071
  display: none;
2041
2072
  }
2042
- `,Zv=g(Fe.div)`
2073
+ `,ny=g(Fe.div)`
2043
2074
  display: flex;
2044
2075
  align-items: center;
2045
2076
  justify-content: center;
@@ -2048,7 +2079,7 @@
2048
2079
  @media (max-width: 640px) {
2049
2080
  display: none;
2050
2081
  }
2051
- `,Jv=g(Fe.div)`
2082
+ `,oy=g(Fe.div)`
2052
2083
  position: absolute;
2053
2084
  top: 100%;
2054
2085
  right: 0;
@@ -2060,7 +2091,7 @@
2060
2091
  box-shadow: var(--shadow-black-card);
2061
2092
  z-index: 100;
2062
2093
  overflow: hidden;
2063
- `,Qv=g.button`
2094
+ `,ry=g.button`
2064
2095
  width: 100%;
2065
2096
  display: flex;
2066
2097
  align-items: center;
@@ -2084,7 +2115,7 @@
2084
2115
  &.danger {
2085
2116
  color: var(--color-main-waringn-state);
2086
2117
  }
2087
- `,Er=({user:e,onProfileClick:t,onLogout:n,menuItems:o=[]})=>{const[r,i]=m.useState(!1),s=m.useRef(null);m.useEffect(()=>{if(!r)return;const d=u=>{s.current&&!s.current.contains(u.target)&&i(!1)};return document.addEventListener("mousedown",d),()=>document.removeEventListener("mousedown",d)},[r]),m.useEffect(()=>{if(!r)return;const d=u=>{u.key==="Escape"&&i(!1)};return document.addEventListener("keydown",d),()=>document.removeEventListener("keydown",d)},[r]);const a=d=>d.split(" ").map(u=>u[0]).join("").toUpperCase().slice(0,2),c=[...[{id:"profile",label:"Profile",icon:Rp,onClick:()=>{i(!1),t?.()},variant:"default"},{id:"logout",label:"Logout",icon:Fp,onClick:()=>{i(!1),n?.()},variant:"danger"}],...o];return p.jsxs("div",{ref:s,children:[p.jsxs(qv,{onClick:()=>i(!r),role:"button",tabIndex:0,onKeyDown:d=>{(d.key==="Enter"||d.key===" ")&&(d.preventDefault(),i(!r))},children:[p.jsx(Yv,{children:e.avatarUrl?p.jsx("img",{src:e.avatarUrl,alt:e.name}):p.jsx(Ve,{size:14,color:"var(--color-main-white)",className:"!font-semibold",children:a(e.name)})}),p.jsxs(Xv,{children:[p.jsx(Ve,{size:14,className:"!font-semibold",children:e.name}),p.jsx(Ve,{size:12,children:e.role})]}),p.jsx(Zv,{animate:{rotate:r?-180:0},transition:{duration:.3},children:p.jsx(H,{component:qa,size:"sm",color:"var(--color-main-blue-primary)"})})]}),p.jsx(At,{children:r&&p.jsx(Jv,{initial:{opacity:0,y:-10,scale:.95},animate:{opacity:1,y:0,scale:1},exit:{opacity:0,y:-10,scale:.95},transition:{duration:.15},children:c.map(d=>p.jsx(m.Fragment,{children:p.jsxs(Qv,{onClick:d.onClick,className:d.variant==="danger"?"danger":"",children:[p.jsx(H,{component:d.icon,size:"sm",color:d.variant==="danger"?"var(--color-main-warning-state)":"var(--color-main-blue-primary)"}),p.jsx(Ve,{size:14,color:`${d.variant==="danger"&&"var(--color-main-warning-state)"}`,children:d.label})]})},d.id))})})]})};Er.displayName="UserProfile";const fc=({hasNotifications:e=!1,notificationCount:t})=>{const n=(t??0)>0||e,o=t&&t>0?t:void 0,r=o?`${o} notification${o===1?"":"s"}`:n?"New notifications":"No notifications",i=`Notifications: ${r}`;return{effectiveHasNotifications:n,displayCount:o,badgeLabel:r,bellAriaLabel:i}},ey=g.button`
2118
+ `,Vr=({user:e,onProfileClick:t,onLogout:n,menuItems:o=[]})=>{const[r,i]=m.useState(!1),s=m.useRef(null);m.useEffect(()=>{if(!r)return;const d=u=>{s.current&&!s.current.contains(u.target)&&i(!1)};return document.addEventListener("mousedown",d),()=>document.removeEventListener("mousedown",d)},[r]),m.useEffect(()=>{if(!r)return;const d=u=>{u.key==="Escape"&&i(!1)};return document.addEventListener("keydown",d),()=>document.removeEventListener("keydown",d)},[r]);const a=d=>d.split(" ").map(u=>u[0]).join("").toUpperCase().slice(0,2),c=[...[{id:"profile",label:"Profile",icon:Lp,onClick:()=>{i(!1),t?.()},variant:"default"},{id:"logout",label:"Logout",icon:Dp,onClick:()=>{i(!1),n?.()},variant:"danger"}],...o];return p.jsxs("div",{ref:s,children:[p.jsxs(Qv,{onClick:()=>i(!r),role:"button",tabIndex:0,onKeyDown:d=>{(d.key==="Enter"||d.key===" ")&&(d.preventDefault(),i(!r))},children:[p.jsx(ey,{children:e.avatarUrl?p.jsx("img",{src:e.avatarUrl,alt:e.name}):p.jsx(Ve,{size:14,color:"var(--color-main-white)",className:"!font-semibold",children:a(e.name)})}),p.jsxs(ty,{children:[p.jsx(Ve,{size:14,className:"!font-semibold",children:e.name}),p.jsx(Ve,{size:12,children:e.role})]}),p.jsx(ny,{animate:{rotate:r?-180:0},transition:{duration:.3},children:p.jsx(U,{component:Ka,size:"sm",color:"var(--color-main-blue-primary)"})})]}),p.jsx(It,{children:r&&p.jsx(oy,{initial:{opacity:0,y:-10,scale:.95},animate:{opacity:1,y:0,scale:1},exit:{opacity:0,y:-10,scale:.95},transition:{duration:.15},children:c.map(d=>p.jsx(m.Fragment,{children:p.jsxs(ry,{onClick:d.onClick,className:d.variant==="danger"?"danger":"",children:[p.jsx(U,{component:d.icon,size:"sm",color:d.variant==="danger"?"var(--color-main-warning-state)":"var(--color-main-blue-primary)"}),p.jsx(Ve,{size:14,color:`${d.variant==="danger"&&"var(--color-main-warning-state)"}`,children:d.label})]})},d.id))})})]})};Vr.displayName="UserProfile";const uc=({hasNotifications:e=!1,notificationCount:t})=>{const n=(t??0)>0||e,o=t&&t>0?t:void 0,r=o?`${o} notification${o===1?"":"s"}`:n?"New notifications":"No notifications",i=`Notifications: ${r}`;return{effectiveHasNotifications:n,displayCount:o,badgeLabel:r,bellAriaLabel:i}},iy=g.button`
2088
2119
  position: relative;
2089
2120
  background: transparent;
2090
2121
  border: none;
@@ -2108,7 +2139,7 @@
2108
2139
  &:active {
2109
2140
  transform: scale(0.92);
2110
2141
  }
2111
- `,ty=g.span`
2142
+ `,sy=g.span`
2112
2143
  position: absolute;
2113
2144
  top: 0.35rem;
2114
2145
  right: 0.35rem;
@@ -2124,7 +2155,7 @@
2124
2155
  min-width: ${({$withCount:e})=>e?"1rem":"0.55rem"};
2125
2156
  height: ${({$withCount:e})=>e?"1rem":"0.55rem"};
2126
2157
  padding: ${({$withCount:e})=>e?"0 0.25rem":"0"};
2127
- `,Dr=({hasNotifications:e=!1,notificationCount:t,onNotificationClick:n})=>{const{effectiveHasNotifications:o,displayCount:r,bellAriaLabel:i}=fc({hasNotifications:e,notificationCount:t});return p.jsxs(ey,{onClick:n,"aria-label":i,title:i,"data-has":o||void 0,children:[p.jsx(H,{component:o?Ap:Ip,size:"md",color:"var(--color-main-blue-primary)"}),o&&p.jsx(ty,{$withCount:!!r,"aria-hidden":!!r,children:r&&(r>99?"99+":r)})]})};Dr.displayName="NotificationButton";const ny=g.header`
2158
+ `,Er=({hasNotifications:e=!1,notificationCount:t,onNotificationClick:n})=>{const{effectiveHasNotifications:o,displayCount:r,bellAriaLabel:i}=uc({hasNotifications:e,notificationCount:t});return p.jsxs(iy,{onClick:n,"aria-label":i,title:i,"data-has":o||void 0,children:[p.jsx(U,{component:o?Fp:Ap,size:"md",color:"var(--color-main-blue-primary)"}),o&&p.jsx(sy,{$withCount:!!r,"aria-hidden":!!r,children:r&&(r>99?"99+":r)})]})};Er.displayName="NotificationButton";const ay=g.header`
2128
2159
  position: fixed;
2129
2160
  top: 0;
2130
2161
  left: 0;
@@ -2140,15 +2171,15 @@
2140
2171
  padding: 0 1rem;
2141
2172
  transition: padding-left 0.3s ease-out;
2142
2173
  padding-left: 5rem;
2143
- `,oy=g.div`
2174
+ `,ly=g.div`
2144
2175
  display: flex;
2145
2176
  align-items: center;
2146
2177
  gap: 1rem;
2147
- `,ry=g.div`
2178
+ `,cy=g.div`
2148
2179
  display: flex;
2149
2180
  align-items: center;
2150
2181
  gap: 1rem;
2151
- `,Fr=({user:e,hasNotifications:t=!1,notificationCount:n,onNotificationClick:o,onUserProfileClick:r,onLogout:i,userMenuItems:s,children:a})=>p.jsxs(ny,{children:[p.jsx(oy,{children:a}),p.jsxs(ry,{children:[p.jsx(Dr,{hasNotifications:t,notificationCount:n,onNotificationClick:o}),e&&p.jsx(Er,{user:e,onProfileClick:r,onLogout:i,menuItems:s})]})]});Fr.displayName="Header";const iy=g.main`
2182
+ `,Dr=({user:e,hasNotifications:t=!1,notificationCount:n,onNotificationClick:o,onUserProfileClick:r,onLogout:i,userMenuItems:s,children:a})=>p.jsxs(ay,{children:[p.jsx(ly,{children:a}),p.jsxs(cy,{children:[p.jsx(Er,{hasNotifications:t,notificationCount:n,onNotificationClick:o}),e&&p.jsx(Vr,{user:e,onProfileClick:r,onLogout:i,menuItems:s})]})]});Dr.displayName="Header";const uy=g.main`
2152
2183
  flex: 1;
2153
2184
  margin-top: 4rem;
2154
2185
  /* Mobile-first: no lateral offset so content occupies full width */
@@ -2164,25 +2195,25 @@
2164
2195
  @media (min-width: 1200px) {
2165
2196
  margin-left: 5rem;
2166
2197
  }
2167
- `,Ar=({children:e,className:t})=>p.jsx(iy,{className:t,children:e});Ar.displayName="LayoutMainContent";const sy=g.div`
2198
+ `,Fr=({children:e,className:t})=>p.jsx(uy,{className:t,children:e});Fr.displayName="LayoutMainContent";const dy=g.div`
2168
2199
  display: flex;
2169
2200
  flex-direction: column;
2170
2201
  height: 100vh;
2171
2202
  overflow: hidden;
2172
- `,ay=({children:e,navigationConfig:t,userRoles:n=[],activePath:o,user:r,hasNotifications:i=!1,notificationCount:s,onNotificationClick:a,onUserProfileClick:l,onNavigate:c,onLogout:d,userMenuItems:u=[],contentClassName:h,logoImgCollapsed:f,logoImgExpanded:v})=>p.jsxs(sy,{children:[p.jsx(lr,{navigationConfig:t,userRoles:n,activePath:o,logoImgCollapsed:f,logoImgExpanded:v,onNavigate:c}),p.jsx(Fr,{user:r,hasNotifications:i,notificationCount:s,onNotificationClick:a,onUserProfileClick:l,onLogout:d,userMenuItems:u}),p.jsx(Ar,{className:h,children:e})]}),ly=e=>p.jsx(vl,{children:p.jsx(ay,{...e})});function cy(e,t,n){let o=`${e}=${encodeURIComponent(t)}; path=/; SameSite=Strict; Secure`;if(n){const r=new Date(Date.now()+n*864e5).toUTCString();o+=`; expires=${r}`}document.cookie=o}function uy(e){return document.cookie.split("; ").reduce((t,n)=>{const o=n.split("=");return o[0]===e?decodeURIComponent(o[1]):t},"")}function dy(e){document.cookie=`${e}=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/`}const jt={sm:{circle:"2rem",fontSize:E[14],line:"2px"},md:{circle:"2.5rem",fontSize:E[18],line:"2px"},lg:{circle:"3.25rem",fontSize:E[20],line:"3px"}},fy=g.div`
2203
+ `,fy=({children:e,navigationConfig:t,userRoles:n=[],activePath:o,user:r,hasNotifications:i=!1,notificationCount:s,onNotificationClick:a,onUserProfileClick:l,onNavigate:c,onLogout:d,userMenuItems:u=[],contentClassName:h,logoImgCollapsed:f,logoImgExpanded:v})=>p.jsxs(dy,{children:[p.jsx(cr,{navigationConfig:t,userRoles:n,activePath:o,logoImgCollapsed:f,logoImgExpanded:v,onNavigate:c}),p.jsx(Dr,{user:r,hasNotifications:i,notificationCount:s,onNotificationClick:a,onUserProfileClick:l,onLogout:d,userMenuItems:u}),p.jsx(Fr,{className:h,children:e})]}),hy=e=>p.jsx(pl,{children:p.jsx(fy,{...e})});function my(e,t,n){let o=`${e}=${encodeURIComponent(t)}; path=/; SameSite=Strict; Secure`;if(n){const r=new Date(Date.now()+n*864e5).toUTCString();o+=`; expires=${r}`}document.cookie=o}function py(e){return document.cookie.split("; ").reduce((t,n)=>{const o=n.split("=");return o[0]===e?decodeURIComponent(o[1]):t},"")}function gy(e){document.cookie=`${e}=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/`}const jt={sm:{circle:"2rem",fontSize:E[14],line:"2px"},md:{circle:"2.5rem",fontSize:E[18],line:"2px"},lg:{circle:"3.25rem",fontSize:E[20],line:"3px"}},vy=g.div`
2173
2204
  display: flex;
2174
2205
  width: 100%;
2175
- `,hy=g.div`
2206
+ `,yy=g.div`
2176
2207
  display: flex;
2177
2208
  flex-direction: ${({$orientation:e})=>e==="vertical"?"column":"row"};
2178
2209
  align-items: center;
2179
2210
  width: 100%;
2180
- `,my=g.div`
2211
+ `,wy=g.div`
2181
2212
  display: flex;
2182
2213
  align-items: center;
2183
2214
  justify-content: center;
2184
2215
  position: relative;
2185
- `,hc=g.div`
2216
+ `,dc=g.div`
2186
2217
  display: flex;
2187
2218
  align-items: center;
2188
2219
  justify-content: center;
@@ -2228,7 +2259,7 @@
2228
2259
  box-shadow: var(--shadow-hover-black-button);
2229
2260
  }
2230
2261
  `}
2231
- `,py=g.div`
2262
+ `,by=g.div`
2232
2263
  background-color: ${({$isCompleted:e})=>e?"var(--color-main-blue-primary)":"var(--color-dark-300)"};
2233
2264
  transition: background-color 0.3s ease;
2234
2265
 
@@ -2240,7 +2271,7 @@
2240
2271
  flex: 1;
2241
2272
  min-width: 2rem;
2242
2273
  `}
2243
- `,gy=g.span`
2274
+ `,xy=g.span`
2244
2275
  position: absolute;
2245
2276
  ${E[14]}
2246
2277
  font-weight: 500;
@@ -2270,7 +2301,7 @@
2270
2301
  border-left-color: var(--color-main-blue-primary);
2271
2302
  }
2272
2303
 
2273
- ${hc}:hover & {
2304
+ ${dc}:hover & {
2274
2305
  opacity: 1;
2275
2306
  }
2276
- `,vy=({steps:e,currentStep:t,orientation:n="horizontal",size:o="md",onStepClick:r,className:i})=>{const s=a=>{r?.(a)};return p.jsx(fy,{$orientation:n,className:i,children:p.jsx(hy,{$orientation:n,children:e.map((a,l)=>{const c=l===t,d=l<t,u=r!=null;return p.jsxs(p.Fragment,{children:[p.jsx(my,{$orientation:n,children:p.jsxs(hc,{$isActive:c,$isCompleted:d,$size:o,$isClickable:u,onClick:()=>u&&s(l),role:u?"button":void 0,tabIndex:u?0:void 0,"aria-current":c?"step":void 0,"aria-label":a.label,onKeyDown:h=>{u&&(h.key==="Enter"||h.key===" ")&&(h.preventDefault(),s(l))},children:[a.content??l+1,a.label&&n==="vertical"&&p.jsx(gy,{children:a.label})]})}),l<e.length-1&&p.jsx(py,{$isCompleted:d,$orientation:n,$size:o})]},a.id)})})})};S.ALLOWED_INPUT_TYPES=Ua,S.Aside=xl,S.Badge=Cm,S.BaseInput=Yo,S.BrandLogo=Cl,S.Button=dt,S.Card=ap,S.CardBody=dp,S.CardFooter=hp,S.CardHeader=cp,S.Checkbox=Nt,S.CheckboxInput=Jo,S.CheckboxLabel=rl,S.CloseOpenButton=$l,S.ColumnFilter=Sn,S.ColumnFilterMenu=Mr,S.Dialog=fl,S.DialogBody=ml,S.DialogFooter=pl,S.DialogHeader=hl,S.Divider=$m,S.ErrorMessage=qo,S.FileList=ol,S.FileUpload=Sg,S.FilterOption=$r,S.FormField=Wg,S.FullScreenSpinner=mm,S.Header=Fr,S.HeadingBold=Nr,S.HeadingRegular=$c,S.Icon=H,S.IconWrapperStyles=pn,S.InfoLabel=_t,S.Label=hn,S.Layout=ly,S.LayoutMainContent=Ar,S.Link=El,S.LinkDisabledStyles=kl,S.LinkSizeStyles=Vl,S.LinkVariantStyles=Ml,S.MobileOpenBtn=Pl,S.Nav=Tl,S.NotificationButton=Dr,S.Overlay=bl,S.PasswordInput=Ja,S.PinInput=Qo,S.PinInputGroup=er,S.RadioInput=or,S.RadioInputDot=tr,S.RadioInputLabel=nr,S.SearchInput=Zo,S.SectionSpinner=Ha,S.SelectInput=gn,S.Sidebar=lr,S.SidebarContext=ir,S.SidebarHeader=Sl,S.SidebarProvider=vl,S.Spinner=dn,S.Stepper=vy,S.Table=ac,S.TableBody=Vr,S.TableCell=ec,S.TableHeader=kr,S.TableHeaderCell=Jl,S.TableHeaderRow=Ql,S.TablePagination=Bv,S.TableRow=tc,S.TermsAndConditions=r0,S.Text=Ve,S.TextAreaInput=Xo,S.ToastProvider=tp,S.Tooltip=gl,S.UserProfile=Er,S.baseFieldStyles=Ze,S.baseInputStyles=mn,S.bodyTextStyles=E,S.columnFiltersToArrayQueryParams=jv,S.columnFiltersToJsonString=dc,S.columnFiltersToQueryParams=Hv,S.columnFiltersToRecord=uc,S.createBackendParams=zv,S.createBackendParamsWithFilters=Gv,S.createColumnHelper=C0,S.createFieldConfig=bp,S.createInputRefs=ll,S.deleteCookie=dy,S.disabledStyles=Oe,S.errorStyles=Je,S.flushedStyles=Wa,S.getActiveFilterCount=wv,S.getActiveFilterValues=Yl,S.getColumnValueCounts=vv,S.getCookie=uy,S.getPropsForInputType=xp,S.getUniqueColumnValues=Pr,S.handleDigitChange=il,S.handleKeyDown=sl,S.handlePaste=al,S.hasActiveFilters=yv,S.hasPermission=ar,S.headingBoldStyles=kn,S.headingRegularStyles=Br,S.isAllowedInputType=Ka,S.mergeFilters=Wv,S.multiSelectFilter=Wl,S.normalizeFieldTypes=ze,S.normalizeSelectOptions=wp,S.overlayAnimation=rr,S.parseJsonToFilters=Kv,S.parseQueryParamsToFilters=Uv,S.searchInArray=ql,S.setCookie=cy,S.sizeStyles=Bt,S.slideAnimation=qg,S.smartAnimation=ul,S.sortRecordToSortingState=Nv,S.sortingStateToJsonString=cc,S.sortingStateToRecord=lc,S.submenuAnimationTopDown=dl,S.toast=jm,S.useColumnFilter=Xl,S.useNotifications=fc,S.useSidebar=sr,S.useTableContext=Ht,S.useTableData=Ov,S.useTableFiltering=ic,S.useTableSorting=rc,S.validateCode=Ig,Object.defineProperty(S,Symbol.toStringTag,{value:"Module"})}));
2307
+ `,Sy=({steps:e,currentStep:t,orientation:n="horizontal",size:o="md",onStepClick:r,className:i})=>{const s=a=>{r?.(a)};return p.jsx(vy,{$orientation:n,className:i,children:p.jsx(yy,{$orientation:n,children:e.map((a,l)=>{const c=l===t,d=l<t,u=r!=null;return p.jsxs(p.Fragment,{children:[p.jsx(wy,{$orientation:n,children:p.jsxs(dc,{$isActive:c,$isCompleted:d,$size:o,$isClickable:u,onClick:()=>u&&s(l),role:u?"button":void 0,tabIndex:u?0:void 0,"aria-current":c?"step":void 0,"aria-label":a.label,onKeyDown:h=>{u&&(h.key==="Enter"||h.key===" ")&&(h.preventDefault(),s(l))},children:[a.content??l+1,a.label&&n==="vertical"&&p.jsx(xy,{children:a.label})]})}),l<e.length-1&&p.jsx(by,{$isCompleted:d,$orientation:n,$size:o})]},a.id)})})})};S.ALLOWED_INPUT_TYPES=ja,S.Aside=wl,S.Badge=Sm,S.BaseInput=Xo,S.BrandLogo=xl,S.Button=ft,S.Card=sp,S.CardBody=up,S.CardFooter=fp,S.CardHeader=lp,S.Checkbox=zt,S.CheckboxInput=Qo,S.CheckboxLabel=nl,S.CloseOpenButton=Cl,S.ColumnFilter=Sn,S.ColumnFilterMenu=Mr,S.Dialog=ul,S.DialogBody=fl,S.DialogFooter=hl,S.DialogHeader=dl,S.Divider=Tm,S.ErrorMessage=Yo,S.FileList=tl,S.FileUpload=xg,S.FilterOption=Pr,S.FormField=Kg,S.FullScreenSpinner=fm,S.Header=Dr,S.HeadingBold=Nr,S.HeadingRegular=Cc,S.Icon=U,S.IconWrapperStyles=pn,S.InfoLabel=Nt,S.Label=hn,S.Layout=hy,S.LayoutMainContent=Fr,S.Link=Ml,S.LinkDisabledStyles=Pl,S.LinkSizeStyles=kl,S.LinkVariantStyles=$l,S.MobileOpenBtn=Tl,S.Nav=Sl,S.NotificationButton=Er,S.Overlay=yl,S.PasswordInput=Xa,S.PinInput=er,S.PinInputGroup=tr,S.RadioInput=rr,S.RadioInputDot=nr,S.RadioInputLabel=or,S.SearchInput=Jo,S.SectionSpinner=mm,S.SelectInput=gn,S.Sidebar=cr,S.SidebarContext=sr,S.SidebarHeader=bl,S.SidebarProvider=pl,S.Spinner=dn,S.Stepper=Sy,S.Table=ic,S.TableBody=Cn,S.TableCell=Jl,S.TableHeader=Zl,S.TableHeaderCell=Yl,S.TableHeaderRow=Xl,S.TablePagination=jv,S.TableRow=Ql,S.TermsAndConditions=o0,S.Text=Ve,S.TextAreaInput=Zo,S.ToastProvider=ep,S.Tooltip=ml,S.UserProfile=Vr,S.baseFieldStyles=Ze,S.baseInputStyles=mn,S.bodyTextStyles=E,S.columnFiltersToArrayQueryParams=qv,S.columnFiltersToJsonString=cc,S.columnFiltersToQueryParams=Wv,S.columnFiltersToRecord=lc,S.createBackendParams=Uv,S.createBackendParamsWithFilters=Yv,S.createColumnHelper=S0,S.createFieldConfig=wp,S.createInputRefs=sl,S.deleteCookie=gy,S.disabledStyles=Oe,S.errorStyles=Je,S.flushedStyles=Ua,S.getActiveFilterCount=wv,S.getActiveFilterValues=Kl,S.getColumnValueCounts=vv,S.getCookie=py,S.getPropsForInputType=bp,S.getUniqueColumnValues=kr,S.handleDigitChange=ol,S.handleKeyDown=rl,S.handlePaste=il,S.hasActiveFilters=yv,S.hasPermission=lr,S.headingBoldStyles=Vn,S.headingRegularStyles=_r,S.isAllowedInputType=Ga,S.mergeFilters=Jv,S.multiSelectFilter=Gl,S.normalizeFieldTypes=ze,S.normalizeSelectOptions=yp,S.overlayAnimation=ir,S.parseJsonToFilters=Zv,S.parseQueryParamsToFilters=Xv,S.searchInArray=Ul,S.setCookie=my,S.sizeStyles=Bt,S.slideAnimation=Wg,S.smartAnimation=ll,S.sortRecordToSortingState=Gv,S.sortingStateToJsonString=ac,S.sortingStateToRecord=sc,S.submenuAnimationTopDown=cl,S.toast=Hm,S.useColumnFilter=Wl,S.useNotifications=uc,S.useSidebar=ar,S.useTableContext=mt,S.useTableData=Kv,S.useTableFiltering=oc,S.useTableSorting=nc,S.validateCode=Ag,Object.defineProperty(S,Symbol.toStringTag,{value:"Module"})}));