fastapi-rtk 0.0.80 → 0.0.81
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/fastapi-rtk.es.js +1887 -1868
- package/dist/fastapi-rtk.umd.js +60 -60
- package/package.json +1 -1
package/dist/fastapi-rtk.umd.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
(function(I,_){typeof exports=="object"&&typeof module<"u"?_(exports,require("react"),require("react-router-dom"),require("@mantine/hooks"),require("@mantine/core"),require("@mantine/form"),require("@mantine/dates"),require("@jsonforms/core"),require("@jsonforms/react"),require("@emotion/react")):typeof define=="function"&&define.amd?define(["exports","react","react-router-dom","@mantine/hooks","@mantine/core","@mantine/form","@mantine/dates","@jsonforms/core","@jsonforms/react","@emotion/react"],_):(I=typeof globalThis<"u"?globalThis:I||self,_(I["fastapi-rtk"]={},I.React$1,I.reactRouterDom,I.hooks,I.core,I.form,I.dates,I.core$1,I.react,I.react$1))})(this,function(I,_,Ft,At,b,gi,Xt,W,_e,pa){"use strict";var rO=Object.defineProperty;var nO=(I,_,Ft)=>_ in I?rO(I,_,{enumerable:!0,configurable:!0,writable:!0,value:Ft}):I[_]=Ft;var
|
|
1
|
+
(function(I,_){typeof exports=="object"&&typeof module<"u"?_(exports,require("react"),require("react-router-dom"),require("@mantine/hooks"),require("@mantine/core"),require("@mantine/form"),require("@mantine/dates"),require("@jsonforms/core"),require("@jsonforms/react"),require("@emotion/react")):typeof define=="function"&&define.amd?define(["exports","react","react-router-dom","@mantine/hooks","@mantine/core","@mantine/form","@mantine/dates","@jsonforms/core","@jsonforms/react","@emotion/react"],_):(I=typeof globalThis<"u"?globalThis:I||self,_(I["fastapi-rtk"]={},I.React$1,I.reactRouterDom,I.hooks,I.core,I.form,I.dates,I.core$1,I.react,I.react$1))})(this,function(I,_,Ft,At,b,gi,Xt,W,_e,pa){"use strict";var rO=Object.defineProperty;var nO=(I,_,Ft)=>_ in I?rO(I,_,{enumerable:!0,configurable:!0,writable:!0,value:Ft}):I[_]=Ft;var If=(I,_,Ft)=>nO(I,typeof _!="symbol"?_+"":_,Ft);function $f(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const r in e)if(r!=="default"){const n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:()=>e[r]})}}return t.default=e,Object.freeze(t)}const Je=$f(_);var Ce=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function yt(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var yi={exports:{}},_r={};/**
|
|
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 ha;function
|
|
9
|
+
*/var ha;function Df(){if(ha)return _r;ha=1;var e=_,t=Symbol.for("react.element"),r=Symbol.for("react.fragment"),n=Object.prototype.hasOwnProperty,i=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,o={key:!0,ref:!0,__self:!0,__source:!0};function a(s,l,u){var f,c={},p=null,y=null;u!==void 0&&(p=""+u),l.key!==void 0&&(p=""+l.key),l.ref!==void 0&&(y=l.ref);for(f in l)n.call(l,f)&&!o.hasOwnProperty(f)&&(c[f]=l[f]);if(s&&s.defaultProps)for(f in l=s.defaultProps,l)c[f]===void 0&&(c[f]=l[f]);return{$$typeof:t,type:s,key:p,ref:y,props:c,_owner:i.current}}return _r.Fragment=r,_r.jsx=a,_r.jsxs=a,_r}var Er={};/**
|
|
10
10
|
* @license React
|
|
11
11
|
* react-jsx-runtime.development.js
|
|
12
12
|
*
|
|
@@ -14,129 +14,129 @@
|
|
|
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 ma;function
|
|
18
|
-
`+J+
|
|
17
|
+
*/var ma;function Mf(){return ma||(ma=1,process.env.NODE_ENV!=="production"&&function(){var e=_,t=Symbol.for("react.element"),r=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),i=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),a=Symbol.for("react.provider"),s=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),f=Symbol.for("react.suspense_list"),c=Symbol.for("react.memo"),p=Symbol.for("react.lazy"),y=Symbol.for("react.offscreen"),g=Symbol.iterator,m="@@iterator";function T(v){if(v===null||typeof v!="object")return null;var w=g&&v[g]||v[m];return typeof w=="function"?w:null}var j=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function F(v){{for(var w=arguments.length,L=new Array(w>1?w-1:0),K=1;K<w;K++)L[K-1]=arguments[K];D("error",v,L)}}function D(v,w,L){{var K=j.ReactDebugCurrentFrame,fe=K.getStackAddendum();fe!==""&&(w+="%s",L=L.concat([fe]));var ye=L.map(function(ue){return String(ue)});ye.unshift("Warning: "+w),Function.prototype.apply.call(console[v],console,ye)}}var O=!1,E=!1,M=!1,Y=!1,ce=!1,ie;ie=Symbol.for("react.module.reference");function h(v){return!!(typeof v=="string"||typeof v=="function"||v===n||v===o||ce||v===i||v===u||v===f||Y||v===y||O||E||M||typeof v=="object"&&v!==null&&(v.$$typeof===p||v.$$typeof===c||v.$$typeof===a||v.$$typeof===s||v.$$typeof===l||v.$$typeof===ie||v.getModuleId!==void 0))}function A(v,w,L){var K=v.displayName;if(K)return K;var fe=w.displayName||w.name||"";return fe!==""?L+"("+fe+")":L}function U(v){return v.displayName||"Context"}function H(v){if(v==null)return null;if(typeof v.tag=="number"&&F("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof v=="function")return v.displayName||v.name||null;if(typeof v=="string")return v;switch(v){case n:return"Fragment";case r:return"Portal";case o:return"Profiler";case i:return"StrictMode";case u:return"Suspense";case f:return"SuspenseList"}if(typeof v=="object")switch(v.$$typeof){case s:var w=v;return U(w)+".Consumer";case a:var L=v;return U(L._context)+".Provider";case l:return A(v,v.render,"ForwardRef");case c:var K=v.displayName||null;return K!==null?K:H(v.type)||"Memo";case p:{var fe=v,ye=fe._payload,ue=fe._init;try{return H(ue(ye))}catch{return null}}}return null}var te=Object.assign,ve=0,G,oe,le,He,k,$,Z;function B(){}B.__reactDisabledLog=!0;function X(){{if(ve===0){G=console.log,oe=console.info,le=console.warn,He=console.error,k=console.group,$=console.groupCollapsed,Z=console.groupEnd;var v={configurable:!0,enumerable:!0,value:B,writable:!0};Object.defineProperties(console,{info:v,log:v,warn:v,error:v,group:v,groupCollapsed:v,groupEnd:v})}ve++}}function V(){{if(ve--,ve===0){var v={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:te({},v,{value:G}),info:te({},v,{value:oe}),warn:te({},v,{value:le}),error:te({},v,{value:He}),group:te({},v,{value:k}),groupCollapsed:te({},v,{value:$}),groupEnd:te({},v,{value:Z})})}ve<0&&F("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var q=j.ReactCurrentDispatcher,J;function Q(v,w,L){{if(J===void 0)try{throw Error()}catch(fe){var K=fe.stack.trim().match(/\n( *(at )?)/);J=K&&K[1]||""}return`
|
|
18
|
+
`+J+v}}var re=!1,ee;{var Ie=typeof WeakMap=="function"?WeakMap:Map;ee=new Ie}function N(v,w){if(!v||re)return"";{var L=ee.get(v);if(L!==void 0)return L}var K;re=!0;var fe=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var ye;ye=q.current,q.current=null,X();try{if(w){var ue=function(){throw Error()};if(Object.defineProperty(ue.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(ue,[])}catch(be){K=be}Reflect.construct(v,[],ue)}else{try{ue.call()}catch(be){K=be}v.call(ue.prototype)}}else{try{throw Error()}catch(be){K=be}v()}}catch(be){if(be&&K&&typeof be.stack=="string"){for(var P=be.stack.split(`
|
|
19
19
|
`),x=K.stack.split(`
|
|
20
20
|
`),C=P.length-1,R=x.length-1;C>=1&&R>=0&&P[C]!==x[R];)R--;for(;C>=1&&R>=0;C--,R--)if(P[C]!==x[R]){if(C!==1||R!==1)do if(C--,R--,R<0||P[C]!==x[R]){var ne=`
|
|
21
|
-
`+P[C].replace(" at new "," at ");return
|
|
21
|
+
`+P[C].replace(" at new "," at ");return v.displayName&&ne.includes("<anonymous>")&&(ne=ne.replace("<anonymous>",v.displayName)),typeof v=="function"&&ee.set(v,ne),ne}while(C>=1&&R>=0);break}}}finally{re=!1,q.current=ye,V(),Error.prepareStackTrace=fe}var Ae=v?v.displayName||v.name:"",Se=Ae?Q(Ae):"";return typeof v=="function"&&ee.set(v,Se),Se}function Me(v,w,L){return N(v,!1)}function z(v){var w=v.prototype;return!!(w&&w.isReactComponent)}function Ge(v,w,L){if(v==null)return"";if(typeof v=="function")return N(v,z(v));if(typeof v=="string")return Q(v);switch(v){case u:return Q("Suspense");case f:return Q("SuspenseList")}if(typeof v=="object")switch(v.$$typeof){case l:return Me(v.render);case c:return Ge(v.type,w,L);case p:{var K=v,fe=K._payload,ye=K._init;try{return Ge(ye(fe),w,L)}catch{}}}return""}var Ke=Object.prototype.hasOwnProperty,at={},Yt=j.ReactDebugCurrentFrame;function Et(v){if(v){var w=v._owner,L=Ge(v.type,v._source,w?w.type:null);Yt.setExtraStackFrame(L)}else Yt.setExtraStackFrame(null)}function ri(v,w,L,K,fe){{var ye=Function.call.bind(Ke);for(var ue in v)if(ye(v,ue)){var P=void 0;try{if(typeof v[ue]!="function"){var x=Error((K||"React class")+": "+L+" type `"+ue+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof v[ue]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw x.name="Invariant Violation",x}P=v[ue](w,ue,K,L,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(C){P=C}P&&!(P instanceof Error)&&(Et(fe),F("%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",L,ue,typeof P),Et(null)),P instanceof Error&&!(P.message in at)&&(at[P.message]=!0,Et(fe),F("Failed %s type: %s",L,P.message),Et(null))}}}var ni=Array.isArray;function Wr(v){return ni(v)}function Hr(v){{var w=typeof Symbol=="function"&&Symbol.toStringTag,L=w&&v[Symbol.toStringTag]||v.constructor.name||"Object";return L}}function qt(v){try{return St(v),!1}catch{return!0}}function St(v){return""+v}function Ct(v){if(qt(v))return F("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",Hr(v)),St(v)}var Mt=j.ReactCurrentOwner,ii={key:!0,ref:!0,__self:!0,__source:!0},Gr,gr,yr;yr={};function vr(v){if(Ke.call(v,"ref")){var w=Object.getOwnPropertyDescriptor(v,"ref").get;if(w&&w.isReactWarning)return!1}return v.ref!==void 0}function br(v){if(Ke.call(v,"key")){var w=Object.getOwnPropertyDescriptor(v,"key").get;if(w&&w.isReactWarning)return!1}return v.key!==void 0}function ft(v,w){if(typeof v.ref=="string"&&Mt.current&&w&&Mt.current.stateNode!==w){var L=H(Mt.current.type);yr[L]||(F('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',H(Mt.current.type),v.ref),yr[L]=!0)}}function Rt(v,w){{var L=function(){Gr||(Gr=!0,F("%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)",w))};L.isReactWarning=!0,Object.defineProperty(v,"key",{get:L,configurable:!0})}}function Yr(v,w){{var L=function(){gr||(gr=!0,F("%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)",w))};L.isReactWarning=!0,Object.defineProperty(v,"ref",{get:L,configurable:!0})}}var qr=function(v,w,L,K,fe,ye,ue){var P={$$typeof:t,type:v,key:w,ref:L,props:ue,_owner:ye};return P._store={},Object.defineProperty(P._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(P,"_self",{configurable:!1,enumerable:!1,writable:!1,value:K}),Object.defineProperty(P,"_source",{configurable:!1,enumerable:!1,writable:!1,value:fe}),Object.freeze&&(Object.freeze(P.props),Object.freeze(P)),P};function da(v,w,L,K,fe){{var ye,ue={},P=null,x=null;L!==void 0&&(Ct(L),P=""+L),br(w)&&(Ct(w.key),P=""+w.key),vr(w)&&(x=w.ref,ft(w,fe));for(ye in w)Ke.call(w,ye)&&!ii.hasOwnProperty(ye)&&(ue[ye]=w[ye]);if(v&&v.defaultProps){var C=v.defaultProps;for(ye in C)ue[ye]===void 0&&(ue[ye]=C[ye])}if(P||x){var R=typeof v=="function"?v.displayName||v.name||"Unknown":v;P&&Rt(ue,R),x&&Yr(ue,R)}return qr(v,P,x,fe,K,Mt.current,ue)}}var wt=j.ReactCurrentOwner,oi=j.ReactDebugCurrentFrame;function Nt(v){if(v){var w=v._owner,L=Ge(v.type,v._source,w?w.type:null);oi.setExtraStackFrame(L)}else oi.setExtraStackFrame(null)}var Pe;Pe=!1;function gt(v){return typeof v=="object"&&v!==null&&v.$$typeof===t}function ai(){{if(wt.current){var v=H(wt.current.type);if(v)return`
|
|
22
22
|
|
|
23
|
-
Check the render method of \``+
|
|
23
|
+
Check the render method of \``+v+"`."}return""}}function si(v){return""}var xr={};function li(v){{var w=ai();if(!w){var L=typeof v=="string"?v:v.displayName||v.name;L&&(w=`
|
|
24
24
|
|
|
25
|
-
Check the top-level render call using <`+L+">.")}return w}}function Kr(
|
|
25
|
+
Check the top-level render call using <`+L+">.")}return w}}function Kr(v,w){{if(!v._store||v._store.validated||v.key!=null)return;v._store.validated=!0;var L=li(w);if(xr[L])return;xr[L]=!0;var K="";v&&v._owner&&v._owner!==wt.current&&(K=" It was passed a child from "+H(v._owner.type)+"."),Nt(v),F('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',L,K),Nt(null)}}function ui(v,w){{if(typeof v!="object")return;if(Wr(v))for(var L=0;L<v.length;L++){var K=v[L];gt(K)&&Kr(K,w)}else if(gt(v))v._store&&(v._store.validated=!0);else if(v){var fe=T(v);if(typeof fe=="function"&&fe!==v.entries)for(var ye=fe.call(v),ue;!(ue=ye.next()).done;)gt(ue.value)&&Kr(ue.value,w)}}}function ci(v){{var w=v.type;if(w==null||typeof w=="string")return;var L;if(typeof w=="function")L=w.propTypes;else if(typeof w=="object"&&(w.$$typeof===l||w.$$typeof===c))L=w.propTypes;else return;if(L){var K=H(w);ri(L,v.props,"prop",K,v)}else if(w.PropTypes!==void 0&&!Pe){Pe=!0;var fe=H(w);F("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",fe||"Unknown")}typeof w.getDefaultProps=="function"&&!w.getDefaultProps.isReactClassApproved&&F("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function fi(v){{for(var w=Object.keys(v.props),L=0;L<w.length;L++){var K=w[L];if(K!=="children"&&K!=="key"){Nt(v),F("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",K),Nt(null);break}}v.ref!==null&&(Nt(v),F("Invalid attribute `ref` supplied to `React.Fragment`."),Nt(null))}}var di={};function rt(v,w,L,K,fe,ye){{var ue=h(v);if(!ue){var P="";(v===void 0||typeof v=="object"&&v!==null&&Object.keys(v).length===0)&&(P+=" 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 x=si();x?P+=x:P+=ai();var C;v===null?C="null":Wr(v)?C="array":v!==void 0&&v.$$typeof===t?(C="<"+(H(v.type)||"Unknown")+" />",P=" Did you accidentally export a JSX literal instead of a component?"):C=typeof v,F("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",C,P)}var R=da(v,w,L,fe,ye);if(R==null)return R;if(ue){var ne=w.children;if(ne!==void 0)if(K)if(Wr(ne)){for(var Ae=0;Ae<ne.length;Ae++)ui(ne[Ae],v);Object.freeze&&Object.freeze(ne)}else F("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 ui(ne,v)}if(Ke.call(w,"key")){var Se=H(v),be=Object.keys(w).filter(function(Ne){return Ne!=="key"}),Xe=be.length>0?"{key: someKey, "+be.join(": ..., ")+": ...}":"{key: someKey}";if(!di[Se+Xe]){var Kt=be.length>0?"{"+be.join(": ..., ")+": ...}":"{}";F(`A props object containing a "key" prop is being spread into JSX:
|
|
26
26
|
let props = %s;
|
|
27
27
|
<%s {...props} />
|
|
28
28
|
React keys must be passed directly to JSX without using spread:
|
|
29
29
|
let props = %s;
|
|
30
|
-
<%s key={someKey} {...props} />`,Xe,Ee,Kt,Ee),di[Ee+Xe]=!0}}return g===n?fi(R):ci(R),R}}function Tr(g,w,L){return rt(g,w,L,!0)}function pi(g,w,L){return rt(g,w,L,!1)}var hi=pi,mi=Tr;Sr.Fragment=n,Sr.jsx=hi,Sr.jsxs=mi}()),Sr}process.env.NODE_ENV==="production"?yi.exports=$f():yi.exports=Df();var d=yi.exports;function ze({path:e,method:t,body:r=void 0,queryParams:n=void 0}){const i=Object.entries(n||{}).reduce((s,[l,u])=>((Array.isArray(u)||typeof u=="object")&&(u=JSON.stringify(u)),s[l]=u,s),{}),o=new Ft.createSearchParams(i);e=e+"?"+o;const a={method:t,mode:"cors",credentials:"include",headers:{"Content-Type":"application/json"},redirect:"follow",referrerPolicy:"no-referrer",body:r?JSON.stringify(r):null};return{fetchPath:e,options:a}}function Mf(e){const t=[];if(e.length===0)return"";if(typeof e[0]!="string")throw new TypeError("Url must be a string. Received "+e[0]);e[0].match(/^[^/:]+:\/*$/)&&e.length>1&&(e[0]=e.shift()+e[0]),e[0].match(/^file:\/\/\//)?e[0]=e[0].replace(/^([^/:]+):\/*/,"$1:///"):e[0]=e[0].replace(/^([^/:]+):\/*/,"$1://");for(let i=0;i<e.length;i++){let o=e[i];if(typeof o!="string")throw new TypeError("Url must be a string. Received "+o);o!==""&&(i>0&&(o=o.replace(/^[\/]+/,"")),i<e.length-1?o=o.replace(/[\/]+$/,""):o=o.replace(/[\/]+$/,"/"),t.push(o))}let r=t.join("/");r=r.replace(/\/(\?|&|#[^!])/g,"$1");const n=r.split("?");return r=n.shift()+(n.length>0?"?":"")+n.join("&"),r}function $e(...e){const t=Array.from(Array.isArray(e[0])?e[0]:e);return Mf(t)}function Xr(e,{autoInvoke:t=!0,initialLoading:r=!1,clearDataOnRefetch:n=!1,...i}={}){const[o,a]=_.useState(null),[s,l]=_.useState(r),[u,f]=_.useState(null),c=_.useRef(null),p=_.useCallback(()=>{if(e)return n&&a(null),f(null),c.current&&c.current.abort(),c.current=new AbortController,l(!0),fetch(e,{signal:c.current.signal,...i}).then(async m=>{const y=await m.json();if(!m.ok){const T=typeof y.detail=="string"?y.detail:JSON.stringify(y.detail,null,2);throw new Error(T)}return a(y),l(!1),y}).catch(m=>(m&&m.name!=="AbortError"&&(f(m),l(!1)),m))},[e]),v=_.useCallback(()=>{var m;c.current&&((m=c.current)==null||m.abort(""),l(!1))},[]);return _.useEffect(()=>(t&&p(),()=>{c.current&&c.current.abort("")}),[p,t]),{data:o,loading:s,error:u,refetch:p,abort:v}}function ga({path:e,autoInvoke:t=!0,initialLoading:r=!0}){const{fetchPath:n,options:i}=_.useMemo(()=>ze({path:$e(e,"auth/user"),method:"GET"}),[e]),{data:o,loading:a,refetch:s,error:l}=Xr(n,{autoInvoke:t,initialLoading:r,...i});return{user:o,loading:a,refetch:s,error:l}}function ya({path:e,queryParams:t,autoInvoke:r=!0,clearDataOnRefetch:n=!1}){const{fetchPath:i,options:o}=_.useMemo(()=>ze({path:$e(e,"/"),method:"GET",queryParams:t}),[e,t]),{data:a,loading:s,refetch:l,error:u}=Xr(i,{autoInvoke:r,clearDataOnRefetch:n,...o});return{data:_.useMemo(()=>{if(!a)return null;const c=a.result.map((p,v)=>{const m=a.ids[v];return{...p,id:m}});return{...a,result:c}},[a]),loading:s,refetch:l,error:u}}const Rf=async(e,t)=>{const{fetchPath:r,options:n}=ze({path:$e(e,"/"),method:"POST",body:t}),i=await fetch(r,n);let o=null;const a=i.headers.get("content-type");if(a&&a.includes("application/json")?o=await i.json():o=await i.text(),!i.ok)throw typeof o=="object"?new Error(typeof o.detail=="string"?o.detail:JSON.stringify(o,null,2)):new Error(o);return o},Nf=async(e,t)=>{const{fetchPath:r,options:n}=ze({path:$e(e,t.toString()),method:"DELETE"}),i=await fetch(r,n);let o=null;const a=i.headers.get("content-type");if(a&&a.includes("application/json")?o=await i.json():o=await i.text(),!i.ok)throw typeof o=="object"?new Error(typeof o.detail=="string"?o.detail:JSON.stringify(o,null,2)):new Error(o);return o},Ff=async(e,t)=>{const{fetchPath:r,options:n}=ze({path:$e(e,t.toString()),method:"GET"}),i=await fetch(r,n);let o=null;const a=i.headers.get("content-type");if(a&&a.includes("application/json")?o=await i.json():o=await i.text(),!i.ok)throw typeof o=="object"?new Error(typeof o.detail=="string"?o.detail:JSON.stringify(o,null,2)):new Error(o);return o},Lf=async(e,t,r)=>{const{fetchPath:n,options:i}=ze({path:$e(e,t.toString()),method:"PUT",body:r}),o=await fetch(n,i);let a=null;const s=o.headers.get("content-type");if(s&&s.includes("application/json")?a=await o.json():a=await o.text(),!o.ok)throw typeof a=="object"?new Error(typeof a.detail=="string"?a.detail:JSON.stringify(a,null,2)):new Error(a);return a},Ze=e=>e&&typeof e=="object"?Array.isArray(e)?e.join(","):JSON.stringify(e):e;function Jr(e,t){const r=e||{columns:[],filters:[],page:0,page_size:25};return t.hasOwnProperty("columns")&&(r.columns=t.columns),t.hasOwnProperty("filters")&&(r.filters=t.filters),t.hasOwnProperty("order_column")&&(r.order_column=t.order_column),t.hasOwnProperty("order_direction")&&(r.order_direction=t.order_direction),t.hasOwnProperty("page")&&(r.page=t.page),t.hasOwnProperty("page_size")&&(r.page_size=t.page_size),r}const va=e=>{const t={};for(const r of e)switch(r.type){case"RelatedList":t[r.name]=[];break;case"Boolean":t[r.name]="false";break;case"Date":case"DateTime":case"Integer":case"Float":case"Geometry":case"Raw":case"Related":t[r.name]=void 0;break;default:t[r.name]=""}return t};function Lt(e){this._maxSize=e,this.clear()}Lt.prototype.clear=function(){this._size=0,this._values=Object.create(null)},Lt.prototype.get=function(e){return this._values[e]},Lt.prototype.set=function(e,t){return this._size>=this._maxSize&&this.clear(),e in this._values||this._size++,this._values[e]=t};var zf=/[^.^\]^[]+|(?=\[\]|\.\.)/g,ba=/^\d+$/,Bf=/^\d/,Uf=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,Vf=/^\s*(['"]?)(.*?)(\1)\s*$/,vi=512,xa=new Lt(vi),Ta=new Lt(vi),_a=new Lt(vi),zt={Cache:Lt,split:xi,normalizePath:bi,setter:function(e){var t=bi(e);return Ta.get(e)||Ta.set(e,function(n,i){for(var o=0,a=t.length,s=n;o<a-1;){var l=t[o];if(l==="__proto__"||l==="constructor"||l==="prototype")return n;s=s[t[o++]]}s[t[o]]=i})},getter:function(e,t){var r=bi(e);return _a.get(e)||_a.set(e,function(i){for(var o=0,a=r.length;o<a;)if(i!=null||!t)i=i[r[o++]];else return;return i})},join:function(e){return e.reduce(function(t,r){return t+(Ti(r)||ba.test(r)?"["+r+"]":(t?".":"")+r)},"")},forEach:function(e,t,r){Wf(Array.isArray(e)?e:xi(e),t,r)}};function bi(e){return xa.get(e)||xa.set(e,xi(e).map(function(t){return t.replace(Vf,"$2")}))}function xi(e){return e.match(zf)||[""]}function Wf(e,t,r){var n=e.length,i,o,a,s;for(o=0;o<n;o++)i=e[o],i&&(Yf(i)&&(i='"'+i+'"'),s=Ti(i),a=!s&&/^\d+$/.test(i),t.call(r,i,s,a,o,e))}function Ti(e){return typeof e=="string"&&e&&["'",'"'].indexOf(e.charAt(0))!==-1}function Hf(e){return e.match(Bf)&&!e.match(ba)}function Gf(e){return Uf.test(e)}function Yf(e){return!Ti(e)&&(Hf(e)||Gf(e))}const qf=/[A-Z\xc0-\xd6\xd8-\xde]?[a-z\xdf-\xf6\xf8-\xff]+(?:['’](?:d|ll|m|re|s|t|ve))?(?=[\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000]|[A-Z\xc0-\xd6\xd8-\xde]|$)|(?:[A-Z\xc0-\xd6\xd8-\xde]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])+(?:['’](?:D|LL|M|RE|S|T|VE))?(?=[\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000]|[A-Z\xc0-\xd6\xd8-\xde](?:[a-z\xdf-\xf6\xf8-\xff]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])|$)|[A-Z\xc0-\xd6\xd8-\xde]?(?:[a-z\xdf-\xf6\xf8-\xff]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])+(?:['’](?:d|ll|m|re|s|t|ve))?|[A-Z\xc0-\xd6\xd8-\xde]+(?:['’](?:D|LL|M|RE|S|T|VE))?|\d*(?:1ST|2ND|3RD|(?![123])\dTH)(?=\b|[a-z_])|\d*(?:1st|2nd|3rd|(?![123])\dth)(?=\b|[A-Z_])|\d+|(?:[\u2700-\u27bf]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff])[\ufe0e\ufe0f]?(?:[\u0300-\u036f\ufe20-\ufe2f\u20d0-\u20ff]|\ud83c[\udffb-\udfff])?(?:\u200d(?:[^\ud800-\udfff]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff])[\ufe0e\ufe0f]?(?:[\u0300-\u036f\ufe20-\ufe2f\u20d0-\u20ff]|\ud83c[\udffb-\udfff])?)*/g,Zr=e=>e.match(qf)||[],Qr=e=>e[0].toUpperCase()+e.slice(1),_i=(e,t)=>Zr(e).join(t).toLowerCase(),Sa=e=>Zr(e).reduce((t,r)=>`${t}${t?r[0].toUpperCase()+r.slice(1).toLowerCase():r.toLowerCase()}`,"");var Si={words:Zr,upperFirst:Qr,camelCase:Sa,pascalCase:e=>Qr(Sa(e)),snakeCase:e=>_i(e,"_"),kebabCase:e=>_i(e,"-"),sentenceCase:e=>Qr(_i(e," ")),titleCase:e=>Zr(e).map(Qr).join(" ")},Ei={exports:{}};Ei.exports=function(e){return Ea(Kf(e),e)},Ei.exports.array=Ea;function Ea(e,t){var r=e.length,n=new Array(r),i={},o=r,a=Xf(t),s=Jf(e);for(t.forEach(function(u){if(!s.has(u[0])||!s.has(u[1]))throw new Error("Unknown node. There is an unknown node in the supplied edges.")});o--;)i[o]||l(e[o],o,new Set);return n;function l(u,f,c){if(c.has(u)){var p;try{p=", node was:"+JSON.stringify(u)}catch{p=""}throw new Error("Cyclic dependency"+p)}if(!s.has(u))throw new Error("Found unknown node. Make sure to provided all involved nodes. Unknown node: "+JSON.stringify(u));if(!i[f]){i[f]=!0;var v=a.get(u)||new Set;if(v=Array.from(v),f=v.length){c.add(u);do{var m=v[--f];l(m,s.get(m),c)}while(f);c.delete(u)}n[--r]=u}}}function Kf(e){for(var t=new Set,r=0,n=e.length;r<n;r++){var i=e[r];t.add(i[0]),t.add(i[1])}return Array.from(t)}function Xf(e){for(var t=new Map,r=0,n=e.length;r<n;r++){var i=e[r];t.has(i[0])||t.set(i[0],new Set),t.has(i[1])||t.set(i[1],new Set),t.get(i[0]).add(i[1])}return t}function Jf(e){for(var t=new Map,r=0,n=e.length;r<n;r++)t.set(e[r],r);return t}var Zf=Ei.exports;const Qf=yt(Zf),ed=Object.prototype.toString,td=Error.prototype.toString,rd=RegExp.prototype.toString,nd=typeof Symbol<"u"?Symbol.prototype.toString:()=>"",id=/^Symbol\((.*)\)(.*)$/;function od(e){return e!=+e?"NaN":e===0&&1/e<0?"-0":""+e}function Ca(e,t=!1){if(e==null||e===!0||e===!1)return""+e;const r=typeof e;if(r==="number")return od(e);if(r==="string")return t?`"${e}"`:e;if(r==="function")return"[Function "+(e.name||"anonymous")+"]";if(r==="symbol")return nd.call(e).replace(id,"Symbol($1)");const n=ed.call(e).slice(8,-1);return n==="Date"?isNaN(e.getTime())?""+e:e.toISOString(e):n==="Error"||e instanceof Error?"["+td.call(e)+"]":n==="RegExp"?rd.call(e):null}function dt(e,t){let r=Ca(e,t);return r!==null?r:JSON.stringify(e,function(n,i){let o=Ca(this[n],t);return o!==null?o:i},2)}function wa(e){return e==null?[]:[].concat(e)}let Aa,Oa,ka,ad=/\$\{\s*(\w+)\s*\}/g;Aa=Symbol.toStringTag;class Pa{constructor(t,r,n,i){this.name=void 0,this.message=void 0,this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=void 0,this.inner=void 0,this[Aa]="Error",this.name="ValidationError",this.value=r,this.path=n,this.type=i,this.errors=[],this.inner=[],wa(t).forEach(o=>{if(Fe.isError(o)){this.errors.push(...o.errors);const a=o.inner.length?o.inner:[o];this.inner.push(...a)}else this.errors.push(o)}),this.message=this.errors.length>1?`${this.errors.length} errors occurred`:this.errors[0]}}Oa=Symbol.hasInstance,ka=Symbol.toStringTag;class Fe extends Error{static formatError(t,r){const n=r.label||r.path||"this";return n!==r.path&&(r=Object.assign({},r,{path:n})),typeof t=="string"?t.replace(ad,(i,o)=>dt(r[o])):typeof t=="function"?t(r):t}static isError(t){return t&&t.name==="ValidationError"}constructor(t,r,n,i,o){const a=new Pa(t,r,n,i);if(o)return a;super(),this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=[],this.inner=[],this[ka]="Error",this.name=a.name,this.message=a.message,this.type=a.type,this.value=a.value,this.path=a.path,this.errors=a.errors,this.inner=a.inner,Error.captureStackTrace&&Error.captureStackTrace(this,Fe)}static[Oa](t){return Pa[Symbol.hasInstance](t)||super[Symbol.hasInstance](t)}}let pt={default:"${path} is invalid",required:"${path} is a required field",defined:"${path} must be defined",notNull:"${path} cannot be null",oneOf:"${path} must be one of the following values: ${values}",notOneOf:"${path} must not be one of the following values: ${values}",notType:({path:e,type:t,value:r,originalValue:n})=>{const i=n!=null&&n!==r?` (cast from the value \`${dt(n,!0)}\`).`:".";return t!=="mixed"?`${e} must be a \`${t}\` type, but the final value was: \`${dt(r,!0)}\``+i:`${e} must match the configured type. The validated value was: \`${dt(r,!0)}\``+i}},Ye={length:"${path} must be exactly ${length} characters",min:"${path} must be at least ${min} characters",max:"${path} must be at most ${max} characters",matches:'${path} must match the following: "${regex}"',email:"${path} must be a valid email",url:"${path} must be a valid URL",uuid:"${path} must be a valid UUID",datetime:"${path} must be a valid ISO date-time",datetime_precision:"${path} must be a valid ISO date-time with a sub-second precision of exactly ${precision} digits",datetime_offset:'${path} must be a valid ISO date-time with UTC "Z" timezone',trim:"${path} must be a trimmed string",lowercase:"${path} must be a lowercase string",uppercase:"${path} must be a upper case string"},Ot={min:"${path} must be greater than or equal to ${min}",max:"${path} must be less than or equal to ${max}",lessThan:"${path} must be less than ${less}",moreThan:"${path} must be greater than ${more}",positive:"${path} must be a positive number",negative:"${path} must be a negative number",integer:"${path} must be an integer"},Ci={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"},wi={isValue:"${path} field must be ${value}"},Ai={noUnknown:"${path} field has unspecified keys: ${unknown}"},en={min:"${path} field must have at least ${min} items",max:"${path} field must have less than or equal to ${max} items",length:"${path} must have ${length} items"},ja={notType:e=>{const{path:t,value:r,spec:n}=e,i=n.types.length;if(Array.isArray(r)){if(r.length<i)return`${t} tuple value has too few items, expected a length of ${i} but got ${r.length} for value: \`${dt(r,!0)}\``;if(r.length>i)return`${t} tuple value has too many items, expected a length of ${i} but got ${r.length} for value: \`${dt(r,!0)}\``}return Fe.formatError(pt.notType,e)}};var Ia=Object.assign(Object.create(null),{mixed:pt,string:Ye,number:Ot,date:Ci,object:Ai,array:en,boolean:wi,tuple:ja});const Bt=e=>e&&e.__isYupSchema__;class tn{static fromOptions(t,r){if(!r.then&&!r.otherwise)throw new TypeError("either `then:` or `otherwise:` is required for `when()` conditions");let{is:n,then:i,otherwise:o}=r,a=typeof n=="function"?n:(...s)=>s.every(l=>l===n);return new tn(t,(s,l)=>{var u;let f=a(...s)?i:o;return(u=f==null?void 0:f(l))!=null?u:l})}constructor(t,r){this.fn=void 0,this.refs=t,this.refs=t,this.fn=r}resolve(t,r){let n=this.refs.map(o=>o.getValue(r==null?void 0:r.value,r==null?void 0:r.parent,r==null?void 0:r.context)),i=this.fn(n,t,r);if(i===void 0||i===t)return t;if(!Bt(i))throw new TypeError("conditions must return a schema object");return i.resolve(r)}}const rn={context:"$",value:"."};function sd(e,t){return new kt(e,t)}class kt{constructor(t,r={}){if(this.key=void 0,this.isContext=void 0,this.isValue=void 0,this.isSibling=void 0,this.path=void 0,this.getter=void 0,this.map=void 0,typeof t!="string")throw new TypeError("ref must be a string, got: "+t);if(this.key=t.trim(),t==="")throw new TypeError("ref must be a non-empty string");this.isContext=this.key[0]===rn.context,this.isValue=this.key[0]===rn.value,this.isSibling=!this.isContext&&!this.isValue;let n=this.isContext?rn.context:this.isValue?rn.value:"";this.path=this.key.slice(n.length),this.getter=this.path&&zt.getter(this.path,!0),this.map=r.map}getValue(t,r,n){let i=this.isContext?n:this.isValue?t:r;return this.getter&&(i=this.getter(i||{})),this.map&&(i=this.map(i)),i}cast(t,r){return this.getValue(t,r==null?void 0:r.parent,r==null?void 0:r.context)}resolve(){return this}describe(){return{type:"ref",key:this.key}}toString(){return`Ref(${this.key})`}static isRef(t){return t&&t.__isYupRef}}kt.prototype.__isYupRef=!0;const st=e=>e==null;function Jt(e){function t({value:r,path:n="",options:i,originalValue:o,schema:a},s,l){const{name:u,test:f,params:c,message:p,skipAbsent:v}=e;let{parent:m,context:y,abortEarly:T=a.spec.abortEarly,disableStackTrace:j=a.spec.disableStackTrace}=i;function F(A){return kt.isRef(A)?A.getValue(r,m,y):A}function D(A={}){const U=Object.assign({value:r,originalValue:o,label:a.spec.label,path:A.path||n,spec:a.spec,disableStackTrace:A.disableStackTrace||j},c,A.params);for(const te of Object.keys(U))U[te]=F(U[te]);const H=new Fe(Fe.formatError(A.message||p,U),r,U.path,A.type||u,U.disableStackTrace);return H.params=U,H}const O=T?s:l;let S={path:n,parent:m,type:u,from:i.from,createError:D,resolve:F,options:i,originalValue:o,schema:a};const M=A=>{Fe.isError(A)?O(A):A?l(null):O(D())},Y=A=>{Fe.isError(A)?O(A):s(A)};if(v&&st(r))return M(!0);let ie;try{var h;if(ie=f.call(S,r,S),typeof((h=ie)==null?void 0:h.then)=="function"){if(i.sync)throw new Error(`Validation test of type: "${S.type}" returned a Promise during a synchronous validate. This test will finish after the validate call has returned`);return Promise.resolve(ie).then(M,Y)}}catch(A){Y(A);return}M(ie)}return t.OPTIONS=e,t}function Oi(e,t,r,n=r){let i,o,a;return t?(zt.forEach(t,(s,l,u)=>{let f=l?s.slice(1,s.length-1):s;e=e.resolve({context:n,parent:i,value:r});let c=e.type==="tuple",p=u?parseInt(f,10):0;if(e.innerType||c){if(c&&!u)throw new Error(`Yup.reach cannot implicitly index into a tuple type. the path part "${a}" must contain an index to the tuple element, e.g. "${a}[0]"`);if(r&&p>=r.length)throw new Error(`Yup.reach cannot resolve an array item at index: ${s}, in the path: ${t}. because there is no value at that index. `);i=r,r=r&&r[p],e=c?e.spec.types[p]:e.innerType}if(!u){if(!e.fields||!e.fields[f])throw new Error(`The schema does not contain the path: ${t}. (failed at: ${a} which is a type: "${e.type}")`);i=r,r=r&&r[f],e=e.fields[f]}o=f,a=l?"["+s+"]":"."+s}),{schema:e,parent:i,parentPath:o}):{parent:i,parentPath:t,schema:e}}function ld(e,t,r,n){return Oi(e,t,r,n).schema}class nn extends Set{describe(){const t=[];for(const r of this.values())t.push(kt.isRef(r)?r.describe():r);return t}resolveAll(t){let r=[];for(const n of this.values())r.push(t(n));return r}clone(){return new nn(this.values())}merge(t,r){const n=this.clone();return t.forEach(i=>n.add(i)),r.forEach(i=>n.delete(i)),n}}function Zt(e,t=new Map){if(Bt(e)||!e||typeof e!="object")return e;if(t.has(e))return t.get(e);let r;if(e instanceof Date)r=new Date(e.getTime()),t.set(e,r);else if(e instanceof RegExp)r=new RegExp(e),t.set(e,r);else if(Array.isArray(e)){r=new Array(e.length),t.set(e,r);for(let n=0;n<e.length;n++)r[n]=Zt(e[n],t)}else if(e instanceof Map){r=new Map,t.set(e,r);for(const[n,i]of e.entries())r.set(n,Zt(i,t))}else if(e instanceof Set){r=new Set,t.set(e,r);for(const n of e)r.add(Zt(n,t))}else if(e instanceof Object){r={},t.set(e,r);for(const[n,i]of Object.entries(e))r[n]=Zt(i,t)}else throw Error(`Unable to clone ${e}`);return r}class Le{constructor(t){this.type=void 0,this.deps=[],this.tests=void 0,this.transforms=void 0,this.conditions=[],this._mutate=void 0,this.internalTests={},this._whitelist=new nn,this._blacklist=new nn,this.exclusiveTests=Object.create(null),this._typeCheck=void 0,this.spec=void 0,this.tests=[],this.transforms=[],this.withMutation(()=>{this.typeError(pt.notType)}),this.type=t.type,this._typeCheck=t.check,this.spec=Object.assign({strip:!1,strict:!1,abortEarly:!0,recursive:!0,disableStackTrace:!1,nullable:!1,optional:!0,coerce:!0},t==null?void 0:t.spec),this.withMutation(r=>{r.nonNullable()})}get _type(){return this.type}clone(t){if(this._mutate)return t&&Object.assign(this.spec,t),this;const r=Object.create(Object.getPrototypeOf(this));return r.type=this.type,r._typeCheck=this._typeCheck,r._whitelist=this._whitelist.clone(),r._blacklist=this._blacklist.clone(),r.internalTests=Object.assign({},this.internalTests),r.exclusiveTests=Object.assign({},this.exclusiveTests),r.deps=[...this.deps],r.conditions=[...this.conditions],r.tests=[...this.tests],r.transforms=[...this.transforms],r.spec=Zt(Object.assign({},this.spec,t)),r}label(t){let r=this.clone();return r.spec.label=t,r}meta(...t){if(t.length===0)return this.spec.meta;let r=this.clone();return r.spec.meta=Object.assign(r.spec.meta||{},t[0]),r}withMutation(t){let r=this._mutate;this._mutate=!0;let n=t(this);return this._mutate=r,n}concat(t){if(!t||t===this)return this;if(t.type!==this.type&&this.type!=="mixed")throw new TypeError(`You cannot \`concat()\` schema's of different types: ${this.type} and ${t.type}`);let r=this,n=t.clone();const i=Object.assign({},r.spec,n.spec);return n.spec=i,n.internalTests=Object.assign({},r.internalTests,n.internalTests),n._whitelist=r._whitelist.merge(t._whitelist,t._blacklist),n._blacklist=r._blacklist.merge(t._blacklist,t._whitelist),n.tests=r.tests,n.exclusiveTests=r.exclusiveTests,n.withMutation(o=>{t.tests.forEach(a=>{o.test(a.OPTIONS)})}),n.transforms=[...r.transforms,...n.transforms],n}isType(t){return t==null?!!(this.spec.nullable&&t===null||this.spec.optional&&t===void 0):this._typeCheck(t)}resolve(t){let r=this;if(r.conditions.length){let n=r.conditions;r=r.clone(),r.conditions=[],r=n.reduce((i,o)=>o.resolve(i,t),r),r=r.resolve(t)}return r}resolveOptions(t){var r,n,i,o;return Object.assign({},t,{from:t.from||[],strict:(r=t.strict)!=null?r:this.spec.strict,abortEarly:(n=t.abortEarly)!=null?n:this.spec.abortEarly,recursive:(i=t.recursive)!=null?i:this.spec.recursive,disableStackTrace:(o=t.disableStackTrace)!=null?o:this.spec.disableStackTrace})}cast(t,r={}){let n=this.resolve(Object.assign({value:t},r)),i=r.assert==="ignore-optionality",o=n._cast(t,r);if(r.assert!==!1&&!n.isType(o)){if(i&&st(o))return o;let a=dt(t),s=dt(o);throw new TypeError(`The value of ${r.path||"field"} could not be cast to a value that satisfies the schema type: "${n.type}".
|
|
30
|
+
<%s key={someKey} {...props} />`,Xe,Se,Kt,Se),di[Se+Xe]=!0}}return v===n?fi(R):ci(R),R}}function Tr(v,w,L){return rt(v,w,L,!0)}function pi(v,w,L){return rt(v,w,L,!1)}var hi=pi,mi=Tr;Er.Fragment=n,Er.jsx=hi,Er.jsxs=mi}()),Er}process.env.NODE_ENV==="production"?yi.exports=Df():yi.exports=Mf();var d=yi.exports;function ze({path:e,method:t,body:r=void 0,queryParams:n=void 0}){const i=Object.entries(n||{}).reduce((s,[l,u])=>((Array.isArray(u)||typeof u=="object")&&(u=JSON.stringify(u)),s[l]=u,s),{}),o=new Ft.createSearchParams(i);e=e+"?"+o;const a={method:t,mode:"cors",credentials:"include",headers:{"Content-Type":"application/json"},redirect:"follow",referrerPolicy:"no-referrer",body:r?JSON.stringify(r):null};return{fetchPath:e,options:a}}function Rf(e){const t=[];if(e.length===0)return"";if(typeof e[0]!="string")throw new TypeError("Url must be a string. Received "+e[0]);e[0].match(/^[^/:]+:\/*$/)&&e.length>1&&(e[0]=e.shift()+e[0]),e[0].match(/^file:\/\/\//)?e[0]=e[0].replace(/^([^/:]+):\/*/,"$1:///"):e[0]=e[0].replace(/^([^/:]+):\/*/,"$1://");for(let i=0;i<e.length;i++){let o=e[i];if(typeof o!="string")throw new TypeError("Url must be a string. Received "+o);o!==""&&(i>0&&(o=o.replace(/^[\/]+/,"")),i<e.length-1?o=o.replace(/[\/]+$/,""):o=o.replace(/[\/]+$/,"/"),t.push(o))}let r=t.join("/");r=r.replace(/\/(\?|&|#[^!])/g,"$1");const n=r.split("?");return r=n.shift()+(n.length>0?"?":"")+n.join("&"),r}function $e(...e){const t=Array.from(Array.isArray(e[0])?e[0]:e);return Rf(t)}function Xr(e,{autoInvoke:t=!0,initialLoading:r=!1,clearDataOnRefetch:n=!1,...i}={}){const[o,a]=_.useState(null),[s,l]=_.useState(r),[u,f]=_.useState(null),c=_.useRef(null),p=_.useCallback(()=>{if(e)return n&&a(null),f(null),c.current&&c.current.abort(),c.current=new AbortController,l(!0),fetch(e,{signal:c.current.signal,...i}).then(async g=>{const m=await g.json();if(!g.ok){const T=typeof m.detail=="string"?m.detail:JSON.stringify(m.detail,null,2);throw new Error(T)}return a(m),l(!1),m}).catch(g=>(g&&g.name!=="AbortError"&&(f(g),l(!1)),g))},[e]),y=_.useCallback(()=>{var g;c.current&&((g=c.current)==null||g.abort(""),l(!1))},[]);return _.useEffect(()=>(t&&p(),()=>{c.current&&c.current.abort("")}),[p,t]),{data:o,loading:s,error:u,refetch:p,abort:y}}function ga({path:e,autoInvoke:t=!0,initialLoading:r=!0}){const{fetchPath:n,options:i}=_.useMemo(()=>ze({path:$e(e,"auth/user"),method:"GET"}),[e]),{data:o,loading:a,refetch:s,error:l}=Xr(n,{autoInvoke:t,initialLoading:r,...i});return{user:o,loading:a,refetch:s,error:l}}function ya({path:e,queryParams:t,autoInvoke:r=!0,clearDataOnRefetch:n=!1}){const{fetchPath:i,options:o}=_.useMemo(()=>ze({path:$e(e,"/"),method:"GET",queryParams:t}),[e,t]),{data:a,loading:s,refetch:l,error:u}=Xr(i,{autoInvoke:r,clearDataOnRefetch:n,...o});return{data:_.useMemo(()=>{if(!a)return null;const c=a.result.map((p,y)=>{const g=a.ids[y];return{...p,id:g}});return{...a,result:c}},[a]),loading:s,refetch:l,error:u}}const Nf=async(e,t)=>{const{fetchPath:r,options:n}=ze({path:$e(e,"/"),method:"POST",body:t}),i=await fetch(r,n);let o=null;const a=i.headers.get("content-type");if(a&&a.includes("application/json")?o=await i.json():o=await i.text(),!i.ok)throw typeof o=="object"?new Error(typeof o.detail=="string"?o.detail:JSON.stringify(o,null,2)):new Error(o);return o},Ff=async(e,t)=>{const{fetchPath:r,options:n}=ze({path:$e(e,t.toString()),method:"DELETE"}),i=await fetch(r,n);let o=null;const a=i.headers.get("content-type");if(a&&a.includes("application/json")?o=await i.json():o=await i.text(),!i.ok)throw typeof o=="object"?new Error(typeof o.detail=="string"?o.detail:JSON.stringify(o,null,2)):new Error(o);return o},Lf=async(e,t)=>{const{fetchPath:r,options:n}=ze({path:$e(e,t.toString()),method:"GET"}),i=await fetch(r,n);let o=null;const a=i.headers.get("content-type");if(a&&a.includes("application/json")?o=await i.json():o=await i.text(),!i.ok)throw typeof o=="object"?new Error(typeof o.detail=="string"?o.detail:JSON.stringify(o,null,2)):new Error(o);return o},zf=async(e,t,r)=>{const{fetchPath:n,options:i}=ze({path:$e(e,t.toString()),method:"PUT",body:r}),o=await fetch(n,i);let a=null;const s=o.headers.get("content-type");if(s&&s.includes("application/json")?a=await o.json():a=await o.text(),!o.ok)throw typeof a=="object"?new Error(typeof a.detail=="string"?a.detail:JSON.stringify(a,null,2)):new Error(a);return a},Ze=e=>e&&typeof e=="object"?Array.isArray(e)?e.join(","):JSON.stringify(e):e;function Jr(e,t){const r=e||{columns:[],filters:[],page:0,page_size:25};return t.hasOwnProperty("columns")&&(r.columns=t.columns),t.hasOwnProperty("filters")&&(r.filters=t.filters),t.hasOwnProperty("order_column")&&(r.order_column=t.order_column),t.hasOwnProperty("order_direction")&&(r.order_direction=t.order_direction),t.hasOwnProperty("page")&&(r.page=t.page),t.hasOwnProperty("page_size")&&(r.page_size=t.page_size),r}const va=e=>{const t={};for(const r of e)switch(r.type){case"RelatedList":t[r.name]=[];break;case"Boolean":t[r.name]="false";break;case"Date":case"DateTime":case"Integer":case"Float":case"Geometry":case"Raw":case"Related":t[r.name]=void 0;break;default:t[r.name]=""}return t};function Lt(e){this._maxSize=e,this.clear()}Lt.prototype.clear=function(){this._size=0,this._values=Object.create(null)},Lt.prototype.get=function(e){return this._values[e]},Lt.prototype.set=function(e,t){return this._size>=this._maxSize&&this.clear(),e in this._values||this._size++,this._values[e]=t};var Bf=/[^.^\]^[]+|(?=\[\]|\.\.)/g,ba=/^\d+$/,Uf=/^\d/,Vf=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,Wf=/^\s*(['"]?)(.*?)(\1)\s*$/,vi=512,xa=new Lt(vi),Ta=new Lt(vi),_a=new Lt(vi),zt={Cache:Lt,split:xi,normalizePath:bi,setter:function(e){var t=bi(e);return Ta.get(e)||Ta.set(e,function(n,i){for(var o=0,a=t.length,s=n;o<a-1;){var l=t[o];if(l==="__proto__"||l==="constructor"||l==="prototype")return n;s=s[t[o++]]}s[t[o]]=i})},getter:function(e,t){var r=bi(e);return _a.get(e)||_a.set(e,function(i){for(var o=0,a=r.length;o<a;)if(i!=null||!t)i=i[r[o++]];else return;return i})},join:function(e){return e.reduce(function(t,r){return t+(Ti(r)||ba.test(r)?"["+r+"]":(t?".":"")+r)},"")},forEach:function(e,t,r){Hf(Array.isArray(e)?e:xi(e),t,r)}};function bi(e){return xa.get(e)||xa.set(e,xi(e).map(function(t){return t.replace(Wf,"$2")}))}function xi(e){return e.match(Bf)||[""]}function Hf(e,t,r){var n=e.length,i,o,a,s;for(o=0;o<n;o++)i=e[o],i&&(qf(i)&&(i='"'+i+'"'),s=Ti(i),a=!s&&/^\d+$/.test(i),t.call(r,i,s,a,o,e))}function Ti(e){return typeof e=="string"&&e&&["'",'"'].indexOf(e.charAt(0))!==-1}function Gf(e){return e.match(Uf)&&!e.match(ba)}function Yf(e){return Vf.test(e)}function qf(e){return!Ti(e)&&(Gf(e)||Yf(e))}const Kf=/[A-Z\xc0-\xd6\xd8-\xde]?[a-z\xdf-\xf6\xf8-\xff]+(?:['’](?:d|ll|m|re|s|t|ve))?(?=[\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000]|[A-Z\xc0-\xd6\xd8-\xde]|$)|(?:[A-Z\xc0-\xd6\xd8-\xde]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])+(?:['’](?:D|LL|M|RE|S|T|VE))?(?=[\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000]|[A-Z\xc0-\xd6\xd8-\xde](?:[a-z\xdf-\xf6\xf8-\xff]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])|$)|[A-Z\xc0-\xd6\xd8-\xde]?(?:[a-z\xdf-\xf6\xf8-\xff]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])+(?:['’](?:d|ll|m|re|s|t|ve))?|[A-Z\xc0-\xd6\xd8-\xde]+(?:['’](?:D|LL|M|RE|S|T|VE))?|\d*(?:1ST|2ND|3RD|(?![123])\dTH)(?=\b|[a-z_])|\d*(?:1st|2nd|3rd|(?![123])\dth)(?=\b|[A-Z_])|\d+|(?:[\u2700-\u27bf]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff])[\ufe0e\ufe0f]?(?:[\u0300-\u036f\ufe20-\ufe2f\u20d0-\u20ff]|\ud83c[\udffb-\udfff])?(?:\u200d(?:[^\ud800-\udfff]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff])[\ufe0e\ufe0f]?(?:[\u0300-\u036f\ufe20-\ufe2f\u20d0-\u20ff]|\ud83c[\udffb-\udfff])?)*/g,Zr=e=>e.match(Kf)||[],Qr=e=>e[0].toUpperCase()+e.slice(1),_i=(e,t)=>Zr(e).join(t).toLowerCase(),Ea=e=>Zr(e).reduce((t,r)=>`${t}${t?r[0].toUpperCase()+r.slice(1).toLowerCase():r.toLowerCase()}`,"");var Ei={words:Zr,upperFirst:Qr,camelCase:Ea,pascalCase:e=>Qr(Ea(e)),snakeCase:e=>_i(e,"_"),kebabCase:e=>_i(e,"-"),sentenceCase:e=>Qr(_i(e," ")),titleCase:e=>Zr(e).map(Qr).join(" ")},Si={exports:{}};Si.exports=function(e){return Sa(Xf(e),e)},Si.exports.array=Sa;function Sa(e,t){var r=e.length,n=new Array(r),i={},o=r,a=Jf(t),s=Zf(e);for(t.forEach(function(u){if(!s.has(u[0])||!s.has(u[1]))throw new Error("Unknown node. There is an unknown node in the supplied edges.")});o--;)i[o]||l(e[o],o,new Set);return n;function l(u,f,c){if(c.has(u)){var p;try{p=", node was:"+JSON.stringify(u)}catch{p=""}throw new Error("Cyclic dependency"+p)}if(!s.has(u))throw new Error("Found unknown node. Make sure to provided all involved nodes. Unknown node: "+JSON.stringify(u));if(!i[f]){i[f]=!0;var y=a.get(u)||new Set;if(y=Array.from(y),f=y.length){c.add(u);do{var g=y[--f];l(g,s.get(g),c)}while(f);c.delete(u)}n[--r]=u}}}function Xf(e){for(var t=new Set,r=0,n=e.length;r<n;r++){var i=e[r];t.add(i[0]),t.add(i[1])}return Array.from(t)}function Jf(e){for(var t=new Map,r=0,n=e.length;r<n;r++){var i=e[r];t.has(i[0])||t.set(i[0],new Set),t.has(i[1])||t.set(i[1],new Set),t.get(i[0]).add(i[1])}return t}function Zf(e){for(var t=new Map,r=0,n=e.length;r<n;r++)t.set(e[r],r);return t}var Qf=Si.exports;const ed=yt(Qf),td=Object.prototype.toString,rd=Error.prototype.toString,nd=RegExp.prototype.toString,id=typeof Symbol<"u"?Symbol.prototype.toString:()=>"",od=/^Symbol\((.*)\)(.*)$/;function ad(e){return e!=+e?"NaN":e===0&&1/e<0?"-0":""+e}function Ca(e,t=!1){if(e==null||e===!0||e===!1)return""+e;const r=typeof e;if(r==="number")return ad(e);if(r==="string")return t?`"${e}"`:e;if(r==="function")return"[Function "+(e.name||"anonymous")+"]";if(r==="symbol")return id.call(e).replace(od,"Symbol($1)");const n=td.call(e).slice(8,-1);return n==="Date"?isNaN(e.getTime())?""+e:e.toISOString(e):n==="Error"||e instanceof Error?"["+rd.call(e)+"]":n==="RegExp"?nd.call(e):null}function dt(e,t){let r=Ca(e,t);return r!==null?r:JSON.stringify(e,function(n,i){let o=Ca(this[n],t);return o!==null?o:i},2)}function wa(e){return e==null?[]:[].concat(e)}let Aa,Oa,ka,sd=/\$\{\s*(\w+)\s*\}/g;Aa=Symbol.toStringTag;class Pa{constructor(t,r,n,i){this.name=void 0,this.message=void 0,this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=void 0,this.inner=void 0,this[Aa]="Error",this.name="ValidationError",this.value=r,this.path=n,this.type=i,this.errors=[],this.inner=[],wa(t).forEach(o=>{if(Fe.isError(o)){this.errors.push(...o.errors);const a=o.inner.length?o.inner:[o];this.inner.push(...a)}else this.errors.push(o)}),this.message=this.errors.length>1?`${this.errors.length} errors occurred`:this.errors[0]}}Oa=Symbol.hasInstance,ka=Symbol.toStringTag;class Fe extends Error{static formatError(t,r){const n=r.label||r.path||"this";return n!==r.path&&(r=Object.assign({},r,{path:n})),typeof t=="string"?t.replace(sd,(i,o)=>dt(r[o])):typeof t=="function"?t(r):t}static isError(t){return t&&t.name==="ValidationError"}constructor(t,r,n,i,o){const a=new Pa(t,r,n,i);if(o)return a;super(),this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=[],this.inner=[],this[ka]="Error",this.name=a.name,this.message=a.message,this.type=a.type,this.value=a.value,this.path=a.path,this.errors=a.errors,this.inner=a.inner,Error.captureStackTrace&&Error.captureStackTrace(this,Fe)}static[Oa](t){return Pa[Symbol.hasInstance](t)||super[Symbol.hasInstance](t)}}let pt={default:"${path} is invalid",required:"${path} is a required field",defined:"${path} must be defined",notNull:"${path} cannot be null",oneOf:"${path} must be one of the following values: ${values}",notOneOf:"${path} must not be one of the following values: ${values}",notType:({path:e,type:t,value:r,originalValue:n})=>{const i=n!=null&&n!==r?` (cast from the value \`${dt(n,!0)}\`).`:".";return t!=="mixed"?`${e} must be a \`${t}\` type, but the final value was: \`${dt(r,!0)}\``+i:`${e} must match the configured type. The validated value was: \`${dt(r,!0)}\``+i}},Ye={length:"${path} must be exactly ${length} characters",min:"${path} must be at least ${min} characters",max:"${path} must be at most ${max} characters",matches:'${path} must match the following: "${regex}"',email:"${path} must be a valid email",url:"${path} must be a valid URL",uuid:"${path} must be a valid UUID",datetime:"${path} must be a valid ISO date-time",datetime_precision:"${path} must be a valid ISO date-time with a sub-second precision of exactly ${precision} digits",datetime_offset:'${path} must be a valid ISO date-time with UTC "Z" timezone',trim:"${path} must be a trimmed string",lowercase:"${path} must be a lowercase string",uppercase:"${path} must be a upper case string"},Ot={min:"${path} must be greater than or equal to ${min}",max:"${path} must be less than or equal to ${max}",lessThan:"${path} must be less than ${less}",moreThan:"${path} must be greater than ${more}",positive:"${path} must be a positive number",negative:"${path} must be a negative number",integer:"${path} must be an integer"},Ci={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"},wi={isValue:"${path} field must be ${value}"},Ai={noUnknown:"${path} field has unspecified keys: ${unknown}"},en={min:"${path} field must have at least ${min} items",max:"${path} field must have less than or equal to ${max} items",length:"${path} must have ${length} items"},ja={notType:e=>{const{path:t,value:r,spec:n}=e,i=n.types.length;if(Array.isArray(r)){if(r.length<i)return`${t} tuple value has too few items, expected a length of ${i} but got ${r.length} for value: \`${dt(r,!0)}\``;if(r.length>i)return`${t} tuple value has too many items, expected a length of ${i} but got ${r.length} for value: \`${dt(r,!0)}\``}return Fe.formatError(pt.notType,e)}};var Ia=Object.assign(Object.create(null),{mixed:pt,string:Ye,number:Ot,date:Ci,object:Ai,array:en,boolean:wi,tuple:ja});const Bt=e=>e&&e.__isYupSchema__;class tn{static fromOptions(t,r){if(!r.then&&!r.otherwise)throw new TypeError("either `then:` or `otherwise:` is required for `when()` conditions");let{is:n,then:i,otherwise:o}=r,a=typeof n=="function"?n:(...s)=>s.every(l=>l===n);return new tn(t,(s,l)=>{var u;let f=a(...s)?i:o;return(u=f==null?void 0:f(l))!=null?u:l})}constructor(t,r){this.fn=void 0,this.refs=t,this.refs=t,this.fn=r}resolve(t,r){let n=this.refs.map(o=>o.getValue(r==null?void 0:r.value,r==null?void 0:r.parent,r==null?void 0:r.context)),i=this.fn(n,t,r);if(i===void 0||i===t)return t;if(!Bt(i))throw new TypeError("conditions must return a schema object");return i.resolve(r)}}const rn={context:"$",value:"."};function ld(e,t){return new kt(e,t)}class kt{constructor(t,r={}){if(this.key=void 0,this.isContext=void 0,this.isValue=void 0,this.isSibling=void 0,this.path=void 0,this.getter=void 0,this.map=void 0,typeof t!="string")throw new TypeError("ref must be a string, got: "+t);if(this.key=t.trim(),t==="")throw new TypeError("ref must be a non-empty string");this.isContext=this.key[0]===rn.context,this.isValue=this.key[0]===rn.value,this.isSibling=!this.isContext&&!this.isValue;let n=this.isContext?rn.context:this.isValue?rn.value:"";this.path=this.key.slice(n.length),this.getter=this.path&&zt.getter(this.path,!0),this.map=r.map}getValue(t,r,n){let i=this.isContext?n:this.isValue?t:r;return this.getter&&(i=this.getter(i||{})),this.map&&(i=this.map(i)),i}cast(t,r){return this.getValue(t,r==null?void 0:r.parent,r==null?void 0:r.context)}resolve(){return this}describe(){return{type:"ref",key:this.key}}toString(){return`Ref(${this.key})`}static isRef(t){return t&&t.__isYupRef}}kt.prototype.__isYupRef=!0;const st=e=>e==null;function Jt(e){function t({value:r,path:n="",options:i,originalValue:o,schema:a},s,l){const{name:u,test:f,params:c,message:p,skipAbsent:y}=e;let{parent:g,context:m,abortEarly:T=a.spec.abortEarly,disableStackTrace:j=a.spec.disableStackTrace}=i;function F(A){return kt.isRef(A)?A.getValue(r,g,m):A}function D(A={}){const U=Object.assign({value:r,originalValue:o,label:a.spec.label,path:A.path||n,spec:a.spec,disableStackTrace:A.disableStackTrace||j},c,A.params);for(const te of Object.keys(U))U[te]=F(U[te]);const H=new Fe(Fe.formatError(A.message||p,U),r,U.path,A.type||u,U.disableStackTrace);return H.params=U,H}const O=T?s:l;let E={path:n,parent:g,type:u,from:i.from,createError:D,resolve:F,options:i,originalValue:o,schema:a};const M=A=>{Fe.isError(A)?O(A):A?l(null):O(D())},Y=A=>{Fe.isError(A)?O(A):s(A)};if(y&&st(r))return M(!0);let ie;try{var h;if(ie=f.call(E,r,E),typeof((h=ie)==null?void 0:h.then)=="function"){if(i.sync)throw new Error(`Validation test of type: "${E.type}" returned a Promise during a synchronous validate. This test will finish after the validate call has returned`);return Promise.resolve(ie).then(M,Y)}}catch(A){Y(A);return}M(ie)}return t.OPTIONS=e,t}function Oi(e,t,r,n=r){let i,o,a;return t?(zt.forEach(t,(s,l,u)=>{let f=l?s.slice(1,s.length-1):s;e=e.resolve({context:n,parent:i,value:r});let c=e.type==="tuple",p=u?parseInt(f,10):0;if(e.innerType||c){if(c&&!u)throw new Error(`Yup.reach cannot implicitly index into a tuple type. the path part "${a}" must contain an index to the tuple element, e.g. "${a}[0]"`);if(r&&p>=r.length)throw new Error(`Yup.reach cannot resolve an array item at index: ${s}, in the path: ${t}. because there is no value at that index. `);i=r,r=r&&r[p],e=c?e.spec.types[p]:e.innerType}if(!u){if(!e.fields||!e.fields[f])throw new Error(`The schema does not contain the path: ${t}. (failed at: ${a} which is a type: "${e.type}")`);i=r,r=r&&r[f],e=e.fields[f]}o=f,a=l?"["+s+"]":"."+s}),{schema:e,parent:i,parentPath:o}):{parent:i,parentPath:t,schema:e}}function ud(e,t,r,n){return Oi(e,t,r,n).schema}class nn extends Set{describe(){const t=[];for(const r of this.values())t.push(kt.isRef(r)?r.describe():r);return t}resolveAll(t){let r=[];for(const n of this.values())r.push(t(n));return r}clone(){return new nn(this.values())}merge(t,r){const n=this.clone();return t.forEach(i=>n.add(i)),r.forEach(i=>n.delete(i)),n}}function Zt(e,t=new Map){if(Bt(e)||!e||typeof e!="object")return e;if(t.has(e))return t.get(e);let r;if(e instanceof Date)r=new Date(e.getTime()),t.set(e,r);else if(e instanceof RegExp)r=new RegExp(e),t.set(e,r);else if(Array.isArray(e)){r=new Array(e.length),t.set(e,r);for(let n=0;n<e.length;n++)r[n]=Zt(e[n],t)}else if(e instanceof Map){r=new Map,t.set(e,r);for(const[n,i]of e.entries())r.set(n,Zt(i,t))}else if(e instanceof Set){r=new Set,t.set(e,r);for(const n of e)r.add(Zt(n,t))}else if(e instanceof Object){r={},t.set(e,r);for(const[n,i]of Object.entries(e))r[n]=Zt(i,t)}else throw Error(`Unable to clone ${e}`);return r}class Le{constructor(t){this.type=void 0,this.deps=[],this.tests=void 0,this.transforms=void 0,this.conditions=[],this._mutate=void 0,this.internalTests={},this._whitelist=new nn,this._blacklist=new nn,this.exclusiveTests=Object.create(null),this._typeCheck=void 0,this.spec=void 0,this.tests=[],this.transforms=[],this.withMutation(()=>{this.typeError(pt.notType)}),this.type=t.type,this._typeCheck=t.check,this.spec=Object.assign({strip:!1,strict:!1,abortEarly:!0,recursive:!0,disableStackTrace:!1,nullable:!1,optional:!0,coerce:!0},t==null?void 0:t.spec),this.withMutation(r=>{r.nonNullable()})}get _type(){return this.type}clone(t){if(this._mutate)return t&&Object.assign(this.spec,t),this;const r=Object.create(Object.getPrototypeOf(this));return r.type=this.type,r._typeCheck=this._typeCheck,r._whitelist=this._whitelist.clone(),r._blacklist=this._blacklist.clone(),r.internalTests=Object.assign({},this.internalTests),r.exclusiveTests=Object.assign({},this.exclusiveTests),r.deps=[...this.deps],r.conditions=[...this.conditions],r.tests=[...this.tests],r.transforms=[...this.transforms],r.spec=Zt(Object.assign({},this.spec,t)),r}label(t){let r=this.clone();return r.spec.label=t,r}meta(...t){if(t.length===0)return this.spec.meta;let r=this.clone();return r.spec.meta=Object.assign(r.spec.meta||{},t[0]),r}withMutation(t){let r=this._mutate;this._mutate=!0;let n=t(this);return this._mutate=r,n}concat(t){if(!t||t===this)return this;if(t.type!==this.type&&this.type!=="mixed")throw new TypeError(`You cannot \`concat()\` schema's of different types: ${this.type} and ${t.type}`);let r=this,n=t.clone();const i=Object.assign({},r.spec,n.spec);return n.spec=i,n.internalTests=Object.assign({},r.internalTests,n.internalTests),n._whitelist=r._whitelist.merge(t._whitelist,t._blacklist),n._blacklist=r._blacklist.merge(t._blacklist,t._whitelist),n.tests=r.tests,n.exclusiveTests=r.exclusiveTests,n.withMutation(o=>{t.tests.forEach(a=>{o.test(a.OPTIONS)})}),n.transforms=[...r.transforms,...n.transforms],n}isType(t){return t==null?!!(this.spec.nullable&&t===null||this.spec.optional&&t===void 0):this._typeCheck(t)}resolve(t){let r=this;if(r.conditions.length){let n=r.conditions;r=r.clone(),r.conditions=[],r=n.reduce((i,o)=>o.resolve(i,t),r),r=r.resolve(t)}return r}resolveOptions(t){var r,n,i,o;return Object.assign({},t,{from:t.from||[],strict:(r=t.strict)!=null?r:this.spec.strict,abortEarly:(n=t.abortEarly)!=null?n:this.spec.abortEarly,recursive:(i=t.recursive)!=null?i:this.spec.recursive,disableStackTrace:(o=t.disableStackTrace)!=null?o:this.spec.disableStackTrace})}cast(t,r={}){let n=this.resolve(Object.assign({value:t},r)),i=r.assert==="ignore-optionality",o=n._cast(t,r);if(r.assert!==!1&&!n.isType(o)){if(i&&st(o))return o;let a=dt(t),s=dt(o);throw new TypeError(`The value of ${r.path||"field"} could not be cast to a value that satisfies the schema type: "${n.type}".
|
|
31
31
|
|
|
32
32
|
attempted value: ${a}
|
|
33
|
-
`+(s!==a?`result of cast: ${s}`:""))}return o}_cast(t,r){let n=t===void 0?t:this.transforms.reduce((i,o)=>o.call(this,i,t,this),t);return n===void 0&&(n=this.getDefault(r)),n}_validate(t,r={},n,i){let{path:o,originalValue:a=t,strict:s=this.spec.strict}=r,l=t;s||(l=this._cast(l,Object.assign({assert:!1},r)));let u=[];for(let f of Object.values(this.internalTests))f&&u.push(f);this.runTests({path:o,value:l,originalValue:a,options:r,tests:u},n,f=>{if(f.length)return i(f,l);this.runTests({path:o,value:l,originalValue:a,options:r,tests:this.tests},n,i)})}runTests(t,r,n){let i=!1,{tests:o,value:a,originalValue:s,path:l,options:u}=t,f=y=>{i||(i=!0,r(y,a))},c=y=>{i||(i=!0,n(y,a))},p=o.length,v=[];if(!p)return c([]);let m={value:a,originalValue:s,path:l,options:u,schema:this};for(let y=0;y<o.length;y++){const T=o[y];T(m,f,function(F){F&&(Array.isArray(F)?v.push(...F):v.push(F)),--p<=0&&c(v)})}}asNestedTest({key:t,index:r,parent:n,parentPath:i,originalParent:o,options:a}){const s=t??r;if(s==null)throw TypeError("Must include `key` or `index` for nested validations");const l=typeof s=="number";let u=n[s];const f=Object.assign({},a,{strict:!0,parent:n,value:u,originalValue:o[s],key:void 0,[l?"index":"key"]:s,path:l||s.includes(".")?`${i||""}[${l?s:`"${s}"`}]`:(i?`${i}.`:"")+t});return(c,p,v)=>this.resolve(f)._validate(u,f,p,v)}validate(t,r){var n;let i=this.resolve(Object.assign({},r,{value:t})),o=(n=r==null?void 0:r.disableStackTrace)!=null?n:i.spec.disableStackTrace;return new Promise((a,s)=>i._validate(t,r,(l,u)=>{Fe.isError(l)&&(l.value=u),s(l)},(l,u)=>{l.length?s(new Fe(l,u,void 0,void 0,o)):a(u)}))}validateSync(t,r){var n;let i=this.resolve(Object.assign({},r,{value:t})),o,a=(n=r==null?void 0:r.disableStackTrace)!=null?n:i.spec.disableStackTrace;return i._validate(t,Object.assign({},r,{sync:!0}),(s,l)=>{throw Fe.isError(s)&&(s.value=l),s},(s,l)=>{if(s.length)throw new Fe(s,t,void 0,void 0,a);o=l}),o}isValid(t,r){return this.validate(t,r).then(()=>!0,n=>{if(Fe.isError(n))return!1;throw n})}isValidSync(t,r){try{return this.validateSync(t,r),!0}catch(n){if(Fe.isError(n))return!1;throw n}}_getDefault(t){let r=this.spec.default;return r==null?r:typeof r=="function"?r.call(this,t):Zt(r)}getDefault(t){return this.resolve(t||{})._getDefault(t)}default(t){return arguments.length===0?this._getDefault():this.clone({default:t})}strict(t=!0){return this.clone({strict:t})}nullability(t,r){const n=this.clone({nullable:t});return n.internalTests.nullable=Jt({message:r,name:"nullable",test(i){return i===null?this.schema.spec.nullable:!0}}),n}optionality(t,r){const n=this.clone({optional:t});return n.internalTests.optionality=Jt({message:r,name:"optionality",test(i){return i===void 0?this.schema.spec.optional:!0}}),n}optional(){return this.optionality(!0)}defined(t=pt.defined){return this.optionality(!1,t)}nullable(){return this.nullability(!0)}nonNullable(t=pt.notNull){return this.nullability(!1,t)}required(t=pt.required){return this.clone().withMutation(r=>r.nonNullable(t).defined(t))}notRequired(){return this.clone().withMutation(t=>t.nullable().optional())}transform(t){let r=this.clone();return r.transforms.push(t),r}test(...t){let r;if(t.length===1?typeof t[0]=="function"?r={test:t[0]}:r=t[0]:t.length===2?r={name:t[0],test:t[1]}:r={name:t[0],message:t[1],test:t[2]},r.message===void 0&&(r.message=pt.default),typeof r.test!="function")throw new TypeError("`test` is a required parameters");let n=this.clone(),i=Jt(r),o=r.exclusive||r.name&&n.exclusiveTests[r.name]===!0;if(r.exclusive&&!r.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return r.name&&(n.exclusiveTests[r.name]=!!r.exclusive),n.tests=n.tests.filter(a=>!(a.OPTIONS.name===r.name&&(o||a.OPTIONS.test===i.OPTIONS.test))),n.tests.push(i),n}when(t,r){!Array.isArray(t)&&typeof t!="string"&&(r=t,t=".");let n=this.clone(),i=wa(t).map(o=>new kt(o));return i.forEach(o=>{o.isSibling&&n.deps.push(o.key)}),n.conditions.push(typeof r=="function"?new tn(i,r):tn.fromOptions(i,r)),n}typeError(t){let r=this.clone();return r.internalTests.typeError=Jt({message:t,name:"typeError",skipAbsent:!0,test(n){return this.schema._typeCheck(n)?!0:this.createError({params:{type:this.schema.type}})}}),r}oneOf(t,r=pt.oneOf){let n=this.clone();return t.forEach(i=>{n._whitelist.add(i),n._blacklist.delete(i)}),n.internalTests.whiteList=Jt({message:r,name:"oneOf",skipAbsent:!0,test(i){let o=this.schema._whitelist,a=o.resolveAll(this.resolve);return a.includes(i)?!0:this.createError({params:{values:Array.from(o).join(", "),resolved:a}})}}),n}notOneOf(t,r=pt.notOneOf){let n=this.clone();return t.forEach(i=>{n._blacklist.add(i),n._whitelist.delete(i)}),n.internalTests.blacklist=Jt({message:r,name:"notOneOf",test(i){let o=this.schema._blacklist,a=o.resolveAll(this.resolve);return a.includes(i)?this.createError({params:{values:Array.from(o).join(", "),resolved:a}}):!0}}),n}strip(t=!0){let r=this.clone();return r.spec.strip=t,r}describe(t){const r=(t?this.resolve(t):this).clone(),{label:n,meta:i,optional:o,nullable:a}=r.spec;return{meta:i,label:n,optional:o,nullable:a,default:r.getDefault(t),type:r.type,oneOf:r._whitelist.describe(),notOneOf:r._blacklist.describe(),tests:r.tests.map(l=>({name:l.OPTIONS.name,params:l.OPTIONS.params})).filter((l,u,f)=>f.findIndex(c=>c.name===l.name)===u)}}}Le.prototype.__isYupSchema__=!0;for(const e of["validate","validateSync"])Le.prototype[`${e}At`]=function(t,r,n={}){const{parent:i,parentPath:o,schema:a}=Oi(this,t,r,n.context);return a[e](i&&i[o],Object.assign({},n,{parent:i,path:t}))};for(const e of["equals","is"])Le.prototype[e]=Le.prototype.oneOf;for(const e of["not","nope"])Le.prototype[e]=Le.prototype.notOneOf;const ud=()=>!0;function on(e){return new ki(e)}class ki extends Le{constructor(t){super(typeof t=="function"?{type:"mixed",check:t}:Object.assign({type:"mixed",check:ud},t))}}on.prototype=ki.prototype;function Pi(){return new ji}class ji extends Le{constructor(){super({type:"boolean",check(t){return t instanceof Boolean&&(t=t.valueOf()),typeof t=="boolean"}}),this.withMutation(()=>{this.transform((t,r,n)=>{if(n.spec.coerce&&!n.isType(t)){if(/^(true|1)$/i.test(String(t)))return!0;if(/^(false|0)$/i.test(String(t)))return!1}return t})})}isTrue(t=wi.isValue){return this.test({message:t,name:"is-value",exclusive:!0,params:{value:"true"},test(r){return st(r)||r===!0}})}isFalse(t=wi.isValue){return this.test({message:t,name:"is-value",exclusive:!0,params:{value:"false"},test(r){return st(r)||r===!1}})}default(t){return super.default(t)}defined(t){return super.defined(t)}optional(){return super.optional()}required(t){return super.required(t)}notRequired(){return super.notRequired()}nullable(){return super.nullable()}nonNullable(t){return super.nonNullable(t)}strip(t){return super.strip(t)}}Pi.prototype=ji.prototype;const cd=/^(\d{4}|[+-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,.](\d{1,}))?)?(?:(Z)|([+-])(\d{2})(?::?(\d{2}))?)?)?$/;function fd(e){const t=Ii(e);if(!t)return Date.parse?Date.parse(e):Number.NaN;if(t.z===void 0&&t.plusMinus===void 0)return new Date(t.year,t.month,t.day,t.hour,t.minute,t.second,t.millisecond).valueOf();let r=0;return t.z!=="Z"&&t.plusMinus!==void 0&&(r=t.hourOffset*60+t.minuteOffset,t.plusMinus==="+"&&(r=0-r)),Date.UTC(t.year,t.month,t.day,t.hour,t.minute+r,t.second,t.millisecond)}function Ii(e){var t,r;const n=cd.exec(e);return n?{year:vt(n[1]),month:vt(n[2],1)-1,day:vt(n[3],1),hour:vt(n[4]),minute:vt(n[5]),second:vt(n[6]),millisecond:n[7]?vt(n[7].substring(0,3)):0,precision:(t=(r=n[7])==null?void 0:r.length)!=null?t:void 0,z:n[8]||void 0,plusMinus:n[9]||void 0,hourOffset:vt(n[10]),minuteOffset:vt(n[11])}:null}function vt(e,t=0){return Number(e)||t}let dd=/^[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,pd=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,hd=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,md="^\\d{4}-\\d{2}-\\d{2}",gd="\\d{2}:\\d{2}:\\d{2}",yd="(([+-]\\d{2}(:?\\d{2})?)|Z)",vd=new RegExp(`${md}T${gd}(\\.\\d+)?${yd}$`),bd=e=>st(e)||e===e.trim(),xd={}.toString();function an(){return new $i}class $i extends Le{constructor(){super({type:"string",check(t){return t instanceof String&&(t=t.valueOf()),typeof t=="string"}}),this.withMutation(()=>{this.transform((t,r,n)=>{if(!n.spec.coerce||n.isType(t)||Array.isArray(t))return t;const i=t!=null&&t.toString?t.toString():t;return i===xd?t:i})})}required(t){return super.required(t).withMutation(r=>r.test({message:t||pt.required,name:"required",skipAbsent:!0,test:n=>!!n.length}))}notRequired(){return super.notRequired().withMutation(t=>(t.tests=t.tests.filter(r=>r.OPTIONS.name!=="required"),t))}length(t,r=Ye.length){return this.test({message:r,name:"length",exclusive:!0,params:{length:t},skipAbsent:!0,test(n){return n.length===this.resolve(t)}})}min(t,r=Ye.min){return this.test({message:r,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(n){return n.length>=this.resolve(t)}})}max(t,r=Ye.max){return this.test({name:"max",exclusive:!0,message:r,params:{max:t},skipAbsent:!0,test(n){return n.length<=this.resolve(t)}})}matches(t,r){let n=!1,i,o;return r&&(typeof r=="object"?{excludeEmptyString:n=!1,message:i,name:o}=r:i=r),this.test({name:o||"matches",message:i||Ye.matches,params:{regex:t},skipAbsent:!0,test:a=>a===""&&n||a.search(t)!==-1})}email(t=Ye.email){return this.matches(dd,{name:"email",message:t,excludeEmptyString:!0})}url(t=Ye.url){return this.matches(pd,{name:"url",message:t,excludeEmptyString:!0})}uuid(t=Ye.uuid){return this.matches(hd,{name:"uuid",message:t,excludeEmptyString:!1})}datetime(t){let r="",n,i;return t&&(typeof t=="object"?{message:r="",allowOffset:n=!1,precision:i=void 0}=t:r=t),this.matches(vd,{name:"datetime",message:r||Ye.datetime,excludeEmptyString:!0}).test({name:"datetime_offset",message:r||Ye.datetime_offset,params:{allowOffset:n},skipAbsent:!0,test:o=>{if(!o||n)return!0;const a=Ii(o);return a?!!a.z:!1}}).test({name:"datetime_precision",message:r||Ye.datetime_precision,params:{precision:i},skipAbsent:!0,test:o=>{if(!o||i==null)return!0;const a=Ii(o);return a?a.precision===i:!1}})}ensure(){return this.default("").transform(t=>t===null?"":t)}trim(t=Ye.trim){return this.transform(r=>r!=null?r.trim():r).test({message:t,name:"trim",test:bd})}lowercase(t=Ye.lowercase){return this.transform(r=>st(r)?r:r.toLowerCase()).test({message:t,name:"string_case",exclusive:!0,skipAbsent:!0,test:r=>st(r)||r===r.toLowerCase()})}uppercase(t=Ye.uppercase){return this.transform(r=>st(r)?r:r.toUpperCase()).test({message:t,name:"string_case",exclusive:!0,skipAbsent:!0,test:r=>st(r)||r===r.toUpperCase()})}}an.prototype=$i.prototype;let Td=e=>e!=+e;function $a(){return new Di}class Di extends Le{constructor(){super({type:"number",check(t){return t instanceof Number&&(t=t.valueOf()),typeof t=="number"&&!Td(t)}}),this.withMutation(()=>{this.transform((t,r,n)=>{if(!n.spec.coerce)return t;let i=t;if(typeof i=="string"){if(i=i.replace(/\s/g,""),i==="")return NaN;i=+i}return n.isType(i)||i===null?i:parseFloat(i)})})}min(t,r=Ot.min){return this.test({message:r,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(n){return n>=this.resolve(t)}})}max(t,r=Ot.max){return this.test({message:r,name:"max",exclusive:!0,params:{max:t},skipAbsent:!0,test(n){return n<=this.resolve(t)}})}lessThan(t,r=Ot.lessThan){return this.test({message:r,name:"max",exclusive:!0,params:{less:t},skipAbsent:!0,test(n){return n<this.resolve(t)}})}moreThan(t,r=Ot.moreThan){return this.test({message:r,name:"min",exclusive:!0,params:{more:t},skipAbsent:!0,test(n){return n>this.resolve(t)}})}positive(t=Ot.positive){return this.moreThan(0,t)}negative(t=Ot.negative){return this.lessThan(0,t)}integer(t=Ot.integer){return this.test({name:"integer",message:t,skipAbsent:!0,test:r=>Number.isInteger(r)})}truncate(){return this.transform(t=>st(t)?t:t|0)}round(t){var r;let n=["ceil","floor","round","trunc"];if(t=((r=t)==null?void 0:r.toLowerCase())||"round",t==="trunc")return this.truncate();if(n.indexOf(t.toLowerCase())===-1)throw new TypeError("Only valid options for round() are: "+n.join(", "));return this.transform(i=>st(i)?i:Math[t](i))}}$a.prototype=Di.prototype;let Da=new Date(""),_d=e=>Object.prototype.toString.call(e)==="[object Date]";function Mi(){return new Qt}class Qt extends Le{constructor(){super({type:"date",check(t){return _d(t)&&!isNaN(t.getTime())}}),this.withMutation(()=>{this.transform((t,r,n)=>!n.spec.coerce||n.isType(t)||t===null?t:(t=fd(t),isNaN(t)?Qt.INVALID_DATE:new Date(t)))})}prepareParam(t,r){let n;if(kt.isRef(t))n=t;else{let i=this.cast(t);if(!this._typeCheck(i))throw new TypeError(`\`${r}\` must be a Date or a value that can be \`cast()\` to a Date`);n=i}return n}min(t,r=Ci.min){let n=this.prepareParam(t,"min");return this.test({message:r,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(i){return i>=this.resolve(n)}})}max(t,r=Ci.max){let n=this.prepareParam(t,"max");return this.test({message:r,name:"max",exclusive:!0,params:{max:t},skipAbsent:!0,test(i){return i<=this.resolve(n)}})}}Qt.INVALID_DATE=Da,Mi.prototype=Qt.prototype,Mi.INVALID_DATE=Da;function Sd(e,t=[]){let r=[],n=new Set,i=new Set(t.map(([a,s])=>`${a}-${s}`));function o(a,s){let l=zt.split(a)[0];n.add(l),i.has(`${s}-${l}`)||r.push([s,l])}for(const a of Object.keys(e)){let s=e[a];n.add(a),kt.isRef(s)&&s.isSibling?o(s.path,a):Bt(s)&&"deps"in s&&s.deps.forEach(l=>o(l,a))}return Qf.array(Array.from(n),r).reverse()}function Ma(e,t){let r=1/0;return e.some((n,i)=>{var o;if((o=t.path)!=null&&o.includes(n))return r=i,!0}),r}function Ra(e){return(t,r)=>Ma(e,t)-Ma(e,r)}const Na=(e,t,r)=>{if(typeof e!="string")return e;let n=e;try{n=JSON.parse(e)}catch{}return r.isType(n)?n:e};function sn(e){if("fields"in e){const t={};for(const[r,n]of Object.entries(e.fields))t[r]=sn(n);return e.setFields(t)}if(e.type==="array"){const t=e.optional();return t.innerType&&(t.innerType=sn(t.innerType)),t}return e.type==="tuple"?e.optional().clone({types:e.spec.types.map(sn)}):"optional"in e?e.optional():e}const Ed=(e,t)=>{const r=[...zt.normalizePath(t)];if(r.length===1)return r[0]in e;let n=r.pop(),i=zt.getter(zt.join(r),!0)(e);return!!(i&&n in i)};let Fa=e=>Object.prototype.toString.call(e)==="[object Object]";function Cd(e,t){let r=Object.keys(e.fields);return Object.keys(t).filter(n=>r.indexOf(n)===-1)}const wd=Ra([]);function Er(e){return new Ri(e)}class Ri extends Le{constructor(t){super({type:"object",check(r){return Fa(r)||typeof r=="function"}}),this.fields=Object.create(null),this._sortErrors=wd,this._nodes=[],this._excludedEdges=[],this.withMutation(()=>{t&&this.shape(t)})}_cast(t,r={}){var n;let i=super._cast(t,r);if(i===void 0)return this.getDefault(r);if(!this._typeCheck(i))return i;let o=this.fields,a=(n=r.stripUnknown)!=null?n:this.spec.noUnknown,s=[].concat(this._nodes,Object.keys(i).filter(c=>!this._nodes.includes(c))),l={},u=Object.assign({},r,{parent:l,__validating:r.__validating||!1}),f=!1;for(const c of s){let p=o[c],v=c in i;if(p){let m,y=i[c];u.path=(r.path?`${r.path}.`:"")+c,p=p.resolve({value:y,context:r.context,parent:l});let T=p instanceof Le?p.spec:void 0,j=T==null?void 0:T.strict;if(T!=null&&T.strip){f=f||c in i;continue}m=!r.__validating||!j?p.cast(i[c],u):i[c],m!==void 0&&(l[c]=m)}else v&&!a&&(l[c]=i[c]);(v!==c in l||l[c]!==i[c])&&(f=!0)}return f?l:i}_validate(t,r={},n,i){let{from:o=[],originalValue:a=t,recursive:s=this.spec.recursive}=r;r.from=[{schema:this,value:a},...o],r.__validating=!0,r.originalValue=a,super._validate(t,r,n,(l,u)=>{if(!s||!Fa(u)){i(l,u);return}a=a||u;let f=[];for(let c of this._nodes){let p=this.fields[c];!p||kt.isRef(p)||f.push(p.asNestedTest({options:r,key:c,parent:u,parentPath:r.path,originalParent:a}))}this.runTests({tests:f,value:u,originalValue:a,options:r},n,c=>{i(c.sort(this._sortErrors).concat(l),u)})})}clone(t){const r=super.clone(t);return r.fields=Object.assign({},this.fields),r._nodes=this._nodes,r._excludedEdges=this._excludedEdges,r._sortErrors=this._sortErrors,r}concat(t){let r=super.concat(t),n=r.fields;for(let[i,o]of Object.entries(this.fields)){const a=n[i];n[i]=a===void 0?o:a}return r.withMutation(i=>i.setFields(n,[...this._excludedEdges,...t._excludedEdges]))}_getDefault(t){if("default"in this.spec)return super._getDefault(t);if(!this._nodes.length)return;let r={};return this._nodes.forEach(n=>{var i;const o=this.fields[n];let a=t;(i=a)!=null&&i.value&&(a=Object.assign({},a,{parent:a.value,value:a.value[n]})),r[n]=o&&"getDefault"in o?o.getDefault(a):void 0}),r}setFields(t,r){let n=this.clone();return n.fields=t,n._nodes=Sd(t,r),n._sortErrors=Ra(Object.keys(t)),r&&(n._excludedEdges=r),n}shape(t,r=[]){return this.clone().withMutation(n=>{let i=n._excludedEdges;return r.length&&(Array.isArray(r[0])||(r=[r]),i=[...n._excludedEdges,...r]),n.setFields(Object.assign(n.fields,t),i)})}partial(){const t={};for(const[r,n]of Object.entries(this.fields))t[r]="optional"in n&&n.optional instanceof Function?n.optional():n;return this.setFields(t)}deepPartial(){return sn(this)}pick(t){const r={};for(const n of t)this.fields[n]&&(r[n]=this.fields[n]);return this.setFields(r,this._excludedEdges.filter(([n,i])=>t.includes(n)&&t.includes(i)))}omit(t){const r=[];for(const n of Object.keys(this.fields))t.includes(n)||r.push(n);return this.pick(r)}from(t,r,n){let i=zt.getter(t,!0);return this.transform(o=>{if(!o)return o;let a=o;return Ed(o,t)&&(a=Object.assign({},o),n||delete a[t],a[r]=i(o)),a})}json(){return this.transform(Na)}noUnknown(t=!0,r=Ai.noUnknown){typeof t!="boolean"&&(r=t,t=!0);let n=this.test({name:"noUnknown",exclusive:!0,message:r,test(i){if(i==null)return!0;const o=Cd(this.schema,i);return!t||o.length===0||this.createError({params:{unknown:o.join(", ")}})}});return n.spec.noUnknown=t,n}unknown(t=!0,r=Ai.noUnknown){return this.noUnknown(!t,r)}transformKeys(t){return this.transform(r=>{if(!r)return r;const n={};for(const i of Object.keys(r))n[t(i)]=r[i];return n})}camelCase(){return this.transformKeys(Si.camelCase)}snakeCase(){return this.transformKeys(Si.snakeCase)}constantCase(){return this.transformKeys(t=>Si.snakeCase(t).toUpperCase())}describe(t){const r=(t?this.resolve(t):this).clone(),n=super.describe(t);n.fields={};for(const[o,a]of Object.entries(r.fields)){var i;let s=t;(i=s)!=null&&i.value&&(s=Object.assign({},s,{parent:s.value,value:s.value[o]})),n.fields[o]=a.describe(s)}return n}}Er.prototype=Ri.prototype;function Ni(e){return new Fi(e)}class Fi extends Le{constructor(t){super({type:"array",spec:{types:t},check(r){return Array.isArray(r)}}),this.innerType=void 0,this.innerType=t}_cast(t,r){const n=super._cast(t,r);if(!this._typeCheck(n)||!this.innerType)return n;let i=!1;const o=n.map((a,s)=>{const l=this.innerType.cast(a,Object.assign({},r,{path:`${r.path||""}[${s}]`}));return l!==a&&(i=!0),l});return i?o:n}_validate(t,r={},n,i){var o;let a=this.innerType,s=(o=r.recursive)!=null?o:this.spec.recursive;r.originalValue!=null&&r.originalValue,super._validate(t,r,n,(l,u)=>{var f;if(!s||!a||!this._typeCheck(u)){i(l,u);return}let c=new Array(u.length);for(let v=0;v<u.length;v++){var p;c[v]=a.asNestedTest({options:r,index:v,parent:u,parentPath:r.path,originalParent:(p=r.originalValue)!=null?p:t})}this.runTests({value:u,tests:c,originalValue:(f=r.originalValue)!=null?f:t,options:r},n,v=>i(v.concat(l),u))})}clone(t){const r=super.clone(t);return r.innerType=this.innerType,r}json(){return this.transform(Na)}concat(t){let r=super.concat(t);return r.innerType=this.innerType,t.innerType&&(r.innerType=r.innerType?r.innerType.concat(t.innerType):t.innerType),r}of(t){let r=this.clone();if(!Bt(t))throw new TypeError("`array.of()` sub-schema must be a valid yup schema not: "+dt(t));return r.innerType=t,r.spec=Object.assign({},r.spec,{types:t}),r}length(t,r=en.length){return this.test({message:r,name:"length",exclusive:!0,params:{length:t},skipAbsent:!0,test(n){return n.length===this.resolve(t)}})}min(t,r){return r=r||en.min,this.test({message:r,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(n){return n.length>=this.resolve(t)}})}max(t,r){return r=r||en.max,this.test({message:r,name:"max",exclusive:!0,params:{max:t},skipAbsent:!0,test(n){return n.length<=this.resolve(t)}})}ensure(){return this.default(()=>[]).transform((t,r)=>this._typeCheck(t)?t:r==null?[]:[].concat(r))}compact(t){let r=t?(n,i,o)=>!t(n,i,o):n=>!!n;return this.transform(n=>n!=null?n.filter(r):n)}describe(t){const r=(t?this.resolve(t):this).clone(),n=super.describe(t);if(r.innerType){var i;let o=t;(i=o)!=null&&i.value&&(o=Object.assign({},o,{parent:o.value,value:o.value[0]})),n.innerType=r.innerType.describe(o)}return n}}Ni.prototype=Fi.prototype;function La(e){return new Li(e)}class Li extends Le{constructor(t){super({type:"tuple",spec:{types:t},check(r){const n=this.spec.types;return Array.isArray(r)&&r.length===n.length}}),this.withMutation(()=>{this.typeError(ja.notType)})}_cast(t,r){const{types:n}=this.spec,i=super._cast(t,r);if(!this._typeCheck(i))return i;let o=!1;const a=n.map((s,l)=>{const u=s.cast(i[l],Object.assign({},r,{path:`${r.path||""}[${l}]`}));return u!==i[l]&&(o=!0),u});return o?a:i}_validate(t,r={},n,i){let o=this.spec.types;super._validate(t,r,n,(a,s)=>{var l;if(!this._typeCheck(s)){i(a,s);return}let u=[];for(let[c,p]of o.entries()){var f;u[c]=p.asNestedTest({options:r,index:c,parent:s,parentPath:r.path,originalParent:(f=r.originalValue)!=null?f:t})}this.runTests({value:s,tests:u,originalValue:(l=r.originalValue)!=null?l:t,options:r},n,c=>i(c.concat(a),s))})}describe(t){const r=(t?this.resolve(t):this).clone(),n=super.describe(t);return n.innerType=r.spec.types.map((i,o)=>{var a;let s=t;return(a=s)!=null&&a.value&&(s=Object.assign({},s,{parent:s.value,value:s.value[o]})),i.describe(s)}),n}}La.prototype=Li.prototype;function Ad(e){return new zi(e)}class zi{constructor(t){this.type="lazy",this.__isYupSchema__=!0,this.spec=void 0,this._resolve=(r,n={})=>{let i=this.builder(r,n);if(!Bt(i))throw new TypeError("lazy() functions must return a valid schema");return this.spec.optional&&(i=i.optional()),i.resolve(n)},this.builder=t,this.spec={meta:void 0,optional:!1}}clone(t){const r=new zi(this.builder);return r.spec=Object.assign({},this.spec,t),r}optionality(t){return this.clone({optional:t})}optional(){return this.optionality(!0)}resolve(t){return this._resolve(t.value,t)}cast(t,r){return this._resolve(t,r).cast(t,r)}asNestedTest(t){let{key:r,index:n,parent:i,options:o}=t,a=i[n??r];return this._resolve(a,Object.assign({},o,{value:a,parent:i})).asNestedTest(t)}validate(t,r){return this._resolve(t,r).validate(t,r)}validateSync(t,r){return this._resolve(t,r).validateSync(t,r)}validateAt(t,r,n){return this._resolve(r,n).validateAt(t,r,n)}validateSyncAt(t,r,n){return this._resolve(r,n).validateSyncAt(t,r,n)}isValid(t,r){return this._resolve(t,r).isValid(t,r)}isValidSync(t,r){return this._resolve(t,r).isValidSync(t,r)}describe(t){return t?this.resolve(t).describe(t):{type:"lazy",meta:this.spec.meta,label:void 0}}meta(...t){if(t.length===0)return this.spec.meta;let r=this.clone();return r.spec.meta=Object.assign(r.spec.meta||{},t[0]),r}}function Od(e){Object.keys(e).forEach(t=>{Object.keys(e[t]).forEach(r=>{Ia[t][r]=e[t][r]})})}function kd(e,t,r){if(!e||!Bt(e.prototype))throw new TypeError("You must provide a yup schema constructor function");if(typeof t!="string")throw new TypeError("A Method name must be provided");if(typeof r!="function")throw new TypeError("Method function must be provided");e.prototype[t]=r}const za=Object.freeze(Object.defineProperty({__proto__:null,ArraySchema:Fi,BooleanSchema:ji,DateSchema:Qt,MixedSchema:ki,NumberSchema:Di,ObjectSchema:Ri,Schema:Le,StringSchema:$i,TupleSchema:Li,ValidationError:Fe,addMethod:kd,array:Ni,bool:Pi,boolean:Pi,date:Mi,defaultLocale:Ia,getIn:Oi,isSchema:Bt,lazy:Ad,mixed:on,number:$a,object:Er,printValue:dt,reach:ld,ref:sd,setLocale:Od,string:an,tuple:La},Symbol.toStringTag,{value:"Module"})),Ba=e=>{const t=e.reduce((r,n)=>{let{name:i,required:o,type:a}=n;switch(a){case"RelatedList":a="array";break;case"Related":a="object";break;case"Integer":case"Float":a="number";break;case"Geometry":case"Raw":a="mixed";break;default:a="string"}let s;try{o?s=za[a]().typeError(`Field must be of type ${a}`).required("Field is required"):s=za[a]().typeError(`Field must be of type ${a}`).nullable(!0)}catch(l){console.log(l)}return r[i]=s,r},{});return Er().shape(t)};function Ua({path:e,autoInvoke:t=!0,clearDataOnRefetch:r=!1}){const{fetchPath:n,options:i}=_.useMemo(()=>ze({path:$e(e,"_info"),method:"GET"}),[e]),{data:o,loading:a,refetch:s,error:l}=Xr(n,{autoInvoke:t,clearDataOnRefetch:r,...i});return{info:_.useMemo(()=>o?{...o,add:{columns:o.add_columns,title:o.add_title,schema:Ba(o.add_columns),defaultValues:va(o.add_columns)},edit:{columns:o.edit_columns,title:o.edit_title,schema:Ba(o.edit_columns),defaultValues:va(o.edit_columns)}}:null,[o]),loading:a,refetch:s,error:l}}const Va={user:null,loading:!0,error:null};function Pd(e,t){switch(t.type){case"initCall":return{...Va,user:e.user};case"setUser":return{...e,user:t.payload,error:null};case"setError":return{...e,loading:!1,error:t.payload};case"setLoading":return{...e,loading:t.payload};default:return e}}function jd(e){const[t,r]=_.useReducer(Pd,Va),{user:n,refetch:i,loading:o}=ga({path:e});_.useEffect(()=>{r({type:"setLoading",payload:o})},[o]),_.useEffect(()=>{r({type:"setUser",payload:n})},[n]);const a=_.useCallback(async({username:c,password:p})=>{r({type:"initCall"});try{const v=new FormData;v.append("username",c),v.append("password",p);const{fetchPath:m,options:y}=ze({path:$e(e,"auth/login"),method:"POST"}),T=await fetch(m,{...y,headers:{"Content-Type":"application/x-www-form-urlencoded"},body:new URLSearchParams(v)});T.ok||(T.status===400?r({type:"setError",payload:"Username or password wrong."}):r({type:"setError",payload:"Couldn't sign in user"})),i()}catch(v){console.error("signin error",v),r({type:"setError",payload:"Failed to fetch"})}},[e,i]),s=_.useCallback(async()=>{r({type:"initCall"});try{const{fetchPath:c,options:p}=ze({path:$e(e,"auth/logout"),method:"POST"});(await fetch(c,p)).ok||r({type:"setError",payload:"Couldn't sign out user"}),r({type:"setUser",payload:null})}catch(c){console.error("signout error",c),r({type:"setError",payload:"Failed to fetch"})}finally{r({type:"setLoading",payload:!1})}},[e]),l=_.useCallback(async c=>{r({type:"initCall"});try{const{fetchPath:p,options:v}=ze({path:$e(e,"auth/user"),method:"PUT",body:c});(await fetch(p,v)).ok||r({type:"setError",payload:"Couldn't update user data"}),i()}catch(p){console.error("update error",p),r({type:"setError",payload:"Failed to post"})}},[e,i]),u=_.useCallback(async c=>{if(!n.email)return r({type:"setError",payload:"No email found"});try{const{fetchPath:p,options:v}=ze({path:$e(e,"auth/forgot-password"),method:"POST",body:{email:n.email}}),m=await fetch(p,v);if(!m.ok){r({type:"setError",payload:"Couldn't request token to reset password"});return}const y=await m.json(),{token:T}=y,{fetchPath:j,options:F}=ze({path:$e(e,"auth/reset-password"),method:"POST",body:{token:T,password:c}});if(!(await fetch(j,F)).ok){r({type:"setError",payload:"Couldn't reset password"});return}i()}catch(p){console.error("resetPassword error",p),r({type:"setError",payload:"Failed to post"})}},[e,i,n==null?void 0:n.email]),f=_.useCallback((c,p)=>{const v=$e(e,"auth/login",c);if(p){const T=window.screenLeft+window.outerWidth/2-250,j=window.screenTop+window.outerHeight/2-500/2,F=window.open(v+"?popup=true","auth",`toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=no, resizable=no, copyhistory=no, width=500, height=500, top=${j}, left=${T}`),D=window.setInterval(function(){F.closed!==!1&&(window.clearInterval(D),i())},200);return}window.location.href=$e(e,"auth/login",c)},[e,i]);return{user:t.user,loading:t.loading,error:t.error,signin:a,signout:s,update:l,resetPassword:u,oauth_signin:f,refetch:i}}function Id(e,t){const{user:r}=t,[n,i]=_.useState(null),[o,a]=_.useState(!0),[s,l]=_.useState({error:"401 Not authorized",message:"User is not logged in."});_.useEffect(()=>{r&&u(e)},[r]);const u=async f=>{a(!0);try{const{fetchPath:c,options:p}=ze({path:$e(f,"info/"),method:"GET"}),v=await fetch(c,p);if(v.ok){const m=await v.json();i(m)}else l({error:"404 Not Found",message:"Couldn't fetch info"})}catch{l({error:"Network error",message:"Failed to fetch"})}finally{a(!1)}};return{info:n,loading:o,error:s}}const Bi=_.createContext({auth:{user:null,loading:!1,error:null,signin:async(e,t)=>null,signout:async()=>null,update:async e=>null,resetPassword:async e=>null,oauth_signin:(e,t)=>null,refetch:async()=>null},info:{info:null,loading:!1,error:null}});function Wa(){return _.useContext(Bi).auth}function Ha(){return _.useContext(Bi).info}function $d(e){const t={baseUrl:new URL(document.baseURI).pathname+"/api/v1",inheritMantineTheme:!1},{baseUrl:r,children:n}={...t,...e},i=jd(r),o={baseUrl:r,...Id(r,i)};return d.jsx(Bi.Provider,{value:{auth:i,info:o},children:n})}const Dd=async(e,t,r)=>{const{fetchPath:n,options:i}=ze({path:$e(t,"/download"),method:"POST"}),o=await fetch(n,{...i,body:JSON.stringify(r)});let a=null;const s=o.headers.get("content-type");if(s&&s.includes("application/json")?a=await o.json():a=await o.blob(),!o.ok)throw typeof a=="object"?new Error(typeof a.detail=="string"?a.detail:JSON.stringify(a,null,2)):new Error(a);const l=document.createElement("a"),u=URL.createObjectURL(a);l.href=u,l.download=e.toLowerCase()+".csv",l.click()};function Md({path:e,initialQueryParams:t,relation:r,fetchInfo:n=!0,clearInfoOnRefetch:i=!1,clearDataOnRefetch:o=!1,resetQueryParamsOnPathChange:a=!0,streaming:s=!1}){const[l,u]=_.useState(t?Jr(null,t):null),f=_.useMemo(()=>r?{...l,filters:[...l.filters,{col:r.foreign_key,opr:r.type,value:Ze(r.id)}]}:l,[r,l]),c=_.useCallback(G=>u(oe=>{if(!oe)return Jr(null,G);const le=Jr({...oe},G);if(s){if(G.page&&G.page!==oe.page&&!G.streaming)throw new Error("You cannot change page in streaming mode, use streaming.fetch() instead");if(G.page_size&&G.page_size!==oe.page_size)throw new Error("You cannot change page size in streaming mode, use streaming.fetch() instead");(G.filters||G.order_column||G.order_direction)&&(le.page=0)}return le}),[s]),[p,v]=_.useState(null),m=_.useMemo(()=>p,[p]),y=_.useCallback(()=>v(null),[]),{info:T,loading:j,refetch:F,error:D}=Ua({path:e,autoInvoke:n,clearDataOnRefetch:i}),{data:O,loading:S,refetch:M,error:Y}=ya({path:e,queryParams:f,autoInvoke:!1,clearDataOnRefetch:o});_.useEffect(()=>{f&&M()},[M,f]),_.useEffect(()=>{if(D){v({message:"Couldn't fetch info",originalError:D});return}if(Y){v({message:"Couldn't fetch list",originalError:Y});return}y()},[D,Y,y]);const ce=_.useMemo(()=>j||S,[j,S]);At.useDidUpdate(()=>{a&&c(Jr(null,t||{}))},[e]);const ie=_.useCallback(async G=>{try{const oe=await Ff(e,Ze(G));return y(),oe}catch(oe){v({message:`Couldn't fetch item with id ${G}`,originalError:oe})}},[e,y]),h=_.useCallback(async(G,oe)=>{try{const le=await Rf(e,G);return oe||(F(),M()),y(),le}catch(le){v({message:"Couldn't add item",originalError:le})}},[M,F,e,y]),A=_.useCallback(async(G,oe,le)=>{try{const He=await Lf(e,Ze(G),oe);return le||(F(),M()),y(),He}catch(He){v({message:`Couldn't update item with id ${G}`,originalError:He})}},[M,F,e,y]),U=_.useCallback(async(G,oe)=>{try{const le=await Nf(e,Ze(G));return oe||(F(),M()),y(),le}catch(le){v({message:`Couldn't delete item with id ${G}`,originalError:le})}},[M,F,e,y]),H=_.useCallback(async G=>{try{await Dd(G,e,f)}catch(oe){v({message:"Couldn't download",originalError:oe})}},[e,f]),[te,ve]=At.useSetState({data:{},isEnd:!1,fetch:()=>{throw new Error("Streaming mode not enabled, enable it by adding `streaming` prop to ApiProvider")}});return _.useEffect(()=>{s&&ve({fetch:()=>c({page:0,streaming:!0})})},[c,ve,s]),_.useEffect(()=>{s&&O&&ve(G=>{let oe=Object.keys(G.data).length;const le={isEnd:!1};return f.page<oe?(oe=f.page,le.data={[f.page]:O.result}):le.data={...G.data,[f.page]:O.result},O.result.length<f.page_size?(le.isEnd=!0,le.fetch=()=>null):le.fetch=()=>c({page:oe+1,streaming:!0}),le})},[O,c,ve,s]),{path:e,data:O,info:T,queryParams:f,loading:ce,error:m,streaming:te,setQueryParams:c,refetch:M,refetchInfo:F,getEntry:ie,addEntry:h,updateEntry:A,deleteEntry:U,download:H}}const Rd=async(e,t,r)=>{const{fetchPath:n,options:i}=ze({path:$e(e,"/bulk",t),method:"POST",body:r}),o=await fetch(n,i);let a=null;const s=o.headers.get("content-type");if(s&&s.includes("application/json")?a=await o.json():a=await o.text(),!o.ok)throw typeof a=="object"?new Error(typeof a.detail=="string"?a.detail:JSON.stringify(a,null,2)):new Error(a);return a},Nd=({Api:e})=>{const[t,r]=_.useState([]),[n,i]=_.useState(null),o=_.useCallback(async(s,l)=>{try{i(null);const u=await Rd(e.path,s,t);return l?void 0:(e.refetch(),u)}catch(u){console.error(u),i({message:"Couldn't perform bulk action",originalError:u})}},[e,t]);return{bulkActions:_.useMemo(()=>({selectedIds:t,setSelectedIds:r}),[t,r]),dispatchBulkActions:o,error:n}},Ui=_.createContext({Api:{path:"",data:null,info:null,queryParams:null,loading:!1,error:null,streaming:null,setQueryParams:e=>null,refetch:()=>null,refetchInfo:()=>null,getEntry:async e=>({}),addEntry:async(e,t)=>({}),updateEntry:async(e,t,r)=>({}),deleteEntry:async(e,t)=>({}),download:async e=>null},BulkActions:{bulkActions:{selectedIds:[],setSelectedIds:()=>{}},dispatchBulkActions:async(e,t)=>{},error:null}});function De(){const e=_.useContext(Ui);if(e===void 0)throw new Error("useApi must be used within a ApiProvider");return e.Api}function Fd(){const e=_.useContext(Ui);if(e===void 0)throw new Error("useBulkActions must be used within a ApiProvider");return e.BulkActions}function Ga({resource_name:e="",initialQueryParams:t,relation:r,fetchInfo:n,clearInfoOnRefetch:i,clearDataOnRefetch:o,resetQueryParamsOnPathChange:a,children:s,streaming:l}){const{baseUrl:u}=Ha(),f=Md({path:$e(u,e),initialQueryParams:t,relation:r,fetchInfo:n,clearInfoOnRefetch:i,clearDataOnRefetch:o,resetQueryParamsOnPathChange:a,streaming:l}),c=Nd({path:$e(u,e),Api:f});return d.jsx(Ui.Provider,{value:{Api:f,BulkActions:c},children:s})}function Vi(e){return t=>{try{return e.validateSync(t,{abortEarly:!1}),{}}catch(r){const n={};return r instanceof Fe&&r.inner.forEach(i=>{n[i.path.replaceAll("[",".").replaceAll("]","")]=i.message}),n}}}function Ld({form:e,name:t,...r}){return d.jsx(d.Fragment,{children:d.jsx(Xt.DateInput,{...e.getInputProps(t),onChange:n=>{if(n instanceof Date){const i=new Date(n.getTime()-n.getTimezoneOffset()*6e4);e.setFieldValue(t,i.toISOString().substring(0,10))}},value:e.getInputProps(t).value?new Date(e.getInputProps(t).value):null,...r})})}function zd({form:e,name:t,...r}){return d.jsx(d.Fragment,{children:d.jsx(Xt.DateTimePicker,{...e.getInputProps(t),onChange:n=>{if(n instanceof Date){const i=new Date(n);e.setFieldValue(t,i.toISOString())}},value:e.getInputProps(t).value?new Date(e.getInputProps(t).value):null,...r})})}function ln({form:e,name:t,...r}){const n=e.getInputProps(t).value,i=_.useMemo(()=>n&&typeof n=="object"?JSON.stringify(n):n||"",[n]);return t==="password"?d.jsx(b.PasswordInput,{...e.getInputProps(t),value:i,...r}):d.jsx(b.TextInput,{...e.getInputProps(t),value:i,...r})}function Ya({form:e,name:t,filter:r,...n}){const[i,o]=_.useState(""),a=e.getInputProps(t).value,s=_.useMemo(()=>a?typeof a=="object"?JSON.stringify(a,null,2):a:"",[a]);return _.useEffect(()=>{o(s)},[s]),r?d.jsx(ln,{form:e,name:t,...n}):d.jsx(b.JsonInput,{autosize:!0,minRows:4,maxRows:12,validationError:"Invalid JSON",...e.getInputProps(t),...n,value:i,onChange:l=>{if(o(l),!l){e.getInputProps(t).onChange(null);return}try{const u=JSON.parse(l);e.getInputProps(t).onChange(u)}catch{}}})}function Bd({form:e,name:t,filter:r,...n}){const[i,o]=_.useState(!!r);return d.jsxs(b.InputWrapper,{label:n.label,description:n.description,children:[!r&&d.jsxs(b.Group,{align:"center",gap:"xs",py:"0.25rem",children:[d.jsx(b.Checkbox,{checked:i,onChange:a=>o(a.currentTarget.checked)}),d.jsx(b.Text,{size:"xs",children:"WKT"})]}),i?d.jsx(ln,{form:e,name:t,...n,label:void 0,description:void 0}):d.jsx(Ya,{form:e,name:t,...n,label:void 0,description:void 0})]})}function Ud({form:e,name:t,items:r,...n}){const i=r.map(a=>({value:String(Ze(a.id)),label:a.value})),o=Array.isArray(e.getInputProps(t).value)?e.getInputProps(t).value.map(a=>String(typeof a=="object"?Ze(a.id):a)):[];return d.jsx(b.MultiSelect,{data:i,searchable:!0,...e.getInputProps(t),value:o||[],...n})}function Vd({form:e,name:t,items:r,filter:n,...i}){var a;const o=r.map(s=>({value:String(Ze(s.id)),label:s.value}));return d.jsx(b.Select,{data:o,searchable:!0,...e.getInputProps(t),onChange:s=>{if(n){e.setFieldValue(t,s);return}const l=r.find(u=>String(Ze(u.id))===s)||null;e.setFieldValue(t,l)},value:n?e.getInputProps(t).value:String(Ze((a=e.getInputProps(t).value)==null?void 0:a.id))||"",...i})}function qa({form:e,name:t,items:r,...n}){return d.jsx(b.Select,{data:r,searchable:!0,...e.getInputProps(t),value:String(e.getInputProps(t).value)||"",...n})}function Wi({form:e,name:t,schema:r,filter:n,...i}){if(!r.type)return null;switch(r.type){case"Boolean":return d.jsx(qa,{form:e,name:t,items:[{label:"true",value:n?"1":"true"},{label:"false",value:n?"0":"false"}],...i});case"RelatedList":return d.jsx(Ud,{form:e,name:t,items:r.values,...i});case"Related":return d.jsx(Vd,{form:e,name:t,items:r.values,filter:n,...i});case"DateTime":return d.jsx(zd,{form:e,name:t,valueFormat:"DD.MM.YYYY HH:mm:ss",schema:r,...i});case"Date":return d.jsx(Ld,{form:e,name:t,valueFormat:"DD.MM.YYYY",schema:r,...i});case"Geometry":return d.jsx(Bd,{form:e,name:t,filter:n,...i});case"Raw":return d.jsx(Ya,{form:e,name:t,filter:n,...i});case"Integer":case"Float":return d.jsx(ln,{form:e,name:t,...i});case"Enum":return d.jsx(qa,{form:e,name:t,items:r.values,...i});default:return d.jsx(ln,{form:e,name:t,...i})}}function Ka({opened:e,onClose:t,...r}){const{info:n,addEntry:i}=De(),o={modal:{},stack:{},addButton:{}},{addButton:a,modal:s,stack:l}=b.useProps("AddDialog",o,r),u=gi.useForm({initialValues:n.add.defaultValues,validate:Vi(n.add.schema)}),f=async c=>{await i(c),u.reset(),t()};return _.useEffect(()=>{u.setInitialValues(n.add.defaultValues),u.reset()},[n.add.defaultValues]),d.jsx(b.Modal,{opened:e,onClose:()=>{u.reset(),t()},title:n.add.title,size:"lg",centered:!0,...s,children:d.jsx(b.Box,{component:"form",onSubmit:u.onSubmit(f),children:d.jsx(b.Stack,{spacing:"md",...l,children:d.jsxs(b.ScrollArea.Autosize,{mah:450,type:"auto",children:[n.add.columns.map((c,p)=>d.jsx(Wi,{form:u,name:c.name,label:c.label,description:c.description,schema:c,withAsterisk:c.required},p)),d.jsx(b.Group,{position:"right",mt:"xl",children:d.jsx(b.Button,{type:"submit",...a,children:"Add"})})]})})})})}/**
|
|
34
|
-
* @license @tabler/icons-react v3.
|
|
33
|
+
`+(s!==a?`result of cast: ${s}`:""))}return o}_cast(t,r){let n=t===void 0?t:this.transforms.reduce((i,o)=>o.call(this,i,t,this),t);return n===void 0&&(n=this.getDefault(r)),n}_validate(t,r={},n,i){let{path:o,originalValue:a=t,strict:s=this.spec.strict}=r,l=t;s||(l=this._cast(l,Object.assign({assert:!1},r)));let u=[];for(let f of Object.values(this.internalTests))f&&u.push(f);this.runTests({path:o,value:l,originalValue:a,options:r,tests:u},n,f=>{if(f.length)return i(f,l);this.runTests({path:o,value:l,originalValue:a,options:r,tests:this.tests},n,i)})}runTests(t,r,n){let i=!1,{tests:o,value:a,originalValue:s,path:l,options:u}=t,f=m=>{i||(i=!0,r(m,a))},c=m=>{i||(i=!0,n(m,a))},p=o.length,y=[];if(!p)return c([]);let g={value:a,originalValue:s,path:l,options:u,schema:this};for(let m=0;m<o.length;m++){const T=o[m];T(g,f,function(F){F&&(Array.isArray(F)?y.push(...F):y.push(F)),--p<=0&&c(y)})}}asNestedTest({key:t,index:r,parent:n,parentPath:i,originalParent:o,options:a}){const s=t??r;if(s==null)throw TypeError("Must include `key` or `index` for nested validations");const l=typeof s=="number";let u=n[s];const f=Object.assign({},a,{strict:!0,parent:n,value:u,originalValue:o[s],key:void 0,[l?"index":"key"]:s,path:l||s.includes(".")?`${i||""}[${l?s:`"${s}"`}]`:(i?`${i}.`:"")+t});return(c,p,y)=>this.resolve(f)._validate(u,f,p,y)}validate(t,r){var n;let i=this.resolve(Object.assign({},r,{value:t})),o=(n=r==null?void 0:r.disableStackTrace)!=null?n:i.spec.disableStackTrace;return new Promise((a,s)=>i._validate(t,r,(l,u)=>{Fe.isError(l)&&(l.value=u),s(l)},(l,u)=>{l.length?s(new Fe(l,u,void 0,void 0,o)):a(u)}))}validateSync(t,r){var n;let i=this.resolve(Object.assign({},r,{value:t})),o,a=(n=r==null?void 0:r.disableStackTrace)!=null?n:i.spec.disableStackTrace;return i._validate(t,Object.assign({},r,{sync:!0}),(s,l)=>{throw Fe.isError(s)&&(s.value=l),s},(s,l)=>{if(s.length)throw new Fe(s,t,void 0,void 0,a);o=l}),o}isValid(t,r){return this.validate(t,r).then(()=>!0,n=>{if(Fe.isError(n))return!1;throw n})}isValidSync(t,r){try{return this.validateSync(t,r),!0}catch(n){if(Fe.isError(n))return!1;throw n}}_getDefault(t){let r=this.spec.default;return r==null?r:typeof r=="function"?r.call(this,t):Zt(r)}getDefault(t){return this.resolve(t||{})._getDefault(t)}default(t){return arguments.length===0?this._getDefault():this.clone({default:t})}strict(t=!0){return this.clone({strict:t})}nullability(t,r){const n=this.clone({nullable:t});return n.internalTests.nullable=Jt({message:r,name:"nullable",test(i){return i===null?this.schema.spec.nullable:!0}}),n}optionality(t,r){const n=this.clone({optional:t});return n.internalTests.optionality=Jt({message:r,name:"optionality",test(i){return i===void 0?this.schema.spec.optional:!0}}),n}optional(){return this.optionality(!0)}defined(t=pt.defined){return this.optionality(!1,t)}nullable(){return this.nullability(!0)}nonNullable(t=pt.notNull){return this.nullability(!1,t)}required(t=pt.required){return this.clone().withMutation(r=>r.nonNullable(t).defined(t))}notRequired(){return this.clone().withMutation(t=>t.nullable().optional())}transform(t){let r=this.clone();return r.transforms.push(t),r}test(...t){let r;if(t.length===1?typeof t[0]=="function"?r={test:t[0]}:r=t[0]:t.length===2?r={name:t[0],test:t[1]}:r={name:t[0],message:t[1],test:t[2]},r.message===void 0&&(r.message=pt.default),typeof r.test!="function")throw new TypeError("`test` is a required parameters");let n=this.clone(),i=Jt(r),o=r.exclusive||r.name&&n.exclusiveTests[r.name]===!0;if(r.exclusive&&!r.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return r.name&&(n.exclusiveTests[r.name]=!!r.exclusive),n.tests=n.tests.filter(a=>!(a.OPTIONS.name===r.name&&(o||a.OPTIONS.test===i.OPTIONS.test))),n.tests.push(i),n}when(t,r){!Array.isArray(t)&&typeof t!="string"&&(r=t,t=".");let n=this.clone(),i=wa(t).map(o=>new kt(o));return i.forEach(o=>{o.isSibling&&n.deps.push(o.key)}),n.conditions.push(typeof r=="function"?new tn(i,r):tn.fromOptions(i,r)),n}typeError(t){let r=this.clone();return r.internalTests.typeError=Jt({message:t,name:"typeError",skipAbsent:!0,test(n){return this.schema._typeCheck(n)?!0:this.createError({params:{type:this.schema.type}})}}),r}oneOf(t,r=pt.oneOf){let n=this.clone();return t.forEach(i=>{n._whitelist.add(i),n._blacklist.delete(i)}),n.internalTests.whiteList=Jt({message:r,name:"oneOf",skipAbsent:!0,test(i){let o=this.schema._whitelist,a=o.resolveAll(this.resolve);return a.includes(i)?!0:this.createError({params:{values:Array.from(o).join(", "),resolved:a}})}}),n}notOneOf(t,r=pt.notOneOf){let n=this.clone();return t.forEach(i=>{n._blacklist.add(i),n._whitelist.delete(i)}),n.internalTests.blacklist=Jt({message:r,name:"notOneOf",test(i){let o=this.schema._blacklist,a=o.resolveAll(this.resolve);return a.includes(i)?this.createError({params:{values:Array.from(o).join(", "),resolved:a}}):!0}}),n}strip(t=!0){let r=this.clone();return r.spec.strip=t,r}describe(t){const r=(t?this.resolve(t):this).clone(),{label:n,meta:i,optional:o,nullable:a}=r.spec;return{meta:i,label:n,optional:o,nullable:a,default:r.getDefault(t),type:r.type,oneOf:r._whitelist.describe(),notOneOf:r._blacklist.describe(),tests:r.tests.map(l=>({name:l.OPTIONS.name,params:l.OPTIONS.params})).filter((l,u,f)=>f.findIndex(c=>c.name===l.name)===u)}}}Le.prototype.__isYupSchema__=!0;for(const e of["validate","validateSync"])Le.prototype[`${e}At`]=function(t,r,n={}){const{parent:i,parentPath:o,schema:a}=Oi(this,t,r,n.context);return a[e](i&&i[o],Object.assign({},n,{parent:i,path:t}))};for(const e of["equals","is"])Le.prototype[e]=Le.prototype.oneOf;for(const e of["not","nope"])Le.prototype[e]=Le.prototype.notOneOf;const cd=()=>!0;function on(e){return new ki(e)}class ki extends Le{constructor(t){super(typeof t=="function"?{type:"mixed",check:t}:Object.assign({type:"mixed",check:cd},t))}}on.prototype=ki.prototype;function Pi(){return new ji}class ji extends Le{constructor(){super({type:"boolean",check(t){return t instanceof Boolean&&(t=t.valueOf()),typeof t=="boolean"}}),this.withMutation(()=>{this.transform((t,r,n)=>{if(n.spec.coerce&&!n.isType(t)){if(/^(true|1)$/i.test(String(t)))return!0;if(/^(false|0)$/i.test(String(t)))return!1}return t})})}isTrue(t=wi.isValue){return this.test({message:t,name:"is-value",exclusive:!0,params:{value:"true"},test(r){return st(r)||r===!0}})}isFalse(t=wi.isValue){return this.test({message:t,name:"is-value",exclusive:!0,params:{value:"false"},test(r){return st(r)||r===!1}})}default(t){return super.default(t)}defined(t){return super.defined(t)}optional(){return super.optional()}required(t){return super.required(t)}notRequired(){return super.notRequired()}nullable(){return super.nullable()}nonNullable(t){return super.nonNullable(t)}strip(t){return super.strip(t)}}Pi.prototype=ji.prototype;const fd=/^(\d{4}|[+-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,.](\d{1,}))?)?(?:(Z)|([+-])(\d{2})(?::?(\d{2}))?)?)?$/;function dd(e){const t=Ii(e);if(!t)return Date.parse?Date.parse(e):Number.NaN;if(t.z===void 0&&t.plusMinus===void 0)return new Date(t.year,t.month,t.day,t.hour,t.minute,t.second,t.millisecond).valueOf();let r=0;return t.z!=="Z"&&t.plusMinus!==void 0&&(r=t.hourOffset*60+t.minuteOffset,t.plusMinus==="+"&&(r=0-r)),Date.UTC(t.year,t.month,t.day,t.hour,t.minute+r,t.second,t.millisecond)}function Ii(e){var t,r;const n=fd.exec(e);return n?{year:vt(n[1]),month:vt(n[2],1)-1,day:vt(n[3],1),hour:vt(n[4]),minute:vt(n[5]),second:vt(n[6]),millisecond:n[7]?vt(n[7].substring(0,3)):0,precision:(t=(r=n[7])==null?void 0:r.length)!=null?t:void 0,z:n[8]||void 0,plusMinus:n[9]||void 0,hourOffset:vt(n[10]),minuteOffset:vt(n[11])}:null}function vt(e,t=0){return Number(e)||t}let pd=/^[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,hd=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,md=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,gd="^\\d{4}-\\d{2}-\\d{2}",yd="\\d{2}:\\d{2}:\\d{2}",vd="(([+-]\\d{2}(:?\\d{2})?)|Z)",bd=new RegExp(`${gd}T${yd}(\\.\\d+)?${vd}$`),xd=e=>st(e)||e===e.trim(),Td={}.toString();function an(){return new $i}class $i extends Le{constructor(){super({type:"string",check(t){return t instanceof String&&(t=t.valueOf()),typeof t=="string"}}),this.withMutation(()=>{this.transform((t,r,n)=>{if(!n.spec.coerce||n.isType(t)||Array.isArray(t))return t;const i=t!=null&&t.toString?t.toString():t;return i===Td?t:i})})}required(t){return super.required(t).withMutation(r=>r.test({message:t||pt.required,name:"required",skipAbsent:!0,test:n=>!!n.length}))}notRequired(){return super.notRequired().withMutation(t=>(t.tests=t.tests.filter(r=>r.OPTIONS.name!=="required"),t))}length(t,r=Ye.length){return this.test({message:r,name:"length",exclusive:!0,params:{length:t},skipAbsent:!0,test(n){return n.length===this.resolve(t)}})}min(t,r=Ye.min){return this.test({message:r,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(n){return n.length>=this.resolve(t)}})}max(t,r=Ye.max){return this.test({name:"max",exclusive:!0,message:r,params:{max:t},skipAbsent:!0,test(n){return n.length<=this.resolve(t)}})}matches(t,r){let n=!1,i,o;return r&&(typeof r=="object"?{excludeEmptyString:n=!1,message:i,name:o}=r:i=r),this.test({name:o||"matches",message:i||Ye.matches,params:{regex:t},skipAbsent:!0,test:a=>a===""&&n||a.search(t)!==-1})}email(t=Ye.email){return this.matches(pd,{name:"email",message:t,excludeEmptyString:!0})}url(t=Ye.url){return this.matches(hd,{name:"url",message:t,excludeEmptyString:!0})}uuid(t=Ye.uuid){return this.matches(md,{name:"uuid",message:t,excludeEmptyString:!1})}datetime(t){let r="",n,i;return t&&(typeof t=="object"?{message:r="",allowOffset:n=!1,precision:i=void 0}=t:r=t),this.matches(bd,{name:"datetime",message:r||Ye.datetime,excludeEmptyString:!0}).test({name:"datetime_offset",message:r||Ye.datetime_offset,params:{allowOffset:n},skipAbsent:!0,test:o=>{if(!o||n)return!0;const a=Ii(o);return a?!!a.z:!1}}).test({name:"datetime_precision",message:r||Ye.datetime_precision,params:{precision:i},skipAbsent:!0,test:o=>{if(!o||i==null)return!0;const a=Ii(o);return a?a.precision===i:!1}})}ensure(){return this.default("").transform(t=>t===null?"":t)}trim(t=Ye.trim){return this.transform(r=>r!=null?r.trim():r).test({message:t,name:"trim",test:xd})}lowercase(t=Ye.lowercase){return this.transform(r=>st(r)?r:r.toLowerCase()).test({message:t,name:"string_case",exclusive:!0,skipAbsent:!0,test:r=>st(r)||r===r.toLowerCase()})}uppercase(t=Ye.uppercase){return this.transform(r=>st(r)?r:r.toUpperCase()).test({message:t,name:"string_case",exclusive:!0,skipAbsent:!0,test:r=>st(r)||r===r.toUpperCase()})}}an.prototype=$i.prototype;let _d=e=>e!=+e;function $a(){return new Di}class Di extends Le{constructor(){super({type:"number",check(t){return t instanceof Number&&(t=t.valueOf()),typeof t=="number"&&!_d(t)}}),this.withMutation(()=>{this.transform((t,r,n)=>{if(!n.spec.coerce)return t;let i=t;if(typeof i=="string"){if(i=i.replace(/\s/g,""),i==="")return NaN;i=+i}return n.isType(i)||i===null?i:parseFloat(i)})})}min(t,r=Ot.min){return this.test({message:r,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(n){return n>=this.resolve(t)}})}max(t,r=Ot.max){return this.test({message:r,name:"max",exclusive:!0,params:{max:t},skipAbsent:!0,test(n){return n<=this.resolve(t)}})}lessThan(t,r=Ot.lessThan){return this.test({message:r,name:"max",exclusive:!0,params:{less:t},skipAbsent:!0,test(n){return n<this.resolve(t)}})}moreThan(t,r=Ot.moreThan){return this.test({message:r,name:"min",exclusive:!0,params:{more:t},skipAbsent:!0,test(n){return n>this.resolve(t)}})}positive(t=Ot.positive){return this.moreThan(0,t)}negative(t=Ot.negative){return this.lessThan(0,t)}integer(t=Ot.integer){return this.test({name:"integer",message:t,skipAbsent:!0,test:r=>Number.isInteger(r)})}truncate(){return this.transform(t=>st(t)?t:t|0)}round(t){var r;let n=["ceil","floor","round","trunc"];if(t=((r=t)==null?void 0:r.toLowerCase())||"round",t==="trunc")return this.truncate();if(n.indexOf(t.toLowerCase())===-1)throw new TypeError("Only valid options for round() are: "+n.join(", "));return this.transform(i=>st(i)?i:Math[t](i))}}$a.prototype=Di.prototype;let Da=new Date(""),Ed=e=>Object.prototype.toString.call(e)==="[object Date]";function Mi(){return new Qt}class Qt extends Le{constructor(){super({type:"date",check(t){return Ed(t)&&!isNaN(t.getTime())}}),this.withMutation(()=>{this.transform((t,r,n)=>!n.spec.coerce||n.isType(t)||t===null?t:(t=dd(t),isNaN(t)?Qt.INVALID_DATE:new Date(t)))})}prepareParam(t,r){let n;if(kt.isRef(t))n=t;else{let i=this.cast(t);if(!this._typeCheck(i))throw new TypeError(`\`${r}\` must be a Date or a value that can be \`cast()\` to a Date`);n=i}return n}min(t,r=Ci.min){let n=this.prepareParam(t,"min");return this.test({message:r,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(i){return i>=this.resolve(n)}})}max(t,r=Ci.max){let n=this.prepareParam(t,"max");return this.test({message:r,name:"max",exclusive:!0,params:{max:t},skipAbsent:!0,test(i){return i<=this.resolve(n)}})}}Qt.INVALID_DATE=Da,Mi.prototype=Qt.prototype,Mi.INVALID_DATE=Da;function Sd(e,t=[]){let r=[],n=new Set,i=new Set(t.map(([a,s])=>`${a}-${s}`));function o(a,s){let l=zt.split(a)[0];n.add(l),i.has(`${s}-${l}`)||r.push([s,l])}for(const a of Object.keys(e)){let s=e[a];n.add(a),kt.isRef(s)&&s.isSibling?o(s.path,a):Bt(s)&&"deps"in s&&s.deps.forEach(l=>o(l,a))}return ed.array(Array.from(n),r).reverse()}function Ma(e,t){let r=1/0;return e.some((n,i)=>{var o;if((o=t.path)!=null&&o.includes(n))return r=i,!0}),r}function Ra(e){return(t,r)=>Ma(e,t)-Ma(e,r)}const Na=(e,t,r)=>{if(typeof e!="string")return e;let n=e;try{n=JSON.parse(e)}catch{}return r.isType(n)?n:e};function sn(e){if("fields"in e){const t={};for(const[r,n]of Object.entries(e.fields))t[r]=sn(n);return e.setFields(t)}if(e.type==="array"){const t=e.optional();return t.innerType&&(t.innerType=sn(t.innerType)),t}return e.type==="tuple"?e.optional().clone({types:e.spec.types.map(sn)}):"optional"in e?e.optional():e}const Cd=(e,t)=>{const r=[...zt.normalizePath(t)];if(r.length===1)return r[0]in e;let n=r.pop(),i=zt.getter(zt.join(r),!0)(e);return!!(i&&n in i)};let Fa=e=>Object.prototype.toString.call(e)==="[object Object]";function wd(e,t){let r=Object.keys(e.fields);return Object.keys(t).filter(n=>r.indexOf(n)===-1)}const Ad=Ra([]);function Sr(e){return new Ri(e)}class Ri extends Le{constructor(t){super({type:"object",check(r){return Fa(r)||typeof r=="function"}}),this.fields=Object.create(null),this._sortErrors=Ad,this._nodes=[],this._excludedEdges=[],this.withMutation(()=>{t&&this.shape(t)})}_cast(t,r={}){var n;let i=super._cast(t,r);if(i===void 0)return this.getDefault(r);if(!this._typeCheck(i))return i;let o=this.fields,a=(n=r.stripUnknown)!=null?n:this.spec.noUnknown,s=[].concat(this._nodes,Object.keys(i).filter(c=>!this._nodes.includes(c))),l={},u=Object.assign({},r,{parent:l,__validating:r.__validating||!1}),f=!1;for(const c of s){let p=o[c],y=c in i;if(p){let g,m=i[c];u.path=(r.path?`${r.path}.`:"")+c,p=p.resolve({value:m,context:r.context,parent:l});let T=p instanceof Le?p.spec:void 0,j=T==null?void 0:T.strict;if(T!=null&&T.strip){f=f||c in i;continue}g=!r.__validating||!j?p.cast(i[c],u):i[c],g!==void 0&&(l[c]=g)}else y&&!a&&(l[c]=i[c]);(y!==c in l||l[c]!==i[c])&&(f=!0)}return f?l:i}_validate(t,r={},n,i){let{from:o=[],originalValue:a=t,recursive:s=this.spec.recursive}=r;r.from=[{schema:this,value:a},...o],r.__validating=!0,r.originalValue=a,super._validate(t,r,n,(l,u)=>{if(!s||!Fa(u)){i(l,u);return}a=a||u;let f=[];for(let c of this._nodes){let p=this.fields[c];!p||kt.isRef(p)||f.push(p.asNestedTest({options:r,key:c,parent:u,parentPath:r.path,originalParent:a}))}this.runTests({tests:f,value:u,originalValue:a,options:r},n,c=>{i(c.sort(this._sortErrors).concat(l),u)})})}clone(t){const r=super.clone(t);return r.fields=Object.assign({},this.fields),r._nodes=this._nodes,r._excludedEdges=this._excludedEdges,r._sortErrors=this._sortErrors,r}concat(t){let r=super.concat(t),n=r.fields;for(let[i,o]of Object.entries(this.fields)){const a=n[i];n[i]=a===void 0?o:a}return r.withMutation(i=>i.setFields(n,[...this._excludedEdges,...t._excludedEdges]))}_getDefault(t){if("default"in this.spec)return super._getDefault(t);if(!this._nodes.length)return;let r={};return this._nodes.forEach(n=>{var i;const o=this.fields[n];let a=t;(i=a)!=null&&i.value&&(a=Object.assign({},a,{parent:a.value,value:a.value[n]})),r[n]=o&&"getDefault"in o?o.getDefault(a):void 0}),r}setFields(t,r){let n=this.clone();return n.fields=t,n._nodes=Sd(t,r),n._sortErrors=Ra(Object.keys(t)),r&&(n._excludedEdges=r),n}shape(t,r=[]){return this.clone().withMutation(n=>{let i=n._excludedEdges;return r.length&&(Array.isArray(r[0])||(r=[r]),i=[...n._excludedEdges,...r]),n.setFields(Object.assign(n.fields,t),i)})}partial(){const t={};for(const[r,n]of Object.entries(this.fields))t[r]="optional"in n&&n.optional instanceof Function?n.optional():n;return this.setFields(t)}deepPartial(){return sn(this)}pick(t){const r={};for(const n of t)this.fields[n]&&(r[n]=this.fields[n]);return this.setFields(r,this._excludedEdges.filter(([n,i])=>t.includes(n)&&t.includes(i)))}omit(t){const r=[];for(const n of Object.keys(this.fields))t.includes(n)||r.push(n);return this.pick(r)}from(t,r,n){let i=zt.getter(t,!0);return this.transform(o=>{if(!o)return o;let a=o;return Cd(o,t)&&(a=Object.assign({},o),n||delete a[t],a[r]=i(o)),a})}json(){return this.transform(Na)}noUnknown(t=!0,r=Ai.noUnknown){typeof t!="boolean"&&(r=t,t=!0);let n=this.test({name:"noUnknown",exclusive:!0,message:r,test(i){if(i==null)return!0;const o=wd(this.schema,i);return!t||o.length===0||this.createError({params:{unknown:o.join(", ")}})}});return n.spec.noUnknown=t,n}unknown(t=!0,r=Ai.noUnknown){return this.noUnknown(!t,r)}transformKeys(t){return this.transform(r=>{if(!r)return r;const n={};for(const i of Object.keys(r))n[t(i)]=r[i];return n})}camelCase(){return this.transformKeys(Ei.camelCase)}snakeCase(){return this.transformKeys(Ei.snakeCase)}constantCase(){return this.transformKeys(t=>Ei.snakeCase(t).toUpperCase())}describe(t){const r=(t?this.resolve(t):this).clone(),n=super.describe(t);n.fields={};for(const[o,a]of Object.entries(r.fields)){var i;let s=t;(i=s)!=null&&i.value&&(s=Object.assign({},s,{parent:s.value,value:s.value[o]})),n.fields[o]=a.describe(s)}return n}}Sr.prototype=Ri.prototype;function Ni(e){return new Fi(e)}class Fi extends Le{constructor(t){super({type:"array",spec:{types:t},check(r){return Array.isArray(r)}}),this.innerType=void 0,this.innerType=t}_cast(t,r){const n=super._cast(t,r);if(!this._typeCheck(n)||!this.innerType)return n;let i=!1;const o=n.map((a,s)=>{const l=this.innerType.cast(a,Object.assign({},r,{path:`${r.path||""}[${s}]`}));return l!==a&&(i=!0),l});return i?o:n}_validate(t,r={},n,i){var o;let a=this.innerType,s=(o=r.recursive)!=null?o:this.spec.recursive;r.originalValue!=null&&r.originalValue,super._validate(t,r,n,(l,u)=>{var f;if(!s||!a||!this._typeCheck(u)){i(l,u);return}let c=new Array(u.length);for(let y=0;y<u.length;y++){var p;c[y]=a.asNestedTest({options:r,index:y,parent:u,parentPath:r.path,originalParent:(p=r.originalValue)!=null?p:t})}this.runTests({value:u,tests:c,originalValue:(f=r.originalValue)!=null?f:t,options:r},n,y=>i(y.concat(l),u))})}clone(t){const r=super.clone(t);return r.innerType=this.innerType,r}json(){return this.transform(Na)}concat(t){let r=super.concat(t);return r.innerType=this.innerType,t.innerType&&(r.innerType=r.innerType?r.innerType.concat(t.innerType):t.innerType),r}of(t){let r=this.clone();if(!Bt(t))throw new TypeError("`array.of()` sub-schema must be a valid yup schema not: "+dt(t));return r.innerType=t,r.spec=Object.assign({},r.spec,{types:t}),r}length(t,r=en.length){return this.test({message:r,name:"length",exclusive:!0,params:{length:t},skipAbsent:!0,test(n){return n.length===this.resolve(t)}})}min(t,r){return r=r||en.min,this.test({message:r,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(n){return n.length>=this.resolve(t)}})}max(t,r){return r=r||en.max,this.test({message:r,name:"max",exclusive:!0,params:{max:t},skipAbsent:!0,test(n){return n.length<=this.resolve(t)}})}ensure(){return this.default(()=>[]).transform((t,r)=>this._typeCheck(t)?t:r==null?[]:[].concat(r))}compact(t){let r=t?(n,i,o)=>!t(n,i,o):n=>!!n;return this.transform(n=>n!=null?n.filter(r):n)}describe(t){const r=(t?this.resolve(t):this).clone(),n=super.describe(t);if(r.innerType){var i;let o=t;(i=o)!=null&&i.value&&(o=Object.assign({},o,{parent:o.value,value:o.value[0]})),n.innerType=r.innerType.describe(o)}return n}}Ni.prototype=Fi.prototype;function La(e){return new Li(e)}class Li extends Le{constructor(t){super({type:"tuple",spec:{types:t},check(r){const n=this.spec.types;return Array.isArray(r)&&r.length===n.length}}),this.withMutation(()=>{this.typeError(ja.notType)})}_cast(t,r){const{types:n}=this.spec,i=super._cast(t,r);if(!this._typeCheck(i))return i;let o=!1;const a=n.map((s,l)=>{const u=s.cast(i[l],Object.assign({},r,{path:`${r.path||""}[${l}]`}));return u!==i[l]&&(o=!0),u});return o?a:i}_validate(t,r={},n,i){let o=this.spec.types;super._validate(t,r,n,(a,s)=>{var l;if(!this._typeCheck(s)){i(a,s);return}let u=[];for(let[c,p]of o.entries()){var f;u[c]=p.asNestedTest({options:r,index:c,parent:s,parentPath:r.path,originalParent:(f=r.originalValue)!=null?f:t})}this.runTests({value:s,tests:u,originalValue:(l=r.originalValue)!=null?l:t,options:r},n,c=>i(c.concat(a),s))})}describe(t){const r=(t?this.resolve(t):this).clone(),n=super.describe(t);return n.innerType=r.spec.types.map((i,o)=>{var a;let s=t;return(a=s)!=null&&a.value&&(s=Object.assign({},s,{parent:s.value,value:s.value[o]})),i.describe(s)}),n}}La.prototype=Li.prototype;function Od(e){return new zi(e)}class zi{constructor(t){this.type="lazy",this.__isYupSchema__=!0,this.spec=void 0,this._resolve=(r,n={})=>{let i=this.builder(r,n);if(!Bt(i))throw new TypeError("lazy() functions must return a valid schema");return this.spec.optional&&(i=i.optional()),i.resolve(n)},this.builder=t,this.spec={meta:void 0,optional:!1}}clone(t){const r=new zi(this.builder);return r.spec=Object.assign({},this.spec,t),r}optionality(t){return this.clone({optional:t})}optional(){return this.optionality(!0)}resolve(t){return this._resolve(t.value,t)}cast(t,r){return this._resolve(t,r).cast(t,r)}asNestedTest(t){let{key:r,index:n,parent:i,options:o}=t,a=i[n??r];return this._resolve(a,Object.assign({},o,{value:a,parent:i})).asNestedTest(t)}validate(t,r){return this._resolve(t,r).validate(t,r)}validateSync(t,r){return this._resolve(t,r).validateSync(t,r)}validateAt(t,r,n){return this._resolve(r,n).validateAt(t,r,n)}validateSyncAt(t,r,n){return this._resolve(r,n).validateSyncAt(t,r,n)}isValid(t,r){return this._resolve(t,r).isValid(t,r)}isValidSync(t,r){return this._resolve(t,r).isValidSync(t,r)}describe(t){return t?this.resolve(t).describe(t):{type:"lazy",meta:this.spec.meta,label:void 0}}meta(...t){if(t.length===0)return this.spec.meta;let r=this.clone();return r.spec.meta=Object.assign(r.spec.meta||{},t[0]),r}}function kd(e){Object.keys(e).forEach(t=>{Object.keys(e[t]).forEach(r=>{Ia[t][r]=e[t][r]})})}function Pd(e,t,r){if(!e||!Bt(e.prototype))throw new TypeError("You must provide a yup schema constructor function");if(typeof t!="string")throw new TypeError("A Method name must be provided");if(typeof r!="function")throw new TypeError("Method function must be provided");e.prototype[t]=r}const za=Object.freeze(Object.defineProperty({__proto__:null,ArraySchema:Fi,BooleanSchema:ji,DateSchema:Qt,MixedSchema:ki,NumberSchema:Di,ObjectSchema:Ri,Schema:Le,StringSchema:$i,TupleSchema:Li,ValidationError:Fe,addMethod:Pd,array:Ni,bool:Pi,boolean:Pi,date:Mi,defaultLocale:Ia,getIn:Oi,isSchema:Bt,lazy:Od,mixed:on,number:$a,object:Sr,printValue:dt,reach:ud,ref:ld,setLocale:kd,string:an,tuple:La},Symbol.toStringTag,{value:"Module"})),Ba=e=>{const t=e.reduce((r,n)=>{let{name:i,required:o,type:a}=n;switch(a){case"RelatedList":a="array";break;case"Related":a="object";break;case"Integer":case"Float":a="number";break;case"Geometry":case"Raw":a="mixed";break;default:a="string"}let s;try{o?s=za[a]().typeError(`Field must be of type ${a}`).required("Field is required"):s=za[a]().typeError(`Field must be of type ${a}`).nullable(!0)}catch(l){console.log(l)}return r[i]=s,r},{});return Sr().shape(t)};function Ua({path:e,autoInvoke:t=!0,clearDataOnRefetch:r=!1}){const{fetchPath:n,options:i}=_.useMemo(()=>ze({path:$e(e,"_info"),method:"GET"}),[e]),{data:o,loading:a,refetch:s,error:l}=Xr(n,{autoInvoke:t,clearDataOnRefetch:r,...i});return{info:_.useMemo(()=>o?{...o,add:{columns:o.add_columns,title:o.add_title,schema:Ba(o.add_columns),defaultValues:va(o.add_columns)},edit:{columns:o.edit_columns,title:o.edit_title,schema:Ba(o.edit_columns),defaultValues:va(o.edit_columns)}}:null,[o]),loading:a,refetch:s,error:l}}const Va={user:null,loading:!0,error:null};function jd(e,t){switch(t.type){case"initCall":return{...Va,user:e.user};case"setUser":return{...e,user:t.payload,error:null};case"setError":return{...e,loading:!1,error:t.payload};case"setLoading":return{...e,loading:t.payload};default:return e}}function Id(e){const[t,r]=_.useReducer(jd,Va),{user:n,refetch:i,loading:o}=ga({path:e});_.useEffect(()=>{r({type:"setLoading",payload:o})},[o]),_.useEffect(()=>{r({type:"setUser",payload:n})},[n]);const a=_.useCallback(async({username:c,password:p})=>{r({type:"initCall"});try{const y=new FormData;y.append("username",c),y.append("password",p);const{fetchPath:g,options:m}=ze({path:$e(e,"auth/login"),method:"POST"}),T=await fetch(g,{...m,headers:{"Content-Type":"application/x-www-form-urlencoded"},body:new URLSearchParams(y)});T.ok||(T.status===400?r({type:"setError",payload:"Username or password wrong."}):r({type:"setError",payload:"Couldn't sign in user"})),i()}catch(y){console.error("signin error",y),r({type:"setError",payload:"Failed to fetch"})}},[e,i]),s=_.useCallback(async()=>{r({type:"initCall"});try{const{fetchPath:c,options:p}=ze({path:$e(e,"auth/logout"),method:"POST"});(await fetch(c,p)).ok||r({type:"setError",payload:"Couldn't sign out user"}),r({type:"setUser",payload:null})}catch(c){console.error("signout error",c),r({type:"setError",payload:"Failed to fetch"})}finally{r({type:"setLoading",payload:!1})}},[e]),l=_.useCallback(async c=>{r({type:"initCall"});try{const{fetchPath:p,options:y}=ze({path:$e(e,"auth/user"),method:"PUT",body:c});(await fetch(p,y)).ok||r({type:"setError",payload:"Couldn't update user data"}),i()}catch(p){console.error("update error",p),r({type:"setError",payload:"Failed to post"})}},[e,i]),u=_.useCallback(async c=>{if(!n.email)return r({type:"setError",payload:"No email found"});try{const{fetchPath:p,options:y}=ze({path:$e(e,"auth/forgot-password"),method:"POST",body:{email:n.email}}),g=await fetch(p,y);if(!g.ok){r({type:"setError",payload:"Couldn't request token to reset password"});return}const m=await g.json(),{token:T}=m,{fetchPath:j,options:F}=ze({path:$e(e,"auth/reset-password"),method:"POST",body:{token:T,password:c}});if(!(await fetch(j,F)).ok){r({type:"setError",payload:"Couldn't reset password"});return}i()}catch(p){console.error("resetPassword error",p),r({type:"setError",payload:"Failed to post"})}},[e,i,n==null?void 0:n.email]),f=_.useCallback((c,p)=>{const y=$e(e,"auth/login",c);if(p){const T=window.screenLeft+window.outerWidth/2-250,j=window.screenTop+window.outerHeight/2-500/2,F=window.open(y+"?popup=true","auth",`toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=no, resizable=no, copyhistory=no, width=500, height=500, top=${j}, left=${T}`),D=window.setInterval(function(){F.closed!==!1&&(window.clearInterval(D),i())},200);return}window.location.href=$e(e,"auth/login",c)},[e,i]);return{user:t.user,loading:t.loading,error:t.error,signin:a,signout:s,update:l,resetPassword:u,oauth_signin:f,refetch:i}}function $d(e,t){const{user:r}=t,[n,i]=_.useState(null),[o,a]=_.useState(!0),[s,l]=_.useState({error:"401 Not authorized",message:"User is not logged in."});_.useEffect(()=>{r&&u(e)},[r]);const u=async f=>{a(!0);try{const{fetchPath:c,options:p}=ze({path:$e(f,"info/"),method:"GET"}),y=await fetch(c,p);if(y.ok){const g=await y.json();i(g)}else l({error:"404 Not Found",message:"Couldn't fetch info"})}catch{l({error:"Network error",message:"Failed to fetch"})}finally{a(!1)}};return{info:n,loading:o,error:s}}const Bi=_.createContext({auth:{user:null,loading:!1,error:null,signin:async(e,t)=>null,signout:async()=>null,update:async e=>null,resetPassword:async e=>null,oauth_signin:(e,t)=>null,refetch:async()=>null},info:{info:null,loading:!1,error:null}});function Wa(){return _.useContext(Bi).auth}function Ha(){return _.useContext(Bi).info}function Dd(e){const t={baseUrl:new URL(document.baseURI).pathname+"/api/v1",inheritMantineTheme:!1},{baseUrl:r,children:n}={...t,...e},i=Id(r),o={baseUrl:r,...$d(r,i)};return d.jsx(Bi.Provider,{value:{auth:i,info:o},children:n})}const Md=async(e,t,r)=>{const{fetchPath:n,options:i}=ze({path:$e(t,"/download"),method:"POST"}),o=await fetch(n,{...i,body:JSON.stringify(r)});let a=null;const s=o.headers.get("content-type");if(s&&s.includes("application/json")?a=await o.json():a=await o.blob(),!o.ok)throw typeof a=="object"?new Error(typeof a.detail=="string"?a.detail:JSON.stringify(a,null,2)):new Error(a);const l=document.createElement("a"),u=URL.createObjectURL(a);l.href=u,l.download=e.toLowerCase()+".csv",l.click()};function Rd({path:e,initialQueryParams:t,relation:r,fetchInfo:n=!0,clearInfoOnRefetch:i=!1,clearDataOnRefetch:o=!1,resetQueryParamsOnPathChange:a=!0,streaming:s=!1}){const[l,u]=_.useState(t?Jr(null,t):null),f=_.useMemo(()=>r?{...l,filters:[...l.filters,{col:r.foreign_key,opr:r.type,value:Ze(r.id)}]}:l,[r,l]),c=_.useCallback(G=>u(oe=>{if(!oe)return Jr(null,G);const le=Jr({...oe},G);if(s){if(G.page&&G.page!==oe.page&&!G.streaming)throw new Error("You cannot change page in streaming mode, use streaming.fetch() instead");if(G.page_size&&G.page_size!==oe.page_size)throw new Error("You cannot change page size in streaming mode, use streaming.fetch() instead");(G.filters||G.order_column||G.order_direction)&&(le.page=0)}return le}),[s]),[p,y]=_.useState(null),g=_.useMemo(()=>p,[p]),m=_.useCallback(()=>y(null),[]),{info:T,loading:j,refetch:F,error:D}=Ua({path:e,autoInvoke:n,clearDataOnRefetch:i}),{data:O,loading:E,refetch:M,error:Y}=ya({path:e,queryParams:f,autoInvoke:!1,clearDataOnRefetch:o});_.useEffect(()=>{f&&M()},[M,f]),_.useEffect(()=>{if(D){y({message:"Couldn't fetch info",originalError:D});return}if(Y){y({message:"Couldn't fetch list",originalError:Y});return}m()},[D,Y,m]);const ce=_.useMemo(()=>j||E,[j,E]);At.useDidUpdate(()=>{a&&c(Jr(null,t||{}))},[e]);const ie=_.useCallback(async G=>{try{const oe=await Lf(e,Ze(G));return m(),oe}catch(oe){y({message:`Couldn't fetch item with id ${G}`,originalError:oe})}},[e,m]),h=_.useCallback(async(G,oe)=>{try{const le=await Nf(e,G);return oe||(F(),M()),m(),le}catch(le){y({message:"Couldn't add item",originalError:le})}},[M,F,e,m]),A=_.useCallback(async(G,oe,le)=>{try{const He=await zf(e,Ze(G),oe);return le||(F(),M()),m(),He}catch(He){y({message:`Couldn't update item with id ${G}`,originalError:He})}},[M,F,e,m]),U=_.useCallback(async(G,oe)=>{try{const le=await Ff(e,Ze(G));return oe||(F(),M()),m(),le}catch(le){y({message:`Couldn't delete item with id ${G}`,originalError:le})}},[M,F,e,m]),H=_.useCallback(async G=>{try{await Md(G,e,f)}catch(oe){y({message:"Couldn't download",originalError:oe})}},[e,f]),[te,ve]=At.useSetState({data:{},isEnd:!1,fetch:()=>{throw new Error("Streaming mode not enabled, enable it by adding `streaming` prop to ApiProvider")}});return _.useEffect(()=>{s&&ve({fetch:()=>c({page:0,streaming:!0})})},[c,ve,s]),_.useEffect(()=>{s&&O&&ve(G=>{let oe=Object.keys(G.data).length;const le={isEnd:!1};return f.page<oe?(oe=f.page,le.data={[f.page]:O.result}):le.data={...G.data,[f.page]:O.result},O.result.length<f.page_size?(le.isEnd=!0,le.fetch=()=>null):le.fetch=()=>c({page:oe+1,streaming:!0}),le})},[O,c,ve,s]),{path:e,data:O,info:T,queryParams:f,loading:ce,error:g,streaming:te,setQueryParams:c,refetch:M,refetchInfo:F,getEntry:ie,addEntry:h,updateEntry:A,deleteEntry:U,download:H}}const Nd=async(e,t,r)=>{const{fetchPath:n,options:i}=ze({path:$e(e,"/bulk",t),method:"POST",body:r}),o=await fetch(n,i);let a=null;const s=o.headers.get("content-type");if(s&&s.includes("application/json")?a=await o.json():a=await o.text(),!o.ok)throw typeof a=="object"?new Error(typeof a.detail=="string"?a.detail:JSON.stringify(a,null,2)):new Error(a);return a},Fd=({Api:e})=>{const[t,r]=_.useState([]),[n,i]=_.useState(null),o=_.useCallback(async(s,l)=>{try{i(null);const u=await Nd(e.path,s,t);return l?void 0:(e.refetch(),u)}catch(u){console.error(u),i({message:"Couldn't perform bulk action",originalError:u})}},[e,t]);return{bulkActions:_.useMemo(()=>({selectedIds:t,setSelectedIds:r}),[t,r]),dispatchBulkActions:o,error:n}},Ui=_.createContext({Api:{path:"",data:null,info:null,queryParams:null,loading:!1,error:null,streaming:null,setQueryParams:e=>null,refetch:()=>null,refetchInfo:()=>null,getEntry:async e=>({}),addEntry:async(e,t)=>({}),updateEntry:async(e,t,r)=>({}),deleteEntry:async(e,t)=>({}),download:async e=>null},BulkActions:{bulkActions:{selectedIds:[],setSelectedIds:()=>{}},dispatchBulkActions:async(e,t)=>{},error:null}});function De(){const e=_.useContext(Ui);if(e===void 0)throw new Error("useApi must be used within a ApiProvider");return e.Api}function Ld(){const e=_.useContext(Ui);if(e===void 0)throw new Error("useBulkActions must be used within a ApiProvider");return e.BulkActions}function Ga({resource_name:e="",initialQueryParams:t,relation:r,fetchInfo:n,clearInfoOnRefetch:i,clearDataOnRefetch:o,resetQueryParamsOnPathChange:a,children:s,streaming:l}){const{baseUrl:u}=Ha(),f=Rd({path:$e(u,e),initialQueryParams:t,relation:r,fetchInfo:n,clearInfoOnRefetch:i,clearDataOnRefetch:o,resetQueryParamsOnPathChange:a,streaming:l}),c=Fd({path:$e(u,e),Api:f});return d.jsx(Ui.Provider,{value:{Api:f,BulkActions:c},children:s})}function Vi(e){return t=>{try{return e.validateSync(t,{abortEarly:!1}),{}}catch(r){const n={};return r instanceof Fe&&r.inner.forEach(i=>{n[i.path.replaceAll("[",".").replaceAll("]","")]=i.message}),n}}}function zd({form:e,name:t,...r}){return d.jsx(d.Fragment,{children:d.jsx(Xt.DateInput,{...e.getInputProps(t),onChange:n=>{if(n instanceof Date){const i=new Date(n.getTime()-n.getTimezoneOffset()*6e4);e.setFieldValue(t,i.toISOString().substring(0,10))}},value:e.getInputProps(t).value?new Date(e.getInputProps(t).value):null,...r})})}function Bd({form:e,name:t,...r}){return d.jsx(d.Fragment,{children:d.jsx(Xt.DateTimePicker,{...e.getInputProps(t),onChange:n=>{if(n instanceof Date){const i=new Date(n);e.setFieldValue(t,i.toISOString())}},value:e.getInputProps(t).value?new Date(e.getInputProps(t).value):null,...r})})}function ln({form:e,name:t,...r}){const n=e.getInputProps(t).value,i=_.useMemo(()=>n&&typeof n=="object"?JSON.stringify(n):n||"",[n]);return t==="password"?d.jsx(b.PasswordInput,{...e.getInputProps(t),value:i,...r}):d.jsx(b.TextInput,{...e.getInputProps(t),value:i,...r})}function Ya({form:e,name:t,filter:r,...n}){const[i,o]=_.useState(""),a=e.getInputProps(t).value,s=_.useMemo(()=>a?typeof a=="object"?JSON.stringify(a,null,2):a:"",[a]);return _.useEffect(()=>{o(s)},[s]),r?d.jsx(ln,{form:e,name:t,...n}):d.jsx(b.JsonInput,{autosize:!0,minRows:4,maxRows:12,validationError:"Invalid JSON",...e.getInputProps(t),...n,value:i,onChange:l=>{if(o(l),!l){e.getInputProps(t).onChange(null);return}try{const u=JSON.parse(l);e.getInputProps(t).onChange(u)}catch{}}})}function Ud({form:e,name:t,filter:r,...n}){const[i,o]=_.useState(!!r);return d.jsxs(b.InputWrapper,{label:n.label,description:n.description,children:[!r&&d.jsxs(b.Group,{align:"center",gap:"xs",py:"0.25rem",children:[d.jsx(b.Checkbox,{checked:i,onChange:a=>o(a.currentTarget.checked)}),d.jsx(b.Text,{size:"xs",children:"WKT"})]}),i?d.jsx(ln,{form:e,name:t,...n,label:void 0,description:void 0}):d.jsx(Ya,{form:e,name:t,...n,label:void 0,description:void 0})]})}function Vd({form:e,name:t,items:r,...n}){const i=r.map(a=>({value:String(Ze(a.id)),label:a.value})),o=Array.isArray(e.getInputProps(t).value)?e.getInputProps(t).value.map(a=>String(typeof a=="object"?Ze(a.id):a)):[];return d.jsx(b.MultiSelect,{data:i,searchable:!0,...e.getInputProps(t),value:o||[],...n})}function Wd({form:e,name:t,items:r,filter:n,...i}){var a;const o=r.map(s=>({value:String(Ze(s.id)),label:s.value}));return d.jsx(b.Select,{data:o,searchable:!0,...e.getInputProps(t),onChange:s=>{if(n){e.setFieldValue(t,s);return}const l=r.find(u=>String(Ze(u.id))===s)||null;e.setFieldValue(t,l)},value:n?e.getInputProps(t).value:String(Ze((a=e.getInputProps(t).value)==null?void 0:a.id))||"",...i})}function qa({form:e,name:t,items:r,...n}){return d.jsx(b.Select,{data:r,searchable:!0,...e.getInputProps(t),value:String(e.getInputProps(t).value)||"",...n})}function Wi({form:e,name:t,schema:r,filter:n,...i}){if(!r.type)return null;switch(r.type){case"Boolean":return d.jsx(qa,{form:e,name:t,items:[{label:"true",value:n?"1":"true"},{label:"false",value:n?"0":"false"}],...i});case"RelatedList":return d.jsx(Vd,{form:e,name:t,items:r.values,...i});case"Related":return d.jsx(Wd,{form:e,name:t,items:r.values,filter:n,...i});case"DateTime":return d.jsx(Bd,{form:e,name:t,valueFormat:"DD.MM.YYYY HH:mm:ss",schema:r,...i});case"Date":return d.jsx(zd,{form:e,name:t,valueFormat:"DD.MM.YYYY",schema:r,...i});case"Geometry":return d.jsx(Ud,{form:e,name:t,filter:n,...i});case"Raw":return d.jsx(Ya,{form:e,name:t,filter:n,...i});case"Integer":case"Float":return d.jsx(ln,{form:e,name:t,...i});case"Enum":return d.jsx(qa,{form:e,name:t,items:r.values,...i});default:return d.jsx(ln,{form:e,name:t,...i})}}function Ka({opened:e,onClose:t,...r}){const{info:n,addEntry:i}=De(),o={modal:{},stack:{},addButton:{}},{addButton:a,modal:s,stack:l}=b.useProps("AddDialog",o,r),u=gi.useForm({initialValues:n.add.defaultValues,validate:Vi(n.add.schema)}),f=async c=>{await i(c),u.reset(),t()};return _.useEffect(()=>{u.setInitialValues(n.add.defaultValues),u.reset()},[n.add.defaultValues]),d.jsx(b.Modal,{opened:e,onClose:()=>{u.reset(),t()},title:n.add.title,size:"lg",centered:!0,...s,children:d.jsx(b.Box,{component:"form",onSubmit:u.onSubmit(f),children:d.jsx(b.Stack,{spacing:"md",...l,children:d.jsxs(b.ScrollArea.Autosize,{mah:450,type:"auto",children:[n.add.columns.map((c,p)=>d.jsx(Wi,{form:u,name:c.name,label:c.label,description:c.description,schema:c,withAsterisk:c.required},p)),d.jsx(b.Group,{position:"right",mt:"xl",children:d.jsx(b.Button,{type:"submit",...a,children:"Add"})})]})})})})}/**
|
|
34
|
+
* @license @tabler/icons-react v3.20.0 - MIT
|
|
35
35
|
*
|
|
36
36
|
* This source code is licensed under the MIT license.
|
|
37
37
|
* See the LICENSE file in the root directory of this source tree.
|
|
38
|
-
*/var
|
|
39
|
-
* @license @tabler/icons-react v3.
|
|
38
|
+
*/var Hd={outline:{xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"},filled:{xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"currentColor",stroke:"none"}};/**
|
|
39
|
+
* @license @tabler/icons-react v3.20.0 - MIT
|
|
40
40
|
*
|
|
41
41
|
* This source code is licensed under the MIT license.
|
|
42
42
|
* See the LICENSE file in the root directory of this source tree.
|
|
43
|
-
*/const Be=(e,t,r,n)=>{const i=_.forwardRef(({color:o="currentColor",size:a=24,stroke:s=2,title:l,className:u,children:f,...c},p)=>_.createElement("svg",{ref:p,...
|
|
44
|
-
* @license @tabler/icons-react v3.
|
|
43
|
+
*/const Be=(e,t,r,n)=>{const i=_.forwardRef(({color:o="currentColor",size:a=24,stroke:s=2,title:l,className:u,children:f,...c},p)=>_.createElement("svg",{ref:p,...Hd[e],width:a,height:a,className:["tabler-icon",`tabler-icon-${t}`,u].join(" "),strokeWidth:s,stroke:o,...c},[l&&_.createElement("title",{key:"svg-title"},l),...n.map(([y,g])=>_.createElement(y,g)),...Array.isArray(f)?f:[f]]));return i.displayName=`${r}`,i};/**
|
|
44
|
+
* @license @tabler/icons-react v3.20.0 - MIT
|
|
45
45
|
*
|
|
46
46
|
* This source code is licensed under the MIT license.
|
|
47
47
|
* See the LICENSE file in the root directory of this source tree.
|
|
48
|
-
*/var
|
|
49
|
-
* @license @tabler/icons-react v3.
|
|
48
|
+
*/var Gd=Be("outline","alert-circle","IconAlertCircle",[["path",{d:"M3 12a9 9 0 1 0 18 0a9 9 0 0 0 -18 0",key:"svg-0"}],["path",{d:"M12 8v4",key:"svg-1"}],["path",{d:"M12 16h.01",key:"svg-2"}]]);/**
|
|
49
|
+
* @license @tabler/icons-react v3.20.0 - MIT
|
|
50
50
|
*
|
|
51
51
|
* This source code is licensed under the MIT license.
|
|
52
52
|
* See the LICENSE file in the root directory of this source tree.
|
|
53
|
-
*/var
|
|
54
|
-
* @license @tabler/icons-react v3.
|
|
53
|
+
*/var Yd=Be("outline","app-window","IconAppWindow",[["path",{d:"M3 5m0 2a2 2 0 0 1 2 -2h14a2 2 0 0 1 2 2v10a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2z",key:"svg-0"}],["path",{d:"M6 8h.01",key:"svg-1"}],["path",{d:"M9 8h.01",key:"svg-2"}]]);/**
|
|
54
|
+
* @license @tabler/icons-react v3.20.0 - MIT
|
|
55
55
|
*
|
|
56
56
|
* This source code is licensed under the MIT license.
|
|
57
57
|
* See the LICENSE file in the root directory of this source tree.
|
|
58
58
|
*/var Hi=Be("outline","chevron-down","IconChevronDown",[["path",{d:"M6 9l6 6l6 -6",key:"svg-0"}]]);/**
|
|
59
|
-
* @license @tabler/icons-react v3.
|
|
59
|
+
* @license @tabler/icons-react v3.20.0 - MIT
|
|
60
60
|
*
|
|
61
61
|
* This source code is licensed under the MIT license.
|
|
62
62
|
* See the LICENSE file in the root directory of this source tree.
|
|
63
63
|
*/var Xa=Be("outline","chevron-up","IconChevronUp",[["path",{d:"M6 15l6 -6l6 6",key:"svg-0"}]]);/**
|
|
64
|
-
* @license @tabler/icons-react v3.
|
|
64
|
+
* @license @tabler/icons-react v3.20.0 - MIT
|
|
65
65
|
*
|
|
66
66
|
* This source code is licensed under the MIT license.
|
|
67
67
|
* See the LICENSE file in the root directory of this source tree.
|
|
68
|
-
*/var
|
|
69
|
-
* @license @tabler/icons-react v3.
|
|
68
|
+
*/var qd=Be("outline","download","IconDownload",[["path",{d:"M4 17v2a2 2 0 0 0 2 2h12a2 2 0 0 0 2 -2v-2",key:"svg-0"}],["path",{d:"M7 11l5 5l5 -5",key:"svg-1"}],["path",{d:"M12 4l0 12",key:"svg-2"}]]);/**
|
|
69
|
+
* @license @tabler/icons-react v3.20.0 - MIT
|
|
70
70
|
*
|
|
71
71
|
* This source code is licensed under the MIT license.
|
|
72
72
|
* See the LICENSE file in the root directory of this source tree.
|
|
73
|
-
*/var
|
|
74
|
-
* @license @tabler/icons-react v3.
|
|
73
|
+
*/var Kd=Be("outline","exclamation-circle","IconExclamationCircle",[["path",{d:"M12 12m-9 0a9 9 0 1 0 18 0a9 9 0 1 0 -18 0",key:"svg-0"}],["path",{d:"M12 9v4",key:"svg-1"}],["path",{d:"M12 16v.01",key:"svg-2"}]]);/**
|
|
74
|
+
* @license @tabler/icons-react v3.20.0 - MIT
|
|
75
75
|
*
|
|
76
76
|
* This source code is licensed under the MIT license.
|
|
77
77
|
* See the LICENSE file in the root directory of this source tree.
|
|
78
|
-
*/var
|
|
79
|
-
* @license @tabler/icons-react v3.
|
|
78
|
+
*/var Xd=Be("outline","eye","IconEye",[["path",{d:"M10 12a2 2 0 1 0 4 0a2 2 0 0 0 -4 0",key:"svg-0"}],["path",{d:"M21 12c-2.4 4 -5.4 6 -9 6c-3.6 0 -6.6 -2 -9 -6c2.4 -4 5.4 -6 9 -6c3.6 0 6.6 2 9 6",key:"svg-1"}]]);/**
|
|
79
|
+
* @license @tabler/icons-react v3.20.0 - MIT
|
|
80
80
|
*
|
|
81
81
|
* This source code is licensed under the MIT license.
|
|
82
82
|
* See the LICENSE file in the root directory of this source tree.
|
|
83
83
|
*/var Ja=Be("outline","filter","IconFilter",[["path",{d:"M4 4h16v2.172a2 2 0 0 1 -.586 1.414l-4.414 4.414v7l-6 2v-8.5l-4.48 -4.928a2 2 0 0 1 -.52 -1.345v-2.227z",key:"svg-0"}]]);/**
|
|
84
|
-
* @license @tabler/icons-react v3.
|
|
84
|
+
* @license @tabler/icons-react v3.20.0 - MIT
|
|
85
85
|
*
|
|
86
86
|
* This source code is licensed under the MIT license.
|
|
87
87
|
* See the LICENSE file in the root directory of this source tree.
|
|
88
|
-
*/var
|
|
89
|
-
* @license @tabler/icons-react v3.
|
|
88
|
+
*/var Jd=Be("outline","id-badge-2","IconIdBadge2",[["path",{d:"M7 12h3v4h-3z",key:"svg-0"}],["path",{d:"M10 6h-6a1 1 0 0 0 -1 1v12a1 1 0 0 0 1 1h16a1 1 0 0 0 1 -1v-12a1 1 0 0 0 -1 -1h-6",key:"svg-1"}],["path",{d:"M10 3m0 1a1 1 0 0 1 1 -1h2a1 1 0 0 1 1 1v3a1 1 0 0 1 -1 1h-2a1 1 0 0 1 -1 -1z",key:"svg-2"}],["path",{d:"M14 16h2",key:"svg-3"}],["path",{d:"M14 12h4",key:"svg-4"}]]);/**
|
|
89
|
+
* @license @tabler/icons-react v3.20.0 - MIT
|
|
90
90
|
*
|
|
91
91
|
* This source code is licensed under the MIT license.
|
|
92
92
|
* See the LICENSE file in the root directory of this source tree.
|
|
93
93
|
*/var Za=Be("outline","lock","IconLock",[["path",{d:"M5 13a2 2 0 0 1 2 -2h10a2 2 0 0 1 2 2v6a2 2 0 0 1 -2 2h-10a2 2 0 0 1 -2 -2v-6z",key:"svg-0"}],["path",{d:"M11 16a1 1 0 1 0 2 0a1 1 0 0 0 -2 0",key:"svg-1"}],["path",{d:"M8 11v-4a4 4 0 1 1 8 0v4",key:"svg-2"}]]);/**
|
|
94
|
-
* @license @tabler/icons-react v3.
|
|
94
|
+
* @license @tabler/icons-react v3.20.0 - MIT
|
|
95
95
|
*
|
|
96
96
|
* This source code is licensed under the MIT license.
|
|
97
97
|
* See the LICENSE file in the root directory of this source tree.
|
|
98
|
-
*/var
|
|
99
|
-
* @license @tabler/icons-react v3.
|
|
98
|
+
*/var Zd=Be("outline","logout","IconLogout",[["path",{d:"M14 8v-2a2 2 0 0 0 -2 -2h-7a2 2 0 0 0 -2 2v12a2 2 0 0 0 2 2h7a2 2 0 0 0 2 -2v-2",key:"svg-0"}],["path",{d:"M9 12h12l-3 -3",key:"svg-1"}],["path",{d:"M18 15l3 -3",key:"svg-2"}]]);/**
|
|
99
|
+
* @license @tabler/icons-react v3.20.0 - MIT
|
|
100
100
|
*
|
|
101
101
|
* This source code is licensed under the MIT license.
|
|
102
102
|
* See the LICENSE file in the root directory of this source tree.
|
|
103
|
-
*/var
|
|
104
|
-
* @license @tabler/icons-react v3.
|
|
103
|
+
*/var Qd=Be("outline","pencil","IconPencil",[["path",{d:"M4 20h4l10.5 -10.5a2.828 2.828 0 1 0 -4 -4l-10.5 10.5v4",key:"svg-0"}],["path",{d:"M13.5 6.5l4 4",key:"svg-1"}]]);/**
|
|
104
|
+
* @license @tabler/icons-react v3.20.0 - MIT
|
|
105
105
|
*
|
|
106
106
|
* This source code is licensed under the MIT license.
|
|
107
107
|
* See the LICENSE file in the root directory of this source tree.
|
|
108
108
|
*/var Gi=Be("outline","plus","IconPlus",[["path",{d:"M12 5l0 14",key:"svg-0"}],["path",{d:"M5 12l14 0",key:"svg-1"}]]);/**
|
|
109
|
-
* @license @tabler/icons-react v3.
|
|
109
|
+
* @license @tabler/icons-react v3.20.0 - MIT
|
|
110
110
|
*
|
|
111
111
|
* This source code is licensed under the MIT license.
|
|
112
112
|
* See the LICENSE file in the root directory of this source tree.
|
|
113
113
|
*/var Qa=Be("outline","trash","IconTrash",[["path",{d:"M4 7l16 0",key:"svg-0"}],["path",{d:"M10 11l0 6",key:"svg-1"}],["path",{d:"M14 11l0 6",key:"svg-2"}],["path",{d:"M5 7l1 12a2 2 0 0 0 2 2h8a2 2 0 0 0 2 -2l1 -12",key:"svg-3"}],["path",{d:"M9 7v-3a1 1 0 0 1 1 -1h4a1 1 0 0 1 1 1v3",key:"svg-4"}]]);/**
|
|
114
|
-
* @license @tabler/icons-react v3.
|
|
114
|
+
* @license @tabler/icons-react v3.20.0 - MIT
|
|
115
115
|
*
|
|
116
116
|
* This source code is licensed under the MIT license.
|
|
117
117
|
* See the LICENSE file in the root directory of this source tree.
|
|
118
|
-
*/var Qd=Be("outline","users","IconUsers",[["path",{d:"M9 7m-4 0a4 4 0 1 0 8 0a4 4 0 1 0 -8 0",key:"svg-0"}],["path",{d:"M3 21v-2a4 4 0 0 1 4 -4h4a4 4 0 0 1 4 4v2",key:"svg-1"}],["path",{d:"M16 3.13a4 4 0 0 1 0 7.75",key:"svg-2"}],["path",{d:"M21 21v-2a4 4 0 0 0 -3 -3.85",key:"svg-3"}]]);function es(...e){const[t,r]=_.useState(!1),n={bg:"transparent",size:"sm",c:"gray"},i=b.useProps("ActionIcon",n,e);return d.jsxs(d.Fragment,{children:[d.jsx(b.Tooltip,{label:"Add Item",children:d.jsx(b.ActionIcon,{bg:i.bg,size:i.size,c:i.c,onClick:()=>{r(!0)},children:d.jsx(Gi,{})})}),d.jsx(Ka,{opened:t,onClose:()=>{r(!1)}})]})}function ep({form:e,name:t,items:r,onChange:n,...i}){return d.jsx(b.Select,{data:r,searchable:!0,...e.getInputProps(t),onChange:n,...i})}function tp({form:e,name:t,items:r,onChange:n,...i}){return d.jsx(b.Select,{data:r,searchable:!0,...e.getInputProps(t),onChange:n,...i})}function rp({form:e,name:t,...r}){const n=b.useCombobox({onDropdownClose:()=>n.resetSelectedOption(),onDropdownOpen:()=>n.updateSelectedOptionIndex("active")}),[i,o]=_.useState([]),[a,s]=_.useState(""),l=c=>{a!==""&&(i.includes(a)||o(p=>[...p,a]),s(""))},u=c=>o(p=>p.filter(v=>v!==c)),f=i.map(c=>d.jsx(b.Pill,{withRemoveButton:!0,onRemove:()=>u(c),children:c},c));return _.useEffect(()=>{const c=e.getInputProps(t).value;if(c)try{o([...c])}catch(p){console.error("Error parsing JSON:",p)}},[]),_.useEffect(()=>{e.getInputProps(t).onChange(i)},[i]),d.jsxs(b.Combobox,{store:n,onOptionSubmit:l,children:[d.jsx(b.Combobox.DropdownTarget,{children:d.jsx(b.PillsInput,{onClick:()=>n.openDropdown(),children:d.jsxs(b.Pill.Group,{children:[f,d.jsx(b.Combobox.EventsTarget,{children:d.jsx(b.PillsInput.Field,{onFocus:()=>n.openDropdown(),onBlur:()=>n.closeDropdown(),value:a,placeholder:"Search values",onChange:c=>{n.updateSelectedOptionIndex(),s(c.currentTarget.value)},onKeyDown:c=>{c.key==="Backspace"&&a.length===0&&(c.preventDefault(),u(i[i.length-1]))}})})]})})}),d.jsx(b.Combobox.Dropdown,{children:d.jsx(b.Combobox.Options,{children:d.jsxs(b.Combobox.Option,{value:"$create",children:["+ Create ",a]})})})]})}function ts({onClose:e,...t}){const{info:r,queryParams:n,setQueryParams:i,path:o}=De(),a=gi.useForm({initialValues:{filters:[]},validate:Vi(Er({filters:Ni().of(Er({col:an().transform(c=>c||void 0).required("Field is required"),opr:an().transform(c=>c||void 0).required("col is required"),value:on().when("col",{is:c=>c&&r.filters[c].schema.required,then:()=>on().required("Value is required")})}))}))}),s={bg:"transparent",size:"sm",c:"gray"},l=b.useProps("ActionIcon",s,t);_.useEffect(()=>{a.setValues({filters:[]}),a.reset()},[o]),_.useEffect(()=>{if(n.filters&&n.filters.length){const c=n.filters.map(p=>({...p,key:At.randomId()}));a.setFieldValue("filters",c)}},[n.filters]);const u=c=>{const p=c.filters.map(({key:m,...y})=>y),v=JSON.parse(JSON.stringify(p));i({filters:v,page:0}),e()},f=a.values.filters.map((c,p)=>d.jsxs(b.Box,{px:"sm",children:[d.jsxs(b.Flex,{my:"md",gap:"md",style:{whiteSpace:"nowrap"},children:[d.jsx(b.Box,{style:{width:"192px"},children:r&&r.filters&&d.jsx(ep,{form:a,name:`filters.${p}.col`,items:Object.entries(r.filters).map(([v,m])=>({label:m.label,value:String(v)})),onChange:v=>{a.setFieldValue(`filters.${p}`,{col:v,opr:"",value:"",key:At.randomId()})}})}),d.jsx(b.Box,{style:{width:"192px"},children:c.col?d.jsx(tp,{form:a,name:`filters.${p}.opr`,items:r.filters[c.col].filters.map(v=>({label:v.name,value:v.operator})),onChange:v=>{a.setFieldValue(`filters.${p}`,{col:a.values.filters[p].col,opr:v,value:"",key:At.randomId()})}}):null}),d.jsx(b.Box,{style:{width:"192px"},children:c.col?c.opr==="in"?d.jsx(rp,{form:a,name:`filters.${p}.value`}):d.jsx(Wi,{form:a,name:`filters.${p}.value`,schema:r.filters[c.col].schema,filter:!0}):null}),d.jsx(b.ActionIcon,{bg:l.bg,size:l.size,c:l.c,onClick:()=>{a.removeListItem("filters",p)},children:d.jsx(Qa,{})})]}),a.values.filters.length>1&&p<a.values.filters.length-1?d.jsx(b.Divider,{my:"md",labelPosition:"center",label:"AND"}):null]},c.key));return d.jsxs(b.Box,{component:"form",onSubmit:a.onSubmit(u),children:[f.length===0&&d.jsx(b.Box,{style:{width:"642px"},children:d.jsx(b.Text,{style:{fontStyle:"italic",padding:"7px"},size:"sm",c:"dimmed",children:"No filters selected..."})}),d.jsx(b.ScrollArea.Autosize,{mah:"40vh",mt:20,children:f}),d.jsx(b.Divider,{my:"sm"}),d.jsxs(b.Box,{style:{display:"flex",justifyContent:"space-between"},children:[d.jsx(b.Button,{variant:"subtle",leftSection:d.jsx(Gi,{}),onClick:()=>{a.insertListItem("filters",{col:"",opr:"",value:"",key:At.randomId()})},children:"Add Filter"}),d.jsx(b.Group,{spacing:"md",children:d.jsx(b.Button,{type:"submit",children:"Apply"})})]})]})}function rs(...e){const{queryParams:t}=De(),r={bg:"transparent",size:"sm",c:"gray"},n=b.useProps("ActionIcon",r,e),[i,o]=_.useState(!1);return d.jsxs(b.Popover,{opened:i,position:"bottom-end",onClose:()=>o(!1),closeOnClickOutside:!1,children:[d.jsx(b.Popover.Target,{children:d.jsx(b.Tooltip,{opened:i?!1:null,label:"Filter",children:t.filters.length!=0?d.jsx(b.Indicator,{zIndex:20,size:16,label:t.filters.length,children:d.jsx(b.ActionIcon,{bg:n.bg,size:n.size,c:n.c,onClick:()=>o(!0),children:d.jsx(Ja,{})})}):d.jsx(b.ActionIcon,{bg:n.bg,size:n.size,c:n.c,onClick:()=>o(!0),children:d.jsx(Ja,{})})})}),d.jsxs(b.Popover.Dropdown,{px:"xs",children:[d.jsx(b.Box,{style:{position:"absolute",top:4,right:4},children:d.jsx(b.CloseButton,{title:"Filters",onClick:()=>o(!1)})}),d.jsx(ts,{onClose:()=>{o(!1)}})]})]})}function np(...e){const[t,r]=_.useState(!1),{download:n}=De(),i={bg:"transparent",size:"sm",c:"gray"},o=b.useProps("ActionIcon",i,e);return t?d.jsx(b.Loader,{color:o.c,size:o.size}):d.jsx(b.Tooltip,{label:"Download",children:d.jsx(b.ActionIcon,{bg:o.bg,size:o.size,c:o.c,onClick:()=>{r(!0),n("download").then(()=>r(!1))},children:d.jsx(Yd,{})})})}const ns=_.memo(({hideAdd:e,hideFilter:t,hideDownload:r,toolbarCustomizer:n})=>{const{info:i}=De(),o=_.useMemo(()=>{const s={};return Object.entries(n).forEach(([l,u])=>{s[l]=u,typeof s[l]=="function"&&(s[l]=s[l]())}),s},[n]),a=i.permissions.includes("can_post");return d.jsxs(b.Flex,{justify:"flex-end",p:"md",gap:"sm",children:[!r&&(o.download||d.jsx(np,{})),a&&!e?o.add||d.jsx(es,{}):null,t?null:o.filter||d.jsx(rs,{})]})});ns.displayName="Toolbar";const is={root:"_root_1kmay_1",wrapper:"_wrapper_1kmay_7",icon:"_icon_1kmay_18"};function Yi({column:e,label:t,orderColumn:r,related:n,toggleAll:i,allChecked:o,classNames:a,styles:s,customElement:l,...u}){const{queryParams:f,setQueryParams:c,loading:p}=De(),v={fw:700,size:"sm",color:"gray.8",hoverColor:"gray.6",selectedColor:"blue"},m=b.useStyles({name:"FieldTitle",classes:is,classNames:a,styles:s,props:u}),y=b.useProps("FieldTitle",v,u),{hovered:T,ref:j}=At.useHover(),F=r&&f.order_column===r,D=m("wrapper");return D.style.cursor=r?D.style.cursor:"auto",d.jsx(b.Table.Th,{className:is.fieldTitleRoot,...m("root"),onClick:r&&!p?()=>c({order_column:r,order_direction:f.order_direction==="asc"?"desc":"asc"}):null,children:d.jsx(b.Box,{ref:j,...D,children:e==="Checkbox"?d.jsx(b.Checkbox,{pb:5,pl:2,onChange:i,checked:o}):d.jsxs(d.Fragment,{children:[d.jsx(b.Box,{w:"100%",fw:y.fw,size:"xl",c:T&&r?y.hoverColor:F?y.selectedColor:y.color,children:l||t||e}),n?d.jsx(b.Tooltip,{label:"Related Field",children:d.jsx(b.Indicator,{label:"rel",style:{indicator:{top:"-1px !important",right:"-2px !important",padding:"4px"}},children:d.jsx(b.Box,{...m("icon"),children:F?f.order_direction==="asc"?d.jsx(Hi,{size:14,strokeWidth:1.5}):d.jsx(Xa,{size:14,strokeWidth:1.5}):null})})}):d.jsx(b.Box,{...m("icon"),children:F?f.order_direction==="asc"?d.jsx(Hi,{size:14,strokeWidth:1.5}):d.jsx(Xa,{size:14,strokeWidth:1.5}):null})]})})})}const os=_.memo(({data:e,info:t,settings:r,hideActions:n,hideCheckbox:i,allChecked:o,toggleAll:a,headerCustomizer:s})=>{const l=e.list_columns.includes("actions")?"_actions":"actions";let u=s==null?void 0:s[l];return typeof u=="function"&&(u=u()),d.jsx(b.Table.Thead,{children:d.jsxs(b.Table.Tr,{children:[i?null:d.jsx(Yi,{data:e,column:"Checkbox",allChecked:o,toggleAll:a}),n?null:d.jsx(Yi,{column:"Actions",customElement:u}),e.list_columns.map((f,c)=>{var v;let p=s==null?void 0:s[f];return typeof p=="function"&&(p=p(e.label_columns[f])),p===null?null:d.jsx(Yi,{column:f,label:e.label_columns[f],orderColumn:e.order_columns.find(m=>m===f)||e.order_columns.find(m=>m.startsWith(`${f}.`)),related:((v=t.filters[f])==null?void 0:v.schema.type)==="Nested",customElement:p},f)})]})})});os.displayName="Header";const qi=(e,t)=>{const r=t.split("."),n=e[r[0]];if(r.length>1&&Array.isArray(n))return n.map(o=>qi(o,r.slice(1).join("."))).join(", ");const i=t.split(".").reduce((o,a)=>o[a],e);return!i&&typeof i!="boolean"&&typeof i!="number"?null:typeof i=="boolean"?i.toString():Array.isArray(i)?i.map(o=>o.name_||JSON.stringify(o,null,2)).join(", "):typeof i=="object"?i.name_||JSON.stringify(i):i};function as(e,t){return e===!0||Array.isArray(e)?t:Object.fromEntries(Object.keys(e).map(r=>[r,as(e[r],t[r])]))}function ss(e,t){if(!e)return e;const r=t.values;return!r||!r.length||Array.isArray(e.id_)&&(e.id=e.id_),e}function ip(e,t){const r={};return t.forEach(n=>{if(n.type==="Related"){r[n.name]=ss(e.result[n.name],n);return}if(n.type==="RelatedList"){r[n.name]=e.result[n.name].map(i=>ss(i,n));return}r[n.name]=typeof e.result[n.name]=="boolean"?String(e.result[n.name]):e.result[n.name]}),r}function op({relatedPath:e,...t}){const{path:r}=De();return $e(r?r.substring(0,r.lastIndexOf("/")):"",e.substring(0,e.lastIndexOf("/"))),d.jsx(Ga,{resource_name:e.replace("/",""),relation:t,children:d.jsx(xo,{hideToolbar:!0,hideDownload:!1})})}const ap=_.memo(op);function sp({item:e,info:t,loading:r,opened:n,onClose:i,...o}){const a={modal:{},tabs:{},tabsList:{},tabsPanel:{}},{modal:s,tabs:l,tabsList:u,tabsPanel:f}=b.useProps("ViewDialog",a,o);return d.jsxs(b.Modal,{opened:n,onClose:i,title:`${e==null?void 0:e.show_title} (#${Ze(e==null?void 0:e.id)})`,size:"lg",centered:!0,zIndex:1e3,...s,children:[d.jsx(b.LoadingOverlay,{visible:r}),!r&&e?d.jsxs(b.Tabs,{defaultValue:"details",...l,children:[d.jsxs(b.Tabs.List,{...u,children:[d.jsx(b.Tabs.Tab,{value:"details",children:"Details"}),t.relations.map((c,p)=>d.jsx(b.Tabs.Tab,{value:c.name,children:c.name},p))]}),d.jsx(b.Tabs.Panel,{pt:"xs",value:"details",...f,children:d.jsx(b.Paper,{p:"xs",withBorder:!0,children:d.jsx(b.Stack,{spacing:"md",children:d.jsx(b.ScrollArea,{h:450,type:"auto",children:e.show_columns.map((c,p)=>d.jsxs(b.Grid,{maw:500,children:[d.jsx(b.Grid.Col,{span:4,children:d.jsx(b.Text,{size:"md",children:e.label_columns[c]})}),d.jsx(b.Grid.Col,{span:1,children:d.jsx(b.Text,{size:"xs",children:":"})}),d.jsx(b.Grid.Col,{span:6,children:d.jsx(b.Text,{size:"md",children:qi(e.result,c)})})]},p))})})})}),t.relations.map((c,p)=>d.jsx(b.Tabs.Panel,{pt:"xs",value:c.name,children:d.jsx(b.Paper,{withBorder:!0,children:d.jsx(ap,{relatedPath:c.path,id:Ze(e.id),foreign_key:c.foreign_key,type:c.type})})},p))]}):null]})}function lp({id:e,...t}){const{info:r,getEntry:n}=De(),i={bg:"transparent",size:"sm",c:"gray"},o=b.useProps("ActionIcon",i,t),[a,s]=_.useState(null),[l,u]=_.useState(!1),[f,c]=_.useState(!1);return d.jsxs(d.Fragment,{children:[d.jsx(b.Tooltip,{label:"Details",children:d.jsx(b.ActionIcon,{bg:o.bg,size:o.size,c:o.c,onClick:async()=>{u(!0);const p=await n(e);p&&(s(p),u(!1),c(!0))},children:d.jsx(Kd,{})})}),d.jsx(sp,{item:a,info:r,loading:l,opened:f,onClose:()=>c(!1)})]})}function up(e,t){return new Promise(r=>{r(ip(e,t.edit.columns))})}function ls({item:e,info:t,opened:r,onClose:n,...i}){const{updateEntry:o}=De(),a={modal:{},stack:{},saveButton:{}},{modal:s,stack:l,saveButton:u}=b.useProps("EditDialog",a,i),f=gi.useForm({initialValues:t.edit.defaultValues,validate:Vi(t.edit.schema)}),c=()=>{const v={};return Object.keys(f.values).forEach(m=>{f.isDirty(m)&&(v[m]=!0)}),v};_.useEffect(()=>{e&&up(e,t).then(v=>{f.setValues(v),f.resetDirty(v)})},[e,t.edit.columns]);const p=async v=>{v=as(c(),v),await o(e.id,v),n()};return _.useEffect(()=>{f.setInitialValues(t.edit.defaultValues),f.reset()},[t.edit.defaultValues]),e?d.jsx(b.Modal,{opened:r,onClose:()=>{n()},title:t.edit.title,size:"lg",centered:!0,...s,children:d.jsx(b.Box,{component:"form",onSubmit:f.onSubmit(p),children:d.jsx(b.Stack,{spacing:"md",...l,children:d.jsxs(b.ScrollArea.Autosize,{mah:450,type:"auto",children:[t.edit.columns.map((v,m)=>d.jsx(Wi,{form:f,name:v.name,label:v.label,description:v.description,schema:v,withAsterisk:v.required},m)),d.jsx(b.Group,{position:"right",mt:"xl",children:d.jsx(b.Button,{type:"submit",...u,children:"Save"})})]})})})}):null}function us({id:e,...t}){const{info:r,getEntry:n}=De(),i={bg:"transparent",size:"sm",c:"gray"},o=b.useProps("ActionIcon",i,t),[a,s]=_.useState(null),[l,u]=_.useState(!1),[f,c]=_.useState(!1);return d.jsxs(d.Fragment,{children:[d.jsx(b.Tooltip,{label:"Edit",children:d.jsx(b.ActionIcon,{bg:o.bg,size:o.size,c:o.c,onClick:async()=>{u(!0);const p=await n(e);p&&(s(p),u(!1),c(!0))},children:d.jsx(Zd,{})})}),d.jsx(ls,{item:a,info:r,opened:f,onClose:()=>c(!1)})]})}function cp({opened:e,onClose:t,handleAccept:r,handleReject:n}){return d.jsxs(b.Modal,{opened:e,onClose:t,"aria-labelledby":"alert-dialog-title","aria-describedby":"alert-dialog-description",title:"Item löschen?",centered:!0,children:["Sind Sie Sicher, dass Sie das Item löschen wollen?",d.jsxs(b.Group,{align:"right",mt:"xl",justify:"flex-end",children:[d.jsx(b.Button,{onClick:n,variant:"default",children:"Abbrechen"}),d.jsx(b.Button,{onClick:r,color:"red",children:"Löschen"})]})]})}function cs({id:e,...t}){const{deleteEntry:r}=De(),n={bg:"transparent",size:"sm",c:"gray"},i=b.useProps("ActionIcon",n,t),[o,a]=_.useState(!1),s=()=>{a(!1)},l=async()=>{r(e),a(!1)};return d.jsxs(d.Fragment,{children:[d.jsx(b.Tooltip,{label:"Delete",children:d.jsx(b.ActionIcon,{bg:i.bg,size:i.size,c:i.c,onClick:()=>{a(!0)},children:d.jsx(Qa,{})})}),d.jsx(cp,{opened:o,onClose:s,handleAccept:l,handleReject:s})]})}function fs({id:e,selected:t}){const{info:r}=De();return d.jsxs(b.Flex,{style:{gap:4,whiteSpace:"nowrap"},children:[r.permissions.includes("can_get")?d.jsx(lp,{id:e}):null,r.permissions.includes("can_put")?d.jsx(us,{id:e}):null,r.permissions.includes("can_delete")?d.jsx(cs,{id:e}):null]})}var ds={},Ki={},Xi={};Object.defineProperty(Xi,"__esModule",{value:!0}),Xi.default=hp;var ps="html",hs="head",un="body",fp=/<([a-zA-Z]+[0-9]?)/,ms=/<head[^]*>/i,gs=/<body[^]*>/i,cn=function(e,t){throw new Error("This browser does not support `document.implementation.createHTMLDocument`")},Ji=function(e,t){throw new Error("This browser does not support `DOMParser.prototype.parseFromString`")},ys=typeof window=="object"&&window.DOMParser;if(typeof ys=="function"){var dp=new ys,pp="text/html";Ji=function(e,t){return t&&(e="<".concat(t,">").concat(e,"</").concat(t,">")),dp.parseFromString(e,pp)},cn=Ji}if(typeof document=="object"&&document.implementation){var fn=document.implementation.createHTMLDocument();cn=function(e,t){if(t){var r=fn.documentElement.querySelector(t);return r&&(r.innerHTML=e),fn}return fn.documentElement.innerHTML=e,fn}}var dn=typeof document=="object"&&document.createElement("template"),Zi;dn&&dn.content&&(Zi=function(e){return dn.innerHTML=e,dn.content.childNodes});function hp(e){var t,r,n=e.match(fp),i=n&&n[1]?n[1].toLowerCase():"";switch(i){case ps:{var o=Ji(e);if(!ms.test(e)){var a=o.querySelector(hs);(t=a==null?void 0:a.parentNode)===null||t===void 0||t.removeChild(a)}if(!gs.test(e)){var a=o.querySelector(un);(r=a==null?void 0:a.parentNode)===null||r===void 0||r.removeChild(a)}return o.querySelectorAll(ps)}case hs:case un:{var s=cn(e).querySelectorAll(i);return gs.test(e)&&ms.test(e)?s[0].parentNode.childNodes:s}default:{if(Zi)return Zi(e);var a=cn(e,un).querySelector(un);return a.childNodes}}}var pn={},Qi={},eo={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Doctype=e.CDATA=e.Tag=e.Style=e.Script=e.Comment=e.Directive=e.Text=e.Root=e.isTag=e.ElementType=void 0;var t;(function(n){n.Root="root",n.Text="text",n.Directive="directive",n.Comment="comment",n.Script="script",n.Style="style",n.Tag="tag",n.CDATA="cdata",n.Doctype="doctype"})(t=e.ElementType||(e.ElementType={}));function r(n){return n.type===t.Tag||n.type===t.Script||n.type===t.Style}e.isTag=r,e.Root=t.Root,e.Text=t.Text,e.Directive=t.Directive,e.Comment=t.Comment,e.Script=t.Script,e.Style=t.Style,e.Tag=t.Tag,e.CDATA=t.CDATA,e.Doctype=t.Doctype})(eo);var ae={},Pt=Ce&&Ce.__extends||function(){var e=function(t,r){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(n[o]=i[o])},e(t,r)};return function(t,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");e(t,r);function n(){this.constructor=t}t.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}}(),Cr=Ce&&Ce.__assign||function(){return Cr=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++){t=arguments[r];for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i])}return e},Cr.apply(this,arguments)};Object.defineProperty(ae,"__esModule",{value:!0}),ae.cloneNode=ae.hasChildren=ae.isDocument=ae.isDirective=ae.isComment=ae.isText=ae.isCDATA=ae.isTag=ae.Element=ae.Document=ae.CDATA=ae.NodeWithChildren=ae.ProcessingInstruction=ae.Comment=ae.Text=ae.DataNode=ae.Node=void 0;var qe=eo,to=function(){function e(){this.parent=null,this.prev=null,this.next=null,this.startIndex=null,this.endIndex=null}return Object.defineProperty(e.prototype,"parentNode",{get:function(){return this.parent},set:function(t){this.parent=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"previousSibling",{get:function(){return this.prev},set:function(t){this.prev=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"nextSibling",{get:function(){return this.next},set:function(t){this.next=t},enumerable:!1,configurable:!0}),e.prototype.cloneNode=function(t){return t===void 0&&(t=!1),ro(this,t)},e}();ae.Node=to;var hn=function(e){Pt(t,e);function t(r){var n=e.call(this)||this;return n.data=r,n}return Object.defineProperty(t.prototype,"nodeValue",{get:function(){return this.data},set:function(r){this.data=r},enumerable:!1,configurable:!0}),t}(to);ae.DataNode=hn;var vs=function(e){Pt(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.type=qe.ElementType.Text,r}return Object.defineProperty(t.prototype,"nodeType",{get:function(){return 3},enumerable:!1,configurable:!0}),t}(hn);ae.Text=vs;var bs=function(e){Pt(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.type=qe.ElementType.Comment,r}return Object.defineProperty(t.prototype,"nodeType",{get:function(){return 8},enumerable:!1,configurable:!0}),t}(hn);ae.Comment=bs;var xs=function(e){Pt(t,e);function t(r,n){var i=e.call(this,n)||this;return i.name=r,i.type=qe.ElementType.Directive,i}return Object.defineProperty(t.prototype,"nodeType",{get:function(){return 1},enumerable:!1,configurable:!0}),t}(hn);ae.ProcessingInstruction=xs;var mn=function(e){Pt(t,e);function t(r){var n=e.call(this)||this;return n.children=r,n}return Object.defineProperty(t.prototype,"firstChild",{get:function(){var r;return(r=this.children[0])!==null&&r!==void 0?r:null},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"lastChild",{get:function(){return this.children.length>0?this.children[this.children.length-1]:null},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"childNodes",{get:function(){return this.children},set:function(r){this.children=r},enumerable:!1,configurable:!0}),t}(to);ae.NodeWithChildren=mn;var Ts=function(e){Pt(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.type=qe.ElementType.CDATA,r}return Object.defineProperty(t.prototype,"nodeType",{get:function(){return 4},enumerable:!1,configurable:!0}),t}(mn);ae.CDATA=Ts;var _s=function(e){Pt(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.type=qe.ElementType.Root,r}return Object.defineProperty(t.prototype,"nodeType",{get:function(){return 9},enumerable:!1,configurable:!0}),t}(mn);ae.Document=_s;var Ss=function(e){Pt(t,e);function t(r,n,i,o){i===void 0&&(i=[]),o===void 0&&(o=r==="script"?qe.ElementType.Script:r==="style"?qe.ElementType.Style:qe.ElementType.Tag);var a=e.call(this,i)||this;return a.name=r,a.attribs=n,a.type=o,a}return Object.defineProperty(t.prototype,"nodeType",{get:function(){return 1},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"tagName",{get:function(){return this.name},set:function(r){this.name=r},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"attributes",{get:function(){var r=this;return Object.keys(this.attribs).map(function(n){var i,o;return{name:n,value:r.attribs[n],namespace:(i=r["x-attribsNamespace"])===null||i===void 0?void 0:i[n],prefix:(o=r["x-attribsPrefix"])===null||o===void 0?void 0:o[n]}})},enumerable:!1,configurable:!0}),t}(mn);ae.Element=Ss;function Es(e){return(0,qe.isTag)(e)}ae.isTag=Es;function Cs(e){return e.type===qe.ElementType.CDATA}ae.isCDATA=Cs;function ws(e){return e.type===qe.ElementType.Text}ae.isText=ws;function As(e){return e.type===qe.ElementType.Comment}ae.isComment=As;function Os(e){return e.type===qe.ElementType.Directive}ae.isDirective=Os;function ks(e){return e.type===qe.ElementType.Root}ae.isDocument=ks;function mp(e){return Object.prototype.hasOwnProperty.call(e,"children")}ae.hasChildren=mp;function ro(e,t){t===void 0&&(t=!1);var r;if(ws(e))r=new vs(e.data);else if(As(e))r=new bs(e.data);else if(Es(e)){var n=t?no(e.children):[],i=new Ss(e.name,Cr({},e.attribs),n);n.forEach(function(l){return l.parent=i}),e.namespace!=null&&(i.namespace=e.namespace),e["x-attribsNamespace"]&&(i["x-attribsNamespace"]=Cr({},e["x-attribsNamespace"])),e["x-attribsPrefix"]&&(i["x-attribsPrefix"]=Cr({},e["x-attribsPrefix"])),r=i}else if(Cs(e)){var n=t?no(e.children):[],o=new Ts(n);n.forEach(function(u){return u.parent=o}),r=o}else if(ks(e)){var n=t?no(e.children):[],a=new _s(n);n.forEach(function(u){return u.parent=a}),e["x-mode"]&&(a["x-mode"]=e["x-mode"]),r=a}else if(Os(e)){var s=new xs(e.name,e.data);e["x-name"]!=null&&(s["x-name"]=e["x-name"],s["x-publicId"]=e["x-publicId"],s["x-systemId"]=e["x-systemId"]),r=s}else throw new Error("Not implemented yet: ".concat(e.type));return r.startIndex=e.startIndex,r.endIndex=e.endIndex,e.sourceCodeLocation!=null&&(r.sourceCodeLocation=e.sourceCodeLocation),r}ae.cloneNode=ro;function no(e){for(var t=e.map(function(n){return ro(n,!0)}),r=1;r<t.length;r++)t[r].prev=t[r-1],t[r-1].next=t[r];return t}(function(e){var t=Ce&&Ce.__createBinding||(Object.create?function(s,l,u,f){f===void 0&&(f=u);var c=Object.getOwnPropertyDescriptor(l,u);(!c||("get"in c?!l.__esModule:c.writable||c.configurable))&&(c={enumerable:!0,get:function(){return l[u]}}),Object.defineProperty(s,f,c)}:function(s,l,u,f){f===void 0&&(f=u),s[f]=l[u]}),r=Ce&&Ce.__exportStar||function(s,l){for(var u in s)u!=="default"&&!Object.prototype.hasOwnProperty.call(l,u)&&t(l,s,u)};Object.defineProperty(e,"__esModule",{value:!0}),e.DomHandler=void 0;var n=eo,i=ae;r(ae,e);var o={withStartIndices:!1,withEndIndices:!1,xmlMode:!1},a=function(){function s(l,u,f){this.dom=[],this.root=new i.Document(this.dom),this.done=!1,this.tagStack=[this.root],this.lastNode=null,this.parser=null,typeof u=="function"&&(f=u,u=o),typeof l=="object"&&(u=l,l=void 0),this.callback=l??null,this.options=u??o,this.elementCB=f??null}return s.prototype.onparserinit=function(l){this.parser=l},s.prototype.onreset=function(){this.dom=[],this.root=new i.Document(this.dom),this.done=!1,this.tagStack=[this.root],this.lastNode=null,this.parser=null},s.prototype.onend=function(){this.done||(this.done=!0,this.parser=null,this.handleCallback(null))},s.prototype.onerror=function(l){this.handleCallback(l)},s.prototype.onclosetag=function(){this.lastNode=null;var l=this.tagStack.pop();this.options.withEndIndices&&(l.endIndex=this.parser.endIndex),this.elementCB&&this.elementCB(l)},s.prototype.onopentag=function(l,u){var f=this.options.xmlMode?n.ElementType.Tag:void 0,c=new i.Element(l,u,void 0,f);this.addNode(c),this.tagStack.push(c)},s.prototype.ontext=function(l){var u=this.lastNode;if(u&&u.type===n.ElementType.Text)u.data+=l,this.options.withEndIndices&&(u.endIndex=this.parser.endIndex);else{var f=new i.Text(l);this.addNode(f),this.lastNode=f}},s.prototype.oncomment=function(l){if(this.lastNode&&this.lastNode.type===n.ElementType.Comment){this.lastNode.data+=l;return}var u=new i.Comment(l);this.addNode(u),this.lastNode=u},s.prototype.oncommentend=function(){this.lastNode=null},s.prototype.oncdatastart=function(){var l=new i.Text(""),u=new i.CDATA([l]);this.addNode(u),l.parent=u,this.lastNode=l},s.prototype.oncdataend=function(){this.lastNode=null},s.prototype.onprocessinginstruction=function(l,u){var f=new i.ProcessingInstruction(l,u);this.addNode(f)},s.prototype.handleCallback=function(l){if(typeof this.callback=="function")this.callback(l,this.dom);else if(l)throw l},s.prototype.addNode=function(l){var u=this.tagStack[this.tagStack.length-1],f=u.children[u.children.length-1];this.options.withStartIndices&&(l.startIndex=this.parser.startIndex),this.options.withEndIndices&&(l.endIndex=this.parser.endIndex),u.children.push(l),f&&(l.prev=f,f.next=l),l.parent=u,this.lastNode=null},s}();e.DomHandler=a,e.default=a})(Qi);var Ps={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CASE_SENSITIVE_TAG_NAMES_MAP=e.CASE_SENSITIVE_TAG_NAMES=void 0,e.CASE_SENSITIVE_TAG_NAMES=["animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","linearGradient","radialGradient","textPath"],e.CASE_SENSITIVE_TAG_NAMES_MAP=e.CASE_SENSITIVE_TAG_NAMES.reduce(function(t,r){return t[r.toLowerCase()]=r,t},{})})(Ps),Object.defineProperty(pn,"__esModule",{value:!0}),pn.formatAttributes=js,pn.formatDOM=Is;var gn=Qi,gp=Ps;function yp(e){return gp.CASE_SENSITIVE_TAG_NAMES_MAP[e]}function js(e){for(var t={},r=0,n=e.length;r<n;r++){var i=e[r];t[i.name]=i.value}return t}function vp(e){e=e.toLowerCase();var t=yp(e);return t||e}function Is(e,t,r){t===void 0&&(t=null);for(var n=[],i,o=0,a=e.length;o<a;o++){var s=e[o];switch(s.nodeType){case 1:{var l=vp(s.nodeName);i=new gn.Element(l,js(s.attributes)),i.children=Is(l==="template"?s.content.childNodes:s.childNodes,i);break}case 3:i=new gn.Text(s.nodeValue);break;case 8:i=new gn.Comment(s.nodeValue);break;default:continue}var u=n[o-1]||null;u&&(u.next=i),i.parent=t,i.prev=u,i.next=null,n.push(i)}return r&&(i=new gn.ProcessingInstruction(r.substring(0,r.indexOf(" ")).toLowerCase(),r),i.next=n[0]||null,i.parent=t,n.unshift(i),n[1]&&(n[1].prev=n[0])),n}var bp=Ce&&Ce.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(Ki,"__esModule",{value:!0}),Ki.default=Sp;var xp=bp(Xi),Tp=pn,_p=/<(![a-zA-Z\s]+)>/;function Sp(e){if(typeof e!="string")throw new TypeError("First argument must be a string");if(!e)return[];var t=e.match(_p),r=t?t[1]:void 0;return(0,Tp.formatDOM)((0,xp.default)(e),null,r)}var yn={},lt={},vn={},Ep=0;vn.SAME=Ep;var Cp=1;vn.CAMELCASE=Cp,vn.possibleStandardNames={accept:0,acceptCharset:1,"accept-charset":"acceptCharset",accessKey:1,action:0,allowFullScreen:1,alt:0,as:0,async:0,autoCapitalize:1,autoComplete:1,autoCorrect:1,autoFocus:1,autoPlay:1,autoSave:1,capture:0,cellPadding:1,cellSpacing:1,challenge:0,charSet:1,checked:0,children:0,cite:0,class:"className",classID:1,className:1,cols:0,colSpan:1,content:0,contentEditable:1,contextMenu:1,controls:0,controlsList:1,coords:0,crossOrigin:1,dangerouslySetInnerHTML:1,data:0,dateTime:1,default:0,defaultChecked:1,defaultValue:1,defer:0,dir:0,disabled:0,disablePictureInPicture:1,disableRemotePlayback:1,download:0,draggable:0,encType:1,enterKeyHint:1,for:"htmlFor",form:0,formMethod:1,formAction:1,formEncType:1,formNoValidate:1,formTarget:1,frameBorder:1,headers:0,height:0,hidden:0,high:0,href:0,hrefLang:1,htmlFor:1,httpEquiv:1,"http-equiv":"httpEquiv",icon:0,id:0,innerHTML:1,inputMode:1,integrity:0,is:0,itemID:1,itemProp:1,itemRef:1,itemScope:1,itemType:1,keyParams:1,keyType:1,kind:0,label:0,lang:0,list:0,loop:0,low:0,manifest:0,marginWidth:1,marginHeight:1,max:0,maxLength:1,media:0,mediaGroup:1,method:0,min:0,minLength:1,multiple:0,muted:0,name:0,noModule:1,nonce:0,noValidate:1,open:0,optimum:0,pattern:0,placeholder:0,playsInline:1,poster:0,preload:0,profile:0,radioGroup:1,readOnly:1,referrerPolicy:1,rel:0,required:0,reversed:0,role:0,rows:0,rowSpan:1,sandbox:0,scope:0,scoped:0,scrolling:0,seamless:0,selected:0,shape:0,size:0,sizes:0,span:0,spellCheck:1,src:0,srcDoc:1,srcLang:1,srcSet:1,start:0,step:0,style:0,summary:0,tabIndex:1,target:0,title:0,type:0,useMap:1,value:0,width:0,wmode:0,wrap:0,about:0,accentHeight:1,"accent-height":"accentHeight",accumulate:0,additive:0,alignmentBaseline:1,"alignment-baseline":"alignmentBaseline",allowReorder:1,alphabetic:0,amplitude:0,arabicForm:1,"arabic-form":"arabicForm",ascent:0,attributeName:1,attributeType:1,autoReverse:1,azimuth:0,baseFrequency:1,baselineShift:1,"baseline-shift":"baselineShift",baseProfile:1,bbox:0,begin:0,bias:0,by:0,calcMode:1,capHeight:1,"cap-height":"capHeight",clip:0,clipPath:1,"clip-path":"clipPath",clipPathUnits:1,clipRule:1,"clip-rule":"clipRule",color:0,colorInterpolation:1,"color-interpolation":"colorInterpolation",colorInterpolationFilters:1,"color-interpolation-filters":"colorInterpolationFilters",colorProfile:1,"color-profile":"colorProfile",colorRendering:1,"color-rendering":"colorRendering",contentScriptType:1,contentStyleType:1,cursor:0,cx:0,cy:0,d:0,datatype:0,decelerate:0,descent:0,diffuseConstant:1,direction:0,display:0,divisor:0,dominantBaseline:1,"dominant-baseline":"dominantBaseline",dur:0,dx:0,dy:0,edgeMode:1,elevation:0,enableBackground:1,"enable-background":"enableBackground",end:0,exponent:0,externalResourcesRequired:1,fill:0,fillOpacity:1,"fill-opacity":"fillOpacity",fillRule:1,"fill-rule":"fillRule",filter:0,filterRes:1,filterUnits:1,floodOpacity:1,"flood-opacity":"floodOpacity",floodColor:1,"flood-color":"floodColor",focusable:0,fontFamily:1,"font-family":"fontFamily",fontSize:1,"font-size":"fontSize",fontSizeAdjust:1,"font-size-adjust":"fontSizeAdjust",fontStretch:1,"font-stretch":"fontStretch",fontStyle:1,"font-style":"fontStyle",fontVariant:1,"font-variant":"fontVariant",fontWeight:1,"font-weight":"fontWeight",format:0,from:0,fx:0,fy:0,g1:0,g2:0,glyphName:1,"glyph-name":"glyphName",glyphOrientationHorizontal:1,"glyph-orientation-horizontal":"glyphOrientationHorizontal",glyphOrientationVertical:1,"glyph-orientation-vertical":"glyphOrientationVertical",glyphRef:1,gradientTransform:1,gradientUnits:1,hanging:0,horizAdvX:1,"horiz-adv-x":"horizAdvX",horizOriginX:1,"horiz-origin-x":"horizOriginX",ideographic:0,imageRendering:1,"image-rendering":"imageRendering",in2:0,in:0,inlist:0,intercept:0,k1:0,k2:0,k3:0,k4:0,k:0,kernelMatrix:1,kernelUnitLength:1,kerning:0,keyPoints:1,keySplines:1,keyTimes:1,lengthAdjust:1,letterSpacing:1,"letter-spacing":"letterSpacing",lightingColor:1,"lighting-color":"lightingColor",limitingConeAngle:1,local:0,markerEnd:1,"marker-end":"markerEnd",markerHeight:1,markerMid:1,"marker-mid":"markerMid",markerStart:1,"marker-start":"markerStart",markerUnits:1,markerWidth:1,mask:0,maskContentUnits:1,maskUnits:1,mathematical:0,mode:0,numOctaves:1,offset:0,opacity:0,operator:0,order:0,orient:0,orientation:0,origin:0,overflow:0,overlinePosition:1,"overline-position":"overlinePosition",overlineThickness:1,"overline-thickness":"overlineThickness",paintOrder:1,"paint-order":"paintOrder",panose1:0,"panose-1":"panose1",pathLength:1,patternContentUnits:1,patternTransform:1,patternUnits:1,pointerEvents:1,"pointer-events":"pointerEvents",points:0,pointsAtX:1,pointsAtY:1,pointsAtZ:1,prefix:0,preserveAlpha:1,preserveAspectRatio:1,primitiveUnits:1,property:0,r:0,radius:0,refX:1,refY:1,renderingIntent:1,"rendering-intent":"renderingIntent",repeatCount:1,repeatDur:1,requiredExtensions:1,requiredFeatures:1,resource:0,restart:0,result:0,results:0,rotate:0,rx:0,ry:0,scale:0,security:0,seed:0,shapeRendering:1,"shape-rendering":"shapeRendering",slope:0,spacing:0,specularConstant:1,specularExponent:1,speed:0,spreadMethod:1,startOffset:1,stdDeviation:1,stemh:0,stemv:0,stitchTiles:1,stopColor:1,"stop-color":"stopColor",stopOpacity:1,"stop-opacity":"stopOpacity",strikethroughPosition:1,"strikethrough-position":"strikethroughPosition",strikethroughThickness:1,"strikethrough-thickness":"strikethroughThickness",string:0,stroke:0,strokeDasharray:1,"stroke-dasharray":"strokeDasharray",strokeDashoffset:1,"stroke-dashoffset":"strokeDashoffset",strokeLinecap:1,"stroke-linecap":"strokeLinecap",strokeLinejoin:1,"stroke-linejoin":"strokeLinejoin",strokeMiterlimit:1,"stroke-miterlimit":"strokeMiterlimit",strokeWidth:1,"stroke-width":"strokeWidth",strokeOpacity:1,"stroke-opacity":"strokeOpacity",suppressContentEditableWarning:1,suppressHydrationWarning:1,surfaceScale:1,systemLanguage:1,tableValues:1,targetX:1,targetY:1,textAnchor:1,"text-anchor":"textAnchor",textDecoration:1,"text-decoration":"textDecoration",textLength:1,textRendering:1,"text-rendering":"textRendering",to:0,transform:0,typeof:0,u1:0,u2:0,underlinePosition:1,"underline-position":"underlinePosition",underlineThickness:1,"underline-thickness":"underlineThickness",unicode:0,unicodeBidi:1,"unicode-bidi":"unicodeBidi",unicodeRange:1,"unicode-range":"unicodeRange",unitsPerEm:1,"units-per-em":"unitsPerEm",unselectable:0,vAlphabetic:1,"v-alphabetic":"vAlphabetic",values:0,vectorEffect:1,"vector-effect":"vectorEffect",version:0,vertAdvY:1,"vert-adv-y":"vertAdvY",vertOriginX:1,"vert-origin-x":"vertOriginX",vertOriginY:1,"vert-origin-y":"vertOriginY",vHanging:1,"v-hanging":"vHanging",vIdeographic:1,"v-ideographic":"vIdeographic",viewBox:1,viewTarget:1,visibility:0,vMathematical:1,"v-mathematical":"vMathematical",vocab:0,widths:0,wordSpacing:1,"word-spacing":"wordSpacing",writingMode:1,"writing-mode":"writingMode",x1:0,x2:0,x:0,xChannelSelector:1,xHeight:1,"x-height":"xHeight",xlinkActuate:1,"xlink:actuate":"xlinkActuate",xlinkArcrole:1,"xlink:arcrole":"xlinkArcrole",xlinkHref:1,"xlink:href":"xlinkHref",xlinkRole:1,"xlink:role":"xlinkRole",xlinkShow:1,"xlink:show":"xlinkShow",xlinkTitle:1,"xlink:title":"xlinkTitle",xlinkType:1,"xlink:type":"xlinkType",xmlBase:1,"xml:base":"xmlBase",xmlLang:1,"xml:lang":"xmlLang",xmlns:0,"xml:space":"xmlSpace",xmlnsXlink:1,"xmlns:xlink":"xmlnsXlink",xmlSpace:1,y1:0,y2:0,y:0,yChannelSelector:1,z:0,zoomAndPan:1};const $s=0,jt=1,bn=2,xn=3,io=4,Ds=5,Ms=6;function wp(e){return Re.hasOwnProperty(e)?Re[e]:null}function Ue(e,t,r,n,i,o,a){this.acceptsBooleans=t===bn||t===xn||t===io,this.attributeName=n,this.attributeNamespace=i,this.mustUseProperty=r,this.propertyName=e,this.type=t,this.sanitizeURL=o,this.removeEmptyString=a}const Re={};["children","dangerouslySetInnerHTML","defaultValue","defaultChecked","innerHTML","suppressContentEditableWarning","suppressHydrationWarning","style"].forEach(e=>{Re[e]=new Ue(e,$s,!1,e,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(([e,t])=>{Re[e]=new Ue(e,jt,!1,t,null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(e=>{Re[e]=new Ue(e,bn,!1,e.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(e=>{Re[e]=new Ue(e,bn,!1,e,null,!1,!1)}),["allowFullScreen","async","autoFocus","autoPlay","controls","default","defer","disabled","disablePictureInPicture","disableRemotePlayback","formNoValidate","hidden","loop","noModule","noValidate","open","playsInline","readOnly","required","reversed","scoped","seamless","itemScope"].forEach(e=>{Re[e]=new Ue(e,xn,!1,e.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(e=>{Re[e]=new Ue(e,xn,!0,e,null,!1,!1)}),["capture","download"].forEach(e=>{Re[e]=new Ue(e,io,!1,e,null,!1,!1)}),["cols","rows","size","span"].forEach(e=>{Re[e]=new Ue(e,Ms,!1,e,null,!1,!1)}),["rowSpan","start"].forEach(e=>{Re[e]=new Ue(e,Ds,!1,e.toLowerCase(),null,!1,!1)});const oo=/[\-\:]([a-z])/g,ao=e=>e[1].toUpperCase();["accent-height","alignment-baseline","arabic-form","baseline-shift","cap-height","clip-path","clip-rule","color-interpolation","color-interpolation-filters","color-profile","color-rendering","dominant-baseline","enable-background","fill-opacity","fill-rule","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","glyph-name","glyph-orientation-horizontal","glyph-orientation-vertical","horiz-adv-x","horiz-origin-x","image-rendering","letter-spacing","lighting-color","marker-end","marker-mid","marker-start","overline-position","overline-thickness","paint-order","panose-1","pointer-events","rendering-intent","shape-rendering","stop-color","stop-opacity","strikethrough-position","strikethrough-thickness","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke-width","text-anchor","text-decoration","text-rendering","underline-position","underline-thickness","unicode-bidi","unicode-range","units-per-em","v-alphabetic","v-hanging","v-ideographic","v-mathematical","vector-effect","vert-adv-y","vert-origin-x","vert-origin-y","word-spacing","writing-mode","xmlns:xlink","x-height"].forEach(e=>{const t=e.replace(oo,ao);Re[t]=new Ue(t,jt,!1,e,null,!1,!1)}),["xlink:actuate","xlink:arcrole","xlink:role","xlink:show","xlink:title","xlink:type"].forEach(e=>{const t=e.replace(oo,ao);Re[t]=new Ue(t,jt,!1,e,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(e=>{const t=e.replace(oo,ao);Re[t]=new Ue(t,jt,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(e=>{Re[e]=new Ue(e,jt,!1,e.toLowerCase(),null,!1,!1)});const Ap="xlinkHref";Re[Ap]=new Ue("xlinkHref",jt,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(e=>{Re[e]=new Ue(e,jt,!1,e.toLowerCase(),null,!0,!0)});const{CAMELCASE:Op,SAME:kp,possibleStandardNames:Rs}=vn,Pp=":A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD"+"\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040",jp=RegExp.prototype.test.bind(new RegExp("^(data|aria)-["+Pp+"]*$")),Ip=Object.keys(Rs).reduce((e,t)=>{const r=Rs[t];return r===kp?e[t]=t:r===Op?e[t.toLowerCase()]=t:e[t]=r,e},{});lt.BOOLEAN=xn,lt.BOOLEANISH_STRING=bn,lt.NUMERIC=Ds,lt.OVERLOADED_BOOLEAN=io,lt.POSITIVE_NUMERIC=Ms,lt.RESERVED=$s,lt.STRING=jt,lt.getPropertyInfo=wp,lt.isCustomAttribute=jp,lt.possibleStandardNames=Ip;var so={},lo={},Ns=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,$p=/\n/g,Dp=/^\s*/,Mp=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,Rp=/^:\s*/,Np=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,Fp=/^[;\s]*/,Lp=/^\s+|\s+$/g,zp=`
|
|
119
|
-
`,Fs="/",Ls="*",Ut="",Bp="comment",Up="declaration",Vp=function(e,t){if(typeof e!="string")throw new TypeError("First argument must be a string");if(!e)return[];t=t||{};var r=1,n=1;function i(m){var y=m.match($p);y&&(r+=y.length);var T=m.lastIndexOf(zp);n=~T?m.length-T:n+m.length}function o(){var m={line:r,column:n};return function(y){return y.position=new a(m),u(),y}}function a(m){this.start=m,this.end={line:r,column:n},this.source=t.source}a.prototype.content=e;function s(m){var y=new Error(t.source+":"+r+":"+n+": "+m);if(y.reason=m,y.filename=t.source,y.line=r,y.column=n,y.source=e,!t.silent)throw y}function l(m){var y=m.exec(e);if(y){var T=y[0];return i(T),e=e.slice(T.length),y}}function u(){l(Dp)}function f(m){var y;for(m=m||[];y=c();)y!==!1&&m.push(y);return m}function c(){var m=o();if(!(Fs!=e.charAt(0)||Ls!=e.charAt(1))){for(var y=2;Ut!=e.charAt(y)&&(Ls!=e.charAt(y)||Fs!=e.charAt(y+1));)++y;if(y+=2,Ut===e.charAt(y-1))return s("End of comment missing");var T=e.slice(2,y-2);return n+=2,i(T),e=e.slice(y),n+=2,m({type:Bp,comment:T})}}function p(){var m=o(),y=l(Mp);if(y){if(c(),!l(Rp))return s("property missing ':'");var T=l(Np),j=m({type:Up,property:zs(y[0].replace(Ns,Ut)),value:T?zs(T[0].replace(Ns,Ut)):Ut});return l(Fp),j}}function v(){var m=[];f(m);for(var y;y=p();)y!==!1&&(m.push(y),f(m));return m}return u(),v()};function zs(e){return e?e.replace(Lp,Ut):Ut}var Wp=Ce&&Ce.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(lo,"__esModule",{value:!0}),lo.default=Gp;var Hp=Wp(Vp);function Gp(e,t){var r=null;if(!e||typeof e!="string")return r;var n=(0,Hp.default)(e),i=typeof t=="function";return n.forEach(function(o){if(o.type==="declaration"){var a=o.property,s=o.value;i?t(a,s,o):s&&(r=r||{},r[a]=s)}}),r}var Tn={};Object.defineProperty(Tn,"__esModule",{value:!0}),Tn.camelCase=void 0;var Yp=/^--[a-zA-Z0-9_-]+$/,qp=/-([a-z])/g,Kp=/^[^-]+$/,Xp=/^-(webkit|moz|ms|o|khtml)-/,Jp=/^-(ms)-/,Zp=function(e){return!e||Kp.test(e)||Yp.test(e)},Qp=function(e,t){return t.toUpperCase()},Bs=function(e,t){return"".concat(t,"-")},eh=function(e,t){return t===void 0&&(t={}),Zp(e)?e:(e=e.toLowerCase(),t.reactCompat?e=e.replace(Jp,Bs):e=e.replace(Xp,Bs),e.replace(qp,Qp))};Tn.camelCase=eh;var th=Ce&&Ce.__importDefault||function(e){return e&&e.__esModule?e:{default:e}},rh=th(lo),nh=Tn;function uo(e,t){var r={};return!e||typeof e!="string"||(0,rh.default)(e,function(n,i){n&&i&&(r[(0,nh.camelCase)(n,t)]=i)}),r}uo.default=uo;var ih=uo;(function(e){var t=Ce&&Ce.__importDefault||function(f){return f&&f.__esModule?f:{default:f}};Object.defineProperty(e,"__esModule",{value:!0}),e.returnFirstArg=e.canTextBeChildOfNode=e.ELEMENTS_WITH_NO_TEXT_CHILDREN=e.PRESERVE_CUSTOM_ATTRIBUTES=void 0,e.isCustomComponent=o,e.setStyleProp=s;var r=_,n=t(ih),i=new Set(["annotation-xml","color-profile","font-face","font-face-src","font-face-uri","font-face-format","font-face-name","missing-glyph"]);function o(f,c){return f.includes("-")?!i.has(f):!!(c&&typeof c.is=="string")}var a={reactCompat:!0};function s(f,c){if(typeof f=="string"){if(!f.trim()){c.style={};return}try{c.style=(0,n.default)(f,a)}catch{c.style={}}}}e.PRESERVE_CUSTOM_ATTRIBUTES=Number(r.version.split(".")[0])>=16,e.ELEMENTS_WITH_NO_TEXT_CHILDREN=new Set(["tr","tbody","thead","tfoot","colgroup","table","head","html","frameset"]);var l=function(f){return!e.ELEMENTS_WITH_NO_TEXT_CHILDREN.has(f.name)};e.canTextBeChildOfNode=l;var u=function(f){return f};e.returnFirstArg=u})(so),Object.defineProperty(yn,"__esModule",{value:!0}),yn.default=lh;var wr=lt,Us=so,oh=["checked","value"],ah=["input","select","textarea"],sh={reset:!0,submit:!0};function lh(e,t){e===void 0&&(e={});var r={},n=!!(e.type&&sh[e.type]);for(var i in e){var o=e[i];if((0,wr.isCustomAttribute)(i)){r[i]=o;continue}var a=i.toLowerCase(),s=Vs(a);if(s){var l=(0,wr.getPropertyInfo)(s);switch(oh.includes(s)&&ah.includes(t)&&!n&&(s=Vs("default"+a)),r[s]=o,l&&l.type){case wr.BOOLEAN:r[s]=!0;break;case wr.OVERLOADED_BOOLEAN:o===""&&(r[s]=!0);break}continue}Us.PRESERVE_CUSTOM_ATTRIBUTES&&(r[i]=o)}return(0,Us.setStyleProp)(e.style,r),r}function Vs(e){return wr.possibleStandardNames[e]}var co={},uh=Ce&&Ce.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(co,"__esModule",{value:!0}),co.default=Ws;var fo=_,ch=uh(yn),Ar=so,fh={cloneElement:fo.cloneElement,createElement:fo.createElement,isValidElement:fo.isValidElement};function Ws(e,t){t===void 0&&(t={});for(var r=[],n=typeof t.replace=="function",i=t.transform||Ar.returnFirstArg,o=t.library||fh,a=o.cloneElement,s=o.createElement,l=o.isValidElement,u=e.length,f=0;f<u;f++){var c=e[f];if(n){var p=t.replace(c,f);if(l(p)){u>1&&(p=a(p,{key:p.key||f})),r.push(i(p,c,f));continue}}if(c.type==="text"){var v=!c.data.trim().length;if(v&&c.parent&&!(0,Ar.canTextBeChildOfNode)(c.parent)||t.trim&&v)continue;r.push(i(c.data,c,f));continue}var m=c,y={};dh(m)?((0,Ar.setStyleProp)(m.attribs.style,m.attribs),y=m.attribs):m.attribs&&(y=(0,ch.default)(m.attribs,m.name));var T=void 0;switch(c.type){case"script":case"style":c.children[0]&&(y.dangerouslySetInnerHTML={__html:c.children[0].data});break;case"tag":c.name==="textarea"&&c.children[0]?y.defaultValue=c.children[0].data:c.children&&c.children.length&&(T=Ws(c.children,t));break;default:continue}u>1&&(y.key=f),r.push(i(s(c.name,y,T),c,f))}return r.length===1?r[0]:r}function dh(e){return Ar.PRESERVE_CUSTOM_ATTRIBUTES&&e.type==="tag"&&(0,Ar.isCustomComponent)(e.name,e.attribs)}(function(e){var t=Ce&&Ce.__importDefault||function(l){return l&&l.__esModule?l:{default:l}};Object.defineProperty(e,"__esModule",{value:!0}),e.htmlToDOM=e.domToReact=e.attributesToProps=e.Text=e.ProcessingInstruction=e.Element=e.Comment=void 0,e.default=s;var r=t(Ki);e.htmlToDOM=r.default;var n=t(yn);e.attributesToProps=n.default;var i=t(co);e.domToReact=i.default;var o=Qi;Object.defineProperty(e,"Comment",{enumerable:!0,get:function(){return o.Comment}}),Object.defineProperty(e,"Element",{enumerable:!0,get:function(){return o.Element}}),Object.defineProperty(e,"ProcessingInstruction",{enumerable:!0,get:function(){return o.ProcessingInstruction}}),Object.defineProperty(e,"Text",{enumerable:!0,get:function(){return o.Text}});var a={lowerCaseAttributeNames:!1};function s(l,u){if(typeof l!="string")throw new TypeError("First argument must be a string");return l?(0,i.default)((0,r.default)(l,(u==null?void 0:u.htmlparser2)||a),u):[]}})(ds);const Hs=yt(ds);Hs.default;/*! @license DOMPurify 3.1.7 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.1.7/LICENSE */const{entries:Gs,setPrototypeOf:Ys,isFrozen:ph,getPrototypeOf:hh,getOwnPropertyDescriptor:mh}=Object;let{freeze:Ve,seal:nt,create:qs}=Object,{apply:po,construct:ho}=typeof Reflect<"u"&&Reflect;Ve||(Ve=function(t){return t}),nt||(nt=function(t){return t}),po||(po=function(t,r,n){return t.apply(r,n)}),ho||(ho=function(t,r){return new t(...r)});const _n=Qe(Array.prototype.forEach),Ks=Qe(Array.prototype.pop),Or=Qe(Array.prototype.push),Sn=Qe(String.prototype.toLowerCase),mo=Qe(String.prototype.toString),Xs=Qe(String.prototype.match),kr=Qe(String.prototype.replace),gh=Qe(String.prototype.indexOf),yh=Qe(String.prototype.trim),ut=Qe(Object.prototype.hasOwnProperty),We=Qe(RegExp.prototype.test),Pr=vh(TypeError);function Qe(e){return function(t){for(var r=arguments.length,n=new Array(r>1?r-1:0),i=1;i<r;i++)n[i-1]=arguments[i];return po(e,t,n)}}function vh(e){return function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return ho(e,r)}}function se(e,t){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:Sn;Ys&&Ys(e,null);let n=t.length;for(;n--;){let i=t[n];if(typeof i=="string"){const o=r(i);o!==i&&(ph(t)||(t[n]=o),i=o)}e[i]=!0}return e}function bh(e){for(let t=0;t<e.length;t++)ut(e,t)||(e[t]=null);return e}function Vt(e){const t=qs(null);for(const[r,n]of Gs(e))ut(e,r)&&(Array.isArray(n)?t[r]=bh(n):n&&typeof n=="object"&&n.constructor===Object?t[r]=Vt(n):t[r]=n);return t}function jr(e,t){for(;e!==null;){const n=mh(e,t);if(n){if(n.get)return Qe(n.get);if(typeof n.value=="function")return Qe(n.value)}e=hh(e)}function r(){return null}return r}const Js=Ve(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","section","select","shadow","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),go=Ve(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","filter","font","g","glyph","glyphref","hkern","image","line","lineargradient","marker","mask","metadata","mpath","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),yo=Ve(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),xh=Ve(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),vo=Ve(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),Th=Ve(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Zs=Ve(["#text"]),Qs=Ve(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","face","for","headers","height","hidden","high","href","hreflang","id","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns","slot"]),bo=Ve(["accent-height","accumulate","additive","alignment-baseline","amplitude","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","exponent","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","intercept","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","slope","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","tablevalues","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),el=Ve(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),En=Ve(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),_h=nt(/\{\{[\w\W]*|[\w\W]*\}\}/gm),Sh=nt(/<%[\w\W]*|[\w\W]*%>/gm),Eh=nt(/\${[\w\W]*}/gm),Ch=nt(/^data-[\-\w.\u00B7-\uFFFF]/),wh=nt(/^aria-[\-\w]+$/),tl=nt(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),Ah=nt(/^(?:\w+script|data):/i),Oh=nt(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),rl=nt(/^html$/i),kh=nt(/^[a-z][.\w]*(-[.\w]+)+$/i);var nl=Object.freeze({__proto__:null,MUSTACHE_EXPR:_h,ERB_EXPR:Sh,TMPLIT_EXPR:Eh,DATA_ATTR:Ch,ARIA_ATTR:wh,IS_ALLOWED_URI:tl,IS_SCRIPT_OR_DATA:Ah,ATTR_WHITESPACE:Oh,DOCTYPE_NAME:rl,CUSTOM_ELEMENT:kh});const Ir={element:1,attribute:2,text:3,cdataSection:4,entityReference:5,entityNode:6,progressingInstruction:7,comment:8,document:9,documentType:10,documentFragment:11,notation:12},Ph=function(){return typeof window>"u"?null:window},jh=function(t,r){if(typeof t!="object"||typeof t.createPolicy!="function")return null;let n=null;const i="data-tt-policy-suffix";r&&r.hasAttribute(i)&&(n=r.getAttribute(i));const o="dompurify"+(n?"#"+n:"");try{return t.createPolicy(o,{createHTML(a){return a},createScriptURL(a){return a}})}catch{return console.warn("TrustedTypes policy "+o+" could not be created."),null}};function il(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Ph();const t=P=>il(P);if(t.version="3.1.7",t.removed=[],!e||!e.document||e.document.nodeType!==Ir.document)return t.isSupported=!1,t;let{document:r}=e;const n=r,i=n.currentScript,{DocumentFragment:o,HTMLTemplateElement:a,Node:s,Element:l,NodeFilter:u,NamedNodeMap:f=e.NamedNodeMap||e.MozNamedAttrMap,HTMLFormElement:c,DOMParser:p,trustedTypes:v}=e,m=l.prototype,y=jr(m,"cloneNode"),T=jr(m,"remove"),j=jr(m,"nextSibling"),F=jr(m,"childNodes"),D=jr(m,"parentNode");if(typeof a=="function"){const P=r.createElement("template");P.content&&P.content.ownerDocument&&(r=P.content.ownerDocument)}let O,S="";const{implementation:M,createNodeIterator:Y,createDocumentFragment:ce,getElementsByTagName:ie}=r,{importNode:h}=n;let A={};t.isSupported=typeof Gs=="function"&&typeof D=="function"&&M&&M.createHTMLDocument!==void 0;const{MUSTACHE_EXPR:U,ERB_EXPR:H,TMPLIT_EXPR:te,DATA_ATTR:ve,ARIA_ATTR:G,IS_SCRIPT_OR_DATA:oe,ATTR_WHITESPACE:le,CUSTOM_ELEMENT:He}=nl;let{IS_ALLOWED_URI:k}=nl,$=null;const Z=se({},[...Js,...go,...yo,...vo,...Zs]);let B=null;const X=se({},[...Qs,...bo,...el,...En]);let V=Object.seal(qs(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),q=null,J=null,Q=!0,re=!0,ee=!1,Ie=!0,N=!1,Me=!0,z=!1,Ge=!1,Ke=!1,at=!1,Yt=!1,St=!1,ri=!0,ni=!1;const Wr="user-content-";let Hr=!0,qt=!1,Et={},Ct=null;const Mt=se({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let ii=null;const Gr=se({},["audio","video","img","source","image","track"]);let gr=null;const yr=se({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),vr="http://www.w3.org/1998/Math/MathML",br="http://www.w3.org/2000/svg",ft="http://www.w3.org/1999/xhtml";let Rt=ft,Yr=!1,qr=null;const da=se({},[vr,br,ft],mo);let wt=null;const oi=["application/xhtml+xml","text/html"],Nt="text/html";let Pe=null,gt=null;const ai=r.createElement("form"),si=function(x){return x instanceof RegExp||x instanceof Function},xr=function(){let x=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!(gt&>===x)){if((!x||typeof x!="object")&&(x={}),x=Vt(x),wt=oi.indexOf(x.PARSER_MEDIA_TYPE)===-1?Nt:x.PARSER_MEDIA_TYPE,Pe=wt==="application/xhtml+xml"?mo:Sn,$=ut(x,"ALLOWED_TAGS")?se({},x.ALLOWED_TAGS,Pe):Z,B=ut(x,"ALLOWED_ATTR")?se({},x.ALLOWED_ATTR,Pe):X,qr=ut(x,"ALLOWED_NAMESPACES")?se({},x.ALLOWED_NAMESPACES,mo):da,gr=ut(x,"ADD_URI_SAFE_ATTR")?se(Vt(yr),x.ADD_URI_SAFE_ATTR,Pe):yr,ii=ut(x,"ADD_DATA_URI_TAGS")?se(Vt(Gr),x.ADD_DATA_URI_TAGS,Pe):Gr,Ct=ut(x,"FORBID_CONTENTS")?se({},x.FORBID_CONTENTS,Pe):Mt,q=ut(x,"FORBID_TAGS")?se({},x.FORBID_TAGS,Pe):{},J=ut(x,"FORBID_ATTR")?se({},x.FORBID_ATTR,Pe):{},Et=ut(x,"USE_PROFILES")?x.USE_PROFILES:!1,Q=x.ALLOW_ARIA_ATTR!==!1,re=x.ALLOW_DATA_ATTR!==!1,ee=x.ALLOW_UNKNOWN_PROTOCOLS||!1,Ie=x.ALLOW_SELF_CLOSE_IN_ATTR!==!1,N=x.SAFE_FOR_TEMPLATES||!1,Me=x.SAFE_FOR_XML!==!1,z=x.WHOLE_DOCUMENT||!1,at=x.RETURN_DOM||!1,Yt=x.RETURN_DOM_FRAGMENT||!1,St=x.RETURN_TRUSTED_TYPE||!1,Ke=x.FORCE_BODY||!1,ri=x.SANITIZE_DOM!==!1,ni=x.SANITIZE_NAMED_PROPS||!1,Hr=x.KEEP_CONTENT!==!1,qt=x.IN_PLACE||!1,k=x.ALLOWED_URI_REGEXP||tl,Rt=x.NAMESPACE||ft,V=x.CUSTOM_ELEMENT_HANDLING||{},x.CUSTOM_ELEMENT_HANDLING&&si(x.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(V.tagNameCheck=x.CUSTOM_ELEMENT_HANDLING.tagNameCheck),x.CUSTOM_ELEMENT_HANDLING&&si(x.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(V.attributeNameCheck=x.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),x.CUSTOM_ELEMENT_HANDLING&&typeof x.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(V.allowCustomizedBuiltInElements=x.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),N&&(re=!1),Yt&&(at=!0),Et&&($=se({},Zs),B=[],Et.html===!0&&(se($,Js),se(B,Qs)),Et.svg===!0&&(se($,go),se(B,bo),se(B,En)),Et.svgFilters===!0&&(se($,yo),se(B,bo),se(B,En)),Et.mathMl===!0&&(se($,vo),se(B,el),se(B,En))),x.ADD_TAGS&&($===Z&&($=Vt($)),se($,x.ADD_TAGS,Pe)),x.ADD_ATTR&&(B===X&&(B=Vt(B)),se(B,x.ADD_ATTR,Pe)),x.ADD_URI_SAFE_ATTR&&se(gr,x.ADD_URI_SAFE_ATTR,Pe),x.FORBID_CONTENTS&&(Ct===Mt&&(Ct=Vt(Ct)),se(Ct,x.FORBID_CONTENTS,Pe)),Hr&&($["#text"]=!0),z&&se($,["html","head","body"]),$.table&&(se($,["tbody"]),delete q.tbody),x.TRUSTED_TYPES_POLICY){if(typeof x.TRUSTED_TYPES_POLICY.createHTML!="function")throw Pr('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof x.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw Pr('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');O=x.TRUSTED_TYPES_POLICY,S=O.createHTML("")}else O===void 0&&(O=jh(v,i)),O!==null&&typeof S=="string"&&(S=O.createHTML(""));Ve&&Ve(x),gt=x}},li=se({},["mi","mo","mn","ms","mtext"]),Kr=se({},["annotation-xml"]),ui=se({},["title","style","font","a","script"]),ci=se({},[...go,...yo,...xh]),fi=se({},[...vo,...Th]),di=function(x){let C=D(x);(!C||!C.tagName)&&(C={namespaceURI:Rt,tagName:"template"});const R=Sn(x.tagName),ne=Sn(C.tagName);return qr[x.namespaceURI]?x.namespaceURI===br?C.namespaceURI===ft?R==="svg":C.namespaceURI===vr?R==="svg"&&(ne==="annotation-xml"||li[ne]):!!ci[R]:x.namespaceURI===vr?C.namespaceURI===ft?R==="math":C.namespaceURI===br?R==="math"&&Kr[ne]:!!fi[R]:x.namespaceURI===ft?C.namespaceURI===br&&!Kr[ne]||C.namespaceURI===vr&&!li[ne]?!1:!fi[R]&&(ui[R]||!ci[R]):!!(wt==="application/xhtml+xml"&&qr[x.namespaceURI]):!1},rt=function(x){Or(t.removed,{element:x});try{D(x).removeChild(x)}catch{T(x)}},Tr=function(x,C){try{Or(t.removed,{attribute:C.getAttributeNode(x),from:C})}catch{Or(t.removed,{attribute:null,from:C})}if(C.removeAttribute(x),x==="is"&&!B[x])if(at||Yt)try{rt(C)}catch{}else try{C.setAttribute(x,"")}catch{}},pi=function(x){let C=null,R=null;if(Ke)x="<remove></remove>"+x;else{const Ee=Xs(x,/^[\r\n\t ]+/);R=Ee&&Ee[0]}wt==="application/xhtml+xml"&&Rt===ft&&(x='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+x+"</body></html>");const ne=O?O.createHTML(x):x;if(Rt===ft)try{C=new p().parseFromString(ne,wt)}catch{}if(!C||!C.documentElement){C=M.createDocument(Rt,"template",null);try{C.documentElement.innerHTML=Yr?S:ne}catch{}}const Ae=C.body||C.documentElement;return x&&R&&Ae.insertBefore(r.createTextNode(R),Ae.childNodes[0]||null),Rt===ft?ie.call(C,z?"html":"body")[0]:z?C.documentElement:Ae},hi=function(x){return Y.call(x.ownerDocument||x,x,u.SHOW_ELEMENT|u.SHOW_COMMENT|u.SHOW_TEXT|u.SHOW_PROCESSING_INSTRUCTION|u.SHOW_CDATA_SECTION,null)},mi=function(x){return x instanceof c&&(typeof x.nodeName!="string"||typeof x.textContent!="string"||typeof x.removeChild!="function"||!(x.attributes instanceof f)||typeof x.removeAttribute!="function"||typeof x.setAttribute!="function"||typeof x.namespaceURI!="string"||typeof x.insertBefore!="function"||typeof x.hasChildNodes!="function")},g=function(x){return typeof s=="function"&&x instanceof s},w=function(x,C,R){A[x]&&_n(A[x],ne=>{ne.call(t,C,R,gt)})},L=function(x){let C=null;if(w("beforeSanitizeElements",x,null),mi(x))return rt(x),!0;const R=Pe(x.nodeName);if(w("uponSanitizeElement",x,{tagName:R,allowedTags:$}),x.hasChildNodes()&&!g(x.firstElementChild)&&We(/<[/\w]/g,x.innerHTML)&&We(/<[/\w]/g,x.textContent)||x.nodeType===Ir.progressingInstruction||Me&&x.nodeType===Ir.comment&&We(/<[/\w]/g,x.data))return rt(x),!0;if(!$[R]||q[R]){if(!q[R]&&fe(R)&&(V.tagNameCheck instanceof RegExp&&We(V.tagNameCheck,R)||V.tagNameCheck instanceof Function&&V.tagNameCheck(R)))return!1;if(Hr&&!Ct[R]){const ne=D(x)||x.parentNode,Ae=F(x)||x.childNodes;if(Ae&&ne){const Ee=Ae.length;for(let be=Ee-1;be>=0;--be){const Xe=y(Ae[be],!0);Xe.__removalCount=(x.__removalCount||0)+1,ne.insertBefore(Xe,j(x))}}}return rt(x),!0}return x instanceof l&&!di(x)||(R==="noscript"||R==="noembed"||R==="noframes")&&We(/<\/no(script|embed|frames)/i,x.innerHTML)?(rt(x),!0):(N&&x.nodeType===Ir.text&&(C=x.textContent,_n([U,H,te],ne=>{C=kr(C,ne," ")}),x.textContent!==C&&(Or(t.removed,{element:x.cloneNode()}),x.textContent=C)),w("afterSanitizeElements",x,null),!1)},K=function(x,C,R){if(ri&&(C==="id"||C==="name")&&(R in r||R in ai))return!1;if(!(re&&!J[C]&&We(ve,C))){if(!(Q&&We(G,C))){if(!B[C]||J[C]){if(!(fe(x)&&(V.tagNameCheck instanceof RegExp&&We(V.tagNameCheck,x)||V.tagNameCheck instanceof Function&&V.tagNameCheck(x))&&(V.attributeNameCheck instanceof RegExp&&We(V.attributeNameCheck,C)||V.attributeNameCheck instanceof Function&&V.attributeNameCheck(C))||C==="is"&&V.allowCustomizedBuiltInElements&&(V.tagNameCheck instanceof RegExp&&We(V.tagNameCheck,R)||V.tagNameCheck instanceof Function&&V.tagNameCheck(R))))return!1}else if(!gr[C]){if(!We(k,kr(R,le,""))){if(!((C==="src"||C==="xlink:href"||C==="href")&&x!=="script"&&gh(R,"data:")===0&&ii[x])){if(!(ee&&!We(oe,kr(R,le,"")))){if(R)return!1}}}}}}return!0},fe=function(x){return x!=="annotation-xml"&&Xs(x,He)},ye=function(x){w("beforeSanitizeAttributes",x,null);const{attributes:C}=x;if(!C)return;const R={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:B};let ne=C.length;for(;ne--;){const Ae=C[ne],{name:Ee,namespaceURI:be,value:Xe}=Ae,Kt=Pe(Ee);let Ne=Ee==="value"?Xe:yh(Xe);if(R.attrName=Kt,R.attrValue=Ne,R.keepAttr=!0,R.forceKeepAttr=void 0,w("uponSanitizeAttribute",x,R),Ne=R.attrValue,R.forceKeepAttr||(Tr(Ee,x),!R.keepAttr))continue;if(!Ie&&We(/\/>/i,Ne)){Tr(Ee,x);continue}N&&_n([U,H,te],Pf=>{Ne=kr(Ne,Pf," ")});const kf=Pe(x.nodeName);if(K(kf,Kt,Ne)){if(ni&&(Kt==="id"||Kt==="name")&&(Tr(Ee,x),Ne=Wr+Ne),Me&&We(/((--!?|])>)|<\/(style|title)/i,Ne)){Tr(Ee,x);continue}if(O&&typeof v=="object"&&typeof v.getAttributeType=="function"&&!be)switch(v.getAttributeType(kf,Kt)){case"TrustedHTML":{Ne=O.createHTML(Ne);break}case"TrustedScriptURL":{Ne=O.createScriptURL(Ne);break}}try{be?x.setAttributeNS(be,Ee,Ne):x.setAttribute(Ee,Ne),mi(x)?rt(x):Ks(t.removed)}catch{}}}w("afterSanitizeAttributes",x,null)},ue=function P(x){let C=null;const R=hi(x);for(w("beforeSanitizeShadowDOM",x,null);C=R.nextNode();)w("uponSanitizeShadowNode",C,null),!L(C)&&(C.content instanceof o&&P(C.content),ye(C));w("afterSanitizeShadowDOM",x,null)};return t.sanitize=function(P){let x=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},C=null,R=null,ne=null,Ae=null;if(Yr=!P,Yr&&(P="<!-->"),typeof P!="string"&&!g(P))if(typeof P.toString=="function"){if(P=P.toString(),typeof P!="string")throw Pr("dirty is not a string, aborting")}else throw Pr("toString is not a function");if(!t.isSupported)return P;if(Ge||xr(x),t.removed=[],typeof P=="string"&&(qt=!1),qt){if(P.nodeName){const Xe=Pe(P.nodeName);if(!$[Xe]||q[Xe])throw Pr("root node is forbidden and cannot be sanitized in-place")}}else if(P instanceof s)C=pi("<!---->"),R=C.ownerDocument.importNode(P,!0),R.nodeType===Ir.element&&R.nodeName==="BODY"||R.nodeName==="HTML"?C=R:C.appendChild(R);else{if(!at&&!N&&!z&&P.indexOf("<")===-1)return O&&St?O.createHTML(P):P;if(C=pi(P),!C)return at?null:St?S:""}C&&Ke&&rt(C.firstChild);const Ee=hi(qt?P:C);for(;ne=Ee.nextNode();)L(ne)||(ne.content instanceof o&&ue(ne.content),ye(ne));if(qt)return P;if(at){if(Yt)for(Ae=ce.call(C.ownerDocument);C.firstChild;)Ae.appendChild(C.firstChild);else Ae=C;return(B.shadowroot||B.shadowrootmode)&&(Ae=h.call(n,Ae,!0)),Ae}let be=z?C.outerHTML:C.innerHTML;return z&&$["!doctype"]&&C.ownerDocument&&C.ownerDocument.doctype&&C.ownerDocument.doctype.name&&We(rl,C.ownerDocument.doctype.name)&&(be="<!DOCTYPE "+C.ownerDocument.doctype.name+`>
|
|
120
|
-
`+be),N&&_n([U,H,te],Xe=>{be=kr(be,Xe," ")}),O&&St?O.createHTML(be):be},t.setConfig=function(){let P=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};xr(P),Ge=!0},t.clearConfig=function(){gt=null,Ge=!1},t.isValidAttribute=function(P,x,C){gt||xr({});const R=Pe(P),ne=Pe(x);return K(R,ne,C)},t.addHook=function(P,x){typeof x=="function"&&(A[P]=A[P]||[],Or(A[P],x))},t.removeHook=function(P){if(A[P])return Ks(A[P])},t.removeHooks=function(P){A[P]&&(A[P]=[])},t.removeAllHooks=function(){A={}},t}var Ih=il();const $h={field:"_field_zdaf7_1",rtl:"_rtl_zdaf7_7",borderRight:"_borderRight_zdaf7_12"},Cn=_.memo(({id:e,entry:t,loading:r,rightBorder:n,children:i,onClickEntry:o,customElement:a,sanitize:s,...l})=>{const u={text:{style:{whiteSpace:"nowrap",overflow:"ellipsis"}}},{text:f}=b.useProps("Field",u,l),c={};Object.entries(f).forEach(([m,y])=>{typeof y=="function"&&(c[m]=y(t))});let p;s&&(p=Ih.sanitize(i));const v=b.useStyles({name:"Field",props:l,classes:$h});return d.jsx(b.Table.Td,{...v("field"),onClick:o?()=>o(e,t):null,...l,children:d.jsx(b.Box,{w:"100%",children:d.jsx(b.Skeleton,{visible:r,children:a||(typeof i!="object"?d.jsx(b.Text,{...f,...c,children:p||i}):p||i)})})})});Cn.displayName="Field";const ol={row:"_row_138r2_1",selected:"_selected_138r2_5"};function Dh({entry:e,selected:t,children:r}){const n=b.useStyles({name:"Row",classes:ol}),i=b.useProps("Row",{},{});Object.entries(i).forEach(([s,l])=>{typeof l=="function"&&(i[s]=l(e))});var{className:o,style:a}=n("row");return o=`${o} ${t?ol.selected:""}`,d.jsx(b.Table.Tr,{className:o,style:{...a},...i,children:r})}function Mh({bodyCustomizer:e,actionColumn:t,id:r,entry:n}){let i=e==null?void 0:e[t];return typeof i=="function"&&(i=i({id:r,...n})),i===null?null:i||d.jsx(fs,{id:r})}function Rh({data:e,loading:t,hideActions:r,hideCheckbox:n,selection:i,toggleRow:o,onClickEntry:a,bodyCustomizer:s}){const l=e.list_columns.includes("actions")?"_actions":"actions";return d.jsx(b.Table.Tbody,{children:e.result.length?e.result.map((u,f)=>{const c=e.ids[f];return d.jsxs(Dh,{entry:{...u,id:c},children:[n?null:d.jsx(Cn,{loading:t,children:d.jsx(b.Checkbox,{pl:2,checked:i.includes(c),onChange:p=>{o(c)}})},f),r?null:d.jsx(Cn,{loading:t,children:d.jsx(Mh,{bodyCustomizer:s,actionColumn:l,id:Ze(c),entry:u})}),e.list_columns.map((p,v)=>{let m=s==null?void 0:s[p];return typeof m=="function"&&(m=m({id:c,...u})),m===null?null:d.jsx(Cn,{id:c,entry:u,loading:t,onClickEntry:a,customElement:m,sanitize:!0,children:qi(u,p)},v)})]},Ze(c))}):d.jsx("tr",{children:d.jsx("td",{style:{padding:"8px"},colSpan:r?e.list_columns.length:e.list_columns.length+1,children:d.jsx(b.Text,{style:{fontStyle:"italic"},size:"sm",c:"dimmed",children:"No data available..."})})})})}const Nh={scrollbar:"_scrollbar_isyo2_1"};function Fh({bulkActions:e,hideActions:t,loading:r,onSelectCheckbox:n,onClickEntry:i,hideCheckbox:o,hideDownload:a,headerCustomizer:s,bodyCustomizer:l,...u}){const f=b.useMantineTheme(),c=b.Table.extend({highlightOnHover:!0,striped:!0,horizontalSpacing:"md",verticalSpacing:"sm"}),p=b.useProps("DatagridTable",c,u),{data:v,info:m}=De(),[y,T]=_.useState([]),[j,F]=_.useState(!1),D=S=>{T(M=>M.includes(S)?M.filter(Y=>Y!==S):[...M,S])},O=()=>{T(S=>S.length===v.ids.length?[]:v.ids.map((M,Y)=>M))};return _.useEffect(()=>{F(y.length===v.result.length&&y.length>0),n&&n(y),e==null||e.setSelectedIds(y.map(S=>S))},[y]),_.useEffect(()=>{T([]),n&&n([])},[v]),d.jsx(b.ScrollArea,{options:{className:f.colorScheme==="dark"?"os-theme-light":void 0},style:{flex:1,flexDirection:"column"},classNames:Nh,children:d.jsxs(b.Table,{stickyHeader:!0,...p,children:[d.jsx(os,{data:v,info:m,hideActions:t,hideCheckbox:o,allChecked:j,setSelection:T,toggleAll:O,headerCustomizer:s}),d.jsx(Rh,{data:v,loading:r,hideActions:t,hideCheckbox:o,selection:y,setSelection:T,toggleRow:D,onClickEntry:i,bodyCustomizer:l})]})})}const al=_.memo(({...e})=>{const{data:t,queryParams:r,setQueryParams:n}=De(),i=[{value:"10",label:"10"},{value:"25",label:"25"},{value:"50",label:"50"}],o=String(r.page_size),[a,s]=_.useState(r.page);_.useEffect(()=>{s(r.page)},[r.page]);const l=f=>{s(f-1),n({page:f-1})},u=f=>{n({page_size:parseInt(f,10),page:0})};return d.jsxs(d.Fragment,{children:[d.jsx(b.Divider,{}),d.jsxs(b.Box,{style:{display:"flex",justifyContent:"space-between",alignItems:"center",height:54,border:"none",borderTopWidth:"1px",padding:"var(--mantine-spacing-md)"},children:[d.jsxs(b.Box,{style:{display:"flex",alignItems:"center",gap:"var(--mantine-spacing-sm)"},children:[d.jsx(b.Text,{children:"Rows per page:"}),d.jsx(b.Select,{value:o,defaultValue:o,onChange:f=>u(f),data:i,allowDeselect:!1,w:80,size:"xs",styles:()=>({input:{fontSize:"14px",fontWeight:"250",lineHeight:"52px",border:"1px solid #E6E8ED"},item:{"&[data-selected]":{"&, &:hover":{outline:"none !important"}}}})})]}),d.jsx(b.Pagination,{size:"sm",total:Math.ceil(t.count/o),value:a+1,onChange:l,...e})]})]})});al.displayName="Pagination";function Lh(){const{error:e}=De(),[t,r]=_.useState(!1);return _.useEffect(()=>{e&&r(!0)},[e]),d.jsx(b.Modal,{opened:t,onClose:()=>r(!1),title:d.jsxs(b.Group,{children:[d.jsx(Hd,{size:16,color:"red"}),d.jsx(b.Text,{children:e?e.originalError.detail||e.originalError.message:"Error"})]}),centered:!0,children:e?d.jsx(b.Text,{children:e.message}):null})}const xo=_.forwardRef((e,t)=>{const{path:r,data:n,loading:i,info:o,setQueryParams:a}=De(),{hideToolbar:s=!1,hideFilter:l=!1,hideAdd:u=!1,hideSettings:f=!1,hideActions:c=!1,hidePagination:p=!1,hideError:v=!1,hideDownload:m=!0,onSelectCheckbox:y=null,onClickEntry:T=null,fetchOnMount:j=!0,bulkActions:F=null,styles:D,headerCustomizer:O={},bodyCustomizer:S={},toolbarCustomizer:M={}}=e;if(_.useEffect(()=>{!n&&j&&a({})},[n]),!o)return;const Y=F===null;return d.jsxs(b.Paper,{ref:t,style:{position:"relative",height:"100%",display:"flex",flexDirection:"column",...D},children:[s?null:d.jsx(ns,{hideFilter:l,hideAdd:u,hideSettings:f,hideDownload:m,toolbarCustomizer:M}),n?d.jsx(Fh,{bulkActions:F,hideActions:c,loading:i,onSelectCheckbox:y,onClickEntry:T,hideCheckbox:Y,hideDownload:m,headerCustomizer:O,bodyCustomizer:S}):null,!p&&n?d.jsx(al,{}):null,v?null:d.jsx(Lh,{})]})});xo.displayName="DataGrid";function zh({children:e,fetch:t=!0,loading:r=d.jsx(b.Center,{children:d.jsx(b.Loader,{})}),end:n=d.jsx(b.Center,{children:"End of data"}),fetchWrapper:i=b.Center,fetchWrapperProps:o}){const{streaming:a,loading:s}=De(),{ref:l,inViewport:u}=At.useInViewport(),f=_.useMemo(()=>Object.values(a.data).flat(),[a.data]),c=_.useMemo(()=>typeof e=="function"?e(f):e,[e,f]);return _.useEffect(()=>{u&&t&&a.fetch()},[u]),d.jsxs(d.Fragment,{children:[c,s&&r,a.isEnd&&n,d.jsx(i,{ref:l,id:"IS-load-trigger",mih:"1%",...o})]})}var Bh=Object.prototype;function Uh(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||Bh;return e===r}var wn=Uh;function Vh(e,t){return function(r){return e(t(r))}}var sl=Vh,Wh=sl,Hh=Wh(Object.keys,Object),Gh=Hh,Yh=wn,qh=Gh,Kh=Object.prototype,Xh=Kh.hasOwnProperty;function Jh(e){if(!Yh(e))return qh(e);var t=[];for(var r in Object(e))Xh.call(e,r)&&r!="constructor"&&t.push(r);return t}var Zh=Jh,Qh=typeof Ce=="object"&&Ce&&Ce.Object===Object&&Ce,ll=Qh,em=ll,tm=typeof self=="object"&&self&&self.Object===Object&&self,rm=em||tm||Function("return this")(),ct=rm,nm=ct,im=nm.Symbol,An=im,ul=An,cl=Object.prototype,om=cl.hasOwnProperty,am=cl.toString,$r=ul?ul.toStringTag:void 0;function sm(e){var t=om.call(e,$r),r=e[$r];try{e[$r]=void 0;var n=!0}catch{}var i=am.call(e);return n&&(t?e[$r]=r:delete e[$r]),i}var lm=sm,um=Object.prototype,cm=um.toString;function fm(e){return cm.call(e)}var dm=fm,fl=An,pm=lm,hm=dm,mm="[object Null]",gm="[object Undefined]",dl=fl?fl.toStringTag:void 0;function ym(e){return e==null?e===void 0?gm:mm:dl&&dl in Object(e)?pm(e):hm(e)}var er=ym;function vm(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var bt=vm,bm=er,xm=bt,Tm="[object AsyncFunction]",_m="[object Function]",Sm="[object GeneratorFunction]",Em="[object Proxy]";function Cm(e){if(!xm(e))return!1;var t=bm(e);return t==_m||t==Sm||t==Tm||t==Em}var To=Cm,wm=ct,Am=wm["__core-js_shared__"],Om=Am,_o=Om,pl=function(){var e=/[^.]+$/.exec(_o&&_o.keys&&_o.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function km(e){return!!pl&&pl in e}var Pm=km,jm=Function.prototype,Im=jm.toString;function $m(e){if(e!=null){try{return Im.call(e)}catch{}try{return e+""}catch{}}return""}var hl=$m,Dm=To,Mm=Pm,Rm=bt,Nm=hl,Fm=/[\\^$.*+?()[\]{}|]/g,Lm=/^\[object .+?Constructor\]$/,zm=Function.prototype,Bm=Object.prototype,Um=zm.toString,Vm=Bm.hasOwnProperty,Wm=RegExp("^"+Um.call(Vm).replace(Fm,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Hm(e){if(!Rm(e)||Mm(e))return!1;var t=Dm(e)?Wm:Lm;return t.test(Nm(e))}var Gm=Hm;function Ym(e,t){return e==null?void 0:e[t]}var qm=Ym,Km=Gm,Xm=qm;function Jm(e,t){var r=Xm(e,t);return Km(r)?r:void 0}var Wt=Jm,Zm=Wt,Qm=ct,eg=Zm(Qm,"DataView"),tg=eg,rg=Wt,ng=ct,ig=rg(ng,"Map"),So=ig,og=Wt,ag=ct,sg=og(ag,"Promise"),lg=sg,ug=Wt,cg=ct,fg=ug(cg,"Set"),ml=fg,dg=Wt,pg=ct,hg=dg(pg,"WeakMap"),mg=hg,Eo=tg,Co=So,wo=lg,Ao=ml,Oo=mg,gl=er,tr=hl,yl="[object Map]",gg="[object Object]",vl="[object Promise]",bl="[object Set]",xl="[object WeakMap]",Tl="[object DataView]",yg=tr(Eo),vg=tr(Co),bg=tr(wo),xg=tr(Ao),Tg=tr(Oo),Ht=gl;(Eo&&Ht(new Eo(new ArrayBuffer(1)))!=Tl||Co&&Ht(new Co)!=yl||wo&&Ht(wo.resolve())!=vl||Ao&&Ht(new Ao)!=bl||Oo&&Ht(new Oo)!=xl)&&(Ht=function(e){var t=gl(e),r=t==gg?e.constructor:void 0,n=r?tr(r):"";if(n)switch(n){case yg:return Tl;case vg:return yl;case bg:return vl;case xg:return bl;case Tg:return xl}return t});var _g=Ht;function Sg(e){return e!=null&&typeof e=="object"}var rr=Sg,Eg=er,Cg=rr,wg="[object Arguments]";function Ag(e){return Cg(e)&&Eg(e)==wg}var Og=Ag,_l=Og,kg=rr,Sl=Object.prototype,Pg=Sl.hasOwnProperty,jg=Sl.propertyIsEnumerable,Ig=_l(function(){return arguments}())?_l:function(e){return kg(e)&&Pg.call(e,"callee")&&!jg.call(e,"callee")},On=Ig,$g=Array.isArray,Dr=$g,Dg=9007199254740991;function Mg(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=Dg}var El=Mg,Rg=To,Ng=El;function Fg(e){return e!=null&&Ng(e.length)&&!Rg(e)}var kn=Fg,Pn={exports:{}};function Lg(){return!1}var zg=Lg;Pn.exports,function(e,t){var r=ct,n=zg,i=t&&!t.nodeType&&t,o=i&&!0&&e&&!e.nodeType&&e,a=o&&o.exports===i,s=a?r.Buffer:void 0,l=s?s.isBuffer:void 0,u=l||n;e.exports=u}(Pn,Pn.exports);var ko=Pn.exports,Bg=er,Ug=El,Vg=rr,Wg="[object Arguments]",Hg="[object Array]",Gg="[object Boolean]",Yg="[object Date]",qg="[object Error]",Kg="[object Function]",Xg="[object Map]",Jg="[object Number]",Zg="[object Object]",Qg="[object RegExp]",ey="[object Set]",ty="[object String]",ry="[object WeakMap]",ny="[object ArrayBuffer]",iy="[object DataView]",oy="[object Float32Array]",ay="[object Float64Array]",sy="[object Int8Array]",ly="[object Int16Array]",uy="[object Int32Array]",cy="[object Uint8Array]",fy="[object Uint8ClampedArray]",dy="[object Uint16Array]",py="[object Uint32Array]",Se={};Se[oy]=Se[ay]=Se[sy]=Se[ly]=Se[uy]=Se[cy]=Se[fy]=Se[dy]=Se[py]=!0,Se[Wg]=Se[Hg]=Se[ny]=Se[Gg]=Se[iy]=Se[Yg]=Se[qg]=Se[Kg]=Se[Xg]=Se[Jg]=Se[Zg]=Se[Qg]=Se[ey]=Se[ty]=Se[ry]=!1;function hy(e){return Vg(e)&&Ug(e.length)&&!!Se[Bg(e)]}var my=hy;function gy(e){return function(t){return e(t)}}var yy=gy,jn={exports:{}};jn.exports,function(e,t){var r=ll,n=t&&!t.nodeType&&t,i=n&&!0&&e&&!e.nodeType&&e,o=i&&i.exports===n,a=o&&r.process,s=function(){try{var l=i&&i.require&&i.require("util").types;return l||a&&a.binding&&a.binding("util")}catch{}}();e.exports=s}(jn,jn.exports);var vy=jn.exports,by=my,xy=yy,Cl=vy,wl=Cl&&Cl.isTypedArray,Ty=wl?xy(wl):by,Po=Ty,_y=Zh,Sy=_g,Ey=On,Cy=Dr,wy=kn,Ay=ko,Oy=wn,ky=Po,Py="[object Map]",jy="[object Set]",Iy=Object.prototype,$y=Iy.hasOwnProperty;function Dy(e){if(e==null)return!0;if(wy(e)&&(Cy(e)||typeof e=="string"||typeof e.splice=="function"||Ay(e)||ky(e)||Ey(e)))return!e.length;var t=Sy(e);if(t==Py||t==jy)return!e.size;if(Oy(e))return!_y(e).length;for(var r in e)if($y.call(e,r))return!1;return!0}var My=Dy;const Al=yt(My),Ol=(e,t,r,n,i,o,a)=>e.map((s,l)=>d.jsx(b.Grid.Col,{span:i==="row"?12/e.length:12,style:{alignContent:"end"},children:d.jsx(_e.JsonFormsDispatch,{uischema:s,schema:t,path:r,enabled:n,renderers:o,cells:a})},`${r}-${l}`)),Ry=({elements:e,schema:t,path:r,enabled:n,direction:i,renderers:o,cells:a})=>Al(e)?null:d.jsx(b.Grid,{spacing:i==="row"?2:0,children:Ol(e,t,r,n,i,o,a)}),jo=_.memo(Ry),Ny=e=>function(r){const n=_e.useJsonForms(),i=W.getAjv({jsonforms:{...n}});return d.jsx(e,{...r,ajv:i})};var Fy=ct,Ly=function(){return Fy.Date.now()},zy=Ly,By=/\s/;function Uy(e){for(var t=e.length;t--&&By.test(e.charAt(t)););return t}var Vy=Uy,Wy=Vy,Hy=/^\s+/;function Gy(e){return e&&e.slice(0,Wy(e)+1).replace(Hy,"")}var Yy=Gy,qy=er,Ky=rr,Xy="[object Symbol]";function Jy(e){return typeof e=="symbol"||Ky(e)&&qy(e)==Xy}var kl=Jy,Zy=Yy,Pl=bt,Qy=kl,jl=NaN,e0=/^[-+]0x[0-9a-f]+$/i,t0=/^0b[01]+$/i,r0=/^0o[0-7]+$/i,n0=parseInt;function i0(e){if(typeof e=="number")return e;if(Qy(e))return jl;if(Pl(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=Pl(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=Zy(e);var r=t0.test(e);return r||r0.test(e)?n0(e.slice(2),r?2:8):e0.test(e)?jl:+e}var Il=i0,o0=bt,Io=zy,$l=Il,a0="Expected a function",s0=Math.max,l0=Math.min;function u0(e,t,r){var n,i,o,a,s,l,u=0,f=!1,c=!1,p=!0;if(typeof e!="function")throw new TypeError(a0);t=$l(t)||0,o0(r)&&(f=!!r.leading,c="maxWait"in r,o=c?s0($l(r.maxWait)||0,t):o,p="trailing"in r?!!r.trailing:p);function v(M){var Y=n,ce=i;return n=i=void 0,u=M,a=e.apply(ce,Y),a}function m(M){return u=M,s=setTimeout(j,t),f?v(M):a}function y(M){var Y=M-l,ce=M-u,ie=t-Y;return c?l0(ie,o-ce):ie}function T(M){var Y=M-l,ce=M-u;return l===void 0||Y>=t||Y<0||c&&ce>=o}function j(){var M=Io();if(T(M))return F(M);s=setTimeout(j,y(M))}function F(M){return s=void 0,p&&n?v(M):(n=i=void 0,a)}function D(){s!==void 0&&clearTimeout(s),u=0,n=l=i=s=void 0}function O(){return s===void 0?a:F(Io())}function S(){var M=Io(),Y=T(M);if(n=arguments,i=this,l=M,Y){if(s===void 0)return m(l);if(c)return clearTimeout(s),s=setTimeout(j,t),v(l)}return s===void 0&&(s=setTimeout(j,t)),a}return S.cancel=D,S.flush=O,S}var c0=u0;const f0=yt(c0),Dl=(e,t,r,n,i,o=300)=>{const[a,s]=_.useState(r??t);_.useEffect(()=>{s(r??t)},[r]);const l=_.useCallback(f0(c=>e(n,c),o),[e,n,o]),u=_.useCallback(c=>{const p=i(c);s(p??t),l(p)},[l,i]),f=_.useCallback(()=>{s(t),e(n,void 0)},[t,e,n]);return[a,u,f]},d0=e=>e===""?void 0:parseFloat(e),p0=e=>d0(e),In=_.memo(function(t){const{allowDecimal:r,className:n,data:i,description:o,errors:a,enabled:s,handleChange:l,label:u,path:f,required:c,hideControls:p}=t,[v,m]=Dl(l,"",i,f,p0);return d.jsx(b.NumberInput,{label:u,description:o,error:a,required:c,value:v,onChange:m,className:n,disabled:!s,allowDecimal:r,hideControls:p,w:"100%"})});function h0(){this.__data__=[],this.size=0}var m0=h0;function g0(e,t){return e===t||e!==e&&t!==t}var $n=g0,y0=$n;function v0(e,t){for(var r=e.length;r--;)if(y0(e[r][0],t))return r;return-1}var Dn=v0,b0=Dn,x0=Array.prototype,T0=x0.splice;function _0(e){var t=this.__data__,r=b0(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():T0.call(t,r,1),--this.size,!0}var S0=_0,E0=Dn;function C0(e){var t=this.__data__,r=E0(t,e);return r<0?void 0:t[r][1]}var w0=C0,A0=Dn;function O0(e){return A0(this.__data__,e)>-1}var k0=O0,P0=Dn;function j0(e,t){var r=this.__data__,n=P0(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}var I0=j0,$0=m0,D0=S0,M0=w0,R0=k0,N0=I0;function nr(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}nr.prototype.clear=$0,nr.prototype.delete=D0,nr.prototype.get=M0,nr.prototype.has=R0,nr.prototype.set=N0;var Mn=nr,F0=Mn;function L0(){this.__data__=new F0,this.size=0}var z0=L0;function B0(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}var U0=B0;function V0(e){return this.__data__.get(e)}var W0=V0;function H0(e){return this.__data__.has(e)}var G0=H0,Y0=Wt,q0=Y0(Object,"create"),Rn=q0,Ml=Rn;function K0(){this.__data__=Ml?Ml(null):{},this.size=0}var X0=K0;function J0(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var Z0=J0,Q0=Rn,ev="__lodash_hash_undefined__",tv=Object.prototype,rv=tv.hasOwnProperty;function nv(e){var t=this.__data__;if(Q0){var r=t[e];return r===ev?void 0:r}return rv.call(t,e)?t[e]:void 0}var iv=nv,ov=Rn,av=Object.prototype,sv=av.hasOwnProperty;function lv(e){var t=this.__data__;return ov?t[e]!==void 0:sv.call(t,e)}var uv=lv,cv=Rn,fv="__lodash_hash_undefined__";function dv(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=cv&&t===void 0?fv:t,this}var pv=dv,hv=X0,mv=Z0,gv=iv,yv=uv,vv=pv;function ir(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}ir.prototype.clear=hv,ir.prototype.delete=mv,ir.prototype.get=gv,ir.prototype.has=yv,ir.prototype.set=vv;var bv=ir,Rl=bv,xv=Mn,Tv=So;function _v(){this.size=0,this.__data__={hash:new Rl,map:new(Tv||xv),string:new Rl}}var Sv=_v;function Ev(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}var Cv=Ev,wv=Cv;function Av(e,t){var r=e.__data__;return wv(t)?r[typeof t=="string"?"string":"hash"]:r.map}var Nn=Av,Ov=Nn;function kv(e){var t=Ov(this,e).delete(e);return this.size-=t?1:0,t}var Pv=kv,jv=Nn;function Iv(e){return jv(this,e).get(e)}var $v=Iv,Dv=Nn;function Mv(e){return Dv(this,e).has(e)}var Rv=Mv,Nv=Nn;function Fv(e,t){var r=Nv(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,this}var Lv=Fv,zv=Sv,Bv=Pv,Uv=$v,Vv=Rv,Wv=Lv;function or(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}or.prototype.clear=zv,or.prototype.delete=Bv,or.prototype.get=Uv,or.prototype.has=Vv,or.prototype.set=Wv;var Nl=or,Hv=Mn,Gv=So,Yv=Nl,qv=200;function Kv(e,t){var r=this.__data__;if(r instanceof Hv){var n=r.__data__;if(!Gv||n.length<qv-1)return n.push([e,t]),this.size=++r.size,this;r=this.__data__=new Yv(n)}return r.set(e,t),this.size=r.size,this}var Xv=Kv,Jv=Mn,Zv=z0,Qv=U0,eb=W0,tb=G0,rb=Xv;function ar(e){var t=this.__data__=new Jv(e);this.size=t.size}ar.prototype.clear=Zv,ar.prototype.delete=Qv,ar.prototype.get=eb,ar.prototype.has=tb,ar.prototype.set=rb;var nb=ar,ib=Wt,ob=function(){try{var e=ib(Object,"defineProperty");return e({},"",{}),e}catch{}}(),Fl=ob,Ll=Fl;function ab(e,t,r){t=="__proto__"&&Ll?Ll(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}var $o=ab,sb=$o,lb=$n;function ub(e,t,r){(r!==void 0&&!lb(e[t],r)||r===void 0&&!(t in e))&&sb(e,t,r)}var zl=ub;function cb(e){return function(t,r,n){for(var i=-1,o=Object(t),a=n(t),s=a.length;s--;){var l=a[e?s:++i];if(r(o[l],l,o)===!1)break}return t}}var fb=cb,db=fb,pb=db(),hb=pb,Fn={exports:{}};Fn.exports,function(e,t){var r=ct,n=t&&!t.nodeType&&t,i=n&&!0&&e&&!e.nodeType&&e,o=i&&i.exports===n,a=o?r.Buffer:void 0,s=a?a.allocUnsafe:void 0;function l(u,f){if(f)return u.slice();var c=u.length,p=s?s(c):new u.constructor(c);return u.copy(p),p}e.exports=l}(Fn,Fn.exports);var mb=Fn.exports,gb=ct,yb=gb.Uint8Array,vb=yb,Bl=vb;function bb(e){var t=new e.constructor(e.byteLength);return new Bl(t).set(new Bl(e)),t}var xb=bb,Tb=xb;function _b(e,t){var r=t?Tb(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}var Sb=_b;function Eb(e,t){var r=-1,n=e.length;for(t||(t=Array(n));++r<n;)t[r]=e[r];return t}var Cb=Eb,wb=bt,Ul=Object.create,Ab=function(){function e(){}return function(t){if(!wb(t))return{};if(Ul)return Ul(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}}(),Ob=Ab,kb=sl,Pb=kb(Object.getPrototypeOf,Object),Vl=Pb,jb=Ob,Ib=Vl,$b=wn;function Db(e){return typeof e.constructor=="function"&&!$b(e)?jb(Ib(e)):{}}var Mb=Db,Rb=kn,Nb=rr;function Fb(e){return Nb(e)&&Rb(e)}var Wl=Fb,Lb=er,zb=Vl,Bb=rr,Ub="[object Object]",Vb=Function.prototype,Wb=Object.prototype,Hl=Vb.toString,Hb=Wb.hasOwnProperty,Gb=Hl.call(Object);function Yb(e){if(!Bb(e)||Lb(e)!=Ub)return!1;var t=zb(e);if(t===null)return!0;var r=Hb.call(t,"constructor")&&t.constructor;return typeof r=="function"&&r instanceof r&&Hl.call(r)==Gb}var qb=Yb;function Kb(e,t){if(!(t==="constructor"&&typeof e[t]=="function")&&t!="__proto__")return e[t]}var Gl=Kb,Xb=$o,Jb=$n,Zb=Object.prototype,Qb=Zb.hasOwnProperty;function ex(e,t,r){var n=e[t];(!(Qb.call(e,t)&&Jb(n,r))||r===void 0&&!(t in e))&&Xb(e,t,r)}var tx=ex,rx=tx,nx=$o;function ix(e,t,r,n){var i=!r;r||(r={});for(var o=-1,a=t.length;++o<a;){var s=t[o],l=n?n(r[s],e[s],s,r,e):void 0;l===void 0&&(l=e[s]),i?nx(r,s,l):rx(r,s,l)}return r}var ox=ix;function ax(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}var sx=ax,lx=9007199254740991,ux=/^(?:0|[1-9]\d*)$/;function cx(e,t){var r=typeof e;return t=t??lx,!!t&&(r=="number"||r!="symbol"&&ux.test(e))&&e>-1&&e%1==0&&e<t}var Yl=cx,fx=sx,dx=On,px=Dr,hx=ko,mx=Yl,gx=Po,yx=Object.prototype,vx=yx.hasOwnProperty;function bx(e,t){var r=px(e),n=!r&&dx(e),i=!r&&!n&&hx(e),o=!r&&!n&&!i&&gx(e),a=r||n||i||o,s=a?fx(e.length,String):[],l=s.length;for(var u in e)(t||vx.call(e,u))&&!(a&&(u=="length"||i&&(u=="offset"||u=="parent")||o&&(u=="buffer"||u=="byteLength"||u=="byteOffset")||mx(u,l)))&&s.push(u);return s}var xx=bx;function Tx(e){var t=[];if(e!=null)for(var r in Object(e))t.push(r);return t}var _x=Tx,Sx=bt,Ex=wn,Cx=_x,wx=Object.prototype,Ax=wx.hasOwnProperty;function Ox(e){if(!Sx(e))return Cx(e);var t=Ex(e),r=[];for(var n in e)n=="constructor"&&(t||!Ax.call(e,n))||r.push(n);return r}var kx=Ox,Px=xx,jx=kx,Ix=kn;function $x(e){return Ix(e)?Px(e,!0):jx(e)}var ql=$x,Dx=ox,Mx=ql;function Rx(e){return Dx(e,Mx(e))}var Nx=Rx,Kl=zl,Fx=mb,Lx=Sb,zx=Cb,Bx=Mb,Xl=On,Jl=Dr,Ux=Wl,Vx=ko,Wx=To,Hx=bt,Gx=qb,Yx=Po,Zl=Gl,qx=Nx;function Kx(e,t,r,n,i,o,a){var s=Zl(e,r),l=Zl(t,r),u=a.get(l);if(u){Kl(e,r,u);return}var f=o?o(s,l,r+"",e,t,a):void 0,c=f===void 0;if(c){var p=Jl(l),v=!p&&Vx(l),m=!p&&!v&&Yx(l);f=l,p||v||m?Jl(s)?f=s:Ux(s)?f=zx(s):v?(c=!1,f=Fx(l,!0)):m?(c=!1,f=Lx(l,!0)):f=[]:Gx(l)||Xl(l)?(f=s,Xl(s)?f=qx(s):(!Hx(s)||Wx(s))&&(f=Bx(l))):c=!1}c&&(a.set(l,f),i(f,l,n,o,a),a.delete(l)),Kl(e,r,f)}var Xx=Kx,Jx=nb,Zx=zl,Qx=hb,eT=Xx,tT=bt,rT=ql,nT=Gl;function Ql(e,t,r,n,i){e!==t&&Qx(t,function(o,a){if(i||(i=new Jx),tT(o))eT(e,t,a,r,Ql,n,i);else{var s=n?n(nT(e,a),o,a+"",e,t,i):void 0;s===void 0&&(s=o),Zx(e,a,s)}},rT)}var iT=Ql;function oT(e){return e}var eu=oT;function aT(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}var sT=aT,lT=sT,tu=Math.max;function uT(e,t,r){return t=tu(t===void 0?e.length-1:t,0),function(){for(var n=arguments,i=-1,o=tu(n.length-t,0),a=Array(o);++i<o;)a[i]=n[t+i];i=-1;for(var s=Array(t+1);++i<t;)s[i]=n[i];return s[t]=r(a),lT(e,this,s)}}var cT=uT;function fT(e){return function(){return e}}var dT=fT,pT=dT,ru=Fl,hT=eu,mT=ru?function(e,t){return ru(e,"toString",{configurable:!0,enumerable:!1,value:pT(t),writable:!0})}:hT,gT=mT,yT=800,vT=16,bT=Date.now;function xT(e){var t=0,r=0;return function(){var n=bT(),i=vT-(n-r);if(r=n,i>0){if(++t>=yT)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}var TT=xT,_T=gT,ST=TT,ET=ST(_T),CT=ET,wT=eu,AT=cT,OT=CT;function kT(e,t){return OT(AT(e,t,wT),e+"")}var nu=kT,PT=$n,jT=kn,IT=Yl,$T=bt;function DT(e,t,r){if(!$T(r))return!1;var n=typeof t;return(n=="number"?jT(r)&&IT(t,r.length):n=="string"&&t in r)?PT(r[t],e):!1}var iu=DT,MT=nu,RT=iu;function NT(e){return MT(function(t,r){var n=-1,i=r.length,o=i>1?r[i-1]:void 0,a=i>2?r[2]:void 0;for(o=e.length>3&&typeof o=="function"?(i--,o):void 0,a&&RT(r[0],r[1],a)&&(o=i<3?void 0:o,i=1),t=Object(t);++n<i;){var s=r[n];s&&e(t,s,n,o)}return t})}var FT=NT,LT=iT,zT=FT,BT=zT(function(e,t,r){LT(e,t,r)}),UT=BT;const ou=yt(UT),au=_.memo(function(t){const{className:r,config:n,uischema:i,data:o,description:a,errors:s,enabled:l,path:u,handleChange:f,label:c,required:p}=t;return ou({},n,i.options).format==="password"?d.jsx(b.PasswordInput,{label:c,description:a,error:s,required:p,value:o||"",onChange:m=>{f(u,m.currentTarget.value)},className:r,disabled:!l,w:"100%"}):d.jsx(b.TextInput,{label:c,description:a,error:s,required:p,value:o||"",onChange:m=>{f(u,m.currentTarget.value)},className:r,disabled:!l,w:"100%"})}),su=_.memo(function(t){const{className:r,data:n,description:i,enabled:o,errors:a,handleChange:s,label:l,labelPosition:u,path:f,required:c}=t;return d.jsx(b.Checkbox,{label:l,description:i,error:a,disabled:!o,className:r,labelPosition:u,required:c,data:[{label:"true",value:"true"},{label:"false",value:"false"}],value:String(n)||"",onChange:p=>{s(f,p==="true")}})}),VT=e=>d.jsx(In,{...e}),lu=W.rankWith(4,W.isNumberControl),uu=_e.withJsonFormsCellProps(VT),WT=e=>d.jsx(In,{...e}),cu=W.rankWith(3,W.isIntegerControl),fu=_e.withJsonFormsCellProps(WT),HT=e=>d.jsx(au,{...e}),du=W.rankWith(2,W.isStringControl),pu=_e.withJsonFormsCellProps(HT),GT=e=>d.jsx(su,{...e}),hu=W.rankWith(3,W.isBooleanControl),mu=_e.withJsonFormsCellProps(GT),YT=e=>{const{data:t,className:r,enabled:n,path:i,handleChange:o,description:a,errors:s,label:l,required:u}=e;return d.jsx(Xt.DateInput,{valueFormat:"DD.MM.YYYY",label:l,description:a,error:s,required:u,value:t?new Date(t):null,onChange:f=>{if(f instanceof Date){const c=new Date(f.getTime()-f.getTimezoneOffset()*6e4);o(i,c.toISOString().substring(0,10))}},className:r,disabled:!n,w:"100%"})},gu=W.rankWith(2,W.isDateControl),yu=_e.withJsonFormsCellProps(YT),qT=e=>{const{description:t,className:r,enabled:n,path:i,handleChange:o,data:a,errors:s,label:l,required:u}=e;return d.jsx(Xt.DateInput,{valueFormat:"DD.MM.YYYY",className:r,disabled:!n,label:l,description:t,error:s,required:u,value:a?new Date(a):null,onChange:f=>{if(f instanceof Date){const c=new Date(f.getTime()-f.getTimezoneOffset()*6e4);o(i,c.toISOString().substring(0,10))}},w:"100%"})},vu=W.rankWith(5,W.isDateTimeControl),bu=_e.withJsonFormsControlProps(qT),KT=e=>{const{description:t,data:r,options:n,enabled:i,handleChange:o,className:a,errors:s,label:l,required:u}=e;return d.jsx(b.Select,{data:n,defaultValue:r,label:l,description:t,required:u,error:s,disabled:!i,searchable:!0,onChange:f=>{o(path,f)},className:a,w:"100%"})},xu=W.rankWith(5,W.isEnumControl),Tu=_e.withJsonFormsEnumProps(_e.withTranslateProps(_.memo(KT)),!1);function XT(e,t){for(var r=-1,n=t.length,i=e.length;++r<n;)e[i+r]=t[r];return e}var JT=XT,_u=An,ZT=On,QT=Dr,Su=_u?_u.isConcatSpreadable:void 0;function e1(e){return QT(e)||ZT(e)||!!(Su&&e&&e[Su])}var t1=e1,r1=JT,n1=t1;function Eu(e,t,r,n,i){var o=-1,a=e.length;for(r||(r=n1),i||(i=[]);++o<a;){var s=e[o];t>0&&r(s)?t>1?Eu(s,t-1,r,n,i):r1(i,s):n||(i[i.length]=s)}return i}var i1=Eu,o1="__lodash_hash_undefined__";function a1(e){return this.__data__.set(e,o1),this}var s1=a1;function l1(e){return this.__data__.has(e)}var u1=l1,c1=Nl,f1=s1,d1=u1;function Ln(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new c1;++t<r;)this.add(e[t])}Ln.prototype.add=Ln.prototype.push=f1,Ln.prototype.has=d1;var p1=Ln;function h1(e,t,r,n){for(var i=e.length,o=r+(n?1:-1);n?o--:++o<i;)if(t(e[o],o,e))return o;return-1}var m1=h1;function g1(e){return e!==e}var y1=g1;function v1(e,t,r){for(var n=r-1,i=e.length;++n<i;)if(e[n]===t)return n;return-1}var b1=v1,x1=m1,T1=y1,_1=b1;function S1(e,t,r){return t===t?_1(e,t,r):x1(e,T1,r)}var E1=S1,C1=E1;function w1(e,t){var r=e==null?0:e.length;return!!r&&C1(e,t,0)>-1}var A1=w1;function O1(e,t,r){for(var n=-1,i=e==null?0:e.length;++n<i;)if(r(t,e[n]))return!0;return!1}var k1=O1;function P1(e,t){return e.has(t)}var j1=P1;function I1(){}var $1=I1;function D1(e){var t=-1,r=Array(e.size);return e.forEach(function(n){r[++t]=n}),r}var Cu=D1,Do=ml,M1=$1,R1=Cu,N1=1/0,F1=Do&&1/R1(new Do([,-0]))[1]==N1?function(e){return new Do(e)}:M1,L1=F1,z1=p1,B1=A1,U1=k1,V1=j1,W1=L1,H1=Cu,G1=200;function Y1(e,t,r){var n=-1,i=B1,o=e.length,a=!0,s=[],l=s;if(r)a=!1,i=U1;else if(o>=G1){var u=t?null:W1(e);if(u)return H1(u);a=!1,i=V1,l=new z1}else l=t?[]:s;e:for(;++n<o;){var f=e[n],c=t?t(f):f;if(f=r||f!==0?f:0,a&&c===c){for(var p=l.length;p--;)if(l[p]===c)continue e;t&&l.push(c),s.push(f)}else i(l,c,r)||(l!==s&&l.push(c),s.push(f))}return s}var q1=Y1,K1=i1,X1=nu,J1=q1,Z1=Wl,Q1=X1(function(e){return J1(K1(e,1,Z1,!0))}),e_=Q1;const t_=yt(e_);function r_(e,t,r,n){var i=-1,o=e==null?0:e.length;for(n&&o&&(r=e[++i]);++i<o;)r=t(r,e[i],i,e);return r}var n_=r_;function i_(e){return function(t){return e==null?void 0:e[t]}}var o_=i_,a_=o_,s_={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},l_=a_(s_),u_=l_;function c_(e,t){for(var r=-1,n=e==null?0:e.length,i=Array(n);++r<n;)i[r]=t(e[r],r,e);return i}var f_=c_,wu=An,d_=f_,p_=Dr,h_=kl,m_=1/0,Au=wu?wu.prototype:void 0,Ou=Au?Au.toString:void 0;function ku(e){if(typeof e=="string")return e;if(p_(e))return d_(e,ku)+"";if(h_(e))return Ou?Ou.call(e):"";var t=e+"";return t=="0"&&1/e==-m_?"-0":t}var g_=ku,y_=g_;function v_(e){return e==null?"":y_(e)}var Mo=v_,b_=u_,x_=Mo,T_=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,__="\\u0300-\\u036f",S_="\\ufe20-\\ufe2f",E_="\\u20d0-\\u20ff",C_=__+S_+E_,w_="["+C_+"]",A_=RegExp(w_,"g");function O_(e){return e=x_(e),e&&e.replace(T_,b_).replace(A_,"")}var k_=O_,P_=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function j_(e){return e.match(P_)||[]}var I_=j_,$_=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function D_(e){return $_.test(e)}var M_=D_,Pu="\\ud800-\\udfff",R_="\\u0300-\\u036f",N_="\\ufe20-\\ufe2f",F_="\\u20d0-\\u20ff",L_=R_+N_+F_,ju="\\u2700-\\u27bf",Iu="a-z\\xdf-\\xf6\\xf8-\\xff",z_="\\xac\\xb1\\xd7\\xf7",B_="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",U_="\\u2000-\\u206f",V_=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",$u="A-Z\\xc0-\\xd6\\xd8-\\xde",W_="\\ufe0e\\ufe0f",Du=z_+B_+U_+V_,Mu="['’]",Ru="["+Du+"]",H_="["+L_+"]",Nu="\\d+",G_="["+ju+"]",Fu="["+Iu+"]",Lu="[^"+Pu+Du+Nu+ju+Iu+$u+"]",Y_="\\ud83c[\\udffb-\\udfff]",q_="(?:"+H_+"|"+Y_+")",K_="[^"+Pu+"]",zu="(?:\\ud83c[\\udde6-\\uddff]){2}",Bu="[\\ud800-\\udbff][\\udc00-\\udfff]",sr="["+$u+"]",X_="\\u200d",Uu="(?:"+Fu+"|"+Lu+")",J_="(?:"+sr+"|"+Lu+")",Vu="(?:"+Mu+"(?:d|ll|m|re|s|t|ve))?",Wu="(?:"+Mu+"(?:D|LL|M|RE|S|T|VE))?",Hu=q_+"?",Gu="["+W_+"]?",Z_="(?:"+X_+"(?:"+[K_,zu,Bu].join("|")+")"+Gu+Hu+")*",Q_="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",eS="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",tS=Gu+Hu+Z_,rS="(?:"+[G_,zu,Bu].join("|")+")"+tS,nS=RegExp([sr+"?"+Fu+"+"+Vu+"(?="+[Ru,sr,"$"].join("|")+")",J_+"+"+Wu+"(?="+[Ru,sr+Uu,"$"].join("|")+")",sr+"?"+Uu+"+"+Vu,sr+"+"+Wu,eS,Q_,Nu,rS].join("|"),"g");function iS(e){return e.match(nS)||[]}var oS=iS,aS=I_,sS=M_,lS=Mo,uS=oS;function cS(e,t,r){return e=lS(e),t=r?void 0:t,t===void 0?sS(e)?uS(e):aS(e):e.match(t)||[]}var fS=cS,dS=n_,pS=k_,hS=fS,mS="['’]",gS=RegExp(mS,"g");function yS(e){return function(t){return dS(hS(pS(t).replace(gS,"")),e,"")}}var vS=yS;function bS(e,t,r){var n=-1,i=e.length;t<0&&(t=-t>i?0:i+t),r=r>i?i:r,r<0&&(r+=i),i=t>r?0:r-t>>>0,t>>>=0;for(var o=Array(i);++n<i;)o[n]=e[n+t];return o}var xS=bS,TS=xS;function _S(e,t,r){var n=e.length;return r=r===void 0?n:r,!t&&r>=n?e:TS(e,t,r)}var SS=_S,ES="\\ud800-\\udfff",CS="\\u0300-\\u036f",wS="\\ufe20-\\ufe2f",AS="\\u20d0-\\u20ff",OS=CS+wS+AS,kS="\\ufe0e\\ufe0f",PS="\\u200d",jS=RegExp("["+PS+ES+OS+kS+"]");function IS(e){return jS.test(e)}var Yu=IS;function $S(e){return e.split("")}var DS=$S,qu="\\ud800-\\udfff",MS="\\u0300-\\u036f",RS="\\ufe20-\\ufe2f",NS="\\u20d0-\\u20ff",FS=MS+RS+NS,LS="\\ufe0e\\ufe0f",zS="["+qu+"]",Ro="["+FS+"]",No="\\ud83c[\\udffb-\\udfff]",BS="(?:"+Ro+"|"+No+")",Ku="[^"+qu+"]",Xu="(?:\\ud83c[\\udde6-\\uddff]){2}",Ju="[\\ud800-\\udbff][\\udc00-\\udfff]",US="\\u200d",Zu=BS+"?",Qu="["+LS+"]?",VS="(?:"+US+"(?:"+[Ku,Xu,Ju].join("|")+")"+Qu+Zu+")*",WS=Qu+Zu+VS,HS="(?:"+[Ku+Ro+"?",Ro,Xu,Ju,zS].join("|")+")",GS=RegExp(No+"(?="+No+")|"+HS+WS,"g");function YS(e){return e.match(GS)||[]}var qS=YS,KS=DS,XS=Yu,JS=qS;function ZS(e){return XS(e)?JS(e):KS(e)}var QS=ZS,eE=SS,tE=Yu,rE=QS,nE=Mo;function iE(e){return function(t){t=nE(t);var r=tE(t)?rE(t):void 0,n=r?r[0]:t.charAt(0),i=r?eE(r,1).join(""):t.slice(1);return n[e]()+i}}var oE=iE,aE=oE,sE=aE("toUpperCase"),lE=sE,uE=vS,cE=lE,fE=uE(function(e,t,r){return e+(r?" ":"")+cE(t)}),dE=fE;const pE=yt(dE);var hE=Math.ceil,mE=Math.max;function gE(e,t,r,n){for(var i=-1,o=mE(hE((t-e)/(r||1)),0),a=Array(o);o--;)a[n?o:++i]=e,e+=r;return a}var yE=gE,vE=Il,ec=1/0,bE=17976931348623157e292;function xE(e){if(!e)return e===0?e:0;if(e=vE(e),e===ec||e===-ec){var t=e<0?-1:1;return t*bE}return e===e?e:0}var TE=xE,_E=yE,SE=iu,Fo=TE;function EE(e){return function(t,r,n){return n&&typeof n!="number"&&SE(t,r,n)&&(r=n=void 0),t=Fo(t),r===void 0?(r=t,t=0):r=Fo(r),n=n===void 0?t<r?1:-1:Fo(n),_E(t,r,n,e)}}var CE=EE,wE=CE,AE=wE(),OE=AE;const kE=yt(OE);function xt(e){if(typeof e!="object"||e===null)return!1;const t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function tc(e){if(!xt(e))return e;const t={};return Object.keys(e).forEach(r=>{t[r]=tc(e[r])}),t}function et(e,t,r={clone:!0}){const n=r.clone?{...e}:e;return xt(e)&&xt(t)&&Object.keys(t).forEach(i=>{xt(t[i])&&Object.prototype.hasOwnProperty.call(e,i)&&xt(e[i])?n[i]=et(e[i],t[i],r):r.clone?n[i]=xt(t[i])?tc(t[i]):t[i]:n[i]=t[i]}),n}var Lo={exports:{}},zn={exports:{}},pe={};/** @license React v16.13.1
|
|
118
|
+
*/var ep=Be("outline","users","IconUsers",[["path",{d:"M9 7m-4 0a4 4 0 1 0 8 0a4 4 0 1 0 -8 0",key:"svg-0"}],["path",{d:"M3 21v-2a4 4 0 0 1 4 -4h4a4 4 0 0 1 4 4v2",key:"svg-1"}],["path",{d:"M16 3.13a4 4 0 0 1 0 7.75",key:"svg-2"}],["path",{d:"M21 21v-2a4 4 0 0 0 -3 -3.85",key:"svg-3"}]]);function es(...e){const[t,r]=_.useState(!1),n={bg:"transparent",size:"sm",c:"gray"},i=b.useProps("ActionIcon",n,e);return d.jsxs(d.Fragment,{children:[d.jsx(b.Tooltip,{label:"Add Item",children:d.jsx(b.ActionIcon,{bg:i.bg,size:i.size,c:i.c,onClick:()=>{r(!0)},children:d.jsx(Gi,{})})}),d.jsx(Ka,{opened:t,onClose:()=>{r(!1)}})]})}function tp({form:e,name:t,items:r,onChange:n,...i}){return d.jsx(b.Select,{data:r,searchable:!0,...e.getInputProps(t),onChange:n,...i})}function rp({form:e,name:t,items:r,onChange:n,...i}){return d.jsx(b.Select,{data:r,searchable:!0,...e.getInputProps(t),onChange:n,...i})}function np({form:e,name:t,...r}){const n=b.useCombobox({onDropdownClose:()=>n.resetSelectedOption(),onDropdownOpen:()=>n.updateSelectedOptionIndex("active")}),[i,o]=_.useState([]),[a,s]=_.useState(""),l=c=>{a!==""&&(i.includes(a)||o(p=>[...p,a]),s(""))},u=c=>o(p=>p.filter(y=>y!==c)),f=i.map(c=>d.jsx(b.Pill,{withRemoveButton:!0,onRemove:()=>u(c),children:c},c));return _.useEffect(()=>{const c=e.getInputProps(t).value;if(c)try{o([...c])}catch(p){console.error("Error parsing JSON:",p)}},[]),_.useEffect(()=>{e.getInputProps(t).onChange(i)},[i]),d.jsxs(b.Combobox,{store:n,onOptionSubmit:l,children:[d.jsx(b.Combobox.DropdownTarget,{children:d.jsx(b.PillsInput,{onClick:()=>n.openDropdown(),children:d.jsxs(b.Pill.Group,{children:[f,d.jsx(b.Combobox.EventsTarget,{children:d.jsx(b.PillsInput.Field,{onFocus:()=>n.openDropdown(),onBlur:()=>n.closeDropdown(),value:a,placeholder:"Search values",onChange:c=>{n.updateSelectedOptionIndex(),s(c.currentTarget.value)},onKeyDown:c=>{c.key==="Backspace"&&a.length===0&&(c.preventDefault(),u(i[i.length-1]))}})})]})})}),d.jsx(b.Combobox.Dropdown,{children:d.jsx(b.Combobox.Options,{children:d.jsxs(b.Combobox.Option,{value:"$create",children:["+ Create ",a]})})})]})}function ts({onClose:e,...t}){const{info:r,queryParams:n,setQueryParams:i,path:o}=De(),a=gi.useForm({initialValues:{filters:[]},validate:Vi(Sr({filters:Ni().of(Sr({col:an().transform(c=>c||void 0).required("Field is required"),opr:an().transform(c=>c||void 0).required("col is required"),value:on().when("col",{is:c=>c&&r.filters[c].schema.required,then:()=>on().required("Value is required")})}))}))}),s={bg:"transparent",size:"sm",c:"gray"},l=b.useProps("ActionIcon",s,t);_.useEffect(()=>{a.setValues({filters:[]}),a.reset()},[o]),_.useEffect(()=>{if(n.filters&&n.filters.length){const c=n.filters.map(p=>({...p,key:At.randomId()}));a.setFieldValue("filters",c)}},[n.filters]);const u=c=>{const p=c.filters.map(({key:g,...m})=>m),y=JSON.parse(JSON.stringify(p));i({filters:y,page:0}),e()},f=a.values.filters.map((c,p)=>d.jsxs(b.Box,{px:"sm",children:[d.jsxs(b.Flex,{my:"md",gap:"md",style:{whiteSpace:"nowrap"},children:[d.jsx(b.Box,{style:{width:"192px"},children:r&&r.filters&&d.jsx(tp,{form:a,name:`filters.${p}.col`,items:Object.entries(r.filters).map(([y,g])=>({label:g.label,value:String(y)})),onChange:y=>{a.setFieldValue(`filters.${p}`,{col:y,opr:"",value:"",key:At.randomId()})}})}),d.jsx(b.Box,{style:{width:"192px"},children:c.col?d.jsx(rp,{form:a,name:`filters.${p}.opr`,items:r.filters[c.col].filters.map(y=>({label:y.name,value:y.operator})),onChange:y=>{a.setFieldValue(`filters.${p}`,{col:a.values.filters[p].col,opr:y,value:"",key:At.randomId()})}}):null}),d.jsx(b.Box,{style:{width:"192px"},children:c.col?c.opr==="in"?d.jsx(np,{form:a,name:`filters.${p}.value`}):d.jsx(Wi,{form:a,name:`filters.${p}.value`,schema:r.filters[c.col].schema,filter:!0}):null}),d.jsx(b.ActionIcon,{bg:l.bg,size:l.size,c:l.c,onClick:()=>{a.removeListItem("filters",p)},children:d.jsx(Qa,{})})]}),a.values.filters.length>1&&p<a.values.filters.length-1?d.jsx(b.Divider,{my:"md",labelPosition:"center",label:"AND"}):null]},c.key));return d.jsxs(b.Box,{component:"form",onSubmit:a.onSubmit(u),children:[f.length===0&&d.jsx(b.Box,{style:{width:"642px"},children:d.jsx(b.Text,{style:{fontStyle:"italic",padding:"7px"},size:"sm",c:"dimmed",children:"No filters selected..."})}),d.jsx(b.ScrollArea.Autosize,{mah:"40vh",mt:20,children:f}),d.jsx(b.Divider,{my:"sm"}),d.jsxs(b.Box,{style:{display:"flex",justifyContent:"space-between"},children:[d.jsx(b.Button,{variant:"subtle",leftSection:d.jsx(Gi,{}),onClick:()=>{a.insertListItem("filters",{col:"",opr:"",value:"",key:At.randomId()})},children:"Add Filter"}),d.jsx(b.Group,{spacing:"md",children:d.jsx(b.Button,{type:"submit",children:"Apply"})})]})]})}function rs(...e){const{queryParams:t}=De(),r={bg:"transparent",size:"sm",c:"gray"},n=b.useProps("ActionIcon",r,e),[i,o]=_.useState(!1);return d.jsxs(b.Popover,{opened:i,position:"bottom-end",onClose:()=>o(!1),closeOnClickOutside:!1,children:[d.jsx(b.Popover.Target,{children:d.jsx(b.Tooltip,{opened:i?!1:null,label:"Filter",children:t.filters.length!=0?d.jsx(b.Indicator,{zIndex:20,size:16,label:t.filters.length,children:d.jsx(b.ActionIcon,{bg:n.bg,size:n.size,c:n.c,onClick:()=>o(!0),children:d.jsx(Ja,{})})}):d.jsx(b.ActionIcon,{bg:n.bg,size:n.size,c:n.c,onClick:()=>o(!0),children:d.jsx(Ja,{})})})}),d.jsxs(b.Popover.Dropdown,{px:"xs",children:[d.jsx(b.Box,{style:{position:"absolute",top:4,right:4},children:d.jsx(b.CloseButton,{title:"Filters",onClick:()=>o(!1)})}),d.jsx(ts,{onClose:()=>{o(!1)}})]})]})}function ip(...e){const[t,r]=_.useState(!1),{download:n}=De(),i={bg:"transparent",size:"sm",c:"gray"},o=b.useProps("ActionIcon",i,e);return t?d.jsx(b.Loader,{color:o.c,size:o.size}):d.jsx(b.Tooltip,{label:"Download",children:d.jsx(b.ActionIcon,{bg:o.bg,size:o.size,c:o.c,onClick:()=>{r(!0),n("download").then(()=>r(!1))},children:d.jsx(qd,{})})})}const ns=_.memo(({hideAdd:e,hideFilter:t,hideDownload:r,toolbarCustomizer:n})=>{const{info:i}=De(),o=_.useMemo(()=>{const s={};return Object.entries(n).forEach(([l,u])=>{s[l]=u,typeof s[l]=="function"&&(s[l]=s[l]())}),s},[n]),a=i.permissions.includes("can_post");return d.jsxs(b.Flex,{justify:"flex-end",p:"md",gap:"sm",children:[!r&&(o.download||d.jsx(ip,{})),a&&!e?o.add||d.jsx(es,{}):null,t?null:o.filter||d.jsx(rs,{})]})});ns.displayName="Toolbar";const is={root:"_root_1kmay_1",wrapper:"_wrapper_1kmay_7",icon:"_icon_1kmay_18"};function Yi({column:e,label:t,orderColumn:r,related:n,toggleAll:i,allChecked:o,classNames:a,styles:s,customElement:l,...u}){const{queryParams:f,setQueryParams:c,loading:p}=De(),y={fw:700,size:"sm",color:"gray.8",hoverColor:"gray.6",selectedColor:"blue"},g=b.useStyles({name:"FieldTitle",classes:is,classNames:a,styles:s,props:u}),m=b.useProps("FieldTitle",y,u),{hovered:T,ref:j}=At.useHover(),F=r&&f.order_column===r,D=g("wrapper");return D.style.cursor=r?D.style.cursor:"auto",d.jsx(b.Table.Th,{className:is.fieldTitleRoot,...g("root"),onClick:r&&!p?()=>c({order_column:r,order_direction:f.order_direction==="asc"?"desc":"asc"}):null,children:d.jsx(b.Box,{ref:j,...D,children:e==="Checkbox"?d.jsx(b.Checkbox,{pb:5,pl:2,onChange:i,checked:o}):d.jsxs(d.Fragment,{children:[d.jsx(b.Box,{w:"100%",fw:m.fw,size:"xl",c:T&&r?m.hoverColor:F?m.selectedColor:m.color,children:l||t||e}),n?d.jsx(b.Tooltip,{label:"Related Field",children:d.jsx(b.Indicator,{label:"rel",style:{indicator:{top:"-1px !important",right:"-2px !important",padding:"4px"}},children:d.jsx(b.Box,{...g("icon"),children:F?f.order_direction==="asc"?d.jsx(Hi,{size:14,strokeWidth:1.5}):d.jsx(Xa,{size:14,strokeWidth:1.5}):null})})}):d.jsx(b.Box,{...g("icon"),children:F?f.order_direction==="asc"?d.jsx(Hi,{size:14,strokeWidth:1.5}):d.jsx(Xa,{size:14,strokeWidth:1.5}):null})]})})})}const os=_.memo(({data:e,info:t,settings:r,hideActions:n,hideCheckbox:i,allChecked:o,toggleAll:a,headerCustomizer:s})=>{const l=e.list_columns.includes("actions")?"_actions":"actions";let u=s==null?void 0:s[l];return typeof u=="function"&&(u=u()),d.jsx(b.Table.Thead,{children:d.jsxs(b.Table.Tr,{children:[i?null:d.jsx(Yi,{data:e,column:"Checkbox",allChecked:o,toggleAll:a}),n?null:d.jsx(Yi,{column:"Actions",customElement:u}),e.list_columns.map((f,c)=>{var y;let p=s==null?void 0:s[f];return typeof p=="function"&&(p=p(e.label_columns[f])),p===null?null:d.jsx(Yi,{column:f,label:e.label_columns[f],orderColumn:e.order_columns.find(g=>g===f)||e.order_columns.find(g=>g.startsWith(`${f}.`)),related:((y=t.filters[f])==null?void 0:y.schema.type)==="Nested",customElement:p},f)})]})})});os.displayName="Header";const qi=(e,t)=>{const r=t.split("."),n=e[r[0]];if(r.length>1&&Array.isArray(n))return n.map(o=>qi(o,r.slice(1).join("."))).join(", ");const i=t.split(".").reduce((o,a)=>o[a],e);return!i&&typeof i!="boolean"&&typeof i!="number"?null:typeof i=="boolean"?i.toString():Array.isArray(i)?i.map(o=>o.name_||JSON.stringify(o,null,2)).join(", "):typeof i=="object"?i.name_||JSON.stringify(i):i};function as(e,t){return e===!0||Array.isArray(e)?t:Object.fromEntries(Object.keys(e).map(r=>[r,as(e[r],t[r])]))}function ss(e,t){if(!e)return e;const r=t.values;return!r||!r.length||Array.isArray(e.id_)&&(e.id=e.id_),e}function op(e,t){const r={};return t.forEach(n=>{if(n.type==="Related"){r[n.name]=ss(e.result[n.name],n);return}if(n.type==="RelatedList"){r[n.name]=e.result[n.name].map(i=>ss(i,n));return}r[n.name]=typeof e.result[n.name]=="boolean"?String(e.result[n.name]):e.result[n.name]}),r}function ap({relatedPath:e,...t}){const{path:r}=De();return $e(r?r.substring(0,r.lastIndexOf("/")):"",e.substring(0,e.lastIndexOf("/"))),d.jsx(Ga,{resource_name:e.replace("/",""),relation:t,children:d.jsx(xo,{hideToolbar:!0,hideDownload:!1})})}const sp=_.memo(ap);function lp({item:e,info:t,loading:r,opened:n,onClose:i,...o}){const a={modal:{},tabs:{},tabsList:{},tabsPanel:{}},{modal:s,tabs:l,tabsList:u,tabsPanel:f}=b.useProps("ViewDialog",a,o);return d.jsxs(b.Modal,{opened:n,onClose:i,title:`${e==null?void 0:e.show_title} (#${Ze(e==null?void 0:e.id)})`,size:"lg",centered:!0,zIndex:1e3,...s,children:[d.jsx(b.LoadingOverlay,{visible:r}),!r&&e?d.jsxs(b.Tabs,{defaultValue:"details",...l,children:[d.jsxs(b.Tabs.List,{...u,children:[d.jsx(b.Tabs.Tab,{value:"details",children:"Details"}),t.relations.map((c,p)=>d.jsx(b.Tabs.Tab,{value:c.name,children:c.name},p))]}),d.jsx(b.Tabs.Panel,{pt:"xs",value:"details",...f,children:d.jsx(b.Paper,{p:"xs",withBorder:!0,children:d.jsx(b.Stack,{spacing:"md",children:d.jsx(b.ScrollArea,{h:450,type:"auto",children:e.show_columns.map((c,p)=>d.jsxs(b.Grid,{maw:500,children:[d.jsx(b.Grid.Col,{span:4,children:d.jsx(b.Text,{size:"md",children:e.label_columns[c]})}),d.jsx(b.Grid.Col,{span:1,children:d.jsx(b.Text,{size:"xs",children:":"})}),d.jsx(b.Grid.Col,{span:6,children:d.jsx(b.Text,{size:"md",children:qi(e.result,c)})})]},p))})})})}),t.relations.map((c,p)=>d.jsx(b.Tabs.Panel,{pt:"xs",value:c.name,children:d.jsx(b.Paper,{withBorder:!0,children:d.jsx(sp,{relatedPath:c.path,id:Ze(e.id),foreign_key:c.foreign_key,type:c.type})})},p))]}):null]})}function up({id:e,...t}){const{info:r,getEntry:n}=De(),i={bg:"transparent",size:"sm",c:"gray"},o=b.useProps("ActionIcon",i,t),[a,s]=_.useState(null),[l,u]=_.useState(!1),[f,c]=_.useState(!1);return d.jsxs(d.Fragment,{children:[d.jsx(b.Tooltip,{label:"Details",children:d.jsx(b.ActionIcon,{bg:o.bg,size:o.size,c:o.c,onClick:async()=>{u(!0);const p=await n(e);p&&(s(p),u(!1),c(!0))},children:d.jsx(Xd,{})})}),d.jsx(lp,{item:a,info:r,loading:l,opened:f,onClose:()=>c(!1)})]})}function cp(e,t){return new Promise(r=>{r(op(e,t.edit.columns))})}function ls({item:e,info:t,opened:r,onClose:n,...i}){const{updateEntry:o}=De(),a={modal:{},stack:{},saveButton:{}},{modal:s,stack:l,saveButton:u}=b.useProps("EditDialog",a,i),f=gi.useForm({initialValues:t.edit.defaultValues,validate:Vi(t.edit.schema)}),c=()=>{const y={};return Object.keys(f.values).forEach(g=>{f.isDirty(g)&&(y[g]=!0)}),y};_.useEffect(()=>{e&&cp(e,t).then(y=>{f.setValues(y),f.resetDirty(y)})},[e,t.edit.columns]);const p=async y=>{y=as(c(),y),await o(e.id,y),n()};return _.useEffect(()=>{f.setInitialValues(t.edit.defaultValues),f.reset()},[t.edit.defaultValues]),e?d.jsx(b.Modal,{opened:r,onClose:()=>{n()},title:t.edit.title,size:"lg",centered:!0,...s,children:d.jsx(b.Box,{component:"form",onSubmit:f.onSubmit(p),children:d.jsx(b.Stack,{spacing:"md",...l,children:d.jsxs(b.ScrollArea.Autosize,{mah:450,type:"auto",children:[t.edit.columns.map((y,g)=>d.jsx(Wi,{form:f,name:y.name,label:y.label,description:y.description,schema:y,withAsterisk:y.required},g)),d.jsx(b.Group,{position:"right",mt:"xl",children:d.jsx(b.Button,{type:"submit",...u,children:"Save"})})]})})})}):null}function us({id:e,...t}){const{info:r,getEntry:n}=De(),i={bg:"transparent",size:"sm",c:"gray"},o=b.useProps("ActionIcon",i,t),[a,s]=_.useState(null),[l,u]=_.useState(!1),[f,c]=_.useState(!1);return d.jsxs(d.Fragment,{children:[d.jsx(b.Tooltip,{label:"Edit",children:d.jsx(b.ActionIcon,{bg:o.bg,size:o.size,c:o.c,onClick:async()=>{u(!0);const p=await n(e);p&&(s(p),u(!1),c(!0))},children:d.jsx(Qd,{})})}),d.jsx(ls,{item:a,info:r,opened:f,onClose:()=>c(!1)})]})}function fp({opened:e,onClose:t,handleAccept:r,handleReject:n}){return d.jsxs(b.Modal,{opened:e,onClose:t,"aria-labelledby":"alert-dialog-title","aria-describedby":"alert-dialog-description",title:"Item löschen?",centered:!0,children:["Sind Sie Sicher, dass Sie das Item löschen wollen?",d.jsxs(b.Group,{align:"right",mt:"xl",justify:"flex-end",children:[d.jsx(b.Button,{onClick:n,variant:"default",children:"Abbrechen"}),d.jsx(b.Button,{onClick:r,color:"red",children:"Löschen"})]})]})}function cs({id:e,...t}){const{deleteEntry:r}=De(),n={bg:"transparent",size:"sm",c:"gray"},i=b.useProps("ActionIcon",n,t),[o,a]=_.useState(!1),s=()=>{a(!1)},l=async()=>{r(e),a(!1)};return d.jsxs(d.Fragment,{children:[d.jsx(b.Tooltip,{label:"Delete",children:d.jsx(b.ActionIcon,{bg:i.bg,size:i.size,c:i.c,onClick:()=>{a(!0)},children:d.jsx(Qa,{})})}),d.jsx(fp,{opened:o,onClose:s,handleAccept:l,handleReject:s})]})}function fs({id:e,selected:t}){const{info:r}=De();return d.jsxs(b.Flex,{style:{gap:4,whiteSpace:"nowrap"},children:[r.permissions.includes("can_get")?d.jsx(up,{id:e}):null,r.permissions.includes("can_put")?d.jsx(us,{id:e}):null,r.permissions.includes("can_delete")?d.jsx(cs,{id:e}):null]})}var ds={},Ki={},Xi={};Object.defineProperty(Xi,"__esModule",{value:!0}),Xi.default=mp;var ps="html",hs="head",un="body",dp=/<([a-zA-Z]+[0-9]?)/,ms=/<head[^]*>/i,gs=/<body[^]*>/i,cn=function(e,t){throw new Error("This browser does not support `document.implementation.createHTMLDocument`")},Ji=function(e,t){throw new Error("This browser does not support `DOMParser.prototype.parseFromString`")},ys=typeof window=="object"&&window.DOMParser;if(typeof ys=="function"){var pp=new ys,hp="text/html";Ji=function(e,t){return t&&(e="<".concat(t,">").concat(e,"</").concat(t,">")),pp.parseFromString(e,hp)},cn=Ji}if(typeof document=="object"&&document.implementation){var fn=document.implementation.createHTMLDocument();cn=function(e,t){if(t){var r=fn.documentElement.querySelector(t);return r&&(r.innerHTML=e),fn}return fn.documentElement.innerHTML=e,fn}}var dn=typeof document=="object"&&document.createElement("template"),Zi;dn&&dn.content&&(Zi=function(e){return dn.innerHTML=e,dn.content.childNodes});function mp(e){var t,r,n=e.match(dp),i=n&&n[1]?n[1].toLowerCase():"";switch(i){case ps:{var o=Ji(e);if(!ms.test(e)){var a=o.querySelector(hs);(t=a==null?void 0:a.parentNode)===null||t===void 0||t.removeChild(a)}if(!gs.test(e)){var a=o.querySelector(un);(r=a==null?void 0:a.parentNode)===null||r===void 0||r.removeChild(a)}return o.querySelectorAll(ps)}case hs:case un:{var s=cn(e).querySelectorAll(i);return gs.test(e)&&ms.test(e)?s[0].parentNode.childNodes:s}default:{if(Zi)return Zi(e);var a=cn(e,un).querySelector(un);return a.childNodes}}}var pn={},Qi={},eo={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Doctype=e.CDATA=e.Tag=e.Style=e.Script=e.Comment=e.Directive=e.Text=e.Root=e.isTag=e.ElementType=void 0;var t;(function(n){n.Root="root",n.Text="text",n.Directive="directive",n.Comment="comment",n.Script="script",n.Style="style",n.Tag="tag",n.CDATA="cdata",n.Doctype="doctype"})(t=e.ElementType||(e.ElementType={}));function r(n){return n.type===t.Tag||n.type===t.Script||n.type===t.Style}e.isTag=r,e.Root=t.Root,e.Text=t.Text,e.Directive=t.Directive,e.Comment=t.Comment,e.Script=t.Script,e.Style=t.Style,e.Tag=t.Tag,e.CDATA=t.CDATA,e.Doctype=t.Doctype})(eo);var ae={},Pt=Ce&&Ce.__extends||function(){var e=function(t,r){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(n[o]=i[o])},e(t,r)};return function(t,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");e(t,r);function n(){this.constructor=t}t.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}}(),Cr=Ce&&Ce.__assign||function(){return Cr=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++){t=arguments[r];for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i])}return e},Cr.apply(this,arguments)};Object.defineProperty(ae,"__esModule",{value:!0}),ae.cloneNode=ae.hasChildren=ae.isDocument=ae.isDirective=ae.isComment=ae.isText=ae.isCDATA=ae.isTag=ae.Element=ae.Document=ae.CDATA=ae.NodeWithChildren=ae.ProcessingInstruction=ae.Comment=ae.Text=ae.DataNode=ae.Node=void 0;var qe=eo,to=function(){function e(){this.parent=null,this.prev=null,this.next=null,this.startIndex=null,this.endIndex=null}return Object.defineProperty(e.prototype,"parentNode",{get:function(){return this.parent},set:function(t){this.parent=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"previousSibling",{get:function(){return this.prev},set:function(t){this.prev=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"nextSibling",{get:function(){return this.next},set:function(t){this.next=t},enumerable:!1,configurable:!0}),e.prototype.cloneNode=function(t){return t===void 0&&(t=!1),ro(this,t)},e}();ae.Node=to;var hn=function(e){Pt(t,e);function t(r){var n=e.call(this)||this;return n.data=r,n}return Object.defineProperty(t.prototype,"nodeValue",{get:function(){return this.data},set:function(r){this.data=r},enumerable:!1,configurable:!0}),t}(to);ae.DataNode=hn;var vs=function(e){Pt(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.type=qe.ElementType.Text,r}return Object.defineProperty(t.prototype,"nodeType",{get:function(){return 3},enumerable:!1,configurable:!0}),t}(hn);ae.Text=vs;var bs=function(e){Pt(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.type=qe.ElementType.Comment,r}return Object.defineProperty(t.prototype,"nodeType",{get:function(){return 8},enumerable:!1,configurable:!0}),t}(hn);ae.Comment=bs;var xs=function(e){Pt(t,e);function t(r,n){var i=e.call(this,n)||this;return i.name=r,i.type=qe.ElementType.Directive,i}return Object.defineProperty(t.prototype,"nodeType",{get:function(){return 1},enumerable:!1,configurable:!0}),t}(hn);ae.ProcessingInstruction=xs;var mn=function(e){Pt(t,e);function t(r){var n=e.call(this)||this;return n.children=r,n}return Object.defineProperty(t.prototype,"firstChild",{get:function(){var r;return(r=this.children[0])!==null&&r!==void 0?r:null},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"lastChild",{get:function(){return this.children.length>0?this.children[this.children.length-1]:null},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"childNodes",{get:function(){return this.children},set:function(r){this.children=r},enumerable:!1,configurable:!0}),t}(to);ae.NodeWithChildren=mn;var Ts=function(e){Pt(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.type=qe.ElementType.CDATA,r}return Object.defineProperty(t.prototype,"nodeType",{get:function(){return 4},enumerable:!1,configurable:!0}),t}(mn);ae.CDATA=Ts;var _s=function(e){Pt(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.type=qe.ElementType.Root,r}return Object.defineProperty(t.prototype,"nodeType",{get:function(){return 9},enumerable:!1,configurable:!0}),t}(mn);ae.Document=_s;var Es=function(e){Pt(t,e);function t(r,n,i,o){i===void 0&&(i=[]),o===void 0&&(o=r==="script"?qe.ElementType.Script:r==="style"?qe.ElementType.Style:qe.ElementType.Tag);var a=e.call(this,i)||this;return a.name=r,a.attribs=n,a.type=o,a}return Object.defineProperty(t.prototype,"nodeType",{get:function(){return 1},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"tagName",{get:function(){return this.name},set:function(r){this.name=r},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"attributes",{get:function(){var r=this;return Object.keys(this.attribs).map(function(n){var i,o;return{name:n,value:r.attribs[n],namespace:(i=r["x-attribsNamespace"])===null||i===void 0?void 0:i[n],prefix:(o=r["x-attribsPrefix"])===null||o===void 0?void 0:o[n]}})},enumerable:!1,configurable:!0}),t}(mn);ae.Element=Es;function Ss(e){return(0,qe.isTag)(e)}ae.isTag=Ss;function Cs(e){return e.type===qe.ElementType.CDATA}ae.isCDATA=Cs;function ws(e){return e.type===qe.ElementType.Text}ae.isText=ws;function As(e){return e.type===qe.ElementType.Comment}ae.isComment=As;function Os(e){return e.type===qe.ElementType.Directive}ae.isDirective=Os;function ks(e){return e.type===qe.ElementType.Root}ae.isDocument=ks;function gp(e){return Object.prototype.hasOwnProperty.call(e,"children")}ae.hasChildren=gp;function ro(e,t){t===void 0&&(t=!1);var r;if(ws(e))r=new vs(e.data);else if(As(e))r=new bs(e.data);else if(Ss(e)){var n=t?no(e.children):[],i=new Es(e.name,Cr({},e.attribs),n);n.forEach(function(l){return l.parent=i}),e.namespace!=null&&(i.namespace=e.namespace),e["x-attribsNamespace"]&&(i["x-attribsNamespace"]=Cr({},e["x-attribsNamespace"])),e["x-attribsPrefix"]&&(i["x-attribsPrefix"]=Cr({},e["x-attribsPrefix"])),r=i}else if(Cs(e)){var n=t?no(e.children):[],o=new Ts(n);n.forEach(function(u){return u.parent=o}),r=o}else if(ks(e)){var n=t?no(e.children):[],a=new _s(n);n.forEach(function(u){return u.parent=a}),e["x-mode"]&&(a["x-mode"]=e["x-mode"]),r=a}else if(Os(e)){var s=new xs(e.name,e.data);e["x-name"]!=null&&(s["x-name"]=e["x-name"],s["x-publicId"]=e["x-publicId"],s["x-systemId"]=e["x-systemId"]),r=s}else throw new Error("Not implemented yet: ".concat(e.type));return r.startIndex=e.startIndex,r.endIndex=e.endIndex,e.sourceCodeLocation!=null&&(r.sourceCodeLocation=e.sourceCodeLocation),r}ae.cloneNode=ro;function no(e){for(var t=e.map(function(n){return ro(n,!0)}),r=1;r<t.length;r++)t[r].prev=t[r-1],t[r-1].next=t[r];return t}(function(e){var t=Ce&&Ce.__createBinding||(Object.create?function(s,l,u,f){f===void 0&&(f=u);var c=Object.getOwnPropertyDescriptor(l,u);(!c||("get"in c?!l.__esModule:c.writable||c.configurable))&&(c={enumerable:!0,get:function(){return l[u]}}),Object.defineProperty(s,f,c)}:function(s,l,u,f){f===void 0&&(f=u),s[f]=l[u]}),r=Ce&&Ce.__exportStar||function(s,l){for(var u in s)u!=="default"&&!Object.prototype.hasOwnProperty.call(l,u)&&t(l,s,u)};Object.defineProperty(e,"__esModule",{value:!0}),e.DomHandler=void 0;var n=eo,i=ae;r(ae,e);var o={withStartIndices:!1,withEndIndices:!1,xmlMode:!1},a=function(){function s(l,u,f){this.dom=[],this.root=new i.Document(this.dom),this.done=!1,this.tagStack=[this.root],this.lastNode=null,this.parser=null,typeof u=="function"&&(f=u,u=o),typeof l=="object"&&(u=l,l=void 0),this.callback=l??null,this.options=u??o,this.elementCB=f??null}return s.prototype.onparserinit=function(l){this.parser=l},s.prototype.onreset=function(){this.dom=[],this.root=new i.Document(this.dom),this.done=!1,this.tagStack=[this.root],this.lastNode=null,this.parser=null},s.prototype.onend=function(){this.done||(this.done=!0,this.parser=null,this.handleCallback(null))},s.prototype.onerror=function(l){this.handleCallback(l)},s.prototype.onclosetag=function(){this.lastNode=null;var l=this.tagStack.pop();this.options.withEndIndices&&(l.endIndex=this.parser.endIndex),this.elementCB&&this.elementCB(l)},s.prototype.onopentag=function(l,u){var f=this.options.xmlMode?n.ElementType.Tag:void 0,c=new i.Element(l,u,void 0,f);this.addNode(c),this.tagStack.push(c)},s.prototype.ontext=function(l){var u=this.lastNode;if(u&&u.type===n.ElementType.Text)u.data+=l,this.options.withEndIndices&&(u.endIndex=this.parser.endIndex);else{var f=new i.Text(l);this.addNode(f),this.lastNode=f}},s.prototype.oncomment=function(l){if(this.lastNode&&this.lastNode.type===n.ElementType.Comment){this.lastNode.data+=l;return}var u=new i.Comment(l);this.addNode(u),this.lastNode=u},s.prototype.oncommentend=function(){this.lastNode=null},s.prototype.oncdatastart=function(){var l=new i.Text(""),u=new i.CDATA([l]);this.addNode(u),l.parent=u,this.lastNode=l},s.prototype.oncdataend=function(){this.lastNode=null},s.prototype.onprocessinginstruction=function(l,u){var f=new i.ProcessingInstruction(l,u);this.addNode(f)},s.prototype.handleCallback=function(l){if(typeof this.callback=="function")this.callback(l,this.dom);else if(l)throw l},s.prototype.addNode=function(l){var u=this.tagStack[this.tagStack.length-1],f=u.children[u.children.length-1];this.options.withStartIndices&&(l.startIndex=this.parser.startIndex),this.options.withEndIndices&&(l.endIndex=this.parser.endIndex),u.children.push(l),f&&(l.prev=f,f.next=l),l.parent=u,this.lastNode=null},s}();e.DomHandler=a,e.default=a})(Qi);var Ps={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CASE_SENSITIVE_TAG_NAMES_MAP=e.CASE_SENSITIVE_TAG_NAMES=void 0,e.CASE_SENSITIVE_TAG_NAMES=["animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","linearGradient","radialGradient","textPath"],e.CASE_SENSITIVE_TAG_NAMES_MAP=e.CASE_SENSITIVE_TAG_NAMES.reduce(function(t,r){return t[r.toLowerCase()]=r,t},{})})(Ps),Object.defineProperty(pn,"__esModule",{value:!0}),pn.formatAttributes=js,pn.formatDOM=Is;var gn=Qi,yp=Ps;function vp(e){return yp.CASE_SENSITIVE_TAG_NAMES_MAP[e]}function js(e){for(var t={},r=0,n=e.length;r<n;r++){var i=e[r];t[i.name]=i.value}return t}function bp(e){e=e.toLowerCase();var t=vp(e);return t||e}function Is(e,t,r){t===void 0&&(t=null);for(var n=[],i,o=0,a=e.length;o<a;o++){var s=e[o];switch(s.nodeType){case 1:{var l=bp(s.nodeName);i=new gn.Element(l,js(s.attributes)),i.children=Is(l==="template"?s.content.childNodes:s.childNodes,i);break}case 3:i=new gn.Text(s.nodeValue);break;case 8:i=new gn.Comment(s.nodeValue);break;default:continue}var u=n[o-1]||null;u&&(u.next=i),i.parent=t,i.prev=u,i.next=null,n.push(i)}return r&&(i=new gn.ProcessingInstruction(r.substring(0,r.indexOf(" ")).toLowerCase(),r),i.next=n[0]||null,i.parent=t,n.unshift(i),n[1]&&(n[1].prev=n[0])),n}var xp=Ce&&Ce.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(Ki,"__esModule",{value:!0}),Ki.default=Sp;var Tp=xp(Xi),_p=pn,Ep=/<(![a-zA-Z\s]+)>/;function Sp(e){if(typeof e!="string")throw new TypeError("First argument must be a string");if(!e)return[];var t=e.match(Ep),r=t?t[1]:void 0;return(0,_p.formatDOM)((0,Tp.default)(e),null,r)}var yn={},lt={},vn={},Cp=0;vn.SAME=Cp;var wp=1;vn.CAMELCASE=wp,vn.possibleStandardNames={accept:0,acceptCharset:1,"accept-charset":"acceptCharset",accessKey:1,action:0,allowFullScreen:1,alt:0,as:0,async:0,autoCapitalize:1,autoComplete:1,autoCorrect:1,autoFocus:1,autoPlay:1,autoSave:1,capture:0,cellPadding:1,cellSpacing:1,challenge:0,charSet:1,checked:0,children:0,cite:0,class:"className",classID:1,className:1,cols:0,colSpan:1,content:0,contentEditable:1,contextMenu:1,controls:0,controlsList:1,coords:0,crossOrigin:1,dangerouslySetInnerHTML:1,data:0,dateTime:1,default:0,defaultChecked:1,defaultValue:1,defer:0,dir:0,disabled:0,disablePictureInPicture:1,disableRemotePlayback:1,download:0,draggable:0,encType:1,enterKeyHint:1,for:"htmlFor",form:0,formMethod:1,formAction:1,formEncType:1,formNoValidate:1,formTarget:1,frameBorder:1,headers:0,height:0,hidden:0,high:0,href:0,hrefLang:1,htmlFor:1,httpEquiv:1,"http-equiv":"httpEquiv",icon:0,id:0,innerHTML:1,inputMode:1,integrity:0,is:0,itemID:1,itemProp:1,itemRef:1,itemScope:1,itemType:1,keyParams:1,keyType:1,kind:0,label:0,lang:0,list:0,loop:0,low:0,manifest:0,marginWidth:1,marginHeight:1,max:0,maxLength:1,media:0,mediaGroup:1,method:0,min:0,minLength:1,multiple:0,muted:0,name:0,noModule:1,nonce:0,noValidate:1,open:0,optimum:0,pattern:0,placeholder:0,playsInline:1,poster:0,preload:0,profile:0,radioGroup:1,readOnly:1,referrerPolicy:1,rel:0,required:0,reversed:0,role:0,rows:0,rowSpan:1,sandbox:0,scope:0,scoped:0,scrolling:0,seamless:0,selected:0,shape:0,size:0,sizes:0,span:0,spellCheck:1,src:0,srcDoc:1,srcLang:1,srcSet:1,start:0,step:0,style:0,summary:0,tabIndex:1,target:0,title:0,type:0,useMap:1,value:0,width:0,wmode:0,wrap:0,about:0,accentHeight:1,"accent-height":"accentHeight",accumulate:0,additive:0,alignmentBaseline:1,"alignment-baseline":"alignmentBaseline",allowReorder:1,alphabetic:0,amplitude:0,arabicForm:1,"arabic-form":"arabicForm",ascent:0,attributeName:1,attributeType:1,autoReverse:1,azimuth:0,baseFrequency:1,baselineShift:1,"baseline-shift":"baselineShift",baseProfile:1,bbox:0,begin:0,bias:0,by:0,calcMode:1,capHeight:1,"cap-height":"capHeight",clip:0,clipPath:1,"clip-path":"clipPath",clipPathUnits:1,clipRule:1,"clip-rule":"clipRule",color:0,colorInterpolation:1,"color-interpolation":"colorInterpolation",colorInterpolationFilters:1,"color-interpolation-filters":"colorInterpolationFilters",colorProfile:1,"color-profile":"colorProfile",colorRendering:1,"color-rendering":"colorRendering",contentScriptType:1,contentStyleType:1,cursor:0,cx:0,cy:0,d:0,datatype:0,decelerate:0,descent:0,diffuseConstant:1,direction:0,display:0,divisor:0,dominantBaseline:1,"dominant-baseline":"dominantBaseline",dur:0,dx:0,dy:0,edgeMode:1,elevation:0,enableBackground:1,"enable-background":"enableBackground",end:0,exponent:0,externalResourcesRequired:1,fill:0,fillOpacity:1,"fill-opacity":"fillOpacity",fillRule:1,"fill-rule":"fillRule",filter:0,filterRes:1,filterUnits:1,floodOpacity:1,"flood-opacity":"floodOpacity",floodColor:1,"flood-color":"floodColor",focusable:0,fontFamily:1,"font-family":"fontFamily",fontSize:1,"font-size":"fontSize",fontSizeAdjust:1,"font-size-adjust":"fontSizeAdjust",fontStretch:1,"font-stretch":"fontStretch",fontStyle:1,"font-style":"fontStyle",fontVariant:1,"font-variant":"fontVariant",fontWeight:1,"font-weight":"fontWeight",format:0,from:0,fx:0,fy:0,g1:0,g2:0,glyphName:1,"glyph-name":"glyphName",glyphOrientationHorizontal:1,"glyph-orientation-horizontal":"glyphOrientationHorizontal",glyphOrientationVertical:1,"glyph-orientation-vertical":"glyphOrientationVertical",glyphRef:1,gradientTransform:1,gradientUnits:1,hanging:0,horizAdvX:1,"horiz-adv-x":"horizAdvX",horizOriginX:1,"horiz-origin-x":"horizOriginX",ideographic:0,imageRendering:1,"image-rendering":"imageRendering",in2:0,in:0,inlist:0,intercept:0,k1:0,k2:0,k3:0,k4:0,k:0,kernelMatrix:1,kernelUnitLength:1,kerning:0,keyPoints:1,keySplines:1,keyTimes:1,lengthAdjust:1,letterSpacing:1,"letter-spacing":"letterSpacing",lightingColor:1,"lighting-color":"lightingColor",limitingConeAngle:1,local:0,markerEnd:1,"marker-end":"markerEnd",markerHeight:1,markerMid:1,"marker-mid":"markerMid",markerStart:1,"marker-start":"markerStart",markerUnits:1,markerWidth:1,mask:0,maskContentUnits:1,maskUnits:1,mathematical:0,mode:0,numOctaves:1,offset:0,opacity:0,operator:0,order:0,orient:0,orientation:0,origin:0,overflow:0,overlinePosition:1,"overline-position":"overlinePosition",overlineThickness:1,"overline-thickness":"overlineThickness",paintOrder:1,"paint-order":"paintOrder",panose1:0,"panose-1":"panose1",pathLength:1,patternContentUnits:1,patternTransform:1,patternUnits:1,pointerEvents:1,"pointer-events":"pointerEvents",points:0,pointsAtX:1,pointsAtY:1,pointsAtZ:1,prefix:0,preserveAlpha:1,preserveAspectRatio:1,primitiveUnits:1,property:0,r:0,radius:0,refX:1,refY:1,renderingIntent:1,"rendering-intent":"renderingIntent",repeatCount:1,repeatDur:1,requiredExtensions:1,requiredFeatures:1,resource:0,restart:0,result:0,results:0,rotate:0,rx:0,ry:0,scale:0,security:0,seed:0,shapeRendering:1,"shape-rendering":"shapeRendering",slope:0,spacing:0,specularConstant:1,specularExponent:1,speed:0,spreadMethod:1,startOffset:1,stdDeviation:1,stemh:0,stemv:0,stitchTiles:1,stopColor:1,"stop-color":"stopColor",stopOpacity:1,"stop-opacity":"stopOpacity",strikethroughPosition:1,"strikethrough-position":"strikethroughPosition",strikethroughThickness:1,"strikethrough-thickness":"strikethroughThickness",string:0,stroke:0,strokeDasharray:1,"stroke-dasharray":"strokeDasharray",strokeDashoffset:1,"stroke-dashoffset":"strokeDashoffset",strokeLinecap:1,"stroke-linecap":"strokeLinecap",strokeLinejoin:1,"stroke-linejoin":"strokeLinejoin",strokeMiterlimit:1,"stroke-miterlimit":"strokeMiterlimit",strokeWidth:1,"stroke-width":"strokeWidth",strokeOpacity:1,"stroke-opacity":"strokeOpacity",suppressContentEditableWarning:1,suppressHydrationWarning:1,surfaceScale:1,systemLanguage:1,tableValues:1,targetX:1,targetY:1,textAnchor:1,"text-anchor":"textAnchor",textDecoration:1,"text-decoration":"textDecoration",textLength:1,textRendering:1,"text-rendering":"textRendering",to:0,transform:0,typeof:0,u1:0,u2:0,underlinePosition:1,"underline-position":"underlinePosition",underlineThickness:1,"underline-thickness":"underlineThickness",unicode:0,unicodeBidi:1,"unicode-bidi":"unicodeBidi",unicodeRange:1,"unicode-range":"unicodeRange",unitsPerEm:1,"units-per-em":"unitsPerEm",unselectable:0,vAlphabetic:1,"v-alphabetic":"vAlphabetic",values:0,vectorEffect:1,"vector-effect":"vectorEffect",version:0,vertAdvY:1,"vert-adv-y":"vertAdvY",vertOriginX:1,"vert-origin-x":"vertOriginX",vertOriginY:1,"vert-origin-y":"vertOriginY",vHanging:1,"v-hanging":"vHanging",vIdeographic:1,"v-ideographic":"vIdeographic",viewBox:1,viewTarget:1,visibility:0,vMathematical:1,"v-mathematical":"vMathematical",vocab:0,widths:0,wordSpacing:1,"word-spacing":"wordSpacing",writingMode:1,"writing-mode":"writingMode",x1:0,x2:0,x:0,xChannelSelector:1,xHeight:1,"x-height":"xHeight",xlinkActuate:1,"xlink:actuate":"xlinkActuate",xlinkArcrole:1,"xlink:arcrole":"xlinkArcrole",xlinkHref:1,"xlink:href":"xlinkHref",xlinkRole:1,"xlink:role":"xlinkRole",xlinkShow:1,"xlink:show":"xlinkShow",xlinkTitle:1,"xlink:title":"xlinkTitle",xlinkType:1,"xlink:type":"xlinkType",xmlBase:1,"xml:base":"xmlBase",xmlLang:1,"xml:lang":"xmlLang",xmlns:0,"xml:space":"xmlSpace",xmlnsXlink:1,"xmlns:xlink":"xmlnsXlink",xmlSpace:1,y1:0,y2:0,y:0,yChannelSelector:1,z:0,zoomAndPan:1};const $s=0,jt=1,bn=2,xn=3,io=4,Ds=5,Ms=6;function Ap(e){return Re.hasOwnProperty(e)?Re[e]:null}function Ue(e,t,r,n,i,o,a){this.acceptsBooleans=t===bn||t===xn||t===io,this.attributeName=n,this.attributeNamespace=i,this.mustUseProperty=r,this.propertyName=e,this.type=t,this.sanitizeURL=o,this.removeEmptyString=a}const Re={};["children","dangerouslySetInnerHTML","defaultValue","defaultChecked","innerHTML","suppressContentEditableWarning","suppressHydrationWarning","style"].forEach(e=>{Re[e]=new Ue(e,$s,!1,e,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(([e,t])=>{Re[e]=new Ue(e,jt,!1,t,null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(e=>{Re[e]=new Ue(e,bn,!1,e.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(e=>{Re[e]=new Ue(e,bn,!1,e,null,!1,!1)}),["allowFullScreen","async","autoFocus","autoPlay","controls","default","defer","disabled","disablePictureInPicture","disableRemotePlayback","formNoValidate","hidden","loop","noModule","noValidate","open","playsInline","readOnly","required","reversed","scoped","seamless","itemScope"].forEach(e=>{Re[e]=new Ue(e,xn,!1,e.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(e=>{Re[e]=new Ue(e,xn,!0,e,null,!1,!1)}),["capture","download"].forEach(e=>{Re[e]=new Ue(e,io,!1,e,null,!1,!1)}),["cols","rows","size","span"].forEach(e=>{Re[e]=new Ue(e,Ms,!1,e,null,!1,!1)}),["rowSpan","start"].forEach(e=>{Re[e]=new Ue(e,Ds,!1,e.toLowerCase(),null,!1,!1)});const oo=/[\-\:]([a-z])/g,ao=e=>e[1].toUpperCase();["accent-height","alignment-baseline","arabic-form","baseline-shift","cap-height","clip-path","clip-rule","color-interpolation","color-interpolation-filters","color-profile","color-rendering","dominant-baseline","enable-background","fill-opacity","fill-rule","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","glyph-name","glyph-orientation-horizontal","glyph-orientation-vertical","horiz-adv-x","horiz-origin-x","image-rendering","letter-spacing","lighting-color","marker-end","marker-mid","marker-start","overline-position","overline-thickness","paint-order","panose-1","pointer-events","rendering-intent","shape-rendering","stop-color","stop-opacity","strikethrough-position","strikethrough-thickness","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke-width","text-anchor","text-decoration","text-rendering","underline-position","underline-thickness","unicode-bidi","unicode-range","units-per-em","v-alphabetic","v-hanging","v-ideographic","v-mathematical","vector-effect","vert-adv-y","vert-origin-x","vert-origin-y","word-spacing","writing-mode","xmlns:xlink","x-height"].forEach(e=>{const t=e.replace(oo,ao);Re[t]=new Ue(t,jt,!1,e,null,!1,!1)}),["xlink:actuate","xlink:arcrole","xlink:role","xlink:show","xlink:title","xlink:type"].forEach(e=>{const t=e.replace(oo,ao);Re[t]=new Ue(t,jt,!1,e,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(e=>{const t=e.replace(oo,ao);Re[t]=new Ue(t,jt,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(e=>{Re[e]=new Ue(e,jt,!1,e.toLowerCase(),null,!1,!1)});const Op="xlinkHref";Re[Op]=new Ue("xlinkHref",jt,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(e=>{Re[e]=new Ue(e,jt,!1,e.toLowerCase(),null,!0,!0)});const{CAMELCASE:kp,SAME:Pp,possibleStandardNames:Rs}=vn,jp=":A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD"+"\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040",Ip=RegExp.prototype.test.bind(new RegExp("^(data|aria)-["+jp+"]*$")),$p=Object.keys(Rs).reduce((e,t)=>{const r=Rs[t];return r===Pp?e[t]=t:r===kp?e[t.toLowerCase()]=t:e[t]=r,e},{});lt.BOOLEAN=xn,lt.BOOLEANISH_STRING=bn,lt.NUMERIC=Ds,lt.OVERLOADED_BOOLEAN=io,lt.POSITIVE_NUMERIC=Ms,lt.RESERVED=$s,lt.STRING=jt,lt.getPropertyInfo=Ap,lt.isCustomAttribute=Ip,lt.possibleStandardNames=$p;var so={},lo={},Ns=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,Dp=/\n/g,Mp=/^\s*/,Rp=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,Np=/^:\s*/,Fp=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,Lp=/^[;\s]*/,zp=/^\s+|\s+$/g,Bp=`
|
|
119
|
+
`,Fs="/",Ls="*",Ut="",Up="comment",Vp="declaration",Wp=function(e,t){if(typeof e!="string")throw new TypeError("First argument must be a string");if(!e)return[];t=t||{};var r=1,n=1;function i(g){var m=g.match(Dp);m&&(r+=m.length);var T=g.lastIndexOf(Bp);n=~T?g.length-T:n+g.length}function o(){var g={line:r,column:n};return function(m){return m.position=new a(g),u(),m}}function a(g){this.start=g,this.end={line:r,column:n},this.source=t.source}a.prototype.content=e;function s(g){var m=new Error(t.source+":"+r+":"+n+": "+g);if(m.reason=g,m.filename=t.source,m.line=r,m.column=n,m.source=e,!t.silent)throw m}function l(g){var m=g.exec(e);if(m){var T=m[0];return i(T),e=e.slice(T.length),m}}function u(){l(Mp)}function f(g){var m;for(g=g||[];m=c();)m!==!1&&g.push(m);return g}function c(){var g=o();if(!(Fs!=e.charAt(0)||Ls!=e.charAt(1))){for(var m=2;Ut!=e.charAt(m)&&(Ls!=e.charAt(m)||Fs!=e.charAt(m+1));)++m;if(m+=2,Ut===e.charAt(m-1))return s("End of comment missing");var T=e.slice(2,m-2);return n+=2,i(T),e=e.slice(m),n+=2,g({type:Up,comment:T})}}function p(){var g=o(),m=l(Rp);if(m){if(c(),!l(Np))return s("property missing ':'");var T=l(Fp),j=g({type:Vp,property:zs(m[0].replace(Ns,Ut)),value:T?zs(T[0].replace(Ns,Ut)):Ut});return l(Lp),j}}function y(){var g=[];f(g);for(var m;m=p();)m!==!1&&(g.push(m),f(g));return g}return u(),y()};function zs(e){return e?e.replace(zp,Ut):Ut}var Hp=Ce&&Ce.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(lo,"__esModule",{value:!0}),lo.default=Yp;var Gp=Hp(Wp);function Yp(e,t){var r=null;if(!e||typeof e!="string")return r;var n=(0,Gp.default)(e),i=typeof t=="function";return n.forEach(function(o){if(o.type==="declaration"){var a=o.property,s=o.value;i?t(a,s,o):s&&(r=r||{},r[a]=s)}}),r}var Tn={};Object.defineProperty(Tn,"__esModule",{value:!0}),Tn.camelCase=void 0;var qp=/^--[a-zA-Z0-9_-]+$/,Kp=/-([a-z])/g,Xp=/^[^-]+$/,Jp=/^-(webkit|moz|ms|o|khtml)-/,Zp=/^-(ms)-/,Qp=function(e){return!e||Xp.test(e)||qp.test(e)},eh=function(e,t){return t.toUpperCase()},Bs=function(e,t){return"".concat(t,"-")},th=function(e,t){return t===void 0&&(t={}),Qp(e)?e:(e=e.toLowerCase(),t.reactCompat?e=e.replace(Zp,Bs):e=e.replace(Jp,Bs),e.replace(Kp,eh))};Tn.camelCase=th;var rh=Ce&&Ce.__importDefault||function(e){return e&&e.__esModule?e:{default:e}},nh=rh(lo),ih=Tn;function uo(e,t){var r={};return!e||typeof e!="string"||(0,nh.default)(e,function(n,i){n&&i&&(r[(0,ih.camelCase)(n,t)]=i)}),r}uo.default=uo;var oh=uo;(function(e){var t=Ce&&Ce.__importDefault||function(f){return f&&f.__esModule?f:{default:f}};Object.defineProperty(e,"__esModule",{value:!0}),e.returnFirstArg=e.canTextBeChildOfNode=e.ELEMENTS_WITH_NO_TEXT_CHILDREN=e.PRESERVE_CUSTOM_ATTRIBUTES=void 0,e.isCustomComponent=o,e.setStyleProp=s;var r=_,n=t(oh),i=new Set(["annotation-xml","color-profile","font-face","font-face-src","font-face-uri","font-face-format","font-face-name","missing-glyph"]);function o(f,c){return f.includes("-")?!i.has(f):!!(c&&typeof c.is=="string")}var a={reactCompat:!0};function s(f,c){if(typeof f=="string"){if(!f.trim()){c.style={};return}try{c.style=(0,n.default)(f,a)}catch{c.style={}}}}e.PRESERVE_CUSTOM_ATTRIBUTES=Number(r.version.split(".")[0])>=16,e.ELEMENTS_WITH_NO_TEXT_CHILDREN=new Set(["tr","tbody","thead","tfoot","colgroup","table","head","html","frameset"]);var l=function(f){return!e.ELEMENTS_WITH_NO_TEXT_CHILDREN.has(f.name)};e.canTextBeChildOfNode=l;var u=function(f){return f};e.returnFirstArg=u})(so),Object.defineProperty(yn,"__esModule",{value:!0}),yn.default=uh;var wr=lt,Us=so,ah=["checked","value"],sh=["input","select","textarea"],lh={reset:!0,submit:!0};function uh(e,t){e===void 0&&(e={});var r={},n=!!(e.type&&lh[e.type]);for(var i in e){var o=e[i];if((0,wr.isCustomAttribute)(i)){r[i]=o;continue}var a=i.toLowerCase(),s=Vs(a);if(s){var l=(0,wr.getPropertyInfo)(s);switch(ah.includes(s)&&sh.includes(t)&&!n&&(s=Vs("default"+a)),r[s]=o,l&&l.type){case wr.BOOLEAN:r[s]=!0;break;case wr.OVERLOADED_BOOLEAN:o===""&&(r[s]=!0);break}continue}Us.PRESERVE_CUSTOM_ATTRIBUTES&&(r[i]=o)}return(0,Us.setStyleProp)(e.style,r),r}function Vs(e){return wr.possibleStandardNames[e]}var co={},ch=Ce&&Ce.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(co,"__esModule",{value:!0}),co.default=Ws;var fo=_,fh=ch(yn),Ar=so,dh={cloneElement:fo.cloneElement,createElement:fo.createElement,isValidElement:fo.isValidElement};function Ws(e,t){t===void 0&&(t={});for(var r=[],n=typeof t.replace=="function",i=t.transform||Ar.returnFirstArg,o=t.library||dh,a=o.cloneElement,s=o.createElement,l=o.isValidElement,u=e.length,f=0;f<u;f++){var c=e[f];if(n){var p=t.replace(c,f);if(l(p)){u>1&&(p=a(p,{key:p.key||f})),r.push(i(p,c,f));continue}}if(c.type==="text"){var y=!c.data.trim().length;if(y&&c.parent&&!(0,Ar.canTextBeChildOfNode)(c.parent)||t.trim&&y)continue;r.push(i(c.data,c,f));continue}var g=c,m={};ph(g)?((0,Ar.setStyleProp)(g.attribs.style,g.attribs),m=g.attribs):g.attribs&&(m=(0,fh.default)(g.attribs,g.name));var T=void 0;switch(c.type){case"script":case"style":c.children[0]&&(m.dangerouslySetInnerHTML={__html:c.children[0].data});break;case"tag":c.name==="textarea"&&c.children[0]?m.defaultValue=c.children[0].data:c.children&&c.children.length&&(T=Ws(c.children,t));break;default:continue}u>1&&(m.key=f),r.push(i(s(c.name,m,T),c,f))}return r.length===1?r[0]:r}function ph(e){return Ar.PRESERVE_CUSTOM_ATTRIBUTES&&e.type==="tag"&&(0,Ar.isCustomComponent)(e.name,e.attribs)}(function(e){var t=Ce&&Ce.__importDefault||function(l){return l&&l.__esModule?l:{default:l}};Object.defineProperty(e,"__esModule",{value:!0}),e.htmlToDOM=e.domToReact=e.attributesToProps=e.Text=e.ProcessingInstruction=e.Element=e.Comment=void 0,e.default=s;var r=t(Ki);e.htmlToDOM=r.default;var n=t(yn);e.attributesToProps=n.default;var i=t(co);e.domToReact=i.default;var o=Qi;Object.defineProperty(e,"Comment",{enumerable:!0,get:function(){return o.Comment}}),Object.defineProperty(e,"Element",{enumerable:!0,get:function(){return o.Element}}),Object.defineProperty(e,"ProcessingInstruction",{enumerable:!0,get:function(){return o.ProcessingInstruction}}),Object.defineProperty(e,"Text",{enumerable:!0,get:function(){return o.Text}});var a={lowerCaseAttributeNames:!1};function s(l,u){if(typeof l!="string")throw new TypeError("First argument must be a string");return l?(0,i.default)((0,r.default)(l,(u==null?void 0:u.htmlparser2)||a),u):[]}})(ds);const Hs=yt(ds);Hs.default;/*! @license DOMPurify 3.1.7 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.1.7/LICENSE */const{entries:Gs,setPrototypeOf:Ys,isFrozen:hh,getPrototypeOf:mh,getOwnPropertyDescriptor:gh}=Object;let{freeze:Ve,seal:nt,create:qs}=Object,{apply:po,construct:ho}=typeof Reflect<"u"&&Reflect;Ve||(Ve=function(t){return t}),nt||(nt=function(t){return t}),po||(po=function(t,r,n){return t.apply(r,n)}),ho||(ho=function(t,r){return new t(...r)});const _n=Qe(Array.prototype.forEach),Ks=Qe(Array.prototype.pop),Or=Qe(Array.prototype.push),En=Qe(String.prototype.toLowerCase),mo=Qe(String.prototype.toString),Xs=Qe(String.prototype.match),kr=Qe(String.prototype.replace),yh=Qe(String.prototype.indexOf),vh=Qe(String.prototype.trim),ut=Qe(Object.prototype.hasOwnProperty),We=Qe(RegExp.prototype.test),Pr=bh(TypeError);function Qe(e){return function(t){for(var r=arguments.length,n=new Array(r>1?r-1:0),i=1;i<r;i++)n[i-1]=arguments[i];return po(e,t,n)}}function bh(e){return function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return ho(e,r)}}function se(e,t){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:En;Ys&&Ys(e,null);let n=t.length;for(;n--;){let i=t[n];if(typeof i=="string"){const o=r(i);o!==i&&(hh(t)||(t[n]=o),i=o)}e[i]=!0}return e}function xh(e){for(let t=0;t<e.length;t++)ut(e,t)||(e[t]=null);return e}function Vt(e){const t=qs(null);for(const[r,n]of Gs(e))ut(e,r)&&(Array.isArray(n)?t[r]=xh(n):n&&typeof n=="object"&&n.constructor===Object?t[r]=Vt(n):t[r]=n);return t}function jr(e,t){for(;e!==null;){const n=gh(e,t);if(n){if(n.get)return Qe(n.get);if(typeof n.value=="function")return Qe(n.value)}e=mh(e)}function r(){return null}return r}const Js=Ve(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","section","select","shadow","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),go=Ve(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","filter","font","g","glyph","glyphref","hkern","image","line","lineargradient","marker","mask","metadata","mpath","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),yo=Ve(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),Th=Ve(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),vo=Ve(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),_h=Ve(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Zs=Ve(["#text"]),Qs=Ve(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","face","for","headers","height","hidden","high","href","hreflang","id","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns","slot"]),bo=Ve(["accent-height","accumulate","additive","alignment-baseline","amplitude","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","exponent","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","intercept","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","slope","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","tablevalues","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),el=Ve(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),Sn=Ve(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),Eh=nt(/\{\{[\w\W]*|[\w\W]*\}\}/gm),Sh=nt(/<%[\w\W]*|[\w\W]*%>/gm),Ch=nt(/\${[\w\W]*}/gm),wh=nt(/^data-[\-\w.\u00B7-\uFFFF]/),Ah=nt(/^aria-[\-\w]+$/),tl=nt(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),Oh=nt(/^(?:\w+script|data):/i),kh=nt(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),rl=nt(/^html$/i),Ph=nt(/^[a-z][.\w]*(-[.\w]+)+$/i);var nl=Object.freeze({__proto__:null,MUSTACHE_EXPR:Eh,ERB_EXPR:Sh,TMPLIT_EXPR:Ch,DATA_ATTR:wh,ARIA_ATTR:Ah,IS_ALLOWED_URI:tl,IS_SCRIPT_OR_DATA:Oh,ATTR_WHITESPACE:kh,DOCTYPE_NAME:rl,CUSTOM_ELEMENT:Ph});const Ir={element:1,attribute:2,text:3,cdataSection:4,entityReference:5,entityNode:6,progressingInstruction:7,comment:8,document:9,documentType:10,documentFragment:11,notation:12},jh=function(){return typeof window>"u"?null:window},Ih=function(t,r){if(typeof t!="object"||typeof t.createPolicy!="function")return null;let n=null;const i="data-tt-policy-suffix";r&&r.hasAttribute(i)&&(n=r.getAttribute(i));const o="dompurify"+(n?"#"+n:"");try{return t.createPolicy(o,{createHTML(a){return a},createScriptURL(a){return a}})}catch{return console.warn("TrustedTypes policy "+o+" could not be created."),null}};function il(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:jh();const t=P=>il(P);if(t.version="3.1.7",t.removed=[],!e||!e.document||e.document.nodeType!==Ir.document)return t.isSupported=!1,t;let{document:r}=e;const n=r,i=n.currentScript,{DocumentFragment:o,HTMLTemplateElement:a,Node:s,Element:l,NodeFilter:u,NamedNodeMap:f=e.NamedNodeMap||e.MozNamedAttrMap,HTMLFormElement:c,DOMParser:p,trustedTypes:y}=e,g=l.prototype,m=jr(g,"cloneNode"),T=jr(g,"remove"),j=jr(g,"nextSibling"),F=jr(g,"childNodes"),D=jr(g,"parentNode");if(typeof a=="function"){const P=r.createElement("template");P.content&&P.content.ownerDocument&&(r=P.content.ownerDocument)}let O,E="";const{implementation:M,createNodeIterator:Y,createDocumentFragment:ce,getElementsByTagName:ie}=r,{importNode:h}=n;let A={};t.isSupported=typeof Gs=="function"&&typeof D=="function"&&M&&M.createHTMLDocument!==void 0;const{MUSTACHE_EXPR:U,ERB_EXPR:H,TMPLIT_EXPR:te,DATA_ATTR:ve,ARIA_ATTR:G,IS_SCRIPT_OR_DATA:oe,ATTR_WHITESPACE:le,CUSTOM_ELEMENT:He}=nl;let{IS_ALLOWED_URI:k}=nl,$=null;const Z=se({},[...Js,...go,...yo,...vo,...Zs]);let B=null;const X=se({},[...Qs,...bo,...el,...Sn]);let V=Object.seal(qs(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),q=null,J=null,Q=!0,re=!0,ee=!1,Ie=!0,N=!1,Me=!0,z=!1,Ge=!1,Ke=!1,at=!1,Yt=!1,Et=!1,ri=!0,ni=!1;const Wr="user-content-";let Hr=!0,qt=!1,St={},Ct=null;const Mt=se({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let ii=null;const Gr=se({},["audio","video","img","source","image","track"]);let gr=null;const yr=se({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),vr="http://www.w3.org/1998/Math/MathML",br="http://www.w3.org/2000/svg",ft="http://www.w3.org/1999/xhtml";let Rt=ft,Yr=!1,qr=null;const da=se({},[vr,br,ft],mo);let wt=null;const oi=["application/xhtml+xml","text/html"],Nt="text/html";let Pe=null,gt=null;const ai=r.createElement("form"),si=function(x){return x instanceof RegExp||x instanceof Function},xr=function(){let x=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!(gt&>===x)){if((!x||typeof x!="object")&&(x={}),x=Vt(x),wt=oi.indexOf(x.PARSER_MEDIA_TYPE)===-1?Nt:x.PARSER_MEDIA_TYPE,Pe=wt==="application/xhtml+xml"?mo:En,$=ut(x,"ALLOWED_TAGS")?se({},x.ALLOWED_TAGS,Pe):Z,B=ut(x,"ALLOWED_ATTR")?se({},x.ALLOWED_ATTR,Pe):X,qr=ut(x,"ALLOWED_NAMESPACES")?se({},x.ALLOWED_NAMESPACES,mo):da,gr=ut(x,"ADD_URI_SAFE_ATTR")?se(Vt(yr),x.ADD_URI_SAFE_ATTR,Pe):yr,ii=ut(x,"ADD_DATA_URI_TAGS")?se(Vt(Gr),x.ADD_DATA_URI_TAGS,Pe):Gr,Ct=ut(x,"FORBID_CONTENTS")?se({},x.FORBID_CONTENTS,Pe):Mt,q=ut(x,"FORBID_TAGS")?se({},x.FORBID_TAGS,Pe):{},J=ut(x,"FORBID_ATTR")?se({},x.FORBID_ATTR,Pe):{},St=ut(x,"USE_PROFILES")?x.USE_PROFILES:!1,Q=x.ALLOW_ARIA_ATTR!==!1,re=x.ALLOW_DATA_ATTR!==!1,ee=x.ALLOW_UNKNOWN_PROTOCOLS||!1,Ie=x.ALLOW_SELF_CLOSE_IN_ATTR!==!1,N=x.SAFE_FOR_TEMPLATES||!1,Me=x.SAFE_FOR_XML!==!1,z=x.WHOLE_DOCUMENT||!1,at=x.RETURN_DOM||!1,Yt=x.RETURN_DOM_FRAGMENT||!1,Et=x.RETURN_TRUSTED_TYPE||!1,Ke=x.FORCE_BODY||!1,ri=x.SANITIZE_DOM!==!1,ni=x.SANITIZE_NAMED_PROPS||!1,Hr=x.KEEP_CONTENT!==!1,qt=x.IN_PLACE||!1,k=x.ALLOWED_URI_REGEXP||tl,Rt=x.NAMESPACE||ft,V=x.CUSTOM_ELEMENT_HANDLING||{},x.CUSTOM_ELEMENT_HANDLING&&si(x.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(V.tagNameCheck=x.CUSTOM_ELEMENT_HANDLING.tagNameCheck),x.CUSTOM_ELEMENT_HANDLING&&si(x.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(V.attributeNameCheck=x.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),x.CUSTOM_ELEMENT_HANDLING&&typeof x.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(V.allowCustomizedBuiltInElements=x.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),N&&(re=!1),Yt&&(at=!0),St&&($=se({},Zs),B=[],St.html===!0&&(se($,Js),se(B,Qs)),St.svg===!0&&(se($,go),se(B,bo),se(B,Sn)),St.svgFilters===!0&&(se($,yo),se(B,bo),se(B,Sn)),St.mathMl===!0&&(se($,vo),se(B,el),se(B,Sn))),x.ADD_TAGS&&($===Z&&($=Vt($)),se($,x.ADD_TAGS,Pe)),x.ADD_ATTR&&(B===X&&(B=Vt(B)),se(B,x.ADD_ATTR,Pe)),x.ADD_URI_SAFE_ATTR&&se(gr,x.ADD_URI_SAFE_ATTR,Pe),x.FORBID_CONTENTS&&(Ct===Mt&&(Ct=Vt(Ct)),se(Ct,x.FORBID_CONTENTS,Pe)),Hr&&($["#text"]=!0),z&&se($,["html","head","body"]),$.table&&(se($,["tbody"]),delete q.tbody),x.TRUSTED_TYPES_POLICY){if(typeof x.TRUSTED_TYPES_POLICY.createHTML!="function")throw Pr('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof x.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw Pr('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');O=x.TRUSTED_TYPES_POLICY,E=O.createHTML("")}else O===void 0&&(O=Ih(y,i)),O!==null&&typeof E=="string"&&(E=O.createHTML(""));Ve&&Ve(x),gt=x}},li=se({},["mi","mo","mn","ms","mtext"]),Kr=se({},["annotation-xml"]),ui=se({},["title","style","font","a","script"]),ci=se({},[...go,...yo,...Th]),fi=se({},[...vo,..._h]),di=function(x){let C=D(x);(!C||!C.tagName)&&(C={namespaceURI:Rt,tagName:"template"});const R=En(x.tagName),ne=En(C.tagName);return qr[x.namespaceURI]?x.namespaceURI===br?C.namespaceURI===ft?R==="svg":C.namespaceURI===vr?R==="svg"&&(ne==="annotation-xml"||li[ne]):!!ci[R]:x.namespaceURI===vr?C.namespaceURI===ft?R==="math":C.namespaceURI===br?R==="math"&&Kr[ne]:!!fi[R]:x.namespaceURI===ft?C.namespaceURI===br&&!Kr[ne]||C.namespaceURI===vr&&!li[ne]?!1:!fi[R]&&(ui[R]||!ci[R]):!!(wt==="application/xhtml+xml"&&qr[x.namespaceURI]):!1},rt=function(x){Or(t.removed,{element:x});try{D(x).removeChild(x)}catch{T(x)}},Tr=function(x,C){try{Or(t.removed,{attribute:C.getAttributeNode(x),from:C})}catch{Or(t.removed,{attribute:null,from:C})}if(C.removeAttribute(x),x==="is"&&!B[x])if(at||Yt)try{rt(C)}catch{}else try{C.setAttribute(x,"")}catch{}},pi=function(x){let C=null,R=null;if(Ke)x="<remove></remove>"+x;else{const Se=Xs(x,/^[\r\n\t ]+/);R=Se&&Se[0]}wt==="application/xhtml+xml"&&Rt===ft&&(x='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+x+"</body></html>");const ne=O?O.createHTML(x):x;if(Rt===ft)try{C=new p().parseFromString(ne,wt)}catch{}if(!C||!C.documentElement){C=M.createDocument(Rt,"template",null);try{C.documentElement.innerHTML=Yr?E:ne}catch{}}const Ae=C.body||C.documentElement;return x&&R&&Ae.insertBefore(r.createTextNode(R),Ae.childNodes[0]||null),Rt===ft?ie.call(C,z?"html":"body")[0]:z?C.documentElement:Ae},hi=function(x){return Y.call(x.ownerDocument||x,x,u.SHOW_ELEMENT|u.SHOW_COMMENT|u.SHOW_TEXT|u.SHOW_PROCESSING_INSTRUCTION|u.SHOW_CDATA_SECTION,null)},mi=function(x){return x instanceof c&&(typeof x.nodeName!="string"||typeof x.textContent!="string"||typeof x.removeChild!="function"||!(x.attributes instanceof f)||typeof x.removeAttribute!="function"||typeof x.setAttribute!="function"||typeof x.namespaceURI!="string"||typeof x.insertBefore!="function"||typeof x.hasChildNodes!="function")},v=function(x){return typeof s=="function"&&x instanceof s},w=function(x,C,R){A[x]&&_n(A[x],ne=>{ne.call(t,C,R,gt)})},L=function(x){let C=null;if(w("beforeSanitizeElements",x,null),mi(x))return rt(x),!0;const R=Pe(x.nodeName);if(w("uponSanitizeElement",x,{tagName:R,allowedTags:$}),x.hasChildNodes()&&!v(x.firstElementChild)&&We(/<[/\w]/g,x.innerHTML)&&We(/<[/\w]/g,x.textContent)||x.nodeType===Ir.progressingInstruction||Me&&x.nodeType===Ir.comment&&We(/<[/\w]/g,x.data))return rt(x),!0;if(!$[R]||q[R]){if(!q[R]&&fe(R)&&(V.tagNameCheck instanceof RegExp&&We(V.tagNameCheck,R)||V.tagNameCheck instanceof Function&&V.tagNameCheck(R)))return!1;if(Hr&&!Ct[R]){const ne=D(x)||x.parentNode,Ae=F(x)||x.childNodes;if(Ae&&ne){const Se=Ae.length;for(let be=Se-1;be>=0;--be){const Xe=m(Ae[be],!0);Xe.__removalCount=(x.__removalCount||0)+1,ne.insertBefore(Xe,j(x))}}}return rt(x),!0}return x instanceof l&&!di(x)||(R==="noscript"||R==="noembed"||R==="noframes")&&We(/<\/no(script|embed|frames)/i,x.innerHTML)?(rt(x),!0):(N&&x.nodeType===Ir.text&&(C=x.textContent,_n([U,H,te],ne=>{C=kr(C,ne," ")}),x.textContent!==C&&(Or(t.removed,{element:x.cloneNode()}),x.textContent=C)),w("afterSanitizeElements",x,null),!1)},K=function(x,C,R){if(ri&&(C==="id"||C==="name")&&(R in r||R in ai))return!1;if(!(re&&!J[C]&&We(ve,C))){if(!(Q&&We(G,C))){if(!B[C]||J[C]){if(!(fe(x)&&(V.tagNameCheck instanceof RegExp&&We(V.tagNameCheck,x)||V.tagNameCheck instanceof Function&&V.tagNameCheck(x))&&(V.attributeNameCheck instanceof RegExp&&We(V.attributeNameCheck,C)||V.attributeNameCheck instanceof Function&&V.attributeNameCheck(C))||C==="is"&&V.allowCustomizedBuiltInElements&&(V.tagNameCheck instanceof RegExp&&We(V.tagNameCheck,R)||V.tagNameCheck instanceof Function&&V.tagNameCheck(R))))return!1}else if(!gr[C]){if(!We(k,kr(R,le,""))){if(!((C==="src"||C==="xlink:href"||C==="href")&&x!=="script"&&yh(R,"data:")===0&&ii[x])){if(!(ee&&!We(oe,kr(R,le,"")))){if(R)return!1}}}}}}return!0},fe=function(x){return x!=="annotation-xml"&&Xs(x,He)},ye=function(x){w("beforeSanitizeAttributes",x,null);const{attributes:C}=x;if(!C)return;const R={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:B};let ne=C.length;for(;ne--;){const Ae=C[ne],{name:Se,namespaceURI:be,value:Xe}=Ae,Kt=Pe(Se);let Ne=Se==="value"?Xe:vh(Xe);if(R.attrName=Kt,R.attrValue=Ne,R.keepAttr=!0,R.forceKeepAttr=void 0,w("uponSanitizeAttribute",x,R),Ne=R.attrValue,R.forceKeepAttr||(Tr(Se,x),!R.keepAttr))continue;if(!Ie&&We(/\/>/i,Ne)){Tr(Se,x);continue}N&&_n([U,H,te],jf=>{Ne=kr(Ne,jf," ")});const Pf=Pe(x.nodeName);if(K(Pf,Kt,Ne)){if(ni&&(Kt==="id"||Kt==="name")&&(Tr(Se,x),Ne=Wr+Ne),Me&&We(/((--!?|])>)|<\/(style|title)/i,Ne)){Tr(Se,x);continue}if(O&&typeof y=="object"&&typeof y.getAttributeType=="function"&&!be)switch(y.getAttributeType(Pf,Kt)){case"TrustedHTML":{Ne=O.createHTML(Ne);break}case"TrustedScriptURL":{Ne=O.createScriptURL(Ne);break}}try{be?x.setAttributeNS(be,Se,Ne):x.setAttribute(Se,Ne),mi(x)?rt(x):Ks(t.removed)}catch{}}}w("afterSanitizeAttributes",x,null)},ue=function P(x){let C=null;const R=hi(x);for(w("beforeSanitizeShadowDOM",x,null);C=R.nextNode();)w("uponSanitizeShadowNode",C,null),!L(C)&&(C.content instanceof o&&P(C.content),ye(C));w("afterSanitizeShadowDOM",x,null)};return t.sanitize=function(P){let x=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},C=null,R=null,ne=null,Ae=null;if(Yr=!P,Yr&&(P="<!-->"),typeof P!="string"&&!v(P))if(typeof P.toString=="function"){if(P=P.toString(),typeof P!="string")throw Pr("dirty is not a string, aborting")}else throw Pr("toString is not a function");if(!t.isSupported)return P;if(Ge||xr(x),t.removed=[],typeof P=="string"&&(qt=!1),qt){if(P.nodeName){const Xe=Pe(P.nodeName);if(!$[Xe]||q[Xe])throw Pr("root node is forbidden and cannot be sanitized in-place")}}else if(P instanceof s)C=pi("<!---->"),R=C.ownerDocument.importNode(P,!0),R.nodeType===Ir.element&&R.nodeName==="BODY"||R.nodeName==="HTML"?C=R:C.appendChild(R);else{if(!at&&!N&&!z&&P.indexOf("<")===-1)return O&&Et?O.createHTML(P):P;if(C=pi(P),!C)return at?null:Et?E:""}C&&Ke&&rt(C.firstChild);const Se=hi(qt?P:C);for(;ne=Se.nextNode();)L(ne)||(ne.content instanceof o&&ue(ne.content),ye(ne));if(qt)return P;if(at){if(Yt)for(Ae=ce.call(C.ownerDocument);C.firstChild;)Ae.appendChild(C.firstChild);else Ae=C;return(B.shadowroot||B.shadowrootmode)&&(Ae=h.call(n,Ae,!0)),Ae}let be=z?C.outerHTML:C.innerHTML;return z&&$["!doctype"]&&C.ownerDocument&&C.ownerDocument.doctype&&C.ownerDocument.doctype.name&&We(rl,C.ownerDocument.doctype.name)&&(be="<!DOCTYPE "+C.ownerDocument.doctype.name+`>
|
|
120
|
+
`+be),N&&_n([U,H,te],Xe=>{be=kr(be,Xe," ")}),O&&Et?O.createHTML(be):be},t.setConfig=function(){let P=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};xr(P),Ge=!0},t.clearConfig=function(){gt=null,Ge=!1},t.isValidAttribute=function(P,x,C){gt||xr({});const R=Pe(P),ne=Pe(x);return K(R,ne,C)},t.addHook=function(P,x){typeof x=="function"&&(A[P]=A[P]||[],Or(A[P],x))},t.removeHook=function(P){if(A[P])return Ks(A[P])},t.removeHooks=function(P){A[P]&&(A[P]=[])},t.removeAllHooks=function(){A={}},t}var $h=il();const Dh={field:"_field_zdaf7_1",rtl:"_rtl_zdaf7_7",borderRight:"_borderRight_zdaf7_12"},Cn=_.memo(({id:e,entry:t,loading:r,rightBorder:n,children:i,onClickEntry:o,customElement:a,sanitize:s,...l})=>{const u={text:{style:{whiteSpace:"nowrap",overflow:"ellipsis"}}},{text:f}=b.useProps("Field",u,l),c={};Object.entries(f).forEach(([g,m])=>{typeof m=="function"&&(c[g]=m(t))});let p;s&&(p=$h.sanitize(i));const y=b.useStyles({name:"Field",props:l,classes:Dh});return d.jsx(b.Table.Td,{...y("field"),onClick:o?()=>o(e,t):null,...l,children:d.jsx(b.Box,{w:"100%",children:d.jsx(b.Skeleton,{visible:r,children:a||(typeof i!="object"?d.jsx(b.Text,{...f,...c,children:p||i}):p||i)})})})});Cn.displayName="Field";const ol={row:"_row_138r2_1",selected:"_selected_138r2_5"};function Mh({entry:e,selected:t,children:r}){const n=b.useStyles({name:"Row",classes:ol}),i=b.useProps("Row",{},{});Object.entries(i).forEach(([s,l])=>{typeof l=="function"&&(i[s]=l(e))});var{className:o,style:a}=n("row");return o=`${o} ${t?ol.selected:""}`,d.jsx(b.Table.Tr,{className:o,style:{...a},...i,children:r})}function Rh({bodyCustomizer:e,actionColumn:t,id:r,entry:n}){let i=e==null?void 0:e[t];return typeof i=="function"&&(i=i({id:r,...n})),i===null?null:i||d.jsx(fs,{id:r})}function Nh({data:e,loading:t,hideActions:r,hideCheckbox:n,selection:i,toggleRow:o,onClickEntry:a,bodyCustomizer:s}){const l=e.list_columns.includes("actions")?"_actions":"actions";return d.jsx(b.Table.Tbody,{children:e.result.length?e.result.map((u,f)=>{const c=e.ids[f];return d.jsxs(Mh,{entry:{...u,id:c},children:[n?null:d.jsx(Cn,{loading:t,children:d.jsx(b.Checkbox,{pl:2,checked:i.includes(c),onChange:p=>{o(c)}})},f),r?null:d.jsx(Cn,{loading:t,children:d.jsx(Rh,{bodyCustomizer:s,actionColumn:l,id:Ze(c),entry:u})}),e.list_columns.map((p,y)=>{let g=s==null?void 0:s[p];return typeof g=="function"&&(g=g({id:c,...u})),g===null?null:d.jsx(Cn,{id:c,entry:u,loading:t,onClickEntry:a,customElement:g,sanitize:!0,children:qi(u,p)},y)})]},Ze(c))}):d.jsx("tr",{children:d.jsx("td",{style:{padding:"8px"},colSpan:r?e.list_columns.length:e.list_columns.length+1,children:d.jsx(b.Text,{style:{fontStyle:"italic"},size:"sm",c:"dimmed",children:"No data available..."})})})})}const Fh={scrollbar:"_scrollbar_isyo2_1"};function Lh({bulkActions:e,hideActions:t,loading:r,onSelectCheckbox:n,onClickEntry:i,hideCheckbox:o,hideDownload:a,headerCustomizer:s,bodyCustomizer:l,...u}){const f=b.useMantineTheme(),c=b.Table.extend({highlightOnHover:!0,striped:!0,horizontalSpacing:"md",verticalSpacing:"sm"}),p=b.useProps("DatagridTable",c,u),{data:y,info:g}=De(),[m,T]=_.useState([]),[j,F]=_.useState(!1),D=E=>{T(M=>M.includes(E)?M.filter(Y=>Y!==E):[...M,E])},O=()=>{T(E=>E.length===y.ids.length?[]:y.ids.map((M,Y)=>M))};return _.useEffect(()=>{F(m.length===y.result.length&&m.length>0),n&&n(m),e==null||e.setSelectedIds(m.map(E=>E))},[m]),_.useEffect(()=>{T([]),n&&n([])},[y]),d.jsx(b.ScrollArea,{options:{className:f.colorScheme==="dark"?"os-theme-light":void 0},style:{flex:1,flexDirection:"column"},classNames:Fh,children:d.jsxs(b.Table,{stickyHeader:!0,...p,children:[d.jsx(os,{data:y,info:g,hideActions:t,hideCheckbox:o,allChecked:j,setSelection:T,toggleAll:O,headerCustomizer:s}),d.jsx(Nh,{data:y,loading:r,hideActions:t,hideCheckbox:o,selection:m,setSelection:T,toggleRow:D,onClickEntry:i,bodyCustomizer:l})]})})}const al=_.memo(({...e})=>{const{data:t,queryParams:r,setQueryParams:n}=De(),i=[{value:"10",label:"10"},{value:"25",label:"25"},{value:"50",label:"50"}],o=String(r.page_size),[a,s]=_.useState(r.page);_.useEffect(()=>{s(r.page)},[r.page]);const l=f=>{s(f-1),n({page:f-1})},u=f=>{n({page_size:parseInt(f,10),page:0})};return d.jsxs(d.Fragment,{children:[d.jsx(b.Divider,{}),d.jsxs(b.Box,{style:{display:"flex",justifyContent:"space-between",alignItems:"center",height:54,border:"none",borderTopWidth:"1px",padding:"var(--mantine-spacing-md)"},children:[d.jsxs(b.Box,{style:{display:"flex",alignItems:"center",gap:"var(--mantine-spacing-sm)"},children:[d.jsx(b.Text,{children:"Rows per page:"}),d.jsx(b.Select,{value:o,defaultValue:o,onChange:f=>u(f),data:i,allowDeselect:!1,w:80,size:"xs",styles:()=>({input:{fontSize:"14px",fontWeight:"250",lineHeight:"52px",border:"1px solid #E6E8ED"},item:{"&[data-selected]":{"&, &:hover":{outline:"none !important"}}}})})]}),d.jsx(b.Pagination,{size:"sm",total:Math.ceil(t.count/o),value:a+1,onChange:l,...e})]})]})});al.displayName="Pagination";function zh(){const{error:e}=De(),[t,r]=_.useState(!1);return _.useEffect(()=>{e&&r(!0)},[e]),d.jsx(b.Modal,{opened:t,onClose:()=>r(!1),title:d.jsxs(b.Group,{children:[d.jsx(Gd,{size:16,color:"red"}),d.jsx(b.Text,{children:e?e.originalError.detail||e.originalError.message:"Error"})]}),centered:!0,children:e?d.jsx(b.Text,{children:e.message}):null})}const xo=_.forwardRef((e,t)=>{const{path:r,data:n,loading:i,info:o,setQueryParams:a}=De(),{hideToolbar:s=!1,hideFilter:l=!1,hideAdd:u=!1,hideSettings:f=!1,hideActions:c=!1,hidePagination:p=!1,hideError:y=!1,hideDownload:g=!0,onSelectCheckbox:m=null,onClickEntry:T=null,fetchOnMount:j=!0,bulkActions:F=null,styles:D,headerCustomizer:O={},bodyCustomizer:E={},toolbarCustomizer:M={}}=e;if(_.useEffect(()=>{!n&&j&&a({})},[n]),!o)return;const Y=F===null;return d.jsxs(b.Paper,{ref:t,style:{position:"relative",height:"100%",display:"flex",flexDirection:"column",...D},children:[s?null:d.jsx(ns,{hideFilter:l,hideAdd:u,hideSettings:f,hideDownload:g,toolbarCustomizer:M}),n?d.jsx(Lh,{bulkActions:F,hideActions:c,loading:i,onSelectCheckbox:m,onClickEntry:T,hideCheckbox:Y,hideDownload:g,headerCustomizer:O,bodyCustomizer:E}):null,!p&&n?d.jsx(al,{}):null,y?null:d.jsx(zh,{})]})});xo.displayName="DataGrid";function Bh({children:e,fetch:t=!0,loading:r=d.jsx(b.Center,{children:d.jsx(b.Loader,{})}),end:n=d.jsx(b.Center,{children:"End of data"}),fetchWrapper:i=b.Center,fetchWrapperProps:o}){const{streaming:a,loading:s}=De(),{ref:l,inViewport:u}=At.useInViewport(),f=_.useMemo(()=>Object.values(a.data).flat(),[a.data]),c=_.useMemo(()=>typeof e=="function"?e(f):e,[e,f]);return _.useEffect(()=>{u&&t&&a.fetch()},[u]),d.jsxs(d.Fragment,{children:[c,s&&r,a.isEnd&&n,d.jsx(i,{ref:l,id:"IS-load-trigger",mih:"1%",...o})]})}var Uh=Object.prototype;function Vh(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||Uh;return e===r}var wn=Vh;function Wh(e,t){return function(r){return e(t(r))}}var sl=Wh,Hh=sl,Gh=Hh(Object.keys,Object),Yh=Gh,qh=wn,Kh=Yh,Xh=Object.prototype,Jh=Xh.hasOwnProperty;function Zh(e){if(!qh(e))return Kh(e);var t=[];for(var r in Object(e))Jh.call(e,r)&&r!="constructor"&&t.push(r);return t}var Qh=Zh,em=typeof Ce=="object"&&Ce&&Ce.Object===Object&&Ce,ll=em,tm=ll,rm=typeof self=="object"&&self&&self.Object===Object&&self,nm=tm||rm||Function("return this")(),ct=nm,im=ct,om=im.Symbol,An=om,ul=An,cl=Object.prototype,am=cl.hasOwnProperty,sm=cl.toString,$r=ul?ul.toStringTag:void 0;function lm(e){var t=am.call(e,$r),r=e[$r];try{e[$r]=void 0;var n=!0}catch{}var i=sm.call(e);return n&&(t?e[$r]=r:delete e[$r]),i}var um=lm,cm=Object.prototype,fm=cm.toString;function dm(e){return fm.call(e)}var pm=dm,fl=An,hm=um,mm=pm,gm="[object Null]",ym="[object Undefined]",dl=fl?fl.toStringTag:void 0;function vm(e){return e==null?e===void 0?ym:gm:dl&&dl in Object(e)?hm(e):mm(e)}var er=vm;function bm(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var bt=bm,xm=er,Tm=bt,_m="[object AsyncFunction]",Em="[object Function]",Sm="[object GeneratorFunction]",Cm="[object Proxy]";function wm(e){if(!Tm(e))return!1;var t=xm(e);return t==Em||t==Sm||t==_m||t==Cm}var To=wm,Am=ct,Om=Am["__core-js_shared__"],km=Om,_o=km,pl=function(){var e=/[^.]+$/.exec(_o&&_o.keys&&_o.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function Pm(e){return!!pl&&pl in e}var jm=Pm,Im=Function.prototype,$m=Im.toString;function Dm(e){if(e!=null){try{return $m.call(e)}catch{}try{return e+""}catch{}}return""}var hl=Dm,Mm=To,Rm=jm,Nm=bt,Fm=hl,Lm=/[\\^$.*+?()[\]{}|]/g,zm=/^\[object .+?Constructor\]$/,Bm=Function.prototype,Um=Object.prototype,Vm=Bm.toString,Wm=Um.hasOwnProperty,Hm=RegExp("^"+Vm.call(Wm).replace(Lm,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Gm(e){if(!Nm(e)||Rm(e))return!1;var t=Mm(e)?Hm:zm;return t.test(Fm(e))}var Ym=Gm;function qm(e,t){return e==null?void 0:e[t]}var Km=qm,Xm=Ym,Jm=Km;function Zm(e,t){var r=Jm(e,t);return Xm(r)?r:void 0}var Wt=Zm,Qm=Wt,eg=ct,tg=Qm(eg,"DataView"),rg=tg,ng=Wt,ig=ct,og=ng(ig,"Map"),Eo=og,ag=Wt,sg=ct,lg=ag(sg,"Promise"),ug=lg,cg=Wt,fg=ct,dg=cg(fg,"Set"),ml=dg,pg=Wt,hg=ct,mg=pg(hg,"WeakMap"),gg=mg,So=rg,Co=Eo,wo=ug,Ao=ml,Oo=gg,gl=er,tr=hl,yl="[object Map]",yg="[object Object]",vl="[object Promise]",bl="[object Set]",xl="[object WeakMap]",Tl="[object DataView]",vg=tr(So),bg=tr(Co),xg=tr(wo),Tg=tr(Ao),_g=tr(Oo),Ht=gl;(So&&Ht(new So(new ArrayBuffer(1)))!=Tl||Co&&Ht(new Co)!=yl||wo&&Ht(wo.resolve())!=vl||Ao&&Ht(new Ao)!=bl||Oo&&Ht(new Oo)!=xl)&&(Ht=function(e){var t=gl(e),r=t==yg?e.constructor:void 0,n=r?tr(r):"";if(n)switch(n){case vg:return Tl;case bg:return yl;case xg:return vl;case Tg:return bl;case _g:return xl}return t});var Eg=Ht;function Sg(e){return e!=null&&typeof e=="object"}var rr=Sg,Cg=er,wg=rr,Ag="[object Arguments]";function Og(e){return wg(e)&&Cg(e)==Ag}var kg=Og,_l=kg,Pg=rr,El=Object.prototype,jg=El.hasOwnProperty,Ig=El.propertyIsEnumerable,$g=_l(function(){return arguments}())?_l:function(e){return Pg(e)&&jg.call(e,"callee")&&!Ig.call(e,"callee")},On=$g,Dg=Array.isArray,Dr=Dg,Mg=9007199254740991;function Rg(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=Mg}var Sl=Rg,Ng=To,Fg=Sl;function Lg(e){return e!=null&&Fg(e.length)&&!Ng(e)}var kn=Lg,Pn={exports:{}};function zg(){return!1}var Bg=zg;Pn.exports,function(e,t){var r=ct,n=Bg,i=t&&!t.nodeType&&t,o=i&&!0&&e&&!e.nodeType&&e,a=o&&o.exports===i,s=a?r.Buffer:void 0,l=s?s.isBuffer:void 0,u=l||n;e.exports=u}(Pn,Pn.exports);var ko=Pn.exports,Ug=er,Vg=Sl,Wg=rr,Hg="[object Arguments]",Gg="[object Array]",Yg="[object Boolean]",qg="[object Date]",Kg="[object Error]",Xg="[object Function]",Jg="[object Map]",Zg="[object Number]",Qg="[object Object]",ey="[object RegExp]",ty="[object Set]",ry="[object String]",ny="[object WeakMap]",iy="[object ArrayBuffer]",oy="[object DataView]",ay="[object Float32Array]",sy="[object Float64Array]",ly="[object Int8Array]",uy="[object Int16Array]",cy="[object Int32Array]",fy="[object Uint8Array]",dy="[object Uint8ClampedArray]",py="[object Uint16Array]",hy="[object Uint32Array]",Ee={};Ee[ay]=Ee[sy]=Ee[ly]=Ee[uy]=Ee[cy]=Ee[fy]=Ee[dy]=Ee[py]=Ee[hy]=!0,Ee[Hg]=Ee[Gg]=Ee[iy]=Ee[Yg]=Ee[oy]=Ee[qg]=Ee[Kg]=Ee[Xg]=Ee[Jg]=Ee[Zg]=Ee[Qg]=Ee[ey]=Ee[ty]=Ee[ry]=Ee[ny]=!1;function my(e){return Wg(e)&&Vg(e.length)&&!!Ee[Ug(e)]}var gy=my;function yy(e){return function(t){return e(t)}}var vy=yy,jn={exports:{}};jn.exports,function(e,t){var r=ll,n=t&&!t.nodeType&&t,i=n&&!0&&e&&!e.nodeType&&e,o=i&&i.exports===n,a=o&&r.process,s=function(){try{var l=i&&i.require&&i.require("util").types;return l||a&&a.binding&&a.binding("util")}catch{}}();e.exports=s}(jn,jn.exports);var by=jn.exports,xy=gy,Ty=vy,Cl=by,wl=Cl&&Cl.isTypedArray,_y=wl?Ty(wl):xy,Po=_y,Ey=Qh,Sy=Eg,Cy=On,wy=Dr,Ay=kn,Oy=ko,ky=wn,Py=Po,jy="[object Map]",Iy="[object Set]",$y=Object.prototype,Dy=$y.hasOwnProperty;function My(e){if(e==null)return!0;if(Ay(e)&&(wy(e)||typeof e=="string"||typeof e.splice=="function"||Oy(e)||Py(e)||Cy(e)))return!e.length;var t=Sy(e);if(t==jy||t==Iy)return!e.size;if(ky(e))return!Ey(e).length;for(var r in e)if(Dy.call(e,r))return!1;return!0}var Ry=My;const Al=yt(Ry),Ol=(e,t,r,n,i,o,a)=>e.map((s,l)=>d.jsx(b.Grid.Col,{span:i==="row"?12/e.length:12,style:{alignContent:"end"},children:d.jsx(_e.JsonFormsDispatch,{uischema:s,schema:t,path:r,enabled:n,renderers:o,cells:a})},`${r}-${l}`)),Ny=({elements:e,schema:t,path:r,enabled:n,direction:i,renderers:o,cells:a})=>Al(e)?null:d.jsx(b.Grid,{spacing:i==="row"?2:0,children:Ol(e,t,r,n,i,o,a)}),jo=_.memo(Ny),Fy=e=>function(r){const n=_e.useJsonForms(),i=W.getAjv({jsonforms:{...n}});return d.jsx(e,{...r,ajv:i})};var Ly=ct,zy=function(){return Ly.Date.now()},By=zy,Uy=/\s/;function Vy(e){for(var t=e.length;t--&&Uy.test(e.charAt(t)););return t}var Wy=Vy,Hy=Wy,Gy=/^\s+/;function Yy(e){return e&&e.slice(0,Hy(e)+1).replace(Gy,"")}var qy=Yy,Ky=er,Xy=rr,Jy="[object Symbol]";function Zy(e){return typeof e=="symbol"||Xy(e)&&Ky(e)==Jy}var kl=Zy,Qy=qy,Pl=bt,e0=kl,jl=NaN,t0=/^[-+]0x[0-9a-f]+$/i,r0=/^0b[01]+$/i,n0=/^0o[0-7]+$/i,i0=parseInt;function o0(e){if(typeof e=="number")return e;if(e0(e))return jl;if(Pl(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=Pl(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=Qy(e);var r=r0.test(e);return r||n0.test(e)?i0(e.slice(2),r?2:8):t0.test(e)?jl:+e}var Il=o0,a0=bt,Io=By,$l=Il,s0="Expected a function",l0=Math.max,u0=Math.min;function c0(e,t,r){var n,i,o,a,s,l,u=0,f=!1,c=!1,p=!0;if(typeof e!="function")throw new TypeError(s0);t=$l(t)||0,a0(r)&&(f=!!r.leading,c="maxWait"in r,o=c?l0($l(r.maxWait)||0,t):o,p="trailing"in r?!!r.trailing:p);function y(M){var Y=n,ce=i;return n=i=void 0,u=M,a=e.apply(ce,Y),a}function g(M){return u=M,s=setTimeout(j,t),f?y(M):a}function m(M){var Y=M-l,ce=M-u,ie=t-Y;return c?u0(ie,o-ce):ie}function T(M){var Y=M-l,ce=M-u;return l===void 0||Y>=t||Y<0||c&&ce>=o}function j(){var M=Io();if(T(M))return F(M);s=setTimeout(j,m(M))}function F(M){return s=void 0,p&&n?y(M):(n=i=void 0,a)}function D(){s!==void 0&&clearTimeout(s),u=0,n=l=i=s=void 0}function O(){return s===void 0?a:F(Io())}function E(){var M=Io(),Y=T(M);if(n=arguments,i=this,l=M,Y){if(s===void 0)return g(l);if(c)return clearTimeout(s),s=setTimeout(j,t),y(l)}return s===void 0&&(s=setTimeout(j,t)),a}return E.cancel=D,E.flush=O,E}var f0=c0;const d0=yt(f0),Dl=(e,t,r,n,i,o=300)=>{const[a,s]=_.useState(r??t);_.useEffect(()=>{s(r??t)},[r]);const l=_.useCallback(d0(c=>e(n,c),o),[e,n,o]),u=_.useCallback(c=>{const p=i(c);s(p??t),l(p)},[l,i]),f=_.useCallback(()=>{s(t),e(n,void 0)},[t,e,n]);return[a,u,f]},p0=e=>e===""?void 0:parseFloat(e),h0=e=>p0(e),In=_.memo(function(t){const{allowDecimal:r,className:n,data:i,description:o,errors:a,enabled:s,handleChange:l,label:u,path:f,required:c,hideControls:p}=t,[y,g]=Dl(l,"",i,f,h0),m=b.useProps(f,{},{});return Object.keys(m).forEach(T=>{typeof m[T]=="function"&&(m[T]=m[T](i))}),d.jsx(b.NumberInput,{label:u,description:o,error:a,required:c,value:y,onChange:g,className:n,disabled:!s,allowDecimal:r,hideControls:p,w:"100%",...m})});function m0(){this.__data__=[],this.size=0}var g0=m0;function y0(e,t){return e===t||e!==e&&t!==t}var $n=y0,v0=$n;function b0(e,t){for(var r=e.length;r--;)if(v0(e[r][0],t))return r;return-1}var Dn=b0,x0=Dn,T0=Array.prototype,_0=T0.splice;function E0(e){var t=this.__data__,r=x0(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():_0.call(t,r,1),--this.size,!0}var S0=E0,C0=Dn;function w0(e){var t=this.__data__,r=C0(t,e);return r<0?void 0:t[r][1]}var A0=w0,O0=Dn;function k0(e){return O0(this.__data__,e)>-1}var P0=k0,j0=Dn;function I0(e,t){var r=this.__data__,n=j0(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}var $0=I0,D0=g0,M0=S0,R0=A0,N0=P0,F0=$0;function nr(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}nr.prototype.clear=D0,nr.prototype.delete=M0,nr.prototype.get=R0,nr.prototype.has=N0,nr.prototype.set=F0;var Mn=nr,L0=Mn;function z0(){this.__data__=new L0,this.size=0}var B0=z0;function U0(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}var V0=U0;function W0(e){return this.__data__.get(e)}var H0=W0;function G0(e){return this.__data__.has(e)}var Y0=G0,q0=Wt,K0=q0(Object,"create"),Rn=K0,Ml=Rn;function X0(){this.__data__=Ml?Ml(null):{},this.size=0}var J0=X0;function Z0(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var Q0=Z0,ev=Rn,tv="__lodash_hash_undefined__",rv=Object.prototype,nv=rv.hasOwnProperty;function iv(e){var t=this.__data__;if(ev){var r=t[e];return r===tv?void 0:r}return nv.call(t,e)?t[e]:void 0}var ov=iv,av=Rn,sv=Object.prototype,lv=sv.hasOwnProperty;function uv(e){var t=this.__data__;return av?t[e]!==void 0:lv.call(t,e)}var cv=uv,fv=Rn,dv="__lodash_hash_undefined__";function pv(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=fv&&t===void 0?dv:t,this}var hv=pv,mv=J0,gv=Q0,yv=ov,vv=cv,bv=hv;function ir(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}ir.prototype.clear=mv,ir.prototype.delete=gv,ir.prototype.get=yv,ir.prototype.has=vv,ir.prototype.set=bv;var xv=ir,Rl=xv,Tv=Mn,_v=Eo;function Ev(){this.size=0,this.__data__={hash:new Rl,map:new(_v||Tv),string:new Rl}}var Sv=Ev;function Cv(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}var wv=Cv,Av=wv;function Ov(e,t){var r=e.__data__;return Av(t)?r[typeof t=="string"?"string":"hash"]:r.map}var Nn=Ov,kv=Nn;function Pv(e){var t=kv(this,e).delete(e);return this.size-=t?1:0,t}var jv=Pv,Iv=Nn;function $v(e){return Iv(this,e).get(e)}var Dv=$v,Mv=Nn;function Rv(e){return Mv(this,e).has(e)}var Nv=Rv,Fv=Nn;function Lv(e,t){var r=Fv(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,this}var zv=Lv,Bv=Sv,Uv=jv,Vv=Dv,Wv=Nv,Hv=zv;function or(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}or.prototype.clear=Bv,or.prototype.delete=Uv,or.prototype.get=Vv,or.prototype.has=Wv,or.prototype.set=Hv;var Nl=or,Gv=Mn,Yv=Eo,qv=Nl,Kv=200;function Xv(e,t){var r=this.__data__;if(r instanceof Gv){var n=r.__data__;if(!Yv||n.length<Kv-1)return n.push([e,t]),this.size=++r.size,this;r=this.__data__=new qv(n)}return r.set(e,t),this.size=r.size,this}var Jv=Xv,Zv=Mn,Qv=B0,eb=V0,tb=H0,rb=Y0,nb=Jv;function ar(e){var t=this.__data__=new Zv(e);this.size=t.size}ar.prototype.clear=Qv,ar.prototype.delete=eb,ar.prototype.get=tb,ar.prototype.has=rb,ar.prototype.set=nb;var ib=ar,ob=Wt,ab=function(){try{var e=ob(Object,"defineProperty");return e({},"",{}),e}catch{}}(),Fl=ab,Ll=Fl;function sb(e,t,r){t=="__proto__"&&Ll?Ll(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}var $o=sb,lb=$o,ub=$n;function cb(e,t,r){(r!==void 0&&!ub(e[t],r)||r===void 0&&!(t in e))&&lb(e,t,r)}var zl=cb;function fb(e){return function(t,r,n){for(var i=-1,o=Object(t),a=n(t),s=a.length;s--;){var l=a[e?s:++i];if(r(o[l],l,o)===!1)break}return t}}var db=fb,pb=db,hb=pb(),mb=hb,Fn={exports:{}};Fn.exports,function(e,t){var r=ct,n=t&&!t.nodeType&&t,i=n&&!0&&e&&!e.nodeType&&e,o=i&&i.exports===n,a=o?r.Buffer:void 0,s=a?a.allocUnsafe:void 0;function l(u,f){if(f)return u.slice();var c=u.length,p=s?s(c):new u.constructor(c);return u.copy(p),p}e.exports=l}(Fn,Fn.exports);var gb=Fn.exports,yb=ct,vb=yb.Uint8Array,bb=vb,Bl=bb;function xb(e){var t=new e.constructor(e.byteLength);return new Bl(t).set(new Bl(e)),t}var Tb=xb,_b=Tb;function Eb(e,t){var r=t?_b(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}var Sb=Eb;function Cb(e,t){var r=-1,n=e.length;for(t||(t=Array(n));++r<n;)t[r]=e[r];return t}var wb=Cb,Ab=bt,Ul=Object.create,Ob=function(){function e(){}return function(t){if(!Ab(t))return{};if(Ul)return Ul(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}}(),kb=Ob,Pb=sl,jb=Pb(Object.getPrototypeOf,Object),Vl=jb,Ib=kb,$b=Vl,Db=wn;function Mb(e){return typeof e.constructor=="function"&&!Db(e)?Ib($b(e)):{}}var Rb=Mb,Nb=kn,Fb=rr;function Lb(e){return Fb(e)&&Nb(e)}var Wl=Lb,zb=er,Bb=Vl,Ub=rr,Vb="[object Object]",Wb=Function.prototype,Hb=Object.prototype,Hl=Wb.toString,Gb=Hb.hasOwnProperty,Yb=Hl.call(Object);function qb(e){if(!Ub(e)||zb(e)!=Vb)return!1;var t=Bb(e);if(t===null)return!0;var r=Gb.call(t,"constructor")&&t.constructor;return typeof r=="function"&&r instanceof r&&Hl.call(r)==Yb}var Kb=qb;function Xb(e,t){if(!(t==="constructor"&&typeof e[t]=="function")&&t!="__proto__")return e[t]}var Gl=Xb,Jb=$o,Zb=$n,Qb=Object.prototype,ex=Qb.hasOwnProperty;function tx(e,t,r){var n=e[t];(!(ex.call(e,t)&&Zb(n,r))||r===void 0&&!(t in e))&&Jb(e,t,r)}var rx=tx,nx=rx,ix=$o;function ox(e,t,r,n){var i=!r;r||(r={});for(var o=-1,a=t.length;++o<a;){var s=t[o],l=n?n(r[s],e[s],s,r,e):void 0;l===void 0&&(l=e[s]),i?ix(r,s,l):nx(r,s,l)}return r}var ax=ox;function sx(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}var lx=sx,ux=9007199254740991,cx=/^(?:0|[1-9]\d*)$/;function fx(e,t){var r=typeof e;return t=t??ux,!!t&&(r=="number"||r!="symbol"&&cx.test(e))&&e>-1&&e%1==0&&e<t}var Yl=fx,dx=lx,px=On,hx=Dr,mx=ko,gx=Yl,yx=Po,vx=Object.prototype,bx=vx.hasOwnProperty;function xx(e,t){var r=hx(e),n=!r&&px(e),i=!r&&!n&&mx(e),o=!r&&!n&&!i&&yx(e),a=r||n||i||o,s=a?dx(e.length,String):[],l=s.length;for(var u in e)(t||bx.call(e,u))&&!(a&&(u=="length"||i&&(u=="offset"||u=="parent")||o&&(u=="buffer"||u=="byteLength"||u=="byteOffset")||gx(u,l)))&&s.push(u);return s}var Tx=xx;function _x(e){var t=[];if(e!=null)for(var r in Object(e))t.push(r);return t}var Ex=_x,Sx=bt,Cx=wn,wx=Ex,Ax=Object.prototype,Ox=Ax.hasOwnProperty;function kx(e){if(!Sx(e))return wx(e);var t=Cx(e),r=[];for(var n in e)n=="constructor"&&(t||!Ox.call(e,n))||r.push(n);return r}var Px=kx,jx=Tx,Ix=Px,$x=kn;function Dx(e){return $x(e)?jx(e,!0):Ix(e)}var ql=Dx,Mx=ax,Rx=ql;function Nx(e){return Mx(e,Rx(e))}var Fx=Nx,Kl=zl,Lx=gb,zx=Sb,Bx=wb,Ux=Rb,Xl=On,Jl=Dr,Vx=Wl,Wx=ko,Hx=To,Gx=bt,Yx=Kb,qx=Po,Zl=Gl,Kx=Fx;function Xx(e,t,r,n,i,o,a){var s=Zl(e,r),l=Zl(t,r),u=a.get(l);if(u){Kl(e,r,u);return}var f=o?o(s,l,r+"",e,t,a):void 0,c=f===void 0;if(c){var p=Jl(l),y=!p&&Wx(l),g=!p&&!y&&qx(l);f=l,p||y||g?Jl(s)?f=s:Vx(s)?f=Bx(s):y?(c=!1,f=Lx(l,!0)):g?(c=!1,f=zx(l,!0)):f=[]:Yx(l)||Xl(l)?(f=s,Xl(s)?f=Kx(s):(!Gx(s)||Hx(s))&&(f=Ux(l))):c=!1}c&&(a.set(l,f),i(f,l,n,o,a),a.delete(l)),Kl(e,r,f)}var Jx=Xx,Zx=ib,Qx=zl,eT=mb,tT=Jx,rT=bt,nT=ql,iT=Gl;function Ql(e,t,r,n,i){e!==t&&eT(t,function(o,a){if(i||(i=new Zx),rT(o))tT(e,t,a,r,Ql,n,i);else{var s=n?n(iT(e,a),o,a+"",e,t,i):void 0;s===void 0&&(s=o),Qx(e,a,s)}},nT)}var oT=Ql;function aT(e){return e}var eu=aT;function sT(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}var lT=sT,uT=lT,tu=Math.max;function cT(e,t,r){return t=tu(t===void 0?e.length-1:t,0),function(){for(var n=arguments,i=-1,o=tu(n.length-t,0),a=Array(o);++i<o;)a[i]=n[t+i];i=-1;for(var s=Array(t+1);++i<t;)s[i]=n[i];return s[t]=r(a),uT(e,this,s)}}var fT=cT;function dT(e){return function(){return e}}var pT=dT,hT=pT,ru=Fl,mT=eu,gT=ru?function(e,t){return ru(e,"toString",{configurable:!0,enumerable:!1,value:hT(t),writable:!0})}:mT,yT=gT,vT=800,bT=16,xT=Date.now;function TT(e){var t=0,r=0;return function(){var n=xT(),i=bT-(n-r);if(r=n,i>0){if(++t>=vT)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}var _T=TT,ET=yT,ST=_T,CT=ST(ET),wT=CT,AT=eu,OT=fT,kT=wT;function PT(e,t){return kT(OT(e,t,AT),e+"")}var nu=PT,jT=$n,IT=kn,$T=Yl,DT=bt;function MT(e,t,r){if(!DT(r))return!1;var n=typeof t;return(n=="number"?IT(r)&&$T(t,r.length):n=="string"&&t in r)?jT(r[t],e):!1}var iu=MT,RT=nu,NT=iu;function FT(e){return RT(function(t,r){var n=-1,i=r.length,o=i>1?r[i-1]:void 0,a=i>2?r[2]:void 0;for(o=e.length>3&&typeof o=="function"?(i--,o):void 0,a&&NT(r[0],r[1],a)&&(o=i<3?void 0:o,i=1),t=Object(t);++n<i;){var s=r[n];s&&e(t,s,n,o)}return t})}var LT=FT,zT=oT,BT=LT,UT=BT(function(e,t,r){zT(e,t,r)}),VT=UT;const ou=yt(VT),au=_.memo(function(t){const{className:r,config:n,uischema:i,data:o,description:a,errors:s,enabled:l,path:u,handleChange:f,label:c,required:p}=t,y=ou({},n,i.options),g=b.useProps(u,{},{});return Object.keys(g).forEach(m=>{typeof g[m]=="function"&&(g[m]=g[m](o))}),y.format==="password"?d.jsx(b.PasswordInput,{label:c,description:a,error:s,required:p,value:o||"",onChange:m=>{f(u,m.currentTarget.value)},className:r,disabled:!l,w:"100%",...g}):d.jsx(b.TextInput,{label:c,description:a,error:s,required:p,value:o||"",onChange:m=>{f(u,m.currentTarget.value)},className:r,disabled:!l,w:"100%",...g})}),su=_.memo(function(t){const{className:r,data:n,description:i,enabled:o,errors:a,handleChange:s,label:l,labelPosition:u,path:f,required:c}=t,p=b.useProps(f,{},{});return Object.keys(p).forEach(y=>{typeof p[y]=="function"&&(p[y]=p[y](n))}),d.jsx(b.Checkbox,{label:l,description:i,error:a,disabled:!o,className:r,labelPosition:u,required:c,data:[{label:"true",value:"true"},{label:"false",value:"false"}],value:String(n)||"",onChange:y=>{s(f,y==="true")},...p})}),WT=e=>d.jsx(In,{...e}),lu=W.rankWith(4,W.isNumberControl),uu=_e.withJsonFormsCellProps(WT),HT=e=>d.jsx(In,{...e}),cu=W.rankWith(3,W.isIntegerControl),fu=_e.withJsonFormsCellProps(HT),GT=e=>d.jsx(au,{...e}),du=W.rankWith(2,W.isStringControl),pu=_e.withJsonFormsCellProps(GT),YT=e=>d.jsx(su,{...e}),hu=W.rankWith(3,W.isBooleanControl),mu=_e.withJsonFormsCellProps(YT),qT=e=>{const{data:t,className:r,enabled:n,path:i,handleChange:o,description:a,errors:s,label:l,required:u}=e,f=b.useProps(i,{},{});return Object.keys(f).forEach(c=>{typeof f[c]=="function"&&(f[c]=f[c](t))}),d.jsx(Xt.DateInput,{valueFormat:"DD.MM.YYYY",label:l,description:a,error:s,required:u,value:t?new Date(t):null,onChange:c=>{if(c instanceof Date){const p=new Date(c.getTime()-c.getTimezoneOffset()*6e4);o(i,p.toISOString().substring(0,10))}},className:r,disabled:!n,w:"100%",...f})},gu=W.rankWith(2,W.isDateControl),yu=_e.withJsonFormsCellProps(qT),KT=e=>{const{description:t,className:r,enabled:n,path:i,handleChange:o,data:a,errors:s,label:l,required:u}=e,f=b.useProps(i,{},{});return Object.keys(f).forEach(c=>{typeof f[c]=="function"&&(f[c]=f[c](a))}),d.jsx(Xt.DateInput,{valueFormat:"DD.MM.YYYY",className:r,disabled:!n,label:l,description:t,error:s,required:u,value:a?new Date(a):null,onChange:c=>{if(c instanceof Date){const p=new Date(c.getTime()-c.getTimezoneOffset()*6e4);o(i,p.toISOString().substring(0,10))}},w:"100%",...f})},vu=W.rankWith(5,W.isDateTimeControl),bu=_e.withJsonFormsControlProps(KT),XT=e=>{const{description:t,data:r,path:n,options:i,enabled:o,handleChange:a,className:s,errors:l,label:u,required:f}=e,c=b.useProps(n,{},{});return Object.keys(c).forEach(p=>{typeof c[p]=="function"&&(c[p]=c[p](r))}),d.jsx(b.Select,{data:i,defaultValue:r,label:u,description:t,required:f,error:l,disabled:!o,searchable:!0,onChange:p=>{a(n,p)},className:s,w:"100%",...c})},xu=W.rankWith(5,W.isEnumControl),Tu=_e.withJsonFormsEnumProps(_e.withTranslateProps(_.memo(XT)),!1);function JT(e,t){for(var r=-1,n=t.length,i=e.length;++r<n;)e[i+r]=t[r];return e}var ZT=JT,_u=An,QT=On,e1=Dr,Eu=_u?_u.isConcatSpreadable:void 0;function t1(e){return e1(e)||QT(e)||!!(Eu&&e&&e[Eu])}var r1=t1,n1=ZT,i1=r1;function Su(e,t,r,n,i){var o=-1,a=e.length;for(r||(r=i1),i||(i=[]);++o<a;){var s=e[o];t>0&&r(s)?t>1?Su(s,t-1,r,n,i):n1(i,s):n||(i[i.length]=s)}return i}var o1=Su,a1="__lodash_hash_undefined__";function s1(e){return this.__data__.set(e,a1),this}var l1=s1;function u1(e){return this.__data__.has(e)}var c1=u1,f1=Nl,d1=l1,p1=c1;function Ln(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new f1;++t<r;)this.add(e[t])}Ln.prototype.add=Ln.prototype.push=d1,Ln.prototype.has=p1;var h1=Ln;function m1(e,t,r,n){for(var i=e.length,o=r+(n?1:-1);n?o--:++o<i;)if(t(e[o],o,e))return o;return-1}var g1=m1;function y1(e){return e!==e}var v1=y1;function b1(e,t,r){for(var n=r-1,i=e.length;++n<i;)if(e[n]===t)return n;return-1}var x1=b1,T1=g1,_1=v1,E1=x1;function S1(e,t,r){return t===t?E1(e,t,r):T1(e,_1,r)}var C1=S1,w1=C1;function A1(e,t){var r=e==null?0:e.length;return!!r&&w1(e,t,0)>-1}var O1=A1;function k1(e,t,r){for(var n=-1,i=e==null?0:e.length;++n<i;)if(r(t,e[n]))return!0;return!1}var P1=k1;function j1(e,t){return e.has(t)}var I1=j1;function $1(){}var D1=$1;function M1(e){var t=-1,r=Array(e.size);return e.forEach(function(n){r[++t]=n}),r}var Cu=M1,Do=ml,R1=D1,N1=Cu,F1=1/0,L1=Do&&1/N1(new Do([,-0]))[1]==F1?function(e){return new Do(e)}:R1,z1=L1,B1=h1,U1=O1,V1=P1,W1=I1,H1=z1,G1=Cu,Y1=200;function q1(e,t,r){var n=-1,i=U1,o=e.length,a=!0,s=[],l=s;if(r)a=!1,i=V1;else if(o>=Y1){var u=t?null:H1(e);if(u)return G1(u);a=!1,i=W1,l=new B1}else l=t?[]:s;e:for(;++n<o;){var f=e[n],c=t?t(f):f;if(f=r||f!==0?f:0,a&&c===c){for(var p=l.length;p--;)if(l[p]===c)continue e;t&&l.push(c),s.push(f)}else i(l,c,r)||(l!==s&&l.push(c),s.push(f))}return s}var K1=q1,X1=o1,J1=nu,Z1=K1,Q1=Wl,e_=J1(function(e){return Z1(X1(e,1,Q1,!0))}),t_=e_;const r_=yt(t_);function n_(e,t,r,n){var i=-1,o=e==null?0:e.length;for(n&&o&&(r=e[++i]);++i<o;)r=t(r,e[i],i,e);return r}var i_=n_;function o_(e){return function(t){return e==null?void 0:e[t]}}var a_=o_,s_=a_,l_={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},u_=s_(l_),c_=u_;function f_(e,t){for(var r=-1,n=e==null?0:e.length,i=Array(n);++r<n;)i[r]=t(e[r],r,e);return i}var d_=f_,wu=An,p_=d_,h_=Dr,m_=kl,g_=1/0,Au=wu?wu.prototype:void 0,Ou=Au?Au.toString:void 0;function ku(e){if(typeof e=="string")return e;if(h_(e))return p_(e,ku)+"";if(m_(e))return Ou?Ou.call(e):"";var t=e+"";return t=="0"&&1/e==-g_?"-0":t}var y_=ku,v_=y_;function b_(e){return e==null?"":v_(e)}var Mo=b_,x_=c_,T_=Mo,__=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,E_="\\u0300-\\u036f",S_="\\ufe20-\\ufe2f",C_="\\u20d0-\\u20ff",w_=E_+S_+C_,A_="["+w_+"]",O_=RegExp(A_,"g");function k_(e){return e=T_(e),e&&e.replace(__,x_).replace(O_,"")}var P_=k_,j_=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function I_(e){return e.match(j_)||[]}var $_=I_,D_=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function M_(e){return D_.test(e)}var R_=M_,Pu="\\ud800-\\udfff",N_="\\u0300-\\u036f",F_="\\ufe20-\\ufe2f",L_="\\u20d0-\\u20ff",z_=N_+F_+L_,ju="\\u2700-\\u27bf",Iu="a-z\\xdf-\\xf6\\xf8-\\xff",B_="\\xac\\xb1\\xd7\\xf7",U_="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",V_="\\u2000-\\u206f",W_=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",$u="A-Z\\xc0-\\xd6\\xd8-\\xde",H_="\\ufe0e\\ufe0f",Du=B_+U_+V_+W_,Mu="['’]",Ru="["+Du+"]",G_="["+z_+"]",Nu="\\d+",Y_="["+ju+"]",Fu="["+Iu+"]",Lu="[^"+Pu+Du+Nu+ju+Iu+$u+"]",q_="\\ud83c[\\udffb-\\udfff]",K_="(?:"+G_+"|"+q_+")",X_="[^"+Pu+"]",zu="(?:\\ud83c[\\udde6-\\uddff]){2}",Bu="[\\ud800-\\udbff][\\udc00-\\udfff]",sr="["+$u+"]",J_="\\u200d",Uu="(?:"+Fu+"|"+Lu+")",Z_="(?:"+sr+"|"+Lu+")",Vu="(?:"+Mu+"(?:d|ll|m|re|s|t|ve))?",Wu="(?:"+Mu+"(?:D|LL|M|RE|S|T|VE))?",Hu=K_+"?",Gu="["+H_+"]?",Q_="(?:"+J_+"(?:"+[X_,zu,Bu].join("|")+")"+Gu+Hu+")*",eE="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",tE="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",rE=Gu+Hu+Q_,nE="(?:"+[Y_,zu,Bu].join("|")+")"+rE,iE=RegExp([sr+"?"+Fu+"+"+Vu+"(?="+[Ru,sr,"$"].join("|")+")",Z_+"+"+Wu+"(?="+[Ru,sr+Uu,"$"].join("|")+")",sr+"?"+Uu+"+"+Vu,sr+"+"+Wu,tE,eE,Nu,nE].join("|"),"g");function oE(e){return e.match(iE)||[]}var aE=oE,sE=$_,lE=R_,uE=Mo,cE=aE;function fE(e,t,r){return e=uE(e),t=r?void 0:t,t===void 0?lE(e)?cE(e):sE(e):e.match(t)||[]}var dE=fE,pE=i_,hE=P_,mE=dE,gE="['’]",yE=RegExp(gE,"g");function vE(e){return function(t){return pE(mE(hE(t).replace(yE,"")),e,"")}}var bE=vE;function xE(e,t,r){var n=-1,i=e.length;t<0&&(t=-t>i?0:i+t),r=r>i?i:r,r<0&&(r+=i),i=t>r?0:r-t>>>0,t>>>=0;for(var o=Array(i);++n<i;)o[n]=e[n+t];return o}var TE=xE,_E=TE;function EE(e,t,r){var n=e.length;return r=r===void 0?n:r,!t&&r>=n?e:_E(e,t,r)}var SE=EE,CE="\\ud800-\\udfff",wE="\\u0300-\\u036f",AE="\\ufe20-\\ufe2f",OE="\\u20d0-\\u20ff",kE=wE+AE+OE,PE="\\ufe0e\\ufe0f",jE="\\u200d",IE=RegExp("["+jE+CE+kE+PE+"]");function $E(e){return IE.test(e)}var Yu=$E;function DE(e){return e.split("")}var ME=DE,qu="\\ud800-\\udfff",RE="\\u0300-\\u036f",NE="\\ufe20-\\ufe2f",FE="\\u20d0-\\u20ff",LE=RE+NE+FE,zE="\\ufe0e\\ufe0f",BE="["+qu+"]",Ro="["+LE+"]",No="\\ud83c[\\udffb-\\udfff]",UE="(?:"+Ro+"|"+No+")",Ku="[^"+qu+"]",Xu="(?:\\ud83c[\\udde6-\\uddff]){2}",Ju="[\\ud800-\\udbff][\\udc00-\\udfff]",VE="\\u200d",Zu=UE+"?",Qu="["+zE+"]?",WE="(?:"+VE+"(?:"+[Ku,Xu,Ju].join("|")+")"+Qu+Zu+")*",HE=Qu+Zu+WE,GE="(?:"+[Ku+Ro+"?",Ro,Xu,Ju,BE].join("|")+")",YE=RegExp(No+"(?="+No+")|"+GE+HE,"g");function qE(e){return e.match(YE)||[]}var KE=qE,XE=ME,JE=Yu,ZE=KE;function QE(e){return JE(e)?ZE(e):XE(e)}var eS=QE,tS=SE,rS=Yu,nS=eS,iS=Mo;function oS(e){return function(t){t=iS(t);var r=rS(t)?nS(t):void 0,n=r?r[0]:t.charAt(0),i=r?tS(r,1).join(""):t.slice(1);return n[e]()+i}}var aS=oS,sS=aS,lS=sS("toUpperCase"),uS=lS,cS=bE,fS=uS,dS=cS(function(e,t,r){return e+(r?" ":"")+fS(t)}),pS=dS;const hS=yt(pS);var mS=Math.ceil,gS=Math.max;function yS(e,t,r,n){for(var i=-1,o=gS(mS((t-e)/(r||1)),0),a=Array(o);o--;)a[n?o:++i]=e,e+=r;return a}var vS=yS,bS=Il,ec=1/0,xS=17976931348623157e292;function TS(e){if(!e)return e===0?e:0;if(e=bS(e),e===ec||e===-ec){var t=e<0?-1:1;return t*xS}return e===e?e:0}var _S=TS,ES=vS,SS=iu,Fo=_S;function CS(e){return function(t,r,n){return n&&typeof n!="number"&&SS(t,r,n)&&(r=n=void 0),t=Fo(t),r===void 0?(r=t,t=0):r=Fo(r),n=n===void 0?t<r?1:-1:Fo(n),ES(t,r,n,e)}}var wS=CS,AS=wS,OS=AS(),kS=OS;const PS=yt(kS);function xt(e){if(typeof e!="object"||e===null)return!1;const t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function tc(e){if(!xt(e))return e;const t={};return Object.keys(e).forEach(r=>{t[r]=tc(e[r])}),t}function et(e,t,r={clone:!0}){const n=r.clone?{...e}:e;return xt(e)&&xt(t)&&Object.keys(t).forEach(i=>{xt(t[i])&&Object.prototype.hasOwnProperty.call(e,i)&&xt(e[i])?n[i]=et(e[i],t[i],r):r.clone?n[i]=xt(t[i])?tc(t[i]):t[i]:n[i]=t[i]}),n}var Lo={exports:{}},zn={exports:{}},pe={};/** @license React v16.13.1
|
|
121
121
|
* react-is.production.min.js
|
|
122
122
|
*
|
|
123
123
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
124
124
|
*
|
|
125
125
|
* This source code is licensed under the MIT license found in the
|
|
126
126
|
* LICENSE file in the root directory of this source tree.
|
|
127
|
-
*/var rc;function
|
|
127
|
+
*/var rc;function jS(){if(rc)return pe;rc=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,n=e?Symbol.for("react.fragment"):60107,i=e?Symbol.for("react.strict_mode"):60108,o=e?Symbol.for("react.profiler"):60114,a=e?Symbol.for("react.provider"):60109,s=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,u=e?Symbol.for("react.concurrent_mode"):60111,f=e?Symbol.for("react.forward_ref"):60112,c=e?Symbol.for("react.suspense"):60113,p=e?Symbol.for("react.suspense_list"):60120,y=e?Symbol.for("react.memo"):60115,g=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,T=e?Symbol.for("react.fundamental"):60117,j=e?Symbol.for("react.responder"):60118,F=e?Symbol.for("react.scope"):60119;function D(E){if(typeof E=="object"&&E!==null){var M=E.$$typeof;switch(M){case t:switch(E=E.type,E){case l:case u:case n:case o:case i:case c:return E;default:switch(E=E&&E.$$typeof,E){case s:case f:case g:case y:case a:return E;default:return M}}case r:return M}}}function O(E){return D(E)===u}return pe.AsyncMode=l,pe.ConcurrentMode=u,pe.ContextConsumer=s,pe.ContextProvider=a,pe.Element=t,pe.ForwardRef=f,pe.Fragment=n,pe.Lazy=g,pe.Memo=y,pe.Portal=r,pe.Profiler=o,pe.StrictMode=i,pe.Suspense=c,pe.isAsyncMode=function(E){return O(E)||D(E)===l},pe.isConcurrentMode=O,pe.isContextConsumer=function(E){return D(E)===s},pe.isContextProvider=function(E){return D(E)===a},pe.isElement=function(E){return typeof E=="object"&&E!==null&&E.$$typeof===t},pe.isForwardRef=function(E){return D(E)===f},pe.isFragment=function(E){return D(E)===n},pe.isLazy=function(E){return D(E)===g},pe.isMemo=function(E){return D(E)===y},pe.isPortal=function(E){return D(E)===r},pe.isProfiler=function(E){return D(E)===o},pe.isStrictMode=function(E){return D(E)===i},pe.isSuspense=function(E){return D(E)===c},pe.isValidElementType=function(E){return typeof E=="string"||typeof E=="function"||E===n||E===u||E===o||E===i||E===c||E===p||typeof E=="object"&&E!==null&&(E.$$typeof===g||E.$$typeof===y||E.$$typeof===a||E.$$typeof===s||E.$$typeof===f||E.$$typeof===T||E.$$typeof===j||E.$$typeof===F||E.$$typeof===m)},pe.typeOf=D,pe}var he={};/** @license React v16.13.1
|
|
128
128
|
* react-is.development.js
|
|
129
129
|
*
|
|
130
130
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
131
131
|
*
|
|
132
132
|
* This source code is licensed under the MIT license found in the
|
|
133
133
|
* LICENSE file in the root directory of this source tree.
|
|
134
|
-
*/var nc;function
|
|
134
|
+
*/var nc;function IS(){return nc||(nc=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,n=e?Symbol.for("react.fragment"):60107,i=e?Symbol.for("react.strict_mode"):60108,o=e?Symbol.for("react.profiler"):60114,a=e?Symbol.for("react.provider"):60109,s=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,u=e?Symbol.for("react.concurrent_mode"):60111,f=e?Symbol.for("react.forward_ref"):60112,c=e?Symbol.for("react.suspense"):60113,p=e?Symbol.for("react.suspense_list"):60120,y=e?Symbol.for("react.memo"):60115,g=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,T=e?Symbol.for("react.fundamental"):60117,j=e?Symbol.for("react.responder"):60118,F=e?Symbol.for("react.scope"):60119;function D(N){return typeof N=="string"||typeof N=="function"||N===n||N===u||N===o||N===i||N===c||N===p||typeof N=="object"&&N!==null&&(N.$$typeof===g||N.$$typeof===y||N.$$typeof===a||N.$$typeof===s||N.$$typeof===f||N.$$typeof===T||N.$$typeof===j||N.$$typeof===F||N.$$typeof===m)}function O(N){if(typeof N=="object"&&N!==null){var Me=N.$$typeof;switch(Me){case t:var z=N.type;switch(z){case l:case u:case n:case o:case i:case c:return z;default:var Ge=z&&z.$$typeof;switch(Ge){case s:case f:case g:case y:case a:return Ge;default:return Me}}case r:return Me}}}var E=l,M=u,Y=s,ce=a,ie=t,h=f,A=n,U=g,H=y,te=r,ve=o,G=i,oe=c,le=!1;function He(N){return le||(le=!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.")),k(N)||O(N)===l}function k(N){return O(N)===u}function $(N){return O(N)===s}function Z(N){return O(N)===a}function B(N){return typeof N=="object"&&N!==null&&N.$$typeof===t}function X(N){return O(N)===f}function V(N){return O(N)===n}function q(N){return O(N)===g}function J(N){return O(N)===y}function Q(N){return O(N)===r}function re(N){return O(N)===o}function ee(N){return O(N)===i}function Ie(N){return O(N)===c}he.AsyncMode=E,he.ConcurrentMode=M,he.ContextConsumer=Y,he.ContextProvider=ce,he.Element=ie,he.ForwardRef=h,he.Fragment=A,he.Lazy=U,he.Memo=H,he.Portal=te,he.Profiler=ve,he.StrictMode=G,he.Suspense=oe,he.isAsyncMode=He,he.isConcurrentMode=k,he.isContextConsumer=$,he.isContextProvider=Z,he.isElement=B,he.isForwardRef=X,he.isFragment=V,he.isLazy=q,he.isMemo=J,he.isPortal=Q,he.isProfiler=re,he.isStrictMode=ee,he.isSuspense=Ie,he.isValidElementType=D,he.typeOf=O}()),he}var ic;function oc(){return ic||(ic=1,process.env.NODE_ENV==="production"?zn.exports=jS():zn.exports=IS()),zn.exports}/*
|
|
135
135
|
object-assign
|
|
136
136
|
(c) Sindre Sorhus
|
|
137
137
|
@license MIT
|
|
138
|
-
*/var zo,ac;function
|
|
139
|
-
Valid keys: `+JSON.stringify(Object.keys(k),null," "));var N=Ie(J,ee,X,V,q+"."+ee,r);if(N)return N}return null}return T($)}function te(k){switch(typeof k){case"number":case"string":case"undefined":return!0;case"boolean":return!k;case"object":if(Array.isArray(k))return k.every(te);if(k===null||s(k))return!0;var $=c(k);if($){var Z=$.call(k),B;if($!==k.entries){for(;!(B=Z.next()).done;)if(!te(B.value))return!1}else for(;!(B=Z.next()).done;){var X=B.value;if(X&&!te(X[1]))return!1}}else return!1;return!0;default:return!1}}function ve(k,$){return k==="symbol"?!0:$?$["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&$ instanceof Symbol:!1}function G(k){var $=typeof k;return Array.isArray(k)?"array":k instanceof RegExp?"object":ve($,k)?"symbol":$}function oe(k){if(typeof k>"u"||k===null)return""+k;var $=G(k);if($==="object"){if(k instanceof Date)return"date";if(k instanceof RegExp)return"regexp"}return $}function le(k){var $=oe(k);switch($){case"array":case"object":return"an "+$;case"boolean":case"date":case"regexp":return"a "+$;default:return $}}function He(k){return!k.constructor||!k.constructor.name?p:k.constructor.name}return
|
|
138
|
+
*/var zo,ac;function $S(){if(ac)return zo;ac=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,r=Object.prototype.propertyIsEnumerable;function n(o){if(o==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(o)}function i(){try{if(!Object.assign)return!1;var o=new String("abc");if(o[5]="de",Object.getOwnPropertyNames(o)[0]==="5")return!1;for(var a={},s=0;s<10;s++)a["_"+String.fromCharCode(s)]=s;var l=Object.getOwnPropertyNames(a).map(function(f){return a[f]});if(l.join("")!=="0123456789")return!1;var u={};return"abcdefghijklmnopqrst".split("").forEach(function(f){u[f]=f}),Object.keys(Object.assign({},u)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return zo=i()?Object.assign:function(o,a){for(var s,l=n(o),u,f=1;f<arguments.length;f++){s=Object(arguments[f]);for(var c in s)t.call(s,c)&&(l[c]=s[c]);if(e){u=e(s);for(var p=0;p<u.length;p++)r.call(s,u[p])&&(l[u[p]]=s[u[p]])}}return l},zo}var Bo,sc;function Uo(){if(sc)return Bo;sc=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return Bo=e,Bo}var Vo,lc;function uc(){return lc||(lc=1,Vo=Function.call.bind(Object.prototype.hasOwnProperty)),Vo}var Wo,cc;function DS(){if(cc)return Wo;cc=1;var e=function(){};if(process.env.NODE_ENV!=="production"){var t=Uo(),r={},n=uc();e=function(o){var a="Warning: "+o;typeof console<"u"&&console.error(a);try{throw new Error(a)}catch{}}}function i(o,a,s,l,u){if(process.env.NODE_ENV!=="production"){for(var f in o)if(n(o,f)){var c;try{if(typeof o[f]!="function"){var p=Error((l||"React class")+": "+s+" type `"+f+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof o[f]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw p.name="Invariant Violation",p}c=o[f](a,f,l,s,null,t)}catch(g){c=g}if(c&&!(c instanceof Error)&&e((l||"React class")+": type specification of "+s+" `"+f+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof c+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),c instanceof Error&&!(c.message in r)){r[c.message]=!0;var y=u?u():"";e("Failed "+s+" type: "+c.message+(y??""))}}}}return i.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(r={})},Wo=i,Wo}var Ho,fc;function MS(){if(fc)return Ho;fc=1;var e=oc(),t=$S(),r=Uo(),n=uc(),i=DS(),o=function(){};process.env.NODE_ENV!=="production"&&(o=function(s){var l="Warning: "+s;typeof console<"u"&&console.error(l);try{throw new Error(l)}catch{}});function a(){return null}return Ho=function(s,l){var u=typeof Symbol=="function"&&Symbol.iterator,f="@@iterator";function c(k){var $=k&&(u&&k[u]||k[f]);if(typeof $=="function")return $}var p="<<anonymous>>",y={array:j("array"),bigint:j("bigint"),bool:j("boolean"),func:j("function"),number:j("number"),object:j("object"),string:j("string"),symbol:j("symbol"),any:F(),arrayOf:D,element:O(),elementType:E(),instanceOf:M,node:h(),objectOf:ce,oneOf:Y,oneOfType:ie,shape:U,exact:H};function g(k,$){return k===$?k!==0||1/k===1/$:k!==k&&$!==$}function m(k,$){this.message=k,this.data=$&&typeof $=="object"?$:{},this.stack=""}m.prototype=Error.prototype;function T(k){if(process.env.NODE_ENV!=="production")var $={},Z=0;function B(V,q,J,Q,re,ee,Ie){if(Q=Q||p,ee=ee||J,Ie!==r){if(l){var N=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 N.name="Invariant Violation",N}else if(process.env.NODE_ENV!=="production"&&typeof console<"u"){var Me=Q+":"+J;!$[Me]&&Z<3&&(o("You are manually calling a React.PropTypes validation function for the `"+ee+"` prop on `"+Q+"`. 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."),$[Me]=!0,Z++)}}return q[J]==null?V?q[J]===null?new m("The "+re+" `"+ee+"` is marked as required "+("in `"+Q+"`, but its value is `null`.")):new m("The "+re+" `"+ee+"` is marked as required in "+("`"+Q+"`, but its value is `undefined`.")):null:k(q,J,Q,re,ee)}var X=B.bind(null,!1);return X.isRequired=B.bind(null,!0),X}function j(k){function $(Z,B,X,V,q,J){var Q=Z[B],re=G(Q);if(re!==k){var ee=oe(Q);return new m("Invalid "+V+" `"+q+"` of type "+("`"+ee+"` supplied to `"+X+"`, expected ")+("`"+k+"`."),{expectedType:k})}return null}return T($)}function F(){return T(a)}function D(k){function $(Z,B,X,V,q){if(typeof k!="function")return new m("Property `"+q+"` of component `"+X+"` has invalid PropType notation inside arrayOf.");var J=Z[B];if(!Array.isArray(J)){var Q=G(J);return new m("Invalid "+V+" `"+q+"` of type "+("`"+Q+"` supplied to `"+X+"`, expected an array."))}for(var re=0;re<J.length;re++){var ee=k(J,re,X,V,q+"["+re+"]",r);if(ee instanceof Error)return ee}return null}return T($)}function O(){function k($,Z,B,X,V){var q=$[Z];if(!s(q)){var J=G(q);return new m("Invalid "+X+" `"+V+"` of type "+("`"+J+"` supplied to `"+B+"`, expected a single ReactElement."))}return null}return T(k)}function E(){function k($,Z,B,X,V){var q=$[Z];if(!e.isValidElementType(q)){var J=G(q);return new m("Invalid "+X+" `"+V+"` of type "+("`"+J+"` supplied to `"+B+"`, expected a single ReactElement type."))}return null}return T(k)}function M(k){function $(Z,B,X,V,q){if(!(Z[B]instanceof k)){var J=k.name||p,Q=He(Z[B]);return new m("Invalid "+V+" `"+q+"` of type "+("`"+Q+"` supplied to `"+X+"`, expected ")+("instance of `"+J+"`."))}return null}return T($)}function Y(k){if(!Array.isArray(k))return process.env.NODE_ENV!=="production"&&(arguments.length>1?o("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])."):o("Invalid argument supplied to oneOf, expected an array.")),a;function $(Z,B,X,V,q){for(var J=Z[B],Q=0;Q<k.length;Q++)if(g(J,k[Q]))return null;var re=JSON.stringify(k,function(Ie,N){var Me=oe(N);return Me==="symbol"?String(N):N});return new m("Invalid "+V+" `"+q+"` of value `"+String(J)+"` "+("supplied to `"+X+"`, expected one of "+re+"."))}return T($)}function ce(k){function $(Z,B,X,V,q){if(typeof k!="function")return new m("Property `"+q+"` of component `"+X+"` has invalid PropType notation inside objectOf.");var J=Z[B],Q=G(J);if(Q!=="object")return new m("Invalid "+V+" `"+q+"` of type "+("`"+Q+"` supplied to `"+X+"`, expected an object."));for(var re in J)if(n(J,re)){var ee=k(J,re,X,V,q+"."+re,r);if(ee instanceof Error)return ee}return null}return T($)}function ie(k){if(!Array.isArray(k))return process.env.NODE_ENV!=="production"&&o("Invalid argument supplied to oneOfType, expected an instance of array."),a;for(var $=0;$<k.length;$++){var Z=k[$];if(typeof Z!="function")return o("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+le(Z)+" at index "+$+"."),a}function B(X,V,q,J,Q){for(var re=[],ee=0;ee<k.length;ee++){var Ie=k[ee],N=Ie(X,V,q,J,Q,r);if(N==null)return null;N.data&&n(N.data,"expectedType")&&re.push(N.data.expectedType)}var Me=re.length>0?", expected one of type ["+re.join(", ")+"]":"";return new m("Invalid "+J+" `"+Q+"` supplied to "+("`"+q+"`"+Me+"."))}return T(B)}function h(){function k($,Z,B,X,V){return te($[Z])?null:new m("Invalid "+X+" `"+V+"` supplied to "+("`"+B+"`, expected a ReactNode."))}return T(k)}function A(k,$,Z,B,X){return new m((k||"React class")+": "+$+" type `"+Z+"."+B+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+X+"`.")}function U(k){function $(Z,B,X,V,q){var J=Z[B],Q=G(J);if(Q!=="object")return new m("Invalid "+V+" `"+q+"` of type `"+Q+"` "+("supplied to `"+X+"`, expected `object`."));for(var re in k){var ee=k[re];if(typeof ee!="function")return A(X,V,q,re,oe(ee));var Ie=ee(J,re,X,V,q+"."+re,r);if(Ie)return Ie}return null}return T($)}function H(k){function $(Z,B,X,V,q){var J=Z[B],Q=G(J);if(Q!=="object")return new m("Invalid "+V+" `"+q+"` of type `"+Q+"` "+("supplied to `"+X+"`, expected `object`."));var re=t({},Z[B],k);for(var ee in re){var Ie=k[ee];if(n(k,ee)&&typeof Ie!="function")return A(X,V,q,ee,oe(Ie));if(!Ie)return new m("Invalid "+V+" `"+q+"` key `"+ee+"` supplied to `"+X+"`.\nBad object: "+JSON.stringify(Z[B],null," ")+`
|
|
139
|
+
Valid keys: `+JSON.stringify(Object.keys(k),null," "));var N=Ie(J,ee,X,V,q+"."+ee,r);if(N)return N}return null}return T($)}function te(k){switch(typeof k){case"number":case"string":case"undefined":return!0;case"boolean":return!k;case"object":if(Array.isArray(k))return k.every(te);if(k===null||s(k))return!0;var $=c(k);if($){var Z=$.call(k),B;if($!==k.entries){for(;!(B=Z.next()).done;)if(!te(B.value))return!1}else for(;!(B=Z.next()).done;){var X=B.value;if(X&&!te(X[1]))return!1}}else return!1;return!0;default:return!1}}function ve(k,$){return k==="symbol"?!0:$?$["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&$ instanceof Symbol:!1}function G(k){var $=typeof k;return Array.isArray(k)?"array":k instanceof RegExp?"object":ve($,k)?"symbol":$}function oe(k){if(typeof k>"u"||k===null)return""+k;var $=G(k);if($==="object"){if(k instanceof Date)return"date";if(k instanceof RegExp)return"regexp"}return $}function le(k){var $=oe(k);switch($){case"array":case"object":return"an "+$;case"boolean":case"date":case"regexp":return"a "+$;default:return $}}function He(k){return!k.constructor||!k.constructor.name?p:k.constructor.name}return y.checkPropTypes=i,y.resetWarningCache=i.resetWarningCache,y.PropTypes=y,y},Ho}var Go,dc;function RS(){if(dc)return Go;dc=1;var e=Uo();function t(){}function r(){}return r.resetWarningCache=t,Go=function(){function n(a,s,l,u,f,c){if(c!==e){var p=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 p.name="Invariant Violation",p}}n.isRequired=n;function i(){return n}var o={array:n,bigint:n,bool:n,func:n,number:n,object:n,string:n,symbol:n,any:n,arrayOf:i,element:n,elementType:n,instanceOf:i,node:n,objectOf:i,oneOf:i,oneOfType:i,shape:i,exact:i,checkPropTypes:r,resetWarningCache:t};return o.PropTypes=o,o},Go}if(process.env.NODE_ENV!=="production"){var NS=oc(),FS=!0;Lo.exports=MS()(NS.isElement,FS)}else Lo.exports=RS()();var LS=Lo.exports;const de=yt(LS);function It(e,...t){const r=new URL(`https://mui.com/production-error/?code=${e}`);return t.forEach(n=>r.searchParams.append("args[]",n)),`Minified MUI error #${e}; visit ${r} for the full message.`}var Yo={exports:{}},me={};/**
|
|
140
140
|
* @license React
|
|
141
141
|
* react-is.production.min.js
|
|
142
142
|
*
|
|
@@ -144,7 +144,7 @@ Valid keys: `+JSON.stringify(Object.keys(k),null," "));var N=Ie(J,ee,X,V,q+"."+
|
|
|
144
144
|
*
|
|
145
145
|
* This source code is licensed under the MIT license found in the
|
|
146
146
|
* LICENSE file in the root directory of this source tree.
|
|
147
|
-
*/var pc;function
|
|
147
|
+
*/var pc;function zS(){if(pc)return me;pc=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),o=Symbol.for("react.provider"),a=Symbol.for("react.context"),s=Symbol.for("react.server_context"),l=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),f=Symbol.for("react.suspense_list"),c=Symbol.for("react.memo"),p=Symbol.for("react.lazy"),y=Symbol.for("react.offscreen"),g;g=Symbol.for("react.module.reference");function m(T){if(typeof T=="object"&&T!==null){var j=T.$$typeof;switch(j){case e:switch(T=T.type,T){case r:case i:case n:case u:case f:return T;default:switch(T=T&&T.$$typeof,T){case s:case a:case l:case p:case c:case o:return T;default:return j}}case t:return j}}}return me.ContextConsumer=a,me.ContextProvider=o,me.Element=e,me.ForwardRef=l,me.Fragment=r,me.Lazy=p,me.Memo=c,me.Portal=t,me.Profiler=i,me.StrictMode=n,me.Suspense=u,me.SuspenseList=f,me.isAsyncMode=function(){return!1},me.isConcurrentMode=function(){return!1},me.isContextConsumer=function(T){return m(T)===a},me.isContextProvider=function(T){return m(T)===o},me.isElement=function(T){return typeof T=="object"&&T!==null&&T.$$typeof===e},me.isForwardRef=function(T){return m(T)===l},me.isFragment=function(T){return m(T)===r},me.isLazy=function(T){return m(T)===p},me.isMemo=function(T){return m(T)===c},me.isPortal=function(T){return m(T)===t},me.isProfiler=function(T){return m(T)===i},me.isStrictMode=function(T){return m(T)===n},me.isSuspense=function(T){return m(T)===u},me.isSuspenseList=function(T){return m(T)===f},me.isValidElementType=function(T){return typeof T=="string"||typeof T=="function"||T===r||T===i||T===n||T===u||T===f||T===y||typeof T=="object"&&T!==null&&(T.$$typeof===p||T.$$typeof===c||T.$$typeof===o||T.$$typeof===a||T.$$typeof===l||T.$$typeof===g||T.getModuleId!==void 0)},me.typeOf=m,me}var ge={};/**
|
|
148
148
|
* @license React
|
|
149
149
|
* react-is.development.js
|
|
150
150
|
*
|
|
@@ -152,23 +152,23 @@ Valid keys: `+JSON.stringify(Object.keys(k),null," "));var N=Ie(J,ee,X,V,q+"."+
|
|
|
152
152
|
*
|
|
153
153
|
* This source code is licensed under the MIT license found in the
|
|
154
154
|
* LICENSE file in the root directory of this source tree.
|
|
155
|
-
*/var hc;function
|
|
156
|
-
For example, \`@sm\` or \`@600\` or \`@40rem/sidebar\`.`:It(18,`(${t})`));return null}const[,n,i]=r,o=Number.isNaN(+n)?n||0:+n;return e.containerQueries(i).up(o)}function
|
|
155
|
+
*/var hc;function BS(){return hc||(hc=1,process.env.NODE_ENV!=="production"&&function(){var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),o=Symbol.for("react.provider"),a=Symbol.for("react.context"),s=Symbol.for("react.server_context"),l=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),f=Symbol.for("react.suspense_list"),c=Symbol.for("react.memo"),p=Symbol.for("react.lazy"),y=Symbol.for("react.offscreen"),g=!1,m=!1,T=!1,j=!1,F=!1,D;D=Symbol.for("react.module.reference");function O(z){return!!(typeof z=="string"||typeof z=="function"||z===r||z===i||F||z===n||z===u||z===f||j||z===y||g||m||T||typeof z=="object"&&z!==null&&(z.$$typeof===p||z.$$typeof===c||z.$$typeof===o||z.$$typeof===a||z.$$typeof===l||z.$$typeof===D||z.getModuleId!==void 0))}function E(z){if(typeof z=="object"&&z!==null){var Ge=z.$$typeof;switch(Ge){case e:var Ke=z.type;switch(Ke){case r:case i:case n:case u:case f:return Ke;default:var at=Ke&&Ke.$$typeof;switch(at){case s:case a:case l:case p:case c:case o:return at;default:return Ge}}case t:return Ge}}}var M=a,Y=o,ce=e,ie=l,h=r,A=p,U=c,H=t,te=i,ve=n,G=u,oe=f,le=!1,He=!1;function k(z){return le||(le=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1}function $(z){return He||(He=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1}function Z(z){return E(z)===a}function B(z){return E(z)===o}function X(z){return typeof z=="object"&&z!==null&&z.$$typeof===e}function V(z){return E(z)===l}function q(z){return E(z)===r}function J(z){return E(z)===p}function Q(z){return E(z)===c}function re(z){return E(z)===t}function ee(z){return E(z)===i}function Ie(z){return E(z)===n}function N(z){return E(z)===u}function Me(z){return E(z)===f}ge.ContextConsumer=M,ge.ContextProvider=Y,ge.Element=ce,ge.ForwardRef=ie,ge.Fragment=h,ge.Lazy=A,ge.Memo=U,ge.Portal=H,ge.Profiler=te,ge.StrictMode=ve,ge.Suspense=G,ge.SuspenseList=oe,ge.isAsyncMode=k,ge.isConcurrentMode=$,ge.isContextConsumer=Z,ge.isContextProvider=B,ge.isElement=X,ge.isForwardRef=V,ge.isFragment=q,ge.isLazy=J,ge.isMemo=Q,ge.isPortal=re,ge.isProfiler=ee,ge.isStrictMode=Ie,ge.isSuspense=N,ge.isSuspenseList=Me,ge.isValidElementType=O,ge.typeOf=E}()),ge}process.env.NODE_ENV==="production"?Yo.exports=zS():Yo.exports=BS();var mc=Yo.exports;function gc(e,t=""){return e.displayName||e.name||t}function yc(e,t,r){const n=gc(t);return e.displayName||(n!==""?`${r}(${n})`:r)}function US(e){if(e!=null){if(typeof e=="string")return e;if(typeof e=="function")return gc(e,"Component");if(typeof e=="object")switch(e.$$typeof){case mc.ForwardRef:return yc(e,e.render,"ForwardRef");case mc.Memo:return yc(e,e.type,"memo");default:return}}}function Gt(e){if(typeof e!="string")throw new Error(process.env.NODE_ENV!=="production"?"MUI: `capitalize(string)` expects a string argument.":It(7));return e.charAt(0).toUpperCase()+e.slice(1)}function qo(e,t){const r={...t};for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)){const i=n;if(i==="components"||i==="slots")r[i]={...e[i],...r[i]};else if(i==="componentsProps"||i==="slotProps"){const o=e[i],a=t[i];if(!a)r[i]=o||{};else if(!o)r[i]=a;else{r[i]={...a};for(const s in o)if(Object.prototype.hasOwnProperty.call(o,s)){const l=s;r[i][l]=qo(o[l],a[l])}}}else r[i]===void 0&&(r[i]=e[i])}return r}function VS(e,t,r=void 0){const n={};for(const i in e){const o=e[i];let a="",s=!0;for(let l=0;l<o.length;l+=1){const u=o[l];u&&(a+=(s===!0?"":" ")+t(u),s=!1,r&&r[u]&&(a+=" "+r[u]))}n[i]=a}return n}const vc=e=>e,WS=(()=>{let e=vc;return{configure(t){e=t},generate(t){return e(t)},reset(){e=vc}}})(),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 Ko(e,t,r="Mui"){const n=HS[t];return n?`${r}-${n}`:`${WS.generate(e)}-${t}`}function GS(e,t,r="Mui"){const n={};return t.forEach(i=>{n[i]=Ko(e,i,r)}),n}function YS(e,t=Number.MIN_SAFE_INTEGER,r=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,r))}function bc(e){var t,r,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(r=bc(e[t]))&&(n&&(n+=" "),n+=r)}else for(r in e)e[r]&&(n&&(n+=" "),n+=r);return n}function qS(){for(var e,t,r=0,n="",i=arguments.length;r<i;r++)(e=arguments[r])&&(t=bc(e))&&(n&&(n+=" "),n+=t);return n}function Mr(e,t){return t?et(e,t,{clone:!1}):e}const $t=process.env.NODE_ENV!=="production"?de.oneOfType([de.number,de.string,de.object,de.array]):{};function KS(e,t){if(!e.containerQueries)return t;const r=Object.keys(t).filter(n=>n.startsWith("@container")).sort((n,i)=>{var a,s;const o=/min-width:\s*([0-9.]+)/;return+(((a=n.match(o))==null?void 0:a[1])||0)-+(((s=i.match(o))==null?void 0:s[1])||0)});return r.length?r.reduce((n,i)=>{const o=t[i];return delete n[i],n[i]=o,n},{...t}):t}function XS(e,t){return t==="@"||t.startsWith("@")&&(e.some(r=>t.startsWith(`@${r}`))||!!t.match(/^@\d/))}function JS(e,t){const r=t.match(/^@([^/]+)?\/?(.+)?$/);if(!r){if(process.env.NODE_ENV!=="production")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The provided shorthand ${`(${t})`} is invalid. The format should be \`@<breakpoint | number>\` or \`@<breakpoint | number>/<container>\`.
|
|
156
|
+
For example, \`@sm\` or \`@600\` or \`@40rem/sidebar\`.`:It(18,`(${t})`));return null}const[,n,i]=r,o=Number.isNaN(+n)?n||0:+n;return e.containerQueries(i).up(o)}function ZS(e){const t=(o,a)=>o.replace("@media",a?`@container ${a}`:"@container");function r(o,a){o.up=(...s)=>t(e.breakpoints.up(...s),a),o.down=(...s)=>t(e.breakpoints.down(...s),a),o.between=(...s)=>t(e.breakpoints.between(...s),a),o.only=(...s)=>t(e.breakpoints.only(...s),a),o.not=(...s)=>{const l=t(e.breakpoints.not(...s),a);return l.includes("not all and")?l.replace("not all and ","").replace("min-width:","width<").replace("max-width:","width>").replace("and","or"):l}}const n={},i=o=>(r(n,o),n);return r(i),{...e,containerQueries:i}}const Bn={xs:0,sm:600,md:900,lg:1200,xl:1536},xc={keys:["xs","sm","md","lg","xl"],up:e=>`@media (min-width:${Bn[e]}px)`},QS={containerQueries:e=>({up:t=>{let r=typeof t=="number"?t:Bn[t]||t;return typeof r=="number"&&(r=`${r}px`),e?`@container ${e} (min-width:${r})`:`@container (min-width:${r})`}})};function Tt(e,t,r){const n=e.theme||{};if(Array.isArray(t)){const o=n.breakpoints||xc;return t.reduce((a,s,l)=>(a[o.up(o.keys[l])]=r(t[l]),a),{})}if(typeof t=="object"){const o=n.breakpoints||xc;return Object.keys(t).reduce((a,s)=>{if(XS(o.keys,s)){const l=JS(n.containerQueries?n:QS,s);l&&(a[l]=r(t[s],s))}else if(Object.keys(o.values||Bn).includes(s)){const l=o.up(s);a[l]=r(t[s],s)}else{const l=s;a[l]=t[l]}return a},{})}return r(t)}function eC(e={}){var r;return((r=e.keys)==null?void 0:r.reduce((n,i)=>{const o=e.up(i);return n[o]={},n},{}))||{}}function tC(e,t){return e.reduce((r,n)=>{const i=r[n];return(!i||Object.keys(i).length===0)&&delete r[n],r},t)}function Un(e,t,r=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&r){const n=`vars.${t}`.split(".").reduce((i,o)=>i&&i[o]?i[o]:null,e);if(n!=null)return n}return t.split(".").reduce((n,i)=>n&&n[i]!=null?n[i]:null,e)}function Vn(e,t,r,n=r){let i;return typeof e=="function"?i=e(r):Array.isArray(e)?i=e[r]||n:i=Un(e,r)||n,t&&(i=t(i,n,e)),i}function je(e){const{prop:t,cssProperty:r=e.prop,themeKey:n,transform:i}=e,o=a=>{if(a[t]==null)return null;const s=a[t],l=a.theme,u=Un(l,n)||{};return Tt(a,s,c=>{let p=Vn(u,i,c);return c===p&&typeof c=="string"&&(p=Vn(u,i,`${t}${c==="default"?"":Gt(c)}`,c)),r===!1?p:{[r]:p}})};return o.propTypes=process.env.NODE_ENV!=="production"?{[t]:$t}:{},o.filterProps=[t],o}function rC(e){const t={};return r=>(t[r]===void 0&&(t[r]=e(r)),t[r])}const nC={m:"margin",p:"padding"},iC={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},Tc={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},oC=rC(e=>{if(e.length>2)if(Tc[e])e=Tc[e];else return[e];const[t,r]=e.split(""),n=nC[t],i=iC[r]||"";return Array.isArray(i)?i.map(o=>n+o):[n+i]}),Wn=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],Hn=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],aC=[...Wn,...Hn];function Rr(e,t,r,n){const i=Un(e,t,!0)??r;return typeof i=="number"||typeof i=="string"?o=>typeof o=="string"?o:(process.env.NODE_ENV!=="production"&&typeof o!="number"&&console.error(`MUI: Expected ${n} argument to be a number or a string, got ${o}.`),typeof i=="string"?`calc(${o} * ${i})`:i*o):Array.isArray(i)?o=>{if(typeof o=="string")return o;const a=Math.abs(o);process.env.NODE_ENV!=="production"&&(Number.isInteger(a)?a>i.length-1&&console.error([`MUI: The value provided (${a}) overflows.`,`The supported values are: ${JSON.stringify(i)}.`,`${a} > ${i.length-1}, you need to add the missing values.`].join(`
|
|
157
157
|
`)):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(`
|
|
158
158
|
`)));const s=i[a];return o>=0?s:typeof s=="number"?-s:`-${s}`}:typeof i=="function"?i:(process.env.NODE_ENV!=="production"&&console.error([`MUI: The \`theme.${t}\` value (${i}) is invalid.`,"It should be a number, an array or a function."].join(`
|
|
159
|
-
`)),()=>{})}function Xo(e){return Rr(e,"spacing",8,"spacing")}function Nr(e,t){return typeof t=="string"||t==null?t:e(t)}function aC(e,t){return r=>e.reduce((n,i)=>(n[i]=Nr(t,r),n),{})}function sC(e,t,r,n){if(!t.includes(r))return null;const i=iC(r),o=aC(i,n),a=e[r];return Tt(e,a,o)}function _c(e,t){const r=Xo(e.theme);return Object.keys(e).map(n=>sC(e,t,n,r)).reduce(Mr,{})}function Oe(e){return _c(e,Wn)}Oe.propTypes=process.env.NODE_ENV!=="production"?Wn.reduce((e,t)=>(e[t]=$t,e),{}):{},Oe.filterProps=Wn;function ke(e){return _c(e,Hn)}ke.propTypes=process.env.NODE_ENV!=="production"?Hn.reduce((e,t)=>(e[t]=$t,e),{}):{},ke.filterProps=Hn,process.env.NODE_ENV!=="production"&&oC.reduce((e,t)=>(e[t]=$t,e),{});function Gn(...e){const t=e.reduce((n,i)=>(i.filterProps.forEach(o=>{n[o]=i}),n),{}),r=n=>Object.keys(n).reduce((i,o)=>t[o]?Mr(i,t[o](n)):i,{});return r.propTypes=process.env.NODE_ENV!=="production"?e.reduce((n,i)=>Object.assign(n,i.propTypes),{}):{},r.filterProps=e.reduce((n,i)=>n.concat(i.filterProps),[]),r}function it(e){return typeof e!="number"?e:`${e}px solid`}function ot(e,t){return je({prop:e,themeKey:"borders",transform:t})}const lC=ot("border",it),uC=ot("borderTop",it),cC=ot("borderRight",it),fC=ot("borderBottom",it),dC=ot("borderLeft",it),pC=ot("borderColor"),hC=ot("borderTopColor"),mC=ot("borderRightColor"),gC=ot("borderBottomColor"),yC=ot("borderLeftColor"),vC=ot("outline",it),bC=ot("outlineColor"),Yn=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=Rr(e.theme,"shape.borderRadius",4,"borderRadius"),r=n=>({borderRadius:Nr(t,n)});return Tt(e,e.borderRadius,r)}return null};Yn.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:$t}:{},Yn.filterProps=["borderRadius"],Gn(lC,uC,cC,fC,dC,pC,hC,mC,gC,yC,Yn,vC,bC);const qn=e=>{if(e.gap!==void 0&&e.gap!==null){const t=Rr(e.theme,"spacing",8,"gap"),r=n=>({gap:Nr(t,n)});return Tt(e,e.gap,r)}return null};qn.propTypes=process.env.NODE_ENV!=="production"?{gap:$t}:{},qn.filterProps=["gap"];const Kn=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=Rr(e.theme,"spacing",8,"columnGap"),r=n=>({columnGap:Nr(t,n)});return Tt(e,e.columnGap,r)}return null};Kn.propTypes=process.env.NODE_ENV!=="production"?{columnGap:$t}:{},Kn.filterProps=["columnGap"];const Xn=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=Rr(e.theme,"spacing",8,"rowGap"),r=n=>({rowGap:Nr(t,n)});return Tt(e,e.rowGap,r)}return null};Xn.propTypes=process.env.NODE_ENV!=="production"?{rowGap:$t}:{},Xn.filterProps=["rowGap"];const xC=je({prop:"gridColumn"}),TC=je({prop:"gridRow"}),_C=je({prop:"gridAutoFlow"}),SC=je({prop:"gridAutoColumns"}),EC=je({prop:"gridAutoRows"}),CC=je({prop:"gridTemplateColumns"}),wC=je({prop:"gridTemplateRows"}),AC=je({prop:"gridTemplateAreas"}),OC=je({prop:"gridArea"});Gn(qn,Kn,Xn,xC,TC,_C,SC,EC,CC,wC,AC,OC);function lr(e,t){return t==="grey"?t:e}const kC=je({prop:"color",themeKey:"palette",transform:lr}),PC=je({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:lr}),jC=je({prop:"backgroundColor",themeKey:"palette",transform:lr});Gn(kC,PC,jC);function tt(e){return e<=1&&e!==0?`${e*100}%`:e}const IC=je({prop:"width",transform:tt}),Jo=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=r=>{var i,o,a,s,l;const n=((a=(o=(i=e.theme)==null?void 0:i.breakpoints)==null?void 0:o.values)==null?void 0:a[r])||Bn[r];return n?((l=(s=e.theme)==null?void 0:s.breakpoints)==null?void 0:l.unit)!=="px"?{maxWidth:`${n}${e.theme.breakpoints.unit}`}:{maxWidth:n}:{maxWidth:tt(r)}};return Tt(e,e.maxWidth,t)}return null};Jo.filterProps=["maxWidth"];const $C=je({prop:"minWidth",transform:tt}),DC=je({prop:"height",transform:tt}),MC=je({prop:"maxHeight",transform:tt}),RC=je({prop:"minHeight",transform:tt});je({prop:"size",cssProperty:"width",transform:tt}),je({prop:"size",cssProperty:"height",transform:tt});const NC=je({prop:"boxSizing"});Gn(IC,Jo,$C,DC,MC,RC,NC);const Jn={border:{themeKey:"borders",transform:it},borderTop:{themeKey:"borders",transform:it},borderRight:{themeKey:"borders",transform:it},borderBottom:{themeKey:"borders",transform:it},borderLeft:{themeKey:"borders",transform:it},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:it},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:Yn},color:{themeKey:"palette",transform:lr},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:lr},backgroundColor:{themeKey:"palette",transform:lr},p:{style:ke},pt:{style:ke},pr:{style:ke},pb:{style:ke},pl:{style:ke},px:{style:ke},py:{style:ke},padding:{style:ke},paddingTop:{style:ke},paddingRight:{style:ke},paddingBottom:{style:ke},paddingLeft:{style:ke},paddingX:{style:ke},paddingY:{style:ke},paddingInline:{style:ke},paddingInlineStart:{style:ke},paddingInlineEnd:{style:ke},paddingBlock:{style:ke},paddingBlockStart:{style:ke},paddingBlockEnd:{style:ke},m:{style:Oe},mt:{style:Oe},mr:{style:Oe},mb:{style:Oe},ml:{style:Oe},mx:{style:Oe},my:{style:Oe},margin:{style:Oe},marginTop:{style:Oe},marginRight:{style:Oe},marginBottom:{style:Oe},marginLeft:{style:Oe},marginX:{style:Oe},marginY:{style:Oe},marginInline:{style:Oe},marginInlineStart:{style:Oe},marginInlineEnd:{style:Oe},marginBlock:{style:Oe},marginBlockStart:{style:Oe},marginBlockEnd:{style:Oe},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:qn},rowGap:{style:Xn},columnGap:{style:Kn},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:tt},maxWidth:{style:Jo},minWidth:{transform:tt},height:{transform:tt},maxHeight:{transform:tt},minHeight:{transform:tt},boxSizing:{},font:{themeKey:"font"},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}};function FC(...e){const t=e.reduce((n,i)=>n.concat(Object.keys(i)),[]),r=new Set(t);return e.every(n=>r.size===Object.keys(n).length)}function LC(e,t){return typeof e=="function"?e(t):e}function zC(){function e(r,n,i,o){const a={[r]:n,theme:i},s=o[r];if(!s)return{[r]:n};const{cssProperty:l=r,themeKey:u,transform:f,style:c}=s;if(n==null)return null;if(u==="typography"&&n==="inherit")return{[r]:n};const p=Un(i,u)||{};return c?c(a):Tt(a,n,m=>{let y=Vn(p,f,m);return m===y&&typeof m=="string"&&(y=Vn(p,f,`${r}${m==="default"?"":Gt(m)}`,m)),l===!1?y:{[l]:y}})}function t(r){const{sx:n,theme:i={}}=r||{};if(!n)return null;const o=i.unstable_sxConfig??Jn;function a(s){let l=s;if(typeof s=="function")l=s(i);else if(typeof s!="object")return s;if(!l)return null;const u=QE(i.breakpoints),f=Object.keys(u);let c=u;return Object.keys(l).forEach(p=>{const v=LC(l[p],i);if(v!=null)if(typeof v=="object")if(o[p])c=Mr(c,e(p,v,i,o));else{const m=Tt({theme:i},v,y=>({[p]:y}));FC(m,v)?c[p]=t({sx:v,theme:i}):c=Mr(c,m)}else c=Mr(c,e(p,v,i,o))}),qE(i,eC(f,c))}return Array.isArray(n)?n.map(a):a(n)}return t}const ur=zC();ur.filterProps=["sx"];function Zo(){return Zo=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Zo.apply(null,arguments)}function Sc(e){var t=Object.create(null);return function(r){return t[r]===void 0&&(t[r]=e(r)),t[r]}}var BC=/^((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|disableRemotePlayback|download|draggable|encType|enterKeyHint|fetchpriority|fetchPriority|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)-.*))$/,UC=Sc(function(e){return BC.test(e)||e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)<91}),VC=!0;function WC(e,t,r){var n="";return r.split(" ").forEach(function(i){e[i]!==void 0?t.push(e[i]+";"):i&&(n+=i+" ")}),n}var Ec=function(t,r,n){var i=t.key+"-"+r.name;(n===!1||VC===!1)&&t.registered[i]===void 0&&(t.registered[i]=r.styles)},HC=function(t,r,n){Ec(t,r,n);var i=t.key+"-"+r.name;if(t.inserted[r.name]===void 0){var o=r;do t.insert(r===o?"."+i:"",o,t.sheet,!0),o=o.next;while(o!==void 0)}};function GC(e){for(var t=0,r,n=0,i=e.length;i>=4;++n,i-=4)r=e.charCodeAt(n)&255|(e.charCodeAt(++n)&255)<<8|(e.charCodeAt(++n)&255)<<16|(e.charCodeAt(++n)&255)<<24,r=(r&65535)*1540483477+((r>>>16)*59797<<16),r^=r>>>24,t=(r&65535)*1540483477+((r>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(i){case 3:t^=(e.charCodeAt(n+2)&255)<<16;case 2:t^=(e.charCodeAt(n+1)&255)<<8;case 1:t^=e.charCodeAt(n)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var YC={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},qC=!1,KC=/[A-Z]|^ms/g,XC=/_EMO_([^_]+?)_([^]*?)_EMO_/g,Cc=function(t){return t.charCodeAt(1)===45},wc=function(t){return t!=null&&typeof t!="boolean"},Qo=Sc(function(e){return Cc(e)?e:e.replace(KC,"-$&").toLowerCase()}),Ac=function(t,r){switch(t){case"animation":case"animationName":if(typeof r=="string")return r.replace(XC,function(n,i,o){return ht={name:i,styles:o,next:ht},i})}return YC[t]!==1&&!Cc(t)&&typeof r=="number"&&r!==0?r+"px":r},JC="Component selectors can only be used in conjunction with @emotion/babel-plugin, the swc Emotion plugin, or another Emotion-aware compiler transform.";function Fr(e,t,r){if(r==null)return"";var n=r;if(n.__emotion_styles!==void 0)return n;switch(typeof r){case"boolean":return"";case"object":{var i=r;if(i.anim===1)return ht={name:i.name,styles:i.styles,next:ht},i.name;var o=r;if(o.styles!==void 0){var a=o.next;if(a!==void 0)for(;a!==void 0;)ht={name:a.name,styles:a.styles,next:ht},a=a.next;var s=o.styles+";";return s}return ZC(e,t,r)}case"function":{if(e!==void 0){var l=ht,u=r(e);return ht=l,Fr(e,t,u)}break}}var f=r;if(t==null)return f;var c=t[f];return c!==void 0?c:f}function ZC(e,t,r){var n="";if(Array.isArray(r))for(var i=0;i<r.length;i++)n+=Fr(e,t,r[i])+";";else for(var o in r){var a=r[o];if(typeof a!="object"){var s=a;t!=null&&t[s]!==void 0?n+=o+"{"+t[s]+"}":wc(s)&&(n+=Qo(o)+":"+Ac(o,s)+";")}else{if(o==="NO_COMPONENT_SELECTOR"&&qC)throw new Error(JC);if(Array.isArray(a)&&typeof a[0]=="string"&&(t==null||t[a[0]]===void 0))for(var l=0;l<a.length;l++)wc(a[l])&&(n+=Qo(o)+":"+Ac(o,a[l])+";");else{var u=Fr(e,t,a);switch(o){case"animation":case"animationName":{n+=Qo(o)+":"+u+";";break}default:n+=o+"{"+u+"}"}}}}return n}var Oc=/label:\s*([^\s;{]+)\s*(;|$)/g,ht;function kc(e,t,r){if(e.length===1&&typeof e[0]=="object"&&e[0]!==null&&e[0].styles!==void 0)return e[0];var n=!0,i="";ht=void 0;var o=e[0];if(o==null||o.raw===void 0)n=!1,i+=Fr(r,t,o);else{var a=o;i+=a[0]}for(var s=1;s<e.length;s++)if(i+=Fr(r,t,e[s]),n){var l=o;i+=l[s]}Oc.lastIndex=0;for(var u="",f;(f=Oc.exec(i))!==null;)u+="-"+f[1];var c=GC(i)+u;return{name:c,styles:i,next:ht}}var QC=function(t){return t()},ew=Je.useInsertionEffect?Je.useInsertionEffect:!1,tw=ew||QC,rw=UC,nw=function(t){return t!=="theme"},Pc=function(t){return typeof t=="string"&&t.charCodeAt(0)>96?rw:nw},jc=function(t,r,n){var i;if(r){var o=r.shouldForwardProp;i=t.__emotion_forwardProp&&o?function(a){return t.__emotion_forwardProp(a)&&o(a)}:o}return typeof i!="function"&&n&&(i=t.__emotion_forwardProp),i},iw=!1,ow=function(t){var r=t.cache,n=t.serialized,i=t.isStringTag;return Ec(r,n,i),tw(function(){return HC(r,n,i)}),null},aw=function e(t,r){var n=t.__emotion_real===t,i=n&&t.__emotion_base||t,o,a;r!==void 0&&(o=r.label,a=r.target);var s=jc(t,r,n),l=s||Pc(i),u=!l("as");return function(){var f=arguments,c=n&&t.__emotion_styles!==void 0?t.__emotion_styles.slice(0):[];if(o!==void 0&&c.push("label:"+o+";"),f[0]==null||f[0].raw===void 0)c.push.apply(c,f);else{c.push(f[0][0]);for(var p=f.length,v=1;v<p;v++)c.push(f[v],f[0][v])}var m=pa.withEmotionCache(function(y,T,j){var F=u&&y.as||i,D="",O=[],S=y;if(y.theme==null){S={};for(var M in y)S[M]=y[M];S.theme=Je.useContext(pa.ThemeContext)}typeof y.className=="string"?D=WC(T.registered,O,y.className):y.className!=null&&(D=y.className+" ");var Y=kc(c.concat(O),T.registered,S);D+=T.key+"-"+Y.name,a!==void 0&&(D+=" "+a);var ce=u&&s===void 0?Pc(F):l,ie={};for(var h in y)u&&h==="as"||ce(h)&&(ie[h]=y[h]);return ie.className=D,j&&(ie.ref=j),Je.createElement(Je.Fragment,null,Je.createElement(ow,{cache:T,serialized:Y,isStringTag:typeof F=="string"}),Je.createElement(F,ie))});return m.displayName=o!==void 0?o:"Styled("+(typeof i=="string"?i:i.displayName||i.name||"Component")+")",m.defaultProps=t.defaultProps,m.__emotion_real=m,m.__emotion_base=i,m.__emotion_styles=c,m.__emotion_forwardProp=s,Object.defineProperty(m,"toString",{value:function(){return a===void 0&&iw?"NO_COMPONENT_SELECTOR":"."+a}}),m.withComponent=function(y,T){return e(y,Zo({},r,T,{shouldForwardProp:jc(m,T,!0)})).apply(void 0,c)},m}},sw=["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"],ea=aw.bind();sw.forEach(function(e){ea[e]=ea(e)});/**
|
|
160
|
-
* @mui/styled-engine v6.1.
|
|
159
|
+
`)),()=>{})}function Xo(e){return Rr(e,"spacing",8,"spacing")}function Nr(e,t){return typeof t=="string"||t==null?t:e(t)}function sC(e,t){return r=>e.reduce((n,i)=>(n[i]=Nr(t,r),n),{})}function lC(e,t,r,n){if(!t.includes(r))return null;const i=oC(r),o=sC(i,n),a=e[r];return Tt(e,a,o)}function _c(e,t){const r=Xo(e.theme);return Object.keys(e).map(n=>lC(e,t,n,r)).reduce(Mr,{})}function Oe(e){return _c(e,Wn)}Oe.propTypes=process.env.NODE_ENV!=="production"?Wn.reduce((e,t)=>(e[t]=$t,e),{}):{},Oe.filterProps=Wn;function ke(e){return _c(e,Hn)}ke.propTypes=process.env.NODE_ENV!=="production"?Hn.reduce((e,t)=>(e[t]=$t,e),{}):{},ke.filterProps=Hn,process.env.NODE_ENV!=="production"&&aC.reduce((e,t)=>(e[t]=$t,e),{});function Gn(...e){const t=e.reduce((n,i)=>(i.filterProps.forEach(o=>{n[o]=i}),n),{}),r=n=>Object.keys(n).reduce((i,o)=>t[o]?Mr(i,t[o](n)):i,{});return r.propTypes=process.env.NODE_ENV!=="production"?e.reduce((n,i)=>Object.assign(n,i.propTypes),{}):{},r.filterProps=e.reduce((n,i)=>n.concat(i.filterProps),[]),r}function it(e){return typeof e!="number"?e:`${e}px solid`}function ot(e,t){return je({prop:e,themeKey:"borders",transform:t})}const uC=ot("border",it),cC=ot("borderTop",it),fC=ot("borderRight",it),dC=ot("borderBottom",it),pC=ot("borderLeft",it),hC=ot("borderColor"),mC=ot("borderTopColor"),gC=ot("borderRightColor"),yC=ot("borderBottomColor"),vC=ot("borderLeftColor"),bC=ot("outline",it),xC=ot("outlineColor"),Yn=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=Rr(e.theme,"shape.borderRadius",4,"borderRadius"),r=n=>({borderRadius:Nr(t,n)});return Tt(e,e.borderRadius,r)}return null};Yn.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:$t}:{},Yn.filterProps=["borderRadius"],Gn(uC,cC,fC,dC,pC,hC,mC,gC,yC,vC,Yn,bC,xC);const qn=e=>{if(e.gap!==void 0&&e.gap!==null){const t=Rr(e.theme,"spacing",8,"gap"),r=n=>({gap:Nr(t,n)});return Tt(e,e.gap,r)}return null};qn.propTypes=process.env.NODE_ENV!=="production"?{gap:$t}:{},qn.filterProps=["gap"];const Kn=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=Rr(e.theme,"spacing",8,"columnGap"),r=n=>({columnGap:Nr(t,n)});return Tt(e,e.columnGap,r)}return null};Kn.propTypes=process.env.NODE_ENV!=="production"?{columnGap:$t}:{},Kn.filterProps=["columnGap"];const Xn=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=Rr(e.theme,"spacing",8,"rowGap"),r=n=>({rowGap:Nr(t,n)});return Tt(e,e.rowGap,r)}return null};Xn.propTypes=process.env.NODE_ENV!=="production"?{rowGap:$t}:{},Xn.filterProps=["rowGap"];const TC=je({prop:"gridColumn"}),_C=je({prop:"gridRow"}),EC=je({prop:"gridAutoFlow"}),SC=je({prop:"gridAutoColumns"}),CC=je({prop:"gridAutoRows"}),wC=je({prop:"gridTemplateColumns"}),AC=je({prop:"gridTemplateRows"}),OC=je({prop:"gridTemplateAreas"}),kC=je({prop:"gridArea"});Gn(qn,Kn,Xn,TC,_C,EC,SC,CC,wC,AC,OC,kC);function lr(e,t){return t==="grey"?t:e}const PC=je({prop:"color",themeKey:"palette",transform:lr}),jC=je({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:lr}),IC=je({prop:"backgroundColor",themeKey:"palette",transform:lr});Gn(PC,jC,IC);function tt(e){return e<=1&&e!==0?`${e*100}%`:e}const $C=je({prop:"width",transform:tt}),Jo=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=r=>{var i,o,a,s,l;const n=((a=(o=(i=e.theme)==null?void 0:i.breakpoints)==null?void 0:o.values)==null?void 0:a[r])||Bn[r];return n?((l=(s=e.theme)==null?void 0:s.breakpoints)==null?void 0:l.unit)!=="px"?{maxWidth:`${n}${e.theme.breakpoints.unit}`}:{maxWidth:n}:{maxWidth:tt(r)}};return Tt(e,e.maxWidth,t)}return null};Jo.filterProps=["maxWidth"];const DC=je({prop:"minWidth",transform:tt}),MC=je({prop:"height",transform:tt}),RC=je({prop:"maxHeight",transform:tt}),NC=je({prop:"minHeight",transform:tt});je({prop:"size",cssProperty:"width",transform:tt}),je({prop:"size",cssProperty:"height",transform:tt});const FC=je({prop:"boxSizing"});Gn($C,Jo,DC,MC,RC,NC,FC);const Jn={border:{themeKey:"borders",transform:it},borderTop:{themeKey:"borders",transform:it},borderRight:{themeKey:"borders",transform:it},borderBottom:{themeKey:"borders",transform:it},borderLeft:{themeKey:"borders",transform:it},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:it},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:Yn},color:{themeKey:"palette",transform:lr},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:lr},backgroundColor:{themeKey:"palette",transform:lr},p:{style:ke},pt:{style:ke},pr:{style:ke},pb:{style:ke},pl:{style:ke},px:{style:ke},py:{style:ke},padding:{style:ke},paddingTop:{style:ke},paddingRight:{style:ke},paddingBottom:{style:ke},paddingLeft:{style:ke},paddingX:{style:ke},paddingY:{style:ke},paddingInline:{style:ke},paddingInlineStart:{style:ke},paddingInlineEnd:{style:ke},paddingBlock:{style:ke},paddingBlockStart:{style:ke},paddingBlockEnd:{style:ke},m:{style:Oe},mt:{style:Oe},mr:{style:Oe},mb:{style:Oe},ml:{style:Oe},mx:{style:Oe},my:{style:Oe},margin:{style:Oe},marginTop:{style:Oe},marginRight:{style:Oe},marginBottom:{style:Oe},marginLeft:{style:Oe},marginX:{style:Oe},marginY:{style:Oe},marginInline:{style:Oe},marginInlineStart:{style:Oe},marginInlineEnd:{style:Oe},marginBlock:{style:Oe},marginBlockStart:{style:Oe},marginBlockEnd:{style:Oe},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:qn},rowGap:{style:Xn},columnGap:{style:Kn},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:tt},maxWidth:{style:Jo},minWidth:{transform:tt},height:{transform:tt},maxHeight:{transform:tt},minHeight:{transform:tt},boxSizing:{},font:{themeKey:"font"},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}};function LC(...e){const t=e.reduce((n,i)=>n.concat(Object.keys(i)),[]),r=new Set(t);return e.every(n=>r.size===Object.keys(n).length)}function zC(e,t){return typeof e=="function"?e(t):e}function BC(){function e(r,n,i,o){const a={[r]:n,theme:i},s=o[r];if(!s)return{[r]:n};const{cssProperty:l=r,themeKey:u,transform:f,style:c}=s;if(n==null)return null;if(u==="typography"&&n==="inherit")return{[r]:n};const p=Un(i,u)||{};return c?c(a):Tt(a,n,g=>{let m=Vn(p,f,g);return g===m&&typeof g=="string"&&(m=Vn(p,f,`${r}${g==="default"?"":Gt(g)}`,g)),l===!1?m:{[l]:m}})}function t(r){const{sx:n,theme:i={}}=r||{};if(!n)return null;const o=i.unstable_sxConfig??Jn;function a(s){let l=s;if(typeof s=="function")l=s(i);else if(typeof s!="object")return s;if(!l)return null;const u=eC(i.breakpoints),f=Object.keys(u);let c=u;return Object.keys(l).forEach(p=>{const y=zC(l[p],i);if(y!=null)if(typeof y=="object")if(o[p])c=Mr(c,e(p,y,i,o));else{const g=Tt({theme:i},y,m=>({[p]:m}));LC(g,y)?c[p]=t({sx:y,theme:i}):c=Mr(c,g)}else c=Mr(c,e(p,y,i,o))}),KS(i,tC(f,c))}return Array.isArray(n)?n.map(a):a(n)}return t}const ur=BC();ur.filterProps=["sx"];function Zo(){return Zo=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Zo.apply(null,arguments)}function Ec(e){var t=Object.create(null);return function(r){return t[r]===void 0&&(t[r]=e(r)),t[r]}}var UC=/^((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|disableRemotePlayback|download|draggable|encType|enterKeyHint|fetchpriority|fetchPriority|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)-.*))$/,VC=Ec(function(e){return UC.test(e)||e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)<91}),WC=!0;function HC(e,t,r){var n="";return r.split(" ").forEach(function(i){e[i]!==void 0?t.push(e[i]+";"):i&&(n+=i+" ")}),n}var Sc=function(t,r,n){var i=t.key+"-"+r.name;(n===!1||WC===!1)&&t.registered[i]===void 0&&(t.registered[i]=r.styles)},GC=function(t,r,n){Sc(t,r,n);var i=t.key+"-"+r.name;if(t.inserted[r.name]===void 0){var o=r;do t.insert(r===o?"."+i:"",o,t.sheet,!0),o=o.next;while(o!==void 0)}};function YC(e){for(var t=0,r,n=0,i=e.length;i>=4;++n,i-=4)r=e.charCodeAt(n)&255|(e.charCodeAt(++n)&255)<<8|(e.charCodeAt(++n)&255)<<16|(e.charCodeAt(++n)&255)<<24,r=(r&65535)*1540483477+((r>>>16)*59797<<16),r^=r>>>24,t=(r&65535)*1540483477+((r>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(i){case 3:t^=(e.charCodeAt(n+2)&255)<<16;case 2:t^=(e.charCodeAt(n+1)&255)<<8;case 1:t^=e.charCodeAt(n)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var qC={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},KC=!1,XC=/[A-Z]|^ms/g,JC=/_EMO_([^_]+?)_([^]*?)_EMO_/g,Cc=function(t){return t.charCodeAt(1)===45},wc=function(t){return t!=null&&typeof t!="boolean"},Qo=Ec(function(e){return Cc(e)?e:e.replace(XC,"-$&").toLowerCase()}),Ac=function(t,r){switch(t){case"animation":case"animationName":if(typeof r=="string")return r.replace(JC,function(n,i,o){return ht={name:i,styles:o,next:ht},i})}return qC[t]!==1&&!Cc(t)&&typeof r=="number"&&r!==0?r+"px":r},ZC="Component selectors can only be used in conjunction with @emotion/babel-plugin, the swc Emotion plugin, or another Emotion-aware compiler transform.";function Fr(e,t,r){if(r==null)return"";var n=r;if(n.__emotion_styles!==void 0)return n;switch(typeof r){case"boolean":return"";case"object":{var i=r;if(i.anim===1)return ht={name:i.name,styles:i.styles,next:ht},i.name;var o=r;if(o.styles!==void 0){var a=o.next;if(a!==void 0)for(;a!==void 0;)ht={name:a.name,styles:a.styles,next:ht},a=a.next;var s=o.styles+";";return s}return QC(e,t,r)}case"function":{if(e!==void 0){var l=ht,u=r(e);return ht=l,Fr(e,t,u)}break}}var f=r;if(t==null)return f;var c=t[f];return c!==void 0?c:f}function QC(e,t,r){var n="";if(Array.isArray(r))for(var i=0;i<r.length;i++)n+=Fr(e,t,r[i])+";";else for(var o in r){var a=r[o];if(typeof a!="object"){var s=a;t!=null&&t[s]!==void 0?n+=o+"{"+t[s]+"}":wc(s)&&(n+=Qo(o)+":"+Ac(o,s)+";")}else{if(o==="NO_COMPONENT_SELECTOR"&&KC)throw new Error(ZC);if(Array.isArray(a)&&typeof a[0]=="string"&&(t==null||t[a[0]]===void 0))for(var l=0;l<a.length;l++)wc(a[l])&&(n+=Qo(o)+":"+Ac(o,a[l])+";");else{var u=Fr(e,t,a);switch(o){case"animation":case"animationName":{n+=Qo(o)+":"+u+";";break}default:n+=o+"{"+u+"}"}}}}return n}var Oc=/label:\s*([^\s;{]+)\s*(;|$)/g,ht;function kc(e,t,r){if(e.length===1&&typeof e[0]=="object"&&e[0]!==null&&e[0].styles!==void 0)return e[0];var n=!0,i="";ht=void 0;var o=e[0];if(o==null||o.raw===void 0)n=!1,i+=Fr(r,t,o);else{var a=o;i+=a[0]}for(var s=1;s<e.length;s++)if(i+=Fr(r,t,e[s]),n){var l=o;i+=l[s]}Oc.lastIndex=0;for(var u="",f;(f=Oc.exec(i))!==null;)u+="-"+f[1];var c=YC(i)+u;return{name:c,styles:i,next:ht}}var ew=function(t){return t()},tw=Je.useInsertionEffect?Je.useInsertionEffect:!1,rw=tw||ew,nw=VC,iw=function(t){return t!=="theme"},Pc=function(t){return typeof t=="string"&&t.charCodeAt(0)>96?nw:iw},jc=function(t,r,n){var i;if(r){var o=r.shouldForwardProp;i=t.__emotion_forwardProp&&o?function(a){return t.__emotion_forwardProp(a)&&o(a)}:o}return typeof i!="function"&&n&&(i=t.__emotion_forwardProp),i},ow=!1,aw=function(t){var r=t.cache,n=t.serialized,i=t.isStringTag;return Sc(r,n,i),rw(function(){return GC(r,n,i)}),null},sw=function e(t,r){var n=t.__emotion_real===t,i=n&&t.__emotion_base||t,o,a;r!==void 0&&(o=r.label,a=r.target);var s=jc(t,r,n),l=s||Pc(i),u=!l("as");return function(){var f=arguments,c=n&&t.__emotion_styles!==void 0?t.__emotion_styles.slice(0):[];if(o!==void 0&&c.push("label:"+o+";"),f[0]==null||f[0].raw===void 0)c.push.apply(c,f);else{c.push(f[0][0]);for(var p=f.length,y=1;y<p;y++)c.push(f[y],f[0][y])}var g=pa.withEmotionCache(function(m,T,j){var F=u&&m.as||i,D="",O=[],E=m;if(m.theme==null){E={};for(var M in m)E[M]=m[M];E.theme=Je.useContext(pa.ThemeContext)}typeof m.className=="string"?D=HC(T.registered,O,m.className):m.className!=null&&(D=m.className+" ");var Y=kc(c.concat(O),T.registered,E);D+=T.key+"-"+Y.name,a!==void 0&&(D+=" "+a);var ce=u&&s===void 0?Pc(F):l,ie={};for(var h in m)u&&h==="as"||ce(h)&&(ie[h]=m[h]);return ie.className=D,j&&(ie.ref=j),Je.createElement(Je.Fragment,null,Je.createElement(aw,{cache:T,serialized:Y,isStringTag:typeof F=="string"}),Je.createElement(F,ie))});return g.displayName=o!==void 0?o:"Styled("+(typeof i=="string"?i:i.displayName||i.name||"Component")+")",g.defaultProps=t.defaultProps,g.__emotion_real=g,g.__emotion_base=i,g.__emotion_styles=c,g.__emotion_forwardProp=s,Object.defineProperty(g,"toString",{value:function(){return a===void 0&&ow?"NO_COMPONENT_SELECTOR":"."+a}}),g.withComponent=function(m,T){return e(m,Zo({},r,T,{shouldForwardProp:jc(g,T,!0)})).apply(void 0,c)},g}},lw=["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"],ea=sw.bind();lw.forEach(function(e){ea[e]=ea(e)});/**
|
|
160
|
+
* @mui/styled-engine v6.1.5
|
|
161
161
|
*
|
|
162
162
|
* @license MIT
|
|
163
163
|
* This source code is licensed under the MIT license found in the
|
|
164
164
|
* LICENSE file in the root directory of this source tree.
|
|
165
|
-
*/function
|
|
166
|
-
`)):n.some(o=>o===void 0)&&console.error(`MUI: the styled(${i})(...args) API requires all its args to be defined.`),r(...n)}:r}function
|
|
165
|
+
*/function uw(e,t){const r=ea(e,t);return process.env.NODE_ENV!=="production"?(...n)=>{const i=typeof e=="string"?`"${e}"`:"component";return n.length===0?console.error([`MUI: Seems like you called \`styled(${i})()\` without a \`style\` argument.`,'You must provide a `styles` argument: `styled("div")(styleYouForgotToPass)`.'].join(`
|
|
166
|
+
`)):n.some(o=>o===void 0)&&console.error(`MUI: the styled(${i})(...args) API requires all its args to be defined.`),r(...n)}:r}function cw(e,t){Array.isArray(e.__emotion_styles)&&(e.__emotion_styles=t(e.__emotion_styles))}const Ic=[];function $c(e){return Ic[0]=e,kc(Ic)}const fw=e=>{const t=Object.keys(e).map(r=>({key:r,val:e[r]}))||[];return t.sort((r,n)=>r.val-n.val),t.reduce((r,n)=>({...r,[n.key]:n.val}),{})};function dw(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:r="px",step:n=5,...i}=e,o=fw(t),a=Object.keys(o);function s(p){return`@media (min-width:${typeof t[p]=="number"?t[p]:p}${r})`}function l(p){return`@media (max-width:${(typeof t[p]=="number"?t[p]:p)-n/100}${r})`}function u(p,y){const g=a.indexOf(y);return`@media (min-width:${typeof t[p]=="number"?t[p]:p}${r}) and (max-width:${(g!==-1&&typeof t[a[g]]=="number"?t[a[g]]:y)-n/100}${r})`}function f(p){return a.indexOf(p)+1<a.length?u(p,a[a.indexOf(p)+1]):s(p)}function c(p){const y=a.indexOf(p);return y===0?s(a[1]):y===a.length-1?l(a[y]):u(p,a[a.indexOf(p)+1]).replace("@media","@media not all and")}return{keys:a,values:o,up:s,down:l,between:u,only:f,not:c,unit:r,...i}}const pw={borderRadius:4};function Dc(e=8,t=Xo({spacing:e})){if(e.mui)return e;const r=(...n)=>(process.env.NODE_ENV!=="production"&&(n.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${n.length}`)),(n.length===0?[1]:n).map(o=>{const a=t(o);return typeof a=="number"?`${a}px`:a}).join(" "));return r.mui=!0,r}function hw(e,t){var n;const r=this;if(r.vars){if(!((n=r.colorSchemes)!=null&&n[e])||typeof r.getColorSchemeSelector!="function")return{};let i=r.getColorSchemeSelector(e);return i==="&"?t:((i.includes("data-")||i.includes("."))&&(i=`*:where(${i.replace(/\s*&$/,"")}) &`),{[i]:t})}return r.palette.mode===e?t:{}}function Mc(e={},...t){const{breakpoints:r={},palette:n={},spacing:i,shape:o={},...a}=e,s=dw(r),l=Dc(i);let u=et({breakpoints:s,direction:"ltr",components:{},palette:{mode:"light",...n},spacing:l,shape:{...pw,...o}},a);return u=ZS(u),u.applyStyles=hw,u=t.reduce((f,c)=>et(f,c),u),u.unstable_sxConfig={...Jn,...a==null?void 0:a.unstable_sxConfig},u.unstable_sx=function(c){return ur({sx:c,theme:this})},u}function Rc(e){const{variants:t,...r}=e,n={variants:t,style:$c(r),isProcessed:!0};return n.style===r||t&&t.forEach(i=>{typeof i.style!="function"&&(i.style=$c(i.style))}),n}const mw=Mc();function ta(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}function gw(e){return e?(t,r)=>r[e]:null}function yw(e,t,r){e.theme=Tw(e.theme)?r:e.theme[t]||e.theme}function Zn(e,t){const r=typeof t=="function"?t(e):t;if(Array.isArray(r))return r.flatMap(n=>Zn(e,n));if(Array.isArray(r==null?void 0:r.variants)){let n;if(r.isProcessed)n=r.style;else{const{variants:i,...o}=r;n=o}return Nc(e,r.variants,[n])}return r!=null&&r.isProcessed?r.style:r}function Nc(e,t,r=[]){var i;let n;e:for(let o=0;o<t.length;o+=1){const a=t[o];if(typeof a.props=="function"){if(n??(n={...e,...e.ownerState,ownerState:e.ownerState}),!a.props(n))continue}else for(const s in a.props)if(e[s]!==a.props[s]&&((i=e.ownerState)==null?void 0:i[s])!==a.props[s])continue e;typeof a.style=="function"?(n??(n={...e,...e.ownerState,ownerState:e.ownerState}),r.push(a.style(n))):r.push(a.style)}return r}function vw(e={}){const{themeId:t,defaultTheme:r=mw,rootShouldForwardProp:n=ta,slotShouldForwardProp:i=ta}=e;function o(s){yw(s,t,r)}return(s,l={})=>{cw(s,E=>E.filter(M=>M!==ur));const{name:u,slot:f,skipVariantsResolver:c,skipSx:p,overridesResolver:y=gw(Fc(f)),...g}=l,m=c!==void 0?c:f&&f!=="Root"&&f!=="root"||!1,T=p||!1;let j=ta;f==="Root"||f==="root"?j=n:f?j=i:_w(s)&&(j=void 0);const F=uw(s,{shouldForwardProp:j,label:xw(u,f),...g}),D=E=>{if(typeof E=="function"&&E.__emotion_real!==E)return function(Y){return Zn(Y,E)};if(xt(E)){const M=Rc(E);return M.variants?function(ce){return Zn(ce,M)}:M.style}return E},O=(...E)=>{const M=[],Y=E.map(D),ce=[];if(M.push(o),u&&y&&ce.push(function(U){var G,oe;const te=(oe=(G=U.theme.components)==null?void 0:G[u])==null?void 0:oe.styleOverrides;if(!te)return null;const ve={};for(const le in te)ve[le]=Zn(U,te[le]);return y(U,ve)}),u&&!m&&ce.push(function(U){var ve,G;const H=U.theme,te=(G=(ve=H==null?void 0:H.components)==null?void 0:ve[u])==null?void 0:G.variants;return te?Nc(U,te):null}),T||ce.push(ur),Array.isArray(Y[0])){const A=Y.shift(),U=new Array(M.length).fill(""),H=new Array(ce.length).fill("");let te;te=[...U,...A,...H],te.raw=[...U,...A.raw,...H],M.unshift(te)}const ie=[...M,...Y,...ce],h=F(...ie);return s.muiName&&(h.muiName=s.muiName),process.env.NODE_ENV!=="production"&&(h.displayName=bw(u,f,s)),h};return F.withConfig&&(O.withConfig=F.withConfig),O}}function bw(e,t,r){return e?`${e}${Gt(t||"")}`:`Styled(${US(r)})`}function xw(e,t){let r;return process.env.NODE_ENV!=="production"&&e&&(r=`${e}-${Fc(t||"Root")}`),r}function Tw(e){for(const t in e)return!1;return!0}function _w(e){return typeof e=="string"&&e.charCodeAt(0)>96}function Fc(e){return e&&e.charAt(0).toLowerCase()+e.slice(1)}function ra(e,t=0,r=1){return process.env.NODE_ENV!=="production"&&(e<t||e>r)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${r}].`),YS(e,t,r)}function Ew(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let r=e.match(t);return r&&r[0].length===1&&(r=r.map(n=>n+n)),r?`rgb${r.length===4?"a":""}(${r.map((n,i)=>i<3?parseInt(n,16):Math.round(parseInt(n,16)/255*1e3)/1e3).join(", ")})`:""}function Dt(e){if(e.type)return e;if(e.charAt(0)==="#")return Dt(Ew(e));const t=e.indexOf("("),r=e.substring(0,t);if(!["rgb","rgba","hsl","hsla","color"].includes(r))throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color.
|
|
167
167
|
The following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().`:It(9,e));let n=e.substring(t+1,e.length-1),i;if(r==="color"){if(n=n.split(" "),i=n.shift(),n.length===4&&n[3].charAt(0)==="/"&&(n[3]=n[3].slice(1)),!["srgb","display-p3","a98-rgb","prophoto-rgb","rec-2020"].includes(i))throw new Error(process.env.NODE_ENV!=="production"?`MUI: unsupported \`${i}\` color space.
|
|
168
|
-
The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:It(10,i))}else n=n.split(",");return n=n.map(o=>parseFloat(o)),{type:r,values:n,colorSpace:i}}const Sw=e=>{const t=Dt(e);return t.values.slice(0,3).map((r,n)=>t.type.includes("hsl")&&n!==0?`${r}%`:r).join(" ")},Lr=(e,t)=>{try{return Sw(e)}catch{return t&&process.env.NODE_ENV!=="production"&&console.warn(t),e}};function Qn(e){const{type:t,colorSpace:r}=e;let{values:n}=e;return t.includes("rgb")?n=n.map((i,o)=>o<3?parseInt(i,10):i):t.includes("hsl")&&(n[1]=`${n[1]}%`,n[2]=`${n[2]}%`),t.includes("color")?n=`${r} ${n.join(" ")}`:n=`${n.join(", ")}`,`${t}(${n})`}function Lc(e){e=Dt(e);const{values:t}=e,r=t[0],n=t[1]/100,i=t[2]/100,o=n*Math.min(i,1-i),a=(u,f=(u+r/30)%12)=>i-o*Math.max(Math.min(f-3,9-f,1),-1);let s="rgb";const l=[Math.round(a(0)*255),Math.round(a(8)*255),Math.round(a(4)*255)];return e.type==="hsla"&&(s+="a",l.push(t[3])),Qn({type:s,values:l})}function na(e){e=Dt(e);let t=e.type==="hsl"||e.type==="hsla"?Dt(Lc(e)).values:e.values;return t=t.map(r=>(e.type!=="color"&&(r/=255),r<=.03928?r/12.92:((r+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function zc(e,t){const r=na(e),n=na(t);return(Math.max(r,n)+.05)/(Math.min(r,n)+.05)}function
|
|
169
|
-
`))}return T}const p=({color:
|
|
170
|
-
The color object needs to have a \`main\` property or a \`${j}\` property.`:It(11,T?` (${T})`:"",j));if(typeof
|
|
171
|
-
\`color.main\` should be a string, but \`${JSON.stringify(
|
|
168
|
+
The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:It(10,i))}else n=n.split(",");return n=n.map(o=>parseFloat(o)),{type:r,values:n,colorSpace:i}}const Sw=e=>{const t=Dt(e);return t.values.slice(0,3).map((r,n)=>t.type.includes("hsl")&&n!==0?`${r}%`:r).join(" ")},Lr=(e,t)=>{try{return Sw(e)}catch{return t&&process.env.NODE_ENV!=="production"&&console.warn(t),e}};function Qn(e){const{type:t,colorSpace:r}=e;let{values:n}=e;return t.includes("rgb")?n=n.map((i,o)=>o<3?parseInt(i,10):i):t.includes("hsl")&&(n[1]=`${n[1]}%`,n[2]=`${n[2]}%`),t.includes("color")?n=`${r} ${n.join(" ")}`:n=`${n.join(", ")}`,`${t}(${n})`}function Lc(e){e=Dt(e);const{values:t}=e,r=t[0],n=t[1]/100,i=t[2]/100,o=n*Math.min(i,1-i),a=(u,f=(u+r/30)%12)=>i-o*Math.max(Math.min(f-3,9-f,1),-1);let s="rgb";const l=[Math.round(a(0)*255),Math.round(a(8)*255),Math.round(a(4)*255)];return e.type==="hsla"&&(s+="a",l.push(t[3])),Qn({type:s,values:l})}function na(e){e=Dt(e);let t=e.type==="hsl"||e.type==="hsla"?Dt(Lc(e)).values:e.values;return t=t.map(r=>(e.type!=="color"&&(r/=255),r<=.03928?r/12.92:((r+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function zc(e,t){const r=na(e),n=na(t);return(Math.max(r,n)+.05)/(Math.min(r,n)+.05)}function Cw(e,t){return e=Dt(e),t=ra(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,Qn(e)}function ei(e,t,r){try{return Cw(e,t)}catch{return e}}function ia(e,t){if(e=Dt(e),t=ra(t),e.type.includes("hsl"))e.values[2]*=1-t;else if(e.type.includes("rgb")||e.type.includes("color"))for(let r=0;r<3;r+=1)e.values[r]*=1-t;return Qn(e)}function xe(e,t,r){try{return ia(e,t)}catch{return e}}function oa(e,t){if(e=Dt(e),t=ra(t),e.type.includes("hsl"))e.values[2]+=(100-e.values[2])*t;else if(e.type.includes("rgb"))for(let r=0;r<3;r+=1)e.values[r]+=(255-e.values[r])*t;else if(e.type.includes("color"))for(let r=0;r<3;r+=1)e.values[r]+=(1-e.values[r])*t;return Qn(e)}function Te(e,t,r){try{return oa(e,t)}catch{return e}}function ww(e,t=.15){return na(e)>.5?ia(e,t):oa(e,t)}function ti(e,t,r){try{return ww(e,t)}catch{return e}}const Aw=Je.createContext(void 0);process.env.NODE_ENV!=="production"&&(de.node,de.object);function Ow(e){const{theme:t,name:r,props:n}=e;if(!t||!t.components||!t.components[r])return n;const i=t.components[r];return i.defaultProps?qo(i.defaultProps,n):!i.styleOverrides&&!i.variants?qo(i,n):n}function kw({props:e,name:t}){const r=Je.useContext(Aw);return Ow({props:e,name:t,theme:{components:r}})}const Bc={theme:void 0};function Pw(e){let t,r;return function(i){let o=t;return(o===void 0||i.theme!==r)&&(Bc.theme=i.theme,o=Rc(e(Bc)),t=o,r=i.theme),o}}function jw(e=""){function t(...n){if(!n.length)return"";const i=n[0];return typeof i=="string"&&!i.match(/(#|\(|\)|(-?(\d*\.)?\d+)(px|em|%|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc))|^(-?(\d*\.)?\d+)$|(\d+ \d+ \d+)/)?`, var(--${e?`${e}-`:""}${i}${t(...n.slice(1))})`:`, ${i}`}return(n,...i)=>`var(--${e?`${e}-`:""}${n}${t(...i)})`}const Uc=(e,t,r,n=[])=>{let i=e;t.forEach((o,a)=>{a===t.length-1?Array.isArray(i)?i[Number(o)]=r:i&&typeof i=="object"&&(i[o]=r):i&&typeof i=="object"&&(i[o]||(i[o]=n.includes(o)?[]:{}),i=i[o])})},Iw=(e,t,r)=>{function n(i,o=[],a=[]){Object.entries(i).forEach(([s,l])=>{(!r||r&&!r([...o,s]))&&l!=null&&(typeof l=="object"&&Object.keys(l).length>0?n(l,[...o,s],Array.isArray(l)?[...a,s]:a):t([...o,s],l,a))})}n(e)},$w=(e,t)=>typeof t=="number"?["lineHeight","fontWeight","opacity","zIndex"].some(n=>e.includes(n))||e[e.length-1].toLowerCase().includes("opacity")?t:`${t}px`:t;function aa(e,t){const{prefix:r,shouldSkipGeneratingVar:n}=t||{},i={},o={},a={};return Iw(e,(s,l,u)=>{if((typeof l=="string"||typeof l=="number")&&(!n||!n(s,l))){const f=`--${r?`${r}-`:""}${s.join("-")}`,c=$w(s,l);Object.assign(i,{[f]:c}),Uc(o,s,`var(${f})`,u),Uc(a,s,`var(${f}, ${c})`,u)}},s=>s[0]==="vars"),{css:i,vars:o,varsWithDefaults:a}}function Dw(e,t={}){const{getSelector:r=T,disableCssColorScheme:n,colorSchemeSelector:i}=t,{colorSchemes:o={},components:a,defaultColorScheme:s="light",...l}=e,{vars:u,css:f,varsWithDefaults:c}=aa(l,t);let p=c;const y={},{[s]:g,...m}=o;if(Object.entries(m||{}).forEach(([D,O])=>{const{vars:E,css:M,varsWithDefaults:Y}=aa(O,t);p=et(p,Y),y[D]={css:M,vars:E}}),g){const{css:D,vars:O,varsWithDefaults:E}=aa(g,t);p=et(p,E),y[s]={css:D,vars:O}}function T(D,O){var M,Y;let E=i;if(i==="class"&&(E=".%s"),i==="data"&&(E="[data-%s]"),i!=null&&i.startsWith("data-")&&!i.includes("%s")&&(E=`[${i}="%s"]`),D){if(E==="media")return e.defaultColorScheme===D?":root":{[`@media (prefers-color-scheme: ${((Y=(M=o[D])==null?void 0:M.palette)==null?void 0:Y.mode)||D})`]:{":root":O}};if(E)return e.defaultColorScheme===D?`:root, ${E.replace("%s",String(D))}`:E.replace("%s",String(D))}return":root"}return{vars:p,generateThemeVars:()=>{let D={...u};return Object.entries(y).forEach(([,{vars:O}])=>{D=et(D,O)}),D},generateStyleSheets:()=>{var ce,ie;const D=[],O=e.defaultColorScheme||"light";function E(h,A){Object.keys(A).length&&D.push(typeof h=="string"?{[h]:{...A}}:h)}E(r(void 0,{...f}),f);const{[O]:M,...Y}=y;if(M){const{css:h}=M,A=(ie=(ce=o[O])==null?void 0:ce.palette)==null?void 0:ie.mode,U=!n&&A?{colorScheme:A,...h}:{...h};E(r(O,{...U}),U)}return Object.entries(Y).forEach(([h,{css:A}])=>{var te,ve;const U=(ve=(te=o[h])==null?void 0:te.palette)==null?void 0:ve.mode,H=!n&&U?{colorScheme:U,...A}:{...A};E(r(h,{...H}),H)}),D}}}function Mw(e){return function(r){return e==="media"?(process.env.NODE_ENV!=="production"&&r!=="light"&&r!=="dark"&&console.error(`MUI: @media (prefers-color-scheme) supports only 'light' or 'dark', but receive '${r}'.`),`@media (prefers-color-scheme: ${r})`):e?e.startsWith("data-")&&!e.includes("%s")?`[${e}="${r}"] &`:e==="class"?`.${r} &`:e==="data"?`[data-${r}] &`:`${e.replace("%s",r)} &`:"&"}}const zr={black:"#000",white:"#fff"},Rw={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},cr={50:"#f3e5f5",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"},fr={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"},Br={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"},dr={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"},pr={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"},hr={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"};function Vc(){return{text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:zr.white,default:zr.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}}}const Nw=Vc();function Wc(){return{text:{primary:zr.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:zr.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}}}const Hc=Wc();function Gc(e,t,r,n){const i=n.light||n,o=n.dark||n*1.5;e[t]||(e.hasOwnProperty(r)?e[t]=e[r]:t==="light"?e.light=oa(e.main,i):t==="dark"&&(e.dark=ia(e.main,o)))}function Fw(e="light"){return e==="dark"?{main:dr[200],light:dr[50],dark:dr[400]}:{main:dr[700],light:dr[400],dark:dr[800]}}function Lw(e="light"){return e==="dark"?{main:cr[200],light:cr[50],dark:cr[400]}:{main:cr[500],light:cr[300],dark:cr[700]}}function zw(e="light"){return e==="dark"?{main:fr[500],light:fr[300],dark:fr[700]}:{main:fr[700],light:fr[400],dark:fr[800]}}function Bw(e="light"){return e==="dark"?{main:pr[400],light:pr[300],dark:pr[700]}:{main:pr[700],light:pr[500],dark:pr[900]}}function Uw(e="light"){return e==="dark"?{main:hr[400],light:hr[300],dark:hr[700]}:{main:hr[800],light:hr[500],dark:hr[900]}}function Vw(e="light"){return e==="dark"?{main:Br[400],light:Br[300],dark:Br[700]}:{main:"#ed6c02",light:Br[500],dark:Br[900]}}function sa(e){const{mode:t="light",contrastThreshold:r=3,tonalOffset:n=.2,...i}=e,o=e.primary||Fw(t),a=e.secondary||Lw(t),s=e.error||zw(t),l=e.info||Bw(t),u=e.success||Uw(t),f=e.warning||Vw(t);function c(m){const T=zc(m,Hc.text.primary)>=r?Hc.text.primary:Nw.text.primary;if(process.env.NODE_ENV!=="production"){const j=zc(m,T);j<3&&console.error([`MUI: The contrast ratio of ${j}:1 for ${T} on ${m}`,"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(`
|
|
169
|
+
`))}return T}const p=({color:m,name:T,mainShade:j=500,lightShade:F=300,darkShade:D=700})=>{if(m={...m},!m.main&&m[j]&&(m.main=m[j]),!m.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${T?` (${T})`:""} provided to augmentColor(color) is invalid.
|
|
170
|
+
The color object needs to have a \`main\` property or a \`${j}\` property.`:It(11,T?` (${T})`:"",j));if(typeof m.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${T?` (${T})`:""} provided to augmentColor(color) is invalid.
|
|
171
|
+
\`color.main\` should be a string, but \`${JSON.stringify(m.main)}\` was provided instead.
|
|
172
172
|
|
|
173
173
|
Did you intend to use one of the following approaches?
|
|
174
174
|
|
|
@@ -180,15 +180,15 @@ const theme1 = createTheme({ palette: {
|
|
|
180
180
|
|
|
181
181
|
const theme2 = createTheme({ palette: {
|
|
182
182
|
primary: { main: green[500] },
|
|
183
|
-
} });`:It(12,T?` (${T})`:"",JSON.stringify(
|
|
184
|
-
`)),Object.keys(u).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(u).join(",")}].`)}return(Array.isArray(i)?i:[i]).map(f=>`${f} ${typeof a=="string"?a:Kc(a)} ${s} ${typeof l=="string"?l:Kc(l)}`).join(",")},...e,easing:t,duration:r}}const
|
|
185
|
-
`))}y[j]={}}}};Object.keys(p.components).forEach(y=>{const T=p.components[y].styleOverrides;T&&y.startsWith("Mui")&&m(T,y)})}return p.unstable_sxConfig={...Jn,...u==null?void 0:u.unstable_sxConfig},p.unstable_sx=function(m){return ur({sx:m,theme:this})},p}function rA(e){let t;return e<1?t=5.11916*e**2:t=4.5*Math.log(e+1)+2,Math.round(t*10)/1e3}const nA=[...Array(25)].map((e,t)=>{if(t===0)return"none";const r=rA(t);return`linear-gradient(rgba(255 255 255 / ${r}), rgba(255 255 255 / ${r}))`});function Xc(e){return{inputPlaceholder:e==="dark"?.5:.42,inputUnderline:e==="dark"?.7:.42,switchTrackDisabled:e==="dark"?.2:.12,switchTrack:e==="dark"?.3:.38}}function Jc(e){return e==="dark"?nA:[]}function iA(e){const{palette:t={mode:"light"},opacity:r,overlays:n,...i}=e,o=sa(t);return{palette:o,opacity:{...Xc(o.mode),...r},overlays:n||Jc(o.mode),...i}}function oA(e){var t;return!!e[0].match(/(cssVarPrefix|colorSchemeSelector|rootSelector|typography|mixins|breakpoints|direction|transitions)/)||!!e[0].match(/sxConfig$/)||e[0]==="palette"&&!!((t=e[1])!=null&&t.match(/(mode|contrastThreshold|tonalOffset)/))}const aA=e=>[...[...Array(25)].map((t,r)=>`--${e?`${e}-`:""}overlays-${r}`),`--${e?`${e}-`:""}palette-AppBar-darkBg`,`--${e?`${e}-`:""}palette-AppBar-darkColor`],sA=e=>(t,r)=>{const n=e.rootSelector||":root",i=e.colorSchemeSelector;let o=i;if(i==="class"&&(o=".%s"),i==="data"&&(o="[data-%s]"),i!=null&&i.startsWith("data-")&&!i.includes("%s")&&(o=`[${i}="%s"]`),e.defaultColorScheme===t){if(t==="dark"){const a={};return aA(e.cssVarPrefix).forEach(s=>{a[s]=r[s],delete r[s]}),o==="media"?{[n]:r,"@media (prefers-color-scheme: dark)":{[n]:a}}:o?{[o.replace("%s",t)]:a,[`${n}, ${o.replace("%s",t)}`]:r}:{[n]:{...r,...a}}}if(o&&o!=="media")return`${n}, ${o.replace("%s",String(t))}`}else if(t){if(o==="media")return{[`@media (prefers-color-scheme: ${String(t)})`]:{[n]:r}};if(o)return o.replace("%s",String(t))}return n};function lA(e){return xt(e)||typeof e>"u"||typeof e=="string"||typeof e=="boolean"||typeof e=="number"||Array.isArray(e)}function uA(e={}){const t={...e};function r(n){const i=Object.entries(n);for(let o=0;o<i.length;o++){const[a,s]=i[o];!lA(s)||a.startsWith("unstable_")?delete n[a]:xt(s)&&(n[a]={...s},r(n[a]))}}return r(t),`import { unstable_createBreakpoints as createBreakpoints, createTransitions } from '@mui/material/styles';
|
|
183
|
+
} });`:It(12,T?` (${T})`:"",JSON.stringify(m.main)));return Gc(m,"light",F,n),Gc(m,"dark",D,n),m.contrastText||(m.contrastText=c(m.main)),m};let y;return t==="light"?y=Vc():t==="dark"&&(y=Wc()),process.env.NODE_ENV!=="production"&&(y||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),et({common:{...zr},mode:t,primary:p({color:o,name:"primary"}),secondary:p({color:a,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:p({color:s,name:"error"}),warning:p({color:f,name:"warning"}),info:p({color:l,name:"info"}),success:p({color:u,name:"success"}),grey:Rw,contrastThreshold:r,getContrastText:c,augmentColor:p,tonalOffset:n,...y},i)}function Ww(e){const t={};return Object.entries(e).forEach(n=>{const[i,o]=n;typeof o=="object"&&(t[i]=`${o.fontStyle?`${o.fontStyle} `:""}${o.fontVariant?`${o.fontVariant} `:""}${o.fontWeight?`${o.fontWeight} `:""}${o.fontStretch?`${o.fontStretch} `:""}${o.fontSize||""}${o.lineHeight?`/${o.lineHeight} `:""}${o.fontFamily||""}`)}),t}function Hw(e,t){return{toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}},...t}}function Gw(e){return Math.round(e*1e5)/1e5}const Yc={textTransform:"uppercase"},qc='"Roboto", "Helvetica", "Arial", sans-serif';function Yw(e,t){const{fontFamily:r=qc,fontSize:n=14,fontWeightLight:i=300,fontWeightRegular:o=400,fontWeightMedium:a=500,fontWeightBold:s=700,htmlFontSize:l=16,allVariants:u,pxToRem:f,...c}=typeof t=="function"?t(e):t;process.env.NODE_ENV!=="production"&&(typeof n!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof l!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const p=n/14,y=f||(T=>`${T/l*p}rem`),g=(T,j,F,D,O)=>({fontFamily:r,fontWeight:T,fontSize:y(j),lineHeight:F,...r===qc?{letterSpacing:`${Gw(D/j)}em`}:{},...O,...u}),m={h1:g(i,96,1.167,-1.5),h2:g(i,60,1.2,-.5),h3:g(o,48,1.167,0),h4:g(o,34,1.235,.25),h5:g(o,24,1.334,0),h6:g(a,20,1.6,.15),subtitle1:g(o,16,1.75,.15),subtitle2:g(a,14,1.57,.1),body1:g(o,16,1.5,.15),body2:g(o,14,1.43,.15),button:g(a,14,1.75,.4,Yc),caption:g(o,12,1.66,.4),overline:g(o,12,2.66,1,Yc),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return et({htmlFontSize:l,pxToRem:y,fontFamily:r,fontSize:n,fontWeightLight:i,fontWeightRegular:o,fontWeightMedium:a,fontWeightBold:s,...m},c,{clone:!1})}const qw=.2,Kw=.14,Xw=.12;function we(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${qw})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${Kw})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${Xw})`].join(",")}const Jw=["none",we(0,2,1,-1,0,1,1,0,0,1,3,0),we(0,3,1,-2,0,2,2,0,0,1,5,0),we(0,3,3,-2,0,3,4,0,0,1,8,0),we(0,2,4,-1,0,4,5,0,0,1,10,0),we(0,3,5,-1,0,5,8,0,0,1,14,0),we(0,3,5,-1,0,6,10,0,0,1,18,0),we(0,4,5,-2,0,7,10,1,0,2,16,1),we(0,5,5,-3,0,8,10,1,0,3,14,2),we(0,5,6,-3,0,9,12,1,0,3,16,2),we(0,6,6,-3,0,10,14,1,0,4,18,3),we(0,6,7,-4,0,11,15,1,0,4,20,3),we(0,7,8,-4,0,12,17,2,0,5,22,4),we(0,7,8,-4,0,13,19,2,0,5,24,4),we(0,7,9,-4,0,14,21,2,0,5,26,4),we(0,8,9,-5,0,15,22,2,0,6,28,5),we(0,8,10,-5,0,16,24,2,0,6,30,5),we(0,8,11,-5,0,17,26,2,0,6,32,5),we(0,9,11,-5,0,18,28,2,0,7,34,6),we(0,9,12,-6,0,19,29,2,0,7,36,6),we(0,10,13,-6,0,20,31,3,0,8,38,7),we(0,10,13,-6,0,21,33,3,0,8,40,7),we(0,10,14,-6,0,22,35,3,0,8,42,7),we(0,11,14,-7,0,23,36,3,0,9,44,8),we(0,11,15,-7,0,24,38,3,0,9,46,8)],Zw={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)"},Qw={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Kc(e){return`${Math.round(e)}ms`}function eA(e){if(!e)return 0;const t=e/36;return Math.min(Math.round((4+15*t**.25+t/5)*10),3e3)}function tA(e){const t={...Zw,...e.easing},r={...Qw,...e.duration};return{getAutoHeightDuration:eA,create:(i=["all"],o={})=>{const{duration:a=r.standard,easing:s=t.easeInOut,delay:l=0,...u}=o;if(process.env.NODE_ENV!=="production"){const f=p=>typeof p=="string",c=p=>!Number.isNaN(parseFloat(p));!f(i)&&!Array.isArray(i)&&console.error('MUI: Argument "props" must be a string or Array.'),!c(a)&&!f(a)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${a}.`),f(s)||console.error('MUI: Argument "easing" must be a string.'),!c(l)&&!f(l)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof o!="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(`
|
|
184
|
+
`)),Object.keys(u).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(u).join(",")}].`)}return(Array.isArray(i)?i:[i]).map(f=>`${f} ${typeof a=="string"?a:Kc(a)} ${s} ${typeof l=="string"?l:Kc(l)}`).join(",")},...e,easing:t,duration:r}}const rA={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500};function nA(e){return xt(e)||typeof e>"u"||typeof e=="string"||typeof e=="boolean"||typeof e=="number"||Array.isArray(e)}function Xc(e={}){const t={...e};function r(n){const i=Object.entries(n);for(let o=0;o<i.length;o++){const[a,s]=i[o];!nA(s)||a.startsWith("unstable_")?delete n[a]:xt(s)&&(n[a]={...s},r(n[a]))}}return r(t),`import { unstable_createBreakpoints as createBreakpoints, createTransitions } from '@mui/material/styles';
|
|
186
185
|
|
|
187
186
|
const theme = ${JSON.stringify(t,null,2)};
|
|
188
187
|
|
|
189
188
|
theme.breakpoints = createBreakpoints(theme.breakpoints || {});
|
|
190
189
|
theme.transitions = createTransitions(theme.transitions || {});
|
|
191
190
|
|
|
192
|
-
export default theme;`}function
|
|
193
|
-
To suppress this warning, you need to explicitly provide the \`palette.${t}Channel\` as a string (in rgb format, for example "12 12 12") or undefined if you want to remove the channel token.`))}function fA(e){return typeof e=="number"?`${e}px`:typeof e=="string"||typeof e=="function"||Array.isArray(e)?e:"8px"}const mt=e=>{try{return e()}catch{}},dA=(e="mui")=>Pw(e);function ua(e,t,r,n){if(!t)return;t=t===!0?{}:t;const i=n==="dark"?"dark":"light";if(!r){e[n]=iA({...t,palette:{mode:i,...t==null?void 0:t.palette}});return}const{palette:o,...a}=la({...r,palette:{mode:i,...t==null?void 0:t.palette}});return e[n]={...t,palette:o,opacity:{...Xc(i),...t==null?void 0:t.opacity},overlays:(t==null?void 0:t.overlays)||Jc(i)},a}function pA(e={},...t){const{colorSchemes:r={light:!0},defaultColorScheme:n,disableCssColorScheme:i=!1,cssVarPrefix:o="mui",shouldSkipGeneratingVar:a=oA,colorSchemeSelector:s=r.light&&r.dark?"media":void 0,rootSelector:l=":root",...u}=e,f=Object.keys(r)[0],c=n||(r.light&&f!=="light"?"light":f),p=dA(o),{[c]:v,light:m,dark:y,...T}=r,j={...T};let F=v;if((c==="dark"&&!("dark"in r)||c==="light"&&!("light"in r))&&(F=!0),!F)throw new Error(process.env.NODE_ENV!=="production"?`MUI: The \`colorSchemes.${c}\` option is either missing or invalid.`:It(21,c));const D=ua(j,F,u,c);m&&!j.light&&ua(j,m,void 0,"light"),y&&!j.dark&&ua(j,y,void 0,"dark");let O={defaultColorScheme:c,...D,cssVarPrefix:o,colorSchemeSelector:s,rootSelector:l,getCssVar:p,colorSchemes:j,font:{...Vw(D.typography),...D.font},spacing:fA(u.spacing)};Object.keys(O.colorSchemes).forEach(ie=>{const h=O.colorSchemes[ie].palette,A=U=>{const H=U.split("-"),te=H[1],ve=H[2];return p(U,h[te][ve])};if(h.mode==="light"&&(E(h.common,"background","#fff"),E(h.common,"onBackground","#000")),h.mode==="dark"&&(E(h.common,"background","#000"),E(h.common,"onBackground","#fff")),cA(h,["Alert","AppBar","Avatar","Button","Chip","FilledInput","LinearProgress","Skeleton","Slider","SnackbarContent","SpeedDialAction","StepConnector","StepContent","Switch","TableCell","Tooltip"]),h.mode==="light"){E(h.Alert,"errorColor",xe(h.error.light,.6)),E(h.Alert,"infoColor",xe(h.info.light,.6)),E(h.Alert,"successColor",xe(h.success.light,.6)),E(h.Alert,"warningColor",xe(h.warning.light,.6)),E(h.Alert,"errorFilledBg",A("palette-error-main")),E(h.Alert,"infoFilledBg",A("palette-info-main")),E(h.Alert,"successFilledBg",A("palette-success-main")),E(h.Alert,"warningFilledBg",A("palette-warning-main")),E(h.Alert,"errorFilledColor",mt(()=>h.getContrastText(h.error.main))),E(h.Alert,"infoFilledColor",mt(()=>h.getContrastText(h.info.main))),E(h.Alert,"successFilledColor",mt(()=>h.getContrastText(h.success.main))),E(h.Alert,"warningFilledColor",mt(()=>h.getContrastText(h.warning.main))),E(h.Alert,"errorStandardBg",Te(h.error.light,.9)),E(h.Alert,"infoStandardBg",Te(h.info.light,.9)),E(h.Alert,"successStandardBg",Te(h.success.light,.9)),E(h.Alert,"warningStandardBg",Te(h.warning.light,.9)),E(h.Alert,"errorIconColor",A("palette-error-main")),E(h.Alert,"infoIconColor",A("palette-info-main")),E(h.Alert,"successIconColor",A("palette-success-main")),E(h.Alert,"warningIconColor",A("palette-warning-main")),E(h.AppBar,"defaultBg",A("palette-grey-100")),E(h.Avatar,"defaultBg",A("palette-grey-400")),E(h.Button,"inheritContainedBg",A("palette-grey-300")),E(h.Button,"inheritContainedHoverBg",A("palette-grey-A100")),E(h.Chip,"defaultBorder",A("palette-grey-400")),E(h.Chip,"defaultAvatarColor",A("palette-grey-700")),E(h.Chip,"defaultIconColor",A("palette-grey-700")),E(h.FilledInput,"bg","rgba(0, 0, 0, 0.06)"),E(h.FilledInput,"hoverBg","rgba(0, 0, 0, 0.09)"),E(h.FilledInput,"disabledBg","rgba(0, 0, 0, 0.12)"),E(h.LinearProgress,"primaryBg",Te(h.primary.main,.62)),E(h.LinearProgress,"secondaryBg",Te(h.secondary.main,.62)),E(h.LinearProgress,"errorBg",Te(h.error.main,.62)),E(h.LinearProgress,"infoBg",Te(h.info.main,.62)),E(h.LinearProgress,"successBg",Te(h.success.main,.62)),E(h.LinearProgress,"warningBg",Te(h.warning.main,.62)),E(h.Skeleton,"bg",`rgba(${A("palette-text-primaryChannel")} / 0.11)`),E(h.Slider,"primaryTrack",Te(h.primary.main,.62)),E(h.Slider,"secondaryTrack",Te(h.secondary.main,.62)),E(h.Slider,"errorTrack",Te(h.error.main,.62)),E(h.Slider,"infoTrack",Te(h.info.main,.62)),E(h.Slider,"successTrack",Te(h.success.main,.62)),E(h.Slider,"warningTrack",Te(h.warning.main,.62));const U=ti(h.background.default,.8);E(h.SnackbarContent,"bg",U),E(h.SnackbarContent,"color",mt(()=>h.getContrastText(U))),E(h.SpeedDialAction,"fabHoverBg",ti(h.background.paper,.15)),E(h.StepConnector,"border",A("palette-grey-400")),E(h.StepContent,"border",A("palette-grey-400")),E(h.Switch,"defaultColor",A("palette-common-white")),E(h.Switch,"defaultDisabledColor",A("palette-grey-100")),E(h.Switch,"primaryDisabledColor",Te(h.primary.main,.62)),E(h.Switch,"secondaryDisabledColor",Te(h.secondary.main,.62)),E(h.Switch,"errorDisabledColor",Te(h.error.main,.62)),E(h.Switch,"infoDisabledColor",Te(h.info.main,.62)),E(h.Switch,"successDisabledColor",Te(h.success.main,.62)),E(h.Switch,"warningDisabledColor",Te(h.warning.main,.62)),E(h.TableCell,"border",Te(ei(h.divider,1),.88)),E(h.Tooltip,"bg",ei(h.grey[700],.92))}if(h.mode==="dark"){E(h.Alert,"errorColor",Te(h.error.light,.6)),E(h.Alert,"infoColor",Te(h.info.light,.6)),E(h.Alert,"successColor",Te(h.success.light,.6)),E(h.Alert,"warningColor",Te(h.warning.light,.6)),E(h.Alert,"errorFilledBg",A("palette-error-dark")),E(h.Alert,"infoFilledBg",A("palette-info-dark")),E(h.Alert,"successFilledBg",A("palette-success-dark")),E(h.Alert,"warningFilledBg",A("palette-warning-dark")),E(h.Alert,"errorFilledColor",mt(()=>h.getContrastText(h.error.dark))),E(h.Alert,"infoFilledColor",mt(()=>h.getContrastText(h.info.dark))),E(h.Alert,"successFilledColor",mt(()=>h.getContrastText(h.success.dark))),E(h.Alert,"warningFilledColor",mt(()=>h.getContrastText(h.warning.dark))),E(h.Alert,"errorStandardBg",xe(h.error.light,.9)),E(h.Alert,"infoStandardBg",xe(h.info.light,.9)),E(h.Alert,"successStandardBg",xe(h.success.light,.9)),E(h.Alert,"warningStandardBg",xe(h.warning.light,.9)),E(h.Alert,"errorIconColor",A("palette-error-main")),E(h.Alert,"infoIconColor",A("palette-info-main")),E(h.Alert,"successIconColor",A("palette-success-main")),E(h.Alert,"warningIconColor",A("palette-warning-main")),E(h.AppBar,"defaultBg",A("palette-grey-900")),E(h.AppBar,"darkBg",A("palette-background-paper")),E(h.AppBar,"darkColor",A("palette-text-primary")),E(h.Avatar,"defaultBg",A("palette-grey-600")),E(h.Button,"inheritContainedBg",A("palette-grey-800")),E(h.Button,"inheritContainedHoverBg",A("palette-grey-700")),E(h.Chip,"defaultBorder",A("palette-grey-700")),E(h.Chip,"defaultAvatarColor",A("palette-grey-300")),E(h.Chip,"defaultIconColor",A("palette-grey-300")),E(h.FilledInput,"bg","rgba(255, 255, 255, 0.09)"),E(h.FilledInput,"hoverBg","rgba(255, 255, 255, 0.13)"),E(h.FilledInput,"disabledBg","rgba(255, 255, 255, 0.12)"),E(h.LinearProgress,"primaryBg",xe(h.primary.main,.5)),E(h.LinearProgress,"secondaryBg",xe(h.secondary.main,.5)),E(h.LinearProgress,"errorBg",xe(h.error.main,.5)),E(h.LinearProgress,"infoBg",xe(h.info.main,.5)),E(h.LinearProgress,"successBg",xe(h.success.main,.5)),E(h.LinearProgress,"warningBg",xe(h.warning.main,.5)),E(h.Skeleton,"bg",`rgba(${A("palette-text-primaryChannel")} / 0.13)`),E(h.Slider,"primaryTrack",xe(h.primary.main,.5)),E(h.Slider,"secondaryTrack",xe(h.secondary.main,.5)),E(h.Slider,"errorTrack",xe(h.error.main,.5)),E(h.Slider,"infoTrack",xe(h.info.main,.5)),E(h.Slider,"successTrack",xe(h.success.main,.5)),E(h.Slider,"warningTrack",xe(h.warning.main,.5));const U=ti(h.background.default,.98);E(h.SnackbarContent,"bg",U),E(h.SnackbarContent,"color",mt(()=>h.getContrastText(U))),E(h.SpeedDialAction,"fabHoverBg",ti(h.background.paper,.15)),E(h.StepConnector,"border",A("palette-grey-600")),E(h.StepContent,"border",A("palette-grey-600")),E(h.Switch,"defaultColor",A("palette-grey-300")),E(h.Switch,"defaultDisabledColor",A("palette-grey-600")),E(h.Switch,"primaryDisabledColor",xe(h.primary.main,.55)),E(h.Switch,"secondaryDisabledColor",xe(h.secondary.main,.55)),E(h.Switch,"errorDisabledColor",xe(h.error.main,.55)),E(h.Switch,"infoDisabledColor",xe(h.info.main,.55)),E(h.Switch,"successDisabledColor",xe(h.success.main,.55)),E(h.Switch,"warningDisabledColor",xe(h.warning.main,.55)),E(h.TableCell,"border",xe(ei(h.divider,1),.68)),E(h.Tooltip,"bg",ei(h.grey[700],.92))}_t(h.background,"default"),_t(h.background,"paper"),_t(h.common,"background"),_t(h.common,"onBackground"),_t(h,"divider"),Object.keys(h).forEach(U=>{const H=h[U];H&&typeof H=="object"&&(H.main&&E(h[U],"mainChannel",Lr(Ur(H.main))),H.light&&E(h[U],"lightChannel",Lr(Ur(H.light))),H.dark&&E(h[U],"darkChannel",Lr(Ur(H.dark))),H.contrastText&&E(h[U],"contrastTextChannel",Lr(Ur(H.contrastText))),U==="text"&&(_t(h[U],"primary"),_t(h[U],"secondary")),U==="action"&&(H.active&&_t(h[U],"active"),H.selected&&_t(h[U],"selected")))})}),O=t.reduce((ie,h)=>et(ie,h),O);const S={prefix:o,disableCssColorScheme:i,shouldSkipGeneratingVar:a,getSelector:sA(O)},{vars:M,generateThemeVars:Y,generateStyleSheets:ce}=$w(O,S);return O.vars=M,Object.entries(O.colorSchemes[O.defaultColorScheme]).forEach(([ie,h])=>{O[ie]=h}),O.generateThemeVars=Y,O.generateStyleSheets=ce,O.generateSpacing=function(){return Dc(u.spacing,Xo(this))},O.getColorSchemeSelector=Dw(s),O.spacing=O.generateSpacing(),O.shouldSkipGeneratingVar=a,O.unstable_sxConfig={...Jn,...u==null?void 0:u.unstable_sxConfig},O.unstable_sx=function(h){return ur({sx:h,theme:this})},O.toRuntimeSource=uA,O}function Zc(e,t,r){e.colorSchemes&&r&&(e.colorSchemes[t]={...r!==!0&&r,palette:sa({...r===!0?{}:r.palette,mode:t})})}function hA(e={},...t){const{palette:r,cssVariables:n=!1,colorSchemes:i=r?void 0:{light:!0},defaultColorScheme:o=r==null?void 0:r.mode,...a}=e,s=o||"light",l=i==null?void 0:i[s],u={...i,...r?{[s]:{...typeof l!="boolean"&&l,palette:r}}:void 0};if(n===!1){if(!("colorSchemes"in e))return la(e,...t);let f=r;"palette"in e||u[s]&&(u[s]!==!0?f=u[s].palette:s==="dark"&&(f={mode:"dark"}));const c=la({...e,palette:f},...t);return c.defaultColorScheme=s,c.colorSchemes=u,c.palette.mode==="light"&&(c.colorSchemes.light={...u.light!==!0&&u.light,palette:c.palette},Zc(c,"dark",u.dark)),c.palette.mode==="dark"&&(c.colorSchemes.dark={...u.dark!==!0&&u.dark,palette:c.palette},Zc(c,"light",u.light)),c}return!r&&!("light"in u)&&s==="light"&&(u.light=!0),pA({...a,colorSchemes:u,defaultColorScheme:s,...typeof n!="boolean"&&n},...t)}const mA=hA(),gA="$$material";function yA(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const vA=yw({themeId:gA,defaultTheme:mA,rootShouldForwardProp:e=>yA(e)&&e!=="classes"}),bA=kw;process.env.NODE_ENV!=="production"&&(de.node,de.object.isRequired);function xA(e){return Ow(e)}function TA(e){return Ko("MuiSvgIcon",e)}HE("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const _A=e=>{const{color:t,fontSize:r,classes:n}=e,i={root:["root",t!=="inherit"&&`color${Gt(t)}`,`fontSize${Gt(r)}`]};return UE(i,TA,n)},SA=vA("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,r.color!=="inherit"&&t[`color${Gt(r.color)}`],t[`fontSize${Gt(r.fontSize)}`]]}})(bA(({theme:e})=>{var t,r,n,i,o,a,s,l,u,f,c,p,v,m;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",flexShrink:0,transition:(i=(t=e.transitions)==null?void 0:t.create)==null?void 0:i.call(t,"fill",{duration:(n=(r=(e.vars??e).transitions)==null?void 0:r.duration)==null?void 0:n.shorter}),variants:[{props:y=>!y.hasSvgAsChild,style:{fill:"currentColor"}},{props:{fontSize:"inherit"},style:{fontSize:"inherit"}},{props:{fontSize:"small"},style:{fontSize:((a=(o=e.typography)==null?void 0:o.pxToRem)==null?void 0:a.call(o,20))||"1.25rem"}},{props:{fontSize:"medium"},style:{fontSize:((l=(s=e.typography)==null?void 0:s.pxToRem)==null?void 0:l.call(s,24))||"1.5rem"}},{props:{fontSize:"large"},style:{fontSize:((f=(u=e.typography)==null?void 0:u.pxToRem)==null?void 0:f.call(u,35))||"2.1875rem"}},...Object.entries((e.vars??e).palette).filter(([,y])=>y&&y.main).map(([y])=>{var T,j;return{props:{color:y},style:{color:(j=(T=(e.vars??e).palette)==null?void 0:T[y])==null?void 0:j.main}}}),{props:{color:"action"},style:{color:(p=(c=(e.vars??e).palette)==null?void 0:c.action)==null?void 0:p.active}},{props:{color:"disabled"},style:{color:(m=(v=(e.vars??e).palette)==null?void 0:v.action)==null?void 0:m.disabled}},{props:{color:"inherit"},style:{color:void 0}}]}})),Vr=Je.forwardRef(function(t,r){const n=xA({props:t,name:"MuiSvgIcon"}),{children:i,className:o,color:a="inherit",component:s="svg",fontSize:l="medium",htmlColor:u,inheritViewBox:f=!1,titleAccess:c,viewBox:p="0 0 24 24",...v}=n,m=Je.isValidElement(i)&&i.type==="svg",y={...n,color:a,component:s,fontSize:l,instanceFontSize:t.fontSize,inheritViewBox:f,viewBox:p,hasSvgAsChild:m},T={};f||(T.viewBox=p);const j=_A(y);return d.jsxs(SA,{as:s,className:YE(j.root,o),focusable:"false",color:u,"aria-hidden":c?void 0:!0,role:c?"img":void 0,ref:r,...T,...v,...m&&i.props,ownerState:y,children:[m?i.props.children:i,c?d.jsx("title",{children:c}):null]})});process.env.NODE_ENV!=="production"&&(Vr.propTypes={children:de.node,classes:de.object,className:de.string,color:de.oneOfType([de.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),de.string]),component:de.elementType,fontSize:de.oneOfType([de.oneOf(["inherit","large","medium","small"]),de.string]),htmlColor:de.string,inheritViewBox:de.bool,shapeRendering:de.string,sx:de.oneOfType([de.arrayOf(de.oneOfType([de.func,de.object,de.bool])),de.func,de.object]),titleAccess:de.string,viewBox:de.string}),Vr&&(Vr.muiName="SvgIcon");function ca(e,t){function r(n,i){return d.jsx(Vr,{"data-testid":`${t}Icon`,ref:i,...n,children:e})}return process.env.NODE_ENV!=="production"&&(r.displayName=`${t}Icon`),r.muiName=Vr.muiName,Je.memo(Je.forwardRef(r))}const EA=ca(d.jsx("path",{d:"m20 12-1.41-1.41L13 16.17V4h-2v12.17l-5.58-5.59L4 12l8 8z"}),"ArrowDownward"),CA=ca(d.jsx("path",{d:"m4 12 1.41 1.41L11 7.83V20h2V7.83l5.58 5.59L20 12l-8-8z"}),"ArrowUpward"),wA=ca(d.jsx("path",{d:"M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6zM19 4h-3.5l-1-1h-5l-1 1H5v2h14z"}),"Delete"),mr=({children:e,...t})=>d.jsx(b.Table.Td,{...t,children:e}),AA=({errorMessages:e,id:t})=>d.jsx(b.Tooltip,{id:t,title:e,children:d.jsx(b.Indicator,{label:e.split(`
|
|
194
|
-
`).length,children:d.jsx(qd,{})})}),OA={paddingLeft:0,paddingRight:0},kA=_.memo(function({numColumns:t,errors:r,label:n,description:i,path:o,addItem:a,schema:s,enabled:l,translations:u,rootSchema:f}){const c={bg:"transparent",size:"sm",c:"gray"},p=b.useProps("ActionIcon",c,{});return d.jsxs(b.Table.Tr,{children:[d.jsx(mr,{colSpan:t,children:d.jsxs(b.Stack,{children:[d.jsxs(b.Grid,{justify:"flex-start",align:"center",gutter:"sm",children:[d.jsx(b.Grid.Col,{span:"content",children:d.jsx(b.Text,{children:n})}),d.jsx(b.Grid.Col,{span:"content",children:r.length!==0?d.jsx(b.Grid.Col,{span:"content",children:d.jsx(AA,{id:"tooltip-validation",errorMessages:r})}):null})]}),i&&d.jsx(b.Text,{size:"sm",children:i})]})}),l?d.jsx(mr,{align:"right",style:OA,children:d.jsx(b.Tooltip,{id:"tooltip-add",title:u.addTooltip,position:"bottom",children:d.jsx(b.ActionIcon,{bg:p.bg,size:p.size,c:p.c,onClick:a(o,W.createDefaultValue(s,f)),children:d.jsx(Gi,{})})})}):null]})}),Qc={fixedCell:{width:"150px",height:"50px",paddingLeft:0,paddingRight:0,textAlign:"center"},fixedCellSmall:{width:"50px",height:"50px",paddingLeft:0,paddingRight:0,textAlign:"center"}},ef=(e,t,r,n,i)=>{if(t.type==="object")return tf(t).map(o=>{var l,u;const a=W.Paths.compose(r,o),s={propName:o,schema:t,title:((u=(l=t.properties)==null?void 0:l[o])==null?void 0:u.title)??pE(o),rowPath:r,cellPath:a,enabled:n,cells:i};return d.jsx(e,{...s},a)});{const o={schema:t,rowPath:r,cellPath:r,enabled:n};return d.jsx(e,{...o},r)}},tf=e=>e.type==="object"&&typeof e.properties=="object"?Object.keys(e.properties).filter(t=>e.properties[t].type!=="array"):[""],PA=({numColumns:e,translations:t})=>d.jsx(b.Table.Tr,{children:d.jsx(mr,{colSpan:e,children:d.jsx(b.Text,{align:"center",children:t.noDataMessage})})}),jA=_.memo(function({title:t}){return d.jsx(b.Table.Th,{children:t})}),IA=(e,t)=>{const r=t.rowPath+(t.schema.type==="object"?"."+t.propName:""),n=W.formatErrorMessage(t_(W.errorsAt(r,t.schema,i=>i===r)(e.core.errors).map(i=>i.message)));return{rowPath:t.rowPath,propName:t.propName,schema:t.schema,rootSchema:e.core.schema,errors:n,path:r,enabled:t.enabled,cells:t.cells||e.cells,renderers:t.renderers||e.renderers}},rf=e=>({type:"Control",scope:e,label:!1}),$A=_.memo(function({path:t,propName:r,schema:n,rootSchema:i,errors:o,enabled:a,renderers:s,cells:l,isValid:u}){return d.jsxs(mr,{children:[n.properties?d.jsx(_e.DispatchCell,{schema:W.Resolve.schema(n,`#/properties/${W.encode(r)}`,i),uischema:rf(`#/properties/${W.encode(r)}`),path:t,enabled:a,renderers:s,cells:l}):d.jsx(_e.DispatchCell,{schema:n,uischema:rf("#"),path:t,enabled:a,renderers:s,cells:l}),d.jsx(b.Text,{size:"xs",children:u?"":o})]})}),DA=e=>{const t=_e.useJsonForms(),r=IA(t,e),n=Al(r.errors);return d.jsx($A,{...r,isValid:n})},MA=({childPath:e,schema:t,rowIndex:r,openDeleteDialog:n,moveUpCreator:i,moveDownCreator:o,enableUp:a,enableDown:s,showSortButtons:l,enabled:u,cells:f,path:c,translations:p})=>{const v={bg:"transparent",size:"sm",c:"gray"},m=b.useProps("ActionIcon",v,{}),y=_.useMemo(()=>i(c,r),[i,c,r]),T=_.useMemo(()=>o(c,r),[o,c,r]);return d.jsxs(b.Table.Tr,{children:[ef(DA,t,e,u,f),u?d.jsx(mr,{style:l?Qc.fixedCell:Qc.fixedCellSmall,children:d.jsxs(b.Grid,{justify:"flex-end",align:"center",children:[l?d.jsxs(_.Fragment,{children:[d.jsx(b.Grid.Col,{span:"content",children:d.jsx(b.Tooltip,{id:"tooltip-up",title:p.up,position:"bottom",opened:a?void 0:!1,children:d.jsx(b.ActionIcon,{bg:m.bg,size:m.size,c:m.c,"aria-label":p.upAriaLabel,onClick:y,disabled:!a,children:d.jsx(CA,{})})})}),d.jsx(b.Grid.Col,{span:"content",children:d.jsx(b.Tooltip,{id:"tooltip-down",title:p.down,position:"bottom",opened:s?void 0:!1,children:d.jsx(b.ActionIcon,{bg:m.bg,size:m.size,c:m.c,"aria-label":p.downAriaLabel,onClick:T,disabled:!s,children:d.jsx(EA,{})})})})]}):null,d.jsx(b.Grid.Col,{span:"content",children:d.jsx(b.Tooltip,{id:"tooltip-remove",title:p.removeTooltip,position:"bottom",children:d.jsx(b.ActionIcon,{bg:m.bg,size:m.size,c:m.c,"aria-label":p.removeAriaLabel,onClick:()=>n(e,r),children:d.jsx(wA,{})})})})]})}):null]},e)},nf=_.memo(MA),RA=({data:e,path:t,schema:r,openDeleteDialog:n,moveUp:i,moveDown:o,uischema:a,config:s,enabled:l,cells:u,translations:f})=>{if(e===0)return d.jsx(PA,{numColumns:tf(r).length+1,translations:f});const p=ou({},s,a.options);return d.jsx(_.Fragment,{children:kE(e).map(v=>{const m=W.Paths.compose(t,`${v}`);return d.jsx(nf,{childPath:m,rowIndex:v,schema:r,openDeleteDialog:n,moveUpCreator:i,moveDownCreator:o,enableUp:v!==0,enableDown:v!==e-1,showSortButtons:p.showSortButtons||p.showArrayTableSortButtons,enabled:l,cells:u,path:t,translations:f},m)})})};class of extends _.Component{constructor(){super(...arguments);jf(this,"addItem",(r,n)=>this.props.addItem(r,n))}render(){const{label:r,description:n,path:i,schema:o,rootSchema:a,uischema:s,errors:l,openDeleteDialog:u,visible:f,enabled:c,cells:p,translations:v}=this.props,m=s,y=o.type==="object",T=y?ef(jA,o,i,c,p):void 0;return f?d.jsxs(b.Table,{children:[d.jsxs(b.Table.Thead,{children:[d.jsx(kA,{errors:l,label:r,description:n,addItem:this.addItem,numColumns:y?T.length:1,path:i,uischema:m,schema:o,rootSchema:a,enabled:c,translations:v}),y&&d.jsxs(b.Table.Tr,{children:[T,c?d.jsx(b.Table.Th,{}):null]})]}),d.jsx(b.Table.Tbody,{children:d.jsx(RA,{openDeleteDialog:u,translations:v,...this.props})})]}):null}}const af=_.memo(function({open:t,onClose:r,onConfirm:n,onCancel:i,title:o,message:a,acceptText:s,declineText:l}){return d.jsxs(b.Modal,{opened:t,withCloseButton:!1,centered:!0,title:o,keepMounted:!0,onClose:r,children:[a,d.jsxs(b.Flex,{justify:"flex-end",align:"center",gap:"sm",children:[d.jsx(b.Button,{onClick:i,children:l}),d.jsx(b.Button,{onClick:n,children:s})]})]})}),NA=e=>{const[t,r]=_.useState(!1),[n,i]=_.useState(void 0),[o,a]=_.useState(void 0),{removeItems:s,visible:l}=e,u=_.useCallback((v,m)=>{r(!0),i(v),a(m)},[r,i,a]),f=_.useCallback(()=>r(!1),[r]),c=_.useCallback(()=>{const v=n.substring(0,n.lastIndexOf("."));s(v,[o])(),r(!1)},[r,n,o]),p=_.useCallback(()=>r(!1),[r]);return l?d.jsxs(d.Fragment,{children:[d.jsx(of,{...e,openDeleteDialog:u}),d.jsx(af,{open:t,onCancel:f,onConfirm:c,onClose:p,acceptText:e.translations.deleteDialogAccept,declineText:e.translations.deleteDialogDecline,title:e.translations.deleteDialogTitle,message:e.translations.deleteDialogMessage})]}):null},sf=W.rankWith(3,W.or(W.isObjectArrayControl,W.isPrimitiveArrayControl)),lf=_e.withJsonFormsArrayLayoutProps(NA),FA=({errors:e,description:t,label:r,required:n,path:i,options:o,data:a,enabled:s,handleChange:l})=>d.jsx(b.MultiSelect,{disabled:!s,data:o,defaultValue:a,label:r,description:t,required:n,error:e,onChange:u=>{l(i,u)}}),LA=e=>e.oneOf!==void 0&&e.oneOf.length>0&&e.oneOf.every(t=>t.const!==void 0),zA=e=>e.type==="string"&&e.enum!==void 0,uf=W.rankWith(6,W.and(W.uiTypeIs("Control"),W.and(W.schemaMatches(e=>W.hasType(e,"array")&&!Array.isArray(e.items)&&e.uniqueItems===!0),W.schemaSubPathMatches("items",(e,t)=>{const r=e.$ref?W.resolveSchema(t,e.$ref,t):e;return LA(r)||zA(r)})))),cf=_e.withJsonFormsMultiEnumProps(FA),BA=e=>{const{description:t,errors:r,data:n,handleChange:i,path:o,label:a,required:s,enabled:l}=e;return d.jsx(Xt.DateInput,{valueFormat:"DD.MM.YYYY",disabled:!l,label:a,description:t,error:r,required:s,value:n?new Date(n):null,onChange:u=>{if(u instanceof Date){const f=new Date(u.getTime()-u.getTimezoneOffset()*6e4);i(o,f.toISOString().substring(0,10))}}})},ff=W.rankWith(5,W.isDateControl),df=_e.withJsonFormsControlProps(BA),UA=e=>{const{description:t,errors:r,data:n,handleChange:i,path:o,label:a,required:s,enabled:l}=e;return d.jsx(Xt.DateTimePicker,{valueFormat:"DD.MM.YYYY HH:mm",disabled:!l,label:a,description:t,error:r,required:s,value:n?new Date(n):null,onChange:u=>{if(u instanceof Date){const f=new Date(u);i(o,f.toISOString())}}})},pf=W.rankWith(5,W.isDateTimeControl),hf=_e.withJsonFormsControlProps(UA),VA=e=>d.jsx(In,{...e}),mf=W.rankWith(3,W.isNumberControl),gf=_e.withJsonFormsControlProps(VA),WA=e=>d.jsx(In,{...e}),yf=W.rankWith(3,W.isIntegerControl),vf=_e.withJsonFormsControlProps(WA),HA=e=>d.jsx(au,{...e}),bf=W.rankWith(3,W.isStringControl),xf=_e.withJsonFormsControlProps(HA),GA=e=>d.jsx(su,{...e}),Tf=W.rankWith(3,W.isBooleanControl),_f=_e.withJsonFormsControlProps(GA),YA=({data:e,options:t,handleChange:r,path:n,...i})=>{const{description:o,errors:a,label:s,required:l,enabled:u}=i;return d.jsx(b.Select,{disabled:!u,data:t,value:e||null,label:s,description:o,required:l,error:a,searchable:!0,onChange:f=>{r(n,f)}})},Sf=W.rankWith(5,W.isEnumControl),Ef=_e.withJsonFormsEnumProps(_e.withTranslateProps(_.memo(YA)),!1),qA=e=>{const{text:t,visible:r}=e;return r?d.jsx(b.Title,{fw:"bold",size:"xl",children:t}):null},KA=W.rankWith(3,W.isLabelable),XA=_e.withJsonFormsLabelProps(qA),Cf=W.rankWith(5,W.uiTypeIs("HorizontalLayout")),JA=({uischema:e,renderers:t,cells:r,schema:n,path:i,enabled:o})=>{const s={elements:e.elements,schema:n,path:i,enabled:o,direction:"row"};return d.jsx(jo,{...s,renderers:t,cells:r})},wf=_e.withJsonFormsLayoutProps(JA),Af=W.rankWith(5,W.uiTypeIs("VerticalLayout")),ZA=({uischema:e,schema:t,path:r,enabled:n,renderers:i,cells:o})=>{const s={elements:e.elements,schema:t,path:r,enabled:n,direction:"column"};return d.jsx(jo,{...s,renderers:i,cells:o})},Of=_e.withJsonFormsLayoutProps(ZA),QA=[{tester:ff,renderer:df},{tester:pf,renderer:hf},{tester:mf,renderer:gf},{tester:yf,renderer:vf},{tester:bf,renderer:xf},{tester:Tf,renderer:_f},{tester:Sf,renderer:Ef},{tester:sf,renderer:lf},{tester:uf,renderer:cf},{tester:Cf,renderer:wf},{tester:Af,renderer:Of},{tester:KA,renderer:XA}],eO=[{tester:du,cell:pu},{tester:lu,cell:uu},{tester:cu,cell:fu},{tester:hu,cell:mu},{tester:gu,cell:yu},{tester:vu,cell:bu},{tester:xu,cell:Tu}],fa={iconSmall:"_iconSmall_sxv3z_1",iconLarge:"_iconLarge_sxv3z_6",btn:"_btn_sxv3z_17"};function tO({basePath:e="/security",Target:t,children:r}){const n=Ft.useNavigate(),{user:i,signout:o}=Wa(),[a,s]=_.useState(!1),u=[{resource_name:e+"/users",label:"Users",name:"UsersApi",Icon:Qd},{resource_name:e+"/roles",label:"Roles",name:"RolesApi",Icon:Xd},{resource_name:e+"/permissions",label:"Base Permissions",name:"PermissionsApi",Icon:Za},{resource_name:e+"/permissionviews",label:"Permission on Views",name:"PermissionViewApi",Icon:Za},{resource_name:e+"/viewsmenus",label:"Views/Menus",name:"ViewsMenusApi",Icon:Gd}].filter(f=>i.permissions.includes(f.name));return d.jsxs(b.Menu,{width:260,position:"bottom-end",transition:"pop-top-right",withinPortal:!0,opened:a,onClose:()=>s(!1),onOpen:()=>s(!0),children:[d.jsx(b.Menu.Target,{children:t||d.jsx(b.UnstyledButton,{className:fa.btn,style:{borderRadius:4},p:"xs",children:d.jsxs(b.Group,{style:{flexWrap:"nowrap"},spacing:7,children:[d.jsx(b.Text,{weight:500,size:"sm",style:{lineHeight:1,whiteSpace:"nowrap"},mr:3,children:`${i.first_name} ${i.last_name}`}),d.jsx(Hi,{size:12})]})})}),d.jsxs(b.Menu.Dropdown,{children:[u.length?d.jsxs(d.Fragment,{children:[d.jsx(b.Menu.Label,{children:"Security"}),u.map((f,c)=>d.jsx(b.Menu.Item,{p:12,leftSection:d.jsx(f.Icon,{className:fa.iconSmall}),onClick:()=>n(f.resource_name),children:f.label},c)),d.jsx(b.Menu.Divider,{})]}):null,r,d.jsx(b.Menu.Item,{leftSection:d.jsx(Jd,{p:12,className:fa.iconSmall}),onClick:o,children:"Logout"})]})]})}I.Actions=fs,I.Add=es,I.AddDialog=Ka,I.ApiProvider=Ga,I.DataGrid=xo,I.Delete=cs,I.DeleteDialog=af,I.Edit=us,I.EditDialog=ls,I.Filter=rs,I.FilterMenu=ts,I.InfiniteScroll=zh,I.MantineArrayControlRenderer=lf,I.MantineBooleanCell=mu,I.MantineBooleanControl=_f,I.MantineDateCell=yu,I.MantineDateControl=df,I.MantineDateTimeCell=bu,I.MantineDateTimeControl=hf,I.MantineEnumArrayRenderer=cf,I.MantineEnumCell=Tu,I.MantineEnumControl=Ef,I.MantineHorizontalLayoutRenderer=wf,I.MantineIntegerCell=fu,I.MantineIntegerControl=vf,I.MantineLayoutRenderer=jo,I.MantineNumberCell=uu,I.MantineNumberControl=gf,I.MantineTableControl=of,I.MantineTextCell=pu,I.MantineTextControl=xf,I.MantineVerticalLayoutRenderer=Of,I.NoBorderTableCell=mr,I.NonEmptyRow=nf,I.Provider=$d,I.UserMenu=tO,I.mantineArrayControlTester=sf,I.mantineBooleanCellTester=hu,I.mantineBooleanControlTester=Tf,I.mantineCells=eO,I.mantineDateCellTester=gu,I.mantineDateControlTester=ff,I.mantineDateTimeCellTester=vu,I.mantineDateTimeControlTester=pf,I.mantineEnumArrayRendererTester=uf,I.mantineEnumCellTester=xu,I.mantineEnumControlTester=Sf,I.mantineHorizontalLayoutTester=Cf,I.mantineIntegerCellTester=cu,I.mantineIntegerControlTester=yf,I.mantineNumberCellTester=lu,I.mantineNumberControlTester=mf,I.mantineRenderers=QA,I.mantineTextCellTester=du,I.mantineTextControlTester=bf,I.mantineVerticalLayoutTester=Af,I.renderLayoutElements=Ol,I.useApi=De,I.useAuth=Wa,I.useAuthenticate=ga,I.useBulkActions=Fd,I.useCustomFetch=Xr,I.useDebouncedChange=Dl,I.useGetList=ya,I.useInfo=Ha,I.useInfo_=Ua,I.withAjvProps=Ny,Object.defineProperty(I,Symbol.toStringTag,{value:"Module"})});
|
|
191
|
+
export default theme;`}function la(e={},...t){const{breakpoints:r,mixins:n={},spacing:i,palette:o={},transitions:a={},typography:s={},shape:l,...u}=e;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.":It(20));const f=sa(o),c=Mc(e);let p=et(c,{mixins:Hw(c.breakpoints,n),palette:f,shadows:Jw.slice(),typography:Yw(f,s),transitions:tA(a),zIndex:{...rA}});if(p=et(p,u),p=t.reduce((y,g)=>et(y,g),p),process.env.NODE_ENV!=="production"){const y=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],g=(m,T)=>{let j;for(j in m){const F=m[j];if(y.includes(j)&&Object.keys(F).length>0){if(process.env.NODE_ENV!=="production"){const D=Ko("",j);console.error([`MUI: The \`${T}\` component increases the CSS specificity of the \`${j}\` internal state.`,"You can not override it like this: ",JSON.stringify(m,null,2),"",`Instead, you need to use the '&.${D}' syntax:`,JSON.stringify({root:{[`&.${D}`]:F}},null,2),"","https://mui.com/r/state-classes-guide"].join(`
|
|
192
|
+
`))}m[j]={}}}};Object.keys(p.components).forEach(m=>{const T=p.components[m].styleOverrides;T&&m.startsWith("Mui")&&g(T,m)})}return p.unstable_sxConfig={...Jn,...u==null?void 0:u.unstable_sxConfig},p.unstable_sx=function(g){return ur({sx:g,theme:this})},p.toRuntimeSource=Xc,p}function iA(e){let t;return e<1?t=5.11916*e**2:t=4.5*Math.log(e+1)+2,Math.round(t*10)/1e3}const oA=[...Array(25)].map((e,t)=>{if(t===0)return"none";const r=iA(t);return`linear-gradient(rgba(255 255 255 / ${r}), rgba(255 255 255 / ${r}))`});function Jc(e){return{inputPlaceholder:e==="dark"?.5:.42,inputUnderline:e==="dark"?.7:.42,switchTrackDisabled:e==="dark"?.2:.12,switchTrack:e==="dark"?.3:.38}}function Zc(e){return e==="dark"?oA:[]}function aA(e){const{palette:t={mode:"light"},opacity:r,overlays:n,...i}=e,o=sa(t);return{palette:o,opacity:{...Jc(o.mode),...r},overlays:n||Zc(o.mode),...i}}function sA(e){var t;return!!e[0].match(/(cssVarPrefix|colorSchemeSelector|rootSelector|typography|mixins|breakpoints|direction|transitions)/)||!!e[0].match(/sxConfig$/)||e[0]==="palette"&&!!((t=e[1])!=null&&t.match(/(mode|contrastThreshold|tonalOffset)/))}const lA=e=>[...[...Array(25)].map((t,r)=>`--${e?`${e}-`:""}overlays-${r}`),`--${e?`${e}-`:""}palette-AppBar-darkBg`,`--${e?`${e}-`:""}palette-AppBar-darkColor`],uA=e=>(t,r)=>{const n=e.rootSelector||":root",i=e.colorSchemeSelector;let o=i;if(i==="class"&&(o=".%s"),i==="data"&&(o="[data-%s]"),i!=null&&i.startsWith("data-")&&!i.includes("%s")&&(o=`[${i}="%s"]`),e.defaultColorScheme===t){if(t==="dark"){const a={};return lA(e.cssVarPrefix).forEach(s=>{a[s]=r[s],delete r[s]}),o==="media"?{[n]:r,"@media (prefers-color-scheme: dark)":{[n]:a}}:o?{[o.replace("%s",t)]:a,[`${n}, ${o.replace("%s",t)}`]:r}:{[n]:{...r,...a}}}if(o&&o!=="media")return`${n}, ${o.replace("%s",String(t))}`}else if(t){if(o==="media")return{[`@media (prefers-color-scheme: ${String(t)})`]:{[n]:r}};if(o)return o.replace("%s",String(t))}return n};function cA(e,t){t.forEach(r=>{e[r]||(e[r]={})})}function S(e,t,r){!e[t]&&r&&(e[t]=r)}function Ur(e){return!e||!e.startsWith("hsl")?e:Lc(e)}function _t(e,t){`${t}Channel`in e||(e[`${t}Channel`]=Lr(Ur(e[t]),`MUI: Can't create \`palette.${t}Channel\` because \`palette.${t}\` is not one of these formats: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().
|
|
193
|
+
To suppress this warning, you need to explicitly provide the \`palette.${t}Channel\` as a string (in rgb format, for example "12 12 12") or undefined if you want to remove the channel token.`))}function fA(e){return typeof e=="number"?`${e}px`:typeof e=="string"||typeof e=="function"||Array.isArray(e)?e:"8px"}const mt=e=>{try{return e()}catch{}},dA=(e="mui")=>jw(e);function ua(e,t,r,n){if(!t)return;t=t===!0?{}:t;const i=n==="dark"?"dark":"light";if(!r){e[n]=aA({...t,palette:{mode:i,...t==null?void 0:t.palette}});return}const{palette:o,...a}=la({...r,palette:{mode:i,...t==null?void 0:t.palette}});return e[n]={...t,palette:o,opacity:{...Jc(i),...t==null?void 0:t.opacity},overlays:(t==null?void 0:t.overlays)||Zc(i)},a}function pA(e={},...t){const{colorSchemes:r={light:!0},defaultColorScheme:n,disableCssColorScheme:i=!1,cssVarPrefix:o="mui",shouldSkipGeneratingVar:a=sA,colorSchemeSelector:s=r.light&&r.dark?"media":void 0,rootSelector:l=":root",...u}=e,f=Object.keys(r)[0],c=n||(r.light&&f!=="light"?"light":f),p=dA(o),{[c]:y,light:g,dark:m,...T}=r,j={...T};let F=y;if((c==="dark"&&!("dark"in r)||c==="light"&&!("light"in r))&&(F=!0),!F)throw new Error(process.env.NODE_ENV!=="production"?`MUI: The \`colorSchemes.${c}\` option is either missing or invalid.`:It(21,c));const D=ua(j,F,u,c);g&&!j.light&&ua(j,g,void 0,"light"),m&&!j.dark&&ua(j,m,void 0,"dark");let O={defaultColorScheme:c,...D,cssVarPrefix:o,colorSchemeSelector:s,rootSelector:l,getCssVar:p,colorSchemes:j,font:{...Ww(D.typography),...D.font},spacing:fA(u.spacing)};Object.keys(O.colorSchemes).forEach(ie=>{const h=O.colorSchemes[ie].palette,A=U=>{const H=U.split("-"),te=H[1],ve=H[2];return p(U,h[te][ve])};if(h.mode==="light"&&(S(h.common,"background","#fff"),S(h.common,"onBackground","#000")),h.mode==="dark"&&(S(h.common,"background","#000"),S(h.common,"onBackground","#fff")),cA(h,["Alert","AppBar","Avatar","Button","Chip","FilledInput","LinearProgress","Skeleton","Slider","SnackbarContent","SpeedDialAction","StepConnector","StepContent","Switch","TableCell","Tooltip"]),h.mode==="light"){S(h.Alert,"errorColor",xe(h.error.light,.6)),S(h.Alert,"infoColor",xe(h.info.light,.6)),S(h.Alert,"successColor",xe(h.success.light,.6)),S(h.Alert,"warningColor",xe(h.warning.light,.6)),S(h.Alert,"errorFilledBg",A("palette-error-main")),S(h.Alert,"infoFilledBg",A("palette-info-main")),S(h.Alert,"successFilledBg",A("palette-success-main")),S(h.Alert,"warningFilledBg",A("palette-warning-main")),S(h.Alert,"errorFilledColor",mt(()=>h.getContrastText(h.error.main))),S(h.Alert,"infoFilledColor",mt(()=>h.getContrastText(h.info.main))),S(h.Alert,"successFilledColor",mt(()=>h.getContrastText(h.success.main))),S(h.Alert,"warningFilledColor",mt(()=>h.getContrastText(h.warning.main))),S(h.Alert,"errorStandardBg",Te(h.error.light,.9)),S(h.Alert,"infoStandardBg",Te(h.info.light,.9)),S(h.Alert,"successStandardBg",Te(h.success.light,.9)),S(h.Alert,"warningStandardBg",Te(h.warning.light,.9)),S(h.Alert,"errorIconColor",A("palette-error-main")),S(h.Alert,"infoIconColor",A("palette-info-main")),S(h.Alert,"successIconColor",A("palette-success-main")),S(h.Alert,"warningIconColor",A("palette-warning-main")),S(h.AppBar,"defaultBg",A("palette-grey-100")),S(h.Avatar,"defaultBg",A("palette-grey-400")),S(h.Button,"inheritContainedBg",A("palette-grey-300")),S(h.Button,"inheritContainedHoverBg",A("palette-grey-A100")),S(h.Chip,"defaultBorder",A("palette-grey-400")),S(h.Chip,"defaultAvatarColor",A("palette-grey-700")),S(h.Chip,"defaultIconColor",A("palette-grey-700")),S(h.FilledInput,"bg","rgba(0, 0, 0, 0.06)"),S(h.FilledInput,"hoverBg","rgba(0, 0, 0, 0.09)"),S(h.FilledInput,"disabledBg","rgba(0, 0, 0, 0.12)"),S(h.LinearProgress,"primaryBg",Te(h.primary.main,.62)),S(h.LinearProgress,"secondaryBg",Te(h.secondary.main,.62)),S(h.LinearProgress,"errorBg",Te(h.error.main,.62)),S(h.LinearProgress,"infoBg",Te(h.info.main,.62)),S(h.LinearProgress,"successBg",Te(h.success.main,.62)),S(h.LinearProgress,"warningBg",Te(h.warning.main,.62)),S(h.Skeleton,"bg",`rgba(${A("palette-text-primaryChannel")} / 0.11)`),S(h.Slider,"primaryTrack",Te(h.primary.main,.62)),S(h.Slider,"secondaryTrack",Te(h.secondary.main,.62)),S(h.Slider,"errorTrack",Te(h.error.main,.62)),S(h.Slider,"infoTrack",Te(h.info.main,.62)),S(h.Slider,"successTrack",Te(h.success.main,.62)),S(h.Slider,"warningTrack",Te(h.warning.main,.62));const U=ti(h.background.default,.8);S(h.SnackbarContent,"bg",U),S(h.SnackbarContent,"color",mt(()=>h.getContrastText(U))),S(h.SpeedDialAction,"fabHoverBg",ti(h.background.paper,.15)),S(h.StepConnector,"border",A("palette-grey-400")),S(h.StepContent,"border",A("palette-grey-400")),S(h.Switch,"defaultColor",A("palette-common-white")),S(h.Switch,"defaultDisabledColor",A("palette-grey-100")),S(h.Switch,"primaryDisabledColor",Te(h.primary.main,.62)),S(h.Switch,"secondaryDisabledColor",Te(h.secondary.main,.62)),S(h.Switch,"errorDisabledColor",Te(h.error.main,.62)),S(h.Switch,"infoDisabledColor",Te(h.info.main,.62)),S(h.Switch,"successDisabledColor",Te(h.success.main,.62)),S(h.Switch,"warningDisabledColor",Te(h.warning.main,.62)),S(h.TableCell,"border",Te(ei(h.divider,1),.88)),S(h.Tooltip,"bg",ei(h.grey[700],.92))}if(h.mode==="dark"){S(h.Alert,"errorColor",Te(h.error.light,.6)),S(h.Alert,"infoColor",Te(h.info.light,.6)),S(h.Alert,"successColor",Te(h.success.light,.6)),S(h.Alert,"warningColor",Te(h.warning.light,.6)),S(h.Alert,"errorFilledBg",A("palette-error-dark")),S(h.Alert,"infoFilledBg",A("palette-info-dark")),S(h.Alert,"successFilledBg",A("palette-success-dark")),S(h.Alert,"warningFilledBg",A("palette-warning-dark")),S(h.Alert,"errorFilledColor",mt(()=>h.getContrastText(h.error.dark))),S(h.Alert,"infoFilledColor",mt(()=>h.getContrastText(h.info.dark))),S(h.Alert,"successFilledColor",mt(()=>h.getContrastText(h.success.dark))),S(h.Alert,"warningFilledColor",mt(()=>h.getContrastText(h.warning.dark))),S(h.Alert,"errorStandardBg",xe(h.error.light,.9)),S(h.Alert,"infoStandardBg",xe(h.info.light,.9)),S(h.Alert,"successStandardBg",xe(h.success.light,.9)),S(h.Alert,"warningStandardBg",xe(h.warning.light,.9)),S(h.Alert,"errorIconColor",A("palette-error-main")),S(h.Alert,"infoIconColor",A("palette-info-main")),S(h.Alert,"successIconColor",A("palette-success-main")),S(h.Alert,"warningIconColor",A("palette-warning-main")),S(h.AppBar,"defaultBg",A("palette-grey-900")),S(h.AppBar,"darkBg",A("palette-background-paper")),S(h.AppBar,"darkColor",A("palette-text-primary")),S(h.Avatar,"defaultBg",A("palette-grey-600")),S(h.Button,"inheritContainedBg",A("palette-grey-800")),S(h.Button,"inheritContainedHoverBg",A("palette-grey-700")),S(h.Chip,"defaultBorder",A("palette-grey-700")),S(h.Chip,"defaultAvatarColor",A("palette-grey-300")),S(h.Chip,"defaultIconColor",A("palette-grey-300")),S(h.FilledInput,"bg","rgba(255, 255, 255, 0.09)"),S(h.FilledInput,"hoverBg","rgba(255, 255, 255, 0.13)"),S(h.FilledInput,"disabledBg","rgba(255, 255, 255, 0.12)"),S(h.LinearProgress,"primaryBg",xe(h.primary.main,.5)),S(h.LinearProgress,"secondaryBg",xe(h.secondary.main,.5)),S(h.LinearProgress,"errorBg",xe(h.error.main,.5)),S(h.LinearProgress,"infoBg",xe(h.info.main,.5)),S(h.LinearProgress,"successBg",xe(h.success.main,.5)),S(h.LinearProgress,"warningBg",xe(h.warning.main,.5)),S(h.Skeleton,"bg",`rgba(${A("palette-text-primaryChannel")} / 0.13)`),S(h.Slider,"primaryTrack",xe(h.primary.main,.5)),S(h.Slider,"secondaryTrack",xe(h.secondary.main,.5)),S(h.Slider,"errorTrack",xe(h.error.main,.5)),S(h.Slider,"infoTrack",xe(h.info.main,.5)),S(h.Slider,"successTrack",xe(h.success.main,.5)),S(h.Slider,"warningTrack",xe(h.warning.main,.5));const U=ti(h.background.default,.98);S(h.SnackbarContent,"bg",U),S(h.SnackbarContent,"color",mt(()=>h.getContrastText(U))),S(h.SpeedDialAction,"fabHoverBg",ti(h.background.paper,.15)),S(h.StepConnector,"border",A("palette-grey-600")),S(h.StepContent,"border",A("palette-grey-600")),S(h.Switch,"defaultColor",A("palette-grey-300")),S(h.Switch,"defaultDisabledColor",A("palette-grey-600")),S(h.Switch,"primaryDisabledColor",xe(h.primary.main,.55)),S(h.Switch,"secondaryDisabledColor",xe(h.secondary.main,.55)),S(h.Switch,"errorDisabledColor",xe(h.error.main,.55)),S(h.Switch,"infoDisabledColor",xe(h.info.main,.55)),S(h.Switch,"successDisabledColor",xe(h.success.main,.55)),S(h.Switch,"warningDisabledColor",xe(h.warning.main,.55)),S(h.TableCell,"border",xe(ei(h.divider,1),.68)),S(h.Tooltip,"bg",ei(h.grey[700],.92))}_t(h.background,"default"),_t(h.background,"paper"),_t(h.common,"background"),_t(h.common,"onBackground"),_t(h,"divider"),Object.keys(h).forEach(U=>{const H=h[U];H&&typeof H=="object"&&(H.main&&S(h[U],"mainChannel",Lr(Ur(H.main))),H.light&&S(h[U],"lightChannel",Lr(Ur(H.light))),H.dark&&S(h[U],"darkChannel",Lr(Ur(H.dark))),H.contrastText&&S(h[U],"contrastTextChannel",Lr(Ur(H.contrastText))),U==="text"&&(_t(h[U],"primary"),_t(h[U],"secondary")),U==="action"&&(H.active&&_t(h[U],"active"),H.selected&&_t(h[U],"selected")))})}),O=t.reduce((ie,h)=>et(ie,h),O);const E={prefix:o,disableCssColorScheme:i,shouldSkipGeneratingVar:a,getSelector:uA(O)},{vars:M,generateThemeVars:Y,generateStyleSheets:ce}=Dw(O,E);return O.vars=M,Object.entries(O.colorSchemes[O.defaultColorScheme]).forEach(([ie,h])=>{O[ie]=h}),O.generateThemeVars=Y,O.generateStyleSheets=ce,O.generateSpacing=function(){return Dc(u.spacing,Xo(this))},O.getColorSchemeSelector=Mw(s),O.spacing=O.generateSpacing(),O.shouldSkipGeneratingVar=a,O.unstable_sxConfig={...Jn,...u==null?void 0:u.unstable_sxConfig},O.unstable_sx=function(h){return ur({sx:h,theme:this})},O.toRuntimeSource=Xc,O}function Qc(e,t,r){e.colorSchemes&&r&&(e.colorSchemes[t]={...r!==!0&&r,palette:sa({...r===!0?{}:r.palette,mode:t})})}function hA(e={},...t){const{palette:r,cssVariables:n=!1,colorSchemes:i=r?void 0:{light:!0},defaultColorScheme:o=r==null?void 0:r.mode,...a}=e,s=o||"light",l=i==null?void 0:i[s],u={...i,...r?{[s]:{...typeof l!="boolean"&&l,palette:r}}:void 0};if(n===!1){if(!("colorSchemes"in e))return la(e,...t);let f=r;"palette"in e||u[s]&&(u[s]!==!0?f=u[s].palette:s==="dark"&&(f={mode:"dark"}));const c=la({...e,palette:f},...t);return c.defaultColorScheme=s,c.colorSchemes=u,c.palette.mode==="light"&&(c.colorSchemes.light={...u.light!==!0&&u.light,palette:c.palette},Qc(c,"dark",u.dark)),c.palette.mode==="dark"&&(c.colorSchemes.dark={...u.dark!==!0&&u.dark,palette:c.palette},Qc(c,"light",u.light)),c}return!r&&!("light"in u)&&s==="light"&&(u.light=!0),pA({...a,colorSchemes:u,defaultColorScheme:s,...typeof n!="boolean"&&n},...t)}const mA=hA(),gA="$$material";function yA(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const vA=vw({themeId:gA,defaultTheme:mA,rootShouldForwardProp:e=>yA(e)&&e!=="classes"}),bA=Pw;process.env.NODE_ENV!=="production"&&(de.node,de.object.isRequired);function xA(e){return kw(e)}function TA(e){return Ko("MuiSvgIcon",e)}GS("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const _A=e=>{const{color:t,fontSize:r,classes:n}=e,i={root:["root",t!=="inherit"&&`color${Gt(t)}`,`fontSize${Gt(r)}`]};return VS(i,TA,n)},EA=vA("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,r.color!=="inherit"&&t[`color${Gt(r.color)}`],t[`fontSize${Gt(r.fontSize)}`]]}})(bA(({theme:e})=>{var t,r,n,i,o,a,s,l,u,f,c,p,y,g;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",flexShrink:0,transition:(i=(t=e.transitions)==null?void 0:t.create)==null?void 0:i.call(t,"fill",{duration:(n=(r=(e.vars??e).transitions)==null?void 0:r.duration)==null?void 0:n.shorter}),variants:[{props:m=>!m.hasSvgAsChild,style:{fill:"currentColor"}},{props:{fontSize:"inherit"},style:{fontSize:"inherit"}},{props:{fontSize:"small"},style:{fontSize:((a=(o=e.typography)==null?void 0:o.pxToRem)==null?void 0:a.call(o,20))||"1.25rem"}},{props:{fontSize:"medium"},style:{fontSize:((l=(s=e.typography)==null?void 0:s.pxToRem)==null?void 0:l.call(s,24))||"1.5rem"}},{props:{fontSize:"large"},style:{fontSize:((f=(u=e.typography)==null?void 0:u.pxToRem)==null?void 0:f.call(u,35))||"2.1875rem"}},...Object.entries((e.vars??e).palette).filter(([,m])=>m&&m.main).map(([m])=>{var T,j;return{props:{color:m},style:{color:(j=(T=(e.vars??e).palette)==null?void 0:T[m])==null?void 0:j.main}}}),{props:{color:"action"},style:{color:(p=(c=(e.vars??e).palette)==null?void 0:c.action)==null?void 0:p.active}},{props:{color:"disabled"},style:{color:(g=(y=(e.vars??e).palette)==null?void 0:y.action)==null?void 0:g.disabled}},{props:{color:"inherit"},style:{color:void 0}}]}})),Vr=Je.forwardRef(function(t,r){const n=xA({props:t,name:"MuiSvgIcon"}),{children:i,className:o,color:a="inherit",component:s="svg",fontSize:l="medium",htmlColor:u,inheritViewBox:f=!1,titleAccess:c,viewBox:p="0 0 24 24",...y}=n,g=Je.isValidElement(i)&&i.type==="svg",m={...n,color:a,component:s,fontSize:l,instanceFontSize:t.fontSize,inheritViewBox:f,viewBox:p,hasSvgAsChild:g},T={};f||(T.viewBox=p);const j=_A(m);return d.jsxs(EA,{as:s,className:qS(j.root,o),focusable:"false",color:u,"aria-hidden":c?void 0:!0,role:c?"img":void 0,ref:r,...T,...y,...g&&i.props,ownerState:m,children:[g?i.props.children:i,c?d.jsx("title",{children:c}):null]})});process.env.NODE_ENV!=="production"&&(Vr.propTypes={children:de.node,classes:de.object,className:de.string,color:de.oneOfType([de.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),de.string]),component:de.elementType,fontSize:de.oneOfType([de.oneOf(["inherit","large","medium","small"]),de.string]),htmlColor:de.string,inheritViewBox:de.bool,shapeRendering:de.string,sx:de.oneOfType([de.arrayOf(de.oneOfType([de.func,de.object,de.bool])),de.func,de.object]),titleAccess:de.string,viewBox:de.string}),Vr&&(Vr.muiName="SvgIcon");function ca(e,t){function r(n,i){return d.jsx(Vr,{"data-testid":`${t}Icon`,ref:i,...n,children:e})}return process.env.NODE_ENV!=="production"&&(r.displayName=`${t}Icon`),r.muiName=Vr.muiName,Je.memo(Je.forwardRef(r))}const SA=ca(d.jsx("path",{d:"m20 12-1.41-1.41L13 16.17V4h-2v12.17l-5.58-5.59L4 12l8 8z"}),"ArrowDownward"),CA=ca(d.jsx("path",{d:"m4 12 1.41 1.41L11 7.83V20h2V7.83l5.58 5.59L20 12l-8-8z"}),"ArrowUpward"),wA=ca(d.jsx("path",{d:"M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6zM19 4h-3.5l-1-1h-5l-1 1H5v2h14z"}),"Delete"),mr=({children:e,...t})=>d.jsx(b.Table.Td,{...t,children:e}),AA=({errorMessages:e,id:t})=>d.jsx(b.Tooltip,{id:t,title:e,children:d.jsx(b.Indicator,{label:e.split(`
|
|
194
|
+
`).length,children:d.jsx(Kd,{})})}),OA={paddingLeft:0,paddingRight:0},kA=_.memo(function({numColumns:t,errors:r,label:n,description:i,path:o,addItem:a,schema:s,enabled:l,translations:u,rootSchema:f}){const c={bg:"transparent",size:"sm",c:"gray"},p=b.useProps("ActionIcon",c,{});return d.jsxs(b.Table.Tr,{children:[d.jsx(mr,{colSpan:t,children:d.jsxs(b.Stack,{children:[d.jsxs(b.Grid,{justify:"flex-start",align:"center",gutter:"sm",children:[d.jsx(b.Grid.Col,{span:"content",children:d.jsx(b.Text,{children:n})}),d.jsx(b.Grid.Col,{span:"content",children:r.length!==0?d.jsx(b.Grid.Col,{span:"content",children:d.jsx(AA,{id:"tooltip-validation",errorMessages:r})}):null})]}),i&&d.jsx(b.Text,{size:"sm",children:i})]})}),l?d.jsx(mr,{align:"right",style:OA,children:d.jsx(b.Tooltip,{id:"tooltip-add",title:u.addTooltip,position:"bottom",children:d.jsx(b.ActionIcon,{bg:p.bg,size:p.size,c:p.c,onClick:a(o,W.createDefaultValue(s,f)),children:d.jsx(Gi,{})})})}):null]})}),ef={fixedCell:{width:"150px",height:"50px",paddingLeft:0,paddingRight:0,textAlign:"center"},fixedCellSmall:{width:"50px",height:"50px",paddingLeft:0,paddingRight:0,textAlign:"center"}},tf=(e,t,r,n,i)=>{if(t.type==="object")return rf(t).map(o=>{var l,u;const a=W.Paths.compose(r,o),s={propName:o,schema:t,title:((u=(l=t.properties)==null?void 0:l[o])==null?void 0:u.title)??hS(o),rowPath:r,cellPath:a,enabled:n,cells:i};return d.jsx(e,{...s},a)});{const o={schema:t,rowPath:r,cellPath:r,enabled:n};return d.jsx(e,{...o},r)}},rf=e=>e.type==="object"&&typeof e.properties=="object"?Object.keys(e.properties).filter(t=>e.properties[t].type!=="array"):[""],PA=({numColumns:e,translations:t})=>d.jsx(b.Table.Tr,{children:d.jsx(mr,{colSpan:e,children:d.jsx(b.Text,{align:"center",children:t.noDataMessage})})}),jA=_.memo(function({title:t}){return d.jsx(b.Table.Th,{children:t})}),IA=(e,t)=>{const r=t.rowPath+(t.schema.type==="object"?"."+t.propName:""),n=W.formatErrorMessage(r_(W.errorsAt(r,t.schema,i=>i===r)(e.core.errors).map(i=>i.message)));return{rowPath:t.rowPath,propName:t.propName,schema:t.schema,rootSchema:e.core.schema,errors:n,path:r,enabled:t.enabled,cells:t.cells||e.cells,renderers:t.renderers||e.renderers}},nf=e=>({type:"Control",scope:e,label:!1}),$A=_.memo(function({path:t,propName:r,schema:n,rootSchema:i,errors:o,enabled:a,renderers:s,cells:l,isValid:u}){return d.jsxs(mr,{children:[n.properties?d.jsx(_e.DispatchCell,{schema:W.Resolve.schema(n,`#/properties/${W.encode(r)}`,i),uischema:nf(`#/properties/${W.encode(r)}`),path:t,enabled:a,renderers:s,cells:l}):d.jsx(_e.DispatchCell,{schema:n,uischema:nf("#"),path:t,enabled:a,renderers:s,cells:l}),d.jsx(b.Text,{size:"xs",children:u?"":o})]})}),DA=e=>{const t=_e.useJsonForms(),r=IA(t,e),n=Al(r.errors);return d.jsx($A,{...r,isValid:n})},MA=({childPath:e,schema:t,rowIndex:r,openDeleteDialog:n,moveUpCreator:i,moveDownCreator:o,enableUp:a,enableDown:s,showSortButtons:l,enabled:u,cells:f,path:c,translations:p})=>{const y={bg:"transparent",size:"sm",c:"gray"},g=b.useProps("ActionIcon",y,{}),m=_.useMemo(()=>i(c,r),[i,c,r]),T=_.useMemo(()=>o(c,r),[o,c,r]);return d.jsxs(b.Table.Tr,{children:[tf(DA,t,e,u,f),u?d.jsx(mr,{style:l?ef.fixedCell:ef.fixedCellSmall,children:d.jsxs(b.Grid,{justify:"flex-end",align:"center",children:[l?d.jsxs(_.Fragment,{children:[d.jsx(b.Grid.Col,{span:"content",children:d.jsx(b.Tooltip,{id:"tooltip-up",title:p.up,position:"bottom",opened:a?void 0:!1,children:d.jsx(b.ActionIcon,{bg:g.bg,size:g.size,c:g.c,"aria-label":p.upAriaLabel,onClick:m,disabled:!a,children:d.jsx(CA,{})})})}),d.jsx(b.Grid.Col,{span:"content",children:d.jsx(b.Tooltip,{id:"tooltip-down",title:p.down,position:"bottom",opened:s?void 0:!1,children:d.jsx(b.ActionIcon,{bg:g.bg,size:g.size,c:g.c,"aria-label":p.downAriaLabel,onClick:T,disabled:!s,children:d.jsx(SA,{})})})})]}):null,d.jsx(b.Grid.Col,{span:"content",children:d.jsx(b.Tooltip,{id:"tooltip-remove",title:p.removeTooltip,position:"bottom",children:d.jsx(b.ActionIcon,{bg:g.bg,size:g.size,c:g.c,"aria-label":p.removeAriaLabel,onClick:()=>n(e,r),children:d.jsx(wA,{})})})})]})}):null]},e)},of=_.memo(MA),RA=({data:e,path:t,schema:r,openDeleteDialog:n,moveUp:i,moveDown:o,uischema:a,config:s,enabled:l,cells:u,translations:f})=>{if(e===0)return d.jsx(PA,{numColumns:rf(r).length+1,translations:f});const p=ou({},s,a.options);return d.jsx(_.Fragment,{children:PS(e).map(y=>{const g=W.Paths.compose(t,`${y}`);return d.jsx(of,{childPath:g,rowIndex:y,schema:r,openDeleteDialog:n,moveUpCreator:i,moveDownCreator:o,enableUp:y!==0,enableDown:y!==e-1,showSortButtons:p.showSortButtons||p.showArrayTableSortButtons,enabled:l,cells:u,path:t,translations:f},g)})})};class af extends _.Component{constructor(){super(...arguments);If(this,"addItem",(r,n)=>this.props.addItem(r,n))}render(){const{label:r,description:n,path:i,schema:o,rootSchema:a,uischema:s,errors:l,openDeleteDialog:u,visible:f,enabled:c,cells:p,translations:y}=this.props,g=s,m=o.type==="object",T=m?tf(jA,o,i,c,p):void 0;return f?d.jsxs(b.Table,{children:[d.jsxs(b.Table.Thead,{children:[d.jsx(kA,{errors:l,label:r,description:n,addItem:this.addItem,numColumns:m?T.length:1,path:i,uischema:g,schema:o,rootSchema:a,enabled:c,translations:y}),m&&d.jsxs(b.Table.Tr,{children:[T,c?d.jsx(b.Table.Th,{}):null]})]}),d.jsx(b.Table.Tbody,{children:d.jsx(RA,{openDeleteDialog:u,translations:y,...this.props})})]}):null}}const sf=_.memo(function({open:t,onClose:r,onConfirm:n,onCancel:i,title:o,message:a,acceptText:s,declineText:l}){return d.jsxs(b.Modal,{opened:t,withCloseButton:!1,centered:!0,title:o,keepMounted:!0,onClose:r,children:[a,d.jsxs(b.Flex,{justify:"flex-end",align:"center",gap:"sm",children:[d.jsx(b.Button,{onClick:i,children:l}),d.jsx(b.Button,{onClick:n,children:s})]})]})}),NA=e=>{const[t,r]=_.useState(!1),[n,i]=_.useState(void 0),[o,a]=_.useState(void 0),{removeItems:s,visible:l}=e,u=_.useCallback((y,g)=>{r(!0),i(y),a(g)},[r,i,a]),f=_.useCallback(()=>r(!1),[r]),c=_.useCallback(()=>{const y=n.substring(0,n.lastIndexOf("."));s(y,[o])(),r(!1)},[r,n,o]),p=_.useCallback(()=>r(!1),[r]);return l?d.jsxs(d.Fragment,{children:[d.jsx(af,{...e,openDeleteDialog:u}),d.jsx(sf,{open:t,onCancel:f,onConfirm:c,onClose:p,acceptText:e.translations.deleteDialogAccept,declineText:e.translations.deleteDialogDecline,title:e.translations.deleteDialogTitle,message:e.translations.deleteDialogMessage})]}):null},lf=W.rankWith(3,W.or(W.isObjectArrayControl,W.isPrimitiveArrayControl)),uf=_e.withJsonFormsArrayLayoutProps(NA),FA=({errors:e,description:t,label:r,required:n,path:i,options:o,data:a,enabled:s,handleChange:l})=>d.jsx(b.MultiSelect,{disabled:!s,data:o,defaultValue:a,label:r,description:t,required:n,error:e,onChange:u=>{l(i,u)}}),LA=e=>e.oneOf!==void 0&&e.oneOf.length>0&&e.oneOf.every(t=>t.const!==void 0),zA=e=>e.type==="string"&&e.enum!==void 0,cf=W.rankWith(6,W.and(W.uiTypeIs("Control"),W.and(W.schemaMatches(e=>W.hasType(e,"array")&&!Array.isArray(e.items)&&e.uniqueItems===!0),W.schemaSubPathMatches("items",(e,t)=>{const r=e.$ref?W.resolveSchema(t,e.$ref,t):e;return LA(r)||zA(r)})))),ff=_e.withJsonFormsMultiEnumProps(FA),BA=e=>{const{description:t,errors:r,data:n,handleChange:i,path:o,label:a,required:s,enabled:l}=e;return d.jsx(Xt.DateInput,{valueFormat:"DD.MM.YYYY",disabled:!l,label:a,description:t,error:r,required:s,value:n?new Date(n):null,onChange:u=>{if(u instanceof Date){const f=new Date(u.getTime()-u.getTimezoneOffset()*6e4);i(o,f.toISOString().substring(0,10))}}})},df=W.rankWith(5,W.isDateControl),pf=_e.withJsonFormsControlProps(BA),UA=e=>{const{description:t,errors:r,data:n,handleChange:i,path:o,label:a,required:s,enabled:l}=e;return d.jsx(Xt.DateTimePicker,{valueFormat:"DD.MM.YYYY HH:mm",disabled:!l,label:a,description:t,error:r,required:s,value:n?new Date(n):null,onChange:u=>{if(u instanceof Date){const f=new Date(u);i(o,f.toISOString())}}})},hf=W.rankWith(5,W.isDateTimeControl),mf=_e.withJsonFormsControlProps(UA),VA=e=>d.jsx(In,{...e}),gf=W.rankWith(3,W.isNumberControl),yf=_e.withJsonFormsControlProps(VA),WA=e=>d.jsx(In,{...e}),vf=W.rankWith(3,W.isIntegerControl),bf=_e.withJsonFormsControlProps(WA),HA=e=>d.jsx(au,{...e}),xf=W.rankWith(3,W.isStringControl),Tf=_e.withJsonFormsControlProps(HA),GA=e=>d.jsx(su,{...e}),_f=W.rankWith(3,W.isBooleanControl),Ef=_e.withJsonFormsControlProps(GA),YA=({data:e,options:t,handleChange:r,path:n,...i})=>{const{description:o,errors:a,label:s,required:l,enabled:u}=i;return d.jsx(b.Select,{disabled:!u,data:t,value:e||null,label:s,description:o,required:l,error:a,searchable:!0,onChange:f=>{r(n,f)}})},Sf=W.rankWith(5,W.isEnumControl),Cf=_e.withJsonFormsEnumProps(_e.withTranslateProps(_.memo(YA)),!1),qA=e=>{const{text:t,visible:r}=e;return r?d.jsx(b.Title,{fw:"bold",size:"xl",children:t}):null},KA=W.rankWith(3,W.isLabelable),XA=_e.withJsonFormsLabelProps(qA),wf=W.rankWith(5,W.uiTypeIs("HorizontalLayout")),JA=({uischema:e,renderers:t,cells:r,schema:n,path:i,enabled:o})=>{const s={elements:e.elements,schema:n,path:i,enabled:o,direction:"row"};return d.jsx(jo,{...s,renderers:t,cells:r})},Af=_e.withJsonFormsLayoutProps(JA),Of=W.rankWith(5,W.uiTypeIs("VerticalLayout")),ZA=({uischema:e,schema:t,path:r,enabled:n,renderers:i,cells:o})=>{const s={elements:e.elements,schema:t,path:r,enabled:n,direction:"column"};return d.jsx(jo,{...s,renderers:i,cells:o})},kf=_e.withJsonFormsLayoutProps(ZA),QA=[{tester:df,renderer:pf},{tester:hf,renderer:mf},{tester:gf,renderer:yf},{tester:vf,renderer:bf},{tester:xf,renderer:Tf},{tester:_f,renderer:Ef},{tester:Sf,renderer:Cf},{tester:lf,renderer:uf},{tester:cf,renderer:ff},{tester:wf,renderer:Af},{tester:Of,renderer:kf},{tester:KA,renderer:XA}],eO=[{tester:du,cell:pu},{tester:lu,cell:uu},{tester:cu,cell:fu},{tester:hu,cell:mu},{tester:gu,cell:yu},{tester:vu,cell:bu},{tester:xu,cell:Tu}],fa={iconSmall:"_iconSmall_sxv3z_1",iconLarge:"_iconLarge_sxv3z_6",btn:"_btn_sxv3z_17"};function tO({basePath:e="/security",Target:t,children:r}){const n=Ft.useNavigate(),{user:i,signout:o}=Wa(),[a,s]=_.useState(!1),u=[{resource_name:e+"/users",label:"Users",name:"UsersApi",Icon:ep},{resource_name:e+"/roles",label:"Roles",name:"RolesApi",Icon:Jd},{resource_name:e+"/permissions",label:"Base Permissions",name:"PermissionsApi",Icon:Za},{resource_name:e+"/permissionviews",label:"Permission on Views",name:"PermissionViewApi",Icon:Za},{resource_name:e+"/viewsmenus",label:"Views/Menus",name:"ViewsMenusApi",Icon:Yd}].filter(f=>i.permissions.includes(f.name));return d.jsxs(b.Menu,{width:260,position:"bottom-end",transition:"pop-top-right",withinPortal:!0,opened:a,onClose:()=>s(!1),onOpen:()=>s(!0),children:[d.jsx(b.Menu.Target,{children:t||d.jsx(b.UnstyledButton,{className:fa.btn,style:{borderRadius:4},p:"xs",children:d.jsxs(b.Group,{style:{flexWrap:"nowrap"},spacing:7,children:[d.jsx(b.Text,{weight:500,size:"sm",style:{lineHeight:1,whiteSpace:"nowrap"},mr:3,children:`${i.first_name} ${i.last_name}`}),d.jsx(Hi,{size:12})]})})}),d.jsxs(b.Menu.Dropdown,{children:[u.length?d.jsxs(d.Fragment,{children:[d.jsx(b.Menu.Label,{children:"Security"}),u.map((f,c)=>d.jsx(b.Menu.Item,{p:12,leftSection:d.jsx(f.Icon,{className:fa.iconSmall}),onClick:()=>n(f.resource_name),children:f.label},c)),d.jsx(b.Menu.Divider,{})]}):null,r,d.jsx(b.Menu.Item,{leftSection:d.jsx(Zd,{p:12,className:fa.iconSmall}),onClick:o,children:"Logout"})]})]})}I.Actions=fs,I.Add=es,I.AddDialog=Ka,I.ApiProvider=Ga,I.DataGrid=xo,I.Delete=cs,I.DeleteDialog=sf,I.Edit=us,I.EditDialog=ls,I.Filter=rs,I.FilterMenu=ts,I.InfiniteScroll=Bh,I.MantineArrayControlRenderer=uf,I.MantineBooleanCell=mu,I.MantineBooleanControl=Ef,I.MantineDateCell=yu,I.MantineDateControl=pf,I.MantineDateTimeCell=bu,I.MantineDateTimeControl=mf,I.MantineEnumArrayRenderer=ff,I.MantineEnumCell=Tu,I.MantineEnumControl=Cf,I.MantineHorizontalLayoutRenderer=Af,I.MantineIntegerCell=fu,I.MantineIntegerControl=bf,I.MantineLayoutRenderer=jo,I.MantineNumberCell=uu,I.MantineNumberControl=yf,I.MantineTableControl=af,I.MantineTextCell=pu,I.MantineTextControl=Tf,I.MantineVerticalLayoutRenderer=kf,I.NoBorderTableCell=mr,I.NonEmptyRow=of,I.Provider=Dd,I.UserMenu=tO,I.mantineArrayControlTester=lf,I.mantineBooleanCellTester=hu,I.mantineBooleanControlTester=_f,I.mantineCells=eO,I.mantineDateCellTester=gu,I.mantineDateControlTester=df,I.mantineDateTimeCellTester=vu,I.mantineDateTimeControlTester=hf,I.mantineEnumArrayRendererTester=cf,I.mantineEnumCellTester=xu,I.mantineEnumControlTester=Sf,I.mantineHorizontalLayoutTester=wf,I.mantineIntegerCellTester=cu,I.mantineIntegerControlTester=vf,I.mantineNumberCellTester=lu,I.mantineNumberControlTester=gf,I.mantineRenderers=QA,I.mantineTextCellTester=du,I.mantineTextControlTester=xf,I.mantineVerticalLayoutTester=Of,I.renderLayoutElements=Ol,I.useApi=De,I.useAuth=Wa,I.useAuthenticate=ga,I.useBulkActions=Ld,I.useCustomFetch=Xr,I.useDebouncedChange=Dl,I.useGetList=ya,I.useInfo=Ha,I.useInfo_=Ua,I.withAjvProps=Fy,Object.defineProperty(I,Symbol.toStringTag,{value:"Module"})});
|