finform-react-builder 1.8.13 → 1.8.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1,23 +1,23 @@
1
- "use strict";var vc=Object.defineProperty;var Ha=e=>{throw TypeError(e)};var bc=(e,t,r)=>t in e?vc(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var rn=(e,t,r)=>bc(e,typeof t!="symbol"?t+"":t,r),bi=(e,t,r)=>t.has(e)||Ha("Cannot "+r);var C=(e,t,r)=>(bi(e,t,"read from private field"),r?r.call(e):t.get(e)),me=(e,t,r)=>t.has(e)?Ha("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,r),re=(e,t,r,n)=>(bi(e,t,"write to private field"),n?n.call(e,r):t.set(e,r),r),xe=(e,t,r)=>(bi(e,t,"access private method"),r);var jn=(e,t,r,n)=>({set _(i){re(e,t,i,r)},get _(){return C(e,t,n)}});Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const m=require("react/jsx-runtime"),$=require("react"),E=require("@mui/material"),wc=require("@emotion/styled"),Sr=require("@emotion/react");function Sc(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const r in e)if(r!=="default"){const n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:()=>e[r]})}}return t.default=e,Object.freeze(t)}const ne=Sc($);var Sn=e=>e.type==="checkbox",lr=e=>e instanceof Date,He=e=>e==null;const Is=e=>typeof e=="object";var Me=e=>!He(e)&&!Array.isArray(e)&&Is(e)&&!lr(e),Ms=e=>Me(e)&&e.target?Sn(e.target)?e.target.checked:e.target.value:e,Cc=e=>e.substring(0,e.search(/\.\d+(\.|$)/))||e,zs=(e,t)=>e.has(Cc(t)),Ec=e=>{const t=e.constructor&&e.constructor.prototype;return Me(t)&&t.hasOwnProperty("isPrototypeOf")},ya=typeof window<"u"&&typeof window.HTMLElement<"u"&&typeof document<"u";function Ne(e){let t;const r=Array.isArray(e),n=typeof FileList<"u"?e instanceof FileList:!1;if(e instanceof Date)t=new Date(e);else if(e instanceof Set)t=new Set(e);else if(!(ya&&(e instanceof Blob||n))&&(r||Me(e)))if(t=r?[]:{},!r&&!Ec(e))t=e;else for(const i in e)e.hasOwnProperty(i)&&(t[i]=Ne(e[i]));else return e;return t}var ci=e=>/^\w*$/.test(e),Ie=e=>e===void 0,xa=e=>Array.isArray(e)?e.filter(Boolean):[],va=e=>xa(e.replace(/["|']|\]/g,"").split(/\.|\[/)),Z=(e,t,r)=>{if(!t||!Me(e))return r;const n=(ci(t)?[t]:va(t)).reduce((i,a)=>He(i)?i:i[a],e);return Ie(n)||n===e?Ie(e[t])?r:e[t]:n},rt=e=>typeof e=="boolean",Se=(e,t,r)=>{let n=-1;const i=ci(t)?[t]:va(t),a=i.length,o=a-1;for(;++n<a;){const s=i[n];let l=r;if(n!==o){const p=e[s];l=Me(p)||Array.isArray(p)?p:isNaN(+i[n+1])?{}:[]}if(s==="__proto__"||s==="constructor"||s==="prototype")return;e[s]=l,e=e[s]}};const Wn={BLUR:"blur",FOCUS_OUT:"focusout",CHANGE:"change"},gt={onBlur:"onBlur",onChange:"onChange",onSubmit:"onSubmit",onTouched:"onTouched",all:"all"},_t={max:"max",min:"min",maxLength:"maxLength",minLength:"minLength",pattern:"pattern",required:"required",validate:"validate"},Vs=$.createContext(null);Vs.displayName="HookFormContext";const ba=()=>$.useContext(Vs);var Bs=(e,t,r,n=!0)=>{const i={defaultValues:t._defaultValues};for(const a in e)Object.defineProperty(i,a,{get:()=>{const o=a;return t._proxyFormState[o]!==gt.all&&(t._proxyFormState[o]=!n||gt.all),r&&(r[o]=!0),e[o]}});return i};const wa=typeof window<"u"?ne.useLayoutEffect:ne.useEffect;function kc(e){const t=ba(),{control:r=t.control,disabled:n,name:i,exact:a}=e||{},[o,s]=$.useState(r._formState),l=$.useRef({isDirty:!1,isLoading:!1,dirtyFields:!1,touchedFields:!1,validatingFields:!1,isValidating:!1,isValid:!1,errors:!1});return wa(()=>r._subscribe({name:i,formState:l.current,exact:a,callback:p=>{!n&&s({...r._formState,...p})}}),[i,n,a]),$.useEffect(()=>{l.current.isValid&&r._setValid(!0)},[r]),$.useMemo(()=>Bs(o,r,l.current,!1),[o,r])}var jt=e=>typeof e=="string",Ns=(e,t,r,n,i)=>jt(e)?(n&&t.watch.add(e),Z(r,e,i)):Array.isArray(e)?e.map(a=>(n&&t.watch.add(a),Z(r,a))):(n&&(t.watchAll=!0),r);function Tc(e){const t=ba(),{control:r=t.control,name:n,defaultValue:i,disabled:a,exact:o}=e||{},s=$.useRef(i),[l,p]=$.useState(r._getWatch(n,s.current));return wa(()=>r._subscribe({name:n,formState:{values:!0},exact:o,callback:u=>!a&&p(Ns(n,r._names,u.values||r._formValues,!1,s.current))}),[n,r,a,o]),$.useEffect(()=>r._removeUnmounted()),l}function Oc(e){const t=ba(),{name:r,disabled:n,control:i=t.control,shouldUnregister:a}=e,o=zs(i._names.array,r),s=Tc({control:i,name:r,defaultValue:Z(i._formValues,r,Z(i._defaultValues,r,e.defaultValue)),exact:!0}),l=kc({control:i,name:r,exact:!0}),p=$.useRef(e),u=$.useRef(i.register(r,{...e.rules,value:s,...rt(e.disabled)?{disabled:e.disabled}:{}})),d=$.useMemo(()=>Object.defineProperties({},{invalid:{enumerable:!0,get:()=>!!Z(l.errors,r)},isDirty:{enumerable:!0,get:()=>!!Z(l.dirtyFields,r)},isTouched:{enumerable:!0,get:()=>!!Z(l.touchedFields,r)},isValidating:{enumerable:!0,get:()=>!!Z(l.validatingFields,r)},error:{enumerable:!0,get:()=>Z(l.errors,r)}}),[l,r]),f=$.useCallback(b=>u.current.onChange({target:{value:Ms(b),name:r},type:Wn.CHANGE}),[r]),y=$.useCallback(()=>u.current.onBlur({target:{value:Z(i._formValues,r),name:r},type:Wn.BLUR}),[r,i._formValues]),S=$.useCallback(b=>{const g=Z(i._fields,r);g&&b&&(g._f.ref={focus:()=>b.focus&&b.focus(),select:()=>b.select&&b.select(),setCustomValidity:O=>b.setCustomValidity(O),reportValidity:()=>b.reportValidity()})},[i._fields,r]),c=$.useMemo(()=>({name:r,value:s,...rt(n)||l.disabled?{disabled:l.disabled||n}:{},onChange:f,onBlur:y,ref:S}),[r,n,l.disabled,f,y,S,s]);return $.useEffect(()=>{const b=i._options.shouldUnregister||a;i.register(r,{...p.current.rules,...rt(p.current.disabled)?{disabled:p.current.disabled}:{}});const g=(O,A)=>{const k=Z(i._fields,O);k&&k._f&&(k._f.mount=A)};if(g(r,!0),b){const O=Ne(Z(i._options.defaultValues,r));Se(i._defaultValues,r,O),Ie(Z(i._formValues,r))&&Se(i._formValues,r,O)}return!o&&i.register(r),()=>{(o?b&&!i._state.action:b)?i.unregister(r):g(r,!1)}},[r,i,o,a]),$.useEffect(()=>{i._setDisabledField({disabled:n,name:r})},[n,r,i]),$.useMemo(()=>({field:c,formState:l,fieldState:d}),[c,l,d])}const bt=e=>e.render(Oc(e));var Ls=(e,t,r,n,i)=>t?{...r[e],types:{...r[e]&&r[e].types?r[e].types:{},[n]:i||!0}}:{},pn=e=>Array.isArray(e)?e:[e],Ka=()=>{let e=[];return{get observers(){return e},next:i=>{for(const a of e)a.next&&a.next(i)},subscribe:i=>(e.push(i),{unsubscribe:()=>{e=e.filter(a=>a!==i)}}),unsubscribe:()=>{e=[]}}},zi=e=>He(e)||!Is(e);function Lt(e,t){if(zi(e)||zi(t))return e===t;if(lr(e)&&lr(t))return e.getTime()===t.getTime();const r=Object.keys(e),n=Object.keys(t);if(r.length!==n.length)return!1;for(const i of r){const a=e[i];if(!n.includes(i))return!1;if(i!=="ref"){const o=t[i];if(lr(a)&&lr(o)||Me(a)&&Me(o)||Array.isArray(a)&&Array.isArray(o)?!Lt(a,o):a!==o)return!1}}return!0}var Xe=e=>Me(e)&&!Object.keys(e).length,Sa=e=>e.type==="file",yt=e=>typeof e=="function",Hn=e=>{if(!ya)return!1;const t=e?e.ownerDocument:0;return e instanceof(t&&t.defaultView?t.defaultView.HTMLElement:HTMLElement)},qs=e=>e.type==="select-multiple",Ca=e=>e.type==="radio",jc=e=>Ca(e)||Sn(e),wi=e=>Hn(e)&&e.isConnected;function Fc(e,t){const r=t.slice(0,-1).length;let n=0;for(;n<r;)e=Ie(e)?n++:e[t[n++]];return e}function _c(e){for(const t in e)if(e.hasOwnProperty(t)&&!Ie(e[t]))return!1;return!0}function Ve(e,t){const r=Array.isArray(t)?t:ci(t)?[t]:va(t),n=r.length===1?e:Fc(e,r),i=r.length-1,a=r[i];return n&&delete n[a],i!==0&&(Me(n)&&Xe(n)||Array.isArray(n)&&_c(n))&&Ve(e,r.slice(0,-1)),e}var Us=e=>{for(const t in e)if(yt(e[t]))return!0;return!1};function Kn(e,t={}){const r=Array.isArray(e);if(Me(e)||r)for(const n in e)Array.isArray(e[n])||Me(e[n])&&!Us(e[n])?(t[n]=Array.isArray(e[n])?[]:{},Kn(e[n],t[n])):He(e[n])||(t[n]=!0);return t}function Ws(e,t,r){const n=Array.isArray(e);if(Me(e)||n)for(const i in e)Array.isArray(e[i])||Me(e[i])&&!Us(e[i])?Ie(t)||zi(r[i])?r[i]=Array.isArray(e[i])?Kn(e[i],[]):{...Kn(e[i])}:Ws(e[i],He(t)?{}:t[i],r[i]):r[i]=!Lt(e[i],t[i]);return r}var nn=(e,t)=>Ws(e,t,Kn(t));const Qa={value:!1,isValid:!1},Ya={value:!0,isValid:!0};var Hs=e=>{if(Array.isArray(e)){if(e.length>1){const t=e.filter(r=>r&&r.checked&&!r.disabled).map(r=>r.value);return{value:t,isValid:!!t.length}}return e[0].checked&&!e[0].disabled?e[0].attributes&&!Ie(e[0].attributes.value)?Ie(e[0].value)||e[0].value===""?Ya:{value:e[0].value,isValid:!0}:Ya:Qa}return Qa},Ks=(e,{valueAsNumber:t,valueAsDate:r,setValueAs:n})=>Ie(e)?e:t?e===""?NaN:e&&+e:r&&jt(e)?new Date(e):n?n(e):e;const Ga={isValid:!1,value:null};var Qs=e=>Array.isArray(e)?e.reduce((t,r)=>r&&r.checked&&!r.disabled?{isValid:!0,value:r.value}:t,Ga):Ga;function Za(e){const t=e.ref;return Sa(t)?t.files:Ca(t)?Qs(e.refs).value:qs(t)?[...t.selectedOptions].map(({value:r})=>r):Sn(t)?Hs(e.refs).value:Ks(Ie(t.value)?e.ref.value:t.value,e)}var Ac=(e,t,r,n)=>{const i={};for(const a of e){const o=Z(t,a);o&&Se(i,a,o._f)}return{criteriaMode:r,names:[...e],fields:i,shouldUseNativeValidation:n}},Qn=e=>e instanceof RegExp,an=e=>Ie(e)?e:Qn(e)?e.source:Me(e)?Qn(e.value)?e.value.source:e.value:e,Xa=e=>({isOnSubmit:!e||e===gt.onSubmit,isOnBlur:e===gt.onBlur,isOnChange:e===gt.onChange,isOnAll:e===gt.all,isOnTouch:e===gt.onTouched});const Ja="AsyncFunction";var Rc=e=>!!e&&!!e.validate&&!!(yt(e.validate)&&e.validate.constructor.name===Ja||Me(e.validate)&&Object.values(e.validate).find(t=>t.constructor.name===Ja)),$c=e=>e.mount&&(e.required||e.min||e.max||e.maxLength||e.minLength||e.pattern||e.validate),eo=(e,t,r)=>!r&&(t.watchAll||t.watch.has(e)||[...t.watch].some(n=>e.startsWith(n)&&/^\.\w+/.test(e.slice(n.length))));const dn=(e,t,r,n)=>{for(const i of r||Object.keys(e)){const a=Z(e,i);if(a){const{_f:o,...s}=a;if(o){if(o.refs&&o.refs[0]&&t(o.refs[0],i)&&!n)return!0;if(o.ref&&t(o.ref,o.name)&&!n)return!0;if(dn(s,t))break}else if(Me(s)&&dn(s,t))break}}};function to(e,t,r){const n=Z(e,r);if(n||ci(r))return{error:n,name:r};const i=r.split(".");for(;i.length;){const a=i.join("."),o=Z(t,a),s=Z(e,a);if(o&&!Array.isArray(o)&&r!==a)return{name:r};if(s&&s.type)return{name:a,error:s};if(s&&s.root&&s.root.type)return{name:`${a}.root`,error:s.root};i.pop()}return{name:r}}var Dc=(e,t,r,n)=>{r(e);const{name:i,...a}=e;return Xe(a)||Object.keys(a).length>=Object.keys(t).length||Object.keys(a).find(o=>t[o]===(!n||gt.all))},Pc=(e,t,r)=>!e||!t||e===t||pn(e).some(n=>n&&(r?n===t:n.startsWith(t)||t.startsWith(n))),Ic=(e,t,r,n,i)=>i.isOnAll?!1:!r&&i.isOnTouch?!(t||e):(r?n.isOnBlur:i.isOnBlur)?!e:(r?n.isOnChange:i.isOnChange)?e:!0,Mc=(e,t)=>!xa(Z(e,t)).length&&Ve(e,t),zc=(e,t,r)=>{const n=pn(Z(e,r));return Se(n,"root",t[r]),Se(e,r,n),e},Vn=e=>jt(e);function ro(e,t,r="validate"){if(Vn(e)||Array.isArray(e)&&e.every(Vn)||rt(e)&&!e)return{type:r,message:Vn(e)?e:"",ref:t}}var Fr=e=>Me(e)&&!Qn(e)?e:{value:e,message:""},no=async(e,t,r,n,i,a)=>{const{ref:o,refs:s,required:l,maxLength:p,minLength:u,min:d,max:f,pattern:y,validate:S,name:c,valueAsNumber:b,mount:g}=e._f,O=Z(r,c);if(!g||t.has(c))return{};const A=s?s[0]:o,k=P=>{i&&A.reportValidity&&(A.setCustomValidity(rt(P)?"":P||""),A.reportValidity())},x={},B=Ca(o),_=Sn(o),K=B||_,W=(b||Sa(o))&&Ie(o.value)&&Ie(O)||Hn(o)&&o.value===""||O===""||Array.isArray(O)&&!O.length,h=Ls.bind(null,c,n,x),M=(P,q,N,X=_t.maxLength,ie=_t.minLength)=>{const ge=P?q:N;x[c]={type:P?X:ie,message:ge,ref:o,...h(P?X:ie,ge)}};if(a?!Array.isArray(O)||!O.length:l&&(!K&&(W||He(O))||rt(O)&&!O||_&&!Hs(s).isValid||B&&!Qs(s).isValid)){const{value:P,message:q}=Vn(l)?{value:!!l,message:l}:Fr(l);if(P&&(x[c]={type:_t.required,message:q,ref:A,...h(_t.required,q)},!n))return k(q),x}if(!W&&(!He(d)||!He(f))){let P,q;const N=Fr(f),X=Fr(d);if(!He(O)&&!isNaN(O)){const ie=o.valueAsNumber||O&&+O;He(N.value)||(P=ie>N.value),He(X.value)||(q=ie<X.value)}else{const ie=o.valueAsDate||new Date(O),ge=V=>new Date(new Date().toDateString()+" "+V),ce=o.type=="time",se=o.type=="week";jt(N.value)&&O&&(P=ce?ge(O)>ge(N.value):se?O>N.value:ie>new Date(N.value)),jt(X.value)&&O&&(q=ce?ge(O)<ge(X.value):se?O<X.value:ie<new Date(X.value))}if((P||q)&&(M(!!P,N.message,X.message,_t.max,_t.min),!n))return k(x[c].message),x}if((p||u)&&!W&&(jt(O)||a&&Array.isArray(O))){const P=Fr(p),q=Fr(u),N=!He(P.value)&&O.length>+P.value,X=!He(q.value)&&O.length<+q.value;if((N||X)&&(M(N,P.message,q.message),!n))return k(x[c].message),x}if(y&&!W&&jt(O)){const{value:P,message:q}=Fr(y);if(Qn(P)&&!O.match(P)&&(x[c]={type:_t.pattern,message:q,ref:o,...h(_t.pattern,q)},!n))return k(q),x}if(S){if(yt(S)){const P=await S(O,r),q=ro(P,A);if(q&&(x[c]={...q,...h(_t.validate,q.message)},!n))return k(q.message),x}else if(Me(S)){let P={};for(const q in S){if(!Xe(P)&&!n)break;const N=ro(await S[q](O,r),A,q);N&&(P={...N,...h(q,N.message)},k(N.message),n&&(x[c]=P))}if(!Xe(P)&&(x[c]={ref:A,...P},!n))return x}}return k(!0),x};const Vc={mode:gt.onSubmit,reValidateMode:gt.onChange,shouldFocusError:!0};function Bc(e={}){let t={...Vc,...e},r={submitCount:0,isDirty:!1,isReady:!1,isLoading:yt(t.defaultValues),isValidating:!1,isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,touchedFields:{},dirtyFields:{},validatingFields:{},errors:t.errors||{},disabled:t.disabled||!1};const n={};let i=Me(t.defaultValues)||Me(t.values)?Ne(t.defaultValues||t.values)||{}:{},a=t.shouldUnregister?{}:Ne(i),o={action:!1,mount:!1,watch:!1},s={mount:new Set,disabled:new Set,unMount:new Set,array:new Set,watch:new Set},l,p=0;const u={isDirty:!1,dirtyFields:!1,validatingFields:!1,touchedFields:!1,isValidating:!1,isValid:!1,errors:!1};let d={...u};const f={array:Ka(),state:Ka()},y=t.criteriaMode===gt.all,S=v=>j=>{clearTimeout(p),p=setTimeout(v,j)},c=async v=>{if(!t.disabled&&(u.isValid||d.isValid||v)){const j=t.resolver?Xe((await _()).errors):await W(n,!0);j!==r.isValid&&f.state.next({isValid:j})}},b=(v,j)=>{!t.disabled&&(u.isValidating||u.validatingFields||d.isValidating||d.validatingFields)&&((v||Array.from(s.mount)).forEach(T=>{T&&(j?Se(r.validatingFields,T,j):Ve(r.validatingFields,T))}),f.state.next({validatingFields:r.validatingFields,isValidating:!Xe(r.validatingFields)}))},g=(v,j=[],T,G,F=!0,R=!0)=>{if(G&&T&&!t.disabled){if(o.action=!0,R&&Array.isArray(Z(n,v))){const J=T(Z(n,v),G.argA,G.argB);F&&Se(n,v,J)}if(R&&Array.isArray(Z(r.errors,v))){const J=T(Z(r.errors,v),G.argA,G.argB);F&&Se(r.errors,v,J),Mc(r.errors,v)}if((u.touchedFields||d.touchedFields)&&R&&Array.isArray(Z(r.touchedFields,v))){const J=T(Z(r.touchedFields,v),G.argA,G.argB);F&&Se(r.touchedFields,v,J)}(u.dirtyFields||d.dirtyFields)&&(r.dirtyFields=nn(i,a)),f.state.next({name:v,isDirty:M(v,j),dirtyFields:r.dirtyFields,errors:r.errors,isValid:r.isValid})}else Se(a,v,j)},O=(v,j)=>{Se(r.errors,v,j),f.state.next({errors:r.errors})},A=v=>{r.errors=v,f.state.next({errors:r.errors,isValid:!1})},k=(v,j,T,G)=>{const F=Z(n,v);if(F){const R=Z(a,v,Ie(T)?Z(i,v):T);Ie(R)||G&&G.defaultChecked||j?Se(a,v,j?R:Za(F._f)):N(v,R),o.mount&&c()}},x=(v,j,T,G,F)=>{let R=!1,J=!1;const he={name:v};if(!t.disabled){if(!T||G){(u.isDirty||d.isDirty)&&(J=r.isDirty,r.isDirty=he.isDirty=M(),R=J!==he.isDirty);const ye=Lt(Z(i,v),j);J=!!Z(r.dirtyFields,v),ye?Ve(r.dirtyFields,v):Se(r.dirtyFields,v,!0),he.dirtyFields=r.dirtyFields,R=R||(u.dirtyFields||d.dirtyFields)&&J!==!ye}if(T){const ye=Z(r.touchedFields,v);ye||(Se(r.touchedFields,v,T),he.touchedFields=r.touchedFields,R=R||(u.touchedFields||d.touchedFields)&&ye!==T)}R&&F&&f.state.next(he)}return R?he:{}},B=(v,j,T,G)=>{const F=Z(r.errors,v),R=(u.isValid||d.isValid)&&rt(j)&&r.isValid!==j;if(t.delayError&&T?(l=S(()=>O(v,T)),l(t.delayError)):(clearTimeout(p),l=null,T?Se(r.errors,v,T):Ve(r.errors,v)),(T?!Lt(F,T):F)||!Xe(G)||R){const J={...G,...R&&rt(j)?{isValid:j}:{},errors:r.errors,name:v};r={...r,...J},f.state.next(J)}},_=async v=>{b(v,!0);const j=await t.resolver(a,t.context,Ac(v||s.mount,n,t.criteriaMode,t.shouldUseNativeValidation));return b(v),j},K=async v=>{const{errors:j}=await _(v);if(v)for(const T of v){const G=Z(j,T);G?Se(r.errors,T,G):Ve(r.errors,T)}else r.errors=j;return j},W=async(v,j,T={valid:!0})=>{for(const G in v){const F=v[G];if(F){const{_f:R,...J}=F;if(R){const he=s.array.has(R.name),ye=F._f&&Rc(F._f);ye&&u.validatingFields&&b([G],!0);const Be=await no(F,s.disabled,a,y,t.shouldUseNativeValidation&&!j,he);if(ye&&u.validatingFields&&b([G]),Be[R.name]&&(T.valid=!1,j))break;!j&&(Z(Be,R.name)?he?zc(r.errors,Be,R.name):Se(r.errors,R.name,Be[R.name]):Ve(r.errors,R.name))}!Xe(J)&&await W(J,j,T)}}return T.valid},h=()=>{for(const v of s.unMount){const j=Z(n,v);j&&(j._f.refs?j._f.refs.every(T=>!wi(T)):!wi(j._f.ref))&&ee(v)}s.unMount=new Set},M=(v,j)=>!t.disabled&&(v&&j&&Se(a,v,j),!Lt(V(),i)),P=(v,j,T)=>Ns(v,s,{...o.mount?a:Ie(j)?i:jt(v)?{[v]:j}:j},T,j),q=v=>xa(Z(o.mount?a:i,v,t.shouldUnregister?Z(i,v,[]):[])),N=(v,j,T={})=>{const G=Z(n,v);let F=j;if(G){const R=G._f;R&&(!R.disabled&&Se(a,v,Ks(j,R)),F=Hn(R.ref)&&He(j)?"":j,qs(R.ref)?[...R.ref.options].forEach(J=>J.selected=F.includes(J.value)):R.refs?Sn(R.ref)?R.refs.forEach(J=>{(!J.defaultChecked||!J.disabled)&&(Array.isArray(F)?J.checked=!!F.find(he=>he===J.value):J.checked=F===J.value||!!F)}):R.refs.forEach(J=>J.checked=J.value===F):Sa(R.ref)?R.ref.value="":(R.ref.value=F,R.ref.type||f.state.next({name:v,values:Ne(a)})))}(T.shouldDirty||T.shouldTouch)&&x(v,F,T.shouldTouch,T.shouldDirty,!0),T.shouldValidate&&se(v)},X=(v,j,T)=>{for(const G in j){if(!j.hasOwnProperty(G))return;const F=j[G],R=v+"."+G,J=Z(n,R);(s.array.has(v)||Me(F)||J&&!J._f)&&!lr(F)?X(R,F,T):N(R,F,T)}},ie=(v,j,T={})=>{const G=Z(n,v),F=s.array.has(v),R=Ne(j);Se(a,v,R),F?(f.array.next({name:v,values:Ne(a)}),(u.isDirty||u.dirtyFields||d.isDirty||d.dirtyFields)&&T.shouldDirty&&f.state.next({name:v,dirtyFields:nn(i,a),isDirty:M(v,R)})):G&&!G._f&&!He(R)?X(v,R,T):N(v,R,T),eo(v,s)&&f.state.next({...r}),f.state.next({name:o.mount?v:void 0,values:Ne(a)})},ge=async v=>{o.mount=!0;const j=v.target;let T=j.name,G=!0;const F=Z(n,T),R=ye=>{G=Number.isNaN(ye)||lr(ye)&&isNaN(ye.getTime())||Lt(ye,Z(a,T,ye))},J=Xa(t.mode),he=Xa(t.reValidateMode);if(F){let ye,Be;const ft=j.type?Za(F._f):Ms(v),st=v.type===Wn.BLUR||v.type===Wn.FOCUS_OUT,Jr=!$c(F._f)&&!t.resolver&&!Z(r.errors,T)&&!F._f.deps||Ic(st,Z(r.touchedFields,T),r.isSubmitted,he,J),ir=eo(T,s,st);Se(a,T,ft),st?(F._f.onBlur&&F._f.onBlur(v),l&&l(0)):F._f.onChange&&F._f.onChange(v);const zt=x(T,ft,st),en=!Xe(zt)||ir;if(!st&&f.state.next({name:T,type:v.type,values:Ne(a)}),Jr)return(u.isValid||d.isValid)&&(t.mode==="onBlur"?st&&c():st||c()),en&&f.state.next({name:T,...ir?{}:zt});if(!st&&ir&&f.state.next({...r}),t.resolver){const{errors:Or}=await _([T]);if(R(ft),G){const tn=to(r.errors,n,T),jr=to(Or,n,tn.name||T);ye=jr.error,T=jr.name,Be=Xe(Or)}}else b([T],!0),ye=(await no(F,s.disabled,a,y,t.shouldUseNativeValidation))[T],b([T]),R(ft),G&&(ye?Be=!1:(u.isValid||d.isValid)&&(Be=await W(n,!0)));G&&(F._f.deps&&se(F._f.deps),B(T,Be,ye,zt))}},ce=(v,j)=>{if(Z(r.errors,j)&&v.focus)return v.focus(),1},se=async(v,j={})=>{let T,G;const F=pn(v);if(t.resolver){const R=await K(Ie(v)?v:F);T=Xe(R),G=v?!F.some(J=>Z(R,J)):T}else v?(G=(await Promise.all(F.map(async R=>{const J=Z(n,R);return await W(J&&J._f?{[R]:J}:J)}))).every(Boolean),!(!G&&!r.isValid)&&c()):G=T=await W(n);return f.state.next({...!jt(v)||(u.isValid||d.isValid)&&T!==r.isValid?{}:{name:v},...t.resolver||!v?{isValid:T}:{},errors:r.errors}),j.shouldFocus&&!G&&dn(n,ce,v?F:s.mount),G},V=v=>{const j={...o.mount?a:i};return Ie(v)?j:jt(v)?Z(j,v):v.map(T=>Z(j,T))},H=(v,j)=>({invalid:!!Z((j||r).errors,v),isDirty:!!Z((j||r).dirtyFields,v),error:Z((j||r).errors,v),isValidating:!!Z(r.validatingFields,v),isTouched:!!Z((j||r).touchedFields,v)}),ue=v=>{v&&pn(v).forEach(j=>Ve(r.errors,j)),f.state.next({errors:v?r.errors:{}})},Y=(v,j,T)=>{const G=(Z(n,v,{_f:{}})._f||{}).ref,F=Z(r.errors,v)||{},{ref:R,message:J,type:he,...ye}=F;Se(r.errors,v,{...ye,...j,ref:G}),f.state.next({name:v,errors:r.errors,isValid:!1}),T&&T.shouldFocus&&G&&G.focus&&G.focus()},te=(v,j)=>yt(v)?f.state.subscribe({next:T=>v(P(void 0,j),T)}):P(v,j,!0),le=v=>f.state.subscribe({next:j=>{Pc(v.name,j.name,v.exact)&&Dc(j,v.formState||u,Te,v.reRenderRoot)&&v.callback({values:{...a},...r,...j})}}).unsubscribe,U=v=>(o.mount=!0,d={...d,...v.formState},le({...v,formState:d})),ee=(v,j={})=>{for(const T of v?pn(v):s.mount)s.mount.delete(T),s.array.delete(T),j.keepValue||(Ve(n,T),Ve(a,T)),!j.keepError&&Ve(r.errors,T),!j.keepDirty&&Ve(r.dirtyFields,T),!j.keepTouched&&Ve(r.touchedFields,T),!j.keepIsValidating&&Ve(r.validatingFields,T),!t.shouldUnregister&&!j.keepDefaultValue&&Ve(i,T);f.state.next({values:Ne(a)}),f.state.next({...r,...j.keepDirty?{isDirty:M()}:{}}),!j.keepIsValid&&c()},oe=({disabled:v,name:j})=>{(rt(v)&&o.mount||v||s.disabled.has(j))&&(v?s.disabled.add(j):s.disabled.delete(j))},fe=(v,j={})=>{let T=Z(n,v);const G=rt(j.disabled)||rt(t.disabled);return Se(n,v,{...T||{},_f:{...T&&T._f?T._f:{ref:{name:v}},name:v,mount:!0,...j}}),s.mount.add(v),T?oe({disabled:rt(j.disabled)?j.disabled:t.disabled,name:v}):k(v,!0,j.value),{...G?{disabled:j.disabled||t.disabled}:{},...t.progressive?{required:!!j.required,min:an(j.min),max:an(j.max),minLength:an(j.minLength),maxLength:an(j.maxLength),pattern:an(j.pattern)}:{},name:v,onChange:ge,onBlur:ge,ref:F=>{if(F){fe(v,j),T=Z(n,v);const R=Ie(F.value)&&F.querySelectorAll&&F.querySelectorAll("input,select,textarea")[0]||F,J=jc(R),he=T._f.refs||[];if(J?he.find(ye=>ye===R):R===T._f.ref)return;Se(n,v,{_f:{...T._f,...J?{refs:[...he.filter(wi),R,...Array.isArray(Z(i,v))?[{}]:[]],ref:{type:R.type,name:v}}:{ref:R}}}),k(v,!1,void 0,R)}else T=Z(n,v,{}),T._f&&(T._f.mount=!1),(t.shouldUnregister||j.shouldUnregister)&&!(zs(s.array,v)&&o.action)&&s.unMount.add(v)}}},pe=()=>t.shouldFocusError&&dn(n,ce,s.mount),L=v=>{rt(v)&&(f.state.next({disabled:v}),dn(n,(j,T)=>{const G=Z(n,T);G&&(j.disabled=G._f.disabled||v,Array.isArray(G._f.refs)&&G._f.refs.forEach(F=>{F.disabled=G._f.disabled||v}))},0,!1))},I=(v,j)=>async T=>{let G;T&&(T.preventDefault&&T.preventDefault(),T.persist&&T.persist());let F=Ne(a);if(f.state.next({isSubmitting:!0}),t.resolver){const{errors:R,values:J}=await _();r.errors=R,F=J}else await W(n);if(s.disabled.size)for(const R of s.disabled)Se(F,R,void 0);if(Ve(r.errors,"root"),Xe(r.errors)){f.state.next({errors:{}});try{await v(F,T)}catch(R){G=R}}else j&&await j({...r.errors},T),pe(),setTimeout(pe);if(f.state.next({isSubmitted:!0,isSubmitting:!1,isSubmitSuccessful:Xe(r.errors)&&!G,submitCount:r.submitCount+1,errors:r.errors}),G)throw G},z=(v,j={})=>{Z(n,v)&&(Ie(j.defaultValue)?ie(v,Ne(Z(i,v))):(ie(v,j.defaultValue),Se(i,v,Ne(j.defaultValue))),j.keepTouched||Ve(r.touchedFields,v),j.keepDirty||(Ve(r.dirtyFields,v),r.isDirty=j.defaultValue?M(v,Ne(Z(i,v))):M()),j.keepError||(Ve(r.errors,v),u.isValid&&c()),f.state.next({...r}))},ae=(v,j={})=>{const T=v?Ne(v):i,G=Ne(T),F=Xe(v),R=F?i:G;if(j.keepDefaultValues||(i=T),!j.keepValues){if(j.keepDirtyValues){const J=new Set([...s.mount,...Object.keys(nn(i,a))]);for(const he of Array.from(J))Z(r.dirtyFields,he)?Se(R,he,Z(a,he)):ie(he,Z(R,he))}else{if(ya&&Ie(v))for(const J of s.mount){const he=Z(n,J);if(he&&he._f){const ye=Array.isArray(he._f.refs)?he._f.refs[0]:he._f.ref;if(Hn(ye)){const Be=ye.closest("form");if(Be){Be.reset();break}}}}for(const J of s.mount)ie(J,Z(R,J))}a=Ne(R),f.array.next({values:{...R}}),f.state.next({values:{...R}})}s={mount:j.keepDirtyValues?s.mount:new Set,unMount:new Set,array:new Set,disabled:new Set,watch:new Set,watchAll:!1,focus:""},o.mount=!u.isValid||!!j.keepIsValid||!!j.keepDirtyValues,o.watch=!!t.shouldUnregister,f.state.next({submitCount:j.keepSubmitCount?r.submitCount:0,isDirty:F?!1:j.keepDirty?r.isDirty:!!(j.keepDefaultValues&&!Lt(v,i)),isSubmitted:j.keepIsSubmitted?r.isSubmitted:!1,dirtyFields:F?{}:j.keepDirtyValues?j.keepDefaultValues&&a?nn(i,a):r.dirtyFields:j.keepDefaultValues&&v?nn(i,v):j.keepDirty?r.dirtyFields:{},touchedFields:j.keepTouched?r.touchedFields:{},errors:j.keepErrors?r.errors:{},isSubmitSuccessful:j.keepIsSubmitSuccessful?r.isSubmitSuccessful:!1,isSubmitting:!1})},de=(v,j)=>ae(yt(v)?v(a):v,j),_e=(v,j={})=>{const T=Z(n,v),G=T&&T._f;if(G){const F=G.refs?G.refs[0]:G.ref;F.focus&&(F.focus(),j.shouldSelect&&yt(F.select)&&F.select())}},Te=v=>{r={...r,...v}},Ye={control:{register:fe,unregister:ee,getFieldState:H,handleSubmit:I,setError:Y,_subscribe:le,_runSchema:_,_focusError:pe,_getWatch:P,_getDirty:M,_setValid:c,_setFieldArray:g,_setDisabledField:oe,_setErrors:A,_getFieldArray:q,_reset:ae,_resetDefaultValues:()=>yt(t.defaultValues)&&t.defaultValues().then(v=>{de(v,t.resetOptions),f.state.next({isLoading:!1})}),_removeUnmounted:h,_disableForm:L,_subjects:f,_proxyFormState:u,get _fields(){return n},get _formValues(){return a},get _state(){return o},set _state(v){o=v},get _defaultValues(){return i},get _names(){return s},set _names(v){s=v},get _formState(){return r},get _options(){return t},set _options(v){t={...t,...v}}},subscribe:U,trigger:se,register:fe,handleSubmit:I,watch:te,setValue:ie,getValues:V,reset:de,resetField:z,clearErrors:ue,unregister:ee,setError:Y,setFocus:_e,getFieldState:H};return{...Ye,formControl:Ye}}function Nc(e={}){const t=$.useRef(void 0),r=$.useRef(void 0),[n,i]=$.useState({isDirty:!1,isValidating:!1,isLoading:yt(e.defaultValues),isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,submitCount:0,dirtyFields:{},touchedFields:{},validatingFields:{},errors:e.errors||{},disabled:e.disabled||!1,isReady:!1,defaultValues:yt(e.defaultValues)?void 0:e.defaultValues});if(!t.current)if(e.formControl)t.current={...e.formControl,formState:n},e.defaultValues&&!yt(e.defaultValues)&&e.formControl.reset(e.defaultValues,e.resetOptions);else{const{formControl:o,...s}=Bc(e);t.current={...s,formState:n}}const a=t.current.control;return a._options=e,wa(()=>{const o=a._subscribe({formState:a._proxyFormState,callback:()=>i({...a._formState}),reRenderRoot:!0});return i(s=>({...s,isReady:!0})),a._formState.isReady=!0,o},[a]),$.useEffect(()=>a._disableForm(e.disabled),[a,e.disabled]),$.useEffect(()=>{e.mode&&(a._options.mode=e.mode),e.reValidateMode&&(a._options.reValidateMode=e.reValidateMode)},[a,e.mode,e.reValidateMode]),$.useEffect(()=>{e.errors&&(a._setErrors(e.errors),a._focusError())},[a,e.errors]),$.useEffect(()=>{e.shouldUnregister&&a._subjects.state.next({values:a._getWatch()})},[a,e.shouldUnregister]),$.useEffect(()=>{if(a._proxyFormState.isDirty){const o=a._getDirty();o!==n.isDirty&&a._subjects.state.next({isDirty:o})}},[a,n.isDirty]),$.useEffect(()=>{e.values&&!Lt(e.values,r.current)?(a._reset(e.values,a._options.resetOptions),r.current=e.values,i(o=>({...o}))):a._resetDefaultValues()},[a,e.values]),$.useEffect(()=>{a._state.mount||(a._setValid(),a._state.mount=!0),a._state.watch&&(a._state.watch=!1,a._subjects.state.next({...a._formState})),a._removeUnmounted()}),t.current.formState=Bs(n,a),t.current}const io=(e,t,r)=>{if(e&&"reportValidity"in e){const n=Z(r,t);e.setCustomValidity(n&&n.message||""),e.reportValidity()}},Ys=(e,t)=>{for(const r in t.fields){const n=t.fields[r];n&&n.ref&&"reportValidity"in n.ref?io(n.ref,r,e):n&&n.refs&&n.refs.forEach(i=>io(i,r,e))}},Lc=(e,t)=>{t.shouldUseNativeValidation&&Ys(e,t);const r={};for(const n in e){const i=Z(t.fields,n),a=Object.assign(e[n]||{},{ref:i&&i.ref});if(qc(t.names||Object.keys(e),n)){const o=Object.assign({},Z(r,n));Se(o,"root",a),Se(r,n,o)}else Se(r,n,a)}return r},qc=(e,t)=>{const r=ao(t);return e.some(n=>ao(n).match(`^${r}\\.\\d+`))};function ao(e){return e.replace(/\]|\[/g,"")}function Uc(e,t,r){return r===void 0&&(r={}),function(n,i,a){try{return Promise.resolve(function(o,s){try{var l=(t!=null&&t.context&&process.env.NODE_ENV==="development"&&console.warn("You should not used the yup options context. Please, use the 'useForm' context object instead"),Promise.resolve(e[r.mode==="sync"?"validateSync":"validate"](n,Object.assign({abortEarly:!1},t,{context:i}))).then(function(p){return a.shouldUseNativeValidation&&Ys({},a),{values:r.raw?Object.assign({},n):p,errors:{}}}))}catch(p){return s(p)}return l&&l.then?l.then(void 0,s):l}(0,function(o){if(!o.inner)throw o;return{values:{},errors:Lc((s=o,l=!a.shouldUseNativeValidation&&a.criteriaMode==="all",(s.inner||[]).reduce(function(p,u){if(p[u.path]||(p[u.path]={message:u.message,type:u.type}),l){var d=p[u.path].types,f=d&&d[u.type];p[u.path]=Ls(u.path,l,p,u.type,f?[].concat(f,u.message):u.message)}return p},{})),a)};var s,l}))}catch(o){return Promise.reject(o)}}}var Cn=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},br=typeof window>"u"||"Deno"in globalThis;function Je(){}function Wc(e,t){return typeof e=="function"?e(t):e}function Vi(e){return typeof e=="number"&&e>=0&&e!==1/0}function Gs(e,t){return Math.max(e+(t||0)-Date.now(),0)}function Xt(e,t){return typeof e=="function"?e(t):e}function ct(e,t){return typeof e=="function"?e(t):e}function oo(e,t){const{type:r="all",exact:n,fetchStatus:i,predicate:a,queryKey:o,stale:s}=e;if(o){if(n){if(t.queryHash!==Ea(o,t.options))return!1}else if(!mn(t.queryKey,o))return!1}if(r!=="all"){const l=t.isActive();if(r==="active"&&!l||r==="inactive"&&l)return!1}return!(typeof s=="boolean"&&t.isStale()!==s||i&&i!==t.state.fetchStatus||a&&!a(t))}function so(e,t){const{exact:r,status:n,predicate:i,mutationKey:a}=e;if(a){if(!t.options.mutationKey)return!1;if(r){if(hn(t.options.mutationKey)!==hn(a))return!1}else if(!mn(t.options.mutationKey,a))return!1}return!(n&&t.state.status!==n||i&&!i(t))}function Ea(e,t){return((t==null?void 0:t.queryKeyHashFn)||hn)(e)}function hn(e){return JSON.stringify(e,(t,r)=>Li(r)?Object.keys(r).sort().reduce((n,i)=>(n[i]=r[i],n),{}):r)}function mn(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?Object.keys(t).every(r=>mn(e[r],t[r])):!1}function Bi(e,t){if(e===t)return e;const r=lo(e)&&lo(t);if(r||Li(e)&&Li(t)){const n=r?e:Object.keys(e),i=n.length,a=r?t:Object.keys(t),o=a.length,s=r?[]:{},l=new Set(n);let p=0;for(let u=0;u<o;u++){const d=r?u:a[u];(!r&&l.has(d)||r)&&e[d]===void 0&&t[d]===void 0?(s[d]=void 0,p++):(s[d]=Bi(e[d],t[d]),s[d]===e[d]&&e[d]!==void 0&&p++)}return i===o&&p===i?e:s}return t}function Ni(e,t){if(!t||Object.keys(e).length!==Object.keys(t).length)return!1;for(const r in e)if(e[r]!==t[r])return!1;return!0}function lo(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function Li(e){if(!co(e))return!1;const t=e.constructor;if(t===void 0)return!0;const r=t.prototype;return!(!co(r)||!r.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function co(e){return Object.prototype.toString.call(e)==="[object Object]"}function Hc(e){return new Promise(t=>{setTimeout(t,e)})}function qi(e,t,r){if(typeof r.structuralSharing=="function")return r.structuralSharing(e,t);if(r.structuralSharing!==!1){if(process.env.NODE_ENV!=="production")try{return Bi(e,t)}catch(n){throw console.error(`Structural sharing requires data to be JSON serializable. To fix this, turn off structuralSharing or return JSON-serializable data from your queryFn. [${r.queryHash}]: ${n}`),n}return Bi(e,t)}return t}function Kc(e,t,r=0){const n=[...e,t];return r&&n.length>r?n.slice(1):n}function Qc(e,t,r=0){const n=[t,...e];return r&&n.length>r?n.slice(0,-1):n}var Yn=Symbol();function Zs(e,t){return process.env.NODE_ENV!=="production"&&e.queryFn===Yn&&console.error(`Attempted to invoke queryFn when set to skipToken. This is likely a configuration error. Query hash: '${e.queryHash}'`),!e.queryFn&&(t!=null&&t.initialPromise)?()=>t.initialPromise:!e.queryFn||e.queryFn===Yn?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}function Yc(e,t){return typeof e=="function"?e(...t):!!e}var ur,qt,zr,Os,Gc=(Os=class extends Cn{constructor(){super();me(this,ur);me(this,qt);me(this,zr);re(this,zr,t=>{if(!br&&window.addEventListener){const r=()=>t();return window.addEventListener("visibilitychange",r,!1),()=>{window.removeEventListener("visibilitychange",r)}}})}onSubscribe(){C(this,qt)||this.setEventListener(C(this,zr))}onUnsubscribe(){var t;this.hasListeners()||((t=C(this,qt))==null||t.call(this),re(this,qt,void 0))}setEventListener(t){var r;re(this,zr,t),(r=C(this,qt))==null||r.call(this),re(this,qt,t(n=>{typeof n=="boolean"?this.setFocused(n):this.onFocus()}))}setFocused(t){C(this,ur)!==t&&(re(this,ur,t),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(r=>{r(t)})}isFocused(){var t;return typeof C(this,ur)=="boolean"?C(this,ur):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},ur=new WeakMap,qt=new WeakMap,zr=new WeakMap,Os),ka=new Gc,Vr,Ut,Br,js,Zc=(js=class extends Cn{constructor(){super();me(this,Vr,!0);me(this,Ut);me(this,Br);re(this,Br,t=>{if(!br&&window.addEventListener){const r=()=>t(!0),n=()=>t(!1);return window.addEventListener("online",r,!1),window.addEventListener("offline",n,!1),()=>{window.removeEventListener("online",r),window.removeEventListener("offline",n)}}})}onSubscribe(){C(this,Ut)||this.setEventListener(C(this,Br))}onUnsubscribe(){var t;this.hasListeners()||((t=C(this,Ut))==null||t.call(this),re(this,Ut,void 0))}setEventListener(t){var r;re(this,Br,t),(r=C(this,Ut))==null||r.call(this),re(this,Ut,t(this.setOnline.bind(this)))}setOnline(t){C(this,Vr)!==t&&(re(this,Vr,t),this.listeners.forEach(n=>{n(t)}))}isOnline(){return C(this,Vr)}},Vr=new WeakMap,Ut=new WeakMap,Br=new WeakMap,js),Gn=new Zc;function Ui(){let e,t;const r=new Promise((i,a)=>{e=i,t=a});r.status="pending",r.catch(()=>{});function n(i){Object.assign(r,i),delete r.resolve,delete r.reject}return r.resolve=i=>{n({status:"fulfilled",value:i}),e(i)},r.reject=i=>{n({status:"rejected",reason:i}),t(i)},r}function Xc(e){return Math.min(1e3*2**e,3e4)}function Xs(e){return(e??"online")==="online"?Gn.isOnline():!0}var Js=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function Si(e){return e instanceof Js}function el(e){let t=!1,r=0,n=!1,i;const a=Ui(),o=c=>{var b;n||(f(new Js(c)),(b=e.abort)==null||b.call(e))},s=()=>{t=!0},l=()=>{t=!1},p=()=>ka.isFocused()&&(e.networkMode==="always"||Gn.isOnline())&&e.canRun(),u=()=>Xs(e.networkMode)&&e.canRun(),d=c=>{var b;n||(n=!0,(b=e.onSuccess)==null||b.call(e,c),i==null||i(),a.resolve(c))},f=c=>{var b;n||(n=!0,(b=e.onError)==null||b.call(e,c),i==null||i(),a.reject(c))},y=()=>new Promise(c=>{var b;i=g=>{(n||p())&&c(g)},(b=e.onPause)==null||b.call(e)}).then(()=>{var c;i=void 0,n||(c=e.onContinue)==null||c.call(e)}),S=()=>{if(n)return;let c;const b=r===0?e.initialPromise:void 0;try{c=b??e.fn()}catch(g){c=Promise.reject(g)}Promise.resolve(c).then(d).catch(g=>{var B;if(n)return;const O=e.retry??(br?0:3),A=e.retryDelay??Xc,k=typeof A=="function"?A(r,g):A,x=O===!0||typeof O=="number"&&r<O||typeof O=="function"&&O(r,g);if(t||!x){f(g);return}r++,(B=e.onFail)==null||B.call(e,r,g),Hc(k).then(()=>p()?void 0:y()).then(()=>{t?f(g):S()})})};return{promise:a,cancel:o,continue:()=>(i==null||i(),a),cancelRetry:s,continueRetry:l,canStart:u,start:()=>(u()?S():y().then(S),a)}}var Jc=e=>setTimeout(e,0);function eu(){let e=[],t=0,r=s=>{s()},n=s=>{s()},i=Jc;const a=s=>{t?e.push(s):i(()=>{r(s)})},o=()=>{const s=e;e=[],s.length&&i(()=>{n(()=>{s.forEach(l=>{r(l)})})})};return{batch:s=>{let l;t++;try{l=s()}finally{t--,t||o()}return l},batchCalls:s=>(...l)=>{a(()=>{s(...l)})},schedule:a,setNotifyFunction:s=>{r=s},setBatchNotifyFunction:s=>{n=s},setScheduler:s=>{i=s}}}var Le=eu(),pr,Fs,tl=(Fs=class{constructor(){me(this,pr)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),Vi(this.gcTime)&&re(this,pr,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(br?1/0:5*60*1e3))}clearGcTimeout(){C(this,pr)&&(clearTimeout(C(this,pr)),re(this,pr,void 0))}},pr=new WeakMap,Fs),Nr,dr,lt,fr,qe,xn,hr,ht,Pt,_s,tu=(_s=class extends tl{constructor(t){super();me(this,ht);me(this,Nr);me(this,dr);me(this,lt);me(this,fr);me(this,qe);me(this,xn);me(this,hr);re(this,hr,!1),re(this,xn,t.defaultOptions),this.setOptions(t.options),this.observers=[],re(this,fr,t.client),re(this,lt,C(this,fr).getQueryCache()),this.queryKey=t.queryKey,this.queryHash=t.queryHash,re(this,Nr,ru(this.options)),this.state=t.state??C(this,Nr),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return(t=C(this,qe))==null?void 0:t.promise}setOptions(t){this.options={...C(this,xn),...t},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&C(this,lt).remove(this)}setData(t,r){const n=qi(this.state.data,t,this.options);return xe(this,ht,Pt).call(this,{data:n,type:"success",dataUpdatedAt:r==null?void 0:r.updatedAt,manual:r==null?void 0:r.manual}),n}setState(t,r){xe(this,ht,Pt).call(this,{type:"setState",state:t,setStateOptions:r})}cancel(t){var n,i;const r=(n=C(this,qe))==null?void 0:n.promise;return(i=C(this,qe))==null||i.cancel(t),r?r.then(Je).catch(Je):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(C(this,Nr))}isActive(){return this.observers.some(t=>ct(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===Yn||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStatic(){return this.getObserversCount()>0?this.observers.some(t=>Xt(t.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(t=>t.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(t=0){return this.state.data===void 0?!0:t==="static"?!1:this.state.isInvalidated?!0:!Gs(this.state.dataUpdatedAt,t)}onFocus(){var r;const t=this.observers.find(n=>n.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(r=C(this,qe))==null||r.continue()}onOnline(){var r;const t=this.observers.find(n=>n.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(r=C(this,qe))==null||r.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),C(this,lt).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(r=>r!==t),this.observers.length||(C(this,qe)&&(C(this,hr)?C(this,qe).cancel({revert:!0}):C(this,qe).cancelRetry()),this.scheduleGc()),C(this,lt).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||xe(this,ht,Pt).call(this,{type:"invalidate"})}fetch(t,r){var p,u,d;if(this.state.fetchStatus!=="idle"){if(this.state.data!==void 0&&(r!=null&&r.cancelRefetch))this.cancel({silent:!0});else if(C(this,qe))return C(this,qe).continueRetry(),C(this,qe).promise}if(t&&this.setOptions(t),!this.options.queryFn){const f=this.observers.find(y=>y.options.queryFn);f&&this.setOptions(f.options)}process.env.NODE_ENV!=="production"&&(Array.isArray(this.options.queryKey)||console.error("As of v4, queryKey needs to be an Array. If you are using a string like 'repoData', please change it to an Array, e.g. ['repoData']"));const n=new AbortController,i=f=>{Object.defineProperty(f,"signal",{enumerable:!0,get:()=>(re(this,hr,!0),n.signal)})},a=()=>{const f=Zs(this.options,r),S=(()=>{const c={client:C(this,fr),queryKey:this.queryKey,meta:this.meta};return i(c),c})();return re(this,hr,!1),this.options.persister?this.options.persister(f,S,this):f(S)},s=(()=>{const f={fetchOptions:r,options:this.options,queryKey:this.queryKey,client:C(this,fr),state:this.state,fetchFn:a};return i(f),f})();(p=this.options.behavior)==null||p.onFetch(s,this),re(this,dr,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((u=s.fetchOptions)==null?void 0:u.meta))&&xe(this,ht,Pt).call(this,{type:"fetch",meta:(d=s.fetchOptions)==null?void 0:d.meta});const l=f=>{var y,S,c,b;Si(f)&&f.silent||xe(this,ht,Pt).call(this,{type:"error",error:f}),Si(f)||((S=(y=C(this,lt).config).onError)==null||S.call(y,f,this),(b=(c=C(this,lt).config).onSettled)==null||b.call(c,this.state.data,f,this)),this.scheduleGc()};return re(this,qe,el({initialPromise:r==null?void 0:r.initialPromise,fn:s.fetchFn,abort:n.abort.bind(n),onSuccess:f=>{var y,S,c,b;if(f===void 0){process.env.NODE_ENV!=="production"&&console.error(`Query data cannot be undefined. Please make sure to return a value other than undefined from your query function. Affected query key: ${this.queryHash}`),l(new Error(`${this.queryHash} data is undefined`));return}try{this.setData(f)}catch(g){l(g);return}(S=(y=C(this,lt).config).onSuccess)==null||S.call(y,f,this),(b=(c=C(this,lt).config).onSettled)==null||b.call(c,f,this.state.error,this),this.scheduleGc()},onError:l,onFail:(f,y)=>{xe(this,ht,Pt).call(this,{type:"failed",failureCount:f,error:y})},onPause:()=>{xe(this,ht,Pt).call(this,{type:"pause"})},onContinue:()=>{xe(this,ht,Pt).call(this,{type:"continue"})},retry:s.options.retry,retryDelay:s.options.retryDelay,networkMode:s.options.networkMode,canRun:()=>!0})),C(this,qe).start()}},Nr=new WeakMap,dr=new WeakMap,lt=new WeakMap,fr=new WeakMap,qe=new WeakMap,xn=new WeakMap,hr=new WeakMap,ht=new WeakSet,Pt=function(t){const r=n=>{switch(t.type){case"failed":return{...n,fetchFailureCount:t.failureCount,fetchFailureReason:t.error};case"pause":return{...n,fetchStatus:"paused"};case"continue":return{...n,fetchStatus:"fetching"};case"fetch":return{...n,...rl(n.data,this.options),fetchMeta:t.meta??null};case"success":return re(this,dr,void 0),{...n,data:t.data,dataUpdateCount:n.dataUpdateCount+1,dataUpdatedAt:t.dataUpdatedAt??Date.now(),error:null,isInvalidated:!1,status:"success",...!t.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":const i=t.error;return Si(i)&&i.revert&&C(this,dr)?{...C(this,dr),fetchStatus:"idle"}:{...n,error:i,errorUpdateCount:n.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:n.fetchFailureCount+1,fetchFailureReason:i,fetchStatus:"idle",status:"error"};case"invalidate":return{...n,isInvalidated:!0};case"setState":return{...n,...t.state}}};this.state=r(this.state),Le.batch(()=>{this.observers.forEach(n=>{n.onQueryUpdate()}),C(this,lt).notify({query:this,type:"updated",action:t})})},_s);function rl(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:Xs(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function ru(e){const t=typeof e.initialData=="function"?e.initialData():e.initialData,r=t!==void 0,n=r?typeof e.initialDataUpdatedAt=="function"?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:r?n??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:r?"success":"pending",fetchStatus:"idle"}}var Et,As,nu=(As=class extends Cn{constructor(t={}){super();me(this,Et);this.config=t,re(this,Et,new Map)}build(t,r,n){const i=r.queryKey,a=r.queryHash??Ea(i,r);let o=this.get(a);return o||(o=new tu({client:t,queryKey:i,queryHash:a,options:t.defaultQueryOptions(r),state:n,defaultOptions:t.getQueryDefaults(i)}),this.add(o)),o}add(t){C(this,Et).has(t.queryHash)||(C(this,Et).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const r=C(this,Et).get(t.queryHash);r&&(t.destroy(),r===t&&C(this,Et).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){Le.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return C(this,Et).get(t)}getAll(){return[...C(this,Et).values()]}find(t){const r={exact:!0,...t};return this.getAll().find(n=>oo(r,n))}findAll(t={}){const r=this.getAll();return Object.keys(t).length>0?r.filter(n=>oo(t,n)):r}notify(t){Le.batch(()=>{this.listeners.forEach(r=>{r(t)})})}onFocus(){Le.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){Le.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},Et=new WeakMap,As),kt,Ue,mr,Tt,Bt,Rs,iu=(Rs=class extends tl{constructor(t){super();me(this,Tt);me(this,kt);me(this,Ue);me(this,mr);this.mutationId=t.mutationId,re(this,Ue,t.mutationCache),re(this,kt,[]),this.state=t.state||au(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){C(this,kt).includes(t)||(C(this,kt).push(t),this.clearGcTimeout(),C(this,Ue).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){re(this,kt,C(this,kt).filter(r=>r!==t)),this.scheduleGc(),C(this,Ue).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){C(this,kt).length||(this.state.status==="pending"?this.scheduleGc():C(this,Ue).remove(this))}continue(){var t;return((t=C(this,mr))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var a,o,s,l,p,u,d,f,y,S,c,b,g,O,A,k,x,B,_,K;const r=()=>{xe(this,Tt,Bt).call(this,{type:"continue"})};re(this,mr,el({fn:()=>this.options.mutationFn?this.options.mutationFn(t):Promise.reject(new Error("No mutationFn found")),onFail:(W,h)=>{xe(this,Tt,Bt).call(this,{type:"failed",failureCount:W,error:h})},onPause:()=>{xe(this,Tt,Bt).call(this,{type:"pause"})},onContinue:r,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>C(this,Ue).canRun(this)}));const n=this.state.status==="pending",i=!C(this,mr).canStart();try{if(n)r();else{xe(this,Tt,Bt).call(this,{type:"pending",variables:t,isPaused:i}),await((o=(a=C(this,Ue).config).onMutate)==null?void 0:o.call(a,t,this));const h=await((l=(s=this.options).onMutate)==null?void 0:l.call(s,t));h!==this.state.context&&xe(this,Tt,Bt).call(this,{type:"pending",context:h,variables:t,isPaused:i})}const W=await C(this,mr).start();return await((u=(p=C(this,Ue).config).onSuccess)==null?void 0:u.call(p,W,t,this.state.context,this)),await((f=(d=this.options).onSuccess)==null?void 0:f.call(d,W,t,this.state.context)),await((S=(y=C(this,Ue).config).onSettled)==null?void 0:S.call(y,W,null,this.state.variables,this.state.context,this)),await((b=(c=this.options).onSettled)==null?void 0:b.call(c,W,null,t,this.state.context)),xe(this,Tt,Bt).call(this,{type:"success",data:W}),W}catch(W){try{throw await((O=(g=C(this,Ue).config).onError)==null?void 0:O.call(g,W,t,this.state.context,this)),await((k=(A=this.options).onError)==null?void 0:k.call(A,W,t,this.state.context)),await((B=(x=C(this,Ue).config).onSettled)==null?void 0:B.call(x,void 0,W,this.state.variables,this.state.context,this)),await((K=(_=this.options).onSettled)==null?void 0:K.call(_,void 0,W,t,this.state.context)),W}finally{xe(this,Tt,Bt).call(this,{type:"error",error:W})}}finally{C(this,Ue).runNext(this)}}},kt=new WeakMap,Ue=new WeakMap,mr=new WeakMap,Tt=new WeakSet,Bt=function(t){const r=n=>{switch(t.type){case"failed":return{...n,failureCount:t.failureCount,failureReason:t.error};case"pause":return{...n,isPaused:!0};case"continue":return{...n,isPaused:!1};case"pending":return{...n,context:t.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:t.isPaused,status:"pending",variables:t.variables,submittedAt:Date.now()};case"success":return{...n,data:t.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...n,data:void 0,error:t.error,failureCount:n.failureCount+1,failureReason:t.error,isPaused:!1,status:"error"}}};this.state=r(this.state),Le.batch(()=>{C(this,kt).forEach(n=>{n.onMutationUpdate(t)}),C(this,Ue).notify({mutation:this,type:"updated",action:t})})},Rs);function au(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var It,mt,vn,$s,ou=($s=class extends Cn{constructor(t={}){super();me(this,It);me(this,mt);me(this,vn);this.config=t,re(this,It,new Set),re(this,mt,new Map),re(this,vn,0)}build(t,r,n){const i=new iu({mutationCache:this,mutationId:++jn(this,vn)._,options:t.defaultMutationOptions(r),state:n});return this.add(i),i}add(t){C(this,It).add(t);const r=Fn(t);if(typeof r=="string"){const n=C(this,mt).get(r);n?n.push(t):C(this,mt).set(r,[t])}this.notify({type:"added",mutation:t})}remove(t){if(C(this,It).delete(t)){const r=Fn(t);if(typeof r=="string"){const n=C(this,mt).get(r);if(n)if(n.length>1){const i=n.indexOf(t);i!==-1&&n.splice(i,1)}else n[0]===t&&C(this,mt).delete(r)}}this.notify({type:"removed",mutation:t})}canRun(t){const r=Fn(t);if(typeof r=="string"){const n=C(this,mt).get(r),i=n==null?void 0:n.find(a=>a.state.status==="pending");return!i||i===t}else return!0}runNext(t){var n;const r=Fn(t);if(typeof r=="string"){const i=(n=C(this,mt).get(r))==null?void 0:n.find(a=>a!==t&&a.state.isPaused);return(i==null?void 0:i.continue())??Promise.resolve()}else return Promise.resolve()}clear(){Le.batch(()=>{C(this,It).forEach(t=>{this.notify({type:"removed",mutation:t})}),C(this,It).clear(),C(this,mt).clear()})}getAll(){return Array.from(C(this,It))}find(t){const r={exact:!0,...t};return this.getAll().find(n=>so(r,n))}findAll(t={}){return this.getAll().filter(r=>so(t,r))}notify(t){Le.batch(()=>{this.listeners.forEach(r=>{r(t)})})}resumePausedMutations(){const t=this.getAll().filter(r=>r.state.isPaused);return Le.batch(()=>Promise.all(t.map(r=>r.continue().catch(Je))))}},It=new WeakMap,mt=new WeakMap,vn=new WeakMap,$s);function Fn(e){var t;return(t=e.options.scope)==null?void 0:t.id}function uo(e){return{onFetch:(t,r)=>{var u,d,f,y,S;const n=t.options,i=(f=(d=(u=t.fetchOptions)==null?void 0:u.meta)==null?void 0:d.fetchMore)==null?void 0:f.direction,a=((y=t.state.data)==null?void 0:y.pages)||[],o=((S=t.state.data)==null?void 0:S.pageParams)||[];let s={pages:[],pageParams:[]},l=0;const p=async()=>{let c=!1;const b=A=>{Object.defineProperty(A,"signal",{enumerable:!0,get:()=>(t.signal.aborted?c=!0:t.signal.addEventListener("abort",()=>{c=!0}),t.signal)})},g=Zs(t.options,t.fetchOptions),O=async(A,k,x)=>{if(c)return Promise.reject();if(k==null&&A.pages.length)return Promise.resolve(A);const _=(()=>{const M={client:t.client,queryKey:t.queryKey,pageParam:k,direction:x?"backward":"forward",meta:t.options.meta};return b(M),M})(),K=await g(_),{maxPages:W}=t.options,h=x?Qc:Kc;return{pages:h(A.pages,K,W),pageParams:h(A.pageParams,k,W)}};if(i&&a.length){const A=i==="backward",k=A?su:po,x={pages:a,pageParams:o},B=k(n,x);s=await O(x,B,A)}else{const A=e??a.length;do{const k=l===0?o[0]??n.initialPageParam:po(n,s);if(l>0&&k==null)break;s=await O(s,k),l++}while(l<A)}return s};t.options.persister?t.fetchFn=()=>{var c,b;return(b=(c=t.options).persister)==null?void 0:b.call(c,p,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},r)}:t.fetchFn=p}}}function po(e,{pages:t,pageParams:r}){const n=t.length-1;return t.length>0?e.getNextPageParam(t[n],t,r[n],r):void 0}function su(e,{pages:t,pageParams:r}){var n;return t.length>0?(n=e.getPreviousPageParam)==null?void 0:n.call(e,t[0],t,r[0],r):void 0}var Pe,Wt,Ht,Lr,qr,Kt,Ur,Wr,Ds,lu=(Ds=class{constructor(e={}){me(this,Pe);me(this,Wt);me(this,Ht);me(this,Lr);me(this,qr);me(this,Kt);me(this,Ur);me(this,Wr);re(this,Pe,e.queryCache||new nu),re(this,Wt,e.mutationCache||new ou),re(this,Ht,e.defaultOptions||{}),re(this,Lr,new Map),re(this,qr,new Map),re(this,Kt,0)}mount(){jn(this,Kt)._++,C(this,Kt)===1&&(re(this,Ur,ka.subscribe(async e=>{e&&(await this.resumePausedMutations(),C(this,Pe).onFocus())})),re(this,Wr,Gn.subscribe(async e=>{e&&(await this.resumePausedMutations(),C(this,Pe).onOnline())})))}unmount(){var e,t;jn(this,Kt)._--,C(this,Kt)===0&&((e=C(this,Ur))==null||e.call(this),re(this,Ur,void 0),(t=C(this,Wr))==null||t.call(this),re(this,Wr,void 0))}isFetching(e){return C(this,Pe).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return C(this,Wt).findAll({...e,status:"pending"}).length}getQueryData(e){var r;const t=this.defaultQueryOptions({queryKey:e});return(r=C(this,Pe).get(t.queryHash))==null?void 0:r.state.data}ensureQueryData(e){const t=this.defaultQueryOptions(e),r=C(this,Pe).build(this,t),n=r.state.data;return n===void 0?this.fetchQuery(e):(e.revalidateIfStale&&r.isStaleByTime(Xt(t.staleTime,r))&&this.prefetchQuery(t),Promise.resolve(n))}getQueriesData(e){return C(this,Pe).findAll(e).map(({queryKey:t,state:r})=>{const n=r.data;return[t,n]})}setQueryData(e,t,r){const n=this.defaultQueryOptions({queryKey:e}),i=C(this,Pe).get(n.queryHash),a=i==null?void 0:i.state.data,o=Wc(t,a);if(o!==void 0)return C(this,Pe).build(this,n).setData(o,{...r,manual:!0})}setQueriesData(e,t,r){return Le.batch(()=>C(this,Pe).findAll(e).map(({queryKey:n})=>[n,this.setQueryData(n,t,r)]))}getQueryState(e){var r;const t=this.defaultQueryOptions({queryKey:e});return(r=C(this,Pe).get(t.queryHash))==null?void 0:r.state}removeQueries(e){const t=C(this,Pe);Le.batch(()=>{t.findAll(e).forEach(r=>{t.remove(r)})})}resetQueries(e,t){const r=C(this,Pe);return Le.batch(()=>(r.findAll(e).forEach(n=>{n.reset()}),this.refetchQueries({type:"active",...e},t)))}cancelQueries(e,t={}){const r={revert:!0,...t},n=Le.batch(()=>C(this,Pe).findAll(e).map(i=>i.cancel(r)));return Promise.all(n).then(Je).catch(Je)}invalidateQueries(e,t={}){return Le.batch(()=>(C(this,Pe).findAll(e).forEach(r=>{r.invalidate()}),(e==null?void 0:e.refetchType)==="none"?Promise.resolve():this.refetchQueries({...e,type:(e==null?void 0:e.refetchType)??(e==null?void 0:e.type)??"active"},t)))}refetchQueries(e,t={}){const r={...t,cancelRefetch:t.cancelRefetch??!0},n=Le.batch(()=>C(this,Pe).findAll(e).filter(i=>!i.isDisabled()&&!i.isStatic()).map(i=>{let a=i.fetch(void 0,r);return r.throwOnError||(a=a.catch(Je)),i.state.fetchStatus==="paused"?Promise.resolve():a}));return Promise.all(n).then(Je)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const r=C(this,Pe).build(this,t);return r.isStaleByTime(Xt(t.staleTime,r))?r.fetch(t):Promise.resolve(r.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(Je).catch(Je)}fetchInfiniteQuery(e){return e.behavior=uo(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(Je).catch(Je)}ensureInfiniteQueryData(e){return e.behavior=uo(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return Gn.isOnline()?C(this,Wt).resumePausedMutations():Promise.resolve()}getQueryCache(){return C(this,Pe)}getMutationCache(){return C(this,Wt)}getDefaultOptions(){return C(this,Ht)}setDefaultOptions(e){re(this,Ht,e)}setQueryDefaults(e,t){C(this,Lr).set(hn(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...C(this,Lr).values()],r={};return t.forEach(n=>{mn(e,n.queryKey)&&Object.assign(r,n.defaultOptions)}),r}setMutationDefaults(e,t){C(this,qr).set(hn(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...C(this,qr).values()],r={};return t.forEach(n=>{mn(e,n.mutationKey)&&Object.assign(r,n.defaultOptions)}),r}defaultQueryOptions(e){if(e._defaulted)return e;const t={...C(this,Ht).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=Ea(t.queryKey,t)),t.refetchOnReconnect===void 0&&(t.refetchOnReconnect=t.networkMode!=="always"),t.throwOnError===void 0&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode="offlineFirst"),t.queryFn===Yn&&(t.enabled=!1),t}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...C(this,Ht).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){C(this,Pe).clear(),C(this,Wt).clear()}},Pe=new WeakMap,Wt=new WeakMap,Ht=new WeakMap,Lr=new WeakMap,qr=new WeakMap,Kt=new WeakMap,Ur=new WeakMap,Wr=new WeakMap,Ds),Ze,ve,bn,We,gr,Hr,Qt,Yt,wn,Kr,Qr,yr,xr,Gt,Yr,Ce,sn,Wi,Hi,Ki,Qi,Yi,Gi,Zi,nl,Ps,cu=(Ps=class extends Cn{constructor(t,r){super();me(this,Ce);me(this,Ze);me(this,ve);me(this,bn);me(this,We);me(this,gr);me(this,Hr);me(this,Qt);me(this,Yt);me(this,wn);me(this,Kr);me(this,Qr);me(this,yr);me(this,xr);me(this,Gt);me(this,Yr,new Set);this.options=r,re(this,Ze,t),re(this,Yt,null),re(this,Qt,Ui()),this.options.experimental_prefetchInRender||C(this,Qt).reject(new Error("experimental_prefetchInRender feature flag is not enabled")),this.bindMethods(),this.setOptions(r)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(C(this,ve).addObserver(this),fo(C(this,ve),this.options)?xe(this,Ce,sn).call(this):this.updateResult(),xe(this,Ce,Qi).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return Xi(C(this,ve),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return Xi(C(this,ve),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,xe(this,Ce,Yi).call(this),xe(this,Ce,Gi).call(this),C(this,ve).removeObserver(this)}setOptions(t){const r=this.options,n=C(this,ve);if(this.options=C(this,Ze).defaultQueryOptions(t),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof ct(this.options.enabled,C(this,ve))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");xe(this,Ce,Zi).call(this),C(this,ve).setOptions(this.options),r._defaulted&&!Ni(this.options,r)&&C(this,Ze).getQueryCache().notify({type:"observerOptionsUpdated",query:C(this,ve),observer:this});const i=this.hasListeners();i&&ho(C(this,ve),n,this.options,r)&&xe(this,Ce,sn).call(this),this.updateResult(),i&&(C(this,ve)!==n||ct(this.options.enabled,C(this,ve))!==ct(r.enabled,C(this,ve))||Xt(this.options.staleTime,C(this,ve))!==Xt(r.staleTime,C(this,ve)))&&xe(this,Ce,Wi).call(this);const a=xe(this,Ce,Hi).call(this);i&&(C(this,ve)!==n||ct(this.options.enabled,C(this,ve))!==ct(r.enabled,C(this,ve))||a!==C(this,Gt))&&xe(this,Ce,Ki).call(this,a)}getOptimisticResult(t){const r=C(this,Ze).getQueryCache().build(C(this,Ze),t),n=this.createResult(r,t);return pu(this,n)&&(re(this,We,n),re(this,Hr,this.options),re(this,gr,C(this,ve).state)),n}getCurrentResult(){return C(this,We)}trackResult(t,r){return new Proxy(t,{get:(n,i)=>(this.trackProp(i),r==null||r(i),Reflect.get(n,i))})}trackProp(t){C(this,Yr).add(t)}getCurrentQuery(){return C(this,ve)}refetch({...t}={}){return this.fetch({...t})}fetchOptimistic(t){const r=C(this,Ze).defaultQueryOptions(t),n=C(this,Ze).getQueryCache().build(C(this,Ze),r);return n.fetch().then(()=>this.createResult(n,r))}fetch(t){return xe(this,Ce,sn).call(this,{...t,cancelRefetch:t.cancelRefetch??!0}).then(()=>(this.updateResult(),C(this,We)))}createResult(t,r){var W;const n=C(this,ve),i=this.options,a=C(this,We),o=C(this,gr),s=C(this,Hr),p=t!==n?t.state:C(this,bn),{state:u}=t;let d={...u},f=!1,y;if(r._optimisticResults){const h=this.hasListeners(),M=!h&&fo(t,r),P=h&&ho(t,n,r,i);(M||P)&&(d={...d,...rl(u.data,t.options)}),r._optimisticResults==="isRestoring"&&(d.fetchStatus="idle")}let{error:S,errorUpdatedAt:c,status:b}=d;y=d.data;let g=!1;if(r.placeholderData!==void 0&&y===void 0&&b==="pending"){let h;a!=null&&a.isPlaceholderData&&r.placeholderData===(s==null?void 0:s.placeholderData)?(h=a.data,g=!0):h=typeof r.placeholderData=="function"?r.placeholderData((W=C(this,Qr))==null?void 0:W.state.data,C(this,Qr)):r.placeholderData,h!==void 0&&(b="success",y=qi(a==null?void 0:a.data,h,r),f=!0)}if(r.select&&y!==void 0&&!g)if(a&&y===(o==null?void 0:o.data)&&r.select===C(this,wn))y=C(this,Kr);else try{re(this,wn,r.select),y=r.select(y),y=qi(a==null?void 0:a.data,y,r),re(this,Kr,y),re(this,Yt,null)}catch(h){re(this,Yt,h)}C(this,Yt)&&(S=C(this,Yt),y=C(this,Kr),c=Date.now(),b="error");const O=d.fetchStatus==="fetching",A=b==="pending",k=b==="error",x=A&&O,B=y!==void 0,K={status:b,fetchStatus:d.fetchStatus,isPending:A,isSuccess:b==="success",isError:k,isInitialLoading:x,isLoading:x,data:y,dataUpdatedAt:d.dataUpdatedAt,error:S,errorUpdatedAt:c,failureCount:d.fetchFailureCount,failureReason:d.fetchFailureReason,errorUpdateCount:d.errorUpdateCount,isFetched:d.dataUpdateCount>0||d.errorUpdateCount>0,isFetchedAfterMount:d.dataUpdateCount>p.dataUpdateCount||d.errorUpdateCount>p.errorUpdateCount,isFetching:O,isRefetching:O&&!A,isLoadingError:k&&!B,isPaused:d.fetchStatus==="paused",isPlaceholderData:f,isRefetchError:k&&B,isStale:Ta(t,r),refetch:this.refetch,promise:C(this,Qt),isEnabled:ct(r.enabled,t)!==!1};if(this.options.experimental_prefetchInRender){const h=q=>{K.status==="error"?q.reject(K.error):K.data!==void 0&&q.resolve(K.data)},M=()=>{const q=re(this,Qt,K.promise=Ui());h(q)},P=C(this,Qt);switch(P.status){case"pending":t.queryHash===n.queryHash&&h(P);break;case"fulfilled":(K.status==="error"||K.data!==P.value)&&M();break;case"rejected":(K.status!=="error"||K.error!==P.reason)&&M();break}}return K}updateResult(){const t=C(this,We),r=this.createResult(C(this,ve),this.options);if(re(this,gr,C(this,ve).state),re(this,Hr,this.options),C(this,gr).data!==void 0&&re(this,Qr,C(this,ve)),Ni(r,t))return;re(this,We,r);const n=()=>{if(!t)return!0;const{notifyOnChangeProps:i}=this.options,a=typeof i=="function"?i():i;if(a==="all"||!a&&!C(this,Yr).size)return!0;const o=new Set(a??C(this,Yr));return this.options.throwOnError&&o.add("error"),Object.keys(C(this,We)).some(s=>{const l=s;return C(this,We)[l]!==t[l]&&o.has(l)})};xe(this,Ce,nl).call(this,{listeners:n()})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&xe(this,Ce,Qi).call(this)}},Ze=new WeakMap,ve=new WeakMap,bn=new WeakMap,We=new WeakMap,gr=new WeakMap,Hr=new WeakMap,Qt=new WeakMap,Yt=new WeakMap,wn=new WeakMap,Kr=new WeakMap,Qr=new WeakMap,yr=new WeakMap,xr=new WeakMap,Gt=new WeakMap,Yr=new WeakMap,Ce=new WeakSet,sn=function(t){xe(this,Ce,Zi).call(this);let r=C(this,ve).fetch(this.options,t);return t!=null&&t.throwOnError||(r=r.catch(Je)),r},Wi=function(){xe(this,Ce,Yi).call(this);const t=Xt(this.options.staleTime,C(this,ve));if(br||C(this,We).isStale||!Vi(t))return;const n=Gs(C(this,We).dataUpdatedAt,t)+1;re(this,yr,setTimeout(()=>{C(this,We).isStale||this.updateResult()},n))},Hi=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(C(this,ve)):this.options.refetchInterval)??!1},Ki=function(t){xe(this,Ce,Gi).call(this),re(this,Gt,t),!(br||ct(this.options.enabled,C(this,ve))===!1||!Vi(C(this,Gt))||C(this,Gt)===0)&&re(this,xr,setInterval(()=>{(this.options.refetchIntervalInBackground||ka.isFocused())&&xe(this,Ce,sn).call(this)},C(this,Gt)))},Qi=function(){xe(this,Ce,Wi).call(this),xe(this,Ce,Ki).call(this,xe(this,Ce,Hi).call(this))},Yi=function(){C(this,yr)&&(clearTimeout(C(this,yr)),re(this,yr,void 0))},Gi=function(){C(this,xr)&&(clearInterval(C(this,xr)),re(this,xr,void 0))},Zi=function(){const t=C(this,Ze).getQueryCache().build(C(this,Ze),this.options);if(t===C(this,ve))return;const r=C(this,ve);re(this,ve,t),re(this,bn,t.state),this.hasListeners()&&(r==null||r.removeObserver(this),t.addObserver(this))},nl=function(t){Le.batch(()=>{t.listeners&&this.listeners.forEach(r=>{r(C(this,We))}),C(this,Ze).getQueryCache().notify({query:C(this,ve),type:"observerResultsUpdated"})})},Ps);function uu(e,t){return ct(t.enabled,e)!==!1&&e.state.data===void 0&&!(e.state.status==="error"&&t.retryOnMount===!1)}function fo(e,t){return uu(e,t)||e.state.data!==void 0&&Xi(e,t,t.refetchOnMount)}function Xi(e,t,r){if(ct(t.enabled,e)!==!1&&Xt(t.staleTime,e)!=="static"){const n=typeof r=="function"?r(e):r;return n==="always"||n!==!1&&Ta(e,t)}return!1}function ho(e,t,r,n){return(e!==t||ct(n.enabled,e)===!1)&&(!r.suspense||e.state.status!=="error")&&Ta(e,r)}function Ta(e,t){return ct(t.enabled,e)!==!1&&e.isStaleByTime(Xt(t.staleTime,e))}function pu(e,t){return!Ni(e.getCurrentResult(),t)}var il=ne.createContext(void 0),du=e=>{const t=ne.useContext(il);if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},fu=({client:e,children:t})=>(ne.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),m.jsx(il.Provider,{value:e,children:t})),al=ne.createContext(!1),hu=()=>ne.useContext(al);al.Provider;function mu(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}var gu=ne.createContext(mu()),yu=()=>ne.useContext(gu),xu=(e,t)=>{(e.suspense||e.throwOnError||e.experimental_prefetchInRender)&&(t.isReset()||(e.retryOnMount=!1))},vu=e=>{ne.useEffect(()=>{e.clearReset()},[e])},bu=({result:e,errorResetBoundary:t,throwOnError:r,query:n,suspense:i})=>e.isError&&!t.isReset()&&!e.isFetching&&n&&(i&&e.data===void 0||Yc(r,[e.error,n])),wu=e=>{if(e.suspense){const t=n=>n==="static"?n:Math.max(n??1e3,1e3),r=e.staleTime;e.staleTime=typeof r=="function"?(...n)=>t(r(...n)):t(r),typeof e.gcTime=="number"&&(e.gcTime=Math.max(e.gcTime,1e3))}},Su=(e,t)=>e.isLoading&&e.isFetching&&!t,Cu=(e,t)=>(e==null?void 0:e.suspense)&&t.isPending,mo=(e,t,r)=>t.fetchOptimistic(e).catch(()=>{r.clearReset()});function Eu(e,t,r){var d,f,y,S,c;if(process.env.NODE_ENV!=="production"&&(typeof e!="object"||Array.isArray(e)))throw new Error('Bad argument type. Starting with v5, only the "Object" form is allowed when calling query related functions. Please use the error stack to find the culprit call. More info here: https://tanstack.com/query/latest/docs/react/guides/migrating-to-v5#supports-a-single-signature-one-object');const n=hu(),i=yu(),a=du(),o=a.defaultQueryOptions(e);(f=(d=a.getDefaultOptions().queries)==null?void 0:d._experimental_beforeQuery)==null||f.call(d,o),process.env.NODE_ENV!=="production"&&(o.queryFn||console.error(`[${o.queryHash}]: No queryFn was passed as an option, and no default queryFn was found. The queryFn parameter is only optional when using a default queryFn. More info here: https://tanstack.com/query/latest/docs/framework/react/guides/default-query-function`)),o._optimisticResults=n?"isRestoring":"optimistic",wu(o),xu(o,i),vu(i);const s=!a.getQueryCache().get(o.queryHash),[l]=ne.useState(()=>new t(a,o)),p=l.getOptimisticResult(o),u=!n&&e.subscribed!==!1;if(ne.useSyncExternalStore(ne.useCallback(b=>{const g=u?l.subscribe(Le.batchCalls(b)):Je;return l.updateResult(),g},[l,u]),()=>l.getCurrentResult(),()=>l.getCurrentResult()),ne.useEffect(()=>{l.setOptions(o)},[o,l]),Cu(o,p))throw mo(o,l,i);if(bu({result:p,errorResetBoundary:i,throwOnError:o.throwOnError,query:a.getQueryCache().get(o.queryHash),suspense:o.suspense}))throw p.error;if((S=(y=a.getDefaultOptions().queries)==null?void 0:y._experimental_afterQuery)==null||S.call(y,o,p),o.experimental_prefetchInRender&&!br&&Su(p,n)){const b=s?mo(o,l,i):(c=a.getQueryCache().get(o.queryHash))==null?void 0:c.promise;b==null||b.catch(Je).finally(()=>{l.updateResult()})}return o.notifyOnChangeProps?p:l.trackResult(p)}function ku(e,t){return Eu(e,cu)}function Oa(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var _n={exports:{}},An={exports:{}},be={};/** @license React v16.13.1
1
+ "use strict";var vc=Object.defineProperty;var Ya=e=>{throw TypeError(e)};var bc=(e,t,r)=>t in e?vc(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var rn=(e,t,r)=>bc(e,typeof t!="symbol"?t+"":t,r),bi=(e,t,r)=>t.has(e)||Ya("Cannot "+r);var C=(e,t,r)=>(bi(e,t,"read from private field"),r?r.call(e):t.get(e)),ye=(e,t,r)=>t.has(e)?Ya("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,r),ee=(e,t,r,n)=>(bi(e,t,"write to private field"),n?n.call(e,r):t.set(e,r),r),ve=(e,t,r)=>(bi(e,t,"access private method"),r);var jn=(e,t,r,n)=>({set _(i){ee(e,t,i,r)},get _(){return C(e,t,n)}});Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const m=require("react/jsx-runtime"),P=require("react"),E=require("@mui/material"),wc=require("@emotion/styled"),Sr=require("@emotion/react");function Sc(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const r in e)if(r!=="default"){const n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:()=>e[r]})}}return t.default=e,Object.freeze(t)}const te=Sc(P);var Sn=e=>e.type==="checkbox",lr=e=>e instanceof Date,Qe=e=>e==null;const Vs=e=>typeof e=="object";var Me=e=>!Qe(e)&&!Array.isArray(e)&&Vs(e)&&!lr(e),Bs=e=>Me(e)&&e.target?Sn(e.target)?e.target.checked:e.target.value:e,Cc=e=>e.substring(0,e.search(/\.\d+(\.|$)/))||e,Ns=(e,t)=>e.has(Cc(t)),Ec=e=>{const t=e.constructor&&e.constructor.prototype;return Me(t)&&t.hasOwnProperty("isPrototypeOf")},ba=typeof window<"u"&&typeof window.HTMLElement<"u"&&typeof document<"u";function qe(e){let t;const r=Array.isArray(e),n=typeof FileList<"u"?e instanceof FileList:!1;if(e instanceof Date)t=new Date(e);else if(e instanceof Set)t=new Set(e);else if(!(ba&&(e instanceof Blob||n))&&(r||Me(e)))if(t=r?[]:{},!r&&!Ec(e))t=e;else for(const i in e)e.hasOwnProperty(i)&&(t[i]=qe(e[i]));else return e;return t}var ci=e=>/^\w*$/.test(e),Ie=e=>e===void 0,wa=e=>Array.isArray(e)?e.filter(Boolean):[],Sa=e=>wa(e.replace(/["|']|\]/g,"").split(/\.|\[/)),G=(e,t,r)=>{if(!t||!Me(e))return r;const n=(ci(t)?[t]:Sa(t)).reduce((i,a)=>Qe(i)?i:i[a],e);return Ie(n)||n===e?Ie(e[t])?r:e[t]:n},rt=e=>typeof e=="boolean",Ce=(e,t,r)=>{let n=-1;const i=ci(t)?[t]:Sa(t),a=i.length,o=a-1;for(;++n<a;){const s=i[n];let l=r;if(n!==o){const p=e[s];l=Me(p)||Array.isArray(p)?p:isNaN(+i[n+1])?{}:[]}if(s==="__proto__"||s==="constructor"||s==="prototype")return;e[s]=l,e=e[s]}};const Wn={BLUR:"blur",FOCUS_OUT:"focusout",CHANGE:"change"},gt={onBlur:"onBlur",onChange:"onChange",onSubmit:"onSubmit",onTouched:"onTouched",all:"all"},At={max:"max",min:"min",maxLength:"maxLength",minLength:"minLength",pattern:"pattern",required:"required",validate:"validate"},Ls=P.createContext(null);Ls.displayName="HookFormContext";const Ca=()=>P.useContext(Ls);var qs=(e,t,r,n=!0)=>{const i={defaultValues:t._defaultValues};for(const a in e)Object.defineProperty(i,a,{get:()=>{const o=a;return t._proxyFormState[o]!==gt.all&&(t._proxyFormState[o]=!n||gt.all),r&&(r[o]=!0),e[o]}});return i};const Ea=typeof window<"u"?te.useLayoutEffect:te.useEffect;function kc(e){const t=Ca(),{control:r=t.control,disabled:n,name:i,exact:a}=e||{},[o,s]=P.useState(r._formState),l=P.useRef({isDirty:!1,isLoading:!1,dirtyFields:!1,touchedFields:!1,validatingFields:!1,isValidating:!1,isValid:!1,errors:!1});return Ea(()=>r._subscribe({name:i,formState:l.current,exact:a,callback:p=>{!n&&s({...r._formState,...p})}}),[i,n,a]),P.useEffect(()=>{l.current.isValid&&r._setValid(!0)},[r]),P.useMemo(()=>qs(o,r,l.current,!1),[o,r])}var jt=e=>typeof e=="string",Us=(e,t,r,n,i)=>jt(e)?(n&&t.watch.add(e),G(r,e,i)):Array.isArray(e)?e.map(a=>(n&&t.watch.add(a),G(r,a))):(n&&(t.watchAll=!0),r);function Tc(e){const t=Ca(),{control:r=t.control,name:n,defaultValue:i,disabled:a,exact:o}=e||{},s=P.useRef(i),[l,p]=P.useState(r._getWatch(n,s.current));return Ea(()=>r._subscribe({name:n,formState:{values:!0},exact:o,callback:u=>!a&&p(Us(n,r._names,u.values||r._formValues,!1,s.current))}),[n,r,a,o]),P.useEffect(()=>r._removeUnmounted()),l}function Oc(e){const t=Ca(),{name:r,disabled:n,control:i=t.control,shouldUnregister:a}=e,o=Ns(i._names.array,r),s=Tc({control:i,name:r,defaultValue:G(i._formValues,r,G(i._defaultValues,r,e.defaultValue)),exact:!0}),l=kc({control:i,name:r,exact:!0}),p=P.useRef(e),u=P.useRef(i.register(r,{...e.rules,value:s,...rt(e.disabled)?{disabled:e.disabled}:{}})),d=P.useMemo(()=>Object.defineProperties({},{invalid:{enumerable:!0,get:()=>!!G(l.errors,r)},isDirty:{enumerable:!0,get:()=>!!G(l.dirtyFields,r)},isTouched:{enumerable:!0,get:()=>!!G(l.touchedFields,r)},isValidating:{enumerable:!0,get:()=>!!G(l.validatingFields,r)},error:{enumerable:!0,get:()=>G(l.errors,r)}}),[l,r]),f=P.useCallback(b=>u.current.onChange({target:{value:Bs(b),name:r},type:Wn.CHANGE}),[r]),g=P.useCallback(()=>u.current.onBlur({target:{value:G(i._formValues,r),name:r},type:Wn.BLUR}),[r,i._formValues]),S=P.useCallback(b=>{const y=G(i._fields,r);y&&b&&(y._f.ref={focus:()=>b.focus&&b.focus(),select:()=>b.select&&b.select(),setCustomValidity:j=>b.setCustomValidity(j),reportValidity:()=>b.reportValidity()})},[i._fields,r]),c=P.useMemo(()=>({name:r,value:s,...rt(n)||l.disabled?{disabled:l.disabled||n}:{},onChange:f,onBlur:g,ref:S}),[r,n,l.disabled,f,g,S,s]);return P.useEffect(()=>{const b=i._options.shouldUnregister||a;i.register(r,{...p.current.rules,...rt(p.current.disabled)?{disabled:p.current.disabled}:{}});const y=(j,R)=>{const k=G(i._fields,j);k&&k._f&&(k._f.mount=R)};if(y(r,!0),b){const j=qe(G(i._options.defaultValues,r));Ce(i._defaultValues,r,j),Ie(G(i._formValues,r))&&Ce(i._formValues,r,j)}return!o&&i.register(r),()=>{(o?b&&!i._state.action:b)?i.unregister(r):y(r,!1)}},[r,i,o,a]),P.useEffect(()=>{i._setDisabledField({disabled:n,name:r})},[n,r,i]),P.useMemo(()=>({field:c,formState:l,fieldState:d}),[c,l,d])}const ht=e=>e.render(Oc(e));var Ws=(e,t,r,n,i)=>t?{...r[e],types:{...r[e]&&r[e].types?r[e].types:{},[n]:i||!0}}:{},pn=e=>Array.isArray(e)?e:[e],Ga=()=>{let e=[];return{get observers(){return e},next:i=>{for(const a of e)a.next&&a.next(i)},subscribe:i=>(e.push(i),{unsubscribe:()=>{e=e.filter(a=>a!==i)}}),unsubscribe:()=>{e=[]}}},zi=e=>Qe(e)||!Vs(e);function Lt(e,t){if(zi(e)||zi(t))return e===t;if(lr(e)&&lr(t))return e.getTime()===t.getTime();const r=Object.keys(e),n=Object.keys(t);if(r.length!==n.length)return!1;for(const i of r){const a=e[i];if(!n.includes(i))return!1;if(i!=="ref"){const o=t[i];if(lr(a)&&lr(o)||Me(a)&&Me(o)||Array.isArray(a)&&Array.isArray(o)?!Lt(a,o):a!==o)return!1}}return!0}var Xe=e=>Me(e)&&!Object.keys(e).length,ka=e=>e.type==="file",xt=e=>typeof e=="function",Hn=e=>{if(!ba)return!1;const t=e?e.ownerDocument:0;return e instanceof(t&&t.defaultView?t.defaultView.HTMLElement:HTMLElement)},Hs=e=>e.type==="select-multiple",Ta=e=>e.type==="radio",jc=e=>Ta(e)||Sn(e),wi=e=>Hn(e)&&e.isConnected;function Fc(e,t){const r=t.slice(0,-1).length;let n=0;for(;n<r;)e=Ie(e)?n++:e[t[n++]];return e}function Ac(e){for(const t in e)if(e.hasOwnProperty(t)&&!Ie(e[t]))return!1;return!0}function Ne(e,t){const r=Array.isArray(t)?t:ci(t)?[t]:Sa(t),n=r.length===1?e:Fc(e,r),i=r.length-1,a=r[i];return n&&delete n[a],i!==0&&(Me(n)&&Xe(n)||Array.isArray(n)&&Ac(n))&&Ne(e,r.slice(0,-1)),e}var Ks=e=>{for(const t in e)if(xt(e[t]))return!0;return!1};function Kn(e,t={}){const r=Array.isArray(e);if(Me(e)||r)for(const n in e)Array.isArray(e[n])||Me(e[n])&&!Ks(e[n])?(t[n]=Array.isArray(e[n])?[]:{},Kn(e[n],t[n])):Qe(e[n])||(t[n]=!0);return t}function Qs(e,t,r){const n=Array.isArray(e);if(Me(e)||n)for(const i in e)Array.isArray(e[i])||Me(e[i])&&!Ks(e[i])?Ie(t)||zi(r[i])?r[i]=Array.isArray(e[i])?Kn(e[i],[]):{...Kn(e[i])}:Qs(e[i],Qe(t)?{}:t[i],r[i]):r[i]=!Lt(e[i],t[i]);return r}var nn=(e,t)=>Qs(e,t,Kn(t));const Za={value:!1,isValid:!1},Xa={value:!0,isValid:!0};var Ys=e=>{if(Array.isArray(e)){if(e.length>1){const t=e.filter(r=>r&&r.checked&&!r.disabled).map(r=>r.value);return{value:t,isValid:!!t.length}}return e[0].checked&&!e[0].disabled?e[0].attributes&&!Ie(e[0].attributes.value)?Ie(e[0].value)||e[0].value===""?Xa:{value:e[0].value,isValid:!0}:Xa:Za}return Za},Gs=(e,{valueAsNumber:t,valueAsDate:r,setValueAs:n})=>Ie(e)?e:t?e===""?NaN:e&&+e:r&&jt(e)?new Date(e):n?n(e):e;const Ja={isValid:!1,value:null};var Zs=e=>Array.isArray(e)?e.reduce((t,r)=>r&&r.checked&&!r.disabled?{isValid:!0,value:r.value}:t,Ja):Ja;function eo(e){const t=e.ref;return ka(t)?t.files:Ta(t)?Zs(e.refs).value:Hs(t)?[...t.selectedOptions].map(({value:r})=>r):Sn(t)?Ys(e.refs).value:Gs(Ie(t.value)?e.ref.value:t.value,e)}var _c=(e,t,r,n)=>{const i={};for(const a of e){const o=G(t,a);o&&Ce(i,a,o._f)}return{criteriaMode:r,names:[...e],fields:i,shouldUseNativeValidation:n}},Qn=e=>e instanceof RegExp,an=e=>Ie(e)?e:Qn(e)?e.source:Me(e)?Qn(e.value)?e.value.source:e.value:e,to=e=>({isOnSubmit:!e||e===gt.onSubmit,isOnBlur:e===gt.onBlur,isOnChange:e===gt.onChange,isOnAll:e===gt.all,isOnTouch:e===gt.onTouched});const ro="AsyncFunction";var Rc=e=>!!e&&!!e.validate&&!!(xt(e.validate)&&e.validate.constructor.name===ro||Me(e.validate)&&Object.values(e.validate).find(t=>t.constructor.name===ro)),$c=e=>e.mount&&(e.required||e.min||e.max||e.maxLength||e.minLength||e.pattern||e.validate),no=(e,t,r)=>!r&&(t.watchAll||t.watch.has(e)||[...t.watch].some(n=>e.startsWith(n)&&/^\.\w+/.test(e.slice(n.length))));const dn=(e,t,r,n)=>{for(const i of r||Object.keys(e)){const a=G(e,i);if(a){const{_f:o,...s}=a;if(o){if(o.refs&&o.refs[0]&&t(o.refs[0],i)&&!n)return!0;if(o.ref&&t(o.ref,o.name)&&!n)return!0;if(dn(s,t))break}else if(Me(s)&&dn(s,t))break}}};function io(e,t,r){const n=G(e,r);if(n||ci(r))return{error:n,name:r};const i=r.split(".");for(;i.length;){const a=i.join("."),o=G(t,a),s=G(e,a);if(o&&!Array.isArray(o)&&r!==a)return{name:r};if(s&&s.type)return{name:a,error:s};if(s&&s.root&&s.root.type)return{name:`${a}.root`,error:s.root};i.pop()}return{name:r}}var Dc=(e,t,r,n)=>{r(e);const{name:i,...a}=e;return Xe(a)||Object.keys(a).length>=Object.keys(t).length||Object.keys(a).find(o=>t[o]===(!n||gt.all))},Pc=(e,t,r)=>!e||!t||e===t||pn(e).some(n=>n&&(r?n===t:n.startsWith(t)||t.startsWith(n))),Ic=(e,t,r,n,i)=>i.isOnAll?!1:!r&&i.isOnTouch?!(t||e):(r?n.isOnBlur:i.isOnBlur)?!e:(r?n.isOnChange:i.isOnChange)?e:!0,Mc=(e,t)=>!wa(G(e,t)).length&&Ne(e,t),zc=(e,t,r)=>{const n=pn(G(e,r));return Ce(n,"root",t[r]),Ce(e,r,n),e},Vn=e=>jt(e);function ao(e,t,r="validate"){if(Vn(e)||Array.isArray(e)&&e.every(Vn)||rt(e)&&!e)return{type:r,message:Vn(e)?e:"",ref:t}}var Fr=e=>Me(e)&&!Qn(e)?e:{value:e,message:""},oo=async(e,t,r,n,i,a)=>{const{ref:o,refs:s,required:l,maxLength:p,minLength:u,min:d,max:f,pattern:g,validate:S,name:c,valueAsNumber:b,mount:y}=e._f,j=G(r,c);if(!y||t.has(c))return{};const R=s?s[0]:o,k=M=>{i&&R.reportValidity&&(R.setCustomValidity(rt(M)?"":M||""),R.reportValidity())},v={},B=Ta(o),A=Sn(o),H=B||A,U=(b||ka(o))&&Ie(o.value)&&Ie(j)||Hn(o)&&o.value===""||j===""||Array.isArray(j)&&!j.length,h=Ws.bind(null,c,n,v),z=(M,q,N,J=At.maxLength,ae=At.minLength)=>{const he=M?q:N;v[c]={type:M?J:ae,message:he,ref:o,...h(M?J:ae,he)}};if(a?!Array.isArray(j)||!j.length:l&&(!H&&(U||Qe(j))||rt(j)&&!j||A&&!Ys(s).isValid||B&&!Zs(s).isValid)){const{value:M,message:q}=Vn(l)?{value:!!l,message:l}:Fr(l);if(M&&(v[c]={type:At.required,message:q,ref:R,...h(At.required,q)},!n))return k(q),v}if(!U&&(!Qe(d)||!Qe(f))){let M,q;const N=Fr(f),J=Fr(d);if(!Qe(j)&&!isNaN(j)){const ae=o.valueAsNumber||j&&+j;Qe(N.value)||(M=ae>N.value),Qe(J.value)||(q=ae<J.value)}else{const ae=o.valueAsDate||new Date(j),he=V=>new Date(new Date().toDateString()+" "+V),ie=o.type=="time",oe=o.type=="week";jt(N.value)&&j&&(M=ie?he(j)>he(N.value):oe?j>N.value:ae>new Date(N.value)),jt(J.value)&&j&&(q=ie?he(j)<he(J.value):oe?j<J.value:ae<new Date(J.value))}if((M||q)&&(z(!!M,N.message,J.message,At.max,At.min),!n))return k(v[c].message),v}if((p||u)&&!U&&(jt(j)||a&&Array.isArray(j))){const M=Fr(p),q=Fr(u),N=!Qe(M.value)&&j.length>+M.value,J=!Qe(q.value)&&j.length<+q.value;if((N||J)&&(z(N,M.message,q.message),!n))return k(v[c].message),v}if(g&&!U&&jt(j)){const{value:M,message:q}=Fr(g);if(Qn(M)&&!j.match(M)&&(v[c]={type:At.pattern,message:q,ref:o,...h(At.pattern,q)},!n))return k(q),v}if(S){if(xt(S)){const M=await S(j,r),q=ao(M,R);if(q&&(v[c]={...q,...h(At.validate,q.message)},!n))return k(q.message),v}else if(Me(S)){let M={};for(const q in S){if(!Xe(M)&&!n)break;const N=ao(await S[q](j,r),R,q);N&&(M={...N,...h(q,N.message)},k(N.message),n&&(v[c]=M))}if(!Xe(M)&&(v[c]={ref:R,...M},!n))return v}}return k(!0),v};const Vc={mode:gt.onSubmit,reValidateMode:gt.onChange,shouldFocusError:!0};function Bc(e={}){let t={...Vc,...e},r={submitCount:0,isDirty:!1,isReady:!1,isLoading:xt(t.defaultValues),isValidating:!1,isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,touchedFields:{},dirtyFields:{},validatingFields:{},errors:t.errors||{},disabled:t.disabled||!1};const n={};let i=Me(t.defaultValues)||Me(t.values)?qe(t.defaultValues||t.values)||{}:{},a=t.shouldUnregister?{}:qe(i),o={action:!1,mount:!1,watch:!1},s={mount:new Set,disabled:new Set,unMount:new Set,array:new Set,watch:new Set},l,p=0;const u={isDirty:!1,dirtyFields:!1,validatingFields:!1,touchedFields:!1,isValidating:!1,isValid:!1,errors:!1};let d={...u};const f={array:Ga(),state:Ga()},g=t.criteriaMode===gt.all,S=x=>O=>{clearTimeout(p),p=setTimeout(x,O)},c=async x=>{if(!t.disabled&&(u.isValid||d.isValid||x)){const O=t.resolver?Xe((await A()).errors):await U(n,!0);O!==r.isValid&&f.state.next({isValid:O})}},b=(x,O)=>{!t.disabled&&(u.isValidating||u.validatingFields||d.isValidating||d.validatingFields)&&((x||Array.from(s.mount)).forEach(T=>{T&&(O?Ce(r.validatingFields,T,O):Ne(r.validatingFields,T))}),f.state.next({validatingFields:r.validatingFields,isValidating:!Xe(r.validatingFields)}))},y=(x,O=[],T,Z,F=!0,$=!0)=>{if(Z&&T&&!t.disabled){if(o.action=!0,$&&Array.isArray(G(n,x))){const Y=T(G(n,x),Z.argA,Z.argB);F&&Ce(n,x,Y)}if($&&Array.isArray(G(r.errors,x))){const Y=T(G(r.errors,x),Z.argA,Z.argB);F&&Ce(r.errors,x,Y),Mc(r.errors,x)}if((u.touchedFields||d.touchedFields)&&$&&Array.isArray(G(r.touchedFields,x))){const Y=T(G(r.touchedFields,x),Z.argA,Z.argB);F&&Ce(r.touchedFields,x,Y)}(u.dirtyFields||d.dirtyFields)&&(r.dirtyFields=nn(i,a)),f.state.next({name:x,isDirty:z(x,O),dirtyFields:r.dirtyFields,errors:r.errors,isValid:r.isValid})}else Ce(a,x,O)},j=(x,O)=>{Ce(r.errors,x,O),f.state.next({errors:r.errors})},R=x=>{r.errors=x,f.state.next({errors:r.errors,isValid:!1})},k=(x,O,T,Z)=>{const F=G(n,x);if(F){const $=G(a,x,Ie(T)?G(i,x):T);Ie($)||Z&&Z.defaultChecked||O?Ce(a,x,O?$:eo(F._f)):N(x,$),o.mount&&c()}},v=(x,O,T,Z,F)=>{let $=!1,Y=!1;const le={name:x};if(!t.disabled){if(!T||Z){(u.isDirty||d.isDirty)&&(Y=r.isDirty,r.isDirty=le.isDirty=z(),$=Y!==le.isDirty);const ge=Lt(G(i,x),O);Y=!!G(r.dirtyFields,x),ge?Ne(r.dirtyFields,x):Ce(r.dirtyFields,x,!0),le.dirtyFields=r.dirtyFields,$=$||(u.dirtyFields||d.dirtyFields)&&Y!==!ge}if(T){const ge=G(r.touchedFields,x);ge||(Ce(r.touchedFields,x,T),le.touchedFields=r.touchedFields,$=$||(u.touchedFields||d.touchedFields)&&ge!==T)}$&&F&&f.state.next(le)}return $?le:{}},B=(x,O,T,Z)=>{const F=G(r.errors,x),$=(u.isValid||d.isValid)&&rt(O)&&r.isValid!==O;if(t.delayError&&T?(l=S(()=>j(x,T)),l(t.delayError)):(clearTimeout(p),l=null,T?Ce(r.errors,x,T):Ne(r.errors,x)),(T?!Lt(F,T):F)||!Xe(Z)||$){const Y={...Z,...$&&rt(O)?{isValid:O}:{},errors:r.errors,name:x};r={...r,...Y},f.state.next(Y)}},A=async x=>{b(x,!0);const O=await t.resolver(a,t.context,_c(x||s.mount,n,t.criteriaMode,t.shouldUseNativeValidation));return b(x),O},H=async x=>{const{errors:O}=await A(x);if(x)for(const T of x){const Z=G(O,T);Z?Ce(r.errors,T,Z):Ne(r.errors,T)}else r.errors=O;return O},U=async(x,O,T={valid:!0})=>{for(const Z in x){const F=x[Z];if(F){const{_f:$,...Y}=F;if($){const le=s.array.has($.name),ge=F._f&&Rc(F._f);ge&&u.validatingFields&&b([Z],!0);const Ve=await oo(F,s.disabled,a,g,t.shouldUseNativeValidation&&!O,le);if(ge&&u.validatingFields&&b([Z]),Ve[$.name]&&(T.valid=!1,O))break;!O&&(G(Ve,$.name)?le?zc(r.errors,Ve,$.name):Ce(r.errors,$.name,Ve[$.name]):Ne(r.errors,$.name))}!Xe(Y)&&await U(Y,O,T)}}return T.valid},h=()=>{for(const x of s.unMount){const O=G(n,x);O&&(O._f.refs?O._f.refs.every(T=>!wi(T)):!wi(O._f.ref))&&ne(x)}s.unMount=new Set},z=(x,O)=>!t.disabled&&(x&&O&&Ce(a,x,O),!Lt(V(),i)),M=(x,O,T)=>Us(x,s,{...o.mount?a:Ie(O)?i:jt(x)?{[x]:O}:O},T,O),q=x=>wa(G(o.mount?a:i,x,t.shouldUnregister?G(i,x,[]):[])),N=(x,O,T={})=>{const Z=G(n,x);let F=O;if(Z){const $=Z._f;$&&(!$.disabled&&Ce(a,x,Gs(O,$)),F=Hn($.ref)&&Qe(O)?"":O,Hs($.ref)?[...$.ref.options].forEach(Y=>Y.selected=F.includes(Y.value)):$.refs?Sn($.ref)?$.refs.forEach(Y=>{(!Y.defaultChecked||!Y.disabled)&&(Array.isArray(F)?Y.checked=!!F.find(le=>le===Y.value):Y.checked=F===Y.value||!!F)}):$.refs.forEach(Y=>Y.checked=Y.value===F):ka($.ref)?$.ref.value="":($.ref.value=F,$.ref.type||f.state.next({name:x,values:qe(a)})))}(T.shouldDirty||T.shouldTouch)&&v(x,F,T.shouldTouch,T.shouldDirty,!0),T.shouldValidate&&oe(x)},J=(x,O,T)=>{for(const Z in O){if(!O.hasOwnProperty(Z))return;const F=O[Z],$=x+"."+Z,Y=G(n,$);(s.array.has(x)||Me(F)||Y&&!Y._f)&&!lr(F)?J($,F,T):N($,F,T)}},ae=(x,O,T={})=>{const Z=G(n,x),F=s.array.has(x),$=qe(O);Ce(a,x,$),F?(f.array.next({name:x,values:qe(a)}),(u.isDirty||u.dirtyFields||d.isDirty||d.dirtyFields)&&T.shouldDirty&&f.state.next({name:x,dirtyFields:nn(i,a),isDirty:z(x,$)})):Z&&!Z._f&&!Qe($)?J(x,$,T):N(x,$,T),no(x,s)&&f.state.next({...r}),f.state.next({name:o.mount?x:void 0,values:qe(a)})},he=async x=>{o.mount=!0;const O=x.target;let T=O.name,Z=!0;const F=G(n,T),$=ge=>{Z=Number.isNaN(ge)||lr(ge)&&isNaN(ge.getTime())||Lt(ge,G(a,T,ge))},Y=to(t.mode),le=to(t.reValidateMode);if(F){let ge,Ve;const ft=O.type?eo(F._f):Bs(x),st=x.type===Wn.BLUR||x.type===Wn.FOCUS_OUT,Jr=!$c(F._f)&&!t.resolver&&!G(r.errors,T)&&!F._f.deps||Ic(st,G(r.touchedFields,T),r.isSubmitted,le,Y),ir=no(T,s,st);Ce(a,T,ft),st?(F._f.onBlur&&F._f.onBlur(x),l&&l(0)):F._f.onChange&&F._f.onChange(x);const zt=v(T,ft,st),en=!Xe(zt)||ir;if(!st&&f.state.next({name:T,type:x.type,values:qe(a)}),Jr)return(u.isValid||d.isValid)&&(t.mode==="onBlur"?st&&c():st||c()),en&&f.state.next({name:T,...ir?{}:zt});if(!st&&ir&&f.state.next({...r}),t.resolver){const{errors:Or}=await A([T]);if($(ft),Z){const tn=io(r.errors,n,T),jr=io(Or,n,tn.name||T);ge=jr.error,T=jr.name,Ve=Xe(Or)}}else b([T],!0),ge=(await oo(F,s.disabled,a,g,t.shouldUseNativeValidation))[T],b([T]),$(ft),Z&&(ge?Ve=!1:(u.isValid||d.isValid)&&(Ve=await U(n,!0)));Z&&(F._f.deps&&oe(F._f.deps),B(T,Ve,ge,zt))}},ie=(x,O)=>{if(G(r.errors,O)&&x.focus)return x.focus(),1},oe=async(x,O={})=>{let T,Z;const F=pn(x);if(t.resolver){const $=await H(Ie(x)?x:F);T=Xe($),Z=x?!F.some(Y=>G($,Y)):T}else x?(Z=(await Promise.all(F.map(async $=>{const Y=G(n,$);return await U(Y&&Y._f?{[$]:Y}:Y)}))).every(Boolean),!(!Z&&!r.isValid)&&c()):Z=T=await U(n);return f.state.next({...!jt(x)||(u.isValid||d.isValid)&&T!==r.isValid?{}:{name:x},...t.resolver||!x?{isValid:T}:{},errors:r.errors}),O.shouldFocus&&!Z&&dn(n,ie,x?F:s.mount),Z},V=x=>{const O={...o.mount?a:i};return Ie(x)?O:jt(x)?G(O,x):x.map(T=>G(O,T))},W=(x,O)=>({invalid:!!G((O||r).errors,x),isDirty:!!G((O||r).dirtyFields,x),error:G((O||r).errors,x),isValidating:!!G(r.validatingFields,x),isTouched:!!G((O||r).touchedFields,x)}),ce=x=>{x&&pn(x).forEach(O=>Ne(r.errors,O)),f.state.next({errors:x?r.errors:{}})},me=(x,O,T)=>{const Z=(G(n,x,{_f:{}})._f||{}).ref,F=G(r.errors,x)||{},{ref:$,message:Y,type:le,...ge}=F;Ce(r.errors,x,{...ge,...O,ref:Z}),f.state.next({name:x,errors:r.errors,isValid:!1}),T&&T.shouldFocus&&Z&&Z.focus&&Z.focus()},se=(x,O)=>xt(x)?f.state.subscribe({next:T=>x(M(void 0,O),T)}):M(x,O,!0),L=x=>f.state.subscribe({next:O=>{Pc(x.name,O.name,x.exact)&&Dc(O,x.formState||u,Le,x.reRenderRoot)&&x.callback({values:{...a},...r,...O})}}).unsubscribe,X=x=>(o.mount=!0,d={...d,...x.formState},L({...x,formState:d})),ne=(x,O={})=>{for(const T of x?pn(x):s.mount)s.mount.delete(T),s.array.delete(T),O.keepValue||(Ne(n,T),Ne(a,T)),!O.keepError&&Ne(r.errors,T),!O.keepDirty&&Ne(r.dirtyFields,T),!O.keepTouched&&Ne(r.touchedFields,T),!O.keepIsValidating&&Ne(r.validatingFields,T),!t.shouldUnregister&&!O.keepDefaultValue&&Ne(i,T);f.state.next({values:qe(a)}),f.state.next({...r,...O.keepDirty?{isDirty:z()}:{}}),!O.keepIsValid&&c()},ue=({disabled:x,name:O})=>{(rt(x)&&o.mount||x||s.disabled.has(O))&&(x?s.disabled.add(O):s.disabled.delete(O))},de=(x,O={})=>{let T=G(n,x);const Z=rt(O.disabled)||rt(t.disabled);return Ce(n,x,{...T||{},_f:{...T&&T._f?T._f:{ref:{name:x}},name:x,mount:!0,...O}}),s.mount.add(x),T?ue({disabled:rt(O.disabled)?O.disabled:t.disabled,name:x}):k(x,!0,O.value),{...Z?{disabled:O.disabled||t.disabled}:{},...t.progressive?{required:!!O.required,min:an(O.min),max:an(O.max),minLength:an(O.minLength),maxLength:an(O.maxLength),pattern:an(O.pattern)}:{},name:x,onChange:he,onBlur:he,ref:F=>{if(F){de(x,O),T=G(n,x);const $=Ie(F.value)&&F.querySelectorAll&&F.querySelectorAll("input,select,textarea")[0]||F,Y=jc($),le=T._f.refs||[];if(Y?le.find(ge=>ge===$):$===T._f.ref)return;Ce(n,x,{_f:{...T._f,...Y?{refs:[...le.filter(wi),$,...Array.isArray(G(i,x))?[{}]:[]],ref:{type:$.type,name:x}}:{ref:$}}}),k(x,!1,void 0,$)}else T=G(n,x,{}),T._f&&(T._f.mount=!1),(t.shouldUnregister||O.shouldUnregister)&&!(Ns(s.array,x)&&o.action)&&s.unMount.add(x)}}},pe=()=>t.shouldFocusError&&dn(n,ie,s.mount),D=x=>{rt(x)&&(f.state.next({disabled:x}),dn(n,(O,T)=>{const Z=G(n,T);Z&&(O.disabled=Z._f.disabled||x,Array.isArray(Z._f.refs)&&Z._f.refs.forEach(F=>{F.disabled=Z._f.disabled||x}))},0,!1))},_=(x,O)=>async T=>{let Z;T&&(T.preventDefault&&T.preventDefault(),T.persist&&T.persist());let F=qe(a);if(f.state.next({isSubmitting:!0}),t.resolver){const{errors:$,values:Y}=await A();r.errors=$,F=Y}else await U(n);if(s.disabled.size)for(const $ of s.disabled)Ce(F,$,void 0);if(Ne(r.errors,"root"),Xe(r.errors)){f.state.next({errors:{}});try{await x(F,T)}catch($){Z=$}}else O&&await O({...r.errors},T),pe(),setTimeout(pe);if(f.state.next({isSubmitted:!0,isSubmitting:!1,isSubmitSuccessful:Xe(r.errors)&&!Z,submitCount:r.submitCount+1,errors:r.errors}),Z)throw Z},Q=(x,O={})=>{G(n,x)&&(Ie(O.defaultValue)?ae(x,qe(G(i,x))):(ae(x,O.defaultValue),Ce(i,x,qe(O.defaultValue))),O.keepTouched||Ne(r.touchedFields,x),O.keepDirty||(Ne(r.dirtyFields,x),r.isDirty=O.defaultValue?z(x,qe(G(i,x))):z()),O.keepError||(Ne(r.errors,x),u.isValid&&c()),f.state.next({...r}))},fe=(x,O={})=>{const T=x?qe(x):i,Z=qe(T),F=Xe(x),$=F?i:Z;if(O.keepDefaultValues||(i=T),!O.keepValues){if(O.keepDirtyValues){const Y=new Set([...s.mount,...Object.keys(nn(i,a))]);for(const le of Array.from(Y))G(r.dirtyFields,le)?Ce($,le,G(a,le)):ae(le,G($,le))}else{if(ba&&Ie(x))for(const Y of s.mount){const le=G(n,Y);if(le&&le._f){const ge=Array.isArray(le._f.refs)?le._f.refs[0]:le._f.ref;if(Hn(ge)){const Ve=ge.closest("form");if(Ve){Ve.reset();break}}}}for(const Y of s.mount)ae(Y,G($,Y))}a=qe($),f.array.next({values:{...$}}),f.state.next({values:{...$}})}s={mount:O.keepDirtyValues?s.mount:new Set,unMount:new Set,array:new Set,disabled:new Set,watch:new Set,watchAll:!1,focus:""},o.mount=!u.isValid||!!O.keepIsValid||!!O.keepDirtyValues,o.watch=!!t.shouldUnregister,f.state.next({submitCount:O.keepSubmitCount?r.submitCount:0,isDirty:F?!1:O.keepDirty?r.isDirty:!!(O.keepDefaultValues&&!Lt(x,i)),isSubmitted:O.keepIsSubmitted?r.isSubmitted:!1,dirtyFields:F?{}:O.keepDirtyValues?O.keepDefaultValues&&a?nn(i,a):r.dirtyFields:O.keepDefaultValues&&x?nn(i,x):O.keepDirty?r.dirtyFields:{},touchedFields:O.keepTouched?r.touchedFields:{},errors:O.keepErrors?r.errors:{},isSubmitSuccessful:O.keepIsSubmitSuccessful?r.isSubmitSuccessful:!1,isSubmitting:!1})},xe=(x,O)=>fe(xt(x)?x(a):x,O),Be=(x,O={})=>{const T=G(n,x),Z=T&&T._f;if(Z){const F=Z.refs?Z.refs[0]:Z.ref;F.focus&&(F.focus(),O.shouldSelect&&xt(F.select)&&F.select())}},Le=x=>{r={...r,...x}},Oe={control:{register:de,unregister:ne,getFieldState:W,handleSubmit:_,setError:me,_subscribe:L,_runSchema:A,_focusError:pe,_getWatch:M,_getDirty:z,_setValid:c,_setFieldArray:y,_setDisabledField:ue,_setErrors:R,_getFieldArray:q,_reset:fe,_resetDefaultValues:()=>xt(t.defaultValues)&&t.defaultValues().then(x=>{xe(x,t.resetOptions),f.state.next({isLoading:!1})}),_removeUnmounted:h,_disableForm:D,_subjects:f,_proxyFormState:u,get _fields(){return n},get _formValues(){return a},get _state(){return o},set _state(x){o=x},get _defaultValues(){return i},get _names(){return s},set _names(x){s=x},get _formState(){return r},get _options(){return t},set _options(x){t={...t,...x}}},subscribe:X,trigger:oe,register:de,handleSubmit:_,watch:se,setValue:ae,getValues:V,reset:xe,resetField:Q,clearErrors:ce,unregister:ne,setError:me,setFocus:Be,getFieldState:W};return{...Oe,formControl:Oe}}function Nc(e={}){const t=P.useRef(void 0),r=P.useRef(void 0),[n,i]=P.useState({isDirty:!1,isValidating:!1,isLoading:xt(e.defaultValues),isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,submitCount:0,dirtyFields:{},touchedFields:{},validatingFields:{},errors:e.errors||{},disabled:e.disabled||!1,isReady:!1,defaultValues:xt(e.defaultValues)?void 0:e.defaultValues});if(!t.current)if(e.formControl)t.current={...e.formControl,formState:n},e.defaultValues&&!xt(e.defaultValues)&&e.formControl.reset(e.defaultValues,e.resetOptions);else{const{formControl:o,...s}=Bc(e);t.current={...s,formState:n}}const a=t.current.control;return a._options=e,Ea(()=>{const o=a._subscribe({formState:a._proxyFormState,callback:()=>i({...a._formState}),reRenderRoot:!0});return i(s=>({...s,isReady:!0})),a._formState.isReady=!0,o},[a]),P.useEffect(()=>a._disableForm(e.disabled),[a,e.disabled]),P.useEffect(()=>{e.mode&&(a._options.mode=e.mode),e.reValidateMode&&(a._options.reValidateMode=e.reValidateMode)},[a,e.mode,e.reValidateMode]),P.useEffect(()=>{e.errors&&(a._setErrors(e.errors),a._focusError())},[a,e.errors]),P.useEffect(()=>{e.shouldUnregister&&a._subjects.state.next({values:a._getWatch()})},[a,e.shouldUnregister]),P.useEffect(()=>{if(a._proxyFormState.isDirty){const o=a._getDirty();o!==n.isDirty&&a._subjects.state.next({isDirty:o})}},[a,n.isDirty]),P.useEffect(()=>{e.values&&!Lt(e.values,r.current)?(a._reset(e.values,a._options.resetOptions),r.current=e.values,i(o=>({...o}))):a._resetDefaultValues()},[a,e.values]),P.useEffect(()=>{a._state.mount||(a._setValid(),a._state.mount=!0),a._state.watch&&(a._state.watch=!1,a._subjects.state.next({...a._formState})),a._removeUnmounted()}),t.current.formState=qs(n,a),t.current}const so=(e,t,r)=>{if(e&&"reportValidity"in e){const n=G(r,t);e.setCustomValidity(n&&n.message||""),e.reportValidity()}},Xs=(e,t)=>{for(const r in t.fields){const n=t.fields[r];n&&n.ref&&"reportValidity"in n.ref?so(n.ref,r,e):n&&n.refs&&n.refs.forEach(i=>so(i,r,e))}},Lc=(e,t)=>{t.shouldUseNativeValidation&&Xs(e,t);const r={};for(const n in e){const i=G(t.fields,n),a=Object.assign(e[n]||{},{ref:i&&i.ref});if(qc(t.names||Object.keys(e),n)){const o=Object.assign({},G(r,n));Ce(o,"root",a),Ce(r,n,o)}else Ce(r,n,a)}return r},qc=(e,t)=>{const r=lo(t);return e.some(n=>lo(n).match(`^${r}\\.\\d+`))};function lo(e){return e.replace(/\]|\[/g,"")}function Uc(e,t,r){return r===void 0&&(r={}),function(n,i,a){try{return Promise.resolve(function(o,s){try{var l=(t!=null&&t.context&&process.env.NODE_ENV==="development"&&console.warn("You should not used the yup options context. Please, use the 'useForm' context object instead"),Promise.resolve(e[r.mode==="sync"?"validateSync":"validate"](n,Object.assign({abortEarly:!1},t,{context:i}))).then(function(p){return a.shouldUseNativeValidation&&Xs({},a),{values:r.raw?Object.assign({},n):p,errors:{}}}))}catch(p){return s(p)}return l&&l.then?l.then(void 0,s):l}(0,function(o){if(!o.inner)throw o;return{values:{},errors:Lc((s=o,l=!a.shouldUseNativeValidation&&a.criteriaMode==="all",(s.inner||[]).reduce(function(p,u){if(p[u.path]||(p[u.path]={message:u.message,type:u.type}),l){var d=p[u.path].types,f=d&&d[u.type];p[u.path]=Ws(u.path,l,p,u.type,f?[].concat(f,u.message):u.message)}return p},{})),a)};var s,l}))}catch(o){return Promise.reject(o)}}}var Cn=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},br=typeof window>"u"||"Deno"in globalThis;function Je(){}function Wc(e,t){return typeof e=="function"?e(t):e}function Vi(e){return typeof e=="number"&&e>=0&&e!==1/0}function Js(e,t){return Math.max(e+(t||0)-Date.now(),0)}function Xt(e,t){return typeof e=="function"?e(t):e}function ct(e,t){return typeof e=="function"?e(t):e}function co(e,t){const{type:r="all",exact:n,fetchStatus:i,predicate:a,queryKey:o,stale:s}=e;if(o){if(n){if(t.queryHash!==Oa(o,t.options))return!1}else if(!mn(t.queryKey,o))return!1}if(r!=="all"){const l=t.isActive();if(r==="active"&&!l||r==="inactive"&&l)return!1}return!(typeof s=="boolean"&&t.isStale()!==s||i&&i!==t.state.fetchStatus||a&&!a(t))}function uo(e,t){const{exact:r,status:n,predicate:i,mutationKey:a}=e;if(a){if(!t.options.mutationKey)return!1;if(r){if(hn(t.options.mutationKey)!==hn(a))return!1}else if(!mn(t.options.mutationKey,a))return!1}return!(n&&t.state.status!==n||i&&!i(t))}function Oa(e,t){return((t==null?void 0:t.queryKeyHashFn)||hn)(e)}function hn(e){return JSON.stringify(e,(t,r)=>Li(r)?Object.keys(r).sort().reduce((n,i)=>(n[i]=r[i],n),{}):r)}function mn(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?Object.keys(t).every(r=>mn(e[r],t[r])):!1}function Bi(e,t){if(e===t)return e;const r=po(e)&&po(t);if(r||Li(e)&&Li(t)){const n=r?e:Object.keys(e),i=n.length,a=r?t:Object.keys(t),o=a.length,s=r?[]:{},l=new Set(n);let p=0;for(let u=0;u<o;u++){const d=r?u:a[u];(!r&&l.has(d)||r)&&e[d]===void 0&&t[d]===void 0?(s[d]=void 0,p++):(s[d]=Bi(e[d],t[d]),s[d]===e[d]&&e[d]!==void 0&&p++)}return i===o&&p===i?e:s}return t}function Ni(e,t){if(!t||Object.keys(e).length!==Object.keys(t).length)return!1;for(const r in e)if(e[r]!==t[r])return!1;return!0}function po(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function Li(e){if(!fo(e))return!1;const t=e.constructor;if(t===void 0)return!0;const r=t.prototype;return!(!fo(r)||!r.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function fo(e){return Object.prototype.toString.call(e)==="[object Object]"}function Hc(e){return new Promise(t=>{setTimeout(t,e)})}function qi(e,t,r){if(typeof r.structuralSharing=="function")return r.structuralSharing(e,t);if(r.structuralSharing!==!1){if(process.env.NODE_ENV!=="production")try{return Bi(e,t)}catch(n){throw console.error(`Structural sharing requires data to be JSON serializable. To fix this, turn off structuralSharing or return JSON-serializable data from your queryFn. [${r.queryHash}]: ${n}`),n}return Bi(e,t)}return t}function Kc(e,t,r=0){const n=[...e,t];return r&&n.length>r?n.slice(1):n}function Qc(e,t,r=0){const n=[t,...e];return r&&n.length>r?n.slice(0,-1):n}var Yn=Symbol();function el(e,t){return process.env.NODE_ENV!=="production"&&e.queryFn===Yn&&console.error(`Attempted to invoke queryFn when set to skipToken. This is likely a configuration error. Query hash: '${e.queryHash}'`),!e.queryFn&&(t!=null&&t.initialPromise)?()=>t.initialPromise:!e.queryFn||e.queryFn===Yn?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}function Yc(e,t){return typeof e=="function"?e(...t):!!e}var ur,qt,zr,As,Gc=(As=class extends Cn{constructor(){super();ye(this,ur);ye(this,qt);ye(this,zr);ee(this,zr,t=>{if(!br&&window.addEventListener){const r=()=>t();return window.addEventListener("visibilitychange",r,!1),()=>{window.removeEventListener("visibilitychange",r)}}})}onSubscribe(){C(this,qt)||this.setEventListener(C(this,zr))}onUnsubscribe(){var t;this.hasListeners()||((t=C(this,qt))==null||t.call(this),ee(this,qt,void 0))}setEventListener(t){var r;ee(this,zr,t),(r=C(this,qt))==null||r.call(this),ee(this,qt,t(n=>{typeof n=="boolean"?this.setFocused(n):this.onFocus()}))}setFocused(t){C(this,ur)!==t&&(ee(this,ur,t),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(r=>{r(t)})}isFocused(){var t;return typeof C(this,ur)=="boolean"?C(this,ur):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},ur=new WeakMap,qt=new WeakMap,zr=new WeakMap,As),ja=new Gc,Vr,Ut,Br,_s,Zc=(_s=class extends Cn{constructor(){super();ye(this,Vr,!0);ye(this,Ut);ye(this,Br);ee(this,Br,t=>{if(!br&&window.addEventListener){const r=()=>t(!0),n=()=>t(!1);return window.addEventListener("online",r,!1),window.addEventListener("offline",n,!1),()=>{window.removeEventListener("online",r),window.removeEventListener("offline",n)}}})}onSubscribe(){C(this,Ut)||this.setEventListener(C(this,Br))}onUnsubscribe(){var t;this.hasListeners()||((t=C(this,Ut))==null||t.call(this),ee(this,Ut,void 0))}setEventListener(t){var r;ee(this,Br,t),(r=C(this,Ut))==null||r.call(this),ee(this,Ut,t(this.setOnline.bind(this)))}setOnline(t){C(this,Vr)!==t&&(ee(this,Vr,t),this.listeners.forEach(n=>{n(t)}))}isOnline(){return C(this,Vr)}},Vr=new WeakMap,Ut=new WeakMap,Br=new WeakMap,_s),Gn=new Zc;function Ui(){let e,t;const r=new Promise((i,a)=>{e=i,t=a});r.status="pending",r.catch(()=>{});function n(i){Object.assign(r,i),delete r.resolve,delete r.reject}return r.resolve=i=>{n({status:"fulfilled",value:i}),e(i)},r.reject=i=>{n({status:"rejected",reason:i}),t(i)},r}function Xc(e){return Math.min(1e3*2**e,3e4)}function tl(e){return(e??"online")==="online"?Gn.isOnline():!0}var rl=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function Si(e){return e instanceof rl}function nl(e){let t=!1,r=0,n=!1,i;const a=Ui(),o=c=>{var b;n||(f(new rl(c)),(b=e.abort)==null||b.call(e))},s=()=>{t=!0},l=()=>{t=!1},p=()=>ja.isFocused()&&(e.networkMode==="always"||Gn.isOnline())&&e.canRun(),u=()=>tl(e.networkMode)&&e.canRun(),d=c=>{var b;n||(n=!0,(b=e.onSuccess)==null||b.call(e,c),i==null||i(),a.resolve(c))},f=c=>{var b;n||(n=!0,(b=e.onError)==null||b.call(e,c),i==null||i(),a.reject(c))},g=()=>new Promise(c=>{var b;i=y=>{(n||p())&&c(y)},(b=e.onPause)==null||b.call(e)}).then(()=>{var c;i=void 0,n||(c=e.onContinue)==null||c.call(e)}),S=()=>{if(n)return;let c;const b=r===0?e.initialPromise:void 0;try{c=b??e.fn()}catch(y){c=Promise.reject(y)}Promise.resolve(c).then(d).catch(y=>{var B;if(n)return;const j=e.retry??(br?0:3),R=e.retryDelay??Xc,k=typeof R=="function"?R(r,y):R,v=j===!0||typeof j=="number"&&r<j||typeof j=="function"&&j(r,y);if(t||!v){f(y);return}r++,(B=e.onFail)==null||B.call(e,r,y),Hc(k).then(()=>p()?void 0:g()).then(()=>{t?f(y):S()})})};return{promise:a,cancel:o,continue:()=>(i==null||i(),a),cancelRetry:s,continueRetry:l,canStart:u,start:()=>(u()?S():g().then(S),a)}}var Jc=e=>setTimeout(e,0);function eu(){let e=[],t=0,r=s=>{s()},n=s=>{s()},i=Jc;const a=s=>{t?e.push(s):i(()=>{r(s)})},o=()=>{const s=e;e=[],s.length&&i(()=>{n(()=>{s.forEach(l=>{r(l)})})})};return{batch:s=>{let l;t++;try{l=s()}finally{t--,t||o()}return l},batchCalls:s=>(...l)=>{a(()=>{s(...l)})},schedule:a,setNotifyFunction:s=>{r=s},setBatchNotifyFunction:s=>{n=s},setScheduler:s=>{i=s}}}var Ue=eu(),pr,Rs,il=(Rs=class{constructor(){ye(this,pr)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),Vi(this.gcTime)&&ee(this,pr,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(br?1/0:5*60*1e3))}clearGcTimeout(){C(this,pr)&&(clearTimeout(C(this,pr)),ee(this,pr,void 0))}},pr=new WeakMap,Rs),Nr,dr,lt,fr,We,xn,hr,mt,Pt,$s,tu=($s=class extends il{constructor(t){super();ye(this,mt);ye(this,Nr);ye(this,dr);ye(this,lt);ye(this,fr);ye(this,We);ye(this,xn);ye(this,hr);ee(this,hr,!1),ee(this,xn,t.defaultOptions),this.setOptions(t.options),this.observers=[],ee(this,fr,t.client),ee(this,lt,C(this,fr).getQueryCache()),this.queryKey=t.queryKey,this.queryHash=t.queryHash,ee(this,Nr,ru(this.options)),this.state=t.state??C(this,Nr),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return(t=C(this,We))==null?void 0:t.promise}setOptions(t){this.options={...C(this,xn),...t},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&C(this,lt).remove(this)}setData(t,r){const n=qi(this.state.data,t,this.options);return ve(this,mt,Pt).call(this,{data:n,type:"success",dataUpdatedAt:r==null?void 0:r.updatedAt,manual:r==null?void 0:r.manual}),n}setState(t,r){ve(this,mt,Pt).call(this,{type:"setState",state:t,setStateOptions:r})}cancel(t){var n,i;const r=(n=C(this,We))==null?void 0:n.promise;return(i=C(this,We))==null||i.cancel(t),r?r.then(Je).catch(Je):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(C(this,Nr))}isActive(){return this.observers.some(t=>ct(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===Yn||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStatic(){return this.getObserversCount()>0?this.observers.some(t=>Xt(t.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(t=>t.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(t=0){return this.state.data===void 0?!0:t==="static"?!1:this.state.isInvalidated?!0:!Js(this.state.dataUpdatedAt,t)}onFocus(){var r;const t=this.observers.find(n=>n.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(r=C(this,We))==null||r.continue()}onOnline(){var r;const t=this.observers.find(n=>n.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(r=C(this,We))==null||r.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),C(this,lt).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(r=>r!==t),this.observers.length||(C(this,We)&&(C(this,hr)?C(this,We).cancel({revert:!0}):C(this,We).cancelRetry()),this.scheduleGc()),C(this,lt).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||ve(this,mt,Pt).call(this,{type:"invalidate"})}fetch(t,r){var p,u,d;if(this.state.fetchStatus!=="idle"){if(this.state.data!==void 0&&(r!=null&&r.cancelRefetch))this.cancel({silent:!0});else if(C(this,We))return C(this,We).continueRetry(),C(this,We).promise}if(t&&this.setOptions(t),!this.options.queryFn){const f=this.observers.find(g=>g.options.queryFn);f&&this.setOptions(f.options)}process.env.NODE_ENV!=="production"&&(Array.isArray(this.options.queryKey)||console.error("As of v4, queryKey needs to be an Array. If you are using a string like 'repoData', please change it to an Array, e.g. ['repoData']"));const n=new AbortController,i=f=>{Object.defineProperty(f,"signal",{enumerable:!0,get:()=>(ee(this,hr,!0),n.signal)})},a=()=>{const f=el(this.options,r),S=(()=>{const c={client:C(this,fr),queryKey:this.queryKey,meta:this.meta};return i(c),c})();return ee(this,hr,!1),this.options.persister?this.options.persister(f,S,this):f(S)},s=(()=>{const f={fetchOptions:r,options:this.options,queryKey:this.queryKey,client:C(this,fr),state:this.state,fetchFn:a};return i(f),f})();(p=this.options.behavior)==null||p.onFetch(s,this),ee(this,dr,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((u=s.fetchOptions)==null?void 0:u.meta))&&ve(this,mt,Pt).call(this,{type:"fetch",meta:(d=s.fetchOptions)==null?void 0:d.meta});const l=f=>{var g,S,c,b;Si(f)&&f.silent||ve(this,mt,Pt).call(this,{type:"error",error:f}),Si(f)||((S=(g=C(this,lt).config).onError)==null||S.call(g,f,this),(b=(c=C(this,lt).config).onSettled)==null||b.call(c,this.state.data,f,this)),this.scheduleGc()};return ee(this,We,nl({initialPromise:r==null?void 0:r.initialPromise,fn:s.fetchFn,abort:n.abort.bind(n),onSuccess:f=>{var g,S,c,b;if(f===void 0){process.env.NODE_ENV!=="production"&&console.error(`Query data cannot be undefined. Please make sure to return a value other than undefined from your query function. Affected query key: ${this.queryHash}`),l(new Error(`${this.queryHash} data is undefined`));return}try{this.setData(f)}catch(y){l(y);return}(S=(g=C(this,lt).config).onSuccess)==null||S.call(g,f,this),(b=(c=C(this,lt).config).onSettled)==null||b.call(c,f,this.state.error,this),this.scheduleGc()},onError:l,onFail:(f,g)=>{ve(this,mt,Pt).call(this,{type:"failed",failureCount:f,error:g})},onPause:()=>{ve(this,mt,Pt).call(this,{type:"pause"})},onContinue:()=>{ve(this,mt,Pt).call(this,{type:"continue"})},retry:s.options.retry,retryDelay:s.options.retryDelay,networkMode:s.options.networkMode,canRun:()=>!0})),C(this,We).start()}},Nr=new WeakMap,dr=new WeakMap,lt=new WeakMap,fr=new WeakMap,We=new WeakMap,xn=new WeakMap,hr=new WeakMap,mt=new WeakSet,Pt=function(t){const r=n=>{switch(t.type){case"failed":return{...n,fetchFailureCount:t.failureCount,fetchFailureReason:t.error};case"pause":return{...n,fetchStatus:"paused"};case"continue":return{...n,fetchStatus:"fetching"};case"fetch":return{...n,...al(n.data,this.options),fetchMeta:t.meta??null};case"success":return ee(this,dr,void 0),{...n,data:t.data,dataUpdateCount:n.dataUpdateCount+1,dataUpdatedAt:t.dataUpdatedAt??Date.now(),error:null,isInvalidated:!1,status:"success",...!t.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":const i=t.error;return Si(i)&&i.revert&&C(this,dr)?{...C(this,dr),fetchStatus:"idle"}:{...n,error:i,errorUpdateCount:n.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:n.fetchFailureCount+1,fetchFailureReason:i,fetchStatus:"idle",status:"error"};case"invalidate":return{...n,isInvalidated:!0};case"setState":return{...n,...t.state}}};this.state=r(this.state),Ue.batch(()=>{this.observers.forEach(n=>{n.onQueryUpdate()}),C(this,lt).notify({query:this,type:"updated",action:t})})},$s);function al(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:tl(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function ru(e){const t=typeof e.initialData=="function"?e.initialData():e.initialData,r=t!==void 0,n=r?typeof e.initialDataUpdatedAt=="function"?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:r?n??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:r?"success":"pending",fetchStatus:"idle"}}var Et,Ds,nu=(Ds=class extends Cn{constructor(t={}){super();ye(this,Et);this.config=t,ee(this,Et,new Map)}build(t,r,n){const i=r.queryKey,a=r.queryHash??Oa(i,r);let o=this.get(a);return o||(o=new tu({client:t,queryKey:i,queryHash:a,options:t.defaultQueryOptions(r),state:n,defaultOptions:t.getQueryDefaults(i)}),this.add(o)),o}add(t){C(this,Et).has(t.queryHash)||(C(this,Et).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const r=C(this,Et).get(t.queryHash);r&&(t.destroy(),r===t&&C(this,Et).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){Ue.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return C(this,Et).get(t)}getAll(){return[...C(this,Et).values()]}find(t){const r={exact:!0,...t};return this.getAll().find(n=>co(r,n))}findAll(t={}){const r=this.getAll();return Object.keys(t).length>0?r.filter(n=>co(t,n)):r}notify(t){Ue.batch(()=>{this.listeners.forEach(r=>{r(t)})})}onFocus(){Ue.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){Ue.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},Et=new WeakMap,Ds),kt,He,mr,Tt,Bt,Ps,iu=(Ps=class extends il{constructor(t){super();ye(this,Tt);ye(this,kt);ye(this,He);ye(this,mr);this.mutationId=t.mutationId,ee(this,He,t.mutationCache),ee(this,kt,[]),this.state=t.state||au(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){C(this,kt).includes(t)||(C(this,kt).push(t),this.clearGcTimeout(),C(this,He).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){ee(this,kt,C(this,kt).filter(r=>r!==t)),this.scheduleGc(),C(this,He).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){C(this,kt).length||(this.state.status==="pending"?this.scheduleGc():C(this,He).remove(this))}continue(){var t;return((t=C(this,mr))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var a,o,s,l,p,u,d,f,g,S,c,b,y,j,R,k,v,B,A,H;const r=()=>{ve(this,Tt,Bt).call(this,{type:"continue"})};ee(this,mr,nl({fn:()=>this.options.mutationFn?this.options.mutationFn(t):Promise.reject(new Error("No mutationFn found")),onFail:(U,h)=>{ve(this,Tt,Bt).call(this,{type:"failed",failureCount:U,error:h})},onPause:()=>{ve(this,Tt,Bt).call(this,{type:"pause"})},onContinue:r,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>C(this,He).canRun(this)}));const n=this.state.status==="pending",i=!C(this,mr).canStart();try{if(n)r();else{ve(this,Tt,Bt).call(this,{type:"pending",variables:t,isPaused:i}),await((o=(a=C(this,He).config).onMutate)==null?void 0:o.call(a,t,this));const h=await((l=(s=this.options).onMutate)==null?void 0:l.call(s,t));h!==this.state.context&&ve(this,Tt,Bt).call(this,{type:"pending",context:h,variables:t,isPaused:i})}const U=await C(this,mr).start();return await((u=(p=C(this,He).config).onSuccess)==null?void 0:u.call(p,U,t,this.state.context,this)),await((f=(d=this.options).onSuccess)==null?void 0:f.call(d,U,t,this.state.context)),await((S=(g=C(this,He).config).onSettled)==null?void 0:S.call(g,U,null,this.state.variables,this.state.context,this)),await((b=(c=this.options).onSettled)==null?void 0:b.call(c,U,null,t,this.state.context)),ve(this,Tt,Bt).call(this,{type:"success",data:U}),U}catch(U){try{throw await((j=(y=C(this,He).config).onError)==null?void 0:j.call(y,U,t,this.state.context,this)),await((k=(R=this.options).onError)==null?void 0:k.call(R,U,t,this.state.context)),await((B=(v=C(this,He).config).onSettled)==null?void 0:B.call(v,void 0,U,this.state.variables,this.state.context,this)),await((H=(A=this.options).onSettled)==null?void 0:H.call(A,void 0,U,t,this.state.context)),U}finally{ve(this,Tt,Bt).call(this,{type:"error",error:U})}}finally{C(this,He).runNext(this)}}},kt=new WeakMap,He=new WeakMap,mr=new WeakMap,Tt=new WeakSet,Bt=function(t){const r=n=>{switch(t.type){case"failed":return{...n,failureCount:t.failureCount,failureReason:t.error};case"pause":return{...n,isPaused:!0};case"continue":return{...n,isPaused:!1};case"pending":return{...n,context:t.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:t.isPaused,status:"pending",variables:t.variables,submittedAt:Date.now()};case"success":return{...n,data:t.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...n,data:void 0,error:t.error,failureCount:n.failureCount+1,failureReason:t.error,isPaused:!1,status:"error"}}};this.state=r(this.state),Ue.batch(()=>{C(this,kt).forEach(n=>{n.onMutationUpdate(t)}),C(this,He).notify({mutation:this,type:"updated",action:t})})},Ps);function au(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var It,yt,vn,Is,ou=(Is=class extends Cn{constructor(t={}){super();ye(this,It);ye(this,yt);ye(this,vn);this.config=t,ee(this,It,new Set),ee(this,yt,new Map),ee(this,vn,0)}build(t,r,n){const i=new iu({mutationCache:this,mutationId:++jn(this,vn)._,options:t.defaultMutationOptions(r),state:n});return this.add(i),i}add(t){C(this,It).add(t);const r=Fn(t);if(typeof r=="string"){const n=C(this,yt).get(r);n?n.push(t):C(this,yt).set(r,[t])}this.notify({type:"added",mutation:t})}remove(t){if(C(this,It).delete(t)){const r=Fn(t);if(typeof r=="string"){const n=C(this,yt).get(r);if(n)if(n.length>1){const i=n.indexOf(t);i!==-1&&n.splice(i,1)}else n[0]===t&&C(this,yt).delete(r)}}this.notify({type:"removed",mutation:t})}canRun(t){const r=Fn(t);if(typeof r=="string"){const n=C(this,yt).get(r),i=n==null?void 0:n.find(a=>a.state.status==="pending");return!i||i===t}else return!0}runNext(t){var n;const r=Fn(t);if(typeof r=="string"){const i=(n=C(this,yt).get(r))==null?void 0:n.find(a=>a!==t&&a.state.isPaused);return(i==null?void 0:i.continue())??Promise.resolve()}else return Promise.resolve()}clear(){Ue.batch(()=>{C(this,It).forEach(t=>{this.notify({type:"removed",mutation:t})}),C(this,It).clear(),C(this,yt).clear()})}getAll(){return Array.from(C(this,It))}find(t){const r={exact:!0,...t};return this.getAll().find(n=>uo(r,n))}findAll(t={}){return this.getAll().filter(r=>uo(t,r))}notify(t){Ue.batch(()=>{this.listeners.forEach(r=>{r(t)})})}resumePausedMutations(){const t=this.getAll().filter(r=>r.state.isPaused);return Ue.batch(()=>Promise.all(t.map(r=>r.continue().catch(Je))))}},It=new WeakMap,yt=new WeakMap,vn=new WeakMap,Is);function Fn(e){var t;return(t=e.options.scope)==null?void 0:t.id}function ho(e){return{onFetch:(t,r)=>{var u,d,f,g,S;const n=t.options,i=(f=(d=(u=t.fetchOptions)==null?void 0:u.meta)==null?void 0:d.fetchMore)==null?void 0:f.direction,a=((g=t.state.data)==null?void 0:g.pages)||[],o=((S=t.state.data)==null?void 0:S.pageParams)||[];let s={pages:[],pageParams:[]},l=0;const p=async()=>{let c=!1;const b=R=>{Object.defineProperty(R,"signal",{enumerable:!0,get:()=>(t.signal.aborted?c=!0:t.signal.addEventListener("abort",()=>{c=!0}),t.signal)})},y=el(t.options,t.fetchOptions),j=async(R,k,v)=>{if(c)return Promise.reject();if(k==null&&R.pages.length)return Promise.resolve(R);const A=(()=>{const z={client:t.client,queryKey:t.queryKey,pageParam:k,direction:v?"backward":"forward",meta:t.options.meta};return b(z),z})(),H=await y(A),{maxPages:U}=t.options,h=v?Qc:Kc;return{pages:h(R.pages,H,U),pageParams:h(R.pageParams,k,U)}};if(i&&a.length){const R=i==="backward",k=R?su:mo,v={pages:a,pageParams:o},B=k(n,v);s=await j(v,B,R)}else{const R=e??a.length;do{const k=l===0?o[0]??n.initialPageParam:mo(n,s);if(l>0&&k==null)break;s=await j(s,k),l++}while(l<R)}return s};t.options.persister?t.fetchFn=()=>{var c,b;return(b=(c=t.options).persister)==null?void 0:b.call(c,p,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},r)}:t.fetchFn=p}}}function mo(e,{pages:t,pageParams:r}){const n=t.length-1;return t.length>0?e.getNextPageParam(t[n],t,r[n],r):void 0}function su(e,{pages:t,pageParams:r}){var n;return t.length>0?(n=e.getPreviousPageParam)==null?void 0:n.call(e,t[0],t,r[0],r):void 0}var Pe,Wt,Ht,Lr,qr,Kt,Ur,Wr,Ms,lu=(Ms=class{constructor(e={}){ye(this,Pe);ye(this,Wt);ye(this,Ht);ye(this,Lr);ye(this,qr);ye(this,Kt);ye(this,Ur);ye(this,Wr);ee(this,Pe,e.queryCache||new nu),ee(this,Wt,e.mutationCache||new ou),ee(this,Ht,e.defaultOptions||{}),ee(this,Lr,new Map),ee(this,qr,new Map),ee(this,Kt,0)}mount(){jn(this,Kt)._++,C(this,Kt)===1&&(ee(this,Ur,ja.subscribe(async e=>{e&&(await this.resumePausedMutations(),C(this,Pe).onFocus())})),ee(this,Wr,Gn.subscribe(async e=>{e&&(await this.resumePausedMutations(),C(this,Pe).onOnline())})))}unmount(){var e,t;jn(this,Kt)._--,C(this,Kt)===0&&((e=C(this,Ur))==null||e.call(this),ee(this,Ur,void 0),(t=C(this,Wr))==null||t.call(this),ee(this,Wr,void 0))}isFetching(e){return C(this,Pe).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return C(this,Wt).findAll({...e,status:"pending"}).length}getQueryData(e){var r;const t=this.defaultQueryOptions({queryKey:e});return(r=C(this,Pe).get(t.queryHash))==null?void 0:r.state.data}ensureQueryData(e){const t=this.defaultQueryOptions(e),r=C(this,Pe).build(this,t),n=r.state.data;return n===void 0?this.fetchQuery(e):(e.revalidateIfStale&&r.isStaleByTime(Xt(t.staleTime,r))&&this.prefetchQuery(t),Promise.resolve(n))}getQueriesData(e){return C(this,Pe).findAll(e).map(({queryKey:t,state:r})=>{const n=r.data;return[t,n]})}setQueryData(e,t,r){const n=this.defaultQueryOptions({queryKey:e}),i=C(this,Pe).get(n.queryHash),a=i==null?void 0:i.state.data,o=Wc(t,a);if(o!==void 0)return C(this,Pe).build(this,n).setData(o,{...r,manual:!0})}setQueriesData(e,t,r){return Ue.batch(()=>C(this,Pe).findAll(e).map(({queryKey:n})=>[n,this.setQueryData(n,t,r)]))}getQueryState(e){var r;const t=this.defaultQueryOptions({queryKey:e});return(r=C(this,Pe).get(t.queryHash))==null?void 0:r.state}removeQueries(e){const t=C(this,Pe);Ue.batch(()=>{t.findAll(e).forEach(r=>{t.remove(r)})})}resetQueries(e,t){const r=C(this,Pe);return Ue.batch(()=>(r.findAll(e).forEach(n=>{n.reset()}),this.refetchQueries({type:"active",...e},t)))}cancelQueries(e,t={}){const r={revert:!0,...t},n=Ue.batch(()=>C(this,Pe).findAll(e).map(i=>i.cancel(r)));return Promise.all(n).then(Je).catch(Je)}invalidateQueries(e,t={}){return Ue.batch(()=>(C(this,Pe).findAll(e).forEach(r=>{r.invalidate()}),(e==null?void 0:e.refetchType)==="none"?Promise.resolve():this.refetchQueries({...e,type:(e==null?void 0:e.refetchType)??(e==null?void 0:e.type)??"active"},t)))}refetchQueries(e,t={}){const r={...t,cancelRefetch:t.cancelRefetch??!0},n=Ue.batch(()=>C(this,Pe).findAll(e).filter(i=>!i.isDisabled()&&!i.isStatic()).map(i=>{let a=i.fetch(void 0,r);return r.throwOnError||(a=a.catch(Je)),i.state.fetchStatus==="paused"?Promise.resolve():a}));return Promise.all(n).then(Je)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const r=C(this,Pe).build(this,t);return r.isStaleByTime(Xt(t.staleTime,r))?r.fetch(t):Promise.resolve(r.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(Je).catch(Je)}fetchInfiniteQuery(e){return e.behavior=ho(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(Je).catch(Je)}ensureInfiniteQueryData(e){return e.behavior=ho(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return Gn.isOnline()?C(this,Wt).resumePausedMutations():Promise.resolve()}getQueryCache(){return C(this,Pe)}getMutationCache(){return C(this,Wt)}getDefaultOptions(){return C(this,Ht)}setDefaultOptions(e){ee(this,Ht,e)}setQueryDefaults(e,t){C(this,Lr).set(hn(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...C(this,Lr).values()],r={};return t.forEach(n=>{mn(e,n.queryKey)&&Object.assign(r,n.defaultOptions)}),r}setMutationDefaults(e,t){C(this,qr).set(hn(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...C(this,qr).values()],r={};return t.forEach(n=>{mn(e,n.mutationKey)&&Object.assign(r,n.defaultOptions)}),r}defaultQueryOptions(e){if(e._defaulted)return e;const t={...C(this,Ht).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=Oa(t.queryKey,t)),t.refetchOnReconnect===void 0&&(t.refetchOnReconnect=t.networkMode!=="always"),t.throwOnError===void 0&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode="offlineFirst"),t.queryFn===Yn&&(t.enabled=!1),t}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...C(this,Ht).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){C(this,Pe).clear(),C(this,Wt).clear()}},Pe=new WeakMap,Wt=new WeakMap,Ht=new WeakMap,Lr=new WeakMap,qr=new WeakMap,Kt=new WeakMap,Ur=new WeakMap,Wr=new WeakMap,Ms),Ze,be,bn,Ke,yr,Hr,Qt,Yt,wn,Kr,Qr,gr,xr,Gt,Yr,Ee,sn,Wi,Hi,Ki,Qi,Yi,Gi,Zi,ol,zs,cu=(zs=class extends Cn{constructor(t,r){super();ye(this,Ee);ye(this,Ze);ye(this,be);ye(this,bn);ye(this,Ke);ye(this,yr);ye(this,Hr);ye(this,Qt);ye(this,Yt);ye(this,wn);ye(this,Kr);ye(this,Qr);ye(this,gr);ye(this,xr);ye(this,Gt);ye(this,Yr,new Set);this.options=r,ee(this,Ze,t),ee(this,Yt,null),ee(this,Qt,Ui()),this.options.experimental_prefetchInRender||C(this,Qt).reject(new Error("experimental_prefetchInRender feature flag is not enabled")),this.bindMethods(),this.setOptions(r)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(C(this,be).addObserver(this),yo(C(this,be),this.options)?ve(this,Ee,sn).call(this):this.updateResult(),ve(this,Ee,Qi).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return Xi(C(this,be),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return Xi(C(this,be),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,ve(this,Ee,Yi).call(this),ve(this,Ee,Gi).call(this),C(this,be).removeObserver(this)}setOptions(t){const r=this.options,n=C(this,be);if(this.options=C(this,Ze).defaultQueryOptions(t),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof ct(this.options.enabled,C(this,be))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");ve(this,Ee,Zi).call(this),C(this,be).setOptions(this.options),r._defaulted&&!Ni(this.options,r)&&C(this,Ze).getQueryCache().notify({type:"observerOptionsUpdated",query:C(this,be),observer:this});const i=this.hasListeners();i&&go(C(this,be),n,this.options,r)&&ve(this,Ee,sn).call(this),this.updateResult(),i&&(C(this,be)!==n||ct(this.options.enabled,C(this,be))!==ct(r.enabled,C(this,be))||Xt(this.options.staleTime,C(this,be))!==Xt(r.staleTime,C(this,be)))&&ve(this,Ee,Wi).call(this);const a=ve(this,Ee,Hi).call(this);i&&(C(this,be)!==n||ct(this.options.enabled,C(this,be))!==ct(r.enabled,C(this,be))||a!==C(this,Gt))&&ve(this,Ee,Ki).call(this,a)}getOptimisticResult(t){const r=C(this,Ze).getQueryCache().build(C(this,Ze),t),n=this.createResult(r,t);return pu(this,n)&&(ee(this,Ke,n),ee(this,Hr,this.options),ee(this,yr,C(this,be).state)),n}getCurrentResult(){return C(this,Ke)}trackResult(t,r){return new Proxy(t,{get:(n,i)=>(this.trackProp(i),r==null||r(i),Reflect.get(n,i))})}trackProp(t){C(this,Yr).add(t)}getCurrentQuery(){return C(this,be)}refetch({...t}={}){return this.fetch({...t})}fetchOptimistic(t){const r=C(this,Ze).defaultQueryOptions(t),n=C(this,Ze).getQueryCache().build(C(this,Ze),r);return n.fetch().then(()=>this.createResult(n,r))}fetch(t){return ve(this,Ee,sn).call(this,{...t,cancelRefetch:t.cancelRefetch??!0}).then(()=>(this.updateResult(),C(this,Ke)))}createResult(t,r){var U;const n=C(this,be),i=this.options,a=C(this,Ke),o=C(this,yr),s=C(this,Hr),p=t!==n?t.state:C(this,bn),{state:u}=t;let d={...u},f=!1,g;if(r._optimisticResults){const h=this.hasListeners(),z=!h&&yo(t,r),M=h&&go(t,n,r,i);(z||M)&&(d={...d,...al(u.data,t.options)}),r._optimisticResults==="isRestoring"&&(d.fetchStatus="idle")}let{error:S,errorUpdatedAt:c,status:b}=d;g=d.data;let y=!1;if(r.placeholderData!==void 0&&g===void 0&&b==="pending"){let h;a!=null&&a.isPlaceholderData&&r.placeholderData===(s==null?void 0:s.placeholderData)?(h=a.data,y=!0):h=typeof r.placeholderData=="function"?r.placeholderData((U=C(this,Qr))==null?void 0:U.state.data,C(this,Qr)):r.placeholderData,h!==void 0&&(b="success",g=qi(a==null?void 0:a.data,h,r),f=!0)}if(r.select&&g!==void 0&&!y)if(a&&g===(o==null?void 0:o.data)&&r.select===C(this,wn))g=C(this,Kr);else try{ee(this,wn,r.select),g=r.select(g),g=qi(a==null?void 0:a.data,g,r),ee(this,Kr,g),ee(this,Yt,null)}catch(h){ee(this,Yt,h)}C(this,Yt)&&(S=C(this,Yt),g=C(this,Kr),c=Date.now(),b="error");const j=d.fetchStatus==="fetching",R=b==="pending",k=b==="error",v=R&&j,B=g!==void 0,H={status:b,fetchStatus:d.fetchStatus,isPending:R,isSuccess:b==="success",isError:k,isInitialLoading:v,isLoading:v,data:g,dataUpdatedAt:d.dataUpdatedAt,error:S,errorUpdatedAt:c,failureCount:d.fetchFailureCount,failureReason:d.fetchFailureReason,errorUpdateCount:d.errorUpdateCount,isFetched:d.dataUpdateCount>0||d.errorUpdateCount>0,isFetchedAfterMount:d.dataUpdateCount>p.dataUpdateCount||d.errorUpdateCount>p.errorUpdateCount,isFetching:j,isRefetching:j&&!R,isLoadingError:k&&!B,isPaused:d.fetchStatus==="paused",isPlaceholderData:f,isRefetchError:k&&B,isStale:Fa(t,r),refetch:this.refetch,promise:C(this,Qt),isEnabled:ct(r.enabled,t)!==!1};if(this.options.experimental_prefetchInRender){const h=q=>{H.status==="error"?q.reject(H.error):H.data!==void 0&&q.resolve(H.data)},z=()=>{const q=ee(this,Qt,H.promise=Ui());h(q)},M=C(this,Qt);switch(M.status){case"pending":t.queryHash===n.queryHash&&h(M);break;case"fulfilled":(H.status==="error"||H.data!==M.value)&&z();break;case"rejected":(H.status!=="error"||H.error!==M.reason)&&z();break}}return H}updateResult(){const t=C(this,Ke),r=this.createResult(C(this,be),this.options);if(ee(this,yr,C(this,be).state),ee(this,Hr,this.options),C(this,yr).data!==void 0&&ee(this,Qr,C(this,be)),Ni(r,t))return;ee(this,Ke,r);const n=()=>{if(!t)return!0;const{notifyOnChangeProps:i}=this.options,a=typeof i=="function"?i():i;if(a==="all"||!a&&!C(this,Yr).size)return!0;const o=new Set(a??C(this,Yr));return this.options.throwOnError&&o.add("error"),Object.keys(C(this,Ke)).some(s=>{const l=s;return C(this,Ke)[l]!==t[l]&&o.has(l)})};ve(this,Ee,ol).call(this,{listeners:n()})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&ve(this,Ee,Qi).call(this)}},Ze=new WeakMap,be=new WeakMap,bn=new WeakMap,Ke=new WeakMap,yr=new WeakMap,Hr=new WeakMap,Qt=new WeakMap,Yt=new WeakMap,wn=new WeakMap,Kr=new WeakMap,Qr=new WeakMap,gr=new WeakMap,xr=new WeakMap,Gt=new WeakMap,Yr=new WeakMap,Ee=new WeakSet,sn=function(t){ve(this,Ee,Zi).call(this);let r=C(this,be).fetch(this.options,t);return t!=null&&t.throwOnError||(r=r.catch(Je)),r},Wi=function(){ve(this,Ee,Yi).call(this);const t=Xt(this.options.staleTime,C(this,be));if(br||C(this,Ke).isStale||!Vi(t))return;const n=Js(C(this,Ke).dataUpdatedAt,t)+1;ee(this,gr,setTimeout(()=>{C(this,Ke).isStale||this.updateResult()},n))},Hi=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(C(this,be)):this.options.refetchInterval)??!1},Ki=function(t){ve(this,Ee,Gi).call(this),ee(this,Gt,t),!(br||ct(this.options.enabled,C(this,be))===!1||!Vi(C(this,Gt))||C(this,Gt)===0)&&ee(this,xr,setInterval(()=>{(this.options.refetchIntervalInBackground||ja.isFocused())&&ve(this,Ee,sn).call(this)},C(this,Gt)))},Qi=function(){ve(this,Ee,Wi).call(this),ve(this,Ee,Ki).call(this,ve(this,Ee,Hi).call(this))},Yi=function(){C(this,gr)&&(clearTimeout(C(this,gr)),ee(this,gr,void 0))},Gi=function(){C(this,xr)&&(clearInterval(C(this,xr)),ee(this,xr,void 0))},Zi=function(){const t=C(this,Ze).getQueryCache().build(C(this,Ze),this.options);if(t===C(this,be))return;const r=C(this,be);ee(this,be,t),ee(this,bn,t.state),this.hasListeners()&&(r==null||r.removeObserver(this),t.addObserver(this))},ol=function(t){Ue.batch(()=>{t.listeners&&this.listeners.forEach(r=>{r(C(this,Ke))}),C(this,Ze).getQueryCache().notify({query:C(this,be),type:"observerResultsUpdated"})})},zs);function uu(e,t){return ct(t.enabled,e)!==!1&&e.state.data===void 0&&!(e.state.status==="error"&&t.retryOnMount===!1)}function yo(e,t){return uu(e,t)||e.state.data!==void 0&&Xi(e,t,t.refetchOnMount)}function Xi(e,t,r){if(ct(t.enabled,e)!==!1&&Xt(t.staleTime,e)!=="static"){const n=typeof r=="function"?r(e):r;return n==="always"||n!==!1&&Fa(e,t)}return!1}function go(e,t,r,n){return(e!==t||ct(n.enabled,e)===!1)&&(!r.suspense||e.state.status!=="error")&&Fa(e,r)}function Fa(e,t){return ct(t.enabled,e)!==!1&&e.isStaleByTime(Xt(t.staleTime,e))}function pu(e,t){return!Ni(e.getCurrentResult(),t)}var sl=te.createContext(void 0),du=e=>{const t=te.useContext(sl);if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},fu=({client:e,children:t})=>(te.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),m.jsx(sl.Provider,{value:e,children:t})),ll=te.createContext(!1),hu=()=>te.useContext(ll);ll.Provider;function mu(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}var yu=te.createContext(mu()),gu=()=>te.useContext(yu),xu=(e,t)=>{(e.suspense||e.throwOnError||e.experimental_prefetchInRender)&&(t.isReset()||(e.retryOnMount=!1))},vu=e=>{te.useEffect(()=>{e.clearReset()},[e])},bu=({result:e,errorResetBoundary:t,throwOnError:r,query:n,suspense:i})=>e.isError&&!t.isReset()&&!e.isFetching&&n&&(i&&e.data===void 0||Yc(r,[e.error,n])),wu=e=>{if(e.suspense){const t=n=>n==="static"?n:Math.max(n??1e3,1e3),r=e.staleTime;e.staleTime=typeof r=="function"?(...n)=>t(r(...n)):t(r),typeof e.gcTime=="number"&&(e.gcTime=Math.max(e.gcTime,1e3))}},Su=(e,t)=>e.isLoading&&e.isFetching&&!t,Cu=(e,t)=>(e==null?void 0:e.suspense)&&t.isPending,xo=(e,t,r)=>t.fetchOptimistic(e).catch(()=>{r.clearReset()});function Eu(e,t,r){var d,f,g,S,c;if(process.env.NODE_ENV!=="production"&&(typeof e!="object"||Array.isArray(e)))throw new Error('Bad argument type. Starting with v5, only the "Object" form is allowed when calling query related functions. Please use the error stack to find the culprit call. More info here: https://tanstack.com/query/latest/docs/react/guides/migrating-to-v5#supports-a-single-signature-one-object');const n=hu(),i=gu(),a=du(),o=a.defaultQueryOptions(e);(f=(d=a.getDefaultOptions().queries)==null?void 0:d._experimental_beforeQuery)==null||f.call(d,o),process.env.NODE_ENV!=="production"&&(o.queryFn||console.error(`[${o.queryHash}]: No queryFn was passed as an option, and no default queryFn was found. The queryFn parameter is only optional when using a default queryFn. More info here: https://tanstack.com/query/latest/docs/framework/react/guides/default-query-function`)),o._optimisticResults=n?"isRestoring":"optimistic",wu(o),xu(o,i),vu(i);const s=!a.getQueryCache().get(o.queryHash),[l]=te.useState(()=>new t(a,o)),p=l.getOptimisticResult(o),u=!n&&e.subscribed!==!1;if(te.useSyncExternalStore(te.useCallback(b=>{const y=u?l.subscribe(Ue.batchCalls(b)):Je;return l.updateResult(),y},[l,u]),()=>l.getCurrentResult(),()=>l.getCurrentResult()),te.useEffect(()=>{l.setOptions(o)},[o,l]),Cu(o,p))throw xo(o,l,i);if(bu({result:p,errorResetBoundary:i,throwOnError:o.throwOnError,query:a.getQueryCache().get(o.queryHash),suspense:o.suspense}))throw p.error;if((S=(g=a.getDefaultOptions().queries)==null?void 0:g._experimental_afterQuery)==null||S.call(g,o,p),o.experimental_prefetchInRender&&!br&&Su(p,n)){const b=s?xo(o,l,i):(c=a.getQueryCache().get(o.queryHash))==null?void 0:c.promise;b==null||b.catch(Je).finally(()=>{l.updateResult()})}return o.notifyOnChangeProps?p:l.trackResult(p)}function ku(e,t){return Eu(e,cu)}function Aa(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var An={exports:{}},_n={exports:{}},we={};/** @license React v16.13.1
2
2
  * react-is.production.min.js
3
3
  *
4
4
  * Copyright (c) Facebook, Inc. and its affiliates.
5
5
  *
6
6
  * This source code is licensed under the MIT license found in the
7
7
  * LICENSE file in the root directory of this source tree.
8
- */var go;function Tu(){if(go)return be;go=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,n=e?Symbol.for("react.fragment"):60107,i=e?Symbol.for("react.strict_mode"):60108,a=e?Symbol.for("react.profiler"):60114,o=e?Symbol.for("react.provider"):60109,s=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,p=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,f=e?Symbol.for("react.suspense_list"):60120,y=e?Symbol.for("react.memo"):60115,S=e?Symbol.for("react.lazy"):60116,c=e?Symbol.for("react.block"):60121,b=e?Symbol.for("react.fundamental"):60117,g=e?Symbol.for("react.responder"):60118,O=e?Symbol.for("react.scope"):60119;function A(x){if(typeof x=="object"&&x!==null){var B=x.$$typeof;switch(B){case t:switch(x=x.type,x){case l:case p:case n:case a:case i:case d:return x;default:switch(x=x&&x.$$typeof,x){case s:case u:case S:case y:case o:return x;default:return B}}case r:return B}}}function k(x){return A(x)===p}return be.AsyncMode=l,be.ConcurrentMode=p,be.ContextConsumer=s,be.ContextProvider=o,be.Element=t,be.ForwardRef=u,be.Fragment=n,be.Lazy=S,be.Memo=y,be.Portal=r,be.Profiler=a,be.StrictMode=i,be.Suspense=d,be.isAsyncMode=function(x){return k(x)||A(x)===l},be.isConcurrentMode=k,be.isContextConsumer=function(x){return A(x)===s},be.isContextProvider=function(x){return A(x)===o},be.isElement=function(x){return typeof x=="object"&&x!==null&&x.$$typeof===t},be.isForwardRef=function(x){return A(x)===u},be.isFragment=function(x){return A(x)===n},be.isLazy=function(x){return A(x)===S},be.isMemo=function(x){return A(x)===y},be.isPortal=function(x){return A(x)===r},be.isProfiler=function(x){return A(x)===a},be.isStrictMode=function(x){return A(x)===i},be.isSuspense=function(x){return A(x)===d},be.isValidElementType=function(x){return typeof x=="string"||typeof x=="function"||x===n||x===p||x===a||x===i||x===d||x===f||typeof x=="object"&&x!==null&&(x.$$typeof===S||x.$$typeof===y||x.$$typeof===o||x.$$typeof===s||x.$$typeof===u||x.$$typeof===b||x.$$typeof===g||x.$$typeof===O||x.$$typeof===c)},be.typeOf=A,be}var we={};/** @license React v16.13.1
8
+ */var vo;function Tu(){if(vo)return we;vo=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,n=e?Symbol.for("react.fragment"):60107,i=e?Symbol.for("react.strict_mode"):60108,a=e?Symbol.for("react.profiler"):60114,o=e?Symbol.for("react.provider"):60109,s=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,p=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,f=e?Symbol.for("react.suspense_list"):60120,g=e?Symbol.for("react.memo"):60115,S=e?Symbol.for("react.lazy"):60116,c=e?Symbol.for("react.block"):60121,b=e?Symbol.for("react.fundamental"):60117,y=e?Symbol.for("react.responder"):60118,j=e?Symbol.for("react.scope"):60119;function R(v){if(typeof v=="object"&&v!==null){var B=v.$$typeof;switch(B){case t:switch(v=v.type,v){case l:case p:case n:case a:case i:case d:return v;default:switch(v=v&&v.$$typeof,v){case s:case u:case S:case g:case o:return v;default:return B}}case r:return B}}}function k(v){return R(v)===p}return we.AsyncMode=l,we.ConcurrentMode=p,we.ContextConsumer=s,we.ContextProvider=o,we.Element=t,we.ForwardRef=u,we.Fragment=n,we.Lazy=S,we.Memo=g,we.Portal=r,we.Profiler=a,we.StrictMode=i,we.Suspense=d,we.isAsyncMode=function(v){return k(v)||R(v)===l},we.isConcurrentMode=k,we.isContextConsumer=function(v){return R(v)===s},we.isContextProvider=function(v){return R(v)===o},we.isElement=function(v){return typeof v=="object"&&v!==null&&v.$$typeof===t},we.isForwardRef=function(v){return R(v)===u},we.isFragment=function(v){return R(v)===n},we.isLazy=function(v){return R(v)===S},we.isMemo=function(v){return R(v)===g},we.isPortal=function(v){return R(v)===r},we.isProfiler=function(v){return R(v)===a},we.isStrictMode=function(v){return R(v)===i},we.isSuspense=function(v){return R(v)===d},we.isValidElementType=function(v){return typeof v=="string"||typeof v=="function"||v===n||v===p||v===a||v===i||v===d||v===f||typeof v=="object"&&v!==null&&(v.$$typeof===S||v.$$typeof===g||v.$$typeof===o||v.$$typeof===s||v.$$typeof===u||v.$$typeof===b||v.$$typeof===y||v.$$typeof===j||v.$$typeof===c)},we.typeOf=R,we}var Se={};/** @license React v16.13.1
9
9
  * react-is.development.js
10
10
  *
11
11
  * Copyright (c) Facebook, Inc. and its affiliates.
12
12
  *
13
13
  * This source code is licensed under the MIT license found in the
14
14
  * LICENSE file in the root directory of this source tree.
15
- */var yo;function Ou(){return yo||(yo=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,n=e?Symbol.for("react.fragment"):60107,i=e?Symbol.for("react.strict_mode"):60108,a=e?Symbol.for("react.profiler"):60114,o=e?Symbol.for("react.provider"):60109,s=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,p=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,f=e?Symbol.for("react.suspense_list"):60120,y=e?Symbol.for("react.memo"):60115,S=e?Symbol.for("react.lazy"):60116,c=e?Symbol.for("react.block"):60121,b=e?Symbol.for("react.fundamental"):60117,g=e?Symbol.for("react.responder"):60118,O=e?Symbol.for("react.scope"):60119;function A(I){return typeof I=="string"||typeof I=="function"||I===n||I===p||I===a||I===i||I===d||I===f||typeof I=="object"&&I!==null&&(I.$$typeof===S||I.$$typeof===y||I.$$typeof===o||I.$$typeof===s||I.$$typeof===u||I.$$typeof===b||I.$$typeof===g||I.$$typeof===O||I.$$typeof===c)}function k(I){if(typeof I=="object"&&I!==null){var z=I.$$typeof;switch(z){case t:var ae=I.type;switch(ae){case l:case p:case n:case a:case i:case d:return ae;default:var de=ae&&ae.$$typeof;switch(de){case s:case u:case S:case y:case o:return de;default:return z}}case r:return z}}}var x=l,B=p,_=s,K=o,W=t,h=u,M=n,P=S,q=y,N=r,X=a,ie=i,ge=d,ce=!1;function se(I){return ce||(ce=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),V(I)||k(I)===l}function V(I){return k(I)===p}function H(I){return k(I)===s}function ue(I){return k(I)===o}function Y(I){return typeof I=="object"&&I!==null&&I.$$typeof===t}function te(I){return k(I)===u}function le(I){return k(I)===n}function U(I){return k(I)===S}function ee(I){return k(I)===y}function oe(I){return k(I)===r}function fe(I){return k(I)===a}function pe(I){return k(I)===i}function L(I){return k(I)===d}we.AsyncMode=x,we.ConcurrentMode=B,we.ContextConsumer=_,we.ContextProvider=K,we.Element=W,we.ForwardRef=h,we.Fragment=M,we.Lazy=P,we.Memo=q,we.Portal=N,we.Profiler=X,we.StrictMode=ie,we.Suspense=ge,we.isAsyncMode=se,we.isConcurrentMode=V,we.isContextConsumer=H,we.isContextProvider=ue,we.isElement=Y,we.isForwardRef=te,we.isFragment=le,we.isLazy=U,we.isMemo=ee,we.isPortal=oe,we.isProfiler=fe,we.isStrictMode=pe,we.isSuspense=L,we.isValidElementType=A,we.typeOf=k}()),we}var xo;function ol(){return xo||(xo=1,process.env.NODE_ENV==="production"?An.exports=Tu():An.exports=Ou()),An.exports}/*
15
+ */var bo;function Ou(){return bo||(bo=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,n=e?Symbol.for("react.fragment"):60107,i=e?Symbol.for("react.strict_mode"):60108,a=e?Symbol.for("react.profiler"):60114,o=e?Symbol.for("react.provider"):60109,s=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,p=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,f=e?Symbol.for("react.suspense_list"):60120,g=e?Symbol.for("react.memo"):60115,S=e?Symbol.for("react.lazy"):60116,c=e?Symbol.for("react.block"):60121,b=e?Symbol.for("react.fundamental"):60117,y=e?Symbol.for("react.responder"):60118,j=e?Symbol.for("react.scope"):60119;function R(_){return typeof _=="string"||typeof _=="function"||_===n||_===p||_===a||_===i||_===d||_===f||typeof _=="object"&&_!==null&&(_.$$typeof===S||_.$$typeof===g||_.$$typeof===o||_.$$typeof===s||_.$$typeof===u||_.$$typeof===b||_.$$typeof===y||_.$$typeof===j||_.$$typeof===c)}function k(_){if(typeof _=="object"&&_!==null){var Q=_.$$typeof;switch(Q){case t:var fe=_.type;switch(fe){case l:case p:case n:case a:case i:case d:return fe;default:var xe=fe&&fe.$$typeof;switch(xe){case s:case u:case S:case g:case o:return xe;default:return Q}}case r:return Q}}}var v=l,B=p,A=s,H=o,U=t,h=u,z=n,M=S,q=g,N=r,J=a,ae=i,he=d,ie=!1;function oe(_){return ie||(ie=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),V(_)||k(_)===l}function V(_){return k(_)===p}function W(_){return k(_)===s}function ce(_){return k(_)===o}function me(_){return typeof _=="object"&&_!==null&&_.$$typeof===t}function se(_){return k(_)===u}function L(_){return k(_)===n}function X(_){return k(_)===S}function ne(_){return k(_)===g}function ue(_){return k(_)===r}function de(_){return k(_)===a}function pe(_){return k(_)===i}function D(_){return k(_)===d}Se.AsyncMode=v,Se.ConcurrentMode=B,Se.ContextConsumer=A,Se.ContextProvider=H,Se.Element=U,Se.ForwardRef=h,Se.Fragment=z,Se.Lazy=M,Se.Memo=q,Se.Portal=N,Se.Profiler=J,Se.StrictMode=ae,Se.Suspense=he,Se.isAsyncMode=oe,Se.isConcurrentMode=V,Se.isContextConsumer=W,Se.isContextProvider=ce,Se.isElement=me,Se.isForwardRef=se,Se.isFragment=L,Se.isLazy=X,Se.isMemo=ne,Se.isPortal=ue,Se.isProfiler=de,Se.isStrictMode=pe,Se.isSuspense=D,Se.isValidElementType=R,Se.typeOf=k}()),Se}var wo;function cl(){return wo||(wo=1,process.env.NODE_ENV==="production"?_n.exports=Tu():_n.exports=Ou()),_n.exports}/*
16
16
  object-assign
17
17
  (c) Sindre Sorhus
18
18
  @license MIT
19
- */var Ci,vo;function ju(){if(vo)return Ci;vo=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,r=Object.prototype.propertyIsEnumerable;function n(a){if(a==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(a)}function i(){try{if(!Object.assign)return!1;var a=new String("abc");if(a[5]="de",Object.getOwnPropertyNames(a)[0]==="5")return!1;for(var o={},s=0;s<10;s++)o["_"+String.fromCharCode(s)]=s;var l=Object.getOwnPropertyNames(o).map(function(u){return o[u]});if(l.join("")!=="0123456789")return!1;var p={};return"abcdefghijklmnopqrst".split("").forEach(function(u){p[u]=u}),Object.keys(Object.assign({},p)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return Ci=i()?Object.assign:function(a,o){for(var s,l=n(a),p,u=1;u<arguments.length;u++){s=Object(arguments[u]);for(var d in s)t.call(s,d)&&(l[d]=s[d]);if(e){p=e(s);for(var f=0;f<p.length;f++)r.call(s,p[f])&&(l[p[f]]=s[p[f]])}}return l},Ci}var Ei,bo;function ja(){if(bo)return Ei;bo=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return Ei=e,Ei}var ki,wo;function sl(){return wo||(wo=1,ki=Function.call.bind(Object.prototype.hasOwnProperty)),ki}var Ti,So;function Fu(){if(So)return Ti;So=1;var e=function(){};if(process.env.NODE_ENV!=="production"){var t=ja(),r={},n=sl();e=function(a){var o="Warning: "+a;typeof console<"u"&&console.error(o);try{throw new Error(o)}catch{}}}function i(a,o,s,l,p){if(process.env.NODE_ENV!=="production"){for(var u in a)if(n(a,u)){var d;try{if(typeof a[u]!="function"){var f=Error((l||"React class")+": "+s+" type `"+u+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof a[u]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw f.name="Invariant Violation",f}d=a[u](o,u,l,s,null,t)}catch(S){d=S}if(d&&!(d instanceof Error)&&e((l||"React class")+": type specification of "+s+" `"+u+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof d+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),d instanceof Error&&!(d.message in r)){r[d.message]=!0;var y=p?p():"";e("Failed "+s+" type: "+d.message+(y??""))}}}}return i.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(r={})},Ti=i,Ti}var Oi,Co;function _u(){if(Co)return Oi;Co=1;var e=ol(),t=ju(),r=ja(),n=sl(),i=Fu(),a=function(){};process.env.NODE_ENV!=="production"&&(a=function(s){var l="Warning: "+s;typeof console<"u"&&console.error(l);try{throw new Error(l)}catch{}});function o(){return null}return Oi=function(s,l){var p=typeof Symbol=="function"&&Symbol.iterator,u="@@iterator";function d(V){var H=V&&(p&&V[p]||V[u]);if(typeof H=="function")return H}var f="<<anonymous>>",y={array:g("array"),bigint:g("bigint"),bool:g("boolean"),func:g("function"),number:g("number"),object:g("object"),string:g("string"),symbol:g("symbol"),any:O(),arrayOf:A,element:k(),elementType:x(),instanceOf:B,node:h(),objectOf:K,oneOf:_,oneOfType:W,shape:P,exact:q};function S(V,H){return V===H?V!==0||1/V===1/H:V!==V&&H!==H}function c(V,H){this.message=V,this.data=H&&typeof H=="object"?H:{},this.stack=""}c.prototype=Error.prototype;function b(V){if(process.env.NODE_ENV!=="production")var H={},ue=0;function Y(le,U,ee,oe,fe,pe,L){if(oe=oe||f,pe=pe||ee,L!==r){if(l){var I=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");throw I.name="Invariant Violation",I}else if(process.env.NODE_ENV!=="production"&&typeof console<"u"){var z=oe+":"+ee;!H[z]&&ue<3&&(a("You are manually calling a React.PropTypes validation function for the `"+pe+"` prop on `"+oe+"`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."),H[z]=!0,ue++)}}return U[ee]==null?le?U[ee]===null?new c("The "+fe+" `"+pe+"` is marked as required "+("in `"+oe+"`, but its value is `null`.")):new c("The "+fe+" `"+pe+"` is marked as required in "+("`"+oe+"`, but its value is `undefined`.")):null:V(U,ee,oe,fe,pe)}var te=Y.bind(null,!1);return te.isRequired=Y.bind(null,!0),te}function g(V){function H(ue,Y,te,le,U,ee){var oe=ue[Y],fe=ie(oe);if(fe!==V){var pe=ge(oe);return new c("Invalid "+le+" `"+U+"` of type "+("`"+pe+"` supplied to `"+te+"`, expected ")+("`"+V+"`."),{expectedType:V})}return null}return b(H)}function O(){return b(o)}function A(V){function H(ue,Y,te,le,U){if(typeof V!="function")return new c("Property `"+U+"` of component `"+te+"` has invalid PropType notation inside arrayOf.");var ee=ue[Y];if(!Array.isArray(ee)){var oe=ie(ee);return new c("Invalid "+le+" `"+U+"` of type "+("`"+oe+"` supplied to `"+te+"`, expected an array."))}for(var fe=0;fe<ee.length;fe++){var pe=V(ee,fe,te,le,U+"["+fe+"]",r);if(pe instanceof Error)return pe}return null}return b(H)}function k(){function V(H,ue,Y,te,le){var U=H[ue];if(!s(U)){var ee=ie(U);return new c("Invalid "+te+" `"+le+"` of type "+("`"+ee+"` supplied to `"+Y+"`, expected a single ReactElement."))}return null}return b(V)}function x(){function V(H,ue,Y,te,le){var U=H[ue];if(!e.isValidElementType(U)){var ee=ie(U);return new c("Invalid "+te+" `"+le+"` of type "+("`"+ee+"` supplied to `"+Y+"`, expected a single ReactElement type."))}return null}return b(V)}function B(V){function H(ue,Y,te,le,U){if(!(ue[Y]instanceof V)){var ee=V.name||f,oe=se(ue[Y]);return new c("Invalid "+le+" `"+U+"` of type "+("`"+oe+"` supplied to `"+te+"`, expected ")+("instance of `"+ee+"`."))}return null}return b(H)}function _(V){if(!Array.isArray(V))return process.env.NODE_ENV!=="production"&&(arguments.length>1?a("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):a("Invalid argument supplied to oneOf, expected an array.")),o;function H(ue,Y,te,le,U){for(var ee=ue[Y],oe=0;oe<V.length;oe++)if(S(ee,V[oe]))return null;var fe=JSON.stringify(V,function(L,I){var z=ge(I);return z==="symbol"?String(I):I});return new c("Invalid "+le+" `"+U+"` of value `"+String(ee)+"` "+("supplied to `"+te+"`, expected one of "+fe+"."))}return b(H)}function K(V){function H(ue,Y,te,le,U){if(typeof V!="function")return new c("Property `"+U+"` of component `"+te+"` has invalid PropType notation inside objectOf.");var ee=ue[Y],oe=ie(ee);if(oe!=="object")return new c("Invalid "+le+" `"+U+"` of type "+("`"+oe+"` supplied to `"+te+"`, expected an object."));for(var fe in ee)if(n(ee,fe)){var pe=V(ee,fe,te,le,U+"."+fe,r);if(pe instanceof Error)return pe}return null}return b(H)}function W(V){if(!Array.isArray(V))return process.env.NODE_ENV!=="production"&&a("Invalid argument supplied to oneOfType, expected an instance of array."),o;for(var H=0;H<V.length;H++){var ue=V[H];if(typeof ue!="function")return a("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+ce(ue)+" at index "+H+"."),o}function Y(te,le,U,ee,oe){for(var fe=[],pe=0;pe<V.length;pe++){var L=V[pe],I=L(te,le,U,ee,oe,r);if(I==null)return null;I.data&&n(I.data,"expectedType")&&fe.push(I.data.expectedType)}var z=fe.length>0?", expected one of type ["+fe.join(", ")+"]":"";return new c("Invalid "+ee+" `"+oe+"` supplied to "+("`"+U+"`"+z+"."))}return b(Y)}function h(){function V(H,ue,Y,te,le){return N(H[ue])?null:new c("Invalid "+te+" `"+le+"` supplied to "+("`"+Y+"`, expected a ReactNode."))}return b(V)}function M(V,H,ue,Y,te){return new c((V||"React class")+": "+H+" type `"+ue+"."+Y+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+te+"`.")}function P(V){function H(ue,Y,te,le,U){var ee=ue[Y],oe=ie(ee);if(oe!=="object")return new c("Invalid "+le+" `"+U+"` of type `"+oe+"` "+("supplied to `"+te+"`, expected `object`."));for(var fe in V){var pe=V[fe];if(typeof pe!="function")return M(te,le,U,fe,ge(pe));var L=pe(ee,fe,te,le,U+"."+fe,r);if(L)return L}return null}return b(H)}function q(V){function H(ue,Y,te,le,U){var ee=ue[Y],oe=ie(ee);if(oe!=="object")return new c("Invalid "+le+" `"+U+"` of type `"+oe+"` "+("supplied to `"+te+"`, expected `object`."));var fe=t({},ue[Y],V);for(var pe in fe){var L=V[pe];if(n(V,pe)&&typeof L!="function")return M(te,le,U,pe,ge(L));if(!L)return new c("Invalid "+le+" `"+U+"` key `"+pe+"` supplied to `"+te+"`.\nBad object: "+JSON.stringify(ue[Y],null," ")+`
20
- Valid keys: `+JSON.stringify(Object.keys(V),null," "));var I=L(ee,pe,te,le,U+"."+pe,r);if(I)return I}return null}return b(H)}function N(V){switch(typeof V){case"number":case"string":case"undefined":return!0;case"boolean":return!V;case"object":if(Array.isArray(V))return V.every(N);if(V===null||s(V))return!0;var H=d(V);if(H){var ue=H.call(V),Y;if(H!==V.entries){for(;!(Y=ue.next()).done;)if(!N(Y.value))return!1}else for(;!(Y=ue.next()).done;){var te=Y.value;if(te&&!N(te[1]))return!1}}else return!1;return!0;default:return!1}}function X(V,H){return V==="symbol"?!0:H?H["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&H instanceof Symbol:!1}function ie(V){var H=typeof V;return Array.isArray(V)?"array":V instanceof RegExp?"object":X(H,V)?"symbol":H}function ge(V){if(typeof V>"u"||V===null)return""+V;var H=ie(V);if(H==="object"){if(V instanceof Date)return"date";if(V instanceof RegExp)return"regexp"}return H}function ce(V){var H=ge(V);switch(H){case"array":case"object":return"an "+H;case"boolean":case"date":case"regexp":return"a "+H;default:return H}}function se(V){return!V.constructor||!V.constructor.name?f:V.constructor.name}return y.checkPropTypes=i,y.resetWarningCache=i.resetWarningCache,y.PropTypes=y,y},Oi}var ji,Eo;function Au(){if(Eo)return ji;Eo=1;var e=ja();function t(){}function r(){}return r.resetWarningCache=t,ji=function(){function n(o,s,l,p,u,d){if(d!==e){var f=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw f.name="Invariant Violation",f}}n.isRequired=n;function i(){return n}var a={array:n,bigint:n,bool:n,func:n,number:n,object:n,string:n,symbol:n,any:n,arrayOf:i,element:n,elementType:n,instanceOf:i,node:n,objectOf:i,oneOf:i,oneOfType:i,shape:i,exact:i,checkPropTypes:r,resetWarningCache:t};return a.PropTypes=a,a},ji}var ko;function Ru(){if(ko)return _n.exports;if(ko=1,process.env.NODE_ENV!=="production"){var e=ol(),t=!0;_n.exports=_u()(e.isElement,t)}else _n.exports=Au()();return _n.exports}var $u=Ru();const w=Oa($u);function ll(e){var t,r,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(r=ll(e[t]))&&(n&&(n+=" "),n+=r)}else for(r in e)e[r]&&(n&&(n+=" "),n+=r);return n}function Ke(){for(var e,t,r=0,n="",i=arguments.length;r<i;r++)(e=arguments[r])&&(t=ll(e))&&(n&&(n+=" "),n+=t);return n}function Xr(e,t,r=void 0){const n={};for(const i in e){const a=e[i];let o="",s=!0;for(let l=0;l<a.length;l+=1){const p=a[l];p&&(o+=(s===!0?"":" ")+t(p),s=!1,r&&r[p]&&(o+=" "+r[p]))}n[i]=o}return n}function er(e,...t){const r=new URL(`https://mui.com/production-error/?code=${e}`);return t.forEach(n=>r.searchParams.append("args[]",n)),`Minified MUI error #${e}; visit ${r} for the full message.`}function Re(e){if(typeof e!="string")throw new Error(process.env.NODE_ENV!=="production"?"MUI: `capitalize(string)` expects a string argument.":er(7));return e.charAt(0).toUpperCase()+e.slice(1)}var Rn={exports:{}},Ee={};/**
19
+ */var Ci,So;function ju(){if(So)return Ci;So=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,r=Object.prototype.propertyIsEnumerable;function n(a){if(a==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(a)}function i(){try{if(!Object.assign)return!1;var a=new String("abc");if(a[5]="de",Object.getOwnPropertyNames(a)[0]==="5")return!1;for(var o={},s=0;s<10;s++)o["_"+String.fromCharCode(s)]=s;var l=Object.getOwnPropertyNames(o).map(function(u){return o[u]});if(l.join("")!=="0123456789")return!1;var p={};return"abcdefghijklmnopqrst".split("").forEach(function(u){p[u]=u}),Object.keys(Object.assign({},p)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return Ci=i()?Object.assign:function(a,o){for(var s,l=n(a),p,u=1;u<arguments.length;u++){s=Object(arguments[u]);for(var d in s)t.call(s,d)&&(l[d]=s[d]);if(e){p=e(s);for(var f=0;f<p.length;f++)r.call(s,p[f])&&(l[p[f]]=s[p[f]])}}return l},Ci}var Ei,Co;function _a(){if(Co)return Ei;Co=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return Ei=e,Ei}var ki,Eo;function ul(){return Eo||(Eo=1,ki=Function.call.bind(Object.prototype.hasOwnProperty)),ki}var Ti,ko;function Fu(){if(ko)return Ti;ko=1;var e=function(){};if(process.env.NODE_ENV!=="production"){var t=_a(),r={},n=ul();e=function(a){var o="Warning: "+a;typeof console<"u"&&console.error(o);try{throw new Error(o)}catch{}}}function i(a,o,s,l,p){if(process.env.NODE_ENV!=="production"){for(var u in a)if(n(a,u)){var d;try{if(typeof a[u]!="function"){var f=Error((l||"React class")+": "+s+" type `"+u+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof a[u]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw f.name="Invariant Violation",f}d=a[u](o,u,l,s,null,t)}catch(S){d=S}if(d&&!(d instanceof Error)&&e((l||"React class")+": type specification of "+s+" `"+u+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof d+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),d instanceof Error&&!(d.message in r)){r[d.message]=!0;var g=p?p():"";e("Failed "+s+" type: "+d.message+(g??""))}}}}return i.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(r={})},Ti=i,Ti}var Oi,To;function Au(){if(To)return Oi;To=1;var e=cl(),t=ju(),r=_a(),n=ul(),i=Fu(),a=function(){};process.env.NODE_ENV!=="production"&&(a=function(s){var l="Warning: "+s;typeof console<"u"&&console.error(l);try{throw new Error(l)}catch{}});function o(){return null}return Oi=function(s,l){var p=typeof Symbol=="function"&&Symbol.iterator,u="@@iterator";function d(V){var W=V&&(p&&V[p]||V[u]);if(typeof W=="function")return W}var f="<<anonymous>>",g={array:y("array"),bigint:y("bigint"),bool:y("boolean"),func:y("function"),number:y("number"),object:y("object"),string:y("string"),symbol:y("symbol"),any:j(),arrayOf:R,element:k(),elementType:v(),instanceOf:B,node:h(),objectOf:H,oneOf:A,oneOfType:U,shape:M,exact:q};function S(V,W){return V===W?V!==0||1/V===1/W:V!==V&&W!==W}function c(V,W){this.message=V,this.data=W&&typeof W=="object"?W:{},this.stack=""}c.prototype=Error.prototype;function b(V){if(process.env.NODE_ENV!=="production")var W={},ce=0;function me(L,X,ne,ue,de,pe,D){if(ue=ue||f,pe=pe||ne,D!==r){if(l){var _=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");throw _.name="Invariant Violation",_}else if(process.env.NODE_ENV!=="production"&&typeof console<"u"){var Q=ue+":"+ne;!W[Q]&&ce<3&&(a("You are manually calling a React.PropTypes validation function for the `"+pe+"` prop on `"+ue+"`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."),W[Q]=!0,ce++)}}return X[ne]==null?L?X[ne]===null?new c("The "+de+" `"+pe+"` is marked as required "+("in `"+ue+"`, but its value is `null`.")):new c("The "+de+" `"+pe+"` is marked as required in "+("`"+ue+"`, but its value is `undefined`.")):null:V(X,ne,ue,de,pe)}var se=me.bind(null,!1);return se.isRequired=me.bind(null,!0),se}function y(V){function W(ce,me,se,L,X,ne){var ue=ce[me],de=ae(ue);if(de!==V){var pe=he(ue);return new c("Invalid "+L+" `"+X+"` of type "+("`"+pe+"` supplied to `"+se+"`, expected ")+("`"+V+"`."),{expectedType:V})}return null}return b(W)}function j(){return b(o)}function R(V){function W(ce,me,se,L,X){if(typeof V!="function")return new c("Property `"+X+"` of component `"+se+"` has invalid PropType notation inside arrayOf.");var ne=ce[me];if(!Array.isArray(ne)){var ue=ae(ne);return new c("Invalid "+L+" `"+X+"` of type "+("`"+ue+"` supplied to `"+se+"`, expected an array."))}for(var de=0;de<ne.length;de++){var pe=V(ne,de,se,L,X+"["+de+"]",r);if(pe instanceof Error)return pe}return null}return b(W)}function k(){function V(W,ce,me,se,L){var X=W[ce];if(!s(X)){var ne=ae(X);return new c("Invalid "+se+" `"+L+"` of type "+("`"+ne+"` supplied to `"+me+"`, expected a single ReactElement."))}return null}return b(V)}function v(){function V(W,ce,me,se,L){var X=W[ce];if(!e.isValidElementType(X)){var ne=ae(X);return new c("Invalid "+se+" `"+L+"` of type "+("`"+ne+"` supplied to `"+me+"`, expected a single ReactElement type."))}return null}return b(V)}function B(V){function W(ce,me,se,L,X){if(!(ce[me]instanceof V)){var ne=V.name||f,ue=oe(ce[me]);return new c("Invalid "+L+" `"+X+"` of type "+("`"+ue+"` supplied to `"+se+"`, expected ")+("instance of `"+ne+"`."))}return null}return b(W)}function A(V){if(!Array.isArray(V))return process.env.NODE_ENV!=="production"&&(arguments.length>1?a("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):a("Invalid argument supplied to oneOf, expected an array.")),o;function W(ce,me,se,L,X){for(var ne=ce[me],ue=0;ue<V.length;ue++)if(S(ne,V[ue]))return null;var de=JSON.stringify(V,function(D,_){var Q=he(_);return Q==="symbol"?String(_):_});return new c("Invalid "+L+" `"+X+"` of value `"+String(ne)+"` "+("supplied to `"+se+"`, expected one of "+de+"."))}return b(W)}function H(V){function W(ce,me,se,L,X){if(typeof V!="function")return new c("Property `"+X+"` of component `"+se+"` has invalid PropType notation inside objectOf.");var ne=ce[me],ue=ae(ne);if(ue!=="object")return new c("Invalid "+L+" `"+X+"` of type "+("`"+ue+"` supplied to `"+se+"`, expected an object."));for(var de in ne)if(n(ne,de)){var pe=V(ne,de,se,L,X+"."+de,r);if(pe instanceof Error)return pe}return null}return b(W)}function U(V){if(!Array.isArray(V))return process.env.NODE_ENV!=="production"&&a("Invalid argument supplied to oneOfType, expected an instance of array."),o;for(var W=0;W<V.length;W++){var ce=V[W];if(typeof ce!="function")return a("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+ie(ce)+" at index "+W+"."),o}function me(se,L,X,ne,ue){for(var de=[],pe=0;pe<V.length;pe++){var D=V[pe],_=D(se,L,X,ne,ue,r);if(_==null)return null;_.data&&n(_.data,"expectedType")&&de.push(_.data.expectedType)}var Q=de.length>0?", expected one of type ["+de.join(", ")+"]":"";return new c("Invalid "+ne+" `"+ue+"` supplied to "+("`"+X+"`"+Q+"."))}return b(me)}function h(){function V(W,ce,me,se,L){return N(W[ce])?null:new c("Invalid "+se+" `"+L+"` supplied to "+("`"+me+"`, expected a ReactNode."))}return b(V)}function z(V,W,ce,me,se){return new c((V||"React class")+": "+W+" type `"+ce+"."+me+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+se+"`.")}function M(V){function W(ce,me,se,L,X){var ne=ce[me],ue=ae(ne);if(ue!=="object")return new c("Invalid "+L+" `"+X+"` of type `"+ue+"` "+("supplied to `"+se+"`, expected `object`."));for(var de in V){var pe=V[de];if(typeof pe!="function")return z(se,L,X,de,he(pe));var D=pe(ne,de,se,L,X+"."+de,r);if(D)return D}return null}return b(W)}function q(V){function W(ce,me,se,L,X){var ne=ce[me],ue=ae(ne);if(ue!=="object")return new c("Invalid "+L+" `"+X+"` of type `"+ue+"` "+("supplied to `"+se+"`, expected `object`."));var de=t({},ce[me],V);for(var pe in de){var D=V[pe];if(n(V,pe)&&typeof D!="function")return z(se,L,X,pe,he(D));if(!D)return new c("Invalid "+L+" `"+X+"` key `"+pe+"` supplied to `"+se+"`.\nBad object: "+JSON.stringify(ce[me],null," ")+`
20
+ Valid keys: `+JSON.stringify(Object.keys(V),null," "));var _=D(ne,pe,se,L,X+"."+pe,r);if(_)return _}return null}return b(W)}function N(V){switch(typeof V){case"number":case"string":case"undefined":return!0;case"boolean":return!V;case"object":if(Array.isArray(V))return V.every(N);if(V===null||s(V))return!0;var W=d(V);if(W){var ce=W.call(V),me;if(W!==V.entries){for(;!(me=ce.next()).done;)if(!N(me.value))return!1}else for(;!(me=ce.next()).done;){var se=me.value;if(se&&!N(se[1]))return!1}}else return!1;return!0;default:return!1}}function J(V,W){return V==="symbol"?!0:W?W["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&W instanceof Symbol:!1}function ae(V){var W=typeof V;return Array.isArray(V)?"array":V instanceof RegExp?"object":J(W,V)?"symbol":W}function he(V){if(typeof V>"u"||V===null)return""+V;var W=ae(V);if(W==="object"){if(V instanceof Date)return"date";if(V instanceof RegExp)return"regexp"}return W}function ie(V){var W=he(V);switch(W){case"array":case"object":return"an "+W;case"boolean":case"date":case"regexp":return"a "+W;default:return W}}function oe(V){return!V.constructor||!V.constructor.name?f:V.constructor.name}return g.checkPropTypes=i,g.resetWarningCache=i.resetWarningCache,g.PropTypes=g,g},Oi}var ji,Oo;function _u(){if(Oo)return ji;Oo=1;var e=_a();function t(){}function r(){}return r.resetWarningCache=t,ji=function(){function n(o,s,l,p,u,d){if(d!==e){var f=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw f.name="Invariant Violation",f}}n.isRequired=n;function i(){return n}var a={array:n,bigint:n,bool:n,func:n,number:n,object:n,string:n,symbol:n,any:n,arrayOf:i,element:n,elementType:n,instanceOf:i,node:n,objectOf:i,oneOf:i,oneOfType:i,shape:i,exact:i,checkPropTypes:r,resetWarningCache:t};return a.PropTypes=a,a},ji}var jo;function Ru(){if(jo)return An.exports;if(jo=1,process.env.NODE_ENV!=="production"){var e=cl(),t=!0;An.exports=Au()(e.isElement,t)}else An.exports=_u()();return An.exports}var $u=Ru();const w=Aa($u);function pl(e){var t,r,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(r=pl(e[t]))&&(n&&(n+=" "),n+=r)}else for(r in e)e[r]&&(n&&(n+=" "),n+=r);return n}function Ye(){for(var e,t,r=0,n="",i=arguments.length;r<i;r++)(e=arguments[r])&&(t=pl(e))&&(n&&(n+=" "),n+=t);return n}function Xr(e,t,r=void 0){const n={};for(const i in e){const a=e[i];let o="",s=!0;for(let l=0;l<a.length;l+=1){const p=a[l];p&&(o+=(s===!0?"":" ")+t(p),s=!1,r&&r[p]&&(o+=" "+r[p]))}n[i]=o}return n}function er(e,...t){const r=new URL(`https://mui.com/production-error/?code=${e}`);return t.forEach(n=>r.searchParams.append("args[]",n)),`Minified MUI error #${e}; visit ${r} for the full message.`}function Re(e){if(typeof e!="string")throw new Error(process.env.NODE_ENV!=="production"?"MUI: `capitalize(string)` expects a string argument.":er(7));return e.charAt(0).toUpperCase()+e.slice(1)}var Rn={exports:{}},ke={};/**
21
21
  * @license React
22
22
  * react-is.production.js
23
23
  *
@@ -25,7 +25,7 @@ Valid keys: `+JSON.stringify(Object.keys(V),null," "));var I=L(ee,pe,te,le,U+".
25
25
  *
26
26
  * This source code is licensed under the MIT license found in the
27
27
  * LICENSE file in the root directory of this source tree.
28
- */var To;function Du(){if(To)return Ee;To=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),a=Symbol.for("react.consumer"),o=Symbol.for("react.context"),s=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),p=Symbol.for("react.suspense_list"),u=Symbol.for("react.memo"),d=Symbol.for("react.lazy"),f=Symbol.for("react.view_transition"),y=Symbol.for("react.client.reference");function S(c){if(typeof c=="object"&&c!==null){var b=c.$$typeof;switch(b){case e:switch(c=c.type,c){case r:case i:case n:case l:case p:case f:return c;default:switch(c=c&&c.$$typeof,c){case o:case s:case d:case u:return c;case a:return c;default:return b}}case t:return b}}}return Ee.ContextConsumer=a,Ee.ContextProvider=o,Ee.Element=e,Ee.ForwardRef=s,Ee.Fragment=r,Ee.Lazy=d,Ee.Memo=u,Ee.Portal=t,Ee.Profiler=i,Ee.StrictMode=n,Ee.Suspense=l,Ee.SuspenseList=p,Ee.isContextConsumer=function(c){return S(c)===a},Ee.isContextProvider=function(c){return S(c)===o},Ee.isElement=function(c){return typeof c=="object"&&c!==null&&c.$$typeof===e},Ee.isForwardRef=function(c){return S(c)===s},Ee.isFragment=function(c){return S(c)===r},Ee.isLazy=function(c){return S(c)===d},Ee.isMemo=function(c){return S(c)===u},Ee.isPortal=function(c){return S(c)===t},Ee.isProfiler=function(c){return S(c)===i},Ee.isStrictMode=function(c){return S(c)===n},Ee.isSuspense=function(c){return S(c)===l},Ee.isSuspenseList=function(c){return S(c)===p},Ee.isValidElementType=function(c){return typeof c=="string"||typeof c=="function"||c===r||c===i||c===n||c===l||c===p||typeof c=="object"&&c!==null&&(c.$$typeof===d||c.$$typeof===u||c.$$typeof===o||c.$$typeof===a||c.$$typeof===s||c.$$typeof===y||c.getModuleId!==void 0)},Ee.typeOf=S,Ee}var ke={};/**
28
+ */var Fo;function Du(){if(Fo)return ke;Fo=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),a=Symbol.for("react.consumer"),o=Symbol.for("react.context"),s=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),p=Symbol.for("react.suspense_list"),u=Symbol.for("react.memo"),d=Symbol.for("react.lazy"),f=Symbol.for("react.view_transition"),g=Symbol.for("react.client.reference");function S(c){if(typeof c=="object"&&c!==null){var b=c.$$typeof;switch(b){case e:switch(c=c.type,c){case r:case i:case n:case l:case p:case f:return c;default:switch(c=c&&c.$$typeof,c){case o:case s:case d:case u:return c;case a:return c;default:return b}}case t:return b}}}return ke.ContextConsumer=a,ke.ContextProvider=o,ke.Element=e,ke.ForwardRef=s,ke.Fragment=r,ke.Lazy=d,ke.Memo=u,ke.Portal=t,ke.Profiler=i,ke.StrictMode=n,ke.Suspense=l,ke.SuspenseList=p,ke.isContextConsumer=function(c){return S(c)===a},ke.isContextProvider=function(c){return S(c)===o},ke.isElement=function(c){return typeof c=="object"&&c!==null&&c.$$typeof===e},ke.isForwardRef=function(c){return S(c)===s},ke.isFragment=function(c){return S(c)===r},ke.isLazy=function(c){return S(c)===d},ke.isMemo=function(c){return S(c)===u},ke.isPortal=function(c){return S(c)===t},ke.isProfiler=function(c){return S(c)===i},ke.isStrictMode=function(c){return S(c)===n},ke.isSuspense=function(c){return S(c)===l},ke.isSuspenseList=function(c){return S(c)===p},ke.isValidElementType=function(c){return typeof c=="string"||typeof c=="function"||c===r||c===i||c===n||c===l||c===p||typeof c=="object"&&c!==null&&(c.$$typeof===d||c.$$typeof===u||c.$$typeof===o||c.$$typeof===a||c.$$typeof===s||c.$$typeof===g||c.getModuleId!==void 0)},ke.typeOf=S,ke}var Te={};/**
29
29
  * @license React
30
30
  * react-is.development.js
31
31
  *
@@ -33,22 +33,22 @@ Valid keys: `+JSON.stringify(Object.keys(V),null," "));var I=L(ee,pe,te,le,U+".
33
33
  *
34
34
  * This source code is licensed under the MIT license found in the
35
35
  * LICENSE file in the root directory of this source tree.
36
- */var Oo;function Pu(){return Oo||(Oo=1,process.env.NODE_ENV!=="production"&&function(){function e(c){if(typeof c=="object"&&c!==null){var b=c.$$typeof;switch(b){case t:switch(c=c.type,c){case n:case a:case i:case p:case u:case y:return c;default:switch(c=c&&c.$$typeof,c){case s:case l:case f:case d:return c;case o:return c;default:return b}}case r:return b}}}var t=Symbol.for("react.transitional.element"),r=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),i=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),o=Symbol.for("react.consumer"),s=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),p=Symbol.for("react.suspense"),u=Symbol.for("react.suspense_list"),d=Symbol.for("react.memo"),f=Symbol.for("react.lazy"),y=Symbol.for("react.view_transition"),S=Symbol.for("react.client.reference");ke.ContextConsumer=o,ke.ContextProvider=s,ke.Element=t,ke.ForwardRef=l,ke.Fragment=n,ke.Lazy=f,ke.Memo=d,ke.Portal=r,ke.Profiler=a,ke.StrictMode=i,ke.Suspense=p,ke.SuspenseList=u,ke.isContextConsumer=function(c){return e(c)===o},ke.isContextProvider=function(c){return e(c)===s},ke.isElement=function(c){return typeof c=="object"&&c!==null&&c.$$typeof===t},ke.isForwardRef=function(c){return e(c)===l},ke.isFragment=function(c){return e(c)===n},ke.isLazy=function(c){return e(c)===f},ke.isMemo=function(c){return e(c)===d},ke.isPortal=function(c){return e(c)===r},ke.isProfiler=function(c){return e(c)===a},ke.isStrictMode=function(c){return e(c)===i},ke.isSuspense=function(c){return e(c)===p},ke.isSuspenseList=function(c){return e(c)===u},ke.isValidElementType=function(c){return typeof c=="string"||typeof c=="function"||c===n||c===a||c===i||c===p||c===u||typeof c=="object"&&c!==null&&(c.$$typeof===f||c.$$typeof===d||c.$$typeof===s||c.$$typeof===o||c.$$typeof===l||c.$$typeof===S||c.getModuleId!==void 0)},ke.typeOf=e}()),ke}var jo;function Iu(){return jo||(jo=1,process.env.NODE_ENV==="production"?Rn.exports=Du():Rn.exports=Pu()),Rn.exports}var Zn=Iu();function Ot(e){if(typeof e!="object"||e===null)return!1;const t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function cl(e){if(ne.isValidElement(e)||Zn.isValidElementType(e)||!Ot(e))return e;const t={};return Object.keys(e).forEach(r=>{t[r]=cl(e[r])}),t}function it(e,t,r={clone:!0}){const n=r.clone?{...e}:e;return Ot(e)&&Ot(t)&&Object.keys(t).forEach(i=>{ne.isValidElement(t[i])||Zn.isValidElementType(t[i])?n[i]=t[i]:Ot(t[i])&&Object.prototype.hasOwnProperty.call(e,i)&&Ot(e[i])?n[i]=it(e[i],t[i],r):r.clone?n[i]=Ot(t[i])?cl(t[i]):t[i]:n[i]=t[i]}),n}function fn(e,t){return t?it(e,t,{clone:!1}):e}const rr=process.env.NODE_ENV!=="production"?w.oneOfType([w.number,w.string,w.object,w.array]):{};function Mu(e,t){if(!e.containerQueries)return t;const r=Object.keys(t).filter(n=>n.startsWith("@container")).sort((n,i)=>{var o,s;const a=/min-width:\s*([0-9.]+)/;return+(((o=n.match(a))==null?void 0:o[1])||0)-+(((s=i.match(a))==null?void 0:s[1])||0)});return r.length?r.reduce((n,i)=>{const a=t[i];return delete n[i],n[i]=a,n},{...t}):t}function zu(e,t){return t==="@"||t.startsWith("@")&&(e.some(r=>t.startsWith(`@${r}`))||!!t.match(/^@\d/))}function Vu(e,t){const r=t.match(/^@([^/]+)?\/?(.+)?$/);if(!r){if(process.env.NODE_ENV!=="production")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The provided shorthand ${`(${t})`} is invalid. The format should be \`@<breakpoint | number>\` or \`@<breakpoint | number>/<container>\`.
37
- For example, \`@sm\` or \`@600\` or \`@40rem/sidebar\`.`:er(18,`(${t})`));return null}const[,n,i]=r,a=Number.isNaN(+n)?n||0:+n;return e.containerQueries(i).up(a)}function Bu(e){const t=(a,o)=>a.replace("@media",o?`@container ${o}`:"@container");function r(a,o){a.up=(...s)=>t(e.breakpoints.up(...s),o),a.down=(...s)=>t(e.breakpoints.down(...s),o),a.between=(...s)=>t(e.breakpoints.between(...s),o),a.only=(...s)=>t(e.breakpoints.only(...s),o),a.not=(...s)=>{const l=t(e.breakpoints.not(...s),o);return l.includes("not all and")?l.replace("not all and ","").replace("min-width:","width<").replace("max-width:","width>").replace("and","or"):l}}const n={},i=a=>(r(n,a),n);return r(i),{...e,containerQueries:i}}const ui={xs:0,sm:600,md:900,lg:1200,xl:1536},Fo={keys:["xs","sm","md","lg","xl"],up:e=>`@media (min-width:${ui[e]}px)`},Nu={containerQueries:e=>({up:t=>{let r=typeof t=="number"?t:ui[t]||t;return typeof r=="number"&&(r=`${r}px`),e?`@container ${e} (min-width:${r})`:`@container (min-width:${r})`}})};function Mt(e,t,r){const n=e.theme||{};if(Array.isArray(t)){const a=n.breakpoints||Fo;return t.reduce((o,s,l)=>(o[a.up(a.keys[l])]=r(t[l]),o),{})}if(typeof t=="object"){const a=n.breakpoints||Fo;return Object.keys(t).reduce((o,s)=>{if(zu(a.keys,s)){const l=Vu(n.containerQueries?n:Nu,s);l&&(o[l]=r(t[s],s))}else if(Object.keys(a.values||ui).includes(s)){const l=a.up(s);o[l]=r(t[s],s)}else{const l=s;o[l]=t[l]}return o},{})}return r(t)}function Lu(e={}){var r;return((r=e.keys)==null?void 0:r.reduce((n,i)=>{const a=e.up(i);return n[a]={},n},{}))||{}}function qu(e,t){return e.reduce((r,n)=>{const i=r[n];return(!i||Object.keys(i).length===0)&&delete r[n],r},t)}function pi(e,t,r=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&r){const n=`vars.${t}`.split(".").reduce((i,a)=>i&&i[a]?i[a]:null,e);if(n!=null)return n}return t.split(".").reduce((n,i)=>n&&n[i]!=null?n[i]:null,e)}function Xn(e,t,r,n=r){let i;return typeof e=="function"?i=e(r):Array.isArray(e)?i=e[r]||n:i=pi(e,r)||n,t&&(i=t(i,n,e)),i}function ze(e){const{prop:t,cssProperty:r=e.prop,themeKey:n,transform:i}=e,a=o=>{if(o[t]==null)return null;const s=o[t],l=o.theme,p=pi(l,n)||{};return Mt(o,s,d=>{let f=Xn(p,i,d);return d===f&&typeof d=="string"&&(f=Xn(p,i,`${t}${d==="default"?"":Re(d)}`,d)),r===!1?f:{[r]:f}})};return a.propTypes=process.env.NODE_ENV!=="production"?{[t]:rr}:{},a.filterProps=[t],a}function Uu(e){const t={};return r=>(t[r]===void 0&&(t[r]=e(r)),t[r])}const Wu={m:"margin",p:"padding"},Hu={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},_o={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},Ku=Uu(e=>{if(e.length>2)if(_o[e])e=_o[e];else return[e];const[t,r]=e.split(""),n=Wu[t],i=Hu[r]||"";return Array.isArray(i)?i.map(a=>n+a):[n+i]}),di=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],fi=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],Qu=[...di,...fi];function En(e,t,r,n){const i=pi(e,t,!0)??r;return typeof i=="number"||typeof i=="string"?a=>typeof a=="string"?a:(process.env.NODE_ENV!=="production"&&typeof a!="number"&&console.error(`MUI: Expected ${n} argument to be a number or a string, got ${a}.`),typeof i=="string"?i.startsWith("var(")&&a===0?0:i.startsWith("var(")&&a===1?i:`calc(${a} * ${i})`:i*a):Array.isArray(i)?a=>{if(typeof a=="string")return a;const o=Math.abs(a);process.env.NODE_ENV!=="production"&&(Number.isInteger(o)?o>i.length-1&&console.error([`MUI: The value provided (${o}) overflows.`,`The supported values are: ${JSON.stringify(i)}.`,`${o} > ${i.length-1}, you need to add the missing values.`].join(`
36
+ */var Ao;function Pu(){return Ao||(Ao=1,process.env.NODE_ENV!=="production"&&function(){function e(c){if(typeof c=="object"&&c!==null){var b=c.$$typeof;switch(b){case t:switch(c=c.type,c){case n:case a:case i:case p:case u:case g:return c;default:switch(c=c&&c.$$typeof,c){case s:case l:case f:case d:return c;case o:return c;default:return b}}case r:return b}}}var t=Symbol.for("react.transitional.element"),r=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),i=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),o=Symbol.for("react.consumer"),s=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),p=Symbol.for("react.suspense"),u=Symbol.for("react.suspense_list"),d=Symbol.for("react.memo"),f=Symbol.for("react.lazy"),g=Symbol.for("react.view_transition"),S=Symbol.for("react.client.reference");Te.ContextConsumer=o,Te.ContextProvider=s,Te.Element=t,Te.ForwardRef=l,Te.Fragment=n,Te.Lazy=f,Te.Memo=d,Te.Portal=r,Te.Profiler=a,Te.StrictMode=i,Te.Suspense=p,Te.SuspenseList=u,Te.isContextConsumer=function(c){return e(c)===o},Te.isContextProvider=function(c){return e(c)===s},Te.isElement=function(c){return typeof c=="object"&&c!==null&&c.$$typeof===t},Te.isForwardRef=function(c){return e(c)===l},Te.isFragment=function(c){return e(c)===n},Te.isLazy=function(c){return e(c)===f},Te.isMemo=function(c){return e(c)===d},Te.isPortal=function(c){return e(c)===r},Te.isProfiler=function(c){return e(c)===a},Te.isStrictMode=function(c){return e(c)===i},Te.isSuspense=function(c){return e(c)===p},Te.isSuspenseList=function(c){return e(c)===u},Te.isValidElementType=function(c){return typeof c=="string"||typeof c=="function"||c===n||c===a||c===i||c===p||c===u||typeof c=="object"&&c!==null&&(c.$$typeof===f||c.$$typeof===d||c.$$typeof===s||c.$$typeof===o||c.$$typeof===l||c.$$typeof===S||c.getModuleId!==void 0)},Te.typeOf=e}()),Te}var _o;function Iu(){return _o||(_o=1,process.env.NODE_ENV==="production"?Rn.exports=Du():Rn.exports=Pu()),Rn.exports}var Zn=Iu();function Ot(e){if(typeof e!="object"||e===null)return!1;const t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function dl(e){if(te.isValidElement(e)||Zn.isValidElementType(e)||!Ot(e))return e;const t={};return Object.keys(e).forEach(r=>{t[r]=dl(e[r])}),t}function it(e,t,r={clone:!0}){const n=r.clone?{...e}:e;return Ot(e)&&Ot(t)&&Object.keys(t).forEach(i=>{te.isValidElement(t[i])||Zn.isValidElementType(t[i])?n[i]=t[i]:Ot(t[i])&&Object.prototype.hasOwnProperty.call(e,i)&&Ot(e[i])?n[i]=it(e[i],t[i],r):r.clone?n[i]=Ot(t[i])?dl(t[i]):t[i]:n[i]=t[i]}),n}function fn(e,t){return t?it(e,t,{clone:!1}):e}const rr=process.env.NODE_ENV!=="production"?w.oneOfType([w.number,w.string,w.object,w.array]):{};function Mu(e,t){if(!e.containerQueries)return t;const r=Object.keys(t).filter(n=>n.startsWith("@container")).sort((n,i)=>{var o,s;const a=/min-width:\s*([0-9.]+)/;return+(((o=n.match(a))==null?void 0:o[1])||0)-+(((s=i.match(a))==null?void 0:s[1])||0)});return r.length?r.reduce((n,i)=>{const a=t[i];return delete n[i],n[i]=a,n},{...t}):t}function zu(e,t){return t==="@"||t.startsWith("@")&&(e.some(r=>t.startsWith(`@${r}`))||!!t.match(/^@\d/))}function Vu(e,t){const r=t.match(/^@([^/]+)?\/?(.+)?$/);if(!r){if(process.env.NODE_ENV!=="production")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The provided shorthand ${`(${t})`} is invalid. The format should be \`@<breakpoint | number>\` or \`@<breakpoint | number>/<container>\`.
37
+ For example, \`@sm\` or \`@600\` or \`@40rem/sidebar\`.`:er(18,`(${t})`));return null}const[,n,i]=r,a=Number.isNaN(+n)?n||0:+n;return e.containerQueries(i).up(a)}function Bu(e){const t=(a,o)=>a.replace("@media",o?`@container ${o}`:"@container");function r(a,o){a.up=(...s)=>t(e.breakpoints.up(...s),o),a.down=(...s)=>t(e.breakpoints.down(...s),o),a.between=(...s)=>t(e.breakpoints.between(...s),o),a.only=(...s)=>t(e.breakpoints.only(...s),o),a.not=(...s)=>{const l=t(e.breakpoints.not(...s),o);return l.includes("not all and")?l.replace("not all and ","").replace("min-width:","width<").replace("max-width:","width>").replace("and","or"):l}}const n={},i=a=>(r(n,a),n);return r(i),{...e,containerQueries:i}}const ui={xs:0,sm:600,md:900,lg:1200,xl:1536},Ro={keys:["xs","sm","md","lg","xl"],up:e=>`@media (min-width:${ui[e]}px)`},Nu={containerQueries:e=>({up:t=>{let r=typeof t=="number"?t:ui[t]||t;return typeof r=="number"&&(r=`${r}px`),e?`@container ${e} (min-width:${r})`:`@container (min-width:${r})`}})};function Mt(e,t,r){const n=e.theme||{};if(Array.isArray(t)){const a=n.breakpoints||Ro;return t.reduce((o,s,l)=>(o[a.up(a.keys[l])]=r(t[l]),o),{})}if(typeof t=="object"){const a=n.breakpoints||Ro;return Object.keys(t).reduce((o,s)=>{if(zu(a.keys,s)){const l=Vu(n.containerQueries?n:Nu,s);l&&(o[l]=r(t[s],s))}else if(Object.keys(a.values||ui).includes(s)){const l=a.up(s);o[l]=r(t[s],s)}else{const l=s;o[l]=t[l]}return o},{})}return r(t)}function Lu(e={}){var r;return((r=e.keys)==null?void 0:r.reduce((n,i)=>{const a=e.up(i);return n[a]={},n},{}))||{}}function qu(e,t){return e.reduce((r,n)=>{const i=r[n];return(!i||Object.keys(i).length===0)&&delete r[n],r},t)}function pi(e,t,r=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&r){const n=`vars.${t}`.split(".").reduce((i,a)=>i&&i[a]?i[a]:null,e);if(n!=null)return n}return t.split(".").reduce((n,i)=>n&&n[i]!=null?n[i]:null,e)}function Xn(e,t,r,n=r){let i;return typeof e=="function"?i=e(r):Array.isArray(e)?i=e[r]||n:i=pi(e,r)||n,t&&(i=t(i,n,e)),i}function ze(e){const{prop:t,cssProperty:r=e.prop,themeKey:n,transform:i}=e,a=o=>{if(o[t]==null)return null;const s=o[t],l=o.theme,p=pi(l,n)||{};return Mt(o,s,d=>{let f=Xn(p,i,d);return d===f&&typeof d=="string"&&(f=Xn(p,i,`${t}${d==="default"?"":Re(d)}`,d)),r===!1?f:{[r]:f}})};return a.propTypes=process.env.NODE_ENV!=="production"?{[t]:rr}:{},a.filterProps=[t],a}function Uu(e){const t={};return r=>(t[r]===void 0&&(t[r]=e(r)),t[r])}const Wu={m:"margin",p:"padding"},Hu={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},$o={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},Ku=Uu(e=>{if(e.length>2)if($o[e])e=$o[e];else return[e];const[t,r]=e.split(""),n=Wu[t],i=Hu[r]||"";return Array.isArray(i)?i.map(a=>n+a):[n+i]}),di=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],fi=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],Qu=[...di,...fi];function En(e,t,r,n){const i=pi(e,t,!0)??r;return typeof i=="number"||typeof i=="string"?a=>typeof a=="string"?a:(process.env.NODE_ENV!=="production"&&typeof a!="number"&&console.error(`MUI: Expected ${n} argument to be a number or a string, got ${a}.`),typeof i=="string"?i.startsWith("var(")&&a===0?0:i.startsWith("var(")&&a===1?i:`calc(${a} * ${i})`:i*a):Array.isArray(i)?a=>{if(typeof a=="string")return a;const o=Math.abs(a);process.env.NODE_ENV!=="production"&&(Number.isInteger(o)?o>i.length-1&&console.error([`MUI: The value provided (${o}) overflows.`,`The supported values are: ${JSON.stringify(i)}.`,`${o} > ${i.length-1}, you need to add the missing values.`].join(`
38
38
  `)):console.error([`MUI: The \`theme.${t}\` array type cannot be combined with non integer values.You should either use an integer value that can be used as index, or define the \`theme.${t}\` as a number.`].join(`
39
39
  `)));const s=i[o];return a>=0?s:typeof s=="number"?-s:typeof s=="string"&&s.startsWith("var(")?`calc(-1 * ${s})`:`-${s}`}:typeof i=="function"?i:(process.env.NODE_ENV!=="production"&&console.error([`MUI: The \`theme.${t}\` value (${i}) is invalid.`,"It should be a number, an array or a function."].join(`
40
- `)),()=>{})}function Fa(e){return En(e,"spacing",8,"spacing")}function kn(e,t){return typeof t=="string"||t==null?t:e(t)}function Yu(e,t){return r=>e.reduce((n,i)=>(n[i]=kn(t,r),n),{})}function Gu(e,t,r,n){if(!t.includes(r))return null;const i=Ku(r),a=Yu(i,n),o=e[r];return Mt(e,o,a)}function ul(e,t){const r=Fa(e.theme);return Object.keys(e).map(n=>Gu(e,t,n,r)).reduce(fn,{})}function $e(e){return ul(e,di)}$e.propTypes=process.env.NODE_ENV!=="production"?di.reduce((e,t)=>(e[t]=rr,e),{}):{};$e.filterProps=di;function De(e){return ul(e,fi)}De.propTypes=process.env.NODE_ENV!=="production"?fi.reduce((e,t)=>(e[t]=rr,e),{}):{};De.filterProps=fi;process.env.NODE_ENV!=="production"&&Qu.reduce((e,t)=>(e[t]=rr,e),{});function hi(...e){const t=e.reduce((n,i)=>(i.filterProps.forEach(a=>{n[a]=i}),n),{}),r=n=>Object.keys(n).reduce((i,a)=>t[a]?fn(i,t[a](n)):i,{});return r.propTypes=process.env.NODE_ENV!=="production"?e.reduce((n,i)=>Object.assign(n,i.propTypes),{}):{},r.filterProps=e.reduce((n,i)=>n.concat(i.filterProps),[]),r}function pt(e){return typeof e!="number"?e:`${e}px solid`}function dt(e,t){return ze({prop:e,themeKey:"borders",transform:t})}const Zu=dt("border",pt),Xu=dt("borderTop",pt),Ju=dt("borderRight",pt),ep=dt("borderBottom",pt),tp=dt("borderLeft",pt),rp=dt("borderColor"),np=dt("borderTopColor"),ip=dt("borderRightColor"),ap=dt("borderBottomColor"),op=dt("borderLeftColor"),sp=dt("outline",pt),lp=dt("outlineColor"),mi=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=En(e.theme,"shape.borderRadius",4,"borderRadius"),r=n=>({borderRadius:kn(t,n)});return Mt(e,e.borderRadius,r)}return null};mi.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:rr}:{};mi.filterProps=["borderRadius"];hi(Zu,Xu,Ju,ep,tp,rp,np,ip,ap,op,mi,sp,lp);const gi=e=>{if(e.gap!==void 0&&e.gap!==null){const t=En(e.theme,"spacing",8,"gap"),r=n=>({gap:kn(t,n)});return Mt(e,e.gap,r)}return null};gi.propTypes=process.env.NODE_ENV!=="production"?{gap:rr}:{};gi.filterProps=["gap"];const yi=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=En(e.theme,"spacing",8,"columnGap"),r=n=>({columnGap:kn(t,n)});return Mt(e,e.columnGap,r)}return null};yi.propTypes=process.env.NODE_ENV!=="production"?{columnGap:rr}:{};yi.filterProps=["columnGap"];const xi=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=En(e.theme,"spacing",8,"rowGap"),r=n=>({rowGap:kn(t,n)});return Mt(e,e.rowGap,r)}return null};xi.propTypes=process.env.NODE_ENV!=="production"?{rowGap:rr}:{};xi.filterProps=["rowGap"];const cp=ze({prop:"gridColumn"}),up=ze({prop:"gridRow"}),pp=ze({prop:"gridAutoFlow"}),dp=ze({prop:"gridAutoColumns"}),fp=ze({prop:"gridAutoRows"}),hp=ze({prop:"gridTemplateColumns"}),mp=ze({prop:"gridTemplateRows"}),gp=ze({prop:"gridTemplateAreas"}),yp=ze({prop:"gridArea"});hi(gi,yi,xi,cp,up,pp,dp,fp,hp,mp,gp,yp);function Mr(e,t){return t==="grey"?t:e}const xp=ze({prop:"color",themeKey:"palette",transform:Mr}),vp=ze({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:Mr}),bp=ze({prop:"backgroundColor",themeKey:"palette",transform:Mr});hi(xp,vp,bp);function nt(e){return e<=1&&e!==0?`${e*100}%`:e}const wp=ze({prop:"width",transform:nt}),_a=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=r=>{var i,a,o,s,l;const n=((o=(a=(i=e.theme)==null?void 0:i.breakpoints)==null?void 0:a.values)==null?void 0:o[r])||ui[r];return n?((l=(s=e.theme)==null?void 0:s.breakpoints)==null?void 0:l.unit)!=="px"?{maxWidth:`${n}${e.theme.breakpoints.unit}`}:{maxWidth:n}:{maxWidth:nt(r)}};return Mt(e,e.maxWidth,t)}return null};_a.filterProps=["maxWidth"];const Sp=ze({prop:"minWidth",transform:nt}),Cp=ze({prop:"height",transform:nt}),Ep=ze({prop:"maxHeight",transform:nt}),kp=ze({prop:"minHeight",transform:nt});ze({prop:"size",cssProperty:"width",transform:nt});ze({prop:"size",cssProperty:"height",transform:nt});const Tp=ze({prop:"boxSizing"});hi(wp,_a,Sp,Cp,Ep,kp,Tp);const Tn={border:{themeKey:"borders",transform:pt},borderTop:{themeKey:"borders",transform:pt},borderRight:{themeKey:"borders",transform:pt},borderBottom:{themeKey:"borders",transform:pt},borderLeft:{themeKey:"borders",transform:pt},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:pt},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:mi},color:{themeKey:"palette",transform:Mr},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:Mr},backgroundColor:{themeKey:"palette",transform:Mr},p:{style:De},pt:{style:De},pr:{style:De},pb:{style:De},pl:{style:De},px:{style:De},py:{style:De},padding:{style:De},paddingTop:{style:De},paddingRight:{style:De},paddingBottom:{style:De},paddingLeft:{style:De},paddingX:{style:De},paddingY:{style:De},paddingInline:{style:De},paddingInlineStart:{style:De},paddingInlineEnd:{style:De},paddingBlock:{style:De},paddingBlockStart:{style:De},paddingBlockEnd:{style:De},m:{style:$e},mt:{style:$e},mr:{style:$e},mb:{style:$e},ml:{style:$e},mx:{style:$e},my:{style:$e},margin:{style:$e},marginTop:{style:$e},marginRight:{style:$e},marginBottom:{style:$e},marginLeft:{style:$e},marginX:{style:$e},marginY:{style:$e},marginInline:{style:$e},marginInlineStart:{style:$e},marginInlineEnd:{style:$e},marginBlock:{style:$e},marginBlockStart:{style:$e},marginBlockEnd:{style:$e},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:gi},rowGap:{style:xi},columnGap:{style:yi},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:nt},maxWidth:{style:_a},minWidth:{transform:nt},height:{transform:nt},maxHeight:{transform:nt},minHeight:{transform:nt},boxSizing:{},font:{themeKey:"font"},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}};function Op(...e){const t=e.reduce((n,i)=>n.concat(Object.keys(i)),[]),r=new Set(t);return e.every(n=>r.size===Object.keys(n).length)}function jp(e,t){return typeof e=="function"?e(t):e}function Fp(){function e(r,n,i,a){const o={[r]:n,theme:i},s=a[r];if(!s)return{[r]:n};const{cssProperty:l=r,themeKey:p,transform:u,style:d}=s;if(n==null)return null;if(p==="typography"&&n==="inherit")return{[r]:n};const f=pi(i,p)||{};return d?d(o):Mt(o,n,S=>{let c=Xn(f,u,S);return S===c&&typeof S=="string"&&(c=Xn(f,u,`${r}${S==="default"?"":Re(S)}`,S)),l===!1?c:{[l]:c}})}function t(r){const{sx:n,theme:i={}}=r||{};if(!n)return null;const a=i.unstable_sxConfig??Tn;function o(s){let l=s;if(typeof s=="function")l=s(i);else if(typeof s!="object")return s;if(!l)return null;const p=Lu(i.breakpoints),u=Object.keys(p);let d=p;return Object.keys(l).forEach(f=>{const y=jp(l[f],i);if(y!=null)if(typeof y=="object")if(a[f])d=fn(d,e(f,y,i,a));else{const S=Mt({theme:i},y,c=>({[f]:c}));Op(S,y)?d[f]=t({sx:y,theme:i}):d=fn(d,S)}else d=fn(d,e(f,y,i,a))}),Mu(i,qu(u,d))}return Array.isArray(n)?n.map(o):o(n)}return t}const Gr=Fp();Gr.filterProps=["sx"];const _p=e=>{var n;const t={systemProps:{},otherProps:{}},r=((n=e==null?void 0:e.theme)==null?void 0:n.unstable_sxConfig)??Tn;return Object.keys(e).forEach(i=>{r[i]?t.systemProps[i]=e[i]:t.otherProps[i]=e[i]}),t};function Ap(e){const{sx:t,...r}=e,{systemProps:n,otherProps:i}=_p(r);let a;return Array.isArray(t)?a=[n,...t]:typeof t=="function"?a=(...o)=>{const s=t(...o);return Ot(s)?{...n,...s}:n}:a={...n,...t},{...i,sx:a}}function Rp(e){for(var t=0,r,n=0,i=e.length;i>=4;++n,i-=4)r=e.charCodeAt(n)&255|(e.charCodeAt(++n)&255)<<8|(e.charCodeAt(++n)&255)<<16|(e.charCodeAt(++n)&255)<<24,r=(r&65535)*1540483477+((r>>>16)*59797<<16),r^=r>>>24,t=(r&65535)*1540483477+((r>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(i){case 3:t^=(e.charCodeAt(n+2)&255)<<16;case 2:t^=(e.charCodeAt(n+1)&255)<<8;case 1:t^=e.charCodeAt(n)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var $p={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1};function Dp(e){var t=Object.create(null);return function(r){return t[r]===void 0&&(t[r]=e(r)),t[r]}}var Pp=/[A-Z]|^ms/g,Ip=/_EMO_([^_]+?)_([^]*?)_EMO_/g,pl=function(t){return t.charCodeAt(1)===45},Ao=function(t){return t!=null&&typeof t!="boolean"},Fi=Dp(function(e){return pl(e)?e:e.replace(Pp,"-$&").toLowerCase()}),Ro=function(t,r){switch(t){case"animation":case"animationName":if(typeof r=="string")return r.replace(Ip,function(n,i,a){return Zt={name:i,styles:a,next:Zt},i})}return $p[t]!==1&&!pl(t)&&typeof r=="number"&&r!==0?r+"px":r};function Jn(e,t,r){if(r==null)return"";var n=r;if(n.__emotion_styles!==void 0)return n;switch(typeof r){case"boolean":return"";case"object":{var i=r;if(i.anim===1)return Zt={name:i.name,styles:i.styles,next:Zt},i.name;var a=r;if(a.styles!==void 0){var o=a.next;if(o!==void 0)for(;o!==void 0;)Zt={name:o.name,styles:o.styles,next:Zt},o=o.next;var s=a.styles+";";return s}return Mp(e,t,r)}}var l=r;return l}function Mp(e,t,r){var n="";if(Array.isArray(r))for(var i=0;i<r.length;i++)n+=Jn(e,t,r[i])+";";else for(var a in r){var o=r[a];if(typeof o!="object"){var s=o;Ao(s)&&(n+=Fi(a)+":"+Ro(a,s)+";")}else if(Array.isArray(o)&&typeof o[0]=="string"&&t==null)for(var l=0;l<o.length;l++)Ao(o[l])&&(n+=Fi(a)+":"+Ro(a,o[l])+";");else{var p=Jn(e,t,o);switch(a){case"animation":case"animationName":{n+=Fi(a)+":"+p+";";break}default:n+=a+"{"+p+"}"}}}return n}var $o=/label:\s*([^\s;{]+)\s*(;|$)/g,Zt;function zp(e,t,r){if(e.length===1&&typeof e[0]=="object"&&e[0]!==null&&e[0].styles!==void 0)return e[0];var n=!0,i="";Zt=void 0;var a=e[0];if(a==null||a.raw===void 0)n=!1,i+=Jn(r,t,a);else{var o=a;i+=o[0]}for(var s=1;s<e.length;s++)if(i+=Jn(r,t,e[s]),n){var l=a;i+=l[s]}$o.lastIndex=0;for(var p="",u;(u=$o.exec(i))!==null;)p+="-"+u[1];var d=Rp(i)+p;return{name:d,styles:i,next:Zt}}/**
40
+ `)),()=>{})}function Ra(e){return En(e,"spacing",8,"spacing")}function kn(e,t){return typeof t=="string"||t==null?t:e(t)}function Yu(e,t){return r=>e.reduce((n,i)=>(n[i]=kn(t,r),n),{})}function Gu(e,t,r,n){if(!t.includes(r))return null;const i=Ku(r),a=Yu(i,n),o=e[r];return Mt(e,o,a)}function fl(e,t){const r=Ra(e.theme);return Object.keys(e).map(n=>Gu(e,t,n,r)).reduce(fn,{})}function $e(e){return fl(e,di)}$e.propTypes=process.env.NODE_ENV!=="production"?di.reduce((e,t)=>(e[t]=rr,e),{}):{};$e.filterProps=di;function De(e){return fl(e,fi)}De.propTypes=process.env.NODE_ENV!=="production"?fi.reduce((e,t)=>(e[t]=rr,e),{}):{};De.filterProps=fi;process.env.NODE_ENV!=="production"&&Qu.reduce((e,t)=>(e[t]=rr,e),{});function hi(...e){const t=e.reduce((n,i)=>(i.filterProps.forEach(a=>{n[a]=i}),n),{}),r=n=>Object.keys(n).reduce((i,a)=>t[a]?fn(i,t[a](n)):i,{});return r.propTypes=process.env.NODE_ENV!=="production"?e.reduce((n,i)=>Object.assign(n,i.propTypes),{}):{},r.filterProps=e.reduce((n,i)=>n.concat(i.filterProps),[]),r}function pt(e){return typeof e!="number"?e:`${e}px solid`}function dt(e,t){return ze({prop:e,themeKey:"borders",transform:t})}const Zu=dt("border",pt),Xu=dt("borderTop",pt),Ju=dt("borderRight",pt),ep=dt("borderBottom",pt),tp=dt("borderLeft",pt),rp=dt("borderColor"),np=dt("borderTopColor"),ip=dt("borderRightColor"),ap=dt("borderBottomColor"),op=dt("borderLeftColor"),sp=dt("outline",pt),lp=dt("outlineColor"),mi=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=En(e.theme,"shape.borderRadius",4,"borderRadius"),r=n=>({borderRadius:kn(t,n)});return Mt(e,e.borderRadius,r)}return null};mi.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:rr}:{};mi.filterProps=["borderRadius"];hi(Zu,Xu,Ju,ep,tp,rp,np,ip,ap,op,mi,sp,lp);const yi=e=>{if(e.gap!==void 0&&e.gap!==null){const t=En(e.theme,"spacing",8,"gap"),r=n=>({gap:kn(t,n)});return Mt(e,e.gap,r)}return null};yi.propTypes=process.env.NODE_ENV!=="production"?{gap:rr}:{};yi.filterProps=["gap"];const gi=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=En(e.theme,"spacing",8,"columnGap"),r=n=>({columnGap:kn(t,n)});return Mt(e,e.columnGap,r)}return null};gi.propTypes=process.env.NODE_ENV!=="production"?{columnGap:rr}:{};gi.filterProps=["columnGap"];const xi=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=En(e.theme,"spacing",8,"rowGap"),r=n=>({rowGap:kn(t,n)});return Mt(e,e.rowGap,r)}return null};xi.propTypes=process.env.NODE_ENV!=="production"?{rowGap:rr}:{};xi.filterProps=["rowGap"];const cp=ze({prop:"gridColumn"}),up=ze({prop:"gridRow"}),pp=ze({prop:"gridAutoFlow"}),dp=ze({prop:"gridAutoColumns"}),fp=ze({prop:"gridAutoRows"}),hp=ze({prop:"gridTemplateColumns"}),mp=ze({prop:"gridTemplateRows"}),yp=ze({prop:"gridTemplateAreas"}),gp=ze({prop:"gridArea"});hi(yi,gi,xi,cp,up,pp,dp,fp,hp,mp,yp,gp);function Mr(e,t){return t==="grey"?t:e}const xp=ze({prop:"color",themeKey:"palette",transform:Mr}),vp=ze({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:Mr}),bp=ze({prop:"backgroundColor",themeKey:"palette",transform:Mr});hi(xp,vp,bp);function nt(e){return e<=1&&e!==0?`${e*100}%`:e}const wp=ze({prop:"width",transform:nt}),$a=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=r=>{var i,a,o,s,l;const n=((o=(a=(i=e.theme)==null?void 0:i.breakpoints)==null?void 0:a.values)==null?void 0:o[r])||ui[r];return n?((l=(s=e.theme)==null?void 0:s.breakpoints)==null?void 0:l.unit)!=="px"?{maxWidth:`${n}${e.theme.breakpoints.unit}`}:{maxWidth:n}:{maxWidth:nt(r)}};return Mt(e,e.maxWidth,t)}return null};$a.filterProps=["maxWidth"];const Sp=ze({prop:"minWidth",transform:nt}),Cp=ze({prop:"height",transform:nt}),Ep=ze({prop:"maxHeight",transform:nt}),kp=ze({prop:"minHeight",transform:nt});ze({prop:"size",cssProperty:"width",transform:nt});ze({prop:"size",cssProperty:"height",transform:nt});const Tp=ze({prop:"boxSizing"});hi(wp,$a,Sp,Cp,Ep,kp,Tp);const Tn={border:{themeKey:"borders",transform:pt},borderTop:{themeKey:"borders",transform:pt},borderRight:{themeKey:"borders",transform:pt},borderBottom:{themeKey:"borders",transform:pt},borderLeft:{themeKey:"borders",transform:pt},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:pt},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:mi},color:{themeKey:"palette",transform:Mr},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:Mr},backgroundColor:{themeKey:"palette",transform:Mr},p:{style:De},pt:{style:De},pr:{style:De},pb:{style:De},pl:{style:De},px:{style:De},py:{style:De},padding:{style:De},paddingTop:{style:De},paddingRight:{style:De},paddingBottom:{style:De},paddingLeft:{style:De},paddingX:{style:De},paddingY:{style:De},paddingInline:{style:De},paddingInlineStart:{style:De},paddingInlineEnd:{style:De},paddingBlock:{style:De},paddingBlockStart:{style:De},paddingBlockEnd:{style:De},m:{style:$e},mt:{style:$e},mr:{style:$e},mb:{style:$e},ml:{style:$e},mx:{style:$e},my:{style:$e},margin:{style:$e},marginTop:{style:$e},marginRight:{style:$e},marginBottom:{style:$e},marginLeft:{style:$e},marginX:{style:$e},marginY:{style:$e},marginInline:{style:$e},marginInlineStart:{style:$e},marginInlineEnd:{style:$e},marginBlock:{style:$e},marginBlockStart:{style:$e},marginBlockEnd:{style:$e},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:yi},rowGap:{style:xi},columnGap:{style:gi},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:nt},maxWidth:{style:$a},minWidth:{transform:nt},height:{transform:nt},maxHeight:{transform:nt},minHeight:{transform:nt},boxSizing:{},font:{themeKey:"font"},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}};function Op(...e){const t=e.reduce((n,i)=>n.concat(Object.keys(i)),[]),r=new Set(t);return e.every(n=>r.size===Object.keys(n).length)}function jp(e,t){return typeof e=="function"?e(t):e}function Fp(){function e(r,n,i,a){const o={[r]:n,theme:i},s=a[r];if(!s)return{[r]:n};const{cssProperty:l=r,themeKey:p,transform:u,style:d}=s;if(n==null)return null;if(p==="typography"&&n==="inherit")return{[r]:n};const f=pi(i,p)||{};return d?d(o):Mt(o,n,S=>{let c=Xn(f,u,S);return S===c&&typeof S=="string"&&(c=Xn(f,u,`${r}${S==="default"?"":Re(S)}`,S)),l===!1?c:{[l]:c}})}function t(r){const{sx:n,theme:i={}}=r||{};if(!n)return null;const a=i.unstable_sxConfig??Tn;function o(s){let l=s;if(typeof s=="function")l=s(i);else if(typeof s!="object")return s;if(!l)return null;const p=Lu(i.breakpoints),u=Object.keys(p);let d=p;return Object.keys(l).forEach(f=>{const g=jp(l[f],i);if(g!=null)if(typeof g=="object")if(a[f])d=fn(d,e(f,g,i,a));else{const S=Mt({theme:i},g,c=>({[f]:c}));Op(S,g)?d[f]=t({sx:g,theme:i}):d=fn(d,S)}else d=fn(d,e(f,g,i,a))}),Mu(i,qu(u,d))}return Array.isArray(n)?n.map(o):o(n)}return t}const Gr=Fp();Gr.filterProps=["sx"];const Ap=e=>{var n;const t={systemProps:{},otherProps:{}},r=((n=e==null?void 0:e.theme)==null?void 0:n.unstable_sxConfig)??Tn;return Object.keys(e).forEach(i=>{r[i]?t.systemProps[i]=e[i]:t.otherProps[i]=e[i]}),t};function _p(e){const{sx:t,...r}=e,{systemProps:n,otherProps:i}=Ap(r);let a;return Array.isArray(t)?a=[n,...t]:typeof t=="function"?a=(...o)=>{const s=t(...o);return Ot(s)?{...n,...s}:n}:a={...n,...t},{...i,sx:a}}function Rp(e){for(var t=0,r,n=0,i=e.length;i>=4;++n,i-=4)r=e.charCodeAt(n)&255|(e.charCodeAt(++n)&255)<<8|(e.charCodeAt(++n)&255)<<16|(e.charCodeAt(++n)&255)<<24,r=(r&65535)*1540483477+((r>>>16)*59797<<16),r^=r>>>24,t=(r&65535)*1540483477+((r>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(i){case 3:t^=(e.charCodeAt(n+2)&255)<<16;case 2:t^=(e.charCodeAt(n+1)&255)<<8;case 1:t^=e.charCodeAt(n)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var $p={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1};function Dp(e){var t=Object.create(null);return function(r){return t[r]===void 0&&(t[r]=e(r)),t[r]}}var Pp=/[A-Z]|^ms/g,Ip=/_EMO_([^_]+?)_([^]*?)_EMO_/g,hl=function(t){return t.charCodeAt(1)===45},Do=function(t){return t!=null&&typeof t!="boolean"},Fi=Dp(function(e){return hl(e)?e:e.replace(Pp,"-$&").toLowerCase()}),Po=function(t,r){switch(t){case"animation":case"animationName":if(typeof r=="string")return r.replace(Ip,function(n,i,a){return Zt={name:i,styles:a,next:Zt},i})}return $p[t]!==1&&!hl(t)&&typeof r=="number"&&r!==0?r+"px":r};function Jn(e,t,r){if(r==null)return"";var n=r;if(n.__emotion_styles!==void 0)return n;switch(typeof r){case"boolean":return"";case"object":{var i=r;if(i.anim===1)return Zt={name:i.name,styles:i.styles,next:Zt},i.name;var a=r;if(a.styles!==void 0){var o=a.next;if(o!==void 0)for(;o!==void 0;)Zt={name:o.name,styles:o.styles,next:Zt},o=o.next;var s=a.styles+";";return s}return Mp(e,t,r)}}var l=r;return l}function Mp(e,t,r){var n="";if(Array.isArray(r))for(var i=0;i<r.length;i++)n+=Jn(e,t,r[i])+";";else for(var a in r){var o=r[a];if(typeof o!="object"){var s=o;Do(s)&&(n+=Fi(a)+":"+Po(a,s)+";")}else if(Array.isArray(o)&&typeof o[0]=="string"&&t==null)for(var l=0;l<o.length;l++)Do(o[l])&&(n+=Fi(a)+":"+Po(a,o[l])+";");else{var p=Jn(e,t,o);switch(a){case"animation":case"animationName":{n+=Fi(a)+":"+p+";";break}default:n+=a+"{"+p+"}"}}}return n}var Io=/label:\s*([^\s;{]+)\s*(;|$)/g,Zt;function zp(e,t,r){if(e.length===1&&typeof e[0]=="object"&&e[0]!==null&&e[0].styles!==void 0)return e[0];var n=!0,i="";Zt=void 0;var a=e[0];if(a==null||a.raw===void 0)n=!1,i+=Jn(r,t,a);else{var o=a;i+=o[0]}for(var s=1;s<e.length;s++)if(i+=Jn(r,t,e[s]),n){var l=a;i+=l[s]}Io.lastIndex=0;for(var p="",u;(u=Io.exec(i))!==null;)p+="-"+u[1];var d=Rp(i)+p;return{name:d,styles:i,next:Zt}}/**
41
41
  * @mui/styled-engine v7.1.1
42
42
  *
43
43
  * @license MIT
44
44
  * This source code is licensed under the MIT license found in the
45
45
  * LICENSE file in the root directory of this source tree.
46
46
  */function Vp(e,t){const r=wc(e,t);return process.env.NODE_ENV!=="production"?(...n)=>{const i=typeof e=="string"?`"${e}"`:"component";return n.length===0?console.error([`MUI: Seems like you called \`styled(${i})()\` without a \`style\` argument.`,'You must provide a `styles` argument: `styled("div")(styleYouForgotToPass)`.'].join(`
47
- `)):n.some(a=>a===void 0)&&console.error(`MUI: the styled(${i})(...args) API requires all its args to be defined.`),r(...n)}:r}function Bp(e,t){Array.isArray(e.__emotion_styles)&&(e.__emotion_styles=t(e.__emotion_styles))}const Do=[];function Po(e){return Do[0]=e,zp(Do)}const Np=e=>{const t=Object.keys(e).map(r=>({key:r,val:e[r]}))||[];return t.sort((r,n)=>r.val-n.val),t.reduce((r,n)=>({...r,[n.key]:n.val}),{})};function Lp(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:r="px",step:n=5,...i}=e,a=Np(t),o=Object.keys(a);function s(f){return`@media (min-width:${typeof t[f]=="number"?t[f]:f}${r})`}function l(f){return`@media (max-width:${(typeof t[f]=="number"?t[f]:f)-n/100}${r})`}function p(f,y){const S=o.indexOf(y);return`@media (min-width:${typeof t[f]=="number"?t[f]:f}${r}) and (max-width:${(S!==-1&&typeof t[o[S]]=="number"?t[o[S]]:y)-n/100}${r})`}function u(f){return o.indexOf(f)+1<o.length?p(f,o[o.indexOf(f)+1]):s(f)}function d(f){const y=o.indexOf(f);return y===0?s(o[1]):y===o.length-1?l(o[y]):p(f,o[o.indexOf(f)+1]).replace("@media","@media not all and")}return{keys:o,values:a,up:s,down:l,between:p,only:u,not:d,unit:r,...i}}const qp={borderRadius:4};function dl(e=8,t=Fa({spacing:e})){if(e.mui)return e;const r=(...n)=>(process.env.NODE_ENV!=="production"&&(n.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${n.length}`)),(n.length===0?[1]:n).map(a=>{const o=t(a);return typeof o=="number"?`${o}px`:o}).join(" "));return r.mui=!0,r}function Up(e,t){var n;const r=this;if(r.vars){if(!((n=r.colorSchemes)!=null&&n[e])||typeof r.getColorSchemeSelector!="function")return{};let i=r.getColorSchemeSelector(e);return i==="&"?t:((i.includes("data-")||i.includes("."))&&(i=`*:where(${i.replace(/\s*&$/,"")}) &`),{[i]:t})}return r.palette.mode===e?t:{}}function fl(e={},...t){const{breakpoints:r={},palette:n={},spacing:i,shape:a={},...o}=e,s=Lp(r),l=dl(i);let p=it({breakpoints:s,direction:"ltr",components:{},palette:{mode:"light",...n},spacing:l,shape:{...qp,...a}},o);return p=Bu(p),p.applyStyles=Up,p=t.reduce((u,d)=>it(u,d),p),p.unstable_sxConfig={...Tn,...o==null?void 0:o.unstable_sxConfig},p.unstable_sx=function(d){return Gr({sx:d,theme:this})},p}const Io=e=>e,Wp=()=>{let e=Io;return{configure(t){e=t},generate(t){return e(t)},reset(){e=Io}}},Hp=Wp(),Kp={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function nr(e,t,r="Mui"){const n=Kp[t];return n?`${r}-${n}`:`${Hp.generate(e)}-${t}`}function Cr(e,t,r="Mui"){const n={};return t.forEach(i=>{n[i]=nr(e,i,r)}),n}function hl(e,t=""){return e.displayName||e.name||t}function Mo(e,t,r){const n=hl(t);return e.displayName||(n!==""?`${r}(${n})`:r)}function Qp(e){if(e!=null){if(typeof e=="string")return e;if(typeof e=="function")return hl(e,"Component");if(typeof e=="object")switch(e.$$typeof){case Zn.ForwardRef:return Mo(e,e.render,"ForwardRef");case Zn.Memo:return Mo(e,e.type,"memo");default:return}}}function ml(e){const{variants:t,...r}=e,n={variants:t,style:Po(r),isProcessed:!0};return n.style===r||t&&t.forEach(i=>{typeof i.style!="function"&&(i.style=Po(i.style))}),n}const Yp=fl();function _i(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}function Gp(e){return e?(t,r)=>r[e]:null}function Zp(e,t,r){e.theme=td(e.theme)?r:e.theme[t]||e.theme}function Bn(e,t){const r=typeof t=="function"?t(e):t;if(Array.isArray(r))return r.flatMap(n=>Bn(e,n));if(Array.isArray(r==null?void 0:r.variants)){let n;if(r.isProcessed)n=r.style;else{const{variants:i,...a}=r;n=a}return gl(e,r.variants,[n])}return r!=null&&r.isProcessed?r.style:r}function gl(e,t,r=[]){var i;let n;e:for(let a=0;a<t.length;a+=1){const o=t[a];if(typeof o.props=="function"){if(n??(n={...e,...e.ownerState,ownerState:e.ownerState}),!o.props(n))continue}else for(const s in o.props)if(e[s]!==o.props[s]&&((i=e.ownerState)==null?void 0:i[s])!==o.props[s])continue e;typeof o.style=="function"?(n??(n={...e,...e.ownerState,ownerState:e.ownerState}),r.push(o.style(n))):r.push(o.style)}return r}function Xp(e={}){const{themeId:t,defaultTheme:r=Yp,rootShouldForwardProp:n=_i,slotShouldForwardProp:i=_i}=e;function a(s){Zp(s,t,r)}return(s,l={})=>{Bp(s,x=>x.filter(B=>B!==Gr));const{name:p,slot:u,skipVariantsResolver:d,skipSx:f,overridesResolver:y=Gp(yl(u)),...S}=l,c=d!==void 0?d:u&&u!=="Root"&&u!=="root"||!1,b=f||!1;let g=_i;u==="Root"||u==="root"?g=n:u?g=i:rd(s)&&(g=void 0);const O=Vp(s,{shouldForwardProp:g,label:ed(p,u),...S}),A=x=>{if(x.__emotion_real===x)return x;if(typeof x=="function")return function(_){return Bn(_,x)};if(Ot(x)){const B=ml(x);return B.variants?function(K){return Bn(K,B)}:B.style}return x},k=(...x)=>{const B=[],_=x.map(A),K=[];if(B.push(a),p&&y&&K.push(function(P){var ie,ge;const N=(ge=(ie=P.theme.components)==null?void 0:ie[p])==null?void 0:ge.styleOverrides;if(!N)return null;const X={};for(const ce in N)X[ce]=Bn(P,N[ce]);return y(P,X)}),p&&!c&&K.push(function(P){var X,ie;const q=P.theme,N=(ie=(X=q==null?void 0:q.components)==null?void 0:X[p])==null?void 0:ie.variants;return N?gl(P,N):null}),b||K.push(Gr),Array.isArray(_[0])){const M=_.shift(),P=new Array(B.length).fill(""),q=new Array(K.length).fill("");let N;N=[...P,...M,...q],N.raw=[...P,...M.raw,...q],B.unshift(N)}const W=[...B,..._,...K],h=O(...W);return s.muiName&&(h.muiName=s.muiName),process.env.NODE_ENV!=="production"&&(h.displayName=Jp(p,u,s)),h};return O.withConfig&&(k.withConfig=O.withConfig),k}}function Jp(e,t,r){return e?`${e}${Re(t||"")}`:`Styled(${Qp(r)})`}function ed(e,t){let r;return process.env.NODE_ENV!=="production"&&e&&(r=`${e}-${yl(t||"Root")}`),r}function td(e){for(const t in e)return!1;return!0}function rd(e){return typeof e=="string"&&e.charCodeAt(0)>96}function yl(e){return e&&e.charAt(0).toLowerCase()+e.slice(1)}function Ji(e,t){const r={...t};for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)){const i=n;if(i==="components"||i==="slots")r[i]={...e[i],...r[i]};else if(i==="componentsProps"||i==="slotProps"){const a=e[i],o=t[i];if(!o)r[i]=a||{};else if(!a)r[i]=o;else{r[i]={...o};for(const s in a)if(Object.prototype.hasOwnProperty.call(a,s)){const l=s;r[i][l]=Ji(a[l],o[l])}}}else r[i]===void 0&&(r[i]=e[i])}return r}const nd=typeof window<"u"?ne.useLayoutEffect:ne.useEffect;function id(e,t=Number.MIN_SAFE_INTEGER,r=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,r))}function Aa(e,t=0,r=1){return process.env.NODE_ENV!=="production"&&(e<t||e>r)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${r}].`),id(e,t,r)}function ad(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let r=e.match(t);return r&&r[0].length===1&&(r=r.map(n=>n+n)),process.env.NODE_ENV!=="production"&&e.length!==e.trim().length&&console.error(`MUI: The color: "${e}" is invalid. Make sure the color input doesn't contain leading/trailing space.`),r?`rgb${r.length===4?"a":""}(${r.map((n,i)=>i<3?parseInt(n,16):Math.round(parseInt(n,16)/255*1e3)/1e3).join(", ")})`:""}function tr(e){if(e.type)return e;if(e.charAt(0)==="#")return tr(ad(e));const t=e.indexOf("("),r=e.substring(0,t);if(!["rgb","rgba","hsl","hsla","color"].includes(r))throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color.
47
+ `)):n.some(a=>a===void 0)&&console.error(`MUI: the styled(${i})(...args) API requires all its args to be defined.`),r(...n)}:r}function Bp(e,t){Array.isArray(e.__emotion_styles)&&(e.__emotion_styles=t(e.__emotion_styles))}const Mo=[];function zo(e){return Mo[0]=e,zp(Mo)}const Np=e=>{const t=Object.keys(e).map(r=>({key:r,val:e[r]}))||[];return t.sort((r,n)=>r.val-n.val),t.reduce((r,n)=>({...r,[n.key]:n.val}),{})};function Lp(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:r="px",step:n=5,...i}=e,a=Np(t),o=Object.keys(a);function s(f){return`@media (min-width:${typeof t[f]=="number"?t[f]:f}${r})`}function l(f){return`@media (max-width:${(typeof t[f]=="number"?t[f]:f)-n/100}${r})`}function p(f,g){const S=o.indexOf(g);return`@media (min-width:${typeof t[f]=="number"?t[f]:f}${r}) and (max-width:${(S!==-1&&typeof t[o[S]]=="number"?t[o[S]]:g)-n/100}${r})`}function u(f){return o.indexOf(f)+1<o.length?p(f,o[o.indexOf(f)+1]):s(f)}function d(f){const g=o.indexOf(f);return g===0?s(o[1]):g===o.length-1?l(o[g]):p(f,o[o.indexOf(f)+1]).replace("@media","@media not all and")}return{keys:o,values:a,up:s,down:l,between:p,only:u,not:d,unit:r,...i}}const qp={borderRadius:4};function ml(e=8,t=Ra({spacing:e})){if(e.mui)return e;const r=(...n)=>(process.env.NODE_ENV!=="production"&&(n.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${n.length}`)),(n.length===0?[1]:n).map(a=>{const o=t(a);return typeof o=="number"?`${o}px`:o}).join(" "));return r.mui=!0,r}function Up(e,t){var n;const r=this;if(r.vars){if(!((n=r.colorSchemes)!=null&&n[e])||typeof r.getColorSchemeSelector!="function")return{};let i=r.getColorSchemeSelector(e);return i==="&"?t:((i.includes("data-")||i.includes("."))&&(i=`*:where(${i.replace(/\s*&$/,"")}) &`),{[i]:t})}return r.palette.mode===e?t:{}}function yl(e={},...t){const{breakpoints:r={},palette:n={},spacing:i,shape:a={},...o}=e,s=Lp(r),l=ml(i);let p=it({breakpoints:s,direction:"ltr",components:{},palette:{mode:"light",...n},spacing:l,shape:{...qp,...a}},o);return p=Bu(p),p.applyStyles=Up,p=t.reduce((u,d)=>it(u,d),p),p.unstable_sxConfig={...Tn,...o==null?void 0:o.unstable_sxConfig},p.unstable_sx=function(d){return Gr({sx:d,theme:this})},p}const Vo=e=>e,Wp=()=>{let e=Vo;return{configure(t){e=t},generate(t){return e(t)},reset(){e=Vo}}},Hp=Wp(),Kp={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function nr(e,t,r="Mui"){const n=Kp[t];return n?`${r}-${n}`:`${Hp.generate(e)}-${t}`}function Cr(e,t,r="Mui"){const n={};return t.forEach(i=>{n[i]=nr(e,i,r)}),n}function gl(e,t=""){return e.displayName||e.name||t}function Bo(e,t,r){const n=gl(t);return e.displayName||(n!==""?`${r}(${n})`:r)}function Qp(e){if(e!=null){if(typeof e=="string")return e;if(typeof e=="function")return gl(e,"Component");if(typeof e=="object")switch(e.$$typeof){case Zn.ForwardRef:return Bo(e,e.render,"ForwardRef");case Zn.Memo:return Bo(e,e.type,"memo");default:return}}}function xl(e){const{variants:t,...r}=e,n={variants:t,style:zo(r),isProcessed:!0};return n.style===r||t&&t.forEach(i=>{typeof i.style!="function"&&(i.style=zo(i.style))}),n}const Yp=yl();function Ai(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}function Gp(e){return e?(t,r)=>r[e]:null}function Zp(e,t,r){e.theme=td(e.theme)?r:e.theme[t]||e.theme}function Bn(e,t){const r=typeof t=="function"?t(e):t;if(Array.isArray(r))return r.flatMap(n=>Bn(e,n));if(Array.isArray(r==null?void 0:r.variants)){let n;if(r.isProcessed)n=r.style;else{const{variants:i,...a}=r;n=a}return vl(e,r.variants,[n])}return r!=null&&r.isProcessed?r.style:r}function vl(e,t,r=[]){var i;let n;e:for(let a=0;a<t.length;a+=1){const o=t[a];if(typeof o.props=="function"){if(n??(n={...e,...e.ownerState,ownerState:e.ownerState}),!o.props(n))continue}else for(const s in o.props)if(e[s]!==o.props[s]&&((i=e.ownerState)==null?void 0:i[s])!==o.props[s])continue e;typeof o.style=="function"?(n??(n={...e,...e.ownerState,ownerState:e.ownerState}),r.push(o.style(n))):r.push(o.style)}return r}function Xp(e={}){const{themeId:t,defaultTheme:r=Yp,rootShouldForwardProp:n=Ai,slotShouldForwardProp:i=Ai}=e;function a(s){Zp(s,t,r)}return(s,l={})=>{Bp(s,v=>v.filter(B=>B!==Gr));const{name:p,slot:u,skipVariantsResolver:d,skipSx:f,overridesResolver:g=Gp(bl(u)),...S}=l,c=d!==void 0?d:u&&u!=="Root"&&u!=="root"||!1,b=f||!1;let y=Ai;u==="Root"||u==="root"?y=n:u?y=i:rd(s)&&(y=void 0);const j=Vp(s,{shouldForwardProp:y,label:ed(p,u),...S}),R=v=>{if(v.__emotion_real===v)return v;if(typeof v=="function")return function(A){return Bn(A,v)};if(Ot(v)){const B=xl(v);return B.variants?function(H){return Bn(H,B)}:B.style}return v},k=(...v)=>{const B=[],A=v.map(R),H=[];if(B.push(a),p&&g&&H.push(function(M){var ae,he;const N=(he=(ae=M.theme.components)==null?void 0:ae[p])==null?void 0:he.styleOverrides;if(!N)return null;const J={};for(const ie in N)J[ie]=Bn(M,N[ie]);return g(M,J)}),p&&!c&&H.push(function(M){var J,ae;const q=M.theme,N=(ae=(J=q==null?void 0:q.components)==null?void 0:J[p])==null?void 0:ae.variants;return N?vl(M,N):null}),b||H.push(Gr),Array.isArray(A[0])){const z=A.shift(),M=new Array(B.length).fill(""),q=new Array(H.length).fill("");let N;N=[...M,...z,...q],N.raw=[...M,...z.raw,...q],B.unshift(N)}const U=[...B,...A,...H],h=j(...U);return s.muiName&&(h.muiName=s.muiName),process.env.NODE_ENV!=="production"&&(h.displayName=Jp(p,u,s)),h};return j.withConfig&&(k.withConfig=j.withConfig),k}}function Jp(e,t,r){return e?`${e}${Re(t||"")}`:`Styled(${Qp(r)})`}function ed(e,t){let r;return process.env.NODE_ENV!=="production"&&e&&(r=`${e}-${bl(t||"Root")}`),r}function td(e){for(const t in e)return!1;return!0}function rd(e){return typeof e=="string"&&e.charCodeAt(0)>96}function bl(e){return e&&e.charAt(0).toLowerCase()+e.slice(1)}function Ji(e,t){const r={...t};for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)){const i=n;if(i==="components"||i==="slots")r[i]={...e[i],...r[i]};else if(i==="componentsProps"||i==="slotProps"){const a=e[i],o=t[i];if(!o)r[i]=a||{};else if(!a)r[i]=o;else{r[i]={...o};for(const s in a)if(Object.prototype.hasOwnProperty.call(a,s)){const l=s;r[i][l]=Ji(a[l],o[l])}}}else r[i]===void 0&&(r[i]=e[i])}return r}const nd=typeof window<"u"?te.useLayoutEffect:te.useEffect;function id(e,t=Number.MIN_SAFE_INTEGER,r=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,r))}function Da(e,t=0,r=1){return process.env.NODE_ENV!=="production"&&(e<t||e>r)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${r}].`),id(e,t,r)}function ad(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let r=e.match(t);return r&&r[0].length===1&&(r=r.map(n=>n+n)),process.env.NODE_ENV!=="production"&&e.length!==e.trim().length&&console.error(`MUI: The color: "${e}" is invalid. Make sure the color input doesn't contain leading/trailing space.`),r?`rgb${r.length===4?"a":""}(${r.map((n,i)=>i<3?parseInt(n,16):Math.round(parseInt(n,16)/255*1e3)/1e3).join(", ")})`:""}function tr(e){if(e.type)return e;if(e.charAt(0)==="#")return tr(ad(e));const t=e.indexOf("("),r=e.substring(0,t);if(!["rgb","rgba","hsl","hsla","color"].includes(r))throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color.
48
48
  The following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().`:er(9,e));let n=e.substring(t+1,e.length-1),i;if(r==="color"){if(n=n.split(" "),i=n.shift(),n.length===4&&n[3].charAt(0)==="/"&&(n[3]=n[3].slice(1)),!["srgb","display-p3","a98-rgb","prophoto-rgb","rec-2020"].includes(i))throw new Error(process.env.NODE_ENV!=="production"?`MUI: unsupported \`${i}\` color space.
49
- The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:er(10,i))}else n=n.split(",");return n=n.map(a=>parseFloat(a)),{type:r,values:n,colorSpace:i}}const od=e=>{const t=tr(e);return t.values.slice(0,3).map((r,n)=>t.type.includes("hsl")&&n!==0?`${r}%`:r).join(" ")},ln=(e,t)=>{try{return od(e)}catch{return t&&process.env.NODE_ENV!=="production"&&console.warn(t),e}};function vi(e){const{type:t,colorSpace:r}=e;let{values:n}=e;return t.includes("rgb")?n=n.map((i,a)=>a<3?parseInt(i,10):i):t.includes("hsl")&&(n[1]=`${n[1]}%`,n[2]=`${n[2]}%`),t.includes("color")?n=`${r} ${n.join(" ")}`:n=`${n.join(", ")}`,`${t}(${n})`}function xl(e){e=tr(e);const{values:t}=e,r=t[0],n=t[1]/100,i=t[2]/100,a=n*Math.min(i,1-i),o=(p,u=(p+r/30)%12)=>i-a*Math.max(Math.min(u-3,9-u,1),-1);let s="rgb";const l=[Math.round(o(0)*255),Math.round(o(8)*255),Math.round(o(4)*255)];return e.type==="hsla"&&(s+="a",l.push(t[3])),vi({type:s,values:l})}function ea(e){e=tr(e);let t=e.type==="hsl"||e.type==="hsla"?tr(xl(e)).values:e.values;return t=t.map(r=>(e.type!=="color"&&(r/=255),r<=.03928?r/12.92:((r+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function zo(e,t){const r=ea(e),n=ea(t);return(Math.max(r,n)+.05)/(Math.min(r,n)+.05)}function Ft(e,t){return e=tr(e),t=Aa(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,vi(e)}function $n(e,t,r){try{return Ft(e,t)}catch{return e}}function Ra(e,t){if(e=tr(e),t=Aa(t),e.type.includes("hsl"))e.values[2]*=1-t;else if(e.type.includes("rgb")||e.type.includes("color"))for(let r=0;r<3;r+=1)e.values[r]*=1-t;return vi(e)}function Oe(e,t,r){try{return Ra(e,t)}catch{return e}}function $a(e,t){if(e=tr(e),t=Aa(t),e.type.includes("hsl"))e.values[2]+=(100-e.values[2])*t;else if(e.type.includes("rgb"))for(let r=0;r<3;r+=1)e.values[r]+=(255-e.values[r])*t;else if(e.type.includes("color"))for(let r=0;r<3;r+=1)e.values[r]+=(1-e.values[r])*t;return vi(e)}function je(e,t,r){try{return $a(e,t)}catch{return e}}function sd(e,t=.15){return ea(e)>.5?Ra(e,t):$a(e,t)}function Dn(e,t,r){try{return sd(e,t)}catch{return e}}const ld=ne.createContext(void 0);process.env.NODE_ENV!=="production"&&(w.node,w.object);function cd(e){const{theme:t,name:r,props:n}=e;if(!t||!t.components||!t.components[r])return n;const i=t.components[r];return i.defaultProps?Ji(i.defaultProps,n):!i.styleOverrides&&!i.variants?Ji(i,n):n}function ud({props:e,name:t}){const r=ne.useContext(ld);return cd({props:e,name:t,theme:{components:r}})}const Vo={theme:void 0};function pd(e){let t,r;return function(i){let a=t;return(a===void 0||i.theme!==r)&&(Vo.theme=i.theme,a=ml(e(Vo)),t=a,r=i.theme),a}}function dd(e=""){function t(...n){if(!n.length)return"";const i=n[0];return typeof i=="string"&&!i.match(/(#|\(|\)|(-?(\d*\.)?\d+)(px|em|%|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc))|^(-?(\d*\.)?\d+)$|(\d+ \d+ \d+)/)?`, var(--${e?`${e}-`:""}${i}${t(...n.slice(1))})`:`, ${i}`}return(n,...i)=>`var(--${e?`${e}-`:""}${n}${t(...i)})`}const Bo=(e,t,r,n=[])=>{let i=e;t.forEach((a,o)=>{o===t.length-1?Array.isArray(i)?i[Number(a)]=r:i&&typeof i=="object"&&(i[a]=r):i&&typeof i=="object"&&(i[a]||(i[a]=n.includes(a)?[]:{}),i=i[a])})},fd=(e,t,r)=>{function n(i,a=[],o=[]){Object.entries(i).forEach(([s,l])=>{(!r||r&&!r([...a,s]))&&l!=null&&(typeof l=="object"&&Object.keys(l).length>0?n(l,[...a,s],Array.isArray(l)?[...o,s]:o):t([...a,s],l,o))})}n(e)},hd=(e,t)=>typeof t=="number"?["lineHeight","fontWeight","opacity","zIndex"].some(n=>e.includes(n))||e[e.length-1].toLowerCase().includes("opacity")?t:`${t}px`:t;function Ai(e,t){const{prefix:r,shouldSkipGeneratingVar:n}=t||{},i={},a={},o={};return fd(e,(s,l,p)=>{if((typeof l=="string"||typeof l=="number")&&(!n||!n(s,l))){const u=`--${r?`${r}-`:""}${s.join("-")}`,d=hd(s,l);Object.assign(i,{[u]:d}),Bo(a,s,`var(${u})`,p),Bo(o,s,`var(${u}, ${d})`,p)}},s=>s[0]==="vars"),{css:i,vars:a,varsWithDefaults:o}}function md(e,t={}){const{getSelector:r=b,disableCssColorScheme:n,colorSchemeSelector:i}=t,{colorSchemes:a={},components:o,defaultColorScheme:s="light",...l}=e,{vars:p,css:u,varsWithDefaults:d}=Ai(l,t);let f=d;const y={},{[s]:S,...c}=a;if(Object.entries(c||{}).forEach(([A,k])=>{const{vars:x,css:B,varsWithDefaults:_}=Ai(k,t);f=it(f,_),y[A]={css:B,vars:x}}),S){const{css:A,vars:k,varsWithDefaults:x}=Ai(S,t);f=it(f,x),y[s]={css:A,vars:k}}function b(A,k){var B,_;let x=i;if(i==="class"&&(x=".%s"),i==="data"&&(x="[data-%s]"),i!=null&&i.startsWith("data-")&&!i.includes("%s")&&(x=`[${i}="%s"]`),A){if(x==="media")return e.defaultColorScheme===A?":root":{[`@media (prefers-color-scheme: ${((_=(B=a[A])==null?void 0:B.palette)==null?void 0:_.mode)||A})`]:{":root":k}};if(x)return e.defaultColorScheme===A?`:root, ${x.replace("%s",String(A))}`:x.replace("%s",String(A))}return":root"}return{vars:f,generateThemeVars:()=>{let A={...p};return Object.entries(y).forEach(([,{vars:k}])=>{A=it(A,k)}),A},generateStyleSheets:()=>{var K,W;const A=[],k=e.defaultColorScheme||"light";function x(h,M){Object.keys(M).length&&A.push(typeof h=="string"?{[h]:{...M}}:h)}x(r(void 0,{...u}),u);const{[k]:B,..._}=y;if(B){const{css:h}=B,M=(W=(K=a[k])==null?void 0:K.palette)==null?void 0:W.mode,P=!n&&M?{colorScheme:M,...h}:{...h};x(r(k,{...P}),P)}return Object.entries(_).forEach(([h,{css:M}])=>{var N,X;const P=(X=(N=a[h])==null?void 0:N.palette)==null?void 0:X.mode,q=!n&&P?{colorScheme:P,...M}:{...M};x(r(h,{...q}),q)}),A}}}function gd(e){return function(r){return e==="media"?(process.env.NODE_ENV!=="production"&&r!=="light"&&r!=="dark"&&console.error(`MUI: @media (prefers-color-scheme) supports only 'light' or 'dark', but receive '${r}'.`),`@media (prefers-color-scheme: ${r})`):e?e.startsWith("data-")&&!e.includes("%s")?`[${e}="${r}"] &`:e==="class"?`.${r} &`:e==="data"?`[data-${r}] &`:`${e.replace("%s",r)} &`:"&"}}const gn={black:"#000",white:"#fff"},yd={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},_r={50:"#f3e5f5",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",700:"#7b1fa2"},Ar={300:"#e57373",400:"#ef5350",500:"#f44336",700:"#d32f2f",800:"#c62828"},on={300:"#ffb74d",400:"#ffa726",500:"#ff9800",700:"#f57c00",900:"#e65100"},Rr={50:"#e3f2fd",200:"#90caf9",400:"#42a5f5",700:"#1976d2",800:"#1565c0"},$r={300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",700:"#0288d1",900:"#01579b"},Dr={300:"#81c784",400:"#66bb6a",500:"#4caf50",700:"#388e3c",800:"#2e7d32",900:"#1b5e20"};function vl(){return{text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:gn.white,default:gn.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}}}const xd=vl();function bl(){return{text:{primary:gn.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:gn.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}}}const No=bl();function Lo(e,t,r,n){const i=n.light||n,a=n.dark||n*1.5;e[t]||(e.hasOwnProperty(r)?e[t]=e[r]:t==="light"?e.light=$a(e.main,i):t==="dark"&&(e.dark=Ra(e.main,a)))}function vd(e="light"){return e==="dark"?{main:Rr[200],light:Rr[50],dark:Rr[400]}:{main:Rr[700],light:Rr[400],dark:Rr[800]}}function bd(e="light"){return e==="dark"?{main:_r[200],light:_r[50],dark:_r[400]}:{main:_r[500],light:_r[300],dark:_r[700]}}function wd(e="light"){return e==="dark"?{main:Ar[500],light:Ar[300],dark:Ar[700]}:{main:Ar[700],light:Ar[400],dark:Ar[800]}}function Sd(e="light"){return e==="dark"?{main:$r[400],light:$r[300],dark:$r[700]}:{main:$r[700],light:$r[500],dark:$r[900]}}function Cd(e="light"){return e==="dark"?{main:Dr[400],light:Dr[300],dark:Dr[700]}:{main:Dr[800],light:Dr[500],dark:Dr[900]}}function Ed(e="light"){return e==="dark"?{main:on[400],light:on[300],dark:on[700]}:{main:"#ed6c02",light:on[500],dark:on[900]}}function Da(e){const{mode:t="light",contrastThreshold:r=3,tonalOffset:n=.2,...i}=e,a=e.primary||vd(t),o=e.secondary||bd(t),s=e.error||wd(t),l=e.info||Sd(t),p=e.success||Cd(t),u=e.warning||Ed(t);function d(c){const b=zo(c,No.text.primary)>=r?No.text.primary:xd.text.primary;if(process.env.NODE_ENV!=="production"){const g=zo(c,b);g<3&&console.error([`MUI: The contrast ratio of ${g}:1 for ${b} on ${c}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(`
50
- `))}return b}const f=({color:c,name:b,mainShade:g=500,lightShade:O=300,darkShade:A=700})=>{if(c={...c},!c.main&&c[g]&&(c.main=c[g]),!c.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${b?` (${b})`:""} provided to augmentColor(color) is invalid.
51
- The color object needs to have a \`main\` property or a \`${g}\` property.`:er(11,b?` (${b})`:"",g));if(typeof c.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${b?` (${b})`:""} provided to augmentColor(color) is invalid.
49
+ The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:er(10,i))}else n=n.split(",");return n=n.map(a=>parseFloat(a)),{type:r,values:n,colorSpace:i}}const od=e=>{const t=tr(e);return t.values.slice(0,3).map((r,n)=>t.type.includes("hsl")&&n!==0?`${r}%`:r).join(" ")},ln=(e,t)=>{try{return od(e)}catch{return t&&process.env.NODE_ENV!=="production"&&console.warn(t),e}};function vi(e){const{type:t,colorSpace:r}=e;let{values:n}=e;return t.includes("rgb")?n=n.map((i,a)=>a<3?parseInt(i,10):i):t.includes("hsl")&&(n[1]=`${n[1]}%`,n[2]=`${n[2]}%`),t.includes("color")?n=`${r} ${n.join(" ")}`:n=`${n.join(", ")}`,`${t}(${n})`}function wl(e){e=tr(e);const{values:t}=e,r=t[0],n=t[1]/100,i=t[2]/100,a=n*Math.min(i,1-i),o=(p,u=(p+r/30)%12)=>i-a*Math.max(Math.min(u-3,9-u,1),-1);let s="rgb";const l=[Math.round(o(0)*255),Math.round(o(8)*255),Math.round(o(4)*255)];return e.type==="hsla"&&(s+="a",l.push(t[3])),vi({type:s,values:l})}function ea(e){e=tr(e);let t=e.type==="hsl"||e.type==="hsla"?tr(wl(e)).values:e.values;return t=t.map(r=>(e.type!=="color"&&(r/=255),r<=.03928?r/12.92:((r+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function No(e,t){const r=ea(e),n=ea(t);return(Math.max(r,n)+.05)/(Math.min(r,n)+.05)}function Ft(e,t){return e=tr(e),t=Da(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,vi(e)}function $n(e,t,r){try{return Ft(e,t)}catch{return e}}function Pa(e,t){if(e=tr(e),t=Da(t),e.type.includes("hsl"))e.values[2]*=1-t;else if(e.type.includes("rgb")||e.type.includes("color"))for(let r=0;r<3;r+=1)e.values[r]*=1-t;return vi(e)}function je(e,t,r){try{return Pa(e,t)}catch{return e}}function Ia(e,t){if(e=tr(e),t=Da(t),e.type.includes("hsl"))e.values[2]+=(100-e.values[2])*t;else if(e.type.includes("rgb"))for(let r=0;r<3;r+=1)e.values[r]+=(255-e.values[r])*t;else if(e.type.includes("color"))for(let r=0;r<3;r+=1)e.values[r]+=(1-e.values[r])*t;return vi(e)}function Fe(e,t,r){try{return Ia(e,t)}catch{return e}}function sd(e,t=.15){return ea(e)>.5?Pa(e,t):Ia(e,t)}function Dn(e,t,r){try{return sd(e,t)}catch{return e}}const ld=te.createContext(void 0);process.env.NODE_ENV!=="production"&&(w.node,w.object);function cd(e){const{theme:t,name:r,props:n}=e;if(!t||!t.components||!t.components[r])return n;const i=t.components[r];return i.defaultProps?Ji(i.defaultProps,n):!i.styleOverrides&&!i.variants?Ji(i,n):n}function ud({props:e,name:t}){const r=te.useContext(ld);return cd({props:e,name:t,theme:{components:r}})}const Lo={theme:void 0};function pd(e){let t,r;return function(i){let a=t;return(a===void 0||i.theme!==r)&&(Lo.theme=i.theme,a=xl(e(Lo)),t=a,r=i.theme),a}}function dd(e=""){function t(...n){if(!n.length)return"";const i=n[0];return typeof i=="string"&&!i.match(/(#|\(|\)|(-?(\d*\.)?\d+)(px|em|%|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc))|^(-?(\d*\.)?\d+)$|(\d+ \d+ \d+)/)?`, var(--${e?`${e}-`:""}${i}${t(...n.slice(1))})`:`, ${i}`}return(n,...i)=>`var(--${e?`${e}-`:""}${n}${t(...i)})`}const qo=(e,t,r,n=[])=>{let i=e;t.forEach((a,o)=>{o===t.length-1?Array.isArray(i)?i[Number(a)]=r:i&&typeof i=="object"&&(i[a]=r):i&&typeof i=="object"&&(i[a]||(i[a]=n.includes(a)?[]:{}),i=i[a])})},fd=(e,t,r)=>{function n(i,a=[],o=[]){Object.entries(i).forEach(([s,l])=>{(!r||r&&!r([...a,s]))&&l!=null&&(typeof l=="object"&&Object.keys(l).length>0?n(l,[...a,s],Array.isArray(l)?[...o,s]:o):t([...a,s],l,o))})}n(e)},hd=(e,t)=>typeof t=="number"?["lineHeight","fontWeight","opacity","zIndex"].some(n=>e.includes(n))||e[e.length-1].toLowerCase().includes("opacity")?t:`${t}px`:t;function _i(e,t){const{prefix:r,shouldSkipGeneratingVar:n}=t||{},i={},a={},o={};return fd(e,(s,l,p)=>{if((typeof l=="string"||typeof l=="number")&&(!n||!n(s,l))){const u=`--${r?`${r}-`:""}${s.join("-")}`,d=hd(s,l);Object.assign(i,{[u]:d}),qo(a,s,`var(${u})`,p),qo(o,s,`var(${u}, ${d})`,p)}},s=>s[0]==="vars"),{css:i,vars:a,varsWithDefaults:o}}function md(e,t={}){const{getSelector:r=b,disableCssColorScheme:n,colorSchemeSelector:i}=t,{colorSchemes:a={},components:o,defaultColorScheme:s="light",...l}=e,{vars:p,css:u,varsWithDefaults:d}=_i(l,t);let f=d;const g={},{[s]:S,...c}=a;if(Object.entries(c||{}).forEach(([R,k])=>{const{vars:v,css:B,varsWithDefaults:A}=_i(k,t);f=it(f,A),g[R]={css:B,vars:v}}),S){const{css:R,vars:k,varsWithDefaults:v}=_i(S,t);f=it(f,v),g[s]={css:R,vars:k}}function b(R,k){var B,A;let v=i;if(i==="class"&&(v=".%s"),i==="data"&&(v="[data-%s]"),i!=null&&i.startsWith("data-")&&!i.includes("%s")&&(v=`[${i}="%s"]`),R){if(v==="media")return e.defaultColorScheme===R?":root":{[`@media (prefers-color-scheme: ${((A=(B=a[R])==null?void 0:B.palette)==null?void 0:A.mode)||R})`]:{":root":k}};if(v)return e.defaultColorScheme===R?`:root, ${v.replace("%s",String(R))}`:v.replace("%s",String(R))}return":root"}return{vars:f,generateThemeVars:()=>{let R={...p};return Object.entries(g).forEach(([,{vars:k}])=>{R=it(R,k)}),R},generateStyleSheets:()=>{var H,U;const R=[],k=e.defaultColorScheme||"light";function v(h,z){Object.keys(z).length&&R.push(typeof h=="string"?{[h]:{...z}}:h)}v(r(void 0,{...u}),u);const{[k]:B,...A}=g;if(B){const{css:h}=B,z=(U=(H=a[k])==null?void 0:H.palette)==null?void 0:U.mode,M=!n&&z?{colorScheme:z,...h}:{...h};v(r(k,{...M}),M)}return Object.entries(A).forEach(([h,{css:z}])=>{var N,J;const M=(J=(N=a[h])==null?void 0:N.palette)==null?void 0:J.mode,q=!n&&M?{colorScheme:M,...z}:{...z};v(r(h,{...q}),q)}),R}}}function yd(e){return function(r){return e==="media"?(process.env.NODE_ENV!=="production"&&r!=="light"&&r!=="dark"&&console.error(`MUI: @media (prefers-color-scheme) supports only 'light' or 'dark', but receive '${r}'.`),`@media (prefers-color-scheme: ${r})`):e?e.startsWith("data-")&&!e.includes("%s")?`[${e}="${r}"] &`:e==="class"?`.${r} &`:e==="data"?`[data-${r}] &`:`${e.replace("%s",r)} &`:"&"}}const yn={black:"#000",white:"#fff"},gd={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},Ar={50:"#f3e5f5",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",700:"#7b1fa2"},_r={300:"#e57373",400:"#ef5350",500:"#f44336",700:"#d32f2f",800:"#c62828"},on={300:"#ffb74d",400:"#ffa726",500:"#ff9800",700:"#f57c00",900:"#e65100"},Rr={50:"#e3f2fd",200:"#90caf9",400:"#42a5f5",700:"#1976d2",800:"#1565c0"},$r={300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",700:"#0288d1",900:"#01579b"},Dr={300:"#81c784",400:"#66bb6a",500:"#4caf50",700:"#388e3c",800:"#2e7d32",900:"#1b5e20"};function Sl(){return{text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:yn.white,default:yn.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}}}const xd=Sl();function Cl(){return{text:{primary:yn.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:yn.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}}}const Uo=Cl();function Wo(e,t,r,n){const i=n.light||n,a=n.dark||n*1.5;e[t]||(e.hasOwnProperty(r)?e[t]=e[r]:t==="light"?e.light=Ia(e.main,i):t==="dark"&&(e.dark=Pa(e.main,a)))}function vd(e="light"){return e==="dark"?{main:Rr[200],light:Rr[50],dark:Rr[400]}:{main:Rr[700],light:Rr[400],dark:Rr[800]}}function bd(e="light"){return e==="dark"?{main:Ar[200],light:Ar[50],dark:Ar[400]}:{main:Ar[500],light:Ar[300],dark:Ar[700]}}function wd(e="light"){return e==="dark"?{main:_r[500],light:_r[300],dark:_r[700]}:{main:_r[700],light:_r[400],dark:_r[800]}}function Sd(e="light"){return e==="dark"?{main:$r[400],light:$r[300],dark:$r[700]}:{main:$r[700],light:$r[500],dark:$r[900]}}function Cd(e="light"){return e==="dark"?{main:Dr[400],light:Dr[300],dark:Dr[700]}:{main:Dr[800],light:Dr[500],dark:Dr[900]}}function Ed(e="light"){return e==="dark"?{main:on[400],light:on[300],dark:on[700]}:{main:"#ed6c02",light:on[500],dark:on[900]}}function Ma(e){const{mode:t="light",contrastThreshold:r=3,tonalOffset:n=.2,...i}=e,a=e.primary||vd(t),o=e.secondary||bd(t),s=e.error||wd(t),l=e.info||Sd(t),p=e.success||Cd(t),u=e.warning||Ed(t);function d(c){const b=No(c,Uo.text.primary)>=r?Uo.text.primary:xd.text.primary;if(process.env.NODE_ENV!=="production"){const y=No(c,b);y<3&&console.error([`MUI: The contrast ratio of ${y}:1 for ${b} on ${c}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(`
50
+ `))}return b}const f=({color:c,name:b,mainShade:y=500,lightShade:j=300,darkShade:R=700})=>{if(c={...c},!c.main&&c[y]&&(c.main=c[y]),!c.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${b?` (${b})`:""} provided to augmentColor(color) is invalid.
51
+ The color object needs to have a \`main\` property or a \`${y}\` property.`:er(11,b?` (${b})`:"",y));if(typeof c.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${b?` (${b})`:""} provided to augmentColor(color) is invalid.
52
52
  \`color.main\` should be a string, but \`${JSON.stringify(c.main)}\` was provided instead.
53
53
 
54
54
  Did you intend to use one of the following approaches?
@@ -61,18 +61,18 @@ const theme1 = createTheme({ palette: {
61
61
 
62
62
  const theme2 = createTheme({ palette: {
63
63
  primary: { main: green[500] },
64
- } });`:er(12,b?` (${b})`:"",JSON.stringify(c.main)));return Lo(c,"light",O,n),Lo(c,"dark",A,n),c.contrastText||(c.contrastText=d(c.main)),c};let y;return t==="light"?y=vl():t==="dark"&&(y=bl()),process.env.NODE_ENV!=="production"&&(y||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),it({common:{...gn},mode:t,primary:f({color:a,name:"primary"}),secondary:f({color:o,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:f({color:s,name:"error"}),warning:f({color:u,name:"warning"}),info:f({color:l,name:"info"}),success:f({color:p,name:"success"}),grey:yd,contrastThreshold:r,getContrastText:d,augmentColor:f,tonalOffset:n,...y},i)}function kd(e){const t={};return Object.entries(e).forEach(n=>{const[i,a]=n;typeof a=="object"&&(t[i]=`${a.fontStyle?`${a.fontStyle} `:""}${a.fontVariant?`${a.fontVariant} `:""}${a.fontWeight?`${a.fontWeight} `:""}${a.fontStretch?`${a.fontStretch} `:""}${a.fontSize||""}${a.lineHeight?`/${a.lineHeight} `:""}${a.fontFamily||""}`)}),t}function Td(e,t){return{toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}},...t}}function Od(e){return Math.round(e*1e5)/1e5}const qo={textTransform:"uppercase"},Uo='"Roboto", "Helvetica", "Arial", sans-serif';function jd(e,t){const{fontFamily:r=Uo,fontSize:n=14,fontWeightLight:i=300,fontWeightRegular:a=400,fontWeightMedium:o=500,fontWeightBold:s=700,htmlFontSize:l=16,allVariants:p,pxToRem:u,...d}=typeof t=="function"?t(e):t;process.env.NODE_ENV!=="production"&&(typeof n!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof l!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const f=n/14,y=u||(b=>`${b/l*f}rem`),S=(b,g,O,A,k)=>({fontFamily:r,fontWeight:b,fontSize:y(g),lineHeight:O,...r===Uo?{letterSpacing:`${Od(A/g)}em`}:{},...k,...p}),c={h1:S(i,96,1.167,-1.5),h2:S(i,60,1.2,-.5),h3:S(a,48,1.167,0),h4:S(a,34,1.235,.25),h5:S(a,24,1.334,0),h6:S(o,20,1.6,.15),subtitle1:S(a,16,1.75,.15),subtitle2:S(o,14,1.57,.1),body1:S(a,16,1.5,.15),body2:S(a,14,1.43,.15),button:S(o,14,1.75,.4,qo),caption:S(a,12,1.66,.4),overline:S(a,12,2.66,1,qo),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return it({htmlFontSize:l,pxToRem:y,fontFamily:r,fontSize:n,fontWeightLight:i,fontWeightRegular:a,fontWeightMedium:o,fontWeightBold:s,...c},d,{clone:!1})}const Fd=.2,_d=.14,Ad=.12;function Fe(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${Fd})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${_d})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${Ad})`].join(",")}const Rd=["none",Fe(0,2,1,-1,0,1,1,0,0,1,3,0),Fe(0,3,1,-2,0,2,2,0,0,1,5,0),Fe(0,3,3,-2,0,3,4,0,0,1,8,0),Fe(0,2,4,-1,0,4,5,0,0,1,10,0),Fe(0,3,5,-1,0,5,8,0,0,1,14,0),Fe(0,3,5,-1,0,6,10,0,0,1,18,0),Fe(0,4,5,-2,0,7,10,1,0,2,16,1),Fe(0,5,5,-3,0,8,10,1,0,3,14,2),Fe(0,5,6,-3,0,9,12,1,0,3,16,2),Fe(0,6,6,-3,0,10,14,1,0,4,18,3),Fe(0,6,7,-4,0,11,15,1,0,4,20,3),Fe(0,7,8,-4,0,12,17,2,0,5,22,4),Fe(0,7,8,-4,0,13,19,2,0,5,24,4),Fe(0,7,9,-4,0,14,21,2,0,5,26,4),Fe(0,8,9,-5,0,15,22,2,0,6,28,5),Fe(0,8,10,-5,0,16,24,2,0,6,30,5),Fe(0,8,11,-5,0,17,26,2,0,6,32,5),Fe(0,9,11,-5,0,18,28,2,0,7,34,6),Fe(0,9,12,-6,0,19,29,2,0,7,36,6),Fe(0,10,13,-6,0,20,31,3,0,8,38,7),Fe(0,10,13,-6,0,21,33,3,0,8,40,7),Fe(0,10,14,-6,0,22,35,3,0,8,42,7),Fe(0,11,14,-7,0,23,36,3,0,9,44,8),Fe(0,11,15,-7,0,24,38,3,0,9,46,8)],$d={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},Dd={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Wo(e){return`${Math.round(e)}ms`}function Pd(e){if(!e)return 0;const t=e/36;return Math.min(Math.round((4+15*t**.25+t/5)*10),3e3)}function Id(e){const t={...$d,...e.easing},r={...Dd,...e.duration};return{getAutoHeightDuration:Pd,create:(i=["all"],a={})=>{const{duration:o=r.standard,easing:s=t.easeInOut,delay:l=0,...p}=a;if(process.env.NODE_ENV!=="production"){const u=f=>typeof f=="string",d=f=>!Number.isNaN(parseFloat(f));!u(i)&&!Array.isArray(i)&&console.error('MUI: Argument "props" must be a string or Array.'),!d(o)&&!u(o)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${o}.`),u(s)||console.error('MUI: Argument "easing" must be a string.'),!d(l)&&!u(l)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof a!="object"&&console.error(["MUI: Secong argument of transition.create must be an object.","Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(`
65
- `)),Object.keys(p).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(p).join(",")}].`)}return(Array.isArray(i)?i:[i]).map(u=>`${u} ${typeof o=="string"?o:Wo(o)} ${s} ${typeof l=="string"?l:Wo(l)}`).join(",")},...e,easing:t,duration:r}}const Md={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500};function zd(e){return Ot(e)||typeof e>"u"||typeof e=="string"||typeof e=="boolean"||typeof e=="number"||Array.isArray(e)}function wl(e={}){const t={...e};function r(n){const i=Object.entries(n);for(let a=0;a<i.length;a++){const[o,s]=i[a];!zd(s)||o.startsWith("unstable_")?delete n[o]:Ot(s)&&(n[o]={...s},r(n[o]))}}return r(t),`import { unstable_createBreakpoints as createBreakpoints, createTransitions } from '@mui/material/styles';
64
+ } });`:er(12,b?` (${b})`:"",JSON.stringify(c.main)));return Wo(c,"light",j,n),Wo(c,"dark",R,n),c.contrastText||(c.contrastText=d(c.main)),c};let g;return t==="light"?g=Sl():t==="dark"&&(g=Cl()),process.env.NODE_ENV!=="production"&&(g||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),it({common:{...yn},mode:t,primary:f({color:a,name:"primary"}),secondary:f({color:o,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:f({color:s,name:"error"}),warning:f({color:u,name:"warning"}),info:f({color:l,name:"info"}),success:f({color:p,name:"success"}),grey:gd,contrastThreshold:r,getContrastText:d,augmentColor:f,tonalOffset:n,...g},i)}function kd(e){const t={};return Object.entries(e).forEach(n=>{const[i,a]=n;typeof a=="object"&&(t[i]=`${a.fontStyle?`${a.fontStyle} `:""}${a.fontVariant?`${a.fontVariant} `:""}${a.fontWeight?`${a.fontWeight} `:""}${a.fontStretch?`${a.fontStretch} `:""}${a.fontSize||""}${a.lineHeight?`/${a.lineHeight} `:""}${a.fontFamily||""}`)}),t}function Td(e,t){return{toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}},...t}}function Od(e){return Math.round(e*1e5)/1e5}const Ho={textTransform:"uppercase"},Ko='"Roboto", "Helvetica", "Arial", sans-serif';function jd(e,t){const{fontFamily:r=Ko,fontSize:n=14,fontWeightLight:i=300,fontWeightRegular:a=400,fontWeightMedium:o=500,fontWeightBold:s=700,htmlFontSize:l=16,allVariants:p,pxToRem:u,...d}=typeof t=="function"?t(e):t;process.env.NODE_ENV!=="production"&&(typeof n!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof l!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const f=n/14,g=u||(b=>`${b/l*f}rem`),S=(b,y,j,R,k)=>({fontFamily:r,fontWeight:b,fontSize:g(y),lineHeight:j,...r===Ko?{letterSpacing:`${Od(R/y)}em`}:{},...k,...p}),c={h1:S(i,96,1.167,-1.5),h2:S(i,60,1.2,-.5),h3:S(a,48,1.167,0),h4:S(a,34,1.235,.25),h5:S(a,24,1.334,0),h6:S(o,20,1.6,.15),subtitle1:S(a,16,1.75,.15),subtitle2:S(o,14,1.57,.1),body1:S(a,16,1.5,.15),body2:S(a,14,1.43,.15),button:S(o,14,1.75,.4,Ho),caption:S(a,12,1.66,.4),overline:S(a,12,2.66,1,Ho),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return it({htmlFontSize:l,pxToRem:g,fontFamily:r,fontSize:n,fontWeightLight:i,fontWeightRegular:a,fontWeightMedium:o,fontWeightBold:s,...c},d,{clone:!1})}const Fd=.2,Ad=.14,_d=.12;function Ae(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${Fd})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${Ad})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${_d})`].join(",")}const Rd=["none",Ae(0,2,1,-1,0,1,1,0,0,1,3,0),Ae(0,3,1,-2,0,2,2,0,0,1,5,0),Ae(0,3,3,-2,0,3,4,0,0,1,8,0),Ae(0,2,4,-1,0,4,5,0,0,1,10,0),Ae(0,3,5,-1,0,5,8,0,0,1,14,0),Ae(0,3,5,-1,0,6,10,0,0,1,18,0),Ae(0,4,5,-2,0,7,10,1,0,2,16,1),Ae(0,5,5,-3,0,8,10,1,0,3,14,2),Ae(0,5,6,-3,0,9,12,1,0,3,16,2),Ae(0,6,6,-3,0,10,14,1,0,4,18,3),Ae(0,6,7,-4,0,11,15,1,0,4,20,3),Ae(0,7,8,-4,0,12,17,2,0,5,22,4),Ae(0,7,8,-4,0,13,19,2,0,5,24,4),Ae(0,7,9,-4,0,14,21,2,0,5,26,4),Ae(0,8,9,-5,0,15,22,2,0,6,28,5),Ae(0,8,10,-5,0,16,24,2,0,6,30,5),Ae(0,8,11,-5,0,17,26,2,0,6,32,5),Ae(0,9,11,-5,0,18,28,2,0,7,34,6),Ae(0,9,12,-6,0,19,29,2,0,7,36,6),Ae(0,10,13,-6,0,20,31,3,0,8,38,7),Ae(0,10,13,-6,0,21,33,3,0,8,40,7),Ae(0,10,14,-6,0,22,35,3,0,8,42,7),Ae(0,11,14,-7,0,23,36,3,0,9,44,8),Ae(0,11,15,-7,0,24,38,3,0,9,46,8)],$d={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},Dd={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Qo(e){return`${Math.round(e)}ms`}function Pd(e){if(!e)return 0;const t=e/36;return Math.min(Math.round((4+15*t**.25+t/5)*10),3e3)}function Id(e){const t={...$d,...e.easing},r={...Dd,...e.duration};return{getAutoHeightDuration:Pd,create:(i=["all"],a={})=>{const{duration:o=r.standard,easing:s=t.easeInOut,delay:l=0,...p}=a;if(process.env.NODE_ENV!=="production"){const u=f=>typeof f=="string",d=f=>!Number.isNaN(parseFloat(f));!u(i)&&!Array.isArray(i)&&console.error('MUI: Argument "props" must be a string or Array.'),!d(o)&&!u(o)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${o}.`),u(s)||console.error('MUI: Argument "easing" must be a string.'),!d(l)&&!u(l)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof a!="object"&&console.error(["MUI: Secong argument of transition.create must be an object.","Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(`
65
+ `)),Object.keys(p).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(p).join(",")}].`)}return(Array.isArray(i)?i:[i]).map(u=>`${u} ${typeof o=="string"?o:Qo(o)} ${s} ${typeof l=="string"?l:Qo(l)}`).join(",")},...e,easing:t,duration:r}}const Md={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500};function zd(e){return Ot(e)||typeof e>"u"||typeof e=="string"||typeof e=="boolean"||typeof e=="number"||Array.isArray(e)}function El(e={}){const t={...e};function r(n){const i=Object.entries(n);for(let a=0;a<i.length;a++){const[o,s]=i[a];!zd(s)||o.startsWith("unstable_")?delete n[o]:Ot(s)&&(n[o]={...s},r(n[o]))}}return r(t),`import { unstable_createBreakpoints as createBreakpoints, createTransitions } from '@mui/material/styles';
66
66
 
67
67
  const theme = ${JSON.stringify(t,null,2)};
68
68
 
69
69
  theme.breakpoints = createBreakpoints(theme.breakpoints || {});
70
70
  theme.transitions = createTransitions(theme.transitions || {});
71
71
 
72
- export default theme;`}function ta(e={},...t){const{breakpoints:r,mixins:n={},spacing:i,palette:a={},transitions:o={},typography:s={},shape:l,...p}=e;if(e.vars&&e.generateThemeVars===void 0)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name or follow the [docs](https://mui.com/material-ui/customization/css-theme-variables/usage/) to enable the feature.":er(20));const u=Da(a),d=fl(e);let f=it(d,{mixins:Td(d.breakpoints,n),palette:u,shadows:Rd.slice(),typography:jd(u,s),transitions:Id(o),zIndex:{...Md}});if(f=it(f,p),f=t.reduce((y,S)=>it(y,S),f),process.env.NODE_ENV!=="production"){const y=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],S=(c,b)=>{let g;for(g in c){const O=c[g];if(y.includes(g)&&Object.keys(O).length>0){if(process.env.NODE_ENV!=="production"){const A=nr("",g);console.error([`MUI: The \`${b}\` component increases the CSS specificity of the \`${g}\` internal state.`,"You can not override it like this: ",JSON.stringify(c,null,2),"",`Instead, you need to use the '&.${A}' syntax:`,JSON.stringify({root:{[`&.${A}`]:O}},null,2),"","https://mui.com/r/state-classes-guide"].join(`
73
- `))}c[g]={}}}};Object.keys(f.components).forEach(c=>{const b=f.components[c].styleOverrides;b&&c.startsWith("Mui")&&S(b,c)})}return f.unstable_sxConfig={...Tn,...p==null?void 0:p.unstable_sxConfig},f.unstable_sx=function(S){return Gr({sx:S,theme:this})},f.toRuntimeSource=wl,f}function Vd(e){let t;return e<1?t=5.11916*e**2:t=4.5*Math.log(e+1)+2,Math.round(t*10)/1e3}const Bd=[...Array(25)].map((e,t)=>{if(t===0)return"none";const r=Vd(t);return`linear-gradient(rgba(255 255 255 / ${r}), rgba(255 255 255 / ${r}))`});function Sl(e){return{inputPlaceholder:e==="dark"?.5:.42,inputUnderline:e==="dark"?.7:.42,switchTrackDisabled:e==="dark"?.2:.12,switchTrack:e==="dark"?.3:.38}}function Cl(e){return e==="dark"?Bd:[]}function Nd(e){const{palette:t={mode:"light"},opacity:r,overlays:n,...i}=e,a=Da(t);return{palette:a,opacity:{...Sl(a.mode),...r},overlays:n||Cl(a.mode),...i}}function Ld(e){var t;return!!e[0].match(/(cssVarPrefix|colorSchemeSelector|rootSelector|typography|mixins|breakpoints|direction|transitions)/)||!!e[0].match(/sxConfig$/)||e[0]==="palette"&&!!((t=e[1])!=null&&t.match(/(mode|contrastThreshold|tonalOffset)/))}const qd=e=>[...[...Array(25)].map((t,r)=>`--${e?`${e}-`:""}overlays-${r}`),`--${e?`${e}-`:""}palette-AppBar-darkBg`,`--${e?`${e}-`:""}palette-AppBar-darkColor`],Ud=e=>(t,r)=>{const n=e.rootSelector||":root",i=e.colorSchemeSelector;let a=i;if(i==="class"&&(a=".%s"),i==="data"&&(a="[data-%s]"),i!=null&&i.startsWith("data-")&&!i.includes("%s")&&(a=`[${i}="%s"]`),e.defaultColorScheme===t){if(t==="dark"){const o={};return qd(e.cssVarPrefix).forEach(s=>{o[s]=r[s],delete r[s]}),a==="media"?{[n]:r,"@media (prefers-color-scheme: dark)":{[n]:o}}:a?{[a.replace("%s",t)]:o,[`${n}, ${a.replace("%s",t)}`]:r}:{[n]:{...r,...o}}}if(a&&a!=="media")return`${n}, ${a.replace("%s",String(t))}`}else if(t){if(a==="media")return{[`@media (prefers-color-scheme: ${String(t)})`]:{[n]:r}};if(a)return a.replace("%s",String(t))}return n};function Wd(e,t){t.forEach(r=>{e[r]||(e[r]={})})}function D(e,t,r){!e[t]&&r&&(e[t]=r)}function cn(e){return typeof e!="string"||!e.startsWith("hsl")?e:xl(e)}function At(e,t){`${t}Channel`in e||(e[`${t}Channel`]=ln(cn(e[t]),`MUI: Can't create \`palette.${t}Channel\` because \`palette.${t}\` is not one of these formats: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().
74
- To suppress this warning, you need to explicitly provide the \`palette.${t}Channel\` as a string (in rgb format, for example "12 12 12") or undefined if you want to remove the channel token.`))}function Hd(e){return typeof e=="number"?`${e}px`:typeof e=="string"||typeof e=="function"||Array.isArray(e)?e:"8px"}const wt=e=>{try{return e()}catch{}},Kd=(e="mui")=>dd(e);function Ri(e,t,r,n){if(!t)return;t=t===!0?{}:t;const i=n==="dark"?"dark":"light";if(!r){e[n]=Nd({...t,palette:{mode:i,...t==null?void 0:t.palette}});return}const{palette:a,...o}=ta({...r,palette:{mode:i,...t==null?void 0:t.palette}});return e[n]={...t,palette:a,opacity:{...Sl(i),...t==null?void 0:t.opacity},overlays:(t==null?void 0:t.overlays)||Cl(i)},o}function Qd(e={},...t){const{colorSchemes:r={light:!0},defaultColorScheme:n,disableCssColorScheme:i=!1,cssVarPrefix:a="mui",shouldSkipGeneratingVar:o=Ld,colorSchemeSelector:s=r.light&&r.dark?"media":void 0,rootSelector:l=":root",...p}=e,u=Object.keys(r)[0],d=n||(r.light&&u!=="light"?"light":u),f=Kd(a),{[d]:y,light:S,dark:c,...b}=r,g={...b};let O=y;if((d==="dark"&&!("dark"in r)||d==="light"&&!("light"in r))&&(O=!0),!O)throw new Error(process.env.NODE_ENV!=="production"?`MUI: The \`colorSchemes.${d}\` option is either missing or invalid.`:er(21,d));const A=Ri(g,O,p,d);S&&!g.light&&Ri(g,S,void 0,"light"),c&&!g.dark&&Ri(g,c,void 0,"dark");let k={defaultColorScheme:d,...A,cssVarPrefix:a,colorSchemeSelector:s,rootSelector:l,getCssVar:f,colorSchemes:g,font:{...kd(A.typography),...A.font},spacing:Hd(p.spacing)};Object.keys(k.colorSchemes).forEach(W=>{const h=k.colorSchemes[W].palette,M=P=>{const q=P.split("-"),N=q[1],X=q[2];return f(P,h[N][X])};if(h.mode==="light"&&(D(h.common,"background","#fff"),D(h.common,"onBackground","#000")),h.mode==="dark"&&(D(h.common,"background","#000"),D(h.common,"onBackground","#fff")),Wd(h,["Alert","AppBar","Avatar","Button","Chip","FilledInput","LinearProgress","Skeleton","Slider","SnackbarContent","SpeedDialAction","StepConnector","StepContent","Switch","TableCell","Tooltip"]),h.mode==="light"){D(h.Alert,"errorColor",Oe(h.error.light,.6)),D(h.Alert,"infoColor",Oe(h.info.light,.6)),D(h.Alert,"successColor",Oe(h.success.light,.6)),D(h.Alert,"warningColor",Oe(h.warning.light,.6)),D(h.Alert,"errorFilledBg",M("palette-error-main")),D(h.Alert,"infoFilledBg",M("palette-info-main")),D(h.Alert,"successFilledBg",M("palette-success-main")),D(h.Alert,"warningFilledBg",M("palette-warning-main")),D(h.Alert,"errorFilledColor",wt(()=>h.getContrastText(h.error.main))),D(h.Alert,"infoFilledColor",wt(()=>h.getContrastText(h.info.main))),D(h.Alert,"successFilledColor",wt(()=>h.getContrastText(h.success.main))),D(h.Alert,"warningFilledColor",wt(()=>h.getContrastText(h.warning.main))),D(h.Alert,"errorStandardBg",je(h.error.light,.9)),D(h.Alert,"infoStandardBg",je(h.info.light,.9)),D(h.Alert,"successStandardBg",je(h.success.light,.9)),D(h.Alert,"warningStandardBg",je(h.warning.light,.9)),D(h.Alert,"errorIconColor",M("palette-error-main")),D(h.Alert,"infoIconColor",M("palette-info-main")),D(h.Alert,"successIconColor",M("palette-success-main")),D(h.Alert,"warningIconColor",M("palette-warning-main")),D(h.AppBar,"defaultBg",M("palette-grey-100")),D(h.Avatar,"defaultBg",M("palette-grey-400")),D(h.Button,"inheritContainedBg",M("palette-grey-300")),D(h.Button,"inheritContainedHoverBg",M("palette-grey-A100")),D(h.Chip,"defaultBorder",M("palette-grey-400")),D(h.Chip,"defaultAvatarColor",M("palette-grey-700")),D(h.Chip,"defaultIconColor",M("palette-grey-700")),D(h.FilledInput,"bg","rgba(0, 0, 0, 0.06)"),D(h.FilledInput,"hoverBg","rgba(0, 0, 0, 0.09)"),D(h.FilledInput,"disabledBg","rgba(0, 0, 0, 0.12)"),D(h.LinearProgress,"primaryBg",je(h.primary.main,.62)),D(h.LinearProgress,"secondaryBg",je(h.secondary.main,.62)),D(h.LinearProgress,"errorBg",je(h.error.main,.62)),D(h.LinearProgress,"infoBg",je(h.info.main,.62)),D(h.LinearProgress,"successBg",je(h.success.main,.62)),D(h.LinearProgress,"warningBg",je(h.warning.main,.62)),D(h.Skeleton,"bg",`rgba(${M("palette-text-primaryChannel")} / 0.11)`),D(h.Slider,"primaryTrack",je(h.primary.main,.62)),D(h.Slider,"secondaryTrack",je(h.secondary.main,.62)),D(h.Slider,"errorTrack",je(h.error.main,.62)),D(h.Slider,"infoTrack",je(h.info.main,.62)),D(h.Slider,"successTrack",je(h.success.main,.62)),D(h.Slider,"warningTrack",je(h.warning.main,.62));const P=Dn(h.background.default,.8);D(h.SnackbarContent,"bg",P),D(h.SnackbarContent,"color",wt(()=>h.getContrastText(P))),D(h.SpeedDialAction,"fabHoverBg",Dn(h.background.paper,.15)),D(h.StepConnector,"border",M("palette-grey-400")),D(h.StepContent,"border",M("palette-grey-400")),D(h.Switch,"defaultColor",M("palette-common-white")),D(h.Switch,"defaultDisabledColor",M("palette-grey-100")),D(h.Switch,"primaryDisabledColor",je(h.primary.main,.62)),D(h.Switch,"secondaryDisabledColor",je(h.secondary.main,.62)),D(h.Switch,"errorDisabledColor",je(h.error.main,.62)),D(h.Switch,"infoDisabledColor",je(h.info.main,.62)),D(h.Switch,"successDisabledColor",je(h.success.main,.62)),D(h.Switch,"warningDisabledColor",je(h.warning.main,.62)),D(h.TableCell,"border",je($n(h.divider,1),.88)),D(h.Tooltip,"bg",$n(h.grey[700],.92))}if(h.mode==="dark"){D(h.Alert,"errorColor",je(h.error.light,.6)),D(h.Alert,"infoColor",je(h.info.light,.6)),D(h.Alert,"successColor",je(h.success.light,.6)),D(h.Alert,"warningColor",je(h.warning.light,.6)),D(h.Alert,"errorFilledBg",M("palette-error-dark")),D(h.Alert,"infoFilledBg",M("palette-info-dark")),D(h.Alert,"successFilledBg",M("palette-success-dark")),D(h.Alert,"warningFilledBg",M("palette-warning-dark")),D(h.Alert,"errorFilledColor",wt(()=>h.getContrastText(h.error.dark))),D(h.Alert,"infoFilledColor",wt(()=>h.getContrastText(h.info.dark))),D(h.Alert,"successFilledColor",wt(()=>h.getContrastText(h.success.dark))),D(h.Alert,"warningFilledColor",wt(()=>h.getContrastText(h.warning.dark))),D(h.Alert,"errorStandardBg",Oe(h.error.light,.9)),D(h.Alert,"infoStandardBg",Oe(h.info.light,.9)),D(h.Alert,"successStandardBg",Oe(h.success.light,.9)),D(h.Alert,"warningStandardBg",Oe(h.warning.light,.9)),D(h.Alert,"errorIconColor",M("palette-error-main")),D(h.Alert,"infoIconColor",M("palette-info-main")),D(h.Alert,"successIconColor",M("palette-success-main")),D(h.Alert,"warningIconColor",M("palette-warning-main")),D(h.AppBar,"defaultBg",M("palette-grey-900")),D(h.AppBar,"darkBg",M("palette-background-paper")),D(h.AppBar,"darkColor",M("palette-text-primary")),D(h.Avatar,"defaultBg",M("palette-grey-600")),D(h.Button,"inheritContainedBg",M("palette-grey-800")),D(h.Button,"inheritContainedHoverBg",M("palette-grey-700")),D(h.Chip,"defaultBorder",M("palette-grey-700")),D(h.Chip,"defaultAvatarColor",M("palette-grey-300")),D(h.Chip,"defaultIconColor",M("palette-grey-300")),D(h.FilledInput,"bg","rgba(255, 255, 255, 0.09)"),D(h.FilledInput,"hoverBg","rgba(255, 255, 255, 0.13)"),D(h.FilledInput,"disabledBg","rgba(255, 255, 255, 0.12)"),D(h.LinearProgress,"primaryBg",Oe(h.primary.main,.5)),D(h.LinearProgress,"secondaryBg",Oe(h.secondary.main,.5)),D(h.LinearProgress,"errorBg",Oe(h.error.main,.5)),D(h.LinearProgress,"infoBg",Oe(h.info.main,.5)),D(h.LinearProgress,"successBg",Oe(h.success.main,.5)),D(h.LinearProgress,"warningBg",Oe(h.warning.main,.5)),D(h.Skeleton,"bg",`rgba(${M("palette-text-primaryChannel")} / 0.13)`),D(h.Slider,"primaryTrack",Oe(h.primary.main,.5)),D(h.Slider,"secondaryTrack",Oe(h.secondary.main,.5)),D(h.Slider,"errorTrack",Oe(h.error.main,.5)),D(h.Slider,"infoTrack",Oe(h.info.main,.5)),D(h.Slider,"successTrack",Oe(h.success.main,.5)),D(h.Slider,"warningTrack",Oe(h.warning.main,.5));const P=Dn(h.background.default,.98);D(h.SnackbarContent,"bg",P),D(h.SnackbarContent,"color",wt(()=>h.getContrastText(P))),D(h.SpeedDialAction,"fabHoverBg",Dn(h.background.paper,.15)),D(h.StepConnector,"border",M("palette-grey-600")),D(h.StepContent,"border",M("palette-grey-600")),D(h.Switch,"defaultColor",M("palette-grey-300")),D(h.Switch,"defaultDisabledColor",M("palette-grey-600")),D(h.Switch,"primaryDisabledColor",Oe(h.primary.main,.55)),D(h.Switch,"secondaryDisabledColor",Oe(h.secondary.main,.55)),D(h.Switch,"errorDisabledColor",Oe(h.error.main,.55)),D(h.Switch,"infoDisabledColor",Oe(h.info.main,.55)),D(h.Switch,"successDisabledColor",Oe(h.success.main,.55)),D(h.Switch,"warningDisabledColor",Oe(h.warning.main,.55)),D(h.TableCell,"border",Oe($n(h.divider,1),.68)),D(h.Tooltip,"bg",$n(h.grey[700],.92))}At(h.background,"default"),At(h.background,"paper"),At(h.common,"background"),At(h.common,"onBackground"),At(h,"divider"),Object.keys(h).forEach(P=>{const q=h[P];P!=="tonalOffset"&&q&&typeof q=="object"&&(q.main&&D(h[P],"mainChannel",ln(cn(q.main))),q.light&&D(h[P],"lightChannel",ln(cn(q.light))),q.dark&&D(h[P],"darkChannel",ln(cn(q.dark))),q.contrastText&&D(h[P],"contrastTextChannel",ln(cn(q.contrastText))),P==="text"&&(At(h[P],"primary"),At(h[P],"secondary")),P==="action"&&(q.active&&At(h[P],"active"),q.selected&&At(h[P],"selected")))})}),k=t.reduce((W,h)=>it(W,h),k);const x={prefix:a,disableCssColorScheme:i,shouldSkipGeneratingVar:o,getSelector:Ud(k)},{vars:B,generateThemeVars:_,generateStyleSheets:K}=md(k,x);return k.vars=B,Object.entries(k.colorSchemes[k.defaultColorScheme]).forEach(([W,h])=>{k[W]=h}),k.generateThemeVars=_,k.generateStyleSheets=K,k.generateSpacing=function(){return dl(p.spacing,Fa(this))},k.getColorSchemeSelector=gd(s),k.spacing=k.generateSpacing(),k.shouldSkipGeneratingVar=o,k.unstable_sxConfig={...Tn,...p==null?void 0:p.unstable_sxConfig},k.unstable_sx=function(h){return Gr({sx:h,theme:this})},k.toRuntimeSource=wl,k}function Ho(e,t,r){e.colorSchemes&&r&&(e.colorSchemes[t]={...r!==!0&&r,palette:Da({...r===!0?{}:r.palette,mode:t})})}function Yd(e={},...t){const{palette:r,cssVariables:n=!1,colorSchemes:i=r?void 0:{light:!0},defaultColorScheme:a=r==null?void 0:r.mode,...o}=e,s=a||"light",l=i==null?void 0:i[s],p={...i,...r?{[s]:{...typeof l!="boolean"&&l,palette:r}}:void 0};if(n===!1){if(!("colorSchemes"in e))return ta(e,...t);let u=r;"palette"in e||p[s]&&(p[s]!==!0?u=p[s].palette:s==="dark"&&(u={mode:"dark"}));const d=ta({...e,palette:u},...t);return d.defaultColorScheme=s,d.colorSchemes=p,d.palette.mode==="light"&&(d.colorSchemes.light={...p.light!==!0&&p.light,palette:d.palette},Ho(d,"dark",p.dark)),d.palette.mode==="dark"&&(d.colorSchemes.dark={...p.dark!==!0&&p.dark,palette:d.palette},Ho(d,"light",p.light)),d}return!r&&!("light"in p)&&s==="light"&&(p.light=!0),Qd({...o,colorSchemes:p,defaultColorScheme:s,...typeof n!="boolean"&&n},...t)}const Gd=Yd(),Zd="$$material";function Xd(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const Jd=e=>Xd(e)&&e!=="classes",ot=Xp({themeId:Zd,defaultTheme:Gd,rootShouldForwardProp:Jd});function ef(){return Ap}const wr=pd;process.env.NODE_ENV!=="production"&&(w.node,w.object.isRequired);function Er(e){return ud(e)}function tf(e){return typeof e.main=="string"}function rf(e,t=[]){if(!tf(e))return!1;for(const r of t)if(!e.hasOwnProperty(r)||typeof e[r]!="string")return!1;return!0}function ei(e=[]){return([,t])=>t&&rf(t,e)}function nf(e){return nr("MuiTypography",e)}Cr("MuiTypography",["root","h1","h2","h3","h4","h5","h6","subtitle1","subtitle2","body1","body2","inherit","button","caption","overline","alignLeft","alignRight","alignCenter","alignJustify","noWrap","gutterBottom","paragraph"]);const af={primary:!0,secondary:!0,error:!0,info:!0,success:!0,warning:!0,textPrimary:!0,textSecondary:!0,textDisabled:!0},of=ef(),sf=e=>{const{align:t,gutterBottom:r,noWrap:n,paragraph:i,variant:a,classes:o}=e,s={root:["root",a,e.align!=="inherit"&&`align${Re(t)}`,r&&"gutterBottom",n&&"noWrap",i&&"paragraph"]};return Xr(s,nf,o)},lf=ot("span",{name:"MuiTypography",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,r.variant&&t[r.variant],r.align!=="inherit"&&t[`align${Re(r.align)}`],r.noWrap&&t.noWrap,r.gutterBottom&&t.gutterBottom,r.paragraph&&t.paragraph]}})(wr(({theme:e})=>{var t;return{margin:0,variants:[{props:{variant:"inherit"},style:{font:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}},...Object.entries(e.typography).filter(([r,n])=>r!=="inherit"&&n&&typeof n=="object").map(([r,n])=>({props:{variant:r},style:n})),...Object.entries(e.palette).filter(ei()).map(([r])=>({props:{color:r},style:{color:(e.vars||e).palette[r].main}})),...Object.entries(((t=e.palette)==null?void 0:t.text)||{}).filter(([,r])=>typeof r=="string").map(([r])=>({props:{color:`text${Re(r)}`},style:{color:(e.vars||e).palette.text[r]}})),{props:({ownerState:r})=>r.align!=="inherit",style:{textAlign:"var(--Typography-textAlign)"}},{props:({ownerState:r})=>r.noWrap,style:{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"}},{props:({ownerState:r})=>r.gutterBottom,style:{marginBottom:"0.35em"}},{props:({ownerState:r})=>r.paragraph,style:{marginBottom:16}}]}})),Ko={h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",subtitle1:"h6",subtitle2:"h6",body1:"p",body2:"p",inherit:"p"},El=ne.forwardRef(function(t,r){const{color:n,...i}=Er({props:t,name:"MuiTypography"}),a=!af[n],o=of({...i,...a&&{color:n}}),{align:s="inherit",className:l,component:p,gutterBottom:u=!1,noWrap:d=!1,paragraph:f=!1,variant:y="body1",variantMapping:S=Ko,...c}=o,b={...o,align:s,color:n,className:l,component:p,gutterBottom:u,noWrap:d,paragraph:f,variant:y,variantMapping:S},g=p||(f?"p":S[y]||Ko[y])||"span",O=sf(b);return m.jsx(lf,{as:g,ref:r,className:Ke(O.root,l),...c,ownerState:b,style:{...s!=="inherit"&&{"--Typography-textAlign":s},...c.style}})});process.env.NODE_ENV!=="production"&&(El.propTypes={align:w.oneOf(["center","inherit","justify","left","right"]),children:w.node,classes:w.object,className:w.string,color:w.oneOfType([w.oneOf(["primary","secondary","success","error","info","warning","textPrimary","textSecondary","textDisabled"]),w.string]),component:w.elementType,gutterBottom:w.bool,noWrap:w.bool,paragraph:w.bool,style:w.object,sx:w.oneOfType([w.arrayOf(w.oneOfType([w.func,w.object,w.bool])),w.func,w.object]),variant:w.oneOfType([w.oneOf(["body1","body2","button","caption","h1","h2","h3","h4","h5","h6","inherit","overline","subtitle1","subtitle2"]),w.string]),variantMapping:w.object});const Pa=ne.createContext(void 0);process.env.NODE_ENV!=="production"&&(Pa.displayName="FormControlContext");function cf(){return ne.useContext(Pa)}function uf(e){return nr("MuiInputAdornment",e)}const Qo=Cr("MuiInputAdornment",["root","filled","standard","outlined","positionStart","positionEnd","disablePointerEvents","hiddenLabel","sizeSmall"]);var Yo;const pf=(e,t)=>{const{ownerState:r}=e;return[t.root,t[`position${Re(r.position)}`],r.disablePointerEvents===!0&&t.disablePointerEvents,t[r.variant]]},df=e=>{const{classes:t,disablePointerEvents:r,hiddenLabel:n,position:i,size:a,variant:o}=e,s={root:["root",r&&"disablePointerEvents",i&&`position${Re(i)}`,o,n&&"hiddenLabel",a&&`size${Re(a)}`]};return Xr(s,uf,t)},ff=ot("div",{name:"MuiInputAdornment",slot:"Root",overridesResolver:pf})(wr(({theme:e})=>({display:"flex",maxHeight:"2em",alignItems:"center",whiteSpace:"nowrap",color:(e.vars||e).palette.action.active,variants:[{props:{variant:"filled"},style:{[`&.${Qo.positionStart}&:not(.${Qo.hiddenLabel})`]:{marginTop:16}}},{props:{position:"start"},style:{marginRight:8}},{props:{position:"end"},style:{marginLeft:8}},{props:{disablePointerEvents:!0},style:{pointerEvents:"none"}}]}))),kl=ne.forwardRef(function(t,r){const n=Er({props:t,name:"MuiInputAdornment"}),{children:i,className:a,component:o="div",disablePointerEvents:s=!1,disableTypography:l=!1,position:p,variant:u,...d}=n,f=cf()||{};let y=u;u&&f.variant&&process.env.NODE_ENV!=="production"&&u===f.variant&&console.error("MUI: The `InputAdornment` variant infers the variant prop you do not have to provide one."),f&&!y&&(y=f.variant);const S={...n,hiddenLabel:f.hiddenLabel,size:f.size,disablePointerEvents:s,position:p,variant:y},c=df(S);return m.jsx(Pa.Provider,{value:null,children:m.jsx(ff,{as:o,ownerState:S,className:Ke(c.root,a),ref:r,...d,children:typeof i=="string"&&!l?m.jsx(El,{color:"textSecondary",children:i}):m.jsxs(ne.Fragment,{children:[p==="start"?Yo||(Yo=m.jsx("span",{className:"notranslate","aria-hidden":!0,children:"​"})):null,i]})})})});process.env.NODE_ENV!=="production"&&(kl.propTypes={children:w.node,classes:w.object,className:w.string,component:w.elementType,disablePointerEvents:w.bool,disableTypography:w.bool,position:w.oneOf(["end","start"]).isRequired,sx:w.oneOfType([w.arrayOf(w.oneOfType([w.func,w.object,w.bool])),w.func,w.object]),variant:w.oneOf(["filled","outlined","standard"])});function Ia(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...n){return e(...n)||t(...n)}}function hf(e){return nr("MuiSvgIcon",e)}Cr("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const mf=e=>{const{color:t,fontSize:r,classes:n}=e,i={root:["root",t!=="inherit"&&`color${Re(t)}`,`fontSize${Re(r)}`]};return Xr(i,hf,n)},gf=ot("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,r.color!=="inherit"&&t[`color${Re(r.color)}`],t[`fontSize${Re(r.fontSize)}`]]}})(wr(({theme:e})=>{var t,r,n,i,a,o,s,l,p,u,d,f,y,S;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",flexShrink:0,transition:(i=(t=e.transitions)==null?void 0:t.create)==null?void 0:i.call(t,"fill",{duration:(n=(r=(e.vars??e).transitions)==null?void 0:r.duration)==null?void 0:n.shorter}),variants:[{props:c=>!c.hasSvgAsChild,style:{fill:"currentColor"}},{props:{fontSize:"inherit"},style:{fontSize:"inherit"}},{props:{fontSize:"small"},style:{fontSize:((o=(a=e.typography)==null?void 0:a.pxToRem)==null?void 0:o.call(a,20))||"1.25rem"}},{props:{fontSize:"medium"},style:{fontSize:((l=(s=e.typography)==null?void 0:s.pxToRem)==null?void 0:l.call(s,24))||"1.5rem"}},{props:{fontSize:"large"},style:{fontSize:((u=(p=e.typography)==null?void 0:p.pxToRem)==null?void 0:u.call(p,35))||"2.1875rem"}},...Object.entries((e.vars??e).palette).filter(([,c])=>c&&c.main).map(([c])=>{var b,g;return{props:{color:c},style:{color:(g=(b=(e.vars??e).palette)==null?void 0:b[c])==null?void 0:g.main}}}),{props:{color:"action"},style:{color:(f=(d=(e.vars??e).palette)==null?void 0:d.action)==null?void 0:f.active}},{props:{color:"disabled"},style:{color:(S=(y=(e.vars??e).palette)==null?void 0:y.action)==null?void 0:S.disabled}},{props:{color:"inherit"},style:{color:void 0}}]}})),ti=ne.forwardRef(function(t,r){const n=Er({props:t,name:"MuiSvgIcon"}),{children:i,className:a,color:o="inherit",component:s="svg",fontSize:l="medium",htmlColor:p,inheritViewBox:u=!1,titleAccess:d,viewBox:f="0 0 24 24",...y}=n,S=ne.isValidElement(i)&&i.type==="svg",c={...n,color:o,component:s,fontSize:l,instanceFontSize:t.fontSize,inheritViewBox:u,viewBox:f,hasSvgAsChild:S},b={};u||(b.viewBox=f);const g=mf(c);return m.jsxs(gf,{as:s,className:Ke(g.root,a),focusable:"false",color:p,"aria-hidden":d?void 0:!0,role:d?"img":void 0,ref:r,...b,...y,...S&&i.props,ownerState:c,children:[S?i.props.children:i,d?m.jsx("title",{children:d}):null]})});process.env.NODE_ENV!=="production"&&(ti.propTypes={children:w.node,classes:w.object,className:w.string,color:w.oneOfType([w.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),w.string]),component:w.elementType,fontSize:w.oneOfType([w.oneOf(["inherit","large","medium","small"]),w.string]),htmlColor:w.string,inheritViewBox:w.bool,shapeRendering:w.string,sx:w.oneOfType([w.arrayOf(w.oneOfType([w.func,w.object,w.bool])),w.func,w.object]),titleAccess:w.string,viewBox:w.string});ti.muiName="SvgIcon";function vt(e,t){function r(n,i){return m.jsx(ti,{"data-testid":process.env.NODE_ENV!=="production"?`${t}Icon`:void 0,ref:i,...n,children:e})}return process.env.NODE_ENV!=="production"&&(r.displayName=`${t}Icon`),r.muiName=ti.muiName,ne.memo(ne.forwardRef(r))}let Go=0;function yf(e){const[t,r]=ne.useState(e),n=e||t;return ne.useEffect(()=>{t==null&&(Go+=1,r(`mui-${Go}`))},[t]),n}const xf={...ne},Zo=xf.useId;function vf(e){if(Zo!==void 0){const t=Zo();return e??t}return yf(e)}function Nn(e){const t=ne.useRef(e);return nd(()=>{t.current=e}),ne.useRef((...r)=>(0,t.current)(...r)).current}function Xo(...e){const t=ne.useRef(void 0),r=ne.useCallback(n=>{const i=e.map(a=>{if(a==null)return null;if(typeof a=="function"){const o=a,s=o(n);return typeof s=="function"?s:()=>{o(null)}}return a.current=n,()=>{a.current=null}});return()=>{i.forEach(a=>a==null?void 0:a())}},e);return ne.useMemo(()=>e.every(n=>n==null)?null:n=>{t.current&&(t.current(),t.current=void 0),n!=null&&(t.current=r(n))},e)}const bf=w.oneOfType([w.func,w.object]);function wf(e){const{prototype:t={}}=e;return!!t.isReactComponent}function Sf(e,t,r,n,i){const a=e[t],o=i||t;if(a==null||typeof window>"u")return null;let s;return typeof a=="function"&&!wf(a)&&(s="Did you accidentally provide a plain function component instead?"),s!==void 0?new Error(`Invalid ${n} \`${o}\` supplied to \`${r}\`. Expected an element type that can hold a ref. ${s} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const Cf=Ia(w.elementType,Sf);function Jo(e){try{return e.matches(":focus-visible")}catch{process.env.NODE_ENV!=="production"&&!/jsdom/.test(window.navigator.userAgent)&&console.warn(["MUI: The `:focus-visible` pseudo class is not supported in this browser.","Some components rely on this feature to work properly."].join(`
75
- `))}return!1}const es={};function Tl(e,t){const r=ne.useRef(es);return r.current===es&&(r.current=e(t)),r}class ri{constructor(){rn(this,"mountEffect",()=>{this.shouldMount&&!this.didMount&&this.ref.current!==null&&(this.didMount=!0,this.mounted.resolve())});this.ref={current:null},this.mounted=null,this.didMount=!1,this.shouldMount=!1,this.setShouldMount=null}static create(){return new ri}static use(){const t=Tl(ri.create).current,[r,n]=ne.useState(!1);return t.shouldMount=r,t.setShouldMount=n,ne.useEffect(t.mountEffect,[r]),t}mount(){return this.mounted||(this.mounted=kf(),this.shouldMount=!0,this.setShouldMount(this.shouldMount)),this.mounted}start(...t){this.mount().then(()=>{var r;return(r=this.ref.current)==null?void 0:r.start(...t)})}stop(...t){this.mount().then(()=>{var r;return(r=this.ref.current)==null?void 0:r.stop(...t)})}pulsate(...t){this.mount().then(()=>{var r;return(r=this.ref.current)==null?void 0:r.pulsate(...t)})}}function Ef(){return ri.use()}function kf(){let e,t;const r=new Promise((n,i)=>{e=n,t=i});return r.resolve=e,r.reject=t,r}function ra(){return ra=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},ra.apply(null,arguments)}function Tf(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}function na(e,t){return na=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,n){return r.__proto__=n,r},na(e,t)}function Of(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,na(e,t)}const ts=$.createContext(null);function jf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Ma(e,t){var r=function(a){return t&&$.isValidElement(a)?t(a):a},n=Object.create(null);return e&&$.Children.map(e,function(i){return i}).forEach(function(i){n[i.key]=r(i)}),n}function Ff(e,t){e=e||{},t=t||{};function r(u){return u in t?t[u]:e[u]}var n=Object.create(null),i=[];for(var a in e)a in t?i.length&&(n[a]=i,i=[]):i.push(a);var o,s={};for(var l in t){if(n[l])for(o=0;o<n[l].length;o++){var p=n[l][o];s[n[l][o]]=r(p)}s[l]=r(l)}for(o=0;o<i.length;o++)s[i[o]]=r(i[o]);return s}function cr(e,t,r){return r[t]!=null?r[t]:e.props[t]}function _f(e,t){return Ma(e.children,function(r){return $.cloneElement(r,{onExited:t.bind(null,r),in:!0,appear:cr(r,"appear",e),enter:cr(r,"enter",e),exit:cr(r,"exit",e)})})}function Af(e,t,r){var n=Ma(e.children),i=Ff(t,n);return Object.keys(i).forEach(function(a){var o=i[a];if($.isValidElement(o)){var s=a in t,l=a in n,p=t[a],u=$.isValidElement(p)&&!p.props.in;l&&(!s||u)?i[a]=$.cloneElement(o,{onExited:r.bind(null,o),in:!0,exit:cr(o,"exit",e),enter:cr(o,"enter",e)}):!l&&s&&!u?i[a]=$.cloneElement(o,{in:!1}):l&&s&&$.isValidElement(p)&&(i[a]=$.cloneElement(o,{onExited:r.bind(null,o),in:p.props.in,exit:cr(o,"exit",e),enter:cr(o,"enter",e)}))}}),i}var Rf=Object.values||function(e){return Object.keys(e).map(function(t){return e[t]})},$f={component:"div",childFactory:function(t){return t}},za=function(e){Of(t,e);function t(n,i){var a;a=e.call(this,n,i)||this;var o=a.handleExited.bind(jf(a));return a.state={contextValue:{isMounting:!0},handleExited:o,firstRender:!0},a}var r=t.prototype;return r.componentDidMount=function(){this.mounted=!0,this.setState({contextValue:{isMounting:!1}})},r.componentWillUnmount=function(){this.mounted=!1},t.getDerivedStateFromProps=function(i,a){var o=a.children,s=a.handleExited,l=a.firstRender;return{children:l?_f(i,s):Af(i,o,s),firstRender:!1}},r.handleExited=function(i,a){var o=Ma(this.props.children);i.key in o||(i.props.onExited&&i.props.onExited(a),this.mounted&&this.setState(function(s){var l=ra({},s.children);return delete l[i.key],{children:l}}))},r.render=function(){var i=this.props,a=i.component,o=i.childFactory,s=Tf(i,["component","childFactory"]),l=this.state.contextValue,p=Rf(this.state.children).map(o);return delete s.appear,delete s.enter,delete s.exit,a===null?$.createElement(ts.Provider,{value:l},p):$.createElement(ts.Provider,{value:l},$.createElement(a,s,p))},t}($.Component);za.propTypes=process.env.NODE_ENV!=="production"?{component:w.any,children:w.node,appear:w.bool,enter:w.bool,exit:w.bool,childFactory:w.func}:{};za.defaultProps=$f;const Df=[];function Pf(e){ne.useEffect(e,Df)}class Va{constructor(){rn(this,"currentId",null);rn(this,"clear",()=>{this.currentId!==null&&(clearTimeout(this.currentId),this.currentId=null)});rn(this,"disposeEffect",()=>this.clear)}static create(){return new Va}start(t,r){this.clear(),this.currentId=setTimeout(()=>{this.currentId=null,r()},t)}}function If(){const e=Tl(Va.create).current;return Pf(e.disposeEffect),e}function Ol(e){const{className:t,classes:r,pulsate:n=!1,rippleX:i,rippleY:a,rippleSize:o,in:s,onExited:l,timeout:p}=e,[u,d]=ne.useState(!1),f=Ke(t,r.ripple,r.rippleVisible,n&&r.ripplePulsate),y={width:o,height:o,top:-(o/2)+a,left:-(o/2)+i},S=Ke(r.child,u&&r.childLeaving,n&&r.childPulsate);return!s&&!u&&d(!0),ne.useEffect(()=>{if(!s&&l!=null){const c=setTimeout(l,p);return()=>{clearTimeout(c)}}},[l,s,p]),m.jsx("span",{className:f,style:y,children:m.jsx("span",{className:S})})}process.env.NODE_ENV!=="production"&&(Ol.propTypes={classes:w.object.isRequired,className:w.string,in:w.bool,onExited:w.func,pulsate:w.bool,rippleSize:w.number,rippleX:w.number,rippleY:w.number,timeout:w.number.isRequired});const ut=Cr("MuiTouchRipple",["root","ripple","rippleVisible","ripplePulsate","child","childLeaving","childPulsate"]),ia=550,Mf=80,zf=Sr.keyframes`
72
+ export default theme;`}function ta(e={},...t){const{breakpoints:r,mixins:n={},spacing:i,palette:a={},transitions:o={},typography:s={},shape:l,...p}=e;if(e.vars&&e.generateThemeVars===void 0)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name or follow the [docs](https://mui.com/material-ui/customization/css-theme-variables/usage/) to enable the feature.":er(20));const u=Ma(a),d=yl(e);let f=it(d,{mixins:Td(d.breakpoints,n),palette:u,shadows:Rd.slice(),typography:jd(u,s),transitions:Id(o),zIndex:{...Md}});if(f=it(f,p),f=t.reduce((g,S)=>it(g,S),f),process.env.NODE_ENV!=="production"){const g=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],S=(c,b)=>{let y;for(y in c){const j=c[y];if(g.includes(y)&&Object.keys(j).length>0){if(process.env.NODE_ENV!=="production"){const R=nr("",y);console.error([`MUI: The \`${b}\` component increases the CSS specificity of the \`${y}\` internal state.`,"You can not override it like this: ",JSON.stringify(c,null,2),"",`Instead, you need to use the '&.${R}' syntax:`,JSON.stringify({root:{[`&.${R}`]:j}},null,2),"","https://mui.com/r/state-classes-guide"].join(`
73
+ `))}c[y]={}}}};Object.keys(f.components).forEach(c=>{const b=f.components[c].styleOverrides;b&&c.startsWith("Mui")&&S(b,c)})}return f.unstable_sxConfig={...Tn,...p==null?void 0:p.unstable_sxConfig},f.unstable_sx=function(S){return Gr({sx:S,theme:this})},f.toRuntimeSource=El,f}function Vd(e){let t;return e<1?t=5.11916*e**2:t=4.5*Math.log(e+1)+2,Math.round(t*10)/1e3}const Bd=[...Array(25)].map((e,t)=>{if(t===0)return"none";const r=Vd(t);return`linear-gradient(rgba(255 255 255 / ${r}), rgba(255 255 255 / ${r}))`});function kl(e){return{inputPlaceholder:e==="dark"?.5:.42,inputUnderline:e==="dark"?.7:.42,switchTrackDisabled:e==="dark"?.2:.12,switchTrack:e==="dark"?.3:.38}}function Tl(e){return e==="dark"?Bd:[]}function Nd(e){const{palette:t={mode:"light"},opacity:r,overlays:n,...i}=e,a=Ma(t);return{palette:a,opacity:{...kl(a.mode),...r},overlays:n||Tl(a.mode),...i}}function Ld(e){var t;return!!e[0].match(/(cssVarPrefix|colorSchemeSelector|rootSelector|typography|mixins|breakpoints|direction|transitions)/)||!!e[0].match(/sxConfig$/)||e[0]==="palette"&&!!((t=e[1])!=null&&t.match(/(mode|contrastThreshold|tonalOffset)/))}const qd=e=>[...[...Array(25)].map((t,r)=>`--${e?`${e}-`:""}overlays-${r}`),`--${e?`${e}-`:""}palette-AppBar-darkBg`,`--${e?`${e}-`:""}palette-AppBar-darkColor`],Ud=e=>(t,r)=>{const n=e.rootSelector||":root",i=e.colorSchemeSelector;let a=i;if(i==="class"&&(a=".%s"),i==="data"&&(a="[data-%s]"),i!=null&&i.startsWith("data-")&&!i.includes("%s")&&(a=`[${i}="%s"]`),e.defaultColorScheme===t){if(t==="dark"){const o={};return qd(e.cssVarPrefix).forEach(s=>{o[s]=r[s],delete r[s]}),a==="media"?{[n]:r,"@media (prefers-color-scheme: dark)":{[n]:o}}:a?{[a.replace("%s",t)]:o,[`${n}, ${a.replace("%s",t)}`]:r}:{[n]:{...r,...o}}}if(a&&a!=="media")return`${n}, ${a.replace("%s",String(t))}`}else if(t){if(a==="media")return{[`@media (prefers-color-scheme: ${String(t)})`]:{[n]:r}};if(a)return a.replace("%s",String(t))}return n};function Wd(e,t){t.forEach(r=>{e[r]||(e[r]={})})}function I(e,t,r){!e[t]&&r&&(e[t]=r)}function cn(e){return typeof e!="string"||!e.startsWith("hsl")?e:wl(e)}function _t(e,t){`${t}Channel`in e||(e[`${t}Channel`]=ln(cn(e[t]),`MUI: Can't create \`palette.${t}Channel\` because \`palette.${t}\` is not one of these formats: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().
74
+ To suppress this warning, you need to explicitly provide the \`palette.${t}Channel\` as a string (in rgb format, for example "12 12 12") or undefined if you want to remove the channel token.`))}function Hd(e){return typeof e=="number"?`${e}px`:typeof e=="string"||typeof e=="function"||Array.isArray(e)?e:"8px"}const wt=e=>{try{return e()}catch{}},Kd=(e="mui")=>dd(e);function Ri(e,t,r,n){if(!t)return;t=t===!0?{}:t;const i=n==="dark"?"dark":"light";if(!r){e[n]=Nd({...t,palette:{mode:i,...t==null?void 0:t.palette}});return}const{palette:a,...o}=ta({...r,palette:{mode:i,...t==null?void 0:t.palette}});return e[n]={...t,palette:a,opacity:{...kl(i),...t==null?void 0:t.opacity},overlays:(t==null?void 0:t.overlays)||Tl(i)},o}function Qd(e={},...t){const{colorSchemes:r={light:!0},defaultColorScheme:n,disableCssColorScheme:i=!1,cssVarPrefix:a="mui",shouldSkipGeneratingVar:o=Ld,colorSchemeSelector:s=r.light&&r.dark?"media":void 0,rootSelector:l=":root",...p}=e,u=Object.keys(r)[0],d=n||(r.light&&u!=="light"?"light":u),f=Kd(a),{[d]:g,light:S,dark:c,...b}=r,y={...b};let j=g;if((d==="dark"&&!("dark"in r)||d==="light"&&!("light"in r))&&(j=!0),!j)throw new Error(process.env.NODE_ENV!=="production"?`MUI: The \`colorSchemes.${d}\` option is either missing or invalid.`:er(21,d));const R=Ri(y,j,p,d);S&&!y.light&&Ri(y,S,void 0,"light"),c&&!y.dark&&Ri(y,c,void 0,"dark");let k={defaultColorScheme:d,...R,cssVarPrefix:a,colorSchemeSelector:s,rootSelector:l,getCssVar:f,colorSchemes:y,font:{...kd(R.typography),...R.font},spacing:Hd(p.spacing)};Object.keys(k.colorSchemes).forEach(U=>{const h=k.colorSchemes[U].palette,z=M=>{const q=M.split("-"),N=q[1],J=q[2];return f(M,h[N][J])};if(h.mode==="light"&&(I(h.common,"background","#fff"),I(h.common,"onBackground","#000")),h.mode==="dark"&&(I(h.common,"background","#000"),I(h.common,"onBackground","#fff")),Wd(h,["Alert","AppBar","Avatar","Button","Chip","FilledInput","LinearProgress","Skeleton","Slider","SnackbarContent","SpeedDialAction","StepConnector","StepContent","Switch","TableCell","Tooltip"]),h.mode==="light"){I(h.Alert,"errorColor",je(h.error.light,.6)),I(h.Alert,"infoColor",je(h.info.light,.6)),I(h.Alert,"successColor",je(h.success.light,.6)),I(h.Alert,"warningColor",je(h.warning.light,.6)),I(h.Alert,"errorFilledBg",z("palette-error-main")),I(h.Alert,"infoFilledBg",z("palette-info-main")),I(h.Alert,"successFilledBg",z("palette-success-main")),I(h.Alert,"warningFilledBg",z("palette-warning-main")),I(h.Alert,"errorFilledColor",wt(()=>h.getContrastText(h.error.main))),I(h.Alert,"infoFilledColor",wt(()=>h.getContrastText(h.info.main))),I(h.Alert,"successFilledColor",wt(()=>h.getContrastText(h.success.main))),I(h.Alert,"warningFilledColor",wt(()=>h.getContrastText(h.warning.main))),I(h.Alert,"errorStandardBg",Fe(h.error.light,.9)),I(h.Alert,"infoStandardBg",Fe(h.info.light,.9)),I(h.Alert,"successStandardBg",Fe(h.success.light,.9)),I(h.Alert,"warningStandardBg",Fe(h.warning.light,.9)),I(h.Alert,"errorIconColor",z("palette-error-main")),I(h.Alert,"infoIconColor",z("palette-info-main")),I(h.Alert,"successIconColor",z("palette-success-main")),I(h.Alert,"warningIconColor",z("palette-warning-main")),I(h.AppBar,"defaultBg",z("palette-grey-100")),I(h.Avatar,"defaultBg",z("palette-grey-400")),I(h.Button,"inheritContainedBg",z("palette-grey-300")),I(h.Button,"inheritContainedHoverBg",z("palette-grey-A100")),I(h.Chip,"defaultBorder",z("palette-grey-400")),I(h.Chip,"defaultAvatarColor",z("palette-grey-700")),I(h.Chip,"defaultIconColor",z("palette-grey-700")),I(h.FilledInput,"bg","rgba(0, 0, 0, 0.06)"),I(h.FilledInput,"hoverBg","rgba(0, 0, 0, 0.09)"),I(h.FilledInput,"disabledBg","rgba(0, 0, 0, 0.12)"),I(h.LinearProgress,"primaryBg",Fe(h.primary.main,.62)),I(h.LinearProgress,"secondaryBg",Fe(h.secondary.main,.62)),I(h.LinearProgress,"errorBg",Fe(h.error.main,.62)),I(h.LinearProgress,"infoBg",Fe(h.info.main,.62)),I(h.LinearProgress,"successBg",Fe(h.success.main,.62)),I(h.LinearProgress,"warningBg",Fe(h.warning.main,.62)),I(h.Skeleton,"bg",`rgba(${z("palette-text-primaryChannel")} / 0.11)`),I(h.Slider,"primaryTrack",Fe(h.primary.main,.62)),I(h.Slider,"secondaryTrack",Fe(h.secondary.main,.62)),I(h.Slider,"errorTrack",Fe(h.error.main,.62)),I(h.Slider,"infoTrack",Fe(h.info.main,.62)),I(h.Slider,"successTrack",Fe(h.success.main,.62)),I(h.Slider,"warningTrack",Fe(h.warning.main,.62));const M=Dn(h.background.default,.8);I(h.SnackbarContent,"bg",M),I(h.SnackbarContent,"color",wt(()=>h.getContrastText(M))),I(h.SpeedDialAction,"fabHoverBg",Dn(h.background.paper,.15)),I(h.StepConnector,"border",z("palette-grey-400")),I(h.StepContent,"border",z("palette-grey-400")),I(h.Switch,"defaultColor",z("palette-common-white")),I(h.Switch,"defaultDisabledColor",z("palette-grey-100")),I(h.Switch,"primaryDisabledColor",Fe(h.primary.main,.62)),I(h.Switch,"secondaryDisabledColor",Fe(h.secondary.main,.62)),I(h.Switch,"errorDisabledColor",Fe(h.error.main,.62)),I(h.Switch,"infoDisabledColor",Fe(h.info.main,.62)),I(h.Switch,"successDisabledColor",Fe(h.success.main,.62)),I(h.Switch,"warningDisabledColor",Fe(h.warning.main,.62)),I(h.TableCell,"border",Fe($n(h.divider,1),.88)),I(h.Tooltip,"bg",$n(h.grey[700],.92))}if(h.mode==="dark"){I(h.Alert,"errorColor",Fe(h.error.light,.6)),I(h.Alert,"infoColor",Fe(h.info.light,.6)),I(h.Alert,"successColor",Fe(h.success.light,.6)),I(h.Alert,"warningColor",Fe(h.warning.light,.6)),I(h.Alert,"errorFilledBg",z("palette-error-dark")),I(h.Alert,"infoFilledBg",z("palette-info-dark")),I(h.Alert,"successFilledBg",z("palette-success-dark")),I(h.Alert,"warningFilledBg",z("palette-warning-dark")),I(h.Alert,"errorFilledColor",wt(()=>h.getContrastText(h.error.dark))),I(h.Alert,"infoFilledColor",wt(()=>h.getContrastText(h.info.dark))),I(h.Alert,"successFilledColor",wt(()=>h.getContrastText(h.success.dark))),I(h.Alert,"warningFilledColor",wt(()=>h.getContrastText(h.warning.dark))),I(h.Alert,"errorStandardBg",je(h.error.light,.9)),I(h.Alert,"infoStandardBg",je(h.info.light,.9)),I(h.Alert,"successStandardBg",je(h.success.light,.9)),I(h.Alert,"warningStandardBg",je(h.warning.light,.9)),I(h.Alert,"errorIconColor",z("palette-error-main")),I(h.Alert,"infoIconColor",z("palette-info-main")),I(h.Alert,"successIconColor",z("palette-success-main")),I(h.Alert,"warningIconColor",z("palette-warning-main")),I(h.AppBar,"defaultBg",z("palette-grey-900")),I(h.AppBar,"darkBg",z("palette-background-paper")),I(h.AppBar,"darkColor",z("palette-text-primary")),I(h.Avatar,"defaultBg",z("palette-grey-600")),I(h.Button,"inheritContainedBg",z("palette-grey-800")),I(h.Button,"inheritContainedHoverBg",z("palette-grey-700")),I(h.Chip,"defaultBorder",z("palette-grey-700")),I(h.Chip,"defaultAvatarColor",z("palette-grey-300")),I(h.Chip,"defaultIconColor",z("palette-grey-300")),I(h.FilledInput,"bg","rgba(255, 255, 255, 0.09)"),I(h.FilledInput,"hoverBg","rgba(255, 255, 255, 0.13)"),I(h.FilledInput,"disabledBg","rgba(255, 255, 255, 0.12)"),I(h.LinearProgress,"primaryBg",je(h.primary.main,.5)),I(h.LinearProgress,"secondaryBg",je(h.secondary.main,.5)),I(h.LinearProgress,"errorBg",je(h.error.main,.5)),I(h.LinearProgress,"infoBg",je(h.info.main,.5)),I(h.LinearProgress,"successBg",je(h.success.main,.5)),I(h.LinearProgress,"warningBg",je(h.warning.main,.5)),I(h.Skeleton,"bg",`rgba(${z("palette-text-primaryChannel")} / 0.13)`),I(h.Slider,"primaryTrack",je(h.primary.main,.5)),I(h.Slider,"secondaryTrack",je(h.secondary.main,.5)),I(h.Slider,"errorTrack",je(h.error.main,.5)),I(h.Slider,"infoTrack",je(h.info.main,.5)),I(h.Slider,"successTrack",je(h.success.main,.5)),I(h.Slider,"warningTrack",je(h.warning.main,.5));const M=Dn(h.background.default,.98);I(h.SnackbarContent,"bg",M),I(h.SnackbarContent,"color",wt(()=>h.getContrastText(M))),I(h.SpeedDialAction,"fabHoverBg",Dn(h.background.paper,.15)),I(h.StepConnector,"border",z("palette-grey-600")),I(h.StepContent,"border",z("palette-grey-600")),I(h.Switch,"defaultColor",z("palette-grey-300")),I(h.Switch,"defaultDisabledColor",z("palette-grey-600")),I(h.Switch,"primaryDisabledColor",je(h.primary.main,.55)),I(h.Switch,"secondaryDisabledColor",je(h.secondary.main,.55)),I(h.Switch,"errorDisabledColor",je(h.error.main,.55)),I(h.Switch,"infoDisabledColor",je(h.info.main,.55)),I(h.Switch,"successDisabledColor",je(h.success.main,.55)),I(h.Switch,"warningDisabledColor",je(h.warning.main,.55)),I(h.TableCell,"border",je($n(h.divider,1),.68)),I(h.Tooltip,"bg",$n(h.grey[700],.92))}_t(h.background,"default"),_t(h.background,"paper"),_t(h.common,"background"),_t(h.common,"onBackground"),_t(h,"divider"),Object.keys(h).forEach(M=>{const q=h[M];M!=="tonalOffset"&&q&&typeof q=="object"&&(q.main&&I(h[M],"mainChannel",ln(cn(q.main))),q.light&&I(h[M],"lightChannel",ln(cn(q.light))),q.dark&&I(h[M],"darkChannel",ln(cn(q.dark))),q.contrastText&&I(h[M],"contrastTextChannel",ln(cn(q.contrastText))),M==="text"&&(_t(h[M],"primary"),_t(h[M],"secondary")),M==="action"&&(q.active&&_t(h[M],"active"),q.selected&&_t(h[M],"selected")))})}),k=t.reduce((U,h)=>it(U,h),k);const v={prefix:a,disableCssColorScheme:i,shouldSkipGeneratingVar:o,getSelector:Ud(k)},{vars:B,generateThemeVars:A,generateStyleSheets:H}=md(k,v);return k.vars=B,Object.entries(k.colorSchemes[k.defaultColorScheme]).forEach(([U,h])=>{k[U]=h}),k.generateThemeVars=A,k.generateStyleSheets=H,k.generateSpacing=function(){return ml(p.spacing,Ra(this))},k.getColorSchemeSelector=yd(s),k.spacing=k.generateSpacing(),k.shouldSkipGeneratingVar=o,k.unstable_sxConfig={...Tn,...p==null?void 0:p.unstable_sxConfig},k.unstable_sx=function(h){return Gr({sx:h,theme:this})},k.toRuntimeSource=El,k}function Yo(e,t,r){e.colorSchemes&&r&&(e.colorSchemes[t]={...r!==!0&&r,palette:Ma({...r===!0?{}:r.palette,mode:t})})}function Yd(e={},...t){const{palette:r,cssVariables:n=!1,colorSchemes:i=r?void 0:{light:!0},defaultColorScheme:a=r==null?void 0:r.mode,...o}=e,s=a||"light",l=i==null?void 0:i[s],p={...i,...r?{[s]:{...typeof l!="boolean"&&l,palette:r}}:void 0};if(n===!1){if(!("colorSchemes"in e))return ta(e,...t);let u=r;"palette"in e||p[s]&&(p[s]!==!0?u=p[s].palette:s==="dark"&&(u={mode:"dark"}));const d=ta({...e,palette:u},...t);return d.defaultColorScheme=s,d.colorSchemes=p,d.palette.mode==="light"&&(d.colorSchemes.light={...p.light!==!0&&p.light,palette:d.palette},Yo(d,"dark",p.dark)),d.palette.mode==="dark"&&(d.colorSchemes.dark={...p.dark!==!0&&p.dark,palette:d.palette},Yo(d,"light",p.light)),d}return!r&&!("light"in p)&&s==="light"&&(p.light=!0),Qd({...o,colorSchemes:p,defaultColorScheme:s,...typeof n!="boolean"&&n},...t)}const Gd=Yd(),Zd="$$material";function Xd(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const Jd=e=>Xd(e)&&e!=="classes",ot=Xp({themeId:Zd,defaultTheme:Gd,rootShouldForwardProp:Jd});function ef(){return _p}const wr=pd;process.env.NODE_ENV!=="production"&&(w.node,w.object.isRequired);function Er(e){return ud(e)}function tf(e){return typeof e.main=="string"}function rf(e,t=[]){if(!tf(e))return!1;for(const r of t)if(!e.hasOwnProperty(r)||typeof e[r]!="string")return!1;return!0}function ei(e=[]){return([,t])=>t&&rf(t,e)}function nf(e){return nr("MuiTypography",e)}Cr("MuiTypography",["root","h1","h2","h3","h4","h5","h6","subtitle1","subtitle2","body1","body2","inherit","button","caption","overline","alignLeft","alignRight","alignCenter","alignJustify","noWrap","gutterBottom","paragraph"]);const af={primary:!0,secondary:!0,error:!0,info:!0,success:!0,warning:!0,textPrimary:!0,textSecondary:!0,textDisabled:!0},of=ef(),sf=e=>{const{align:t,gutterBottom:r,noWrap:n,paragraph:i,variant:a,classes:o}=e,s={root:["root",a,e.align!=="inherit"&&`align${Re(t)}`,r&&"gutterBottom",n&&"noWrap",i&&"paragraph"]};return Xr(s,nf,o)},lf=ot("span",{name:"MuiTypography",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,r.variant&&t[r.variant],r.align!=="inherit"&&t[`align${Re(r.align)}`],r.noWrap&&t.noWrap,r.gutterBottom&&t.gutterBottom,r.paragraph&&t.paragraph]}})(wr(({theme:e})=>{var t;return{margin:0,variants:[{props:{variant:"inherit"},style:{font:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}},...Object.entries(e.typography).filter(([r,n])=>r!=="inherit"&&n&&typeof n=="object").map(([r,n])=>({props:{variant:r},style:n})),...Object.entries(e.palette).filter(ei()).map(([r])=>({props:{color:r},style:{color:(e.vars||e).palette[r].main}})),...Object.entries(((t=e.palette)==null?void 0:t.text)||{}).filter(([,r])=>typeof r=="string").map(([r])=>({props:{color:`text${Re(r)}`},style:{color:(e.vars||e).palette.text[r]}})),{props:({ownerState:r})=>r.align!=="inherit",style:{textAlign:"var(--Typography-textAlign)"}},{props:({ownerState:r})=>r.noWrap,style:{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"}},{props:({ownerState:r})=>r.gutterBottom,style:{marginBottom:"0.35em"}},{props:({ownerState:r})=>r.paragraph,style:{marginBottom:16}}]}})),Go={h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",subtitle1:"h6",subtitle2:"h6",body1:"p",body2:"p",inherit:"p"},Ol=te.forwardRef(function(t,r){const{color:n,...i}=Er({props:t,name:"MuiTypography"}),a=!af[n],o=of({...i,...a&&{color:n}}),{align:s="inherit",className:l,component:p,gutterBottom:u=!1,noWrap:d=!1,paragraph:f=!1,variant:g="body1",variantMapping:S=Go,...c}=o,b={...o,align:s,color:n,className:l,component:p,gutterBottom:u,noWrap:d,paragraph:f,variant:g,variantMapping:S},y=p||(f?"p":S[g]||Go[g])||"span",j=sf(b);return m.jsx(lf,{as:y,ref:r,className:Ye(j.root,l),...c,ownerState:b,style:{...s!=="inherit"&&{"--Typography-textAlign":s},...c.style}})});process.env.NODE_ENV!=="production"&&(Ol.propTypes={align:w.oneOf(["center","inherit","justify","left","right"]),children:w.node,classes:w.object,className:w.string,color:w.oneOfType([w.oneOf(["primary","secondary","success","error","info","warning","textPrimary","textSecondary","textDisabled"]),w.string]),component:w.elementType,gutterBottom:w.bool,noWrap:w.bool,paragraph:w.bool,style:w.object,sx:w.oneOfType([w.arrayOf(w.oneOfType([w.func,w.object,w.bool])),w.func,w.object]),variant:w.oneOfType([w.oneOf(["body1","body2","button","caption","h1","h2","h3","h4","h5","h6","inherit","overline","subtitle1","subtitle2"]),w.string]),variantMapping:w.object});const za=te.createContext(void 0);process.env.NODE_ENV!=="production"&&(za.displayName="FormControlContext");function cf(){return te.useContext(za)}function uf(e){return nr("MuiInputAdornment",e)}const Zo=Cr("MuiInputAdornment",["root","filled","standard","outlined","positionStart","positionEnd","disablePointerEvents","hiddenLabel","sizeSmall"]);var Xo;const pf=(e,t)=>{const{ownerState:r}=e;return[t.root,t[`position${Re(r.position)}`],r.disablePointerEvents===!0&&t.disablePointerEvents,t[r.variant]]},df=e=>{const{classes:t,disablePointerEvents:r,hiddenLabel:n,position:i,size:a,variant:o}=e,s={root:["root",r&&"disablePointerEvents",i&&`position${Re(i)}`,o,n&&"hiddenLabel",a&&`size${Re(a)}`]};return Xr(s,uf,t)},ff=ot("div",{name:"MuiInputAdornment",slot:"Root",overridesResolver:pf})(wr(({theme:e})=>({display:"flex",maxHeight:"2em",alignItems:"center",whiteSpace:"nowrap",color:(e.vars||e).palette.action.active,variants:[{props:{variant:"filled"},style:{[`&.${Zo.positionStart}&:not(.${Zo.hiddenLabel})`]:{marginTop:16}}},{props:{position:"start"},style:{marginRight:8}},{props:{position:"end"},style:{marginLeft:8}},{props:{disablePointerEvents:!0},style:{pointerEvents:"none"}}]}))),jl=te.forwardRef(function(t,r){const n=Er({props:t,name:"MuiInputAdornment"}),{children:i,className:a,component:o="div",disablePointerEvents:s=!1,disableTypography:l=!1,position:p,variant:u,...d}=n,f=cf()||{};let g=u;u&&f.variant&&process.env.NODE_ENV!=="production"&&u===f.variant&&console.error("MUI: The `InputAdornment` variant infers the variant prop you do not have to provide one."),f&&!g&&(g=f.variant);const S={...n,hiddenLabel:f.hiddenLabel,size:f.size,disablePointerEvents:s,position:p,variant:g},c=df(S);return m.jsx(za.Provider,{value:null,children:m.jsx(ff,{as:o,ownerState:S,className:Ye(c.root,a),ref:r,...d,children:typeof i=="string"&&!l?m.jsx(Ol,{color:"textSecondary",children:i}):m.jsxs(te.Fragment,{children:[p==="start"?Xo||(Xo=m.jsx("span",{className:"notranslate","aria-hidden":!0,children:"​"})):null,i]})})})});process.env.NODE_ENV!=="production"&&(jl.propTypes={children:w.node,classes:w.object,className:w.string,component:w.elementType,disablePointerEvents:w.bool,disableTypography:w.bool,position:w.oneOf(["end","start"]).isRequired,sx:w.oneOfType([w.arrayOf(w.oneOfType([w.func,w.object,w.bool])),w.func,w.object]),variant:w.oneOf(["filled","outlined","standard"])});function Va(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...n){return e(...n)||t(...n)}}function hf(e){return nr("MuiSvgIcon",e)}Cr("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const mf=e=>{const{color:t,fontSize:r,classes:n}=e,i={root:["root",t!=="inherit"&&`color${Re(t)}`,`fontSize${Re(r)}`]};return Xr(i,hf,n)},yf=ot("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,r.color!=="inherit"&&t[`color${Re(r.color)}`],t[`fontSize${Re(r.fontSize)}`]]}})(wr(({theme:e})=>{var t,r,n,i,a,o,s,l,p,u,d,f,g,S;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",flexShrink:0,transition:(i=(t=e.transitions)==null?void 0:t.create)==null?void 0:i.call(t,"fill",{duration:(n=(r=(e.vars??e).transitions)==null?void 0:r.duration)==null?void 0:n.shorter}),variants:[{props:c=>!c.hasSvgAsChild,style:{fill:"currentColor"}},{props:{fontSize:"inherit"},style:{fontSize:"inherit"}},{props:{fontSize:"small"},style:{fontSize:((o=(a=e.typography)==null?void 0:a.pxToRem)==null?void 0:o.call(a,20))||"1.25rem"}},{props:{fontSize:"medium"},style:{fontSize:((l=(s=e.typography)==null?void 0:s.pxToRem)==null?void 0:l.call(s,24))||"1.5rem"}},{props:{fontSize:"large"},style:{fontSize:((u=(p=e.typography)==null?void 0:p.pxToRem)==null?void 0:u.call(p,35))||"2.1875rem"}},...Object.entries((e.vars??e).palette).filter(([,c])=>c&&c.main).map(([c])=>{var b,y;return{props:{color:c},style:{color:(y=(b=(e.vars??e).palette)==null?void 0:b[c])==null?void 0:y.main}}}),{props:{color:"action"},style:{color:(f=(d=(e.vars??e).palette)==null?void 0:d.action)==null?void 0:f.active}},{props:{color:"disabled"},style:{color:(S=(g=(e.vars??e).palette)==null?void 0:g.action)==null?void 0:S.disabled}},{props:{color:"inherit"},style:{color:void 0}}]}})),ti=te.forwardRef(function(t,r){const n=Er({props:t,name:"MuiSvgIcon"}),{children:i,className:a,color:o="inherit",component:s="svg",fontSize:l="medium",htmlColor:p,inheritViewBox:u=!1,titleAccess:d,viewBox:f="0 0 24 24",...g}=n,S=te.isValidElement(i)&&i.type==="svg",c={...n,color:o,component:s,fontSize:l,instanceFontSize:t.fontSize,inheritViewBox:u,viewBox:f,hasSvgAsChild:S},b={};u||(b.viewBox=f);const y=mf(c);return m.jsxs(yf,{as:s,className:Ye(y.root,a),focusable:"false",color:p,"aria-hidden":d?void 0:!0,role:d?"img":void 0,ref:r,...b,...g,...S&&i.props,ownerState:c,children:[S?i.props.children:i,d?m.jsx("title",{children:d}):null]})});process.env.NODE_ENV!=="production"&&(ti.propTypes={children:w.node,classes:w.object,className:w.string,color:w.oneOfType([w.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),w.string]),component:w.elementType,fontSize:w.oneOfType([w.oneOf(["inherit","large","medium","small"]),w.string]),htmlColor:w.string,inheritViewBox:w.bool,shapeRendering:w.string,sx:w.oneOfType([w.arrayOf(w.oneOfType([w.func,w.object,w.bool])),w.func,w.object]),titleAccess:w.string,viewBox:w.string});ti.muiName="SvgIcon";function bt(e,t){function r(n,i){return m.jsx(ti,{"data-testid":process.env.NODE_ENV!=="production"?`${t}Icon`:void 0,ref:i,...n,children:e})}return process.env.NODE_ENV!=="production"&&(r.displayName=`${t}Icon`),r.muiName=ti.muiName,te.memo(te.forwardRef(r))}let Jo=0;function gf(e){const[t,r]=te.useState(e),n=e||t;return te.useEffect(()=>{t==null&&(Jo+=1,r(`mui-${Jo}`))},[t]),n}const xf={...te},es=xf.useId;function vf(e){if(es!==void 0){const t=es();return e??t}return gf(e)}function Nn(e){const t=te.useRef(e);return nd(()=>{t.current=e}),te.useRef((...r)=>(0,t.current)(...r)).current}function ts(...e){const t=te.useRef(void 0),r=te.useCallback(n=>{const i=e.map(a=>{if(a==null)return null;if(typeof a=="function"){const o=a,s=o(n);return typeof s=="function"?s:()=>{o(null)}}return a.current=n,()=>{a.current=null}});return()=>{i.forEach(a=>a==null?void 0:a())}},e);return te.useMemo(()=>e.every(n=>n==null)?null:n=>{t.current&&(t.current(),t.current=void 0),n!=null&&(t.current=r(n))},e)}const bf=w.oneOfType([w.func,w.object]);function wf(e){const{prototype:t={}}=e;return!!t.isReactComponent}function Sf(e,t,r,n,i){const a=e[t],o=i||t;if(a==null||typeof window>"u")return null;let s;return typeof a=="function"&&!wf(a)&&(s="Did you accidentally provide a plain function component instead?"),s!==void 0?new Error(`Invalid ${n} \`${o}\` supplied to \`${r}\`. Expected an element type that can hold a ref. ${s} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const Cf=Va(w.elementType,Sf);function rs(e){try{return e.matches(":focus-visible")}catch{process.env.NODE_ENV!=="production"&&!/jsdom/.test(window.navigator.userAgent)&&console.warn(["MUI: The `:focus-visible` pseudo class is not supported in this browser.","Some components rely on this feature to work properly."].join(`
75
+ `))}return!1}const ns={};function Fl(e,t){const r=te.useRef(ns);return r.current===ns&&(r.current=e(t)),r}class ri{constructor(){rn(this,"mountEffect",()=>{this.shouldMount&&!this.didMount&&this.ref.current!==null&&(this.didMount=!0,this.mounted.resolve())});this.ref={current:null},this.mounted=null,this.didMount=!1,this.shouldMount=!1,this.setShouldMount=null}static create(){return new ri}static use(){const t=Fl(ri.create).current,[r,n]=te.useState(!1);return t.shouldMount=r,t.setShouldMount=n,te.useEffect(t.mountEffect,[r]),t}mount(){return this.mounted||(this.mounted=kf(),this.shouldMount=!0,this.setShouldMount(this.shouldMount)),this.mounted}start(...t){this.mount().then(()=>{var r;return(r=this.ref.current)==null?void 0:r.start(...t)})}stop(...t){this.mount().then(()=>{var r;return(r=this.ref.current)==null?void 0:r.stop(...t)})}pulsate(...t){this.mount().then(()=>{var r;return(r=this.ref.current)==null?void 0:r.pulsate(...t)})}}function Ef(){return ri.use()}function kf(){let e,t;const r=new Promise((n,i)=>{e=n,t=i});return r.resolve=e,r.reject=t,r}function ra(){return ra=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},ra.apply(null,arguments)}function Tf(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}function na(e,t){return na=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,n){return r.__proto__=n,r},na(e,t)}function Of(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,na(e,t)}const is=P.createContext(null);function jf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Ba(e,t){var r=function(a){return t&&P.isValidElement(a)?t(a):a},n=Object.create(null);return e&&P.Children.map(e,function(i){return i}).forEach(function(i){n[i.key]=r(i)}),n}function Ff(e,t){e=e||{},t=t||{};function r(u){return u in t?t[u]:e[u]}var n=Object.create(null),i=[];for(var a in e)a in t?i.length&&(n[a]=i,i=[]):i.push(a);var o,s={};for(var l in t){if(n[l])for(o=0;o<n[l].length;o++){var p=n[l][o];s[n[l][o]]=r(p)}s[l]=r(l)}for(o=0;o<i.length;o++)s[i[o]]=r(i[o]);return s}function cr(e,t,r){return r[t]!=null?r[t]:e.props[t]}function Af(e,t){return Ba(e.children,function(r){return P.cloneElement(r,{onExited:t.bind(null,r),in:!0,appear:cr(r,"appear",e),enter:cr(r,"enter",e),exit:cr(r,"exit",e)})})}function _f(e,t,r){var n=Ba(e.children),i=Ff(t,n);return Object.keys(i).forEach(function(a){var o=i[a];if(P.isValidElement(o)){var s=a in t,l=a in n,p=t[a],u=P.isValidElement(p)&&!p.props.in;l&&(!s||u)?i[a]=P.cloneElement(o,{onExited:r.bind(null,o),in:!0,exit:cr(o,"exit",e),enter:cr(o,"enter",e)}):!l&&s&&!u?i[a]=P.cloneElement(o,{in:!1}):l&&s&&P.isValidElement(p)&&(i[a]=P.cloneElement(o,{onExited:r.bind(null,o),in:p.props.in,exit:cr(o,"exit",e),enter:cr(o,"enter",e)}))}}),i}var Rf=Object.values||function(e){return Object.keys(e).map(function(t){return e[t]})},$f={component:"div",childFactory:function(t){return t}},Na=function(e){Of(t,e);function t(n,i){var a;a=e.call(this,n,i)||this;var o=a.handleExited.bind(jf(a));return a.state={contextValue:{isMounting:!0},handleExited:o,firstRender:!0},a}var r=t.prototype;return r.componentDidMount=function(){this.mounted=!0,this.setState({contextValue:{isMounting:!1}})},r.componentWillUnmount=function(){this.mounted=!1},t.getDerivedStateFromProps=function(i,a){var o=a.children,s=a.handleExited,l=a.firstRender;return{children:l?Af(i,s):_f(i,o,s),firstRender:!1}},r.handleExited=function(i,a){var o=Ba(this.props.children);i.key in o||(i.props.onExited&&i.props.onExited(a),this.mounted&&this.setState(function(s){var l=ra({},s.children);return delete l[i.key],{children:l}}))},r.render=function(){var i=this.props,a=i.component,o=i.childFactory,s=Tf(i,["component","childFactory"]),l=this.state.contextValue,p=Rf(this.state.children).map(o);return delete s.appear,delete s.enter,delete s.exit,a===null?P.createElement(is.Provider,{value:l},p):P.createElement(is.Provider,{value:l},P.createElement(a,s,p))},t}(P.Component);Na.propTypes=process.env.NODE_ENV!=="production"?{component:w.any,children:w.node,appear:w.bool,enter:w.bool,exit:w.bool,childFactory:w.func}:{};Na.defaultProps=$f;const Df=[];function Pf(e){te.useEffect(e,Df)}class La{constructor(){rn(this,"currentId",null);rn(this,"clear",()=>{this.currentId!==null&&(clearTimeout(this.currentId),this.currentId=null)});rn(this,"disposeEffect",()=>this.clear)}static create(){return new La}start(t,r){this.clear(),this.currentId=setTimeout(()=>{this.currentId=null,r()},t)}}function If(){const e=Fl(La.create).current;return Pf(e.disposeEffect),e}function Al(e){const{className:t,classes:r,pulsate:n=!1,rippleX:i,rippleY:a,rippleSize:o,in:s,onExited:l,timeout:p}=e,[u,d]=te.useState(!1),f=Ye(t,r.ripple,r.rippleVisible,n&&r.ripplePulsate),g={width:o,height:o,top:-(o/2)+a,left:-(o/2)+i},S=Ye(r.child,u&&r.childLeaving,n&&r.childPulsate);return!s&&!u&&d(!0),te.useEffect(()=>{if(!s&&l!=null){const c=setTimeout(l,p);return()=>{clearTimeout(c)}}},[l,s,p]),m.jsx("span",{className:f,style:g,children:m.jsx("span",{className:S})})}process.env.NODE_ENV!=="production"&&(Al.propTypes={classes:w.object.isRequired,className:w.string,in:w.bool,onExited:w.func,pulsate:w.bool,rippleSize:w.number,rippleX:w.number,rippleY:w.number,timeout:w.number.isRequired});const ut=Cr("MuiTouchRipple",["root","ripple","rippleVisible","ripplePulsate","child","childLeaving","childPulsate"]),ia=550,Mf=80,zf=Sr.keyframes`
76
76
  0% {
77
77
  transform: scale(0);
78
78
  opacity: 0.1;
@@ -102,7 +102,7 @@ To suppress this warning, you need to explicitly provide the \`palette.${t}Chann
102
102
  100% {
103
103
  transform: scale(1);
104
104
  }
105
- `,Nf=ot("span",{name:"MuiTouchRipple",slot:"Root"})({overflow:"hidden",pointerEvents:"none",position:"absolute",zIndex:0,top:0,right:0,bottom:0,left:0,borderRadius:"inherit"}),Lf=ot(Ol,{name:"MuiTouchRipple",slot:"Ripple"})`
105
+ `,Nf=ot("span",{name:"MuiTouchRipple",slot:"Root"})({overflow:"hidden",pointerEvents:"none",position:"absolute",zIndex:0,top:0,right:0,bottom:0,left:0,borderRadius:"inherit"}),Lf=ot(Al,{name:"MuiTouchRipple",slot:"Ripple"})`
106
106
  opacity: 0;
107
107
  position: absolute;
108
108
 
@@ -145,7 +145,7 @@ To suppress this warning, you need to explicitly provide the \`palette.${t}Chann
145
145
  animation-iteration-count: infinite;
146
146
  animation-delay: 200ms;
147
147
  }
148
- `,jl=ne.forwardRef(function(t,r){const n=Er({props:t,name:"MuiTouchRipple"}),{center:i=!1,classes:a={},className:o,...s}=n,[l,p]=ne.useState([]),u=ne.useRef(0),d=ne.useRef(null);ne.useEffect(()=>{d.current&&(d.current(),d.current=null)},[l]);const f=ne.useRef(!1),y=If(),S=ne.useRef(null),c=ne.useRef(null),b=ne.useCallback(k=>{const{pulsate:x,rippleX:B,rippleY:_,rippleSize:K,cb:W}=k;p(h=>[...h,m.jsx(Lf,{classes:{ripple:Ke(a.ripple,ut.ripple),rippleVisible:Ke(a.rippleVisible,ut.rippleVisible),ripplePulsate:Ke(a.ripplePulsate,ut.ripplePulsate),child:Ke(a.child,ut.child),childLeaving:Ke(a.childLeaving,ut.childLeaving),childPulsate:Ke(a.childPulsate,ut.childPulsate)},timeout:ia,pulsate:x,rippleX:B,rippleY:_,rippleSize:K},u.current)]),u.current+=1,d.current=W},[a]),g=ne.useCallback((k={},x={},B=()=>{})=>{const{pulsate:_=!1,center:K=i||x.pulsate,fakeElement:W=!1}=x;if((k==null?void 0:k.type)==="mousedown"&&f.current){f.current=!1;return}(k==null?void 0:k.type)==="touchstart"&&(f.current=!0);const h=W?null:c.current,M=h?h.getBoundingClientRect():{width:0,height:0,left:0,top:0};let P,q,N;if(K||k===void 0||k.clientX===0&&k.clientY===0||!k.clientX&&!k.touches)P=Math.round(M.width/2),q=Math.round(M.height/2);else{const{clientX:X,clientY:ie}=k.touches&&k.touches.length>0?k.touches[0]:k;P=Math.round(X-M.left),q=Math.round(ie-M.top)}if(K)N=Math.sqrt((2*M.width**2+M.height**2)/3),N%2===0&&(N+=1);else{const X=Math.max(Math.abs((h?h.clientWidth:0)-P),P)*2+2,ie=Math.max(Math.abs((h?h.clientHeight:0)-q),q)*2+2;N=Math.sqrt(X**2+ie**2)}k!=null&&k.touches?S.current===null&&(S.current=()=>{b({pulsate:_,rippleX:P,rippleY:q,rippleSize:N,cb:B})},y.start(Mf,()=>{S.current&&(S.current(),S.current=null)})):b({pulsate:_,rippleX:P,rippleY:q,rippleSize:N,cb:B})},[i,b,y]),O=ne.useCallback(()=>{g({},{pulsate:!0})},[g]),A=ne.useCallback((k,x)=>{if(y.clear(),(k==null?void 0:k.type)==="touchend"&&S.current){S.current(),S.current=null,y.start(0,()=>{A(k,x)});return}S.current=null,p(B=>B.length>0?B.slice(1):B),d.current=x},[y]);return ne.useImperativeHandle(r,()=>({pulsate:O,start:g,stop:A}),[O,g,A]),m.jsx(Nf,{className:Ke(ut.root,a.root,o),ref:c,...s,children:m.jsx(za,{component:null,exit:!0,children:l})})});process.env.NODE_ENV!=="production"&&(jl.propTypes={center:w.bool,classes:w.object,className:w.string});function qf(e){return nr("MuiButtonBase",e)}const Uf=Cr("MuiButtonBase",["root","disabled","focusVisible"]),Wf=e=>{const{disabled:t,focusVisible:r,focusVisibleClassName:n,classes:i}=e,o=Xr({root:["root",t&&"disabled",r&&"focusVisible"]},qf,i);return r&&n&&(o.root+=` ${n}`),o},Hf=ot("button",{name:"MuiButtonBase",slot:"Root"})({display:"inline-flex",alignItems:"center",justifyContent:"center",position:"relative",boxSizing:"border-box",WebkitTapHighlightColor:"transparent",backgroundColor:"transparent",outline:0,border:0,margin:0,borderRadius:0,padding:0,cursor:"pointer",userSelect:"none",verticalAlign:"middle",MozAppearance:"none",WebkitAppearance:"none",textDecoration:"none",color:"inherit","&::-moz-focus-inner":{borderStyle:"none"},[`&.${Uf.disabled}`]:{pointerEvents:"none",cursor:"default"},"@media print":{colorAdjust:"exact"}}),Fl=ne.forwardRef(function(t,r){const n=Er({props:t,name:"MuiButtonBase"}),{action:i,centerRipple:a=!1,children:o,className:s,component:l="button",disabled:p=!1,disableRipple:u=!1,disableTouchRipple:d=!1,focusRipple:f=!1,focusVisibleClassName:y,LinkComponent:S="a",onBlur:c,onClick:b,onContextMenu:g,onDragLeave:O,onFocus:A,onFocusVisible:k,onKeyDown:x,onKeyUp:B,onMouseDown:_,onMouseLeave:K,onMouseUp:W,onTouchEnd:h,onTouchMove:M,onTouchStart:P,tabIndex:q=0,TouchRippleProps:N,touchRippleRef:X,type:ie,...ge}=n,ce=ne.useRef(null),se=Ef(),V=Xo(se.ref,X),[H,ue]=ne.useState(!1);p&&H&&ue(!1),ne.useImperativeHandle(i,()=>({focusVisible:()=>{ue(!0),ce.current.focus()}}),[]);const Y=se.shouldMount&&!u&&!p;ne.useEffect(()=>{H&&f&&!u&&se.pulsate()},[u,f,H,se]);const te=Rt(se,"start",_,d),le=Rt(se,"stop",g,d),U=Rt(se,"stop",O,d),ee=Rt(se,"stop",W,d),oe=Rt(se,"stop",T=>{H&&T.preventDefault(),K&&K(T)},d),fe=Rt(se,"start",P,d),pe=Rt(se,"stop",h,d),L=Rt(se,"stop",M,d),I=Rt(se,"stop",T=>{Jo(T.target)||ue(!1),c&&c(T)},!1),z=Nn(T=>{ce.current||(ce.current=T.currentTarget),Jo(T.target)&&(ue(!0),k&&k(T)),A&&A(T)}),ae=()=>{const T=ce.current;return l&&l!=="button"&&!(T.tagName==="A"&&T.href)},de=Nn(T=>{f&&!T.repeat&&H&&T.key===" "&&se.stop(T,()=>{se.start(T)}),T.target===T.currentTarget&&ae()&&T.key===" "&&T.preventDefault(),x&&x(T),T.target===T.currentTarget&&ae()&&T.key==="Enter"&&!p&&(T.preventDefault(),b&&b(T))}),_e=Nn(T=>{f&&T.key===" "&&H&&!T.defaultPrevented&&se.stop(T,()=>{se.pulsate(T)}),B&&B(T),b&&T.target===T.currentTarget&&ae()&&T.key===" "&&!T.defaultPrevented&&b(T)});let Te=l;Te==="button"&&(ge.href||ge.to)&&(Te=S);const Qe={};Te==="button"?(Qe.type=ie===void 0?"button":ie,Qe.disabled=p):(!ge.href&&!ge.to&&(Qe.role="button"),p&&(Qe["aria-disabled"]=p));const Ye=Xo(r,ce),v={...n,centerRipple:a,component:l,disabled:p,disableRipple:u,disableTouchRipple:d,focusRipple:f,tabIndex:q,focusVisible:H},j=Wf(v);return m.jsxs(Hf,{as:Te,className:Ke(j.root,s),ownerState:v,onBlur:I,onClick:b,onContextMenu:le,onFocus:z,onKeyDown:de,onKeyUp:_e,onMouseDown:te,onMouseLeave:oe,onMouseUp:ee,onDragLeave:U,onTouchEnd:pe,onTouchMove:L,onTouchStart:fe,ref:Ye,tabIndex:p?-1:q,type:ie,...Qe,...ge,children:[o,Y?m.jsx(jl,{ref:V,center:a,...N}):null]})});function Rt(e,t,r,n=!1){return Nn(i=>(r&&r(i),n||e[t](i),!0))}process.env.NODE_ENV!=="production"&&(Fl.propTypes={action:bf,centerRipple:w.bool,children:w.node,classes:w.object,className:w.string,component:Cf,disabled:w.bool,disableRipple:w.bool,disableTouchRipple:w.bool,focusRipple:w.bool,focusVisibleClassName:w.string,href:w.any,LinkComponent:w.elementType,onBlur:w.func,onClick:w.func,onContextMenu:w.func,onDragLeave:w.func,onFocus:w.func,onFocusVisible:w.func,onKeyDown:w.func,onKeyUp:w.func,onMouseDown:w.func,onMouseLeave:w.func,onMouseUp:w.func,onTouchEnd:w.func,onTouchMove:w.func,onTouchStart:w.func,sx:w.oneOfType([w.arrayOf(w.oneOfType([w.func,w.object,w.bool])),w.func,w.object]),tabIndex:w.number,TouchRippleProps:w.object,touchRippleRef:w.oneOfType([w.func,w.shape({current:w.shape({pulsate:w.func.isRequired,start:w.func.isRequired,stop:w.func.isRequired})})]),type:w.oneOfType([w.oneOf(["button","reset","submit"]),w.string])});function Kf(e){return nr("MuiCircularProgress",e)}Cr("MuiCircularProgress",["root","determinate","indeterminate","colorPrimary","colorSecondary","svg","circle","circleDeterminate","circleIndeterminate","circleDisableShrink"]);const Vt=44,aa=Sr.keyframes`
148
+ `,_l=te.forwardRef(function(t,r){const n=Er({props:t,name:"MuiTouchRipple"}),{center:i=!1,classes:a={},className:o,...s}=n,[l,p]=te.useState([]),u=te.useRef(0),d=te.useRef(null);te.useEffect(()=>{d.current&&(d.current(),d.current=null)},[l]);const f=te.useRef(!1),g=If(),S=te.useRef(null),c=te.useRef(null),b=te.useCallback(k=>{const{pulsate:v,rippleX:B,rippleY:A,rippleSize:H,cb:U}=k;p(h=>[...h,m.jsx(Lf,{classes:{ripple:Ye(a.ripple,ut.ripple),rippleVisible:Ye(a.rippleVisible,ut.rippleVisible),ripplePulsate:Ye(a.ripplePulsate,ut.ripplePulsate),child:Ye(a.child,ut.child),childLeaving:Ye(a.childLeaving,ut.childLeaving),childPulsate:Ye(a.childPulsate,ut.childPulsate)},timeout:ia,pulsate:v,rippleX:B,rippleY:A,rippleSize:H},u.current)]),u.current+=1,d.current=U},[a]),y=te.useCallback((k={},v={},B=()=>{})=>{const{pulsate:A=!1,center:H=i||v.pulsate,fakeElement:U=!1}=v;if((k==null?void 0:k.type)==="mousedown"&&f.current){f.current=!1;return}(k==null?void 0:k.type)==="touchstart"&&(f.current=!0);const h=U?null:c.current,z=h?h.getBoundingClientRect():{width:0,height:0,left:0,top:0};let M,q,N;if(H||k===void 0||k.clientX===0&&k.clientY===0||!k.clientX&&!k.touches)M=Math.round(z.width/2),q=Math.round(z.height/2);else{const{clientX:J,clientY:ae}=k.touches&&k.touches.length>0?k.touches[0]:k;M=Math.round(J-z.left),q=Math.round(ae-z.top)}if(H)N=Math.sqrt((2*z.width**2+z.height**2)/3),N%2===0&&(N+=1);else{const J=Math.max(Math.abs((h?h.clientWidth:0)-M),M)*2+2,ae=Math.max(Math.abs((h?h.clientHeight:0)-q),q)*2+2;N=Math.sqrt(J**2+ae**2)}k!=null&&k.touches?S.current===null&&(S.current=()=>{b({pulsate:A,rippleX:M,rippleY:q,rippleSize:N,cb:B})},g.start(Mf,()=>{S.current&&(S.current(),S.current=null)})):b({pulsate:A,rippleX:M,rippleY:q,rippleSize:N,cb:B})},[i,b,g]),j=te.useCallback(()=>{y({},{pulsate:!0})},[y]),R=te.useCallback((k,v)=>{if(g.clear(),(k==null?void 0:k.type)==="touchend"&&S.current){S.current(),S.current=null,g.start(0,()=>{R(k,v)});return}S.current=null,p(B=>B.length>0?B.slice(1):B),d.current=v},[g]);return te.useImperativeHandle(r,()=>({pulsate:j,start:y,stop:R}),[j,y,R]),m.jsx(Nf,{className:Ye(ut.root,a.root,o),ref:c,...s,children:m.jsx(Na,{component:null,exit:!0,children:l})})});process.env.NODE_ENV!=="production"&&(_l.propTypes={center:w.bool,classes:w.object,className:w.string});function qf(e){return nr("MuiButtonBase",e)}const Uf=Cr("MuiButtonBase",["root","disabled","focusVisible"]),Wf=e=>{const{disabled:t,focusVisible:r,focusVisibleClassName:n,classes:i}=e,o=Xr({root:["root",t&&"disabled",r&&"focusVisible"]},qf,i);return r&&n&&(o.root+=` ${n}`),o},Hf=ot("button",{name:"MuiButtonBase",slot:"Root"})({display:"inline-flex",alignItems:"center",justifyContent:"center",position:"relative",boxSizing:"border-box",WebkitTapHighlightColor:"transparent",backgroundColor:"transparent",outline:0,border:0,margin:0,borderRadius:0,padding:0,cursor:"pointer",userSelect:"none",verticalAlign:"middle",MozAppearance:"none",WebkitAppearance:"none",textDecoration:"none",color:"inherit","&::-moz-focus-inner":{borderStyle:"none"},[`&.${Uf.disabled}`]:{pointerEvents:"none",cursor:"default"},"@media print":{colorAdjust:"exact"}}),Rl=te.forwardRef(function(t,r){const n=Er({props:t,name:"MuiButtonBase"}),{action:i,centerRipple:a=!1,children:o,className:s,component:l="button",disabled:p=!1,disableRipple:u=!1,disableTouchRipple:d=!1,focusRipple:f=!1,focusVisibleClassName:g,LinkComponent:S="a",onBlur:c,onClick:b,onContextMenu:y,onDragLeave:j,onFocus:R,onFocusVisible:k,onKeyDown:v,onKeyUp:B,onMouseDown:A,onMouseLeave:H,onMouseUp:U,onTouchEnd:h,onTouchMove:z,onTouchStart:M,tabIndex:q=0,TouchRippleProps:N,touchRippleRef:J,type:ae,...he}=n,ie=te.useRef(null),oe=Ef(),V=ts(oe.ref,J),[W,ce]=te.useState(!1);p&&W&&ce(!1),te.useImperativeHandle(i,()=>({focusVisible:()=>{ce(!0),ie.current.focus()}}),[]);const me=oe.shouldMount&&!u&&!p;te.useEffect(()=>{W&&f&&!u&&oe.pulsate()},[u,f,W,oe]);const se=Rt(oe,"start",A,d),L=Rt(oe,"stop",y,d),X=Rt(oe,"stop",j,d),ne=Rt(oe,"stop",U,d),ue=Rt(oe,"stop",T=>{W&&T.preventDefault(),H&&H(T)},d),de=Rt(oe,"start",M,d),pe=Rt(oe,"stop",h,d),D=Rt(oe,"stop",z,d),_=Rt(oe,"stop",T=>{rs(T.target)||ce(!1),c&&c(T)},!1),Q=Nn(T=>{ie.current||(ie.current=T.currentTarget),rs(T.target)&&(ce(!0),k&&k(T)),R&&R(T)}),fe=()=>{const T=ie.current;return l&&l!=="button"&&!(T.tagName==="A"&&T.href)},xe=Nn(T=>{f&&!T.repeat&&W&&T.key===" "&&oe.stop(T,()=>{oe.start(T)}),T.target===T.currentTarget&&fe()&&T.key===" "&&T.preventDefault(),v&&v(T),T.target===T.currentTarget&&fe()&&T.key==="Enter"&&!p&&(T.preventDefault(),b&&b(T))}),Be=Nn(T=>{f&&T.key===" "&&W&&!T.defaultPrevented&&oe.stop(T,()=>{oe.pulsate(T)}),B&&B(T),b&&T.target===T.currentTarget&&fe()&&T.key===" "&&!T.defaultPrevented&&b(T)});let Le=l;Le==="button"&&(he.href||he.to)&&(Le=S);const re={};Le==="button"?(re.type=ae===void 0?"button":ae,re.disabled=p):(!he.href&&!he.to&&(re.role="button"),p&&(re["aria-disabled"]=p));const Oe=ts(r,ie),x={...n,centerRipple:a,component:l,disabled:p,disableRipple:u,disableTouchRipple:d,focusRipple:f,tabIndex:q,focusVisible:W},O=Wf(x);return m.jsxs(Hf,{as:Le,className:Ye(O.root,s),ownerState:x,onBlur:_,onClick:b,onContextMenu:L,onFocus:Q,onKeyDown:xe,onKeyUp:Be,onMouseDown:se,onMouseLeave:ue,onMouseUp:ne,onDragLeave:X,onTouchEnd:pe,onTouchMove:D,onTouchStart:de,ref:Oe,tabIndex:p?-1:q,type:ae,...re,...he,children:[o,me?m.jsx(_l,{ref:V,center:a,...N}):null]})});function Rt(e,t,r,n=!1){return Nn(i=>(r&&r(i),n||e[t](i),!0))}process.env.NODE_ENV!=="production"&&(Rl.propTypes={action:bf,centerRipple:w.bool,children:w.node,classes:w.object,className:w.string,component:Cf,disabled:w.bool,disableRipple:w.bool,disableTouchRipple:w.bool,focusRipple:w.bool,focusVisibleClassName:w.string,href:w.any,LinkComponent:w.elementType,onBlur:w.func,onClick:w.func,onContextMenu:w.func,onDragLeave:w.func,onFocus:w.func,onFocusVisible:w.func,onKeyDown:w.func,onKeyUp:w.func,onMouseDown:w.func,onMouseLeave:w.func,onMouseUp:w.func,onTouchEnd:w.func,onTouchMove:w.func,onTouchStart:w.func,sx:w.oneOfType([w.arrayOf(w.oneOfType([w.func,w.object,w.bool])),w.func,w.object]),tabIndex:w.number,TouchRippleProps:w.object,touchRippleRef:w.oneOfType([w.func,w.shape({current:w.shape({pulsate:w.func.isRequired,start:w.func.isRequired,stop:w.func.isRequired})})]),type:w.oneOfType([w.oneOf(["button","reset","submit"]),w.string])});function Kf(e){return nr("MuiCircularProgress",e)}Cr("MuiCircularProgress",["root","determinate","indeterminate","colorPrimary","colorSecondary","svg","circle","circleDeterminate","circleIndeterminate","circleDisableShrink"]);const Vt=44,aa=Sr.keyframes`
149
149
  0% {
150
150
  transform: rotate(0deg);
151
151
  }
@@ -172,12 +172,12 @@ To suppress this warning, you need to explicitly provide the \`palette.${t}Chann
172
172
  animation: ${aa} 1.4s linear infinite;
173
173
  `:null,Yf=typeof oa!="string"?Sr.css`
174
174
  animation: ${oa} 1.4s ease-in-out infinite;
175
- `:null,Gf=e=>{const{classes:t,variant:r,color:n,disableShrink:i}=e,a={root:["root",r,`color${Re(n)}`],svg:["svg"],circle:["circle",`circle${Re(r)}`,i&&"circleDisableShrink"]};return Xr(a,Kf,t)},Zf=ot("span",{name:"MuiCircularProgress",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,t[r.variant],t[`color${Re(r.color)}`]]}})(wr(({theme:e})=>({display:"inline-block",variants:[{props:{variant:"determinate"},style:{transition:e.transitions.create("transform")}},{props:{variant:"indeterminate"},style:Qf||{animation:`${aa} 1.4s linear infinite`}},...Object.entries(e.palette).filter(ei()).map(([t])=>({props:{color:t},style:{color:(e.vars||e).palette[t].main}}))]}))),Xf=ot("svg",{name:"MuiCircularProgress",slot:"Svg"})({display:"block"}),Jf=ot("circle",{name:"MuiCircularProgress",slot:"Circle",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.circle,t[`circle${Re(r.variant)}`],r.disableShrink&&t.circleDisableShrink]}})(wr(({theme:e})=>({stroke:"currentColor",variants:[{props:{variant:"determinate"},style:{transition:e.transitions.create("stroke-dashoffset")}},{props:{variant:"indeterminate"},style:{strokeDasharray:"80px, 200px",strokeDashoffset:0}},{props:({ownerState:t})=>t.variant==="indeterminate"&&!t.disableShrink,style:Yf||{animation:`${oa} 1.4s ease-in-out infinite`}}]}))),_l=ne.forwardRef(function(t,r){const n=Er({props:t,name:"MuiCircularProgress"}),{className:i,color:a="primary",disableShrink:o=!1,size:s=40,style:l,thickness:p=3.6,value:u=0,variant:d="indeterminate",...f}=n,y={...n,color:a,disableShrink:o,size:s,thickness:p,value:u,variant:d},S=Gf(y),c={},b={},g={};if(d==="determinate"){const O=2*Math.PI*((Vt-p)/2);c.strokeDasharray=O.toFixed(3),g["aria-valuenow"]=Math.round(u),c.strokeDashoffset=`${((100-u)/100*O).toFixed(3)}px`,b.transform="rotate(-90deg)"}return m.jsx(Zf,{className:Ke(S.root,i),style:{width:s,height:s,...b,...l},ownerState:y,ref:r,role:"progressbar",...g,...f,children:m.jsx(Xf,{className:S.svg,ownerState:y,viewBox:`${Vt/2} ${Vt/2} ${Vt} ${Vt}`,children:m.jsx(Jf,{className:S.circle,style:c,ownerState:y,cx:Vt,cy:Vt,r:(Vt-p)/2,fill:"none",strokeWidth:p})})})});process.env.NODE_ENV!=="production"&&(_l.propTypes={classes:w.object,className:w.string,color:w.oneOfType([w.oneOf(["inherit","primary","secondary","error","info","success","warning"]),w.string]),disableShrink:Ia(w.bool,e=>e.disableShrink&&e.variant&&e.variant!=="indeterminate"?new Error("MUI: You have provided the `disableShrink` prop with a variant other than `indeterminate`. This will have no effect."):null),size:w.oneOfType([w.number,w.string]),style:w.object,sx:w.oneOfType([w.arrayOf(w.oneOfType([w.func,w.object,w.bool])),w.func,w.object]),thickness:w.number,value:w.number,variant:w.oneOf(["determinate","indeterminate"])});function eh(e){return nr("MuiIconButton",e)}const rs=Cr("MuiIconButton",["root","disabled","colorInherit","colorPrimary","colorSecondary","colorError","colorInfo","colorSuccess","colorWarning","edgeStart","edgeEnd","sizeSmall","sizeMedium","sizeLarge","loading","loadingIndicator","loadingWrapper"]),th=e=>{const{classes:t,disabled:r,color:n,edge:i,size:a,loading:o}=e,s={root:["root",o&&"loading",r&&"disabled",n!=="default"&&`color${Re(n)}`,i&&`edge${Re(i)}`,`size${Re(a)}`],loadingIndicator:["loadingIndicator"],loadingWrapper:["loadingWrapper"]};return Xr(s,eh,t)},rh=ot(Fl,{name:"MuiIconButton",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,r.loading&&t.loading,r.color!=="default"&&t[`color${Re(r.color)}`],r.edge&&t[`edge${Re(r.edge)}`],t[`size${Re(r.size)}`]]}})(wr(({theme:e})=>({textAlign:"center",flex:"0 0 auto",fontSize:e.typography.pxToRem(24),padding:8,borderRadius:"50%",color:(e.vars||e).palette.action.active,transition:e.transitions.create("background-color",{duration:e.transitions.duration.shortest}),variants:[{props:t=>!t.disableRipple,style:{"--IconButton-hoverBg":e.vars?`rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.hoverOpacity})`:Ft(e.palette.action.active,e.palette.action.hoverOpacity),"&:hover":{backgroundColor:"var(--IconButton-hoverBg)","@media (hover: none)":{backgroundColor:"transparent"}}}},{props:{edge:"start"},style:{marginLeft:-12}},{props:{edge:"start",size:"small"},style:{marginLeft:-3}},{props:{edge:"end"},style:{marginRight:-12}},{props:{edge:"end",size:"small"},style:{marginRight:-3}}]})),wr(({theme:e})=>({variants:[{props:{color:"inherit"},style:{color:"inherit"}},...Object.entries(e.palette).filter(ei()).map(([t])=>({props:{color:t},style:{color:(e.vars||e).palette[t].main}})),...Object.entries(e.palette).filter(ei()).map(([t])=>({props:{color:t},style:{"--IconButton-hoverBg":e.vars?`rgba(${(e.vars||e).palette[t].mainChannel} / ${e.vars.palette.action.hoverOpacity})`:Ft((e.vars||e).palette[t].main,e.palette.action.hoverOpacity)}})),{props:{size:"small"},style:{padding:5,fontSize:e.typography.pxToRem(18)}},{props:{size:"large"},style:{padding:12,fontSize:e.typography.pxToRem(28)}}],[`&.${rs.disabled}`]:{backgroundColor:"transparent",color:(e.vars||e).palette.action.disabled},[`&.${rs.loading}`]:{color:"transparent"}}))),nh=ot("span",{name:"MuiIconButton",slot:"LoadingIndicator"})(({theme:e})=>({display:"none",position:"absolute",visibility:"visible",top:"50%",left:"50%",transform:"translate(-50%, -50%)",color:(e.vars||e).palette.action.disabled,variants:[{props:{loading:!0},style:{display:"flex"}}]})),Ln=ne.forwardRef(function(t,r){const n=Er({props:t,name:"MuiIconButton"}),{edge:i=!1,children:a,className:o,color:s="default",disabled:l=!1,disableFocusRipple:p=!1,size:u="medium",id:d,loading:f=null,loadingIndicator:y,...S}=n,c=vf(d),b=y??m.jsx(_l,{"aria-labelledby":c,color:"inherit",size:16}),g={...n,edge:i,color:s,disabled:l,disableFocusRipple:p,loading:f,loadingIndicator:b,size:u},O=th(g);return m.jsxs(rh,{id:f?c:d,className:Ke(O.root,o),centerRipple:!0,focusRipple:!p,disabled:l||f,ref:r,...S,ownerState:g,children:[typeof f=="boolean"&&m.jsx("span",{className:O.loadingWrapper,style:{display:"contents"},children:m.jsx(nh,{className:O.loadingIndicator,ownerState:g,children:f&&b})}),a]})});process.env.NODE_ENV!=="production"&&(Ln.propTypes={children:Ia(w.node,e=>ne.Children.toArray(e.children).some(r=>ne.isValidElement(r)&&r.props.onClick)?new Error(["MUI: You are providing an onClick event listener to a child of a button element.","Prefer applying it to the IconButton directly.","This guarantees that the whole <button> will be responsive to click events."].join(`
176
- `)):null),classes:w.object,className:w.string,color:w.oneOfType([w.oneOf(["inherit","default","primary","secondary","error","info","success","warning"]),w.string]),disabled:w.bool,disableFocusRipple:w.bool,disableRipple:w.bool,edge:w.oneOf(["end","start",!1]),id:w.string,loading:w.bool,loadingIndicator:w.node,size:w.oneOfType([w.oneOf(["small","medium","large"]),w.string]),sx:w.oneOfType([w.arrayOf(w.oneOfType([w.func,w.object,w.bool])),w.func,w.object])});const ns=vt(m.jsx("path",{d:"M12 4.5C7 4.5 2.73 7.61 1 12c1.73 4.39 6 7.5 11 7.5s9.27-3.11 11-7.5c-1.73-4.39-6-7.5-11-7.5M12 17c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5m0-8c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3"}),"Visibility"),is=vt(m.jsx("path",{d:"M12 7c2.76 0 5 2.24 5 5 0 .65-.13 1.26-.36 1.83l2.92 2.92c1.51-1.26 2.7-2.89 3.43-4.75-1.73-4.39-6-7.5-11-7.5-1.4 0-2.74.25-3.98.7l2.16 2.16C10.74 7.13 11.35 7 12 7M2 4.27l2.28 2.28.46.46C3.08 8.3 1.78 10.02 1 12c1.73 4.39 6 7.5 11 7.5 1.55 0 3.03-.3 4.38-.84l.42.42L19.73 22 21 20.73 3.27 3zM7.53 9.8l1.55 1.55c-.05.21-.08.43-.08.65 0 1.66 1.34 3 3 3 .22 0 .44-.03.65-.08l1.55 1.55c-.67.33-1.41.53-2.2.53-2.76 0-5-2.24-5-5 0-.79.2-1.53.53-2.2m4.31-.78 3.15 3.15.02-.16c0-1.66-1.34-3-3-3z"}),"VisibilityOff"),ih=vt(m.jsx("path",{d:"M16 1H4c-1.1 0-2 .9-2 2v14h2V3h12zm3 4H8c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h11c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2m0 16H8V7h11z"}),"ContentCopy"),Ba=vt(m.jsx("path",{d:"M9 16.17 4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z"}),"Check"),ni=vt(m.jsx("path",{d:"M18 15v3H6v-3H4v3c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2v-3zM7 9l1.41 1.41L11 7.83V16h2V7.83l2.59 2.58L17 9l-5-5z"}),"FileUploadOutlined"),ah=vt(m.jsx("path",{d:"M19 5v14H5V5zm0-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2m-4.86 8.86-3 3.87L9 13.14 6 17h12z"}),"ImageOutlined"),Q={primary:{main:"#2C5EFF",contrastText:"#FFFFFF"},secondary:{main:"#00B894",contrastText:"#FFFFFF"},error:{main:"#E53935"},warning:{main:"#FB8C00"},info:{main:"#1E88E5"},success:{main:"#43A047"},background:{default:"#FFFFFF",paper:"#FFFFFF"},text:{primary:"#111827",secondary:"#6B7280",disabled:"#9CA3AF"},divider:"#E5E7EB"},as=e=>{const t=e.replace("#",""),r=parseInt(t.length===3?t.split("").map(n=>n+n).join(""):t,16);return{r:r>>16&255,g:r>>8&255,b:r&255}},oh=(e,t,r)=>"#"+[e,t,r].map(n=>{const i=Math.round(Math.min(255,Math.max(0,n))).toString(16);return i.length===1?"0"+i:i}).join(""),$t=(e,t,r)=>{const n=as(e),i=as(t);return oh(n.r+(i.r-n.r)*r,n.g+(i.g-n.g)*r,n.b+(i.b-n.b)*r)},Na=e=>{const t="#FFFFFF",r="#000000";return{50:$t(t,e,.08),100:$t(t,e,.16),200:$t(t,e,.28),300:$t(t,e,.4),400:$t(t,e,.55),500:e,600:$t(e,r,.1),700:$t(e,r,.2),800:$t(e,r,.3),900:$t(e,r,.42)}},sh=Na(Q.primary.main),lh=Na(Q.secondary.main),tt=Na(Q.text.primary),ch={primary:Q.primary.main,secondary:Q.secondary.main,textPrimary:Q.text.primary,textSecondary:Q.text.secondary,divider:Q.divider,background:Q.background},sa=({hasError:e,sx:t,labelText:r,labelVariant:n="subtitle2",endAdornment:i,endorsementText:a,endorsementBg:o="#E6E8EC",endorsementColor:s="#111827",endorsementRadius:l="6px",endorsementHeight:p=28,endorsementPaddingX:u="8px",...d})=>{var c,b;const f=!!r,y=a?m.jsx(E.Box,{component:"span",sx:{display:"inline-flex",flex:"0 0 auto",width:"auto",maxWidth:"100%",alignItems:"center",height:p,paddingLeft:u,paddingRight:u,borderRadius:l,backgroundColor:o,color:s,fontSize:12,fontWeight:300,lineHeight:1,whiteSpace:"nowrap"},children:a}):null,S={...d.InputProps,endAdornment:y||i?m.jsxs(E.InputAdornment,{sx:{mr:-1},position:"end",children:[y||i,(c=d.InputProps)==null?void 0:c.endAdornment]}):(b=d.InputProps)==null?void 0:b.endAdornment};return m.jsxs(E.Box,{children:[f&&m.jsx(E.Typography,{variant:n,sx:{color:Q.text.primary,mb:.5,fontWeight:500},children:r}),m.jsx(E.TextField,{fullWidth:!0,size:"small",...d,InputProps:S,label:f?void 0:d.label,sx:{"& .MuiOutlinedInput-root":{backgroundColor:Q.background.paper,borderRadius:"8px","& fieldset":{borderColor:Q.divider},"&:hover fieldset":{borderColor:tt[300]},"&.Mui-focused fieldset":{borderColor:tt[400]},"&.Mui-error fieldset":{borderColor:Q.error.main}},"& .MuiInputBase-input":{color:Q.text.primary},"& .MuiFormLabel-root":{color:Q.text.secondary},"& .MuiFormLabel-root.Mui-focused":{color:Q.text.primary},"& .MuiFormHelperText-root":{color:e?Q.error.main:Q.text.secondary},...t}})]})},Al=({labelText:e,label:t,options:r,loading:n,helperText:i,size:a="small",labelVariant:o="subtitle2",placeholder:s,value:l,sx:p,...u})=>{const d=$.useId(),f=l==null||l===""||Array.isArray(l)&&l.length===0,y=S=>m.jsx("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",...S,children:m.jsx("path",{d:"M6 9l6 6 6-6",stroke:Q.text.secondary,strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})});return m.jsxs(E.FormControl,{fullWidth:!0,size:a,error:!!u.error,variant:"outlined",children:[e&&m.jsx(E.Typography,{variant:o,sx:{color:Q.text.primary,mb:.5,fontWeight:500},children:e}),t&&m.jsx(E.InputLabel,{id:d,shrink:!f||!!s,sx:{color:Q.text.secondary,"&.Mui-focused":{color:Q.text.primary},"&.Mui-error":{color:Q.error.main}},children:t}),m.jsx(E.Select,{...u,value:l,labelId:t?d:void 0,label:t,displayEmpty:!0,input:m.jsx(E.OutlinedInput,{label:t}),IconComponent:y,renderValue:S=>{const c=S;if(f)return m.jsx("span",{style:{color:Q.text.secondary},children:s??""});const b=r.find(g=>g.value===c);return(b==null?void 0:b.label)??String(c)},endAdornment:n?m.jsx(E.CircularProgress,{size:20}):void 0,MenuProps:{PaperProps:{sx:{boxShadow:"0px 0px 10px 0px rgba(0, 0, 0, 0.1)",border:`1px solid ${Q.divider}`,mt:.5,borderRadius:"8px"}}},sx:{backgroundColor:Q.background.paper,boxShadow:"none",borderRadius:"8px",height:"40px","& .MuiSelect-select":{color:Q.text.primary,fontSize:14,pr:3},"& .MuiOutlinedInput-notchedOutline":{borderColor:Q.divider},"&:hover .MuiOutlinedInput-notchedOutline":{borderColor:tt[300]},"&.Mui-focused .MuiOutlinedInput-notchedOutline":{borderColor:tt[400]},"&.Mui-error .MuiOutlinedInput-notchedOutline":{borderColor:Q.error.main},"& svg":{right:8,position:"absolute",pointerEvents:"none"},...p},children:n?m.jsx(E.MenuItem,{disabled:!0,children:m.jsx(E.CircularProgress,{size:16})}):r.map(S=>m.jsx(E.MenuItem,{value:S.value,sx:{backgroundColor:Q.background.paper,color:Q.text.primary,fontSize:14,mx:1,"&:hover":{backgroundColor:tt[50],borderRadius:"4px"},"&.Mui-selected":{backgroundColor:tt[50],borderRadius:"4px"}},children:S.label},S.value))}),i&&m.jsx(E.FormHelperText,{children:i})]})},uh=e=>m.jsx("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e,children:m.jsx("path",{d:"M6 9l6 6 6-6",stroke:Q.text.secondary,strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})}),Rl=({id:e,options:t,value:r,multiple:n,label:i,labelText:a,placeholder:o,onChange:s,labelVariant:l="subtitle2",disabled:p,loading:u,error:d,helperText:f,onOpen:y,noOptionsText:S,sx:c})=>m.jsxs(E.Box,{children:[a&&m.jsx(E.Typography,{variant:l,sx:{color:Q.text.primary,mb:.5,fontWeight:500},children:a}),m.jsx(E.Autocomplete,{id:e,options:t,value:r,multiple:n,size:"small",popupIcon:m.jsx(uh,{}),disabled:p,loading:u,onOpen:y,noOptionsText:S,fullWidth:!0,componentsProps:{paper:{sx:{boxShadow:"0px 0px 10px 0px rgba(0, 0, 0, 0.1)",border:`1px solid ${Q.divider}`,mt:.5,borderRadius:"8px"}}},sx:{"& .MuiOutlinedInput-root":{backgroundColor:Q.background.paper,borderRadius:"8px",height:"40px","& fieldset":{borderColor:Q.divider},"&:hover fieldset":{borderColor:tt[300]},"&.Mui-focused fieldset":{borderColor:tt[400]},"&.Mui-error fieldset":{borderColor:Q.error.main}},"& .MuiInputBase-input":{color:Q.text.primary,fontSize:14},"& .MuiAutocomplete-popupIndicator":{color:Q.text.secondary},"& .MuiAutocomplete-endAdornment svg":{width:16,height:16},...c},getOptionLabel:b=>typeof b=="string"?b:(b==null?void 0:b.label)??"",isOptionEqualToValue:(b,g)=>((b==null?void 0:b.value)??b)===((g==null?void 0:g.value)??g),renderOption:(b,g,{selected:O})=>m.jsxs(E.Box,{component:"li",...b,sx:{backgroundColor:Q.background.paper,color:Q.text.primary,mx:.5,borderRadius:"4px","&:hover":{backgroundColor:tt[50]},"&.Mui-focused":{backgroundColor:tt[50]},...O?{backgroundColor:tt[50]}:{}},children:[n&&m.jsx(E.Checkbox,{checked:O}),m.jsx(E.Typography,{variant:"body2",sx:{color:Q.text.primary,fontSize:14},children:typeof g=="string"?g:g.label})]}),renderInput:b=>m.jsx(E.TextField,{...b,label:i,placeholder:o,size:"small",error:d,helperText:f,InputLabelProps:{shrink:!!r||!!o,sx:{color:Q.text.secondary,"&.Mui-focused":{color:Q.text.primary},"&.Mui-error":{color:Q.error.main}}},InputProps:{...b.InputProps,endAdornment:m.jsxs(m.Fragment,{children:[u?m.jsx(E.CircularProgress,{size:20}):null,b.InputProps.endAdornment]})}}),onChange:(b,g)=>s(g)})]}),$l=({label:e,checked:t,disabled:r,onChange:n,sx:i})=>m.jsx(E.FormControlLabel,{control:m.jsx(E.Checkbox,{size:"small",checked:t,disabled:r,onChange:(a,o)=>n(o)}),label:e,sx:a=>({"& .MuiFormControlLabel-label":{color:a.palette.text.primary,fontSize:14},...i})}),Dl=({label:e,checked:t,disabled:r,onChange:n,sx:i})=>m.jsx(E.FormControlLabel,{control:m.jsx(E.Switch,{checked:t,disabled:r,onChange:(a,o)=>n(o)}),label:e,sx:a=>({"& .MuiFormControlLabel-label":{color:a.palette.text.primary,fontSize:14},...i})}),la=({labelText:e,label:t,value:r,options:n,row:i=!1,onChange:a,labelPosition:o="top",labelVariant:s="subtitle2",helperText:l,error:p,groupPadding:u=1.5,itemGap:d=1})=>m.jsxs(E.FormControl,{error:p,sx:f=>{var y;return{display:"flex",flexDirection:"column",px:f.spacing(u),borderRadius:((y=f.shape)==null?void 0:y.borderRadius)||8,mx:-2.5,backgroundColor:f.palette.background.paper}},children:[o==="top"&&e&&m.jsx(E.Typography,{variant:s,sx:f=>({color:f.palette.text.primary,mb:.5,fontSize:f.typography.fontSize,fontWeight:500}),children:e}),t&&m.jsx(E.FormLabel,{sx:f=>({color:f.palette.text.secondary,mb:.5,mx:1,fontSize:f.typography.fontSize||12,fontWeight:500,"&.Mui-focused":{color:f.palette.text.primary},"&.Mui-error":{color:f.palette.error.main}}),children:t}),m.jsx(E.RadioGroup,{row:i,value:r,onChange:f=>a(f.target.value),sx:f=>({display:"flex",flexDirection:i?"row":"column",gap:f.spacing(d),alignItems:i?"center":"flex-start",mt:-1}),children:n.map(f=>m.jsx(E.FormControlLabel,{value:f.value,control:m.jsx(E.Radio,{size:"small",sx:y=>({color:y.palette.text.secondary,"&.Mui-checked":{color:y.palette.primary.main}})}),label:f.label,sx:y=>({m:0,"& .MuiFormControlLabel-label":{color:y.palette.text.primary,fontSize:14}})},String(f.value)))}),l&&m.jsx(E.FormHelperText,{sx:{mt:.5},children:l})]}),Pl=({labelPosition:e="inner",labelVariant:t="subtitle2",label:r,sx:n,...i})=>m.jsxs(E.Box,{children:[e==="top"&&r&&m.jsx(E.Typography,{variant:t,sx:{color:"#111827",mb:.5},children:r}),m.jsx(E.TextField,{fullWidth:!0,type:"date",size:"small",label:e==="inner"?r:void 0,InputLabelProps:{shrink:!0},...i,sx:{"& .MuiOutlinedInput-root":{backgroundColor:"#FFFFFF",borderRadius:"8px","& fieldset":{borderColor:"#E5E7EB"},"&:hover fieldset":{borderColor:"#D1D5DB"},"&.Mui-focused fieldset":{borderColor:"#D1D5DB"},"&.Mui-error fieldset":{borderColor:"#E53935"}},"& .MuiInputBase-input":{color:"#111827",fontSize:14},...n}})]}),Il=({labelText:e,labelVariant:t="subtitle2",hasError:r,sx:n,label:i,...a})=>{const o=!!e;return m.jsxs(E.Box,{children:[o&&m.jsx(E.Typography,{variant:t,sx:{color:Q.text.primary,mb:.5,fontWeight:500},children:e}),m.jsx(E.TextField,{fullWidth:!0,multiline:!0,minRows:3,size:"small",...a,label:o?void 0:i,sx:{"& .MuiOutlinedInput-root":{backgroundColor:Q.background.paper,borderRadius:"8px","& fieldset":{borderColor:Q.divider},"&:hover fieldset":{borderColor:tt[300]},"&.Mui-focused fieldset":{borderColor:tt[400]},"&.Mui-error fieldset":{borderColor:Q.error.main}},"& .MuiInputBase-input":{color:Q.text.primary,fontSize:14},"& .MuiFormLabel-root":{color:Q.text.secondary},"& .MuiFormLabel-root.Mui-focused":{color:Q.text.primary},"& .MuiFormHelperText-root":{color:r?Q.error.main:Q.text.secondary},...n}})]})},Ml=({title:e,subtitle:t,actions:r,align:n="left",sx:i})=>m.jsxs(E.Box,{sx:a=>({display:"flex",flexDirection:"row",alignItems:"center",justifyContent:"space-between",gap:a.spacing(1),py:a.spacing(1),...i}),children:[m.jsxs(E.Box,{sx:{display:"flex",flexDirection:"column",minWidth:0,flex:1,textAlign:n},children:[e&&m.jsx(E.Typography,{variant:"h6",sx:a=>({color:a.palette.text.primary,fontSize:12,fontWeight:600,lineHeight:1.3}),children:e}),t&&m.jsx(E.Typography,{variant:"body2",sx:a=>({color:a.palette.text.secondary,mt:e?.5:0,fontSize:12,fontWeight:300}),children:t})]}),r&&m.jsx(E.Box,{sx:{display:"flex",alignItems:"center",gap:1,flexWrap:"wrap"},children:r})]}),ph=()=>m.jsxs("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[m.jsx("g",{"clip-path":"url(#clip0_5814_24904)",children:m.jsx("path",{d:"M11 18C11 19.1 10.1 20 9 20C7.9 20 7 19.1 7 18C7 16.9 7.9 16 9 16C10.1 16 11 16.9 11 18ZM9 10C7.9 10 7 10.9 7 12C7 13.1 7.9 14 9 14C10.1 14 11 13.1 11 12C11 10.9 10.1 10 9 10ZM9 4C7.9 4 7 4.9 7 6C7 7.1 7.9 8 9 8C10.1 8 11 7.1 11 6C11 4.9 10.1 4 9 4ZM15 8C16.1 8 17 7.1 17 6C17 4.9 16.1 4 15 4C13.9 4 13 4.9 13 6C13 7.1 13.9 8 15 8ZM15 10C13.9 10 13 10.9 13 12C13 13.1 13.9 14 15 14C16.1 14 17 13.1 17 12C17 10.9 16.1 10 15 10ZM15 16C13.9 16 13 16.9 13 18C13 19.1 13.9 20 15 20C16.1 20 17 19.1 17 18C17 16.9 16.1 16 15 16Z",fill:"#056739","fill-opacity":"0.5"})}),m.jsx("defs",{children:m.jsx("clipPath",{id:"clip0_5814_24904",children:m.jsx("rect",{width:"24",height:"24",fill:"white"})})})]});function dh({items:e,getId:t,onReorder:r,header:n,disabled:i,sx:a,getText:o,showIndex:s=!0,showLeftIcon:l=!0,renderItem:p,chipText:u,helperText:d}){const[f,y]=$.useState(null),[S,c]=$.useState(null),b=k=>x=>{if(!i){y(k),x.dataTransfer.effectAllowed="move";try{x.dataTransfer.setData("text/plain",String(t(e[k])))}catch{}}},g=k=>x=>{i||(x.preventDefault(),c(k),x.dataTransfer.dropEffect="move")},O=k=>x=>{if(i)return;if(x.preventDefault(),f===null||f===k){y(null),c(null);return}const B=[...e],[_]=B.splice(f,1);B.splice(k,0,_),y(null),c(null),r(B)},A=()=>{y(null),c(null)};return m.jsxs(E.Box,{role:"list",sx:k=>({display:"flex",flexDirection:"column",gap:k.spacing(1),...a}),children:[n,m.jsx(E.Divider,{sx:{mt:-.5,mb:1,dividerColor:"#EBEBEB"}}),e.map((k,x)=>{const B=f===x,_=S===x&&f!==null&&f!==x;return m.jsx(E.Box,{role:"listitem",draggable:!i,onDragStart:b(x),onDragOver:g(x),onDrop:O(x),onDragEnd:A,sx:K=>{var W;return{userSelect:"none",cursor:i?"default":"grab",backgroundColor:"#F8F8FA",border:`1px solid ${_?K.palette.primary.main:"#EBEBEB"}`,borderRadius:((W=K.shape)==null?void 0:W.borderRadius)||"8px",padding:K.spacing(1),opacity:B?.6:1,boxShadow:_?`0 0 0 2px ${K.palette.primary.main}33`:"none"}},children:p?p(k,B):m.jsxs(E.Box,{sx:K=>({display:"flex",alignItems:"center",gap:K.spacing(1),minWidth:0}),children:[l&&m.jsx(ph,{}),s&&m.jsxs(E.Typography,{variant:"body2",sx:K=>({fontWeight:600,fontSize:14,color:`${K.palette.text.primary}`,flex:"0 0 auto"}),children:[x+1,"."]}),(()=>{const K=typeof u=="function"?u(k,x):u;return K?m.jsx(E.Chip,{label:K,sx:{borderRadius:"4px",p:"12px 3px"},size:"small"}):null})(),m.jsx(E.Typography,{variant:"body2",sx:K=>({fontSize:12,fontWeight:500,color:`${K.palette.text.primary}90`,flex:1,minWidth:0,overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis"}),children:o?o(k):""})]})},String(t(k)))}),d?typeof d=="string"?m.jsx(E.Typography,{variant:"caption",sx:k=>({color:`${k.palette.text.primary}60`}),children:d}):d:null]})}const fh=ot(E.StepConnector)(()=>({[`&.${E.stepConnectorClasses.vertical}`]:{marginLeft:11},[`& .${E.stepConnectorClasses.line}`]:{minHeight:28,borderLeftWidth:2,borderColor:"#E8E8E8",transition:"border-color 0.3s ease"},[`&.${E.stepConnectorClasses.completed} .${E.stepConnectorClasses.line}`]:{borderColor:Q.primary.main}})),hh=({items:e,activeIndex:t=1,onStepClick:r,sx:n})=>{const i=a=>{const{active:o,completed:s,icon:l}=a;return s?m.jsx(E.Box,{sx:{width:24,height:24,border:`1.2px solid ${Q.primary.main}`,borderRadius:"50%",backgroundColor:Q.primary.main,color:"#fff",display:"flex",alignItems:"center",justifyContent:"center"},children:m.jsx(Ba,{sx:{fontSize:16,fontWeight:600}})}):o?m.jsx(E.Box,{sx:{width:24,height:24,borderRadius:"50%",border:`1.2px solid ${Q.primary.main}`,backgroundColor:Ft(Q.primary.main,.2),color:Q.primary.main,display:"flex",alignItems:"center",justifyContent:"center",fontWeight:500,fontSize:12},children:l}):m.jsx(E.Box,{sx:{width:24,height:24,borderRadius:"50%",backgroundColor:"#E8E8E8",color:Q.text.primary,display:"flex",alignItems:"center",justifyContent:"center",fontWeight:500,fontSize:12},children:l})};return m.jsx(E.Stepper,{orientation:"vertical",activeStep:t,connector:m.jsx(fh,{}),sx:{"& .MuiStepConnector-vertical":{my:-1.1},"& .MuiStepLabel-label":{fontSize:14,color:Q.text.primary,fontWeight:500},"& .MuiStep-root":{cursor:r?"pointer":"default"},...n},children:e.map((a,o)=>m.jsxs(E.Step,{onClick:()=>r==null?void 0:r(o),completed:o<t,children:[m.jsx(E.StepLabel,{StepIconComponent:i,children:m.jsx(E.Typography,{sx:{fontSize:12,fontWeight:500,color:o===t?Q.primary.main:Q.text.primary},children:a.label})}),o!==e.length-1&&m.jsx(E.Divider,{sx:{ml:4.2,borderColor:Q.divider}})]},o))})},zl=({colorKey:e="primary",colorHex:t,tone:r="soft",bgAlpha:n=.12,borderAlpha:i=.24,sx:a,...o})=>m.jsx(E.Chip,{...o,sx:s=>({fontWeight:600,borderRadius:"4px",height:18,border:`0.5px solid ${Ft(t||s.palette.text.primary,.5)}`,backgroundColor:Ft(t||s.palette.text.primary,.1),"& .MuiChip-label":{p:"8px",color:t||s.palette.text.primary,fontSize:10,fontWeight:500},...a})}),mh=ot(E.StepConnector)(()=>({[`&.${E.stepConnectorClasses.vertical}`]:{marginLeft:11},[`& .${E.stepConnectorClasses.line}`]:{minHeight:28,borderLeftWidth:2,height:"70px",borderColor:"#E8E8E8",transition:"border-color 0.3s ease",zIndex:-1},[`&.${E.stepConnectorClasses.completed} .${E.stepConnectorClasses.line}`]:{borderColor:Q.primary.main}})),gh=({items:e,activeIndex:t=1,onStepClick:r,sx:n})=>{const[i,a]=$.useState(null),o=s=>{const{active:l,completed:p,icon:u}=s;return p?m.jsx(E.Box,{sx:{width:24,height:24,border:`1.2px solid ${Q.primary.main}`,borderRadius:"50%",backgroundColor:Q.primary.main,color:"#fff",display:"flex",alignItems:"center",justifyContent:"center",zIndex:1e3},children:m.jsx(Ba,{sx:{fontSize:16,fontWeight:600}})}):l?m.jsx(E.Box,{sx:{width:24,height:24,borderRadius:"50%",border:`1.2px solid ${Q.primary.main}`,backgroundColor:Ft(Q.primary.main,.2),color:Q.primary.main,display:"flex",alignItems:"center",justifyContent:"center",fontWeight:500,fontSize:12,zIndex:1e3,overflow:"hidden"},children:u}):m.jsx(E.Box,{sx:{width:24,height:24,borderRadius:"50%",backgroundColor:"#E8E8E8",color:Q.text.primary,display:"flex",alignItems:"center",justifyContent:"center",fontWeight:500,fontSize:12,zIndex:1e3},children:u})};return m.jsx(E.Stepper,{orientation:"vertical",activeStep:t,connector:m.jsx(mh,{}),sx:{"& .MuiStepConnector-vertical":{my:-3.5},"& .MuiStepLabel-label":{fontSize:14,color:Q.text.primary,fontWeight:500},"& .MuiStep-root":{cursor:r?"pointer":"default"},...n},children:e.map((s,l)=>m.jsxs(E.Step,{onMouseEnter:()=>a(l),onMouseLeave:()=>a(null),onClick:()=>r==null?void 0:r(l),completed:l<t,children:[m.jsxs(E.Box,{sx:{display:"flex",justifyContent:"space-between",alignItems:"flex-start"},children:[m.jsxs(E.StepLabel,{StepIconComponent:o,children:[m.jsxs(E.Box,{sx:{display:"flex",gap:1,alignItems:"center"},children:[m.jsx(E.Typography,{sx:{fontSize:14,fontWeight:500,color:l===t?Q.primary.main:Q.text.primary},children:s.label}),m.jsx(zl,{size:"small",colorHex:l<t?Q.success.main:l===t?"#973B00":Q.text.primary,label:l<t?"Completed":l===t?"In progress":"Not started"})]}),m.jsx(E.Typography,{sx:{fontSize:12,fontWeight:400,color:`${Q.text.primary}60`,mt:.5,width:"80%"},children:s.description})]}),i===l&&m.jsx(E.Button,{sx:{display:l>t?"none":"block"},variant:l<t?"outlined":"contained",size:"small",color:"primary",children:l<t?"Edit":l===t?"Complete":""})]}),l!==e.length-1&&m.jsx(E.Divider,{sx:{ml:4.2,borderColor:Q.divider}})]},l))})},yh=vt(m.jsx("path",{d:"M11 7h2v2h-2zm0 4h2v6h-2zm1-9C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8"}),"InfoOutlined"),xh=({variant:e="list",title:t,subtitle:r,text:n,items:i=[],icon:a,colorHex:o,sx:s})=>{const l=o||Q.info.main,p=Ft(l,.08),u=Ft(l,.08),d=a??m.jsx(yh,{sx:{color:l,fontSize:18}});return e==="inlineInfo"?m.jsxs(E.Card,{sx:{p:1.5,display:"flex",alignItems:"center",gap:1,backgroundColor:p,border:`1px solid ${u}`,boxShadow:"none",...s},children:[m.jsx(E.Box,{sx:{display:"flex",alignItems:"center"},children:d}),m.jsx(E.Typography,{variant:"body2",sx:{fontWeight:400,fontSize:12,lineHeight:1.3,color:l},children:n})]}):e==="inline"?m.jsx(E.Card,{sx:{p:1.5,display:"flex",alignItems:"center",gap:1,backgroundColor:p,border:`1px solid ${u}`,boxShadow:"none",...s},children:m.jsx(E.Typography,{variant:"body2",sx:{fontWeight:400,fontSize:12,lineHeight:1.3,color:l},children:n})}):e==="listWithHeader"?m.jsxs(E.Card,{sx:{p:2,boxShadow:"none",borderRadius:"6px",backgroundColor:p,border:`1px solid ${u}`,...s},children:[m.jsxs(E.Box,{sx:{display:"flex",alignItems:"center",gap:1},children:[d,m.jsx(E.Typography,{variant:"subtitle2",sx:{fontWeight:600,color:l,fontSize:14,lineHeight:1.3},children:t})]}),r&&m.jsx(E.Typography,{variant:"body2",sx:{mt:.5,color:l,fontSize:10,lineHeight:1.3},children:r}),m.jsx(E.List,{sx:{pl:5,"& .MuiListItem-root":{display:"list-item",listStyleType:"disc",color:l},"& .MuiListItemText-primary":{fontSize:"12px",fontWeight:400,lineHeight:"18px",color:l,my:-.5}},children:i.map((f,y)=>m.jsx(E.ListItem,{sx:{py:0},children:m.jsx(E.ListItemText,{primary:f})},y))})]}):m.jsx(E.Card,{sx:{p:"11px",borderRadius:"8px",backgroundColor:p,border:`0.5px solid ${u}`,boxShadow:"none",...s},children:m.jsx(E.List,{sx:{pl:4,"& .MuiListItem-root":{display:"list-item",listStyleType:"disc",color:l},"& .MuiListItemText-primary":{fontSize:"12px",fontWeight:600,lineHeight:"18px",color:l,my:-.5}},children:i.map((f,y)=>m.jsx(E.ListItem,{sx:{py:0},children:m.jsx(E.ListItemText,{primary:f})},y))})})},vh=({value:e,onChange:t,items:r,ariaLabel:n,sx:i,tabSx:a})=>m.jsxs(E.Box,{children:[m.jsx(E.Tabs,{value:e,onChange:(o,s)=>t(s),"aria-label":n||"Fin tabs",sx:o=>({minHeight:"36px",borderRadius:"6px",p:.5,backgroundColor:o.palette.background.paper,boxShadow:"inset 0 0 0 1px "+o.palette.divider,"& .MuiTabs-flexContainer":{gap:.5},"& .MuiTabs-indicator":{display:"none"},...i}),children:r.map((o,s)=>{const l=typeof o.value=="string"||typeof o.value=="number"?o.value:s;return m.jsx(E.Tab,{value:l,disabled:o.disabled,label:m.jsx(E.Typography,{variant:"body2",children:o.label}),sx:p=>({minHeight:32,px:2,textTransform:"none",color:p.palette.text.secondary,borderRadius:"3px",border:"1px solid "+p.palette.divider,backgroundColor:p.palette.background.default,"&:hover":{backgroundColor:p.palette.action.hover},"&.Mui-selected":{color:p.palette.common.white,borderColor:p.palette.primary.main,backgroundColor:p.palette.primary.main,fontWeight:600},...a})},String(l))})}),r.map((o,s)=>{const l=typeof o.value=="string"||typeof o.value=="number"?o.value:s,p=o.content??(typeof o.value=="object"?o.value:null);return p&&e===l?m.jsx(E.Box,{sx:{mt:1},children:p},`panel-${l}`):null})]});async function Vl(e,t,r,n){try{const{endpoint:i,method:a="GET",valueField:o="value",labelField:s="label",headers:l={},params:p={},body:u,transform:d,passThroughFields:f}=e;let y=i;if(t&&!i.startsWith("http")&&(y=`${t}${i.startsWith("/")?i:`/${i}`}`),n){const k=/\{([^}]+)\}/g;y=y.replace(k,(x,B)=>{const _=n[B];return _!=null?encodeURIComponent(String(_)):""}),y=y.replace(/\?&/g,"?").replace(/&&/g,"&").replace(/\?$/g,"")}const S=new URLSearchParams;Object.entries(p).forEach(([k,x])=>{x!=null&&S.append(k,String(x))}),S.toString()&&(y+=`${y.includes("?")?"&":"?"}${S.toString()}`);try{const k=/^https?:\/\//i.test(y),x=new URL(y,k?void 0:"http://local.placeholder"),B=Array.from(x.searchParams.entries());for(const[_,K]of B)(K===""||K==="undefined"||K==="null")&&x.searchParams.delete(_);k?y=x.toString():y=x.pathname+(x.search?x.search:""),y=y.replace(/\?&/g,"?").replace(/&&/g,"&").replace(/\?$/g,"")}catch{}const c={"Content-Type":"application/json",...r,...l},b={method:a,headers:c};(a==="POST"||a==="PUT")&&u&&(b.body=JSON.stringify(u));const g=await fetch(y,b);if(!g.ok)throw new Error(`API request failed: ${g.status} ${g.statusText}`);const O=await g.json();if(d)return d(Array.isArray(O)?O:O.data||O);const A=Array.isArray(O)?O:O.data||O;if(!Array.isArray(A))throw new Error("API response is not an array");return A.map(k=>{const x={label:k[s]||k.name||k.title||String(k[o]||""),value:k[o]||k.id||k.value||""},B=Array.isArray(f)?f:void 0;if(Array.isArray(B))for(const _ of B)k[_]!==void 0&&(x[_]=k[_]);return x})}catch(i){throw console.error("API fetch error:",i),new Error(`Failed to fetch data: ${i instanceof Error?i.message:"Unknown error"}`)}}function Bl(e,t,r,n,i=!1){const a=$.useMemo(()=>{if(!(e!=null&&e.dependsOn)||!n)return null;const s=n[e.dependsOn];return s!==void 0?s:null},[e==null?void 0:e.dependsOn,n]),o=$.useMemo(()=>["api-data",e==null?void 0:e.endpoint,e==null?void 0:e.method,e==null?void 0:e.valueField,e==null?void 0:e.labelField,t,a,n?JSON.stringify(n):null],[e==null?void 0:e.endpoint,e==null?void 0:e.method,e==null?void 0:e.valueField,e==null?void 0:e.labelField,t,a,n]);return ku({queryKey:o,queryFn:()=>{if(!e)throw new Error("API config is required");return Vl(e,t,r,n)},enabled:i&&!!e,staleTime:15*60*1e3,gcTime:30*60*1e3,retry:3,retryDelay:s=>Math.min(1e3*2**s,3e4),refetchOnWindowFocus:!1,refetchOnReconnect:!0,refetchOnMount:!1})}function or(e){return!!(e.apiConfig||e.api_endpoint)}function La(e){return e.apiConfig?e.apiConfig:e.api_endpoint?{endpoint:e.api_endpoint,method:e.api_method||"GET",valueField:e.value_field||"value",labelField:e.label_field||"label",dependsOn:e.depends_on,conditional:e.conditional}:null}function bh(e,t){const r=La(e);if(!(r!=null&&r.conditional)&&!e.conditional)return!0;if(r!=null&&r.dependsOn||e.depends_on){const n=(r==null?void 0:r.dependsOn)||e.depends_on;if(n){const i=t[n];return i!=null&&i!==""}}return!0}const Nl=({field:e,control:t,errors:r,baseUrl:n,apiHeaders:i,formData:a,setValue:o})=>{const s=r[e.name],l=!!s,[p,u]=$.useState(!1),d=$.useRef(!1),[f,y]=$.useState(!1),[S,c]=$.useState(!1),[b,g]=$.useState(!1),O=$.useRef(null),A=$.useRef(null),k=()=>{var Y;return e.required!==void 0?e.required:((Y=e.validation)==null?void 0:Y.required)!==void 0?e.validation.required:!1},x=Y=>k()?`${Y} *`:Y,B=()=>e.value!==void 0?e.value:e.type==="checkbox"?!1:e.type==="select"&&e.default?e.default:e.type==="autocomplete"&&e.multiple?[]:"",_=$.useMemo(()=>{const Y=La(e);return Y&&Array.isArray(e.passThroughFields)&&(Y.passThroughFields=e.passThroughFields),Y},[e.apiConfig,e.api_endpoint,e.api_method,e.value_field,e.label_field,e.depends_on,e.conditional,e.passThroughFields]),K=$.useRef(null),W=_!=null&&_.dependsOn?a==null?void 0:a[_.dependsOn]:null,h=$.useMemo(()=>{if(!(_!=null&&_.dependsOn))return!1;const Y=W,te=K.current,le=Y!==te;return le&&(K.current=Y),le},[_==null?void 0:_.dependsOn,W]),M=$.useMemo(()=>!0,[]),P=$.useMemo(()=>p&&or(e)&&(!(_!=null&&_.dependsOn)||W),[p,e,_==null?void 0:_.dependsOn,W]),q=$.useMemo(()=>{const Y={};if(!a)return Y;const te=(_==null?void 0:_.endpoint)||(e==null?void 0:e.api_endpoint);if(te&&typeof te=="string"){const le=te.match(/\{([^}]+)\}/g)||[];for(const U of le){const ee=U.slice(1,-1),oe=a[ee];oe!==void 0&&(Y[ee]=oe)}}if(_!=null&&_.dependsOn){const le=_.dependsOn,U=a[le];U!==void 0&&(Y[le]=U)}return Y},[_==null?void 0:_.endpoint,e==null?void 0:e.api_endpoint,_==null?void 0:_.dependsOn,a]),{data:N=[],isLoading:X,error:ie}=Bl(_,n,i,q,P),ge=$.useCallback(()=>{or(e)&&!d.current&&(d.current=!0,u(!0))},[e]),ce=$.useCallback(()=>{or(e)&&!d.current&&(d.current=!0,u(!0))},[e]);$.useEffect(()=>{if(or(e)&&!d.current){const Y=a==null?void 0:a[e.name];Y!=null&&Y!==""&&(d.current=!0,u(!0))}},[e,a]),$.useEffect(()=>{or(e)&&(_!=null&&_.dependsOn)&&h&&d.current&&(d.current=!1,u(!1))},[h,_==null?void 0:_.dependsOn]);const se=$.useCallback(()=>or(e)?N:e.type==="select"||e.type==="toggle"||e.type==="radio"||e.type==="autocomplete"?e.options||[]:[],[e,N]);if(!M)return null;const V=()=>{switch(e.type){case"title":return m.jsx(E.Typography,{variant:e.variant||"h4",component:"h1",color:e.color,align:e.align||"left",sx:{mb:3,fontWeight:600,...e.sx},children:e.label});case"section":return m.jsx(E.Typography,{variant:e.variant||"h6",component:"h3",color:e.color,align:e.align||"left",sx:{mb:2,fontWeight:600,color:"text.primary",...e.sx},children:e.label});case"finuiHeader":return m.jsx(Ml,{title:e.title||e.label,subtitle:e.subtitle,actions:e.actions,align:e.align||"left",sx:e.sx});case"text":case"email":case"password":case"tel":case"textarea":return m.jsx(bt,{name:e.name,control:t,defaultValue:B(),render:({field:U})=>e.type==="textarea"?m.jsx(Il,{...U,labelText:e.labelPosition==="top"?x(e.label):void 0,label:e.labelPosition!=="top"?x(e.label):void 0,labelVariant:e.labelVariant,placeholder:e.placeholder,disabled:e.disabled,hasError:l,helperText:(s==null?void 0:s.message)||e.helperText}):m.jsx(sa,{...U,id:e.id,labelText:e.labelPosition==="top"?x(e.label):void 0,label:e.labelPosition!=="top"?x(e.label):void 0,endorsementText:e.endorsementText,endorsementBg:e.endorsementBg,endorsementColor:e.endorsementColor,endorsementRadius:e.endorsementRadius,endorsementHeight:e.endorsementHeight,endorsementPaddingX:e.endorsementPaddingX,labelVariant:e.labelVariant,type:e.type==="password"?f?"text":"password":e.type,placeholder:e.placeholder,disabled:e.disabled,hasError:l,helperText:(s==null?void 0:s.message)||e.helperText,InputProps:e.type==="password"?{endAdornment:m.jsx(kl,{position:"end",children:m.jsx(Ln,{"aria-label":"toggle password visibility",onClick:()=>y(ee=>!ee),edge:"end",children:f?m.jsx(is,{}):m.jsx(ns,{})})})}:void 0})});case"number":return m.jsx(bt,{name:e.name,control:t,defaultValue:B(),render:({field:U})=>m.jsx(sa,{...U,id:e.id,labelText:e.labelPosition==="top"?x(e.label):void 0,label:e.labelPosition!=="top"?x(e.label):void 0,endAdornment:e.endAdornment,endorsementText:e.endorsementText,endorsementBg:e.endorsementBg,endorsementColor:e.endorsementColor,endorsementRadius:e.endorsementRadius,endorsementHeight:e.endorsementHeight,endorsementPaddingX:e.endorsementPaddingX,labelVariant:e.labelVariant,type:"number",placeholder:e.placeholder,disabled:e.disabled,hasError:l,helperText:(s==null?void 0:s.message)||e.helperText,inputProps:{min:e.min,max:e.max}})});case"select":const Y=se();return m.jsx(bt,{name:e.name,control:t,defaultValue:B(),render:({field:U})=>m.jsx(Al,{labelText:e.labelPosition==="top"?x(e.label):void 0,label:e.labelPosition!=="top"&&e.labelPosition!=="none"?x(e.label):void 0,labelVariant:e.labelVariant,value:U.value,onChange:U.onChange,options:Y,disabled:e.disabled||X,placeholder:e.labelPosition==="inner"||e.labelPosition==="none"||!e.labelPosition?e.placeholder||(e.labelPosition==="none"?x(e.label):void 0):e.placeholder,loading:X,error:l||!!ie,helperText:(s==null?void 0:s.message)||(ie==null?void 0:ie.message)||e.helperText,onOpen:ge})});case"checkbox":return m.jsx(bt,{name:e.name,control:t,defaultValue:B(),render:({field:U})=>m.jsx($l,{label:x(e.label),checked:!!U.value,disabled:e.disabled,onChange:U.onChange})});case"toggle":return m.jsx(bt,{name:e.name,control:t,defaultValue:B(),render:({field:U})=>m.jsx(la,{label:x(e.label),labelPosition:e.labelPosition==="none"?"none":"top",labelVariant:e.labelVariant,value:U.value,options:e.options||[],row:!0,onChange:U.onChange})});case"radio":return m.jsx(bt,{name:e.name,control:t,defaultValue:B(),render:({field:U})=>m.jsx(la,{label:x(e.label),labelPosition:e.labelPosition==="none"?"none":"top",labelVariant:e.labelVariant,value:U.value,options:e.options||[],row:e.row===!0,groupPadding:e.groupPadding,itemGap:e.itemGap,helperText:e.helperText,onChange:U.onChange})});case"switch":return m.jsx(bt,{name:e.name,control:t,defaultValue:B(),render:({field:U})=>m.jsx(Dl,{label:x(e.label),checked:!!U.value,disabled:e.disabled,onChange:U.onChange})});case"autocomplete":const te=se(),le=!!(e.disabled||X||_!=null&&_.dependsOn&&!W);return m.jsx(bt,{name:e.name,control:t,defaultValue:B(),render:({field:U})=>{const ee=U.value,oe=e.multiple===!0,fe=(_==null?void 0:_.valueField)||e.value_field||"value",pe=(_==null?void 0:_.labelField)||e.label_field||"label",L=z=>{if(z!=null){if(typeof z=="string"||typeof z=="number")return z;if(typeof z=="object"){if(z[fe]!==void 0)return z[fe];if(z.value!==void 0)return z.value;if(z.id!==void 0)return z.id}}},I=(()=>{if(oe)return(Array.isArray(ee)?ee:[]).map(ae=>{const de=te.find(_e=>{const Te=L(_e);return Te!==void 0&&Te===ae});return de||{[fe]:ae,[pe]:`Selected: ${ae}`,value:ae,label:`Selected: ${ae}`}});{if(ee==null||ee==="")return null;const z=te.find(ae=>{const de=L(ae);return de!==void 0&&de===ee});return z||{[fe]:ee,[pe]:`Selected: ${ee}`,value:ee,label:`Selected: ${ee}`}}})();return m.jsx(Rl,{id:e.id,options:te,value:I,multiple:oe,labelText:e.labelPosition==="top"?x(e.label):void 0,label:e.labelPosition!=="top"?x(e.label):void 0,placeholder:le&&(_!=null&&_.dependsOn)&&!W?`Please select ${_.dependsOn.replace(/_/g," ")} first`:e.placeholder,labelVariant:e.labelVariant,disabled:le,loading:X,error:l||!!ie,helperText:(s==null?void 0:s.message)||(ie==null?void 0:ie.message)||e.helperText||"",onOpen:ce,noOptionsText:le&&(_!=null&&_.dependsOn)&&!W?`Please select ${_.dependsOn.replace(/_/g," ")} first`:X?"Fetching data...":p&&!X&&te.length===0?"No options available":"Click to load options",onChange:z=>{const ae=(_==null?void 0:_.valueField)||e.value_field||"value";if(oe){const _e=(Array.isArray(z)?z:[]).map(Te=>typeof Te=="object"&&(Te[ae]||Te.value||Te.id)||Te);U.onChange(_e)}else{let de;z&&typeof z=="object"?de=z[ae]||z.value||z.id||z:de=z,U.onChange(de);const _e=e.selectedAssignments;if(_e&&z&&typeof z=="object")for(const[Te,Qe]of Object.entries(_e)){const Ye=z[Qe];if(Ye!==void 0&&typeof o=="function")try{o(Te,Ye,{shouldDirty:!0,shouldTouch:!0,shouldValidate:!1})}catch{}}}}})}});case"date":return m.jsx(bt,{name:e.name,control:t,defaultValue:B(),render:({field:U})=>m.jsx(Pl,{...U,id:e.name,label:x(e.label),labelPosition:e.labelPosition||"inner",labelVariant:e.labelVariant,disabled:e.disabled,error:l,helperText:s==null?void 0:s.message,inputProps:{min:e.minDate,max:e.maxDate}})});case"image":return m.jsx(bt,{name:e.name,control:t,defaultValue:B(),render:({field:U})=>{const ee=U.value||e.defaultValue||e.src;if(ee){const z=e.imageUploaded||{},ae=z.previewText||"Preview",de=z.removeText||"Remove",_e=z.saveText||"Save logo",Te=z.showSave!==void 0?z.showSave:!!(e.onSave||z.saveText),Qe=()=>{if(g(!0),typeof e.onPreview=="function")try{e.onPreview(ee)}catch{}},Ye=()=>{U.onChange(""),typeof e.onRemove=="function"&&e.onRemove()},v=()=>{typeof e.onSave=="function"&&e.onSave({url:ee,file:A.current||void 0})},j=T=>{const G=T.target.files&&T.target.files[0];if(G){if(typeof e.onFileSelected=="function")try{e.onFileSelected(G)}catch{}try{const F=URL.createObjectURL(G);U.onChange(F)}catch{}A.current=G,g(!1)}};return m.jsxs(E.Card,{sx:{display:"flex",alignItems:"center",gap:2,p:2,boxShadow:"0px 1px 4px 0px #00000014",...z.cardSx},children:[m.jsx("input",{type:"file",ref:O,accept:Array.isArray(e.accept)?e.accept.join(","):e.accept||"image/*",style:{display:"none"},onChange:j}),m.jsxs(E.Box,{sx:{display:"flex",flexDirection:"column",gap:1},children:[m.jsx(E.Box,{sx:{width:"30%",height:"10%",display:"flex",alignItems:"center",justifyContent:"center",borderRadius:"6px",background:"#FFFFFF",overflow:"hidden",...z.thumbnailSx},children:m.jsx("img",{src:ee,alt:e.alt||e.label,style:{maxWidth:"100%",maxHeight:"100%"}})}),m.jsxs(E.Box,{sx:{flexGrow:1},children:[m.jsx(E.Typography,{sx:{fontSize:"12px",fontWeight:500,...z.fileNameSx},children:typeof ee=="string"?ee.split("/").pop():"Selected image"}),m.jsx(E.Typography,{sx:{fontSize:"10px",...z.fileMetaSx},children:"Image selected"})]}),m.jsxs(E.Box,{sx:{display:"flex",gap:1},children:[m.jsx(E.Button,{type:"button",sx:{...z.previewButtonSx},variant:"outlined",onClick:Qe,startIcon:m.jsx(ns,{}),children:ae}),m.jsx(E.Button,{variant:"outlined",color:"error",onClick:Ye,sx:{...z.removeButtonSx},startIcon:m.jsx(is,{}),children:de}),Te&&m.jsx(E.Button,{variant:"contained",onClick:v,sx:{...z.saveButtonSx},children:_e})]})]}),m.jsxs(E.Dialog,{open:b,onClose:()=>g(!1),maxWidth:"md",fullWidth:!0,children:[m.jsx(E.DialogTitle,{children:z.previewTitle||"Image preview"}),m.jsx(E.DialogContent,{children:m.jsx(E.Box,{sx:{display:"flex",alignItems:"center",justifyContent:"center",borderRadius:"8px",border:"1px solid",borderColor:"divider",backgroundColor:"background.paper",p:1,minHeight:260},children:m.jsx("img",{src:ee,alt:e.alt||e.label,style:{maxWidth:"100%",maxHeight:380}})})}),m.jsxs(E.DialogActions,{children:[m.jsx(E.Button,{type:"button",variant:"outlined",onClick:()=>{var T;return(T=O.current)==null?void 0:T.click()},children:z.replaceText||"Replace logo"}),m.jsx(E.Button,{type:"button",variant:"contained",onClick:()=>g(!1),children:z.closeText||"Close"})]})]})]})}const oe=e.imagePlaceholder||{},fe=oe.icon||"upload",pe=O,L=()=>{var z;try{(z=pe.current)==null||z.click()}catch{}},I=z=>{const ae=z.target.files&&z.target.files[0];if(ae){typeof e.onFileSelected=="function"&&e.onFileSelected(ae);try{const de=URL.createObjectURL(ae);U.onChange(de)}catch{}A.current=ae}};return m.jsxs(E.Card,{sx:{border:"1px dashed",borderColor:"#CCCCCC",boxShadow:"none",p:2,textAlign:"center",color:"primary.main",...oe.sx},children:[m.jsx("input",{type:"file",ref:pe,accept:Array.isArray(e.accept)?e.accept.join(","):e.accept||"image/*",style:{display:"none"},onChange:I}),m.jsx(Ln,{sx:{borderRadius:"8px",...oe.iconSx},children:fe==="image"?m.jsx(ah,{sx:{width:36,height:36,color:"primary.main"}}):m.jsx(ni,{sx:{width:36,height:36,color:"primary.main"}})}),m.jsx(E.Typography,{sx:{fontSize:"16px",fontWeight:600,color:"primary.main",...oe.titleSx},children:oe.title||"Drag & Drop the image here"}),m.jsx(E.Typography,{sx:{fontSize:"12px",fontWeight:400,color:"primary.main",...oe.subtitleSx},children:oe.subtitle||""}),m.jsx(E.Button,{onClick:L,sx:{my:2,...oe.buttonSx},startIcon:m.jsx(ni,{}),variant:"contained",disabled:e.disabled,children:oe.buttonText||"Upload File"}),m.jsx(E.Typography,{sx:{fontSize:"12px",fontWeight:400,...oe.helperTextSx},children:oe.helperText||e.helperText||""})]})}});case"component":return m.jsx(E.Box,{children:e.render?e.render():e.content});default:return null}},H=$.useMemo(()=>!e.disabled||e.copyWhenDisabled===!1?!1:!["title","section","image","component"].includes(e.type),[e.disabled,e.copyWhenDisabled,e.type]),ue=$.useCallback(async()=>{try{const Y=a?a[e.name]:void 0;let te="";Y==null?te="":Array.isArray(Y)?te=Y.join(", "):typeof Y=="object"?te=JSON.stringify(Y):te=String(Y),await navigator.clipboard.writeText(te),c(!0),window.setTimeout(()=>c(!1),1200)}catch{}},[a,e.name]);return m.jsxs(E.Box,{sx:{display:"flex",alignItems:"center",gap:.3},children:[m.jsx(E.Box,{sx:{flexGrow:1},children:V()}),H&&m.jsx(Ln,{"aria-label":`copy ${e.label||e.name}`,onClick:ue,size:"small",children:S?m.jsx(Ba,{fontSize:"small"}):m.jsx(ih,{fontSize:"small"})})]})};var $i,os;function wh(){if(os)return $i;os=1;function e(g){this._maxSize=g,this.clear()}e.prototype.clear=function(){this._size=0,this._values=Object.create(null)},e.prototype.get=function(g){return this._values[g]},e.prototype.set=function(g,O){return this._size>=this._maxSize&&this.clear(),g in this._values||this._size++,this._values[g]=O};var t=/[^.^\]^[]+|(?=\[\]|\.\.)/g,r=/^\d+$/,n=/^\d/,i=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,a=/^\s*(['"]?)(.*?)(\1)\s*$/,o=512,s=new e(o),l=new e(o),p=new e(o);$i={Cache:e,split:d,normalizePath:u,setter:function(g){var O=u(g);return l.get(g)||l.set(g,function(k,x){for(var B=0,_=O.length,K=k;B<_-1;){var W=O[B];if(W==="__proto__"||W==="constructor"||W==="prototype")return k;K=K[O[B++]]}K[O[B]]=x})},getter:function(g,O){var A=u(g);return p.get(g)||p.set(g,function(x){for(var B=0,_=A.length;B<_;)if(x!=null||!O)x=x[A[B++]];else return;return x})},join:function(g){return g.reduce(function(O,A){return O+(y(A)||r.test(A)?"["+A+"]":(O?".":"")+A)},"")},forEach:function(g,O,A){f(Array.isArray(g)?g:d(g),O,A)}};function u(g){return s.get(g)||s.set(g,d(g).map(function(O){return O.replace(a,"$2")}))}function d(g){return g.match(t)||[""]}function f(g,O,A){var k=g.length,x,B,_,K;for(B=0;B<k;B++)x=g[B],x&&(b(x)&&(x='"'+x+'"'),K=y(x),_=!K&&/^\d+$/.test(x),O.call(A,x,K,_,B,g))}function y(g){return typeof g=="string"&&g&&["'",'"'].indexOf(g.charAt(0))!==-1}function S(g){return g.match(n)&&!g.match(r)}function c(g){return i.test(g)}function b(g){return!y(g)&&(S(g)||c(g))}return $i}var vr=wh(),Di,ss;function Sh(){if(ss)return Di;ss=1;const e=/[A-Z\xc0-\xd6\xd8-\xde]?[a-z\xdf-\xf6\xf8-\xff]+(?:['’](?:d|ll|m|re|s|t|ve))?(?=[\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000]|[A-Z\xc0-\xd6\xd8-\xde]|$)|(?:[A-Z\xc0-\xd6\xd8-\xde]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])+(?:['’](?:D|LL|M|RE|S|T|VE))?(?=[\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000]|[A-Z\xc0-\xd6\xd8-\xde](?:[a-z\xdf-\xf6\xf8-\xff]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])|$)|[A-Z\xc0-\xd6\xd8-\xde]?(?:[a-z\xdf-\xf6\xf8-\xff]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])+(?:['’](?:d|ll|m|re|s|t|ve))?|[A-Z\xc0-\xd6\xd8-\xde]+(?:['’](?:D|LL|M|RE|S|T|VE))?|\d*(?:1ST|2ND|3RD|(?![123])\dTH)(?=\b|[a-z_])|\d*(?:1st|2nd|3rd|(?![123])\dth)(?=\b|[A-Z_])|\d+|(?:[\u2700-\u27bf]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff])[\ufe0e\ufe0f]?(?:[\u0300-\u036f\ufe20-\ufe2f\u20d0-\u20ff]|\ud83c[\udffb-\udfff])?(?:\u200d(?:[^\ud800-\udfff]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff])[\ufe0e\ufe0f]?(?:[\u0300-\u036f\ufe20-\ufe2f\u20d0-\u20ff]|\ud83c[\udffb-\udfff])?)*/g,t=u=>u.match(e)||[],r=u=>u[0].toUpperCase()+u.slice(1),n=(u,d)=>t(u).join(d).toLowerCase(),i=u=>t(u).reduce((d,f)=>`${d}${d?f[0].toUpperCase()+f.slice(1).toLowerCase():f.toLowerCase()}`,"");return Di={words:t,upperFirst:r,camelCase:i,pascalCase:u=>r(i(u)),snakeCase:u=>n(u,"_"),kebabCase:u=>n(u,"-"),sentenceCase:u=>r(n(u," ")),titleCase:u=>t(u).map(r).join(" ")},Di}var Pi=Sh(),Pn={exports:{}},ls;function Ch(){if(ls)return Pn.exports;ls=1,Pn.exports=function(i){return e(t(i),i)},Pn.exports.array=e;function e(i,a){var o=i.length,s=new Array(o),l={},p=o,u=r(a),d=n(i);for(a.forEach(function(y){if(!d.has(y[0])||!d.has(y[1]))throw new Error("Unknown node. There is an unknown node in the supplied edges.")});p--;)l[p]||f(i[p],p,new Set);return s;function f(y,S,c){if(c.has(y)){var b;try{b=", node was:"+JSON.stringify(y)}catch{b=""}throw new Error("Cyclic dependency"+b)}if(!d.has(y))throw new Error("Found unknown node. Make sure to provided all involved nodes. Unknown node: "+JSON.stringify(y));if(!l[S]){l[S]=!0;var g=u.get(y)||new Set;if(g=Array.from(g),S=g.length){c.add(y);do{var O=g[--S];f(O,d.get(O),c)}while(S);c.delete(y)}s[--o]=y}}}function t(i){for(var a=new Set,o=0,s=i.length;o<s;o++){var l=i[o];a.add(l[0]),a.add(l[1])}return Array.from(a)}function r(i){for(var a=new Map,o=0,s=i.length;o<s;o++){var l=i[o];a.has(l[0])||a.set(l[0],new Set),a.has(l[1])||a.set(l[1],new Set),a.get(l[0]).add(l[1])}return a}function n(i){for(var a=new Map,o=0,s=i.length;o<s;o++)a.set(i[o],o);return a}return Pn.exports}var Eh=Ch();const kh=Oa(Eh),Th=Object.prototype.toString,Oh=Error.prototype.toString,jh=RegExp.prototype.toString,Fh=typeof Symbol<"u"?Symbol.prototype.toString:()=>"",_h=/^Symbol\((.*)\)(.*)$/;function Ah(e){return e!=+e?"NaN":e===0&&1/e<0?"-0":""+e}function cs(e,t=!1){if(e==null||e===!0||e===!1)return""+e;const r=typeof e;if(r==="number")return Ah(e);if(r==="string")return t?`"${e}"`:e;if(r==="function")return"[Function "+(e.name||"anonymous")+"]";if(r==="symbol")return Fh.call(e).replace(_h,"Symbol($1)");const n=Th.call(e).slice(8,-1);return n==="Date"?isNaN(e.getTime())?""+e:e.toISOString(e):n==="Error"||e instanceof Error?"["+Oh.call(e)+"]":n==="RegExp"?jh.call(e):null}function Jt(e,t){let r=cs(e,t);return r!==null?r:JSON.stringify(e,function(n,i){let a=cs(this[n],t);return a!==null?a:i},2)}function Ll(e){return e==null?[]:[].concat(e)}let ql,Ul,Wl,Rh=/\$\{\s*(\w+)\s*\}/g;ql=Symbol.toStringTag;class us{constructor(t,r,n,i){this.name=void 0,this.message=void 0,this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=void 0,this.inner=void 0,this[ql]="Error",this.name="ValidationError",this.value=r,this.path=n,this.type=i,this.errors=[],this.inner=[],Ll(t).forEach(a=>{if(et.isError(a)){this.errors.push(...a.errors);const o=a.inner.length?a.inner:[a];this.inner.push(...o)}else this.errors.push(a)}),this.message=this.errors.length>1?`${this.errors.length} errors occurred`:this.errors[0]}}Ul=Symbol.hasInstance;Wl=Symbol.toStringTag;class et extends Error{static formatError(t,r){const n=r.label||r.path||"this";return r=Object.assign({},r,{path:n,originalPath:r.path}),typeof t=="string"?t.replace(Rh,(i,a)=>Jt(r[a])):typeof t=="function"?t(r):t}static isError(t){return t&&t.name==="ValidationError"}constructor(t,r,n,i,a){const o=new us(t,r,n,i);if(a)return o;super(),this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=[],this.inner=[],this[Wl]="Error",this.name=o.name,this.message=o.message,this.type=o.type,this.value=o.value,this.path=o.path,this.errors=o.errors,this.inner=o.inner,Error.captureStackTrace&&Error.captureStackTrace(this,et)}static[Ul](t){return us[Symbol.hasInstance](t)||super[Symbol.hasInstance](t)}}let Ct={default:"${path} is invalid",required:"${path} is a required field",defined:"${path} must be defined",notNull:"${path} cannot be null",oneOf:"${path} must be one of the following values: ${values}",notOneOf:"${path} must not be one of the following values: ${values}",notType:({path:e,type:t,value:r,originalValue:n})=>{const i=n!=null&&n!==r?` (cast from the value \`${Jt(n,!0)}\`).`:".";return t!=="mixed"?`${e} must be a \`${t}\` type, but the final value was: \`${Jt(r,!0)}\``+i:`${e} must match the configured type. The validated value was: \`${Jt(r,!0)}\``+i}},Ge={length:"${path} must be exactly ${length} characters",min:"${path} must be at least ${min} characters",max:"${path} must be at most ${max} characters",matches:'${path} must match the following: "${regex}"',email:"${path} must be a valid email",url:"${path} must be a valid URL",uuid:"${path} must be a valid UUID",datetime:"${path} must be a valid ISO date-time",datetime_precision:"${path} must be a valid ISO date-time with a sub-second precision of exactly ${precision} digits",datetime_offset:'${path} must be a valid ISO date-time with UTC "Z" timezone',trim:"${path} must be a trimmed string",lowercase:"${path} must be a lowercase string",uppercase:"${path} must be a upper case string"},Nt={min:"${path} must be greater than or equal to ${min}",max:"${path} must be less than or equal to ${max}",lessThan:"${path} must be less than ${less}",moreThan:"${path} must be greater than ${more}",positive:"${path} must be a positive number",negative:"${path} must be a negative number",integer:"${path} must be an integer"},ca={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"},ua={isValue:"${path} field must be ${value}"},qn={noUnknown:"${path} field has unspecified keys: ${unknown}",exact:"${path} object contains unknown properties: ${properties}"},$h={min:"${path} field must have at least ${min} items",max:"${path} field must have less than or equal to ${max} items",length:"${path} must have ${length} items"},Dh={notType:e=>{const{path:t,value:r,spec:n}=e,i=n.types.length;if(Array.isArray(r)){if(r.length<i)return`${t} tuple value has too few items, expected a length of ${i} but got ${r.length} for value: \`${Jt(r,!0)}\``;if(r.length>i)return`${t} tuple value has too many items, expected a length of ${i} but got ${r.length} for value: \`${Jt(r,!0)}\``}return et.formatError(Ct.notType,e)}};Object.assign(Object.create(null),{mixed:Ct,string:Ge,number:Nt,date:ca,object:qn,array:$h,boolean:ua,tuple:Dh});const qa=e=>e&&e.__isYupSchema__;class ii{static fromOptions(t,r){if(!r.then&&!r.otherwise)throw new TypeError("either `then:` or `otherwise:` is required for `when()` conditions");let{is:n,then:i,otherwise:a}=r,o=typeof n=="function"?n:(...s)=>s.every(l=>l===n);return new ii(t,(s,l)=>{var p;let u=o(...s)?i:a;return(p=u==null?void 0:u(l))!=null?p:l})}constructor(t,r){this.fn=void 0,this.refs=t,this.refs=t,this.fn=r}resolve(t,r){let n=this.refs.map(a=>a.getValue(r==null?void 0:r.value,r==null?void 0:r.parent,r==null?void 0:r.context)),i=this.fn(n,t,r);if(i===void 0||i===t)return t;if(!qa(i))throw new TypeError("conditions must return a schema object");return i.resolve(r)}}const In={context:"$",value:"."};class kr{constructor(t,r={}){if(this.key=void 0,this.isContext=void 0,this.isValue=void 0,this.isSibling=void 0,this.path=void 0,this.getter=void 0,this.map=void 0,typeof t!="string")throw new TypeError("ref must be a string, got: "+t);if(this.key=t.trim(),t==="")throw new TypeError("ref must be a non-empty string");this.isContext=this.key[0]===In.context,this.isValue=this.key[0]===In.value,this.isSibling=!this.isContext&&!this.isValue;let n=this.isContext?In.context:this.isValue?In.value:"";this.path=this.key.slice(n.length),this.getter=this.path&&vr.getter(this.path,!0),this.map=r.map}getValue(t,r,n){let i=this.isContext?n:this.isValue?t:r;return this.getter&&(i=this.getter(i||{})),this.map&&(i=this.map(i)),i}cast(t,r){return this.getValue(t,r==null?void 0:r.parent,r==null?void 0:r.context)}resolve(){return this}describe(){return{type:"ref",key:this.key}}toString(){return`Ref(${this.key})`}static isRef(t){return t&&t.__isYupRef}}kr.prototype.__isYupRef=!0;const xt=e=>e==null;function Pr(e){function t({value:r,path:n="",options:i,originalValue:a,schema:o},s,l){const{name:p,test:u,params:d,message:f,skipAbsent:y}=e;let{parent:S,context:c,abortEarly:b=o.spec.abortEarly,disableStackTrace:g=o.spec.disableStackTrace}=i;function O(M){return kr.isRef(M)?M.getValue(r,S,c):M}function A(M={}){const P=Object.assign({value:r,originalValue:a,label:o.spec.label,path:M.path||n,spec:o.spec,disableStackTrace:M.disableStackTrace||g},d,M.params);for(const N of Object.keys(P))P[N]=O(P[N]);const q=new et(et.formatError(M.message||f,P),r,P.path,M.type||p,P.disableStackTrace);return q.params=P,q}const k=b?s:l;let x={path:n,parent:S,type:p,from:i.from,createError:A,resolve:O,options:i,originalValue:a,schema:o};const B=M=>{et.isError(M)?k(M):M?l(null):k(A())},_=M=>{et.isError(M)?k(M):s(M)};if(y&&xt(r))return B(!0);let W;try{var h;if(W=u.call(x,r,x),typeof((h=W)==null?void 0:h.then)=="function"){if(i.sync)throw new Error(`Validation test of type: "${x.type}" returned a Promise during a synchronous validate. This test will finish after the validate call has returned`);return Promise.resolve(W).then(B,_)}}catch(M){_(M);return}B(W)}return t.OPTIONS=e,t}function Ph(e,t,r,n=r){let i,a,o;return t?(vr.forEach(t,(s,l,p)=>{let u=l?s.slice(1,s.length-1):s;e=e.resolve({context:n,parent:i,value:r});let d=e.type==="tuple",f=p?parseInt(u,10):0;if(e.innerType||d){if(d&&!p)throw new Error(`Yup.reach cannot implicitly index into a tuple type. the path part "${o}" must contain an index to the tuple element, e.g. "${o}[0]"`);if(r&&f>=r.length)throw new Error(`Yup.reach cannot resolve an array item at index: ${s}, in the path: ${t}. because there is no value at that index. `);i=r,r=r&&r[f],e=d?e.spec.types[f]:e.innerType}if(!p){if(!e.fields||!e.fields[u])throw new Error(`The schema does not contain the path: ${t}. (failed at: ${o} which is a type: "${e.type}")`);i=r,r=r&&r[u],e=e.fields[u]}a=u,o=l?"["+s+"]":"."+s}),{schema:e,parent:i,parentPath:a}):{parent:i,parentPath:t,schema:e}}class ai extends Set{describe(){const t=[];for(const r of this.values())t.push(kr.isRef(r)?r.describe():r);return t}resolveAll(t){let r=[];for(const n of this.values())r.push(t(n));return r}clone(){return new ai(this.values())}merge(t,r){const n=this.clone();return t.forEach(i=>n.add(i)),r.forEach(i=>n.delete(i)),n}}function Ir(e,t=new Map){if(qa(e)||!e||typeof e!="object")return e;if(t.has(e))return t.get(e);let r;if(e instanceof Date)r=new Date(e.getTime()),t.set(e,r);else if(e instanceof RegExp)r=new RegExp(e),t.set(e,r);else if(Array.isArray(e)){r=new Array(e.length),t.set(e,r);for(let n=0;n<e.length;n++)r[n]=Ir(e[n],t)}else if(e instanceof Map){r=new Map,t.set(e,r);for(const[n,i]of e.entries())r.set(n,Ir(i,t))}else if(e instanceof Set){r=new Set,t.set(e,r);for(const n of e)r.add(Ir(n,t))}else if(e instanceof Object){r={},t.set(e,r);for(const[n,i]of Object.entries(e))r[n]=Ir(i,t)}else throw Error(`Unable to clone ${e}`);return r}class at{constructor(t){this.type=void 0,this.deps=[],this.tests=void 0,this.transforms=void 0,this.conditions=[],this._mutate=void 0,this.internalTests={},this._whitelist=new ai,this._blacklist=new ai,this.exclusiveTests=Object.create(null),this._typeCheck=void 0,this.spec=void 0,this.tests=[],this.transforms=[],this.withMutation(()=>{this.typeError(Ct.notType)}),this.type=t.type,this._typeCheck=t.check,this.spec=Object.assign({strip:!1,strict:!1,abortEarly:!0,recursive:!0,disableStackTrace:!1,nullable:!1,optional:!0,coerce:!0},t==null?void 0:t.spec),this.withMutation(r=>{r.nonNullable()})}get _type(){return this.type}clone(t){if(this._mutate)return t&&Object.assign(this.spec,t),this;const r=Object.create(Object.getPrototypeOf(this));return r.type=this.type,r._typeCheck=this._typeCheck,r._whitelist=this._whitelist.clone(),r._blacklist=this._blacklist.clone(),r.internalTests=Object.assign({},this.internalTests),r.exclusiveTests=Object.assign({},this.exclusiveTests),r.deps=[...this.deps],r.conditions=[...this.conditions],r.tests=[...this.tests],r.transforms=[...this.transforms],r.spec=Ir(Object.assign({},this.spec,t)),r}label(t){let r=this.clone();return r.spec.label=t,r}meta(...t){if(t.length===0)return this.spec.meta;let r=this.clone();return r.spec.meta=Object.assign(r.spec.meta||{},t[0]),r}withMutation(t){let r=this._mutate;this._mutate=!0;let n=t(this);return this._mutate=r,n}concat(t){if(!t||t===this)return this;if(t.type!==this.type&&this.type!=="mixed")throw new TypeError(`You cannot \`concat()\` schema's of different types: ${this.type} and ${t.type}`);let r=this,n=t.clone();const i=Object.assign({},r.spec,n.spec);return n.spec=i,n.internalTests=Object.assign({},r.internalTests,n.internalTests),n._whitelist=r._whitelist.merge(t._whitelist,t._blacklist),n._blacklist=r._blacklist.merge(t._blacklist,t._whitelist),n.tests=r.tests,n.exclusiveTests=r.exclusiveTests,n.withMutation(a=>{t.tests.forEach(o=>{a.test(o.OPTIONS)})}),n.transforms=[...r.transforms,...n.transforms],n}isType(t){return t==null?!!(this.spec.nullable&&t===null||this.spec.optional&&t===void 0):this._typeCheck(t)}resolve(t){let r=this;if(r.conditions.length){let n=r.conditions;r=r.clone(),r.conditions=[],r=n.reduce((i,a)=>a.resolve(i,t),r),r=r.resolve(t)}return r}resolveOptions(t){var r,n,i,a;return Object.assign({},t,{from:t.from||[],strict:(r=t.strict)!=null?r:this.spec.strict,abortEarly:(n=t.abortEarly)!=null?n:this.spec.abortEarly,recursive:(i=t.recursive)!=null?i:this.spec.recursive,disableStackTrace:(a=t.disableStackTrace)!=null?a:this.spec.disableStackTrace})}cast(t,r={}){let n=this.resolve(Object.assign({value:t},r)),i=r.assert==="ignore-optionality",a=n._cast(t,r);if(r.assert!==!1&&!n.isType(a)){if(i&&xt(a))return a;let o=Jt(t),s=Jt(a);throw new TypeError(`The value of ${r.path||"field"} could not be cast to a value that satisfies the schema type: "${n.type}".
175
+ `:null,Gf=e=>{const{classes:t,variant:r,color:n,disableShrink:i}=e,a={root:["root",r,`color${Re(n)}`],svg:["svg"],circle:["circle",`circle${Re(r)}`,i&&"circleDisableShrink"]};return Xr(a,Kf,t)},Zf=ot("span",{name:"MuiCircularProgress",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,t[r.variant],t[`color${Re(r.color)}`]]}})(wr(({theme:e})=>({display:"inline-block",variants:[{props:{variant:"determinate"},style:{transition:e.transitions.create("transform")}},{props:{variant:"indeterminate"},style:Qf||{animation:`${aa} 1.4s linear infinite`}},...Object.entries(e.palette).filter(ei()).map(([t])=>({props:{color:t},style:{color:(e.vars||e).palette[t].main}}))]}))),Xf=ot("svg",{name:"MuiCircularProgress",slot:"Svg"})({display:"block"}),Jf=ot("circle",{name:"MuiCircularProgress",slot:"Circle",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.circle,t[`circle${Re(r.variant)}`],r.disableShrink&&t.circleDisableShrink]}})(wr(({theme:e})=>({stroke:"currentColor",variants:[{props:{variant:"determinate"},style:{transition:e.transitions.create("stroke-dashoffset")}},{props:{variant:"indeterminate"},style:{strokeDasharray:"80px, 200px",strokeDashoffset:0}},{props:({ownerState:t})=>t.variant==="indeterminate"&&!t.disableShrink,style:Yf||{animation:`${oa} 1.4s ease-in-out infinite`}}]}))),$l=te.forwardRef(function(t,r){const n=Er({props:t,name:"MuiCircularProgress"}),{className:i,color:a="primary",disableShrink:o=!1,size:s=40,style:l,thickness:p=3.6,value:u=0,variant:d="indeterminate",...f}=n,g={...n,color:a,disableShrink:o,size:s,thickness:p,value:u,variant:d},S=Gf(g),c={},b={},y={};if(d==="determinate"){const j=2*Math.PI*((Vt-p)/2);c.strokeDasharray=j.toFixed(3),y["aria-valuenow"]=Math.round(u),c.strokeDashoffset=`${((100-u)/100*j).toFixed(3)}px`,b.transform="rotate(-90deg)"}return m.jsx(Zf,{className:Ye(S.root,i),style:{width:s,height:s,...b,...l},ownerState:g,ref:r,role:"progressbar",...y,...f,children:m.jsx(Xf,{className:S.svg,ownerState:g,viewBox:`${Vt/2} ${Vt/2} ${Vt} ${Vt}`,children:m.jsx(Jf,{className:S.circle,style:c,ownerState:g,cx:Vt,cy:Vt,r:(Vt-p)/2,fill:"none",strokeWidth:p})})})});process.env.NODE_ENV!=="production"&&($l.propTypes={classes:w.object,className:w.string,color:w.oneOfType([w.oneOf(["inherit","primary","secondary","error","info","success","warning"]),w.string]),disableShrink:Va(w.bool,e=>e.disableShrink&&e.variant&&e.variant!=="indeterminate"?new Error("MUI: You have provided the `disableShrink` prop with a variant other than `indeterminate`. This will have no effect."):null),size:w.oneOfType([w.number,w.string]),style:w.object,sx:w.oneOfType([w.arrayOf(w.oneOfType([w.func,w.object,w.bool])),w.func,w.object]),thickness:w.number,value:w.number,variant:w.oneOf(["determinate","indeterminate"])});function eh(e){return nr("MuiIconButton",e)}const as=Cr("MuiIconButton",["root","disabled","colorInherit","colorPrimary","colorSecondary","colorError","colorInfo","colorSuccess","colorWarning","edgeStart","edgeEnd","sizeSmall","sizeMedium","sizeLarge","loading","loadingIndicator","loadingWrapper"]),th=e=>{const{classes:t,disabled:r,color:n,edge:i,size:a,loading:o}=e,s={root:["root",o&&"loading",r&&"disabled",n!=="default"&&`color${Re(n)}`,i&&`edge${Re(i)}`,`size${Re(a)}`],loadingIndicator:["loadingIndicator"],loadingWrapper:["loadingWrapper"]};return Xr(s,eh,t)},rh=ot(Rl,{name:"MuiIconButton",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,r.loading&&t.loading,r.color!=="default"&&t[`color${Re(r.color)}`],r.edge&&t[`edge${Re(r.edge)}`],t[`size${Re(r.size)}`]]}})(wr(({theme:e})=>({textAlign:"center",flex:"0 0 auto",fontSize:e.typography.pxToRem(24),padding:8,borderRadius:"50%",color:(e.vars||e).palette.action.active,transition:e.transitions.create("background-color",{duration:e.transitions.duration.shortest}),variants:[{props:t=>!t.disableRipple,style:{"--IconButton-hoverBg":e.vars?`rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.hoverOpacity})`:Ft(e.palette.action.active,e.palette.action.hoverOpacity),"&:hover":{backgroundColor:"var(--IconButton-hoverBg)","@media (hover: none)":{backgroundColor:"transparent"}}}},{props:{edge:"start"},style:{marginLeft:-12}},{props:{edge:"start",size:"small"},style:{marginLeft:-3}},{props:{edge:"end"},style:{marginRight:-12}},{props:{edge:"end",size:"small"},style:{marginRight:-3}}]})),wr(({theme:e})=>({variants:[{props:{color:"inherit"},style:{color:"inherit"}},...Object.entries(e.palette).filter(ei()).map(([t])=>({props:{color:t},style:{color:(e.vars||e).palette[t].main}})),...Object.entries(e.palette).filter(ei()).map(([t])=>({props:{color:t},style:{"--IconButton-hoverBg":e.vars?`rgba(${(e.vars||e).palette[t].mainChannel} / ${e.vars.palette.action.hoverOpacity})`:Ft((e.vars||e).palette[t].main,e.palette.action.hoverOpacity)}})),{props:{size:"small"},style:{padding:5,fontSize:e.typography.pxToRem(18)}},{props:{size:"large"},style:{padding:12,fontSize:e.typography.pxToRem(28)}}],[`&.${as.disabled}`]:{backgroundColor:"transparent",color:(e.vars||e).palette.action.disabled},[`&.${as.loading}`]:{color:"transparent"}}))),nh=ot("span",{name:"MuiIconButton",slot:"LoadingIndicator"})(({theme:e})=>({display:"none",position:"absolute",visibility:"visible",top:"50%",left:"50%",transform:"translate(-50%, -50%)",color:(e.vars||e).palette.action.disabled,variants:[{props:{loading:!0},style:{display:"flex"}}]})),Ln=te.forwardRef(function(t,r){const n=Er({props:t,name:"MuiIconButton"}),{edge:i=!1,children:a,className:o,color:s="default",disabled:l=!1,disableFocusRipple:p=!1,size:u="medium",id:d,loading:f=null,loadingIndicator:g,...S}=n,c=vf(d),b=g??m.jsx($l,{"aria-labelledby":c,color:"inherit",size:16}),y={...n,edge:i,color:s,disabled:l,disableFocusRipple:p,loading:f,loadingIndicator:b,size:u},j=th(y);return m.jsxs(rh,{id:f?c:d,className:Ye(j.root,o),centerRipple:!0,focusRipple:!p,disabled:l||f,ref:r,...S,ownerState:y,children:[typeof f=="boolean"&&m.jsx("span",{className:j.loadingWrapper,style:{display:"contents"},children:m.jsx(nh,{className:j.loadingIndicator,ownerState:y,children:f&&b})}),a]})});process.env.NODE_ENV!=="production"&&(Ln.propTypes={children:Va(w.node,e=>te.Children.toArray(e.children).some(r=>te.isValidElement(r)&&r.props.onClick)?new Error(["MUI: You are providing an onClick event listener to a child of a button element.","Prefer applying it to the IconButton directly.","This guarantees that the whole <button> will be responsive to click events."].join(`
176
+ `)):null),classes:w.object,className:w.string,color:w.oneOfType([w.oneOf(["inherit","default","primary","secondary","error","info","success","warning"]),w.string]),disabled:w.bool,disableFocusRipple:w.bool,disableRipple:w.bool,edge:w.oneOf(["end","start",!1]),id:w.string,loading:w.bool,loadingIndicator:w.node,size:w.oneOfType([w.oneOf(["small","medium","large"]),w.string]),sx:w.oneOfType([w.arrayOf(w.oneOfType([w.func,w.object,w.bool])),w.func,w.object])});const os=bt(m.jsx("path",{d:"M12 4.5C7 4.5 2.73 7.61 1 12c1.73 4.39 6 7.5 11 7.5s9.27-3.11 11-7.5c-1.73-4.39-6-7.5-11-7.5M12 17c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5m0-8c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3"}),"Visibility"),ss=bt(m.jsx("path",{d:"M12 7c2.76 0 5 2.24 5 5 0 .65-.13 1.26-.36 1.83l2.92 2.92c1.51-1.26 2.7-2.89 3.43-4.75-1.73-4.39-6-7.5-11-7.5-1.4 0-2.74.25-3.98.7l2.16 2.16C10.74 7.13 11.35 7 12 7M2 4.27l2.28 2.28.46.46C3.08 8.3 1.78 10.02 1 12c1.73 4.39 6 7.5 11 7.5 1.55 0 3.03-.3 4.38-.84l.42.42L19.73 22 21 20.73 3.27 3zM7.53 9.8l1.55 1.55c-.05.21-.08.43-.08.65 0 1.66 1.34 3 3 3 .22 0 .44-.03.65-.08l1.55 1.55c-.67.33-1.41.53-2.2.53-2.76 0-5-2.24-5-5 0-.79.2-1.53.53-2.2m4.31-.78 3.15 3.15.02-.16c0-1.66-1.34-3-3-3z"}),"VisibilityOff"),ih=bt(m.jsx("path",{d:"M16 1H4c-1.1 0-2 .9-2 2v14h2V3h12zm3 4H8c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h11c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2m0 16H8V7h11z"}),"ContentCopy"),qa=bt(m.jsx("path",{d:"M9 16.17 4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z"}),"Check"),ni=bt(m.jsx("path",{d:"M18 15v3H6v-3H4v3c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2v-3zM7 9l1.41 1.41L11 7.83V16h2V7.83l2.59 2.58L17 9l-5-5z"}),"FileUploadOutlined"),ah=bt(m.jsx("path",{d:"M19 5v14H5V5zm0-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2m-4.86 8.86-3 3.87L9 13.14 6 17h12z"}),"ImageOutlined"),K={primary:{main:"#2C5EFF",contrastText:"#FFFFFF"},secondary:{main:"#00B894",contrastText:"#FFFFFF"},error:{main:"#E53935"},warning:{main:"#FB8C00"},info:{main:"#1E88E5"},success:{main:"#43A047"},background:{default:"#FFFFFF",paper:"#FFFFFF"},text:{primary:"#111827",secondary:"#6B7280",disabled:"#9CA3AF"},divider:"#E5E7EB"},ls=e=>{const t=e.replace("#",""),r=parseInt(t.length===3?t.split("").map(n=>n+n).join(""):t,16);return{r:r>>16&255,g:r>>8&255,b:r&255}},oh=(e,t,r)=>"#"+[e,t,r].map(n=>{const i=Math.round(Math.min(255,Math.max(0,n))).toString(16);return i.length===1?"0"+i:i}).join(""),$t=(e,t,r)=>{const n=ls(e),i=ls(t);return oh(n.r+(i.r-n.r)*r,n.g+(i.g-n.g)*r,n.b+(i.b-n.b)*r)},Ua=e=>{const t="#FFFFFF",r="#000000";return{50:$t(t,e,.08),100:$t(t,e,.16),200:$t(t,e,.28),300:$t(t,e,.4),400:$t(t,e,.55),500:e,600:$t(e,r,.1),700:$t(e,r,.2),800:$t(e,r,.3),900:$t(e,r,.42)}},sh=Ua(K.primary.main),lh=Ua(K.secondary.main),tt=Ua(K.text.primary),ch={primary:K.primary.main,secondary:K.secondary.main,textPrimary:K.text.primary,textSecondary:K.text.secondary,divider:K.divider,background:K.background},sa=({hasError:e,sx:t,labelText:r,labelVariant:n="subtitle2",endAdornment:i,endorsementText:a,endorsementBg:o="#E6E8EC",endorsementColor:s="#111827",endorsementRadius:l="6px",endorsementHeight:p=28,endorsementPaddingX:u="8px",...d})=>{var c,b;const f=!!r,g=a?m.jsx(E.Box,{component:"span",sx:{display:"inline-flex",flex:"0 0 auto",width:"auto",maxWidth:"100%",alignItems:"center",height:p,paddingLeft:u,paddingRight:u,borderRadius:l,backgroundColor:o,color:s,fontSize:12,fontWeight:300,lineHeight:1,whiteSpace:"nowrap"},children:a}):null,S={...d.InputProps,endAdornment:g||i?m.jsxs(E.InputAdornment,{sx:{mr:-1},position:"end",children:[g||i,(c=d.InputProps)==null?void 0:c.endAdornment]}):(b=d.InputProps)==null?void 0:b.endAdornment};return m.jsxs(E.Box,{children:[f&&m.jsx(E.Typography,{variant:n,sx:{color:K.text.primary,mb:.5,fontWeight:500},children:r}),m.jsx(E.TextField,{fullWidth:!0,size:"small",...d,InputProps:S,label:f?void 0:d.label,sx:{"& .MuiOutlinedInput-root":{backgroundColor:K.background.paper,borderRadius:"8px","& fieldset":{borderColor:K.divider},"&:hover fieldset":{borderColor:tt[300]},"&.Mui-focused fieldset":{borderColor:tt[400]},"&.Mui-error fieldset":{borderColor:K.error.main}},"& .MuiInputBase-input":{color:K.text.primary},"& .MuiFormLabel-root":{color:K.text.secondary},"& .MuiFormLabel-root.Mui-focused":{color:K.text.primary},"& .MuiFormHelperText-root":{color:e?K.error.main:K.text.secondary},...t}})]})},Dl=({labelText:e,label:t,options:r,loading:n,helperText:i,size:a="small",labelVariant:o="subtitle2",placeholder:s,value:l,sx:p,...u})=>{const d=P.useId(),f=l==null||l===""||Array.isArray(l)&&l.length===0,g=S=>m.jsx("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",...S,children:m.jsx("path",{d:"M6 9l6 6 6-6",stroke:K.text.secondary,strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})});return m.jsxs(E.FormControl,{fullWidth:!0,size:a,error:!!u.error,variant:"outlined",children:[e&&m.jsx(E.Typography,{variant:o,sx:{color:K.text.primary,mb:.5,fontWeight:500},children:e}),t&&m.jsx(E.InputLabel,{id:d,shrink:!f||!!s,sx:{color:K.text.secondary,"&.Mui-focused":{color:K.text.primary},"&.Mui-error":{color:K.error.main}},children:t}),m.jsx(E.Select,{...u,value:l,labelId:t?d:void 0,label:t,displayEmpty:!0,input:m.jsx(E.OutlinedInput,{label:t}),IconComponent:g,renderValue:S=>{const c=S;if(f)return m.jsx("span",{style:{color:K.text.secondary},children:s??""});const b=r.find(y=>y.value===c);return(b==null?void 0:b.label)??String(c)},endAdornment:n?m.jsx(E.CircularProgress,{size:20}):void 0,MenuProps:{PaperProps:{sx:{boxShadow:"0px 0px 10px 0px rgba(0, 0, 0, 0.1)",border:`1px solid ${K.divider}`,mt:.5,borderRadius:"8px"}}},sx:{backgroundColor:K.background.paper,boxShadow:"none",borderRadius:"8px",height:"40px","& .MuiSelect-select":{color:K.text.primary,fontSize:14,pr:3},"& .MuiOutlinedInput-notchedOutline":{borderColor:K.divider},"&:hover .MuiOutlinedInput-notchedOutline":{borderColor:tt[300]},"&.Mui-focused .MuiOutlinedInput-notchedOutline":{borderColor:tt[400]},"&.Mui-error .MuiOutlinedInput-notchedOutline":{borderColor:K.error.main},"& svg":{right:8,position:"absolute",pointerEvents:"none"},...p},children:n?m.jsx(E.MenuItem,{disabled:!0,children:m.jsx(E.CircularProgress,{size:16})}):r.map(S=>m.jsx(E.MenuItem,{value:S.value,sx:{backgroundColor:K.background.paper,color:K.text.primary,fontSize:14,mx:1,"&:hover":{backgroundColor:tt[50],borderRadius:"4px"},"&.Mui-selected":{backgroundColor:tt[50],borderRadius:"4px"}},children:S.label},S.value))}),i&&m.jsx(E.FormHelperText,{children:i})]})},uh=e=>m.jsx("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e,children:m.jsx("path",{d:"M6 9l6 6 6-6",stroke:K.text.secondary,strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})}),Pl=({id:e,options:t,value:r,multiple:n,label:i,labelText:a,placeholder:o,onChange:s,labelVariant:l="subtitle2",disabled:p,loading:u,error:d,helperText:f,onOpen:g,noOptionsText:S,sx:c})=>m.jsxs(E.Box,{children:[a&&m.jsx(E.Typography,{variant:l,sx:{color:K.text.primary,mb:.5,fontWeight:500},children:a}),m.jsx(E.Autocomplete,{id:e,options:t,value:r,multiple:n,size:"small",popupIcon:m.jsx(uh,{}),disabled:p,loading:u,onOpen:g,noOptionsText:S,fullWidth:!0,componentsProps:{paper:{sx:{boxShadow:"0px 0px 10px 0px rgba(0, 0, 0, 0.1)",border:`1px solid ${K.divider}`,mt:.5,borderRadius:"8px"}}},sx:{"& .MuiOutlinedInput-root":{backgroundColor:K.background.paper,borderRadius:"8px",height:"40px","& fieldset":{borderColor:K.divider},"&:hover fieldset":{borderColor:tt[300]},"&.Mui-focused fieldset":{borderColor:tt[400]},"&.Mui-error fieldset":{borderColor:K.error.main}},"& .MuiInputBase-input":{color:K.text.primary,fontSize:14},"& .MuiAutocomplete-popupIndicator":{color:K.text.secondary},"& .MuiAutocomplete-endAdornment svg":{width:16,height:16},...c},getOptionLabel:b=>typeof b=="string"?b:(b==null?void 0:b.label)??"",isOptionEqualToValue:(b,y)=>((b==null?void 0:b.value)??b)===((y==null?void 0:y.value)??y),renderOption:(b,y,{selected:j})=>m.jsxs(E.Box,{component:"li",...b,sx:{backgroundColor:K.background.paper,color:K.text.primary,mx:.5,borderRadius:"4px","&:hover":{backgroundColor:tt[50]},"&.Mui-focused":{backgroundColor:tt[50]},...j?{backgroundColor:tt[50]}:{}},children:[n&&m.jsx(E.Checkbox,{checked:j}),m.jsx(E.Typography,{variant:"body2",sx:{color:K.text.primary,fontSize:14},children:typeof y=="string"?y:y.label})]}),renderInput:b=>m.jsx(E.TextField,{...b,label:i,placeholder:o,size:"small",error:d,helperText:f,InputLabelProps:{shrink:!!r||!!o,sx:{color:K.text.secondary,"&.Mui-focused":{color:K.text.primary},"&.Mui-error":{color:K.error.main}}},InputProps:{...b.InputProps,endAdornment:m.jsxs(m.Fragment,{children:[u?m.jsx(E.CircularProgress,{size:20}):null,b.InputProps.endAdornment]})}}),onChange:(b,y)=>s(y)})]}),la=({label:e,checked:t,disabled:r,onChange:n,sx:i})=>m.jsx(E.FormControlLabel,{control:m.jsx(E.Checkbox,{size:"small",checked:t,disabled:r,onChange:(a,o)=>n(o)}),label:e,sx:a=>({"& .MuiFormControlLabel-label":{color:a.palette.text.primary,fontSize:14},...i})}),ca=({label:e,checked:t,disabled:r,onChange:n,sx:i})=>m.jsx(E.FormControlLabel,{control:m.jsx(E.Switch,{checked:t,disabled:r,onChange:(a,o)=>n(o)}),label:e,sx:a=>({"& .MuiFormControlLabel-label":{color:a.palette.text.primary,fontSize:14},...i})}),ua=({labelText:e,label:t,value:r,options:n,row:i=!1,onChange:a,labelPosition:o="top",labelVariant:s="subtitle2",helperText:l,error:p,groupPadding:u=1.5,itemGap:d=1})=>m.jsxs(E.FormControl,{error:p,sx:f=>{var g;return{display:"flex",flexDirection:"column",px:f.spacing(u),borderRadius:((g=f.shape)==null?void 0:g.borderRadius)||8,mx:-2.5,backgroundColor:f.palette.background.paper}},children:[o==="top"&&e&&m.jsx(E.Typography,{variant:s,sx:f=>({color:f.palette.text.primary,mb:.5,fontSize:f.typography.fontSize,fontWeight:500}),children:e}),t&&m.jsx(E.FormLabel,{sx:f=>({color:f.palette.text.secondary,mb:.5,mx:1,fontSize:f.typography.fontSize||12,fontWeight:500,"&.Mui-focused":{color:f.palette.text.primary},"&.Mui-error":{color:f.palette.error.main}}),children:t}),m.jsx(E.RadioGroup,{row:i,value:r,onChange:f=>a(f.target.value),sx:f=>({display:"flex",flexDirection:i?"row":"column",gap:f.spacing(d),alignItems:i?"center":"flex-start",mt:-1}),children:n.map(f=>m.jsx(E.FormControlLabel,{value:f.value,control:m.jsx(E.Radio,{size:"small",sx:g=>({color:g.palette.text.secondary,"&.Mui-checked":{color:g.palette.primary.main}})}),label:f.label,sx:g=>({m:0,"& .MuiFormControlLabel-label":{color:g.palette.text.primary,fontSize:14}})},String(f.value)))}),l&&m.jsx(E.FormHelperText,{sx:{mt:.5},children:l})]}),Il=({labelPosition:e="inner",labelVariant:t="subtitle2",label:r,sx:n,...i})=>m.jsxs(E.Box,{children:[e==="top"&&r&&m.jsx(E.Typography,{variant:t,sx:{color:"#111827",mb:.5},children:r}),m.jsx(E.TextField,{fullWidth:!0,type:"date",size:"small",label:e==="inner"?r:void 0,InputLabelProps:{shrink:!0},...i,sx:{"& .MuiOutlinedInput-root":{backgroundColor:"#FFFFFF",borderRadius:"8px","& fieldset":{borderColor:"#E5E7EB"},"&:hover fieldset":{borderColor:"#D1D5DB"},"&.Mui-focused fieldset":{borderColor:"#D1D5DB"},"&.Mui-error fieldset":{borderColor:"#E53935"}},"& .MuiInputBase-input":{color:"#111827",fontSize:14},...n}})]}),Ml=({labelText:e,labelVariant:t="subtitle2",hasError:r,sx:n,label:i,...a})=>{const o=!!e;return m.jsxs(E.Box,{children:[o&&m.jsx(E.Typography,{variant:t,sx:{color:K.text.primary,mb:.5,fontWeight:500},children:e}),m.jsx(E.TextField,{fullWidth:!0,multiline:!0,minRows:3,size:"small",...a,label:o?void 0:i,sx:{"& .MuiOutlinedInput-root":{backgroundColor:K.background.paper,borderRadius:"8px","& fieldset":{borderColor:K.divider},"&:hover fieldset":{borderColor:tt[300]},"&.Mui-focused fieldset":{borderColor:tt[400]},"&.Mui-error fieldset":{borderColor:K.error.main}},"& .MuiInputBase-input":{color:K.text.primary,fontSize:14},"& .MuiFormLabel-root":{color:K.text.secondary},"& .MuiFormLabel-root.Mui-focused":{color:K.text.primary},"& .MuiFormHelperText-root":{color:r?K.error.main:K.text.secondary},...n}})]})},pa=({title:e,subtitle:t,actions:r,align:n="left",sx:i})=>m.jsxs(E.Box,{sx:a=>({display:"flex",flexDirection:"row",alignItems:"center",justifyContent:"space-between",gap:a.spacing(1),py:a.spacing(1),...i}),children:[m.jsxs(E.Box,{sx:{display:"flex",flexDirection:"column",minWidth:0,flex:1,textAlign:n},children:[e&&m.jsx(E.Typography,{variant:"h6",sx:a=>({color:a.palette.text.primary,fontSize:12,fontWeight:600,lineHeight:1.3}),children:e}),t&&m.jsx(E.Typography,{variant:"body2",sx:a=>({color:a.palette.text.secondary,mt:e?.5:0,fontSize:12,fontWeight:300}),children:t})]}),r&&m.jsx(E.Box,{sx:{display:"flex",alignItems:"center",gap:1,flexWrap:"wrap"},children:r})]}),ph=()=>m.jsxs("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[m.jsx("g",{"clip-path":"url(#clip0_5814_24904)",children:m.jsx("path",{d:"M11 18C11 19.1 10.1 20 9 20C7.9 20 7 19.1 7 18C7 16.9 7.9 16 9 16C10.1 16 11 16.9 11 18ZM9 10C7.9 10 7 10.9 7 12C7 13.1 7.9 14 9 14C10.1 14 11 13.1 11 12C11 10.9 10.1 10 9 10ZM9 4C7.9 4 7 4.9 7 6C7 7.1 7.9 8 9 8C10.1 8 11 7.1 11 6C11 4.9 10.1 4 9 4ZM15 8C16.1 8 17 7.1 17 6C17 4.9 16.1 4 15 4C13.9 4 13 4.9 13 6C13 7.1 13.9 8 15 8ZM15 10C13.9 10 13 10.9 13 12C13 13.1 13.9 14 15 14C16.1 14 17 13.1 17 12C17 10.9 16.1 10 15 10ZM15 16C13.9 16 13 16.9 13 18C13 19.1 13.9 20 15 20C16.1 20 17 19.1 17 18C17 16.9 16.1 16 15 16Z",fill:"#056739","fill-opacity":"0.5"})}),m.jsx("defs",{children:m.jsx("clipPath",{id:"clip0_5814_24904",children:m.jsx("rect",{width:"24",height:"24",fill:"white"})})})]});function dh({items:e,getId:t,onReorder:r,header:n,disabled:i,sx:a,getText:o,showIndex:s=!0,showLeftIcon:l=!0,renderItem:p,chipText:u,helperText:d}){const[f,g]=P.useState(null),[S,c]=P.useState(null),b=k=>v=>{if(!i){g(k),v.dataTransfer.effectAllowed="move";try{v.dataTransfer.setData("text/plain",String(t(e[k])))}catch{}}},y=k=>v=>{i||(v.preventDefault(),c(k),v.dataTransfer.dropEffect="move")},j=k=>v=>{if(i)return;if(v.preventDefault(),f===null||f===k){g(null),c(null);return}const B=[...e],[A]=B.splice(f,1);B.splice(k,0,A),g(null),c(null),r(B)},R=()=>{g(null),c(null)};return m.jsxs(E.Box,{role:"list",sx:k=>({display:"flex",flexDirection:"column",gap:k.spacing(1),...a}),children:[n,m.jsx(E.Divider,{sx:{mt:-.5,mb:1,dividerColor:"#EBEBEB"}}),e.map((k,v)=>{const B=f===v,A=S===v&&f!==null&&f!==v;return m.jsx(E.Box,{role:"listitem",draggable:!i,onDragStart:b(v),onDragOver:y(v),onDrop:j(v),onDragEnd:R,sx:H=>{var U;return{userSelect:"none",cursor:i?"default":"grab",backgroundColor:"#F8F8FA",border:`1px solid ${A?H.palette.primary.main:"#EBEBEB"}`,borderRadius:((U=H.shape)==null?void 0:U.borderRadius)||"8px",padding:H.spacing(1),opacity:B?.6:1,boxShadow:A?`0 0 0 2px ${H.palette.primary.main}33`:"none"}},children:p?p(k,B):m.jsxs(E.Box,{sx:H=>({display:"flex",alignItems:"center",gap:H.spacing(1),minWidth:0}),children:[l&&m.jsx(ph,{}),s&&m.jsxs(E.Typography,{variant:"body2",sx:H=>({fontWeight:600,fontSize:14,color:`${H.palette.text.primary}`,flex:"0 0 auto"}),children:[v+1,"."]}),(()=>{const H=typeof u=="function"?u(k,v):u;return H?m.jsx(E.Chip,{label:H,sx:{borderRadius:"4px",p:"12px 3px"},size:"small"}):null})(),m.jsx(E.Typography,{variant:"body2",sx:H=>({fontSize:12,fontWeight:500,color:`${H.palette.text.primary}90`,flex:1,minWidth:0,overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis"}),children:o?o(k):""})]})},String(t(k)))}),d?typeof d=="string"?m.jsx(E.Typography,{variant:"caption",sx:k=>({color:`${k.palette.text.primary}60`}),children:d}):d:null]})}const fh=ot(E.StepConnector)(()=>({[`&.${E.stepConnectorClasses.vertical}`]:{marginLeft:11},[`& .${E.stepConnectorClasses.line}`]:{minHeight:28,borderLeftWidth:2,borderColor:"#E8E8E8",transition:"border-color 0.3s ease"},[`&.${E.stepConnectorClasses.completed} .${E.stepConnectorClasses.line}`]:{borderColor:K.primary.main}})),hh=({items:e,activeIndex:t=1,onStepClick:r,sx:n})=>{const i=a=>{const{active:o,completed:s,icon:l}=a;return s?m.jsx(E.Box,{sx:{width:24,height:24,border:`1.2px solid ${K.primary.main}`,borderRadius:"50%",backgroundColor:K.primary.main,color:"#fff",display:"flex",alignItems:"center",justifyContent:"center"},children:m.jsx(qa,{sx:{fontSize:16,fontWeight:600}})}):o?m.jsx(E.Box,{sx:{width:24,height:24,borderRadius:"50%",border:`1.2px solid ${K.primary.main}`,backgroundColor:Ft(K.primary.main,.2),color:K.primary.main,display:"flex",alignItems:"center",justifyContent:"center",fontWeight:500,fontSize:12},children:l}):m.jsx(E.Box,{sx:{width:24,height:24,borderRadius:"50%",backgroundColor:"#E8E8E8",color:K.text.primary,display:"flex",alignItems:"center",justifyContent:"center",fontWeight:500,fontSize:12},children:l})};return m.jsx(E.Stepper,{orientation:"vertical",activeStep:t,connector:m.jsx(fh,{}),sx:{"& .MuiStepConnector-vertical":{my:-1.1},"& .MuiStepLabel-label":{fontSize:14,color:K.text.primary,fontWeight:500},"& .MuiStep-root":{cursor:r?"pointer":"default"},...n},children:e.map((a,o)=>m.jsxs(E.Step,{onClick:()=>r==null?void 0:r(o),completed:o<t,children:[m.jsx(E.StepLabel,{StepIconComponent:i,children:m.jsx(E.Typography,{sx:{fontSize:12,fontWeight:500,color:o===t?K.primary.main:K.text.primary},children:a.label})}),o!==e.length-1&&m.jsx(E.Divider,{sx:{ml:4.2,borderColor:K.divider}})]},o))})},zl=({colorKey:e="primary",colorHex:t,tone:r="soft",bgAlpha:n=.12,borderAlpha:i=.24,sx:a,...o})=>m.jsx(E.Chip,{...o,sx:s=>({fontWeight:600,borderRadius:"4px",height:18,border:`0.5px solid ${Ft(t||s.palette.text.primary,.5)}`,backgroundColor:Ft(t||s.palette.text.primary,.1),"& .MuiChip-label":{p:"8px",color:t||s.palette.text.primary,fontSize:10,fontWeight:500},...a})}),mh=ot(E.StepConnector)(()=>({[`&.${E.stepConnectorClasses.vertical}`]:{marginLeft:11},[`& .${E.stepConnectorClasses.line}`]:{minHeight:28,borderLeftWidth:2,height:"70px",borderColor:"#E8E8E8",transition:"border-color 0.3s ease",zIndex:-1},[`&.${E.stepConnectorClasses.completed} .${E.stepConnectorClasses.line}`]:{borderColor:K.primary.main}})),yh=({items:e,activeIndex:t=1,onStepClick:r,sx:n})=>{const[i,a]=P.useState(null),o=s=>{const{active:l,completed:p,icon:u}=s;return p?m.jsx(E.Box,{sx:{width:24,height:24,border:`1.2px solid ${K.primary.main}`,borderRadius:"50%",backgroundColor:K.primary.main,color:"#fff",display:"flex",alignItems:"center",justifyContent:"center",zIndex:1e3},children:m.jsx(qa,{sx:{fontSize:16,fontWeight:600}})}):l?m.jsx(E.Box,{sx:{width:24,height:24,borderRadius:"50%",border:`1.2px solid ${K.primary.main}`,backgroundColor:Ft(K.primary.main,.2),color:K.primary.main,display:"flex",alignItems:"center",justifyContent:"center",fontWeight:500,fontSize:12,zIndex:1e3,overflow:"hidden"},children:u}):m.jsx(E.Box,{sx:{width:24,height:24,borderRadius:"50%",backgroundColor:"#E8E8E8",color:K.text.primary,display:"flex",alignItems:"center",justifyContent:"center",fontWeight:500,fontSize:12,zIndex:1e3},children:u})};return m.jsx(E.Stepper,{orientation:"vertical",activeStep:t,connector:m.jsx(mh,{}),sx:{"& .MuiStepConnector-vertical":{my:-3.5},"& .MuiStepLabel-label":{fontSize:14,color:K.text.primary,fontWeight:500},"& .MuiStep-root":{cursor:r?"pointer":"default"},...n},children:e.map((s,l)=>m.jsxs(E.Step,{onMouseEnter:()=>a(l),onMouseLeave:()=>a(null),onClick:()=>r==null?void 0:r(l),completed:l<t,children:[m.jsxs(E.Box,{sx:{display:"flex",justifyContent:"space-between",alignItems:"flex-start"},children:[m.jsxs(E.StepLabel,{StepIconComponent:o,children:[m.jsxs(E.Box,{sx:{display:"flex",gap:1,alignItems:"center"},children:[m.jsx(E.Typography,{sx:{fontSize:14,fontWeight:500,color:l===t?K.primary.main:K.text.primary},children:s.label}),m.jsx(zl,{size:"small",colorHex:l<t?K.success.main:l===t?"#973B00":K.text.primary,label:l<t?"Completed":l===t?"In progress":"Not started"})]}),m.jsx(E.Typography,{sx:{fontSize:12,fontWeight:400,color:`${K.text.primary}60`,mt:.5,width:"80%"},children:s.description})]}),i===l&&m.jsx(E.Button,{sx:{display:l>t?"none":"block"},variant:l<t?"outlined":"contained",size:"small",color:"primary",children:l<t?"Edit":l===t?"Complete":""})]}),l!==e.length-1&&m.jsx(E.Divider,{sx:{ml:4.2,borderColor:K.divider}})]},l))})},gh=bt(m.jsx("path",{d:"M11 7h2v2h-2zm0 4h2v6h-2zm1-9C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8"}),"InfoOutlined"),xh=({variant:e="list",title:t,subtitle:r,text:n,items:i=[],icon:a,colorHex:o,sx:s})=>{const l=o||K.info.main,p=Ft(l,.08),u=Ft(l,.08),d=a??m.jsx(gh,{sx:{color:l,fontSize:18}});return e==="inlineInfo"?m.jsxs(E.Card,{sx:{p:1.5,display:"flex",alignItems:"center",gap:1,backgroundColor:p,border:`1px solid ${u}`,boxShadow:"none",...s},children:[m.jsx(E.Box,{sx:{display:"flex",alignItems:"center"},children:d}),m.jsx(E.Typography,{variant:"body2",sx:{fontWeight:400,fontSize:12,lineHeight:1.3,color:l},children:n})]}):e==="inline"?m.jsx(E.Card,{sx:{p:1.5,display:"flex",alignItems:"center",gap:1,backgroundColor:p,border:`1px solid ${u}`,boxShadow:"none",...s},children:m.jsx(E.Typography,{variant:"body2",sx:{fontWeight:400,fontSize:12,lineHeight:1.3,color:l},children:n})}):e==="listWithHeader"?m.jsxs(E.Card,{sx:{p:2,boxShadow:"none",borderRadius:"6px",backgroundColor:p,border:`1px solid ${u}`,...s},children:[m.jsxs(E.Box,{sx:{display:"flex",alignItems:"center",gap:1},children:[d,m.jsx(E.Typography,{variant:"subtitle2",sx:{fontWeight:600,color:l,fontSize:14,lineHeight:1.3},children:t})]}),r&&m.jsx(E.Typography,{variant:"body2",sx:{mt:.5,color:l,fontSize:10,lineHeight:1.3},children:r}),m.jsx(E.List,{sx:{pl:5,"& .MuiListItem-root":{display:"list-item",listStyleType:"disc",color:l},"& .MuiListItemText-primary":{fontSize:"12px",fontWeight:400,lineHeight:"18px",color:l,my:-.5}},children:i.map((f,g)=>m.jsx(E.ListItem,{sx:{py:0},children:m.jsx(E.ListItemText,{primary:f})},g))})]}):m.jsx(E.Card,{sx:{p:"11px",borderRadius:"8px",backgroundColor:p,border:`0.5px solid ${u}`,boxShadow:"none",...s},children:m.jsx(E.List,{sx:{pl:4,"& .MuiListItem-root":{display:"list-item",listStyleType:"disc",color:l},"& .MuiListItemText-primary":{fontSize:"12px",fontWeight:600,lineHeight:"18px",color:l,my:-.5}},children:i.map((f,g)=>m.jsx(E.ListItem,{sx:{py:0},children:m.jsx(E.ListItemText,{primary:f})},g))})})},vh=({value:e,onChange:t,items:r,ariaLabel:n,sx:i,tabSx:a})=>m.jsxs(E.Box,{children:[m.jsx(E.Tabs,{value:e,onChange:(o,s)=>t(s),"aria-label":n||"Fin tabs",sx:o=>({minHeight:"36px",borderRadius:"6px",p:.5,backgroundColor:o.palette.background.paper,boxShadow:"inset 0 0 0 1px "+o.palette.divider,"& .MuiTabs-flexContainer":{gap:.5},"& .MuiTabs-indicator":{display:"none"},...i}),children:r.map((o,s)=>{const l=typeof o.value=="string"||typeof o.value=="number"?o.value:s;return m.jsx(E.Tab,{value:l,disabled:o.disabled,label:m.jsx(E.Typography,{variant:"body2",children:o.label}),sx:p=>({minHeight:32,px:2,textTransform:"none",color:p.palette.text.secondary,borderRadius:"3px",border:"1px solid "+p.palette.divider,backgroundColor:p.palette.background.default,"&:hover":{backgroundColor:p.palette.action.hover},"&.Mui-selected":{color:p.palette.common.white,borderColor:p.palette.primary.main,backgroundColor:p.palette.primary.main,fontWeight:600},...a})},String(l))})}),r.map((o,s)=>{const l=typeof o.value=="string"||typeof o.value=="number"?o.value:s,p=o.content??(typeof o.value=="object"?o.value:null);return p&&e===l?m.jsx(E.Box,{sx:{mt:1},children:p},`panel-${l}`):null})]});async function Vl(e,t,r,n){try{const{endpoint:i,method:a="GET",valueField:o="value",labelField:s="label",headers:l={},params:p={},body:u,transform:d,passThroughFields:f}=e;let g=i;if(t&&!i.startsWith("http")&&(g=`${t}${i.startsWith("/")?i:`/${i}`}`),n){const k=/\{([^}]+)\}/g;g=g.replace(k,(v,B)=>{const A=n[B];return A!=null?encodeURIComponent(String(A)):""}),g=g.replace(/\?&/g,"?").replace(/&&/g,"&").replace(/\?$/g,"")}const S=new URLSearchParams;Object.entries(p).forEach(([k,v])=>{v!=null&&S.append(k,String(v))}),S.toString()&&(g+=`${g.includes("?")?"&":"?"}${S.toString()}`);try{const k=/^https?:\/\//i.test(g),v=new URL(g,k?void 0:"http://local.placeholder"),B=Array.from(v.searchParams.entries());for(const[A,H]of B)(H===""||H==="undefined"||H==="null")&&v.searchParams.delete(A);k?g=v.toString():g=v.pathname+(v.search?v.search:""),g=g.replace(/\?&/g,"?").replace(/&&/g,"&").replace(/\?$/g,"")}catch{}const c={"Content-Type":"application/json",...r,...l},b={method:a,headers:c};(a==="POST"||a==="PUT")&&u&&(b.body=JSON.stringify(u));const y=await fetch(g,b);if(!y.ok)throw new Error(`API request failed: ${y.status} ${y.statusText}`);const j=await y.json();if(d)return d(Array.isArray(j)?j:j.data||j);const R=Array.isArray(j)?j:j.data||j;if(!Array.isArray(R))throw new Error("API response is not an array");return R.map(k=>{const v={label:k[s]||k.name||k.title||String(k[o]||""),value:k[o]||k.id||k.value||""},B=Array.isArray(f)?f:void 0;if(Array.isArray(B))for(const A of B)k[A]!==void 0&&(v[A]=k[A]);return v})}catch(i){throw console.error("API fetch error:",i),new Error(`Failed to fetch data: ${i instanceof Error?i.message:"Unknown error"}`)}}function Bl(e,t,r,n,i=!1){const a=P.useMemo(()=>{if(!(e!=null&&e.dependsOn)||!n)return null;const s=n[e.dependsOn];return s!==void 0?s:null},[e==null?void 0:e.dependsOn,n]),o=P.useMemo(()=>["api-data",e==null?void 0:e.endpoint,e==null?void 0:e.method,e==null?void 0:e.valueField,e==null?void 0:e.labelField,t,a,n?JSON.stringify(n):null],[e==null?void 0:e.endpoint,e==null?void 0:e.method,e==null?void 0:e.valueField,e==null?void 0:e.labelField,t,a,n]);return ku({queryKey:o,queryFn:()=>{if(!e)throw new Error("API config is required");return Vl(e,t,r,n)},enabled:i&&!!e,staleTime:15*60*1e3,gcTime:30*60*1e3,retry:3,retryDelay:s=>Math.min(1e3*2**s,3e4),refetchOnWindowFocus:!1,refetchOnReconnect:!0,refetchOnMount:!1})}function or(e){return!!(e.apiConfig||e.api_endpoint)}function Wa(e){return e.apiConfig?e.apiConfig:e.api_endpoint?{endpoint:e.api_endpoint,method:e.api_method||"GET",valueField:e.value_field||"value",labelField:e.label_field||"label",dependsOn:e.depends_on,conditional:e.conditional}:null}function bh(e,t){const r=Wa(e);if(!(r!=null&&r.conditional)&&!e.conditional)return!0;if(r!=null&&r.dependsOn||e.depends_on){const n=(r==null?void 0:r.dependsOn)||e.depends_on;if(n){const i=t[n];return i!=null&&i!==""}}return!0}const Nl=({field:e,control:t,errors:r,baseUrl:n,apiHeaders:i,formData:a,setValue:o})=>{const s=r[e.name],l=!!s,[p,u]=P.useState(!1),d=P.useRef(!1),[f,g]=P.useState(!1),[S,c]=P.useState(!1),[b,y]=P.useState(!1),j=P.useRef(null),R=P.useRef(null),k=()=>{var L;return e.required!==void 0?e.required:((L=e.validation)==null?void 0:L.required)!==void 0?e.validation.required:!1},v=L=>k()?`${L} *`:L,B=()=>e.value!==void 0?e.value:e.type==="checkbox"?!1:e.type==="select"&&e.default?e.default:e.type==="autocomplete"&&e.multiple?[]:"",A=P.useMemo(()=>{const L=Wa(e);return L&&Array.isArray(e.passThroughFields)&&(L.passThroughFields=e.passThroughFields),L},[e.apiConfig,e.api_endpoint,e.api_method,e.value_field,e.label_field,e.depends_on,e.conditional,e.passThroughFields]),H=P.useRef(null),U=A!=null&&A.dependsOn?a==null?void 0:a[A.dependsOn]:null,h=P.useMemo(()=>{if(!(A!=null&&A.dependsOn))return!1;const L=U,X=H.current,ne=L!==X;return ne&&(H.current=L),ne},[A==null?void 0:A.dependsOn,U]),z=P.useMemo(()=>{const L=e.showWhen;if(typeof L=="function")try{return!!L(a||{})}catch{return!0}if(L&&typeof L=="object"){const X=L.field,ne=L.equals,ue=L.in,de=X?(a||{})[X]:void 0;if(X&&typeof ne<"u")return de===ne;if(X&&Array.isArray(ue))return ue.includes(de)}return!0},[e.showWhen,a]),M=P.useCallback(()=>{const L=e.dynamicEndorsement;if(typeof L=="function")try{return L(a||{})}catch{return e.endorsementText}return e.endorsementText},[e,a]),q=P.useCallback(()=>{const L=e.endAdornment;if(typeof L=="function")try{return L(a||{})}catch{return}return L},[e,a]),N=P.useMemo(()=>p&&or(e)&&(!(A!=null&&A.dependsOn)||U),[p,e,A==null?void 0:A.dependsOn,U]),J=P.useMemo(()=>{const L={};if(!a)return L;const X=(A==null?void 0:A.endpoint)||(e==null?void 0:e.api_endpoint);if(X&&typeof X=="string"){const ne=X.match(/\{([^}]+)\}/g)||[];for(const ue of ne){const de=ue.slice(1,-1),pe=a[de];pe!==void 0&&(L[de]=pe)}}if(A!=null&&A.dependsOn){const ne=A.dependsOn,ue=a[ne];ue!==void 0&&(L[ne]=ue)}return L},[A==null?void 0:A.endpoint,e==null?void 0:e.api_endpoint,A==null?void 0:A.dependsOn,a]),{data:ae=[],isLoading:he,error:ie}=Bl(A,n,i,J,N),oe=P.useCallback(()=>{or(e)&&!d.current&&(d.current=!0,u(!0))},[e]),V=P.useCallback(()=>{or(e)&&!d.current&&(d.current=!0,u(!0))},[e]);P.useEffect(()=>{if(or(e)&&!d.current){const L=a==null?void 0:a[e.name];L!=null&&L!==""&&(d.current=!0,u(!0))}},[e,a]),P.useEffect(()=>{or(e)&&(A!=null&&A.dependsOn)&&h&&d.current&&(d.current=!1,u(!1))},[h,A==null?void 0:A.dependsOn]);const W=P.useCallback(()=>or(e)?ae:e.type==="select"||e.type==="toggle"||e.type==="radio"||e.type==="autocomplete"?e.options||[]:[],[e,ae]),ce=()=>{switch(e.type){case"title":return m.jsx(E.Typography,{variant:e.variant||"h4",component:"h1",color:e.color,align:e.align||"left",sx:{mb:3,fontWeight:600,...e.sx},children:e.label});case"section":return m.jsx(E.Typography,{variant:e.variant||"h6",component:"h3",color:e.color,align:e.align||"left",sx:{mb:2,fontWeight:600,color:"text.primary",...e.sx},children:e.label});case"finuiHeader":const L=e.actionName,X=e.actionComponent,ne=e.actionLabel;return L&&X?m.jsx(ht,{name:L,control:t,defaultValue:e.value??!1,render:({field:D})=>m.jsx(pa,{title:e.title||e.label,subtitle:e.subtitle,align:e.align||"left",sx:e.sx,actions:X==="switch"?m.jsx(ca,{label:ne,checked:!!D.value,onChange:D.onChange}):m.jsx(la,{label:ne||"",checked:!!D.value,onChange:D.onChange})})}):m.jsx(pa,{title:e.title||e.label,subtitle:e.subtitle,actions:e.actions,align:e.align||"left",sx:e.sx});case"text":case"email":case"password":case"tel":case"textarea":return m.jsx(ht,{name:e.name,control:t,defaultValue:B(),render:({field:D})=>e.type==="textarea"?m.jsx(Ml,{...D,labelText:e.labelPosition==="top"?v(e.label):void 0,label:e.labelPosition!=="top"?v(e.label):void 0,labelVariant:e.labelVariant,placeholder:e.placeholder,disabled:e.disabled,hasError:l,helperText:(s==null?void 0:s.message)||e.helperText}):m.jsx(sa,{...D,id:e.id,labelText:e.labelPosition==="top"?v(e.label):void 0,label:e.labelPosition!=="top"?v(e.label):void 0,endorsementText:M(),endorsementBg:e.endorsementBg,endorsementColor:e.endorsementColor,endorsementRadius:e.endorsementRadius,endorsementHeight:e.endorsementHeight,endorsementPaddingX:e.endorsementPaddingX,labelVariant:e.labelVariant,type:e.type==="password"?f?"text":"password":e.type,placeholder:e.placeholder,disabled:e.disabled,hasError:l,helperText:(s==null?void 0:s.message)||e.helperText,InputProps:e.type==="password"?{endAdornment:m.jsx(jl,{position:"end",children:m.jsx(Ln,{"aria-label":"toggle password visibility",onClick:()=>g(_=>!_),edge:"end",children:f?m.jsx(ss,{}):m.jsx(os,{})})})}:void 0})});case"number":return m.jsx(ht,{name:e.name,control:t,defaultValue:B(),render:({field:D})=>m.jsx(sa,{...D,id:e.id,labelText:e.labelPosition==="top"?v(e.label):void 0,label:e.labelPosition!=="top"?v(e.label):void 0,endAdornment:q(),endorsementText:M(),endorsementBg:e.endorsementBg,endorsementColor:e.endorsementColor,endorsementRadius:e.endorsementRadius,endorsementHeight:e.endorsementHeight,endorsementPaddingX:e.endorsementPaddingX,labelVariant:e.labelVariant,type:"number",placeholder:e.placeholder,disabled:e.disabled,hasError:l,helperText:(s==null?void 0:s.message)||e.helperText,inputProps:{min:e.min,max:e.max}})});case"select":const ue=W();return m.jsx(ht,{name:e.name,control:t,defaultValue:B(),render:({field:D})=>m.jsx(Dl,{labelText:e.labelPosition==="top"?v(e.label):void 0,label:e.labelPosition!=="top"&&e.labelPosition!=="none"?v(e.label):void 0,labelVariant:e.labelVariant,value:D.value,onChange:D.onChange,options:ue,disabled:e.disabled||he,placeholder:e.labelPosition==="inner"||e.labelPosition==="none"||!e.labelPosition?e.placeholder||(e.labelPosition==="none"?v(e.label):void 0):e.placeholder,loading:he,error:l||!!ie,helperText:(s==null?void 0:s.message)||(ie==null?void 0:ie.message)||e.helperText,onOpen:oe})});case"checkbox":return m.jsx(ht,{name:e.name,control:t,defaultValue:B(),render:({field:D})=>m.jsx(la,{label:v(e.label),checked:!!D.value,disabled:e.disabled,onChange:D.onChange})});case"toggle":return m.jsx(ht,{name:e.name,control:t,defaultValue:B(),render:({field:D})=>m.jsx(ua,{label:v(e.label),labelPosition:e.labelPosition==="none"?"none":"top",labelVariant:e.labelVariant,value:D.value,options:e.options||[],row:!0,onChange:D.onChange})});case"radio":return m.jsx(ht,{name:e.name,control:t,defaultValue:B(),render:({field:D})=>m.jsx(ua,{label:v(e.label),labelPosition:e.labelPosition==="none"?"none":"top",labelVariant:e.labelVariant,value:D.value,options:e.options||[],row:e.row===!0,groupPadding:e.groupPadding,itemGap:e.itemGap,helperText:e.helperText,onChange:D.onChange})});case"switch":return m.jsx(ht,{name:e.name,control:t,defaultValue:B(),render:({field:D})=>m.jsx(ca,{label:v(e.label),checked:!!D.value,disabled:e.disabled,onChange:D.onChange})});case"autocomplete":const de=W(),pe=!!(e.disabled||he||A!=null&&A.dependsOn&&!U);return m.jsx(ht,{name:e.name,control:t,defaultValue:B(),render:({field:D})=>{const _=D.value,Q=e.multiple===!0,fe=(A==null?void 0:A.valueField)||e.value_field||"value",xe=(A==null?void 0:A.labelField)||e.label_field||"label",Be=re=>{if(re!=null){if(typeof re=="string"||typeof re=="number")return re;if(typeof re=="object"){if(re[fe]!==void 0)return re[fe];if(re.value!==void 0)return re.value;if(re.id!==void 0)return re.id}}},Le=(()=>{if(Q)return(Array.isArray(_)?_:[]).map(Oe=>{const x=de.find(O=>{const T=Be(O);return T!==void 0&&T===Oe});return x||{[fe]:Oe,[xe]:`Selected: ${Oe}`,value:Oe,label:`Selected: ${Oe}`}});{if(_==null||_==="")return null;const re=de.find(Oe=>{const x=Be(Oe);return x!==void 0&&x===_});return re||{[fe]:_,[xe]:`Selected: ${_}`,value:_,label:`Selected: ${_}`}}})();return m.jsx(Pl,{id:e.id,options:de,value:Le,multiple:Q,labelText:e.labelPosition==="top"?v(e.label):void 0,label:e.labelPosition!=="top"?v(e.label):void 0,placeholder:pe&&(A!=null&&A.dependsOn)&&!U?`Please select ${A.dependsOn.replace(/_/g," ")} first`:e.placeholder,labelVariant:e.labelVariant,disabled:pe,loading:he,error:l||!!ie,helperText:(s==null?void 0:s.message)||(ie==null?void 0:ie.message)||e.helperText||"",onOpen:V,noOptionsText:pe&&(A!=null&&A.dependsOn)&&!U?`Please select ${A.dependsOn.replace(/_/g," ")} first`:he?"Fetching data...":p&&!he&&de.length===0?"No options available":"Click to load options",onChange:re=>{const Oe=(A==null?void 0:A.valueField)||e.value_field||"value";if(Q){const O=(Array.isArray(re)?re:[]).map(T=>typeof T=="object"&&(T[Oe]||T.value||T.id)||T);D.onChange(O)}else{let x;re&&typeof re=="object"?x=re[Oe]||re.value||re.id||re:x=re,D.onChange(x);const O=e.selectedAssignments;if(O&&re&&typeof re=="object")for(const[T,Z]of Object.entries(O)){const F=re[Z];if(F!==void 0&&typeof o=="function")try{o(T,F,{shouldDirty:!0,shouldTouch:!0,shouldValidate:!1})}catch{}}}}})}});case"date":return m.jsx(ht,{name:e.name,control:t,defaultValue:B(),render:({field:D})=>m.jsx(Il,{...D,id:e.name,label:v(e.label),labelPosition:e.labelPosition||"inner",labelVariant:e.labelVariant,disabled:e.disabled,error:l,helperText:s==null?void 0:s.message,inputProps:{min:e.minDate,max:e.maxDate}})});case"image":return m.jsx(ht,{name:e.name,control:t,defaultValue:B(),render:({field:D})=>{const _=D.value||e.defaultValue||e.src;if(_){const re=e.imageUploaded||{},Oe=re.previewText||"Preview",x=re.removeText||"Remove",O=re.saveText||"Save logo",T=re.showSave!==void 0?re.showSave:!!(e.onSave||re.saveText),Z=()=>{if(y(!0),typeof e.onPreview=="function")try{e.onPreview(_)}catch{}},F=()=>{D.onChange(""),typeof e.onRemove=="function"&&e.onRemove()},$=()=>{typeof e.onSave=="function"&&e.onSave({url:_,file:R.current||void 0})},Y=le=>{const ge=le.target.files&&le.target.files[0];if(ge){if(typeof e.onFileSelected=="function")try{e.onFileSelected(ge)}catch{}try{const Ve=URL.createObjectURL(ge);D.onChange(Ve)}catch{}R.current=ge,y(!1)}};return m.jsxs(E.Card,{sx:{display:"flex",alignItems:"center",gap:2,p:2,boxShadow:"0px 1px 4px 0px #00000014",...re.cardSx},children:[m.jsx("input",{type:"file",ref:j,accept:Array.isArray(e.accept)?e.accept.join(","):e.accept||"image/*",style:{display:"none"},onChange:Y}),m.jsxs(E.Box,{sx:{display:"flex",flexDirection:"column",gap:1},children:[m.jsx(E.Box,{sx:{width:"30%",height:"10%",display:"flex",alignItems:"center",justifyContent:"center",borderRadius:"6px",background:"#FFFFFF",overflow:"hidden",...re.thumbnailSx},children:m.jsx("img",{src:_,alt:e.alt||e.label,style:{maxWidth:"100%",maxHeight:"100%"}})}),m.jsxs(E.Box,{sx:{flexGrow:1},children:[m.jsx(E.Typography,{sx:{fontSize:"12px",fontWeight:500,...re.fileNameSx},children:typeof _=="string"?_.split("/").pop():"Selected image"}),m.jsx(E.Typography,{sx:{fontSize:"10px",...re.fileMetaSx},children:"Image selected"})]}),m.jsxs(E.Box,{sx:{display:"flex",gap:1},children:[m.jsx(E.Button,{type:"button",sx:{...re.previewButtonSx},variant:"outlined",onClick:Z,startIcon:m.jsx(os,{}),children:Oe}),m.jsx(E.Button,{variant:"outlined",color:"error",onClick:F,sx:{...re.removeButtonSx},startIcon:m.jsx(ss,{}),children:x}),T&&m.jsx(E.Button,{variant:"contained",onClick:$,sx:{...re.saveButtonSx},children:O})]})]}),m.jsxs(E.Dialog,{open:b,onClose:()=>y(!1),maxWidth:"md",fullWidth:!0,children:[m.jsx(E.DialogTitle,{children:re.previewTitle||"Image preview"}),m.jsx(E.DialogContent,{children:m.jsx(E.Box,{sx:{display:"flex",alignItems:"center",justifyContent:"center",borderRadius:"8px",border:"1px solid",borderColor:"divider",backgroundColor:"background.paper",p:1,minHeight:260},children:m.jsx("img",{src:_,alt:e.alt||e.label,style:{maxWidth:"100%",maxHeight:380}})})}),m.jsxs(E.DialogActions,{children:[m.jsx(E.Button,{type:"button",variant:"outlined",onClick:()=>{var le;return(le=j.current)==null?void 0:le.click()},children:re.replaceText||"Replace logo"}),m.jsx(E.Button,{type:"button",variant:"contained",onClick:()=>y(!1),children:re.closeText||"Close"})]})]})]})}const Q=e.imagePlaceholder||{},fe=Q.icon||"upload",xe=j,Be=()=>{var re;try{(re=xe.current)==null||re.click()}catch{}},Le=re=>{const Oe=re.target.files&&re.target.files[0];if(Oe){typeof e.onFileSelected=="function"&&e.onFileSelected(Oe);try{const x=URL.createObjectURL(Oe);D.onChange(x)}catch{}R.current=Oe}};return m.jsxs(E.Card,{sx:{border:"1px dashed",borderColor:"#CCCCCC",boxShadow:"none",p:2,textAlign:"center",color:"primary.main",...Q.sx},children:[m.jsx("input",{type:"file",ref:xe,accept:Array.isArray(e.accept)?e.accept.join(","):e.accept||"image/*",style:{display:"none"},onChange:Le}),m.jsx(Ln,{sx:{borderRadius:"8px",...Q.iconSx},children:fe==="image"?m.jsx(ah,{sx:{width:36,height:36,color:"primary.main"}}):m.jsx(ni,{sx:{width:36,height:36,color:"primary.main"}})}),m.jsx(E.Typography,{sx:{fontSize:"16px",fontWeight:600,color:"primary.main",...Q.titleSx},children:Q.title||"Drag & Drop the image here"}),m.jsx(E.Typography,{sx:{fontSize:"12px",fontWeight:400,color:"primary.main",...Q.subtitleSx},children:Q.subtitle||""}),m.jsx(E.Button,{onClick:Be,sx:{my:2,...Q.buttonSx},startIcon:m.jsx(ni,{}),variant:"contained",disabled:e.disabled,children:Q.buttonText||"Upload File"}),m.jsx(E.Typography,{sx:{fontSize:"12px",fontWeight:400,...Q.helperTextSx},children:Q.helperText||e.helperText||""})]})}});case"component":return m.jsx(E.Box,{children:e.render?e.render():e.content});default:return null}},me=P.useMemo(()=>!e.disabled||e.copyWhenDisabled===!1?!1:!["title","section","image","component"].includes(e.type),[e.disabled,e.copyWhenDisabled,e.type]),se=P.useCallback(async()=>{try{const L=a?a[e.name]:void 0;let X="";L==null?X="":Array.isArray(L)?X=L.join(", "):typeof L=="object"?X=JSON.stringify(L):X=String(L),await navigator.clipboard.writeText(X),c(!0),window.setTimeout(()=>c(!1),1200)}catch{}},[a,e.name]);return m.jsxs(E.Box,{sx:{display:"flex",alignItems:"center",gap:.3},children:[m.jsx(E.Box,{sx:{flexGrow:1},children:z?ce():null}),me&&m.jsx(Ln,{"aria-label":`copy ${e.label||e.name}`,onClick:se,size:"small",children:S?m.jsx(qa,{fontSize:"small"}):m.jsx(ih,{fontSize:"small"})})]})};var $i,cs;function wh(){if(cs)return $i;cs=1;function e(y){this._maxSize=y,this.clear()}e.prototype.clear=function(){this._size=0,this._values=Object.create(null)},e.prototype.get=function(y){return this._values[y]},e.prototype.set=function(y,j){return this._size>=this._maxSize&&this.clear(),y in this._values||this._size++,this._values[y]=j};var t=/[^.^\]^[]+|(?=\[\]|\.\.)/g,r=/^\d+$/,n=/^\d/,i=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,a=/^\s*(['"]?)(.*?)(\1)\s*$/,o=512,s=new e(o),l=new e(o),p=new e(o);$i={Cache:e,split:d,normalizePath:u,setter:function(y){var j=u(y);return l.get(y)||l.set(y,function(k,v){for(var B=0,A=j.length,H=k;B<A-1;){var U=j[B];if(U==="__proto__"||U==="constructor"||U==="prototype")return k;H=H[j[B++]]}H[j[B]]=v})},getter:function(y,j){var R=u(y);return p.get(y)||p.set(y,function(v){for(var B=0,A=R.length;B<A;)if(v!=null||!j)v=v[R[B++]];else return;return v})},join:function(y){return y.reduce(function(j,R){return j+(g(R)||r.test(R)?"["+R+"]":(j?".":"")+R)},"")},forEach:function(y,j,R){f(Array.isArray(y)?y:d(y),j,R)}};function u(y){return s.get(y)||s.set(y,d(y).map(function(j){return j.replace(a,"$2")}))}function d(y){return y.match(t)||[""]}function f(y,j,R){var k=y.length,v,B,A,H;for(B=0;B<k;B++)v=y[B],v&&(b(v)&&(v='"'+v+'"'),H=g(v),A=!H&&/^\d+$/.test(v),j.call(R,v,H,A,B,y))}function g(y){return typeof y=="string"&&y&&["'",'"'].indexOf(y.charAt(0))!==-1}function S(y){return y.match(n)&&!y.match(r)}function c(y){return i.test(y)}function b(y){return!g(y)&&(S(y)||c(y))}return $i}var vr=wh(),Di,us;function Sh(){if(us)return Di;us=1;const e=/[A-Z\xc0-\xd6\xd8-\xde]?[a-z\xdf-\xf6\xf8-\xff]+(?:['’](?:d|ll|m|re|s|t|ve))?(?=[\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000]|[A-Z\xc0-\xd6\xd8-\xde]|$)|(?:[A-Z\xc0-\xd6\xd8-\xde]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])+(?:['’](?:D|LL|M|RE|S|T|VE))?(?=[\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000]|[A-Z\xc0-\xd6\xd8-\xde](?:[a-z\xdf-\xf6\xf8-\xff]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])|$)|[A-Z\xc0-\xd6\xd8-\xde]?(?:[a-z\xdf-\xf6\xf8-\xff]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])+(?:['’](?:d|ll|m|re|s|t|ve))?|[A-Z\xc0-\xd6\xd8-\xde]+(?:['’](?:D|LL|M|RE|S|T|VE))?|\d*(?:1ST|2ND|3RD|(?![123])\dTH)(?=\b|[a-z_])|\d*(?:1st|2nd|3rd|(?![123])\dth)(?=\b|[A-Z_])|\d+|(?:[\u2700-\u27bf]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff])[\ufe0e\ufe0f]?(?:[\u0300-\u036f\ufe20-\ufe2f\u20d0-\u20ff]|\ud83c[\udffb-\udfff])?(?:\u200d(?:[^\ud800-\udfff]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff])[\ufe0e\ufe0f]?(?:[\u0300-\u036f\ufe20-\ufe2f\u20d0-\u20ff]|\ud83c[\udffb-\udfff])?)*/g,t=u=>u.match(e)||[],r=u=>u[0].toUpperCase()+u.slice(1),n=(u,d)=>t(u).join(d).toLowerCase(),i=u=>t(u).reduce((d,f)=>`${d}${d?f[0].toUpperCase()+f.slice(1).toLowerCase():f.toLowerCase()}`,"");return Di={words:t,upperFirst:r,camelCase:i,pascalCase:u=>r(i(u)),snakeCase:u=>n(u,"_"),kebabCase:u=>n(u,"-"),sentenceCase:u=>r(n(u," ")),titleCase:u=>t(u).map(r).join(" ")},Di}var Pi=Sh(),Pn={exports:{}},ps;function Ch(){if(ps)return Pn.exports;ps=1,Pn.exports=function(i){return e(t(i),i)},Pn.exports.array=e;function e(i,a){var o=i.length,s=new Array(o),l={},p=o,u=r(a),d=n(i);for(a.forEach(function(g){if(!d.has(g[0])||!d.has(g[1]))throw new Error("Unknown node. There is an unknown node in the supplied edges.")});p--;)l[p]||f(i[p],p,new Set);return s;function f(g,S,c){if(c.has(g)){var b;try{b=", node was:"+JSON.stringify(g)}catch{b=""}throw new Error("Cyclic dependency"+b)}if(!d.has(g))throw new Error("Found unknown node. Make sure to provided all involved nodes. Unknown node: "+JSON.stringify(g));if(!l[S]){l[S]=!0;var y=u.get(g)||new Set;if(y=Array.from(y),S=y.length){c.add(g);do{var j=y[--S];f(j,d.get(j),c)}while(S);c.delete(g)}s[--o]=g}}}function t(i){for(var a=new Set,o=0,s=i.length;o<s;o++){var l=i[o];a.add(l[0]),a.add(l[1])}return Array.from(a)}function r(i){for(var a=new Map,o=0,s=i.length;o<s;o++){var l=i[o];a.has(l[0])||a.set(l[0],new Set),a.has(l[1])||a.set(l[1],new Set),a.get(l[0]).add(l[1])}return a}function n(i){for(var a=new Map,o=0,s=i.length;o<s;o++)a.set(i[o],o);return a}return Pn.exports}var Eh=Ch();const kh=Aa(Eh),Th=Object.prototype.toString,Oh=Error.prototype.toString,jh=RegExp.prototype.toString,Fh=typeof Symbol<"u"?Symbol.prototype.toString:()=>"",Ah=/^Symbol\((.*)\)(.*)$/;function _h(e){return e!=+e?"NaN":e===0&&1/e<0?"-0":""+e}function ds(e,t=!1){if(e==null||e===!0||e===!1)return""+e;const r=typeof e;if(r==="number")return _h(e);if(r==="string")return t?`"${e}"`:e;if(r==="function")return"[Function "+(e.name||"anonymous")+"]";if(r==="symbol")return Fh.call(e).replace(Ah,"Symbol($1)");const n=Th.call(e).slice(8,-1);return n==="Date"?isNaN(e.getTime())?""+e:e.toISOString(e):n==="Error"||e instanceof Error?"["+Oh.call(e)+"]":n==="RegExp"?jh.call(e):null}function Jt(e,t){let r=ds(e,t);return r!==null?r:JSON.stringify(e,function(n,i){let a=ds(this[n],t);return a!==null?a:i},2)}function Ll(e){return e==null?[]:[].concat(e)}let ql,Ul,Wl,Rh=/\$\{\s*(\w+)\s*\}/g;ql=Symbol.toStringTag;class fs{constructor(t,r,n,i){this.name=void 0,this.message=void 0,this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=void 0,this.inner=void 0,this[ql]="Error",this.name="ValidationError",this.value=r,this.path=n,this.type=i,this.errors=[],this.inner=[],Ll(t).forEach(a=>{if(et.isError(a)){this.errors.push(...a.errors);const o=a.inner.length?a.inner:[a];this.inner.push(...o)}else this.errors.push(a)}),this.message=this.errors.length>1?`${this.errors.length} errors occurred`:this.errors[0]}}Ul=Symbol.hasInstance;Wl=Symbol.toStringTag;class et extends Error{static formatError(t,r){const n=r.label||r.path||"this";return r=Object.assign({},r,{path:n,originalPath:r.path}),typeof t=="string"?t.replace(Rh,(i,a)=>Jt(r[a])):typeof t=="function"?t(r):t}static isError(t){return t&&t.name==="ValidationError"}constructor(t,r,n,i,a){const o=new fs(t,r,n,i);if(a)return o;super(),this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=[],this.inner=[],this[Wl]="Error",this.name=o.name,this.message=o.message,this.type=o.type,this.value=o.value,this.path=o.path,this.errors=o.errors,this.inner=o.inner,Error.captureStackTrace&&Error.captureStackTrace(this,et)}static[Ul](t){return fs[Symbol.hasInstance](t)||super[Symbol.hasInstance](t)}}let Ct={default:"${path} is invalid",required:"${path} is a required field",defined:"${path} must be defined",notNull:"${path} cannot be null",oneOf:"${path} must be one of the following values: ${values}",notOneOf:"${path} must not be one of the following values: ${values}",notType:({path:e,type:t,value:r,originalValue:n})=>{const i=n!=null&&n!==r?` (cast from the value \`${Jt(n,!0)}\`).`:".";return t!=="mixed"?`${e} must be a \`${t}\` type, but the final value was: \`${Jt(r,!0)}\``+i:`${e} must match the configured type. The validated value was: \`${Jt(r,!0)}\``+i}},Ge={length:"${path} must be exactly ${length} characters",min:"${path} must be at least ${min} characters",max:"${path} must be at most ${max} characters",matches:'${path} must match the following: "${regex}"',email:"${path} must be a valid email",url:"${path} must be a valid URL",uuid:"${path} must be a valid UUID",datetime:"${path} must be a valid ISO date-time",datetime_precision:"${path} must be a valid ISO date-time with a sub-second precision of exactly ${precision} digits",datetime_offset:'${path} must be a valid ISO date-time with UTC "Z" timezone',trim:"${path} must be a trimmed string",lowercase:"${path} must be a lowercase string",uppercase:"${path} must be a upper case string"},Nt={min:"${path} must be greater than or equal to ${min}",max:"${path} must be less than or equal to ${max}",lessThan:"${path} must be less than ${less}",moreThan:"${path} must be greater than ${more}",positive:"${path} must be a positive number",negative:"${path} must be a negative number",integer:"${path} must be an integer"},da={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"},fa={isValue:"${path} field must be ${value}"},qn={noUnknown:"${path} field has unspecified keys: ${unknown}",exact:"${path} object contains unknown properties: ${properties}"},$h={min:"${path} field must have at least ${min} items",max:"${path} field must have less than or equal to ${max} items",length:"${path} must have ${length} items"},Dh={notType:e=>{const{path:t,value:r,spec:n}=e,i=n.types.length;if(Array.isArray(r)){if(r.length<i)return`${t} tuple value has too few items, expected a length of ${i} but got ${r.length} for value: \`${Jt(r,!0)}\``;if(r.length>i)return`${t} tuple value has too many items, expected a length of ${i} but got ${r.length} for value: \`${Jt(r,!0)}\``}return et.formatError(Ct.notType,e)}};Object.assign(Object.create(null),{mixed:Ct,string:Ge,number:Nt,date:da,object:qn,array:$h,boolean:fa,tuple:Dh});const Ha=e=>e&&e.__isYupSchema__;class ii{static fromOptions(t,r){if(!r.then&&!r.otherwise)throw new TypeError("either `then:` or `otherwise:` is required for `when()` conditions");let{is:n,then:i,otherwise:a}=r,o=typeof n=="function"?n:(...s)=>s.every(l=>l===n);return new ii(t,(s,l)=>{var p;let u=o(...s)?i:a;return(p=u==null?void 0:u(l))!=null?p:l})}constructor(t,r){this.fn=void 0,this.refs=t,this.refs=t,this.fn=r}resolve(t,r){let n=this.refs.map(a=>a.getValue(r==null?void 0:r.value,r==null?void 0:r.parent,r==null?void 0:r.context)),i=this.fn(n,t,r);if(i===void 0||i===t)return t;if(!Ha(i))throw new TypeError("conditions must return a schema object");return i.resolve(r)}}const In={context:"$",value:"."};class kr{constructor(t,r={}){if(this.key=void 0,this.isContext=void 0,this.isValue=void 0,this.isSibling=void 0,this.path=void 0,this.getter=void 0,this.map=void 0,typeof t!="string")throw new TypeError("ref must be a string, got: "+t);if(this.key=t.trim(),t==="")throw new TypeError("ref must be a non-empty string");this.isContext=this.key[0]===In.context,this.isValue=this.key[0]===In.value,this.isSibling=!this.isContext&&!this.isValue;let n=this.isContext?In.context:this.isValue?In.value:"";this.path=this.key.slice(n.length),this.getter=this.path&&vr.getter(this.path,!0),this.map=r.map}getValue(t,r,n){let i=this.isContext?n:this.isValue?t:r;return this.getter&&(i=this.getter(i||{})),this.map&&(i=this.map(i)),i}cast(t,r){return this.getValue(t,r==null?void 0:r.parent,r==null?void 0:r.context)}resolve(){return this}describe(){return{type:"ref",key:this.key}}toString(){return`Ref(${this.key})`}static isRef(t){return t&&t.__isYupRef}}kr.prototype.__isYupRef=!0;const vt=e=>e==null;function Pr(e){function t({value:r,path:n="",options:i,originalValue:a,schema:o},s,l){const{name:p,test:u,params:d,message:f,skipAbsent:g}=e;let{parent:S,context:c,abortEarly:b=o.spec.abortEarly,disableStackTrace:y=o.spec.disableStackTrace}=i;function j(z){return kr.isRef(z)?z.getValue(r,S,c):z}function R(z={}){const M=Object.assign({value:r,originalValue:a,label:o.spec.label,path:z.path||n,spec:o.spec,disableStackTrace:z.disableStackTrace||y},d,z.params);for(const N of Object.keys(M))M[N]=j(M[N]);const q=new et(et.formatError(z.message||f,M),r,M.path,z.type||p,M.disableStackTrace);return q.params=M,q}const k=b?s:l;let v={path:n,parent:S,type:p,from:i.from,createError:R,resolve:j,options:i,originalValue:a,schema:o};const B=z=>{et.isError(z)?k(z):z?l(null):k(R())},A=z=>{et.isError(z)?k(z):s(z)};if(g&&vt(r))return B(!0);let U;try{var h;if(U=u.call(v,r,v),typeof((h=U)==null?void 0:h.then)=="function"){if(i.sync)throw new Error(`Validation test of type: "${v.type}" returned a Promise during a synchronous validate. This test will finish after the validate call has returned`);return Promise.resolve(U).then(B,A)}}catch(z){A(z);return}B(U)}return t.OPTIONS=e,t}function Ph(e,t,r,n=r){let i,a,o;return t?(vr.forEach(t,(s,l,p)=>{let u=l?s.slice(1,s.length-1):s;e=e.resolve({context:n,parent:i,value:r});let d=e.type==="tuple",f=p?parseInt(u,10):0;if(e.innerType||d){if(d&&!p)throw new Error(`Yup.reach cannot implicitly index into a tuple type. the path part "${o}" must contain an index to the tuple element, e.g. "${o}[0]"`);if(r&&f>=r.length)throw new Error(`Yup.reach cannot resolve an array item at index: ${s}, in the path: ${t}. because there is no value at that index. `);i=r,r=r&&r[f],e=d?e.spec.types[f]:e.innerType}if(!p){if(!e.fields||!e.fields[u])throw new Error(`The schema does not contain the path: ${t}. (failed at: ${o} which is a type: "${e.type}")`);i=r,r=r&&r[u],e=e.fields[u]}a=u,o=l?"["+s+"]":"."+s}),{schema:e,parent:i,parentPath:a}):{parent:i,parentPath:t,schema:e}}class ai extends Set{describe(){const t=[];for(const r of this.values())t.push(kr.isRef(r)?r.describe():r);return t}resolveAll(t){let r=[];for(const n of this.values())r.push(t(n));return r}clone(){return new ai(this.values())}merge(t,r){const n=this.clone();return t.forEach(i=>n.add(i)),r.forEach(i=>n.delete(i)),n}}function Ir(e,t=new Map){if(Ha(e)||!e||typeof e!="object")return e;if(t.has(e))return t.get(e);let r;if(e instanceof Date)r=new Date(e.getTime()),t.set(e,r);else if(e instanceof RegExp)r=new RegExp(e),t.set(e,r);else if(Array.isArray(e)){r=new Array(e.length),t.set(e,r);for(let n=0;n<e.length;n++)r[n]=Ir(e[n],t)}else if(e instanceof Map){r=new Map,t.set(e,r);for(const[n,i]of e.entries())r.set(n,Ir(i,t))}else if(e instanceof Set){r=new Set,t.set(e,r);for(const n of e)r.add(Ir(n,t))}else if(e instanceof Object){r={},t.set(e,r);for(const[n,i]of Object.entries(e))r[n]=Ir(i,t)}else throw Error(`Unable to clone ${e}`);return r}class at{constructor(t){this.type=void 0,this.deps=[],this.tests=void 0,this.transforms=void 0,this.conditions=[],this._mutate=void 0,this.internalTests={},this._whitelist=new ai,this._blacklist=new ai,this.exclusiveTests=Object.create(null),this._typeCheck=void 0,this.spec=void 0,this.tests=[],this.transforms=[],this.withMutation(()=>{this.typeError(Ct.notType)}),this.type=t.type,this._typeCheck=t.check,this.spec=Object.assign({strip:!1,strict:!1,abortEarly:!0,recursive:!0,disableStackTrace:!1,nullable:!1,optional:!0,coerce:!0},t==null?void 0:t.spec),this.withMutation(r=>{r.nonNullable()})}get _type(){return this.type}clone(t){if(this._mutate)return t&&Object.assign(this.spec,t),this;const r=Object.create(Object.getPrototypeOf(this));return r.type=this.type,r._typeCheck=this._typeCheck,r._whitelist=this._whitelist.clone(),r._blacklist=this._blacklist.clone(),r.internalTests=Object.assign({},this.internalTests),r.exclusiveTests=Object.assign({},this.exclusiveTests),r.deps=[...this.deps],r.conditions=[...this.conditions],r.tests=[...this.tests],r.transforms=[...this.transforms],r.spec=Ir(Object.assign({},this.spec,t)),r}label(t){let r=this.clone();return r.spec.label=t,r}meta(...t){if(t.length===0)return this.spec.meta;let r=this.clone();return r.spec.meta=Object.assign(r.spec.meta||{},t[0]),r}withMutation(t){let r=this._mutate;this._mutate=!0;let n=t(this);return this._mutate=r,n}concat(t){if(!t||t===this)return this;if(t.type!==this.type&&this.type!=="mixed")throw new TypeError(`You cannot \`concat()\` schema's of different types: ${this.type} and ${t.type}`);let r=this,n=t.clone();const i=Object.assign({},r.spec,n.spec);return n.spec=i,n.internalTests=Object.assign({},r.internalTests,n.internalTests),n._whitelist=r._whitelist.merge(t._whitelist,t._blacklist),n._blacklist=r._blacklist.merge(t._blacklist,t._whitelist),n.tests=r.tests,n.exclusiveTests=r.exclusiveTests,n.withMutation(a=>{t.tests.forEach(o=>{a.test(o.OPTIONS)})}),n.transforms=[...r.transforms,...n.transforms],n}isType(t){return t==null?!!(this.spec.nullable&&t===null||this.spec.optional&&t===void 0):this._typeCheck(t)}resolve(t){let r=this;if(r.conditions.length){let n=r.conditions;r=r.clone(),r.conditions=[],r=n.reduce((i,a)=>a.resolve(i,t),r),r=r.resolve(t)}return r}resolveOptions(t){var r,n,i,a;return Object.assign({},t,{from:t.from||[],strict:(r=t.strict)!=null?r:this.spec.strict,abortEarly:(n=t.abortEarly)!=null?n:this.spec.abortEarly,recursive:(i=t.recursive)!=null?i:this.spec.recursive,disableStackTrace:(a=t.disableStackTrace)!=null?a:this.spec.disableStackTrace})}cast(t,r={}){let n=this.resolve(Object.assign({value:t},r)),i=r.assert==="ignore-optionality",a=n._cast(t,r);if(r.assert!==!1&&!n.isType(a)){if(i&&vt(a))return a;let o=Jt(t),s=Jt(a);throw new TypeError(`The value of ${r.path||"field"} could not be cast to a value that satisfies the schema type: "${n.type}".
177
177
 
178
178
  attempted value: ${o}
179
- `+(s!==o?`result of cast: ${s}`:""))}return a}_cast(t,r){let n=t===void 0?t:this.transforms.reduce((i,a)=>a.call(this,i,t,this),t);return n===void 0&&(n=this.getDefault(r)),n}_validate(t,r={},n,i){let{path:a,originalValue:o=t,strict:s=this.spec.strict}=r,l=t;s||(l=this._cast(l,Object.assign({assert:!1},r)));let p=[];for(let u of Object.values(this.internalTests))u&&p.push(u);this.runTests({path:a,value:l,originalValue:o,options:r,tests:p},n,u=>{if(u.length)return i(u,l);this.runTests({path:a,value:l,originalValue:o,options:r,tests:this.tests},n,i)})}runTests(t,r,n){let i=!1,{tests:a,value:o,originalValue:s,path:l,options:p}=t,u=c=>{i||(i=!0,r(c,o))},d=c=>{i||(i=!0,n(c,o))},f=a.length,y=[];if(!f)return d([]);let S={value:o,originalValue:s,path:l,options:p,schema:this};for(let c=0;c<a.length;c++){const b=a[c];b(S,u,function(O){O&&(Array.isArray(O)?y.push(...O):y.push(O)),--f<=0&&d(y)})}}asNestedTest({key:t,index:r,parent:n,parentPath:i,originalParent:a,options:o}){const s=t??r;if(s==null)throw TypeError("Must include `key` or `index` for nested validations");const l=typeof s=="number";let p=n[s];const u=Object.assign({},o,{strict:!0,parent:n,value:p,originalValue:a[s],key:void 0,[l?"index":"key"]:s,path:l||s.includes(".")?`${i||""}[${l?s:`"${s}"`}]`:(i?`${i}.`:"")+t});return(d,f,y)=>this.resolve(u)._validate(p,u,f,y)}validate(t,r){var n;let i=this.resolve(Object.assign({},r,{value:t})),a=(n=r==null?void 0:r.disableStackTrace)!=null?n:i.spec.disableStackTrace;return new Promise((o,s)=>i._validate(t,r,(l,p)=>{et.isError(l)&&(l.value=p),s(l)},(l,p)=>{l.length?s(new et(l,p,void 0,void 0,a)):o(p)}))}validateSync(t,r){var n;let i=this.resolve(Object.assign({},r,{value:t})),a,o=(n=r==null?void 0:r.disableStackTrace)!=null?n:i.spec.disableStackTrace;return i._validate(t,Object.assign({},r,{sync:!0}),(s,l)=>{throw et.isError(s)&&(s.value=l),s},(s,l)=>{if(s.length)throw new et(s,t,void 0,void 0,o);a=l}),a}isValid(t,r){return this.validate(t,r).then(()=>!0,n=>{if(et.isError(n))return!1;throw n})}isValidSync(t,r){try{return this.validateSync(t,r),!0}catch(n){if(et.isError(n))return!1;throw n}}_getDefault(t){let r=this.spec.default;return r==null?r:typeof r=="function"?r.call(this,t):Ir(r)}getDefault(t){return this.resolve(t||{})._getDefault(t)}default(t){return arguments.length===0?this._getDefault():this.clone({default:t})}strict(t=!0){return this.clone({strict:t})}nullability(t,r){const n=this.clone({nullable:t});return n.internalTests.nullable=Pr({message:r,name:"nullable",test(i){return i===null?this.schema.spec.nullable:!0}}),n}optionality(t,r){const n=this.clone({optional:t});return n.internalTests.optionality=Pr({message:r,name:"optionality",test(i){return i===void 0?this.schema.spec.optional:!0}}),n}optional(){return this.optionality(!0)}defined(t=Ct.defined){return this.optionality(!1,t)}nullable(){return this.nullability(!0)}nonNullable(t=Ct.notNull){return this.nullability(!1,t)}required(t=Ct.required){return this.clone().withMutation(r=>r.nonNullable(t).defined(t))}notRequired(){return this.clone().withMutation(t=>t.nullable().optional())}transform(t){let r=this.clone();return r.transforms.push(t),r}test(...t){let r;if(t.length===1?typeof t[0]=="function"?r={test:t[0]}:r=t[0]:t.length===2?r={name:t[0],test:t[1]}:r={name:t[0],message:t[1],test:t[2]},r.message===void 0&&(r.message=Ct.default),typeof r.test!="function")throw new TypeError("`test` is a required parameters");let n=this.clone(),i=Pr(r),a=r.exclusive||r.name&&n.exclusiveTests[r.name]===!0;if(r.exclusive&&!r.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return r.name&&(n.exclusiveTests[r.name]=!!r.exclusive),n.tests=n.tests.filter(o=>!(o.OPTIONS.name===r.name&&(a||o.OPTIONS.test===i.OPTIONS.test))),n.tests.push(i),n}when(t,r){!Array.isArray(t)&&typeof t!="string"&&(r=t,t=".");let n=this.clone(),i=Ll(t).map(a=>new kr(a));return i.forEach(a=>{a.isSibling&&n.deps.push(a.key)}),n.conditions.push(typeof r=="function"?new ii(i,r):ii.fromOptions(i,r)),n}typeError(t){let r=this.clone();return r.internalTests.typeError=Pr({message:t,name:"typeError",skipAbsent:!0,test(n){return this.schema._typeCheck(n)?!0:this.createError({params:{type:this.schema.type}})}}),r}oneOf(t,r=Ct.oneOf){let n=this.clone();return t.forEach(i=>{n._whitelist.add(i),n._blacklist.delete(i)}),n.internalTests.whiteList=Pr({message:r,name:"oneOf",skipAbsent:!0,test(i){let a=this.schema._whitelist,o=a.resolveAll(this.resolve);return o.includes(i)?!0:this.createError({params:{values:Array.from(a).join(", "),resolved:o}})}}),n}notOneOf(t,r=Ct.notOneOf){let n=this.clone();return t.forEach(i=>{n._blacklist.add(i),n._whitelist.delete(i)}),n.internalTests.blacklist=Pr({message:r,name:"notOneOf",test(i){let a=this.schema._blacklist,o=a.resolveAll(this.resolve);return o.includes(i)?this.createError({params:{values:Array.from(a).join(", "),resolved:o}}):!0}}),n}strip(t=!0){let r=this.clone();return r.spec.strip=t,r}describe(t){const r=(t?this.resolve(t):this).clone(),{label:n,meta:i,optional:a,nullable:o}=r.spec;return{meta:i,label:n,optional:a,nullable:o,default:r.getDefault(t),type:r.type,oneOf:r._whitelist.describe(),notOneOf:r._blacklist.describe(),tests:r.tests.map(l=>({name:l.OPTIONS.name,params:l.OPTIONS.params})).filter((l,p,u)=>u.findIndex(d=>d.name===l.name)===p)}}}at.prototype.__isYupSchema__=!0;for(const e of["validate","validateSync"])at.prototype[`${e}At`]=function(t,r,n={}){const{parent:i,parentPath:a,schema:o}=Ph(this,t,r,n.context);return o[e](i&&i[a],Object.assign({},n,{parent:i,path:t}))};for(const e of["equals","is"])at.prototype[e]=at.prototype.oneOf;for(const e of["not","nope"])at.prototype[e]=at.prototype.notOneOf;const Ih=()=>!0;function Hl(e){return new Kl(e)}class Kl extends at{constructor(t){super(typeof t=="function"?{type:"mixed",check:t}:Object.assign({type:"mixed",check:Ih},t))}}Hl.prototype=Kl.prototype;function Ql(){return new Yl}class Yl extends at{constructor(){super({type:"boolean",check(t){return t instanceof Boolean&&(t=t.valueOf()),typeof t=="boolean"}}),this.withMutation(()=>{this.transform((t,r,n)=>{if(n.spec.coerce&&!n.isType(t)){if(/^(true|1)$/i.test(String(t)))return!0;if(/^(false|0)$/i.test(String(t)))return!1}return t})})}isTrue(t=ua.isValue){return this.test({message:t,name:"is-value",exclusive:!0,params:{value:"true"},test(r){return xt(r)||r===!0}})}isFalse(t=ua.isValue){return this.test({message:t,name:"is-value",exclusive:!0,params:{value:"false"},test(r){return xt(r)||r===!1}})}default(t){return super.default(t)}defined(t){return super.defined(t)}optional(){return super.optional()}required(t){return super.required(t)}notRequired(){return super.notRequired()}nullable(){return super.nullable()}nonNullable(t){return super.nonNullable(t)}strip(t){return super.strip(t)}}Ql.prototype=Yl.prototype;const Mh=/^(\d{4}|[+-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,.](\d{1,}))?)?(?:(Z)|([+-])(\d{2})(?::?(\d{2}))?)?)?$/;function zh(e){const t=pa(e);if(!t)return Date.parse?Date.parse(e):Number.NaN;if(t.z===void 0&&t.plusMinus===void 0)return new Date(t.year,t.month,t.day,t.hour,t.minute,t.second,t.millisecond).valueOf();let r=0;return t.z!=="Z"&&t.plusMinus!==void 0&&(r=t.hourOffset*60+t.minuteOffset,t.plusMinus==="+"&&(r=0-r)),Date.UTC(t.year,t.month,t.day,t.hour,t.minute+r,t.second,t.millisecond)}function pa(e){var t,r;const n=Mh.exec(e);return n?{year:Dt(n[1]),month:Dt(n[2],1)-1,day:Dt(n[3],1),hour:Dt(n[4]),minute:Dt(n[5]),second:Dt(n[6]),millisecond:n[7]?Dt(n[7].substring(0,3)):0,precision:(t=(r=n[7])==null?void 0:r.length)!=null?t:void 0,z:n[8]||void 0,plusMinus:n[9]||void 0,hourOffset:Dt(n[10]),minuteOffset:Dt(n[11])}:null}function Dt(e,t=0){return Number(e)||t}let Vh=/^[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,Bh=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,Nh=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,Lh="^\\d{4}-\\d{2}-\\d{2}",qh="\\d{2}:\\d{2}:\\d{2}",Uh="(([+-]\\d{2}(:?\\d{2})?)|Z)",Wh=new RegExp(`${Lh}T${qh}(\\.\\d+)?${Uh}$`),Hh=e=>xt(e)||e===e.trim(),Kh={}.toString();function un(){return new Gl}class Gl extends at{constructor(){super({type:"string",check(t){return t instanceof String&&(t=t.valueOf()),typeof t=="string"}}),this.withMutation(()=>{this.transform((t,r,n)=>{if(!n.spec.coerce||n.isType(t)||Array.isArray(t))return t;const i=t!=null&&t.toString?t.toString():t;return i===Kh?t:i})})}required(t){return super.required(t).withMutation(r=>r.test({message:t||Ct.required,name:"required",skipAbsent:!0,test:n=>!!n.length}))}notRequired(){return super.notRequired().withMutation(t=>(t.tests=t.tests.filter(r=>r.OPTIONS.name!=="required"),t))}length(t,r=Ge.length){return this.test({message:r,name:"length",exclusive:!0,params:{length:t},skipAbsent:!0,test(n){return n.length===this.resolve(t)}})}min(t,r=Ge.min){return this.test({message:r,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(n){return n.length>=this.resolve(t)}})}max(t,r=Ge.max){return this.test({name:"max",exclusive:!0,message:r,params:{max:t},skipAbsent:!0,test(n){return n.length<=this.resolve(t)}})}matches(t,r){let n=!1,i,a;return r&&(typeof r=="object"?{excludeEmptyString:n=!1,message:i,name:a}=r:i=r),this.test({name:a||"matches",message:i||Ge.matches,params:{regex:t},skipAbsent:!0,test:o=>o===""&&n||o.search(t)!==-1})}email(t=Ge.email){return this.matches(Vh,{name:"email",message:t,excludeEmptyString:!0})}url(t=Ge.url){return this.matches(Bh,{name:"url",message:t,excludeEmptyString:!0})}uuid(t=Ge.uuid){return this.matches(Nh,{name:"uuid",message:t,excludeEmptyString:!1})}datetime(t){let r="",n,i;return t&&(typeof t=="object"?{message:r="",allowOffset:n=!1,precision:i=void 0}=t:r=t),this.matches(Wh,{name:"datetime",message:r||Ge.datetime,excludeEmptyString:!0}).test({name:"datetime_offset",message:r||Ge.datetime_offset,params:{allowOffset:n},skipAbsent:!0,test:a=>{if(!a||n)return!0;const o=pa(a);return o?!!o.z:!1}}).test({name:"datetime_precision",message:r||Ge.datetime_precision,params:{precision:i},skipAbsent:!0,test:a=>{if(!a||i==null)return!0;const o=pa(a);return o?o.precision===i:!1}})}ensure(){return this.default("").transform(t=>t===null?"":t)}trim(t=Ge.trim){return this.transform(r=>r!=null?r.trim():r).test({message:t,name:"trim",test:Hh})}lowercase(t=Ge.lowercase){return this.transform(r=>xt(r)?r:r.toLowerCase()).test({message:t,name:"string_case",exclusive:!0,skipAbsent:!0,test:r=>xt(r)||r===r.toLowerCase()})}uppercase(t=Ge.uppercase){return this.transform(r=>xt(r)?r:r.toUpperCase()).test({message:t,name:"string_case",exclusive:!0,skipAbsent:!0,test:r=>xt(r)||r===r.toUpperCase()})}}un.prototype=Gl.prototype;let Qh=e=>e!=+e;function Zl(){return new Xl}class Xl extends at{constructor(){super({type:"number",check(t){return t instanceof Number&&(t=t.valueOf()),typeof t=="number"&&!Qh(t)}}),this.withMutation(()=>{this.transform((t,r,n)=>{if(!n.spec.coerce)return t;let i=t;if(typeof i=="string"){if(i=i.replace(/\s/g,""),i==="")return NaN;i=+i}return n.isType(i)||i===null?i:parseFloat(i)})})}min(t,r=Nt.min){return this.test({message:r,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(n){return n>=this.resolve(t)}})}max(t,r=Nt.max){return this.test({message:r,name:"max",exclusive:!0,params:{max:t},skipAbsent:!0,test(n){return n<=this.resolve(t)}})}lessThan(t,r=Nt.lessThan){return this.test({message:r,name:"max",exclusive:!0,params:{less:t},skipAbsent:!0,test(n){return n<this.resolve(t)}})}moreThan(t,r=Nt.moreThan){return this.test({message:r,name:"min",exclusive:!0,params:{more:t},skipAbsent:!0,test(n){return n>this.resolve(t)}})}positive(t=Nt.positive){return this.moreThan(0,t)}negative(t=Nt.negative){return this.lessThan(0,t)}integer(t=Nt.integer){return this.test({name:"integer",message:t,skipAbsent:!0,test:r=>Number.isInteger(r)})}truncate(){return this.transform(t=>xt(t)?t:t|0)}round(t){var r;let n=["ceil","floor","round","trunc"];if(t=((r=t)==null?void 0:r.toLowerCase())||"round",t==="trunc")return this.truncate();if(n.indexOf(t.toLowerCase())===-1)throw new TypeError("Only valid options for round() are: "+n.join(", "));return this.transform(i=>xt(i)?i:Math[t](i))}}Zl.prototype=Xl.prototype;let Jl=new Date(""),Yh=e=>Object.prototype.toString.call(e)==="[object Date]";function Ua(){return new On}class On extends at{constructor(){super({type:"date",check(t){return Yh(t)&&!isNaN(t.getTime())}}),this.withMutation(()=>{this.transform((t,r,n)=>!n.spec.coerce||n.isType(t)||t===null?t:(t=zh(t),isNaN(t)?On.INVALID_DATE:new Date(t)))})}prepareParam(t,r){let n;if(kr.isRef(t))n=t;else{let i=this.cast(t);if(!this._typeCheck(i))throw new TypeError(`\`${r}\` must be a Date or a value that can be \`cast()\` to a Date`);n=i}return n}min(t,r=ca.min){let n=this.prepareParam(t,"min");return this.test({message:r,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(i){return i>=this.resolve(n)}})}max(t,r=ca.max){let n=this.prepareParam(t,"max");return this.test({message:r,name:"max",exclusive:!0,params:{max:t},skipAbsent:!0,test(i){return i<=this.resolve(n)}})}}On.INVALID_DATE=Jl;Ua.prototype=On.prototype;Ua.INVALID_DATE=Jl;function Gh(e,t=[]){let r=[],n=new Set,i=new Set(t.map(([o,s])=>`${o}-${s}`));function a(o,s){let l=vr.split(o)[0];n.add(l),i.has(`${s}-${l}`)||r.push([s,l])}for(const o of Object.keys(e)){let s=e[o];n.add(o),kr.isRef(s)&&s.isSibling?a(s.path,o):qa(s)&&"deps"in s&&s.deps.forEach(l=>a(l,o))}return kh.array(Array.from(n),r).reverse()}function ps(e,t){let r=1/0;return e.some((n,i)=>{var a;if((a=t.path)!=null&&a.includes(n))return r=i,!0}),r}function ec(e){return(t,r)=>ps(e,t)-ps(e,r)}const Zh=(e,t,r)=>{if(typeof e!="string")return e;let n=e;try{n=JSON.parse(e)}catch{}return r.isType(n)?n:e};function Un(e){if("fields"in e){const t={};for(const[r,n]of Object.entries(e.fields))t[r]=Un(n);return e.setFields(t)}if(e.type==="array"){const t=e.optional();return t.innerType&&(t.innerType=Un(t.innerType)),t}return e.type==="tuple"?e.optional().clone({types:e.spec.types.map(Un)}):"optional"in e?e.optional():e}const Xh=(e,t)=>{const r=[...vr.normalizePath(t)];if(r.length===1)return r[0]in e;let n=r.pop(),i=vr.getter(vr.join(r),!0)(e);return!!(i&&n in i)};let ds=e=>Object.prototype.toString.call(e)==="[object Object]";function fs(e,t){let r=Object.keys(e.fields);return Object.keys(t).filter(n=>r.indexOf(n)===-1)}const Jh=ec([]);function tc(e){return new rc(e)}class rc extends at{constructor(t){super({type:"object",check(r){return ds(r)||typeof r=="function"}}),this.fields=Object.create(null),this._sortErrors=Jh,this._nodes=[],this._excludedEdges=[],this.withMutation(()=>{t&&this.shape(t)})}_cast(t,r={}){var n;let i=super._cast(t,r);if(i===void 0)return this.getDefault(r);if(!this._typeCheck(i))return i;let a=this.fields,o=(n=r.stripUnknown)!=null?n:this.spec.noUnknown,s=[].concat(this._nodes,Object.keys(i).filter(d=>!this._nodes.includes(d))),l={},p=Object.assign({},r,{parent:l,__validating:r.__validating||!1}),u=!1;for(const d of s){let f=a[d],y=d in i;if(f){let S,c=i[d];p.path=(r.path?`${r.path}.`:"")+d,f=f.resolve({value:c,context:r.context,parent:l});let b=f instanceof at?f.spec:void 0,g=b==null?void 0:b.strict;if(b!=null&&b.strip){u=u||d in i;continue}S=!r.__validating||!g?f.cast(i[d],p):i[d],S!==void 0&&(l[d]=S)}else y&&!o&&(l[d]=i[d]);(y!==d in l||l[d]!==i[d])&&(u=!0)}return u?l:i}_validate(t,r={},n,i){let{from:a=[],originalValue:o=t,recursive:s=this.spec.recursive}=r;r.from=[{schema:this,value:o},...a],r.__validating=!0,r.originalValue=o,super._validate(t,r,n,(l,p)=>{if(!s||!ds(p)){i(l,p);return}o=o||p;let u=[];for(let d of this._nodes){let f=this.fields[d];!f||kr.isRef(f)||u.push(f.asNestedTest({options:r,key:d,parent:p,parentPath:r.path,originalParent:o}))}this.runTests({tests:u,value:p,originalValue:o,options:r},n,d=>{i(d.sort(this._sortErrors).concat(l),p)})})}clone(t){const r=super.clone(t);return r.fields=Object.assign({},this.fields),r._nodes=this._nodes,r._excludedEdges=this._excludedEdges,r._sortErrors=this._sortErrors,r}concat(t){let r=super.concat(t),n=r.fields;for(let[i,a]of Object.entries(this.fields)){const o=n[i];n[i]=o===void 0?a:o}return r.withMutation(i=>i.setFields(n,[...this._excludedEdges,...t._excludedEdges]))}_getDefault(t){if("default"in this.spec)return super._getDefault(t);if(!this._nodes.length)return;let r={};return this._nodes.forEach(n=>{var i;const a=this.fields[n];let o=t;(i=o)!=null&&i.value&&(o=Object.assign({},o,{parent:o.value,value:o.value[n]})),r[n]=a&&"getDefault"in a?a.getDefault(o):void 0}),r}setFields(t,r){let n=this.clone();return n.fields=t,n._nodes=Gh(t,r),n._sortErrors=ec(Object.keys(t)),r&&(n._excludedEdges=r),n}shape(t,r=[]){return this.clone().withMutation(n=>{let i=n._excludedEdges;return r.length&&(Array.isArray(r[0])||(r=[r]),i=[...n._excludedEdges,...r]),n.setFields(Object.assign(n.fields,t),i)})}partial(){const t={};for(const[r,n]of Object.entries(this.fields))t[r]="optional"in n&&n.optional instanceof Function?n.optional():n;return this.setFields(t)}deepPartial(){return Un(this)}pick(t){const r={};for(const n of t)this.fields[n]&&(r[n]=this.fields[n]);return this.setFields(r,this._excludedEdges.filter(([n,i])=>t.includes(n)&&t.includes(i)))}omit(t){const r=[];for(const n of Object.keys(this.fields))t.includes(n)||r.push(n);return this.pick(r)}from(t,r,n){let i=vr.getter(t,!0);return this.transform(a=>{if(!a)return a;let o=a;return Xh(a,t)&&(o=Object.assign({},a),n||delete o[t],o[r]=i(a)),o})}json(){return this.transform(Zh)}exact(t){return this.test({name:"exact",exclusive:!0,message:t||qn.exact,test(r){if(r==null)return!0;const n=fs(this.schema,r);return n.length===0||this.createError({params:{properties:n.join(", ")}})}})}stripUnknown(){return this.clone({noUnknown:!0})}noUnknown(t=!0,r=qn.noUnknown){typeof t!="boolean"&&(r=t,t=!0);let n=this.test({name:"noUnknown",exclusive:!0,message:r,test(i){if(i==null)return!0;const a=fs(this.schema,i);return!t||a.length===0||this.createError({params:{unknown:a.join(", ")}})}});return n.spec.noUnknown=t,n}unknown(t=!0,r=qn.noUnknown){return this.noUnknown(!t,r)}transformKeys(t){return this.transform(r=>{if(!r)return r;const n={};for(const i of Object.keys(r))n[t(i)]=r[i];return n})}camelCase(){return this.transformKeys(Pi.camelCase)}snakeCase(){return this.transformKeys(Pi.snakeCase)}constantCase(){return this.transformKeys(t=>Pi.snakeCase(t).toUpperCase())}describe(t){const r=(t?this.resolve(t):this).clone(),n=super.describe(t);n.fields={};for(const[a,o]of Object.entries(r.fields)){var i;let s=t;(i=s)!=null&&i.value&&(s=Object.assign({},s,{parent:s.value,value:s.value[a]})),n.fields[a]=o.describe(s)}return n}}tc.prototype=rc.prototype;const nc=e=>{const t={};return e.forEach(r=>{var a,o,s;let n;switch(r.type){case"text":case"textarea":case"tel":n=un(),r.validation?n=ar(n,r,"string"):(r.minLength&&(n=n.min(r.minLength,`${r.label} must be at least ${r.minLength} characters`)),r.maxLength&&(n=n.max(r.maxLength,`${r.label} must be at most ${r.maxLength} characters`)),r.pattern&&(n=n.test("pattern",`${r.label} format is invalid`,l=>l?new RegExp(r.pattern).test(l):!0)));break;case"email":n=un().email(((a=r.validation)==null?void 0:a.message)||`${r.label} must be a valid email address`),r.validation&&(n=ar(n,r,"string"));break;case"password":n=un(),r.validation?n=ar(n,r,"string"):(r.minLength&&(n=n.min(r.minLength,`${r.label} must be at least ${r.minLength} characters`)),r.maxLength&&(n=n.max(r.maxLength,`${r.label} must be at most ${r.maxLength} characters`)),r.pattern&&(n=n.test("pattern",`${r.label} format is invalid`,l=>l?new RegExp(r.pattern).test(l):!0)));break;case"number":n=Zl().typeError(`${r.label} must be a number`),r.validation?n=ar(n,r,"number"):(r.min!==void 0&&(n=n.min(r.min,`${r.label} must be at least ${r.min}`)),r.max!==void 0&&(n=n.max(r.max,`${r.label} must be at most ${r.max}`)));break;case"select":n=un(),r.validation&&(n=ar(n,r,"string"));break;case"checkbox":n=Ql(),r.validation&&(n=ar(n,r,"boolean"));break;case"date":n=Ua().typeError(`${r.label} must be a valid date`),r.validation?n=ar(n,r,"date"):(r.minDate&&(n=n.min(new Date(r.minDate),`${r.label} must be after ${r.minDate}`)),r.maxDate&&(n=n.max(new Date(r.maxDate),`${r.label} must be before ${r.maxDate}`)));break;default:n=Hl()}if(((o=r.validation)==null?void 0:o.required)!==void 0?r.validation.required:r.required){const l=((s=r.validation)==null?void 0:s.message)||`${r.label} is required`;n=n.required(l)}t[r.name]=n}),tc().shape(t)},ar=(e,t,r)=>{const n=t.validation;if(!n)return e;if(r==="string"){if(n.minLength!==void 0){const i=n.message||`${t.label} must be at least ${n.minLength} characters`;e=e.min(n.minLength,i)}if(n.maxLength!==void 0){const i=n.message||`${t.label} must be at most ${n.maxLength} characters`;e=e.max(n.maxLength,i)}}if(r==="number"){if(n.min!==void 0){const i=n.message||`${t.label} must be at least ${n.min}`;e=e.min(n.min,i)}if(n.max!==void 0){const i=n.message||`${t.label} must be at most ${n.max}`;e=e.max(n.max,i)}}if(n.pattern){const i=typeof n.pattern=="string"?new RegExp(n.pattern):n.pattern,a=n.message||`${t.label} format is invalid`;e=e.test("pattern",a,o=>o?i.test(o):!0)}return n.custom&&(e=e.test("custom",n.message||`${t.label} is invalid`,i=>{const a=n.custom(i);return typeof a=="boolean"?a:!1})),e},ic=({currentStep:e,totalSteps:t,onStepChange:r,stepTitles:n=[],showStepTitles:i=!0,completedSteps:a=[]})=>{const o=$.useMemo(()=>Array.from({length:t},(u,d)=>d+1),[t]),s=$.useMemo(()=>Math.round(e/t*100),[e,t]),l=u=>n[u-1]||`Step ${u}`,p=u=>u===e||a.includes(u)||u===e+1&&a.includes(e);return m.jsxs(E.Card,{sx:{mb:2,p:2,boxShadow:"0px 1px 4px 0px #00000014",background:"#F8F8F8",borderRadius:"4px"},children:[m.jsxs(E.Box,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between",mb:2},children:[m.jsx(E.Box,{sx:{display:"flex",alignItems:"center",flexWrap:"wrap"},children:o.map((u,d)=>{const f=u===e,y=u<e||a.includes(u),S=f||y?"primary.main":"#8F97A4";return m.jsxs(E.Box,{sx:{display:"flex",alignItems:"center"},children:[m.jsxs(E.Box,{onClick:()=>p(u)&&r(u),sx:{display:"flex",alignItems:"center",cursor:p(u)?"pointer":"default"},children:[m.jsx(E.Box,{sx:{width:24,height:24,borderRadius:"50%",border:f||y?"2px solid":"1px solid",borderColor:f||y?"primary.main":"#8F97A4",display:"flex",alignItems:"center",justifyContent:"center",backgroundColor:c=>f||y?Ft(c.palette.primary.main,.2):"transparent",mr:.5,color:S,fontWeight:f||y?600:500,fontSize:"12px"},children:u}),i&&m.jsx(E.Typography,{sx:{fontSize:"12px",fontWeight:600,color:S},children:l(u)})]}),d<o.length-1&&m.jsx(E.Box,{sx:{width:40,height:2,mx:1,borderRadius:1,backgroundColor:u<e?"primary.main":"#DFE3E8"}})]},u)})}),m.jsx(E.Typography,{sx:{color:"#8F97A4",fontSize:"12px",fontWeight:500},children:`Step ${e} of ${t}, ${s}% complete`})]}),m.jsx(E.LinearProgress,{variant:"determinate",value:s,sx:{height:4,borderRadius:"50px",backgroundColor:u=>u.palette.grey[300],"& .MuiLinearProgress-bar":{backgroundColor:"primary.main",borderRadius:5}}})]})},ac=({buttons:e,disabled:t=!1})=>{const r=s=>{s.onClick&&s.onClick()},n=e.filter(s=>s.position==="left"||!s.position),i=e.filter(s=>s.position==="center"),a=e.filter(s=>s.position==="right"),o=(s,l)=>{const p=(s.text||"").toLowerCase(),u=s.type==="submit"||p.includes("submit")||p.includes("save")||p.includes("next"),d=s.position==="left"||p.includes("cancel")||p.includes("back")||p.includes("draft"),f=s.type?s.type:u?"submit":"button",y=d?"outlined":"contained",S=s.disabled||t,c=b=>b&&["primary","secondary","error","info","success","warning"].includes(b)?b:"primary";return m.jsxs(E.Button,{type:f,variant:y,color:c(s.color),size:s.size||"large",disabled:S,onClick:s.onClick?()=>r(s):void 0,sx:s.sx,children:[s.loading&&m.jsx(E.CircularProgress,{size:20,sx:{mr:1}}),s.text]},`${s.text}-${l}`)};return m.jsxs(E.Box,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[m.jsx(E.Box,{sx:{display:"flex",gap:2},children:n.map((s,l)=>o(s,l))}),m.jsx(E.Box,{sx:{display:"flex",gap:2},children:i.map((s,l)=>o(s,l))}),m.jsx(E.Box,{sx:{display:"flex",gap:2},children:a.map((s,l)=>o(s,l))})]})},em=({config:e,onSubmit:t,onStepChange:r,currentStep:n=1,totalSteps:i=1,isMultiStep:a=!1,formData:o})=>{const{buttons:s,position:l="right",layout:p="horizontal",spacing:u=2,sx:d}=e,f=g=>{let O="button",A="contained";return g.type?O=g.type:g.text.toLowerCase().includes("submit")||g.text.toLowerCase().includes("save")||g.text.toLowerCase().includes("next")?O="submit":(g.text.toLowerCase().includes("reset")||g.text.toLowerCase().includes("clear"))&&(O="reset"),(g.text.toLowerCase().includes("cancel")||g.text.toLowerCase().includes("back")||g.text.toLowerCase().includes("draft"))&&(A="outlined"),{buttonType:O,buttonVariant:A}},y=g=>["primary","secondary","error","warning","info","success"].includes(g||"")?g:"primary",S=g=>{const{buttonType:O}=f(g);g.onClick?g.onClick():O==="submit"&&t?t(o):a&&r&&(g.text.toLowerCase().includes("next")?r(n+1,i):(g.text.toLowerCase().includes("back")||g.text.toLowerCase().includes("previous"))&&r(n-1,i))},c=(g,O)=>{const{buttonType:A,buttonVariant:k}=f(g),x=y(g.color);return m.jsx(E.Button,{type:A,variant:k,color:x,size:g.size||"medium",disabled:g.disabled,onClick:()=>S(g),sx:g.sx,children:g.text},O)},b=()=>{const g={display:"flex",gap:u,...d};switch(l){case"left":return{...g,justifyContent:"flex-start"};case"center":return{...g,justifyContent:"center"};case"right":return{...g,justifyContent:"flex-end"};case"space-between":return{...g,justifyContent:"space-between"};default:return{...g,justifyContent:"flex-end"}}};return p==="vertical"?m.jsx(E.Box,{sx:b(),children:s.map((g,O)=>m.jsx(E.Box,{sx:{width:"100%"},children:c(g,O)},O))}):m.jsx(E.Box,{sx:b(),children:m.jsx(E.ButtonGroup,{variant:"outlined",size:"medium",children:s.map((g,O)=>c(g,O))})})},tm=new lu({defaultOptions:{queries:{staleTime:15*60*1e3,gcTime:30*60*1e3,retry:3,retryDelay:e=>Math.min(1e3*2**e,3e4),refetchOnWindowFocus:!1,refetchOnReconnect:!0}}}),rm=e=>m.jsx(fu,{client:tm,children:m.jsx(nm,{...e})}),nm=({id:e,theme:t,fields:r,onSubmit:n,onChange:i,submitButtonText:a="Submit",onSubmitClick:o,defaultValues:s,showSubmitButton:l=!0,buttons:p,buttonGroup:u,baseUrl:d,apiHeaders:f,stepNavigationProps:y})=>{var fe,pe;const S=[...new Set(r.map(L=>L.step).filter(L=>L!=null&&L>0))].sort((L,I)=>(L||0)-(I||0)),c=S.length>1,b=S.length||1,[g,O]=$.useState(1),A=c?r.filter(L=>L.step===g):r,k=$.useMemo(()=>nc(A),[A]),{control:x,handleSubmit:B,formState:{errors:_},watch:K,setValue:W,resetField:h,trigger:M}=Nc({resolver:Uc(k),mode:"onChange",defaultValues:s}),P=K(),q=$.useRef({});$.useEffect(()=>{const L=[];for(const I of r){const z=I.depends_on;z&&typeof I.name=="string"&&L.push({dependentField:I.name,dependencyName:z})}if(L.length!==0)for(const{dependentField:I,dependencyName:z}of L){const ae=q.current[z],de=P==null?void 0:P[z];if(ae!==de)try{h(I)}catch{}q.current[z]=de}},[r,P,h]);const N=$.useRef(i);$.useEffect(()=>{N.current=i},[i]);const X=$.useMemo(()=>{try{return JSON.stringify(P)}catch{return String(Date.now())}},[P]),ie=$.useRef(null);$.useEffect(()=>{N.current&&ie.current!==X&&(ie.current=X,N.current(P))},[X]);const ge=async()=>{if(!c)return!0;const L=r.filter(z=>z.step===g);for(const z of L)if(z.required){const ae=P[z.name];let de=!0;if(z.type==="checkbox"?de=ae===!0:Array.isArray(ae)?de=ae.length>0:de=ae!=null&&ae!=="",!de)return!1}return await M()?!0:Object.keys(_).filter(ae=>L.some(de=>de.name===ae)).map(ae=>{const de=_[ae];return typeof(de==null?void 0:de.message)=="string"?de.message:`${ae} is invalid`}).length===0},ce=$.useMemo(()=>{if(!c)return!0;const L=r.filter(z=>z.step===g);for(const z of L)if(z.required){const ae=P[z.name];let de=!0;if(z.type==="checkbox"?de=ae===!0:Array.isArray(ae)?de=ae.length>0:de=ae!=null&&ae!=="",!de)return!1}return Object.keys(_).filter(z=>L.some(ae=>ae.name===z)).length===0},[c,g,r,P,_]),se=$.useMemo(()=>{if(c)return ce;for(const L of r)if(L.required){const I=P[L.name];let z=!0;if(L.type==="checkbox"?z=I===!0:z=I!=null&&I!==""&&!(Array.isArray(I)&&I.length===0),!z)return!1}return Object.keys(_).length===0},[c,ce,r,P,_]),V=async L=>{L<1||L>b||L>g&&c&&!await ge()||O(L)},H=async L=>{if(c&&g<b){console.warn("Form submission attempted on non-final step");return}o&&o(L),n(L)},ue=async L=>{L&&(L.preventDefault(),L.stopPropagation()),c&&g<b&&await ge()&&V(g+1)},Y=L=>{L&&(L.preventDefault(),L.stopPropagation()),c&&g>1&&V(g-1)},te=L=>L.col?L.col:(L.xs||L.sm||L.md||L.lg||L.xl)&&(L.xs||L.sm||L.md||L.lg||L.xl)||12,le=t?E.createTheme({palette:{primary:{main:t.primaryColor||"#1976d2"},secondary:{main:t.secondaryColor||"#dc004e"},background:{default:t.backgroundColor||"#ffffff"},text:{primary:t.textColor||"#000000"}},shape:{borderRadius:t.borderRadius||4},spacing:t.spacing||8,typography:{fontFamily:((fe=t.typography)==null?void 0:fe.fontFamily)||"Roboto, Arial, sans-serif",fontSize:typeof((pe=t.typography)==null?void 0:pe.fontSize)=="number"?t.typography.fontSize:14}}):void 0,U=()=>{if(u&&u.buttons&&u.buttons.length>0){const L={...u,buttons:u.buttons.map(I=>{const z=(I.text||"").toLowerCase(),ae=I.type==="submit"||z.includes("submit")||z.includes("save")||z.includes("finish")||z.includes("complete"),de=z.includes("next");let _e=!1;return c?(ae||de)&&(_e=!ce):ae&&(_e=!se),{...I,disabled:I.disabled||_e}})};return m.jsx(E.Box,{sx:{mt:3},children:m.jsx(em,{config:L,onSubmit:H,onStepChange:V,currentStep:g,totalSteps:b,isMultiStep:c,formData:P})})}if(p&&p.length>0){const L=p.map(I=>{const z=(I.text||"").toLowerCase(),ae=I.type==="submit"||z.includes("submit")||z.includes("save")||z.includes("finish")||z.includes("complete"),de=z.includes("next");let _e=!1;return c?(ae||de)&&(_e=!ce):ae&&(_e=!se),{...I,disabled:I.disabled||_e}});return m.jsx(ac,{buttons:L})}return l?m.jsx(E.Box,{sx:{mt:3,display:"flex",justifyContent:"flex-end",flexDirection:"column",alignItems:"flex-end"},children:m.jsxs(E.Box,{sx:{display:"flex",gap:2},children:[c&&g>1&&m.jsx(E.Button,{type:"button",variant:"outlined",onClick:Y,children:"Previous"}),c?g<b?m.jsx(E.Button,{type:"button",variant:"contained",color:"primary",size:"large",disabled:!ce,onClick:ue,children:"Next"}):m.jsx(E.Button,{type:"submit",variant:"contained",color:"primary",size:"large",disabled:!ce,children:a}):m.jsx(E.Button,{type:"submit",variant:"contained",color:"primary",size:"large",disabled:!se,children:a})]})}):null},ee=$.useMemo(()=>{const L=[];let I=[];for(const z of A)z.type==="section"&&I.length>0?(L.push(I),I=[z]):I.push(z);return I.length>0&&L.push(I),L},[A]),oe=m.jsxs(E.Box,{component:"form",onSubmit:L=>{if(c&&g<b){L.preventDefault(),L.stopPropagation(),ce&&ue();return}B(H)(L)},id:e,onKeyDown:L=>{L.key==="Enter"&&c&&g<b&&(L.preventDefault(),ce&&ue())},children:[c&&m.jsx(ic,{currentStep:g,totalSteps:b,onStepChange:V,stepTitles:y==null?void 0:y.stepTitles,showStepTitles:(y==null?void 0:y.showStepTitles)!==!1}),ee.map((L,I)=>m.jsx(E.Card,{sx:{p:2,boxShadow:"0px 1px 4px 0px #00000029",background:"#FFFFFF",borderRadius:"6px",display:"grid",gridTemplateColumns:"repeat(12, 1fr)",gap:2,width:"100%",mb:2},children:L.map(z=>{const ae=te(z);return m.jsx(E.Box,{sx:{gridColumn:`span ${ae}`},children:m.jsx(Nl,{field:z,control:x,errors:_,baseUrl:d,apiHeaders:f,formData:P,setValue:W})},z.name)})},`group-${I}`)),U()]});return le?m.jsx(E.ThemeProvider,{theme:le,children:oe}):oe},im=({src:e,alt:t,width:r="100%",height:n="auto",style:i,className:a,onClick:o})=>m.jsx(E.Box,{sx:{textAlign:"center"},children:m.jsx("img",{src:e||"/placeholder-image.png",alt:t||"Image",width:r,height:n,style:{maxWidth:"100%",height:"auto",borderRadius:"8px",cursor:o?"pointer":"default",...i},className:a,onClick:o,onError:s=>{s.currentTarget.src="/placeholder-image.png"}})});function Tr(e,t,r,n){function i(a){return a instanceof r?a:new r(function(o){o(a)})}return new(r||(r=Promise))(function(a,o){function s(u){try{p(n.next(u))}catch(d){o(d)}}function l(u){try{p(n.throw(u))}catch(d){o(d)}}function p(u){u.done?a(u.value):i(u.value).then(s,l)}p((n=n.apply(e,t||[])).next())})}const am=new Map([["1km","application/vnd.1000minds.decision-model+xml"],["3dml","text/vnd.in3d.3dml"],["3ds","image/x-3ds"],["3g2","video/3gpp2"],["3gp","video/3gp"],["3gpp","video/3gpp"],["3mf","model/3mf"],["7z","application/x-7z-compressed"],["7zip","application/x-7z-compressed"],["123","application/vnd.lotus-1-2-3"],["aab","application/x-authorware-bin"],["aac","audio/x-acc"],["aam","application/x-authorware-map"],["aas","application/x-authorware-seg"],["abw","application/x-abiword"],["ac","application/vnd.nokia.n-gage.ac+xml"],["ac3","audio/ac3"],["acc","application/vnd.americandynamics.acc"],["ace","application/x-ace-compressed"],["acu","application/vnd.acucobol"],["acutc","application/vnd.acucorp"],["adp","audio/adpcm"],["aep","application/vnd.audiograph"],["afm","application/x-font-type1"],["afp","application/vnd.ibm.modcap"],["ahead","application/vnd.ahead.space"],["ai","application/pdf"],["aif","audio/x-aiff"],["aifc","audio/x-aiff"],["aiff","audio/x-aiff"],["air","application/vnd.adobe.air-application-installer-package+zip"],["ait","application/vnd.dvb.ait"],["ami","application/vnd.amiga.ami"],["amr","audio/amr"],["apk","application/vnd.android.package-archive"],["apng","image/apng"],["appcache","text/cache-manifest"],["application","application/x-ms-application"],["apr","application/vnd.lotus-approach"],["arc","application/x-freearc"],["arj","application/x-arj"],["asc","application/pgp-signature"],["asf","video/x-ms-asf"],["asm","text/x-asm"],["aso","application/vnd.accpac.simply.aso"],["asx","video/x-ms-asf"],["atc","application/vnd.acucorp"],["atom","application/atom+xml"],["atomcat","application/atomcat+xml"],["atomdeleted","application/atomdeleted+xml"],["atomsvc","application/atomsvc+xml"],["atx","application/vnd.antix.game-component"],["au","audio/x-au"],["avi","video/x-msvideo"],["avif","image/avif"],["aw","application/applixware"],["azf","application/vnd.airzip.filesecure.azf"],["azs","application/vnd.airzip.filesecure.azs"],["azv","image/vnd.airzip.accelerator.azv"],["azw","application/vnd.amazon.ebook"],["b16","image/vnd.pco.b16"],["bat","application/x-msdownload"],["bcpio","application/x-bcpio"],["bdf","application/x-font-bdf"],["bdm","application/vnd.syncml.dm+wbxml"],["bdoc","application/x-bdoc"],["bed","application/vnd.realvnc.bed"],["bh2","application/vnd.fujitsu.oasysprs"],["bin","application/octet-stream"],["blb","application/x-blorb"],["blorb","application/x-blorb"],["bmi","application/vnd.bmi"],["bmml","application/vnd.balsamiq.bmml+xml"],["bmp","image/bmp"],["book","application/vnd.framemaker"],["box","application/vnd.previewsystems.box"],["boz","application/x-bzip2"],["bpk","application/octet-stream"],["bpmn","application/octet-stream"],["bsp","model/vnd.valve.source.compiled-map"],["btif","image/prs.btif"],["buffer","application/octet-stream"],["bz","application/x-bzip"],["bz2","application/x-bzip2"],["c","text/x-c"],["c4d","application/vnd.clonk.c4group"],["c4f","application/vnd.clonk.c4group"],["c4g","application/vnd.clonk.c4group"],["c4p","application/vnd.clonk.c4group"],["c4u","application/vnd.clonk.c4group"],["c11amc","application/vnd.cluetrust.cartomobile-config"],["c11amz","application/vnd.cluetrust.cartomobile-config-pkg"],["cab","application/vnd.ms-cab-compressed"],["caf","audio/x-caf"],["cap","application/vnd.tcpdump.pcap"],["car","application/vnd.curl.car"],["cat","application/vnd.ms-pki.seccat"],["cb7","application/x-cbr"],["cba","application/x-cbr"],["cbr","application/x-cbr"],["cbt","application/x-cbr"],["cbz","application/x-cbr"],["cc","text/x-c"],["cco","application/x-cocoa"],["cct","application/x-director"],["ccxml","application/ccxml+xml"],["cdbcmsg","application/vnd.contact.cmsg"],["cda","application/x-cdf"],["cdf","application/x-netcdf"],["cdfx","application/cdfx+xml"],["cdkey","application/vnd.mediastation.cdkey"],["cdmia","application/cdmi-capability"],["cdmic","application/cdmi-container"],["cdmid","application/cdmi-domain"],["cdmio","application/cdmi-object"],["cdmiq","application/cdmi-queue"],["cdr","application/cdr"],["cdx","chemical/x-cdx"],["cdxml","application/vnd.chemdraw+xml"],["cdy","application/vnd.cinderella"],["cer","application/pkix-cert"],["cfs","application/x-cfs-compressed"],["cgm","image/cgm"],["chat","application/x-chat"],["chm","application/vnd.ms-htmlhelp"],["chrt","application/vnd.kde.kchart"],["cif","chemical/x-cif"],["cii","application/vnd.anser-web-certificate-issue-initiation"],["cil","application/vnd.ms-artgalry"],["cjs","application/node"],["cla","application/vnd.claymore"],["class","application/octet-stream"],["clkk","application/vnd.crick.clicker.keyboard"],["clkp","application/vnd.crick.clicker.palette"],["clkt","application/vnd.crick.clicker.template"],["clkw","application/vnd.crick.clicker.wordbank"],["clkx","application/vnd.crick.clicker"],["clp","application/x-msclip"],["cmc","application/vnd.cosmocaller"],["cmdf","chemical/x-cmdf"],["cml","chemical/x-cml"],["cmp","application/vnd.yellowriver-custom-menu"],["cmx","image/x-cmx"],["cod","application/vnd.rim.cod"],["coffee","text/coffeescript"],["com","application/x-msdownload"],["conf","text/plain"],["cpio","application/x-cpio"],["cpp","text/x-c"],["cpt","application/mac-compactpro"],["crd","application/x-mscardfile"],["crl","application/pkix-crl"],["crt","application/x-x509-ca-cert"],["crx","application/x-chrome-extension"],["cryptonote","application/vnd.rig.cryptonote"],["csh","application/x-csh"],["csl","application/vnd.citationstyles.style+xml"],["csml","chemical/x-csml"],["csp","application/vnd.commonspace"],["csr","application/octet-stream"],["css","text/css"],["cst","application/x-director"],["csv","text/csv"],["cu","application/cu-seeme"],["curl","text/vnd.curl"],["cww","application/prs.cww"],["cxt","application/x-director"],["cxx","text/x-c"],["dae","model/vnd.collada+xml"],["daf","application/vnd.mobius.daf"],["dart","application/vnd.dart"],["dataless","application/vnd.fdsn.seed"],["davmount","application/davmount+xml"],["dbf","application/vnd.dbf"],["dbk","application/docbook+xml"],["dcr","application/x-director"],["dcurl","text/vnd.curl.dcurl"],["dd2","application/vnd.oma.dd2+xml"],["ddd","application/vnd.fujixerox.ddd"],["ddf","application/vnd.syncml.dmddf+xml"],["dds","image/vnd.ms-dds"],["deb","application/x-debian-package"],["def","text/plain"],["deploy","application/octet-stream"],["der","application/x-x509-ca-cert"],["dfac","application/vnd.dreamfactory"],["dgc","application/x-dgc-compressed"],["dic","text/x-c"],["dir","application/x-director"],["dis","application/vnd.mobius.dis"],["disposition-notification","message/disposition-notification"],["dist","application/octet-stream"],["distz","application/octet-stream"],["djv","image/vnd.djvu"],["djvu","image/vnd.djvu"],["dll","application/octet-stream"],["dmg","application/x-apple-diskimage"],["dmn","application/octet-stream"],["dmp","application/vnd.tcpdump.pcap"],["dms","application/octet-stream"],["dna","application/vnd.dna"],["doc","application/msword"],["docm","application/vnd.ms-word.template.macroEnabled.12"],["docx","application/vnd.openxmlformats-officedocument.wordprocessingml.document"],["dot","application/msword"],["dotm","application/vnd.ms-word.template.macroEnabled.12"],["dotx","application/vnd.openxmlformats-officedocument.wordprocessingml.template"],["dp","application/vnd.osgi.dp"],["dpg","application/vnd.dpgraph"],["dra","audio/vnd.dra"],["drle","image/dicom-rle"],["dsc","text/prs.lines.tag"],["dssc","application/dssc+der"],["dtb","application/x-dtbook+xml"],["dtd","application/xml-dtd"],["dts","audio/vnd.dts"],["dtshd","audio/vnd.dts.hd"],["dump","application/octet-stream"],["dvb","video/vnd.dvb.file"],["dvi","application/x-dvi"],["dwd","application/atsc-dwd+xml"],["dwf","model/vnd.dwf"],["dwg","image/vnd.dwg"],["dxf","image/vnd.dxf"],["dxp","application/vnd.spotfire.dxp"],["dxr","application/x-director"],["ear","application/java-archive"],["ecelp4800","audio/vnd.nuera.ecelp4800"],["ecelp7470","audio/vnd.nuera.ecelp7470"],["ecelp9600","audio/vnd.nuera.ecelp9600"],["ecma","application/ecmascript"],["edm","application/vnd.novadigm.edm"],["edx","application/vnd.novadigm.edx"],["efif","application/vnd.picsel"],["ei6","application/vnd.pg.osasli"],["elc","application/octet-stream"],["emf","image/emf"],["eml","message/rfc822"],["emma","application/emma+xml"],["emotionml","application/emotionml+xml"],["emz","application/x-msmetafile"],["eol","audio/vnd.digital-winds"],["eot","application/vnd.ms-fontobject"],["eps","application/postscript"],["epub","application/epub+zip"],["es","application/ecmascript"],["es3","application/vnd.eszigno3+xml"],["esa","application/vnd.osgi.subsystem"],["esf","application/vnd.epson.esf"],["et3","application/vnd.eszigno3+xml"],["etx","text/x-setext"],["eva","application/x-eva"],["evy","application/x-envoy"],["exe","application/octet-stream"],["exi","application/exi"],["exp","application/express"],["exr","image/aces"],["ext","application/vnd.novadigm.ext"],["ez","application/andrew-inset"],["ez2","application/vnd.ezpix-album"],["ez3","application/vnd.ezpix-package"],["f","text/x-fortran"],["f4v","video/mp4"],["f77","text/x-fortran"],["f90","text/x-fortran"],["fbs","image/vnd.fastbidsheet"],["fcdt","application/vnd.adobe.formscentral.fcdt"],["fcs","application/vnd.isac.fcs"],["fdf","application/vnd.fdf"],["fdt","application/fdt+xml"],["fe_launch","application/vnd.denovo.fcselayout-link"],["fg5","application/vnd.fujitsu.oasysgp"],["fgd","application/x-director"],["fh","image/x-freehand"],["fh4","image/x-freehand"],["fh5","image/x-freehand"],["fh7","image/x-freehand"],["fhc","image/x-freehand"],["fig","application/x-xfig"],["fits","image/fits"],["flac","audio/x-flac"],["fli","video/x-fli"],["flo","application/vnd.micrografx.flo"],["flv","video/x-flv"],["flw","application/vnd.kde.kivio"],["flx","text/vnd.fmi.flexstor"],["fly","text/vnd.fly"],["fm","application/vnd.framemaker"],["fnc","application/vnd.frogans.fnc"],["fo","application/vnd.software602.filler.form+xml"],["for","text/x-fortran"],["fpx","image/vnd.fpx"],["frame","application/vnd.framemaker"],["fsc","application/vnd.fsc.weblaunch"],["fst","image/vnd.fst"],["ftc","application/vnd.fluxtime.clip"],["fti","application/vnd.anser-web-funds-transfer-initiation"],["fvt","video/vnd.fvt"],["fxp","application/vnd.adobe.fxp"],["fxpl","application/vnd.adobe.fxp"],["fzs","application/vnd.fuzzysheet"],["g2w","application/vnd.geoplan"],["g3","image/g3fax"],["g3w","application/vnd.geospace"],["gac","application/vnd.groove-account"],["gam","application/x-tads"],["gbr","application/rpki-ghostbusters"],["gca","application/x-gca-compressed"],["gdl","model/vnd.gdl"],["gdoc","application/vnd.google-apps.document"],["geo","application/vnd.dynageo"],["geojson","application/geo+json"],["gex","application/vnd.geometry-explorer"],["ggb","application/vnd.geogebra.file"],["ggt","application/vnd.geogebra.tool"],["ghf","application/vnd.groove-help"],["gif","image/gif"],["gim","application/vnd.groove-identity-message"],["glb","model/gltf-binary"],["gltf","model/gltf+json"],["gml","application/gml+xml"],["gmx","application/vnd.gmx"],["gnumeric","application/x-gnumeric"],["gpg","application/gpg-keys"],["gph","application/vnd.flographit"],["gpx","application/gpx+xml"],["gqf","application/vnd.grafeq"],["gqs","application/vnd.grafeq"],["gram","application/srgs"],["gramps","application/x-gramps-xml"],["gre","application/vnd.geometry-explorer"],["grv","application/vnd.groove-injector"],["grxml","application/srgs+xml"],["gsf","application/x-font-ghostscript"],["gsheet","application/vnd.google-apps.spreadsheet"],["gslides","application/vnd.google-apps.presentation"],["gtar","application/x-gtar"],["gtm","application/vnd.groove-tool-message"],["gtw","model/vnd.gtw"],["gv","text/vnd.graphviz"],["gxf","application/gxf"],["gxt","application/vnd.geonext"],["gz","application/gzip"],["gzip","application/gzip"],["h","text/x-c"],["h261","video/h261"],["h263","video/h263"],["h264","video/h264"],["hal","application/vnd.hal+xml"],["hbci","application/vnd.hbci"],["hbs","text/x-handlebars-template"],["hdd","application/x-virtualbox-hdd"],["hdf","application/x-hdf"],["heic","image/heic"],["heics","image/heic-sequence"],["heif","image/heif"],["heifs","image/heif-sequence"],["hej2","image/hej2k"],["held","application/atsc-held+xml"],["hh","text/x-c"],["hjson","application/hjson"],["hlp","application/winhlp"],["hpgl","application/vnd.hp-hpgl"],["hpid","application/vnd.hp-hpid"],["hps","application/vnd.hp-hps"],["hqx","application/mac-binhex40"],["hsj2","image/hsj2"],["htc","text/x-component"],["htke","application/vnd.kenameaapp"],["htm","text/html"],["html","text/html"],["hvd","application/vnd.yamaha.hv-dic"],["hvp","application/vnd.yamaha.hv-voice"],["hvs","application/vnd.yamaha.hv-script"],["i2g","application/vnd.intergeo"],["icc","application/vnd.iccprofile"],["ice","x-conference/x-cooltalk"],["icm","application/vnd.iccprofile"],["ico","image/x-icon"],["ics","text/calendar"],["ief","image/ief"],["ifb","text/calendar"],["ifm","application/vnd.shana.informed.formdata"],["iges","model/iges"],["igl","application/vnd.igloader"],["igm","application/vnd.insors.igm"],["igs","model/iges"],["igx","application/vnd.micrografx.igx"],["iif","application/vnd.shana.informed.interchange"],["img","application/octet-stream"],["imp","application/vnd.accpac.simply.imp"],["ims","application/vnd.ms-ims"],["in","text/plain"],["ini","text/plain"],["ink","application/inkml+xml"],["inkml","application/inkml+xml"],["install","application/x-install-instructions"],["iota","application/vnd.astraea-software.iota"],["ipfix","application/ipfix"],["ipk","application/vnd.shana.informed.package"],["irm","application/vnd.ibm.rights-management"],["irp","application/vnd.irepository.package+xml"],["iso","application/x-iso9660-image"],["itp","application/vnd.shana.informed.formtemplate"],["its","application/its+xml"],["ivp","application/vnd.immervision-ivp"],["ivu","application/vnd.immervision-ivu"],["jad","text/vnd.sun.j2me.app-descriptor"],["jade","text/jade"],["jam","application/vnd.jam"],["jar","application/java-archive"],["jardiff","application/x-java-archive-diff"],["java","text/x-java-source"],["jhc","image/jphc"],["jisp","application/vnd.jisp"],["jls","image/jls"],["jlt","application/vnd.hp-jlyt"],["jng","image/x-jng"],["jnlp","application/x-java-jnlp-file"],["joda","application/vnd.joost.joda-archive"],["jp2","image/jp2"],["jpe","image/jpeg"],["jpeg","image/jpeg"],["jpf","image/jpx"],["jpg","image/jpeg"],["jpg2","image/jp2"],["jpgm","video/jpm"],["jpgv","video/jpeg"],["jph","image/jph"],["jpm","video/jpm"],["jpx","image/jpx"],["js","application/javascript"],["json","application/json"],["json5","application/json5"],["jsonld","application/ld+json"],["jsonl","application/jsonl"],["jsonml","application/jsonml+json"],["jsx","text/jsx"],["jxr","image/jxr"],["jxra","image/jxra"],["jxrs","image/jxrs"],["jxs","image/jxs"],["jxsc","image/jxsc"],["jxsi","image/jxsi"],["jxss","image/jxss"],["kar","audio/midi"],["karbon","application/vnd.kde.karbon"],["kdb","application/octet-stream"],["kdbx","application/x-keepass2"],["key","application/x-iwork-keynote-sffkey"],["kfo","application/vnd.kde.kformula"],["kia","application/vnd.kidspiration"],["kml","application/vnd.google-earth.kml+xml"],["kmz","application/vnd.google-earth.kmz"],["kne","application/vnd.kinar"],["knp","application/vnd.kinar"],["kon","application/vnd.kde.kontour"],["kpr","application/vnd.kde.kpresenter"],["kpt","application/vnd.kde.kpresenter"],["kpxx","application/vnd.ds-keypoint"],["ksp","application/vnd.kde.kspread"],["ktr","application/vnd.kahootz"],["ktx","image/ktx"],["ktx2","image/ktx2"],["ktz","application/vnd.kahootz"],["kwd","application/vnd.kde.kword"],["kwt","application/vnd.kde.kword"],["lasxml","application/vnd.las.las+xml"],["latex","application/x-latex"],["lbd","application/vnd.llamagraphics.life-balance.desktop"],["lbe","application/vnd.llamagraphics.life-balance.exchange+xml"],["les","application/vnd.hhe.lesson-player"],["less","text/less"],["lgr","application/lgr+xml"],["lha","application/octet-stream"],["link66","application/vnd.route66.link66+xml"],["list","text/plain"],["list3820","application/vnd.ibm.modcap"],["listafp","application/vnd.ibm.modcap"],["litcoffee","text/coffeescript"],["lnk","application/x-ms-shortcut"],["log","text/plain"],["lostxml","application/lost+xml"],["lrf","application/octet-stream"],["lrm","application/vnd.ms-lrm"],["ltf","application/vnd.frogans.ltf"],["lua","text/x-lua"],["luac","application/x-lua-bytecode"],["lvp","audio/vnd.lucent.voice"],["lwp","application/vnd.lotus-wordpro"],["lzh","application/octet-stream"],["m1v","video/mpeg"],["m2a","audio/mpeg"],["m2v","video/mpeg"],["m3a","audio/mpeg"],["m3u","text/plain"],["m3u8","application/vnd.apple.mpegurl"],["m4a","audio/x-m4a"],["m4p","application/mp4"],["m4s","video/iso.segment"],["m4u","application/vnd.mpegurl"],["m4v","video/x-m4v"],["m13","application/x-msmediaview"],["m14","application/x-msmediaview"],["m21","application/mp21"],["ma","application/mathematica"],["mads","application/mads+xml"],["maei","application/mmt-aei+xml"],["mag","application/vnd.ecowin.chart"],["maker","application/vnd.framemaker"],["man","text/troff"],["manifest","text/cache-manifest"],["map","application/json"],["mar","application/octet-stream"],["markdown","text/markdown"],["mathml","application/mathml+xml"],["mb","application/mathematica"],["mbk","application/vnd.mobius.mbk"],["mbox","application/mbox"],["mc1","application/vnd.medcalcdata"],["mcd","application/vnd.mcd"],["mcurl","text/vnd.curl.mcurl"],["md","text/markdown"],["mdb","application/x-msaccess"],["mdi","image/vnd.ms-modi"],["mdx","text/mdx"],["me","text/troff"],["mesh","model/mesh"],["meta4","application/metalink4+xml"],["metalink","application/metalink+xml"],["mets","application/mets+xml"],["mfm","application/vnd.mfmp"],["mft","application/rpki-manifest"],["mgp","application/vnd.osgeo.mapguide.package"],["mgz","application/vnd.proteus.magazine"],["mid","audio/midi"],["midi","audio/midi"],["mie","application/x-mie"],["mif","application/vnd.mif"],["mime","message/rfc822"],["mj2","video/mj2"],["mjp2","video/mj2"],["mjs","application/javascript"],["mk3d","video/x-matroska"],["mka","audio/x-matroska"],["mkd","text/x-markdown"],["mks","video/x-matroska"],["mkv","video/x-matroska"],["mlp","application/vnd.dolby.mlp"],["mmd","application/vnd.chipnuts.karaoke-mmd"],["mmf","application/vnd.smaf"],["mml","text/mathml"],["mmr","image/vnd.fujixerox.edmics-mmr"],["mng","video/x-mng"],["mny","application/x-msmoney"],["mobi","application/x-mobipocket-ebook"],["mods","application/mods+xml"],["mov","video/quicktime"],["movie","video/x-sgi-movie"],["mp2","audio/mpeg"],["mp2a","audio/mpeg"],["mp3","audio/mpeg"],["mp4","video/mp4"],["mp4a","audio/mp4"],["mp4s","application/mp4"],["mp4v","video/mp4"],["mp21","application/mp21"],["mpc","application/vnd.mophun.certificate"],["mpd","application/dash+xml"],["mpe","video/mpeg"],["mpeg","video/mpeg"],["mpg","video/mpeg"],["mpg4","video/mp4"],["mpga","audio/mpeg"],["mpkg","application/vnd.apple.installer+xml"],["mpm","application/vnd.blueice.multipass"],["mpn","application/vnd.mophun.application"],["mpp","application/vnd.ms-project"],["mpt","application/vnd.ms-project"],["mpy","application/vnd.ibm.minipay"],["mqy","application/vnd.mobius.mqy"],["mrc","application/marc"],["mrcx","application/marcxml+xml"],["ms","text/troff"],["mscml","application/mediaservercontrol+xml"],["mseed","application/vnd.fdsn.mseed"],["mseq","application/vnd.mseq"],["msf","application/vnd.epson.msf"],["msg","application/vnd.ms-outlook"],["msh","model/mesh"],["msi","application/x-msdownload"],["msl","application/vnd.mobius.msl"],["msm","application/octet-stream"],["msp","application/octet-stream"],["msty","application/vnd.muvee.style"],["mtl","model/mtl"],["mts","model/vnd.mts"],["mus","application/vnd.musician"],["musd","application/mmt-usd+xml"],["musicxml","application/vnd.recordare.musicxml+xml"],["mvb","application/x-msmediaview"],["mvt","application/vnd.mapbox-vector-tile"],["mwf","application/vnd.mfer"],["mxf","application/mxf"],["mxl","application/vnd.recordare.musicxml"],["mxmf","audio/mobile-xmf"],["mxml","application/xv+xml"],["mxs","application/vnd.triscape.mxs"],["mxu","video/vnd.mpegurl"],["n-gage","application/vnd.nokia.n-gage.symbian.install"],["n3","text/n3"],["nb","application/mathematica"],["nbp","application/vnd.wolfram.player"],["nc","application/x-netcdf"],["ncx","application/x-dtbncx+xml"],["nfo","text/x-nfo"],["ngdat","application/vnd.nokia.n-gage.data"],["nitf","application/vnd.nitf"],["nlu","application/vnd.neurolanguage.nlu"],["nml","application/vnd.enliven"],["nnd","application/vnd.noblenet-directory"],["nns","application/vnd.noblenet-sealer"],["nnw","application/vnd.noblenet-web"],["npx","image/vnd.net-fpx"],["nq","application/n-quads"],["nsc","application/x-conference"],["nsf","application/vnd.lotus-notes"],["nt","application/n-triples"],["ntf","application/vnd.nitf"],["numbers","application/x-iwork-numbers-sffnumbers"],["nzb","application/x-nzb"],["oa2","application/vnd.fujitsu.oasys2"],["oa3","application/vnd.fujitsu.oasys3"],["oas","application/vnd.fujitsu.oasys"],["obd","application/x-msbinder"],["obgx","application/vnd.openblox.game+xml"],["obj","model/obj"],["oda","application/oda"],["odb","application/vnd.oasis.opendocument.database"],["odc","application/vnd.oasis.opendocument.chart"],["odf","application/vnd.oasis.opendocument.formula"],["odft","application/vnd.oasis.opendocument.formula-template"],["odg","application/vnd.oasis.opendocument.graphics"],["odi","application/vnd.oasis.opendocument.image"],["odm","application/vnd.oasis.opendocument.text-master"],["odp","application/vnd.oasis.opendocument.presentation"],["ods","application/vnd.oasis.opendocument.spreadsheet"],["odt","application/vnd.oasis.opendocument.text"],["oga","audio/ogg"],["ogex","model/vnd.opengex"],["ogg","audio/ogg"],["ogv","video/ogg"],["ogx","application/ogg"],["omdoc","application/omdoc+xml"],["onepkg","application/onenote"],["onetmp","application/onenote"],["onetoc","application/onenote"],["onetoc2","application/onenote"],["opf","application/oebps-package+xml"],["opml","text/x-opml"],["oprc","application/vnd.palm"],["opus","audio/ogg"],["org","text/x-org"],["osf","application/vnd.yamaha.openscoreformat"],["osfpvg","application/vnd.yamaha.openscoreformat.osfpvg+xml"],["osm","application/vnd.openstreetmap.data+xml"],["otc","application/vnd.oasis.opendocument.chart-template"],["otf","font/otf"],["otg","application/vnd.oasis.opendocument.graphics-template"],["oth","application/vnd.oasis.opendocument.text-web"],["oti","application/vnd.oasis.opendocument.image-template"],["otp","application/vnd.oasis.opendocument.presentation-template"],["ots","application/vnd.oasis.opendocument.spreadsheet-template"],["ott","application/vnd.oasis.opendocument.text-template"],["ova","application/x-virtualbox-ova"],["ovf","application/x-virtualbox-ovf"],["owl","application/rdf+xml"],["oxps","application/oxps"],["oxt","application/vnd.openofficeorg.extension"],["p","text/x-pascal"],["p7a","application/x-pkcs7-signature"],["p7b","application/x-pkcs7-certificates"],["p7c","application/pkcs7-mime"],["p7m","application/pkcs7-mime"],["p7r","application/x-pkcs7-certreqresp"],["p7s","application/pkcs7-signature"],["p8","application/pkcs8"],["p10","application/x-pkcs10"],["p12","application/x-pkcs12"],["pac","application/x-ns-proxy-autoconfig"],["pages","application/x-iwork-pages-sffpages"],["pas","text/x-pascal"],["paw","application/vnd.pawaafile"],["pbd","application/vnd.powerbuilder6"],["pbm","image/x-portable-bitmap"],["pcap","application/vnd.tcpdump.pcap"],["pcf","application/x-font-pcf"],["pcl","application/vnd.hp-pcl"],["pclxl","application/vnd.hp-pclxl"],["pct","image/x-pict"],["pcurl","application/vnd.curl.pcurl"],["pcx","image/x-pcx"],["pdb","application/x-pilot"],["pde","text/x-processing"],["pdf","application/pdf"],["pem","application/x-x509-user-cert"],["pfa","application/x-font-type1"],["pfb","application/x-font-type1"],["pfm","application/x-font-type1"],["pfr","application/font-tdpfr"],["pfx","application/x-pkcs12"],["pgm","image/x-portable-graymap"],["pgn","application/x-chess-pgn"],["pgp","application/pgp"],["php","application/x-httpd-php"],["php3","application/x-httpd-php"],["php4","application/x-httpd-php"],["phps","application/x-httpd-php-source"],["phtml","application/x-httpd-php"],["pic","image/x-pict"],["pkg","application/octet-stream"],["pki","application/pkixcmp"],["pkipath","application/pkix-pkipath"],["pkpass","application/vnd.apple.pkpass"],["pl","application/x-perl"],["plb","application/vnd.3gpp.pic-bw-large"],["plc","application/vnd.mobius.plc"],["plf","application/vnd.pocketlearn"],["pls","application/pls+xml"],["pm","application/x-perl"],["pml","application/vnd.ctc-posml"],["png","image/png"],["pnm","image/x-portable-anymap"],["portpkg","application/vnd.macports.portpkg"],["pot","application/vnd.ms-powerpoint"],["potm","application/vnd.ms-powerpoint.presentation.macroEnabled.12"],["potx","application/vnd.openxmlformats-officedocument.presentationml.template"],["ppa","application/vnd.ms-powerpoint"],["ppam","application/vnd.ms-powerpoint.addin.macroEnabled.12"],["ppd","application/vnd.cups-ppd"],["ppm","image/x-portable-pixmap"],["pps","application/vnd.ms-powerpoint"],["ppsm","application/vnd.ms-powerpoint.slideshow.macroEnabled.12"],["ppsx","application/vnd.openxmlformats-officedocument.presentationml.slideshow"],["ppt","application/powerpoint"],["pptm","application/vnd.ms-powerpoint.presentation.macroEnabled.12"],["pptx","application/vnd.openxmlformats-officedocument.presentationml.presentation"],["pqa","application/vnd.palm"],["prc","application/x-pilot"],["pre","application/vnd.lotus-freelance"],["prf","application/pics-rules"],["provx","application/provenance+xml"],["ps","application/postscript"],["psb","application/vnd.3gpp.pic-bw-small"],["psd","application/x-photoshop"],["psf","application/x-font-linux-psf"],["pskcxml","application/pskc+xml"],["pti","image/prs.pti"],["ptid","application/vnd.pvi.ptid1"],["pub","application/x-mspublisher"],["pvb","application/vnd.3gpp.pic-bw-var"],["pwn","application/vnd.3m.post-it-notes"],["pya","audio/vnd.ms-playready.media.pya"],["pyv","video/vnd.ms-playready.media.pyv"],["qam","application/vnd.epson.quickanime"],["qbo","application/vnd.intu.qbo"],["qfx","application/vnd.intu.qfx"],["qps","application/vnd.publishare-delta-tree"],["qt","video/quicktime"],["qwd","application/vnd.quark.quarkxpress"],["qwt","application/vnd.quark.quarkxpress"],["qxb","application/vnd.quark.quarkxpress"],["qxd","application/vnd.quark.quarkxpress"],["qxl","application/vnd.quark.quarkxpress"],["qxt","application/vnd.quark.quarkxpress"],["ra","audio/x-realaudio"],["ram","audio/x-pn-realaudio"],["raml","application/raml+yaml"],["rapd","application/route-apd+xml"],["rar","application/x-rar"],["ras","image/x-cmu-raster"],["rcprofile","application/vnd.ipunplugged.rcprofile"],["rdf","application/rdf+xml"],["rdz","application/vnd.data-vision.rdz"],["relo","application/p2p-overlay+xml"],["rep","application/vnd.businessobjects"],["res","application/x-dtbresource+xml"],["rgb","image/x-rgb"],["rif","application/reginfo+xml"],["rip","audio/vnd.rip"],["ris","application/x-research-info-systems"],["rl","application/resource-lists+xml"],["rlc","image/vnd.fujixerox.edmics-rlc"],["rld","application/resource-lists-diff+xml"],["rm","audio/x-pn-realaudio"],["rmi","audio/midi"],["rmp","audio/x-pn-realaudio-plugin"],["rms","application/vnd.jcp.javame.midlet-rms"],["rmvb","application/vnd.rn-realmedia-vbr"],["rnc","application/relax-ng-compact-syntax"],["rng","application/xml"],["roa","application/rpki-roa"],["roff","text/troff"],["rp9","application/vnd.cloanto.rp9"],["rpm","audio/x-pn-realaudio-plugin"],["rpss","application/vnd.nokia.radio-presets"],["rpst","application/vnd.nokia.radio-preset"],["rq","application/sparql-query"],["rs","application/rls-services+xml"],["rsa","application/x-pkcs7"],["rsat","application/atsc-rsat+xml"],["rsd","application/rsd+xml"],["rsheet","application/urc-ressheet+xml"],["rss","application/rss+xml"],["rtf","text/rtf"],["rtx","text/richtext"],["run","application/x-makeself"],["rusd","application/route-usd+xml"],["rv","video/vnd.rn-realvideo"],["s","text/x-asm"],["s3m","audio/s3m"],["saf","application/vnd.yamaha.smaf-audio"],["sass","text/x-sass"],["sbml","application/sbml+xml"],["sc","application/vnd.ibm.secure-container"],["scd","application/x-msschedule"],["scm","application/vnd.lotus-screencam"],["scq","application/scvp-cv-request"],["scs","application/scvp-cv-response"],["scss","text/x-scss"],["scurl","text/vnd.curl.scurl"],["sda","application/vnd.stardivision.draw"],["sdc","application/vnd.stardivision.calc"],["sdd","application/vnd.stardivision.impress"],["sdkd","application/vnd.solent.sdkm+xml"],["sdkm","application/vnd.solent.sdkm+xml"],["sdp","application/sdp"],["sdw","application/vnd.stardivision.writer"],["sea","application/octet-stream"],["see","application/vnd.seemail"],["seed","application/vnd.fdsn.seed"],["sema","application/vnd.sema"],["semd","application/vnd.semd"],["semf","application/vnd.semf"],["senmlx","application/senml+xml"],["sensmlx","application/sensml+xml"],["ser","application/java-serialized-object"],["setpay","application/set-payment-initiation"],["setreg","application/set-registration-initiation"],["sfd-hdstx","application/vnd.hydrostatix.sof-data"],["sfs","application/vnd.spotfire.sfs"],["sfv","text/x-sfv"],["sgi","image/sgi"],["sgl","application/vnd.stardivision.writer-global"],["sgm","text/sgml"],["sgml","text/sgml"],["sh","application/x-sh"],["shar","application/x-shar"],["shex","text/shex"],["shf","application/shf+xml"],["shtml","text/html"],["sid","image/x-mrsid-image"],["sieve","application/sieve"],["sig","application/pgp-signature"],["sil","audio/silk"],["silo","model/mesh"],["sis","application/vnd.symbian.install"],["sisx","application/vnd.symbian.install"],["sit","application/x-stuffit"],["sitx","application/x-stuffitx"],["siv","application/sieve"],["skd","application/vnd.koan"],["skm","application/vnd.koan"],["skp","application/vnd.koan"],["skt","application/vnd.koan"],["sldm","application/vnd.ms-powerpoint.slide.macroenabled.12"],["sldx","application/vnd.openxmlformats-officedocument.presentationml.slide"],["slim","text/slim"],["slm","text/slim"],["sls","application/route-s-tsid+xml"],["slt","application/vnd.epson.salt"],["sm","application/vnd.stepmania.stepchart"],["smf","application/vnd.stardivision.math"],["smi","application/smil"],["smil","application/smil"],["smv","video/x-smv"],["smzip","application/vnd.stepmania.package"],["snd","audio/basic"],["snf","application/x-font-snf"],["so","application/octet-stream"],["spc","application/x-pkcs7-certificates"],["spdx","text/spdx"],["spf","application/vnd.yamaha.smaf-phrase"],["spl","application/x-futuresplash"],["spot","text/vnd.in3d.spot"],["spp","application/scvp-vp-response"],["spq","application/scvp-vp-request"],["spx","audio/ogg"],["sql","application/x-sql"],["src","application/x-wais-source"],["srt","application/x-subrip"],["sru","application/sru+xml"],["srx","application/sparql-results+xml"],["ssdl","application/ssdl+xml"],["sse","application/vnd.kodak-descriptor"],["ssf","application/vnd.epson.ssf"],["ssml","application/ssml+xml"],["sst","application/octet-stream"],["st","application/vnd.sailingtracker.track"],["stc","application/vnd.sun.xml.calc.template"],["std","application/vnd.sun.xml.draw.template"],["stf","application/vnd.wt.stf"],["sti","application/vnd.sun.xml.impress.template"],["stk","application/hyperstudio"],["stl","model/stl"],["stpx","model/step+xml"],["stpxz","model/step-xml+zip"],["stpz","model/step+zip"],["str","application/vnd.pg.format"],["stw","application/vnd.sun.xml.writer.template"],["styl","text/stylus"],["stylus","text/stylus"],["sub","text/vnd.dvb.subtitle"],["sus","application/vnd.sus-calendar"],["susp","application/vnd.sus-calendar"],["sv4cpio","application/x-sv4cpio"],["sv4crc","application/x-sv4crc"],["svc","application/vnd.dvb.service"],["svd","application/vnd.svd"],["svg","image/svg+xml"],["svgz","image/svg+xml"],["swa","application/x-director"],["swf","application/x-shockwave-flash"],["swi","application/vnd.aristanetworks.swi"],["swidtag","application/swid+xml"],["sxc","application/vnd.sun.xml.calc"],["sxd","application/vnd.sun.xml.draw"],["sxg","application/vnd.sun.xml.writer.global"],["sxi","application/vnd.sun.xml.impress"],["sxm","application/vnd.sun.xml.math"],["sxw","application/vnd.sun.xml.writer"],["t","text/troff"],["t3","application/x-t3vm-image"],["t38","image/t38"],["taglet","application/vnd.mynfc"],["tao","application/vnd.tao.intent-module-archive"],["tap","image/vnd.tencent.tap"],["tar","application/x-tar"],["tcap","application/vnd.3gpp2.tcap"],["tcl","application/x-tcl"],["td","application/urc-targetdesc+xml"],["teacher","application/vnd.smart.teacher"],["tei","application/tei+xml"],["teicorpus","application/tei+xml"],["tex","application/x-tex"],["texi","application/x-texinfo"],["texinfo","application/x-texinfo"],["text","text/plain"],["tfi","application/thraud+xml"],["tfm","application/x-tex-tfm"],["tfx","image/tiff-fx"],["tga","image/x-tga"],["tgz","application/x-tar"],["thmx","application/vnd.ms-officetheme"],["tif","image/tiff"],["tiff","image/tiff"],["tk","application/x-tcl"],["tmo","application/vnd.tmobile-livetv"],["toml","application/toml"],["torrent","application/x-bittorrent"],["tpl","application/vnd.groove-tool-template"],["tpt","application/vnd.trid.tpt"],["tr","text/troff"],["tra","application/vnd.trueapp"],["trig","application/trig"],["trm","application/x-msterminal"],["ts","video/mp2t"],["tsd","application/timestamped-data"],["tsv","text/tab-separated-values"],["ttc","font/collection"],["ttf","font/ttf"],["ttl","text/turtle"],["ttml","application/ttml+xml"],["twd","application/vnd.simtech-mindmapper"],["twds","application/vnd.simtech-mindmapper"],["txd","application/vnd.genomatix.tuxedo"],["txf","application/vnd.mobius.txf"],["txt","text/plain"],["u8dsn","message/global-delivery-status"],["u8hdr","message/global-headers"],["u8mdn","message/global-disposition-notification"],["u8msg","message/global"],["u32","application/x-authorware-bin"],["ubj","application/ubjson"],["udeb","application/x-debian-package"],["ufd","application/vnd.ufdl"],["ufdl","application/vnd.ufdl"],["ulx","application/x-glulx"],["umj","application/vnd.umajin"],["unityweb","application/vnd.unity"],["uoml","application/vnd.uoml+xml"],["uri","text/uri-list"],["uris","text/uri-list"],["urls","text/uri-list"],["usdz","model/vnd.usdz+zip"],["ustar","application/x-ustar"],["utz","application/vnd.uiq.theme"],["uu","text/x-uuencode"],["uva","audio/vnd.dece.audio"],["uvd","application/vnd.dece.data"],["uvf","application/vnd.dece.data"],["uvg","image/vnd.dece.graphic"],["uvh","video/vnd.dece.hd"],["uvi","image/vnd.dece.graphic"],["uvm","video/vnd.dece.mobile"],["uvp","video/vnd.dece.pd"],["uvs","video/vnd.dece.sd"],["uvt","application/vnd.dece.ttml+xml"],["uvu","video/vnd.uvvu.mp4"],["uvv","video/vnd.dece.video"],["uvva","audio/vnd.dece.audio"],["uvvd","application/vnd.dece.data"],["uvvf","application/vnd.dece.data"],["uvvg","image/vnd.dece.graphic"],["uvvh","video/vnd.dece.hd"],["uvvi","image/vnd.dece.graphic"],["uvvm","video/vnd.dece.mobile"],["uvvp","video/vnd.dece.pd"],["uvvs","video/vnd.dece.sd"],["uvvt","application/vnd.dece.ttml+xml"],["uvvu","video/vnd.uvvu.mp4"],["uvvv","video/vnd.dece.video"],["uvvx","application/vnd.dece.unspecified"],["uvvz","application/vnd.dece.zip"],["uvx","application/vnd.dece.unspecified"],["uvz","application/vnd.dece.zip"],["vbox","application/x-virtualbox-vbox"],["vbox-extpack","application/x-virtualbox-vbox-extpack"],["vcard","text/vcard"],["vcd","application/x-cdlink"],["vcf","text/x-vcard"],["vcg","application/vnd.groove-vcard"],["vcs","text/x-vcalendar"],["vcx","application/vnd.vcx"],["vdi","application/x-virtualbox-vdi"],["vds","model/vnd.sap.vds"],["vhd","application/x-virtualbox-vhd"],["vis","application/vnd.visionary"],["viv","video/vnd.vivo"],["vlc","application/videolan"],["vmdk","application/x-virtualbox-vmdk"],["vob","video/x-ms-vob"],["vor","application/vnd.stardivision.writer"],["vox","application/x-authorware-bin"],["vrml","model/vrml"],["vsd","application/vnd.visio"],["vsf","application/vnd.vsf"],["vss","application/vnd.visio"],["vst","application/vnd.visio"],["vsw","application/vnd.visio"],["vtf","image/vnd.valve.source.texture"],["vtt","text/vtt"],["vtu","model/vnd.vtu"],["vxml","application/voicexml+xml"],["w3d","application/x-director"],["wad","application/x-doom"],["wadl","application/vnd.sun.wadl+xml"],["war","application/java-archive"],["wasm","application/wasm"],["wav","audio/x-wav"],["wax","audio/x-ms-wax"],["wbmp","image/vnd.wap.wbmp"],["wbs","application/vnd.criticaltools.wbs+xml"],["wbxml","application/wbxml"],["wcm","application/vnd.ms-works"],["wdb","application/vnd.ms-works"],["wdp","image/vnd.ms-photo"],["weba","audio/webm"],["webapp","application/x-web-app-manifest+json"],["webm","video/webm"],["webmanifest","application/manifest+json"],["webp","image/webp"],["wg","application/vnd.pmi.widget"],["wgt","application/widget"],["wks","application/vnd.ms-works"],["wm","video/x-ms-wm"],["wma","audio/x-ms-wma"],["wmd","application/x-ms-wmd"],["wmf","image/wmf"],["wml","text/vnd.wap.wml"],["wmlc","application/wmlc"],["wmls","text/vnd.wap.wmlscript"],["wmlsc","application/vnd.wap.wmlscriptc"],["wmv","video/x-ms-wmv"],["wmx","video/x-ms-wmx"],["wmz","application/x-msmetafile"],["woff","font/woff"],["woff2","font/woff2"],["word","application/msword"],["wpd","application/vnd.wordperfect"],["wpl","application/vnd.ms-wpl"],["wps","application/vnd.ms-works"],["wqd","application/vnd.wqd"],["wri","application/x-mswrite"],["wrl","model/vrml"],["wsc","message/vnd.wfa.wsc"],["wsdl","application/wsdl+xml"],["wspolicy","application/wspolicy+xml"],["wtb","application/vnd.webturbo"],["wvx","video/x-ms-wvx"],["x3d","model/x3d+xml"],["x3db","model/x3d+fastinfoset"],["x3dbz","model/x3d+binary"],["x3dv","model/x3d-vrml"],["x3dvz","model/x3d+vrml"],["x3dz","model/x3d+xml"],["x32","application/x-authorware-bin"],["x_b","model/vnd.parasolid.transmit.binary"],["x_t","model/vnd.parasolid.transmit.text"],["xaml","application/xaml+xml"],["xap","application/x-silverlight-app"],["xar","application/vnd.xara"],["xav","application/xcap-att+xml"],["xbap","application/x-ms-xbap"],["xbd","application/vnd.fujixerox.docuworks.binder"],["xbm","image/x-xbitmap"],["xca","application/xcap-caps+xml"],["xcs","application/calendar+xml"],["xdf","application/xcap-diff+xml"],["xdm","application/vnd.syncml.dm+xml"],["xdp","application/vnd.adobe.xdp+xml"],["xdssc","application/dssc+xml"],["xdw","application/vnd.fujixerox.docuworks"],["xel","application/xcap-el+xml"],["xenc","application/xenc+xml"],["xer","application/patch-ops-error+xml"],["xfdf","application/vnd.adobe.xfdf"],["xfdl","application/vnd.xfdl"],["xht","application/xhtml+xml"],["xhtml","application/xhtml+xml"],["xhvml","application/xv+xml"],["xif","image/vnd.xiff"],["xl","application/excel"],["xla","application/vnd.ms-excel"],["xlam","application/vnd.ms-excel.addin.macroEnabled.12"],["xlc","application/vnd.ms-excel"],["xlf","application/xliff+xml"],["xlm","application/vnd.ms-excel"],["xls","application/vnd.ms-excel"],["xlsb","application/vnd.ms-excel.sheet.binary.macroEnabled.12"],["xlsm","application/vnd.ms-excel.sheet.macroEnabled.12"],["xlsx","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"],["xlt","application/vnd.ms-excel"],["xltm","application/vnd.ms-excel.template.macroEnabled.12"],["xltx","application/vnd.openxmlformats-officedocument.spreadsheetml.template"],["xlw","application/vnd.ms-excel"],["xm","audio/xm"],["xml","application/xml"],["xns","application/xcap-ns+xml"],["xo","application/vnd.olpc-sugar"],["xop","application/xop+xml"],["xpi","application/x-xpinstall"],["xpl","application/xproc+xml"],["xpm","image/x-xpixmap"],["xpr","application/vnd.is-xpr"],["xps","application/vnd.ms-xpsdocument"],["xpw","application/vnd.intercon.formnet"],["xpx","application/vnd.intercon.formnet"],["xsd","application/xml"],["xsl","application/xml"],["xslt","application/xslt+xml"],["xsm","application/vnd.syncml+xml"],["xspf","application/xspf+xml"],["xul","application/vnd.mozilla.xul+xml"],["xvm","application/xv+xml"],["xvml","application/xv+xml"],["xwd","image/x-xwindowdump"],["xyz","chemical/x-xyz"],["xz","application/x-xz"],["yaml","text/yaml"],["yang","application/yang"],["yin","application/yin+xml"],["yml","text/yaml"],["ymp","text/x-suse-ymp"],["z","application/x-compress"],["z1","application/x-zmachine"],["z2","application/x-zmachine"],["z3","application/x-zmachine"],["z4","application/x-zmachine"],["z5","application/x-zmachine"],["z6","application/x-zmachine"],["z7","application/x-zmachine"],["z8","application/x-zmachine"],["zaz","application/vnd.zzazz.deck+xml"],["zip","application/zip"],["zir","application/vnd.zul"],["zirz","application/vnd.zul"],["zmm","application/vnd.handheld-entertainment+xml"],["zsh","text/x-scriptzsh"]]);function Zr(e,t,r){const n=om(e),{webkitRelativePath:i}=e,a=typeof t=="string"?t:typeof i=="string"&&i.length>0?i:`./${e.name}`;return typeof n.path!="string"&&hs(n,"path",a),hs(n,"relativePath",a),n}function om(e){const{name:t}=e;if(t&&t.lastIndexOf(".")!==-1&&!e.type){const n=t.split(".").pop().toLowerCase(),i=am.get(n);i&&Object.defineProperty(e,"type",{value:i,writable:!1,configurable:!1,enumerable:!0})}return e}function hs(e,t,r){Object.defineProperty(e,t,{value:r,writable:!1,configurable:!1,enumerable:!0})}const sm=[".DS_Store","Thumbs.db"];function lm(e){return Tr(this,void 0,void 0,function*(){return oi(e)&&cm(e.dataTransfer)?fm(e.dataTransfer,e.type):um(e)?pm(e):Array.isArray(e)&&e.every(t=>"getFile"in t&&typeof t.getFile=="function")?dm(e):[]})}function cm(e){return oi(e)}function um(e){return oi(e)&&oi(e.target)}function oi(e){return typeof e=="object"&&e!==null}function pm(e){return da(e.target.files).map(t=>Zr(t))}function dm(e){return Tr(this,void 0,void 0,function*(){return(yield Promise.all(e.map(r=>r.getFile()))).map(r=>Zr(r))})}function fm(e,t){return Tr(this,void 0,void 0,function*(){if(e.items){const r=da(e.items).filter(i=>i.kind==="file");if(t!=="drop")return r;const n=yield Promise.all(r.map(hm));return ms(oc(n))}return ms(da(e.files).map(r=>Zr(r)))})}function ms(e){return e.filter(t=>sm.indexOf(t.name)===-1)}function da(e){if(e===null)return[];const t=[];for(let r=0;r<e.length;r++){const n=e[r];t.push(n)}return t}function hm(e){if(typeof e.webkitGetAsEntry!="function")return gs(e);const t=e.webkitGetAsEntry();return t&&t.isDirectory?sc(t):gs(e,t)}function oc(e){return e.reduce((t,r)=>[...t,...Array.isArray(r)?oc(r):[r]],[])}function gs(e,t){return Tr(this,void 0,void 0,function*(){var r;if(globalThis.isSecureContext&&typeof e.getAsFileSystemHandle=="function"){const a=yield e.getAsFileSystemHandle();if(a===null)throw new Error(`${e} is not a File`);if(a!==void 0){const o=yield a.getFile();return o.handle=a,Zr(o)}}const n=e.getAsFile();if(!n)throw new Error(`${e} is not a File`);return Zr(n,(r=t==null?void 0:t.fullPath)!==null&&r!==void 0?r:void 0)})}function mm(e){return Tr(this,void 0,void 0,function*(){return e.isDirectory?sc(e):gm(e)})}function sc(e){const t=e.createReader();return new Promise((r,n)=>{const i=[];function a(){t.readEntries(o=>Tr(this,void 0,void 0,function*(){if(o.length){const s=Promise.all(o.map(mm));i.push(s),a()}else try{const s=yield Promise.all(i);r(s)}catch(s){n(s)}}),o=>{n(o)})}a()})}function gm(e){return Tr(this,void 0,void 0,function*(){return new Promise((t,r)=>{e.file(n=>{const i=Zr(n,e.fullPath);t(i)},n=>{r(n)})})})}var Mn={},ys;function ym(){return ys||(ys=1,Mn.__esModule=!0,Mn.default=function(e,t){if(e&&t){var r=Array.isArray(t)?t:t.split(",");if(r.length===0)return!0;var n=e.name||"",i=(e.type||"").toLowerCase(),a=i.replace(/\/.*$/,"");return r.some(function(o){var s=o.trim().toLowerCase();return s.charAt(0)==="."?n.toLowerCase().endsWith(s):s.endsWith("/*")?a===s.replace(/\/.*$/,""):i===s})}return!0}),Mn}var xm=ym();const Ii=Oa(xm);function xs(e){return wm(e)||bm(e)||cc(e)||vm()}function vm(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
180
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function bm(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function wm(e){if(Array.isArray(e))return fa(e)}function vs(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function bs(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?vs(Object(r),!0).forEach(function(n){lc(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):vs(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function lc(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function yn(e,t){return Em(e)||Cm(e,t)||cc(e,t)||Sm()}function Sm(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
181
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function cc(e,t){if(e){if(typeof e=="string")return fa(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return fa(e,t)}}function fa(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function Cm(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n=[],i=!0,a=!1,o,s;try{for(r=r.call(e);!(i=(o=r.next()).done)&&(n.push(o.value),!(t&&n.length===t));i=!0);}catch(l){a=!0,s=l}finally{try{!i&&r.return!=null&&r.return()}finally{if(a)throw s}}return n}}function Em(e){if(Array.isArray(e))return e}var km=typeof Ii=="function"?Ii:Ii.default,Tm="file-invalid-type",Om="file-too-large",jm="file-too-small",Fm="too-many-files",_m=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"",r=t.split(","),n=r.length>1?"one of ".concat(r.join(", ")):r[0];return{code:Tm,message:"File type must be ".concat(n)}},ws=function(t){return{code:Om,message:"File is larger than ".concat(t," ").concat(t===1?"byte":"bytes")}},Ss=function(t){return{code:jm,message:"File is smaller than ".concat(t," ").concat(t===1?"byte":"bytes")}},Am={code:Fm,message:"Too many files"};function uc(e,t){var r=e.type==="application/x-moz-file"||km(e,t);return[r,r?null:_m(t)]}function pc(e,t,r){if(sr(e.size))if(sr(t)&&sr(r)){if(e.size>r)return[!1,ws(r)];if(e.size<t)return[!1,Ss(t)]}else{if(sr(t)&&e.size<t)return[!1,Ss(t)];if(sr(r)&&e.size>r)return[!1,ws(r)]}return[!0,null]}function sr(e){return e!=null}function Rm(e){var t=e.files,r=e.accept,n=e.minSize,i=e.maxSize,a=e.multiple,o=e.maxFiles,s=e.validator;return!a&&t.length>1||a&&o>=1&&t.length>o?!1:t.every(function(l){var p=uc(l,r),u=yn(p,1),d=u[0],f=pc(l,n,i),y=yn(f,1),S=y[0],c=s?s(l):null;return d&&S&&!c})}function si(e){return typeof e.isPropagationStopped=="function"?e.isPropagationStopped():typeof e.cancelBubble<"u"?e.cancelBubble:!1}function zn(e){return e.dataTransfer?Array.prototype.some.call(e.dataTransfer.types,function(t){return t==="Files"||t==="application/x-moz-file"}):!!e.target&&!!e.target.files}function Cs(e){e.preventDefault()}function $m(e){return e.indexOf("MSIE")!==-1||e.indexOf("Trident/")!==-1}function Dm(e){return e.indexOf("Edge/")!==-1}function Pm(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:window.navigator.userAgent;return $m(e)||Dm(e)}function St(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return function(n){for(var i=arguments.length,a=new Array(i>1?i-1:0),o=1;o<i;o++)a[o-1]=arguments[o];return t.some(function(s){return!si(n)&&s&&s.apply(void 0,[n].concat(a)),si(n)})}}function Im(){return"showOpenFilePicker"in window}function Mm(e){if(sr(e)){var t=Object.entries(e).filter(function(r){var n=yn(r,2),i=n[0],a=n[1],o=!0;return dc(i)||(console.warn('Skipped "'.concat(i,'" because it is not a valid MIME type. Check https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types/Common_types for a list of valid MIME types.')),o=!1),(!Array.isArray(a)||!a.every(fc))&&(console.warn('Skipped "'.concat(i,'" because an invalid file extension was provided.')),o=!1),o}).reduce(function(r,n){var i=yn(n,2),a=i[0],o=i[1];return bs(bs({},r),{},lc({},a,o))},{});return[{description:"Files",accept:t}]}return e}function zm(e){if(sr(e))return Object.entries(e).reduce(function(t,r){var n=yn(r,2),i=n[0],a=n[1];return[].concat(xs(t),[i],xs(a))},[]).filter(function(t){return dc(t)||fc(t)}).join(",")}function Vm(e){return e instanceof DOMException&&(e.name==="AbortError"||e.code===e.ABORT_ERR)}function Bm(e){return e instanceof DOMException&&(e.name==="SecurityError"||e.code===e.SECURITY_ERR)}function dc(e){return e==="audio/*"||e==="video/*"||e==="image/*"||e==="text/*"||e==="application/*"||/\w+\/[-+.\w]+/g.test(e)}function fc(e){return/^.*\.[\w]+$/.test(e)}var Nm=["children"],Lm=["open"],qm=["refKey","role","onKeyDown","onFocus","onBlur","onClick","onDragEnter","onDragOver","onDragLeave","onDrop"],Um=["refKey","onChange","onClick"];function Wm(e){return Qm(e)||Km(e)||hc(e)||Hm()}function Hm(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
182
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Km(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Qm(e){if(Array.isArray(e))return ha(e)}function Mi(e,t){return Zm(e)||Gm(e,t)||hc(e,t)||Ym()}function Ym(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
183
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function hc(e,t){if(e){if(typeof e=="string")return ha(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return ha(e,t)}}function ha(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function Gm(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n=[],i=!0,a=!1,o,s;try{for(r=r.call(e);!(i=(o=r.next()).done)&&(n.push(o.value),!(t&&n.length===t));i=!0);}catch(l){a=!0,s=l}finally{try{!i&&r.return!=null&&r.return()}finally{if(a)throw s}}return n}}function Zm(e){if(Array.isArray(e))return e}function Es(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Ae(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Es(Object(r),!0).forEach(function(n){ma(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Es(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function ma(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function li(e,t){if(e==null)return{};var r=Xm(e,t),n,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)n=a[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function Xm(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,a;for(a=0;a<n.length;a++)i=n[a],!(t.indexOf(i)>=0)&&(r[i]=e[i]);return r}var Wa=$.forwardRef(function(e,t){var r=e.children,n=li(e,Nm),i=gc(n),a=i.open,o=li(i,Lm);return $.useImperativeHandle(t,function(){return{open:a}},[a]),$.createElement($.Fragment,null,r(Ae(Ae({},o),{},{open:a})))});Wa.displayName="Dropzone";var mc={disabled:!1,getFilesFromEvent:lm,maxSize:1/0,minSize:0,multiple:!0,maxFiles:0,preventDropOnDocument:!0,noClick:!1,noKeyboard:!1,noDrag:!1,noDragEventsBubbling:!1,validator:null,useFsAccessApi:!1,autoFocus:!1};Wa.defaultProps=mc;Wa.propTypes={children:w.func,accept:w.objectOf(w.arrayOf(w.string)),multiple:w.bool,preventDropOnDocument:w.bool,noClick:w.bool,noKeyboard:w.bool,noDrag:w.bool,noDragEventsBubbling:w.bool,minSize:w.number,maxSize:w.number,maxFiles:w.number,disabled:w.bool,getFilesFromEvent:w.func,onFileDialogCancel:w.func,onFileDialogOpen:w.func,useFsAccessApi:w.bool,autoFocus:w.bool,onDragEnter:w.func,onDragLeave:w.func,onDragOver:w.func,onDrop:w.func,onDropAccepted:w.func,onDropRejected:w.func,onError:w.func,validator:w.func};var ga={isFocused:!1,isFileDialogActive:!1,isDragActive:!1,isDragAccept:!1,isDragReject:!1,acceptedFiles:[],fileRejections:[]};function gc(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=Ae(Ae({},mc),e),r=t.accept,n=t.disabled,i=t.getFilesFromEvent,a=t.maxSize,o=t.minSize,s=t.multiple,l=t.maxFiles,p=t.onDragEnter,u=t.onDragLeave,d=t.onDragOver,f=t.onDrop,y=t.onDropAccepted,S=t.onDropRejected,c=t.onFileDialogCancel,b=t.onFileDialogOpen,g=t.useFsAccessApi,O=t.autoFocus,A=t.preventDropOnDocument,k=t.noClick,x=t.noKeyboard,B=t.noDrag,_=t.noDragEventsBubbling,K=t.onError,W=t.validator,h=$.useMemo(function(){return zm(r)},[r]),M=$.useMemo(function(){return Mm(r)},[r]),P=$.useMemo(function(){return typeof b=="function"?b:ks},[b]),q=$.useMemo(function(){return typeof c=="function"?c:ks},[c]),N=$.useRef(null),X=$.useRef(null),ie=$.useReducer(Jm,ga),ge=Mi(ie,2),ce=ge[0],se=ge[1],V=ce.isFocused,H=ce.isFileDialogActive,ue=$.useRef(typeof window<"u"&&window.isSecureContext&&g&&Im()),Y=function(){!ue.current&&H&&setTimeout(function(){if(X.current){var R=X.current.files;R.length||(se({type:"closeDialog"}),q())}},300)};$.useEffect(function(){return window.addEventListener("focus",Y,!1),function(){window.removeEventListener("focus",Y,!1)}},[X,H,q,ue]);var te=$.useRef([]),le=function(R){N.current&&N.current.contains(R.target)||(R.preventDefault(),te.current=[])};$.useEffect(function(){return A&&(document.addEventListener("dragover",Cs,!1),document.addEventListener("drop",le,!1)),function(){A&&(document.removeEventListener("dragover",Cs),document.removeEventListener("drop",le))}},[N,A]),$.useEffect(function(){return!n&&O&&N.current&&N.current.focus(),function(){}},[N,O,n]);var U=$.useCallback(function(F){K?K(F):console.error(F)},[K]),ee=$.useCallback(function(F){F.preventDefault(),F.persist(),v(F),te.current=[].concat(Wm(te.current),[F.target]),zn(F)&&Promise.resolve(i(F)).then(function(R){if(!(si(F)&&!_)){var J=R.length,he=J>0&&Rm({files:R,accept:h,minSize:o,maxSize:a,multiple:s,maxFiles:l,validator:W}),ye=J>0&&!he;se({isDragAccept:he,isDragReject:ye,isDragActive:!0,type:"setDraggedFiles"}),p&&p(F)}}).catch(function(R){return U(R)})},[i,p,U,_,h,o,a,s,l,W]),oe=$.useCallback(function(F){F.preventDefault(),F.persist(),v(F);var R=zn(F);if(R&&F.dataTransfer)try{F.dataTransfer.dropEffect="copy"}catch{}return R&&d&&d(F),!1},[d,_]),fe=$.useCallback(function(F){F.preventDefault(),F.persist(),v(F);var R=te.current.filter(function(he){return N.current&&N.current.contains(he)}),J=R.indexOf(F.target);J!==-1&&R.splice(J,1),te.current=R,!(R.length>0)&&(se({type:"setDraggedFiles",isDragActive:!1,isDragAccept:!1,isDragReject:!1}),zn(F)&&u&&u(F))},[N,u,_]),pe=$.useCallback(function(F,R){var J=[],he=[];F.forEach(function(ye){var Be=uc(ye,h),ft=Mi(Be,2),st=ft[0],Jr=ft[1],ir=pc(ye,o,a),zt=Mi(ir,2),en=zt[0],Or=zt[1],tn=W?W(ye):null;if(st&&en&&!tn)J.push(ye);else{var jr=[Jr,Or];tn&&(jr=jr.concat(tn)),he.push({file:ye,errors:jr.filter(function(xc){return xc})})}}),(!s&&J.length>1||s&&l>=1&&J.length>l)&&(J.forEach(function(ye){he.push({file:ye,errors:[Am]})}),J.splice(0)),se({acceptedFiles:J,fileRejections:he,isDragReject:he.length>0,type:"setFiles"}),f&&f(J,he,R),he.length>0&&S&&S(he,R),J.length>0&&y&&y(J,R)},[se,s,h,o,a,l,f,y,S,W]),L=$.useCallback(function(F){F.preventDefault(),F.persist(),v(F),te.current=[],zn(F)&&Promise.resolve(i(F)).then(function(R){si(F)&&!_||pe(R,F)}).catch(function(R){return U(R)}),se({type:"reset"})},[i,pe,U,_]),I=$.useCallback(function(){if(ue.current){se({type:"openDialog"}),P();var F={multiple:s,types:M};window.showOpenFilePicker(F).then(function(R){return i(R)}).then(function(R){pe(R,null),se({type:"closeDialog"})}).catch(function(R){Vm(R)?(q(R),se({type:"closeDialog"})):Bm(R)?(ue.current=!1,X.current?(X.current.value=null,X.current.click()):U(new Error("Cannot open the file picker because the https://developer.mozilla.org/en-US/docs/Web/API/File_System_Access_API is not supported and no <input> was provided."))):U(R)});return}X.current&&(se({type:"openDialog"}),P(),X.current.value=null,X.current.click())},[se,P,q,g,pe,U,M,s]),z=$.useCallback(function(F){!N.current||!N.current.isEqualNode(F.target)||(F.key===" "||F.key==="Enter"||F.keyCode===32||F.keyCode===13)&&(F.preventDefault(),I())},[N,I]),ae=$.useCallback(function(){se({type:"focus"})},[]),de=$.useCallback(function(){se({type:"blur"})},[]),_e=$.useCallback(function(){k||(Pm()?setTimeout(I,0):I())},[k,I]),Te=function(R){return n?null:R},Qe=function(R){return x?null:Te(R)},Ye=function(R){return B?null:Te(R)},v=function(R){_&&R.stopPropagation()},j=$.useMemo(function(){return function(){var F=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},R=F.refKey,J=R===void 0?"ref":R,he=F.role,ye=F.onKeyDown,Be=F.onFocus,ft=F.onBlur,st=F.onClick,Jr=F.onDragEnter,ir=F.onDragOver,zt=F.onDragLeave,en=F.onDrop,Or=li(F,qm);return Ae(Ae(ma({onKeyDown:Qe(St(ye,z)),onFocus:Qe(St(Be,ae)),onBlur:Qe(St(ft,de)),onClick:Te(St(st,_e)),onDragEnter:Ye(St(Jr,ee)),onDragOver:Ye(St(ir,oe)),onDragLeave:Ye(St(zt,fe)),onDrop:Ye(St(en,L)),role:typeof he=="string"&&he!==""?he:"presentation"},J,N),!n&&!x?{tabIndex:0}:{}),Or)}},[N,z,ae,de,_e,ee,oe,fe,L,x,B,n]),T=$.useCallback(function(F){F.stopPropagation()},[]),G=$.useMemo(function(){return function(){var F=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},R=F.refKey,J=R===void 0?"ref":R,he=F.onChange,ye=F.onClick,Be=li(F,Um),ft=ma({accept:h,multiple:s,type:"file",style:{border:0,clip:"rect(0, 0, 0, 0)",clipPath:"inset(50%)",height:"1px",margin:"0 -1px -1px 0",overflow:"hidden",padding:0,position:"absolute",width:"1px",whiteSpace:"nowrap"},onChange:Te(St(he,L)),onClick:Te(St(ye,T)),tabIndex:-1},J,X);return Ae(Ae({},ft),Be)}},[X,r,s,L,n]);return Ae(Ae({},ce),{},{isFocused:V&&!n,getRootProps:j,getInputProps:G,rootRef:N,inputRef:X,open:Te(I)})}function Jm(e,t){switch(t.type){case"focus":return Ae(Ae({},e),{},{isFocused:!0});case"blur":return Ae(Ae({},e),{},{isFocused:!1});case"openDialog":return Ae(Ae({},ga),{},{isFileDialogActive:!0});case"closeDialog":return Ae(Ae({},e),{},{isFileDialogActive:!1});case"setDraggedFiles":return Ae(Ae({},e),{},{isDragActive:t.isDragActive,isDragAccept:t.isDragAccept,isDragReject:t.isDragReject});case"setFiles":return Ae(Ae({},e),{},{acceptedFiles:t.acceptedFiles,fileRejections:t.fileRejections,isDragReject:t.isDragReject});case"reset":return Ae({},ga);default:return e}}function ks(){}const eg=vt(m.jsx("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m-2 15-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8z"}),"CheckCircle"),tg=vt(m.jsx("path",{d:"M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6zM19 4h-3.5l-1-1h-5l-1 1H5v2h14z"}),"Delete"),Ts=vt(m.jsx("path",{d:"M14 2H6c-1.1 0-1.99.9-1.99 2L4 20c0 1.1.89 2 1.99 2H18c1.1 0 2-.9 2-2V8zm2 16H8v-2h8zm0-4H8v-2h8zm-3-5V3.5L18.5 9z"}),"Description"),rg=vt(m.jsx("path",{d:"M21 19V5c0-1.1-.9-2-2-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2M8.5 13.5l2.5 3.01L14.5 12l4.5 6H5z"}),"Image"),yc=({file:e,onRemove:t})=>{const r=()=>e.file.type.startsWith("image/")?m.jsx(rg,{}):e.file.type.includes("pdf")?m.jsx(Ts,{}):m.jsx(Ts,{}),n=()=>{switch(e.status){case"success":return m.jsx(eg,{color:"success"});case"uploading":return m.jsx(E.CircularProgress,{size:16});default:return null}},i=a=>{if(a===0)return"0 Bytes";const o=1024,s=["Bytes","KB","MB","GB"],l=Math.floor(Math.log(a)/Math.log(o));return parseFloat((a/Math.pow(o,l)).toFixed(2))+" "+s[l]};return m.jsxs(E.Paper,{sx:{p:2,mb:1,display:"flex",alignItems:"center",gap:2,border:"1px solid #e0e0e0"},children:[m.jsxs(E.Box,{sx:{display:"flex",alignItems:"center",gap:1},children:[r(),n()]}),m.jsxs(E.Box,{sx:{flex:1,minWidth:0},children:[m.jsx(E.Typography,{variant:"body2",noWrap:!0,children:e.file.name}),m.jsxs(E.Typography,{variant:"caption",color:"textSecondary",children:[i(e.file.size)," • ",e.file.type]})]}),m.jsx(E.Tooltip,{title:"Remove file",children:m.jsx(E.IconButton,{size:"small",onClick:()=>t(e.id),color:"error",children:m.jsx(tg,{})})})]})},ng=({config:e,value:t=[],onChange:r,onSubmit:n,disabled:i=!1,className:a,style:o,title:s,subtitle:l,buttonText:p,fileSupportedText:u})=>{const[d,f]=$.useState(t),[y,S]=$.useState([]),[c,b]=$.useState(!1),[g,O]=$.useState(!1),[A,k]=$.useState([]),x=$.useRef(null);$.useEffect(()=>{f(t)},[t]);const B=$.useCallback(N=>{var ie,ge;return((ie=e==null?void 0:e.fileTypes)==null?void 0:ie.some(ce=>{if(ce.includes("*")){const se=ce.split("/")[0];return N.type.startsWith(se)}return N.type===ce}))?e!=null&&e.maxSize&&N.size>e.maxSize?`File size exceeds maximum limit of ${(e.maxSize/1048576).toFixed(1)}MB`:null:`File type ${N.type} is not allowed. Allowed types: ${(ge=e==null?void 0:e.fileTypes)==null?void 0:ge.join(", ")}`},[e]),_=$.useCallback(async N=>{console.log("handleFiles called with:",N.length,"files"),b(!0);const X=[],ie=[];try{for(const ce of N){let se=null;if(e!=null&&e.multiple&&d.some(H=>H.file.name===ce.name&&H.file.size===ce.size&&H.file.lastModified===ce.lastModified)){ie.push(`${ce.name}: File already exists`);continue}if(se=B(ce),!se&&(e!=null&&e.customValidation))try{const V=e.customValidation(ce);V instanceof Promise?se=await V:se=V}catch(V){se=`Custom validation failed: ${V instanceof Error?V.message:"Unknown error"}`}if(se)ie.push(`${ce.name}: ${se}`);else{const V={id:`${Date.now()}-${Math.random().toString(36).substr(2,9)}`,file:ce,preview:ce.type.startsWith("image/")?URL.createObjectURL(ce):void 0,progress:0,status:"pending",uploadedAt:new Date};X.push(V)}}const ge=e!=null&&e.multiple?[...d,...X]:X;f(ge),r==null||r(ge),ie.length>0?(k(ie),S(ie)):(k([]),S([]))}catch(ge){const ce=`Unexpected error: ${ge instanceof Error?ge.message:"Unknown error"}`;k([ce]),S([ce])}},[d,e==null?void 0:e.multiple,B,e==null?void 0:e.customValidation,r]),K=$.useCallback(N=>{b(!0);const X=d.filter(ie=>ie.id!==N);f(X),r==null||r(X),k([]),x.current&&(x.current.value="")},[d,r]),W=$.useCallback(()=>{if(e!=null&&e.required&&d.length===0){S([`${e.title} is required`]);return}k([]),O(!0);const N=d.filter(X=>X.status!=="error");n==null||n(N)},[d,n,e==null?void 0:e.required,e==null?void 0:e.title]),{getRootProps:h,getInputProps:M,isDragActive:P}=gc({onDrop:_,multiple:e==null?void 0:e.multiple,disabled:i,noClick:!1,noKeyboard:!1});$.useEffect(()=>{if(!c)return;const N=[],X=[...A,...N];X.length>0?S(X):S([])},[d,e==null?void 0:e.required,e==null?void 0:e.title,c,g,A]);const q=()=>{var N;switch(((N=e==null?void 0:e.submitButton)==null?void 0:N.position)||"right"){case"left":return"flex-start";case"center":return"center";case"right":return"flex-end";default:return"flex-end"}};return m.jsxs(E.Box,{className:a,style:o,children:[m.jsxs(E.Typography,{variant:"h6",gutterBottom:!0,children:[e==null?void 0:e.title,(e==null?void 0:e.required)&&m.jsx("span",{style:{color:"red"},children:" *"})]}),(e==null?void 0:e.description)&&m.jsx(E.Typography,{variant:"body2",color:"textSecondary",gutterBottom:!0,children:e==null?void 0:e.description}),$.createElement(E.Card,{...h(),key:`dropzone-${d.length}`,sx:{border:"1px dashed",borderColor:P?"primary.main":"#CCCCCC",backgroundColor:P?"action.hover":"#F5F5F5",boxShadow:"none",p:3,textAlign:"center",cursor:i?"not-allowed":"pointer",transition:"all 0.2s ease","&:hover":{borderColor:i?"grey.300":"primary.main",backgroundColor:i?"background.paper":"action.hover"}}},m.jsx("input",{...M(),ref:x}),m.jsx(E.IconButton,{sx:{borderRadius:"8px"},children:m.jsx(ni,{sx:{width:36,height:36,color:"primary.main"}})}),m.jsx(E.Typography,{sx:{fontSize:"16px",fontWeight:600,color:"primary.main"},children:s}),m.jsx(E.Typography,{sx:{fontSize:"12px",fontWeight:400,color:"primary.main"},children:l}),m.jsx(E.Button,{onClick:()=>{var N;return(N=x.current)==null?void 0:N.click()},sx:{my:2},startIcon:m.jsx(ni,{}),variant:"contained",children:p}),m.jsx(E.Typography,{sx:{fontSize:"12px",fontWeight:400},children:u})),y.length>0&&m.jsx(E.Alert,{severity:"error",sx:{mt:2},children:y.map((N,X)=>m.jsx(E.Typography,{variant:"body2",children:N},X))}),d.length>0&&m.jsxs(E.Box,{sx:{mt:2},children:[m.jsxs(E.Typography,{variant:"subtitle1",gutterBottom:!0,children:["Selected Files (",d.length,")"]}),d.map(N=>m.jsx(yc,{file:N,onRemove:K},N.id))]}),(e==null?void 0:e.helperText)&&m.jsx(E.Typography,{variant:"caption",color:"textSecondary",sx:{mt:1,display:"block"},children:e.helperText}),(e==null?void 0:e.submitButton)&&m.jsx(E.Box,{sx:{mt:3,display:"flex",justifyContent:q()},children:m.jsx(E.Button,{variant:"contained",onClick:W,disabled:i||e.submitButton.disabled||d.length===0,startIcon:e.submitButton.loading?m.jsx(E.CircularProgress,{size:16,color:"inherit"}):void 0,children:e.submitButton.text})})]})};exports.CustomButtons=ac;exports.DocumentUpload=ng;exports.FieldRenderer=Nl;exports.FilePreview=yc;exports.FinAutocomplete=Rl;exports.FinCheckbox=$l;exports.FinChip=zl;exports.FinCustomizedVerticalStepper=gh;exports.FinDateField=Pl;exports.FinDragDropList=dh;exports.FinForm=rm;exports.FinInfoCard=xh;exports.FinRadioGroup=la;exports.FinSelect=Al;exports.FinSwitch=Dl;exports.FinTabs=vh;exports.FinTextField=sa;exports.FinTextarea=Il;exports.FinUiHeader=Ml;exports.FinVerticalStepper=hh;exports.ImageComponent=im;exports.StepNavigation=ic;exports.brand=ch;exports.fetchApiData=Vl;exports.finflowPalette=Q;exports.generateSchema=nc;exports.getApiConfig=La;exports.hasApiConfig=or;exports.neutral=tt;exports.primary=sh;exports.secondary=lh;exports.shouldShowField=bh;exports.useApiData=Bl;
179
+ `+(s!==o?`result of cast: ${s}`:""))}return a}_cast(t,r){let n=t===void 0?t:this.transforms.reduce((i,a)=>a.call(this,i,t,this),t);return n===void 0&&(n=this.getDefault(r)),n}_validate(t,r={},n,i){let{path:a,originalValue:o=t,strict:s=this.spec.strict}=r,l=t;s||(l=this._cast(l,Object.assign({assert:!1},r)));let p=[];for(let u of Object.values(this.internalTests))u&&p.push(u);this.runTests({path:a,value:l,originalValue:o,options:r,tests:p},n,u=>{if(u.length)return i(u,l);this.runTests({path:a,value:l,originalValue:o,options:r,tests:this.tests},n,i)})}runTests(t,r,n){let i=!1,{tests:a,value:o,originalValue:s,path:l,options:p}=t,u=c=>{i||(i=!0,r(c,o))},d=c=>{i||(i=!0,n(c,o))},f=a.length,g=[];if(!f)return d([]);let S={value:o,originalValue:s,path:l,options:p,schema:this};for(let c=0;c<a.length;c++){const b=a[c];b(S,u,function(j){j&&(Array.isArray(j)?g.push(...j):g.push(j)),--f<=0&&d(g)})}}asNestedTest({key:t,index:r,parent:n,parentPath:i,originalParent:a,options:o}){const s=t??r;if(s==null)throw TypeError("Must include `key` or `index` for nested validations");const l=typeof s=="number";let p=n[s];const u=Object.assign({},o,{strict:!0,parent:n,value:p,originalValue:a[s],key:void 0,[l?"index":"key"]:s,path:l||s.includes(".")?`${i||""}[${l?s:`"${s}"`}]`:(i?`${i}.`:"")+t});return(d,f,g)=>this.resolve(u)._validate(p,u,f,g)}validate(t,r){var n;let i=this.resolve(Object.assign({},r,{value:t})),a=(n=r==null?void 0:r.disableStackTrace)!=null?n:i.spec.disableStackTrace;return new Promise((o,s)=>i._validate(t,r,(l,p)=>{et.isError(l)&&(l.value=p),s(l)},(l,p)=>{l.length?s(new et(l,p,void 0,void 0,a)):o(p)}))}validateSync(t,r){var n;let i=this.resolve(Object.assign({},r,{value:t})),a,o=(n=r==null?void 0:r.disableStackTrace)!=null?n:i.spec.disableStackTrace;return i._validate(t,Object.assign({},r,{sync:!0}),(s,l)=>{throw et.isError(s)&&(s.value=l),s},(s,l)=>{if(s.length)throw new et(s,t,void 0,void 0,o);a=l}),a}isValid(t,r){return this.validate(t,r).then(()=>!0,n=>{if(et.isError(n))return!1;throw n})}isValidSync(t,r){try{return this.validateSync(t,r),!0}catch(n){if(et.isError(n))return!1;throw n}}_getDefault(t){let r=this.spec.default;return r==null?r:typeof r=="function"?r.call(this,t):Ir(r)}getDefault(t){return this.resolve(t||{})._getDefault(t)}default(t){return arguments.length===0?this._getDefault():this.clone({default:t})}strict(t=!0){return this.clone({strict:t})}nullability(t,r){const n=this.clone({nullable:t});return n.internalTests.nullable=Pr({message:r,name:"nullable",test(i){return i===null?this.schema.spec.nullable:!0}}),n}optionality(t,r){const n=this.clone({optional:t});return n.internalTests.optionality=Pr({message:r,name:"optionality",test(i){return i===void 0?this.schema.spec.optional:!0}}),n}optional(){return this.optionality(!0)}defined(t=Ct.defined){return this.optionality(!1,t)}nullable(){return this.nullability(!0)}nonNullable(t=Ct.notNull){return this.nullability(!1,t)}required(t=Ct.required){return this.clone().withMutation(r=>r.nonNullable(t).defined(t))}notRequired(){return this.clone().withMutation(t=>t.nullable().optional())}transform(t){let r=this.clone();return r.transforms.push(t),r}test(...t){let r;if(t.length===1?typeof t[0]=="function"?r={test:t[0]}:r=t[0]:t.length===2?r={name:t[0],test:t[1]}:r={name:t[0],message:t[1],test:t[2]},r.message===void 0&&(r.message=Ct.default),typeof r.test!="function")throw new TypeError("`test` is a required parameters");let n=this.clone(),i=Pr(r),a=r.exclusive||r.name&&n.exclusiveTests[r.name]===!0;if(r.exclusive&&!r.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return r.name&&(n.exclusiveTests[r.name]=!!r.exclusive),n.tests=n.tests.filter(o=>!(o.OPTIONS.name===r.name&&(a||o.OPTIONS.test===i.OPTIONS.test))),n.tests.push(i),n}when(t,r){!Array.isArray(t)&&typeof t!="string"&&(r=t,t=".");let n=this.clone(),i=Ll(t).map(a=>new kr(a));return i.forEach(a=>{a.isSibling&&n.deps.push(a.key)}),n.conditions.push(typeof r=="function"?new ii(i,r):ii.fromOptions(i,r)),n}typeError(t){let r=this.clone();return r.internalTests.typeError=Pr({message:t,name:"typeError",skipAbsent:!0,test(n){return this.schema._typeCheck(n)?!0:this.createError({params:{type:this.schema.type}})}}),r}oneOf(t,r=Ct.oneOf){let n=this.clone();return t.forEach(i=>{n._whitelist.add(i),n._blacklist.delete(i)}),n.internalTests.whiteList=Pr({message:r,name:"oneOf",skipAbsent:!0,test(i){let a=this.schema._whitelist,o=a.resolveAll(this.resolve);return o.includes(i)?!0:this.createError({params:{values:Array.from(a).join(", "),resolved:o}})}}),n}notOneOf(t,r=Ct.notOneOf){let n=this.clone();return t.forEach(i=>{n._blacklist.add(i),n._whitelist.delete(i)}),n.internalTests.blacklist=Pr({message:r,name:"notOneOf",test(i){let a=this.schema._blacklist,o=a.resolveAll(this.resolve);return o.includes(i)?this.createError({params:{values:Array.from(a).join(", "),resolved:o}}):!0}}),n}strip(t=!0){let r=this.clone();return r.spec.strip=t,r}describe(t){const r=(t?this.resolve(t):this).clone(),{label:n,meta:i,optional:a,nullable:o}=r.spec;return{meta:i,label:n,optional:a,nullable:o,default:r.getDefault(t),type:r.type,oneOf:r._whitelist.describe(),notOneOf:r._blacklist.describe(),tests:r.tests.map(l=>({name:l.OPTIONS.name,params:l.OPTIONS.params})).filter((l,p,u)=>u.findIndex(d=>d.name===l.name)===p)}}}at.prototype.__isYupSchema__=!0;for(const e of["validate","validateSync"])at.prototype[`${e}At`]=function(t,r,n={}){const{parent:i,parentPath:a,schema:o}=Ph(this,t,r,n.context);return o[e](i&&i[a],Object.assign({},n,{parent:i,path:t}))};for(const e of["equals","is"])at.prototype[e]=at.prototype.oneOf;for(const e of["not","nope"])at.prototype[e]=at.prototype.notOneOf;const Ih=()=>!0;function Hl(e){return new Kl(e)}class Kl extends at{constructor(t){super(typeof t=="function"?{type:"mixed",check:t}:Object.assign({type:"mixed",check:Ih},t))}}Hl.prototype=Kl.prototype;function Ql(){return new Yl}class Yl extends at{constructor(){super({type:"boolean",check(t){return t instanceof Boolean&&(t=t.valueOf()),typeof t=="boolean"}}),this.withMutation(()=>{this.transform((t,r,n)=>{if(n.spec.coerce&&!n.isType(t)){if(/^(true|1)$/i.test(String(t)))return!0;if(/^(false|0)$/i.test(String(t)))return!1}return t})})}isTrue(t=fa.isValue){return this.test({message:t,name:"is-value",exclusive:!0,params:{value:"true"},test(r){return vt(r)||r===!0}})}isFalse(t=fa.isValue){return this.test({message:t,name:"is-value",exclusive:!0,params:{value:"false"},test(r){return vt(r)||r===!1}})}default(t){return super.default(t)}defined(t){return super.defined(t)}optional(){return super.optional()}required(t){return super.required(t)}notRequired(){return super.notRequired()}nullable(){return super.nullable()}nonNullable(t){return super.nonNullable(t)}strip(t){return super.strip(t)}}Ql.prototype=Yl.prototype;const Mh=/^(\d{4}|[+-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,.](\d{1,}))?)?(?:(Z)|([+-])(\d{2})(?::?(\d{2}))?)?)?$/;function zh(e){const t=ha(e);if(!t)return Date.parse?Date.parse(e):Number.NaN;if(t.z===void 0&&t.plusMinus===void 0)return new Date(t.year,t.month,t.day,t.hour,t.minute,t.second,t.millisecond).valueOf();let r=0;return t.z!=="Z"&&t.plusMinus!==void 0&&(r=t.hourOffset*60+t.minuteOffset,t.plusMinus==="+"&&(r=0-r)),Date.UTC(t.year,t.month,t.day,t.hour,t.minute+r,t.second,t.millisecond)}function ha(e){var t,r;const n=Mh.exec(e);return n?{year:Dt(n[1]),month:Dt(n[2],1)-1,day:Dt(n[3],1),hour:Dt(n[4]),minute:Dt(n[5]),second:Dt(n[6]),millisecond:n[7]?Dt(n[7].substring(0,3)):0,precision:(t=(r=n[7])==null?void 0:r.length)!=null?t:void 0,z:n[8]||void 0,plusMinus:n[9]||void 0,hourOffset:Dt(n[10]),minuteOffset:Dt(n[11])}:null}function Dt(e,t=0){return Number(e)||t}let Vh=/^[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,Bh=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,Nh=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,Lh="^\\d{4}-\\d{2}-\\d{2}",qh="\\d{2}:\\d{2}:\\d{2}",Uh="(([+-]\\d{2}(:?\\d{2})?)|Z)",Wh=new RegExp(`${Lh}T${qh}(\\.\\d+)?${Uh}$`),Hh=e=>vt(e)||e===e.trim(),Kh={}.toString();function un(){return new Gl}class Gl extends at{constructor(){super({type:"string",check(t){return t instanceof String&&(t=t.valueOf()),typeof t=="string"}}),this.withMutation(()=>{this.transform((t,r,n)=>{if(!n.spec.coerce||n.isType(t)||Array.isArray(t))return t;const i=t!=null&&t.toString?t.toString():t;return i===Kh?t:i})})}required(t){return super.required(t).withMutation(r=>r.test({message:t||Ct.required,name:"required",skipAbsent:!0,test:n=>!!n.length}))}notRequired(){return super.notRequired().withMutation(t=>(t.tests=t.tests.filter(r=>r.OPTIONS.name!=="required"),t))}length(t,r=Ge.length){return this.test({message:r,name:"length",exclusive:!0,params:{length:t},skipAbsent:!0,test(n){return n.length===this.resolve(t)}})}min(t,r=Ge.min){return this.test({message:r,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(n){return n.length>=this.resolve(t)}})}max(t,r=Ge.max){return this.test({name:"max",exclusive:!0,message:r,params:{max:t},skipAbsent:!0,test(n){return n.length<=this.resolve(t)}})}matches(t,r){let n=!1,i,a;return r&&(typeof r=="object"?{excludeEmptyString:n=!1,message:i,name:a}=r:i=r),this.test({name:a||"matches",message:i||Ge.matches,params:{regex:t},skipAbsent:!0,test:o=>o===""&&n||o.search(t)!==-1})}email(t=Ge.email){return this.matches(Vh,{name:"email",message:t,excludeEmptyString:!0})}url(t=Ge.url){return this.matches(Bh,{name:"url",message:t,excludeEmptyString:!0})}uuid(t=Ge.uuid){return this.matches(Nh,{name:"uuid",message:t,excludeEmptyString:!1})}datetime(t){let r="",n,i;return t&&(typeof t=="object"?{message:r="",allowOffset:n=!1,precision:i=void 0}=t:r=t),this.matches(Wh,{name:"datetime",message:r||Ge.datetime,excludeEmptyString:!0}).test({name:"datetime_offset",message:r||Ge.datetime_offset,params:{allowOffset:n},skipAbsent:!0,test:a=>{if(!a||n)return!0;const o=ha(a);return o?!!o.z:!1}}).test({name:"datetime_precision",message:r||Ge.datetime_precision,params:{precision:i},skipAbsent:!0,test:a=>{if(!a||i==null)return!0;const o=ha(a);return o?o.precision===i:!1}})}ensure(){return this.default("").transform(t=>t===null?"":t)}trim(t=Ge.trim){return this.transform(r=>r!=null?r.trim():r).test({message:t,name:"trim",test:Hh})}lowercase(t=Ge.lowercase){return this.transform(r=>vt(r)?r:r.toLowerCase()).test({message:t,name:"string_case",exclusive:!0,skipAbsent:!0,test:r=>vt(r)||r===r.toLowerCase()})}uppercase(t=Ge.uppercase){return this.transform(r=>vt(r)?r:r.toUpperCase()).test({message:t,name:"string_case",exclusive:!0,skipAbsent:!0,test:r=>vt(r)||r===r.toUpperCase()})}}un.prototype=Gl.prototype;let Qh=e=>e!=+e;function Zl(){return new Xl}class Xl extends at{constructor(){super({type:"number",check(t){return t instanceof Number&&(t=t.valueOf()),typeof t=="number"&&!Qh(t)}}),this.withMutation(()=>{this.transform((t,r,n)=>{if(!n.spec.coerce)return t;let i=t;if(typeof i=="string"){if(i=i.replace(/\s/g,""),i==="")return NaN;i=+i}return n.isType(i)||i===null?i:parseFloat(i)})})}min(t,r=Nt.min){return this.test({message:r,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(n){return n>=this.resolve(t)}})}max(t,r=Nt.max){return this.test({message:r,name:"max",exclusive:!0,params:{max:t},skipAbsent:!0,test(n){return n<=this.resolve(t)}})}lessThan(t,r=Nt.lessThan){return this.test({message:r,name:"max",exclusive:!0,params:{less:t},skipAbsent:!0,test(n){return n<this.resolve(t)}})}moreThan(t,r=Nt.moreThan){return this.test({message:r,name:"min",exclusive:!0,params:{more:t},skipAbsent:!0,test(n){return n>this.resolve(t)}})}positive(t=Nt.positive){return this.moreThan(0,t)}negative(t=Nt.negative){return this.lessThan(0,t)}integer(t=Nt.integer){return this.test({name:"integer",message:t,skipAbsent:!0,test:r=>Number.isInteger(r)})}truncate(){return this.transform(t=>vt(t)?t:t|0)}round(t){var r;let n=["ceil","floor","round","trunc"];if(t=((r=t)==null?void 0:r.toLowerCase())||"round",t==="trunc")return this.truncate();if(n.indexOf(t.toLowerCase())===-1)throw new TypeError("Only valid options for round() are: "+n.join(", "));return this.transform(i=>vt(i)?i:Math[t](i))}}Zl.prototype=Xl.prototype;let Jl=new Date(""),Yh=e=>Object.prototype.toString.call(e)==="[object Date]";function Ka(){return new On}class On extends at{constructor(){super({type:"date",check(t){return Yh(t)&&!isNaN(t.getTime())}}),this.withMutation(()=>{this.transform((t,r,n)=>!n.spec.coerce||n.isType(t)||t===null?t:(t=zh(t),isNaN(t)?On.INVALID_DATE:new Date(t)))})}prepareParam(t,r){let n;if(kr.isRef(t))n=t;else{let i=this.cast(t);if(!this._typeCheck(i))throw new TypeError(`\`${r}\` must be a Date or a value that can be \`cast()\` to a Date`);n=i}return n}min(t,r=da.min){let n=this.prepareParam(t,"min");return this.test({message:r,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(i){return i>=this.resolve(n)}})}max(t,r=da.max){let n=this.prepareParam(t,"max");return this.test({message:r,name:"max",exclusive:!0,params:{max:t},skipAbsent:!0,test(i){return i<=this.resolve(n)}})}}On.INVALID_DATE=Jl;Ka.prototype=On.prototype;Ka.INVALID_DATE=Jl;function Gh(e,t=[]){let r=[],n=new Set,i=new Set(t.map(([o,s])=>`${o}-${s}`));function a(o,s){let l=vr.split(o)[0];n.add(l),i.has(`${s}-${l}`)||r.push([s,l])}for(const o of Object.keys(e)){let s=e[o];n.add(o),kr.isRef(s)&&s.isSibling?a(s.path,o):Ha(s)&&"deps"in s&&s.deps.forEach(l=>a(l,o))}return kh.array(Array.from(n),r).reverse()}function hs(e,t){let r=1/0;return e.some((n,i)=>{var a;if((a=t.path)!=null&&a.includes(n))return r=i,!0}),r}function ec(e){return(t,r)=>hs(e,t)-hs(e,r)}const Zh=(e,t,r)=>{if(typeof e!="string")return e;let n=e;try{n=JSON.parse(e)}catch{}return r.isType(n)?n:e};function Un(e){if("fields"in e){const t={};for(const[r,n]of Object.entries(e.fields))t[r]=Un(n);return e.setFields(t)}if(e.type==="array"){const t=e.optional();return t.innerType&&(t.innerType=Un(t.innerType)),t}return e.type==="tuple"?e.optional().clone({types:e.spec.types.map(Un)}):"optional"in e?e.optional():e}const Xh=(e,t)=>{const r=[...vr.normalizePath(t)];if(r.length===1)return r[0]in e;let n=r.pop(),i=vr.getter(vr.join(r),!0)(e);return!!(i&&n in i)};let ms=e=>Object.prototype.toString.call(e)==="[object Object]";function ys(e,t){let r=Object.keys(e.fields);return Object.keys(t).filter(n=>r.indexOf(n)===-1)}const Jh=ec([]);function tc(e){return new rc(e)}class rc extends at{constructor(t){super({type:"object",check(r){return ms(r)||typeof r=="function"}}),this.fields=Object.create(null),this._sortErrors=Jh,this._nodes=[],this._excludedEdges=[],this.withMutation(()=>{t&&this.shape(t)})}_cast(t,r={}){var n;let i=super._cast(t,r);if(i===void 0)return this.getDefault(r);if(!this._typeCheck(i))return i;let a=this.fields,o=(n=r.stripUnknown)!=null?n:this.spec.noUnknown,s=[].concat(this._nodes,Object.keys(i).filter(d=>!this._nodes.includes(d))),l={},p=Object.assign({},r,{parent:l,__validating:r.__validating||!1}),u=!1;for(const d of s){let f=a[d],g=d in i;if(f){let S,c=i[d];p.path=(r.path?`${r.path}.`:"")+d,f=f.resolve({value:c,context:r.context,parent:l});let b=f instanceof at?f.spec:void 0,y=b==null?void 0:b.strict;if(b!=null&&b.strip){u=u||d in i;continue}S=!r.__validating||!y?f.cast(i[d],p):i[d],S!==void 0&&(l[d]=S)}else g&&!o&&(l[d]=i[d]);(g!==d in l||l[d]!==i[d])&&(u=!0)}return u?l:i}_validate(t,r={},n,i){let{from:a=[],originalValue:o=t,recursive:s=this.spec.recursive}=r;r.from=[{schema:this,value:o},...a],r.__validating=!0,r.originalValue=o,super._validate(t,r,n,(l,p)=>{if(!s||!ms(p)){i(l,p);return}o=o||p;let u=[];for(let d of this._nodes){let f=this.fields[d];!f||kr.isRef(f)||u.push(f.asNestedTest({options:r,key:d,parent:p,parentPath:r.path,originalParent:o}))}this.runTests({tests:u,value:p,originalValue:o,options:r},n,d=>{i(d.sort(this._sortErrors).concat(l),p)})})}clone(t){const r=super.clone(t);return r.fields=Object.assign({},this.fields),r._nodes=this._nodes,r._excludedEdges=this._excludedEdges,r._sortErrors=this._sortErrors,r}concat(t){let r=super.concat(t),n=r.fields;for(let[i,a]of Object.entries(this.fields)){const o=n[i];n[i]=o===void 0?a:o}return r.withMutation(i=>i.setFields(n,[...this._excludedEdges,...t._excludedEdges]))}_getDefault(t){if("default"in this.spec)return super._getDefault(t);if(!this._nodes.length)return;let r={};return this._nodes.forEach(n=>{var i;const a=this.fields[n];let o=t;(i=o)!=null&&i.value&&(o=Object.assign({},o,{parent:o.value,value:o.value[n]})),r[n]=a&&"getDefault"in a?a.getDefault(o):void 0}),r}setFields(t,r){let n=this.clone();return n.fields=t,n._nodes=Gh(t,r),n._sortErrors=ec(Object.keys(t)),r&&(n._excludedEdges=r),n}shape(t,r=[]){return this.clone().withMutation(n=>{let i=n._excludedEdges;return r.length&&(Array.isArray(r[0])||(r=[r]),i=[...n._excludedEdges,...r]),n.setFields(Object.assign(n.fields,t),i)})}partial(){const t={};for(const[r,n]of Object.entries(this.fields))t[r]="optional"in n&&n.optional instanceof Function?n.optional():n;return this.setFields(t)}deepPartial(){return Un(this)}pick(t){const r={};for(const n of t)this.fields[n]&&(r[n]=this.fields[n]);return this.setFields(r,this._excludedEdges.filter(([n,i])=>t.includes(n)&&t.includes(i)))}omit(t){const r=[];for(const n of Object.keys(this.fields))t.includes(n)||r.push(n);return this.pick(r)}from(t,r,n){let i=vr.getter(t,!0);return this.transform(a=>{if(!a)return a;let o=a;return Xh(a,t)&&(o=Object.assign({},a),n||delete o[t],o[r]=i(a)),o})}json(){return this.transform(Zh)}exact(t){return this.test({name:"exact",exclusive:!0,message:t||qn.exact,test(r){if(r==null)return!0;const n=ys(this.schema,r);return n.length===0||this.createError({params:{properties:n.join(", ")}})}})}stripUnknown(){return this.clone({noUnknown:!0})}noUnknown(t=!0,r=qn.noUnknown){typeof t!="boolean"&&(r=t,t=!0);let n=this.test({name:"noUnknown",exclusive:!0,message:r,test(i){if(i==null)return!0;const a=ys(this.schema,i);return!t||a.length===0||this.createError({params:{unknown:a.join(", ")}})}});return n.spec.noUnknown=t,n}unknown(t=!0,r=qn.noUnknown){return this.noUnknown(!t,r)}transformKeys(t){return this.transform(r=>{if(!r)return r;const n={};for(const i of Object.keys(r))n[t(i)]=r[i];return n})}camelCase(){return this.transformKeys(Pi.camelCase)}snakeCase(){return this.transformKeys(Pi.snakeCase)}constantCase(){return this.transformKeys(t=>Pi.snakeCase(t).toUpperCase())}describe(t){const r=(t?this.resolve(t):this).clone(),n=super.describe(t);n.fields={};for(const[a,o]of Object.entries(r.fields)){var i;let s=t;(i=s)!=null&&i.value&&(s=Object.assign({},s,{parent:s.value,value:s.value[a]})),n.fields[a]=o.describe(s)}return n}}tc.prototype=rc.prototype;const nc=e=>{const t={};return e.forEach(r=>{var a,o,s;let n;switch(r.type){case"text":case"textarea":case"tel":n=un(),r.validation?n=ar(n,r,"string"):(r.minLength&&(n=n.min(r.minLength,`${r.label} must be at least ${r.minLength} characters`)),r.maxLength&&(n=n.max(r.maxLength,`${r.label} must be at most ${r.maxLength} characters`)),r.pattern&&(n=n.test("pattern",`${r.label} format is invalid`,l=>l?new RegExp(r.pattern).test(l):!0)));break;case"email":n=un().email(((a=r.validation)==null?void 0:a.message)||`${r.label} must be a valid email address`),r.validation&&(n=ar(n,r,"string"));break;case"password":n=un(),r.validation?n=ar(n,r,"string"):(r.minLength&&(n=n.min(r.minLength,`${r.label} must be at least ${r.minLength} characters`)),r.maxLength&&(n=n.max(r.maxLength,`${r.label} must be at most ${r.maxLength} characters`)),r.pattern&&(n=n.test("pattern",`${r.label} format is invalid`,l=>l?new RegExp(r.pattern).test(l):!0)));break;case"number":n=Zl().typeError(`${r.label} must be a number`),r.validation?n=ar(n,r,"number"):(r.min!==void 0&&(n=n.min(r.min,`${r.label} must be at least ${r.min}`)),r.max!==void 0&&(n=n.max(r.max,`${r.label} must be at most ${r.max}`)));break;case"select":n=un(),r.validation&&(n=ar(n,r,"string"));break;case"checkbox":n=Ql(),r.validation&&(n=ar(n,r,"boolean"));break;case"date":n=Ka().typeError(`${r.label} must be a valid date`),r.validation?n=ar(n,r,"date"):(r.minDate&&(n=n.min(new Date(r.minDate),`${r.label} must be after ${r.minDate}`)),r.maxDate&&(n=n.max(new Date(r.maxDate),`${r.label} must be before ${r.maxDate}`)));break;default:n=Hl()}if(((o=r.validation)==null?void 0:o.required)!==void 0?r.validation.required:r.required){const l=((s=r.validation)==null?void 0:s.message)||`${r.label} is required`;n=n.required(l)}t[r.name]=n}),tc().shape(t)},ar=(e,t,r)=>{const n=t.validation;if(!n)return e;if(r==="string"){if(n.minLength!==void 0){const i=n.message||`${t.label} must be at least ${n.minLength} characters`;e=e.min(n.minLength,i)}if(n.maxLength!==void 0){const i=n.message||`${t.label} must be at most ${n.maxLength} characters`;e=e.max(n.maxLength,i)}}if(r==="number"){if(n.min!==void 0){const i=n.message||`${t.label} must be at least ${n.min}`;e=e.min(n.min,i)}if(n.max!==void 0){const i=n.message||`${t.label} must be at most ${n.max}`;e=e.max(n.max,i)}}if(n.pattern){const i=typeof n.pattern=="string"?new RegExp(n.pattern):n.pattern,a=n.message||`${t.label} format is invalid`;e=e.test("pattern",a,o=>o?i.test(o):!0)}return n.custom&&(e=e.test("custom",n.message||`${t.label} is invalid`,i=>{const a=n.custom(i);return typeof a=="boolean"?a:!1})),e},ic=({currentStep:e,totalSteps:t,onStepChange:r,stepTitles:n=[],showStepTitles:i=!0,completedSteps:a=[]})=>{const o=P.useMemo(()=>Array.from({length:t},(u,d)=>d+1),[t]),s=P.useMemo(()=>Math.round(e/t*100),[e,t]),l=u=>n[u-1]||`Step ${u}`,p=u=>u===e||a.includes(u)||u===e+1&&a.includes(e);return m.jsxs(E.Card,{sx:{mb:2,p:2,boxShadow:"0px 1px 4px 0px #00000014",background:"#F8F8F8",borderRadius:"4px"},children:[m.jsxs(E.Box,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between",mb:2},children:[m.jsx(E.Box,{sx:{display:"flex",alignItems:"center",flexWrap:"wrap"},children:o.map((u,d)=>{const f=u===e,g=u<e||a.includes(u),S=f||g?"primary.main":"#8F97A4";return m.jsxs(E.Box,{sx:{display:"flex",alignItems:"center"},children:[m.jsxs(E.Box,{onClick:()=>p(u)&&r(u),sx:{display:"flex",alignItems:"center",cursor:p(u)?"pointer":"default"},children:[m.jsx(E.Box,{sx:{width:24,height:24,borderRadius:"50%",border:f||g?"2px solid":"1px solid",borderColor:f||g?"primary.main":"#8F97A4",display:"flex",alignItems:"center",justifyContent:"center",backgroundColor:c=>f||g?Ft(c.palette.primary.main,.2):"transparent",mr:.5,color:S,fontWeight:f||g?600:500,fontSize:"12px"},children:u}),i&&m.jsx(E.Typography,{sx:{fontSize:"12px",fontWeight:600,color:S},children:l(u)})]}),d<o.length-1&&m.jsx(E.Box,{sx:{width:40,height:2,mx:1,borderRadius:1,backgroundColor:u<e?"primary.main":"#DFE3E8"}})]},u)})}),m.jsx(E.Typography,{sx:{color:"#8F97A4",fontSize:"12px",fontWeight:500},children:`Step ${e} of ${t}, ${s}% complete`})]}),m.jsx(E.LinearProgress,{variant:"determinate",value:s,sx:{height:4,borderRadius:"50px",backgroundColor:u=>u.palette.grey[300],"& .MuiLinearProgress-bar":{backgroundColor:"primary.main",borderRadius:5}}})]})},ac=({buttons:e,disabled:t=!1})=>{const r=s=>{s.onClick&&s.onClick()},n=e.filter(s=>s.position==="left"||!s.position),i=e.filter(s=>s.position==="center"),a=e.filter(s=>s.position==="right"),o=(s,l)=>{const p=(s.text||"").toLowerCase(),u=s.type==="submit"||p.includes("submit")||p.includes("save")||p.includes("next"),d=s.position==="left"||p.includes("cancel")||p.includes("back")||p.includes("draft"),f=s.type?s.type:u?"submit":"button",g=d?"outlined":"contained",S=s.disabled||t,c=b=>b&&["primary","secondary","error","info","success","warning"].includes(b)?b:"primary";return m.jsxs(E.Button,{type:f,variant:g,color:c(s.color),size:s.size||"large",disabled:S,onClick:s.onClick?()=>r(s):void 0,sx:s.sx,children:[s.loading&&m.jsx(E.CircularProgress,{size:20,sx:{mr:1}}),s.text]},`${s.text}-${l}`)};return m.jsxs(E.Box,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[m.jsx(E.Box,{sx:{display:"flex",gap:2},children:n.map((s,l)=>o(s,l))}),m.jsx(E.Box,{sx:{display:"flex",gap:2},children:i.map((s,l)=>o(s,l))}),m.jsx(E.Box,{sx:{display:"flex",gap:2},children:a.map((s,l)=>o(s,l))})]})},em=({config:e,onSubmit:t,onStepChange:r,currentStep:n=1,totalSteps:i=1,isMultiStep:a=!1,formData:o})=>{const{buttons:s,position:l="right",layout:p="horizontal",spacing:u=2,sx:d}=e,f=y=>{let j="button",R="contained";return y.type?j=y.type:y.text.toLowerCase().includes("submit")||y.text.toLowerCase().includes("save")||y.text.toLowerCase().includes("next")?j="submit":(y.text.toLowerCase().includes("reset")||y.text.toLowerCase().includes("clear"))&&(j="reset"),(y.text.toLowerCase().includes("cancel")||y.text.toLowerCase().includes("back")||y.text.toLowerCase().includes("draft"))&&(R="outlined"),{buttonType:j,buttonVariant:R}},g=y=>["primary","secondary","error","warning","info","success"].includes(y||"")?y:"primary",S=y=>{const{buttonType:j}=f(y);y.onClick?y.onClick():j==="submit"&&t?t(o):a&&r&&(y.text.toLowerCase().includes("next")?r(n+1,i):(y.text.toLowerCase().includes("back")||y.text.toLowerCase().includes("previous"))&&r(n-1,i))},c=(y,j)=>{const{buttonType:R,buttonVariant:k}=f(y),v=g(y.color);return m.jsx(E.Button,{type:R,variant:k,color:v,size:y.size||"medium",disabled:y.disabled,onClick:()=>S(y),sx:y.sx,children:y.text},j)},b=()=>{const y={display:"flex",gap:u,...d};switch(l){case"left":return{...y,justifyContent:"flex-start"};case"center":return{...y,justifyContent:"center"};case"right":return{...y,justifyContent:"flex-end"};case"space-between":return{...y,justifyContent:"space-between"};default:return{...y,justifyContent:"flex-end"}}};return p==="vertical"?m.jsx(E.Box,{sx:b(),children:s.map((y,j)=>m.jsx(E.Box,{sx:{width:"100%"},children:c(y,j)},j))}):m.jsx(E.Box,{sx:b(),children:m.jsx(E.ButtonGroup,{variant:"outlined",size:"medium",children:s.map((y,j)=>c(y,j))})})},tm=new lu({defaultOptions:{queries:{staleTime:15*60*1e3,gcTime:30*60*1e3,retry:3,retryDelay:e=>Math.min(1e3*2**e,3e4),refetchOnWindowFocus:!1,refetchOnReconnect:!0}}}),rm=e=>m.jsx(fu,{client:tm,children:m.jsx(nm,{...e})}),nm=({id:e,theme:t,fields:r,onSubmit:n,onChange:i,submitButtonText:a="Submit",onSubmitClick:o,defaultValues:s,showSubmitButton:l=!0,buttons:p,buttonGroup:u,baseUrl:d,apiHeaders:f,stepNavigationProps:g})=>{var de,pe;const S=[...new Set(r.map(D=>D.step).filter(D=>D!=null&&D>0))].sort((D,_)=>(D||0)-(_||0)),c=S.length>1,b=S.length||1,[y,j]=P.useState(1),R=c?r.filter(D=>D.step===y):r,k=P.useMemo(()=>nc(R),[R]),{control:v,handleSubmit:B,formState:{errors:A},watch:H,setValue:U,resetField:h,trigger:z}=Nc({resolver:Uc(k),mode:"onChange",defaultValues:s}),M=H(),q=P.useRef({});P.useEffect(()=>{const D=[];for(const _ of r){const Q=_.depends_on;Q&&typeof _.name=="string"&&D.push({dependentField:_.name,dependencyName:Q})}if(D.length!==0)for(const{dependentField:_,dependencyName:Q}of D){const fe=q.current[Q],xe=M==null?void 0:M[Q];if(fe!==xe)try{h(_)}catch{}q.current[Q]=xe}},[r,M,h]);const N=P.useRef(i);P.useEffect(()=>{N.current=i},[i]);const J=P.useMemo(()=>{try{return JSON.stringify(M)}catch{return String(Date.now())}},[M]),ae=P.useRef(null);P.useEffect(()=>{N.current&&ae.current!==J&&(ae.current=J,N.current(M))},[J]);const he=async()=>{if(!c)return!0;const D=r.filter(Q=>Q.step===y);for(const Q of D)if(Q.required){const fe=M[Q.name];let xe=!0;if(Q.type==="checkbox"?xe=fe===!0:Array.isArray(fe)?xe=fe.length>0:xe=fe!=null&&fe!=="",!xe)return!1}return await z()?!0:Object.keys(A).filter(fe=>D.some(xe=>xe.name===fe)).map(fe=>{const xe=A[fe];return typeof(xe==null?void 0:xe.message)=="string"?xe.message:`${fe} is invalid`}).length===0},ie=P.useMemo(()=>{if(!c)return!0;const D=r.filter(Q=>Q.step===y);for(const Q of D)if(Q.required){const fe=M[Q.name];let xe=!0;if(Q.type==="checkbox"?xe=fe===!0:Array.isArray(fe)?xe=fe.length>0:xe=fe!=null&&fe!=="",!xe)return!1}return Object.keys(A).filter(Q=>D.some(fe=>fe.name===Q)).length===0},[c,y,r,M,A]),oe=P.useMemo(()=>{if(c)return ie;for(const D of r)if(D.required){const _=M[D.name];let Q=!0;if(D.type==="checkbox"?Q=_===!0:Q=_!=null&&_!==""&&!(Array.isArray(_)&&_.length===0),!Q)return!1}return Object.keys(A).length===0},[c,ie,r,M,A]),V=async D=>{D<1||D>b||D>y&&c&&!await he()||j(D)},W=async D=>{if(c&&y<b){console.warn("Form submission attempted on non-final step");return}o&&o(D),n(D)},ce=async D=>{D&&(D.preventDefault(),D.stopPropagation()),c&&y<b&&await he()&&V(y+1)},me=D=>{D&&(D.preventDefault(),D.stopPropagation()),c&&y>1&&V(y-1)},se=D=>D.col?D.col:(D.xs||D.sm||D.md||D.lg||D.xl)&&(D.xs||D.sm||D.md||D.lg||D.xl)||12,L=t?E.createTheme({palette:{primary:{main:t.primaryColor||"#1976d2"},secondary:{main:t.secondaryColor||"#dc004e"},background:{default:t.backgroundColor||"#ffffff"},text:{primary:t.textColor||"#000000"}},shape:{borderRadius:t.borderRadius||4},spacing:t.spacing||8,typography:{fontFamily:((de=t.typography)==null?void 0:de.fontFamily)||"Roboto, Arial, sans-serif",fontSize:typeof((pe=t.typography)==null?void 0:pe.fontSize)=="number"?t.typography.fontSize:14}}):void 0,X=()=>{if(u&&u.buttons&&u.buttons.length>0){const D={...u,buttons:u.buttons.map(_=>{const Q=(_.text||"").toLowerCase(),fe=_.type==="submit"||Q.includes("submit")||Q.includes("save")||Q.includes("finish")||Q.includes("complete"),xe=Q.includes("next");let Be=!1;return c?(fe||xe)&&(Be=!ie):fe&&(Be=!oe),{..._,disabled:_.disabled||Be}})};return m.jsx(E.Box,{sx:{mt:3},children:m.jsx(em,{config:D,onSubmit:W,onStepChange:V,currentStep:y,totalSteps:b,isMultiStep:c,formData:M})})}if(p&&p.length>0){const D=p.map(_=>{const Q=(_.text||"").toLowerCase(),fe=_.type==="submit"||Q.includes("submit")||Q.includes("save")||Q.includes("finish")||Q.includes("complete"),xe=Q.includes("next");let Be=!1;return c?(fe||xe)&&(Be=!ie):fe&&(Be=!oe),{..._,disabled:_.disabled||Be}});return m.jsx(ac,{buttons:D})}return l?m.jsx(E.Box,{sx:{mt:3,display:"flex",justifyContent:"flex-end",flexDirection:"column",alignItems:"flex-end"},children:m.jsxs(E.Box,{sx:{display:"flex",gap:2},children:[c&&y>1&&m.jsx(E.Button,{type:"button",variant:"outlined",onClick:me,children:"Previous"}),c?y<b?m.jsx(E.Button,{type:"button",variant:"contained",color:"primary",size:"large",disabled:!ie,onClick:ce,children:"Next"}):m.jsx(E.Button,{type:"submit",variant:"contained",color:"primary",size:"large",disabled:!ie,children:a}):m.jsx(E.Button,{type:"submit",variant:"contained",color:"primary",size:"large",disabled:!oe,children:a})]})}):null},ne=P.useMemo(()=>{const D=[];let _=[];for(const Q of R)Q.type==="section"&&_.length>0?(D.push(_),_=[Q]):_.push(Q);return _.length>0&&D.push(_),D},[R]),ue=m.jsxs(E.Box,{component:"form",onSubmit:D=>{if(c&&y<b){D.preventDefault(),D.stopPropagation(),ie&&ce();return}B(W)(D)},id:e,onKeyDown:D=>{D.key==="Enter"&&c&&y<b&&(D.preventDefault(),ie&&ce())},children:[c&&m.jsx(ic,{currentStep:y,totalSteps:b,onStepChange:V,stepTitles:g==null?void 0:g.stepTitles,showStepTitles:(g==null?void 0:g.showStepTitles)!==!1}),ne.map((D,_)=>m.jsx(E.Card,{sx:{p:2,boxShadow:"0px 1px 4px 0px #00000029",background:"#FFFFFF",borderRadius:"6px",display:"grid",gridTemplateColumns:"repeat(12, 1fr)",gap:2,width:"100%",mb:2},children:D.map(Q=>{const fe=se(Q);return m.jsx(E.Box,{sx:{gridColumn:`span ${fe}`},children:m.jsx(Nl,{field:Q,control:v,errors:A,baseUrl:d,apiHeaders:f,formData:M,setValue:U})},Q.name)})},`group-${_}`)),X()]});return L?m.jsx(E.ThemeProvider,{theme:L,children:ue}):ue},im=({src:e,alt:t,width:r="100%",height:n="auto",style:i,className:a,onClick:o})=>m.jsx(E.Box,{sx:{textAlign:"center"},children:m.jsx("img",{src:e||"/placeholder-image.png",alt:t||"Image",width:r,height:n,style:{maxWidth:"100%",height:"auto",borderRadius:"8px",cursor:o?"pointer":"default",...i},className:a,onClick:o,onError:s=>{s.currentTarget.src="/placeholder-image.png"}})});function Tr(e,t,r,n){function i(a){return a instanceof r?a:new r(function(o){o(a)})}return new(r||(r=Promise))(function(a,o){function s(u){try{p(n.next(u))}catch(d){o(d)}}function l(u){try{p(n.throw(u))}catch(d){o(d)}}function p(u){u.done?a(u.value):i(u.value).then(s,l)}p((n=n.apply(e,t||[])).next())})}const am=new Map([["1km","application/vnd.1000minds.decision-model+xml"],["3dml","text/vnd.in3d.3dml"],["3ds","image/x-3ds"],["3g2","video/3gpp2"],["3gp","video/3gp"],["3gpp","video/3gpp"],["3mf","model/3mf"],["7z","application/x-7z-compressed"],["7zip","application/x-7z-compressed"],["123","application/vnd.lotus-1-2-3"],["aab","application/x-authorware-bin"],["aac","audio/x-acc"],["aam","application/x-authorware-map"],["aas","application/x-authorware-seg"],["abw","application/x-abiword"],["ac","application/vnd.nokia.n-gage.ac+xml"],["ac3","audio/ac3"],["acc","application/vnd.americandynamics.acc"],["ace","application/x-ace-compressed"],["acu","application/vnd.acucobol"],["acutc","application/vnd.acucorp"],["adp","audio/adpcm"],["aep","application/vnd.audiograph"],["afm","application/x-font-type1"],["afp","application/vnd.ibm.modcap"],["ahead","application/vnd.ahead.space"],["ai","application/pdf"],["aif","audio/x-aiff"],["aifc","audio/x-aiff"],["aiff","audio/x-aiff"],["air","application/vnd.adobe.air-application-installer-package+zip"],["ait","application/vnd.dvb.ait"],["ami","application/vnd.amiga.ami"],["amr","audio/amr"],["apk","application/vnd.android.package-archive"],["apng","image/apng"],["appcache","text/cache-manifest"],["application","application/x-ms-application"],["apr","application/vnd.lotus-approach"],["arc","application/x-freearc"],["arj","application/x-arj"],["asc","application/pgp-signature"],["asf","video/x-ms-asf"],["asm","text/x-asm"],["aso","application/vnd.accpac.simply.aso"],["asx","video/x-ms-asf"],["atc","application/vnd.acucorp"],["atom","application/atom+xml"],["atomcat","application/atomcat+xml"],["atomdeleted","application/atomdeleted+xml"],["atomsvc","application/atomsvc+xml"],["atx","application/vnd.antix.game-component"],["au","audio/x-au"],["avi","video/x-msvideo"],["avif","image/avif"],["aw","application/applixware"],["azf","application/vnd.airzip.filesecure.azf"],["azs","application/vnd.airzip.filesecure.azs"],["azv","image/vnd.airzip.accelerator.azv"],["azw","application/vnd.amazon.ebook"],["b16","image/vnd.pco.b16"],["bat","application/x-msdownload"],["bcpio","application/x-bcpio"],["bdf","application/x-font-bdf"],["bdm","application/vnd.syncml.dm+wbxml"],["bdoc","application/x-bdoc"],["bed","application/vnd.realvnc.bed"],["bh2","application/vnd.fujitsu.oasysprs"],["bin","application/octet-stream"],["blb","application/x-blorb"],["blorb","application/x-blorb"],["bmi","application/vnd.bmi"],["bmml","application/vnd.balsamiq.bmml+xml"],["bmp","image/bmp"],["book","application/vnd.framemaker"],["box","application/vnd.previewsystems.box"],["boz","application/x-bzip2"],["bpk","application/octet-stream"],["bpmn","application/octet-stream"],["bsp","model/vnd.valve.source.compiled-map"],["btif","image/prs.btif"],["buffer","application/octet-stream"],["bz","application/x-bzip"],["bz2","application/x-bzip2"],["c","text/x-c"],["c4d","application/vnd.clonk.c4group"],["c4f","application/vnd.clonk.c4group"],["c4g","application/vnd.clonk.c4group"],["c4p","application/vnd.clonk.c4group"],["c4u","application/vnd.clonk.c4group"],["c11amc","application/vnd.cluetrust.cartomobile-config"],["c11amz","application/vnd.cluetrust.cartomobile-config-pkg"],["cab","application/vnd.ms-cab-compressed"],["caf","audio/x-caf"],["cap","application/vnd.tcpdump.pcap"],["car","application/vnd.curl.car"],["cat","application/vnd.ms-pki.seccat"],["cb7","application/x-cbr"],["cba","application/x-cbr"],["cbr","application/x-cbr"],["cbt","application/x-cbr"],["cbz","application/x-cbr"],["cc","text/x-c"],["cco","application/x-cocoa"],["cct","application/x-director"],["ccxml","application/ccxml+xml"],["cdbcmsg","application/vnd.contact.cmsg"],["cda","application/x-cdf"],["cdf","application/x-netcdf"],["cdfx","application/cdfx+xml"],["cdkey","application/vnd.mediastation.cdkey"],["cdmia","application/cdmi-capability"],["cdmic","application/cdmi-container"],["cdmid","application/cdmi-domain"],["cdmio","application/cdmi-object"],["cdmiq","application/cdmi-queue"],["cdr","application/cdr"],["cdx","chemical/x-cdx"],["cdxml","application/vnd.chemdraw+xml"],["cdy","application/vnd.cinderella"],["cer","application/pkix-cert"],["cfs","application/x-cfs-compressed"],["cgm","image/cgm"],["chat","application/x-chat"],["chm","application/vnd.ms-htmlhelp"],["chrt","application/vnd.kde.kchart"],["cif","chemical/x-cif"],["cii","application/vnd.anser-web-certificate-issue-initiation"],["cil","application/vnd.ms-artgalry"],["cjs","application/node"],["cla","application/vnd.claymore"],["class","application/octet-stream"],["clkk","application/vnd.crick.clicker.keyboard"],["clkp","application/vnd.crick.clicker.palette"],["clkt","application/vnd.crick.clicker.template"],["clkw","application/vnd.crick.clicker.wordbank"],["clkx","application/vnd.crick.clicker"],["clp","application/x-msclip"],["cmc","application/vnd.cosmocaller"],["cmdf","chemical/x-cmdf"],["cml","chemical/x-cml"],["cmp","application/vnd.yellowriver-custom-menu"],["cmx","image/x-cmx"],["cod","application/vnd.rim.cod"],["coffee","text/coffeescript"],["com","application/x-msdownload"],["conf","text/plain"],["cpio","application/x-cpio"],["cpp","text/x-c"],["cpt","application/mac-compactpro"],["crd","application/x-mscardfile"],["crl","application/pkix-crl"],["crt","application/x-x509-ca-cert"],["crx","application/x-chrome-extension"],["cryptonote","application/vnd.rig.cryptonote"],["csh","application/x-csh"],["csl","application/vnd.citationstyles.style+xml"],["csml","chemical/x-csml"],["csp","application/vnd.commonspace"],["csr","application/octet-stream"],["css","text/css"],["cst","application/x-director"],["csv","text/csv"],["cu","application/cu-seeme"],["curl","text/vnd.curl"],["cww","application/prs.cww"],["cxt","application/x-director"],["cxx","text/x-c"],["dae","model/vnd.collada+xml"],["daf","application/vnd.mobius.daf"],["dart","application/vnd.dart"],["dataless","application/vnd.fdsn.seed"],["davmount","application/davmount+xml"],["dbf","application/vnd.dbf"],["dbk","application/docbook+xml"],["dcr","application/x-director"],["dcurl","text/vnd.curl.dcurl"],["dd2","application/vnd.oma.dd2+xml"],["ddd","application/vnd.fujixerox.ddd"],["ddf","application/vnd.syncml.dmddf+xml"],["dds","image/vnd.ms-dds"],["deb","application/x-debian-package"],["def","text/plain"],["deploy","application/octet-stream"],["der","application/x-x509-ca-cert"],["dfac","application/vnd.dreamfactory"],["dgc","application/x-dgc-compressed"],["dic","text/x-c"],["dir","application/x-director"],["dis","application/vnd.mobius.dis"],["disposition-notification","message/disposition-notification"],["dist","application/octet-stream"],["distz","application/octet-stream"],["djv","image/vnd.djvu"],["djvu","image/vnd.djvu"],["dll","application/octet-stream"],["dmg","application/x-apple-diskimage"],["dmn","application/octet-stream"],["dmp","application/vnd.tcpdump.pcap"],["dms","application/octet-stream"],["dna","application/vnd.dna"],["doc","application/msword"],["docm","application/vnd.ms-word.template.macroEnabled.12"],["docx","application/vnd.openxmlformats-officedocument.wordprocessingml.document"],["dot","application/msword"],["dotm","application/vnd.ms-word.template.macroEnabled.12"],["dotx","application/vnd.openxmlformats-officedocument.wordprocessingml.template"],["dp","application/vnd.osgi.dp"],["dpg","application/vnd.dpgraph"],["dra","audio/vnd.dra"],["drle","image/dicom-rle"],["dsc","text/prs.lines.tag"],["dssc","application/dssc+der"],["dtb","application/x-dtbook+xml"],["dtd","application/xml-dtd"],["dts","audio/vnd.dts"],["dtshd","audio/vnd.dts.hd"],["dump","application/octet-stream"],["dvb","video/vnd.dvb.file"],["dvi","application/x-dvi"],["dwd","application/atsc-dwd+xml"],["dwf","model/vnd.dwf"],["dwg","image/vnd.dwg"],["dxf","image/vnd.dxf"],["dxp","application/vnd.spotfire.dxp"],["dxr","application/x-director"],["ear","application/java-archive"],["ecelp4800","audio/vnd.nuera.ecelp4800"],["ecelp7470","audio/vnd.nuera.ecelp7470"],["ecelp9600","audio/vnd.nuera.ecelp9600"],["ecma","application/ecmascript"],["edm","application/vnd.novadigm.edm"],["edx","application/vnd.novadigm.edx"],["efif","application/vnd.picsel"],["ei6","application/vnd.pg.osasli"],["elc","application/octet-stream"],["emf","image/emf"],["eml","message/rfc822"],["emma","application/emma+xml"],["emotionml","application/emotionml+xml"],["emz","application/x-msmetafile"],["eol","audio/vnd.digital-winds"],["eot","application/vnd.ms-fontobject"],["eps","application/postscript"],["epub","application/epub+zip"],["es","application/ecmascript"],["es3","application/vnd.eszigno3+xml"],["esa","application/vnd.osgi.subsystem"],["esf","application/vnd.epson.esf"],["et3","application/vnd.eszigno3+xml"],["etx","text/x-setext"],["eva","application/x-eva"],["evy","application/x-envoy"],["exe","application/octet-stream"],["exi","application/exi"],["exp","application/express"],["exr","image/aces"],["ext","application/vnd.novadigm.ext"],["ez","application/andrew-inset"],["ez2","application/vnd.ezpix-album"],["ez3","application/vnd.ezpix-package"],["f","text/x-fortran"],["f4v","video/mp4"],["f77","text/x-fortran"],["f90","text/x-fortran"],["fbs","image/vnd.fastbidsheet"],["fcdt","application/vnd.adobe.formscentral.fcdt"],["fcs","application/vnd.isac.fcs"],["fdf","application/vnd.fdf"],["fdt","application/fdt+xml"],["fe_launch","application/vnd.denovo.fcselayout-link"],["fg5","application/vnd.fujitsu.oasysgp"],["fgd","application/x-director"],["fh","image/x-freehand"],["fh4","image/x-freehand"],["fh5","image/x-freehand"],["fh7","image/x-freehand"],["fhc","image/x-freehand"],["fig","application/x-xfig"],["fits","image/fits"],["flac","audio/x-flac"],["fli","video/x-fli"],["flo","application/vnd.micrografx.flo"],["flv","video/x-flv"],["flw","application/vnd.kde.kivio"],["flx","text/vnd.fmi.flexstor"],["fly","text/vnd.fly"],["fm","application/vnd.framemaker"],["fnc","application/vnd.frogans.fnc"],["fo","application/vnd.software602.filler.form+xml"],["for","text/x-fortran"],["fpx","image/vnd.fpx"],["frame","application/vnd.framemaker"],["fsc","application/vnd.fsc.weblaunch"],["fst","image/vnd.fst"],["ftc","application/vnd.fluxtime.clip"],["fti","application/vnd.anser-web-funds-transfer-initiation"],["fvt","video/vnd.fvt"],["fxp","application/vnd.adobe.fxp"],["fxpl","application/vnd.adobe.fxp"],["fzs","application/vnd.fuzzysheet"],["g2w","application/vnd.geoplan"],["g3","image/g3fax"],["g3w","application/vnd.geospace"],["gac","application/vnd.groove-account"],["gam","application/x-tads"],["gbr","application/rpki-ghostbusters"],["gca","application/x-gca-compressed"],["gdl","model/vnd.gdl"],["gdoc","application/vnd.google-apps.document"],["geo","application/vnd.dynageo"],["geojson","application/geo+json"],["gex","application/vnd.geometry-explorer"],["ggb","application/vnd.geogebra.file"],["ggt","application/vnd.geogebra.tool"],["ghf","application/vnd.groove-help"],["gif","image/gif"],["gim","application/vnd.groove-identity-message"],["glb","model/gltf-binary"],["gltf","model/gltf+json"],["gml","application/gml+xml"],["gmx","application/vnd.gmx"],["gnumeric","application/x-gnumeric"],["gpg","application/gpg-keys"],["gph","application/vnd.flographit"],["gpx","application/gpx+xml"],["gqf","application/vnd.grafeq"],["gqs","application/vnd.grafeq"],["gram","application/srgs"],["gramps","application/x-gramps-xml"],["gre","application/vnd.geometry-explorer"],["grv","application/vnd.groove-injector"],["grxml","application/srgs+xml"],["gsf","application/x-font-ghostscript"],["gsheet","application/vnd.google-apps.spreadsheet"],["gslides","application/vnd.google-apps.presentation"],["gtar","application/x-gtar"],["gtm","application/vnd.groove-tool-message"],["gtw","model/vnd.gtw"],["gv","text/vnd.graphviz"],["gxf","application/gxf"],["gxt","application/vnd.geonext"],["gz","application/gzip"],["gzip","application/gzip"],["h","text/x-c"],["h261","video/h261"],["h263","video/h263"],["h264","video/h264"],["hal","application/vnd.hal+xml"],["hbci","application/vnd.hbci"],["hbs","text/x-handlebars-template"],["hdd","application/x-virtualbox-hdd"],["hdf","application/x-hdf"],["heic","image/heic"],["heics","image/heic-sequence"],["heif","image/heif"],["heifs","image/heif-sequence"],["hej2","image/hej2k"],["held","application/atsc-held+xml"],["hh","text/x-c"],["hjson","application/hjson"],["hlp","application/winhlp"],["hpgl","application/vnd.hp-hpgl"],["hpid","application/vnd.hp-hpid"],["hps","application/vnd.hp-hps"],["hqx","application/mac-binhex40"],["hsj2","image/hsj2"],["htc","text/x-component"],["htke","application/vnd.kenameaapp"],["htm","text/html"],["html","text/html"],["hvd","application/vnd.yamaha.hv-dic"],["hvp","application/vnd.yamaha.hv-voice"],["hvs","application/vnd.yamaha.hv-script"],["i2g","application/vnd.intergeo"],["icc","application/vnd.iccprofile"],["ice","x-conference/x-cooltalk"],["icm","application/vnd.iccprofile"],["ico","image/x-icon"],["ics","text/calendar"],["ief","image/ief"],["ifb","text/calendar"],["ifm","application/vnd.shana.informed.formdata"],["iges","model/iges"],["igl","application/vnd.igloader"],["igm","application/vnd.insors.igm"],["igs","model/iges"],["igx","application/vnd.micrografx.igx"],["iif","application/vnd.shana.informed.interchange"],["img","application/octet-stream"],["imp","application/vnd.accpac.simply.imp"],["ims","application/vnd.ms-ims"],["in","text/plain"],["ini","text/plain"],["ink","application/inkml+xml"],["inkml","application/inkml+xml"],["install","application/x-install-instructions"],["iota","application/vnd.astraea-software.iota"],["ipfix","application/ipfix"],["ipk","application/vnd.shana.informed.package"],["irm","application/vnd.ibm.rights-management"],["irp","application/vnd.irepository.package+xml"],["iso","application/x-iso9660-image"],["itp","application/vnd.shana.informed.formtemplate"],["its","application/its+xml"],["ivp","application/vnd.immervision-ivp"],["ivu","application/vnd.immervision-ivu"],["jad","text/vnd.sun.j2me.app-descriptor"],["jade","text/jade"],["jam","application/vnd.jam"],["jar","application/java-archive"],["jardiff","application/x-java-archive-diff"],["java","text/x-java-source"],["jhc","image/jphc"],["jisp","application/vnd.jisp"],["jls","image/jls"],["jlt","application/vnd.hp-jlyt"],["jng","image/x-jng"],["jnlp","application/x-java-jnlp-file"],["joda","application/vnd.joost.joda-archive"],["jp2","image/jp2"],["jpe","image/jpeg"],["jpeg","image/jpeg"],["jpf","image/jpx"],["jpg","image/jpeg"],["jpg2","image/jp2"],["jpgm","video/jpm"],["jpgv","video/jpeg"],["jph","image/jph"],["jpm","video/jpm"],["jpx","image/jpx"],["js","application/javascript"],["json","application/json"],["json5","application/json5"],["jsonld","application/ld+json"],["jsonl","application/jsonl"],["jsonml","application/jsonml+json"],["jsx","text/jsx"],["jxr","image/jxr"],["jxra","image/jxra"],["jxrs","image/jxrs"],["jxs","image/jxs"],["jxsc","image/jxsc"],["jxsi","image/jxsi"],["jxss","image/jxss"],["kar","audio/midi"],["karbon","application/vnd.kde.karbon"],["kdb","application/octet-stream"],["kdbx","application/x-keepass2"],["key","application/x-iwork-keynote-sffkey"],["kfo","application/vnd.kde.kformula"],["kia","application/vnd.kidspiration"],["kml","application/vnd.google-earth.kml+xml"],["kmz","application/vnd.google-earth.kmz"],["kne","application/vnd.kinar"],["knp","application/vnd.kinar"],["kon","application/vnd.kde.kontour"],["kpr","application/vnd.kde.kpresenter"],["kpt","application/vnd.kde.kpresenter"],["kpxx","application/vnd.ds-keypoint"],["ksp","application/vnd.kde.kspread"],["ktr","application/vnd.kahootz"],["ktx","image/ktx"],["ktx2","image/ktx2"],["ktz","application/vnd.kahootz"],["kwd","application/vnd.kde.kword"],["kwt","application/vnd.kde.kword"],["lasxml","application/vnd.las.las+xml"],["latex","application/x-latex"],["lbd","application/vnd.llamagraphics.life-balance.desktop"],["lbe","application/vnd.llamagraphics.life-balance.exchange+xml"],["les","application/vnd.hhe.lesson-player"],["less","text/less"],["lgr","application/lgr+xml"],["lha","application/octet-stream"],["link66","application/vnd.route66.link66+xml"],["list","text/plain"],["list3820","application/vnd.ibm.modcap"],["listafp","application/vnd.ibm.modcap"],["litcoffee","text/coffeescript"],["lnk","application/x-ms-shortcut"],["log","text/plain"],["lostxml","application/lost+xml"],["lrf","application/octet-stream"],["lrm","application/vnd.ms-lrm"],["ltf","application/vnd.frogans.ltf"],["lua","text/x-lua"],["luac","application/x-lua-bytecode"],["lvp","audio/vnd.lucent.voice"],["lwp","application/vnd.lotus-wordpro"],["lzh","application/octet-stream"],["m1v","video/mpeg"],["m2a","audio/mpeg"],["m2v","video/mpeg"],["m3a","audio/mpeg"],["m3u","text/plain"],["m3u8","application/vnd.apple.mpegurl"],["m4a","audio/x-m4a"],["m4p","application/mp4"],["m4s","video/iso.segment"],["m4u","application/vnd.mpegurl"],["m4v","video/x-m4v"],["m13","application/x-msmediaview"],["m14","application/x-msmediaview"],["m21","application/mp21"],["ma","application/mathematica"],["mads","application/mads+xml"],["maei","application/mmt-aei+xml"],["mag","application/vnd.ecowin.chart"],["maker","application/vnd.framemaker"],["man","text/troff"],["manifest","text/cache-manifest"],["map","application/json"],["mar","application/octet-stream"],["markdown","text/markdown"],["mathml","application/mathml+xml"],["mb","application/mathematica"],["mbk","application/vnd.mobius.mbk"],["mbox","application/mbox"],["mc1","application/vnd.medcalcdata"],["mcd","application/vnd.mcd"],["mcurl","text/vnd.curl.mcurl"],["md","text/markdown"],["mdb","application/x-msaccess"],["mdi","image/vnd.ms-modi"],["mdx","text/mdx"],["me","text/troff"],["mesh","model/mesh"],["meta4","application/metalink4+xml"],["metalink","application/metalink+xml"],["mets","application/mets+xml"],["mfm","application/vnd.mfmp"],["mft","application/rpki-manifest"],["mgp","application/vnd.osgeo.mapguide.package"],["mgz","application/vnd.proteus.magazine"],["mid","audio/midi"],["midi","audio/midi"],["mie","application/x-mie"],["mif","application/vnd.mif"],["mime","message/rfc822"],["mj2","video/mj2"],["mjp2","video/mj2"],["mjs","application/javascript"],["mk3d","video/x-matroska"],["mka","audio/x-matroska"],["mkd","text/x-markdown"],["mks","video/x-matroska"],["mkv","video/x-matroska"],["mlp","application/vnd.dolby.mlp"],["mmd","application/vnd.chipnuts.karaoke-mmd"],["mmf","application/vnd.smaf"],["mml","text/mathml"],["mmr","image/vnd.fujixerox.edmics-mmr"],["mng","video/x-mng"],["mny","application/x-msmoney"],["mobi","application/x-mobipocket-ebook"],["mods","application/mods+xml"],["mov","video/quicktime"],["movie","video/x-sgi-movie"],["mp2","audio/mpeg"],["mp2a","audio/mpeg"],["mp3","audio/mpeg"],["mp4","video/mp4"],["mp4a","audio/mp4"],["mp4s","application/mp4"],["mp4v","video/mp4"],["mp21","application/mp21"],["mpc","application/vnd.mophun.certificate"],["mpd","application/dash+xml"],["mpe","video/mpeg"],["mpeg","video/mpeg"],["mpg","video/mpeg"],["mpg4","video/mp4"],["mpga","audio/mpeg"],["mpkg","application/vnd.apple.installer+xml"],["mpm","application/vnd.blueice.multipass"],["mpn","application/vnd.mophun.application"],["mpp","application/vnd.ms-project"],["mpt","application/vnd.ms-project"],["mpy","application/vnd.ibm.minipay"],["mqy","application/vnd.mobius.mqy"],["mrc","application/marc"],["mrcx","application/marcxml+xml"],["ms","text/troff"],["mscml","application/mediaservercontrol+xml"],["mseed","application/vnd.fdsn.mseed"],["mseq","application/vnd.mseq"],["msf","application/vnd.epson.msf"],["msg","application/vnd.ms-outlook"],["msh","model/mesh"],["msi","application/x-msdownload"],["msl","application/vnd.mobius.msl"],["msm","application/octet-stream"],["msp","application/octet-stream"],["msty","application/vnd.muvee.style"],["mtl","model/mtl"],["mts","model/vnd.mts"],["mus","application/vnd.musician"],["musd","application/mmt-usd+xml"],["musicxml","application/vnd.recordare.musicxml+xml"],["mvb","application/x-msmediaview"],["mvt","application/vnd.mapbox-vector-tile"],["mwf","application/vnd.mfer"],["mxf","application/mxf"],["mxl","application/vnd.recordare.musicxml"],["mxmf","audio/mobile-xmf"],["mxml","application/xv+xml"],["mxs","application/vnd.triscape.mxs"],["mxu","video/vnd.mpegurl"],["n-gage","application/vnd.nokia.n-gage.symbian.install"],["n3","text/n3"],["nb","application/mathematica"],["nbp","application/vnd.wolfram.player"],["nc","application/x-netcdf"],["ncx","application/x-dtbncx+xml"],["nfo","text/x-nfo"],["ngdat","application/vnd.nokia.n-gage.data"],["nitf","application/vnd.nitf"],["nlu","application/vnd.neurolanguage.nlu"],["nml","application/vnd.enliven"],["nnd","application/vnd.noblenet-directory"],["nns","application/vnd.noblenet-sealer"],["nnw","application/vnd.noblenet-web"],["npx","image/vnd.net-fpx"],["nq","application/n-quads"],["nsc","application/x-conference"],["nsf","application/vnd.lotus-notes"],["nt","application/n-triples"],["ntf","application/vnd.nitf"],["numbers","application/x-iwork-numbers-sffnumbers"],["nzb","application/x-nzb"],["oa2","application/vnd.fujitsu.oasys2"],["oa3","application/vnd.fujitsu.oasys3"],["oas","application/vnd.fujitsu.oasys"],["obd","application/x-msbinder"],["obgx","application/vnd.openblox.game+xml"],["obj","model/obj"],["oda","application/oda"],["odb","application/vnd.oasis.opendocument.database"],["odc","application/vnd.oasis.opendocument.chart"],["odf","application/vnd.oasis.opendocument.formula"],["odft","application/vnd.oasis.opendocument.formula-template"],["odg","application/vnd.oasis.opendocument.graphics"],["odi","application/vnd.oasis.opendocument.image"],["odm","application/vnd.oasis.opendocument.text-master"],["odp","application/vnd.oasis.opendocument.presentation"],["ods","application/vnd.oasis.opendocument.spreadsheet"],["odt","application/vnd.oasis.opendocument.text"],["oga","audio/ogg"],["ogex","model/vnd.opengex"],["ogg","audio/ogg"],["ogv","video/ogg"],["ogx","application/ogg"],["omdoc","application/omdoc+xml"],["onepkg","application/onenote"],["onetmp","application/onenote"],["onetoc","application/onenote"],["onetoc2","application/onenote"],["opf","application/oebps-package+xml"],["opml","text/x-opml"],["oprc","application/vnd.palm"],["opus","audio/ogg"],["org","text/x-org"],["osf","application/vnd.yamaha.openscoreformat"],["osfpvg","application/vnd.yamaha.openscoreformat.osfpvg+xml"],["osm","application/vnd.openstreetmap.data+xml"],["otc","application/vnd.oasis.opendocument.chart-template"],["otf","font/otf"],["otg","application/vnd.oasis.opendocument.graphics-template"],["oth","application/vnd.oasis.opendocument.text-web"],["oti","application/vnd.oasis.opendocument.image-template"],["otp","application/vnd.oasis.opendocument.presentation-template"],["ots","application/vnd.oasis.opendocument.spreadsheet-template"],["ott","application/vnd.oasis.opendocument.text-template"],["ova","application/x-virtualbox-ova"],["ovf","application/x-virtualbox-ovf"],["owl","application/rdf+xml"],["oxps","application/oxps"],["oxt","application/vnd.openofficeorg.extension"],["p","text/x-pascal"],["p7a","application/x-pkcs7-signature"],["p7b","application/x-pkcs7-certificates"],["p7c","application/pkcs7-mime"],["p7m","application/pkcs7-mime"],["p7r","application/x-pkcs7-certreqresp"],["p7s","application/pkcs7-signature"],["p8","application/pkcs8"],["p10","application/x-pkcs10"],["p12","application/x-pkcs12"],["pac","application/x-ns-proxy-autoconfig"],["pages","application/x-iwork-pages-sffpages"],["pas","text/x-pascal"],["paw","application/vnd.pawaafile"],["pbd","application/vnd.powerbuilder6"],["pbm","image/x-portable-bitmap"],["pcap","application/vnd.tcpdump.pcap"],["pcf","application/x-font-pcf"],["pcl","application/vnd.hp-pcl"],["pclxl","application/vnd.hp-pclxl"],["pct","image/x-pict"],["pcurl","application/vnd.curl.pcurl"],["pcx","image/x-pcx"],["pdb","application/x-pilot"],["pde","text/x-processing"],["pdf","application/pdf"],["pem","application/x-x509-user-cert"],["pfa","application/x-font-type1"],["pfb","application/x-font-type1"],["pfm","application/x-font-type1"],["pfr","application/font-tdpfr"],["pfx","application/x-pkcs12"],["pgm","image/x-portable-graymap"],["pgn","application/x-chess-pgn"],["pgp","application/pgp"],["php","application/x-httpd-php"],["php3","application/x-httpd-php"],["php4","application/x-httpd-php"],["phps","application/x-httpd-php-source"],["phtml","application/x-httpd-php"],["pic","image/x-pict"],["pkg","application/octet-stream"],["pki","application/pkixcmp"],["pkipath","application/pkix-pkipath"],["pkpass","application/vnd.apple.pkpass"],["pl","application/x-perl"],["plb","application/vnd.3gpp.pic-bw-large"],["plc","application/vnd.mobius.plc"],["plf","application/vnd.pocketlearn"],["pls","application/pls+xml"],["pm","application/x-perl"],["pml","application/vnd.ctc-posml"],["png","image/png"],["pnm","image/x-portable-anymap"],["portpkg","application/vnd.macports.portpkg"],["pot","application/vnd.ms-powerpoint"],["potm","application/vnd.ms-powerpoint.presentation.macroEnabled.12"],["potx","application/vnd.openxmlformats-officedocument.presentationml.template"],["ppa","application/vnd.ms-powerpoint"],["ppam","application/vnd.ms-powerpoint.addin.macroEnabled.12"],["ppd","application/vnd.cups-ppd"],["ppm","image/x-portable-pixmap"],["pps","application/vnd.ms-powerpoint"],["ppsm","application/vnd.ms-powerpoint.slideshow.macroEnabled.12"],["ppsx","application/vnd.openxmlformats-officedocument.presentationml.slideshow"],["ppt","application/powerpoint"],["pptm","application/vnd.ms-powerpoint.presentation.macroEnabled.12"],["pptx","application/vnd.openxmlformats-officedocument.presentationml.presentation"],["pqa","application/vnd.palm"],["prc","application/x-pilot"],["pre","application/vnd.lotus-freelance"],["prf","application/pics-rules"],["provx","application/provenance+xml"],["ps","application/postscript"],["psb","application/vnd.3gpp.pic-bw-small"],["psd","application/x-photoshop"],["psf","application/x-font-linux-psf"],["pskcxml","application/pskc+xml"],["pti","image/prs.pti"],["ptid","application/vnd.pvi.ptid1"],["pub","application/x-mspublisher"],["pvb","application/vnd.3gpp.pic-bw-var"],["pwn","application/vnd.3m.post-it-notes"],["pya","audio/vnd.ms-playready.media.pya"],["pyv","video/vnd.ms-playready.media.pyv"],["qam","application/vnd.epson.quickanime"],["qbo","application/vnd.intu.qbo"],["qfx","application/vnd.intu.qfx"],["qps","application/vnd.publishare-delta-tree"],["qt","video/quicktime"],["qwd","application/vnd.quark.quarkxpress"],["qwt","application/vnd.quark.quarkxpress"],["qxb","application/vnd.quark.quarkxpress"],["qxd","application/vnd.quark.quarkxpress"],["qxl","application/vnd.quark.quarkxpress"],["qxt","application/vnd.quark.quarkxpress"],["ra","audio/x-realaudio"],["ram","audio/x-pn-realaudio"],["raml","application/raml+yaml"],["rapd","application/route-apd+xml"],["rar","application/x-rar"],["ras","image/x-cmu-raster"],["rcprofile","application/vnd.ipunplugged.rcprofile"],["rdf","application/rdf+xml"],["rdz","application/vnd.data-vision.rdz"],["relo","application/p2p-overlay+xml"],["rep","application/vnd.businessobjects"],["res","application/x-dtbresource+xml"],["rgb","image/x-rgb"],["rif","application/reginfo+xml"],["rip","audio/vnd.rip"],["ris","application/x-research-info-systems"],["rl","application/resource-lists+xml"],["rlc","image/vnd.fujixerox.edmics-rlc"],["rld","application/resource-lists-diff+xml"],["rm","audio/x-pn-realaudio"],["rmi","audio/midi"],["rmp","audio/x-pn-realaudio-plugin"],["rms","application/vnd.jcp.javame.midlet-rms"],["rmvb","application/vnd.rn-realmedia-vbr"],["rnc","application/relax-ng-compact-syntax"],["rng","application/xml"],["roa","application/rpki-roa"],["roff","text/troff"],["rp9","application/vnd.cloanto.rp9"],["rpm","audio/x-pn-realaudio-plugin"],["rpss","application/vnd.nokia.radio-presets"],["rpst","application/vnd.nokia.radio-preset"],["rq","application/sparql-query"],["rs","application/rls-services+xml"],["rsa","application/x-pkcs7"],["rsat","application/atsc-rsat+xml"],["rsd","application/rsd+xml"],["rsheet","application/urc-ressheet+xml"],["rss","application/rss+xml"],["rtf","text/rtf"],["rtx","text/richtext"],["run","application/x-makeself"],["rusd","application/route-usd+xml"],["rv","video/vnd.rn-realvideo"],["s","text/x-asm"],["s3m","audio/s3m"],["saf","application/vnd.yamaha.smaf-audio"],["sass","text/x-sass"],["sbml","application/sbml+xml"],["sc","application/vnd.ibm.secure-container"],["scd","application/x-msschedule"],["scm","application/vnd.lotus-screencam"],["scq","application/scvp-cv-request"],["scs","application/scvp-cv-response"],["scss","text/x-scss"],["scurl","text/vnd.curl.scurl"],["sda","application/vnd.stardivision.draw"],["sdc","application/vnd.stardivision.calc"],["sdd","application/vnd.stardivision.impress"],["sdkd","application/vnd.solent.sdkm+xml"],["sdkm","application/vnd.solent.sdkm+xml"],["sdp","application/sdp"],["sdw","application/vnd.stardivision.writer"],["sea","application/octet-stream"],["see","application/vnd.seemail"],["seed","application/vnd.fdsn.seed"],["sema","application/vnd.sema"],["semd","application/vnd.semd"],["semf","application/vnd.semf"],["senmlx","application/senml+xml"],["sensmlx","application/sensml+xml"],["ser","application/java-serialized-object"],["setpay","application/set-payment-initiation"],["setreg","application/set-registration-initiation"],["sfd-hdstx","application/vnd.hydrostatix.sof-data"],["sfs","application/vnd.spotfire.sfs"],["sfv","text/x-sfv"],["sgi","image/sgi"],["sgl","application/vnd.stardivision.writer-global"],["sgm","text/sgml"],["sgml","text/sgml"],["sh","application/x-sh"],["shar","application/x-shar"],["shex","text/shex"],["shf","application/shf+xml"],["shtml","text/html"],["sid","image/x-mrsid-image"],["sieve","application/sieve"],["sig","application/pgp-signature"],["sil","audio/silk"],["silo","model/mesh"],["sis","application/vnd.symbian.install"],["sisx","application/vnd.symbian.install"],["sit","application/x-stuffit"],["sitx","application/x-stuffitx"],["siv","application/sieve"],["skd","application/vnd.koan"],["skm","application/vnd.koan"],["skp","application/vnd.koan"],["skt","application/vnd.koan"],["sldm","application/vnd.ms-powerpoint.slide.macroenabled.12"],["sldx","application/vnd.openxmlformats-officedocument.presentationml.slide"],["slim","text/slim"],["slm","text/slim"],["sls","application/route-s-tsid+xml"],["slt","application/vnd.epson.salt"],["sm","application/vnd.stepmania.stepchart"],["smf","application/vnd.stardivision.math"],["smi","application/smil"],["smil","application/smil"],["smv","video/x-smv"],["smzip","application/vnd.stepmania.package"],["snd","audio/basic"],["snf","application/x-font-snf"],["so","application/octet-stream"],["spc","application/x-pkcs7-certificates"],["spdx","text/spdx"],["spf","application/vnd.yamaha.smaf-phrase"],["spl","application/x-futuresplash"],["spot","text/vnd.in3d.spot"],["spp","application/scvp-vp-response"],["spq","application/scvp-vp-request"],["spx","audio/ogg"],["sql","application/x-sql"],["src","application/x-wais-source"],["srt","application/x-subrip"],["sru","application/sru+xml"],["srx","application/sparql-results+xml"],["ssdl","application/ssdl+xml"],["sse","application/vnd.kodak-descriptor"],["ssf","application/vnd.epson.ssf"],["ssml","application/ssml+xml"],["sst","application/octet-stream"],["st","application/vnd.sailingtracker.track"],["stc","application/vnd.sun.xml.calc.template"],["std","application/vnd.sun.xml.draw.template"],["stf","application/vnd.wt.stf"],["sti","application/vnd.sun.xml.impress.template"],["stk","application/hyperstudio"],["stl","model/stl"],["stpx","model/step+xml"],["stpxz","model/step-xml+zip"],["stpz","model/step+zip"],["str","application/vnd.pg.format"],["stw","application/vnd.sun.xml.writer.template"],["styl","text/stylus"],["stylus","text/stylus"],["sub","text/vnd.dvb.subtitle"],["sus","application/vnd.sus-calendar"],["susp","application/vnd.sus-calendar"],["sv4cpio","application/x-sv4cpio"],["sv4crc","application/x-sv4crc"],["svc","application/vnd.dvb.service"],["svd","application/vnd.svd"],["svg","image/svg+xml"],["svgz","image/svg+xml"],["swa","application/x-director"],["swf","application/x-shockwave-flash"],["swi","application/vnd.aristanetworks.swi"],["swidtag","application/swid+xml"],["sxc","application/vnd.sun.xml.calc"],["sxd","application/vnd.sun.xml.draw"],["sxg","application/vnd.sun.xml.writer.global"],["sxi","application/vnd.sun.xml.impress"],["sxm","application/vnd.sun.xml.math"],["sxw","application/vnd.sun.xml.writer"],["t","text/troff"],["t3","application/x-t3vm-image"],["t38","image/t38"],["taglet","application/vnd.mynfc"],["tao","application/vnd.tao.intent-module-archive"],["tap","image/vnd.tencent.tap"],["tar","application/x-tar"],["tcap","application/vnd.3gpp2.tcap"],["tcl","application/x-tcl"],["td","application/urc-targetdesc+xml"],["teacher","application/vnd.smart.teacher"],["tei","application/tei+xml"],["teicorpus","application/tei+xml"],["tex","application/x-tex"],["texi","application/x-texinfo"],["texinfo","application/x-texinfo"],["text","text/plain"],["tfi","application/thraud+xml"],["tfm","application/x-tex-tfm"],["tfx","image/tiff-fx"],["tga","image/x-tga"],["tgz","application/x-tar"],["thmx","application/vnd.ms-officetheme"],["tif","image/tiff"],["tiff","image/tiff"],["tk","application/x-tcl"],["tmo","application/vnd.tmobile-livetv"],["toml","application/toml"],["torrent","application/x-bittorrent"],["tpl","application/vnd.groove-tool-template"],["tpt","application/vnd.trid.tpt"],["tr","text/troff"],["tra","application/vnd.trueapp"],["trig","application/trig"],["trm","application/x-msterminal"],["ts","video/mp2t"],["tsd","application/timestamped-data"],["tsv","text/tab-separated-values"],["ttc","font/collection"],["ttf","font/ttf"],["ttl","text/turtle"],["ttml","application/ttml+xml"],["twd","application/vnd.simtech-mindmapper"],["twds","application/vnd.simtech-mindmapper"],["txd","application/vnd.genomatix.tuxedo"],["txf","application/vnd.mobius.txf"],["txt","text/plain"],["u8dsn","message/global-delivery-status"],["u8hdr","message/global-headers"],["u8mdn","message/global-disposition-notification"],["u8msg","message/global"],["u32","application/x-authorware-bin"],["ubj","application/ubjson"],["udeb","application/x-debian-package"],["ufd","application/vnd.ufdl"],["ufdl","application/vnd.ufdl"],["ulx","application/x-glulx"],["umj","application/vnd.umajin"],["unityweb","application/vnd.unity"],["uoml","application/vnd.uoml+xml"],["uri","text/uri-list"],["uris","text/uri-list"],["urls","text/uri-list"],["usdz","model/vnd.usdz+zip"],["ustar","application/x-ustar"],["utz","application/vnd.uiq.theme"],["uu","text/x-uuencode"],["uva","audio/vnd.dece.audio"],["uvd","application/vnd.dece.data"],["uvf","application/vnd.dece.data"],["uvg","image/vnd.dece.graphic"],["uvh","video/vnd.dece.hd"],["uvi","image/vnd.dece.graphic"],["uvm","video/vnd.dece.mobile"],["uvp","video/vnd.dece.pd"],["uvs","video/vnd.dece.sd"],["uvt","application/vnd.dece.ttml+xml"],["uvu","video/vnd.uvvu.mp4"],["uvv","video/vnd.dece.video"],["uvva","audio/vnd.dece.audio"],["uvvd","application/vnd.dece.data"],["uvvf","application/vnd.dece.data"],["uvvg","image/vnd.dece.graphic"],["uvvh","video/vnd.dece.hd"],["uvvi","image/vnd.dece.graphic"],["uvvm","video/vnd.dece.mobile"],["uvvp","video/vnd.dece.pd"],["uvvs","video/vnd.dece.sd"],["uvvt","application/vnd.dece.ttml+xml"],["uvvu","video/vnd.uvvu.mp4"],["uvvv","video/vnd.dece.video"],["uvvx","application/vnd.dece.unspecified"],["uvvz","application/vnd.dece.zip"],["uvx","application/vnd.dece.unspecified"],["uvz","application/vnd.dece.zip"],["vbox","application/x-virtualbox-vbox"],["vbox-extpack","application/x-virtualbox-vbox-extpack"],["vcard","text/vcard"],["vcd","application/x-cdlink"],["vcf","text/x-vcard"],["vcg","application/vnd.groove-vcard"],["vcs","text/x-vcalendar"],["vcx","application/vnd.vcx"],["vdi","application/x-virtualbox-vdi"],["vds","model/vnd.sap.vds"],["vhd","application/x-virtualbox-vhd"],["vis","application/vnd.visionary"],["viv","video/vnd.vivo"],["vlc","application/videolan"],["vmdk","application/x-virtualbox-vmdk"],["vob","video/x-ms-vob"],["vor","application/vnd.stardivision.writer"],["vox","application/x-authorware-bin"],["vrml","model/vrml"],["vsd","application/vnd.visio"],["vsf","application/vnd.vsf"],["vss","application/vnd.visio"],["vst","application/vnd.visio"],["vsw","application/vnd.visio"],["vtf","image/vnd.valve.source.texture"],["vtt","text/vtt"],["vtu","model/vnd.vtu"],["vxml","application/voicexml+xml"],["w3d","application/x-director"],["wad","application/x-doom"],["wadl","application/vnd.sun.wadl+xml"],["war","application/java-archive"],["wasm","application/wasm"],["wav","audio/x-wav"],["wax","audio/x-ms-wax"],["wbmp","image/vnd.wap.wbmp"],["wbs","application/vnd.criticaltools.wbs+xml"],["wbxml","application/wbxml"],["wcm","application/vnd.ms-works"],["wdb","application/vnd.ms-works"],["wdp","image/vnd.ms-photo"],["weba","audio/webm"],["webapp","application/x-web-app-manifest+json"],["webm","video/webm"],["webmanifest","application/manifest+json"],["webp","image/webp"],["wg","application/vnd.pmi.widget"],["wgt","application/widget"],["wks","application/vnd.ms-works"],["wm","video/x-ms-wm"],["wma","audio/x-ms-wma"],["wmd","application/x-ms-wmd"],["wmf","image/wmf"],["wml","text/vnd.wap.wml"],["wmlc","application/wmlc"],["wmls","text/vnd.wap.wmlscript"],["wmlsc","application/vnd.wap.wmlscriptc"],["wmv","video/x-ms-wmv"],["wmx","video/x-ms-wmx"],["wmz","application/x-msmetafile"],["woff","font/woff"],["woff2","font/woff2"],["word","application/msword"],["wpd","application/vnd.wordperfect"],["wpl","application/vnd.ms-wpl"],["wps","application/vnd.ms-works"],["wqd","application/vnd.wqd"],["wri","application/x-mswrite"],["wrl","model/vrml"],["wsc","message/vnd.wfa.wsc"],["wsdl","application/wsdl+xml"],["wspolicy","application/wspolicy+xml"],["wtb","application/vnd.webturbo"],["wvx","video/x-ms-wvx"],["x3d","model/x3d+xml"],["x3db","model/x3d+fastinfoset"],["x3dbz","model/x3d+binary"],["x3dv","model/x3d-vrml"],["x3dvz","model/x3d+vrml"],["x3dz","model/x3d+xml"],["x32","application/x-authorware-bin"],["x_b","model/vnd.parasolid.transmit.binary"],["x_t","model/vnd.parasolid.transmit.text"],["xaml","application/xaml+xml"],["xap","application/x-silverlight-app"],["xar","application/vnd.xara"],["xav","application/xcap-att+xml"],["xbap","application/x-ms-xbap"],["xbd","application/vnd.fujixerox.docuworks.binder"],["xbm","image/x-xbitmap"],["xca","application/xcap-caps+xml"],["xcs","application/calendar+xml"],["xdf","application/xcap-diff+xml"],["xdm","application/vnd.syncml.dm+xml"],["xdp","application/vnd.adobe.xdp+xml"],["xdssc","application/dssc+xml"],["xdw","application/vnd.fujixerox.docuworks"],["xel","application/xcap-el+xml"],["xenc","application/xenc+xml"],["xer","application/patch-ops-error+xml"],["xfdf","application/vnd.adobe.xfdf"],["xfdl","application/vnd.xfdl"],["xht","application/xhtml+xml"],["xhtml","application/xhtml+xml"],["xhvml","application/xv+xml"],["xif","image/vnd.xiff"],["xl","application/excel"],["xla","application/vnd.ms-excel"],["xlam","application/vnd.ms-excel.addin.macroEnabled.12"],["xlc","application/vnd.ms-excel"],["xlf","application/xliff+xml"],["xlm","application/vnd.ms-excel"],["xls","application/vnd.ms-excel"],["xlsb","application/vnd.ms-excel.sheet.binary.macroEnabled.12"],["xlsm","application/vnd.ms-excel.sheet.macroEnabled.12"],["xlsx","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"],["xlt","application/vnd.ms-excel"],["xltm","application/vnd.ms-excel.template.macroEnabled.12"],["xltx","application/vnd.openxmlformats-officedocument.spreadsheetml.template"],["xlw","application/vnd.ms-excel"],["xm","audio/xm"],["xml","application/xml"],["xns","application/xcap-ns+xml"],["xo","application/vnd.olpc-sugar"],["xop","application/xop+xml"],["xpi","application/x-xpinstall"],["xpl","application/xproc+xml"],["xpm","image/x-xpixmap"],["xpr","application/vnd.is-xpr"],["xps","application/vnd.ms-xpsdocument"],["xpw","application/vnd.intercon.formnet"],["xpx","application/vnd.intercon.formnet"],["xsd","application/xml"],["xsl","application/xml"],["xslt","application/xslt+xml"],["xsm","application/vnd.syncml+xml"],["xspf","application/xspf+xml"],["xul","application/vnd.mozilla.xul+xml"],["xvm","application/xv+xml"],["xvml","application/xv+xml"],["xwd","image/x-xwindowdump"],["xyz","chemical/x-xyz"],["xz","application/x-xz"],["yaml","text/yaml"],["yang","application/yang"],["yin","application/yin+xml"],["yml","text/yaml"],["ymp","text/x-suse-ymp"],["z","application/x-compress"],["z1","application/x-zmachine"],["z2","application/x-zmachine"],["z3","application/x-zmachine"],["z4","application/x-zmachine"],["z5","application/x-zmachine"],["z6","application/x-zmachine"],["z7","application/x-zmachine"],["z8","application/x-zmachine"],["zaz","application/vnd.zzazz.deck+xml"],["zip","application/zip"],["zir","application/vnd.zul"],["zirz","application/vnd.zul"],["zmm","application/vnd.handheld-entertainment+xml"],["zsh","text/x-scriptzsh"]]);function Zr(e,t,r){const n=om(e),{webkitRelativePath:i}=e,a=typeof t=="string"?t:typeof i=="string"&&i.length>0?i:`./${e.name}`;return typeof n.path!="string"&&gs(n,"path",a),gs(n,"relativePath",a),n}function om(e){const{name:t}=e;if(t&&t.lastIndexOf(".")!==-1&&!e.type){const n=t.split(".").pop().toLowerCase(),i=am.get(n);i&&Object.defineProperty(e,"type",{value:i,writable:!1,configurable:!1,enumerable:!0})}return e}function gs(e,t,r){Object.defineProperty(e,t,{value:r,writable:!1,configurable:!1,enumerable:!0})}const sm=[".DS_Store","Thumbs.db"];function lm(e){return Tr(this,void 0,void 0,function*(){return oi(e)&&cm(e.dataTransfer)?fm(e.dataTransfer,e.type):um(e)?pm(e):Array.isArray(e)&&e.every(t=>"getFile"in t&&typeof t.getFile=="function")?dm(e):[]})}function cm(e){return oi(e)}function um(e){return oi(e)&&oi(e.target)}function oi(e){return typeof e=="object"&&e!==null}function pm(e){return ma(e.target.files).map(t=>Zr(t))}function dm(e){return Tr(this,void 0,void 0,function*(){return(yield Promise.all(e.map(r=>r.getFile()))).map(r=>Zr(r))})}function fm(e,t){return Tr(this,void 0,void 0,function*(){if(e.items){const r=ma(e.items).filter(i=>i.kind==="file");if(t!=="drop")return r;const n=yield Promise.all(r.map(hm));return xs(oc(n))}return xs(ma(e.files).map(r=>Zr(r)))})}function xs(e){return e.filter(t=>sm.indexOf(t.name)===-1)}function ma(e){if(e===null)return[];const t=[];for(let r=0;r<e.length;r++){const n=e[r];t.push(n)}return t}function hm(e){if(typeof e.webkitGetAsEntry!="function")return vs(e);const t=e.webkitGetAsEntry();return t&&t.isDirectory?sc(t):vs(e,t)}function oc(e){return e.reduce((t,r)=>[...t,...Array.isArray(r)?oc(r):[r]],[])}function vs(e,t){return Tr(this,void 0,void 0,function*(){var r;if(globalThis.isSecureContext&&typeof e.getAsFileSystemHandle=="function"){const a=yield e.getAsFileSystemHandle();if(a===null)throw new Error(`${e} is not a File`);if(a!==void 0){const o=yield a.getFile();return o.handle=a,Zr(o)}}const n=e.getAsFile();if(!n)throw new Error(`${e} is not a File`);return Zr(n,(r=t==null?void 0:t.fullPath)!==null&&r!==void 0?r:void 0)})}function mm(e){return Tr(this,void 0,void 0,function*(){return e.isDirectory?sc(e):ym(e)})}function sc(e){const t=e.createReader();return new Promise((r,n)=>{const i=[];function a(){t.readEntries(o=>Tr(this,void 0,void 0,function*(){if(o.length){const s=Promise.all(o.map(mm));i.push(s),a()}else try{const s=yield Promise.all(i);r(s)}catch(s){n(s)}}),o=>{n(o)})}a()})}function ym(e){return Tr(this,void 0,void 0,function*(){return new Promise((t,r)=>{e.file(n=>{const i=Zr(n,e.fullPath);t(i)},n=>{r(n)})})})}var Mn={},bs;function gm(){return bs||(bs=1,Mn.__esModule=!0,Mn.default=function(e,t){if(e&&t){var r=Array.isArray(t)?t:t.split(",");if(r.length===0)return!0;var n=e.name||"",i=(e.type||"").toLowerCase(),a=i.replace(/\/.*$/,"");return r.some(function(o){var s=o.trim().toLowerCase();return s.charAt(0)==="."?n.toLowerCase().endsWith(s):s.endsWith("/*")?a===s.replace(/\/.*$/,""):i===s})}return!0}),Mn}var xm=gm();const Ii=Aa(xm);function ws(e){return wm(e)||bm(e)||cc(e)||vm()}function vm(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
180
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function bm(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function wm(e){if(Array.isArray(e))return ya(e)}function Ss(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Cs(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Ss(Object(r),!0).forEach(function(n){lc(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Ss(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function lc(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function gn(e,t){return Em(e)||Cm(e,t)||cc(e,t)||Sm()}function Sm(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
181
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function cc(e,t){if(e){if(typeof e=="string")return ya(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return ya(e,t)}}function ya(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function Cm(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n=[],i=!0,a=!1,o,s;try{for(r=r.call(e);!(i=(o=r.next()).done)&&(n.push(o.value),!(t&&n.length===t));i=!0);}catch(l){a=!0,s=l}finally{try{!i&&r.return!=null&&r.return()}finally{if(a)throw s}}return n}}function Em(e){if(Array.isArray(e))return e}var km=typeof Ii=="function"?Ii:Ii.default,Tm="file-invalid-type",Om="file-too-large",jm="file-too-small",Fm="too-many-files",Am=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"",r=t.split(","),n=r.length>1?"one of ".concat(r.join(", ")):r[0];return{code:Tm,message:"File type must be ".concat(n)}},Es=function(t){return{code:Om,message:"File is larger than ".concat(t," ").concat(t===1?"byte":"bytes")}},ks=function(t){return{code:jm,message:"File is smaller than ".concat(t," ").concat(t===1?"byte":"bytes")}},_m={code:Fm,message:"Too many files"};function uc(e,t){var r=e.type==="application/x-moz-file"||km(e,t);return[r,r?null:Am(t)]}function pc(e,t,r){if(sr(e.size))if(sr(t)&&sr(r)){if(e.size>r)return[!1,Es(r)];if(e.size<t)return[!1,ks(t)]}else{if(sr(t)&&e.size<t)return[!1,ks(t)];if(sr(r)&&e.size>r)return[!1,Es(r)]}return[!0,null]}function sr(e){return e!=null}function Rm(e){var t=e.files,r=e.accept,n=e.minSize,i=e.maxSize,a=e.multiple,o=e.maxFiles,s=e.validator;return!a&&t.length>1||a&&o>=1&&t.length>o?!1:t.every(function(l){var p=uc(l,r),u=gn(p,1),d=u[0],f=pc(l,n,i),g=gn(f,1),S=g[0],c=s?s(l):null;return d&&S&&!c})}function si(e){return typeof e.isPropagationStopped=="function"?e.isPropagationStopped():typeof e.cancelBubble<"u"?e.cancelBubble:!1}function zn(e){return e.dataTransfer?Array.prototype.some.call(e.dataTransfer.types,function(t){return t==="Files"||t==="application/x-moz-file"}):!!e.target&&!!e.target.files}function Ts(e){e.preventDefault()}function $m(e){return e.indexOf("MSIE")!==-1||e.indexOf("Trident/")!==-1}function Dm(e){return e.indexOf("Edge/")!==-1}function Pm(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:window.navigator.userAgent;return $m(e)||Dm(e)}function St(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return function(n){for(var i=arguments.length,a=new Array(i>1?i-1:0),o=1;o<i;o++)a[o-1]=arguments[o];return t.some(function(s){return!si(n)&&s&&s.apply(void 0,[n].concat(a)),si(n)})}}function Im(){return"showOpenFilePicker"in window}function Mm(e){if(sr(e)){var t=Object.entries(e).filter(function(r){var n=gn(r,2),i=n[0],a=n[1],o=!0;return dc(i)||(console.warn('Skipped "'.concat(i,'" because it is not a valid MIME type. Check https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types/Common_types for a list of valid MIME types.')),o=!1),(!Array.isArray(a)||!a.every(fc))&&(console.warn('Skipped "'.concat(i,'" because an invalid file extension was provided.')),o=!1),o}).reduce(function(r,n){var i=gn(n,2),a=i[0],o=i[1];return Cs(Cs({},r),{},lc({},a,o))},{});return[{description:"Files",accept:t}]}return e}function zm(e){if(sr(e))return Object.entries(e).reduce(function(t,r){var n=gn(r,2),i=n[0],a=n[1];return[].concat(ws(t),[i],ws(a))},[]).filter(function(t){return dc(t)||fc(t)}).join(",")}function Vm(e){return e instanceof DOMException&&(e.name==="AbortError"||e.code===e.ABORT_ERR)}function Bm(e){return e instanceof DOMException&&(e.name==="SecurityError"||e.code===e.SECURITY_ERR)}function dc(e){return e==="audio/*"||e==="video/*"||e==="image/*"||e==="text/*"||e==="application/*"||/\w+\/[-+.\w]+/g.test(e)}function fc(e){return/^.*\.[\w]+$/.test(e)}var Nm=["children"],Lm=["open"],qm=["refKey","role","onKeyDown","onFocus","onBlur","onClick","onDragEnter","onDragOver","onDragLeave","onDrop"],Um=["refKey","onChange","onClick"];function Wm(e){return Qm(e)||Km(e)||hc(e)||Hm()}function Hm(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
182
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Km(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Qm(e){if(Array.isArray(e))return ga(e)}function Mi(e,t){return Zm(e)||Gm(e,t)||hc(e,t)||Ym()}function Ym(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
183
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function hc(e,t){if(e){if(typeof e=="string")return ga(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return ga(e,t)}}function ga(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function Gm(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n=[],i=!0,a=!1,o,s;try{for(r=r.call(e);!(i=(o=r.next()).done)&&(n.push(o.value),!(t&&n.length===t));i=!0);}catch(l){a=!0,s=l}finally{try{!i&&r.return!=null&&r.return()}finally{if(a)throw s}}return n}}function Zm(e){if(Array.isArray(e))return e}function Os(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function _e(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Os(Object(r),!0).forEach(function(n){xa(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Os(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function xa(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function li(e,t){if(e==null)return{};var r=Xm(e,t),n,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)n=a[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function Xm(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,a;for(a=0;a<n.length;a++)i=n[a],!(t.indexOf(i)>=0)&&(r[i]=e[i]);return r}var Qa=P.forwardRef(function(e,t){var r=e.children,n=li(e,Nm),i=yc(n),a=i.open,o=li(i,Lm);return P.useImperativeHandle(t,function(){return{open:a}},[a]),P.createElement(P.Fragment,null,r(_e(_e({},o),{},{open:a})))});Qa.displayName="Dropzone";var mc={disabled:!1,getFilesFromEvent:lm,maxSize:1/0,minSize:0,multiple:!0,maxFiles:0,preventDropOnDocument:!0,noClick:!1,noKeyboard:!1,noDrag:!1,noDragEventsBubbling:!1,validator:null,useFsAccessApi:!1,autoFocus:!1};Qa.defaultProps=mc;Qa.propTypes={children:w.func,accept:w.objectOf(w.arrayOf(w.string)),multiple:w.bool,preventDropOnDocument:w.bool,noClick:w.bool,noKeyboard:w.bool,noDrag:w.bool,noDragEventsBubbling:w.bool,minSize:w.number,maxSize:w.number,maxFiles:w.number,disabled:w.bool,getFilesFromEvent:w.func,onFileDialogCancel:w.func,onFileDialogOpen:w.func,useFsAccessApi:w.bool,autoFocus:w.bool,onDragEnter:w.func,onDragLeave:w.func,onDragOver:w.func,onDrop:w.func,onDropAccepted:w.func,onDropRejected:w.func,onError:w.func,validator:w.func};var va={isFocused:!1,isFileDialogActive:!1,isDragActive:!1,isDragAccept:!1,isDragReject:!1,acceptedFiles:[],fileRejections:[]};function yc(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=_e(_e({},mc),e),r=t.accept,n=t.disabled,i=t.getFilesFromEvent,a=t.maxSize,o=t.minSize,s=t.multiple,l=t.maxFiles,p=t.onDragEnter,u=t.onDragLeave,d=t.onDragOver,f=t.onDrop,g=t.onDropAccepted,S=t.onDropRejected,c=t.onFileDialogCancel,b=t.onFileDialogOpen,y=t.useFsAccessApi,j=t.autoFocus,R=t.preventDropOnDocument,k=t.noClick,v=t.noKeyboard,B=t.noDrag,A=t.noDragEventsBubbling,H=t.onError,U=t.validator,h=P.useMemo(function(){return zm(r)},[r]),z=P.useMemo(function(){return Mm(r)},[r]),M=P.useMemo(function(){return typeof b=="function"?b:js},[b]),q=P.useMemo(function(){return typeof c=="function"?c:js},[c]),N=P.useRef(null),J=P.useRef(null),ae=P.useReducer(Jm,va),he=Mi(ae,2),ie=he[0],oe=he[1],V=ie.isFocused,W=ie.isFileDialogActive,ce=P.useRef(typeof window<"u"&&window.isSecureContext&&y&&Im()),me=function(){!ce.current&&W&&setTimeout(function(){if(J.current){var $=J.current.files;$.length||(oe({type:"closeDialog"}),q())}},300)};P.useEffect(function(){return window.addEventListener("focus",me,!1),function(){window.removeEventListener("focus",me,!1)}},[J,W,q,ce]);var se=P.useRef([]),L=function($){N.current&&N.current.contains($.target)||($.preventDefault(),se.current=[])};P.useEffect(function(){return R&&(document.addEventListener("dragover",Ts,!1),document.addEventListener("drop",L,!1)),function(){R&&(document.removeEventListener("dragover",Ts),document.removeEventListener("drop",L))}},[N,R]),P.useEffect(function(){return!n&&j&&N.current&&N.current.focus(),function(){}},[N,j,n]);var X=P.useCallback(function(F){H?H(F):console.error(F)},[H]),ne=P.useCallback(function(F){F.preventDefault(),F.persist(),x(F),se.current=[].concat(Wm(se.current),[F.target]),zn(F)&&Promise.resolve(i(F)).then(function($){if(!(si(F)&&!A)){var Y=$.length,le=Y>0&&Rm({files:$,accept:h,minSize:o,maxSize:a,multiple:s,maxFiles:l,validator:U}),ge=Y>0&&!le;oe({isDragAccept:le,isDragReject:ge,isDragActive:!0,type:"setDraggedFiles"}),p&&p(F)}}).catch(function($){return X($)})},[i,p,X,A,h,o,a,s,l,U]),ue=P.useCallback(function(F){F.preventDefault(),F.persist(),x(F);var $=zn(F);if($&&F.dataTransfer)try{F.dataTransfer.dropEffect="copy"}catch{}return $&&d&&d(F),!1},[d,A]),de=P.useCallback(function(F){F.preventDefault(),F.persist(),x(F);var $=se.current.filter(function(le){return N.current&&N.current.contains(le)}),Y=$.indexOf(F.target);Y!==-1&&$.splice(Y,1),se.current=$,!($.length>0)&&(oe({type:"setDraggedFiles",isDragActive:!1,isDragAccept:!1,isDragReject:!1}),zn(F)&&u&&u(F))},[N,u,A]),pe=P.useCallback(function(F,$){var Y=[],le=[];F.forEach(function(ge){var Ve=uc(ge,h),ft=Mi(Ve,2),st=ft[0],Jr=ft[1],ir=pc(ge,o,a),zt=Mi(ir,2),en=zt[0],Or=zt[1],tn=U?U(ge):null;if(st&&en&&!tn)Y.push(ge);else{var jr=[Jr,Or];tn&&(jr=jr.concat(tn)),le.push({file:ge,errors:jr.filter(function(xc){return xc})})}}),(!s&&Y.length>1||s&&l>=1&&Y.length>l)&&(Y.forEach(function(ge){le.push({file:ge,errors:[_m]})}),Y.splice(0)),oe({acceptedFiles:Y,fileRejections:le,isDragReject:le.length>0,type:"setFiles"}),f&&f(Y,le,$),le.length>0&&S&&S(le,$),Y.length>0&&g&&g(Y,$)},[oe,s,h,o,a,l,f,g,S,U]),D=P.useCallback(function(F){F.preventDefault(),F.persist(),x(F),se.current=[],zn(F)&&Promise.resolve(i(F)).then(function($){si(F)&&!A||pe($,F)}).catch(function($){return X($)}),oe({type:"reset"})},[i,pe,X,A]),_=P.useCallback(function(){if(ce.current){oe({type:"openDialog"}),M();var F={multiple:s,types:z};window.showOpenFilePicker(F).then(function($){return i($)}).then(function($){pe($,null),oe({type:"closeDialog"})}).catch(function($){Vm($)?(q($),oe({type:"closeDialog"})):Bm($)?(ce.current=!1,J.current?(J.current.value=null,J.current.click()):X(new Error("Cannot open the file picker because the https://developer.mozilla.org/en-US/docs/Web/API/File_System_Access_API is not supported and no <input> was provided."))):X($)});return}J.current&&(oe({type:"openDialog"}),M(),J.current.value=null,J.current.click())},[oe,M,q,y,pe,X,z,s]),Q=P.useCallback(function(F){!N.current||!N.current.isEqualNode(F.target)||(F.key===" "||F.key==="Enter"||F.keyCode===32||F.keyCode===13)&&(F.preventDefault(),_())},[N,_]),fe=P.useCallback(function(){oe({type:"focus"})},[]),xe=P.useCallback(function(){oe({type:"blur"})},[]),Be=P.useCallback(function(){k||(Pm()?setTimeout(_,0):_())},[k,_]),Le=function($){return n?null:$},re=function($){return v?null:Le($)},Oe=function($){return B?null:Le($)},x=function($){A&&$.stopPropagation()},O=P.useMemo(function(){return function(){var F=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},$=F.refKey,Y=$===void 0?"ref":$,le=F.role,ge=F.onKeyDown,Ve=F.onFocus,ft=F.onBlur,st=F.onClick,Jr=F.onDragEnter,ir=F.onDragOver,zt=F.onDragLeave,en=F.onDrop,Or=li(F,qm);return _e(_e(xa({onKeyDown:re(St(ge,Q)),onFocus:re(St(Ve,fe)),onBlur:re(St(ft,xe)),onClick:Le(St(st,Be)),onDragEnter:Oe(St(Jr,ne)),onDragOver:Oe(St(ir,ue)),onDragLeave:Oe(St(zt,de)),onDrop:Oe(St(en,D)),role:typeof le=="string"&&le!==""?le:"presentation"},Y,N),!n&&!v?{tabIndex:0}:{}),Or)}},[N,Q,fe,xe,Be,ne,ue,de,D,v,B,n]),T=P.useCallback(function(F){F.stopPropagation()},[]),Z=P.useMemo(function(){return function(){var F=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},$=F.refKey,Y=$===void 0?"ref":$,le=F.onChange,ge=F.onClick,Ve=li(F,Um),ft=xa({accept:h,multiple:s,type:"file",style:{border:0,clip:"rect(0, 0, 0, 0)",clipPath:"inset(50%)",height:"1px",margin:"0 -1px -1px 0",overflow:"hidden",padding:0,position:"absolute",width:"1px",whiteSpace:"nowrap"},onChange:Le(St(le,D)),onClick:Le(St(ge,T)),tabIndex:-1},Y,J);return _e(_e({},ft),Ve)}},[J,r,s,D,n]);return _e(_e({},ie),{},{isFocused:V&&!n,getRootProps:O,getInputProps:Z,rootRef:N,inputRef:J,open:Le(_)})}function Jm(e,t){switch(t.type){case"focus":return _e(_e({},e),{},{isFocused:!0});case"blur":return _e(_e({},e),{},{isFocused:!1});case"openDialog":return _e(_e({},va),{},{isFileDialogActive:!0});case"closeDialog":return _e(_e({},e),{},{isFileDialogActive:!1});case"setDraggedFiles":return _e(_e({},e),{},{isDragActive:t.isDragActive,isDragAccept:t.isDragAccept,isDragReject:t.isDragReject});case"setFiles":return _e(_e({},e),{},{acceptedFiles:t.acceptedFiles,fileRejections:t.fileRejections,isDragReject:t.isDragReject});case"reset":return _e({},va);default:return e}}function js(){}const ey=bt(m.jsx("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m-2 15-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8z"}),"CheckCircle"),ty=bt(m.jsx("path",{d:"M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6zM19 4h-3.5l-1-1h-5l-1 1H5v2h14z"}),"Delete"),Fs=bt(m.jsx("path",{d:"M14 2H6c-1.1 0-1.99.9-1.99 2L4 20c0 1.1.89 2 1.99 2H18c1.1 0 2-.9 2-2V8zm2 16H8v-2h8zm0-4H8v-2h8zm-3-5V3.5L18.5 9z"}),"Description"),ry=bt(m.jsx("path",{d:"M21 19V5c0-1.1-.9-2-2-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2M8.5 13.5l2.5 3.01L14.5 12l4.5 6H5z"}),"Image"),gc=({file:e,onRemove:t})=>{const r=()=>e.file.type.startsWith("image/")?m.jsx(ry,{}):e.file.type.includes("pdf")?m.jsx(Fs,{}):m.jsx(Fs,{}),n=()=>{switch(e.status){case"success":return m.jsx(ey,{color:"success"});case"uploading":return m.jsx(E.CircularProgress,{size:16});default:return null}},i=a=>{if(a===0)return"0 Bytes";const o=1024,s=["Bytes","KB","MB","GB"],l=Math.floor(Math.log(a)/Math.log(o));return parseFloat((a/Math.pow(o,l)).toFixed(2))+" "+s[l]};return m.jsxs(E.Paper,{sx:{p:2,mb:1,display:"flex",alignItems:"center",gap:2,border:"1px solid #e0e0e0"},children:[m.jsxs(E.Box,{sx:{display:"flex",alignItems:"center",gap:1},children:[r(),n()]}),m.jsxs(E.Box,{sx:{flex:1,minWidth:0},children:[m.jsx(E.Typography,{variant:"body2",noWrap:!0,children:e.file.name}),m.jsxs(E.Typography,{variant:"caption",color:"textSecondary",children:[i(e.file.size)," • ",e.file.type]})]}),m.jsx(E.Tooltip,{title:"Remove file",children:m.jsx(E.IconButton,{size:"small",onClick:()=>t(e.id),color:"error",children:m.jsx(ty,{})})})]})},ny=({config:e,value:t=[],onChange:r,onSubmit:n,disabled:i=!1,className:a,style:o,title:s,subtitle:l,buttonText:p,fileSupportedText:u})=>{const[d,f]=P.useState(t),[g,S]=P.useState([]),[c,b]=P.useState(!1),[y,j]=P.useState(!1),[R,k]=P.useState([]),v=P.useRef(null);P.useEffect(()=>{f(t)},[t]);const B=P.useCallback(N=>{var ae,he;return((ae=e==null?void 0:e.fileTypes)==null?void 0:ae.some(ie=>{if(ie.includes("*")){const oe=ie.split("/")[0];return N.type.startsWith(oe)}return N.type===ie}))?e!=null&&e.maxSize&&N.size>e.maxSize?`File size exceeds maximum limit of ${(e.maxSize/1048576).toFixed(1)}MB`:null:`File type ${N.type} is not allowed. Allowed types: ${(he=e==null?void 0:e.fileTypes)==null?void 0:he.join(", ")}`},[e]),A=P.useCallback(async N=>{console.log("handleFiles called with:",N.length,"files"),b(!0);const J=[],ae=[];try{for(const ie of N){let oe=null;if(e!=null&&e.multiple&&d.some(W=>W.file.name===ie.name&&W.file.size===ie.size&&W.file.lastModified===ie.lastModified)){ae.push(`${ie.name}: File already exists`);continue}if(oe=B(ie),!oe&&(e!=null&&e.customValidation))try{const V=e.customValidation(ie);V instanceof Promise?oe=await V:oe=V}catch(V){oe=`Custom validation failed: ${V instanceof Error?V.message:"Unknown error"}`}if(oe)ae.push(`${ie.name}: ${oe}`);else{const V={id:`${Date.now()}-${Math.random().toString(36).substr(2,9)}`,file:ie,preview:ie.type.startsWith("image/")?URL.createObjectURL(ie):void 0,progress:0,status:"pending",uploadedAt:new Date};J.push(V)}}const he=e!=null&&e.multiple?[...d,...J]:J;f(he),r==null||r(he),ae.length>0?(k(ae),S(ae)):(k([]),S([]))}catch(he){const ie=`Unexpected error: ${he instanceof Error?he.message:"Unknown error"}`;k([ie]),S([ie])}},[d,e==null?void 0:e.multiple,B,e==null?void 0:e.customValidation,r]),H=P.useCallback(N=>{b(!0);const J=d.filter(ae=>ae.id!==N);f(J),r==null||r(J),k([]),v.current&&(v.current.value="")},[d,r]),U=P.useCallback(()=>{if(e!=null&&e.required&&d.length===0){S([`${e.title} is required`]);return}k([]),j(!0);const N=d.filter(J=>J.status!=="error");n==null||n(N)},[d,n,e==null?void 0:e.required,e==null?void 0:e.title]),{getRootProps:h,getInputProps:z,isDragActive:M}=yc({onDrop:A,multiple:e==null?void 0:e.multiple,disabled:i,noClick:!1,noKeyboard:!1});P.useEffect(()=>{if(!c)return;const N=[],J=[...R,...N];J.length>0?S(J):S([])},[d,e==null?void 0:e.required,e==null?void 0:e.title,c,y,R]);const q=()=>{var N;switch(((N=e==null?void 0:e.submitButton)==null?void 0:N.position)||"right"){case"left":return"flex-start";case"center":return"center";case"right":return"flex-end";default:return"flex-end"}};return m.jsxs(E.Box,{className:a,style:o,children:[m.jsxs(E.Typography,{variant:"h6",gutterBottom:!0,children:[e==null?void 0:e.title,(e==null?void 0:e.required)&&m.jsx("span",{style:{color:"red"},children:" *"})]}),(e==null?void 0:e.description)&&m.jsx(E.Typography,{variant:"body2",color:"textSecondary",gutterBottom:!0,children:e==null?void 0:e.description}),P.createElement(E.Card,{...h(),key:`dropzone-${d.length}`,sx:{border:"1px dashed",borderColor:M?"primary.main":"#CCCCCC",backgroundColor:M?"action.hover":"#F5F5F5",boxShadow:"none",p:3,textAlign:"center",cursor:i?"not-allowed":"pointer",transition:"all 0.2s ease","&:hover":{borderColor:i?"grey.300":"primary.main",backgroundColor:i?"background.paper":"action.hover"}}},m.jsx("input",{...z(),ref:v}),m.jsx(E.IconButton,{sx:{borderRadius:"8px"},children:m.jsx(ni,{sx:{width:36,height:36,color:"primary.main"}})}),m.jsx(E.Typography,{sx:{fontSize:"16px",fontWeight:600,color:"primary.main"},children:s}),m.jsx(E.Typography,{sx:{fontSize:"12px",fontWeight:400,color:"primary.main"},children:l}),m.jsx(E.Button,{onClick:()=>{var N;return(N=v.current)==null?void 0:N.click()},sx:{my:2},startIcon:m.jsx(ni,{}),variant:"contained",children:p}),m.jsx(E.Typography,{sx:{fontSize:"12px",fontWeight:400},children:u})),g.length>0&&m.jsx(E.Alert,{severity:"error",sx:{mt:2},children:g.map((N,J)=>m.jsx(E.Typography,{variant:"body2",children:N},J))}),d.length>0&&m.jsxs(E.Box,{sx:{mt:2},children:[m.jsxs(E.Typography,{variant:"subtitle1",gutterBottom:!0,children:["Selected Files (",d.length,")"]}),d.map(N=>m.jsx(gc,{file:N,onRemove:H},N.id))]}),(e==null?void 0:e.helperText)&&m.jsx(E.Typography,{variant:"caption",color:"textSecondary",sx:{mt:1,display:"block"},children:e.helperText}),(e==null?void 0:e.submitButton)&&m.jsx(E.Box,{sx:{mt:3,display:"flex",justifyContent:q()},children:m.jsx(E.Button,{variant:"contained",onClick:U,disabled:i||e.submitButton.disabled||d.length===0,startIcon:e.submitButton.loading?m.jsx(E.CircularProgress,{size:16,color:"inherit"}):void 0,children:e.submitButton.text})})]})};exports.CustomButtons=ac;exports.DocumentUpload=ny;exports.FieldRenderer=Nl;exports.FilePreview=gc;exports.FinAutocomplete=Pl;exports.FinCheckbox=la;exports.FinChip=zl;exports.FinCustomizedVerticalStepper=yh;exports.FinDateField=Il;exports.FinDragDropList=dh;exports.FinForm=rm;exports.FinInfoCard=xh;exports.FinRadioGroup=ua;exports.FinSelect=Dl;exports.FinSwitch=ca;exports.FinTabs=vh;exports.FinTextField=sa;exports.FinTextarea=Ml;exports.FinUiHeader=pa;exports.FinVerticalStepper=hh;exports.ImageComponent=im;exports.StepNavigation=ic;exports.brand=ch;exports.fetchApiData=Vl;exports.finflowPalette=K;exports.generateSchema=nc;exports.getApiConfig=Wa;exports.hasApiConfig=or;exports.neutral=tt;exports.primary=sh;exports.secondary=lh;exports.shouldShowField=bh;exports.useApiData=Bl;