@data-c/ui 0.2.50 → 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.d.ts +39 -175
- package/dist/index.js +8 -8
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +228 -0
- package/dist/index.mjs.map +1 -0
- package/package.json +4 -18
package/dist/index.mjs
ADDED
|
@@ -0,0 +1,228 @@
|
|
|
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&<(ep,{sx:{mr:1},onClick:o,children:lt(Q0,{})}),a&<(an,{typographyProps:y,value:d,onChange:v=>{a&&a(v)}}),!a&<(Y0,{...y,children:e})]}),n&<(ep,{sx:{marginLeft:"auto"},onClick:n,children:lt(J0,{fontSize:"medium"})}),aa(q0,{spacing:1,direction:"row",children:[i&<(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}".
|
|
156
|
+
|
|
157
|
+
attempted value: ${i}
|
|
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};
|
|
159
|
+
/*! Bundled license information:
|
|
160
|
+
|
|
161
|
+
react-is/cjs/react-is.production.min.js:
|
|
162
|
+
(** @license React v16.13.1
|
|
163
|
+
* react-is.production.min.js
|
|
164
|
+
*
|
|
165
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
166
|
+
*
|
|
167
|
+
* This source code is licensed under the MIT license found in the
|
|
168
|
+
* LICENSE file in the root directory of this source tree.
|
|
169
|
+
*)
|
|
170
|
+
|
|
171
|
+
react-is/cjs/react-is.development.js:
|
|
172
|
+
(** @license React v16.13.1
|
|
173
|
+
* react-is.development.js
|
|
174
|
+
*
|
|
175
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
176
|
+
*
|
|
177
|
+
* This source code is licensed under the MIT license found in the
|
|
178
|
+
* LICENSE file in the root directory of this source tree.
|
|
179
|
+
*)
|
|
180
|
+
|
|
181
|
+
object-assign/index.js:
|
|
182
|
+
(*
|
|
183
|
+
object-assign
|
|
184
|
+
(c) Sindre Sorhus
|
|
185
|
+
@license MIT
|
|
186
|
+
*)
|
|
187
|
+
|
|
188
|
+
react-is/cjs/react-is.production.js:
|
|
189
|
+
(**
|
|
190
|
+
* @license React
|
|
191
|
+
* react-is.production.js
|
|
192
|
+
*
|
|
193
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
194
|
+
*
|
|
195
|
+
* This source code is licensed under the MIT license found in the
|
|
196
|
+
* LICENSE file in the root directory of this source tree.
|
|
197
|
+
*)
|
|
198
|
+
|
|
199
|
+
react-is/cjs/react-is.development.js:
|
|
200
|
+
(**
|
|
201
|
+
* @license React
|
|
202
|
+
* react-is.development.js
|
|
203
|
+
*
|
|
204
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
205
|
+
*
|
|
206
|
+
* This source code is licensed under the MIT license found in the
|
|
207
|
+
* LICENSE file in the root directory of this source tree.
|
|
208
|
+
*)
|
|
209
|
+
|
|
210
|
+
@mui/styled-engine/esm/index.js:
|
|
211
|
+
(**
|
|
212
|
+
* @mui/styled-engine v7.3.6
|
|
213
|
+
*
|
|
214
|
+
* @license MIT
|
|
215
|
+
* This source code is licensed under the MIT license found in the
|
|
216
|
+
* LICENSE file in the root directory of this source tree.
|
|
217
|
+
*)
|
|
218
|
+
|
|
219
|
+
@mui/system/esm/index.js:
|
|
220
|
+
(**
|
|
221
|
+
* @mui/system v7.3.6
|
|
222
|
+
*
|
|
223
|
+
* @license MIT
|
|
224
|
+
* This source code is licensed under the MIT license found in the
|
|
225
|
+
* LICENSE file in the root directory of this source tree.
|
|
226
|
+
*)
|
|
227
|
+
*/
|
|
228
|
+
//# sourceMappingURL=index.mjs.map
|