@sg-front-core/layout-v1 1.0.0

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.
@@ -0,0 +1,4 @@
1
+ (function(){"use strict";try{if(typeof document<"u"){var t=document.createElement("style");t.appendChild(document.createTextNode('.sg-layout .modern-top-menu{position:relative;display:flex;align-items:center;min-width:0;flex:1;--sg-topmenu-btn-size: 32px;--sg-topmenu-btn-offset: 10px;--sg-topmenu-btn-gap: 12px;--sg-topmenu-safe-inline: calc( var(--sg-topmenu-btn-size) + var(--sg-topmenu-btn-offset) + var(--sg-topmenu-btn-gap) )}.sg-layout .modern-top-menu:before,.sg-layout .modern-top-menu:after{content:"";position:absolute;top:0;bottom:0;width:28px;pointer-events:none;opacity:0;transition:opacity .2s ease;z-index:2}.sg-layout .modern-top-menu.is-scroll-left:before{left:0;opacity:1;background:linear-gradient(to right,var(--sg-layout-header-bg, rgba(248, 250, 252, .98)),rgba(248,250,252,0))}.sg-layout .modern-top-menu.is-scroll-right:after{right:0;opacity:1;background:linear-gradient(to left,var(--sg-layout-header-bg, rgba(248, 250, 252, .98)),rgba(248,250,252,0))}.sg-layout .modern-top-menu__btn.ant-btn{position:absolute;top:50%;transform:translateY(-50%);width:var(--sg-topmenu-btn-size);height:var(--sg-topmenu-btn-size);padding:0;border-radius:999px;background:#ffffffe6;border:1px solid rgba(226,232,240,1);box-shadow:0 8px 20px #0f172a14;display:none;align-items:center;justify-content:center;z-index:3}.sg-layout .modern-top-menu__btn--left.ant-btn{left:var(--sg-topmenu-btn-offset)!important}.sg-layout .modern-top-menu__btn--right.ant-btn{right:var(--sg-topmenu-btn-offset)!important}.sg-layout .modern-top-menu.is-scroll-left .modern-top-menu__btn--left.ant-btn,.sg-layout .modern-top-menu.is-scroll-right .modern-top-menu__btn--right.ant-btn{display:inline-flex}.sg-layout .modern-ul{display:flex;flex-direction:row;flex-wrap:nowrap;align-items:center;overflow-x:auto;overflow-y:hidden;white-space:nowrap;-webkit-overflow-scrolling:touch;scrollbar-width:none;padding:0 6px 0 0!important;margin:0;list-style:none;scroll-snap-type:x proximity;gap:2px;writing-mode:horizontal-tb!important;text-orientation:mixed}.sg-layout .modern-ul::-webkit-scrollbar{display:none}.sg-layout .modern-ul li{display:flex!important;align-items:center;justify-content:center;position:relative;flex:0 0 auto!important;flex-shrink:0!important;width:auto!important;min-width:max-content;white-space:nowrap!important;word-break:keep-all!important;scroll-snap-align:start;border-radius:10px;min-height:56px;padding:0 16px;writing-mode:horizontal-tb!important;text-orientation:mixed}.sg-layout .modern-top-menu__item{cursor:pointer;position:relative;font-weight:700;font-size:14px;color:#0f172ae6;transition:all .2s ease}.sg-layout .modern-top-menu__item-text{display:inline-block;white-space:nowrap!important;max-width:140px;overflow:hidden;text-overflow:ellipsis;text-shadow:0 1px 2px rgba(15,23,42,.08);position:relative;z-index:1;writing-mode:horizontal-tb!important;text-orientation:mixed}.sg-layout .modern-top-menu.is-scroll-left .modern-ul{padding-left:var(--sg-topmenu-safe-inline)!important}.sg-layout .modern-top-menu.is-scroll-right .modern-ul{padding-right:var(--sg-topmenu-safe-inline)!important}.sg-layout .modern-ul li:after{position:absolute;content:"";top:0;left:0;width:100%;height:3px;background:var(--sg-theme-primary, #6366f1);transform:scale(0);transform-origin:right;transition:transform .5s;z-index:0;pointer-events:none}.sg-layout .modern-ul li:hover{background:#14141408;border-radius:0!important}.sg-layout .modern-ul .menu-checked:hover{background:var(--sg-theme-primary, #6366f1)}.sg-layout .modern-ul li:hover:after{transform:scale(1);transform-origin:left}.sg-layout .modern-ul .menu-checked{background:var(--sg-theme-primary, #6366f1);border-radius:0!important}.sg-layout .modern-ul .menu-checked span{color:#fff}.sg-layout .modern-ul .menu-checked .modern-top-menu__item-text{text-shadow:none}')),document.head.appendChild(t)}}catch(e){console.error("vite-plugin-css-injected-by-js",e)}})();
2
+ (function(G,u){typeof exports=="object"&&typeof module<"u"?u(exports,require("react/jsx-runtime"),require("antd"),require("@sg-front-core/ui-v1"),require("@ant-design/icons"),require("react"),require("react-router-dom"),require("react-dom"),require("sggkui")):typeof define=="function"&&define.amd?define(["exports","react/jsx-runtime","antd","@sg-front-core/ui-v1","@ant-design/icons","react","react-router-dom","react-dom","sggkui"],u):(G=typeof globalThis<"u"?globalThis:G||self,u(G["@sg-front-core/layout-v1"]={},G.jsxRuntime,G.antd,G.SgFrontCoreUiV1,G.AntDesignIcons,G.React,G.ReactRouterDOM,G.ReactDOM,G.sggkui))})(this,(function(G,u,V,te,Te,p,Z,Se,Qt){"use strict";function ft(e){var n,r,t="";if(typeof e=="string"||typeof e=="number")t+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(n=0;n<o;n++)e[n]&&(r=ft(e[n]))&&(t&&(t+=" "),t+=r)}else for(r in e)e[r]&&(t&&(t+=" "),t+=r);return t}function fe(){for(var e,n,r=0,t="",o=arguments.length;r<o;r++)(e=arguments[r])&&(n=ft(e))&&(t&&(t+=" "),t+=n);return t}function Be(e){const{status:n,setStatus:r,closeIcon:t="drawer-close",openIcon:o="drawer-open",color:i="rgba(0,0,0,.25)"}=e,s=fe("fixed top-1/2 -translate-y-1/2 z-40","origin-center","cursor-pointer","opacity-30","hover:opacity-100","transition-all","duration-300");return u.jsx("div",{children:n?u.jsx(V.Tooltip,{title:"收起侧边栏",placement:"right",children:u.jsx(te.Iconfont,{icon:t,className:`${s} left-[248px]`,size:30,color:i,onClick:()=>r(!n)})}):u.jsx(V.Tooltip,{title:"展开侧边栏",placement:"right",children:u.jsx(te.Iconfont,{icon:o,className:`${s} left-0`,size:30,color:i,onClick:()=>r(!n)})})})}const R={};function Rt(e){R.useSystemStore=e.useSystemStore,R.local=e.local,R.request=e.request,R.projectCName=e.projectCName,R.isLegacyLayoutStyle=e.isLegacyLayoutStyle}function ie(){if(!R.useSystemStore)throw new Error("[@sg-front-core/layout-v1] missing setup: call setupSgTemplateLayout({ useSystemStore, local, request, ... }) before rendering layouts.");return R.useSystemStore()}function He(){if(!R.local)throw new Error("[@sg-front-core/layout-v1] missing setup: call setupSgTemplateLayout({ local, ... }).");return R.local}function dt(){if(!R.request)throw new Error("[@sg-front-core/layout-v1] missing setup: call setupSgTemplateLayout({ request, ... }).");return R.request}function pt(){return R.projectCName??""}function en(e){return R.isLegacyLayoutStyle?R.isLegacyLayoutStyle(e):e===0||e==="legacy"||e===!1}const ht=e=>e.filter(r=>r.path!=null).map(r=>r.handle?.hidden?null:r.children&&r.children.length>0?{label:r.handle.title,key:r.path,icon:u.jsx(Te.FolderOutlined,{}),hidden:r.handle?.hidden||!1,children:ht(r.children)}:{label:r.handle?.title||r.path,key:r.path,hidden:r.handle?.hidden||!1,link:r.handle?.link||null,frame:r.handle?.isFrame,processId:r.handle?.processId,query:r.handle?.query,icon:u.jsx(Te.TagOutlined,{})});function tn(e){return[{key:"home",label:"首页",children:e,closable:!1}]}var nn=function(e){return function(n,r){var t=p.useRef(!1);e(function(){return function(){t.current=!1}},[]),e(function(){if(!t.current)t.current=!0;else return n()},r)}},re=function(){return re=Object.assign||function(n){for(var r,t=1,o=arguments.length;t<o;t++){r=arguments[t];for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(n[i]=r[i])}return n},re.apply(this,arguments)};function vt(e,n){var r={};for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&n.indexOf(t)<0&&(r[t]=e[t]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,t=Object.getOwnPropertySymbols(e);o<t.length;o++)n.indexOf(t[o])<0&&Object.prototype.propertyIsEnumerable.call(e,t[o])&&(r[t[o]]=e[t[o]]);return r}function rn(e,n,r,t){function o(i){return i instanceof r?i:new r(function(s){s(i)})}return new(r||(r=Promise))(function(i,s){function a(d){try{l(t.next(d))}catch(f){s(f)}}function c(d){try{l(t.throw(d))}catch(f){s(f)}}function l(d){d.done?i(d.value):o(d.value).then(a,c)}l((t=t.apply(e,n||[])).next())})}function on(e,n){var r={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},t,o,i,s=Object.create((typeof Iterator=="function"?Iterator:Object).prototype);return s.next=a(0),s.throw=a(1),s.return=a(2),typeof Symbol=="function"&&(s[Symbol.iterator]=function(){return this}),s;function a(l){return function(d){return c([l,d])}}function c(l){if(t)throw new TypeError("Generator is already executing.");for(;s&&(s=0,l[0]&&(r=0)),r;)try{if(t=1,o&&(i=l[0]&2?o.return:l[0]?o.throw||((i=o.return)&&i.call(o),0):o.next)&&!(i=i.call(o,l[1])).done)return i;switch(o=0,i&&(l=[l[0]&2,i.value]),l[0]){case 0:case 1:i=l;break;case 4:return r.label++,{value:l[1],done:!1};case 5:r.label++,o=l[1],l=[0];continue;case 7:l=r.ops.pop(),r.trys.pop();continue;default:if(i=r.trys,!(i=i.length>0&&i[i.length-1])&&(l[0]===6||l[0]===2)){r=0;continue}if(l[0]===3&&(!i||l[1]>i[0]&&l[1]<i[3])){r.label=l[1];break}if(l[0]===6&&r.label<i[1]){r.label=i[1],i=l;break}if(i&&r.label<i[2]){r.label=i[2],r.ops.push(l);break}i[2]&&r.ops.pop(),r.trys.pop();continue}l=n.call(e,r)}catch(d){l=[6,d],o=0}finally{t=i=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}function J(e,n){var r=typeof Symbol=="function"&&e[Symbol.iterator];if(!r)return e;var t=r.call(e),o,i=[],s;try{for(;(n===void 0||n-- >0)&&!(o=t.next()).done;)i.push(o.value)}catch(a){s={error:a}}finally{try{o&&!o.done&&(r=t.return)&&r.call(t)}finally{if(s)throw s.error}}return i}function Q(e,n,r){if(r||arguments.length===2)for(var t=0,o=n.length,i;t<o;t++)(i||!(t in n))&&(i||(i=Array.prototype.slice.call(n,0,t)),i[t]=n[t]);return e.concat(i||Array.prototype.slice.call(n))}typeof SuppressedError=="function"&&SuppressedError;var ke=function(e){return typeof e=="function"},Ce=process.env.NODE_ENV==="development"||process.env.NODE_ENV==="test",de=function(e){Ce&&(ke(e)||console.error("useMemoizedFn expected parameter is a function, got ".concat(typeof e)));var n=p.useRef(e);n.current=p.useMemo(function(){return e},[e]);var r=p.useRef(void 0);return r.current||(r.current=function(){for(var t=[],o=0;o<arguments.length;o++)t[o]=arguments[o];return n.current.apply(this,t)}),r.current};const Ue=nn(p.useEffect);var yt=function(e,n){var r=n.manual,t=n.ready,o=t===void 0?!0:t,i=n.defaultParams,s=i===void 0?[]:i,a=n.refreshDeps,c=a===void 0?[]:a,l=n.refreshDepsAction,d=p.useRef(!1);return d.current=!1,Ue(function(){!r&&o&&(d.current=!0,e.run.apply(e,Q([],J(s),!1)))},[o]),Ue(function(){d.current||r||(d.current=!0,l?l():e.refresh())},Q([],J(c),!1)),{onBefore:function(){if(!o)return{stopNow:!0}}}};yt.onInit=function(e){var n=e.ready,r=n===void 0?!0:n,t=e.manual;return{loading:!t&&r}};function sn(e,n){if(e===n)return!0;for(var r=0;r<e.length;r++)if(!Object.is(e[r],n[r]))return!1;return!0}var mt=function(e,n){var r=p.useRef({deps:n,obj:void 0,initialized:!1}).current;return(r.initialized===!1||!sn(r.deps,n))&&(r.deps=n,r.obj=e(),r.initialized=!0),r.obj};function gt(e){var n=p.useRef(e);return n.current=e,n}var Ve=function(e){Ce&&(ke(e)||console.error("useUnmount expected parameter is a function, got ".concat(typeof e)));var n=gt(e);p.useEffect(function(){return function(){n.current()}},[])},Oe=new Map,an=function(e,n,r){var t=Oe.get(e);t?.timer&&clearTimeout(t.timer);var o=void 0;n>-1&&(o=setTimeout(function(){Oe.delete(e)},n)),Oe.set(e,re(re({},r),{timer:o}))},ln=function(e){return Oe.get(e)},Pe=new Map,cn=function(e){return Pe.get(e)},un=function(e,n){Pe.set(e,n),n.then(function(r){return Pe.delete(e),r}).catch(function(){Pe.delete(e)})},pe={},fn=function(e,n){pe[e]&&pe[e].forEach(function(r){return r(n)})},Ye=function(e,n){return pe[e]||(pe[e]=[]),pe[e].push(n),function(){var t=pe[e].indexOf(n);pe[e].splice(t,1)}},dn=function(e,n){var r=n.cacheKey,t=n.cacheTime,o=t===void 0?300*1e3:t,i=n.staleTime,s=i===void 0?0:i,a=n.setCache,c=n.getCache,l=p.useRef(void 0),d=p.useRef(void 0),f=function(v,E){a?a(E):an(v,o,E),fn(v,E.data)},m=function(v,E){return E===void 0&&(E=[]),c?c(E):ln(v)};return mt(function(){if(r){var v=m(r);v&&Object.hasOwnProperty.call(v,"data")&&(e.state.data=v.data,e.state.params=v.params,(s===-1||Date.now()-v.time<=s)&&(e.state.loading=!1)),l.current=Ye(r,function(E){e.setState({data:E})})}},[]),Ve(function(){var v;(v=l.current)===null||v===void 0||v.call(l)}),r?{onBefore:function(v){var E=m(r,v);return!E||!Object.hasOwnProperty.call(E,"data")?{}:s===-1||Date.now()-E.time<=s?{loading:!1,data:E?.data,error:void 0,returnNow:!0}:{data:E?.data,error:void 0}},onRequest:function(v,E){var w=cn(r);return w&&w!==d.current?{servicePromise:w}:(w=v.apply(void 0,Q([],J(E),!1)),d.current=w,un(r,w),{servicePromise:w})},onSuccess:function(v,E){var w;r&&((w=l.current)===null||w===void 0||w.call(l),f(r,{data:v,params:E,time:Date.now()}),l.current=Ye(r,function(P){e.setState({data:P})}))},onMutate:function(v){var E;r&&((E=l.current)===null||E===void 0||E.call(l),f(r,{data:v,params:e.state.params,time:Date.now()}),l.current=Ye(r,function(w){e.setState({data:w})}))}}:{}};function ge(e){var n=typeof e;return e!=null&&(n=="object"||n=="function")}var pn=typeof global=="object"&&global&&global.Object===Object&&global,hn=typeof self=="object"&&self&&self.Object===Object&&self,bt=pn||hn||Function("return this")(),Ke=function(){return bt.Date.now()},vn=/\s/;function yn(e){for(var n=e.length;n--&&vn.test(e.charAt(n)););return n}var mn=/^\s+/;function gn(e){return e&&e.slice(0,yn(e)+1).replace(mn,"")}var Le=bt.Symbol,Et=Object.prototype,bn=Et.hasOwnProperty,En=Et.toString,be=Le?Le.toStringTag:void 0;function xn(e){var n=bn.call(e,be),r=e[be];try{e[be]=void 0;var t=!0}catch{}var o=En.call(e);return t&&(n?e[be]=r:delete e[be]),o}var wn=Object.prototype,Tn=wn.toString;function Sn(e){return Tn.call(e)}var kn="[object Null]",Cn="[object Undefined]",xt=Le?Le.toStringTag:void 0;function wt(e){return e==null?e===void 0?Cn:kn:xt&&xt in Object(e)?xn(e):Sn(e)}function On(e){return e!=null&&typeof e=="object"}var Pn="[object Symbol]";function Ln(e){return typeof e=="symbol"||On(e)&&wt(e)==Pn}var Tt=NaN,Nn=/^[-+]0x[0-9a-f]+$/i,jn=/^0b[01]+$/i,_n=/^0o[0-7]+$/i,An=parseInt;function St(e){if(typeof e=="number")return e;if(Ln(e))return Tt;if(ge(e)){var n=typeof e.valueOf=="function"?e.valueOf():e;e=ge(n)?n+"":n}if(typeof e!="string")return e===0?e:+e;e=gn(e);var r=jn.test(e);return r||_n.test(e)?An(e.slice(2),r?2:8):Nn.test(e)?Tt:+e}var Mn="Expected a function",Wn=Math.max,$n=Math.min;function kt(e,n,r){var t,o,i,s,a,c,l=0,d=!1,f=!1,m=!0;if(typeof e!="function")throw new TypeError(Mn);n=St(n)||0,ge(r)&&(d=!!r.leading,f="maxWait"in r,i=f?Wn(St(r.maxWait)||0,n):i,m="trailing"in r?!!r.trailing:m);function v(_){var k=t,g=o;return t=o=void 0,l=_,s=e.apply(g,k),s}function E(_){return l=_,a=setTimeout(T,n),d?v(_):s}function w(_){var k=_-c,g=_-l,S=n-k;return f?$n(S,i-g):S}function P(_){var k=_-c,g=_-l;return c===void 0||k>=n||k<0||f&&g>=i}function T(){var _=Ke();if(P(_))return H(_);a=setTimeout(T,w(_))}function H(_){return a=void 0,m&&t?v(_):(t=o=void 0,s)}function L(){a!==void 0&&clearTimeout(a),l=0,t=c=o=a=void 0}function j(){return a===void 0?s:H(Ke())}function y(){var _=Ke(),k=P(_);if(t=arguments,o=this,c=_,k){if(a===void 0)return E(c);if(f)return clearTimeout(a),a=setTimeout(T,n),v(c)}return a===void 0&&(a=setTimeout(T,n)),s}return y.cancel=L,y.flush=j,y}var In=function(e,n){var r=n.debounceWait,t=n.debounceLeading,o=n.debounceTrailing,i=n.debounceMaxWait,s=p.useRef(void 0),a=p.useMemo(function(){var c={};return t!==void 0&&(c.leading=t),o!==void 0&&(c.trailing=o),i!==void 0&&(c.maxWait=i),c},[t,o,i]);return p.useEffect(function(){if(r){var c=e.runAsync.bind(e);return s.current=kt(function(l){l()},r,a),e.runAsync=function(){for(var l=[],d=0;d<arguments.length;d++)l[d]=arguments[d];return new Promise(function(f,m){var v;(v=s.current)===null||v===void 0||v.call(s,function(){c.apply(void 0,Q([],J(l),!1)).then(f).catch(m)})})},function(){var l;(l=s.current)===null||l===void 0||l.cancel(),e.runAsync=c}}},[r,a]),r?{onCancel:function(){var c;(c=s.current)===null||c===void 0||c.cancel()}}:{}},Fn=function(e,n){var r=n.loadingDelay,t=n.ready,o=p.useRef(void 0);if(!r)return{};var i=function(){o.current&&clearTimeout(o.current)};return{onBefore:function(){return i(),t!==!1&&(o.current=setTimeout(function(){e.setState({loading:!0})},r)),{loading:!1}},onFinally:function(){i()},onCancel:function(){i()}}},Ne=!!(typeof window<"u"&&window.document&&window.document.createElement);function Ge(){return Ne?document.visibilityState!=="hidden":!0}var je=new Set;function Dn(e){return je.add(e),function(){je.has(e)&&je.delete(e)}}if(Ne){var qn=function(){Ge()&&je.forEach(function(e){return e()})};window.addEventListener("visibilitychange",qn,!1)}var zn=function(e,n){var r=n.pollingInterval,t=n.pollingWhenHidden,o=t===void 0?!0:t,i=n.pollingErrorRetryCount,s=i===void 0?-1:i,a=p.useRef(void 0),c=p.useRef(void 0),l=p.useRef(0),d=function(){var f;a.current&&clearTimeout(a.current),(f=c.current)===null||f===void 0||f.call(c)};return Ue(function(){r||d()},[r]),r?{onBefore:function(){d()},onError:function(){l.current+=1},onSuccess:function(){l.current=0},onFinally:function(){s===-1||s!==-1&&l.current<=s?a.current=setTimeout(function(){!o&&!Ge()?c.current=Dn(function(){e.refresh()}):e.refresh()},r):l.current=0},onCancel:function(){d()}}:{}};function Bn(e,n){var r=!1;return function(){for(var t=[],o=0;o<arguments.length;o++)t[o]=arguments[o];r||(r=!0,e.apply(void 0,Q([],J(t),!1)),setTimeout(function(){r=!1},n))}}var Hn=function(){return Ne&&typeof navigator.onLine<"u"?navigator.onLine:!0},_e=new Set;function Un(e){return _e.add(e),function(){_e.has(e)&&_e.delete(e)}}if(Ne){var Ct=function(){!Ge()||!Hn()||_e.forEach(function(e){return e()})};window.addEventListener("visibilitychange",Ct,!1),window.addEventListener("focus",Ct,!1)}var Vn=function(e,n){var r=n.refreshOnWindowFocus,t=n.focusTimespan,o=t===void 0?5e3:t,i=p.useRef(void 0),s=function(){var a;(a=i.current)===null||a===void 0||a.call(i)};return p.useEffect(function(){if(r){var a=Bn(e.refresh.bind(e),o);i.current=Un(function(){a()})}return function(){s()}},[r,o]),Ve(function(){s()}),{}},Yn=function(e,n){var r=n.retryInterval,t=n.retryCount,o=p.useRef(void 0),i=p.useRef(0),s=p.useRef(!1);return t?{onBefore:function(){s.current||(i.current=0),s.current=!1,o.current&&clearTimeout(o.current)},onSuccess:function(){i.current=0},onError:function(){if(i.current+=1,t===-1||i.current<=t){var a=r??Math.min(1e3*Math.pow(2,i.current),3e4);o.current=setTimeout(function(){s.current=!0,e.refresh()},a)}else i.current=0},onCancel:function(){i.current=0,o.current&&clearTimeout(o.current)}}:{}},Kn="Expected a function";function Gn(e,n,r){var t=!0,o=!0;if(typeof e!="function")throw new TypeError(Kn);return ge(r)&&(t="leading"in r?!!r.leading:t,o="trailing"in r?!!r.trailing:o),kt(e,n,{leading:t,maxWait:n,trailing:o})}var Xn=function(e,n){var r=n.throttleWait,t=n.throttleLeading,o=n.throttleTrailing,i=p.useRef(void 0),s={};return t!==void 0&&(s.leading=t),o!==void 0&&(s.trailing=o),p.useEffect(function(){if(r){var a=e.runAsync.bind(e);return i.current=Gn(function(c){c()},r,s),e.runAsync=function(){for(var c=[],l=0;l<arguments.length;l++)c[l]=arguments[l];return new Promise(function(d,f){var m;(m=i.current)===null||m===void 0||m.call(i,function(){a.apply(void 0,Q([],J(c),!1)).then(d).catch(f)})})},function(){var c;e.runAsync=a,(c=i.current)===null||c===void 0||c.cancel()}}},[r,t,o]),r?{onCancel:function(){var a;(a=i.current)===null||a===void 0||a.cancel()}}:{}},Xe=function(e){Ce&&(ke(e)||console.error('useMount: parameter `fn` expected to be a function, but got "'.concat(typeof e,'".'))),p.useEffect(function(){var n=e?.();if(!(n&&typeof n=="object"&&typeof n.then=="function"))return n},[])},Zn=function(){var e=J(p.useState({}),2),n=e[1];return de(function(){return n({})})},Jn=(function(){function e(n,r,t,o){o===void 0&&(o={}),this.serviceRef=n,this.options=r,this.subscribe=t,this.initState=o,this.pluginImpls=[],this.count=0,this.state={loading:!1,params:void 0,data:void 0,error:void 0},this.state=re(re(re({},this.state),{loading:!r.manual}),o)}return e.prototype.setState=function(n){n===void 0&&(n={}),this.state=re(re({},this.state),n),this.subscribe()},e.prototype.runPluginHandler=function(n){for(var r=[],t=1;t<arguments.length;t++)r[t-1]=arguments[t];var o=this.pluginImpls.map(function(i){var s;return(s=i[n])===null||s===void 0?void 0:s.call.apply(s,Q([i],J(r),!1))}).filter(Boolean);return Object.assign.apply(Object,Q([{}],J(o),!1))},e.prototype.runAsync=function(){for(var n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];return rn(this,void 0,void 0,function(){var t,o,i,s,a,c,l,d,f,m,v,E,w,P,T,H,L,j,y,_,k;return on(this,function(g){switch(g.label){case 0:if(this.count+=1,t=this.count,o=this.runPluginHandler("onBefore",n),i=o.stopNow,s=i===void 0?!1:i,a=o.returnNow,c=a===void 0?!1:a,l=vt(o,["stopNow","returnNow"]),s)return[2,Promise.resolve(l.data)];if(this.setState(re({loading:!0,params:n},l)),c)return[2,Promise.resolve(l.data)];(w=(E=this.options).onBefore)===null||w===void 0||w.call(E,n),g.label=1;case 1:return g.trys.push([1,3,,4]),d=this.runPluginHandler("onRequest",this.serviceRef.current,n).servicePromise,d||(d=(v=this.serviceRef).current.apply(v,Q([],J(n),!1))),[4,d];case 2:return f=g.sent(),t!==this.count?[2,new Promise(function(){})]:(this.setState({data:f,error:void 0,loading:!1}),(T=(P=this.options).onSuccess)===null||T===void 0||T.call(P,f,n),this.runPluginHandler("onSuccess",f,n),(L=(H=this.options).onFinally)===null||L===void 0||L.call(H,n,f,void 0),t===this.count&&this.runPluginHandler("onFinally",n,f,void 0),[2,f]);case 3:if(m=g.sent(),t!==this.count)return[2,new Promise(function(){})];throw this.setState({error:m,loading:!1}),(y=(j=this.options).onError)===null||y===void 0||y.call(j,m,n),this.runPluginHandler("onError",m,n),(k=(_=this.options).onFinally)===null||k===void 0||k.call(_,n,void 0,m),t===this.count&&this.runPluginHandler("onFinally",n,void 0,m),m;case 4:return[2]}})})},e.prototype.run=function(){for(var n=this,r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];this.runAsync.apply(this,Q([],J(r),!1)).catch(function(o){n.options.onError||console.error(o)})},e.prototype.cancel=function(){this.count+=1,this.setState({loading:!1}),this.runPluginHandler("onCancel")},e.prototype.refresh=function(){this.run.apply(this,Q([],J(this.state.params||[]),!1))},e.prototype.refreshAsync=function(){return this.runAsync.apply(this,Q([],J(this.state.params||[]),!1))},e.prototype.mutate=function(n){var r=ke(n)?n(this.state.data):n;this.runPluginHandler("onMutate",r),this.setState({data:r})},e})();function Qn(e,n,r){n===void 0&&(n={}),r===void 0&&(r=[]);var t=n.manual,o=t===void 0?!1:t,i=n.ready,s=i===void 0?!0:i,a=vt(n,["manual","ready"]);Ce&&n.defaultParams&&!Array.isArray(n.defaultParams)&&console.warn("expected defaultParams is array, got ".concat(typeof n.defaultParams));var c=re({manual:o,ready:s},a),l=gt(e),d=Zn(),f=mt(function(){var m=r.map(function(v){var E;return(E=v?.onInit)===null||E===void 0?void 0:E.call(v,c)}).filter(Boolean);return new Jn(l,c,d,Object.assign.apply(Object,Q([{}],J(m),!1)))},[]);return f.options=c,f.pluginImpls=r.map(function(m){return m(f,c)}),Xe(function(){if(!o&&s){var m=f.state.params||n.defaultParams||[];f.run.apply(f,Q([],J(m),!1))}}),Ve(function(){f.cancel()}),{loading:f.state.loading,data:f.state.data,error:f.state.error,params:f.state.params||[],cancel:de(f.cancel.bind(f)),refresh:de(f.refresh.bind(f)),refreshAsync:de(f.refreshAsync.bind(f)),run:de(f.run.bind(f)),runAsync:de(f.runAsync.bind(f)),mutate:de(f.mutate.bind(f))}}function Ot(e,n,r){return Qn(e,n,Q(Q([],J([]),!1),[In,Fn,zn,Vn,Xn,yt,dn,Yn],!1))}function Rn(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function Ae(){return Ae=Object.assign?Object.assign.bind():function(e){for(var n=1;n<arguments.length;n++){var r=arguments[n];for(var t in r)({}).hasOwnProperty.call(r,t)&&(e[t]=r[t])}return e},Ae.apply(null,arguments)}function Pt(e,n){if(e==null)return{};var r={};for(var t in e)if({}.hasOwnProperty.call(e,t)){if(n.indexOf(t)!==-1)continue;r[t]=e[t]}return r}function Ze(e,n){return Ze=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,t){return r.__proto__=t,r},Ze(e,n)}function Je(e,n){e.prototype=Object.create(n.prototype),e.prototype.constructor=e,Ze(e,n)}var Me={exports:{}},We={exports:{}},z={};var Lt;function er(){if(Lt)return z;Lt=1;var e=typeof Symbol=="function"&&Symbol.for,n=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,t=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,i=e?Symbol.for("react.profiler"):60114,s=e?Symbol.for("react.provider"):60109,a=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,l=e?Symbol.for("react.concurrent_mode"):60111,d=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,m=e?Symbol.for("react.suspense_list"):60120,v=e?Symbol.for("react.memo"):60115,E=e?Symbol.for("react.lazy"):60116,w=e?Symbol.for("react.block"):60121,P=e?Symbol.for("react.fundamental"):60117,T=e?Symbol.for("react.responder"):60118,H=e?Symbol.for("react.scope"):60119;function L(y){if(typeof y=="object"&&y!==null){var _=y.$$typeof;switch(_){case n:switch(y=y.type,y){case c:case l:case t:case i:case o:case f:return y;default:switch(y=y&&y.$$typeof,y){case a:case d:case E:case v:case s:return y;default:return _}}case r:return _}}}function j(y){return L(y)===l}return z.AsyncMode=c,z.ConcurrentMode=l,z.ContextConsumer=a,z.ContextProvider=s,z.Element=n,z.ForwardRef=d,z.Fragment=t,z.Lazy=E,z.Memo=v,z.Portal=r,z.Profiler=i,z.StrictMode=o,z.Suspense=f,z.isAsyncMode=function(y){return j(y)||L(y)===c},z.isConcurrentMode=j,z.isContextConsumer=function(y){return L(y)===a},z.isContextProvider=function(y){return L(y)===s},z.isElement=function(y){return typeof y=="object"&&y!==null&&y.$$typeof===n},z.isForwardRef=function(y){return L(y)===d},z.isFragment=function(y){return L(y)===t},z.isLazy=function(y){return L(y)===E},z.isMemo=function(y){return L(y)===v},z.isPortal=function(y){return L(y)===r},z.isProfiler=function(y){return L(y)===i},z.isStrictMode=function(y){return L(y)===o},z.isSuspense=function(y){return L(y)===f},z.isValidElementType=function(y){return typeof y=="string"||typeof y=="function"||y===t||y===l||y===i||y===o||y===f||y===m||typeof y=="object"&&y!==null&&(y.$$typeof===E||y.$$typeof===v||y.$$typeof===s||y.$$typeof===a||y.$$typeof===d||y.$$typeof===P||y.$$typeof===T||y.$$typeof===H||y.$$typeof===w)},z.typeOf=L,z}var B={};var Nt;function tr(){return Nt||(Nt=1,process.env.NODE_ENV!=="production"&&(function(){var e=typeof Symbol=="function"&&Symbol.for,n=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,t=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,i=e?Symbol.for("react.profiler"):60114,s=e?Symbol.for("react.provider"):60109,a=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,l=e?Symbol.for("react.concurrent_mode"):60111,d=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,m=e?Symbol.for("react.suspense_list"):60120,v=e?Symbol.for("react.memo"):60115,E=e?Symbol.for("react.lazy"):60116,w=e?Symbol.for("react.block"):60121,P=e?Symbol.for("react.fundamental"):60117,T=e?Symbol.for("react.responder"):60118,H=e?Symbol.for("react.scope"):60119;function L(b){return typeof b=="string"||typeof b=="function"||b===t||b===l||b===i||b===o||b===f||b===m||typeof b=="object"&&b!==null&&(b.$$typeof===E||b.$$typeof===v||b.$$typeof===s||b.$$typeof===a||b.$$typeof===d||b.$$typeof===P||b.$$typeof===T||b.$$typeof===H||b.$$typeof===w)}function j(b){if(typeof b=="object"&&b!==null){var ce=b.$$typeof;switch(ce){case n:var ze=b.type;switch(ze){case c:case l:case t:case i:case o:case f:return ze;default:var Jt=ze&&ze.$$typeof;switch(Jt){case a:case d:case E:case v:case s:return Jt;default:return ce}}case r:return ce}}}var y=c,_=l,k=a,g=s,S=n,O=d,A=t,X=E,Y=v,K=r,oe=i,le=o,ve=f,qe=!1;function ut(b){return qe||(qe=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),h(b)||j(b)===c}function h(b){return j(b)===l}function x(b){return j(b)===a}function I(b){return j(b)===s}function W(b){return typeof b=="object"&&b!==null&&b.$$typeof===n}function N(b){return j(b)===d}function F(b){return j(b)===t}function M(b){return j(b)===E}function $(b){return j(b)===v}function D(b){return j(b)===r}function U(b){return j(b)===i}function q(b){return j(b)===o}function ee(b){return j(b)===f}B.AsyncMode=y,B.ConcurrentMode=_,B.ContextConsumer=k,B.ContextProvider=g,B.Element=S,B.ForwardRef=O,B.Fragment=A,B.Lazy=X,B.Memo=Y,B.Portal=K,B.Profiler=oe,B.StrictMode=le,B.Suspense=ve,B.isAsyncMode=ut,B.isConcurrentMode=h,B.isContextConsumer=x,B.isContextProvider=I,B.isElement=W,B.isForwardRef=N,B.isFragment=F,B.isLazy=M,B.isMemo=$,B.isPortal=D,B.isProfiler=U,B.isStrictMode=q,B.isSuspense=ee,B.isValidElementType=L,B.typeOf=j})()),B}var jt;function _t(){return jt||(jt=1,process.env.NODE_ENV==="production"?We.exports=er():We.exports=tr()),We.exports}var Qe,At;function nr(){if(At)return Qe;At=1;var e=Object.getOwnPropertySymbols,n=Object.prototype.hasOwnProperty,r=Object.prototype.propertyIsEnumerable;function t(i){if(i==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(i)}function o(){try{if(!Object.assign)return!1;var i=new String("abc");if(i[5]="de",Object.getOwnPropertyNames(i)[0]==="5")return!1;for(var s={},a=0;a<10;a++)s["_"+String.fromCharCode(a)]=a;var c=Object.getOwnPropertyNames(s).map(function(d){return s[d]});if(c.join("")!=="0123456789")return!1;var l={};return"abcdefghijklmnopqrst".split("").forEach(function(d){l[d]=d}),Object.keys(Object.assign({},l)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return Qe=o()?Object.assign:function(i,s){for(var a,c=t(i),l,d=1;d<arguments.length;d++){a=Object(arguments[d]);for(var f in a)n.call(a,f)&&(c[f]=a[f]);if(e){l=e(a);for(var m=0;m<l.length;m++)r.call(a,l[m])&&(c[l[m]]=a[l[m]])}}return c},Qe}var Re,Mt;function et(){if(Mt)return Re;Mt=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return Re=e,Re}var tt,Wt;function $t(){return Wt||(Wt=1,tt=Function.call.bind(Object.prototype.hasOwnProperty)),tt}var nt,It;function rr(){if(It)return nt;It=1;var e=function(){};if(process.env.NODE_ENV!=="production"){var n=et(),r={},t=$t();e=function(i){var s="Warning: "+i;typeof console<"u"&&console.error(s);try{throw new Error(s)}catch{}}}function o(i,s,a,c,l){if(process.env.NODE_ENV!=="production"){for(var d in i)if(t(i,d)){var f;try{if(typeof i[d]!="function"){var m=Error((c||"React class")+": "+a+" type `"+d+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof i[d]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw m.name="Invariant Violation",m}f=i[d](s,d,c,a,null,n)}catch(E){f=E}if(f&&!(f instanceof Error)&&e((c||"React class")+": type specification of "+a+" `"+d+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof f+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),f instanceof Error&&!(f.message in r)){r[f.message]=!0;var v=l?l():"";e("Failed "+a+" type: "+f.message+(v??""))}}}}return o.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(r={})},nt=o,nt}var rt,Ft;function or(){if(Ft)return rt;Ft=1;var e=_t(),n=nr(),r=et(),t=$t(),o=rr(),i=function(){};process.env.NODE_ENV!=="production"&&(i=function(a){var c="Warning: "+a;typeof console<"u"&&console.error(c);try{throw new Error(c)}catch{}});function s(){return null}return rt=function(a,c){var l=typeof Symbol=="function"&&Symbol.iterator,d="@@iterator";function f(h){var x=h&&(l&&h[l]||h[d]);if(typeof x=="function")return x}var m="<<anonymous>>",v={array:T("array"),bigint:T("bigint"),bool:T("boolean"),func:T("function"),number:T("number"),object:T("object"),string:T("string"),symbol:T("symbol"),any:H(),arrayOf:L,element:j(),elementType:y(),instanceOf:_,node:O(),objectOf:g,oneOf:k,oneOfType:S,shape:X,exact:Y};function E(h,x){return h===x?h!==0||1/h===1/x:h!==h&&x!==x}function w(h,x){this.message=h,this.data=x&&typeof x=="object"?x:{},this.stack=""}w.prototype=Error.prototype;function P(h){if(process.env.NODE_ENV!=="production")var x={},I=0;function W(F,M,$,D,U,q,ee){if(D=D||m,q=q||$,ee!==r){if(c){var b=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");throw b.name="Invariant Violation",b}else if(process.env.NODE_ENV!=="production"&&typeof console<"u"){var ce=D+":"+$;!x[ce]&&I<3&&(i("You are manually calling a React.PropTypes validation function for the `"+q+"` prop on `"+D+"`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."),x[ce]=!0,I++)}}return M[$]==null?F?M[$]===null?new w("The "+U+" `"+q+"` is marked as required "+("in `"+D+"`, but its value is `null`.")):new w("The "+U+" `"+q+"` is marked as required in "+("`"+D+"`, but its value is `undefined`.")):null:h(M,$,D,U,q)}var N=W.bind(null,!1);return N.isRequired=W.bind(null,!0),N}function T(h){function x(I,W,N,F,M,$){var D=I[W],U=le(D);if(U!==h){var q=ve(D);return new w("Invalid "+F+" `"+M+"` of type "+("`"+q+"` supplied to `"+N+"`, expected ")+("`"+h+"`."),{expectedType:h})}return null}return P(x)}function H(){return P(s)}function L(h){function x(I,W,N,F,M){if(typeof h!="function")return new w("Property `"+M+"` of component `"+N+"` has invalid PropType notation inside arrayOf.");var $=I[W];if(!Array.isArray($)){var D=le($);return new w("Invalid "+F+" `"+M+"` of type "+("`"+D+"` supplied to `"+N+"`, expected an array."))}for(var U=0;U<$.length;U++){var q=h($,U,N,F,M+"["+U+"]",r);if(q instanceof Error)return q}return null}return P(x)}function j(){function h(x,I,W,N,F){var M=x[I];if(!a(M)){var $=le(M);return new w("Invalid "+N+" `"+F+"` of type "+("`"+$+"` supplied to `"+W+"`, expected a single ReactElement."))}return null}return P(h)}function y(){function h(x,I,W,N,F){var M=x[I];if(!e.isValidElementType(M)){var $=le(M);return new w("Invalid "+N+" `"+F+"` of type "+("`"+$+"` supplied to `"+W+"`, expected a single ReactElement type."))}return null}return P(h)}function _(h){function x(I,W,N,F,M){if(!(I[W]instanceof h)){var $=h.name||m,D=ut(I[W]);return new w("Invalid "+F+" `"+M+"` of type "+("`"+D+"` supplied to `"+N+"`, expected ")+("instance of `"+$+"`."))}return null}return P(x)}function k(h){if(!Array.isArray(h))return process.env.NODE_ENV!=="production"&&(arguments.length>1?i("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):i("Invalid argument supplied to oneOf, expected an array.")),s;function x(I,W,N,F,M){for(var $=I[W],D=0;D<h.length;D++)if(E($,h[D]))return null;var U=JSON.stringify(h,function(ee,b){var ce=ve(b);return ce==="symbol"?String(b):b});return new w("Invalid "+F+" `"+M+"` of value `"+String($)+"` "+("supplied to `"+N+"`, expected one of "+U+"."))}return P(x)}function g(h){function x(I,W,N,F,M){if(typeof h!="function")return new w("Property `"+M+"` of component `"+N+"` has invalid PropType notation inside objectOf.");var $=I[W],D=le($);if(D!=="object")return new w("Invalid "+F+" `"+M+"` of type "+("`"+D+"` supplied to `"+N+"`, expected an object."));for(var U in $)if(t($,U)){var q=h($,U,N,F,M+"."+U,r);if(q instanceof Error)return q}return null}return P(x)}function S(h){if(!Array.isArray(h))return process.env.NODE_ENV!=="production"&&i("Invalid argument supplied to oneOfType, expected an instance of array."),s;for(var x=0;x<h.length;x++){var I=h[x];if(typeof I!="function")return i("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+qe(I)+" at index "+x+"."),s}function W(N,F,M,$,D){for(var U=[],q=0;q<h.length;q++){var ee=h[q],b=ee(N,F,M,$,D,r);if(b==null)return null;b.data&&t(b.data,"expectedType")&&U.push(b.data.expectedType)}var ce=U.length>0?", expected one of type ["+U.join(", ")+"]":"";return new w("Invalid "+$+" `"+D+"` supplied to "+("`"+M+"`"+ce+"."))}return P(W)}function O(){function h(x,I,W,N,F){return K(x[I])?null:new w("Invalid "+N+" `"+F+"` supplied to "+("`"+W+"`, expected a ReactNode."))}return P(h)}function A(h,x,I,W,N){return new w((h||"React class")+": "+x+" type `"+I+"."+W+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+N+"`.")}function X(h){function x(I,W,N,F,M){var $=I[W],D=le($);if(D!=="object")return new w("Invalid "+F+" `"+M+"` of type `"+D+"` "+("supplied to `"+N+"`, expected `object`."));for(var U in h){var q=h[U];if(typeof q!="function")return A(N,F,M,U,ve(q));var ee=q($,U,N,F,M+"."+U,r);if(ee)return ee}return null}return P(x)}function Y(h){function x(I,W,N,F,M){var $=I[W],D=le($);if(D!=="object")return new w("Invalid "+F+" `"+M+"` of type `"+D+"` "+("supplied to `"+N+"`, expected `object`."));var U=n({},I[W],h);for(var q in U){var ee=h[q];if(t(h,q)&&typeof ee!="function")return A(N,F,M,q,ve(ee));if(!ee)return new w("Invalid "+F+" `"+M+"` key `"+q+"` supplied to `"+N+"`.\nBad object: "+JSON.stringify(I[W],null," ")+`
3
+ Valid keys: `+JSON.stringify(Object.keys(h),null," "));var b=ee($,q,N,F,M+"."+q,r);if(b)return b}return null}return P(x)}function K(h){switch(typeof h){case"number":case"string":case"undefined":return!0;case"boolean":return!h;case"object":if(Array.isArray(h))return h.every(K);if(h===null||a(h))return!0;var x=f(h);if(x){var I=x.call(h),W;if(x!==h.entries){for(;!(W=I.next()).done;)if(!K(W.value))return!1}else for(;!(W=I.next()).done;){var N=W.value;if(N&&!K(N[1]))return!1}}else return!1;return!0;default:return!1}}function oe(h,x){return h==="symbol"?!0:x?x["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&x instanceof Symbol:!1}function le(h){var x=typeof h;return Array.isArray(h)?"array":h instanceof RegExp?"object":oe(x,h)?"symbol":x}function ve(h){if(typeof h>"u"||h===null)return""+h;var x=le(h);if(x==="object"){if(h instanceof Date)return"date";if(h instanceof RegExp)return"regexp"}return x}function qe(h){var x=ve(h);switch(x){case"array":case"object":return"an "+x;case"boolean":case"date":case"regexp":return"a "+x;default:return x}}function ut(h){return!h.constructor||!h.constructor.name?m:h.constructor.name}return v.checkPropTypes=o,v.resetWarningCache=o.resetWarningCache,v.PropTypes=v,v},rt}var ot,Dt;function ir(){if(Dt)return ot;Dt=1;var e=et();function n(){}function r(){}return r.resetWarningCache=n,ot=function(){function t(s,a,c,l,d,f){if(f!==e){var m=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw m.name="Invariant Violation",m}}t.isRequired=t;function o(){return t}var i={array:t,bigint:t,bool:t,func:t,number:t,object:t,string:t,symbol:t,any:t,arrayOf:o,element:t,elementType:t,instanceOf:o,node:t,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:r,resetWarningCache:n};return i.PropTypes=i,i},ot}var qt;function sr(){if(qt)return Me.exports;if(qt=1,process.env.NODE_ENV!=="production"){var e=_t(),n=!0;Me.exports=or()(e.isElement,n)}else Me.exports=ir()();return Me.exports}var ar=sr();const C=Rn(ar);function lr(e,n){return e.classList?!!n&&e.classList.contains(n):(" "+(e.className.baseVal||e.className)+" ").indexOf(" "+n+" ")!==-1}function cr(e,n){e.classList?e.classList.add(n):lr(e,n)||(typeof e.className=="string"?e.className=e.className+" "+n:e.setAttribute("class",(e.className&&e.className.baseVal||"")+" "+n))}function zt(e,n){return e.replace(new RegExp("(^|\\s)"+n+"(?:\\s|$)","g"),"$1").replace(/\s+/g," ").replace(/^\s*|\s*$/g,"")}function ur(e,n){e.classList?e.classList.remove(n):typeof e.className=="string"?e.className=zt(e.className,n):e.setAttribute("class",zt(e.className&&e.className.baseVal||"",n))}const Bt={disabled:!1};var fr=process.env.NODE_ENV!=="production"?C.oneOfType([C.number,C.shape({enter:C.number,exit:C.number,appear:C.number}).isRequired]):null,dr=process.env.NODE_ENV!=="production"?C.oneOfType([C.string,C.shape({enter:C.string,exit:C.string,active:C.string}),C.shape({enter:C.string,enterDone:C.string,enterActive:C.string,exit:C.string,exitDone:C.string,exitActive:C.string})]):null;const it=p.createContext(null);var Ht=function(n){return n.scrollTop},Ee="unmounted",he="exited",ne="entering",se="entered",xe="exiting",ae=(function(e){Je(n,e);function n(t,o){var i;i=e.call(this,t,o)||this;var s=o,a=s&&!s.isMounting?t.enter:t.appear,c;return i.appearStatus=null,t.in?a?(c=he,i.appearStatus=ne):c=se:t.unmountOnExit||t.mountOnEnter?c=Ee:c=he,i.state={status:c},i.nextCallback=null,i}n.getDerivedStateFromProps=function(o,i){var s=o.in;return s&&i.status===Ee?{status:he}:null};var r=n.prototype;return r.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},r.componentDidUpdate=function(o){var i=null;if(o!==this.props){var s=this.state.status;this.props.in?s!==ne&&s!==se&&(i=ne):(s===ne||s===se)&&(i=xe)}this.updateStatus(!1,i)},r.componentWillUnmount=function(){this.cancelNextCallback()},r.getTimeouts=function(){var o=this.props.timeout,i,s,a;return i=s=a=o,o!=null&&typeof o!="number"&&(i=o.exit,s=o.enter,a=o.appear!==void 0?o.appear:s),{exit:i,enter:s,appear:a}},r.updateStatus=function(o,i){if(o===void 0&&(o=!1),i!==null)if(this.cancelNextCallback(),i===ne){if(this.props.unmountOnExit||this.props.mountOnEnter){var s=this.props.nodeRef?this.props.nodeRef.current:Se.findDOMNode(this);s&&Ht(s)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===he&&this.setState({status:Ee})},r.performEnter=function(o){var i=this,s=this.props.enter,a=this.context?this.context.isMounting:o,c=this.props.nodeRef?[a]:[Se.findDOMNode(this),a],l=c[0],d=c[1],f=this.getTimeouts(),m=a?f.appear:f.enter;if(!o&&!s||Bt.disabled){this.safeSetState({status:se},function(){i.props.onEntered(l)});return}this.props.onEnter(l,d),this.safeSetState({status:ne},function(){i.props.onEntering(l,d),i.onTransitionEnd(m,function(){i.safeSetState({status:se},function(){i.props.onEntered(l,d)})})})},r.performExit=function(){var o=this,i=this.props.exit,s=this.getTimeouts(),a=this.props.nodeRef?void 0:Se.findDOMNode(this);if(!i||Bt.disabled){this.safeSetState({status:he},function(){o.props.onExited(a)});return}this.props.onExit(a),this.safeSetState({status:xe},function(){o.props.onExiting(a),o.onTransitionEnd(s.exit,function(){o.safeSetState({status:he},function(){o.props.onExited(a)})})})},r.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},r.safeSetState=function(o,i){i=this.setNextCallback(i),this.setState(o,i)},r.setNextCallback=function(o){var i=this,s=!0;return this.nextCallback=function(a){s&&(s=!1,i.nextCallback=null,o(a))},this.nextCallback.cancel=function(){s=!1},this.nextCallback},r.onTransitionEnd=function(o,i){this.setNextCallback(i);var s=this.props.nodeRef?this.props.nodeRef.current:Se.findDOMNode(this),a=o==null&&!this.props.addEndListener;if(!s||a){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var c=this.props.nodeRef?[this.nextCallback]:[s,this.nextCallback],l=c[0],d=c[1];this.props.addEndListener(l,d)}o!=null&&setTimeout(this.nextCallback,o)},r.render=function(){var o=this.state.status;if(o===Ee)return null;var i=this.props,s=i.children;i.in,i.mountOnEnter,i.unmountOnExit,i.appear,i.enter,i.exit,i.timeout,i.addEndListener,i.onEnter,i.onEntering,i.onEntered,i.onExit,i.onExiting,i.onExited,i.nodeRef;var a=Pt(i,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return p.createElement(it.Provider,{value:null},typeof s=="function"?s(o,a):p.cloneElement(p.Children.only(s),a))},n})(p.Component);ae.contextType=it,ae.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:C.shape({current:typeof Element>"u"?C.any:function(e,n,r,t,o,i){var s=e[n];return C.instanceOf(s&&"ownerDocument"in s?s.ownerDocument.defaultView.Element:Element)(e,n,r,t,o,i)}}),children:C.oneOfType([C.func.isRequired,C.element.isRequired]).isRequired,in:C.bool,mountOnEnter:C.bool,unmountOnExit:C.bool,appear:C.bool,enter:C.bool,exit:C.bool,timeout:function(n){var r=fr;n.addEndListener||(r=r.isRequired);for(var t=arguments.length,o=new Array(t>1?t-1:0),i=1;i<t;i++)o[i-1]=arguments[i];return r.apply(void 0,[n].concat(o))},addEndListener:C.func,onEnter:C.func,onEntering:C.func,onEntered:C.func,onExit:C.func,onExiting:C.func,onExited:C.func}:{};function ye(){}ae.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:ye,onEntering:ye,onEntered:ye,onExit:ye,onExiting:ye,onExited:ye},ae.UNMOUNTED=Ee,ae.EXITED=he,ae.ENTERING=ne,ae.ENTERED=se,ae.EXITING=xe;var pr=function(n,r){return n&&r&&r.split(" ").forEach(function(t){return cr(n,t)})},st=function(n,r){return n&&r&&r.split(" ").forEach(function(t){return ur(n,t)})},at=(function(e){Je(n,e);function n(){for(var t,o=arguments.length,i=new Array(o),s=0;s<o;s++)i[s]=arguments[s];return t=e.call.apply(e,[this].concat(i))||this,t.appliedClasses={appear:{},enter:{},exit:{}},t.onEnter=function(a,c){var l=t.resolveArguments(a,c),d=l[0],f=l[1];t.removeClasses(d,"exit"),t.addClass(d,f?"appear":"enter","base"),t.props.onEnter&&t.props.onEnter(a,c)},t.onEntering=function(a,c){var l=t.resolveArguments(a,c),d=l[0],f=l[1],m=f?"appear":"enter";t.addClass(d,m,"active"),t.props.onEntering&&t.props.onEntering(a,c)},t.onEntered=function(a,c){var l=t.resolveArguments(a,c),d=l[0],f=l[1],m=f?"appear":"enter";t.removeClasses(d,m),t.addClass(d,m,"done"),t.props.onEntered&&t.props.onEntered(a,c)},t.onExit=function(a){var c=t.resolveArguments(a),l=c[0];t.removeClasses(l,"appear"),t.removeClasses(l,"enter"),t.addClass(l,"exit","base"),t.props.onExit&&t.props.onExit(a)},t.onExiting=function(a){var c=t.resolveArguments(a),l=c[0];t.addClass(l,"exit","active"),t.props.onExiting&&t.props.onExiting(a)},t.onExited=function(a){var c=t.resolveArguments(a),l=c[0];t.removeClasses(l,"exit"),t.addClass(l,"exit","done"),t.props.onExited&&t.props.onExited(a)},t.resolveArguments=function(a,c){return t.props.nodeRef?[t.props.nodeRef.current,a]:[a,c]},t.getClassNames=function(a){var c=t.props.classNames,l=typeof c=="string",d=l&&c?c+"-":"",f=l?""+d+a:c[a],m=l?f+"-active":c[a+"Active"],v=l?f+"-done":c[a+"Done"];return{baseClassName:f,activeClassName:m,doneClassName:v}},t}var r=n.prototype;return r.addClass=function(o,i,s){var a=this.getClassNames(i)[s+"ClassName"],c=this.getClassNames("enter"),l=c.doneClassName;i==="appear"&&s==="done"&&l&&(a+=" "+l),s==="active"&&o&&Ht(o),a&&(this.appliedClasses[i][s]=a,pr(o,a))},r.removeClasses=function(o,i){var s=this.appliedClasses[i],a=s.base,c=s.active,l=s.done;this.appliedClasses[i]={},a&&st(o,a),c&&st(o,c),l&&st(o,l)},r.render=function(){var o=this.props;o.classNames;var i=Pt(o,["classNames"]);return p.createElement(ae,Ae({},i,{onEnter:this.onEnter,onEntered:this.onEntered,onEntering:this.onEntering,onExit:this.onExit,onExiting:this.onExiting,onExited:this.onExited}))},n})(p.Component);at.defaultProps={classNames:""},at.propTypes=process.env.NODE_ENV!=="production"?Ae({},ae.propTypes,{classNames:dr,onEnter:C.func,onEntering:C.func,onEntered:C.func,onExit:C.func,onExiting:C.func,onExited:C.func}):{};var $e,Ie;function hr(e,n){return!(e===n||p.isValidElement(e)&&p.isValidElement(n)&&e.key!=null&&e.key===n.key)}var ue={out:"out-in",in:"in-out"},Fe=function(n,r,t){return function(){var o;n.props[r]&&(o=n.props)[r].apply(o,arguments),t()}},vr=($e={},$e[ue.out]=function(e){var n=e.current,r=e.changeState;return p.cloneElement(n,{in:!1,onExited:Fe(n,"onExited",function(){r(ne,null)})})},$e[ue.in]=function(e){var n=e.current,r=e.changeState,t=e.children;return[n,p.cloneElement(t,{in:!0,onEntered:Fe(t,"onEntered",function(){r(ne)})})]},$e),yr=(Ie={},Ie[ue.out]=function(e){var n=e.children,r=e.changeState;return p.cloneElement(n,{in:!0,onEntered:Fe(n,"onEntered",function(){r(se,p.cloneElement(n,{in:!0}))})})},Ie[ue.in]=function(e){var n=e.current,r=e.children,t=e.changeState;return[p.cloneElement(n,{in:!1,onExited:Fe(n,"onExited",function(){t(se,p.cloneElement(r,{in:!0}))})}),p.cloneElement(r,{in:!0})]},Ie),lt=(function(e){Je(n,e);function n(){for(var t,o=arguments.length,i=new Array(o),s=0;s<o;s++)i[s]=arguments[s];return t=e.call.apply(e,[this].concat(i))||this,t.state={status:se,current:null},t.appeared=!1,t.changeState=function(a,c){c===void 0&&(c=t.state.current),t.setState({status:a,current:c})},t}var r=n.prototype;return r.componentDidMount=function(){this.appeared=!0},n.getDerivedStateFromProps=function(o,i){return o.children==null?{current:null}:i.status===ne&&o.mode===ue.in?{status:ne}:i.current&&hr(i.current,o.children)?{status:xe}:{current:p.cloneElement(o.children,{in:!0})}},r.render=function(){var o=this.props,i=o.children,s=o.mode,a=this.state,c=a.status,l=a.current,d={children:i,current:l,changeState:this.changeState,status:c},f;switch(c){case ne:f=yr[s](d);break;case xe:f=vr[s](d);break;case se:f=l}return p.createElement(it.Provider,{value:{isMounting:!this.appeared}},f)},n})(p.Component);lt.propTypes=process.env.NODE_ENV!=="production"?{mode:C.oneOf([ue.in,ue.out]),children:C.oneOfType([C.element.isRequired])}:{},lt.defaultProps={mode:ue.out};const mr=()=>{const e=pt();return u.jsxs("section",{className:"flex items-center justify-start border-slate-200 mx-4 text-center my-3",children:[u.jsx("svg",{className:"w-8 h-8 fill-red-500",viewBox:"0 0 400 400",xmlns:"http://www.w3.org/2000/svg",children:u.jsxs("g",{children:[u.jsx("ellipse",{cx:"200.611",cy:"200.667",rx:"177.778",ry:"177.778"}),u.jsx("path",{fill:"#fff",d:"M28.944 221.778l197.5-194.445L367 254.556 227.556 374 28.944 221.778z"}),u.jsx("path",{d:"M78.431 253.29c15.953 45.715 69.05 64.287 135.717 66.43 166.908 12.62 192.836-144.553 36.578-120.73-64.853 10.321-82.784-8.213-85.598-36.225-2.813-28.012 30.315-52.258 67.58-53.362 37.264-1.103 54.208 22.032 48.86 41.818l-9.562 19.561c41.474-19.361 20.499-63.282-27.842-79.486-153.068-31.708-185.996 155.8-20.504 125.847 68.981-11.553 134.89 63.901 2.433 88.456-23.908 3.21-100.442 8.175-127.509-42.995l-20.153-9.314z"}),u.jsx("ellipse",{cx:"98.944",cy:"237.889",rx:"26.111",ry:"26.111"}),u.jsx("ellipse",{cx:"259.222",cy:"153.167",rx:"21.944",ry:"21.944"})]})}),u.jsx(V.Tooltip,{title:e,children:u.jsx("span",{className:"text-lg font-bold ml-2 bg-gradient-to-r from-red-500 to-orange-500 bg-clip text-transparent custom-logo-text",children:e.substring(0,9)})})]})},gr=()=>{const{menus:e}=ie(),n=Z.useNavigate(),r=Z.useLocation(),[t,o]=p.useState([""]),i=e.map(c=>c?.key);p.useEffect(()=>{o(r.pathname.substring(1).split("/"))},[r.pathname]);const s=c=>{const l=c.find(d=>t.indexOf(d)===-1);i.indexOf(l)===-1?o(c):o(l?[l]:[])},a=({keyPath:c,key:l,item:d})=>{if(l.indexOf("://")!==-1){window.open(l);return}const f=d.props?.query||"",m=c.reverse().join("/");n(`${m}${f?"?"+f:""}`)};return u.jsx("section",{className:"flex-1 flex flex-col justify-between",children:u.jsx(V.Menu,{mode:"inline",openKeys:t,onOpenChange:s,onClick:a,selectedKeys:r.pathname.substring(1).split("/"),items:e,style:{borderInlineWidth:0},className:"border-t border-b border-slate-100"})})};var br=["size","strokeWidth","strokeLinecap","strokeLinejoin","theme","fill","className","spin"];function Ut(e,n){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(e);n&&(t=t.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,t)}return r}function Vt(e){for(var n=1;n<arguments.length;n++){var r=arguments[n]!=null?arguments[n]:{};n%2?Ut(Object(r),!0).forEach(function(t){Er(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Ut(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function Er(e,n,r){return n in e?Object.defineProperty(e,n,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[n]=r,e}function xr(e,n){if(e==null)return{};var r=wr(e,n),t,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)t=i[o],!(n.indexOf(t)>=0)&&Object.prototype.propertyIsEnumerable.call(e,t)&&(r[t]=e[t])}return r}function wr(e,n){if(e==null)return{};var r={},t=Object.keys(e),o,i;for(i=0;i<t.length;i++)o=t[i],!(n.indexOf(o)>=0)&&(r[o]=e[o]);return r}var Tr={size:"1em",strokeWidth:4,strokeLinecap:"round",strokeLinejoin:"round",rtl:!1,theme:"outline",colors:{outline:{fill:"#333",background:"transparent"},filled:{fill:"#333",background:"#FFF"},twoTone:{fill:"#333",twoTone:"#2F88FF"},multiColor:{outStrokeColor:"#333",outFillColor:"#2F88FF",innerStrokeColor:"#FFF",innerFillColor:"#43CCF8"}},prefix:"i"};function Sr(){return"icon-"+((1+Math.random())*4294967296|0).toString(16).substring(1)}function kr(e,n,r){var t=typeof n.fill=="string"?[n.fill]:n.fill||[],o=[],i=n.theme||r.theme;switch(i){case"outline":o.push(typeof t[0]=="string"?t[0]:"currentColor"),o.push("none"),o.push(typeof t[0]=="string"?t[0]:"currentColor"),o.push("none");break;case"filled":o.push(typeof t[0]=="string"?t[0]:"currentColor"),o.push(typeof t[0]=="string"?t[0]:"currentColor"),o.push("#FFF"),o.push("#FFF");break;case"two-tone":o.push(typeof t[0]=="string"?t[0]:"currentColor"),o.push(typeof t[1]=="string"?t[1]:r.colors.twoTone.twoTone),o.push(typeof t[0]=="string"?t[0]:"currentColor"),o.push(typeof t[1]=="string"?t[1]:r.colors.twoTone.twoTone);break;case"multi-color":o.push(typeof t[0]=="string"?t[0]:"currentColor"),o.push(typeof t[1]=="string"?t[1]:r.colors.multiColor.outFillColor),o.push(typeof t[2]=="string"?t[2]:r.colors.multiColor.innerStrokeColor),o.push(typeof t[3]=="string"?t[3]:r.colors.multiColor.innerFillColor);break}return{size:n.size||r.size,strokeWidth:n.strokeWidth||r.strokeWidth,strokeLinecap:n.strokeLinecap||r.strokeLinecap,strokeLinejoin:n.strokeLinejoin||r.strokeLinejoin,colors:o,id:e}}var Yt=p.createContext(Tr);Yt.Provider;function me(e,n,r){return function(t){var o=t.size,i=t.strokeWidth,s=t.strokeLinecap,a=t.strokeLinejoin,c=t.theme,l=t.fill,d=t.className,f=t.spin,m=xr(t,br),v=p.useContext(Yt),E=p.useMemo(Sr,[]),w=kr(E,{size:o,strokeWidth:i,strokeLinecap:s,strokeLinejoin:a,theme:c,fill:l},v),P=[v.prefix+"-icon"];return P.push(v.prefix+"-icon-"+e),n&&v.rtl&&P.push(v.prefix+"-icon-rtl"),f&&P.push(v.prefix+"-icon-spin"),d&&P.push(d),p.createElement("span",Vt(Vt({},m),{},{className:P.join(" ")}),r(w))}}const Cr=me("grid-three",!0,function(e){return p.createElement("svg",{width:e.size,height:e.size,viewBox:"0 0 48 48",fill:"none"},p.createElement("path",{d:"M39.3 6H8.7C7.20883 6 6 7.20883 6 8.7V39.3C6 40.7912 7.20883 42 8.7 42H39.3C40.7912 42 42 40.7912 42 39.3V8.7C42 7.20883 40.7912 6 39.3 6Z",stroke:e.colors[0],strokeWidth:e.strokeWidth}),p.createElement("path",{d:"M15 6L15 42",stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap}),p.createElement("path",{d:"M42 17H6",stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap}))}),Or=me("home",!1,function(e){return p.createElement("svg",{width:e.size,height:e.size,viewBox:"0 0 48 48",fill:"none"},p.createElement("path",{d:"M9 18V42H39V18L24 6L9 18Z",fill:e.colors[1],stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),p.createElement("path",{d:"M19 29V42H29V29H19Z",fill:e.colors[3],stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinejoin:e.strokeLinejoin}),p.createElement("path",{d:"M9 42H39",stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap}))}),Kt=me("info",!0,function(e){return p.createElement("svg",{width:e.size,height:e.size,viewBox:"0 0 48 48",fill:"none"},p.createElement("path",{d:"M24 44C29.5228 44 34.5228 41.7614 38.1421 38.1421C41.7614 34.5228 44 29.5228 44 24C44 18.4772 41.7614 13.4772 38.1421 9.85786C34.5228 6.23858 29.5228 4 24 4C18.4772 4 13.4772 6.23858 9.85786 9.85786C6.23858 13.4772 4 18.4772 4 24C4 29.5228 6.23858 34.5228 9.85786 38.1421C13.4772 41.7614 18.4772 44 24 44Z",fill:e.colors[1],stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinejoin:e.strokeLinejoin}),p.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M24 11C25.3807 11 26.5 12.1193 26.5 13.5C26.5 14.8807 25.3807 16 24 16C22.6193 16 21.5 14.8807 21.5 13.5C21.5 12.1193 22.6193 11 24 11Z",fill:e.colors[2]}),p.createElement("path",{d:"M24.5 34V20H23.5H22.5",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),p.createElement("path",{d:"M21 34H28",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}))}),Pr=me("layout-one",!0,function(e){return p.createElement("svg",{width:e.size,height:e.size,viewBox:"0 0 48 48",fill:"none"},p.createElement("rect",{x:"6",y:"6",width:"36",height:"36",rx:"3",fill:e.colors[1],stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinejoin:e.strokeLinejoin}),p.createElement("path",{d:"M6 16H42",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),p.createElement("path",{d:"M6 13V19",stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),p.createElement("path",{d:"M42 14V20",stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),p.createElement("path",{d:"M32 16V42",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),p.createElement("path",{d:"M29 42H35",stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}))}),Gt=me("logout",!0,function(e){return p.createElement("svg",{width:e.size,height:e.size,viewBox:"0 0 48 48",fill:"none"},p.createElement("path",{d:"M23.9917 6H6V42H24",stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),p.createElement("path",{d:"M33 33L42 24L33 15",stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),p.createElement("path",{d:"M16 23.9917H42",stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}))}),Lr=me("right",!0,function(e){return p.createElement("svg",{width:e.size,height:e.size,viewBox:"0 0 48 48",fill:"none"},p.createElement("path",{d:"M19 12L31 24L19 36",stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}))});function Nr(e){return typeof e=="number"?e===0?1:0:e==="legacy"?"modern":e==="modern"?"legacy":0}function jr(){const{layoutStyle:e,setLayoutStyle:n}=ie(),r=He(),t=Nr(e),o=e===0||e==="legacy";return u.jsx(V.Tooltip,{placement:"top",title:o?"切换到顶部菜单":"切换到左侧菜单",children:u.jsx(V.Button,{type:"text",className:"hover:bg-gray-100 rounded h-8 w-8 flex-center",onClick:()=>{r.layout?.set?.(t===0?"legacy":"modern"),n(t)},children:o?u.jsx(Cr,{theme:"outline",size:"16",className:"text-slate-500"}):u.jsx(Pr,{theme:"outline",size:"16",className:"text-slate-500 -scale-x-100"})})})}const _r=()=>{const{user:e,recoverConfig:n}=ie(),r=Z.useNavigate(),t=He(),o=dt(),i=Ot(()=>o({url:"v1/system/logout",method:"post"}),{manual:!0});return u.jsxs("section",{className:"bg-white mt-4 p-3 pr-2 flex items-center border border-slate-200 rounded-lg m-2",children:[u.jsxs("div",{className:"ml-1 flex-1",children:[u.jsx("div",{className:"text-slate-600 font-bold",children:e.userName}),u.jsxs("div",{className:"text-slate-400 text-sm",children:["@",e.roles]})]}),u.jsx(Z.Link,{to:"userinfo",className:"hover:bg-gray-100 rounded h-8 w-8 flex-center",children:u.jsx(Kt,{theme:"outline",size:"16",className:"text-slate-500"})}),u.jsx(jr,{}),u.jsx(te.PopConfirm,{title:"确认注销?",onConfirm:()=>{i.run(),t.token?.set?.(""),t.user?.set?.(""),n(),r("/login")},children:u.jsx(V.Button,{type:"text",className:"hover:bg-gray-100 rounded h-8 w-8 flex-center",children:u.jsx(Gt,{theme:"outline",size:"16",className:"text-slate-500"})})})]})},Ar=e=>{const{cls:n}=e,r=fe("aside_tree flex-shrink-0 flex flex-col overflow-auto h-screen sticky top-0 border-r border-r-slate-200 w-[248px] bg-slate-50 text-gray-700 text-sm",n);return u.jsxs("aside",{className:r,children:[u.jsx(mr,{}),e.loading?u.jsxs(p.Fragment,{children:[u.jsx(gr,{}),u.jsx(_r,{})]}):e.spin]})};var Mr="[object AsyncFunction]",Wr="[object Function]",$r="[object GeneratorFunction]",Ir="[object Proxy]";function Fr(e){if(!ge(e))return!1;var n=wt(e);return n==Wr||n==$r||n==Mr||n==Ir}const Dr=()=>{const n=Z.useMatches().map(r=>{const{getTitle:t,title:o}=r.handle||{};return{title:Fr(t)?t(r):o,path:r.pathname}}).filter(r=>!!r.title);return u.jsxs("header",{children:[u.jsxs("section",{className:"my-3 flex items-center text-gray-500 text-sm",children:[u.jsx(Z.Link,{to:"/home",children:u.jsx(Or,{theme:"outline",size:"20"})}),n.map(({title:r,path:t},o)=>o>0?u.jsxs(p.Fragment,{children:[u.jsx(Lr,{theme:"outline",size:"14",className:"text-gray-200 mx-2"}),u.jsx(Z.Link,{to:t,className:o===n.length-1?"text-gray-500 font-bold":"",children:r})]},o):u.jsx(p.Fragment,{},o))]}),u.jsx("section",{className:"mt-8 mb-4 text-2xl font-bold"})]})},qr=()=>{const{userReq:e,menuReq:n}=ie();Xe(()=>{!e.data&&e.run(),!n.data&&n.run()});const[r,t]=p.useState(!0),o=Z.useLocation(),i=p.useRef(null),s=fe(r?"opacity-100 w-[248px]":"!w-0 opacity-0","transition-all duration-200"),a=p.useMemo(()=>u.jsx("div",{className:"p-4 pl-6",children:u.jsx(V.Spin,{})}),[]);return u.jsxs("div",{className:"sg-layout sg-layout--main flex overflow-hidden w-screen",children:[u.jsx(Ar,{loading:!!n.data,spin:a,cls:s}),u.jsx(Be,{status:r,setStatus:t}),n.data?u.jsx(p.Fragment,{children:u.jsxs("main",{className:"flex flex-col flex-1 overflow-x-auto p-8 pt-2 h-screen",children:[u.jsx(Dr,{}),u.jsx(lt,{children:u.jsx(at,{timeout:100,classNames:"fade",appear:!0,unmountOnExit:!0,nodeRef:i,children:u.jsx("div",{ref:i,children:u.jsx(te.ErrorBoundary,{children:u.jsx(Z.Outlet,{})})})},o.pathname)})]})}):a]})};function zr(){const e=Z.useLocation(),n=Z.useNavigate(),{setActiveTopLabel:r,layoutStyle:t}=ie();p.useEffect(()=>{if(en(t))return;const o=e.pathname.substring(1);if(o===""){n("/home",{replace:!0});return}const i=o.indexOf("/")===-1?o:o.substring(0,o.indexOf("/"));r(i)},[t,e.pathname,n,r])}const Xt=(e,n)=>n.every(r=>e.includes(r)),Br=()=>{const{menus:e,activeTopLabel:n,activeLeftMenuChildren:r,flattenRoutes:t}=ie(),o=Z.useNavigate(),i=Z.useLocation(),[s,a]=p.useState([""]),c=e.map(f=>f?.key);p.useEffect(()=>{a(i.pathname.substring(1).split("/"))},[i.pathname]);const l=f=>{const m=f.find(v=>s.indexOf(v)===-1);c.indexOf(m)===-1?a(f):a(m?[m]:[])},d=({keyPath:f,key:m})=>{if(m.indexOf("://")!==-1){window.open(m);return}const v=f.reverse().join("/");if(i.pathname.substring(1)!==m){const E=`${n}/${v}`.split("/"),w=t.findIndex(P=>Xt(String(P.key).split("?")[0].split("/"),E));w>=0&&o(`/${t[w].key}`)}};return u.jsx("section",{className:"flex-1 flex flex-col justify-between",children:u.jsx(V.Menu,{mode:"inline",openKeys:s,onOpenChange:l,onClick:d,selectedKeys:i.pathname.substring(1).split("/"),items:r,style:{borderInlineWidth:0},className:"border-b border-slate-100"})})},Hr=e=>{const{cls:n}=e,r=fe("aside_tree flex-shrink-0 flex flex-col overflow-auto h-full sticky top-0 border-r border-r-slate-200 w-[248px] bg-slate-50 text-gray-700 text-sm",n);return u.jsx("aside",{className:r,children:e.loading?u.jsx(p.Fragment,{children:u.jsx(Br,{})}):e.spin})},Ur=()=>{const{userReq:e,recoverConfig:n,resetTabs:r}=ie(),t=Z.useNavigate(),[o,i]=p.useState(!1),s=e.data?.data?.user||{},a=He(),c=dt(),l=Ot(()=>c({url:"v1/system/logout",method:"post"}),{manual:!0}),d=[{key:"info",label:u.jsxs(V.Space,{children:[u.jsx(Kt,{theme:"outline",size:"14",className:"text-slate-500"}),u.jsx("span",{className:"text-slate-500",children:"个人信息"})]}),onClick:()=>{t("/userinfo")}},{key:"logout",label:u.jsxs(V.Space,{children:[u.jsx(Gt,{theme:"outline",size:"14",className:"text-slate-500"}),u.jsx("span",{className:"text-slate-500",children:"退出"})]}),onClick:()=>i(!0)}];return u.jsxs(u.Fragment,{children:[u.jsx("section",{className:"pr-2 flex items-center",children:u.jsx(V.Dropdown,{menu:{items:d},placement:"topRight",arrow:{pointAtCenter:!0},children:u.jsx(V.Avatar,{className:"mr-1",children:String(s?.nickName||"").substring(0,1)})})}),u.jsx(V.Modal,{centered:!0,title:u.jsx("span",{className:"text-[20px] leading-[20px] font-[400] text-[#333]",children:"您确定要退出吗?"}),footer:u.jsxs(u.Fragment,{children:[u.jsx(V.Button,{type:"default",onClick:()=>{l.run(),a.token?.set?.(""),a.user?.set?.(""),r(),n(),t("/login")},children:"退出"}),u.jsx(V.Button,{type:"primary",onClick:()=>i(!1),children:"保持登录"})]}),maskClosable:!1,open:o,width:416,onCancel:()=>i(!1),onOk:()=>i(!1),transitionName:"",maskTransitionName:"",children:u.jsx("p",{className:"text-[13px] mt-[16px] mb-[39px] text-[#626675] leading-[13px]",children:"退出后,个人信息、部分缓存数据等功能可能无法使用。"})})]})},Vr=e=>{const{className:n}=e,r=Z.useNavigate(),{topRootMenus:t,setActiveTopLabel:o,activeTopLabel:i}=ie(),s=pt(),a=p.useRef(null),[c,l]=p.useState(!1),[d,f]=p.useState(!1),m=()=>{const T=a.current;if(!T)return;const H=T.scrollWidth-T.clientWidth;l(T.scrollLeft>0),f(H>0&&T.scrollLeft<H-1)};p.useEffect(()=>{m();const T=a.current;if(!T)return;const H=()=>m(),L=()=>m(),j=y=>{if(T.scrollWidth-T.clientWidth<=0)return;const k=y.deltaX!==0?y.deltaX:y.deltaY;if(k===0)return;const g=T.scrollLeft;T.scrollLeft+=k,T.scrollLeft!==g&&y.preventDefault()};return T.addEventListener("scroll",H,{passive:!0}),T.addEventListener("wheel",j,{passive:!1}),window.addEventListener("resize",L),()=>{T.removeEventListener("scroll",H),T.removeEventListener("wheel",j),window.removeEventListener("resize",L)}},[t.length]);const v=p.useMemo(()=>fe("modern-top-menu",c&&"is-scroll-left",d&&"is-scroll-right"),[c,d]),E=T=>{const H=a.current;H&&H.scrollBy({left:T,behavior:"smooth"})},w=fe(n),P="modern-top-menu__item";return u.jsx("header",{className:w,children:u.jsxs("section",{className:"flex justify-between text-gray-500 text-sm border-b border-slate-200",children:[u.jsx("div",{className:"w-[247px]",children:u.jsxs("section",{className:"flex items-center justify-start border-slate-200 mx-4 text-center my-3",children:[u.jsx("svg",{className:"w-8 h-8 fill-red-500",viewBox:"0 0 400 400",xmlns:"http://www.w3.org/2000/svg",children:u.jsxs("g",{children:[u.jsx("ellipse",{cx:"200.611",cy:"200.667",rx:"177.778",ry:"177.778"}),u.jsx("path",{fill:"#fff",d:"M28.944 221.778l197.5-194.445L367 254.556 227.556 374 28.944 221.778z"}),u.jsx("path",{d:"M78.431 253.29c15.953 45.715 69.05 64.287 135.717 66.433 166.908 12.62 192.836-144.553 36.578-120.73-64.853 10.321-82.784-8.213-85.598-36.225-2.813-28.012 30.315-52.258 67.58-53.362 37.264-1.103 54.208 22.032 48.86 41.818l-9.562 19.561c41.474-19.361 20.499-63.282-27.842-79.486-153.068-31.708-185.996 155.8-20.504 125.847 68.981-11.553 134.89 63.901 2.433 88.456-23.908 3.21-100.442 8.175-127.509-42.995l-20.153-9.314z"}),u.jsx("ellipse",{cx:"98.944",cy:"237.889",rx:"26.111",ry:"26.111"}),u.jsx("ellipse",{cx:"259.222",cy:"153.167",rx:"21.944",ry:"21.944"})]})}),u.jsx(V.Tooltip,{title:s,children:u.jsx("span",{className:"text-lg font-bold ml-2 bg-gradient-to-r from-red-500 to-orange-500 bg-clip text-transparent custom-logo-text",children:s.substring(0,9)})})]})}),u.jsx("section",{className:"flex flex-1 min-w-0 justify-start",children:u.jsxs("div",{className:v,children:[u.jsx(V.Button,{type:"text",className:"modern-top-menu__btn modern-top-menu__btn--left",onClick:()=>E(-320),"aria-label":"scroll left",icon:u.jsx(Te.LeftOutlined,{})}),u.jsx("ul",{ref:a,className:"modern-ul",children:t.map(T=>u.jsx("li",{className:`${P} ${i===T.key?"menu-checked":""}`,onClick:()=>{o(T.key),r(`/${T.key}`)},title:String(T.label??""),children:u.jsx("span",{className:"modern-top-menu__item-text",children:T.label})},T.key))}),u.jsx(V.Button,{type:"text",className:"modern-top-menu__btn modern-top-menu__btn--right",onClick:()=>E(320),"aria-label":"scroll right",icon:u.jsx(Te.RightOutlined,{})})]})}),u.jsx("section",{className:"flex-center w-[200px] justify-end mr-4",children:u.jsx(Ur,{})})]})})};var Yr=e=>{let n=e;for(;n=n.parentElement;){const r=getComputedStyle(n,null).getPropertyValue("overflow-y");if(n===document.body)return window;if(r==="auto"||r==="scroll"||r==="overlay")return n}return window},Zt=e=>e.firstChild?e.firstChild.offsetParent===e:!0,Kr=(e,n)=>{let r=e,t=0;Zt(n)||(t+=e.offsetTop-n.offsetTop,n=e.offsetParent,t+=-e.offsetTop);do t+=r.offsetTop,r=r.offsetParent;while(r&&r!==n);return t},Gr=e=>{let n=e.parentElement;for(;n&&getComputedStyle(n,null).getPropertyValue("display")==="contents";)n=n.parentElement;return n||window},we=null;typeof CSS<"u"&&CSS.supports&&(CSS.supports("position","sticky")?we="sticky":CSS.supports("position","-webkit-sticky")&&(we="-webkit-sticky"));var De=!1;try{const e=Object.defineProperty({},"passive",{get(){De={passive:!0}}}),n=()=>{};window.addEventListener("testPassive",n,e),window.removeEventListener("testPassive",n,e)}catch{}var ct=e=>{const{el:n,onChange:r,unsubs:t,measure:o}=e;if(n===window){const i=()=>({top:0,left:0,height:window.innerHeight,width:window.innerWidth}),s=o(i()),a=()=>{Object.assign(s,o(i())),r()};return window.addEventListener("resize",a,De),t.push(()=>window.removeEventListener("resize",a)),s}else{const i=o(n.getBoundingClientRect()),s=()=>{Object.assign(i,o(n.getBoundingClientRect())),r()},a=new ResizeObserver(s);return a.observe(n),t.push(()=>a.disconnect()),i}},Xr=e=>{const n=getComputedStyle(e,null),r=parseInt(n.getPropertyValue("padding-top"),10),t=parseInt(n.getPropertyValue("padding-bottom"),10);return{top:r,bottom:t}},Zr=(e,n,r)=>{const{bottom:t,offsetBottom:o,offsetTop:i}=r,s=Yr(e);let a=!1;const c=()=>{a||requestAnimationFrame(()=>{const k=f();if(k!==L)j(k);else if(k===1&&!t){const{height:g}=v,{height:S}=T;e.style.top=`${g-S-o}px`}else if(k===2){const{height:g,offsetTop:S}=v,{height:O,naturalTop:A}=P,{height:X}=T,Y=Math.max(0,S+l+g-(A+X+o));if(t){const K=Math.max(0,O-X-Y);e.style.bottom=`${K}px`}else e.style.top=`${Y}px`}a=!1}),a=!0};let l=s===window?window.scrollY:s.scrollTop;const d=k=>{const{offsetTop:g,height:S}=v,{naturalTop:O}=P,{height:A}=T;return k+g+S>=O+A+H+o},f=()=>{const{height:k}=v,{height:g}=T;return g+i+o<=k?3:d(l)?1:2},m=s!==window&&Zt(s),v=ct({el:s,onChange:c,unsubs:n,measure:({height:k,top:g})=>({height:k,offsetTop:m?g:0})}),E=Gr(e),w=E===window?{top:0,bottom:0}:Xr(E),P=ct({el:E,onChange:c,unsubs:n,measure:({height:k})=>({height:k-w.top-w.bottom,naturalTop:E===window?0:Kr(E,s)+w.top+v.offsetTop})}),T=ct({el:e,onChange:c,unsubs:n,measure:({height:k})=>({height:k})});let H=0,L=f();const j=k=>{const g=L;if(L=k,g===2&&(H=-1),k===3){e.style.position=we,t?e.style.bottom=`${o}px`:e.style.top=`${i}px`;return}const{height:S,offsetTop:O}=v,{height:A,naturalTop:X}=P,{height:Y}=T;if(k===2)if(e.style.position="relative",H=g===0?Math.max(0,O+l-X+i):Math.max(0,O+l+S-(X+Y+o)),t){const K=Math.max(0,A-Y-H);e.style.bottom=`${K}px`}else e.style.top=`${H}px`;else e.style.position=we,k===1?t?e.style.bottom=`${o}px`:e.style.top=`${S-Y-o}px`:t?e.style.bottom=`${S-Y-o}px`:e.style.top=`${i}px`};j(L);const y=k=>{if(k===l)return;const g=k-l;if(l=k,L===3)return;const{offsetTop:S,height:O}=v,{naturalTop:A,height:X}=P,{height:Y}=T;if(g>0)if(L===0){if(k+S+i>A){const K=Math.max(0,S+l-A+i);k+S+O<=A+Y+K+o?j(2):j(1)}}else L===2&&d(k)&&j(1);else if(L===1){if(S+k+O<A+X+o){const K=Math.max(0,S+l+O-(A+Y+o));S+k+i>=A+K?j(2):j(0)}}else L===2&&S+k+i<A+H&&j(0)},_=s===window?()=>y(window.scrollY):()=>y(s.scrollTop);s.addEventListener("scroll",_,De),s.addEventListener("mousewheel",_,De),n.push(()=>s.removeEventListener("scroll",_),()=>s.removeEventListener("mousewheel",_))},Jr=({offsetTop:e=0,offsetBottom:n=0,bottom:r=!1}={})=>{const[t,o]=p.useState(null);return p.useEffect(()=>{if(!t||!we)return;const i=[];return Zr(t,i,{offsetBottom:n,offsetTop:e,bottom:r}),()=>{i.forEach(s=>s())}},[t,n,e,r]),o},Qr=e=>{const{offsetTop:n,offsetBottom:r,bottom:t,children:o,className:i,style:s}=e,a=Jr({offsetTop:n,offsetBottom:r,bottom:t});return u.jsx("div",{className:i,style:s,ref:a,children:o})},Rr=Qr;const eo=e=>{const{flattenRoutes:n,panes:r,setPanes:t,activeLeftMenuChildren:o,activeKey:i,dynamicFlatternRouteScale:s,setActiveKey:a,resetTabs:c}=ie(),{className:l}=e,d=Z.useLocation(),f=Z.useNavigate(),[m,v]=p.useState(!1),{showAlert:E}=Qt.useAlert(),w=p.useRef({});p.useEffect(()=>{const g=d.pathname.substring(1);if(g.split("/").length===1&&o.length>=1||g.split("/").length===1&&o[0]?.children)return;const S=n?.filter(A=>Xt(String(A.key).split("?")[0].split("/"),g.split("/")))[0],O=S?.key?window.location.href.indexOf("action=")>-1?{...S,label:d.state??new URLSearchParams(window.location.href).get("title")??"New Tab"}:{...S}:void 0;if(S?.key&&(O.key=g+d.search),!O&&n.length){r?.findIndex(A=>A.key==="404")===-1&&t([...r,n.filter(A=>A.key==="404")[0]]),a("404");return}O&&r?.findIndex(A=>A.key===O.key)===-1&&O.type!=="M"&&(String(O.key).startsWith("lowcode/flow")&&(s({path:g+d.search,component:"lowcode/flow/index",meta:{title:"工作流"}}),O.label=d.state),t([...r,O])),O?.key&&a(O.key)},[d,n,t,o]);const P=g=>{a(g)},T=(g,S)=>{S==="remove"&&L(g)},H=g=>{const S=r.filter(O=>O.key===g)[0];f(S.key)},L=g=>{const S=r,O=S.findIndex(Y=>Y.key===g);if(O<0)return;const A=S[Math.max(0,O-1)]?.key??"home",X=[...S];X.splice(O,1),t(X),f(A)},j=async g=>{const S=r,O=S.find(Y=>Y.key==="home")??S[0],A=S.find(Y=>Y.key===w.current.key)??O;if(g){c(),f("/home");return}const X=A?.key!=="home"?[O,A]:[O];t(X),a(A?.key??"home"),f(A?.key==="home"?"/home":A.key)};te.useEvent(te.TAB_EVENTS.CLOSE,g=>{const{closeAll:S=!1,jumpToHome:O=!1}=g;if(S){j(!0);return}L(i),O&&a("home")}),te.useEvent(te.TAB_EVENTS.OPEN,g=>{const{key:S="",pageCode:O="",query:A="",params:X={},newWindow:Y=!1}=g;let K="";if(O&&(K=n?.map(oe=>oe.key).filter(oe=>String(oe).endsWith(`pageCode=${O}`))[0]),S&&!O&&(K=n?.map(oe=>oe.key).filter(oe=>oe.key===S)[0]),K){if(Y){window.open(`/#/${K+A}`);return}f(`${K+A}`,X)}else E({type:"warning",title:`跳转页签找不到低代码页面参数 pageCode={${O}}。`,timeout:3e3})}),te.useEvent(te.TAB_EVENTS.ROUTE,g=>{const{url:S="/home",params:O={}}=g;f(S,O)}),te.useEvent(te.TAB_EVENTS.RELOAD,()=>{v(!0),a(w.current.key),setTimeout(()=>{v(!1)},500)});const y=g=>{switch(g.domEvent.stopPropagation(),g.key){case"1":v(!0),a(w.current.key),setTimeout(()=>{v(!1)},500);return;case"2":L(w.current.key);return;case"3":j();return;case"4":j(!0);return}},_=p.useMemo(()=>r?.map(g=>({key:g.key,label:u.jsx(V.Dropdown,{menu:{items:[{key:"1",label:"刷新"},{key:"2",label:"关闭",disabled:g.key==="home"},{key:"3",label:"关闭其他",disabled:r.length<3&&g.key!=="home"},{key:"4",label:"关闭全部",disabled:g.key==="home"}],onClick:S=>{w.current=g,y(S)}},trigger:["contextMenu"],children:u.jsxs("span",{children:[w.current.key===g.key&&m&&u.jsx(V.Spin,{size:"small",style:{transform:"scale(0.8)",marginRight:5,marginTop:-2}}),g.label]})}),children:u.jsx(te.ErrorBoundary,{children:m&&w.current.key===g.key?u.jsx(V.Spin,{}):g.children}),closable:g.closable})),[r,m]),k=(g,S)=>u.jsx(Rr,{offsetTop:0,offsetBottom:0,style:{marginBottom:-5,zIndex:10},children:u.jsx(S,{...g,className:"bg-white"})});return u.jsx(V.Tabs,{activeKey:i,className:l,hideAdd:!0,onChange:P,onEdit:T,onTabClick:H,type:"editable-card",size:"small",items:_,renderTabBar:k,tabBarExtraContent:u.jsx("div",{className:"tab-transition"})})},to=()=>{const{userReq:e,menuReq:n}=ie();Xe(()=>{!e.data&&e.run(),!n.data&&n.run()});const[r,t]=p.useState(!0);zr();const o=fe(r?"opacity-100 w-[248px]":"!w-0 opacity-0","transition-all duration-200 border-t-0"),i=p.useMemo(()=>u.jsx("div",{className:"p-4 pl-6",children:u.jsx(V.Spin,{})}),[]),s=p.useMemo(()=>u.jsx("section",{className:"pl-4 pr-4 w-full overflow-auto h-full",children:u.jsx(eo,{defaultActiveKey:"home",className:"h-full sg_multi_tabs"})}),[]);return u.jsxs("div",{className:"sg-layout sg-layout--modern flex w-full h-screen flex-col",children:[u.jsx(Vr,{className:"w-full bg-slate-50"}),u.jsxs("section",{className:"flex flex-row flex-1 overflow-auto",children:[u.jsx(Hr,{loading:!!n.data,spin:i,cls:o}),u.jsx(Be,{status:r,setStatus:t}),n.data?s:i]})]})};G.MainLayout=qr,G.MenuStatusCrumb=Be,G.ModernLayout=to,G.createInitPanes=tn,G.setupSgTemplateLayout=Rt,G.transMenu=ht,Object.defineProperty(G,Symbol.toStringTag,{value:"Module"})}));
4
+ //# sourceMappingURL=core-layout.umd.cjs.map