treege 0.11.4 → 0.12.1
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/CHANGELOG.md +2 -2
- package/dist/main.js +2578 -2465
- package/dist/main.umd.cjs +37 -37
- package/dist/src/features/Treege/components/{FieldsSelect/FieldsSelect.d.ts → FieldSelect/FieldSelect.d.ts} +2 -2
- package/dist/src/features/Treege/components/FieldSelect/index.d.ts +3 -0
- package/dist/src/features/Treege/components/{FieldsSelect/useFieldsSelect.d.ts → FieldSelect/useFieldSelect.d.ts} +2 -2
- package/dist/src/features/Treege/components/FieldSelectAutocompleteCreatable/FieldSelectAutocompleteCreatable.d.ts +11 -0
- package/dist/src/features/Treege/components/FieldSelectAutocompleteCreatable/index.d.ts +3 -0
- package/dist/src/features/Treege/components/Forms/FormTreeCardMutation/useFormTreeCardMutation.d.ts +6 -1
- package/dist/src/features/Treege/type/TreeNode.d.ts +2 -0
- package/dist/src/locales/en/translation-en.d.ts +1 -0
- package/dist/src/locales/fr/translation-fr.d.ts +1 -0
- package/dist/src/utils/tree/appendNode/appendNode.d.ts +2 -7
- package/dist/src/utils/tree/getNamesInTree/getNamesInTree.d.ts +7 -0
- package/dist/src/utils/tree/getUniqueTagsInTree/getUniqueTagsInTree.d.ts +7 -0
- package/dist/src/utils/tree/getUniqueTagsInTree/test/mock.d.ts +10 -0
- package/dist/src/utils/tree/index.d.ts +2 -2
- package/package.json +1 -1
- package/dist/src/components/Layouts/Header/Header.test.d.ts +0 -1
- package/dist/src/components/Layouts/Main/Main.test.d.ts +0 -1
- package/dist/src/components/Layouts/MosaicLayout/MosaicLayout.test.d.ts +0 -1
- package/dist/src/components/Layouts/Sidebar/Sidebar.test.d.ts +0 -1
- package/dist/src/features/Treege/components/FieldsSelect/index.d.ts +0 -3
- package/dist/src/utils/array/isUniqueArrayItem/test/isUniqueArrayItem.test.d.ts +0 -1
- package/dist/src/utils/array/isUniqueArrayItemWithNewEntry/test/isUniqueArrayItemWithNewEntry.test.d.ts +0 -1
- package/dist/src/utils/object/removeObjectProperty/test/removeObjectProperty.test.d.ts +0 -1
- package/dist/src/utils/tree/appendNode/test/appendNode.test.d.ts +0 -1
- package/dist/src/utils/tree/findNodeByNameInTree/test/findNodeByNameInTree.test.d.ts +0 -1
- package/dist/src/utils/tree/findParentNodeByNameInTree/test/findParentNodeByNameInTree.test.d.ts +0 -1
- package/dist/src/utils/tree/getNode/test/getNode.test.d.ts +0 -1
- package/dist/src/utils/tree/getNodeNames/getNodeNames.d.ts +0 -7
- package/dist/src/utils/tree/getNodeNames/test/getNodeNames.test.d.ts +0 -1
- package/dist/src/utils/tree/getTree/test/getTree.test.d.ts +0 -1
- package/dist/src/utils/tree/removeNode/test/removeNode.test.d.ts +0 -1
- package/dist/src/utils/tree/updateNodeInTree/test/updateNodeInTree.test.d.ts +0 -1
- /package/dist/src/{components/DataDisplay/Logo/Logo.test.d.ts → utils/tree/getNamesInTree/test/getNamesInTree.d.ts} +0 -0
- /package/dist/src/utils/tree/{getNodeNames → getNamesInTree}/test/mock.d.ts +0 -0
- /package/dist/src/{components/Layouts/Action/Action.test.d.ts → utils/tree/getUniqueTagsInTree/test/getUniqueTagsInTree.d.ts} +0 -0
package/dist/main.umd.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(Oe,N){typeof exports=="object"&&typeof module<"u"?N(exports,require("react"),require("@tanstack/react-query"),require("axios"),require("@tracktor/design-system"),require("react-d3-tree"),require("react-i18next"),require("@codemirror/lang-json"),require("@uiw/codemirror-theme-dracula"),require("@uiw/react-codemirror"),require("i18next"),require("i18next-browser-languagedetector")):typeof define=="function"&&define.amd?define(["exports","react","@tanstack/react-query","axios","@tracktor/design-system","react-d3-tree","react-i18next","@codemirror/lang-json","@uiw/codemirror-theme-dracula","@uiw/react-codemirror","i18next","i18next-browser-languagedetector"],N):(Oe=typeof globalThis<"u"?globalThis:Oe||self,N(Oe.treege={},Oe.React,Oe.reactQuery,Oe.axios,Oe.tracktorDesignSystem,Oe.ReactD3Tree,Oe.reactI18next,Oe.codemirrorLangJson,Oe.codemirrorThemeDracula,Oe.reactCodemirror,Oe.i18next,Oe.i18nextBrowserLanguageDetector))})(this,function(Oe,N,lt,ct,y,ii,$e,si,li,ci,Ot,ui){"use strict";function di(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const G=di(N);function fi(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function pi(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var Yr={exports:{}},Ct={};/**
|
|
2
2
|
* @license React
|
|
3
3
|
* react-jsx-runtime.production.min.js
|
|
4
4
|
*
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
*
|
|
7
7
|
* This source code is licensed under the MIT license found in the
|
|
8
8
|
* LICENSE file in the root directory of this source tree.
|
|
9
|
-
*/var
|
|
9
|
+
*/var qn;function hi(){if(qn)return Ct;qn=1;var e=N,t=Symbol.for("react.element"),n=Symbol.for("react.fragment"),r=Object.prototype.hasOwnProperty,o=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,a={key:!0,ref:!0,__self:!0,__source:!0};function i(l,u,d){var f,p={},h=null,M=null;d!==void 0&&(h=""+d),u.key!==void 0&&(h=""+u.key),u.ref!==void 0&&(M=u.ref);for(f in u)r.call(u,f)&&!a.hasOwnProperty(f)&&(p[f]=u[f]);if(l&&l.defaultProps)for(f in u=l.defaultProps,u)p[f]===void 0&&(p[f]=u[f]);return{$$typeof:t,type:l,key:h,ref:M,props:p,_owner:o.current}}return Ct.Fragment=n,Ct.jsx=i,Ct.jsxs=i,Ct}var wt={};/**
|
|
10
10
|
* @license React
|
|
11
11
|
* react-jsx-runtime.development.js
|
|
12
12
|
*
|
|
@@ -14,38 +14,38 @@
|
|
|
14
14
|
*
|
|
15
15
|
* This source code is licensed under the MIT license found in the
|
|
16
16
|
* LICENSE file in the root directory of this source tree.
|
|
17
|
-
*/var
|
|
18
|
-
`+
|
|
19
|
-
`),
|
|
20
|
-
`),
|
|
21
|
-
`+
|
|
17
|
+
*/var Wn;function gi(){return Wn||(Wn=1,process.env.NODE_ENV!=="production"&&function(){var e=N,t=Symbol.for("react.element"),n=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),i=Symbol.for("react.provider"),l=Symbol.for("react.context"),u=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),f=Symbol.for("react.suspense_list"),p=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),M=Symbol.for("react.offscreen"),v=Symbol.iterator,g="@@iterator";function m(s){if(s===null||typeof s!="object")return null;var T=v&&s[v]||s[g];return typeof T=="function"?T:null}var x=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function O(s){{for(var T=arguments.length,D=new Array(T>1?T-1:0),k=1;k<T;k++)D[k-1]=arguments[k];I("error",s,D)}}function I(s,T,D){{var k=x.ReactDebugCurrentFrame,J=k.getStackAddendum();J!==""&&(T+="%s",D=D.concat([J]));var X=D.map(function(B){return String(B)});X.unshift("Warning: "+T),Function.prototype.apply.call(console[s],console,X)}}var A=!1,b=!1,W=!1,z=!1,Te=!1,he;he=Symbol.for("react.module.reference");function _(s){return!!(typeof s=="string"||typeof s=="function"||s===r||s===a||Te||s===o||s===d||s===f||z||s===M||A||b||W||typeof s=="object"&&s!==null&&(s.$$typeof===h||s.$$typeof===p||s.$$typeof===i||s.$$typeof===l||s.$$typeof===u||s.$$typeof===he||s.getModuleId!==void 0))}function se(s,T,D){var k=s.displayName;if(k)return k;var J=T.displayName||T.name||"";return J!==""?D+"("+J+")":D}function me(s){return s.displayName||"Context"}function de(s){if(s==null)return null;if(typeof s.tag=="number"&&O("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof s=="function")return s.displayName||s.name||null;if(typeof s=="string")return s;switch(s){case r:return"Fragment";case n:return"Portal";case a:return"Profiler";case o:return"StrictMode";case d:return"Suspense";case f:return"SuspenseList"}if(typeof s=="object")switch(s.$$typeof){case l:var T=s;return me(T)+".Consumer";case i:var D=s;return me(D._context)+".Provider";case u:return se(s,s.render,"ForwardRef");case p:var k=s.displayName||null;return k!==null?k:de(s.type)||"Memo";case h:{var J=s,X=J._payload,B=J._init;try{return de(B(X))}catch{return null}}}return null}var le=Object.assign,Me=0,xe,Ee,_e,Ye,j,w,L;function $(){}$.__reactDisabledLog=!0;function R(){{if(Me===0){xe=console.log,Ee=console.info,_e=console.warn,Ye=console.error,j=console.group,w=console.groupCollapsed,L=console.groupEnd;var s={configurable:!0,enumerable:!0,value:$,writable:!0};Object.defineProperties(console,{info:s,log:s,warn:s,error:s,group:s,groupCollapsed:s,groupEnd:s})}Me++}}function U(){{if(Me--,Me===0){var s={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:le({},s,{value:xe}),info:le({},s,{value:Ee}),warn:le({},s,{value:_e}),error:le({},s,{value:Ye}),group:le({},s,{value:j}),groupCollapsed:le({},s,{value:w}),groupEnd:le({},s,{value:L})})}Me<0&&O("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var P=x.ReactCurrentDispatcher,F;function Y(s,T,D){{if(F===void 0)try{throw Error()}catch(J){var k=J.stack.trim().match(/\n( *(at )?)/);F=k&&k[1]||""}return`
|
|
18
|
+
`+F+s}}var Q=!1,V;{var Ne=typeof WeakMap=="function"?WeakMap:Map;V=new Ne}function E(s,T){if(!s||Q)return"";{var D=V.get(s);if(D!==void 0)return D}var k;Q=!0;var J=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var X;X=P.current,P.current=null,R();try{if(T){var B=function(){throw Error()};if(Object.defineProperty(B.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(B,[])}catch(qe){k=qe}Reflect.construct(s,[],B)}else{try{B.call()}catch(qe){k=qe}s.call(B.prototype)}}else{try{throw Error()}catch(qe){k=qe}s()}}catch(qe){if(qe&&k&&typeof qe.stack=="string"){for(var q=qe.stack.split(`
|
|
19
|
+
`),je=k.stack.split(`
|
|
20
|
+
`),fe=q.length-1,pe=je.length-1;fe>=1&&pe>=0&&q[fe]!==je[pe];)pe--;for(;fe>=1&&pe>=0;fe--,pe--)if(q[fe]!==je[pe]){if(fe!==1||pe!==1)do if(fe--,pe--,pe<0||q[fe]!==je[pe]){var Ie=`
|
|
21
|
+
`+q[fe].replace(" at new "," at ");return s.displayName&&Ie.includes("<anonymous>")&&(Ie=Ie.replace("<anonymous>",s.displayName)),typeof s=="function"&&V.set(s,Ie),Ie}while(fe>=1&&pe>=0);break}}}finally{Q=!1,P.current=X,U(),Error.prepareStackTrace=J}var Be=s?s.displayName||s.name:"",Gt=Be?Y(Be):"";return typeof s=="function"&&V.set(s,Gt),Gt}function Re(s,T,D){return E(s,!1)}function S(s){var T=s.prototype;return!!(T&&T.isReactComponent)}function Qe(s,T,D){if(s==null)return"";if(typeof s=="function")return E(s,S(s));if(typeof s=="string")return Y(s);switch(s){case d:return Y("Suspense");case f:return Y("SuspenseList")}if(typeof s=="object")switch(s.$$typeof){case u:return Re(s.render);case p:return Qe(s.type,T,D);case h:{var k=s,J=k._payload,X=k._init;try{return Qe(X(J),T,D)}catch{}}}return""}var Je=Object.prototype.hasOwnProperty,it={},Nr=x.ReactDebugCurrentFrame;function Tt(s){if(s){var T=s._owner,D=Qe(s.type,s._source,T?T.type:null);Nr.setExtraStackFrame(D)}else Nr.setExtraStackFrame(null)}function Yn(s,T,D,k,J){{var X=Function.call.bind(Je);for(var B in s)if(X(s,B)){var q=void 0;try{if(typeof s[B]!="function"){var je=Error((k||"React class")+": "+D+" type `"+B+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof s[B]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw je.name="Invariant Violation",je}q=s[B](T,B,k,D,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(fe){q=fe}q&&!(q instanceof Error)&&(Tt(J),O("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",k||"React class",D,B,typeof q),Tt(null)),q instanceof Error&&!(q.message in it)&&(it[q.message]=!0,Tt(J),O("Failed %s type: %s",D,q.message),Tt(null))}}}var Fn=Array.isArray;function Ft(s){return Fn(s)}function Un(s){{var T=typeof Symbol=="function"&&Symbol.toStringTag,D=T&&s[Symbol.toStringTag]||s.constructor.name||"Object";return D}}function Vn(s){try{return Er(s),!1}catch{return!0}}function Er(s){return""+s}function Or(s){if(Vn(s))return O("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",Un(s)),Er(s)}var st=x.ReactCurrentOwner,Qn={key:!0,ref:!0,__self:!0,__source:!0},Cr,Ut,jt;jt={};function wr(s){if(Je.call(s,"ref")){var T=Object.getOwnPropertyDescriptor(s,"ref").get;if(T&&T.isReactWarning)return!1}return s.ref!==void 0}function Ir(s){if(Je.call(s,"key")){var T=Object.getOwnPropertyDescriptor(s,"key").get;if(T&&T.isReactWarning)return!1}return s.key!==void 0}function Bn(s,T){if(typeof s.ref=="string"&&st.current&&T&&st.current.stateNode!==T){var D=de(st.current.type);jt[D]||(O('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref',de(st.current.type),s.ref),jt[D]=!0)}}function Ar(s,T){{var D=function(){Cr||(Cr=!0,O("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",T))};D.isReactWarning=!0,Object.defineProperty(s,"key",{get:D,configurable:!0})}}function Sr(s,T){{var D=function(){Ut||(Ut=!0,O("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",T))};D.isReactWarning=!0,Object.defineProperty(s,"ref",{get:D,configurable:!0})}}var kr=function(s,T,D,k,J,X,B){var q={$$typeof:t,type:s,key:T,ref:D,props:B,_owner:X};return q._store={},Object.defineProperty(q._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(q,"_self",{configurable:!1,enumerable:!1,writable:!1,value:k}),Object.defineProperty(q,"_source",{configurable:!1,enumerable:!1,writable:!1,value:J}),Object.freeze&&(Object.freeze(q.props),Object.freeze(q)),q};function zr(s,T,D,k,J){{var X,B={},q=null,je=null;D!==void 0&&(Or(D),q=""+D),Ir(T)&&(Or(T.key),q=""+T.key),wr(T)&&(je=T.ref,Bn(T,J));for(X in T)Je.call(T,X)&&!Qn.hasOwnProperty(X)&&(B[X]=T[X]);if(s&&s.defaultProps){var fe=s.defaultProps;for(X in fe)B[X]===void 0&&(B[X]=fe[X])}if(q||je){var pe=typeof s=="function"?s.displayName||s.name||"Unknown":s;q&&Ar(B,pe),je&&Sr(B,pe)}return kr(s,q,je,J,k,st.current,B)}}var Dt=x.ReactCurrentOwner,Vt=x.ReactDebugCurrentFrame;function nt(s){if(s){var T=s._owner,D=Qe(s.type,s._source,T?T.type:null);Vt.setExtraStackFrame(D)}else Vt.setExtraStackFrame(null)}var Nt;Nt=!1;function Et(s){return typeof s=="object"&&s!==null&&s.$$typeof===t}function Qt(){{if(Dt.current){var s=de(Dt.current.type);if(s)return`
|
|
22
22
|
|
|
23
|
-
Check the render method of \``+
|
|
23
|
+
Check the render method of \``+s+"`."}return""}}function _r(s){{if(s!==void 0){var T=s.fileName.replace(/^.*[\\\/]/,""),D=s.lineNumber;return`
|
|
24
24
|
|
|
25
|
-
Check your code at `+T+":"+D+"."}return""}}var
|
|
25
|
+
Check your code at `+T+":"+D+"."}return""}}var Bt={};function Rr(s){{var T=Qt();if(!T){var D=typeof s=="string"?s:s.displayName||s.name;D&&(T=`
|
|
26
26
|
|
|
27
|
-
Check the top-level render call using <`+D+">.")}return T}}function ee(c,T){{if(!c._store||c._store.validated||c.key!=null)return;c._store.validated=!0;var D=E(T);if(Kt[D])return;Kt[D]=!0;var z="";c&&c._owner&&c._owner!==Ot.current&&(z=" It was passed a child from "+de(c._owner.type)+"."),it(c),N('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',D,z),it(null)}}function te(c,T){{if(typeof c!="object")return;if(Bt(c))for(var D=0;D<c.length;D++){var z=c[D];It(z)&&ee(z,T)}else if(It(c))c._store&&(c._store.validated=!0);else if(c){var G=m(c);if(typeof G=="function"&&G!==c.entries)for(var Z=G.call(c),B;!(B=Z.next()).done;)It(B.value)&&ee(B.value,T)}}}function ge(c){{var T=c.type;if(T==null||typeof T=="string")return;var D;if(typeof T=="function")D=T.propTypes;else if(typeof T=="object"&&(T.$$typeof===u||T.$$typeof===h))D=T.propTypes;else return;if(D){var z=de(T);Pn(D,c.props,"prop",z,c)}else if(T.PropTypes!==void 0&&!wt){wt=!0;var G=de(T);N("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",G||"Unknown")}typeof T.getDefaultProps=="function"&&!T.getDefaultProps.isReactClassApproved&&N("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function Le(c){{for(var T=Object.keys(c.props),D=0;D<T.length;D++){var z=T[D];if(z!=="children"&&z!=="key"){it(c),N("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",z),it(null);break}}c.ref!==null&&(it(c),N("Invalid attribute `ref` supplied to `React.Fragment`."),it(null))}}function $e(c,T,D,z,G,Z){{var B=R(c);if(!B){var F="";(c===void 0||typeof c=="object"&&c!==null&&Object.keys(c).length===0)&&(F+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var Ee=Lr(G);Ee?F+=Ee:F+=Gt();var xe;c===null?xe="null":Bt(c)?xe="array":c!==void 0&&c.$$typeof===t?(xe="<"+(de(c.type)||"Unknown")+" />",F=" Did you accidentally export a JSX literal instead of a component?"):xe=typeof c,N("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",xe,F)}var fe=Rr(c,T,D,G,Z);if(fe==null)return fe;if(B){var Oe=T.children;if(Oe!==void 0)if(z)if(Bt(Oe)){for(var lt=0;lt<Oe.length;lt++)te(Oe[lt],c);Object.freeze&&Object.freeze(Oe)}else N("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else te(Oe,c)}return c===r?Le(fe):ge(fe),fe}}function We(c,T,D){return $e(c,T,D,!0)}function Fe(c,T,D){return $e(c,T,D,!1)}var nt=Fe,Ct=We;zt.Fragment=r,zt.jsx=nt,zt.jsxs=Ct}()),zt}process.env.NODE_ENV==="production"?Pr.exports=fi():Pr.exports=pi();var l=Pr.exports;const ce={background:"#0a1929",borderBlue:"#0f353e",borderGrey:"rgba(255, 255, 255, 0.1)",grey500:"#868c95",primary:"#0ed3b4",secondary:"#007ef6",tertiary:"#0f353e"},hi={components:{MuiButton:{styleOverrides:{root:({ownerState:e})=>({...e.color==="primary"&&e.variant==="contained"&&{color:`${ce.tertiary} !important`}})}}},palette:{background:{default:ce.background,paper:ce.background},mode:"dark",primary:{main:ce.primary},secondary:{main:ce.secondary}}},gi=({children:e})=>l.jsxs(l.Fragment,{children:[l.jsx(y.GlobalStyles,{styles:{"*":{scrollbarColor:"rgba(255, 255, 255, 0.2) rgba(255, 255, 255, 0.05)",scrollbarWidth:"thin"},"*::-webkit-scrollbar":{height:6,width:6},"*::-webkit-scrollbar-button":{height:0,width:0},"*::-webkit-scrollbar-corner":{background:"transparent"},"*::-webkit-scrollbar-thumb":{backgroundColor:"rgba(255, 255, 255, 0.2)",border:0,borderRadius:10},"*::-webkit-scrollbar-track":{background:"rgba(255, 255, 255, 0.05)"},"html, body, #root":{height:"100%"}}}),l.jsx(y.ThemeProvider,{theme:hi,children:e})]}),mi=new ft.QueryClient({defaultOptions:{queries:{refetchOnWindowFocus:!1,retry:!1}}}),yi={authToken:void 0},vi=S.createContext(yi),bi=({children:e,authToken:t})=>{const n=S.useMemo(()=>({authToken:t}),[t]);return l.jsx(vi.Provider,{value:n,children:e})},qn={dispatchSnackbar:()=>null,snackbar:{open:!1}},Wn=S.createContext(qn),Jt={closeSnackbar:"closeSnackbar",openSnackbar:"openSnackbar"},Mi=(e,t="success")=>({message:e,severity:t,type:Jt.openSnackbar}),Gn=()=>({type:Jt.closeSnackbar}),xi=(e,t)=>{switch(t.type){case Jt.openSnackbar:{const{message:n,severity:r}=t;return{message:n,open:!0,severity:r}}case Jt.closeSnackbar:return{...e,open:!1};default:throw new Error}},Ti={snackbarAlert:{width:"100%"}},ji=({children:e})=>{const[t,n]=S.useReducer(xi,qn.snackbar),{message:r,open:o,severity:a}=t,i=6e3,s=()=>n(Gn()),u=S.useMemo(()=>({dispatchSnackbar:n,snackbar:t}),[t,n]);return l.jsxs(Wn.Provider,{value:u,children:[l.jsx(y.Snackbar,{open:o,autoHideDuration:i,onClose:s,anchorOrigin:{horizontal:"center",vertical:"bottom"},children:l.jsx(y.Alert,{onClose:s,severity:a,sx:Ti.snackbarAlert,variant:"filled",children:r})}),e]})},Ni="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNDYyIiBoZWlnaHQ9IjE0NCIgdmlld0Jve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Y0VjEwNC4wOEM0NTMuNTI0IDEwNS4wNCA0NTEuMDYgMTA1Ljc0NCA0NDguMjQ0IDEwNi4xOTJDNDQ1LjQyOCAxMDYuNzA0IDQ0Mi4zNTYgMTA2Ljk2IDQzOS4wMjggMTA2Ljk2Wk00MjUuMzk2IDc5Ljc5Mkg0NDYuOTk2Vjc3LjI5NkM0NDYuOTk2IDc0LjY3MiA0NDYuMjI4IDcyLjYyNCA0NDQuNjkyIDcxLjE1MkM0NDMuMTU2IDY5LjYxNiA0NDAuNTY0IDY4Ljg0OCA0MzYuOTE2IDY4Ljg0OEM0MzIuNjI4IDY4Ljg0OCA0MjkuNjIgNjkuNzEyIDQyNy44OTIgNzEuNDRDNDI2LjIyOCA3My4xNjggNDI1LjM5NiA3NS45NTIgNDI1LjM5NiA3OS43OTJaIiBmaWxsPSJ3aGl0ZSIvPgo8ZGVmcz4KPGNsaXBQYXRoIGlkPSJjbGlwMF8yXzY1Ij4KPHJlY3Qgd2lkdGg9IjE1MS45MyIgaGVpZ2h0PSIxMzYuNjQiIGZpbGw9IndoaXRlIiB0cmFuc2Zvcm09InRyYW5zbGF0ZSgwIDQpIi8+CjwvY2xpcFBhdGg+CjwvZGVmcz4KPC9zdmc+Cg==",Di=()=>l.jsx("img",{src:Ni,alt:"Treege",height:30,width:"auto"}),Ei=()=>{const[e,t]=S.useState({x:0,y:0}),[n,r]=S.useState({height:0,width:0}),o=S.useCallback(a=>{if(!a)return null;const{width:i,height:s}=a.getBoundingClientRect();return r({height:s,width:i}),t({x:i/2,y:s/2}),a},[]);return{dimensions:n,refContainer:o,translate:e}},Kn=({color:e,height:t=20,width:n=20})=>l.jsxs("svg",{focusable:"false",x:"0px",y:"0px",viewBox:"0 0 24 24",color:e,height:t,width:n,children:[l.jsx("path",{fill:"currentColor",d:`M19.1,18H14v2c0,1.1-0.9,2-2,2s-2-0.9-2-2v-2H4.9c-0.8,0-1.3-0.9-0.8-1.5L7,12l0,0c-0.8,0-1.3-0.9-0.8-1.6l5-7.2
|
|
28
|
-
c0.4-0.6,1.2-0.6,1.6,0l0.6,0.9c-0.8,0.8-1.2,2-1.2,3.2c0,2.6,2.1,4.7,4.7,4.7H17l3,4.5C20.4,17.1,19.9,18,19.1,18z`}),
|
|
29
|
-
c0-0.5,0.4-0.8,0.8-0.8h2.1V4.4c0-0.5,0.4-0.8,0.8-0.8s0.8,0.4,0.8,0.8v2.1h2.1C20.3,6.5,20.6,6.8,20.6,7.3z`})]}),
|
|
27
|
+
Check the top-level render call using <`+D+">.")}return T}}function qt(s,T){{if(!s._store||s._store.validated||s.key!=null)return;s._store.validated=!0;var D=Rr(T);if(Bt[D])return;Bt[D]=!0;var k="";s&&s._owner&&s._owner!==Dt.current&&(k=" It was passed a child from "+de(s._owner.type)+"."),nt(s),O('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',D,k),nt(null)}}function Wt(s,T){{if(typeof s!="object")return;if(Ft(s))for(var D=0;D<s.length;D++){var k=s[D];Et(k)&&qt(k,T)}else if(Et(s))s._store&&(s._store.validated=!0);else if(s){var J=m(s);if(typeof J=="function"&&J!==s.entries)for(var X=J.call(s),B;!(B=X.next()).done;)Et(B.value)&&qt(B.value,T)}}}function Lr(s){{var T=s.type;if(T==null||typeof T=="string")return;var D;if(typeof T=="function")D=T.propTypes;else if(typeof T=="object"&&(T.$$typeof===u||T.$$typeof===p))D=T.propTypes;else return;if(D){var k=de(T);Yn(D,s.props,"prop",k,s)}else if(T.PropTypes!==void 0&&!Nt){Nt=!0;var J=de(T);O("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",J||"Unknown")}typeof T.getDefaultProps=="function"&&!T.getDefaultProps.isReactClassApproved&&O("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function $r(s){{for(var T=Object.keys(s.props),D=0;D<T.length;D++){var k=T[D];if(k!=="children"&&k!=="key"){nt(s),O("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",k),nt(null);break}}s.ref!==null&&(nt(s),O("Invalid attribute `ref` supplied to `React.Fragment`."),nt(null))}}function C(s,T,D,k,J,X){{var B=_(s);if(!B){var q="";(s===void 0||typeof s=="object"&&s!==null&&Object.keys(s).length===0)&&(q+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var je=_r(J);je?q+=je:q+=Qt();var fe;s===null?fe="null":Ft(s)?fe="array":s!==void 0&&s.$$typeof===t?(fe="<"+(de(s.type)||"Unknown")+" />",q=" Did you accidentally export a JSX literal instead of a component?"):fe=typeof s,O("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",fe,q)}var pe=zr(s,T,D,J,X);if(pe==null)return pe;if(B){var Ie=T.children;if(Ie!==void 0)if(k)if(Ft(Ie)){for(var Be=0;Be<Ie.length;Be++)Wt(Ie[Be],s);Object.freeze&&Object.freeze(Ie)}else O("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else Wt(Ie,s)}return s===r?$r(pe):Lr(pe),pe}}function K(s,T,D){return C(s,T,D,!0)}function ie(s,T,D){return C(s,T,D,!1)}var ye=ie,Le=K;wt.Fragment=r,wt.jsx=ye,wt.jsxs=Le}()),wt}process.env.NODE_ENV==="production"?Yr.exports=hi():Yr.exports=gi();var c=Yr.exports;const ce={background:"#0a1929",borderBlue:"#0f353e",borderGrey:"rgba(255, 255, 255, 0.1)",grey500:"#868c95",primary:"#0ed3b4",secondary:"#007ef6",tertiary:"#0f353e"},mi={components:{MuiButton:{styleOverrides:{root:({ownerState:e})=>({...e.color==="primary"&&e.variant==="contained"&&{color:`${ce.tertiary} !important`}})}}},palette:{background:{default:ce.background,paper:ce.background},mode:"dark",primary:{main:ce.primary},secondary:{main:ce.secondary}}},yi=({children:e})=>c.jsxs(c.Fragment,{children:[c.jsx(y.GlobalStyles,{styles:{"*":{scrollbarColor:"rgba(255, 255, 255, 0.2) rgba(255, 255, 255, 0.05)",scrollbarWidth:"thin"},"*::-webkit-scrollbar":{height:6,width:6},"*::-webkit-scrollbar-button":{height:0,width:0},"*::-webkit-scrollbar-corner":{background:"transparent"},"*::-webkit-scrollbar-thumb":{backgroundColor:"rgba(255, 255, 255, 0.2)",border:0,borderRadius:10},"*::-webkit-scrollbar-track":{background:"rgba(255, 255, 255, 0.05)"},"html, body, #root":{height:"100%"}}}),c.jsx(y.ThemeProvider,{theme:mi,children:e})]}),vi=new lt.QueryClient({defaultOptions:{queries:{refetchOnWindowFocus:!1,retry:!1}}}),bi={authToken:void 0},Mi=N.createContext(bi),xi=({children:e,authToken:t})=>{const n=N.useMemo(()=>({authToken:t}),[t]);return c.jsx(Mi.Provider,{value:n,children:e})},Gn={dispatchSnackbar:()=>null,snackbar:{open:!1}},Kn=N.createContext(Gn),Jt={closeSnackbar:"closeSnackbar",openSnackbar:"openSnackbar"},Ti=(e,t="success")=>({message:e,severity:t,type:Jt.openSnackbar}),Jn=()=>({type:Jt.closeSnackbar}),ji=(e,t)=>{switch(t.type){case Jt.openSnackbar:{const{message:n,severity:r}=t;return{message:n,open:!0,severity:r}}case Jt.closeSnackbar:return{...e,open:!1};default:throw new Error}},Di={snackbarAlert:{width:"100%"}},Ni=({children:e})=>{const[t,n]=N.useReducer(ji,Gn.snackbar),{message:r,open:o,severity:a}=t,i=6e3,l=()=>n(Jn()),u=N.useMemo(()=>({dispatchSnackbar:n,snackbar:t}),[t,n]);return c.jsxs(Kn.Provider,{value:u,children:[c.jsx(y.Snackbar,{open:o,autoHideDuration:i,onClose:l,anchorOrigin:{horizontal:"center",vertical:"bottom"},children:c.jsx(y.Alert,{onClose:l,severity:a,sx:Di.snackbarAlert,variant:"filled",children:r})}),e]})},Ei="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNDYyIiBoZWlnaHQ9IjE0NCIgdmlld0JveD0iMCAwIDQ2MiAxNDQiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8y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xOTJDNDQ1LjQyOCAxMDYuNzA0IDQ0Mi4zNTYgMTA2Ljk2IDQzOS4wMjggMTA2Ljk2Wk00MjUuMzk2IDc5Ljc5Mkg0NDYuOTk2Vjc3LjI5NkM0NDYuOTk2IDc0LjY3MiA0NDYuMjI4IDcyLjYyNCA0NDQuNjkyIDcxLjE1MkM0NDMuMTU2IDY5LjYxNiA0NDAuNTY0IDY4Ljg0OCA0MzYuOTE2IDY4Ljg0OEM0MzIuNjI4IDY4Ljg0OCA0MjkuNjIgNjkuNzEyIDQyNy44OTIgNzEuNDRDNDI2LjIyOCA3My4xNjggNDI1LjM5NiA3NS45NTIgNDI1LjM5NiA3OS43OTJaIiBmaWxsPSJ3aGl0ZSIvPgo8ZGVmcz4KPGNsaXBQYXRoIGlkPSJjbGlwMF8yXzY1Ij4KPHJlY3Qgd2lkdGg9IjE1MS45MyIgaGVpZ2h0PSIxMzYuNjQiIGZpbGw9IndoaXRlIiB0cmFuc2Zvcm09InRyYW5zbGF0ZSgwIDQpIi8+CjwvY2xpcFBhdGg+CjwvZGVmcz4KPC9zdmc+Cg==",Oi=()=>c.jsx("img",{src:Ei,alt:"Treege",height:30,width:"auto"}),Ci=()=>{const[e,t]=N.useState({x:0,y:0}),[n,r]=N.useState({height:0,width:0}),o=N.useCallback(a=>{if(!a)return null;const{width:i,height:l}=a.getBoundingClientRect();return r({height:l,width:i}),t({x:i/2,y:l/2}),a},[]);return{dimensions:n,refContainer:o,translate:e}},Zn=({color:e,height:t=20,width:n=20})=>c.jsxs("svg",{focusable:"false",x:"0px",y:"0px",viewBox:"0 0 24 24",color:e,height:t,width:n,children:[c.jsx("path",{fill:"currentColor",d:`M19.1,18H14v2c0,1.1-0.9,2-2,2s-2-0.9-2-2v-2H4.9c-0.8,0-1.3-0.9-0.8-1.5L7,12l0,0c-0.8,0-1.3-0.9-0.8-1.6l5-7.2
|
|
28
|
+
c0.4-0.6,1.2-0.6,1.6,0l0.6,0.9c-0.8,0.8-1.2,2-1.2,3.2c0,2.6,2.1,4.7,4.7,4.7H17l3,4.5C20.4,17.1,19.9,18,19.1,18z`}),c.jsx("path",{fill:"currentColor",d:`M20.6,7.3c0,0.4-0.4,0.8-0.8,0.8h-2.1v2.1c0,0.4-0.4,0.8-0.8,0.8s-0.8-0.4-0.8-0.8V8.1H14c-0.5,0-0.8-0.4-0.8-0.8
|
|
29
|
+
c0-0.5,0.4-0.8,0.8-0.8h2.1V4.4c0-0.5,0.4-0.8,0.8-0.8s0.8,0.4,0.8,0.8v2.1h2.1C20.3,6.5,20.6,6.8,20.6,7.3z`})]}),Fe={backendConfig:{baseUrl:"",endpoints:{workflow:"/v1/workflow",workflows:"/v1/workflows"}},currentHierarchyPointNode:null,currentTree:{errorName:"",id:"",name:""},dispatchTree:()=>null,modalOpen:null,setCurrentHierarchyPointNode:()=>null,setCurrentTree:()=>null,setModalOpen:()=>null,setTreeModalOpen:()=>null,setTreePath:()=>null,tree:null,treeModalOpen:!1,treePath:[],version:""},Xn=N.createContext(Fe),Ce=()=>N.useContext(Xn),wi=()=>{const{setModalOpen:e}=Ce();return{handleClick:()=>e("add")}},Ii=()=>{const{t:e}=$e.useTranslation("button"),{handleClick:t}=wi();return c.jsx(y.Box,{alignItems:"center",justifyContent:"center",display:"flex",height:"100%",children:c.jsx(y.Button,{onClick:t,size:"medium",variant:"contained",startIcon:c.jsx(Zn,{}),children:e("createTree",{ns:"button"})})})},Zt=(e,t)=>{const{backendConfig:n}=Ce(),{endpoints:r}=n||{},{workflow:o=""}=r||{};return lt.useQuery(["workflow",e],async({signal:a})=>{const{data:i}=await ct.get(`${o}?id=${e}`,{signal:a});return i},{enabled:!!e,...t})},Fr={container:{height:"100%",width:"100%"},progressContainer:{alignItems:"center",display:"flex",height:"100%",justifyContent:"center"},treeLink:{stroke:`${ce.borderGrey} !important`}},Hn="tree-link",Ai=({data:e,renderCustomNodeElement:t,nodeSize:n={x:300,y:300}})=>{const{dimensions:r,refContainer:o,translate:a}=Ci(),{currentTree:i}=Ce(),{isInitialLoading:l,data:u}=Zt(i.id);return!e&&!i.id||u&&!e?c.jsx(Ii,{}):i.id&&!e||l?c.jsx(y.Box,{sx:Fr.progressContainer,children:c.jsx(y.CircularProgress,{})}):c.jsxs("div",{style:Fr.container,ref:o,children:[c.jsx(y.GlobalStyles,{styles:{[`.${Hn}`]:Fr.treeLink}}),c.jsx(ii,{data:e,orientation:"vertical",translate:a,dimensions:r,renderCustomNodeElement:t,pathFunc:"diagonal",pathClassFunc:()=>Hn,nodeSize:n})]})},eo=N.memo(Ai),Si=()=>({formatJSON:t=>JSON.stringify(t??{},null,2)}),to={fullHeight:{height:"100%"}},ki=({value:e})=>{const{formatJSON:t}=Si();return c.jsxs("div",{style:to.fullHeight,children:[c.jsx(y.GlobalStyles,{styles:{".cm-activeLine.cm-line, .cm-gutterElement.cm-activeLineGutter":{backgroundColor:"transparent"}}}),c.jsx(ci,{value:t(e),extensions:[si.json()],editable:!1,theme:li.dracula,height:"100%",style:to.fullHeight})]})};var Ur={},ro={exports:{}};(function(e){function t(n){return n&&n.__esModule?n:{default:n}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(ro);var Ae=ro.exports,Vr={};function Z(){return Z=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Z.apply(this,arguments)}function ot(e){return e!==null&&typeof e=="object"&&e.constructor===Object}function no(e){if(!ot(e))return e;const t={};return Object.keys(e).forEach(n=>{t[n]=no(e[n])}),t}function We(e,t,n={clone:!0}){const r=n.clone?Z({},e):e;return ot(e)&&ot(t)&&Object.keys(t).forEach(o=>{o!=="__proto__"&&(ot(t[o])&&o in e&&ot(e[o])?r[o]=We(e[o],t[o],n):n.clone?r[o]=ot(t[o])?no(t[o]):t[o]:r[o]=t[o])}),r}var Qr={exports:{}},Xt={exports:{}},te={};/** @license React v16.13.1
|
|
30
30
|
* react-is.production.min.js
|
|
31
31
|
*
|
|
32
32
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
33
33
|
*
|
|
34
34
|
* This source code is licensed under the MIT license found in the
|
|
35
35
|
* LICENSE file in the root directory of this source tree.
|
|
36
|
-
*/var
|
|
36
|
+
*/var oo;function zi(){if(oo)return te;oo=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,a=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,u=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,f=e?Symbol.for("react.forward_ref"):60112,p=e?Symbol.for("react.suspense"):60113,h=e?Symbol.for("react.suspense_list"):60120,M=e?Symbol.for("react.memo"):60115,v=e?Symbol.for("react.lazy"):60116,g=e?Symbol.for("react.block"):60121,m=e?Symbol.for("react.fundamental"):60117,x=e?Symbol.for("react.responder"):60118,O=e?Symbol.for("react.scope"):60119;function I(b){if(typeof b=="object"&&b!==null){var W=b.$$typeof;switch(W){case t:switch(b=b.type,b){case u:case d:case r:case a:case o:case p:return b;default:switch(b=b&&b.$$typeof,b){case l:case f:case v:case M:case i:return b;default:return W}}case n:return W}}}function A(b){return I(b)===d}return te.AsyncMode=u,te.ConcurrentMode=d,te.ContextConsumer=l,te.ContextProvider=i,te.Element=t,te.ForwardRef=f,te.Fragment=r,te.Lazy=v,te.Memo=M,te.Portal=n,te.Profiler=a,te.StrictMode=o,te.Suspense=p,te.isAsyncMode=function(b){return A(b)||I(b)===u},te.isConcurrentMode=A,te.isContextConsumer=function(b){return I(b)===l},te.isContextProvider=function(b){return I(b)===i},te.isElement=function(b){return typeof b=="object"&&b!==null&&b.$$typeof===t},te.isForwardRef=function(b){return I(b)===f},te.isFragment=function(b){return I(b)===r},te.isLazy=function(b){return I(b)===v},te.isMemo=function(b){return I(b)===M},te.isPortal=function(b){return I(b)===n},te.isProfiler=function(b){return I(b)===a},te.isStrictMode=function(b){return I(b)===o},te.isSuspense=function(b){return I(b)===p},te.isValidElementType=function(b){return typeof b=="string"||typeof b=="function"||b===r||b===d||b===a||b===o||b===p||b===h||typeof b=="object"&&b!==null&&(b.$$typeof===v||b.$$typeof===M||b.$$typeof===i||b.$$typeof===l||b.$$typeof===f||b.$$typeof===m||b.$$typeof===x||b.$$typeof===O||b.$$typeof===g)},te.typeOf=I,te}var re={};/** @license React v16.13.1
|
|
37
37
|
* react-is.development.js
|
|
38
38
|
*
|
|
39
39
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
40
40
|
*
|
|
41
41
|
* This source code is licensed under the MIT license found in the
|
|
42
42
|
* LICENSE file in the root directory of this source tree.
|
|
43
|
-
*/var
|
|
43
|
+
*/var ao;function _i(){return ao||(ao=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,a=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,u=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,f=e?Symbol.for("react.forward_ref"):60112,p=e?Symbol.for("react.suspense"):60113,h=e?Symbol.for("react.suspense_list"):60120,M=e?Symbol.for("react.memo"):60115,v=e?Symbol.for("react.lazy"):60116,g=e?Symbol.for("react.block"):60121,m=e?Symbol.for("react.fundamental"):60117,x=e?Symbol.for("react.responder"):60118,O=e?Symbol.for("react.scope"):60119;function I(E){return typeof E=="string"||typeof E=="function"||E===r||E===d||E===a||E===o||E===p||E===h||typeof E=="object"&&E!==null&&(E.$$typeof===v||E.$$typeof===M||E.$$typeof===i||E.$$typeof===l||E.$$typeof===f||E.$$typeof===m||E.$$typeof===x||E.$$typeof===O||E.$$typeof===g)}function A(E){if(typeof E=="object"&&E!==null){var Re=E.$$typeof;switch(Re){case t:var S=E.type;switch(S){case u:case d:case r:case a:case o:case p:return S;default:var Qe=S&&S.$$typeof;switch(Qe){case l:case f:case v:case M:case i:return Qe;default:return Re}}case n:return Re}}}var b=u,W=d,z=l,Te=i,he=t,_=f,se=r,me=v,de=M,le=n,Me=a,xe=o,Ee=p,_e=!1;function Ye(E){return _e||(_e=!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.")),j(E)||A(E)===u}function j(E){return A(E)===d}function w(E){return A(E)===l}function L(E){return A(E)===i}function $(E){return typeof E=="object"&&E!==null&&E.$$typeof===t}function R(E){return A(E)===f}function U(E){return A(E)===r}function P(E){return A(E)===v}function F(E){return A(E)===M}function Y(E){return A(E)===n}function Q(E){return A(E)===a}function V(E){return A(E)===o}function Ne(E){return A(E)===p}re.AsyncMode=b,re.ConcurrentMode=W,re.ContextConsumer=z,re.ContextProvider=Te,re.Element=he,re.ForwardRef=_,re.Fragment=se,re.Lazy=me,re.Memo=de,re.Portal=le,re.Profiler=Me,re.StrictMode=xe,re.Suspense=Ee,re.isAsyncMode=Ye,re.isConcurrentMode=j,re.isContextConsumer=w,re.isContextProvider=L,re.isElement=$,re.isForwardRef=R,re.isFragment=U,re.isLazy=P,re.isMemo=F,re.isPortal=Y,re.isProfiler=Q,re.isStrictMode=V,re.isSuspense=Ne,re.isValidElementType=I,re.typeOf=A}()),re}var io;function so(){return io||(io=1,process.env.NODE_ENV==="production"?Xt.exports=zi():Xt.exports=_i()),Xt.exports}/*
|
|
44
44
|
object-assign
|
|
45
45
|
(c) Sindre Sorhus
|
|
46
46
|
@license MIT
|
|
47
|
-
*/var
|
|
48
|
-
Valid keys: `+JSON.stringify(Object.keys(j),null," "));var
|
|
47
|
+
*/var Br,lo;function Ri(){if(lo)return Br;lo=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;function r(a){if(a==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(a)}function o(){try{if(!Object.assign)return!1;var a=new String("abc");if(a[5]="de",Object.getOwnPropertyNames(a)[0]==="5")return!1;for(var i={},l=0;l<10;l++)i["_"+String.fromCharCode(l)]=l;var u=Object.getOwnPropertyNames(i).map(function(f){return i[f]});if(u.join("")!=="0123456789")return!1;var d={};return"abcdefghijklmnopqrst".split("").forEach(function(f){d[f]=f}),Object.keys(Object.assign({},d)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return Br=o()?Object.assign:function(a,i){for(var l,u=r(a),d,f=1;f<arguments.length;f++){l=Object(arguments[f]);for(var p in l)t.call(l,p)&&(u[p]=l[p]);if(e){d=e(l);for(var h=0;h<d.length;h++)n.call(l,d[h])&&(u[d[h]]=l[d[h]])}}return u},Br}var qr,co;function Wr(){if(co)return qr;co=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return qr=e,qr}var Gr,uo;function fo(){return uo||(uo=1,Gr=Function.call.bind(Object.prototype.hasOwnProperty)),Gr}var Kr,po;function Li(){if(po)return Kr;po=1;var e=function(){};if(process.env.NODE_ENV!=="production"){var t=Wr(),n={},r=fo();e=function(a){var i="Warning: "+a;typeof console<"u"&&console.error(i);try{throw new Error(i)}catch{}}}function o(a,i,l,u,d){if(process.env.NODE_ENV!=="production"){for(var f in a)if(r(a,f)){var p;try{if(typeof a[f]!="function"){var h=Error((u||"React class")+": "+l+" type `"+f+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof a[f]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw h.name="Invariant Violation",h}p=a[f](i,f,u,l,null,t)}catch(v){p=v}if(p&&!(p instanceof Error)&&e((u||"React class")+": type specification of "+l+" `"+f+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof p+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),p instanceof Error&&!(p.message in n)){n[p.message]=!0;var M=d?d():"";e("Failed "+l+" type: "+p.message+(M??""))}}}}return o.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(n={})},Kr=o,Kr}var Jr,ho;function $i(){if(ho)return Jr;ho=1;var e=so(),t=Ri(),n=Wr(),r=fo(),o=Li(),a=function(){};process.env.NODE_ENV!=="production"&&(a=function(l){var u="Warning: "+l;typeof console<"u"&&console.error(u);try{throw new Error(u)}catch{}});function i(){return null}return Jr=function(l,u){var d=typeof Symbol=="function"&&Symbol.iterator,f="@@iterator";function p(j){var w=j&&(d&&j[d]||j[f]);if(typeof w=="function")return w}var h="<<anonymous>>",M={array:x("array"),bigint:x("bigint"),bool:x("boolean"),func:x("function"),number:x("number"),object:x("object"),string:x("string"),symbol:x("symbol"),any:O(),arrayOf:I,element:A(),elementType:b(),instanceOf:W,node:_(),objectOf:Te,oneOf:z,oneOfType:he,shape:me,exact:de};function v(j,w){return j===w?j!==0||1/j===1/w:j!==j&&w!==w}function g(j,w){this.message=j,this.data=w&&typeof w=="object"?w:{},this.stack=""}g.prototype=Error.prototype;function m(j){if(process.env.NODE_ENV!=="production")var w={},L=0;function $(U,P,F,Y,Q,V,Ne){if(Y=Y||h,V=V||F,Ne!==n){if(u){var E=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 E.name="Invariant Violation",E}else if(process.env.NODE_ENV!=="production"&&typeof console<"u"){var Re=Y+":"+F;!w[Re]&&L<3&&(a("You are manually calling a React.PropTypes validation function for the `"+V+"` prop on `"+Y+"`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."),w[Re]=!0,L++)}}return P[F]==null?U?P[F]===null?new g("The "+Q+" `"+V+"` is marked as required "+("in `"+Y+"`, but its value is `null`.")):new g("The "+Q+" `"+V+"` is marked as required in "+("`"+Y+"`, but its value is `undefined`.")):null:j(P,F,Y,Q,V)}var R=$.bind(null,!1);return R.isRequired=$.bind(null,!0),R}function x(j){function w(L,$,R,U,P,F){var Y=L[$],Q=xe(Y);if(Q!==j){var V=Ee(Y);return new g("Invalid "+U+" `"+P+"` of type "+("`"+V+"` supplied to `"+R+"`, expected ")+("`"+j+"`."),{expectedType:j})}return null}return m(w)}function O(){return m(i)}function I(j){function w(L,$,R,U,P){if(typeof j!="function")return new g("Property `"+P+"` of component `"+R+"` has invalid PropType notation inside arrayOf.");var F=L[$];if(!Array.isArray(F)){var Y=xe(F);return new g("Invalid "+U+" `"+P+"` of type "+("`"+Y+"` supplied to `"+R+"`, expected an array."))}for(var Q=0;Q<F.length;Q++){var V=j(F,Q,R,U,P+"["+Q+"]",n);if(V instanceof Error)return V}return null}return m(w)}function A(){function j(w,L,$,R,U){var P=w[L];if(!l(P)){var F=xe(P);return new g("Invalid "+R+" `"+U+"` of type "+("`"+F+"` supplied to `"+$+"`, expected a single ReactElement."))}return null}return m(j)}function b(){function j(w,L,$,R,U){var P=w[L];if(!e.isValidElementType(P)){var F=xe(P);return new g("Invalid "+R+" `"+U+"` of type "+("`"+F+"` supplied to `"+$+"`, expected a single ReactElement type."))}return null}return m(j)}function W(j){function w(L,$,R,U,P){if(!(L[$]instanceof j)){var F=j.name||h,Y=Ye(L[$]);return new g("Invalid "+U+" `"+P+"` of type "+("`"+Y+"` supplied to `"+R+"`, expected ")+("instance of `"+F+"`."))}return null}return m(w)}function z(j){if(!Array.isArray(j))return process.env.NODE_ENV!=="production"&&(arguments.length>1?a("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):a("Invalid argument supplied to oneOf, expected an array.")),i;function w(L,$,R,U,P){for(var F=L[$],Y=0;Y<j.length;Y++)if(v(F,j[Y]))return null;var Q=JSON.stringify(j,function(Ne,E){var Re=Ee(E);return Re==="symbol"?String(E):E});return new g("Invalid "+U+" `"+P+"` of value `"+String(F)+"` "+("supplied to `"+R+"`, expected one of "+Q+"."))}return m(w)}function Te(j){function w(L,$,R,U,P){if(typeof j!="function")return new g("Property `"+P+"` of component `"+R+"` has invalid PropType notation inside objectOf.");var F=L[$],Y=xe(F);if(Y!=="object")return new g("Invalid "+U+" `"+P+"` of type "+("`"+Y+"` supplied to `"+R+"`, expected an object."));for(var Q in F)if(r(F,Q)){var V=j(F,Q,R,U,P+"."+Q,n);if(V instanceof Error)return V}return null}return m(w)}function he(j){if(!Array.isArray(j))return process.env.NODE_ENV!=="production"&&a("Invalid argument supplied to oneOfType, expected an instance of array."),i;for(var w=0;w<j.length;w++){var L=j[w];if(typeof L!="function")return a("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+_e(L)+" at index "+w+"."),i}function $(R,U,P,F,Y){for(var Q=[],V=0;V<j.length;V++){var Ne=j[V],E=Ne(R,U,P,F,Y,n);if(E==null)return null;E.data&&r(E.data,"expectedType")&&Q.push(E.data.expectedType)}var Re=Q.length>0?", expected one of type ["+Q.join(", ")+"]":"";return new g("Invalid "+F+" `"+Y+"` supplied to "+("`"+P+"`"+Re+"."))}return m($)}function _(){function j(w,L,$,R,U){return le(w[L])?null:new g("Invalid "+R+" `"+U+"` supplied to "+("`"+$+"`, expected a ReactNode."))}return m(j)}function se(j,w,L,$,R){return new g((j||"React class")+": "+w+" type `"+L+"."+$+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+R+"`.")}function me(j){function w(L,$,R,U,P){var F=L[$],Y=xe(F);if(Y!=="object")return new g("Invalid "+U+" `"+P+"` of type `"+Y+"` "+("supplied to `"+R+"`, expected `object`."));for(var Q in j){var V=j[Q];if(typeof V!="function")return se(R,U,P,Q,Ee(V));var Ne=V(F,Q,R,U,P+"."+Q,n);if(Ne)return Ne}return null}return m(w)}function de(j){function w(L,$,R,U,P){var F=L[$],Y=xe(F);if(Y!=="object")return new g("Invalid "+U+" `"+P+"` of type `"+Y+"` "+("supplied to `"+R+"`, expected `object`."));var Q=t({},L[$],j);for(var V in Q){var Ne=j[V];if(r(j,V)&&typeof Ne!="function")return se(R,U,P,V,Ee(Ne));if(!Ne)return new g("Invalid "+U+" `"+P+"` key `"+V+"` supplied to `"+R+"`.\nBad object: "+JSON.stringify(L[$],null," ")+`
|
|
48
|
+
Valid keys: `+JSON.stringify(Object.keys(j),null," "));var E=Ne(F,V,R,U,P+"."+V,n);if(E)return E}return null}return m(w)}function le(j){switch(typeof j){case"number":case"string":case"undefined":return!0;case"boolean":return!j;case"object":if(Array.isArray(j))return j.every(le);if(j===null||l(j))return!0;var w=p(j);if(w){var L=w.call(j),$;if(w!==j.entries){for(;!($=L.next()).done;)if(!le($.value))return!1}else for(;!($=L.next()).done;){var R=$.value;if(R&&!le(R[1]))return!1}}else return!1;return!0;default:return!1}}function Me(j,w){return j==="symbol"?!0:w?w["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&w instanceof Symbol:!1}function xe(j){var w=typeof j;return Array.isArray(j)?"array":j instanceof RegExp?"object":Me(w,j)?"symbol":w}function Ee(j){if(typeof j>"u"||j===null)return""+j;var w=xe(j);if(w==="object"){if(j instanceof Date)return"date";if(j instanceof RegExp)return"regexp"}return w}function _e(j){var w=Ee(j);switch(w){case"array":case"object":return"an "+w;case"boolean":case"date":case"regexp":return"a "+w;default:return w}}function Ye(j){return!j.constructor||!j.constructor.name?h:j.constructor.name}return M.checkPropTypes=o,M.resetWarningCache=o.resetWarningCache,M.PropTypes=M,M},Jr}var Zr,go;function Pi(){if(go)return Zr;go=1;var e=Wr();function t(){}function n(){}return n.resetWarningCache=t,Zr=function(){function r(i,l,u,d,f,p){if(p!==e){var h=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 h.name="Invariant Violation",h}}r.isRequired=r;function o(){return r}var a={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return a.PropTypes=a,a},Zr}if(process.env.NODE_ENV!=="production"){var Yi=so(),Fi=!0;Qr.exports=$i()(Yi.isElement,Fi)}else Qr.exports=Pi()();var Ui=Qr.exports;const ue=fi(Ui);function ut(e){let t="https://mui.com/production-error/?code="+e;for(let n=1;n<arguments.length;n+=1)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified MUI error #"+e+"; visit "+t+" for the full message."}var Xr={exports:{}},ne={};/**
|
|
49
49
|
* @license React
|
|
50
50
|
* react-is.production.min.js
|
|
51
51
|
*
|
|
@@ -53,7 +53,7 @@ Valid keys: `+JSON.stringify(Object.keys(j),null," "));var O=je(P,U,L,Q,k+"."+U
|
|
|
53
53
|
*
|
|
54
54
|
* This source code is licensed under the MIT license found in the
|
|
55
55
|
* LICENSE file in the root directory of this source tree.
|
|
56
|
-
*/var
|
|
56
|
+
*/var mo;function Vi(){if(mo)return ne;mo=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),a=Symbol.for("react.provider"),i=Symbol.for("react.context"),l=Symbol.for("react.server_context"),u=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),f=Symbol.for("react.suspense_list"),p=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),M=Symbol.for("react.offscreen"),v;v=Symbol.for("react.module.reference");function g(m){if(typeof m=="object"&&m!==null){var x=m.$$typeof;switch(x){case e:switch(m=m.type,m){case n:case o:case r:case d:case f:return m;default:switch(m=m&&m.$$typeof,m){case l:case i:case u:case h:case p:case a:return m;default:return x}}case t:return x}}}return ne.ContextConsumer=i,ne.ContextProvider=a,ne.Element=e,ne.ForwardRef=u,ne.Fragment=n,ne.Lazy=h,ne.Memo=p,ne.Portal=t,ne.Profiler=o,ne.StrictMode=r,ne.Suspense=d,ne.SuspenseList=f,ne.isAsyncMode=function(){return!1},ne.isConcurrentMode=function(){return!1},ne.isContextConsumer=function(m){return g(m)===i},ne.isContextProvider=function(m){return g(m)===a},ne.isElement=function(m){return typeof m=="object"&&m!==null&&m.$$typeof===e},ne.isForwardRef=function(m){return g(m)===u},ne.isFragment=function(m){return g(m)===n},ne.isLazy=function(m){return g(m)===h},ne.isMemo=function(m){return g(m)===p},ne.isPortal=function(m){return g(m)===t},ne.isProfiler=function(m){return g(m)===o},ne.isStrictMode=function(m){return g(m)===r},ne.isSuspense=function(m){return g(m)===d},ne.isSuspenseList=function(m){return g(m)===f},ne.isValidElementType=function(m){return typeof m=="string"||typeof m=="function"||m===n||m===o||m===r||m===d||m===f||m===M||typeof m=="object"&&m!==null&&(m.$$typeof===h||m.$$typeof===p||m.$$typeof===a||m.$$typeof===i||m.$$typeof===u||m.$$typeof===v||m.getModuleId!==void 0)},ne.typeOf=g,ne}var oe={};/**
|
|
57
57
|
* @license React
|
|
58
58
|
* react-is.development.js
|
|
59
59
|
*
|
|
@@ -61,37 +61,37 @@ Valid keys: `+JSON.stringify(Object.keys(j),null," "));var O=je(P,U,L,Q,k+"."+U
|
|
|
61
61
|
*
|
|
62
62
|
* This source code is licensed under the MIT license found in the
|
|
63
63
|
* LICENSE file in the root directory of this source tree.
|
|
64
|
-
*/var
|
|
65
|
-
`))},[r,n,e]);const{current:d}=
|
|
66
|
-
`))},[JSON.stringify(t)])}const u=
|
|
67
|
-
`+r+"\n\n`@import` rules must be before all other types of rules in a stylesheet but other rules have already been inserted. Please ensure that `@import` rules are before all other rules."),this._alreadyInsertedOrderInsensitiveRule=this._alreadyInsertedOrderInsensitiveRule||!a}if(this.isSpeedy){var i=ys(o);try{i.insertRule(r,i.cssRules.length)}catch(s){process.env.NODE_ENV!=="production"&&!/:(-moz-placeholder|-moz-focus-inner|-moz-focusring|-ms-input-placeholder|-moz-read-write|-moz-read-only|-ms-clear|-ms-expand|-ms-reveal){/.test(r)&&console.error('There was a problem inserting the following rule: "'+r+'"',s)}}else o.appendChild(document.createTextNode(r));this.ctr++},t.flush=function(){this.tags.forEach(function(r){return r.parentNode&&r.parentNode.removeChild(r)}),this.tags=[],this.ctr=0,process.env.NODE_ENV!=="production"&&(this._alreadyInsertedOrderInsensitiveRule=!1)},e}(),ke="-ms-",er="-moz-",X="-webkit-",tn="comm",rn="rule",nn="decl",Ms="@import",Co="@keyframes",xs="@layer",Ts=Math.abs,tr=String.fromCharCode,js=Object.assign;function Ns(e,t){return Ce(e,0)^45?(((t<<2^Ce(e,0))<<2^Ce(e,1))<<2^Ce(e,2))<<2^Ce(e,3):0}function Ao(e){return e.trim()}function Ds(e,t){return(e=t.exec(e))?e[0]:e}function H(e,t,n){return e.replace(t,n)}function on(e,t){return e.indexOf(t)}function Ce(e,t){return e.charCodeAt(t)|0}function kt(e,t,n){return e.slice(t,n)}function He(e){return e.length}function an(e){return e.length}function rr(e,t){return t.push(e),e}function Es(e,t){return e.map(t).join("")}var nr=1,gt=1,So=0,Ye=0,Te=0,mt="";function or(e,t,n,r,o,a,i){return{value:e,root:t,parent:n,type:r,props:o,children:a,line:nr,column:gt,length:i,return:""}}function _t(e,t){return js(or("",null,null,"",null,null,0),e,{length:-e.length},t)}function Os(){return Te}function ws(){return Te=Ye>0?Ce(mt,--Ye):0,gt--,Te===10&&(gt=1,nr--),Te}function Qe(){return Te=Ye<So?Ce(mt,Ye++):0,gt++,Te===10&&(gt=1,nr++),Te}function et(){return Ce(mt,Ye)}function ar(){return Ye}function Rt(e,t){return kt(mt,e,t)}function Lt(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function zo(e){return nr=gt=1,So=He(mt=e),Ye=0,[]}function ko(e){return mt="",e}function ir(e){return Ao(Rt(Ye-1,sn(e===91?e+2:e===40?e+1:e)))}function Is(e){for(;(Te=et())&&Te<33;)Qe();return Lt(e)>2||Lt(Te)>3?"":" "}function Cs(e,t){for(;--t&&Qe()&&!(Te<48||Te>102||Te>57&&Te<65||Te>70&&Te<97););return Rt(e,ar()+(t<6&&et()==32&&Qe()==32))}function sn(e){for(;Qe();)switch(Te){case e:return Ye;case 34:case 39:e!==34&&e!==39&&sn(Te);break;case 40:e===41&&sn(e);break;case 92:Qe();break}return Ye}function As(e,t){for(;Qe()&&e+Te!==47+10;)if(e+Te===42+42&&et()===47)break;return"/*"+Rt(t,Ye-1)+"*"+tr(e===47?e:Qe())}function Ss(e){for(;!Lt(et());)Qe();return Rt(e,Ye)}function zs(e){return ko(sr("",null,null,null,[""],e=zo(e),0,[0],e))}function sr(e,t,n,r,o,a,i,s,u){for(var d=0,f=0,h=i,p=0,M=0,v=0,g=1,m=1,x=1,N=0,I="",C=o,b=a,q=r,_=I;m;)switch(v=N,N=Qe()){case 40:if(v!=108&&Ce(_,h-1)==58){on(_+=H(ir(N),"&","&\f"),"&\f")!=-1&&(x=-1);break}case 34:case 39:case 91:_+=ir(N);break;case 9:case 10:case 13:case 32:_+=Is(v);break;case 92:_+=Cs(ar()-1,7);continue;case 47:switch(et()){case 42:case 47:rr(ks(As(Qe(),ar()),t,n),u);break;default:_+="/"}break;case 123*g:s[d++]=He(_)*x;case 125*g:case 59:case 0:switch(N){case 0:case 125:m=0;case 59+f:x==-1&&(_=H(_,/\f/g,"")),M>0&&He(_)-h&&rr(M>32?Ro(_+";",r,n,h-1):Ro(H(_," ","")+";",r,n,h-2),u);break;case 59:_+=";";default:if(rr(q=_o(_,t,n,d,f,o,s,I,C=[],b=[],h),a),N===123)if(f===0)sr(_,t,q,q,C,a,h,s,b);else switch(p===99&&Ce(_,3)===110?100:p){case 100:case 108:case 109:case 115:sr(e,q,q,r&&rr(_o(e,q,q,0,0,o,s,I,o,C=[],h),b),o,b,h,s,r?C:b);break;default:sr(_,q,q,q,[""],b,0,s,b)}}d=f=M=0,g=x=1,I=_="",h=i;break;case 58:h=1+He(_),M=v;default:if(g<1){if(N==123)--g;else if(N==125&&g++==0&&ws()==125)continue}switch(_+=tr(N),N*g){case 38:x=f>0?1:(_+="\f",-1);break;case 44:s[d++]=(He(_)-1)*x,x=1;break;case 64:et()===45&&(_+=ir(Qe())),p=et(),f=h=He(I=_+=Ss(ar())),N++;break;case 45:v===45&&He(_)==2&&(g=0)}}return a}function _o(e,t,n,r,o,a,i,s,u,d,f){for(var h=o-1,p=o===0?a:[""],M=an(p),v=0,g=0,m=0;v<r;++v)for(var x=0,N=kt(e,h+1,h=Ts(g=i[v])),I=e;x<M;++x)(I=Ao(g>0?p[x]+" "+N:H(N,/&\f/g,p[x])))&&(u[m++]=I);return or(e,t,n,o===0?rn:s,u,d,f)}function ks(e,t,n){return or(e,t,n,tn,tr(Os()),kt(e,2,-2),0)}function Ro(e,t,n,r){return or(e,t,n,nn,kt(e,0,r),kt(e,r+1,-1),r)}function yt(e,t){for(var n="",r=an(e),o=0;o<r;o++)n+=t(e[o],o,e,t)||"";return n}function _s(e,t,n,r){switch(e.type){case xs:if(e.children.length)break;case Ms:case nn:return e.return=e.return||e.value;case tn:return"";case Co:return e.return=e.value+"{"+yt(e.children,r)+"}";case rn:e.value=e.props.join(",")}return He(n=yt(e.children,r))?e.return=e.value+"{"+n+"}":""}function Rs(e){var t=an(e);return function(n,r,o,a){for(var i="",s=0;s<t;s++)i+=e[s](n,r,o,a)||"";return i}}function Ls(e){return function(t){t.root||(t=t.return)&&e(t)}}var $s=function(t,n,r){for(var o=0,a=0;o=a,a=et(),o===38&&a===12&&(n[r]=1),!Lt(a);)Qe();return Rt(t,Ye)},Ps=function(t,n){var r=-1,o=44;do switch(Lt(o)){case 0:o===38&&et()===12&&(n[r]=1),t[r]+=$s(Ye-1,n,r);break;case 2:t[r]+=ir(o);break;case 4:if(o===44){t[++r]=et()===58?"&\f":"",n[r]=t[r].length;break}default:t[r]+=tr(o)}while(o=Qe());return t},Ys=function(t,n){return ko(Ps(zo(t),n))},Lo=new WeakMap,Us=function(t){if(!(t.type!=="rule"||!t.parent||t.length<1)){for(var n=t.value,r=t.parent,o=t.column===r.column&&t.line===r.line;r.type!=="rule";)if(r=r.parent,!r)return;if(!(t.props.length===1&&n.charCodeAt(0)!==58&&!Lo.get(r))&&!o){Lo.set(t,!0);for(var a=[],i=Ys(n,a),s=r.props,u=0,d=0;u<i.length;u++)for(var f=0;f<s.length;f++,d++)t.props[d]=a[u]?i[u].replace(/&\f/g,s[f]):s[f]+" "+i[u]}}},Fs=function(t){if(t.type==="decl"){var n=t.value;n.charCodeAt(0)===108&&n.charCodeAt(2)===98&&(t.return="",t.value="")}},Vs="emotion-disable-server-rendering-unsafe-selector-warning-please-do-not-use-this-the-warning-exists-for-a-reason",Qs=function(t){return t.type==="comm"&&t.children.indexOf(Vs)>-1},Bs=function(t){return function(n,r,o){if(!(n.type!=="rule"||t.compat)){var a=n.value.match(/(:first|:nth|:nth-last)-child/g);if(a){for(var i=!!n.parent,s=i?n.parent.children:o,u=s.length-1;u>=0;u--){var d=s[u];if(d.line<n.line)break;if(d.column<n.column){if(Qs(d))return;break}}a.forEach(function(f){console.error('The pseudo class "'+f+'" is potentially unsafe when doing server-side rendering. Try changing it to "'+f.split("-child")[0]+'-of-type".')})}}}},$o=function(t){return t.type.charCodeAt(1)===105&&t.type.charCodeAt(0)===64},qs=function(t,n){for(var r=t-1;r>=0;r--)if(!$o(n[r]))return!0;return!1},Po=function(t){t.type="",t.value="",t.return="",t.children="",t.props=""},Ws=function(t,n,r){$o(t)&&(t.parent?(console.error("`@import` rules can't be nested inside other rules. Please move it to the top level and put it before regular rules. Keep in mind that they can only be used within global styles."),Po(t)):qs(n,r)&&(console.error("`@import` rules can't be after other rules. Please put your `@import` rules before your other rules."),Po(t)))};function Yo(e,t){switch(Ns(e,t)){case 5103:return X+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return X+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return X+e+er+e+ke+e+e;case 6828:case 4268:return X+e+ke+e+e;case 6165:return X+e+ke+"flex-"+e+e;case 5187:return X+e+H(e,/(\w+).+(:[^]+)/,X+"box-$1$2"+ke+"flex-$1$2")+e;case 5443:return X+e+ke+"flex-item-"+H(e,/flex-|-self/,"")+e;case 4675:return X+e+ke+"flex-line-pack"+H(e,/align-content|flex-|-self/,"")+e;case 5548:return X+e+ke+H(e,"shrink","negative")+e;case 5292:return X+e+ke+H(e,"basis","preferred-size")+e;case 6060:return X+"box-"+H(e,"-grow","")+X+e+ke+H(e,"grow","positive")+e;case 4554:return X+H(e,/([^-])(transform)/g,"$1"+X+"$2")+e;case 6187:return H(H(H(e,/(zoom-|grab)/,X+"$1"),/(image-set)/,X+"$1"),e,"")+e;case 5495:case 3959:return H(e,/(image-set\([^]*)/,X+"$1$`$1");case 4968:return H(H(e,/(.+:)(flex-)?(.*)/,X+"box-pack:$3"+ke+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+X+e+e;case 4095:case 3583:case 4068:case 2532:return H(e,/(.+)-inline(.+)/,X+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(He(e)-1-t>6)switch(Ce(e,t+1)){case 109:if(Ce(e,t+4)!==45)break;case 102:return H(e,/(.+:)(.+)-([^]+)/,"$1"+X+"$2-$3$1"+er+(Ce(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~on(e,"stretch")?Yo(H(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(Ce(e,t+1)!==115)break;case 6444:switch(Ce(e,He(e)-3-(~on(e,"!important")&&10))){case 107:return H(e,":",":"+X)+e;case 101:return H(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+X+(Ce(e,14)===45?"inline-":"")+"box$3$1"+X+"$2$3$1"+ke+"$2box$3")+e}break;case 5936:switch(Ce(e,t+11)){case 114:return X+e+ke+H(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return X+e+ke+H(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return X+e+ke+H(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return X+e+ke+e+e}return e}var Gs=function(t,n,r,o){if(t.length>-1&&!t.return)switch(t.type){case nn:t.return=Yo(t.value,t.length);break;case Co:return yt([_t(t,{value:H(t.value,"@","@"+X)})],o);case rn:if(t.length)return Es(t.props,function(a){switch(Ds(a,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return yt([_t(t,{props:[H(a,/:(read-\w+)/,":"+er+"$1")]})],o);case"::placeholder":return yt([_t(t,{props:[H(a,/:(plac\w+)/,":"+X+"input-$1")]}),_t(t,{props:[H(a,/:(plac\w+)/,":"+er+"$1")]}),_t(t,{props:[H(a,/:(plac\w+)/,ke+"input-$1")]})],o)}return""})}},Ks=[Gs],Js=function(t){var n=t.key;if(process.env.NODE_ENV!=="production"&&!n)throw new Error(`You have to configure \`key\` for your cache. Please make sure it's unique (and not equal to 'css') as it's used for linking styles to your cache.
|
|
68
|
-
If multiple caches share the same key they might "fight" for each other's style elements.`);if(n==="css"){var r=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(r,function(g){var m=g.getAttribute("data-emotion");m.indexOf(" ")!==-1&&(document.head.appendChild(g),g.setAttribute("data-s",""))})}var o=t.stylisPlugins||
|
|
64
|
+
*/var yo;function Qi(){return yo||(yo=1,process.env.NODE_ENV!=="production"&&function(){var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),a=Symbol.for("react.provider"),i=Symbol.for("react.context"),l=Symbol.for("react.server_context"),u=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),f=Symbol.for("react.suspense_list"),p=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),M=Symbol.for("react.offscreen"),v=!1,g=!1,m=!1,x=!1,O=!1,I;I=Symbol.for("react.module.reference");function A(S){return!!(typeof S=="string"||typeof S=="function"||S===n||S===o||O||S===r||S===d||S===f||x||S===M||v||g||m||typeof S=="object"&&S!==null&&(S.$$typeof===h||S.$$typeof===p||S.$$typeof===a||S.$$typeof===i||S.$$typeof===u||S.$$typeof===I||S.getModuleId!==void 0))}function b(S){if(typeof S=="object"&&S!==null){var Qe=S.$$typeof;switch(Qe){case e:var Je=S.type;switch(Je){case n:case o:case r:case d:case f:return Je;default:var it=Je&&Je.$$typeof;switch(it){case l:case i:case u:case h:case p:case a:return it;default:return Qe}}case t:return Qe}}}var W=i,z=a,Te=e,he=u,_=n,se=h,me=p,de=t,le=o,Me=r,xe=d,Ee=f,_e=!1,Ye=!1;function j(S){return _e||(_e=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1}function w(S){return Ye||(Ye=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1}function L(S){return b(S)===i}function $(S){return b(S)===a}function R(S){return typeof S=="object"&&S!==null&&S.$$typeof===e}function U(S){return b(S)===u}function P(S){return b(S)===n}function F(S){return b(S)===h}function Y(S){return b(S)===p}function Q(S){return b(S)===t}function V(S){return b(S)===o}function Ne(S){return b(S)===r}function E(S){return b(S)===d}function Re(S){return b(S)===f}oe.ContextConsumer=W,oe.ContextProvider=z,oe.Element=Te,oe.ForwardRef=he,oe.Fragment=_,oe.Lazy=se,oe.Memo=me,oe.Portal=de,oe.Profiler=le,oe.StrictMode=Me,oe.Suspense=xe,oe.SuspenseList=Ee,oe.isAsyncMode=j,oe.isConcurrentMode=w,oe.isContextConsumer=L,oe.isContextProvider=$,oe.isElement=R,oe.isForwardRef=U,oe.isFragment=P,oe.isLazy=F,oe.isMemo=Y,oe.isPortal=Q,oe.isProfiler=V,oe.isStrictMode=Ne,oe.isSuspense=E,oe.isSuspenseList=Re,oe.isValidElementType=A,oe.typeOf=b}()),oe}process.env.NODE_ENV==="production"?Xr.exports=Vi():Xr.exports=Qi();var vo=Xr.exports;const Bi=/^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/;function qi(e){const t=`${e}`.match(Bi);return t&&t[1]||""}function bo(e,t=""){return e.displayName||e.name||qi(e)||t}function Mo(e,t,n){const r=bo(t);return e.displayName||(r!==""?`${n}(${r})`:n)}function Wi(e){if(e!=null){if(typeof e=="string")return e;if(typeof e=="function")return bo(e,"Component");if(typeof e=="object")switch(e.$$typeof){case vo.ForwardRef:return Mo(e,e.render,"ForwardRef");case vo.Memo:return Mo(e,e.type,"memo");default:return}}}function Ge(e){if(typeof e!="string")throw new Error(process.env.NODE_ENV!=="production"?"MUI: `capitalize(string)` expects a string argument.":ut(7));return e.charAt(0).toUpperCase()+e.slice(1)}function Gi(...e){return e.reduce((t,n)=>n==null?t:function(...o){t.apply(this,o),n.apply(this,o)},()=>{})}function Ki(e,t=166){let n;function r(...o){const a=()=>{e.apply(this,o)};clearTimeout(n),n=setTimeout(a,t)}return r.clear=()=>{clearTimeout(n)},r}function Ji(e,t){return process.env.NODE_ENV==="production"?()=>null:(n,r,o,a,i)=>{const l=o||"<<anonymous>>",u=i||r;return typeof n[r]<"u"?new Error(`The ${a} \`${u}\` of \`${l}\` is deprecated. ${t}`):null}}function Zi(e,t){var n,r;return G.isValidElement(e)&&t.indexOf((n=e.type.muiName)!=null?n:(r=e.type)==null||(r=r._payload)==null||(r=r.value)==null?void 0:r.muiName)!==-1}function xo(e){return e&&e.ownerDocument||document}function Xi(e){return xo(e).defaultView||window}function Hi(e,t){if(process.env.NODE_ENV==="production")return()=>null;const n=t?Z({},t.propTypes):null;return o=>(a,i,l,u,d,...f)=>{const p=d||i,h=n==null?void 0:n[p];if(h){const M=h(a,i,l,u,d,...f);if(M)return M}return typeof a[i]<"u"&&!a[o]?new Error(`The prop \`${p}\` of \`${e}\` can only be used together with the \`${o}\` prop.`):null}}function To(e,t){typeof e=="function"?e(t):e&&(e.current=t)}const jo=typeof window<"u"?G.useLayoutEffect:G.useEffect;let Do=0;function es(e){const[t,n]=G.useState(e),r=e||t;return G.useEffect(()=>{t==null&&(Do+=1,n(`mui-${Do}`))},[t]),r}const No=G["useId".toString()];function ts(e){if(No!==void 0){const t=No();return e??t}return es(e)}function rs(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const a=o||t;return typeof e[t]<"u"?new Error(`The prop \`${a}\` is not supported. Please remove it.`):null}function ns({controlled:e,default:t,name:n,state:r="value"}){const{current:o}=G.useRef(e!==void 0),[a,i]=G.useState(t),l=o?e:a;if(process.env.NODE_ENV!=="production"){G.useEffect(()=>{o!==(e!==void 0)&&console.error([`MUI: A component is changing the ${o?"":"un"}controlled ${r} state of ${n} to be ${o?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(`
|
|
65
|
+
`))},[r,n,e]);const{current:d}=G.useRef(t);G.useEffect(()=>{!o&&d!==t&&console.error([`MUI: A component is changing the default ${r} state of an uncontrolled ${n} after being initialized. To suppress this warning opt to use a controlled ${n}.`].join(`
|
|
66
|
+
`))},[JSON.stringify(t)])}const u=G.useCallback(d=>{o||i(d)},[]);return[l,u]}function os(e){const t=G.useRef(e);return jo(()=>{t.current=e}),G.useCallback((...n)=>(0,t.current)(...n),[])}function as(...e){return G.useMemo(()=>e.every(t=>t==null)?null:t=>{e.forEach(n=>{To(n,t)})},e)}let Ht=!0,Hr=!1,Eo;const is={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function ss(e){const{type:t,tagName:n}=e;return!!(n==="INPUT"&&is[t]&&!e.readOnly||n==="TEXTAREA"&&!e.readOnly||e.isContentEditable)}function ls(e){e.metaKey||e.altKey||e.ctrlKey||(Ht=!0)}function en(){Ht=!1}function cs(){this.visibilityState==="hidden"&&Hr&&(Ht=!0)}function us(e){e.addEventListener("keydown",ls,!0),e.addEventListener("mousedown",en,!0),e.addEventListener("pointerdown",en,!0),e.addEventListener("touchstart",en,!0),e.addEventListener("visibilitychange",cs,!0)}function ds(e){const{target:t}=e;try{return t.matches(":focus-visible")}catch{}return Ht||ss(t)}function fs(){const e=G.useCallback(o=>{o!=null&&us(o.ownerDocument)},[]),t=G.useRef(!1);function n(){return t.current?(Hr=!0,window.clearTimeout(Eo),Eo=window.setTimeout(()=>{Hr=!1},100),t.current=!1,!0):!1}function r(o){return ds(o)?(t.current=!0,!0):!1}return{isFocusVisibleRef:t,onFocus:r,onBlur:n,ref:e}}function Oo(e,t){const n=Z({},t);return Object.keys(e).forEach(r=>{if(r.toString().match(/^(components|slots)$/))n[r]=Z({},e[r],n[r]);else if(r.toString().match(/^(componentsProps|slotProps)$/)){const o=e[r]||{},a=t[r];n[r]={},!a||!Object.keys(a)?n[r]=o:!o||!Object.keys(o)?n[r]=a:(n[r]=Z({},a),Object.keys(o).forEach(i=>{n[r][i]=Oo(o[i],a[i])}))}else n[r]===void 0&&(n[r]=e[r])}),n}function ps(e,t,n=void 0){const r={};return Object.keys(e).forEach(o=>{r[o]=e[o].reduce((a,i)=>{if(i){const l=t(i);l!==""&&a.push(l),n&&n[i]&&a.push(n[i])}return a},[]).join(" ")}),r}const Co=e=>e,wo=(()=>{let e=Co;return{configure(t){e=t},generate(t){return e(t)},reset(){e=Co}}})(),hs={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 tn(e,t,n="Mui"){const r=hs[t];return r?`${n}-${r}`:`${wo.generate(e)}-${t}`}function gs(e,t,n="Mui"){const r={};return t.forEach(o=>{r[o]=tn(e,o,n)}),r}function tt(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,a;for(a=0;a<r.length;a++)o=r[a],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function Io(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(n=Io(e[t]))&&(r&&(r+=" "),r+=n);else for(t in e)e[t]&&(r&&(r+=" "),r+=t);return r}function ms(){for(var e,t,n=0,r="";n<arguments.length;)(e=arguments[n++])&&(t=Io(e))&&(r&&(r+=" "),r+=t);return r}function Ao(e){var t=Object.create(null);return function(n){return t[n]===void 0&&(t[n]=e(n)),t[n]}}var ys=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|enterKeyHint|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,vs=Ao(function(e){return ys.test(e)||e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)<91});function bs(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}function Ms(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),e.nonce!==void 0&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}var xs=function(){function e(n){var r=this;this._insertTag=function(o){var a;r.tags.length===0?r.insertionPoint?a=r.insertionPoint.nextSibling:r.prepend?a=r.container.firstChild:a=r.before:a=r.tags[r.tags.length-1].nextSibling,r.container.insertBefore(o,a),r.tags.push(o)},this.isSpeedy=n.speedy===void 0?process.env.NODE_ENV==="production":n.speedy,this.tags=[],this.ctr=0,this.nonce=n.nonce,this.key=n.key,this.container=n.container,this.prepend=n.prepend,this.insertionPoint=n.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(r){r.forEach(this._insertTag)},t.insert=function(r){this.ctr%(this.isSpeedy?65e3:1)===0&&this._insertTag(Ms(this));var o=this.tags[this.tags.length-1];if(process.env.NODE_ENV!=="production"){var a=r.charCodeAt(0)===64&&r.charCodeAt(1)===105;a&&this._alreadyInsertedOrderInsensitiveRule&&console.error(`You're attempting to insert the following rule:
|
|
67
|
+
`+r+"\n\n`@import` rules must be before all other types of rules in a stylesheet but other rules have already been inserted. Please ensure that `@import` rules are before all other rules."),this._alreadyInsertedOrderInsensitiveRule=this._alreadyInsertedOrderInsensitiveRule||!a}if(this.isSpeedy){var i=bs(o);try{i.insertRule(r,i.cssRules.length)}catch(l){process.env.NODE_ENV!=="production"&&!/:(-moz-placeholder|-moz-focus-inner|-moz-focusring|-ms-input-placeholder|-moz-read-write|-moz-read-only|-ms-clear|-ms-expand|-ms-reveal){/.test(r)&&console.error('There was a problem inserting the following rule: "'+r+'"',l)}}else o.appendChild(document.createTextNode(r));this.ctr++},t.flush=function(){this.tags.forEach(function(r){return r.parentNode&&r.parentNode.removeChild(r)}),this.tags=[],this.ctr=0,process.env.NODE_ENV!=="production"&&(this._alreadyInsertedOrderInsensitiveRule=!1)},e}(),ze="-ms-",er="-moz-",H="-webkit-",rn="comm",nn="rule",on="decl",Ts="@import",So="@keyframes",js="@layer",Ds=Math.abs,tr=String.fromCharCode,Ns=Object.assign;function Es(e,t){return Se(e,0)^45?(((t<<2^Se(e,0))<<2^Se(e,1))<<2^Se(e,2))<<2^Se(e,3):0}function ko(e){return e.trim()}function Os(e,t){return(e=t.exec(e))?e[0]:e}function ee(e,t,n){return e.replace(t,n)}function an(e,t){return e.indexOf(t)}function Se(e,t){return e.charCodeAt(t)|0}function It(e,t,n){return e.slice(t,n)}function Ze(e){return e.length}function sn(e){return e.length}function rr(e,t){return t.push(e),e}function Cs(e,t){return e.map(t).join("")}var nr=1,dt=1,zo=0,Pe=0,De=0,ft="";function or(e,t,n,r,o,a,i){return{value:e,root:t,parent:n,type:r,props:o,children:a,line:nr,column:dt,length:i,return:""}}function At(e,t){return Ns(or("",null,null,"",null,null,0),e,{length:-e.length},t)}function ws(){return De}function Is(){return De=Pe>0?Se(ft,--Pe):0,dt--,De===10&&(dt=1,nr--),De}function Ue(){return De=Pe<zo?Se(ft,Pe++):0,dt++,De===10&&(dt=1,nr++),De}function Xe(){return Se(ft,Pe)}function ar(){return Pe}function St(e,t){return It(ft,e,t)}function kt(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function _o(e){return nr=dt=1,zo=Ze(ft=e),Pe=0,[]}function Ro(e){return ft="",e}function ir(e){return ko(St(Pe-1,ln(e===91?e+2:e===40?e+1:e)))}function As(e){for(;(De=Xe())&&De<33;)Ue();return kt(e)>2||kt(De)>3?"":" "}function Ss(e,t){for(;--t&&Ue()&&!(De<48||De>102||De>57&&De<65||De>70&&De<97););return St(e,ar()+(t<6&&Xe()==32&&Ue()==32))}function ln(e){for(;Ue();)switch(De){case e:return Pe;case 34:case 39:e!==34&&e!==39&&ln(De);break;case 40:e===41&&ln(e);break;case 92:Ue();break}return Pe}function ks(e,t){for(;Ue()&&e+De!==47+10;)if(e+De===42+42&&Xe()===47)break;return"/*"+St(t,Pe-1)+"*"+tr(e===47?e:Ue())}function zs(e){for(;!kt(Xe());)Ue();return St(e,Pe)}function _s(e){return Ro(sr("",null,null,null,[""],e=_o(e),0,[0],e))}function sr(e,t,n,r,o,a,i,l,u){for(var d=0,f=0,p=i,h=0,M=0,v=0,g=1,m=1,x=1,O=0,I="",A=o,b=a,W=r,z=I;m;)switch(v=O,O=Ue()){case 40:if(v!=108&&Se(z,p-1)==58){an(z+=ee(ir(O),"&","&\f"),"&\f")!=-1&&(x=-1);break}case 34:case 39:case 91:z+=ir(O);break;case 9:case 10:case 13:case 32:z+=As(v);break;case 92:z+=Ss(ar()-1,7);continue;case 47:switch(Xe()){case 42:case 47:rr(Rs(ks(Ue(),ar()),t,n),u);break;default:z+="/"}break;case 123*g:l[d++]=Ze(z)*x;case 125*g:case 59:case 0:switch(O){case 0:case 125:m=0;case 59+f:x==-1&&(z=ee(z,/\f/g,"")),M>0&&Ze(z)-p&&rr(M>32?$o(z+";",r,n,p-1):$o(ee(z," ","")+";",r,n,p-2),u);break;case 59:z+=";";default:if(rr(W=Lo(z,t,n,d,f,o,l,I,A=[],b=[],p),a),O===123)if(f===0)sr(z,t,W,W,A,a,p,l,b);else switch(h===99&&Se(z,3)===110?100:h){case 100:case 108:case 109:case 115:sr(e,W,W,r&&rr(Lo(e,W,W,0,0,o,l,I,o,A=[],p),b),o,b,p,l,r?A:b);break;default:sr(z,W,W,W,[""],b,0,l,b)}}d=f=M=0,g=x=1,I=z="",p=i;break;case 58:p=1+Ze(z),M=v;default:if(g<1){if(O==123)--g;else if(O==125&&g++==0&&Is()==125)continue}switch(z+=tr(O),O*g){case 38:x=f>0?1:(z+="\f",-1);break;case 44:l[d++]=(Ze(z)-1)*x,x=1;break;case 64:Xe()===45&&(z+=ir(Ue())),h=Xe(),f=p=Ze(I=z+=zs(ar())),O++;break;case 45:v===45&&Ze(z)==2&&(g=0)}}return a}function Lo(e,t,n,r,o,a,i,l,u,d,f){for(var p=o-1,h=o===0?a:[""],M=sn(h),v=0,g=0,m=0;v<r;++v)for(var x=0,O=It(e,p+1,p=Ds(g=i[v])),I=e;x<M;++x)(I=ko(g>0?h[x]+" "+O:ee(O,/&\f/g,h[x])))&&(u[m++]=I);return or(e,t,n,o===0?nn:l,u,d,f)}function Rs(e,t,n){return or(e,t,n,rn,tr(ws()),It(e,2,-2),0)}function $o(e,t,n,r){return or(e,t,n,on,It(e,0,r),It(e,r+1,-1),r)}function pt(e,t){for(var n="",r=sn(e),o=0;o<r;o++)n+=t(e[o],o,e,t)||"";return n}function Ls(e,t,n,r){switch(e.type){case js:if(e.children.length)break;case Ts:case on:return e.return=e.return||e.value;case rn:return"";case So:return e.return=e.value+"{"+pt(e.children,r)+"}";case nn:e.value=e.props.join(",")}return Ze(n=pt(e.children,r))?e.return=e.value+"{"+n+"}":""}function $s(e){var t=sn(e);return function(n,r,o,a){for(var i="",l=0;l<t;l++)i+=e[l](n,r,o,a)||"";return i}}function Ps(e){return function(t){t.root||(t=t.return)&&e(t)}}var Ys=function(t,n,r){for(var o=0,a=0;o=a,a=Xe(),o===38&&a===12&&(n[r]=1),!kt(a);)Ue();return St(t,Pe)},Fs=function(t,n){var r=-1,o=44;do switch(kt(o)){case 0:o===38&&Xe()===12&&(n[r]=1),t[r]+=Ys(Pe-1,n,r);break;case 2:t[r]+=ir(o);break;case 4:if(o===44){t[++r]=Xe()===58?"&\f":"",n[r]=t[r].length;break}default:t[r]+=tr(o)}while(o=Ue());return t},Us=function(t,n){return Ro(Fs(_o(t),n))},Po=new WeakMap,Vs=function(t){if(!(t.type!=="rule"||!t.parent||t.length<1)){for(var n=t.value,r=t.parent,o=t.column===r.column&&t.line===r.line;r.type!=="rule";)if(r=r.parent,!r)return;if(!(t.props.length===1&&n.charCodeAt(0)!==58&&!Po.get(r))&&!o){Po.set(t,!0);for(var a=[],i=Us(n,a),l=r.props,u=0,d=0;u<i.length;u++)for(var f=0;f<l.length;f++,d++)t.props[d]=a[u]?i[u].replace(/&\f/g,l[f]):l[f]+" "+i[u]}}},Qs=function(t){if(t.type==="decl"){var n=t.value;n.charCodeAt(0)===108&&n.charCodeAt(2)===98&&(t.return="",t.value="")}},Bs="emotion-disable-server-rendering-unsafe-selector-warning-please-do-not-use-this-the-warning-exists-for-a-reason",qs=function(t){return t.type==="comm"&&t.children.indexOf(Bs)>-1},Ws=function(t){return function(n,r,o){if(!(n.type!=="rule"||t.compat)){var a=n.value.match(/(:first|:nth|:nth-last)-child/g);if(a){for(var i=!!n.parent,l=i?n.parent.children:o,u=l.length-1;u>=0;u--){var d=l[u];if(d.line<n.line)break;if(d.column<n.column){if(qs(d))return;break}}a.forEach(function(f){console.error('The pseudo class "'+f+'" is potentially unsafe when doing server-side rendering. Try changing it to "'+f.split("-child")[0]+'-of-type".')})}}}},Yo=function(t){return t.type.charCodeAt(1)===105&&t.type.charCodeAt(0)===64},Gs=function(t,n){for(var r=t-1;r>=0;r--)if(!Yo(n[r]))return!0;return!1},Fo=function(t){t.type="",t.value="",t.return="",t.children="",t.props=""},Ks=function(t,n,r){Yo(t)&&(t.parent?(console.error("`@import` rules can't be nested inside other rules. Please move it to the top level and put it before regular rules. Keep in mind that they can only be used within global styles."),Fo(t)):Gs(n,r)&&(console.error("`@import` rules can't be after other rules. Please put your `@import` rules before your other rules."),Fo(t)))};function Uo(e,t){switch(Es(e,t)){case 5103:return H+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return H+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return H+e+er+e+ze+e+e;case 6828:case 4268:return H+e+ze+e+e;case 6165:return H+e+ze+"flex-"+e+e;case 5187:return H+e+ee(e,/(\w+).+(:[^]+)/,H+"box-$1$2"+ze+"flex-$1$2")+e;case 5443:return H+e+ze+"flex-item-"+ee(e,/flex-|-self/,"")+e;case 4675:return H+e+ze+"flex-line-pack"+ee(e,/align-content|flex-|-self/,"")+e;case 5548:return H+e+ze+ee(e,"shrink","negative")+e;case 5292:return H+e+ze+ee(e,"basis","preferred-size")+e;case 6060:return H+"box-"+ee(e,"-grow","")+H+e+ze+ee(e,"grow","positive")+e;case 4554:return H+ee(e,/([^-])(transform)/g,"$1"+H+"$2")+e;case 6187:return ee(ee(ee(e,/(zoom-|grab)/,H+"$1"),/(image-set)/,H+"$1"),e,"")+e;case 5495:case 3959:return ee(e,/(image-set\([^]*)/,H+"$1$`$1");case 4968:return ee(ee(e,/(.+:)(flex-)?(.*)/,H+"box-pack:$3"+ze+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+H+e+e;case 4095:case 3583:case 4068:case 2532:return ee(e,/(.+)-inline(.+)/,H+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(Ze(e)-1-t>6)switch(Se(e,t+1)){case 109:if(Se(e,t+4)!==45)break;case 102:return ee(e,/(.+:)(.+)-([^]+)/,"$1"+H+"$2-$3$1"+er+(Se(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~an(e,"stretch")?Uo(ee(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(Se(e,t+1)!==115)break;case 6444:switch(Se(e,Ze(e)-3-(~an(e,"!important")&&10))){case 107:return ee(e,":",":"+H)+e;case 101:return ee(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+H+(Se(e,14)===45?"inline-":"")+"box$3$1"+H+"$2$3$1"+ze+"$2box$3")+e}break;case 5936:switch(Se(e,t+11)){case 114:return H+e+ze+ee(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return H+e+ze+ee(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return H+e+ze+ee(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return H+e+ze+e+e}return e}var Js=function(t,n,r,o){if(t.length>-1&&!t.return)switch(t.type){case on:t.return=Uo(t.value,t.length);break;case So:return pt([At(t,{value:ee(t.value,"@","@"+H)})],o);case nn:if(t.length)return Cs(t.props,function(a){switch(Os(a,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return pt([At(t,{props:[ee(a,/:(read-\w+)/,":"+er+"$1")]})],o);case"::placeholder":return pt([At(t,{props:[ee(a,/:(plac\w+)/,":"+H+"input-$1")]}),At(t,{props:[ee(a,/:(plac\w+)/,":"+er+"$1")]}),At(t,{props:[ee(a,/:(plac\w+)/,ze+"input-$1")]})],o)}return""})}},Zs=[Js],Xs=function(t){var n=t.key;if(process.env.NODE_ENV!=="production"&&!n)throw new Error(`You have to configure \`key\` for your cache. Please make sure it's unique (and not equal to 'css') as it's used for linking styles to your cache.
|
|
68
|
+
If multiple caches share the same key they might "fight" for each other's style elements.`);if(n==="css"){var r=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(r,function(g){var m=g.getAttribute("data-emotion");m.indexOf(" ")!==-1&&(document.head.appendChild(g),g.setAttribute("data-s",""))})}var o=t.stylisPlugins||Zs;if(process.env.NODE_ENV!=="production"&&/[^a-z-]/.test(n))throw new Error('Emotion key must only contain lower case alphabetical characters and - but "'+n+'" was passed');var a={},i,l=[];i=t.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+n+' "]'),function(g){for(var m=g.getAttribute("data-emotion").split(" "),x=1;x<m.length;x++)a[m[x]]=!0;l.push(g)});var u,d=[Vs,Qs];process.env.NODE_ENV!=="production"&&d.push(Ws({get compat(){return v.compat}}),Ks);{var f,p=[Ls,process.env.NODE_ENV!=="production"?function(g){g.root||(g.return?f.insert(g.return):g.value&&g.type!==rn&&f.insert(g.value+"{}"))}:Ps(function(g){f.insert(g)})],h=$s(d.concat(o,p)),M=function(m){return pt(_s(m),h)};u=function(m,x,O,I){f=O,process.env.NODE_ENV!=="production"&&x.map!==void 0&&(f={insert:function(b){O.insert(b+x.map)}}),M(m?m+"{"+x.styles+"}":x.styles),I&&(v.inserted[x.name]=!0)}}var v={key:n,sheet:new xs({key:n,container:i,nonce:t.nonce,speedy:t.speedy,prepend:t.prepend,insertionPoint:t.insertionPoint}),nonce:t.nonce,inserted:a,registered:{},insert:u};return v.sheet.hydrate(l),v},Hs=!0;function Vo(e,t,n){var r="";return n.split(" ").forEach(function(o){e[o]!==void 0?t.push(e[o]+";"):r+=o+" "}),r}var cn=function(t,n,r){var o=t.key+"-"+n.name;(r===!1||Hs===!1)&&t.registered[o]===void 0&&(t.registered[o]=n.styles)},Qo=function(t,n,r){cn(t,n,r);var o=t.key+"-"+n.name;if(t.inserted[n.name]===void 0){var a=n;do t.insert(n===a?"."+o:"",a,t.sheet,!0),a=a.next;while(a!==void 0)}};function el(e){for(var t=0,n,r=0,o=e.length;o>=4;++r,o-=4)n=e.charCodeAt(r)&255|(e.charCodeAt(++r)&255)<<8|(e.charCodeAt(++r)&255)<<16|(e.charCodeAt(++r)&255)<<24,n=(n&65535)*1540483477+((n>>>16)*59797<<16),n^=n>>>24,t=(n&65535)*1540483477+((n>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(o){case 3:t^=(e.charCodeAt(r+2)&255)<<16;case 2:t^=(e.charCodeAt(r+1)&255)<<8;case 1:t^=e.charCodeAt(r)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var tl={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,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},Bo=`You have illegal escape sequence in your template literal, most likely inside content's property value.
|
|
69
69
|
Because you write your CSS inside a JavaScript string you actually have to do double escaping, so for example "content: '\\00d7';" should become "content: '\\\\00d7';".
|
|
70
70
|
You can read more about this here:
|
|
71
|
-
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_literals#ES2018_revision_of_illegal_escape_sequences`,
|
|
71
|
+
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_literals#ES2018_revision_of_illegal_escape_sequences`,rl="You have passed in falsy value as style object's key (can happen when in example you pass unexported component as computed key).",nl=/[A-Z]|^ms/g,qo=/_EMO_([^_]+?)_([^]*?)_EMO_/g,un=function(t){return t.charCodeAt(1)===45},Wo=function(t){return t!=null&&typeof t!="boolean"},dn=Ao(function(e){return un(e)?e:e.replace(nl,"-$&").toLowerCase()}),lr=function(t,n){switch(t){case"animation":case"animationName":if(typeof n=="string")return n.replace(qo,function(r,o,a){return Ke={name:o,styles:a,next:Ke},o})}return tl[t]!==1&&!un(t)&&typeof n=="number"&&n!==0?n+"px":n};if(process.env.NODE_ENV!=="production"){var ol=/(var|attr|counters?|url|element|(((repeating-)?(linear|radial))|conic)-gradient)\(|(no-)?(open|close)-quote/,al=["normal","none","initial","inherit","unset"],il=lr,sl=/^-ms-/,ll=/-(.)/g,Go={};lr=function(t,n){if(t==="content"&&(typeof n!="string"||al.indexOf(n)===-1&&!ol.test(n)&&(n.charAt(0)!==n.charAt(n.length-1)||n.charAt(0)!=='"'&&n.charAt(0)!=="'")))throw new Error("You seem to be using a value for 'content' without quotes, try replacing it with `content: '\""+n+"\"'`");var r=il(t,n);return r!==""&&!un(t)&&t.indexOf("-")!==-1&&Go[t]===void 0&&(Go[t]=!0,console.error("Using kebab-case for css properties in objects is not supported. Did you mean "+t.replace(sl,"ms-").replace(ll,function(o,a){return a.toUpperCase()})+"?")),r}}var Ko="Component selectors can only be used in conjunction with @emotion/babel-plugin, the swc Emotion plugin, or another Emotion-aware compiler transform.";function zt(e,t,n){if(n==null)return"";if(n.__emotion_styles!==void 0){if(process.env.NODE_ENV!=="production"&&n.toString()==="NO_COMPONENT_SELECTOR")throw new Error(Ko);return n}switch(typeof n){case"boolean":return"";case"object":{if(n.anim===1)return Ke={name:n.name,styles:n.styles,next:Ke},n.name;if(n.styles!==void 0){var r=n.next;if(r!==void 0)for(;r!==void 0;)Ke={name:r.name,styles:r.styles,next:Ke},r=r.next;var o=n.styles+";";return process.env.NODE_ENV!=="production"&&n.map!==void 0&&(o+=n.map),o}return cl(e,t,n)}case"function":{if(e!==void 0){var a=Ke,i=n(e);return Ke=a,zt(e,t,i)}else process.env.NODE_ENV!=="production"&&console.error("Functions that are interpolated in css calls will be stringified.\nIf you want to have a css call based on props, create a function that returns a css call like this\nlet dynamicStyle = (props) => css`color: ${props.color}`\nIt can be called directly with props or interpolated in a styled call like this\nlet SomeComponent = styled('div')`${dynamicStyle}`");break}case"string":if(process.env.NODE_ENV!=="production"){var l=[],u=n.replace(qo,function(f,p,h){var M="animation"+l.length;return l.push("const "+M+" = keyframes`"+h.replace(/^@keyframes animation-\w+/,"")+"`"),"${"+M+"}"});l.length&&console.error("`keyframes` output got interpolated into plain string, please wrap it with `css`.\n\nInstead of doing this:\n\n"+[].concat(l,["`"+u+"`"]).join(`
|
|
72
72
|
`)+`
|
|
73
73
|
|
|
74
74
|
You should wrap it with \`css\` like this:
|
|
75
75
|
|
|
76
|
-
`+("css`"+u+"`"))}break}if(t==null)return n;var d=t[n];return d!==void 0?d:n}function
|
|
76
|
+
`+("css`"+u+"`"))}break}if(t==null)return n;var d=t[n];return d!==void 0?d:n}function cl(e,t,n){var r="";if(Array.isArray(n))for(var o=0;o<n.length;o++)r+=zt(e,t,n[o])+";";else for(var a in n){var i=n[a];if(typeof i!="object")t!=null&&t[i]!==void 0?r+=a+"{"+t[i]+"}":Wo(i)&&(r+=dn(a)+":"+lr(a,i)+";");else{if(a==="NO_COMPONENT_SELECTOR"&&process.env.NODE_ENV!=="production")throw new Error(Ko);if(Array.isArray(i)&&typeof i[0]=="string"&&(t==null||t[i[0]]===void 0))for(var l=0;l<i.length;l++)Wo(i[l])&&(r+=dn(a)+":"+lr(a,i[l])+";");else{var u=zt(e,t,i);switch(a){case"animation":case"animationName":{r+=dn(a)+":"+u+";";break}default:process.env.NODE_ENV!=="production"&&a==="undefined"&&console.error(rl),r+=a+"{"+u+"}"}}}}return r}var Jo=/label:\s*([^\s;\n{]+)\s*(;|$)/g,Zo;process.env.NODE_ENV!=="production"&&(Zo=/\/\*#\ssourceMappingURL=data:application\/json;\S+\s+\*\//g);var Ke,fn=function(t,n,r){if(t.length===1&&typeof t[0]=="object"&&t[0]!==null&&t[0].styles!==void 0)return t[0];var o=!0,a="";Ke=void 0;var i=t[0];i==null||i.raw===void 0?(o=!1,a+=zt(r,n,i)):(process.env.NODE_ENV!=="production"&&i[0]===void 0&&console.error(Bo),a+=i[0]);for(var l=1;l<t.length;l++)a+=zt(r,n,t[l]),o&&(process.env.NODE_ENV!=="production"&&i[l]===void 0&&console.error(Bo),a+=i[l]);var u;process.env.NODE_ENV!=="production"&&(a=a.replace(Zo,function(h){return u=h,""})),Jo.lastIndex=0;for(var d="",f;(f=Jo.exec(a))!==null;)d+="-"+f[1];var p=el(a)+d;return process.env.NODE_ENV!=="production"?{name:p,styles:a,map:u,next:Ke,toString:function(){return"You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop)."}}:{name:p,styles:a,next:Ke}},ul=function(t){return t()},dl=G["useInsertionEffect"]?G["useInsertionEffect"]:!1,Xo=dl||ul,fl={}.hasOwnProperty,pn=G.createContext(typeof HTMLElement<"u"?Xs({key:"css"}):null);process.env.NODE_ENV!=="production"&&(pn.displayName="EmotionCacheContext"),pn.Provider;var Ho=function(t){return N.forwardRef(function(n,r){var o=N.useContext(pn);return t(n,o,r)})},cr=G.createContext({});process.env.NODE_ENV!=="production"&&(cr.displayName="EmotionThemeContext");var ea="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",ta="__EMOTION_LABEL_PLEASE_DO_NOT_USE__",pl=function(t){var n=t.cache,r=t.serialized,o=t.isStringTag;return cn(n,r,o),Xo(function(){return Qo(n,r,o)}),null},hl=Ho(function(e,t,n){var r=e.css;typeof r=="string"&&t.registered[r]!==void 0&&(r=t.registered[r]);var o=e[ea],a=[r],i="";typeof e.className=="string"?i=Vo(t.registered,a,e.className):e.className!=null&&(i=e.className+" ");var l=fn(a,void 0,G.useContext(cr));if(process.env.NODE_ENV!=="production"&&l.name.indexOf("-")===-1){var u=e[ta];u&&(l=fn([l,"label:"+u+";"]))}i+=t.key+"-"+l.name;var d={};for(var f in e)fl.call(e,f)&&f!=="css"&&f!==ea&&(process.env.NODE_ENV==="production"||f!==ta)&&(d[f]=e[f]);return d.ref=n,d.className=i,G.createElement(G.Fragment,null,G.createElement(pl,{cache:t,serialized:l,isStringTag:typeof o=="string"}),G.createElement(o,d))});process.env.NODE_ENV!=="production"&&(hl.displayName="EmotionCssPropInternal");var gl=vs,ml=function(t){return t!=="theme"},ra=function(t){return typeof t=="string"&&t.charCodeAt(0)>96?gl:ml},na=function(t,n,r){var o;if(n){var a=n.shouldForwardProp;o=t.__emotion_forwardProp&&a?function(i){return t.__emotion_forwardProp(i)&&a(i)}:a}return typeof o!="function"&&r&&(o=t.__emotion_forwardProp),o},oa=`You have illegal escape sequence in your template literal, most likely inside content's property value.
|
|
77
77
|
Because you write your CSS inside a JavaScript string you actually have to do double escaping, so for example "content: '\\00d7';" should become "content: '\\\\00d7';".
|
|
78
78
|
You can read more about this here:
|
|
79
|
-
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_literals#ES2018_revision_of_illegal_escape_sequences`,
|
|
80
|
-
You may have forgotten to import it.`);var r=t.__emotion_real===t,o=r&&t.__emotion_base||t,a,i;n!==void 0&&(a=n.label,i=n.target);var
|
|
79
|
+
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_literals#ES2018_revision_of_illegal_escape_sequences`,yl=function(t){var n=t.cache,r=t.serialized,o=t.isStringTag;return cn(n,r,o),Xo(function(){return Qo(n,r,o)}),null},vl=function e(t,n){if(process.env.NODE_ENV!=="production"&&t===void 0)throw new Error(`You are trying to create a styled element with an undefined component.
|
|
80
|
+
You may have forgotten to import it.`);var r=t.__emotion_real===t,o=r&&t.__emotion_base||t,a,i;n!==void 0&&(a=n.label,i=n.target);var l=na(t,n,r),u=l||ra(o),d=!u("as");return function(){var f=arguments,p=r&&t.__emotion_styles!==void 0?t.__emotion_styles.slice(0):[];if(a!==void 0&&p.push("label:"+a+";"),f[0]==null||f[0].raw===void 0)p.push.apply(p,f);else{process.env.NODE_ENV!=="production"&&f[0][0]===void 0&&console.error(oa),p.push(f[0][0]);for(var h=f.length,M=1;M<h;M++)process.env.NODE_ENV!=="production"&&f[0][M]===void 0&&console.error(oa),p.push(f[M],f[0][M])}var v=Ho(function(g,m,x){var O=d&&g.as||o,I="",A=[],b=g;if(g.theme==null){b={};for(var W in g)b[W]=g[W];b.theme=G.useContext(cr)}typeof g.className=="string"?I=Vo(m.registered,A,g.className):g.className!=null&&(I=g.className+" ");var z=fn(p.concat(A),m.registered,b);I+=m.key+"-"+z.name,i!==void 0&&(I+=" "+i);var Te=d&&l===void 0?ra(O):u,he={};for(var _ in g)d&&_==="as"||Te(_)&&(he[_]=g[_]);return he.className=I,he.ref=x,G.createElement(G.Fragment,null,G.createElement(yl,{cache:m,serialized:z,isStringTag:typeof O=="string"}),G.createElement(O,he))});return v.displayName=a!==void 0?a:"Styled("+(typeof o=="string"?o:o.displayName||o.name||"Component")+")",v.defaultProps=t.defaultProps,v.__emotion_real=v,v.__emotion_base=o,v.__emotion_styles=p,v.__emotion_forwardProp=l,Object.defineProperty(v,"toString",{value:function(){return i===void 0&&process.env.NODE_ENV!=="production"?"NO_COMPONENT_SELECTOR":"."+i}}),v.withComponent=function(g,m){return e(g,Z({},n,m,{shouldForwardProp:na(v,m,!0)})).apply(void 0,p)},v}},bl=["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","marquee","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"],hn=vl.bind();bl.forEach(function(e){hn[e]=hn(e)});/**
|
|
81
81
|
* @mui/styled-engine v5.14.12
|
|
82
82
|
*
|
|
83
83
|
* @license MIT
|
|
84
84
|
* This source code is licensed under the MIT license found in the
|
|
85
85
|
* LICENSE file in the root directory of this source tree.
|
|
86
|
-
*/function
|
|
87
|
-
`)):r.some(a=>a===void 0)&&console.error(`MUI: the styled(${o})(...args) API requires all its args to be defined.`),n(...r)}:n}const
|
|
86
|
+
*/function Ml(e,t){const n=hn(e,t);return process.env.NODE_ENV!=="production"?(...r)=>{const o=typeof e=="string"?`"${e}"`:"component";return r.length===0?console.error([`MUI: Seems like you called \`styled(${o})()\` without a \`style\` argument.`,'You must provide a `styles` argument: `styled("div")(styleYouForgotToPass)`.'].join(`
|
|
87
|
+
`)):r.some(a=>a===void 0)&&console.error(`MUI: the styled(${o})(...args) API requires all its args to be defined.`),n(...r)}:n}const xl=(e,t)=>{Array.isArray(e.__emotion_styles)&&(e.__emotion_styles=t(e.__emotion_styles))},Tl=["values","unit","step"],jl=e=>{const t=Object.keys(e).map(n=>({key:n,val:e[n]}))||[];return t.sort((n,r)=>n.val-r.val),t.reduce((n,r)=>Z({},n,{[r.key]:r.val}),{})};function Dl(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:n="px",step:r=5}=e,o=tt(e,Tl),a=jl(t),i=Object.keys(a);function l(h){return`@media (min-width:${typeof t[h]=="number"?t[h]:h}${n})`}function u(h){return`@media (max-width:${(typeof t[h]=="number"?t[h]:h)-r/100}${n})`}function d(h,M){const v=i.indexOf(M);return`@media (min-width:${typeof t[h]=="number"?t[h]:h}${n}) and (max-width:${(v!==-1&&typeof t[i[v]]=="number"?t[i[v]]:M)-r/100}${n})`}function f(h){return i.indexOf(h)+1<i.length?d(h,i[i.indexOf(h)+1]):l(h)}function p(h){const M=i.indexOf(h);return M===0?l(i[1]):M===i.length-1?u(i[M]):d(h,i[i.indexOf(h)+1]).replace("@media","@media not all and")}return Z({keys:i,values:a,up:l,down:u,between:d,only:f,not:p,unit:n},o)}const Nl={borderRadius:4},at=process.env.NODE_ENV!=="production"?ue.oneOfType([ue.number,ue.string,ue.object,ue.array]):{};function _t(e,t){return t?We(e,t,{clone:!1}):e}const gn={xs:0,sm:600,md:900,lg:1200,xl:1536},aa={keys:["xs","sm","md","lg","xl"],up:e=>`@media (min-width:${gn[e]}px)`};function rt(e,t,n){const r=e.theme||{};if(Array.isArray(t)){const a=r.breakpoints||aa;return t.reduce((i,l,u)=>(i[a.up(a.keys[u])]=n(t[u]),i),{})}if(typeof t=="object"){const a=r.breakpoints||aa;return Object.keys(t).reduce((i,l)=>{if(Object.keys(a.values||gn).indexOf(l)!==-1){const u=a.up(l);i[u]=n(t[l],l)}else{const u=l;i[u]=t[u]}return i},{})}return n(t)}function El(e={}){var t;return((t=e.keys)==null?void 0:t.reduce((r,o)=>{const a=e.up(o);return r[a]={},r},{}))||{}}function Ol(e,t){return e.reduce((n,r)=>{const o=n[r];return(!o||Object.keys(o).length===0)&&delete n[r],n},t)}function ur(e,t,n=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&n){const r=`vars.${t}`.split(".").reduce((o,a)=>o&&o[a]?o[a]:null,e);if(r!=null)return r}return t.split(".").reduce((r,o)=>r&&r[o]!=null?r[o]:null,e)}function dr(e,t,n,r=n){let o;return typeof e=="function"?o=e(n):Array.isArray(e)?o=e[n]||r:o=ur(e,n)||r,t&&(o=t(o,r,e)),o}function ae(e){const{prop:t,cssProperty:n=e.prop,themeKey:r,transform:o}=e,a=i=>{if(i[t]==null)return null;const l=i[t],u=i.theme,d=ur(u,r)||{};return rt(i,l,p=>{let h=dr(d,o,p);return p===h&&typeof p=="string"&&(h=dr(d,o,`${t}${p==="default"?"":Ge(p)}`,p)),n===!1?h:{[n]:h}})};return a.propTypes=process.env.NODE_ENV!=="production"?{[t]:at}:{},a.filterProps=[t],a}function Cl(e){const t={};return n=>(t[n]===void 0&&(t[n]=e(n)),t[n])}const wl={m:"margin",p:"padding"},Il={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},ia={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},Al=Cl(e=>{if(e.length>2)if(ia[e])e=ia[e];else return[e];const[t,n]=e.split(""),r=wl[t],o=Il[n]||"";return Array.isArray(o)?o.map(a=>r+a):[r+o]}),fr=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],pr=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],Sl=[...fr,...pr];function Rt(e,t,n,r){var o;const a=(o=ur(e,t,!1))!=null?o:n;return typeof a=="number"?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&typeof i!="number"&&console.error(`MUI: Expected ${r} argument to be a number or a string, got ${i}.`),a*i):Array.isArray(a)?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&(Number.isInteger(i)?i>a.length-1&&console.error([`MUI: The value provided (${i}) overflows.`,`The supported values are: ${JSON.stringify(a)}.`,`${i} > ${a.length-1}, you need to add the missing values.`].join(`
|
|
88
88
|
`)):console.error([`MUI: The \`theme.${t}\` array type cannot be combined with non integer values.You should either use an integer value that can be used as index, or define the \`theme.${t}\` as a number.`].join(`
|
|
89
89
|
`))),a[i]):typeof a=="function"?a:(process.env.NODE_ENV!=="production"&&console.error([`MUI: The \`theme.${t}\` value (${a}) is invalid.`,"It should be a number, an array or a function."].join(`
|
|
90
|
-
`)),()=>{})}function aa(e){return Yt(e,"spacing",8,"spacing")}function Ut(e,t){if(typeof t=="string"||t==null)return t;const n=Math.abs(t),r=e(n);return t>=0?r:typeof r=="number"?-r:`-${r}`}function Ac(e,t){return n=>e.reduce((r,o)=>(r[o]=Ut(t,n),r),{})}function Sc(e,t,n,r){if(t.indexOf(n)===-1)return null;const o=Ic(n),a=Ac(o,r),i=e[n];return at(e,i,a)}function ia(e,t){const n=aa(e.theme);return Object.keys(e).map(r=>Sc(e,t,r,n)).reduce(Pt,{})}function ve(e){return ia(e,fr)}ve.propTypes=process.env.NODE_ENV!=="production"?fr.reduce((e,t)=>(e[t]=ct,e),{}):{},ve.filterProps=fr;function be(e){return ia(e,pr)}be.propTypes=process.env.NODE_ENV!=="production"?pr.reduce((e,t)=>(e[t]=ct,e),{}):{},be.filterProps=pr,process.env.NODE_ENV!=="production"&&Cc.reduce((e,t)=>(e[t]=ct,e),{});function zc(e=8){if(e.mui)return e;const t=aa({spacing:e}),n=(...r)=>(process.env.NODE_ENV!=="production"&&(r.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)),(r.length===0?[1]:r).map(a=>{const i=t(a);return typeof i=="number"?`${i}px`:i}).join(" "));return n.mui=!0,n}function hr(...e){const t=e.reduce((r,o)=>(o.filterProps.forEach(a=>{r[a]=o}),r),{}),n=r=>Object.keys(r).reduce((o,a)=>t[a]?Pt(o,t[a](r)):o,{});return n.propTypes=process.env.NODE_ENV!=="production"?e.reduce((r,o)=>Object.assign(r,o.propTypes),{}):{},n.filterProps=e.reduce((r,o)=>r.concat(o.filterProps),[]),n}function tt(e){return typeof e!="number"?e:`${e}px solid`}const kc=ie({prop:"border",themeKey:"borders",transform:tt}),_c=ie({prop:"borderTop",themeKey:"borders",transform:tt}),Rc=ie({prop:"borderRight",themeKey:"borders",transform:tt}),Lc=ie({prop:"borderBottom",themeKey:"borders",transform:tt}),$c=ie({prop:"borderLeft",themeKey:"borders",transform:tt}),Pc=ie({prop:"borderColor",themeKey:"palette"}),Yc=ie({prop:"borderTopColor",themeKey:"palette"}),Uc=ie({prop:"borderRightColor",themeKey:"palette"}),Fc=ie({prop:"borderBottomColor",themeKey:"palette"}),Vc=ie({prop:"borderLeftColor",themeKey:"palette"}),gr=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=Yt(e.theme,"shape.borderRadius",4,"borderRadius"),n=r=>({borderRadius:Ut(t,r)});return at(e,e.borderRadius,n)}return null};gr.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:ct}:{},gr.filterProps=["borderRadius"],hr(kc,_c,Rc,Lc,$c,Pc,Yc,Uc,Fc,Vc,gr);const mr=e=>{if(e.gap!==void 0&&e.gap!==null){const t=Yt(e.theme,"spacing",8,"gap"),n=r=>({gap:Ut(t,r)});return at(e,e.gap,n)}return null};mr.propTypes=process.env.NODE_ENV!=="production"?{gap:ct}:{},mr.filterProps=["gap"];const yr=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=Yt(e.theme,"spacing",8,"columnGap"),n=r=>({columnGap:Ut(t,r)});return at(e,e.columnGap,n)}return null};yr.propTypes=process.env.NODE_ENV!=="production"?{columnGap:ct}:{},yr.filterProps=["columnGap"];const vr=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=Yt(e.theme,"spacing",8,"rowGap"),n=r=>({rowGap:Ut(t,r)});return at(e,e.rowGap,n)}return null};vr.propTypes=process.env.NODE_ENV!=="production"?{rowGap:ct}:{},vr.filterProps=["rowGap"];const Qc=ie({prop:"gridColumn"}),Bc=ie({prop:"gridRow"}),qc=ie({prop:"gridAutoFlow"}),Wc=ie({prop:"gridAutoColumns"}),Gc=ie({prop:"gridAutoRows"}),Kc=ie({prop:"gridTemplateColumns"}),Jc=ie({prop:"gridTemplateRows"}),Zc=ie({prop:"gridTemplateAreas"}),Xc=ie({prop:"gridArea"});hr(mr,yr,vr,Qc,Bc,qc,Wc,Gc,Kc,Jc,Zc,Xc);function vt(e,t){return t==="grey"?t:e}const Hc=ie({prop:"color",themeKey:"palette",transform:vt}),el=ie({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:vt}),tl=ie({prop:"backgroundColor",themeKey:"palette",transform:vt});hr(Hc,el,tl);function Be(e){return e<=1&&e!==0?`${e*100}%`:e}const rl=ie({prop:"width",transform:Be}),gn=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=n=>{var r,o;const a=((r=e.theme)==null||(r=r.breakpoints)==null||(r=r.values)==null?void 0:r[n])||hn[n];return a?((o=e.theme)==null||(o=o.breakpoints)==null?void 0:o.unit)!=="px"?{maxWidth:`${a}${e.theme.breakpoints.unit}`}:{maxWidth:a}:{maxWidth:Be(n)}};return at(e,e.maxWidth,t)}return null};gn.filterProps=["maxWidth"];const nl=ie({prop:"minWidth",transform:Be}),ol=ie({prop:"height",transform:Be}),al=ie({prop:"maxHeight",transform:Be}),il=ie({prop:"minHeight",transform:Be});ie({prop:"size",cssProperty:"width",transform:Be}),ie({prop:"size",cssProperty:"height",transform:Be});const sl=ie({prop:"boxSizing"});hr(rl,gn,nl,ol,al,il,sl);const mn={border:{themeKey:"borders",transform:tt},borderTop:{themeKey:"borders",transform:tt},borderRight:{themeKey:"borders",transform:tt},borderBottom:{themeKey:"borders",transform:tt},borderLeft:{themeKey:"borders",transform:tt},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:gr},color:{themeKey:"palette",transform:vt},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:vt},backgroundColor:{themeKey:"palette",transform:vt},p:{style:be},pt:{style:be},pr:{style:be},pb:{style:be},pl:{style:be},px:{style:be},py:{style:be},padding:{style:be},paddingTop:{style:be},paddingRight:{style:be},paddingBottom:{style:be},paddingLeft:{style:be},paddingX:{style:be},paddingY:{style:be},paddingInline:{style:be},paddingInlineStart:{style:be},paddingInlineEnd:{style:be},paddingBlock:{style:be},paddingBlockStart:{style:be},paddingBlockEnd:{style:be},m:{style:ve},mt:{style:ve},mr:{style:ve},mb:{style:ve},ml:{style:ve},mx:{style:ve},my:{style:ve},margin:{style:ve},marginTop:{style:ve},marginRight:{style:ve},marginBottom:{style:ve},marginLeft:{style:ve},marginX:{style:ve},marginY:{style:ve},marginInline:{style:ve},marginInlineStart:{style:ve},marginInlineEnd:{style:ve},marginBlock:{style:ve},marginBlockStart:{style:ve},marginBlockEnd:{style:ve},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:mr},rowGap:{style:vr},columnGap:{style:yr},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Be},maxWidth:{style:gn},minWidth:{transform:Be},height:{transform:Be},maxHeight:{transform:Be},minHeight:{transform:Be},boxSizing:{},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}};function cl(...e){const t=e.reduce((r,o)=>r.concat(Object.keys(o)),[]),n=new Set(t);return e.every(r=>n.size===Object.keys(r).length)}function ll(e,t){return typeof e=="function"?e(t):e}function ul(){function e(n,r,o,a){const i={[n]:r,theme:o},s=a[n];if(!s)return{[n]:r};const{cssProperty:u=n,themeKey:d,transform:f,style:h}=s;if(r==null)return null;if(d==="typography"&&r==="inherit")return{[n]:r};const p=ur(o,d)||{};return h?h(i):at(i,r,v=>{let g=dr(p,f,v);return v===g&&typeof v=="string"&&(g=dr(p,f,`${n}${v==="default"?"":Ke(v)}`,v)),u===!1?g:{[u]:g}})}function t(n){var r;const{sx:o,theme:a={}}=n||{};if(!o)return null;const i=(r=a.unstable_sxConfig)!=null?r:mn;function s(u){let d=u;if(typeof u=="function")d=u(a);else if(typeof u!="object")return u;if(!d)return null;const f=Nc(a.breakpoints),h=Object.keys(f);let p=f;return Object.keys(d).forEach(M=>{const v=ll(d[M],a);if(v!=null)if(typeof v=="object")if(i[M])p=Pt(p,e(M,v,a,i));else{const g=at({theme:a},v,m=>({[M]:m}));cl(g,v)?p[M]=t({sx:v,theme:a}):p=Pt(p,g)}else p=Pt(p,e(M,v,a,i))}),Dc(h,p)}return Array.isArray(o)?o.map(s):s(o)}return t}const sa=ul();sa.filterProps=["sx"];const yn=sa,dl=["breakpoints","palette","spacing","shape"];function vn(e={},...t){const{breakpoints:n={},palette:r={},spacing:o,shape:a={}}=e,i=ot(e,dl),s=Tc(n),u=zc(o);let d=Ge({breakpoints:s,direction:"ltr",components:{},palette:J({mode:"light"},r),spacing:u,shape:J({},jc,a)},i);return d=t.reduce((f,h)=>Ge(f,h),d),d.unstable_sxConfig=J({},mn,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(h){return yn({sx:h,theme:this})},d}function fl(e){return Object.keys(e).length===0}function pl(e=null){const t=K.useContext(lr);return!t||fl(t)?e:t}const hl=vn();function gl(e=hl){return pl(e)}const ml=["variant"];function ca(e){return e.length===0}function la(e){const{variant:t}=e,n=ot(e,ml);let r=t||"";return Object.keys(n).sort().forEach(o=>{o==="color"?r+=ca(r)?e[o]:Ke(e[o]):r+=`${ca(r)?o:Ke(o)}${Ke(e[o].toString())}`}),r}const yl=["name","slot","skipVariantsResolver","skipSx","overridesResolver"];function vl(e){return Object.keys(e).length===0}function bl(e){return typeof e=="string"&&e.charCodeAt(0)>96}const Ml=(e,t)=>t.components&&t.components[e]&&t.components[e].styleOverrides?t.components[e].styleOverrides:null,br=e=>{const t={};return e&&e.forEach(n=>{const r=la(n.props);t[r]=n.style}),t},xl=(e,t)=>{let n=[];return t&&t.components&&t.components[e]&&t.components[e].variants&&(n=t.components[e].variants),br(n)},Mr=(e,t,n)=>{const{ownerState:r={}}=e,o=[];return n&&n.forEach(a=>{let i=!0;Object.keys(a.props).forEach(s=>{r[s]!==a.props[s]&&e[s]!==a.props[s]&&(i=!1)}),i&&o.push(t[la(a.props)])}),o},Tl=(e,t,n,r)=>{var o;const a=n==null||(o=n.components)==null||(o=o[r])==null?void 0:o.variants;return Mr(e,t,a)};function xr(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const jl=vn(),ua=e=>e&&e.charAt(0).toLowerCase()+e.slice(1);function Tr({defaultTheme:e,theme:t,themeId:n}){return vl(t)?e:t[n]||t}function Nl(e){return e?(t,n)=>n[e]:null}const da=({styledArg:e,props:t,defaultTheme:n,themeId:r})=>{const o=e(J({},t,{theme:Tr(J({},t,{defaultTheme:n,themeId:r}))}));let a;if(o&&o.variants&&(a=o.variants,delete o.variants),a){const i=Mr(t,br(a),a);return[o,...i]}return o};function Dl(e={}){const{themeId:t,defaultTheme:n=jl,rootShouldForwardProp:r=xr,slotShouldForwardProp:o=xr}=e,a=i=>yn(J({},i,{theme:Tr(J({},i,{defaultTheme:n,themeId:t}))}));return a.__mui_systemSx=!0,(i,s={})=>{bc(i,C=>C.filter(b=>!(b!=null&&b.__mui_systemSx)));const{name:u,slot:d,skipVariantsResolver:f,skipSx:h,overridesResolver:p=Nl(ua(d))}=s,M=ot(s,yl),v=f!==void 0?f:d&&d!=="Root"&&d!=="root"||!1,g=h||!1;let m;process.env.NODE_ENV!=="production"&&u&&(m=`${u}-${ua(d||"Root")}`);let x=xr;d==="Root"||d==="root"?x=r:d?x=o:bl(i)&&(x=void 0);const N=vc(i,J({shouldForwardProp:x,label:m},M)),I=(C,...b)=>{const q=b?b.map(R=>{if(typeof R=="function"&&R.__emotion_real!==R)return ue=>da({styledArg:R,props:ue,defaultTheme:n,themeId:t});if(st(R)){let ue=R,he;return R&&R.variants&&(he=R.variants,delete ue.variants,ue=de=>{let se=R;return Mr(de,br(he),he).forEach(ye=>{se=Ge(se,ye)}),se}),ue}return R}):[];let _=C;if(st(C)){let R;C&&C.variants&&(R=C.variants,delete _.variants,_=ue=>{let he=C;return Mr(ue,br(R),R).forEach(se=>{he=Ge(he,se)}),he})}else typeof C=="function"&&C.__emotion_real!==C&&(_=R=>da({styledArg:C,props:R,defaultTheme:n,themeId:t}));u&&p&&q.push(R=>{const ue=Tr(J({},R,{defaultTheme:n,themeId:t})),he=Ml(u,ue);if(he){const de={};return Object.entries(he).forEach(([se,Me])=>{de[se]=typeof Me=="function"?Me(J({},R,{theme:ue})):Me}),p(R,de)}return null}),u&&!v&&q.push(R=>{const ue=Tr(J({},R,{defaultTheme:n,themeId:t}));return Tl(R,xl(u,ue),ue,u)}),g||q.push(a);const Se=q.length-b.length;if(Array.isArray(C)&&Se>0){const R=new Array(Se).fill("");_=[...C,...R],_.raw=[...C.raw,...R]}const me=N(_,...q);if(process.env.NODE_ENV!=="production"){let R;u&&(R=`${u}${Ke(d||"")}`),R===void 0&&(R=`Styled(${Bi(i)})`),me.displayName=R}return i.muiName&&(me.muiName=i.muiName),me};return N.withConfig&&(I.withConfig=N.withConfig),I}}function El(e){const{theme:t,name:n,props:r}=e;return!t||!t.components||!t.components[n]||!t.components[n].defaultProps?r:Do(t.components[n].defaultProps,r)}function Ol({props:e,name:t,defaultTheme:n,themeId:r}){let o=gl(n);return r&&(o=o[r]||o),El({theme:o,name:t,props:e})}function fa(e,t=0,n=1){return process.env.NODE_ENV!=="production"&&(e<t||e>n)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${n}].`),Math.min(Math.max(t,e),n)}function wl(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let n=e.match(t);return n&&n[0].length===1&&(n=n.map(r=>r+r)),n?`rgb${n.length===4?"a":""}(${n.map((r,o)=>o<3?parseInt(r,16):Math.round(parseInt(r,16)/255*1e3)/1e3).join(", ")})`:""}function bt(e){if(e.type)return e;if(e.charAt(0)==="#")return bt(wl(e));const t=e.indexOf("("),n=e.substring(0,t);if(["rgb","rgba","hsl","hsla","color"].indexOf(n)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color.
|
|
91
|
-
The following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().`:
|
|
92
|
-
The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:
|
|
93
|
-
`))}return m}const
|
|
94
|
-
The color object needs to have a \`main\` property or a \`${x}\` property.`:
|
|
90
|
+
`)),()=>{})}function sa(e){return Rt(e,"spacing",8,"spacing")}function Lt(e,t){if(typeof t=="string"||t==null)return t;const n=Math.abs(t),r=e(n);return t>=0?r:typeof r=="number"?-r:`-${r}`}function kl(e,t){return n=>e.reduce((r,o)=>(r[o]=Lt(t,n),r),{})}function zl(e,t,n,r){if(t.indexOf(n)===-1)return null;const o=Al(n),a=kl(o,r),i=e[n];return rt(e,i,a)}function la(e,t){const n=sa(e.theme);return Object.keys(e).map(r=>zl(e,t,r,n)).reduce(_t,{})}function ve(e){return la(e,fr)}ve.propTypes=process.env.NODE_ENV!=="production"?fr.reduce((e,t)=>(e[t]=at,e),{}):{},ve.filterProps=fr;function be(e){return la(e,pr)}be.propTypes=process.env.NODE_ENV!=="production"?pr.reduce((e,t)=>(e[t]=at,e),{}):{},be.filterProps=pr,process.env.NODE_ENV!=="production"&&Sl.reduce((e,t)=>(e[t]=at,e),{});function _l(e=8){if(e.mui)return e;const t=sa({spacing:e}),n=(...r)=>(process.env.NODE_ENV!=="production"&&(r.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)),(r.length===0?[1]:r).map(a=>{const i=t(a);return typeof i=="number"?`${i}px`:i}).join(" "));return n.mui=!0,n}function hr(...e){const t=e.reduce((r,o)=>(o.filterProps.forEach(a=>{r[a]=o}),r),{}),n=r=>Object.keys(r).reduce((o,a)=>t[a]?_t(o,t[a](r)):o,{});return n.propTypes=process.env.NODE_ENV!=="production"?e.reduce((r,o)=>Object.assign(r,o.propTypes),{}):{},n.filterProps=e.reduce((r,o)=>r.concat(o.filterProps),[]),n}function He(e){return typeof e!="number"?e:`${e}px solid`}const Rl=ae({prop:"border",themeKey:"borders",transform:He}),Ll=ae({prop:"borderTop",themeKey:"borders",transform:He}),$l=ae({prop:"borderRight",themeKey:"borders",transform:He}),Pl=ae({prop:"borderBottom",themeKey:"borders",transform:He}),Yl=ae({prop:"borderLeft",themeKey:"borders",transform:He}),Fl=ae({prop:"borderColor",themeKey:"palette"}),Ul=ae({prop:"borderTopColor",themeKey:"palette"}),Vl=ae({prop:"borderRightColor",themeKey:"palette"}),Ql=ae({prop:"borderBottomColor",themeKey:"palette"}),Bl=ae({prop:"borderLeftColor",themeKey:"palette"}),gr=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=Rt(e.theme,"shape.borderRadius",4,"borderRadius"),n=r=>({borderRadius:Lt(t,r)});return rt(e,e.borderRadius,n)}return null};gr.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:at}:{},gr.filterProps=["borderRadius"],hr(Rl,Ll,$l,Pl,Yl,Fl,Ul,Vl,Ql,Bl,gr);const mr=e=>{if(e.gap!==void 0&&e.gap!==null){const t=Rt(e.theme,"spacing",8,"gap"),n=r=>({gap:Lt(t,r)});return rt(e,e.gap,n)}return null};mr.propTypes=process.env.NODE_ENV!=="production"?{gap:at}:{},mr.filterProps=["gap"];const yr=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=Rt(e.theme,"spacing",8,"columnGap"),n=r=>({columnGap:Lt(t,r)});return rt(e,e.columnGap,n)}return null};yr.propTypes=process.env.NODE_ENV!=="production"?{columnGap:at}:{},yr.filterProps=["columnGap"];const vr=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=Rt(e.theme,"spacing",8,"rowGap"),n=r=>({rowGap:Lt(t,r)});return rt(e,e.rowGap,n)}return null};vr.propTypes=process.env.NODE_ENV!=="production"?{rowGap:at}:{},vr.filterProps=["rowGap"];const ql=ae({prop:"gridColumn"}),Wl=ae({prop:"gridRow"}),Gl=ae({prop:"gridAutoFlow"}),Kl=ae({prop:"gridAutoColumns"}),Jl=ae({prop:"gridAutoRows"}),Zl=ae({prop:"gridTemplateColumns"}),Xl=ae({prop:"gridTemplateRows"}),Hl=ae({prop:"gridTemplateAreas"}),ec=ae({prop:"gridArea"});hr(mr,yr,vr,ql,Wl,Gl,Kl,Jl,Zl,Xl,Hl,ec);function ht(e,t){return t==="grey"?t:e}const tc=ae({prop:"color",themeKey:"palette",transform:ht}),rc=ae({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:ht}),nc=ae({prop:"backgroundColor",themeKey:"palette",transform:ht});hr(tc,rc,nc);function Ve(e){return e<=1&&e!==0?`${e*100}%`:e}const oc=ae({prop:"width",transform:Ve}),mn=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=n=>{var r,o;const a=((r=e.theme)==null||(r=r.breakpoints)==null||(r=r.values)==null?void 0:r[n])||gn[n];return a?((o=e.theme)==null||(o=o.breakpoints)==null?void 0:o.unit)!=="px"?{maxWidth:`${a}${e.theme.breakpoints.unit}`}:{maxWidth:a}:{maxWidth:Ve(n)}};return rt(e,e.maxWidth,t)}return null};mn.filterProps=["maxWidth"];const ac=ae({prop:"minWidth",transform:Ve}),ic=ae({prop:"height",transform:Ve}),sc=ae({prop:"maxHeight",transform:Ve}),lc=ae({prop:"minHeight",transform:Ve});ae({prop:"size",cssProperty:"width",transform:Ve}),ae({prop:"size",cssProperty:"height",transform:Ve});const cc=ae({prop:"boxSizing"});hr(oc,mn,ac,ic,sc,lc,cc);const yn={border:{themeKey:"borders",transform:He},borderTop:{themeKey:"borders",transform:He},borderRight:{themeKey:"borders",transform:He},borderBottom:{themeKey:"borders",transform:He},borderLeft:{themeKey:"borders",transform:He},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:gr},color:{themeKey:"palette",transform:ht},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:ht},backgroundColor:{themeKey:"palette",transform:ht},p:{style:be},pt:{style:be},pr:{style:be},pb:{style:be},pl:{style:be},px:{style:be},py:{style:be},padding:{style:be},paddingTop:{style:be},paddingRight:{style:be},paddingBottom:{style:be},paddingLeft:{style:be},paddingX:{style:be},paddingY:{style:be},paddingInline:{style:be},paddingInlineStart:{style:be},paddingInlineEnd:{style:be},paddingBlock:{style:be},paddingBlockStart:{style:be},paddingBlockEnd:{style:be},m:{style:ve},mt:{style:ve},mr:{style:ve},mb:{style:ve},ml:{style:ve},mx:{style:ve},my:{style:ve},margin:{style:ve},marginTop:{style:ve},marginRight:{style:ve},marginBottom:{style:ve},marginLeft:{style:ve},marginX:{style:ve},marginY:{style:ve},marginInline:{style:ve},marginInlineStart:{style:ve},marginInlineEnd:{style:ve},marginBlock:{style:ve},marginBlockStart:{style:ve},marginBlockEnd:{style:ve},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:mr},rowGap:{style:vr},columnGap:{style:yr},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Ve},maxWidth:{style:mn},minWidth:{transform:Ve},height:{transform:Ve},maxHeight:{transform:Ve},minHeight:{transform:Ve},boxSizing:{},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}};function uc(...e){const t=e.reduce((r,o)=>r.concat(Object.keys(o)),[]),n=new Set(t);return e.every(r=>n.size===Object.keys(r).length)}function dc(e,t){return typeof e=="function"?e(t):e}function fc(){function e(n,r,o,a){const i={[n]:r,theme:o},l=a[n];if(!l)return{[n]:r};const{cssProperty:u=n,themeKey:d,transform:f,style:p}=l;if(r==null)return null;if(d==="typography"&&r==="inherit")return{[n]:r};const h=ur(o,d)||{};return p?p(i):rt(i,r,v=>{let g=dr(h,f,v);return v===g&&typeof v=="string"&&(g=dr(h,f,`${n}${v==="default"?"":Ge(v)}`,v)),u===!1?g:{[u]:g}})}function t(n){var r;const{sx:o,theme:a={}}=n||{};if(!o)return null;const i=(r=a.unstable_sxConfig)!=null?r:yn;function l(u){let d=u;if(typeof u=="function")d=u(a);else if(typeof u!="object")return u;if(!d)return null;const f=El(a.breakpoints),p=Object.keys(f);let h=f;return Object.keys(d).forEach(M=>{const v=dc(d[M],a);if(v!=null)if(typeof v=="object")if(i[M])h=_t(h,e(M,v,a,i));else{const g=rt({theme:a},v,m=>({[M]:m}));uc(g,v)?h[M]=t({sx:v,theme:a}):h=_t(h,g)}else h=_t(h,e(M,v,a,i))}),Ol(p,h)}return Array.isArray(o)?o.map(l):l(o)}return t}const ca=fc();ca.filterProps=["sx"];const vn=ca,pc=["breakpoints","palette","spacing","shape"];function bn(e={},...t){const{breakpoints:n={},palette:r={},spacing:o,shape:a={}}=e,i=tt(e,pc),l=Dl(n),u=_l(o);let d=We({breakpoints:l,direction:"ltr",components:{},palette:Z({mode:"light"},r),spacing:u,shape:Z({},Nl,a)},i);return d=t.reduce((f,p)=>We(f,p),d),d.unstable_sxConfig=Z({},yn,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(p){return vn({sx:p,theme:this})},d}function hc(e){return Object.keys(e).length===0}function gc(e=null){const t=G.useContext(cr);return!t||hc(t)?e:t}const mc=bn();function yc(e=mc){return gc(e)}const vc=["variant"];function ua(e){return e.length===0}function da(e){const{variant:t}=e,n=tt(e,vc);let r=t||"";return Object.keys(n).sort().forEach(o=>{o==="color"?r+=ua(r)?e[o]:Ge(e[o]):r+=`${ua(r)?o:Ge(o)}${Ge(e[o].toString())}`}),r}const bc=["name","slot","skipVariantsResolver","skipSx","overridesResolver"];function Mc(e){return Object.keys(e).length===0}function xc(e){return typeof e=="string"&&e.charCodeAt(0)>96}const Tc=(e,t)=>t.components&&t.components[e]&&t.components[e].styleOverrides?t.components[e].styleOverrides:null,br=e=>{const t={};return e&&e.forEach(n=>{const r=da(n.props);t[r]=n.style}),t},jc=(e,t)=>{let n=[];return t&&t.components&&t.components[e]&&t.components[e].variants&&(n=t.components[e].variants),br(n)},Mr=(e,t,n)=>{const{ownerState:r={}}=e,o=[];return n&&n.forEach(a=>{let i=!0;Object.keys(a.props).forEach(l=>{r[l]!==a.props[l]&&e[l]!==a.props[l]&&(i=!1)}),i&&o.push(t[da(a.props)])}),o},Dc=(e,t,n,r)=>{var o;const a=n==null||(o=n.components)==null||(o=o[r])==null?void 0:o.variants;return Mr(e,t,a)};function xr(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const Nc=bn(),fa=e=>e&&e.charAt(0).toLowerCase()+e.slice(1);function Tr({defaultTheme:e,theme:t,themeId:n}){return Mc(t)?e:t[n]||t}function Ec(e){return e?(t,n)=>n[e]:null}const pa=({styledArg:e,props:t,defaultTheme:n,themeId:r})=>{const o=e(Z({},t,{theme:Tr(Z({},t,{defaultTheme:n,themeId:r}))}));let a;if(o&&o.variants&&(a=o.variants,delete o.variants),a){const i=Mr(t,br(a),a);return[o,...i]}return o};function Oc(e={}){const{themeId:t,defaultTheme:n=Nc,rootShouldForwardProp:r=xr,slotShouldForwardProp:o=xr}=e,a=i=>vn(Z({},i,{theme:Tr(Z({},i,{defaultTheme:n,themeId:t}))}));return a.__mui_systemSx=!0,(i,l={})=>{xl(i,A=>A.filter(b=>!(b!=null&&b.__mui_systemSx)));const{name:u,slot:d,skipVariantsResolver:f,skipSx:p,overridesResolver:h=Ec(fa(d))}=l,M=tt(l,bc),v=f!==void 0?f:d&&d!=="Root"&&d!=="root"||!1,g=p||!1;let m;process.env.NODE_ENV!=="production"&&u&&(m=`${u}-${fa(d||"Root")}`);let x=xr;d==="Root"||d==="root"?x=r:d?x=o:xc(i)&&(x=void 0);const O=Ml(i,Z({shouldForwardProp:x,label:m},M)),I=(A,...b)=>{const W=b?b.map(_=>{if(typeof _=="function"&&_.__emotion_real!==_)return se=>pa({styledArg:_,props:se,defaultTheme:n,themeId:t});if(ot(_)){let se=_,me;return _&&_.variants&&(me=_.variants,delete se.variants,se=de=>{let le=_;return Mr(de,br(me),me).forEach(xe=>{le=We(le,xe)}),le}),se}return _}):[];let z=A;if(ot(A)){let _;A&&A.variants&&(_=A.variants,delete z.variants,z=se=>{let me=A;return Mr(se,br(_),_).forEach(le=>{me=We(me,le)}),me})}else typeof A=="function"&&A.__emotion_real!==A&&(z=_=>pa({styledArg:A,props:_,defaultTheme:n,themeId:t}));u&&h&&W.push(_=>{const se=Tr(Z({},_,{defaultTheme:n,themeId:t})),me=Tc(u,se);if(me){const de={};return Object.entries(me).forEach(([le,Me])=>{de[le]=typeof Me=="function"?Me(Z({},_,{theme:se})):Me}),h(_,de)}return null}),u&&!v&&W.push(_=>{const se=Tr(Z({},_,{defaultTheme:n,themeId:t}));return Dc(_,jc(u,se),se,u)}),g||W.push(a);const Te=W.length-b.length;if(Array.isArray(A)&&Te>0){const _=new Array(Te).fill("");z=[...A,..._],z.raw=[...A.raw,..._]}const he=O(z,...W);if(process.env.NODE_ENV!=="production"){let _;u&&(_=`${u}${Ge(d||"")}`),_===void 0&&(_=`Styled(${Wi(i)})`),he.displayName=_}return i.muiName&&(he.muiName=i.muiName),he};return O.withConfig&&(I.withConfig=O.withConfig),I}}function Cc(e){const{theme:t,name:n,props:r}=e;return!t||!t.components||!t.components[n]||!t.components[n].defaultProps?r:Oo(t.components[n].defaultProps,r)}function wc({props:e,name:t,defaultTheme:n,themeId:r}){let o=yc(n);return r&&(o=o[r]||o),Cc({theme:o,name:t,props:e})}function ha(e,t=0,n=1){return process.env.NODE_ENV!=="production"&&(e<t||e>n)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${n}].`),Math.min(Math.max(t,e),n)}function Ic(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let n=e.match(t);return n&&n[0].length===1&&(n=n.map(r=>r+r)),n?`rgb${n.length===4?"a":""}(${n.map((r,o)=>o<3?parseInt(r,16):Math.round(parseInt(r,16)/255*1e3)/1e3).join(", ")})`:""}function gt(e){if(e.type)return e;if(e.charAt(0)==="#")return gt(Ic(e));const t=e.indexOf("("),n=e.substring(0,t);if(["rgb","rgba","hsl","hsla","color"].indexOf(n)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color.
|
|
91
|
+
The following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().`:ut(9,e));let r=e.substring(t+1,e.length-1),o;if(n==="color"){if(r=r.split(" "),o=r.shift(),r.length===4&&r[3].charAt(0)==="/"&&(r[3]=r[3].slice(1)),["srgb","display-p3","a98-rgb","prophoto-rgb","rec-2020"].indexOf(o)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: unsupported \`${o}\` color space.
|
|
92
|
+
The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:ut(10,o))}else r=r.split(",");return r=r.map(a=>parseFloat(a)),{type:n,values:r,colorSpace:o}}function Mn(e){const{type:t,colorSpace:n}=e;let{values:r}=e;return t.indexOf("rgb")!==-1?r=r.map((o,a)=>a<3?parseInt(o,10):o):t.indexOf("hsl")!==-1&&(r[1]=`${r[1]}%`,r[2]=`${r[2]}%`),t.indexOf("color")!==-1?r=`${n} ${r.join(" ")}`:r=`${r.join(", ")}`,`${t}(${r})`}function Ac(e){e=gt(e);const{values:t}=e,n=t[0],r=t[1]/100,o=t[2]/100,a=r*Math.min(o,1-o),i=(d,f=(d+n/30)%12)=>o-a*Math.max(Math.min(f-3,9-f,1),-1);let l="rgb";const u=[Math.round(i(0)*255),Math.round(i(8)*255),Math.round(i(4)*255)];return e.type==="hsla"&&(l+="a",u.push(t[3])),Mn({type:l,values:u})}function ga(e){e=gt(e);let t=e.type==="hsl"||e.type==="hsla"?gt(Ac(e)).values:e.values;return t=t.map(n=>(e.type!=="color"&&(n/=255),n<=.03928?n/12.92:((n+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function ma(e,t){const n=ga(e),r=ga(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function Sc(e,t){if(e=gt(e),t=ha(t),e.type.indexOf("hsl")!==-1)e.values[2]*=1-t;else if(e.type.indexOf("rgb")!==-1||e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]*=1-t;return Mn(e)}function kc(e,t){if(e=gt(e),t=ha(t),e.type.indexOf("hsl")!==-1)e.values[2]+=(100-e.values[2])*t;else if(e.type.indexOf("rgb")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;else if(e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(1-e.values[n])*t;return Mn(e)}function zc(e,t){return Z({toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}}},t)}const $t={black:"#000",white:"#fff"},_c={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},mt={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff"},yt={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000"},Pt={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"},vt={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff"},bt={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea"},Mt={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853"},Rc=["mode","contrastThreshold","tonalOffset"],ya={text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:$t.white,default:$t.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}},xn={text:{primary:$t.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:$t.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}};function va(e,t,n,r){const o=r.light||r,a=r.dark||r*1.5;e[t]||(e.hasOwnProperty(n)?e[t]=e[n]:t==="light"?e.light=kc(e.main,o):t==="dark"&&(e.dark=Sc(e.main,a)))}function Lc(e="light"){return e==="dark"?{main:vt[200],light:vt[50],dark:vt[400]}:{main:vt[700],light:vt[400],dark:vt[800]}}function $c(e="light"){return e==="dark"?{main:mt[200],light:mt[50],dark:mt[400]}:{main:mt[500],light:mt[300],dark:mt[700]}}function Pc(e="light"){return e==="dark"?{main:yt[500],light:yt[300],dark:yt[700]}:{main:yt[700],light:yt[400],dark:yt[800]}}function Yc(e="light"){return e==="dark"?{main:bt[400],light:bt[300],dark:bt[700]}:{main:bt[700],light:bt[500],dark:bt[900]}}function Fc(e="light"){return e==="dark"?{main:Mt[400],light:Mt[300],dark:Mt[700]}:{main:Mt[800],light:Mt[500],dark:Mt[900]}}function Uc(e="light"){return e==="dark"?{main:Pt[400],light:Pt[300],dark:Pt[700]}:{main:"#ed6c02",light:Pt[500],dark:Pt[900]}}function Vc(e){const{mode:t="light",contrastThreshold:n=3,tonalOffset:r=.2}=e,o=tt(e,Rc),a=e.primary||Lc(t),i=e.secondary||$c(t),l=e.error||Pc(t),u=e.info||Yc(t),d=e.success||Fc(t),f=e.warning||Uc(t);function p(g){const m=ma(g,xn.text.primary)>=n?xn.text.primary:ya.text.primary;if(process.env.NODE_ENV!=="production"){const x=ma(g,m);x<3&&console.error([`MUI: The contrast ratio of ${x}:1 for ${m} on ${g}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(`
|
|
93
|
+
`))}return m}const h=({color:g,name:m,mainShade:x=500,lightShade:O=300,darkShade:I=700})=>{if(g=Z({},g),!g.main&&g[x]&&(g.main=g[x]),!g.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${m?` (${m})`:""} provided to augmentColor(color) is invalid.
|
|
94
|
+
The color object needs to have a \`main\` property or a \`${x}\` property.`:ut(11,m?` (${m})`:"",x));if(typeof g.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${m?` (${m})`:""} provided to augmentColor(color) is invalid.
|
|
95
95
|
\`color.main\` should be a string, but \`${JSON.stringify(g.main)}\` was provided instead.
|
|
96
96
|
|
|
97
97
|
Did you intend to use one of the following approaches?
|
|
@@ -104,7 +104,7 @@ const theme1 = createTheme({ palette: {
|
|
|
104
104
|
|
|
105
105
|
const theme2 = createTheme({ palette: {
|
|
106
106
|
primary: { main: green[500] },
|
|
107
|
-
} });`:
|
|
108
|
-
`)),Object.keys(d).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(d).join(",")}].`)}return(Array.isArray(o)?o:[o]).map(f=>`${f} ${typeof i=="string"?i:
|
|
109
|
-
`))}
|
|
110
|
-
`)),Oo.configure(e)}},unstable_useEnhancedEffect:xo,unstable_useId:Hi,unsupportedProp:es,useControlled:ts,useEventCallback:rs,useForkRef:ns,useIsFocusVisible:us},Symbol.toStringTag,{value:"Module"})));var ja;function Ae(){return ja||(ja=1,function(e){"use client";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return t.createSvgIcon}});var t=uu}(Fr)),Fr}var du=Ie;Object.defineProperty(Ur,"__esModule",{value:!0});var Na=Ur.default=void 0,fu=du(Ae()),pu=l,hu=(0,fu.default)((0,pu.jsx)("path",{d:"M6.56 7.98C6.1 7.52 5.31 7.6 5 8.17c-.28.51-.5 1.03-.67 1.58-.19.63.31 1.25.96 1.25h.01c.43 0 .82-.28.94-.7.12-.4.28-.79.48-1.17.22-.37.15-.84-.16-1.15zM5.31 13h-.02c-.65 0-1.15.62-.96 1.25.16.54.38 1.07.66 1.58.31.57 1.11.66 1.57.2.3-.31.38-.77.17-1.15-.2-.37-.36-.76-.48-1.16-.12-.44-.51-.72-.94-.72zm2.85 6.02c.51.28 1.04.5 1.59.66.62.18 1.24-.32 1.24-.96v-.03c0-.43-.28-.82-.7-.94-.4-.12-.78-.28-1.15-.48-.38-.21-.86-.14-1.16.17l-.03.03c-.45.45-.36 1.24.21 1.55zM13 4.07v-.66c0-.89-1.08-1.34-1.71-.71L9.17 4.83c-.4.4-.4 1.04 0 1.43l2.13 2.08c.63.62 1.7.17 1.7-.72V6.09c2.84.48 5 2.94 5 5.91 0 2.73-1.82 5.02-4.32 5.75-.41.12-.68.51-.68.94v.02c0 .65.61 1.14 1.23.96C17.57 18.71 20 15.64 20 12c0-4.08-3.05-7.44-7-7.93z"}),"RotateLeftRounded");Na=Ur.default=hu;var Tn={},gu=Ie;Object.defineProperty(Tn,"__esModule",{value:!0});var Da=Tn.default=void 0,mu=gu(Ae()),yu=l,vu=(0,mu.default)((0,yu.jsx)("path",{d:"M17.59 3.59c-.38-.38-.89-.59-1.42-.59H5c-1.11 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V7.83c0-.53-.21-1.04-.59-1.41l-2.82-2.83zM12 19c-1.66 0-3-1.34-3-3s1.34-3 3-3 3 1.34 3 3-1.34 3-3 3zm1-10H7c-1.1 0-2-.9-2-2s.9-2 2-2h6c1.1 0 2 .9 2 2s-.9 2-2 2z"}),"SaveRounded");Da=Tn.default=vu;var jn={},bu=Ie;Object.defineProperty(jn,"__esModule",{value:!0});var Ea=jn.default=void 0,Mu=bu(Ae()),xu=l,Tu=(0,Mu.default)((0,xu.jsx)("path",{d:"M18 2h-7.17c-.53 0-1.04.21-1.42.59L4.59 7.41C4.21 7.79 4 8.3 4 8.83V20c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-6.35 14.65-2.79-2.79c-.32-.32-.1-.86.35-.86H11v-2.99c0-.55.44-.99.99-1 .56-.01 1.01.44 1.01 1V13h1.79c.45 0 .67.54.35.85l-2.79 2.79c-.19.2-.51.2-.7.01z"}),"SimCardDownloadRounded");Ea=jn.default=Tu;const Oa=(e,t)=>{if(!e)return null;if(e.name===t)return e;const n=e.children||[];for(let r=0;r<n.length;r+=1){const o=n[r],a=Oa(o,t);if(a)return a}return null},Dt=(e,t)=>{var a,i,s,u,d;if(!e)return null;if(!t)return e;if(((a=e.attributes)==null?void 0:a.treePath)===t)return((i=e.attributes)==null?void 0:i.tree)||null;let n=null;const r=(s=e.attributes)==null?void 0:s.tree,o=(u=e.children)==null?void 0:u.length;if(r&&(n=Dt((d=e.attributes)==null?void 0:d.tree,t)),o){const{children:f}=e;for(let h=0;h<f.length;h+=1){const p=f[h];if(n!==null)return n;n=Dt(p,t)}}return n},jr=(e,t,n)=>{const r=Dt(e,t);return Oa(r,n)},ju=(e,t)=>{if(!e)return null;const{attributes:n}=t,r=n.isDecision;return Object.defineProperty(e,"attributes",{value:{...e.attributes,isLeaf:!1}}),r?(Object.defineProperty(e,"children",{value:[{...t,attributes:{...n,isLeaf:!1}}]}),null):(Object.defineProperty(e,"children",{value:[{...t,attributes:{...n,isLeaf:!e.children.length}}]}),null)},Nu=({tree:e,path:t,name:n,child:r})=>{var u;const{attributes:o,children:a}=r;if(!e)return a.length?{...r}:{...r,attributes:{...o,isLeaf:!0,isRoot:!0}};const i=structuredClone(e),s=jr(i,t,n);return ju(s,{...r,...!o.isDecision&&{children:[...((u=jr(e,t,n))==null?void 0:u.children)||[]]}}),i},Du=e=>{if(!e)return[];const t=[],n=r=>{if(r.name&&t.push(r.name),r.children.length){const{children:o}=r;for(let a=0;a<o.length;a+=1)n(o[a])}};return n(e),t},wa=(e,t,n=null)=>{if(!e)return null;if(e.name===t)return n;const r=e.children||[];for(let o=0;o<r.length;o+=1){const a=r[o],i=wa(a,t,e);if(i!==null)return i}return null},Eu=(e,t)=>(!e||!t||(Object.defineProperty(e,"children",{value:e.children.filter(n=>n.name!==t.name)}),Object.defineProperty(e,"attributes",{value:{...e.attributes,isLeaf:!0}})),null),Ou=(e,t,n)=>{const r=Dt(e,t);return wa(r,n)},wu=({tree:e,path:t,name:n})=>{const r=structuredClone(e),o=jr(r,t,n),a=Ou(r,t,n);return Eu(a,o),r},Iu=(e,t)=>{if(!e)return null;const n=t.attributes.isDecision,r=e.attributes.isDecision,o=e.attributes.depth===0,a={value:t.name},i=r||n,s=i?{value:[...t.children]}:{value:[...e.children]},u=i?{value:{...t.attributes,isLeaf:!t.children.length||!n,isRoot:o}}:{value:{...t.attributes,isLeaf:!e.children.length,isRoot:o}};return Object.defineProperties(e,{attributes:u,children:s,name:a}),null},Cu=({tree:e,path:t,name:n,child:r})=>{const o=structuredClone(e),a=jr(o,t,n);return Iu(a,r),o},rt={appendTreeCard:"appendTreeCard",deleteTreeCard:"deleteTreeCard",replaceTreeCard:"replaceTreeCard",resetTree:"resetTree",setTree:"setTree"},Au=(e,t,n)=>({children:n,name:t,path:e,type:rt.appendTreeCard}),Su=(e,t,n)=>({children:n,name:t,path:e,type:rt.replaceTreeCard}),zu=(e,t)=>({name:t,path:e,type:rt.deleteTreeCard}),Ia=()=>({type:rt.resetTree}),Ca=e=>({tree:e,type:rt.setTree}),ku=(e,t)=>{switch(t.type){case rt.appendTreeCard:{const{name:n,path:r,children:o}=t;return Nu({child:o,name:n,path:r,tree:e})}case rt.deleteTreeCard:{const{path:n,name:r}=t;return wu({name:r,path:n,tree:e})}case rt.replaceTreeCard:{const{name:n,path:r,children:o}=t;return Cu({child:o,name:n,path:r,tree:e})}case rt.resetTree:return null;case rt.setTree:return t.tree;default:throw new Error}},Nn=()=>{const{dispatchSnackbar:e}=S.useContext(Wn);return{close:()=>e(Gn()),open:(r,o="success")=>e(Mi(r,o))}},_u=e=>{const{backendConfig:t}=we(),{endpoints:n}=t||{},{workflow:r=""}=n||{};return ft.useMutation(["patchWorkflow"],async o=>{const{data:a}=await pt.patch(r,o);return a},e)},Ru=e=>{const{backendConfig:t}=we(),{endpoints:n}=t||{},{workflow:r=""}=n||{};return ft.useMutation(["postWorkflow"],async o=>{const{data:a}=await pt.post(r,o);return a},e)},Lu=()=>{const{t:e}=Pe.useTranslation(["snackMessage"]),{open:t}=Nn(),{setCurrentTree:n,currentTree:r,tree:o,dispatchTree:a}=we(),[i,s]=S.useState(!1),{version:u}=we(),{mutate:d}=Ru({onError:()=>{t(e("error.saveTree",{ns:"snackMessage"}),"error")},onSuccess:x=>{t(e("success.saveTree",{ns:"snackMessage"})),n(N=>({...N,id:x.workflow_id}))}}),{mutate:f}=_u({onError:()=>{t(e("error.updateTree",{ns:"snackMessage"}),"error")},onSuccess:()=>{t(e("success.updateTree",{ns:"snackMessage"}))}}),h=x=>JSON.stringify(x,null,2),p=x=>`data:text/json;charset=utf-8,${encodeURIComponent(h(x))}`,M=()=>{s(!1)};return{formatJSON:h,getDownloadLink:p,handleClose:M,handleOpen:()=>{s(!0)},handleResetTree:()=>{a(Ia()),M()},handleSubmit:()=>{const{name:x,id:N}=r;if(!x){n(I=>({...I,errorName:"Champs Requis"}));return}if(o){if(N){f({id:N,label:x,version:u,workflow:o});return}d({label:x,version:u,workflow:o})}},openModal:i}},$u=({downloadedFileName:e="export",value:t})=>{const{t:n}=Pe.useTranslation(),{getDownloadLink:r,handleSubmit:o,handleClose:a,handleOpen:i,handleResetTree:s,openModal:u}=Lu(),{currentTree:d,backendConfig:f,tree:h}=we(),{id:p}=d;return l.jsxs(y.Stack,{direction:"row",spacing:2,justifyContent:"center",children:[l.jsx(y.Tooltip,{title:n("resetTree",{ns:"button"}),enterDelay:1500,disableHoverListener:!t,arrow:!0,children:l.jsx(y.Box,{children:l.jsx(y.Button,{disabled:!h,onClick:i,variant:"outlined",color:"warning",children:l.jsx(Na,{})})})}),l.jsx(y.Divider,{orientation:"vertical",flexItem:!0}),l.jsx(y.Tooltip,{title:n("downloadJSONFile",{ns:"button"}),enterDelay:1500,disableHoverListener:!t,arrow:!0,children:l.jsx(y.Box,{children:l.jsx(y.Button,{variant:"outlined",href:r(t),download:`${e}.json`,disabled:!t,children:l.jsx(Ea,{})})})}),l.jsx(y.Tooltip,{title:p?n("update",{ns:"button"}):n("save",{ns:"button"}),enterDelay:1500,disableHoverListener:!t,arrow:!0,children:l.jsx(y.Box,{children:l.jsx(y.Button,{variant:"outlined",onClick:o,disabled:!t||!(f!=null&&f.baseUrl),children:l.jsx(Da,{})})})}),l.jsxs(y.Dialog,{maxWidth:"xs",fullWidth:!0,open:u,onClose:a,children:[l.jsx(y.DialogTitle,{variant:"h3",children:n("resetTree",{ns:"button"})}),l.jsx(y.DialogContent,{children:l.jsx(y.DialogContentText,{children:n("resetTreeContent",{ns:"modal"})})}),l.jsxs(y.DialogActions,{children:[l.jsx(y.Button,{onClick:a,children:n("close",{ns:"button"})}),l.jsx(y.Button,{variant:"contained",color:"warning",onClick:s,children:n("reset",{ns:"button"})})]})]})]})},Pu={box:{backgroundColor:ce.background,border:`solid 1px ${ce.borderBlue}`}},Aa=({children:e,description:t,open:n,onClose:r,title:o})=>l.jsx(y.Dialog,{open:n,onClose:r,"aria-labelledby":"modal-modal-title","aria-describedby":"modal-modal-description",scroll:"body",maxWidth:"sm",fullWidth:!0,children:l.jsxs(y.Box,{sx:Pu.box,p:4,children:[l.jsx("h3",{children:o}),l.jsx("p",{children:t}),e]})});var Dn={},Yu=Ie;Object.defineProperty(Dn,"__esModule",{value:!0});var Sa=Dn.default=void 0,Uu=Yu(Ae()),Fu=l,Vu=(0,Uu.default)((0,Fu.jsx)("path",{d:"M18.3 5.71a.9959.9959 0 0 0-1.41 0L12 10.59 7.11 5.7a.9959.9959 0 0 0-1.41 0c-.39.39-.39 1.02 0 1.41L10.59 12 5.7 16.89c-.39.39-.39 1.02 0 1.41.39.39 1.02.39 1.41 0L12 13.41l4.89 4.89c.39.39 1.02.39 1.41 0 .39-.39.39-1.02 0-1.41L13.41 12l4.89-4.89c.38-.38.38-1.02 0-1.4z"}),"CloseRounded");Sa=Dn.default=Vu;const Nr={container:{display:"flex",flexDirection:"column",height:"100%",margin:1},main:{border:`solid 1px ${ce.borderBlue}`,height:" 100%",margin:1},toolbar:{backgroundColor:ce.background,boxShadow:"none",display:"flex",padding:"0 ! important"},toolbarBox:{backgroundColor:ce.tertiary,border:`solid 1px ${ce.primary}`,margin:1,paddingX:2,paddingY:1,width:"100%"}},Qu=({children:e,appear:t,in:n,onEnter:r,onExited:o,onFocus:a,role:i,tabIndex:s,timeout:u},d)=>l.jsx(y.Slide,{direction:"up",ref:d,appear:t,in:n,onEnter:r,onExited:o,onFocus:a,role:i,tabIndex:s,timeout:u,children:e}),Bu=S.forwardRef(Qu),qu=({children:e,open:t,onClose:n,title:r})=>l.jsx(y.Dialog,{PaperProps:{sx:{backgroundColor:ce.background,backgroundImage:"none"}},open:t,"aria-labelledby":"modal-modal-title","aria-describedby":"modal-modal-description",fullScreen:!0,TransitionComponent:Bu,children:l.jsxs(y.Box,{sx:Nr.container,children:[l.jsx(y.AppBar,{position:"sticky",elevation:0,children:l.jsx(y.Toolbar,{sx:Nr.toolbar,children:l.jsxs(y.Stack,{direction:"row",alignItems:"center",justifyContent:"space-between",sx:Nr.toolbarBox,children:[l.jsx(y.Typography,{variant:"h5",children:l.jsx("strong",{children:r})}),l.jsx(y.IconButton,{edge:"end",color:"inherit",onClick:n,"aria-label":"close",children:l.jsx(Sa,{})})]})})}),l.jsx(y.Box,{sx:Nr.main,children:e})]})}),Wu={box:{border:`solid 1px ${ce.borderBlue}`,flexGrow:0}},Gu=({children:e})=>l.jsx(y.Box,{p:2,role:"group",sx:Wu.box,children:e}),Ku={box:{border:`solid 1px ${ce.borderBlue}`,flexGrow:0}},Ju=({children:e})=>l.jsx(y.Box,{sx:Ku.box,padding:2,component:"header",children:e}),Zu={box:{border:`solid 1px ${ce.borderBlue}`,flexGrow:1}},Xu=({children:e})=>l.jsx(y.Box,{sx:Zu.box,component:"main",role:"tree",children:e}),za={stack:{width:"100%"}},Hu=({children:e})=>{const t=S.Children.toArray(e);return l.jsxs(y.Grid,{container:!0,padding:1,flexWrap:"nowrap",height:"100%",role:"treegrid",children:[l.jsx(y.Grid,{item:!0,xs:9,padding:1,display:"flex",children:l.jsxs(y.Stack,{sx:za.stack,spacing:2,children:[t[0],t[1]]})}),l.jsx(y.Grid,{item:!0,xs:3,padding:1,display:"flex",children:l.jsxs(y.Stack,{sx:za.stack,spacing:2,children:[t[2],t[3]]})})]})},ed={box:{border:`solid 1px ${ce.borderBlue}`,flexGrow:1,overflow:"auto"}},td=({children:e})=>l.jsx(y.Box,{sx:ed.box,component:"aside",children:e}),rd=()=>{const{dispatchTree:e,setModalOpen:t,currentHierarchyPointNode:n,treePath:r}=we();return{handleSubmit:a=>{var u,d;a.preventDefault();const i=((u=n==null?void 0:n.data)==null?void 0:u.name)||"",s=((d=r==null?void 0:r.at(-1))==null?void 0:d.path)||"";e(zu(s,i)),t(null)}}},nd=({onClose:e})=>{const{t}=Pe.useTranslation(),{handleSubmit:n}=rd();return l.jsx("form",{onSubmit:n,children:l.jsxs(y.Stack,{spacing:2,direction:"row",justifyContent:"flex-end",children:[l.jsx(y.Button,{variant:"text",onClick:e,children:t("cancel")}),l.jsx(y.Button,{variant:"contained",color:"error",type:"submit",children:t("remove")})]})})};var En={},od=Ie;Object.defineProperty(En,"__esModule",{value:!0});var ka=En.default=void 0,ad=od(Ae()),id=l,sd=(0,ad.default)((0,id.jsx)("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm4 11h-3v3c0 .55-.45 1-1 1s-1-.45-1-1v-3H8c-.55 0-1-.45-1-1s.45-1 1-1h3V8c0-.55.45-1 1-1s1 .45 1 1v3h3c.55 0 1 .45 1 1s-.45 1-1 1z"}),"AddCircleRounded");ka=En.default=sd;var On={},cd=Ie;Object.defineProperty(On,"__esModule",{value:!0});var _a=On.default=void 0,ld=cd(Ae()),ud=l,dd=(0,ld.default)((0,ud.jsx)("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm4 11H8c-.55 0-1-.45-1-1s.45-1 1-1h8c.55 0 1 .45 1 1s-.45 1-1 1z"}),"RemoveCircleRounded");_a=On.default=dd;const Qt=[{isBooleanField:!1,isDecisionField:!1,isRepeatableDisabled:!1,isRequiredDisabled:!1,type:"text"},{isBooleanField:!1,isDecisionField:!1,isRepeatableDisabled:!1,isRequiredDisabled:!1,type:"number"},{isBooleanField:!1,isDecisionField:!1,isRepeatableDisabled:!1,isRequiredDisabled:!1,type:"email"},{isBooleanField:!1,isDecisionField:!1,isRepeatableDisabled:!1,isRequiredDisabled:!1,type:"file"},{isBooleanField:!1,isDecisionField:!1,isRepeatableDisabled:!1,isRequiredDisabled:!1,type:"password"},{isBooleanField:!1,isDecisionField:!1,isRepeatableDisabled:!1,isRequiredDisabled:!1,type:"tel"},{isBooleanField:!1,isDecisionField:!1,isRepeatableDisabled:!1,isRequiredDisabled:!1,type:"address"},{isBooleanField:!1,isDecisionField:!1,isRepeatableDisabled:!1,isRequiredDisabled:!1,type:"url"},{isBooleanField:!1,isDecisionField:!1,isRepeatableDisabled:!1,isRequiredDisabled:!1,type:"date"},{isBooleanField:!1,isDecisionField:!1,isRepeatableDisabled:!1,isRequiredDisabled:!1,type:"time"},{isBooleanField:!0,isDecisionField:!1,isRepeatableDisabled:!0,isRequiredDisabled:!0,type:"switch"},{isBooleanField:!0,isDecisionField:!1,isRepeatableDisabled:!0,isRequiredDisabled:!0,type:"checkbox"},{isBooleanField:!1,isDecisionField:!1,isRepeatableDisabled:!0,isRequiredDisabled:!0,type:"hidden"},{isBooleanField:!1,isDecisionField:!1,isRepeatableDisabled:!0,isRequiredDisabled:!0,type:"tree"},{isBooleanField:!1,isDecisionField:!0,isRepeatableDisabled:!0,isRequiredDisabled:!1,type:"radio"},{isBooleanField:!1,isDecisionField:!0,isRepeatableDisabled:!0,isRequiredDisabled:!1,type:"select"}],fd=()=>{const{backendConfig:e}=we();return{fields:S.useCallback(()=>Qt.filter(n=>!(n.type==="tree"&&!(e!=null&&e.baseUrl))),[e==null?void 0:e.baseUrl])()}},pd=({onChange:e,value:t})=>{const{t:n}=Pe.useTranslation(["translation","form"]),{fields:r}=fd();return l.jsxs(y.FormControl,{sx:{flex:1},required:!0,children:[l.jsx(y.InputLabel,{children:n("type")}),l.jsx(y.Select,{value:t,label:n("type"),onChange:e,MenuProps:{PaperProps:{sx:{maxHeight:300}}},children:r.map(({type:o,isDecisionField:a})=>l.jsxs(y.MenuItem,{value:o,children:[n(`type.${o}`,{ns:"form"}),a&&l.jsx(y.Chip,{label:n("decisionField",{ns:"form"}),size:"small",color:"info",sx:{marginLeft:1}})]},o))})]})};var wn={},hd=Ie;Object.defineProperty(wn,"__esModule",{value:!0});var Ra=wn.default=void 0,gd=hd(Ae()),md=l,yd=(0,gd.default)((0,md.jsx)("path",{d:"M18 13h-5v5c0 .55-.45 1-1 1s-1-.45-1-1v-5H6c-.55 0-1-.45-1-1s.45-1 1-1h5V6c0-.55.45-1 1-1s1 .45 1 1v5h5c.55 0 1 .45 1 1s-.45 1-1 1z"}),"AddRounded");Ra=wn.default=yd;const vd=e=>{const{backendConfig:t}=we(),{endpoints:n}=t||{},{workflows:r=""}=n||{};return ft.useQuery(["workflows"],async({signal:o})=>{const{data:a}=await pt.get(r,{signal:o});return a},e)},bd=({isControlled:e,fetchWorkflowsOnOpen:t})=>{const{t:n}=Pe.useTranslation("snackMessage"),{open:r}=Nn(),{currentTree:o,setCurrentTree:a,dispatchTree:i}=we(),[s,u]=S.useState(""),d=!!s&&!e&&s!==o.id,{data:f,isError:h}=Zt(s,{enabled:d}),{data:p,isLoading:M,refetch:v}=vd({enabled:!t}),g=S.useCallback(async({target:x})=>{var I;const{value:N}=x;if(N==="add-new-tree"){u(""),a({name:""}),i(Ia());return}u(N),a({id:N,name:(I=p==null?void 0:p.find(C=>C.id===N))==null?void 0:I.label})},[i,a,p]),m=S.useCallback(async()=>{if(t)try{await v(),o.id&&!s&&u(o.id)}catch{r(n("error.fetchTree",{ns:"snackMessage"}),"error")}},[t,v,o.id,s,r,n]);return S.useEffect(()=>{if(f&&s!==o.id){const{id:x,label:N,workflow:I}=f;a({id:x,name:N}),i(Ca(I))}},[o.id,i,e,a,s,f]),S.useEffect(()=>{h&&r(n("error.fetchTree",{ns:"snackMessage"}),"error")},[h,r,n]),{currentTree:o,fetchWorkflowSuggestions:v,handleChangeTree:g,handleOnOpen:m,setTreeSelected:u,treeSelected:s,workflowsSuggestions:p,workflowsSuggestionsLoading:M}},La={formControl:{flex:1},select:{".MuiOutlinedInput-notchedOutline":{border:0,paddingLeft:5},".MuiSelect-select":{opacity:0,width:0},boxShadow:"none"}},$a=({arrowOnly:e,required:t,size:n,showBtnAddNewTree:r,onChange:o,value:a,fetchWorkflowsOnOpen:i})=>{const{t:s}=Pe.useTranslation("form"),u=S.useMemo(()=>!!o,[o]),{handleChangeTree:d,handleOnOpen:f,workflowsSuggestions:h,workflowsSuggestionsLoading:p,treeSelected:M}=bd({fetchWorkflowsOnOpen:i,isControlled:u});return l.jsxs(y.FormControl,{size:n,required:t,sx:La.formControl,children:[!e&&l.jsx(y.InputLabel,{children:s("tree",{ns:"form"})}),l.jsxs(y.Select,{value:u?a:M,id:"tree-select",onChange:v=>u?o==null?void 0:o(v):d(v),sx:e?La.select:void 0,label:s("tree",{ns:"form"}),onOpen:f,children:[(a&&p||p)&&l.jsx(y.MenuItem,{value:a,children:l.jsx(y.Skeleton,{width:"100%"})}),h==null?void 0:h.map(({label:v,id:g})=>l.jsx(y.MenuItem,{value:g,children:v},g)),r&&l.jsx(y.MenuItem,{disabled:!0,children:l.jsx(y.Box,{sx:{height:1,width:"100%"},children:l.jsx(y.Divider,{})})}),r&&l.jsxs(y.MenuItem,{value:"add-new-tree",children:[l.jsx(y.Typography,{mr:1,children:s("newTree",{ns:"form"})}),l.jsx(Ra,{color:"primary"})]})]})]})},Md=({helperText:e,hiddenValue:t,isHiddenField:n,isTreeField:r,treeSelected:o,handleChangeTreeSelect:a,handleChangeHelperText:i,handleChangeHiddenValue:s})=>{const{t:u}=Pe.useTranslation(["translation","form"]);return r?l.jsx($a,{required:!0,value:o,onChange:a}):n?l.jsx(y.TextField,{required:!0,sx:{flex:1},label:u("hiddenValue",{ns:"form"}),onChange:s,value:t}):l.jsx(y.TextField,{sx:{flex:1},label:u("helperText",{ns:"form"}),onChange:i,value:e})},Pa=e=>new Set([...e]).size===e.length,xd=(e,t,n)=>{const r=[...e,t];return Pa(n?r.filter(o=>o!==n):r)},Td=()=>{var Cr,Ar,Sr,zr,kr,_r,Rr,Ot,Wt,it,wt,It,Gt,Lr,Kt;const e=S.useMemo(()=>[{id:"0",label:"",message:"",value:""}],[]),{tree:t,dispatchTree:n,currentHierarchyPointNode:r,modalOpen:o,treePath:a,setModalOpen:i}=we(),{open:s}=Nn(),{t:u}=Pe.useTranslation(),[d,f]=S.useState(e),[h,p]=S.useState(""),[M,v]=S.useState(""),[g,m]=S.useState(""),[x,N]=S.useState(!1),[I,C]=S.useState(!1),[b,q]=S.useState("text"),[_,Se]=S.useState(""),[me,R]=S.useState(""),[ue,he]=S.useState(""),[de,se]=S.useState({off:"",on:""}),[Me,ye]=S.useState(!1),[_e,ze]=S.useState(""),Ue=o==="edit",j=b==="tree",w=b==="hidden",Y=Qt.some(E=>E.type===b&&(E==null?void 0:E.isBooleanField)),$=Qt.some(E=>E.type===b&&(E==null?void 0:E.isDecisionField)),L=Qt.some(E=>E.type===b&&(E==null?void 0:E.isRequiredDisabled)),Q=Qt.some(E=>E.type===b&&(E==null?void 0:E.isRepeatableDisabled)),k=((Ar=(Cr=r==null?void 0:r.data)==null?void 0:Cr.attributes)==null?void 0:Ar.isLeaf)??!0,P=E=>!$&&E>0,{refetch:V,isInitialLoading:W}=Zt(_,{enabled:!1,onError:()=>{s(u("error.fetchTree",{ns:"snackMessage"}),"error")}}),U=(E,ee)=>{f(te=>te.map(ge=>{const{id:Le}=ge;return E.target.dataset.id===Le?{...ge,id:Le,[ee]:E.target.value}:{...ge}}))},je=E=>{v(E.target.value)},O=E=>{m(E.target.value)},Re=E=>{U(E,"label")},A=E=>{U(E,"value")},qe=E=>{U(E,"message")},Ze=E=>{he(E.target.value)},ut=E=>{var Fe;const{value:ee}=E.target;if(p(E.target.value),!t||!ee){ze("");return}const te=Ue&&(r==null?void 0:r.data.name),ge=(Fe=a==null?void 0:a.at(-1))==null?void 0:Fe.path,Le=Dt(t,ge),$e=Du(Le);if(xd($e,ee,te)){ze("");return}ze(u("mustBeUnique",{ns:"form"}))},Dr=E=>{N(E.target.checked)},Et=E=>{C(E.target.checked)},Pn=E=>{ye(E.target.checked)},Yn=E=>{q(E.target.value),C(!1),N(!1),ye(!1)},Bt=E=>{Se(E.target.value)},Un=E=>ee=>{se(te=>({...te,[E]:ee.target.value}))},Fn=E=>{R(E.target.value)},Er=()=>{f(E=>{const ee=Number(E[E.length-1].id),te=String(ee+1);return[...E,{...e[0],id:te}]})},Or=E=>{f(ee=>ee.filter(({id:te})=>E.currentTarget.value!==te))},dt=(E,ee)=>{var ge,Le,$e;const te=($e=(Le=(ge=E==null?void 0:E.children)==null?void 0:ge[ee])==null?void 0:Le.data)==null?void 0:$e.children;return te?te.map(({name:We,attributes:Fe,children:nt})=>({attributes:Fe,children:nt,name:We})):[]},Vn=E=>{var ee;return I?(ee=d==null?void 0:d.filter((te,ge)=>!P(ge)))==null?void 0:ee.map(({message:te,value:ge,label:Le},$e)=>{const We=`${h}:${ge}`,Fe=dt(r,$e);return{attributes:{depth:E+1,label:Le,value:ge,...te&&{message:te},...Fe.length===0&&{isLeaf:!0}},children:Fe,name:We}}):[]},wr=E=>E.map(({message:ee,...te})=>({...te,...ee&&{message:ee}})),Ir=(E,ee,te)=>{var ge;return E&&(!ee||te)?V():E&&ee&&!te?{data:{workflow:(ge=r==null?void 0:r.data.attributes)==null?void 0:ge.tree},isError:null}:{data:null,isError:null}},qt=async E=>{var G,Z,B,F;E.preventDefault();const{on:ee,off:te}=de,ge=((G=r==null?void 0:r.data)==null?void 0:G.name)||"",Le=(r==null?void 0:r.depth)||0,$e=o==="edit",We=Le+($e||r===null?0:1),Fe=Vn(We),nt=(Z=a==null?void 0:a.at(-1))==null?void 0:Z.path,Ct=a.length?`${nt}/${h}`:`/${h}`,c=((F=(B=r==null?void 0:r.data.attributes)==null?void 0:B.tree)==null?void 0:F.treeId)!==_,{data:T,isError:D}=await Ir(j,$e,c);if(D)return;const z={attributes:{depth:We,label:g,type:b,...me&&{helperText:me},...(te||ee)&&{messages:{...te&&{off:te},...ee&&{on:ee}}},...j&&{tree:{...T==null?void 0:T.workflow,treeId:_},treePath:Ct},...I&&{isDecision:I},...$&&!I&&{values:wr(d)},...x&&{required:x},...ue&&{step:ue},...Me&&{repeatable:Me},...w&&{hiddenValue:M}},children:Fe,name:h};n($e?Su(nt||"",ge,z):Au(nt||null,ge,z)),i(null)};return S.useEffect(()=>{var E,ee,te,ge,Le,$e,We,Fe,nt,Ct,c,T,D,z,G,Z,B,F,Ee;if(o==="edit"){const fe=((ee=(E=r==null?void 0:r.data)==null?void 0:E.attributes)==null?void 0:ee.values)||((Le=(ge=(te=r==null?void 0:r.data)==null?void 0:te.children)==null?void 0:ge.filter(({attributes:Oe})=>!(Oe!=null&&Oe.type)))==null?void 0:Le.map(({attributes:Oe},lt)=>{const{label:$r,value:Xe,message:ni}=Oe||{};return{id:String(lt),label:String($r),value:String(Xe),...ni&&{message:String(ni)}}}));p((r==null?void 0:r.data.name)||""),q((($e=r==null?void 0:r.data.attributes)==null?void 0:$e.type)||"text"),R(((We=r==null?void 0:r.data.attributes)==null?void 0:We.helperText)||""),N(((Fe=r==null?void 0:r.data.attributes)==null?void 0:Fe.required)||!1),he(((nt=r==null?void 0:r.data.attributes)==null?void 0:nt.step)||""),m(((Ct=r==null?void 0:r.data.attributes)==null?void 0:Ct.label)||""),C(((c=r==null?void 0:r.data.attributes)==null?void 0:c.isDecision)||!1),f(fe!=null&&fe.length?fe:e),se({off:((D=(T=r==null?void 0:r.data.attributes)==null?void 0:T.messages)==null?void 0:D.off)||"",on:((G=(z=r==null?void 0:r.data.attributes)==null?void 0:z.messages)==null?void 0:G.on)||""}),Se(((B=(Z=r==null?void 0:r.data.attributes)==null?void 0:Z.tree)==null?void 0:B.treeId)||""),ye(((F=r==null?void 0:r.data.attributes)==null?void 0:F.repeatable)||!1),v(((Ee=r==null?void 0:r.data.attributes)==null?void 0:Ee.hiddenValue)||"")}},[(zr=(Sr=r==null?void 0:r.data.attributes)==null?void 0:Sr.tree)==null?void 0:zr.treeId,(kr=r==null?void 0:r.data.attributes)==null?void 0:kr.messages,(_r=r==null?void 0:r.data.attributes)==null?void 0:_r.helperText,(Rr=r==null?void 0:r.data.attributes)==null?void 0:Rr.isDecision,(Ot=r==null?void 0:r.data.attributes)==null?void 0:Ot.label,(Wt=r==null?void 0:r.data.attributes)==null?void 0:Wt.required,(it=r==null?void 0:r.data.attributes)==null?void 0:it.step,(wt=r==null?void 0:r.data.attributes)==null?void 0:wt.type,(It=r==null?void 0:r.data.attributes)==null?void 0:It.values,(Gt=r==null?void 0:r.data)==null?void 0:Gt.children,r==null?void 0:r.data.name,(Lr=r==null?void 0:r.data.attributes)==null?void 0:Lr.repeatable,(Kt=r==null?void 0:r.data.attributes)==null?void 0:Kt.hiddenValue,e,o]),{getDisabledValueField:P,handleAddValue:Er,handleChangeHelperText:Fn,handleChangeHiddenValue:je,handleChangeIsDecisionField:Et,handleChangeLabel:O,handleChangeMessage:Un,handleChangeName:ut,handleChangeOptionLabel:Re,handleChangeOptionMessage:qe,handleChangeOptionValue:A,handleChangeRepeatable:Pn,handleChangeRequired:Dr,handleChangeStep:Ze,handleChangeTreeSelect:Bt,handleChangeType:Yn,handleDeleteValue:Or,handleSubmit:qt,helperText:me,hiddenValue:M,isBooleanField:Y,isDecision:I,isDecisionField:$,isEditModal:Ue,isHiddenField:w,isLeaf:k,isRepeatableDisabled:Q,isRequiredDisabled:L,isTreeField:j,isWorkflowLoading:W,label:g,messages:de,name:h,repeatable:Me,required:x,step:ue,treeSelected:_,type:b,uniqueNameErrorMessage:_e,values:d}},Ya={marginRight:"-20px !important",minWidth:"auto !important"},Ua={iconButton:Ya,iconButtonDelete:{...Ya,"&:before":{borderRadius:"50%",content:'""',height:20,position:"absolute",width:20,zIndex:-1},backgroundColor:ce.background,position:"absolute",right:0,top:"50%",transform:"translateY(-50%)"}},jd=({onClose:e})=>{const{t}=Pe.useTranslation(["translation","form"]),{values:n,required:r,name:o,uniqueNameErrorMessage:a,type:i,helperText:s,label:u,hiddenValue:d,isBooleanField:f,isDecision:h,isEditModal:p,isDecisionField:M,isHiddenField:v,isRequiredDisabled:g,isRepeatableDisabled:m,isTreeField:x,treeSelected:N,isWorkflowLoading:I,repeatable:C,isLeaf:b,messages:{on:q,off:_},handleChangeTreeSelect:Se,handleChangeHelperText:me,handleChangeOptionMessage:R,handleChangeRequired:ue,handleChangeName:he,handleChangeType:de,handleChangeIsDecisionField:se,handleChangeOptionLabel:Me,handleDeleteValue:ye,handleChangeOptionValue:_e,handleChangeMessage:ze,handleSubmit:Ue,handleAddValue:j,handleChangeLabel:w,handleChangeRepeatable:Y,handleChangeHiddenValue:$}=Td();return l.jsxs("form",{onSubmit:Ue,children:[l.jsxs(y.Stack,{spacing:1,paddingY:1,direction:{sm:"row",xs:"column"},children:[l.jsx(y.TextField,{sx:{flex:1},label:t("label",{ns:"form"}),onChange:w,value:u,required:!0}),l.jsx(y.TextField,{label:t("name"),sx:{flex:1},onChange:he,value:o,error:!!a,helperText:a,required:!0})]}),l.jsxs(y.Stack,{spacing:1,paddingY:1,direction:{sm:"row",xs:"column"},children:[l.jsx(pd,{value:i,onChange:de}),l.jsx(Md,{helperText:s,hiddenValue:d,isHiddenField:v,isTreeField:x,treeSelected:N,handleChangeTreeSelect:Se,handleChangeHelperText:me,handleChangeHiddenValue:$})]}),f&&l.jsxs(y.Stack,{spacing:1,paddingY:1,direction:{sm:"row",xs:"column"},children:[l.jsx(y.TextField,{sx:{flex:1},label:t("onMessage",{ns:"form"}),onChange:ze("on"),value:q}),l.jsx(y.TextField,{sx:{flex:1},label:t("offMessage",{ns:"form"}),onChange:ze("off"),value:_})]}),l.jsxs(y.Stack,{paddingY:1,children:[l.jsx(y.FormGroup,{children:l.jsx(y.FormControlLabel,{disabled:m,control:l.jsx(y.Checkbox,{checked:C,onChange:Y}),label:t("repeatable",{ns:"form"})})}),l.jsx(y.FormGroup,{children:l.jsx(y.FormControlLabel,{disabled:g,control:l.jsx(y.Checkbox,{checked:r,onChange:ue}),label:t("required")})}),(b||p)&&l.jsx(y.FormGroup,{children:l.jsx(y.FormControlLabel,{disabled:!M,control:l.jsx(y.Checkbox,{checked:h,onChange:se}),label:t("decisionField",{ns:"form"})})})]}),M&&l.jsxs(l.Fragment,{children:[l.jsx("h4",{children:t("values")}),n==null?void 0:n.map(({value:L,label:Q,id:k,message:P})=>l.jsxs(y.Stack,{direction:{sm:"row",xs:"column"},spacing:1,paddingY:1,position:"relative",children:[l.jsx(y.TextField,{label:t("label",{ns:"form"}),sx:{flex:1},onChange:Me,value:Q,inputProps:{"data-id":k},required:!0}),l.jsx(y.TextField,{label:t("value",{ns:"form"}),sx:{flex:1},onChange:_e,value:L,inputProps:{"data-id":k},required:!0}),l.jsx(y.TextField,{label:"Message",sx:{flex:1},onChange:R,value:P,inputProps:{"data-id":k}}),n.length>1&&l.jsx(y.IconButton,{color:"warning",sx:Ua.iconButtonDelete,value:k,onClick:ye,children:l.jsx(_a,{})})]},k))]}),M&&l.jsx(y.Box,{justifyContent:"flex-end",display:"flex",children:l.jsx(y.IconButton,{color:"success",sx:Ua.iconButton,onClick:j,children:l.jsx(ka,{})})}),l.jsxs(y.Stack,{spacing:2,direction:"row",justifyContent:"flex-end",paddingTop:3,children:[l.jsx(y.Button,{variant:"text",onClick:e,children:t("cancel")}),l.jsx(y.Button,{variant:"contained",type:"submit",disabled:!!a||I,isLoading:I,loadingIndicator:l.jsx(y.CircularProgress,{size:14}),children:t("validate")})]})]})};var In={},Nd=Ie;Object.defineProperty(In,"__esModule",{value:!0});var Fa=In.default=void 0,Dd=Nd(Ae()),Ed=l,Od=(0,Dd.default)((0,Ed.jsx)("path",{d:"M17 11h3c1.11 0 2-.9 2-2V5c0-1.11-.9-2-2-2h-3c-1.11 0-2 .9-2 2v1H9.01V5c0-1.11-.9-2-2-2H4c-1.1 0-2 .9-2 2v4c0 1.11.9 2 2 2h3c1.11 0 2-.9 2-2V8h2v7.01c0 1.65 1.34 2.99 2.99 2.99H15v1c0 1.11.9 2 2 2h3c1.11 0 2-.9 2-2v-4c0-1.11-.9-2-2-2h-3c-1.11 0-2 .9-2 2v1h-1.01c-.54 0-.99-.45-.99-.99V8h2v1c0 1.1.9 2 2 2z"}),"AccountTreeRounded");Fa=In.default=Od;var Cn={},wd=Ie;Object.defineProperty(Cn,"__esModule",{value:!0});var Va=Cn.default=void 0,Id=wd(Ae()),Cd=l,Ad=(0,Id.default)((0,Cd.jsx)("path",{d:"M19 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-3 10h-3v3c0 .55-.45 1-1 1s-1-.45-1-1v-3H8c-.55 0-1-.45-1-1s.45-1 1-1h3V8c0-.55.45-1 1-1s1 .45 1 1v3h3c.55 0 1 .45 1 1s-.45 1-1 1z"}),"AddBoxRounded");Va=Cn.default=Ad;var An={},Sd=Ie;Object.defineProperty(An,"__esModule",{value:!0});var Qa=An.default=void 0,zd=Sd(Ae()),kd=l,_d=(0,zd.default)((0,kd.jsx)("path",{d:"M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V9c0-1.1-.9-2-2-2H8c-1.1 0-2 .9-2 2v10zM9 9h6c.55 0 1 .45 1 1v8c0 .55-.45 1-1 1H9c-.55 0-1-.45-1-1v-8c0-.55.45-1 1-1zm6.5-5-.71-.71c-.18-.18-.44-.29-.7-.29H9.91c-.26 0-.52.11-.7.29L8.5 4H6c-.55 0-1 .45-1 1s.45 1 1 1h12c.55 0 1-.45 1-1s-.45-1-1-1h-2.5z"}),"DeleteOutlineRounded");Qa=An.default=_d;var Sn={},Rd=Ie;Object.defineProperty(Sn,"__esModule",{value:!0});var Ba=Sn.default=void 0,Ld=Rd(Ae()),$d=l,Pd=(0,Ld.default)((0,$d.jsx)("path",{d:"M3 17.46v3.04c0 .28.22.5.5.5h3.04c.13 0 .26-.05.35-.15L17.81 9.94l-3.75-3.75L3.15 17.1c-.1.1-.15.22-.15.36zM20.71 7.04c.39-.39.39-1.02 0-1.41l-2.34-2.34a.9959.9959 0 0 0-1.41 0l-1.83 1.83 3.75 3.75 1.83-1.83z"}),"EditRounded");Ba=Sn.default=Pd;var zn={},Yd=Ie;Object.defineProperty(zn,"__esModule",{value:!0});var qa=zn.default=void 0,Ud=Yd(Ae()),Fd=l,Vd=(0,Ud.default)((0,Fd.jsx)("path",{d:"M12 3c-4.8 0-9 3.86-9 9 0 2.12.74 4.07 1.97 5.61l-1.68 1.68c-.39.39-.39 1.02 0 1.41.39.39 1.02.39 1.41 0l1.68-1.68C7.93 20.26 9.88 21 12 21c2.3 0 4.61-.88 6.36-2.64C20.12 16.61 21 14.3 21 12V5c0-1.1-.9-2-2-2h-7zm3.83 9.26-5.16 4.63c-.16.15-.41.14-.56-.01-.14-.14-.16-.36-.04-.52l2.44-3.33-4.05-.4c-.44-.04-.63-.59-.3-.89l5.16-4.63c.16-.15.41-.14.56.01.14.14.16.36.04.52l-2.44 3.33 4.05.4c.45.04.63.59.3.89z"}),"EnergySavingsLeafRounded");qa=zn.default=Vd;var kn={},Qd=Ie;Object.defineProperty(kn,"__esModule",{value:!0});var Wa=kn.default=void 0,Bd=Qd(Ae()),Ga=l,qd=(0,Bd.default)([(0,Ga.jsx)("path",{d:"M14.14 12h-.06c.81 0 1.28-.91.82-1.57L9.82 3.17c-.4-.57-1.24-.57-1.64 0L3.1 10.43c-.46.66.01 1.57.82 1.57h-.06L.99 16.46c-.43.66.05 1.54.84 1.54H7v2c0 1.1.9 2 2 2s2-.9 2-2v-2h5.17c.79 0 1.27-.88.84-1.54L14.14 12z"},"0"),(0,Ga.jsx)("path",{d:"M23.01 16.46 20.14 12h-.06c.81 0 1.28-.91.82-1.57l-5.08-7.26c-.4-.57-1.24-.57-1.64 0l-1.57 2.24 3.11 4.44c.43.61.48 1.41.14 2.07-.08.16-.18.3-.3.43l2.29 3.57c.4.62.42 1.4.07 2.04-.01.02-.02.03-.03.04h4.28c.79 0 1.27-.88.84-1.54zM13 20c0 1.1.9 2 2 2s2-.9 2-2v-1h-4v1z"},"1")],"ForestRounded");Wa=kn.default=qd;var _n={},Wd=Ie;Object.defineProperty(_n,"__esModule",{value:!0});var Ka=_n.default=void 0,Gd=Wd(Ae()),Kd=l,Jd=(0,Gd.default)((0,Kd.jsx)("path",{d:"M12 4V2.21c0-.45-.54-.67-.85-.35l-2.8 2.79c-.2.2-.2.51 0 .71l2.79 2.79c.32.31.86.09.86-.36V6c3.31 0 6 2.69 6 6 0 .79-.15 1.56-.44 2.25-.15.36-.04.77.23 1.04.51.51 1.37.33 1.64-.34.37-.91.57-1.91.57-2.95 0-4.42-3.58-8-8-8zm0 14c-3.31 0-6-2.69-6-6 0-.79.15-1.56.44-2.25.15-.36.04-.77-.23-1.04-.51-.51-1.37-.33-1.64.34C4.2 9.96 4 10.96 4 12c0 4.42 3.58 8 8 8v1.79c0 .45.54.67.85.35l2.79-2.79c.2-.2.2-.51 0-.71l-2.79-2.79c-.31-.31-.85-.09-.85.36V18z"}),"LoopRounded");Ka=_n.default=Jd;var Rn={},Zd=Ie;Object.defineProperty(Rn,"__esModule",{value:!0});var Ja=Rn.default=void 0,Xd=Zd(Ae()),Hd=l,ef=(0,Xd.default)((0,Hd.jsx)("path",{d:"M16.96 12h.08c.81 0 1.28-.91.82-1.57l-5.08-7.25c-.4-.57-1.24-.57-1.64 0L6.1 10.43c-.46.66.02 1.57.83 1.57h.04l-2.9 4.46c-.44.66.04 1.54.84 1.54h5.08v2.02c0 1.09.89 1.98 1.98 1.98 1.09 0 1.98-.89 1.98-1.98V18h5.15c.8 0 1.28-.89.83-1.55L16.96 12z"}),"ParkRounded");Ja=Rn.default=ef;var Ln={},tf=Ie;Object.defineProperty(Ln,"__esModule",{value:!0});var Za=Ln.default=void 0,rf=tf(Ae()),nf=l,of=(0,rf.default)((0,nf.jsx)("path",{d:"M12 6.5c2.76 0 5 2.24 5 5 0 .51-.1 1-.24 1.46l3.06 3.06c1.39-1.23 2.49-2.77 3.18-4.53C21.27 7.11 17 4 12 4c-1.27 0-2.49.2-3.64.57l2.17 2.17c.47-.14.96-.24 1.47-.24zM2.71 3.16c-.39.39-.39 1.02 0 1.41l1.97 1.97C3.06 7.83 1.77 9.53 1 11.5 2.73 15.89 7 19 12 19c1.52 0 2.97-.3 4.31-.82l2.72 2.72c.39.39 1.02.39 1.41 0 .39-.39.39-1.02 0-1.41L4.13 3.16c-.39-.39-1.03-.39-1.42 0zM12 16.5c-2.76 0-5-2.24-5-5 0-.77.18-1.5.49-2.14l1.57 1.57c-.03.18-.06.37-.06.57 0 1.66 1.34 3 3 3 .2 0 .38-.03.57-.07L14.14 16c-.65.32-1.37.5-2.14.5zm2.97-5.33c-.15-1.4-1.25-2.49-2.64-2.64l2.64 2.64z"}),"VisibilityOffRounded");Za=Ln.default=of;var $n={},af=Ie;Object.defineProperty($n,"__esModule",{value:!0});var Xa=$n.default=void 0,sf=af(Ae()),cf=l,lf=(0,sf.default)((0,cf.jsx)("path",{d:"M12 4C7 4 2.73 7.11 1 11.5 2.73 15.89 7 19 12 19s9.27-3.11 11-7.5C21.27 7.11 17 4 12 4zm0 12.5c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5zm0-8c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3z"}),"VisibilityRounded");Xa=$n.default=lf;const De={actionButton:{minWidth:"auto !important"},container:{background:ce.background,borderRadius:"1rem"},containerField:{background:ce.background,border:`solid 1px ${ce.primary}`,borderRadius:"1rem"},containerHidden:{background:ce.background,border:`solid 1px ${ce.borderGrey}`,borderRadius:"1rem"},containerTree:{background:ce.tertiary,border:`solid 1px ${ce.primary}`,borderRadius:"1rem"},containerValue:{background:ce.background,border:`solid 1px ${ce.secondary}`,borderRadius:"1rem"},icon:{color:ce.grey500},nodeSvg:{stroke:"transparent !important"},stepChip:{fontSize:".7rem !important",fontWeight:"bold",height:"20px !important"},title:{display:"-webkit-box",margin:0,overflow:"hidden",textAlign:"right",textOverflow:"ellipsis",webkitBoxOrient:"vertical",webkitLineClamp:2}},uf=e=>{const t=!!e,n=e==="tree";return e==="hidden"?De.containerHidden:n?De.containerTree:t?De.containerField:De.containerValue},df=({nodeDatum:e,onAddChildren:t,onEditChildren:n,onDeleteChildren:r,onOpenTreeModal:o,hierarchyPointNode:a,size:i=220})=>{var q;const{t:s}=Pe.useTranslation(["translation","form"]),{attributes:u}=e||{},{isRoot:d,isLeaf:f,required:h,isDecision:p,step:M,type:v,label:g,repeatable:m}=u||{},x=!!v,N=v==="tree",I=v==="hidden",C=!x,b=!d&&!f;return l.jsxs("g",{children:[l.jsx(y.GlobalStyles,{styles:{".rd3t-node svg":De.nodeSvg}}),l.jsx(y.Box,{component:"foreignObject",height:i,width:i,x:`-${i/2}`,y:`-${i/2}`,sx:uf(v),children:l.jsxs(y.Box,{flex:1,display:"flex",p:2,height:"100%",flexDirection:"column",justifyContent:"space-between",children:[l.jsxs(y.Stack,{alignItems:"flex-end",spacing:.5,children:[x&&l.jsxs(y.Stack,{direction:"row",spacing:1,alignItems:"center",children:[M&&l.jsx(y.Tooltip,{title:`${s("step",{ns:"form"})} ${(q=e==null?void 0:e.attributes)==null?void 0:q.step}`,placement:"left",arrow:!0,children:l.jsx(y.Chip,{color:"primary",size:"small",label:M,sx:De.stepChip})}),l.jsx(y.Typography,{variant:"subtitle2",sx:De.title,children:l.jsx("strong",{children:g})})]}),x&&l.jsx(y.Chip,{color:"info",size:"small",label:s(`type.${v}`,{ns:"form"})}),h&&l.jsx(y.Stack,{direction:"row",spacing:.5,children:h&&l.jsx(y.Chip,{color:"warning",size:"small",variant:"outlined",label:s("required")})}),l.jsx(y.Stack,{spacing:.5,alignItems:"flex-end",children:C&&l.jsx(y.Typography,{variant:"subtitle2",sx:De.title,children:l.jsx("strong",{children:g})})}),l.jsxs(y.Stack,{paddingTop:.5,spacing:.5,direction:"row",children:[m&&l.jsx(y.Tooltip,{title:s("isARepeatable"),placement:"bottom",arrow:!0,children:l.jsx(Ka,{style:De.icon})}),f&&l.jsx(y.Tooltip,{title:s("isALeaf"),placement:"bottom",arrow:!0,children:l.jsx(qa,{style:De.icon})}),I&&l.jsx(y.Tooltip,{title:s("isAHidden"),placement:"bottom",arrow:!0,children:l.jsx(Za,{style:De.icon})}),d&&l.jsx(y.Tooltip,{title:s("isTheRoot"),placement:"bottom",arrow:!0,children:l.jsx(Ja,{style:De.icon})}),b&&l.jsx(y.Tooltip,{title:s("isABranch"),placement:"bottom",arrow:!0,children:l.jsx(Fa,{style:De.icon})}),N&&l.jsx(y.Tooltip,{title:s("isATree"),placement:"bottom",arrow:!0,children:l.jsx(Wa,{style:De.icon})})]})]}),l.jsxs(y.Stack,{direction:"row",justifyContent:"flex-end",spacing:0,alignSelf:"flex-end",children:[!d&&l.jsx(y.Tooltip,{title:s("remove"),arrow:!0,children:l.jsx(y.Button,{variant:"text",sx:De.actionButton,size:"small",color:"error",onClick:()=>r==null?void 0:r(a),children:l.jsx(Qa,{})})}),!C&&l.jsx(y.Tooltip,{title:s("edit"),arrow:!0,children:l.jsx(y.Button,{variant:"text",color:"secondary",sx:De.actionButton,size:"small",onClick:()=>n==null?void 0:n(a),children:l.jsx(Ba,{})})}),!p&&l.jsx(y.Tooltip,{title:s("add"),arrow:!0,children:l.jsx(y.Button,{variant:"text",color:"success",sx:De.actionButton,size:"small",onClick:()=>t==null?void 0:t(a),children:l.jsx(Va,{})})}),N&&l.jsx(y.Tooltip,{title:s("show"),arrow:!0,children:l.jsx(y.Button,{variant:"text",color:"info",sx:De.actionButton,size:"small",onClick:()=>o==null?void 0:o(a),children:l.jsx(Xa,{})})})]})]})})]})},ff=S.memo(df),Ha=()=>{const{setModalOpen:e,setCurrentHierarchyPointNode:t,setTreeModalOpen:n,setTreePath:r}=we();return{handleAddChildren:d=>{t(d),e("add")},handleCloseTreeModal:()=>{r([]),n(!1)},handleDeleteChildren:d=>{t(d),e("delete")},handleEditChildren:d=>{t(d),e("edit")},handleOpenTreeModal:d=>{var h,p;const f={label:d==null?void 0:d.data.attributes.label,path:((p=(h=d==null?void 0:d.data)==null?void 0:h.attributes)==null?void 0:p.treePath)||""};r(M=>[...M,f]),n(!0)}}},pf=({nodeDatum:e,hierarchyPointNode:t,toggleNode:n,onNodeClick:r,onNodeMouseOver:o,onNodeMouseOut:a,addChildren:i})=>{const{handleDeleteChildren:s,handleEditChildren:u,handleAddChildren:d,handleOpenTreeModal:f}=Ha();return l.jsx(ff,{addChildren:i,nodeDatum:e,hierarchyPointNode:t,toggleNode:n,onNodeClick:r,onNodeMouseOver:o,onNodeMouseOut:a,onAddChildren:d,onOpenTreeModal:f,onDeleteChildren:s,onEditChildren:u})},ei=({nodeDatum:e,hierarchyPointNode:t,toggleNode:n,onNodeClick:r,onNodeMouseOver:o,onNodeMouseOut:a,addChildren:i})=>l.jsx(pf,{addChildren:i,nodeDatum:e,hierarchyPointNode:t,toggleNode:n,onNodeClick:r,onNodeMouseOver:o,onNodeMouseOut:a}),hf=()=>{const{t:e}=Pe.useTranslation(["modal","snackMessage"]),{currentHierarchyPointNode:t,modalOpen:n,setModalOpen:r}=we(),o=n==="edit";return{closeModal:()=>r(null),getTitleModalDelete:()=>{var p,M;const h=(M=(p=t==null?void 0:t.data)==null?void 0:p.attributes)==null?void 0:M.label;return e("deleteTitle",{name:h,ns:"modal"})},getTitleModalMutation:()=>{var M;const h=(M=t==null?void 0:t.data)==null?void 0:M.attributes.label;return h?e(o?"editTitle":"addTitle",{name:h,ns:"modal"}):e("addFirstTitle",{name:h,ns:"modal"})},isDeleteModal:n==="delete",isModalMutationOpen:o||n==="add"}},gf=()=>{const{currentTree:e,setCurrentTree:t,tree:n}=we(),{name:r,errorName:o,id:a}=e;return{disabled:!!e.id&&!n,errorName:o,handleChangeName:u=>{const{value:d}=u.target;if(!d){t(f=>({...f,errorName:"Champs requis",name:u.target.value}));return}t(f=>({...f,errorName:"",name:u.target.value}))},id:a,name:r}},mf=()=>{const{t:e}=Pe.useTranslation("form"),{name:t,handleChangeName:n,errorName:r,disabled:o}=gf();return l.jsx(y.TextField,{required:!0,label:e("treeName",{ns:"form"}),size:"small",onChange:n,value:t,error:!!r,disabled:o})},yf=()=>{var M,v;const{tree:e,treeModalOpen:t,treePath:n,backendConfig:r}=we(),{handleCloseTreeModal:o}=Ha(),{getTitleModalMutation:a,closeModal:i,getTitleModalDelete:s,isModalMutationOpen:u,isDeleteModal:d}=hf(),f=(M=n==null?void 0:n.at(-1))==null?void 0:M.path,h=(v=n==null?void 0:n.at(-1))==null?void 0:v.label,p=e&&Dt(e,f);return l.jsxs(l.Fragment,{children:[l.jsxs(Hu,{children:[l.jsx(Ju,{children:l.jsxs(y.Stack,{justifyContent:"space-between",direction:"row",alignItems:"center",children:[l.jsx(Di,{}),!!(r!=null&&r.baseUrl)&&l.jsxs(y.Stack,{direction:"row",alignItems:"center",spacing:2,children:[l.jsx(mf,{}),l.jsx($a,{size:"small",arrowOnly:!0,showBtnAddNewTree:!0,fetchWorkflowsOnOpen:!0})]})]})}),l.jsx(Xu,{children:l.jsx(Xn,{data:e,renderCustomNodeElement:ei})}),l.jsx(td,{children:l.jsx(Ai,{value:e})}),l.jsx(Gu,{children:l.jsx($u,{value:e})})]}),l.jsx(Aa,{open:u,onClose:i,title:a(),children:l.jsx(jd,{onClose:i})}),l.jsx(Aa,{open:d,onClose:i,title:s(),children:l.jsx(nd,{onClose:i})}),l.jsx(qu,{open:t,onClose:o,title:h,children:p&&l.jsx(Xn,{data:p,renderCustomNodeElement:ei})})]})},vf="0.11.4",bf=({children:e,initialTree:t,initialTreeId:n,backendConfig:r})=>{const[o,a]=S.useState(Ve.currentHierarchyPointNode),[i,s]=S.useState(Ve.modalOpen),[u,d]=S.useState(Ve.treeModalOpen),[f,h]=S.useState(Ve.treePath),[p,M]=S.useReducer(ku,t||Ve.tree),[v,g]=S.useState(n?{...Ve.currentTree,id:n}:Ve.currentTree),m=S.useMemo(()=>{var x,N;return{backendConfig:{baseUrl:((x=Ve==null?void 0:Ve.backendConfig)==null?void 0:x.baseUrl)||"",...Ve.backendConfig,...r,endpoints:{...(N=Ve.backendConfig)==null?void 0:N.endpoints,...r==null?void 0:r.endpoints}},currentHierarchyPointNode:o,currentTree:v,dispatchTree:M,modalOpen:i,setCurrentHierarchyPointNode:a,setCurrentTree:g,setModalOpen:s,setTreeModalOpen:d,setTreePath:h,tree:p,treeModalOpen:u,treePath:f,version:vf}},[r,o,v,i,p,u,f]);return Zt(v.id,{enabled:!!n,onSuccess:async x=>{x&&(g({id:x==null?void 0:x.id,name:x==null?void 0:x.label}),M(Ca((x==null?void 0:x.workflow)||null)))}}),l.jsx(Jn.Provider,{value:m,children:e})},Mf={close:"Close",createTree:"Create Tree",downloadJSONFile:"Download JSON File",reset:"Reset",resetTree:"Reset tree",save:"Save",update:"Update"},xf={error:{fetchTree:"An error has occurred. Please try again",saveTree:"An error has occurred. Please try again",updateTree:"An error has occurred. Please try again"},success:{saveTree:"Tree registered",updateTree:"Tree updated"}},Tf={add:"Add",cancel:"Cancel",disabled:"Disabled",edit:"Edit",isABranch:"Is a branch",isAHidden:"Is a hidden field",isALeaf:"Is a leaf",isARepeatable:"Is a repeatable",isATree:"Is a tree",isTheRoot:"Is the root",label:"Label",name:"Name",remove:"Remove",required:"Required",save:"Save",show:"Show",type:"Type",validate:"Validate",value:"Value",values:"Values"},jf={close:"Fermer",createTree:"Créer un arbre",downloadJSONFile:"Télécharger le fichier JSON",reset:"Réinitialiser",resetTree:"Réinitialiser l'arbre",save:"Enregistrer",update:"Modifier"},ti={decisionField:"Champs de décision",helperText:"Texte d'information",hiddenValue:"Valeur caché",label:"Label",mustBeUnique:"Doit être unique",newTree:"Nouvel arbre",offMessage:"Message (désactiver)",onMessage:"Message (activer)",repeatable:"Répétable",staticFields:"Champs statiques",step:"Étape",tree:"Arbre",treeName:"Nom de l'arbre",type:{address:"Adresse",checkbox:"Case à cocher",date:"Date",email:"Email",file:"Fichier",hidden:"Champs caché",number:"Nombre",password:"Mot de passe",radio:"Radio",select:"Select",switch:"Switch",tel:"Téléphone",text:"Texte",time:"Temps",tree:"Arbre",url:"URL"},value:"Valeur",values:"Valeurs"},ri={addFirstTitle:"Ajouter un champ",addTitle:"Ajouter un champ à « {{name}} »",deleteTitle:"Voulez vraiment supprimer « {{name}} »",editTitle:"Éditer le champ « {{name}} »",resetTreeContent:"Êtes-vous sûr de vouloir réinitialiser l'arbre ?",saveTree:"Enregistrer l'arbre"},Nf={error:{fetchTree:"Une erreur est survenue veuillez réessayer",saveTree:"Une erreur est survenue veuillez réessayer",updateTree:"Une erreur est survenue veuillez réessayer"},success:{saveTree:"Arbre enregistré",updateTree:"Arbre mis à jour"}},Df={add:"Ajouter",cancel:"Annuler",disabled:"Désactivé",edit:"Éditer",isABranch:"Est une branche",isAHidden:"Est un champs caché",isALeaf:"Est une feuille",isARepeatable:"Est répétable",isATree:"Est un arbre",isTheRoot:"Est la racine",label:"Label",name:"Nom",remove:"Supprimer",required:"Requis",save:"Enregistrer",show:"Afficher",type:"Type",validate:"Valider",value:"Valeur",values:"Valeurs"};At.use(ci).use(Pe.initReactI18next).init({debug:!1,fallbackLng:"en",interpolation:{escapeValue:!1},load:"languageOnly",react:{useSuspense:!0},resources:{en:{button:Mf,form:ti,modal:ri,snackMessage:xf,translation:Tf},fr:{button:jf,form:ti,modal:ri,snackMessage:Nf,translation:Df}},returnNull:!1}).then(()=>{document.documentElement.lang!==At.resolvedLanguage&&At.resolvedLanguage&&document.documentElement.setAttribute("lang",At.resolvedLanguage)}),At.on("languageChanged",e=>{document.documentElement.setAttribute("lang",e)});const Ef=({initialTree:e,initialTreeId:t,backendConfig:n})=>(S.useLayoutEffect(()=>{pt.defaults.baseURL=n==null?void 0:n.baseUrl,n!=null&&n.authToken&&(pt.defaults.headers.common.Authorization=`Bearer ${n==null?void 0:n.authToken}`)},[n==null?void 0:n.authToken,n==null?void 0:n.baseUrl]),l.jsx(ft.QueryClientProvider,{client:mi,children:l.jsx(bi,{authToken:n==null?void 0:n.authToken,children:l.jsx(bf,{backendConfig:n,initialTree:e,initialTreeId:t,children:l.jsx(gi,{children:l.jsx(ji,{children:l.jsx(yf,{})})})})})}));Ne.TreePlusIcon=Kn,Ne.Treege=Ef,Object.defineProperty(Ne,Symbol.toStringTag,{value:"Module"})});
|
|
107
|
+
} });`:ut(12,m?` (${m})`:"",JSON.stringify(g.main)));return va(g,"light",O,r),va(g,"dark",I,r),g.contrastText||(g.contrastText=p(g.main)),g},M={dark:xn,light:ya};return process.env.NODE_ENV!=="production"&&(M[t]||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),We(Z({common:Z({},$t),mode:t,primary:h({color:a,name:"primary"}),secondary:h({color:i,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:h({color:l,name:"error"}),warning:h({color:f,name:"warning"}),info:h({color:u,name:"info"}),success:h({color:d,name:"success"}),grey:_c,contrastThreshold:n,getContrastText:p,augmentColor:h,tonalOffset:r},M[t]),o)}const Qc=["fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem"];function Bc(e){return Math.round(e*1e5)/1e5}const ba={textTransform:"uppercase"},Ma='"Roboto", "Helvetica", "Arial", sans-serif';function qc(e,t){const n=typeof t=="function"?t(e):t,{fontFamily:r=Ma,fontSize:o=14,fontWeightLight:a=300,fontWeightRegular:i=400,fontWeightMedium:l=500,fontWeightBold:u=700,htmlFontSize:d=16,allVariants:f,pxToRem:p}=n,h=tt(n,Qc);process.env.NODE_ENV!=="production"&&(typeof o!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof d!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const M=o/14,v=p||(x=>`${x/d*M}rem`),g=(x,O,I,A,b)=>Z({fontFamily:r,fontWeight:x,fontSize:v(O),lineHeight:I},r===Ma?{letterSpacing:`${Bc(A/O)}em`}:{},b,f),m={h1:g(a,96,1.167,-1.5),h2:g(a,60,1.2,-.5),h3:g(i,48,1.167,0),h4:g(i,34,1.235,.25),h5:g(i,24,1.334,0),h6:g(l,20,1.6,.15),subtitle1:g(i,16,1.75,.15),subtitle2:g(l,14,1.57,.1),body1:g(i,16,1.5,.15),body2:g(i,14,1.43,.15),button:g(l,14,1.75,.4,ba),caption:g(i,12,1.66,.4),overline:g(i,12,2.66,1,ba),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return We(Z({htmlFontSize:d,pxToRem:v,fontFamily:r,fontSize:o,fontWeightLight:a,fontWeightRegular:i,fontWeightMedium:l,fontWeightBold:u},m),h,{clone:!1})}const Wc=.2,Gc=.14,Kc=.12;function ge(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${Wc})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${Gc})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${Kc})`].join(",")}const Jc=["none",ge(0,2,1,-1,0,1,1,0,0,1,3,0),ge(0,3,1,-2,0,2,2,0,0,1,5,0),ge(0,3,3,-2,0,3,4,0,0,1,8,0),ge(0,2,4,-1,0,4,5,0,0,1,10,0),ge(0,3,5,-1,0,5,8,0,0,1,14,0),ge(0,3,5,-1,0,6,10,0,0,1,18,0),ge(0,4,5,-2,0,7,10,1,0,2,16,1),ge(0,5,5,-3,0,8,10,1,0,3,14,2),ge(0,5,6,-3,0,9,12,1,0,3,16,2),ge(0,6,6,-3,0,10,14,1,0,4,18,3),ge(0,6,7,-4,0,11,15,1,0,4,20,3),ge(0,7,8,-4,0,12,17,2,0,5,22,4),ge(0,7,8,-4,0,13,19,2,0,5,24,4),ge(0,7,9,-4,0,14,21,2,0,5,26,4),ge(0,8,9,-5,0,15,22,2,0,6,28,5),ge(0,8,10,-5,0,16,24,2,0,6,30,5),ge(0,8,11,-5,0,17,26,2,0,6,32,5),ge(0,9,11,-5,0,18,28,2,0,7,34,6),ge(0,9,12,-6,0,19,29,2,0,7,36,6),ge(0,10,13,-6,0,20,31,3,0,8,38,7),ge(0,10,13,-6,0,21,33,3,0,8,40,7),ge(0,10,14,-6,0,22,35,3,0,8,42,7),ge(0,11,14,-7,0,23,36,3,0,9,44,8),ge(0,11,15,-7,0,24,38,3,0,9,46,8)],Zc=["duration","easing","delay"],Xc={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},Hc={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function xa(e){return`${Math.round(e)}ms`}function eu(e){if(!e)return 0;const t=e/36;return Math.round((4+15*t**.25+t/5)*10)}function tu(e){const t=Z({},Xc,e.easing),n=Z({},Hc,e.duration);return Z({getAutoHeightDuration:eu,create:(o=["all"],a={})=>{const{duration:i=n.standard,easing:l=t.easeInOut,delay:u=0}=a,d=tt(a,Zc);if(process.env.NODE_ENV!=="production"){const f=h=>typeof h=="string",p=h=>!isNaN(parseFloat(h));!f(o)&&!Array.isArray(o)&&console.error('MUI: Argument "props" must be a string or Array.'),!p(i)&&!f(i)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`),f(l)||console.error('MUI: Argument "easing" must be a string.'),!p(u)&&!f(u)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof a!="object"&&console.error(["MUI: Secong argument of transition.create must be an object.","Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(`
|
|
108
|
+
`)),Object.keys(d).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(d).join(",")}].`)}return(Array.isArray(o)?o:[o]).map(f=>`${f} ${typeof i=="string"?i:xa(i)} ${l} ${typeof u=="string"?u:xa(u)}`).join(",")}},e,{easing:t,duration:n})}const ru={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500},nu=["breakpoints","mixins","spacing","palette","transitions","typography","shape"];function ou(e={},...t){const{mixins:n={},palette:r={},transitions:o={},typography:a={}}=e,i=tt(e,nu);if(e.vars)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name.":ut(18));const l=Vc(r),u=bn(e);let d=We(u,{mixins:zc(u.breakpoints,n),palette:l,shadows:Jc.slice(),typography:qc(l,a),transitions:tu(o),zIndex:Z({},ru)});if(d=We(d,i),d=t.reduce((f,p)=>We(f,p),d),process.env.NODE_ENV!=="production"){const f=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],p=(h,M)=>{let v;for(v in h){const g=h[v];if(f.indexOf(v)!==-1&&Object.keys(g).length>0){if(process.env.NODE_ENV!=="production"){const m=tn("",v);console.error([`MUI: The \`${M}\` component increases the CSS specificity of the \`${v}\` internal state.`,"You can not override it like this: ",JSON.stringify(h,null,2),"",`Instead, you need to use the '&.${m}' syntax:`,JSON.stringify({root:{[`&.${m}`]:g}},null,2),"","https://mui.com/r/state-classes-guide"].join(`
|
|
109
|
+
`))}h[v]={}}}};Object.keys(d.components).forEach(h=>{const M=d.components[h].styleOverrides;M&&h.indexOf("Mui")===0&&p(M,h)})}return d.unstable_sxConfig=Z({},yn,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(p){return vn({sx:p,theme:this})},d}const Ta=ou(),ja="$$material";function au({props:e,name:t}){return wc({props:e,name:t,defaultTheme:Ta,themeId:ja})}const iu=Oc({themeId:ja,defaultTheme:Ta,rootShouldForwardProp:e=>xr(e)&&e!=="classes"});function su(e){return tn("MuiSvgIcon",e)}gs("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const lu=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],cu=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${Ge(t)}`,`fontSize${Ge(n)}`]};return ps(o,su,r)},uu=iu("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${Ge(n.color)}`],t[`fontSize${Ge(n.fontSize)}`]]}})(({theme:e,ownerState:t})=>{var n,r,o,a,i,l,u,d,f,p,h,M,v;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:(n=e.transitions)==null||(r=n.create)==null?void 0:r.call(n,"fill",{duration:(o=e.transitions)==null||(o=o.duration)==null?void 0:o.shorter}),fontSize:{inherit:"inherit",small:((a=e.typography)==null||(i=a.pxToRem)==null?void 0:i.call(a,20))||"1.25rem",medium:((l=e.typography)==null||(u=l.pxToRem)==null?void 0:u.call(l,24))||"1.5rem",large:((d=e.typography)==null||(f=d.pxToRem)==null?void 0:f.call(d,35))||"2.1875rem"}[t.fontSize],color:(p=(h=(e.vars||e).palette)==null||(h=h[t.color])==null?void 0:h.main)!=null?p:{action:(M=(e.vars||e).palette)==null||(M=M.action)==null?void 0:M.active,disabled:(v=(e.vars||e).palette)==null||(v=v.action)==null?void 0:v.disabled,inherit:void 0}[t.color]}}),Tn=G.forwardRef(function(t,n){const r=au({props:t,name:"MuiSvgIcon"}),{children:o,className:a,color:i="inherit",component:l="svg",fontSize:u="medium",htmlColor:d,inheritViewBox:f=!1,titleAccess:p,viewBox:h="0 0 24 24"}=r,M=tt(r,lu),v=G.isValidElement(o)&&o.type==="svg",g=Z({},r,{color:i,component:l,fontSize:u,instanceFontSize:t.fontSize,inheritViewBox:f,viewBox:h,hasSvgAsChild:v}),m={};f||(m.viewBox=h);const x=cu(g);return c.jsxs(uu,Z({as:l,className:ms(x.root,a),focusable:"false",color:d,"aria-hidden":p?void 0:!0,role:p?"img":void 0,ref:n},m,M,v&&o.props,{ownerState:g,children:[v?o.props.children:o,p?c.jsx("title",{children:p}):null]}))});process.env.NODE_ENV!=="production"&&(Tn.propTypes={children:ue.node,classes:ue.object,className:ue.string,color:ue.oneOfType([ue.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),ue.string]),component:ue.elementType,fontSize:ue.oneOfType([ue.oneOf(["inherit","large","medium","small"]),ue.string]),htmlColor:ue.string,inheritViewBox:ue.bool,shapeRendering:ue.string,sx:ue.oneOfType([ue.arrayOf(ue.oneOfType([ue.func,ue.object,ue.bool])),ue.func,ue.object]),titleAccess:ue.string,viewBox:ue.string}),Tn.muiName="SvgIcon";const Da=Tn;function du(e,t){function n(r,o){return c.jsx(Da,Z({"data-testid":`${t}Icon`,ref:o},r,{children:e}))}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=Da.muiName,G.memo(G.forwardRef(n))}const fu=pi(Object.freeze(Object.defineProperty({__proto__:null,capitalize:Ge,createChainedFunction:Gi,createSvgIcon:du,debounce:Ki,deprecatedPropType:Ji,isMuiElement:Zi,ownerDocument:xo,ownerWindow:Xi,requirePropFactory:Hi,setRef:To,unstable_ClassNameGenerator:{configure:e=>{process.env.NODE_ENV!=="production"&&console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.","","You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead","","The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401","","The updated documentation: https://mui.com/guides/classname-generator/"].join(`
|
|
110
|
+
`)),wo.configure(e)}},unstable_useEnhancedEffect:jo,unstable_useId:ts,unsupportedProp:rs,useControlled:ns,useEventCallback:os,useForkRef:as,useIsFocusVisible:fs},Symbol.toStringTag,{value:"Module"})));var Na;function ke(){return Na||(Na=1,function(e){"use client";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return t.createSvgIcon}});var t=fu}(Vr)),Vr}var pu=Ae;Object.defineProperty(Ur,"__esModule",{value:!0});var Ea=Ur.default=void 0,hu=pu(ke()),gu=c,mu=(0,hu.default)((0,gu.jsx)("path",{d:"M6.56 7.98C6.1 7.52 5.31 7.6 5 8.17c-.28.51-.5 1.03-.67 1.58-.19.63.31 1.25.96 1.25h.01c.43 0 .82-.28.94-.7.12-.4.28-.79.48-1.17.22-.37.15-.84-.16-1.15zM5.31 13h-.02c-.65 0-1.15.62-.96 1.25.16.54.38 1.07.66 1.58.31.57 1.11.66 1.57.2.3-.31.38-.77.17-1.15-.2-.37-.36-.76-.48-1.16-.12-.44-.51-.72-.94-.72zm2.85 6.02c.51.28 1.04.5 1.59.66.62.18 1.24-.32 1.24-.96v-.03c0-.43-.28-.82-.7-.94-.4-.12-.78-.28-1.15-.48-.38-.21-.86-.14-1.16.17l-.03.03c-.45.45-.36 1.24.21 1.55zM13 4.07v-.66c0-.89-1.08-1.34-1.71-.71L9.17 4.83c-.4.4-.4 1.04 0 1.43l2.13 2.08c.63.62 1.7.17 1.7-.72V6.09c2.84.48 5 2.94 5 5.91 0 2.73-1.82 5.02-4.32 5.75-.41.12-.68.51-.68.94v.02c0 .65.61 1.14 1.23.96C17.57 18.71 20 15.64 20 12c0-4.08-3.05-7.44-7-7.93z"}),"RotateLeftRounded");Ea=Ur.default=mu;var jn={},yu=Ae;Object.defineProperty(jn,"__esModule",{value:!0});var Oa=jn.default=void 0,vu=yu(ke()),bu=c,Mu=(0,vu.default)((0,bu.jsx)("path",{d:"M17.59 3.59c-.38-.38-.89-.59-1.42-.59H5c-1.11 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V7.83c0-.53-.21-1.04-.59-1.41l-2.82-2.83zM12 19c-1.66 0-3-1.34-3-3s1.34-3 3-3 3 1.34 3 3-1.34 3-3 3zm1-10H7c-1.1 0-2-.9-2-2s.9-2 2-2h6c1.1 0 2 .9 2 2s-.9 2-2 2z"}),"SaveRounded");Oa=jn.default=Mu;var Dn={},xu=Ae;Object.defineProperty(Dn,"__esModule",{value:!0});var Ca=Dn.default=void 0,Tu=xu(ke()),ju=c,Du=(0,Tu.default)((0,ju.jsx)("path",{d:"M18 2h-7.17c-.53 0-1.04.21-1.42.59L4.59 7.41C4.21 7.79 4 8.3 4 8.83V20c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-6.35 14.65-2.79-2.79c-.32-.32-.1-.86.35-.86H11v-2.99c0-.55.44-.99.99-1 .56-.01 1.01.44 1.01 1V13h1.79c.45 0 .67.54.35.85l-2.79 2.79c-.19.2-.51.2-.7.01z"}),"SimCardDownloadRounded");Ca=Dn.default=Du;const wa=(e,t)=>{if(!e)return null;if(e.name===t)return e;const n=e.children||[];for(let r=0;r<n.length;r+=1){const o=n[r],a=wa(o,t);if(a)return a}return null},xt=(e,t)=>{var a,i,l,u,d;if(!e)return null;if(!t)return e;if(((a=e.attributes)==null?void 0:a.treePath)===t)return((i=e.attributes)==null?void 0:i.tree)||null;let n=null;const r=(l=e.attributes)==null?void 0:l.tree,o=(u=e.children)==null?void 0:u.length;if(r&&(n=xt((d=e.attributes)==null?void 0:d.tree,t)),o){const{children:f}=e;for(let p=0;p<f.length;p+=1){const h=f[p];if(n!==null)return n;n=xt(h,t)}}return n},jr=(e,t,n)=>{const r=xt(e,t);return wa(r,n)},Nu=(e,t)=>{if(!e)return null;const{attributes:n}=t,r=n.isDecision;return Object.defineProperty(e,"attributes",{value:{...e.attributes,isLeaf:!1}}),r?(Object.defineProperty(e,"children",{value:[{...t,attributes:{...n,isLeaf:!1}}]}),null):(Object.defineProperty(e,"children",{value:[{...t,attributes:{...n,isLeaf:!e.children.length}}]}),null)},Eu=({tree:e,path:t,name:n,child:r})=>{var u;const{attributes:o,children:a}=r;if(!e)return a.length?{...r}:{...r,attributes:{...o,isLeaf:!0,isRoot:!0}};const i=structuredClone(e),l=jr(i,t,n);return Nu(l,{...r,...!o.isDecision&&{children:[...((u=jr(e,t,n))==null?void 0:u.children)||[]]}}),i},Ia=(e,t,n=null)=>{if(!e)return null;if(e.name===t)return n;const r=e.children||[];for(let o=0;o<r.length;o+=1){const a=r[o],i=Ia(a,t,e);if(i!==null)return i}return null},Ou=(e,t)=>(!e||!t||(Object.defineProperty(e,"children",{value:e.children.filter(n=>n.name!==t.name)}),Object.defineProperty(e,"attributes",{value:{...e.attributes,isLeaf:!0}})),null),Cu=(e,t,n)=>{const r=xt(e,t);return Ia(r,n)},wu=({tree:e,path:t,name:n})=>{const r=structuredClone(e),o=jr(r,t,n),a=Cu(r,t,n);return Ou(a,o),r},Iu=e=>{if(!e)return[];const t=[],n=r=>{if(r.name&&t.push(r.name),r.children.length){const{children:o}=r;for(let a=0;a<o.length;a+=1)n(o[a])}};return n(e),t},Au=(e,t)=>{if(!e)return null;const n=t.attributes.isDecision,r=e.attributes.isDecision,o=e.attributes.depth===0,a={value:t.name},i=r||n,l=i?{value:[...t.children]}:{value:[...e.children]},u=i?{value:{...t.attributes,isLeaf:!t.children.length||!n,isRoot:o}}:{value:{...t.attributes,isLeaf:!e.children.length,isRoot:o}};return Object.defineProperties(e,{attributes:u,children:l,name:a}),null},Su=({tree:e,path:t,name:n,child:r})=>{const o=structuredClone(e),a=jr(o,t,n);return Au(a,r),o},et={appendTreeCard:"appendTreeCard",deleteTreeCard:"deleteTreeCard",replaceTreeCard:"replaceTreeCard",resetTree:"resetTree",setTree:"setTree"},ku=(e,t,n)=>({children:n,name:t,path:e,type:et.appendTreeCard}),zu=(e,t,n)=>({children:n,name:t,path:e,type:et.replaceTreeCard}),_u=(e,t)=>({name:t,path:e,type:et.deleteTreeCard}),Aa=()=>({type:et.resetTree}),Sa=e=>({tree:e,type:et.setTree}),Ru=(e,t)=>{switch(t.type){case et.appendTreeCard:{const{name:n,path:r,children:o}=t;return Eu({child:o,name:n,path:r,tree:e})}case et.deleteTreeCard:{const{path:n,name:r}=t;return wu({name:r,path:n,tree:e})}case et.replaceTreeCard:{const{name:n,path:r,children:o}=t;return Su({child:o,name:n,path:r,tree:e})}case et.resetTree:return null;case et.setTree:return t.tree;default:throw new Error}},Nn=()=>{const{dispatchSnackbar:e}=N.useContext(Kn);return{close:()=>e(Jn()),open:(r,o="success")=>e(Ti(r,o))}},Lu=e=>{const{backendConfig:t}=Ce(),{endpoints:n}=t||{},{workflow:r=""}=n||{};return lt.useMutation(["patchWorkflow"],async o=>{const{data:a}=await ct.patch(r,o);return a},e)},$u=e=>{const{backendConfig:t}=Ce(),{endpoints:n}=t||{},{workflow:r=""}=n||{};return lt.useMutation(["postWorkflow"],async o=>{const{data:a}=await ct.post(r,o);return a},e)},Pu=()=>{const{t:e}=$e.useTranslation(["snackMessage"]),{open:t}=Nn(),{setCurrentTree:n,currentTree:r,tree:o,dispatchTree:a}=Ce(),[i,l]=N.useState(!1),{version:u}=Ce(),{mutate:d}=$u({onError:()=>{t(e("error.saveTree",{ns:"snackMessage"}),"error")},onSuccess:x=>{t(e("success.saveTree",{ns:"snackMessage"})),n(O=>({...O,id:x.workflow_id}))}}),{mutate:f}=Lu({onError:()=>{t(e("error.updateTree",{ns:"snackMessage"}),"error")},onSuccess:()=>{t(e("success.updateTree",{ns:"snackMessage"}))}}),p=x=>JSON.stringify(x,null,2),h=x=>`data:text/json;charset=utf-8,${encodeURIComponent(p(x))}`,M=()=>{l(!1)};return{formatJSON:p,getDownloadLink:h,handleClose:M,handleOpen:()=>{l(!0)},handleResetTree:()=>{a(Aa()),M()},handleSubmit:()=>{const{name:x,id:O}=r;if(!x){n(I=>({...I,errorName:"Champs Requis"}));return}if(o){if(O){f({id:O,label:x,version:u,workflow:o});return}d({label:x,version:u,workflow:o})}},openModal:i}},Yu=({downloadedFileName:e="export",value:t})=>{const{t:n}=$e.useTranslation(),{getDownloadLink:r,handleSubmit:o,handleClose:a,handleOpen:i,handleResetTree:l,openModal:u}=Pu(),{currentTree:d,backendConfig:f,tree:p}=Ce(),{id:h}=d;return c.jsxs(y.Stack,{direction:"row",spacing:2,justifyContent:"center",children:[c.jsx(y.Tooltip,{title:n("resetTree",{ns:"button"}),enterDelay:1500,disableHoverListener:!t,arrow:!0,children:c.jsx(y.Box,{children:c.jsx(y.Button,{disabled:!p,onClick:i,variant:"outlined",color:"warning",children:c.jsx(Ea,{})})})}),c.jsx(y.Divider,{orientation:"vertical",flexItem:!0}),c.jsx(y.Tooltip,{title:n("downloadJSONFile",{ns:"button"}),enterDelay:1500,disableHoverListener:!t,arrow:!0,children:c.jsx(y.Box,{children:c.jsx(y.Button,{variant:"outlined",href:r(t),download:`${e}.json`,disabled:!t,children:c.jsx(Ca,{})})})}),c.jsx(y.Tooltip,{title:h?n("update",{ns:"button"}):n("save",{ns:"button"}),enterDelay:1500,disableHoverListener:!t,arrow:!0,children:c.jsx(y.Box,{children:c.jsx(y.Button,{variant:"outlined",onClick:o,disabled:!t||!(f!=null&&f.baseUrl),children:c.jsx(Oa,{})})})}),c.jsxs(y.Dialog,{maxWidth:"xs",fullWidth:!0,open:u,onClose:a,children:[c.jsx(y.DialogTitle,{variant:"h3",children:n("resetTree",{ns:"button"})}),c.jsx(y.DialogContent,{children:c.jsx(y.DialogContentText,{children:n("resetTreeContent",{ns:"modal"})})}),c.jsxs(y.DialogActions,{children:[c.jsx(y.Button,{onClick:a,children:n("close",{ns:"button"})}),c.jsx(y.Button,{variant:"contained",color:"warning",onClick:l,children:n("reset",{ns:"button"})})]})]})]})},Fu={box:{backgroundColor:ce.background,border:`solid 1px ${ce.borderBlue}`}},ka=({children:e,description:t,open:n,onClose:r,title:o})=>c.jsx(y.Dialog,{open:n,onClose:r,"aria-labelledby":"modal-modal-title","aria-describedby":"modal-modal-description",scroll:"body",maxWidth:"sm",fullWidth:!0,children:c.jsxs(y.Box,{sx:Fu.box,p:4,children:[c.jsx("h3",{children:o}),c.jsx("p",{children:t}),e]})});var En={},Uu=Ae;Object.defineProperty(En,"__esModule",{value:!0});var za=En.default=void 0,Vu=Uu(ke()),Qu=c,Bu=(0,Vu.default)((0,Qu.jsx)("path",{d:"M18.3 5.71a.9959.9959 0 0 0-1.41 0L12 10.59 7.11 5.7a.9959.9959 0 0 0-1.41 0c-.39.39-.39 1.02 0 1.41L10.59 12 5.7 16.89c-.39.39-.39 1.02 0 1.41.39.39 1.02.39 1.41 0L12 13.41l4.89 4.89c.39.39 1.02.39 1.41 0 .39-.39.39-1.02 0-1.41L13.41 12l4.89-4.89c.38-.38.38-1.02 0-1.4z"}),"CloseRounded");za=En.default=Bu;const Dr={container:{display:"flex",flexDirection:"column",height:"100%",margin:1},main:{border:`solid 1px ${ce.borderBlue}`,height:" 100%",margin:1},toolbar:{backgroundColor:ce.background,boxShadow:"none",display:"flex",padding:"0 ! important"},toolbarBox:{backgroundColor:ce.tertiary,border:`solid 1px ${ce.primary}`,margin:1,paddingX:2,paddingY:1,width:"100%"}},qu=({children:e,appear:t,in:n,onEnter:r,onExited:o,onFocus:a,role:i,tabIndex:l,timeout:u},d)=>c.jsx(y.Slide,{direction:"up",ref:d,appear:t,in:n,onEnter:r,onExited:o,onFocus:a,role:i,tabIndex:l,timeout:u,children:e}),Wu=N.forwardRef(qu),Gu=({children:e,open:t,onClose:n,title:r})=>c.jsx(y.Dialog,{PaperProps:{sx:{backgroundColor:ce.background,backgroundImage:"none"}},open:t,"aria-labelledby":"modal-modal-title","aria-describedby":"modal-modal-description",fullScreen:!0,TransitionComponent:Wu,children:c.jsxs(y.Box,{sx:Dr.container,children:[c.jsx(y.AppBar,{position:"sticky",elevation:0,children:c.jsx(y.Toolbar,{sx:Dr.toolbar,children:c.jsxs(y.Stack,{direction:"row",alignItems:"center",justifyContent:"space-between",sx:Dr.toolbarBox,children:[c.jsx(y.Typography,{variant:"h5",children:c.jsx("strong",{children:r})}),c.jsx(y.IconButton,{edge:"end",color:"inherit",onClick:n,"aria-label":"close",children:c.jsx(za,{})})]})})}),c.jsx(y.Box,{sx:Dr.main,children:e})]})}),Ku={box:{border:`solid 1px ${ce.borderBlue}`,flexGrow:0}},Ju=({children:e})=>c.jsx(y.Box,{p:2,role:"group",sx:Ku.box,children:e}),Zu={box:{border:`solid 1px ${ce.borderBlue}`,flexGrow:0}},Xu=({children:e})=>c.jsx(y.Box,{sx:Zu.box,padding:2,component:"header",children:e}),Hu={box:{border:`solid 1px ${ce.borderBlue}`,flexGrow:1}},ed=({children:e})=>c.jsx(y.Box,{sx:Hu.box,component:"main",role:"tree",children:e}),_a={stack:{width:"100%"}},td=({children:e})=>{const t=N.Children.toArray(e);return c.jsxs(y.Grid,{container:!0,padding:1,flexWrap:"nowrap",height:"100%",role:"treegrid",children:[c.jsx(y.Grid,{item:!0,xs:9,padding:1,display:"flex",children:c.jsxs(y.Stack,{sx:_a.stack,spacing:2,children:[t[0],t[1]]})}),c.jsx(y.Grid,{item:!0,xs:3,padding:1,display:"flex",children:c.jsxs(y.Stack,{sx:_a.stack,spacing:2,children:[t[2],t[3]]})})]})},rd={box:{border:`solid 1px ${ce.borderBlue}`,flexGrow:1,overflow:"auto"}},nd=({children:e})=>c.jsx(y.Box,{sx:rd.box,component:"aside",children:e}),od=()=>{const{dispatchTree:e,setModalOpen:t,currentHierarchyPointNode:n,treePath:r}=Ce();return{handleSubmit:a=>{var u,d;a.preventDefault();const i=((u=n==null?void 0:n.data)==null?void 0:u.name)||"",l=((d=r==null?void 0:r.at(-1))==null?void 0:d.path)||"";e(_u(l,i)),t(null)}}},ad=({onClose:e})=>{const{t}=$e.useTranslation(),{handleSubmit:n}=od();return c.jsx("form",{onSubmit:n,children:c.jsxs(y.Stack,{spacing:2,direction:"row",justifyContent:"flex-end",children:[c.jsx(y.Button,{variant:"text",onClick:e,children:t("cancel")}),c.jsx(y.Button,{variant:"contained",color:"error",type:"submit",children:t("remove")})]})})};var On={},id=Ae;Object.defineProperty(On,"__esModule",{value:!0});var Ra=On.default=void 0,sd=id(ke()),ld=c,cd=(0,sd.default)((0,ld.jsx)("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm4 11h-3v3c0 .55-.45 1-1 1s-1-.45-1-1v-3H8c-.55 0-1-.45-1-1s.45-1 1-1h3V8c0-.55.45-1 1-1s1 .45 1 1v3h3c.55 0 1 .45 1 1s-.45 1-1 1z"}),"AddCircleRounded");Ra=On.default=cd;var Cn={},ud=Ae;Object.defineProperty(Cn,"__esModule",{value:!0});var La=Cn.default=void 0,dd=ud(ke()),fd=c,pd=(0,dd.default)((0,fd.jsx)("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm4 11H8c-.55 0-1-.45-1-1s.45-1 1-1h8c.55 0 1 .45 1 1s-.45 1-1 1z"}),"RemoveCircleRounded");La=Cn.default=pd;const Yt=[{isBooleanField:!1,isDecisionField:!1,isRepeatableDisabled:!1,isRequiredDisabled:!1,type:"text"},{isBooleanField:!1,isDecisionField:!1,isRepeatableDisabled:!1,isRequiredDisabled:!1,type:"number"},{isBooleanField:!1,isDecisionField:!1,isRepeatableDisabled:!1,isRequiredDisabled:!1,type:"email"},{isBooleanField:!1,isDecisionField:!1,isRepeatableDisabled:!1,isRequiredDisabled:!1,type:"file"},{isBooleanField:!1,isDecisionField:!1,isRepeatableDisabled:!1,isRequiredDisabled:!1,type:"password"},{isBooleanField:!1,isDecisionField:!1,isRepeatableDisabled:!1,isRequiredDisabled:!1,type:"tel"},{isBooleanField:!1,isDecisionField:!1,isRepeatableDisabled:!1,isRequiredDisabled:!1,type:"address"},{isBooleanField:!1,isDecisionField:!1,isRepeatableDisabled:!1,isRequiredDisabled:!1,type:"url"},{isBooleanField:!1,isDecisionField:!1,isRepeatableDisabled:!1,isRequiredDisabled:!1,type:"date"},{isBooleanField:!1,isDecisionField:!1,isRepeatableDisabled:!1,isRequiredDisabled:!1,type:"time"},{isBooleanField:!0,isDecisionField:!1,isRepeatableDisabled:!0,isRequiredDisabled:!0,type:"switch"},{isBooleanField:!0,isDecisionField:!1,isRepeatableDisabled:!0,isRequiredDisabled:!0,type:"checkbox"},{isBooleanField:!1,isDecisionField:!1,isRepeatableDisabled:!0,isRequiredDisabled:!0,type:"hidden"},{isBooleanField:!1,isDecisionField:!1,isRepeatableDisabled:!0,isRequiredDisabled:!0,type:"tree"},{isBooleanField:!1,isDecisionField:!0,isRepeatableDisabled:!0,isRequiredDisabled:!1,type:"radio"},{isBooleanField:!1,isDecisionField:!0,isRepeatableDisabled:!0,isRequiredDisabled:!1,type:"select"}],hd=()=>{const{backendConfig:e}=Ce();return{fields:N.useCallback(()=>Yt.filter(n=>!(n.type==="tree"&&!(e!=null&&e.baseUrl))),[e==null?void 0:e.baseUrl])()}},gd=({onChange:e,value:t})=>{const{t:n}=$e.useTranslation(["translation","form"]),{fields:r}=hd();return c.jsxs(y.FormControl,{sx:{flex:1},required:!0,children:[c.jsx(y.InputLabel,{children:n("type")}),c.jsx(y.Select,{value:t,label:n("type"),onChange:e,MenuProps:{PaperProps:{sx:{maxHeight:300}}},children:r.map(({type:o,isDecisionField:a})=>c.jsxs(y.MenuItem,{value:o,children:[n(`type.${o}`,{ns:"form"}),a&&c.jsx(y.Chip,{label:n("decisionField",{ns:"form"}),size:"small",color:"info",sx:{marginLeft:1}})]},o))})]})},md=e=>{if(!e)return[];const t=new Set,n=r=>{var o,a;if((o=r==null?void 0:r.attributes)!=null&&o.tag&&t.add(r.attributes.tag),(a=r==null?void 0:r.children)!=null&&a.length){const{children:i}=r;for(let l=0;l<i.length;l+=1)n(i[l])}};return n(e),[...t]},yd=y.createFilterOptions(),vd=({value:e,onChange:t})=>{const{t:n}=$e.useTranslation(["translation","form"]),{tree:r}=Ce(),o=md(r).reduce((a,i)=>[...a,{inputValue:i,label:i}],[]);return c.jsx(y.Autocomplete,{freeSolo:!0,fullWidth:!0,value:e,onChange:t,filterOptions:(a,i)=>{const l=yd(a,i),{inputValue:u}=i,d=a.some(f=>typeof f!="string"&&u===f.label);return u!==""&&!d&&l.push({inputValue:u,label:`${n("add")} "${u}"`}),l},getOptionLabel:a=>typeof a=="string"?a:a.inputValue?a.inputValue:a.label,renderOption:(a,i)=>c.jsx("li",{...a,children:typeof i!="string"&&i.label}),renderInput:a=>c.jsx(y.TextField,{...a,label:n("tag")}),options:o})};var wn={},bd=Ae;Object.defineProperty(wn,"__esModule",{value:!0});var $a=wn.default=void 0,Md=bd(ke()),xd=c,Td=(0,Md.default)((0,xd.jsx)("path",{d:"M18 13h-5v5c0 .55-.45 1-1 1s-1-.45-1-1v-5H6c-.55 0-1-.45-1-1s.45-1 1-1h5V6c0-.55.45-1 1-1s1 .45 1 1v5h5c.55 0 1 .45 1 1s-.45 1-1 1z"}),"AddRounded");$a=wn.default=Td;const jd=e=>{const{backendConfig:t}=Ce(),{endpoints:n}=t||{},{workflows:r=""}=n||{};return lt.useQuery(["workflows"],async({signal:o})=>{const{data:a}=await ct.get(r,{signal:o});return a},e)},Dd=({isControlled:e,fetchWorkflowsOnOpen:t})=>{const{t:n}=$e.useTranslation("snackMessage"),{open:r}=Nn(),{currentTree:o,setCurrentTree:a,dispatchTree:i}=Ce(),[l,u]=N.useState(""),d=!!l&&!e&&l!==o.id,{data:f,isError:p}=Zt(l,{enabled:d}),{data:h,isLoading:M,refetch:v}=jd({enabled:!t}),g=N.useCallback(async({target:x})=>{var I;const{value:O}=x;if(O==="add-new-tree"){u(""),a({name:""}),i(Aa());return}u(O),a({id:O,name:(I=h==null?void 0:h.find(A=>A.id===O))==null?void 0:I.label})},[i,a,h]),m=N.useCallback(async()=>{if(t)try{await v(),o.id&&!l&&u(o.id)}catch{r(n("error.fetchTree",{ns:"snackMessage"}),"error")}},[t,v,o.id,l,r,n]);return N.useEffect(()=>{if(f&&l!==o.id){const{id:x,label:O,workflow:I}=f;a({id:x,name:O}),i(Sa(I))}},[o.id,i,e,a,l,f]),N.useEffect(()=>{p&&r(n("error.fetchTree",{ns:"snackMessage"}),"error")},[p,r,n]),{currentTree:o,fetchWorkflowSuggestions:v,handleChangeTree:g,handleOnOpen:m,setTreeSelected:u,treeSelected:l,workflowsSuggestions:h,workflowsSuggestionsLoading:M}},Pa={formControl:{flex:1},select:{".MuiOutlinedInput-notchedOutline":{border:0,paddingLeft:5},".MuiSelect-select":{opacity:0,width:0},boxShadow:"none"}},Ya=({arrowOnly:e,required:t,size:n,showBtnAddNewTree:r,onChange:o,value:a,fetchWorkflowsOnOpen:i})=>{const{t:l}=$e.useTranslation("form"),u=N.useMemo(()=>!!o,[o]),{handleChangeTree:d,handleOnOpen:f,workflowsSuggestions:p,workflowsSuggestionsLoading:h,treeSelected:M}=Dd({fetchWorkflowsOnOpen:i,isControlled:u});return c.jsxs(y.FormControl,{size:n,required:t,sx:Pa.formControl,children:[!e&&c.jsx(y.InputLabel,{children:l("tree",{ns:"form"})}),c.jsxs(y.Select,{value:u?a:M,id:"tree-select",onChange:v=>u?o==null?void 0:o(v):d(v),sx:e?Pa.select:void 0,label:l("tree",{ns:"form"}),onOpen:f,children:[(a&&h||h)&&c.jsx(y.MenuItem,{value:a,children:c.jsx(y.Skeleton,{width:"100%"})}),p==null?void 0:p.map(({label:v,id:g})=>c.jsx(y.MenuItem,{value:g,children:v},g)),r&&c.jsx(y.MenuItem,{disabled:!0,children:c.jsx(y.Box,{sx:{height:1,width:"100%"},children:c.jsx(y.Divider,{})})}),r&&c.jsxs(y.MenuItem,{value:"add-new-tree",children:[c.jsx(y.Typography,{mr:1,children:l("newTree",{ns:"form"})}),c.jsx($a,{color:"primary"})]})]})]})},Nd=({helperText:e,hiddenValue:t,isHiddenField:n,isTreeField:r,treeSelected:o,handleChangeTreeSelect:a,handleChangeHelperText:i,handleChangeHiddenValue:l})=>{const{t:u}=$e.useTranslation(["translation","form"]);return r?c.jsx(Ya,{required:!0,value:o,onChange:a}):n?c.jsx(y.TextField,{required:!0,sx:{flex:1},label:u("hiddenValue",{ns:"form"}),onChange:l,value:t}):c.jsx(y.TextField,{sx:{flex:1},label:u("helperText",{ns:"form"}),onChange:i,value:e})},Fa=e=>new Set([...e]).size===e.length,Ed=(e,t,n)=>{const r=[...e,t];return Fa(n?r.filter(o=>o!==n):r)},Od=()=>{var Ar,Sr,kr,zr,Dt,Vt,nt,Nt,Et,Qt,_r,Bt,Rr,qt,Wt,Lr,$r;const e=N.useMemo(()=>[{id:"0",label:"",message:"",value:""}],[]),{tree:t,dispatchTree:n,currentHierarchyPointNode:r,modalOpen:o,treePath:a,setModalOpen:i}=Ce(),{open:l}=Nn(),{t:u}=$e.useTranslation(),[d,f]=N.useState(e),[p,h]=N.useState(""),[M,v]=N.useState(""),[g,m]=N.useState(""),[x,O]=N.useState(!1),[I,A]=N.useState(!1),[b,W]=N.useState("text"),[z,Te]=N.useState(null),[he,_]=N.useState(""),[se,me]=N.useState(""),[de,le]=N.useState(""),[Me,xe]=N.useState({off:"",on:""}),[Ee,_e]=N.useState(!1),[Ye,j]=N.useState(""),w=o==="edit",L=b==="tree",$=b==="hidden",R=Yt.some(C=>C.type===b&&(C==null?void 0:C.isBooleanField)),U=Yt.some(C=>C.type===b&&(C==null?void 0:C.isDecisionField)),P=Yt.some(C=>C.type===b&&(C==null?void 0:C.isRequiredDisabled)),F=Yt.some(C=>C.type===b&&(C==null?void 0:C.isRepeatableDisabled)),Y=((Sr=(Ar=r==null?void 0:r.data)==null?void 0:Ar.attributes)==null?void 0:Sr.isLeaf)??!0,Q=N.useCallback(C=>!U&&C>0,[U]),{refetch:V,isInitialLoading:Ne}=Zt(he,{enabled:!1,onError:()=>{l(u("error.fetchTree",{ns:"snackMessage"}),"error")}}),E=N.useCallback((C,K)=>{f(ie=>ie.map(ye=>{const{id:Le}=ye;return C.target.dataset.id===Le?{...ye,id:Le,[K]:C.target.value}:{...ye}}))},[]),Re=N.useCallback((C,K)=>{typeof K=="string"?Te(K):K&&K.inputValue?Te(K.inputValue):Te(null)},[]),S=N.useCallback(C=>{v(C.target.value)},[]),Qe=N.useCallback(C=>{m(C.target.value)},[]),Je=N.useCallback(C=>{E(C,"label")},[E]),it=N.useCallback(C=>{E(C,"value")},[E]),Nr=N.useCallback(C=>{E(C,"message")},[E]),Tt=N.useCallback(C=>{le(C.target.value)},[]),Yn=N.useCallback(C=>{var D;const{value:K}=C.target;if(h(C.target.value),!t||!K){j("");return}const ie=w&&(r==null?void 0:r.data.name),ye=(D=a==null?void 0:a.at(-1))==null?void 0:D.path,Le=xt(t,ye),s=Iu(Le);if(Ed(s,K,ie)){j("");return}j(u("mustBeUnique",{ns:"form"}))},[r==null?void 0:r.data.name,w,u,t,a]),Fn=N.useCallback(C=>{O(C.target.checked)},[]),Ft=N.useCallback(C=>{A(C.target.checked)},[]),Un=N.useCallback(C=>{_e(C.target.checked)},[]),Vn=N.useCallback(C=>{W(C.target.value),A(!1),O(!1),_e(!1)},[]),Er=N.useCallback(C=>{_(C.target.value)},[]),Or=N.useCallback(C=>K=>{xe(ie=>({...ie,[C]:K.target.value}))},[]),st=N.useCallback(C=>{me(C.target.value)},[]),Qn=N.useCallback(()=>{f(C=>{const K=Number(C[C.length-1].id),ie=String(K+1);return[...C,{...e[0],id:ie}]})},[e]),Cr=N.useCallback(C=>{f(K=>K.filter(({id:ie})=>C.currentTarget.value!==ie))},[]),Ut=N.useCallback((C,K)=>{var ye,Le,s;const ie=(s=(Le=(ye=C==null?void 0:C.children)==null?void 0:ye[K])==null?void 0:Le.data)==null?void 0:s.children;return ie?ie.map(({name:T,attributes:D,children:k})=>({attributes:D,children:k,name:T})):[]},[]),jt=N.useCallback(C=>{var K;return I?(K=d==null?void 0:d.filter((ie,ye)=>!Q(ye)))==null?void 0:K.map(({message:ie,value:ye,label:Le},s)=>{const T=`${p}:${ye}`,D=Ut(r,s);return{attributes:{depth:C+1,label:Le,value:ye,...ie&&{message:ie},...D.length===0&&{isLeaf:!0}},children:D,name:T}}):[]},[r,Q,Ut,I,p,d]),wr=N.useCallback(C=>C.map(({message:K,...ie})=>({...ie,...K&&{message:K}})),[]),Ir=N.useCallback((C,K,ie)=>{var ye;return C&&(!K||ie)?V():C&&K&&!ie?{data:{workflow:(ye=r==null?void 0:r.data.attributes)==null?void 0:ye.tree},isError:null}:{data:null,isError:null}},[(kr=r==null?void 0:r.data.attributes)==null?void 0:kr.tree,V]),Bn=N.useCallback(async C=>{var fe,pe,Ie,Be;C.preventDefault();const{on:K,off:ie}=Me,ye=((fe=r==null?void 0:r.data)==null?void 0:fe.name)||"",Le=(r==null?void 0:r.depth)||0,s=o==="edit",T=Le+(s||r===null?0:1),D=jt(T),k=(pe=a==null?void 0:a.at(-1))==null?void 0:pe.path,J=a.length?`${k}/${p}`:`/${p}`,X=((Be=(Ie=r==null?void 0:r.data.attributes)==null?void 0:Ie.tree)==null?void 0:Be.treeId)!==he,{data:B,isError:q}=await Ir(L,s,X);if(q)return;const je={attributes:{depth:T,label:g,type:b,...se&&{helperText:se},...(ie||K)&&{messages:{...ie&&{off:ie},...K&&{on:K}}},...L&&{tree:{...B==null?void 0:B.workflow,treeId:he},treePath:J},...I&&{isDecision:I},...U&&!I&&{values:wr(d)},...x&&{required:x},...de&&{step:de},...Ee&&{repeatable:Ee},...$&&{hiddenValue:M},...z&&{tag:z}},children:D,name:p};n(s?zu(k||"",ye,je):ku(k||null,ye,je)),i(null)},[r,n,jt,wr,Ir,se,M,I,U,$,L,g,Me,o,p,Ee,x,i,de,z,a,he,b,d]);return N.useEffect(()=>{var C,K,ie,ye,Le,s,T,D,k,J,X,B,q,je,fe,pe,Ie,Be,Gt,qe;if(o==="edit"){const Pr=((K=(C=r==null?void 0:r.data)==null?void 0:C.attributes)==null?void 0:K.values)||((Le=(ye=(ie=r==null?void 0:r.data)==null?void 0:ie.children)==null?void 0:ye.filter(({attributes:Kt})=>!(Kt!=null&&Kt.type)))==null?void 0:Le.map(({attributes:Kt},Sf)=>{const{label:kf,value:zf,message:ai}=Kt||{};return{id:String(Sf),label:String(kf),value:String(zf),...ai&&{message:String(ai)}}}));h((r==null?void 0:r.data.name)||""),Te(((s=r==null?void 0:r.data.attributes)==null?void 0:s.tag)||null),W(((T=r==null?void 0:r.data.attributes)==null?void 0:T.type)||"text"),me(((D=r==null?void 0:r.data.attributes)==null?void 0:D.helperText)||""),O(((k=r==null?void 0:r.data.attributes)==null?void 0:k.required)||!1),le(((J=r==null?void 0:r.data.attributes)==null?void 0:J.step)||""),m(((X=r==null?void 0:r.data.attributes)==null?void 0:X.label)||""),A(((B=r==null?void 0:r.data.attributes)==null?void 0:B.isDecision)||!1),f(Pr!=null&&Pr.length?Pr:e),xe({off:((je=(q=r==null?void 0:r.data.attributes)==null?void 0:q.messages)==null?void 0:je.off)||"",on:((pe=(fe=r==null?void 0:r.data.attributes)==null?void 0:fe.messages)==null?void 0:pe.on)||""}),_(((Be=(Ie=r==null?void 0:r.data.attributes)==null?void 0:Ie.tree)==null?void 0:Be.treeId)||""),_e(((Gt=r==null?void 0:r.data.attributes)==null?void 0:Gt.repeatable)||!1),v(((qe=r==null?void 0:r.data.attributes)==null?void 0:qe.hiddenValue)||"")}},[(Dt=(zr=r==null?void 0:r.data.attributes)==null?void 0:zr.tree)==null?void 0:Dt.treeId,(Vt=r==null?void 0:r.data.attributes)==null?void 0:Vt.messages,(nt=r==null?void 0:r.data.attributes)==null?void 0:nt.helperText,(Nt=r==null?void 0:r.data.attributes)==null?void 0:Nt.isDecision,(Et=r==null?void 0:r.data.attributes)==null?void 0:Et.label,(Qt=r==null?void 0:r.data.attributes)==null?void 0:Qt.required,(_r=r==null?void 0:r.data.attributes)==null?void 0:_r.step,(Bt=r==null?void 0:r.data.attributes)==null?void 0:Bt.type,(Rr=r==null?void 0:r.data.attributes)==null?void 0:Rr.values,(qt=r==null?void 0:r.data)==null?void 0:qt.children,r==null?void 0:r.data.name,(Wt=r==null?void 0:r.data.attributes)==null?void 0:Wt.tag,(Lr=r==null?void 0:r.data.attributes)==null?void 0:Lr.repeatable,($r=r==null?void 0:r.data.attributes)==null?void 0:$r.hiddenValue,e,o]),{getDisabledValueField:Q,handleAddValue:Qn,handleChangeHelperText:st,handleChangeHiddenValue:S,handleChangeIsDecisionField:Ft,handleChangeLabel:Qe,handleChangeMessage:Or,handleChangeName:Yn,handleChangeOptionLabel:Je,handleChangeOptionMessage:Nr,handleChangeOptionValue:it,handleChangeRepeatable:Un,handleChangeRequired:Fn,handleChangeStep:Tt,handleChangeTag:Re,handleChangeTreeSelect:Er,handleChangeType:Vn,handleDeleteValue:Cr,handleSubmit:Bn,helperText:se,hiddenValue:M,isBooleanField:R,isDecision:I,isDecisionField:U,isEditModal:w,isHiddenField:$,isLeaf:Y,isRepeatableDisabled:F,isRequiredDisabled:P,isTreeField:L,isWorkflowLoading:Ne,label:g,messages:Me,name:p,repeatable:Ee,required:x,step:de,tag:z,treeSelected:he,type:b,uniqueNameErrorMessage:Ye,values:d}},Ua={marginRight:"-20px !important",minWidth:"auto !important"},Va={iconButton:Ua,iconButtonDelete:{...Ua,"&:before":{borderRadius:"50%",content:'""',height:20,position:"absolute",width:20,zIndex:-1},backgroundColor:ce.background,position:"absolute",right:0,top:"50%",transform:"translateY(-50%)"}},Cd=({onClose:e})=>{const{t}=$e.useTranslation(["translation","form"]),{values:n,required:r,name:o,tag:a,uniqueNameErrorMessage:i,type:l,helperText:u,label:d,hiddenValue:f,isBooleanField:p,isDecision:h,isEditModal:M,isDecisionField:v,isHiddenField:g,isRequiredDisabled:m,isRepeatableDisabled:x,isTreeField:O,treeSelected:I,isWorkflowLoading:A,repeatable:b,isLeaf:W,messages:{on:z,off:Te},handleChangeTreeSelect:he,handleChangeHelperText:_,handleChangeOptionMessage:se,handleChangeRequired:me,handleChangeName:de,handleChangeType:le,handleChangeIsDecisionField:Me,handleChangeOptionLabel:xe,handleDeleteValue:Ee,handleChangeOptionValue:_e,handleChangeMessage:Ye,handleSubmit:j,handleAddValue:w,handleChangeLabel:L,handleChangeRepeatable:$,handleChangeHiddenValue:R,handleChangeTag:U}=Od();return c.jsxs("form",{onSubmit:j,children:[c.jsxs(y.Stack,{spacing:1,paddingY:1,direction:{sm:"row",xs:"column"},children:[c.jsx(y.TextField,{sx:{flex:1},label:t("label",{ns:"form"}),onChange:L,value:d,required:!0}),c.jsx(y.TextField,{label:t("name"),sx:{flex:1},onChange:de,value:o,error:!!i,helperText:i,required:!0})]}),c.jsxs(y.Stack,{spacing:1,paddingY:1,direction:{sm:"row",xs:"column"},children:[c.jsx(gd,{value:l,onChange:le}),c.jsx(Nd,{helperText:u,hiddenValue:f,isHiddenField:g,isTreeField:O,treeSelected:I,handleChangeTreeSelect:he,handleChangeHelperText:_,handleChangeHiddenValue:R})]}),c.jsx(y.Stack,{spacing:1,paddingY:1,direction:{sm:"row",xs:"column"},children:c.jsx(vd,{value:a,onChange:U})}),p&&c.jsxs(y.Stack,{spacing:1,paddingY:1,direction:{sm:"row",xs:"column"},children:[c.jsx(y.TextField,{sx:{flex:1},label:t("onMessage",{ns:"form"}),onChange:Ye("on"),value:z}),c.jsx(y.TextField,{sx:{flex:1},label:t("offMessage",{ns:"form"}),onChange:Ye("off"),value:Te})]}),c.jsxs(y.Stack,{paddingY:1,children:[c.jsx(y.FormGroup,{children:c.jsx(y.FormControlLabel,{disabled:x,control:c.jsx(y.Checkbox,{checked:b,onChange:$}),label:t("repeatable",{ns:"form"})})}),c.jsx(y.FormGroup,{children:c.jsx(y.FormControlLabel,{disabled:m,control:c.jsx(y.Checkbox,{checked:r,onChange:me}),label:t("required")})}),(W||M)&&c.jsx(y.FormGroup,{children:c.jsx(y.FormControlLabel,{disabled:!v,control:c.jsx(y.Checkbox,{checked:h,onChange:Me}),label:t("decisionField",{ns:"form"})})})]}),v&&c.jsxs(c.Fragment,{children:[c.jsx("h4",{children:t("values")}),n==null?void 0:n.map(({value:P,label:F,id:Y,message:Q})=>c.jsxs(y.Stack,{direction:{sm:"row",xs:"column"},spacing:1,paddingY:1,position:"relative",children:[c.jsx(y.TextField,{label:t("label",{ns:"form"}),sx:{flex:1},onChange:xe,value:F,inputProps:{"data-id":Y},required:!0}),c.jsx(y.TextField,{label:t("value",{ns:"form"}),sx:{flex:1},onChange:_e,value:P,inputProps:{"data-id":Y},required:!0}),c.jsx(y.TextField,{label:"Message",sx:{flex:1},onChange:se,value:Q,inputProps:{"data-id":Y}}),n.length>1&&c.jsx(y.IconButton,{color:"warning",sx:Va.iconButtonDelete,value:Y,onClick:Ee,children:c.jsx(La,{})})]},Y))]}),v&&c.jsx(y.Box,{justifyContent:"flex-end",display:"flex",children:c.jsx(y.IconButton,{color:"success",sx:Va.iconButton,onClick:w,children:c.jsx(Ra,{})})}),c.jsxs(y.Stack,{spacing:2,direction:"row",justifyContent:"flex-end",paddingTop:3,children:[c.jsx(y.Button,{variant:"text",onClick:e,children:t("cancel")}),c.jsx(y.Button,{variant:"contained",type:"submit",disabled:!!i||A,isLoading:A,loadingIndicator:c.jsx(y.CircularProgress,{size:14}),children:t("validate")})]})]})};var In={},wd=Ae;Object.defineProperty(In,"__esModule",{value:!0});var Qa=In.default=void 0,Id=wd(ke()),Ad=c,Sd=(0,Id.default)((0,Ad.jsx)("path",{d:"M17 11h3c1.11 0 2-.9 2-2V5c0-1.11-.9-2-2-2h-3c-1.11 0-2 .9-2 2v1H9.01V5c0-1.11-.9-2-2-2H4c-1.1 0-2 .9-2 2v4c0 1.11.9 2 2 2h3c1.11 0 2-.9 2-2V8h2v7.01c0 1.65 1.34 2.99 2.99 2.99H15v1c0 1.11.9 2 2 2h3c1.11 0 2-.9 2-2v-4c0-1.11-.9-2-2-2h-3c-1.11 0-2 .9-2 2v1h-1.01c-.54 0-.99-.45-.99-.99V8h2v1c0 1.1.9 2 2 2z"}),"AccountTreeRounded");Qa=In.default=Sd;var An={},kd=Ae;Object.defineProperty(An,"__esModule",{value:!0});var Ba=An.default=void 0,zd=kd(ke()),_d=c,Rd=(0,zd.default)((0,_d.jsx)("path",{d:"M19 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-3 10h-3v3c0 .55-.45 1-1 1s-1-.45-1-1v-3H8c-.55 0-1-.45-1-1s.45-1 1-1h3V8c0-.55.45-1 1-1s1 .45 1 1v3h3c.55 0 1 .45 1 1s-.45 1-1 1z"}),"AddBoxRounded");Ba=An.default=Rd;var Sn={},Ld=Ae;Object.defineProperty(Sn,"__esModule",{value:!0});var qa=Sn.default=void 0,$d=Ld(ke()),Pd=c,Yd=(0,$d.default)((0,Pd.jsx)("path",{d:"M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V9c0-1.1-.9-2-2-2H8c-1.1 0-2 .9-2 2v10zM9 9h6c.55 0 1 .45 1 1v8c0 .55-.45 1-1 1H9c-.55 0-1-.45-1-1v-8c0-.55.45-1 1-1zm6.5-5-.71-.71c-.18-.18-.44-.29-.7-.29H9.91c-.26 0-.52.11-.7.29L8.5 4H6c-.55 0-1 .45-1 1s.45 1 1 1h12c.55 0 1-.45 1-1s-.45-1-1-1h-2.5z"}),"DeleteOutlineRounded");qa=Sn.default=Yd;var kn={},Fd=Ae;Object.defineProperty(kn,"__esModule",{value:!0});var Wa=kn.default=void 0,Ud=Fd(ke()),Vd=c,Qd=(0,Ud.default)((0,Vd.jsx)("path",{d:"M3 17.46v3.04c0 .28.22.5.5.5h3.04c.13 0 .26-.05.35-.15L17.81 9.94l-3.75-3.75L3.15 17.1c-.1.1-.15.22-.15.36zM20.71 7.04c.39-.39.39-1.02 0-1.41l-2.34-2.34a.9959.9959 0 0 0-1.41 0l-1.83 1.83 3.75 3.75 1.83-1.83z"}),"EditRounded");Wa=kn.default=Qd;var zn={},Bd=Ae;Object.defineProperty(zn,"__esModule",{value:!0});var Ga=zn.default=void 0,qd=Bd(ke()),Wd=c,Gd=(0,qd.default)((0,Wd.jsx)("path",{d:"M12 3c-4.8 0-9 3.86-9 9 0 2.12.74 4.07 1.97 5.61l-1.68 1.68c-.39.39-.39 1.02 0 1.41.39.39 1.02.39 1.41 0l1.68-1.68C7.93 20.26 9.88 21 12 21c2.3 0 4.61-.88 6.36-2.64C20.12 16.61 21 14.3 21 12V5c0-1.1-.9-2-2-2h-7zm3.83 9.26-5.16 4.63c-.16.15-.41.14-.56-.01-.14-.14-.16-.36-.04-.52l2.44-3.33-4.05-.4c-.44-.04-.63-.59-.3-.89l5.16-4.63c.16-.15.41-.14.56.01.14.14.16.36.04.52l-2.44 3.33 4.05.4c.45.04.63.59.3.89z"}),"EnergySavingsLeafRounded");Ga=zn.default=Gd;var _n={},Kd=Ae;Object.defineProperty(_n,"__esModule",{value:!0});var Ka=_n.default=void 0,Jd=Kd(ke()),Ja=c,Zd=(0,Jd.default)([(0,Ja.jsx)("path",{d:"M14.14 12h-.06c.81 0 1.28-.91.82-1.57L9.82 3.17c-.4-.57-1.24-.57-1.64 0L3.1 10.43c-.46.66.01 1.57.82 1.57h-.06L.99 16.46c-.43.66.05 1.54.84 1.54H7v2c0 1.1.9 2 2 2s2-.9 2-2v-2h5.17c.79 0 1.27-.88.84-1.54L14.14 12z"},"0"),(0,Ja.jsx)("path",{d:"M23.01 16.46 20.14 12h-.06c.81 0 1.28-.91.82-1.57l-5.08-7.26c-.4-.57-1.24-.57-1.64 0l-1.57 2.24 3.11 4.44c.43.61.48 1.41.14 2.07-.08.16-.18.3-.3.43l2.29 3.57c.4.62.42 1.4.07 2.04-.01.02-.02.03-.03.04h4.28c.79 0 1.27-.88.84-1.54zM13 20c0 1.1.9 2 2 2s2-.9 2-2v-1h-4v1z"},"1")],"ForestRounded");Ka=_n.default=Zd;var Rn={},Xd=Ae;Object.defineProperty(Rn,"__esModule",{value:!0});var Za=Rn.default=void 0,Hd=Xd(ke()),ef=c,tf=(0,Hd.default)((0,ef.jsx)("path",{d:"M12 4V2.21c0-.45-.54-.67-.85-.35l-2.8 2.79c-.2.2-.2.51 0 .71l2.79 2.79c.32.31.86.09.86-.36V6c3.31 0 6 2.69 6 6 0 .79-.15 1.56-.44 2.25-.15.36-.04.77.23 1.04.51.51 1.37.33 1.64-.34.37-.91.57-1.91.57-2.95 0-4.42-3.58-8-8-8zm0 14c-3.31 0-6-2.69-6-6 0-.79.15-1.56.44-2.25.15-.36.04-.77-.23-1.04-.51-.51-1.37-.33-1.64.34C4.2 9.96 4 10.96 4 12c0 4.42 3.58 8 8 8v1.79c0 .45.54.67.85.35l2.79-2.79c.2-.2.2-.51 0-.71l-2.79-2.79c-.31-.31-.85-.09-.85.36V18z"}),"LoopRounded");Za=Rn.default=tf;var Ln={},rf=Ae;Object.defineProperty(Ln,"__esModule",{value:!0});var Xa=Ln.default=void 0,nf=rf(ke()),of=c,af=(0,nf.default)((0,of.jsx)("path",{d:"M16.96 12h.08c.81 0 1.28-.91.82-1.57l-5.08-7.25c-.4-.57-1.24-.57-1.64 0L6.1 10.43c-.46.66.02 1.57.83 1.57h.04l-2.9 4.46c-.44.66.04 1.54.84 1.54h5.08v2.02c0 1.09.89 1.98 1.98 1.98 1.09 0 1.98-.89 1.98-1.98V18h5.15c.8 0 1.28-.89.83-1.55L16.96 12z"}),"ParkRounded");Xa=Ln.default=af;var $n={},sf=Ae;Object.defineProperty($n,"__esModule",{value:!0});var Ha=$n.default=void 0,lf=sf(ke()),cf=c,uf=(0,lf.default)((0,cf.jsx)("path",{d:"M12 6.5c2.76 0 5 2.24 5 5 0 .51-.1 1-.24 1.46l3.06 3.06c1.39-1.23 2.49-2.77 3.18-4.53C21.27 7.11 17 4 12 4c-1.27 0-2.49.2-3.64.57l2.17 2.17c.47-.14.96-.24 1.47-.24zM2.71 3.16c-.39.39-.39 1.02 0 1.41l1.97 1.97C3.06 7.83 1.77 9.53 1 11.5 2.73 15.89 7 19 12 19c1.52 0 2.97-.3 4.31-.82l2.72 2.72c.39.39 1.02.39 1.41 0 .39-.39.39-1.02 0-1.41L4.13 3.16c-.39-.39-1.03-.39-1.42 0zM12 16.5c-2.76 0-5-2.24-5-5 0-.77.18-1.5.49-2.14l1.57 1.57c-.03.18-.06.37-.06.57 0 1.66 1.34 3 3 3 .2 0 .38-.03.57-.07L14.14 16c-.65.32-1.37.5-2.14.5zm2.97-5.33c-.15-1.4-1.25-2.49-2.64-2.64l2.64 2.64z"}),"VisibilityOffRounded");Ha=$n.default=uf;var Pn={},df=Ae;Object.defineProperty(Pn,"__esModule",{value:!0});var ei=Pn.default=void 0,ff=df(ke()),pf=c,hf=(0,ff.default)((0,pf.jsx)("path",{d:"M12 4C7 4 2.73 7.11 1 11.5 2.73 15.89 7 19 12 19s9.27-3.11 11-7.5C21.27 7.11 17 4 12 4zm0 12.5c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5zm0-8c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3z"}),"VisibilityRounded");ei=Pn.default=hf;const we={actionButton:{minWidth:"auto !important"},container:{background:ce.background,borderRadius:"1rem"},containerField:{background:ce.background,border:`solid 1px ${ce.primary}`,borderRadius:"1rem"},containerHidden:{background:ce.background,border:`solid 1px ${ce.borderGrey}`,borderRadius:"1rem"},containerTree:{background:ce.tertiary,border:`solid 1px ${ce.primary}`,borderRadius:"1rem"},containerValue:{background:ce.background,border:`solid 1px ${ce.secondary}`,borderRadius:"1rem"},icon:{color:ce.grey500},nodeSvg:{stroke:"transparent !important"},stepChip:{fontSize:".7rem !important",fontWeight:"bold",height:"20px !important"},title:{display:"-webkit-box",margin:0,overflow:"hidden",textAlign:"right",textOverflow:"ellipsis",webkitBoxOrient:"vertical",webkitLineClamp:2}},gf=e=>{const t=!!e,n=e==="tree";return e==="hidden"?we.containerHidden:n?we.containerTree:t?we.containerField:we.containerValue},mf=({nodeDatum:e,onAddChildren:t,onEditChildren:n,onDeleteChildren:r,onOpenTreeModal:o,hierarchyPointNode:a,size:i=220})=>{var z;const{t:l}=$e.useTranslation(["translation","form"]),{attributes:u}=e||{},{isRoot:d,isLeaf:f,required:p,isDecision:h,step:M,type:v,label:g,repeatable:m,tag:x}=u||{},O=!!v,I=v==="tree",A=v==="hidden",b=!O,W=!d&&!f;return c.jsxs("g",{children:[c.jsx(y.GlobalStyles,{styles:{".rd3t-node svg":we.nodeSvg}}),c.jsx(y.Box,{component:"foreignObject",height:i,width:i,x:`-${i/2}`,y:`-${i/2}`,sx:gf(v),children:c.jsxs(y.Box,{flex:1,display:"flex",p:2,height:"100%",flexDirection:"column",justifyContent:"space-between",children:[c.jsxs(y.Stack,{alignItems:"flex-end",spacing:.5,children:[O&&c.jsxs(y.Stack,{direction:"row",spacing:1,alignItems:"center",children:[M&&c.jsx(y.Tooltip,{title:`${l("step",{ns:"form"})} ${(z=e==null?void 0:e.attributes)==null?void 0:z.step}`,placement:"left",arrow:!0,children:c.jsx(y.Chip,{color:"primary",size:"small",label:M,sx:we.stepChip})}),c.jsx(y.Typography,{variant:"subtitle2",sx:we.title,children:c.jsx("strong",{children:g})})]}),O&&c.jsx(y.Chip,{color:"info",size:"small",label:l(`type.${v}`,{ns:"form"})}),x&&c.jsx(y.Chip,{variant:"outlined",color:"warning",size:"small",label:x}),p&&c.jsx(y.Stack,{direction:"row",spacing:.5,children:p&&c.jsx(y.Typography,{variant:"body2",sx:{color:({palette:Te})=>Te.error.main},children:l("required")})}),c.jsx(y.Stack,{spacing:.5,alignItems:"flex-end",children:b&&c.jsx(y.Typography,{variant:"subtitle2",sx:we.title,children:c.jsx("strong",{children:g})})}),c.jsxs(y.Stack,{paddingTop:.5,spacing:.5,direction:"row",children:[m&&c.jsx(y.Tooltip,{title:l("isARepeatable"),placement:"bottom",arrow:!0,children:c.jsx(Za,{style:we.icon})}),f&&c.jsx(y.Tooltip,{title:l("isALeaf"),placement:"bottom",arrow:!0,children:c.jsx(Ga,{style:we.icon})}),A&&c.jsx(y.Tooltip,{title:l("isAHidden"),placement:"bottom",arrow:!0,children:c.jsx(Ha,{style:we.icon})}),d&&c.jsx(y.Tooltip,{title:l("isTheRoot"),placement:"bottom",arrow:!0,children:c.jsx(Xa,{style:we.icon})}),W&&c.jsx(y.Tooltip,{title:l("isABranch"),placement:"bottom",arrow:!0,children:c.jsx(Qa,{style:we.icon})}),I&&c.jsx(y.Tooltip,{title:l("isATree"),placement:"bottom",arrow:!0,children:c.jsx(Ka,{style:we.icon})})]})]}),c.jsxs(y.Stack,{direction:"row",justifyContent:"flex-end",spacing:0,alignSelf:"flex-end",children:[!d&&c.jsx(y.Tooltip,{title:l("remove"),arrow:!0,children:c.jsx(y.Button,{variant:"text",sx:we.actionButton,size:"small",color:"error",onClick:()=>r==null?void 0:r(a),children:c.jsx(qa,{})})}),!b&&c.jsx(y.Tooltip,{title:l("edit"),arrow:!0,children:c.jsx(y.Button,{variant:"text",color:"secondary",sx:we.actionButton,size:"small",onClick:()=>n==null?void 0:n(a),children:c.jsx(Wa,{})})}),!h&&c.jsx(y.Tooltip,{title:l("add"),arrow:!0,children:c.jsx(y.Button,{variant:"text",color:"success",sx:we.actionButton,size:"small",onClick:()=>t==null?void 0:t(a),children:c.jsx(Ba,{})})}),I&&c.jsx(y.Tooltip,{title:l("show"),arrow:!0,children:c.jsx(y.Button,{variant:"text",color:"info",sx:we.actionButton,size:"small",onClick:()=>o==null?void 0:o(a),children:c.jsx(ei,{})})})]})]})})]})},yf=N.memo(mf),ti=()=>{const{setModalOpen:e,setCurrentHierarchyPointNode:t,setTreeModalOpen:n,setTreePath:r}=Ce();return{handleAddChildren:d=>{t(d),e("add")},handleCloseTreeModal:()=>{r([]),n(!1)},handleDeleteChildren:d=>{t(d),e("delete")},handleEditChildren:d=>{t(d),e("edit")},handleOpenTreeModal:d=>{var p,h;const f={label:d==null?void 0:d.data.attributes.label,path:((h=(p=d==null?void 0:d.data)==null?void 0:p.attributes)==null?void 0:h.treePath)||""};r(M=>[...M,f]),n(!0)}}},vf=({nodeDatum:e,hierarchyPointNode:t,toggleNode:n,onNodeClick:r,onNodeMouseOver:o,onNodeMouseOut:a,addChildren:i})=>{const{handleDeleteChildren:l,handleEditChildren:u,handleAddChildren:d,handleOpenTreeModal:f}=ti();return c.jsx(yf,{addChildren:i,nodeDatum:e,hierarchyPointNode:t,toggleNode:n,onNodeClick:r,onNodeMouseOver:o,onNodeMouseOut:a,onAddChildren:d,onOpenTreeModal:f,onDeleteChildren:l,onEditChildren:u})},ri=({nodeDatum:e,hierarchyPointNode:t,toggleNode:n,onNodeClick:r,onNodeMouseOver:o,onNodeMouseOut:a,addChildren:i})=>c.jsx(vf,{addChildren:i,nodeDatum:e,hierarchyPointNode:t,toggleNode:n,onNodeClick:r,onNodeMouseOver:o,onNodeMouseOut:a}),bf=()=>{const{t:e}=$e.useTranslation(["modal","snackMessage"]),{currentHierarchyPointNode:t,modalOpen:n,setModalOpen:r}=Ce(),o=n==="edit";return{closeModal:()=>r(null),getTitleModalDelete:()=>{var h,M;const p=(M=(h=t==null?void 0:t.data)==null?void 0:h.attributes)==null?void 0:M.label;return e("deleteTitle",{name:p,ns:"modal"})},getTitleModalMutation:()=>{var M;const p=(M=t==null?void 0:t.data)==null?void 0:M.attributes.label;return p?e(o?"editTitle":"addTitle",{name:p,ns:"modal"}):e("addFirstTitle",{name:p,ns:"modal"})},isDeleteModal:n==="delete",isModalMutationOpen:o||n==="add"}},Mf=()=>{const{currentTree:e,setCurrentTree:t,tree:n}=Ce(),{name:r,errorName:o,id:a}=e;return{disabled:!!e.id&&!n,errorName:o,handleChangeName:u=>{const{value:d}=u.target;if(!d){t(f=>({...f,errorName:"Champs requis",name:u.target.value}));return}t(f=>({...f,errorName:"",name:u.target.value}))},id:a,name:r}},xf=()=>{const{t:e}=$e.useTranslation("form"),{name:t,handleChangeName:n,errorName:r,disabled:o}=Mf();return c.jsx(y.TextField,{required:!0,label:e("treeName",{ns:"form"}),size:"small",onChange:n,value:t,error:!!r,disabled:o})},Tf=()=>{var M,v;const{tree:e,treeModalOpen:t,treePath:n,backendConfig:r}=Ce(),{handleCloseTreeModal:o}=ti(),{getTitleModalMutation:a,closeModal:i,getTitleModalDelete:l,isModalMutationOpen:u,isDeleteModal:d}=bf(),f=(M=n==null?void 0:n.at(-1))==null?void 0:M.path,p=(v=n==null?void 0:n.at(-1))==null?void 0:v.label,h=e&&xt(e,f);return c.jsxs(c.Fragment,{children:[c.jsxs(td,{children:[c.jsx(Xu,{children:c.jsxs(y.Stack,{justifyContent:"space-between",direction:"row",alignItems:"center",children:[c.jsx(Oi,{}),!!(r!=null&&r.baseUrl)&&c.jsxs(y.Stack,{direction:"row",alignItems:"center",spacing:2,children:[c.jsx(xf,{}),c.jsx(Ya,{size:"small",arrowOnly:!0,showBtnAddNewTree:!0,fetchWorkflowsOnOpen:!0})]})]})}),c.jsx(ed,{children:c.jsx(eo,{data:e,renderCustomNodeElement:ri})}),c.jsx(nd,{children:c.jsx(ki,{value:e})}),c.jsx(Ju,{children:c.jsx(Yu,{value:e})})]}),c.jsx(ka,{open:u,onClose:i,title:a(),children:c.jsx(Cd,{onClose:i})}),c.jsx(ka,{open:d,onClose:i,title:l(),children:c.jsx(ad,{onClose:i})}),c.jsx(Gu,{open:t,onClose:o,title:p,children:h&&c.jsx(eo,{data:h,renderCustomNodeElement:ri})})]})},jf="0.12.1",Df=({children:e,initialTree:t,initialTreeId:n,backendConfig:r})=>{const[o,a]=N.useState(Fe.currentHierarchyPointNode),[i,l]=N.useState(Fe.modalOpen),[u,d]=N.useState(Fe.treeModalOpen),[f,p]=N.useState(Fe.treePath),[h,M]=N.useReducer(Ru,t||Fe.tree),[v,g]=N.useState(n?{...Fe.currentTree,id:n}:Fe.currentTree),m=N.useMemo(()=>{var x,O;return{backendConfig:{baseUrl:((x=Fe==null?void 0:Fe.backendConfig)==null?void 0:x.baseUrl)||"",...Fe.backendConfig,...r,endpoints:{...(O=Fe.backendConfig)==null?void 0:O.endpoints,...r==null?void 0:r.endpoints}},currentHierarchyPointNode:o,currentTree:v,dispatchTree:M,modalOpen:i,setCurrentHierarchyPointNode:a,setCurrentTree:g,setModalOpen:l,setTreeModalOpen:d,setTreePath:p,tree:h,treeModalOpen:u,treePath:f,version:jf}},[r,o,v,i,h,u,f]);return Zt(v.id,{enabled:!!n,onSuccess:async x=>{x&&(g({id:x==null?void 0:x.id,name:x==null?void 0:x.label}),M(Sa((x==null?void 0:x.workflow)||null)))}}),c.jsx(Xn.Provider,{value:m,children:e})},Nf={close:"Close",createTree:"Create Tree",downloadJSONFile:"Download JSON File",reset:"Reset",resetTree:"Reset tree",save:"Save",update:"Update"},Ef={error:{fetchTree:"An error has occurred. Please try again",saveTree:"An error has occurred. Please try again",updateTree:"An error has occurred. Please try again"},success:{saveTree:"Tree registered",updateTree:"Tree updated"}},Of={add:"Add",cancel:"Cancel",disabled:"Disabled",edit:"Edit",isABranch:"Is a branch",isAHidden:"Is a hidden field",isALeaf:"Is a leaf",isARepeatable:"Is a repeatable",isATree:"Is a tree",isTheRoot:"Is the root",label:"Label",name:"Name",remove:"Remove",required:"Required",save:"Save",show:"Show",tag:"Tag",type:"Type",validate:"Validate",value:"Value",values:"Values"},Cf={close:"Fermer",createTree:"Créer un arbre",downloadJSONFile:"Télécharger le fichier JSON",reset:"Réinitialiser",resetTree:"Réinitialiser l'arbre",save:"Enregistrer",update:"Modifier"},ni={decisionField:"Champs de décision",helperText:"Texte d'information",hiddenValue:"Valeur caché",label:"Label",mustBeUnique:"Doit être unique",newTree:"Nouvel arbre",offMessage:"Message (désactiver)",onMessage:"Message (activer)",repeatable:"Répétable",staticFields:"Champs statiques",step:"Étape",tree:"Arbre",treeName:"Nom de l'arbre",type:{address:"Adresse",checkbox:"Case à cocher",date:"Date",email:"Email",file:"Fichier",hidden:"Champs caché",number:"Nombre",password:"Mot de passe",radio:"Radio",select:"Select",switch:"Switch",tel:"Téléphone",text:"Texte",time:"Temps",tree:"Arbre",url:"URL"},value:"Valeur",values:"Valeurs"},oi={addFirstTitle:"Ajouter un champ",addTitle:"Ajouter un champ à « {{name}} »",deleteTitle:"Voulez vraiment supprimer « {{name}} »",editTitle:"Éditer le champ « {{name}} »",resetTreeContent:"Êtes-vous sûr de vouloir réinitialiser l'arbre ?",saveTree:"Enregistrer l'arbre"},wf={error:{fetchTree:"Une erreur est survenue veuillez réessayer",saveTree:"Une erreur est survenue veuillez réessayer",updateTree:"Une erreur est survenue veuillez réessayer"},success:{saveTree:"Arbre enregistré",updateTree:"Arbre mis à jour"}},If={add:"Ajouter",cancel:"Annuler",disabled:"Désactivé",edit:"Éditer",isABranch:"Est une branche",isAHidden:"Est un champs caché",isALeaf:"Est une feuille",isARepeatable:"Est répétable",isATree:"Est un arbre",isTheRoot:"Est la racine",label:"Label",name:"Nom",remove:"Supprimer",required:"Requis",save:"Enregistrer",show:"Afficher",tag:"Tag",type:"Type",validate:"Valider",value:"Valeur",values:"Valeurs"};Ot.use(ui).use($e.initReactI18next).init({debug:!1,fallbackLng:"en",interpolation:{escapeValue:!1},load:"languageOnly",react:{useSuspense:!0},resources:{en:{button:Nf,form:ni,modal:oi,snackMessage:Ef,translation:Of},fr:{button:Cf,form:ni,modal:oi,snackMessage:wf,translation:If}},returnNull:!1}).then(()=>{document.documentElement.lang!==Ot.resolvedLanguage&&Ot.resolvedLanguage&&document.documentElement.setAttribute("lang",Ot.resolvedLanguage)}),Ot.on("languageChanged",e=>{document.documentElement.setAttribute("lang",e)});const Af=({initialTree:e,initialTreeId:t,backendConfig:n})=>(N.useLayoutEffect(()=>{ct.defaults.baseURL=n==null?void 0:n.baseUrl,n!=null&&n.authToken&&(ct.defaults.headers.common.Authorization=`Bearer ${n==null?void 0:n.authToken}`)},[n==null?void 0:n.authToken,n==null?void 0:n.baseUrl]),c.jsx(lt.QueryClientProvider,{client:vi,children:c.jsx(xi,{authToken:n==null?void 0:n.authToken,children:c.jsx(Df,{backendConfig:n,initialTree:e,initialTreeId:t,children:c.jsx(yi,{children:c.jsx(Ni,{children:c.jsx(Tf,{})})})})})}));Oe.TreePlusIcon=Zn,Oe.Treege=Af,Object.defineProperty(Oe,Symbol.toStringTag,{value:"Module"})});
|