@ukpc-lib/react 0.13.1-sandbox.saas-8516 → 0.13.1-sandbox.saas-8516-p3
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/components/index.cjs +1 -1
- package/dist/components/index.js +2 -2
- package/dist/{index.esm2017-CFH-ljHI.cjs → index.esm2017-5ZwUVFAV.cjs} +1 -1
- package/dist/{index.esm2017-C7IPAfyC.js → index.esm2017-DUxPJxVH.js} +20 -5
- package/dist/share/index.cjs +1 -1
- package/dist/share/index.js +1 -1
- package/package.json +1 -1
- package/web-components-bundle/access-denied/index.js +2 -2
- package/web-components-bundle/base-breadcrumbs/index.js +2 -2
- package/web-components-bundle/favorite-menu/index.js +4 -4
- package/web-components-bundle/global-menu/index.js +4 -4
- package/web-components-bundle/global-topbar/index.js +6 -6
- package/web-components-bundle/has-permission/index.js +3 -3
- package/web-components-bundle/{index-B4uOLjGK.js → index-CI-NA37P.js} +1 -1
- package/web-components-bundle/{index-B_Ae1FHp.js → index-CjGg-DF7.js} +8950 -8938
- package/web-components-bundle/{index-BSe1av43.js → index-Cx0zTfOC.js} +1 -1
- package/web-components-bundle/{index-BTy-Dpix.js → index-DE6E5mlm.js} +536 -536
- package/web-components-bundle/page-not-found/index.js +2 -2
- package/web-components-bundle/{react-to-web-component-CXwKHjZr.js → react-to-web-component-D7SoYMky.js} +1535 -1527
- package/web-components-bundle/{react-toastify.esm-CrTD7cpE.js → react-toastify.esm-Y1WvK90L.js} +1 -1
- package/web-components-bundle/toast-config/index.js +2 -2
- package/web-components-bundle/toast-config-notification/index.js +2 -2
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("react/jsx-runtime"),T=require("react"),m=require("../index.esm2017-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("react/jsx-runtime"),T=require("react"),m=require("../index.esm2017-5ZwUVFAV.cjs"),X=require("moment"),N=require("@mui/material");require("axios");require("@r2wc/react-to-web-component");const mn=require("react-router-dom");require("react-query");require("react-dom");function $o(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const A=$o(T),Ao=e=>{var r,o;const{tabs:t}=e,n=s=>{e.setCurrentTab(s.target.id)};return console.log("🚀 ~ brandColors:",e.currentTab),l.jsxs(l.Fragment,{children:[l.jsx("style",{children:`
|
|
2
2
|
.tab-title {
|
|
3
3
|
min-width: 90px;
|
|
4
4
|
padding: 5px 16px;
|
package/dist/components/index.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import ii, { jsxs as M, Fragment as le, jsx as u } from "react/jsx-runtime";
|
|
2
2
|
import * as N from "react";
|
|
3
3
|
import ye, { useState as W, useContext as $e, useEffect as q, useRef as Se, useCallback as Mt, forwardRef as ai, createElement as sr, PureComponent as si } from "react";
|
|
4
|
-
import { c as ne, a as gt, C as Le, t as ct, p as li, L as Xr, u as ci, b as ui, S as qn, d as di, e as fi, Q as Zn, f as Et, g as Xn, h as hi, s as Ct, _ as B, P as R, i as pe, j as mi, o as pi, k as Ne, l as gi, m as yi, n as Jr, q as Ot, r as Qr, I as vi, v as bi, w as en, D as xi, x as Jn, y as Qn, z as Si, A as wi, B as _i } from "../index.esm2017-
|
|
5
|
-
import { H as au, G as su, K as lu, E as cu, F as uu, J as du } from "../index.esm2017-
|
|
4
|
+
import { c as ne, a as gt, C as Le, t as ct, p as li, L as Xr, u as ci, b as ui, S as qn, d as di, e as fi, Q as Zn, f as Et, g as Xn, h as hi, s as Ct, _ as B, P as R, i as pe, j as mi, o as pi, k as Ne, l as gi, m as yi, n as Jr, q as Ot, r as Qr, I as vi, v as bi, w as en, D as xi, x as Jn, y as Qn, z as Si, A as wi, B as _i } from "../index.esm2017-DUxPJxVH.js";
|
|
5
|
+
import { H as au, G as su, K as lu, E as cu, F as uu, J as du } from "../index.esm2017-DUxPJxVH.js";
|
|
6
6
|
import Q from "moment";
|
|
7
7
|
import { Stack as me, Dialog as Ei, DialogTitle as Ci, Typography as Ce, DialogContent as Ti, DialogActions as Ii, Button as pr, Box as ki, ClickAwayListener as Mi, TextField as eo, IconButton as Oi, CircularProgress as $i, Fade as Ai, Paper as Ni, Checkbox as Ri, Breadcrumbs as Pi } from "@mui/material";
|
|
8
8
|
import "axios";
|
|
@@ -133,7 +133,7 @@ Previous: %s
|
|
|
133
133
|
Incoming: %s`,Ki,"["+v.join(", ")+"]","["+l.join(", ")+"]");for(var d=0;d<l.length&&d<v.length;d++)if(!qt(v[d],l[d]))return!1;return!0}function $u(){if(So>0)throw new Error("Rendered more hooks than during the previous render");return{memoizedState:null,queue:null,next:null}}function xi(){return Zt===null?Ws===null?(hs=!1,Ws=Zt=$u()):(hs=!0,Zt=Ws):Zt.next===null?(hs=!1,Zt=Zt.next=$u()):(hs=!0,Zt=Zt.next),Zt}function Vu(v,l){bi=l,Sa=v,$r=!1,ti=0}function Ys(v,l,d,g){for(;tl;)tl=!1,ti=0,So+=1,Zt=null,d=v(l,g);return Hu(),d}function Vr(){var v=ti!==0;return v}function Hu(){$r=!1,bi=null,Sa=null,tl=!1,Ws=null,So=0,wi=null,Zt=null}function Uu(v){return $r&&i("Context can only be read while React is rendering. In classes, you can read it in the render method or getDerivedStateFromProps. In function components, you can read it directly in the function body, but not inside Hooks like useReducer() or useMemo()."),xa(v)}function Wu(v){return Ki="useContext",zs(),xa(v)}function Gs(v,l){return typeof l=="function"?l(v):l}function ps(v){return Ki="useState",zu(Gs,v)}function zu(v,l,d){if(v!==Gs&&(Ki="useReducer"),bi=zs(),Zt=xi(),hs){var g=Zt.queue,x=g.dispatch;if(wi!==null){var R=wi.get(g);if(R!==void 0){wi.delete(g);var B=Zt.memoizedState,z=R;do{var re=z.action;$r=!0,B=v(B,re),$r=!1,z=z.next}while(z!==null);return Zt.memoizedState=B,[B,x]}}return[Zt.memoizedState,x]}else{$r=!0;var we;v===Gs?we=typeof l=="function"?l():l:we=d!==void 0?d(l):l,$r=!1,Zt.memoizedState=we;var je=Zt.queue={last:null,dispatch:null},Ye=je.dispatch=Vc.bind(null,bi,je);return[Zt.memoizedState,Ye]}}function $c(v,l){bi=zs(),Zt=xi();var d=l===void 0?null:l;if(Zt!==null){var g=Zt.memoizedState;if(g!==null&&d!==null){var x=g[1];if(Bc(d,x))return g[0]}}$r=!0;var R=v();return $r=!1,Zt.memoizedState=[R,d],R}function $l(v){bi=zs(),Zt=xi();var l=Zt.memoizedState;if(l===null){var d={current:v};return Object.seal(d),Zt.memoizedState=d,d}else return l}function Gf(v,l){Ki="useLayoutEffect",i("useLayoutEffect does nothing on the server, because its effect cannot be encoded into the server renderer's output format. This will lead to a mismatch between the initial, non-hydrated UI and the intended UI. To avoid this, useLayoutEffect should only be used in components that render exclusively on the client. See https://reactjs.org/link/uselayouteffect-ssr for common fixes.")}function Vc(v,l,d){if(So>=Bu)throw new Error("Too many re-renders. React limits the number of renders to prevent an infinite loop.");if(v===bi){tl=!0;var g={action:d,next:null};wi===null&&(wi=new Map);var x=wi.get(l);if(x===void 0)wi.set(l,g);else{for(var R=x;R.next!==null;)R=R.next;R.next=g}}}function fr(v,l){return $c(function(){return v},l)}function Yu(v,l,d){return zs(),l(v._source)}function Hc(v,l,d){if(d===void 0)throw new Error("Missing getServerSnapshot, which is required for server-rendered content. Will revert to client rendering.");return d()}function Si(v){return zs(),v}function Vl(){throw new Error("startTransition cannot be called during server rendering.")}function Ta(){return zs(),[!1,Vl]}function gs(){var v=Sa,l=Ho(v.treeContext),d=qs;if(d===null)throw new Error("Invalid hook call. Hooks can only be called inside of the body of a function component.");var g=ti++;return jn(d,l,g)}function nl(){}var rr={readContext:Uu,useContext:Wu,useMemo:$c,useReducer:zu,useRef:$l,useState:ps,useInsertionEffect:nl,useLayoutEffect:Gf,useCallback:fr,useImperativeHandle:nl,useEffect:nl,useDebugValue:nl,useDeferredValue:Si,useTransition:Ta,useId:gs,useMutableSource:Yu,useSyncExternalStore:Hc},qs=null;function Hl(v){qs=v}function Ca(v){try{var l="",d=v;do{switch(d.tag){case 0:l+=Xi(d.type,null,null);break;case 1:l+=ma(d.type,null,null);break;case 2:l+=Ic(d.type,null,null);break}d=d.parent}while(d);return l}catch(g){return`
|
|
134
134
|
Error generating stack: `+g.message+`
|
|
135
135
|
`+g.stack}}var Ul=n.ReactCurrentDispatcher,Ea=n.ReactDebugCurrentFrame,Wl=0,To=1,zl=2,Xs=3,Uc=4,rl=0,ka=1,Da=2,Gu=12800;function Wc(v){return console.error(v),null}function Ks(){}function Yl(v,l,d,g,x,R,B,z,re){var we=[],je=new Set,Ye={destination:null,responseState:l,progressiveChunkSize:g===void 0?Gu:g,status:rl,fatalError:null,nextSegmentId:0,allPendingTasks:0,pendingRootTasks:0,completedRootSegment:null,abortableTasks:je,pingedTasks:we,clientRenderedBoundaries:[],completedBoundaries:[],partialBoundaries:[],onError:x===void 0?Wc:x,onAllReady:R===void 0?Ks:R,onShellReady:B===void 0?Ks:B,onShellError:z===void 0?Ks:z,onFatalError:re===void 0?Ks:re},nt=il(Ye,0,null,d,!1,!1);nt.parentFlushed=!0;var xt=Wo(Ye,v,null,nt,je,Gn,Ll,Uf);return we.push(xt),Ye}function Uo(v,l){var d=v.pingedTasks;d.push(l),d.length===1&&a(function(){return ec(v)})}function Gl(v,l){return{id:_i,rootSegmentID:-1,parentFlushed:!1,pendingTasks:0,forceClientRender:!1,completedSegments:[],byteSize:0,fallbackAbortableTasks:l,errorDigest:null}}function Wo(v,l,d,g,x,R,B,z){v.allPendingTasks++,d===null?v.pendingRootTasks++:d.pendingTasks++;var re={node:l,ping:function(){return Uo(v,re)},blockedBoundary:d,blockedSegment:g,abortSet:x,legacyContext:R,context:B,treeContext:z};return re.componentStack=null,x.add(re),re}function il(v,l,d,g,x,R){return{status:Wl,id:-1,index:l,parentFlushed:!1,chunks:[],children:[],formatContext:g,boundary:d,lastPushedText:x,textEmbedded:R}}var Zi=null;function Ji(){return Zi===null||Zi.componentStack===null?"":Ca(Zi.componentStack)}function Co(v,l){v.componentStack={tag:0,parent:v.componentStack,type:l}}function ol(v,l){v.componentStack={tag:1,parent:v.componentStack,type:l}}function ms(v,l){v.componentStack={tag:2,parent:v.componentStack,type:l}}function Qi(v){v.componentStack===null?i("Unexpectedly popped too many stack frames. This is a bug in React."):v.componentStack=v.componentStack.parent}var Pa=null;function ql(v,l){{var d;typeof l=="string"?d=l:l&&typeof l.message=="string"?d=l.message:d=String(l);var g=Pa||Ji();Pa=null,v.errorMessage=d,v.errorComponentStack=g}}function sl(v,l){var d=v.onError(l);if(d!=null&&typeof d!="string")throw new Error('onError returned something with a type other than "string". onError should return a string and may return null or undefined but must not return anything else. It received something of type "'+typeof d+'" instead');return d}function Oa(v,l){var d=v.onShellError;d(l);var g=v.onFatalError;g(l),v.destination!==null?(v.status=Da,H(v.destination,l)):(v.status=ka,v.fatalError=l)}function zc(v,l,d){Co(l,"Suspense");var g=l.blockedBoundary,x=l.blockedSegment,R=d.fallback,B=d.children,z=new Set,re=Gl(v,z),we=x.chunks.length,je=il(v,we,re,x.formatContext,!1,!1);x.children.push(je),x.lastPushedText=!1;var Ye=il(v,0,null,x.formatContext,!1,!1);Ye.parentFlushed=!0,l.blockedBoundary=re,l.blockedSegment=Ye;try{if(Ti(v,l,B),_n(Ye.chunks,v.responseState,Ye.lastPushedText,Ye.textEmbedded),Ye.status=To,bs(re,Ye),re.pendingTasks===0){Qi(l);return}}catch(xt){Ye.status=Uc,re.forceClientRender=!0,re.errorDigest=sl(v,xt),ql(re,xt)}finally{l.blockedBoundary=g,l.blockedSegment=x}var nt=Wo(v,R,g,je,z,l.legacyContext,l.context,l.treeContext);nt.componentStack=l.componentStack,v.pingedTasks.push(nt),Qi(l)}function qu(v,l,d,g){Co(l,d);var x=l.blockedSegment,R=co(x.chunks,d,g,v.responseState,x.formatContext);x.lastPushedText=!1;var B=x.formatContext;x.formatContext=pi(B,d,g),Ti(v,l,R),x.formatContext=B,Mo(x.chunks,d),x.lastPushedText=!1,Qi(l)}function Xu(v){return v.prototype&&v.prototype.isReactComponent}function Zs(v,l,d,g,x){var R={};Vu(l,R);var B=d(g,x);return Ys(d,g,B,x)}function Ku(v,l,d,g,x){var R=d.render();d.props!==x&&(Kl||i("It looks like %s is reassigning its own `this.props` while rendering. This is not supported and can lead to confusing bugs.",pn(g)||"a component"),Kl=!0);{var B=g.childContextTypes;if(B!=null){var z=l.legacyContext,re=Iu(d,g,z,B);l.legacyContext=re,dr(v,l,R),l.legacyContext=z;return}}dr(v,l,R)}function Xl(v,l,d,g){ms(l,d);var x=ls(d,l.legacyContext),R=xo(d,g,x);el(R,d,g,x),Ku(v,l,R,d,g),Qi(l)}var Bt={},al={},Zu={},Js={},Kl=!1,Yc={},Gc=!1,ni=!1,qc=!1;function Zl(v,l,d,g){var x;if(x=ls(d,l.legacyContext),ol(l,d),d.prototype&&typeof d.prototype.render=="function"){var R=pn(d)||"Unknown";Bt[R]||(i("The <%s /> component appears to have a render method, but doesn't extend React.Component. This is likely to cause errors. Change %s to extend React.Component instead.",R,R),Bt[R]=!0)}var B=Zs(v,l,d,g,x),z=Vr();if(typeof B=="object"&&B!==null&&typeof B.render=="function"&&B.$$typeof===void 0){var re=pn(d)||"Unknown";al[re]||(i("The <%s /> component appears to be a function component that returns a class instance. Change %s to a class that extends React.Component instead. If you can't use a class try assigning the prototype on the function as a workaround. `%s.prototype = React.Component.prototype`. Don't use an arrow function since it cannot be called with `new` by React.",re,re,re),al[re]=!0)}if(typeof B=="object"&&B!==null&&typeof B.render=="function"&&B.$$typeof===void 0){{var we=pn(d)||"Unknown";al[we]||(i("The <%s /> component appears to be a function component that returns a class instance. Change %s to a class that extends React.Component instead. If you can't use a class try assigning the prototype on the function as a workaround. `%s.prototype = React.Component.prototype`. Don't use an arrow function since it cannot be called with `new` by React.",we,we,we),al[we]=!0)}el(B,d,g,x),Ku(v,l,B,d,g)}else if(Ju(d),z){var je=l.treeContext,Ye=1,nt=0;l.treeContext=Nu(je,Ye,nt);try{dr(v,l,B)}finally{l.treeContext=je}}else dr(v,l,B);Qi(l)}function Ju(v){{if(v&&v.childContextTypes&&i("%s(...): childContextTypes cannot be defined on a function component.",v.displayName||v.name||"Component"),v.defaultProps!==void 0){var l=pn(v)||"Unknown";Yc[l]||(i("%s: Support for defaultProps will be removed from function components in a future major release. Use JavaScript default parameters instead.",l),Yc[l]=!0)}if(typeof v.getDerivedStateFromProps=="function"){var d=pn(v)||"Unknown";Js[d]||(i("%s: Function components do not support getDerivedStateFromProps.",d),Js[d]=!0)}if(typeof v.contextType=="object"&&v.contextType!==null){var g=pn(v)||"Unknown";Zu[g]||(i("%s: Function components do not support contextType.",g),Zu[g]=!0)}}}function Qu(v,l){if(v&&v.defaultProps){var d=J({},l),g=v.defaultProps;for(var x in g)d[x]===void 0&&(d[x]=g[x]);return d}return l}function Xc(v,l,d,g,x){ol(l,d.render);var R=Zs(v,l,d.render,g,x),B=Vr();if(B){var z=l.treeContext,re=1,we=0;l.treeContext=Nu(z,re,we);try{dr(v,l,R)}finally{l.treeContext=z}}else dr(v,l,R);Qi(l)}function Hr(v,l,d,g,x){var R=d.type,B=Qu(R,g);Qs(v,l,R,B,x)}function vs(v,l,d,g){d._context===void 0?d!==d.Consumer&&(qc||(qc=!0,i("Rendering <Context> directly is not supported and will be removed in a future major release. Did you mean to render <Context.Consumer> instead?"))):d=d._context;var x=g.children;typeof x!="function"&&i("A context consumer was rendered with multiple children, or a child that isn't a function. A context consumer expects a single child that is a function. If you did pass a function, make sure there is no trailing or leading whitespace around it.");var R=xa(d),B=x(R);dr(v,l,B)}function Ur(v,l,d,g){var x=d._context,R=g.value,B=g.children,z;z=l.context,l.context=Mu(x,R),dr(v,l,B),l.context=Bf(x),z!==l.context&&i("Popping the context provider did not return back to the original snapshot. This is a bug in React.")}function Kc(v,l,d,g,x){Co(l,"Lazy");var R=d._payload,B=d._init,z=B(R),re=Qu(z,g);Qs(v,l,z,re,x),Qi(l)}function Qs(v,l,d,g,x){if(typeof d=="function")if(Xu(d)){Xl(v,l,d,g);return}else{Zl(v,l,d,g);return}if(typeof d=="string"){qu(v,l,d,g);return}switch(d){case Yn:case Vt:case K:case le:case Ee:{dr(v,l,g.children);return}case lt:{Co(l,"SuspenseList"),dr(v,l,g.children),Qi(l);return}case wt:throw new Error("ReactDOMServer does not yet support scope components.");case st:{zc(v,l,g);return}}if(typeof d=="object"&&d!==null)switch(d.$$typeof){case Fe:{Xc(v,l,d,g,x);return}case rt:{Hr(v,l,d,g,x);return}case se:{Ur(v,l,d,g);return}case Ae:{vs(v,l,d,g);return}case It:{Kc(v,l,d,g);return}}var R="";throw(d===void 0||typeof d=="object"&&d!==null&&Object.keys(d).length===0)&&(R+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports."),new Error("Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) "+("but got: "+(d==null?d:typeof d)+"."+R))}function Zc(v,l){typeof Symbol=="function"&&v[Symbol.toStringTag]==="Generator"&&(Gc||i("Using Generators as children is unsupported and will likely yield unexpected results because enumerating a generator mutates it. You may convert it to an array with `Array.from()` or the `[...spread]` operator before rendering. Keep in mind you might need to polyfill these features for older browsers."),Gc=!0),v.entries===l&&(ni||i("Using Maps as children is not supported. Use an array of keyed ReactElements instead."),ni=!0)}function dr(v,l,d){try{return Jc(v,l,d)}catch(g){throw typeof g=="object"&&g!==null&&typeof g.then=="function"||(Pa=Pa!==null?Pa:Ji()),g}}function Jc(v,l,d){if(l.node=d,typeof d=="object"&&d!==null){switch(d.$$typeof){case fe:{var g=d,x=g.type,R=g.props,B=g.ref;Qs(v,l,x,R,B);return}case Se:throw new Error("Portals are not currently supported by the server renderer. Render them conditionally so that they only appear on the client render.");case It:{var z=d,re=z._payload,we=z._init,je;try{je=we(re)}catch(eo){throw typeof eo=="object"&&eo!==null&&typeof eo.then=="function"&&Co(l,"Lazy"),eo}dr(v,l,je);return}}if(er(d)){Jl(v,l,d);return}var Ye=jr(d);if(Ye){Zc(d,Ye);var nt=Ye.call(d);if(nt){var xt=nt.next();if(!xt.done){var en=[];do en.push(xt.value),xt=nt.next();while(!xt.done);Jl(v,l,en);return}return}}var ir=Object.prototype.toString.call(d);throw new Error("Objects are not valid as a React child (found: "+(ir==="[object Object]"?"object with keys {"+Object.keys(d).join(", ")+"}":ir)+"). If you meant to render a collection of children, use an array instead.")}if(typeof d=="string"){var Eo=l.blockedSegment;Eo.lastPushedText=On(l.blockedSegment.chunks,d,v.responseState,Eo.lastPushedText);return}if(typeof d=="number"){var ws=l.blockedSegment;ws.lastPushedText=On(l.blockedSegment.chunks,""+d,v.responseState,ws.lastPushedText);return}typeof d=="function"&&i("Functions are not valid as a React child. This may happen if you return a Component instead of <Component /> from render. Or maybe you meant to call this function rather than return it.")}function Jl(v,l,d){for(var g=d.length,x=0;x<g;x++){var R=l.treeContext;l.treeContext=Nu(R,g,x);try{Ti(v,l,d[x])}finally{l.treeContext=R}}}function Ql(v,l,d){var g=l.blockedSegment,x=g.chunks.length,R=il(v,x,null,g.formatContext,g.lastPushedText,!0);g.children.push(R),g.lastPushedText=!1;var B=Wo(v,l.node,l.blockedBoundary,R,l.abortSet,l.legacyContext,l.context,l.treeContext);l.componentStack!==null&&(B.componentStack=l.componentStack.parent);var z=B.ping;d.then(z,z)}function Ti(v,l,d){var g=l.blockedSegment.formatContext,x=l.legacyContext,R=l.context,B=null;B=l.componentStack;try{return dr(v,l,d)}catch(z){if(Hu(),typeof z=="object"&&z!==null&&typeof z.then=="function"){Ql(v,l,z),l.blockedSegment.formatContext=g,l.legacyContext=x,l.context=R,fs(R),l.componentStack=B;return}else throw l.blockedSegment.formatContext=g,l.legacyContext=x,l.context=R,fs(R),l.componentStack=B,z}}function Qc(v,l,d,g){var x=sl(v,g);if(l===null?Oa(v,g):(l.pendingTasks--,l.forceClientRender||(l.forceClientRender=!0,l.errorDigest=x,ql(l,g),l.parentFlushed&&v.clientRenderedBoundaries.push(l))),v.allPendingTasks--,v.allPendingTasks===0){var R=v.onAllReady;R()}}function ys(v){var l=this,d=v.blockedBoundary,g=v.blockedSegment;g.status=Xs,ea(l,d,g)}function eu(v,l,d){var g=v.blockedBoundary,x=v.blockedSegment;if(x.status=Xs,g===null)l.allPendingTasks--,l.status!==Da&&(l.status=Da,l.destination!==null&&A(l.destination));else{if(g.pendingTasks--,!g.forceClientRender){g.forceClientRender=!0;var R=d===void 0?new Error("The render was aborted by the server without a reason."):d;g.errorDigest=l.onError(R);{var B="The server did not finish this Suspense boundary: ";R&&typeof R.message=="string"?R=B+R.message:R=B+String(R);var z=Zi;Zi=v;try{ql(g,R)}finally{Zi=z}}g.parentFlushed&&l.clientRenderedBoundaries.push(g)}if(g.fallbackAbortableTasks.forEach(function(we){return eu(we,l,d)}),g.fallbackAbortableTasks.clear(),l.allPendingTasks--,l.allPendingTasks===0){var re=l.onAllReady;re()}}}function bs(v,l){if(l.chunks.length===0&&l.children.length===1&&l.children[0].boundary===null){var d=l.children[0];d.id=l.id,d.parentFlushed=!0,d.status===To&&bs(v,d)}else{var g=v.completedSegments;g.push(l)}}function ea(v,l,d){if(l===null){if(d.parentFlushed){if(v.completedRootSegment!==null)throw new Error("There can only be one root segment. This is a bug in React.");v.completedRootSegment=d}if(v.pendingRootTasks--,v.pendingRootTasks===0){v.onShellError=Ks;var g=v.onShellReady;g()}}else if(l.pendingTasks--,!l.forceClientRender){if(l.pendingTasks===0)d.parentFlushed&&d.status===To&&bs(l,d),l.parentFlushed&&v.completedBoundaries.push(l),l.fallbackAbortableTasks.forEach(ys,v),l.fallbackAbortableTasks.clear();else if(d.parentFlushed&&d.status===To){bs(l,d);var x=l.completedSegments;x.length===1&&l.parentFlushed&&v.partialBoundaries.push(l)}}if(v.allPendingTasks--,v.allPendingTasks===0){var R=v.onAllReady;R()}}function qf(v,l){var d=l.blockedSegment;if(d.status===Wl){fs(l.context);var g=null;g=Zi,Zi=l;try{dr(v,l,l.node),_n(d.chunks,v.responseState,d.lastPushedText,d.textEmbedded),l.abortSet.delete(l),d.status=To,ea(v,l.blockedBoundary,d)}catch(R){if(Hu(),typeof R=="object"&&R!==null&&typeof R.then=="function"){var x=l.ping;R.then(x,x)}else l.abortSet.delete(l),d.status=Uc,Qc(v,l.blockedBoundary,d,R)}finally{Zi=g}}}function ec(v){if(v.status!==Da){var l=Lc(),d=Ul.current;Ul.current=rr;var g;g=Ea.getCurrentStack,Ea.getCurrentStack=Ji;var x=qs;Hl(v.responseState);try{var R=v.pingedTasks,B;for(B=0;B<R.length;B++){var z=R[B];qf(v,z)}R.splice(0,B),v.destination!==null&&Ii(v,v.destination)}catch(re){sl(v,re),Oa(v,re)}finally{Hl(x),Ul.current=d,Ea.getCurrentStack=g,d===rr&&fs(l)}}}function ll(v,l,d){switch(d.parentFlushed=!0,d.status){case Wl:{var g=d.id=v.nextSegmentId++;return d.lastPushedText=!1,d.textEmbedded=!1,cr(l,v.responseState,g)}case To:{d.status=zl;for(var x=!0,R=d.chunks,B=0,z=d.children,re=0;re<z.length;re++){for(var we=z[re];B<we.index;B++)m(l,R[B]);x=ul(v,l,we)}for(;B<R.length-1;B++)m(l,R[B]);return B<R.length&&(x=T(l,R[B])),x}default:throw new Error("Aborted, errored or already flushed boundaries should not be flushed again. This is a bug in React.")}}function ul(v,l,d){var g=d.boundary;if(g===null)return ll(v,l,d);if(g.parentFlushed=!0,g.forceClientRender)return Be(l,v.responseState,g.errorDigest,g.errorMessage,g.errorComponentStack),ll(v,l,d),Et(l,v.responseState);if(g.pendingTasks>0){g.rootSegmentID=v.nextSegmentId++,g.completedSegments.length>0&&v.partialBoundaries.push(g);var x=g.id=nn(v.responseState);return xe(l,v.responseState,x),ll(v,l,d),Tt(l,v.responseState)}else{if(g.byteSize>v.progressiveChunkSize)return g.rootSegmentID=v.nextSegmentId++,v.completedBoundaries.push(g),xe(l,v.responseState,g.id),ll(v,l,d),Tt(l,v.responseState);Re(l,v.responseState);var R=g.completedSegments;if(R.length!==1)throw new Error("A previously unvisited boundary must have exactly one root segment. This is a bug in React.");var B=R[0];return ul(v,l,B),it(l,v.responseState)}}function tc(v,l,d){return Rl(l,v.responseState,d.id,d.errorDigest,d.errorMessage,d.errorComponentStack)}function tu(v,l,d){return St(l,v.responseState,d.formatContext,d.id),ul(v,l,d),vt(l,d.formatContext)}function nc(v,l,d){for(var g=d.completedSegments,x=0;x<g.length;x++){var R=g[x];Wr(v,l,d,R)}return g.length=0,mo(l,v.responseState,d.id,d.rootSegmentID)}function ef(v,l,d){for(var g=d.completedSegments,x=0;x<g.length;x++){var R=g[x];if(!Wr(v,l,d,R))return x++,g.splice(0,x),!1}return g.splice(0,x),!0}function Wr(v,l,d,g){if(g.status===zl)return!0;var x=g.id;if(x===-1){var R=g.id=d.rootSegmentID;if(R===-1)throw new Error("A root segment ID must have been assigned by now. This is a bug in React.");return tu(v,l,g)}else return tu(v,l,g),za(l,v.responseState,x)}function Ii(v,l){b();try{var d=v.completedRootSegment;d!==null&&v.pendingRootTasks===0&&(ul(v,l,d),v.completedRootSegment=null,yi(l,v.responseState));var g=v.clientRenderedBoundaries,x;for(x=0;x<g.length;x++){var R=g[x];tc(v,l,R)}g.splice(0,x);var B=v.completedBoundaries;for(x=0;x<B.length;x++){var z=B[x];nc(v,l,z)}B.splice(0,x),E(l),b(l);var re=v.partialBoundaries;for(x=0;x<re.length;x++){var we=re[x];if(!ef(v,l,we)){v.destination=null,x++,re.splice(0,x);return}}re.splice(0,x);var je=v.completedBoundaries;for(x=0;x<je.length;x++){var Ye=je[x];nc(v,l,Ye)}je.splice(0,x)}finally{E(l),v.allPendingTasks===0&&v.pingedTasks.length===0&&v.clientRenderedBoundaries.length===0&&v.completedBoundaries.length===0&&(v.abortableTasks.size!==0&&i("There was still abortable task at the root when we closed. This is a bug in React."),A(l))}}function tf(v){a(function(){return ec(v)})}function Xf(v,l){if(v.status===ka){v.status=Da,H(l,v.fatalError);return}if(v.status!==Da&&v.destination===null){v.destination=l;try{Ii(v,l)}catch(d){sl(v,d),Oa(v,d)}}}function cl(v,l){try{var d=v.abortableTasks;d.forEach(function(g){return eu(g,v,l)}),d.clear(),v.destination!==null&&Ii(v,v.destination)}catch(g){sl(v,g),Oa(v,g)}}function _a(v,l){return new Promise(function(d,g){var x,R,B=new Promise(function(nt,xt){R=nt,x=xt});function z(){var nt=new ReadableStream({type:"bytes",pull:function(xt){Xf(we,xt)},cancel:function(xt){cl(we)}},{highWaterMark:0});nt.allReady=B,d(nt)}function re(nt){B.catch(function(){}),g(nt)}var we=Yl(v,Oi(l?l.identifierPrefix:void 0,l?l.nonce:void 0,l?l.bootstrapScriptContent:void 0,l?l.bootstrapScripts:void 0,l?l.bootstrapModules:void 0),hi(l?l.namespaceURI:void 0),l?l.progressiveChunkSize:void 0,l?l.onError:void 0,R,z,re,x);if(l&&l.signal){var je=l.signal,Ye=function(){cl(we,je.reason),je.removeEventListener("abort",Ye)};je.addEventListener("abort",Ye)}tf(we)})}Mh.renderToReadableStream=_a,Mh.version=e}()),Mh}var kc,Ev;process.env.NODE_ENV==="production"?(kc=M4(),Ev=L4()):(kc=F4(),Ev=N4());kc.version;var j4=kc.renderToString;kc.renderToStaticMarkup;kc.renderToNodeStream;kc.renderToStaticNodeStream;Ev.renderToReadableStream;var B4=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function BD(t,e){return t(e={exports:{}},e.exports),e.exports}var $4=BD(function(t){(function(e){var n=function(M,_,H){if(!f(_)||b(_)||m(_)||T(_)||c(_))return _;var Y,ne=0,Z=0;if(p(_))for(Y=[],Z=_.length;ne<Z;ne++)Y.push(n(M,_[ne],H));else for(var ce in Y={},_)Object.prototype.hasOwnProperty.call(_,ce)&&(Y[M(ce,H)]=n(M,_[ce],H));return Y},r=function(M){return E(M)?M:(M=M.replace(/[\-_\s]+(.)?/g,function(_,H){return H?H.toUpperCase():""})).substr(0,1).toLowerCase()+M.substr(1)},i=function(M){var _=r(M);return _.substr(0,1).toUpperCase()+_.substr(1)},o=function(M,_){return function(H,Y){var ne=(Y=Y||{}).separator||"_",Z=Y.split||/(?=[A-Z])/;return H.split(Z).join(ne)}(M,_).toLowerCase()},a=Object.prototype.toString,c=function(M){return typeof M=="function"},f=function(M){return M===Object(M)},p=function(M){return a.call(M)=="[object Array]"},b=function(M){return a.call(M)=="[object Date]"},m=function(M){return a.call(M)=="[object RegExp]"},T=function(M){return a.call(M)=="[object Boolean]"},E=function(M){return(M-=0)==M},A=function(M,_){var H=_&&"process"in _?_.process:_;return typeof H!="function"?M:function(Y,ne){return H(Y,M,ne)}},I={camelize:r,decamelize:o,pascalize:i,depascalize:o,camelizeKeys:function(M,_){return n(A(r,_),M)},decamelizeKeys:function(M,_){return n(A(o,_),M,_)},pascalizeKeys:function(M,_){return n(A(i,_),M)},depascalizeKeys:function(){return this.decamelizeKeys.apply(this,arguments)}};t.exports?t.exports=I:e.humps=I})(B4)}).decamelize,V4=function(t){if(Array.isArray(t))return t},H4=function(t,e){if(typeof Symbol<"u"&&Symbol.iterator in Object(t)){var n=[],r=!0,i=!1,o=void 0;try{for(var a,c=t[Symbol.iterator]();!(r=(a=c.next()).done)&&(n.push(a.value),!e||n.length!==e);r=!0);}catch(f){i=!0,o=f}finally{try{r||c.return==null||c.return()}finally{if(i)throw o}}return n}},S1=function(t,e){(e==null||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r},U4=function(t,e){if(t){if(typeof t=="string")return S1(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set"?Array.from(t):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?S1(t,e):void 0}},W4=function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
136
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)},z4=function(t,e){return V4(t)||H4(t,e)||U4(t,e)||W4()},$D=BD(function(t){function e(){return t.exports=e=Object.assign||function(n){for(var r=1;r<arguments.length;r++){var i=arguments[r];for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(n[o]=i[o])}return n},e.apply(this,arguments)}t.exports=e}),Y4=function(t,e){if(t==null)return{};var n,r,i={},o=Object.keys(t);for(r=0;r<o.length;r++)n=o[r],e.indexOf(n)>=0||(i[n]=t[n]);return i},VD=function(t,e){if(t==null)return{};var n,r,i=Y4(t,e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);for(r=0;r<o.length;r++)n=o[r],e.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i},G4=q.createContext(null);function HD(t){var e=t.children,n=e===void 0?"":e,r=VD(t,["children"]);return typeof n!="string"&&(n=j4(n)),q.createElement("template",$D({},r,{dangerouslySetInnerHTML:{__html:n}}))}function UD(t){var e=t.root,n=t.children;return Fv.createPortal(n===void 0?null:n,e)}function q4(t){var e=q.forwardRef(function(n,r){var i,o,a=n.mode,c=a===void 0?"open":a,f=n.delegatesFocus,p=f!==void 0&&f,b=n.styleSheets,m=b===void 0?[]:b,T=n.ssr,E=T!==void 0&&T,A=n.children,I=VD(n,["mode","delegatesFocus","styleSheets","ssr","children"]),M=(o=q.useRef((i=r)&&i.current),q.useEffect(function(){i&&(i.current=o.current)},[i]),o),_=q.useState(null),H=z4(_,2),Y=H[0],ne=H[1],Z="node_".concat(c).concat(p);return q.useLayoutEffect(function(){if(M.current)try{if(typeof r=="function"&&r(M.current),E){var ce=M.current.shadowRoot;return void ne(ce)}var S=M.current.attachShadow({mode:c,delegatesFocus:p});m.length>0&&(S.adoptedStyleSheets=m),ne(S)}catch(ue){(function(ae){var Ge=ae.error,Le=ae.styleSheets,Me=ae.root;switch(Ge.name){case"NotSupportedError":Le.length>0&&(Me.adoptedStyleSheets=Le);break;default:throw Ge}})({error:ue,styleSheets:m,root:Y})}},[r,M,m]),q.createElement(q.Fragment,null,q.createElement(t.tag,$D({key:Z,ref:M},I),(Y||E)&&q.createElement(G4.Provider,{value:Y},E?q.createElement(HD,{shadowroot:c,shadowrootmode:c},t.render({root:Y,ssr:E,children:A})):q.createElement(UD,{root:Y},t.render({root:Y,ssr:E,children:A})))))});return e.propTypes={mode:_s.oneOf(["open","closed"]),delegatesFocus:_s.bool,styleSheets:_s.arrayOf(_s.instanceOf(globalThis.CSSStyleSheet)),ssr:_s.bool,children:_s.node},e}HD.propTypes={children:_s.oneOfType([_s.string,_s.node])},UD.propTypes={root:_s.object.isRequired,children:_s.node};var mm=new Map;function X4(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"core",n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:function(r){return r.children};return new Proxy(t,{get:function(r,i){var o=$4(i,{separator:"-"}),a="".concat(e,"-").concat(o);return mm.has(a)||mm.set(a,q4({tag:o,render:n})),mm.get(a)}})}var WD=X4();const K4=".app,.treeRoot{height:100%}.draggingSource{opacity:.3}.placeholderContainer{position:relative}.dropTarget{background-color:#8d878711}",Z4=".favorite-bar{position:sticky;top:64px;z-index:900;transition:transform .3s ease,opacity .3s ease;border-bottom:1px solid #ddd}.favorite-bar--hidden{transform:translateY(-100%);opacity:0}.favorite-bar--visible{transform:translateY(0);opacity:1}";var T1;(function(t){t.DragStart="dragStart",t.DragMove="dragMove",t.DragEnd="dragEnd",t.DragCancel="dragCancel",t.DragOver="dragOver",t.RegisterDroppable="registerDroppable",t.SetDroppableDisabled="setDroppableDisabled",t.UnregisterDroppable="unregisterDroppable"})(T1||(T1={}));const J4=Object.freeze({x:0,y:0});var Tf;(function(t){t[t.Forward=1]="Forward",t[t.Backward=-1]="Backward"})(Tf||(Tf={}));var C1;(function(t){t.Click="click",t.DragStart="dragstart",t.Keydown="keydown",t.ContextMenu="contextmenu",t.Resize="resize",t.SelectionChange="selectionchange",t.VisibilityChange="visibilitychange"})(C1||(C1={}));var Rs;(function(t){t.Space="Space",t.Down="ArrowDown",t.Right="ArrowRight",t.Left="ArrowLeft",t.Up="ArrowUp",t.Esc="Escape",t.Enter="Enter",t.Tab="Tab"})(Rs||(Rs={}));Rs.Space,Rs.Enter,Rs.Esc,Rs.Space,Rs.Enter,Rs.Tab;var E1;(function(t){t[t.RightClick=2]="RightClick"})(E1||(E1={}));var k1;(function(t){t[t.Pointer=0]="Pointer",t[t.DraggableRect=1]="DraggableRect"})(k1||(k1={}));var D1;(function(t){t[t.TreeOrder=0]="TreeOrder",t[t.ReversedTreeOrder=1]="ReversedTreeOrder"})(D1||(D1={}));Tf.Backward+"",Tf.Forward+"",Tf.Backward+"",Tf.Forward+"";var kv;(function(t){t[t.Always=0]="Always",t[t.BeforeDragging=1]="BeforeDragging",t[t.WhileDragging=2]="WhileDragging"})(kv||(kv={}));var Dv;(function(t){t.Optimized="optimized"})(Dv||(Dv={}));kv.WhileDragging,Dv.Optimized;({...J4});var P1;(function(t){t[t.Uninitialized=0]="Uninitialized",t[t.Initializing=1]="Initializing",t[t.Initialized=2]="Initialized"})(P1||(P1={}));function Q4(t,e,n){const r=t.slice();return r.splice(n<0?r.length+n:n,0,r.splice(e,1)[0]),r}Rs.Down,Rs.Right,Rs.Up,Rs.Left;function e6(t){const e=new CustomEvent("updateFavoriteMenu",{detail:{menuItem:t}});window.dispatchEvent(e)}const vm="MENU_ITEM";function t6(t){const e=Sp.useLocation(),[n,r]=q.useState([]),[i,o]=q.useState(!1);console.log("isSubmit",i);const a=q.useRef(null),[c,f]=q.useState(window.location.href);q.useEffect(()=>{f(window.location.href)},[e]);const p=M=>`${M}`;function b(M,_){for(const H of M){if(H.id===_)return H;if(H.children){const Y=b(H.children,_);if(Y)return Y}}return null}function m(M,_){const H=b(n,M);H?(H.isFavorite=_,e6(H),nb(M,_)):console.error(`Item with id ${M} not found`)}const T=M=>{console.log("Favorite menus changed",M);const _=M.detail.favoriteMenus||[];r(_)};q.useEffect(()=>(window.addEventListener("favoriteMenusChange",T),()=>{window.removeEventListener("favoriteMenusChange",T)}),[]);const E=(M,_)=>{n[M];const H=Q4(n,M,_);r(H),o(!0);const Y={menuItemIds:H.map(ne=>ne.id)};As.post("global-menu-config/api/v1/menu-items/user/order-favorites",Y,{baseURL:t.baseUrl}).then(()=>{}).catch(ne=>{console.error(ne),r(n)}).finally(()=>{o(!1)})},A=({item:M,index:_})=>{const H=q.useRef(null),[{isDragging:Y},ne]=XE({type:vm,item:()=>({id:M.id,index:_}),collect:ae=>({isDragging:ae.isDragging()})}),[{isOver:Z,isOverCurrent:ce},S]=up(()=>({accept:vm,collect:ae=>({isOver:ae.isOver(),isOverCurrent:ae.isOver({shallow:!0})}),drop:ae=>{E(ae.index,_),ae.index=_}}),[]);let ue="hover-off";return(ce||Z)&&(ue="hover-on"),ne(S(H)),_e.jsx("div",{ref:H,style:{opacity:Y?.7:1,boxShadow:Y?"0 4px 8px rgba(0, 0, 0, 0.2)":"none",cursor:"move",display:"inline-block",marginRight:"8px",position:"relative",transition:"transform 0.3s ease-in-out"},className:`item ${ue}`,children:_e.jsx(jD,{replacePath:t.replacePath,ssr:t.ssr,brandColors:t.brandColors,baseUrl:t.baseUrl,item:M,level:1,onSetFavoriteSuccess:m})})},I=()=>{const M=q.useRef(null),[{isOver:_,canDrop:H},Y]=up(()=>({accept:vm,drop:ne=>{E(ne.index,n.length-1),ne.index=n.length-1},collect:ne=>({isOver:ne.isOver(),canDrop:ne.canDrop()})}),[n]);return Y(M),_e.jsx("div",{ref:M,style:{height:40,width:150,display:"flex",alignItems:"center",justifyContent:"center",borderLeft:_&&H?"2px solid var(--primary300)":"transparent"}})};return _e.jsx(_e.Fragment,{children:n.length?_e.jsx("div",{className:p("favorite-menu"),children:_e.jsx(Wv,{ref:a,className:p("wrap-section favorite-menu__menu"),style:{marginTop:4,flex:1,overflow:"auto",height:"100%",overflowY:"hidden"},children:_e.jsx(UE,{backend:eC,children:_e.jsxs("div",{style:{display:"inline-flex"},children:[n.map((M,_)=>_e.jsx(A,{item:M,index:_},M.id)),_e.jsx(I,{})]})})})}):""})}function n6(t=32){const[e,n]=q.useState(!0),[r,i]=q.useState(0),o=()=>{const a=window.scrollY;a>r&&a>t?n(!1):a<r&&n(!0),i(a)};return q.useEffect(()=>(window.addEventListener("scroll",o),()=>window.removeEventListener("scroll",o)),[r]),{isFavoriteBarVisible:e}}function r6(t){const{isFavoriteBarVisible:e}=n6();return _e.jsxs(_e.Fragment,{children:[_e.jsx("style",{children:Z4}),_e.jsx("div",{className:`favorite-bar ${e?"favorite-bar--visible":"favorite-bar--hidden"}`,children:_e.jsx(WD.div,{children:_e.jsx(Vv,{styles:[VT,I4,K4],children:_e.jsx(t6,{...t})})})})]})}function nb(t,e){const n=JSON.parse(localStorage.getItem("favoriteItems")||"[]");if(e)n.includes(t)||n.push(t);else{const r=n.indexOf(t);r>-1&&n.splice(r,1)}localStorage.setItem("favoriteItems",JSON.stringify(n))}function zD({...t}){var ke,We,et;const e=t.item,n=t.level||0,r=!!((ke=t.item.children)!=null&&ke.length),{isActive:i,isCollapsed:o}=t,a=`level-${n}`,c=o?"collapsed":"expanded",f=i(e.id)?"active":"",p=r?"parent":"child",b=t.params.isOpen?"isOpen":"isClose",m=t.isInternalApp?"isInternalApp":"",T=(qe,Je=a)=>`${qe} ${Je} ${c} ${f} ${p} ${b} ${m}`,[E,A]=q.useState(!1),[I,M]=q.useState(e.isFavorite||!1);q.useEffect(()=>{M(!!t.item.isFavorite)},[t.item.isFavorite]);const _=q.useRef(),H=q.useRef();H!=null&&H.current&&((We=H==null?void 0:H.current)==null?void 0:We.scrollWidth)>((et=H==null?void 0:H.current)==null?void 0:et.clientWidth);const Y=window.location.origin,ne=e.path&&e.path.includes("http")?new URL(e.path):{origin:"",pathname:""},Z=window.location.pathname.split("/")[1],ce=ne.pathname.split("/")[1],S=t.item.redirectUrl||t.ssr||!Y.includes("local")&&Y!==ne.origin||ce!==Z,ue=r?"div":!t.isInternalApp&&S?"a":Sp.Link,ae=e.redirectUrl||e.path||"#",Ge=n+1,Le=r&&o&&E,Me=o||n===0?void 0:`${n+.25}rem`,$e=()=>{A(!0)},Ue=()=>{A(!1)},he="/global-menu-config/api/v1/menu-items/user/set-favorite",Ce=e.serviceKey==="mn_poms";t.params.depth*20,t.params.depth,_H(e.id,t.params.isOpen,t.params.onToggle);const Ne=Ce||o&&n===0?e.name==="POMs"?"Parking Operations Management":e.description||e.name:null,tt=Object.entries(t.brandColors||{}).reduce((qe,[Je,Ke])=>(Ke&&(qe[`--${Je}`]=Ke),qe),{}),me=Y!==ne.origin||t.item.redirectUrl?"_blank":"_self";return _e.jsxs("div",{ref:_,className:T("menu-item__wrapper tree-node"),style:{borderRadius:"8px",transition:"all 0.3s",...tt},onMouseOver:$e,onMouseOut:Ue,onDragStart:qe=>{o&&n>1&&qe.preventDefault()},children:[_e.jsx(sa.Tooltip,{placement:"top",title:Ne,disableInteractive:!0,children:_e.jsxs(ue,{target:me,to:ae,href:ae,draggable:"true",className:T("menu-item__link"),style:{paddingLeft:Me},onClick:qe=>{localStorage.setItem("latestClickMenuPath",(e.path||"").replace(window.location.origin,"")),!(ue==="a"&&me==="_blank")&&(o||t.toggleExpand(qe))},children:[_e.jsx(i6,{cls:T,item:e}),_e.jsx("span",{className:T("menu-item__label"),ref:H,children:e.name}),_e.jsx(o6,{tooltipPosition:Ne?"right":"top",menuLevel:n,hasChildren:r,isHovered:E,isFavorite:I,onClick:qe=>{const Je={menuConfigId:e.id,isFavorite:qe},Ke=t.baseUrl+he;As.post(Ke,Je).then(ot=>{var ct;M(qe),Yv("Set favorite menu item successfully"),(ct=t.onSetFavoriteSuccess)==null||ct.call(t,t.item.id,qe),nb(t.item.id,qe)}).catch(ot=>{var ct,pt;Wd(((pt=(ct=ot.response)==null?void 0:ct.data)==null?void 0:pt.errorMessage)||"Have error when set favorite menu item")})}}),r&&_e.jsx("div",{className:T("menu-item__icon-arrow__wrapper"),children:_e.jsx(Q5,{className:T(`menu-item__icon-arrow__icon ${t.params.isOpen?"open":"close"}`)})})]})}),Le&&_e.jsx(e4,{parentRef:_,onlyChild:!o,renderChildren:({maxHeight:qe})=>{var Je;return _e.jsx(OD.div,{className:T(`menu-item__dropdown ${t.params.isOpen?"menu-item__dropdown--open":"menu-item__dropdown--close"}`,`level-${Ge}`),style:eb({maxHeight:qe,overflowY:"auto",paddingRight:3},qe!=="auto"&&!!Ge),children:(Je=e.children)==null?void 0:Je.map(Ke=>q.createElement(zD,{...t,key:Ke.id,item:Ke,level:Ge}))})}})]})}function i6({item:t,cls:e}){return _e.jsx("div",{className:e("menu-item__icon"),children:_e.jsx(ND,{item:t})})}function o6(t){const e={marginRight:t.hasChildren?10:0,fontSize:18,fill:ki.warning};return _e.jsxs(_e.Fragment,{children:[t.isHovered&&!t.isFavorite&&_e.jsx(sa.Tooltip,{placement:t.tooltipPosition||"top",title:"Add to favorites",disableInteractive:!0,children:_e.jsx("div",{children:_e.jsx(_D,{style:e,onClick:n=>{var r;n.preventDefault(),n.stopPropagation(),(r=t.onClick)==null||r.call(t,!0)}})})}),t.isFavorite&&_e.jsx(sa.Tooltip,{placement:t.tooltipPosition||"top",title:"Remove from favorites",disableInteractive:!0,children:_e.jsx("div",{children:_e.jsx(RD,{style:e,onClick:n=>{var r;n.preventDefault(),n.stopPropagation(),(r=t.onClick)==null||r.call(t,!1)}})})})]})}function s6(){return _e.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"22",height:"22",fill:"currentColor",stroke:"currentColor",strokeWidth:"0",viewBox:"0 0 24 24",children:_e.jsx("path",{d:"M21 18v2H3v-2h18zM6.596 3.903L8.01 5.318 4.828 8.5 8.01 11.68l-1.414 1.415L2 8.5l4.596-4.597zM21 11v2h-9v-2h9zm0-7v2h-9V4h9z"})})}function a6(){return _e.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"22",height:"22",fill:"currentColor",stroke:"currentColor",strokeWidth:"0",viewBox:"0 0 24 24",children:_e.jsx("path",{d:"M3 4h18v2H3V4zm0 7h18v2H3v-2zm0 7h18v2H3v-2z"})})}function l6(t){return _e.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"18",height:"20",fill:"none",viewBox:"0 0 18 20",...t,children:_e.jsx("path",{fill:"#E01B00",fillRule:"evenodd",d:"M.179 2.875A2.375 2.375 0 012.554.5h3.393a1.018 1.018 0 010 2.036H2.554a.34.34 0 00-.34.339v14.25c0 .187.152.34.34.34h3.393a1.018 1.018 0 110 2.035H2.554a2.375 2.375 0 01-2.375-2.375V2.875zm14.167 6.107h-7.72a1.018 1.018 0 000 2.036h7.72l-2.673 2.673a1.018 1.018 0 101.44 1.44l4.41-4.411a1.018 1.018 0 000-1.44l-4.41-4.41a1.018 1.018 0 10-1.44 1.439l2.673 2.673z",clipRule:"evenodd"})})}const u6=".flex-col-center{display:flex;flex-direction:column;justify-content:center}.wrap-section{padding:0 8px;transition:all .3s}.wrap-section.collapsed{padding:0 4px}.side-bar{position:fixed;top:64px;left:0;height:calc(100vh - 64px);max-width:18rem;display:flex;flex-direction:column;border-right:1px solid #ddd;background-color:#fafafa;transition:all .3s}.side-bar.expanded{width:17rem}.side-bar.collapsed{width:64px}.side-bar__wrap-btn-logout,.side-bar__btn-logout{margin:5px 0}.side-bar__logout-btn__text{margin-left:12px;font-size:.875rem;opacity:1}.side-bar__logout-btn__text.collapsed{opacity:0;transition:ease-in-out .2s;transition-delay:.15s}.side-bar__wrapper-toggle-btn{display:flex;flex-direction:row;justify-content:flex-end;transition:all .3s;margin-right:-8px;margin-top:40px}.side-bar__wrapper-toggle-btn.collapsed{justify-content:center;width:100%}.side-bar__toggle-btn{margin-top:-6px;color:#85858a}.side-bar__logout-btn{width:100%;text-align:left;display:flex;flex-direction:row;align-items:center;padding:8px 16px 8px 18.6665px;min-height:48px;border-radius:.375rem;overflow:hidden;transition:all .3s ease-in-out;background-color:initial}.side-bar__logout-btn:hover{background-color:#919eab14}.side-bar__icon-logout{flex-shrink:0}.menu-item__wrapper{display:flex;flex-direction:column;position:relative;width:100%;color:#292929}.menu-item__wrapper.collapsed.active,.menu-item__wrapper.expanded.active.parent.isClose,.menu-item__wrapper.expanded.active.child{color:var(--primary400);background-color:var(--primary200)}.menu-item__link{display:flex;flex-direction:row;border-radius:.375rem;align-items:center;padding:.5rem;position:relative;height:48px;cursor:pointer}.menu-item__link.expanded.level-0{padding:.5rem 10px}.menu-item__link:hover{background-color:#919eab14}.menu-item__link.collapsed.level-0{padding-left:calc(.5rem + 7.665px)!important}.menu-item__link.active{background-color:#009d4f1a;color:inherit}.menu-item__link.active.level-0,.menu-item__link.active.level-1,.menu-item__link.active.level-2,.menu-item__link.active.level-3,.menu-item__link.active.level-4,.menu-item__link.active.level-5,.menu-item__link.active.level-6,.menu-item__link.active.level-7,.menu-item__link.active.level-8,.menu-item__link.active.level-9{background-color:inherit;color:inherit}.menu-item__link.active.level-1:hover,.menu-item__link.active.level-2:hover,.menu-item__link.active.level-3:hover,.menu-item__link.active.level-4:hover,.menu-item__link.active.level-5:hover,.menu-item__link.active.level-6:hover,.menu-item__link.active.level-7:hover,.menu-item__link.active.level-8:hover,.menu-item__link.active.level-9:hover,.menu-item__link.active.level-0:hover{background-color:#919eab14}.menu-item__link.level-0{transition:padding .2s}.menu-item__link.menu-item__link.collapsed.level-0{padding:0}.menu-item__icon{width:1.5rem;height:1.5rem;flex-shrink:0;display:grid;place-items:center;color:#85858a}.menu-item__icon.collapsed.active,.menu-item__icon.expanded.active.parent.isClose,.menu-item__icon.expanded.active.child{color:inherit}.menu-item__icon.collapsed.level-0>*{margin:0 auto}.menu-item__label{font-size:.875rem;text-overflow:ellipsis;overflow:hidden;white-space:nowrap;width:100%;flex-shrink:1;margin-left:12px;padding-right:12px;opacity:1}.menu-item__label.level-0.collapsed{text-overflow:unset}.menu-item__label.active{color:inherit}.menu-item__label.collapsed{margin-left:8px;font-size:.75rem;line-height:1rem}.menu-item__label.collapsed.level-0{font-size:.875rem;opacity:0;transition-delay:.15s}.menu-item__label.level-0{margin-left:8px;font-weight:500;font-size:.951rem}.menu-item__label.level-0.isInternalApp{font-weight:unset!important}.menu-item__icon-arrow__wrapper{display:grid;place-items:center;position:absolute;top:50%;transform:translateY(-50%);right:0}.menu-item__icon-arrow__wrapper.expanded{right:4px}.menu-item__icon-arrow__icon{transition:transform .3s!important;transform:rotate(-90deg)!important}.menu-item__icon-arrow__icon.active{color:inherit}.menu-item__icon-arrow__icon.expanded.open{transform:rotate(0)!important}.menu-item__dropdown.collapsed{background-color:#fafafa;border:1px solid #ddd;box-shadow:#0000001a 0 10px 15px -3px,#0000000d 0 4px 6px -2px;border-radius:4px;width:210px;max-width:210px;padding:4px;z-index:1200}.menu-item__dropdown::-webkit-scrollbar{width:4px}.menu-item__dropdown::-webkit-scrollbar-thumb{background-color:#9b9b9b99;border-radius:2px}.menu-item__dropdown,.menu-item__dropdown>*{margin-top:4px}.menu-item__dropdown.expanded.menu-item__dropdown--close{margin-top:0;transition:margin-top .3s}.menu-item__dropdown:first-of-type{margin-top:0}.menu-item__dropdown>*:first-child{margin-top:0}.menu-item__dropdown.collapsed .menu-item__link{height:40px}.menu-item__dropdown.collapsed .menu-item__link.level-0{height:48px}.menu-item__dropdown.collapsed.level-0{width:auto;max-width:unset;box-shadow:none;border:none;padding:0;background-color:unset}.menu-item__dropdown.expanded{overflow:hidden}.icon-btn{display:inline-flex;align-items:center;justify-content:center;padding:8px;border-radius:50%;background-color:transparent;transition:background-color .3s ease;border:none}.icon-btn:hover{background-color:var(--btn-bg-hover)}.simplebar-scrollbar:before{background-color:#0000002d}.side-bar__menu.collapsed .simplebar-track.simplebar-vertical{display:none}@keyframes fadeIn{0%{opacity:0}to{opacity:1}}",c6=t=>{const e=t.isCollapsed?0:t.depth*16;return _e.jsx("div",{style:{backgroundColor:t.color||"#93D500",height:"2px",position:"absolute",right:"0",top:"0",left:e}})},f6=".app,.treeRoot{height:100%}.draggingSource{opacity:.3}.placeholderContainer{position:relative}.dropTarget{background-color:#8d878711}",d6=t=>{const[e,n]=q.useState(()=>{const r=localStorage.getItem("openingMenuIds");return r&&r!=="[]"?JSON.parse(r):(t==null?void 0:t.initOpenIds)||[]});return q.useEffect(()=>{localStorage.setItem("openingMenuIds",JSON.stringify(e))},[e]),[e,n]};function YD(t){document.documentElement.style.setProperty("--global-menu-width",!t||t==="true"?"64px":"17rem")}const Gh=localStorage.getItem("isCollapsed");YD(Gh);function h6(t){const e=new CustomEvent("favoriteMenusChange",{detail:{favoriteMenus:t}});window.dispatchEvent(e)}function p6(t){const e=Sp.useLocation(),[n,r]=q.useState([]),i=n.map(Le=>Le.data),[o,a]=q.useState(!1),[c,f]=q.useState([]),[p,b]=q.useState(Gh===null?!0:Gh==="true"),[m,T]=q.useState(window.location.href),E=q.useRef(null);q.useEffect(()=>{var Le;(Le=t.handleCallback)==null||Le.call(t,i)},[i,t.handleCallback]),q.useEffect(()=>{T(window.location.href)},[e]);const A=m6(i,m),[I,M]=d6({initOpenIds:t.initOpenIds}),_=()=>{var Le,Me;if(b(!p),localStorage.setItem("isCollapsed",JSON.stringify(!p)),YD(p),p)I&&((Le=E.current)==null||Le.open(I));else{const $e=n.filter(Ue=>Ue.parent===0).map(Ue=>Ue.id);console.log("closeIds:",$e),(Me=E.current)==null||Me.close($e)}},[H,Y]=q.useState(!1),ne=p?"collapsed":"expanded",Z=Le=>`${Le} ${ne}`,ce=q.useRef(null);q.useLayoutEffect(()=>{(async()=>{var Me,$e;try{const Ue=t.menuPath||"/global-menu-config/api/v1/menu-items/user",he=t.baseUrl+Ue,{data:Ce}=await As.get(he);let Pe=Ce.map(tt=>({...tt,parentKey:tt.parentKey||0}));Pe=qD(Pe),t.replacePath&&(Pe=GD(Pe,t.replacePath));const Ne=Pe.map(tt=>({id:tt.id,parent:tt.parentKey,text:tt.name,data:tt}));r(Ne)}catch(Ue){console.error("Global menu",Ue),Wd((($e=(Me=Ue.response)==null?void 0:Me.data)==null?void 0:$e.errorMessage)||"Have error when get menu items")}})()},[t.baseUrl,t.menuPath,t.replacePath]);const S=async()=>{try{const Le=await fetch(`${t.baseUrl}/global-menu-config/api/v1/menu-items/user/get-favorites`);if(!Le.ok)throw new Error("Failed to fetch favorite items");const Me=await Le.json();f(Me)}catch(Le){console.error("Error fetching favorite items:",Le)}};q.useEffect(()=>{S()},[t.baseUrl]),q.useEffect(()=>{let Le=[];c.forEach(Ue=>{const he=i.find(Ce=>Ce.id===Ue&&Ce.isFavorite===!0);he&&(Le=[...Le,he])}),console.log(Le);function Me(Ue){return i.every(he=>he.parentKey!==Ue.id)?Ue:{...Ue,children:i.filter(he=>he.parentKey===Ue.id).map(he=>Me(he))}}const $e=Le.map(Ue=>Me(Ue));h6($e)},[i]);function ue(Le){const Me=Le.detail.menuItem;r($e=>$e.map(Ue=>Ue.id!==Me.id?Ue:{...Ue,data:Me})),S()}q.useEffect(()=>(window.addEventListener("updateFavoriteMenu",ue),()=>{window.removeEventListener("updateFavoriteMenu",ue)}),[]),q.useLayoutEffect(()=>{var Ue;const Le=localStorage.getItem("scrollPos");Le&&ce.current&&setTimeout(()=>{const he=ce.current.getScrollElement();he.scrollTop=parseInt(Le)},0);const Me=()=>{if(ce.current){const he=ce.current.getScrollElement();localStorage.setItem("scrollPos",he.scrollTop.toString())}},$e=(Ue=ce.current)==null?void 0:Ue.getScrollElement();return $e==null||$e.addEventListener("scroll",Me),()=>{$e==null||$e.removeEventListener("scroll",Me)}},[i]);function ae(Le){a(!0);const Me=[...n];r(Le);const $e=Le.map((Ue,he)=>({menuItemId:Ue.id,order:he}));As.post("/global-menu-config/api/v1/menu-items/user",$e,{baseURL:t.baseUrl}).then(()=>{}).catch(Ue=>{console.error(Ue),r(Me)}).finally(()=>{a(!1)})}const Ge=q.useMemo(()=>Gh==="false"?I:[],[]);return console.log("nodesglobal menu",n),_e.jsxs("div",{className:Z("side-bar"),children:[_e.jsx("div",{className:Z("wrap-section side-bar__wrapper-toggle-btn"),children:_e.jsx("button",{className:"icon-btn side-bar__toggle-btn",onClick:_,children:p?_e.jsx(a6,{}):_e.jsx(s6,{})})}),_e.jsx(Wv,{ref:ce,className:Z("wrap-section side-bar__menu"),style:{marginTop:24,flex:1,overflow:"auto",height:"100%",overflowX:"hidden"},children:_e.jsx(UE,{backend:eH,options:EH(),children:_e.jsx(HH,{ref:E,classes:{root:"treeRoot",draggingSource:"draggingSource",placeholder:"placeholderContainer",listItem:Le=>{var Me;return((Me=Le.data)==null?void 0:Me.name)==="Home"?"isHome":""}},tree:n,rootId:0,sort:!1,insertDroppableFirst:!1,enableAnimateExpand:!0,dropTargetOffset:10,onDrop:ae,render:(Le,Me)=>{function $e(Pe){return n.every(Ne=>Ne.parent!==Pe.id)?Pe:{...Pe,children:n.filter(Ne=>Ne.parent===Pe.id).map(Ne=>$e(Ne.data))}}const Ue=$e(Le.data),he=Pe=>A.some(Ne=>Ne.id===Pe);function Ce(Pe,Ne){r(tt=>tt.map(me=>me.id===Pe?{...me,data:{...me.data,isFavorite:Ne}}:me)),S()}return _e.jsx(zD,{isInternalApp:t.isInternalApp,isActive:he,isCollapsed:p,replacePath:t.replacePath,ssr:t.ssr,brandColors:t.brandColors,baseUrl:t.baseUrl,node:Le,params:Me,nodes:n,item:Ue,expanded:()=>!1,toggleExpand:Pe=>{var Ne;if(Pe.stopPropagation(),Me.isOpen)console.log("open toggleExpand"),Me.onToggle();else{console.log("close toggleExpand");const tt=n.filter(me=>me.parent===Le.parent&&me.id!==Le.id).map(me=>me.id);console.log(" closeIds:",tt),(Ne=E.current)==null||Ne.open(Le.id),setTimeout(()=>{var me;(me=E.current)==null||me.close(tt)},0)}},level:Me.depth,onSetFavoriteSuccess:Ce})},placeholderRender:(Le,{depth:Me})=>{var $e;return _e.jsx(c6,{node:Le,depth:Me,color:($e=t.brandColors)==null?void 0:$e.primary300,isCollapsed:p})},canDrag:()=>!o,canDrop:(Le,{dragSource:Me,dropTargetId:$e})=>(Me==null?void 0:Me.parent)===$e,onDragStart:Le=>{console.log("onDragStart",Le)},onChangeOpen:Le=>{localStorage.getItem("isCollapsed")==="false"&&(console.log("onChangeOpen:",Le),M(Le))},initialOpen:Ge})})}),_e.jsxs("div",{className:Z("wrap-section side-bar__wrap-btn-logout"),children:[_e.jsxs("button",{className:Z("side-bar__logout-btn"),onClick:()=>Y(!0),children:[_e.jsx(l6,{className:Z("side-bar__icon-logout")}),_e.jsx("span",{className:Z("side-bar__logout-btn__text"),children:"Logout"})]}),_e.jsx(X1,{isOpen:H,onClose:()=>Y(!1),onConfirm:()=>t.logout?t.logout():oT(t.baseUrl)})]})]})}const O1={"/stella/page/SiteManagement/Company/List?tenantId=1":["/stella/page/SiteManagement/Company"],"/stella/page/SiteManagement/Portfolio/List":["/stella/page/SiteManagement/Portfolio"],"/stella/page/SiteManagement/CountryRegion/List":["/stella/page/SiteManagement/CountryRegion"],"/stella/page/SiteManagement/VehicleListController/List":["/stella/page/SiteManagement/VehicleListController"],"/stella/page/ContraventionManagement/CorrespondenceTemplate/List":["/stella/page/ContraventionManagement/CorrespondenceTemplate"],"/stella/page/ContraventionManagement/VerificationsAudit/List":["/stella/page/ContraventionManagement/VerificationsAudit"],"/stella/page/ContraventionManagement/PendingWardenVerification/List":["/stella/page/ContraventionManagement/PendingWardenVerification"],"/stella/page/ContraventionManagement/Appeal/Search":["/stella/page/ContraventionManagement/Appeal"],"/stella/page/ContraventionManagement/Contravention/Search":["/stella/page/ContraventionManagement/Contravention"],"/stella/page/ContraventionManagement/Tag/Search":["/stella/page/ContraventionManagement/Tag"],"/stella/page/ContraventionManagement/WorkflowMapping/List":["/stella/page/ContraventionManagement/WorkflowMapping"],"/stella/page/ContraventionManagement/WorkflowLetterTemplateMapping/List":["/stella/page/ContraventionManagement/WorkflowLetterTemplateMapping"],"/stella/page/ContraventionManagement/ScannedAppeal/Summary":["/stella/page/ContraventionManagement/ScannedAppeal"],"/stella/page/ContraventionManagement/PendingAppealWorkQueue/List":["/stella/page/ContraventionManagement/PendingAppeal"],"/stella/page/ContraventionManagement/NoDecisionAIAppeal/List":["/stella/page/ContraventionManagement/NoDecisionAIAppeal"],"/stella/page/ContraventionManagement/VerifyAIAppeal/List":["/stella/page/ContraventionManagement/VerifyAIAppeal"],"/anpr/page/LocationDisableReasons/Index":["/anpr/page/LocationDisableReasons"],"/anpr/page/Tags/Index":["/anpr/page/Tags"],"/anpr/page/VendorLocations/Index":["/anpr/page/VendorLocations"],"/anpr/page/Cameras/Index":["/anpr/page/Cameras"],"/anpr/page/Locations/Index":["/anpr/page/Locations"],"/anpr/page/Devices/Index":["/anpr/page/Devices"],"/anpr/page/Technical/Overview":["/anpr/page/Technical"],"/anpr/page/Technical/Index":["/anpr/page/Technical"],"/anpr/page/Technical/Index?priority=P1":["/anpr/page/Technical"],"/anpr/page/Technical/Index?priority=P2":["/anpr/page/Technical"],"/anpr/page/Technical/Index?priority=P3":["/anpr/page/Technical"],"/anpr/page/Technical/Index?priority=P4":["/anpr/page/Technical"],"/anpr/page/CustomVerifications/WipByLocation":["/anpr/page/CustomVerifications"],"/anpr/page/Issues/Index?status=Closed":["/anpr/page/Issues"],"/anpr/page/Issues/Index":["/anpr/page/Issues"],"/anpr/page/Issues/Overview":["/anpr/page/Issues"]};function g6(t,e){const r=t.replace(window.origin,""),i=new URL(r,window.location.origin),o=new URL(e,window.origin),a=localStorage.getItem("latestClickMenuPath");return a&&O1[a]&&a===r&&O1[a].some(c=>e.includes(c))?4:i.pathname===o.pathname&&i.search===o.search?3:i.pathname===o.pathname?2:o.pathname.startsWith(i.pathname)?1:0}function m6(t,e){const n=t.map(a=>({item:a,priority:a.path?g6(a.path,e):0})).filter(a=>a.priority>0),r=n.length>0?n.reduce((a,c)=>c.priority>a.priority?c:a).item:null,i=[];let o=r;for(;o;)i.unshift(o),o=t.find(a=>a.id===(o==null?void 0:o.parentKey))||null;return i}function GD(t,e){return t.map(n=>{var r;return(r=n.children)!=null&&r.length?(n.path="",n.children=GD(n.children,e)):n.path=e(n.path),n})}function qD(t){return t.map(n=>n.path&&!n.path.includes("http")&&n.path.includes("/")?{...n,path:window.location.origin+n.path}:(n.children&&(n.children=qD(n.children)),n))}function v6(t){return _e.jsx(WD.div,{children:_e.jsx(Vv,{styles:[VT,u6,f6],style:{position:"sticky",zIndex:1300},children:_e.jsx(p6,{...t})})})}const y6={"page-container":"_page-container_1pwo1_1","page-main-content":"_page-main-content_1pwo1_8","page-title":"_page-title_1pwo1_19","text-base":"_text-base_1pwo1_26","mt-4":"_mt-4_1pwo1_33"};var bp={exports:{}};/**
|
|
136
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)},z4=function(t,e){return V4(t)||H4(t,e)||U4(t,e)||W4()},$D=BD(function(t){function e(){return t.exports=e=Object.assign||function(n){for(var r=1;r<arguments.length;r++){var i=arguments[r];for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(n[o]=i[o])}return n},e.apply(this,arguments)}t.exports=e}),Y4=function(t,e){if(t==null)return{};var n,r,i={},o=Object.keys(t);for(r=0;r<o.length;r++)n=o[r],e.indexOf(n)>=0||(i[n]=t[n]);return i},VD=function(t,e){if(t==null)return{};var n,r,i=Y4(t,e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);for(r=0;r<o.length;r++)n=o[r],e.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i},G4=q.createContext(null);function HD(t){var e=t.children,n=e===void 0?"":e,r=VD(t,["children"]);return typeof n!="string"&&(n=j4(n)),q.createElement("template",$D({},r,{dangerouslySetInnerHTML:{__html:n}}))}function UD(t){var e=t.root,n=t.children;return Fv.createPortal(n===void 0?null:n,e)}function q4(t){var e=q.forwardRef(function(n,r){var i,o,a=n.mode,c=a===void 0?"open":a,f=n.delegatesFocus,p=f!==void 0&&f,b=n.styleSheets,m=b===void 0?[]:b,T=n.ssr,E=T!==void 0&&T,A=n.children,I=VD(n,["mode","delegatesFocus","styleSheets","ssr","children"]),M=(o=q.useRef((i=r)&&i.current),q.useEffect(function(){i&&(i.current=o.current)},[i]),o),_=q.useState(null),H=z4(_,2),Y=H[0],ne=H[1],Z="node_".concat(c).concat(p);return q.useLayoutEffect(function(){if(M.current)try{if(typeof r=="function"&&r(M.current),E){var ce=M.current.shadowRoot;return void ne(ce)}var S=M.current.attachShadow({mode:c,delegatesFocus:p});m.length>0&&(S.adoptedStyleSheets=m),ne(S)}catch(ue){(function(ae){var Ge=ae.error,Le=ae.styleSheets,Me=ae.root;switch(Ge.name){case"NotSupportedError":Le.length>0&&(Me.adoptedStyleSheets=Le);break;default:throw Ge}})({error:ue,styleSheets:m,root:Y})}},[r,M,m]),q.createElement(q.Fragment,null,q.createElement(t.tag,$D({key:Z,ref:M},I),(Y||E)&&q.createElement(G4.Provider,{value:Y},E?q.createElement(HD,{shadowroot:c,shadowrootmode:c},t.render({root:Y,ssr:E,children:A})):q.createElement(UD,{root:Y},t.render({root:Y,ssr:E,children:A})))))});return e.propTypes={mode:_s.oneOf(["open","closed"]),delegatesFocus:_s.bool,styleSheets:_s.arrayOf(_s.instanceOf(globalThis.CSSStyleSheet)),ssr:_s.bool,children:_s.node},e}HD.propTypes={children:_s.oneOfType([_s.string,_s.node])},UD.propTypes={root:_s.object.isRequired,children:_s.node};var mm=new Map;function X4(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"core",n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:function(r){return r.children};return new Proxy(t,{get:function(r,i){var o=$4(i,{separator:"-"}),a="".concat(e,"-").concat(o);return mm.has(a)||mm.set(a,q4({tag:o,render:n})),mm.get(a)}})}var WD=X4();const K4=".app,.treeRoot{height:100%}.draggingSource{opacity:.3}.placeholderContainer{position:relative}.dropTarget{background-color:#8d878711}",Z4=".favorite-bar{position:sticky;top:64px;z-index:900;transition:transform .3s ease,opacity .3s ease;border-bottom:1px solid #ddd}.favorite-bar--hidden{transform:translateY(-100%);opacity:0}.favorite-bar--visible{transform:translateY(0);opacity:1}";var T1;(function(t){t.DragStart="dragStart",t.DragMove="dragMove",t.DragEnd="dragEnd",t.DragCancel="dragCancel",t.DragOver="dragOver",t.RegisterDroppable="registerDroppable",t.SetDroppableDisabled="setDroppableDisabled",t.UnregisterDroppable="unregisterDroppable"})(T1||(T1={}));const J4=Object.freeze({x:0,y:0});var Tf;(function(t){t[t.Forward=1]="Forward",t[t.Backward=-1]="Backward"})(Tf||(Tf={}));var C1;(function(t){t.Click="click",t.DragStart="dragstart",t.Keydown="keydown",t.ContextMenu="contextmenu",t.Resize="resize",t.SelectionChange="selectionchange",t.VisibilityChange="visibilitychange"})(C1||(C1={}));var Rs;(function(t){t.Space="Space",t.Down="ArrowDown",t.Right="ArrowRight",t.Left="ArrowLeft",t.Up="ArrowUp",t.Esc="Escape",t.Enter="Enter",t.Tab="Tab"})(Rs||(Rs={}));Rs.Space,Rs.Enter,Rs.Esc,Rs.Space,Rs.Enter,Rs.Tab;var E1;(function(t){t[t.RightClick=2]="RightClick"})(E1||(E1={}));var k1;(function(t){t[t.Pointer=0]="Pointer",t[t.DraggableRect=1]="DraggableRect"})(k1||(k1={}));var D1;(function(t){t[t.TreeOrder=0]="TreeOrder",t[t.ReversedTreeOrder=1]="ReversedTreeOrder"})(D1||(D1={}));Tf.Backward+"",Tf.Forward+"",Tf.Backward+"",Tf.Forward+"";var kv;(function(t){t[t.Always=0]="Always",t[t.BeforeDragging=1]="BeforeDragging",t[t.WhileDragging=2]="WhileDragging"})(kv||(kv={}));var Dv;(function(t){t.Optimized="optimized"})(Dv||(Dv={}));kv.WhileDragging,Dv.Optimized;({...J4});var P1;(function(t){t[t.Uninitialized=0]="Uninitialized",t[t.Initializing=1]="Initializing",t[t.Initialized=2]="Initialized"})(P1||(P1={}));function Q4(t,e,n){const r=t.slice();return r.splice(n<0?r.length+n:n,0,r.splice(e,1)[0]),r}Rs.Down,Rs.Right,Rs.Up,Rs.Left;function e6(t){const e=new CustomEvent("updateFavoriteMenu",{detail:{menuItem:t}});window.dispatchEvent(e)}const vm="MENU_ITEM";function t6(t){const e=Sp.useLocation(),[n,r]=q.useState([]),[i,o]=q.useState(!1);console.log("isSubmit",i);const a=q.useRef(null),[c,f]=q.useState(window.location.href);q.useEffect(()=>{f(window.location.href)},[e]);const p=M=>`${M}`;function b(M,_){for(const H of M){if(H.id===_)return H;if(H.children){const Y=b(H.children,_);if(Y)return Y}}return null}function m(M,_){const H=b(n,M);H?(H.isFavorite=_,e6(H),nb(M,_)):console.error(`Item with id ${M} not found`)}const T=M=>{console.log("Favorite menus changed",M);const _=M.detail.favoriteMenus||[];r(_)};q.useEffect(()=>(window.addEventListener("favoriteMenusChange",T),()=>{window.removeEventListener("favoriteMenusChange",T)}),[]);const E=(M,_)=>{n[M];const H=Q4(n,M,_);r(H),o(!0);const Y={menuItemIds:H.map(ne=>ne.id)};As.post("global-menu-config/api/v1/menu-items/user/order-favorites",Y,{baseURL:t.baseUrl}).then(()=>{}).catch(ne=>{console.error(ne),r(n)}).finally(()=>{o(!1)})},A=({item:M,index:_})=>{const H=q.useRef(null),[{isDragging:Y},ne]=XE({type:vm,item:()=>({id:M.id,index:_}),collect:ae=>({isDragging:ae.isDragging()})}),[{isOver:Z,isOverCurrent:ce},S]=up(()=>({accept:vm,collect:ae=>({isOver:ae.isOver(),isOverCurrent:ae.isOver({shallow:!0})}),drop:ae=>{E(ae.index,_),ae.index=_}}),[]);let ue="hover-off";return(ce||Z)&&(ue="hover-on"),ne(S(H)),_e.jsx("div",{ref:H,style:{opacity:Y?.7:1,boxShadow:Y?"0 4px 8px rgba(0, 0, 0, 0.2)":"none",cursor:"move",display:"inline-block",marginRight:"8px",position:"relative",transition:"transform 0.3s ease-in-out"},className:`item ${ue}`,children:_e.jsx(jD,{replacePath:t.replacePath,ssr:t.ssr,brandColors:t.brandColors,baseUrl:t.baseUrl,item:M,level:1,onSetFavoriteSuccess:m})})},I=()=>{const M=q.useRef(null),[{isOver:_,canDrop:H},Y]=up(()=>({accept:vm,drop:ne=>{E(ne.index,n.length-1),ne.index=n.length-1},collect:ne=>({isOver:ne.isOver(),canDrop:ne.canDrop()})}),[n]);return Y(M),_e.jsx("div",{ref:M,style:{height:40,width:150,display:"flex",alignItems:"center",justifyContent:"center",borderLeft:_&&H?"2px solid var(--primary300)":"transparent"}})};return _e.jsx(_e.Fragment,{children:n.length?_e.jsx("div",{className:p("favorite-menu"),children:_e.jsx(Wv,{ref:a,className:p("wrap-section favorite-menu__menu"),style:{marginTop:4,flex:1,overflow:"auto",height:"100%",overflowY:"hidden"},children:_e.jsx(UE,{backend:eC,children:_e.jsxs("div",{style:{display:"inline-flex"},children:[n.map((M,_)=>_e.jsx(A,{item:M,index:_},M.id)),_e.jsx(I,{})]})})})}):""})}function n6(t=32){const[e,n]=q.useState(!0),[r,i]=q.useState(0),o=()=>{const a=window.scrollY;a>r&&a>t?n(!1):a<r&&n(!0),i(a)};return q.useEffect(()=>(window.addEventListener("scroll",o),()=>window.removeEventListener("scroll",o)),[r]),{isFavoriteBarVisible:e}}function r6(t){const{isFavoriteBarVisible:e}=n6();return _e.jsxs(_e.Fragment,{children:[_e.jsx("style",{children:Z4}),_e.jsx("div",{className:`favorite-bar ${e?"favorite-bar--visible":"favorite-bar--hidden"}`,children:_e.jsx(WD.div,{children:_e.jsx(Vv,{styles:[VT,I4,K4],children:_e.jsx(t6,{...t})})})})]})}function nb(t,e){const n=JSON.parse(localStorage.getItem("favoriteItems")||"[]");if(e)n.includes(t)||n.push(t);else{const r=n.indexOf(t);r>-1&&n.splice(r,1)}localStorage.setItem("favoriteItems",JSON.stringify(n))}function zD({...t}){var ke,We,et;const e=t.item,n=t.level||0,r=!!((ke=t.item.children)!=null&&ke.length),{isActive:i,isCollapsed:o}=t,a=`level-${n}`,c=o?"collapsed":"expanded",f=i(e.id)?"active":"",p=r?"parent":"child",b=t.params.isOpen?"isOpen":"isClose",m=t.isInternalApp?"isInternalApp":"",T=(qe,Je=a)=>`${qe} ${Je} ${c} ${f} ${p} ${b} ${m}`,[E,A]=q.useState(!1),[I,M]=q.useState(e.isFavorite||!1);q.useEffect(()=>{M(!!t.item.isFavorite)},[t.item.isFavorite]);const _=q.useRef(),H=q.useRef();H!=null&&H.current&&((We=H==null?void 0:H.current)==null?void 0:We.scrollWidth)>((et=H==null?void 0:H.current)==null?void 0:et.clientWidth);const Y=window.location.origin,ne=e.path&&e.path.includes("http")?new URL(e.path):{origin:"",pathname:""},Z=window.location.pathname.split("/")[1],ce=ne.pathname.split("/")[1],S=t.item.redirectUrl||t.ssr||!Y.includes("local")&&Y!==ne.origin||ce!==Z,ue=r?"div":!t.isInternalApp&&S?"a":Sp.Link,ae=e.redirectUrl||e.path||"#",Ge=n+1,Le=r&&o&&E,Me=o||n===0?void 0:`${n+.25}rem`,$e=()=>{A(!0)},Ue=()=>{A(!1)},he="/global-menu-config/api/v1/menu-items/user/set-favorite",Ce=e.serviceKey==="mn_poms";t.params.depth*20,t.params.depth,_H(e.id,t.params.isOpen,t.params.onToggle);const Ne=Ce||o&&n===0?e.name==="POMs"?"Parking Operations Management":e.description||e.name:null,tt=Object.entries(t.brandColors||{}).reduce((qe,[Je,Ke])=>(Ke&&(qe[`--${Je}`]=Ke),qe),{}),me=Y!==ne.origin||t.item.redirectUrl?"_blank":"_self";return _e.jsxs("div",{ref:_,className:T("menu-item__wrapper tree-node"),style:{borderRadius:"8px",transition:"all 0.3s",...tt},onMouseOver:$e,onMouseOut:Ue,onDragStart:qe=>{o&&n>1&&qe.preventDefault()},children:[_e.jsx(sa.Tooltip,{placement:"top",title:Ne,disableInteractive:!0,children:_e.jsxs(ue,{target:me,to:ae,href:ae,draggable:"true",className:T("menu-item__link"),style:{paddingLeft:Me},onClick:qe=>{ue==="a"&&me==="_blank"||o||(localStorage.setItem("latestClickMenuPath",(e.path||"").replace(window.location.origin,"")),t.toggleExpand(qe))},children:[_e.jsx(i6,{cls:T,item:e}),_e.jsx("span",{className:T("menu-item__label"),ref:H,children:e.name}),_e.jsx(o6,{tooltipPosition:Ne?"right":"top",menuLevel:n,hasChildren:r,isHovered:E,isFavorite:I,onClick:qe=>{const Je={menuConfigId:e.id,isFavorite:qe},Ke=t.baseUrl+he;As.post(Ke,Je).then(ot=>{var ct;M(qe),Yv("Set favorite menu item successfully"),(ct=t.onSetFavoriteSuccess)==null||ct.call(t,t.item.id,qe),nb(t.item.id,qe)}).catch(ot=>{var ct,pt;Wd(((pt=(ct=ot.response)==null?void 0:ct.data)==null?void 0:pt.errorMessage)||"Have error when set favorite menu item")})}}),r&&_e.jsx("div",{className:T("menu-item__icon-arrow__wrapper"),children:_e.jsx(Q5,{className:T(`menu-item__icon-arrow__icon ${t.params.isOpen?"open":"close"}`)})})]})}),Le&&_e.jsx(e4,{parentRef:_,onlyChild:!o,renderChildren:({maxHeight:qe})=>{var Je;return _e.jsx(OD.div,{className:T(`menu-item__dropdown ${t.params.isOpen?"menu-item__dropdown--open":"menu-item__dropdown--close"}`,`level-${Ge}`),style:eb({maxHeight:qe,overflowY:"auto",paddingRight:3},qe!=="auto"&&!!Ge),children:(Je=e.children)==null?void 0:Je.map(Ke=>q.createElement(zD,{...t,key:Ke.id,item:Ke,level:Ge}))})}})]})}function i6({item:t,cls:e}){return _e.jsx("div",{className:e("menu-item__icon"),children:_e.jsx(ND,{item:t})})}function o6(t){const e={marginRight:t.hasChildren?10:0,fontSize:18,fill:ki.warning};return _e.jsxs(_e.Fragment,{children:[t.isHovered&&!t.isFavorite&&_e.jsx(sa.Tooltip,{placement:t.tooltipPosition||"top",title:"Add to favorites",disableInteractive:!0,children:_e.jsx("div",{children:_e.jsx(_D,{style:e,onClick:n=>{var r;n.preventDefault(),n.stopPropagation(),(r=t.onClick)==null||r.call(t,!0)}})})}),t.isFavorite&&_e.jsx(sa.Tooltip,{placement:t.tooltipPosition||"top",title:"Remove from favorites",disableInteractive:!0,children:_e.jsx("div",{children:_e.jsx(RD,{style:e,onClick:n=>{var r;n.preventDefault(),n.stopPropagation(),(r=t.onClick)==null||r.call(t,!1)}})})})]})}function s6(){return _e.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"22",height:"22",fill:"currentColor",stroke:"currentColor",strokeWidth:"0",viewBox:"0 0 24 24",children:_e.jsx("path",{d:"M21 18v2H3v-2h18zM6.596 3.903L8.01 5.318 4.828 8.5 8.01 11.68l-1.414 1.415L2 8.5l4.596-4.597zM21 11v2h-9v-2h9zm0-7v2h-9V4h9z"})})}function a6(){return _e.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"22",height:"22",fill:"currentColor",stroke:"currentColor",strokeWidth:"0",viewBox:"0 0 24 24",children:_e.jsx("path",{d:"M3 4h18v2H3V4zm0 7h18v2H3v-2zm0 7h18v2H3v-2z"})})}function l6(t){return _e.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"18",height:"20",fill:"none",viewBox:"0 0 18 20",...t,children:_e.jsx("path",{fill:"#E01B00",fillRule:"evenodd",d:"M.179 2.875A2.375 2.375 0 012.554.5h3.393a1.018 1.018 0 010 2.036H2.554a.34.34 0 00-.34.339v14.25c0 .187.152.34.34.34h3.393a1.018 1.018 0 110 2.035H2.554a2.375 2.375 0 01-2.375-2.375V2.875zm14.167 6.107h-7.72a1.018 1.018 0 000 2.036h7.72l-2.673 2.673a1.018 1.018 0 101.44 1.44l4.41-4.411a1.018 1.018 0 000-1.44l-4.41-4.41a1.018 1.018 0 10-1.44 1.439l2.673 2.673z",clipRule:"evenodd"})})}const u6=".flex-col-center{display:flex;flex-direction:column;justify-content:center}.wrap-section{padding:0 8px;transition:all .3s}.wrap-section.collapsed{padding:0 4px}.side-bar{position:fixed;top:64px;left:0;height:calc(100vh - 64px);max-width:18rem;display:flex;flex-direction:column;border-right:1px solid #ddd;background-color:#fafafa;transition:all .3s}.side-bar.expanded{width:17rem}.side-bar.collapsed{width:64px}.side-bar__wrap-btn-logout,.side-bar__btn-logout{margin:5px 0}.side-bar__logout-btn__text{margin-left:12px;font-size:.875rem;opacity:1}.side-bar__logout-btn__text.collapsed{opacity:0;transition:ease-in-out .2s;transition-delay:.15s}.side-bar__wrapper-toggle-btn{display:flex;flex-direction:row;justify-content:flex-end;transition:all .3s;margin-right:-8px;margin-top:40px}.side-bar__wrapper-toggle-btn.collapsed{justify-content:center;width:100%}.side-bar__toggle-btn{margin-top:-6px;color:#85858a}.side-bar__logout-btn{width:100%;text-align:left;display:flex;flex-direction:row;align-items:center;padding:8px 16px 8px 18.6665px;min-height:48px;border-radius:.375rem;overflow:hidden;transition:all .3s ease-in-out;background-color:initial}.side-bar__logout-btn:hover{background-color:#919eab14}.side-bar__icon-logout{flex-shrink:0}.menu-item__wrapper{display:flex;flex-direction:column;position:relative;width:100%;color:#292929}.menu-item__wrapper.collapsed.active,.menu-item__wrapper.expanded.active.parent.isClose,.menu-item__wrapper.expanded.active.child{color:var(--primary400);background-color:var(--primary200)}.menu-item__link{display:flex;flex-direction:row;border-radius:.375rem;align-items:center;padding:.5rem;position:relative;height:48px;cursor:pointer}.menu-item__link.expanded.level-0{padding:.5rem 10px}.menu-item__link:hover{background-color:#919eab14}.menu-item__link.collapsed.level-0{padding-left:calc(.5rem + 7.665px)!important}.menu-item__link.active{background-color:#009d4f1a;color:inherit}.menu-item__link.active.level-0,.menu-item__link.active.level-1,.menu-item__link.active.level-2,.menu-item__link.active.level-3,.menu-item__link.active.level-4,.menu-item__link.active.level-5,.menu-item__link.active.level-6,.menu-item__link.active.level-7,.menu-item__link.active.level-8,.menu-item__link.active.level-9{background-color:inherit;color:inherit}.menu-item__link.active.level-1:hover,.menu-item__link.active.level-2:hover,.menu-item__link.active.level-3:hover,.menu-item__link.active.level-4:hover,.menu-item__link.active.level-5:hover,.menu-item__link.active.level-6:hover,.menu-item__link.active.level-7:hover,.menu-item__link.active.level-8:hover,.menu-item__link.active.level-9:hover,.menu-item__link.active.level-0:hover{background-color:#919eab14}.menu-item__link.level-0{transition:padding .2s}.menu-item__link.menu-item__link.collapsed.level-0{padding:0}.menu-item__icon{width:1.5rem;height:1.5rem;flex-shrink:0;display:grid;place-items:center;color:#85858a}.menu-item__icon.collapsed.active,.menu-item__icon.expanded.active.parent.isClose,.menu-item__icon.expanded.active.child{color:inherit}.menu-item__icon.collapsed.level-0>*{margin:0 auto}.menu-item__label{font-size:.875rem;text-overflow:ellipsis;overflow:hidden;white-space:nowrap;width:100%;flex-shrink:1;margin-left:12px;padding-right:12px;opacity:1}.menu-item__label.level-0.collapsed{text-overflow:unset}.menu-item__label.active{color:inherit}.menu-item__label.collapsed{margin-left:8px;font-size:.75rem;line-height:1rem}.menu-item__label.collapsed.level-0{font-size:.875rem;opacity:0;transition-delay:.15s}.menu-item__label.level-0{margin-left:8px;font-weight:500;font-size:.951rem}.menu-item__label.level-0.isInternalApp{font-weight:unset!important}.menu-item__icon-arrow__wrapper{display:grid;place-items:center;position:absolute;top:50%;transform:translateY(-50%);right:0}.menu-item__icon-arrow__wrapper.expanded{right:4px}.menu-item__icon-arrow__icon{transition:transform .3s!important;transform:rotate(-90deg)!important}.menu-item__icon-arrow__icon.active{color:inherit}.menu-item__icon-arrow__icon.expanded.open{transform:rotate(0)!important}.menu-item__dropdown.collapsed{background-color:#fafafa;border:1px solid #ddd;box-shadow:#0000001a 0 10px 15px -3px,#0000000d 0 4px 6px -2px;border-radius:4px;width:210px;max-width:210px;padding:4px;z-index:1200}.menu-item__dropdown::-webkit-scrollbar{width:4px}.menu-item__dropdown::-webkit-scrollbar-thumb{background-color:#9b9b9b99;border-radius:2px}.menu-item__dropdown,.menu-item__dropdown>*{margin-top:4px}.menu-item__dropdown.expanded.menu-item__dropdown--close{margin-top:0;transition:margin-top .3s}.menu-item__dropdown:first-of-type{margin-top:0}.menu-item__dropdown>*:first-child{margin-top:0}.menu-item__dropdown.collapsed .menu-item__link{height:40px}.menu-item__dropdown.collapsed .menu-item__link.level-0{height:48px}.menu-item__dropdown.collapsed.level-0{width:auto;max-width:unset;box-shadow:none;border:none;padding:0;background-color:unset}.menu-item__dropdown.expanded{overflow:hidden}.icon-btn{display:inline-flex;align-items:center;justify-content:center;padding:8px;border-radius:50%;background-color:transparent;transition:background-color .3s ease;border:none}.icon-btn:hover{background-color:var(--btn-bg-hover)}.simplebar-scrollbar:before{background-color:#0000002d}.side-bar__menu.collapsed .simplebar-track.simplebar-vertical{display:none}@keyframes fadeIn{0%{opacity:0}to{opacity:1}}",c6=t=>{const e=t.isCollapsed?0:t.depth*16;return _e.jsx("div",{style:{backgroundColor:t.color||"#93D500",height:"2px",position:"absolute",right:"0",top:"0",left:e}})},f6=".app,.treeRoot{height:100%}.draggingSource{opacity:.3}.placeholderContainer{position:relative}.dropTarget{background-color:#8d878711}",d6=t=>{const[e,n]=q.useState(()=>{const r=localStorage.getItem("openingMenuIds");return r&&r!=="[]"?JSON.parse(r):(t==null?void 0:t.initOpenIds)||[]});return q.useEffect(()=>{localStorage.setItem("openingMenuIds",JSON.stringify(e))},[e]),[e,n]};function YD(t){document.documentElement.style.setProperty("--global-menu-width",!t||t==="true"?"64px":"17rem")}const Gh=localStorage.getItem("isCollapsed");YD(Gh);function h6(t){const e=new CustomEvent("favoriteMenusChange",{detail:{favoriteMenus:t}});window.dispatchEvent(e)}function p6(t){const e=Sp.useLocation(),[n,r]=q.useState([]),i=n.map(Le=>Le.data),[o,a]=q.useState(!1),[c,f]=q.useState([]),[p,b]=q.useState(Gh===null?!0:Gh==="true"),[m,T]=q.useState(window.location.href),E=q.useRef(null);q.useEffect(()=>{var Le;(Le=t.handleCallback)==null||Le.call(t,i)},[i,t.handleCallback]),q.useEffect(()=>{T(window.location.href)},[e]);const A=m6(i,m),[I,M]=d6({initOpenIds:t.initOpenIds}),_=()=>{var Le,Me;if(b(!p),localStorage.setItem("isCollapsed",JSON.stringify(!p)),YD(p),p)I&&((Le=E.current)==null||Le.open(I));else{const $e=n.filter(Ue=>Ue.parent===0).map(Ue=>Ue.id);console.log("closeIds:",$e),(Me=E.current)==null||Me.close($e)}},[H,Y]=q.useState(!1),ne=p?"collapsed":"expanded",Z=Le=>`${Le} ${ne}`,ce=q.useRef(null);q.useLayoutEffect(()=>{(async()=>{var Me,$e;try{const Ue=t.menuPath||"/global-menu-config/api/v1/menu-items/user",he=t.baseUrl+Ue,{data:Ce}=await As.get(he);let Pe=Ce.map(tt=>({...tt,parentKey:tt.parentKey||0}));Pe=qD(Pe),t.replacePath&&(Pe=GD(Pe,t.replacePath));const Ne=Pe.map(tt=>({id:tt.id,parent:tt.parentKey,text:tt.name,data:tt}));r(Ne)}catch(Ue){console.error("Global menu",Ue),Wd((($e=(Me=Ue.response)==null?void 0:Me.data)==null?void 0:$e.errorMessage)||"Have error when get menu items")}})()},[t.baseUrl,t.menuPath,t.replacePath]);const S=async()=>{try{const Le=await fetch(`${t.baseUrl}/global-menu-config/api/v1/menu-items/user/get-favorites`);if(!Le.ok)throw new Error("Failed to fetch favorite items");const Me=await Le.json();f(Me)}catch(Le){console.error("Error fetching favorite items:",Le)}};q.useEffect(()=>{S()},[t.baseUrl]),q.useEffect(()=>{let Le=[];c.forEach(Ue=>{const he=i.find(Ce=>Ce.id===Ue&&Ce.isFavorite===!0);he&&(Le=[...Le,he])}),console.log(Le);function Me(Ue){return i.every(he=>he.parentKey!==Ue.id)?Ue:{...Ue,children:i.filter(he=>he.parentKey===Ue.id).map(he=>Me(he))}}const $e=Le.map(Ue=>Me(Ue));h6($e)},[i]);function ue(Le){const Me=Le.detail.menuItem;r($e=>$e.map(Ue=>Ue.id!==Me.id?Ue:{...Ue,data:Me})),S()}q.useEffect(()=>(window.addEventListener("updateFavoriteMenu",ue),()=>{window.removeEventListener("updateFavoriteMenu",ue)}),[]),q.useLayoutEffect(()=>{var Ue;const Le=localStorage.getItem("scrollPos");Le&&ce.current&&setTimeout(()=>{const he=ce.current.getScrollElement();he.scrollTop=parseInt(Le)},0);const Me=()=>{if(ce.current){const he=ce.current.getScrollElement();localStorage.setItem("scrollPos",he.scrollTop.toString())}},$e=(Ue=ce.current)==null?void 0:Ue.getScrollElement();return $e==null||$e.addEventListener("scroll",Me),()=>{$e==null||$e.removeEventListener("scroll",Me)}},[i]);function ae(Le){a(!0);const Me=[...n];r(Le);const $e=Le.map((Ue,he)=>({menuItemId:Ue.id,order:he}));As.post("/global-menu-config/api/v1/menu-items/user",$e,{baseURL:t.baseUrl}).then(()=>{}).catch(Ue=>{console.error(Ue),r(Me)}).finally(()=>{a(!1)})}const Ge=q.useMemo(()=>Gh==="false"?I:[],[]);return console.log("nodesglobal menu",n),_e.jsxs("div",{className:Z("side-bar"),children:[_e.jsx("div",{className:Z("wrap-section side-bar__wrapper-toggle-btn"),children:_e.jsx("button",{className:"icon-btn side-bar__toggle-btn",onClick:_,children:p?_e.jsx(a6,{}):_e.jsx(s6,{})})}),_e.jsx(Wv,{ref:ce,className:Z("wrap-section side-bar__menu"),style:{marginTop:24,flex:1,overflow:"auto",height:"100%",overflowX:"hidden"},children:_e.jsx(UE,{backend:eH,options:EH(),children:_e.jsx(HH,{ref:E,classes:{root:"treeRoot",draggingSource:"draggingSource",placeholder:"placeholderContainer",listItem:Le=>{var Me;return((Me=Le.data)==null?void 0:Me.name)==="Home"?"isHome":""}},tree:n,rootId:0,sort:!1,insertDroppableFirst:!1,enableAnimateExpand:!0,dropTargetOffset:10,onDrop:ae,render:(Le,Me)=>{function $e(Pe){return n.every(Ne=>Ne.parent!==Pe.id)?Pe:{...Pe,children:n.filter(Ne=>Ne.parent===Pe.id).map(Ne=>$e(Ne.data))}}const Ue=$e(Le.data),he=Pe=>A.some(Ne=>Ne.id===Pe);function Ce(Pe,Ne){r(tt=>tt.map(me=>me.id===Pe?{...me,data:{...me.data,isFavorite:Ne}}:me)),S()}return _e.jsx(zD,{isInternalApp:t.isInternalApp,isActive:he,isCollapsed:p,replacePath:t.replacePath,ssr:t.ssr,brandColors:t.brandColors,baseUrl:t.baseUrl,node:Le,params:Me,nodes:n,item:Ue,expanded:()=>!1,toggleExpand:Pe=>{var Ne;if(Pe.stopPropagation(),Me.isOpen)console.log("open toggleExpand"),Me.onToggle();else{console.log("close toggleExpand");const tt=n.filter(me=>me.parent===Le.parent&&me.id!==Le.id).map(me=>me.id);console.log(" closeIds:",tt),(Ne=E.current)==null||Ne.open(Le.id),setTimeout(()=>{var me;(me=E.current)==null||me.close(tt)},0)}},level:Me.depth,onSetFavoriteSuccess:Ce})},placeholderRender:(Le,{depth:Me})=>{var $e;return _e.jsx(c6,{node:Le,depth:Me,color:($e=t.brandColors)==null?void 0:$e.primary300,isCollapsed:p})},canDrag:()=>!o,canDrop:(Le,{dragSource:Me,dropTargetId:$e})=>(Me==null?void 0:Me.parent)===$e,onDragStart:Le=>{console.log("onDragStart",Le)},onChangeOpen:Le=>{localStorage.getItem("isCollapsed")==="false"&&(console.log("onChangeOpen:",Le),M(Le))},initialOpen:Ge})})}),_e.jsxs("div",{className:Z("wrap-section side-bar__wrap-btn-logout"),children:[_e.jsxs("button",{className:Z("side-bar__logout-btn"),onClick:()=>Y(!0),children:[_e.jsx(l6,{className:Z("side-bar__icon-logout")}),_e.jsx("span",{className:Z("side-bar__logout-btn__text"),children:"Logout"})]}),_e.jsx(X1,{isOpen:H,onClose:()=>Y(!1),onConfirm:()=>t.logout?t.logout():oT(t.baseUrl)})]})]})}const O1={"/stella/page/SiteManagement/Company/List?tenantId=1":["/stella/page/SiteManagement/Portfolio","/stella/page/SiteManagement/Company","/stella/page/SiteManagement/Region","/stella/page/SiteManagement/Location","/stella/page/SiteManagement/Zone","/stella/page/SiteManagement/Service","/stella/page/SiteManagement/Sign"],"/stella/page/SiteManagement/Portfolio/List":["/stella/page/SiteManagement/Portfolio","/stella/page/SiteManagement/Company","/stella/page/SiteManagement/Region","/stella/page/SiteManagement/Location","/stella/page/SiteManagement/Zone","/stella/page/SiteManagement/Service","/stella/page/SiteManagement/Sign"],"/stella/page/SiteManagement/CountryRegion/List":["/stella/page/SiteManagement/CountryRegion"],"/stella/page/SiteManagement/VehicleListController/List":["/stella/page/SiteManagement/VehicleListController"],"/stella/page/ContraventionManagement/CorrespondenceTemplate/List":["/stella/page/ContraventionManagement/CorrespondenceTemplate"],"/stella/page/ContraventionManagement/VerificationsAudit/List":["/stella/page/ContraventionManagement/VerificationsAudit"],"/stella/page/ContraventionManagement/PendingWardenVerification/List":["/stella/page/ContraventionManagement/PendingWardenVerification"],"/stella/page/ContraventionManagement/Appeal/Search":["/stella/page/ContraventionManagement/Appeal"],"/stella/page/ContraventionManagement/Contravention/Search":["/stella/page/ContraventionManagement/Contravention"],"/stella/page/ContraventionManagement/Tag/Search":["/stella/page/ContraventionManagement/Tag"],"/stella/page/ContraventionManagement/WorkflowMapping/List":["/stella/page/ContraventionManagement/WorkflowMapping"],"/stella/page/ContraventionManagement/WorkflowLetterTemplateMapping/List":["/stella/page/ContraventionManagement/WorkflowLetterTemplateMapping"],"/stella/page/ContraventionManagement/ScannedAppeal/Summary":["/stella/page/ContraventionManagement/ScannedAppeal"],"/stella/page/ContraventionManagement/PendingAppealWorkQueue/List":["/stella/page/ContraventionManagement/PendingAppeal"],"/stella/page/ContraventionManagement/NoDecisionAIAppeal/List":["/stella/page/ContraventionManagement/NoDecisionAIAppeal"],"/stella/page/ContraventionManagement/VerifyAIAppeal/List":["/stella/page/ContraventionManagement/VerifyAIAppeal"],"/anpr/page/LocationDisableReasons/Index":["/anpr/page/LocationDisableReasons"],"/anpr/page/Tags/Index":["/anpr/page/Tags"],"/anpr/page/VendorLocations/Index":["/anpr/page/VendorLocations"],"/anpr/page/Cameras/Index":["/anpr/page/Cameras"],"/anpr/page/Locations/Index":["/anpr/page/Locations"],"/anpr/page/Devices/Index":["/anpr/page/Devices","/anpr/page/Locations"],"/anpr/page/Technical/Overview":["/anpr/page/Technical"],"/anpr/page/Technical/Index":["/anpr/page/Technical"],"/anpr/page/Technical/Index?priority=P1":["/anpr/page/Technical"],"/anpr/page/Technical/Index?priority=P2":["/anpr/page/Technical"],"/anpr/page/Technical/Index?priority=P3":["/anpr/page/Technical"],"/anpr/page/Technical/Index?priority=P4":["/anpr/page/Technical"],"/anpr/page/CustomVerifications/WipByLocation":["/anpr/page/CustomVerifications"],"/anpr/page/Issues/Index?status=Closed":["/anpr/page/Issues"],"/anpr/page/Issues/Index":["/anpr/page/Issues"],"/anpr/page/Issues/Overview":["/anpr/page/Issues"]};function g6(t,e){const r=t.replace(window.origin,""),i=new URL(r,window.location.origin),o=new URL(e,window.origin),a=localStorage.getItem("latestClickMenuPath");return r&&O1[r]&&O1[r].some(c=>e.includes(c))?a===r?5:4:i.pathname===o.pathname&&i.search===o.search?3:i.pathname===o.pathname?2:o.pathname.startsWith(i.pathname)?1:0}function m6(t,e){const n=t.map(a=>({item:a,priority:a.path?g6(a.path,e):0})).filter(a=>a.priority>0),r=n.length>0?n.reduce((a,c)=>c.priority>a.priority?c:a).item:null,i=[];let o=r;for(;o;)i.unshift(o),o=t.find(a=>a.id===(o==null?void 0:o.parentKey))||null;return i}function GD(t,e){return t.map(n=>{var r;return(r=n.children)!=null&&r.length?(n.path="",n.children=GD(n.children,e)):n.path=e(n.path),n})}function qD(t){return t.map(n=>n.path&&!n.path.includes("http")&&n.path.includes("/")?{...n,path:window.location.origin+n.path}:(n.children&&(n.children=qD(n.children)),n))}function v6(t){return _e.jsx(WD.div,{children:_e.jsx(Vv,{styles:[VT,u6,f6],style:{position:"sticky",zIndex:1300},children:_e.jsx(p6,{...t})})})}const y6={"page-container":"_page-container_1pwo1_1","page-main-content":"_page-main-content_1pwo1_8","page-title":"_page-title_1pwo1_19","text-base":"_text-base_1pwo1_26","mt-4":"_mt-4_1pwo1_33"};var bp={exports:{}};/**
|
|
137
137
|
* @license
|
|
138
138
|
* Lodash <https://lodash.com/>
|
|
139
139
|
* Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
|
|
@@ -29847,7 +29847,10 @@ function QD({ ...t }) {
|
|
|
29847
29847
|
// : undefined,
|
|
29848
29848
|
},
|
|
29849
29849
|
onClick: (Ge) => {
|
|
29850
|
-
|
|
29850
|
+
le === "a" && ge === "_blank" || o || (localStorage.setItem(
|
|
29851
|
+
"latestClickMenuPath",
|
|
29852
|
+
(e.path || "").replace(window.location.origin, "")
|
|
29853
|
+
), t.toggleExpand(Ge));
|
|
29851
29854
|
},
|
|
29852
29855
|
children: [
|
|
29853
29856
|
/* @__PURE__ */ Ve(d6, { cls: T, item: e }),
|
|
@@ -30336,10 +30339,22 @@ function S6(t) {
|
|
|
30336
30339
|
}
|
|
30337
30340
|
const L1 = {
|
|
30338
30341
|
"/stella/page/SiteManagement/Company/List?tenantId=1": [
|
|
30339
|
-
"/stella/page/SiteManagement/
|
|
30342
|
+
"/stella/page/SiteManagement/Portfolio",
|
|
30343
|
+
"/stella/page/SiteManagement/Company",
|
|
30344
|
+
"/stella/page/SiteManagement/Region",
|
|
30345
|
+
"/stella/page/SiteManagement/Location",
|
|
30346
|
+
"/stella/page/SiteManagement/Zone",
|
|
30347
|
+
"/stella/page/SiteManagement/Service",
|
|
30348
|
+
"/stella/page/SiteManagement/Sign"
|
|
30340
30349
|
],
|
|
30341
30350
|
"/stella/page/SiteManagement/Portfolio/List": [
|
|
30342
|
-
"/stella/page/SiteManagement/Portfolio"
|
|
30351
|
+
"/stella/page/SiteManagement/Portfolio",
|
|
30352
|
+
"/stella/page/SiteManagement/Company",
|
|
30353
|
+
"/stella/page/SiteManagement/Region",
|
|
30354
|
+
"/stella/page/SiteManagement/Location",
|
|
30355
|
+
"/stella/page/SiteManagement/Zone",
|
|
30356
|
+
"/stella/page/SiteManagement/Service",
|
|
30357
|
+
"/stella/page/SiteManagement/Sign"
|
|
30343
30358
|
],
|
|
30344
30359
|
"/stella/page/SiteManagement/CountryRegion/List": [
|
|
30345
30360
|
"/stella/page/SiteManagement/CountryRegion"
|
|
@@ -30393,7 +30408,7 @@ const L1 = {
|
|
|
30393
30408
|
"/anpr/page/VendorLocations/Index": ["/anpr/page/VendorLocations"],
|
|
30394
30409
|
"/anpr/page/Cameras/Index": ["/anpr/page/Cameras"],
|
|
30395
30410
|
"/anpr/page/Locations/Index": ["/anpr/page/Locations"],
|
|
30396
|
-
"/anpr/page/Devices/Index": ["/anpr/page/Devices"],
|
|
30411
|
+
"/anpr/page/Devices/Index": ["/anpr/page/Devices", "/anpr/page/Locations"],
|
|
30397
30412
|
//
|
|
30398
30413
|
"/anpr/page/Technical/Overview": ["/anpr/page/Technical"],
|
|
30399
30414
|
"/anpr/page/Technical/Index": ["/anpr/page/Technical"],
|
|
@@ -30410,7 +30425,7 @@ const L1 = {
|
|
|
30410
30425
|
};
|
|
30411
30426
|
function T6(t, e) {
|
|
30412
30427
|
const r = t.replace(window.origin, ""), i = new URL(r, window.location.origin), o = new URL(e, window.origin), a = localStorage.getItem("latestClickMenuPath");
|
|
30413
|
-
return
|
|
30428
|
+
return r && L1[r] && L1[r].some((c) => e.includes(c)) ? a === r ? 5 : 4 : i.pathname === o.pathname && i.search === o.search ? 3 : i.pathname === o.pathname ? 2 : o.pathname.startsWith(i.pathname) ? 1 : 0;
|
|
30414
30429
|
}
|
|
30415
30430
|
function C6(t, e) {
|
|
30416
30431
|
const n = t.map((a) => ({
|
package/dist/share/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../index.esm2017-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../index.esm2017-5ZwUVFAV.cjs"),m=require("axios"),u=require("react"),i=require("react/jsx-runtime");require("@r2wc/react-to-web-component");const l=require("react-router-dom");require("@mui/material");const c=s=>{const[t,o]=u.useState([]);return u.useEffect(()=>{m.get(`${s}/user-management/api/v1/users/my-account/permissions`,{withCredentials:!0}).then(r=>o(r.data)).catch(r=>{console.error("Getting user permission error:",r)})},[s]),t},a=s=>(t,o)=>{const r=c(s);return o?t.every(n=>r==null?void 0:r.includes(n)):t.some(n=>r==null?void 0:r.includes(n))},h=({baseUrl:s,accessWith:t,requireAll:o,children:r})=>a(s)(t,o)?i.jsx(i.Fragment,{children:r}):null,P=({accessWith:s,requireAll:t,baseUrl:o,unAuthorizedPath:r,children:n})=>a(o)(s,t)?i.jsx(i.Fragment,{children:n}):i.jsx(l.Navigate,{to:r,replace:!0});exports.AuthContext=e.AuthContext;exports.AuthProvider=e.AuthProvider;exports.ERROR_MESSAGE=e.ERROR_MESSAGE;exports.SaasThemeProvider=e.SaasThemeProvider;exports.TranslationProvider=e.TranslationProvider;exports.axiosInstance=e.axiosInstance;exports.color=e.color;exports.createCustomTheme=e.createCustomTheme;exports.handleErrorAxios=e.handleErrorAxios;exports.login=e.login;exports.logout=e.logout;exports.responseInterceptor=e.responseInterceptor;exports.search=e.search;exports.setFavicon=e.setFavicon;exports.translate=e.translate;exports.translationConfig=e.translationConfig;exports.useAuth=e.useAuth;exports.useCustomTranslation=e.useCustomTranslation;exports.useTheme=e.useTheme;exports.useTranslation=e.useTranslation$1;exports.HasPermission=h;exports.PermissionRoute=P;exports.getUseHasPermission=a;exports.useGetPermission=c;
|
package/dist/share/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { M as R, N as S, O as G, a0 as y, Y as F, a as H, c as I, Z as M, U as N, R as O, T as $, V as j, v as w, $ as U, t as V, W as X, b as Y, u as Z, g as _, X as b } from "../index.esm2017-
|
|
1
|
+
import { M as R, N as S, O as G, a0 as y, Y as F, a as H, c as I, Z as M, U as N, R as O, T as $, V as j, v as w, $ as U, t as V, W as X, b as Y, u as Z, g as _, X as b } from "../index.esm2017-DUxPJxVH.js";
|
|
2
2
|
import u from "axios";
|
|
3
3
|
import { useState as m, useEffect as c } from "react";
|
|
4
4
|
import { jsx as a, Fragment as n } from "react/jsx-runtime";
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import "../react-to-web-component-
|
|
2
|
-
import { F as i, u as m } from "../index-
|
|
3
|
-
import "../index-
|
|
4
|
-
import "../index-
|
|
1
|
+
import "../react-to-web-component-D7SoYMky.js";
|
|
2
|
+
import { F as i, u as m } from "../index-CjGg-DF7.js";
|
|
3
|
+
import "../index-Cx0zTfOC.js";
|
|
4
|
+
import "../index-DE6E5mlm.js";
|
|
5
5
|
export {
|
|
6
6
|
i as FavoriteMenu,
|
|
7
7
|
m as updateFavoriteItems
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import "../react-to-web-component-
|
|
2
|
-
import { G as i } from "../index-
|
|
3
|
-
import "../index-
|
|
4
|
-
import "../index-
|
|
1
|
+
import "../react-to-web-component-D7SoYMky.js";
|
|
2
|
+
import { G as i } from "../index-CjGg-DF7.js";
|
|
3
|
+
import "../index-Cx0zTfOC.js";
|
|
4
|
+
import "../index-DE6E5mlm.js";
|
|
5
5
|
export {
|
|
6
6
|
i as GlobalMenu
|
|
7
7
|
};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import "../react-to-web-component-
|
|
2
|
-
import { L as n, T as s } from "../index-
|
|
3
|
-
import "../index-
|
|
4
|
-
import "../index-
|
|
5
|
-
import "../index-
|
|
6
|
-
import "../react-toastify.esm-
|
|
1
|
+
import "../react-to-web-component-D7SoYMky.js";
|
|
2
|
+
import { L as n, T as s } from "../index-CjGg-DF7.js";
|
|
3
|
+
import "../index-Cx0zTfOC.js";
|
|
4
|
+
import "../index-CI-NA37P.js";
|
|
5
|
+
import "../index-DE6E5mlm.js";
|
|
6
|
+
import "../react-toastify.esm-Y1WvK90L.js";
|
|
7
7
|
import "../toast-config/index.js";
|
|
8
8
|
import "../toast-config-notification/index.js";
|
|
9
9
|
export {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import "../react-to-web-component-
|
|
2
|
-
import { H as e, g as m } from "../index-
|
|
3
|
-
import "../index-
|
|
1
|
+
import "../react-to-web-component-D7SoYMky.js";
|
|
2
|
+
import { H as e, g as m } from "../index-CjGg-DF7.js";
|
|
3
|
+
import "../index-DE6E5mlm.js";
|
|
4
4
|
export {
|
|
5
5
|
e as HasPermission,
|
|
6
6
|
m as getUseHasPermission
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as $, c as ce, g as Jt, s as Xt, j as E } from "./react-to-web-component-
|
|
1
|
+
import { r as $, c as ce, g as Jt, s as Xt, j as E } from "./react-to-web-component-D7SoYMky.js";
|
|
2
2
|
import { _ as Wt, a as Z } from "./setPrototypeOf-BVKdEITT.js";
|
|
3
3
|
function Gt(i, e) {
|
|
4
4
|
for (var t = 0; t < e.length; t++) {
|