@data-c/ui 0.2.51 → 0.2.52

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.mjs CHANGED
@@ -1,13 +1,161 @@
1
- var If=Object.create;var nc=Object.defineProperty;var Ef=Object.getOwnPropertyDescriptor;var Af=Object.getOwnPropertyNames;var Mf=Object.getPrototypeOf,Df=Object.prototype.hasOwnProperty;var ne=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var Ff=(e,t,r,o)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of Af(t))!Df.call(e,n)&&n!==r&&nc(e,n,{get:()=>t[n],enumerable:!(o=Ef(t,n))||o.enumerable});return e};var Xe=(e,t,r)=>(r=e!=null?If(Mf(e)):{},Ff(t||!e||!e.__esModule?nc(r,"default",{value:e,enumerable:!0}):r,e));var Ec=ne(z=>{"use strict";var X=typeof Symbol=="function"&&Symbol.for,ni=X?Symbol.for("react.element"):60103,ii=X?Symbol.for("react.portal"):60106,to=X?Symbol.for("react.fragment"):60107,ro=X?Symbol.for("react.strict_mode"):60108,oo=X?Symbol.for("react.profiler"):60114,no=X?Symbol.for("react.provider"):60109,io=X?Symbol.for("react.context"):60110,ai=X?Symbol.for("react.async_mode"):60111,ao=X?Symbol.for("react.concurrent_mode"):60111,so=X?Symbol.for("react.forward_ref"):60112,lo=X?Symbol.for("react.suspense"):60113,Bm=X?Symbol.for("react.suspense_list"):60120,co=X?Symbol.for("react.memo"):60115,uo=X?Symbol.for("react.lazy"):60116,_m=X?Symbol.for("react.block"):60121,Lm=X?Symbol.for("react.fundamental"):60117,$m=X?Symbol.for("react.responder"):60118,Nm=X?Symbol.for("react.scope"):60119;function he(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case ni:switch(e=e.type,e){case ai:case ao:case to:case oo:case ro:case lo:return e;default:switch(e=e&&e.$$typeof,e){case io:case so:case uo:case co:case no:return e;default:return t}}case ii:return t}}}function Ic(e){return he(e)===ao}z.AsyncMode=ai;z.ConcurrentMode=ao;z.ContextConsumer=io;z.ContextProvider=no;z.Element=ni;z.ForwardRef=so;z.Fragment=to;z.Lazy=uo;z.Memo=co;z.Portal=ii;z.Profiler=oo;z.StrictMode=ro;z.Suspense=lo;z.isAsyncMode=function(e){return Ic(e)||he(e)===ai};z.isConcurrentMode=Ic;z.isContextConsumer=function(e){return he(e)===io};z.isContextProvider=function(e){return he(e)===no};z.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===ni};z.isForwardRef=function(e){return he(e)===so};z.isFragment=function(e){return he(e)===to};z.isLazy=function(e){return he(e)===uo};z.isMemo=function(e){return he(e)===co};z.isPortal=function(e){return he(e)===ii};z.isProfiler=function(e){return he(e)===oo};z.isStrictMode=function(e){return he(e)===ro};z.isSuspense=function(e){return he(e)===lo};z.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===to||e===ao||e===oo||e===ro||e===lo||e===Bm||typeof e=="object"&&e!==null&&(e.$$typeof===uo||e.$$typeof===co||e.$$typeof===no||e.$$typeof===io||e.$$typeof===so||e.$$typeof===Lm||e.$$typeof===$m||e.$$typeof===Nm||e.$$typeof===_m)};z.typeOf=he});var Ac=ne(W=>{"use strict";process.env.NODE_ENV!=="production"&&function(){"use strict";var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,o=e?Symbol.for("react.fragment"):60107,n=e?Symbol.for("react.strict_mode"):60108,a=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,s=e?Symbol.for("react.async_mode"):60111,c=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,f=e?Symbol.for("react.suspense_list"):60120,m=e?Symbol.for("react.memo"):60115,g=e?Symbol.for("react.lazy"):60116,p=e?Symbol.for("react.block"):60121,y=e?Symbol.for("react.fundamental"):60117,v=e?Symbol.for("react.responder"):60118,x=e?Symbol.for("react.scope"):60119;function S(T){return typeof T=="string"||typeof T=="function"||T===o||T===c||T===a||T===n||T===d||T===f||typeof T=="object"&&T!==null&&(T.$$typeof===g||T.$$typeof===m||T.$$typeof===i||T.$$typeof===l||T.$$typeof===u||T.$$typeof===y||T.$$typeof===v||T.$$typeof===x||T.$$typeof===p)}function w(T){if(typeof T=="object"&&T!==null){var qn=T.$$typeof;switch(qn){case t:var Kr=T.type;switch(Kr){case s:case c:case o:case a:case n:case d:return Kr;default:var oc=Kr&&Kr.$$typeof;switch(oc){case l:case u:case g:case m:case i:return oc;default:return qn}}case r:return qn}}}var C=s,k=c,P=l,Q=i,$=t,se=u,E=o,le=g,h=m,b=r,I=a,M=n,A=d,B=!1;function D(T){return B||(B=!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.")),F(T)||w(T)===s}function F(T){return w(T)===c}function _(T){return w(T)===l}function N(T){return w(T)===i}function L(T){return typeof T=="object"&&T!==null&&T.$$typeof===t}function pe(T){return w(T)===u}function oe(T){return w(T)===o}function Je(T){return w(T)===g}function wf(T){return w(T)===m}function Sf(T){return w(T)===r}function Tf(T){return w(T)===a}function Pf(T){return w(T)===n}function kf(T){return w(T)===d}W.AsyncMode=C,W.ConcurrentMode=k,W.ContextConsumer=P,W.ContextProvider=Q,W.Element=$,W.ForwardRef=se,W.Fragment=E,W.Lazy=le,W.Memo=h,W.Portal=b,W.Profiler=I,W.StrictMode=M,W.Suspense=A,W.isAsyncMode=D,W.isConcurrentMode=F,W.isContextConsumer=_,W.isContextProvider=N,W.isElement=L,W.isForwardRef=pe,W.isFragment=oe,W.isLazy=Je,W.isMemo=wf,W.isPortal=Sf,W.isProfiler=Tf,W.isStrictMode=Pf,W.isSuspense=kf,W.isValidElementType=S,W.typeOf=w}()});var li=ne((L2,si)=>{"use strict";process.env.NODE_ENV==="production"?si.exports=Ec():si.exports=Ac()});var Fc=ne(($2,Dc)=>{"use strict";var Mc=Object.getOwnPropertySymbols,Vm=Object.prototype.hasOwnProperty,zm=Object.prototype.propertyIsEnumerable;function Wm(e){if(e==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}function Gm(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de",Object.getOwnPropertyNames(e)[0]==="5")return!1;for(var t={},r=0;r<10;r++)t["_"+String.fromCharCode(r)]=r;var o=Object.getOwnPropertyNames(t).map(function(a){return t[a]});if(o.join("")!=="0123456789")return!1;var n={};return"abcdefghijklmnopqrst".split("").forEach(function(a){n[a]=a}),Object.keys(Object.assign({},n)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}Dc.exports=Gm()?Object.assign:function(e,t){for(var r,o=Wm(e),n,a=1;a<arguments.length;a++){r=Object(arguments[a]);for(var i in r)Vm.call(r,i)&&(o[i]=r[i]);if(Mc){n=Mc(r);for(var l=0;l<n.length;l++)zm.call(r,n[l])&&(o[n[l]]=r[n[l]])}}return o}});var po=ne((N2,Rc)=>{"use strict";var Hm="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";Rc.exports=Hm});var ci=ne((V2,Oc)=>{Oc.exports=Function.call.bind(Object.prototype.hasOwnProperty)});var Nc=ne((z2,$c)=>{"use strict";var ui=function(){};process.env.NODE_ENV!=="production"&&(Bc=po(),fo={},_c=ci(),ui=function(e){var t="Warning: "+e;typeof console<"u"&&console.error(t);try{throw new Error(t)}catch{}});var Bc,fo,_c;function Lc(e,t,r,o,n){if(process.env.NODE_ENV!=="production"){for(var a in e)if(_c(e,a)){var i;try{if(typeof e[a]!="function"){var l=Error((o||"React class")+": "+r+" type `"+a+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof e[a]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw l.name="Invariant Violation",l}i=e[a](t,a,o,r,null,Bc)}catch(c){i=c}if(i&&!(i instanceof Error)&&ui((o||"React class")+": type specification of "+r+" `"+a+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof i+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),i instanceof Error&&!(i.message in fo)){fo[i.message]=!0;var s=n?n():"";ui("Failed "+r+" type: "+i.message+(s??""))}}}}Lc.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(fo={})};$c.exports=Lc});var Wc=ne((W2,zc)=>{"use strict";var Um=li(),jm=Fc(),_t=po(),pi=ci(),Vc=Nc(),Lt=function(){};process.env.NODE_ENV!=="production"&&(Lt=function(e){var t="Warning: "+e;typeof console<"u"&&console.error(t);try{throw new Error(t)}catch{}});function mo(){return null}zc.exports=function(e,t){var r=typeof Symbol=="function"&&Symbol.iterator,o="@@iterator";function n(h){var b=h&&(r&&h[r]||h[o]);if(typeof b=="function")return b}var a="<<anonymous>>",i={array:u("array"),bigint:u("bigint"),bool:u("boolean"),func:u("function"),number:u("number"),object:u("object"),string:u("string"),symbol:u("symbol"),any:d(),arrayOf:f,element:m(),elementType:g(),instanceOf:p,node:S(),objectOf:v,oneOf:y,oneOfType:x,shape:C,exact:k};function l(h,b){return h===b?h!==0||1/h===1/b:h!==h&&b!==b}function s(h,b){this.message=h,this.data=b&&typeof b=="object"?b:{},this.stack=""}s.prototype=Error.prototype;function c(h){if(process.env.NODE_ENV!=="production")var b={},I=0;function M(B,D,F,_,N,L,pe){if(_=_||a,L=L||F,pe!==_t){if(t){var oe=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 oe.name="Invariant Violation",oe}else if(process.env.NODE_ENV!=="production"&&typeof console<"u"){var Je=_+":"+F;!b[Je]&&I<3&&(Lt("You are manually calling a React.PropTypes validation function for the `"+L+"` prop on `"+_+"`. 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."),b[Je]=!0,I++)}}return D[F]==null?B?D[F]===null?new s("The "+N+" `"+L+"` is marked as required "+("in `"+_+"`, but its value is `null`.")):new s("The "+N+" `"+L+"` is marked as required in "+("`"+_+"`, but its value is `undefined`.")):null:h(D,F,_,N,L)}var A=M.bind(null,!1);return A.isRequired=M.bind(null,!0),A}function u(h){function b(I,M,A,B,D,F){var _=I[M],N=$(_);if(N!==h){var L=se(_);return new s("Invalid "+B+" `"+D+"` of type "+("`"+L+"` supplied to `"+A+"`, expected ")+("`"+h+"`."),{expectedType:h})}return null}return c(b)}function d(){return c(mo)}function f(h){function b(I,M,A,B,D){if(typeof h!="function")return new s("Property `"+D+"` of component `"+A+"` has invalid PropType notation inside arrayOf.");var F=I[M];if(!Array.isArray(F)){var _=$(F);return new s("Invalid "+B+" `"+D+"` of type "+("`"+_+"` supplied to `"+A+"`, expected an array."))}for(var N=0;N<F.length;N++){var L=h(F,N,A,B,D+"["+N+"]",_t);if(L instanceof Error)return L}return null}return c(b)}function m(){function h(b,I,M,A,B){var D=b[I];if(!e(D)){var F=$(D);return new s("Invalid "+A+" `"+B+"` of type "+("`"+F+"` supplied to `"+M+"`, expected a single ReactElement."))}return null}return c(h)}function g(){function h(b,I,M,A,B){var D=b[I];if(!Um.isValidElementType(D)){var F=$(D);return new s("Invalid "+A+" `"+B+"` of type "+("`"+F+"` supplied to `"+M+"`, expected a single ReactElement type."))}return null}return c(h)}function p(h){function b(I,M,A,B,D){if(!(I[M]instanceof h)){var F=h.name||a,_=le(I[M]);return new s("Invalid "+B+" `"+D+"` of type "+("`"+_+"` supplied to `"+A+"`, expected ")+("instance of `"+F+"`."))}return null}return c(b)}function y(h){if(!Array.isArray(h))return process.env.NODE_ENV!=="production"&&(arguments.length>1?Lt("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])."):Lt("Invalid argument supplied to oneOf, expected an array.")),mo;function b(I,M,A,B,D){for(var F=I[M],_=0;_<h.length;_++)if(l(F,h[_]))return null;var N=JSON.stringify(h,function(pe,oe){var Je=se(oe);return Je==="symbol"?String(oe):oe});return new s("Invalid "+B+" `"+D+"` of value `"+String(F)+"` "+("supplied to `"+A+"`, expected one of "+N+"."))}return c(b)}function v(h){function b(I,M,A,B,D){if(typeof h!="function")return new s("Property `"+D+"` of component `"+A+"` has invalid PropType notation inside objectOf.");var F=I[M],_=$(F);if(_!=="object")return new s("Invalid "+B+" `"+D+"` of type "+("`"+_+"` supplied to `"+A+"`, expected an object."));for(var N in F)if(pi(F,N)){var L=h(F,N,A,B,D+"."+N,_t);if(L instanceof Error)return L}return null}return c(b)}function x(h){if(!Array.isArray(h))return process.env.NODE_ENV!=="production"&&Lt("Invalid argument supplied to oneOfType, expected an instance of array."),mo;for(var b=0;b<h.length;b++){var I=h[b];if(typeof I!="function")return Lt("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+E(I)+" at index "+b+"."),mo}function M(A,B,D,F,_){for(var N=[],L=0;L<h.length;L++){var pe=h[L],oe=pe(A,B,D,F,_,_t);if(oe==null)return null;oe.data&&pi(oe.data,"expectedType")&&N.push(oe.data.expectedType)}var Je=N.length>0?", expected one of type ["+N.join(", ")+"]":"";return new s("Invalid "+F+" `"+_+"` supplied to "+("`"+D+"`"+Je+"."))}return c(M)}function S(){function h(b,I,M,A,B){return P(b[I])?null:new s("Invalid "+A+" `"+B+"` supplied to "+("`"+M+"`, expected a ReactNode."))}return c(h)}function w(h,b,I,M,A){return new s((h||"React class")+": "+b+" type `"+I+"."+M+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+A+"`.")}function C(h){function b(I,M,A,B,D){var F=I[M],_=$(F);if(_!=="object")return new s("Invalid "+B+" `"+D+"` of type `"+_+"` "+("supplied to `"+A+"`, expected `object`."));for(var N in h){var L=h[N];if(typeof L!="function")return w(A,B,D,N,se(L));var pe=L(F,N,A,B,D+"."+N,_t);if(pe)return pe}return null}return c(b)}function k(h){function b(I,M,A,B,D){var F=I[M],_=$(F);if(_!=="object")return new s("Invalid "+B+" `"+D+"` of type `"+_+"` "+("supplied to `"+A+"`, expected `object`."));var N=jm({},I[M],h);for(var L in N){var pe=h[L];if(pi(h,L)&&typeof pe!="function")return w(A,B,D,L,se(pe));if(!pe)return new s("Invalid "+B+" `"+D+"` key `"+L+"` supplied to `"+A+"`.\nBad object: "+JSON.stringify(I[M],null," ")+`
2
- Valid keys: `+JSON.stringify(Object.keys(h),null," "));var oe=pe(F,L,A,B,D+"."+L,_t);if(oe)return oe}return null}return c(b)}function P(h){switch(typeof h){case"number":case"string":case"undefined":return!0;case"boolean":return!h;case"object":if(Array.isArray(h))return h.every(P);if(h===null||e(h))return!0;var b=n(h);if(b){var I=b.call(h),M;if(b!==h.entries){for(;!(M=I.next()).done;)if(!P(M.value))return!1}else for(;!(M=I.next()).done;){var A=M.value;if(A&&!P(A[1]))return!1}}else return!1;return!0;default:return!1}}function Q(h,b){return h==="symbol"?!0:b?b["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&b instanceof Symbol:!1}function $(h){var b=typeof h;return Array.isArray(h)?"array":h instanceof RegExp?"object":Q(b,h)?"symbol":b}function se(h){if(typeof h>"u"||h===null)return""+h;var b=$(h);if(b==="object"){if(h instanceof Date)return"date";if(h instanceof RegExp)return"regexp"}return b}function E(h){var b=se(h);switch(b){case"array":case"object":return"an "+b;case"boolean":case"date":case"regexp":return"a "+b;default:return b}}function le(h){return!h.constructor||!h.constructor.name?a:h.constructor.name}return i.checkPropTypes=Vc,i.resetWarningCache=Vc.resetWarningCache,i.PropTypes=i,i}});var jc=ne((G2,Uc)=>{"use strict";var qm=po();function Gc(){}function Hc(){}Hc.resetWarningCache=Gc;Uc.exports=function(){function e(o,n,a,i,l,s){if(s!==qm){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}}e.isRequired=e;function t(){return e}var r={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:Hc,resetWarningCache:Gc};return r.PropTypes=r,r}});var go=ne((H2,di)=>{process.env.NODE_ENV!=="production"?(qc=li(),Yc=!0,di.exports=Wc()(qc.isElement,Yc)):di.exports=jc()();var qc,Yc});var Jc=ne(G=>{"use strict";var mi=Symbol.for("react.transitional.element"),gi=Symbol.for("react.portal"),ho=Symbol.for("react.fragment"),yo=Symbol.for("react.strict_mode"),xo=Symbol.for("react.profiler"),vo=Symbol.for("react.consumer"),bo=Symbol.for("react.context"),Co=Symbol.for("react.forward_ref"),wo=Symbol.for("react.suspense"),So=Symbol.for("react.suspense_list"),To=Symbol.for("react.memo"),Po=Symbol.for("react.lazy"),Km=Symbol.for("react.view_transition"),Zm=Symbol.for("react.client.reference");function Se(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case mi:switch(e=e.type,e){case ho:case xo:case yo:case wo:case So:case Km:return e;default:switch(e=e&&e.$$typeof,e){case bo:case Co:case Po:case To:return e;case vo:return e;default:return t}}case gi:return t}}}G.ContextConsumer=vo;G.ContextProvider=bo;G.Element=mi;G.ForwardRef=Co;G.Fragment=ho;G.Lazy=Po;G.Memo=To;G.Portal=gi;G.Profiler=xo;G.StrictMode=yo;G.Suspense=wo;G.SuspenseList=So;G.isContextConsumer=function(e){return Se(e)===vo};G.isContextProvider=function(e){return Se(e)===bo};G.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===mi};G.isForwardRef=function(e){return Se(e)===Co};G.isFragment=function(e){return Se(e)===ho};G.isLazy=function(e){return Se(e)===Po};G.isMemo=function(e){return Se(e)===To};G.isPortal=function(e){return Se(e)===gi};G.isProfiler=function(e){return Se(e)===xo};G.isStrictMode=function(e){return Se(e)===yo};G.isSuspense=function(e){return Se(e)===wo};G.isSuspenseList=function(e){return Se(e)===So};G.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===ho||e===xo||e===yo||e===wo||e===So||typeof e=="object"&&e!==null&&(e.$$typeof===Po||e.$$typeof===To||e.$$typeof===bo||e.$$typeof===vo||e.$$typeof===Co||e.$$typeof===Zm||e.getModuleId!==void 0)};G.typeOf=Se});var Xc=ne(H=>{"use strict";process.env.NODE_ENV!=="production"&&function(){function e(p){if(typeof p=="object"&&p!==null){var y=p.$$typeof;switch(y){case t:switch(p=p.type,p){case o:case a:case n:case c:case u:case m:return p;default:switch(p=p&&p.$$typeof,p){case l:case s:case f:case d:return p;case i:return p;default:return y}}case r:return y}}}var t=Symbol.for("react.transitional.element"),r=Symbol.for("react.portal"),o=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),i=Symbol.for("react.consumer"),l=Symbol.for("react.context"),s=Symbol.for("react.forward_ref"),c=Symbol.for("react.suspense"),u=Symbol.for("react.suspense_list"),d=Symbol.for("react.memo"),f=Symbol.for("react.lazy"),m=Symbol.for("react.view_transition"),g=Symbol.for("react.client.reference");H.ContextConsumer=i,H.ContextProvider=l,H.Element=t,H.ForwardRef=s,H.Fragment=o,H.Lazy=f,H.Memo=d,H.Portal=r,H.Profiler=a,H.StrictMode=n,H.Suspense=c,H.SuspenseList=u,H.isContextConsumer=function(p){return e(p)===i},H.isContextProvider=function(p){return e(p)===l},H.isElement=function(p){return typeof p=="object"&&p!==null&&p.$$typeof===t},H.isForwardRef=function(p){return e(p)===s},H.isFragment=function(p){return e(p)===o},H.isLazy=function(p){return e(p)===f},H.isMemo=function(p){return e(p)===d},H.isPortal=function(p){return e(p)===r},H.isProfiler=function(p){return e(p)===a},H.isStrictMode=function(p){return e(p)===n},H.isSuspense=function(p){return e(p)===c},H.isSuspenseList=function(p){return e(p)===u},H.isValidElementType=function(p){return typeof p=="string"||typeof p=="function"||p===o||p===a||p===n||p===c||p===u||typeof p=="object"&&p!==null&&(p.$$typeof===f||p.$$typeof===d||p.$$typeof===l||p.$$typeof===i||p.$$typeof===s||p.$$typeof===g||p.getModuleId!==void 0)},H.typeOf=e}()});var yi=ne((X2,hi)=>{"use strict";process.env.NODE_ENV==="production"?hi.exports=Jc():hi.exports=Xc()});var Du=ne((dM,Mu)=>{"use strict";function mt(e){this._maxSize=e,this.clear()}mt.prototype.clear=function(){this._size=0,this._values=Object.create(null)};mt.prototype.get=function(e){return this._values[e]};mt.prototype.set=function(e,t){return this._size>=this._maxSize&&this.clear(),e in this._values||this._size++,this._values[e]=t};var jh=/[^.^\]^[]+|(?=\[\]|\.\.)/g,Au=/^\d+$/,qh=/^\d/,Yh=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,Kh=/^\s*(['"]?)(.*?)(\1)\s*$/,Ui=512,ku=new mt(Ui),Iu=new mt(Ui),Eu=new mt(Ui);Mu.exports={Cache:mt,split:Hi,normalizePath:Gi,setter:function(e){var t=Gi(e);return Iu.get(e)||Iu.set(e,function(o,n){for(var a=0,i=t.length,l=o;a<i-1;){var s=t[a];if(s==="__proto__"||s==="constructor"||s==="prototype")return o;l=l[t[a++]]}l[t[a]]=n})},getter:function(e,t){var r=Gi(e);return Eu.get(e)||Eu.set(e,function(n){for(var a=0,i=r.length;a<i;)if(n!=null||!t)n=n[r[a++]];else return;return n})},join:function(e){return e.reduce(function(t,r){return t+(ji(r)||Au.test(r)?"["+r+"]":(t?".":"")+r)},"")},forEach:function(e,t,r){Zh(Array.isArray(e)?e:Hi(e),t,r)}};function Gi(e){return ku.get(e)||ku.set(e,Hi(e).map(function(t){return t.replace(Kh,"$2")}))}function Hi(e){return e.match(jh)||[""]}function Zh(e,t,r){var o=e.length,n,a,i,l;for(a=0;a<o;a++)n=e[a],n&&(Xh(n)&&(n='"'+n+'"'),l=ji(n),i=!l&&/^\d+$/.test(n),t.call(r,n,l,i,a,e))}function ji(e){return typeof e=="string"&&e&&["'",'"'].indexOf(e.charAt(0))!==-1}function Qh(e){return e.match(qh)&&!e.match(Au)}function Jh(e){return Yh.test(e)}function Xh(e){return!ji(e)&&(Qh(e)||Jh(e))}});var Ou=ne((fM,Ru)=>{var ey=/[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,jo=e=>e.match(ey)||[],qo=e=>e[0].toUpperCase()+e.slice(1),qi=(e,t)=>jo(e).join(t).toLowerCase(),Fu=e=>jo(e).reduce((t,r)=>`${t}${t?r[0].toUpperCase()+r.slice(1).toLowerCase():r.toLowerCase()}`,""),ty=e=>qo(Fu(e)),ry=e=>qi(e,"_"),oy=e=>qi(e,"-"),ny=e=>qo(qi(e," ")),iy=e=>jo(e).map(qo).join(" ");Ru.exports={words:jo,upperFirst:qo,camelCase:Fu,pascalCase:ty,snakeCase:ry,kebabCase:oy,sentenceCase:ny,titleCase:iy}});var _u=ne((mM,Yi)=>{Yi.exports=function(e){return Bu(ay(e),e)};Yi.exports.array=Bu;function Bu(e,t){var r=e.length,o=new Array(r),n={},a=r,i=sy(t),l=ly(e);for(t.forEach(function(c){if(!l.has(c[0])||!l.has(c[1]))throw new Error("Unknown node. There is an unknown node in the supplied edges.")});a--;)n[a]||s(e[a],a,new Set);return o;function s(c,u,d){if(d.has(c)){var f;try{f=", node was:"+JSON.stringify(c)}catch{f=""}throw new Error("Cyclic dependency"+f)}if(!l.has(c))throw new Error("Found unknown node. Make sure to provided all involved nodes. Unknown node: "+JSON.stringify(c));if(!n[u]){n[u]=!0;var m=i.get(c)||new Set;if(m=Array.from(m),u=m.length){d.add(c);do{var g=m[--u];s(g,l.get(g),d)}while(u);d.delete(c)}o[--r]=c}}}function ay(e){for(var t=new Set,r=0,o=e.length;r<o;r++){var n=e[r];t.add(n[0]),t.add(n[1])}return Array.from(t)}function sy(e){for(var t=new Map,r=0,o=e.length;r<o;r++){var n=e[r];t.has(n[0])||t.set(n[0],new Set),t.has(n[1])||t.set(n[1],new Set),t.get(n[0]).add(n[1])}return t}function ly(e){for(var t=new Map,r=0,o=e.length;r<o;r++)t.set(e[r],r);return t}});import{Button as Rf,CircularProgress as Of}from"@mui/material";import{jsx as ic}from"react/jsx-runtime";var Bf=e=>{let{isLoading:t,children:r,...o}=e;return ic(Rf,{...o,disabled:t?!0:o.disabled,children:t?ic(Of,{color:"secondary",size:22}):r})},R=Bf;import{Stack as _f}from"@mui/material";import{jsx as Lf}from"react/jsx-runtime";function _e(e){return Lf(_f,{direction:"row",justifyContent:"flex-end",alignItems:"center",spacing:1,...e})}import{FormControl as $f,FormControlLabel as Nf,Checkbox as Vf}from"@mui/material";import{jsx as Yn}from"react/jsx-runtime";function ac(e){let{label:t,...r}=e;return Yn($f,{component:"fieldset",children:Yn(Nf,{label:t,control:Yn(Vf,{...r})})})}import{Box as sc}from"@mui/material";import{getContrast as Yf}from"polished";import{alpha as zf,createTheme as Wf,responsiveFontSizes as Gf}from"@mui/material/styles";var st="#05b5e6",Hf="#05b5e6",ie={32:"2rem",28:"1.75rem",24:"1.5",20:"1.25rem",16:"1rem",14:"0.875rem",12:"0.75rem",10:"0.625rem"},we={800:"#202024",700:"#262626",600:"#333333",500:"#808080",400:"#BBBBBA",300:"#E0E0E0",200:"#F2F2F2",100:"#FAFAFA"},Uf={cssVariables:!0,mixins:{toolbar:{height:48},menu:{width:260}},palette:{situacao:{aberto:"#FFFF00",fechado:"#FFA500",orcamento:"#800080",analise:"#0000FF",cancelado:"#FF0000",liberado:"#008000"},border:"rgba(0, 0, 0, 0.23)",text:{primary:"#262626",secondary:"#808080"},primary:{light:"#66D1E6",main:st,dark:Hf},secondary:{light:"#eceff1",main:"#13143F",dark:"#263238"},background:{default:"#FFF",paper:"#F4F4F4"},error:{main:"#F44336",dark:"#BE0D00",light:"#FF6C5F"},warning:{main:"#FFCD38",dark:"#C29000",light:"#FFED58"},success:{main:"#4CAF50",dark:"#187B1C",light:"#7DE081"},grey:{800:we[800],700:we[700],600:we[600],500:we[500],400:we[400],300:we[300],200:we[200],100:we[100]}},typography:{fontFamily:["Roboto","Lato","sans-serif","Poppins","Montserrat"].join(","),h1:{fontSize:ie[32],fontWeight:400,color:"#262626"},h2:{fontSize:ie[28],fontWeight:400,color:"#262626"},h3:{fontSize:ie[24],fontWeight:400,color:"#262626"},h4:{fontSize:ie[20],fontWeight:400,color:"#262626"},h5:{fontSize:ie[16],fontWeight:400,color:"#262626"},h6:{fontSize:ie[14],fontWeight:500,color:"#262626"},subtitle1:{fontSize:ie[14],fontWeight:400,color:"#262626"},subtitle2:{fontSize:ie[12],fontWeight:500,color:we[500]},body1:{fontSize:ie[14],fontWeight:400,color:"#262626"},body2:{fontSize:ie[12],fontWeight:400,color:"#808080"},caption:{fontSize:ie[12],fontWeight:400,color:"#808080"},overline:{fontSize:ie[10],fontWeight:400,textTransform:"uppercase",color:"#808080"}},components:{MuiTabs:{styleOverrides:{root:{minHeight:"30px"}}},MuiTab:{styleOverrides:{root:{minHeight:"30px",height:"30px",textTransform:"none",fontWeight:"400",fontSize:ie[12],"& .MuiTab-iconWrapper":{fontSize:ie[16]}}}},MuiList:{styleOverrides:{root:{paddingTop:0}}},MuiListItemButton:{styleOverrides:{root:{"&.Mui-selected":{backgroundColor:zf(st,.1),boxShadow:`inset 0 0 0 0.5px ${st}`,borderRadius:"4px","& .MuiTypography-root":{color:st,fontWeight:500},"& .MuiListItemIcon-root svg":{strokeWidth:2,color:st}},":hover":{background:"rgba(89, 195, 224, 15%)",borderRadius:"4px"}}}},MuiToolbar:{defaultProps:{sx:{minHeight:"46px"}},styleOverrides:{root:{background:"#FFFFFF"}}},MuiChip:{defaultProps:{size:"small"}},MuiContainer:{defaultProps:{maxWidth:!1,disableGutters:!0},styleOverrides:{root:{display:"flex",flexDirection:"column",flexGrow:1}}},MuiButton:{defaultProps:{size:"small",variant:"outlined"},styleOverrides:{root:{fontSize:"0.755rem",textTransform:"none",fontWeight:"bold",minWidth:"78px"},contained:{color:"rgba(255,255,255,0.85)",boxShadow:"none"},outlined:{background:"white",":disabled":{background:"none",boxShadow:"none",borderColor:"#E0E0E0"}}}},MuiCheckbox:{defaultProps:{size:"small"}},MuiFormControl:{defaultProps:{size:"small"},styleOverrides:{root:{}}},MuiInputBase:{styleOverrides:{root:{fontSize:ie[12],height:"auto",minHeight:"28px","&.MuiInputBase-sizeSmall":{"& .MuiOutlinedInput-input":{padding:"3.5px 14px"}},"&.MuiInputBase-multiline.MuiInputBase-sizeSmall":{height:"auto",padding:0,"& .MuiOutlinedInput-input":{padding:"8.5px 14px"}}}}},MuiTextField:{defaultProps:{size:"small",fullWidth:!0,InputLabelProps:{shrink:!0}},styleOverrides:{root:{"& label":{color:we[500],fontSize:"13px"},"& .MuiInputBase-root":{backgroundColor:"#fff"},"& .MuiInputBase-input[readonly]":{backgroundColor:we[200],color:we[700]}}}},MuiAutocomplete:{defaultProps:{size:"small"},styleOverrides:{inputRoot:{fontSize:"14px","& .MuiOutlinedInput-input":{padding:"3.5px 14px"}},root:{"& .MuiOutlinedInput-root.MuiInputBase-sizeSmall":{padding:"0 12px"},"& .MuiOutlinedInput-root.MuiInputBase-sizeSmall .MuiAutocomplete-input":{padding:0}}}},MuiInputLabel:{styleOverrides:{root:{fontSize:ie[14]}}},MuiSvgIcon:{defaultProps:{fontSize:"small",color:"inherit"}},MuiIconButton:{defaultProps:{size:"small"},styleOverrides:{root:{}}},MuiPopover:{styleOverrides:{paper:{borderRadius:"12px"}}},MuiMenuItem:{styleOverrides:{root:{"&.Mui-selected":{"& .MuiIcon-root":{color:st},"& .MuiTypography-root":{color:st}},":hover":{borderRadius:"6px",background:"rgba(89, 195, 224, 15%)"}}}},MuiBadge:{styleOverrides:{root:{"& .MuiBadge-anchorOriginBottomLeft":{height:"16px",top:8}},badge:{fontSize:"8pt"}}},MuiTableCell:{styleOverrides:{root:{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",padding:0,"&.selected":{backgroundColor:"#199"}},head:{backgroundColor:"#FAFAFA",border:"1px solid #D0D0D0",color:"#808080","& span":{color:"#808080"},"& div":{marginLeft:"4px"}},body:{backgroundColor:"#ffffff00",border:"1px solid #D0D0D0",borderTop:"none",borderBottom:"none","& > div":{fontSize:"9pt",paddingLeft:"6px",paddingRight:"6px",paddingTop:"2px",paddingBottom:"2px"}}}},MuiTableRow:{styleOverrides:{root:{backgroundColor:"#FFFFFF",height:"30px","&.MuiTableRow-hover":{"&:hover":{backgroundColor:"#ffffde"}}},head:{borderRadius:"4px","& div":{fontWeight:"600",fontSize:"13px",padding:"2px"}}}},MUIDataTableHeadCell:{styleOverrides:{toolButton:{height:"48px"}}},MUIDataTableBodyRow:{styleOverrides:{root:{"&:hover":{backgroundColor:"#333"},"&:nth-of-type(even)":{backgroundColor:"#F5F5F5"},"&:last-child":{borderBottom:"1px solid #D0D0D0"}}}},MuiTableHead:{styleOverrides:{root:{height:"48px"}}},MuiPaper:{styleOverrides:{root:{background:"#FFFFFF"}}},MuiDrawer:{styleOverrides:{paper:{}}},MuiDialog:{styleOverrides:{paper:{borderRadius:"6px"}}},MuiDialogContent:{styleOverrides:{root:{}}}}},jf=Wf(Uf),qf=Gf(jf),V=qf;import{Fragment as Qf,jsx as Zr,jsxs as Zf}from"react/jsx-runtime";var Kf={"primary-light":V.palette.primary.light,primary:V.palette.primary.main,"primary-dark":V.palette.primary.dark,"text-secondary":V.palette.text.secondary,"text-primary":V.palette.text.primary,"background-paper":V.palette.background.paper,background:V.palette.background.default,"error-light":V.palette.error.light,error:V.palette.error.main,"erro-drark":V.palette.error.dark,"warning-light":V.palette.warning.light,warning:V.palette.warning.main,"warning-dark":V.palette.warning.dark,"success-light":V.palette.success.light,success:V.palette.success.main,"success-dark":V.palette.success.dark,"grey-100":V.palette.grey[100],"grey-200":V.palette.grey[200],"grey-300":V.palette.grey[300],"grey-400":V.palette.grey[400],"grey-500":V.palette.grey[500],"grey-600":V.palette.grey[600],"grey-700":V.palette.grey[700],"grey-800":V.palette.grey[800]};function lc(){return Zr(Qf,{children:Object.entries(Kf).map(([e,t])=>Zr(sc,{sx:{backgroundColor:t,padding:"2rem"},children:Zf(sc,{sx:{display:"flex",justifyContent:"space-between",fontFamily:V.typography.fontFamily,color:Yf(t,"#FFF")<3.5?"#000":"#FFF"},children:[Zr("strong",{children:e}),Zr("span",{children:t})]})},e))})}import{Box as Qr,IconButton as Jr,Icon as pc,Badge as sm}from"@mui/material";import{Edit as dc,Delete as fc,GetApp as mc}from"@mui/icons-material";import{Tooltip as Jf,tooltipClasses as Xf,Box as Kn,Icon as em,Typography as tm,Divider as rm}from"@mui/material";import{styled as om}from"@mui/material/styles";import{jsx as lt,jsxs as cc}from"react/jsx-runtime";var nm=om(({className:e,...t})=>lt(Jf,{...t,classes:{popper:e}}))(({theme:e})=>({[`& .${Xf.tooltip}`]:{backgroundColor:"#f5f5f9",color:"rgba(0, 0, 0, 0.87)",maxWidth:320,minWidth:180,fontSize:e.typography.pxToRem(12),border:"1px solid #dadde9"}})),im={info:"Informa\xE7\xE3o",warning:"Aten\xE7\xE3o"},am=e=>{let{title:t,type:r}=e;return cc(Kn,{sx:{mt:.5},children:[cc(Kn,{sx:{display:"flex",flexDirection:"row",alignItems:"center",alignContent:"center"},children:[lt(em,{color:r,fontSize:"small",children:r})," ",lt(tm,{variant:"subtitle2",sx:{ml:.5},children:im[r]})]}),lt(rm,{sx:{mt:.5}}),lt(Kn,{sx:{mt:1},children:t})]})},uc=e=>{let{type:t,children:r,title:o,...n}=e;return lt(nm,{arrow:!0,title:lt(am,{title:o||"",type:t}),enterDelay:300,...n,children:r})};uc.defaultProps={type:"info"};var Rt=uc;import{jsx as ae,jsxs as fr}from"react/jsx-runtime";var qP=()=>({style:{width:"80px",textAlign:"center"}}),YP=()=>({style:{width:"128px",textAlign:"right"}});function Zn(e){let{onClick:t,value:r,extraOptions:o,displayUpdateButton:n,displayDeleteButton:a,displayTransporterButton:i,disableTooltip:l,disabled:s,disabledUpdateButton:c,disabledDeleteButton:u,disabledTransporterButton:d}=e;return fr(Qr,{children:[o&&o.map(({id:f,icon:m,iconButtonProps:g,tooltip:p,visible:y,disabled:v,badge:x})=>y===null||!!y&&ae(sm,{color:"primary",badgeContent:x,children:fr(Jr,{onClick:S=>t(f,r,S),size:"small",disabled:v,...g,children:[p&&ae(Rt,{type:p.type,title:p.content,children:ae(pc,{fontSize:"small",children:m})}),!p&&ae(pc,{fontSize:"small",children:m})]},f)})),i&&fr(Jr,{size:"small",onClick:f=>t("transport",r,f),color:"primary",disabled:s||d,children:[l&&ae(mc,{fontSize:"small"}),!l&&ae(Rt,{type:"warning",title:ae(Qr,{children:"Clique para transportar este registro."}),children:ae(mc,{fontSize:"small"})})]}),n&&fr(Jr,{size:"small",color:"primary",onClick:f=>t("edit",r,f),disabled:s||c,children:[l&&ae(dc,{fontSize:"small"}),!l&&ae(Rt,{type:"info",title:ae(Qr,{children:"Clique para editar este registro."}),children:ae(dc,{fontSize:"small"})})]}),a&&fr(Jr,{size:"small",onClick:f=>t("delete",r,f),color:"primary",disabled:s||u,children:[l&&ae(fc,{fontSize:"small"}),!l&&ae(Rt,{type:"warning",title:ae(Qr,{children:"Clique para excluir este registro."}),children:ae(fc,{fontSize:"small"})})]})]})}Zn.defaultProps={displayUpdateButton:!0,displayDeleteButton:!0,displayTransporterButton:!1,disableTooltip:!0};import{Box as Qn,Chip as gc,IconButton as lm}from"@mui/material";import{RestartAlt as cm}from"@mui/icons-material";import{useFilterData as um,useFilterApi as pm}from"@data-c/providers";import{useCallback as dm,useMemo as fm}from"react";import{jsx as Ot,jsxs as mm}from"react/jsx-runtime";function Xr(e){let{renderLabel:t,disableds:r}=e,{deleteFilterValue:o,deleteAllFilterValues:n}=pm(),{filterValues:a,appliedValues:i}=um(),l=fm(()=>{if(Object.keys(i||{}).length>0){let u=!1,d=Object.keys(i||{});for(let f=0;f<d.length;f++){let m=i[d[f]];if(Array.isArray(m)&&m.length>0){u=!0;break}else if(!Array.isArray(m)&&m){u=!0;break}}return u}return!1},[i]),s=dm(c=>t?t(a[c].label,i[c]):`${a[c].label} - ${i&&i[c]}`,[t,a,i]);return mm(Qn,{sx:{display:"flex",flexDirection:"row",justifyContent:"space-between"},children:[Ot(Qn,{sx:{display:"flex",flexWrap:"wrap",alignItems:"center",justifyContent:"flex-end",gap:1},children:l&&Object.keys(i||{}).map(c=>{let u=Array.isArray(r)&&r.includes(c),d;if(u||(d=()=>{o&&o(c)}),Array.isArray(i[c])&&i[c].length>0)return Ot(gc,{size:"small",label:s(c),onDelete:d,variant:"outlined"},c);if(!Array.isArray(i[c])&&i[c])return Ot(gc,{size:"small",label:s(c),onDelete:d,variant:"outlined"},c)})}),l&&Ot(Qn,{sx:{mr:.5,ml:.5,display:"flex",alignContent:"center",alignItems:"center"},children:Ot(lm,{onClick:()=>{n&&n()},children:Ot(cm,{fontSize:"small",color:"error"})})})]})}import{useEffect as bm}from"react";import{useFilterApi as ti,useFilterData as Cm}from"@data-c/providers";import{RestartAlt as wm,Search as yc}from"@mui/icons-material";import{Box as Sm,Button as ei,Stack as Tm}from"@mui/material";import{Box as Jn,Stack as hc,Drawer as gm,Typography as hm,IconButton as ym,Toolbar as xm}from"@mui/material";import{Cancel as vm}from"@mui/icons-material";import{jsx as ct,jsxs as Xn}from"react/jsx-runtime";function eo(e){let{drawerTitle:t,actions:r,onClose:o,children:n,...a}=e;return ct(gm,{PaperProps:{style:{borderRadius:"12px 0 0 12px"}},onClose:o,...a,children:Xn(hc,{sx:{width:"360px",height:"100%",justifyContent:"space-between",backgroundColor:i=>i.palette.background.paper},children:[Xn(hc,{children:[ct(xm,{}),Xn(Jn,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",alignContent:"center",height:"48px",borderBottom:i=>`solid 1px ${i.palette.grey[300]}`},children:[ct(hm,{component:"h1",variant:"h5",sx:{pl:i=>i.spacing(2)},children:t}),o&&ct(ym,{onClick:o,children:ct(vm,{color:"error"})})]}),ct(Jn,{sx:{padding:i=>i.spacing(2)},children:n})]}),r&&ct(Jn,{sx:{pt:i=>i.spacing(1),pb:i=>i.spacing(1),pl:i=>i.spacing(2),pr:i=>i.spacing(2),borderTop:i=>`solid 1px ${i.palette.grey[300]}`},children:r})]})})}eo.defaultProps={anchor:"right"};import{Fragment as Im,jsx as et,jsxs as mr}from"react/jsx-runtime";var Pm=()=>{let{applyFilterValues:e,closeFilter:t,deleteAllFilterValues:r}=ti();function o(){t()}function n(){e(),t()}function a(){r&&(r(),t())}return mr(Tm,{sx:{flexDirection:"row",justifyContent:"flex-end","& > button:first-child":{mr:1}},children:[mr(ei,{fullWidth:!0,onClick:a,color:"error",children:[et(wm,{})," Redefinir Padr\xE3o"]}),mr(ei,{fullWidth:!0,variant:"contained",onClick:n,children:[et(yc,{})," Aplicar"]})]})},km=e=>{let{title:t,children:r,onApplyFilters:o,drawerProps:n}=e,{isOpen:a,appliedValues:i}=Cm(),{closeFilter:l}=ti();return bm(()=>{o&&o(i)},[i]),et(eo,{...n,drawerTitle:t,open:a,children:r,onClose:()=>l(),actions:et(Pm,{})})};function ri(e){let{triggerButtonLabel:t,triggerButtonProps:r,triggerButton:o,title:n,children:a,onApplyFilters:i,renderLabel:l,disableds:s,disableFilterControl:c,drawerProps:u}=e,{openFilter:d}=ti(),f=o==="none"?null:o||et(ei,{variant:"contained",onClick:()=>{d()},...r,children:t||"Adicionar"});return mr(Im,{children:[c&&f,!c&&mr(Sm,{sx:{display:"flex",direction:"row",justifyContent:"flex-end",alignItems:"center",alignContent:"center"},children:[et(Xr,{renderLabel:l,disableds:s}),f]}),et(km,{...u,onApplyFilters:i,title:n||"",children:a})]})}ri.defaultProps={triggerButtonLabel:"Aplicar",triggerButtonProps:{variant:"contained",startIcon:et(yc,{})},title:"Aplicar"};import{Circle as Em}from"@mui/icons-material";import{jsx as Am}from"react/jsx-runtime";function xc(e){let{isFlagged:t,type:r}=e;return t?Am(Em,{color:r,sx:{fontSize:"10pt"}}):null}import{Box as gu,Divider as gh,styled as hh,Typography as yh}from"@mui/material";function Bt(e,...t){let r=new URL(`https://mui.com/production-error/?code=${e}`);return t.forEach(o=>r.searchParams.append("args[]",o)),`Minified MUI error #${e}; visit ${r} for the full message.`}import Ym from"@emotion/styled";function vc(e){for(var t=0,r,o=0,n=e.length;n>=4;++o,n-=4)r=e.charCodeAt(o)&255|(e.charCodeAt(++o)&255)<<8|(e.charCodeAt(++o)&255)<<16|(e.charCodeAt(++o)&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(n){case 3:t^=(e.charCodeAt(o+2)&255)<<16;case 2:t^=(e.charCodeAt(o+1)&255)<<8;case 1:t^=e.charCodeAt(o)&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 bc={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 Cc(e){var t=Object.create(null);return function(r){return t[r]===void 0&&(t[r]=e(r)),t[r]}}var Mm=!1,Dm=/[A-Z]|^ms/g,Fm=/_EMO_([^_]+?)_([^]*?)_EMO_/g,Pc=function(t){return t.charCodeAt(1)===45},wc=function(t){return t!=null&&typeof t!="boolean"},oi=Cc(function(e){return Pc(e)?e:e.replace(Dm,"-$&").toLowerCase()}),Sc=function(t,r){switch(t){case"animation":case"animationName":if(typeof r=="string")return r.replace(Fm,function(o,n,a){return Le={name:n,styles:a,next:Le},n})}return bc[t]!==1&&!Pc(t)&&typeof r=="number"&&r!==0?r+"px":r},Rm="Component selectors can only be used in conjunction with @emotion/babel-plugin, the swc Emotion plugin, or another Emotion-aware compiler transform.";function gr(e,t,r){if(r==null)return"";var o=r;if(o.__emotion_styles!==void 0)return o;switch(typeof r){case"boolean":return"";case"object":{var n=r;if(n.anim===1)return Le={name:n.name,styles:n.styles,next:Le},n.name;var a=r;if(a.styles!==void 0){var i=a.next;if(i!==void 0)for(;i!==void 0;)Le={name:i.name,styles:i.styles,next:Le},i=i.next;var l=a.styles+";";return l}return Om(e,t,r)}case"function":{if(e!==void 0){var s=Le,c=r(e);return Le=s,gr(e,t,c)}break}}var u=r;if(t==null)return u;var d=t[u];return d!==void 0?d:u}function Om(e,t,r){var o="";if(Array.isArray(r))for(var n=0;n<r.length;n++)o+=gr(e,t,r[n])+";";else for(var a in r){var i=r[a];if(typeof i!="object"){var l=i;t!=null&&t[l]!==void 0?o+=a+"{"+t[l]+"}":wc(l)&&(o+=oi(a)+":"+Sc(a,l)+";")}else{if(a==="NO_COMPONENT_SELECTOR"&&Mm)throw new Error(Rm);if(Array.isArray(i)&&typeof i[0]=="string"&&(t==null||t[i[0]]===void 0))for(var s=0;s<i.length;s++)wc(i[s])&&(o+=oi(a)+":"+Sc(a,i[s])+";");else{var c=gr(e,t,i);switch(a){case"animation":case"animationName":{o+=oi(a)+":"+c+";";break}default:o+=a+"{"+c+"}"}}}}return o}var Tc=/label:\s*([^\s;{]+)\s*(;|$)/g,Le;function kc(e,t,r){if(e.length===1&&typeof e[0]=="object"&&e[0]!==null&&e[0].styles!==void 0)return e[0];var o=!0,n="";Le=void 0;var a=e[0];if(a==null||a.raw===void 0)o=!1,n+=gr(r,t,a);else{var i=a;n+=i[0]}for(var l=1;l<e.length;l++)if(n+=gr(r,t,e[l]),o){var s=a;n+=s[l]}Tc.lastIndex=0;for(var c="",u;(u=Tc.exec(n))!==null;)c+="-"+u[1];var d=vc(n)+c;return{name:d,styles:n,next:Le}}import{ThemeContext as Qc,keyframes as K2,css as Z2}from"@emotion/react";function fi(e,t){let r=Ym(e,t);return process.env.NODE_ENV!=="production"?(...o)=>{let n=typeof e=="string"?`"${e}"`:"component";return o.length===0?console.error([`MUI: Seems like you called \`styled(${n})()\` without a \`style\` argument.`,'You must provide a `styles` argument: `styled("div")(styleYouForgotToPass)`.'].join(`
3
- `)):o.some(a=>a===void 0)&&console.error(`MUI: the styled(${n})(...args) API requires all its args to be defined.`),r(...o)}:r}function Zc(e,t){Array.isArray(e.__emotion_styles)&&(e.__emotion_styles=t(e.__emotion_styles))}var Kc=[];function We(e){return Kc[0]=e,kc(Kc)}var vi=Xe(yi(),1);import*as xi from"react";function $e(e){if(typeof e!="object"||e===null)return!1;let t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function eu(e){if(xi.isValidElement(e)||(0,vi.isValidElementType)(e)||!$e(e))return e;let t={};return Object.keys(e).forEach(r=>{t[r]=eu(e[r])}),t}function Te(e,t,r={clone:!0}){let o=r.clone?{...e}:e;return $e(e)&&$e(t)&&Object.keys(t).forEach(n=>{xi.isValidElement(t[n])||(0,vi.isValidElementType)(t[n])?o[n]=t[n]:$e(t[n])&&Object.prototype.hasOwnProperty.call(e,n)&&$e(e[n])?o[n]=Te(e[n],t[n],r):r.clone?o[n]=$e(t[n])?eu(t[n]):t[n]:o[n]=t[n]}),o}var Qm=e=>{let t=Object.keys(e).map(r=>({key:r,val:e[r]}))||[];return t.sort((r,o)=>r.val-o.val),t.reduce((r,o)=>({...r,[o.key]:o.val}),{})};function bi(e){let{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:r="px",step:o=5,...n}=e,a=Qm(t),i=Object.keys(a);function l(f){return`@media (min-width:${typeof t[f]=="number"?t[f]:f}${r})`}function s(f){return`@media (max-width:${(typeof t[f]=="number"?t[f]:f)-o/100}${r})`}function c(f,m){let g=i.indexOf(m);return`@media (min-width:${typeof t[f]=="number"?t[f]:f}${r}) and (max-width:${(g!==-1&&typeof t[i[g]]=="number"?t[i[g]]:m)-o/100}${r})`}function u(f){return i.indexOf(f)+1<i.length?c(f,i[i.indexOf(f)+1]):l(f)}function d(f){let m=i.indexOf(f);return m===0?l(i[1]):m===i.length-1?s(i[m]):c(f,i[i.indexOf(f)+1]).replace("@media","@media not all and")}return{keys:i,values:a,up:l,down:s,between:c,only:u,not:d,unit:r,...n}}function ko(e,t){if(!e.containerQueries)return t;let r=Object.keys(t).filter(o=>o.startsWith("@container")).sort((o,n)=>{let a=/min-width:\s*([0-9.]+)/;return+(o.match(a)?.[1]||0)-+(n.match(a)?.[1]||0)});return r.length?r.reduce((o,n)=>{let a=t[n];return delete o[n],o[n]=a,o},{...t}):t}function Ci(e,t){return t==="@"||t.startsWith("@")&&(e.some(r=>t.startsWith(`@${r}`))||!!t.match(/^@\d/))}function wi(e,t){let 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>\`.
4
- For example, \`@sm\` or \`@600\` or \`@40rem/sidebar\`.`:Bt(18,`(${t})`));return null}let[,o,n]=r,a=Number.isNaN(+o)?o||0:+o;return e.containerQueries(n).up(a)}function Io(e){let t=(a,i)=>a.replace("@media",i?`@container ${i}`:"@container");function r(a,i){a.up=(...l)=>t(e.breakpoints.up(...l),i),a.down=(...l)=>t(e.breakpoints.down(...l),i),a.between=(...l)=>t(e.breakpoints.between(...l),i),a.only=(...l)=>t(e.breakpoints.only(...l),i),a.not=(...l)=>{let s=t(e.breakpoints.not(...l),i);return s.includes("not all and")?s.replace("not all and ","").replace("min-width:","width<").replace("max-width:","width>").replace("and","or"):s}}let o={},n=a=>(r(o,a),o);return r(n),{...e,containerQueries:n}}var Jm={borderRadius:4},tu=Jm;var $t=Xe(go(),1),Xm=process.env.NODE_ENV!=="production"?$t.default.oneOfType([$t.default.number,$t.default.string,$t.default.object,$t.default.array]):{},ye=Xm;function eg(e,t){return t?Te(e,t,{clone:!1}):e}var Ge=eg;var hr={xs:0,sm:600,md:900,lg:1200,xl:1536},ru={keys:["xs","sm","md","lg","xl"],up:e=>`@media (min-width:${hr[e]}px)`},tg={containerQueries:e=>({up:t=>{let r=typeof t=="number"?t:hr[t]||t;return typeof r=="number"&&(r=`${r}px`),e?`@container ${e} (min-width:${r})`:`@container (min-width:${r})`}})};function ee(e,t,r){let o=e.theme||{};if(Array.isArray(t)){let a=o.breakpoints||ru;return t.reduce((i,l,s)=>(i[a.up(a.keys[s])]=r(t[s]),i),{})}if(typeof t=="object"){let a=o.breakpoints||ru;return Object.keys(t).reduce((i,l)=>{if(Ci(a.keys,l)){let s=wi(o.containerQueries?o:tg,l);s&&(i[s]=r(t[l],l))}else if(Object.keys(a.values||hr).includes(l)){let s=a.up(l);i[s]=r(t[l],l)}else{let s=l;i[s]=t[s]}return i},{})}return r(t)}function Si(e={}){return e.keys?.reduce((r,o)=>{let n=e.up(o);return r[n]={},r},{})||{}}function Eo(e,t){return e.reduce((r,o)=>{let n=r[o];return(!n||Object.keys(n).length===0)&&delete r[o],r},t)}function ou(e,...t){let r=Si(e),o=[r,...t].reduce((n,a)=>Te(n,a),{});return Eo(Object.keys(r),o)}function rg(e,t){if(typeof e!="object")return{};let r={},o=Object.keys(t);return Array.isArray(e)?o.forEach((n,a)=>{a<e.length&&(r[n]=!0)}):o.forEach(n=>{e[n]!=null&&(r[n]=!0)}),r}function Ao({values:e,breakpoints:t,base:r}){let o=r||rg(e,t),n=Object.keys(o);if(n.length===0)return e;let a;return n.reduce((i,l,s)=>(Array.isArray(e)?(i[l]=e[s]!=null?e[s]:e[a],a=s):typeof e=="object"?(i[l]=e[l]!=null?e[l]:e[a],a=l):i[l]=e,i),{})}function tt(e){if(typeof e!="string")throw new Error(process.env.NODE_ENV!=="production"?"MUI: `capitalize(string)` expects a string argument.":Bt(7));return e.charAt(0).toUpperCase()+e.slice(1)}function Nt(e,t,r=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&r){let o=`vars.${t}`.split(".").reduce((n,a)=>n&&n[a]?n[a]:null,e);if(o!=null)return o}return t.split(".").reduce((o,n)=>o&&o[n]!=null?o[n]:null,e)}function yr(e,t,r,o=r){let n;return typeof e=="function"?n=e(r):Array.isArray(e)?n=e[r]||o:n=Nt(e,r)||o,t&&(n=t(n,o,e)),n}function og(e){let{prop:t,cssProperty:r=e.prop,themeKey:o,transform:n}=e,a=i=>{if(i[t]==null)return null;let l=i[t],s=i.theme,c=Nt(s,o)||{};return ee(i,l,d=>{let f=yr(c,n,d);return d===f&&typeof d=="string"&&(f=yr(c,n,`${t}${d==="default"?"":tt(d)}`,d)),r===!1?f:{[r]:f}})};return a.propTypes=process.env.NODE_ENV!=="production"?{[t]:ye}:{},a.filterProps=[t],a}var U=og;function Mo(e){let t={};return r=>(t[r]===void 0&&(t[r]=e(r)),t[r])}var ng={m:"margin",p:"padding"},ig={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},nu={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},ag=Mo(e=>{if(e.length>2)if(nu[e])e=nu[e];else return[e];let[t,r]=e.split(""),o=ng[t],n=ig[r]||"";return Array.isArray(n)?n.map(a=>o+a):[o+n]}),Do=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],Fo=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],Ti=[...Do,...Fo];function ut(e,t,r,o){let n=Nt(e,t,!0)??r;return typeof n=="number"||typeof n=="string"?a=>typeof a=="string"?a:(process.env.NODE_ENV!=="production"&&typeof a!="number"&&console.error(`MUI: Expected ${o} argument to be a number or a string, got ${a}.`),typeof n=="string"?n.startsWith("var(")&&a===0?0:n.startsWith("var(")&&a===1?n:`calc(${a} * ${n})`:n*a):Array.isArray(n)?a=>{if(typeof a=="string")return a;let i=Math.abs(a);process.env.NODE_ENV!=="production"&&(Number.isInteger(i)?i>n.length-1&&console.error([`MUI: The value provided (${i}) overflows.`,`The supported values are: ${JSON.stringify(n)}.`,`${i} > ${n.length-1}, you need to add the missing values.`].join(`
5
- `)):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(`
6
- `)));let l=n[i];return a>=0?l:typeof l=="number"?-l:typeof l=="string"&&l.startsWith("var(")?`calc(-1 * ${l})`:`-${l}`}:typeof n=="function"?n:(process.env.NODE_ENV!=="production"&&console.error([`MUI: The \`theme.${t}\` value (${n}) is invalid.`,"It should be a number, an array or a function."].join(`
7
- `)),()=>{})}function xr(e){return ut(e,"spacing",8,"spacing")}function Ne(e,t){return typeof t=="string"||t==null?t:e(t)}function sg(e,t){return r=>e.reduce((o,n)=>(o[n]=Ne(t,r),o),{})}function lg(e,t,r,o){if(!t.includes(r))return null;let n=ag(r),a=sg(n,o),i=e[r];return ee(e,i,a)}function Pi(e,t){let r=xr(e.theme);return Object.keys(e).map(o=>lg(e,t,o,r)).reduce(Ge,{})}function K(e){return Pi(e,Do)}K.propTypes=process.env.NODE_ENV!=="production"?Do.reduce((e,t)=>(e[t]=ye,e),{}):{};K.filterProps=Do;function Z(e){return Pi(e,Fo)}Z.propTypes=process.env.NODE_ENV!=="production"?Fo.reduce((e,t)=>(e[t]=ye,e),{}):{};Z.filterProps=Fo;function iu(e){return Pi(e,Ti)}iu.propTypes=process.env.NODE_ENV!=="production"?Ti.reduce((e,t)=>(e[t]=ye,e),{}):{};iu.filterProps=Ti;function ki(e=8,t=xr({spacing:e})){if(e.mui)return e;let r=(...o)=>(process.env.NODE_ENV!=="production"&&(o.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${o.length}`)),(o.length===0?[1]:o).map(a=>{let i=t(a);return typeof i=="number"?`${i}px`:i}).join(" "));return r.mui=!0,r}function cg(...e){let t=e.reduce((o,n)=>(n.filterProps.forEach(a=>{o[a]=n}),o),{}),r=o=>Object.keys(o).reduce((n,a)=>t[a]?Ge(n,t[a](o)):n,{});return r.propTypes=process.env.NODE_ENV!=="production"?e.reduce((o,n)=>Object.assign(o,n.propTypes),{}):{},r.filterProps=e.reduce((o,n)=>o.concat(n.filterProps),[]),r}var He=cg;function xe(e){return typeof e!="number"?e:`${e}px solid`}function Pe(e,t){return U({prop:e,themeKey:"borders",transform:t})}var ug=Pe("border",xe),pg=Pe("borderTop",xe),dg=Pe("borderRight",xe),fg=Pe("borderBottom",xe),mg=Pe("borderLeft",xe),gg=Pe("borderColor"),hg=Pe("borderTopColor"),yg=Pe("borderRightColor"),xg=Pe("borderBottomColor"),vg=Pe("borderLeftColor"),bg=Pe("outline",xe),Cg=Pe("outlineColor"),vr=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){let t=ut(e.theme,"shape.borderRadius",4,"borderRadius"),r=o=>({borderRadius:Ne(t,o)});return ee(e,e.borderRadius,r)}return null};vr.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:ye}:{};vr.filterProps=["borderRadius"];var Jk=He(ug,pg,dg,fg,mg,gg,hg,yg,xg,vg,vr,bg,Cg);var br=e=>{if(e.gap!==void 0&&e.gap!==null){let t=ut(e.theme,"spacing",8,"gap"),r=o=>({gap:Ne(t,o)});return ee(e,e.gap,r)}return null};br.propTypes=process.env.NODE_ENV!=="production"?{gap:ye}:{};br.filterProps=["gap"];var Cr=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){let t=ut(e.theme,"spacing",8,"columnGap"),r=o=>({columnGap:Ne(t,o)});return ee(e,e.columnGap,r)}return null};Cr.propTypes=process.env.NODE_ENV!=="production"?{columnGap:ye}:{};Cr.filterProps=["columnGap"];var wr=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){let t=ut(e.theme,"spacing",8,"rowGap"),r=o=>({rowGap:Ne(t,o)});return ee(e,e.rowGap,r)}return null};wr.propTypes=process.env.NODE_ENV!=="production"?{rowGap:ye}:{};wr.filterProps=["rowGap"];var wg=U({prop:"gridColumn"}),Sg=U({prop:"gridRow"}),Tg=U({prop:"gridAutoFlow"}),Pg=U({prop:"gridAutoColumns"}),kg=U({prop:"gridAutoRows"}),Ig=U({prop:"gridTemplateColumns"}),Eg=U({prop:"gridTemplateRows"}),Ag=U({prop:"gridTemplateAreas"}),Mg=U({prop:"gridArea"}),iI=He(br,Cr,wr,wg,Sg,Tg,Pg,kg,Ig,Eg,Ag,Mg);function pt(e,t){return t==="grey"?t:e}var Dg=U({prop:"color",themeKey:"palette",transform:pt}),Fg=U({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:pt}),Rg=U({prop:"backgroundColor",themeKey:"palette",transform:pt}),cI=He(Dg,Fg,Rg);function de(e){return e<=1&&e!==0?`${e*100}%`:e}var Og=U({prop:"width",transform:de}),Ro=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){let t=r=>{let o=e.theme?.breakpoints?.values?.[r]||hr[r];return o?e.theme?.breakpoints?.unit!=="px"?{maxWidth:`${o}${e.theme.breakpoints.unit}`}:{maxWidth:o}:{maxWidth:de(r)}};return ee(e,e.maxWidth,t)}return null};Ro.filterProps=["maxWidth"];var Bg=U({prop:"minWidth",transform:de}),_g=U({prop:"height",transform:de}),Lg=U({prop:"maxHeight",transform:de}),$g=U({prop:"minHeight",transform:de}),mI=U({prop:"size",cssProperty:"width",transform:de}),gI=U({prop:"size",cssProperty:"height",transform:de}),Ng=U({prop:"boxSizing"}),hI=He(Og,Ro,Bg,_g,Lg,$g,Ng);var Vg={border:{themeKey:"borders",transform:xe},borderTop:{themeKey:"borders",transform:xe},borderRight:{themeKey:"borders",transform:xe},borderBottom:{themeKey:"borders",transform:xe},borderLeft:{themeKey:"borders",transform:xe},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:xe},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:vr},color:{themeKey:"palette",transform:pt},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:pt},backgroundColor:{themeKey:"palette",transform:pt},p:{style:Z},pt:{style:Z},pr:{style:Z},pb:{style:Z},pl:{style:Z},px:{style:Z},py:{style:Z},padding:{style:Z},paddingTop:{style:Z},paddingRight:{style:Z},paddingBottom:{style:Z},paddingLeft:{style:Z},paddingX:{style:Z},paddingY:{style:Z},paddingInline:{style:Z},paddingInlineStart:{style:Z},paddingInlineEnd:{style:Z},paddingBlock:{style:Z},paddingBlockStart:{style:Z},paddingBlockEnd:{style:Z},m:{style:K},mt:{style:K},mr:{style:K},mb:{style:K},ml:{style:K},mx:{style:K},my:{style:K},margin:{style:K},marginTop:{style:K},marginRight:{style:K},marginBottom:{style:K},marginLeft:{style:K},marginX:{style:K},marginY:{style:K},marginInline:{style:K},marginInlineStart:{style:K},marginInlineEnd:{style:K},marginBlock:{style:K},marginBlockStart:{style:K},marginBlockEnd:{style:K},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:br},rowGap:{style:wr},columnGap:{style:Cr},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:de},maxWidth:{style:Ro},minWidth:{transform:de},height:{transform:de},maxHeight:{transform:de},minHeight:{transform:de},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"}},Vt=Vg;function zg(...e){let t=e.reduce((o,n)=>o.concat(Object.keys(n)),[]),r=new Set(t);return e.every(o=>r.size===Object.keys(o).length)}function Wg(e,t){return typeof e=="function"?e(t):e}function Gg(){function e(r,o,n,a){let i={[r]:o,theme:n},l=a[r];if(!l)return{[r]:o};let{cssProperty:s=r,themeKey:c,transform:u,style:d}=l;if(o==null)return null;if(c==="typography"&&o==="inherit")return{[r]:o};let f=Nt(n,c)||{};return d?d(i):ee(i,o,g=>{let p=yr(f,u,g);return g===p&&typeof g=="string"&&(p=yr(f,u,`${r}${g==="default"?"":tt(g)}`,g)),s===!1?p:{[s]:p}})}function t(r){let{sx:o,theme:n={},nested:a}=r||{};if(!o)return null;let i=n.unstable_sxConfig??Vt;function l(s){let c=s;if(typeof s=="function")c=s(n);else if(typeof s!="object")return s;if(!c)return null;let u=Si(n.breakpoints),d=Object.keys(u),f=u;return Object.keys(c).forEach(m=>{let g=Wg(c[m],n);if(g!=null)if(typeof g=="object")if(i[m])f=Ge(f,e(m,g,n,i));else{let p=ee({theme:n},g,y=>({[m]:y}));zg(p,g)?f[m]=t({sx:g,theme:n,nested:!0}):f=Ge(f,p)}else f=Ge(f,e(m,g,n,i))}),!a&&n.modularCssLayers?{"@layer sx":ko(n,Eo(d,f))}:ko(n,Eo(d,f))}return Array.isArray(o)?o.map(l):l(o)}return t}var au=Gg();au.filterProps=["sx"];var zt=au;function Ii(e,t){let r=this;if(r.vars){if(!r.colorSchemes?.[e]||typeof r.getColorSchemeSelector!="function")return{};let o=r.getColorSchemeSelector(e);return o==="&"?t:((o.includes("data-")||o.includes("."))&&(o=`*:where(${o.replace(/\s*&$/,"")}) &`),{[o]:t})}return r.palette.mode===e?t:{}}function Hg(e={},...t){let{breakpoints:r={},palette:o={},spacing:n,shape:a={},...i}=e,l=bi(r),s=ki(n),c=Te({breakpoints:l,direction:"ltr",components:{},palette:{mode:"light",...o},spacing:s,shape:{...tu,...a}},i);return c=Io(c),c.applyStyles=Ii,c=t.reduce((u,d)=>Te(u,d),c),c.unstable_sxConfig={...Vt,...i?.unstable_sxConfig},c.unstable_sx=function(d){return zt({sx:d,theme:this})},c}var dt=Hg;import*as su from"react";function Ug(e){return Object.keys(e).length===0}function jg(e=null){let t=su.useContext(Qc);return!t||Ug(t)?e:t}var Ei=jg;var qg=dt();function Yg(e=qg){return Ei(e)}var Ai=Yg;var Kg=e=>{let t={systemProps:{},otherProps:{}},r=e?.theme?.unstable_sxConfig??Vt;return Object.keys(e).forEach(o=>{r[o]?t.systemProps[o]=e[o]:t.otherProps[o]=e[o]}),t};function Oo(e){let{sx:t,...r}=e,{systemProps:o,otherProps:n}=Kg(r),a;return Array.isArray(t)?a=[o,...t]:typeof t=="function"?a=(...i)=>{let l=t(...i);return $e(l)?{...o,...l}:o}:a={...o,...t},{...n,sx:a}}var lu=e=>e,Zg=()=>{let e=lu;return{configure(t){e=t},generate(t){return e(t)},reset(){e=lu}}},Qg=Zg(),Mi=Qg;function cu(e){var t,r,o="";if(typeof e=="string"||typeof e=="number")o+=e;else if(typeof e=="object")if(Array.isArray(e)){var n=e.length;for(t=0;t<n;t++)e[t]&&(r=cu(e[t]))&&(o&&(o+=" "),o+=r)}else for(r in e)e[r]&&(o&&(o+=" "),o+=r);return o}function Jg(){for(var e,t,r=0,o="",n=arguments.length;r<n;r++)(e=arguments[r])&&(t=cu(e))&&(o&&(o+=" "),o+=t);return o}var Bo=Jg;var Xg={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 _o(e,t,r="Mui"){let o=Xg[t];return o?`${r}-${o}`:`${Mi.generate(e)}-${t}`}var Lo=Xe(yi(),1);function pu(e,t=""){return e.displayName||e.name||t}function uu(e,t,r){let o=pu(t);return e.displayName||(o!==""?`${r}(${o})`:r)}function $o(e){if(e!=null){if(typeof e=="string")return e;if(typeof e=="function")return pu(e,"Component");if(typeof e=="object")switch(e.$$typeof){case Lo.ForwardRef:return uu(e,e.render,"ForwardRef");case Lo.Memo:return uu(e,e.type,"memo");default:return}}}function Di(e){let{variants:t,...r}=e,o={variants:t,style:We(r),isProcessed:!0};return o.style===r||t&&t.forEach(n=>{typeof n.style!="function"&&(n.style=We(n.style))}),o}var eh=dt();function Fi(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}function ft(e,t){return t&&e&&typeof e=="object"&&e.styles&&!e.styles.startsWith("@layer")&&(e.styles=`@layer ${t}{${String(e.styles)}}`),e}function th(e){return e?(t,r)=>r[e]:null}function rh(e,t,r){e.theme=ih(e.theme)?r:e.theme[t]||e.theme}function No(e,t,r){let o=typeof t=="function"?t(e):t;if(Array.isArray(o))return o.flatMap(n=>No(e,n,r));if(Array.isArray(o?.variants)){let n;if(o.isProcessed)n=r?ft(o.style,r):o.style;else{let{variants:a,...i}=o;n=r?ft(We(i),r):i}return du(e,o.variants,[n],r)}return o?.isProcessed?r?ft(We(o.style),r):o.style:r?ft(We(o),r):o}function du(e,t,r=[],o=void 0){let n;e:for(let a=0;a<t.length;a+=1){let i=t[a];if(typeof i.props=="function"){if(n??(n={...e,...e.ownerState,ownerState:e.ownerState}),!i.props(n))continue}else for(let l in i.props)if(e[l]!==i.props[l]&&e.ownerState?.[l]!==i.props[l])continue e;typeof i.style=="function"?(n??(n={...e,...e.ownerState,ownerState:e.ownerState}),r.push(o?ft(We(i.style(n)),o):i.style(n))):r.push(o?ft(We(i.style),o):i.style)}return r}function Vo(e={}){let{themeId:t,defaultTheme:r=eh,rootShouldForwardProp:o=Fi,slotShouldForwardProp:n=Fi}=e;function a(l){rh(l,t,r)}return(l,s={})=>{Zc(l,k=>k.filter(P=>P!==zt));let{name:c,slot:u,skipVariantsResolver:d,skipSx:f,overridesResolver:m=th(fu(u)),...g}=s,p=c&&c.startsWith("Mui")||u?"components":"custom",y=d!==void 0?d:u&&u!=="Root"&&u!=="root"||!1,v=f||!1,x=Fi;u==="Root"||u==="root"?x=o:u?x=n:ah(l)&&(x=void 0);let S=fi(l,{shouldForwardProp:x,label:nh(c,u),...g}),w=k=>{if(k.__emotion_real===k)return k;if(typeof k=="function")return function(Q){return No(Q,k,Q.theme.modularCssLayers?p:void 0)};if($e(k)){let P=Di(k);return function($){return P.variants?No($,P,$.theme.modularCssLayers?p:void 0):$.theme.modularCssLayers?ft(P.style,p):P.style}}return k},C=(...k)=>{let P=[],Q=k.map(w),$=[];if(P.push(a),c&&m&&$.push(function(h){let I=h.theme.components?.[c]?.styleOverrides;if(!I)return null;let M={};for(let A in I)M[A]=No(h,I[A],h.theme.modularCssLayers?"theme":void 0);return m(h,M)}),c&&!y&&$.push(function(h){let I=h.theme?.components?.[c]?.variants;return I?du(h,I,[],h.theme.modularCssLayers?"theme":void 0):null}),v||$.push(zt),Array.isArray(Q[0])){let le=Q.shift(),h=new Array(P.length).fill(""),b=new Array($.length).fill(""),I;I=[...h,...le,...b],I.raw=[...h,...le.raw,...b],P.unshift(I)}let se=[...P,...Q,...$],E=S(...se);return l.muiName&&(E.muiName=l.muiName),process.env.NODE_ENV!=="production"&&(E.displayName=oh(c,u,l)),E};return S.withConfig&&(C.withConfig=S.withConfig),C}}function oh(e,t,r){return e?`${e}${tt(t||"")}`:`Styled(${$o(r)})`}function nh(e,t){let r;return process.env.NODE_ENV!=="production"&&e&&(r=`${e}-${fu(t||"Root")}`),r}function ih(e){for(let t in e)return!1;return!0}function ah(e){return typeof e=="string"&&e.charCodeAt(0)>96}function fu(e){return e&&e.charAt(0).toLowerCase()+e.slice(1)}var sh=Vo(),Ri=sh;function Sr(e,t,r=!1){let o={...t};for(let n in e)if(Object.prototype.hasOwnProperty.call(e,n)){let a=n;if(a==="components"||a==="slots")o[a]={...e[a],...o[a]};else if(a==="componentsProps"||a==="slotProps"){let i=e[a],l=t[a];if(!l)o[a]=i||{};else if(!i)o[a]=l;else{o[a]={...l};for(let s in i)if(Object.prototype.hasOwnProperty.call(i,s)){let c=s;o[a][c]=Sr(i[c],l[c],r)}}}else a==="className"&&r&&t.className?o.className=Bo(e?.className,t?.className):a==="style"&&r&&t.style?o.style={...e?.style,...t?.style}:o[a]===void 0&&(o[a]=e[a])}return o}function Oi(e){let{theme:t,name:r,props:o}=e;return!t||!t.components||!t.components[r]||!t.components[r].defaultProps?o:Sr(t.components[r].defaultProps,o)}function zo({props:e,name:t,defaultTheme:r,themeId:o}){let n=Ai(r);return o&&(n=n[o]||n),Oi({theme:n,name:t,props:e})}function Wo(e,t,r=void 0){let o={};for(let n in e){let a=e[n],i="",l=!0;for(let s=0;s<a.length;s+=1){let c=a[s];c&&(i+=(l===!0?"":" ")+t(c),l=!1,r&&r[c]&&(i+=" "+r[c]))}o[n]=i}return o}var j=Xe(go(),1);var Y=Xe(go(),1);import*as Wt from"react";import{jsx as lh}from"react/jsx-runtime";var ch=dt(),uh=Ri("div",{name:"MuiStack",slot:"Root"});function ph(e){return zo({props:e,name:"MuiStack",defaultTheme:ch})}function dh(e,t){let r=Wt.Children.toArray(e).filter(Boolean);return r.reduce((o,n,a)=>(o.push(n),a<r.length-1&&o.push(Wt.cloneElement(t,{key:`separator-${a}`})),o),[])}var fh=e=>({row:"Left","row-reverse":"Right",column:"Top","column-reverse":"Bottom"})[e],mh=({ownerState:e,theme:t})=>{let r={display:"flex",flexDirection:"column",...ee({theme:t},Ao({values:e.direction,breakpoints:t.breakpoints.values}),o=>({flexDirection:o}))};if(e.spacing){let o=xr(t),n=Object.keys(t.breakpoints.values).reduce((s,c)=>((typeof e.spacing=="object"&&e.spacing[c]!=null||typeof e.direction=="object"&&e.direction[c]!=null)&&(s[c]=!0),s),{}),a=Ao({values:e.direction,base:n}),i=Ao({values:e.spacing,base:n});typeof a=="object"&&Object.keys(a).forEach((s,c,u)=>{if(!a[s]){let f=c>0?a[u[c-1]]:"column";a[s]=f}}),r=Te(r,ee({theme:t},i,(s,c)=>e.useFlexGap?{gap:Ne(o,s)}:{"& > :not(style):not(style)":{margin:0},"& > :not(style) ~ :not(style)":{[`margin${fh(c?a[c]:e.direction)}`]:Ne(o,s)}}))}return r=ou(t.breakpoints,r),r};function Bi(e={}){let{createStyledComponent:t=uh,useThemeProps:r=ph,componentName:o="MuiStack"}=e,n=()=>Wo({root:["root"]},s=>_o(o,s),{}),a=t(mh),i=Wt.forwardRef(function(s,c){let u=r(s),d=Oo(u),{component:f="div",direction:m="column",spacing:g=0,divider:p,children:y,className:v,useFlexGap:x=!1,...S}=d,w={direction:m,spacing:g,useFlexGap:x},C=n();return lh(a,{as:f,ownerState:w,ref:c,className:Bo(C.root,v),...S,children:p?dh(y,p):y})});return process.env.NODE_ENV!=="production"&&(i.propTypes={children:Y.default.node,direction:Y.default.oneOfType([Y.default.oneOf(["column-reverse","column","row-reverse","row"]),Y.default.arrayOf(Y.default.oneOf(["column-reverse","column","row-reverse","row"])),Y.default.object]),divider:Y.default.node,spacing:Y.default.oneOfType([Y.default.arrayOf(Y.default.oneOfType([Y.default.number,Y.default.string])),Y.default.number,Y.default.object,Y.default.string]),sx:Y.default.oneOfType([Y.default.arrayOf(Y.default.oneOfType([Y.default.func,Y.default.object,Y.default.bool])),Y.default.func,Y.default.object])}),i}var mu=Bi();process.env.NODE_ENV!=="production"&&(mu.propTypes={children:j.default.node,component:j.default.elementType,direction:j.default.oneOfType([j.default.oneOf(["column-reverse","column","row-reverse","row"]),j.default.arrayOf(j.default.oneOf(["column-reverse","column","row-reverse","row"])),j.default.object]),divider:j.default.node,spacing:j.default.oneOfType([j.default.arrayOf(j.default.oneOfType([j.default.number,j.default.string])),j.default.number,j.default.object,j.default.string]),sx:j.default.oneOfType([j.default.arrayOf(j.default.oneOfType([j.default.func,j.default.object,j.default.bool])),j.default.func,j.default.object]),useFlexGap:j.default.bool});var Go=mu;import{jsx as Ho,jsxs as hu}from"react/jsx-runtime";var xh=hh(yh)(({theme:e})=>({fontWeight:"bold"}));function yu(e){let{label:t,children:r,labelProps:o,contentProps:n,isNumber:a,showDivider:i}=e;return hu(gu,{sx:{display:"flex",gap:4},children:[hu(gu,{children:[Ho(Go,{children:Ho(xh,{...o,children:t})}),Ho(Go,{direction:a?"row":"column",justifyContent:a?"flex-end":"center",children:r})]}),i&&Ho(gh,{orientation:"vertical",flexItem:!0})]})}import{useEffect as vu,useRef as Rh,useState as bu}from"react";import{Box as Cu,IconButton as wu,Stack as Oh,Typography as Bh,useMediaQuery as _h,Toolbar as Lh}from"@mui/material";import{ArrowBack as $h,Close as Nh}from"@mui/icons-material";import{Cancel as vh,Edit as bh,Save as Ch}from"@mui/icons-material";import{Stack as wh,TextField as Sh,Typography as Th,IconButton as xu,ClickAwayListener as Ph,InputAdornment as kh,CircularProgress as Ih}from"@mui/material";import{useEffect as _i,useState as Li}from"react";import{Fragment as Eh,jsx as Ue,jsxs as $i}from"react/jsx-runtime";function Uo(e){let{typographyProps:t,onChange:r,onEscape:o,value:n,displayEditButton:a,displaySaveButton:i,textFieldProps:l,isEditing:s,isLoading:c,error:u}=e,{InputProps:d,value:f,onKeyDown:m,onChange:g,...p}=l||{},[y,v]=Li(!1),[x,S]=Li(!1),[w,C]=Li();return _i(()=>{C(n)},[n]),_i(()=>{v(!!s)},[s]),_i(()=>{u&&S(!0)},[u]),$i(Eh,{children:[!y&&!c&&!x&&$i(wh,{sx:{cursor:"pointer"},direction:"row",alignItems:"center",spacing:1,children:[Ue(Th,{onClick:()=>{v(!0)},...t,children:w}),a&&Ue(xu,{onClick:()=>{v(!0)},children:Ue(bh,{})})]}),(y||c||x)&&Ue(Ph,{onClickAway:()=>v(!1),children:Ue(Sh,{disabled:c,autoFocus:!0,value:w,error:x,onKeyDown:k=>{k.key==="Enter"&&(r(w),v(!1)),k.key==="Escape"&&(C(n),v(!1),S(!1),o&&o(n,w))},onChange:k=>{let P=k.target.value;C(P)},InputProps:{endAdornment:$i(kh,{position:"end",children:[c&&Ue(Ih,{size:18}),i&&Ue(xu,{onClick:()=>{n!=w&&r(w),v(!1)},edge:"end",children:n!=w?Ue(Ch,{}):Ue(vh,{})})]})},...p})})]})}import{InputAdornment as Ah,TextField as Mh}from"@mui/material";import{Search as Dh}from"@mui/icons-material";import Fh from"lodash";import{jsx as Ni}from"react/jsx-runtime";function Gt(e){let{onSearch:t,...r}=e,o=Fh.debounce(a=>t(a),500);function n(a){let i=a.target.value;o(i)}return Ni(Mh,{onChange:n,autoFocus:!0,InputProps:{startAdornment:Ni(Ah,{position:"start",children:Ni(Dh,{})})},...r})}import{jsx as rt,jsxs as Vi}from"react/jsx-runtime";function Su(e){let{title:t,children:r,onBack:o,onClose:n,onUpdate:a,onSearch:i,storagePath:l,toolbarProps:s}=e,[c,u]=bu(!1),[d,f]=bu("");vu(()=>{f(t)},[t]);let m=Rh(null);vu(()=>{if(i&&l){let v=localStorage.getItem(l);m.current&&(m.current.value=v),i(v||"")}},[l]);let g=_h(v=>v.breakpoints.down("sm"));function p(v){l&&localStorage.setItem(l,v),i&&i(v)}let y={component:"h1",variant:"h4",sx:{fontWeight:"500"}};return rt(Lh,{...s,children:Vi(Cu,{sx:{display:"flex",flexDirection:g||n?"column":"row",justifyContent:"space-between",alignContent:"center",alignItems:"center",flexGrow:1},children:[Vi(Cu,{sx:{display:"flex",alignItems:"center",flexDirection:"row"},children:[o&&rt(wu,{sx:{mr:1},onClick:o,children:rt($h,{})}),a&&rt(Uo,{typographyProps:y,value:d,onChange:v=>{a&&a(v)}}),!a&&rt(Bh,{...y,children:t})]}),n&&rt(wu,{sx:{marginLeft:"auto"},onClick:n,children:rt(Nh,{fontSize:"medium"})}),Vi(Oh,{spacing:1,direction:"row",children:[i&&rt(Gt,{inputRef:m,autoFocus:!0,onSearch:p}),r]})]})})}import{Stack as dn,Typography as A0,useMediaQuery as M0,useTheme as D0}from"@mui/material";import{Stack as Vh,useMediaQuery as zh,useTheme as Wh}from"@mui/material";import{jsx as Gh}from"react/jsx-runtime";function zi(e){let{children:t}=e,r=Wh(),o=zh(r.breakpoints.up("md"));return Gh(Vh,{component:"section",display:o?"flex":"none",width:"100%",direction:"row",justifyContent:"center",alignItems:"center",sx:{},children:t})}import{Box as x0,Stack as v0,useMediaQuery as b0,useTheme as C0}from"@mui/material";import{Stack as Hh,Typography as Tu}from"@mui/material";import{jsx as Pu,jsxs as Uh}from"react/jsx-runtime";function Wi(e){let{label:t,subTitle:r="Acesse sua conta"}=e;return Uh(Hh,{component:"header",textAlign:"center",marginBottom:"3rem",children:[Pu(Tu,{component:"h2",fontSize:"2rem",fontWeight:"bold",variant:"body1",fontFamily:"Montserrat",sx:{color:o=>o.palette.primary.dark},children:t}),Pu(Tu,{component:"h3",fontSize:"1.25rem",fontFamily:"Montserrat",color:"primary",variant:"body1",children:r})]})}import{useState as Jt}from"react";import{Alert as lp,Divider as cp,Stack as ln,TextField as Dx,Typography as Fx}from"@mui/material";import{isAxiosError as Rx}from"axios";import{useValidations as Ox,useCredentials as Bx}from"@data-c/hooks";var ke=Xe(Du()),Tr=Xe(Ou()),zu=Xe(_u()),cy=Object.prototype.toString,uy=Error.prototype.toString,py=RegExp.prototype.toString,dy=typeof Symbol<"u"?Symbol.prototype.toString:()=>"",fy=/^Symbol\((.*)\)(.*)$/;function my(e){return e!=+e?"NaN":e===0&&1/e<0?"-0":""+e}function Lu(e,t=!1){if(e==null||e===!0||e===!1)return""+e;let r=typeof e;if(r==="number")return my(e);if(r==="string")return t?`"${e}"`:e;if(r==="function")return"[Function "+(e.name||"anonymous")+"]";if(r==="symbol")return dy.call(e).replace(fy,"Symbol($1)");let o=cy.call(e).slice(8,-1);return o==="Date"?isNaN(e.getTime())?""+e:e.toISOString(e):o==="Error"||e instanceof Error?"["+uy.call(e)+"]":o==="RegExp"?py.call(e):null}function qe(e,t){let r=Lu(e,t);return r!==null?r:JSON.stringify(e,function(o,n){let a=Lu(this[o],t);return a!==null?a:n},2)}function Wu(e){return e==null?[]:[].concat(e)}var Gu,Hu,Uu,gy=/\$\{\s*(\w+)\s*\}/g;Gu=Symbol.toStringTag;var Jo=class{constructor(t,r,o,n){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[Gu]="Error",this.name="ValidationError",this.value=r,this.path=o,this.type=n,this.errors=[],this.inner=[],Wu(t).forEach(a=>{if(te.isError(a)){this.errors.push(...a.errors);let i=a.inner.length?a.inner:[a];this.inner.push(...i)}else this.errors.push(a)}),this.message=this.errors.length>1?`${this.errors.length} errors occurred`:this.errors[0]}};Hu=Symbol.hasInstance;Uu=Symbol.toStringTag;var te=class extends Error{static formatError(t,r){let o=r.label||r.path||"this";return r=Object.assign({},r,{path:o,originalPath:r.path}),typeof t=="string"?t.replace(gy,(n,a)=>qe(r[a])):typeof t=="function"?t(r):t}static isError(t){return t&&t.name==="ValidationError"}constructor(t,r,o,n,a){let i=new Jo(t,r,o,n);if(a)return i;super(),this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=[],this.inner=[],this[Uu]="Error",this.name=i.name,this.message=i.message,this.type=i.type,this.value=i.value,this.path=i.path,this.errors=i.errors,this.inner=i.inner,Error.captureStackTrace&&Error.captureStackTrace(this,te)}static[Hu](t){return Jo[Symbol.hasInstance](t)||super[Symbol.hasInstance](t)}},Ve={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:o})=>{let n=o!=null&&o!==r?` (cast from the value \`${qe(o,!0)}\`).`:".";return t!=="mixed"?`${e} must be a \`${t}\` type, but the final value was: \`${qe(r,!0)}\``+n:`${e} must match the configured type. The validated value was: \`${qe(r,!0)}\``+n}},fe={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"},ot={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"},Ki={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"},Zi={isValue:"${path} field must be ${value}"},Ko={noUnknown:"${path} field has unspecified keys: ${unknown}",exact:"${path} object contains unknown properties: ${properties}"},Zo={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"},ju={notType:e=>{let{path:t,value:r,spec:o}=e,n=o.types.length;if(Array.isArray(r)){if(r.length<n)return`${t} tuple value has too few items, expected a length of ${n} but got ${r.length} for value: \`${qe(r,!0)}\``;if(r.length>n)return`${t} tuple value has too many items, expected a length of ${n} but got ${r.length} for value: \`${qe(r,!0)}\``}return te.formatError(Ve.notType,e)}},gM=Object.assign(Object.create(null),{mixed:Ve,string:fe,number:ot,date:Ki,object:Ko,array:Zo,boolean:Zi,tuple:ju}),sn=e=>e&&e.__isYupSchema__,jt=class{static fromOptions(t,r){if(!r.then&&!r.otherwise)throw new TypeError("either `then:` or `otherwise:` is required for `when()` conditions");let{is:o,then:n,otherwise:a}=r,i=typeof o=="function"?o:(...l)=>l.every(s=>s===o);return new jt(t,(l,s)=>{var c;let u=i(...l)?n:a;return(c=u?.(s))!=null?c:s})}constructor(t,r){this.fn=void 0,this.refs=t,this.refs=t,this.fn=r}resolve(t,r){let o=this.refs.map(a=>a.getValue(r?.value,r?.parent,r?.context)),n=this.fn(o,t,r);if(n===void 0||n===t)return t;if(!sn(n))throw new TypeError("conditions must return a schema object");return n.resolve(r)}},Yo={context:"$",value:"."};var Ye=class{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]===Yo.context,this.isValue=this.key[0]===Yo.value,this.isSibling=!this.isContext&&!this.isValue;let o=this.isContext?Yo.context:this.isValue?Yo.value:"";this.path=this.key.slice(o.length),this.getter=this.path&&(0,ke.getter)(this.path,!0),this.map=r.map}getValue(t,r,o){let n=this.isContext?o:this.isValue?t:r;return this.getter&&(n=this.getter(n||{})),this.map&&(n=this.map(n)),n}cast(t,r){return this.getValue(t,r?.parent,r?.context)}resolve(){return this}describe(){return{type:"ref",key:this.key}}toString(){return`Ref(${this.key})`}static isRef(t){return t&&t.__isYupRef}};Ye.prototype.__isYupRef=!0;var Me=e=>e==null;function Ht(e){function t({value:r,path:o="",options:n,originalValue:a,schema:i},l,s){let{name:c,test:u,params:d,message:f,skipAbsent:m}=e,{parent:g,context:p,abortEarly:y=i.spec.abortEarly,disableStackTrace:v=i.spec.disableStackTrace}=n,x={value:r,parent:g,context:p};function S(E={}){let le=qu(Object.assign({value:r,originalValue:a,label:i.spec.label,path:E.path||o,spec:i.spec,disableStackTrace:E.disableStackTrace||v},d,E.params),x),h=new te(te.formatError(E.message||f,le),r,le.path,E.type||c,le.disableStackTrace);return h.params=le,h}let w=y?l:s,C={path:o,parent:g,type:c,from:n.from,createError:S,resolve(E){return Yu(E,x)},options:n,originalValue:a,schema:i},k=E=>{te.isError(E)?w(E):E?s(null):w(S())},P=E=>{te.isError(E)?w(E):l(E)};if(m&&Me(r))return k(!0);let $;try{var se;if($=u.call(C,r,C),typeof((se=$)==null?void 0:se.then)=="function"){if(n.sync)throw new Error(`Validation test of type: "${C.type}" returned a Promise during a synchronous validate. This test will finish after the validate call has returned`);return Promise.resolve($).then(k,P)}}catch(E){P(E);return}k($)}return t.OPTIONS=e,t}function qu(e,t){if(!e)return e;for(let r of Object.keys(e))e[r]=Yu(e[r],t);return e}function Yu(e,t){return Ye.isRef(e)?e.getValue(t.value,t.parent,t.context):e}function hy(e,t,r,o=r){let n,a,i;return t?((0,ke.forEach)(t,(l,s,c)=>{let u=s?l.slice(1,l.length-1):l;e=e.resolve({context:o,parent:n,value:r});let d=e.type==="tuple",f=c?parseInt(u,10):0;if(e.innerType||d){if(d&&!c)throw new Error(`Yup.reach cannot implicitly index into a tuple type. the path part "${i}" must contain an index to the tuple element, e.g. "${i}[0]"`);if(r&&f>=r.length)throw new Error(`Yup.reach cannot resolve an array item at index: ${l}, in the path: ${t}. because there is no value at that index. `);n=r,r=r&&r[f],e=d?e.spec.types[f]:e.innerType}if(!c){if(!e.fields||!e.fields[u])throw new Error(`The schema does not contain the path: ${t}. (failed at: ${i} which is a type: "${e.type}")`);n=r,r=r&&r[u],e=e.fields[u]}a=u,i=s?"["+l+"]":"."+l}),{schema:e,parent:n,parentPath:a}):{parent:n,parentPath:t,schema:e}}var qt=class extends Set{describe(){let t=[];for(let r of this.values())t.push(Ye.isRef(r)?r.describe():r);return t}resolveAll(t){let r=[];for(let o of this.values())r.push(t(o));return r}clone(){return new qt(this.values())}merge(t,r){let o=this.clone();return t.forEach(n=>o.add(n)),r.forEach(n=>o.delete(n)),o}};function Ut(e,t=new Map){if(sn(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 o=0;o<e.length;o++)r[o]=Ut(e[o],t)}else if(e instanceof Map){r=new Map,t.set(e,r);for(let[o,n]of e.entries())r.set(o,Ut(n,t))}else if(e instanceof Set){r=new Set,t.set(e,r);for(let o of e)r.add(Ut(o,t))}else if(e instanceof Object){r={},t.set(e,r);for(let[o,n]of Object.entries(e))r[o]=Ut(n,t)}else throw Error(`Unable to clone ${e}`);return r}function yy(e){if(!(e!=null&&e.length))return;let t=[],r="",o=!1,n=!1;for(let a=0;a<e.length;a++){let i=e[a];if(i==="["&&!n){r&&(t.push(...r.split(".").filter(Boolean)),r=""),o=!0;continue}if(i==="]"&&!n){r&&(/^\d+$/.test(r)?t.push(r):t.push(r.replace(/^"|"$/g,"")),r=""),o=!1;continue}if(i==='"'){n=!n;continue}if(i==="."&&!o&&!n){r&&(t.push(r),r="");continue}r+=i}return r&&t.push(...r.split(".").filter(Boolean)),t}function xy(e,t){let r=t?`${t}.${e.path}`:e.path;return e.errors.map(o=>({message:o,path:yy(r)}))}function Ku(e,t){var r;if(!((r=e.inner)!=null&&r.length)&&e.errors.length)return xy(e,t);let o=t?`${t}.${e.path}`:e.path;return e.inner.flatMap(n=>Ku(n,o))}var re=class{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 qt,this._blacklist=new qt,this.exclusiveTests=Object.create(null),this._typeCheck=void 0,this.spec=void 0,this.tests=[],this.transforms=[],this.withMutation(()=>{this.typeError(Ve.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?.spec),this.withMutation(r=>{r.nonNullable()})}get _type(){return this.type}clone(t){if(this._mutate)return t&&Object.assign(this.spec,t),this;let 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=Ut(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 o=t(this);return this._mutate=r,o}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,o=t.clone(),n=Object.assign({},r.spec,o.spec);return o.spec=n,o.internalTests=Object.assign({},r.internalTests,o.internalTests),o._whitelist=r._whitelist.merge(t._whitelist,t._blacklist),o._blacklist=r._blacklist.merge(t._blacklist,t._whitelist),o.tests=r.tests,o.exclusiveTests=r.exclusiveTests,o.withMutation(a=>{t.tests.forEach(i=>{a.test(i.OPTIONS)})}),o.transforms=[...r.transforms,...o.transforms],o}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 o=r.conditions;r=r.clone(),r.conditions=[],r=o.reduce((n,a)=>a.resolve(n,t),r),r=r.resolve(t)}return r}resolveOptions(t){var r,o,n,a;return Object.assign({},t,{from:t.from||[],strict:(r=t.strict)!=null?r:this.spec.strict,abortEarly:(o=t.abortEarly)!=null?o:this.spec.abortEarly,recursive:(n=t.recursive)!=null?n:this.spec.recursive,disableStackTrace:(a=t.disableStackTrace)!=null?a:this.spec.disableStackTrace})}cast(t,r={}){let o=this.resolve(Object.assign({},r,{value:t})),n=r.assert==="ignore-optionality",a=o._cast(t,r);if(r.assert!==!1&&!o.isType(a)){if(n&&Me(a))return a;let i=qe(t),l=qe(a);throw new TypeError(`The value of ${r.path||"field"} could not be cast to a value that satisfies the schema type: "${o.type}".
1
+ var im=Object.create;var Tu=Object.defineProperty;var am=Object.getOwnPropertyDescriptor;var sm=Object.getOwnPropertyNames;var lm=Object.getPrototypeOf,um=Object.prototype.hasOwnProperty;var ne=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports);var cm=(t,e,r,o)=>{if(e&&typeof e=="object"||typeof e=="function")for(let n of sm(e))!um.call(t,n)&&n!==r&&Tu(t,n,{get:()=>e[n],enumerable:!(o=am(e,n))||o.enumerable});return t};var rt=(t,e,r)=>(r=t!=null?im(lm(t)):{},cm(e||!t||!t.__esModule?Tu(r,"default",{value:t,enumerable:!0}):r,t));var ac=ne(V=>{"use strict";var X=typeof Symbol=="function"&&Symbol.for,Ti=X?Symbol.for("react.element"):60103,Pi=X?Symbol.for("react.portal"):60106,go=X?Symbol.for("react.fragment"):60107,yo=X?Symbol.for("react.strict_mode"):60108,bo=X?Symbol.for("react.profiler"):60114,vo=X?Symbol.for("react.provider"):60109,xo=X?Symbol.for("react.context"):60110,ki=X?Symbol.for("react.async_mode"):60111,Co=X?Symbol.for("react.concurrent_mode"):60111,wo=X?Symbol.for("react.forward_ref"):60112,So=X?Symbol.for("react.suspense"):60113,Yh=X?Symbol.for("react.suspense_list"):60120,To=X?Symbol.for("react.memo"):60115,Po=X?Symbol.for("react.lazy"):60116,Kh=X?Symbol.for("react.block"):60121,Zh=X?Symbol.for("react.fundamental"):60117,Qh=X?Symbol.for("react.responder"):60118,Jh=X?Symbol.for("react.scope"):60119;function ve(t){if(typeof t=="object"&&t!==null){var e=t.$$typeof;switch(e){case Ti:switch(t=t.type,t){case ki:case Co:case go:case bo:case yo:case So:return t;default:switch(t=t&&t.$$typeof,t){case xo:case wo:case Po:case To:case vo:return t;default:return e}}case Pi:return e}}}function ic(t){return ve(t)===Co}V.AsyncMode=ki;V.ConcurrentMode=Co;V.ContextConsumer=xo;V.ContextProvider=vo;V.Element=Ti;V.ForwardRef=wo;V.Fragment=go;V.Lazy=Po;V.Memo=To;V.Portal=Pi;V.Profiler=bo;V.StrictMode=yo;V.Suspense=So;V.isAsyncMode=function(t){return ic(t)||ve(t)===ki};V.isConcurrentMode=ic;V.isContextConsumer=function(t){return ve(t)===xo};V.isContextProvider=function(t){return ve(t)===vo};V.isElement=function(t){return typeof t=="object"&&t!==null&&t.$$typeof===Ti};V.isForwardRef=function(t){return ve(t)===wo};V.isFragment=function(t){return ve(t)===go};V.isLazy=function(t){return ve(t)===Po};V.isMemo=function(t){return ve(t)===To};V.isPortal=function(t){return ve(t)===Pi};V.isProfiler=function(t){return ve(t)===bo};V.isStrictMode=function(t){return ve(t)===yo};V.isSuspense=function(t){return ve(t)===So};V.isValidElementType=function(t){return typeof t=="string"||typeof t=="function"||t===go||t===Co||t===bo||t===yo||t===So||t===Yh||typeof t=="object"&&t!==null&&(t.$$typeof===Po||t.$$typeof===To||t.$$typeof===vo||t.$$typeof===xo||t.$$typeof===wo||t.$$typeof===Zh||t.$$typeof===Qh||t.$$typeof===Jh||t.$$typeof===Kh)};V.typeOf=ve});var sc=ne(W=>{"use strict";process.env.NODE_ENV!=="production"&&function(){"use strict";var t=typeof Symbol=="function"&&Symbol.for,e=t?Symbol.for("react.element"):60103,r=t?Symbol.for("react.portal"):60106,o=t?Symbol.for("react.fragment"):60107,n=t?Symbol.for("react.strict_mode"):60108,a=t?Symbol.for("react.profiler"):60114,i=t?Symbol.for("react.provider"):60109,l=t?Symbol.for("react.context"):60110,s=t?Symbol.for("react.async_mode"):60111,u=t?Symbol.for("react.concurrent_mode"):60111,c=t?Symbol.for("react.forward_ref"):60112,d=t?Symbol.for("react.suspense"):60113,f=t?Symbol.for("react.suspense_list"):60120,m=t?Symbol.for("react.memo"):60115,h=t?Symbol.for("react.lazy"):60116,p=t?Symbol.for("react.block"):60121,y=t?Symbol.for("react.fundamental"):60117,v=t?Symbol.for("react.responder"):60118,b=t?Symbol.for("react.scope"):60119;function S(T){return typeof T=="string"||typeof T=="function"||T===o||T===u||T===a||T===n||T===d||T===f||typeof T=="object"&&T!==null&&(T.$$typeof===h||T.$$typeof===m||T.$$typeof===i||T.$$typeof===l||T.$$typeof===c||T.$$typeof===y||T.$$typeof===v||T.$$typeof===b||T.$$typeof===p)}function w(T){if(typeof T=="object"&&T!==null){var si=T.$$typeof;switch(si){case e:var io=T.type;switch(io){case s:case u:case o:case a:case n:case d:return io;default:var Su=io&&io.$$typeof;switch(Su){case l:case c:case h:case m:case i:return Su;default:return si}}case r:return si}}}var C=s,k=u,P=l,Q=i,z=e,se=c,A=o,le=h,g=m,x=r,I=a,F=n,E=d,B=!1;function M(T){return B||(B=!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.")),R(T)||w(T)===s}function R(T){return w(T)===u}function L(T){return w(T)===l}function _(T){return w(T)===i}function $(T){return typeof T=="object"&&T!==null&&T.$$typeof===e}function fe(T){return w(T)===c}function oe(T){return w(T)===o}function tt(T){return w(T)===h}function em(T){return w(T)===m}function tm(T){return w(T)===r}function rm(T){return w(T)===a}function om(T){return w(T)===n}function nm(T){return w(T)===d}W.AsyncMode=C,W.ConcurrentMode=k,W.ContextConsumer=P,W.ContextProvider=Q,W.Element=z,W.ForwardRef=se,W.Fragment=A,W.Lazy=le,W.Memo=g,W.Portal=x,W.Profiler=I,W.StrictMode=F,W.Suspense=E,W.isAsyncMode=M,W.isConcurrentMode=R,W.isContextConsumer=L,W.isContextProvider=_,W.isElement=$,W.isForwardRef=fe,W.isFragment=oe,W.isLazy=tt,W.isMemo=em,W.isPortal=tm,W.isProfiler=rm,W.isStrictMode=om,W.isSuspense=nm,W.isValidElementType=S,W.typeOf=w}()});var Ai=ne((OI,Ii)=>{"use strict";process.env.NODE_ENV==="production"?Ii.exports=ac():Ii.exports=sc()});var cc=ne((BI,uc)=>{"use strict";var lc=Object.getOwnPropertySymbols,Xh=Object.prototype.hasOwnProperty,eg=Object.prototype.propertyIsEnumerable;function tg(t){if(t==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(t)}function rg(){try{if(!Object.assign)return!1;var t=new String("abc");if(t[5]="de",Object.getOwnPropertyNames(t)[0]==="5")return!1;for(var e={},r=0;r<10;r++)e["_"+String.fromCharCode(r)]=r;var o=Object.getOwnPropertyNames(e).map(function(a){return e[a]});if(o.join("")!=="0123456789")return!1;var n={};return"abcdefghijklmnopqrst".split("").forEach(function(a){n[a]=a}),Object.keys(Object.assign({},n)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}uc.exports=rg()?Object.assign:function(t,e){for(var r,o=tg(t),n,a=1;a<arguments.length;a++){r=Object(arguments[a]);for(var i in r)Xh.call(r,i)&&(o[i]=r[i]);if(lc){n=lc(r);for(var l=0;l<n.length;l++)eg.call(r,n[l])&&(o[n[l]]=r[n[l]])}}return o}});var ko=ne((LI,pc)=>{"use strict";var og="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";pc.exports=og});var Ei=ne(($I,fc)=>{fc.exports=Function.call.bind(Object.prototype.hasOwnProperty)});var yc=ne((zI,gc)=>{"use strict";var Fi=function(){};process.env.NODE_ENV!=="production"&&(dc=ko(),Io={},mc=Ei(),Fi=function(t){var e="Warning: "+t;typeof console<"u"&&console.error(e);try{throw new Error(e)}catch{}});var dc,Io,mc;function hc(t,e,r,o,n){if(process.env.NODE_ENV!=="production"){for(var a in t)if(mc(t,a)){var i;try{if(typeof t[a]!="function"){var l=Error((o||"React class")+": "+r+" type `"+a+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof t[a]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw l.name="Invariant Violation",l}i=t[a](e,a,o,r,null,dc)}catch(u){i=u}if(i&&!(i instanceof Error)&&Fi((o||"React class")+": type specification of "+r+" `"+a+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof i+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),i instanceof Error&&!(i.message in Io)){Io[i.message]=!0;var s=n?n():"";Fi("Failed "+r+" type: "+i.message+(s??""))}}}}hc.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(Io={})};gc.exports=hc});var xc=ne((_I,vc)=>{"use strict";var ng=Ai(),ig=cc(),jt=ko(),Mi=Ei(),bc=yc(),Ut=function(){};process.env.NODE_ENV!=="production"&&(Ut=function(t){var e="Warning: "+t;typeof console<"u"&&console.error(e);try{throw new Error(e)}catch{}});function Ao(){return null}vc.exports=function(t,e){var r=typeof Symbol=="function"&&Symbol.iterator,o="@@iterator";function n(g){var x=g&&(r&&g[r]||g[o]);if(typeof x=="function")return x}var a="<<anonymous>>",i={array:c("array"),bigint:c("bigint"),bool:c("boolean"),func:c("function"),number:c("number"),object:c("object"),string:c("string"),symbol:c("symbol"),any:d(),arrayOf:f,element:m(),elementType:h(),instanceOf:p,node:S(),objectOf:v,oneOf:y,oneOfType:b,shape:C,exact:k};function l(g,x){return g===x?g!==0||1/g===1/x:g!==g&&x!==x}function s(g,x){this.message=g,this.data=x&&typeof x=="object"?x:{},this.stack=""}s.prototype=Error.prototype;function u(g){if(process.env.NODE_ENV!=="production")var x={},I=0;function F(B,M,R,L,_,$,fe){if(L=L||a,$=$||R,fe!==jt){if(e){var oe=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 oe.name="Invariant Violation",oe}else if(process.env.NODE_ENV!=="production"&&typeof console<"u"){var tt=L+":"+R;!x[tt]&&I<3&&(Ut("You are manually calling a React.PropTypes validation function for the `"+$+"` prop on `"+L+"`. 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."),x[tt]=!0,I++)}}return M[R]==null?B?M[R]===null?new s("The "+_+" `"+$+"` is marked as required "+("in `"+L+"`, but its value is `null`.")):new s("The "+_+" `"+$+"` is marked as required in "+("`"+L+"`, but its value is `undefined`.")):null:g(M,R,L,_,$)}var E=F.bind(null,!1);return E.isRequired=F.bind(null,!0),E}function c(g){function x(I,F,E,B,M,R){var L=I[F],_=z(L);if(_!==g){var $=se(L);return new s("Invalid "+B+" `"+M+"` of type "+("`"+$+"` supplied to `"+E+"`, expected ")+("`"+g+"`."),{expectedType:g})}return null}return u(x)}function d(){return u(Ao)}function f(g){function x(I,F,E,B,M){if(typeof g!="function")return new s("Property `"+M+"` of component `"+E+"` has invalid PropType notation inside arrayOf.");var R=I[F];if(!Array.isArray(R)){var L=z(R);return new s("Invalid "+B+" `"+M+"` of type "+("`"+L+"` supplied to `"+E+"`, expected an array."))}for(var _=0;_<R.length;_++){var $=g(R,_,E,B,M+"["+_+"]",jt);if($ instanceof Error)return $}return null}return u(x)}function m(){function g(x,I,F,E,B){var M=x[I];if(!t(M)){var R=z(M);return new s("Invalid "+E+" `"+B+"` of type "+("`"+R+"` supplied to `"+F+"`, expected a single ReactElement."))}return null}return u(g)}function h(){function g(x,I,F,E,B){var M=x[I];if(!ng.isValidElementType(M)){var R=z(M);return new s("Invalid "+E+" `"+B+"` of type "+("`"+R+"` supplied to `"+F+"`, expected a single ReactElement type."))}return null}return u(g)}function p(g){function x(I,F,E,B,M){if(!(I[F]instanceof g)){var R=g.name||a,L=le(I[F]);return new s("Invalid "+B+" `"+M+"` of type "+("`"+L+"` supplied to `"+E+"`, expected ")+("instance of `"+R+"`."))}return null}return u(x)}function y(g){if(!Array.isArray(g))return process.env.NODE_ENV!=="production"&&(arguments.length>1?Ut("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])."):Ut("Invalid argument supplied to oneOf, expected an array.")),Ao;function x(I,F,E,B,M){for(var R=I[F],L=0;L<g.length;L++)if(l(R,g[L]))return null;var _=JSON.stringify(g,function(fe,oe){var tt=se(oe);return tt==="symbol"?String(oe):oe});return new s("Invalid "+B+" `"+M+"` of value `"+String(R)+"` "+("supplied to `"+E+"`, expected one of "+_+"."))}return u(x)}function v(g){function x(I,F,E,B,M){if(typeof g!="function")return new s("Property `"+M+"` of component `"+E+"` has invalid PropType notation inside objectOf.");var R=I[F],L=z(R);if(L!=="object")return new s("Invalid "+B+" `"+M+"` of type "+("`"+L+"` supplied to `"+E+"`, expected an object."));for(var _ in R)if(Mi(R,_)){var $=g(R,_,E,B,M+"."+_,jt);if($ instanceof Error)return $}return null}return u(x)}function b(g){if(!Array.isArray(g))return process.env.NODE_ENV!=="production"&&Ut("Invalid argument supplied to oneOfType, expected an instance of array."),Ao;for(var x=0;x<g.length;x++){var I=g[x];if(typeof I!="function")return Ut("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+A(I)+" at index "+x+"."),Ao}function F(E,B,M,R,L){for(var _=[],$=0;$<g.length;$++){var fe=g[$],oe=fe(E,B,M,R,L,jt);if(oe==null)return null;oe.data&&Mi(oe.data,"expectedType")&&_.push(oe.data.expectedType)}var tt=_.length>0?", expected one of type ["+_.join(", ")+"]":"";return new s("Invalid "+R+" `"+L+"` supplied to "+("`"+M+"`"+tt+"."))}return u(F)}function S(){function g(x,I,F,E,B){return P(x[I])?null:new s("Invalid "+E+" `"+B+"` supplied to "+("`"+F+"`, expected a ReactNode."))}return u(g)}function w(g,x,I,F,E){return new s((g||"React class")+": "+x+" type `"+I+"."+F+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+E+"`.")}function C(g){function x(I,F,E,B,M){var R=I[F],L=z(R);if(L!=="object")return new s("Invalid "+B+" `"+M+"` of type `"+L+"` "+("supplied to `"+E+"`, expected `object`."));for(var _ in g){var $=g[_];if(typeof $!="function")return w(E,B,M,_,se($));var fe=$(R,_,E,B,M+"."+_,jt);if(fe)return fe}return null}return u(x)}function k(g){function x(I,F,E,B,M){var R=I[F],L=z(R);if(L!=="object")return new s("Invalid "+B+" `"+M+"` of type `"+L+"` "+("supplied to `"+E+"`, expected `object`."));var _=ig({},I[F],g);for(var $ in _){var fe=g[$];if(Mi(g,$)&&typeof fe!="function")return w(E,B,M,$,se(fe));if(!fe)return new s("Invalid "+B+" `"+M+"` key `"+$+"` supplied to `"+E+"`.\nBad object: "+JSON.stringify(I[F],null," ")+`
2
+ Valid keys: `+JSON.stringify(Object.keys(g),null," "));var oe=fe(R,$,E,B,M+"."+$,jt);if(oe)return oe}return null}return u(x)}function P(g){switch(typeof g){case"number":case"string":case"undefined":return!0;case"boolean":return!g;case"object":if(Array.isArray(g))return g.every(P);if(g===null||t(g))return!0;var x=n(g);if(x){var I=x.call(g),F;if(x!==g.entries){for(;!(F=I.next()).done;)if(!P(F.value))return!1}else for(;!(F=I.next()).done;){var E=F.value;if(E&&!P(E[1]))return!1}}else return!1;return!0;default:return!1}}function Q(g,x){return g==="symbol"?!0:x?x["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&x instanceof Symbol:!1}function z(g){var x=typeof g;return Array.isArray(g)?"array":g instanceof RegExp?"object":Q(x,g)?"symbol":x}function se(g){if(typeof g>"u"||g===null)return""+g;var x=z(g);if(x==="object"){if(g instanceof Date)return"date";if(g instanceof RegExp)return"regexp"}return x}function A(g){var x=se(g);switch(x){case"array":case"object":return"an "+x;case"boolean":case"date":case"regexp":return"a "+x;default:return x}}function le(g){return!g.constructor||!g.constructor.name?a:g.constructor.name}return i.checkPropTypes=bc,i.resetWarningCache=bc.resetWarningCache,i.PropTypes=i,i}});var Tc=ne((NI,Sc)=>{"use strict";var ag=ko();function Cc(){}function wc(){}wc.resetWarningCache=Cc;Sc.exports=function(){function t(o,n,a,i,l,s){if(s!==ag){var u=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 u.name="Invariant Violation",u}}t.isRequired=t;function e(){return t}var r={array:t,bigint:t,bool:t,func:t,number:t,object:t,string:t,symbol:t,any:t,arrayOf:e,element:t,elementType:t,instanceOf:e,node:t,objectOf:e,oneOf:e,oneOfType:e,shape:e,exact:e,checkPropTypes:wc,resetWarningCache:Cc};return r.PropTypes=r,r}});var Eo=ne((VI,Ri)=>{process.env.NODE_ENV!=="production"?(Pc=Ai(),kc=!0,Ri.exports=xc()(Pc.isElement,kc)):Ri.exports=Tc()();var Pc,kc});var Fc=ne(H=>{"use strict";var Oi=Symbol.for("react.transitional.element"),Bi=Symbol.for("react.portal"),Fo=Symbol.for("react.fragment"),Mo=Symbol.for("react.strict_mode"),Ro=Symbol.for("react.profiler"),Do=Symbol.for("react.consumer"),Oo=Symbol.for("react.context"),Bo=Symbol.for("react.forward_ref"),Lo=Symbol.for("react.suspense"),$o=Symbol.for("react.suspense_list"),zo=Symbol.for("react.memo"),_o=Symbol.for("react.lazy"),lg=Symbol.for("react.view_transition"),ug=Symbol.for("react.client.reference");function ke(t){if(typeof t=="object"&&t!==null){var e=t.$$typeof;switch(e){case Oi:switch(t=t.type,t){case Fo:case Ro:case Mo:case Lo:case $o:case lg:return t;default:switch(t=t&&t.$$typeof,t){case Oo:case Bo:case _o:case zo:return t;case Do:return t;default:return e}}case Bi:return e}}}H.ContextConsumer=Do;H.ContextProvider=Oo;H.Element=Oi;H.ForwardRef=Bo;H.Fragment=Fo;H.Lazy=_o;H.Memo=zo;H.Portal=Bi;H.Profiler=Ro;H.StrictMode=Mo;H.Suspense=Lo;H.SuspenseList=$o;H.isContextConsumer=function(t){return ke(t)===Do};H.isContextProvider=function(t){return ke(t)===Oo};H.isElement=function(t){return typeof t=="object"&&t!==null&&t.$$typeof===Oi};H.isForwardRef=function(t){return ke(t)===Bo};H.isFragment=function(t){return ke(t)===Fo};H.isLazy=function(t){return ke(t)===_o};H.isMemo=function(t){return ke(t)===zo};H.isPortal=function(t){return ke(t)===Bi};H.isProfiler=function(t){return ke(t)===Ro};H.isStrictMode=function(t){return ke(t)===Mo};H.isSuspense=function(t){return ke(t)===Lo};H.isSuspenseList=function(t){return ke(t)===$o};H.isValidElementType=function(t){return typeof t=="string"||typeof t=="function"||t===Fo||t===Ro||t===Mo||t===Lo||t===$o||typeof t=="object"&&t!==null&&(t.$$typeof===_o||t.$$typeof===zo||t.$$typeof===Oo||t.$$typeof===Do||t.$$typeof===Bo||t.$$typeof===ug||t.getModuleId!==void 0)};H.typeOf=ke});var Mc=ne(G=>{"use strict";process.env.NODE_ENV!=="production"&&function(){function t(p){if(typeof p=="object"&&p!==null){var y=p.$$typeof;switch(y){case e:switch(p=p.type,p){case o:case a:case n:case u:case c:case m:return p;default:switch(p=p&&p.$$typeof,p){case l:case s:case f:case d:return p;case i:return p;default:return y}}case r:return y}}}var e=Symbol.for("react.transitional.element"),r=Symbol.for("react.portal"),o=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),i=Symbol.for("react.consumer"),l=Symbol.for("react.context"),s=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),c=Symbol.for("react.suspense_list"),d=Symbol.for("react.memo"),f=Symbol.for("react.lazy"),m=Symbol.for("react.view_transition"),h=Symbol.for("react.client.reference");G.ContextConsumer=i,G.ContextProvider=l,G.Element=e,G.ForwardRef=s,G.Fragment=o,G.Lazy=f,G.Memo=d,G.Portal=r,G.Profiler=a,G.StrictMode=n,G.Suspense=u,G.SuspenseList=c,G.isContextConsumer=function(p){return t(p)===i},G.isContextProvider=function(p){return t(p)===l},G.isElement=function(p){return typeof p=="object"&&p!==null&&p.$$typeof===e},G.isForwardRef=function(p){return t(p)===s},G.isFragment=function(p){return t(p)===o},G.isLazy=function(p){return t(p)===f},G.isMemo=function(p){return t(p)===d},G.isPortal=function(p){return t(p)===r},G.isProfiler=function(p){return t(p)===a},G.isStrictMode=function(p){return t(p)===n},G.isSuspense=function(p){return t(p)===u},G.isSuspenseList=function(p){return t(p)===c},G.isValidElementType=function(p){return typeof p=="string"||typeof p=="function"||p===o||p===a||p===n||p===u||p===c||typeof p=="object"&&p!==null&&(p.$$typeof===f||p.$$typeof===d||p.$$typeof===l||p.$$typeof===i||p.$$typeof===s||p.$$typeof===h||p.getModuleId!==void 0)},G.typeOf=t}()});var $i=ne((ZI,Li)=>{"use strict";process.env.NODE_ENV==="production"?Li.exports=Fc():Li.exports=Mc()});var up=ne((uR,lp)=>{"use strict";function wt(t){this._maxSize=t,this.clear()}wt.prototype.clear=function(){this._size=0,this._values=Object.create(null)};wt.prototype.get=function(t){return this._values[t]};wt.prototype.set=function(t,e){return this._size>=this._maxSize&&this.clear(),t in this._values||this._size++,this._values[t]=e};var iy=/[^.^\]^[]+|(?=\[\]|\.\.)/g,sp=/^\d+$/,ay=/^\d/,sy=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,ly=/^\s*(['"]?)(.*?)(\1)\s*$/,pa=512,np=new wt(pa),ip=new wt(pa),ap=new wt(pa);lp.exports={Cache:wt,split:ca,normalizePath:ua,setter:function(t){var e=ua(t);return ip.get(t)||ip.set(t,function(o,n){for(var a=0,i=e.length,l=o;a<i-1;){var s=e[a];if(s==="__proto__"||s==="constructor"||s==="prototype")return o;l=l[e[a++]]}l[e[a]]=n})},getter:function(t,e){var r=ua(t);return ap.get(t)||ap.set(t,function(n){for(var a=0,i=r.length;a<i;)if(n!=null||!e)n=n[r[a++]];else return;return n})},join:function(t){return t.reduce(function(e,r){return e+(fa(r)||sp.test(r)?"["+r+"]":(e?".":"")+r)},"")},forEach:function(t,e,r){uy(Array.isArray(t)?t:ca(t),e,r)}};function ua(t){return np.get(t)||np.set(t,ca(t).map(function(e){return e.replace(ly,"$2")}))}function ca(t){return t.match(iy)||[""]}function uy(t,e,r){var o=t.length,n,a,i,l;for(a=0;a<o;a++)n=t[a],n&&(fy(n)&&(n='"'+n+'"'),l=fa(n),i=!l&&/^\d+$/.test(n),e.call(r,n,l,i,a,t))}function fa(t){return typeof t=="string"&&t&&["'",'"'].indexOf(t.charAt(0))!==-1}function cy(t){return t.match(ay)&&!t.match(sp)}function py(t){return sy.test(t)}function fy(t){return!fa(t)&&(cy(t)||py(t))}});var fp=ne((cR,pp)=>{var dy=/[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,sn=t=>t.match(dy)||[],ln=t=>t[0].toUpperCase()+t.slice(1),da=(t,e)=>sn(t).join(e).toLowerCase(),cp=t=>sn(t).reduce((e,r)=>`${e}${e?r[0].toUpperCase()+r.slice(1).toLowerCase():r.toLowerCase()}`,""),my=t=>ln(cp(t)),hy=t=>da(t,"_"),gy=t=>da(t,"-"),yy=t=>ln(da(t," ")),by=t=>sn(t).map(ln).join(" ");pp.exports={words:sn,upperFirst:ln,camelCase:cp,pascalCase:my,snakeCase:hy,kebabCase:gy,sentenceCase:yy,titleCase:by}});var mp=ne((pR,ma)=>{ma.exports=function(t){return dp(vy(t),t)};ma.exports.array=dp;function dp(t,e){var r=t.length,o=new Array(r),n={},a=r,i=xy(e),l=Cy(t);for(e.forEach(function(u){if(!l.has(u[0])||!l.has(u[1]))throw new Error("Unknown node. There is an unknown node in the supplied edges.")});a--;)n[a]||s(t[a],a,new Set);return o;function s(u,c,d){if(d.has(u)){var f;try{f=", node was:"+JSON.stringify(u)}catch{f=""}throw new Error("Cyclic dependency"+f)}if(!l.has(u))throw new Error("Found unknown node. Make sure to provided all involved nodes. Unknown node: "+JSON.stringify(u));if(!n[c]){n[c]=!0;var m=i.get(u)||new Set;if(m=Array.from(m),c=m.length){d.add(u);do{var h=m[--c];s(h,l.get(h),d)}while(c);d.delete(u)}o[--r]=u}}}function vy(t){for(var e=new Set,r=0,o=t.length;r<o;r++){var n=t[r];e.add(n[0]),e.add(n[1])}return Array.from(e)}function xy(t){for(var e=new Map,r=0,o=t.length;r<o;r++){var n=t[r];e.has(n[0])||e.set(n[0],new Set),e.has(n[1])||e.set(n[1],new Set),e.get(n[0]).add(n[1])}return e}function Cy(t){for(var e=new Map,r=0,o=t.length;r<o;r++)e.set(t[r],r);return e}});import{Button as pm,CircularProgress as fm}from"@mui/material";import{jsx as Pu}from"react/jsx-runtime";var dm=t=>{let{isLoading:e,children:r,...o}=t;return Pu(pm,{...o,disabled:e?!0:o.disabled,children:e?Pu(fm,{color:"secondary",size:22}):r})},D=dm;import{Stack as mm}from"@mui/material";import{jsx as hm}from"react/jsx-runtime";function _e(t){return hm(mm,{direction:"row",justifyContent:"flex-end",alignItems:"center",spacing:1,...t})}import{FormControl as gm,FormControlLabel as ym,Checkbox as bm}from"@mui/material";import{jsx as li}from"react/jsx-runtime";function ku(t){let{label:e,...r}=t;return li(gm,{component:"fieldset",children:li(ym,{label:e,control:li(bm,{...r})})})}import{Box as _u}from"@mui/material";function ue(){return ue=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var o in r)({}).hasOwnProperty.call(r,o)&&(t[o]=r[o])}return t},ue.apply(null,arguments)}function Iu(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function ot(t,e){return ot=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},ot(t,e)}function Au(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,ot(t,e)}function ao(t){return ao=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},ao(t)}function Eu(t){try{return Function.toString.call(t).indexOf("[native code]")!==-1}catch{return typeof t=="function"}}function ui(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(ui=function(){return!!t})()}function Fu(t,e,r){if(ui())return Reflect.construct.apply(null,arguments);var o=[null];o.push.apply(o,e);var n=new(t.bind.apply(t,o));return r&&ot(n,r.prototype),n}function so(t){var e=typeof Map=="function"?new Map:void 0;return so=function(o){if(o===null||!Eu(o))return o;if(typeof o!="function")throw new TypeError("Super expression must either be null or a function");if(e!==void 0){if(e.has(o))return e.get(o);e.set(o,n)}function n(){return Fu(o,arguments,ao(this).constructor)}return n.prototype=Object.create(o.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),ot(n,o)},so(t)}var vm={1:`Passed invalid arguments to hsl, please pass multiple numbers e.g. hsl(360, 0.75, 0.4) or an object e.g. rgb({ hue: 255, saturation: 0.4, lightness: 0.75 }).
3
+
4
+ `,2:`Passed invalid arguments to hsla, please pass multiple numbers e.g. hsla(360, 0.75, 0.4, 0.7) or an object e.g. rgb({ hue: 255, saturation: 0.4, lightness: 0.75, alpha: 0.7 }).
5
+
6
+ `,3:`Passed an incorrect argument to a color function, please pass a string representation of a color.
7
+
8
+ `,4:`Couldn't generate valid rgb string from %s, it returned %s.
9
+
10
+ `,5:`Couldn't parse the color string. Please provide the color as a string in hex, rgb, rgba, hsl or hsla notation.
11
+
12
+ `,6:`Passed invalid arguments to rgb, please pass multiple numbers e.g. rgb(255, 205, 100) or an object e.g. rgb({ red: 255, green: 205, blue: 100 }).
13
+
14
+ `,7:`Passed invalid arguments to rgba, please pass multiple numbers e.g. rgb(255, 205, 100, 0.75) or an object e.g. rgb({ red: 255, green: 205, blue: 100, alpha: 0.75 }).
15
+
16
+ `,8:`Passed invalid argument to toColorString, please pass a RgbColor, RgbaColor, HslColor or HslaColor object.
17
+
18
+ `,9:`Please provide a number of steps to the modularScale helper.
19
+
20
+ `,10:`Please pass a number or one of the predefined scales to the modularScale helper as the ratio.
21
+
22
+ `,11:`Invalid value passed as base to modularScale, expected number or em string but got "%s"
23
+
24
+ `,12:`Expected a string ending in "px" or a number passed as the first argument to %s(), got "%s" instead.
25
+
26
+ `,13:`Expected a string ending in "px" or a number passed as the second argument to %s(), got "%s" instead.
27
+
28
+ `,14:`Passed invalid pixel value ("%s") to %s(), please pass a value like "12px" or 12.
29
+
30
+ `,15:`Passed invalid base value ("%s") to %s(), please pass a value like "12px" or 12.
31
+
32
+ `,16:`You must provide a template to this method.
33
+
34
+ `,17:`You passed an unsupported selector state to this method.
35
+
36
+ `,18:`minScreen and maxScreen must be provided as stringified numbers with the same units.
37
+
38
+ `,19:`fromSize and toSize must be provided as stringified numbers with the same units.
39
+
40
+ `,20:`expects either an array of objects or a single object with the properties prop, fromSize, and toSize.
41
+
42
+ `,21:"expects the objects in the first argument array to have the properties `prop`, `fromSize`, and `toSize`.\n\n",22:"expects the first argument object to have the properties `prop`, `fromSize`, and `toSize`.\n\n",23:`fontFace expects a name of a font-family.
43
+
44
+ `,24:`fontFace expects either the path to the font file(s) or a name of a local copy.
45
+
46
+ `,25:`fontFace expects localFonts to be an array.
47
+
48
+ `,26:`fontFace expects fileFormats to be an array.
49
+
50
+ `,27:`radialGradient requries at least 2 color-stops to properly render.
51
+
52
+ `,28:`Please supply a filename to retinaImage() as the first argument.
53
+
54
+ `,29:`Passed invalid argument to triangle, please pass correct pointingDirection e.g. 'right'.
55
+
56
+ `,30:"Passed an invalid value to `height` or `width`. Please provide a pixel based unit.\n\n",31:`The animation shorthand only takes 8 arguments. See the specification for more information: http://mdn.io/animation
57
+
58
+ `,32:`To pass multiple animations please supply them in arrays, e.g. animation(['rotate', '2s'], ['move', '1s'])
59
+ To pass a single animation please supply them in simple values, e.g. animation('rotate', '2s')
60
+
61
+ `,33:`The animation shorthand arrays can only have 8 elements. See the specification for more information: http://mdn.io/animation
62
+
63
+ `,34:`borderRadius expects a radius value as a string or number as the second argument.
64
+
65
+ `,35:`borderRadius expects one of "top", "bottom", "left" or "right" as the first argument.
66
+
67
+ `,36:`Property must be a string value.
68
+
69
+ `,37:`Syntax Error at %s.
70
+
71
+ `,38:`Formula contains a function that needs parentheses at %s.
72
+
73
+ `,39:`Formula is missing closing parenthesis at %s.
74
+
75
+ `,40:`Formula has too many closing parentheses at %s.
76
+
77
+ `,41:`All values in a formula must have the same unit or be unitless.
78
+
79
+ `,42:`Please provide a number of steps to the modularScale helper.
80
+
81
+ `,43:`Please pass a number or one of the predefined scales to the modularScale helper as the ratio.
82
+
83
+ `,44:`Invalid value passed as base to modularScale, expected number or em/rem string but got %s.
84
+
85
+ `,45:`Passed invalid argument to hslToColorString, please pass a HslColor or HslaColor object.
86
+
87
+ `,46:`Passed invalid argument to rgbToColorString, please pass a RgbColor or RgbaColor object.
88
+
89
+ `,47:`minScreen and maxScreen must be provided as stringified numbers with the same units.
90
+
91
+ `,48:`fromSize and toSize must be provided as stringified numbers with the same units.
92
+
93
+ `,49:`Expects either an array of objects or a single object with the properties prop, fromSize, and toSize.
94
+
95
+ `,50:`Expects the objects in the first argument array to have the properties prop, fromSize, and toSize.
96
+
97
+ `,51:`Expects the first argument object to have the properties prop, fromSize, and toSize.
98
+
99
+ `,52:`fontFace expects either the path to the font file(s) or a name of a local copy.
100
+
101
+ `,53:`fontFace expects localFonts to be an array.
102
+
103
+ `,54:`fontFace expects fileFormats to be an array.
104
+
105
+ `,55:`fontFace expects a name of a font-family.
106
+
107
+ `,56:`linearGradient requries at least 2 color-stops to properly render.
108
+
109
+ `,57:`radialGradient requries at least 2 color-stops to properly render.
110
+
111
+ `,58:`Please supply a filename to retinaImage() as the first argument.
112
+
113
+ `,59:`Passed invalid argument to triangle, please pass correct pointingDirection e.g. 'right'.
114
+
115
+ `,60:"Passed an invalid value to `height` or `width`. Please provide a pixel based unit.\n\n",61:`Property must be a string value.
116
+
117
+ `,62:`borderRadius expects a radius value as a string or number as the second argument.
118
+
119
+ `,63:`borderRadius expects one of "top", "bottom", "left" or "right" as the first argument.
120
+
121
+ `,64:`The animation shorthand only takes 8 arguments. See the specification for more information: http://mdn.io/animation.
122
+
123
+ `,65:`To pass multiple animations please supply them in arrays, e.g. animation(['rotate', '2s'], ['move', '1s'])\\nTo pass a single animation please supply them in simple values, e.g. animation('rotate', '2s').
124
+
125
+ `,66:`The animation shorthand arrays can only have 8 elements. See the specification for more information: http://mdn.io/animation.
126
+
127
+ `,67:`You must provide a template to this method.
128
+
129
+ `,68:`You passed an unsupported selector state to this method.
130
+
131
+ `,69:`Expected a string ending in "px" or a number passed as the first argument to %s(), got %s instead.
132
+
133
+ `,70:`Expected a string ending in "px" or a number passed as the second argument to %s(), got %s instead.
134
+
135
+ `,71:`Passed invalid pixel value %s to %s(), please pass a value like "12px" or 12.
136
+
137
+ `,72:`Passed invalid base value %s to %s(), please pass a value like "12px" or 12.
138
+
139
+ `,73:`Please provide a valid CSS variable.
140
+
141
+ `,74:`CSS variable not found and no default was provided.
142
+
143
+ `,75:`important requires a valid style object, got a %s instead.
144
+
145
+ `,76:`fromSize and toSize must be provided as stringified numbers with the same units as minScreen and maxScreen.
146
+
147
+ `,77:`remToPx expects a value in "rem" but you provided it in "%s".
148
+
149
+ `,78:`base must be set in "px" or "%" but you set it in "%s".
150
+ `};function xm(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];var o=e[0],n=[],a;for(a=1;a<e.length;a+=1)n.push(e[a]);return n.forEach(function(i){o=o.replace(/%[a-z]/,i)}),o}var de=function(t){Au(e,t);function e(r){var o;if(process.env.NODE_ENV==="production")o=t.call(this,"An error occurred. See https://github.com/styled-components/polished/blob/main/src/internalHelpers/errors.md#"+r+" for more information.")||this;else{for(var n=arguments.length,a=new Array(n>1?n-1:0),i=1;i<n;i++)a[i-1]=arguments[i];o=t.call(this,xm.apply(void 0,[vm[r]].concat(a)))||this}return Iu(o)}return e}(so(Error));function Mu(t,e){return t.substr(-e.length)===e}var Cm=/^([+-]?(?:\d+|\d*\.\d+))([a-z]*|%)$/;function Ru(t){if(typeof t!="string")return t;var e=t.match(Cm);return e?parseFloat(t):t}var wm=function(e){return function(r,o){o===void 0&&(o="16px");var n=r,a=o;if(typeof r=="string"){if(!Mu(r,"px"))throw new de(69,e,r);n=Ru(r)}if(typeof o=="string"){if(!Mu(o,"px"))throw new de(70,e,o);a=Ru(o)}if(typeof n=="string")throw new de(71,r,e);if(typeof a=="string")throw new de(72,o,e);return""+n/a+e}},Bu=wm,fk=Bu("em");var dk=Bu("rem");function ci(t){return Math.round(t*255)}function Sm(t,e,r){return ci(t)+","+ci(e)+","+ci(r)}function wr(t,e,r,o){if(o===void 0&&(o=Sm),e===0)return o(r,r,r);var n=(t%360+360)%360/60,a=(1-Math.abs(2*r-1))*e,i=a*(1-Math.abs(n%2-1)),l=0,s=0,u=0;n>=0&&n<1?(l=a,s=i):n>=1&&n<2?(l=i,s=a):n>=2&&n<3?(s=a,u=i):n>=3&&n<4?(s=i,u=a):n>=4&&n<5?(l=i,u=a):n>=5&&n<6&&(l=a,u=i);var c=r-a/2,d=l+c,f=s+c,m=u+c;return o(d,f,m)}var Du={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"00ffff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"0000ff",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"00ffff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"ff00ff",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"639",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"};function Tm(t){if(typeof t!="string")return t;var e=t.toLowerCase();return Du[e]?"#"+Du[e]:t}var Pm=/^#[a-fA-F0-9]{6}$/,km=/^#[a-fA-F0-9]{8}$/,Im=/^#[a-fA-F0-9]{3}$/,Am=/^#[a-fA-F0-9]{4}$/,pi=/^rgb\(\s*(\d{1,3})\s*(?:,)?\s*(\d{1,3})\s*(?:,)?\s*(\d{1,3})\s*\)$/i,Em=/^rgb(?:a)?\(\s*(\d{1,3})\s*(?:,)?\s*(\d{1,3})\s*(?:,)?\s*(\d{1,3})\s*(?:,|\/)\s*([-+]?\d*[.]?\d+[%]?)\s*\)$/i,Fm=/^hsl\(\s*(\d{0,3}[.]?[0-9]+(?:deg)?)\s*(?:,)?\s*(\d{1,3}[.]?[0-9]?)%\s*(?:,)?\s*(\d{1,3}[.]?[0-9]?)%\s*\)$/i,Mm=/^hsl(?:a)?\(\s*(\d{0,3}[.]?[0-9]+(?:deg)?)\s*(?:,)?\s*(\d{1,3}[.]?[0-9]?)%\s*(?:,)?\s*(\d{1,3}[.]?[0-9]?)%\s*(?:,|\/)\s*([-+]?\d*[.]?\d+[%]?)\s*\)$/i;function mt(t){if(typeof t!="string")throw new de(3);var e=Tm(t);if(e.match(Pm))return{red:parseInt(""+e[1]+e[2],16),green:parseInt(""+e[3]+e[4],16),blue:parseInt(""+e[5]+e[6],16)};if(e.match(km)){var r=parseFloat((parseInt(""+e[7]+e[8],16)/255).toFixed(2));return{red:parseInt(""+e[1]+e[2],16),green:parseInt(""+e[3]+e[4],16),blue:parseInt(""+e[5]+e[6],16),alpha:r}}if(e.match(Im))return{red:parseInt(""+e[1]+e[1],16),green:parseInt(""+e[2]+e[2],16),blue:parseInt(""+e[3]+e[3],16)};if(e.match(Am)){var o=parseFloat((parseInt(""+e[4]+e[4],16)/255).toFixed(2));return{red:parseInt(""+e[1]+e[1],16),green:parseInt(""+e[2]+e[2],16),blue:parseInt(""+e[3]+e[3],16),alpha:o}}var n=pi.exec(e);if(n)return{red:parseInt(""+n[1],10),green:parseInt(""+n[2],10),blue:parseInt(""+n[3],10)};var a=Em.exec(e.substring(0,50));if(a)return{red:parseInt(""+a[1],10),green:parseInt(""+a[2],10),blue:parseInt(""+a[3],10),alpha:parseFloat(""+a[4])>1?parseFloat(""+a[4])/100:parseFloat(""+a[4])};var i=Fm.exec(e);if(i){var l=parseInt(""+i[1],10),s=parseInt(""+i[2],10)/100,u=parseInt(""+i[3],10)/100,c="rgb("+wr(l,s,u)+")",d=pi.exec(c);if(!d)throw new de(4,e,c);return{red:parseInt(""+d[1],10),green:parseInt(""+d[2],10),blue:parseInt(""+d[3],10)}}var f=Mm.exec(e.substring(0,50));if(f){var m=parseInt(""+f[1],10),h=parseInt(""+f[2],10)/100,p=parseInt(""+f[3],10)/100,y="rgb("+wr(m,h,p)+")",v=pi.exec(y);if(!v)throw new de(4,e,y);return{red:parseInt(""+v[1],10),green:parseInt(""+v[2],10),blue:parseInt(""+v[3],10),alpha:parseFloat(""+f[4])>1?parseFloat(""+f[4])/100:parseFloat(""+f[4])}}throw new de(5)}function Rm(t){var e=t.red/255,r=t.green/255,o=t.blue/255,n=Math.max(e,r,o),a=Math.min(e,r,o),i=(n+a)/2;if(n===a)return t.alpha!==void 0?{hue:0,saturation:0,lightness:i,alpha:t.alpha}:{hue:0,saturation:0,lightness:i};var l,s=n-a,u=i>.5?s/(2-n-a):s/(n+a);switch(n){case e:l=(r-o)/s+(r<o?6:0);break;case r:l=(o-e)/s+2;break;default:l=(e-r)/s+4;break}return l*=60,t.alpha!==void 0?{hue:l,saturation:u,lightness:i,alpha:t.alpha}:{hue:l,saturation:u,lightness:i}}function nt(t){return Rm(mt(t))}var Dm=function(e){return e.length===7&&e[1]===e[2]&&e[3]===e[4]&&e[5]===e[6]?"#"+e[1]+e[3]+e[5]:e},di=Dm;function dt(t){var e=t.toString(16);return e.length===1?"0"+e:e}function fi(t){return dt(Math.round(t*255))}function Om(t,e,r){return di("#"+fi(t)+fi(e)+fi(r))}function lo(t,e,r){return wr(t,e,r,Om)}function Bm(t,e,r){if(typeof t=="number"&&typeof e=="number"&&typeof r=="number")return lo(t,e,r);if(typeof t=="object"&&e===void 0&&r===void 0)return lo(t.hue,t.saturation,t.lightness);throw new de(1)}function Lm(t,e,r,o){if(typeof t=="number"&&typeof e=="number"&&typeof r=="number"&&typeof o=="number")return o>=1?lo(t,e,r):"rgba("+wr(t,e,r)+","+o+")";if(typeof t=="object"&&e===void 0&&r===void 0&&o===void 0)return t.alpha>=1?lo(t.hue,t.saturation,t.lightness):"rgba("+wr(t.hue,t.saturation,t.lightness)+","+t.alpha+")";throw new de(2)}function mi(t,e,r){if(typeof t=="number"&&typeof e=="number"&&typeof r=="number")return di("#"+dt(t)+dt(e)+dt(r));if(typeof t=="object"&&e===void 0&&r===void 0)return di("#"+dt(t.red)+dt(t.green)+dt(t.blue));throw new de(6)}function uo(t,e,r,o){if(typeof t=="string"&&typeof e=="number"){var n=mt(t);return"rgba("+n.red+","+n.green+","+n.blue+","+e+")"}else{if(typeof t=="number"&&typeof e=="number"&&typeof r=="number"&&typeof o=="number")return o>=1?mi(t,e,r):"rgba("+t+","+e+","+r+","+o+")";if(typeof t=="object"&&e===void 0&&r===void 0&&o===void 0)return t.alpha>=1?mi(t.red,t.green,t.blue):"rgba("+t.red+","+t.green+","+t.blue+","+t.alpha+")"}throw new de(7)}var $m=function(e){return typeof e.red=="number"&&typeof e.green=="number"&&typeof e.blue=="number"&&(typeof e.alpha!="number"||typeof e.alpha>"u")},zm=function(e){return typeof e.red=="number"&&typeof e.green=="number"&&typeof e.blue=="number"&&typeof e.alpha=="number"},_m=function(e){return typeof e.hue=="number"&&typeof e.saturation=="number"&&typeof e.lightness=="number"&&(typeof e.alpha!="number"||typeof e.alpha>"u")},Nm=function(e){return typeof e.hue=="number"&&typeof e.saturation=="number"&&typeof e.lightness=="number"&&typeof e.alpha=="number"};function it(t){if(typeof t!="object")throw new de(8);if(zm(t))return uo(t);if($m(t))return mi(t);if(Nm(t))return Lm(t);if(_m(t))return Bm(t);throw new de(8)}function Lu(t,e,r){return function(){var n=r.concat(Array.prototype.slice.call(arguments));return n.length>=e?t.apply(this,n):Lu(t,e,n)}}function be(t){return Lu(t,t.length,[])}function Vm(t,e){if(e==="transparent")return e;var r=nt(e);return it(ue({},r,{hue:r.hue+parseFloat(t)}))}var mk=be(Vm);function Vt(t,e,r){return Math.max(t,Math.min(e,r))}function Wm(t,e){if(e==="transparent")return e;var r=nt(e);return it(ue({},r,{lightness:Vt(0,1,r.lightness-parseFloat(t))}))}var hk=be(Wm);function Hm(t,e){if(e==="transparent")return e;var r=nt(e);return it(ue({},r,{saturation:Vt(0,1,r.saturation-parseFloat(t))}))}var gk=be(Hm);function Ou(t){if(t==="transparent")return 0;var e=mt(t),r=Object.keys(e).map(function(i){var l=e[i]/255;return l<=.03928?l/12.92:Math.pow((l+.055)/1.055,2.4)}),o=r[0],n=r[1],a=r[2];return parseFloat((.2126*o+.7152*n+.0722*a).toFixed(3))}function $u(t,e){var r=Ou(t),o=Ou(e);return parseFloat((r>o?(r+.05)/(o+.05):(o+.05)/(r+.05)).toFixed(2))}function Gm(t,e){if(e==="transparent")return e;var r=nt(e);return it(ue({},r,{lightness:Vt(0,1,r.lightness+parseFloat(t))}))}var yk=be(Gm);function jm(t,e,r){if(e==="transparent")return r;if(r==="transparent")return e;if(t===0)return r;var o=mt(e),n=ue({},o,{alpha:typeof o.alpha=="number"?o.alpha:1}),a=mt(r),i=ue({},a,{alpha:typeof a.alpha=="number"?a.alpha:1}),l=n.alpha-i.alpha,s=parseFloat(t)*2-1,u=s*l===-1?s:s+l,c=1+s*l,d=(u/c+1)/2,f=1-d,m={red:Math.floor(n.red*d+i.red*f),green:Math.floor(n.green*d+i.green*f),blue:Math.floor(n.blue*d+i.blue*f),alpha:n.alpha*parseFloat(t)+i.alpha*(1-parseFloat(t))};return uo(m)}var Um=be(jm),zu=Um;function qm(t,e){if(e==="transparent")return e;var r=mt(e),o=typeof r.alpha=="number"?r.alpha:1,n=ue({},r,{alpha:Vt(0,1,(o*100+parseFloat(t)*100)/100)});return uo(n)}var bk=be(qm);function Ym(t,e){if(e==="transparent")return e;var r=nt(e);return it(ue({},r,{saturation:Vt(0,1,r.saturation+parseFloat(t))}))}var vk=be(Ym);function Km(t,e){return e==="transparent"?e:it(ue({},nt(e),{hue:parseFloat(t)}))}var xk=be(Km);function Zm(t,e){return e==="transparent"?e:it(ue({},nt(e),{lightness:parseFloat(t)}))}var Ck=be(Zm);function Qm(t,e){return e==="transparent"?e:it(ue({},nt(e),{saturation:parseFloat(t)}))}var wk=be(Qm);function Jm(t,e){return e==="transparent"?e:zu(parseFloat(t),"rgb(0, 0, 0)",e)}var Sk=be(Jm);function Xm(t,e){return e==="transparent"?e:zu(parseFloat(t),"rgb(255, 255, 255)",e)}var Tk=be(Xm);function eh(t,e){if(e==="transparent")return e;var r=mt(e),o=typeof r.alpha=="number"?r.alpha:1,n=ue({},r,{alpha:Vt(0,1,+(o*100-parseFloat(t)*100).toFixed(2)/100)});return uo(n)}var Pk=be(eh);import{alpha as th,createTheme as rh,responsiveFontSizes as oh}from"@mui/material/styles";var ht="#05b5e6",nh="#05b5e6",ie={32:"2rem",28:"1.75rem",24:"1.5",20:"1.25rem",16:"1rem",14:"0.875rem",12:"0.75rem",10:"0.625rem"},Pe={800:"#202024",700:"#262626",600:"#333333",500:"#808080",400:"#BBBBBA",300:"#E0E0E0",200:"#F2F2F2",100:"#FAFAFA"},ih={cssVariables:!0,mixins:{toolbar:{height:48},menu:{width:260}},palette:{situacao:{aberto:"#FFFF00",fechado:"#FFA500",orcamento:"#800080",analise:"#0000FF",cancelado:"#FF0000",liberado:"#008000"},border:"rgba(0, 0, 0, 0.23)",text:{primary:"#262626",secondary:"#808080"},primary:{light:"#66D1E6",main:ht,dark:nh},secondary:{light:"#eceff1",main:"#13143F",dark:"#263238"},background:{default:"#FFF",paper:"#F4F4F4"},error:{main:"#F44336",dark:"#BE0D00",light:"#FF6C5F"},warning:{main:"#FFCD38",dark:"#C29000",light:"#FFED58"},success:{main:"#4CAF50",dark:"#187B1C",light:"#7DE081"},grey:{800:Pe[800],700:Pe[700],600:Pe[600],500:Pe[500],400:Pe[400],300:Pe[300],200:Pe[200],100:Pe[100]}},typography:{fontFamily:["Roboto","Lato","sans-serif","Poppins","Montserrat"].join(","),h1:{fontSize:ie[32],fontWeight:400,color:"#262626"},h2:{fontSize:ie[28],fontWeight:400,color:"#262626"},h3:{fontSize:ie[24],fontWeight:400,color:"#262626"},h4:{fontSize:ie[20],fontWeight:400,color:"#262626"},h5:{fontSize:ie[16],fontWeight:400,color:"#262626"},h6:{fontSize:ie[14],fontWeight:500,color:"#262626"},subtitle1:{fontSize:ie[14],fontWeight:400,color:"#262626"},subtitle2:{fontSize:ie[12],fontWeight:500,color:Pe[500]},body1:{fontSize:ie[14],fontWeight:400,color:"#262626"},body2:{fontSize:ie[12],fontWeight:400,color:"#808080"},caption:{fontSize:ie[12],fontWeight:400,color:"#808080"},overline:{fontSize:ie[10],fontWeight:400,textTransform:"uppercase",color:"#808080"}},components:{MuiTabs:{styleOverrides:{root:{minHeight:"30px"}}},MuiTab:{styleOverrides:{root:{minHeight:"30px",height:"30px",textTransform:"none",fontWeight:"400",fontSize:ie[12],"& .MuiTab-iconWrapper":{fontSize:ie[16]}}}},MuiList:{styleOverrides:{root:{paddingTop:0}}},MuiListItemButton:{styleOverrides:{root:{"&.Mui-selected":{backgroundColor:th(ht,.1),boxShadow:`inset 0 0 0 0.5px ${ht}`,borderRadius:"4px","& .MuiTypography-root":{color:ht,fontWeight:500},"& .MuiListItemIcon-root svg":{strokeWidth:2,color:ht}},":hover":{background:"rgba(89, 195, 224, 15%)",borderRadius:"4px"}}}},MuiToolbar:{defaultProps:{sx:{minHeight:"46px"}},styleOverrides:{root:{background:"#FFFFFF"}}},MuiChip:{defaultProps:{size:"small"}},MuiContainer:{defaultProps:{maxWidth:!1,disableGutters:!0},styleOverrides:{root:{display:"flex",flexDirection:"column",flexGrow:1}}},MuiButton:{defaultProps:{size:"small",variant:"outlined"},styleOverrides:{root:{fontSize:"0.755rem",textTransform:"none",fontWeight:"bold",minWidth:"78px"},contained:{color:"rgba(255,255,255,0.85)",boxShadow:"none"},outlined:{background:"white",":disabled":{background:"none",boxShadow:"none",borderColor:"#E0E0E0"}}}},MuiCheckbox:{defaultProps:{size:"small"}},MuiFormControl:{defaultProps:{size:"small"},styleOverrides:{root:{}}},MuiInputBase:{styleOverrides:{root:{fontSize:ie[12],height:"auto",minHeight:"28px","&.MuiInputBase-sizeSmall":{"& .MuiOutlinedInput-input":{padding:"3.5px 14px"}},"&.MuiInputBase-multiline.MuiInputBase-sizeSmall":{height:"auto",padding:0,"& .MuiOutlinedInput-input":{padding:"8.5px 14px"}}}}},MuiTextField:{defaultProps:{size:"small",fullWidth:!0,InputLabelProps:{shrink:!0}},styleOverrides:{root:{"& label":{color:Pe[500],fontSize:"13px"},"& .MuiInputBase-root":{backgroundColor:"#fff"},"& .MuiInputBase-input[readonly]":{backgroundColor:Pe[200],color:Pe[700]}}}},MuiAutocomplete:{defaultProps:{size:"small"},styleOverrides:{inputRoot:{fontSize:"14px","& .MuiOutlinedInput-input":{padding:"3.5px 14px"}},root:{"& .MuiOutlinedInput-root.MuiInputBase-sizeSmall":{padding:"0 12px"},"& .MuiOutlinedInput-root.MuiInputBase-sizeSmall .MuiAutocomplete-input":{padding:0}}}},MuiInputLabel:{styleOverrides:{root:{fontSize:ie[14]}}},MuiSvgIcon:{defaultProps:{fontSize:"small",color:"inherit"}},MuiIconButton:{defaultProps:{size:"small"},styleOverrides:{root:{}}},MuiPopover:{styleOverrides:{paper:{borderRadius:"12px"}}},MuiMenuItem:{styleOverrides:{root:{"&.Mui-selected":{"& .MuiIcon-root":{color:ht},"& .MuiTypography-root":{color:ht}},":hover":{borderRadius:"6px",background:"rgba(89, 195, 224, 15%)"}}}},MuiBadge:{styleOverrides:{root:{"& .MuiBadge-anchorOriginBottomLeft":{height:"16px",top:8}},badge:{fontSize:"8pt"}}},MuiTableCell:{styleOverrides:{root:{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",padding:0,"&.selected":{backgroundColor:"#199"}},head:{backgroundColor:"#FAFAFA",border:"1px solid #D0D0D0",color:"#808080","& span":{color:"#808080"},"& div":{marginLeft:"4px"}},body:{backgroundColor:"#ffffff00",border:"1px solid #D0D0D0",borderTop:"none",borderBottom:"none","& > div":{fontSize:"9pt",paddingLeft:"6px",paddingRight:"6px",paddingTop:"2px",paddingBottom:"2px"}}}},MuiTableRow:{styleOverrides:{root:{backgroundColor:"#FFFFFF",height:"30px","&.MuiTableRow-hover":{"&:hover":{backgroundColor:"#ffffde"}}},head:{borderRadius:"4px","& div":{fontWeight:"600",fontSize:"13px",padding:"2px"}}}},MUIDataTableHeadCell:{styleOverrides:{toolButton:{height:"48px"}}},MUIDataTableBodyRow:{styleOverrides:{root:{"&:hover":{backgroundColor:"#333"},"&:nth-of-type(even)":{backgroundColor:"#F5F5F5"},"&:last-child":{borderBottom:"1px solid #D0D0D0"}}}},MuiTableHead:{styleOverrides:{root:{height:"48px"}}},MuiPaper:{styleOverrides:{root:{background:"#FFFFFF"}}},MuiDrawer:{styleOverrides:{paper:{}}},MuiDialog:{styleOverrides:{paper:{borderRadius:"6px"}}},MuiDialogContent:{styleOverrides:{root:{}}}}},ah=rh(ih),sh=oh(ah),N=sh;import{Fragment as ch,jsx as co,jsxs as uh}from"react/jsx-runtime";var lh={"primary-light":N.palette.primary.light,primary:N.palette.primary.main,"primary-dark":N.palette.primary.dark,"text-secondary":N.palette.text.secondary,"text-primary":N.palette.text.primary,"background-paper":N.palette.background.paper,background:N.palette.background.default,"error-light":N.palette.error.light,error:N.palette.error.main,"erro-drark":N.palette.error.dark,"warning-light":N.palette.warning.light,warning:N.palette.warning.main,"warning-dark":N.palette.warning.dark,"success-light":N.palette.success.light,success:N.palette.success.main,"success-dark":N.palette.success.dark,"grey-100":N.palette.grey[100],"grey-200":N.palette.grey[200],"grey-300":N.palette.grey[300],"grey-400":N.palette.grey[400],"grey-500":N.palette.grey[500],"grey-600":N.palette.grey[600],"grey-700":N.palette.grey[700],"grey-800":N.palette.grey[800]};function Nu(){return co(ch,{children:Object.entries(lh).map(([t,e])=>co(_u,{sx:{backgroundColor:e,padding:"2rem"},children:uh(_u,{sx:{display:"flex",justifyContent:"space-between",fontFamily:N.typography.fontFamily,color:$u(e,"#FFF")<3.5?"#000":"#FFF"},children:[co("strong",{children:t}),co("span",{children:e})]})},t))})}import{Box as po,IconButton as fo,Icon as Hu,Badge as xh}from"@mui/material";import{Edit as Gu,Delete as ju,GetApp as Uu}from"@mui/icons-material";import{Tooltip as ph,tooltipClasses as fh,Box as hi,Icon as dh,Typography as mh,Divider as hh}from"@mui/material";import{styled as gh}from"@mui/material/styles";import{jsx as gt,jsxs as Vu}from"react/jsx-runtime";var yh=gh(({className:t,...e})=>gt(ph,{...e,classes:{popper:t}}))(({theme:t})=>({[`& .${fh.tooltip}`]:{backgroundColor:"#f5f5f9",color:"rgba(0, 0, 0, 0.87)",maxWidth:320,minWidth:180,fontSize:t.typography.pxToRem(12),border:"1px solid #dadde9"}})),bh={info:"Informa\xE7\xE3o",warning:"Aten\xE7\xE3o"},vh=t=>{let{title:e,type:r}=t;return Vu(hi,{sx:{mt:.5},children:[Vu(hi,{sx:{display:"flex",flexDirection:"row",alignItems:"center",alignContent:"center"},children:[gt(dh,{color:r,fontSize:"small",children:r})," ",gt(mh,{variant:"subtitle2",sx:{ml:.5},children:bh[r]})]}),gt(hh,{sx:{mt:.5}}),gt(hi,{sx:{mt:1},children:e})]})},Wu=t=>{let{type:e,children:r,title:o,...n}=t;return gt(yh,{arrow:!0,title:gt(vh,{title:o||"",type:e}),enterDelay:300,...n,children:r})};Wu.defaultProps={type:"info"};var Wt=Wu;import{jsx as ae,jsxs as Sr}from"react/jsx-runtime";var Gk=()=>({style:{width:"80px",textAlign:"center"}}),jk=()=>({style:{width:"128px",textAlign:"right"}});function gi(t){let{onClick:e,value:r,extraOptions:o,displayUpdateButton:n,displayDeleteButton:a,displayTransporterButton:i,disableTooltip:l,disabled:s,disabledUpdateButton:u,disabledDeleteButton:c,disabledTransporterButton:d}=t;return Sr(po,{children:[o&&o.map(({id:f,icon:m,iconButtonProps:h,tooltip:p,visible:y,disabled:v,badge:b})=>y===null||!!y&&ae(xh,{color:"primary",badgeContent:b,children:Sr(fo,{onClick:S=>e(f,r,S),size:"small",disabled:v,...h,children:[p&&ae(Wt,{type:p.type,title:p.content,children:ae(Hu,{fontSize:"small",children:m})}),!p&&ae(Hu,{fontSize:"small",children:m})]},f)})),i&&Sr(fo,{size:"small",onClick:f=>e("transport",r,f),color:"primary",disabled:s||d,children:[l&&ae(Uu,{fontSize:"small"}),!l&&ae(Wt,{type:"warning",title:ae(po,{children:"Clique para transportar este registro."}),children:ae(Uu,{fontSize:"small"})})]}),n&&Sr(fo,{size:"small",color:"primary",onClick:f=>e("edit",r,f),disabled:s||u,children:[l&&ae(Gu,{fontSize:"small"}),!l&&ae(Wt,{type:"info",title:ae(po,{children:"Clique para editar este registro."}),children:ae(Gu,{fontSize:"small"})})]}),a&&Sr(fo,{size:"small",onClick:f=>e("delete",r,f),color:"primary",disabled:s||c,children:[l&&ae(ju,{fontSize:"small"}),!l&&ae(Wt,{type:"warning",title:ae(po,{children:"Clique para excluir este registro."}),children:ae(ju,{fontSize:"small"})})]})]})}gi.defaultProps={displayUpdateButton:!0,displayDeleteButton:!0,displayTransporterButton:!1,disableTooltip:!0};import{Box as yi,Chip as qu,IconButton as Ch}from"@mui/material";import{RestartAlt as wh}from"@mui/icons-material";import{useFilterData as Sh,useFilterApi as Th}from"@data-c/providers";import{useCallback as Ph,useMemo as kh}from"react";import{jsx as Ht,jsxs as Ih}from"react/jsx-runtime";function mo(t){let{renderLabel:e,disableds:r}=t,{deleteFilterValue:o,deleteAllFilterValues:n}=Th(),{filterValues:a,appliedValues:i}=Sh(),l=kh(()=>{if(Object.keys(i||{}).length>0){let c=!1,d=Object.keys(i||{});for(let f=0;f<d.length;f++){let m=i[d[f]];if(Array.isArray(m)&&m.length>0){c=!0;break}else if(!Array.isArray(m)&&m){c=!0;break}}return c}return!1},[i]),s=Ph(u=>e?e(a[u].label,i[u]):`${a[u].label} - ${i&&i[u]}`,[e,a,i]);return Ih(yi,{sx:{display:"flex",flexDirection:"row",justifyContent:"space-between"},children:[Ht(yi,{sx:{display:"flex",flexWrap:"wrap",alignItems:"center",justifyContent:"flex-end",gap:1},children:l&&Object.keys(i||{}).map(u=>{let c=Array.isArray(r)&&r.includes(u),d;if(c||(d=()=>{o&&o(u)}),Array.isArray(i[u])&&i[u].length>0)return Ht(qu,{size:"small",label:s(u),onDelete:d,variant:"outlined"},u);if(!Array.isArray(i[u])&&i[u])return Ht(qu,{size:"small",label:s(u),onDelete:d,variant:"outlined"},u)})}),l&&Ht(yi,{sx:{mr:.5,ml:.5,display:"flex",alignContent:"center",alignItems:"center"},children:Ht(Ch,{onClick:()=>{n&&n()},children:Ht(wh,{fontSize:"small",color:"error"})})})]})}import{useEffect as Dh}from"react";import{useFilterApi as Ci,useFilterData as Oh}from"@data-c/providers";import{RestartAlt as Bh,Search as Ku}from"@mui/icons-material";import{Box as Lh,Button as xi,Stack as $h}from"@mui/material";import{Box as bi,Stack as Yu,Drawer as Ah,Typography as Eh,IconButton as Fh,Toolbar as Mh}from"@mui/material";import{Cancel as Rh}from"@mui/icons-material";import{jsx as yt,jsxs as vi}from"react/jsx-runtime";function ho(t){let{drawerTitle:e,actions:r,onClose:o,children:n,...a}=t;return yt(Ah,{PaperProps:{style:{borderRadius:"12px 0 0 12px"}},onClose:o,...a,children:vi(Yu,{sx:{width:"360px",height:"100%",justifyContent:"space-between",backgroundColor:i=>i.palette.background.paper},children:[vi(Yu,{children:[yt(Mh,{}),vi(bi,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",alignContent:"center",height:"48px",borderBottom:i=>`solid 1px ${i.palette.grey[300]}`},children:[yt(Eh,{component:"h1",variant:"h5",sx:{pl:i=>i.spacing(2)},children:e}),o&&yt(Fh,{onClick:o,children:yt(Rh,{color:"error"})})]}),yt(bi,{sx:{padding:i=>i.spacing(2)},children:n})]}),r&&yt(bi,{sx:{pt:i=>i.spacing(1),pb:i=>i.spacing(1),pl:i=>i.spacing(2),pr:i=>i.spacing(2),borderTop:i=>`solid 1px ${i.palette.grey[300]}`},children:r})]})})}ho.defaultProps={anchor:"right"};import{Fragment as Nh,jsx as at,jsxs as Tr}from"react/jsx-runtime";var zh=()=>{let{applyFilterValues:t,closeFilter:e,deleteAllFilterValues:r}=Ci();function o(){e()}function n(){t(),e()}function a(){r&&(r(),e())}return Tr($h,{sx:{flexDirection:"row",justifyContent:"flex-end","& > button:first-child":{mr:1}},children:[Tr(xi,{fullWidth:!0,onClick:a,color:"error",children:[at(Bh,{})," Redefinir Padr\xE3o"]}),Tr(xi,{fullWidth:!0,variant:"contained",onClick:n,children:[at(Ku,{})," Aplicar"]})]})},_h=t=>{let{title:e,children:r,onApplyFilters:o,drawerProps:n}=t,{isOpen:a,appliedValues:i}=Oh(),{closeFilter:l}=Ci();return Dh(()=>{o&&o(i)},[i]),at(ho,{...n,drawerTitle:e,open:a,children:r,onClose:()=>l(),actions:at(zh,{})})};function wi(t){let{triggerButtonLabel:e,triggerButtonProps:r,triggerButton:o,title:n,children:a,onApplyFilters:i,renderLabel:l,disableds:s,disableFilterControl:u,drawerProps:c}=t,{openFilter:d}=Ci(),f=o==="none"?null:o||at(xi,{variant:"contained",onClick:()=>{d()},...r,children:e||"Adicionar"});return Tr(Nh,{children:[u&&f,!u&&Tr(Lh,{sx:{display:"flex",direction:"row",justifyContent:"flex-end",alignItems:"center",alignContent:"center"},children:[at(mo,{renderLabel:l,disableds:s}),f]}),at(_h,{...c,onApplyFilters:i,title:n||"",children:a})]})}wi.defaultProps={triggerButtonLabel:"Aplicar",triggerButtonProps:{variant:"contained",startIcon:at(Ku,{})},title:"Aplicar"};import{Circle as Vh}from"@mui/icons-material";import{jsx as Wh}from"react/jsx-runtime";function Zu(t){let{isFlagged:e,type:r}=t;return e?Wh(Vh,{color:r,sx:{fontSize:"10pt"}}):null}import{Box as qc,Divider as A0,styled as E0,Typography as F0}from"@mui/material";function Gt(t,...e){let r=new URL(`https://mui.com/production-error/?code=${t}`);return e.forEach(o=>r.searchParams.append("args[]",o)),`Minified MUI error #${t}; visit ${r} for the full message.`}import sg from"@emotion/styled";function Qu(t){for(var e=0,r,o=0,n=t.length;n>=4;++o,n-=4)r=t.charCodeAt(o)&255|(t.charCodeAt(++o)&255)<<8|(t.charCodeAt(++o)&255)<<16|(t.charCodeAt(++o)&255)<<24,r=(r&65535)*1540483477+((r>>>16)*59797<<16),r^=r>>>24,e=(r&65535)*1540483477+((r>>>16)*59797<<16)^(e&65535)*1540483477+((e>>>16)*59797<<16);switch(n){case 3:e^=(t.charCodeAt(o+2)&255)<<16;case 2:e^=(t.charCodeAt(o+1)&255)<<8;case 1:e^=t.charCodeAt(o)&255,e=(e&65535)*1540483477+((e>>>16)*59797<<16)}return e^=e>>>13,e=(e&65535)*1540483477+((e>>>16)*59797<<16),((e^e>>>15)>>>0).toString(36)}var Ju={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 Xu(t){var e=Object.create(null);return function(r){return e[r]===void 0&&(e[r]=t(r)),e[r]}}var Hh=!1,Gh=/[A-Z]|^ms/g,jh=/_EMO_([^_]+?)_([^]*?)_EMO_/g,oc=function(e){return e.charCodeAt(1)===45},ec=function(e){return e!=null&&typeof e!="boolean"},Si=Xu(function(t){return oc(t)?t:t.replace(Gh,"-$&").toLowerCase()}),tc=function(e,r){switch(e){case"animation":case"animationName":if(typeof r=="string")return r.replace(jh,function(o,n,a){return Ne={name:n,styles:a,next:Ne},n})}return Ju[e]!==1&&!oc(e)&&typeof r=="number"&&r!==0?r+"px":r},Uh="Component selectors can only be used in conjunction with @emotion/babel-plugin, the swc Emotion plugin, or another Emotion-aware compiler transform.";function Pr(t,e,r){if(r==null)return"";var o=r;if(o.__emotion_styles!==void 0)return o;switch(typeof r){case"boolean":return"";case"object":{var n=r;if(n.anim===1)return Ne={name:n.name,styles:n.styles,next:Ne},n.name;var a=r;if(a.styles!==void 0){var i=a.next;if(i!==void 0)for(;i!==void 0;)Ne={name:i.name,styles:i.styles,next:Ne},i=i.next;var l=a.styles+";";return l}return qh(t,e,r)}case"function":{if(t!==void 0){var s=Ne,u=r(t);return Ne=s,Pr(t,e,u)}break}}var c=r;if(e==null)return c;var d=e[c];return d!==void 0?d:c}function qh(t,e,r){var o="";if(Array.isArray(r))for(var n=0;n<r.length;n++)o+=Pr(t,e,r[n])+";";else for(var a in r){var i=r[a];if(typeof i!="object"){var l=i;e!=null&&e[l]!==void 0?o+=a+"{"+e[l]+"}":ec(l)&&(o+=Si(a)+":"+tc(a,l)+";")}else{if(a==="NO_COMPONENT_SELECTOR"&&Hh)throw new Error(Uh);if(Array.isArray(i)&&typeof i[0]=="string"&&(e==null||e[i[0]]===void 0))for(var s=0;s<i.length;s++)ec(i[s])&&(o+=Si(a)+":"+tc(a,i[s])+";");else{var u=Pr(t,e,i);switch(a){case"animation":case"animationName":{o+=Si(a)+":"+u+";";break}default:o+=a+"{"+u+"}"}}}}return o}var rc=/label:\s*([^\s;{]+)\s*(;|$)/g,Ne;function nc(t,e,r){if(t.length===1&&typeof t[0]=="object"&&t[0]!==null&&t[0].styles!==void 0)return t[0];var o=!0,n="";Ne=void 0;var a=t[0];if(a==null||a.raw===void 0)o=!1,n+=Pr(r,e,a);else{var i=a;n+=i[0]}for(var l=1;l<t.length;l++)if(n+=Pr(r,e,t[l]),o){var s=a;n+=s[l]}rc.lastIndex=0;for(var u="",c;(c=rc.exec(n))!==null;)u+="-"+c[1];var d=Qu(n)+u;return{name:d,styles:n,next:Ne}}import{ThemeContext as Ec,keyframes as UI,css as qI}from"@emotion/react";function Di(t,e){let r=sg(t,e);return process.env.NODE_ENV!=="production"?(...o)=>{let n=typeof t=="string"?`"${t}"`:"component";return o.length===0?console.error([`MUI: Seems like you called \`styled(${n})()\` without a \`style\` argument.`,'You must provide a `styles` argument: `styled("div")(styleYouForgotToPass)`.'].join(`
151
+ `)):o.some(a=>a===void 0)&&console.error(`MUI: the styled(${n})(...args) API requires all its args to be defined.`),r(...o)}:r}function Ac(t,e){Array.isArray(t.__emotion_styles)&&(t.__emotion_styles=e(t.__emotion_styles))}var Ic=[];function je(t){return Ic[0]=t,nc(Ic)}var _i=rt($i(),1);import*as zi from"react";function Ve(t){if(typeof t!="object"||t===null)return!1;let e=Object.getPrototypeOf(t);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(Symbol.toStringTag in t)&&!(Symbol.iterator in t)}function Rc(t){if(zi.isValidElement(t)||(0,_i.isValidElementType)(t)||!Ve(t))return t;let e={};return Object.keys(t).forEach(r=>{e[r]=Rc(t[r])}),e}function Ie(t,e,r={clone:!0}){let o=r.clone?{...t}:t;return Ve(t)&&Ve(e)&&Object.keys(e).forEach(n=>{zi.isValidElement(e[n])||(0,_i.isValidElementType)(e[n])?o[n]=e[n]:Ve(e[n])&&Object.prototype.hasOwnProperty.call(t,n)&&Ve(t[n])?o[n]=Ie(t[n],e[n],r):r.clone?o[n]=Ve(e[n])?Rc(e[n]):e[n]:o[n]=e[n]}),o}var cg=t=>{let e=Object.keys(t).map(r=>({key:r,val:t[r]}))||[];return e.sort((r,o)=>r.val-o.val),e.reduce((r,o)=>({...r,[o.key]:o.val}),{})};function Ni(t){let{values:e={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:r="px",step:o=5,...n}=t,a=cg(e),i=Object.keys(a);function l(f){return`@media (min-width:${typeof e[f]=="number"?e[f]:f}${r})`}function s(f){return`@media (max-width:${(typeof e[f]=="number"?e[f]:f)-o/100}${r})`}function u(f,m){let h=i.indexOf(m);return`@media (min-width:${typeof e[f]=="number"?e[f]:f}${r}) and (max-width:${(h!==-1&&typeof e[i[h]]=="number"?e[i[h]]:m)-o/100}${r})`}function c(f){return i.indexOf(f)+1<i.length?u(f,i[i.indexOf(f)+1]):l(f)}function d(f){let m=i.indexOf(f);return m===0?l(i[1]):m===i.length-1?s(i[m]):u(f,i[i.indexOf(f)+1]).replace("@media","@media not all and")}return{keys:i,values:a,up:l,down:s,between:u,only:c,not:d,unit:r,...n}}function No(t,e){if(!t.containerQueries)return e;let r=Object.keys(e).filter(o=>o.startsWith("@container")).sort((o,n)=>{let a=/min-width:\s*([0-9.]+)/;return+(o.match(a)?.[1]||0)-+(n.match(a)?.[1]||0)});return r.length?r.reduce((o,n)=>{let a=e[n];return delete o[n],o[n]=a,o},{...e}):e}function Vi(t,e){return e==="@"||e.startsWith("@")&&(t.some(r=>e.startsWith(`@${r}`))||!!e.match(/^@\d/))}function Wi(t,e){let r=e.match(/^@([^/]+)?\/?(.+)?$/);if(!r){if(process.env.NODE_ENV!=="production")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The provided shorthand ${`(${e})`} is invalid. The format should be \`@<breakpoint | number>\` or \`@<breakpoint | number>/<container>\`.
152
+ For example, \`@sm\` or \`@600\` or \`@40rem/sidebar\`.`:Gt(18,`(${e})`));return null}let[,o,n]=r,a=Number.isNaN(+o)?o||0:+o;return t.containerQueries(n).up(a)}function Vo(t){let e=(a,i)=>a.replace("@media",i?`@container ${i}`:"@container");function r(a,i){a.up=(...l)=>e(t.breakpoints.up(...l),i),a.down=(...l)=>e(t.breakpoints.down(...l),i),a.between=(...l)=>e(t.breakpoints.between(...l),i),a.only=(...l)=>e(t.breakpoints.only(...l),i),a.not=(...l)=>{let s=e(t.breakpoints.not(...l),i);return s.includes("not all and")?s.replace("not all and ","").replace("min-width:","width<").replace("max-width:","width>").replace("and","or"):s}}let o={},n=a=>(r(o,a),o);return r(n),{...t,containerQueries:n}}var pg={borderRadius:4},Dc=pg;var qt=rt(Eo(),1),fg=process.env.NODE_ENV!=="production"?qt.default.oneOfType([qt.default.number,qt.default.string,qt.default.object,qt.default.array]):{},xe=fg;function dg(t,e){return e?Ie(t,e,{clone:!1}):t}var Ue=dg;var kr={xs:0,sm:600,md:900,lg:1200,xl:1536},Oc={keys:["xs","sm","md","lg","xl"],up:t=>`@media (min-width:${kr[t]}px)`},mg={containerQueries:t=>({up:e=>{let r=typeof e=="number"?e:kr[e]||e;return typeof r=="number"&&(r=`${r}px`),t?`@container ${t} (min-width:${r})`:`@container (min-width:${r})`}})};function ee(t,e,r){let o=t.theme||{};if(Array.isArray(e)){let a=o.breakpoints||Oc;return e.reduce((i,l,s)=>(i[a.up(a.keys[s])]=r(e[s]),i),{})}if(typeof e=="object"){let a=o.breakpoints||Oc;return Object.keys(e).reduce((i,l)=>{if(Vi(a.keys,l)){let s=Wi(o.containerQueries?o:mg,l);s&&(i[s]=r(e[l],l))}else if(Object.keys(a.values||kr).includes(l)){let s=a.up(l);i[s]=r(e[l],l)}else{let s=l;i[s]=e[s]}return i},{})}return r(e)}function Hi(t={}){return t.keys?.reduce((r,o)=>{let n=t.up(o);return r[n]={},r},{})||{}}function Wo(t,e){return t.reduce((r,o)=>{let n=r[o];return(!n||Object.keys(n).length===0)&&delete r[o],r},e)}function Bc(t,...e){let r=Hi(t),o=[r,...e].reduce((n,a)=>Ie(n,a),{});return Wo(Object.keys(r),o)}function hg(t,e){if(typeof t!="object")return{};let r={},o=Object.keys(e);return Array.isArray(t)?o.forEach((n,a)=>{a<t.length&&(r[n]=!0)}):o.forEach(n=>{t[n]!=null&&(r[n]=!0)}),r}function Ho({values:t,breakpoints:e,base:r}){let o=r||hg(t,e),n=Object.keys(o);if(n.length===0)return t;let a;return n.reduce((i,l,s)=>(Array.isArray(t)?(i[l]=t[s]!=null?t[s]:t[a],a=s):typeof t=="object"?(i[l]=t[l]!=null?t[l]:t[a],a=l):i[l]=t,i),{})}function st(t){if(typeof t!="string")throw new Error(process.env.NODE_ENV!=="production"?"MUI: `capitalize(string)` expects a string argument.":Gt(7));return t.charAt(0).toUpperCase()+t.slice(1)}function Yt(t,e,r=!0){if(!e||typeof e!="string")return null;if(t&&t.vars&&r){let o=`vars.${e}`.split(".").reduce((n,a)=>n&&n[a]?n[a]:null,t);if(o!=null)return o}return e.split(".").reduce((o,n)=>o&&o[n]!=null?o[n]:null,t)}function Ir(t,e,r,o=r){let n;return typeof t=="function"?n=t(r):Array.isArray(t)?n=t[r]||o:n=Yt(t,r)||o,e&&(n=e(n,o,t)),n}function gg(t){let{prop:e,cssProperty:r=t.prop,themeKey:o,transform:n}=t,a=i=>{if(i[e]==null)return null;let l=i[e],s=i.theme,u=Yt(s,o)||{};return ee(i,l,d=>{let f=Ir(u,n,d);return d===f&&typeof d=="string"&&(f=Ir(u,n,`${e}${d==="default"?"":st(d)}`,d)),r===!1?f:{[r]:f}})};return a.propTypes=process.env.NODE_ENV!=="production"?{[e]:xe}:{},a.filterProps=[e],a}var j=gg;function Go(t){let e={};return r=>(e[r]===void 0&&(e[r]=t(r)),e[r])}var yg={m:"margin",p:"padding"},bg={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},Lc={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},vg=Go(t=>{if(t.length>2)if(Lc[t])t=Lc[t];else return[t];let[e,r]=t.split(""),o=yg[e],n=bg[r]||"";return Array.isArray(n)?n.map(a=>o+a):[o+n]}),jo=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],Uo=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],Gi=[...jo,...Uo];function bt(t,e,r,o){let n=Yt(t,e,!0)??r;return typeof n=="number"||typeof n=="string"?a=>typeof a=="string"?a:(process.env.NODE_ENV!=="production"&&typeof a!="number"&&console.error(`MUI: Expected ${o} argument to be a number or a string, got ${a}.`),typeof n=="string"?n.startsWith("var(")&&a===0?0:n.startsWith("var(")&&a===1?n:`calc(${a} * ${n})`:n*a):Array.isArray(n)?a=>{if(typeof a=="string")return a;let i=Math.abs(a);process.env.NODE_ENV!=="production"&&(Number.isInteger(i)?i>n.length-1&&console.error([`MUI: The value provided (${i}) overflows.`,`The supported values are: ${JSON.stringify(n)}.`,`${i} > ${n.length-1}, you need to add the missing values.`].join(`
153
+ `)):console.error([`MUI: The \`theme.${e}\` 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.${e}\` as a number.`].join(`
154
+ `)));let l=n[i];return a>=0?l:typeof l=="number"?-l:typeof l=="string"&&l.startsWith("var(")?`calc(-1 * ${l})`:`-${l}`}:typeof n=="function"?n:(process.env.NODE_ENV!=="production"&&console.error([`MUI: The \`theme.${e}\` value (${n}) is invalid.`,"It should be a number, an array or a function."].join(`
155
+ `)),()=>{})}function Ar(t){return bt(t,"spacing",8,"spacing")}function We(t,e){return typeof e=="string"||e==null?e:t(e)}function xg(t,e){return r=>t.reduce((o,n)=>(o[n]=We(e,r),o),{})}function Cg(t,e,r,o){if(!e.includes(r))return null;let n=vg(r),a=xg(n,o),i=t[r];return ee(t,i,a)}function ji(t,e){let r=Ar(t.theme);return Object.keys(t).map(o=>Cg(t,e,o,r)).reduce(Ue,{})}function K(t){return ji(t,jo)}K.propTypes=process.env.NODE_ENV!=="production"?jo.reduce((t,e)=>(t[e]=xe,t),{}):{};K.filterProps=jo;function Z(t){return ji(t,Uo)}Z.propTypes=process.env.NODE_ENV!=="production"?Uo.reduce((t,e)=>(t[e]=xe,t),{}):{};Z.filterProps=Uo;function $c(t){return ji(t,Gi)}$c.propTypes=process.env.NODE_ENV!=="production"?Gi.reduce((t,e)=>(t[e]=xe,t),{}):{};$c.filterProps=Gi;function Ui(t=8,e=Ar({spacing:t})){if(t.mui)return t;let r=(...o)=>(process.env.NODE_ENV!=="production"&&(o.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${o.length}`)),(o.length===0?[1]:o).map(a=>{let i=e(a);return typeof i=="number"?`${i}px`:i}).join(" "));return r.mui=!0,r}function wg(...t){let e=t.reduce((o,n)=>(n.filterProps.forEach(a=>{o[a]=n}),o),{}),r=o=>Object.keys(o).reduce((n,a)=>e[a]?Ue(n,e[a](o)):n,{});return r.propTypes=process.env.NODE_ENV!=="production"?t.reduce((o,n)=>Object.assign(o,n.propTypes),{}):{},r.filterProps=t.reduce((o,n)=>o.concat(n.filterProps),[]),r}var qe=wg;function Ce(t){return typeof t!="number"?t:`${t}px solid`}function Ae(t,e){return j({prop:t,themeKey:"borders",transform:e})}var Sg=Ae("border",Ce),Tg=Ae("borderTop",Ce),Pg=Ae("borderRight",Ce),kg=Ae("borderBottom",Ce),Ig=Ae("borderLeft",Ce),Ag=Ae("borderColor"),Eg=Ae("borderTopColor"),Fg=Ae("borderRightColor"),Mg=Ae("borderBottomColor"),Rg=Ae("borderLeftColor"),Dg=Ae("outline",Ce),Og=Ae("outlineColor"),Er=t=>{if(t.borderRadius!==void 0&&t.borderRadius!==null){let e=bt(t.theme,"shape.borderRadius",4,"borderRadius"),r=o=>({borderRadius:We(e,o)});return ee(t,t.borderRadius,r)}return null};Er.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:xe}:{};Er.filterProps=["borderRadius"];var KA=qe(Sg,Tg,Pg,kg,Ig,Ag,Eg,Fg,Mg,Rg,Er,Dg,Og);var Fr=t=>{if(t.gap!==void 0&&t.gap!==null){let e=bt(t.theme,"spacing",8,"gap"),r=o=>({gap:We(e,o)});return ee(t,t.gap,r)}return null};Fr.propTypes=process.env.NODE_ENV!=="production"?{gap:xe}:{};Fr.filterProps=["gap"];var Mr=t=>{if(t.columnGap!==void 0&&t.columnGap!==null){let e=bt(t.theme,"spacing",8,"columnGap"),r=o=>({columnGap:We(e,o)});return ee(t,t.columnGap,r)}return null};Mr.propTypes=process.env.NODE_ENV!=="production"?{columnGap:xe}:{};Mr.filterProps=["columnGap"];var Rr=t=>{if(t.rowGap!==void 0&&t.rowGap!==null){let e=bt(t.theme,"spacing",8,"rowGap"),r=o=>({rowGap:We(e,o)});return ee(t,t.rowGap,r)}return null};Rr.propTypes=process.env.NODE_ENV!=="production"?{rowGap:xe}:{};Rr.filterProps=["rowGap"];var Bg=j({prop:"gridColumn"}),Lg=j({prop:"gridRow"}),$g=j({prop:"gridAutoFlow"}),zg=j({prop:"gridAutoColumns"}),_g=j({prop:"gridAutoRows"}),Ng=j({prop:"gridTemplateColumns"}),Vg=j({prop:"gridTemplateRows"}),Wg=j({prop:"gridTemplateAreas"}),Hg=j({prop:"gridArea"}),rE=qe(Fr,Mr,Rr,Bg,Lg,$g,zg,_g,Ng,Vg,Wg,Hg);function vt(t,e){return e==="grey"?e:t}var Gg=j({prop:"color",themeKey:"palette",transform:vt}),jg=j({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:vt}),Ug=j({prop:"backgroundColor",themeKey:"palette",transform:vt}),aE=qe(Gg,jg,Ug);function me(t){return t<=1&&t!==0?`${t*100}%`:t}var qg=j({prop:"width",transform:me}),qo=t=>{if(t.maxWidth!==void 0&&t.maxWidth!==null){let e=r=>{let o=t.theme?.breakpoints?.values?.[r]||kr[r];return o?t.theme?.breakpoints?.unit!=="px"?{maxWidth:`${o}${t.theme.breakpoints.unit}`}:{maxWidth:o}:{maxWidth:me(r)}};return ee(t,t.maxWidth,e)}return null};qo.filterProps=["maxWidth"];var Yg=j({prop:"minWidth",transform:me}),Kg=j({prop:"height",transform:me}),Zg=j({prop:"maxHeight",transform:me}),Qg=j({prop:"minHeight",transform:me}),pE=j({prop:"size",cssProperty:"width",transform:me}),fE=j({prop:"size",cssProperty:"height",transform:me}),Jg=j({prop:"boxSizing"}),dE=qe(qg,qo,Yg,Kg,Zg,Qg,Jg);var Xg={border:{themeKey:"borders",transform:Ce},borderTop:{themeKey:"borders",transform:Ce},borderRight:{themeKey:"borders",transform:Ce},borderBottom:{themeKey:"borders",transform:Ce},borderLeft:{themeKey:"borders",transform:Ce},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:Ce},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:Er},color:{themeKey:"palette",transform:vt},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:vt},backgroundColor:{themeKey:"palette",transform:vt},p:{style:Z},pt:{style:Z},pr:{style:Z},pb:{style:Z},pl:{style:Z},px:{style:Z},py:{style:Z},padding:{style:Z},paddingTop:{style:Z},paddingRight:{style:Z},paddingBottom:{style:Z},paddingLeft:{style:Z},paddingX:{style:Z},paddingY:{style:Z},paddingInline:{style:Z},paddingInlineStart:{style:Z},paddingInlineEnd:{style:Z},paddingBlock:{style:Z},paddingBlockStart:{style:Z},paddingBlockEnd:{style:Z},m:{style:K},mt:{style:K},mr:{style:K},mb:{style:K},ml:{style:K},mx:{style:K},my:{style:K},margin:{style:K},marginTop:{style:K},marginRight:{style:K},marginBottom:{style:K},marginLeft:{style:K},marginX:{style:K},marginY:{style:K},marginInline:{style:K},marginInlineStart:{style:K},marginInlineEnd:{style:K},marginBlock:{style:K},marginBlockStart:{style:K},marginBlockEnd:{style:K},displayPrint:{cssProperty:!1,transform:t=>({"@media print":{display:t}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:Fr},rowGap:{style:Rr},columnGap:{style:Mr},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:me},maxWidth:{style:qo},minWidth:{transform:me},height:{transform:me},maxHeight:{transform:me},minHeight:{transform:me},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"}},Kt=Xg;function e0(...t){let e=t.reduce((o,n)=>o.concat(Object.keys(n)),[]),r=new Set(e);return t.every(o=>r.size===Object.keys(o).length)}function t0(t,e){return typeof t=="function"?t(e):t}function r0(){function t(r,o,n,a){let i={[r]:o,theme:n},l=a[r];if(!l)return{[r]:o};let{cssProperty:s=r,themeKey:u,transform:c,style:d}=l;if(o==null)return null;if(u==="typography"&&o==="inherit")return{[r]:o};let f=Yt(n,u)||{};return d?d(i):ee(i,o,h=>{let p=Ir(f,c,h);return h===p&&typeof h=="string"&&(p=Ir(f,c,`${r}${h==="default"?"":st(h)}`,h)),s===!1?p:{[s]:p}})}function e(r){let{sx:o,theme:n={},nested:a}=r||{};if(!o)return null;let i=n.unstable_sxConfig??Kt;function l(s){let u=s;if(typeof s=="function")u=s(n);else if(typeof s!="object")return s;if(!u)return null;let c=Hi(n.breakpoints),d=Object.keys(c),f=c;return Object.keys(u).forEach(m=>{let h=t0(u[m],n);if(h!=null)if(typeof h=="object")if(i[m])f=Ue(f,t(m,h,n,i));else{let p=ee({theme:n},h,y=>({[m]:y}));e0(p,h)?f[m]=e({sx:h,theme:n,nested:!0}):f=Ue(f,p)}else f=Ue(f,t(m,h,n,i))}),!a&&n.modularCssLayers?{"@layer sx":No(n,Wo(d,f))}:No(n,Wo(d,f))}return Array.isArray(o)?o.map(l):l(o)}return e}var zc=r0();zc.filterProps=["sx"];var Zt=zc;function qi(t,e){let r=this;if(r.vars){if(!r.colorSchemes?.[t]||typeof r.getColorSchemeSelector!="function")return{};let o=r.getColorSchemeSelector(t);return o==="&"?e:((o.includes("data-")||o.includes("."))&&(o=`*:where(${o.replace(/\s*&$/,"")}) &`),{[o]:e})}return r.palette.mode===t?e:{}}function o0(t={},...e){let{breakpoints:r={},palette:o={},spacing:n,shape:a={},...i}=t,l=Ni(r),s=Ui(n),u=Ie({breakpoints:l,direction:"ltr",components:{},palette:{mode:"light",...o},spacing:s,shape:{...Dc,...a}},i);return u=Vo(u),u.applyStyles=qi,u=e.reduce((c,d)=>Ie(c,d),u),u.unstable_sxConfig={...Kt,...i?.unstable_sxConfig},u.unstable_sx=function(d){return Zt({sx:d,theme:this})},u}var xt=o0;import*as _c from"react";function n0(t){return Object.keys(t).length===0}function i0(t=null){let e=_c.useContext(Ec);return!e||n0(e)?t:e}var Yi=i0;var a0=xt();function s0(t=a0){return Yi(t)}var Ki=s0;var l0=t=>{let e={systemProps:{},otherProps:{}},r=t?.theme?.unstable_sxConfig??Kt;return Object.keys(t).forEach(o=>{r[o]?e.systemProps[o]=t[o]:e.otherProps[o]=t[o]}),e};function Yo(t){let{sx:e,...r}=t,{systemProps:o,otherProps:n}=l0(r),a;return Array.isArray(e)?a=[o,...e]:typeof e=="function"?a=(...i)=>{let l=e(...i);return Ve(l)?{...o,...l}:o}:a={...o,...e},{...n,sx:a}}var Nc=t=>t,u0=()=>{let t=Nc;return{configure(e){t=e},generate(e){return t(e)},reset(){t=Nc}}},c0=u0(),Zi=c0;function Vc(t){var e,r,o="";if(typeof t=="string"||typeof t=="number")o+=t;else if(typeof t=="object")if(Array.isArray(t)){var n=t.length;for(e=0;e<n;e++)t[e]&&(r=Vc(t[e]))&&(o&&(o+=" "),o+=r)}else for(r in t)t[r]&&(o&&(o+=" "),o+=r);return o}function p0(){for(var t,e,r=0,o="",n=arguments.length;r<n;r++)(t=arguments[r])&&(e=Vc(t))&&(o&&(o+=" "),o+=e);return o}var Ko=p0;var f0={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 Zo(t,e,r="Mui"){let o=f0[e];return o?`${r}-${o}`:`${Zi.generate(t)}-${e}`}var Qo=rt($i(),1);function Hc(t,e=""){return t.displayName||t.name||e}function Wc(t,e,r){let o=Hc(e);return t.displayName||(o!==""?`${r}(${o})`:r)}function Jo(t){if(t!=null){if(typeof t=="string")return t;if(typeof t=="function")return Hc(t,"Component");if(typeof t=="object")switch(t.$$typeof){case Qo.ForwardRef:return Wc(t,t.render,"ForwardRef");case Qo.Memo:return Wc(t,t.type,"memo");default:return}}}function Qi(t){let{variants:e,...r}=t,o={variants:e,style:je(r),isProcessed:!0};return o.style===r||e&&e.forEach(n=>{typeof n.style!="function"&&(n.style=je(n.style))}),o}var d0=xt();function Ji(t){return t!=="ownerState"&&t!=="theme"&&t!=="sx"&&t!=="as"}function Ct(t,e){return e&&t&&typeof t=="object"&&t.styles&&!t.styles.startsWith("@layer")&&(t.styles=`@layer ${e}{${String(t.styles)}}`),t}function m0(t){return t?(e,r)=>r[t]:null}function h0(t,e,r){t.theme=b0(t.theme)?r:t.theme[e]||t.theme}function Xo(t,e,r){let o=typeof e=="function"?e(t):e;if(Array.isArray(o))return o.flatMap(n=>Xo(t,n,r));if(Array.isArray(o?.variants)){let n;if(o.isProcessed)n=r?Ct(o.style,r):o.style;else{let{variants:a,...i}=o;n=r?Ct(je(i),r):i}return Gc(t,o.variants,[n],r)}return o?.isProcessed?r?Ct(je(o.style),r):o.style:r?Ct(je(o),r):o}function Gc(t,e,r=[],o=void 0){let n;e:for(let a=0;a<e.length;a+=1){let i=e[a];if(typeof i.props=="function"){if(n??(n={...t,...t.ownerState,ownerState:t.ownerState}),!i.props(n))continue}else for(let l in i.props)if(t[l]!==i.props[l]&&t.ownerState?.[l]!==i.props[l])continue e;typeof i.style=="function"?(n??(n={...t,...t.ownerState,ownerState:t.ownerState}),r.push(o?Ct(je(i.style(n)),o):i.style(n))):r.push(o?Ct(je(i.style),o):i.style)}return r}function en(t={}){let{themeId:e,defaultTheme:r=d0,rootShouldForwardProp:o=Ji,slotShouldForwardProp:n=Ji}=t;function a(l){h0(l,e,r)}return(l,s={})=>{Ac(l,k=>k.filter(P=>P!==Zt));let{name:u,slot:c,skipVariantsResolver:d,skipSx:f,overridesResolver:m=m0(jc(c)),...h}=s,p=u&&u.startsWith("Mui")||c?"components":"custom",y=d!==void 0?d:c&&c!=="Root"&&c!=="root"||!1,v=f||!1,b=Ji;c==="Root"||c==="root"?b=o:c?b=n:v0(l)&&(b=void 0);let S=Di(l,{shouldForwardProp:b,label:y0(u,c),...h}),w=k=>{if(k.__emotion_real===k)return k;if(typeof k=="function")return function(Q){return Xo(Q,k,Q.theme.modularCssLayers?p:void 0)};if(Ve(k)){let P=Qi(k);return function(z){return P.variants?Xo(z,P,z.theme.modularCssLayers?p:void 0):z.theme.modularCssLayers?Ct(P.style,p):P.style}}return k},C=(...k)=>{let P=[],Q=k.map(w),z=[];if(P.push(a),u&&m&&z.push(function(g){let I=g.theme.components?.[u]?.styleOverrides;if(!I)return null;let F={};for(let E in I)F[E]=Xo(g,I[E],g.theme.modularCssLayers?"theme":void 0);return m(g,F)}),u&&!y&&z.push(function(g){let I=g.theme?.components?.[u]?.variants;return I?Gc(g,I,[],g.theme.modularCssLayers?"theme":void 0):null}),v||z.push(Zt),Array.isArray(Q[0])){let le=Q.shift(),g=new Array(P.length).fill(""),x=new Array(z.length).fill(""),I;I=[...g,...le,...x],I.raw=[...g,...le.raw,...x],P.unshift(I)}let se=[...P,...Q,...z],A=S(...se);return l.muiName&&(A.muiName=l.muiName),process.env.NODE_ENV!=="production"&&(A.displayName=g0(u,c,l)),A};return S.withConfig&&(C.withConfig=S.withConfig),C}}function g0(t,e,r){return t?`${t}${st(e||"")}`:`Styled(${Jo(r)})`}function y0(t,e){let r;return process.env.NODE_ENV!=="production"&&t&&(r=`${t}-${jc(e||"Root")}`),r}function b0(t){for(let e in t)return!1;return!0}function v0(t){return typeof t=="string"&&t.charCodeAt(0)>96}function jc(t){return t&&t.charAt(0).toLowerCase()+t.slice(1)}var x0=en(),Xi=x0;function Dr(t,e,r=!1){let o={...e};for(let n in t)if(Object.prototype.hasOwnProperty.call(t,n)){let a=n;if(a==="components"||a==="slots")o[a]={...t[a],...o[a]};else if(a==="componentsProps"||a==="slotProps"){let i=t[a],l=e[a];if(!l)o[a]=i||{};else if(!i)o[a]=l;else{o[a]={...l};for(let s in i)if(Object.prototype.hasOwnProperty.call(i,s)){let u=s;o[a][u]=Dr(i[u],l[u],r)}}}else a==="className"&&r&&e.className?o.className=Ko(t?.className,e?.className):a==="style"&&r&&e.style?o.style={...t?.style,...e?.style}:o[a]===void 0&&(o[a]=t[a])}return o}function ea(t){let{theme:e,name:r,props:o}=t;return!e||!e.components||!e.components[r]||!e.components[r].defaultProps?o:Dr(e.components[r].defaultProps,o)}function tn({props:t,name:e,defaultTheme:r,themeId:o}){let n=Ki(r);return o&&(n=n[o]||n),ea({theme:n,name:e,props:t})}function rn(t,e,r=void 0){let o={};for(let n in t){let a=t[n],i="",l=!0;for(let s=0;s<a.length;s+=1){let u=a[s];u&&(i+=(l===!0?"":" ")+e(u),l=!1,r&&r[u]&&(i+=" "+r[u]))}o[n]=i}return o}var U=rt(Eo(),1);var Y=rt(Eo(),1);import*as Qt from"react";import{jsx as C0}from"react/jsx-runtime";var w0=xt(),S0=Xi("div",{name:"MuiStack",slot:"Root"});function T0(t){return tn({props:t,name:"MuiStack",defaultTheme:w0})}function P0(t,e){let r=Qt.Children.toArray(t).filter(Boolean);return r.reduce((o,n,a)=>(o.push(n),a<r.length-1&&o.push(Qt.cloneElement(e,{key:`separator-${a}`})),o),[])}var k0=t=>({row:"Left","row-reverse":"Right",column:"Top","column-reverse":"Bottom"})[t],I0=({ownerState:t,theme:e})=>{let r={display:"flex",flexDirection:"column",...ee({theme:e},Ho({values:t.direction,breakpoints:e.breakpoints.values}),o=>({flexDirection:o}))};if(t.spacing){let o=Ar(e),n=Object.keys(e.breakpoints.values).reduce((s,u)=>((typeof t.spacing=="object"&&t.spacing[u]!=null||typeof t.direction=="object"&&t.direction[u]!=null)&&(s[u]=!0),s),{}),a=Ho({values:t.direction,base:n}),i=Ho({values:t.spacing,base:n});typeof a=="object"&&Object.keys(a).forEach((s,u,c)=>{if(!a[s]){let f=u>0?a[c[u-1]]:"column";a[s]=f}}),r=Ie(r,ee({theme:e},i,(s,u)=>t.useFlexGap?{gap:We(o,s)}:{"& > :not(style):not(style)":{margin:0},"& > :not(style) ~ :not(style)":{[`margin${k0(u?a[u]:t.direction)}`]:We(o,s)}}))}return r=Bc(e.breakpoints,r),r};function ta(t={}){let{createStyledComponent:e=S0,useThemeProps:r=T0,componentName:o="MuiStack"}=t,n=()=>rn({root:["root"]},s=>Zo(o,s),{}),a=e(I0),i=Qt.forwardRef(function(s,u){let c=r(s),d=Yo(c),{component:f="div",direction:m="column",spacing:h=0,divider:p,children:y,className:v,useFlexGap:b=!1,...S}=d,w={direction:m,spacing:h,useFlexGap:b},C=n();return C0(a,{as:f,ownerState:w,ref:u,className:Ko(C.root,v),...S,children:p?P0(y,p):y})});return process.env.NODE_ENV!=="production"&&(i.propTypes={children:Y.default.node,direction:Y.default.oneOfType([Y.default.oneOf(["column-reverse","column","row-reverse","row"]),Y.default.arrayOf(Y.default.oneOf(["column-reverse","column","row-reverse","row"])),Y.default.object]),divider:Y.default.node,spacing:Y.default.oneOfType([Y.default.arrayOf(Y.default.oneOfType([Y.default.number,Y.default.string])),Y.default.number,Y.default.object,Y.default.string]),sx:Y.default.oneOfType([Y.default.arrayOf(Y.default.oneOfType([Y.default.func,Y.default.object,Y.default.bool])),Y.default.func,Y.default.object])}),i}var Uc=ta();process.env.NODE_ENV!=="production"&&(Uc.propTypes={children:U.default.node,component:U.default.elementType,direction:U.default.oneOfType([U.default.oneOf(["column-reverse","column","row-reverse","row"]),U.default.arrayOf(U.default.oneOf(["column-reverse","column","row-reverse","row"])),U.default.object]),divider:U.default.node,spacing:U.default.oneOfType([U.default.arrayOf(U.default.oneOfType([U.default.number,U.default.string])),U.default.number,U.default.object,U.default.string]),sx:U.default.oneOfType([U.default.arrayOf(U.default.oneOfType([U.default.func,U.default.object,U.default.bool])),U.default.func,U.default.object]),useFlexGap:U.default.bool});var on=Uc;import{jsx as nn,jsxs as Yc}from"react/jsx-runtime";var M0=E0(F0)(({theme:t})=>({fontWeight:"bold"}));function Kc(t){let{label:e,children:r,labelProps:o,contentProps:n,isNumber:a,showDivider:i}=t;return Yc(qc,{sx:{display:"flex",gap:4},children:[Yc(qc,{children:[nn(on,{children:nn(M0,{...o,children:e})}),nn(on,{direction:a?"row":"column",justifyContent:a?"flex-end":"center",children:r})]}),i&&nn(A0,{orientation:"vertical",flexItem:!0})]})}import{useEffect as Qc,useRef as U0,useState as Jc}from"react";import{Box as Xc,IconButton as ep,Stack as q0,Typography as Y0,useMediaQuery as K0,Toolbar as Z0}from"@mui/material";import{ArrowBack as Q0,Close as J0}from"@mui/icons-material";import{Cancel as R0,Edit as D0,Save as O0}from"@mui/icons-material";import{Stack as B0,TextField as L0,Typography as $0,IconButton as Zc,ClickAwayListener as z0,InputAdornment as _0,CircularProgress as N0}from"@mui/material";import{useEffect as ra,useState as oa}from"react";import{Fragment as V0,jsx as Ye,jsxs as na}from"react/jsx-runtime";function an(t){let{typographyProps:e,onChange:r,onEscape:o,value:n,displayEditButton:a,displaySaveButton:i,textFieldProps:l,isEditing:s,isLoading:u,error:c}=t,{InputProps:d,value:f,onKeyDown:m,onChange:h,...p}=l||{},[y,v]=oa(!1),[b,S]=oa(!1),[w,C]=oa();return ra(()=>{C(n)},[n]),ra(()=>{v(!!s)},[s]),ra(()=>{c&&S(!0)},[c]),na(V0,{children:[!y&&!u&&!b&&na(B0,{sx:{cursor:"pointer"},direction:"row",alignItems:"center",spacing:1,children:[Ye($0,{onClick:()=>{v(!0)},...e,children:w}),a&&Ye(Zc,{onClick:()=>{v(!0)},children:Ye(D0,{})})]}),(y||u||b)&&Ye(z0,{onClickAway:()=>v(!1),children:Ye(L0,{disabled:u,autoFocus:!0,value:w,error:b,onKeyDown:k=>{k.key==="Enter"&&(r(w),v(!1)),k.key==="Escape"&&(C(n),v(!1),S(!1),o&&o(n,w))},onChange:k=>{let P=k.target.value;C(P)},InputProps:{endAdornment:na(_0,{position:"end",children:[u&&Ye(N0,{size:18}),i&&Ye(Zc,{onClick:()=>{n!=w&&r(w),v(!1)},edge:"end",children:n!=w?Ye(O0,{}):Ye(R0,{})})]})},...p})})]})}import{InputAdornment as W0,TextField as H0}from"@mui/material";import{Search as G0}from"@mui/icons-material";import j0 from"lodash";import{jsx as ia}from"react/jsx-runtime";function Jt(t){let{onSearch:e,...r}=t,o=j0.debounce(a=>e(a),500);function n(a){let i=a.target.value;o(i)}return ia(H0,{onChange:n,autoFocus:!0,InputProps:{startAdornment:ia(W0,{position:"start",children:ia(G0,{})})},...r})}import{jsx as lt,jsxs as aa}from"react/jsx-runtime";function tp(t){let{title:e,children:r,onBack:o,onClose:n,onUpdate:a,onSearch:i,storagePath:l,toolbarProps:s}=t,[u,c]=Jc(!1),[d,f]=Jc("");Qc(()=>{f(e)},[e]);let m=U0(null);Qc(()=>{if(i&&l){let v=localStorage.getItem(l);m.current&&(m.current.value=v),i(v||"")}},[l]);let h=K0(v=>v.breakpoints.down("sm"));function p(v){l&&localStorage.setItem(l,v),i&&i(v)}let y={component:"h1",variant:"h4",sx:{fontWeight:"500"}};return lt(Z0,{...s,children:aa(Xc,{sx:{display:"flex",flexDirection:h||n?"column":"row",justifyContent:"space-between",alignContent:"center",alignItems:"center",flexGrow:1},children:[aa(Xc,{sx:{display:"flex",alignItems:"center",flexDirection:"row"},children:[o&&lt(ep,{sx:{mr:1},onClick:o,children:lt(Q0,{})}),a&&lt(an,{typographyProps:y,value:d,onChange:v=>{a&&a(v)}}),!a&&lt(Y0,{...y,children:e})]}),n&&lt(ep,{sx:{marginLeft:"auto"},onClick:n,children:lt(J0,{fontSize:"medium"})}),aa(q0,{spacing:1,direction:"row",children:[i&&lt(Jt,{inputRef:m,autoFocus:!0,onSearch:p}),r]})]})})}import{Stack as kn,Typography as Wv,useMediaQuery as Hv,useTheme as Gv}from"@mui/material";import{Stack as X0,useMediaQuery as ey,useTheme as ty}from"@mui/material";import{jsx as ry}from"react/jsx-runtime";function sa(t){let{children:e}=t,r=ty(),o=ey(r.breakpoints.up("md"));return ry(X0,{component:"section",display:o?"flex":"none",width:"100%",direction:"row",justifyContent:"center",alignItems:"center",sx:{},children:e})}import{Box as Mv,Stack as Rv,useMediaQuery as Dv,useTheme as Ov}from"@mui/material";import{Stack as oy,Typography as rp}from"@mui/material";import{jsx as op,jsxs as ny}from"react/jsx-runtime";function la(t){let{label:e,subTitle:r="Acesse sua conta"}=t;return ny(oy,{component:"header",textAlign:"center",marginBottom:"3rem",children:[op(rp,{component:"h2",fontSize:"2rem",fontWeight:"bold",variant:"body1",fontFamily:"Montserrat",sx:{color:o=>o.palette.primary.dark},children:e}),op(rp,{component:"h3",fontSize:"1.25rem",fontFamily:"Montserrat",color:"primary",variant:"body1",children:r})]})}import{useState as sr}from"react";import{Alert as Np,Divider as Vp,Stack as wn,TextField as Gb,Typography as jb}from"@mui/material";import{isAxiosError as Ub}from"axios";import{useValidations as qb,useCredentials as Yb}from"@data-c/hooks";var Ee=rt(up()),Or=rt(fp()),vp=rt(mp()),wy=Object.prototype.toString,Sy=Error.prototype.toString,Ty=RegExp.prototype.toString,Py=typeof Symbol<"u"?Symbol.prototype.toString:()=>"",ky=/^Symbol\((.*)\)(.*)$/;function Iy(t){return t!=+t?"NaN":t===0&&1/t<0?"-0":""+t}function hp(t,e=!1){if(t==null||t===!0||t===!1)return""+t;let r=typeof t;if(r==="number")return Iy(t);if(r==="string")return e?`"${t}"`:t;if(r==="function")return"[Function "+(t.name||"anonymous")+"]";if(r==="symbol")return Py.call(t).replace(ky,"Symbol($1)");let o=wy.call(t).slice(8,-1);return o==="Date"?isNaN(t.getTime())?""+t:t.toISOString(t):o==="Error"||t instanceof Error?"["+Sy.call(t)+"]":o==="RegExp"?Ty.call(t):null}function Ze(t,e){let r=hp(t,e);return r!==null?r:JSON.stringify(t,function(o,n){let a=hp(this[o],e);return a!==null?a:n},2)}function xp(t){return t==null?[]:[].concat(t)}var Cp,wp,Sp,Ay=/\$\{\s*(\w+)\s*\}/g;Cp=Symbol.toStringTag;var dn=class{constructor(e,r,o,n){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[Cp]="Error",this.name="ValidationError",this.value=r,this.path=o,this.type=n,this.errors=[],this.inner=[],xp(e).forEach(a=>{if(te.isError(a)){this.errors.push(...a.errors);let i=a.inner.length?a.inner:[a];this.inner.push(...i)}else this.errors.push(a)}),this.message=this.errors.length>1?`${this.errors.length} errors occurred`:this.errors[0]}};wp=Symbol.hasInstance;Sp=Symbol.toStringTag;var te=class extends Error{static formatError(e,r){let o=r.label||r.path||"this";return r=Object.assign({},r,{path:o,originalPath:r.path}),typeof e=="string"?e.replace(Ay,(n,a)=>Ze(r[a])):typeof e=="function"?e(r):e}static isError(e){return e&&e.name==="ValidationError"}constructor(e,r,o,n,a){let i=new dn(e,r,o,n);if(a)return i;super(),this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=[],this.inner=[],this[Sp]="Error",this.name=i.name,this.message=i.message,this.type=i.type,this.value=i.value,this.path=i.path,this.errors=i.errors,this.inner=i.inner,Error.captureStackTrace&&Error.captureStackTrace(this,te)}static[wp](e){return dn[Symbol.hasInstance](e)||super[Symbol.hasInstance](e)}},He={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:t,type:e,value:r,originalValue:o})=>{let n=o!=null&&o!==r?` (cast from the value \`${Ze(o,!0)}\`).`:".";return e!=="mixed"?`${t} must be a \`${e}\` type, but the final value was: \`${Ze(r,!0)}\``+n:`${t} must match the configured type. The validated value was: \`${Ze(r,!0)}\``+n}},he={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"},ut={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"},ha={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"},ga={isValue:"${path} field must be ${value}"},cn={noUnknown:"${path} field has unspecified keys: ${unknown}",exact:"${path} object contains unknown properties: ${properties}"},pn={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"},Tp={notType:t=>{let{path:e,value:r,spec:o}=t,n=o.types.length;if(Array.isArray(r)){if(r.length<n)return`${e} tuple value has too few items, expected a length of ${n} but got ${r.length} for value: \`${Ze(r,!0)}\``;if(r.length>n)return`${e} tuple value has too many items, expected a length of ${n} but got ${r.length} for value: \`${Ze(r,!0)}\``}return te.formatError(He.notType,t)}},fR=Object.assign(Object.create(null),{mixed:He,string:he,number:ut,date:ha,object:cn,array:pn,boolean:ga,tuple:Tp}),Cn=t=>t&&t.__isYupSchema__,tr=class{static fromOptions(e,r){if(!r.then&&!r.otherwise)throw new TypeError("either `then:` or `otherwise:` is required for `when()` conditions");let{is:o,then:n,otherwise:a}=r,i=typeof o=="function"?o:(...l)=>l.every(s=>s===o);return new tr(e,(l,s)=>{var u;let c=i(...l)?n:a;return(u=c?.(s))!=null?u:s})}constructor(e,r){this.fn=void 0,this.refs=e,this.refs=e,this.fn=r}resolve(e,r){let o=this.refs.map(a=>a.getValue(r?.value,r?.parent,r?.context)),n=this.fn(o,e,r);if(n===void 0||n===e)return e;if(!Cn(n))throw new TypeError("conditions must return a schema object");return n.resolve(r)}},un={context:"$",value:"."};var Qe=class{constructor(e,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 e!="string")throw new TypeError("ref must be a string, got: "+e);if(this.key=e.trim(),e==="")throw new TypeError("ref must be a non-empty string");this.isContext=this.key[0]===un.context,this.isValue=this.key[0]===un.value,this.isSibling=!this.isContext&&!this.isValue;let o=this.isContext?un.context:this.isValue?un.value:"";this.path=this.key.slice(o.length),this.getter=this.path&&(0,Ee.getter)(this.path,!0),this.map=r.map}getValue(e,r,o){let n=this.isContext?o:this.isValue?e:r;return this.getter&&(n=this.getter(n||{})),this.map&&(n=this.map(n)),n}cast(e,r){return this.getValue(e,r?.parent,r?.context)}resolve(){return this}describe(){return{type:"ref",key:this.key}}toString(){return`Ref(${this.key})`}static isRef(e){return e&&e.__isYupRef}};Qe.prototype.__isYupRef=!0;var De=t=>t==null;function Xt(t){function e({value:r,path:o="",options:n,originalValue:a,schema:i},l,s){let{name:u,test:c,params:d,message:f,skipAbsent:m}=t,{parent:h,context:p,abortEarly:y=i.spec.abortEarly,disableStackTrace:v=i.spec.disableStackTrace}=n,b={value:r,parent:h,context:p};function S(A={}){let le=Pp(Object.assign({value:r,originalValue:a,label:i.spec.label,path:A.path||o,spec:i.spec,disableStackTrace:A.disableStackTrace||v},d,A.params),b),g=new te(te.formatError(A.message||f,le),r,le.path,A.type||u,le.disableStackTrace);return g.params=le,g}let w=y?l:s,C={path:o,parent:h,type:u,from:n.from,createError:S,resolve(A){return kp(A,b)},options:n,originalValue:a,schema:i},k=A=>{te.isError(A)?w(A):A?s(null):w(S())},P=A=>{te.isError(A)?w(A):l(A)};if(m&&De(r))return k(!0);let z;try{var se;if(z=c.call(C,r,C),typeof((se=z)==null?void 0:se.then)=="function"){if(n.sync)throw new Error(`Validation test of type: "${C.type}" returned a Promise during a synchronous validate. This test will finish after the validate call has returned`);return Promise.resolve(z).then(k,P)}}catch(A){P(A);return}k(z)}return e.OPTIONS=t,e}function Pp(t,e){if(!t)return t;for(let r of Object.keys(t))t[r]=kp(t[r],e);return t}function kp(t,e){return Qe.isRef(t)?t.getValue(e.value,e.parent,e.context):t}function Ey(t,e,r,o=r){let n,a,i;return e?((0,Ee.forEach)(e,(l,s,u)=>{let c=s?l.slice(1,l.length-1):l;t=t.resolve({context:o,parent:n,value:r});let d=t.type==="tuple",f=u?parseInt(c,10):0;if(t.innerType||d){if(d&&!u)throw new Error(`Yup.reach cannot implicitly index into a tuple type. the path part "${i}" must contain an index to the tuple element, e.g. "${i}[0]"`);if(r&&f>=r.length)throw new Error(`Yup.reach cannot resolve an array item at index: ${l}, in the path: ${e}. because there is no value at that index. `);n=r,r=r&&r[f],t=d?t.spec.types[f]:t.innerType}if(!u){if(!t.fields||!t.fields[c])throw new Error(`The schema does not contain the path: ${e}. (failed at: ${i} which is a type: "${t.type}")`);n=r,r=r&&r[c],t=t.fields[c]}a=c,i=s?"["+l+"]":"."+l}),{schema:t,parent:n,parentPath:a}):{parent:n,parentPath:e,schema:t}}var rr=class extends Set{describe(){let e=[];for(let r of this.values())e.push(Qe.isRef(r)?r.describe():r);return e}resolveAll(e){let r=[];for(let o of this.values())r.push(e(o));return r}clone(){return new rr(this.values())}merge(e,r){let o=this.clone();return e.forEach(n=>o.add(n)),r.forEach(n=>o.delete(n)),o}};function er(t,e=new Map){if(Cn(t)||!t||typeof t!="object")return t;if(e.has(t))return e.get(t);let r;if(t instanceof Date)r=new Date(t.getTime()),e.set(t,r);else if(t instanceof RegExp)r=new RegExp(t),e.set(t,r);else if(Array.isArray(t)){r=new Array(t.length),e.set(t,r);for(let o=0;o<t.length;o++)r[o]=er(t[o],e)}else if(t instanceof Map){r=new Map,e.set(t,r);for(let[o,n]of t.entries())r.set(o,er(n,e))}else if(t instanceof Set){r=new Set,e.set(t,r);for(let o of t)r.add(er(o,e))}else if(t instanceof Object){r={},e.set(t,r);for(let[o,n]of Object.entries(t))r[o]=er(n,e)}else throw Error(`Unable to clone ${t}`);return r}function Fy(t){if(!(t!=null&&t.length))return;let e=[],r="",o=!1,n=!1;for(let a=0;a<t.length;a++){let i=t[a];if(i==="["&&!n){r&&(e.push(...r.split(".").filter(Boolean)),r=""),o=!0;continue}if(i==="]"&&!n){r&&(/^\d+$/.test(r)?e.push(r):e.push(r.replace(/^"|"$/g,"")),r=""),o=!1;continue}if(i==='"'){n=!n;continue}if(i==="."&&!o&&!n){r&&(e.push(r),r="");continue}r+=i}return r&&e.push(...r.split(".").filter(Boolean)),e}function My(t,e){let r=e?`${e}.${t.path}`:t.path;return t.errors.map(o=>({message:o,path:Fy(r)}))}function Ip(t,e){var r;if(!((r=t.inner)!=null&&r.length)&&t.errors.length)return My(t,e);let o=e?`${e}.${t.path}`:t.path;return t.inner.flatMap(n=>Ip(n,o))}var re=class{constructor(e){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 rr,this._blacklist=new rr,this.exclusiveTests=Object.create(null),this._typeCheck=void 0,this.spec=void 0,this.tests=[],this.transforms=[],this.withMutation(()=>{this.typeError(He.notType)}),this.type=e.type,this._typeCheck=e.check,this.spec=Object.assign({strip:!1,strict:!1,abortEarly:!0,recursive:!0,disableStackTrace:!1,nullable:!1,optional:!0,coerce:!0},e?.spec),this.withMutation(r=>{r.nonNullable()})}get _type(){return this.type}clone(e){if(this._mutate)return e&&Object.assign(this.spec,e),this;let 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=er(Object.assign({},this.spec,e)),r}label(e){let r=this.clone();return r.spec.label=e,r}meta(...e){if(e.length===0)return this.spec.meta;let r=this.clone();return r.spec.meta=Object.assign(r.spec.meta||{},e[0]),r}withMutation(e){let r=this._mutate;this._mutate=!0;let o=e(this);return this._mutate=r,o}concat(e){if(!e||e===this)return this;if(e.type!==this.type&&this.type!=="mixed")throw new TypeError(`You cannot \`concat()\` schema's of different types: ${this.type} and ${e.type}`);let r=this,o=e.clone(),n=Object.assign({},r.spec,o.spec);return o.spec=n,o.internalTests=Object.assign({},r.internalTests,o.internalTests),o._whitelist=r._whitelist.merge(e._whitelist,e._blacklist),o._blacklist=r._blacklist.merge(e._blacklist,e._whitelist),o.tests=r.tests,o.exclusiveTests=r.exclusiveTests,o.withMutation(a=>{e.tests.forEach(i=>{a.test(i.OPTIONS)})}),o.transforms=[...r.transforms,...o.transforms],o}isType(e){return e==null?!!(this.spec.nullable&&e===null||this.spec.optional&&e===void 0):this._typeCheck(e)}resolve(e){let r=this;if(r.conditions.length){let o=r.conditions;r=r.clone(),r.conditions=[],r=o.reduce((n,a)=>a.resolve(n,e),r),r=r.resolve(e)}return r}resolveOptions(e){var r,o,n,a;return Object.assign({},e,{from:e.from||[],strict:(r=e.strict)!=null?r:this.spec.strict,abortEarly:(o=e.abortEarly)!=null?o:this.spec.abortEarly,recursive:(n=e.recursive)!=null?n:this.spec.recursive,disableStackTrace:(a=e.disableStackTrace)!=null?a:this.spec.disableStackTrace})}cast(e,r={}){let o=this.resolve(Object.assign({},r,{value:e})),n=r.assert==="ignore-optionality",a=o._cast(e,r);if(r.assert!==!1&&!o.isType(a)){if(n&&De(a))return a;let i=Ze(e),l=Ze(a);throw new TypeError(`The value of ${r.path||"field"} could not be cast to a value that satisfies the schema type: "${o.type}".
8
156
 
9
157
  attempted value: ${i}
10
- `+(l!==i?`result of cast: ${l}`:""))}return a}_cast(t,r){let o=t===void 0?t:this.transforms.reduce((n,a)=>a.call(this,n,t,this,r),t);return o===void 0&&(o=this.getDefault(r)),o}_validate(t,r={},o,n){let{path:a,originalValue:i=t,strict:l=this.spec.strict}=r,s=t;l||(s=this._cast(s,Object.assign({assert:!1},r)));let c=[];for(let u of Object.values(this.internalTests))u&&c.push(u);this.runTests({path:a,value:s,originalValue:i,options:r,tests:c},o,u=>{if(u.length)return n(u,s);this.runTests({path:a,value:s,originalValue:i,options:r,tests:this.tests},o,n)})}runTests(t,r,o){let n=!1,{tests:a,value:i,originalValue:l,path:s,options:c}=t,u=p=>{n||(n=!0,r(p,i))},d=p=>{n||(n=!0,o(p,i))},f=a.length,m=[];if(!f)return d([]);let g={value:i,originalValue:l,path:s,options:c,schema:this};for(let p=0;p<a.length;p++){let y=a[p];y(g,u,function(x){x&&(Array.isArray(x)?m.push(...x):m.push(x)),--f<=0&&d(m)})}}asNestedTest({key:t,index:r,parent:o,parentPath:n,originalParent:a,options:i}){let l=t??r;if(l==null)throw TypeError("Must include `key` or `index` for nested validations");let s=typeof l=="number",c=o[l],u=Object.assign({},i,{strict:!0,parent:o,value:c,originalValue:a[l],key:void 0,[s?"index":"key"]:l,path:s||l.includes(".")?`${n||""}[${s?l:`"${l}"`}]`:(n?`${n}.`:"")+t});return(d,f,m)=>this.resolve(u)._validate(c,u,f,m)}validate(t,r){var o;let n=this.resolve(Object.assign({},r,{value:t})),a=(o=r?.disableStackTrace)!=null?o:n.spec.disableStackTrace;return new Promise((i,l)=>n._validate(t,r,(s,c)=>{te.isError(s)&&(s.value=c),l(s)},(s,c)=>{s.length?l(new te(s,c,void 0,void 0,a)):i(c)}))}validateSync(t,r){var o;let n=this.resolve(Object.assign({},r,{value:t})),a,i=(o=r?.disableStackTrace)!=null?o:n.spec.disableStackTrace;return n._validate(t,Object.assign({},r,{sync:!0}),(l,s)=>{throw te.isError(l)&&(l.value=s),l},(l,s)=>{if(l.length)throw new te(l,t,void 0,void 0,i);a=s}),a}isValid(t,r){return this.validate(t,r).then(()=>!0,o=>{if(te.isError(o))return!1;throw o})}isValidSync(t,r){try{return this.validateSync(t,r),!0}catch(o){if(te.isError(o))return!1;throw o}}_getDefault(t){let r=this.spec.default;return r==null?r:typeof r=="function"?r.call(this,t):Ut(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){let o=this.clone({nullable:t});return o.internalTests.nullable=Ht({message:r,name:"nullable",test(n){return n===null?this.schema.spec.nullable:!0}}),o}optionality(t,r){let o=this.clone({optional:t});return o.internalTests.optionality=Ht({message:r,name:"optionality",test(n){return n===void 0?this.schema.spec.optional:!0}}),o}optional(){return this.optionality(!0)}defined(t=Ve.defined){return this.optionality(!1,t)}nullable(){return this.nullability(!0)}nonNullable(t=Ve.notNull){return this.nullability(!1,t)}required(t=Ve.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=Ve.default),typeof r.test!="function")throw new TypeError("`test` is a required parameters");let o=this.clone(),n=Ht(r),a=r.exclusive||r.name&&o.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&&(o.exclusiveTests[r.name]=!!r.exclusive),o.tests=o.tests.filter(i=>!(i.OPTIONS.name===r.name&&(a||i.OPTIONS.test===n.OPTIONS.test))),o.tests.push(n),o}when(t,r){!Array.isArray(t)&&typeof t!="string"&&(r=t,t=".");let o=this.clone(),n=Wu(t).map(a=>new Ye(a));return n.forEach(a=>{a.isSibling&&o.deps.push(a.key)}),o.conditions.push(typeof r=="function"?new jt(n,r):jt.fromOptions(n,r)),o}typeError(t){let r=this.clone();return r.internalTests.typeError=Ht({message:t,name:"typeError",skipAbsent:!0,test(o){return this.schema._typeCheck(o)?!0:this.createError({params:{type:this.schema.type}})}}),r}oneOf(t,r=Ve.oneOf){let o=this.clone();return t.forEach(n=>{o._whitelist.add(n),o._blacklist.delete(n)}),o.internalTests.whiteList=Ht({message:r,name:"oneOf",skipAbsent:!0,test(n){let a=this.schema._whitelist,i=a.resolveAll(this.resolve);return i.includes(n)?!0:this.createError({params:{values:Array.from(a).join(", "),resolved:i}})}}),o}notOneOf(t,r=Ve.notOneOf){let o=this.clone();return t.forEach(n=>{o._blacklist.add(n),o._whitelist.delete(n)}),o.internalTests.blacklist=Ht({message:r,name:"notOneOf",test(n){let a=this.schema._blacklist,i=a.resolveAll(this.resolve);return i.includes(n)?this.createError({params:{values:Array.from(a).join(", "),resolved:i}}):!0}}),o}strip(t=!0){let r=this.clone();return r.spec.strip=t,r}describe(t){let r=(t?this.resolve(t):this).clone(),{label:o,meta:n,optional:a,nullable:i}=r.spec;return{meta:n,label:o,optional:a,nullable:i,default:r.getDefault(t),type:r.type,oneOf:r._whitelist.describe(),notOneOf:r._blacklist.describe(),tests:r.tests.filter((s,c,u)=>u.findIndex(d=>d.OPTIONS.name===s.OPTIONS.name)===c).map(s=>{let c=s.OPTIONS.params&&t?qu(Object.assign({},s.OPTIONS.params),t):s.OPTIONS.params;return{name:s.OPTIONS.name,params:c}})}}get"~standard"(){let t=this;return{version:1,vendor:"yup",async validate(o){try{return{value:await t.validate(o,{abortEarly:!1})}}catch(n){if(n instanceof te)return{issues:Ku(n)};throw n}}}}};re.prototype.__isYupSchema__=!0;for(let e of["validate","validateSync"])re.prototype[`${e}At`]=function(t,r,o={}){let{parent:n,parentPath:a,schema:i}=hy(this,t,r,o.context);return i[e](n&&n[a],Object.assign({},o,{parent:n,path:t}))};for(let e of["equals","is"])re.prototype[e]=re.prototype.oneOf;for(let e of["not","nope"])re.prototype[e]=re.prototype.notOneOf;var vy=()=>!0;function by(e){return new Xo(e)}var Xo=class extends re{constructor(t){super(typeof t=="function"?{type:"mixed",check:t}:Object.assign({type:"mixed",check:vy},t))}};by.prototype=Xo.prototype;function Cy(){return new en}var en=class extends re{constructor(){super({type:"boolean",check(t){return t instanceof Boolean&&(t=t.valueOf()),typeof t=="boolean"}}),this.withMutation(()=>{this.transform((t,r)=>{if(this.spec.coerce&&!this.isType(t)){if(/^(true|1)$/i.test(String(t)))return!0;if(/^(false|0)$/i.test(String(t)))return!1}return t})})}isTrue(t=Zi.isValue){return this.test({message:t,name:"is-value",exclusive:!0,params:{value:"true"},test(r){return Me(r)||r===!0}})}isFalse(t=Zi.isValue){return this.test({message:t,name:"is-value",exclusive:!0,params:{value:"false"},test(r){return Me(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)}};Cy.prototype=en.prototype;var wy=/^(\d{4}|[+-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,.](\d{1,}))?)?(?:(Z)|([+-])(\d{2})(?::?(\d{2}))?)?)?$/;function Sy(e){let t=Qi(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 Qi(e){var t,r;let o=wy.exec(e);return o?{year:je(o[1]),month:je(o[2],1)-1,day:je(o[3],1),hour:je(o[4]),minute:je(o[5]),second:je(o[6]),millisecond:o[7]?je(o[7].substring(0,3)):0,precision:(t=(r=o[7])==null?void 0:r.length)!=null?t:void 0,z:o[8]||void 0,plusMinus:o[9]||void 0,hourOffset:je(o[10]),minuteOffset:je(o[11])}:null}function je(e,t=0){return Number(e)||t}var Ty=/^[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])?)*$/,Py=/^((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,ky=/^(?:[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,Iy="^\\d{4}-\\d{2}-\\d{2}",Ey="\\d{2}:\\d{2}:\\d{2}",Ay="(([+-]\\d{2}(:?\\d{2})?)|Z)",My=new RegExp(`${Iy}T${Ey}(\\.\\d+)?${Ay}$`),Dy=e=>Me(e)||e===e.trim(),Fy={}.toString();function ce(){return new tn}var tn=class extends re{constructor(){super({type:"string",check(t){return t instanceof String&&(t=t.valueOf()),typeof t=="string"}}),this.withMutation(()=>{this.transform((t,r)=>{if(!this.spec.coerce||this.isType(t)||Array.isArray(t))return t;let o=t!=null&&t.toString?t.toString():t;return o===Fy?t:o})})}required(t){return super.required(t).withMutation(r=>r.test({message:t||Ve.required,name:"required",skipAbsent:!0,test:o=>!!o.length}))}notRequired(){return super.notRequired().withMutation(t=>(t.tests=t.tests.filter(r=>r.OPTIONS.name!=="required"),t))}length(t,r=fe.length){return this.test({message:r,name:"length",exclusive:!0,params:{length:t},skipAbsent:!0,test(o){return o.length===this.resolve(t)}})}min(t,r=fe.min){return this.test({message:r,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(o){return o.length>=this.resolve(t)}})}max(t,r=fe.max){return this.test({name:"max",exclusive:!0,message:r,params:{max:t},skipAbsent:!0,test(o){return o.length<=this.resolve(t)}})}matches(t,r){let o=!1,n,a;return r&&(typeof r=="object"?{excludeEmptyString:o=!1,message:n,name:a}=r:n=r),this.test({name:a||"matches",message:n||fe.matches,params:{regex:t},skipAbsent:!0,test:i=>i===""&&o||i.search(t)!==-1})}email(t=fe.email){return this.matches(Ty,{name:"email",message:t,excludeEmptyString:!0})}url(t=fe.url){return this.matches(Py,{name:"url",message:t,excludeEmptyString:!0})}uuid(t=fe.uuid){return this.matches(ky,{name:"uuid",message:t,excludeEmptyString:!1})}datetime(t){let r="",o,n;return t&&(typeof t=="object"?{message:r="",allowOffset:o=!1,precision:n=void 0}=t:r=t),this.matches(My,{name:"datetime",message:r||fe.datetime,excludeEmptyString:!0}).test({name:"datetime_offset",message:r||fe.datetime_offset,params:{allowOffset:o},skipAbsent:!0,test:a=>{if(!a||o)return!0;let i=Qi(a);return i?!!i.z:!1}}).test({name:"datetime_precision",message:r||fe.datetime_precision,params:{precision:n},skipAbsent:!0,test:a=>{if(!a||n==null)return!0;let i=Qi(a);return i?i.precision===n:!1}})}ensure(){return this.default("").transform(t=>t===null?"":t)}trim(t=fe.trim){return this.transform(r=>r!=null?r.trim():r).test({message:t,name:"trim",test:Dy})}lowercase(t=fe.lowercase){return this.transform(r=>Me(r)?r:r.toLowerCase()).test({message:t,name:"string_case",exclusive:!0,skipAbsent:!0,test:r=>Me(r)||r===r.toLowerCase()})}uppercase(t=fe.uppercase){return this.transform(r=>Me(r)?r:r.toUpperCase()).test({message:t,name:"string_case",exclusive:!0,skipAbsent:!0,test:r=>Me(r)||r===r.toUpperCase()})}};ce.prototype=tn.prototype;var Ry=e=>e!=+e;function Oy(){return new rn}var rn=class extends re{constructor(){super({type:"number",check(t){return t instanceof Number&&(t=t.valueOf()),typeof t=="number"&&!Ry(t)}}),this.withMutation(()=>{this.transform((t,r)=>{if(!this.spec.coerce)return t;let o=t;if(typeof o=="string"){if(o=o.replace(/\s/g,""),o==="")return NaN;o=+o}return this.isType(o)||o===null?o:parseFloat(o)})})}min(t,r=ot.min){return this.test({message:r,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(o){return o>=this.resolve(t)}})}max(t,r=ot.max){return this.test({message:r,name:"max",exclusive:!0,params:{max:t},skipAbsent:!0,test(o){return o<=this.resolve(t)}})}lessThan(t,r=ot.lessThan){return this.test({message:r,name:"max",exclusive:!0,params:{less:t},skipAbsent:!0,test(o){return o<this.resolve(t)}})}moreThan(t,r=ot.moreThan){return this.test({message:r,name:"min",exclusive:!0,params:{more:t},skipAbsent:!0,test(o){return o>this.resolve(t)}})}positive(t=ot.positive){return this.moreThan(0,t)}negative(t=ot.negative){return this.lessThan(0,t)}integer(t=ot.integer){return this.test({name:"integer",message:t,skipAbsent:!0,test:r=>Number.isInteger(r)})}truncate(){return this.transform(t=>Me(t)?t:t|0)}round(t){var r;let o=["ceil","floor","round","trunc"];if(t=((r=t)==null?void 0:r.toLowerCase())||"round",t==="trunc")return this.truncate();if(o.indexOf(t.toLowerCase())===-1)throw new TypeError("Only valid options for round() are: "+o.join(", "));return this.transform(n=>Me(n)?n:Math[t](n))}};Oy.prototype=rn.prototype;var Zu=new Date(""),By=e=>Object.prototype.toString.call(e)==="[object Date]";function Qu(){return new gt}var gt=class extends re{constructor(){super({type:"date",check(t){return By(t)&&!isNaN(t.getTime())}}),this.withMutation(()=>{this.transform((t,r)=>!this.spec.coerce||this.isType(t)||t===null?t:(t=Sy(t),isNaN(t)?gt.INVALID_DATE:new Date(t)))})}prepareParam(t,r){let o;if(Ye.isRef(t))o=t;else{let n=this.cast(t);if(!this._typeCheck(n))throw new TypeError(`\`${r}\` must be a Date or a value that can be \`cast()\` to a Date`);o=n}return o}min(t,r=Ki.min){let o=this.prepareParam(t,"min");return this.test({message:r,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(n){return n>=this.resolve(o)}})}max(t,r=Ki.max){let o=this.prepareParam(t,"max");return this.test({message:r,name:"max",exclusive:!0,params:{max:t},skipAbsent:!0,test(n){return n<=this.resolve(o)}})}};gt.INVALID_DATE=Zu;Qu.prototype=gt.prototype;Qu.INVALID_DATE=Zu;function _y(e,t=[]){let r=[],o=new Set,n=new Set(t.map(([i,l])=>`${i}-${l}`));function a(i,l){let s=(0,ke.split)(i)[0];o.add(s),n.has(`${l}-${s}`)||r.push([l,s])}for(let i of Object.keys(e)){let l=e[i];o.add(i),Ye.isRef(l)&&l.isSibling?a(l.path,i):sn(l)&&"deps"in l&&l.deps.forEach(s=>a(s,i))}return zu.default.array(Array.from(o),r).reverse()}function $u(e,t){let r=1/0;return e.some((o,n)=>{var a;if((a=t.path)!=null&&a.includes(o))return r=n,!0}),r}function Ju(e){return(t,r)=>$u(e,t)-$u(e,r)}var Xu=(e,t,r)=>{if(typeof e!="string")return e;let o=e;try{o=JSON.parse(e)}catch{}return r.isType(o)?o:e};function Qo(e){if("fields"in e){let t={};for(let[r,o]of Object.entries(e.fields))t[r]=Qo(o);return e.setFields(t)}if(e.type==="array"){let t=e.optional();return t.innerType&&(t.innerType=Qo(t.innerType)),t}return e.type==="tuple"?e.optional().clone({types:e.spec.types.map(Qo)}):"optional"in e?e.optional():e}var Ly=(e,t)=>{let r=[...(0,ke.normalizePath)(t)];if(r.length===1)return r[0]in e;let o=r.pop(),n=(0,ke.getter)((0,ke.join)(r),!0)(e);return!!(n&&o in n)},Nu=e=>Object.prototype.toString.call(e)==="[object Object]";function Vu(e,t){let r=Object.keys(e.fields);return Object.keys(t).filter(o=>r.indexOf(o)===-1)}var $y=Ju([]);function ve(e){return new on(e)}var on=class extends re{constructor(t){super({type:"object",check(r){return Nu(r)||typeof r=="function"}}),this.fields=Object.create(null),this._sortErrors=$y,this._nodes=[],this._excludedEdges=[],this.withMutation(()=>{t&&this.shape(t)})}_cast(t,r={}){var o;let n=super._cast(t,r);if(n===void 0)return this.getDefault(r);if(!this._typeCheck(n))return n;let a=this.fields,i=(o=r.stripUnknown)!=null?o:this.spec.noUnknown,l=[].concat(this._nodes,Object.keys(n).filter(d=>!this._nodes.includes(d))),s={},c=Object.assign({},r,{parent:s,__validating:r.__validating||!1}),u=!1;for(let d of l){let f=a[d],m=d in n,g=n[d];if(f){let p;c.path=(r.path?`${r.path}.`:"")+d,f=f.resolve({value:g,context:r.context,parent:s});let y=f instanceof re?f.spec:void 0,v=y?.strict;if(y!=null&&y.strip){u=u||d in n;continue}p=!r.__validating||!v?f.cast(g,c):g,p!==void 0&&(s[d]=p)}else m&&!i&&(s[d]=g);(m!==d in s||s[d]!==g)&&(u=!0)}return u?s:n}_validate(t,r={},o,n){let{from:a=[],originalValue:i=t,recursive:l=this.spec.recursive}=r;r.from=[{schema:this,value:i},...a],r.__validating=!0,r.originalValue=i,super._validate(t,r,o,(s,c)=>{if(!l||!Nu(c)){n(s,c);return}i=i||c;let u=[];for(let d of this._nodes){let f=this.fields[d];!f||Ye.isRef(f)||u.push(f.asNestedTest({options:r,key:d,parent:c,parentPath:r.path,originalParent:i}))}this.runTests({tests:u,value:c,originalValue:i,options:r},o,d=>{n(d.sort(this._sortErrors).concat(s),c)})})}clone(t){let 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),o=r.fields;for(let[n,a]of Object.entries(this.fields)){let i=o[n];o[n]=i===void 0?a:i}return r.withMutation(n=>n.setFields(o,[...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(o=>{var n;let a=this.fields[o],i=t;(n=i)!=null&&n.value&&(i=Object.assign({},i,{parent:i.value,value:i.value[o]})),r[o]=a&&"getDefault"in a?a.getDefault(i):void 0}),r}setFields(t,r){let o=this.clone();return o.fields=t,o._nodes=_y(t,r),o._sortErrors=Ju(Object.keys(t)),r&&(o._excludedEdges=r),o}shape(t,r=[]){return this.clone().withMutation(o=>{let n=o._excludedEdges;return r.length&&(Array.isArray(r[0])||(r=[r]),n=[...o._excludedEdges,...r]),o.setFields(Object.assign(o.fields,t),n)})}partial(){let t={};for(let[r,o]of Object.entries(this.fields))t[r]="optional"in o&&o.optional instanceof Function?o.optional():o;return this.setFields(t)}deepPartial(){return Qo(this)}pick(t){let r={};for(let o of t)this.fields[o]&&(r[o]=this.fields[o]);return this.setFields(r,this._excludedEdges.filter(([o,n])=>t.includes(o)&&t.includes(n)))}omit(t){let r=[];for(let o of Object.keys(this.fields))t.includes(o)||r.push(o);return this.pick(r)}from(t,r,o){let n=(0,ke.getter)(t,!0);return this.transform(a=>{if(!a)return a;let i=a;return Ly(a,t)&&(i=Object.assign({},a),o||delete i[t],i[r]=n(a)),i})}json(){return this.transform(Xu)}exact(t){return this.test({name:"exact",exclusive:!0,message:t||Ko.exact,test(r){if(r==null)return!0;let o=Vu(this.schema,r);return o.length===0||this.createError({params:{properties:o.join(", ")}})}})}stripUnknown(){return this.clone({noUnknown:!0})}noUnknown(t=!0,r=Ko.noUnknown){typeof t!="boolean"&&(r=t,t=!0);let o=this.test({name:"noUnknown",exclusive:!0,message:r,test(n){if(n==null)return!0;let a=Vu(this.schema,n);return!t||a.length===0||this.createError({params:{unknown:a.join(", ")}})}});return o.spec.noUnknown=t,o}unknown(t=!0,r=Ko.noUnknown){return this.noUnknown(!t,r)}transformKeys(t){return this.transform(r=>{if(!r)return r;let o={};for(let n of Object.keys(r))o[t(n)]=r[n];return o})}camelCase(){return this.transformKeys(Tr.camelCase)}snakeCase(){return this.transformKeys(Tr.snakeCase)}constantCase(){return this.transformKeys(t=>(0,Tr.snakeCase)(t).toUpperCase())}describe(t){let r=(t?this.resolve(t):this).clone(),o=super.describe(t);o.fields={};for(let[a,i]of Object.entries(r.fields)){var n;let l=t;(n=l)!=null&&n.value&&(l=Object.assign({},l,{parent:l.value,value:l.value[a]})),o.fields[a]=i.describe(l)}return o}};ve.prototype=on.prototype;function Ny(e){return new nn(e)}var nn=class extends re{constructor(t){super({type:"array",spec:{types:t},check(r){return Array.isArray(r)}}),this.innerType=void 0,this.innerType=t}_cast(t,r){let o=super._cast(t,r);if(!this._typeCheck(o)||!this.innerType)return o;let n=!1,a=o.map((i,l)=>{let s=this.innerType.cast(i,Object.assign({},r,{path:`${r.path||""}[${l}]`,parent:o,originalValue:i,value:i,index:l}));return s!==i&&(n=!0),s});return n?a:o}_validate(t,r={},o,n){var a;let i=this.innerType,l=(a=r.recursive)!=null?a:this.spec.recursive;r.originalValue!=null&&r.originalValue,super._validate(t,r,o,(s,c)=>{var u;if(!l||!i||!this._typeCheck(c)){n(s,c);return}let d=new Array(c.length);for(let m=0;m<c.length;m++){var f;d[m]=i.asNestedTest({options:r,index:m,parent:c,parentPath:r.path,originalParent:(f=r.originalValue)!=null?f:t})}this.runTests({value:c,tests:d,originalValue:(u=r.originalValue)!=null?u:t,options:r},o,m=>n(m.concat(s),c))})}clone(t){let r=super.clone(t);return r.innerType=this.innerType,r}json(){return this.transform(Xu)}concat(t){let r=super.concat(t);return r.innerType=this.innerType,t.innerType&&(r.innerType=r.innerType?r.innerType.concat(t.innerType):t.innerType),r}of(t){let r=this.clone();if(!sn(t))throw new TypeError("`array.of()` sub-schema must be a valid yup schema not: "+qe(t));return r.innerType=t,r.spec=Object.assign({},r.spec,{types:t}),r}length(t,r=Zo.length){return this.test({message:r,name:"length",exclusive:!0,params:{length:t},skipAbsent:!0,test(o){return o.length===this.resolve(t)}})}min(t,r){return r=r||Zo.min,this.test({message:r,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(o){return o.length>=this.resolve(t)}})}max(t,r){return r=r||Zo.max,this.test({message:r,name:"max",exclusive:!0,params:{max:t},skipAbsent:!0,test(o){return o.length<=this.resolve(t)}})}ensure(){return this.default(()=>[]).transform((t,r)=>this._typeCheck(t)?t:r==null?[]:[].concat(r))}compact(t){let r=t?(o,n,a)=>!t(o,n,a):o=>!!o;return this.transform(o=>o!=null?o.filter(r):o)}describe(t){let r=(t?this.resolve(t):this).clone(),o=super.describe(t);if(r.innerType){var n;let a=t;(n=a)!=null&&n.value&&(a=Object.assign({},a,{parent:a.value,value:a.value[0]})),o.innerType=r.innerType.describe(a)}return o}};Ny.prototype=nn.prototype;function Vy(e){return new an(e)}var an=class extends re{constructor(t){super({type:"tuple",spec:{types:t},check(r){let o=this.spec.types;return Array.isArray(r)&&r.length===o.length}}),this.withMutation(()=>{this.typeError(ju.notType)})}_cast(t,r){let{types:o}=this.spec,n=super._cast(t,r);if(!this._typeCheck(n))return n;let a=!1,i=o.map((l,s)=>{let c=l.cast(n[s],Object.assign({},r,{path:`${r.path||""}[${s}]`,parent:n,originalValue:n[s],value:n[s],index:s}));return c!==n[s]&&(a=!0),c});return a?i:n}_validate(t,r={},o,n){let a=this.spec.types;super._validate(t,r,o,(i,l)=>{var s;if(!this._typeCheck(l)){n(i,l);return}let c=[];for(let[d,f]of a.entries()){var u;c[d]=f.asNestedTest({options:r,index:d,parent:l,parentPath:r.path,originalParent:(u=r.originalValue)!=null?u:t})}this.runTests({value:l,tests:c,originalValue:(s=r.originalValue)!=null?s:t,options:r},o,d=>n(d.concat(i),l))})}describe(t){let r=(t?this.resolve(t):this).clone(),o=super.describe(t);return o.innerType=r.spec.types.map((n,a)=>{var i;let l=t;return(i=l)!=null&&i.value&&(l=Object.assign({},l,{parent:l.value,value:l.value[a]})),n.describe(l)}),o}};Vy.prototype=an.prototype;import{Alert as np,Grid as Kt}from"@mui/material";import{useState as ip}from"react";import{useCredentials as Px,useForm as kx,useValidations as Ix}from"@data-c/hooks";import{isAxiosError as Ex}from"axios";import{useEffect as ap}from"react";import Ax from"validator/lib/isStrongPassword";import{useState as zy}from"react";import{Visibility as Wy,VisibilityOff as Gy}from"@mui/icons-material";import{IconButton as Hy,InputAdornment as Uy,TextField as jy}from"@mui/material";import{jsx as Pr}from"react/jsx-runtime";function ht(e){let{name:t,label:r,value:o,onChange:n,onKeyDown:a}=e,[i,l]=zy(!1);function s(){l(!i)}return Pr(jy,{name:t,label:r,value:o||"",onChange:n,onKeyDown:a,type:i?"text":"password",InputProps:{endAdornment:Pr(Uy,{position:"end",children:Pr(Hy,{tabIndex:-1,onClick:s,edge:"end",children:i?Pr(Gy,{}):Pr(Wy,{})})})}})}import{useDialogs as $D}from"@toolpad/core";import{jsx as qy}from"react/jsx-runtime";function Ji({children:e,...t}){return qy(R,{variant:"outlined",color:"error",...t,children:"Cancelar"})}import{Close as Yy}from"@mui/icons-material";import{IconButton as Ky}from"@mui/material";import{jsx as ep}from"react/jsx-runtime";function yt({onClose:e}){return ep(Ky,{onClick:()=>e(),sx:{position:"absolute",right:"11px"},children:ep(Yy,{})})}import{Stack as Zy}from"@mui/material";import{jsx as Qy}from"react/jsx-runtime";function xt(e){return Qy(Zy,{direction:"row",alignItems:"center",gap:1,marginLeft:"auto",...e})}import{jsx as Jy}from"react/jsx-runtime";function Xi({children:e,label:t,...r}){return Jy(R,{variant:"contained",...r,children:t||"Salvar"})}import{Button as Xy}from"@mui/material";import{useDialogs as ex}from"@toolpad/core";import{jsx as tx}from"react/jsx-runtime";function ea(e){let{dialogComponent:t,payload:r,label:o,...n}=e,a=ex();return tx(Xy,{variant:"contained",onClick:()=>{a.open(t,r)},...n,children:o||" Adicionar"})}import{Typography as gx}from"@mui/material";import{Stack as tp}from"@mui/material";import{jsx as rp}from"react/jsx-runtime";function vt({children:e,...t}){return rp(tp,{component:"main",margin:"44px 0 55.75px",overflow:"auto",children:rp(tp,{padding:"16px",...t,children:e})})}import{Stack as rx,useTheme as ox}from"@mui/material";import{jsx as nx}from"react/jsx-runtime";function bt(e){let t=ox();return nx(rx,{component:"footer",position:"absolute",direction:"row",alignItems:"center",bottom:0,left:0,right:0,padding:"8px 16px",borderTop:`solid 1px ${t.palette.grey[300]}`,height:"48px",sx:{backgroundColor:t.palette.background.paper},...e})}import{Stack as ix,useTheme as ax}from"@mui/material";import{jsx as sx}from"react/jsx-runtime";function Ct(e){let t=ax();return sx(ix,{component:"header",height:"44px",position:"absolute",direction:"row",top:0,left:0,right:0,display:"flex",alignItems:"center",padding:"16px",borderBottom:`solid 1px ${t.palette.grey[300]}`,...e})}import{forwardRef as lx}from"react";import{Dialog as cx,Slide as ux,Stack as px}from"@mui/material";import{jsx as ta}from"react/jsx-runtime";var dx=lx(function(t,r){return ta(ux,{direction:"up",ref:r,...t})});function wt({children:e,height:t,fullWidth:r=!0,...o}){return ta(cx,{disableRestoreFocus:!0,fullWidth:r,TransitionComponent:dx,sx:{"& .MuiBackdrop-root":{backgroundColor:"#6464648F"},...o?.sx},PaperProps:{style:{height:t,overflow:"hidden",position:"absolute",top:"51px",margin:0}},...o,children:ta(px,{height:"100%",position:"relative",overflow:"auto",children:e})})}import{Typography as fx}from"@mui/material";import{jsx as mx}from"react/jsx-runtime";function St(e){return mx(fx,{component:"h6",variant:"h6",sx:{whiteSpace:"nowrap"},...e})}import{jsx as Tt,jsxs as ra}from"react/jsx-runtime";function oa(e){let{open:t,onClose:r,payload:o}=e,{title:n,message:a,confirmButtonLabel:i="Confirmar",cancelButtonLabel:l="Cancelar",payload:s}=o;return ra(wt,{open:t,onClose:()=>r(!1),children:[ra(Ct,{children:[Tt(St,{children:n||"Precisamos da sua confirma\xE7\xE3o"}),Tt(yt,{onClose:()=>r(!1)})]}),Tt(vt,{children:Tt(gx,{variant:"body1",children:a||"Voc\xEA tem certeza que deseja continuar?"})}),Tt(bt,{children:ra(xt,{children:[Tt(R,{onClick:()=>r(!1),sx:{minWidth:"100px"},children:l}),Tt(R,{color:"error",variant:"contained",onClick:()=>r(s??!0),sx:{minWidth:"100px"},children:i})]})})]})}import{Alert as hx}from"@mui/material";import{jsx as Pt,jsxs as na}from"react/jsx-runtime";function ia({open:e,onClose:t,payload:r}){let{useRemover:o,configs:n}=r,{mutateAsync:a,isLoading:i}=o();async function l(){try{await a(n),t()}catch{}}return na(wt,{open:e,onClose:t,children:[na(Ct,{children:[Pt(St,{children:"Tem certeza de que deseja excluir este registro?"}),Pt(yt,{onClose:t})]}),Pt(vt,{children:Pt(hx,{severity:"error",children:"O registro ser\xE1 removido permanentemente. Deseja continuar?"})}),Pt(bt,{children:na(xt,{children:[Pt(R,{onClick:()=>t(),sx:{minWidth:"100px"},children:"Manter registro"}),Pt(R,{color:"error",variant:"contained",isLoading:i,onClick:l,sx:{minWidth:"100px"},children:"Remover"})]})})]})}import{DialogsProvider as yx}from"@toolpad/core";import{jsx as xx}from"react/jsx-runtime";function aa({children:e}){return xx(yx,{children:e})}var vx={Root:wt,Provider:aa,AdicionarButton:ea,Header:Ct,Title:St,ActionClose:yt,Content:vt,Footer:bt,Actions:xt,ActionCancelar:Ji,ActionSalvar:Xi,ConfirmDelete:ia,Confirm:oa},O=vx;import{Box as bx,Typography as Cx,useTheme as wx}from"@mui/material";import{Circle as Sx}from"@mui/icons-material";import{jsx as op,jsxs as Tx}from"react/jsx-runtime";function kt(e){let{isValid:t,message:r}=e,o=wx();return Tx(bx,{sx:{display:"flex",flexDirection:"row",alignItems:"center"},children:[op(Sx,{color:t?"success":"inherit",sx:{fontSize:"8pt"}}),op(Cx,{variant:"body2",sx:{color:t?o.palette.success.main:"inherit",textDecoration:t?"line-through":"none",ml:1,fontSize:"10pt"},children:r})]})}import{jsx as J,jsxs as Zt}from"react/jsx-runtime";var sp={senhaAtual:"",senhaNova:""},Mx=ve().shape({senhaAtual:ce().required("Informe a Senha Atual."),senhaNova:ce().required("Informe a Nova Senha.")});function Qt(e){let{isOpen:t,credentialsConfig:r,onClose:o,onSuccess:n,onFailed:a,primeiroAcesso:i,senhaAtual:l,email:s}=e,{alterarSenha:c,isSubmitting:u}=Px(r),{setValidationErrors:d,validationProps:f}=Ix(),{data:m,handleChange:g,setData:p,changeValue:y}=kx(sp),[v,x]=ip(!1),[S,w]=ip(null);ap(()=>{l&&y("senhaAtual",l)},[l]),ap(()=>{m.senhaNova&&x(Ax(m.senhaNova,{minLength:8,minLowercase:1,minUppercase:1,minNumbers:1,minSymbols:1}))},[m.senhaNova]);async function C(){d(null),w(null),Mx.validate(m,{abortEarly:!1}).then(async()=>{let{senhaAtual:E,senhaNova:le}=m;try{await c(E,le,s)&&(n&&n(),p(sp))}catch(h){if(a&&a(h),Ex(h)){w(h.response?.data.message);return}w("Ocorreu um erro ao tentar alterar a senha")}}).catch(E=>{d(E)})}function k(){return m?.senhaNova.length>=8}function P(){if(m?.senhaNova){let E=m?.senhaNova.match(/[a-z]/g);return Array.isArray(E)&&E.length>0}return!1}function Q(){if(m?.senhaNova){let E=m?.senhaNova.match(/[A-Z]/g);return Array.isArray(E)&&E.length>0}return!1}function $(){if(m?.senhaNova){let E=m?.senhaNova.match(/\d/g);return Array.isArray(E)&&E.length>0}return!1}function se(){if(m?.senhaNova){let E=m?.senhaNova.match(/\W/g);return Array.isArray(E)&&E.length>0}return!1}return Zt(O.Root,{open:t,onClose:E=>o(),maxWidth:"md",children:[Zt(O.Header,{children:[J(O.Title,{children:"Alterar Senha"}),J(O.ActionClose,{onClose:o})]}),J(O.Content,{children:Zt(Kt,{container:!0,spacing:2,children:[i&&J(Kt,{size:12,children:Zt(np,{severity:"info",children:["Voc\xEA est\xE1 acessando o sistema com uma senha tempor\xE1ria.",J("br",{}),"Cadastre uma senha segura para deixar sua conta mais protegida."]})}),J(Kt,{size:12,children:J(ht,{name:"senhaAtual",label:"Senha Atual",value:m?.senhaAtual||"",onChange:g,...f("senhaAtual")})}),J(Kt,{size:12,children:J(ht,{name:"senhaNova",label:"Nova Senha",value:m?.senhaNova||"",onChange:g,...f("senhaNova")})}),Zt(Kt,{size:12,children:[J(kt,{isValid:k(),message:"O tamanho m\xEDnimo da nova senha \xE9 de 8 caracteres"}),J(kt,{isValid:P(),message:"A nova senha deve ter ao menos uma letra min\xFAscula"}),J(kt,{isValid:Q(),message:"A nova senha deve ter ao menos uma letra mai\xFAscula"}),J(kt,{isValid:$(),message:"A nova senha deve ter ao menos um n\xFAmero"}),J(kt,{isValid:se(),message:"A nova senha deve ter ao menos um caracter especial"})]}),S&&J(Kt,{size:12,children:J(np,{severity:"error",children:S})})]})}),J(O.Footer,{children:Zt(O.Actions,{children:[J(O.ActionCancelar,{onClick:()=>o()}),J(O.ActionSalvar,{label:"Alterar Senha",onClick:C,isLoading:u,disabled:!v})]})})]})}import{Mail as _x,WhatsApp as Lx}from"@mui/icons-material";import{jsx as me,jsxs as kr}from"react/jsx-runtime";var $x=ve().shape({email:ce().required("Informe o e-mail"),password:ce().required("Informe a senha")});function sa(e){let{onLoginSuccess:t,onLoginFailed:r,onOptionsClick:o,credentialsConfig:n}=e,[a,i]=Jt(""),[l,s]=Jt(""),[c,u]=Jt(!1),[d,f]=Jt(!1),[m,g]=Jt(!1),[p,y]=Jt(null),{login:v}=Bx(n),{validationProps:x,setValidationErrors:S}=Ox();async function w(){S(null),y(null),$x.validate({email:a,password:l},{abortEarly:!1}).then(async()=>{u(!0);try{let C=await v(a,l);C&&t(C)}catch(C){if(Rx(C)){if(C.response?.data.code==="E_FIRST_ACCESS"){f(!0);return}y(C.response?.data.message)}r(C)}}).catch(C=>{S(C)}).finally(()=>{u(!1)})}return kr(ln,{component:"form",onSubmit:w,children:[kr(ln,{spacing:2,children:[me(Dx,{name:"email",label:"E-mail",margin:"normal",autoFocus:!0,value:a||"",onChange:C=>i(C.target.value),...x("email")}),me(ht,{name:"password",label:"Senha",size:"medium",placeholder:"Sua senha",value:l||"",onChange:C=>s(C.target.value),onKeyDown:C=>C.key==="Enter"&&w(),...x("password")}),me(R,{fullWidth:!0,variant:"contained",onClick:w,isLoading:c,sx:{mt:1},children:"Entrar"})]}),me(R,{onClick:()=>o("esqueci-senha"),variant:"text",disableRipple:!0,disableTouchRipple:!0,sx:{justifyContent:"flex-start",alignContent:"center",alignItems:"center",textAlign:"left",width:"120px",marginTop:.5,fontWeight:"400",":hover":{}},children:"Esqueci a senha"}),p&&me(lp,{severity:"error",children:p}),m&&kr(lp,{severity:"success",children:["Senha cadastrada com sucesso",me("br",{}),"Tudo pronto para voc\xEA fazer o login"]}),kr(ln,{direction:"row",justifyContent:"center",alignItems:"center",mt:2,mb:2,children:[me(cp,{sx:{flexGrow:1,mr:1}}),me(Fx,{children:"Ou fa\xE7a login com"}),me(cp,{sx:{flexGrow:1,ml:1}})]}),kr(ln,{spacing:1,children:[me(R,{onClick:()=>o("otp-email"),startIcon:me(_x,{}),children:"Entrar com senha tempor\xE1ria"}),me(R,{onClick:()=>o("otp-whatsapp"),startIcon:me(Lx,{}),children:"Entrar com senha tempor\xE1ria"})]}),me(Qt,{senhaAtual:l,email:a,primeiroAcesso:!0,isOpen:d,onClose:async()=>f(!1),onSuccess:()=>{f(!1),g(!0),s("")},credentialsConfig:n})]})}import{useState as cn}from"react";import{Alert as up,Box as Nx,TextField as Vx}from"@mui/material";import{useCredentials as zx,useValidations as Wx}from"@data-c/hooks";import{jsx as It,jsxs as Hx}from"react/jsx-runtime";var Gx=ve().shape({email:ce().required("Informe o e-mail")});function la(e){let{onLoginClick:t,credentialsConfig:r}=e,[o,n]=cn(""),[a,i]=cn(!1),[l,s]=cn(!1),[c,u]=cn(null),{recuperarSenha:d}=zx(r),{validationProps:f,setValidationErrors:m}=Wx();async function g(){m(null),Gx.validate({email:o},{abortEarly:!1}).then(async()=>{try{i(!0),await d(o),s(!0)}catch(p){u(p.response?.data.message)}finally{i(!1)}}).catch(p=>{m(p)})}return Hx(Nx,{component:"form",children:[It(Vx,{name:"email",label:"E-mail",margin:"normal",placeholder:"Informe o e-mail utilizado para acessar o sistema",autoFocus:!0,value:o||"",onChange:p=>n(p.target.value),...f("email")}),It(R,{fullWidth:!0,variant:"contained",onClick:g,isLoading:a,children:"Recuperar minha senha"}),It(_e,{sx:{display:"inline-flex",justifyContent:"space-between",width:"100%",marginTop:1},children:It(R,{onClick:t,variant:"text",sx:{fontWeight:"400",":hover":{color:p=>p.palette.primary.dark}},children:"Voltar para o Login"})}),l&&It(up,{severity:"success",action:It(R,{onClick:t,variant:"text",sx:{fontWeight:"400",":hover":{color:p=>p.palette.primary.dark}},children:"Ir para o Login"}),children:"Enviamos para o seu e-mail as instru\xE7\xF5es para recuperar a sua senha"}),c&&It(up,{severity:"error",children:c})]})}import{useEffect as Ux,useState as jx}from"react";import{Box as qx,MenuItem as Yx,TextField as Kx}from"@mui/material";import{useCredentials as Zx}from"@data-c/hooks";import{jsx as ca,jsxs as Qx}from"react/jsx-runtime";function ua(e){let{loginData:t,credentialsConfig:r,onLoginFailed:o,onLoginSuccess:n}=e,[a,i]=jx(""),{selecionarLicenca:l,isSubmitting:s}=Zx(r);Ux(()=>{if(Array.isArray(t?.empresas)){let u=t?.empresas[0];i(u?.uuid)}},[t]);async function c(){try{let u=await l(t?.token,a);u?n(u):o("Nenhuma token definida")}catch(u){o(u)}}return Qx(qx,{component:"form",sx:{minWidth:"290px"},children:[ca(Kx,{label:"Licen\xE7as",margin:"normal",select:!0,autoFocus:!0,value:a,onChange:u=>{i(u.target.value)},children:t?.empresas?.map(u=>ca(Yx,{value:u.uuid,children:u.nome},u.uuid))}),ca(R,{fullWidth:!0,variant:"contained",onClick:c,isLoading:s,sx:{mt:1},children:"Confirmar"})]})}import{useEffect as w0,useState as gp}from"react";import{useCredentials as S0}from"@data-c/hooks";import{Alert as c0,IconButton as u0,Stack as mp,TextField as p0,Typography as d0}from"@mui/material";import{useForm as f0}from"@data-c/hooks";import{useState as Jx,useMemo as Xx}from"react";import e0 from"@mui/material/TextField";import{jsx as t0}from"react/jsx-runtime";var pp=e=>{let t=e.replace(/\D/g,"");return t.length<=2?`(${t}`:t.length<=7?`(${t.slice(0,2)}) ${t.slice(2)}`:t.length<=11?`(${t.slice(0,2)}) ${t.slice(2,7)}-${t.slice(7)}`:`(${t.slice(0,2)}) ${t.slice(2,7)}-${t.slice(7,11)}`};function Ir(e){let{value:t,onChange:r,...o}=e,[n,a]=Jx(""),i=t!==void 0,l=Xx(()=>i?pp(t||""):n,[t,n,i]);return t0(e0,{value:l,onChange:c=>{let u=pp(c.target.value);if(i||a(u),r){let d={...c,target:{...c.target,value:u}};r(d)}},inputProps:{maxLength:15},...o})}import{useCredentials as m0}from"@data-c/hooks";import{useState as fa}from"react";import{useCredentials as i0}from"@data-c/hooks";import{Alert as a0,Stack as s0,Typography as fp}from"@mui/material";import{useEffect as l0,useState as pa}from"react";import{useRef as r0}from"react";import{Box as o0,TextField as n0}from"@mui/material";import{jsx as dp}from"react/jsx-runtime";function Er({length:e=6,value:t,onChange:r}){let o=r0([]),n=(i,l)=>{let s="ABCDEF0123456789",c=l.toUpperCase().split("").find(f=>s.includes(f))||"",u=t.split("");u[i]=c;let d=u.join("");r(d),c&&i<e-1&&o.current[i+1]?.focus()},a=(i,l)=>{l.key==="Backspace"&&!t[i]&&i>0&&o.current[i-1]?.focus()};return dp(o0,{display:"flex",gap:1,children:Array.from({length:e}).map((i,l)=>dp(n0,{autoFocus:l===0,inputRef:s=>o.current[l]=s,slotProps:{htmlInput:{maxLength:1,style:{textAlign:"center",fontSize:"24px",width:"24px",height:"36px"}}},value:t[l]||"",onChange:s=>n(l,s.target.value),onKeyDown:s=>a(l,s)},l))})}import{jsx as De,jsxs as Ar}from"react/jsx-runtime";function da(e){let{open:t,onClose:r,payload:o,onLoginSuccess:n,credentialsConfig:a}=e,[i,l]=pa(""),[s,c]=pa(!1),[u,d]=pa(!1),{validarOtpVerificationCode:f}=i0(a);l0(()=>{s&&setTimeout(()=>{c(!1)},3e3)},[s]);async function m(){try{d(!0);let g=await f({channel:o.channel,target:o.target,code:i});g&&n(g),r()}catch(g){c(g.response.data.message)}finally{d(!1)}}return Ar(O.Root,{open:t,onClose:g=>r(),maxWidth:"xs",children:[Ar(O.Header,{children:[De(O.Title,{children:"Entrar com senha tempor\xE1ria"}),De(O.ActionClose,{onClose:r})]}),De(O.Content,{children:Ar(s0,{spacing:2,justifyContent:"center",alignContent:"center",alignItems:"center",children:[De(fp,{variant:"subtitle1",sx:{fontWeight:"bolder",fontSize:"11pt"},children:"\u{1F510} Digite a senha tempor\xE1ria para acessar sua conta"}),Ar(fp,{variant:"body1",sx:{fontSize:"10pt"},children:["Enviamos uma senha tempor\xE1ria para ",De("b",{children:o.target}),". ",De("br",{}),"Digite o c\xF3digo abaixo para acessar sua conta."]}),De(Er,{value:i,onChange:g=>{l(g)}}),s&&De(a0,{sx:{flexGrow:1},severity:"error",children:s})]})}),De(O.Footer,{children:Ar(O.Actions,{children:[De(O.ActionCancelar,{onClick:()=>r()}),De(O.ActionSalvar,{label:"Entrar",onClick:m,isLoading:u,disabled:i.length!=6})]})})]})}import{HelpOutline as g0}from"@mui/icons-material";import{Fragment as y0,jsx as Fe,jsxs as un}from"react/jsx-runtime";var h0=ve().shape({contato:ce().when("$tipo",([e],t)=>e==="otp-email"?t.email("E-mail inv\xE1lido").required("Informe o e-mail"):t.matches(/^\+?[1-9]\d{7,14}$/,"N\xFAmero de WhatsApp inv\xE1lido").required("Informe o WhatsApp"))});function pn(e){let{tipo:t,credentialsConfig:r,onLoginSuccess:o,onLoginClick:n}=e,[a,i]=fa(!1),[l,s]=fa(!1),{gerarOtpVerificationCode:c}=m0(r),{handleChange:u,changeValue:d,data:f,validate:m,validationErrors:g}=f0({contato:""},h0),[p,y]=fa(!1);return un(y0,{children:[Fe("form",{onSubmit:async x=>{x.preventDefault(),m(async S=>{try{s(!1),i(!0);let w=await c({channel:t==="otp-email"?"email":"whatsapp",target:S.contato});y(!0)}catch(w){s(w.response.data.message)}finally{i(!1)}},{context:{tipo:t}})},children:un(mp,{spacing:2,children:[Fe(d0,{variant:"subtitle2",children:t==="otp-email"?" Informe seu e-mail para receber um c\xF3digo de acesso":"Informe seu n\xFAmero de WhatsApp para receber um c\xF3digo de acesso"}),t==="otp-email"&&Fe(p0,{autoFocus:!0,name:"contato",label:"E-mail",value:f.contato||"",onChange:u,fullWidth:!0,...g("contato")}),t==="otp-whatsapp"&&Fe(Ir,{autoFocus:!0,name:"contato",label:"Whatsapp",value:f.contato||"",onChange:x=>{d("contato",x.target.value.replace(/[^\d+]/g,""))},fullWidth:!0,...g("contato")}),un(mp,{children:[Fe(R,{isLoading:a,type:"submit",variant:"contained",color:"primary",children:"Enviar c\xF3digo"}),un(_e,{sx:{display:"inline-flex",justifyContent:"space-between",width:"100%",marginTop:1},children:[Fe(R,{onClick:n,variant:"text",sx:{fontWeight:"400",":hover":{color:x=>x.palette.primary.dark}},children:"Voltar para o Login"}),Fe("a",{href:"https://datacsistemashelp.zendesk.com/hc/pt-br/articles/36489079108756-Login-OTP-via-WhatsApp",target:"_blank",rel:"noopener noreferrer",children:Fe(u0,{children:Fe(g0,{color:"primary"})})})]})]}),l&&Fe(c0,{severity:"error",children:l})]})}),Fe(da,{onLoginSuccess:o,open:p,onClose:async x=>{y(!1)},payload:{target:f.contato,channel:t==="otp-email"?"email":"whatsapp"},credentialsConfig:r})]})}import{jsx as Xt,jsxs as hp}from"react/jsx-runtime";var T0={login:"Acesse sua conta",licensa:"Selecione a licen\xE7a","esqueci-senha":"Recupere a sua senha","otp-email":"Entrar com senha tempor\xE1ria (E-mail)","otp-whatsapp":"Entrar com senha tempor\xE1ria (WhatsApp)"};function ma(e){let{credentialsConfig:t,onLoginSuccess:r,onLoginFailed:o,onAlreadyLogged:n,appName:a}=e,[i,l]=gp(),{selecionarLicenca:s,isAuthenticated:c}=S0(t),[u,d]=gp("login"),f=C0(),m=b0(f.breakpoints.up("md"));w0(()=>{c&&n&&n()},[c]);async function g(S){try{if(Array.isArray(S?.empresas)){if(S?.empresas.length===1){let w=await s(S?.token,S.empresas[0].uuid);w&&r(w);return}d("licensa"),l(S);return}r(S)}catch(w){o(w)}}async function p(S){o(S)}function y(S){d(S)}function v(){d("login")}let x=T0[u];return hp(v0,{children:[Xt(Wi,{label:a,subTitle:x}),hp(x0,{sx:{marginTop:2},children:[u==="login"&&Xt(sa,{credentialsConfig:t,onLoginSuccess:g,onLoginFailed:p,onOptionsClick:y}),u==="licensa"&&Xt(ua,{loginData:i,credentialsConfig:t,onLoginSuccess:r,onLoginFailed:o}),u==="esqueci-senha"&&Xt(la,{onLoginClick:v,credentialsConfig:t}),u==="otp-email"&&Xt(pn,{onLoginClick:v,onLoginSuccess:g,tipo:"otp-email",credentialsConfig:t}),u==="otp-whatsapp"&&Xt(pn,{onLoginClick:v,onLoginSuccess:g,tipo:"otp-whatsapp",credentialsConfig:t})]})]})}import{ArrowRight as P0}from"@mui/icons-material";import{Link as k0,Stack as yp,Typography as ga,useMediaQuery as I0,useTheme as E0}from"@mui/material";import{jsx as er,jsxs as xp}from"react/jsx-runtime";function ha(){let e=E0(),t=I0(e.breakpoints.up("md"));return er(yp,{component:"section",display:t?"flex":"none",width:"100%",direction:"row",justifyContent:"center",alignItems:"center",sx:{backgroundImage:"url(https://datac-site-assets.s3.sa-east-1.amazonaws.com/background_login.png)",backgroundSize:"cover",backgroundPosition:"right",backgroundRepeat:"no-repeat"},children:xp(yp,{padding:"2rem",children:[er(ga,{component:"h1",fontSize:"3.5rem",lineHeight:"4rem",fontWeight:"bold",color:"white",fontFamily:"Montserrat",letterSpacing:0,children:"Inova\xE7\xE3o e tecnologia"}),er(ga,{component:"h2",color:"white",fontSize:"2.5rem",lineHeight:"3rem",letterSpacing:0,fontWeight:"bold",fontFamily:"Montserrat",children:"para empresas de resultado"}),er(ga,{component:"span",fontSize:"1.25rem",lineHeight:"1.25rem",fontWeight:"300",letterSpacing:0,marginTop:"1.5rem",marginBottom:"3rem",fontFamily:"Montserrat",sx:{color:"rgb(68, 167, 255)"},children:"Mais de 30 anos de exist\xEAncia e muitas hist\xF3rias de sucesso."}),er(k0,{href:"https://site.datac.com.br/services/",target:"_blank",children:xp(R,{component:"a",variant:"text",sx:{width:"fit-content",color:"rgb(255, 255, 255)",fontWeight:"400",fontSize:"0.875rem",lineHeight:"1.125rem",fontFamily:"Montserrat",backgroundColor:"rgb(22, 23, 101)",borderRadius:"30px",padding:"17px 48px",":hover":{backgroundColor:"rgb(255, 255, 255)",color:"rgb(22, 23, 101)"},alignItems:"center"},children:["Conhe\xE7a nossos produtos",er(P0,{fontSize:"medium",sx:{color:r=>r.palette.success.light}})]})})]})})}import{jsx as Et,jsxs as ya}from"react/jsx-runtime";function F0({children:e}){let t=D0(),r=M0(t.breakpoints.up("md"));return ya(dn,{component:"section",width:r?"46%":"100%",minWidth:"420px",maxWidth:r?"614px":"initial",justifyContent:"center",alignItems:"center",padding:"2rem",children:[Et(dn,{width:"100%",maxWidth:"28rem",margin:"auto 0",children:e}),ya(dn,{direction:"row",alignItems:"center",marginBottom:-3,children:[Et("img",{width:"60",src:"https://datac-site-assets.s3.sa-east-1.amazonaws.com/logomarca.png"}),Et(A0,{variant:"body1",component:"span",fontSize:"0.7rem",sx:{color:o=>o.palette.grey[500]},children:"Data C Sistemas"})]})]})}function vp(e){let{banner:t,loginSection:r}=e;return ya(dn,{component:"main",direction:"row",height:"100vh",children:[t?Et(zi,{children:t}):Et(ha,{}),Et(F0,{children:r||Et(ma,{...e})})]})}import{formatDocumento as tf,normalizeText as rf}from"@data-c/hooks";import{Stack as R0}from"@mui/material";import{jsx as O0}from"react/jsx-runtime";function xa(e){return O0(R0,{direction:"row",alignItems:"center",alignContent:"center",spacing:1,flex:1,flexGrow:1,...e})}import{AppBar as B0,Stack as _0,Toolbar as L0}from"@mui/material";import $0 from"react";import{jsx as fn}from"react/jsx-runtime";function va({children:e}){return fn($0.Fragment,{children:fn(B0,{position:"fixed",elevation:0,sx:{width:"100%",zIndex:t=>t.zIndex.drawer+1,borderBottom:t=>`1px solid ${t.palette.grey[300]}`},children:fn(L0,{children:fn(_0,{sx:{width:"100%"},direction:"row",alignContent:"center",alignItems:"center",justifyContent:"space-between",children:e})})})})}import{IconButton as pb}from"@mui/material";import{SvgIcon as N0}from"@mui/material";import{jsx as tr,jsxs as V0}from"react/jsx-runtime";function ba(e){return tr(N0,{...e,children:V0("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[tr("path",{d:"M3 5v14"}),tr("path",{d:"M8 5v14"}),tr("path",{d:"M12 5v14"}),tr("path",{d:"M17 5v14"}),tr("path",{d:"M21 5v14"})]})})}import{SvgIcon as z0}from"@mui/material";import{jsx as Ca,jsxs as W0}from"react/jsx-runtime";function wa(e){return Ca(z0,{...e,children:W0("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Ca("circle",{cx:"12",cy:"12",r:"10"}),Ca("path",{d:"m4.9 4.9 14.2 14.2"})]})})}import{SvgIcon as G0}from"@mui/material";import{jsx as mn,jsxs as H0}from"react/jsx-runtime";function Sa(e){return mn(G0,{...e,children:H0("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[mn("rect",{width:"20",height:"5",x:"2",y:"3",rx:"1"}),mn("path",{d:"M4 8v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8"}),mn("path",{d:"M10 12h4"})]})})}import{SvgIcon as U0}from"@mui/material";import{jsx as Ta}from"react/jsx-runtime";function Mr(e){return Ta(U0,{...e,children:Ta("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:Ta("path",{d:"m6 9 6 6 6-6"})})})}import{SvgIcon as j0}from"@mui/material";import{jsx as Pa}from"react/jsx-runtime";function ka(e){return Pa(j0,{...e,children:Pa("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:Pa("path",{d:"M12 3c7.2 0 9 1.8 9 9s-1.8 9-9 9-9-1.8-9-9 1.8-9 9-9"})})})}import{SvgIcon as q0}from"@mui/material";import{jsx as Dr,jsxs as Y0}from"react/jsx-runtime";function Ia(e){return Dr(q0,{...e,children:Y0("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Dr("path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2"}),Dr("circle",{cx:"9",cy:"7",r:"4"}),Dr("path",{d:"M22 21v-2a4 4 0 0 0-3-3.87"}),Dr("path",{d:"M16 3.13a4 4 0 0 1 0 7.75"})]})})}import{SvgIcon as K0}from"@mui/material";import{jsx as Ea,jsxs as Z0}from"react/jsx-runtime";function Aa(e){return Ea(K0,{...e,children:Z0("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Ea("path",{d:"m11 17-5-5 5-5"}),Ea("path",{d:"m18 17-5-5 5-5"})]})})}import{SvgIcon as Q0}from"@mui/material";import{jsx as Ma,jsxs as J0}from"react/jsx-runtime";function Da(e){return Ma(Q0,{...e,children:J0("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Ma("path",{d:"M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z"}),Ma("circle",{cx:"12",cy:"12",r:"3"})]})})}import{SvgIcon as X0}from"@mui/material";import{jsx as Fr,jsxs as ev}from"react/jsx-runtime";function Fa(e){return Fr(X0,{...e,children:ev("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Fr("rect",{width:"7",height:"9",x:"3",y:"3",rx:"1"}),Fr("rect",{width:"7",height:"5",x:"14",y:"3",rx:"1"}),Fr("rect",{width:"7",height:"9",x:"14",y:"12",rx:"1"}),Fr("rect",{width:"7",height:"5",x:"3",y:"16",rx:"1"})]})})}import{SvgIcon as tv}from"@mui/material";import{jsx as rr,jsxs as rv}from"react/jsx-runtime";function Ra(e){return rr(tv,{...e,children:rv("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[rr("path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z"}),rr("path",{d:"M14 2v4a2 2 0 0 0 2 2h4"}),rr("path",{d:"M10 9H8"}),rr("path",{d:"M16 13H8"}),rr("path",{d:"M16 17H8"})]})})}import{SvgIcon as ov}from"@mui/material";import{jsx as Oa}from"react/jsx-runtime";function Rr(e){return Oa(ov,{...e,children:Oa("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:Oa("path",{d:"m6 9 6 6 6-6"})})})}import{SvgIcon as nv}from"@mui/material";import{jsx as gn,jsxs as iv}from"react/jsx-runtime";function Ba(e){return gn(nv,{...e,children:iv("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[gn("path",{d:"m7 21-4.3-4.3c-1-1-1-2.5 0-3.4l9.6-9.6c1-1 2.5-1 3.4 0l5.6 5.6c1 1 1 2.5 0 3.4L13 21"}),gn("path",{d:"M22 21H7"}),gn("path",{d:"m5 11 9 9"})]})})}import{styled as av}from"@mui/material/styles";import{jsx as cv}from"react/jsx-runtime";var sv=e=>({transition:e.transitions.create(["transform"],{duration:500})}),lv=av(Rr,{shouldForwardProp:e=>e!=="open"})(({theme:e,open:t})=>({...sv(e),...t&&{transform:"rotate(-180deg)"},...!t&&{transform:"rotate(0)"}}));function _a(e){let{open:t}=e;return cv(lv,{fontSize:"small",open:t})}import{SvgIcon as uv}from"@mui/material";import{jsx as hn,jsxs as pv}from"react/jsx-runtime";function La(e){return hn(uv,{...e,children:pv("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[hn("path",{d:"M3 6h18"}),hn("path",{d:"M7 12h10"}),hn("path",{d:"M10 18h4"})]})})}import{SvgIcon as dv}from"@mui/material";import{jsx as yn,jsxs as fv}from"react/jsx-runtime";function $a(e){return yn(dv,{...e,children:fv("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[yn("path",{d:"M18 20a6 6 0 0 0-12 0"}),yn("circle",{cx:"12",cy:"10",r:"4"}),yn("circle",{cx:"12",cy:"12",r:"10"})]})})}import{SvgIcon as mv}from"@mui/material";import{jsx as or,jsxs as gv}from"react/jsx-runtime";function Na(e){return or(mv,{...e,children:gv("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[or("path",{d:"m11 17 2 2a1 1 0 1 0 3-3"}),or("path",{d:"m14 14 2.5 2.5a1 1 0 1 0 3-3l-3.88-3.88a3 3 0 0 0-4.24 0l-.88.88a1 1 0 1 1-3-3l2.81-2.81a5.79 5.79 0 0 1 7.06-.87l.47.28a2 2 0 0 0 1.42.25L21 4"}),or("path",{d:"m21 3 1 11h-2"}),or("path",{d:"M3 3 2 14l6.5 6.5a1 1 0 1 0 3-3"}),or("path",{d:"M3 4h8"})]})})}import{SvgIcon as hv}from"@mui/material";import{jsx as xn,jsxs as yv}from"react/jsx-runtime";function Va(e){return xn(hv,{...e,children:yv("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[xn("path",{d:"M7.9 20A9 9 0 1 0 4 16.1L2 22Z"}),xn("path",{d:"M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3"}),xn("path",{d:"M12 17h.01"})]})})}import{SvgIcon as xv}from"@mui/material";import{jsx as vn,jsxs as vv}from"react/jsx-runtime";function za(e){return vn(xv,{...e,children:vv("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[vn("path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8"}),vn("path",{d:"M3 3v5h5"}),vn("path",{d:"M12 7v5l4 2"})]})})}import{SvgIcon as bv}from"@mui/material";import{jsx as Or,jsxs as Cv}from"react/jsx-runtime";function Wa(e){return Or(bv,{...e,children:Cv("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Or("rect",{width:"18",height:"18",x:"3",y:"3",rx:"2"}),Or("path",{d:"M8 7v7"}),Or("path",{d:"M12 7v4"}),Or("path",{d:"M16 7v9"})]})})}import{SvgIcon as wv}from"@mui/material";import{jsx as bn,jsxs as Sv}from"react/jsx-runtime";function Ga(e){return bn(wv,{...e,children:Sv("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[bn("path",{d:"M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4"}),bn("polyline",{points:"16 17 21 12 16 7"}),bn("line",{x1:"21",x2:"9",y1:"12",y2:"12"})]})})}import{SvgIcon as Tv}from"@mui/material";import{jsx as Ha,jsxs as Pv}from"react/jsx-runtime";function Ua(e){return Ha(Tv,{...e,children:Pv("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"white",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Ha("path",{d:"M20 10c0 4.993-5.539 10.193-7.399 11.799a1 1 0 0 1-1.202 0C9.539 20.193 4 14.993 4 10a8 8 0 0 1 16 0"}),Ha("circle",{cx:"12",cy:"10",r:"3"})]})})}import{SvgIcon as kv}from"@mui/material";import{jsx as Cn,jsxs as Iv}from"react/jsx-runtime";function ja(e){return Cn(kv,{...e,children:Iv("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Cn("path",{d:"M14.106 5.553a2 2 0 0 0 1.788 0l3.659-1.83A1 1 0 0 1 21 4.619v12.764a1 1 0 0 1-.553.894l-4.553 2.277a2 2 0 0 1-1.788 0l-4.212-2.106a2 2 0 0 0-1.788 0l-3.659 1.83A1 1 0 0 1 3 19.381V6.618a1 1 0 0 1 .553-.894l4.553-2.277a2 2 0 0 1 1.788 0z"}),Cn("path",{d:"M15 5.764v15"}),Cn("path",{d:"M9 3.236v15"})]})})}import{SvgIcon as Ev}from"@mui/material";import{jsx as wn,jsxs as Av}from"react/jsx-runtime";function qa(e){return wn(Ev,{...e,children:Av("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[wn("line",{x1:"4",x2:"20",y1:"12",y2:"12"}),wn("line",{x1:"4",x2:"20",y1:"6",y2:"6"}),wn("line",{x1:"4",x2:"20",y1:"18",y2:"18"})]})})}import{SvgIcon as Mv}from"@mui/material";import{jsx as nr,jsxs as Dv}from"react/jsx-runtime";function Ya(e){return nr(Mv,{...e,children:Dv("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[nr("path",{d:"m11 17 2 2a1 1 0 1 0 3-3"}),nr("path",{d:"m14 14 2.5 2.5a1 1 0 1 0 3-3l-3.88-3.88a3 3 0 0 0-4.24 0l-.88.88a1 1 0 1 1-3-3l2.81-2.81a5.79 5.79 0 0 1 7.06-.87l.47.28a2 2 0 0 0 1.42.25L21 4"}),nr("path",{d:"m21 3 1 11h-2"}),nr("path",{d:"M3 3 2 14l6.5 6.5a1 1 0 1 0 3-3"}),nr("path",{d:"M3 4h8"})]})})}import{SvgIcon as Fv}from"@mui/material";import{jsx as Ka,jsxs as Rv}from"react/jsx-runtime";function Za(e){return Ka(Fv,{...e,children:Rv("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Ka("path",{d:"m6 17 5-5-5-5"}),Ka("path",{d:"m13 17 5-5-5-5"})]})})}import{SvgIcon as Ov}from"@mui/material";import{jsx as Qa,jsxs as Bv}from"react/jsx-runtime";function Ja(e){return Qa(Ov,{...e,children:Bv("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Qa("path",{d:"M2.586 17.414A2 2 0 0 0 2 18.828V21a1 1 0 0 0 1 1h3a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h1a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h.172a2 2 0 0 0 1.414-.586l.814-.814a6.5 6.5 0 1 0-4-4z"}),Qa("circle",{cx:"16.5",cy:"7.5",r:".5",fill:"currentColor"})]})})}import{SvgIcon as _v}from"@mui/material";import{jsx as Xa,jsxs as Lv}from"react/jsx-runtime";function es(e){return Xa(_v,{...e,children:Lv("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Xa("circle",{cx:"11",cy:"11",r:"8"}),Xa("path",{d:"m21 21-4.3-4.3"})]})})}import{SvgIcon as $v}from"@mui/material";import{jsx as ir,jsxs as Nv}from"react/jsx-runtime";function ts(e){return ir($v,{...e,children:Nv("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[ir("path",{d:"m2 7 4.41-4.41A2 2 0 0 1 7.83 2h8.34a2 2 0 0 1 1.42.59L22 7"}),ir("path",{d:"M4 12v8a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-8"}),ir("path",{d:"M15 22v-4a2 2 0 0 0-2-2h-2a2 2 0 0 0-2 2v4"}),ir("path",{d:"M2 7h20"}),ir("path",{d:"M22 7v3a2 2 0 0 1-2 2a2.7 2.7 0 0 1-1.59-.63.7.7 0 0 0-.82 0A2.7 2.7 0 0 1 16 12a2.7 2.7 0 0 1-1.59-.63.7.7 0 0 0-.82 0A2.7 2.7 0 0 1 12 12a2.7 2.7 0 0 1-1.59-.63.7.7 0 0 0-.82 0A2.7 2.7 0 0 1 8 12a2.7 2.7 0 0 1-1.59-.63.7.7 0 0 0-.82 0A2.7 2.7 0 0 1 4 12a2 2 0 0 1-2-2V7"})]})})}import{SvgIcon as Vv}from"@mui/material";import{jsx as Sn,jsxs as zv}from"react/jsx-runtime";function rs(e){return Sn(Vv,{...e,children:zv("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Sn("path",{d:"M17 22h-1a4 4 0 0 1-4-4V6a4 4 0 0 1 4-4h1"}),Sn("path",{d:"M7 22h1a4 4 0 0 0 4-4v-1"}),Sn("path",{d:"M7 2h1a4 4 0 0 1 4 4v1"})]})})}import{SvgIcon as Wv}from"@mui/material";import{jsx as Br,jsxs as Gv}from"react/jsx-runtime";function os(e){return Br(Wv,{...e,children:Gv("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Br("path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2"}),Br("circle",{cx:"9",cy:"7",r:"4"}),Br("path",{d:"M22 21v-2a4 4 0 0 0-3-3.87"}),Br("path",{d:"M16 3.13a4 4 0 0 1 0 7.75"})]})})}import{SvgIcon as Hv}from"@mui/material";import{jsx as ns,jsxs as Uv}from"react/jsx-runtime";function is(e){return ns(Hv,{...e,children:Uv("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[ns("path",{d:"M2.5 17a24.12 24.12 0 0 1 0-10 2 2 0 0 1 1.4-1.4 49.56 49.56 0 0 1 16.2 0A2 2 0 0 1 21.5 7a24.12 24.12 0 0 1 0 10 2 2 0 0 1-1.4 1.4 49.55 49.55 0 0 1-16.2 0A2 2 0 0 1 2.5 17"}),ns("path",{d:"m10 15 5-3-5-3z"})]})})}import{SvgIcon as jv}from"@mui/material";import{jsx as Tn,jsxs as qv}from"react/jsx-runtime";function as(e){return Tn(jv,{...e,children:qv("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Tn("path",{d:"M12 17V3"}),Tn("path",{d:"m6 11 6 6 6-6"}),Tn("path",{d:"M19 21H5"})]})})}import{SvgIcon as Yv}from"@mui/material";import{jsx as At,jsxs as Kv}from"react/jsx-runtime";function ss(e){return At(Yv,{...e,children:Kv("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[At("line",{x1:"3",x2:"21",y1:"22",y2:"22"}),At("line",{x1:"6",x2:"6",y1:"18",y2:"11"}),At("line",{x1:"10",x2:"10",y1:"18",y2:"11"}),At("line",{x1:"14",x2:"14",y1:"18",y2:"11"}),At("line",{x1:"18",x2:"18",y1:"18",y2:"11"}),At("polygon",{points:"12 2 20 7 4 7"})]})})}import{SvgIcon as Zv}from"@mui/material";import{jsx as _r,jsxs as Qv}from"react/jsx-runtime";function ls(e){return _r(Zv,{...e,children:Qv("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[_r("path",{d:"M15.536 11.293a1 1 0 0 0 0 1.414l2.376 2.377a1 1 0 0 0 1.414 0l2.377-2.377a1 1 0 0 0 0-1.414l-2.377-2.377a1 1 0 0 0-1.414 0z"}),_r("path",{d:"M2.297 11.293a1 1 0 0 0 0 1.414l2.377 2.377a1 1 0 0 0 1.414 0l2.377-2.377a1 1 0 0 0 0-1.414L6.088 8.916a1 1 0 0 0-1.414 0z"}),_r("path",{d:"M8.916 17.912a1 1 0 0 0 0 1.415l2.377 2.376a1 1 0 0 0 1.414 0l2.377-2.376a1 1 0 0 0 0-1.415l-2.377-2.376a1 1 0 0 0-1.414 0z"}),_r("path",{d:"M8.916 4.674a1 1 0 0 0 0 1.414l2.377 2.376a1 1 0 0 0 1.414 0l2.377-2.376a1 1 0 0 0 0-1.414l-2.377-2.377a1 1 0 0 0-1.414 0z"})]})})}import{SvgIcon as Jv}from"@mui/material";import{jsx as Pn,jsxs as Xv}from"react/jsx-runtime";function cs(e){return Pn(Jv,{...e,children:Xv("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Pn("circle",{cx:"16",cy:"16",r:"6"}),Pn("path",{d:"M7 20H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H20a2 2 0 0 1 2 2"}),Pn("path",{d:"M16 14v2l1 1"})]})})}import{SvgIcon as eb}from"@mui/material";import{jsx as Lr,jsxs as tb}from"react/jsx-runtime";function us(e){return Lr(eb,{...e,children:tb("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Lr("path",{d:"M13.22 2.416a2 2 0 0 0-2.511.057l-7 5.999A2 2 0 0 0 3 10v9a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7.354"}),Lr("path",{d:"M15 21v-8a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v8"}),Lr("path",{d:"M15 6h6"}),Lr("path",{d:"M18 3v6"})]})})}import{SvgIcon as rb}from"@mui/material";import{jsx as ar,jsxs as ob}from"react/jsx-runtime";function ps(e){return ar(rb,{...e,children:ob("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[ar("rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2"}),ar("line",{x1:"3",x2:"21",y1:"9",y2:"9"}),ar("line",{x1:"3",x2:"21",y1:"15",y2:"15"}),ar("line",{x1:"9",x2:"9",y1:"9",y2:"21"}),ar("line",{x1:"15",x2:"15",y1:"9",y2:"21"})]})})}import{SvgIcon as nb}from"@mui/material";import{jsx as ds}from"react/jsx-runtime";function fs(e){return ds(nb,{...e,children:ds("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:ds("path",{d:"m15 18-6-6 6-6"})})})}import{SvgIcon as ib}from"@mui/material";import{jsx as ms}from"react/jsx-runtime";function gs(e){return ms(ib,{...e,children:ms("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:ms("path",{d:"m9 18 6-6-6-6"})})})}import{SvgIcon as ab}from"@mui/material";import{jsx as Re,jsxs as sb}from"react/jsx-runtime";function hs(e){return Re(ab,{...e,children:sb("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Re("path",{d:"M8 2v4"}),Re("path",{d:"M16 2v4"}),Re("rect",{width:"18",height:"18",x:"3",y:"4",rx:"2"}),Re("path",{d:"M3 10h18"}),Re("path",{d:"M8 14h.01"}),Re("path",{d:"M12 14h.01"}),Re("path",{d:"M16 14h.01"}),Re("path",{d:"M8 18h.01"}),Re("path",{d:"M12 18h.01"}),Re("path",{d:"M16 18h.01"})]})})}import{SvgIcon as lb}from"@mui/material";import{jsx as kn,jsxs as cb}from"react/jsx-runtime";function ys(e){return kn(lb,{...e,children:cb("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[kn("path",{d:"M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z"}),kn("path",{d:"M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7"}),kn("path",{d:"M7 3v4a1 1 0 0 0 1 1h7"})]})})}var ub={Circle:ka,Dashboard:Fa,Expandable:_a,Down:Rr,Negociacao:Ya,Cadastro:Sa,Clientes:Ia,Filter:La,Search:es,ChevronDown:Mr,Kanban:Wa,Erease:Ba,BarCode:ba,TextCursor:rs,OpenPanel:Za,ClosePanel:Aa,Menu:qa,Configs:Da,Users:os,Password:Ja,Logout:Ga,History:za,Help:Va,Video:is,Docs:Ra,Block:wa,Maps:ja,MapPin:Ua,HandShake:Na,Store:ts,Download:as,ContaBancaria:ss,GrupoLancamento:ls,HistoricoPadrao:cs,Imovel:us,Lancamento:ps,ChevronLeft:fs,ChevronRight:gs,Calendar:hs,Save:ys,Profile:$a},ge=ub;import{jsx as bp}from"react/jsx-runtime";function xs(e){let{...t}=e;return bp(pb,{...t,children:bp(ge.Menu,{})})}var db={Root:va,Content:xa,ToggleMenu:xs},fb=db;import{Collapse as mb,List as gb,ListItem as hb,ListItemIcon as yb,ListItemText as xb,Icon as vb,ListItemButton as bb,styled as Cb}from"@mui/material";import{useState as wb}from"react";import{Fragment as Tb,jsx as nt,jsxs as Cp}from"react/jsx-runtime";var Sb=Cb(bb,{})(({theme:e})=>({height:"32px",cursor:"pointer",gap:e.spacing(2),transition:"0.2s ease-in-out",padding:`${e.spacing(.25)} ${e.spacing(2)} ${e.spacing(.25)} ${e.spacing(2)}`,"&:hover":{backgroundColor:"rgba(89, 195, 224, 15%);","& .MuiTypography-root":{color:e.palette.primary.main,transition:"0.2s ease-in-out"},"& .MuiSvgIcon-root":{color:e.palette.primary.main,transition:"0.2s ease-in-out"},"& .MuiIcon-root":{color:e.palette.primary.main,transition:"0.2s ease-in-out"}},"& .MuiIcon-root":{color:e.palette.grey[500],fontSize:"20px"},"& .MuiTypography-root":{fontSize:"0.805rem",color:e.palette.text.primary},"& .MuiSvgIcon-root":{fontSize:"0.955rem"},"& .MuiListItemIcon-root":{minWidth:"0px"}}));function vs({label:e,icon:t,visible:r=!0,children:o,selected:n=!1,onClick:a,link:i,secondaryLabel:l}){if(!r)return null;let[s,c]=wb(!1),u=!!o;function d(){if(u){c(m=>!m);return}a&&i&&a(i)}function f(m){return typeof t=="string"?nt(vb,{children:t}):m||nt(ge.Circle,{})}return Cp(Tb,{children:[nt(hb,{disableGutters:!0,disablePadding:!0,children:Cp(Sb,{selected:n,disableGutters:!0,onClick:m=>{m.stopPropagation(),d()},children:[nt(yb,{children:f(t)}),nt(xb,{primary:e}),l,u&&nt(ge.Expandable,{open:s})]})}),u&&nt(mb,{in:s,timeout:"auto",unmountOnExit:!0,children:nt(gb,{sx:{"& .MuiListItemButton-root":{paddingLeft:4},"& .MuiList-root > .MuiListItem-root > .MuiListItemButton-root":{paddingLeft:6},"& .MuiList-root > .MuiList-root > .MuiListItemButton-root":{paddingLeft:12}},disablePadding:!0,children:o})})]})}import{ListItem as Ib,ListItemIcon as Eb,ListItemText as Ab,Icon as Mb,ListItemButton as Db,Popper as Fb,styled as Rb}from"@mui/material";import Ob from"lodash";import bs,{useState as Bb}from"react";import{Paper as Pb}from"@mui/material";import{jsx as kb}from"react/jsx-runtime";function In(e){return kb(Pb,{sx:{p:2},elevation:0,...e})}import{jsx as Mt,jsxs as Lb}from"react/jsx-runtime";var _b=Rb(Db,{})(({theme:e})=>({cursor:"pointer",padding:`${e.spacing(1)} ${e.spacing(0)} ${e.spacing(.25)} ${e.spacing(0)}`,minHeight:"32px",flexDirection:"column",justifyContent:"center",alignItem:"center",alignContent:"center","&:hover":{backgroundColor:"rgba(89, 195, 224, 15%);","& .MuiTypography-root":{color:e.palette.primary.main,transition:"0.2s ease-in-out"},"& .MuiSvgIcon-root":{color:e.palette.primary.main,transition:"0.2s ease-in-out"},"& .MuiIcon-root":{color:e.palette.primary.main,transition:"0.2s ease-in-out"}},"& .MuiIcon-root":{color:e.palette.grey[500],fontSize:"20px"},"& .MuiSvgIcon-root":{fontSize:"0.955rem"},"& .MuiTypography-root":{fontSize:"0.805rem",color:e.palette.text.primary},"& .MuiListItemIcon-root":{minWidth:"0px"}}));function wp(e,t){return bs.Children.map(e,r=>{if(!bs.isValidElement(r))return r;let o=r.props?.children?wp(r.props.children,t):null;return bs.cloneElement(r,{open:t,children:o})})}function Cs(e){let{icon:t,label:r,link:o,id:n,selected:a=!1,children:i,onClick:l}=e,[s,c]=Bb(null);function u(){l&&o&&l(o)}function d(p,y){c({element:p.currentTarget,id:y})}function f(){c(null)}let m=wp(i,!0);function g(p){return typeof t=="string"?Mt(Mb,{children:t}):p||Mt(ge.Circle,{})}return Mt(Ib,{disableGutters:!0,disablePadding:!0,children:Lb(_b,{selected:a,onMouseEnter:p=>{o||d(p,n)},onMouseLeave:()=>{o||f()},disableGutters:!0,onClick:p=>{p.stopPropagation(),u()},children:[Mt(Eb,{children:g(t)}),Mt(Ab,{primary:Ob.truncate(r,{length:12})}),s?.id===n&&Mt(Fb,{sx:{zIndex:999999},anchorEl:s?.element,open:!!s?.element,placement:"right-start",children:Mt(In,{elevation:1,sx:{position:"relative","&::before":{content:'""',position:"absolute",left:-8,width:"1.2rem",height:"1.2rem",backgroundImage:'url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0IiBmaWxsPSJub25lIiBzdHJva2U9IiM4MDgwODAiIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIiBjbGFzcz0ibHVjaWRlIGx1Y2lkZS1waW4tc2FmZXR5LW9wZW4iPjxwYXRoIGQ9Ik0yMC44IDMuMmMtMS42LTEuNi00LjEtMS42LTUuNyAwTDEyLjMgNlMxNSA5IDE4IDZjLTMgMyAwIDUuNyAwIDUuN2wyLjgtMi44YzEuNi0xLjYgMS42LTQuMiAwLTUuNyIvPjxwYXRoIGQ9Im03LjEgMjEuMSAxMC4zLTEwLjIiLz48Y2lyY2xlIGN4PSI1IiBjeT0iMTkiIHI9IjMiLz48cGF0aCBkPSJNOSAycy00LjEgOS41LTYuNzU1IDE1LjgiLz48L3N2Zz4=")',backgroundSize:"contain",backgroundRepeat:"no-repeat",transition:"transform 0.2s ease-in-out"},p:1,width:p=>p.mixins.menu?.width},children:m})})]})})}import{jsx as Sp}from"react/jsx-runtime";function ws(e){let{open:t,isFirstLevel:r=!1,...o}=e;return t?Sp(vs,{...o}):Sp(Cs,{...o})}import{createContext as $b,useContext as Nb,useEffect as Vb,useState as zb}from"react";import{jsx as Hb}from"react/jsx-runtime";function Wb(e,t){if(!e)throw new Error(t)}var Tp=$b(null);function Pp(e){let{children:t,storageKey:r="mio:menu"}=e,[o,n]=zb(()=>{let i=window.localStorage.getItem(r)||"true";return i?JSON.parse(i):!0});function a(){n(i=>!i)}return Vb(()=>{window.localStorage.setItem(r,JSON.stringify(o))},[o,r]),Hb(Tp.Provider,{value:{isOpen:o,toggleMenu:a},children:t})}function Gb(){let e=Nb(Tp);return Wb(e,"cannot find MenuContext provider"),e}import{List as Ub,Drawer as jb}from"@mui/material";import{styled as Ap}from"@mui/material/styles";import Ss from"react";import{jsx as Ep,jsxs as Kb}from"react/jsx-runtime";var kp=e=>({width:e?.mixins?.menu?.width||64,background:"#FFFFFF",transition:e.transitions.create("width",{easing:e.transitions.easing.sharp,duration:e.transitions.duration.enteringScreen}),overflowX:"hidden"}),Ip=e=>({background:"#FFFFFF",transition:e.transitions.create("width",{easing:e.transitions.easing.sharp,duration:e.transitions.duration.leavingScreen}),overflowX:"hidden",width:0,[e.breakpoints.up("sm")]:{width:`calc(${e.spacing(12)} + 1px)`}}),qb=Ap(jb,{shouldForwardProp:e=>e!=="open"})(({theme:e,open:t})=>({width:e?.mixins?.menu?.width||64,borderRightStyle:"none",whiteSpace:"nowrap",boxSizing:"border-box",...t&&{...kp(e),"& .MuiDrawer-paper":kp(e)},...!t&&{...Ip(e),"& .MuiDrawer-paper":Ip(e)}})),Yb=Ap("div")(({theme:e})=>e.mixins.toolbar);function Mp(e,t,r,o){return Ss.Children.map(e,n=>{if(!Ss.isValidElement(n))return n;let a=n.props.link?.split("/").filter(Boolean)||[],i=n.props.link||"",c="/"+(t?.split("/").filter(Boolean)||[]).slice(0,a.length).join("/"),u=n.props?.children?Mp(n.props.children,t,r,o):null;return Ss.cloneElement(n,{open:r,selected:c===i,onClick:d=>{o&&o(d)},children:u})})}function Ts(e){let{open:t,toggleMenu:r,children:o,onClickItem:n,listProps:a}=e,l=new URL(window.location.href).pathname,s=Mp(o,l,t,n);return Kb(qb,{variant:"permanent",open:t,onClose:r,children:[Ep(Yb,{}),Ep(Ub,{...a,children:s})]})}import{jsx as Jb}from"react/jsx-runtime";function Zb(e){return e.map(t=>t.visible?Jb(Dp.Item,{link:t.link,id:t.id,label:t.label,icon:t.icon,secondaryLabel:t.secondaryLabel,children:t.items&&Zb(t.items)},t.id):null)}var Dp={Root:Ts,Item:ws,Provider:Pp};var Qb=Dp;import{Button as Xb,Breadcrumbs as eC,Typography as tC}from"@mui/material";import{jsx as Ps}from"react/jsx-runtime";function Fp(e){let{links:t}=e;function r(o,n){location.pathname}return Ps(eC,{sx:{height:"30px",display:"flex",textWrap:"nowrap"},children:t.map((o,n)=>t.length===1||t.length===n+1?Ps(tC,{sx:{fontSize:"10pt",fontWeight:"bolder"},variant:"subtitle1",color:"black",children:o.label},o.link):Ps(Xb,{variant:"text",children:o.label},o.link))})}import{Stack as rC}from"@mui/material";import{jsx as oC}from"react/jsx-runtime";function ks(e){let{children:t}=e;return oC(rC,{pl:1,pr:1,pt:.5,pb:.5,direction:"row",alignContent:"center",alignItems:"center",justifyContent:"space-between",spacing:1,children:t})}var nC={Root:ks},iC=nC;import{Stack as aC}from"@mui/material";import{jsx as sC}from"react/jsx-runtime";function Is({children:e,...t}){return sC(aC,{pt:1,pl:1,pr:1,pb:1,direction:"row",spacing:1,justifyContent:"flex-end",sx:{backgroundColor:r=>r.palette.background.paper,borderTop:r=>`1px solid ${r.palette.border}`},...t,children:e})}import{IconButton as fC}from"@mui/material";import Bp,{useContext as _p,useEffect as Rp,useMemo as cC,useReducer as uC}from"react";var lC=process.env.NODE_ENV==="production",Es="Invariant failed";function As(e,t){if(!e){if(lC)throw new Error(Es);var r=typeof t=="function"?t():t,o=r?"".concat(Es,": ").concat(r):Es;throw new Error(o)}}import{v4 as pC}from"uuid";import{jsx as Op}from"react/jsx-runtime";function dC(e,t){switch(t.type){case"loadFiltersFromStorage":return{...e,filterValues:t?.storageValues?.filterValues,appliedValues:t?.storageValues?.appliedValues};case"updateFilterValues":return{...e,filterValues:t.filterValues};case"updateFilterValue":return{...e,filterValues:{...e.filterValues,[t.payload.name]:t.payload.value}};case"updateAppliedValues":let r=e.filterValues,o=[];if(r&&Object.entries(r).length>0){let[s]=Object.keys(r);o=[{[s]:r[s]}]}return t?.storagePath&&localStorage.setItem(t.storagePath,JSON.stringify({appliedValues:r,filterValuesAsArray:o,filterValues:e.filterValues})),t.onFilterApplied&&t.onFilterApplied(r),{...e,appliedValues:r,filterValuesAsArray:o,isOpen:!1,searchId:pC()};case"updateIsOpen":return{...e,isOpen:t.isOpen,target:t.target};case"updateContainer":return{...e,container:t.container};case"toggleIsOpen":return{...e,isOpen:!e.isOpen};case"deleteAppliedValue":let{[t.filterName]:n,...a}=e.appliedValues||{},{[t.filterName]:i,...l}=e.filterValues||{};if(t?.storagePath){let s=JSON.parse(localStorage.getItem(t.storagePath)||"{}"),{[t.filterName]:c,...u}=s.appliedValues||{},{[t.filterName]:d,...f}=s.filterValues||{};localStorage.setItem(t.storagePath,JSON.stringify({...s,appliedValues:u,filterValues:f}))}return{...e,appliedValues:a,filterValues:l};case"deleteAllAppliedValues":return t.storagePath&&localStorage.removeItem(t.storagePath),t.onFilterApplied&&t.onFilterApplied(t.filterValues),{...e,appliedValues:{},filterValues:t.filterValues}}}var Lp=Bp.createContext({}),$p=Bp.createContext({});function Np(e){let{children:t,filterValues:r,storagePath:o,onFilterApplied:n}=e,[a,i]=uC(dC,{filterValues:{}});Rp(()=>{r!=null&&(i({type:"updateFilterValues",filterValues:r}),i({type:"updateAppliedValues",storagePath:o,onFilterApplied:n}))},[r,o,n]),Rp(()=>{if(o){let s=localStorage.getItem(o);if(s&&s!=="undefined"){let c=JSON.parse(s);i({type:"loadFiltersFromStorage",storageValues:c})}}},[o]);let l=cC(()=>{function s(x){i({type:"updateIsOpen",isOpen:!0,target:x?.target||void 0})}function c(){i({type:"updateIsOpen",isOpen:!1,target:void 0})}function u(){i({type:"toggleIsOpen"})}function d(x){let S=x.target.type,w=x.target.name,C;switch(S){case"text":C=x.target.value;break;case"checkbox":C=x.target.checked;break;default:C=x.target.value}i({type:"updateFilterValue",payload:{name:w,value:C}})}function f(x,S){i({type:"updateFilterValue",payload:{name:x,value:S}})}function m(x){i({type:"updateFilterValues",filterValues:x})}function g(){i({type:"updateAppliedValues",storagePath:o,onFilterApplied:n})}function p(x){i({type:"deleteAppliedValue",filterName:x,storagePath:o,onFilterApplied:n})}function y(){i({type:"deleteAllAppliedValues",filterValues:r,storagePath:o}),i({type:"updateAppliedValues",storagePath:o,onFilterApplied:n})}function v(x){i({type:"updateContainer",container:x})}return{setContainer:v,openFilter:s,closeFilter:c,onChangeFilterValue:d,changeFilterValue:f,changeFilterValues:m,applyFilterValues:g,deleteFilterValue:p,deleteAllFilterValues:y,toggleFilter:u}},[r]);return Op($p.Provider,{value:l,children:Op(Lp.Provider,{value:a,children:t})})}function sr(){let e=_p(Lp);return As(e,"cannot find FilterDataContext provider"),e}function Ie(){let e=_p($p);return As(e,"cannot find FilterApiContextContext provider"),e}import{jsx as Vp}from"react/jsx-runtime";function Ms(){let{openFilter:e}=Ie();return Vp(fC,{onClick:t=>{e(t)},children:Vp(ge.Filter,{})})}import{Popover as mC}from"@mui/material";import{jsx as gC}from"react/jsx-runtime";function Ds(e){let{children:t}=e,{isOpen:r,container:o}=sr(),{closeFilter:n}=Ie();return gC(mC,{elevation:0,open:r,onClose:n,anchorEl:o,anchorOrigin:{vertical:"bottom",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"right"},sx:{"& .MuiPopover-paper":{width:"360px",border:i=>`1px solid ${i.palette.border}`,borderRadius:"8px",mt:.5,pt:2}},children:t})}import{Box as hC}from"@mui/material";import{jsx as yC}from"react/jsx-runtime";function Fs({children:e}){return yC(hC,{mt:1,ml:1,mr:1,mb:2,children:e})}import{Button as xC,Stack as vC}from"@mui/material";import{jsx as Rs,jsxs as bC}from"react/jsx-runtime";function Os(){let{applyFilterValues:e}=Ie();return Rs(xC,{variant:"contained",onClick:()=>{e()},children:bC(vC,{direction:"row",spacing:.5,alignItems:"center",children:[Rs(ge.Search,{sx:{fontSize:"0.855rem"}})," ",Rs("span",{children:"Pesquisar"})]})})}import{Chip as CC}from"@mui/material";import{jsx as wC}from"react/jsx-runtime";function Bs(e){let{children:t,disabledDelete:r=!1,...o}=e;return wC(CC,{...o})}import{usePopover as SC}from"@data-c/hooks";import{Box as TC,Button as zp,Popover as PC,Stack as Wp}from"@mui/material";import $r from"react";import{jsx as _s,jsxs as Ls}from"react/jsx-runtime";function $s({children:e}){let{appliedValues:t}=sr(),{applyFilterValues:r,deleteFilterValue:o}=Ie(),{isOpen:n,open:a,close:i,anchorEl:l,data:s}=SC(),c=$r.Children.map(e,u=>!$r.isValidElement(u)||!(t&&u.props.name in t)?null:$r.cloneElement(u,{onDelete:u.props.disabledDelete?void 0:f=>{o&&o(u.props.name||""),i()},onClick:f=>{a(f,{target:f.currentTarget,name:u.props.name,disabledDelete:u.props.disabledDelete||!1})}}));return Ls(Wp,{direction:"row",spacing:.5,flex:1,justifyContent:"flex-end",children:[c,Ls(PC,{open:!!n||!1,onClose:()=>i(),anchorEl:l,elevation:0,sx:{"& .MuiPopover-paper":{minWidth:"300px",border:u=>`1px solid ${u.palette.border}`,borderRadius:"8px",mt:1}},anchorOrigin:{vertical:"bottom",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"right"},children:[_s(TC,{pt:2,pl:1,pr:1,pb:2,children:$r.Children.map(e,u=>$r.isValidElement(u)&&u.props.name===s?.name?u.props.children:null)}),Ls(Wp,{sx:{backgroundColor:u=>u.palette.background.paper,borderTop:u=>`1px solid ${u.palette.border}`},p:1,direction:"row",justifyContent:"flex-end",spacing:1,children:[!s?.disabledDelete&&_s(zp,{color:"error",onClick:()=>{o&&o(s?.name||""),i()},children:"Apagar"}),_s(zp,{variant:"contained",onClick:()=>{i(),r()},children:"Aplicar"})]})]})]})}import{Stack as Gp}from"@mui/material";import{useEffect as kC,useRef as IC}from"react";import{jsx as Hp,jsxs as EC}from"react/jsx-runtime";function Ns({children:e}){let t=IC(null),{setContainer:r}=Ie(),{container:o}=sr();return kC(()=>{let n=()=>{t.current&&r(t.current)};return n(),window.addEventListener("resize",n),()=>{window.removeEventListener("resize",n)}},[o]),EC(Gp,{ref:t,direction:"row",alignContent:"center",alignItems:"center",spacing:1,children:[Hp(ge.Search,{sx:{fontSize:"0.95rem"}}),Hp(Gp,{width:"100%",direction:"row",justifyContent:"space-between",alignItems:"center",alignContent:"center",children:e})]})}import{Button as AC}from"@mui/material";import{jsx as MC}from"react/jsx-runtime";function Vs(){let{deleteAllFilterValues:e}=Ie();return MC(AC,{color:"error",onClick:()=>{e&&e()},children:"Resetar"})}import{Box as DC}from"@mui/material";import{jsx as FC}from"react/jsx-runtime";function zs(e){let{children:t}=e;return FC(DC,{sx:{border:r=>`1px solid ${r.palette.border}`,borderRadius:"90px",flexGrow:1,pl:1,pr:1},children:t})}import{InputBase as RC}from"@mui/material";import OC from"lodash";import{jsx as BC}from"react/jsx-runtime";function Ws(e){let{onChange:t,...r}=e,o=OC.debounce(a=>t(a),500);function n(a){let i=a.target.value;o(i)}return BC(RC,{fullWidth:!0,onChange:n,...r})}var _C={Root:zs,SearchTextField:Ws,Container:Ns,AdvancedContainer:Ds,AdvancedContent:Fs,AdvancedActionsContainer:Is,AdvancedButton:Ms,Provider:Np,ApplyButton:Os,ResetButton:Vs,Chips:$s,Chip:Bs},LC=_C;import{ColumnsPanelTrigger as J1,useGridApiRef as X1}from"@mui/x-data-grid";import{useEffect as Zp,useMemo as WC}from"react";import{Circle as Qp}from"@mui/icons-material";import{LinearProgress as GC,Stack as HC}from"@mui/material";import{DataGrid as UC,gridFilteredSortedRowIdsSelector as jC}from"@mui/x-data-grid";import{ptBR as qC}from"@mui/x-data-grid/locales";import{Stack as Gs,Typography as Up}from"@mui/material";import{jsx as En,jsxs as jp}from"react/jsx-runtime";function Hs(){return jp(Gs,{alignItems:"center",justifyContent:"center",gap:2,padding:2,maxWidth:"400px",minWidth:"200px",children:[En(Gs,{width:"250px",height:"250px",alignItems:"center",justifyContent:"center",borderRadius:"50%",sx:{background:"linear-gradient(to top, #ffffff, #fdfcfd, #fafafa, #f8f7f8, #f5f5f6);"},children:En("img",{src:"https://datac-site-assets.s3.sa-east-1.amazonaws.com/empty-data.svg",alt:"Imagem de notifica\xE7\xE3o",width:"148px",height:"148px"})}),jp(Gs,{spacing:1,textAlign:"center",children:[En(Up,{variant:"h4",component:"h2",fontWeight:"600",children:"Nenhum registro encontrado"}),En(Up,{variant:"body2",whiteSpace:"normal",children:"Tente outra pesquisa ou adicione um novo registro."})]})]})}import{Stack as Us,Typography as qp}from"@mui/material";import{jsx as An,jsxs as Yp}from"react/jsx-runtime";function js({errorMessage:e}){return Yp(Us,{alignItems:"center",justifyContent:"center",gap:2,padding:2,maxWidth:"400px",minWidth:"200px",children:[An(Us,{width:"250px",height:"250px",alignItems:"center",justifyContent:"center",borderRadius:"50%",sx:{background:"linear-gradient(to top, #ffffff, #fdfcfd, #fafafa, #f8f7f8, #f5f5f6);"},children:An("img",{src:"https://datac-site-assets.s3.sa-east-1.amazonaws.com/error.svg",alt:"Imagem de erro",width:"148px",height:"148px"})}),Yp(Us,{gap:1,textAlign:"center",children:[An(qp,{variant:"h4",component:"h2",fontWeight:"600",children:"Ops! Algo deu errado"}),An(qp,{variant:"body2",children:e})]})]})}import{createContext as $C,useContext as NC,useState as qs}from"react";import{useGridApiRef as VC}from"@mui/x-data-grid";import{jsx as zC}from"react/jsx-runtime";var Kp=$C({});function Ys({children:e}){let[t,r]=qs({type:"include",ids:new Set}),[o,n]=qs(!1),[a,i]=qs(!1),l=VC();function s(){r({type:"include",ids:new Set}),n(!0)}return zC(Kp.Provider,{value:{apiRef:l,rowsSelectedId:t,clearCallback:o,breakpoint:a,setClearCallback:n,setBreakpoint:i,setRowsSelectedId:r,clearRowsSelectedId:s},children:e})}function ze(){return NC(Kp)}import{jsx as lr,jsxs as KC}from"react/jsx-runtime";var YC=({apiRef:e})=>jC(e);function Ks(e){let{error:t,isLoading:r,isFetching:o,data:n,columns:a,controlledRowsSelectedId:i,onClearRowsSelectedId:l,onRowSelectionChange:s,onCellKeyDown:c,onRowDoubleClick:u,stackProps:d,slots:f,...m}=e,{rowsSelectedId:g,setRowsSelectedId:p,clearCallback:y,setClearCallback:v,apiRef:x}=ze(),S=WC(()=>k=>k.map(P=>P.headerName==="A\xE7\xF5es"?{...P,minWidth:P.minWidth||80,maxWidth:P.maxWidth||P.width||80,headerClassName:"sticky-header",cellClassName:"sticky-cell"}:{...P,flex:P.flex||1,minWidth:P.minWidth||100,headerClassName:P?.enableStickyColumns?"sticky-header":"",cellClassName:P?.enableStickyColumns?"sticky-cell":""}),[a]);Zp(()=>{i&&p(i)},[i]),Zp(()=>{y&&(l&&l({type:"include",ids:new Set}),v(!1))},[y]);function w(k,P,Q){switch(P.ctrlKey&&P.code==="KeyE"?"ctrl+e":P.code){case"Enter":P.preventDefault(),c&&c("edit",k.id);break;case"F3":P.preventDefault(),c&&c("edit",k.id);break;case"Delete":P.preventDefault(),c&&c("delete",k.id);break;case"ctrl+e":P.preventDefault(),(E=>{x?.current&&x.current.exportDataAsCsv(E)})({getRowsToExport:YC});break;default:break}}function C(k,P,Q){u&&u("edit",k.id)}return KC(HC,{height:"100%",minHeight:"500px",position:"relative",...d,children:[!r&&o&&lr(GC,{sx:{position:"absolute",top:0,right:0,left:0,zIndex:999,height:"3px"}}),lr(UC,{apiRef:x,rows:n,columns:S(a),density:"compact",hideFooterPagination:!0,hideFooter:!0,loading:r,rowHeight:43,columnHeaderHeight:43,disableVirtualization:!0,onRowDoubleClick:C,onCellKeyDown:w,disableRowSelectionOnClick:!0,rowSelectionModel:g,onRowSelectionModelChange:(k,P)=>{s&&s(k,P),!i&&p(k)},slots:{booleanCellFalseIcon:()=>lr(Qp,{color:"error",sx:{fontSize:"10pt"}}),booleanCellTrueIcon:()=>lr(Qp,{color:"success",sx:{fontSize:"10pt"}}),noRowsOverlay:()=>!r&&t?lr(js,{errorMessage:t}):lr(Hs,{}),...f},slotProps:{loadingOverlay:{variant:"skeleton",noRowsVariant:"skeleton"}},disableColumnFilter:!0,localeText:qC.components.MuiDataGrid.defaultProps.localeText,sx:{border:"none",borderRadius:0,"--DataGrid-rowBorderColor":"#edf2f9","--DataGrid-containerBackground":"#f4f6fa",".MuiDataGrid-overlayWrapperInner":{display:"flex",alignItems:"center",justifyContent:"center"},".MuiDataGrid-row":{backgroundColor:"white","&:nth-of-type(even)":{backgroundColor:"#f9fafd"},":hover":{backgroundColor:"#e9e9e9"},"&.Mui-selected":{backgroundColor:"rgb(238, 249, 252)","&:hover":{backgroundColor:"rgb(222, 243, 249)"}}},".MuiDataGrid-cell":{fontSize:"12px",color:"#0b0e14"},".MuiDataGrid-columnHeaders":{border:"solid 1px #edf2f9"},".MuiDataGrid-columnHeaderTitle":{fontSize:"12px",color:"#0b0e14",fontWeight:"600"},"& .sticky-cell":{position:"sticky",right:0,background:"inherit",zIndex:1},"& .sticky-header":{position:"sticky",right:0,background:"inherit",zIndex:2}},...m})]})}import{GridActionsCellItem as ZC}from"@mui/x-data-grid";import{jsx as QC}from"react/jsx-runtime";function Zs(e){let{ref:t,...r}=e;return QC(ZC,{...r,ref:t})}import{GridActionsCellItem as JC}from"@mui/x-data-grid";import{Trash2 as XC}from"lucide-react";import{jsx as Jp}from"react/jsx-runtime";function Qs(e){let{ref:t,...r}=e;return Jp(JC,{color:"error",label:"Deletar",icon:Jp(XC,{size:16}),...r,ref:t})}import{GridActionsCellItem as e1}from"@mui/x-data-grid";import{Pencil as t1}from"lucide-react";import{jsx as Xp}from"react/jsx-runtime";function Js(e){let{ref:t,...r}=e;return Xp(e1,{label:"Editar",color:"primary",icon:Xp(t1,{size:16}),...r,ref:t})}import{useEffect as r1}from"react";import{Stack as o1,useMediaQuery as n1,useTheme as i1}from"@mui/material";import{jsx as a1}from"react/jsx-runtime";function Xs({children:e,breakpoints:t}){let{setBreakpoint:r}=ze(),o=i1(),n=n1(o.breakpoints.down(t||"md"));return r1(()=>{r(n)},[n]),a1(o1,{flexDirection:"row",alignItems:"center",justifyContent:"flex-end",gap:1,marginLeft:"auto",flexGrow:1,children:e})}import{GridActionsCellItem as s1}from"@mui/x-data-grid";import{ArrowBigDown as l1}from"lucide-react";import{jsx as ed}from"react/jsx-runtime";function el(e){let{ref:t,...r}=e;return ed(s1,{color:"primary",label:"Transportar",icon:ed(l1,{size:16}),...r,ref:t})}import{Button as c1,CircularProgress as td,IconButton as u1,Tooltip as p1,Box as d1}from"@mui/material";import{Fragment as f1,jsx as Nr,jsxs as rd}from"react/jsx-runtime";function Vr(e){let{isLoading:t,startIcon:r,children:o,title:n,...a}=e,{breakpoint:i}=ze();return Nr(f1,{children:i?Nr(p1,{title:o,children:rd(u1,{...a,color:"primary",disabled:t?!0:a.disabled,children:[r,t&&Nr(td,{color:"secondary",size:14,sx:{position:"absolute",top:"25%",bottom:"25%",left:"25%",right:"25%",transform:"translate(-50%, -50%)"}})]})}):Nr(c1,{startIcon:r,disabled:t?!0:a.disabled,sx:{position:"relative",height:"26px",minWidth:"70px",padding:"7px 8px 8px",border:"1px solid rgba(223, 226, 231, 0.8)",borderRadius:"6px",display:"flex",alignItems:"center",overflow:"hidden",whiteSpace:"nowrap",flexShrink:1,transition:"width 0.2s ease"},...a,children:rd(d1,{component:"span",sx:{transition:"opacity 0.2s ease, width 0.2s ease",overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis"},children:[t&&Nr(td,{color:"secondary",size:14,sx:{position:"absolute",top:"22%",left:"44%",transform:"translate(-50%, -50%)"}}),o]})})})}import{GridActionsCellItem as m1}from"@mui/x-data-grid";import{jsx as od}from"react/jsx-runtime";function tl(e){let{event:t,onClick:r,...o}=e;return od(m1,{label:"A\xE7\xE3o",onClick:()=>{},icon:od("span",{children:"\u{1F527}"})})}import{Delete as g1}from"@mui/icons-material";import{GridActionsCellItem as h1}from"@mui/x-data-grid";import{jsx as nd}from"react/jsx-runtime";function rl({onClick:e,...t}){return nd(h1,{icon:nd(g1,{}),label:"Delete",color:"primary",onClick:()=>{e&&e("delete")},...t})}import{Edit as y1}from"@mui/icons-material";import{GridActionsCellItem as x1}from"@mui/x-data-grid";import{jsx as id}from"react/jsx-runtime";function ol({onClick:e,...t}){return id(x1,{icon:id(y1,{}),label:"Edit",color:"primary",onClick:()=>e&&e("edit"),...t})}import{Children as v1,cloneElement as b1,isValidElement as C1}from"react";import{Fragment as w1,jsx as S1}from"react/jsx-runtime";function nl(e){let{children:t,onClick:r}=e;return S1(w1,{children:v1.map(t,o=>{if(C1(o))return b1(o,{onClick:r})})})}import{GetApp as T1}from"@mui/icons-material";import{GridActionsCellItem as P1}from"@mui/x-data-grid";import{jsx as ad}from"react/jsx-runtime";function il({onClick:e,...t}){return ad(P1,{icon:ad(T1,{}),label:"Transport",color:"primary",onClick:()=>e&&e("transport"),...t})}import{Stack as k1}from"@mui/material";import{jsx as I1}from"react/jsx-runtime";function al(e){return I1(k1,{direction:"row",width:"100%",flexGrow:1,alignItems:"center",gap:1.5,sx:{background:"#f4f"},...e})}import{FileDownload as E1}from"@mui/icons-material";import{gridFilteredSortedRowIdsSelector as A1}from"@mui/x-data-grid";import{jsx as sd}from"react/jsx-runtime";var M1=({apiRef:e})=>A1(e);function sl(){let{apiRef:e}=ze(),t=r=>{e?.current&&e.current.exportDataAsCsv(r)};return sd(Vr,{startIcon:sd(E1,{}),onClick:()=>t({getRowsToExport:M1}),children:"Exportar CSV"})}import{TableFooter as D1}from"@mui/material";import{jsx as F1}from"react/jsx-runtime";function ll(e){return F1(D1,{...e,sx:{height:"54px",paddingX:"12px",gap:"12px",display:"flex",alignItems:"center",backgroundColor:"white",borderBottomLeftRadius:"8px",borderBottomRightRadius:"8px",borderTop:"1px solid #edf2f9"}})}import{useMemo as ld}from"react";import{TextField as R1,Pagination as O1,MenuItem as B1,Stack as cd,Typography as _1}from"@mui/material";import{pluralizar as ud}from"@data-c/hooks";import{jsx as Mn,jsxs as pd}from"react/jsx-runtime";function cl(e){let{onChangePageSize:t,onChangePage:r,pagination:o,rowsPerPageOptions:n=[15,50,100,200]}=e,{page:a,pageSize:i=15,totalRecords:l}=o||{},s=ld(()=>o?.lastPage?o.lastPage:(l||0)<i?1:Math.max(Math.ceil((l||0)/i)),[l,i]),c=ld(()=>{if((l||0)<i)return`Exibindo ${ud(l||0,"registro","registros",!0)}`;let d=i;if(a===s){let f=(l||0)%i;d=f===0?i:f}return`Exibindo ${ud(d||0,"registro","registros",!0)} de ${l}`},[o,s]);return pd(cd,{width:"100%",direction:"row",alignItems:"center",gap:2,marginLeft:"auto",children:[Mn(_1,{variant:"body2",fontSize:"13px",fontWeight:"500",whiteSpace:"nowrap",children:c}),!0&&pd(cd,{direction:"row",alignItems:"center",gap:2,marginLeft:"auto",children:[Mn(R1,{sx:{width:"78px",fontSize:"8pt"},size:"small",value:i||0,select:!0,onChange:d=>{t&&t(parseInt(d.target.value))},children:n.map(d=>Mn(B1,{value:d,children:d},d))}),Mn(O1,{variant:"outlined",shape:"rounded",count:s||0,showFirstButton:!0,showLastButton:!0,onChange:(d,f)=>{r&&r(f)},page:a||0,color:"primary"})]})]})}import{useEffect as L1,useRef as $1,useState as N1}from"react";import{Stack as V1}from"@mui/material";import{jsx as dd}from"react/jsx-runtime";function ul({children:e,height:t,...r}){let o=$1(null),[n,a]=N1(500);return L1(()=>{let i=()=>{let l=o.current;if(!l)return;let s=l.getBoundingClientRect().top;a(window.innerHeight-s)};return i(),window.addEventListener("resize",i),()=>{window.removeEventListener("resize",i)}},[]),dd(V1,{ref:o,sx:{backgroundColor:"#f4f6fa",border:"1px solid #edf2f9",borderRadius:2,height:t||`calc(${n}px - 16px)`,...r.sx},...r,children:dd(Ys,{children:e})})}import{Stack as z1,Typography as W1}from"@mui/material";import{useMemo as G1}from"react";import{jsx as U1,jsxs as H1}from"react/jsx-runtime";function pl(e){let{countTitle:t,gender:r}=e,{rowsSelectedId:o}=ze(),n=o?.ids.size||0,a=G1(()=>{if(!t)return"";let i=r==="feminino"?"selecionada":"selecionado",l=r==="feminino"?"selecionadas":"selecionados",s=r==="feminino"?"Nenhuma":"Nenhum";return n===1?`${t} ${i}`:n&&n>1?`${t.split(" ").map(c=>`${c}s`).join(" ")} ${l}`:`${s} ${t} ${i}`},[n]);return U1(z1,{children:H1(W1,{variant:"body2",fontSize:"13px",fontWeight:"500",whiteSpace:"nowrap",children:[n&&n>0?n:""," ",a]})})}import{Typography as j1,useTheme as q1}from"@mui/material";import{jsx as Y1}from"react/jsx-runtime";function dl({children:e,titleDivider:t=!1,sx:r}){let o=q1();return Y1(j1,{variant:"h6",whiteSpace:"nowrap",sx:{borderRight:t?`solid 1px ${o.palette.grey[300]}`:"none",paddingRight:1.5,...r},children:e})}import{Paper as K1,Stack as Z1}from"@mui/material";import{jsx as Q1}from"react/jsx-runtime";function fl({children:e}){return Q1(Z1,{component:K1,elevation:0,gap:1.5,flexDirection:"row",justifyContent:"space-between",alignItems:"center",p:1,borderRadius:"8px 8px 0 0",sx:{width:"100%"},children:e})}var ew={CellActionTransport:il,SelectionCounter:pl,CellActionDelete:rl,ExportCsvButton:sl,CellActionEdit:ol,CellActions:nl,CellAction:tl,Pagination:cl,Actions:Xs,Toolbar:fl,Content:al,Button:Vr,Footer:ll,Table:Ks,Title:dl,Root:ul,Action:Zs,ActionEdit:Js,ActionDelete:Qs,ActionTransport:el,ColumnsPanelTrigger:J1,useGridApiRef:X1},tw=ew;import{Stack as rw}from"@mui/material";import{jsx as ow}from"react/jsx-runtime";function ml(e){return ow(rw,{gap:.5,overflow:"hidden",...e})}import{Stack as nw}from"@mui/material";import{jsx as iw}from"react/jsx-runtime";function gl(e){return iw(nw,{sx:[{overflowY:"auto",overflowX:"hidden"},...Array.isArray(e.sx)?e.sx:e.sx?[e.sx]:[]],...e})}import{MenuItem as aw}from"@mui/material";import{jsx as sw}from"react/jsx-runtime";function hl(e){return sw(aw,{...e})}var lw={Root:ml,Content:gl,Item:hl},zr=lw;import{createContext as cw,useCallback as fd,useContext as uw,useEffect as pw,useState as md}from"react";import{jsx as dw}from"react/jsx-runtime";var gd=cw(void 0),hd=({children:e,open:t,onOpenChange:r})=>{let[o,n]=md(!1),[a,i]=md(null),l=fd(c=>{i(c),n(!0),r?.(!0)},[]),s=fd(()=>{n(!1),i(null),r?.(!1)},[]);return pw(()=>{n(!!t)},[t]),dw(gd.Provider,{value:{isOpen:o,open:l,close:s,anchorEl:a,setAnchorEl:i},children:e})},cr=()=>{let e=uw(gd);if(!e)throw new Error("usePopover must be used within a PopoverProvider");return e};import{jsx as fw}from"react/jsx-runtime";function yl(e){let{children:t,open:r,onOpenChange:o}=e;return fw(hd,{open:r,onOpenChange:o,children:t})}import{Button as mw}from"@mui/material";import{Slot as gw}from"@radix-ui/react-slot";import{jsx as hw}from"react/jsx-runtime";function xl(e){let{asChild:t=!1,...r}=e,o=t?gw:mw,{open:n}=cr();return hw(o,{onClick:a=>{n(a.currentTarget)},...r})}import{Button as yw}from"@mui/material";import{Slot as xw}from"@radix-ui/react-slot";import{jsx as vw}from"react/jsx-runtime";function vl(e){let{asChild:t=!1,...r}=e,o=t?xw:yw,{close:n}=cr();return vw(o,{onClick:a=>{n()},...r})}import{Popover as bw}from"@mui/material";import{jsx as Cw}from"react/jsx-runtime";function bl(e){let{isOpen:t,close:r,anchorEl:o}=cr();return Cw(bw,{open:t,anchorEl:o,onClose:r,anchorOrigin:{vertical:"bottom",horizontal:"center"},slotProps:{paper:{sx:{borderRadius:"12px"}}},transformOrigin:{vertical:"top",horizontal:"center"},...e,children:e.children})}var ww={Root:yl,Trigger:xl,Content:bl,Close:vl},ur=ww;import{Button as Sw,ButtonGroup as Tw,ClickAwayListener as Pw,Grow as kw,MenuList as Iw,MenuItem as Ew,Paper as Aw,Popper as Mw}from"@mui/material";import yd,{Children as Dw,useEffect as xd,useRef as Fw,useState as vd}from"react";import{jsx as it,jsxs as Cd}from"react/jsx-runtime";var bd="mio-componente:button-group:value";function Cl(e){let{children:t,value:r,onChange:o,isLoading:n,disableMemory:a}=e,[i,l]=vd(!1),[s,c]=vd(()=>{if(!a)return window.localStorage.getItem(bd)||r||0;if(r)return r}),u=Fw(null);xd(()=>{c(r===void 0?0:r)},[r]),xd(()=>{window.localStorage.setItem(bd,s||0),c(s)},[s]);let d=[],f=Dw.map(t,(m,g)=>{d.push({label:m.props.children,value:m.props?.value||g});let p=yd.cloneElement(m,{isLoading:n,sx:{maxWidth:"300px",width:"120px"},value:m.props?.value||g});return!s&&g===0||s&&Number(p.props.value)===Number(s)?p:null});return Cd(yd.Fragment,{children:[Cd(Tw,{variant:"contained",size:"small",ref:u,children:[f,it(Sw,{disabled:n,"data-allow-click":"true",onClick:()=>{l(m=>!m)},sx:{width:"30px"},children:it(Mr,{sx:{fontSize:"13pt"}})})]}),it(Mw,{open:i,transition:!0,anchorEl:u.current,sx:{zIndex:999999},placement:"bottom-end",children:({TransitionProps:m})=>it(kw,{...m,children:it(Aw,{sx:{minWidth:"120px"},children:it(Pw,{onClickAway:()=>l(!1),children:it(Iw,{autoFocusItem:!0,disablePadding:!0,children:d.map(g=>it(Ew,{onClick:()=>{o?o(g.value):c(g.value),l(!1)},children:g.label},g.value))})})})})})]})}import{jsx as Rw}from"react/jsx-runtime";function wl(e){return Rw(R,{...e})}var Ow={Root:Cl,Button:wl},Bw=Ow;import{Box as _w}from"@mui/material";import{jsx as Lw}from"react/jsx-runtime";function Sl(e){let{children:t,sx:r,...o}=e;return Lw(_w,{sx:{position:"relative",border:n=>`1px solid ${n.palette.divider} `,boxShadow:n=>`1px 2px 4px ${n.palette.divider}`,borderRadius:2,...r},...o,children:t})}import{Box as $w,Stack as Nw}from"@mui/material";import wd from"react";import{jsx as Sd}from"react/jsx-runtime";function Tl(e){let{children:t}=e,r=wd.Children.toArray(t).map(o=>wd.isValidElement(o)&&Sd($w,{sx:{},children:o}));return Sd(Nw,{sx:{backgroundColor:o=>o.palette.background.paper,borderBottom:o=>`solid 1px ${o.palette.divider}`,height:"30px",pl:1,pr:1},direction:"row",alignItems:"center",justifyContent:"space-between",children:t})}import{Typography as Vw}from"@mui/material";import{jsx as zw}from"react/jsx-runtime";function Pl(e){let{title:t}=e;return zw(Vw,{component:"h6",variant:"h6",children:t})}import{Stack as Ww}from"@mui/material";import{jsx as Gw}from"react/jsx-runtime";function kl(e){let{children:t,...r}=e;return Gw(Ww,{...r,sx:{p:1,...r.sx},children:t})}var Hw={Root:Sl,Content:kl,Header:Tl,Title:Pl},Uw=Hw;import*as jw from"lucide-react";import{jsx as Kw}from"react/jsx-runtime";var qw=({name:e,size:t=16,strokeWidth:r=1.5,color:o="currentColor",...n})=>{let a=jw[e];return Kw(a,{size:t,strokeWidth:r,color:o,...n})},Yw=qw;import{Typography as Zw,useTheme as Qw}from"@mui/material";import{jsx as Xw}from"react/jsx-runtime";function Jw(e,t){switch(t){case"title1":return{fontSize:"2rem",color:e.palette.primary.main,fontWeight:700};case"title2":return{fontSize:"1.25rem",color:e.palette.text.secondary,fontWeight:500};case"title3":return{fontSize:"0.850rem",color:e.palette.grey[600],fontWeight:700};default:return{}}}function Dn({children:e,variant:t="title1",sx:r,...o}){let n=Qw();return Xw(Zw,{sx:{...Jw(n,t),...r},...o,children:e})}import{Box as eS}from"@mui/material";import{jsx as tS}from"react/jsx-runtime";function Il(e){return tS(eS,{mt:2,sx:{display:"flex",flexDirection:"column",flexGrow:1},...e})}import{Stack as rS}from"@mui/material";import{jsx as oS}from"react/jsx-runtime";function El(e){let{children:t,...r}=e;return oS(rS,{direction:"row",alignContent:"center",alignItems:"center",justifyContent:"space-between",spacing:1,...r,children:t})}import{Container as nS}from"@mui/material";import{jsx as iS}from"react/jsx-runtime";function Al(e){return iS(nS,{sx:{padding:1,inset:0,overflow:"auto"},...e})}import{jsx as aS}from"react/jsx-runtime";function Ml({title:e,...t}){return aS(Dn,{variant:"title3",...t,children:e})}var sS={Root:Al,Header:El,Title:Ml,Content:Il},lS=sS;import{CircularProgress as kd,IconButton as Td,Autocomplete as cS,Stack as Id,TextField as uS,Typography as pS}from"@mui/material";import dS from"lodash";import Pd,{useCallback as fS}from"react";import{jsx as Ke,jsxs as gS}from"react/jsx-runtime";function mS(){return gS(Id,{direction:"row",spacing:1,alignContent:"center",alignItems:"center",children:[Ke(kd,{size:16}),Ke(pS,{variant:"body1",children:"Carregando..."})]})}function Fn(e){let{value:t,onChange:r,onSearchChange:o,onDoubleClick:n,options:a,isLoading:i,renderValue:l,required:s,readonly:c,multiple:u,disableCloseOnSelect:d,endAdornment:f,disabled:m,filterOptions:g,renderOption:p,...y}=e;function v(C,k=!1,P=!1){if(C){let Q=Pd.Children.toArray(C.props?.children),$=Q.length===1?0:1;return Q.splice($,0,Ke(Td,{sx:{padding:"2px"},size:"small",color:"default",onClick:()=>{},disabled:P,children:"'s'"})),f&&Q.unshift(f),k&&Q.unshift(Ke(Td,{disabled:!0,children:Ke(kd,{color:"primary",size:18})})),Ke(Id,{direction:"row",spacing:2,children:Pd.cloneElement(C,{},Q)})}return C}let x=dS.debounce((C,k)=>{k!=="selectOption"&&o&&o(C,k)},500),S=fS((C,k,P)=>{x(k,P)},[x]);function w(C){r&&r(C)}return Ke(cS,{onDoubleClick:()=>{n&&n()},multiple:u,loading:i,loadingText:Ke(mS,{}),value:t,onChange:(C,k)=>w(k),options:a,onInputChange:S,getOptionLabel:l,readOnly:c,disabled:m,disableCloseOnSelect:d,filterOptions:g,renderOption:p,renderInput:C=>Ke(uS,{slotProps:{inputLabel:{shrink:!0},input:{...C.InputProps,startAdornment:f}},...C,required:s,fullWidth:!0,disabled:m,...y}),noOptionsText:"Digite algo para pesquisar"})}import Dd,{isValidElement as bS}from"react";import{createContext as hS,useContext as yS}from"react";var Ed=hS(void 0),Rn=()=>{let e=yS(Ed);if(!e)throw new Error("useTransporterScope must be used inside <Transporter.Root />");return e},Ad=Ed.Provider;import{createStore as xS,useStore as vS}from"zustand";var On=new Map;function Md(e){if(On.has(e))return On.get(e);let t=xS((r,o)=>({isOpen:!1,query:void 0,setQuery:n=>r({query:n}),setValue:n=>r({value:n}),openTransporter:()=>r({isOpen:!0}),closeTransporter:async n=>{if(r({isOpen:!1}),n)if(Array.isArray(o().value)){if(typeof n!="string"&&typeof n!="number"){let s=o().value,u=s.includes(n)?s.filter(d=>d!==n):[...s,n];o().triggerOnChange(u);return}let a=o().value,l=a.find(s=>s?.id===n.id)?a.filter(s=>s!==n):[...a,n];o().triggerOnChange(l)}else o().triggerOnChange(n)},onChange:void 0,setOnChange:n=>r({onChange:n}),triggerOnChange:n=>{o().onChange?.(n)}}));return On.set(e,t),t}function Wr(e){let t=On.get(e);if(!t)throw new Error(`No transporter store found for id "${e}"`);return vS(t)}import{jsx as Dl,jsxs as Fd}from"react/jsx-runtime";function Fl(e){let{children:t,title:r}=e,o=Rn(),{isOpen:n,closeTransporter:a}=Wr(o);if(!n)return null;let i=Dd.Children.map(t,l=>{if(bS(l))return Dd.cloneElement(l,{displayTransportAction:!0,onTransport:s=>{a(s)}});throw new Error("Tipo inv\xE1lido para DataTable")});return Fd(O.Root,{open:n,onClose:a,fullWidth:!0,maxWidth:"lg",children:[Fd(O.Header,{children:[Dl(O.Title,{children:r||"Caixa de Busca Avan\xE7ada"}),Dl(O.ActionClose,{onClose:a})]}),Dl(O.Content,{children:i})]})}import{useEffect as CS}from"react";import{jsx as wS}from"react/jsx-runtime";function Rl(e){let{scope:t,onChange:r,value:o,children:n}=e,a=Md(t);return a.getState().setValue(o),CS(()=>(a.getState().setOnChange(r),()=>{a.getState().setOnChange(void 0)}),[t,r]),wS(Ad,{value:t,children:n})}import{jsx as SS}from"react/jsx-runtime";function Ol(e){let{disableLocalFiltering:t,renderOption:r,...o}=e,n=Rn(),{openTransporter:a,triggerOnChange:i,value:l}=Wr(n);return SS(Fn,{onDoubleClick:()=>a(),value:l,onChange:s=>{i(s)},...t&&{filterOptions:s=>s},renderOption:r,...o})}var TS={Root:Rl,TextField:Ol,Container:Fl};var PS=TS;import{TextField as kS}from"@mui/material";import{jsx as IS}from"react/jsx-runtime";function be(e){return IS(kS,{...e,slotProps:{input:{readOnly:e.readonly,...e.slotProps?.input},...e.slotProps}})}import{useMemo as ES,useState as AS}from"react";import{jsx as DS}from"react/jsx-runtime";var Bn=e=>e.replace(/\D/g,""),Rd=e=>{let t=Bn(e).slice(0,11);return t.length<=3?t:t.length<=6?`${t.slice(0,3)}.${t.slice(3)}`:t.length<=9?`${t.slice(0,3)}.${t.slice(3,6)}.${t.slice(6)}`:`${t.slice(0,3)}.${t.slice(3,6)}.${t.slice(6,9)}-${t.slice(9)}`},Od=e=>{let t=Bn(e).slice(0,14);return t.length<=2?t:t.length<=5?`${t.slice(0,2)}.${t.slice(2)}`:t.length<=8?`${t.slice(0,2)}.${t.slice(2,5)}.${t.slice(5)}`:t.length<=12?`${t.slice(0,2)}.${t.slice(2,5)}.${t.slice(5,8)}/${t.slice(8)}`:`${t.slice(0,2)}.${t.slice(2,5)}.${t.slice(5,8)}/${t.slice(8,12)}-${t.slice(12)}`},Bd=(e,t)=>{let r=Bn(e);return t==="cpf"?Rd(r):t==="cnpj"?Od(r):r.length<=11?Rd(r):Od(r)},MS=(e,t)=>e==="cpf"?14:18;function _d(e){let{value:t,onChange:r,tipoDocumento:o="auto",slotProps:n,...a}=e,[i,l]=AS(""),s=t!==void 0,c=ES(()=>s?Bd(t||"",o):i,[t,i,s,o]),u=f=>{let m=f.target.value,g=Bd(m,o);if(s||l(g),r){let p=Bn(m);f.target.value=p,r(f)}},d=MS(o,t||i);return DS(be,{value:c,onChange:u,slotProps:{htmlInput:{maxLength:d,...n?.htmlInput},...n},placeholder:o==="cnpj"?"99.999.999/9999-99":o==="cpf"?"999.999.999-99":"CPF (999.999.999-99) ou CNPJ (99.999.999/9999-99)",...a})}import{useMemo as FS,useState as RS}from"react";import{jsx as OS}from"react/jsx-runtime";var $d=e=>e.replace(/\D/g,""),Ld=e=>{let t=$d(e).slice(0,8);return t.length<=5?t:`${t.slice(0,5)}-${t.slice(5)}`};function Nd(e){let{value:t,onChange:r,slotProps:o,...n}=e,[a,i]=RS(""),l=t!==void 0,s=FS(()=>l?Ld(t||""):a,[t,a,l]);return OS(be,{value:s,onChange:u=>{let d=u.target.value,f=Ld(d);if(l||i(f),r){let m=$d(d);u.target.value=m,r(u)}},slotProps:{htmlInput:{maxLength:9,...o?.htmlInput},...o},placeholder:"99999-999",...n})}import{useMemo as BS,useState as _S}from"react";import{jsx as $S}from"react/jsx-runtime";var _n=e=>e.replace(/\D/g,""),Bl=(e,t)=>{let r=_n(e);if(t){let o=r.slice(0,2),n=r.slice(2,4),a=r.slice(4,8),i=r.slice(8,12);return r.length<=2?`+${o}`:r.length<=4?`+${o} (${n}`:r.length<=8?`+${o} (${n}) ${a}`:`+${o} (${n}) ${a}-${i}`}else{let o=r.slice(0,10);return o.length<=2?`(${o}`:o.length<=6?`(${o.slice(0,2)}) ${o.slice(2)}`:`(${o.slice(0,2)}) ${o.slice(2,6)}-${o.slice(6)}`}},_l=(e,t)=>{let r=_n(e).slice(0,t?15:11);if(t){let o=r.slice(0,2),n=r.slice(2,4),a=r.slice(4,9),i=r.slice(9,13),l=r.slice(13);return r.length<=2?`+${o}`:r.length<=4?`+${o} (${n}`:r.length<=9?`+${o} (${n}) ${a}`:r.length<=13?`+${o} (${n}) ${a}-${i}`:`+${o} (${n}) ${a}-${i}${l}`}else{let o=r.slice(0,11);return o.length<=2?`(${o}`:o.length<=7?`(${o.slice(0,2)}) ${o.slice(2)}`:`(${o.slice(0,2)}) ${o.slice(2,7)}-${o.slice(7)}`}},Vd=(e,t,r)=>{let o=_n(e);return t==="fixed"?Bl(o,r):t==="mobile"?_l(o,r):r?o.length>12?_l(o,r):Bl(o,r):o.length>10?_l(o,r):Bl(o,r)},LS=(e,t)=>t?19:e==="fixed"?14:15;function zd(e){let{value:t,onChange:r,tipoTelefone:o="auto",allowDDI:n=!1,inputProps:a,...i}=e,[l,s]=_S(""),c=t!==void 0,u=BS(()=>c?Vd(t||"",o,n):l,[t,l,c,o,n]),d=m=>{let g=m.target.value,p=Vd(g,o,n);if(c||s(p),r){let y=_n(g);m.target.value=y,r(m)}},f=LS(o,n);return $S(be,{value:u,onChange:d,inputProps:{maxLength:f,...a},placeholder:n?o==="mobile"?"+99 (99) 99999-9999":o==="fixed"?"+99 (99) 9999-9999":"+99 (99) 9999-9999 ou +99 (99) 99999-9999":o==="mobile"?"(99) 99999-9999":o==="fixed"?"(99) 9999-9999":"(99) 9999-9999 ou (99) 99999-9999",...i})}import{Alert as Wd,CircularProgress as US,Dialog as jS,DialogContent as qS,DialogTitle as YS}from"@mui/material";import KS from"axios";import{useEffect as Gd,useState as Gr}from"react";import{Collapse as NS,Stack as VS,Typography as zS}from"@mui/material";import{useState as WS}from"react";import{Fragment as GS,jsx as Ln,jsxs as HS}from"react/jsx-runtime";function Ll(e){let{article:t,isOpen:r}=e,[o,n]=WS(!!r);return HS(GS,{children:[Ln(VS,{onClick:()=>n(!o),sx:{p:.5,":hover":{borderRadius:"4px",backgroundColor:a=>a.palette.grey[200],cursor:"pointer"}},children:Ln(zS,{variant:"subtitle1",children:t.title})}),Ln(NS,{in:o,sx:{pl:1,pr:1},children:Ln("div",{dangerouslySetInnerHTML:{__html:t?.body?.replace('width="560"','width="412px"').replace('height="315"','height="240px"').replace("h2","h3")||""}})})]})}import{Fragment as ZS,jsx as $n,jsxs as Hr}from"react/jsx-runtime";function Hd(e){let{sectionId:t,versao:r,authorization:o,notificarNovaVersao:n=!1,localStoragePath:a}=e,[i,l]=Gr(void 0),[s,c]=Gr(!1),[u,d]=Gr(!1),[f,m]=Gr(!1),[g,p]=Gr(!1);return Gd(()=>{if(n&&a){let y=JSON.parse(localStorage.getItem(a)||"[]");y.includes(r)||(m(!0),p(!0),localStorage.setItem(a,JSON.stringify([...y,r])))}},[n,a,r]),Gd(()=>{async function y(){c(!0);try{let v=localStorage.getItem(t);if(v){let w=JSON.parse(v);if(new Date().getTime()-w.timestamp<10*60*1e3){l(w.article),c(!1);return}}let x=o?{Authorization:`Bearer ${o}`}:{},S=await KS.get(`https://datacsistemashelp.zendesk.com/api/v2/help_center/pt-br/sections/${t}/articles`,{headers:x,params:{sort_by:"created_at",sort_order:"desc"}});l(S.data.articles)}catch{d("Ocorreu um erro ao obter as notas de vers\xE3o")}finally{c(!1)}}t&&f&&y()},[t,f]),Hr(ZS,{children:[$n(R,{onClick:y=>{y.preventDefault(),m(!0)},sx:{fontSize:"0.7rem",minWidth:0,pt:0,pb:0,pl:.5,pr:.5,color:y=>y.palette.grey[500]},variant:"text",children:r}),Hr(jS,{fullWidth:!0,maxWidth:"md",scroll:"paper",open:f,onClose:()=>m(!1),children:[Hr(YS,{children:["Notas de Vers\xE3o"," ",s&&$n(US,{sx:{ml:1},size:14})]}),Hr(qS,{children:[g&&Hr(Wd,{severity:"info",sx:{mb:2},children:["Uma nova vers\xE3o (",r,") est\xE1 dispon\xEDvel!"]}),u&&$n(Wd,{severity:"error",children:"N\xE3o foi poss\xEDvel carregar o conte\xFAdo"}),i?.map((y,v)=>$n(Ll,{isOpen:v===0,article:y},y.id))]})]})]})}import{DatePicker as QS}from"@mui/x-date-pickers";import{DateTime as JS}from"luxon";import{jsx as XS}from"react/jsx-runtime";function Dt(e){let{value:t,error:r,onChange:o,fromFormat:n,format:a,...i}=e;function l(s){if(s?.isValid){o(s?.toFormat("yyyy-MM-dd"));return}if(s===null){o(null);return}}return XS(QS,{format:a||"dd/MM/yyyy",value:JS.fromFormat(t||"",n||"yyyy-MM-dd"),onChange:s=>l(s),slotProps:{textField:{error:!!r}},...i})}import{LocalizationProvider as eT}from"@mui/x-date-pickers";import{AdapterLuxon as tT}from"@mui/x-date-pickers/AdapterLuxon";import{jsx as rT}from"react/jsx-runtime";function Ud({children:e}){return rT(eT,{dateAdapter:tT,adapterLocale:"pt-br",children:e})}import{IconButton as Nn,InputAdornment as jd,MenuItem as Ee,Stack as Vn,styled as oT}from"@mui/material";import{ArrowLeftIcon as qd,ArrowRightIcon as Yd,PickersDay as nT}from"@mui/x-date-pickers";import{DateTime as Ce}from"luxon";import{useEffect as iT,useMemo as Jd,useState as Kd}from"react";import{jsx as q,jsxs as Ze}from"react/jsx-runtime";var aT=oT(nT,{shouldForwardProp:e=>e!=="isSelected"&&e!=="isHovered"})(({theme:e,isSelected:t,isHovered:r,isToday:o,day:n})=>()=>({borderRadius:0,"& .MuiPickersDay-today":{backgroundColor:"#f52",borderRadius:"50%"},...o&&!r&&!t&&{borderRadius:"50%","& .MuiPickersDay-today":{padding:"0px"}},...t&&{backgroundColor:e.palette.primary.main,color:e.palette.primary.contrastText,"&:hover, &:focus":{backgroundColor:e.palette.primary.main}},...r&&{backgroundColor:e.palette.primary[e.palette.mode],"&:hover, &:focus":{backgroundColor:e.palette.primary[e.palette.mode]}},...n.weekday===1&&{borderTopLeftRadius:"50%",borderBottomLeftRadius:"50%"},...n.weekday===7&&{borderTopRightRadius:"50%",borderBottomRightRadius:"50%"}})),Zd=(e,t)=>t==null?!1:e.weekNumber===t.weekNumber;function Qd(e){let{day:t,selectedDay:r,hoveredDay:o,...n}=e,a=Jd(()=>t.day===Ce.now().day,[]);return q(aT,{...n,day:t,isToday:a,sx:{px:2.5},disableMargin:!0,selected:!1,isSelected:Zd(t,r),isHovered:Zd(t,o)})}function $l(e){let{value:t,onChange:r,renderFieldSet:o}=e,[n,a]=Kd(null),[i,l]=Kd({tipo:"month",firstDate:null,secondDate:null});iT(()=>{t&&l(t)},[t]);function s(){let y=(i.firstDate?Ce.fromFormat(i.firstDate,"yyyy-MM-dd"):Ce.now().startOf("day")).minus({[i.tipo]:1});d(i.tipo,y.toFormat("yyyy-MM-dd"))}function c(){let y=(i.firstDate?Ce.fromFormat(i.firstDate,"yyyy-MM-dd"):Ce.now().startOf("day")).plus({[i.tipo]:1});d(i.tipo,y.toFormat("yyyy-MM-dd"))}function u(p,y,v){let x=y.startOf(v).toFormat("yyyy-MM-dd"),S=y.endOf(v).toFormat("yyyy-MM-dd"),w={tipo:p,firstDate:x,secondDate:S};l(w),r&&r(w)}function d(p,y){if(p==="livre"){l({...i,tipo:"livre"}),r&&r({...i,tipo:"livre"});return}let v=y?Ce.fromFormat(y,"yyyy-MM-dd"):Ce.now();p==="month"&&u(p,v,"month"),p==="day"&&u(p,v,"day"),p==="week"&&u(p,v,"week"),p==="quarter"&&u(p,v,"quarter"),p==="year"&&u(p,v,"year")}function f(p){if(i.tipo==="livre"&&p){let y={...i,firstDate:p};l(y),r&&r(y);return}p&&d(i.tipo,p)}function m(p){if(i.tipo==="livre"&&p){let y={...i,secondDate:p};l(y),r&&r(y);return}p&&d(i.tipo,p)}let g=Jd(()=>{if(i.tipo==="month"||i.tipo==="quarter")return["month"];if(i.tipo==="day")return["day"];if(i.tipo==="year")return["year"]},[i.tipo]);return o?Ze("fieldset",{style:{border:"1px solid #cfcfcf",borderRadius:"4px"},children:[q("legend",{style:{color:"#808080",fontSize:"0.7rem",paddingLeft:"4px",paddingRight:"8px"},children:"Per\xEDodo"}),Ze(Vn,{spacing:2,children:[Ze(be,{value:i.tipo,onChange:p=>{let y=p.target.value;d(y,i?.firstDate||null)},select:!0,fullWidth:!0,size:"small",variant:"outlined",InputProps:{startAdornment:i?.tipo!=="livre"&&Ze(jd,{position:"start",children:[q(Nn,{size:"small",onClick:s,children:q(qd,{fontSize:"small"})}),q(Nn,{size:"small",onClick:c,children:q(Yd,{fontSize:"small"})})]})},children:[q(Ee,{value:"livre",children:"Livre"}),q(Ee,{value:"month",children:"Mensal"}),q(Ee,{value:"day",children:"Di\xE1rio"}),q(Ee,{value:"week",children:"Semanal"}),q(Ee,{value:"quarter",children:"Trimestral"}),q(Ee,{value:"year",children:"Anual"})]}),Ze(Vn,{direction:"row",spacing:1,children:[q(Dt,{label:"In\xEDcio",onChange:f,value:i.firstDate,showDaysOutsideCurrentMonth:!0,slots:i.tipo==="week"?{day:Qd}:void 0,slotProps:i.tipo==="week"?{day:p=>({selectedDay:i?.firstDate?Ce.fromFormat(i.firstDate,"yyyy-MM-dd").startOf("week"):Ce.now(),hoveredDay:n,onPointerEnter:()=>a(p.day),onPointerLeave:()=>a(null)})}:void 0,views:g}),i.tipo!=="day"&&q(Dt,{disabled:i.tipo!=="livre"||!i?.firstDate,minDate:i?.firstDate?Ce.fromFormat(i.firstDate,"yyyy-MM-dd"):void 0,showDaysOutsideCurrentMonth:!0,label:"Fim",onChange:m,value:i.secondDate})]})]})]}):Ze(Vn,{spacing:2,children:[Ze(be,{value:i.tipo,onChange:p=>{let y=p.target.value;d(y,i?.firstDate||null)},select:!0,fullWidth:!0,size:"small",variant:"outlined",InputProps:{startAdornment:i?.tipo!=="livre"&&Ze(jd,{position:"start",children:[q(Nn,{size:"small",onClick:s,children:q(qd,{fontSize:"small"})}),q(Nn,{size:"small",onClick:c,children:q(Yd,{fontSize:"small"})})]})},children:[q(Ee,{value:"livre",children:"Livre"}),q(Ee,{value:"month",children:"Mensal"}),q(Ee,{value:"day",children:"Di\xE1rio"}),q(Ee,{value:"week",children:"Semanal"}),q(Ee,{value:"quarter",children:"Trimestral"}),q(Ee,{value:"year",children:"Anual"})]}),Ze(Vn,{direction:"row",spacing:1,children:[q(Dt,{label:"In\xEDcio",onChange:f,value:i.firstDate,showDaysOutsideCurrentMonth:!0,slots:i.tipo==="week"?{day:Qd}:void 0,slotProps:i.tipo==="week"?{day:p=>({selectedDay:i?.firstDate?Ce.fromFormat(i.firstDate,"yyyy-MM-dd").startOf("week"):Ce.now(),hoveredDay:n,onPointerEnter:()=>a(p.day),onPointerLeave:()=>a(null)})}:void 0,views:g}),i.tipo!=="day"&&q(Dt,{disabled:i.tipo!=="livre"||!i?.firstDate,minDate:i?.firstDate?Ce.fromFormat(i.firstDate,"yyyy-MM-dd"):void 0,showDaysOutsideCurrentMonth:!0,label:"Fim",onChange:p=>{l({...i,secondDate:p})},value:i.secondDate})]})]})}$l.defaultProps={renderFieldSet:!0};import{formatCurrency as sT,isValidNumber as lT}from"@data-c/hooks";import{forwardRef as cT,useCallback as Xd}from"react";import{jsx as pT}from"react/jsx-runtime";function Nl(e){if(!e)return 0;let t=String(e);return t=t.replace(/\./g,"").replace(/,/g,"."),parseFloat(t)}var Vl=null,zn=!1,ef=cT((e,t)=>{let{value:r,onChange:o,sx:n,...a}=e;Vl=null;let i=Xd(s=>{let c=s.target.value||"0.00";lT(c)&&(Vl==="Backspace"?c=(Nl(c)/10).toFixed(2):zn?(c=(Nl(c)/100).toFixed(2),zn=!1):c=(Nl(c)*10).toFixed(2),o&&(s.target.value=c,o(s,c)))},[o]),l=Xd(s=>{s.target.selectionStart===s.target.selectionEnd&&(s.target.selectionStart=s.target.value.length,s.target.selectionEnd=s.target.value.length)},[]);return pT(be,{onKeyDown:s=>{Vl=s.key},onSelect:s=>{let c=s.target;c.selectionStart===0&&c.selectionEnd===c.value.length?zn=!0:zn=!1,l(s)},onChange:i,value:sT(String(r),2)||"",inputRef:t,sx:{"& .MuiInputBase-input":{textAlign:"right"},...n},...a})});ef.defaultProps={value:0};var uT=ef;import{Button as dT,Stack as of,Typography as Wn}from"@mui/material";import{ArrowDropDown as fT}from"@mui/icons-material";import{useState as mT}from"react";import{jsx as Oe,jsxs as Ur}from"react/jsx-runtime";function nf(e){let{licencas:t,licencaSelecionada:r,onAlterarLicenca:o}=e,[n,a]=mT("");if(t.length===0)return Ur(of,{overflow:"hidden",children:[Oe(Wn,{overflow:"hidden",textOverflow:"ellipsis",variant:"body1",children:r.nome}),Oe(Wn,{overflow:"hidden",textOverflow:"ellipsis",variant:"body2",children:tf(r.documento)})]});function i(s){a(s)}let l=n.length>0?t.filter(s=>["nome"].some(c=>rf(String(s[c])).includes(rf(n)))):t;return Ur(ur.Root,{children:[Oe(ur.Trigger,{asChild:!0,children:Ur(dT,{sx:{color:s=>s.palette.grey[900]},variant:"text",children:[r.nome,Oe(fT,{})]})}),Oe(ur.Content,{sx:{"& .MuiPopover-paper":{minWidth:"300px",borderRadius:"12px",p:.5}},children:Ur(zr.Root,{sx:{m:.5,minWidth:"300px",maxHeight:"300px",overflow:"auto"},children:[Oe(Gt,{autoFocus:!0,onSearch:i}),Oe(zr.Content,{children:l.map(s=>Oe(ur.Close,{asChild:!0,children:Oe(zr.Item,{selected:r.uuid===s.uuid,onClick:()=>o(s),children:Ur(of,{children:[Oe(Wn,{variant:"body1",textOverflow:"ellipsis",children:s.nome}),Oe(Wn,{variant:"body2",textOverflow:"ellipsis",children:tf(s.documento)})]})})},s.uuid))})]})})]})}import{Drawer as OT,Toolbar as BT}from"@mui/material";import{styled as _T}from"@mui/material/styles";import{List as IT}from"@mui/material";import{useState as bT}from"react";import{Box as CT,Collapse as wT,Icon as ST,ListItemText as TT}from"@mui/material";import{ExpandMore as PT,ExpandLess as kT}from"@mui/icons-material";import{MenuItem as gT}from"@mui/material";import{styled as hT}from"@mui/material/styles";import{jsx as vT}from"react/jsx-runtime";var yT=hT(gT,{})(({theme:e})=>({borderRadius:"6px",width:"90%",gap:"16px",margin:"0 auto",padding:"8px 16px",transition:"0.1s ease-in-out","&:hover":{backgroundColor:"rgba(89, 195, 224, 15%);","& .MuiTypography-root":{color:e.palette.primary.main},"& .MuiSvgIcon-root":{color:e.palette.primary.main},"& .MuiIcon-root":{color:e.palette.primary.main}},"& .MuiIcon-root":{color:e.palette.grey[500],fontSize:"20px"},"& .MuiTypography-root":{letterSpacing:"0.5px",color:e.palette.text.secondary,fontSize:e.typography.body1},"& .MuiSvgIcon-root":{fontSize:"24px"}})),xT=e=>vT(yT,{...e}),Gn=xT;import{jsx as pr,jsxs as af}from"react/jsx-runtime";function zl(e){let{menuItem:t,activeMenu:r,onMenuClick:o}=e,[n,a]=bT(!1);if(!t.visible)return null;let i=!!(t?.items&&t?.items.length>0);function l(){a(!n)}return af(CT,{children:[af(Gn,{onClick:()=>{if(t?.link){o(t.link);return}l()},selected:r===t.link,children:[!!t.icon&&pr(ST,{children:t.icon}),pr(TT,{primary:t.label}),i&&!n&&pr(PT,{}),i&&n&&pr(kT,{})]}),t?.items&&pr(wT,{in:n,timeout:"auto",unmountOnExit:!0,children:pr(Ft,{activeMenu:r,sx:{pl:s=>s.spacing(1.5)},menus:t?.items||[],onMenuClick:o})})]})}import{jsx as sf}from"react/jsx-runtime";function Ft(e){let{menus:t,activeMenu:r,onMenuClick:o,...n}=e;return sf(IT,{component:"nav",disablePadding:!0,...n,children:t.map(a=>sf(zl,{onMenuClick:o,activeMenu:r,menuItem:a},a.id))})}import{useState as ET}from"react";import{List as AT,Icon as MT,ListItemIcon as DT,Popper as FT}from"@mui/material";import{jsx as jr,jsxs as RT}from"react/jsx-runtime";function Wl(e){let{menus:t,activeMenu:r,onMenuClick:o}=e,[n,a]=ET(null),i=(s,c,u)=>{a({element:s.currentTarget,id:c,items:u})},l=()=>{a(null)};return jr(AT,{component:"nav",disablePadding:!0,children:t.map(s=>s.visible?RT(Gn,{onMouseEnter:c=>{s?.link||i(c,s.id,s.items)},onMouseLeave:()=>{s?.link||l()},onClick:()=>{s?.link&&o(s.link)},selected:r===s.link,children:[jr(DT,{children:jr(MT,{children:s.icon})}),n?.id===s.id&&jr(FT,{sx:{zIndex:999999},anchorEl:n?.element,open:!!n?.element,placement:"right-start",children:jr(Ft,{activeMenu:r,onMenuClick:o,menus:s?.items||[],sx:{minWidth:"240px",backgroundColor:V.palette.background.paper,borderRadius:"12px",padding:"16px 4px",boxShadow:"0px 5px 5px -3px rgb(0 0 0 / 20%), 0px 8px 10px 1px rgb(0 0 0 / 14%), 0px 3px 14px 2px rgb(0 0 0 / 12%);"}})})]},`minMenu-${s.id}`):null)})}import{jsx as Gl,jsxs as $T}from"react/jsx-runtime";var lf=(e,t)=>({width:e,transition:t.transitions.create("width",{easing:t.transitions.easing.sharp,duration:t.transitions.duration.enteringScreen}),overflowX:"hidden"}),cf=e=>({transition:e.transitions.create("width",{easing:e.transitions.easing.sharp,duration:e.transitions.duration.leavingScreen}),overflowX:"hidden",width:`calc(${e.spacing(8)} + 1px)`,[e.breakpoints.up("sm")]:{width:`calc(${e.spacing(8)} + 1px)`}}),LT=_T(OT,{shouldForwardProp:e=>e!=="open"&&e!=="width"})(({theme:e,open:t,width:r})=>({width:r,bgcolor:e.palette.background.paper,boxShadow:"2px 3px 20px -16px rgb(32 32 36 / 30%)",borderRightStyle:"none",whiteSpace:"nowrap",boxSizing:"border-box",...t&&{...lf(r,e),"& .MuiDrawer-paper":lf(r,e)},...!t&&{...cf(e),"& .MuiDrawer-paper":cf(e)}}));function uf(e){let{open:t,items:r,width:o,activeMenu:n,onMenuClick:a,toggleMenu:i,...l}=e;return $T(LT,{width:o,open:t,onClose:()=>i(!1),...l,children:[Gl(BT,{}),t&&Gl(Ft,{onMenuClick:a,activeMenu:n,menus:r}),!t&&Gl(Wl,{onMenuClick:a,activeMenu:n,menus:r})]})}import{Box as NT}from"@mui/material";import{jsx as VT}from"react/jsx-runtime";function pf(e){return VT(NT,{m:2,sx:{display:"flex",flexDirection:"column",flexGrow:1},...e})}import{useUserContext as zT}from"@data-c/providers";import WT from"@mui/material/Avatar";import{jsx as GT}from"react/jsx-runtime";function df(e){let{user:t}=zT();return GT(WT,{src:t?.avatarUrl,sx:{width:64,height:64,margin:"auto",mb:2},...e})}import{Stack as tc,Tab as bf,Tabs as fP}from"@mui/material";import{useState as mP}from"react";import{Box as HT}from"@mui/material";import{jsx as UT}from"react/jsx-runtime";function Hn(e){let{children:t,value:r,index:o,...n}=e;return r!==o?null:UT(HT,{role:"tabpanel",hidden:r!==o,id:`scrollable-auto-tabpanel-${o}`,"aria-labelledby":`scrollable-auto-tab-${o}`,sx:{display:"flex",flexDirection:"column",flexGrow:1},...n,children:r===o&&t})}import{useCredentials as JT,useForm as XT}from"@data-c/hooks";import{Alert as hf,Divider as eP,Grid as qr,Stack as tP,TextField as Ul,Typography as yf}from"@mui/material";import{useEffect as jl,useState as ql}from"react";import{useState as dr,useCallback as jT}from"react";import qT from"react-easy-crop";import YT from"@mui/material/Slider";import ff from"@mui/material/Button";import KT from"@mui/material/Dialog";import mf from"@mui/material/Avatar";function Hl(e,t){return new Promise(r=>{let o=new Image;o.src=e,o.onload=()=>{let n=document.createElement("canvas");n.width=t.width,n.height=t.height;let a=n.getContext("2d");a&&(a.drawImage(o,t.x,t.y,t.width,t.height,0,0,t.width,t.height),r(n.toDataURL("image/jpeg")))}})}import{Stack as ZT}from"@mui/material";import{jsx as Qe,jsxs as Un}from"react/jsx-runtime";var QT=({onSave:e,src:t})=>{let[r,o]=dr(null),[n,a]=dr(null),[i,l]=dr({x:0,y:0}),[s,c]=dr(1),[u,d]=dr(null),[f,m]=dr(!1),g=jT((v,x)=>{d(x)},[]);return Un(ZT,{direction:"row",spacing:2,alignItems:"center",children:[n?Qe(mf,{src:n,alt:"Preview",sx:{width:64,height:64,margin:"auto",mb:2}}):Qe(mf,{src:t,sx:{width:64,height:64,margin:"auto",mb:2}}),Un("label",{children:[Qe("input",{type:"file",accept:"image/*",onChange:v=>{let x=v.target.files?.[0];if(!x)return;let S=new FileReader;S.onload=()=>{o(S.result),m(!0)},S.readAsDataURL(x)},style:{display:"none"}}),Qe(ff,{variant:"contained",component:"span",children:"Alterar foto"})]}),Un(KT,{open:f,onClose:()=>m(!1),maxWidth:"sm",fullWidth:!0,children:[Qe("div",{style:{position:"relative",height:400,background:"#333"},children:r&&Qe(qT,{image:r,crop:i,zoom:s,aspect:1,cropShape:"round",showGrid:!1,onCropChange:l,onZoomChange:c,onCropComplete:g})}),Un("div",{style:{padding:20},children:[Qe(YT,{value:s,min:1,max:3,step:.1,onChange:(v,x)=>c(x)}),Qe(_e,{children:Qe(ff,{variant:"contained",onClick:async()=>{if(!r||!u)return;let v=await Hl(r,u);a(v),m(!1),e&&e(v)},children:"Salvar"})})]})]})]})},gf=QT;import{jsx as ue,jsxs as xf}from"react/jsx-runtime";var rP=ve().shape({name:ce().required("Informe o nome")});function Yl(e){let{usuario:t,credentialsConfig:r,onUploadComplete:o}=e,{data:n,setData:a,handleChange:i,validate:l,validationErrors:s}=XT(t,rP),[c,u]=ql(!1),[d,f]=ql(!1),[m,g]=ql(!1),{uploadAvatar:p,atualizarUsuario:y}=JT(r);jl(()=>{a(t)},[t]),jl(()=>{m&&setTimeout(()=>{g(!1)},3e3)},[m]),jl(()=>{c&&setTimeout(()=>{u(!1)},3e3)},[c]);function v(){l(async x=>{try{f(!0),await y(x),g(!0)}catch{u("Ocorreu um erro ao alterar os dados da conta")}finally{f(!1)}})}return xf(tP,{spacing:2,children:[ue(yf,{variant:"h6",children:"Avatar"}),ue(gf,{src:n?.avatarUrl,onSave:x=>{try{p(x),o&&(g(!0),o(!0))}catch(S){u("Ocorreu um erro ao atualizar a foto de perfil"),o&&o(!1,S)}}}),ue(eP,{}),ue(yf,{variant:"h6",children:"Informa\xE7\xF5es da Conta"}),xf(qr,{container:!0,spacing:1.5,children:[ue(qr,{size:{xl:4,lg:4,md:4,sm:12,xs:12},children:ue(Ul,{disabled:!0,fullWidth:!0,label:"E-mail",value:n?.email||""})}),ue(qr,{size:{xl:4,lg:4,md:4,sm:12,xs:12},children:ue(Ul,{name:"name",fullWidth:!0,label:"Nome",value:n?.name||"",onChange:i,...s("name")})}),ue(qr,{size:{xl:4,lg:4,md:4,sm:12,xs:12},children:ue(Ul,{name:"surname",fullWidth:!0,label:"Sobrenome",value:n?.surname||"",onChange:i})})]}),ue(qr,{size:{xl:4,lg:4,md:4,sm:12,xs:12},children:ue(_e,{children:ue(R,{isLoading:d,onClick:()=>v(),variant:"contained",children:"Salvar"})})}),m&&ue(hf,{children:"Dados da conta alterados com sucesso!"}),c&&ue(hf,{severity:"error",children:c})]})}import{useCredentials as sP,useForm as lP}from"@data-c/hooks";import{Alert as cP,Divider as uP,Stack as Ql,Typography as Jl}from"@mui/material";import{useEffect as pP,useState as jn}from"react";import{useCredentials as oP}from"@data-c/hooks";import{Alert as nP,Stack as iP,Typography as vf}from"@mui/material";import{useEffect as aP,useState as Kl}from"react";import{jsx as Be,jsxs as Yr}from"react/jsx-runtime";function Zl(e){let{open:t,onClose:r,payload:o,onCodigoVerificado:n,credentialsConfig:a}=e,[i,l]=Kl(""),[s,c]=Kl(!1),[u,d]=Kl(!1),{validarCodigoWhatsapp:f}=oP(a);aP(()=>{s&&setTimeout(()=>{c(!1)},3e3)},[s]);async function m(){try{d(!0);let g=await f(i);n(g.data)}catch(g){c(g.response.data.message)}finally{d(!1)}}return Yr(O.Root,{open:t,onClose:g=>r(),maxWidth:"xs",children:[Yr(O.Header,{children:[Be(O.Title,{children:"Verifica\xE7\xE3o do seu n\xFAmero de WhatsApp"}),Be(O.ActionClose,{onClose:r})]}),Be(O.Content,{children:Yr(iP,{spacing:2,justifyContent:"center",alignContent:"center",alignItems:"center",children:[Be(vf,{variant:"subtitle1",sx:{fontWeight:"bolder",fontSize:"11pt"},children:"\u{1F510} Verifique seu n\xFAmero"}),Yr(vf,{variant:"body1",sx:{fontSize:"10pt"},children:["Enviamos um c\xF3digo via WhatsApp para +55"," ",Be("b",{children:`(${o?.whatsappNumber?.slice(0,2)}) ${o?.whatsappNumber?.slice(2,7)}-${o?.whatsappNumber?.slice(7)}`}),". ",Be("br",{}),"Digite o c\xF3digo abaixo para confirmar que este n\xFAmero \xE9 seu."]}),Be(Er,{value:i,onChange:g=>{l(g)}}),s&&Be(nP,{sx:{flexGrow:1},severity:"error",children:s})]})}),Be(O.Footer,{children:Yr(O.Actions,{children:[Be(O.ActionCancelar,{onClick:()=>r()}),Be(O.ActionSalvar,{label:"Verificar",onClick:m,isLoading:u,disabled:i.length!=6})]})})]})}import{Verified as dP}from"@mui/icons-material";import{jsx as Ae,jsxs as Xl}from"react/jsx-runtime";var SW=ve().shape({whatsappNumber:ce().required("Informe o n\xFAmero do whastapp").length(15)});function ec(e){let{usuario:t,credentialsConfig:r,onWhastappSaved:o}=e,[n,a]=jn(!1),[i,l]=jn(!1),{data:s,setData:c,changeValue:u,validate:d,validationErrors:f}=lP(t),[m,g]=jn(!1),[p,y]=jn(!1),{atualizarUsuario:v,gerarWhatsappVerificationCode:x}=sP(r);pP(()=>{c(t)},[t]);function S(){d(async C=>{try{l(!0);let k=await v(C);o&&o(k.data)}catch{}finally{l(!1)}})}async function w(){try{g(!0);let C=await x();y(!0)}catch{}finally{g(!1)}}return Xl(Ql,{spacing:2,children:[Ae(Jl,{variant:"h6",children:"Senha"}),Ae(R,{onClick:()=>{a(!0)},sx:{width:"200px"},fullWidth:!1,variant:"contained",children:"Alterar Senha"}),Ae(Qt,{isOpen:n,onClose:async()=>a(!1),credentialsConfig:r}),Ae(uP,{}),Ae(Jl,{variant:"h6",children:"Login com Whastapp"}),Xl(Ql,{direction:"row",spacing:2,children:[Ae(Ir,{disabled:!!s?.whatsappVerifiedAt,fullWidth:!1,name:"whatsappNumber",label:"Whastapp",value:s.whatsappNumber||"",onChange:C=>{u("whatsappNumber",C.target.value)}}),s.whatsappVerifiedAt&&Xl(Ql,{direction:"row",spacing:1,justifyContent:"center",alignItems:"center",children:[Ae(dP,{color:"success"}),Ae(Jl,{variant:"body2",children:"N\xFAmero Verificado"})]}),s.whatsappNumber&&s.whatsappNumber.replace(/\D/g,"").length===11&&!s.whatsappVerifiedAt&&Ae(R,{isLoading:i,onClick:S,children:"Salvar Whatsapp"})]}),t.whatsappNumber&&t.whatsappNumber.replace(/\D/g,"").length===11&&!s.whatsappVerifiedAt&&Ae(cP,{severity:"warning",action:Ae(R,{isLoading:m,onClick:w,children:"Enviar n\xFAmero de verifica\xE7\xE3o"}),children:"O seu n\xFAmero de whatsapp ainda n\xE3o est\xE1 validado"}),Ae(Zl,{open:p,onClose:async C=>{y(!1)},payload:t,credentialsConfig:r,onCodigoVerificado:C=>{c(C),y(!1)}})]})}import{useUserContext as gP}from"@data-c/providers";import{Fragment as hP,jsx as at,jsxs as rc}from"react/jsx-runtime";function Cf(e){let[t,r]=mP(0),{user:o,setUser:n,credentialsConfig:a}=gP();return at(hP,{children:rc(tc,{spacing:2,direction:"row",children:[at(tc,{sx:{width:"200px"},children:rc(fP,{orientation:"vertical",value:t,onChange:(i,l)=>{r(l)},sx:{"& .MuiButtonBase-root":{alignItems:"flex-start"}},children:[at(bf,{label:"Minha Conta",value:0}),at(bf,{label:"Login e Seguran\xE7a",value:1})]})}),rc(tc,{sx:{flexGrow:1},children:[at(Hn,{value:t,index:0,children:at(Yl,{credentialsConfig:a,usuario:o||{}})}),at(Hn,{value:t,index:1,children:at(ec,{onWhastappSaved:i=>{n(i)},credentialsConfig:a,usuario:o||{}})})]})]})})}export{nf as AlterarLicenca,Qt as AlterarSenha,Fn as Autocomplete,df as Avatar,Fp as Breadcrumbs,R as Button,_e as ButtonContainer,Bw as ButtonGroup,Nd as CEPTextField,Uw as Card,ac as Checkbox,lc as ColorsGrid,pf as Content,iC as ContentTitle,YP as CurrencyCellStyle,uT as CurrencyTextField,tw as DataTable,Zn as DataTableOptions,Dt as DatePicker,Ud as DatePickerProvider,$l as DateRangePicker,O as Dialog,_d as DocumentoTextField,uf as DrawerMenu,Uo as Editable,LC as Filter,$p as FilterApiContext,ri as FilterContainer,Xr as FilterControl,Lp as FilterDataContext,Np as FilterProvider,xc as Flag,fb as Header,ge as Icon,yu as LabelValue,zr as List,Yw as LucidIcon,Qb as Menu,vp as MioAuth,Hd as NotaVersao,qP as OptionStyles,lS as Page,Su as PageTitle,ht as PasswordTextField,ur as Popover,Cf as Profile,Gt as SearchTextField,In as Surface,zd as TelefoneTextField,be as TextField,Dn as Title,Rt as Tooltip,PS as Transporter,Zb as renderMenuItems,V as theme,$D as useDialogs,sr as useFilter,Ie as useFilterApi,Gb as useMenu,Wr as useTransporter};
158
+ `+(l!==i?`result of cast: ${l}`:""))}return a}_cast(e,r){let o=e===void 0?e:this.transforms.reduce((n,a)=>a.call(this,n,e,this,r),e);return o===void 0&&(o=this.getDefault(r)),o}_validate(e,r={},o,n){let{path:a,originalValue:i=e,strict:l=this.spec.strict}=r,s=e;l||(s=this._cast(s,Object.assign({assert:!1},r)));let u=[];for(let c of Object.values(this.internalTests))c&&u.push(c);this.runTests({path:a,value:s,originalValue:i,options:r,tests:u},o,c=>{if(c.length)return n(c,s);this.runTests({path:a,value:s,originalValue:i,options:r,tests:this.tests},o,n)})}runTests(e,r,o){let n=!1,{tests:a,value:i,originalValue:l,path:s,options:u}=e,c=p=>{n||(n=!0,r(p,i))},d=p=>{n||(n=!0,o(p,i))},f=a.length,m=[];if(!f)return d([]);let h={value:i,originalValue:l,path:s,options:u,schema:this};for(let p=0;p<a.length;p++){let y=a[p];y(h,c,function(b){b&&(Array.isArray(b)?m.push(...b):m.push(b)),--f<=0&&d(m)})}}asNestedTest({key:e,index:r,parent:o,parentPath:n,originalParent:a,options:i}){let l=e??r;if(l==null)throw TypeError("Must include `key` or `index` for nested validations");let s=typeof l=="number",u=o[l],c=Object.assign({},i,{strict:!0,parent:o,value:u,originalValue:a[l],key:void 0,[s?"index":"key"]:l,path:s||l.includes(".")?`${n||""}[${s?l:`"${l}"`}]`:(n?`${n}.`:"")+e});return(d,f,m)=>this.resolve(c)._validate(u,c,f,m)}validate(e,r){var o;let n=this.resolve(Object.assign({},r,{value:e})),a=(o=r?.disableStackTrace)!=null?o:n.spec.disableStackTrace;return new Promise((i,l)=>n._validate(e,r,(s,u)=>{te.isError(s)&&(s.value=u),l(s)},(s,u)=>{s.length?l(new te(s,u,void 0,void 0,a)):i(u)}))}validateSync(e,r){var o;let n=this.resolve(Object.assign({},r,{value:e})),a,i=(o=r?.disableStackTrace)!=null?o:n.spec.disableStackTrace;return n._validate(e,Object.assign({},r,{sync:!0}),(l,s)=>{throw te.isError(l)&&(l.value=s),l},(l,s)=>{if(l.length)throw new te(l,e,void 0,void 0,i);a=s}),a}isValid(e,r){return this.validate(e,r).then(()=>!0,o=>{if(te.isError(o))return!1;throw o})}isValidSync(e,r){try{return this.validateSync(e,r),!0}catch(o){if(te.isError(o))return!1;throw o}}_getDefault(e){let r=this.spec.default;return r==null?r:typeof r=="function"?r.call(this,e):er(r)}getDefault(e){return this.resolve(e||{})._getDefault(e)}default(e){return arguments.length===0?this._getDefault():this.clone({default:e})}strict(e=!0){return this.clone({strict:e})}nullability(e,r){let o=this.clone({nullable:e});return o.internalTests.nullable=Xt({message:r,name:"nullable",test(n){return n===null?this.schema.spec.nullable:!0}}),o}optionality(e,r){let o=this.clone({optional:e});return o.internalTests.optionality=Xt({message:r,name:"optionality",test(n){return n===void 0?this.schema.spec.optional:!0}}),o}optional(){return this.optionality(!0)}defined(e=He.defined){return this.optionality(!1,e)}nullable(){return this.nullability(!0)}nonNullable(e=He.notNull){return this.nullability(!1,e)}required(e=He.required){return this.clone().withMutation(r=>r.nonNullable(e).defined(e))}notRequired(){return this.clone().withMutation(e=>e.nullable().optional())}transform(e){let r=this.clone();return r.transforms.push(e),r}test(...e){let r;if(e.length===1?typeof e[0]=="function"?r={test:e[0]}:r=e[0]:e.length===2?r={name:e[0],test:e[1]}:r={name:e[0],message:e[1],test:e[2]},r.message===void 0&&(r.message=He.default),typeof r.test!="function")throw new TypeError("`test` is a required parameters");let o=this.clone(),n=Xt(r),a=r.exclusive||r.name&&o.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&&(o.exclusiveTests[r.name]=!!r.exclusive),o.tests=o.tests.filter(i=>!(i.OPTIONS.name===r.name&&(a||i.OPTIONS.test===n.OPTIONS.test))),o.tests.push(n),o}when(e,r){!Array.isArray(e)&&typeof e!="string"&&(r=e,e=".");let o=this.clone(),n=xp(e).map(a=>new Qe(a));return n.forEach(a=>{a.isSibling&&o.deps.push(a.key)}),o.conditions.push(typeof r=="function"?new tr(n,r):tr.fromOptions(n,r)),o}typeError(e){let r=this.clone();return r.internalTests.typeError=Xt({message:e,name:"typeError",skipAbsent:!0,test(o){return this.schema._typeCheck(o)?!0:this.createError({params:{type:this.schema.type}})}}),r}oneOf(e,r=He.oneOf){let o=this.clone();return e.forEach(n=>{o._whitelist.add(n),o._blacklist.delete(n)}),o.internalTests.whiteList=Xt({message:r,name:"oneOf",skipAbsent:!0,test(n){let a=this.schema._whitelist,i=a.resolveAll(this.resolve);return i.includes(n)?!0:this.createError({params:{values:Array.from(a).join(", "),resolved:i}})}}),o}notOneOf(e,r=He.notOneOf){let o=this.clone();return e.forEach(n=>{o._blacklist.add(n),o._whitelist.delete(n)}),o.internalTests.blacklist=Xt({message:r,name:"notOneOf",test(n){let a=this.schema._blacklist,i=a.resolveAll(this.resolve);return i.includes(n)?this.createError({params:{values:Array.from(a).join(", "),resolved:i}}):!0}}),o}strip(e=!0){let r=this.clone();return r.spec.strip=e,r}describe(e){let r=(e?this.resolve(e):this).clone(),{label:o,meta:n,optional:a,nullable:i}=r.spec;return{meta:n,label:o,optional:a,nullable:i,default:r.getDefault(e),type:r.type,oneOf:r._whitelist.describe(),notOneOf:r._blacklist.describe(),tests:r.tests.filter((s,u,c)=>c.findIndex(d=>d.OPTIONS.name===s.OPTIONS.name)===u).map(s=>{let u=s.OPTIONS.params&&e?Pp(Object.assign({},s.OPTIONS.params),e):s.OPTIONS.params;return{name:s.OPTIONS.name,params:u}})}}get"~standard"(){let e=this;return{version:1,vendor:"yup",async validate(o){try{return{value:await e.validate(o,{abortEarly:!1})}}catch(n){if(n instanceof te)return{issues:Ip(n)};throw n}}}}};re.prototype.__isYupSchema__=!0;for(let t of["validate","validateSync"])re.prototype[`${t}At`]=function(e,r,o={}){let{parent:n,parentPath:a,schema:i}=Ey(this,e,r,o.context);return i[t](n&&n[a],Object.assign({},o,{parent:n,path:e}))};for(let t of["equals","is"])re.prototype[t]=re.prototype.oneOf;for(let t of["not","nope"])re.prototype[t]=re.prototype.notOneOf;var Ry=()=>!0;function Dy(t){return new mn(t)}var mn=class extends re{constructor(e){super(typeof e=="function"?{type:"mixed",check:e}:Object.assign({type:"mixed",check:Ry},e))}};Dy.prototype=mn.prototype;function Oy(){return new hn}var hn=class extends re{constructor(){super({type:"boolean",check(e){return e instanceof Boolean&&(e=e.valueOf()),typeof e=="boolean"}}),this.withMutation(()=>{this.transform((e,r)=>{if(this.spec.coerce&&!this.isType(e)){if(/^(true|1)$/i.test(String(e)))return!0;if(/^(false|0)$/i.test(String(e)))return!1}return e})})}isTrue(e=ga.isValue){return this.test({message:e,name:"is-value",exclusive:!0,params:{value:"true"},test(r){return De(r)||r===!0}})}isFalse(e=ga.isValue){return this.test({message:e,name:"is-value",exclusive:!0,params:{value:"false"},test(r){return De(r)||r===!1}})}default(e){return super.default(e)}defined(e){return super.defined(e)}optional(){return super.optional()}required(e){return super.required(e)}notRequired(){return super.notRequired()}nullable(){return super.nullable()}nonNullable(e){return super.nonNullable(e)}strip(e){return super.strip(e)}};Oy.prototype=hn.prototype;var By=/^(\d{4}|[+-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,.](\d{1,}))?)?(?:(Z)|([+-])(\d{2})(?::?(\d{2}))?)?)?$/;function Ly(t){let e=ya(t);if(!e)return Date.parse?Date.parse(t):Number.NaN;if(e.z===void 0&&e.plusMinus===void 0)return new Date(e.year,e.month,e.day,e.hour,e.minute,e.second,e.millisecond).valueOf();let r=0;return e.z!=="Z"&&e.plusMinus!==void 0&&(r=e.hourOffset*60+e.minuteOffset,e.plusMinus==="+"&&(r=0-r)),Date.UTC(e.year,e.month,e.day,e.hour,e.minute+r,e.second,e.millisecond)}function ya(t){var e,r;let o=By.exec(t);return o?{year:Ke(o[1]),month:Ke(o[2],1)-1,day:Ke(o[3],1),hour:Ke(o[4]),minute:Ke(o[5]),second:Ke(o[6]),millisecond:o[7]?Ke(o[7].substring(0,3)):0,precision:(e=(r=o[7])==null?void 0:r.length)!=null?e:void 0,z:o[8]||void 0,plusMinus:o[9]||void 0,hourOffset:Ke(o[10]),minuteOffset:Ke(o[11])}:null}function Ke(t,e=0){return Number(t)||e}var $y=/^[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])?)*$/,zy=/^((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,_y=/^(?:[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,Ny="^\\d{4}-\\d{2}-\\d{2}",Vy="\\d{2}:\\d{2}:\\d{2}",Wy="(([+-]\\d{2}(:?\\d{2})?)|Z)",Hy=new RegExp(`${Ny}T${Vy}(\\.\\d+)?${Wy}$`),Gy=t=>De(t)||t===t.trim(),jy={}.toString();function ce(){return new gn}var gn=class extends re{constructor(){super({type:"string",check(e){return e instanceof String&&(e=e.valueOf()),typeof e=="string"}}),this.withMutation(()=>{this.transform((e,r)=>{if(!this.spec.coerce||this.isType(e)||Array.isArray(e))return e;let o=e!=null&&e.toString?e.toString():e;return o===jy?e:o})})}required(e){return super.required(e).withMutation(r=>r.test({message:e||He.required,name:"required",skipAbsent:!0,test:o=>!!o.length}))}notRequired(){return super.notRequired().withMutation(e=>(e.tests=e.tests.filter(r=>r.OPTIONS.name!=="required"),e))}length(e,r=he.length){return this.test({message:r,name:"length",exclusive:!0,params:{length:e},skipAbsent:!0,test(o){return o.length===this.resolve(e)}})}min(e,r=he.min){return this.test({message:r,name:"min",exclusive:!0,params:{min:e},skipAbsent:!0,test(o){return o.length>=this.resolve(e)}})}max(e,r=he.max){return this.test({name:"max",exclusive:!0,message:r,params:{max:e},skipAbsent:!0,test(o){return o.length<=this.resolve(e)}})}matches(e,r){let o=!1,n,a;return r&&(typeof r=="object"?{excludeEmptyString:o=!1,message:n,name:a}=r:n=r),this.test({name:a||"matches",message:n||he.matches,params:{regex:e},skipAbsent:!0,test:i=>i===""&&o||i.search(e)!==-1})}email(e=he.email){return this.matches($y,{name:"email",message:e,excludeEmptyString:!0})}url(e=he.url){return this.matches(zy,{name:"url",message:e,excludeEmptyString:!0})}uuid(e=he.uuid){return this.matches(_y,{name:"uuid",message:e,excludeEmptyString:!1})}datetime(e){let r="",o,n;return e&&(typeof e=="object"?{message:r="",allowOffset:o=!1,precision:n=void 0}=e:r=e),this.matches(Hy,{name:"datetime",message:r||he.datetime,excludeEmptyString:!0}).test({name:"datetime_offset",message:r||he.datetime_offset,params:{allowOffset:o},skipAbsent:!0,test:a=>{if(!a||o)return!0;let i=ya(a);return i?!!i.z:!1}}).test({name:"datetime_precision",message:r||he.datetime_precision,params:{precision:n},skipAbsent:!0,test:a=>{if(!a||n==null)return!0;let i=ya(a);return i?i.precision===n:!1}})}ensure(){return this.default("").transform(e=>e===null?"":e)}trim(e=he.trim){return this.transform(r=>r!=null?r.trim():r).test({message:e,name:"trim",test:Gy})}lowercase(e=he.lowercase){return this.transform(r=>De(r)?r:r.toLowerCase()).test({message:e,name:"string_case",exclusive:!0,skipAbsent:!0,test:r=>De(r)||r===r.toLowerCase()})}uppercase(e=he.uppercase){return this.transform(r=>De(r)?r:r.toUpperCase()).test({message:e,name:"string_case",exclusive:!0,skipAbsent:!0,test:r=>De(r)||r===r.toUpperCase()})}};ce.prototype=gn.prototype;var Uy=t=>t!=+t;function qy(){return new yn}var yn=class extends re{constructor(){super({type:"number",check(e){return e instanceof Number&&(e=e.valueOf()),typeof e=="number"&&!Uy(e)}}),this.withMutation(()=>{this.transform((e,r)=>{if(!this.spec.coerce)return e;let o=e;if(typeof o=="string"){if(o=o.replace(/\s/g,""),o==="")return NaN;o=+o}return this.isType(o)||o===null?o:parseFloat(o)})})}min(e,r=ut.min){return this.test({message:r,name:"min",exclusive:!0,params:{min:e},skipAbsent:!0,test(o){return o>=this.resolve(e)}})}max(e,r=ut.max){return this.test({message:r,name:"max",exclusive:!0,params:{max:e},skipAbsent:!0,test(o){return o<=this.resolve(e)}})}lessThan(e,r=ut.lessThan){return this.test({message:r,name:"max",exclusive:!0,params:{less:e},skipAbsent:!0,test(o){return o<this.resolve(e)}})}moreThan(e,r=ut.moreThan){return this.test({message:r,name:"min",exclusive:!0,params:{more:e},skipAbsent:!0,test(o){return o>this.resolve(e)}})}positive(e=ut.positive){return this.moreThan(0,e)}negative(e=ut.negative){return this.lessThan(0,e)}integer(e=ut.integer){return this.test({name:"integer",message:e,skipAbsent:!0,test:r=>Number.isInteger(r)})}truncate(){return this.transform(e=>De(e)?e:e|0)}round(e){var r;let o=["ceil","floor","round","trunc"];if(e=((r=e)==null?void 0:r.toLowerCase())||"round",e==="trunc")return this.truncate();if(o.indexOf(e.toLowerCase())===-1)throw new TypeError("Only valid options for round() are: "+o.join(", "));return this.transform(n=>De(n)?n:Math[e](n))}};qy.prototype=yn.prototype;var Ap=new Date(""),Yy=t=>Object.prototype.toString.call(t)==="[object Date]";function Ep(){return new St}var St=class extends re{constructor(){super({type:"date",check(e){return Yy(e)&&!isNaN(e.getTime())}}),this.withMutation(()=>{this.transform((e,r)=>!this.spec.coerce||this.isType(e)||e===null?e:(e=Ly(e),isNaN(e)?St.INVALID_DATE:new Date(e)))})}prepareParam(e,r){let o;if(Qe.isRef(e))o=e;else{let n=this.cast(e);if(!this._typeCheck(n))throw new TypeError(`\`${r}\` must be a Date or a value that can be \`cast()\` to a Date`);o=n}return o}min(e,r=ha.min){let o=this.prepareParam(e,"min");return this.test({message:r,name:"min",exclusive:!0,params:{min:e},skipAbsent:!0,test(n){return n>=this.resolve(o)}})}max(e,r=ha.max){let o=this.prepareParam(e,"max");return this.test({message:r,name:"max",exclusive:!0,params:{max:e},skipAbsent:!0,test(n){return n<=this.resolve(o)}})}};St.INVALID_DATE=Ap;Ep.prototype=St.prototype;Ep.INVALID_DATE=Ap;function Ky(t,e=[]){let r=[],o=new Set,n=new Set(e.map(([i,l])=>`${i}-${l}`));function a(i,l){let s=(0,Ee.split)(i)[0];o.add(s),n.has(`${l}-${s}`)||r.push([l,s])}for(let i of Object.keys(t)){let l=t[i];o.add(i),Qe.isRef(l)&&l.isSibling?a(l.path,i):Cn(l)&&"deps"in l&&l.deps.forEach(s=>a(s,i))}return vp.default.array(Array.from(o),r).reverse()}function gp(t,e){let r=1/0;return t.some((o,n)=>{var a;if((a=e.path)!=null&&a.includes(o))return r=n,!0}),r}function Fp(t){return(e,r)=>gp(t,e)-gp(t,r)}var Mp=(t,e,r)=>{if(typeof t!="string")return t;let o=t;try{o=JSON.parse(t)}catch{}return r.isType(o)?o:t};function fn(t){if("fields"in t){let e={};for(let[r,o]of Object.entries(t.fields))e[r]=fn(o);return t.setFields(e)}if(t.type==="array"){let e=t.optional();return e.innerType&&(e.innerType=fn(e.innerType)),e}return t.type==="tuple"?t.optional().clone({types:t.spec.types.map(fn)}):"optional"in t?t.optional():t}var Zy=(t,e)=>{let r=[...(0,Ee.normalizePath)(e)];if(r.length===1)return r[0]in t;let o=r.pop(),n=(0,Ee.getter)((0,Ee.join)(r),!0)(t);return!!(n&&o in n)},yp=t=>Object.prototype.toString.call(t)==="[object Object]";function bp(t,e){let r=Object.keys(t.fields);return Object.keys(e).filter(o=>r.indexOf(o)===-1)}var Qy=Fp([]);function we(t){return new bn(t)}var bn=class extends re{constructor(e){super({type:"object",check(r){return yp(r)||typeof r=="function"}}),this.fields=Object.create(null),this._sortErrors=Qy,this._nodes=[],this._excludedEdges=[],this.withMutation(()=>{e&&this.shape(e)})}_cast(e,r={}){var o;let n=super._cast(e,r);if(n===void 0)return this.getDefault(r);if(!this._typeCheck(n))return n;let a=this.fields,i=(o=r.stripUnknown)!=null?o:this.spec.noUnknown,l=[].concat(this._nodes,Object.keys(n).filter(d=>!this._nodes.includes(d))),s={},u=Object.assign({},r,{parent:s,__validating:r.__validating||!1}),c=!1;for(let d of l){let f=a[d],m=d in n,h=n[d];if(f){let p;u.path=(r.path?`${r.path}.`:"")+d,f=f.resolve({value:h,context:r.context,parent:s});let y=f instanceof re?f.spec:void 0,v=y?.strict;if(y!=null&&y.strip){c=c||d in n;continue}p=!r.__validating||!v?f.cast(h,u):h,p!==void 0&&(s[d]=p)}else m&&!i&&(s[d]=h);(m!==d in s||s[d]!==h)&&(c=!0)}return c?s:n}_validate(e,r={},o,n){let{from:a=[],originalValue:i=e,recursive:l=this.spec.recursive}=r;r.from=[{schema:this,value:i},...a],r.__validating=!0,r.originalValue=i,super._validate(e,r,o,(s,u)=>{if(!l||!yp(u)){n(s,u);return}i=i||u;let c=[];for(let d of this._nodes){let f=this.fields[d];!f||Qe.isRef(f)||c.push(f.asNestedTest({options:r,key:d,parent:u,parentPath:r.path,originalParent:i}))}this.runTests({tests:c,value:u,originalValue:i,options:r},o,d=>{n(d.sort(this._sortErrors).concat(s),u)})})}clone(e){let r=super.clone(e);return r.fields=Object.assign({},this.fields),r._nodes=this._nodes,r._excludedEdges=this._excludedEdges,r._sortErrors=this._sortErrors,r}concat(e){let r=super.concat(e),o=r.fields;for(let[n,a]of Object.entries(this.fields)){let i=o[n];o[n]=i===void 0?a:i}return r.withMutation(n=>n.setFields(o,[...this._excludedEdges,...e._excludedEdges]))}_getDefault(e){if("default"in this.spec)return super._getDefault(e);if(!this._nodes.length)return;let r={};return this._nodes.forEach(o=>{var n;let a=this.fields[o],i=e;(n=i)!=null&&n.value&&(i=Object.assign({},i,{parent:i.value,value:i.value[o]})),r[o]=a&&"getDefault"in a?a.getDefault(i):void 0}),r}setFields(e,r){let o=this.clone();return o.fields=e,o._nodes=Ky(e,r),o._sortErrors=Fp(Object.keys(e)),r&&(o._excludedEdges=r),o}shape(e,r=[]){return this.clone().withMutation(o=>{let n=o._excludedEdges;return r.length&&(Array.isArray(r[0])||(r=[r]),n=[...o._excludedEdges,...r]),o.setFields(Object.assign(o.fields,e),n)})}partial(){let e={};for(let[r,o]of Object.entries(this.fields))e[r]="optional"in o&&o.optional instanceof Function?o.optional():o;return this.setFields(e)}deepPartial(){return fn(this)}pick(e){let r={};for(let o of e)this.fields[o]&&(r[o]=this.fields[o]);return this.setFields(r,this._excludedEdges.filter(([o,n])=>e.includes(o)&&e.includes(n)))}omit(e){let r=[];for(let o of Object.keys(this.fields))e.includes(o)||r.push(o);return this.pick(r)}from(e,r,o){let n=(0,Ee.getter)(e,!0);return this.transform(a=>{if(!a)return a;let i=a;return Zy(a,e)&&(i=Object.assign({},a),o||delete i[e],i[r]=n(a)),i})}json(){return this.transform(Mp)}exact(e){return this.test({name:"exact",exclusive:!0,message:e||cn.exact,test(r){if(r==null)return!0;let o=bp(this.schema,r);return o.length===0||this.createError({params:{properties:o.join(", ")}})}})}stripUnknown(){return this.clone({noUnknown:!0})}noUnknown(e=!0,r=cn.noUnknown){typeof e!="boolean"&&(r=e,e=!0);let o=this.test({name:"noUnknown",exclusive:!0,message:r,test(n){if(n==null)return!0;let a=bp(this.schema,n);return!e||a.length===0||this.createError({params:{unknown:a.join(", ")}})}});return o.spec.noUnknown=e,o}unknown(e=!0,r=cn.noUnknown){return this.noUnknown(!e,r)}transformKeys(e){return this.transform(r=>{if(!r)return r;let o={};for(let n of Object.keys(r))o[e(n)]=r[n];return o})}camelCase(){return this.transformKeys(Or.camelCase)}snakeCase(){return this.transformKeys(Or.snakeCase)}constantCase(){return this.transformKeys(e=>(0,Or.snakeCase)(e).toUpperCase())}describe(e){let r=(e?this.resolve(e):this).clone(),o=super.describe(e);o.fields={};for(let[a,i]of Object.entries(r.fields)){var n;let l=e;(n=l)!=null&&n.value&&(l=Object.assign({},l,{parent:l.value,value:l.value[a]})),o.fields[a]=i.describe(l)}return o}};we.prototype=bn.prototype;function Jy(t){return new vn(t)}var vn=class extends re{constructor(e){super({type:"array",spec:{types:e},check(r){return Array.isArray(r)}}),this.innerType=void 0,this.innerType=e}_cast(e,r){let o=super._cast(e,r);if(!this._typeCheck(o)||!this.innerType)return o;let n=!1,a=o.map((i,l)=>{let s=this.innerType.cast(i,Object.assign({},r,{path:`${r.path||""}[${l}]`,parent:o,originalValue:i,value:i,index:l}));return s!==i&&(n=!0),s});return n?a:o}_validate(e,r={},o,n){var a;let i=this.innerType,l=(a=r.recursive)!=null?a:this.spec.recursive;r.originalValue!=null&&r.originalValue,super._validate(e,r,o,(s,u)=>{var c;if(!l||!i||!this._typeCheck(u)){n(s,u);return}let d=new Array(u.length);for(let m=0;m<u.length;m++){var f;d[m]=i.asNestedTest({options:r,index:m,parent:u,parentPath:r.path,originalParent:(f=r.originalValue)!=null?f:e})}this.runTests({value:u,tests:d,originalValue:(c=r.originalValue)!=null?c:e,options:r},o,m=>n(m.concat(s),u))})}clone(e){let r=super.clone(e);return r.innerType=this.innerType,r}json(){return this.transform(Mp)}concat(e){let r=super.concat(e);return r.innerType=this.innerType,e.innerType&&(r.innerType=r.innerType?r.innerType.concat(e.innerType):e.innerType),r}of(e){let r=this.clone();if(!Cn(e))throw new TypeError("`array.of()` sub-schema must be a valid yup schema not: "+Ze(e));return r.innerType=e,r.spec=Object.assign({},r.spec,{types:e}),r}length(e,r=pn.length){return this.test({message:r,name:"length",exclusive:!0,params:{length:e},skipAbsent:!0,test(o){return o.length===this.resolve(e)}})}min(e,r){return r=r||pn.min,this.test({message:r,name:"min",exclusive:!0,params:{min:e},skipAbsent:!0,test(o){return o.length>=this.resolve(e)}})}max(e,r){return r=r||pn.max,this.test({message:r,name:"max",exclusive:!0,params:{max:e},skipAbsent:!0,test(o){return o.length<=this.resolve(e)}})}ensure(){return this.default(()=>[]).transform((e,r)=>this._typeCheck(e)?e:r==null?[]:[].concat(r))}compact(e){let r=e?(o,n,a)=>!e(o,n,a):o=>!!o;return this.transform(o=>o!=null?o.filter(r):o)}describe(e){let r=(e?this.resolve(e):this).clone(),o=super.describe(e);if(r.innerType){var n;let a=e;(n=a)!=null&&n.value&&(a=Object.assign({},a,{parent:a.value,value:a.value[0]})),o.innerType=r.innerType.describe(a)}return o}};Jy.prototype=vn.prototype;function Xy(t){return new xn(t)}var xn=class extends re{constructor(e){super({type:"tuple",spec:{types:e},check(r){let o=this.spec.types;return Array.isArray(r)&&r.length===o.length}}),this.withMutation(()=>{this.typeError(Tp.notType)})}_cast(e,r){let{types:o}=this.spec,n=super._cast(e,r);if(!this._typeCheck(n))return n;let a=!1,i=o.map((l,s)=>{let u=l.cast(n[s],Object.assign({},r,{path:`${r.path||""}[${s}]`,parent:n,originalValue:n[s],value:n[s],index:s}));return u!==n[s]&&(a=!0),u});return a?i:n}_validate(e,r={},o,n){let a=this.spec.types;super._validate(e,r,o,(i,l)=>{var s;if(!this._typeCheck(l)){n(i,l);return}let u=[];for(let[d,f]of a.entries()){var c;u[d]=f.asNestedTest({options:r,index:d,parent:l,parentPath:r.path,originalParent:(c=r.originalValue)!=null?c:e})}this.runTests({value:l,tests:u,originalValue:(s=r.originalValue)!=null?s:e,options:r},o,d=>n(d.concat(i),l))})}describe(e){let r=(e?this.resolve(e):this).clone(),o=super.describe(e);return o.innerType=r.spec.types.map((n,a)=>{var i;let l=e;return(i=l)!=null&&i.value&&(l=Object.assign({},l,{parent:l.value,value:l.value[a]})),n.describe(l)}),o}};Xy.prototype=xn.prototype;import{Alert as Lp,Grid as nr}from"@mui/material";import{useState as $p}from"react";import{useCredentials as zb,useForm as _b,useValidations as Nb}from"@data-c/hooks";import{isAxiosError as Vb}from"axios";import{useEffect as zp}from"react";import Wb from"validator/lib/isStrongPassword";import{useState as eb}from"react";import{Visibility as tb,VisibilityOff as rb}from"@mui/icons-material";import{IconButton as ob,InputAdornment as nb,TextField as ib}from"@mui/material";import{jsx as Br}from"react/jsx-runtime";function Tt(t){let{name:e,label:r,value:o,onChange:n,onKeyDown:a}=t,[i,l]=eb(!1);function s(){l(!i)}return Br(ib,{name:e,label:r,value:o||"",onChange:n,onKeyDown:a,type:i?"text":"password",InputProps:{endAdornment:Br(nb,{position:"end",children:Br(ob,{tabIndex:-1,onClick:s,edge:"end",children:i?Br(rb,{}):Br(tb,{})})})}})}import{useDialogs as BD}from"@toolpad/core";import{jsx as ab}from"react/jsx-runtime";function ba({children:t,...e}){return ab(D,{variant:"outlined",color:"error",...e,children:"Cancelar"})}import{Close as sb}from"@mui/icons-material";import{IconButton as lb}from"@mui/material";import{jsx as Rp}from"react/jsx-runtime";function Pt({onClose:t}){return Rp(lb,{onClick:()=>t(),sx:{position:"absolute",right:"11px"},children:Rp(sb,{})})}import{Stack as ub}from"@mui/material";import{jsx as cb}from"react/jsx-runtime";function kt(t){return cb(ub,{direction:"row",alignItems:"center",gap:1,marginLeft:"auto",...t})}import{jsx as pb}from"react/jsx-runtime";function va({children:t,label:e,...r}){return pb(D,{variant:"contained",...r,children:e||"Salvar"})}import{Button as fb}from"@mui/material";import{useDialogs as db}from"@toolpad/core";import{jsx as mb}from"react/jsx-runtime";function xa(t){let{dialogComponent:e,payload:r,label:o,...n}=t,a=db();return mb(fb,{variant:"contained",onClick:()=>{a.open(e,r)},...n,children:o||" Adicionar"})}import{Typography as Ab}from"@mui/material";import{Stack as Dp}from"@mui/material";import{jsx as Op}from"react/jsx-runtime";function It({children:t,...e}){return Op(Dp,{component:"main",margin:"44px 0 55.75px",overflow:"auto",children:Op(Dp,{padding:"16px",...e,children:t})})}import{Stack as hb,useTheme as gb}from"@mui/material";import{jsx as yb}from"react/jsx-runtime";function At(t){let e=gb();return yb(hb,{component:"footer",position:"absolute",direction:"row",alignItems:"center",bottom:0,left:0,right:0,padding:"8px 16px",borderTop:`solid 1px ${e.palette.grey[300]}`,height:"48px",sx:{backgroundColor:e.palette.background.paper},...t})}import{Stack as bb,useTheme as vb}from"@mui/material";import{jsx as xb}from"react/jsx-runtime";function Et(t){let e=vb();return xb(bb,{component:"header",height:"44px",position:"absolute",direction:"row",top:0,left:0,right:0,display:"flex",alignItems:"center",padding:"16px",borderBottom:`solid 1px ${e.palette.grey[300]}`,...t})}import{forwardRef as Cb}from"react";import{Dialog as wb,Slide as Sb,Stack as Tb}from"@mui/material";import{jsx as Ca}from"react/jsx-runtime";var Pb=Cb(function(e,r){return Ca(Sb,{direction:"up",ref:r,...e})});function Ft({children:t,height:e,fullWidth:r=!0,...o}){return Ca(wb,{disableRestoreFocus:!0,fullWidth:r,TransitionComponent:Pb,sx:{"& .MuiBackdrop-root":{backgroundColor:"#6464648F"},...o?.sx},PaperProps:{style:{height:e,overflow:"hidden",position:"absolute",top:"51px",margin:0}},...o,children:Ca(Tb,{height:"100%",position:"relative",overflow:"auto",children:t})})}import{Typography as kb}from"@mui/material";import{jsx as Ib}from"react/jsx-runtime";function Mt(t){return Ib(kb,{component:"h6",variant:"h6",sx:{whiteSpace:"nowrap"},...t})}import{jsx as Rt,jsxs as wa}from"react/jsx-runtime";function Sa(t){let{open:e,onClose:r,payload:o}=t,{title:n,message:a,confirmButtonLabel:i="Confirmar",cancelButtonLabel:l="Cancelar",payload:s}=o;return wa(Ft,{open:e,onClose:()=>r(!1),children:[wa(Et,{children:[Rt(Mt,{children:n||"Precisamos da sua confirma\xE7\xE3o"}),Rt(Pt,{onClose:()=>r(!1)})]}),Rt(It,{children:Rt(Ab,{variant:"body1",children:a||"Voc\xEA tem certeza que deseja continuar?"})}),Rt(At,{children:wa(kt,{children:[Rt(D,{onClick:()=>r(!1),sx:{minWidth:"100px"},children:l}),Rt(D,{color:"error",variant:"contained",onClick:()=>r(s??!0),sx:{minWidth:"100px"},children:i})]})})]})}import{Alert as Eb}from"@mui/material";import{jsx as Dt,jsxs as Ta}from"react/jsx-runtime";function Pa({open:t,onClose:e,payload:r}){let{useRemover:o,configs:n}=r,{mutateAsync:a,isLoading:i}=o();async function l(){try{await a(n),e()}catch{}}return Ta(Ft,{open:t,onClose:e,children:[Ta(Et,{children:[Dt(Mt,{children:"Tem certeza de que deseja excluir este registro?"}),Dt(Pt,{onClose:e})]}),Dt(It,{children:Dt(Eb,{severity:"error",children:"O registro ser\xE1 removido permanentemente. Deseja continuar?"})}),Dt(At,{children:Ta(kt,{children:[Dt(D,{onClick:()=>e(),sx:{minWidth:"100px"},children:"Manter registro"}),Dt(D,{color:"error",variant:"contained",isLoading:i,onClick:l,sx:{minWidth:"100px"},children:"Remover"})]})})]})}import{DialogsProvider as Fb}from"@toolpad/core";import{jsx as Mb}from"react/jsx-runtime";function ka({children:t}){return Mb(Fb,{children:t})}var Rb={Root:Ft,Provider:ka,AdicionarButton:xa,Header:Et,Title:Mt,ActionClose:Pt,Content:It,Footer:At,Actions:kt,ActionCancelar:ba,ActionSalvar:va,ConfirmDelete:Pa,Confirm:Sa},O=Rb;import{Box as Db,Typography as Ob,useTheme as Bb}from"@mui/material";import{Circle as Lb}from"@mui/icons-material";import{jsx as Bp,jsxs as $b}from"react/jsx-runtime";function Ot(t){let{isValid:e,message:r}=t,o=Bb();return $b(Db,{sx:{display:"flex",flexDirection:"row",alignItems:"center"},children:[Bp(Lb,{color:e?"success":"inherit",sx:{fontSize:"8pt"}}),Bp(Ob,{variant:"body2",sx:{color:e?o.palette.success.main:"inherit",textDecoration:e?"line-through":"none",ml:1,fontSize:"10pt"},children:r})]})}import{jsx as J,jsxs as ir}from"react/jsx-runtime";var _p={senhaAtual:"",senhaNova:""},Hb=we().shape({senhaAtual:ce().required("Informe a Senha Atual."),senhaNova:ce().required("Informe a Nova Senha.")});function ar(t){let{isOpen:e,credentialsConfig:r,onClose:o,onSuccess:n,onFailed:a,primeiroAcesso:i,senhaAtual:l,email:s}=t,{alterarSenha:u,isSubmitting:c}=zb(r),{setValidationErrors:d,validationProps:f}=Nb(),{data:m,handleChange:h,setData:p,changeValue:y}=_b(_p),[v,b]=$p(!1),[S,w]=$p(null);zp(()=>{l&&y("senhaAtual",l)},[l]),zp(()=>{m.senhaNova&&b(Wb(m.senhaNova,{minLength:8,minLowercase:1,minUppercase:1,minNumbers:1,minSymbols:1}))},[m.senhaNova]);async function C(){d(null),w(null),Hb.validate(m,{abortEarly:!1}).then(async()=>{let{senhaAtual:A,senhaNova:le}=m;try{await u(A,le,s)&&(n&&n(),p(_p))}catch(g){if(a&&a(g),Vb(g)){w(g.response?.data.message);return}w("Ocorreu um erro ao tentar alterar a senha")}}).catch(A=>{d(A)})}function k(){return m?.senhaNova.length>=8}function P(){if(m?.senhaNova){let A=m?.senhaNova.match(/[a-z]/g);return Array.isArray(A)&&A.length>0}return!1}function Q(){if(m?.senhaNova){let A=m?.senhaNova.match(/[A-Z]/g);return Array.isArray(A)&&A.length>0}return!1}function z(){if(m?.senhaNova){let A=m?.senhaNova.match(/\d/g);return Array.isArray(A)&&A.length>0}return!1}function se(){if(m?.senhaNova){let A=m?.senhaNova.match(/\W/g);return Array.isArray(A)&&A.length>0}return!1}return ir(O.Root,{open:e,onClose:A=>o(),maxWidth:"md",children:[ir(O.Header,{children:[J(O.Title,{children:"Alterar Senha"}),J(O.ActionClose,{onClose:o})]}),J(O.Content,{children:ir(nr,{container:!0,spacing:2,children:[i&&J(nr,{size:12,children:ir(Lp,{severity:"info",children:["Voc\xEA est\xE1 acessando o sistema com uma senha tempor\xE1ria.",J("br",{}),"Cadastre uma senha segura para deixar sua conta mais protegida."]})}),J(nr,{size:12,children:J(Tt,{name:"senhaAtual",label:"Senha Atual",value:m?.senhaAtual||"",onChange:h,...f("senhaAtual")})}),J(nr,{size:12,children:J(Tt,{name:"senhaNova",label:"Nova Senha",value:m?.senhaNova||"",onChange:h,...f("senhaNova")})}),ir(nr,{size:12,children:[J(Ot,{isValid:k(),message:"O tamanho m\xEDnimo da nova senha \xE9 de 8 caracteres"}),J(Ot,{isValid:P(),message:"A nova senha deve ter ao menos uma letra min\xFAscula"}),J(Ot,{isValid:Q(),message:"A nova senha deve ter ao menos uma letra mai\xFAscula"}),J(Ot,{isValid:z(),message:"A nova senha deve ter ao menos um n\xFAmero"}),J(Ot,{isValid:se(),message:"A nova senha deve ter ao menos um caracter especial"})]}),S&&J(nr,{size:12,children:J(Lp,{severity:"error",children:S})})]})}),J(O.Footer,{children:ir(O.Actions,{children:[J(O.ActionCancelar,{onClick:()=>o()}),J(O.ActionSalvar,{label:"Alterar Senha",onClick:C,isLoading:c,disabled:!v})]})})]})}import{Mail as Kb,WhatsApp as Zb}from"@mui/icons-material";import{jsx as ge,jsxs as Lr}from"react/jsx-runtime";var Qb=we().shape({email:ce().required("Informe o e-mail"),password:ce().required("Informe a senha")});function Ia(t){let{onLoginSuccess:e,onLoginFailed:r,onOptionsClick:o,credentialsConfig:n}=t,[a,i]=sr(""),[l,s]=sr(""),[u,c]=sr(!1),[d,f]=sr(!1),[m,h]=sr(!1),[p,y]=sr(null),{login:v}=Yb(n),{validationProps:b,setValidationErrors:S}=qb();async function w(){S(null),y(null),Qb.validate({email:a,password:l},{abortEarly:!1}).then(async()=>{c(!0);try{let C=await v(a,l);C&&e(C)}catch(C){if(Ub(C)){if(C.response?.data.code==="E_FIRST_ACCESS"){f(!0);return}y(C.response?.data.message)}r(C)}}).catch(C=>{S(C)}).finally(()=>{c(!1)})}return Lr(wn,{component:"form",onSubmit:w,children:[Lr(wn,{spacing:2,children:[ge(Gb,{name:"email",label:"E-mail",margin:"normal",autoFocus:!0,value:a||"",onChange:C=>i(C.target.value),...b("email")}),ge(Tt,{name:"password",label:"Senha",size:"medium",placeholder:"Sua senha",value:l||"",onChange:C=>s(C.target.value),onKeyDown:C=>C.key==="Enter"&&w(),...b("password")}),ge(D,{fullWidth:!0,variant:"contained",onClick:w,isLoading:u,sx:{mt:1},children:"Entrar"})]}),ge(D,{onClick:()=>o("esqueci-senha"),variant:"text",disableRipple:!0,disableTouchRipple:!0,sx:{justifyContent:"flex-start",alignContent:"center",alignItems:"center",textAlign:"left",width:"120px",marginTop:.5,fontWeight:"400",":hover":{}},children:"Esqueci a senha"}),p&&ge(Np,{severity:"error",children:p}),m&&Lr(Np,{severity:"success",children:["Senha cadastrada com sucesso",ge("br",{}),"Tudo pronto para voc\xEA fazer o login"]}),Lr(wn,{direction:"row",justifyContent:"center",alignItems:"center",mt:2,mb:2,children:[ge(Vp,{sx:{flexGrow:1,mr:1}}),ge(jb,{children:"Ou fa\xE7a login com"}),ge(Vp,{sx:{flexGrow:1,ml:1}})]}),Lr(wn,{spacing:1,children:[ge(D,{onClick:()=>o("otp-email"),startIcon:ge(Kb,{}),children:"Entrar com senha tempor\xE1ria"}),ge(D,{onClick:()=>o("otp-whatsapp"),startIcon:ge(Zb,{}),children:"Entrar com senha tempor\xE1ria"})]}),ge(ar,{senhaAtual:l,email:a,primeiroAcesso:!0,isOpen:d,onClose:async()=>f(!1),onSuccess:()=>{f(!1),h(!0),s("")},credentialsConfig:n})]})}import{useState as Sn}from"react";import{Alert as Wp,Box as Jb,TextField as Xb}from"@mui/material";import{useCredentials as ev,useValidations as tv}from"@data-c/hooks";import{jsx as Bt,jsxs as ov}from"react/jsx-runtime";var rv=we().shape({email:ce().required("Informe o e-mail")});function Aa(t){let{onLoginClick:e,credentialsConfig:r}=t,[o,n]=Sn(""),[a,i]=Sn(!1),[l,s]=Sn(!1),[u,c]=Sn(null),{recuperarSenha:d}=ev(r),{validationProps:f,setValidationErrors:m}=tv();async function h(){m(null),rv.validate({email:o},{abortEarly:!1}).then(async()=>{try{i(!0),await d(o),s(!0)}catch(p){c(p.response?.data.message)}finally{i(!1)}}).catch(p=>{m(p)})}return ov(Jb,{component:"form",children:[Bt(Xb,{name:"email",label:"E-mail",margin:"normal",placeholder:"Informe o e-mail utilizado para acessar o sistema",autoFocus:!0,value:o||"",onChange:p=>n(p.target.value),...f("email")}),Bt(D,{fullWidth:!0,variant:"contained",onClick:h,isLoading:a,children:"Recuperar minha senha"}),Bt(_e,{sx:{display:"inline-flex",justifyContent:"space-between",width:"100%",marginTop:1},children:Bt(D,{onClick:e,variant:"text",sx:{fontWeight:"400",":hover":{color:p=>p.palette.primary.dark}},children:"Voltar para o Login"})}),l&&Bt(Wp,{severity:"success",action:Bt(D,{onClick:e,variant:"text",sx:{fontWeight:"400",":hover":{color:p=>p.palette.primary.dark}},children:"Ir para o Login"}),children:"Enviamos para o seu e-mail as instru\xE7\xF5es para recuperar a sua senha"}),u&&Bt(Wp,{severity:"error",children:u})]})}import{useEffect as nv,useState as iv}from"react";import{Box as av,MenuItem as sv,TextField as lv}from"@mui/material";import{useCredentials as uv}from"@data-c/hooks";import{jsx as Ea,jsxs as cv}from"react/jsx-runtime";function Fa(t){let{loginData:e,credentialsConfig:r,onLoginFailed:o,onLoginSuccess:n}=t,[a,i]=iv(""),{selecionarLicenca:l,isSubmitting:s}=uv(r);nv(()=>{if(Array.isArray(e?.empresas)){let c=e?.empresas[0];i(c?.uuid)}},[e]);async function u(){try{let c=await l(e?.token,a);c?n(c):o("Nenhuma token definida")}catch(c){o(c)}}return cv(av,{component:"form",sx:{minWidth:"290px"},children:[Ea(lv,{label:"Licen\xE7as",margin:"normal",select:!0,autoFocus:!0,value:a,onChange:c=>{i(c.target.value)},children:e?.empresas?.map(c=>Ea(sv,{value:c.uuid,children:c.nome},c.uuid))}),Ea(D,{fullWidth:!0,variant:"contained",onClick:u,isLoading:s,sx:{mt:1},children:"Confirmar"})]})}import{useEffect as Bv,useState as qp}from"react";import{useCredentials as Lv}from"@data-c/hooks";import{Alert as wv,IconButton as Sv,Stack as Up,TextField as Tv,Typography as Pv}from"@mui/material";import{useForm as kv}from"@data-c/hooks";import{useState as pv,useMemo as fv}from"react";import dv from"@mui/material/TextField";import{jsx as mv}from"react/jsx-runtime";var Hp=t=>{let e=t.replace(/\D/g,"");return e.length<=2?`(${e}`:e.length<=7?`(${e.slice(0,2)}) ${e.slice(2)}`:e.length<=11?`(${e.slice(0,2)}) ${e.slice(2,7)}-${e.slice(7)}`:`(${e.slice(0,2)}) ${e.slice(2,7)}-${e.slice(7,11)}`};function $r(t){let{value:e,onChange:r,...o}=t,[n,a]=pv(""),i=e!==void 0,l=fv(()=>i?Hp(e||""):n,[e,n,i]);return mv(dv,{value:l,onChange:u=>{let c=Hp(u.target.value);if(i||a(c),r){let d={...u,target:{...u.target,value:c}};r(d)}},inputProps:{maxLength:15},...o})}import{useCredentials as Iv}from"@data-c/hooks";import{useState as Da}from"react";import{useCredentials as bv}from"@data-c/hooks";import{Alert as vv,Stack as xv,Typography as jp}from"@mui/material";import{useEffect as Cv,useState as Ma}from"react";import{useRef as hv}from"react";import{Box as gv,TextField as yv}from"@mui/material";import{jsx as Gp}from"react/jsx-runtime";function zr({length:t=6,value:e,onChange:r}){let o=hv([]),n=(i,l)=>{let s="ABCDEF0123456789",u=l.toUpperCase().split("").find(f=>s.includes(f))||"",c=e.split("");c[i]=u;let d=c.join("");r(d),u&&i<t-1&&o.current[i+1]?.focus()},a=(i,l)=>{l.key==="Backspace"&&!e[i]&&i>0&&o.current[i-1]?.focus()};return Gp(gv,{display:"flex",gap:1,children:Array.from({length:t}).map((i,l)=>Gp(yv,{autoFocus:l===0,inputRef:s=>o.current[l]=s,slotProps:{htmlInput:{maxLength:1,style:{textAlign:"center",fontSize:"24px",width:"24px",height:"36px"}}},value:e[l]||"",onChange:s=>n(l,s.target.value),onKeyDown:s=>a(l,s)},l))})}import{jsx as Oe,jsxs as _r}from"react/jsx-runtime";function Ra(t){let{open:e,onClose:r,payload:o,onLoginSuccess:n,credentialsConfig:a}=t,[i,l]=Ma(""),[s,u]=Ma(!1),[c,d]=Ma(!1),{validarOtpVerificationCode:f}=bv(a);Cv(()=>{s&&setTimeout(()=>{u(!1)},3e3)},[s]);async function m(){try{d(!0);let h=await f({channel:o.channel,target:o.target,code:i});h&&n(h),r()}catch(h){u(h.response.data.message)}finally{d(!1)}}return _r(O.Root,{open:e,onClose:h=>r(),maxWidth:"xs",children:[_r(O.Header,{children:[Oe(O.Title,{children:"Entrar com senha tempor\xE1ria"}),Oe(O.ActionClose,{onClose:r})]}),Oe(O.Content,{children:_r(xv,{spacing:2,justifyContent:"center",alignContent:"center",alignItems:"center",children:[Oe(jp,{variant:"subtitle1",sx:{fontWeight:"bolder",fontSize:"11pt"},children:"\u{1F510} Digite a senha tempor\xE1ria para acessar sua conta"}),_r(jp,{variant:"body1",sx:{fontSize:"10pt"},children:["Enviamos uma senha tempor\xE1ria para ",Oe("b",{children:o.target}),". ",Oe("br",{}),"Digite o c\xF3digo abaixo para acessar sua conta."]}),Oe(zr,{value:i,onChange:h=>{l(h)}}),s&&Oe(vv,{sx:{flexGrow:1},severity:"error",children:s})]})}),Oe(O.Footer,{children:_r(O.Actions,{children:[Oe(O.ActionCancelar,{onClick:()=>r()}),Oe(O.ActionSalvar,{label:"Entrar",onClick:m,isLoading:c,disabled:i.length!=6})]})})]})}import{HelpOutline as Av}from"@mui/icons-material";import{Fragment as Fv,jsx as Be,jsxs as Tn}from"react/jsx-runtime";var Ev=we().shape({contato:ce().when("$tipo",([t],e)=>t==="otp-email"?e.email("E-mail inv\xE1lido").required("Informe o e-mail"):e.matches(/^\+?[1-9]\d{7,14}$/,"N\xFAmero de WhatsApp inv\xE1lido").required("Informe o WhatsApp"))});function Pn(t){let{tipo:e,credentialsConfig:r,onLoginSuccess:o,onLoginClick:n}=t,[a,i]=Da(!1),[l,s]=Da(!1),{gerarOtpVerificationCode:u}=Iv(r),{handleChange:c,changeValue:d,data:f,validate:m,validationErrors:h}=kv({contato:""},Ev),[p,y]=Da(!1);return Tn(Fv,{children:[Be("form",{onSubmit:async b=>{b.preventDefault(),m(async S=>{try{s(!1),i(!0);let w=await u({channel:e==="otp-email"?"email":"whatsapp",target:S.contato});y(!0)}catch(w){s(w.response.data.message)}finally{i(!1)}},{context:{tipo:e}})},children:Tn(Up,{spacing:2,children:[Be(Pv,{variant:"subtitle2",children:e==="otp-email"?" Informe seu e-mail para receber um c\xF3digo de acesso":"Informe seu n\xFAmero de WhatsApp para receber um c\xF3digo de acesso"}),e==="otp-email"&&Be(Tv,{autoFocus:!0,name:"contato",label:"E-mail",value:f.contato||"",onChange:c,fullWidth:!0,...h("contato")}),e==="otp-whatsapp"&&Be($r,{autoFocus:!0,name:"contato",label:"Whatsapp",value:f.contato||"",onChange:b=>{d("contato",b.target.value.replace(/[^\d+]/g,""))},fullWidth:!0,...h("contato")}),Tn(Up,{children:[Be(D,{isLoading:a,type:"submit",variant:"contained",color:"primary",children:"Enviar c\xF3digo"}),Tn(_e,{sx:{display:"inline-flex",justifyContent:"space-between",width:"100%",marginTop:1},children:[Be(D,{onClick:n,variant:"text",sx:{fontWeight:"400",":hover":{color:b=>b.palette.primary.dark}},children:"Voltar para o Login"}),Be("a",{href:"https://datacsistemashelp.zendesk.com/hc/pt-br/articles/36489079108756-Login-OTP-via-WhatsApp",target:"_blank",rel:"noopener noreferrer",children:Be(Sv,{children:Be(Av,{color:"primary"})})})]})]}),l&&Be(wv,{severity:"error",children:l})]})}),Be(Ra,{onLoginSuccess:o,open:p,onClose:async b=>{y(!1)},payload:{target:f.contato,channel:e==="otp-email"?"email":"whatsapp"},credentialsConfig:r})]})}import{jsx as lr,jsxs as Yp}from"react/jsx-runtime";var $v={login:"Acesse sua conta",licensa:"Selecione a licen\xE7a","esqueci-senha":"Recupere a sua senha","otp-email":"Entrar com senha tempor\xE1ria (E-mail)","otp-whatsapp":"Entrar com senha tempor\xE1ria (WhatsApp)"};function Oa(t){let{credentialsConfig:e,onLoginSuccess:r,onLoginFailed:o,onAlreadyLogged:n,appName:a}=t,[i,l]=qp(),{selecionarLicenca:s,isAuthenticated:u}=Lv(e),[c,d]=qp("login"),f=Ov(),m=Dv(f.breakpoints.up("md"));Bv(()=>{u&&n&&n()},[u]);async function h(S){try{if(Array.isArray(S?.empresas)){if(S?.empresas.length===1){let w=await s(S?.token,S.empresas[0].uuid);w&&r(w);return}d("licensa"),l(S);return}r(S)}catch(w){o(w)}}async function p(S){o(S)}function y(S){d(S)}function v(){d("login")}let b=$v[c];return Yp(Rv,{children:[lr(la,{label:a,subTitle:b}),Yp(Mv,{sx:{marginTop:2},children:[c==="login"&&lr(Ia,{credentialsConfig:e,onLoginSuccess:h,onLoginFailed:p,onOptionsClick:y}),c==="licensa"&&lr(Fa,{loginData:i,credentialsConfig:e,onLoginSuccess:r,onLoginFailed:o}),c==="esqueci-senha"&&lr(Aa,{onLoginClick:v,credentialsConfig:e}),c==="otp-email"&&lr(Pn,{onLoginClick:v,onLoginSuccess:h,tipo:"otp-email",credentialsConfig:e}),c==="otp-whatsapp"&&lr(Pn,{onLoginClick:v,onLoginSuccess:h,tipo:"otp-whatsapp",credentialsConfig:e})]})]})}import{ArrowRight as zv}from"@mui/icons-material";import{Link as _v,Stack as Kp,Typography as Ba,useMediaQuery as Nv,useTheme as Vv}from"@mui/material";import{jsx as ur,jsxs as Zp}from"react/jsx-runtime";function La(){let t=Vv(),e=Nv(t.breakpoints.up("md"));return ur(Kp,{component:"section",display:e?"flex":"none",width:"100%",direction:"row",justifyContent:"center",alignItems:"center",sx:{backgroundImage:"url(https://datac-site-assets.s3.sa-east-1.amazonaws.com/background_login.png)",backgroundSize:"cover",backgroundPosition:"right",backgroundRepeat:"no-repeat"},children:Zp(Kp,{padding:"2rem",children:[ur(Ba,{component:"h1",fontSize:"3.5rem",lineHeight:"4rem",fontWeight:"bold",color:"white",fontFamily:"Montserrat",letterSpacing:0,children:"Inova\xE7\xE3o e tecnologia"}),ur(Ba,{component:"h2",color:"white",fontSize:"2.5rem",lineHeight:"3rem",letterSpacing:0,fontWeight:"bold",fontFamily:"Montserrat",children:"para empresas de resultado"}),ur(Ba,{component:"span",fontSize:"1.25rem",lineHeight:"1.25rem",fontWeight:"300",letterSpacing:0,marginTop:"1.5rem",marginBottom:"3rem",fontFamily:"Montserrat",sx:{color:"rgb(68, 167, 255)"},children:"Mais de 30 anos de exist\xEAncia e muitas hist\xF3rias de sucesso."}),ur(_v,{href:"https://site.datac.com.br/services/",target:"_blank",children:Zp(D,{component:"a",variant:"text",sx:{width:"fit-content",color:"rgb(255, 255, 255)",fontWeight:"400",fontSize:"0.875rem",lineHeight:"1.125rem",fontFamily:"Montserrat",backgroundColor:"rgb(22, 23, 101)",borderRadius:"30px",padding:"17px 48px",":hover":{backgroundColor:"rgb(255, 255, 255)",color:"rgb(22, 23, 101)"},alignItems:"center"},children:["Conhe\xE7a nossos produtos",ur(zv,{fontSize:"medium",sx:{color:r=>r.palette.success.light}})]})})]})})}import{jsx as Lt,jsxs as $a}from"react/jsx-runtime";function jv({children:t}){let e=Gv(),r=Hv(e.breakpoints.up("md"));return $a(kn,{component:"section",width:r?"46%":"100%",minWidth:"420px",maxWidth:r?"614px":"initial",justifyContent:"center",alignItems:"center",padding:"2rem",children:[Lt(kn,{width:"100%",maxWidth:"28rem",margin:"auto 0",children:t}),$a(kn,{direction:"row",alignItems:"center",marginBottom:-3,children:[Lt("img",{width:"60",src:"https://datac-site-assets.s3.sa-east-1.amazonaws.com/logomarca.png"}),Lt(Wv,{variant:"body1",component:"span",fontSize:"0.7rem",sx:{color:o=>o.palette.grey[500]},children:"Data C Sistemas"})]})]})}function Qp(t){let{banner:e,loginSection:r}=t;return $a(kn,{component:"main",direction:"row",height:"100vh",children:[e?Lt(sa,{children:e}):Lt(La,{}),Lt(jv,{children:r||Lt(Oa,{...t})})]})}import{formatDocumento as Od,normalizeText as Bd}from"@data-c/hooks";import{Stack as Uv}from"@mui/material";import{jsx as qv}from"react/jsx-runtime";function za(t){return qv(Uv,{direction:"row",alignItems:"center",alignContent:"center",spacing:1,flex:1,flexGrow:1,...t})}import{AppBar as Yv,Stack as Kv,Toolbar as Zv}from"@mui/material";import Qv from"react";import{jsx as In}from"react/jsx-runtime";function _a({children:t}){return In(Qv.Fragment,{children:In(Yv,{position:"fixed",elevation:0,sx:{width:"100%",zIndex:e=>e.zIndex.drawer+1,borderBottom:e=>`1px solid ${e.palette.grey[300]}`},children:In(Zv,{children:In(Kv,{sx:{width:"100%"},direction:"row",alignContent:"center",alignItems:"center",justifyContent:"space-between",children:t})})})})}import{IconButton as T1}from"@mui/material";import{SvgIcon as Jv}from"@mui/material";import{jsx as cr,jsxs as Xv}from"react/jsx-runtime";function Na(t){return cr(Jv,{...t,children:Xv("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[cr("path",{d:"M3 5v14"}),cr("path",{d:"M8 5v14"}),cr("path",{d:"M12 5v14"}),cr("path",{d:"M17 5v14"}),cr("path",{d:"M21 5v14"})]})})}import{SvgIcon as ex}from"@mui/material";import{jsx as Va,jsxs as tx}from"react/jsx-runtime";function Wa(t){return Va(ex,{...t,children:tx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Va("circle",{cx:"12",cy:"12",r:"10"}),Va("path",{d:"m4.9 4.9 14.2 14.2"})]})})}import{SvgIcon as rx}from"@mui/material";import{jsx as An,jsxs as ox}from"react/jsx-runtime";function Ha(t){return An(rx,{...t,children:ox("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[An("rect",{width:"20",height:"5",x:"2",y:"3",rx:"1"}),An("path",{d:"M4 8v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8"}),An("path",{d:"M10 12h4"})]})})}import{SvgIcon as nx}from"@mui/material";import{jsx as Ga}from"react/jsx-runtime";function Nr(t){return Ga(nx,{...t,children:Ga("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:Ga("path",{d:"m6 9 6 6 6-6"})})})}import{SvgIcon as ix}from"@mui/material";import{jsx as ja}from"react/jsx-runtime";function Ua(t){return ja(ix,{...t,children:ja("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:ja("path",{d:"M12 3c7.2 0 9 1.8 9 9s-1.8 9-9 9-9-1.8-9-9 1.8-9 9-9"})})})}import{SvgIcon as ax}from"@mui/material";import{jsx as Vr,jsxs as sx}from"react/jsx-runtime";function qa(t){return Vr(ax,{...t,children:sx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Vr("path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2"}),Vr("circle",{cx:"9",cy:"7",r:"4"}),Vr("path",{d:"M22 21v-2a4 4 0 0 0-3-3.87"}),Vr("path",{d:"M16 3.13a4 4 0 0 1 0 7.75"})]})})}import{SvgIcon as lx}from"@mui/material";import{jsx as Ya,jsxs as ux}from"react/jsx-runtime";function Ka(t){return Ya(lx,{...t,children:ux("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Ya("path",{d:"m11 17-5-5 5-5"}),Ya("path",{d:"m18 17-5-5 5-5"})]})})}import{SvgIcon as cx}from"@mui/material";import{jsx as Za,jsxs as px}from"react/jsx-runtime";function Qa(t){return Za(cx,{...t,children:px("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Za("path",{d:"M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z"}),Za("circle",{cx:"12",cy:"12",r:"3"})]})})}import{SvgIcon as fx}from"@mui/material";import{jsx as Wr,jsxs as dx}from"react/jsx-runtime";function Ja(t){return Wr(fx,{...t,children:dx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Wr("rect",{width:"7",height:"9",x:"3",y:"3",rx:"1"}),Wr("rect",{width:"7",height:"5",x:"14",y:"3",rx:"1"}),Wr("rect",{width:"7",height:"9",x:"14",y:"12",rx:"1"}),Wr("rect",{width:"7",height:"5",x:"3",y:"16",rx:"1"})]})})}import{SvgIcon as mx}from"@mui/material";import{jsx as pr,jsxs as hx}from"react/jsx-runtime";function Xa(t){return pr(mx,{...t,children:hx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[pr("path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z"}),pr("path",{d:"M14 2v4a2 2 0 0 0 2 2h4"}),pr("path",{d:"M10 9H8"}),pr("path",{d:"M16 13H8"}),pr("path",{d:"M16 17H8"})]})})}import{SvgIcon as gx}from"@mui/material";import{jsx as es}from"react/jsx-runtime";function Hr(t){return es(gx,{...t,children:es("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:es("path",{d:"m6 9 6 6 6-6"})})})}import{SvgIcon as yx}from"@mui/material";import{jsx as En,jsxs as bx}from"react/jsx-runtime";function ts(t){return En(yx,{...t,children:bx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[En("path",{d:"m7 21-4.3-4.3c-1-1-1-2.5 0-3.4l9.6-9.6c1-1 2.5-1 3.4 0l5.6 5.6c1 1 1 2.5 0 3.4L13 21"}),En("path",{d:"M22 21H7"}),En("path",{d:"m5 11 9 9"})]})})}import{styled as vx}from"@mui/material/styles";import{jsx as wx}from"react/jsx-runtime";var xx=t=>({transition:t.transitions.create(["transform"],{duration:500})}),Cx=vx(Hr,{shouldForwardProp:t=>t!=="open"})(({theme:t,open:e})=>({...xx(t),...e&&{transform:"rotate(-180deg)"},...!e&&{transform:"rotate(0)"}}));function rs(t){let{open:e}=t;return wx(Cx,{fontSize:"small",open:e})}import{SvgIcon as Sx}from"@mui/material";import{jsx as Fn,jsxs as Tx}from"react/jsx-runtime";function os(t){return Fn(Sx,{...t,children:Tx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Fn("path",{d:"M3 6h18"}),Fn("path",{d:"M7 12h10"}),Fn("path",{d:"M10 18h4"})]})})}import{SvgIcon as Px}from"@mui/material";import{jsx as Mn,jsxs as kx}from"react/jsx-runtime";function ns(t){return Mn(Px,{...t,children:kx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[Mn("path",{d:"M18 20a6 6 0 0 0-12 0"}),Mn("circle",{cx:"12",cy:"10",r:"4"}),Mn("circle",{cx:"12",cy:"12",r:"10"})]})})}import{SvgIcon as Ix}from"@mui/material";import{jsx as fr,jsxs as Ax}from"react/jsx-runtime";function is(t){return fr(Ix,{...t,children:Ax("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[fr("path",{d:"m11 17 2 2a1 1 0 1 0 3-3"}),fr("path",{d:"m14 14 2.5 2.5a1 1 0 1 0 3-3l-3.88-3.88a3 3 0 0 0-4.24 0l-.88.88a1 1 0 1 1-3-3l2.81-2.81a5.79 5.79 0 0 1 7.06-.87l.47.28a2 2 0 0 0 1.42.25L21 4"}),fr("path",{d:"m21 3 1 11h-2"}),fr("path",{d:"M3 3 2 14l6.5 6.5a1 1 0 1 0 3-3"}),fr("path",{d:"M3 4h8"})]})})}import{SvgIcon as Ex}from"@mui/material";import{jsx as Rn,jsxs as Fx}from"react/jsx-runtime";function as(t){return Rn(Ex,{...t,children:Fx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Rn("path",{d:"M7.9 20A9 9 0 1 0 4 16.1L2 22Z"}),Rn("path",{d:"M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3"}),Rn("path",{d:"M12 17h.01"})]})})}import{SvgIcon as Mx}from"@mui/material";import{jsx as Dn,jsxs as Rx}from"react/jsx-runtime";function ss(t){return Dn(Mx,{...t,children:Rx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Dn("path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8"}),Dn("path",{d:"M3 3v5h5"}),Dn("path",{d:"M12 7v5l4 2"})]})})}import{SvgIcon as Dx}from"@mui/material";import{jsx as Gr,jsxs as Ox}from"react/jsx-runtime";function ls(t){return Gr(Dx,{...t,children:Ox("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Gr("rect",{width:"18",height:"18",x:"3",y:"3",rx:"2"}),Gr("path",{d:"M8 7v7"}),Gr("path",{d:"M12 7v4"}),Gr("path",{d:"M16 7v9"})]})})}import{SvgIcon as Bx}from"@mui/material";import{jsx as On,jsxs as Lx}from"react/jsx-runtime";function us(t){return On(Bx,{...t,children:Lx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[On("path",{d:"M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4"}),On("polyline",{points:"16 17 21 12 16 7"}),On("line",{x1:"21",x2:"9",y1:"12",y2:"12"})]})})}import{SvgIcon as $x}from"@mui/material";import{jsx as cs,jsxs as zx}from"react/jsx-runtime";function ps(t){return cs($x,{...t,children:zx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"white",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[cs("path",{d:"M20 10c0 4.993-5.539 10.193-7.399 11.799a1 1 0 0 1-1.202 0C9.539 20.193 4 14.993 4 10a8 8 0 0 1 16 0"}),cs("circle",{cx:"12",cy:"10",r:"3"})]})})}import{SvgIcon as _x}from"@mui/material";import{jsx as Bn,jsxs as Nx}from"react/jsx-runtime";function fs(t){return Bn(_x,{...t,children:Nx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Bn("path",{d:"M14.106 5.553a2 2 0 0 0 1.788 0l3.659-1.83A1 1 0 0 1 21 4.619v12.764a1 1 0 0 1-.553.894l-4.553 2.277a2 2 0 0 1-1.788 0l-4.212-2.106a2 2 0 0 0-1.788 0l-3.659 1.83A1 1 0 0 1 3 19.381V6.618a1 1 0 0 1 .553-.894l4.553-2.277a2 2 0 0 1 1.788 0z"}),Bn("path",{d:"M15 5.764v15"}),Bn("path",{d:"M9 3.236v15"})]})})}import{SvgIcon as Vx}from"@mui/material";import{jsx as Ln,jsxs as Wx}from"react/jsx-runtime";function ds(t){return Ln(Vx,{...t,children:Wx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Ln("line",{x1:"4",x2:"20",y1:"12",y2:"12"}),Ln("line",{x1:"4",x2:"20",y1:"6",y2:"6"}),Ln("line",{x1:"4",x2:"20",y1:"18",y2:"18"})]})})}import{SvgIcon as Hx}from"@mui/material";import{jsx as dr,jsxs as Gx}from"react/jsx-runtime";function ms(t){return dr(Hx,{...t,children:Gx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[dr("path",{d:"m11 17 2 2a1 1 0 1 0 3-3"}),dr("path",{d:"m14 14 2.5 2.5a1 1 0 1 0 3-3l-3.88-3.88a3 3 0 0 0-4.24 0l-.88.88a1 1 0 1 1-3-3l2.81-2.81a5.79 5.79 0 0 1 7.06-.87l.47.28a2 2 0 0 0 1.42.25L21 4"}),dr("path",{d:"m21 3 1 11h-2"}),dr("path",{d:"M3 3 2 14l6.5 6.5a1 1 0 1 0 3-3"}),dr("path",{d:"M3 4h8"})]})})}import{SvgIcon as jx}from"@mui/material";import{jsx as hs,jsxs as Ux}from"react/jsx-runtime";function gs(t){return hs(jx,{...t,children:Ux("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[hs("path",{d:"m6 17 5-5-5-5"}),hs("path",{d:"m13 17 5-5-5-5"})]})})}import{SvgIcon as qx}from"@mui/material";import{jsx as ys,jsxs as Yx}from"react/jsx-runtime";function bs(t){return ys(qx,{...t,children:Yx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[ys("path",{d:"M2.586 17.414A2 2 0 0 0 2 18.828V21a1 1 0 0 0 1 1h3a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h1a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h.172a2 2 0 0 0 1.414-.586l.814-.814a6.5 6.5 0 1 0-4-4z"}),ys("circle",{cx:"16.5",cy:"7.5",r:".5",fill:"currentColor"})]})})}import{SvgIcon as Kx}from"@mui/material";import{jsx as vs,jsxs as Zx}from"react/jsx-runtime";function xs(t){return vs(Kx,{...t,children:Zx("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[vs("circle",{cx:"11",cy:"11",r:"8"}),vs("path",{d:"m21 21-4.3-4.3"})]})})}import{SvgIcon as Qx}from"@mui/material";import{jsx as mr,jsxs as Jx}from"react/jsx-runtime";function Cs(t){return mr(Qx,{...t,children:Jx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[mr("path",{d:"m2 7 4.41-4.41A2 2 0 0 1 7.83 2h8.34a2 2 0 0 1 1.42.59L22 7"}),mr("path",{d:"M4 12v8a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-8"}),mr("path",{d:"M15 22v-4a2 2 0 0 0-2-2h-2a2 2 0 0 0-2 2v4"}),mr("path",{d:"M2 7h20"}),mr("path",{d:"M22 7v3a2 2 0 0 1-2 2a2.7 2.7 0 0 1-1.59-.63.7.7 0 0 0-.82 0A2.7 2.7 0 0 1 16 12a2.7 2.7 0 0 1-1.59-.63.7.7 0 0 0-.82 0A2.7 2.7 0 0 1 12 12a2.7 2.7 0 0 1-1.59-.63.7.7 0 0 0-.82 0A2.7 2.7 0 0 1 8 12a2.7 2.7 0 0 1-1.59-.63.7.7 0 0 0-.82 0A2.7 2.7 0 0 1 4 12a2 2 0 0 1-2-2V7"})]})})}import{SvgIcon as Xx}from"@mui/material";import{jsx as $n,jsxs as e1}from"react/jsx-runtime";function ws(t){return $n(Xx,{...t,children:e1("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[$n("path",{d:"M17 22h-1a4 4 0 0 1-4-4V6a4 4 0 0 1 4-4h1"}),$n("path",{d:"M7 22h1a4 4 0 0 0 4-4v-1"}),$n("path",{d:"M7 2h1a4 4 0 0 1 4 4v1"})]})})}import{SvgIcon as t1}from"@mui/material";import{jsx as jr,jsxs as r1}from"react/jsx-runtime";function Ss(t){return jr(t1,{...t,children:r1("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[jr("path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2"}),jr("circle",{cx:"9",cy:"7",r:"4"}),jr("path",{d:"M22 21v-2a4 4 0 0 0-3-3.87"}),jr("path",{d:"M16 3.13a4 4 0 0 1 0 7.75"})]})})}import{SvgIcon as o1}from"@mui/material";import{jsx as Ts,jsxs as n1}from"react/jsx-runtime";function Ps(t){return Ts(o1,{...t,children:n1("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Ts("path",{d:"M2.5 17a24.12 24.12 0 0 1 0-10 2 2 0 0 1 1.4-1.4 49.56 49.56 0 0 1 16.2 0A2 2 0 0 1 21.5 7a24.12 24.12 0 0 1 0 10 2 2 0 0 1-1.4 1.4 49.55 49.55 0 0 1-16.2 0A2 2 0 0 1 2.5 17"}),Ts("path",{d:"m10 15 5-3-5-3z"})]})})}import{SvgIcon as i1}from"@mui/material";import{jsx as zn,jsxs as a1}from"react/jsx-runtime";function ks(t){return zn(i1,{...t,children:a1("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[zn("path",{d:"M12 17V3"}),zn("path",{d:"m6 11 6 6 6-6"}),zn("path",{d:"M19 21H5"})]})})}import{SvgIcon as s1}from"@mui/material";import{jsx as $t,jsxs as l1}from"react/jsx-runtime";function Is(t){return $t(s1,{...t,children:l1("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[$t("line",{x1:"3",x2:"21",y1:"22",y2:"22"}),$t("line",{x1:"6",x2:"6",y1:"18",y2:"11"}),$t("line",{x1:"10",x2:"10",y1:"18",y2:"11"}),$t("line",{x1:"14",x2:"14",y1:"18",y2:"11"}),$t("line",{x1:"18",x2:"18",y1:"18",y2:"11"}),$t("polygon",{points:"12 2 20 7 4 7"})]})})}import{SvgIcon as u1}from"@mui/material";import{jsx as Ur,jsxs as c1}from"react/jsx-runtime";function As(t){return Ur(u1,{...t,children:c1("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Ur("path",{d:"M15.536 11.293a1 1 0 0 0 0 1.414l2.376 2.377a1 1 0 0 0 1.414 0l2.377-2.377a1 1 0 0 0 0-1.414l-2.377-2.377a1 1 0 0 0-1.414 0z"}),Ur("path",{d:"M2.297 11.293a1 1 0 0 0 0 1.414l2.377 2.377a1 1 0 0 0 1.414 0l2.377-2.377a1 1 0 0 0 0-1.414L6.088 8.916a1 1 0 0 0-1.414 0z"}),Ur("path",{d:"M8.916 17.912a1 1 0 0 0 0 1.415l2.377 2.376a1 1 0 0 0 1.414 0l2.377-2.376a1 1 0 0 0 0-1.415l-2.377-2.376a1 1 0 0 0-1.414 0z"}),Ur("path",{d:"M8.916 4.674a1 1 0 0 0 0 1.414l2.377 2.376a1 1 0 0 0 1.414 0l2.377-2.376a1 1 0 0 0 0-1.414l-2.377-2.377a1 1 0 0 0-1.414 0z"})]})})}import{SvgIcon as p1}from"@mui/material";import{jsx as _n,jsxs as f1}from"react/jsx-runtime";function Es(t){return _n(p1,{...t,children:f1("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[_n("circle",{cx:"16",cy:"16",r:"6"}),_n("path",{d:"M7 20H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H20a2 2 0 0 1 2 2"}),_n("path",{d:"M16 14v2l1 1"})]})})}import{SvgIcon as d1}from"@mui/material";import{jsx as qr,jsxs as m1}from"react/jsx-runtime";function Fs(t){return qr(d1,{...t,children:m1("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[qr("path",{d:"M13.22 2.416a2 2 0 0 0-2.511.057l-7 5.999A2 2 0 0 0 3 10v9a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7.354"}),qr("path",{d:"M15 21v-8a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v8"}),qr("path",{d:"M15 6h6"}),qr("path",{d:"M18 3v6"})]})})}import{SvgIcon as h1}from"@mui/material";import{jsx as hr,jsxs as g1}from"react/jsx-runtime";function Ms(t){return hr(h1,{...t,children:g1("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[hr("rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2"}),hr("line",{x1:"3",x2:"21",y1:"9",y2:"9"}),hr("line",{x1:"3",x2:"21",y1:"15",y2:"15"}),hr("line",{x1:"9",x2:"9",y1:"9",y2:"21"}),hr("line",{x1:"15",x2:"15",y1:"9",y2:"21"})]})})}import{SvgIcon as y1}from"@mui/material";import{jsx as Rs}from"react/jsx-runtime";function Ds(t){return Rs(y1,{...t,children:Rs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:Rs("path",{d:"m15 18-6-6 6-6"})})})}import{SvgIcon as b1}from"@mui/material";import{jsx as Os}from"react/jsx-runtime";function Bs(t){return Os(b1,{...t,children:Os("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:Os("path",{d:"m9 18 6-6-6-6"})})})}import{SvgIcon as v1}from"@mui/material";import{jsx as Le,jsxs as x1}from"react/jsx-runtime";function Ls(t){return Le(v1,{...t,children:x1("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Le("path",{d:"M8 2v4"}),Le("path",{d:"M16 2v4"}),Le("rect",{width:"18",height:"18",x:"3",y:"4",rx:"2"}),Le("path",{d:"M3 10h18"}),Le("path",{d:"M8 14h.01"}),Le("path",{d:"M12 14h.01"}),Le("path",{d:"M16 14h.01"}),Le("path",{d:"M8 18h.01"}),Le("path",{d:"M12 18h.01"}),Le("path",{d:"M16 18h.01"})]})})}import{SvgIcon as C1}from"@mui/material";import{jsx as Nn,jsxs as w1}from"react/jsx-runtime";function $s(t){return Nn(C1,{...t,children:w1("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",children:[Nn("path",{d:"M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z"}),Nn("path",{d:"M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7"}),Nn("path",{d:"M7 3v4a1 1 0 0 0 1 1h7"})]})})}var S1={Circle:Ua,Dashboard:Ja,Expandable:rs,Down:Hr,Negociacao:ms,Cadastro:Ha,Clientes:qa,Filter:os,Search:xs,ChevronDown:Nr,Kanban:ls,Erease:ts,BarCode:Na,TextCursor:ws,OpenPanel:gs,ClosePanel:Ka,Menu:ds,Configs:Qa,Users:Ss,Password:bs,Logout:us,History:ss,Help:as,Video:Ps,Docs:Xa,Block:Wa,Maps:fs,MapPin:ps,HandShake:is,Store:Cs,Download:ks,ContaBancaria:Is,GrupoLancamento:As,HistoricoPadrao:Es,Imovel:Fs,Lancamento:Ms,ChevronLeft:Ds,ChevronRight:Bs,Calendar:Ls,Save:$s,Profile:ns},ye=S1;import{jsx as Jp}from"react/jsx-runtime";function zs(t){let{...e}=t;return Jp(T1,{...e,children:Jp(ye.Menu,{})})}var P1={Root:_a,Content:za,ToggleMenu:zs},k1=P1;import{Collapse as I1,List as A1,ListItem as E1,ListItemIcon as F1,ListItemText as M1,Icon as R1,ListItemButton as D1,styled as O1}from"@mui/material";import{useState as B1}from"react";import{Fragment as $1,jsx as ct,jsxs as Xp}from"react/jsx-runtime";var L1=O1(D1,{})(({theme:t})=>({height:"32px",cursor:"pointer",gap:t.spacing(2),transition:"0.2s ease-in-out",padding:`${t.spacing(.25)} ${t.spacing(2)} ${t.spacing(.25)} ${t.spacing(2)}`,"&:hover":{backgroundColor:"rgba(89, 195, 224, 15%);","& .MuiTypography-root":{color:t.palette.primary.main,transition:"0.2s ease-in-out"},"& .MuiSvgIcon-root":{color:t.palette.primary.main,transition:"0.2s ease-in-out"},"& .MuiIcon-root":{color:t.palette.primary.main,transition:"0.2s ease-in-out"}},"& .MuiIcon-root":{color:t.palette.grey[500],fontSize:"20px"},"& .MuiTypography-root":{fontSize:"0.805rem",color:t.palette.text.primary},"& .MuiSvgIcon-root":{fontSize:"0.955rem"},"& .MuiListItemIcon-root":{minWidth:"0px"}}));function _s({label:t,icon:e,visible:r=!0,children:o,selected:n=!1,onClick:a,link:i,secondaryLabel:l}){if(!r)return null;let[s,u]=B1(!1),c=!!o;function d(){if(c){u(m=>!m);return}a&&i&&a(i)}function f(m){return typeof e=="string"?ct(R1,{children:e}):m||ct(ye.Circle,{})}return Xp($1,{children:[ct(E1,{disableGutters:!0,disablePadding:!0,children:Xp(L1,{selected:n,disableGutters:!0,onClick:m=>{m.stopPropagation(),d()},children:[ct(F1,{children:f(e)}),ct(M1,{primary:t}),l,c&&ct(ye.Expandable,{open:s})]})}),c&&ct(I1,{in:s,timeout:"auto",unmountOnExit:!0,children:ct(A1,{sx:{"& .MuiListItemButton-root":{paddingLeft:4},"& .MuiList-root > .MuiListItem-root > .MuiListItemButton-root":{paddingLeft:6},"& .MuiList-root > .MuiList-root > .MuiListItemButton-root":{paddingLeft:12}},disablePadding:!0,children:o})})]})}import{ListItem as N1,ListItemIcon as V1,ListItemText as W1,Icon as H1,ListItemButton as G1,Popper as j1,styled as U1}from"@mui/material";import q1 from"lodash";import Ns,{useState as Y1}from"react";import{Paper as z1}from"@mui/material";import{jsx as _1}from"react/jsx-runtime";function Vn(t){return _1(z1,{sx:{p:2},elevation:0,...t})}import{jsx as zt,jsxs as Z1}from"react/jsx-runtime";var K1=U1(G1,{})(({theme:t})=>({cursor:"pointer",padding:`${t.spacing(1)} ${t.spacing(0)} ${t.spacing(.25)} ${t.spacing(0)}`,minHeight:"32px",flexDirection:"column",justifyContent:"center",alignItem:"center",alignContent:"center","&:hover":{backgroundColor:"rgba(89, 195, 224, 15%);","& .MuiTypography-root":{color:t.palette.primary.main,transition:"0.2s ease-in-out"},"& .MuiSvgIcon-root":{color:t.palette.primary.main,transition:"0.2s ease-in-out"},"& .MuiIcon-root":{color:t.palette.primary.main,transition:"0.2s ease-in-out"}},"& .MuiIcon-root":{color:t.palette.grey[500],fontSize:"20px"},"& .MuiSvgIcon-root":{fontSize:"0.955rem"},"& .MuiTypography-root":{fontSize:"0.805rem",color:t.palette.text.primary},"& .MuiListItemIcon-root":{minWidth:"0px"}}));function ef(t,e){return Ns.Children.map(t,r=>{if(!Ns.isValidElement(r))return r;let o=r.props?.children?ef(r.props.children,e):null;return Ns.cloneElement(r,{open:e,children:o})})}function Vs(t){let{icon:e,label:r,link:o,id:n,selected:a=!1,children:i,onClick:l}=t,[s,u]=Y1(null);function c(){l&&o&&l(o)}function d(p,y){u({element:p.currentTarget,id:y})}function f(){u(null)}let m=ef(i,!0);function h(p){return typeof e=="string"?zt(H1,{children:e}):p||zt(ye.Circle,{})}return zt(N1,{disableGutters:!0,disablePadding:!0,children:Z1(K1,{selected:a,onMouseEnter:p=>{o||d(p,n)},onMouseLeave:()=>{o||f()},disableGutters:!0,onClick:p=>{p.stopPropagation(),c()},children:[zt(V1,{children:h(e)}),zt(W1,{primary:q1.truncate(r,{length:12})}),s?.id===n&&zt(j1,{sx:{zIndex:999999},anchorEl:s?.element,open:!!s?.element,placement:"right-start",children:zt(Vn,{elevation:1,sx:{position:"relative","&::before":{content:'""',position:"absolute",left:-8,width:"1.2rem",height:"1.2rem",backgroundImage:'url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0IiBmaWxsPSJub25lIiBzdHJva2U9IiM4MDgwODAiIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIiBjbGFzcz0ibHVjaWRlIGx1Y2lkZS1waW4tc2FmZXR5LW9wZW4iPjxwYXRoIGQ9Ik0yMC44IDMuMmMtMS42LTEuNi00LjEtMS42LTUuNyAwTDEyLjMgNlMxNSA5IDE4IDZjLTMgMyAwIDUuNyAwIDUuN2wyLjgtMi44YzEuNi0xLjYgMS42LTQuMiAwLTUuNyIvPjxwYXRoIGQ9Im03LjEgMjEuMSAxMC4zLTEwLjIiLz48Y2lyY2xlIGN4PSI1IiBjeT0iMTkiIHI9IjMiLz48cGF0aCBkPSJNOSAycy00LjEgOS41LTYuNzU1IDE1LjgiLz48L3N2Zz4=")',backgroundSize:"contain",backgroundRepeat:"no-repeat",transition:"transform 0.2s ease-in-out"},p:1,width:p=>p.mixins.menu?.width},children:m})})]})})}import{jsx as tf}from"react/jsx-runtime";function Ws(t){let{open:e,isFirstLevel:r=!1,...o}=t;return e?tf(_s,{...o}):tf(Vs,{...o})}import{createContext as Q1,useContext as J1,useEffect as X1,useState as eC}from"react";import{jsx as oC}from"react/jsx-runtime";function tC(t,e){if(!t)throw new Error(e)}var rf=Q1(null);function of(t){let{children:e,storageKey:r="mio:menu"}=t,[o,n]=eC(()=>{let i=window.localStorage.getItem(r)||"true";return i?JSON.parse(i):!0});function a(){n(i=>!i)}return X1(()=>{window.localStorage.setItem(r,JSON.stringify(o))},[o,r]),oC(rf.Provider,{value:{isOpen:o,toggleMenu:a},children:e})}function rC(){let t=J1(rf);return tC(t,"cannot find MenuContext provider"),t}import{List as nC,Drawer as iC}from"@mui/material";import{styled as lf}from"@mui/material/styles";import Hs from"react";import{jsx as sf,jsxs as lC}from"react/jsx-runtime";var nf=t=>({width:t?.mixins?.menu?.width||64,background:"#FFFFFF",transition:t.transitions.create("width",{easing:t.transitions.easing.sharp,duration:t.transitions.duration.enteringScreen}),overflowX:"hidden"}),af=t=>({background:"#FFFFFF",transition:t.transitions.create("width",{easing:t.transitions.easing.sharp,duration:t.transitions.duration.leavingScreen}),overflowX:"hidden",width:0,[t.breakpoints.up("sm")]:{width:`calc(${t.spacing(12)} + 1px)`}}),aC=lf(iC,{shouldForwardProp:t=>t!=="open"})(({theme:t,open:e})=>({width:t?.mixins?.menu?.width||64,borderRightStyle:"none",whiteSpace:"nowrap",boxSizing:"border-box",...e&&{...nf(t),"& .MuiDrawer-paper":nf(t)},...!e&&{...af(t),"& .MuiDrawer-paper":af(t)}})),sC=lf("div")(({theme:t})=>t.mixins.toolbar);function uf(t,e,r,o){return Hs.Children.map(t,n=>{if(!Hs.isValidElement(n))return n;let a=n.props.link?.split("/").filter(Boolean)||[],i=n.props.link||"",u="/"+(e?.split("/").filter(Boolean)||[]).slice(0,a.length).join("/"),c=n.props?.children?uf(n.props.children,e,r,o):null;return Hs.cloneElement(n,{open:r,selected:u===i,onClick:d=>{o&&o(d)},children:c})})}function Gs(t){let{open:e,toggleMenu:r,children:o,onClickItem:n,listProps:a}=t,l=new URL(window.location.href).pathname,s=uf(o,l,e,n);return lC(aC,{variant:"permanent",open:e,onClose:r,children:[sf(sC,{}),sf(nC,{...a,children:s})]})}import{jsx as pC}from"react/jsx-runtime";function uC(t){return t.map(e=>e.visible?pC(cf.Item,{link:e.link,id:e.id,label:e.label,icon:e.icon,secondaryLabel:e.secondaryLabel,children:e.items&&uC(e.items)},e.id):null)}var cf={Root:Gs,Item:Ws,Provider:of};var cC=cf;import{Button as fC,Breadcrumbs as dC,Typography as mC}from"@mui/material";import{jsx as js}from"react/jsx-runtime";function pf(t){let{links:e}=t;function r(o,n){location.pathname}return js(dC,{sx:{height:"30px",display:"flex",textWrap:"nowrap"},children:e.map((o,n)=>e.length===1||e.length===n+1?js(mC,{sx:{fontSize:"10pt",fontWeight:"bolder"},variant:"subtitle1",color:"black",children:o.label},o.link):js(fC,{variant:"text",children:o.label},o.link))})}import{Stack as hC}from"@mui/material";import{jsx as gC}from"react/jsx-runtime";function Us(t){let{children:e}=t;return gC(hC,{pl:1,pr:1,pt:.5,pb:.5,direction:"row",alignContent:"center",alignItems:"center",justifyContent:"space-between",spacing:1,children:e})}var yC={Root:Us},bC=yC;import{Stack as vC}from"@mui/material";import{jsx as xC}from"react/jsx-runtime";function qs({children:t,...e}){return xC(vC,{pt:1,pl:1,pr:1,pb:1,direction:"row",spacing:1,justifyContent:"flex-end",sx:{backgroundColor:r=>r.palette.background.paper,borderTop:r=>`1px solid ${r.palette.border}`},...e,children:t})}import{IconButton as kC}from"@mui/material";import mf,{useContext as hf,useEffect as ff,useMemo as wC,useReducer as SC}from"react";var CC=process.env.NODE_ENV==="production",Ys="Invariant failed";function Ks(t,e){if(!t){if(CC)throw new Error(Ys);var r=typeof e=="function"?e():e,o=r?"".concat(Ys,": ").concat(r):Ys;throw new Error(o)}}import{v4 as TC}from"uuid";import{jsx as df}from"react/jsx-runtime";function PC(t,e){switch(e.type){case"loadFiltersFromStorage":return{...t,filterValues:e?.storageValues?.filterValues,appliedValues:e?.storageValues?.appliedValues};case"updateFilterValues":return{...t,filterValues:e.filterValues};case"updateFilterValue":return{...t,filterValues:{...t.filterValues,[e.payload.name]:e.payload.value}};case"updateAppliedValues":let r=t.filterValues,o=[];if(r&&Object.entries(r).length>0){let[s]=Object.keys(r);o=[{[s]:r[s]}]}return e?.storagePath&&localStorage.setItem(e.storagePath,JSON.stringify({appliedValues:r,filterValuesAsArray:o,filterValues:t.filterValues})),e.onFilterApplied&&e.onFilterApplied(r),{...t,appliedValues:r,filterValuesAsArray:o,isOpen:!1,searchId:TC()};case"updateIsOpen":return{...t,isOpen:e.isOpen,target:e.target};case"updateContainer":return{...t,container:e.container};case"toggleIsOpen":return{...t,isOpen:!t.isOpen};case"deleteAppliedValue":let{[e.filterName]:n,...a}=t.appliedValues||{},{[e.filterName]:i,...l}=t.filterValues||{};if(e?.storagePath){let s=JSON.parse(localStorage.getItem(e.storagePath)||"{}"),{[e.filterName]:u,...c}=s.appliedValues||{},{[e.filterName]:d,...f}=s.filterValues||{};localStorage.setItem(e.storagePath,JSON.stringify({...s,appliedValues:c,filterValues:f}))}return{...t,appliedValues:a,filterValues:l};case"deleteAllAppliedValues":return e.storagePath&&localStorage.removeItem(e.storagePath),e.onFilterApplied&&e.onFilterApplied(e.filterValues),{...t,appliedValues:{},filterValues:e.filterValues}}}var gf=mf.createContext({}),yf=mf.createContext({});function bf(t){let{children:e,filterValues:r,storagePath:o,onFilterApplied:n}=t,[a,i]=SC(PC,{filterValues:{}});ff(()=>{r!=null&&(i({type:"updateFilterValues",filterValues:r}),i({type:"updateAppliedValues",storagePath:o,onFilterApplied:n}))},[r,o,n]),ff(()=>{if(o){let s=localStorage.getItem(o);if(s&&s!=="undefined"){let u=JSON.parse(s);i({type:"loadFiltersFromStorage",storageValues:u})}}},[o]);let l=wC(()=>{function s(b){i({type:"updateIsOpen",isOpen:!0,target:b?.target||void 0})}function u(){i({type:"updateIsOpen",isOpen:!1,target:void 0})}function c(){i({type:"toggleIsOpen"})}function d(b){let S=b.target.type,w=b.target.name,C;switch(S){case"text":C=b.target.value;break;case"checkbox":C=b.target.checked;break;default:C=b.target.value}i({type:"updateFilterValue",payload:{name:w,value:C}})}function f(b,S){i({type:"updateFilterValue",payload:{name:b,value:S}})}function m(b){i({type:"updateFilterValues",filterValues:b})}function h(){i({type:"updateAppliedValues",storagePath:o,onFilterApplied:n})}function p(b){i({type:"deleteAppliedValue",filterName:b,storagePath:o,onFilterApplied:n})}function y(){i({type:"deleteAllAppliedValues",filterValues:r,storagePath:o}),i({type:"updateAppliedValues",storagePath:o,onFilterApplied:n})}function v(b){i({type:"updateContainer",container:b})}return{setContainer:v,openFilter:s,closeFilter:u,onChangeFilterValue:d,changeFilterValue:f,changeFilterValues:m,applyFilterValues:h,deleteFilterValue:p,deleteAllFilterValues:y,toggleFilter:c}},[r]);return df(yf.Provider,{value:l,children:df(gf.Provider,{value:a,children:e})})}function gr(){let t=hf(gf);return Ks(t,"cannot find FilterDataContext provider"),t}function Fe(){let t=hf(yf);return Ks(t,"cannot find FilterApiContextContext provider"),t}import{jsx as vf}from"react/jsx-runtime";function Zs(){let{openFilter:t}=Fe();return vf(kC,{onClick:e=>{t(e)},children:vf(ye.Filter,{})})}import{Popover as IC}from"@mui/material";import{jsx as AC}from"react/jsx-runtime";function Qs(t){let{children:e}=t,{isOpen:r,container:o}=gr(),{closeFilter:n}=Fe();return AC(IC,{elevation:0,open:r,onClose:n,anchorEl:o,anchorOrigin:{vertical:"bottom",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"right"},sx:{"& .MuiPopover-paper":{width:"360px",border:i=>`1px solid ${i.palette.border}`,borderRadius:"8px",mt:.5,pt:2}},children:e})}import{Box as EC}from"@mui/material";import{jsx as FC}from"react/jsx-runtime";function Js({children:t}){return FC(EC,{mt:1,ml:1,mr:1,mb:2,children:t})}import{Button as MC,Stack as RC}from"@mui/material";import{jsx as Xs,jsxs as DC}from"react/jsx-runtime";function el(){let{applyFilterValues:t}=Fe();return Xs(MC,{variant:"contained",onClick:()=>{t()},children:DC(RC,{direction:"row",spacing:.5,alignItems:"center",children:[Xs(ye.Search,{sx:{fontSize:"0.855rem"}})," ",Xs("span",{children:"Pesquisar"})]})})}import{Chip as OC}from"@mui/material";import{jsx as BC}from"react/jsx-runtime";function tl(t){let{children:e,disabledDelete:r=!1,...o}=t;return BC(OC,{...o})}import{usePopover as LC}from"@data-c/hooks";import{Box as $C,Button as xf,Popover as zC,Stack as Cf}from"@mui/material";import Yr from"react";import{jsx as rl,jsxs as ol}from"react/jsx-runtime";function nl({children:t}){let{appliedValues:e}=gr(),{applyFilterValues:r,deleteFilterValue:o}=Fe(),{isOpen:n,open:a,close:i,anchorEl:l,data:s}=LC(),u=Yr.Children.map(t,c=>!Yr.isValidElement(c)||!(e&&c.props.name in e)?null:Yr.cloneElement(c,{onDelete:c.props.disabledDelete?void 0:f=>{o&&o(c.props.name||""),i()},onClick:f=>{a(f,{target:f.currentTarget,name:c.props.name,disabledDelete:c.props.disabledDelete||!1})}}));return ol(Cf,{direction:"row",spacing:.5,flex:1,justifyContent:"flex-end",children:[u,ol(zC,{open:!!n||!1,onClose:()=>i(),anchorEl:l,elevation:0,sx:{"& .MuiPopover-paper":{minWidth:"300px",border:c=>`1px solid ${c.palette.border}`,borderRadius:"8px",mt:1}},anchorOrigin:{vertical:"bottom",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"right"},children:[rl($C,{pt:2,pl:1,pr:1,pb:2,children:Yr.Children.map(t,c=>Yr.isValidElement(c)&&c.props.name===s?.name?c.props.children:null)}),ol(Cf,{sx:{backgroundColor:c=>c.palette.background.paper,borderTop:c=>`1px solid ${c.palette.border}`},p:1,direction:"row",justifyContent:"flex-end",spacing:1,children:[!s?.disabledDelete&&rl(xf,{color:"error",onClick:()=>{o&&o(s?.name||""),i()},children:"Apagar"}),rl(xf,{variant:"contained",onClick:()=>{i(),r()},children:"Aplicar"})]})]})]})}import{Stack as wf}from"@mui/material";import{useEffect as _C,useRef as NC}from"react";import{jsx as Sf,jsxs as VC}from"react/jsx-runtime";function il({children:t}){let e=NC(null),{setContainer:r}=Fe(),{container:o}=gr();return _C(()=>{let n=()=>{e.current&&r(e.current)};return n(),window.addEventListener("resize",n),()=>{window.removeEventListener("resize",n)}},[o]),VC(wf,{ref:e,direction:"row",alignContent:"center",alignItems:"center",spacing:1,children:[Sf(ye.Search,{sx:{fontSize:"0.95rem"}}),Sf(wf,{width:"100%",direction:"row",justifyContent:"space-between",alignItems:"center",alignContent:"center",children:t})]})}import{Button as WC}from"@mui/material";import{jsx as HC}from"react/jsx-runtime";function al(){let{deleteAllFilterValues:t}=Fe();return HC(WC,{color:"error",onClick:()=>{t&&t()},children:"Resetar"})}import{Box as GC}from"@mui/material";import{jsx as jC}from"react/jsx-runtime";function sl(t){let{children:e}=t;return jC(GC,{sx:{border:r=>`1px solid ${r.palette.border}`,borderRadius:"90px",flexGrow:1,pl:1,pr:1},children:e})}import{InputBase as UC}from"@mui/material";import qC from"lodash";import{jsx as YC}from"react/jsx-runtime";function ll(t){let{onChange:e,...r}=t,o=qC.debounce(a=>e(a),500);function n(a){let i=a.target.value;o(i)}return YC(UC,{fullWidth:!0,onChange:n,...r})}var KC={Root:sl,SearchTextField:ll,Container:il,AdvancedContainer:Qs,AdvancedContent:Js,AdvancedActionsContainer:qs,AdvancedButton:Zs,Provider:bf,ApplyButton:el,ResetButton:al,Chips:nl,Chip:tl},ZC=KC;import{ColumnsPanelTrigger as pS,useGridApiRef as fS}from"@mui/x-data-grid";import{useEffect as Ef,useMemo as tw}from"react";import{Circle as Ff}from"@mui/icons-material";import{LinearProgress as rw,Stack as ow}from"@mui/material";import{DataGrid as nw,gridFilteredSortedRowIdsSelector as iw}from"@mui/x-data-grid";import{ptBR as aw}from"@mui/x-data-grid/locales";import{Stack as ul,Typography as Tf}from"@mui/material";import{jsx as Wn,jsxs as Pf}from"react/jsx-runtime";function cl(){return Pf(ul,{alignItems:"center",justifyContent:"center",gap:2,padding:2,maxWidth:"400px",minWidth:"200px",children:[Wn(ul,{width:"250px",height:"250px",alignItems:"center",justifyContent:"center",borderRadius:"50%",sx:{background:"linear-gradient(to top, #ffffff, #fdfcfd, #fafafa, #f8f7f8, #f5f5f6);"},children:Wn("img",{src:"https://datac-site-assets.s3.sa-east-1.amazonaws.com/empty-data.svg",alt:"Imagem de notifica\xE7\xE3o",width:"148px",height:"148px"})}),Pf(ul,{spacing:1,textAlign:"center",children:[Wn(Tf,{variant:"h4",component:"h2",fontWeight:"600",children:"Nenhum registro encontrado"}),Wn(Tf,{variant:"body2",whiteSpace:"normal",children:"Tente outra pesquisa ou adicione um novo registro."})]})]})}import{Stack as pl,Typography as kf}from"@mui/material";import{jsx as Hn,jsxs as If}from"react/jsx-runtime";function fl({errorMessage:t}){return If(pl,{alignItems:"center",justifyContent:"center",gap:2,padding:2,maxWidth:"400px",minWidth:"200px",children:[Hn(pl,{width:"250px",height:"250px",alignItems:"center",justifyContent:"center",borderRadius:"50%",sx:{background:"linear-gradient(to top, #ffffff, #fdfcfd, #fafafa, #f8f7f8, #f5f5f6);"},children:Hn("img",{src:"https://datac-site-assets.s3.sa-east-1.amazonaws.com/error.svg",alt:"Imagem de erro",width:"148px",height:"148px"})}),If(pl,{gap:1,textAlign:"center",children:[Hn(kf,{variant:"h4",component:"h2",fontWeight:"600",children:"Ops! Algo deu errado"}),Hn(kf,{variant:"body2",children:t})]})]})}import{createContext as QC,useContext as JC,useState as dl}from"react";import{useGridApiRef as XC}from"@mui/x-data-grid";import{jsx as ew}from"react/jsx-runtime";var Af=QC({});function ml({children:t}){let[e,r]=dl({type:"include",ids:new Set}),[o,n]=dl(!1),[a,i]=dl(!1),l=XC();function s(){r({type:"include",ids:new Set}),n(!0)}return ew(Af.Provider,{value:{apiRef:l,rowsSelectedId:e,clearCallback:o,breakpoint:a,setClearCallback:n,setBreakpoint:i,setRowsSelectedId:r,clearRowsSelectedId:s},children:t})}function Ge(){return JC(Af)}import{jsx as yr,jsxs as lw}from"react/jsx-runtime";var sw=({apiRef:t})=>iw(t);function hl(t){let{error:e,isLoading:r,isFetching:o,data:n,columns:a,controlledRowsSelectedId:i,onClearRowsSelectedId:l,onRowSelectionChange:s,onCellKeyDown:u,onRowDoubleClick:c,stackProps:d,slots:f,...m}=t,{rowsSelectedId:h,setRowsSelectedId:p,clearCallback:y,setClearCallback:v,apiRef:b}=Ge(),S=tw(()=>k=>k.map(P=>P.headerName==="A\xE7\xF5es"?{...P,minWidth:P.minWidth||80,maxWidth:P.maxWidth||P.width||80,headerClassName:"sticky-header",cellClassName:"sticky-cell"}:{...P,flex:P.flex||1,minWidth:P.minWidth||100,headerClassName:P?.enableStickyColumns?"sticky-header":"",cellClassName:P?.enableStickyColumns?"sticky-cell":""}),[a]);Ef(()=>{i&&p(i)},[i]),Ef(()=>{y&&(l&&l({type:"include",ids:new Set}),v(!1))},[y]);function w(k,P,Q){switch(P.ctrlKey&&P.code==="KeyE"?"ctrl+e":P.code){case"Enter":P.preventDefault(),u&&u("edit",k.id);break;case"F3":P.preventDefault(),u&&u("edit",k.id);break;case"Delete":P.preventDefault(),u&&u("delete",k.id);break;case"ctrl+e":P.preventDefault(),(A=>{b?.current&&b.current.exportDataAsCsv(A)})({getRowsToExport:sw});break;default:break}}function C(k,P,Q){c&&c("edit",k.id)}return lw(ow,{height:"100%",minHeight:"500px",position:"relative",...d,children:[!r&&o&&yr(rw,{sx:{position:"absolute",top:0,right:0,left:0,zIndex:999,height:"3px"}}),yr(nw,{apiRef:b,rows:n,columns:S(a),density:"compact",hideFooterPagination:!0,hideFooter:!0,loading:r,rowHeight:43,columnHeaderHeight:43,disableVirtualization:!0,onRowDoubleClick:C,onCellKeyDown:w,disableRowSelectionOnClick:!0,rowSelectionModel:h,onRowSelectionModelChange:(k,P)=>{s&&s(k,P),!i&&p(k)},slots:{booleanCellFalseIcon:()=>yr(Ff,{color:"error",sx:{fontSize:"10pt"}}),booleanCellTrueIcon:()=>yr(Ff,{color:"success",sx:{fontSize:"10pt"}}),noRowsOverlay:()=>!r&&e?yr(fl,{errorMessage:e}):yr(cl,{}),...f},slotProps:{loadingOverlay:{variant:"skeleton",noRowsVariant:"skeleton"}},disableColumnFilter:!0,localeText:aw.components.MuiDataGrid.defaultProps.localeText,sx:{border:"none",borderRadius:0,"--DataGrid-rowBorderColor":"#edf2f9","--DataGrid-containerBackground":"#f4f6fa",".MuiDataGrid-overlayWrapperInner":{display:"flex",alignItems:"center",justifyContent:"center"},".MuiDataGrid-row":{backgroundColor:"white","&:nth-of-type(even)":{backgroundColor:"#f9fafd"},":hover":{backgroundColor:"#e9e9e9"},"&.Mui-selected":{backgroundColor:"rgb(238, 249, 252)","&:hover":{backgroundColor:"rgb(222, 243, 249)"}}},".MuiDataGrid-cell":{fontSize:"12px",color:"#0b0e14"},".MuiDataGrid-columnHeaders":{border:"solid 1px #edf2f9"},".MuiDataGrid-columnHeaderTitle":{fontSize:"12px",color:"#0b0e14",fontWeight:"600"},"& .sticky-cell":{position:"sticky",right:0,background:"inherit",zIndex:1},"& .sticky-header":{position:"sticky",right:0,background:"inherit",zIndex:2}},...m})]})}import{GridActionsCellItem as uw}from"@mui/x-data-grid";import{jsx as cw}from"react/jsx-runtime";function gl(t){let{ref:e,...r}=t;return cw(uw,{...r,ref:e})}import{GridActionsCellItem as pw}from"@mui/x-data-grid";import{Trash2 as fw}from"lucide-react";import{jsx as Mf}from"react/jsx-runtime";function yl(t){let{ref:e,...r}=t;return Mf(pw,{color:"error",label:"Deletar",icon:Mf(fw,{size:16}),...r,ref:e})}import{GridActionsCellItem as dw}from"@mui/x-data-grid";import{Pencil as mw}from"lucide-react";import{jsx as Rf}from"react/jsx-runtime";function bl(t){let{ref:e,...r}=t;return Rf(dw,{label:"Editar",color:"primary",icon:Rf(mw,{size:16}),...r,ref:e})}import{useEffect as hw}from"react";import{Stack as gw,useMediaQuery as yw,useTheme as bw}from"@mui/material";import{jsx as vw}from"react/jsx-runtime";function vl({children:t,breakpoints:e}){let{setBreakpoint:r}=Ge(),o=bw(),n=yw(o.breakpoints.down(e||"md"));return hw(()=>{r(n)},[n]),vw(gw,{flexDirection:"row",alignItems:"center",justifyContent:"flex-end",gap:1,marginLeft:"auto",flexGrow:1,children:t})}import{GridActionsCellItem as xw}from"@mui/x-data-grid";import{ArrowBigDown as Cw}from"lucide-react";import{jsx as Df}from"react/jsx-runtime";function xl(t){let{ref:e,...r}=t;return Df(xw,{color:"primary",label:"Transportar",icon:Df(Cw,{size:16}),...r,ref:e})}import{Button as ww,CircularProgress as Of,IconButton as Sw,Tooltip as Tw,Box as Pw}from"@mui/material";import{Fragment as kw,jsx as Kr,jsxs as Bf}from"react/jsx-runtime";function Zr(t){let{isLoading:e,startIcon:r,children:o,title:n,...a}=t,{breakpoint:i}=Ge();return Kr(kw,{children:i?Kr(Tw,{title:o,children:Bf(Sw,{...a,color:"primary",disabled:e?!0:a.disabled,children:[r,e&&Kr(Of,{color:"secondary",size:14,sx:{position:"absolute",top:"25%",bottom:"25%",left:"25%",right:"25%",transform:"translate(-50%, -50%)"}})]})}):Kr(ww,{startIcon:r,disabled:e?!0:a.disabled,sx:{position:"relative",height:"26px",minWidth:"70px",padding:"7px 8px 8px",border:"1px solid rgba(223, 226, 231, 0.8)",borderRadius:"6px",display:"flex",alignItems:"center",overflow:"hidden",whiteSpace:"nowrap",flexShrink:1,transition:"width 0.2s ease"},...a,children:Bf(Pw,{component:"span",sx:{transition:"opacity 0.2s ease, width 0.2s ease",overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis"},children:[e&&Kr(Of,{color:"secondary",size:14,sx:{position:"absolute",top:"22%",left:"44%",transform:"translate(-50%, -50%)"}}),o]})})})}import{GridActionsCellItem as Iw}from"@mui/x-data-grid";import{jsx as Lf}from"react/jsx-runtime";function Cl(t){let{event:e,onClick:r,...o}=t;return Lf(Iw,{label:"A\xE7\xE3o",onClick:()=>{},icon:Lf("span",{children:"\u{1F527}"})})}import{Delete as Aw}from"@mui/icons-material";import{GridActionsCellItem as Ew}from"@mui/x-data-grid";import{jsx as $f}from"react/jsx-runtime";function wl({onClick:t,...e}){return $f(Ew,{icon:$f(Aw,{}),label:"Delete",color:"primary",onClick:()=>{t&&t("delete")},...e})}import{Edit as Fw}from"@mui/icons-material";import{GridActionsCellItem as Mw}from"@mui/x-data-grid";import{jsx as zf}from"react/jsx-runtime";function Sl({onClick:t,...e}){return zf(Mw,{icon:zf(Fw,{}),label:"Edit",color:"primary",onClick:()=>t&&t("edit"),...e})}import{Children as Rw,cloneElement as Dw,isValidElement as Ow}from"react";import{Fragment as Bw,jsx as Lw}from"react/jsx-runtime";function Tl(t){let{children:e,onClick:r}=t;return Lw(Bw,{children:Rw.map(e,o=>{if(Ow(o))return Dw(o,{onClick:r})})})}import{GetApp as $w}from"@mui/icons-material";import{GridActionsCellItem as zw}from"@mui/x-data-grid";import{jsx as _f}from"react/jsx-runtime";function Pl({onClick:t,...e}){return _f(zw,{icon:_f($w,{}),label:"Transport",color:"primary",onClick:()=>t&&t("transport"),...e})}import{Stack as _w}from"@mui/material";import{jsx as Nw}from"react/jsx-runtime";function kl(t){return Nw(_w,{direction:"row",width:"100%",flexGrow:1,alignItems:"center",gap:1.5,sx:{background:"#f4f"},...t})}import{FileDownload as Vw}from"@mui/icons-material";import{gridFilteredSortedRowIdsSelector as Ww}from"@mui/x-data-grid";import{jsx as Nf}from"react/jsx-runtime";var Hw=({apiRef:t})=>Ww(t);function Il(){let{apiRef:t}=Ge(),e=r=>{t?.current&&t.current.exportDataAsCsv(r)};return Nf(Zr,{startIcon:Nf(Vw,{}),onClick:()=>e({getRowsToExport:Hw}),children:"Exportar CSV"})}import{TableFooter as Gw}from"@mui/material";import{jsx as jw}from"react/jsx-runtime";function Al(t){return jw(Gw,{...t,sx:{height:"54px",paddingX:"12px",gap:"12px",display:"flex",alignItems:"center",backgroundColor:"white",borderBottomLeftRadius:"8px",borderBottomRightRadius:"8px",borderTop:"1px solid #edf2f9"}})}import{useMemo as Vf}from"react";import{TextField as Uw,Pagination as qw,MenuItem as Yw,Stack as Wf,Typography as Kw}from"@mui/material";import{pluralizar as Hf}from"@data-c/hooks";import{jsx as Gn,jsxs as Gf}from"react/jsx-runtime";function El(t){let{onChangePageSize:e,onChangePage:r,pagination:o,rowsPerPageOptions:n=[15,50,100,200]}=t,{page:a,pageSize:i=15,totalRecords:l}=o||{},s=Vf(()=>o?.lastPage?o.lastPage:(l||0)<i?1:Math.max(Math.ceil((l||0)/i)),[l,i]),u=Vf(()=>{if((l||0)<i)return`Exibindo ${Hf(l||0,"registro","registros",!0)}`;let d=i;if(a===s){let f=(l||0)%i;d=f===0?i:f}return`Exibindo ${Hf(d||0,"registro","registros",!0)} de ${l}`},[o,s]);return Gf(Wf,{width:"100%",direction:"row",alignItems:"center",gap:2,marginLeft:"auto",children:[Gn(Kw,{variant:"body2",fontSize:"13px",fontWeight:"500",whiteSpace:"nowrap",children:u}),!0&&Gf(Wf,{direction:"row",alignItems:"center",gap:2,marginLeft:"auto",children:[Gn(Uw,{sx:{width:"78px",fontSize:"8pt"},size:"small",value:i||0,select:!0,onChange:d=>{e&&e(parseInt(d.target.value))},children:n.map(d=>Gn(Yw,{value:d,children:d},d))}),Gn(qw,{variant:"outlined",shape:"rounded",count:s||0,showFirstButton:!0,showLastButton:!0,onChange:(d,f)=>{r&&r(f)},page:a||0,color:"primary"})]})]})}import{useEffect as Zw,useRef as Qw,useState as Jw}from"react";import{Stack as Xw}from"@mui/material";import{jsx as jf}from"react/jsx-runtime";function Fl({children:t,height:e,...r}){let o=Qw(null),[n,a]=Jw(500);return Zw(()=>{let i=()=>{let l=o.current;if(!l)return;let s=l.getBoundingClientRect().top;a(window.innerHeight-s)};return i(),window.addEventListener("resize",i),()=>{window.removeEventListener("resize",i)}},[]),jf(Xw,{ref:o,sx:{backgroundColor:"#f4f6fa",border:"1px solid #edf2f9",borderRadius:2,height:e||`calc(${n}px - 16px)`,...r.sx},...r,children:jf(ml,{children:t})})}import{Stack as eS,Typography as tS}from"@mui/material";import{useMemo as rS}from"react";import{jsx as nS,jsxs as oS}from"react/jsx-runtime";function Ml(t){let{countTitle:e,gender:r}=t,{rowsSelectedId:o}=Ge(),n=o?.ids.size||0,a=rS(()=>{if(!e)return"";let i=r==="feminino"?"selecionada":"selecionado",l=r==="feminino"?"selecionadas":"selecionados",s=r==="feminino"?"Nenhuma":"Nenhum";return n===1?`${e} ${i}`:n&&n>1?`${e.split(" ").map(u=>`${u}s`).join(" ")} ${l}`:`${s} ${e} ${i}`},[n]);return nS(eS,{children:oS(tS,{variant:"body2",fontSize:"13px",fontWeight:"500",whiteSpace:"nowrap",children:[n&&n>0?n:""," ",a]})})}import{Typography as iS,useTheme as aS}from"@mui/material";import{jsx as sS}from"react/jsx-runtime";function Rl({children:t,titleDivider:e=!1,sx:r}){let o=aS();return sS(iS,{variant:"h6",whiteSpace:"nowrap",sx:{borderRight:e?`solid 1px ${o.palette.grey[300]}`:"none",paddingRight:1.5,...r},children:t})}import{Paper as lS,Stack as uS}from"@mui/material";import{jsx as cS}from"react/jsx-runtime";function Dl({children:t}){return cS(uS,{component:lS,elevation:0,gap:1.5,flexDirection:"row",justifyContent:"space-between",alignItems:"center",p:1,borderRadius:"8px 8px 0 0",sx:{width:"100%"},children:t})}var dS={CellActionTransport:Pl,SelectionCounter:Ml,CellActionDelete:wl,ExportCsvButton:Il,CellActionEdit:Sl,CellActions:Tl,CellAction:Cl,Pagination:El,Actions:vl,Toolbar:Dl,Content:kl,Button:Zr,Footer:Al,Table:hl,Title:Rl,Root:Fl,Action:gl,ActionEdit:bl,ActionDelete:yl,ActionTransport:xl,ColumnsPanelTrigger:pS,useGridApiRef:fS},mS=dS;import{Stack as hS}from"@mui/material";import{jsx as gS}from"react/jsx-runtime";function Ol(t){return gS(hS,{gap:.5,overflow:"hidden",...t})}import{Stack as yS}from"@mui/material";import{jsx as bS}from"react/jsx-runtime";function Bl(t){return bS(yS,{sx:[{overflowY:"auto",overflowX:"hidden"},...Array.isArray(t.sx)?t.sx:t.sx?[t.sx]:[]],...t})}import{MenuItem as vS}from"@mui/material";import{jsx as xS}from"react/jsx-runtime";function Ll(t){return xS(vS,{...t})}var CS={Root:Ol,Content:Bl,Item:Ll},Qr=CS;import{createContext as wS,useCallback as Uf,useContext as SS,useEffect as TS,useState as qf}from"react";import{jsx as PS}from"react/jsx-runtime";var Yf=wS(void 0),Kf=({children:t,open:e,onOpenChange:r})=>{let[o,n]=qf(!1),[a,i]=qf(null),l=Uf(u=>{i(u),n(!0),r?.(!0)},[]),s=Uf(()=>{n(!1),i(null),r?.(!1)},[]);return TS(()=>{n(!!e)},[e]),PS(Yf.Provider,{value:{isOpen:o,open:l,close:s,anchorEl:a,setAnchorEl:i},children:t})},br=()=>{let t=SS(Yf);if(!t)throw new Error("usePopover must be used within a PopoverProvider");return t};import{jsx as kS}from"react/jsx-runtime";function $l(t){let{children:e,open:r,onOpenChange:o}=t;return kS(Kf,{open:r,onOpenChange:o,children:e})}import{Button as IS}from"@mui/material";import{Slot as AS}from"@radix-ui/react-slot";import{jsx as ES}from"react/jsx-runtime";function zl(t){let{asChild:e=!1,...r}=t,o=e?AS:IS,{open:n}=br();return ES(o,{onClick:a=>{n(a.currentTarget)},...r})}import{Button as FS}from"@mui/material";import{Slot as MS}from"@radix-ui/react-slot";import{jsx as RS}from"react/jsx-runtime";function _l(t){let{asChild:e=!1,...r}=t,o=e?MS:FS,{close:n}=br();return RS(o,{onClick:a=>{n()},...r})}import{Popover as DS}from"@mui/material";import{jsx as OS}from"react/jsx-runtime";function Nl(t){let{isOpen:e,close:r,anchorEl:o}=br();return OS(DS,{open:e,anchorEl:o,onClose:r,anchorOrigin:{vertical:"bottom",horizontal:"center"},slotProps:{paper:{sx:{borderRadius:"12px"}}},transformOrigin:{vertical:"top",horizontal:"center"},...t,children:t.children})}var BS={Root:$l,Trigger:zl,Content:Nl,Close:_l},vr=BS;import{Button as LS,ButtonGroup as $S,ClickAwayListener as zS,Grow as _S,MenuList as NS,MenuItem as VS,Paper as WS,Popper as HS}from"@mui/material";import Zf,{Children as GS,useEffect as Qf,useRef as jS,useState as Jf}from"react";import{jsx as pt,jsxs as ed}from"react/jsx-runtime";var Xf="mio-componente:button-group:value";function Vl(t){let{children:e,value:r,onChange:o,isLoading:n,disableMemory:a}=t,[i,l]=Jf(!1),[s,u]=Jf(()=>{if(!a)return window.localStorage.getItem(Xf)||r||0;if(r)return r}),c=jS(null);Qf(()=>{u(r===void 0?0:r)},[r]),Qf(()=>{window.localStorage.setItem(Xf,s||0),u(s)},[s]);let d=[],f=GS.map(e,(m,h)=>{d.push({label:m.props.children,value:m.props?.value||h});let p=Zf.cloneElement(m,{isLoading:n,sx:{maxWidth:"300px",width:"120px"},value:m.props?.value||h});return!s&&h===0||s&&Number(p.props.value)===Number(s)?p:null});return ed(Zf.Fragment,{children:[ed($S,{variant:"contained",size:"small",ref:c,children:[f,pt(LS,{disabled:n,"data-allow-click":"true",onClick:()=>{l(m=>!m)},sx:{width:"30px"},children:pt(Nr,{sx:{fontSize:"13pt"}})})]}),pt(HS,{open:i,transition:!0,anchorEl:c.current,sx:{zIndex:999999},placement:"bottom-end",children:({TransitionProps:m})=>pt(_S,{...m,children:pt(WS,{sx:{minWidth:"120px"},children:pt(zS,{onClickAway:()=>l(!1),children:pt(NS,{autoFocusItem:!0,disablePadding:!0,children:d.map(h=>pt(VS,{onClick:()=>{o?o(h.value):u(h.value),l(!1)},children:h.label},h.value))})})})})})]})}import{jsx as US}from"react/jsx-runtime";function Wl(t){return US(D,{...t})}var qS={Root:Vl,Button:Wl},YS=qS;import{Box as KS}from"@mui/material";import{jsx as ZS}from"react/jsx-runtime";function Hl(t){let{children:e,sx:r,...o}=t;return ZS(KS,{sx:{position:"relative",border:n=>`1px solid ${n.palette.divider} `,boxShadow:n=>`1px 2px 4px ${n.palette.divider}`,borderRadius:2,...r},...o,children:e})}import{Box as QS,Stack as JS}from"@mui/material";import td from"react";import{jsx as rd}from"react/jsx-runtime";function Gl(t){let{children:e}=t,r=td.Children.toArray(e).map(o=>td.isValidElement(o)&&rd(QS,{sx:{},children:o}));return rd(JS,{sx:{backgroundColor:o=>o.palette.background.paper,borderBottom:o=>`solid 1px ${o.palette.divider}`,height:"30px",pl:1,pr:1},direction:"row",alignItems:"center",justifyContent:"space-between",children:e})}import{Typography as XS}from"@mui/material";import{jsx as e2}from"react/jsx-runtime";function jl(t){let{title:e}=t;return e2(XS,{component:"h6",variant:"h6",children:e})}import{Stack as t2}from"@mui/material";import{jsx as r2}from"react/jsx-runtime";function Ul(t){let{children:e,...r}=t;return r2(t2,{...r,sx:{p:1,...r.sx},children:e})}var o2={Root:Hl,Content:Ul,Header:Gl,Title:jl},n2=o2;import*as i2 from"lucide-react";import{jsx as l2}from"react/jsx-runtime";var a2=({name:t,size:e=16,strokeWidth:r=1.5,color:o="currentColor",...n})=>{let a=i2[t];return l2(a,{size:e,strokeWidth:r,color:o,...n})},s2=a2;import{Typography as u2,useTheme as c2}from"@mui/material";import{jsx as f2}from"react/jsx-runtime";function p2(t,e){switch(e){case"title1":return{fontSize:"2rem",color:t.palette.primary.main,fontWeight:700};case"title2":return{fontSize:"1.25rem",color:t.palette.text.secondary,fontWeight:500};case"title3":return{fontSize:"0.850rem",color:t.palette.grey[600],fontWeight:700};default:return{}}}function jn({children:t,variant:e="title1",sx:r,...o}){let n=c2();return f2(u2,{sx:{...p2(n,e),...r},...o,children:t})}import{Box as d2}from"@mui/material";import{jsx as m2}from"react/jsx-runtime";function ql(t){return m2(d2,{mt:2,sx:{display:"flex",flexDirection:"column",flexGrow:1},...t})}import{Stack as h2}from"@mui/material";import{jsx as g2}from"react/jsx-runtime";function Yl(t){let{children:e,...r}=t;return g2(h2,{direction:"row",alignContent:"center",alignItems:"center",justifyContent:"space-between",spacing:1,...r,children:e})}import{Container as y2}from"@mui/material";import{jsx as b2}from"react/jsx-runtime";function Kl(t){return b2(y2,{sx:{padding:1,inset:0,overflow:"auto"},...t})}import{jsx as v2}from"react/jsx-runtime";function Zl({title:t,...e}){return v2(jn,{variant:"title3",...e,children:t})}var x2={Root:Kl,Header:Yl,Title:Zl,Content:ql},C2=x2;import{CircularProgress as id,IconButton as od,Autocomplete as w2,Stack as ad,TextField as S2,Typography as T2}from"@mui/material";import P2 from"lodash";import nd,{useCallback as k2}from"react";import{jsx as Je,jsxs as A2}from"react/jsx-runtime";function I2(){return A2(ad,{direction:"row",spacing:1,alignContent:"center",alignItems:"center",children:[Je(id,{size:16}),Je(T2,{variant:"body1",children:"Carregando..."})]})}function Un(t){let{value:e,onChange:r,onSearchChange:o,onDoubleClick:n,options:a,isLoading:i,renderValue:l,required:s,readonly:u,multiple:c,disableCloseOnSelect:d,endAdornment:f,disabled:m,filterOptions:h,renderOption:p,...y}=t;function v(C,k=!1,P=!1){if(C){let Q=nd.Children.toArray(C.props?.children),z=Q.length===1?0:1;return Q.splice(z,0,Je(od,{sx:{padding:"2px"},size:"small",color:"default",onClick:()=>{},disabled:P,children:"'s'"})),f&&Q.unshift(f),k&&Q.unshift(Je(od,{disabled:!0,children:Je(id,{color:"primary",size:18})})),Je(ad,{direction:"row",spacing:2,children:nd.cloneElement(C,{},Q)})}return C}let b=P2.debounce((C,k)=>{k!=="selectOption"&&o&&o(C,k)},500),S=k2((C,k,P)=>{b(k,P)},[b]);function w(C){r&&r(C)}return Je(w2,{onDoubleClick:()=>{n&&n()},multiple:c,loading:i,loadingText:Je(I2,{}),value:e,onChange:(C,k)=>w(k),options:a,onInputChange:S,getOptionLabel:l,readOnly:u,disabled:m,disableCloseOnSelect:d,filterOptions:h,renderOption:p,renderInput:C=>Je(S2,{slotProps:{inputLabel:{shrink:!0},input:{...C.InputProps,startAdornment:f}},...C,required:s,fullWidth:!0,disabled:m,...y}),noOptionsText:"Digite algo para pesquisar"})}import cd,{isValidElement as D2}from"react";import{createContext as E2,useContext as F2}from"react";var sd=E2(void 0),qn=()=>{let t=F2(sd);if(!t)throw new Error("useTransporterScope must be used inside <Transporter.Root />");return t},ld=sd.Provider;import{createStore as M2,useStore as R2}from"zustand";var Yn=new Map;function ud(t){if(Yn.has(t))return Yn.get(t);let e=M2((r,o)=>({isOpen:!1,query:void 0,setQuery:n=>r({query:n}),setValue:n=>r({value:n}),openTransporter:()=>r({isOpen:!0}),closeTransporter:async n=>{if(r({isOpen:!1}),n)if(Array.isArray(o().value)){if(typeof n!="string"&&typeof n!="number"){let s=o().value,c=s.includes(n)?s.filter(d=>d!==n):[...s,n];o().triggerOnChange(c);return}let a=o().value,l=a.find(s=>s?.id===n.id)?a.filter(s=>s!==n):[...a,n];o().triggerOnChange(l)}else o().triggerOnChange(n)},onChange:void 0,setOnChange:n=>r({onChange:n}),triggerOnChange:n=>{o().onChange?.(n)}}));return Yn.set(t,e),e}function Jr(t){let e=Yn.get(t);if(!e)throw new Error(`No transporter store found for id "${t}"`);return R2(e)}import{jsx as Ql,jsxs as pd}from"react/jsx-runtime";function Jl(t){let{children:e,title:r}=t,o=qn(),{isOpen:n,closeTransporter:a}=Jr(o);if(!n)return null;let i=cd.Children.map(e,l=>{if(D2(l))return cd.cloneElement(l,{displayTransportAction:!0,onTransport:s=>{a(s)}});throw new Error("Tipo inv\xE1lido para DataTable")});return pd(O.Root,{open:n,onClose:a,fullWidth:!0,maxWidth:"lg",children:[pd(O.Header,{children:[Ql(O.Title,{children:r||"Caixa de Busca Avan\xE7ada"}),Ql(O.ActionClose,{onClose:a})]}),Ql(O.Content,{children:i})]})}import{useEffect as O2}from"react";import{jsx as B2}from"react/jsx-runtime";function Xl(t){let{scope:e,onChange:r,value:o,children:n}=t,a=ud(e);return a.getState().setValue(o),O2(()=>(a.getState().setOnChange(r),()=>{a.getState().setOnChange(void 0)}),[e,r]),B2(ld,{value:e,children:n})}import{jsx as L2}from"react/jsx-runtime";function eu(t){let{disableLocalFiltering:e,renderOption:r,...o}=t,n=qn(),{openTransporter:a,triggerOnChange:i,value:l}=Jr(n);return L2(Un,{onDoubleClick:()=>a(),value:l,onChange:s=>{i(s)},...e&&{filterOptions:s=>s},renderOption:r,...o})}var $2={Root:Xl,TextField:eu,Container:Jl};var z2=$2;import{TextField as _2}from"@mui/material";import{jsx as N2}from"react/jsx-runtime";function Se(t){return N2(_2,{...t,slotProps:{input:{readOnly:t.readonly,...t.slotProps?.input},...t.slotProps}})}import{useMemo as V2,useState as W2}from"react";import{jsx as G2}from"react/jsx-runtime";var Kn=t=>t.replace(/\D/g,""),fd=t=>{let e=Kn(t).slice(0,11);return e.length<=3?e:e.length<=6?`${e.slice(0,3)}.${e.slice(3)}`:e.length<=9?`${e.slice(0,3)}.${e.slice(3,6)}.${e.slice(6)}`:`${e.slice(0,3)}.${e.slice(3,6)}.${e.slice(6,9)}-${e.slice(9)}`},dd=t=>{let e=Kn(t).slice(0,14);return e.length<=2?e:e.length<=5?`${e.slice(0,2)}.${e.slice(2)}`:e.length<=8?`${e.slice(0,2)}.${e.slice(2,5)}.${e.slice(5)}`:e.length<=12?`${e.slice(0,2)}.${e.slice(2,5)}.${e.slice(5,8)}/${e.slice(8)}`:`${e.slice(0,2)}.${e.slice(2,5)}.${e.slice(5,8)}/${e.slice(8,12)}-${e.slice(12)}`},md=(t,e)=>{let r=Kn(t);return e==="cpf"?fd(r):e==="cnpj"?dd(r):r.length<=11?fd(r):dd(r)},H2=(t,e)=>t==="cpf"?14:18;function hd(t){let{value:e,onChange:r,tipoDocumento:o="auto",slotProps:n,...a}=t,[i,l]=W2(""),s=e!==void 0,u=V2(()=>s?md(e||"",o):i,[e,i,s,o]),c=f=>{let m=f.target.value,h=md(m,o);if(s||l(h),r){let p=Kn(m);f.target.value=p,r(f)}},d=H2(o,e||i);return G2(Se,{value:u,onChange:c,slotProps:{htmlInput:{maxLength:d,...n?.htmlInput},...n},placeholder:o==="cnpj"?"99.999.999/9999-99":o==="cpf"?"999.999.999-99":"CPF (999.999.999-99) ou CNPJ (99.999.999/9999-99)",...a})}import{useMemo as j2,useState as U2}from"react";import{jsx as q2}from"react/jsx-runtime";var yd=t=>t.replace(/\D/g,""),gd=t=>{let e=yd(t).slice(0,8);return e.length<=5?e:`${e.slice(0,5)}-${e.slice(5)}`};function bd(t){let{value:e,onChange:r,slotProps:o,...n}=t,[a,i]=U2(""),l=e!==void 0,s=j2(()=>l?gd(e||""):a,[e,a,l]);return q2(Se,{value:s,onChange:c=>{let d=c.target.value,f=gd(d);if(l||i(f),r){let m=yd(d);c.target.value=m,r(c)}},slotProps:{htmlInput:{maxLength:9,...o?.htmlInput},...o},placeholder:"99999-999",...n})}import{useMemo as Y2,useState as K2}from"react";import{jsx as Q2}from"react/jsx-runtime";var Zn=t=>t.replace(/\D/g,""),tu=(t,e)=>{let r=Zn(t);if(e){let o=r.slice(0,2),n=r.slice(2,4),a=r.slice(4,8),i=r.slice(8,12);return r.length<=2?`+${o}`:r.length<=4?`+${o} (${n}`:r.length<=8?`+${o} (${n}) ${a}`:`+${o} (${n}) ${a}-${i}`}else{let o=r.slice(0,10);return o.length<=2?`(${o}`:o.length<=6?`(${o.slice(0,2)}) ${o.slice(2)}`:`(${o.slice(0,2)}) ${o.slice(2,6)}-${o.slice(6)}`}},ru=(t,e)=>{let r=Zn(t).slice(0,e?15:11);if(e){let o=r.slice(0,2),n=r.slice(2,4),a=r.slice(4,9),i=r.slice(9,13),l=r.slice(13);return r.length<=2?`+${o}`:r.length<=4?`+${o} (${n}`:r.length<=9?`+${o} (${n}) ${a}`:r.length<=13?`+${o} (${n}) ${a}-${i}`:`+${o} (${n}) ${a}-${i}${l}`}else{let o=r.slice(0,11);return o.length<=2?`(${o}`:o.length<=7?`(${o.slice(0,2)}) ${o.slice(2)}`:`(${o.slice(0,2)}) ${o.slice(2,7)}-${o.slice(7)}`}},vd=(t,e,r)=>{let o=Zn(t);return e==="fixed"?tu(o,r):e==="mobile"?ru(o,r):r?o.length>12?ru(o,r):tu(o,r):o.length>10?ru(o,r):tu(o,r)},Z2=(t,e)=>e?19:t==="fixed"?14:15;function xd(t){let{value:e,onChange:r,tipoTelefone:o="auto",allowDDI:n=!1,inputProps:a,...i}=t,[l,s]=K2(""),u=e!==void 0,c=Y2(()=>u?vd(e||"",o,n):l,[e,l,u,o,n]),d=m=>{let h=m.target.value,p=vd(h,o,n);if(u||s(p),r){let y=Zn(h);m.target.value=y,r(m)}},f=Z2(o,n);return Q2(Se,{value:c,onChange:d,inputProps:{maxLength:f,...a},placeholder:n?o==="mobile"?"+99 (99) 99999-9999":o==="fixed"?"+99 (99) 9999-9999":"+99 (99) 9999-9999 ou +99 (99) 99999-9999":o==="mobile"?"(99) 99999-9999":o==="fixed"?"(99) 9999-9999":"(99) 9999-9999 ou (99) 99999-9999",...i})}import{Alert as Cd,CircularProgress as nT,Dialog as iT,DialogContent as aT,DialogTitle as sT}from"@mui/material";import lT from"axios";import{useEffect as wd,useState as Xr}from"react";import{Collapse as J2,Stack as X2,Typography as eT}from"@mui/material";import{useState as tT}from"react";import{Fragment as rT,jsx as Qn,jsxs as oT}from"react/jsx-runtime";function ou(t){let{article:e,isOpen:r}=t,[o,n]=tT(!!r);return oT(rT,{children:[Qn(X2,{onClick:()=>n(!o),sx:{p:.5,":hover":{borderRadius:"4px",backgroundColor:a=>a.palette.grey[200],cursor:"pointer"}},children:Qn(eT,{variant:"subtitle1",children:e.title})}),Qn(J2,{in:o,sx:{pl:1,pr:1},children:Qn("div",{dangerouslySetInnerHTML:{__html:e?.body?.replace('width="560"','width="412px"').replace('height="315"','height="240px"').replace("h2","h3")||""}})})]})}import{Fragment as uT,jsx as Jn,jsxs as eo}from"react/jsx-runtime";function Sd(t){let{sectionId:e,versao:r,authorization:o,notificarNovaVersao:n=!1,localStoragePath:a}=t,[i,l]=Xr(void 0),[s,u]=Xr(!1),[c,d]=Xr(!1),[f,m]=Xr(!1),[h,p]=Xr(!1);return wd(()=>{if(n&&a){let y=JSON.parse(localStorage.getItem(a)||"[]");y.includes(r)||(m(!0),p(!0),localStorage.setItem(a,JSON.stringify([...y,r])))}},[n,a,r]),wd(()=>{async function y(){u(!0);try{let v=localStorage.getItem(e);if(v){let w=JSON.parse(v);if(new Date().getTime()-w.timestamp<10*60*1e3){l(w.article),u(!1);return}}let b=o?{Authorization:`Bearer ${o}`}:{},S=await lT.get(`https://datacsistemashelp.zendesk.com/api/v2/help_center/pt-br/sections/${e}/articles`,{headers:b,params:{sort_by:"created_at",sort_order:"desc"}});l(S.data.articles)}catch{d("Ocorreu um erro ao obter as notas de vers\xE3o")}finally{u(!1)}}e&&f&&y()},[e,f]),eo(uT,{children:[Jn(D,{onClick:y=>{y.preventDefault(),m(!0)},sx:{fontSize:"0.7rem",minWidth:0,pt:0,pb:0,pl:.5,pr:.5,color:y=>y.palette.grey[500]},variant:"text",children:r}),eo(iT,{fullWidth:!0,maxWidth:"md",scroll:"paper",open:f,onClose:()=>m(!1),children:[eo(sT,{children:["Notas de Vers\xE3o"," ",s&&Jn(nT,{sx:{ml:1},size:14})]}),eo(aT,{children:[h&&eo(Cd,{severity:"info",sx:{mb:2},children:["Uma nova vers\xE3o (",r,") est\xE1 dispon\xEDvel!"]}),c&&Jn(Cd,{severity:"error",children:"N\xE3o foi poss\xEDvel carregar o conte\xFAdo"}),i?.map((y,v)=>Jn(ou,{isOpen:v===0,article:y},y.id))]})]})]})}import{DatePicker as cT}from"@mui/x-date-pickers";import{DateTime as pT}from"luxon";import{jsx as fT}from"react/jsx-runtime";function _t(t){let{value:e,error:r,onChange:o,fromFormat:n,format:a,...i}=t;function l(s){if(s?.isValid){o(s?.toFormat("yyyy-MM-dd"));return}if(s===null){o(null);return}}return fT(cT,{format:a||"dd/MM/yyyy",value:pT.fromFormat(e||"",n||"yyyy-MM-dd"),onChange:s=>l(s),slotProps:{textField:{error:!!r}},...i})}import{LocalizationProvider as dT}from"@mui/x-date-pickers";import{AdapterLuxon as mT}from"@mui/x-date-pickers/AdapterLuxon";import{jsx as hT}from"react/jsx-runtime";function Td({children:t}){return hT(dT,{dateAdapter:mT,adapterLocale:"pt-br",children:t})}import{IconButton as Xn,InputAdornment as Pd,MenuItem as Me,Stack as ei,styled as gT}from"@mui/material";import{ArrowLeftIcon as kd,ArrowRightIcon as Id,PickersDay as yT}from"@mui/x-date-pickers";import{DateTime as Te}from"luxon";import{useEffect as bT,useMemo as Md,useState as Ad}from"react";import{jsx as q,jsxs as Xe}from"react/jsx-runtime";var vT=gT(yT,{shouldForwardProp:t=>t!=="isSelected"&&t!=="isHovered"})(({theme:t,isSelected:e,isHovered:r,isToday:o,day:n})=>()=>({borderRadius:0,"& .MuiPickersDay-today":{backgroundColor:"#f52",borderRadius:"50%"},...o&&!r&&!e&&{borderRadius:"50%","& .MuiPickersDay-today":{padding:"0px"}},...e&&{backgroundColor:t.palette.primary.main,color:t.palette.primary.contrastText,"&:hover, &:focus":{backgroundColor:t.palette.primary.main}},...r&&{backgroundColor:t.palette.primary[t.palette.mode],"&:hover, &:focus":{backgroundColor:t.palette.primary[t.palette.mode]}},...n.weekday===1&&{borderTopLeftRadius:"50%",borderBottomLeftRadius:"50%"},...n.weekday===7&&{borderTopRightRadius:"50%",borderBottomRightRadius:"50%"}})),Ed=(t,e)=>e==null?!1:t.weekNumber===e.weekNumber;function Fd(t){let{day:e,selectedDay:r,hoveredDay:o,...n}=t,a=Md(()=>e.day===Te.now().day,[]);return q(vT,{...n,day:e,isToday:a,sx:{px:2.5},disableMargin:!0,selected:!1,isSelected:Ed(e,r),isHovered:Ed(e,o)})}function nu(t){let{value:e,onChange:r,renderFieldSet:o}=t,[n,a]=Ad(null),[i,l]=Ad({tipo:"month",firstDate:null,secondDate:null});bT(()=>{e&&l(e)},[e]);function s(){let y=(i.firstDate?Te.fromFormat(i.firstDate,"yyyy-MM-dd"):Te.now().startOf("day")).minus({[i.tipo]:1});d(i.tipo,y.toFormat("yyyy-MM-dd"))}function u(){let y=(i.firstDate?Te.fromFormat(i.firstDate,"yyyy-MM-dd"):Te.now().startOf("day")).plus({[i.tipo]:1});d(i.tipo,y.toFormat("yyyy-MM-dd"))}function c(p,y,v){let b=y.startOf(v).toFormat("yyyy-MM-dd"),S=y.endOf(v).toFormat("yyyy-MM-dd"),w={tipo:p,firstDate:b,secondDate:S};l(w),r&&r(w)}function d(p,y){if(p==="livre"){l({...i,tipo:"livre"}),r&&r({...i,tipo:"livre"});return}let v=y?Te.fromFormat(y,"yyyy-MM-dd"):Te.now();p==="month"&&c(p,v,"month"),p==="day"&&c(p,v,"day"),p==="week"&&c(p,v,"week"),p==="quarter"&&c(p,v,"quarter"),p==="year"&&c(p,v,"year")}function f(p){if(i.tipo==="livre"&&p){let y={...i,firstDate:p};l(y),r&&r(y);return}p&&d(i.tipo,p)}function m(p){if(i.tipo==="livre"&&p){let y={...i,secondDate:p};l(y),r&&r(y);return}p&&d(i.tipo,p)}let h=Md(()=>{if(i.tipo==="month"||i.tipo==="quarter")return["month"];if(i.tipo==="day")return["day"];if(i.tipo==="year")return["year"]},[i.tipo]);return o?Xe("fieldset",{style:{border:"1px solid #cfcfcf",borderRadius:"4px"},children:[q("legend",{style:{color:"#808080",fontSize:"0.7rem",paddingLeft:"4px",paddingRight:"8px"},children:"Per\xEDodo"}),Xe(ei,{spacing:2,children:[Xe(Se,{value:i.tipo,onChange:p=>{let y=p.target.value;d(y,i?.firstDate||null)},select:!0,fullWidth:!0,size:"small",variant:"outlined",InputProps:{startAdornment:i?.tipo!=="livre"&&Xe(Pd,{position:"start",children:[q(Xn,{size:"small",onClick:s,children:q(kd,{fontSize:"small"})}),q(Xn,{size:"small",onClick:u,children:q(Id,{fontSize:"small"})})]})},children:[q(Me,{value:"livre",children:"Livre"}),q(Me,{value:"month",children:"Mensal"}),q(Me,{value:"day",children:"Di\xE1rio"}),q(Me,{value:"week",children:"Semanal"}),q(Me,{value:"quarter",children:"Trimestral"}),q(Me,{value:"year",children:"Anual"})]}),Xe(ei,{direction:"row",spacing:1,children:[q(_t,{label:"In\xEDcio",onChange:f,value:i.firstDate,showDaysOutsideCurrentMonth:!0,slots:i.tipo==="week"?{day:Fd}:void 0,slotProps:i.tipo==="week"?{day:p=>({selectedDay:i?.firstDate?Te.fromFormat(i.firstDate,"yyyy-MM-dd").startOf("week"):Te.now(),hoveredDay:n,onPointerEnter:()=>a(p.day),onPointerLeave:()=>a(null)})}:void 0,views:h}),i.tipo!=="day"&&q(_t,{disabled:i.tipo!=="livre"||!i?.firstDate,minDate:i?.firstDate?Te.fromFormat(i.firstDate,"yyyy-MM-dd"):void 0,showDaysOutsideCurrentMonth:!0,label:"Fim",onChange:m,value:i.secondDate})]})]})]}):Xe(ei,{spacing:2,children:[Xe(Se,{value:i.tipo,onChange:p=>{let y=p.target.value;d(y,i?.firstDate||null)},select:!0,fullWidth:!0,size:"small",variant:"outlined",InputProps:{startAdornment:i?.tipo!=="livre"&&Xe(Pd,{position:"start",children:[q(Xn,{size:"small",onClick:s,children:q(kd,{fontSize:"small"})}),q(Xn,{size:"small",onClick:u,children:q(Id,{fontSize:"small"})})]})},children:[q(Me,{value:"livre",children:"Livre"}),q(Me,{value:"month",children:"Mensal"}),q(Me,{value:"day",children:"Di\xE1rio"}),q(Me,{value:"week",children:"Semanal"}),q(Me,{value:"quarter",children:"Trimestral"}),q(Me,{value:"year",children:"Anual"})]}),Xe(ei,{direction:"row",spacing:1,children:[q(_t,{label:"In\xEDcio",onChange:f,value:i.firstDate,showDaysOutsideCurrentMonth:!0,slots:i.tipo==="week"?{day:Fd}:void 0,slotProps:i.tipo==="week"?{day:p=>({selectedDay:i?.firstDate?Te.fromFormat(i.firstDate,"yyyy-MM-dd").startOf("week"):Te.now(),hoveredDay:n,onPointerEnter:()=>a(p.day),onPointerLeave:()=>a(null)})}:void 0,views:h}),i.tipo!=="day"&&q(_t,{disabled:i.tipo!=="livre"||!i?.firstDate,minDate:i?.firstDate?Te.fromFormat(i.firstDate,"yyyy-MM-dd"):void 0,showDaysOutsideCurrentMonth:!0,label:"Fim",onChange:p=>{l({...i,secondDate:p})},value:i.secondDate})]})]})}nu.defaultProps={renderFieldSet:!0};import{formatCurrency as xT,isValidNumber as CT}from"@data-c/hooks";import{forwardRef as wT,useCallback as Rd}from"react";import{jsx as TT}from"react/jsx-runtime";function iu(t){if(!t)return 0;let e=String(t);return e=e.replace(/\./g,"").replace(/,/g,"."),parseFloat(e)}var au=null,ti=!1,Dd=wT((t,e)=>{let{value:r,onChange:o,sx:n,...a}=t;au=null;let i=Rd(s=>{let u=s.target.value||"0.00";CT(u)&&(au==="Backspace"?u=(iu(u)/10).toFixed(2):ti?(u=(iu(u)/100).toFixed(2),ti=!1):u=(iu(u)*10).toFixed(2),o&&(s.target.value=u,o(s,u)))},[o]),l=Rd(s=>{s.target.selectionStart===s.target.selectionEnd&&(s.target.selectionStart=s.target.value.length,s.target.selectionEnd=s.target.value.length)},[]);return TT(Se,{onKeyDown:s=>{au=s.key},onSelect:s=>{let u=s.target;u.selectionStart===0&&u.selectionEnd===u.value.length?ti=!0:ti=!1,l(s)},onChange:i,value:xT(String(r),2)||"",inputRef:e,sx:{"& .MuiInputBase-input":{textAlign:"right"},...n},...a})});Dd.defaultProps={value:0};var ST=Dd;import{Button as PT,Stack as Ld,Typography as ri}from"@mui/material";import{ArrowDropDown as kT}from"@mui/icons-material";import{useState as IT}from"react";import{jsx as $e,jsxs as to}from"react/jsx-runtime";function $d(t){let{licencas:e,licencaSelecionada:r,onAlterarLicenca:o}=t,[n,a]=IT("");if(e.length===0)return to(Ld,{overflow:"hidden",children:[$e(ri,{overflow:"hidden",textOverflow:"ellipsis",variant:"body1",children:r.nome}),$e(ri,{overflow:"hidden",textOverflow:"ellipsis",variant:"body2",children:Od(r.documento)})]});function i(s){a(s)}let l=n.length>0?e.filter(s=>["nome"].some(u=>Bd(String(s[u])).includes(Bd(n)))):e;return to(vr.Root,{children:[$e(vr.Trigger,{asChild:!0,children:to(PT,{sx:{color:s=>s.palette.grey[900]},variant:"text",children:[r.nome,$e(kT,{})]})}),$e(vr.Content,{sx:{"& .MuiPopover-paper":{minWidth:"300px",borderRadius:"12px",p:.5}},children:to(Qr.Root,{sx:{m:.5,minWidth:"300px",maxHeight:"300px",overflow:"auto"},children:[$e(Jt,{autoFocus:!0,onSearch:i}),$e(Qr.Content,{children:l.map(s=>$e(vr.Close,{asChild:!0,children:$e(Qr.Item,{selected:r.uuid===s.uuid,onClick:()=>o(s),children:to(Ld,{children:[$e(ri,{variant:"body1",textOverflow:"ellipsis",children:s.nome}),$e(ri,{variant:"body2",textOverflow:"ellipsis",children:Od(s.documento)})]})})},s.uuid))})]})})]})}import{Drawer as qT,Toolbar as YT}from"@mui/material";import{styled as KT}from"@mui/material/styles";import{List as NT}from"@mui/material";import{useState as DT}from"react";import{Box as OT,Collapse as BT,Icon as LT,ListItemText as $T}from"@mui/material";import{ExpandMore as zT,ExpandLess as _T}from"@mui/icons-material";import{MenuItem as AT}from"@mui/material";import{styled as ET}from"@mui/material/styles";import{jsx as RT}from"react/jsx-runtime";var FT=ET(AT,{})(({theme:t})=>({borderRadius:"6px",width:"90%",gap:"16px",margin:"0 auto",padding:"8px 16px",transition:"0.1s ease-in-out","&:hover":{backgroundColor:"rgba(89, 195, 224, 15%);","& .MuiTypography-root":{color:t.palette.primary.main},"& .MuiSvgIcon-root":{color:t.palette.primary.main},"& .MuiIcon-root":{color:t.palette.primary.main}},"& .MuiIcon-root":{color:t.palette.grey[500],fontSize:"20px"},"& .MuiTypography-root":{letterSpacing:"0.5px",color:t.palette.text.secondary,fontSize:t.typography.body1},"& .MuiSvgIcon-root":{fontSize:"24px"}})),MT=t=>RT(FT,{...t}),oi=MT;import{jsx as xr,jsxs as zd}from"react/jsx-runtime";function su(t){let{menuItem:e,activeMenu:r,onMenuClick:o}=t,[n,a]=DT(!1);if(!e.visible)return null;let i=!!(e?.items&&e?.items.length>0);function l(){a(!n)}return zd(OT,{children:[zd(oi,{onClick:()=>{if(e?.link){o(e.link);return}l()},selected:r===e.link,children:[!!e.icon&&xr(LT,{children:e.icon}),xr($T,{primary:e.label}),i&&!n&&xr(zT,{}),i&&n&&xr(_T,{})]}),e?.items&&xr(BT,{in:n,timeout:"auto",unmountOnExit:!0,children:xr(Nt,{activeMenu:r,sx:{pl:s=>s.spacing(1.5)},menus:e?.items||[],onMenuClick:o})})]})}import{jsx as _d}from"react/jsx-runtime";function Nt(t){let{menus:e,activeMenu:r,onMenuClick:o,...n}=t;return _d(NT,{component:"nav",disablePadding:!0,...n,children:e.map(a=>_d(su,{onMenuClick:o,activeMenu:r,menuItem:a},a.id))})}import{useState as VT}from"react";import{List as WT,Icon as HT,ListItemIcon as GT,Popper as jT}from"@mui/material";import{jsx as ro,jsxs as UT}from"react/jsx-runtime";function lu(t){let{menus:e,activeMenu:r,onMenuClick:o}=t,[n,a]=VT(null),i=(s,u,c)=>{a({element:s.currentTarget,id:u,items:c})},l=()=>{a(null)};return ro(WT,{component:"nav",disablePadding:!0,children:e.map(s=>s.visible?UT(oi,{onMouseEnter:u=>{s?.link||i(u,s.id,s.items)},onMouseLeave:()=>{s?.link||l()},onClick:()=>{s?.link&&o(s.link)},selected:r===s.link,children:[ro(GT,{children:ro(HT,{children:s.icon})}),n?.id===s.id&&ro(jT,{sx:{zIndex:999999},anchorEl:n?.element,open:!!n?.element,placement:"right-start",children:ro(Nt,{activeMenu:r,onMenuClick:o,menus:s?.items||[],sx:{minWidth:"240px",backgroundColor:N.palette.background.paper,borderRadius:"12px",padding:"16px 4px",boxShadow:"0px 5px 5px -3px rgb(0 0 0 / 20%), 0px 8px 10px 1px rgb(0 0 0 / 14%), 0px 3px 14px 2px rgb(0 0 0 / 12%);"}})})]},`minMenu-${s.id}`):null)})}import{jsx as uu,jsxs as QT}from"react/jsx-runtime";var Nd=(t,e)=>({width:t,transition:e.transitions.create("width",{easing:e.transitions.easing.sharp,duration:e.transitions.duration.enteringScreen}),overflowX:"hidden"}),Vd=t=>({transition:t.transitions.create("width",{easing:t.transitions.easing.sharp,duration:t.transitions.duration.leavingScreen}),overflowX:"hidden",width:`calc(${t.spacing(8)} + 1px)`,[t.breakpoints.up("sm")]:{width:`calc(${t.spacing(8)} + 1px)`}}),ZT=KT(qT,{shouldForwardProp:t=>t!=="open"&&t!=="width"})(({theme:t,open:e,width:r})=>({width:r,bgcolor:t.palette.background.paper,boxShadow:"2px 3px 20px -16px rgb(32 32 36 / 30%)",borderRightStyle:"none",whiteSpace:"nowrap",boxSizing:"border-box",...e&&{...Nd(r,t),"& .MuiDrawer-paper":Nd(r,t)},...!e&&{...Vd(t),"& .MuiDrawer-paper":Vd(t)}}));function Wd(t){let{open:e,items:r,width:o,activeMenu:n,onMenuClick:a,toggleMenu:i,...l}=t;return QT(ZT,{width:o,open:e,onClose:()=>i(!1),...l,children:[uu(YT,{}),e&&uu(Nt,{onMenuClick:a,activeMenu:n,menus:r}),!e&&uu(lu,{onMenuClick:a,activeMenu:n,menus:r})]})}import{Box as JT}from"@mui/material";import{jsx as XT}from"react/jsx-runtime";function Hd(t){return XT(JT,{m:2,sx:{display:"flex",flexDirection:"column",flexGrow:1},...t})}import{useUserContext as eP}from"@data-c/providers";import tP from"@mui/material/Avatar";import{jsx as rP}from"react/jsx-runtime";function Gd(t){let{user:e}=eP();return rP(tP,{src:e?.avatarUrl,sx:{width:64,height:64,margin:"auto",mb:2},...t})}import{Stack as Cu,Tab as Jd,Tabs as kP}from"@mui/material";import{useState as IP}from"react";import{Box as oP}from"@mui/material";import{jsx as nP}from"react/jsx-runtime";function ni(t){let{children:e,value:r,index:o,...n}=t;return r!==o?null:nP(oP,{role:"tabpanel",hidden:r!==o,id:`scrollable-auto-tabpanel-${o}`,"aria-labelledby":`scrollable-auto-tab-${o}`,sx:{display:"flex",flexDirection:"column",flexGrow:1},...n,children:r===o&&e})}import{useCredentials as pP,useForm as fP}from"@data-c/hooks";import{Alert as Yd,Divider as dP,Grid as oo,Stack as mP,TextField as pu,Typography as Kd}from"@mui/material";import{useEffect as fu,useState as du}from"react";import{useState as Cr,useCallback as iP}from"react";import aP from"react-easy-crop";import sP from"@mui/material/Slider";import jd from"@mui/material/Button";import lP from"@mui/material/Dialog";import Ud from"@mui/material/Avatar";function cu(t,e){return new Promise(r=>{let o=new Image;o.src=t,o.onload=()=>{let n=document.createElement("canvas");n.width=e.width,n.height=e.height;let a=n.getContext("2d");a&&(a.drawImage(o,e.x,e.y,e.width,e.height,0,0,e.width,e.height),r(n.toDataURL("image/jpeg")))}})}import{Stack as uP}from"@mui/material";import{jsx as et,jsxs as ii}from"react/jsx-runtime";var cP=({onSave:t,src:e})=>{let[r,o]=Cr(null),[n,a]=Cr(null),[i,l]=Cr({x:0,y:0}),[s,u]=Cr(1),[c,d]=Cr(null),[f,m]=Cr(!1),h=iP((v,b)=>{d(b)},[]);return ii(uP,{direction:"row",spacing:2,alignItems:"center",children:[n?et(Ud,{src:n,alt:"Preview",sx:{width:64,height:64,margin:"auto",mb:2}}):et(Ud,{src:e,sx:{width:64,height:64,margin:"auto",mb:2}}),ii("label",{children:[et("input",{type:"file",accept:"image/*",onChange:v=>{let b=v.target.files?.[0];if(!b)return;let S=new FileReader;S.onload=()=>{o(S.result),m(!0)},S.readAsDataURL(b)},style:{display:"none"}}),et(jd,{variant:"contained",component:"span",children:"Alterar foto"})]}),ii(lP,{open:f,onClose:()=>m(!1),maxWidth:"sm",fullWidth:!0,children:[et("div",{style:{position:"relative",height:400,background:"#333"},children:r&&et(aP,{image:r,crop:i,zoom:s,aspect:1,cropShape:"round",showGrid:!1,onCropChange:l,onZoomChange:u,onCropComplete:h})}),ii("div",{style:{padding:20},children:[et(sP,{value:s,min:1,max:3,step:.1,onChange:(v,b)=>u(b)}),et(_e,{children:et(jd,{variant:"contained",onClick:async()=>{if(!r||!c)return;let v=await cu(r,c);a(v),m(!1),t&&t(v)},children:"Salvar"})})]})]})]})},qd=cP;import{jsx as pe,jsxs as Zd}from"react/jsx-runtime";var hP=we().shape({name:ce().required("Informe o nome")});function mu(t){let{usuario:e,credentialsConfig:r,onUploadComplete:o}=t,{data:n,setData:a,handleChange:i,validate:l,validationErrors:s}=fP(e,hP),[u,c]=du(!1),[d,f]=du(!1),[m,h]=du(!1),{uploadAvatar:p,atualizarUsuario:y}=pP(r);fu(()=>{a(e)},[e]),fu(()=>{m&&setTimeout(()=>{h(!1)},3e3)},[m]),fu(()=>{u&&setTimeout(()=>{c(!1)},3e3)},[u]);function v(){l(async b=>{try{f(!0),await y(b),h(!0)}catch{c("Ocorreu um erro ao alterar os dados da conta")}finally{f(!1)}})}return Zd(mP,{spacing:2,children:[pe(Kd,{variant:"h6",children:"Avatar"}),pe(qd,{src:n?.avatarUrl,onSave:b=>{try{p(b),o&&(h(!0),o(!0))}catch(S){c("Ocorreu um erro ao atualizar a foto de perfil"),o&&o(!1,S)}}}),pe(dP,{}),pe(Kd,{variant:"h6",children:"Informa\xE7\xF5es da Conta"}),Zd(oo,{container:!0,spacing:1.5,children:[pe(oo,{size:{xl:4,lg:4,md:4,sm:12,xs:12},children:pe(pu,{disabled:!0,fullWidth:!0,label:"E-mail",value:n?.email||""})}),pe(oo,{size:{xl:4,lg:4,md:4,sm:12,xs:12},children:pe(pu,{name:"name",fullWidth:!0,label:"Nome",value:n?.name||"",onChange:i,...s("name")})}),pe(oo,{size:{xl:4,lg:4,md:4,sm:12,xs:12},children:pe(pu,{name:"surname",fullWidth:!0,label:"Sobrenome",value:n?.surname||"",onChange:i})})]}),pe(oo,{size:{xl:4,lg:4,md:4,sm:12,xs:12},children:pe(_e,{children:pe(D,{isLoading:d,onClick:()=>v(),variant:"contained",children:"Salvar"})})}),m&&pe(Yd,{children:"Dados da conta alterados com sucesso!"}),u&&pe(Yd,{severity:"error",children:u})]})}import{useCredentials as xP,useForm as CP}from"@data-c/hooks";import{Alert as wP,Divider as SP,Stack as yu,Typography as bu}from"@mui/material";import{useEffect as TP,useState as ai}from"react";import{useCredentials as gP}from"@data-c/hooks";import{Alert as yP,Stack as bP,Typography as Qd}from"@mui/material";import{useEffect as vP,useState as hu}from"react";import{jsx as ze,jsxs as no}from"react/jsx-runtime";function gu(t){let{open:e,onClose:r,payload:o,onCodigoVerificado:n,credentialsConfig:a}=t,[i,l]=hu(""),[s,u]=hu(!1),[c,d]=hu(!1),{validarCodigoWhatsapp:f}=gP(a);vP(()=>{s&&setTimeout(()=>{u(!1)},3e3)},[s]);async function m(){try{d(!0);let h=await f(i);n(h.data)}catch(h){u(h.response.data.message)}finally{d(!1)}}return no(O.Root,{open:e,onClose:h=>r(),maxWidth:"xs",children:[no(O.Header,{children:[ze(O.Title,{children:"Verifica\xE7\xE3o do seu n\xFAmero de WhatsApp"}),ze(O.ActionClose,{onClose:r})]}),ze(O.Content,{children:no(bP,{spacing:2,justifyContent:"center",alignContent:"center",alignItems:"center",children:[ze(Qd,{variant:"subtitle1",sx:{fontWeight:"bolder",fontSize:"11pt"},children:"\u{1F510} Verifique seu n\xFAmero"}),no(Qd,{variant:"body1",sx:{fontSize:"10pt"},children:["Enviamos um c\xF3digo via WhatsApp para +55"," ",ze("b",{children:`(${o?.whatsappNumber?.slice(0,2)}) ${o?.whatsappNumber?.slice(2,7)}-${o?.whatsappNumber?.slice(7)}`}),". ",ze("br",{}),"Digite o c\xF3digo abaixo para confirmar que este n\xFAmero \xE9 seu."]}),ze(zr,{value:i,onChange:h=>{l(h)}}),s&&ze(yP,{sx:{flexGrow:1},severity:"error",children:s})]})}),ze(O.Footer,{children:no(O.Actions,{children:[ze(O.ActionCancelar,{onClick:()=>r()}),ze(O.ActionSalvar,{label:"Verificar",onClick:m,isLoading:c,disabled:i.length!=6})]})})]})}import{Verified as PP}from"@mui/icons-material";import{jsx as Re,jsxs as vu}from"react/jsx-runtime";var xG=we().shape({whatsappNumber:ce().required("Informe o n\xFAmero do whastapp").length(15)});function xu(t){let{usuario:e,credentialsConfig:r,onWhastappSaved:o}=t,[n,a]=ai(!1),[i,l]=ai(!1),{data:s,setData:u,changeValue:c,validate:d,validationErrors:f}=CP(e),[m,h]=ai(!1),[p,y]=ai(!1),{atualizarUsuario:v,gerarWhatsappVerificationCode:b}=xP(r);TP(()=>{u(e)},[e]);function S(){d(async C=>{try{l(!0);let k=await v(C);o&&o(k.data)}catch{}finally{l(!1)}})}async function w(){try{h(!0);let C=await b();y(!0)}catch{}finally{h(!1)}}return vu(yu,{spacing:2,children:[Re(bu,{variant:"h6",children:"Senha"}),Re(D,{onClick:()=>{a(!0)},sx:{width:"200px"},fullWidth:!1,variant:"contained",children:"Alterar Senha"}),Re(ar,{isOpen:n,onClose:async()=>a(!1),credentialsConfig:r}),Re(SP,{}),Re(bu,{variant:"h6",children:"Login com Whastapp"}),vu(yu,{direction:"row",spacing:2,children:[Re($r,{disabled:!!s?.whatsappVerifiedAt,fullWidth:!1,name:"whatsappNumber",label:"Whastapp",value:s.whatsappNumber||"",onChange:C=>{c("whatsappNumber",C.target.value)}}),s.whatsappVerifiedAt&&vu(yu,{direction:"row",spacing:1,justifyContent:"center",alignItems:"center",children:[Re(PP,{color:"success"}),Re(bu,{variant:"body2",children:"N\xFAmero Verificado"})]}),s.whatsappNumber&&s.whatsappNumber.replace(/\D/g,"").length===11&&!s.whatsappVerifiedAt&&Re(D,{isLoading:i,onClick:S,children:"Salvar Whatsapp"})]}),e.whatsappNumber&&e.whatsappNumber.replace(/\D/g,"").length===11&&!s.whatsappVerifiedAt&&Re(wP,{severity:"warning",action:Re(D,{isLoading:m,onClick:w,children:"Enviar n\xFAmero de verifica\xE7\xE3o"}),children:"O seu n\xFAmero de whatsapp ainda n\xE3o est\xE1 validado"}),Re(gu,{open:p,onClose:async C=>{y(!1)},payload:e,credentialsConfig:r,onCodigoVerificado:C=>{u(C),y(!1)}})]})}import{useUserContext as AP}from"@data-c/providers";import{Fragment as EP,jsx as ft,jsxs as wu}from"react/jsx-runtime";function Xd(t){let[e,r]=IP(0),{user:o,setUser:n,credentialsConfig:a}=AP();return ft(EP,{children:wu(Cu,{spacing:2,direction:"row",children:[ft(Cu,{sx:{width:"200px"},children:wu(kP,{orientation:"vertical",value:e,onChange:(i,l)=>{r(l)},sx:{"& .MuiButtonBase-root":{alignItems:"flex-start"}},children:[ft(Jd,{label:"Minha Conta",value:0}),ft(Jd,{label:"Login e Seguran\xE7a",value:1})]})}),wu(Cu,{sx:{flexGrow:1},children:[ft(ni,{value:e,index:0,children:ft(mu,{credentialsConfig:a,usuario:o||{}})}),ft(ni,{value:e,index:1,children:ft(xu,{onWhastappSaved:i=>{n(i)},credentialsConfig:a,usuario:o||{}})})]})]})})}export{$d as AlterarLicenca,ar as AlterarSenha,Un as Autocomplete,Gd as Avatar,pf as Breadcrumbs,D as Button,_e as ButtonContainer,YS as ButtonGroup,bd as CEPTextField,n2 as Card,ku as Checkbox,Nu as ColorsGrid,Hd as Content,bC as ContentTitle,jk as CurrencyCellStyle,ST as CurrencyTextField,mS as DataTable,gi as DataTableOptions,_t as DatePicker,Td as DatePickerProvider,nu as DateRangePicker,O as Dialog,hd as DocumentoTextField,Wd as DrawerMenu,an as Editable,ZC as Filter,yf as FilterApiContext,wi as FilterContainer,mo as FilterControl,gf as FilterDataContext,bf as FilterProvider,Zu as Flag,k1 as Header,ye as Icon,Kc as LabelValue,Qr as List,s2 as LucidIcon,cC as Menu,Qp as MioAuth,Sd as NotaVersao,Gk as OptionStyles,C2 as Page,tp as PageTitle,Tt as PasswordTextField,vr as Popover,Xd as Profile,Jt as SearchTextField,Vn as Surface,xd as TelefoneTextField,Se as TextField,jn as Title,Wt as Tooltip,z2 as Transporter,uC as renderMenuItems,N as theme,BD as useDialogs,gr as useFilter,Fe as useFilterApi,rC as useMenu,Jr as useTransporter};
11
159
  /*! Bundled license information:
12
160
 
13
161
  react-is/cjs/react-is.production.min.js: