finform-react-builder 1.6.2 → 1.7.0

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 nc=Object.defineProperty;var Va=e=>{throw TypeError(e)};var ic=(e,t,r)=>t in e?nc(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var Xr=(e,t,r)=>ic(e,typeof t!="symbol"?t+"":t,r),gi=(e,t,r)=>t.has(e)||Va("Cannot "+r);var b=(e,t,r)=>(gi(e,t,"read from private field"),r?r.call(e):t.get(e)),fe=(e,t,r)=>t.has(e)?Va("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,r),ne=(e,t,r,n)=>(gi(e,t,"write to private field"),n?n.call(e,r):t.set(e,r),r),ye=(e,t,r)=>(gi(e,t,"access private method"),r);var Cn=(e,t,r,n)=>({set _(i){ne(e,t,i,r)},get _(){return b(e,t,n)}});Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const v=require("react/jsx-runtime"),I=require("react"),D=require("@mui/material"),ac=require("@emotion/styled"),vr=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 ie=sc(I);var vn=e=>e.type==="checkbox",ir=e=>e instanceof Date,He=e=>e==null;const _o=e=>typeof e=="object";var Pe=e=>!He(e)&&!Array.isArray(e)&&_o(e)&&!ir(e),Ao=e=>Pe(e)&&e.target?vn(e.target)?e.target.checked:e.target.value:e,oc=e=>e.substring(0,e.search(/\.\d+(\.|$)/))||e,Fo=(e,t)=>e.has(oc(t)),lc=e=>{const t=e.constructor&&e.constructor.prototype;return Pe(t)&&t.hasOwnProperty("isPrototypeOf")},da=typeof window<"u"&&typeof window.HTMLElement<"u"&&typeof document<"u";function Ve(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(!(da&&(e instanceof Blob||n))&&(r||Pe(e)))if(t=r?[]:{},!r&&!lc(e))t=e;else for(const i in e)e.hasOwnProperty(i)&&(t[i]=Ve(e[i]));else return e;return t}var si=e=>/^\w*$/.test(e),De=e=>e===void 0,fa=e=>Array.isArray(e)?e.filter(Boolean):[],ma=e=>fa(e.replace(/["|']|\]/g,"").split(/\.|\[/)),Y=(e,t,r)=>{if(!t||!Pe(e))return r;const n=(si(t)?[t]:ma(t)).reduce((i,a)=>He(i)?i:i[a],e);return De(n)||n===e?De(e[t])?r:e[t]:n},et=e=>typeof e=="boolean",be=(e,t,r)=>{let n=-1;const i=si(t)?[t]:ma(t),a=i.length,s=a-1;for(;++n<a;){const o=i[n];let l=r;if(n!==s){const d=e[o];l=Pe(d)||Array.isArray(d)?d:isNaN(+i[n+1])?{}:[]}if(o==="__proto__"||o==="constructor"||o==="prototype")return;e[o]=l,e=e[o]}};const Bn={BLUR:"blur",FOCUS_OUT:"focusout",CHANGE:"change"},ft={onBlur:"onBlur",onChange:"onChange",onSubmit:"onSubmit",onTouched:"onTouched",all:"all"},Ot={max:"max",min:"min",maxLength:"maxLength",minLength:"minLength",pattern:"pattern",required:"required",validate:"validate"},jo=I.createContext(null);jo.displayName="HookFormContext";const ha=()=>I.useContext(jo);var Ro=(e,t,r,n=!0)=>{const i={defaultValues:t._defaultValues};for(const a in e)Object.defineProperty(i,a,{get:()=>{const s=a;return t._proxyFormState[s]!==ft.all&&(t._proxyFormState[s]=!n||ft.all),r&&(r[s]=!0),e[s]}});return i};const ya=typeof window<"u"?ie.useLayoutEffect:ie.useEffect;function cc(e){const t=ha(),{control:r=t.control,disabled:n,name:i,exact:a}=e||{},[s,o]=I.useState(r._formState),l=I.useRef({isDirty:!1,isLoading:!1,dirtyFields:!1,touchedFields:!1,validatingFields:!1,isValidating:!1,isValid:!1,errors:!1});return ya(()=>r._subscribe({name:i,formState:l.current,exact:a,callback:d=>{!n&&o({...r._formState,...d})}}),[i,n,a]),I.useEffect(()=>{l.current.isValid&&r._setValid(!0)},[r]),I.useMemo(()=>Ro(s,r,l.current,!1),[s,r])}var Tt=e=>typeof e=="string",$o=(e,t,r,n,i)=>Tt(e)?(n&&t.watch.add(e),Y(r,e,i)):Array.isArray(e)?e.map(a=>(n&&t.watch.add(a),Y(r,a))):(n&&(t.watchAll=!0),r);function uc(e){const t=ha(),{control:r=t.control,name:n,defaultValue:i,disabled:a,exact:s}=e||{},o=I.useRef(i),[l,d]=I.useState(r._getWatch(n,o.current));return ya(()=>r._subscribe({name:n,formState:{values:!0},exact:s,callback:u=>!a&&d($o(n,r._names,u.values||r._formValues,!1,o.current))}),[n,r,a,s]),I.useEffect(()=>r._removeUnmounted()),l}function pc(e){const t=ha(),{name:r,disabled:n,control:i=t.control,shouldUnregister:a}=e,s=Fo(i._names.array,r),o=uc({control:i,name:r,defaultValue:Y(i._formValues,r,Y(i._defaultValues,r,e.defaultValue)),exact:!0}),l=cc({control:i,name:r,exact:!0}),d=I.useRef(e),u=I.useRef(i.register(r,{...e.rules,value:o,...et(e.disabled)?{disabled:e.disabled}:{}})),f=I.useMemo(()=>Object.defineProperties({},{invalid:{enumerable:!0,get:()=>!!Y(l.errors,r)},isDirty:{enumerable:!0,get:()=>!!Y(l.dirtyFields,r)},isTouched:{enumerable:!0,get:()=>!!Y(l.touchedFields,r)},isValidating:{enumerable:!0,get:()=>!!Y(l.validatingFields,r)},error:{enumerable:!0,get:()=>Y(l.errors,r)}}),[l,r]),m=I.useCallback(E=>u.current.onChange({target:{value:Ao(E),name:r},type:Bn.CHANGE}),[r]),x=I.useCallback(()=>u.current.onBlur({target:{value:Y(i._formValues,r),name:r},type:Bn.BLUR}),[r,i._formValues]),S=I.useCallback(E=>{const h=Y(i._fields,r);h&&E&&(h._f.ref={focus:()=>E.focus&&E.focus(),select:()=>E.select&&E.select(),setCustomValidity:_=>E.setCustomValidity(_),reportValidity:()=>E.reportValidity()})},[i._fields,r]),c=I.useMemo(()=>({name:r,value:o,...et(n)||l.disabled?{disabled:l.disabled||n}:{},onChange:m,onBlur:x,ref:S}),[r,n,l.disabled,m,x,S,o]);return I.useEffect(()=>{const E=i._options.shouldUnregister||a;i.register(r,{...d.current.rules,...et(d.current.disabled)?{disabled:d.current.disabled}:{}});const h=(_,$)=>{const T=Y(i._fields,_);T&&T._f&&(T._f.mount=$)};if(h(r,!0),E){const _=Ve(Y(i._options.defaultValues,r));be(i._defaultValues,r,_),De(Y(i._formValues,r))&&be(i._formValues,r,_)}return!s&&i.register(r),()=>{(s?E&&!i._state.action:E)?i.unregister(r):h(r,!1)}},[r,i,s,a]),I.useEffect(()=>{i._setDisabledField({disabled:n,name:r})},[n,r,i]),I.useMemo(()=>({field:c,formState:l,fieldState:f}),[c,l,f])}const gt=e=>e.render(pc(e));var Do=(e,t,r,n,i)=>t?{...r[e],types:{...r[e]&&r[e].types?r[e].types:{},[n]:i||!0}}:{},on=e=>Array.isArray(e)?e:[e],Na=()=>{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=[]}}},Pi=e=>He(e)||!_o(e);function zt(e,t){if(Pi(e)||Pi(t))return e===t;if(ir(e)&&ir(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 s=t[i];if(ir(a)&&ir(s)||Pe(a)&&Pe(s)||Array.isArray(a)&&Array.isArray(s)?!zt(a,s):a!==s)return!1}}return!0}var Ge=e=>Pe(e)&&!Object.keys(e).length,ga=e=>e.type==="file",mt=e=>typeof e=="function",Ln=e=>{if(!da)return!1;const t=e?e.ownerDocument:0;return e instanceof(t&&t.defaultView?t.defaultView.HTMLElement:HTMLElement)},Po=e=>e.type==="select-multiple",va=e=>e.type==="radio",dc=e=>va(e)||vn(e),vi=e=>Ln(e)&&e.isConnected;function fc(e,t){const r=t.slice(0,-1).length;let n=0;for(;n<r;)e=De(e)?n++:e[t[n++]];return e}function mc(e){for(const t in e)if(e.hasOwnProperty(t)&&!De(e[t]))return!1;return!0}function Me(e,t){const r=Array.isArray(t)?t:si(t)?[t]:ma(t),n=r.length===1?e:fc(e,r),i=r.length-1,a=r[i];return n&&delete n[a],i!==0&&(Pe(n)&&Ge(n)||Array.isArray(n)&&mc(n))&&Me(e,r.slice(0,-1)),e}var Io=e=>{for(const t in e)if(mt(e[t]))return!0;return!1};function qn(e,t={}){const r=Array.isArray(e);if(Pe(e)||r)for(const n in e)Array.isArray(e[n])||Pe(e[n])&&!Io(e[n])?(t[n]=Array.isArray(e[n])?[]:{},qn(e[n],t[n])):He(e[n])||(t[n]=!0);return t}function Mo(e,t,r){const n=Array.isArray(e);if(Pe(e)||n)for(const i in e)Array.isArray(e[i])||Pe(e[i])&&!Io(e[i])?De(t)||Pi(r[i])?r[i]=Array.isArray(e[i])?qn(e[i],[]):{...qn(e[i])}:Mo(e[i],He(t)?{}:t[i],r[i]):r[i]=!zt(e[i],t[i]);return r}var Jr=(e,t)=>Mo(e,t,qn(t));const Ba={value:!1,isValid:!1},La={value:!0,isValid:!0};var zo=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&&!De(e[0].attributes.value)?De(e[0].value)||e[0].value===""?La:{value:e[0].value,isValid:!0}:La:Ba}return Ba},Vo=(e,{valueAsNumber:t,valueAsDate:r,setValueAs:n})=>De(e)?e:t?e===""?NaN:e&&+e:r&&Tt(e)?new Date(e):n?n(e):e;const qa={isValid:!1,value:null};var No=e=>Array.isArray(e)?e.reduce((t,r)=>r&&r.checked&&!r.disabled?{isValid:!0,value:r.value}:t,qa):qa;function Ua(e){const t=e.ref;return ga(t)?t.files:va(t)?No(e.refs).value:Po(t)?[...t.selectedOptions].map(({value:r})=>r):vn(t)?zo(e.refs).value:Vo(De(t.value)?e.ref.value:t.value,e)}var hc=(e,t,r,n)=>{const i={};for(const a of e){const s=Y(t,a);s&&be(i,a,s._f)}return{criteriaMode:r,names:[...e],fields:i,shouldUseNativeValidation:n}},Un=e=>e instanceof RegExp,en=e=>De(e)?e:Un(e)?e.source:Pe(e)?Un(e.value)?e.value.source:e.value:e,Wa=e=>({isOnSubmit:!e||e===ft.onSubmit,isOnBlur:e===ft.onBlur,isOnChange:e===ft.onChange,isOnAll:e===ft.all,isOnTouch:e===ft.onTouched});const Ha="AsyncFunction";var yc=e=>!!e&&!!e.validate&&!!(mt(e.validate)&&e.validate.constructor.name===Ha||Pe(e.validate)&&Object.values(e.validate).find(t=>t.constructor.name===Ha)),gc=e=>e.mount&&(e.required||e.min||e.max||e.maxLength||e.minLength||e.pattern||e.validate),Ka=(e,t,r)=>!r&&(t.watchAll||t.watch.has(e)||[...t.watch].some(n=>e.startsWith(n)&&/^\.\w+/.test(e.slice(n.length))));const ln=(e,t,r,n)=>{for(const i of r||Object.keys(e)){const a=Y(e,i);if(a){const{_f:s,...o}=a;if(s){if(s.refs&&s.refs[0]&&t(s.refs[0],i)&&!n)return!0;if(s.ref&&t(s.ref,s.name)&&!n)return!0;if(ln(o,t))break}else if(Pe(o)&&ln(o,t))break}}};function Qa(e,t,r){const n=Y(e,r);if(n||si(r))return{error:n,name:r};const i=r.split(".");for(;i.length;){const a=i.join("."),s=Y(t,a),o=Y(e,a);if(s&&!Array.isArray(s)&&r!==a)return{name:r};if(o&&o.type)return{name:a,error:o};if(o&&o.root&&o.root.type)return{name:`${a}.root`,error:o.root};i.pop()}return{name:r}}var vc=(e,t,r,n)=>{r(e);const{name:i,...a}=e;return Ge(a)||Object.keys(a).length>=Object.keys(t).length||Object.keys(a).find(s=>t[s]===(!n||ft.all))},xc=(e,t,r)=>!e||!t||e===t||on(e).some(n=>n&&(r?n===t:n.startsWith(t)||t.startsWith(n))),bc=(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,wc=(e,t)=>!fa(Y(e,t)).length&&Me(e,t),Sc=(e,t,r)=>{const n=on(Y(e,r));return be(n,"root",t[r]),be(e,r,n),e},Pn=e=>Tt(e);function Ya(e,t,r="validate"){if(Pn(e)||Array.isArray(e)&&e.every(Pn)||et(e)&&!e)return{type:r,message:Pn(e)?e:"",ref:t}}var Tr=e=>Pe(e)&&!Un(e)?e:{value:e,message:""},Ga=async(e,t,r,n,i,a)=>{const{ref:s,refs:o,required:l,maxLength:d,minLength:u,min:f,max:m,pattern:x,validate:S,name:c,valueAsNumber:E,mount:h}=e._f,_=Y(r,c);if(!h||t.has(c))return{};const $=o?o[0]:s,T=V=>{i&&$.reportValidity&&($.setCustomValidity(et(V)?"":V||""),$.reportValidity())},w={},F=va(s),X=vn(s),J=F||X,W=(E||ga(s))&&De(s.value)&&De(_)||Ln(s)&&s.value===""||_===""||Array.isArray(_)&&!_.length,p=Do.bind(null,c,n,w),R=(V,B,z,H=Ot.maxLength,le=Ot.minLength)=>{const ce=V?B:z;w[c]={type:V?H:le,message:ce,ref:s,...p(V?H:le,ce)}};if(a?!Array.isArray(_)||!_.length:l&&(!J&&(W||He(_))||et(_)&&!_||X&&!zo(o).isValid||F&&!No(o).isValid)){const{value:V,message:B}=Pn(l)?{value:!!l,message:l}:Tr(l);if(V&&(w[c]={type:Ot.required,message:B,ref:$,...p(Ot.required,B)},!n))return T(B),w}if(!W&&(!He(f)||!He(m))){let V,B;const z=Tr(m),H=Tr(f);if(!He(_)&&!isNaN(_)){const le=s.valueAsNumber||_&&+_;He(z.value)||(V=le>z.value),He(H.value)||(B=le<H.value)}else{const le=s.valueAsDate||new Date(_),ce=N=>new Date(new Date().toDateString()+" "+N),pe=s.type=="time",oe=s.type=="week";Tt(z.value)&&_&&(V=pe?ce(_)>ce(z.value):oe?_>z.value:le>new Date(z.value)),Tt(H.value)&&_&&(B=pe?ce(_)<ce(H.value):oe?_<H.value:le<new Date(H.value))}if((V||B)&&(R(!!V,z.message,H.message,Ot.max,Ot.min),!n))return T(w[c].message),w}if((d||u)&&!W&&(Tt(_)||a&&Array.isArray(_))){const V=Tr(d),B=Tr(u),z=!He(V.value)&&_.length>+V.value,H=!He(B.value)&&_.length<+B.value;if((z||H)&&(R(z,V.message,B.message),!n))return T(w[c].message),w}if(x&&!W&&Tt(_)){const{value:V,message:B}=Tr(x);if(Un(V)&&!_.match(V)&&(w[c]={type:Ot.pattern,message:B,ref:s,...p(Ot.pattern,B)},!n))return T(B),w}if(S){if(mt(S)){const V=await S(_,r),B=Ya(V,$);if(B&&(w[c]={...B,...p(Ot.validate,B.message)},!n))return T(B.message),w}else if(Pe(S)){let V={};for(const B in S){if(!Ge(V)&&!n)break;const z=Ya(await S[B](_,r),$,B);z&&(V={...z,...p(B,z.message)},T(z.message),n&&(w[c]=V))}if(!Ge(V)&&(w[c]={ref:$,...V},!n))return w}}return T(!0),w};const Ec={mode:ft.onSubmit,reValidateMode:ft.onChange,shouldFocusError:!0};function Cc(e={}){let t={...Ec,...e},r={submitCount:0,isDirty:!1,isReady:!1,isLoading:mt(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=Pe(t.defaultValues)||Pe(t.values)?Ve(t.defaultValues||t.values)||{}:{},a=t.shouldUnregister?{}:Ve(i),s={action:!1,mount:!1,watch:!1},o={mount:new Set,disabled:new Set,unMount:new Set,array:new Set,watch:new Set},l,d=0;const u={isDirty:!1,dirtyFields:!1,validatingFields:!1,touchedFields:!1,isValidating:!1,isValid:!1,errors:!1};let f={...u};const m={array:Na(),state:Na()},x=t.criteriaMode===ft.all,S=y=>O=>{clearTimeout(d),d=setTimeout(y,O)},c=async y=>{if(!t.disabled&&(u.isValid||f.isValid||y)){const O=t.resolver?Ge((await X()).errors):await W(n,!0);O!==r.isValid&&m.state.next({isValid:O})}},E=(y,O)=>{!t.disabled&&(u.isValidating||u.validatingFields||f.isValidating||f.validatingFields)&&((y||Array.from(o.mount)).forEach(k=>{k&&(O?be(r.validatingFields,k,O):Me(r.validatingFields,k))}),m.state.next({validatingFields:r.validatingFields,isValidating:!Ge(r.validatingFields)}))},h=(y,O=[],k,Z,A=!0,j=!0)=>{if(Z&&k&&!t.disabled){if(s.action=!0,j&&Array.isArray(Y(n,y))){const G=k(Y(n,y),Z.argA,Z.argB);A&&be(n,y,G)}if(j&&Array.isArray(Y(r.errors,y))){const G=k(Y(r.errors,y),Z.argA,Z.argB);A&&be(r.errors,y,G),wc(r.errors,y)}if((u.touchedFields||f.touchedFields)&&j&&Array.isArray(Y(r.touchedFields,y))){const G=k(Y(r.touchedFields,y),Z.argA,Z.argB);A&&be(r.touchedFields,y,G)}(u.dirtyFields||f.dirtyFields)&&(r.dirtyFields=Jr(i,a)),m.state.next({name:y,isDirty:R(y,O),dirtyFields:r.dirtyFields,errors:r.errors,isValid:r.isValid})}else be(a,y,O)},_=(y,O)=>{be(r.errors,y,O),m.state.next({errors:r.errors})},$=y=>{r.errors=y,m.state.next({errors:r.errors,isValid:!1})},T=(y,O,k,Z)=>{const A=Y(n,y);if(A){const j=Y(a,y,De(k)?Y(i,y):k);De(j)||Z&&Z.defaultChecked||O?be(a,y,O?j:Ua(A._f)):z(y,j),s.mount&&c()}},w=(y,O,k,Z,A)=>{let j=!1,G=!1;const de={name:y};if(!t.disabled){if(!k||Z){(u.isDirty||f.isDirty)&&(G=r.isDirty,r.isDirty=de.isDirty=R(),j=G!==de.isDirty);const he=zt(Y(i,y),O);G=!!Y(r.dirtyFields,y),he?Me(r.dirtyFields,y):be(r.dirtyFields,y,!0),de.dirtyFields=r.dirtyFields,j=j||(u.dirtyFields||f.dirtyFields)&&G!==!he}if(k){const he=Y(r.touchedFields,y);he||(be(r.touchedFields,y,k),de.touchedFields=r.touchedFields,j=j||(u.touchedFields||f.touchedFields)&&he!==k)}j&&A&&m.state.next(de)}return j?de:{}},F=(y,O,k,Z)=>{const A=Y(r.errors,y),j=(u.isValid||f.isValid)&&et(O)&&r.isValid!==O;if(t.delayError&&k?(l=S(()=>_(y,k)),l(t.delayError)):(clearTimeout(d),l=null,k?be(r.errors,y,k):Me(r.errors,y)),(k?!zt(A,k):A)||!Ge(Z)||j){const G={...Z,...j&&et(O)?{isValid:O}:{},errors:r.errors,name:y};r={...r,...G},m.state.next(G)}},X=async y=>{E(y,!0);const O=await t.resolver(a,t.context,hc(y||o.mount,n,t.criteriaMode,t.shouldUseNativeValidation));return E(y),O},J=async y=>{const{errors:O}=await X(y);if(y)for(const k of y){const Z=Y(O,k);Z?be(r.errors,k,Z):Me(r.errors,k)}else r.errors=O;return O},W=async(y,O,k={valid:!0})=>{for(const Z in y){const A=y[Z];if(A){const{_f:j,...G}=A;if(j){const de=o.array.has(j.name),he=A._f&&yc(A._f);he&&u.validatingFields&&E([Z],!0);const ze=await Ga(A,o.disabled,a,x,t.shouldUseNativeValidation&&!O,de);if(he&&u.validatingFields&&E([Z]),ze[j.name]&&(k.valid=!1,O))break;!O&&(Y(ze,j.name)?de?Sc(r.errors,ze,j.name):be(r.errors,j.name,ze[j.name]):Me(r.errors,j.name))}!Ge(G)&&await W(G,O,k)}}return k.valid},p=()=>{for(const y of o.unMount){const O=Y(n,y);O&&(O._f.refs?O._f.refs.every(k=>!vi(k)):!vi(O._f.ref))&&te(y)}o.unMount=new Set},R=(y,O)=>!t.disabled&&(y&&O&&be(a,y,O),!zt(N(),i)),V=(y,O,k)=>$o(y,o,{...s.mount?a:De(O)?i:Tt(y)?{[y]:O}:O},k,O),B=y=>fa(Y(s.mount?a:i,y,t.shouldUnregister?Y(i,y,[]):[])),z=(y,O,k={})=>{const Z=Y(n,y);let A=O;if(Z){const j=Z._f;j&&(!j.disabled&&be(a,y,Vo(O,j)),A=Ln(j.ref)&&He(O)?"":O,Po(j.ref)?[...j.ref.options].forEach(G=>G.selected=A.includes(G.value)):j.refs?vn(j.ref)?j.refs.forEach(G=>{(!G.defaultChecked||!G.disabled)&&(Array.isArray(A)?G.checked=!!A.find(de=>de===G.value):G.checked=A===G.value||!!A)}):j.refs.forEach(G=>G.checked=G.value===A):ga(j.ref)?j.ref.value="":(j.ref.value=A,j.ref.type||m.state.next({name:y,values:Ve(a)})))}(k.shouldDirty||k.shouldTouch)&&w(y,A,k.shouldTouch,k.shouldDirty,!0),k.shouldValidate&&oe(y)},H=(y,O,k)=>{for(const Z in O){if(!O.hasOwnProperty(Z))return;const A=O[Z],j=y+"."+Z,G=Y(n,j);(o.array.has(y)||Pe(A)||G&&!G._f)&&!ir(A)?H(j,A,k):z(j,A,k)}},le=(y,O,k={})=>{const Z=Y(n,y),A=o.array.has(y),j=Ve(O);be(a,y,j),A?(m.array.next({name:y,values:Ve(a)}),(u.isDirty||u.dirtyFields||f.isDirty||f.dirtyFields)&&k.shouldDirty&&m.state.next({name:y,dirtyFields:Jr(i,a),isDirty:R(y,j)})):Z&&!Z._f&&!He(j)?H(y,j,k):z(y,j,k),Ka(y,o)&&m.state.next({...r}),m.state.next({name:s.mount?y:void 0,values:Ve(a)})},ce=async y=>{s.mount=!0;const O=y.target;let k=O.name,Z=!0;const A=Y(n,k),j=he=>{Z=Number.isNaN(he)||ir(he)&&isNaN(he.getTime())||zt(he,Y(a,k,he))},G=Wa(t.mode),de=Wa(t.reValidateMode);if(A){let he,ze;const ut=O.type?Ua(A._f):Ao(y),it=y.type===Bn.BLUR||y.type===Bn.FOCUS_OUT,Yr=!gc(A._f)&&!t.resolver&&!Y(r.errors,k)&&!A._f.deps||bc(it,Y(r.touchedFields,k),r.isSubmitted,de,G),er=Ka(k,o,it);be(a,k,ut),it?(A._f.onBlur&&A._f.onBlur(y),l&&l(0)):A._f.onChange&&A._f.onChange(y);const Dt=w(k,ut,it),Gr=!Ge(Dt)||er;if(!it&&m.state.next({name:k,type:y.type,values:Ve(a)}),Yr)return(u.isValid||f.isValid)&&(t.mode==="onBlur"?it&&c():it||c()),Gr&&m.state.next({name:k,...er?{}:Dt});if(!it&&er&&m.state.next({...r}),t.resolver){const{errors:Er}=await X([k]);if(j(ut),Z){const Zr=Qa(r.errors,n,k),Cr=Qa(Er,n,Zr.name||k);he=Cr.error,k=Cr.name,ze=Ge(Er)}}else E([k],!0),he=(await Ga(A,o.disabled,a,x,t.shouldUseNativeValidation))[k],E([k]),j(ut),Z&&(he?ze=!1:(u.isValid||f.isValid)&&(ze=await W(n,!0)));Z&&(A._f.deps&&oe(A._f.deps),F(k,ze,he,Dt))}},pe=(y,O)=>{if(Y(r.errors,O)&&y.focus)return y.focus(),1},oe=async(y,O={})=>{let k,Z;const A=on(y);if(t.resolver){const j=await J(De(y)?y:A);k=Ge(j),Z=y?!A.some(G=>Y(j,G)):k}else y?(Z=(await Promise.all(A.map(async j=>{const G=Y(n,j);return await W(G&&G._f?{[j]:G}:G)}))).every(Boolean),!(!Z&&!r.isValid)&&c()):Z=k=await W(n);return m.state.next({...!Tt(y)||(u.isValid||f.isValid)&&k!==r.isValid?{}:{name:y},...t.resolver||!y?{isValid:k}:{},errors:r.errors}),O.shouldFocus&&!Z&&ln(n,pe,y?A:o.mount),Z},N=y=>{const O={...s.mount?a:i};return De(y)?O:Tt(y)?Y(O,y):y.map(k=>Y(O,k))},L=(y,O)=>({invalid:!!Y((O||r).errors,y),isDirty:!!Y((O||r).dirtyFields,y),error:Y((O||r).errors,y),isValidating:!!Y(r.validatingFields,y),isTouched:!!Y((O||r).touchedFields,y)}),K=y=>{y&&on(y).forEach(O=>Me(r.errors,O)),m.state.next({errors:y?r.errors:{}})},se=(y,O,k)=>{const Z=(Y(n,y,{_f:{}})._f||{}).ref,A=Y(r.errors,y)||{},{ref:j,message:G,type:de,...he}=A;be(r.errors,y,{...he,...O,ref:Z}),m.state.next({name:y,errors:r.errors,isValid:!1}),k&&k.shouldFocus&&Z&&Z.focus&&Z.focus()},ae=(y,O)=>mt(y)?m.state.subscribe({next:k=>y(V(void 0,O),k)}):V(y,O,!0),ee=y=>m.state.subscribe({next:O=>{xc(y.name,O.name,y.exact)&&vc(O,y.formState||u,Se,y.reRenderRoot)&&y.callback({values:{...a},...r,...O})}}).unsubscribe,q=y=>(s.mount=!0,f={...f,...y.formState},ee({...y,formState:f})),te=(y,O={})=>{for(const k of y?on(y):o.mount)o.mount.delete(k),o.array.delete(k),O.keepValue||(Me(n,k),Me(a,k)),!O.keepError&&Me(r.errors,k),!O.keepDirty&&Me(r.dirtyFields,k),!O.keepTouched&&Me(r.touchedFields,k),!O.keepIsValidating&&Me(r.validatingFields,k),!t.shouldUnregister&&!O.keepDefaultValue&&Me(i,k);m.state.next({values:Ve(a)}),m.state.next({...r,...O.keepDirty?{isDirty:R()}:{}}),!O.keepIsValid&&c()},ue=({disabled:y,name:O})=>{(et(y)&&s.mount||y||o.disabled.has(O))&&(y?o.disabled.add(O):o.disabled.delete(O))},M=(y,O={})=>{let k=Y(n,y);const Z=et(O.disabled)||et(t.disabled);return be(n,y,{...k||{},_f:{...k&&k._f?k._f:{ref:{name:y}},name:y,mount:!0,...O}}),o.mount.add(y),k?ue({disabled:et(O.disabled)?O.disabled:t.disabled,name:y}):T(y,!0,O.value),{...Z?{disabled:O.disabled||t.disabled}:{},...t.progressive?{required:!!O.required,min:en(O.min),max:en(O.max),minLength:en(O.minLength),maxLength:en(O.maxLength),pattern:en(O.pattern)}:{},name:y,onChange:ce,onBlur:ce,ref:A=>{if(A){M(y,O),k=Y(n,y);const j=De(A.value)&&A.querySelectorAll&&A.querySelectorAll("input,select,textarea")[0]||A,G=dc(j),de=k._f.refs||[];if(G?de.find(he=>he===j):j===k._f.ref)return;be(n,y,{_f:{...k._f,...G?{refs:[...de.filter(vi),j,...Array.isArray(Y(i,y))?[{}]:[]],ref:{type:j.type,name:y}}:{ref:j}}}),T(y,!1,void 0,j)}else k=Y(n,y,{}),k._f&&(k._f.mount=!1),(t.shouldUnregister||O.shouldUnregister)&&!(Fo(o.array,y)&&s.action)&&o.unMount.add(y)}}},U=()=>t.shouldFocusError&&ln(n,pe,o.mount),re=y=>{et(y)&&(m.state.next({disabled:y}),ln(n,(O,k)=>{const Z=Y(n,k);Z&&(O.disabled=Z._f.disabled||y,Array.isArray(Z._f.refs)&&Z._f.refs.forEach(A=>{A.disabled=Z._f.disabled||y}))},0,!1))},C=(y,O)=>async k=>{let Z;k&&(k.preventDefault&&k.preventDefault(),k.persist&&k.persist());let A=Ve(a);if(m.state.next({isSubmitting:!0}),t.resolver){const{errors:j,values:G}=await X();r.errors=j,A=G}else await W(n);if(o.disabled.size)for(const j of o.disabled)be(A,j,void 0);if(Me(r.errors,"root"),Ge(r.errors)){m.state.next({errors:{}});try{await y(A,k)}catch(j){Z=j}}else O&&await O({...r.errors},k),U(),setTimeout(U);if(m.state.next({isSubmitted:!0,isSubmitting:!1,isSubmitSuccessful:Ge(r.errors)&&!Z,submitCount:r.submitCount+1,errors:r.errors}),Z)throw Z},Q=(y,O={})=>{Y(n,y)&&(De(O.defaultValue)?le(y,Ve(Y(i,y))):(le(y,O.defaultValue),be(i,y,Ve(O.defaultValue))),O.keepTouched||Me(r.touchedFields,y),O.keepDirty||(Me(r.dirtyFields,y),r.isDirty=O.defaultValue?R(y,Ve(Y(i,y))):R()),O.keepError||(Me(r.errors,y),u.isValid&&c()),m.state.next({...r}))},me=(y,O={})=>{const k=y?Ve(y):i,Z=Ve(k),A=Ge(y),j=A?i:Z;if(O.keepDefaultValues||(i=k),!O.keepValues){if(O.keepDirtyValues){const G=new Set([...o.mount,...Object.keys(Jr(i,a))]);for(const de of Array.from(G))Y(r.dirtyFields,de)?be(j,de,Y(a,de)):le(de,Y(j,de))}else{if(da&&De(y))for(const G of o.mount){const de=Y(n,G);if(de&&de._f){const he=Array.isArray(de._f.refs)?de._f.refs[0]:de._f.ref;if(Ln(he)){const ze=he.closest("form");if(ze){ze.reset();break}}}}for(const G of o.mount)le(G,Y(j,G))}a=Ve(j),m.array.next({values:{...j}}),m.state.next({values:{...j}})}o={mount:O.keepDirtyValues?o.mount:new Set,unMount:new Set,array:new Set,disabled:new Set,watch:new Set,watchAll:!1,focus:""},s.mount=!u.isValid||!!O.keepIsValid||!!O.keepDirtyValues,s.watch=!!t.shouldUnregister,m.state.next({submitCount:O.keepSubmitCount?r.submitCount:0,isDirty:A?!1:O.keepDirty?r.isDirty:!!(O.keepDefaultValues&&!zt(y,i)),isSubmitted:O.keepIsSubmitted?r.isSubmitted:!1,dirtyFields:A?{}:O.keepDirtyValues?O.keepDefaultValues&&a?Jr(i,a):r.dirtyFields:O.keepDefaultValues&&y?Jr(i,y):O.keepDirty?r.dirtyFields:{},touchedFields:O.keepTouched?r.touchedFields:{},errors:O.keepErrors?r.errors:{},isSubmitSuccessful:O.keepIsSubmitSuccessful?r.isSubmitSuccessful:!1,isSubmitting:!1})},Te=(y,O)=>me(mt(y)?y(a):y,O),Be=(y,O={})=>{const k=Y(n,y),Z=k&&k._f;if(Z){const A=Z.refs?Z.refs[0]:Z.ref;A.focus&&(A.focus(),O.shouldSelect&&mt(A.select)&&A.select())}},Se=y=>{r={...r,...y}},Je={control:{register:M,unregister:te,getFieldState:L,handleSubmit:C,setError:se,_subscribe:ee,_runSchema:X,_focusError:U,_getWatch:V,_getDirty:R,_setValid:c,_setFieldArray:h,_setDisabledField:ue,_setErrors:$,_getFieldArray:B,_reset:me,_resetDefaultValues:()=>mt(t.defaultValues)&&t.defaultValues().then(y=>{Te(y,t.resetOptions),m.state.next({isLoading:!1})}),_removeUnmounted:p,_disableForm:re,_subjects:m,_proxyFormState:u,get _fields(){return n},get _formValues(){return a},get _state(){return s},set _state(y){s=y},get _defaultValues(){return i},get _names(){return o},set _names(y){o=y},get _formState(){return r},get _options(){return t},set _options(y){t={...t,...y}}},subscribe:q,trigger:oe,register:M,handleSubmit:C,watch:ae,setValue:le,getValues:N,reset:Te,resetField:Q,clearErrors:K,unregister:te,setError:se,setFocus:Be,getFieldState:L};return{...Je,formControl:Je}}function Tc(e={}){const t=I.useRef(void 0),r=I.useRef(void 0),[n,i]=I.useState({isDirty:!1,isValidating:!1,isLoading:mt(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:mt(e.defaultValues)?void 0:e.defaultValues});if(!t.current)if(e.formControl)t.current={...e.formControl,formState:n},e.defaultValues&&!mt(e.defaultValues)&&e.formControl.reset(e.defaultValues,e.resetOptions);else{const{formControl:s,...o}=Cc(e);t.current={...o,formState:n}}const a=t.current.control;return a._options=e,ya(()=>{const s=a._subscribe({formState:a._proxyFormState,callback:()=>i({...a._formState}),reRenderRoot:!0});return i(o=>({...o,isReady:!0})),a._formState.isReady=!0,s},[a]),I.useEffect(()=>a._disableForm(e.disabled),[a,e.disabled]),I.useEffect(()=>{e.mode&&(a._options.mode=e.mode),e.reValidateMode&&(a._options.reValidateMode=e.reValidateMode)},[a,e.mode,e.reValidateMode]),I.useEffect(()=>{e.errors&&(a._setErrors(e.errors),a._focusError())},[a,e.errors]),I.useEffect(()=>{e.shouldUnregister&&a._subjects.state.next({values:a._getWatch()})},[a,e.shouldUnregister]),I.useEffect(()=>{if(a._proxyFormState.isDirty){const s=a._getDirty();s!==n.isDirty&&a._subjects.state.next({isDirty:s})}},[a,n.isDirty]),I.useEffect(()=>{e.values&&!zt(e.values,r.current)?(a._reset(e.values,a._options.resetOptions),r.current=e.values,i(s=>({...s}))):a._resetDefaultValues()},[a,e.values]),I.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=Ro(n,a),t.current}const Za=(e,t,r)=>{if(e&&"reportValidity"in e){const n=Y(r,t);e.setCustomValidity(n&&n.message||""),e.reportValidity()}},Bo=(e,t)=>{for(const r in t.fields){const n=t.fields[r];n&&n.ref&&"reportValidity"in n.ref?Za(n.ref,r,e):n&&n.refs&&n.refs.forEach(i=>Za(i,r,e))}},kc=(e,t)=>{t.shouldUseNativeValidation&&Bo(e,t);const r={};for(const n in e){const i=Y(t.fields,n),a=Object.assign(e[n]||{},{ref:i&&i.ref});if(Oc(t.names||Object.keys(e),n)){const s=Object.assign({},Y(r,n));be(s,"root",a),be(r,n,s)}else be(r,n,a)}return r},Oc=(e,t)=>{const r=Xa(t);return e.some(n=>Xa(n).match(`^${r}\\.\\d+`))};function Xa(e){return e.replace(/\]|\[/g,"")}function _c(e,t,r){return r===void 0&&(r={}),function(n,i,a){try{return Promise.resolve(function(s,o){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(d){return a.shouldUseNativeValidation&&Bo({},a),{values:r.raw?Object.assign({},n):d,errors:{}}}))}catch(d){return o(d)}return l&&l.then?l.then(void 0,o):l}(0,function(s){if(!s.inner)throw s;return{values:{},errors:kc((o=s,l=!a.shouldUseNativeValidation&&a.criteriaMode==="all",(o.inner||[]).reduce(function(d,u){if(d[u.path]||(d[u.path]={message:u.message,type:u.type}),l){var f=d[u.path].types,m=f&&f[u.type];d[u.path]=Do(u.path,l,d,u.type,m?[].concat(m,u.message):u.message)}return d},{})),a)};var o,l}))}catch(s){return Promise.reject(s)}}}var xn=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(){}},yr=typeof window>"u"||"Deno"in globalThis;function Ze(){}function Ac(e,t){return typeof e=="function"?e(t):e}function Ii(e){return typeof e=="number"&&e>=0&&e!==1/0}function Lo(e,t){return Math.max(e+(t||0)-Date.now(),0)}function Qt(e,t){return typeof e=="function"?e(t):e}function st(e,t){return typeof e=="function"?e(t):e}function Ja(e,t){const{type:r="all",exact:n,fetchStatus:i,predicate:a,queryKey:s,stale:o}=e;if(s){if(n){if(t.queryHash!==xa(s,t.options))return!1}else if(!pn(t.queryKey,s))return!1}if(r!=="all"){const l=t.isActive();if(r==="active"&&!l||r==="inactive"&&l)return!1}return!(typeof o=="boolean"&&t.isStale()!==o||i&&i!==t.state.fetchStatus||a&&!a(t))}function es(e,t){const{exact:r,status:n,predicate:i,mutationKey:a}=e;if(a){if(!t.options.mutationKey)return!1;if(r){if(un(t.options.mutationKey)!==un(a))return!1}else if(!pn(t.options.mutationKey,a))return!1}return!(n&&t.state.status!==n||i&&!i(t))}function xa(e,t){return((t==null?void 0:t.queryKeyHashFn)||un)(e)}function un(e){return JSON.stringify(e,(t,r)=>Vi(r)?Object.keys(r).sort().reduce((n,i)=>(n[i]=r[i],n),{}):r)}function pn(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?Object.keys(t).every(r=>pn(e[r],t[r])):!1}function Mi(e,t){if(e===t)return e;const r=ts(e)&&ts(t);if(r||Vi(e)&&Vi(t)){const n=r?e:Object.keys(e),i=n.length,a=r?t:Object.keys(t),s=a.length,o=r?[]:{},l=new Set(n);let d=0;for(let u=0;u<s;u++){const f=r?u:a[u];(!r&&l.has(f)||r)&&e[f]===void 0&&t[f]===void 0?(o[f]=void 0,d++):(o[f]=Mi(e[f],t[f]),o[f]===e[f]&&e[f]!==void 0&&d++)}return i===s&&d===i?e:o}return t}function zi(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 ts(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function Vi(e){if(!rs(e))return!1;const t=e.constructor;if(t===void 0)return!0;const r=t.prototype;return!(!rs(r)||!r.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function rs(e){return Object.prototype.toString.call(e)==="[object Object]"}function Fc(e){return new Promise(t=>{setTimeout(t,e)})}function Ni(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 Mi(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 Mi(e,t)}return t}function jc(e,t,r=0){const n=[...e,t];return r&&n.length>r?n.slice(1):n}function Rc(e,t,r=0){const n=[t,...e];return r&&n.length>r?n.slice(0,-1):n}var Wn=Symbol();function qo(e,t){return process.env.NODE_ENV!=="production"&&e.queryFn===Wn&&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===Wn?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}function $c(e,t){return typeof e=="function"?e(...t):!!e}var sr,Vt,Dr,xo,Dc=(xo=class extends xn{constructor(){super();fe(this,sr);fe(this,Vt);fe(this,Dr);ne(this,Dr,t=>{if(!yr&&window.addEventListener){const r=()=>t();return window.addEventListener("visibilitychange",r,!1),()=>{window.removeEventListener("visibilitychange",r)}}})}onSubscribe(){b(this,Vt)||this.setEventListener(b(this,Dr))}onUnsubscribe(){var t;this.hasListeners()||((t=b(this,Vt))==null||t.call(this),ne(this,Vt,void 0))}setEventListener(t){var r;ne(this,Dr,t),(r=b(this,Vt))==null||r.call(this),ne(this,Vt,t(n=>{typeof n=="boolean"?this.setFocused(n):this.onFocus()}))}setFocused(t){b(this,sr)!==t&&(ne(this,sr,t),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(r=>{r(t)})}isFocused(){var t;return typeof b(this,sr)=="boolean"?b(this,sr):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},sr=new WeakMap,Vt=new WeakMap,Dr=new WeakMap,xo),ba=new Dc,Pr,Nt,Ir,bo,Pc=(bo=class extends xn{constructor(){super();fe(this,Pr,!0);fe(this,Nt);fe(this,Ir);ne(this,Ir,t=>{if(!yr&&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(){b(this,Nt)||this.setEventListener(b(this,Ir))}onUnsubscribe(){var t;this.hasListeners()||((t=b(this,Nt))==null||t.call(this),ne(this,Nt,void 0))}setEventListener(t){var r;ne(this,Ir,t),(r=b(this,Nt))==null||r.call(this),ne(this,Nt,t(this.setOnline.bind(this)))}setOnline(t){b(this,Pr)!==t&&(ne(this,Pr,t),this.listeners.forEach(n=>{n(t)}))}isOnline(){return b(this,Pr)}},Pr=new WeakMap,Nt=new WeakMap,Ir=new WeakMap,bo),Hn=new Pc;function Bi(){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 Ic(e){return Math.min(1e3*2**e,3e4)}function Uo(e){return(e??"online")==="online"?Hn.isOnline():!0}var Wo=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function xi(e){return e instanceof Wo}function Ho(e){let t=!1,r=0,n=!1,i;const a=Bi(),s=c=>{var E;n||(m(new Wo(c)),(E=e.abort)==null||E.call(e))},o=()=>{t=!0},l=()=>{t=!1},d=()=>ba.isFocused()&&(e.networkMode==="always"||Hn.isOnline())&&e.canRun(),u=()=>Uo(e.networkMode)&&e.canRun(),f=c=>{var E;n||(n=!0,(E=e.onSuccess)==null||E.call(e,c),i==null||i(),a.resolve(c))},m=c=>{var E;n||(n=!0,(E=e.onError)==null||E.call(e,c),i==null||i(),a.reject(c))},x=()=>new Promise(c=>{var E;i=h=>{(n||d())&&c(h)},(E=e.onPause)==null||E.call(e)}).then(()=>{var c;i=void 0,n||(c=e.onContinue)==null||c.call(e)}),S=()=>{if(n)return;let c;const E=r===0?e.initialPromise:void 0;try{c=E??e.fn()}catch(h){c=Promise.reject(h)}Promise.resolve(c).then(f).catch(h=>{var F;if(n)return;const _=e.retry??(yr?0:3),$=e.retryDelay??Ic,T=typeof $=="function"?$(r,h):$,w=_===!0||typeof _=="number"&&r<_||typeof _=="function"&&_(r,h);if(t||!w){m(h);return}r++,(F=e.onFail)==null||F.call(e,r,h),Fc(T).then(()=>d()?void 0:x()).then(()=>{t?m(h):S()})})};return{promise:a,cancel:s,continue:()=>(i==null||i(),a),cancelRetry:o,continueRetry:l,canStart:u,start:()=>(u()?S():x().then(S),a)}}var Mc=e=>setTimeout(e,0);function zc(){let e=[],t=0,r=o=>{o()},n=o=>{o()},i=Mc;const a=o=>{t?e.push(o):i(()=>{r(o)})},s=()=>{const o=e;e=[],o.length&&i(()=>{n(()=>{o.forEach(l=>{r(l)})})})};return{batch:o=>{let l;t++;try{l=o()}finally{t--,t||s()}return l},batchCalls:o=>(...l)=>{a(()=>{o(...l)})},schedule:a,setNotifyFunction:o=>{r=o},setBatchNotifyFunction:o=>{n=o},setScheduler:o=>{i=o}}}var Ne=zc(),or,wo,Ko=(wo=class{constructor(){fe(this,or)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),Ii(this.gcTime)&&ne(this,or,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(yr?1/0:5*60*1e3))}clearGcTimeout(){b(this,or)&&(clearTimeout(b(this,or)),ne(this,or,void 0))}},or=new WeakMap,wo),Mr,lr,at,cr,Le,mn,ur,pt,jt,So,Vc=(So=class extends Ko{constructor(t){super();fe(this,pt);fe(this,Mr);fe(this,lr);fe(this,at);fe(this,cr);fe(this,Le);fe(this,mn);fe(this,ur);ne(this,ur,!1),ne(this,mn,t.defaultOptions),this.setOptions(t.options),this.observers=[],ne(this,cr,t.client),ne(this,at,b(this,cr).getQueryCache()),this.queryKey=t.queryKey,this.queryHash=t.queryHash,ne(this,Mr,Nc(this.options)),this.state=t.state??b(this,Mr),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return(t=b(this,Le))==null?void 0:t.promise}setOptions(t){this.options={...b(this,mn),...t},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&b(this,at).remove(this)}setData(t,r){const n=Ni(this.state.data,t,this.options);return ye(this,pt,jt).call(this,{data:n,type:"success",dataUpdatedAt:r==null?void 0:r.updatedAt,manual:r==null?void 0:r.manual}),n}setState(t,r){ye(this,pt,jt).call(this,{type:"setState",state:t,setStateOptions:r})}cancel(t){var n,i;const r=(n=b(this,Le))==null?void 0:n.promise;return(i=b(this,Le))==null||i.cancel(t),r?r.then(Ze).catch(Ze):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(b(this,Mr))}isActive(){return this.observers.some(t=>st(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===Wn||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStatic(){return this.getObserversCount()>0?this.observers.some(t=>Qt(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:!Lo(this.state.dataUpdatedAt,t)}onFocus(){var r;const t=this.observers.find(n=>n.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(r=b(this,Le))==null||r.continue()}onOnline(){var r;const t=this.observers.find(n=>n.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(r=b(this,Le))==null||r.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),b(this,at).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(r=>r!==t),this.observers.length||(b(this,Le)&&(b(this,ur)?b(this,Le).cancel({revert:!0}):b(this,Le).cancelRetry()),this.scheduleGc()),b(this,at).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||ye(this,pt,jt).call(this,{type:"invalidate"})}fetch(t,r){var d,u,f;if(this.state.fetchStatus!=="idle"){if(this.state.data!==void 0&&(r!=null&&r.cancelRefetch))this.cancel({silent:!0});else if(b(this,Le))return b(this,Le).continueRetry(),b(this,Le).promise}if(t&&this.setOptions(t),!this.options.queryFn){const m=this.observers.find(x=>x.options.queryFn);m&&this.setOptions(m.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=m=>{Object.defineProperty(m,"signal",{enumerable:!0,get:()=>(ne(this,ur,!0),n.signal)})},a=()=>{const m=qo(this.options,r),S=(()=>{const c={client:b(this,cr),queryKey:this.queryKey,meta:this.meta};return i(c),c})();return ne(this,ur,!1),this.options.persister?this.options.persister(m,S,this):m(S)},o=(()=>{const m={fetchOptions:r,options:this.options,queryKey:this.queryKey,client:b(this,cr),state:this.state,fetchFn:a};return i(m),m})();(d=this.options.behavior)==null||d.onFetch(o,this),ne(this,lr,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((u=o.fetchOptions)==null?void 0:u.meta))&&ye(this,pt,jt).call(this,{type:"fetch",meta:(f=o.fetchOptions)==null?void 0:f.meta});const l=m=>{var x,S,c,E;xi(m)&&m.silent||ye(this,pt,jt).call(this,{type:"error",error:m}),xi(m)||((S=(x=b(this,at).config).onError)==null||S.call(x,m,this),(E=(c=b(this,at).config).onSettled)==null||E.call(c,this.state.data,m,this)),this.scheduleGc()};return ne(this,Le,Ho({initialPromise:r==null?void 0:r.initialPromise,fn:o.fetchFn,abort:n.abort.bind(n),onSuccess:m=>{var x,S,c,E;if(m===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(m)}catch(h){l(h);return}(S=(x=b(this,at).config).onSuccess)==null||S.call(x,m,this),(E=(c=b(this,at).config).onSettled)==null||E.call(c,m,this.state.error,this),this.scheduleGc()},onError:l,onFail:(m,x)=>{ye(this,pt,jt).call(this,{type:"failed",failureCount:m,error:x})},onPause:()=>{ye(this,pt,jt).call(this,{type:"pause"})},onContinue:()=>{ye(this,pt,jt).call(this,{type:"continue"})},retry:o.options.retry,retryDelay:o.options.retryDelay,networkMode:o.options.networkMode,canRun:()=>!0})),b(this,Le).start()}},Mr=new WeakMap,lr=new WeakMap,at=new WeakMap,cr=new WeakMap,Le=new WeakMap,mn=new WeakMap,ur=new WeakMap,pt=new WeakSet,jt=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,...Qo(n.data,this.options),fetchMeta:t.meta??null};case"success":return ne(this,lr,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 xi(i)&&i.revert&&b(this,lr)?{...b(this,lr),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),Ne.batch(()=>{this.observers.forEach(n=>{n.onQueryUpdate()}),b(this,at).notify({query:this,type:"updated",action:t})})},So);function Qo(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:Uo(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function Nc(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 wt,Eo,Bc=(Eo=class extends xn{constructor(t={}){super();fe(this,wt);this.config=t,ne(this,wt,new Map)}build(t,r,n){const i=r.queryKey,a=r.queryHash??xa(i,r);let s=this.get(a);return s||(s=new Vc({client:t,queryKey:i,queryHash:a,options:t.defaultQueryOptions(r),state:n,defaultOptions:t.getQueryDefaults(i)}),this.add(s)),s}add(t){b(this,wt).has(t.queryHash)||(b(this,wt).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const r=b(this,wt).get(t.queryHash);r&&(t.destroy(),r===t&&b(this,wt).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){Ne.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return b(this,wt).get(t)}getAll(){return[...b(this,wt).values()]}find(t){const r={exact:!0,...t};return this.getAll().find(n=>Ja(r,n))}findAll(t={}){const r=this.getAll();return Object.keys(t).length>0?r.filter(n=>Ja(t,n)):r}notify(t){Ne.batch(()=>{this.listeners.forEach(r=>{r(t)})})}onFocus(){Ne.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){Ne.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},wt=new WeakMap,Eo),St,Ue,pr,Et,It,Co,Lc=(Co=class extends Ko{constructor(t){super();fe(this,Et);fe(this,St);fe(this,Ue);fe(this,pr);this.mutationId=t.mutationId,ne(this,Ue,t.mutationCache),ne(this,St,[]),this.state=t.state||qc(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){b(this,St).includes(t)||(b(this,St).push(t),this.clearGcTimeout(),b(this,Ue).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){ne(this,St,b(this,St).filter(r=>r!==t)),this.scheduleGc(),b(this,Ue).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){b(this,St).length||(this.state.status==="pending"?this.scheduleGc():b(this,Ue).remove(this))}continue(){var t;return((t=b(this,pr))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var a,s,o,l,d,u,f,m,x,S,c,E,h,_,$,T,w,F,X,J;const r=()=>{ye(this,Et,It).call(this,{type:"continue"})};ne(this,pr,Ho({fn:()=>this.options.mutationFn?this.options.mutationFn(t):Promise.reject(new Error("No mutationFn found")),onFail:(W,p)=>{ye(this,Et,It).call(this,{type:"failed",failureCount:W,error:p})},onPause:()=>{ye(this,Et,It).call(this,{type:"pause"})},onContinue:r,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>b(this,Ue).canRun(this)}));const n=this.state.status==="pending",i=!b(this,pr).canStart();try{if(n)r();else{ye(this,Et,It).call(this,{type:"pending",variables:t,isPaused:i}),await((s=(a=b(this,Ue).config).onMutate)==null?void 0:s.call(a,t,this));const p=await((l=(o=this.options).onMutate)==null?void 0:l.call(o,t));p!==this.state.context&&ye(this,Et,It).call(this,{type:"pending",context:p,variables:t,isPaused:i})}const W=await b(this,pr).start();return await((u=(d=b(this,Ue).config).onSuccess)==null?void 0:u.call(d,W,t,this.state.context,this)),await((m=(f=this.options).onSuccess)==null?void 0:m.call(f,W,t,this.state.context)),await((S=(x=b(this,Ue).config).onSettled)==null?void 0:S.call(x,W,null,this.state.variables,this.state.context,this)),await((E=(c=this.options).onSettled)==null?void 0:E.call(c,W,null,t,this.state.context)),ye(this,Et,It).call(this,{type:"success",data:W}),W}catch(W){try{throw await((_=(h=b(this,Ue).config).onError)==null?void 0:_.call(h,W,t,this.state.context,this)),await((T=($=this.options).onError)==null?void 0:T.call($,W,t,this.state.context)),await((F=(w=b(this,Ue).config).onSettled)==null?void 0:F.call(w,void 0,W,this.state.variables,this.state.context,this)),await((J=(X=this.options).onSettled)==null?void 0:J.call(X,void 0,W,t,this.state.context)),W}finally{ye(this,Et,It).call(this,{type:"error",error:W})}}finally{b(this,Ue).runNext(this)}}},St=new WeakMap,Ue=new WeakMap,pr=new WeakMap,Et=new WeakSet,It=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),Ne.batch(()=>{b(this,St).forEach(n=>{n.onMutationUpdate(t)}),b(this,Ue).notify({mutation:this,type:"updated",action:t})})},Co);function qc(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var Rt,dt,hn,To,Uc=(To=class extends xn{constructor(t={}){super();fe(this,Rt);fe(this,dt);fe(this,hn);this.config=t,ne(this,Rt,new Set),ne(this,dt,new Map),ne(this,hn,0)}build(t,r,n){const i=new Lc({mutationCache:this,mutationId:++Cn(this,hn)._,options:t.defaultMutationOptions(r),state:n});return this.add(i),i}add(t){b(this,Rt).add(t);const r=Tn(t);if(typeof r=="string"){const n=b(this,dt).get(r);n?n.push(t):b(this,dt).set(r,[t])}this.notify({type:"added",mutation:t})}remove(t){if(b(this,Rt).delete(t)){const r=Tn(t);if(typeof r=="string"){const n=b(this,dt).get(r);if(n)if(n.length>1){const i=n.indexOf(t);i!==-1&&n.splice(i,1)}else n[0]===t&&b(this,dt).delete(r)}}this.notify({type:"removed",mutation:t})}canRun(t){const r=Tn(t);if(typeof r=="string"){const n=b(this,dt).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=Tn(t);if(typeof r=="string"){const i=(n=b(this,dt).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(){Ne.batch(()=>{b(this,Rt).forEach(t=>{this.notify({type:"removed",mutation:t})}),b(this,Rt).clear(),b(this,dt).clear()})}getAll(){return Array.from(b(this,Rt))}find(t){const r={exact:!0,...t};return this.getAll().find(n=>es(r,n))}findAll(t={}){return this.getAll().filter(r=>es(t,r))}notify(t){Ne.batch(()=>{this.listeners.forEach(r=>{r(t)})})}resumePausedMutations(){const t=this.getAll().filter(r=>r.state.isPaused);return Ne.batch(()=>Promise.all(t.map(r=>r.continue().catch(Ze))))}},Rt=new WeakMap,dt=new WeakMap,hn=new WeakMap,To);function Tn(e){var t;return(t=e.options.scope)==null?void 0:t.id}function ns(e){return{onFetch:(t,r)=>{var u,f,m,x,S;const n=t.options,i=(m=(f=(u=t.fetchOptions)==null?void 0:u.meta)==null?void 0:f.fetchMore)==null?void 0:m.direction,a=((x=t.state.data)==null?void 0:x.pages)||[],s=((S=t.state.data)==null?void 0:S.pageParams)||[];let o={pages:[],pageParams:[]},l=0;const d=async()=>{let c=!1;const E=$=>{Object.defineProperty($,"signal",{enumerable:!0,get:()=>(t.signal.aborted?c=!0:t.signal.addEventListener("abort",()=>{c=!0}),t.signal)})},h=qo(t.options,t.fetchOptions),_=async($,T,w)=>{if(c)return Promise.reject();if(T==null&&$.pages.length)return Promise.resolve($);const X=(()=>{const R={client:t.client,queryKey:t.queryKey,pageParam:T,direction:w?"backward":"forward",meta:t.options.meta};return E(R),R})(),J=await h(X),{maxPages:W}=t.options,p=w?Rc:jc;return{pages:p($.pages,J,W),pageParams:p($.pageParams,T,W)}};if(i&&a.length){const $=i==="backward",T=$?Wc:is,w={pages:a,pageParams:s},F=T(n,w);o=await _(w,F,$)}else{const $=e??a.length;do{const T=l===0?s[0]??n.initialPageParam:is(n,o);if(l>0&&T==null)break;o=await _(o,T),l++}while(l<$)}return o};t.options.persister?t.fetchFn=()=>{var c,E;return(E=(c=t.options).persister)==null?void 0:E.call(c,d,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},r)}:t.fetchFn=d}}}function is(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 Wc(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 $e,Bt,Lt,zr,Vr,qt,Nr,Br,ko,Hc=(ko=class{constructor(e={}){fe(this,$e);fe(this,Bt);fe(this,Lt);fe(this,zr);fe(this,Vr);fe(this,qt);fe(this,Nr);fe(this,Br);ne(this,$e,e.queryCache||new Bc),ne(this,Bt,e.mutationCache||new Uc),ne(this,Lt,e.defaultOptions||{}),ne(this,zr,new Map),ne(this,Vr,new Map),ne(this,qt,0)}mount(){Cn(this,qt)._++,b(this,qt)===1&&(ne(this,Nr,ba.subscribe(async e=>{e&&(await this.resumePausedMutations(),b(this,$e).onFocus())})),ne(this,Br,Hn.subscribe(async e=>{e&&(await this.resumePausedMutations(),b(this,$e).onOnline())})))}unmount(){var e,t;Cn(this,qt)._--,b(this,qt)===0&&((e=b(this,Nr))==null||e.call(this),ne(this,Nr,void 0),(t=b(this,Br))==null||t.call(this),ne(this,Br,void 0))}isFetching(e){return b(this,$e).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return b(this,Bt).findAll({...e,status:"pending"}).length}getQueryData(e){var r;const t=this.defaultQueryOptions({queryKey:e});return(r=b(this,$e).get(t.queryHash))==null?void 0:r.state.data}ensureQueryData(e){const t=this.defaultQueryOptions(e),r=b(this,$e).build(this,t),n=r.state.data;return n===void 0?this.fetchQuery(e):(e.revalidateIfStale&&r.isStaleByTime(Qt(t.staleTime,r))&&this.prefetchQuery(t),Promise.resolve(n))}getQueriesData(e){return b(this,$e).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=b(this,$e).get(n.queryHash),a=i==null?void 0:i.state.data,s=Ac(t,a);if(s!==void 0)return b(this,$e).build(this,n).setData(s,{...r,manual:!0})}setQueriesData(e,t,r){return Ne.batch(()=>b(this,$e).findAll(e).map(({queryKey:n})=>[n,this.setQueryData(n,t,r)]))}getQueryState(e){var r;const t=this.defaultQueryOptions({queryKey:e});return(r=b(this,$e).get(t.queryHash))==null?void 0:r.state}removeQueries(e){const t=b(this,$e);Ne.batch(()=>{t.findAll(e).forEach(r=>{t.remove(r)})})}resetQueries(e,t){const r=b(this,$e);return Ne.batch(()=>(r.findAll(e).forEach(n=>{n.reset()}),this.refetchQueries({type:"active",...e},t)))}cancelQueries(e,t={}){const r={revert:!0,...t},n=Ne.batch(()=>b(this,$e).findAll(e).map(i=>i.cancel(r)));return Promise.all(n).then(Ze).catch(Ze)}invalidateQueries(e,t={}){return Ne.batch(()=>(b(this,$e).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=Ne.batch(()=>b(this,$e).findAll(e).filter(i=>!i.isDisabled()&&!i.isStatic()).map(i=>{let a=i.fetch(void 0,r);return r.throwOnError||(a=a.catch(Ze)),i.state.fetchStatus==="paused"?Promise.resolve():a}));return Promise.all(n).then(Ze)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const r=b(this,$e).build(this,t);return r.isStaleByTime(Qt(t.staleTime,r))?r.fetch(t):Promise.resolve(r.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(Ze).catch(Ze)}fetchInfiniteQuery(e){return e.behavior=ns(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(Ze).catch(Ze)}ensureInfiniteQueryData(e){return e.behavior=ns(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return Hn.isOnline()?b(this,Bt).resumePausedMutations():Promise.resolve()}getQueryCache(){return b(this,$e)}getMutationCache(){return b(this,Bt)}getDefaultOptions(){return b(this,Lt)}setDefaultOptions(e){ne(this,Lt,e)}setQueryDefaults(e,t){b(this,zr).set(un(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...b(this,zr).values()],r={};return t.forEach(n=>{pn(e,n.queryKey)&&Object.assign(r,n.defaultOptions)}),r}setMutationDefaults(e,t){b(this,Vr).set(un(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...b(this,Vr).values()],r={};return t.forEach(n=>{pn(e,n.mutationKey)&&Object.assign(r,n.defaultOptions)}),r}defaultQueryOptions(e){if(e._defaulted)return e;const t={...b(this,Lt).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=xa(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===Wn&&(t.enabled=!1),t}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...b(this,Lt).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){b(this,$e).clear(),b(this,Bt).clear()}},$e=new WeakMap,Bt=new WeakMap,Lt=new WeakMap,zr=new WeakMap,Vr=new WeakMap,qt=new WeakMap,Nr=new WeakMap,Br=new WeakMap,ko),Ye,ge,yn,We,dr,Lr,Ut,Wt,gn,qr,Ur,fr,mr,Ht,Wr,we,rn,Li,qi,Ui,Wi,Hi,Ki,Qi,Yo,Oo,Kc=(Oo=class extends xn{constructor(t,r){super();fe(this,we);fe(this,Ye);fe(this,ge);fe(this,yn);fe(this,We);fe(this,dr);fe(this,Lr);fe(this,Ut);fe(this,Wt);fe(this,gn);fe(this,qr);fe(this,Ur);fe(this,fr);fe(this,mr);fe(this,Ht);fe(this,Wr,new Set);this.options=r,ne(this,Ye,t),ne(this,Wt,null),ne(this,Ut,Bi()),this.options.experimental_prefetchInRender||b(this,Ut).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&&(b(this,ge).addObserver(this),as(b(this,ge),this.options)?ye(this,we,rn).call(this):this.updateResult(),ye(this,we,Wi).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return Yi(b(this,ge),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return Yi(b(this,ge),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,ye(this,we,Hi).call(this),ye(this,we,Ki).call(this),b(this,ge).removeObserver(this)}setOptions(t){const r=this.options,n=b(this,ge);if(this.options=b(this,Ye).defaultQueryOptions(t),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof st(this.options.enabled,b(this,ge))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");ye(this,we,Qi).call(this),b(this,ge).setOptions(this.options),r._defaulted&&!zi(this.options,r)&&b(this,Ye).getQueryCache().notify({type:"observerOptionsUpdated",query:b(this,ge),observer:this});const i=this.hasListeners();i&&ss(b(this,ge),n,this.options,r)&&ye(this,we,rn).call(this),this.updateResult(),i&&(b(this,ge)!==n||st(this.options.enabled,b(this,ge))!==st(r.enabled,b(this,ge))||Qt(this.options.staleTime,b(this,ge))!==Qt(r.staleTime,b(this,ge)))&&ye(this,we,Li).call(this);const a=ye(this,we,qi).call(this);i&&(b(this,ge)!==n||st(this.options.enabled,b(this,ge))!==st(r.enabled,b(this,ge))||a!==b(this,Ht))&&ye(this,we,Ui).call(this,a)}getOptimisticResult(t){const r=b(this,Ye).getQueryCache().build(b(this,Ye),t),n=this.createResult(r,t);return Yc(this,n)&&(ne(this,We,n),ne(this,Lr,this.options),ne(this,dr,b(this,ge).state)),n}getCurrentResult(){return b(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){b(this,Wr).add(t)}getCurrentQuery(){return b(this,ge)}refetch({...t}={}){return this.fetch({...t})}fetchOptimistic(t){const r=b(this,Ye).defaultQueryOptions(t),n=b(this,Ye).getQueryCache().build(b(this,Ye),r);return n.fetch().then(()=>this.createResult(n,r))}fetch(t){return ye(this,we,rn).call(this,{...t,cancelRefetch:t.cancelRefetch??!0}).then(()=>(this.updateResult(),b(this,We)))}createResult(t,r){var W;const n=b(this,ge),i=this.options,a=b(this,We),s=b(this,dr),o=b(this,Lr),d=t!==n?t.state:b(this,yn),{state:u}=t;let f={...u},m=!1,x;if(r._optimisticResults){const p=this.hasListeners(),R=!p&&as(t,r),V=p&&ss(t,n,r,i);(R||V)&&(f={...f,...Qo(u.data,t.options)}),r._optimisticResults==="isRestoring"&&(f.fetchStatus="idle")}let{error:S,errorUpdatedAt:c,status:E}=f;x=f.data;let h=!1;if(r.placeholderData!==void 0&&x===void 0&&E==="pending"){let p;a!=null&&a.isPlaceholderData&&r.placeholderData===(o==null?void 0:o.placeholderData)?(p=a.data,h=!0):p=typeof r.placeholderData=="function"?r.placeholderData((W=b(this,Ur))==null?void 0:W.state.data,b(this,Ur)):r.placeholderData,p!==void 0&&(E="success",x=Ni(a==null?void 0:a.data,p,r),m=!0)}if(r.select&&x!==void 0&&!h)if(a&&x===(s==null?void 0:s.data)&&r.select===b(this,gn))x=b(this,qr);else try{ne(this,gn,r.select),x=r.select(x),x=Ni(a==null?void 0:a.data,x,r),ne(this,qr,x),ne(this,Wt,null)}catch(p){ne(this,Wt,p)}b(this,Wt)&&(S=b(this,Wt),x=b(this,qr),c=Date.now(),E="error");const _=f.fetchStatus==="fetching",$=E==="pending",T=E==="error",w=$&&_,F=x!==void 0,J={status:E,fetchStatus:f.fetchStatus,isPending:$,isSuccess:E==="success",isError:T,isInitialLoading:w,isLoading:w,data:x,dataUpdatedAt:f.dataUpdatedAt,error:S,errorUpdatedAt:c,failureCount:f.fetchFailureCount,failureReason:f.fetchFailureReason,errorUpdateCount:f.errorUpdateCount,isFetched:f.dataUpdateCount>0||f.errorUpdateCount>0,isFetchedAfterMount:f.dataUpdateCount>d.dataUpdateCount||f.errorUpdateCount>d.errorUpdateCount,isFetching:_,isRefetching:_&&!$,isLoadingError:T&&!F,isPaused:f.fetchStatus==="paused",isPlaceholderData:m,isRefetchError:T&&F,isStale:wa(t,r),refetch:this.refetch,promise:b(this,Ut),isEnabled:st(r.enabled,t)!==!1};if(this.options.experimental_prefetchInRender){const p=B=>{J.status==="error"?B.reject(J.error):J.data!==void 0&&B.resolve(J.data)},R=()=>{const B=ne(this,Ut,J.promise=Bi());p(B)},V=b(this,Ut);switch(V.status){case"pending":t.queryHash===n.queryHash&&p(V);break;case"fulfilled":(J.status==="error"||J.data!==V.value)&&R();break;case"rejected":(J.status!=="error"||J.error!==V.reason)&&R();break}}return J}updateResult(){const t=b(this,We),r=this.createResult(b(this,ge),this.options);if(ne(this,dr,b(this,ge).state),ne(this,Lr,this.options),b(this,dr).data!==void 0&&ne(this,Ur,b(this,ge)),zi(r,t))return;ne(this,We,r);const n=()=>{if(!t)return!0;const{notifyOnChangeProps:i}=this.options,a=typeof i=="function"?i():i;if(a==="all"||!a&&!b(this,Wr).size)return!0;const s=new Set(a??b(this,Wr));return this.options.throwOnError&&s.add("error"),Object.keys(b(this,We)).some(o=>{const l=o;return b(this,We)[l]!==t[l]&&s.has(l)})};ye(this,we,Yo).call(this,{listeners:n()})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&ye(this,we,Wi).call(this)}},Ye=new WeakMap,ge=new WeakMap,yn=new WeakMap,We=new WeakMap,dr=new WeakMap,Lr=new WeakMap,Ut=new WeakMap,Wt=new WeakMap,gn=new WeakMap,qr=new WeakMap,Ur=new WeakMap,fr=new WeakMap,mr=new WeakMap,Ht=new WeakMap,Wr=new WeakMap,we=new WeakSet,rn=function(t){ye(this,we,Qi).call(this);let r=b(this,ge).fetch(this.options,t);return t!=null&&t.throwOnError||(r=r.catch(Ze)),r},Li=function(){ye(this,we,Hi).call(this);const t=Qt(this.options.staleTime,b(this,ge));if(yr||b(this,We).isStale||!Ii(t))return;const n=Lo(b(this,We).dataUpdatedAt,t)+1;ne(this,fr,setTimeout(()=>{b(this,We).isStale||this.updateResult()},n))},qi=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(b(this,ge)):this.options.refetchInterval)??!1},Ui=function(t){ye(this,we,Ki).call(this),ne(this,Ht,t),!(yr||st(this.options.enabled,b(this,ge))===!1||!Ii(b(this,Ht))||b(this,Ht)===0)&&ne(this,mr,setInterval(()=>{(this.options.refetchIntervalInBackground||ba.isFocused())&&ye(this,we,rn).call(this)},b(this,Ht)))},Wi=function(){ye(this,we,Li).call(this),ye(this,we,Ui).call(this,ye(this,we,qi).call(this))},Hi=function(){b(this,fr)&&(clearTimeout(b(this,fr)),ne(this,fr,void 0))},Ki=function(){b(this,mr)&&(clearInterval(b(this,mr)),ne(this,mr,void 0))},Qi=function(){const t=b(this,Ye).getQueryCache().build(b(this,Ye),this.options);if(t===b(this,ge))return;const r=b(this,ge);ne(this,ge,t),ne(this,yn,t.state),this.hasListeners()&&(r==null||r.removeObserver(this),t.addObserver(this))},Yo=function(t){Ne.batch(()=>{t.listeners&&this.listeners.forEach(r=>{r(b(this,We))}),b(this,Ye).getQueryCache().notify({query:b(this,ge),type:"observerResultsUpdated"})})},Oo);function Qc(e,t){return st(t.enabled,e)!==!1&&e.state.data===void 0&&!(e.state.status==="error"&&t.retryOnMount===!1)}function as(e,t){return Qc(e,t)||e.state.data!==void 0&&Yi(e,t,t.refetchOnMount)}function Yi(e,t,r){if(st(t.enabled,e)!==!1&&Qt(t.staleTime,e)!=="static"){const n=typeof r=="function"?r(e):r;return n==="always"||n!==!1&&wa(e,t)}return!1}function ss(e,t,r,n){return(e!==t||st(n.enabled,e)===!1)&&(!r.suspense||e.state.status!=="error")&&wa(e,r)}function wa(e,t){return st(t.enabled,e)!==!1&&e.isStaleByTime(Qt(t.staleTime,e))}function Yc(e,t){return!zi(e.getCurrentResult(),t)}var Go=ie.createContext(void 0),Gc=e=>{const t=ie.useContext(Go);if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},Zc=({client:e,children:t})=>(ie.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),v.jsx(Go.Provider,{value:e,children:t})),Zo=ie.createContext(!1),Xc=()=>ie.useContext(Zo);Zo.Provider;function Jc(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}var eu=ie.createContext(Jc()),tu=()=>ie.useContext(eu),ru=(e,t)=>{(e.suspense||e.throwOnError||e.experimental_prefetchInRender)&&(t.isReset()||(e.retryOnMount=!1))},nu=e=>{ie.useEffect(()=>{e.clearReset()},[e])},iu=({result:e,errorResetBoundary:t,throwOnError:r,query:n,suspense:i})=>e.isError&&!t.isReset()&&!e.isFetching&&n&&(i&&e.data===void 0||$c(r,[e.error,n])),au=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,ou=(e,t)=>(e==null?void 0:e.suspense)&&t.isPending,os=(e,t,r)=>t.fetchOptimistic(e).catch(()=>{r.clearReset()});function lu(e,t,r){var f,m,x,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=Xc(),i=tu(),a=Gc(),s=a.defaultQueryOptions(e);(m=(f=a.getDefaultOptions().queries)==null?void 0:f._experimental_beforeQuery)==null||m.call(f,s),process.env.NODE_ENV!=="production"&&(s.queryFn||console.error(`[${s.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`)),s._optimisticResults=n?"isRestoring":"optimistic",au(s),ru(s,i),nu(i);const o=!a.getQueryCache().get(s.queryHash),[l]=ie.useState(()=>new t(a,s)),d=l.getOptimisticResult(s),u=!n&&e.subscribed!==!1;if(ie.useSyncExternalStore(ie.useCallback(E=>{const h=u?l.subscribe(Ne.batchCalls(E)):Ze;return l.updateResult(),h},[l,u]),()=>l.getCurrentResult(),()=>l.getCurrentResult()),ie.useEffect(()=>{l.setOptions(s)},[s,l]),ou(s,d))throw os(s,l,i);if(iu({result:d,errorResetBoundary:i,throwOnError:s.throwOnError,query:a.getQueryCache().get(s.queryHash),suspense:s.suspense}))throw d.error;if((S=(x=a.getDefaultOptions().queries)==null?void 0:x._experimental_afterQuery)==null||S.call(x,s,d),s.experimental_prefetchInRender&&!yr&&su(d,n)){const E=o?os(s,l,i):(c=a.getQueryCache().get(s.queryHash))==null?void 0:c.promise;E==null||E.catch(Ze).finally(()=>{l.updateResult()})}return s.notifyOnChangeProps?d:l.trackResult(d)}function cu(e,t){return lu(e,Kc)}function Sa(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var kn={exports:{}},On={exports:{}},ve={};/** @license React v16.13.1
1
+ "use strict";var nc=Object.defineProperty;var Va=e=>{throw TypeError(e)};var ic=(e,t,r)=>t in e?nc(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var Xr=(e,t,r)=>ic(e,typeof t!="symbol"?t+"":t,r),gi=(e,t,r)=>t.has(e)||Va("Cannot "+r);var S=(e,t,r)=>(gi(e,t,"read from private field"),r?r.call(e):t.get(e)),fe=(e,t,r)=>t.has(e)?Va("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,r),ne=(e,t,r,n)=>(gi(e,t,"write to private field"),n?n.call(e,r):t.set(e,r),r),ge=(e,t,r)=>(gi(e,t,"access private method"),r);var Tn=(e,t,r,n)=>({set _(i){ne(e,t,i,r)},get _(){return S(e,t,n)}});Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const v=require("react/jsx-runtime"),D=require("react"),R=require("@mui/material"),ac=require("@emotion/styled"),vr=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 ie=sc(D);var vn=e=>e.type==="checkbox",ir=e=>e instanceof Date,Ke=e=>e==null;const _o=e=>typeof e=="object";var Me=e=>!Ke(e)&&!Array.isArray(e)&&_o(e)&&!ir(e),Ao=e=>Me(e)&&e.target?vn(e.target)?e.target.checked:e.target.value:e,oc=e=>e.substring(0,e.search(/\.\d+(\.|$)/))||e,Fo=(e,t)=>e.has(oc(t)),lc=e=>{const t=e.constructor&&e.constructor.prototype;return Me(t)&&t.hasOwnProperty("isPrototypeOf")},da=typeof window<"u"&&typeof window.HTMLElement<"u"&&typeof document<"u";function Be(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(!(da&&(e instanceof Blob||n))&&(r||Me(e)))if(t=r?[]:{},!r&&!lc(e))t=e;else for(const i in e)e.hasOwnProperty(i)&&(t[i]=Be(e[i]));else return e;return t}var si=e=>/^\w*$/.test(e),Ie=e=>e===void 0,fa=e=>Array.isArray(e)?e.filter(Boolean):[],ma=e=>fa(e.replace(/["|']|\]/g,"").split(/\.|\[/)),X=(e,t,r)=>{if(!t||!Me(e))return r;const n=(si(t)?[t]:ma(t)).reduce((i,a)=>Ke(i)?i:i[a],e);return Ie(n)||n===e?Ie(e[t])?r:e[t]:n},et=e=>typeof e=="boolean",we=(e,t,r)=>{let n=-1;const i=si(t)?[t]:ma(t),a=i.length,s=a-1;for(;++n<a;){const o=i[n];let l=r;if(n!==s){const f=e[o];l=Me(f)||Array.isArray(f)?f:isNaN(+i[n+1])?{}:[]}if(o==="__proto__"||o==="constructor"||o==="prototype")return;e[o]=l,e=e[o]}};const Bn={BLUR:"blur",FOCUS_OUT:"focusout",CHANGE:"change"},ft={onBlur:"onBlur",onChange:"onChange",onSubmit:"onSubmit",onTouched:"onTouched",all:"all"},Ot={max:"max",min:"min",maxLength:"maxLength",minLength:"minLength",pattern:"pattern",required:"required",validate:"validate"},jo=D.createContext(null);jo.displayName="HookFormContext";const ha=()=>D.useContext(jo);var Ro=(e,t,r,n=!0)=>{const i={defaultValues:t._defaultValues};for(const a in e)Object.defineProperty(i,a,{get:()=>{const s=a;return t._proxyFormState[s]!==ft.all&&(t._proxyFormState[s]=!n||ft.all),r&&(r[s]=!0),e[s]}});return i};const ya=typeof window<"u"?ie.useLayoutEffect:ie.useEffect;function cc(e){const t=ha(),{control:r=t.control,disabled:n,name:i,exact:a}=e||{},[s,o]=D.useState(r._formState),l=D.useRef({isDirty:!1,isLoading:!1,dirtyFields:!1,touchedFields:!1,validatingFields:!1,isValidating:!1,isValid:!1,errors:!1});return ya(()=>r._subscribe({name:i,formState:l.current,exact:a,callback:f=>{!n&&o({...r._formState,...f})}}),[i,n,a]),D.useEffect(()=>{l.current.isValid&&r._setValid(!0)},[r]),D.useMemo(()=>Ro(s,r,l.current,!1),[s,r])}var kt=e=>typeof e=="string",$o=(e,t,r,n,i)=>kt(e)?(n&&t.watch.add(e),X(r,e,i)):Array.isArray(e)?e.map(a=>(n&&t.watch.add(a),X(r,a))):(n&&(t.watchAll=!0),r);function uc(e){const t=ha(),{control:r=t.control,name:n,defaultValue:i,disabled:a,exact:s}=e||{},o=D.useRef(i),[l,f]=D.useState(r._getWatch(n,o.current));return ya(()=>r._subscribe({name:n,formState:{values:!0},exact:s,callback:u=>!a&&f($o(n,r._names,u.values||r._formValues,!1,o.current))}),[n,r,a,s]),D.useEffect(()=>r._removeUnmounted()),l}function pc(e){const t=ha(),{name:r,disabled:n,control:i=t.control,shouldUnregister:a}=e,s=Fo(i._names.array,r),o=uc({control:i,name:r,defaultValue:X(i._formValues,r,X(i._defaultValues,r,e.defaultValue)),exact:!0}),l=cc({control:i,name:r,exact:!0}),f=D.useRef(e),u=D.useRef(i.register(r,{...e.rules,value:o,...et(e.disabled)?{disabled:e.disabled}:{}})),p=D.useMemo(()=>Object.defineProperties({},{invalid:{enumerable:!0,get:()=>!!X(l.errors,r)},isDirty:{enumerable:!0,get:()=>!!X(l.dirtyFields,r)},isTouched:{enumerable:!0,get:()=>!!X(l.touchedFields,r)},isValidating:{enumerable:!0,get:()=>!!X(l.validatingFields,r)},error:{enumerable:!0,get:()=>X(l.errors,r)}}),[l,r]),m=D.useCallback(E=>u.current.onChange({target:{value:Ao(E),name:r},type:Bn.CHANGE}),[r]),x=D.useCallback(()=>u.current.onBlur({target:{value:X(i._formValues,r),name:r},type:Bn.BLUR}),[r,i._formValues]),w=D.useCallback(E=>{const y=X(i._fields,r);y&&E&&(y._f.ref={focus:()=>E.focus&&E.focus(),select:()=>E.select&&E.select(),setCustomValidity:C=>E.setCustomValidity(C),reportValidity:()=>E.reportValidity()})},[i._fields,r]),c=D.useMemo(()=>({name:r,value:o,...et(n)||l.disabled?{disabled:l.disabled||n}:{},onChange:m,onBlur:x,ref:w}),[r,n,l.disabled,m,x,w,o]);return D.useEffect(()=>{const E=i._options.shouldUnregister||a;i.register(r,{...f.current.rules,...et(f.current.disabled)?{disabled:f.current.disabled}:{}});const y=(C,A)=>{const _=X(i._fields,C);_&&_._f&&(_._f.mount=A)};if(y(r,!0),E){const C=Be(X(i._options.defaultValues,r));we(i._defaultValues,r,C),Ie(X(i._formValues,r))&&we(i._formValues,r,C)}return!s&&i.register(r),()=>{(s?E&&!i._state.action:E)?i.unregister(r):y(r,!1)}},[r,i,s,a]),D.useEffect(()=>{i._setDisabledField({disabled:n,name:r})},[n,r,i]),D.useMemo(()=>({field:c,formState:l,fieldState:p}),[c,l,p])}const gt=e=>e.render(pc(e));var Do=(e,t,r,n,i)=>t?{...r[e],types:{...r[e]&&r[e].types?r[e].types:{},[n]:i||!0}}:{},on=e=>Array.isArray(e)?e:[e],Na=()=>{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=[]}}},Pi=e=>Ke(e)||!_o(e);function zt(e,t){if(Pi(e)||Pi(t))return e===t;if(ir(e)&&ir(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 s=t[i];if(ir(a)&&ir(s)||Me(a)&&Me(s)||Array.isArray(a)&&Array.isArray(s)?!zt(a,s):a!==s)return!1}}return!0}var Ze=e=>Me(e)&&!Object.keys(e).length,ga=e=>e.type==="file",mt=e=>typeof e=="function",Ln=e=>{if(!da)return!1;const t=e?e.ownerDocument:0;return e instanceof(t&&t.defaultView?t.defaultView.HTMLElement:HTMLElement)},Po=e=>e.type==="select-multiple",va=e=>e.type==="radio",dc=e=>va(e)||vn(e),vi=e=>Ln(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 mc(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:si(t)?[t]:ma(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)&&Ze(n)||Array.isArray(n)&&mc(n))&&Ve(e,r.slice(0,-1)),e}var Io=e=>{for(const t in e)if(mt(e[t]))return!0;return!1};function qn(e,t={}){const r=Array.isArray(e);if(Me(e)||r)for(const n in e)Array.isArray(e[n])||Me(e[n])&&!Io(e[n])?(t[n]=Array.isArray(e[n])?[]:{},qn(e[n],t[n])):Ke(e[n])||(t[n]=!0);return t}function Mo(e,t,r){const n=Array.isArray(e);if(Me(e)||n)for(const i in e)Array.isArray(e[i])||Me(e[i])&&!Io(e[i])?Ie(t)||Pi(r[i])?r[i]=Array.isArray(e[i])?qn(e[i],[]):{...qn(e[i])}:Mo(e[i],Ke(t)?{}:t[i],r[i]):r[i]=!zt(e[i],t[i]);return r}var Jr=(e,t)=>Mo(e,t,qn(t));const Ba={value:!1,isValid:!1},La={value:!0,isValid:!0};var zo=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===""?La:{value:e[0].value,isValid:!0}:La:Ba}return Ba},Vo=(e,{valueAsNumber:t,valueAsDate:r,setValueAs:n})=>Ie(e)?e:t?e===""?NaN:e&&+e:r&&kt(e)?new Date(e):n?n(e):e;const qa={isValid:!1,value:null};var No=e=>Array.isArray(e)?e.reduce((t,r)=>r&&r.checked&&!r.disabled?{isValid:!0,value:r.value}:t,qa):qa;function Ua(e){const t=e.ref;return ga(t)?t.files:va(t)?No(e.refs).value:Po(t)?[...t.selectedOptions].map(({value:r})=>r):vn(t)?zo(e.refs).value:Vo(Ie(t.value)?e.ref.value:t.value,e)}var hc=(e,t,r,n)=>{const i={};for(const a of e){const s=X(t,a);s&&we(i,a,s._f)}return{criteriaMode:r,names:[...e],fields:i,shouldUseNativeValidation:n}},Un=e=>e instanceof RegExp,en=e=>Ie(e)?e:Un(e)?e.source:Me(e)?Un(e.value)?e.value.source:e.value:e,Wa=e=>({isOnSubmit:!e||e===ft.onSubmit,isOnBlur:e===ft.onBlur,isOnChange:e===ft.onChange,isOnAll:e===ft.all,isOnTouch:e===ft.onTouched});const Ha="AsyncFunction";var yc=e=>!!e&&!!e.validate&&!!(mt(e.validate)&&e.validate.constructor.name===Ha||Me(e.validate)&&Object.values(e.validate).find(t=>t.constructor.name===Ha)),gc=e=>e.mount&&(e.required||e.min||e.max||e.maxLength||e.minLength||e.pattern||e.validate),Ka=(e,t,r)=>!r&&(t.watchAll||t.watch.has(e)||[...t.watch].some(n=>e.startsWith(n)&&/^\.\w+/.test(e.slice(n.length))));const ln=(e,t,r,n)=>{for(const i of r||Object.keys(e)){const a=X(e,i);if(a){const{_f:s,...o}=a;if(s){if(s.refs&&s.refs[0]&&t(s.refs[0],i)&&!n)return!0;if(s.ref&&t(s.ref,s.name)&&!n)return!0;if(ln(o,t))break}else if(Me(o)&&ln(o,t))break}}};function Qa(e,t,r){const n=X(e,r);if(n||si(r))return{error:n,name:r};const i=r.split(".");for(;i.length;){const a=i.join("."),s=X(t,a),o=X(e,a);if(s&&!Array.isArray(s)&&r!==a)return{name:r};if(o&&o.type)return{name:a,error:o};if(o&&o.root&&o.root.type)return{name:`${a}.root`,error:o.root};i.pop()}return{name:r}}var vc=(e,t,r,n)=>{r(e);const{name:i,...a}=e;return Ze(a)||Object.keys(a).length>=Object.keys(t).length||Object.keys(a).find(s=>t[s]===(!n||ft.all))},xc=(e,t,r)=>!e||!t||e===t||on(e).some(n=>n&&(r?n===t:n.startsWith(t)||t.startsWith(n))),bc=(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,wc=(e,t)=>!fa(X(e,t)).length&&Ve(e,t),Sc=(e,t,r)=>{const n=on(X(e,r));return we(n,"root",t[r]),we(e,r,n),e},Pn=e=>kt(e);function Ya(e,t,r="validate"){if(Pn(e)||Array.isArray(e)&&e.every(Pn)||et(e)&&!e)return{type:r,message:Pn(e)?e:"",ref:t}}var kr=e=>Me(e)&&!Un(e)?e:{value:e,message:""},Ga=async(e,t,r,n,i,a)=>{const{ref:s,refs:o,required:l,maxLength:f,minLength:u,min:p,max:m,pattern:x,validate:w,name:c,valueAsNumber:E,mount:y}=e._f,C=X(r,c);if(!y||t.has(c))return{};const A=o?o[0]:s,_=P=>{i&&A.reportValidity&&(A.setCustomValidity(et(P)?"":P||""),A.reportValidity())},b={},L=va(s),j=vn(s),ee=L||j,K=(E||ga(s))&&Ie(s.value)&&Ie(C)||Ln(s)&&s.value===""||C===""||Array.isArray(C)&&!C.length,d=Do.bind(null,c,n,b),z=(P,q,N,Y=Ot.maxLength,re=Ot.minLength)=>{const me=P?q:N;b[c]={type:P?Y:re,message:me,ref:s,...d(P?Y:re,me)}};if(a?!Array.isArray(C)||!C.length:l&&(!ee&&(K||Ke(C))||et(C)&&!C||j&&!zo(o).isValid||L&&!No(o).isValid)){const{value:P,message:q}=Pn(l)?{value:!!l,message:l}:kr(l);if(P&&(b[c]={type:Ot.required,message:q,ref:A,...d(Ot.required,q)},!n))return _(q),b}if(!K&&(!Ke(p)||!Ke(m))){let P,q;const N=kr(m),Y=kr(p);if(!Ke(C)&&!isNaN(C)){const re=s.valueAsNumber||C&&+C;Ke(N.value)||(P=re>N.value),Ke(Y.value)||(q=re<Y.value)}else{const re=s.valueAsDate||new Date(C),me=V=>new Date(new Date().toDateString()+" "+V),ce=s.type=="time",oe=s.type=="week";kt(N.value)&&C&&(P=ce?me(C)>me(N.value):oe?C>N.value:re>new Date(N.value)),kt(Y.value)&&C&&(q=ce?me(C)<me(Y.value):oe?C<Y.value:re<new Date(Y.value))}if((P||q)&&(z(!!P,N.message,Y.message,Ot.max,Ot.min),!n))return _(b[c].message),b}if((f||u)&&!K&&(kt(C)||a&&Array.isArray(C))){const P=kr(f),q=kr(u),N=!Ke(P.value)&&C.length>+P.value,Y=!Ke(q.value)&&C.length<+q.value;if((N||Y)&&(z(N,P.message,q.message),!n))return _(b[c].message),b}if(x&&!K&&kt(C)){const{value:P,message:q}=kr(x);if(Un(P)&&!C.match(P)&&(b[c]={type:Ot.pattern,message:q,ref:s,...d(Ot.pattern,q)},!n))return _(q),b}if(w){if(mt(w)){const P=await w(C,r),q=Ya(P,A);if(q&&(b[c]={...q,...d(Ot.validate,q.message)},!n))return _(q.message),b}else if(Me(w)){let P={};for(const q in w){if(!Ze(P)&&!n)break;const N=Ya(await w[q](C,r),A,q);N&&(P={...N,...d(q,N.message)},_(N.message),n&&(b[c]=P))}if(!Ze(P)&&(b[c]={ref:A,...P},!n))return b}}return _(!0),b};const Ec={mode:ft.onSubmit,reValidateMode:ft.onChange,shouldFocusError:!0};function Tc(e={}){let t={...Ec,...e},r={submitCount:0,isDirty:!1,isReady:!1,isLoading:mt(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)?Be(t.defaultValues||t.values)||{}:{},a=t.shouldUnregister?{}:Be(i),s={action:!1,mount:!1,watch:!1},o={mount:new Set,disabled:new Set,unMount:new Set,array:new Set,watch:new Set},l,f=0;const u={isDirty:!1,dirtyFields:!1,validatingFields:!1,touchedFields:!1,isValidating:!1,isValid:!1,errors:!1};let p={...u};const m={array:Na(),state:Na()},x=t.criteriaMode===ft.all,w=h=>k=>{clearTimeout(f),f=setTimeout(h,k)},c=async h=>{if(!t.disabled&&(u.isValid||p.isValid||h)){const k=t.resolver?Ze((await j()).errors):await K(n,!0);k!==r.isValid&&m.state.next({isValid:k})}},E=(h,k)=>{!t.disabled&&(u.isValidating||u.validatingFields||p.isValidating||p.validatingFields)&&((h||Array.from(o.mount)).forEach(T=>{T&&(k?we(r.validatingFields,T,k):Ve(r.validatingFields,T))}),m.state.next({validatingFields:r.validatingFields,isValidating:!Ze(r.validatingFields)}))},y=(h,k=[],T,Z,O=!0,F=!0)=>{if(Z&&T&&!t.disabled){if(s.action=!0,F&&Array.isArray(X(n,h))){const J=T(X(n,h),Z.argA,Z.argB);O&&we(n,h,J)}if(F&&Array.isArray(X(r.errors,h))){const J=T(X(r.errors,h),Z.argA,Z.argB);O&&we(r.errors,h,J),wc(r.errors,h)}if((u.touchedFields||p.touchedFields)&&F&&Array.isArray(X(r.touchedFields,h))){const J=T(X(r.touchedFields,h),Z.argA,Z.argB);O&&we(r.touchedFields,h,J)}(u.dirtyFields||p.dirtyFields)&&(r.dirtyFields=Jr(i,a)),m.state.next({name:h,isDirty:z(h,k),dirtyFields:r.dirtyFields,errors:r.errors,isValid:r.isValid})}else we(a,h,k)},C=(h,k)=>{we(r.errors,h,k),m.state.next({errors:r.errors})},A=h=>{r.errors=h,m.state.next({errors:r.errors,isValid:!1})},_=(h,k,T,Z)=>{const O=X(n,h);if(O){const F=X(a,h,Ie(T)?X(i,h):T);Ie(F)||Z&&Z.defaultChecked||k?we(a,h,k?F:Ua(O._f)):N(h,F),s.mount&&c()}},b=(h,k,T,Z,O)=>{let F=!1,J=!1;const de={name:h};if(!t.disabled){if(!T||Z){(u.isDirty||p.isDirty)&&(J=r.isDirty,r.isDirty=de.isDirty=z(),F=J!==de.isDirty);const he=zt(X(i,h),k);J=!!X(r.dirtyFields,h),he?Ve(r.dirtyFields,h):we(r.dirtyFields,h,!0),de.dirtyFields=r.dirtyFields,F=F||(u.dirtyFields||p.dirtyFields)&&J!==!he}if(T){const he=X(r.touchedFields,h);he||(we(r.touchedFields,h,T),de.touchedFields=r.touchedFields,F=F||(u.touchedFields||p.touchedFields)&&he!==T)}F&&O&&m.state.next(de)}return F?de:{}},L=(h,k,T,Z)=>{const O=X(r.errors,h),F=(u.isValid||p.isValid)&&et(k)&&r.isValid!==k;if(t.delayError&&T?(l=w(()=>C(h,T)),l(t.delayError)):(clearTimeout(f),l=null,T?we(r.errors,h,T):Ve(r.errors,h)),(T?!zt(O,T):O)||!Ze(Z)||F){const J={...Z,...F&&et(k)?{isValid:k}:{},errors:r.errors,name:h};r={...r,...J},m.state.next(J)}},j=async h=>{E(h,!0);const k=await t.resolver(a,t.context,hc(h||o.mount,n,t.criteriaMode,t.shouldUseNativeValidation));return E(h),k},ee=async h=>{const{errors:k}=await j(h);if(h)for(const T of h){const Z=X(k,T);Z?we(r.errors,T,Z):Ve(r.errors,T)}else r.errors=k;return k},K=async(h,k,T={valid:!0})=>{for(const Z in h){const O=h[Z];if(O){const{_f:F,...J}=O;if(F){const de=o.array.has(F.name),he=O._f&&yc(O._f);he&&u.validatingFields&&E([Z],!0);const Ne=await Ga(O,o.disabled,a,x,t.shouldUseNativeValidation&&!k,de);if(he&&u.validatingFields&&E([Z]),Ne[F.name]&&(T.valid=!1,k))break;!k&&(X(Ne,F.name)?de?Sc(r.errors,Ne,F.name):we(r.errors,F.name,Ne[F.name]):Ve(r.errors,F.name))}!Ze(J)&&await K(J,k,T)}}return T.valid},d=()=>{for(const h of o.unMount){const k=X(n,h);k&&(k._f.refs?k._f.refs.every(T=>!vi(T)):!vi(k._f.ref))&&H(h)}o.unMount=new Set},z=(h,k)=>!t.disabled&&(h&&k&&we(a,h,k),!zt(V(),i)),P=(h,k,T)=>$o(h,o,{...s.mount?a:Ie(k)?i:kt(h)?{[h]:k}:k},T,k),q=h=>fa(X(s.mount?a:i,h,t.shouldUnregister?X(i,h,[]):[])),N=(h,k,T={})=>{const Z=X(n,h);let O=k;if(Z){const F=Z._f;F&&(!F.disabled&&we(a,h,Vo(k,F)),O=Ln(F.ref)&&Ke(k)?"":k,Po(F.ref)?[...F.ref.options].forEach(J=>J.selected=O.includes(J.value)):F.refs?vn(F.ref)?F.refs.forEach(J=>{(!J.defaultChecked||!J.disabled)&&(Array.isArray(O)?J.checked=!!O.find(de=>de===J.value):J.checked=O===J.value||!!O)}):F.refs.forEach(J=>J.checked=J.value===O):ga(F.ref)?F.ref.value="":(F.ref.value=O,F.ref.type||m.state.next({name:h,values:Be(a)})))}(T.shouldDirty||T.shouldTouch)&&b(h,O,T.shouldTouch,T.shouldDirty,!0),T.shouldValidate&&oe(h)},Y=(h,k,T)=>{for(const Z in k){if(!k.hasOwnProperty(Z))return;const O=k[Z],F=h+"."+Z,J=X(n,F);(o.array.has(h)||Me(O)||J&&!J._f)&&!ir(O)?Y(F,O,T):N(F,O,T)}},re=(h,k,T={})=>{const Z=X(n,h),O=o.array.has(h),F=Be(k);we(a,h,F),O?(m.array.next({name:h,values:Be(a)}),(u.isDirty||u.dirtyFields||p.isDirty||p.dirtyFields)&&T.shouldDirty&&m.state.next({name:h,dirtyFields:Jr(i,a),isDirty:z(h,F)})):Z&&!Z._f&&!Ke(F)?Y(h,F,T):N(h,F,T),Ka(h,o)&&m.state.next({...r}),m.state.next({name:s.mount?h:void 0,values:Be(a)})},me=async h=>{s.mount=!0;const k=h.target;let T=k.name,Z=!0;const O=X(n,T),F=he=>{Z=Number.isNaN(he)||ir(he)&&isNaN(he.getTime())||zt(he,X(a,T,he))},J=Wa(t.mode),de=Wa(t.reValidateMode);if(O){let he,Ne;const ut=k.type?Ua(O._f):Ao(h),it=h.type===Bn.BLUR||h.type===Bn.FOCUS_OUT,Yr=!gc(O._f)&&!t.resolver&&!X(r.errors,T)&&!O._f.deps||bc(it,X(r.touchedFields,T),r.isSubmitted,de,J),er=Ka(T,o,it);we(a,T,ut),it?(O._f.onBlur&&O._f.onBlur(h),l&&l(0)):O._f.onChange&&O._f.onChange(h);const Dt=b(T,ut,it),Gr=!Ze(Dt)||er;if(!it&&m.state.next({name:T,type:h.type,values:Be(a)}),Yr)return(u.isValid||p.isValid)&&(t.mode==="onBlur"?it&&c():it||c()),Gr&&m.state.next({name:T,...er?{}:Dt});if(!it&&er&&m.state.next({...r}),t.resolver){const{errors:Er}=await j([T]);if(F(ut),Z){const Zr=Qa(r.errors,n,T),Tr=Qa(Er,n,Zr.name||T);he=Tr.error,T=Tr.name,Ne=Ze(Er)}}else E([T],!0),he=(await Ga(O,o.disabled,a,x,t.shouldUseNativeValidation))[T],E([T]),F(ut),Z&&(he?Ne=!1:(u.isValid||p.isValid)&&(Ne=await K(n,!0)));Z&&(O._f.deps&&oe(O._f.deps),L(T,Ne,he,Dt))}},ce=(h,k)=>{if(X(r.errors,k)&&h.focus)return h.focus(),1},oe=async(h,k={})=>{let T,Z;const O=on(h);if(t.resolver){const F=await ee(Ie(h)?h:O);T=Ze(F),Z=h?!O.some(J=>X(F,J)):T}else h?(Z=(await Promise.all(O.map(async F=>{const J=X(n,F);return await K(J&&J._f?{[F]:J}:J)}))).every(Boolean),!(!Z&&!r.isValid)&&c()):Z=T=await K(n);return m.state.next({...!kt(h)||(u.isValid||p.isValid)&&T!==r.isValid?{}:{name:h},...t.resolver||!h?{isValid:T}:{},errors:r.errors}),k.shouldFocus&&!Z&&ln(n,ce,h?O:o.mount),Z},V=h=>{const k={...s.mount?a:i};return Ie(h)?k:kt(h)?X(k,h):h.map(T=>X(k,T))},U=(h,k)=>({invalid:!!X((k||r).errors,h),isDirty:!!X((k||r).dirtyFields,h),error:X((k||r).errors,h),isValidating:!!X(r.validatingFields,h),isTouched:!!X((k||r).touchedFields,h)}),ue=h=>{h&&on(h).forEach(k=>Ve(r.errors,k)),m.state.next({errors:h?r.errors:{}})},Q=(h,k,T)=>{const Z=(X(n,h,{_f:{}})._f||{}).ref,O=X(r.errors,h)||{},{ref:F,message:J,type:de,...he}=O;we(r.errors,h,{...he,...k,ref:Z}),m.state.next({name:h,errors:r.errors,isValid:!1}),T&&T.shouldFocus&&Z&&Z.focus&&Z.focus()},te=(h,k)=>mt(h)?m.state.subscribe({next:T=>h(P(void 0,k),T)}):P(h,k,!0),le=h=>m.state.subscribe({next:k=>{xc(h.name,k.name,h.exact)&&vc(k,h.formState||u,_e,h.reRenderRoot)&&h.callback({values:{...a},...r,...k})}}).unsubscribe,W=h=>(s.mount=!0,p={...p,...h.formState},le({...h,formState:p})),H=(h,k={})=>{for(const T of h?on(h):o.mount)o.mount.delete(T),o.array.delete(T),k.keepValue||(Ve(n,T),Ve(a,T)),!k.keepError&&Ve(r.errors,T),!k.keepDirty&&Ve(r.dirtyFields,T),!k.keepTouched&&Ve(r.touchedFields,T),!k.keepIsValidating&&Ve(r.validatingFields,T),!t.shouldUnregister&&!k.keepDefaultValue&&Ve(i,T);m.state.next({values:Be(a)}),m.state.next({...r,...k.keepDirty?{isDirty:z()}:{}}),!k.keepIsValid&&c()},ae=({disabled:h,name:k})=>{(et(h)&&s.mount||h||o.disabled.has(k))&&(h?o.disabled.add(k):o.disabled.delete(k))},pe=(h,k={})=>{let T=X(n,h);const Z=et(k.disabled)||et(t.disabled);return we(n,h,{...T||{},_f:{...T&&T._f?T._f:{ref:{name:h}},name:h,mount:!0,...k}}),o.mount.add(h),T?ae({disabled:et(k.disabled)?k.disabled:t.disabled,name:h}):_(h,!0,k.value),{...Z?{disabled:k.disabled||t.disabled}:{},...t.progressive?{required:!!k.required,min:en(k.min),max:en(k.max),minLength:en(k.minLength),maxLength:en(k.maxLength),pattern:en(k.pattern)}:{},name:h,onChange:me,onBlur:me,ref:O=>{if(O){pe(h,k),T=X(n,h);const F=Ie(O.value)&&O.querySelectorAll&&O.querySelectorAll("input,select,textarea")[0]||O,J=dc(F),de=T._f.refs||[];if(J?de.find(he=>he===F):F===T._f.ref)return;we(n,h,{_f:{...T._f,...J?{refs:[...de.filter(vi),F,...Array.isArray(X(i,h))?[{}]:[]],ref:{type:F.type,name:h}}:{ref:F}}}),_(h,!1,void 0,F)}else T=X(n,h,{}),T._f&&(T._f.mount=!1),(t.shouldUnregister||k.shouldUnregister)&&!(Fo(o.array,h)&&s.action)&&o.unMount.add(h)}}},M=()=>t.shouldFocusError&&ln(n,ce,o.mount),se=h=>{et(h)&&(m.state.next({disabled:h}),ln(n,(k,T)=>{const Z=X(n,T);Z&&(k.disabled=Z._f.disabled||h,Array.isArray(Z._f.refs)&&Z._f.refs.forEach(O=>{O.disabled=Z._f.disabled||h}))},0,!1))},I=(h,k)=>async T=>{let Z;T&&(T.preventDefault&&T.preventDefault(),T.persist&&T.persist());let O=Be(a);if(m.state.next({isSubmitting:!0}),t.resolver){const{errors:F,values:J}=await j();r.errors=F,O=J}else await K(n);if(o.disabled.size)for(const F of o.disabled)we(O,F,void 0);if(Ve(r.errors,"root"),Ze(r.errors)){m.state.next({errors:{}});try{await h(O,T)}catch(F){Z=F}}else k&&await k({...r.errors},T),M(),setTimeout(M);if(m.state.next({isSubmitted:!0,isSubmitting:!1,isSubmitSuccessful:Ze(r.errors)&&!Z,submitCount:r.submitCount+1,errors:r.errors}),Z)throw Z},B=(h,k={})=>{X(n,h)&&(Ie(k.defaultValue)?re(h,Be(X(i,h))):(re(h,k.defaultValue),we(i,h,Be(k.defaultValue))),k.keepTouched||Ve(r.touchedFields,h),k.keepDirty||(Ve(r.dirtyFields,h),r.isDirty=k.defaultValue?z(h,Be(X(i,h))):z()),k.keepError||(Ve(r.errors,h),u.isValid&&c()),m.state.next({...r}))},G=(h,k={})=>{const T=h?Be(h):i,Z=Be(T),O=Ze(h),F=O?i:Z;if(k.keepDefaultValues||(i=T),!k.keepValues){if(k.keepDirtyValues){const J=new Set([...o.mount,...Object.keys(Jr(i,a))]);for(const de of Array.from(J))X(r.dirtyFields,de)?we(F,de,X(a,de)):re(de,X(F,de))}else{if(da&&Ie(h))for(const J of o.mount){const de=X(n,J);if(de&&de._f){const he=Array.isArray(de._f.refs)?de._f.refs[0]:de._f.ref;if(Ln(he)){const Ne=he.closest("form");if(Ne){Ne.reset();break}}}}for(const J of o.mount)re(J,X(F,J))}a=Be(F),m.array.next({values:{...F}}),m.state.next({values:{...F}})}o={mount:k.keepDirtyValues?o.mount:new Set,unMount:new Set,array:new Set,disabled:new Set,watch:new Set,watchAll:!1,focus:""},s.mount=!u.isValid||!!k.keepIsValid||!!k.keepDirtyValues,s.watch=!!t.shouldUnregister,m.state.next({submitCount:k.keepSubmitCount?r.submitCount:0,isDirty:O?!1:k.keepDirty?r.isDirty:!!(k.keepDefaultValues&&!zt(h,i)),isSubmitted:k.keepIsSubmitted?r.isSubmitted:!1,dirtyFields:O?{}:k.keepDirtyValues?k.keepDefaultValues&&a?Jr(i,a):r.dirtyFields:k.keepDefaultValues&&h?Jr(i,h):k.keepDirty?r.dirtyFields:{},touchedFields:k.keepTouched?r.touchedFields:{},errors:k.keepErrors?r.errors:{},isSubmitSuccessful:k.keepIsSubmitSuccessful?r.isSubmitSuccessful:!1,isSubmitting:!1})},ye=(h,k)=>G(mt(h)?h(a):h,k),Fe=(h,k={})=>{const T=X(n,h),Z=T&&T._f;if(Z){const O=Z.refs?Z.refs[0]:Z.ref;O.focus&&(O.focus(),k.shouldSelect&&mt(O.select)&&O.select())}},_e=h=>{r={...r,...h}},qe={control:{register:pe,unregister:H,getFieldState:U,handleSubmit:I,setError:Q,_subscribe:le,_runSchema:j,_focusError:M,_getWatch:P,_getDirty:z,_setValid:c,_setFieldArray:y,_setDisabledField:ae,_setErrors:A,_getFieldArray:q,_reset:G,_resetDefaultValues:()=>mt(t.defaultValues)&&t.defaultValues().then(h=>{ye(h,t.resetOptions),m.state.next({isLoading:!1})}),_removeUnmounted:d,_disableForm:se,_subjects:m,_proxyFormState:u,get _fields(){return n},get _formValues(){return a},get _state(){return s},set _state(h){s=h},get _defaultValues(){return i},get _names(){return o},set _names(h){o=h},get _formState(){return r},get _options(){return t},set _options(h){t={...t,...h}}},subscribe:W,trigger:oe,register:pe,handleSubmit:I,watch:te,setValue:re,getValues:V,reset:ye,resetField:B,clearErrors:ue,unregister:H,setError:Q,setFocus:Fe,getFieldState:U};return{...qe,formControl:qe}}function kc(e={}){const t=D.useRef(void 0),r=D.useRef(void 0),[n,i]=D.useState({isDirty:!1,isValidating:!1,isLoading:mt(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:mt(e.defaultValues)?void 0:e.defaultValues});if(!t.current)if(e.formControl)t.current={...e.formControl,formState:n},e.defaultValues&&!mt(e.defaultValues)&&e.formControl.reset(e.defaultValues,e.resetOptions);else{const{formControl:s,...o}=Tc(e);t.current={...o,formState:n}}const a=t.current.control;return a._options=e,ya(()=>{const s=a._subscribe({formState:a._proxyFormState,callback:()=>i({...a._formState}),reRenderRoot:!0});return i(o=>({...o,isReady:!0})),a._formState.isReady=!0,s},[a]),D.useEffect(()=>a._disableForm(e.disabled),[a,e.disabled]),D.useEffect(()=>{e.mode&&(a._options.mode=e.mode),e.reValidateMode&&(a._options.reValidateMode=e.reValidateMode)},[a,e.mode,e.reValidateMode]),D.useEffect(()=>{e.errors&&(a._setErrors(e.errors),a._focusError())},[a,e.errors]),D.useEffect(()=>{e.shouldUnregister&&a._subjects.state.next({values:a._getWatch()})},[a,e.shouldUnregister]),D.useEffect(()=>{if(a._proxyFormState.isDirty){const s=a._getDirty();s!==n.isDirty&&a._subjects.state.next({isDirty:s})}},[a,n.isDirty]),D.useEffect(()=>{e.values&&!zt(e.values,r.current)?(a._reset(e.values,a._options.resetOptions),r.current=e.values,i(s=>({...s}))):a._resetDefaultValues()},[a,e.values]),D.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=Ro(n,a),t.current}const Za=(e,t,r)=>{if(e&&"reportValidity"in e){const n=X(r,t);e.setCustomValidity(n&&n.message||""),e.reportValidity()}},Bo=(e,t)=>{for(const r in t.fields){const n=t.fields[r];n&&n.ref&&"reportValidity"in n.ref?Za(n.ref,r,e):n&&n.refs&&n.refs.forEach(i=>Za(i,r,e))}},Cc=(e,t)=>{t.shouldUseNativeValidation&&Bo(e,t);const r={};for(const n in e){const i=X(t.fields,n),a=Object.assign(e[n]||{},{ref:i&&i.ref});if(Oc(t.names||Object.keys(e),n)){const s=Object.assign({},X(r,n));we(s,"root",a),we(r,n,s)}else we(r,n,a)}return r},Oc=(e,t)=>{const r=Xa(t);return e.some(n=>Xa(n).match(`^${r}\\.\\d+`))};function Xa(e){return e.replace(/\]|\[/g,"")}function _c(e,t,r){return r===void 0&&(r={}),function(n,i,a){try{return Promise.resolve(function(s,o){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(f){return a.shouldUseNativeValidation&&Bo({},a),{values:r.raw?Object.assign({},n):f,errors:{}}}))}catch(f){return o(f)}return l&&l.then?l.then(void 0,o):l}(0,function(s){if(!s.inner)throw s;return{values:{},errors:Cc((o=s,l=!a.shouldUseNativeValidation&&a.criteriaMode==="all",(o.inner||[]).reduce(function(f,u){if(f[u.path]||(f[u.path]={message:u.message,type:u.type}),l){var p=f[u.path].types,m=p&&p[u.type];f[u.path]=Do(u.path,l,f,u.type,m?[].concat(m,u.message):u.message)}return f},{})),a)};var o,l}))}catch(s){return Promise.reject(s)}}}var xn=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(){}},yr=typeof window>"u"||"Deno"in globalThis;function Xe(){}function Ac(e,t){return typeof e=="function"?e(t):e}function Ii(e){return typeof e=="number"&&e>=0&&e!==1/0}function Lo(e,t){return Math.max(e+(t||0)-Date.now(),0)}function Qt(e,t){return typeof e=="function"?e(t):e}function st(e,t){return typeof e=="function"?e(t):e}function Ja(e,t){const{type:r="all",exact:n,fetchStatus:i,predicate:a,queryKey:s,stale:o}=e;if(s){if(n){if(t.queryHash!==xa(s,t.options))return!1}else if(!pn(t.queryKey,s))return!1}if(r!=="all"){const l=t.isActive();if(r==="active"&&!l||r==="inactive"&&l)return!1}return!(typeof o=="boolean"&&t.isStale()!==o||i&&i!==t.state.fetchStatus||a&&!a(t))}function es(e,t){const{exact:r,status:n,predicate:i,mutationKey:a}=e;if(a){if(!t.options.mutationKey)return!1;if(r){if(un(t.options.mutationKey)!==un(a))return!1}else if(!pn(t.options.mutationKey,a))return!1}return!(n&&t.state.status!==n||i&&!i(t))}function xa(e,t){return((t==null?void 0:t.queryKeyHashFn)||un)(e)}function un(e){return JSON.stringify(e,(t,r)=>Vi(r)?Object.keys(r).sort().reduce((n,i)=>(n[i]=r[i],n),{}):r)}function pn(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?Object.keys(t).every(r=>pn(e[r],t[r])):!1}function Mi(e,t){if(e===t)return e;const r=ts(e)&&ts(t);if(r||Vi(e)&&Vi(t)){const n=r?e:Object.keys(e),i=n.length,a=r?t:Object.keys(t),s=a.length,o=r?[]:{},l=new Set(n);let f=0;for(let u=0;u<s;u++){const p=r?u:a[u];(!r&&l.has(p)||r)&&e[p]===void 0&&t[p]===void 0?(o[p]=void 0,f++):(o[p]=Mi(e[p],t[p]),o[p]===e[p]&&e[p]!==void 0&&f++)}return i===s&&f===i?e:o}return t}function zi(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 ts(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function Vi(e){if(!rs(e))return!1;const t=e.constructor;if(t===void 0)return!0;const r=t.prototype;return!(!rs(r)||!r.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function rs(e){return Object.prototype.toString.call(e)==="[object Object]"}function Fc(e){return new Promise(t=>{setTimeout(t,e)})}function Ni(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 Mi(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 Mi(e,t)}return t}function jc(e,t,r=0){const n=[...e,t];return r&&n.length>r?n.slice(1):n}function Rc(e,t,r=0){const n=[t,...e];return r&&n.length>r?n.slice(0,-1):n}var Wn=Symbol();function qo(e,t){return process.env.NODE_ENV!=="production"&&e.queryFn===Wn&&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===Wn?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}function $c(e,t){return typeof e=="function"?e(...t):!!e}var sr,Vt,Dr,xo,Dc=(xo=class extends xn{constructor(){super();fe(this,sr);fe(this,Vt);fe(this,Dr);ne(this,Dr,t=>{if(!yr&&window.addEventListener){const r=()=>t();return window.addEventListener("visibilitychange",r,!1),()=>{window.removeEventListener("visibilitychange",r)}}})}onSubscribe(){S(this,Vt)||this.setEventListener(S(this,Dr))}onUnsubscribe(){var t;this.hasListeners()||((t=S(this,Vt))==null||t.call(this),ne(this,Vt,void 0))}setEventListener(t){var r;ne(this,Dr,t),(r=S(this,Vt))==null||r.call(this),ne(this,Vt,t(n=>{typeof n=="boolean"?this.setFocused(n):this.onFocus()}))}setFocused(t){S(this,sr)!==t&&(ne(this,sr,t),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(r=>{r(t)})}isFocused(){var t;return typeof S(this,sr)=="boolean"?S(this,sr):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},sr=new WeakMap,Vt=new WeakMap,Dr=new WeakMap,xo),ba=new Dc,Pr,Nt,Ir,bo,Pc=(bo=class extends xn{constructor(){super();fe(this,Pr,!0);fe(this,Nt);fe(this,Ir);ne(this,Ir,t=>{if(!yr&&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(){S(this,Nt)||this.setEventListener(S(this,Ir))}onUnsubscribe(){var t;this.hasListeners()||((t=S(this,Nt))==null||t.call(this),ne(this,Nt,void 0))}setEventListener(t){var r;ne(this,Ir,t),(r=S(this,Nt))==null||r.call(this),ne(this,Nt,t(this.setOnline.bind(this)))}setOnline(t){S(this,Pr)!==t&&(ne(this,Pr,t),this.listeners.forEach(n=>{n(t)}))}isOnline(){return S(this,Pr)}},Pr=new WeakMap,Nt=new WeakMap,Ir=new WeakMap,bo),Hn=new Pc;function Bi(){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 Ic(e){return Math.min(1e3*2**e,3e4)}function Uo(e){return(e??"online")==="online"?Hn.isOnline():!0}var Wo=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function xi(e){return e instanceof Wo}function Ho(e){let t=!1,r=0,n=!1,i;const a=Bi(),s=c=>{var E;n||(m(new Wo(c)),(E=e.abort)==null||E.call(e))},o=()=>{t=!0},l=()=>{t=!1},f=()=>ba.isFocused()&&(e.networkMode==="always"||Hn.isOnline())&&e.canRun(),u=()=>Uo(e.networkMode)&&e.canRun(),p=c=>{var E;n||(n=!0,(E=e.onSuccess)==null||E.call(e,c),i==null||i(),a.resolve(c))},m=c=>{var E;n||(n=!0,(E=e.onError)==null||E.call(e,c),i==null||i(),a.reject(c))},x=()=>new Promise(c=>{var E;i=y=>{(n||f())&&c(y)},(E=e.onPause)==null||E.call(e)}).then(()=>{var c;i=void 0,n||(c=e.onContinue)==null||c.call(e)}),w=()=>{if(n)return;let c;const E=r===0?e.initialPromise:void 0;try{c=E??e.fn()}catch(y){c=Promise.reject(y)}Promise.resolve(c).then(p).catch(y=>{var L;if(n)return;const C=e.retry??(yr?0:3),A=e.retryDelay??Ic,_=typeof A=="function"?A(r,y):A,b=C===!0||typeof C=="number"&&r<C||typeof C=="function"&&C(r,y);if(t||!b){m(y);return}r++,(L=e.onFail)==null||L.call(e,r,y),Fc(_).then(()=>f()?void 0:x()).then(()=>{t?m(y):w()})})};return{promise:a,cancel:s,continue:()=>(i==null||i(),a),cancelRetry:o,continueRetry:l,canStart:u,start:()=>(u()?w():x().then(w),a)}}var Mc=e=>setTimeout(e,0);function zc(){let e=[],t=0,r=o=>{o()},n=o=>{o()},i=Mc;const a=o=>{t?e.push(o):i(()=>{r(o)})},s=()=>{const o=e;e=[],o.length&&i(()=>{n(()=>{o.forEach(l=>{r(l)})})})};return{batch:o=>{let l;t++;try{l=o()}finally{t--,t||s()}return l},batchCalls:o=>(...l)=>{a(()=>{o(...l)})},schedule:a,setNotifyFunction:o=>{r=o},setBatchNotifyFunction:o=>{n=o},setScheduler:o=>{i=o}}}var Le=zc(),or,wo,Ko=(wo=class{constructor(){fe(this,or)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),Ii(this.gcTime)&&ne(this,or,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(yr?1/0:5*60*1e3))}clearGcTimeout(){S(this,or)&&(clearTimeout(S(this,or)),ne(this,or,void 0))}},or=new WeakMap,wo),Mr,lr,at,cr,Ue,mn,ur,pt,jt,So,Vc=(So=class extends Ko{constructor(t){super();fe(this,pt);fe(this,Mr);fe(this,lr);fe(this,at);fe(this,cr);fe(this,Ue);fe(this,mn);fe(this,ur);ne(this,ur,!1),ne(this,mn,t.defaultOptions),this.setOptions(t.options),this.observers=[],ne(this,cr,t.client),ne(this,at,S(this,cr).getQueryCache()),this.queryKey=t.queryKey,this.queryHash=t.queryHash,ne(this,Mr,Nc(this.options)),this.state=t.state??S(this,Mr),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return(t=S(this,Ue))==null?void 0:t.promise}setOptions(t){this.options={...S(this,mn),...t},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&S(this,at).remove(this)}setData(t,r){const n=Ni(this.state.data,t,this.options);return ge(this,pt,jt).call(this,{data:n,type:"success",dataUpdatedAt:r==null?void 0:r.updatedAt,manual:r==null?void 0:r.manual}),n}setState(t,r){ge(this,pt,jt).call(this,{type:"setState",state:t,setStateOptions:r})}cancel(t){var n,i;const r=(n=S(this,Ue))==null?void 0:n.promise;return(i=S(this,Ue))==null||i.cancel(t),r?r.then(Xe).catch(Xe):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(S(this,Mr))}isActive(){return this.observers.some(t=>st(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===Wn||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStatic(){return this.getObserversCount()>0?this.observers.some(t=>Qt(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:!Lo(this.state.dataUpdatedAt,t)}onFocus(){var r;const t=this.observers.find(n=>n.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(r=S(this,Ue))==null||r.continue()}onOnline(){var r;const t=this.observers.find(n=>n.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(r=S(this,Ue))==null||r.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),S(this,at).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(r=>r!==t),this.observers.length||(S(this,Ue)&&(S(this,ur)?S(this,Ue).cancel({revert:!0}):S(this,Ue).cancelRetry()),this.scheduleGc()),S(this,at).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||ge(this,pt,jt).call(this,{type:"invalidate"})}fetch(t,r){var f,u,p;if(this.state.fetchStatus!=="idle"){if(this.state.data!==void 0&&(r!=null&&r.cancelRefetch))this.cancel({silent:!0});else if(S(this,Ue))return S(this,Ue).continueRetry(),S(this,Ue).promise}if(t&&this.setOptions(t),!this.options.queryFn){const m=this.observers.find(x=>x.options.queryFn);m&&this.setOptions(m.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=m=>{Object.defineProperty(m,"signal",{enumerable:!0,get:()=>(ne(this,ur,!0),n.signal)})},a=()=>{const m=qo(this.options,r),w=(()=>{const c={client:S(this,cr),queryKey:this.queryKey,meta:this.meta};return i(c),c})();return ne(this,ur,!1),this.options.persister?this.options.persister(m,w,this):m(w)},o=(()=>{const m={fetchOptions:r,options:this.options,queryKey:this.queryKey,client:S(this,cr),state:this.state,fetchFn:a};return i(m),m})();(f=this.options.behavior)==null||f.onFetch(o,this),ne(this,lr,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((u=o.fetchOptions)==null?void 0:u.meta))&&ge(this,pt,jt).call(this,{type:"fetch",meta:(p=o.fetchOptions)==null?void 0:p.meta});const l=m=>{var x,w,c,E;xi(m)&&m.silent||ge(this,pt,jt).call(this,{type:"error",error:m}),xi(m)||((w=(x=S(this,at).config).onError)==null||w.call(x,m,this),(E=(c=S(this,at).config).onSettled)==null||E.call(c,this.state.data,m,this)),this.scheduleGc()};return ne(this,Ue,Ho({initialPromise:r==null?void 0:r.initialPromise,fn:o.fetchFn,abort:n.abort.bind(n),onSuccess:m=>{var x,w,c,E;if(m===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(m)}catch(y){l(y);return}(w=(x=S(this,at).config).onSuccess)==null||w.call(x,m,this),(E=(c=S(this,at).config).onSettled)==null||E.call(c,m,this.state.error,this),this.scheduleGc()},onError:l,onFail:(m,x)=>{ge(this,pt,jt).call(this,{type:"failed",failureCount:m,error:x})},onPause:()=>{ge(this,pt,jt).call(this,{type:"pause"})},onContinue:()=>{ge(this,pt,jt).call(this,{type:"continue"})},retry:o.options.retry,retryDelay:o.options.retryDelay,networkMode:o.options.networkMode,canRun:()=>!0})),S(this,Ue).start()}},Mr=new WeakMap,lr=new WeakMap,at=new WeakMap,cr=new WeakMap,Ue=new WeakMap,mn=new WeakMap,ur=new WeakMap,pt=new WeakSet,jt=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,...Qo(n.data,this.options),fetchMeta:t.meta??null};case"success":return ne(this,lr,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 xi(i)&&i.revert&&S(this,lr)?{...S(this,lr),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()}),S(this,at).notify({query:this,type:"updated",action:t})})},So);function Qo(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:Uo(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function Nc(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 wt,Eo,Bc=(Eo=class extends xn{constructor(t={}){super();fe(this,wt);this.config=t,ne(this,wt,new Map)}build(t,r,n){const i=r.queryKey,a=r.queryHash??xa(i,r);let s=this.get(a);return s||(s=new Vc({client:t,queryKey:i,queryHash:a,options:t.defaultQueryOptions(r),state:n,defaultOptions:t.getQueryDefaults(i)}),this.add(s)),s}add(t){S(this,wt).has(t.queryHash)||(S(this,wt).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const r=S(this,wt).get(t.queryHash);r&&(t.destroy(),r===t&&S(this,wt).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){Le.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return S(this,wt).get(t)}getAll(){return[...S(this,wt).values()]}find(t){const r={exact:!0,...t};return this.getAll().find(n=>Ja(r,n))}findAll(t={}){const r=this.getAll();return Object.keys(t).length>0?r.filter(n=>Ja(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()})})}},wt=new WeakMap,Eo),St,We,pr,Et,It,To,Lc=(To=class extends Ko{constructor(t){super();fe(this,Et);fe(this,St);fe(this,We);fe(this,pr);this.mutationId=t.mutationId,ne(this,We,t.mutationCache),ne(this,St,[]),this.state=t.state||qc(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){S(this,St).includes(t)||(S(this,St).push(t),this.clearGcTimeout(),S(this,We).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){ne(this,St,S(this,St).filter(r=>r!==t)),this.scheduleGc(),S(this,We).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){S(this,St).length||(this.state.status==="pending"?this.scheduleGc():S(this,We).remove(this))}continue(){var t;return((t=S(this,pr))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var a,s,o,l,f,u,p,m,x,w,c,E,y,C,A,_,b,L,j,ee;const r=()=>{ge(this,Et,It).call(this,{type:"continue"})};ne(this,pr,Ho({fn:()=>this.options.mutationFn?this.options.mutationFn(t):Promise.reject(new Error("No mutationFn found")),onFail:(K,d)=>{ge(this,Et,It).call(this,{type:"failed",failureCount:K,error:d})},onPause:()=>{ge(this,Et,It).call(this,{type:"pause"})},onContinue:r,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>S(this,We).canRun(this)}));const n=this.state.status==="pending",i=!S(this,pr).canStart();try{if(n)r();else{ge(this,Et,It).call(this,{type:"pending",variables:t,isPaused:i}),await((s=(a=S(this,We).config).onMutate)==null?void 0:s.call(a,t,this));const d=await((l=(o=this.options).onMutate)==null?void 0:l.call(o,t));d!==this.state.context&&ge(this,Et,It).call(this,{type:"pending",context:d,variables:t,isPaused:i})}const K=await S(this,pr).start();return await((u=(f=S(this,We).config).onSuccess)==null?void 0:u.call(f,K,t,this.state.context,this)),await((m=(p=this.options).onSuccess)==null?void 0:m.call(p,K,t,this.state.context)),await((w=(x=S(this,We).config).onSettled)==null?void 0:w.call(x,K,null,this.state.variables,this.state.context,this)),await((E=(c=this.options).onSettled)==null?void 0:E.call(c,K,null,t,this.state.context)),ge(this,Et,It).call(this,{type:"success",data:K}),K}catch(K){try{throw await((C=(y=S(this,We).config).onError)==null?void 0:C.call(y,K,t,this.state.context,this)),await((_=(A=this.options).onError)==null?void 0:_.call(A,K,t,this.state.context)),await((L=(b=S(this,We).config).onSettled)==null?void 0:L.call(b,void 0,K,this.state.variables,this.state.context,this)),await((ee=(j=this.options).onSettled)==null?void 0:ee.call(j,void 0,K,t,this.state.context)),K}finally{ge(this,Et,It).call(this,{type:"error",error:K})}}finally{S(this,We).runNext(this)}}},St=new WeakMap,We=new WeakMap,pr=new WeakMap,Et=new WeakSet,It=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(()=>{S(this,St).forEach(n=>{n.onMutationUpdate(t)}),S(this,We).notify({mutation:this,type:"updated",action:t})})},To);function qc(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var Rt,dt,hn,ko,Uc=(ko=class extends xn{constructor(t={}){super();fe(this,Rt);fe(this,dt);fe(this,hn);this.config=t,ne(this,Rt,new Set),ne(this,dt,new Map),ne(this,hn,0)}build(t,r,n){const i=new Lc({mutationCache:this,mutationId:++Tn(this,hn)._,options:t.defaultMutationOptions(r),state:n});return this.add(i),i}add(t){S(this,Rt).add(t);const r=kn(t);if(typeof r=="string"){const n=S(this,dt).get(r);n?n.push(t):S(this,dt).set(r,[t])}this.notify({type:"added",mutation:t})}remove(t){if(S(this,Rt).delete(t)){const r=kn(t);if(typeof r=="string"){const n=S(this,dt).get(r);if(n)if(n.length>1){const i=n.indexOf(t);i!==-1&&n.splice(i,1)}else n[0]===t&&S(this,dt).delete(r)}}this.notify({type:"removed",mutation:t})}canRun(t){const r=kn(t);if(typeof r=="string"){const n=S(this,dt).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=kn(t);if(typeof r=="string"){const i=(n=S(this,dt).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(()=>{S(this,Rt).forEach(t=>{this.notify({type:"removed",mutation:t})}),S(this,Rt).clear(),S(this,dt).clear()})}getAll(){return Array.from(S(this,Rt))}find(t){const r={exact:!0,...t};return this.getAll().find(n=>es(r,n))}findAll(t={}){return this.getAll().filter(r=>es(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(Xe))))}},Rt=new WeakMap,dt=new WeakMap,hn=new WeakMap,ko);function kn(e){var t;return(t=e.options.scope)==null?void 0:t.id}function ns(e){return{onFetch:(t,r)=>{var u,p,m,x,w;const n=t.options,i=(m=(p=(u=t.fetchOptions)==null?void 0:u.meta)==null?void 0:p.fetchMore)==null?void 0:m.direction,a=((x=t.state.data)==null?void 0:x.pages)||[],s=((w=t.state.data)==null?void 0:w.pageParams)||[];let o={pages:[],pageParams:[]},l=0;const f=async()=>{let c=!1;const E=A=>{Object.defineProperty(A,"signal",{enumerable:!0,get:()=>(t.signal.aborted?c=!0:t.signal.addEventListener("abort",()=>{c=!0}),t.signal)})},y=qo(t.options,t.fetchOptions),C=async(A,_,b)=>{if(c)return Promise.reject();if(_==null&&A.pages.length)return Promise.resolve(A);const j=(()=>{const z={client:t.client,queryKey:t.queryKey,pageParam:_,direction:b?"backward":"forward",meta:t.options.meta};return E(z),z})(),ee=await y(j),{maxPages:K}=t.options,d=b?Rc:jc;return{pages:d(A.pages,ee,K),pageParams:d(A.pageParams,_,K)}};if(i&&a.length){const A=i==="backward",_=A?Wc:is,b={pages:a,pageParams:s},L=_(n,b);o=await C(b,L,A)}else{const A=e??a.length;do{const _=l===0?s[0]??n.initialPageParam:is(n,o);if(l>0&&_==null)break;o=await C(o,_),l++}while(l<A)}return o};t.options.persister?t.fetchFn=()=>{var c,E;return(E=(c=t.options).persister)==null?void 0:E.call(c,f,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},r)}:t.fetchFn=f}}}function is(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 Wc(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,Bt,Lt,zr,Vr,qt,Nr,Br,Co,Hc=(Co=class{constructor(e={}){fe(this,Pe);fe(this,Bt);fe(this,Lt);fe(this,zr);fe(this,Vr);fe(this,qt);fe(this,Nr);fe(this,Br);ne(this,Pe,e.queryCache||new Bc),ne(this,Bt,e.mutationCache||new Uc),ne(this,Lt,e.defaultOptions||{}),ne(this,zr,new Map),ne(this,Vr,new Map),ne(this,qt,0)}mount(){Tn(this,qt)._++,S(this,qt)===1&&(ne(this,Nr,ba.subscribe(async e=>{e&&(await this.resumePausedMutations(),S(this,Pe).onFocus())})),ne(this,Br,Hn.subscribe(async e=>{e&&(await this.resumePausedMutations(),S(this,Pe).onOnline())})))}unmount(){var e,t;Tn(this,qt)._--,S(this,qt)===0&&((e=S(this,Nr))==null||e.call(this),ne(this,Nr,void 0),(t=S(this,Br))==null||t.call(this),ne(this,Br,void 0))}isFetching(e){return S(this,Pe).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return S(this,Bt).findAll({...e,status:"pending"}).length}getQueryData(e){var r;const t=this.defaultQueryOptions({queryKey:e});return(r=S(this,Pe).get(t.queryHash))==null?void 0:r.state.data}ensureQueryData(e){const t=this.defaultQueryOptions(e),r=S(this,Pe).build(this,t),n=r.state.data;return n===void 0?this.fetchQuery(e):(e.revalidateIfStale&&r.isStaleByTime(Qt(t.staleTime,r))&&this.prefetchQuery(t),Promise.resolve(n))}getQueriesData(e){return S(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=S(this,Pe).get(n.queryHash),a=i==null?void 0:i.state.data,s=Ac(t,a);if(s!==void 0)return S(this,Pe).build(this,n).setData(s,{...r,manual:!0})}setQueriesData(e,t,r){return Le.batch(()=>S(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=S(this,Pe).get(t.queryHash))==null?void 0:r.state}removeQueries(e){const t=S(this,Pe);Le.batch(()=>{t.findAll(e).forEach(r=>{t.remove(r)})})}resetQueries(e,t){const r=S(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(()=>S(this,Pe).findAll(e).map(i=>i.cancel(r)));return Promise.all(n).then(Xe).catch(Xe)}invalidateQueries(e,t={}){return Le.batch(()=>(S(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(()=>S(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(Xe)),i.state.fetchStatus==="paused"?Promise.resolve():a}));return Promise.all(n).then(Xe)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const r=S(this,Pe).build(this,t);return r.isStaleByTime(Qt(t.staleTime,r))?r.fetch(t):Promise.resolve(r.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(Xe).catch(Xe)}fetchInfiniteQuery(e){return e.behavior=ns(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(Xe).catch(Xe)}ensureInfiniteQueryData(e){return e.behavior=ns(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return Hn.isOnline()?S(this,Bt).resumePausedMutations():Promise.resolve()}getQueryCache(){return S(this,Pe)}getMutationCache(){return S(this,Bt)}getDefaultOptions(){return S(this,Lt)}setDefaultOptions(e){ne(this,Lt,e)}setQueryDefaults(e,t){S(this,zr).set(un(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...S(this,zr).values()],r={};return t.forEach(n=>{pn(e,n.queryKey)&&Object.assign(r,n.defaultOptions)}),r}setMutationDefaults(e,t){S(this,Vr).set(un(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...S(this,Vr).values()],r={};return t.forEach(n=>{pn(e,n.mutationKey)&&Object.assign(r,n.defaultOptions)}),r}defaultQueryOptions(e){if(e._defaulted)return e;const t={...S(this,Lt).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=xa(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===Wn&&(t.enabled=!1),t}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...S(this,Lt).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){S(this,Pe).clear(),S(this,Bt).clear()}},Pe=new WeakMap,Bt=new WeakMap,Lt=new WeakMap,zr=new WeakMap,Vr=new WeakMap,qt=new WeakMap,Nr=new WeakMap,Br=new WeakMap,Co),Ge,ve,yn,He,dr,Lr,Ut,Wt,gn,qr,Ur,fr,mr,Ht,Wr,Se,rn,Li,qi,Ui,Wi,Hi,Ki,Qi,Yo,Oo,Kc=(Oo=class extends xn{constructor(t,r){super();fe(this,Se);fe(this,Ge);fe(this,ve);fe(this,yn);fe(this,He);fe(this,dr);fe(this,Lr);fe(this,Ut);fe(this,Wt);fe(this,gn);fe(this,qr);fe(this,Ur);fe(this,fr);fe(this,mr);fe(this,Ht);fe(this,Wr,new Set);this.options=r,ne(this,Ge,t),ne(this,Wt,null),ne(this,Ut,Bi()),this.options.experimental_prefetchInRender||S(this,Ut).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&&(S(this,ve).addObserver(this),as(S(this,ve),this.options)?ge(this,Se,rn).call(this):this.updateResult(),ge(this,Se,Wi).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return Yi(S(this,ve),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return Yi(S(this,ve),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,ge(this,Se,Hi).call(this),ge(this,Se,Ki).call(this),S(this,ve).removeObserver(this)}setOptions(t){const r=this.options,n=S(this,ve);if(this.options=S(this,Ge).defaultQueryOptions(t),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof st(this.options.enabled,S(this,ve))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");ge(this,Se,Qi).call(this),S(this,ve).setOptions(this.options),r._defaulted&&!zi(this.options,r)&&S(this,Ge).getQueryCache().notify({type:"observerOptionsUpdated",query:S(this,ve),observer:this});const i=this.hasListeners();i&&ss(S(this,ve),n,this.options,r)&&ge(this,Se,rn).call(this),this.updateResult(),i&&(S(this,ve)!==n||st(this.options.enabled,S(this,ve))!==st(r.enabled,S(this,ve))||Qt(this.options.staleTime,S(this,ve))!==Qt(r.staleTime,S(this,ve)))&&ge(this,Se,Li).call(this);const a=ge(this,Se,qi).call(this);i&&(S(this,ve)!==n||st(this.options.enabled,S(this,ve))!==st(r.enabled,S(this,ve))||a!==S(this,Ht))&&ge(this,Se,Ui).call(this,a)}getOptimisticResult(t){const r=S(this,Ge).getQueryCache().build(S(this,Ge),t),n=this.createResult(r,t);return Yc(this,n)&&(ne(this,He,n),ne(this,Lr,this.options),ne(this,dr,S(this,ve).state)),n}getCurrentResult(){return S(this,He)}trackResult(t,r){return new Proxy(t,{get:(n,i)=>(this.trackProp(i),r==null||r(i),Reflect.get(n,i))})}trackProp(t){S(this,Wr).add(t)}getCurrentQuery(){return S(this,ve)}refetch({...t}={}){return this.fetch({...t})}fetchOptimistic(t){const r=S(this,Ge).defaultQueryOptions(t),n=S(this,Ge).getQueryCache().build(S(this,Ge),r);return n.fetch().then(()=>this.createResult(n,r))}fetch(t){return ge(this,Se,rn).call(this,{...t,cancelRefetch:t.cancelRefetch??!0}).then(()=>(this.updateResult(),S(this,He)))}createResult(t,r){var K;const n=S(this,ve),i=this.options,a=S(this,He),s=S(this,dr),o=S(this,Lr),f=t!==n?t.state:S(this,yn),{state:u}=t;let p={...u},m=!1,x;if(r._optimisticResults){const d=this.hasListeners(),z=!d&&as(t,r),P=d&&ss(t,n,r,i);(z||P)&&(p={...p,...Qo(u.data,t.options)}),r._optimisticResults==="isRestoring"&&(p.fetchStatus="idle")}let{error:w,errorUpdatedAt:c,status:E}=p;x=p.data;let y=!1;if(r.placeholderData!==void 0&&x===void 0&&E==="pending"){let d;a!=null&&a.isPlaceholderData&&r.placeholderData===(o==null?void 0:o.placeholderData)?(d=a.data,y=!0):d=typeof r.placeholderData=="function"?r.placeholderData((K=S(this,Ur))==null?void 0:K.state.data,S(this,Ur)):r.placeholderData,d!==void 0&&(E="success",x=Ni(a==null?void 0:a.data,d,r),m=!0)}if(r.select&&x!==void 0&&!y)if(a&&x===(s==null?void 0:s.data)&&r.select===S(this,gn))x=S(this,qr);else try{ne(this,gn,r.select),x=r.select(x),x=Ni(a==null?void 0:a.data,x,r),ne(this,qr,x),ne(this,Wt,null)}catch(d){ne(this,Wt,d)}S(this,Wt)&&(w=S(this,Wt),x=S(this,qr),c=Date.now(),E="error");const C=p.fetchStatus==="fetching",A=E==="pending",_=E==="error",b=A&&C,L=x!==void 0,ee={status:E,fetchStatus:p.fetchStatus,isPending:A,isSuccess:E==="success",isError:_,isInitialLoading:b,isLoading:b,data:x,dataUpdatedAt:p.dataUpdatedAt,error:w,errorUpdatedAt:c,failureCount:p.fetchFailureCount,failureReason:p.fetchFailureReason,errorUpdateCount:p.errorUpdateCount,isFetched:p.dataUpdateCount>0||p.errorUpdateCount>0,isFetchedAfterMount:p.dataUpdateCount>f.dataUpdateCount||p.errorUpdateCount>f.errorUpdateCount,isFetching:C,isRefetching:C&&!A,isLoadingError:_&&!L,isPaused:p.fetchStatus==="paused",isPlaceholderData:m,isRefetchError:_&&L,isStale:wa(t,r),refetch:this.refetch,promise:S(this,Ut),isEnabled:st(r.enabled,t)!==!1};if(this.options.experimental_prefetchInRender){const d=q=>{ee.status==="error"?q.reject(ee.error):ee.data!==void 0&&q.resolve(ee.data)},z=()=>{const q=ne(this,Ut,ee.promise=Bi());d(q)},P=S(this,Ut);switch(P.status){case"pending":t.queryHash===n.queryHash&&d(P);break;case"fulfilled":(ee.status==="error"||ee.data!==P.value)&&z();break;case"rejected":(ee.status!=="error"||ee.error!==P.reason)&&z();break}}return ee}updateResult(){const t=S(this,He),r=this.createResult(S(this,ve),this.options);if(ne(this,dr,S(this,ve).state),ne(this,Lr,this.options),S(this,dr).data!==void 0&&ne(this,Ur,S(this,ve)),zi(r,t))return;ne(this,He,r);const n=()=>{if(!t)return!0;const{notifyOnChangeProps:i}=this.options,a=typeof i=="function"?i():i;if(a==="all"||!a&&!S(this,Wr).size)return!0;const s=new Set(a??S(this,Wr));return this.options.throwOnError&&s.add("error"),Object.keys(S(this,He)).some(o=>{const l=o;return S(this,He)[l]!==t[l]&&s.has(l)})};ge(this,Se,Yo).call(this,{listeners:n()})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&ge(this,Se,Wi).call(this)}},Ge=new WeakMap,ve=new WeakMap,yn=new WeakMap,He=new WeakMap,dr=new WeakMap,Lr=new WeakMap,Ut=new WeakMap,Wt=new WeakMap,gn=new WeakMap,qr=new WeakMap,Ur=new WeakMap,fr=new WeakMap,mr=new WeakMap,Ht=new WeakMap,Wr=new WeakMap,Se=new WeakSet,rn=function(t){ge(this,Se,Qi).call(this);let r=S(this,ve).fetch(this.options,t);return t!=null&&t.throwOnError||(r=r.catch(Xe)),r},Li=function(){ge(this,Se,Hi).call(this);const t=Qt(this.options.staleTime,S(this,ve));if(yr||S(this,He).isStale||!Ii(t))return;const n=Lo(S(this,He).dataUpdatedAt,t)+1;ne(this,fr,setTimeout(()=>{S(this,He).isStale||this.updateResult()},n))},qi=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(S(this,ve)):this.options.refetchInterval)??!1},Ui=function(t){ge(this,Se,Ki).call(this),ne(this,Ht,t),!(yr||st(this.options.enabled,S(this,ve))===!1||!Ii(S(this,Ht))||S(this,Ht)===0)&&ne(this,mr,setInterval(()=>{(this.options.refetchIntervalInBackground||ba.isFocused())&&ge(this,Se,rn).call(this)},S(this,Ht)))},Wi=function(){ge(this,Se,Li).call(this),ge(this,Se,Ui).call(this,ge(this,Se,qi).call(this))},Hi=function(){S(this,fr)&&(clearTimeout(S(this,fr)),ne(this,fr,void 0))},Ki=function(){S(this,mr)&&(clearInterval(S(this,mr)),ne(this,mr,void 0))},Qi=function(){const t=S(this,Ge).getQueryCache().build(S(this,Ge),this.options);if(t===S(this,ve))return;const r=S(this,ve);ne(this,ve,t),ne(this,yn,t.state),this.hasListeners()&&(r==null||r.removeObserver(this),t.addObserver(this))},Yo=function(t){Le.batch(()=>{t.listeners&&this.listeners.forEach(r=>{r(S(this,He))}),S(this,Ge).getQueryCache().notify({query:S(this,ve),type:"observerResultsUpdated"})})},Oo);function Qc(e,t){return st(t.enabled,e)!==!1&&e.state.data===void 0&&!(e.state.status==="error"&&t.retryOnMount===!1)}function as(e,t){return Qc(e,t)||e.state.data!==void 0&&Yi(e,t,t.refetchOnMount)}function Yi(e,t,r){if(st(t.enabled,e)!==!1&&Qt(t.staleTime,e)!=="static"){const n=typeof r=="function"?r(e):r;return n==="always"||n!==!1&&wa(e,t)}return!1}function ss(e,t,r,n){return(e!==t||st(n.enabled,e)===!1)&&(!r.suspense||e.state.status!=="error")&&wa(e,r)}function wa(e,t){return st(t.enabled,e)!==!1&&e.isStaleByTime(Qt(t.staleTime,e))}function Yc(e,t){return!zi(e.getCurrentResult(),t)}var Go=ie.createContext(void 0),Gc=e=>{const t=ie.useContext(Go);if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},Zc=({client:e,children:t})=>(ie.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),v.jsx(Go.Provider,{value:e,children:t})),Zo=ie.createContext(!1),Xc=()=>ie.useContext(Zo);Zo.Provider;function Jc(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}var eu=ie.createContext(Jc()),tu=()=>ie.useContext(eu),ru=(e,t)=>{(e.suspense||e.throwOnError||e.experimental_prefetchInRender)&&(t.isReset()||(e.retryOnMount=!1))},nu=e=>{ie.useEffect(()=>{e.clearReset()},[e])},iu=({result:e,errorResetBoundary:t,throwOnError:r,query:n,suspense:i})=>e.isError&&!t.isReset()&&!e.isFetching&&n&&(i&&e.data===void 0||$c(r,[e.error,n])),au=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,ou=(e,t)=>(e==null?void 0:e.suspense)&&t.isPending,os=(e,t,r)=>t.fetchOptimistic(e).catch(()=>{r.clearReset()});function lu(e,t,r){var p,m,x,w,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=Xc(),i=tu(),a=Gc(),s=a.defaultQueryOptions(e);(m=(p=a.getDefaultOptions().queries)==null?void 0:p._experimental_beforeQuery)==null||m.call(p,s),process.env.NODE_ENV!=="production"&&(s.queryFn||console.error(`[${s.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`)),s._optimisticResults=n?"isRestoring":"optimistic",au(s),ru(s,i),nu(i);const o=!a.getQueryCache().get(s.queryHash),[l]=ie.useState(()=>new t(a,s)),f=l.getOptimisticResult(s),u=!n&&e.subscribed!==!1;if(ie.useSyncExternalStore(ie.useCallback(E=>{const y=u?l.subscribe(Le.batchCalls(E)):Xe;return l.updateResult(),y},[l,u]),()=>l.getCurrentResult(),()=>l.getCurrentResult()),ie.useEffect(()=>{l.setOptions(s)},[s,l]),ou(s,f))throw os(s,l,i);if(iu({result:f,errorResetBoundary:i,throwOnError:s.throwOnError,query:a.getQueryCache().get(s.queryHash),suspense:s.suspense}))throw f.error;if((w=(x=a.getDefaultOptions().queries)==null?void 0:x._experimental_afterQuery)==null||w.call(x,s,f),s.experimental_prefetchInRender&&!yr&&su(f,n)){const E=o?os(s,l,i):(c=a.getQueryCache().get(s.queryHash))==null?void 0:c.promise;E==null||E.catch(Xe).finally(()=>{l.updateResult()})}return s.notifyOnChangeProps?f:l.trackResult(f)}function cu(e,t){return lu(e,Kc)}function Sa(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Cn={exports:{}},On={exports:{}},xe={};/** @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 ls;function uu(){if(ls)return ve;ls=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,s=e?Symbol.for("react.provider"):60109,o=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,m=e?Symbol.for("react.suspense_list"):60120,x=e?Symbol.for("react.memo"):60115,S=e?Symbol.for("react.lazy"):60116,c=e?Symbol.for("react.block"):60121,E=e?Symbol.for("react.fundamental"):60117,h=e?Symbol.for("react.responder"):60118,_=e?Symbol.for("react.scope"):60119;function $(w){if(typeof w=="object"&&w!==null){var F=w.$$typeof;switch(F){case t:switch(w=w.type,w){case l:case d:case n:case a:case i:case f:return w;default:switch(w=w&&w.$$typeof,w){case o:case u:case S:case x:case s:return w;default:return F}}case r:return F}}}function T(w){return $(w)===d}return ve.AsyncMode=l,ve.ConcurrentMode=d,ve.ContextConsumer=o,ve.ContextProvider=s,ve.Element=t,ve.ForwardRef=u,ve.Fragment=n,ve.Lazy=S,ve.Memo=x,ve.Portal=r,ve.Profiler=a,ve.StrictMode=i,ve.Suspense=f,ve.isAsyncMode=function(w){return T(w)||$(w)===l},ve.isConcurrentMode=T,ve.isContextConsumer=function(w){return $(w)===o},ve.isContextProvider=function(w){return $(w)===s},ve.isElement=function(w){return typeof w=="object"&&w!==null&&w.$$typeof===t},ve.isForwardRef=function(w){return $(w)===u},ve.isFragment=function(w){return $(w)===n},ve.isLazy=function(w){return $(w)===S},ve.isMemo=function(w){return $(w)===x},ve.isPortal=function(w){return $(w)===r},ve.isProfiler=function(w){return $(w)===a},ve.isStrictMode=function(w){return $(w)===i},ve.isSuspense=function(w){return $(w)===f},ve.isValidElementType=function(w){return typeof w=="string"||typeof w=="function"||w===n||w===d||w===a||w===i||w===f||w===m||typeof w=="object"&&w!==null&&(w.$$typeof===S||w.$$typeof===x||w.$$typeof===s||w.$$typeof===o||w.$$typeof===u||w.$$typeof===E||w.$$typeof===h||w.$$typeof===_||w.$$typeof===c)},ve.typeOf=$,ve}var xe={};/** @license React v16.13.1
8
+ */var ls;function uu(){if(ls)return xe;ls=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,s=e?Symbol.for("react.provider"):60109,o=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,f=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,p=e?Symbol.for("react.suspense"):60113,m=e?Symbol.for("react.suspense_list"):60120,x=e?Symbol.for("react.memo"):60115,w=e?Symbol.for("react.lazy"):60116,c=e?Symbol.for("react.block"):60121,E=e?Symbol.for("react.fundamental"):60117,y=e?Symbol.for("react.responder"):60118,C=e?Symbol.for("react.scope"):60119;function A(b){if(typeof b=="object"&&b!==null){var L=b.$$typeof;switch(L){case t:switch(b=b.type,b){case l:case f:case n:case a:case i:case p:return b;default:switch(b=b&&b.$$typeof,b){case o:case u:case w:case x:case s:return b;default:return L}}case r:return L}}}function _(b){return A(b)===f}return xe.AsyncMode=l,xe.ConcurrentMode=f,xe.ContextConsumer=o,xe.ContextProvider=s,xe.Element=t,xe.ForwardRef=u,xe.Fragment=n,xe.Lazy=w,xe.Memo=x,xe.Portal=r,xe.Profiler=a,xe.StrictMode=i,xe.Suspense=p,xe.isAsyncMode=function(b){return _(b)||A(b)===l},xe.isConcurrentMode=_,xe.isContextConsumer=function(b){return A(b)===o},xe.isContextProvider=function(b){return A(b)===s},xe.isElement=function(b){return typeof b=="object"&&b!==null&&b.$$typeof===t},xe.isForwardRef=function(b){return A(b)===u},xe.isFragment=function(b){return A(b)===n},xe.isLazy=function(b){return A(b)===w},xe.isMemo=function(b){return A(b)===x},xe.isPortal=function(b){return A(b)===r},xe.isProfiler=function(b){return A(b)===a},xe.isStrictMode=function(b){return A(b)===i},xe.isSuspense=function(b){return A(b)===p},xe.isValidElementType=function(b){return typeof b=="string"||typeof b=="function"||b===n||b===f||b===a||b===i||b===p||b===m||typeof b=="object"&&b!==null&&(b.$$typeof===w||b.$$typeof===x||b.$$typeof===s||b.$$typeof===o||b.$$typeof===u||b.$$typeof===E||b.$$typeof===y||b.$$typeof===C||b.$$typeof===c)},xe.typeOf=A,xe}var be={};/** @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 cs;function pu(){return cs||(cs=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,s=e?Symbol.for("react.provider"):60109,o=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,m=e?Symbol.for("react.suspense_list"):60120,x=e?Symbol.for("react.memo"):60115,S=e?Symbol.for("react.lazy"):60116,c=e?Symbol.for("react.block"):60121,E=e?Symbol.for("react.fundamental"):60117,h=e?Symbol.for("react.responder"):60118,_=e?Symbol.for("react.scope"):60119;function $(C){return typeof C=="string"||typeof C=="function"||C===n||C===d||C===a||C===i||C===f||C===m||typeof C=="object"&&C!==null&&(C.$$typeof===S||C.$$typeof===x||C.$$typeof===s||C.$$typeof===o||C.$$typeof===u||C.$$typeof===E||C.$$typeof===h||C.$$typeof===_||C.$$typeof===c)}function T(C){if(typeof C=="object"&&C!==null){var Q=C.$$typeof;switch(Q){case t:var me=C.type;switch(me){case l:case d:case n:case a:case i:case f:return me;default:var Te=me&&me.$$typeof;switch(Te){case o:case u:case S:case x:case s:return Te;default:return Q}}case r:return Q}}}var w=l,F=d,X=o,J=s,W=t,p=u,R=n,V=S,B=x,z=r,H=a,le=i,ce=f,pe=!1;function oe(C){return pe||(pe=!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.")),N(C)||T(C)===l}function N(C){return T(C)===d}function L(C){return T(C)===o}function K(C){return T(C)===s}function se(C){return typeof C=="object"&&C!==null&&C.$$typeof===t}function ae(C){return T(C)===u}function ee(C){return T(C)===n}function q(C){return T(C)===S}function te(C){return T(C)===x}function ue(C){return T(C)===r}function M(C){return T(C)===a}function U(C){return T(C)===i}function re(C){return T(C)===f}xe.AsyncMode=w,xe.ConcurrentMode=F,xe.ContextConsumer=X,xe.ContextProvider=J,xe.Element=W,xe.ForwardRef=p,xe.Fragment=R,xe.Lazy=V,xe.Memo=B,xe.Portal=z,xe.Profiler=H,xe.StrictMode=le,xe.Suspense=ce,xe.isAsyncMode=oe,xe.isConcurrentMode=N,xe.isContextConsumer=L,xe.isContextProvider=K,xe.isElement=se,xe.isForwardRef=ae,xe.isFragment=ee,xe.isLazy=q,xe.isMemo=te,xe.isPortal=ue,xe.isProfiler=M,xe.isStrictMode=U,xe.isSuspense=re,xe.isValidElementType=$,xe.typeOf=T}()),xe}var us;function Xo(){return us||(us=1,process.env.NODE_ENV==="production"?On.exports=uu():On.exports=pu()),On.exports}/*
15
+ */var cs;function pu(){return cs||(cs=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,s=e?Symbol.for("react.provider"):60109,o=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,f=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,p=e?Symbol.for("react.suspense"):60113,m=e?Symbol.for("react.suspense_list"):60120,x=e?Symbol.for("react.memo"):60115,w=e?Symbol.for("react.lazy"):60116,c=e?Symbol.for("react.block"):60121,E=e?Symbol.for("react.fundamental"):60117,y=e?Symbol.for("react.responder"):60118,C=e?Symbol.for("react.scope"):60119;function A(I){return typeof I=="string"||typeof I=="function"||I===n||I===f||I===a||I===i||I===p||I===m||typeof I=="object"&&I!==null&&(I.$$typeof===w||I.$$typeof===x||I.$$typeof===s||I.$$typeof===o||I.$$typeof===u||I.$$typeof===E||I.$$typeof===y||I.$$typeof===C||I.$$typeof===c)}function _(I){if(typeof I=="object"&&I!==null){var B=I.$$typeof;switch(B){case t:var G=I.type;switch(G){case l:case f:case n:case a:case i:case p:return G;default:var ye=G&&G.$$typeof;switch(ye){case o:case u:case w:case x:case s:return ye;default:return B}}case r:return B}}}var b=l,L=f,j=o,ee=s,K=t,d=u,z=n,P=w,q=x,N=r,Y=a,re=i,me=p,ce=!1;function oe(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)||_(I)===l}function V(I){return _(I)===f}function U(I){return _(I)===o}function ue(I){return _(I)===s}function Q(I){return typeof I=="object"&&I!==null&&I.$$typeof===t}function te(I){return _(I)===u}function le(I){return _(I)===n}function W(I){return _(I)===w}function H(I){return _(I)===x}function ae(I){return _(I)===r}function pe(I){return _(I)===a}function M(I){return _(I)===i}function se(I){return _(I)===p}be.AsyncMode=b,be.ConcurrentMode=L,be.ContextConsumer=j,be.ContextProvider=ee,be.Element=K,be.ForwardRef=d,be.Fragment=z,be.Lazy=P,be.Memo=q,be.Portal=N,be.Profiler=Y,be.StrictMode=re,be.Suspense=me,be.isAsyncMode=oe,be.isConcurrentMode=V,be.isContextConsumer=U,be.isContextProvider=ue,be.isElement=Q,be.isForwardRef=te,be.isFragment=le,be.isLazy=W,be.isMemo=H,be.isPortal=ae,be.isProfiler=pe,be.isStrictMode=M,be.isSuspense=se,be.isValidElementType=A,be.typeOf=_}()),be}var us;function Xo(){return us||(us=1,process.env.NODE_ENV==="production"?On.exports=uu():On.exports=pu()),On.exports}/*
16
16
  object-assign
17
17
  (c) Sindre Sorhus
18
18
  @license MIT
19
- */var bi,ps;function du(){if(ps)return bi;ps=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 s={},o=0;o<10;o++)s["_"+String.fromCharCode(o)]=o;var l=Object.getOwnPropertyNames(s).map(function(u){return s[u]});if(l.join("")!=="0123456789")return!1;var d={};return"abcdefghijklmnopqrst".split("").forEach(function(u){d[u]=u}),Object.keys(Object.assign({},d)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return bi=i()?Object.assign:function(a,s){for(var o,l=n(a),d,u=1;u<arguments.length;u++){o=Object(arguments[u]);for(var f in o)t.call(o,f)&&(l[f]=o[f]);if(e){d=e(o);for(var m=0;m<d.length;m++)r.call(o,d[m])&&(l[d[m]]=o[d[m]])}}return l},bi}var wi,ds;function Ea(){if(ds)return wi;ds=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return wi=e,wi}var Si,fs;function Jo(){return fs||(fs=1,Si=Function.call.bind(Object.prototype.hasOwnProperty)),Si}var Ei,ms;function fu(){if(ms)return Ei;ms=1;var e=function(){};if(process.env.NODE_ENV!=="production"){var t=Ea(),r={},n=Jo();e=function(a){var s="Warning: "+a;typeof console<"u"&&console.error(s);try{throw new Error(s)}catch{}}}function i(a,s,o,l,d){if(process.env.NODE_ENV!=="production"){for(var u in a)if(n(a,u)){var f;try{if(typeof a[u]!="function"){var m=Error((l||"React class")+": "+o+" 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 m.name="Invariant Violation",m}f=a[u](s,u,l,o,null,t)}catch(S){f=S}if(f&&!(f instanceof Error)&&e((l||"React class")+": type specification of "+o+" `"+u+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof f+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),f instanceof Error&&!(f.message in r)){r[f.message]=!0;var x=d?d():"";e("Failed "+o+" type: "+f.message+(x??""))}}}}return i.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(r={})},Ei=i,Ei}var Ci,hs;function mu(){if(hs)return Ci;hs=1;var e=Xo(),t=du(),r=Ea(),n=Jo(),i=fu(),a=function(){};process.env.NODE_ENV!=="production"&&(a=function(o){var l="Warning: "+o;typeof console<"u"&&console.error(l);try{throw new Error(l)}catch{}});function s(){return null}return Ci=function(o,l){var d=typeof Symbol=="function"&&Symbol.iterator,u="@@iterator";function f(N){var L=N&&(d&&N[d]||N[u]);if(typeof L=="function")return L}var m="<<anonymous>>",x={array:h("array"),bigint:h("bigint"),bool:h("boolean"),func:h("function"),number:h("number"),object:h("object"),string:h("string"),symbol:h("symbol"),any:_(),arrayOf:$,element:T(),elementType:w(),instanceOf:F,node:p(),objectOf:J,oneOf:X,oneOfType:W,shape:V,exact:B};function S(N,L){return N===L?N!==0||1/N===1/L:N!==N&&L!==L}function c(N,L){this.message=N,this.data=L&&typeof L=="object"?L:{},this.stack=""}c.prototype=Error.prototype;function E(N){if(process.env.NODE_ENV!=="production")var L={},K=0;function se(ee,q,te,ue,M,U,re){if(ue=ue||m,U=U||te,re!==r){if(l){var C=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 C.name="Invariant Violation",C}else if(process.env.NODE_ENV!=="production"&&typeof console<"u"){var Q=ue+":"+te;!L[Q]&&K<3&&(a("You are manually calling a React.PropTypes validation function for the `"+U+"` 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."),L[Q]=!0,K++)}}return q[te]==null?ee?q[te]===null?new c("The "+M+" `"+U+"` is marked as required "+("in `"+ue+"`, but its value is `null`.")):new c("The "+M+" `"+U+"` is marked as required in "+("`"+ue+"`, but its value is `undefined`.")):null:N(q,te,ue,M,U)}var ae=se.bind(null,!1);return ae.isRequired=se.bind(null,!0),ae}function h(N){function L(K,se,ae,ee,q,te){var ue=K[se],M=le(ue);if(M!==N){var U=ce(ue);return new c("Invalid "+ee+" `"+q+"` of type "+("`"+U+"` supplied to `"+ae+"`, expected ")+("`"+N+"`."),{expectedType:N})}return null}return E(L)}function _(){return E(s)}function $(N){function L(K,se,ae,ee,q){if(typeof N!="function")return new c("Property `"+q+"` of component `"+ae+"` has invalid PropType notation inside arrayOf.");var te=K[se];if(!Array.isArray(te)){var ue=le(te);return new c("Invalid "+ee+" `"+q+"` of type "+("`"+ue+"` supplied to `"+ae+"`, expected an array."))}for(var M=0;M<te.length;M++){var U=N(te,M,ae,ee,q+"["+M+"]",r);if(U instanceof Error)return U}return null}return E(L)}function T(){function N(L,K,se,ae,ee){var q=L[K];if(!o(q)){var te=le(q);return new c("Invalid "+ae+" `"+ee+"` of type "+("`"+te+"` supplied to `"+se+"`, expected a single ReactElement."))}return null}return E(N)}function w(){function N(L,K,se,ae,ee){var q=L[K];if(!e.isValidElementType(q)){var te=le(q);return new c("Invalid "+ae+" `"+ee+"` of type "+("`"+te+"` supplied to `"+se+"`, expected a single ReactElement type."))}return null}return E(N)}function F(N){function L(K,se,ae,ee,q){if(!(K[se]instanceof N)){var te=N.name||m,ue=oe(K[se]);return new c("Invalid "+ee+" `"+q+"` of type "+("`"+ue+"` supplied to `"+ae+"`, expected ")+("instance of `"+te+"`."))}return null}return E(L)}function X(N){if(!Array.isArray(N))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.")),s;function L(K,se,ae,ee,q){for(var te=K[se],ue=0;ue<N.length;ue++)if(S(te,N[ue]))return null;var M=JSON.stringify(N,function(re,C){var Q=ce(C);return Q==="symbol"?String(C):C});return new c("Invalid "+ee+" `"+q+"` of value `"+String(te)+"` "+("supplied to `"+ae+"`, expected one of "+M+"."))}return E(L)}function J(N){function L(K,se,ae,ee,q){if(typeof N!="function")return new c("Property `"+q+"` of component `"+ae+"` has invalid PropType notation inside objectOf.");var te=K[se],ue=le(te);if(ue!=="object")return new c("Invalid "+ee+" `"+q+"` of type "+("`"+ue+"` supplied to `"+ae+"`, expected an object."));for(var M in te)if(n(te,M)){var U=N(te,M,ae,ee,q+"."+M,r);if(U instanceof Error)return U}return null}return E(L)}function W(N){if(!Array.isArray(N))return process.env.NODE_ENV!=="production"&&a("Invalid argument supplied to oneOfType, expected an instance of array."),s;for(var L=0;L<N.length;L++){var K=N[L];if(typeof K!="function")return a("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+pe(K)+" at index "+L+"."),s}function se(ae,ee,q,te,ue){for(var M=[],U=0;U<N.length;U++){var re=N[U],C=re(ae,ee,q,te,ue,r);if(C==null)return null;C.data&&n(C.data,"expectedType")&&M.push(C.data.expectedType)}var Q=M.length>0?", expected one of type ["+M.join(", ")+"]":"";return new c("Invalid "+te+" `"+ue+"` supplied to "+("`"+q+"`"+Q+"."))}return E(se)}function p(){function N(L,K,se,ae,ee){return z(L[K])?null:new c("Invalid "+ae+" `"+ee+"` supplied to "+("`"+se+"`, expected a ReactNode."))}return E(N)}function R(N,L,K,se,ae){return new c((N||"React class")+": "+L+" type `"+K+"."+se+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+ae+"`.")}function V(N){function L(K,se,ae,ee,q){var te=K[se],ue=le(te);if(ue!=="object")return new c("Invalid "+ee+" `"+q+"` of type `"+ue+"` "+("supplied to `"+ae+"`, expected `object`."));for(var M in N){var U=N[M];if(typeof U!="function")return R(ae,ee,q,M,ce(U));var re=U(te,M,ae,ee,q+"."+M,r);if(re)return re}return null}return E(L)}function B(N){function L(K,se,ae,ee,q){var te=K[se],ue=le(te);if(ue!=="object")return new c("Invalid "+ee+" `"+q+"` of type `"+ue+"` "+("supplied to `"+ae+"`, expected `object`."));var M=t({},K[se],N);for(var U in M){var re=N[U];if(n(N,U)&&typeof re!="function")return R(ae,ee,q,U,ce(re));if(!re)return new c("Invalid "+ee+" `"+q+"` key `"+U+"` supplied to `"+ae+"`.\nBad object: "+JSON.stringify(K[se],null," ")+`
20
- Valid keys: `+JSON.stringify(Object.keys(N),null," "));var C=re(te,U,ae,ee,q+"."+U,r);if(C)return C}return null}return E(L)}function z(N){switch(typeof N){case"number":case"string":case"undefined":return!0;case"boolean":return!N;case"object":if(Array.isArray(N))return N.every(z);if(N===null||o(N))return!0;var L=f(N);if(L){var K=L.call(N),se;if(L!==N.entries){for(;!(se=K.next()).done;)if(!z(se.value))return!1}else for(;!(se=K.next()).done;){var ae=se.value;if(ae&&!z(ae[1]))return!1}}else return!1;return!0;default:return!1}}function H(N,L){return N==="symbol"?!0:L?L["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&L instanceof Symbol:!1}function le(N){var L=typeof N;return Array.isArray(N)?"array":N instanceof RegExp?"object":H(L,N)?"symbol":L}function ce(N){if(typeof N>"u"||N===null)return""+N;var L=le(N);if(L==="object"){if(N instanceof Date)return"date";if(N instanceof RegExp)return"regexp"}return L}function pe(N){var L=ce(N);switch(L){case"array":case"object":return"an "+L;case"boolean":case"date":case"regexp":return"a "+L;default:return L}}function oe(N){return!N.constructor||!N.constructor.name?m:N.constructor.name}return x.checkPropTypes=i,x.resetWarningCache=i.resetWarningCache,x.PropTypes=x,x},Ci}var Ti,ys;function hu(){if(ys)return Ti;ys=1;var e=Ea();function t(){}function r(){}return r.resetWarningCache=t,Ti=function(){function n(s,o,l,d,u,f){if(f!==e){var m=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 m.name="Invariant Violation",m}}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},Ti}var gs;function yu(){if(gs)return kn.exports;if(gs=1,process.env.NODE_ENV!=="production"){var e=Xo(),t=!0;kn.exports=mu()(e.isElement,t)}else kn.exports=hu()();return kn.exports}var gu=yu();const g=Sa(gu);function el(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=el(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=el(e))&&(n&&(n+=" "),n+=t);return n}function Qr(e,t,r=void 0){const n={};for(const i in e){const a=e[i];let s="",o=!0;for(let l=0;l<a.length;l+=1){const d=a[l];d&&(s+=(o===!0?"":" ")+t(d),o=!1,r&&r[d]&&(s+=" "+r[d]))}n[i]=s}return n}function Gt(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 Fe(e){if(typeof e!="string")throw new Error(process.env.NODE_ENV!=="production"?"MUI: `capitalize(string)` expects a string argument.":Gt(7));return e.charAt(0).toUpperCase()+e.slice(1)}var _n={exports:{}},Ee={};/**
19
+ */var bi,ps;function du(){if(ps)return bi;ps=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 s={},o=0;o<10;o++)s["_"+String.fromCharCode(o)]=o;var l=Object.getOwnPropertyNames(s).map(function(u){return s[u]});if(l.join("")!=="0123456789")return!1;var f={};return"abcdefghijklmnopqrst".split("").forEach(function(u){f[u]=u}),Object.keys(Object.assign({},f)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return bi=i()?Object.assign:function(a,s){for(var o,l=n(a),f,u=1;u<arguments.length;u++){o=Object(arguments[u]);for(var p in o)t.call(o,p)&&(l[p]=o[p]);if(e){f=e(o);for(var m=0;m<f.length;m++)r.call(o,f[m])&&(l[f[m]]=o[f[m]])}}return l},bi}var wi,ds;function Ea(){if(ds)return wi;ds=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return wi=e,wi}var Si,fs;function Jo(){return fs||(fs=1,Si=Function.call.bind(Object.prototype.hasOwnProperty)),Si}var Ei,ms;function fu(){if(ms)return Ei;ms=1;var e=function(){};if(process.env.NODE_ENV!=="production"){var t=Ea(),r={},n=Jo();e=function(a){var s="Warning: "+a;typeof console<"u"&&console.error(s);try{throw new Error(s)}catch{}}}function i(a,s,o,l,f){if(process.env.NODE_ENV!=="production"){for(var u in a)if(n(a,u)){var p;try{if(typeof a[u]!="function"){var m=Error((l||"React class")+": "+o+" 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 m.name="Invariant Violation",m}p=a[u](s,u,l,o,null,t)}catch(w){p=w}if(p&&!(p instanceof Error)&&e((l||"React class")+": type specification of "+o+" `"+u+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof p+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),p instanceof Error&&!(p.message in r)){r[p.message]=!0;var x=f?f():"";e("Failed "+o+" type: "+p.message+(x??""))}}}}return i.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(r={})},Ei=i,Ei}var Ti,hs;function mu(){if(hs)return Ti;hs=1;var e=Xo(),t=du(),r=Ea(),n=Jo(),i=fu(),a=function(){};process.env.NODE_ENV!=="production"&&(a=function(o){var l="Warning: "+o;typeof console<"u"&&console.error(l);try{throw new Error(l)}catch{}});function s(){return null}return Ti=function(o,l){var f=typeof Symbol=="function"&&Symbol.iterator,u="@@iterator";function p(V){var U=V&&(f&&V[f]||V[u]);if(typeof U=="function")return U}var m="<<anonymous>>",x={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:C(),arrayOf:A,element:_(),elementType:b(),instanceOf:L,node:d(),objectOf:ee,oneOf:j,oneOfType:K,shape:P,exact:q};function w(V,U){return V===U?V!==0||1/V===1/U:V!==V&&U!==U}function c(V,U){this.message=V,this.data=U&&typeof U=="object"?U:{},this.stack=""}c.prototype=Error.prototype;function E(V){if(process.env.NODE_ENV!=="production")var U={},ue=0;function Q(le,W,H,ae,pe,M,se){if(ae=ae||m,M=M||H,se!==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 B=ae+":"+H;!U[B]&&ue<3&&(a("You are manually calling a React.PropTypes validation function for the `"+M+"` prop on `"+ae+"`. 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."),U[B]=!0,ue++)}}return W[H]==null?le?W[H]===null?new c("The "+pe+" `"+M+"` is marked as required "+("in `"+ae+"`, but its value is `null`.")):new c("The "+pe+" `"+M+"` is marked as required in "+("`"+ae+"`, but its value is `undefined`.")):null:V(W,H,ae,pe,M)}var te=Q.bind(null,!1);return te.isRequired=Q.bind(null,!0),te}function y(V){function U(ue,Q,te,le,W,H){var ae=ue[Q],pe=re(ae);if(pe!==V){var M=me(ae);return new c("Invalid "+le+" `"+W+"` of type "+("`"+M+"` supplied to `"+te+"`, expected ")+("`"+V+"`."),{expectedType:V})}return null}return E(U)}function C(){return E(s)}function A(V){function U(ue,Q,te,le,W){if(typeof V!="function")return new c("Property `"+W+"` of component `"+te+"` has invalid PropType notation inside arrayOf.");var H=ue[Q];if(!Array.isArray(H)){var ae=re(H);return new c("Invalid "+le+" `"+W+"` of type "+("`"+ae+"` supplied to `"+te+"`, expected an array."))}for(var pe=0;pe<H.length;pe++){var M=V(H,pe,te,le,W+"["+pe+"]",r);if(M instanceof Error)return M}return null}return E(U)}function _(){function V(U,ue,Q,te,le){var W=U[ue];if(!o(W)){var H=re(W);return new c("Invalid "+te+" `"+le+"` of type "+("`"+H+"` supplied to `"+Q+"`, expected a single ReactElement."))}return null}return E(V)}function b(){function V(U,ue,Q,te,le){var W=U[ue];if(!e.isValidElementType(W)){var H=re(W);return new c("Invalid "+te+" `"+le+"` of type "+("`"+H+"` supplied to `"+Q+"`, expected a single ReactElement type."))}return null}return E(V)}function L(V){function U(ue,Q,te,le,W){if(!(ue[Q]instanceof V)){var H=V.name||m,ae=oe(ue[Q]);return new c("Invalid "+le+" `"+W+"` of type "+("`"+ae+"` supplied to `"+te+"`, expected ")+("instance of `"+H+"`."))}return null}return E(U)}function j(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.")),s;function U(ue,Q,te,le,W){for(var H=ue[Q],ae=0;ae<V.length;ae++)if(w(H,V[ae]))return null;var pe=JSON.stringify(V,function(se,I){var B=me(I);return B==="symbol"?String(I):I});return new c("Invalid "+le+" `"+W+"` of value `"+String(H)+"` "+("supplied to `"+te+"`, expected one of "+pe+"."))}return E(U)}function ee(V){function U(ue,Q,te,le,W){if(typeof V!="function")return new c("Property `"+W+"` of component `"+te+"` has invalid PropType notation inside objectOf.");var H=ue[Q],ae=re(H);if(ae!=="object")return new c("Invalid "+le+" `"+W+"` of type "+("`"+ae+"` supplied to `"+te+"`, expected an object."));for(var pe in H)if(n(H,pe)){var M=V(H,pe,te,le,W+"."+pe,r);if(M instanceof Error)return M}return null}return E(U)}function K(V){if(!Array.isArray(V))return process.env.NODE_ENV!=="production"&&a("Invalid argument supplied to oneOfType, expected an instance of array."),s;for(var U=0;U<V.length;U++){var ue=V[U];if(typeof ue!="function")return a("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+ce(ue)+" at index "+U+"."),s}function Q(te,le,W,H,ae){for(var pe=[],M=0;M<V.length;M++){var se=V[M],I=se(te,le,W,H,ae,r);if(I==null)return null;I.data&&n(I.data,"expectedType")&&pe.push(I.data.expectedType)}var B=pe.length>0?", expected one of type ["+pe.join(", ")+"]":"";return new c("Invalid "+H+" `"+ae+"` supplied to "+("`"+W+"`"+B+"."))}return E(Q)}function d(){function V(U,ue,Q,te,le){return N(U[ue])?null:new c("Invalid "+te+" `"+le+"` supplied to "+("`"+Q+"`, expected a ReactNode."))}return E(V)}function z(V,U,ue,Q,te){return new c((V||"React class")+": "+U+" type `"+ue+"."+Q+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+te+"`.")}function P(V){function U(ue,Q,te,le,W){var H=ue[Q],ae=re(H);if(ae!=="object")return new c("Invalid "+le+" `"+W+"` of type `"+ae+"` "+("supplied to `"+te+"`, expected `object`."));for(var pe in V){var M=V[pe];if(typeof M!="function")return z(te,le,W,pe,me(M));var se=M(H,pe,te,le,W+"."+pe,r);if(se)return se}return null}return E(U)}function q(V){function U(ue,Q,te,le,W){var H=ue[Q],ae=re(H);if(ae!=="object")return new c("Invalid "+le+" `"+W+"` of type `"+ae+"` "+("supplied to `"+te+"`, expected `object`."));var pe=t({},ue[Q],V);for(var M in pe){var se=V[M];if(n(V,M)&&typeof se!="function")return z(te,le,W,M,me(se));if(!se)return new c("Invalid "+le+" `"+W+"` key `"+M+"` supplied to `"+te+"`.\nBad object: "+JSON.stringify(ue[Q],null," ")+`
20
+ Valid keys: `+JSON.stringify(Object.keys(V),null," "));var I=se(H,M,te,le,W+"."+M,r);if(I)return I}return null}return E(U)}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||o(V))return!0;var U=p(V);if(U){var ue=U.call(V),Q;if(U!==V.entries){for(;!(Q=ue.next()).done;)if(!N(Q.value))return!1}else for(;!(Q=ue.next()).done;){var te=Q.value;if(te&&!N(te[1]))return!1}}else return!1;return!0;default:return!1}}function Y(V,U){return V==="symbol"?!0:U?U["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&U instanceof Symbol:!1}function re(V){var U=typeof V;return Array.isArray(V)?"array":V instanceof RegExp?"object":Y(U,V)?"symbol":U}function me(V){if(typeof V>"u"||V===null)return""+V;var U=re(V);if(U==="object"){if(V instanceof Date)return"date";if(V instanceof RegExp)return"regexp"}return U}function ce(V){var U=me(V);switch(U){case"array":case"object":return"an "+U;case"boolean":case"date":case"regexp":return"a "+U;default:return U}}function oe(V){return!V.constructor||!V.constructor.name?m:V.constructor.name}return x.checkPropTypes=i,x.resetWarningCache=i.resetWarningCache,x.PropTypes=x,x},Ti}var ki,ys;function hu(){if(ys)return ki;ys=1;var e=Ea();function t(){}function r(){}return r.resetWarningCache=t,ki=function(){function n(s,o,l,f,u,p){if(p!==e){var m=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 m.name="Invariant Violation",m}}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},ki}var gs;function yu(){if(gs)return Cn.exports;if(gs=1,process.env.NODE_ENV!=="production"){var e=Xo(),t=!0;Cn.exports=mu()(e.isElement,t)}else Cn.exports=hu()();return Cn.exports}var gu=yu();const g=Sa(gu);function el(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=el(e[t]))&&(n&&(n+=" "),n+=r)}else for(r in e)e[r]&&(n&&(n+=" "),n+=r);return n}function Qe(){for(var e,t,r=0,n="",i=arguments.length;r<i;r++)(e=arguments[r])&&(t=el(e))&&(n&&(n+=" "),n+=t);return n}function Qr(e,t,r=void 0){const n={};for(const i in e){const a=e[i];let s="",o=!0;for(let l=0;l<a.length;l+=1){const f=a[l];f&&(s+=(o===!0?"":" ")+t(f),o=!1,r&&r[f]&&(s+=" "+r[f]))}n[i]=s}return n}function Gt(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.":Gt(7));return e.charAt(0).toUpperCase()+e.slice(1)}var _n={exports:{}},Ee={};/**
21
21
  * @license React
22
22
  * react-is.production.js
23
23
  *
@@ -25,7 +25,7 @@ Valid keys: `+JSON.stringify(Object.keys(N),null," "));var C=re(te,U,ae,ee,q+".
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 vs;function vu(){if(vs)return Ee;vs=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"),s=Symbol.for("react.context"),o=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),d=Symbol.for("react.suspense_list"),u=Symbol.for("react.memo"),f=Symbol.for("react.lazy"),m=Symbol.for("react.view_transition"),x=Symbol.for("react.client.reference");function S(c){if(typeof c=="object"&&c!==null){var E=c.$$typeof;switch(E){case e:switch(c=c.type,c){case r:case i:case n:case l:case d:case m:return c;default:switch(c=c&&c.$$typeof,c){case s:case o:case f:case u:return c;case a:return c;default:return E}}case t:return E}}}return Ee.ContextConsumer=a,Ee.ContextProvider=s,Ee.Element=e,Ee.ForwardRef=o,Ee.Fragment=r,Ee.Lazy=f,Ee.Memo=u,Ee.Portal=t,Ee.Profiler=i,Ee.StrictMode=n,Ee.Suspense=l,Ee.SuspenseList=d,Ee.isContextConsumer=function(c){return S(c)===a},Ee.isContextProvider=function(c){return S(c)===s},Ee.isElement=function(c){return typeof c=="object"&&c!==null&&c.$$typeof===e},Ee.isForwardRef=function(c){return S(c)===o},Ee.isFragment=function(c){return S(c)===r},Ee.isLazy=function(c){return S(c)===f},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)===d},Ee.isValidElementType=function(c){return typeof c=="string"||typeof c=="function"||c===r||c===i||c===n||c===l||c===d||typeof c=="object"&&c!==null&&(c.$$typeof===f||c.$$typeof===u||c.$$typeof===s||c.$$typeof===a||c.$$typeof===o||c.$$typeof===x||c.getModuleId!==void 0)},Ee.typeOf=S,Ee}var Ce={};/**
28
+ */var vs;function vu(){if(vs)return Ee;vs=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"),s=Symbol.for("react.context"),o=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),f=Symbol.for("react.suspense_list"),u=Symbol.for("react.memo"),p=Symbol.for("react.lazy"),m=Symbol.for("react.view_transition"),x=Symbol.for("react.client.reference");function w(c){if(typeof c=="object"&&c!==null){var E=c.$$typeof;switch(E){case e:switch(c=c.type,c){case r:case i:case n:case l:case f:case m:return c;default:switch(c=c&&c.$$typeof,c){case s:case o:case p:case u:return c;case a:return c;default:return E}}case t:return E}}}return Ee.ContextConsumer=a,Ee.ContextProvider=s,Ee.Element=e,Ee.ForwardRef=o,Ee.Fragment=r,Ee.Lazy=p,Ee.Memo=u,Ee.Portal=t,Ee.Profiler=i,Ee.StrictMode=n,Ee.Suspense=l,Ee.SuspenseList=f,Ee.isContextConsumer=function(c){return w(c)===a},Ee.isContextProvider=function(c){return w(c)===s},Ee.isElement=function(c){return typeof c=="object"&&c!==null&&c.$$typeof===e},Ee.isForwardRef=function(c){return w(c)===o},Ee.isFragment=function(c){return w(c)===r},Ee.isLazy=function(c){return w(c)===p},Ee.isMemo=function(c){return w(c)===u},Ee.isPortal=function(c){return w(c)===t},Ee.isProfiler=function(c){return w(c)===i},Ee.isStrictMode=function(c){return w(c)===n},Ee.isSuspense=function(c){return w(c)===l},Ee.isSuspenseList=function(c){return w(c)===f},Ee.isValidElementType=function(c){return typeof c=="string"||typeof c=="function"||c===r||c===i||c===n||c===l||c===f||typeof c=="object"&&c!==null&&(c.$$typeof===p||c.$$typeof===u||c.$$typeof===s||c.$$typeof===a||c.$$typeof===o||c.$$typeof===x||c.getModuleId!==void 0)},Ee.typeOf=w,Ee}var Te={};/**
29
29
  * @license React
30
30
  * react-is.development.js
31
31
  *
@@ -33,22 +33,22 @@ Valid keys: `+JSON.stringify(Object.keys(N),null," "));var C=re(te,U,ae,ee,q+".
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 xs;function xu(){return xs||(xs=1,process.env.NODE_ENV!=="production"&&function(){function e(c){if(typeof c=="object"&&c!==null){var E=c.$$typeof;switch(E){case t:switch(c=c.type,c){case n:case a:case i:case d:case u:case x:return c;default:switch(c=c&&c.$$typeof,c){case o:case l:case m:case f:return c;case s:return c;default:return E}}case r:return E}}}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"),s=Symbol.for("react.consumer"),o=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),u=Symbol.for("react.suspense_list"),f=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),x=Symbol.for("react.view_transition"),S=Symbol.for("react.client.reference");Ce.ContextConsumer=s,Ce.ContextProvider=o,Ce.Element=t,Ce.ForwardRef=l,Ce.Fragment=n,Ce.Lazy=m,Ce.Memo=f,Ce.Portal=r,Ce.Profiler=a,Ce.StrictMode=i,Ce.Suspense=d,Ce.SuspenseList=u,Ce.isContextConsumer=function(c){return e(c)===s},Ce.isContextProvider=function(c){return e(c)===o},Ce.isElement=function(c){return typeof c=="object"&&c!==null&&c.$$typeof===t},Ce.isForwardRef=function(c){return e(c)===l},Ce.isFragment=function(c){return e(c)===n},Ce.isLazy=function(c){return e(c)===m},Ce.isMemo=function(c){return e(c)===f},Ce.isPortal=function(c){return e(c)===r},Ce.isProfiler=function(c){return e(c)===a},Ce.isStrictMode=function(c){return e(c)===i},Ce.isSuspense=function(c){return e(c)===d},Ce.isSuspenseList=function(c){return e(c)===u},Ce.isValidElementType=function(c){return typeof c=="string"||typeof c=="function"||c===n||c===a||c===i||c===d||c===u||typeof c=="object"&&c!==null&&(c.$$typeof===m||c.$$typeof===f||c.$$typeof===o||c.$$typeof===s||c.$$typeof===l||c.$$typeof===S||c.getModuleId!==void 0)},Ce.typeOf=e}()),Ce}var bs;function bu(){return bs||(bs=1,process.env.NODE_ENV==="production"?_n.exports=vu():_n.exports=xu()),_n.exports}var Kn=bu();function Ct(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 tl(e){if(ie.isValidElement(e)||Kn.isValidElementType(e)||!Ct(e))return e;const t={};return Object.keys(e).forEach(r=>{t[r]=tl(e[r])}),t}function rt(e,t,r={clone:!0}){const n=r.clone?{...e}:e;return Ct(e)&&Ct(t)&&Object.keys(t).forEach(i=>{ie.isValidElement(t[i])||Kn.isValidElementType(t[i])?n[i]=t[i]:Ct(t[i])&&Object.prototype.hasOwnProperty.call(e,i)&&Ct(e[i])?n[i]=rt(e[i],t[i],r):r.clone?n[i]=Ct(t[i])?tl(t[i]):t[i]:n[i]=t[i]}),n}function cn(e,t){return t?rt(e,t,{clone:!1}):e}const Xt=process.env.NODE_ENV!=="production"?g.oneOfType([g.number,g.string,g.object,g.array]):{};function wu(e,t){if(!e.containerQueries)return t;const r=Object.keys(t).filter(n=>n.startsWith("@container")).sort((n,i)=>{var s,o;const a=/min-width:\s*([0-9.]+)/;return+(((s=n.match(a))==null?void 0:s[1])||0)-+(((o=i.match(a))==null?void 0:o[1])||0)});return r.length?r.reduce((n,i)=>{const a=t[i];return delete n[i],n[i]=a,n},{...t}):t}function Su(e,t){return t==="@"||t.startsWith("@")&&(e.some(r=>t.startsWith(`@${r}`))||!!t.match(/^@\d/))}function Eu(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\`.`:Gt(18,`(${t})`));return null}const[,n,i]=r,a=Number.isNaN(+n)?n||0:+n;return e.containerQueries(i).up(a)}function Cu(e){const t=(a,s)=>a.replace("@media",s?`@container ${s}`:"@container");function r(a,s){a.up=(...o)=>t(e.breakpoints.up(...o),s),a.down=(...o)=>t(e.breakpoints.down(...o),s),a.between=(...o)=>t(e.breakpoints.between(...o),s),a.only=(...o)=>t(e.breakpoints.only(...o),s),a.not=(...o)=>{const l=t(e.breakpoints.not(...o),s);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 oi={xs:0,sm:600,md:900,lg:1200,xl:1536},ws={keys:["xs","sm","md","lg","xl"],up:e=>`@media (min-width:${oi[e]}px)`},Tu={containerQueries:e=>({up:t=>{let r=typeof t=="number"?t:oi[t]||t;return typeof r=="number"&&(r=`${r}px`),e?`@container ${e} (min-width:${r})`:`@container (min-width:${r})`}})};function $t(e,t,r){const n=e.theme||{};if(Array.isArray(t)){const a=n.breakpoints||ws;return t.reduce((s,o,l)=>(s[a.up(a.keys[l])]=r(t[l]),s),{})}if(typeof t=="object"){const a=n.breakpoints||ws;return Object.keys(t).reduce((s,o)=>{if(Su(a.keys,o)){const l=Eu(n.containerQueries?n:Tu,o);l&&(s[l]=r(t[o],o))}else if(Object.keys(a.values||oi).includes(o)){const l=a.up(o);s[l]=r(t[o],o)}else{const l=o;s[l]=t[l]}return s},{})}return r(t)}function ku(e={}){var r;return((r=e.keys)==null?void 0:r.reduce((n,i)=>{const a=e.up(i);return n[a]={},n},{}))||{}}function Ou(e,t){return e.reduce((r,n)=>{const i=r[n];return(!i||Object.keys(i).length===0)&&delete r[n],r},t)}function li(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 Qn(e,t,r,n=r){let i;return typeof e=="function"?i=e(r):Array.isArray(e)?i=e[r]||n:i=li(e,r)||n,t&&(i=t(i,n,e)),i}function Ie(e){const{prop:t,cssProperty:r=e.prop,themeKey:n,transform:i}=e,a=s=>{if(s[t]==null)return null;const o=s[t],l=s.theme,d=li(l,n)||{};return $t(s,o,f=>{let m=Qn(d,i,f);return f===m&&typeof f=="string"&&(m=Qn(d,i,`${t}${f==="default"?"":Fe(f)}`,f)),r===!1?m:{[r]:m}})};return a.propTypes=process.env.NODE_ENV!=="production"?{[t]:Xt}:{},a.filterProps=[t],a}function _u(e){const t={};return r=>(t[r]===void 0&&(t[r]=e(r)),t[r])}const Au={m:"margin",p:"padding"},Fu={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},Ss={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},ju=_u(e=>{if(e.length>2)if(Ss[e])e=Ss[e];else return[e];const[t,r]=e.split(""),n=Au[t],i=Fu[r]||"";return Array.isArray(i)?i.map(a=>n+a):[n+i]}),ci=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],ui=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],Ru=[...ci,...ui];function bn(e,t,r,n){const i=li(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 s=Math.abs(a);process.env.NODE_ENV!=="production"&&(Number.isInteger(s)?s>i.length-1&&console.error([`MUI: The value provided (${s}) overflows.`,`The supported values are: ${JSON.stringify(i)}.`,`${s} > ${i.length-1}, you need to add the missing values.`].join(`
36
+ */var xs;function xu(){return xs||(xs=1,process.env.NODE_ENV!=="production"&&function(){function e(c){if(typeof c=="object"&&c!==null){var E=c.$$typeof;switch(E){case t:switch(c=c.type,c){case n:case a:case i:case f:case u:case x:return c;default:switch(c=c&&c.$$typeof,c){case o:case l:case m:case p:return c;case s:return c;default:return E}}case r:return E}}}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"),s=Symbol.for("react.consumer"),o=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),f=Symbol.for("react.suspense"),u=Symbol.for("react.suspense_list"),p=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),x=Symbol.for("react.view_transition"),w=Symbol.for("react.client.reference");Te.ContextConsumer=s,Te.ContextProvider=o,Te.Element=t,Te.ForwardRef=l,Te.Fragment=n,Te.Lazy=m,Te.Memo=p,Te.Portal=r,Te.Profiler=a,Te.StrictMode=i,Te.Suspense=f,Te.SuspenseList=u,Te.isContextConsumer=function(c){return e(c)===s},Te.isContextProvider=function(c){return e(c)===o},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)===m},Te.isMemo=function(c){return e(c)===p},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)===f},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===f||c===u||typeof c=="object"&&c!==null&&(c.$$typeof===m||c.$$typeof===p||c.$$typeof===o||c.$$typeof===s||c.$$typeof===l||c.$$typeof===w||c.getModuleId!==void 0)},Te.typeOf=e}()),Te}var bs;function bu(){return bs||(bs=1,process.env.NODE_ENV==="production"?_n.exports=vu():_n.exports=xu()),_n.exports}var Kn=bu();function Tt(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 tl(e){if(ie.isValidElement(e)||Kn.isValidElementType(e)||!Tt(e))return e;const t={};return Object.keys(e).forEach(r=>{t[r]=tl(e[r])}),t}function rt(e,t,r={clone:!0}){const n=r.clone?{...e}:e;return Tt(e)&&Tt(t)&&Object.keys(t).forEach(i=>{ie.isValidElement(t[i])||Kn.isValidElementType(t[i])?n[i]=t[i]:Tt(t[i])&&Object.prototype.hasOwnProperty.call(e,i)&&Tt(e[i])?n[i]=rt(e[i],t[i],r):r.clone?n[i]=Tt(t[i])?tl(t[i]):t[i]:n[i]=t[i]}),n}function cn(e,t){return t?rt(e,t,{clone:!1}):e}const Xt=process.env.NODE_ENV!=="production"?g.oneOfType([g.number,g.string,g.object,g.array]):{};function wu(e,t){if(!e.containerQueries)return t;const r=Object.keys(t).filter(n=>n.startsWith("@container")).sort((n,i)=>{var s,o;const a=/min-width:\s*([0-9.]+)/;return+(((s=n.match(a))==null?void 0:s[1])||0)-+(((o=i.match(a))==null?void 0:o[1])||0)});return r.length?r.reduce((n,i)=>{const a=t[i];return delete n[i],n[i]=a,n},{...t}):t}function Su(e,t){return t==="@"||t.startsWith("@")&&(e.some(r=>t.startsWith(`@${r}`))||!!t.match(/^@\d/))}function Eu(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\`.`:Gt(18,`(${t})`));return null}const[,n,i]=r,a=Number.isNaN(+n)?n||0:+n;return e.containerQueries(i).up(a)}function Tu(e){const t=(a,s)=>a.replace("@media",s?`@container ${s}`:"@container");function r(a,s){a.up=(...o)=>t(e.breakpoints.up(...o),s),a.down=(...o)=>t(e.breakpoints.down(...o),s),a.between=(...o)=>t(e.breakpoints.between(...o),s),a.only=(...o)=>t(e.breakpoints.only(...o),s),a.not=(...o)=>{const l=t(e.breakpoints.not(...o),s);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 oi={xs:0,sm:600,md:900,lg:1200,xl:1536},ws={keys:["xs","sm","md","lg","xl"],up:e=>`@media (min-width:${oi[e]}px)`},ku={containerQueries:e=>({up:t=>{let r=typeof t=="number"?t:oi[t]||t;return typeof r=="number"&&(r=`${r}px`),e?`@container ${e} (min-width:${r})`:`@container (min-width:${r})`}})};function $t(e,t,r){const n=e.theme||{};if(Array.isArray(t)){const a=n.breakpoints||ws;return t.reduce((s,o,l)=>(s[a.up(a.keys[l])]=r(t[l]),s),{})}if(typeof t=="object"){const a=n.breakpoints||ws;return Object.keys(t).reduce((s,o)=>{if(Su(a.keys,o)){const l=Eu(n.containerQueries?n:ku,o);l&&(s[l]=r(t[o],o))}else if(Object.keys(a.values||oi).includes(o)){const l=a.up(o);s[l]=r(t[o],o)}else{const l=o;s[l]=t[l]}return s},{})}return r(t)}function Cu(e={}){var r;return((r=e.keys)==null?void 0:r.reduce((n,i)=>{const a=e.up(i);return n[a]={},n},{}))||{}}function Ou(e,t){return e.reduce((r,n)=>{const i=r[n];return(!i||Object.keys(i).length===0)&&delete r[n],r},t)}function li(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 Qn(e,t,r,n=r){let i;return typeof e=="function"?i=e(r):Array.isArray(e)?i=e[r]||n:i=li(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=s=>{if(s[t]==null)return null;const o=s[t],l=s.theme,f=li(l,n)||{};return $t(s,o,p=>{let m=Qn(f,i,p);return p===m&&typeof p=="string"&&(m=Qn(f,i,`${t}${p==="default"?"":Re(p)}`,p)),r===!1?m:{[r]:m}})};return a.propTypes=process.env.NODE_ENV!=="production"?{[t]:Xt}:{},a.filterProps=[t],a}function _u(e){const t={};return r=>(t[r]===void 0&&(t[r]=e(r)),t[r])}const Au={m:"margin",p:"padding"},Fu={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},Ss={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},ju=_u(e=>{if(e.length>2)if(Ss[e])e=Ss[e];else return[e];const[t,r]=e.split(""),n=Au[t],i=Fu[r]||"";return Array.isArray(i)?i.map(a=>n+a):[n+i]}),ci=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],ui=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],Ru=[...ci,...ui];function bn(e,t,r,n){const i=li(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 s=Math.abs(a);process.env.NODE_ENV!=="production"&&(Number.isInteger(s)?s>i.length-1&&console.error([`MUI: The value provided (${s}) overflows.`,`The supported values are: ${JSON.stringify(i)}.`,`${s} > ${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 o=i[s];return a>=0?o:typeof o=="number"?-o:typeof o=="string"&&o.startsWith("var(")?`calc(-1 * ${o})`:`-${o}`}: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 Ca(e){return bn(e,"spacing",8,"spacing")}function wn(e,t){return typeof t=="string"||t==null?t:e(t)}function $u(e,t){return r=>e.reduce((n,i)=>(n[i]=wn(t,r),n),{})}function Du(e,t,r,n){if(!t.includes(r))return null;const i=ju(r),a=$u(i,n),s=e[r];return $t(e,s,a)}function rl(e,t){const r=Ca(e.theme);return Object.keys(e).map(n=>Du(e,t,n,r)).reduce(cn,{})}function je(e){return rl(e,ci)}je.propTypes=process.env.NODE_ENV!=="production"?ci.reduce((e,t)=>(e[t]=Xt,e),{}):{};je.filterProps=ci;function Re(e){return rl(e,ui)}Re.propTypes=process.env.NODE_ENV!=="production"?ui.reduce((e,t)=>(e[t]=Xt,e),{}):{};Re.filterProps=ui;process.env.NODE_ENV!=="production"&&Ru.reduce((e,t)=>(e[t]=Xt,e),{});function pi(...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]?cn(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 lt(e){return typeof e!="number"?e:`${e}px solid`}function ct(e,t){return Ie({prop:e,themeKey:"borders",transform:t})}const Pu=ct("border",lt),Iu=ct("borderTop",lt),Mu=ct("borderRight",lt),zu=ct("borderBottom",lt),Vu=ct("borderLeft",lt),Nu=ct("borderColor"),Bu=ct("borderTopColor"),Lu=ct("borderRightColor"),qu=ct("borderBottomColor"),Uu=ct("borderLeftColor"),Wu=ct("outline",lt),Hu=ct("outlineColor"),di=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=bn(e.theme,"shape.borderRadius",4,"borderRadius"),r=n=>({borderRadius:wn(t,n)});return $t(e,e.borderRadius,r)}return null};di.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:Xt}:{};di.filterProps=["borderRadius"];pi(Pu,Iu,Mu,zu,Vu,Nu,Bu,Lu,qu,Uu,di,Wu,Hu);const fi=e=>{if(e.gap!==void 0&&e.gap!==null){const t=bn(e.theme,"spacing",8,"gap"),r=n=>({gap:wn(t,n)});return $t(e,e.gap,r)}return null};fi.propTypes=process.env.NODE_ENV!=="production"?{gap:Xt}:{};fi.filterProps=["gap"];const mi=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=bn(e.theme,"spacing",8,"columnGap"),r=n=>({columnGap:wn(t,n)});return $t(e,e.columnGap,r)}return null};mi.propTypes=process.env.NODE_ENV!=="production"?{columnGap:Xt}:{};mi.filterProps=["columnGap"];const hi=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=bn(e.theme,"spacing",8,"rowGap"),r=n=>({rowGap:wn(t,n)});return $t(e,e.rowGap,r)}return null};hi.propTypes=process.env.NODE_ENV!=="production"?{rowGap:Xt}:{};hi.filterProps=["rowGap"];const Ku=Ie({prop:"gridColumn"}),Qu=Ie({prop:"gridRow"}),Yu=Ie({prop:"gridAutoFlow"}),Gu=Ie({prop:"gridAutoColumns"}),Zu=Ie({prop:"gridAutoRows"}),Xu=Ie({prop:"gridTemplateColumns"}),Ju=Ie({prop:"gridTemplateRows"}),ep=Ie({prop:"gridTemplateAreas"}),tp=Ie({prop:"gridArea"});pi(fi,mi,hi,Ku,Qu,Yu,Gu,Zu,Xu,Ju,ep,tp);function $r(e,t){return t==="grey"?t:e}const rp=Ie({prop:"color",themeKey:"palette",transform:$r}),np=Ie({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:$r}),ip=Ie({prop:"backgroundColor",themeKey:"palette",transform:$r});pi(rp,np,ip);function tt(e){return e<=1&&e!==0?`${e*100}%`:e}const ap=Ie({prop:"width",transform:tt}),Ta=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=r=>{var i,a,s,o,l;const n=((s=(a=(i=e.theme)==null?void 0:i.breakpoints)==null?void 0:a.values)==null?void 0:s[r])||oi[r];return n?((l=(o=e.theme)==null?void 0:o.breakpoints)==null?void 0:l.unit)!=="px"?{maxWidth:`${n}${e.theme.breakpoints.unit}`}:{maxWidth:n}:{maxWidth:tt(r)}};return $t(e,e.maxWidth,t)}return null};Ta.filterProps=["maxWidth"];const sp=Ie({prop:"minWidth",transform:tt}),op=Ie({prop:"height",transform:tt}),lp=Ie({prop:"maxHeight",transform:tt}),cp=Ie({prop:"minHeight",transform:tt});Ie({prop:"size",cssProperty:"width",transform:tt});Ie({prop:"size",cssProperty:"height",transform:tt});const up=Ie({prop:"boxSizing"});pi(ap,Ta,sp,op,lp,cp,up);const Sn={border:{themeKey:"borders",transform:lt},borderTop:{themeKey:"borders",transform:lt},borderRight:{themeKey:"borders",transform:lt},borderBottom:{themeKey:"borders",transform:lt},borderLeft:{themeKey:"borders",transform:lt},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:lt},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:di},color:{themeKey:"palette",transform:$r},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:$r},backgroundColor:{themeKey:"palette",transform:$r},p:{style:Re},pt:{style:Re},pr:{style:Re},pb:{style:Re},pl:{style:Re},px:{style:Re},py:{style:Re},padding:{style:Re},paddingTop:{style:Re},paddingRight:{style:Re},paddingBottom:{style:Re},paddingLeft:{style:Re},paddingX:{style:Re},paddingY:{style:Re},paddingInline:{style:Re},paddingInlineStart:{style:Re},paddingInlineEnd:{style:Re},paddingBlock:{style:Re},paddingBlockStart:{style:Re},paddingBlockEnd:{style:Re},m:{style:je},mt:{style:je},mr:{style:je},mb:{style:je},ml:{style:je},mx:{style:je},my:{style:je},margin:{style:je},marginTop:{style:je},marginRight:{style:je},marginBottom:{style:je},marginLeft:{style:je},marginX:{style:je},marginY:{style:je},marginInline:{style:je},marginInlineStart:{style:je},marginInlineEnd:{style:je},marginBlock:{style:je},marginBlockStart:{style:je},marginBlockEnd:{style:je},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:fi},rowGap:{style:hi},columnGap:{style:mi},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:tt},maxWidth:{style:Ta},minWidth:{transform:tt},height:{transform:tt},maxHeight:{transform:tt},minHeight:{transform:tt},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 pp(...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 dp(e,t){return typeof e=="function"?e(t):e}function fp(){function e(r,n,i,a){const s={[r]:n,theme:i},o=a[r];if(!o)return{[r]:n};const{cssProperty:l=r,themeKey:d,transform:u,style:f}=o;if(n==null)return null;if(d==="typography"&&n==="inherit")return{[r]:n};const m=li(i,d)||{};return f?f(s):$t(s,n,S=>{let c=Qn(m,u,S);return S===c&&typeof S=="string"&&(c=Qn(m,u,`${r}${S==="default"?"":Fe(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??Sn;function s(o){let l=o;if(typeof o=="function")l=o(i);else if(typeof o!="object")return o;if(!l)return null;const d=ku(i.breakpoints),u=Object.keys(d);let f=d;return Object.keys(l).forEach(m=>{const x=dp(l[m],i);if(x!=null)if(typeof x=="object")if(a[m])f=cn(f,e(m,x,i,a));else{const S=$t({theme:i},x,c=>({[m]:c}));pp(S,x)?f[m]=t({sx:x,theme:i}):f=cn(f,S)}else f=cn(f,e(m,x,i,a))}),wu(i,Ou(u,f))}return Array.isArray(n)?n.map(s):s(n)}return t}const Hr=fp();Hr.filterProps=["sx"];const mp=e=>{var n;const t={systemProps:{},otherProps:{}},r=((n=e==null?void 0:e.theme)==null?void 0:n.unstable_sxConfig)??Sn;return Object.keys(e).forEach(i=>{r[i]?t.systemProps[i]=e[i]:t.otherProps[i]=e[i]}),t};function hp(e){const{sx:t,...r}=e,{systemProps:n,otherProps:i}=mp(r);let a;return Array.isArray(t)?a=[n,...t]:typeof t=="function"?a=(...s)=>{const o=t(...s);return Ct(o)?{...n,...o}:n}:a={...n,...t},{...i,sx:a}}function yp(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 gp={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 vp(e){var t=Object.create(null);return function(r){return t[r]===void 0&&(t[r]=e(r)),t[r]}}var xp=/[A-Z]|^ms/g,bp=/_EMO_([^_]+?)_([^]*?)_EMO_/g,nl=function(t){return t.charCodeAt(1)===45},Es=function(t){return t!=null&&typeof t!="boolean"},ki=vp(function(e){return nl(e)?e:e.replace(xp,"-$&").toLowerCase()}),Cs=function(t,r){switch(t){case"animation":case"animationName":if(typeof r=="string")return r.replace(bp,function(n,i,a){return Kt={name:i,styles:a,next:Kt},i})}return gp[t]!==1&&!nl(t)&&typeof r=="number"&&r!==0?r+"px":r};function Yn(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 Kt={name:i.name,styles:i.styles,next:Kt},i.name;var a=r;if(a.styles!==void 0){var s=a.next;if(s!==void 0)for(;s!==void 0;)Kt={name:s.name,styles:s.styles,next:Kt},s=s.next;var o=a.styles+";";return o}return wp(e,t,r)}}var l=r;return l}function wp(e,t,r){var n="";if(Array.isArray(r))for(var i=0;i<r.length;i++)n+=Yn(e,t,r[i])+";";else for(var a in r){var s=r[a];if(typeof s!="object"){var o=s;Es(o)&&(n+=ki(a)+":"+Cs(a,o)+";")}else if(Array.isArray(s)&&typeof s[0]=="string"&&t==null)for(var l=0;l<s.length;l++)Es(s[l])&&(n+=ki(a)+":"+Cs(a,s[l])+";");else{var d=Yn(e,t,s);switch(a){case"animation":case"animationName":{n+=ki(a)+":"+d+";";break}default:n+=a+"{"+d+"}"}}}return n}var Ts=/label:\s*([^\s;{]+)\s*(;|$)/g,Kt;function Sp(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="";Kt=void 0;var a=e[0];if(a==null||a.raw===void 0)n=!1,i+=Yn(r,t,a);else{var s=a;i+=s[0]}for(var o=1;o<e.length;o++)if(i+=Yn(r,t,e[o]),n){var l=a;i+=l[o]}Ts.lastIndex=0;for(var d="",u;(u=Ts.exec(i))!==null;)d+="-"+u[1];var f=yp(i)+d;return{name:f,styles:i,next:Kt}}/**
40
+ `)),()=>{})}function Ta(e){return bn(e,"spacing",8,"spacing")}function wn(e,t){return typeof t=="string"||t==null?t:e(t)}function $u(e,t){return r=>e.reduce((n,i)=>(n[i]=wn(t,r),n),{})}function Du(e,t,r,n){if(!t.includes(r))return null;const i=ju(r),a=$u(i,n),s=e[r];return $t(e,s,a)}function rl(e,t){const r=Ta(e.theme);return Object.keys(e).map(n=>Du(e,t,n,r)).reduce(cn,{})}function $e(e){return rl(e,ci)}$e.propTypes=process.env.NODE_ENV!=="production"?ci.reduce((e,t)=>(e[t]=Xt,e),{}):{};$e.filterProps=ci;function De(e){return rl(e,ui)}De.propTypes=process.env.NODE_ENV!=="production"?ui.reduce((e,t)=>(e[t]=Xt,e),{}):{};De.filterProps=ui;process.env.NODE_ENV!=="production"&&Ru.reduce((e,t)=>(e[t]=Xt,e),{});function pi(...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]?cn(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 lt(e){return typeof e!="number"?e:`${e}px solid`}function ct(e,t){return ze({prop:e,themeKey:"borders",transform:t})}const Pu=ct("border",lt),Iu=ct("borderTop",lt),Mu=ct("borderRight",lt),zu=ct("borderBottom",lt),Vu=ct("borderLeft",lt),Nu=ct("borderColor"),Bu=ct("borderTopColor"),Lu=ct("borderRightColor"),qu=ct("borderBottomColor"),Uu=ct("borderLeftColor"),Wu=ct("outline",lt),Hu=ct("outlineColor"),di=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=bn(e.theme,"shape.borderRadius",4,"borderRadius"),r=n=>({borderRadius:wn(t,n)});return $t(e,e.borderRadius,r)}return null};di.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:Xt}:{};di.filterProps=["borderRadius"];pi(Pu,Iu,Mu,zu,Vu,Nu,Bu,Lu,qu,Uu,di,Wu,Hu);const fi=e=>{if(e.gap!==void 0&&e.gap!==null){const t=bn(e.theme,"spacing",8,"gap"),r=n=>({gap:wn(t,n)});return $t(e,e.gap,r)}return null};fi.propTypes=process.env.NODE_ENV!=="production"?{gap:Xt}:{};fi.filterProps=["gap"];const mi=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=bn(e.theme,"spacing",8,"columnGap"),r=n=>({columnGap:wn(t,n)});return $t(e,e.columnGap,r)}return null};mi.propTypes=process.env.NODE_ENV!=="production"?{columnGap:Xt}:{};mi.filterProps=["columnGap"];const hi=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=bn(e.theme,"spacing",8,"rowGap"),r=n=>({rowGap:wn(t,n)});return $t(e,e.rowGap,r)}return null};hi.propTypes=process.env.NODE_ENV!=="production"?{rowGap:Xt}:{};hi.filterProps=["rowGap"];const Ku=ze({prop:"gridColumn"}),Qu=ze({prop:"gridRow"}),Yu=ze({prop:"gridAutoFlow"}),Gu=ze({prop:"gridAutoColumns"}),Zu=ze({prop:"gridAutoRows"}),Xu=ze({prop:"gridTemplateColumns"}),Ju=ze({prop:"gridTemplateRows"}),ep=ze({prop:"gridTemplateAreas"}),tp=ze({prop:"gridArea"});pi(fi,mi,hi,Ku,Qu,Yu,Gu,Zu,Xu,Ju,ep,tp);function $r(e,t){return t==="grey"?t:e}const rp=ze({prop:"color",themeKey:"palette",transform:$r}),np=ze({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:$r}),ip=ze({prop:"backgroundColor",themeKey:"palette",transform:$r});pi(rp,np,ip);function tt(e){return e<=1&&e!==0?`${e*100}%`:e}const ap=ze({prop:"width",transform:tt}),ka=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=r=>{var i,a,s,o,l;const n=((s=(a=(i=e.theme)==null?void 0:i.breakpoints)==null?void 0:a.values)==null?void 0:s[r])||oi[r];return n?((l=(o=e.theme)==null?void 0:o.breakpoints)==null?void 0:l.unit)!=="px"?{maxWidth:`${n}${e.theme.breakpoints.unit}`}:{maxWidth:n}:{maxWidth:tt(r)}};return $t(e,e.maxWidth,t)}return null};ka.filterProps=["maxWidth"];const sp=ze({prop:"minWidth",transform:tt}),op=ze({prop:"height",transform:tt}),lp=ze({prop:"maxHeight",transform:tt}),cp=ze({prop:"minHeight",transform:tt});ze({prop:"size",cssProperty:"width",transform:tt});ze({prop:"size",cssProperty:"height",transform:tt});const up=ze({prop:"boxSizing"});pi(ap,ka,sp,op,lp,cp,up);const Sn={border:{themeKey:"borders",transform:lt},borderTop:{themeKey:"borders",transform:lt},borderRight:{themeKey:"borders",transform:lt},borderBottom:{themeKey:"borders",transform:lt},borderLeft:{themeKey:"borders",transform:lt},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:lt},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:di},color:{themeKey:"palette",transform:$r},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:$r},backgroundColor:{themeKey:"palette",transform:$r},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:fi},rowGap:{style:hi},columnGap:{style:mi},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:tt},maxWidth:{style:ka},minWidth:{transform:tt},height:{transform:tt},maxHeight:{transform:tt},minHeight:{transform:tt},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 pp(...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 dp(e,t){return typeof e=="function"?e(t):e}function fp(){function e(r,n,i,a){const s={[r]:n,theme:i},o=a[r];if(!o)return{[r]:n};const{cssProperty:l=r,themeKey:f,transform:u,style:p}=o;if(n==null)return null;if(f==="typography"&&n==="inherit")return{[r]:n};const m=li(i,f)||{};return p?p(s):$t(s,n,w=>{let c=Qn(m,u,w);return w===c&&typeof w=="string"&&(c=Qn(m,u,`${r}${w==="default"?"":Re(w)}`,w)),l===!1?c:{[l]:c}})}function t(r){const{sx:n,theme:i={}}=r||{};if(!n)return null;const a=i.unstable_sxConfig??Sn;function s(o){let l=o;if(typeof o=="function")l=o(i);else if(typeof o!="object")return o;if(!l)return null;const f=Cu(i.breakpoints),u=Object.keys(f);let p=f;return Object.keys(l).forEach(m=>{const x=dp(l[m],i);if(x!=null)if(typeof x=="object")if(a[m])p=cn(p,e(m,x,i,a));else{const w=$t({theme:i},x,c=>({[m]:c}));pp(w,x)?p[m]=t({sx:x,theme:i}):p=cn(p,w)}else p=cn(p,e(m,x,i,a))}),wu(i,Ou(u,p))}return Array.isArray(n)?n.map(s):s(n)}return t}const Hr=fp();Hr.filterProps=["sx"];const mp=e=>{var n;const t={systemProps:{},otherProps:{}},r=((n=e==null?void 0:e.theme)==null?void 0:n.unstable_sxConfig)??Sn;return Object.keys(e).forEach(i=>{r[i]?t.systemProps[i]=e[i]:t.otherProps[i]=e[i]}),t};function hp(e){const{sx:t,...r}=e,{systemProps:n,otherProps:i}=mp(r);let a;return Array.isArray(t)?a=[n,...t]:typeof t=="function"?a=(...s)=>{const o=t(...s);return Tt(o)?{...n,...o}:n}:a={...n,...t},{...i,sx:a}}function yp(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 gp={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 vp(e){var t=Object.create(null);return function(r){return t[r]===void 0&&(t[r]=e(r)),t[r]}}var xp=/[A-Z]|^ms/g,bp=/_EMO_([^_]+?)_([^]*?)_EMO_/g,nl=function(t){return t.charCodeAt(1)===45},Es=function(t){return t!=null&&typeof t!="boolean"},Ci=vp(function(e){return nl(e)?e:e.replace(xp,"-$&").toLowerCase()}),Ts=function(t,r){switch(t){case"animation":case"animationName":if(typeof r=="string")return r.replace(bp,function(n,i,a){return Kt={name:i,styles:a,next:Kt},i})}return gp[t]!==1&&!nl(t)&&typeof r=="number"&&r!==0?r+"px":r};function Yn(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 Kt={name:i.name,styles:i.styles,next:Kt},i.name;var a=r;if(a.styles!==void 0){var s=a.next;if(s!==void 0)for(;s!==void 0;)Kt={name:s.name,styles:s.styles,next:Kt},s=s.next;var o=a.styles+";";return o}return wp(e,t,r)}}var l=r;return l}function wp(e,t,r){var n="";if(Array.isArray(r))for(var i=0;i<r.length;i++)n+=Yn(e,t,r[i])+";";else for(var a in r){var s=r[a];if(typeof s!="object"){var o=s;Es(o)&&(n+=Ci(a)+":"+Ts(a,o)+";")}else if(Array.isArray(s)&&typeof s[0]=="string"&&t==null)for(var l=0;l<s.length;l++)Es(s[l])&&(n+=Ci(a)+":"+Ts(a,s[l])+";");else{var f=Yn(e,t,s);switch(a){case"animation":case"animationName":{n+=Ci(a)+":"+f+";";break}default:n+=a+"{"+f+"}"}}}return n}var ks=/label:\s*([^\s;{]+)\s*(;|$)/g,Kt;function Sp(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="";Kt=void 0;var a=e[0];if(a==null||a.raw===void 0)n=!1,i+=Yn(r,t,a);else{var s=a;i+=s[0]}for(var o=1;o<e.length;o++)if(i+=Yn(r,t,e[o]),n){var l=a;i+=l[o]}ks.lastIndex=0;for(var f="",u;(u=ks.exec(i))!==null;)f+="-"+u[1];var p=yp(i)+f;return{name:p,styles:i,next:Kt}}/**
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 Ep(e,t){const r=ac(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 Cp(e,t){Array.isArray(e.__emotion_styles)&&(e.__emotion_styles=t(e.__emotion_styles))}const ks=[];function Os(e){return ks[0]=e,Sp(ks)}const Tp=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 kp(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:r="px",step:n=5,...i}=e,a=Tp(t),s=Object.keys(a);function o(m){return`@media (min-width:${typeof t[m]=="number"?t[m]:m}${r})`}function l(m){return`@media (max-width:${(typeof t[m]=="number"?t[m]:m)-n/100}${r})`}function d(m,x){const S=s.indexOf(x);return`@media (min-width:${typeof t[m]=="number"?t[m]:m}${r}) and (max-width:${(S!==-1&&typeof t[s[S]]=="number"?t[s[S]]:x)-n/100}${r})`}function u(m){return s.indexOf(m)+1<s.length?d(m,s[s.indexOf(m)+1]):o(m)}function f(m){const x=s.indexOf(m);return x===0?o(s[1]):x===s.length-1?l(s[x]):d(m,s[s.indexOf(m)+1]).replace("@media","@media not all and")}return{keys:s,values:a,up:o,down:l,between:d,only:u,not:f,unit:r,...i}}const Op={borderRadius:4};function il(e=8,t=Ca({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 s=t(a);return typeof s=="number"?`${s}px`:s}).join(" "));return r.mui=!0,r}function _p(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 al(e={},...t){const{breakpoints:r={},palette:n={},spacing:i,shape:a={},...s}=e,o=kp(r),l=il(i);let d=rt({breakpoints:o,direction:"ltr",components:{},palette:{mode:"light",...n},spacing:l,shape:{...Op,...a}},s);return d=Cu(d),d.applyStyles=_p,d=t.reduce((u,f)=>rt(u,f),d),d.unstable_sxConfig={...Sn,...s==null?void 0:s.unstable_sxConfig},d.unstable_sx=function(f){return Hr({sx:f,theme:this})},d}const _s=e=>e,Ap=()=>{let e=_s;return{configure(t){e=t},generate(t){return e(t)},reset(){e=_s}}},Fp=Ap(),jp={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 Jt(e,t,r="Mui"){const n=jp[t];return n?`${r}-${n}`:`${Fp.generate(e)}-${t}`}function xr(e,t,r="Mui"){const n={};return t.forEach(i=>{n[i]=Jt(e,i,r)}),n}function sl(e,t=""){return e.displayName||e.name||t}function As(e,t,r){const n=sl(t);return e.displayName||(n!==""?`${r}(${n})`:r)}function Rp(e){if(e!=null){if(typeof e=="string")return e;if(typeof e=="function")return sl(e,"Component");if(typeof e=="object")switch(e.$$typeof){case Kn.ForwardRef:return As(e,e.render,"ForwardRef");case Kn.Memo:return As(e,e.type,"memo");default:return}}}function ol(e){const{variants:t,...r}=e,n={variants:t,style:Os(r),isProcessed:!0};return n.style===r||t&&t.forEach(i=>{typeof i.style!="function"&&(i.style=Os(i.style))}),n}const $p=al();function Oi(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}function Dp(e){return e?(t,r)=>r[e]:null}function Pp(e,t,r){e.theme=Vp(e.theme)?r:e.theme[t]||e.theme}function In(e,t){const r=typeof t=="function"?t(e):t;if(Array.isArray(r))return r.flatMap(n=>In(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 ll(e,r.variants,[n])}return r!=null&&r.isProcessed?r.style:r}function ll(e,t,r=[]){var i;let n;e:for(let a=0;a<t.length;a+=1){const s=t[a];if(typeof s.props=="function"){if(n??(n={...e,...e.ownerState,ownerState:e.ownerState}),!s.props(n))continue}else for(const o in s.props)if(e[o]!==s.props[o]&&((i=e.ownerState)==null?void 0:i[o])!==s.props[o])continue e;typeof s.style=="function"?(n??(n={...e,...e.ownerState,ownerState:e.ownerState}),r.push(s.style(n))):r.push(s.style)}return r}function Ip(e={}){const{themeId:t,defaultTheme:r=$p,rootShouldForwardProp:n=Oi,slotShouldForwardProp:i=Oi}=e;function a(o){Pp(o,t,r)}return(o,l={})=>{Cp(o,w=>w.filter(F=>F!==Hr));const{name:d,slot:u,skipVariantsResolver:f,skipSx:m,overridesResolver:x=Dp(cl(u)),...S}=l,c=f!==void 0?f:u&&u!=="Root"&&u!=="root"||!1,E=m||!1;let h=Oi;u==="Root"||u==="root"?h=n:u?h=i:Np(o)&&(h=void 0);const _=Ep(o,{shouldForwardProp:h,label:zp(d,u),...S}),$=w=>{if(w.__emotion_real===w)return w;if(typeof w=="function")return function(X){return In(X,w)};if(Ct(w)){const F=ol(w);return F.variants?function(J){return In(J,F)}:F.style}return w},T=(...w)=>{const F=[],X=w.map($),J=[];if(F.push(a),d&&x&&J.push(function(V){var le,ce;const z=(ce=(le=V.theme.components)==null?void 0:le[d])==null?void 0:ce.styleOverrides;if(!z)return null;const H={};for(const pe in z)H[pe]=In(V,z[pe]);return x(V,H)}),d&&!c&&J.push(function(V){var H,le;const B=V.theme,z=(le=(H=B==null?void 0:B.components)==null?void 0:H[d])==null?void 0:le.variants;return z?ll(V,z):null}),E||J.push(Hr),Array.isArray(X[0])){const R=X.shift(),V=new Array(F.length).fill(""),B=new Array(J.length).fill("");let z;z=[...V,...R,...B],z.raw=[...V,...R.raw,...B],F.unshift(z)}const W=[...F,...X,...J],p=_(...W);return o.muiName&&(p.muiName=o.muiName),process.env.NODE_ENV!=="production"&&(p.displayName=Mp(d,u,o)),p};return _.withConfig&&(T.withConfig=_.withConfig),T}}function Mp(e,t,r){return e?`${e}${Fe(t||"")}`:`Styled(${Rp(r)})`}function zp(e,t){let r;return process.env.NODE_ENV!=="production"&&e&&(r=`${e}-${cl(t||"Root")}`),r}function Vp(e){for(const t in e)return!1;return!0}function Np(e){return typeof e=="string"&&e.charCodeAt(0)>96}function cl(e){return e&&e.charAt(0).toLowerCase()+e.slice(1)}function Gi(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],s=t[i];if(!s)r[i]=a||{};else if(!a)r[i]=s;else{r[i]={...s};for(const o in a)if(Object.prototype.hasOwnProperty.call(a,o)){const l=o;r[i][l]=Gi(a[l],s[l])}}}else r[i]===void 0&&(r[i]=e[i])}return r}const Bp=typeof window<"u"?ie.useLayoutEffect:ie.useEffect;function Lp(e,t=Number.MIN_SAFE_INTEGER,r=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,r))}function ka(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}].`),Lp(e,t,r)}function qp(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 Zt(e){if(e.type)return e;if(e.charAt(0)==="#")return Zt(qp(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 Tp(e,t){Array.isArray(e.__emotion_styles)&&(e.__emotion_styles=t(e.__emotion_styles))}const Cs=[];function Os(e){return Cs[0]=e,Sp(Cs)}const kp=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 Cp(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:r="px",step:n=5,...i}=e,a=kp(t),s=Object.keys(a);function o(m){return`@media (min-width:${typeof t[m]=="number"?t[m]:m}${r})`}function l(m){return`@media (max-width:${(typeof t[m]=="number"?t[m]:m)-n/100}${r})`}function f(m,x){const w=s.indexOf(x);return`@media (min-width:${typeof t[m]=="number"?t[m]:m}${r}) and (max-width:${(w!==-1&&typeof t[s[w]]=="number"?t[s[w]]:x)-n/100}${r})`}function u(m){return s.indexOf(m)+1<s.length?f(m,s[s.indexOf(m)+1]):o(m)}function p(m){const x=s.indexOf(m);return x===0?o(s[1]):x===s.length-1?l(s[x]):f(m,s[s.indexOf(m)+1]).replace("@media","@media not all and")}return{keys:s,values:a,up:o,down:l,between:f,only:u,not:p,unit:r,...i}}const Op={borderRadius:4};function il(e=8,t=Ta({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 s=t(a);return typeof s=="number"?`${s}px`:s}).join(" "));return r.mui=!0,r}function _p(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 al(e={},...t){const{breakpoints:r={},palette:n={},spacing:i,shape:a={},...s}=e,o=Cp(r),l=il(i);let f=rt({breakpoints:o,direction:"ltr",components:{},palette:{mode:"light",...n},spacing:l,shape:{...Op,...a}},s);return f=Tu(f),f.applyStyles=_p,f=t.reduce((u,p)=>rt(u,p),f),f.unstable_sxConfig={...Sn,...s==null?void 0:s.unstable_sxConfig},f.unstable_sx=function(p){return Hr({sx:p,theme:this})},f}const _s=e=>e,Ap=()=>{let e=_s;return{configure(t){e=t},generate(t){return e(t)},reset(){e=_s}}},Fp=Ap(),jp={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 Jt(e,t,r="Mui"){const n=jp[t];return n?`${r}-${n}`:`${Fp.generate(e)}-${t}`}function xr(e,t,r="Mui"){const n={};return t.forEach(i=>{n[i]=Jt(e,i,r)}),n}function sl(e,t=""){return e.displayName||e.name||t}function As(e,t,r){const n=sl(t);return e.displayName||(n!==""?`${r}(${n})`:r)}function Rp(e){if(e!=null){if(typeof e=="string")return e;if(typeof e=="function")return sl(e,"Component");if(typeof e=="object")switch(e.$$typeof){case Kn.ForwardRef:return As(e,e.render,"ForwardRef");case Kn.Memo:return As(e,e.type,"memo");default:return}}}function ol(e){const{variants:t,...r}=e,n={variants:t,style:Os(r),isProcessed:!0};return n.style===r||t&&t.forEach(i=>{typeof i.style!="function"&&(i.style=Os(i.style))}),n}const $p=al();function Oi(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}function Dp(e){return e?(t,r)=>r[e]:null}function Pp(e,t,r){e.theme=Vp(e.theme)?r:e.theme[t]||e.theme}function In(e,t){const r=typeof t=="function"?t(e):t;if(Array.isArray(r))return r.flatMap(n=>In(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 ll(e,r.variants,[n])}return r!=null&&r.isProcessed?r.style:r}function ll(e,t,r=[]){var i;let n;e:for(let a=0;a<t.length;a+=1){const s=t[a];if(typeof s.props=="function"){if(n??(n={...e,...e.ownerState,ownerState:e.ownerState}),!s.props(n))continue}else for(const o in s.props)if(e[o]!==s.props[o]&&((i=e.ownerState)==null?void 0:i[o])!==s.props[o])continue e;typeof s.style=="function"?(n??(n={...e,...e.ownerState,ownerState:e.ownerState}),r.push(s.style(n))):r.push(s.style)}return r}function Ip(e={}){const{themeId:t,defaultTheme:r=$p,rootShouldForwardProp:n=Oi,slotShouldForwardProp:i=Oi}=e;function a(o){Pp(o,t,r)}return(o,l={})=>{Tp(o,b=>b.filter(L=>L!==Hr));const{name:f,slot:u,skipVariantsResolver:p,skipSx:m,overridesResolver:x=Dp(cl(u)),...w}=l,c=p!==void 0?p:u&&u!=="Root"&&u!=="root"||!1,E=m||!1;let y=Oi;u==="Root"||u==="root"?y=n:u?y=i:Np(o)&&(y=void 0);const C=Ep(o,{shouldForwardProp:y,label:zp(f,u),...w}),A=b=>{if(b.__emotion_real===b)return b;if(typeof b=="function")return function(j){return In(j,b)};if(Tt(b)){const L=ol(b);return L.variants?function(ee){return In(ee,L)}:L.style}return b},_=(...b)=>{const L=[],j=b.map(A),ee=[];if(L.push(a),f&&x&&ee.push(function(P){var re,me;const N=(me=(re=P.theme.components)==null?void 0:re[f])==null?void 0:me.styleOverrides;if(!N)return null;const Y={};for(const ce in N)Y[ce]=In(P,N[ce]);return x(P,Y)}),f&&!c&&ee.push(function(P){var Y,re;const q=P.theme,N=(re=(Y=q==null?void 0:q.components)==null?void 0:Y[f])==null?void 0:re.variants;return N?ll(P,N):null}),E||ee.push(Hr),Array.isArray(j[0])){const z=j.shift(),P=new Array(L.length).fill(""),q=new Array(ee.length).fill("");let N;N=[...P,...z,...q],N.raw=[...P,...z.raw,...q],L.unshift(N)}const K=[...L,...j,...ee],d=C(...K);return o.muiName&&(d.muiName=o.muiName),process.env.NODE_ENV!=="production"&&(d.displayName=Mp(f,u,o)),d};return C.withConfig&&(_.withConfig=C.withConfig),_}}function Mp(e,t,r){return e?`${e}${Re(t||"")}`:`Styled(${Rp(r)})`}function zp(e,t){let r;return process.env.NODE_ENV!=="production"&&e&&(r=`${e}-${cl(t||"Root")}`),r}function Vp(e){for(const t in e)return!1;return!0}function Np(e){return typeof e=="string"&&e.charCodeAt(0)>96}function cl(e){return e&&e.charAt(0).toLowerCase()+e.slice(1)}function Gi(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],s=t[i];if(!s)r[i]=a||{};else if(!a)r[i]=s;else{r[i]={...s};for(const o in a)if(Object.prototype.hasOwnProperty.call(a,o)){const l=o;r[i][l]=Gi(a[l],s[l])}}}else r[i]===void 0&&(r[i]=e[i])}return r}const Bp=typeof window<"u"?ie.useLayoutEffect:ie.useEffect;function Lp(e,t=Number.MIN_SAFE_INTEGER,r=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,r))}function Ca(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}].`),Lp(e,t,r)}function qp(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 Zt(e){if(e.type)return e;if(e.charAt(0)==="#")return Zt(qp(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().`:Gt(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.`:Gt(10,i))}else n=n.split(",");return n=n.map(a=>parseFloat(a)),{type:r,values:n,colorSpace:i}}const Up=e=>{const t=Zt(e);return t.values.slice(0,3).map((r,n)=>t.type.includes("hsl")&&n!==0?`${r}%`:r).join(" ")},nn=(e,t)=>{try{return Up(e)}catch{return t&&process.env.NODE_ENV!=="production"&&console.warn(t),e}};function yi(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 ul(e){e=Zt(e);const{values:t}=e,r=t[0],n=t[1]/100,i=t[2]/100,a=n*Math.min(i,1-i),s=(d,u=(d+r/30)%12)=>i-a*Math.max(Math.min(u-3,9-u,1),-1);let o="rgb";const l=[Math.round(s(0)*255),Math.round(s(8)*255),Math.round(s(4)*255)];return e.type==="hsla"&&(o+="a",l.push(t[3])),yi({type:o,values:l})}function Zi(e){e=Zt(e);let t=e.type==="hsl"||e.type==="hsla"?Zt(ul(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 Fs(e,t){const r=Zi(e),n=Zi(t);return(Math.max(r,n)+.05)/(Math.min(r,n)+.05)}function Gn(e,t){return e=Zt(e),t=ka(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,yi(e)}function An(e,t,r){try{return Gn(e,t)}catch{return e}}function Oa(e,t){if(e=Zt(e),t=ka(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 yi(e)}function ke(e,t,r){try{return Oa(e,t)}catch{return e}}function _a(e,t){if(e=Zt(e),t=ka(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 yi(e)}function Oe(e,t,r){try{return _a(e,t)}catch{return e}}function Wp(e,t=.15){return Zi(e)>.5?Oa(e,t):_a(e,t)}function Fn(e,t,r){try{return Wp(e,t)}catch{return e}}const Hp=ie.createContext(void 0);process.env.NODE_ENV!=="production"&&(g.node,g.object);function Kp(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?Gi(i.defaultProps,n):!i.styleOverrides&&!i.variants?Gi(i,n):n}function Qp({props:e,name:t}){const r=ie.useContext(Hp);return Kp({props:e,name:t,theme:{components:r}})}const js={theme:void 0};function Yp(e){let t,r;return function(i){let a=t;return(a===void 0||i.theme!==r)&&(js.theme=i.theme,a=ol(e(js)),t=a,r=i.theme),a}}function Gp(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 Rs=(e,t,r,n=[])=>{let i=e;t.forEach((a,s)=>{s===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])})},Zp=(e,t,r)=>{function n(i,a=[],s=[]){Object.entries(i).forEach(([o,l])=>{(!r||r&&!r([...a,o]))&&l!=null&&(typeof l=="object"&&Object.keys(l).length>0?n(l,[...a,o],Array.isArray(l)?[...s,o]:s):t([...a,o],l,s))})}n(e)},Xp=(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={},s={};return Zp(e,(o,l,d)=>{if((typeof l=="string"||typeof l=="number")&&(!n||!n(o,l))){const u=`--${r?`${r}-`:""}${o.join("-")}`,f=Xp(o,l);Object.assign(i,{[u]:f}),Rs(a,o,`var(${u})`,d),Rs(s,o,`var(${u}, ${f})`,d)}},o=>o[0]==="vars"),{css:i,vars:a,varsWithDefaults:s}}function Jp(e,t={}){const{getSelector:r=E,disableCssColorScheme:n,colorSchemeSelector:i}=t,{colorSchemes:a={},components:s,defaultColorScheme:o="light",...l}=e,{vars:d,css:u,varsWithDefaults:f}=_i(l,t);let m=f;const x={},{[o]:S,...c}=a;if(Object.entries(c||{}).forEach(([$,T])=>{const{vars:w,css:F,varsWithDefaults:X}=_i(T,t);m=rt(m,X),x[$]={css:F,vars:w}}),S){const{css:$,vars:T,varsWithDefaults:w}=_i(S,t);m=rt(m,w),x[o]={css:$,vars:T}}function E($,T){var F,X;let w=i;if(i==="class"&&(w=".%s"),i==="data"&&(w="[data-%s]"),i!=null&&i.startsWith("data-")&&!i.includes("%s")&&(w=`[${i}="%s"]`),$){if(w==="media")return e.defaultColorScheme===$?":root":{[`@media (prefers-color-scheme: ${((X=(F=a[$])==null?void 0:F.palette)==null?void 0:X.mode)||$})`]:{":root":T}};if(w)return e.defaultColorScheme===$?`:root, ${w.replace("%s",String($))}`:w.replace("%s",String($))}return":root"}return{vars:m,generateThemeVars:()=>{let $={...d};return Object.entries(x).forEach(([,{vars:T}])=>{$=rt($,T)}),$},generateStyleSheets:()=>{var J,W;const $=[],T=e.defaultColorScheme||"light";function w(p,R){Object.keys(R).length&&$.push(typeof p=="string"?{[p]:{...R}}:p)}w(r(void 0,{...u}),u);const{[T]:F,...X}=x;if(F){const{css:p}=F,R=(W=(J=a[T])==null?void 0:J.palette)==null?void 0:W.mode,V=!n&&R?{colorScheme:R,...p}:{...p};w(r(T,{...V}),V)}return Object.entries(X).forEach(([p,{css:R}])=>{var z,H;const V=(H=(z=a[p])==null?void 0:z.palette)==null?void 0:H.mode,B=!n&&V?{colorScheme:V,...R}:{...R};w(r(p,{...B}),B)}),$}}}function ed(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 dn={black:"#000",white:"#fff"},td={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"},kr={50:"#f3e5f5",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",700:"#7b1fa2"},Or={300:"#e57373",400:"#ef5350",500:"#f44336",700:"#d32f2f",800:"#c62828"},tn={300:"#ffb74d",400:"#ffa726",500:"#ff9800",700:"#f57c00",900:"#e65100"},_r={50:"#e3f2fd",200:"#90caf9",400:"#42a5f5",700:"#1976d2",800:"#1565c0"},Ar={300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",700:"#0288d1",900:"#01579b"},Fr={300:"#81c784",400:"#66bb6a",500:"#4caf50",700:"#388e3c",800:"#2e7d32",900:"#1b5e20"};function pl(){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:dn.white,default:dn.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 rd=pl();function dl(){return{text:{primary:dn.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:dn.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 $s=dl();function Ds(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=Oa(e.main,a)))}function nd(e="light"){return e==="dark"?{main:_r[200],light:_r[50],dark:_r[400]}:{main:_r[700],light:_r[400],dark:_r[800]}}function id(e="light"){return e==="dark"?{main:kr[200],light:kr[50],dark:kr[400]}:{main:kr[500],light:kr[300],dark:kr[700]}}function ad(e="light"){return e==="dark"?{main:Or[500],light:Or[300],dark:Or[700]}:{main:Or[700],light:Or[400],dark:Or[800]}}function sd(e="light"){return e==="dark"?{main:Ar[400],light:Ar[300],dark:Ar[700]}:{main:Ar[700],light:Ar[500],dark:Ar[900]}}function od(e="light"){return e==="dark"?{main:Fr[400],light:Fr[300],dark:Fr[700]}:{main:Fr[800],light:Fr[500],dark:Fr[900]}}function ld(e="light"){return e==="dark"?{main:tn[400],light:tn[300],dark:tn[700]}:{main:"#ed6c02",light:tn[500],dark:tn[900]}}function Aa(e){const{mode:t="light",contrastThreshold:r=3,tonalOffset:n=.2,...i}=e,a=e.primary||nd(t),s=e.secondary||id(t),o=e.error||ad(t),l=e.info||sd(t),d=e.success||od(t),u=e.warning||ld(t);function f(c){const E=Fs(c,$s.text.primary)>=r?$s.text.primary:rd.text.primary;if(process.env.NODE_ENV!=="production"){const h=Fs(c,E);h<3&&console.error([`MUI: The contrast ratio of ${h}:1 for ${E} 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 E}const m=({color:c,name:E,mainShade:h=500,lightShade:_=300,darkShade:$=700})=>{if(c={...c},!c.main&&c[h]&&(c.main=c[h]),!c.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${E?` (${E})`:""} provided to augmentColor(color) is invalid.
51
- The color object needs to have a \`main\` property or a \`${h}\` property.`:Gt(11,E?` (${E})`:"",h));if(typeof c.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${E?` (${E})`:""} provided to augmentColor(color) is invalid.
49
+ The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:Gt(10,i))}else n=n.split(",");return n=n.map(a=>parseFloat(a)),{type:r,values:n,colorSpace:i}}const Up=e=>{const t=Zt(e);return t.values.slice(0,3).map((r,n)=>t.type.includes("hsl")&&n!==0?`${r}%`:r).join(" ")},nn=(e,t)=>{try{return Up(e)}catch{return t&&process.env.NODE_ENV!=="production"&&console.warn(t),e}};function yi(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 ul(e){e=Zt(e);const{values:t}=e,r=t[0],n=t[1]/100,i=t[2]/100,a=n*Math.min(i,1-i),s=(f,u=(f+r/30)%12)=>i-a*Math.max(Math.min(u-3,9-u,1),-1);let o="rgb";const l=[Math.round(s(0)*255),Math.round(s(8)*255),Math.round(s(4)*255)];return e.type==="hsla"&&(o+="a",l.push(t[3])),yi({type:o,values:l})}function Zi(e){e=Zt(e);let t=e.type==="hsl"||e.type==="hsla"?Zt(ul(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 Fs(e,t){const r=Zi(e),n=Zi(t);return(Math.max(r,n)+.05)/(Math.min(r,n)+.05)}function Gn(e,t){return e=Zt(e),t=Ca(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,yi(e)}function An(e,t,r){try{return Gn(e,t)}catch{return e}}function Oa(e,t){if(e=Zt(e),t=Ca(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 yi(e)}function Ce(e,t,r){try{return Oa(e,t)}catch{return e}}function _a(e,t){if(e=Zt(e),t=Ca(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 yi(e)}function Oe(e,t,r){try{return _a(e,t)}catch{return e}}function Wp(e,t=.15){return Zi(e)>.5?Oa(e,t):_a(e,t)}function Fn(e,t,r){try{return Wp(e,t)}catch{return e}}const Hp=ie.createContext(void 0);process.env.NODE_ENV!=="production"&&(g.node,g.object);function Kp(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?Gi(i.defaultProps,n):!i.styleOverrides&&!i.variants?Gi(i,n):n}function Qp({props:e,name:t}){const r=ie.useContext(Hp);return Kp({props:e,name:t,theme:{components:r}})}const js={theme:void 0};function Yp(e){let t,r;return function(i){let a=t;return(a===void 0||i.theme!==r)&&(js.theme=i.theme,a=ol(e(js)),t=a,r=i.theme),a}}function Gp(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 Rs=(e,t,r,n=[])=>{let i=e;t.forEach((a,s)=>{s===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])})},Zp=(e,t,r)=>{function n(i,a=[],s=[]){Object.entries(i).forEach(([o,l])=>{(!r||r&&!r([...a,o]))&&l!=null&&(typeof l=="object"&&Object.keys(l).length>0?n(l,[...a,o],Array.isArray(l)?[...s,o]:s):t([...a,o],l,s))})}n(e)},Xp=(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={},s={};return Zp(e,(o,l,f)=>{if((typeof l=="string"||typeof l=="number")&&(!n||!n(o,l))){const u=`--${r?`${r}-`:""}${o.join("-")}`,p=Xp(o,l);Object.assign(i,{[u]:p}),Rs(a,o,`var(${u})`,f),Rs(s,o,`var(${u}, ${p})`,f)}},o=>o[0]==="vars"),{css:i,vars:a,varsWithDefaults:s}}function Jp(e,t={}){const{getSelector:r=E,disableCssColorScheme:n,colorSchemeSelector:i}=t,{colorSchemes:a={},components:s,defaultColorScheme:o="light",...l}=e,{vars:f,css:u,varsWithDefaults:p}=_i(l,t);let m=p;const x={},{[o]:w,...c}=a;if(Object.entries(c||{}).forEach(([A,_])=>{const{vars:b,css:L,varsWithDefaults:j}=_i(_,t);m=rt(m,j),x[A]={css:L,vars:b}}),w){const{css:A,vars:_,varsWithDefaults:b}=_i(w,t);m=rt(m,b),x[o]={css:A,vars:_}}function E(A,_){var L,j;let b=i;if(i==="class"&&(b=".%s"),i==="data"&&(b="[data-%s]"),i!=null&&i.startsWith("data-")&&!i.includes("%s")&&(b=`[${i}="%s"]`),A){if(b==="media")return e.defaultColorScheme===A?":root":{[`@media (prefers-color-scheme: ${((j=(L=a[A])==null?void 0:L.palette)==null?void 0:j.mode)||A})`]:{":root":_}};if(b)return e.defaultColorScheme===A?`:root, ${b.replace("%s",String(A))}`:b.replace("%s",String(A))}return":root"}return{vars:m,generateThemeVars:()=>{let A={...f};return Object.entries(x).forEach(([,{vars:_}])=>{A=rt(A,_)}),A},generateStyleSheets:()=>{var ee,K;const A=[],_=e.defaultColorScheme||"light";function b(d,z){Object.keys(z).length&&A.push(typeof d=="string"?{[d]:{...z}}:d)}b(r(void 0,{...u}),u);const{[_]:L,...j}=x;if(L){const{css:d}=L,z=(K=(ee=a[_])==null?void 0:ee.palette)==null?void 0:K.mode,P=!n&&z?{colorScheme:z,...d}:{...d};b(r(_,{...P}),P)}return Object.entries(j).forEach(([d,{css:z}])=>{var N,Y;const P=(Y=(N=a[d])==null?void 0:N.palette)==null?void 0:Y.mode,q=!n&&P?{colorScheme:P,...z}:{...z};b(r(d,{...q}),q)}),A}}}function ed(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 dn={black:"#000",white:"#fff"},td={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"},Cr={50:"#f3e5f5",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",700:"#7b1fa2"},Or={300:"#e57373",400:"#ef5350",500:"#f44336",700:"#d32f2f",800:"#c62828"},tn={300:"#ffb74d",400:"#ffa726",500:"#ff9800",700:"#f57c00",900:"#e65100"},_r={50:"#e3f2fd",200:"#90caf9",400:"#42a5f5",700:"#1976d2",800:"#1565c0"},Ar={300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",700:"#0288d1",900:"#01579b"},Fr={300:"#81c784",400:"#66bb6a",500:"#4caf50",700:"#388e3c",800:"#2e7d32",900:"#1b5e20"};function pl(){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:dn.white,default:dn.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 rd=pl();function dl(){return{text:{primary:dn.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:dn.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 $s=dl();function Ds(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=Oa(e.main,a)))}function nd(e="light"){return e==="dark"?{main:_r[200],light:_r[50],dark:_r[400]}:{main:_r[700],light:_r[400],dark:_r[800]}}function id(e="light"){return e==="dark"?{main:Cr[200],light:Cr[50],dark:Cr[400]}:{main:Cr[500],light:Cr[300],dark:Cr[700]}}function ad(e="light"){return e==="dark"?{main:Or[500],light:Or[300],dark:Or[700]}:{main:Or[700],light:Or[400],dark:Or[800]}}function sd(e="light"){return e==="dark"?{main:Ar[400],light:Ar[300],dark:Ar[700]}:{main:Ar[700],light:Ar[500],dark:Ar[900]}}function od(e="light"){return e==="dark"?{main:Fr[400],light:Fr[300],dark:Fr[700]}:{main:Fr[800],light:Fr[500],dark:Fr[900]}}function ld(e="light"){return e==="dark"?{main:tn[400],light:tn[300],dark:tn[700]}:{main:"#ed6c02",light:tn[500],dark:tn[900]}}function Aa(e){const{mode:t="light",contrastThreshold:r=3,tonalOffset:n=.2,...i}=e,a=e.primary||nd(t),s=e.secondary||id(t),o=e.error||ad(t),l=e.info||sd(t),f=e.success||od(t),u=e.warning||ld(t);function p(c){const E=Fs(c,$s.text.primary)>=r?$s.text.primary:rd.text.primary;if(process.env.NODE_ENV!=="production"){const y=Fs(c,E);y<3&&console.error([`MUI: The contrast ratio of ${y}:1 for ${E} 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 E}const m=({color:c,name:E,mainShade:y=500,lightShade:C=300,darkShade:A=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${E?` (${E})`:""} provided to augmentColor(color) is invalid.
51
+ The color object needs to have a \`main\` property or a \`${y}\` property.`:Gt(11,E?` (${E})`:"",y));if(typeof c.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${E?` (${E})`:""} 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
- } });`:Gt(12,E?` (${E})`:"",JSON.stringify(c.main)));return Ds(c,"light",_,n),Ds(c,"dark",$,n),c.contrastText||(c.contrastText=f(c.main)),c};let x;return t==="light"?x=pl():t==="dark"&&(x=dl()),process.env.NODE_ENV!=="production"&&(x||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),rt({common:{...dn},mode:t,primary:m({color:a,name:"primary"}),secondary:m({color:s,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:m({color:o,name:"error"}),warning:m({color:u,name:"warning"}),info:m({color:l,name:"info"}),success:m({color:d,name:"success"}),grey:td,contrastThreshold:r,getContrastText:f,augmentColor:m,tonalOffset:n,...x},i)}function cd(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 ud(e,t){return{toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}},...t}}function pd(e){return Math.round(e*1e5)/1e5}const Ps={textTransform:"uppercase"},Is='"Roboto", "Helvetica", "Arial", sans-serif';function dd(e,t){const{fontFamily:r=Is,fontSize:n=14,fontWeightLight:i=300,fontWeightRegular:a=400,fontWeightMedium:s=500,fontWeightBold:o=700,htmlFontSize:l=16,allVariants:d,pxToRem:u,...f}=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 m=n/14,x=u||(E=>`${E/l*m}rem`),S=(E,h,_,$,T)=>({fontFamily:r,fontWeight:E,fontSize:x(h),lineHeight:_,...r===Is?{letterSpacing:`${pd($/h)}em`}:{},...T,...d}),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(s,20,1.6,.15),subtitle1:S(a,16,1.75,.15),subtitle2:S(s,14,1.57,.1),body1:S(a,16,1.5,.15),body2:S(a,14,1.43,.15),button:S(s,14,1.75,.4,Ps),caption:S(a,12,1.66,.4),overline:S(a,12,2.66,1,Ps),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return rt({htmlFontSize:l,pxToRem:x,fontFamily:r,fontSize:n,fontWeightLight:i,fontWeightRegular:a,fontWeightMedium:s,fontWeightBold:o,...c},f,{clone:!1})}const fd=.2,md=.14,hd=.12;function _e(...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,${md})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${hd})`].join(",")}const yd=["none",_e(0,2,1,-1,0,1,1,0,0,1,3,0),_e(0,3,1,-2,0,2,2,0,0,1,5,0),_e(0,3,3,-2,0,3,4,0,0,1,8,0),_e(0,2,4,-1,0,4,5,0,0,1,10,0),_e(0,3,5,-1,0,5,8,0,0,1,14,0),_e(0,3,5,-1,0,6,10,0,0,1,18,0),_e(0,4,5,-2,0,7,10,1,0,2,16,1),_e(0,5,5,-3,0,8,10,1,0,3,14,2),_e(0,5,6,-3,0,9,12,1,0,3,16,2),_e(0,6,6,-3,0,10,14,1,0,4,18,3),_e(0,6,7,-4,0,11,15,1,0,4,20,3),_e(0,7,8,-4,0,12,17,2,0,5,22,4),_e(0,7,8,-4,0,13,19,2,0,5,24,4),_e(0,7,9,-4,0,14,21,2,0,5,26,4),_e(0,8,9,-5,0,15,22,2,0,6,28,5),_e(0,8,10,-5,0,16,24,2,0,6,30,5),_e(0,8,11,-5,0,17,26,2,0,6,32,5),_e(0,9,11,-5,0,18,28,2,0,7,34,6),_e(0,9,12,-6,0,19,29,2,0,7,36,6),_e(0,10,13,-6,0,20,31,3,0,8,38,7),_e(0,10,13,-6,0,21,33,3,0,8,40,7),_e(0,10,14,-6,0,22,35,3,0,8,42,7),_e(0,11,14,-7,0,23,36,3,0,9,44,8),_e(0,11,15,-7,0,24,38,3,0,9,46,8)],gd={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)"},vd={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Ms(e){return`${Math.round(e)}ms`}function xd(e){if(!e)return 0;const t=e/36;return Math.min(Math.round((4+15*t**.25+t/5)*10),3e3)}function bd(e){const t={...gd,...e.easing},r={...vd,...e.duration};return{getAutoHeightDuration:xd,create:(i=["all"],a={})=>{const{duration:s=r.standard,easing:o=t.easeInOut,delay:l=0,...d}=a;if(process.env.NODE_ENV!=="production"){const u=m=>typeof m=="string",f=m=>!Number.isNaN(parseFloat(m));!u(i)&&!Array.isArray(i)&&console.error('MUI: Argument "props" must be a string or Array.'),!f(s)&&!u(s)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${s}.`),u(o)||console.error('MUI: Argument "easing" must be a string.'),!f(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(d).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(d).join(",")}].`)}return(Array.isArray(i)?i:[i]).map(u=>`${u} ${typeof s=="string"?s:Ms(s)} ${o} ${typeof l=="string"?l:Ms(l)}`).join(",")},...e,easing:t,duration:r}}const wd={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500};function Sd(e){return Ct(e)||typeof e>"u"||typeof e=="string"||typeof e=="boolean"||typeof e=="number"||Array.isArray(e)}function fl(e={}){const t={...e};function r(n){const i=Object.entries(n);for(let a=0;a<i.length;a++){const[s,o]=i[a];!Sd(o)||s.startsWith("unstable_")?delete n[s]:Ct(o)&&(n[s]={...o},r(n[s]))}}return r(t),`import { unstable_createBreakpoints as createBreakpoints, createTransitions } from '@mui/material/styles';
64
+ } });`:Gt(12,E?` (${E})`:"",JSON.stringify(c.main)));return Ds(c,"light",C,n),Ds(c,"dark",A,n),c.contrastText||(c.contrastText=p(c.main)),c};let x;return t==="light"?x=pl():t==="dark"&&(x=dl()),process.env.NODE_ENV!=="production"&&(x||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),rt({common:{...dn},mode:t,primary:m({color:a,name:"primary"}),secondary:m({color:s,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:m({color:o,name:"error"}),warning:m({color:u,name:"warning"}),info:m({color:l,name:"info"}),success:m({color:f,name:"success"}),grey:td,contrastThreshold:r,getContrastText:p,augmentColor:m,tonalOffset:n,...x},i)}function cd(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 ud(e,t){return{toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}},...t}}function pd(e){return Math.round(e*1e5)/1e5}const Ps={textTransform:"uppercase"},Is='"Roboto", "Helvetica", "Arial", sans-serif';function dd(e,t){const{fontFamily:r=Is,fontSize:n=14,fontWeightLight:i=300,fontWeightRegular:a=400,fontWeightMedium:s=500,fontWeightBold:o=700,htmlFontSize:l=16,allVariants:f,pxToRem:u,...p}=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 m=n/14,x=u||(E=>`${E/l*m}rem`),w=(E,y,C,A,_)=>({fontFamily:r,fontWeight:E,fontSize:x(y),lineHeight:C,...r===Is?{letterSpacing:`${pd(A/y)}em`}:{},..._,...f}),c={h1:w(i,96,1.167,-1.5),h2:w(i,60,1.2,-.5),h3:w(a,48,1.167,0),h4:w(a,34,1.235,.25),h5:w(a,24,1.334,0),h6:w(s,20,1.6,.15),subtitle1:w(a,16,1.75,.15),subtitle2:w(s,14,1.57,.1),body1:w(a,16,1.5,.15),body2:w(a,14,1.43,.15),button:w(s,14,1.75,.4,Ps),caption:w(a,12,1.66,.4),overline:w(a,12,2.66,1,Ps),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return rt({htmlFontSize:l,pxToRem:x,fontFamily:r,fontSize:n,fontWeightLight:i,fontWeightRegular:a,fontWeightMedium:s,fontWeightBold:o,...c},p,{clone:!1})}const fd=.2,md=.14,hd=.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,${md})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${hd})`].join(",")}const yd=["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)],gd={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)"},vd={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Ms(e){return`${Math.round(e)}ms`}function xd(e){if(!e)return 0;const t=e/36;return Math.min(Math.round((4+15*t**.25+t/5)*10),3e3)}function bd(e){const t={...gd,...e.easing},r={...vd,...e.duration};return{getAutoHeightDuration:xd,create:(i=["all"],a={})=>{const{duration:s=r.standard,easing:o=t.easeInOut,delay:l=0,...f}=a;if(process.env.NODE_ENV!=="production"){const u=m=>typeof m=="string",p=m=>!Number.isNaN(parseFloat(m));!u(i)&&!Array.isArray(i)&&console.error('MUI: Argument "props" must be a string or Array.'),!p(s)&&!u(s)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${s}.`),u(o)||console.error('MUI: Argument "easing" must be a string.'),!p(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(f).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(f).join(",")}].`)}return(Array.isArray(i)?i:[i]).map(u=>`${u} ${typeof s=="string"?s:Ms(s)} ${o} ${typeof l=="string"?l:Ms(l)}`).join(",")},...e,easing:t,duration:r}}const wd={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500};function Sd(e){return Tt(e)||typeof e>"u"||typeof e=="string"||typeof e=="boolean"||typeof e=="number"||Array.isArray(e)}function fl(e={}){const t={...e};function r(n){const i=Object.entries(n);for(let a=0;a<i.length;a++){const[s,o]=i[a];!Sd(o)||s.startsWith("unstable_")?delete n[s]:Tt(o)&&(n[s]={...o},r(n[s]))}}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 Xi(e={},...t){const{breakpoints:r,mixins:n={},spacing:i,palette:a={},transitions:s={},typography:o={},shape:l,...d}=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.":Gt(20));const u=Aa(a),f=al(e);let m=rt(f,{mixins:ud(f.breakpoints,n),palette:u,shadows:yd.slice(),typography:dd(u,o),transitions:bd(s),zIndex:{...wd}});if(m=rt(m,d),m=t.reduce((x,S)=>rt(x,S),m),process.env.NODE_ENV!=="production"){const x=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],S=(c,E)=>{let h;for(h in c){const _=c[h];if(x.includes(h)&&Object.keys(_).length>0){if(process.env.NODE_ENV!=="production"){const $=Jt("",h);console.error([`MUI: The \`${E}\` component increases the CSS specificity of the \`${h}\` internal state.`,"You can not override it like this: ",JSON.stringify(c,null,2),"",`Instead, you need to use the '&.${$}' syntax:`,JSON.stringify({root:{[`&.${$}`]:_}},null,2),"","https://mui.com/r/state-classes-guide"].join(`
73
- `))}c[h]={}}}};Object.keys(m.components).forEach(c=>{const E=m.components[c].styleOverrides;E&&c.startsWith("Mui")&&S(E,c)})}return m.unstable_sxConfig={...Sn,...d==null?void 0:d.unstable_sxConfig},m.unstable_sx=function(S){return Hr({sx:S,theme:this})},m.toRuntimeSource=fl,m}function Ed(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 Cd=[...Array(25)].map((e,t)=>{if(t===0)return"none";const r=Ed(t);return`linear-gradient(rgba(255 255 255 / ${r}), rgba(255 255 255 / ${r}))`});function ml(e){return{inputPlaceholder:e==="dark"?.5:.42,inputUnderline:e==="dark"?.7:.42,switchTrackDisabled:e==="dark"?.2:.12,switchTrack:e==="dark"?.3:.38}}function hl(e){return e==="dark"?Cd:[]}function Td(e){const{palette:t={mode:"light"},opacity:r,overlays:n,...i}=e,a=Aa(t);return{palette:a,opacity:{...ml(a.mode),...r},overlays:n||hl(a.mode),...i}}function kd(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 Od=e=>[...[...Array(25)].map((t,r)=>`--${e?`${e}-`:""}overlays-${r}`),`--${e?`${e}-`:""}palette-AppBar-darkBg`,`--${e?`${e}-`:""}palette-AppBar-darkColor`],_d=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 s={};return Od(e.cssVarPrefix).forEach(o=>{s[o]=r[o],delete r[o]}),a==="media"?{[n]:r,"@media (prefers-color-scheme: dark)":{[n]:s}}:a?{[a.replace("%s",t)]:s,[`${n}, ${a.replace("%s",t)}`]:r}:{[n]:{...r,...s}}}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 Ad(e,t){t.forEach(r=>{e[r]||(e[r]={})})}function P(e,t,r){!e[t]&&r&&(e[t]=r)}function an(e){return typeof e!="string"||!e.startsWith("hsl")?e:ul(e)}function _t(e,t){`${t}Channel`in e||(e[`${t}Channel`]=nn(an(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 Fd(e){return typeof e=="number"?`${e}px`:typeof e=="string"||typeof e=="function"||Array.isArray(e)?e:"8px"}const vt=e=>{try{return e()}catch{}},jd=(e="mui")=>Gp(e);function Ai(e,t,r,n){if(!t)return;t=t===!0?{}:t;const i=n==="dark"?"dark":"light";if(!r){e[n]=Td({...t,palette:{mode:i,...t==null?void 0:t.palette}});return}const{palette:a,...s}=Xi({...r,palette:{mode:i,...t==null?void 0:t.palette}});return e[n]={...t,palette:a,opacity:{...ml(i),...t==null?void 0:t.opacity},overlays:(t==null?void 0:t.overlays)||hl(i)},s}function Rd(e={},...t){const{colorSchemes:r={light:!0},defaultColorScheme:n,disableCssColorScheme:i=!1,cssVarPrefix:a="mui",shouldSkipGeneratingVar:s=kd,colorSchemeSelector:o=r.light&&r.dark?"media":void 0,rootSelector:l=":root",...d}=e,u=Object.keys(r)[0],f=n||(r.light&&u!=="light"?"light":u),m=jd(a),{[f]:x,light:S,dark:c,...E}=r,h={...E};let _=x;if((f==="dark"&&!("dark"in r)||f==="light"&&!("light"in r))&&(_=!0),!_)throw new Error(process.env.NODE_ENV!=="production"?`MUI: The \`colorSchemes.${f}\` option is either missing or invalid.`:Gt(21,f));const $=Ai(h,_,d,f);S&&!h.light&&Ai(h,S,void 0,"light"),c&&!h.dark&&Ai(h,c,void 0,"dark");let T={defaultColorScheme:f,...$,cssVarPrefix:a,colorSchemeSelector:o,rootSelector:l,getCssVar:m,colorSchemes:h,font:{...cd($.typography),...$.font},spacing:Fd(d.spacing)};Object.keys(T.colorSchemes).forEach(W=>{const p=T.colorSchemes[W].palette,R=V=>{const B=V.split("-"),z=B[1],H=B[2];return m(V,p[z][H])};if(p.mode==="light"&&(P(p.common,"background","#fff"),P(p.common,"onBackground","#000")),p.mode==="dark"&&(P(p.common,"background","#000"),P(p.common,"onBackground","#fff")),Ad(p,["Alert","AppBar","Avatar","Button","Chip","FilledInput","LinearProgress","Skeleton","Slider","SnackbarContent","SpeedDialAction","StepConnector","StepContent","Switch","TableCell","Tooltip"]),p.mode==="light"){P(p.Alert,"errorColor",ke(p.error.light,.6)),P(p.Alert,"infoColor",ke(p.info.light,.6)),P(p.Alert,"successColor",ke(p.success.light,.6)),P(p.Alert,"warningColor",ke(p.warning.light,.6)),P(p.Alert,"errorFilledBg",R("palette-error-main")),P(p.Alert,"infoFilledBg",R("palette-info-main")),P(p.Alert,"successFilledBg",R("palette-success-main")),P(p.Alert,"warningFilledBg",R("palette-warning-main")),P(p.Alert,"errorFilledColor",vt(()=>p.getContrastText(p.error.main))),P(p.Alert,"infoFilledColor",vt(()=>p.getContrastText(p.info.main))),P(p.Alert,"successFilledColor",vt(()=>p.getContrastText(p.success.main))),P(p.Alert,"warningFilledColor",vt(()=>p.getContrastText(p.warning.main))),P(p.Alert,"errorStandardBg",Oe(p.error.light,.9)),P(p.Alert,"infoStandardBg",Oe(p.info.light,.9)),P(p.Alert,"successStandardBg",Oe(p.success.light,.9)),P(p.Alert,"warningStandardBg",Oe(p.warning.light,.9)),P(p.Alert,"errorIconColor",R("palette-error-main")),P(p.Alert,"infoIconColor",R("palette-info-main")),P(p.Alert,"successIconColor",R("palette-success-main")),P(p.Alert,"warningIconColor",R("palette-warning-main")),P(p.AppBar,"defaultBg",R("palette-grey-100")),P(p.Avatar,"defaultBg",R("palette-grey-400")),P(p.Button,"inheritContainedBg",R("palette-grey-300")),P(p.Button,"inheritContainedHoverBg",R("palette-grey-A100")),P(p.Chip,"defaultBorder",R("palette-grey-400")),P(p.Chip,"defaultAvatarColor",R("palette-grey-700")),P(p.Chip,"defaultIconColor",R("palette-grey-700")),P(p.FilledInput,"bg","rgba(0, 0, 0, 0.06)"),P(p.FilledInput,"hoverBg","rgba(0, 0, 0, 0.09)"),P(p.FilledInput,"disabledBg","rgba(0, 0, 0, 0.12)"),P(p.LinearProgress,"primaryBg",Oe(p.primary.main,.62)),P(p.LinearProgress,"secondaryBg",Oe(p.secondary.main,.62)),P(p.LinearProgress,"errorBg",Oe(p.error.main,.62)),P(p.LinearProgress,"infoBg",Oe(p.info.main,.62)),P(p.LinearProgress,"successBg",Oe(p.success.main,.62)),P(p.LinearProgress,"warningBg",Oe(p.warning.main,.62)),P(p.Skeleton,"bg",`rgba(${R("palette-text-primaryChannel")} / 0.11)`),P(p.Slider,"primaryTrack",Oe(p.primary.main,.62)),P(p.Slider,"secondaryTrack",Oe(p.secondary.main,.62)),P(p.Slider,"errorTrack",Oe(p.error.main,.62)),P(p.Slider,"infoTrack",Oe(p.info.main,.62)),P(p.Slider,"successTrack",Oe(p.success.main,.62)),P(p.Slider,"warningTrack",Oe(p.warning.main,.62));const V=Fn(p.background.default,.8);P(p.SnackbarContent,"bg",V),P(p.SnackbarContent,"color",vt(()=>p.getContrastText(V))),P(p.SpeedDialAction,"fabHoverBg",Fn(p.background.paper,.15)),P(p.StepConnector,"border",R("palette-grey-400")),P(p.StepContent,"border",R("palette-grey-400")),P(p.Switch,"defaultColor",R("palette-common-white")),P(p.Switch,"defaultDisabledColor",R("palette-grey-100")),P(p.Switch,"primaryDisabledColor",Oe(p.primary.main,.62)),P(p.Switch,"secondaryDisabledColor",Oe(p.secondary.main,.62)),P(p.Switch,"errorDisabledColor",Oe(p.error.main,.62)),P(p.Switch,"infoDisabledColor",Oe(p.info.main,.62)),P(p.Switch,"successDisabledColor",Oe(p.success.main,.62)),P(p.Switch,"warningDisabledColor",Oe(p.warning.main,.62)),P(p.TableCell,"border",Oe(An(p.divider,1),.88)),P(p.Tooltip,"bg",An(p.grey[700],.92))}if(p.mode==="dark"){P(p.Alert,"errorColor",Oe(p.error.light,.6)),P(p.Alert,"infoColor",Oe(p.info.light,.6)),P(p.Alert,"successColor",Oe(p.success.light,.6)),P(p.Alert,"warningColor",Oe(p.warning.light,.6)),P(p.Alert,"errorFilledBg",R("palette-error-dark")),P(p.Alert,"infoFilledBg",R("palette-info-dark")),P(p.Alert,"successFilledBg",R("palette-success-dark")),P(p.Alert,"warningFilledBg",R("palette-warning-dark")),P(p.Alert,"errorFilledColor",vt(()=>p.getContrastText(p.error.dark))),P(p.Alert,"infoFilledColor",vt(()=>p.getContrastText(p.info.dark))),P(p.Alert,"successFilledColor",vt(()=>p.getContrastText(p.success.dark))),P(p.Alert,"warningFilledColor",vt(()=>p.getContrastText(p.warning.dark))),P(p.Alert,"errorStandardBg",ke(p.error.light,.9)),P(p.Alert,"infoStandardBg",ke(p.info.light,.9)),P(p.Alert,"successStandardBg",ke(p.success.light,.9)),P(p.Alert,"warningStandardBg",ke(p.warning.light,.9)),P(p.Alert,"errorIconColor",R("palette-error-main")),P(p.Alert,"infoIconColor",R("palette-info-main")),P(p.Alert,"successIconColor",R("palette-success-main")),P(p.Alert,"warningIconColor",R("palette-warning-main")),P(p.AppBar,"defaultBg",R("palette-grey-900")),P(p.AppBar,"darkBg",R("palette-background-paper")),P(p.AppBar,"darkColor",R("palette-text-primary")),P(p.Avatar,"defaultBg",R("palette-grey-600")),P(p.Button,"inheritContainedBg",R("palette-grey-800")),P(p.Button,"inheritContainedHoverBg",R("palette-grey-700")),P(p.Chip,"defaultBorder",R("palette-grey-700")),P(p.Chip,"defaultAvatarColor",R("palette-grey-300")),P(p.Chip,"defaultIconColor",R("palette-grey-300")),P(p.FilledInput,"bg","rgba(255, 255, 255, 0.09)"),P(p.FilledInput,"hoverBg","rgba(255, 255, 255, 0.13)"),P(p.FilledInput,"disabledBg","rgba(255, 255, 255, 0.12)"),P(p.LinearProgress,"primaryBg",ke(p.primary.main,.5)),P(p.LinearProgress,"secondaryBg",ke(p.secondary.main,.5)),P(p.LinearProgress,"errorBg",ke(p.error.main,.5)),P(p.LinearProgress,"infoBg",ke(p.info.main,.5)),P(p.LinearProgress,"successBg",ke(p.success.main,.5)),P(p.LinearProgress,"warningBg",ke(p.warning.main,.5)),P(p.Skeleton,"bg",`rgba(${R("palette-text-primaryChannel")} / 0.13)`),P(p.Slider,"primaryTrack",ke(p.primary.main,.5)),P(p.Slider,"secondaryTrack",ke(p.secondary.main,.5)),P(p.Slider,"errorTrack",ke(p.error.main,.5)),P(p.Slider,"infoTrack",ke(p.info.main,.5)),P(p.Slider,"successTrack",ke(p.success.main,.5)),P(p.Slider,"warningTrack",ke(p.warning.main,.5));const V=Fn(p.background.default,.98);P(p.SnackbarContent,"bg",V),P(p.SnackbarContent,"color",vt(()=>p.getContrastText(V))),P(p.SpeedDialAction,"fabHoverBg",Fn(p.background.paper,.15)),P(p.StepConnector,"border",R("palette-grey-600")),P(p.StepContent,"border",R("palette-grey-600")),P(p.Switch,"defaultColor",R("palette-grey-300")),P(p.Switch,"defaultDisabledColor",R("palette-grey-600")),P(p.Switch,"primaryDisabledColor",ke(p.primary.main,.55)),P(p.Switch,"secondaryDisabledColor",ke(p.secondary.main,.55)),P(p.Switch,"errorDisabledColor",ke(p.error.main,.55)),P(p.Switch,"infoDisabledColor",ke(p.info.main,.55)),P(p.Switch,"successDisabledColor",ke(p.success.main,.55)),P(p.Switch,"warningDisabledColor",ke(p.warning.main,.55)),P(p.TableCell,"border",ke(An(p.divider,1),.68)),P(p.Tooltip,"bg",An(p.grey[700],.92))}_t(p.background,"default"),_t(p.background,"paper"),_t(p.common,"background"),_t(p.common,"onBackground"),_t(p,"divider"),Object.keys(p).forEach(V=>{const B=p[V];V!=="tonalOffset"&&B&&typeof B=="object"&&(B.main&&P(p[V],"mainChannel",nn(an(B.main))),B.light&&P(p[V],"lightChannel",nn(an(B.light))),B.dark&&P(p[V],"darkChannel",nn(an(B.dark))),B.contrastText&&P(p[V],"contrastTextChannel",nn(an(B.contrastText))),V==="text"&&(_t(p[V],"primary"),_t(p[V],"secondary")),V==="action"&&(B.active&&_t(p[V],"active"),B.selected&&_t(p[V],"selected")))})}),T=t.reduce((W,p)=>rt(W,p),T);const w={prefix:a,disableCssColorScheme:i,shouldSkipGeneratingVar:s,getSelector:_d(T)},{vars:F,generateThemeVars:X,generateStyleSheets:J}=Jp(T,w);return T.vars=F,Object.entries(T.colorSchemes[T.defaultColorScheme]).forEach(([W,p])=>{T[W]=p}),T.generateThemeVars=X,T.generateStyleSheets=J,T.generateSpacing=function(){return il(d.spacing,Ca(this))},T.getColorSchemeSelector=ed(o),T.spacing=T.generateSpacing(),T.shouldSkipGeneratingVar=s,T.unstable_sxConfig={...Sn,...d==null?void 0:d.unstable_sxConfig},T.unstable_sx=function(p){return Hr({sx:p,theme:this})},T.toRuntimeSource=fl,T}function zs(e,t,r){e.colorSchemes&&r&&(e.colorSchemes[t]={...r!==!0&&r,palette:Aa({...r===!0?{}:r.palette,mode:t})})}function $d(e={},...t){const{palette:r,cssVariables:n=!1,colorSchemes:i=r?void 0:{light:!0},defaultColorScheme:a=r==null?void 0:r.mode,...s}=e,o=a||"light",l=i==null?void 0:i[o],d={...i,...r?{[o]:{...typeof l!="boolean"&&l,palette:r}}:void 0};if(n===!1){if(!("colorSchemes"in e))return Xi(e,...t);let u=r;"palette"in e||d[o]&&(d[o]!==!0?u=d[o].palette:o==="dark"&&(u={mode:"dark"}));const f=Xi({...e,palette:u},...t);return f.defaultColorScheme=o,f.colorSchemes=d,f.palette.mode==="light"&&(f.colorSchemes.light={...d.light!==!0&&d.light,palette:f.palette},zs(f,"dark",d.dark)),f.palette.mode==="dark"&&(f.colorSchemes.dark={...d.dark!==!0&&d.dark,palette:f.palette},zs(f,"light",d.light)),f}return!r&&!("light"in d)&&o==="light"&&(d.light=!0),Rd({...s,colorSchemes:d,defaultColorScheme:o,...typeof n!="boolean"&&n},...t)}const Dd=$d(),Pd="$$material";function Id(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const Md=e=>Id(e)&&e!=="classes",yt=Ip({themeId:Pd,defaultTheme:Dd,rootShouldForwardProp:Md});function zd(){return hp}const gr=Yp;process.env.NODE_ENV!=="production"&&(g.node,g.object.isRequired);function br(e){return Qp(e)}function Vd(e){return typeof e.main=="string"}function Nd(e,t=[]){if(!Vd(e))return!1;for(const r of t)if(!e.hasOwnProperty(r)||typeof e[r]!="string")return!1;return!0}function Zn(e=[]){return([,t])=>t&&Nd(t,e)}function Bd(e){return Jt("MuiTypography",e)}xr("MuiTypography",["root","h1","h2","h3","h4","h5","h6","subtitle1","subtitle2","body1","body2","inherit","button","caption","overline","alignLeft","alignRight","alignCenter","alignJustify","noWrap","gutterBottom","paragraph"]);const Ld={primary:!0,secondary:!0,error:!0,info:!0,success:!0,warning:!0,textPrimary:!0,textSecondary:!0,textDisabled:!0},qd=zd(),Ud=e=>{const{align:t,gutterBottom:r,noWrap:n,paragraph:i,variant:a,classes:s}=e,o={root:["root",a,e.align!=="inherit"&&`align${Fe(t)}`,r&&"gutterBottom",n&&"noWrap",i&&"paragraph"]};return Qr(o,Bd,s)},Wd=yt("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${Fe(r.align)}`],r.noWrap&&t.noWrap,r.gutterBottom&&t.gutterBottom,r.paragraph&&t.paragraph]}})(gr(({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(Zn()).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${Fe(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}}]}})),Vs={h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",subtitle1:"h6",subtitle2:"h6",body1:"p",body2:"p",inherit:"p"},yl=ie.forwardRef(function(t,r){const{color:n,...i}=br({props:t,name:"MuiTypography"}),a=!Ld[n],s=qd({...i,...a&&{color:n}}),{align:o="inherit",className:l,component:d,gutterBottom:u=!1,noWrap:f=!1,paragraph:m=!1,variant:x="body1",variantMapping:S=Vs,...c}=s,E={...s,align:o,color:n,className:l,component:d,gutterBottom:u,noWrap:f,paragraph:m,variant:x,variantMapping:S},h=d||(m?"p":S[x]||Vs[x])||"span",_=Ud(E);return v.jsx(Wd,{as:h,ref:r,className:Ke(_.root,l),...c,ownerState:E,style:{...o!=="inherit"&&{"--Typography-textAlign":o},...c.style}})});process.env.NODE_ENV!=="production"&&(yl.propTypes={align:g.oneOf(["center","inherit","justify","left","right"]),children:g.node,classes:g.object,className:g.string,color:g.oneOfType([g.oneOf(["primary","secondary","success","error","info","warning","textPrimary","textSecondary","textDisabled"]),g.string]),component:g.elementType,gutterBottom:g.bool,noWrap:g.bool,paragraph:g.bool,style:g.object,sx:g.oneOfType([g.arrayOf(g.oneOfType([g.func,g.object,g.bool])),g.func,g.object]),variant:g.oneOfType([g.oneOf(["body1","body2","button","caption","h1","h2","h3","h4","h5","h6","inherit","overline","subtitle1","subtitle2"]),g.string]),variantMapping:g.object});const Fa=ie.createContext(void 0);process.env.NODE_ENV!=="production"&&(Fa.displayName="FormControlContext");function Hd(){return ie.useContext(Fa)}function Kd(e){return Jt("MuiInputAdornment",e)}const Ns=xr("MuiInputAdornment",["root","filled","standard","outlined","positionStart","positionEnd","disablePointerEvents","hiddenLabel","sizeSmall"]);var Bs;const Qd=(e,t)=>{const{ownerState:r}=e;return[t.root,t[`position${Fe(r.position)}`],r.disablePointerEvents===!0&&t.disablePointerEvents,t[r.variant]]},Yd=e=>{const{classes:t,disablePointerEvents:r,hiddenLabel:n,position:i,size:a,variant:s}=e,o={root:["root",r&&"disablePointerEvents",i&&`position${Fe(i)}`,s,n&&"hiddenLabel",a&&`size${Fe(a)}`]};return Qr(o,Kd,t)},Gd=yt("div",{name:"MuiInputAdornment",slot:"Root",overridesResolver:Qd})(gr(({theme:e})=>({display:"flex",maxHeight:"2em",alignItems:"center",whiteSpace:"nowrap",color:(e.vars||e).palette.action.active,variants:[{props:{variant:"filled"},style:{[`&.${Ns.positionStart}&:not(.${Ns.hiddenLabel})`]:{marginTop:16}}},{props:{position:"start"},style:{marginRight:8}},{props:{position:"end"},style:{marginLeft:8}},{props:{disablePointerEvents:!0},style:{pointerEvents:"none"}}]}))),gl=ie.forwardRef(function(t,r){const n=br({props:t,name:"MuiInputAdornment"}),{children:i,className:a,component:s="div",disablePointerEvents:o=!1,disableTypography:l=!1,position:d,variant:u,...f}=n,m=Hd()||{};let x=u;u&&m.variant&&process.env.NODE_ENV!=="production"&&u===m.variant&&console.error("MUI: The `InputAdornment` variant infers the variant prop you do not have to provide one."),m&&!x&&(x=m.variant);const S={...n,hiddenLabel:m.hiddenLabel,size:m.size,disablePointerEvents:o,position:d,variant:x},c=Yd(S);return v.jsx(Fa.Provider,{value:null,children:v.jsx(Gd,{as:s,ownerState:S,className:Ke(c.root,a),ref:r,...f,children:typeof i=="string"&&!l?v.jsx(yl,{color:"textSecondary",children:i}):v.jsxs(ie.Fragment,{children:[d==="start"?Bs||(Bs=v.jsx("span",{className:"notranslate","aria-hidden":!0,children:"​"})):null,i]})})})});process.env.NODE_ENV!=="production"&&(gl.propTypes={children:g.node,classes:g.object,className:g.string,component:g.elementType,disablePointerEvents:g.bool,disableTypography:g.bool,position:g.oneOf(["end","start"]).isRequired,sx:g.oneOfType([g.arrayOf(g.oneOfType([g.func,g.object,g.bool])),g.func,g.object]),variant:g.oneOf(["filled","outlined","standard"])});function ja(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...n){return e(...n)||t(...n)}}function Zd(e){return Jt("MuiSvgIcon",e)}xr("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const Xd=e=>{const{color:t,fontSize:r,classes:n}=e,i={root:["root",t!=="inherit"&&`color${Fe(t)}`,`fontSize${Fe(r)}`]};return Qr(i,Zd,n)},Jd=yt("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,r.color!=="inherit"&&t[`color${Fe(r.color)}`],t[`fontSize${Fe(r.fontSize)}`]]}})(gr(({theme:e})=>{var t,r,n,i,a,s,o,l,d,u,f,m,x,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:((s=(a=e.typography)==null?void 0:a.pxToRem)==null?void 0:s.call(a,20))||"1.25rem"}},{props:{fontSize:"medium"},style:{fontSize:((l=(o=e.typography)==null?void 0:o.pxToRem)==null?void 0:l.call(o,24))||"1.5rem"}},{props:{fontSize:"large"},style:{fontSize:((u=(d=e.typography)==null?void 0:d.pxToRem)==null?void 0:u.call(d,35))||"2.1875rem"}},...Object.entries((e.vars??e).palette).filter(([,c])=>c&&c.main).map(([c])=>{var E,h;return{props:{color:c},style:{color:(h=(E=(e.vars??e).palette)==null?void 0:E[c])==null?void 0:h.main}}}),{props:{color:"action"},style:{color:(m=(f=(e.vars??e).palette)==null?void 0:f.action)==null?void 0:m.active}},{props:{color:"disabled"},style:{color:(S=(x=(e.vars??e).palette)==null?void 0:x.action)==null?void 0:S.disabled}},{props:{color:"inherit"},style:{color:void 0}}]}})),Xn=ie.forwardRef(function(t,r){const n=br({props:t,name:"MuiSvgIcon"}),{children:i,className:a,color:s="inherit",component:o="svg",fontSize:l="medium",htmlColor:d,inheritViewBox:u=!1,titleAccess:f,viewBox:m="0 0 24 24",...x}=n,S=ie.isValidElement(i)&&i.type==="svg",c={...n,color:s,component:o,fontSize:l,instanceFontSize:t.fontSize,inheritViewBox:u,viewBox:m,hasSvgAsChild:S},E={};u||(E.viewBox=m);const h=Xd(c);return v.jsxs(Jd,{as:o,className:Ke(h.root,a),focusable:"false",color:d,"aria-hidden":f?void 0:!0,role:f?"img":void 0,ref:r,...E,...x,...S&&i.props,ownerState:c,children:[S?i.props.children:i,f?v.jsx("title",{children:f}):null]})});process.env.NODE_ENV!=="production"&&(Xn.propTypes={children:g.node,classes:g.object,className:g.string,color:g.oneOfType([g.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),g.string]),component:g.elementType,fontSize:g.oneOfType([g.oneOf(["inherit","large","medium","small"]),g.string]),htmlColor:g.string,inheritViewBox:g.bool,shapeRendering:g.string,sx:g.oneOfType([g.arrayOf(g.oneOfType([g.func,g.object,g.bool])),g.func,g.object]),titleAccess:g.string,viewBox:g.string});Xn.muiName="SvgIcon";function kt(e,t){function r(n,i){return v.jsx(Xn,{"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=Xn.muiName,ie.memo(ie.forwardRef(r))}let Ls=0;function ef(e){const[t,r]=ie.useState(e),n=e||t;return ie.useEffect(()=>{t==null&&(Ls+=1,r(`mui-${Ls}`))},[t]),n}const tf={...ie},qs=tf.useId;function rf(e){if(qs!==void 0){const t=qs();return e??t}return ef(e)}function Mn(e){const t=ie.useRef(e);return Bp(()=>{t.current=e}),ie.useRef((...r)=>(0,t.current)(...r)).current}function Us(...e){const t=ie.useRef(void 0),r=ie.useCallback(n=>{const i=e.map(a=>{if(a==null)return null;if(typeof a=="function"){const s=a,o=s(n);return typeof o=="function"?o:()=>{s(null)}}return a.current=n,()=>{a.current=null}});return()=>{i.forEach(a=>a==null?void 0:a())}},e);return ie.useMemo(()=>e.every(n=>n==null)?null:n=>{t.current&&(t.current(),t.current=void 0),n!=null&&(t.current=r(n))},e)}const nf=g.oneOfType([g.func,g.object]);function af(e){const{prototype:t={}}=e;return!!t.isReactComponent}function sf(e,t,r,n,i){const a=e[t],s=i||t;if(a==null||typeof window>"u")return null;let o;return typeof a=="function"&&!af(a)&&(o="Did you accidentally provide a plain function component instead?"),o!==void 0?new Error(`Invalid ${n} \`${s}\` supplied to \`${r}\`. Expected an element type that can hold a ref. ${o} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const of=ja(g.elementType,sf);function Ws(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 Hs={};function vl(e,t){const r=ie.useRef(Hs);return r.current===Hs&&(r.current=e(t)),r}class Jn{constructor(){Xr(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 Jn}static use(){const t=vl(Jn.create).current,[r,n]=ie.useState(!1);return t.shouldMount=r,t.setShouldMount=n,ie.useEffect(t.mountEffect,[r]),t}mount(){return this.mounted||(this.mounted=cf(),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 lf(){return Jn.use()}function cf(){let e,t;const r=new Promise((n,i)=>{e=n,t=i});return r.resolve=e,r.reject=t,r}function Ji(){return Ji=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},Ji.apply(null,arguments)}function uf(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 ea(e,t){return ea=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,n){return r.__proto__=n,r},ea(e,t)}function pf(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,ea(e,t)}const Ks=I.createContext(null);function df(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Ra(e,t){var r=function(a){return t&&I.isValidElement(a)?t(a):a},n=Object.create(null);return e&&I.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 s,o={};for(var l in t){if(n[l])for(s=0;s<n[l].length;s++){var d=n[l][s];o[n[l][s]]=r(d)}o[l]=r(l)}for(s=0;s<i.length;s++)o[i[s]]=r(i[s]);return o}function ar(e,t,r){return r[t]!=null?r[t]:e.props[t]}function mf(e,t){return Ra(e.children,function(r){return I.cloneElement(r,{onExited:t.bind(null,r),in:!0,appear:ar(r,"appear",e),enter:ar(r,"enter",e),exit:ar(r,"exit",e)})})}function hf(e,t,r){var n=Ra(e.children),i=ff(t,n);return Object.keys(i).forEach(function(a){var s=i[a];if(I.isValidElement(s)){var o=a in t,l=a in n,d=t[a],u=I.isValidElement(d)&&!d.props.in;l&&(!o||u)?i[a]=I.cloneElement(s,{onExited:r.bind(null,s),in:!0,exit:ar(s,"exit",e),enter:ar(s,"enter",e)}):!l&&o&&!u?i[a]=I.cloneElement(s,{in:!1}):l&&o&&I.isValidElement(d)&&(i[a]=I.cloneElement(s,{onExited:r.bind(null,s),in:d.props.in,exit:ar(s,"exit",e),enter:ar(s,"enter",e)}))}}),i}var yf=Object.values||function(e){return Object.keys(e).map(function(t){return e[t]})},gf={component:"div",childFactory:function(t){return t}},$a=function(e){pf(t,e);function t(n,i){var a;a=e.call(this,n,i)||this;var s=a.handleExited.bind(df(a));return a.state={contextValue:{isMounting:!0},handleExited:s,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 s=a.children,o=a.handleExited,l=a.firstRender;return{children:l?mf(i,o):hf(i,s,o),firstRender:!1}},r.handleExited=function(i,a){var s=Ra(this.props.children);i.key in s||(i.props.onExited&&i.props.onExited(a),this.mounted&&this.setState(function(o){var l=Ji({},o.children);return delete l[i.key],{children:l}}))},r.render=function(){var i=this.props,a=i.component,s=i.childFactory,o=uf(i,["component","childFactory"]),l=this.state.contextValue,d=yf(this.state.children).map(s);return delete o.appear,delete o.enter,delete o.exit,a===null?I.createElement(Ks.Provider,{value:l},d):I.createElement(Ks.Provider,{value:l},I.createElement(a,o,d))},t}(I.Component);$a.propTypes=process.env.NODE_ENV!=="production"?{component:g.any,children:g.node,appear:g.bool,enter:g.bool,exit:g.bool,childFactory:g.func}:{};$a.defaultProps=gf;const vf=[];function xf(e){ie.useEffect(e,vf)}class Da{constructor(){Xr(this,"currentId",null);Xr(this,"clear",()=>{this.currentId!==null&&(clearTimeout(this.currentId),this.currentId=null)});Xr(this,"disposeEffect",()=>this.clear)}static create(){return new Da}start(t,r){this.clear(),this.currentId=setTimeout(()=>{this.currentId=null,r()},t)}}function bf(){const e=vl(Da.create).current;return xf(e.disposeEffect),e}function xl(e){const{className:t,classes:r,pulsate:n=!1,rippleX:i,rippleY:a,rippleSize:s,in:o,onExited:l,timeout:d}=e,[u,f]=ie.useState(!1),m=Ke(t,r.ripple,r.rippleVisible,n&&r.ripplePulsate),x={width:s,height:s,top:-(s/2)+a,left:-(s/2)+i},S=Ke(r.child,u&&r.childLeaving,n&&r.childPulsate);return!o&&!u&&f(!0),ie.useEffect(()=>{if(!o&&l!=null){const c=setTimeout(l,d);return()=>{clearTimeout(c)}}},[l,o,d]),v.jsx("span",{className:m,style:x,children:v.jsx("span",{className:S})})}process.env.NODE_ENV!=="production"&&(xl.propTypes={classes:g.object.isRequired,className:g.string,in:g.bool,onExited:g.func,pulsate:g.bool,rippleSize:g.number,rippleX:g.number,rippleY:g.number,timeout:g.number.isRequired});const ot=xr("MuiTouchRipple",["root","ripple","rippleVisible","ripplePulsate","child","childLeaving","childPulsate"]),ta=550,wf=80,Sf=vr.keyframes`
72
+ export default theme;`}function Xi(e={},...t){const{breakpoints:r,mixins:n={},spacing:i,palette:a={},transitions:s={},typography:o={},shape:l,...f}=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.":Gt(20));const u=Aa(a),p=al(e);let m=rt(p,{mixins:ud(p.breakpoints,n),palette:u,shadows:yd.slice(),typography:dd(u,o),transitions:bd(s),zIndex:{...wd}});if(m=rt(m,f),m=t.reduce((x,w)=>rt(x,w),m),process.env.NODE_ENV!=="production"){const x=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],w=(c,E)=>{let y;for(y in c){const C=c[y];if(x.includes(y)&&Object.keys(C).length>0){if(process.env.NODE_ENV!=="production"){const A=Jt("",y);console.error([`MUI: The \`${E}\` 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 '&.${A}' syntax:`,JSON.stringify({root:{[`&.${A}`]:C}},null,2),"","https://mui.com/r/state-classes-guide"].join(`
73
+ `))}c[y]={}}}};Object.keys(m.components).forEach(c=>{const E=m.components[c].styleOverrides;E&&c.startsWith("Mui")&&w(E,c)})}return m.unstable_sxConfig={...Sn,...f==null?void 0:f.unstable_sxConfig},m.unstable_sx=function(w){return Hr({sx:w,theme:this})},m.toRuntimeSource=fl,m}function Ed(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 Td=[...Array(25)].map((e,t)=>{if(t===0)return"none";const r=Ed(t);return`linear-gradient(rgba(255 255 255 / ${r}), rgba(255 255 255 / ${r}))`});function ml(e){return{inputPlaceholder:e==="dark"?.5:.42,inputUnderline:e==="dark"?.7:.42,switchTrackDisabled:e==="dark"?.2:.12,switchTrack:e==="dark"?.3:.38}}function hl(e){return e==="dark"?Td:[]}function kd(e){const{palette:t={mode:"light"},opacity:r,overlays:n,...i}=e,a=Aa(t);return{palette:a,opacity:{...ml(a.mode),...r},overlays:n||hl(a.mode),...i}}function Cd(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 Od=e=>[...[...Array(25)].map((t,r)=>`--${e?`${e}-`:""}overlays-${r}`),`--${e?`${e}-`:""}palette-AppBar-darkBg`,`--${e?`${e}-`:""}palette-AppBar-darkColor`],_d=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 s={};return Od(e.cssVarPrefix).forEach(o=>{s[o]=r[o],delete r[o]}),a==="media"?{[n]:r,"@media (prefers-color-scheme: dark)":{[n]:s}}:a?{[a.replace("%s",t)]:s,[`${n}, ${a.replace("%s",t)}`]:r}:{[n]:{...r,...s}}}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 Ad(e,t){t.forEach(r=>{e[r]||(e[r]={})})}function $(e,t,r){!e[t]&&r&&(e[t]=r)}function an(e){return typeof e!="string"||!e.startsWith("hsl")?e:ul(e)}function _t(e,t){`${t}Channel`in e||(e[`${t}Channel`]=nn(an(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 Fd(e){return typeof e=="number"?`${e}px`:typeof e=="string"||typeof e=="function"||Array.isArray(e)?e:"8px"}const vt=e=>{try{return e()}catch{}},jd=(e="mui")=>Gp(e);function Ai(e,t,r,n){if(!t)return;t=t===!0?{}:t;const i=n==="dark"?"dark":"light";if(!r){e[n]=kd({...t,palette:{mode:i,...t==null?void 0:t.palette}});return}const{palette:a,...s}=Xi({...r,palette:{mode:i,...t==null?void 0:t.palette}});return e[n]={...t,palette:a,opacity:{...ml(i),...t==null?void 0:t.opacity},overlays:(t==null?void 0:t.overlays)||hl(i)},s}function Rd(e={},...t){const{colorSchemes:r={light:!0},defaultColorScheme:n,disableCssColorScheme:i=!1,cssVarPrefix:a="mui",shouldSkipGeneratingVar:s=Cd,colorSchemeSelector:o=r.light&&r.dark?"media":void 0,rootSelector:l=":root",...f}=e,u=Object.keys(r)[0],p=n||(r.light&&u!=="light"?"light":u),m=jd(a),{[p]:x,light:w,dark:c,...E}=r,y={...E};let C=x;if((p==="dark"&&!("dark"in r)||p==="light"&&!("light"in r))&&(C=!0),!C)throw new Error(process.env.NODE_ENV!=="production"?`MUI: The \`colorSchemes.${p}\` option is either missing or invalid.`:Gt(21,p));const A=Ai(y,C,f,p);w&&!y.light&&Ai(y,w,void 0,"light"),c&&!y.dark&&Ai(y,c,void 0,"dark");let _={defaultColorScheme:p,...A,cssVarPrefix:a,colorSchemeSelector:o,rootSelector:l,getCssVar:m,colorSchemes:y,font:{...cd(A.typography),...A.font},spacing:Fd(f.spacing)};Object.keys(_.colorSchemes).forEach(K=>{const d=_.colorSchemes[K].palette,z=P=>{const q=P.split("-"),N=q[1],Y=q[2];return m(P,d[N][Y])};if(d.mode==="light"&&($(d.common,"background","#fff"),$(d.common,"onBackground","#000")),d.mode==="dark"&&($(d.common,"background","#000"),$(d.common,"onBackground","#fff")),Ad(d,["Alert","AppBar","Avatar","Button","Chip","FilledInput","LinearProgress","Skeleton","Slider","SnackbarContent","SpeedDialAction","StepConnector","StepContent","Switch","TableCell","Tooltip"]),d.mode==="light"){$(d.Alert,"errorColor",Ce(d.error.light,.6)),$(d.Alert,"infoColor",Ce(d.info.light,.6)),$(d.Alert,"successColor",Ce(d.success.light,.6)),$(d.Alert,"warningColor",Ce(d.warning.light,.6)),$(d.Alert,"errorFilledBg",z("palette-error-main")),$(d.Alert,"infoFilledBg",z("palette-info-main")),$(d.Alert,"successFilledBg",z("palette-success-main")),$(d.Alert,"warningFilledBg",z("palette-warning-main")),$(d.Alert,"errorFilledColor",vt(()=>d.getContrastText(d.error.main))),$(d.Alert,"infoFilledColor",vt(()=>d.getContrastText(d.info.main))),$(d.Alert,"successFilledColor",vt(()=>d.getContrastText(d.success.main))),$(d.Alert,"warningFilledColor",vt(()=>d.getContrastText(d.warning.main))),$(d.Alert,"errorStandardBg",Oe(d.error.light,.9)),$(d.Alert,"infoStandardBg",Oe(d.info.light,.9)),$(d.Alert,"successStandardBg",Oe(d.success.light,.9)),$(d.Alert,"warningStandardBg",Oe(d.warning.light,.9)),$(d.Alert,"errorIconColor",z("palette-error-main")),$(d.Alert,"infoIconColor",z("palette-info-main")),$(d.Alert,"successIconColor",z("palette-success-main")),$(d.Alert,"warningIconColor",z("palette-warning-main")),$(d.AppBar,"defaultBg",z("palette-grey-100")),$(d.Avatar,"defaultBg",z("palette-grey-400")),$(d.Button,"inheritContainedBg",z("palette-grey-300")),$(d.Button,"inheritContainedHoverBg",z("palette-grey-A100")),$(d.Chip,"defaultBorder",z("palette-grey-400")),$(d.Chip,"defaultAvatarColor",z("palette-grey-700")),$(d.Chip,"defaultIconColor",z("palette-grey-700")),$(d.FilledInput,"bg","rgba(0, 0, 0, 0.06)"),$(d.FilledInput,"hoverBg","rgba(0, 0, 0, 0.09)"),$(d.FilledInput,"disabledBg","rgba(0, 0, 0, 0.12)"),$(d.LinearProgress,"primaryBg",Oe(d.primary.main,.62)),$(d.LinearProgress,"secondaryBg",Oe(d.secondary.main,.62)),$(d.LinearProgress,"errorBg",Oe(d.error.main,.62)),$(d.LinearProgress,"infoBg",Oe(d.info.main,.62)),$(d.LinearProgress,"successBg",Oe(d.success.main,.62)),$(d.LinearProgress,"warningBg",Oe(d.warning.main,.62)),$(d.Skeleton,"bg",`rgba(${z("palette-text-primaryChannel")} / 0.11)`),$(d.Slider,"primaryTrack",Oe(d.primary.main,.62)),$(d.Slider,"secondaryTrack",Oe(d.secondary.main,.62)),$(d.Slider,"errorTrack",Oe(d.error.main,.62)),$(d.Slider,"infoTrack",Oe(d.info.main,.62)),$(d.Slider,"successTrack",Oe(d.success.main,.62)),$(d.Slider,"warningTrack",Oe(d.warning.main,.62));const P=Fn(d.background.default,.8);$(d.SnackbarContent,"bg",P),$(d.SnackbarContent,"color",vt(()=>d.getContrastText(P))),$(d.SpeedDialAction,"fabHoverBg",Fn(d.background.paper,.15)),$(d.StepConnector,"border",z("palette-grey-400")),$(d.StepContent,"border",z("palette-grey-400")),$(d.Switch,"defaultColor",z("palette-common-white")),$(d.Switch,"defaultDisabledColor",z("palette-grey-100")),$(d.Switch,"primaryDisabledColor",Oe(d.primary.main,.62)),$(d.Switch,"secondaryDisabledColor",Oe(d.secondary.main,.62)),$(d.Switch,"errorDisabledColor",Oe(d.error.main,.62)),$(d.Switch,"infoDisabledColor",Oe(d.info.main,.62)),$(d.Switch,"successDisabledColor",Oe(d.success.main,.62)),$(d.Switch,"warningDisabledColor",Oe(d.warning.main,.62)),$(d.TableCell,"border",Oe(An(d.divider,1),.88)),$(d.Tooltip,"bg",An(d.grey[700],.92))}if(d.mode==="dark"){$(d.Alert,"errorColor",Oe(d.error.light,.6)),$(d.Alert,"infoColor",Oe(d.info.light,.6)),$(d.Alert,"successColor",Oe(d.success.light,.6)),$(d.Alert,"warningColor",Oe(d.warning.light,.6)),$(d.Alert,"errorFilledBg",z("palette-error-dark")),$(d.Alert,"infoFilledBg",z("palette-info-dark")),$(d.Alert,"successFilledBg",z("palette-success-dark")),$(d.Alert,"warningFilledBg",z("palette-warning-dark")),$(d.Alert,"errorFilledColor",vt(()=>d.getContrastText(d.error.dark))),$(d.Alert,"infoFilledColor",vt(()=>d.getContrastText(d.info.dark))),$(d.Alert,"successFilledColor",vt(()=>d.getContrastText(d.success.dark))),$(d.Alert,"warningFilledColor",vt(()=>d.getContrastText(d.warning.dark))),$(d.Alert,"errorStandardBg",Ce(d.error.light,.9)),$(d.Alert,"infoStandardBg",Ce(d.info.light,.9)),$(d.Alert,"successStandardBg",Ce(d.success.light,.9)),$(d.Alert,"warningStandardBg",Ce(d.warning.light,.9)),$(d.Alert,"errorIconColor",z("palette-error-main")),$(d.Alert,"infoIconColor",z("palette-info-main")),$(d.Alert,"successIconColor",z("palette-success-main")),$(d.Alert,"warningIconColor",z("palette-warning-main")),$(d.AppBar,"defaultBg",z("palette-grey-900")),$(d.AppBar,"darkBg",z("palette-background-paper")),$(d.AppBar,"darkColor",z("palette-text-primary")),$(d.Avatar,"defaultBg",z("palette-grey-600")),$(d.Button,"inheritContainedBg",z("palette-grey-800")),$(d.Button,"inheritContainedHoverBg",z("palette-grey-700")),$(d.Chip,"defaultBorder",z("palette-grey-700")),$(d.Chip,"defaultAvatarColor",z("palette-grey-300")),$(d.Chip,"defaultIconColor",z("palette-grey-300")),$(d.FilledInput,"bg","rgba(255, 255, 255, 0.09)"),$(d.FilledInput,"hoverBg","rgba(255, 255, 255, 0.13)"),$(d.FilledInput,"disabledBg","rgba(255, 255, 255, 0.12)"),$(d.LinearProgress,"primaryBg",Ce(d.primary.main,.5)),$(d.LinearProgress,"secondaryBg",Ce(d.secondary.main,.5)),$(d.LinearProgress,"errorBg",Ce(d.error.main,.5)),$(d.LinearProgress,"infoBg",Ce(d.info.main,.5)),$(d.LinearProgress,"successBg",Ce(d.success.main,.5)),$(d.LinearProgress,"warningBg",Ce(d.warning.main,.5)),$(d.Skeleton,"bg",`rgba(${z("palette-text-primaryChannel")} / 0.13)`),$(d.Slider,"primaryTrack",Ce(d.primary.main,.5)),$(d.Slider,"secondaryTrack",Ce(d.secondary.main,.5)),$(d.Slider,"errorTrack",Ce(d.error.main,.5)),$(d.Slider,"infoTrack",Ce(d.info.main,.5)),$(d.Slider,"successTrack",Ce(d.success.main,.5)),$(d.Slider,"warningTrack",Ce(d.warning.main,.5));const P=Fn(d.background.default,.98);$(d.SnackbarContent,"bg",P),$(d.SnackbarContent,"color",vt(()=>d.getContrastText(P))),$(d.SpeedDialAction,"fabHoverBg",Fn(d.background.paper,.15)),$(d.StepConnector,"border",z("palette-grey-600")),$(d.StepContent,"border",z("palette-grey-600")),$(d.Switch,"defaultColor",z("palette-grey-300")),$(d.Switch,"defaultDisabledColor",z("palette-grey-600")),$(d.Switch,"primaryDisabledColor",Ce(d.primary.main,.55)),$(d.Switch,"secondaryDisabledColor",Ce(d.secondary.main,.55)),$(d.Switch,"errorDisabledColor",Ce(d.error.main,.55)),$(d.Switch,"infoDisabledColor",Ce(d.info.main,.55)),$(d.Switch,"successDisabledColor",Ce(d.success.main,.55)),$(d.Switch,"warningDisabledColor",Ce(d.warning.main,.55)),$(d.TableCell,"border",Ce(An(d.divider,1),.68)),$(d.Tooltip,"bg",An(d.grey[700],.92))}_t(d.background,"default"),_t(d.background,"paper"),_t(d.common,"background"),_t(d.common,"onBackground"),_t(d,"divider"),Object.keys(d).forEach(P=>{const q=d[P];P!=="tonalOffset"&&q&&typeof q=="object"&&(q.main&&$(d[P],"mainChannel",nn(an(q.main))),q.light&&$(d[P],"lightChannel",nn(an(q.light))),q.dark&&$(d[P],"darkChannel",nn(an(q.dark))),q.contrastText&&$(d[P],"contrastTextChannel",nn(an(q.contrastText))),P==="text"&&(_t(d[P],"primary"),_t(d[P],"secondary")),P==="action"&&(q.active&&_t(d[P],"active"),q.selected&&_t(d[P],"selected")))})}),_=t.reduce((K,d)=>rt(K,d),_);const b={prefix:a,disableCssColorScheme:i,shouldSkipGeneratingVar:s,getSelector:_d(_)},{vars:L,generateThemeVars:j,generateStyleSheets:ee}=Jp(_,b);return _.vars=L,Object.entries(_.colorSchemes[_.defaultColorScheme]).forEach(([K,d])=>{_[K]=d}),_.generateThemeVars=j,_.generateStyleSheets=ee,_.generateSpacing=function(){return il(f.spacing,Ta(this))},_.getColorSchemeSelector=ed(o),_.spacing=_.generateSpacing(),_.shouldSkipGeneratingVar=s,_.unstable_sxConfig={...Sn,...f==null?void 0:f.unstable_sxConfig},_.unstable_sx=function(d){return Hr({sx:d,theme:this})},_.toRuntimeSource=fl,_}function zs(e,t,r){e.colorSchemes&&r&&(e.colorSchemes[t]={...r!==!0&&r,palette:Aa({...r===!0?{}:r.palette,mode:t})})}function $d(e={},...t){const{palette:r,cssVariables:n=!1,colorSchemes:i=r?void 0:{light:!0},defaultColorScheme:a=r==null?void 0:r.mode,...s}=e,o=a||"light",l=i==null?void 0:i[o],f={...i,...r?{[o]:{...typeof l!="boolean"&&l,palette:r}}:void 0};if(n===!1){if(!("colorSchemes"in e))return Xi(e,...t);let u=r;"palette"in e||f[o]&&(f[o]!==!0?u=f[o].palette:o==="dark"&&(u={mode:"dark"}));const p=Xi({...e,palette:u},...t);return p.defaultColorScheme=o,p.colorSchemes=f,p.palette.mode==="light"&&(p.colorSchemes.light={...f.light!==!0&&f.light,palette:p.palette},zs(p,"dark",f.dark)),p.palette.mode==="dark"&&(p.colorSchemes.dark={...f.dark!==!0&&f.dark,palette:p.palette},zs(p,"light",f.light)),p}return!r&&!("light"in f)&&o==="light"&&(f.light=!0),Rd({...s,colorSchemes:f,defaultColorScheme:o,...typeof n!="boolean"&&n},...t)}const Dd=$d(),Pd="$$material";function Id(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const Md=e=>Id(e)&&e!=="classes",yt=Ip({themeId:Pd,defaultTheme:Dd,rootShouldForwardProp:Md});function zd(){return hp}const gr=Yp;process.env.NODE_ENV!=="production"&&(g.node,g.object.isRequired);function br(e){return Qp(e)}function Vd(e){return typeof e.main=="string"}function Nd(e,t=[]){if(!Vd(e))return!1;for(const r of t)if(!e.hasOwnProperty(r)||typeof e[r]!="string")return!1;return!0}function Zn(e=[]){return([,t])=>t&&Nd(t,e)}function Bd(e){return Jt("MuiTypography",e)}xr("MuiTypography",["root","h1","h2","h3","h4","h5","h6","subtitle1","subtitle2","body1","body2","inherit","button","caption","overline","alignLeft","alignRight","alignCenter","alignJustify","noWrap","gutterBottom","paragraph"]);const Ld={primary:!0,secondary:!0,error:!0,info:!0,success:!0,warning:!0,textPrimary:!0,textSecondary:!0,textDisabled:!0},qd=zd(),Ud=e=>{const{align:t,gutterBottom:r,noWrap:n,paragraph:i,variant:a,classes:s}=e,o={root:["root",a,e.align!=="inherit"&&`align${Re(t)}`,r&&"gutterBottom",n&&"noWrap",i&&"paragraph"]};return Qr(o,Bd,s)},Wd=yt("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]}})(gr(({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(Zn()).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}}]}})),Vs={h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",subtitle1:"h6",subtitle2:"h6",body1:"p",body2:"p",inherit:"p"},yl=ie.forwardRef(function(t,r){const{color:n,...i}=br({props:t,name:"MuiTypography"}),a=!Ld[n],s=qd({...i,...a&&{color:n}}),{align:o="inherit",className:l,component:f,gutterBottom:u=!1,noWrap:p=!1,paragraph:m=!1,variant:x="body1",variantMapping:w=Vs,...c}=s,E={...s,align:o,color:n,className:l,component:f,gutterBottom:u,noWrap:p,paragraph:m,variant:x,variantMapping:w},y=f||(m?"p":w[x]||Vs[x])||"span",C=Ud(E);return v.jsx(Wd,{as:y,ref:r,className:Qe(C.root,l),...c,ownerState:E,style:{...o!=="inherit"&&{"--Typography-textAlign":o},...c.style}})});process.env.NODE_ENV!=="production"&&(yl.propTypes={align:g.oneOf(["center","inherit","justify","left","right"]),children:g.node,classes:g.object,className:g.string,color:g.oneOfType([g.oneOf(["primary","secondary","success","error","info","warning","textPrimary","textSecondary","textDisabled"]),g.string]),component:g.elementType,gutterBottom:g.bool,noWrap:g.bool,paragraph:g.bool,style:g.object,sx:g.oneOfType([g.arrayOf(g.oneOfType([g.func,g.object,g.bool])),g.func,g.object]),variant:g.oneOfType([g.oneOf(["body1","body2","button","caption","h1","h2","h3","h4","h5","h6","inherit","overline","subtitle1","subtitle2"]),g.string]),variantMapping:g.object});const Fa=ie.createContext(void 0);process.env.NODE_ENV!=="production"&&(Fa.displayName="FormControlContext");function Hd(){return ie.useContext(Fa)}function Kd(e){return Jt("MuiInputAdornment",e)}const Ns=xr("MuiInputAdornment",["root","filled","standard","outlined","positionStart","positionEnd","disablePointerEvents","hiddenLabel","sizeSmall"]);var Bs;const Qd=(e,t)=>{const{ownerState:r}=e;return[t.root,t[`position${Re(r.position)}`],r.disablePointerEvents===!0&&t.disablePointerEvents,t[r.variant]]},Yd=e=>{const{classes:t,disablePointerEvents:r,hiddenLabel:n,position:i,size:a,variant:s}=e,o={root:["root",r&&"disablePointerEvents",i&&`position${Re(i)}`,s,n&&"hiddenLabel",a&&`size${Re(a)}`]};return Qr(o,Kd,t)},Gd=yt("div",{name:"MuiInputAdornment",slot:"Root",overridesResolver:Qd})(gr(({theme:e})=>({display:"flex",maxHeight:"2em",alignItems:"center",whiteSpace:"nowrap",color:(e.vars||e).palette.action.active,variants:[{props:{variant:"filled"},style:{[`&.${Ns.positionStart}&:not(.${Ns.hiddenLabel})`]:{marginTop:16}}},{props:{position:"start"},style:{marginRight:8}},{props:{position:"end"},style:{marginLeft:8}},{props:{disablePointerEvents:!0},style:{pointerEvents:"none"}}]}))),gl=ie.forwardRef(function(t,r){const n=br({props:t,name:"MuiInputAdornment"}),{children:i,className:a,component:s="div",disablePointerEvents:o=!1,disableTypography:l=!1,position:f,variant:u,...p}=n,m=Hd()||{};let x=u;u&&m.variant&&process.env.NODE_ENV!=="production"&&u===m.variant&&console.error("MUI: The `InputAdornment` variant infers the variant prop you do not have to provide one."),m&&!x&&(x=m.variant);const w={...n,hiddenLabel:m.hiddenLabel,size:m.size,disablePointerEvents:o,position:f,variant:x},c=Yd(w);return v.jsx(Fa.Provider,{value:null,children:v.jsx(Gd,{as:s,ownerState:w,className:Qe(c.root,a),ref:r,...p,children:typeof i=="string"&&!l?v.jsx(yl,{color:"textSecondary",children:i}):v.jsxs(ie.Fragment,{children:[f==="start"?Bs||(Bs=v.jsx("span",{className:"notranslate","aria-hidden":!0,children:"​"})):null,i]})})})});process.env.NODE_ENV!=="production"&&(gl.propTypes={children:g.node,classes:g.object,className:g.string,component:g.elementType,disablePointerEvents:g.bool,disableTypography:g.bool,position:g.oneOf(["end","start"]).isRequired,sx:g.oneOfType([g.arrayOf(g.oneOfType([g.func,g.object,g.bool])),g.func,g.object]),variant:g.oneOf(["filled","outlined","standard"])});function ja(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...n){return e(...n)||t(...n)}}function Zd(e){return Jt("MuiSvgIcon",e)}xr("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const Xd=e=>{const{color:t,fontSize:r,classes:n}=e,i={root:["root",t!=="inherit"&&`color${Re(t)}`,`fontSize${Re(r)}`]};return Qr(i,Zd,n)},Jd=yt("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)}`]]}})(gr(({theme:e})=>{var t,r,n,i,a,s,o,l,f,u,p,m,x,w;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:((s=(a=e.typography)==null?void 0:a.pxToRem)==null?void 0:s.call(a,20))||"1.25rem"}},{props:{fontSize:"medium"},style:{fontSize:((l=(o=e.typography)==null?void 0:o.pxToRem)==null?void 0:l.call(o,24))||"1.5rem"}},{props:{fontSize:"large"},style:{fontSize:((u=(f=e.typography)==null?void 0:f.pxToRem)==null?void 0:u.call(f,35))||"2.1875rem"}},...Object.entries((e.vars??e).palette).filter(([,c])=>c&&c.main).map(([c])=>{var E,y;return{props:{color:c},style:{color:(y=(E=(e.vars??e).palette)==null?void 0:E[c])==null?void 0:y.main}}}),{props:{color:"action"},style:{color:(m=(p=(e.vars??e).palette)==null?void 0:p.action)==null?void 0:m.active}},{props:{color:"disabled"},style:{color:(w=(x=(e.vars??e).palette)==null?void 0:x.action)==null?void 0:w.disabled}},{props:{color:"inherit"},style:{color:void 0}}]}})),Xn=ie.forwardRef(function(t,r){const n=br({props:t,name:"MuiSvgIcon"}),{children:i,className:a,color:s="inherit",component:o="svg",fontSize:l="medium",htmlColor:f,inheritViewBox:u=!1,titleAccess:p,viewBox:m="0 0 24 24",...x}=n,w=ie.isValidElement(i)&&i.type==="svg",c={...n,color:s,component:o,fontSize:l,instanceFontSize:t.fontSize,inheritViewBox:u,viewBox:m,hasSvgAsChild:w},E={};u||(E.viewBox=m);const y=Xd(c);return v.jsxs(Jd,{as:o,className:Qe(y.root,a),focusable:"false",color:f,"aria-hidden":p?void 0:!0,role:p?"img":void 0,ref:r,...E,...x,...w&&i.props,ownerState:c,children:[w?i.props.children:i,p?v.jsx("title",{children:p}):null]})});process.env.NODE_ENV!=="production"&&(Xn.propTypes={children:g.node,classes:g.object,className:g.string,color:g.oneOfType([g.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),g.string]),component:g.elementType,fontSize:g.oneOfType([g.oneOf(["inherit","large","medium","small"]),g.string]),htmlColor:g.string,inheritViewBox:g.bool,shapeRendering:g.string,sx:g.oneOfType([g.arrayOf(g.oneOfType([g.func,g.object,g.bool])),g.func,g.object]),titleAccess:g.string,viewBox:g.string});Xn.muiName="SvgIcon";function Ct(e,t){function r(n,i){return v.jsx(Xn,{"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=Xn.muiName,ie.memo(ie.forwardRef(r))}let Ls=0;function ef(e){const[t,r]=ie.useState(e),n=e||t;return ie.useEffect(()=>{t==null&&(Ls+=1,r(`mui-${Ls}`))},[t]),n}const tf={...ie},qs=tf.useId;function rf(e){if(qs!==void 0){const t=qs();return e??t}return ef(e)}function Mn(e){const t=ie.useRef(e);return Bp(()=>{t.current=e}),ie.useRef((...r)=>(0,t.current)(...r)).current}function Us(...e){const t=ie.useRef(void 0),r=ie.useCallback(n=>{const i=e.map(a=>{if(a==null)return null;if(typeof a=="function"){const s=a,o=s(n);return typeof o=="function"?o:()=>{s(null)}}return a.current=n,()=>{a.current=null}});return()=>{i.forEach(a=>a==null?void 0:a())}},e);return ie.useMemo(()=>e.every(n=>n==null)?null:n=>{t.current&&(t.current(),t.current=void 0),n!=null&&(t.current=r(n))},e)}const nf=g.oneOfType([g.func,g.object]);function af(e){const{prototype:t={}}=e;return!!t.isReactComponent}function sf(e,t,r,n,i){const a=e[t],s=i||t;if(a==null||typeof window>"u")return null;let o;return typeof a=="function"&&!af(a)&&(o="Did you accidentally provide a plain function component instead?"),o!==void 0?new Error(`Invalid ${n} \`${s}\` supplied to \`${r}\`. Expected an element type that can hold a ref. ${o} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const of=ja(g.elementType,sf);function Ws(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 Hs={};function vl(e,t){const r=ie.useRef(Hs);return r.current===Hs&&(r.current=e(t)),r}class Jn{constructor(){Xr(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 Jn}static use(){const t=vl(Jn.create).current,[r,n]=ie.useState(!1);return t.shouldMount=r,t.setShouldMount=n,ie.useEffect(t.mountEffect,[r]),t}mount(){return this.mounted||(this.mounted=cf(),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 lf(){return Jn.use()}function cf(){let e,t;const r=new Promise((n,i)=>{e=n,t=i});return r.resolve=e,r.reject=t,r}function Ji(){return Ji=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},Ji.apply(null,arguments)}function uf(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 ea(e,t){return ea=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,n){return r.__proto__=n,r},ea(e,t)}function pf(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,ea(e,t)}const Ks=D.createContext(null);function df(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Ra(e,t){var r=function(a){return t&&D.isValidElement(a)?t(a):a},n=Object.create(null);return e&&D.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 s,o={};for(var l in t){if(n[l])for(s=0;s<n[l].length;s++){var f=n[l][s];o[n[l][s]]=r(f)}o[l]=r(l)}for(s=0;s<i.length;s++)o[i[s]]=r(i[s]);return o}function ar(e,t,r){return r[t]!=null?r[t]:e.props[t]}function mf(e,t){return Ra(e.children,function(r){return D.cloneElement(r,{onExited:t.bind(null,r),in:!0,appear:ar(r,"appear",e),enter:ar(r,"enter",e),exit:ar(r,"exit",e)})})}function hf(e,t,r){var n=Ra(e.children),i=ff(t,n);return Object.keys(i).forEach(function(a){var s=i[a];if(D.isValidElement(s)){var o=a in t,l=a in n,f=t[a],u=D.isValidElement(f)&&!f.props.in;l&&(!o||u)?i[a]=D.cloneElement(s,{onExited:r.bind(null,s),in:!0,exit:ar(s,"exit",e),enter:ar(s,"enter",e)}):!l&&o&&!u?i[a]=D.cloneElement(s,{in:!1}):l&&o&&D.isValidElement(f)&&(i[a]=D.cloneElement(s,{onExited:r.bind(null,s),in:f.props.in,exit:ar(s,"exit",e),enter:ar(s,"enter",e)}))}}),i}var yf=Object.values||function(e){return Object.keys(e).map(function(t){return e[t]})},gf={component:"div",childFactory:function(t){return t}},$a=function(e){pf(t,e);function t(n,i){var a;a=e.call(this,n,i)||this;var s=a.handleExited.bind(df(a));return a.state={contextValue:{isMounting:!0},handleExited:s,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 s=a.children,o=a.handleExited,l=a.firstRender;return{children:l?mf(i,o):hf(i,s,o),firstRender:!1}},r.handleExited=function(i,a){var s=Ra(this.props.children);i.key in s||(i.props.onExited&&i.props.onExited(a),this.mounted&&this.setState(function(o){var l=Ji({},o.children);return delete l[i.key],{children:l}}))},r.render=function(){var i=this.props,a=i.component,s=i.childFactory,o=uf(i,["component","childFactory"]),l=this.state.contextValue,f=yf(this.state.children).map(s);return delete o.appear,delete o.enter,delete o.exit,a===null?D.createElement(Ks.Provider,{value:l},f):D.createElement(Ks.Provider,{value:l},D.createElement(a,o,f))},t}(D.Component);$a.propTypes=process.env.NODE_ENV!=="production"?{component:g.any,children:g.node,appear:g.bool,enter:g.bool,exit:g.bool,childFactory:g.func}:{};$a.defaultProps=gf;const vf=[];function xf(e){ie.useEffect(e,vf)}class Da{constructor(){Xr(this,"currentId",null);Xr(this,"clear",()=>{this.currentId!==null&&(clearTimeout(this.currentId),this.currentId=null)});Xr(this,"disposeEffect",()=>this.clear)}static create(){return new Da}start(t,r){this.clear(),this.currentId=setTimeout(()=>{this.currentId=null,r()},t)}}function bf(){const e=vl(Da.create).current;return xf(e.disposeEffect),e}function xl(e){const{className:t,classes:r,pulsate:n=!1,rippleX:i,rippleY:a,rippleSize:s,in:o,onExited:l,timeout:f}=e,[u,p]=ie.useState(!1),m=Qe(t,r.ripple,r.rippleVisible,n&&r.ripplePulsate),x={width:s,height:s,top:-(s/2)+a,left:-(s/2)+i},w=Qe(r.child,u&&r.childLeaving,n&&r.childPulsate);return!o&&!u&&p(!0),ie.useEffect(()=>{if(!o&&l!=null){const c=setTimeout(l,f);return()=>{clearTimeout(c)}}},[l,o,f]),v.jsx("span",{className:m,style:x,children:v.jsx("span",{className:w})})}process.env.NODE_ENV!=="production"&&(xl.propTypes={classes:g.object.isRequired,className:g.string,in:g.bool,onExited:g.func,pulsate:g.bool,rippleSize:g.number,rippleX:g.number,rippleY:g.number,timeout:g.number.isRequired});const ot=xr("MuiTouchRipple",["root","ripple","rippleVisible","ripplePulsate","child","childLeaving","childPulsate"]),ta=550,wf=80,Sf=vr.keyframes`
76
76
  0% {
77
77
  transform: scale(0);
78
78
  opacity: 0.1;
@@ -90,7 +90,7 @@ To suppress this warning, you need to explicitly provide the \`palette.${t}Chann
90
90
  100% {
91
91
  opacity: 0;
92
92
  }
93
- `,Cf=vr.keyframes`
93
+ `,Tf=vr.keyframes`
94
94
  0% {
95
95
  transform: scale(1);
96
96
  }
@@ -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
- `,Tf=yt("span",{name:"MuiTouchRipple",slot:"Root"})({overflow:"hidden",pointerEvents:"none",position:"absolute",zIndex:0,top:0,right:0,bottom:0,left:0,borderRadius:"inherit"}),kf=yt(xl,{name:"MuiTouchRipple",slot:"Ripple"})`
105
+ `,kf=yt("span",{name:"MuiTouchRipple",slot:"Root"})({overflow:"hidden",pointerEvents:"none",position:"absolute",zIndex:0,top:0,right:0,bottom:0,left:0,borderRadius:"inherit"}),Cf=yt(xl,{name:"MuiTouchRipple",slot:"Ripple"})`
106
106
  opacity: 0;
107
107
  position: absolute;
108
108
 
@@ -139,13 +139,13 @@ To suppress this warning, you need to explicitly provide the \`palette.${t}Chann
139
139
  /* @noflip */
140
140
  left: 0px;
141
141
  top: 0;
142
- animation-name: ${Cf};
142
+ animation-name: ${Tf};
143
143
  animation-duration: 2500ms;
144
144
  animation-timing-function: ${({theme:e})=>e.transitions.easing.easeInOut};
145
145
  animation-iteration-count: infinite;
146
146
  animation-delay: 200ms;
147
147
  }
148
- `,bl=ie.forwardRef(function(t,r){const n=br({props:t,name:"MuiTouchRipple"}),{center:i=!1,classes:a={},className:s,...o}=n,[l,d]=ie.useState([]),u=ie.useRef(0),f=ie.useRef(null);ie.useEffect(()=>{f.current&&(f.current(),f.current=null)},[l]);const m=ie.useRef(!1),x=bf(),S=ie.useRef(null),c=ie.useRef(null),E=ie.useCallback(T=>{const{pulsate:w,rippleX:F,rippleY:X,rippleSize:J,cb:W}=T;d(p=>[...p,v.jsx(kf,{classes:{ripple:Ke(a.ripple,ot.ripple),rippleVisible:Ke(a.rippleVisible,ot.rippleVisible),ripplePulsate:Ke(a.ripplePulsate,ot.ripplePulsate),child:Ke(a.child,ot.child),childLeaving:Ke(a.childLeaving,ot.childLeaving),childPulsate:Ke(a.childPulsate,ot.childPulsate)},timeout:ta,pulsate:w,rippleX:F,rippleY:X,rippleSize:J},u.current)]),u.current+=1,f.current=W},[a]),h=ie.useCallback((T={},w={},F=()=>{})=>{const{pulsate:X=!1,center:J=i||w.pulsate,fakeElement:W=!1}=w;if((T==null?void 0:T.type)==="mousedown"&&m.current){m.current=!1;return}(T==null?void 0:T.type)==="touchstart"&&(m.current=!0);const p=W?null:c.current,R=p?p.getBoundingClientRect():{width:0,height:0,left:0,top:0};let V,B,z;if(J||T===void 0||T.clientX===0&&T.clientY===0||!T.clientX&&!T.touches)V=Math.round(R.width/2),B=Math.round(R.height/2);else{const{clientX:H,clientY:le}=T.touches&&T.touches.length>0?T.touches[0]:T;V=Math.round(H-R.left),B=Math.round(le-R.top)}if(J)z=Math.sqrt((2*R.width**2+R.height**2)/3),z%2===0&&(z+=1);else{const H=Math.max(Math.abs((p?p.clientWidth:0)-V),V)*2+2,le=Math.max(Math.abs((p?p.clientHeight:0)-B),B)*2+2;z=Math.sqrt(H**2+le**2)}T!=null&&T.touches?S.current===null&&(S.current=()=>{E({pulsate:X,rippleX:V,rippleY:B,rippleSize:z,cb:F})},x.start(wf,()=>{S.current&&(S.current(),S.current=null)})):E({pulsate:X,rippleX:V,rippleY:B,rippleSize:z,cb:F})},[i,E,x]),_=ie.useCallback(()=>{h({},{pulsate:!0})},[h]),$=ie.useCallback((T,w)=>{if(x.clear(),(T==null?void 0:T.type)==="touchend"&&S.current){S.current(),S.current=null,x.start(0,()=>{$(T,w)});return}S.current=null,d(F=>F.length>0?F.slice(1):F),f.current=w},[x]);return ie.useImperativeHandle(r,()=>({pulsate:_,start:h,stop:$}),[_,h,$]),v.jsx(Tf,{className:Ke(ot.root,a.root,s),ref:c,...o,children:v.jsx($a,{component:null,exit:!0,children:l})})});process.env.NODE_ENV!=="production"&&(bl.propTypes={center:g.bool,classes:g.object,className:g.string});function Of(e){return Jt("MuiButtonBase",e)}const _f=xr("MuiButtonBase",["root","disabled","focusVisible"]),Af=e=>{const{disabled:t,focusVisible:r,focusVisibleClassName:n,classes:i}=e,s=Qr({root:["root",t&&"disabled",r&&"focusVisible"]},Of,i);return r&&n&&(s.root+=` ${n}`),s},Ff=yt("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"},[`&.${_f.disabled}`]:{pointerEvents:"none",cursor:"default"},"@media print":{colorAdjust:"exact"}}),wl=ie.forwardRef(function(t,r){const n=br({props:t,name:"MuiButtonBase"}),{action:i,centerRipple:a=!1,children:s,className:o,component:l="button",disabled:d=!1,disableRipple:u=!1,disableTouchRipple:f=!1,focusRipple:m=!1,focusVisibleClassName:x,LinkComponent:S="a",onBlur:c,onClick:E,onContextMenu:h,onDragLeave:_,onFocus:$,onFocusVisible:T,onKeyDown:w,onKeyUp:F,onMouseDown:X,onMouseLeave:J,onMouseUp:W,onTouchEnd:p,onTouchMove:R,onTouchStart:V,tabIndex:B=0,TouchRippleProps:z,touchRippleRef:H,type:le,...ce}=n,pe=ie.useRef(null),oe=lf(),N=Us(oe.ref,H),[L,K]=ie.useState(!1);d&&L&&K(!1),ie.useImperativeHandle(i,()=>({focusVisible:()=>{K(!0),pe.current.focus()}}),[]);const se=oe.shouldMount&&!u&&!d;ie.useEffect(()=>{L&&m&&!u&&oe.pulsate()},[u,m,L,oe]);const ae=At(oe,"start",X,f),ee=At(oe,"stop",h,f),q=At(oe,"stop",_,f),te=At(oe,"stop",W,f),ue=At(oe,"stop",k=>{L&&k.preventDefault(),J&&J(k)},f),M=At(oe,"start",V,f),U=At(oe,"stop",p,f),re=At(oe,"stop",R,f),C=At(oe,"stop",k=>{Ws(k.target)||K(!1),c&&c(k)},!1),Q=Mn(k=>{pe.current||(pe.current=k.currentTarget),Ws(k.target)&&(K(!0),T&&T(k)),$&&$(k)}),me=()=>{const k=pe.current;return l&&l!=="button"&&!(k.tagName==="A"&&k.href)},Te=Mn(k=>{m&&!k.repeat&&L&&k.key===" "&&oe.stop(k,()=>{oe.start(k)}),k.target===k.currentTarget&&me()&&k.key===" "&&k.preventDefault(),w&&w(k),k.target===k.currentTarget&&me()&&k.key==="Enter"&&!d&&(k.preventDefault(),E&&E(k))}),Be=Mn(k=>{m&&k.key===" "&&L&&!k.defaultPrevented&&oe.stop(k,()=>{oe.pulsate(k)}),F&&F(k),E&&k.target===k.currentTarget&&me()&&k.key===" "&&!k.defaultPrevented&&E(k)});let Se=l;Se==="button"&&(ce.href||ce.to)&&(Se=S);const qe={};Se==="button"?(qe.type=le===void 0?"button":le,qe.disabled=d):(!ce.href&&!ce.to&&(qe.role="button"),d&&(qe["aria-disabled"]=d));const Je=Us(r,pe),y={...n,centerRipple:a,component:l,disabled:d,disableRipple:u,disableTouchRipple:f,focusRipple:m,tabIndex:B,focusVisible:L},O=Af(y);return v.jsxs(Ff,{as:Se,className:Ke(O.root,o),ownerState:y,onBlur:C,onClick:E,onContextMenu:ee,onFocus:Q,onKeyDown:Te,onKeyUp:Be,onMouseDown:ae,onMouseLeave:ue,onMouseUp:te,onDragLeave:q,onTouchEnd:U,onTouchMove:re,onTouchStart:M,ref:Je,tabIndex:d?-1:B,type:le,...qe,...ce,children:[s,se?v.jsx(bl,{ref:N,center:a,...z}):null]})});function At(e,t,r,n=!1){return Mn(i=>(r&&r(i),n||e[t](i),!0))}process.env.NODE_ENV!=="production"&&(wl.propTypes={action:nf,centerRipple:g.bool,children:g.node,classes:g.object,className:g.string,component:of,disabled:g.bool,disableRipple:g.bool,disableTouchRipple:g.bool,focusRipple:g.bool,focusVisibleClassName:g.string,href:g.any,LinkComponent:g.elementType,onBlur:g.func,onClick:g.func,onContextMenu:g.func,onDragLeave:g.func,onFocus:g.func,onFocusVisible:g.func,onKeyDown:g.func,onKeyUp:g.func,onMouseDown:g.func,onMouseLeave:g.func,onMouseUp:g.func,onTouchEnd:g.func,onTouchMove:g.func,onTouchStart:g.func,sx:g.oneOfType([g.arrayOf(g.oneOfType([g.func,g.object,g.bool])),g.func,g.object]),tabIndex:g.number,TouchRippleProps:g.object,touchRippleRef:g.oneOfType([g.func,g.shape({current:g.shape({pulsate:g.func.isRequired,start:g.func.isRequired,stop:g.func.isRequired})})]),type:g.oneOfType([g.oneOf(["button","reset","submit"]),g.string])});function jf(e){return Jt("MuiCircularProgress",e)}xr("MuiCircularProgress",["root","determinate","indeterminate","colorPrimary","colorSecondary","svg","circle","circleDeterminate","circleIndeterminate","circleDisableShrink"]);const Pt=44,ra=vr.keyframes`
148
+ `,bl=ie.forwardRef(function(t,r){const n=br({props:t,name:"MuiTouchRipple"}),{center:i=!1,classes:a={},className:s,...o}=n,[l,f]=ie.useState([]),u=ie.useRef(0),p=ie.useRef(null);ie.useEffect(()=>{p.current&&(p.current(),p.current=null)},[l]);const m=ie.useRef(!1),x=bf(),w=ie.useRef(null),c=ie.useRef(null),E=ie.useCallback(_=>{const{pulsate:b,rippleX:L,rippleY:j,rippleSize:ee,cb:K}=_;f(d=>[...d,v.jsx(Cf,{classes:{ripple:Qe(a.ripple,ot.ripple),rippleVisible:Qe(a.rippleVisible,ot.rippleVisible),ripplePulsate:Qe(a.ripplePulsate,ot.ripplePulsate),child:Qe(a.child,ot.child),childLeaving:Qe(a.childLeaving,ot.childLeaving),childPulsate:Qe(a.childPulsate,ot.childPulsate)},timeout:ta,pulsate:b,rippleX:L,rippleY:j,rippleSize:ee},u.current)]),u.current+=1,p.current=K},[a]),y=ie.useCallback((_={},b={},L=()=>{})=>{const{pulsate:j=!1,center:ee=i||b.pulsate,fakeElement:K=!1}=b;if((_==null?void 0:_.type)==="mousedown"&&m.current){m.current=!1;return}(_==null?void 0:_.type)==="touchstart"&&(m.current=!0);const d=K?null:c.current,z=d?d.getBoundingClientRect():{width:0,height:0,left:0,top:0};let P,q,N;if(ee||_===void 0||_.clientX===0&&_.clientY===0||!_.clientX&&!_.touches)P=Math.round(z.width/2),q=Math.round(z.height/2);else{const{clientX:Y,clientY:re}=_.touches&&_.touches.length>0?_.touches[0]:_;P=Math.round(Y-z.left),q=Math.round(re-z.top)}if(ee)N=Math.sqrt((2*z.width**2+z.height**2)/3),N%2===0&&(N+=1);else{const Y=Math.max(Math.abs((d?d.clientWidth:0)-P),P)*2+2,re=Math.max(Math.abs((d?d.clientHeight:0)-q),q)*2+2;N=Math.sqrt(Y**2+re**2)}_!=null&&_.touches?w.current===null&&(w.current=()=>{E({pulsate:j,rippleX:P,rippleY:q,rippleSize:N,cb:L})},x.start(wf,()=>{w.current&&(w.current(),w.current=null)})):E({pulsate:j,rippleX:P,rippleY:q,rippleSize:N,cb:L})},[i,E,x]),C=ie.useCallback(()=>{y({},{pulsate:!0})},[y]),A=ie.useCallback((_,b)=>{if(x.clear(),(_==null?void 0:_.type)==="touchend"&&w.current){w.current(),w.current=null,x.start(0,()=>{A(_,b)});return}w.current=null,f(L=>L.length>0?L.slice(1):L),p.current=b},[x]);return ie.useImperativeHandle(r,()=>({pulsate:C,start:y,stop:A}),[C,y,A]),v.jsx(kf,{className:Qe(ot.root,a.root,s),ref:c,...o,children:v.jsx($a,{component:null,exit:!0,children:l})})});process.env.NODE_ENV!=="production"&&(bl.propTypes={center:g.bool,classes:g.object,className:g.string});function Of(e){return Jt("MuiButtonBase",e)}const _f=xr("MuiButtonBase",["root","disabled","focusVisible"]),Af=e=>{const{disabled:t,focusVisible:r,focusVisibleClassName:n,classes:i}=e,s=Qr({root:["root",t&&"disabled",r&&"focusVisible"]},Of,i);return r&&n&&(s.root+=` ${n}`),s},Ff=yt("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"},[`&.${_f.disabled}`]:{pointerEvents:"none",cursor:"default"},"@media print":{colorAdjust:"exact"}}),wl=ie.forwardRef(function(t,r){const n=br({props:t,name:"MuiButtonBase"}),{action:i,centerRipple:a=!1,children:s,className:o,component:l="button",disabled:f=!1,disableRipple:u=!1,disableTouchRipple:p=!1,focusRipple:m=!1,focusVisibleClassName:x,LinkComponent:w="a",onBlur:c,onClick:E,onContextMenu:y,onDragLeave:C,onFocus:A,onFocusVisible:_,onKeyDown:b,onKeyUp:L,onMouseDown:j,onMouseLeave:ee,onMouseUp:K,onTouchEnd:d,onTouchMove:z,onTouchStart:P,tabIndex:q=0,TouchRippleProps:N,touchRippleRef:Y,type:re,...me}=n,ce=ie.useRef(null),oe=lf(),V=Us(oe.ref,Y),[U,ue]=ie.useState(!1);f&&U&&ue(!1),ie.useImperativeHandle(i,()=>({focusVisible:()=>{ue(!0),ce.current.focus()}}),[]);const Q=oe.shouldMount&&!u&&!f;ie.useEffect(()=>{U&&m&&!u&&oe.pulsate()},[u,m,U,oe]);const te=At(oe,"start",j,p),le=At(oe,"stop",y,p),W=At(oe,"stop",C,p),H=At(oe,"stop",K,p),ae=At(oe,"stop",T=>{U&&T.preventDefault(),ee&&ee(T)},p),pe=At(oe,"start",P,p),M=At(oe,"stop",d,p),se=At(oe,"stop",z,p),I=At(oe,"stop",T=>{Ws(T.target)||ue(!1),c&&c(T)},!1),B=Mn(T=>{ce.current||(ce.current=T.currentTarget),Ws(T.target)&&(ue(!0),_&&_(T)),A&&A(T)}),G=()=>{const T=ce.current;return l&&l!=="button"&&!(T.tagName==="A"&&T.href)},ye=Mn(T=>{m&&!T.repeat&&U&&T.key===" "&&oe.stop(T,()=>{oe.start(T)}),T.target===T.currentTarget&&G()&&T.key===" "&&T.preventDefault(),b&&b(T),T.target===T.currentTarget&&G()&&T.key==="Enter"&&!f&&(T.preventDefault(),E&&E(T))}),Fe=Mn(T=>{m&&T.key===" "&&U&&!T.defaultPrevented&&oe.stop(T,()=>{oe.pulsate(T)}),L&&L(T),E&&T.target===T.currentTarget&&G()&&T.key===" "&&!T.defaultPrevented&&E(T)});let _e=l;_e==="button"&&(me.href||me.to)&&(_e=w);const ke={};_e==="button"?(ke.type=re===void 0?"button":re,ke.disabled=f):(!me.href&&!me.to&&(ke.role="button"),f&&(ke["aria-disabled"]=f));const qe=Us(r,ce),h={...n,centerRipple:a,component:l,disabled:f,disableRipple:u,disableTouchRipple:p,focusRipple:m,tabIndex:q,focusVisible:U},k=Af(h);return v.jsxs(Ff,{as:_e,className:Qe(k.root,o),ownerState:h,onBlur:I,onClick:E,onContextMenu:le,onFocus:B,onKeyDown:ye,onKeyUp:Fe,onMouseDown:te,onMouseLeave:ae,onMouseUp:H,onDragLeave:W,onTouchEnd:M,onTouchMove:se,onTouchStart:pe,ref:qe,tabIndex:f?-1:q,type:re,...ke,...me,children:[s,Q?v.jsx(bl,{ref:V,center:a,...N}):null]})});function At(e,t,r,n=!1){return Mn(i=>(r&&r(i),n||e[t](i),!0))}process.env.NODE_ENV!=="production"&&(wl.propTypes={action:nf,centerRipple:g.bool,children:g.node,classes:g.object,className:g.string,component:of,disabled:g.bool,disableRipple:g.bool,disableTouchRipple:g.bool,focusRipple:g.bool,focusVisibleClassName:g.string,href:g.any,LinkComponent:g.elementType,onBlur:g.func,onClick:g.func,onContextMenu:g.func,onDragLeave:g.func,onFocus:g.func,onFocusVisible:g.func,onKeyDown:g.func,onKeyUp:g.func,onMouseDown:g.func,onMouseLeave:g.func,onMouseUp:g.func,onTouchEnd:g.func,onTouchMove:g.func,onTouchStart:g.func,sx:g.oneOfType([g.arrayOf(g.oneOfType([g.func,g.object,g.bool])),g.func,g.object]),tabIndex:g.number,TouchRippleProps:g.object,touchRippleRef:g.oneOfType([g.func,g.shape({current:g.shape({pulsate:g.func.isRequired,start:g.func.isRequired,stop:g.func.isRequired})})]),type:g.oneOfType([g.oneOf(["button","reset","submit"]),g.string])});function jf(e){return Jt("MuiCircularProgress",e)}xr("MuiCircularProgress",["root","determinate","indeterminate","colorPrimary","colorSecondary","svg","circle","circleDeterminate","circleIndeterminate","circleDisableShrink"]);const Pt=44,ra=vr.keyframes`
149
149
  0% {
150
150
  transform: rotate(0deg);
151
151
  }
@@ -172,13 +172,13 @@ To suppress this warning, you need to explicitly provide the \`palette.${t}Chann
172
172
  animation: ${ra} 1.4s linear infinite;
173
173
  `:null,$f=typeof na!="string"?vr.css`
174
174
  animation: ${na} 1.4s ease-in-out infinite;
175
- `:null,Df=e=>{const{classes:t,variant:r,color:n,disableShrink:i}=e,a={root:["root",r,`color${Fe(n)}`],svg:["svg"],circle:["circle",`circle${Fe(r)}`,i&&"circleDisableShrink"]};return Qr(a,jf,t)},Pf=yt("span",{name:"MuiCircularProgress",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,t[r.variant],t[`color${Fe(r.color)}`]]}})(gr(({theme:e})=>({display:"inline-block",variants:[{props:{variant:"determinate"},style:{transition:e.transitions.create("transform")}},{props:{variant:"indeterminate"},style:Rf||{animation:`${ra} 1.4s linear infinite`}},...Object.entries(e.palette).filter(Zn()).map(([t])=>({props:{color:t},style:{color:(e.vars||e).palette[t].main}}))]}))),If=yt("svg",{name:"MuiCircularProgress",slot:"Svg"})({display:"block"}),Mf=yt("circle",{name:"MuiCircularProgress",slot:"Circle",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.circle,t[`circle${Fe(r.variant)}`],r.disableShrink&&t.circleDisableShrink]}})(gr(({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:$f||{animation:`${na} 1.4s ease-in-out infinite`}}]}))),Sl=ie.forwardRef(function(t,r){const n=br({props:t,name:"MuiCircularProgress"}),{className:i,color:a="primary",disableShrink:s=!1,size:o=40,style:l,thickness:d=3.6,value:u=0,variant:f="indeterminate",...m}=n,x={...n,color:a,disableShrink:s,size:o,thickness:d,value:u,variant:f},S=Df(x),c={},E={},h={};if(f==="determinate"){const _=2*Math.PI*((Pt-d)/2);c.strokeDasharray=_.toFixed(3),h["aria-valuenow"]=Math.round(u),c.strokeDashoffset=`${((100-u)/100*_).toFixed(3)}px`,E.transform="rotate(-90deg)"}return v.jsx(Pf,{className:Ke(S.root,i),style:{width:o,height:o,...E,...l},ownerState:x,ref:r,role:"progressbar",...h,...m,children:v.jsx(If,{className:S.svg,ownerState:x,viewBox:`${Pt/2} ${Pt/2} ${Pt} ${Pt}`,children:v.jsx(Mf,{className:S.circle,style:c,ownerState:x,cx:Pt,cy:Pt,r:(Pt-d)/2,fill:"none",strokeWidth:d})})})});process.env.NODE_ENV!=="production"&&(Sl.propTypes={classes:g.object,className:g.string,color:g.oneOfType([g.oneOf(["inherit","primary","secondary","error","info","success","warning"]),g.string]),disableShrink:ja(g.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:g.oneOfType([g.number,g.string]),style:g.object,sx:g.oneOfType([g.arrayOf(g.oneOfType([g.func,g.object,g.bool])),g.func,g.object]),thickness:g.number,value:g.number,variant:g.oneOf(["determinate","indeterminate"])});function zf(e){return Jt("MuiIconButton",e)}const Qs=xr("MuiIconButton",["root","disabled","colorInherit","colorPrimary","colorSecondary","colorError","colorInfo","colorSuccess","colorWarning","edgeStart","edgeEnd","sizeSmall","sizeMedium","sizeLarge","loading","loadingIndicator","loadingWrapper"]),Vf=e=>{const{classes:t,disabled:r,color:n,edge:i,size:a,loading:s}=e,o={root:["root",s&&"loading",r&&"disabled",n!=="default"&&`color${Fe(n)}`,i&&`edge${Fe(i)}`,`size${Fe(a)}`],loadingIndicator:["loadingIndicator"],loadingWrapper:["loadingWrapper"]};return Qr(o,zf,t)},Nf=yt(wl,{name:"MuiIconButton",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,r.loading&&t.loading,r.color!=="default"&&t[`color${Fe(r.color)}`],r.edge&&t[`edge${Fe(r.edge)}`],t[`size${Fe(r.size)}`]]}})(gr(({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})`:Gn(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}}]})),gr(({theme:e})=>({variants:[{props:{color:"inherit"},style:{color:"inherit"}},...Object.entries(e.palette).filter(Zn()).map(([t])=>({props:{color:t},style:{color:(e.vars||e).palette[t].main}})),...Object.entries(e.palette).filter(Zn()).map(([t])=>({props:{color:t},style:{"--IconButton-hoverBg":e.vars?`rgba(${(e.vars||e).palette[t].mainChannel} / ${e.vars.palette.action.hoverOpacity})`:Gn((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)}}],[`&.${Qs.disabled}`]:{backgroundColor:"transparent",color:(e.vars||e).palette.action.disabled},[`&.${Qs.loading}`]:{color:"transparent"}}))),Bf=yt("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"}}]})),zn=ie.forwardRef(function(t,r){const n=br({props:t,name:"MuiIconButton"}),{edge:i=!1,children:a,className:s,color:o="default",disabled:l=!1,disableFocusRipple:d=!1,size:u="medium",id:f,loading:m=null,loadingIndicator:x,...S}=n,c=rf(f),E=x??v.jsx(Sl,{"aria-labelledby":c,color:"inherit",size:16}),h={...n,edge:i,color:o,disabled:l,disableFocusRipple:d,loading:m,loadingIndicator:E,size:u},_=Vf(h);return v.jsxs(Nf,{id:m?c:f,className:Ke(_.root,s),centerRipple:!0,focusRipple:!d,disabled:l||m,ref:r,...S,ownerState:h,children:[typeof m=="boolean"&&v.jsx("span",{className:_.loadingWrapper,style:{display:"contents"},children:v.jsx(Bf,{className:_.loadingIndicator,ownerState:h,children:m&&E})}),a]})});process.env.NODE_ENV!=="production"&&(zn.propTypes={children:ja(g.node,e=>ie.Children.toArray(e.children).some(r=>ie.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:g.object,className:g.string,color:g.oneOfType([g.oneOf(["inherit","default","primary","secondary","error","info","success","warning"]),g.string]),disabled:g.bool,disableFocusRipple:g.bool,disableRipple:g.bool,edge:g.oneOf(["end","start",!1]),id:g.string,loading:g.bool,loadingIndicator:g.node,size:g.oneOfType([g.oneOf(["small","medium","large"]),g.string]),sx:g.oneOfType([g.arrayOf(g.oneOfType([g.func,g.object,g.bool])),g.func,g.object])});const Ys=kt(v.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"),Gs=kt(v.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"),Lf=kt(v.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"),qf=kt(v.jsx("path",{d:"M9 16.17 4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z"}),"Check"),ei=kt(v.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"),Uf=kt(v.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");async function El(e,t,r,n){try{const{endpoint:i,method:a="GET",valueField:s="value",labelField:o="label",headers:l={},params:d={},body:u,transform:f,dependsOn:m}=e;let x=i;if(t&&!i.startsWith("http")&&(x=`${t}${i.startsWith("/")?i:`/${i}`}`),m&&n){const T=n[m];T&&(x=x.replace(`{${m}}`,encodeURIComponent(T)))}const S=new URLSearchParams;Object.entries(d).forEach(([T,w])=>{w!=null&&S.append(T,String(w))}),S.toString()&&(x+=`${x.includes("?")?"&":"?"}${S.toString()}`);const c={"Content-Type":"application/json",...r,...l},E={method:a,headers:c};(a==="POST"||a==="PUT")&&u&&(E.body=JSON.stringify(u));const h=await fetch(x,E);if(!h.ok)throw new Error(`API request failed: ${h.status} ${h.statusText}`);const _=await h.json();if(f)return f(Array.isArray(_)?_:_.data||_);const $=Array.isArray(_)?_:_.data||_;if(!Array.isArray($))throw new Error("API response is not an array");return $.map(T=>({label:T[o]||T.name||T.title||String(T[s]||""),value:T[s]||T.id||T.value||""}))}catch(i){throw console.error("API fetch error:",i),new Error(`Failed to fetch data: ${i instanceof Error?i.message:"Unknown error"}`)}}function Cl(e,t,r,n,i=!1){const a=I.useMemo(()=>{if(!(e!=null&&e.dependsOn)||!n)return null;const o=n[e.dependsOn];return o!==void 0?o:null},[e==null?void 0:e.dependsOn,n]),s=I.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],[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]);return cu({queryKey:s,queryFn:()=>{if(!e)throw new Error("API config is required");return El(e,t,r,n)},enabled:i&&!!e,staleTime:15*60*1e3,gcTime:30*60*1e3,retry:3,retryDelay:o=>Math.min(1e3*2**o,3e4),refetchOnWindowFocus:!1,refetchOnReconnect:!0,refetchOnMount:!1})}function rr(e){return!!(e.apiConfig||e.api_endpoint)}function Pa(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 Wf(e,t){const r=Pa(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 Tl=({field:e,control:t,errors:r,baseUrl:n,apiHeaders:i,formData:a})=>{const s=r[e.name],o=!!s,[l,d]=I.useState(!1),u=I.useRef(!1),[f,m]=I.useState(!1),[x,S]=I.useState(!1),[c,E]=I.useState(!1),h=I.useRef(null),_=I.useRef(null),$=()=>{var K;return e.required!==void 0?e.required:((K=e.validation)==null?void 0:K.required)!==void 0?e.validation.required:!1},T=K=>$()?`${K} *`:K,w=()=>e.value!==void 0?e.value:e.type==="checkbox"?!1:e.type==="select"&&e.default?e.default:e.type==="autocomplete"&&e.multiple?[]:"",F=I.useMemo(()=>Pa(e),[e.apiConfig,e.api_endpoint,e.api_method,e.value_field,e.label_field,e.depends_on,e.conditional]),X=I.useRef(null),J=F!=null&&F.dependsOn?a==null?void 0:a[F.dependsOn]:null,W=I.useMemo(()=>{if(!(F!=null&&F.dependsOn))return!1;const K=J,se=X.current,ae=K!==se;return ae&&(X.current=K),ae},[F==null?void 0:F.dependsOn,J]),p=I.useMemo(()=>!0,[]),R=I.useMemo(()=>l&&rr(e)&&(!(F!=null&&F.dependsOn)||J),[l,e,F==null?void 0:F.dependsOn,J]),V=I.useMemo(()=>{if(!(F!=null&&F.dependsOn)||!a)return{};const K={};return F.dependsOn&&a[F.dependsOn]!==void 0&&(K[F.dependsOn]=a[F.dependsOn]),K},[F==null?void 0:F.dependsOn,a]),{data:B=[],isLoading:z,error:H}=Cl(F,n,i,V,R),le=I.useCallback(()=>{rr(e)&&!u.current&&(u.current=!0,d(!0))},[e]),ce=I.useCallback(()=>{rr(e)&&!u.current&&(u.current=!0,d(!0))},[e]);I.useEffect(()=>{if(rr(e)&&!u.current){const K=a==null?void 0:a[e.name];K!=null&&K!==""&&(u.current=!0,d(!0))}},[e,a]),I.useEffect(()=>{rr(e)&&(F!=null&&F.dependsOn)&&W&&u.current&&(u.current=!1,d(!1))},[W,F==null?void 0:F.dependsOn]);const pe=I.useCallback(()=>rr(e)?B:e.type==="select"||e.type==="toggle"||e.type==="radio"||e.type==="autocomplete"?e.options||[]:[],[e,B]);if(!p)return null;const oe=()=>{switch(e.type){case"title":return v.jsx(D.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 v.jsx(D.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"text":case"email":case"password":case"tel":case"textarea":return v.jsx(gt,{name:e.name,control:t,defaultValue:w(),render:({field:ee})=>v.jsx(D.TextField,{...ee,id:e.id,fullWidth:!0,label:T(e.label),size:"small",type:e.type==="password"?f?"text":"password":e.type!=="textarea"?e.type:void 0,placeholder:e.placeholder,disabled:e.disabled,error:o,helperText:(s==null?void 0:s.message)||e.helperText,multiline:e.type==="textarea",minRows:e.rows||(e.type==="textarea"?3:void 0),InputProps:e.type==="password"?{endAdornment:v.jsx(gl,{position:"end",children:v.jsx(zn,{"aria-label":"toggle password visibility",onClick:()=>m(q=>!q),edge:"end",children:f?v.jsx(Gs,{}):v.jsx(Ys,{})})})}:void 0})});case"number":return v.jsx(gt,{name:e.name,control:t,defaultValue:w(),render:({field:ee})=>v.jsx(D.TextField,{...ee,id:e.id,fullWidth:!0,label:T(e.label),size:"small",type:"number",placeholder:e.placeholder,disabled:e.disabled,error:o,helperText:s==null?void 0:s.message,inputProps:{min:e.min,max:e.max}})});case"select":const K=pe();return v.jsx(gt,{name:e.name,control:t,defaultValue:w(),render:({field:ee})=>v.jsxs(D.FormControl,{fullWidth:!0,error:o||!!H,size:"small",children:[v.jsx(D.InputLabel,{id:e.id,size:"small",children:T(e.label)}),v.jsx(D.Select,{...ee,labelId:e.id,label:T(e.label),size:"small",disabled:e.disabled||z,endAdornment:z?v.jsx(D.CircularProgress,{size:20}):void 0,onOpen:le,children:z?v.jsx(D.MenuItem,{disabled:!0,children:v.jsxs(D.Box,{sx:{display:"flex",alignItems:"center",gap:1,width:"100%"},children:[v.jsx(D.CircularProgress,{size:16}),v.jsx(D.Typography,{variant:"body2",children:"Fetching data..."})]})}):K.length>0?K.map(q=>v.jsx(D.MenuItem,{value:q.value,children:q.label},q.value)):l&&!z?v.jsx(D.MenuItem,{disabled:!0,children:v.jsx(D.Typography,{variant:"body2",color:"text.secondary",children:"No options available"})}):v.jsx(D.MenuItem,{disabled:!0,children:v.jsx(D.Typography,{variant:"body2",color:"text.secondary",children:"Click to load options"})})}),(o||H||e.helperText)&&v.jsx(D.FormHelperText,{children:(s==null?void 0:s.message)||(H==null?void 0:H.message)||e.helperText})]})});case"checkbox":return v.jsx(gt,{name:e.name,control:t,defaultValue:w(),render:({field:ee})=>v.jsxs(D.Box,{sx:{mt:1,mb:0},children:[v.jsx(D.FormControlLabel,{control:v.jsx(D.Checkbox,{...ee,id:e.id,checked:ee.value,size:"small",disabled:e.disabled}),label:T(e.label)}),(o||e.helperText)&&v.jsx(D.FormHelperText,{error:o,sx:{ml:0},children:(s==null?void 0:s.message)||e.helperText})]})});case"toggle":return v.jsx(gt,{name:e.name,control:t,defaultValue:w(),render:({field:ee})=>v.jsxs(D.FormControl,{component:"fieldset",error:o,children:[v.jsx(D.Typography,{variant:"body2",component:"legend",sx:{mb:1},children:T(e.label)}),v.jsx(D.RadioGroup,{...ee,row:!0,children:e.options.map(q=>v.jsx(D.FormControlLabel,{value:q.value,control:v.jsx(D.Radio,{size:"small"}),label:q.label},q.value))}),(o||e.helperText)&&v.jsx(D.FormHelperText,{error:o,children:(s==null?void 0:s.message)||e.helperText})]})});case"radio":return v.jsx(gt,{name:e.name,control:t,defaultValue:w(),render:({field:ee})=>v.jsxs(D.FormControl,{component:"fieldset",error:o,children:[v.jsx(D.Typography,{variant:"body2",component:"legend",sx:{mb:1},children:T(e.label)}),v.jsx(D.RadioGroup,{...ee,children:e.options.map(q=>v.jsx(D.FormControlLabel,{value:q.value,control:v.jsx(D.Radio,{size:"small"}),label:q.label},q.value))}),o&&v.jsx(D.FormHelperText,{error:!0,children:s==null?void 0:s.message})]})});case"switch":return v.jsx(gt,{name:e.name,control:t,defaultValue:w(),render:({field:ee})=>v.jsxs(D.Box,{sx:{mt:1,mb:0},children:[v.jsx(D.FormControlLabel,{control:v.jsx(D.Switch,{...ee,id:e.id,checked:ee.value,size:"small",disabled:e.disabled}),label:T(e.label)}),(o||e.helperText)&&v.jsx(D.FormHelperText,{error:o,sx:{ml:0},children:(s==null?void 0:s.message)||e.helperText})]})});case"autocomplete":const se=pe(),ae=!!(e.disabled||z||F!=null&&F.dependsOn&&!J);return v.jsx(gt,{name:e.name,control:t,defaultValue:w(),render:({field:ee})=>{const q=ee.value,te=e.multiple===!0,ue=(F==null?void 0:F.valueField)||e.value_field||"value",M=(F==null?void 0:F.labelField)||e.label_field||"label",U=C=>{if(C!=null){if(typeof C=="string"||typeof C=="number")return C;if(typeof C=="object"){if(C[ue]!==void 0)return C[ue];if(C.value!==void 0)return C.value;if(C.id!==void 0)return C.id}}},re=(()=>{if(te)return(Array.isArray(q)?q:[]).map(Q=>{const me=se.find(Te=>{const Be=U(Te);return Be!==void 0&&Be===Q});return me||{[ue]:Q,[M]:`Selected: ${Q}`,value:Q,label:`Selected: ${Q}`}});{if(q==null||q==="")return null;const C=se.find(Q=>{const me=U(Q);return me!==void 0&&me===q});return C||{[ue]:q,[M]:`Selected: ${q}`,value:q,label:`Selected: ${q}`}}})();return v.jsx(D.Autocomplete,{...ee,id:e.id,options:se,value:re,size:"small",getOptionLabel:C=>typeof C=="string"?C:C[M]||C.label||C.name||"",isOptionEqualToValue:(C,Q)=>{const me=U(C),Te=U(Q);return me===void 0||Te===void 0?!1:me===Te},multiple:e.multiple,disableCloseOnSelect:te,freeSolo:e.freeSolo,filterOptions:e.filterOptions===!1?()=>se:void 0,disabled:ae,loading:z,onOpen:ce,renderOption:(C,Q,{selected:me})=>{const Te=typeof Q=="string"?Q:Q[M]||Q.label||Q.name||"";return v.jsxs("li",{...C,children:[te&&v.jsx(D.Checkbox,{style:{marginRight:8},checked:me}),Te]})},renderTags:te?(C,Q)=>{const Te=C.slice(0,2).map((Se,qe)=>{const Je=typeof Se=="string"?Se:Se[M]||Se.label||Se.name||"",y=Q({index:qe});return I.createElement(D.Chip,{...y,key:qe,label:Je,size:"small"})}),Be=C.length-2;return Be>0&&Te.push(v.jsx(D.Chip,{label:`+${Be} more`,size:"small"},"more")),Te}:void 0,renderInput:C=>v.jsx(D.TextField,{...C,label:T(e.label),size:"small",placeholder:ae&&(F!=null&&F.dependsOn)&&!J?`Please select ${F.dependsOn.replace(/_/g," ")} first`:e.placeholder,error:o||!!H,helperText:(s==null?void 0:s.message)||(H==null?void 0:H.message)||e.helperText||"",InputProps:{...C.InputProps,endAdornment:v.jsxs(v.Fragment,{children:[z?v.jsx(D.CircularProgress,{color:"inherit",size:20}):null,C.InputProps.endAdornment]})}}),onChange:(C,Q)=>{const me=(F==null?void 0:F.valueField)||e.value_field||"value";if(te){const Be=(Array.isArray(Q)?Q:[]).map(Se=>typeof Se=="object"&&(Se[me]||Se.value||Se.id)||Se);ee.onChange(Be)}else{let Te;Q&&typeof Q=="object"?Te=Q[me]||Q.value||Q.id||Q:Te=Q,ee.onChange(Te)}},noOptionsText:ae&&(F!=null&&F.dependsOn)&&!J?`Please select ${F.dependsOn.replace(/_/g," ")} first`:z?"Fetching data...":l&&!z&&se.length===0?"No options available":"Click to load options"})}});case"date":return v.jsx(gt,{name:e.name,control:t,defaultValue:w(),render:({field:ee})=>v.jsx(D.TextField,{...ee,id:e.name,fullWidth:!0,label:T(e.label),size:"small",type:"date",disabled:e.disabled,error:o,helperText:s==null?void 0:s.message,InputLabelProps:{shrink:!0},inputProps:{min:e.minDate,max:e.maxDate}})});case"image":return v.jsx(gt,{name:e.name,control:t,defaultValue:w(),render:({field:ee})=>{const q=ee.value||e.defaultValue||e.src;if(q){const C=e.imageUploaded||{},Q=C.previewText||"Preview",me=C.removeText||"Remove",Te=C.saveText||"Save logo",Be=C.showSave!==void 0?C.showSave:!!(e.onSave||C.saveText),Se=()=>{if(E(!0),typeof e.onPreview=="function")try{e.onPreview(q)}catch{}},qe=()=>{ee.onChange(""),typeof e.onRemove=="function"&&e.onRemove()},Je=()=>{typeof e.onSave=="function"&&e.onSave({url:q,file:_.current||void 0})},y=O=>{const k=O.target.files&&O.target.files[0];if(k){if(typeof e.onFileSelected=="function")try{e.onFileSelected(k)}catch{}try{const Z=URL.createObjectURL(k);ee.onChange(Z)}catch{}_.current=k,E(!1)}};return v.jsxs(D.Card,{sx:{display:"flex",alignItems:"center",gap:2,p:2,boxShadow:"0px 1px 4px 0px #00000014",...C.cardSx},children:[v.jsx("input",{type:"file",ref:h,accept:Array.isArray(e.accept)?e.accept.join(","):e.accept||"image/*",style:{display:"none"},onChange:y}),v.jsxs(D.Box,{sx:{display:"flex",flexDirection:"column",gap:1},children:[v.jsx(D.Box,{sx:{width:"30%",height:"10%",display:"flex",alignItems:"center",justifyContent:"center",borderRadius:"6px",background:"#FFFFFF",overflow:"hidden",...C.thumbnailSx},children:v.jsx("img",{src:q,alt:e.alt||e.label,style:{maxWidth:"100%",maxHeight:"100%"}})}),v.jsxs(D.Box,{sx:{flexGrow:1},children:[v.jsx(D.Typography,{sx:{fontSize:"12px",fontWeight:500,...C.fileNameSx},children:typeof q=="string"?q.split("/").pop():"Selected image"}),v.jsx(D.Typography,{sx:{fontSize:"10px",...C.fileMetaSx},children:"Image selected"})]}),v.jsxs(D.Box,{sx:{display:"flex",gap:1},children:[v.jsx(D.Button,{type:"button",sx:{...C.previewButtonSx},variant:"outlined",onClick:Se,startIcon:v.jsx(Ys,{}),children:Q}),v.jsx(D.Button,{variant:"outlined",color:"error",onClick:qe,sx:{...C.removeButtonSx},startIcon:v.jsx(Gs,{}),children:me}),Be&&v.jsx(D.Button,{variant:"contained",onClick:Je,sx:{...C.saveButtonSx},children:Te})]})]}),v.jsxs(D.Dialog,{open:c,onClose:()=>E(!1),maxWidth:"md",fullWidth:!0,children:[v.jsx(D.DialogTitle,{children:C.previewTitle||"Image preview"}),v.jsx(D.DialogContent,{children:v.jsx(D.Box,{sx:{display:"flex",alignItems:"center",justifyContent:"center",borderRadius:"8px",border:"1px solid",borderColor:"divider",backgroundColor:"background.paper",p:1,minHeight:260},children:v.jsx("img",{src:q,alt:e.alt||e.label,style:{maxWidth:"100%",maxHeight:380}})})}),v.jsxs(D.DialogActions,{children:[v.jsx(D.Button,{type:"button",variant:"outlined",onClick:()=>{var O;return(O=h.current)==null?void 0:O.click()},children:C.replaceText||"Replace logo"}),v.jsx(D.Button,{type:"button",variant:"contained",onClick:()=>E(!1),children:C.closeText||"Close"})]})]})]})}const te=e.imagePlaceholder||{},ue=te.icon||"upload",M=h,U=()=>{var C;try{(C=M.current)==null||C.click()}catch{}},re=C=>{const Q=C.target.files&&C.target.files[0];if(Q){typeof e.onFileSelected=="function"&&e.onFileSelected(Q);try{const me=URL.createObjectURL(Q);ee.onChange(me)}catch{}_.current=Q}};return v.jsxs(D.Card,{sx:{border:"1px dashed",borderColor:"#CCCCCC",boxShadow:"none",p:2,textAlign:"center",color:"primary.main",...te.sx},children:[v.jsx("input",{type:"file",ref:M,accept:Array.isArray(e.accept)?e.accept.join(","):e.accept||"image/*",style:{display:"none"},onChange:re}),v.jsx(zn,{sx:{borderRadius:"8px",...te.iconSx},children:ue==="image"?v.jsx(Uf,{sx:{width:36,height:36,color:"primary.main"}}):v.jsx(ei,{sx:{width:36,height:36,color:"primary.main"}})}),v.jsx(D.Typography,{sx:{fontSize:"16px",fontWeight:600,color:"primary.main",...te.titleSx},children:te.title||"Drag & Drop the image here"}),v.jsx(D.Typography,{sx:{fontSize:"12px",fontWeight:400,color:"primary.main",...te.subtitleSx},children:te.subtitle||""}),v.jsx(D.Button,{onClick:U,sx:{my:2,...te.buttonSx},startIcon:v.jsx(ei,{}),variant:"contained",disabled:e.disabled,children:te.buttonText||"Upload File"}),v.jsx(D.Typography,{sx:{fontSize:"12px",fontWeight:400,...te.helperTextSx},children:te.helperText||e.helperText||""})]})}});case"component":return v.jsx(D.Box,{children:e.render?e.render():e.content});default:return null}},N=I.useMemo(()=>!e.disabled||e.copyWhenDisabled===!1?!1:!["title","section","image","component"].includes(e.type),[e.disabled,e.copyWhenDisabled,e.type]),L=I.useCallback(async()=>{try{const K=a?a[e.name]:void 0;let se="";K==null?se="":Array.isArray(K)?se=K.join(", "):typeof K=="object"?se=JSON.stringify(K):se=String(K),await navigator.clipboard.writeText(se),S(!0),window.setTimeout(()=>S(!1),1200)}catch{}},[a,e.name]);return v.jsxs(D.Box,{sx:{display:"flex",alignItems:"center",gap:.3},children:[v.jsx(D.Box,{sx:{flexGrow:1},children:oe()}),N&&v.jsx(zn,{"aria-label":`copy ${e.label||e.name}`,onClick:L,size:"small",children:x?v.jsx(qf,{fontSize:"small"}):v.jsx(Lf,{fontSize:"small"})})]})};var Fi,Zs;function Hf(){if(Zs)return Fi;Zs=1;function e(h){this._maxSize=h,this.clear()}e.prototype.clear=function(){this._size=0,this._values=Object.create(null)},e.prototype.get=function(h){return this._values[h]},e.prototype.set=function(h,_){return this._size>=this._maxSize&&this.clear(),h in this._values||this._size++,this._values[h]=_};var t=/[^.^\]^[]+|(?=\[\]|\.\.)/g,r=/^\d+$/,n=/^\d/,i=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,a=/^\s*(['"]?)(.*?)(\1)\s*$/,s=512,o=new e(s),l=new e(s),d=new e(s);Fi={Cache:e,split:f,normalizePath:u,setter:function(h){var _=u(h);return l.get(h)||l.set(h,function(T,w){for(var F=0,X=_.length,J=T;F<X-1;){var W=_[F];if(W==="__proto__"||W==="constructor"||W==="prototype")return T;J=J[_[F++]]}J[_[F]]=w})},getter:function(h,_){var $=u(h);return d.get(h)||d.set(h,function(w){for(var F=0,X=$.length;F<X;)if(w!=null||!_)w=w[$[F++]];else return;return w})},join:function(h){return h.reduce(function(_,$){return _+(x($)||r.test($)?"["+$+"]":(_?".":"")+$)},"")},forEach:function(h,_,$){m(Array.isArray(h)?h:f(h),_,$)}};function u(h){return o.get(h)||o.set(h,f(h).map(function(_){return _.replace(a,"$2")}))}function f(h){return h.match(t)||[""]}function m(h,_,$){var T=h.length,w,F,X,J;for(F=0;F<T;F++)w=h[F],w&&(E(w)&&(w='"'+w+'"'),J=x(w),X=!J&&/^\d+$/.test(w),_.call($,w,J,X,F,h))}function x(h){return typeof h=="string"&&h&&["'",'"'].indexOf(h.charAt(0))!==-1}function S(h){return h.match(n)&&!h.match(r)}function c(h){return i.test(h)}function E(h){return!x(h)&&(S(h)||c(h))}return Fi}var hr=Hf(),ji,Xs;function Kf(){if(Xs)return ji;Xs=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,f)=>t(u).join(f).toLowerCase(),i=u=>t(u).reduce((f,m)=>`${f}${f?m[0].toUpperCase()+m.slice(1).toLowerCase():m.toLowerCase()}`,"");return ji={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(" ")},ji}var Ri=Kf(),jn={exports:{}},Js;function Qf(){if(Js)return jn.exports;Js=1,jn.exports=function(i){return e(t(i),i)},jn.exports.array=e;function e(i,a){var s=i.length,o=new Array(s),l={},d=s,u=r(a),f=n(i);for(a.forEach(function(x){if(!f.has(x[0])||!f.has(x[1]))throw new Error("Unknown node. There is an unknown node in the supplied edges.")});d--;)l[d]||m(i[d],d,new Set);return o;function m(x,S,c){if(c.has(x)){var E;try{E=", node was:"+JSON.stringify(x)}catch{E=""}throw new Error("Cyclic dependency"+E)}if(!f.has(x))throw new Error("Found unknown node. Make sure to provided all involved nodes. Unknown node: "+JSON.stringify(x));if(!l[S]){l[S]=!0;var h=u.get(x)||new Set;if(h=Array.from(h),S=h.length){c.add(x);do{var _=h[--S];m(_,f.get(_),c)}while(S);c.delete(x)}o[--s]=x}}}function t(i){for(var a=new Set,s=0,o=i.length;s<o;s++){var l=i[s];a.add(l[0]),a.add(l[1])}return Array.from(a)}function r(i){for(var a=new Map,s=0,o=i.length;s<o;s++){var l=i[s];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,s=0,o=i.length;s<o;s++)a.set(i[s],s);return a}return jn.exports}var Yf=Qf();const Gf=Sa(Yf),Zf=Object.prototype.toString,Xf=Error.prototype.toString,Jf=RegExp.prototype.toString,em=typeof Symbol<"u"?Symbol.prototype.toString:()=>"",tm=/^Symbol\((.*)\)(.*)$/;function rm(e){return e!=+e?"NaN":e===0&&1/e<0?"-0":""+e}function eo(e,t=!1){if(e==null||e===!0||e===!1)return""+e;const r=typeof e;if(r==="number")return rm(e);if(r==="string")return t?`"${e}"`:e;if(r==="function")return"[Function "+(e.name||"anonymous")+"]";if(r==="symbol")return em.call(e).replace(tm,"Symbol($1)");const n=Zf.call(e).slice(8,-1);return n==="Date"?isNaN(e.getTime())?""+e:e.toISOString(e):n==="Error"||e instanceof Error?"["+Xf.call(e)+"]":n==="RegExp"?Jf.call(e):null}function Yt(e,t){let r=eo(e,t);return r!==null?r:JSON.stringify(e,function(n,i){let a=eo(this[n],t);return a!==null?a:i},2)}function kl(e){return e==null?[]:[].concat(e)}let Ol,_l,Al,nm=/\$\{\s*(\w+)\s*\}/g;Ol=Symbol.toStringTag;class to{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[Ol]="Error",this.name="ValidationError",this.value=r,this.path=n,this.type=i,this.errors=[],this.inner=[],kl(t).forEach(a=>{if(Xe.isError(a)){this.errors.push(...a.errors);const s=a.inner.length?a.inner:[a];this.inner.push(...s)}else this.errors.push(a)}),this.message=this.errors.length>1?`${this.errors.length} errors occurred`:this.errors[0]}}_l=Symbol.hasInstance;Al=Symbol.toStringTag;class Xe 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(nm,(i,a)=>Yt(r[a])):typeof t=="function"?t(r):t}static isError(t){return t&&t.name==="ValidationError"}constructor(t,r,n,i,a){const s=new to(t,r,n,i);if(a)return s;super(),this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=[],this.inner=[],this[Al]="Error",this.name=s.name,this.message=s.message,this.type=s.type,this.value=s.value,this.path=s.path,this.errors=s.errors,this.inner=s.inner,Error.captureStackTrace&&Error.captureStackTrace(this,Xe)}static[_l](t){return to[Symbol.hasInstance](t)||super[Symbol.hasInstance](t)}}let bt={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 \`${Yt(n,!0)}\`).`:".";return t!=="mixed"?`${e} must be a \`${t}\` type, but the final value was: \`${Yt(r,!0)}\``+i:`${e} must match the configured type. The validated value was: \`${Yt(r,!0)}\``+i}},Qe={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"},Mt={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"},ia={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"},aa={isValue:"${path} field must be ${value}"},Vn={noUnknown:"${path} field has unspecified keys: ${unknown}",exact:"${path} object contains unknown properties: ${properties}"},im={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"},am={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: \`${Yt(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: \`${Yt(r,!0)}\``}return Xe.formatError(bt.notType,e)}};Object.assign(Object.create(null),{mixed:bt,string:Qe,number:Mt,date:ia,object:Vn,array:im,boolean:aa,tuple:am});const Ia=e=>e&&e.__isYupSchema__;class ti{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,s=typeof n=="function"?n:(...o)=>o.every(l=>l===n);return new ti(t,(o,l)=>{var d;let u=s(...o)?i:a;return(d=u==null?void 0:u(l))!=null?d: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(!Ia(i))throw new TypeError("conditions must return a schema object");return i.resolve(r)}}const Rn={context:"$",value:"."};class wr{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]===Rn.context,this.isValue=this.key[0]===Rn.value,this.isSibling=!this.isContext&&!this.isValue;let n=this.isContext?Rn.context:this.isValue?Rn.value:"";this.path=this.key.slice(n.length),this.getter=this.path&&hr.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}}wr.prototype.__isYupRef=!0;const ht=e=>e==null;function jr(e){function t({value:r,path:n="",options:i,originalValue:a,schema:s},o,l){const{name:d,test:u,params:f,message:m,skipAbsent:x}=e;let{parent:S,context:c,abortEarly:E=s.spec.abortEarly,disableStackTrace:h=s.spec.disableStackTrace}=i;function _(R){return wr.isRef(R)?R.getValue(r,S,c):R}function $(R={}){const V=Object.assign({value:r,originalValue:a,label:s.spec.label,path:R.path||n,spec:s.spec,disableStackTrace:R.disableStackTrace||h},f,R.params);for(const z of Object.keys(V))V[z]=_(V[z]);const B=new Xe(Xe.formatError(R.message||m,V),r,V.path,R.type||d,V.disableStackTrace);return B.params=V,B}const T=E?o:l;let w={path:n,parent:S,type:d,from:i.from,createError:$,resolve:_,options:i,originalValue:a,schema:s};const F=R=>{Xe.isError(R)?T(R):R?l(null):T($())},X=R=>{Xe.isError(R)?T(R):o(R)};if(x&&ht(r))return F(!0);let W;try{var p;if(W=u.call(w,r,w),typeof((p=W)==null?void 0:p.then)=="function"){if(i.sync)throw new Error(`Validation test of type: "${w.type}" returned a Promise during a synchronous validate. This test will finish after the validate call has returned`);return Promise.resolve(W).then(F,X)}}catch(R){X(R);return}F(W)}return t.OPTIONS=e,t}function sm(e,t,r,n=r){let i,a,s;return t?(hr.forEach(t,(o,l,d)=>{let u=l?o.slice(1,o.length-1):o;e=e.resolve({context:n,parent:i,value:r});let f=e.type==="tuple",m=d?parseInt(u,10):0;if(e.innerType||f){if(f&&!d)throw new Error(`Yup.reach cannot implicitly index into a tuple type. the path part "${s}" must contain an index to the tuple element, e.g. "${s}[0]"`);if(r&&m>=r.length)throw new Error(`Yup.reach cannot resolve an array item at index: ${o}, in the path: ${t}. because there is no value at that index. `);i=r,r=r&&r[m],e=f?e.spec.types[m]:e.innerType}if(!d){if(!e.fields||!e.fields[u])throw new Error(`The schema does not contain the path: ${t}. (failed at: ${s} which is a type: "${e.type}")`);i=r,r=r&&r[u],e=e.fields[u]}a=u,s=l?"["+o+"]":"."+o}),{schema:e,parent:i,parentPath:a}):{parent:i,parentPath:t,schema:e}}class ri extends Set{describe(){const t=[];for(const r of this.values())t.push(wr.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 ri(this.values())}merge(t,r){const n=this.clone();return t.forEach(i=>n.add(i)),r.forEach(i=>n.delete(i)),n}}function Rr(e,t=new Map){if(Ia(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]=Rr(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,Rr(i,t))}else if(e instanceof Set){r=new Set,t.set(e,r);for(const n of e)r.add(Rr(n,t))}else if(e instanceof Object){r={},t.set(e,r);for(const[n,i]of Object.entries(e))r[n]=Rr(i,t)}else throw Error(`Unable to clone ${e}`);return r}class nt{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 ri,this._blacklist=new ri,this.exclusiveTests=Object.create(null),this._typeCheck=void 0,this.spec=void 0,this.tests=[],this.transforms=[],this.withMutation(()=>{this.typeError(bt.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=Rr(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(s=>{a.test(s.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&&ht(a))return a;let s=Yt(t),o=Yt(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,Df=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 Qr(a,jf,t)},Pf=yt("span",{name:"MuiCircularProgress",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,t[r.variant],t[`color${Re(r.color)}`]]}})(gr(({theme:e})=>({display:"inline-block",variants:[{props:{variant:"determinate"},style:{transition:e.transitions.create("transform")}},{props:{variant:"indeterminate"},style:Rf||{animation:`${ra} 1.4s linear infinite`}},...Object.entries(e.palette).filter(Zn()).map(([t])=>({props:{color:t},style:{color:(e.vars||e).palette[t].main}}))]}))),If=yt("svg",{name:"MuiCircularProgress",slot:"Svg"})({display:"block"}),Mf=yt("circle",{name:"MuiCircularProgress",slot:"Circle",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.circle,t[`circle${Re(r.variant)}`],r.disableShrink&&t.circleDisableShrink]}})(gr(({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:$f||{animation:`${na} 1.4s ease-in-out infinite`}}]}))),Sl=ie.forwardRef(function(t,r){const n=br({props:t,name:"MuiCircularProgress"}),{className:i,color:a="primary",disableShrink:s=!1,size:o=40,style:l,thickness:f=3.6,value:u=0,variant:p="indeterminate",...m}=n,x={...n,color:a,disableShrink:s,size:o,thickness:f,value:u,variant:p},w=Df(x),c={},E={},y={};if(p==="determinate"){const C=2*Math.PI*((Pt-f)/2);c.strokeDasharray=C.toFixed(3),y["aria-valuenow"]=Math.round(u),c.strokeDashoffset=`${((100-u)/100*C).toFixed(3)}px`,E.transform="rotate(-90deg)"}return v.jsx(Pf,{className:Qe(w.root,i),style:{width:o,height:o,...E,...l},ownerState:x,ref:r,role:"progressbar",...y,...m,children:v.jsx(If,{className:w.svg,ownerState:x,viewBox:`${Pt/2} ${Pt/2} ${Pt} ${Pt}`,children:v.jsx(Mf,{className:w.circle,style:c,ownerState:x,cx:Pt,cy:Pt,r:(Pt-f)/2,fill:"none",strokeWidth:f})})})});process.env.NODE_ENV!=="production"&&(Sl.propTypes={classes:g.object,className:g.string,color:g.oneOfType([g.oneOf(["inherit","primary","secondary","error","info","success","warning"]),g.string]),disableShrink:ja(g.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:g.oneOfType([g.number,g.string]),style:g.object,sx:g.oneOfType([g.arrayOf(g.oneOfType([g.func,g.object,g.bool])),g.func,g.object]),thickness:g.number,value:g.number,variant:g.oneOf(["determinate","indeterminate"])});function zf(e){return Jt("MuiIconButton",e)}const Qs=xr("MuiIconButton",["root","disabled","colorInherit","colorPrimary","colorSecondary","colorError","colorInfo","colorSuccess","colorWarning","edgeStart","edgeEnd","sizeSmall","sizeMedium","sizeLarge","loading","loadingIndicator","loadingWrapper"]),Vf=e=>{const{classes:t,disabled:r,color:n,edge:i,size:a,loading:s}=e,o={root:["root",s&&"loading",r&&"disabled",n!=="default"&&`color${Re(n)}`,i&&`edge${Re(i)}`,`size${Re(a)}`],loadingIndicator:["loadingIndicator"],loadingWrapper:["loadingWrapper"]};return Qr(o,zf,t)},Nf=yt(wl,{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)}`]]}})(gr(({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})`:Gn(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}}]})),gr(({theme:e})=>({variants:[{props:{color:"inherit"},style:{color:"inherit"}},...Object.entries(e.palette).filter(Zn()).map(([t])=>({props:{color:t},style:{color:(e.vars||e).palette[t].main}})),...Object.entries(e.palette).filter(Zn()).map(([t])=>({props:{color:t},style:{"--IconButton-hoverBg":e.vars?`rgba(${(e.vars||e).palette[t].mainChannel} / ${e.vars.palette.action.hoverOpacity})`:Gn((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)}}],[`&.${Qs.disabled}`]:{backgroundColor:"transparent",color:(e.vars||e).palette.action.disabled},[`&.${Qs.loading}`]:{color:"transparent"}}))),Bf=yt("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"}}]})),zn=ie.forwardRef(function(t,r){const n=br({props:t,name:"MuiIconButton"}),{edge:i=!1,children:a,className:s,color:o="default",disabled:l=!1,disableFocusRipple:f=!1,size:u="medium",id:p,loading:m=null,loadingIndicator:x,...w}=n,c=rf(p),E=x??v.jsx(Sl,{"aria-labelledby":c,color:"inherit",size:16}),y={...n,edge:i,color:o,disabled:l,disableFocusRipple:f,loading:m,loadingIndicator:E,size:u},C=Vf(y);return v.jsxs(Nf,{id:m?c:p,className:Qe(C.root,s),centerRipple:!0,focusRipple:!f,disabled:l||m,ref:r,...w,ownerState:y,children:[typeof m=="boolean"&&v.jsx("span",{className:C.loadingWrapper,style:{display:"contents"},children:v.jsx(Bf,{className:C.loadingIndicator,ownerState:y,children:m&&E})}),a]})});process.env.NODE_ENV!=="production"&&(zn.propTypes={children:ja(g.node,e=>ie.Children.toArray(e.children).some(r=>ie.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:g.object,className:g.string,color:g.oneOfType([g.oneOf(["inherit","default","primary","secondary","error","info","success","warning"]),g.string]),disabled:g.bool,disableFocusRipple:g.bool,disableRipple:g.bool,edge:g.oneOf(["end","start",!1]),id:g.string,loading:g.bool,loadingIndicator:g.node,size:g.oneOfType([g.oneOf(["small","medium","large"]),g.string]),sx:g.oneOfType([g.arrayOf(g.oneOfType([g.func,g.object,g.bool])),g.func,g.object])});const Ys=Ct(v.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"),Gs=Ct(v.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"),Lf=Ct(v.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"),qf=Ct(v.jsx("path",{d:"M9 16.17 4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z"}),"Check"),ei=Ct(v.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"),Uf=Ct(v.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");async function El(e,t,r,n){try{const{endpoint:i,method:a="GET",valueField:s="value",labelField:o="label",headers:l={},params:f={},body:u,transform:p,dependsOn:m,passThroughFields:x}=e;let w=i;if(t&&!i.startsWith("http")&&(w=`${t}${i.startsWith("/")?i:`/${i}`}`),n){const b=/\{([^}]+)\}/g;w=w.replace(b,(L,j)=>{const ee=n[j];return ee!=null?encodeURIComponent(String(ee)):""}),w=w.replace(/\?&/g,"?").replace(/&&/g,"&").replace(/\?$/g,"")}const c=new URLSearchParams;Object.entries(f).forEach(([b,L])=>{L!=null&&c.append(b,String(L))}),c.toString()&&(w+=`${w.includes("?")?"&":"?"}${c.toString()}`);const E={"Content-Type":"application/json",...r,...l},y={method:a,headers:E};(a==="POST"||a==="PUT")&&u&&(y.body=JSON.stringify(u));const C=await fetch(w,y);if(!C.ok)throw new Error(`API request failed: ${C.status} ${C.statusText}`);const A=await C.json();if(p)return p(Array.isArray(A)?A:A.data||A);const _=Array.isArray(A)?A:A.data||A;if(!Array.isArray(_))throw new Error("API response is not an array");return _.map(b=>{const L={label:b[o]||b.name||b.title||String(b[s]||""),value:b[s]||b.id||b.value||""},j=Array.isArray(x)?x:void 0;if(Array.isArray(j))for(const ee of j)b[ee]!==void 0&&(L[ee]=b[ee]);return L})}catch(i){throw console.error("API fetch error:",i),new Error(`Failed to fetch data: ${i instanceof Error?i.message:"Unknown error"}`)}}function Tl(e,t,r,n,i=!1){const a=D.useMemo(()=>{if(!(e!=null&&e.dependsOn)||!n)return null;const o=n[e.dependsOn];return o!==void 0?o:null},[e==null?void 0:e.dependsOn,n]),s=D.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 cu({queryKey:s,queryFn:()=>{if(!e)throw new Error("API config is required");return El(e,t,r,n)},enabled:i&&!!e,staleTime:15*60*1e3,gcTime:30*60*1e3,retry:3,retryDelay:o=>Math.min(1e3*2**o,3e4),refetchOnWindowFocus:!1,refetchOnReconnect:!0,refetchOnMount:!1})}function rr(e){return!!(e.apiConfig||e.api_endpoint)}function Pa(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 Wf(e,t){const r=Pa(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 kl=({field:e,control:t,errors:r,baseUrl:n,apiHeaders:i,formData:a,setValue:s})=>{const o=r[e.name],l=!!o,[f,u]=D.useState(!1),p=D.useRef(!1),[m,x]=D.useState(!1),[w,c]=D.useState(!1),[E,y]=D.useState(!1),C=D.useRef(null),A=D.useRef(null),_=()=>{var Q;return e.required!==void 0?e.required:((Q=e.validation)==null?void 0:Q.required)!==void 0?e.validation.required:!1},b=Q=>_()?`${Q} *`:Q,L=()=>e.value!==void 0?e.value:e.type==="checkbox"?!1:e.type==="select"&&e.default?e.default:e.type==="autocomplete"&&e.multiple?[]:"",j=D.useMemo(()=>{const Q=Pa(e);return Q&&Array.isArray(e.passThroughFields)&&(Q.passThroughFields=e.passThroughFields),Q},[e.apiConfig,e.api_endpoint,e.api_method,e.value_field,e.label_field,e.depends_on,e.conditional,e.passThroughFields]),ee=D.useRef(null),K=j!=null&&j.dependsOn?a==null?void 0:a[j.dependsOn]:null,d=D.useMemo(()=>{if(!(j!=null&&j.dependsOn))return!1;const Q=K,te=ee.current,le=Q!==te;return le&&(ee.current=Q),le},[j==null?void 0:j.dependsOn,K]),z=D.useMemo(()=>!0,[]),P=D.useMemo(()=>f&&rr(e)&&(!(j!=null&&j.dependsOn)||K),[f,e,j==null?void 0:j.dependsOn,K]),q=D.useMemo(()=>{const Q={};if(!a)return Q;const te=(j==null?void 0:j.endpoint)||(e==null?void 0:e.api_endpoint);if(te&&typeof te=="string"){const le=te.match(/\{([^}]+)\}/g)||[];for(const W of le){const H=W.slice(1,-1),ae=a[H];ae!==void 0&&(Q[H]=ae)}}if(j!=null&&j.dependsOn){const le=j.dependsOn,W=a[le];W!==void 0&&(Q[le]=W)}return Q},[j==null?void 0:j.endpoint,e==null?void 0:e.api_endpoint,j==null?void 0:j.dependsOn,a]),{data:N=[],isLoading:Y,error:re}=Tl(j,n,i,q,P),me=D.useCallback(()=>{rr(e)&&!p.current&&(p.current=!0,u(!0))},[e]),ce=D.useCallback(()=>{rr(e)&&!p.current&&(p.current=!0,u(!0))},[e]);D.useEffect(()=>{if(rr(e)&&!p.current){const Q=a==null?void 0:a[e.name];Q!=null&&Q!==""&&(p.current=!0,u(!0))}},[e,a]),D.useEffect(()=>{rr(e)&&(j!=null&&j.dependsOn)&&d&&p.current&&(p.current=!1,u(!1))},[d,j==null?void 0:j.dependsOn]);const oe=D.useCallback(()=>rr(e)?N:e.type==="select"||e.type==="toggle"||e.type==="radio"||e.type==="autocomplete"?e.options||[]:[],[e,N]);if(!z)return null;const V=()=>{switch(e.type){case"title":return v.jsx(R.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 v.jsx(R.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"text":case"email":case"password":case"tel":case"textarea":return v.jsx(gt,{name:e.name,control:t,defaultValue:L(),render:({field:W})=>v.jsx(R.TextField,{...W,id:e.id,fullWidth:!0,label:b(e.label),size:"small",type:e.type==="password"?m?"text":"password":e.type!=="textarea"?e.type:void 0,placeholder:e.placeholder,disabled:e.disabled,error:l,helperText:(o==null?void 0:o.message)||e.helperText,multiline:e.type==="textarea",minRows:e.rows||(e.type==="textarea"?3:void 0),InputProps:e.type==="password"?{endAdornment:v.jsx(gl,{position:"end",children:v.jsx(zn,{"aria-label":"toggle password visibility",onClick:()=>x(H=>!H),edge:"end",children:m?v.jsx(Gs,{}):v.jsx(Ys,{})})})}:void 0})});case"number":return v.jsx(gt,{name:e.name,control:t,defaultValue:L(),render:({field:W})=>v.jsx(R.TextField,{...W,id:e.id,fullWidth:!0,label:b(e.label),size:"small",type:"number",placeholder:e.placeholder,disabled:e.disabled,error:l,helperText:o==null?void 0:o.message,inputProps:{min:e.min,max:e.max}})});case"select":const Q=oe();return v.jsx(gt,{name:e.name,control:t,defaultValue:L(),render:({field:W})=>v.jsxs(R.FormControl,{fullWidth:!0,error:l||!!re,size:"small",children:[v.jsx(R.InputLabel,{id:e.id,size:"small",children:b(e.label)}),v.jsx(R.Select,{...W,labelId:e.id,label:b(e.label),size:"small",disabled:e.disabled||Y,endAdornment:Y?v.jsx(R.CircularProgress,{size:20}):void 0,onOpen:me,children:Y?v.jsx(R.MenuItem,{disabled:!0,children:v.jsxs(R.Box,{sx:{display:"flex",alignItems:"center",gap:1,width:"100%"},children:[v.jsx(R.CircularProgress,{size:16}),v.jsx(R.Typography,{variant:"body2",children:"Fetching data..."})]})}):Q.length>0?Q.map(H=>v.jsx(R.MenuItem,{value:H.value,children:H.label},H.value)):f&&!Y?v.jsx(R.MenuItem,{disabled:!0,children:v.jsx(R.Typography,{variant:"body2",color:"text.secondary",children:"No options available"})}):v.jsx(R.MenuItem,{disabled:!0,children:v.jsx(R.Typography,{variant:"body2",color:"text.secondary",children:"Click to load options"})})}),(l||re||e.helperText)&&v.jsx(R.FormHelperText,{children:(o==null?void 0:o.message)||(re==null?void 0:re.message)||e.helperText})]})});case"checkbox":return v.jsx(gt,{name:e.name,control:t,defaultValue:L(),render:({field:W})=>v.jsxs(R.Box,{sx:{mt:1,mb:0},children:[v.jsx(R.FormControlLabel,{control:v.jsx(R.Checkbox,{...W,id:e.id,checked:W.value,size:"small",disabled:e.disabled}),label:b(e.label)}),(l||e.helperText)&&v.jsx(R.FormHelperText,{error:l,sx:{ml:0},children:(o==null?void 0:o.message)||e.helperText})]})});case"toggle":return v.jsx(gt,{name:e.name,control:t,defaultValue:L(),render:({field:W})=>v.jsxs(R.FormControl,{component:"fieldset",error:l,children:[v.jsx(R.Typography,{variant:"body2",component:"legend",sx:{mb:1},children:b(e.label)}),v.jsx(R.RadioGroup,{...W,row:!0,children:e.options.map(H=>v.jsx(R.FormControlLabel,{value:H.value,control:v.jsx(R.Radio,{size:"small"}),label:H.label},H.value))}),(l||e.helperText)&&v.jsx(R.FormHelperText,{error:l,children:(o==null?void 0:o.message)||e.helperText})]})});case"radio":return v.jsx(gt,{name:e.name,control:t,defaultValue:L(),render:({field:W})=>v.jsxs(R.FormControl,{component:"fieldset",error:l,children:[v.jsx(R.Typography,{variant:"body2",component:"legend",sx:{mb:1},children:b(e.label)}),v.jsx(R.RadioGroup,{...W,children:e.options.map(H=>v.jsx(R.FormControlLabel,{value:H.value,control:v.jsx(R.Radio,{size:"small"}),label:H.label},H.value))}),l&&v.jsx(R.FormHelperText,{error:!0,children:o==null?void 0:o.message})]})});case"switch":return v.jsx(gt,{name:e.name,control:t,defaultValue:L(),render:({field:W})=>v.jsxs(R.Box,{sx:{mt:1,mb:0},children:[v.jsx(R.FormControlLabel,{control:v.jsx(R.Switch,{...W,id:e.id,checked:W.value,size:"small",disabled:e.disabled}),label:b(e.label)}),(l||e.helperText)&&v.jsx(R.FormHelperText,{error:l,sx:{ml:0},children:(o==null?void 0:o.message)||e.helperText})]})});case"autocomplete":const te=oe(),le=!!(e.disabled||Y||j!=null&&j.dependsOn&&!K);return v.jsx(gt,{name:e.name,control:t,defaultValue:L(),render:({field:W})=>{const H=W.value,ae=e.multiple===!0,pe=(j==null?void 0:j.valueField)||e.value_field||"value",M=(j==null?void 0:j.labelField)||e.label_field||"label",se=B=>{if(B!=null){if(typeof B=="string"||typeof B=="number")return B;if(typeof B=="object"){if(B[pe]!==void 0)return B[pe];if(B.value!==void 0)return B.value;if(B.id!==void 0)return B.id}}},I=(()=>{if(ae)return(Array.isArray(H)?H:[]).map(G=>{const ye=te.find(Fe=>{const _e=se(Fe);return _e!==void 0&&_e===G});return ye||{[pe]:G,[M]:`Selected: ${G}`,value:G,label:`Selected: ${G}`}});{if(H==null||H==="")return null;const B=te.find(G=>{const ye=se(G);return ye!==void 0&&ye===H});return B||{[pe]:H,[M]:`Selected: ${H}`,value:H,label:`Selected: ${H}`}}})();return v.jsx(R.Autocomplete,{...W,id:e.id,options:te,value:I,size:"small",getOptionLabel:B=>typeof B=="string"?B:B[M]||B.label||B.name||"",isOptionEqualToValue:(B,G)=>{const ye=se(B),Fe=se(G);return ye===void 0||Fe===void 0?!1:ye===Fe},multiple:e.multiple,disableCloseOnSelect:ae,freeSolo:e.freeSolo,filterOptions:e.filterOptions===!1?()=>te:void 0,disabled:le,loading:Y,onOpen:ce,renderOption:(B,G,{selected:ye})=>{const Fe=typeof G=="string"?G:G[M]||G.label||G.name||"";return v.jsxs("li",{...B,children:[ae&&v.jsx(R.Checkbox,{style:{marginRight:8},checked:ye}),Fe]})},renderTags:ae?(B,G)=>{const Fe=B.slice(0,2).map((ke,qe)=>{const h=typeof ke=="string"?ke:ke[M]||ke.label||ke.name||"",k=G({index:qe});return D.createElement(R.Chip,{...k,key:qe,label:h,size:"small"})}),_e=B.length-2;return _e>0&&Fe.push(v.jsx(R.Chip,{label:`+${_e} more`,size:"small"},"more")),Fe}:void 0,renderInput:B=>v.jsx(R.TextField,{...B,label:b(e.label),size:"small",placeholder:le&&(j!=null&&j.dependsOn)&&!K?`Please select ${j.dependsOn.replace(/_/g," ")} first`:e.placeholder,error:l||!!re,helperText:(o==null?void 0:o.message)||(re==null?void 0:re.message)||e.helperText||"",InputProps:{...B.InputProps,endAdornment:v.jsxs(v.Fragment,{children:[Y?v.jsx(R.CircularProgress,{color:"inherit",size:20}):null,B.InputProps.endAdornment]})}}),onChange:(B,G)=>{const ye=(j==null?void 0:j.valueField)||e.value_field||"value";if(ae){const _e=(Array.isArray(G)?G:[]).map(ke=>typeof ke=="object"&&(ke[ye]||ke.value||ke.id)||ke);W.onChange(_e)}else{let Fe;G&&typeof G=="object"?Fe=G[ye]||G.value||G.id||G:Fe=G,W.onChange(Fe);const _e=e.selectedAssignments;if(_e&&G&&typeof G=="object")for(const[ke,qe]of Object.entries(_e)){const h=G[qe];if(h!==void 0&&typeof s=="function")try{s(ke,h,{shouldDirty:!0,shouldTouch:!0,shouldValidate:!1})}catch{}}}},noOptionsText:le&&(j!=null&&j.dependsOn)&&!K?`Please select ${j.dependsOn.replace(/_/g," ")} first`:Y?"Fetching data...":f&&!Y&&te.length===0?"No options available":"Click to load options"})}});case"date":return v.jsx(gt,{name:e.name,control:t,defaultValue:L(),render:({field:W})=>v.jsx(R.TextField,{...W,id:e.name,fullWidth:!0,label:b(e.label),size:"small",type:"date",disabled:e.disabled,error:l,helperText:o==null?void 0:o.message,InputLabelProps:{shrink:!0},inputProps:{min:e.minDate,max:e.maxDate}})});case"image":return v.jsx(gt,{name:e.name,control:t,defaultValue:L(),render:({field:W})=>{const H=W.value||e.defaultValue||e.src;if(H){const B=e.imageUploaded||{},G=B.previewText||"Preview",ye=B.removeText||"Remove",Fe=B.saveText||"Save logo",_e=B.showSave!==void 0?B.showSave:!!(e.onSave||B.saveText),ke=()=>{if(y(!0),typeof e.onPreview=="function")try{e.onPreview(H)}catch{}},qe=()=>{W.onChange(""),typeof e.onRemove=="function"&&e.onRemove()},h=()=>{typeof e.onSave=="function"&&e.onSave({url:H,file:A.current||void 0})},k=T=>{const Z=T.target.files&&T.target.files[0];if(Z){if(typeof e.onFileSelected=="function")try{e.onFileSelected(Z)}catch{}try{const O=URL.createObjectURL(Z);W.onChange(O)}catch{}A.current=Z,y(!1)}};return v.jsxs(R.Card,{sx:{display:"flex",alignItems:"center",gap:2,p:2,boxShadow:"0px 1px 4px 0px #00000014",...B.cardSx},children:[v.jsx("input",{type:"file",ref:C,accept:Array.isArray(e.accept)?e.accept.join(","):e.accept||"image/*",style:{display:"none"},onChange:k}),v.jsxs(R.Box,{sx:{display:"flex",flexDirection:"column",gap:1},children:[v.jsx(R.Box,{sx:{width:"30%",height:"10%",display:"flex",alignItems:"center",justifyContent:"center",borderRadius:"6px",background:"#FFFFFF",overflow:"hidden",...B.thumbnailSx},children:v.jsx("img",{src:H,alt:e.alt||e.label,style:{maxWidth:"100%",maxHeight:"100%"}})}),v.jsxs(R.Box,{sx:{flexGrow:1},children:[v.jsx(R.Typography,{sx:{fontSize:"12px",fontWeight:500,...B.fileNameSx},children:typeof H=="string"?H.split("/").pop():"Selected image"}),v.jsx(R.Typography,{sx:{fontSize:"10px",...B.fileMetaSx},children:"Image selected"})]}),v.jsxs(R.Box,{sx:{display:"flex",gap:1},children:[v.jsx(R.Button,{type:"button",sx:{...B.previewButtonSx},variant:"outlined",onClick:ke,startIcon:v.jsx(Ys,{}),children:G}),v.jsx(R.Button,{variant:"outlined",color:"error",onClick:qe,sx:{...B.removeButtonSx},startIcon:v.jsx(Gs,{}),children:ye}),_e&&v.jsx(R.Button,{variant:"contained",onClick:h,sx:{...B.saveButtonSx},children:Fe})]})]}),v.jsxs(R.Dialog,{open:E,onClose:()=>y(!1),maxWidth:"md",fullWidth:!0,children:[v.jsx(R.DialogTitle,{children:B.previewTitle||"Image preview"}),v.jsx(R.DialogContent,{children:v.jsx(R.Box,{sx:{display:"flex",alignItems:"center",justifyContent:"center",borderRadius:"8px",border:"1px solid",borderColor:"divider",backgroundColor:"background.paper",p:1,minHeight:260},children:v.jsx("img",{src:H,alt:e.alt||e.label,style:{maxWidth:"100%",maxHeight:380}})})}),v.jsxs(R.DialogActions,{children:[v.jsx(R.Button,{type:"button",variant:"outlined",onClick:()=>{var T;return(T=C.current)==null?void 0:T.click()},children:B.replaceText||"Replace logo"}),v.jsx(R.Button,{type:"button",variant:"contained",onClick:()=>y(!1),children:B.closeText||"Close"})]})]})]})}const ae=e.imagePlaceholder||{},pe=ae.icon||"upload",M=C,se=()=>{var B;try{(B=M.current)==null||B.click()}catch{}},I=B=>{const G=B.target.files&&B.target.files[0];if(G){typeof e.onFileSelected=="function"&&e.onFileSelected(G);try{const ye=URL.createObjectURL(G);W.onChange(ye)}catch{}A.current=G}};return v.jsxs(R.Card,{sx:{border:"1px dashed",borderColor:"#CCCCCC",boxShadow:"none",p:2,textAlign:"center",color:"primary.main",...ae.sx},children:[v.jsx("input",{type:"file",ref:M,accept:Array.isArray(e.accept)?e.accept.join(","):e.accept||"image/*",style:{display:"none"},onChange:I}),v.jsx(zn,{sx:{borderRadius:"8px",...ae.iconSx},children:pe==="image"?v.jsx(Uf,{sx:{width:36,height:36,color:"primary.main"}}):v.jsx(ei,{sx:{width:36,height:36,color:"primary.main"}})}),v.jsx(R.Typography,{sx:{fontSize:"16px",fontWeight:600,color:"primary.main",...ae.titleSx},children:ae.title||"Drag & Drop the image here"}),v.jsx(R.Typography,{sx:{fontSize:"12px",fontWeight:400,color:"primary.main",...ae.subtitleSx},children:ae.subtitle||""}),v.jsx(R.Button,{onClick:se,sx:{my:2,...ae.buttonSx},startIcon:v.jsx(ei,{}),variant:"contained",disabled:e.disabled,children:ae.buttonText||"Upload File"}),v.jsx(R.Typography,{sx:{fontSize:"12px",fontWeight:400,...ae.helperTextSx},children:ae.helperText||e.helperText||""})]})}});case"component":return v.jsx(R.Box,{children:e.render?e.render():e.content});default:return null}},U=D.useMemo(()=>!e.disabled||e.copyWhenDisabled===!1?!1:!["title","section","image","component"].includes(e.type),[e.disabled,e.copyWhenDisabled,e.type]),ue=D.useCallback(async()=>{try{const Q=a?a[e.name]:void 0;let te="";Q==null?te="":Array.isArray(Q)?te=Q.join(", "):typeof Q=="object"?te=JSON.stringify(Q):te=String(Q),await navigator.clipboard.writeText(te),c(!0),window.setTimeout(()=>c(!1),1200)}catch{}},[a,e.name]);return v.jsxs(R.Box,{sx:{display:"flex",alignItems:"center",gap:.3},children:[v.jsx(R.Box,{sx:{flexGrow:1},children:V()}),U&&v.jsx(zn,{"aria-label":`copy ${e.label||e.name}`,onClick:ue,size:"small",children:w?v.jsx(qf,{fontSize:"small"}):v.jsx(Lf,{fontSize:"small"})})]})};var Fi,Zs;function Hf(){if(Zs)return Fi;Zs=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,C){return this._size>=this._maxSize&&this.clear(),y in this._values||this._size++,this._values[y]=C};var t=/[^.^\]^[]+|(?=\[\]|\.\.)/g,r=/^\d+$/,n=/^\d/,i=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,a=/^\s*(['"]?)(.*?)(\1)\s*$/,s=512,o=new e(s),l=new e(s),f=new e(s);Fi={Cache:e,split:p,normalizePath:u,setter:function(y){var C=u(y);return l.get(y)||l.set(y,function(_,b){for(var L=0,j=C.length,ee=_;L<j-1;){var K=C[L];if(K==="__proto__"||K==="constructor"||K==="prototype")return _;ee=ee[C[L++]]}ee[C[L]]=b})},getter:function(y,C){var A=u(y);return f.get(y)||f.set(y,function(b){for(var L=0,j=A.length;L<j;)if(b!=null||!C)b=b[A[L++]];else return;return b})},join:function(y){return y.reduce(function(C,A){return C+(x(A)||r.test(A)?"["+A+"]":(C?".":"")+A)},"")},forEach:function(y,C,A){m(Array.isArray(y)?y:p(y),C,A)}};function u(y){return o.get(y)||o.set(y,p(y).map(function(C){return C.replace(a,"$2")}))}function p(y){return y.match(t)||[""]}function m(y,C,A){var _=y.length,b,L,j,ee;for(L=0;L<_;L++)b=y[L],b&&(E(b)&&(b='"'+b+'"'),ee=x(b),j=!ee&&/^\d+$/.test(b),C.call(A,b,ee,j,L,y))}function x(y){return typeof y=="string"&&y&&["'",'"'].indexOf(y.charAt(0))!==-1}function w(y){return y.match(n)&&!y.match(r)}function c(y){return i.test(y)}function E(y){return!x(y)&&(w(y)||c(y))}return Fi}var hr=Hf(),ji,Xs;function Kf(){if(Xs)return ji;Xs=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,p)=>t(u).join(p).toLowerCase(),i=u=>t(u).reduce((p,m)=>`${p}${p?m[0].toUpperCase()+m.slice(1).toLowerCase():m.toLowerCase()}`,"");return ji={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(" ")},ji}var Ri=Kf(),jn={exports:{}},Js;function Qf(){if(Js)return jn.exports;Js=1,jn.exports=function(i){return e(t(i),i)},jn.exports.array=e;function e(i,a){var s=i.length,o=new Array(s),l={},f=s,u=r(a),p=n(i);for(a.forEach(function(x){if(!p.has(x[0])||!p.has(x[1]))throw new Error("Unknown node. There is an unknown node in the supplied edges.")});f--;)l[f]||m(i[f],f,new Set);return o;function m(x,w,c){if(c.has(x)){var E;try{E=", node was:"+JSON.stringify(x)}catch{E=""}throw new Error("Cyclic dependency"+E)}if(!p.has(x))throw new Error("Found unknown node. Make sure to provided all involved nodes. Unknown node: "+JSON.stringify(x));if(!l[w]){l[w]=!0;var y=u.get(x)||new Set;if(y=Array.from(y),w=y.length){c.add(x);do{var C=y[--w];m(C,p.get(C),c)}while(w);c.delete(x)}o[--s]=x}}}function t(i){for(var a=new Set,s=0,o=i.length;s<o;s++){var l=i[s];a.add(l[0]),a.add(l[1])}return Array.from(a)}function r(i){for(var a=new Map,s=0,o=i.length;s<o;s++){var l=i[s];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,s=0,o=i.length;s<o;s++)a.set(i[s],s);return a}return jn.exports}var Yf=Qf();const Gf=Sa(Yf),Zf=Object.prototype.toString,Xf=Error.prototype.toString,Jf=RegExp.prototype.toString,em=typeof Symbol<"u"?Symbol.prototype.toString:()=>"",tm=/^Symbol\((.*)\)(.*)$/;function rm(e){return e!=+e?"NaN":e===0&&1/e<0?"-0":""+e}function eo(e,t=!1){if(e==null||e===!0||e===!1)return""+e;const r=typeof e;if(r==="number")return rm(e);if(r==="string")return t?`"${e}"`:e;if(r==="function")return"[Function "+(e.name||"anonymous")+"]";if(r==="symbol")return em.call(e).replace(tm,"Symbol($1)");const n=Zf.call(e).slice(8,-1);return n==="Date"?isNaN(e.getTime())?""+e:e.toISOString(e):n==="Error"||e instanceof Error?"["+Xf.call(e)+"]":n==="RegExp"?Jf.call(e):null}function Yt(e,t){let r=eo(e,t);return r!==null?r:JSON.stringify(e,function(n,i){let a=eo(this[n],t);return a!==null?a:i},2)}function Cl(e){return e==null?[]:[].concat(e)}let Ol,_l,Al,nm=/\$\{\s*(\w+)\s*\}/g;Ol=Symbol.toStringTag;class to{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[Ol]="Error",this.name="ValidationError",this.value=r,this.path=n,this.type=i,this.errors=[],this.inner=[],Cl(t).forEach(a=>{if(Je.isError(a)){this.errors.push(...a.errors);const s=a.inner.length?a.inner:[a];this.inner.push(...s)}else this.errors.push(a)}),this.message=this.errors.length>1?`${this.errors.length} errors occurred`:this.errors[0]}}_l=Symbol.hasInstance;Al=Symbol.toStringTag;class Je 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(nm,(i,a)=>Yt(r[a])):typeof t=="function"?t(r):t}static isError(t){return t&&t.name==="ValidationError"}constructor(t,r,n,i,a){const s=new to(t,r,n,i);if(a)return s;super(),this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=[],this.inner=[],this[Al]="Error",this.name=s.name,this.message=s.message,this.type=s.type,this.value=s.value,this.path=s.path,this.errors=s.errors,this.inner=s.inner,Error.captureStackTrace&&Error.captureStackTrace(this,Je)}static[_l](t){return to[Symbol.hasInstance](t)||super[Symbol.hasInstance](t)}}let bt={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 \`${Yt(n,!0)}\`).`:".";return t!=="mixed"?`${e} must be a \`${t}\` type, but the final value was: \`${Yt(r,!0)}\``+i:`${e} must match the configured type. The validated value was: \`${Yt(r,!0)}\``+i}},Ye={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"},Mt={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"},ia={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"},aa={isValue:"${path} field must be ${value}"},Vn={noUnknown:"${path} field has unspecified keys: ${unknown}",exact:"${path} object contains unknown properties: ${properties}"},im={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"},am={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: \`${Yt(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: \`${Yt(r,!0)}\``}return Je.formatError(bt.notType,e)}};Object.assign(Object.create(null),{mixed:bt,string:Ye,number:Mt,date:ia,object:Vn,array:im,boolean:aa,tuple:am});const Ia=e=>e&&e.__isYupSchema__;class ti{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,s=typeof n=="function"?n:(...o)=>o.every(l=>l===n);return new ti(t,(o,l)=>{var f;let u=s(...o)?i:a;return(f=u==null?void 0:u(l))!=null?f: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(!Ia(i))throw new TypeError("conditions must return a schema object");return i.resolve(r)}}const Rn={context:"$",value:"."};class wr{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]===Rn.context,this.isValue=this.key[0]===Rn.value,this.isSibling=!this.isContext&&!this.isValue;let n=this.isContext?Rn.context:this.isValue?Rn.value:"";this.path=this.key.slice(n.length),this.getter=this.path&&hr.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}}wr.prototype.__isYupRef=!0;const ht=e=>e==null;function jr(e){function t({value:r,path:n="",options:i,originalValue:a,schema:s},o,l){const{name:f,test:u,params:p,message:m,skipAbsent:x}=e;let{parent:w,context:c,abortEarly:E=s.spec.abortEarly,disableStackTrace:y=s.spec.disableStackTrace}=i;function C(z){return wr.isRef(z)?z.getValue(r,w,c):z}function A(z={}){const P=Object.assign({value:r,originalValue:a,label:s.spec.label,path:z.path||n,spec:s.spec,disableStackTrace:z.disableStackTrace||y},p,z.params);for(const N of Object.keys(P))P[N]=C(P[N]);const q=new Je(Je.formatError(z.message||m,P),r,P.path,z.type||f,P.disableStackTrace);return q.params=P,q}const _=E?o:l;let b={path:n,parent:w,type:f,from:i.from,createError:A,resolve:C,options:i,originalValue:a,schema:s};const L=z=>{Je.isError(z)?_(z):z?l(null):_(A())},j=z=>{Je.isError(z)?_(z):o(z)};if(x&&ht(r))return L(!0);let K;try{var d;if(K=u.call(b,r,b),typeof((d=K)==null?void 0:d.then)=="function"){if(i.sync)throw new Error(`Validation test of type: "${b.type}" returned a Promise during a synchronous validate. This test will finish after the validate call has returned`);return Promise.resolve(K).then(L,j)}}catch(z){j(z);return}L(K)}return t.OPTIONS=e,t}function sm(e,t,r,n=r){let i,a,s;return t?(hr.forEach(t,(o,l,f)=>{let u=l?o.slice(1,o.length-1):o;e=e.resolve({context:n,parent:i,value:r});let p=e.type==="tuple",m=f?parseInt(u,10):0;if(e.innerType||p){if(p&&!f)throw new Error(`Yup.reach cannot implicitly index into a tuple type. the path part "${s}" must contain an index to the tuple element, e.g. "${s}[0]"`);if(r&&m>=r.length)throw new Error(`Yup.reach cannot resolve an array item at index: ${o}, in the path: ${t}. because there is no value at that index. `);i=r,r=r&&r[m],e=p?e.spec.types[m]:e.innerType}if(!f){if(!e.fields||!e.fields[u])throw new Error(`The schema does not contain the path: ${t}. (failed at: ${s} which is a type: "${e.type}")`);i=r,r=r&&r[u],e=e.fields[u]}a=u,s=l?"["+o+"]":"."+o}),{schema:e,parent:i,parentPath:a}):{parent:i,parentPath:t,schema:e}}class ri extends Set{describe(){const t=[];for(const r of this.values())t.push(wr.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 ri(this.values())}merge(t,r){const n=this.clone();return t.forEach(i=>n.add(i)),r.forEach(i=>n.delete(i)),n}}function Rr(e,t=new Map){if(Ia(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]=Rr(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,Rr(i,t))}else if(e instanceof Set){r=new Set,t.set(e,r);for(const n of e)r.add(Rr(n,t))}else if(e instanceof Object){r={},t.set(e,r);for(const[n,i]of Object.entries(e))r[n]=Rr(i,t)}else throw Error(`Unable to clone ${e}`);return r}class nt{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 ri,this._blacklist=new ri,this.exclusiveTests=Object.create(null),this._typeCheck=void 0,this.spec=void 0,this.tests=[],this.transforms=[],this.withMutation(()=>{this.typeError(bt.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=Rr(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(s=>{a.test(s.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&&ht(a))return a;let s=Yt(t),o=Yt(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: ${s}
179
- `+(o!==s?`result of cast: ${o}`:""))}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:s=t,strict:o=this.spec.strict}=r,l=t;o||(l=this._cast(l,Object.assign({assert:!1},r)));let d=[];for(let u of Object.values(this.internalTests))u&&d.push(u);this.runTests({path:a,value:l,originalValue:s,options:r,tests:d},n,u=>{if(u.length)return i(u,l);this.runTests({path:a,value:l,originalValue:s,options:r,tests:this.tests},n,i)})}runTests(t,r,n){let i=!1,{tests:a,value:s,originalValue:o,path:l,options:d}=t,u=c=>{i||(i=!0,r(c,s))},f=c=>{i||(i=!0,n(c,s))},m=a.length,x=[];if(!m)return f([]);let S={value:s,originalValue:o,path:l,options:d,schema:this};for(let c=0;c<a.length;c++){const E=a[c];E(S,u,function(_){_&&(Array.isArray(_)?x.push(..._):x.push(_)),--m<=0&&f(x)})}}asNestedTest({key:t,index:r,parent:n,parentPath:i,originalParent:a,options:s}){const o=t??r;if(o==null)throw TypeError("Must include `key` or `index` for nested validations");const l=typeof o=="number";let d=n[o];const u=Object.assign({},s,{strict:!0,parent:n,value:d,originalValue:a[o],key:void 0,[l?"index":"key"]:o,path:l||o.includes(".")?`${i||""}[${l?o:`"${o}"`}]`:(i?`${i}.`:"")+t});return(f,m,x)=>this.resolve(u)._validate(d,u,m,x)}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((s,o)=>i._validate(t,r,(l,d)=>{Xe.isError(l)&&(l.value=d),o(l)},(l,d)=>{l.length?o(new Xe(l,d,void 0,void 0,a)):s(d)}))}validateSync(t,r){var n;let i=this.resolve(Object.assign({},r,{value:t})),a,s=(n=r==null?void 0:r.disableStackTrace)!=null?n:i.spec.disableStackTrace;return i._validate(t,Object.assign({},r,{sync:!0}),(o,l)=>{throw Xe.isError(o)&&(o.value=l),o},(o,l)=>{if(o.length)throw new Xe(o,t,void 0,void 0,s);a=l}),a}isValid(t,r){return this.validate(t,r).then(()=>!0,n=>{if(Xe.isError(n))return!1;throw n})}isValidSync(t,r){try{return this.validateSync(t,r),!0}catch(n){if(Xe.isError(n))return!1;throw n}}_getDefault(t){let r=this.spec.default;return r==null?r:typeof r=="function"?r.call(this,t):Rr(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=jr({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=jr({message:r,name:"optionality",test(i){return i===void 0?this.schema.spec.optional:!0}}),n}optional(){return this.optionality(!0)}defined(t=bt.defined){return this.optionality(!1,t)}nullable(){return this.nullability(!0)}nonNullable(t=bt.notNull){return this.nullability(!1,t)}required(t=bt.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=bt.default),typeof r.test!="function")throw new TypeError("`test` is a required parameters");let n=this.clone(),i=jr(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(s=>!(s.OPTIONS.name===r.name&&(a||s.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=kl(t).map(a=>new wr(a));return i.forEach(a=>{a.isSibling&&n.deps.push(a.key)}),n.conditions.push(typeof r=="function"?new ti(i,r):ti.fromOptions(i,r)),n}typeError(t){let r=this.clone();return r.internalTests.typeError=jr({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=bt.oneOf){let n=this.clone();return t.forEach(i=>{n._whitelist.add(i),n._blacklist.delete(i)}),n.internalTests.whiteList=jr({message:r,name:"oneOf",skipAbsent:!0,test(i){let a=this.schema._whitelist,s=a.resolveAll(this.resolve);return s.includes(i)?!0:this.createError({params:{values:Array.from(a).join(", "),resolved:s}})}}),n}notOneOf(t,r=bt.notOneOf){let n=this.clone();return t.forEach(i=>{n._blacklist.add(i),n._whitelist.delete(i)}),n.internalTests.blacklist=jr({message:r,name:"notOneOf",test(i){let a=this.schema._blacklist,s=a.resolveAll(this.resolve);return s.includes(i)?this.createError({params:{values:Array.from(a).join(", "),resolved:s}}):!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:s}=r.spec;return{meta:i,label:n,optional:a,nullable:s,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,d,u)=>u.findIndex(f=>f.name===l.name)===d)}}}nt.prototype.__isYupSchema__=!0;for(const e of["validate","validateSync"])nt.prototype[`${e}At`]=function(t,r,n={}){const{parent:i,parentPath:a,schema:s}=sm(this,t,r,n.context);return s[e](i&&i[a],Object.assign({},n,{parent:i,path:t}))};for(const e of["equals","is"])nt.prototype[e]=nt.prototype.oneOf;for(const e of["not","nope"])nt.prototype[e]=nt.prototype.notOneOf;const om=()=>!0;function Fl(e){return new jl(e)}class jl extends nt{constructor(t){super(typeof t=="function"?{type:"mixed",check:t}:Object.assign({type:"mixed",check:om},t))}}Fl.prototype=jl.prototype;function Rl(){return new $l}class $l extends nt{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=aa.isValue){return this.test({message:t,name:"is-value",exclusive:!0,params:{value:"true"},test(r){return ht(r)||r===!0}})}isFalse(t=aa.isValue){return this.test({message:t,name:"is-value",exclusive:!0,params:{value:"false"},test(r){return ht(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)}}Rl.prototype=$l.prototype;const lm=/^(\d{4}|[+-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,.](\d{1,}))?)?(?:(Z)|([+-])(\d{2})(?::?(\d{2}))?)?)?$/;function cm(e){const t=sa(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 sa(e){var t,r;const n=lm.exec(e);return n?{year:Ft(n[1]),month:Ft(n[2],1)-1,day:Ft(n[3],1),hour:Ft(n[4]),minute:Ft(n[5]),second:Ft(n[6]),millisecond:n[7]?Ft(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:Ft(n[10]),minuteOffset:Ft(n[11])}:null}function Ft(e,t=0){return Number(e)||t}let um=/^[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])?)*$/,pm=/^((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,dm=/^(?:[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,fm="^\\d{4}-\\d{2}-\\d{2}",mm="\\d{2}:\\d{2}:\\d{2}",hm="(([+-]\\d{2}(:?\\d{2})?)|Z)",ym=new RegExp(`${fm}T${mm}(\\.\\d+)?${hm}$`),gm=e=>ht(e)||e===e.trim(),vm={}.toString();function sn(){return new Dl}class Dl extends nt{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===vm?t:i})})}required(t){return super.required(t).withMutation(r=>r.test({message:t||bt.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=Qe.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=Qe.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=Qe.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||Qe.matches,params:{regex:t},skipAbsent:!0,test:s=>s===""&&n||s.search(t)!==-1})}email(t=Qe.email){return this.matches(um,{name:"email",message:t,excludeEmptyString:!0})}url(t=Qe.url){return this.matches(pm,{name:"url",message:t,excludeEmptyString:!0})}uuid(t=Qe.uuid){return this.matches(dm,{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(ym,{name:"datetime",message:r||Qe.datetime,excludeEmptyString:!0}).test({name:"datetime_offset",message:r||Qe.datetime_offset,params:{allowOffset:n},skipAbsent:!0,test:a=>{if(!a||n)return!0;const s=sa(a);return s?!!s.z:!1}}).test({name:"datetime_precision",message:r||Qe.datetime_precision,params:{precision:i},skipAbsent:!0,test:a=>{if(!a||i==null)return!0;const s=sa(a);return s?s.precision===i:!1}})}ensure(){return this.default("").transform(t=>t===null?"":t)}trim(t=Qe.trim){return this.transform(r=>r!=null?r.trim():r).test({message:t,name:"trim",test:gm})}lowercase(t=Qe.lowercase){return this.transform(r=>ht(r)?r:r.toLowerCase()).test({message:t,name:"string_case",exclusive:!0,skipAbsent:!0,test:r=>ht(r)||r===r.toLowerCase()})}uppercase(t=Qe.uppercase){return this.transform(r=>ht(r)?r:r.toUpperCase()).test({message:t,name:"string_case",exclusive:!0,skipAbsent:!0,test:r=>ht(r)||r===r.toUpperCase()})}}sn.prototype=Dl.prototype;let xm=e=>e!=+e;function Pl(){return new Il}class Il extends nt{constructor(){super({type:"number",check(t){return t instanceof Number&&(t=t.valueOf()),typeof t=="number"&&!xm(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=Mt.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=Mt.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=Mt.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=Mt.moreThan){return this.test({message:r,name:"min",exclusive:!0,params:{more:t},skipAbsent:!0,test(n){return n>this.resolve(t)}})}positive(t=Mt.positive){return this.moreThan(0,t)}negative(t=Mt.negative){return this.lessThan(0,t)}integer(t=Mt.integer){return this.test({name:"integer",message:t,skipAbsent:!0,test:r=>Number.isInteger(r)})}truncate(){return this.transform(t=>ht(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=>ht(i)?i:Math[t](i))}}Pl.prototype=Il.prototype;let Ml=new Date(""),bm=e=>Object.prototype.toString.call(e)==="[object Date]";function Ma(){return new En}class En extends nt{constructor(){super({type:"date",check(t){return bm(t)&&!isNaN(t.getTime())}}),this.withMutation(()=>{this.transform((t,r,n)=>!n.spec.coerce||n.isType(t)||t===null?t:(t=cm(t),isNaN(t)?En.INVALID_DATE:new Date(t)))})}prepareParam(t,r){let n;if(wr.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=ia.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=ia.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)}})}}En.INVALID_DATE=Ml;Ma.prototype=En.prototype;Ma.INVALID_DATE=Ml;function wm(e,t=[]){let r=[],n=new Set,i=new Set(t.map(([s,o])=>`${s}-${o}`));function a(s,o){let l=hr.split(s)[0];n.add(l),i.has(`${o}-${l}`)||r.push([o,l])}for(const s of Object.keys(e)){let o=e[s];n.add(s),wr.isRef(o)&&o.isSibling?a(o.path,s):Ia(o)&&"deps"in o&&o.deps.forEach(l=>a(l,s))}return Gf.array(Array.from(n),r).reverse()}function ro(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 zl(e){return(t,r)=>ro(e,t)-ro(e,r)}const Sm=(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 Nn(e){if("fields"in e){const t={};for(const[r,n]of Object.entries(e.fields))t[r]=Nn(n);return e.setFields(t)}if(e.type==="array"){const t=e.optional();return t.innerType&&(t.innerType=Nn(t.innerType)),t}return e.type==="tuple"?e.optional().clone({types:e.spec.types.map(Nn)}):"optional"in e?e.optional():e}const Em=(e,t)=>{const r=[...hr.normalizePath(t)];if(r.length===1)return r[0]in e;let n=r.pop(),i=hr.getter(hr.join(r),!0)(e);return!!(i&&n in i)};let no=e=>Object.prototype.toString.call(e)==="[object Object]";function io(e,t){let r=Object.keys(e.fields);return Object.keys(t).filter(n=>r.indexOf(n)===-1)}const Cm=zl([]);function Vl(e){return new Nl(e)}class Nl extends nt{constructor(t){super({type:"object",check(r){return no(r)||typeof r=="function"}}),this.fields=Object.create(null),this._sortErrors=Cm,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,s=(n=r.stripUnknown)!=null?n:this.spec.noUnknown,o=[].concat(this._nodes,Object.keys(i).filter(f=>!this._nodes.includes(f))),l={},d=Object.assign({},r,{parent:l,__validating:r.__validating||!1}),u=!1;for(const f of o){let m=a[f],x=f in i;if(m){let S,c=i[f];d.path=(r.path?`${r.path}.`:"")+f,m=m.resolve({value:c,context:r.context,parent:l});let E=m instanceof nt?m.spec:void 0,h=E==null?void 0:E.strict;if(E!=null&&E.strip){u=u||f in i;continue}S=!r.__validating||!h?m.cast(i[f],d):i[f],S!==void 0&&(l[f]=S)}else x&&!s&&(l[f]=i[f]);(x!==f in l||l[f]!==i[f])&&(u=!0)}return u?l:i}_validate(t,r={},n,i){let{from:a=[],originalValue:s=t,recursive:o=this.spec.recursive}=r;r.from=[{schema:this,value:s},...a],r.__validating=!0,r.originalValue=s,super._validate(t,r,n,(l,d)=>{if(!o||!no(d)){i(l,d);return}s=s||d;let u=[];for(let f of this._nodes){let m=this.fields[f];!m||wr.isRef(m)||u.push(m.asNestedTest({options:r,key:f,parent:d,parentPath:r.path,originalParent:s}))}this.runTests({tests:u,value:d,originalValue:s,options:r},n,f=>{i(f.sort(this._sortErrors).concat(l),d)})})}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 s=n[i];n[i]=s===void 0?a:s}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 s=t;(i=s)!=null&&i.value&&(s=Object.assign({},s,{parent:s.value,value:s.value[n]})),r[n]=a&&"getDefault"in a?a.getDefault(s):void 0}),r}setFields(t,r){let n=this.clone();return n.fields=t,n._nodes=wm(t,r),n._sortErrors=zl(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 Nn(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=hr.getter(t,!0);return this.transform(a=>{if(!a)return a;let s=a;return Em(a,t)&&(s=Object.assign({},a),n||delete s[t],s[r]=i(a)),s})}json(){return this.transform(Sm)}exact(t){return this.test({name:"exact",exclusive:!0,message:t||Vn.exact,test(r){if(r==null)return!0;const n=io(this.schema,r);return n.length===0||this.createError({params:{properties:n.join(", ")}})}})}stripUnknown(){return this.clone({noUnknown:!0})}noUnknown(t=!0,r=Vn.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=io(this.schema,i);return!t||a.length===0||this.createError({params:{unknown:a.join(", ")}})}});return n.spec.noUnknown=t,n}unknown(t=!0,r=Vn.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(Ri.camelCase)}snakeCase(){return this.transformKeys(Ri.snakeCase)}constantCase(){return this.transformKeys(t=>Ri.snakeCase(t).toUpperCase())}describe(t){const r=(t?this.resolve(t):this).clone(),n=super.describe(t);n.fields={};for(const[a,s]of Object.entries(r.fields)){var i;let o=t;(i=o)!=null&&i.value&&(o=Object.assign({},o,{parent:o.value,value:o.value[a]})),n.fields[a]=s.describe(o)}return n}}Vl.prototype=Nl.prototype;const Bl=e=>{const t={};return e.forEach(r=>{var a,s,o;let n;switch(r.type){case"text":case"textarea":case"tel":n=sn(),r.validation?n=tr(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=sn().email(((a=r.validation)==null?void 0:a.message)||`${r.label} must be a valid email address`),r.validation&&(n=tr(n,r,"string"));break;case"password":n=sn(),r.validation?n=tr(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=Pl().typeError(`${r.label} must be a number`),r.validation?n=tr(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=sn(),r.validation&&(n=tr(n,r,"string"));break;case"checkbox":n=Rl(),r.validation&&(n=tr(n,r,"boolean"));break;case"date":n=Ma().typeError(`${r.label} must be a valid date`),r.validation?n=tr(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=Fl()}if(((s=r.validation)==null?void 0:s.required)!==void 0?r.validation.required:r.required){const l=((o=r.validation)==null?void 0:o.message)||`${r.label} is required`;n=n.required(l)}t[r.name]=n}),Vl().shape(t)},tr=(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,s=>s?i.test(s):!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},Ll=({currentStep:e,totalSteps:t,onStepChange:r,stepTitles:n=[],showStepTitles:i=!0,completedSteps:a=[]})=>{const s=I.useMemo(()=>Array.from({length:t},(u,f)=>f+1),[t]),o=I.useMemo(()=>Math.round(e/t*100),[e,t]),l=u=>n[u-1]||`Step ${u}`,d=u=>u===e||a.includes(u)||u===e+1&&a.includes(e);return v.jsxs(D.Card,{sx:{mb:2,p:2,boxShadow:"0px 1px 4px 0px #00000014",background:"#F8F8F8",borderRadius:"4px"},children:[v.jsxs(D.Box,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between",mb:2},children:[v.jsx(D.Box,{sx:{display:"flex",alignItems:"center",flexWrap:"wrap"},children:s.map((u,f)=>{const m=u===e,x=u<e||a.includes(u),S=m||x?"primary.main":"#8F97A4";return v.jsxs(D.Box,{sx:{display:"flex",alignItems:"center"},children:[v.jsxs(D.Box,{onClick:()=>d(u)&&r(u),sx:{display:"flex",alignItems:"center",cursor:d(u)?"pointer":"default"},children:[v.jsx(D.Box,{sx:{width:24,height:24,borderRadius:"50%",border:m||x?"2px solid":"1px solid",borderColor:m||x?"primary.main":"#8F97A4",display:"flex",alignItems:"center",justifyContent:"center",backgroundColor:c=>m||x?Gn(c.palette.primary.main,.2):"transparent",mr:.5,color:S,fontWeight:m||x?600:500,fontSize:"12px"},children:u}),i&&v.jsx(D.Typography,{sx:{fontSize:"12px",fontWeight:600,color:S},children:l(u)})]}),f<s.length-1&&v.jsx(D.Box,{sx:{width:40,height:2,mx:1,borderRadius:1,backgroundColor:u<e?"primary.main":"#DFE3E8"}})]},u)})}),v.jsx(D.Typography,{sx:{color:"#8F97A4",fontSize:"12px",fontWeight:500},children:`Step ${e} of ${t}, ${o}% complete`})]}),v.jsx(D.LinearProgress,{variant:"determinate",value:o,sx:{height:4,borderRadius:"50px",backgroundColor:u=>u.palette.grey[300],"& .MuiLinearProgress-bar":{backgroundColor:"primary.main",borderRadius:5}}})]})},ql=({buttons:e,disabled:t=!1})=>{const r=o=>{o.onClick&&o.onClick()},n=e.filter(o=>o.position==="left"||!o.position),i=e.filter(o=>o.position==="center"),a=e.filter(o=>o.position==="right"),s=(o,l)=>{const d=(o.text||"").toLowerCase(),u=o.type==="submit"||d.includes("submit")||d.includes("save")||d.includes("next"),f=o.position==="left"||d.includes("cancel")||d.includes("back")||d.includes("draft"),m=o.type?o.type:u?"submit":"button",x=f?"outlined":"contained",S=o.disabled||t,c=E=>E&&["primary","secondary","error","info","success","warning"].includes(E)?E:"primary";return v.jsxs(D.Button,{type:m,variant:x,color:c(o.color),size:o.size||"large",disabled:S,onClick:o.onClick?()=>r(o):void 0,sx:o.sx,children:[o.loading&&v.jsx(D.CircularProgress,{size:20,sx:{mr:1}}),o.text]},`${o.text}-${l}`)};return v.jsxs(D.Box,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[v.jsx(D.Box,{sx:{display:"flex",gap:2},children:n.map((o,l)=>s(o,l))}),v.jsx(D.Box,{sx:{display:"flex",gap:2},children:i.map((o,l)=>s(o,l))}),v.jsx(D.Box,{sx:{display:"flex",gap:2},children:a.map((o,l)=>s(o,l))})]})},Tm=({config:e,onSubmit:t,onStepChange:r,currentStep:n=1,totalSteps:i=1,isMultiStep:a=!1,formData:s})=>{const{buttons:o,position:l="right",layout:d="horizontal",spacing:u=2,sx:f}=e,m=h=>{let _="button",$="contained";return h.type?_=h.type:h.text.toLowerCase().includes("submit")||h.text.toLowerCase().includes("save")||h.text.toLowerCase().includes("next")?_="submit":(h.text.toLowerCase().includes("reset")||h.text.toLowerCase().includes("clear"))&&(_="reset"),(h.text.toLowerCase().includes("cancel")||h.text.toLowerCase().includes("back")||h.text.toLowerCase().includes("draft"))&&($="outlined"),{buttonType:_,buttonVariant:$}},x=h=>["primary","secondary","error","warning","info","success"].includes(h||"")?h:"primary",S=h=>{const{buttonType:_}=m(h);h.onClick?h.onClick():_==="submit"&&t?t(s):a&&r&&(h.text.toLowerCase().includes("next")?r(n+1,i):(h.text.toLowerCase().includes("back")||h.text.toLowerCase().includes("previous"))&&r(n-1,i))},c=(h,_)=>{const{buttonType:$,buttonVariant:T}=m(h),w=x(h.color);return v.jsx(D.Button,{type:$,variant:T,color:w,size:h.size||"medium",disabled:h.disabled,onClick:()=>S(h),sx:h.sx,children:h.text},_)},E=()=>{const h={display:"flex",gap:u,...f};switch(l){case"left":return{...h,justifyContent:"flex-start"};case"center":return{...h,justifyContent:"center"};case"right":return{...h,justifyContent:"flex-end"};case"space-between":return{...h,justifyContent:"space-between"};default:return{...h,justifyContent:"flex-end"}}};return d==="vertical"?v.jsx(D.Box,{sx:E(),children:o.map((h,_)=>v.jsx(D.Box,{sx:{width:"100%"},children:c(h,_)},_))}):v.jsx(D.Box,{sx:E(),children:v.jsx(D.ButtonGroup,{variant:"outlined",size:"medium",children:o.map((h,_)=>c(h,_))})})},km=new Hc({defaultOptions:{queries:{staleTime:15*60*1e3,gcTime:30*60*1e3,retry:3,retryDelay:e=>Math.min(1e3*2**e,3e4),refetchOnWindowFocus:!1,refetchOnReconnect:!0}}}),Om=e=>v.jsx(Zc,{client:km,children:v.jsx(_m,{...e})}),_m=({id:e,theme:t,fields:r,onSubmit:n,onChange:i,submitButtonText:a="Submit",onSubmitClick:s,defaultValues:o,showSubmitButton:l=!0,buttons:d,buttonGroup:u,baseUrl:f,apiHeaders:m,stepNavigationProps:x})=>{var te,ue;const S=[...new Set(r.map(M=>M.step).filter(M=>M!=null&&M>0))].sort((M,U)=>(M||0)-(U||0)),c=S.length>1,E=S.length||1,[h,_]=I.useState(1),$=c?r.filter(M=>M.step===h):r,T=I.useMemo(()=>Bl($),[$]),{control:w,handleSubmit:F,formState:{errors:X},watch:J,resetField:W,trigger:p}=Tc({resolver:_c(T),mode:"onChange",defaultValues:o}),R=J(),V=I.useRef({});I.useEffect(()=>{const M=[];for(const U of r){const re=U.depends_on;re&&typeof U.name=="string"&&M.push({dependentField:U.name,dependencyName:re})}if(M.length!==0)for(const{dependentField:U,dependencyName:re}of M){const C=V.current[re],Q=R==null?void 0:R[re];if(C!==Q)try{W(U)}catch{}V.current[re]=Q}},[r,R,W]);const B=I.useRef(i);I.useEffect(()=>{B.current=i},[i]);const z=I.useMemo(()=>{try{return JSON.stringify(R)}catch{return String(Date.now())}},[R]),H=I.useRef(null);I.useEffect(()=>{B.current&&H.current!==z&&(H.current=z,B.current(R))},[z]);const le=async()=>{if(!c)return!0;const M=r.filter(re=>re.step===h);for(const re of M)if(re.required){const C=R[re.name];let Q=!0;if(re.type==="checkbox"?Q=C===!0:Array.isArray(C)?Q=C.length>0:Q=C!=null&&C!=="",!Q)return!1}return await p()?!0:Object.keys(X).filter(C=>M.some(Q=>Q.name===C)).map(C=>{const Q=X[C];return typeof(Q==null?void 0:Q.message)=="string"?Q.message:`${C} is invalid`}).length===0},ce=I.useMemo(()=>{if(!c)return!0;const M=r.filter(re=>re.step===h);for(const re of M)if(re.required){const C=R[re.name];let Q=!0;if(re.type==="checkbox"?Q=C===!0:Array.isArray(C)?Q=C.length>0:Q=C!=null&&C!=="",!Q)return!1}return Object.keys(X).filter(re=>M.some(C=>C.name===re)).length===0},[c,h,r,R,X]),pe=I.useMemo(()=>{if(c)return ce;for(const M of r)if(M.required){const U=R[M.name];let re=!0;if(M.type==="checkbox"?re=U===!0:re=U!=null&&U!==""&&!(Array.isArray(U)&&U.length===0),!re)return!1}return Object.keys(X).length===0},[c,ce,r,R,X]),oe=async M=>{M<1||M>E||M>h&&c&&!await le()||_(M)},N=async M=>{if(c&&h<E){console.warn("Form submission attempted on non-final step");return}s&&s(M),n(M)},L=async M=>{M&&(M.preventDefault(),M.stopPropagation()),c&&h<E&&await le()&&oe(h+1)},K=M=>{M&&(M.preventDefault(),M.stopPropagation()),c&&h>1&&oe(h-1)},se=M=>M.col?M.col:(M.xs||M.sm||M.md||M.lg||M.xl)&&(M.xs||M.sm||M.md||M.lg||M.xl)||12,ae=t?D.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:((te=t.typography)==null?void 0:te.fontFamily)||"Roboto, Arial, sans-serif",fontSize:typeof((ue=t.typography)==null?void 0:ue.fontSize)=="number"?t.typography.fontSize:14}}):void 0,ee=()=>{if(u&&u.buttons&&u.buttons.length>0){const M={...u,buttons:u.buttons.map(U=>{const re=(U.text||"").toLowerCase(),C=U.type==="submit"||re.includes("submit")||re.includes("save")||re.includes("finish")||re.includes("complete"),Q=re.includes("next");let me=!1;return c?(C||Q)&&(me=!ce):C&&(me=!pe),{...U,disabled:U.disabled||me}})};return v.jsx(D.Box,{sx:{mt:3},children:v.jsx(Tm,{config:M,onSubmit:N,onStepChange:oe,currentStep:h,totalSteps:E,isMultiStep:c,formData:R})})}if(d&&d.length>0){const M=d.map(U=>{const re=(U.text||"").toLowerCase(),C=U.type==="submit"||re.includes("submit")||re.includes("save")||re.includes("finish")||re.includes("complete"),Q=re.includes("next");let me=!1;return c?(C||Q)&&(me=!ce):C&&(me=!pe),{...U,disabled:U.disabled||me}});return v.jsx(ql,{buttons:M})}return l?v.jsx(D.Box,{sx:{mt:3,display:"flex",justifyContent:"flex-end",flexDirection:"column",alignItems:"flex-end"},children:v.jsxs(D.Box,{sx:{display:"flex",gap:2},children:[c&&h>1&&v.jsx(D.Button,{type:"button",variant:"outlined",onClick:K,children:"Previous"}),c?h<E?v.jsx(D.Button,{type:"button",variant:"contained",color:"primary",size:"large",disabled:!ce,onClick:L,children:"Next"}):v.jsx(D.Button,{type:"submit",variant:"contained",color:"primary",size:"large",disabled:!ce,children:a}):v.jsx(D.Button,{type:"submit",variant:"contained",color:"primary",size:"large",disabled:!pe,children:a})]})}):null},q=v.jsxs(D.Box,{component:"form",onSubmit:M=>{if(c&&h<E){M.preventDefault(),M.stopPropagation(),ce&&L();return}F(N)(M)},id:e,onKeyDown:M=>{M.key==="Enter"&&c&&h<E&&(M.preventDefault(),ce&&L())},children:[c&&v.jsx(Ll,{currentStep:h,totalSteps:E,onStepChange:oe,stepTitles:x==null?void 0:x.stepTitles,showStepTitles:(x==null?void 0:x.showStepTitles)!==!1}),v.jsx(D.Card,{sx:{p:2,boxShadow:"0px 1px 4px 0px #00000014",background:"#F8F8F8",borderRadius:"4px",display:"grid",gridTemplateColumns:"repeat(12, 1fr)",gap:2},children:$.map(M=>{const U=se(M);return v.jsx(D.Box,{sx:{gridColumn:`span ${U}`},children:v.jsx(Tl,{field:M,control:w,errors:X,baseUrl:f,apiHeaders:m,formData:R})},M.name)})}),ee()]});return ae?v.jsx(D.ThemeProvider,{theme:ae,children:q}):q},Am=({src:e,alt:t,width:r="100%",height:n="auto",style:i,className:a,onClick:s})=>v.jsx(D.Box,{sx:{textAlign:"center"},children:v.jsx("img",{src:e||"/placeholder-image.png",alt:t||"Image",width:r,height:n,style:{maxWidth:"100%",height:"auto",borderRadius:"8px",cursor:s?"pointer":"default",...i},className:a,onClick:s,onError:o=>{o.currentTarget.src="/placeholder-image.png"}})});function Sr(e,t,r,n){function i(a){return a instanceof r?a:new r(function(s){s(a)})}return new(r||(r=Promise))(function(a,s){function o(u){try{d(n.next(u))}catch(f){s(f)}}function l(u){try{d(n.throw(u))}catch(f){s(f)}}function d(u){u.done?a(u.value):i(u.value).then(o,l)}d((n=n.apply(e,t||[])).next())})}const Fm=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 Kr(e,t,r){const n=jm(e),{webkitRelativePath:i}=e,a=typeof t=="string"?t:typeof i=="string"&&i.length>0?i:`./${e.name}`;return typeof n.path!="string"&&ao(n,"path",a),ao(n,"relativePath",a),n}function jm(e){const{name:t}=e;if(t&&t.lastIndexOf(".")!==-1&&!e.type){const n=t.split(".").pop().toLowerCase(),i=Fm.get(n);i&&Object.defineProperty(e,"type",{value:i,writable:!1,configurable:!1,enumerable:!0})}return e}function ao(e,t,r){Object.defineProperty(e,t,{value:r,writable:!1,configurable:!1,enumerable:!0})}const Rm=[".DS_Store","Thumbs.db"];function $m(e){return Sr(this,void 0,void 0,function*(){return ni(e)&&Dm(e.dataTransfer)?zm(e.dataTransfer,e.type):Pm(e)?Im(e):Array.isArray(e)&&e.every(t=>"getFile"in t&&typeof t.getFile=="function")?Mm(e):[]})}function Dm(e){return ni(e)}function Pm(e){return ni(e)&&ni(e.target)}function ni(e){return typeof e=="object"&&e!==null}function Im(e){return oa(e.target.files).map(t=>Kr(t))}function Mm(e){return Sr(this,void 0,void 0,function*(){return(yield Promise.all(e.map(r=>r.getFile()))).map(r=>Kr(r))})}function zm(e,t){return Sr(this,void 0,void 0,function*(){if(e.items){const r=oa(e.items).filter(i=>i.kind==="file");if(t!=="drop")return r;const n=yield Promise.all(r.map(Vm));return so(Ul(n))}return so(oa(e.files).map(r=>Kr(r)))})}function so(e){return e.filter(t=>Rm.indexOf(t.name)===-1)}function oa(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 Vm(e){if(typeof e.webkitGetAsEntry!="function")return oo(e);const t=e.webkitGetAsEntry();return t&&t.isDirectory?Wl(t):oo(e,t)}function Ul(e){return e.reduce((t,r)=>[...t,...Array.isArray(r)?Ul(r):[r]],[])}function oo(e,t){return Sr(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 s=yield a.getFile();return s.handle=a,Kr(s)}}const n=e.getAsFile();if(!n)throw new Error(`${e} is not a File`);return Kr(n,(r=t==null?void 0:t.fullPath)!==null&&r!==void 0?r:void 0)})}function Nm(e){return Sr(this,void 0,void 0,function*(){return e.isDirectory?Wl(e):Bm(e)})}function Wl(e){const t=e.createReader();return new Promise((r,n)=>{const i=[];function a(){t.readEntries(s=>Sr(this,void 0,void 0,function*(){if(s.length){const o=Promise.all(s.map(Nm));i.push(o),a()}else try{const o=yield Promise.all(i);r(o)}catch(o){n(o)}}),s=>{n(s)})}a()})}function Bm(e){return Sr(this,void 0,void 0,function*(){return new Promise((t,r)=>{e.file(n=>{const i=Kr(n,e.fullPath);t(i)},n=>{r(n)})})})}var $n={},lo;function Lm(){return lo||(lo=1,$n.__esModule=!0,$n.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(s){var o=s.trim().toLowerCase();return o.charAt(0)==="."?n.toLowerCase().endsWith(o):o.endsWith("/*")?a===o.replace(/\/.*$/,""):i===o})}return!0}),$n}var qm=Lm();const $i=Sa(qm);function co(e){return Hm(e)||Wm(e)||Kl(e)||Um()}function Um(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
179
+ `+(o!==s?`result of cast: ${o}`:""))}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:s=t,strict:o=this.spec.strict}=r,l=t;o||(l=this._cast(l,Object.assign({assert:!1},r)));let f=[];for(let u of Object.values(this.internalTests))u&&f.push(u);this.runTests({path:a,value:l,originalValue:s,options:r,tests:f},n,u=>{if(u.length)return i(u,l);this.runTests({path:a,value:l,originalValue:s,options:r,tests:this.tests},n,i)})}runTests(t,r,n){let i=!1,{tests:a,value:s,originalValue:o,path:l,options:f}=t,u=c=>{i||(i=!0,r(c,s))},p=c=>{i||(i=!0,n(c,s))},m=a.length,x=[];if(!m)return p([]);let w={value:s,originalValue:o,path:l,options:f,schema:this};for(let c=0;c<a.length;c++){const E=a[c];E(w,u,function(C){C&&(Array.isArray(C)?x.push(...C):x.push(C)),--m<=0&&p(x)})}}asNestedTest({key:t,index:r,parent:n,parentPath:i,originalParent:a,options:s}){const o=t??r;if(o==null)throw TypeError("Must include `key` or `index` for nested validations");const l=typeof o=="number";let f=n[o];const u=Object.assign({},s,{strict:!0,parent:n,value:f,originalValue:a[o],key:void 0,[l?"index":"key"]:o,path:l||o.includes(".")?`${i||""}[${l?o:`"${o}"`}]`:(i?`${i}.`:"")+t});return(p,m,x)=>this.resolve(u)._validate(f,u,m,x)}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((s,o)=>i._validate(t,r,(l,f)=>{Je.isError(l)&&(l.value=f),o(l)},(l,f)=>{l.length?o(new Je(l,f,void 0,void 0,a)):s(f)}))}validateSync(t,r){var n;let i=this.resolve(Object.assign({},r,{value:t})),a,s=(n=r==null?void 0:r.disableStackTrace)!=null?n:i.spec.disableStackTrace;return i._validate(t,Object.assign({},r,{sync:!0}),(o,l)=>{throw Je.isError(o)&&(o.value=l),o},(o,l)=>{if(o.length)throw new Je(o,t,void 0,void 0,s);a=l}),a}isValid(t,r){return this.validate(t,r).then(()=>!0,n=>{if(Je.isError(n))return!1;throw n})}isValidSync(t,r){try{return this.validateSync(t,r),!0}catch(n){if(Je.isError(n))return!1;throw n}}_getDefault(t){let r=this.spec.default;return r==null?r:typeof r=="function"?r.call(this,t):Rr(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=jr({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=jr({message:r,name:"optionality",test(i){return i===void 0?this.schema.spec.optional:!0}}),n}optional(){return this.optionality(!0)}defined(t=bt.defined){return this.optionality(!1,t)}nullable(){return this.nullability(!0)}nonNullable(t=bt.notNull){return this.nullability(!1,t)}required(t=bt.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=bt.default),typeof r.test!="function")throw new TypeError("`test` is a required parameters");let n=this.clone(),i=jr(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(s=>!(s.OPTIONS.name===r.name&&(a||s.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=Cl(t).map(a=>new wr(a));return i.forEach(a=>{a.isSibling&&n.deps.push(a.key)}),n.conditions.push(typeof r=="function"?new ti(i,r):ti.fromOptions(i,r)),n}typeError(t){let r=this.clone();return r.internalTests.typeError=jr({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=bt.oneOf){let n=this.clone();return t.forEach(i=>{n._whitelist.add(i),n._blacklist.delete(i)}),n.internalTests.whiteList=jr({message:r,name:"oneOf",skipAbsent:!0,test(i){let a=this.schema._whitelist,s=a.resolveAll(this.resolve);return s.includes(i)?!0:this.createError({params:{values:Array.from(a).join(", "),resolved:s}})}}),n}notOneOf(t,r=bt.notOneOf){let n=this.clone();return t.forEach(i=>{n._blacklist.add(i),n._whitelist.delete(i)}),n.internalTests.blacklist=jr({message:r,name:"notOneOf",test(i){let a=this.schema._blacklist,s=a.resolveAll(this.resolve);return s.includes(i)?this.createError({params:{values:Array.from(a).join(", "),resolved:s}}):!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:s}=r.spec;return{meta:i,label:n,optional:a,nullable:s,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,f,u)=>u.findIndex(p=>p.name===l.name)===f)}}}nt.prototype.__isYupSchema__=!0;for(const e of["validate","validateSync"])nt.prototype[`${e}At`]=function(t,r,n={}){const{parent:i,parentPath:a,schema:s}=sm(this,t,r,n.context);return s[e](i&&i[a],Object.assign({},n,{parent:i,path:t}))};for(const e of["equals","is"])nt.prototype[e]=nt.prototype.oneOf;for(const e of["not","nope"])nt.prototype[e]=nt.prototype.notOneOf;const om=()=>!0;function Fl(e){return new jl(e)}class jl extends nt{constructor(t){super(typeof t=="function"?{type:"mixed",check:t}:Object.assign({type:"mixed",check:om},t))}}Fl.prototype=jl.prototype;function Rl(){return new $l}class $l extends nt{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=aa.isValue){return this.test({message:t,name:"is-value",exclusive:!0,params:{value:"true"},test(r){return ht(r)||r===!0}})}isFalse(t=aa.isValue){return this.test({message:t,name:"is-value",exclusive:!0,params:{value:"false"},test(r){return ht(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)}}Rl.prototype=$l.prototype;const lm=/^(\d{4}|[+-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,.](\d{1,}))?)?(?:(Z)|([+-])(\d{2})(?::?(\d{2}))?)?)?$/;function cm(e){const t=sa(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 sa(e){var t,r;const n=lm.exec(e);return n?{year:Ft(n[1]),month:Ft(n[2],1)-1,day:Ft(n[3],1),hour:Ft(n[4]),minute:Ft(n[5]),second:Ft(n[6]),millisecond:n[7]?Ft(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:Ft(n[10]),minuteOffset:Ft(n[11])}:null}function Ft(e,t=0){return Number(e)||t}let um=/^[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])?)*$/,pm=/^((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,dm=/^(?:[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,fm="^\\d{4}-\\d{2}-\\d{2}",mm="\\d{2}:\\d{2}:\\d{2}",hm="(([+-]\\d{2}(:?\\d{2})?)|Z)",ym=new RegExp(`${fm}T${mm}(\\.\\d+)?${hm}$`),gm=e=>ht(e)||e===e.trim(),vm={}.toString();function sn(){return new Dl}class Dl extends nt{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===vm?t:i})})}required(t){return super.required(t).withMutation(r=>r.test({message:t||bt.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=Ye.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=Ye.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=Ye.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||Ye.matches,params:{regex:t},skipAbsent:!0,test:s=>s===""&&n||s.search(t)!==-1})}email(t=Ye.email){return this.matches(um,{name:"email",message:t,excludeEmptyString:!0})}url(t=Ye.url){return this.matches(pm,{name:"url",message:t,excludeEmptyString:!0})}uuid(t=Ye.uuid){return this.matches(dm,{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(ym,{name:"datetime",message:r||Ye.datetime,excludeEmptyString:!0}).test({name:"datetime_offset",message:r||Ye.datetime_offset,params:{allowOffset:n},skipAbsent:!0,test:a=>{if(!a||n)return!0;const s=sa(a);return s?!!s.z:!1}}).test({name:"datetime_precision",message:r||Ye.datetime_precision,params:{precision:i},skipAbsent:!0,test:a=>{if(!a||i==null)return!0;const s=sa(a);return s?s.precision===i:!1}})}ensure(){return this.default("").transform(t=>t===null?"":t)}trim(t=Ye.trim){return this.transform(r=>r!=null?r.trim():r).test({message:t,name:"trim",test:gm})}lowercase(t=Ye.lowercase){return this.transform(r=>ht(r)?r:r.toLowerCase()).test({message:t,name:"string_case",exclusive:!0,skipAbsent:!0,test:r=>ht(r)||r===r.toLowerCase()})}uppercase(t=Ye.uppercase){return this.transform(r=>ht(r)?r:r.toUpperCase()).test({message:t,name:"string_case",exclusive:!0,skipAbsent:!0,test:r=>ht(r)||r===r.toUpperCase()})}}sn.prototype=Dl.prototype;let xm=e=>e!=+e;function Pl(){return new Il}class Il extends nt{constructor(){super({type:"number",check(t){return t instanceof Number&&(t=t.valueOf()),typeof t=="number"&&!xm(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=Mt.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=Mt.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=Mt.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=Mt.moreThan){return this.test({message:r,name:"min",exclusive:!0,params:{more:t},skipAbsent:!0,test(n){return n>this.resolve(t)}})}positive(t=Mt.positive){return this.moreThan(0,t)}negative(t=Mt.negative){return this.lessThan(0,t)}integer(t=Mt.integer){return this.test({name:"integer",message:t,skipAbsent:!0,test:r=>Number.isInteger(r)})}truncate(){return this.transform(t=>ht(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=>ht(i)?i:Math[t](i))}}Pl.prototype=Il.prototype;let Ml=new Date(""),bm=e=>Object.prototype.toString.call(e)==="[object Date]";function Ma(){return new En}class En extends nt{constructor(){super({type:"date",check(t){return bm(t)&&!isNaN(t.getTime())}}),this.withMutation(()=>{this.transform((t,r,n)=>!n.spec.coerce||n.isType(t)||t===null?t:(t=cm(t),isNaN(t)?En.INVALID_DATE:new Date(t)))})}prepareParam(t,r){let n;if(wr.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=ia.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=ia.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)}})}}En.INVALID_DATE=Ml;Ma.prototype=En.prototype;Ma.INVALID_DATE=Ml;function wm(e,t=[]){let r=[],n=new Set,i=new Set(t.map(([s,o])=>`${s}-${o}`));function a(s,o){let l=hr.split(s)[0];n.add(l),i.has(`${o}-${l}`)||r.push([o,l])}for(const s of Object.keys(e)){let o=e[s];n.add(s),wr.isRef(o)&&o.isSibling?a(o.path,s):Ia(o)&&"deps"in o&&o.deps.forEach(l=>a(l,s))}return Gf.array(Array.from(n),r).reverse()}function ro(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 zl(e){return(t,r)=>ro(e,t)-ro(e,r)}const Sm=(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 Nn(e){if("fields"in e){const t={};for(const[r,n]of Object.entries(e.fields))t[r]=Nn(n);return e.setFields(t)}if(e.type==="array"){const t=e.optional();return t.innerType&&(t.innerType=Nn(t.innerType)),t}return e.type==="tuple"?e.optional().clone({types:e.spec.types.map(Nn)}):"optional"in e?e.optional():e}const Em=(e,t)=>{const r=[...hr.normalizePath(t)];if(r.length===1)return r[0]in e;let n=r.pop(),i=hr.getter(hr.join(r),!0)(e);return!!(i&&n in i)};let no=e=>Object.prototype.toString.call(e)==="[object Object]";function io(e,t){let r=Object.keys(e.fields);return Object.keys(t).filter(n=>r.indexOf(n)===-1)}const Tm=zl([]);function Vl(e){return new Nl(e)}class Nl extends nt{constructor(t){super({type:"object",check(r){return no(r)||typeof r=="function"}}),this.fields=Object.create(null),this._sortErrors=Tm,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,s=(n=r.stripUnknown)!=null?n:this.spec.noUnknown,o=[].concat(this._nodes,Object.keys(i).filter(p=>!this._nodes.includes(p))),l={},f=Object.assign({},r,{parent:l,__validating:r.__validating||!1}),u=!1;for(const p of o){let m=a[p],x=p in i;if(m){let w,c=i[p];f.path=(r.path?`${r.path}.`:"")+p,m=m.resolve({value:c,context:r.context,parent:l});let E=m instanceof nt?m.spec:void 0,y=E==null?void 0:E.strict;if(E!=null&&E.strip){u=u||p in i;continue}w=!r.__validating||!y?m.cast(i[p],f):i[p],w!==void 0&&(l[p]=w)}else x&&!s&&(l[p]=i[p]);(x!==p in l||l[p]!==i[p])&&(u=!0)}return u?l:i}_validate(t,r={},n,i){let{from:a=[],originalValue:s=t,recursive:o=this.spec.recursive}=r;r.from=[{schema:this,value:s},...a],r.__validating=!0,r.originalValue=s,super._validate(t,r,n,(l,f)=>{if(!o||!no(f)){i(l,f);return}s=s||f;let u=[];for(let p of this._nodes){let m=this.fields[p];!m||wr.isRef(m)||u.push(m.asNestedTest({options:r,key:p,parent:f,parentPath:r.path,originalParent:s}))}this.runTests({tests:u,value:f,originalValue:s,options:r},n,p=>{i(p.sort(this._sortErrors).concat(l),f)})})}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 s=n[i];n[i]=s===void 0?a:s}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 s=t;(i=s)!=null&&i.value&&(s=Object.assign({},s,{parent:s.value,value:s.value[n]})),r[n]=a&&"getDefault"in a?a.getDefault(s):void 0}),r}setFields(t,r){let n=this.clone();return n.fields=t,n._nodes=wm(t,r),n._sortErrors=zl(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 Nn(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=hr.getter(t,!0);return this.transform(a=>{if(!a)return a;let s=a;return Em(a,t)&&(s=Object.assign({},a),n||delete s[t],s[r]=i(a)),s})}json(){return this.transform(Sm)}exact(t){return this.test({name:"exact",exclusive:!0,message:t||Vn.exact,test(r){if(r==null)return!0;const n=io(this.schema,r);return n.length===0||this.createError({params:{properties:n.join(", ")}})}})}stripUnknown(){return this.clone({noUnknown:!0})}noUnknown(t=!0,r=Vn.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=io(this.schema,i);return!t||a.length===0||this.createError({params:{unknown:a.join(", ")}})}});return n.spec.noUnknown=t,n}unknown(t=!0,r=Vn.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(Ri.camelCase)}snakeCase(){return this.transformKeys(Ri.snakeCase)}constantCase(){return this.transformKeys(t=>Ri.snakeCase(t).toUpperCase())}describe(t){const r=(t?this.resolve(t):this).clone(),n=super.describe(t);n.fields={};for(const[a,s]of Object.entries(r.fields)){var i;let o=t;(i=o)!=null&&i.value&&(o=Object.assign({},o,{parent:o.value,value:o.value[a]})),n.fields[a]=s.describe(o)}return n}}Vl.prototype=Nl.prototype;const Bl=e=>{const t={};return e.forEach(r=>{var a,s,o;let n;switch(r.type){case"text":case"textarea":case"tel":n=sn(),r.validation?n=tr(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=sn().email(((a=r.validation)==null?void 0:a.message)||`${r.label} must be a valid email address`),r.validation&&(n=tr(n,r,"string"));break;case"password":n=sn(),r.validation?n=tr(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=Pl().typeError(`${r.label} must be a number`),r.validation?n=tr(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=sn(),r.validation&&(n=tr(n,r,"string"));break;case"checkbox":n=Rl(),r.validation&&(n=tr(n,r,"boolean"));break;case"date":n=Ma().typeError(`${r.label} must be a valid date`),r.validation?n=tr(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=Fl()}if(((s=r.validation)==null?void 0:s.required)!==void 0?r.validation.required:r.required){const l=((o=r.validation)==null?void 0:o.message)||`${r.label} is required`;n=n.required(l)}t[r.name]=n}),Vl().shape(t)},tr=(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,s=>s?i.test(s):!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},Ll=({currentStep:e,totalSteps:t,onStepChange:r,stepTitles:n=[],showStepTitles:i=!0,completedSteps:a=[]})=>{const s=D.useMemo(()=>Array.from({length:t},(u,p)=>p+1),[t]),o=D.useMemo(()=>Math.round(e/t*100),[e,t]),l=u=>n[u-1]||`Step ${u}`,f=u=>u===e||a.includes(u)||u===e+1&&a.includes(e);return v.jsxs(R.Card,{sx:{mb:2,p:2,boxShadow:"0px 1px 4px 0px #00000014",background:"#F8F8F8",borderRadius:"4px"},children:[v.jsxs(R.Box,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between",mb:2},children:[v.jsx(R.Box,{sx:{display:"flex",alignItems:"center",flexWrap:"wrap"},children:s.map((u,p)=>{const m=u===e,x=u<e||a.includes(u),w=m||x?"primary.main":"#8F97A4";return v.jsxs(R.Box,{sx:{display:"flex",alignItems:"center"},children:[v.jsxs(R.Box,{onClick:()=>f(u)&&r(u),sx:{display:"flex",alignItems:"center",cursor:f(u)?"pointer":"default"},children:[v.jsx(R.Box,{sx:{width:24,height:24,borderRadius:"50%",border:m||x?"2px solid":"1px solid",borderColor:m||x?"primary.main":"#8F97A4",display:"flex",alignItems:"center",justifyContent:"center",backgroundColor:c=>m||x?Gn(c.palette.primary.main,.2):"transparent",mr:.5,color:w,fontWeight:m||x?600:500,fontSize:"12px"},children:u}),i&&v.jsx(R.Typography,{sx:{fontSize:"12px",fontWeight:600,color:w},children:l(u)})]}),p<s.length-1&&v.jsx(R.Box,{sx:{width:40,height:2,mx:1,borderRadius:1,backgroundColor:u<e?"primary.main":"#DFE3E8"}})]},u)})}),v.jsx(R.Typography,{sx:{color:"#8F97A4",fontSize:"12px",fontWeight:500},children:`Step ${e} of ${t}, ${o}% complete`})]}),v.jsx(R.LinearProgress,{variant:"determinate",value:o,sx:{height:4,borderRadius:"50px",backgroundColor:u=>u.palette.grey[300],"& .MuiLinearProgress-bar":{backgroundColor:"primary.main",borderRadius:5}}})]})},ql=({buttons:e,disabled:t=!1})=>{const r=o=>{o.onClick&&o.onClick()},n=e.filter(o=>o.position==="left"||!o.position),i=e.filter(o=>o.position==="center"),a=e.filter(o=>o.position==="right"),s=(o,l)=>{const f=(o.text||"").toLowerCase(),u=o.type==="submit"||f.includes("submit")||f.includes("save")||f.includes("next"),p=o.position==="left"||f.includes("cancel")||f.includes("back")||f.includes("draft"),m=o.type?o.type:u?"submit":"button",x=p?"outlined":"contained",w=o.disabled||t,c=E=>E&&["primary","secondary","error","info","success","warning"].includes(E)?E:"primary";return v.jsxs(R.Button,{type:m,variant:x,color:c(o.color),size:o.size||"large",disabled:w,onClick:o.onClick?()=>r(o):void 0,sx:o.sx,children:[o.loading&&v.jsx(R.CircularProgress,{size:20,sx:{mr:1}}),o.text]},`${o.text}-${l}`)};return v.jsxs(R.Box,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[v.jsx(R.Box,{sx:{display:"flex",gap:2},children:n.map((o,l)=>s(o,l))}),v.jsx(R.Box,{sx:{display:"flex",gap:2},children:i.map((o,l)=>s(o,l))}),v.jsx(R.Box,{sx:{display:"flex",gap:2},children:a.map((o,l)=>s(o,l))})]})},km=({config:e,onSubmit:t,onStepChange:r,currentStep:n=1,totalSteps:i=1,isMultiStep:a=!1,formData:s})=>{const{buttons:o,position:l="right",layout:f="horizontal",spacing:u=2,sx:p}=e,m=y=>{let C="button",A="contained";return y.type?C=y.type:y.text.toLowerCase().includes("submit")||y.text.toLowerCase().includes("save")||y.text.toLowerCase().includes("next")?C="submit":(y.text.toLowerCase().includes("reset")||y.text.toLowerCase().includes("clear"))&&(C="reset"),(y.text.toLowerCase().includes("cancel")||y.text.toLowerCase().includes("back")||y.text.toLowerCase().includes("draft"))&&(A="outlined"),{buttonType:C,buttonVariant:A}},x=y=>["primary","secondary","error","warning","info","success"].includes(y||"")?y:"primary",w=y=>{const{buttonType:C}=m(y);y.onClick?y.onClick():C==="submit"&&t?t(s):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,C)=>{const{buttonType:A,buttonVariant:_}=m(y),b=x(y.color);return v.jsx(R.Button,{type:A,variant:_,color:b,size:y.size||"medium",disabled:y.disabled,onClick:()=>w(y),sx:y.sx,children:y.text},C)},E=()=>{const y={display:"flex",gap:u,...p};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 f==="vertical"?v.jsx(R.Box,{sx:E(),children:o.map((y,C)=>v.jsx(R.Box,{sx:{width:"100%"},children:c(y,C)},C))}):v.jsx(R.Box,{sx:E(),children:v.jsx(R.ButtonGroup,{variant:"outlined",size:"medium",children:o.map((y,C)=>c(y,C))})})},Cm=new Hc({defaultOptions:{queries:{staleTime:15*60*1e3,gcTime:30*60*1e3,retry:3,retryDelay:e=>Math.min(1e3*2**e,3e4),refetchOnWindowFocus:!1,refetchOnReconnect:!0}}}),Om=e=>v.jsx(Zc,{client:Cm,children:v.jsx(_m,{...e})}),_m=({id:e,theme:t,fields:r,onSubmit:n,onChange:i,submitButtonText:a="Submit",onSubmitClick:s,defaultValues:o,showSubmitButton:l=!0,buttons:f,buttonGroup:u,baseUrl:p,apiHeaders:m,stepNavigationProps:x})=>{var ae,pe;const w=[...new Set(r.map(M=>M.step).filter(M=>M!=null&&M>0))].sort((M,se)=>(M||0)-(se||0)),c=w.length>1,E=w.length||1,[y,C]=D.useState(1),A=c?r.filter(M=>M.step===y):r,_=D.useMemo(()=>Bl(A),[A]),{control:b,handleSubmit:L,formState:{errors:j},watch:ee,setValue:K,resetField:d,trigger:z}=kc({resolver:_c(_),mode:"onChange",defaultValues:o}),P=ee(),q=D.useRef({});D.useEffect(()=>{const M=[];for(const se of r){const I=se.depends_on;I&&typeof se.name=="string"&&M.push({dependentField:se.name,dependencyName:I})}if(M.length!==0)for(const{dependentField:se,dependencyName:I}of M){const B=q.current[I],G=P==null?void 0:P[I];if(B!==G)try{d(se)}catch{}q.current[I]=G}},[r,P,d]);const N=D.useRef(i);D.useEffect(()=>{N.current=i},[i]);const Y=D.useMemo(()=>{try{return JSON.stringify(P)}catch{return String(Date.now())}},[P]),re=D.useRef(null);D.useEffect(()=>{N.current&&re.current!==Y&&(re.current=Y,N.current(P))},[Y]);const me=async()=>{if(!c)return!0;const M=r.filter(I=>I.step===y);for(const I of M)if(I.required){const B=P[I.name];let G=!0;if(I.type==="checkbox"?G=B===!0:Array.isArray(B)?G=B.length>0:G=B!=null&&B!=="",!G)return!1}return await z()?!0:Object.keys(j).filter(B=>M.some(G=>G.name===B)).map(B=>{const G=j[B];return typeof(G==null?void 0:G.message)=="string"?G.message:`${B} is invalid`}).length===0},ce=D.useMemo(()=>{if(!c)return!0;const M=r.filter(I=>I.step===y);for(const I of M)if(I.required){const B=P[I.name];let G=!0;if(I.type==="checkbox"?G=B===!0:Array.isArray(B)?G=B.length>0:G=B!=null&&B!=="",!G)return!1}return Object.keys(j).filter(I=>M.some(B=>B.name===I)).length===0},[c,y,r,P,j]),oe=D.useMemo(()=>{if(c)return ce;for(const M of r)if(M.required){const se=P[M.name];let I=!0;if(M.type==="checkbox"?I=se===!0:I=se!=null&&se!==""&&!(Array.isArray(se)&&se.length===0),!I)return!1}return Object.keys(j).length===0},[c,ce,r,P,j]),V=async M=>{M<1||M>E||M>y&&c&&!await me()||C(M)},U=async M=>{if(c&&y<E){console.warn("Form submission attempted on non-final step");return}s&&s(M),n(M)},ue=async M=>{M&&(M.preventDefault(),M.stopPropagation()),c&&y<E&&await me()&&V(y+1)},Q=M=>{M&&(M.preventDefault(),M.stopPropagation()),c&&y>1&&V(y-1)},te=M=>M.col?M.col:(M.xs||M.sm||M.md||M.lg||M.xl)&&(M.xs||M.sm||M.md||M.lg||M.xl)||12,le=t?R.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:((ae=t.typography)==null?void 0:ae.fontFamily)||"Roboto, Arial, sans-serif",fontSize:typeof((pe=t.typography)==null?void 0:pe.fontSize)=="number"?t.typography.fontSize:14}}):void 0,W=()=>{if(u&&u.buttons&&u.buttons.length>0){const M={...u,buttons:u.buttons.map(se=>{const I=(se.text||"").toLowerCase(),B=se.type==="submit"||I.includes("submit")||I.includes("save")||I.includes("finish")||I.includes("complete"),G=I.includes("next");let ye=!1;return c?(B||G)&&(ye=!ce):B&&(ye=!oe),{...se,disabled:se.disabled||ye}})};return v.jsx(R.Box,{sx:{mt:3},children:v.jsx(km,{config:M,onSubmit:U,onStepChange:V,currentStep:y,totalSteps:E,isMultiStep:c,formData:P})})}if(f&&f.length>0){const M=f.map(se=>{const I=(se.text||"").toLowerCase(),B=se.type==="submit"||I.includes("submit")||I.includes("save")||I.includes("finish")||I.includes("complete"),G=I.includes("next");let ye=!1;return c?(B||G)&&(ye=!ce):B&&(ye=!oe),{...se,disabled:se.disabled||ye}});return v.jsx(ql,{buttons:M})}return l?v.jsx(R.Box,{sx:{mt:3,display:"flex",justifyContent:"flex-end",flexDirection:"column",alignItems:"flex-end"},children:v.jsxs(R.Box,{sx:{display:"flex",gap:2},children:[c&&y>1&&v.jsx(R.Button,{type:"button",variant:"outlined",onClick:Q,children:"Previous"}),c?y<E?v.jsx(R.Button,{type:"button",variant:"contained",color:"primary",size:"large",disabled:!ce,onClick:ue,children:"Next"}):v.jsx(R.Button,{type:"submit",variant:"contained",color:"primary",size:"large",disabled:!ce,children:a}):v.jsx(R.Button,{type:"submit",variant:"contained",color:"primary",size:"large",disabled:!oe,children:a})]})}):null},H=v.jsxs(R.Box,{component:"form",onSubmit:M=>{if(c&&y<E){M.preventDefault(),M.stopPropagation(),ce&&ue();return}L(U)(M)},id:e,onKeyDown:M=>{M.key==="Enter"&&c&&y<E&&(M.preventDefault(),ce&&ue())},children:[c&&v.jsx(Ll,{currentStep:y,totalSteps:E,onStepChange:V,stepTitles:x==null?void 0:x.stepTitles,showStepTitles:(x==null?void 0:x.showStepTitles)!==!1}),v.jsx(R.Card,{sx:{p:2,boxShadow:"0px 1px 4px 0px #00000014",background:"#F8F8F8",borderRadius:"4px",display:"grid",gridTemplateColumns:"repeat(12, 1fr)",gap:2},children:A.map(M=>{const se=te(M);return v.jsx(R.Box,{sx:{gridColumn:`span ${se}`},children:v.jsx(kl,{field:M,control:b,errors:j,baseUrl:p,apiHeaders:m,formData:P,setValue:K})},M.name)})}),W()]});return le?v.jsx(R.ThemeProvider,{theme:le,children:H}):H},Am=({src:e,alt:t,width:r="100%",height:n="auto",style:i,className:a,onClick:s})=>v.jsx(R.Box,{sx:{textAlign:"center"},children:v.jsx("img",{src:e||"/placeholder-image.png",alt:t||"Image",width:r,height:n,style:{maxWidth:"100%",height:"auto",borderRadius:"8px",cursor:s?"pointer":"default",...i},className:a,onClick:s,onError:o=>{o.currentTarget.src="/placeholder-image.png"}})});function Sr(e,t,r,n){function i(a){return a instanceof r?a:new r(function(s){s(a)})}return new(r||(r=Promise))(function(a,s){function o(u){try{f(n.next(u))}catch(p){s(p)}}function l(u){try{f(n.throw(u))}catch(p){s(p)}}function f(u){u.done?a(u.value):i(u.value).then(o,l)}f((n=n.apply(e,t||[])).next())})}const Fm=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 Kr(e,t,r){const n=jm(e),{webkitRelativePath:i}=e,a=typeof t=="string"?t:typeof i=="string"&&i.length>0?i:`./${e.name}`;return typeof n.path!="string"&&ao(n,"path",a),ao(n,"relativePath",a),n}function jm(e){const{name:t}=e;if(t&&t.lastIndexOf(".")!==-1&&!e.type){const n=t.split(".").pop().toLowerCase(),i=Fm.get(n);i&&Object.defineProperty(e,"type",{value:i,writable:!1,configurable:!1,enumerable:!0})}return e}function ao(e,t,r){Object.defineProperty(e,t,{value:r,writable:!1,configurable:!1,enumerable:!0})}const Rm=[".DS_Store","Thumbs.db"];function $m(e){return Sr(this,void 0,void 0,function*(){return ni(e)&&Dm(e.dataTransfer)?zm(e.dataTransfer,e.type):Pm(e)?Im(e):Array.isArray(e)&&e.every(t=>"getFile"in t&&typeof t.getFile=="function")?Mm(e):[]})}function Dm(e){return ni(e)}function Pm(e){return ni(e)&&ni(e.target)}function ni(e){return typeof e=="object"&&e!==null}function Im(e){return oa(e.target.files).map(t=>Kr(t))}function Mm(e){return Sr(this,void 0,void 0,function*(){return(yield Promise.all(e.map(r=>r.getFile()))).map(r=>Kr(r))})}function zm(e,t){return Sr(this,void 0,void 0,function*(){if(e.items){const r=oa(e.items).filter(i=>i.kind==="file");if(t!=="drop")return r;const n=yield Promise.all(r.map(Vm));return so(Ul(n))}return so(oa(e.files).map(r=>Kr(r)))})}function so(e){return e.filter(t=>Rm.indexOf(t.name)===-1)}function oa(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 Vm(e){if(typeof e.webkitGetAsEntry!="function")return oo(e);const t=e.webkitGetAsEntry();return t&&t.isDirectory?Wl(t):oo(e,t)}function Ul(e){return e.reduce((t,r)=>[...t,...Array.isArray(r)?Ul(r):[r]],[])}function oo(e,t){return Sr(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 s=yield a.getFile();return s.handle=a,Kr(s)}}const n=e.getAsFile();if(!n)throw new Error(`${e} is not a File`);return Kr(n,(r=t==null?void 0:t.fullPath)!==null&&r!==void 0?r:void 0)})}function Nm(e){return Sr(this,void 0,void 0,function*(){return e.isDirectory?Wl(e):Bm(e)})}function Wl(e){const t=e.createReader();return new Promise((r,n)=>{const i=[];function a(){t.readEntries(s=>Sr(this,void 0,void 0,function*(){if(s.length){const o=Promise.all(s.map(Nm));i.push(o),a()}else try{const o=yield Promise.all(i);r(o)}catch(o){n(o)}}),s=>{n(s)})}a()})}function Bm(e){return Sr(this,void 0,void 0,function*(){return new Promise((t,r)=>{e.file(n=>{const i=Kr(n,e.fullPath);t(i)},n=>{r(n)})})})}var $n={},lo;function Lm(){return lo||(lo=1,$n.__esModule=!0,$n.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(s){var o=s.trim().toLowerCase();return o.charAt(0)==="."?n.toLowerCase().endsWith(o):o.endsWith("/*")?a===o.replace(/\/.*$/,""):i===o})}return!0}),$n}var qm=Lm();const $i=Sa(qm);function co(e){return Hm(e)||Wm(e)||Kl(e)||Um()}function Um(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
180
180
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Wm(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Hm(e){if(Array.isArray(e))return la(e)}function uo(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 po(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?uo(Object(r),!0).forEach(function(n){Hl(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):uo(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Hl(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function fn(e,t){return Ym(e)||Qm(e,t)||Kl(e,t)||Km()}function Km(){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 Kl(e,t){if(e){if(typeof e=="string")return la(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 la(e,t)}}function la(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 Qm(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n=[],i=!0,a=!1,s,o;try{for(r=r.call(e);!(i=(s=r.next()).done)&&(n.push(s.value),!(t&&n.length===t));i=!0);}catch(l){a=!0,o=l}finally{try{!i&&r.return!=null&&r.return()}finally{if(a)throw o}}return n}}function Ym(e){if(Array.isArray(e))return e}var Gm=typeof $i=="function"?$i:$i.default,Zm="file-invalid-type",Xm="file-too-large",Jm="file-too-small",eh="too-many-files",th=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:Zm,message:"File type must be ".concat(n)}},fo=function(t){return{code:Xm,message:"File is larger than ".concat(t," ").concat(t===1?"byte":"bytes")}},mo=function(t){return{code:Jm,message:"File is smaller than ".concat(t," ").concat(t===1?"byte":"bytes")}},rh={code:eh,message:"Too many files"};function Ql(e,t){var r=e.type==="application/x-moz-file"||Gm(e,t);return[r,r?null:th(t)]}function Yl(e,t,r){if(nr(e.size))if(nr(t)&&nr(r)){if(e.size>r)return[!1,fo(r)];if(e.size<t)return[!1,mo(t)]}else{if(nr(t)&&e.size<t)return[!1,mo(t)];if(nr(r)&&e.size>r)return[!1,fo(r)]}return[!0,null]}function nr(e){return e!=null}function nh(e){var t=e.files,r=e.accept,n=e.minSize,i=e.maxSize,a=e.multiple,s=e.maxFiles,o=e.validator;return!a&&t.length>1||a&&s>=1&&t.length>s?!1:t.every(function(l){var d=Ql(l,r),u=fn(d,1),f=u[0],m=Yl(l,n,i),x=fn(m,1),S=x[0],c=o?o(l):null;return f&&S&&!c})}function ii(e){return typeof e.isPropagationStopped=="function"?e.isPropagationStopped():typeof e.cancelBubble<"u"?e.cancelBubble:!1}function Dn(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 ho(e){e.preventDefault()}function ih(e){return e.indexOf("MSIE")!==-1||e.indexOf("Trident/")!==-1}function ah(e){return e.indexOf("Edge/")!==-1}function sh(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:window.navigator.userAgent;return ih(e)||ah(e)}function xt(){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),s=1;s<i;s++)a[s-1]=arguments[s];return t.some(function(o){return!ii(n)&&o&&o.apply(void 0,[n].concat(a)),ii(n)})}}function oh(){return"showOpenFilePicker"in window}function lh(e){if(nr(e)){var t=Object.entries(e).filter(function(r){var n=fn(r,2),i=n[0],a=n[1],s=!0;return Gl(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.')),s=!1),(!Array.isArray(a)||!a.every(Zl))&&(console.warn('Skipped "'.concat(i,'" because an invalid file extension was provided.')),s=!1),s}).reduce(function(r,n){var i=fn(n,2),a=i[0],s=i[1];return po(po({},r),{},Hl({},a,s))},{});return[{description:"Files",accept:t}]}return e}function ch(e){if(nr(e))return Object.entries(e).reduce(function(t,r){var n=fn(r,2),i=n[0],a=n[1];return[].concat(co(t),[i],co(a))},[]).filter(function(t){return Gl(t)||Zl(t)}).join(",")}function uh(e){return e instanceof DOMException&&(e.name==="AbortError"||e.code===e.ABORT_ERR)}function ph(e){return e instanceof DOMException&&(e.name==="SecurityError"||e.code===e.SECURITY_ERR)}function Gl(e){return e==="audio/*"||e==="video/*"||e==="image/*"||e==="text/*"||e==="application/*"||/\w+\/[-+.\w]+/g.test(e)}function Zl(e){return/^.*\.[\w]+$/.test(e)}var dh=["children"],fh=["open"],mh=["refKey","role","onKeyDown","onFocus","onBlur","onClick","onDragEnter","onDragOver","onDragLeave","onDrop"],hh=["refKey","onChange","onClick"];function yh(e){return xh(e)||vh(e)||Xl(e)||gh()}function gh(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
181
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Kl(e,t){if(e){if(typeof e=="string")return la(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 la(e,t)}}function la(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 Qm(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n=[],i=!0,a=!1,s,o;try{for(r=r.call(e);!(i=(s=r.next()).done)&&(n.push(s.value),!(t&&n.length===t));i=!0);}catch(l){a=!0,o=l}finally{try{!i&&r.return!=null&&r.return()}finally{if(a)throw o}}return n}}function Ym(e){if(Array.isArray(e))return e}var Gm=typeof $i=="function"?$i:$i.default,Zm="file-invalid-type",Xm="file-too-large",Jm="file-too-small",eh="too-many-files",th=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:Zm,message:"File type must be ".concat(n)}},fo=function(t){return{code:Xm,message:"File is larger than ".concat(t," ").concat(t===1?"byte":"bytes")}},mo=function(t){return{code:Jm,message:"File is smaller than ".concat(t," ").concat(t===1?"byte":"bytes")}},rh={code:eh,message:"Too many files"};function Ql(e,t){var r=e.type==="application/x-moz-file"||Gm(e,t);return[r,r?null:th(t)]}function Yl(e,t,r){if(nr(e.size))if(nr(t)&&nr(r)){if(e.size>r)return[!1,fo(r)];if(e.size<t)return[!1,mo(t)]}else{if(nr(t)&&e.size<t)return[!1,mo(t)];if(nr(r)&&e.size>r)return[!1,fo(r)]}return[!0,null]}function nr(e){return e!=null}function nh(e){var t=e.files,r=e.accept,n=e.minSize,i=e.maxSize,a=e.multiple,s=e.maxFiles,o=e.validator;return!a&&t.length>1||a&&s>=1&&t.length>s?!1:t.every(function(l){var f=Ql(l,r),u=fn(f,1),p=u[0],m=Yl(l,n,i),x=fn(m,1),w=x[0],c=o?o(l):null;return p&&w&&!c})}function ii(e){return typeof e.isPropagationStopped=="function"?e.isPropagationStopped():typeof e.cancelBubble<"u"?e.cancelBubble:!1}function Dn(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 ho(e){e.preventDefault()}function ih(e){return e.indexOf("MSIE")!==-1||e.indexOf("Trident/")!==-1}function ah(e){return e.indexOf("Edge/")!==-1}function sh(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:window.navigator.userAgent;return ih(e)||ah(e)}function xt(){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),s=1;s<i;s++)a[s-1]=arguments[s];return t.some(function(o){return!ii(n)&&o&&o.apply(void 0,[n].concat(a)),ii(n)})}}function oh(){return"showOpenFilePicker"in window}function lh(e){if(nr(e)){var t=Object.entries(e).filter(function(r){var n=fn(r,2),i=n[0],a=n[1],s=!0;return Gl(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.')),s=!1),(!Array.isArray(a)||!a.every(Zl))&&(console.warn('Skipped "'.concat(i,'" because an invalid file extension was provided.')),s=!1),s}).reduce(function(r,n){var i=fn(n,2),a=i[0],s=i[1];return po(po({},r),{},Hl({},a,s))},{});return[{description:"Files",accept:t}]}return e}function ch(e){if(nr(e))return Object.entries(e).reduce(function(t,r){var n=fn(r,2),i=n[0],a=n[1];return[].concat(co(t),[i],co(a))},[]).filter(function(t){return Gl(t)||Zl(t)}).join(",")}function uh(e){return e instanceof DOMException&&(e.name==="AbortError"||e.code===e.ABORT_ERR)}function ph(e){return e instanceof DOMException&&(e.name==="SecurityError"||e.code===e.SECURITY_ERR)}function Gl(e){return e==="audio/*"||e==="video/*"||e==="image/*"||e==="text/*"||e==="application/*"||/\w+\/[-+.\w]+/g.test(e)}function Zl(e){return/^.*\.[\w]+$/.test(e)}var dh=["children"],fh=["open"],mh=["refKey","role","onKeyDown","onFocus","onBlur","onClick","onDragEnter","onDragOver","onDragLeave","onDrop"],hh=["refKey","onChange","onClick"];function yh(e){return xh(e)||vh(e)||Xl(e)||gh()}function gh(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
182
182
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function vh(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function xh(e){if(Array.isArray(e))return ca(e)}function Di(e,t){return Sh(e)||wh(e,t)||Xl(e,t)||bh()}function bh(){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 Xl(e,t){if(e){if(typeof e=="string")return ca(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 ca(e,t)}}function ca(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 wh(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n=[],i=!0,a=!1,s,o;try{for(r=r.call(e);!(i=(s=r.next()).done)&&(n.push(s.value),!(t&&n.length===t));i=!0);}catch(l){a=!0,o=l}finally{try{!i&&r.return!=null&&r.return()}finally{if(a)throw o}}return n}}function Sh(e){if(Array.isArray(e))return e}function yo(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?yo(Object(r),!0).forEach(function(n){ua(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):yo(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function ua(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function ai(e,t){if(e==null)return{};var r=Eh(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 Eh(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 za=I.forwardRef(function(e,t){var r=e.children,n=ai(e,dh),i=ec(n),a=i.open,s=ai(i,fh);return I.useImperativeHandle(t,function(){return{open:a}},[a]),I.createElement(I.Fragment,null,r(Ae(Ae({},s),{},{open:a})))});za.displayName="Dropzone";var Jl={disabled:!1,getFilesFromEvent:$m,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};za.defaultProps=Jl;za.propTypes={children:g.func,accept:g.objectOf(g.arrayOf(g.string)),multiple:g.bool,preventDropOnDocument:g.bool,noClick:g.bool,noKeyboard:g.bool,noDrag:g.bool,noDragEventsBubbling:g.bool,minSize:g.number,maxSize:g.number,maxFiles:g.number,disabled:g.bool,getFilesFromEvent:g.func,onFileDialogCancel:g.func,onFileDialogOpen:g.func,useFsAccessApi:g.bool,autoFocus:g.bool,onDragEnter:g.func,onDragLeave:g.func,onDragOver:g.func,onDrop:g.func,onDropAccepted:g.func,onDropRejected:g.func,onError:g.func,validator:g.func};var pa={isFocused:!1,isFileDialogActive:!1,isDragActive:!1,isDragAccept:!1,isDragReject:!1,acceptedFiles:[],fileRejections:[]};function ec(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=Ae(Ae({},Jl),e),r=t.accept,n=t.disabled,i=t.getFilesFromEvent,a=t.maxSize,s=t.minSize,o=t.multiple,l=t.maxFiles,d=t.onDragEnter,u=t.onDragLeave,f=t.onDragOver,m=t.onDrop,x=t.onDropAccepted,S=t.onDropRejected,c=t.onFileDialogCancel,E=t.onFileDialogOpen,h=t.useFsAccessApi,_=t.autoFocus,$=t.preventDropOnDocument,T=t.noClick,w=t.noKeyboard,F=t.noDrag,X=t.noDragEventsBubbling,J=t.onError,W=t.validator,p=I.useMemo(function(){return ch(r)},[r]),R=I.useMemo(function(){return lh(r)},[r]),V=I.useMemo(function(){return typeof E=="function"?E:go},[E]),B=I.useMemo(function(){return typeof c=="function"?c:go},[c]),z=I.useRef(null),H=I.useRef(null),le=I.useReducer(Ch,pa),ce=Di(le,2),pe=ce[0],oe=ce[1],N=pe.isFocused,L=pe.isFileDialogActive,K=I.useRef(typeof window<"u"&&window.isSecureContext&&h&&oh()),se=function(){!K.current&&L&&setTimeout(function(){if(H.current){var j=H.current.files;j.length||(oe({type:"closeDialog"}),B())}},300)};I.useEffect(function(){return window.addEventListener("focus",se,!1),function(){window.removeEventListener("focus",se,!1)}},[H,L,B,K]);var ae=I.useRef([]),ee=function(j){z.current&&z.current.contains(j.target)||(j.preventDefault(),ae.current=[])};I.useEffect(function(){return $&&(document.addEventListener("dragover",ho,!1),document.addEventListener("drop",ee,!1)),function(){$&&(document.removeEventListener("dragover",ho),document.removeEventListener("drop",ee))}},[z,$]),I.useEffect(function(){return!n&&_&&z.current&&z.current.focus(),function(){}},[z,_,n]);var q=I.useCallback(function(A){J?J(A):console.error(A)},[J]),te=I.useCallback(function(A){A.preventDefault(),A.persist(),y(A),ae.current=[].concat(yh(ae.current),[A.target]),Dn(A)&&Promise.resolve(i(A)).then(function(j){if(!(ii(A)&&!X)){var G=j.length,de=G>0&&nh({files:j,accept:p,minSize:s,maxSize:a,multiple:o,maxFiles:l,validator:W}),he=G>0&&!de;oe({isDragAccept:de,isDragReject:he,isDragActive:!0,type:"setDraggedFiles"}),d&&d(A)}}).catch(function(j){return q(j)})},[i,d,q,X,p,s,a,o,l,W]),ue=I.useCallback(function(A){A.preventDefault(),A.persist(),y(A);var j=Dn(A);if(j&&A.dataTransfer)try{A.dataTransfer.dropEffect="copy"}catch{}return j&&f&&f(A),!1},[f,X]),M=I.useCallback(function(A){A.preventDefault(),A.persist(),y(A);var j=ae.current.filter(function(de){return z.current&&z.current.contains(de)}),G=j.indexOf(A.target);G!==-1&&j.splice(G,1),ae.current=j,!(j.length>0)&&(oe({type:"setDraggedFiles",isDragActive:!1,isDragAccept:!1,isDragReject:!1}),Dn(A)&&u&&u(A))},[z,u,X]),U=I.useCallback(function(A,j){var G=[],de=[];A.forEach(function(he){var ze=Ql(he,p),ut=Di(ze,2),it=ut[0],Yr=ut[1],er=Yl(he,s,a),Dt=Di(er,2),Gr=Dt[0],Er=Dt[1],Zr=W?W(he):null;if(it&&Gr&&!Zr)G.push(he);else{var Cr=[Yr,Er];Zr&&(Cr=Cr.concat(Zr)),de.push({file:he,errors:Cr.filter(function(rc){return rc})})}}),(!o&&G.length>1||o&&l>=1&&G.length>l)&&(G.forEach(function(he){de.push({file:he,errors:[rh]})}),G.splice(0)),oe({acceptedFiles:G,fileRejections:de,isDragReject:de.length>0,type:"setFiles"}),m&&m(G,de,j),de.length>0&&S&&S(de,j),G.length>0&&x&&x(G,j)},[oe,o,p,s,a,l,m,x,S,W]),re=I.useCallback(function(A){A.preventDefault(),A.persist(),y(A),ae.current=[],Dn(A)&&Promise.resolve(i(A)).then(function(j){ii(A)&&!X||U(j,A)}).catch(function(j){return q(j)}),oe({type:"reset"})},[i,U,q,X]),C=I.useCallback(function(){if(K.current){oe({type:"openDialog"}),V();var A={multiple:o,types:R};window.showOpenFilePicker(A).then(function(j){return i(j)}).then(function(j){U(j,null),oe({type:"closeDialog"})}).catch(function(j){uh(j)?(B(j),oe({type:"closeDialog"})):ph(j)?(K.current=!1,H.current?(H.current.value=null,H.current.click()):q(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."))):q(j)});return}H.current&&(oe({type:"openDialog"}),V(),H.current.value=null,H.current.click())},[oe,V,B,h,U,q,R,o]),Q=I.useCallback(function(A){!z.current||!z.current.isEqualNode(A.target)||(A.key===" "||A.key==="Enter"||A.keyCode===32||A.keyCode===13)&&(A.preventDefault(),C())},[z,C]),me=I.useCallback(function(){oe({type:"focus"})},[]),Te=I.useCallback(function(){oe({type:"blur"})},[]),Be=I.useCallback(function(){T||(sh()?setTimeout(C,0):C())},[T,C]),Se=function(j){return n?null:j},qe=function(j){return w?null:Se(j)},Je=function(j){return F?null:Se(j)},y=function(j){X&&j.stopPropagation()},O=I.useMemo(function(){return function(){var A=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},j=A.refKey,G=j===void 0?"ref":j,de=A.role,he=A.onKeyDown,ze=A.onFocus,ut=A.onBlur,it=A.onClick,Yr=A.onDragEnter,er=A.onDragOver,Dt=A.onDragLeave,Gr=A.onDrop,Er=ai(A,mh);return Ae(Ae(ua({onKeyDown:qe(xt(he,Q)),onFocus:qe(xt(ze,me)),onBlur:qe(xt(ut,Te)),onClick:Se(xt(it,Be)),onDragEnter:Je(xt(Yr,te)),onDragOver:Je(xt(er,ue)),onDragLeave:Je(xt(Dt,M)),onDrop:Je(xt(Gr,re)),role:typeof de=="string"&&de!==""?de:"presentation"},G,z),!n&&!w?{tabIndex:0}:{}),Er)}},[z,Q,me,Te,Be,te,ue,M,re,w,F,n]),k=I.useCallback(function(A){A.stopPropagation()},[]),Z=I.useMemo(function(){return function(){var A=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},j=A.refKey,G=j===void 0?"ref":j,de=A.onChange,he=A.onClick,ze=ai(A,hh),ut=ua({accept:p,multiple:o,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:Se(xt(de,re)),onClick:Se(xt(he,k)),tabIndex:-1},G,H);return Ae(Ae({},ut),ze)}},[H,r,o,re,n]);return Ae(Ae({},pe),{},{isFocused:N&&!n,getRootProps:O,getInputProps:Z,rootRef:z,inputRef:H,open:Se(C)})}function Ch(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({},pa),{},{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({},pa);default:return e}}function go(){}const Th=kt(v.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"),kh=kt(v.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"),vo=kt(v.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"),Oh=kt(v.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"),tc=({file:e,onRemove:t})=>{const r=()=>e.file.type.startsWith("image/")?v.jsx(Oh,{}):e.file.type.includes("pdf")?v.jsx(vo,{}):v.jsx(vo,{}),n=()=>{switch(e.status){case"success":return v.jsx(Th,{color:"success"});case"uploading":return v.jsx(D.CircularProgress,{size:16});default:return null}},i=a=>{if(a===0)return"0 Bytes";const s=1024,o=["Bytes","KB","MB","GB"],l=Math.floor(Math.log(a)/Math.log(s));return parseFloat((a/Math.pow(s,l)).toFixed(2))+" "+o[l]};return v.jsxs(D.Paper,{sx:{p:2,mb:1,display:"flex",alignItems:"center",gap:2,border:"1px solid #e0e0e0"},children:[v.jsxs(D.Box,{sx:{display:"flex",alignItems:"center",gap:1},children:[r(),n()]}),v.jsxs(D.Box,{sx:{flex:1,minWidth:0},children:[v.jsx(D.Typography,{variant:"body2",noWrap:!0,children:e.file.name}),v.jsxs(D.Typography,{variant:"caption",color:"textSecondary",children:[i(e.file.size)," • ",e.file.type]})]}),v.jsx(D.Tooltip,{title:"Remove file",children:v.jsx(D.IconButton,{size:"small",onClick:()=>t(e.id),color:"error",children:v.jsx(kh,{})})})]})},_h=({config:e,value:t=[],onChange:r,onSubmit:n,disabled:i=!1,className:a,style:s,title:o,subtitle:l,buttonText:d,fileSupportedText:u})=>{const[f,m]=I.useState(t),[x,S]=I.useState([]),[c,E]=I.useState(!1),[h,_]=I.useState(!1),[$,T]=I.useState([]),w=I.useRef(null);I.useEffect(()=>{m(t)},[t]);const F=I.useCallback(z=>{var le,ce;return((le=e==null?void 0:e.fileTypes)==null?void 0:le.some(pe=>{if(pe.includes("*")){const oe=pe.split("/")[0];return z.type.startsWith(oe)}return z.type===pe}))?e!=null&&e.maxSize&&z.size>e.maxSize?`File size exceeds maximum limit of ${(e.maxSize/1048576).toFixed(1)}MB`:null:`File type ${z.type} is not allowed. Allowed types: ${(ce=e==null?void 0:e.fileTypes)==null?void 0:ce.join(", ")}`},[e]),X=I.useCallback(async z=>{console.log("handleFiles called with:",z.length,"files"),E(!0);const H=[],le=[];try{for(const pe of z){let oe=null;if(e!=null&&e.multiple&&f.some(L=>L.file.name===pe.name&&L.file.size===pe.size&&L.file.lastModified===pe.lastModified)){le.push(`${pe.name}: File already exists`);continue}if(oe=F(pe),!oe&&(e!=null&&e.customValidation))try{const N=e.customValidation(pe);N instanceof Promise?oe=await N:oe=N}catch(N){oe=`Custom validation failed: ${N instanceof Error?N.message:"Unknown error"}`}if(oe)le.push(`${pe.name}: ${oe}`);else{const N={id:`${Date.now()}-${Math.random().toString(36).substr(2,9)}`,file:pe,preview:pe.type.startsWith("image/")?URL.createObjectURL(pe):void 0,progress:0,status:"pending",uploadedAt:new Date};H.push(N)}}const ce=e!=null&&e.multiple?[...f,...H]:H;m(ce),r==null||r(ce),le.length>0?(T(le),S(le)):(T([]),S([]))}catch(ce){const pe=`Unexpected error: ${ce instanceof Error?ce.message:"Unknown error"}`;T([pe]),S([pe])}},[f,e==null?void 0:e.multiple,F,e==null?void 0:e.customValidation,r]),J=I.useCallback(z=>{E(!0);const H=f.filter(le=>le.id!==z);m(H),r==null||r(H),T([]),w.current&&(w.current.value="")},[f,r]),W=I.useCallback(()=>{if(e!=null&&e.required&&f.length===0){S([`${e.title} is required`]);return}T([]),_(!0);const z=f.filter(H=>H.status!=="error");n==null||n(z)},[f,n,e==null?void 0:e.required,e==null?void 0:e.title]),{getRootProps:p,getInputProps:R,isDragActive:V}=ec({onDrop:X,multiple:e==null?void 0:e.multiple,disabled:i,noClick:!1,noKeyboard:!1});I.useEffect(()=>{if(!c)return;const z=[],H=[...$,...z];H.length>0?S(H):S([])},[f,e==null?void 0:e.required,e==null?void 0:e.title,c,h,$]);const B=()=>{var z;switch(((z=e==null?void 0:e.submitButton)==null?void 0:z.position)||"right"){case"left":return"flex-start";case"center":return"center";case"right":return"flex-end";default:return"flex-end"}};return v.jsxs(D.Box,{className:a,style:s,children:[v.jsxs(D.Typography,{variant:"h6",gutterBottom:!0,children:[e==null?void 0:e.title,(e==null?void 0:e.required)&&v.jsx("span",{style:{color:"red"},children:" *"})]}),(e==null?void 0:e.description)&&v.jsx(D.Typography,{variant:"body2",color:"textSecondary",gutterBottom:!0,children:e==null?void 0:e.description}),I.createElement(D.Card,{...p(),key:`dropzone-${f.length}`,sx:{border:"1px dashed",borderColor:V?"primary.main":"#CCCCCC",backgroundColor:V?"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"}}},v.jsx("input",{...R(),ref:w}),v.jsx(D.IconButton,{sx:{borderRadius:"8px"},children:v.jsx(ei,{sx:{width:36,height:36,color:"primary.main"}})}),v.jsx(D.Typography,{sx:{fontSize:"16px",fontWeight:600,color:"primary.main"},children:o}),v.jsx(D.Typography,{sx:{fontSize:"12px",fontWeight:400,color:"primary.main"},children:l}),v.jsx(D.Button,{onClick:()=>{var z;return(z=w.current)==null?void 0:z.click()},sx:{my:2},startIcon:v.jsx(ei,{}),variant:"contained",children:d}),v.jsx(D.Typography,{sx:{fontSize:"12px",fontWeight:400},children:u})),x.length>0&&v.jsx(D.Alert,{severity:"error",sx:{mt:2},children:x.map((z,H)=>v.jsx(D.Typography,{variant:"body2",children:z},H))}),f.length>0&&v.jsxs(D.Box,{sx:{mt:2},children:[v.jsxs(D.Typography,{variant:"subtitle1",gutterBottom:!0,children:["Selected Files (",f.length,")"]}),f.map(z=>v.jsx(tc,{file:z,onRemove:J},z.id))]}),(e==null?void 0:e.helperText)&&v.jsx(D.Typography,{variant:"caption",color:"textSecondary",sx:{mt:1,display:"block"},children:e.helperText}),(e==null?void 0:e.submitButton)&&v.jsx(D.Box,{sx:{mt:3,display:"flex",justifyContent:B()},children:v.jsx(D.Button,{variant:"contained",onClick:W,disabled:i||e.submitButton.disabled||f.length===0,startIcon:e.submitButton.loading?v.jsx(D.CircularProgress,{size:16,color:"inherit"}):void 0,children:e.submitButton.text})})]})};exports.CustomButtons=ql;exports.DocumentUpload=_h;exports.FieldRenderer=Tl;exports.FilePreview=tc;exports.FinForm=Om;exports.ImageComponent=Am;exports.StepNavigation=Ll;exports.fetchApiData=El;exports.generateSchema=Bl;exports.getApiConfig=Pa;exports.hasApiConfig=rr;exports.shouldShowField=Wf;exports.useApiData=Cl;
183
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Xl(e,t){if(e){if(typeof e=="string")return ca(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 ca(e,t)}}function ca(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 wh(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n=[],i=!0,a=!1,s,o;try{for(r=r.call(e);!(i=(s=r.next()).done)&&(n.push(s.value),!(t&&n.length===t));i=!0);}catch(l){a=!0,o=l}finally{try{!i&&r.return!=null&&r.return()}finally{if(a)throw o}}return n}}function Sh(e){if(Array.isArray(e))return e}function yo(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 je(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?yo(Object(r),!0).forEach(function(n){ua(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):yo(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function ua(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function ai(e,t){if(e==null)return{};var r=Eh(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 Eh(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 za=D.forwardRef(function(e,t){var r=e.children,n=ai(e,dh),i=ec(n),a=i.open,s=ai(i,fh);return D.useImperativeHandle(t,function(){return{open:a}},[a]),D.createElement(D.Fragment,null,r(je(je({},s),{},{open:a})))});za.displayName="Dropzone";var Jl={disabled:!1,getFilesFromEvent:$m,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};za.defaultProps=Jl;za.propTypes={children:g.func,accept:g.objectOf(g.arrayOf(g.string)),multiple:g.bool,preventDropOnDocument:g.bool,noClick:g.bool,noKeyboard:g.bool,noDrag:g.bool,noDragEventsBubbling:g.bool,minSize:g.number,maxSize:g.number,maxFiles:g.number,disabled:g.bool,getFilesFromEvent:g.func,onFileDialogCancel:g.func,onFileDialogOpen:g.func,useFsAccessApi:g.bool,autoFocus:g.bool,onDragEnter:g.func,onDragLeave:g.func,onDragOver:g.func,onDrop:g.func,onDropAccepted:g.func,onDropRejected:g.func,onError:g.func,validator:g.func};var pa={isFocused:!1,isFileDialogActive:!1,isDragActive:!1,isDragAccept:!1,isDragReject:!1,acceptedFiles:[],fileRejections:[]};function ec(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=je(je({},Jl),e),r=t.accept,n=t.disabled,i=t.getFilesFromEvent,a=t.maxSize,s=t.minSize,o=t.multiple,l=t.maxFiles,f=t.onDragEnter,u=t.onDragLeave,p=t.onDragOver,m=t.onDrop,x=t.onDropAccepted,w=t.onDropRejected,c=t.onFileDialogCancel,E=t.onFileDialogOpen,y=t.useFsAccessApi,C=t.autoFocus,A=t.preventDropOnDocument,_=t.noClick,b=t.noKeyboard,L=t.noDrag,j=t.noDragEventsBubbling,ee=t.onError,K=t.validator,d=D.useMemo(function(){return ch(r)},[r]),z=D.useMemo(function(){return lh(r)},[r]),P=D.useMemo(function(){return typeof E=="function"?E:go},[E]),q=D.useMemo(function(){return typeof c=="function"?c:go},[c]),N=D.useRef(null),Y=D.useRef(null),re=D.useReducer(Th,pa),me=Di(re,2),ce=me[0],oe=me[1],V=ce.isFocused,U=ce.isFileDialogActive,ue=D.useRef(typeof window<"u"&&window.isSecureContext&&y&&oh()),Q=function(){!ue.current&&U&&setTimeout(function(){if(Y.current){var F=Y.current.files;F.length||(oe({type:"closeDialog"}),q())}},300)};D.useEffect(function(){return window.addEventListener("focus",Q,!1),function(){window.removeEventListener("focus",Q,!1)}},[Y,U,q,ue]);var te=D.useRef([]),le=function(F){N.current&&N.current.contains(F.target)||(F.preventDefault(),te.current=[])};D.useEffect(function(){return A&&(document.addEventListener("dragover",ho,!1),document.addEventListener("drop",le,!1)),function(){A&&(document.removeEventListener("dragover",ho),document.removeEventListener("drop",le))}},[N,A]),D.useEffect(function(){return!n&&C&&N.current&&N.current.focus(),function(){}},[N,C,n]);var W=D.useCallback(function(O){ee?ee(O):console.error(O)},[ee]),H=D.useCallback(function(O){O.preventDefault(),O.persist(),h(O),te.current=[].concat(yh(te.current),[O.target]),Dn(O)&&Promise.resolve(i(O)).then(function(F){if(!(ii(O)&&!j)){var J=F.length,de=J>0&&nh({files:F,accept:d,minSize:s,maxSize:a,multiple:o,maxFiles:l,validator:K}),he=J>0&&!de;oe({isDragAccept:de,isDragReject:he,isDragActive:!0,type:"setDraggedFiles"}),f&&f(O)}}).catch(function(F){return W(F)})},[i,f,W,j,d,s,a,o,l,K]),ae=D.useCallback(function(O){O.preventDefault(),O.persist(),h(O);var F=Dn(O);if(F&&O.dataTransfer)try{O.dataTransfer.dropEffect="copy"}catch{}return F&&p&&p(O),!1},[p,j]),pe=D.useCallback(function(O){O.preventDefault(),O.persist(),h(O);var F=te.current.filter(function(de){return N.current&&N.current.contains(de)}),J=F.indexOf(O.target);J!==-1&&F.splice(J,1),te.current=F,!(F.length>0)&&(oe({type:"setDraggedFiles",isDragActive:!1,isDragAccept:!1,isDragReject:!1}),Dn(O)&&u&&u(O))},[N,u,j]),M=D.useCallback(function(O,F){var J=[],de=[];O.forEach(function(he){var Ne=Ql(he,d),ut=Di(Ne,2),it=ut[0],Yr=ut[1],er=Yl(he,s,a),Dt=Di(er,2),Gr=Dt[0],Er=Dt[1],Zr=K?K(he):null;if(it&&Gr&&!Zr)J.push(he);else{var Tr=[Yr,Er];Zr&&(Tr=Tr.concat(Zr)),de.push({file:he,errors:Tr.filter(function(rc){return rc})})}}),(!o&&J.length>1||o&&l>=1&&J.length>l)&&(J.forEach(function(he){de.push({file:he,errors:[rh]})}),J.splice(0)),oe({acceptedFiles:J,fileRejections:de,isDragReject:de.length>0,type:"setFiles"}),m&&m(J,de,F),de.length>0&&w&&w(de,F),J.length>0&&x&&x(J,F)},[oe,o,d,s,a,l,m,x,w,K]),se=D.useCallback(function(O){O.preventDefault(),O.persist(),h(O),te.current=[],Dn(O)&&Promise.resolve(i(O)).then(function(F){ii(O)&&!j||M(F,O)}).catch(function(F){return W(F)}),oe({type:"reset"})},[i,M,W,j]),I=D.useCallback(function(){if(ue.current){oe({type:"openDialog"}),P();var O={multiple:o,types:z};window.showOpenFilePicker(O).then(function(F){return i(F)}).then(function(F){M(F,null),oe({type:"closeDialog"})}).catch(function(F){uh(F)?(q(F),oe({type:"closeDialog"})):ph(F)?(ue.current=!1,Y.current?(Y.current.value=null,Y.current.click()):W(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."))):W(F)});return}Y.current&&(oe({type:"openDialog"}),P(),Y.current.value=null,Y.current.click())},[oe,P,q,y,M,W,z,o]),B=D.useCallback(function(O){!N.current||!N.current.isEqualNode(O.target)||(O.key===" "||O.key==="Enter"||O.keyCode===32||O.keyCode===13)&&(O.preventDefault(),I())},[N,I]),G=D.useCallback(function(){oe({type:"focus"})},[]),ye=D.useCallback(function(){oe({type:"blur"})},[]),Fe=D.useCallback(function(){_||(sh()?setTimeout(I,0):I())},[_,I]),_e=function(F){return n?null:F},ke=function(F){return b?null:_e(F)},qe=function(F){return L?null:_e(F)},h=function(F){j&&F.stopPropagation()},k=D.useMemo(function(){return function(){var O=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},F=O.refKey,J=F===void 0?"ref":F,de=O.role,he=O.onKeyDown,Ne=O.onFocus,ut=O.onBlur,it=O.onClick,Yr=O.onDragEnter,er=O.onDragOver,Dt=O.onDragLeave,Gr=O.onDrop,Er=ai(O,mh);return je(je(ua({onKeyDown:ke(xt(he,B)),onFocus:ke(xt(Ne,G)),onBlur:ke(xt(ut,ye)),onClick:_e(xt(it,Fe)),onDragEnter:qe(xt(Yr,H)),onDragOver:qe(xt(er,ae)),onDragLeave:qe(xt(Dt,pe)),onDrop:qe(xt(Gr,se)),role:typeof de=="string"&&de!==""?de:"presentation"},J,N),!n&&!b?{tabIndex:0}:{}),Er)}},[N,B,G,ye,Fe,H,ae,pe,se,b,L,n]),T=D.useCallback(function(O){O.stopPropagation()},[]),Z=D.useMemo(function(){return function(){var O=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},F=O.refKey,J=F===void 0?"ref":F,de=O.onChange,he=O.onClick,Ne=ai(O,hh),ut=ua({accept:d,multiple:o,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:_e(xt(de,se)),onClick:_e(xt(he,T)),tabIndex:-1},J,Y);return je(je({},ut),Ne)}},[Y,r,o,se,n]);return je(je({},ce),{},{isFocused:V&&!n,getRootProps:k,getInputProps:Z,rootRef:N,inputRef:Y,open:_e(I)})}function Th(e,t){switch(t.type){case"focus":return je(je({},e),{},{isFocused:!0});case"blur":return je(je({},e),{},{isFocused:!1});case"openDialog":return je(je({},pa),{},{isFileDialogActive:!0});case"closeDialog":return je(je({},e),{},{isFileDialogActive:!1});case"setDraggedFiles":return je(je({},e),{},{isDragActive:t.isDragActive,isDragAccept:t.isDragAccept,isDragReject:t.isDragReject});case"setFiles":return je(je({},e),{},{acceptedFiles:t.acceptedFiles,fileRejections:t.fileRejections,isDragReject:t.isDragReject});case"reset":return je({},pa);default:return e}}function go(){}const kh=Ct(v.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"),Ch=Ct(v.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"),vo=Ct(v.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"),Oh=Ct(v.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"),tc=({file:e,onRemove:t})=>{const r=()=>e.file.type.startsWith("image/")?v.jsx(Oh,{}):e.file.type.includes("pdf")?v.jsx(vo,{}):v.jsx(vo,{}),n=()=>{switch(e.status){case"success":return v.jsx(kh,{color:"success"});case"uploading":return v.jsx(R.CircularProgress,{size:16});default:return null}},i=a=>{if(a===0)return"0 Bytes";const s=1024,o=["Bytes","KB","MB","GB"],l=Math.floor(Math.log(a)/Math.log(s));return parseFloat((a/Math.pow(s,l)).toFixed(2))+" "+o[l]};return v.jsxs(R.Paper,{sx:{p:2,mb:1,display:"flex",alignItems:"center",gap:2,border:"1px solid #e0e0e0"},children:[v.jsxs(R.Box,{sx:{display:"flex",alignItems:"center",gap:1},children:[r(),n()]}),v.jsxs(R.Box,{sx:{flex:1,minWidth:0},children:[v.jsx(R.Typography,{variant:"body2",noWrap:!0,children:e.file.name}),v.jsxs(R.Typography,{variant:"caption",color:"textSecondary",children:[i(e.file.size)," • ",e.file.type]})]}),v.jsx(R.Tooltip,{title:"Remove file",children:v.jsx(R.IconButton,{size:"small",onClick:()=>t(e.id),color:"error",children:v.jsx(Ch,{})})})]})},_h=({config:e,value:t=[],onChange:r,onSubmit:n,disabled:i=!1,className:a,style:s,title:o,subtitle:l,buttonText:f,fileSupportedText:u})=>{const[p,m]=D.useState(t),[x,w]=D.useState([]),[c,E]=D.useState(!1),[y,C]=D.useState(!1),[A,_]=D.useState([]),b=D.useRef(null);D.useEffect(()=>{m(t)},[t]);const L=D.useCallback(N=>{var re,me;return((re=e==null?void 0:e.fileTypes)==null?void 0:re.some(ce=>{if(ce.includes("*")){const oe=ce.split("/")[0];return N.type.startsWith(oe)}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: ${(me=e==null?void 0:e.fileTypes)==null?void 0:me.join(", ")}`},[e]),j=D.useCallback(async N=>{console.log("handleFiles called with:",N.length,"files"),E(!0);const Y=[],re=[];try{for(const ce of N){let oe=null;if(e!=null&&e.multiple&&p.some(U=>U.file.name===ce.name&&U.file.size===ce.size&&U.file.lastModified===ce.lastModified)){re.push(`${ce.name}: File already exists`);continue}if(oe=L(ce),!oe&&(e!=null&&e.customValidation))try{const V=e.customValidation(ce);V instanceof Promise?oe=await V:oe=V}catch(V){oe=`Custom validation failed: ${V instanceof Error?V.message:"Unknown error"}`}if(oe)re.push(`${ce.name}: ${oe}`);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};Y.push(V)}}const me=e!=null&&e.multiple?[...p,...Y]:Y;m(me),r==null||r(me),re.length>0?(_(re),w(re)):(_([]),w([]))}catch(me){const ce=`Unexpected error: ${me instanceof Error?me.message:"Unknown error"}`;_([ce]),w([ce])}},[p,e==null?void 0:e.multiple,L,e==null?void 0:e.customValidation,r]),ee=D.useCallback(N=>{E(!0);const Y=p.filter(re=>re.id!==N);m(Y),r==null||r(Y),_([]),b.current&&(b.current.value="")},[p,r]),K=D.useCallback(()=>{if(e!=null&&e.required&&p.length===0){w([`${e.title} is required`]);return}_([]),C(!0);const N=p.filter(Y=>Y.status!=="error");n==null||n(N)},[p,n,e==null?void 0:e.required,e==null?void 0:e.title]),{getRootProps:d,getInputProps:z,isDragActive:P}=ec({onDrop:j,multiple:e==null?void 0:e.multiple,disabled:i,noClick:!1,noKeyboard:!1});D.useEffect(()=>{if(!c)return;const N=[],Y=[...A,...N];Y.length>0?w(Y):w([])},[p,e==null?void 0:e.required,e==null?void 0:e.title,c,y,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 v.jsxs(R.Box,{className:a,style:s,children:[v.jsxs(R.Typography,{variant:"h6",gutterBottom:!0,children:[e==null?void 0:e.title,(e==null?void 0:e.required)&&v.jsx("span",{style:{color:"red"},children:" *"})]}),(e==null?void 0:e.description)&&v.jsx(R.Typography,{variant:"body2",color:"textSecondary",gutterBottom:!0,children:e==null?void 0:e.description}),D.createElement(R.Card,{...d(),key:`dropzone-${p.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"}}},v.jsx("input",{...z(),ref:b}),v.jsx(R.IconButton,{sx:{borderRadius:"8px"},children:v.jsx(ei,{sx:{width:36,height:36,color:"primary.main"}})}),v.jsx(R.Typography,{sx:{fontSize:"16px",fontWeight:600,color:"primary.main"},children:o}),v.jsx(R.Typography,{sx:{fontSize:"12px",fontWeight:400,color:"primary.main"},children:l}),v.jsx(R.Button,{onClick:()=>{var N;return(N=b.current)==null?void 0:N.click()},sx:{my:2},startIcon:v.jsx(ei,{}),variant:"contained",children:f}),v.jsx(R.Typography,{sx:{fontSize:"12px",fontWeight:400},children:u})),x.length>0&&v.jsx(R.Alert,{severity:"error",sx:{mt:2},children:x.map((N,Y)=>v.jsx(R.Typography,{variant:"body2",children:N},Y))}),p.length>0&&v.jsxs(R.Box,{sx:{mt:2},children:[v.jsxs(R.Typography,{variant:"subtitle1",gutterBottom:!0,children:["Selected Files (",p.length,")"]}),p.map(N=>v.jsx(tc,{file:N,onRemove:ee},N.id))]}),(e==null?void 0:e.helperText)&&v.jsx(R.Typography,{variant:"caption",color:"textSecondary",sx:{mt:1,display:"block"},children:e.helperText}),(e==null?void 0:e.submitButton)&&v.jsx(R.Box,{sx:{mt:3,display:"flex",justifyContent:q()},children:v.jsx(R.Button,{variant:"contained",onClick:K,disabled:i||e.submitButton.disabled||p.length===0,startIcon:e.submitButton.loading?v.jsx(R.CircularProgress,{size:16,color:"inherit"}):void 0,children:e.submitButton.text})})]})};exports.CustomButtons=ql;exports.DocumentUpload=_h;exports.FieldRenderer=kl;exports.FilePreview=tc;exports.FinForm=Om;exports.ImageComponent=Am;exports.StepNavigation=Ll;exports.fetchApiData=El;exports.generateSchema=Bl;exports.getApiConfig=Pa;exports.hasApiConfig=rr;exports.shouldShowField=Wf;exports.useApiData=Tl;
184
184
  //# sourceMappingURL=index.js.map