xto-fronted 0.8.3 → 0.9.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.
@@ -1,105 +1,115 @@
1
- import { x as E, y as Ie, z as at, A as nt, B as lt, C as rt, D as Ee, o as _t, E as it, F as ft, i as et, m as gt, G as yt, H as tt, I as bt, J as kt, K as wt } from "./user-BfEOXV7Q.js";
2
- import { ref as y, computed as w, watch as xe, defineComponent as le, resolveComponent as ct, openBlock as a, createBlock as B, unref as l, withCtx as M, createElementBlock as c, Fragment as K, renderList as Z, createElementVNode as e, toDisplayString as x, createCommentVNode as T, normalizeClass as Q, withDirectives as Te, vShow as xt, createVNode as b, createTextVNode as ye, onMounted as je, onUnmounted as We, vModelText as qe, Transition as Ce, withModifiers as Fe, normalizeStyle as Ne, reactive as He, createStaticVNode as Pe, withKeys as Ct, h as $t } from "vue";
3
- import { defineStore as Ue } from "pinia";
4
- import { useRoute as Le, useRouter as he, createRouter as Ye, createWebHistory as Ge } from "vue-router";
5
- import { SubMenu as Ke, MenuItem as Se, Menu as Xe, Tabs as Lt, TabPane as Mt } from "@xto/navigation";
6
- import { Icon as U, Button as $e } from "@xto/base";
7
- import { Drawer as Je, Message as St } from "@xto/feedback";
8
- import { Form as Nt, FormItem as De, Input as st, Checkbox as It } from "@xto/form";
9
- import { createLocaleProvider as Et, getSupportedLocales as Ut, useLocale as zt } from "@xto/core/locale";
10
- function Pt(t) {
1
+ import { y as T, z as bt, A as Ne, B as it, C as ct, D as ut, E as dt, F as ze, p as wt, G as mt, H as kt, j as at, n as xt, I as Ct, J as nt, K as $t, L as Lt, M as Mt, h as St, N as Nt } from "./user-B0q24FmO.js";
2
+ import { ref as g, computed as w, watch as Se, defineComponent as ie, resolveComponent as pt, openBlock as a, createBlock as D, unref as l, withCtx as S, createElementBlock as c, Fragment as H, renderList as J, createElementVNode as e, toDisplayString as x, createCommentVNode as P, normalizeClass as Z, withDirectives as Be, vShow as Et, createVNode as y, createTextVNode as Ce, onMounted as Ye, onUnmounted as Ge, vModelText as Xe, Transition as Ee, withModifiers as Ve, normalizeStyle as Pe, reactive as Je, createStaticVNode as Ae, withKeys as It, h as Ut } from "vue";
3
+ import { defineStore as Fe } from "pinia";
4
+ import { useRoute as Ue, useRouter as be, createRouter as Ze, createWebHistory as Qe } from "vue-router";
5
+ import { SubMenu as He, MenuItem as Te, Menu as et, Tabs as Tt, TabPane as Pt } from "@xto/navigation";
6
+ import { Icon as I, Button as Ie } from "@xto/base";
7
+ import { Drawer as tt, Message as zt } from "@xto/feedback";
8
+ import { Form as Ft, FormItem as Oe, Input as lt, Checkbox as Dt } from "@xto/form";
9
+ import { createLocaleProvider as At, getSupportedLocales as Bt, useLocale as Vt } from "@xto/core/locale";
10
+ function Ot(t) {
11
11
  const n = /^#?([0-9a-f]{6})$/i.exec(t.trim());
12
12
  if (!n) return null;
13
- const u = parseInt(n[1], 16);
14
- return [u >> 16 & 255, u >> 8 & 255, u & 255];
13
+ const m = parseInt(n[1], 16);
14
+ return [m >> 16 & 255, m >> 8 & 255, m & 255];
15
15
  }
16
- const pe = Ue("app", () => {
17
- const t = y(E.get("appName") || "XTO App"), n = y(E.get("indexPath") || "/dashboard"), u = y(E.get("loginPath") || "/login"), s = y(E.get("isDark") || !1), o = y(E.get("theme") || "light"), i = y(E.get("layout") || "sidebar"), h = y(E.get("isCollapsed") || !1), v = y(E.get("showTabs") ?? !0), d = y(E.get("showFooter") ?? !0), g = y(E.get("showBreadcrumb") ?? !0), _ = y(E.get("primaryColor") || "#4F46E5"), f = y([]), m = y([]), j = w(() => s.value ? "dark" : "light"), D = (N) => {
18
- t.value = N, E.set("appName", N);
19
- }, W = (N) => {
20
- n.value = N, E.set("indexPath", N);
21
- }, A = (N) => {
22
- u.value = N, E.set("loginPath", N);
16
+ function Le(t) {
17
+ const n = T.get(t);
18
+ return n === null || n === "" ? void 0 : n;
19
+ }
20
+ const ye = bt(), Me = ye.features || {}, Rt = ["layout", "primaryColor", "theme", "isDark", "showTabs", "showBreadcrumb", "showFooter"], he = Fe("app", () => {
21
+ const t = g(T.get("appName") || "XTO App"), n = g(T.get("indexPath") || "/dashboard"), m = g(T.get("loginPath") || "/login"), o = g(Le("theme") ?? ye.theme ?? "light"), s = g(o.value === "dark"), h = g(Le("layout") ?? ye.layout ?? "sidebar"), i = g(T.get("isCollapsed") || !1), v = g(Le("showTabs") ?? Me.showTabs ?? !0), d = g(Le("showFooter") ?? Me.showFooter ?? !0), f = g(Le("showBreadcrumb") ?? Me.showBreadcrumb ?? !0), _ = g(Le("primaryColor") ?? ye.primaryColor ?? "#4F46E5"), k = g(ye.allowUserOverride !== !1), u = g([]), K = g([]), A = w(() => s.value ? "dark" : "light"), j = (M) => {
22
+ t.value = M, T.set("appName", M);
23
+ }, B = (M) => {
24
+ n.value = M, T.set("indexPath", M);
25
+ }, W = (M) => {
26
+ m.value = M, T.set("loginPath", M);
23
27
  }, V = () => {
24
- s.value = !s.value, o.value = s.value ? "dark" : "light", ee();
25
- }, G = (N) => {
26
- o.value = N, s.value = N === "dark", ee();
27
- }, ee = () => {
28
- const N = document.documentElement;
29
- s.value ? N.classList.add("dark") : N.classList.remove("dark"), E.set("isDark", s.value), E.set("theme", o.value);
28
+ const M = document.documentElement;
29
+ s.value ? M.classList.add("dark") : M.classList.remove("dark");
30
+ }, Q = () => {
31
+ s.value = !s.value, o.value = s.value ? "dark" : "light", X();
32
+ }, ee = (M) => {
33
+ o.value = M, s.value = M === "dark", X();
30
34
  }, X = () => {
31
- h.value = !h.value, E.set("isCollapsed", h.value);
32
- }, q = (N) => {
33
- i.value = N, E.set("layout", N);
34
- }, oe = () => {
35
- v.value = !v.value, E.set("showTabs", v.value);
36
- }, P = () => {
37
- d.value = !d.value, E.set("showFooter", d.value);
38
- }, I = () => {
39
- g.value = !g.value, E.set("showBreadcrumb", g.value);
40
- }, F = (N) => {
41
- _.value = N;
42
- const H = document.documentElement;
43
- H.style.setProperty("--xto-color-primary", N);
44
- const de = Pt(N);
45
- if (de) {
46
- const te = (Y, me) => {
47
- const fe = me ? [255, 255, 255] : [0, 0, 0];
48
- return `#${de.map((ce, ge) => Math.round(ce + (fe[ge] - ce) * Y)).map((ce) => ce.toString(16).padStart(2, "0")).join("")}`;
35
+ V(), T.set("isDark", s.value), T.set("theme", o.value);
36
+ }, G = () => {
37
+ i.value = !i.value, T.set("isCollapsed", i.value);
38
+ }, te = (M) => {
39
+ h.value = M, T.set("layout", M);
40
+ }, F = () => {
41
+ v.value = !v.value, T.set("showTabs", v.value);
42
+ }, E = () => {
43
+ d.value = !d.value, T.set("showFooter", d.value);
44
+ }, z = () => {
45
+ f.value = !f.value, T.set("showBreadcrumb", f.value);
46
+ }, Y = (M) => {
47
+ const O = document.documentElement;
48
+ O.style.setProperty("--xto-color-primary", M);
49
+ const me = Ot(M);
50
+ if (me) {
51
+ const pe = (oe, ke) => {
52
+ const xe = ke ? [255, 255, 255] : [0, 0, 0];
53
+ return `#${me.map((re, ge) => Math.round(re + (xe[ge] - re) * oe)).map((re) => re.toString(16).padStart(2, "0")).join("")}`;
49
54
  };
50
- for (let Y = 1; Y <= 9; Y++)
51
- H.style.setProperty(`--xto-color-primary-light-${Y}`, te(Y * 0.1, !0));
52
- H.style.setProperty("--xto-color-primary-dark-1", te(0.12, !1)), H.style.setProperty("--xto-color-primary-dark-2", te(0.28, !1)), H.style.setProperty("--xto-color-primary-dark-3", te(0.45, !1)), H.style.setProperty("--xto-color-ring", N);
55
+ for (let oe = 1; oe <= 9; oe++)
56
+ O.style.setProperty(`--xto-color-primary-light-${oe}`, pe(oe * 0.1, !0));
57
+ O.style.setProperty("--xto-color-primary-dark-1", pe(0.12, !1)), O.style.setProperty("--xto-color-primary-dark-2", pe(0.28, !1)), O.style.setProperty("--xto-color-primary-dark-3", pe(0.45, !1)), O.style.setProperty("--xto-color-ring", M);
53
58
  }
54
- E.set("primaryColor", N);
55
- }, J = (N) => {
56
- f.value.includes(N) || f.value.push(N);
57
- }, R = (N) => {
58
- const H = f.value.indexOf(N);
59
- H > -1 && f.value.splice(H, 1);
59
+ }, q = (M) => {
60
+ _.value = M, Y(M), T.set("primaryColor", M);
60
61
  }, ne = () => {
61
- f.value = [];
62
- }, ue = (N) => {
63
- m.value = N;
64
- }, _e = () => {
65
- ee(), _.value !== "#4F46E5" && document.documentElement.style.setProperty("--xto-color-primary", _.value);
62
+ Rt.forEach((M) => T.remove(M)), h.value = ye.layout ?? "sidebar", _.value = ye.primaryColor ?? "#4F46E5", o.value = ye.theme ?? "light", s.value = o.value === "dark", v.value = Me.showTabs ?? !0, d.value = Me.showFooter ?? !0, f.value = Me.showBreadcrumb ?? !0, V(), Y(_.value);
63
+ }, ve = (M) => {
64
+ u.value.includes(M) || u.value.push(M);
65
+ }, we = (M) => {
66
+ const O = u.value.indexOf(M);
67
+ O > -1 && u.value.splice(O, 1);
68
+ }, le = () => {
69
+ u.value = [];
70
+ }, de = (M) => {
71
+ K.value = M;
72
+ }, fe = () => {
73
+ V(), Y(_.value);
66
74
  };
67
- return xe(s, ee), {
75
+ return Se(s, V), {
68
76
  appName: t,
69
77
  indexPath: n,
70
- loginPath: u,
78
+ loginPath: m,
71
79
  isDark: s,
72
80
  theme: o,
73
- layout: i,
74
- isCollapsed: h,
81
+ layout: h,
82
+ isCollapsed: i,
75
83
  showTabs: v,
76
84
  showFooter: d,
77
- showBreadcrumb: g,
85
+ showBreadcrumb: f,
78
86
  primaryColor: _,
79
- cachedViews: f,
80
- mixSubMenus: m,
81
- themeClass: j,
82
- setAppName: D,
83
- setIndexPath: W,
84
- setLoginPath: A,
85
- toggleTheme: V,
86
- toggleCollapse: X,
87
- setTheme: G,
88
- setLayout: q,
89
- toggleTabs: oe,
90
- toggleFooter: P,
91
- toggleBreadcrumb: I,
92
- setPrimaryColor: F,
93
- addCachedView: J,
94
- removeCachedView: R,
95
- clearCachedViews: ne,
96
- setMixSubMenus: ue,
97
- initTheme: _e
87
+ allowUserOverride: k,
88
+ cachedViews: u,
89
+ mixSubMenus: K,
90
+ themeClass: A,
91
+ setAppName: j,
92
+ setIndexPath: B,
93
+ setLoginPath: W,
94
+ toggleTheme: Q,
95
+ toggleCollapse: G,
96
+ setTheme: ee,
97
+ setLayout: te,
98
+ toggleTabs: F,
99
+ toggleFooter: E,
100
+ toggleBreadcrumb: z,
101
+ setPrimaryColor: q,
102
+ resetToServerDefaults: ne,
103
+ addCachedView: ve,
104
+ removeCachedView: we,
105
+ clearCachedViews: le,
106
+ setMixSubMenus: de,
107
+ initTheme: fe
98
108
  };
99
- }), Tt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
109
+ }), Kt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
100
110
  __proto__: null,
101
- useAppStore: pe
102
- }, Symbol.toStringTag, { value: "Module" })), Ft = "menu_list", Dt = "permission_list", Ae = () => `${Ft}_${Ie()}`, Be = () => `${Dt}_${Ie()}`, At = {
111
+ useAppStore: he
112
+ }, Symbol.toStringTag, { value: "Module" })), jt = "menu_list", Wt = "permission_list", Re = () => `${jt}_${Ne()}`, Ke = () => `${Wt}_${Ne()}`, qt = {
103
113
  menuCode: "home",
104
114
  menuName: "首页",
105
115
  menuUrl: "/dashboard",
@@ -108,125 +118,125 @@ const pe = Ue("app", () => {
108
118
  isDefault: !1,
109
119
  isOut: !1
110
120
  };
111
- function ut(t) {
121
+ function vt(t) {
112
122
  return t.filter((n) => n.type !== 1).map((n) => ({
113
123
  ...n,
114
- children: n.children ? ut(n.children) : void 0
124
+ children: n.children ? vt(n.children) : void 0
115
125
  }));
116
126
  }
117
- function Bt(t) {
127
+ function Ht(t) {
118
128
  const n = [];
119
- function u(s) {
120
- s.forEach((o) => {
121
- o.type === 1 && o.menuCode && n.push(o.menuCode), o.children && u(o.children);
129
+ function m(o) {
130
+ o.forEach((s) => {
131
+ s.type === 1 && s.menuCode && n.push(s.menuCode), s.children && m(s.children);
122
132
  });
123
133
  }
124
- return u(t), n;
134
+ return m(t), n;
125
135
  }
126
- const ve = Ue("menu", () => {
127
- const t = y(E.get(Ae()) || []), n = y(E.get(Be()) || []), u = w(() => t.value.length > 0);
136
+ const _e = Fe("menu", () => {
137
+ const t = g(T.get(Re()) || []), n = g(T.get(Ke()) || []), m = w(() => t.value.length > 0);
128
138
  return {
129
139
  menuList: t,
130
140
  permissions: n,
131
- hasMenu: u,
132
- setMenuList: (h) => {
133
- n.value = Bt(h), E.set(Be(), n.value);
134
- const v = ut(h);
135
- t.value = [At, ...v], E.set(Ae(), t.value);
141
+ hasMenu: m,
142
+ setMenuList: (i) => {
143
+ n.value = Ht(i), T.set(Ke(), n.value);
144
+ const v = vt(i);
145
+ t.value = [qt, ...v], T.set(Re(), t.value);
136
146
  },
137
147
  clearMenu: () => {
138
- t.value = [], n.value = [], E.remove(Ae()), E.remove(Be());
148
+ t.value = [], n.value = [], T.remove(Re()), T.remove(Ke());
139
149
  },
140
- hasPermission: (h) => Array.isArray(h) ? h.some((v) => n.value.includes(v)) : n.value.includes(h)
150
+ hasPermission: (i) => Array.isArray(i) ? i.some((v) => n.value.includes(v)) : n.value.includes(i)
141
151
  };
142
- }), Ve = "user_info", re = Ue("user", () => {
143
- const t = y(E.get(Ve)), n = w(() => !!t.value), u = w(() => {
144
- var m;
145
- return ((m = t.value) == null ? void 0 : m.userId) || "";
146
- }), s = w(() => {
147
- var m;
148
- return ((m = t.value) == null ? void 0 : m.userName) || "";
152
+ }), je = "user_info", ce = Fe("user", () => {
153
+ const t = g(T.get(je)), n = w(() => !!t.value), m = w(() => {
154
+ var u;
155
+ return ((u = t.value) == null ? void 0 : u.userId) || "";
149
156
  }), o = w(() => {
150
- var m;
151
- return ((m = t.value) == null ? void 0 : m.departmentName) || "";
152
- }), i = w(() => {
153
- var m;
154
- return ((m = t.value) == null ? void 0 : m.roleName) || "";
157
+ var u;
158
+ return ((u = t.value) == null ? void 0 : u.userName) || "";
159
+ }), s = w(() => {
160
+ var u;
161
+ return ((u = t.value) == null ? void 0 : u.departmentName) || "";
155
162
  }), h = w(() => {
156
- var m;
157
- return ((m = t.value) == null ? void 0 : m.email) || "";
163
+ var u;
164
+ return ((u = t.value) == null ? void 0 : u.roleName) || "";
165
+ }), i = w(() => {
166
+ var u;
167
+ return ((u = t.value) == null ? void 0 : u.email) || "";
158
168
  }), v = w(() => {
159
- var m;
160
- return ((m = t.value) == null ? void 0 : m.mobilePhone) || "";
169
+ var u;
170
+ return ((u = t.value) == null ? void 0 : u.mobilePhone) || "";
161
171
  }), d = w(() => {
162
- var m;
163
- return ((m = t.value) == null ? void 0 : m.positionName) || "";
164
- }), g = w(() => {
165
- var m;
166
- return ((m = t.value) == null ? void 0 : m.avatar) || "";
172
+ var u;
173
+ return ((u = t.value) == null ? void 0 : u.positionName) || "";
174
+ }), f = w(() => {
175
+ var u;
176
+ return ((u = t.value) == null ? void 0 : u.avatar) || "";
167
177
  });
168
178
  return {
169
179
  userInfo: t,
170
180
  isLoggedIn: n,
171
- userId: u,
172
- userName: s,
173
- departmentName: o,
174
- roleName: i,
175
- email: h,
181
+ userId: m,
182
+ userName: o,
183
+ departmentName: s,
184
+ roleName: h,
185
+ email: i,
176
186
  mobilePhone: v,
177
187
  positionName: d,
178
- avatar: g,
179
- setUserInfo: (m) => {
180
- t.value = m, E.set(Ve, m);
188
+ avatar: f,
189
+ setUserInfo: (u) => {
190
+ t.value = u, T.set(je, u);
181
191
  },
182
192
  clearUserInfo: () => {
183
- t.value = null, E.remove(Ve);
193
+ t.value = null, T.remove(je);
184
194
  }
185
195
  };
186
- }), ze = Ue("auth", () => {
187
- const t = y(at()), n = w(() => nt()), u = y(""), s = y(""), o = y(""), i = y("/login");
196
+ }), De = Fe("auth", () => {
197
+ const t = g(it()), n = w(() => ct()), m = g(""), o = g(""), s = g(""), h = g("/login");
188
198
  return {
189
199
  token: t,
190
200
  isLoggedIn: n,
191
- baseUrl: u,
192
- appId: s,
193
- clientId: o,
194
- loginPath: i,
195
- login: (m) => {
196
- t.value = m.access_token, rt(m);
201
+ baseUrl: m,
202
+ appId: o,
203
+ clientId: s,
204
+ loginPath: h,
205
+ login: (u) => {
206
+ t.value = u.access_token, dt(u);
197
207
  },
198
208
  logout: () => {
199
- t.value = null, lt();
209
+ t.value = null, ut();
200
210
  },
201
- setBaseUrl: (m) => {
202
- u.value = m;
211
+ setBaseUrl: (u) => {
212
+ m.value = u;
203
213
  },
204
- setAppId: (m) => {
205
- s.value = m;
214
+ setAppId: (u) => {
215
+ o.value = u;
206
216
  },
207
- setClientId: (m) => {
208
- o.value = m;
217
+ setClientId: (u) => {
218
+ s.value = u;
209
219
  },
210
- setLoginPath: (m) => {
211
- i.value = m;
220
+ setLoginPath: (u) => {
221
+ h.value = u;
212
222
  }
213
223
  };
214
- }), Vt = { class: "menu-item__content" }, Ot = { class: "menu-item__icon" }, Rt = {
224
+ }), Yt = { class: "menu-item__content" }, Gt = { class: "menu-item__icon" }, Xt = {
215
225
  key: 1,
216
226
  class: "menu-item__char"
217
- }, Kt = { class: "menu-item__text" }, jt = { class: "menu-item__content" }, Wt = {
227
+ }, Jt = { class: "menu-item__text" }, Zt = { class: "menu-item__content" }, Qt = {
218
228
  key: 0,
219
229
  class: "menu-item__icon"
220
- }, qt = {
230
+ }, es = {
221
231
  key: 1,
222
232
  class: "menu-item__char"
223
- }, Ht = { class: "menu-item__text" }, Yt = /* @__PURE__ */ le({
233
+ }, ts = { class: "menu-item__text" }, ss = /* @__PURE__ */ ie({
224
234
  __name: "SidebarMenuItem",
225
235
  props: {
226
236
  menu: {}
227
237
  },
228
238
  setup(t) {
229
- const n = t, u = /* @__PURE__ */ new Set([
239
+ const n = t, m = /* @__PURE__ */ new Set([
230
240
  "arrow-up",
231
241
  "arrow-down",
232
242
  "arrow-left",
@@ -328,7 +338,7 @@ const ve = Ue("menu", () => {
328
338
  "sun",
329
339
  "theme",
330
340
  "skin"
331
- ]), s = (d) => {
341
+ ]), o = (d) => {
332
342
  if (!d || d === "") return "";
333
343
  if (d.startsWith("tineco-icon-")) {
334
344
  const _ = d.replace("tineco-icon-", "");
@@ -365,215 +375,215 @@ const ve = Ue("menu", () => {
365
375
  list: "list",
366
376
  grid: "grid"
367
377
  }[d] || d;
368
- }, o = (d) => d ? d.charAt(0) : "", i = (d) => u.has(d), h = w(() => n.menu.menuId || n.menu.menuCode || n.menu.menuUrl || ""), v = w(() => n.menu.children && n.menu.children.length > 0);
369
- return (d, g) => {
370
- const _ = ct("SidebarMenuItem", !0);
371
- return v.value ? (a(), B(l(Ke), {
378
+ }, s = (d) => d ? d.charAt(0) : "", h = (d) => m.has(d), i = w(() => n.menu.menuId || n.menu.menuCode || n.menu.menuUrl || ""), v = w(() => n.menu.children && n.menu.children.length > 0);
379
+ return (d, f) => {
380
+ const _ = pt("SidebarMenuItem", !0);
381
+ return v.value ? (a(), D(l(He), {
372
382
  key: 0,
373
- index: h.value
383
+ index: i.value
374
384
  }, {
375
- title: M(() => [
376
- e("span", Vt, [
377
- e("span", Ot, [
378
- i(s(t.menu.icon)) ? (a(), B(l(U), {
385
+ title: S(() => [
386
+ e("span", Yt, [
387
+ e("span", Gt, [
388
+ h(o(t.menu.icon)) ? (a(), D(l(I), {
379
389
  key: 0,
380
- name: s(t.menu.icon),
390
+ name: o(t.menu.icon),
381
391
  size: 16
382
- }, null, 8, ["name"])) : (a(), c("span", Rt, x(o(t.menu.menuName)), 1))
392
+ }, null, 8, ["name"])) : (a(), c("span", Xt, x(s(t.menu.menuName)), 1))
383
393
  ]),
384
- e("span", Kt, x(t.menu.menuName), 1)
394
+ e("span", Jt, x(t.menu.menuName), 1)
385
395
  ])
386
396
  ]),
387
- default: M(() => [
388
- (a(!0), c(K, null, Z(t.menu.children, (f) => (a(), B(_, {
389
- key: f.menuId || f.menuCode || f.menuUrl,
390
- menu: f
397
+ default: S(() => [
398
+ (a(!0), c(H, null, J(t.menu.children, (k) => (a(), D(_, {
399
+ key: k.menuId || k.menuCode || k.menuUrl,
400
+ menu: k
391
401
  }, null, 8, ["menu"]))), 128))
392
402
  ]),
393
403
  _: 1
394
- }, 8, ["index"])) : (a(), B(l(Se), {
404
+ }, 8, ["index"])) : (a(), D(l(Te), {
395
405
  key: 1,
396
- index: t.menu.menuUrl || h.value
406
+ index: t.menu.menuUrl || i.value
397
407
  }, {
398
- default: M(() => [
399
- e("span", jt, [
400
- t.menu.menuName !== "首页" ? (a(), c("span", Wt, [
401
- i(s(t.menu.icon)) ? (a(), B(l(U), {
408
+ default: S(() => [
409
+ e("span", Zt, [
410
+ t.menu.menuName !== "首页" ? (a(), c("span", Qt, [
411
+ h(o(t.menu.icon)) ? (a(), D(l(I), {
402
412
  key: 0,
403
- name: s(t.menu.icon),
413
+ name: o(t.menu.icon),
404
414
  size: 16
405
- }, null, 8, ["name"])) : (a(), c("span", qt, x(o(t.menu.menuName)), 1))
406
- ])) : T("", !0),
407
- e("span", Ht, x(t.menu.menuName), 1)
415
+ }, null, 8, ["name"])) : (a(), c("span", es, x(s(t.menu.menuName)), 1))
416
+ ])) : P("", !0),
417
+ e("span", ts, x(t.menu.menuName), 1)
408
418
  ])
409
419
  ]),
410
420
  _: 1
411
421
  }, 8, ["index"]));
412
422
  };
413
423
  }
414
- }), ie = (t, n) => {
415
- const u = t.__vccOpts || t;
416
- for (const [s, o] of n)
417
- u[s] = o;
418
- return u;
419
- }, Gt = /* @__PURE__ */ ie(Yt, [["__scopeId", "data-v-03a4d35c"]]), Xt = {
424
+ }), ue = (t, n) => {
425
+ const m = t.__vccOpts || t;
426
+ for (const [o, s] of n)
427
+ m[o] = s;
428
+ return m;
429
+ }, os = /* @__PURE__ */ ue(ss, [["__scopeId", "data-v-03a4d35c"]]), as = {
420
430
  key: 0,
421
431
  class: "sidebar__logo"
422
- }, Jt = ["src"], Zt = {
432
+ }, ns = ["src"], ls = {
423
433
  key: 1,
424
434
  class: "sidebar__user"
425
- }, Qt = { class: "sidebar__user-info" }, es = { class: "sidebar__user-name" }, ts = { class: "sidebar__user-role" }, Oe = "sidebar_opened_menus", Re = "sidebar_menu_list_key", ss = /* @__PURE__ */ le({
435
+ }, rs = { class: "sidebar__user-info" }, is = { class: "sidebar__user-name" }, cs = { class: "sidebar__user-role" }, We = "sidebar_opened_menus", qe = "sidebar_menu_list_key", us = /* @__PURE__ */ ie({
426
436
  __name: "Sidebar",
427
437
  props: {
428
438
  menuList: { default: () => [] },
429
439
  showLogo: { type: Boolean, default: !0 },
430
440
  showUser: { type: Boolean, default: !0 },
431
- logoSrc: { default: Ee("/vite.svg") }
441
+ logoSrc: {}
432
442
  },
433
443
  setup(t) {
434
- const n = t, u = Le(), s = he(), o = ve(), i = re(), h = ze(), v = pe(), d = w(() => n.menuList.length > 0 ? n.menuList : o.menuList), g = w(() => v.isCollapsed), _ = w(() => u.path), f = (P) => P.menuId || P.menuCode || P.menuUrl || "", m = () => d.value.map(f).join(","), j = E.get(Re) || "", D = m(), W = j === D ? E.get(Oe) || [] : [], A = y(W);
435
- xe(A, (P) => {
436
- E.set(Oe, P), E.set(Re, m());
444
+ const n = t, m = w(() => n.logoSrc || ze("/vite.svg")), o = Ue(), s = be(), h = _e(), i = ce(), v = De(), d = he(), f = w(() => n.menuList.length > 0 ? n.menuList : h.menuList), _ = w(() => d.isCollapsed), k = w(() => o.path), u = (F) => F.menuId || F.menuCode || F.menuUrl || "", K = () => f.value.map(u).join(","), A = T.get(qe) || "", j = K(), B = A === j ? T.get(We) || [] : [], W = g(B);
445
+ Se(W, (F) => {
446
+ T.set(We, F), T.set(qe, K());
437
447
  }, { deep: !0 });
438
- const V = (P, I, F = []) => {
439
- var J;
440
- for (const R of P) {
441
- if (R.menuUrl && (I === R.menuUrl || I.startsWith(R.menuUrl + "/")))
442
- return [...F, f(R)];
443
- if ((J = R.children) != null && J.length) {
444
- const ne = V(R.children, I, [...F, f(R)]);
448
+ const V = (F, E, z = []) => {
449
+ var Y;
450
+ for (const q of F) {
451
+ if (q.menuUrl && (E === q.menuUrl || E.startsWith(q.menuUrl + "/")))
452
+ return [...z, u(q)];
453
+ if ((Y = q.children) != null && Y.length) {
454
+ const ne = V(q.children, E, [...z, u(q)]);
445
455
  if (ne) return ne;
446
456
  }
447
457
  }
448
458
  return null;
449
459
  };
450
- xe([() => u.path, d], ([P, I]) => {
451
- if (I.length > 0) {
452
- const F = V(I, P);
453
- if (F) {
454
- const J = F.slice(0, -1), R = /* @__PURE__ */ new Set([...A.value, ...J]);
455
- A.value = Array.from(R);
460
+ Se([() => o.path, f], ([F, E]) => {
461
+ if (E.length > 0) {
462
+ const z = V(E, F);
463
+ if (z) {
464
+ const Y = z.slice(0, -1), q = /* @__PURE__ */ new Set([...W.value, ...Y]);
465
+ W.value = Array.from(q);
456
466
  }
457
467
  }
458
- }, { immediate: !0 }), xe(d, (P, I) => {
459
- P !== I && (A.value = [], E.set(Oe, []), E.set(Re, m()));
468
+ }, { immediate: !0 }), Se(f, (F, E) => {
469
+ F !== E && (W.value = [], T.set(We, []), T.set(qe, K()));
460
470
  }, { immediate: !1 });
461
- const G = w(() => v.isDark ? "#161B21" : "#fff"), ee = w(() => v.isDark ? "#D9DCE1" : "#4E5566"), X = w(() => v.isDark ? "#818CF8" : "#4F46E5"), q = (P) => {
462
- P && P !== u.path && s.push(P);
463
- }, oe = () => {
464
- h.logout(), i.clearUserInfo(), o.clearMenu(), s.push(v.loginPath);
471
+ const Q = w(() => d.isDark ? "#161B21" : "#fff"), ee = w(() => d.isDark ? "#D9DCE1" : "#4E5566"), X = w(() => d.isDark ? "#818CF8" : "#4F46E5"), G = (F) => {
472
+ F && F !== o.path && s.push(F);
473
+ }, te = () => {
474
+ v.logout(), i.clearUserInfo(), h.clearMenu(), s.push(d.loginPath);
465
475
  };
466
- return (P, I) => (a(), c("div", {
467
- class: Q(["sidebar", { "sidebar--collapsed": g.value }])
476
+ return (F, E) => (a(), c("div", {
477
+ class: Z(["sidebar", { "sidebar--collapsed": _.value }])
468
478
  }, [
469
- n.showLogo ? (a(), c("div", Xt, [
479
+ n.showLogo ? (a(), c("div", as, [
470
480
  e("img", {
471
- src: n.logoSrc,
481
+ src: m.value,
472
482
  alt: "Logo",
473
483
  class: "sidebar__logo-img"
474
- }, null, 8, Jt),
475
- Te(e("span", { class: "sidebar__logo-text" }, x(l(v).appName), 513), [
476
- [xt, !g.value]
484
+ }, null, 8, ns),
485
+ Be(e("span", { class: "sidebar__logo-text" }, x(l(d).appName), 513), [
486
+ [Et, !_.value]
477
487
  ])
478
- ])) : T("", !0),
479
- b(l(Xe), {
480
- modelValue: _.value,
481
- "onUpdate:modelValue": I[0] || (I[0] = (F) => _.value = F),
482
- openeds: A.value,
483
- "onUpdate:openeds": I[1] || (I[1] = (F) => A.value = F),
488
+ ])) : P("", !0),
489
+ y(l(et), {
490
+ modelValue: k.value,
491
+ "onUpdate:modelValue": E[0] || (E[0] = (z) => k.value = z),
492
+ openeds: W.value,
493
+ "onUpdate:openeds": E[1] || (E[1] = (z) => W.value = z),
484
494
  mode: "vertical",
485
- collapse: g.value,
495
+ collapse: _.value,
486
496
  "collapse-transition": !1,
487
- "background-color": G.value,
497
+ "background-color": Q.value,
488
498
  "text-color": ee.value,
489
499
  "active-text-color": X.value,
490
500
  class: "sidebar__menu",
491
- onSelect: q
501
+ onSelect: G
492
502
  }, {
493
- default: M(() => [
494
- (a(!0), c(K, null, Z(d.value, (F) => (a(), B(Gt, {
495
- key: f(F),
496
- menu: F
503
+ default: S(() => [
504
+ (a(!0), c(H, null, J(f.value, (z) => (a(), D(os, {
505
+ key: u(z),
506
+ menu: z
497
507
  }, null, 8, ["menu"]))), 128))
498
508
  ]),
499
509
  _: 1
500
510
  }, 8, ["modelValue", "openeds", "collapse", "background-color", "text-color", "active-text-color"]),
501
- n.showUser && !g.value ? (a(), c("div", Zt, [
502
- e("div", Qt, [
503
- e("span", es, x(l(i).userName), 1),
504
- e("span", ts, x(l(i).departmentName), 1)
511
+ n.showUser && !_.value ? (a(), c("div", ls, [
512
+ e("div", rs, [
513
+ e("span", is, x(l(i).userName), 1),
514
+ e("span", cs, x(l(i).departmentName), 1)
505
515
  ]),
506
- b(l($e), {
516
+ y(l(Ie), {
507
517
  type: "text",
508
518
  size: "small",
509
- onClick: oe
519
+ onClick: te
510
520
  }, {
511
- default: M(() => [...I[2] || (I[2] = [
512
- ye("退出", -1)
521
+ default: S(() => [...E[2] || (E[2] = [
522
+ Ce("退出", -1)
513
523
  ])]),
514
524
  _: 1
515
525
  })
516
- ])) : T("", !0)
526
+ ])) : P("", !0)
517
527
  ], 2));
518
528
  }
519
- }), ot = /* @__PURE__ */ ie(ss, [["__scopeId", "data-v-0d079780"]]), os = { class: "header" }, as = { class: "header__left" }, ns = {
529
+ }), rt = /* @__PURE__ */ ue(us, [["__scopeId", "data-v-3145ea3a"]]), ds = { class: "header" }, ms = { class: "header__left" }, ps = {
520
530
  key: 0,
521
531
  class: "header__breadcrumb"
522
- }, ls = {
532
+ }, vs = {
523
533
  key: 0,
524
534
  class: "breadcrumb-separator"
525
- }, rs = { class: "header__right" }, is = {
535
+ }, hs = { class: "header__right" }, _s = {
526
536
  key: 0,
527
537
  class: "header__search-dropdown"
528
- }, cs = {
538
+ }, fs = {
529
539
  key: 0,
530
540
  class: "header__search-results"
531
- }, us = ["onClick"], ds = {
541
+ }, gs = ["onClick"], ys = {
532
542
  key: 0,
533
543
  class: "header__search-icon"
534
- }, ms = {
544
+ }, bs = {
535
545
  key: 1,
536
546
  class: "header__search-char"
537
- }, ps = { class: "header__search-item-title" }, vs = {
547
+ }, ws = { class: "header__search-item-title" }, ks = {
538
548
  key: 1,
539
549
  class: "header__search-item-parent"
540
- }, hs = {
550
+ }, xs = {
541
551
  key: 1,
542
552
  class: "header__search-empty"
543
- }, _s = ["title"], fs = { class: "header__avatar" }, gs = { class: "header__user-name" }, ys = {
553
+ }, Cs = ["title"], $s = { class: "header__avatar" }, Ls = { class: "header__user-name" }, Ms = {
544
554
  key: 0,
545
555
  class: "header__dropdown"
546
- }, bs = { class: "header__dropdown-header" }, ks = { class: "header__dropdown-avatar" }, ws = { class: "header__dropdown-info" }, xs = { class: "header__dropdown-name" }, Cs = { class: "header__dropdown-role" }, $s = { class: "header__dropdown-menu" }, Ls = { class: "settings-drawer" }, Ms = { class: "settings-section" }, Ss = { class: "settings-layout-options" }, Ns = ["onClick"], Is = { class: "layout-option__preview" }, Es = {
556
+ }, Ss = { class: "header__dropdown-header" }, Ns = { class: "header__dropdown-avatar" }, Es = { class: "header__dropdown-info" }, Is = { class: "header__dropdown-name" }, Us = { class: "header__dropdown-role" }, Ts = { class: "header__dropdown-menu" }, Ps = { class: "settings-drawer" }, zs = { class: "settings-section" }, Fs = { class: "settings-layout-options" }, Ds = ["onClick"], As = { class: "layout-option__preview" }, Bs = {
547
557
  key: 0,
548
558
  class: "layout-preview-sidebar"
549
- }, Us = {
559
+ }, Vs = {
550
560
  key: 1,
551
561
  class: "layout-preview-top"
552
- }, zs = {
562
+ }, Os = {
553
563
  key: 2,
554
564
  class: "layout-preview-mix"
555
- }, Ps = { class: "layout-option__label" }, Ts = { class: "settings-section" }, Fs = { class: "settings-color-options" }, Ds = ["title", "onClick"], As = { class: "settings-section" }, Bs = { class: "settings-switch-list" }, Vs = { class: "settings-switch-item" }, Os = { class: "settings-switch-item" }, Rs = /* @__PURE__ */ le({
565
+ }, Rs = { class: "layout-option__label" }, Ks = { class: "settings-section" }, js = { class: "settings-color-options" }, Ws = ["title", "onClick"], qs = { class: "settings-section" }, Hs = { class: "settings-switch-list" }, Ys = { class: "settings-switch-item" }, Gs = { class: "settings-switch-item" }, Xs = { class: "settings-section" }, Js = /* @__PURE__ */ ie({
556
566
  __name: "Header",
557
567
  setup(t) {
558
- const n = Le(), u = he(), s = pe(), o = re(), i = ze(), h = ve(), v = y(!1), d = y(!1), g = y(null), _ = y(!1), f = y(!1), m = y(""), j = y(null), D = y(!1), W = [
568
+ const n = Ue(), m = be(), o = he(), s = ce(), h = De(), i = _e(), v = g(!1), d = g(!1), f = g(null), _ = g(!1), k = g(!1), u = g(""), K = g(null), A = g(!1), j = [
559
569
  { value: "sidebar", label: "左侧菜单", icon: "sidebar-left" },
560
570
  { value: "top", label: "顶部菜单", icon: "menu" },
561
571
  { value: "mix", label: "混合菜单", icon: "grid" }
562
- ], A = [
572
+ ], B = [
563
573
  { value: "#4F46E5", label: "品牌蓝" },
564
574
  { value: "#0F6FDE", label: "企业蓝" },
565
575
  { value: "#00A870", label: "翡翠绿" },
566
576
  { value: "#D46B08", label: "琥珀橙" },
567
577
  { value: "#1F2329", label: "石墨黑" }
568
- ], V = w(() => n.matched.filter((k) => k.meta && k.meta.title).map((k) => ({
569
- title: k.meta.title,
570
- path: k.path
571
- }))), G = (z, k = "") => {
578
+ ], W = w(() => n.matched.filter((b) => b.meta && b.meta.title).map((b) => ({
579
+ title: b.meta.title,
580
+ path: b.path
581
+ }))), V = (U, b = "") => {
572
582
  const se = [];
573
- return z.forEach(($) => {
574
- $.children && $.children.length > 0 ? se.push(...G($.children, $.menuName)) : se.push({ ...$, parentTitle: k, title: $.menuName, path: $.menuUrl });
583
+ return U.forEach(($) => {
584
+ $.children && $.children.length > 0 ? se.push(...V($.children, $.menuName)) : se.push({ ...$, parentTitle: b, title: $.menuName, path: $.menuUrl });
575
585
  }), se;
576
- }, ee = /* @__PURE__ */ new Set([
586
+ }, Q = /* @__PURE__ */ new Set([
577
587
  "arrow-up",
578
588
  "arrow-down",
579
589
  "arrow-left",
@@ -675,10 +685,10 @@ const ve = Ue("menu", () => {
675
685
  "sun",
676
686
  "theme",
677
687
  "skin"
678
- ]), X = (z) => {
679
- if (!z || z === "") return "";
680
- if (z.startsWith("tineco-icon-")) {
681
- const se = z.replace("tineco-icon-", "");
688
+ ]), ee = (U) => {
689
+ if (!U || U === "") return "";
690
+ if (U.startsWith("tineco-icon-")) {
691
+ const se = U.replace("tineco-icon-", "");
682
692
  return {
683
693
  home: "home",
684
694
  dashboard: "dashboard",
@@ -711,169 +721,172 @@ const ve = Ue("menu", () => {
711
721
  app: "app",
712
722
  list: "list",
713
723
  grid: "grid"
714
- }[z] || z;
715
- }, q = (z) => z ? z.charAt(0) : "", oe = (z) => ee.has(z), P = w(() => m.value.trim() ? G(h.menuList).filter(
716
- (k) => k.title.toLowerCase().includes(m.value.toLowerCase())
717
- ) : []), I = w(() => s.layout), F = () => {
718
- s.toggleCollapse();
719
- }, J = () => {
720
- s.toggleTheme();
721
- }, R = () => {
724
+ }[U] || U;
725
+ }, X = (U) => U ? U.charAt(0) : "", G = (U) => Q.has(U), te = w(() => u.value.trim() ? V(i.menuList).filter(
726
+ (b) => b.title.toLowerCase().includes(u.value.toLowerCase())
727
+ ) : []), F = w(() => o.layout), E = () => {
728
+ o.toggleCollapse();
729
+ }, z = () => {
730
+ o.toggleTheme();
731
+ }, Y = () => {
722
732
  d.value = !0;
723
- }, ne = (z) => {
724
- s.setLayout(z), d.value = !1;
725
- }, ue = (z) => {
726
- D.value = z;
727
- const k = document.documentElement;
728
- z ? k.classList.add("grey-mode") : k.classList.remove("grey-mode");
729
- }, _e = () => {
730
- ue(!D.value), d.value = !1;
731
- }, N = () => {
732
- s.toggleTheme(), d.value = !1;
733
- }, H = () => {
734
- document.fullscreenElement ? document.exitFullscreen() : document.documentElement.requestFullscreen();
733
+ }, q = (U) => {
734
+ o.setLayout(U), d.value = !1;
735
+ }, ne = (U) => {
736
+ A.value = U;
737
+ const b = document.documentElement;
738
+ U ? b.classList.add("grey-mode") : b.classList.remove("grey-mode");
739
+ }, ve = () => {
740
+ ne(!A.value), d.value = !1;
741
+ }, we = () => {
742
+ o.toggleTheme(), d.value = !1;
743
+ }, le = () => {
744
+ o.resetToServerDefaults(), d.value = !1;
735
745
  }, de = () => {
746
+ document.fullscreenElement ? document.exitFullscreen() : document.documentElement.requestFullscreen();
747
+ }, fe = () => {
736
748
  _.value = !!document.fullscreenElement;
737
- }, te = () => {
749
+ }, M = () => {
738
750
  v.value = !v.value;
739
- }, Y = () => {
751
+ }, O = () => {
740
752
  v.value = !1;
741
753
  }, me = () => {
742
- f.value = !1, m.value = "";
743
- }, fe = (z) => {
744
- u.push(z), me();
745
- }, be = (z) => {
746
- s.setPrimaryColor(z), d.value = !1;
747
- }, ce = () => {
748
- Y(), u.push("/profile");
749
- }, ge = () => {
750
- Y(), u.push("/change-password");
751
- }, Me = () => {
752
- Y(), i.logout(), o.clearUserInfo(), h.clearMenu(), u.push(s.loginPath);
753
- }, ke = (z) => {
754
- g.value && !g.value.contains(z.target) && Y(), j.value && !j.value.contains(z.target) && me();
755
- }, we = (z) => {
756
- z.key === "Escape" && (me(), Y());
754
+ k.value = !1, u.value = "";
755
+ }, pe = (U) => {
756
+ m.push(U), me();
757
+ }, oe = (U) => {
758
+ o.setPrimaryColor(U), d.value = !1;
759
+ }, ke = () => {
760
+ O(), m.push("/profile");
761
+ }, xe = () => {
762
+ O(), m.push("/change-password");
763
+ }, $e = () => {
764
+ O(), h.logout(), s.clearUserInfo(), i.clearMenu(), m.push(o.loginPath);
765
+ }, re = (U) => {
766
+ f.value && !f.value.contains(U.target) && O(), K.value && !K.value.contains(U.target) && me();
767
+ }, ge = (U) => {
768
+ U.key === "Escape" && (me(), O());
757
769
  };
758
- return je(() => {
759
- document.addEventListener("click", ke), document.addEventListener("fullscreenchange", de), document.addEventListener("keydown", we), s.initTheme(), D.value = document.documentElement.classList.contains("grey-mode");
760
- }), We(() => {
761
- document.removeEventListener("click", ke), document.removeEventListener("fullscreenchange", de), document.removeEventListener("keydown", we);
762
- }), (z, k) => {
770
+ return Ye(() => {
771
+ document.addEventListener("click", re), document.addEventListener("fullscreenchange", fe), document.addEventListener("keydown", ge), o.initTheme(), A.value = document.documentElement.classList.contains("grey-mode");
772
+ }), Ge(() => {
773
+ document.removeEventListener("click", re), document.removeEventListener("fullscreenchange", fe), document.removeEventListener("keydown", ge);
774
+ }), (U, b) => {
763
775
  var se;
764
- return a(), c("div", os, [
765
- e("div", as, [
776
+ return a(), c("div", ds, [
777
+ e("div", ms, [
766
778
  e("div", {
767
779
  class: "header__collapse",
768
- onClick: F
780
+ onClick: E
769
781
  }, [
770
- b(l(U), {
771
- name: l(s).isCollapsed ? "menu-unfold" : "menu-fold",
782
+ y(l(I), {
783
+ name: l(o).isCollapsed ? "menu-unfold" : "menu-fold",
772
784
  size: 18
773
785
  }, null, 8, ["name"])
774
786
  ]),
775
- l(s).showBreadcrumb ? (a(), c("div", ns, [
776
- (a(!0), c(K, null, Z(V.value, ($, S) => (a(), c("span", {
787
+ l(o).showBreadcrumb ? (a(), c("div", ps, [
788
+ (a(!0), c(H, null, J(W.value, ($, N) => (a(), c("span", {
777
789
  key: $.path
778
790
  }, [
779
- S > 0 ? (a(), c("span", ls, "/")) : T("", !0),
791
+ N > 0 ? (a(), c("span", vs, "/")) : P("", !0),
780
792
  e("span", {
781
- class: Q({ "is-current": S === V.value.length - 1 })
793
+ class: Z({ "is-current": N === W.value.length - 1 })
782
794
  }, x($.title), 3)
783
795
  ]))), 128))
784
- ])) : T("", !0)
796
+ ])) : P("", !0)
785
797
  ]),
786
- e("div", rs, [
798
+ e("div", hs, [
787
799
  e("div", {
788
800
  class: "header__search",
789
801
  ref_key: "searchRef",
790
- ref: j
802
+ ref: K
791
803
  }, [
792
- b(l(U), {
804
+ y(l(I), {
793
805
  name: "search",
794
806
  size: 14,
795
807
  class: "header__search-icon"
796
808
  }),
797
- Te(e("input", {
798
- "onUpdate:modelValue": k[0] || (k[0] = ($) => m.value = $),
809
+ Be(e("input", {
810
+ "onUpdate:modelValue": b[0] || (b[0] = ($) => u.value = $),
799
811
  type: "text",
800
812
  class: "header__search-input",
801
813
  placeholder: "搜索菜单...",
802
- onFocus: k[1] || (k[1] = ($) => f.value = !0)
814
+ onFocus: b[1] || (b[1] = ($) => k.value = !0)
803
815
  }, null, 544), [
804
- [qe, m.value]
816
+ [Xe, u.value]
805
817
  ]),
806
- b(Ce, { name: "search-dropdown" }, {
807
- default: M(() => [
808
- f.value && (P.value.length > 0 || m.value) ? (a(), c("div", is, [
809
- P.value.length > 0 ? (a(), c("div", cs, [
810
- (a(!0), c(K, null, Z(P.value, ($) => (a(), c("div", {
818
+ y(Ee, { name: "search-dropdown" }, {
819
+ default: S(() => [
820
+ k.value && (te.value.length > 0 || u.value) ? (a(), c("div", _s, [
821
+ te.value.length > 0 ? (a(), c("div", fs, [
822
+ (a(!0), c(H, null, J(te.value, ($) => (a(), c("div", {
811
823
  key: $.path,
812
824
  class: "header__search-item",
813
- onClick: (S) => fe($.path)
825
+ onClick: (N) => pe($.path)
814
826
  }, [
815
- $.title !== "首页" ? (a(), c("span", ds, [
816
- oe(X($.icon)) ? (a(), B(l(U), {
827
+ $.title !== "首页" ? (a(), c("span", ys, [
828
+ G(ee($.icon)) ? (a(), D(l(I), {
817
829
  key: 0,
818
- name: X($.icon),
830
+ name: ee($.icon),
819
831
  size: 16
820
- }, null, 8, ["name"])) : (a(), c("span", ms, x(q($.title)), 1))
821
- ])) : T("", !0),
822
- e("span", ps, x($.title), 1),
823
- $.parentTitle ? (a(), c("span", vs, x($.parentTitle), 1)) : T("", !0)
824
- ], 8, us))), 128))
825
- ])) : (a(), c("div", hs, " 未找到匹配的菜单 "))
826
- ])) : T("", !0)
832
+ }, null, 8, ["name"])) : (a(), c("span", bs, x(X($.title)), 1))
833
+ ])) : P("", !0),
834
+ e("span", ws, x($.title), 1),
835
+ $.parentTitle ? (a(), c("span", ks, x($.parentTitle), 1)) : P("", !0)
836
+ ], 8, gs))), 128))
837
+ ])) : (a(), c("div", xs, " 未找到匹配的菜单 "))
838
+ ])) : P("", !0)
827
839
  ]),
828
840
  _: 1
829
841
  })
830
842
  ], 512),
831
843
  e("div", {
832
844
  class: "header__action",
833
- onClick: H,
845
+ onClick: de,
834
846
  title: _.value ? "退出全屏" : "全屏"
835
847
  }, [
836
- b(l(U), {
848
+ y(l(I), {
837
849
  name: _.value ? "fullscreen-exit" : "fullscreen",
838
850
  size: 16
839
851
  }, null, 8, ["name"])
840
- ], 8, _s),
841
- e("div", {
852
+ ], 8, Cs),
853
+ l(o).allowUserOverride ? (a(), c("div", {
854
+ key: 0,
842
855
  class: "header__action",
843
- onClick: R,
856
+ onClick: Y,
844
857
  title: "换肤设置"
845
858
  }, [
846
- b(l(U), {
859
+ y(l(I), {
847
860
  name: "skin",
848
861
  size: 16
849
862
  })
850
- ]),
863
+ ])) : P("", !0),
851
864
  e("div", {
852
865
  class: "header__action",
853
- onClick: J,
866
+ onClick: z,
854
867
  title: "切换主题"
855
868
  }, [
856
- b(l(U), {
857
- name: l(s).isDark ? "sun" : "moon",
869
+ y(l(I), {
870
+ name: l(o).isDark ? "sun" : "moon",
858
871
  size: 16
859
872
  }, null, 8, ["name"])
860
873
  ]),
861
874
  e("div", {
862
875
  class: "header__user",
863
876
  ref_key: "dropdownRef",
864
- ref: g
877
+ ref: f
865
878
  }, [
866
879
  e("div", {
867
880
  class: "header__user-trigger",
868
- onClick: Fe(te, ["stop"])
881
+ onClick: Ve(M, ["stop"])
869
882
  }, [
870
- e("div", fs, [
871
- e("span", null, x(((se = l(o).userName) == null ? void 0 : se.charAt(0)) || "U"), 1)
883
+ e("div", $s, [
884
+ e("span", null, x(((se = l(s).userName) == null ? void 0 : se.charAt(0)) || "U"), 1)
872
885
  ]),
873
- e("span", gs, x(l(o).userName), 1),
886
+ e("span", Ls, x(l(s).userName), 1),
874
887
  e("span", {
875
- class: Q(["header__user-arrow", { "is-active": v.value }])
876
- }, [...k[3] || (k[3] = [
888
+ class: Z(["header__user-arrow", { "is-active": v.value }])
889
+ }, [...b[3] || (b[3] = [
877
890
  e("svg", {
878
891
  viewBox: "0 0 12 12",
879
892
  width: "10",
@@ -888,89 +901,89 @@ const ve = Ue("menu", () => {
888
901
  ], -1)
889
902
  ])], 2)
890
903
  ]),
891
- b(Ce, { name: "dropdown" }, {
892
- default: M(() => {
904
+ y(Ee, { name: "dropdown" }, {
905
+ default: S(() => {
893
906
  var $;
894
907
  return [
895
- v.value ? (a(), c("div", ys, [
896
- e("div", bs, [
897
- e("div", ks, [
898
- e("span", null, x((($ = l(o).userName) == null ? void 0 : $.charAt(0)) || "U"), 1)
908
+ v.value ? (a(), c("div", Ms, [
909
+ e("div", Ss, [
910
+ e("div", Ns, [
911
+ e("span", null, x((($ = l(s).userName) == null ? void 0 : $.charAt(0)) || "U"), 1)
899
912
  ]),
900
- e("div", ws, [
901
- e("div", xs, x(l(o).userName), 1),
902
- e("div", Cs, x(l(o).roleName || l(o).departmentName), 1)
913
+ e("div", Es, [
914
+ e("div", Is, x(l(s).userName), 1),
915
+ e("div", Us, x(l(s).roleName || l(s).departmentName), 1)
903
916
  ])
904
917
  ]),
905
- k[8] || (k[8] = e("div", { class: "header__dropdown-divider" }, null, -1)),
906
- e("div", $s, [
918
+ b[8] || (b[8] = e("div", { class: "header__dropdown-divider" }, null, -1)),
919
+ e("div", Ts, [
907
920
  e("div", {
908
921
  class: "header__dropdown-item",
909
- onClick: ce
922
+ onClick: ke
910
923
  }, [
911
- b(l(U), {
924
+ y(l(I), {
912
925
  name: "user",
913
926
  size: 16
914
927
  }),
915
- k[4] || (k[4] = e("span", null, "个人信息", -1))
928
+ b[4] || (b[4] = e("span", null, "个人信息", -1))
916
929
  ]),
917
930
  e("div", {
918
931
  class: "header__dropdown-item",
919
- onClick: ge
932
+ onClick: xe
920
933
  }, [
921
- b(l(U), {
934
+ y(l(I), {
922
935
  name: "lock",
923
936
  size: 16
924
937
  }),
925
- k[5] || (k[5] = e("span", null, "修改密码", -1))
938
+ b[5] || (b[5] = e("span", null, "修改密码", -1))
926
939
  ]),
927
- k[7] || (k[7] = e("div", { class: "header__dropdown-divider" }, null, -1)),
940
+ b[7] || (b[7] = e("div", { class: "header__dropdown-divider" }, null, -1)),
928
941
  e("div", {
929
942
  class: "header__dropdown-item header__dropdown-item--danger",
930
- onClick: Me
943
+ onClick: $e
931
944
  }, [
932
- b(l(U), {
945
+ y(l(I), {
933
946
  name: "logout",
934
947
  size: 16
935
948
  }),
936
- k[6] || (k[6] = e("span", null, "退出登录", -1))
949
+ b[6] || (b[6] = e("span", null, "退出登录", -1))
937
950
  ])
938
951
  ])
939
- ])) : T("", !0)
952
+ ])) : P("", !0)
940
953
  ];
941
954
  }),
942
955
  _: 1
943
956
  })
944
957
  ], 512)
945
958
  ]),
946
- b(l(Je), {
959
+ y(l(tt), {
947
960
  modelValue: d.value,
948
- "onUpdate:modelValue": k[2] || (k[2] = ($) => d.value = $),
961
+ "onUpdate:modelValue": b[2] || (b[2] = ($) => d.value = $),
949
962
  title: "换肤设置",
950
963
  direction: "rtl",
951
964
  size: "320px"
952
965
  }, {
953
- default: M(() => [
954
- e("div", Ls, [
955
- e("div", Ms, [
956
- k[12] || (k[12] = e("div", { class: "settings-title" }, "布局模式", -1)),
957
- e("div", Ss, [
958
- (a(), c(K, null, Z(W, ($) => e("div", {
966
+ default: S(() => [
967
+ e("div", Ps, [
968
+ e("div", zs, [
969
+ b[12] || (b[12] = e("div", { class: "settings-title" }, "布局模式", -1)),
970
+ e("div", Fs, [
971
+ (a(), c(H, null, J(j, ($) => e("div", {
959
972
  key: $.value,
960
- class: Q(["layout-option", { "is-active": I.value === $.value }]),
961
- onClick: (S) => ne($.value)
973
+ class: Z(["layout-option", { "is-active": F.value === $.value }]),
974
+ onClick: (N) => q($.value)
962
975
  }, [
963
- e("div", Is, [
964
- $.value === "sidebar" ? (a(), c("div", Es, [...k[9] || (k[9] = [
976
+ e("div", As, [
977
+ $.value === "sidebar" ? (a(), c("div", Bs, [...b[9] || (b[9] = [
965
978
  e("div", { class: "preview-aside" }, null, -1),
966
979
  e("div", { class: "preview-main" }, [
967
980
  e("div", { class: "preview-header" }),
968
981
  e("div", { class: "preview-content" })
969
982
  ], -1)
970
- ])])) : $.value === "top" ? (a(), c("div", Us, [...k[10] || (k[10] = [
983
+ ])])) : $.value === "top" ? (a(), c("div", Vs, [...b[10] || (b[10] = [
971
984
  e("div", { class: "preview-header-full" }, null, -1),
972
985
  e("div", { class: "preview-content-full" }, null, -1)
973
- ])])) : (a(), c("div", zs, [...k[11] || (k[11] = [
986
+ ])])) : (a(), c("div", Os, [...b[11] || (b[11] = [
974
987
  e("div", { class: "preview-header-mix" }, [
975
988
  e("div", { class: "preview-mix-left" })
976
989
  ], -1),
@@ -980,51 +993,63 @@ const ve = Ue("menu", () => {
980
993
  ], -1)
981
994
  ])]))
982
995
  ]),
983
- e("span", Ps, x($.label), 1)
984
- ], 10, Ns)), 64))
996
+ e("span", Rs, x($.label), 1)
997
+ ], 10, Ds)), 64))
985
998
  ])
986
999
  ]),
987
- e("div", Ts, [
988
- k[13] || (k[13] = e("div", { class: "settings-title" }, "主题色", -1)),
989
- e("div", Fs, [
990
- (a(), c(K, null, Z(A, ($) => e("div", {
1000
+ e("div", Ks, [
1001
+ b[13] || (b[13] = e("div", { class: "settings-title" }, "主题色", -1)),
1002
+ e("div", js, [
1003
+ (a(), c(H, null, J(B, ($) => e("div", {
991
1004
  key: $.value,
992
- class: Q(["color-option", { "is-active": l(s).primaryColor === $.value }]),
993
- style: Ne({ backgroundColor: $.value }),
1005
+ class: Z(["color-option", { "is-active": l(o).primaryColor === $.value }]),
1006
+ style: Pe({ backgroundColor: $.value }),
994
1007
  title: $.label,
995
- onClick: (S) => be($.value)
1008
+ onClick: (N) => oe($.value)
996
1009
  }, [
997
- l(s).primaryColor === $.value ? (a(), B(l(U), {
1010
+ l(o).primaryColor === $.value ? (a(), D(l(I), {
998
1011
  key: 0,
999
1012
  name: "check",
1000
1013
  size: 12,
1001
1014
  color: "#fff"
1002
- })) : T("", !0)
1003
- ], 14, Ds)), 64))
1015
+ })) : P("", !0)
1016
+ ], 14, Ws)), 64))
1004
1017
  ])
1005
1018
  ]),
1006
- e("div", As, [
1007
- k[18] || (k[18] = e("div", { class: "settings-title" }, "功能设置", -1)),
1008
- e("div", Bs, [
1009
- e("div", Vs, [
1010
- k[15] || (k[15] = e("span", null, "灰色模式", -1)),
1019
+ e("div", qs, [
1020
+ b[18] || (b[18] = e("div", { class: "settings-title" }, "功能设置", -1)),
1021
+ e("div", Hs, [
1022
+ e("div", Ys, [
1023
+ b[15] || (b[15] = e("span", null, "灰色模式", -1)),
1011
1024
  e("div", {
1012
- class: Q(["switch-wrapper", { "is-checked": D.value }]),
1013
- onClick: _e
1014
- }, [...k[14] || (k[14] = [
1025
+ class: Z(["switch-wrapper", { "is-checked": A.value }]),
1026
+ onClick: ve
1027
+ }, [...b[14] || (b[14] = [
1015
1028
  e("span", { class: "switch-core" }, null, -1)
1016
1029
  ])], 2)
1017
1030
  ]),
1018
- e("div", Os, [
1019
- k[17] || (k[17] = e("span", null, "暗黑模式", -1)),
1031
+ e("div", Gs, [
1032
+ b[17] || (b[17] = e("span", null, "暗黑模式", -1)),
1020
1033
  e("div", {
1021
- class: Q(["switch-wrapper", { "is-checked": l(s).isDark }]),
1022
- onClick: N
1023
- }, [...k[16] || (k[16] = [
1034
+ class: Z(["switch-wrapper", { "is-checked": l(o).isDark }]),
1035
+ onClick: we
1036
+ }, [...b[16] || (b[16] = [
1024
1037
  e("span", { class: "switch-core" }, null, -1)
1025
1038
  ])], 2)
1026
1039
  ])
1027
1040
  ])
1041
+ ]),
1042
+ e("div", Xs, [
1043
+ e("div", {
1044
+ class: "settings-reset",
1045
+ onClick: le
1046
+ }, [
1047
+ y(l(I), {
1048
+ name: "refresh",
1049
+ size: 14
1050
+ }),
1051
+ b[19] || (b[19] = e("span", null, "恢复默认", -1))
1052
+ ])
1028
1053
  ])
1029
1054
  ])
1030
1055
  ]),
@@ -1033,73 +1058,73 @@ const ve = Ue("menu", () => {
1033
1058
  ]);
1034
1059
  };
1035
1060
  }
1036
- }), Ks = /* @__PURE__ */ ie(Rs, [["__scopeId", "data-v-11f8bfa7"]]), js = { class: "top-menu" }, Ws = { class: "top-menu__logo" }, qs = ["src"], Hs = { class: "top-menu__logo-text" }, Ys = { class: "top-menu__menu-content" }, Gs = {
1061
+ }), Zs = /* @__PURE__ */ ue(Js, [["__scopeId", "data-v-21769fe5"]]), Qs = { class: "top-menu" }, eo = { class: "top-menu__logo" }, to = ["src"], so = { class: "top-menu__logo-text" }, oo = { class: "top-menu__menu-content" }, ao = {
1037
1062
  key: 0,
1038
1063
  class: "top-menu__menu-icon"
1039
- }, Xs = {
1064
+ }, no = {
1040
1065
  key: 1,
1041
1066
  class: "top-menu__menu-char"
1042
- }, Js = { class: "top-menu__menu-text" }, Zs = { class: "top-menu__menu-content" }, Qs = { class: "top-menu__menu-icon" }, eo = {
1067
+ }, lo = { class: "top-menu__menu-text" }, ro = { class: "top-menu__menu-content" }, io = { class: "top-menu__menu-icon" }, co = {
1043
1068
  key: 1,
1044
1069
  class: "top-menu__menu-char"
1045
- }, to = { class: "top-menu__menu-text" }, so = { class: "top-menu__menu-content" }, oo = { class: "top-menu__menu-icon" }, ao = {
1070
+ }, uo = { class: "top-menu__menu-text" }, mo = { class: "top-menu__menu-content" }, po = { class: "top-menu__menu-icon" }, vo = {
1046
1071
  key: 1,
1047
1072
  class: "top-menu__menu-char"
1048
- }, no = { class: "top-menu__menu-text" }, lo = { class: "top-menu__menu-content" }, ro = { class: "top-menu__menu-icon" }, io = {
1073
+ }, ho = { class: "top-menu__menu-text" }, _o = { class: "top-menu__menu-content" }, fo = { class: "top-menu__menu-icon" }, go = {
1049
1074
  key: 1,
1050
1075
  class: "top-menu__menu-char"
1051
- }, co = { class: "top-menu__menu-text" }, uo = { class: "top-menu__menu-content" }, mo = {
1076
+ }, yo = { class: "top-menu__menu-text" }, bo = { class: "top-menu__menu-content" }, wo = {
1052
1077
  key: 0,
1053
1078
  class: "top-menu__menu-icon"
1054
- }, po = {
1079
+ }, ko = {
1055
1080
  key: 1,
1056
1081
  class: "top-menu__menu-char"
1057
- }, vo = { class: "top-menu__menu-text" }, ho = { class: "top-menu__actions" }, _o = {
1082
+ }, xo = { class: "top-menu__menu-text" }, Co = { class: "top-menu__actions" }, $o = {
1058
1083
  key: 0,
1059
1084
  class: "top-menu__search-dropdown"
1060
- }, fo = {
1085
+ }, Lo = {
1061
1086
  key: 0,
1062
1087
  class: "top-menu__search-results"
1063
- }, go = ["onClick"], yo = {
1088
+ }, Mo = ["onClick"], So = {
1064
1089
  key: 0,
1065
1090
  class: "top-menu__search-icon-item"
1066
- }, bo = {
1091
+ }, No = {
1067
1092
  key: 1,
1068
1093
  class: "top-menu__search-char"
1069
- }, ko = { class: "top-menu__search-item-title" }, wo = {
1094
+ }, Eo = { class: "top-menu__search-item-title" }, Io = {
1070
1095
  key: 1,
1071
1096
  class: "top-menu__search-item-parent"
1072
- }, xo = {
1097
+ }, Uo = {
1073
1098
  key: 1,
1074
1099
  class: "top-menu__search-empty"
1075
- }, Co = ["title"], $o = { class: "top-menu__avatar" }, Lo = { class: "top-menu__user-name" }, Mo = {
1100
+ }, To = ["title"], Po = { class: "top-menu__avatar" }, zo = { class: "top-menu__user-name" }, Fo = {
1076
1101
  key: 0,
1077
1102
  class: "top-menu__dropdown"
1078
- }, So = { class: "top-menu__dropdown-header" }, No = { class: "top-menu__dropdown-avatar" }, Io = { class: "top-menu__dropdown-info" }, Eo = { class: "top-menu__dropdown-name" }, Uo = { class: "top-menu__dropdown-role" }, zo = { class: "top-menu__dropdown-menu" }, Po = { class: "settings-drawer" }, To = { class: "settings-section" }, Fo = { class: "settings-layout-options" }, Do = ["onClick"], Ao = { class: "layout-option__preview" }, Bo = {
1103
+ }, Do = { class: "top-menu__dropdown-header" }, Ao = { class: "top-menu__dropdown-avatar" }, Bo = { class: "top-menu__dropdown-info" }, Vo = { class: "top-menu__dropdown-name" }, Oo = { class: "top-menu__dropdown-role" }, Ro = { class: "top-menu__dropdown-menu" }, Ko = { class: "settings-drawer" }, jo = { class: "settings-section" }, Wo = { class: "settings-layout-options" }, qo = ["onClick"], Ho = { class: "layout-option__preview" }, Yo = {
1079
1104
  key: 0,
1080
1105
  class: "layout-preview-sidebar"
1081
- }, Vo = {
1106
+ }, Go = {
1082
1107
  key: 1,
1083
1108
  class: "layout-preview-top"
1084
- }, Oo = {
1109
+ }, Xo = {
1085
1110
  key: 2,
1086
1111
  class: "layout-preview-mix"
1087
- }, Ro = { class: "layout-option__label" }, Ko = { class: "settings-section" }, jo = { class: "settings-color-options" }, Wo = ["title", "onClick"], qo = { class: "settings-section" }, Ho = { class: "settings-switch-list" }, Yo = { class: "settings-switch-item" }, Go = { class: "settings-switch-item" }, Xo = /* @__PURE__ */ le({
1112
+ }, Jo = { class: "layout-option__label" }, Zo = { class: "settings-section" }, Qo = { class: "settings-color-options" }, ea = ["title", "onClick"], ta = { class: "settings-section" }, sa = { class: "settings-switch-list" }, oa = { class: "settings-switch-item" }, aa = { class: "settings-switch-item" }, na = /* @__PURE__ */ ie({
1088
1113
  __name: "TopMenu",
1089
1114
  props: {
1090
- logoSrc: { default: Ee("/vite.svg") }
1115
+ logoSrc: {}
1091
1116
  },
1092
1117
  setup(t) {
1093
- const n = t, u = Le(), s = he(), o = ve(), i = pe(), h = re(), v = ze(), d = w(() => u.path), g = (S, C = "") => {
1118
+ const n = t, m = w(() => n.logoSrc || ze("/vite.svg")), o = Ue(), s = be(), h = _e(), i = he(), v = ce(), d = De(), f = w(() => o.path), _ = (N, C = "") => {
1094
1119
  const ae = [];
1095
- return S.forEach((r) => {
1096
- r.children && r.children.length > 0 ? ae.push(...g(r.children, r.menuName)) : ae.push({ ...r, parentTitle: C, title: r.menuName, path: r.menuUrl });
1120
+ return N.forEach((r) => {
1121
+ r.children && r.children.length > 0 ? ae.push(..._(r.children, r.menuName)) : ae.push({ ...r, parentTitle: C, title: r.menuName, path: r.menuUrl });
1097
1122
  }), ae;
1098
- }, _ = w(() => X.value.trim() ? g(o.menuList).filter(
1123
+ }, k = w(() => X.value.trim() ? _(h.menuList).filter(
1099
1124
  (C) => C.title.toLowerCase().includes(X.value.toLowerCase())
1100
- ) : []), f = w(() => i.isDark ? "#1d1e1f" : "#fff"), m = w(() => i.isDark ? "#cfd3dc" : "#303133"), j = w(() => "#409eff"), D = y(!1), W = y(null), A = y(!1), V = y(!1), G = y(!1), ee = y(!1), X = y(""), q = y(null), oe = (S) => {
1101
- S && S !== u.path && s.push(S);
1102
- }, P = /* @__PURE__ */ new Set([
1125
+ ) : []), u = w(() => i.isDark ? "#1d1e1f" : "#fff"), K = w(() => i.isDark ? "#cfd3dc" : "#303133"), A = w(() => "#409eff"), j = g(!1), B = g(null), W = g(!1), V = g(!1), Q = g(!1), ee = g(!1), X = g(""), G = g(null), te = (N) => {
1126
+ N && N !== o.path && s.push(N);
1127
+ }, F = /* @__PURE__ */ new Set([
1103
1128
  "arrow-up",
1104
1129
  "arrow-down",
1105
1130
  "arrow-left",
@@ -1201,10 +1226,10 @@ const ve = Ue("menu", () => {
1201
1226
  "sun",
1202
1227
  "theme",
1203
1228
  "skin"
1204
- ]), I = (S) => {
1205
- if (!S || S === "") return "";
1206
- if (S.startsWith("tineco-icon-")) {
1207
- const ae = S.replace("tineco-icon-", "");
1229
+ ]), E = (N) => {
1230
+ if (!N || N === "") return "";
1231
+ if (N.startsWith("tineco-icon-")) {
1232
+ const ae = N.replace("tineco-icon-", "");
1208
1233
  return {
1209
1234
  home: "home",
1210
1235
  dashboard: "dashboard",
@@ -1237,155 +1262,155 @@ const ve = Ue("menu", () => {
1237
1262
  app: "app",
1238
1263
  list: "list",
1239
1264
  grid: "grid"
1240
- }[S] || S;
1241
- }, F = (S) => S ? S.charAt(0) : "", J = (S) => P.has(S), R = () => {
1265
+ }[N] || N;
1266
+ }, z = (N) => N ? N.charAt(0) : "", Y = (N) => F.has(N), q = () => {
1242
1267
  i.toggleTheme(), V.value = !1;
1243
1268
  }, ne = () => {
1244
1269
  document.fullscreenElement ? document.exitFullscreen() : document.documentElement.requestFullscreen();
1245
- }, ue = () => {
1246
- A.value = !!document.fullscreenElement;
1247
- }, _e = () => {
1248
- D.value = !D.value;
1249
- }, N = () => {
1250
- D.value = !1;
1251
- }, H = () => {
1270
+ }, ve = () => {
1271
+ W.value = !!document.fullscreenElement;
1272
+ }, we = () => {
1273
+ j.value = !j.value;
1274
+ }, le = () => {
1275
+ j.value = !1;
1276
+ }, de = () => {
1252
1277
  ee.value = !1, X.value = "";
1253
- }, de = (S) => {
1254
- s.push(S), H();
1255
- }, te = () => {
1278
+ }, fe = (N) => {
1279
+ s.push(N), de();
1280
+ }, M = () => {
1256
1281
  V.value = !0;
1257
- }, Y = (S) => {
1258
- G.value = S;
1282
+ }, O = (N) => {
1283
+ Q.value = N;
1259
1284
  const C = document.documentElement;
1260
- S ? C.classList.add("grey-mode") : C.classList.remove("grey-mode");
1285
+ N ? C.classList.add("grey-mode") : C.classList.remove("grey-mode");
1261
1286
  }, me = () => {
1262
- Y(!G.value), V.value = !1;
1263
- }, fe = () => {
1287
+ O(!Q.value), V.value = !1;
1288
+ }, pe = () => {
1264
1289
  i.toggleTheme(), V.value = !1;
1265
- }, be = [
1290
+ }, oe = [
1266
1291
  { value: "sidebar", label: "左侧菜单", icon: "sidebar-left" },
1267
1292
  { value: "top", label: "顶部菜单", icon: "menu" },
1268
1293
  { value: "mix", label: "混合菜单", icon: "grid" }
1269
- ], ce = w(() => i.layout), ge = (S) => {
1270
- i.setLayout(S), V.value = !1;
1271
- }, Me = [
1294
+ ], ke = w(() => i.layout), xe = (N) => {
1295
+ i.setLayout(N), V.value = !1;
1296
+ }, $e = [
1272
1297
  { value: "#409eff", label: "默认蓝" },
1273
1298
  { value: "#0F6FDE", label: "企业蓝" },
1274
1299
  { value: "#00A870", label: "翡翠绿" },
1275
1300
  { value: "#D46B08", label: "琥珀橙" },
1276
1301
  { value: "#1F2329", label: "石墨黑" }
1277
- ], ke = (S) => {
1278
- i.setPrimaryColor(S), V.value = !1;
1279
- }, we = () => {
1280
- N(), s.push("/profile");
1281
- }, z = () => {
1282
- N(), s.push("/change-password");
1283
- }, k = () => {
1284
- N(), v.logout(), h.clearUserInfo(), o.clearMenu(), s.push(i.loginPath);
1285
- }, se = (S) => {
1286
- W.value && !W.value.contains(S.target) && N(), q.value && !q.value.contains(S.target) && H();
1287
- }, $ = (S) => {
1288
- S.key === "Escape" && (H(), N());
1302
+ ], re = (N) => {
1303
+ i.setPrimaryColor(N), V.value = !1;
1304
+ }, ge = () => {
1305
+ le(), s.push("/profile");
1306
+ }, U = () => {
1307
+ le(), s.push("/change-password");
1308
+ }, b = () => {
1309
+ le(), d.logout(), v.clearUserInfo(), h.clearMenu(), s.push(i.loginPath);
1310
+ }, se = (N) => {
1311
+ B.value && !B.value.contains(N.target) && le(), G.value && !G.value.contains(N.target) && de();
1312
+ }, $ = (N) => {
1313
+ N.key === "Escape" && (de(), le());
1289
1314
  };
1290
- return je(() => {
1291
- document.addEventListener("click", se), document.addEventListener("fullscreenchange", ue), document.addEventListener("keydown", $), G.value = document.documentElement.classList.contains("grey-mode");
1292
- }), We(() => {
1293
- document.removeEventListener("click", se), document.removeEventListener("fullscreenchange", ue), document.removeEventListener("keydown", $);
1294
- }), (S, C) => {
1315
+ return Ye(() => {
1316
+ document.addEventListener("click", se), document.addEventListener("fullscreenchange", ve), document.addEventListener("keydown", $), Q.value = document.documentElement.classList.contains("grey-mode");
1317
+ }), Ge(() => {
1318
+ document.removeEventListener("click", se), document.removeEventListener("fullscreenchange", ve), document.removeEventListener("keydown", $);
1319
+ }), (N, C) => {
1295
1320
  var ae;
1296
- return a(), c("div", js, [
1297
- e("div", Ws, [
1321
+ return a(), c("div", Qs, [
1322
+ e("div", eo, [
1298
1323
  e("img", {
1299
- src: n.logoSrc,
1324
+ src: m.value,
1300
1325
  alt: "Logo",
1301
1326
  class: "top-menu__logo-img"
1302
- }, null, 8, qs),
1303
- e("span", Hs, x(l(i).appName), 1)
1327
+ }, null, 8, to),
1328
+ e("span", so, x(l(i).appName), 1)
1304
1329
  ]),
1305
- b(l(Xe), {
1306
- "model-value": d.value,
1330
+ y(l(et), {
1331
+ "model-value": f.value,
1307
1332
  mode: "horizontal",
1308
- "background-color": f.value,
1309
- "text-color": m.value,
1310
- "active-text-color": j.value,
1333
+ "background-color": u.value,
1334
+ "text-color": K.value,
1335
+ "active-text-color": A.value,
1311
1336
  class: "top-menu__menu",
1312
- onSelect: oe
1337
+ onSelect: te
1313
1338
  }, {
1314
- default: M(() => [
1315
- (a(!0), c(K, null, Z(l(o).menuList, (r) => (a(), c(K, {
1339
+ default: S(() => [
1340
+ (a(!0), c(H, null, J(l(h).menuList, (r) => (a(), c(H, {
1316
1341
  key: r.menuUrl
1317
1342
  }, [
1318
- r.children && r.children.length > 0 ? (a(), B(l(Ke), {
1343
+ r.children && r.children.length > 0 ? (a(), D(l(He), {
1319
1344
  key: 0,
1320
1345
  index: r.menuUrl
1321
1346
  }, {
1322
- title: M(() => [
1323
- e("span", Ys, [
1324
- r.menuName !== "首页" ? (a(), c("span", Gs, [
1325
- J(I(r.icon)) ? (a(), B(l(U), {
1347
+ title: S(() => [
1348
+ e("span", oo, [
1349
+ r.menuName !== "首页" ? (a(), c("span", ao, [
1350
+ Y(E(r.icon)) ? (a(), D(l(I), {
1326
1351
  key: 0,
1327
- name: I(r.icon),
1352
+ name: E(r.icon),
1328
1353
  size: 16
1329
- }, null, 8, ["name"])) : (a(), c("span", Xs, x(F(r.menuName)), 1))
1330
- ])) : T("", !0),
1331
- e("span", Js, x(r.menuName), 1)
1354
+ }, null, 8, ["name"])) : (a(), c("span", no, x(z(r.menuName)), 1))
1355
+ ])) : P("", !0),
1356
+ e("span", lo, x(r.menuName), 1)
1332
1357
  ])
1333
1358
  ]),
1334
- default: M(() => [
1335
- (a(!0), c(K, null, Z(r.children, (p) => (a(), c(K, {
1359
+ default: S(() => [
1360
+ (a(!0), c(H, null, J(r.children, (p) => (a(), c(H, {
1336
1361
  key: p.menuUrl
1337
1362
  }, [
1338
- p.children && p.children.length > 0 ? (a(), B(l(Ke), {
1363
+ p.children && p.children.length > 0 ? (a(), D(l(He), {
1339
1364
  key: 0,
1340
1365
  index: p.menuUrl
1341
1366
  }, {
1342
- title: M(() => [
1343
- e("span", Zs, [
1344
- e("span", Qs, [
1345
- J(I(p.icon)) ? (a(), B(l(U), {
1367
+ title: S(() => [
1368
+ e("span", ro, [
1369
+ e("span", io, [
1370
+ Y(E(p.icon)) ? (a(), D(l(I), {
1346
1371
  key: 0,
1347
- name: I(p.icon),
1372
+ name: E(p.icon),
1348
1373
  size: 16
1349
- }, null, 8, ["name"])) : (a(), c("span", eo, x(F(p.menuName)), 1))
1374
+ }, null, 8, ["name"])) : (a(), c("span", co, x(z(p.menuName)), 1))
1350
1375
  ]),
1351
- e("span", to, x(p.menuName), 1)
1376
+ e("span", uo, x(p.menuName), 1)
1352
1377
  ])
1353
1378
  ]),
1354
- default: M(() => [
1355
- (a(!0), c(K, null, Z(p.children, (O) => (a(), B(l(Se), {
1356
- key: O.menuUrl,
1357
- index: O.menuUrl
1379
+ default: S(() => [
1380
+ (a(!0), c(H, null, J(p.children, (R) => (a(), D(l(Te), {
1381
+ key: R.menuUrl,
1382
+ index: R.menuUrl
1358
1383
  }, {
1359
- default: M(() => [
1360
- e("span", so, [
1361
- e("span", oo, [
1362
- J(I(O.icon)) ? (a(), B(l(U), {
1384
+ default: S(() => [
1385
+ e("span", mo, [
1386
+ e("span", po, [
1387
+ Y(E(R.icon)) ? (a(), D(l(I), {
1363
1388
  key: 0,
1364
- name: I(O.icon),
1389
+ name: E(R.icon),
1365
1390
  size: 16
1366
- }, null, 8, ["name"])) : (a(), c("span", ao, x(F(O.menuName)), 1))
1391
+ }, null, 8, ["name"])) : (a(), c("span", vo, x(z(R.menuName)), 1))
1367
1392
  ]),
1368
- e("span", no, x(O.menuName), 1)
1393
+ e("span", ho, x(R.menuName), 1)
1369
1394
  ])
1370
1395
  ]),
1371
1396
  _: 2
1372
1397
  }, 1032, ["index"]))), 128))
1373
1398
  ]),
1374
1399
  _: 2
1375
- }, 1032, ["index"])) : (a(), B(l(Se), {
1400
+ }, 1032, ["index"])) : (a(), D(l(Te), {
1376
1401
  key: 1,
1377
1402
  index: p.menuUrl
1378
1403
  }, {
1379
- default: M(() => [
1380
- e("span", lo, [
1381
- e("span", ro, [
1382
- J(I(p.icon)) ? (a(), B(l(U), {
1404
+ default: S(() => [
1405
+ e("span", _o, [
1406
+ e("span", fo, [
1407
+ Y(E(p.icon)) ? (a(), D(l(I), {
1383
1408
  key: 0,
1384
- name: I(p.icon),
1409
+ name: E(p.icon),
1385
1410
  size: 16
1386
- }, null, 8, ["name"])) : (a(), c("span", io, x(F(p.menuName)), 1))
1411
+ }, null, 8, ["name"])) : (a(), c("span", go, x(z(p.menuName)), 1))
1387
1412
  ]),
1388
- e("span", co, x(p.menuName), 1)
1413
+ e("span", yo, x(p.menuName), 1)
1389
1414
  ])
1390
1415
  ]),
1391
1416
  _: 2
@@ -1393,20 +1418,20 @@ const ve = Ue("menu", () => {
1393
1418
  ], 64))), 128))
1394
1419
  ]),
1395
1420
  _: 2
1396
- }, 1032, ["index"])) : (a(), B(l(Se), {
1421
+ }, 1032, ["index"])) : (a(), D(l(Te), {
1397
1422
  key: 1,
1398
1423
  index: r.menuUrl
1399
1424
  }, {
1400
- default: M(() => [
1401
- e("span", uo, [
1402
- r.menuName !== "首页" ? (a(), c("span", mo, [
1403
- J(I(r.icon)) ? (a(), B(l(U), {
1425
+ default: S(() => [
1426
+ e("span", bo, [
1427
+ r.menuName !== "首页" ? (a(), c("span", wo, [
1428
+ Y(E(r.icon)) ? (a(), D(l(I), {
1404
1429
  key: 0,
1405
- name: I(r.icon),
1430
+ name: E(r.icon),
1406
1431
  size: 16
1407
- }, null, 8, ["name"])) : (a(), c("span", po, x(F(r.menuName)), 1))
1408
- ])) : T("", !0),
1409
- e("span", vo, x(r.menuName), 1)
1432
+ }, null, 8, ["name"])) : (a(), c("span", ko, x(z(r.menuName)), 1))
1433
+ ])) : P("", !0),
1434
+ e("span", xo, x(r.menuName), 1)
1410
1435
  ])
1411
1436
  ]),
1412
1437
  _: 2
@@ -1415,47 +1440,47 @@ const ve = Ue("menu", () => {
1415
1440
  ]),
1416
1441
  _: 1
1417
1442
  }, 8, ["model-value", "background-color", "text-color", "active-text-color"]),
1418
- e("div", ho, [
1443
+ e("div", Co, [
1419
1444
  e("div", {
1420
1445
  class: "top-menu__search",
1421
1446
  ref_key: "searchRef",
1422
- ref: q
1447
+ ref: G
1423
1448
  }, [
1424
- b(l(U), {
1449
+ y(l(I), {
1425
1450
  name: "search",
1426
1451
  size: 14,
1427
1452
  class: "top-menu__search-icon"
1428
1453
  }),
1429
- Te(e("input", {
1454
+ Be(e("input", {
1430
1455
  "onUpdate:modelValue": C[0] || (C[0] = (r) => X.value = r),
1431
1456
  type: "text",
1432
1457
  class: "top-menu__search-input",
1433
1458
  placeholder: "搜索菜单...",
1434
1459
  onFocus: C[1] || (C[1] = (r) => ee.value = !0)
1435
1460
  }, null, 544), [
1436
- [qe, X.value]
1461
+ [Xe, X.value]
1437
1462
  ]),
1438
- b(Ce, { name: "search-dropdown" }, {
1439
- default: M(() => [
1440
- ee.value && (_.value.length > 0 || X.value) ? (a(), c("div", _o, [
1441
- _.value.length > 0 ? (a(), c("div", fo, [
1442
- (a(!0), c(K, null, Z(_.value, (r) => (a(), c("div", {
1463
+ y(Ee, { name: "search-dropdown" }, {
1464
+ default: S(() => [
1465
+ ee.value && (k.value.length > 0 || X.value) ? (a(), c("div", $o, [
1466
+ k.value.length > 0 ? (a(), c("div", Lo, [
1467
+ (a(!0), c(H, null, J(k.value, (r) => (a(), c("div", {
1443
1468
  key: r.path,
1444
1469
  class: "top-menu__search-item",
1445
- onClick: (p) => de(r.path)
1470
+ onClick: (p) => fe(r.path)
1446
1471
  }, [
1447
- r.title !== "首页" ? (a(), c("span", yo, [
1448
- J(I(r.icon)) ? (a(), B(l(U), {
1472
+ r.title !== "首页" ? (a(), c("span", So, [
1473
+ Y(E(r.icon)) ? (a(), D(l(I), {
1449
1474
  key: 0,
1450
- name: I(r.icon),
1475
+ name: E(r.icon),
1451
1476
  size: 16
1452
- }, null, 8, ["name"])) : (a(), c("span", bo, x(F(r.title)), 1))
1453
- ])) : T("", !0),
1454
- e("span", ko, x(r.title), 1),
1455
- r.parentTitle ? (a(), c("span", wo, x(r.parentTitle), 1)) : T("", !0)
1456
- ], 8, go))), 128))
1457
- ])) : (a(), c("div", xo, " 未找到匹配的菜单 "))
1458
- ])) : T("", !0)
1477
+ }, null, 8, ["name"])) : (a(), c("span", No, x(z(r.title)), 1))
1478
+ ])) : P("", !0),
1479
+ e("span", Eo, x(r.title), 1),
1480
+ r.parentTitle ? (a(), c("span", Io, x(r.parentTitle), 1)) : P("", !0)
1481
+ ], 8, Mo))), 128))
1482
+ ])) : (a(), c("div", Uo, " 未找到匹配的菜单 "))
1483
+ ])) : P("", !0)
1459
1484
  ]),
1460
1485
  _: 1
1461
1486
  })
@@ -1463,29 +1488,29 @@ const ve = Ue("menu", () => {
1463
1488
  e("div", {
1464
1489
  class: "top-menu__action",
1465
1490
  onClick: ne,
1466
- title: A.value ? "退出全屏" : "全屏"
1491
+ title: W.value ? "退出全屏" : "全屏"
1467
1492
  }, [
1468
- b(l(U), {
1469
- name: A.value ? "fullscreen-exit" : "fullscreen",
1493
+ y(l(I), {
1494
+ name: W.value ? "fullscreen-exit" : "fullscreen",
1470
1495
  size: 16
1471
1496
  }, null, 8, ["name"])
1472
- ], 8, Co),
1497
+ ], 8, To),
1473
1498
  e("div", {
1474
1499
  class: "top-menu__action",
1475
- onClick: te,
1500
+ onClick: M,
1476
1501
  title: "换肤设置"
1477
1502
  }, [
1478
- b(l(U), {
1503
+ y(l(I), {
1479
1504
  name: "skin",
1480
1505
  size: 16
1481
1506
  })
1482
1507
  ]),
1483
1508
  e("div", {
1484
1509
  class: "top-menu__action",
1485
- onClick: R,
1510
+ onClick: q,
1486
1511
  title: "切换主题"
1487
1512
  }, [
1488
- b(l(U), {
1513
+ y(l(I), {
1489
1514
  name: l(i).isDark ? "sun" : "moon",
1490
1515
  size: 16
1491
1516
  }, null, 8, ["name"])
@@ -1493,18 +1518,18 @@ const ve = Ue("menu", () => {
1493
1518
  e("div", {
1494
1519
  class: "top-menu__user",
1495
1520
  ref_key: "dropdownRef",
1496
- ref: W
1521
+ ref: B
1497
1522
  }, [
1498
1523
  e("div", {
1499
1524
  class: "top-menu__user-trigger",
1500
- onClick: Fe(_e, ["stop"])
1525
+ onClick: Ve(we, ["stop"])
1501
1526
  }, [
1502
- e("div", $o, [
1503
- e("span", null, x(((ae = l(h).userName) == null ? void 0 : ae.charAt(0)) || "U"), 1)
1527
+ e("div", Po, [
1528
+ e("span", null, x(((ae = l(v).userName) == null ? void 0 : ae.charAt(0)) || "U"), 1)
1504
1529
  ]),
1505
- e("span", Lo, x(l(h).userName), 1),
1530
+ e("span", zo, x(l(v).userName), 1),
1506
1531
  e("span", {
1507
- class: Q(["top-menu__user-arrow", { "is-active": D.value }])
1532
+ class: Z(["top-menu__user-arrow", { "is-active": j.value }])
1508
1533
  }, [...C[3] || (C[3] = [
1509
1534
  e("svg", {
1510
1535
  viewBox: "0 0 12 12",
@@ -1520,27 +1545,27 @@ const ve = Ue("menu", () => {
1520
1545
  ], -1)
1521
1546
  ])], 2)
1522
1547
  ]),
1523
- b(Ce, { name: "dropdown" }, {
1524
- default: M(() => {
1548
+ y(Ee, { name: "dropdown" }, {
1549
+ default: S(() => {
1525
1550
  var r;
1526
1551
  return [
1527
- D.value ? (a(), c("div", Mo, [
1528
- e("div", So, [
1529
- e("div", No, [
1530
- e("span", null, x(((r = l(h).userName) == null ? void 0 : r.charAt(0)) || "U"), 1)
1552
+ j.value ? (a(), c("div", Fo, [
1553
+ e("div", Do, [
1554
+ e("div", Ao, [
1555
+ e("span", null, x(((r = l(v).userName) == null ? void 0 : r.charAt(0)) || "U"), 1)
1531
1556
  ]),
1532
- e("div", Io, [
1533
- e("div", Eo, x(l(h).userName), 1),
1534
- e("div", Uo, x(l(h).departmentName), 1)
1557
+ e("div", Bo, [
1558
+ e("div", Vo, x(l(v).userName), 1),
1559
+ e("div", Oo, x(l(v).departmentName), 1)
1535
1560
  ])
1536
1561
  ]),
1537
1562
  C[8] || (C[8] = e("div", { class: "top-menu__dropdown-divider" }, null, -1)),
1538
- e("div", zo, [
1563
+ e("div", Ro, [
1539
1564
  e("div", {
1540
1565
  class: "top-menu__dropdown-item",
1541
- onClick: we
1566
+ onClick: ge
1542
1567
  }, [
1543
- b(l(U), {
1568
+ y(l(I), {
1544
1569
  name: "user",
1545
1570
  size: 16
1546
1571
  }),
@@ -1548,9 +1573,9 @@ const ve = Ue("menu", () => {
1548
1573
  ]),
1549
1574
  e("div", {
1550
1575
  class: "top-menu__dropdown-item",
1551
- onClick: z
1576
+ onClick: U
1552
1577
  }, [
1553
- b(l(U), {
1578
+ y(l(I), {
1554
1579
  name: "lock",
1555
1580
  size: 16
1556
1581
  }),
@@ -1559,50 +1584,50 @@ const ve = Ue("menu", () => {
1559
1584
  C[7] || (C[7] = e("div", { class: "top-menu__dropdown-divider" }, null, -1)),
1560
1585
  e("div", {
1561
1586
  class: "top-menu__dropdown-item top-menu__dropdown-item--danger",
1562
- onClick: k
1587
+ onClick: b
1563
1588
  }, [
1564
- b(l(U), {
1589
+ y(l(I), {
1565
1590
  name: "logout",
1566
1591
  size: 16
1567
1592
  }),
1568
1593
  C[6] || (C[6] = e("span", null, "退出登录", -1))
1569
1594
  ])
1570
1595
  ])
1571
- ])) : T("", !0)
1596
+ ])) : P("", !0)
1572
1597
  ];
1573
1598
  }),
1574
1599
  _: 1
1575
1600
  })
1576
1601
  ], 512)
1577
1602
  ]),
1578
- b(l(Je), {
1603
+ y(l(tt), {
1579
1604
  modelValue: V.value,
1580
1605
  "onUpdate:modelValue": C[2] || (C[2] = (r) => V.value = r),
1581
1606
  title: "换肤设置",
1582
1607
  direction: "rtl",
1583
1608
  size: "320px"
1584
1609
  }, {
1585
- default: M(() => [
1586
- e("div", Po, [
1587
- e("div", To, [
1610
+ default: S(() => [
1611
+ e("div", Ko, [
1612
+ e("div", jo, [
1588
1613
  C[12] || (C[12] = e("div", { class: "settings-title" }, "布局模式", -1)),
1589
- e("div", Fo, [
1590
- (a(), c(K, null, Z(be, (r) => e("div", {
1614
+ e("div", Wo, [
1615
+ (a(), c(H, null, J(oe, (r) => e("div", {
1591
1616
  key: r.value,
1592
- class: Q(["layout-option", { "is-active": ce.value === r.value }]),
1593
- onClick: (p) => ge(r.value)
1617
+ class: Z(["layout-option", { "is-active": ke.value === r.value }]),
1618
+ onClick: (p) => xe(r.value)
1594
1619
  }, [
1595
- e("div", Ao, [
1596
- r.value === "sidebar" ? (a(), c("div", Bo, [...C[9] || (C[9] = [
1620
+ e("div", Ho, [
1621
+ r.value === "sidebar" ? (a(), c("div", Yo, [...C[9] || (C[9] = [
1597
1622
  e("div", { class: "preview-aside" }, null, -1),
1598
1623
  e("div", { class: "preview-main" }, [
1599
1624
  e("div", { class: "preview-header" }),
1600
1625
  e("div", { class: "preview-content" })
1601
1626
  ], -1)
1602
- ])])) : r.value === "top" ? (a(), c("div", Vo, [...C[10] || (C[10] = [
1627
+ ])])) : r.value === "top" ? (a(), c("div", Go, [...C[10] || (C[10] = [
1603
1628
  e("div", { class: "preview-header-full" }, null, -1),
1604
1629
  e("div", { class: "preview-content-full" }, null, -1)
1605
- ])])) : (a(), c("div", Oo, [...C[11] || (C[11] = [
1630
+ ])])) : (a(), c("div", Xo, [...C[11] || (C[11] = [
1606
1631
  e("div", { class: "preview-header-mix" }, [
1607
1632
  e("div", { class: "preview-mix-left" })
1608
1633
  ], -1),
@@ -1612,46 +1637,46 @@ const ve = Ue("menu", () => {
1612
1637
  ], -1)
1613
1638
  ])]))
1614
1639
  ]),
1615
- e("span", Ro, x(r.label), 1)
1616
- ], 10, Do)), 64))
1640
+ e("span", Jo, x(r.label), 1)
1641
+ ], 10, qo)), 64))
1617
1642
  ])
1618
1643
  ]),
1619
- e("div", Ko, [
1644
+ e("div", Zo, [
1620
1645
  C[13] || (C[13] = e("div", { class: "settings-title" }, "主题色", -1)),
1621
- e("div", jo, [
1622
- (a(), c(K, null, Z(Me, (r) => e("div", {
1646
+ e("div", Qo, [
1647
+ (a(), c(H, null, J($e, (r) => e("div", {
1623
1648
  key: r.value,
1624
- class: Q(["color-option", { "is-active": l(i).primaryColor === r.value }]),
1625
- style: Ne({ backgroundColor: r.value }),
1649
+ class: Z(["color-option", { "is-active": l(i).primaryColor === r.value }]),
1650
+ style: Pe({ backgroundColor: r.value }),
1626
1651
  title: r.label,
1627
- onClick: (p) => ke(r.value)
1652
+ onClick: (p) => re(r.value)
1628
1653
  }, [
1629
- l(i).primaryColor === r.value ? (a(), B(l(U), {
1654
+ l(i).primaryColor === r.value ? (a(), D(l(I), {
1630
1655
  key: 0,
1631
1656
  name: "check",
1632
1657
  size: 12,
1633
1658
  color: "#fff"
1634
- })) : T("", !0)
1635
- ], 14, Wo)), 64))
1659
+ })) : P("", !0)
1660
+ ], 14, ea)), 64))
1636
1661
  ])
1637
1662
  ]),
1638
- e("div", qo, [
1663
+ e("div", ta, [
1639
1664
  C[18] || (C[18] = e("div", { class: "settings-title" }, "功能设置", -1)),
1640
- e("div", Ho, [
1641
- e("div", Yo, [
1665
+ e("div", sa, [
1666
+ e("div", oa, [
1642
1667
  C[15] || (C[15] = e("span", null, "灰色模式", -1)),
1643
1668
  e("div", {
1644
- class: Q(["switch-wrapper", { "is-checked": G.value }]),
1669
+ class: Z(["switch-wrapper", { "is-checked": Q.value }]),
1645
1670
  onClick: me
1646
1671
  }, [...C[14] || (C[14] = [
1647
1672
  e("span", { class: "switch-core" }, null, -1)
1648
1673
  ])], 2)
1649
1674
  ]),
1650
- e("div", Go, [
1675
+ e("div", aa, [
1651
1676
  C[17] || (C[17] = e("span", null, "暗黑模式", -1)),
1652
1677
  e("div", {
1653
- class: Q(["switch-wrapper", { "is-checked": l(i).isDark }]),
1654
- onClick: fe
1678
+ class: Z(["switch-wrapper", { "is-checked": l(i).isDark }]),
1679
+ onClick: pe
1655
1680
  }, [...C[16] || (C[16] = [
1656
1681
  e("span", { class: "switch-core" }, null, -1)
1657
1682
  ])], 2)
@@ -1665,76 +1690,76 @@ const ve = Ue("menu", () => {
1665
1690
  ]);
1666
1691
  };
1667
1692
  }
1668
- }), Jo = /* @__PURE__ */ ie(Xo, [["__scopeId", "data-v-b402e7ec"]]), Zo = { class: "mix-top-menu" }, Qo = { class: "mix-top-menu__logo" }, ea = ["src"], ta = { class: "mix-top-menu__logo-text" }, sa = { class: "mix-top-menu__menu-content" }, oa = {
1693
+ }), la = /* @__PURE__ */ ue(na, [["__scopeId", "data-v-711d5b8d"]]), ra = { class: "mix-top-menu" }, ia = { class: "mix-top-menu__logo" }, ca = ["src"], ua = { class: "mix-top-menu__logo-text" }, da = { class: "mix-top-menu__menu-content" }, ma = {
1669
1694
  key: 0,
1670
1695
  class: "mix-top-menu__menu-icon"
1671
- }, aa = {
1696
+ }, pa = {
1672
1697
  key: 1,
1673
1698
  class: "mix-top-menu__menu-char"
1674
- }, na = { class: "mix-top-menu__menu-text" }, la = { class: "mix-top-menu__actions" }, ra = {
1699
+ }, va = { class: "mix-top-menu__menu-text" }, ha = { class: "mix-top-menu__actions" }, _a = {
1675
1700
  key: 0,
1676
1701
  class: "mix-top-menu__search-dropdown"
1677
- }, ia = {
1702
+ }, fa = {
1678
1703
  key: 0,
1679
1704
  class: "mix-top-menu__search-results"
1680
- }, ca = ["onClick"], ua = {
1705
+ }, ga = ["onClick"], ya = {
1681
1706
  key: 0,
1682
1707
  class: "mix-top-menu__search-icon-item"
1683
- }, da = {
1708
+ }, ba = {
1684
1709
  key: 1,
1685
1710
  class: "mix-top-menu__search-char"
1686
- }, ma = { class: "mix-top-menu__search-item-title" }, pa = {
1711
+ }, wa = { class: "mix-top-menu__search-item-title" }, ka = {
1687
1712
  key: 1,
1688
1713
  class: "mix-top-menu__search-item-parent"
1689
- }, va = {
1714
+ }, xa = {
1690
1715
  key: 1,
1691
1716
  class: "mix-top-menu__search-empty"
1692
- }, ha = ["title"], _a = { class: "mix-top-menu__avatar" }, fa = { class: "mix-top-menu__user-name" }, ga = {
1717
+ }, Ca = ["title"], $a = { class: "mix-top-menu__avatar" }, La = { class: "mix-top-menu__user-name" }, Ma = {
1693
1718
  key: 0,
1694
1719
  class: "mix-top-menu__dropdown"
1695
- }, ya = { class: "mix-top-menu__dropdown-header" }, ba = { class: "mix-top-menu__dropdown-avatar" }, ka = { class: "mix-top-menu__dropdown-info" }, wa = { class: "mix-top-menu__dropdown-name" }, xa = { class: "mix-top-menu__dropdown-role" }, Ca = { class: "mix-top-menu__dropdown-menu" }, $a = { class: "settings-drawer" }, La = { class: "settings-section" }, Ma = { class: "settings-layout-options" }, Sa = ["onClick"], Na = { class: "layout-option__preview" }, Ia = {
1720
+ }, Sa = { class: "mix-top-menu__dropdown-header" }, Na = { class: "mix-top-menu__dropdown-avatar" }, Ea = { class: "mix-top-menu__dropdown-info" }, Ia = { class: "mix-top-menu__dropdown-name" }, Ua = { class: "mix-top-menu__dropdown-role" }, Ta = { class: "mix-top-menu__dropdown-menu" }, Pa = { class: "settings-drawer" }, za = { class: "settings-section" }, Fa = { class: "settings-layout-options" }, Da = ["onClick"], Aa = { class: "layout-option__preview" }, Ba = {
1696
1721
  key: 0,
1697
1722
  class: "layout-preview-sidebar"
1698
- }, Ea = {
1723
+ }, Va = {
1699
1724
  key: 1,
1700
1725
  class: "layout-preview-top"
1701
- }, Ua = {
1726
+ }, Oa = {
1702
1727
  key: 2,
1703
1728
  class: "layout-preview-mix"
1704
- }, za = { class: "layout-option__label" }, Pa = { class: "settings-section" }, Ta = { class: "settings-color-options" }, Fa = ["title", "onClick"], Da = { class: "settings-section" }, Aa = { class: "settings-switch-list" }, Ba = { class: "settings-switch-item" }, Va = { class: "settings-switch-item" }, Oa = /* @__PURE__ */ le({
1729
+ }, Ra = { class: "layout-option__label" }, Ka = { class: "settings-section" }, ja = { class: "settings-color-options" }, Wa = ["title", "onClick"], qa = { class: "settings-section" }, Ha = { class: "settings-switch-list" }, Ya = { class: "settings-switch-item" }, Ga = { class: "settings-switch-item" }, Xa = /* @__PURE__ */ ie({
1705
1730
  __name: "MixTopMenu",
1706
1731
  props: {
1707
- logoSrc: { default: Ee("/vite.svg") }
1732
+ logoSrc: {}
1708
1733
  },
1709
1734
  setup(t) {
1710
- const n = t, u = Le(), s = he(), o = ve(), i = pe(), h = re(), v = ze(), d = y(""), g = (r, p = "") => {
1711
- const O = [];
1735
+ const n = t, m = w(() => n.logoSrc || ze("/vite.svg")), o = Ue(), s = be(), h = _e(), i = he(), v = ce(), d = De(), f = g(""), _ = (r, p = "") => {
1736
+ const R = [];
1712
1737
  return r.forEach((L) => {
1713
- L.children && L.children.length > 0 ? O.push(...g(L.children, L.menuName)) : O.push({ ...L, parentTitle: p, title: L.menuName, path: L.menuUrl });
1714
- }), O;
1715
- }, _ = w(() => I.value.trim() ? g(o.menuList).filter(
1716
- (p) => p.title.toLowerCase().includes(I.value.toLowerCase())
1717
- ) : []), f = w(() => {
1718
- const r = o.menuList.find((p) => p.menuUrl === d.value);
1738
+ L.children && L.children.length > 0 ? R.push(..._(L.children, L.menuName)) : R.push({ ...L, parentTitle: p, title: L.menuName, path: L.menuUrl });
1739
+ }), R;
1740
+ }, k = w(() => E.value.trim() ? _(h.menuList).filter(
1741
+ (p) => p.title.toLowerCase().includes(E.value.toLowerCase())
1742
+ ) : []), u = w(() => {
1743
+ const r = h.menuList.find((p) => p.menuUrl === f.value);
1719
1744
  return (r == null ? void 0 : r.children) || [];
1720
- }), m = w(() => o.menuList.find((r) => !!(u.path === r.menuUrl || r.children && r.children.some((p) => u.path.startsWith(p.menuUrl) || u.path === p.menuUrl)))), j = () => {
1721
- m.value ? d.value = m.value.menuUrl : o.menuList.length > 0 && (d.value = o.menuList[0].menuUrl);
1722
- }, D = (r) => {
1723
- d.value = r;
1724
- const p = o.menuList.find((O) => O.menuUrl === r);
1745
+ }), K = w(() => h.menuList.find((r) => !!(o.path === r.menuUrl || r.children && r.children.some((p) => o.path.startsWith(p.menuUrl) || o.path === p.menuUrl)))), A = () => {
1746
+ K.value ? f.value = K.value.menuUrl : h.menuList.length > 0 && (f.value = h.menuList[0].menuUrl);
1747
+ }, j = (r) => {
1748
+ f.value = r;
1749
+ const p = h.menuList.find((R) => R.menuUrl === r);
1725
1750
  if (p)
1726
1751
  if (p.children && p.children.length > 0) {
1727
- const O = p.children[0].menuUrl;
1728
- u.path !== O && s.push(O);
1752
+ const R = p.children[0].menuUrl;
1753
+ o.path !== R && s.push(R);
1729
1754
  } else
1730
- u.path !== r && s.push(r);
1731
- }, W = w(() => i.isDark ? "#1d1e1f" : "#fff"), A = w(() => i.isDark ? "#cfd3dc" : "#303133"), V = w(() => "#409eff"), G = y(!1), ee = y(null), X = y(!1), q = y(!1), oe = y(!1), P = y(!1), I = y(""), F = y(null);
1732
- xe(() => u.path, () => {
1733
- j(), i.setMixSubMenus(f.value);
1734
- }), xe(() => o.menuList, (r) => {
1735
- r && r.length > 0 && (j(), i.setMixSubMenus(f.value));
1755
+ o.path !== r && s.push(r);
1756
+ }, B = w(() => i.isDark ? "#1d1e1f" : "#fff"), W = w(() => i.isDark ? "#cfd3dc" : "#303133"), V = w(() => "#409eff"), Q = g(!1), ee = g(null), X = g(!1), G = g(!1), te = g(!1), F = g(!1), E = g(""), z = g(null);
1757
+ Se(() => o.path, () => {
1758
+ A(), i.setMixSubMenus(u.value);
1759
+ }), Se(() => h.menuList, (r) => {
1760
+ r && r.length > 0 && (A(), i.setMixSubMenus(u.value));
1736
1761
  }, { immediate: !0 });
1737
- const J = /* @__PURE__ */ new Set([
1762
+ const Y = /* @__PURE__ */ new Set([
1738
1763
  "arrow-up",
1739
1764
  "arrow-down",
1740
1765
  "arrow-left",
@@ -1836,10 +1861,10 @@ const ve = Ue("menu", () => {
1836
1861
  "sun",
1837
1862
  "theme",
1838
1863
  "skin"
1839
- ]), R = (r) => {
1864
+ ]), q = (r) => {
1840
1865
  if (!r || r === "") return "";
1841
1866
  if (r.startsWith("tineco-icon-")) {
1842
- const O = r.replace("tineco-icon-", "");
1867
+ const R = r.replace("tineco-icon-", "");
1843
1868
  return {
1844
1869
  home: "home",
1845
1870
  dashboard: "dashboard",
@@ -1853,7 +1878,7 @@ const ve = Ue("menu", () => {
1853
1878
  chart: "chart",
1854
1879
  report: "report",
1855
1880
  analytics: "analytics"
1856
- }[O] || O;
1881
+ }[R] || R;
1857
1882
  }
1858
1883
  return {
1859
1884
  dashboard: "dashboard",
@@ -1873,94 +1898,94 @@ const ve = Ue("menu", () => {
1873
1898
  list: "list",
1874
1899
  grid: "grid"
1875
1900
  }[r] || r;
1876
- }, ne = (r) => r ? r.charAt(0) : "", ue = (r) => J.has(r), _e = () => {
1877
- i.toggleTheme(), q.value = !1;
1878
- }, N = () => {
1901
+ }, ne = (r) => r ? r.charAt(0) : "", ve = (r) => Y.has(r), we = () => {
1902
+ i.toggleTheme(), G.value = !1;
1903
+ }, le = () => {
1879
1904
  document.fullscreenElement ? document.exitFullscreen() : document.documentElement.requestFullscreen();
1880
- }, H = () => {
1881
- X.value = !!document.fullscreenElement;
1882
1905
  }, de = () => {
1883
- G.value = !G.value;
1884
- }, te = () => {
1885
- G.value = !1;
1886
- }, Y = () => {
1887
- P.value = !1, I.value = "";
1888
- }, me = (r) => {
1889
- s.push(r), Y();
1906
+ X.value = !!document.fullscreenElement;
1890
1907
  }, fe = () => {
1891
- q.value = !0;
1892
- }, be = (r) => {
1893
- oe.value = r;
1908
+ Q.value = !Q.value;
1909
+ }, M = () => {
1910
+ Q.value = !1;
1911
+ }, O = () => {
1912
+ F.value = !1, E.value = "";
1913
+ }, me = (r) => {
1914
+ s.push(r), O();
1915
+ }, pe = () => {
1916
+ G.value = !0;
1917
+ }, oe = (r) => {
1918
+ te.value = r;
1894
1919
  const p = document.documentElement;
1895
1920
  r ? p.classList.add("grey-mode") : p.classList.remove("grey-mode");
1896
- }, ce = () => {
1897
- be(!oe.value), q.value = !1;
1898
- }, ge = () => {
1899
- i.toggleTheme(), q.value = !1;
1900
- }, Me = [
1921
+ }, ke = () => {
1922
+ oe(!te.value), G.value = !1;
1923
+ }, xe = () => {
1924
+ i.toggleTheme(), G.value = !1;
1925
+ }, $e = [
1901
1926
  { value: "sidebar", label: "左侧菜单", icon: "sidebar-left" },
1902
1927
  { value: "top", label: "顶部菜单", icon: "menu" },
1903
1928
  { value: "mix", label: "混合菜单", icon: "grid" }
1904
- ], ke = w(() => i.layout), we = (r) => {
1905
- i.setLayout(r), q.value = !1;
1906
- }, z = [
1929
+ ], re = w(() => i.layout), ge = (r) => {
1930
+ i.setLayout(r), G.value = !1;
1931
+ }, U = [
1907
1932
  { value: "#409eff", label: "默认蓝" },
1908
1933
  { value: "#0F6FDE", label: "企业蓝" },
1909
1934
  { value: "#00A870", label: "翡翠绿" },
1910
1935
  { value: "#D46B08", label: "琥珀橙" },
1911
1936
  { value: "#1F2329", label: "石墨黑" }
1912
- ], k = (r) => {
1913
- i.setPrimaryColor(r), q.value = !1;
1937
+ ], b = (r) => {
1938
+ i.setPrimaryColor(r), G.value = !1;
1914
1939
  }, se = () => {
1915
- te(), s.push("/profile");
1940
+ M(), s.push("/profile");
1916
1941
  }, $ = () => {
1917
- te(), s.push("/change-password");
1918
- }, S = () => {
1919
- te(), v.logout(), h.clearUserInfo(), o.clearMenu(), s.push(i.loginPath);
1942
+ M(), s.push("/change-password");
1943
+ }, N = () => {
1944
+ M(), d.logout(), v.clearUserInfo(), h.clearMenu(), s.push(i.loginPath);
1920
1945
  }, C = (r) => {
1921
- ee.value && !ee.value.contains(r.target) && te(), F.value && !F.value.contains(r.target) && Y();
1946
+ ee.value && !ee.value.contains(r.target) && M(), z.value && !z.value.contains(r.target) && O();
1922
1947
  }, ae = (r) => {
1923
- r.key === "Escape" && (Y(), te());
1948
+ r.key === "Escape" && (O(), M());
1924
1949
  };
1925
- return je(() => {
1926
- document.addEventListener("click", C), document.addEventListener("fullscreenchange", H), document.addEventListener("keydown", ae), oe.value = document.documentElement.classList.contains("grey-mode"), j();
1927
- }), We(() => {
1928
- document.removeEventListener("click", C), document.removeEventListener("fullscreenchange", H), document.removeEventListener("keydown", ae);
1950
+ return Ye(() => {
1951
+ document.addEventListener("click", C), document.addEventListener("fullscreenchange", de), document.addEventListener("keydown", ae), te.value = document.documentElement.classList.contains("grey-mode"), A();
1952
+ }), Ge(() => {
1953
+ document.removeEventListener("click", C), document.removeEventListener("fullscreenchange", de), document.removeEventListener("keydown", ae);
1929
1954
  }), (r, p) => {
1930
- var O;
1931
- return a(), c("div", Zo, [
1932
- e("div", Qo, [
1955
+ var R;
1956
+ return a(), c("div", ra, [
1957
+ e("div", ia, [
1933
1958
  e("img", {
1934
- src: n.logoSrc,
1959
+ src: m.value,
1935
1960
  alt: "Logo",
1936
1961
  class: "mix-top-menu__logo-img"
1937
- }, null, 8, ea),
1938
- e("span", ta, x(l(i).appName), 1)
1962
+ }, null, 8, ca),
1963
+ e("span", ua, x(l(i).appName), 1)
1939
1964
  ]),
1940
- b(l(Xe), {
1941
- "model-value": d.value,
1965
+ y(l(et), {
1966
+ "model-value": f.value,
1942
1967
  mode: "horizontal",
1943
- "background-color": W.value,
1944
- "text-color": A.value,
1968
+ "background-color": B.value,
1969
+ "text-color": W.value,
1945
1970
  "active-text-color": V.value,
1946
1971
  class: "mix-top-menu__menu",
1947
- onSelect: D
1972
+ onSelect: j
1948
1973
  }, {
1949
- default: M(() => [
1950
- (a(!0), c(K, null, Z(l(o).menuList, (L) => (a(), B(l(Se), {
1974
+ default: S(() => [
1975
+ (a(!0), c(H, null, J(l(h).menuList, (L) => (a(), D(l(Te), {
1951
1976
  key: L.menuUrl,
1952
1977
  index: L.menuUrl
1953
1978
  }, {
1954
- default: M(() => [
1955
- e("span", sa, [
1956
- L.menuName !== "首页" ? (a(), c("span", oa, [
1957
- ue(R(L.icon)) ? (a(), B(l(U), {
1979
+ default: S(() => [
1980
+ e("span", da, [
1981
+ L.menuName !== "首页" ? (a(), c("span", ma, [
1982
+ ve(q(L.icon)) ? (a(), D(l(I), {
1958
1983
  key: 0,
1959
- name: R(L.icon),
1984
+ name: q(L.icon),
1960
1985
  size: 16
1961
- }, null, 8, ["name"])) : (a(), c("span", aa, x(ne(L.menuName)), 1))
1962
- ])) : T("", !0),
1963
- e("span", na, x(L.menuName), 1)
1986
+ }, null, 8, ["name"])) : (a(), c("span", pa, x(ne(L.menuName)), 1))
1987
+ ])) : P("", !0),
1988
+ e("span", va, x(L.menuName), 1)
1964
1989
  ])
1965
1990
  ]),
1966
1991
  _: 2
@@ -1968,77 +1993,77 @@ const ve = Ue("menu", () => {
1968
1993
  ]),
1969
1994
  _: 1
1970
1995
  }, 8, ["model-value", "background-color", "text-color", "active-text-color"]),
1971
- e("div", la, [
1996
+ e("div", ha, [
1972
1997
  e("div", {
1973
1998
  class: "mix-top-menu__search",
1974
1999
  ref_key: "searchRef",
1975
- ref: F
2000
+ ref: z
1976
2001
  }, [
1977
- b(l(U), {
2002
+ y(l(I), {
1978
2003
  name: "search",
1979
2004
  size: 14,
1980
2005
  class: "mix-top-menu__search-icon"
1981
2006
  }),
1982
- Te(e("input", {
1983
- "onUpdate:modelValue": p[0] || (p[0] = (L) => I.value = L),
2007
+ Be(e("input", {
2008
+ "onUpdate:modelValue": p[0] || (p[0] = (L) => E.value = L),
1984
2009
  type: "text",
1985
2010
  class: "mix-top-menu__search-input",
1986
2011
  placeholder: "搜索菜单...",
1987
- onFocus: p[1] || (p[1] = (L) => P.value = !0)
2012
+ onFocus: p[1] || (p[1] = (L) => F.value = !0)
1988
2013
  }, null, 544), [
1989
- [qe, I.value]
2014
+ [Xe, E.value]
1990
2015
  ]),
1991
- b(Ce, { name: "search-dropdown" }, {
1992
- default: M(() => [
1993
- P.value && (_.value.length > 0 || I.value) ? (a(), c("div", ra, [
1994
- _.value.length > 0 ? (a(), c("div", ia, [
1995
- (a(!0), c(K, null, Z(_.value, (L) => (a(), c("div", {
2016
+ y(Ee, { name: "search-dropdown" }, {
2017
+ default: S(() => [
2018
+ F.value && (k.value.length > 0 || E.value) ? (a(), c("div", _a, [
2019
+ k.value.length > 0 ? (a(), c("div", fa, [
2020
+ (a(!0), c(H, null, J(k.value, (L) => (a(), c("div", {
1996
2021
  key: L.path,
1997
2022
  class: "mix-top-menu__search-item",
1998
- onClick: (Qe) => me(L.path)
2023
+ onClick: (ot) => me(L.path)
1999
2024
  }, [
2000
- L.title !== "首页" ? (a(), c("span", ua, [
2001
- ue(R(L.icon)) ? (a(), B(l(U), {
2025
+ L.title !== "首页" ? (a(), c("span", ya, [
2026
+ ve(q(L.icon)) ? (a(), D(l(I), {
2002
2027
  key: 0,
2003
- name: R(L.icon),
2028
+ name: q(L.icon),
2004
2029
  size: 16
2005
- }, null, 8, ["name"])) : (a(), c("span", da, x(ne(L.title)), 1))
2006
- ])) : T("", !0),
2007
- e("span", ma, x(L.title), 1),
2008
- L.parentTitle ? (a(), c("span", pa, x(L.parentTitle), 1)) : T("", !0)
2009
- ], 8, ca))), 128))
2010
- ])) : (a(), c("div", va, " 未找到匹配的菜单 "))
2011
- ])) : T("", !0)
2030
+ }, null, 8, ["name"])) : (a(), c("span", ba, x(ne(L.title)), 1))
2031
+ ])) : P("", !0),
2032
+ e("span", wa, x(L.title), 1),
2033
+ L.parentTitle ? (a(), c("span", ka, x(L.parentTitle), 1)) : P("", !0)
2034
+ ], 8, ga))), 128))
2035
+ ])) : (a(), c("div", xa, " 未找到匹配的菜单 "))
2036
+ ])) : P("", !0)
2012
2037
  ]),
2013
2038
  _: 1
2014
2039
  })
2015
2040
  ], 512),
2016
2041
  e("div", {
2017
2042
  class: "mix-top-menu__action",
2018
- onClick: N,
2043
+ onClick: le,
2019
2044
  title: X.value ? "退出全屏" : "全屏"
2020
2045
  }, [
2021
- b(l(U), {
2046
+ y(l(I), {
2022
2047
  name: X.value ? "fullscreen-exit" : "fullscreen",
2023
2048
  size: 16
2024
2049
  }, null, 8, ["name"])
2025
- ], 8, ha),
2050
+ ], 8, Ca),
2026
2051
  e("div", {
2027
2052
  class: "mix-top-menu__action",
2028
- onClick: fe,
2053
+ onClick: pe,
2029
2054
  title: "换肤设置"
2030
2055
  }, [
2031
- b(l(U), {
2056
+ y(l(I), {
2032
2057
  name: "skin",
2033
2058
  size: 16
2034
2059
  })
2035
2060
  ]),
2036
2061
  e("div", {
2037
2062
  class: "mix-top-menu__action",
2038
- onClick: _e,
2063
+ onClick: we,
2039
2064
  title: "切换主题"
2040
2065
  }, [
2041
- b(l(U), {
2066
+ y(l(I), {
2042
2067
  name: l(i).isDark ? "sun" : "moon",
2043
2068
  size: 16
2044
2069
  }, null, 8, ["name"])
@@ -2050,14 +2075,14 @@ const ve = Ue("menu", () => {
2050
2075
  }, [
2051
2076
  e("div", {
2052
2077
  class: "mix-top-menu__user-trigger",
2053
- onClick: Fe(de, ["stop"])
2078
+ onClick: Ve(fe, ["stop"])
2054
2079
  }, [
2055
- e("div", _a, [
2056
- e("span", null, x(((O = l(h).userName) == null ? void 0 : O.charAt(0)) || "U"), 1)
2080
+ e("div", $a, [
2081
+ e("span", null, x(((R = l(v).userName) == null ? void 0 : R.charAt(0)) || "U"), 1)
2057
2082
  ]),
2058
- e("span", fa, x(l(h).userName), 1),
2083
+ e("span", La, x(l(v).userName), 1),
2059
2084
  e("span", {
2060
- class: Q(["mix-top-menu__user-arrow", { "is-active": G.value }])
2085
+ class: Z(["mix-top-menu__user-arrow", { "is-active": Q.value }])
2061
2086
  }, [...p[3] || (p[3] = [
2062
2087
  e("svg", {
2063
2088
  viewBox: "0 0 12 12",
@@ -2073,27 +2098,27 @@ const ve = Ue("menu", () => {
2073
2098
  ], -1)
2074
2099
  ])], 2)
2075
2100
  ]),
2076
- b(Ce, { name: "dropdown" }, {
2077
- default: M(() => {
2101
+ y(Ee, { name: "dropdown" }, {
2102
+ default: S(() => {
2078
2103
  var L;
2079
2104
  return [
2080
- G.value ? (a(), c("div", ga, [
2081
- e("div", ya, [
2082
- e("div", ba, [
2083
- e("span", null, x(((L = l(h).userName) == null ? void 0 : L.charAt(0)) || "U"), 1)
2105
+ Q.value ? (a(), c("div", Ma, [
2106
+ e("div", Sa, [
2107
+ e("div", Na, [
2108
+ e("span", null, x(((L = l(v).userName) == null ? void 0 : L.charAt(0)) || "U"), 1)
2084
2109
  ]),
2085
- e("div", ka, [
2086
- e("div", wa, x(l(h).userName), 1),
2087
- e("div", xa, x(l(h).departmentName), 1)
2110
+ e("div", Ea, [
2111
+ e("div", Ia, x(l(v).userName), 1),
2112
+ e("div", Ua, x(l(v).departmentName), 1)
2088
2113
  ])
2089
2114
  ]),
2090
2115
  p[8] || (p[8] = e("div", { class: "mix-top-menu__dropdown-divider" }, null, -1)),
2091
- e("div", Ca, [
2116
+ e("div", Ta, [
2092
2117
  e("div", {
2093
2118
  class: "mix-top-menu__dropdown-item",
2094
2119
  onClick: se
2095
2120
  }, [
2096
- b(l(U), {
2121
+ y(l(I), {
2097
2122
  name: "user",
2098
2123
  size: 16
2099
2124
  }),
@@ -2103,7 +2128,7 @@ const ve = Ue("menu", () => {
2103
2128
  class: "mix-top-menu__dropdown-item",
2104
2129
  onClick: $
2105
2130
  }, [
2106
- b(l(U), {
2131
+ y(l(I), {
2107
2132
  name: "lock",
2108
2133
  size: 16
2109
2134
  }),
@@ -2112,50 +2137,50 @@ const ve = Ue("menu", () => {
2112
2137
  p[7] || (p[7] = e("div", { class: "mix-top-menu__dropdown-divider" }, null, -1)),
2113
2138
  e("div", {
2114
2139
  class: "mix-top-menu__dropdown-item mix-top-menu__dropdown-item--danger",
2115
- onClick: S
2140
+ onClick: N
2116
2141
  }, [
2117
- b(l(U), {
2142
+ y(l(I), {
2118
2143
  name: "logout",
2119
2144
  size: 16
2120
2145
  }),
2121
2146
  p[6] || (p[6] = e("span", null, "退出登录", -1))
2122
2147
  ])
2123
2148
  ])
2124
- ])) : T("", !0)
2149
+ ])) : P("", !0)
2125
2150
  ];
2126
2151
  }),
2127
2152
  _: 1
2128
2153
  })
2129
2154
  ], 512)
2130
2155
  ]),
2131
- b(l(Je), {
2132
- modelValue: q.value,
2133
- "onUpdate:modelValue": p[2] || (p[2] = (L) => q.value = L),
2156
+ y(l(tt), {
2157
+ modelValue: G.value,
2158
+ "onUpdate:modelValue": p[2] || (p[2] = (L) => G.value = L),
2134
2159
  title: "换肤设置",
2135
2160
  direction: "rtl",
2136
2161
  size: "320px"
2137
2162
  }, {
2138
- default: M(() => [
2139
- e("div", $a, [
2140
- e("div", La, [
2163
+ default: S(() => [
2164
+ e("div", Pa, [
2165
+ e("div", za, [
2141
2166
  p[12] || (p[12] = e("div", { class: "settings-title" }, "布局模式", -1)),
2142
- e("div", Ma, [
2143
- (a(), c(K, null, Z(Me, (L) => e("div", {
2167
+ e("div", Fa, [
2168
+ (a(), c(H, null, J($e, (L) => e("div", {
2144
2169
  key: L.value,
2145
- class: Q(["layout-option", { "is-active": ke.value === L.value }]),
2146
- onClick: (Qe) => we(L.value)
2170
+ class: Z(["layout-option", { "is-active": re.value === L.value }]),
2171
+ onClick: (ot) => ge(L.value)
2147
2172
  }, [
2148
- e("div", Na, [
2149
- L.value === "sidebar" ? (a(), c("div", Ia, [...p[9] || (p[9] = [
2173
+ e("div", Aa, [
2174
+ L.value === "sidebar" ? (a(), c("div", Ba, [...p[9] || (p[9] = [
2150
2175
  e("div", { class: "preview-aside" }, null, -1),
2151
2176
  e("div", { class: "preview-main" }, [
2152
2177
  e("div", { class: "preview-header" }),
2153
2178
  e("div", { class: "preview-content" })
2154
2179
  ], -1)
2155
- ])])) : L.value === "top" ? (a(), c("div", Ea, [...p[10] || (p[10] = [
2180
+ ])])) : L.value === "top" ? (a(), c("div", Va, [...p[10] || (p[10] = [
2156
2181
  e("div", { class: "preview-header-full" }, null, -1),
2157
2182
  e("div", { class: "preview-content-full" }, null, -1)
2158
- ])])) : (a(), c("div", Ua, [...p[11] || (p[11] = [
2183
+ ])])) : (a(), c("div", Oa, [...p[11] || (p[11] = [
2159
2184
  e("div", { class: "preview-header-mix" }, [
2160
2185
  e("div", { class: "preview-mix-left" })
2161
2186
  ], -1),
@@ -2165,46 +2190,46 @@ const ve = Ue("menu", () => {
2165
2190
  ], -1)
2166
2191
  ])]))
2167
2192
  ]),
2168
- e("span", za, x(L.label), 1)
2169
- ], 10, Sa)), 64))
2193
+ e("span", Ra, x(L.label), 1)
2194
+ ], 10, Da)), 64))
2170
2195
  ])
2171
2196
  ]),
2172
- e("div", Pa, [
2197
+ e("div", Ka, [
2173
2198
  p[13] || (p[13] = e("div", { class: "settings-title" }, "主题色", -1)),
2174
- e("div", Ta, [
2175
- (a(), c(K, null, Z(z, (L) => e("div", {
2199
+ e("div", ja, [
2200
+ (a(), c(H, null, J(U, (L) => e("div", {
2176
2201
  key: L.value,
2177
- class: Q(["color-option", { "is-active": l(i).primaryColor === L.value }]),
2178
- style: Ne({ backgroundColor: L.value }),
2202
+ class: Z(["color-option", { "is-active": l(i).primaryColor === L.value }]),
2203
+ style: Pe({ backgroundColor: L.value }),
2179
2204
  title: L.label,
2180
- onClick: (Qe) => k(L.value)
2205
+ onClick: (ot) => b(L.value)
2181
2206
  }, [
2182
- l(i).primaryColor === L.value ? (a(), B(l(U), {
2207
+ l(i).primaryColor === L.value ? (a(), D(l(I), {
2183
2208
  key: 0,
2184
2209
  name: "check",
2185
2210
  size: 12,
2186
2211
  color: "#fff"
2187
- })) : T("", !0)
2188
- ], 14, Fa)), 64))
2212
+ })) : P("", !0)
2213
+ ], 14, Wa)), 64))
2189
2214
  ])
2190
2215
  ]),
2191
- e("div", Da, [
2216
+ e("div", qa, [
2192
2217
  p[18] || (p[18] = e("div", { class: "settings-title" }, "功能设置", -1)),
2193
- e("div", Aa, [
2194
- e("div", Ba, [
2218
+ e("div", Ha, [
2219
+ e("div", Ya, [
2195
2220
  p[15] || (p[15] = e("span", null, "灰色模式", -1)),
2196
2221
  e("div", {
2197
- class: Q(["switch-wrapper", { "is-checked": oe.value }]),
2198
- onClick: ce
2222
+ class: Z(["switch-wrapper", { "is-checked": te.value }]),
2223
+ onClick: ke
2199
2224
  }, [...p[14] || (p[14] = [
2200
2225
  e("span", { class: "switch-core" }, null, -1)
2201
2226
  ])], 2)
2202
2227
  ]),
2203
- e("div", Va, [
2228
+ e("div", Ga, [
2204
2229
  p[17] || (p[17] = e("span", null, "暗黑模式", -1)),
2205
2230
  e("div", {
2206
- class: Q(["switch-wrapper", { "is-checked": l(i).isDark }]),
2207
- onClick: ge
2231
+ class: Z(["switch-wrapper", { "is-checked": l(i).isDark }]),
2232
+ onClick: xe
2208
2233
  }, [...p[16] || (p[16] = [
2209
2234
  e("span", { class: "switch-core" }, null, -1)
2210
2235
  ])], 2)
@@ -2218,134 +2243,130 @@ const ve = Ue("menu", () => {
2218
2243
  ]);
2219
2244
  };
2220
2245
  }
2221
- }), Ra = /* @__PURE__ */ ie(Oa, [["__scopeId", "data-v-2a9b8000"]]), Ka = {
2246
+ }), Ja = /* @__PURE__ */ ue(Xa, [["__scopeId", "data-v-ec17777f"]]), Za = {
2222
2247
  key: 0,
2223
2248
  class: "layout layout--sidebar"
2224
- }, ja = { class: "layout__main" }, Wa = { class: "layout__header" }, qa = { class: "layout__content" }, Ha = {
2249
+ }, Qa = { class: "layout__main" }, en = { class: "layout__header" }, tn = { class: "layout__content" }, sn = {
2225
2250
  key: 1,
2226
2251
  class: "layout layout--top"
2227
- }, Ya = { class: "layout__top-menu" }, Ga = { class: "layout__main" }, Xa = { class: "layout__content" }, Ja = {
2252
+ }, on = { class: "layout__top-menu" }, an = { class: "layout__main" }, nn = { class: "layout__content" }, ln = {
2228
2253
  key: 2,
2229
2254
  class: "layout layout--mix"
2230
- }, Za = { class: "layout__mix-top-menu" }, Qa = { class: "layout__mix-body" }, en = { class: "layout__content" }, tn = /* @__PURE__ */ le({
2255
+ }, rn = { class: "layout__mix-top-menu" }, cn = { class: "layout__mix-body" }, un = { class: "layout__content" }, dn = /* @__PURE__ */ ie({
2231
2256
  __name: "index",
2232
2257
  props: {
2233
- logoSrc: { default: Ee("/vite.svg") }
2258
+ logoSrc: {}
2234
2259
  },
2235
2260
  setup(t) {
2236
- const n = t, u = pe(), s = ve(), o = w(
2237
- () => u.isCollapsed ? "64px" : "210px"
2238
- ), i = w(() => u.layout), h = w(() => i.value === "mix"), v = w(() => i.value === "sidebar" ? s.menuList : i.value === "mix" ? u.mixSubMenus : []), d = w(() => h.value ? v.value.length > 0 : !1);
2239
- return (g, _) => {
2240
- const f = ct("router-view");
2241
- return a(), c(K, null, [
2242
- i.value === "sidebar" ? (a(), c("div", Ka, [
2261
+ const n = t, m = w(() => n.logoSrc || ze("/vite.svg")), o = he(), s = _e(), h = w(
2262
+ () => o.isCollapsed ? "64px" : "210px"
2263
+ ), i = w(() => o.layout), v = w(() => i.value === "mix"), d = w(() => i.value === "sidebar" ? s.menuList : i.value === "mix" ? o.mixSubMenus : []), f = w(() => v.value ? d.value.length > 0 : !1);
2264
+ return (_, k) => {
2265
+ const u = pt("router-view");
2266
+ return a(), c(H, null, [
2267
+ i.value === "sidebar" ? (a(), c("div", Za, [
2243
2268
  e("aside", {
2244
2269
  class: "layout__aside",
2245
- style: Ne({ width: o.value })
2270
+ style: Pe({ width: h.value })
2246
2271
  }, [
2247
- b(ot, {
2248
- "menu-list": v.value,
2272
+ y(rt, {
2273
+ "menu-list": d.value,
2249
2274
  "show-logo": !0,
2250
2275
  "show-user": !0,
2251
- "logo-src": n.logoSrc
2276
+ "logo-src": m.value
2252
2277
  }, null, 8, ["menu-list", "logo-src"])
2253
2278
  ], 4),
2254
- e("div", ja, [
2255
- e("header", Wa, [
2256
- b(Ks)
2279
+ e("div", Qa, [
2280
+ e("header", en, [
2281
+ y(Zs)
2257
2282
  ]),
2258
- e("main", qa, [
2259
- b(f)
2283
+ e("main", tn, [
2284
+ y(u)
2260
2285
  ])
2261
2286
  ])
2262
- ])) : T("", !0),
2263
- i.value === "top" ? (a(), c("div", Ha, [
2264
- e("div", Ya, [
2265
- b(Jo, {
2266
- "logo-src": n.logoSrc
2267
- }, null, 8, ["logo-src"])
2287
+ ])) : P("", !0),
2288
+ i.value === "top" ? (a(), c("div", sn, [
2289
+ e("div", on, [
2290
+ y(la, { "logo-src": m.value }, null, 8, ["logo-src"])
2268
2291
  ]),
2269
- e("div", Ga, [
2270
- e("main", Xa, [
2271
- b(f)
2292
+ e("div", an, [
2293
+ e("main", nn, [
2294
+ y(u)
2272
2295
  ])
2273
2296
  ])
2274
- ])) : T("", !0),
2275
- i.value === "mix" ? (a(), c("div", Ja, [
2276
- e("div", Za, [
2277
- b(Ra, {
2278
- "logo-src": n.logoSrc
2279
- }, null, 8, ["logo-src"])
2297
+ ])) : P("", !0),
2298
+ i.value === "mix" ? (a(), c("div", ln, [
2299
+ e("div", rn, [
2300
+ y(Ja, { "logo-src": m.value }, null, 8, ["logo-src"])
2280
2301
  ]),
2281
- e("div", Qa, [
2282
- d.value ? (a(), c("aside", {
2302
+ e("div", cn, [
2303
+ f.value ? (a(), c("aside", {
2283
2304
  key: 0,
2284
2305
  class: "layout__aside",
2285
- style: Ne({ width: o.value })
2306
+ style: Pe({ width: h.value })
2286
2307
  }, [
2287
- b(ot, {
2288
- "menu-list": v.value,
2308
+ y(rt, {
2309
+ "menu-list": d.value,
2289
2310
  "show-logo": !1,
2290
2311
  "show-user": !1
2291
2312
  }, null, 8, ["menu-list"])
2292
- ], 4)) : T("", !0),
2293
- e("main", en, [
2294
- b(f)
2313
+ ], 4)) : P("", !0),
2314
+ e("main", un, [
2315
+ y(u)
2295
2316
  ])
2296
2317
  ])
2297
- ])) : T("", !0)
2318
+ ])) : P("", !0)
2298
2319
  ], 64);
2299
2320
  };
2300
2321
  }
2301
- }), dt = /* @__PURE__ */ ie(tn, [["__scopeId", "data-v-7f48e1f8"]]), sn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2322
+ }), ht = /* @__PURE__ */ ue(dn, [["__scopeId", "data-v-4e5f3bf5"]]), mn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2302
2323
  __proto__: null,
2303
- default: dt
2304
- }, Symbol.toStringTag, { value: "Module" })), on = { class: "tabs-wrapper" }, an = { class: "tab-label" }, nn = ["onClick"], ln = /* @__PURE__ */ le({
2324
+ default: ht
2325
+ }, Symbol.toStringTag, { value: "Module" })), pn = { class: "tabs-wrapper" }, vn = { class: "tab-label" }, hn = ["onClick"], _n = /* @__PURE__ */ ie({
2305
2326
  __name: "Tabs",
2306
2327
  setup(t) {
2307
- const n = Le(), u = he(), s = w(() => {
2328
+ const n = Ue(), m = be(), o = w(() => {
2308
2329
  const v = [];
2309
2330
  return n.matched.forEach((d) => {
2310
- var g;
2311
- (g = d.meta) != null && g.affix && v.push({
2331
+ var f;
2332
+ (f = d.meta) != null && f.affix && v.push({
2312
2333
  name: d.name,
2313
2334
  title: d.meta.title,
2314
2335
  path: d.path,
2315
2336
  affix: !0
2316
2337
  });
2317
2338
  }), v;
2318
- }), o = w(() => n.path), i = (v) => {
2319
- u.push(v);
2320
- }, h = (v) => {
2321
- const d = s.value.find((g) => g.path === v);
2322
- if (!(d != null && d.affix) && v === o.value) {
2323
- const g = s.value.findIndex((f) => f.path === v), _ = s.value[g - 1] || s.value[g + 1];
2324
- _ && u.push(_.path);
2339
+ }), s = w(() => n.path), h = (v) => {
2340
+ m.push(v);
2341
+ }, i = (v) => {
2342
+ const d = o.value.find((f) => f.path === v);
2343
+ if (!(d != null && d.affix) && v === s.value) {
2344
+ const f = o.value.findIndex((k) => k.path === v), _ = o.value[f - 1] || o.value[f + 1];
2345
+ _ && m.push(_.path);
2325
2346
  }
2326
2347
  };
2327
- return (v, d) => (a(), c("div", on, [
2328
- b(l(Lt), {
2329
- modelValue: o.value,
2330
- "onUpdate:modelValue": d[0] || (d[0] = (g) => o.value = g),
2348
+ return (v, d) => (a(), c("div", pn, [
2349
+ y(l(Tt), {
2350
+ modelValue: s.value,
2351
+ "onUpdate:modelValue": d[0] || (d[0] = (f) => s.value = f),
2331
2352
  type: "card",
2332
- onTabClick: i
2353
+ onTabClick: h
2333
2354
  }, {
2334
- default: M(() => [
2335
- (a(!0), c(K, null, Z(s.value, (g) => (a(), B(l(Mt), {
2336
- key: g.path,
2337
- name: g.path,
2338
- label: g.title,
2339
- closable: !g.affix
2355
+ default: S(() => [
2356
+ (a(!0), c(H, null, J(o.value, (f) => (a(), D(l(Pt), {
2357
+ key: f.path,
2358
+ name: f.path,
2359
+ label: f.title,
2360
+ closable: !f.affix
2340
2361
  }, {
2341
- label: M(() => [
2342
- e("span", an, [
2343
- ye(x(g.title) + " ", 1),
2344
- g.affix ? T("", !0) : (a(), c("span", {
2362
+ label: S(() => [
2363
+ e("span", vn, [
2364
+ Ce(x(f.title) + " ", 1),
2365
+ f.affix ? P("", !0) : (a(), c("span", {
2345
2366
  key: 0,
2346
2367
  class: "tab-close",
2347
- onClick: Fe((_) => h(g.path), ["stop"])
2348
- }, " ✕ ", 8, nn))
2368
+ onClick: Ve((_) => i(f.path), ["stop"])
2369
+ }, " ✕ ", 8, hn))
2349
2370
  ])
2350
2371
  ]),
2351
2372
  _: 2
@@ -2355,19 +2376,19 @@ const ve = Ue("menu", () => {
2355
2376
  }, 8, ["modelValue"])
2356
2377
  ]));
2357
2378
  }
2358
- }), Xn = /* @__PURE__ */ ie(ln, [["__scopeId", "data-v-0a4ca30d"]]), rn = {}, cn = { class: "footer" };
2359
- function un(t, n) {
2360
- return a(), c("div", cn, [...n[0] || (n[0] = [
2379
+ }), nl = /* @__PURE__ */ ue(_n, [["__scopeId", "data-v-0a4ca30d"]]), fn = {}, gn = { class: "footer" };
2380
+ function yn(t, n) {
2381
+ return a(), c("div", gn, [...n[0] || (n[0] = [
2361
2382
  e("span", null, "Copyright © 2024 Xto Demo. All Rights Reserved.", -1)
2362
2383
  ])]);
2363
2384
  }
2364
- const Jn = /* @__PURE__ */ ie(rn, [["render", un], ["__scopeId", "data-v-ac63e349"]]), dn = { class: "login-page" }, mn = { class: "login-form-section" }, pn = { class: "form-container" }, vn = { class: "input-wrapper" }, hn = { class: "input-wrapper" }, _n = { class: "form-options" }, fn = { key: 0 }, gn = { key: 1 }, yn = /* @__PURE__ */ le({
2385
+ const ll = /* @__PURE__ */ ue(fn, [["render", yn], ["__scopeId", "data-v-ac63e349"]]), bn = { class: "login-page" }, wn = { class: "login-form-section" }, kn = { class: "form-container" }, xn = { class: "input-wrapper" }, Cn = { class: "input-wrapper" }, $n = { class: "form-options" }, Ln = { key: 0 }, Mn = { key: 1 }, Sn = /* @__PURE__ */ ie({
2365
2386
  __name: "index",
2366
2387
  setup(t) {
2367
- const n = he(), u = Le(), s = y(!1), o = y(!1), i = He({
2388
+ const n = be(), m = Ue(), o = g(!1), s = g(!1), h = Je({
2368
2389
  uid: "",
2369
2390
  password: ""
2370
- }), h = {
2391
+ }), i = {
2371
2392
  uid: [
2372
2393
  { required: !0, message: "请输入用户名", trigger: "blur" }
2373
2394
  ],
@@ -2375,55 +2396,55 @@ const Jn = /* @__PURE__ */ ie(rn, [["render", un], ["__scopeId", "data-v-ac63e34
2375
2396
  { required: !0, message: "请输入密码", trigger: "blur" },
2376
2397
  { min: 6, message: "密码长度至少6位", trigger: "blur" }
2377
2398
  ]
2378
- }, v = y(), d = async () => {
2379
- var g;
2399
+ }, v = g(), d = async () => {
2400
+ var f;
2380
2401
  try {
2381
- await ((g = v.value) == null ? void 0 : g.validate()), s.value = !0;
2382
- const _ = await _t({
2383
- appId: Ie(),
2384
- clientId: it(),
2385
- uid: i.uid,
2386
- password: i.password,
2402
+ await ((f = v.value) == null ? void 0 : f.validate()), o.value = !0;
2403
+ const _ = await wt({
2404
+ appId: Ne(),
2405
+ clientId: mt(),
2406
+ uid: h.uid,
2407
+ password: h.password,
2387
2408
  code: !0
2388
2409
  });
2389
- rt(_), St.success("登录成功");
2390
- const f = u.query.redirect;
2391
- f ? n.push(f) : n.push({ name: "Dashboard" });
2410
+ dt(_), zt.success("登录成功");
2411
+ const k = m.query.redirect;
2412
+ k ? n.push(k) : n.push({ name: "Dashboard" });
2392
2413
  } catch (_) {
2393
2414
  console.error("登录失败:", _);
2394
2415
  } finally {
2395
- s.value = !1;
2416
+ o.value = !1;
2396
2417
  }
2397
2418
  };
2398
- return (g, _) => (a(), c("div", dn, [
2399
- _[10] || (_[10] = Pe('<div class="login-brand" data-v-20b19b53><div class="brand-content" data-v-20b19b53><div class="brand-logo" data-v-20b19b53><div class="logo-icon" data-v-20b19b53><svg viewBox="0 0 48 48" fill="none" xmlns="http://www.w3.org/2000/svg" data-v-20b19b53><rect width="48" height="48" rx="12" fill="currentColor" data-v-20b19b53></rect><path d="M14 24L20 30L34 16" stroke="white" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" data-v-20b19b53></path></svg></div><span class="logo-text" data-v-20b19b53>XTO</span></div><div class="brand-slogan" data-v-20b19b53><h1 data-v-20b19b53>企业级后台管理解决方案</h1><p data-v-20b19b53>开箱即用的中后台前端/设计解决方案</p></div><div class="brand-features" data-v-20b19b53><div class="feature-item" data-v-20b19b53><div class="feature-icon" data-v-20b19b53><svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" data-v-20b19b53><path d="M13 2L3 14h9l-1 8 10-12h-9l1-8z" data-v-20b19b53></path></svg></div><div class="feature-text" data-v-20b19b53><h4 data-v-20b19b53>高性能</h4><p data-v-20b19b53>极致的渲染性能与响应速度</p></div></div><div class="feature-item" data-v-20b19b53><div class="feature-icon" data-v-20b19b53><svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" data-v-20b19b53><rect x="3" y="3" width="18" height="18" rx="2" data-v-20b19b53></rect><path d="M9 9h6M9 12h6M9 15h4" data-v-20b19b53></path></svg></div><div class="feature-text" data-v-20b19b53><h4 data-v-20b19b53>丰富组件</h4><p data-v-20b19b53>60+ 高质量业务组件</p></div></div><div class="feature-item" data-v-20b19b53><div class="feature-icon" data-v-20b19b53><svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" data-v-20b19b53><circle cx="12" cy="12" r="10" data-v-20b19b53></circle><path d="M12 6v6l4 2" data-v-20b19b53></path></svg></div><div class="feature-text" data-v-20b19b53><h4 data-v-20b19b53>持续更新</h4><p data-v-20b19b53>活跃的社区与快速迭代</p></div></div></div><div class="brand-decoration" data-v-20b19b53><div class="decoration-line" data-v-20b19b53></div><div class="decoration-dots" data-v-20b19b53><span data-v-20b19b53></span><span data-v-20b19b53></span><span data-v-20b19b53></span></div></div></div><div class="brand-bg" data-v-20b19b53><div class="bg-grid" data-v-20b19b53></div></div></div>', 1)),
2400
- e("div", mn, [
2401
- e("div", pn, [
2419
+ return (f, _) => (a(), c("div", bn, [
2420
+ _[10] || (_[10] = Ae('<div class="login-brand" data-v-20b19b53><div class="brand-content" data-v-20b19b53><div class="brand-logo" data-v-20b19b53><div class="logo-icon" data-v-20b19b53><svg viewBox="0 0 48 48" fill="none" xmlns="http://www.w3.org/2000/svg" data-v-20b19b53><rect width="48" height="48" rx="12" fill="currentColor" data-v-20b19b53></rect><path d="M14 24L20 30L34 16" stroke="white" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" data-v-20b19b53></path></svg></div><span class="logo-text" data-v-20b19b53>XTO</span></div><div class="brand-slogan" data-v-20b19b53><h1 data-v-20b19b53>企业级后台管理解决方案</h1><p data-v-20b19b53>开箱即用的中后台前端/设计解决方案</p></div><div class="brand-features" data-v-20b19b53><div class="feature-item" data-v-20b19b53><div class="feature-icon" data-v-20b19b53><svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" data-v-20b19b53><path d="M13 2L3 14h9l-1 8 10-12h-9l1-8z" data-v-20b19b53></path></svg></div><div class="feature-text" data-v-20b19b53><h4 data-v-20b19b53>高性能</h4><p data-v-20b19b53>极致的渲染性能与响应速度</p></div></div><div class="feature-item" data-v-20b19b53><div class="feature-icon" data-v-20b19b53><svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" data-v-20b19b53><rect x="3" y="3" width="18" height="18" rx="2" data-v-20b19b53></rect><path d="M9 9h6M9 12h6M9 15h4" data-v-20b19b53></path></svg></div><div class="feature-text" data-v-20b19b53><h4 data-v-20b19b53>丰富组件</h4><p data-v-20b19b53>60+ 高质量业务组件</p></div></div><div class="feature-item" data-v-20b19b53><div class="feature-icon" data-v-20b19b53><svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" data-v-20b19b53><circle cx="12" cy="12" r="10" data-v-20b19b53></circle><path d="M12 6v6l4 2" data-v-20b19b53></path></svg></div><div class="feature-text" data-v-20b19b53><h4 data-v-20b19b53>持续更新</h4><p data-v-20b19b53>活跃的社区与快速迭代</p></div></div></div><div class="brand-decoration" data-v-20b19b53><div class="decoration-line" data-v-20b19b53></div><div class="decoration-dots" data-v-20b19b53><span data-v-20b19b53></span><span data-v-20b19b53></span><span data-v-20b19b53></span></div></div></div><div class="brand-bg" data-v-20b19b53><div class="bg-grid" data-v-20b19b53></div></div></div>', 1)),
2421
+ e("div", wn, [
2422
+ e("div", kn, [
2402
2423
  _[7] || (_[7] = e("div", { class: "form-header" }, [
2403
2424
  e("h2", null, "欢迎登录"),
2404
2425
  e("p", null, "请输入您的账户信息")
2405
2426
  ], -1)),
2406
- b(l(Nt), {
2427
+ y(l(Ft), {
2407
2428
  ref_key: "formRef",
2408
2429
  ref: v,
2409
- model: i,
2410
- rules: h,
2430
+ model: h,
2431
+ rules: i,
2411
2432
  class: "login-form",
2412
2433
  "label-width": "0"
2413
2434
  }, {
2414
- default: M(() => [
2415
- b(l(De), { prop: "uid" }, {
2416
- default: M(() => [
2417
- e("div", vn, [
2435
+ default: S(() => [
2436
+ y(l(Oe), { prop: "uid" }, {
2437
+ default: S(() => [
2438
+ e("div", xn, [
2418
2439
  _[3] || (_[3] = e("label", { class: "input-label" }, "用户名", -1)),
2419
- b(l(st), {
2420
- modelValue: i.uid,
2421
- "onUpdate:modelValue": _[0] || (_[0] = (f) => i.uid = f),
2440
+ y(l(lt), {
2441
+ modelValue: h.uid,
2442
+ "onUpdate:modelValue": _[0] || (_[0] = (k) => h.uid = k),
2422
2443
  placeholder: "请输入用户名",
2423
2444
  size: "large"
2424
2445
  }, {
2425
- prefix: M(() => [
2426
- b(l(U), {
2446
+ prefix: S(() => [
2447
+ y(l(I), {
2427
2448
  name: "user",
2428
2449
  size: 18
2429
2450
  })
@@ -2434,21 +2455,21 @@ const Jn = /* @__PURE__ */ ie(rn, [["render", un], ["__scopeId", "data-v-ac63e34
2434
2455
  ]),
2435
2456
  _: 1
2436
2457
  }),
2437
- b(l(De), { prop: "password" }, {
2438
- default: M(() => [
2439
- e("div", hn, [
2458
+ y(l(Oe), { prop: "password" }, {
2459
+ default: S(() => [
2460
+ e("div", Cn, [
2440
2461
  _[4] || (_[4] = e("label", { class: "input-label" }, "密码", -1)),
2441
- b(l(st), {
2442
- modelValue: i.password,
2443
- "onUpdate:modelValue": _[1] || (_[1] = (f) => i.password = f),
2462
+ y(l(lt), {
2463
+ modelValue: h.password,
2464
+ "onUpdate:modelValue": _[1] || (_[1] = (k) => h.password = k),
2444
2465
  type: "password",
2445
2466
  placeholder: "请输入密码",
2446
2467
  size: "large",
2447
2468
  "show-password": "",
2448
- onKeyup: Ct(d, ["enter"])
2469
+ onKeyup: It(d, ["enter"])
2449
2470
  }, {
2450
- prefix: M(() => [
2451
- b(l(U), {
2471
+ prefix: S(() => [
2472
+ y(l(I), {
2452
2473
  name: "lock",
2453
2474
  size: 18
2454
2475
  })
@@ -2459,13 +2480,13 @@ const Jn = /* @__PURE__ */ ie(rn, [["render", un], ["__scopeId", "data-v-ac63e34
2459
2480
  ]),
2460
2481
  _: 1
2461
2482
  }),
2462
- e("div", _n, [
2463
- b(l(It), {
2464
- modelValue: o.value,
2465
- "onUpdate:modelValue": _[2] || (_[2] = (f) => o.value = f)
2483
+ e("div", $n, [
2484
+ y(l(Dt), {
2485
+ modelValue: s.value,
2486
+ "onUpdate:modelValue": _[2] || (_[2] = (k) => s.value = k)
2466
2487
  }, {
2467
- default: M(() => [..._[5] || (_[5] = [
2468
- ye("记住我", -1)
2488
+ default: S(() => [..._[5] || (_[5] = [
2489
+ Ce("记住我", -1)
2469
2490
  ])]),
2470
2491
  _: 1
2471
2492
  }, 8, ["modelValue"]),
@@ -2474,17 +2495,17 @@ const Jn = /* @__PURE__ */ ie(rn, [["render", un], ["__scopeId", "data-v-ac63e34
2474
2495
  class: "forgot-link"
2475
2496
  }, "忘记密码?", -1))
2476
2497
  ]),
2477
- b(l(De), null, {
2478
- default: M(() => [
2479
- b(l($e), {
2498
+ y(l(Oe), null, {
2499
+ default: S(() => [
2500
+ y(l(Ie), {
2480
2501
  type: "primary",
2481
2502
  size: "large",
2482
- loading: s.value,
2503
+ loading: o.value,
2483
2504
  class: "login-btn",
2484
2505
  onClick: d
2485
2506
  }, {
2486
- default: M(() => [
2487
- s.value ? (a(), c("span", gn, "登录中...")) : (a(), c("span", fn, "登 录"))
2507
+ default: S(() => [
2508
+ o.value ? (a(), c("span", Mn, "登录中...")) : (a(), c("span", Ln, "登 录"))
2488
2509
  ]),
2489
2510
  _: 1
2490
2511
  }, 8, ["loading"])
@@ -2494,7 +2515,7 @@ const Jn = /* @__PURE__ */ ie(rn, [["render", un], ["__scopeId", "data-v-ac63e34
2494
2515
  ]),
2495
2516
  _: 1
2496
2517
  }, 8, ["model"]),
2497
- _[8] || (_[8] = Pe('<div class="form-footer" data-v-20b19b53><p data-v-20b19b53>其他登录方式</p><div class="social-login" data-v-20b19b53><button class="social-btn" title="企业微信" data-v-20b19b53><svg viewBox="0 0 24 24" fill="currentColor" data-v-20b19b53><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-1 17.93c-3.95-.49-7-3.85-7-7.93 0-.62.08-1.21.21-1.79L9 15v1c0 1.1.9 2 2 2v1.93zm6.9-2.54c-.26-.81-1-1.39-1.9-1.39h-1v-3c0-.55-.45-1-1-1H8v-2h2c.55 0 1-.45 1-1V7h2c1.1 0 2-.9 2-2v-.41c2.93 1.19 5 4.06 5 7.41 0 2.08-.8 3.97-2.1 5.39z" data-v-20b19b53></path></svg></button><button class="social-btn" title="钉钉" data-v-20b19b53><svg viewBox="0 0 24 24" fill="currentColor" data-v-20b19b53><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm4.64 6.8c-.15 1.58-.8 5.42-1.13 7.19-.14.75-.42 1-.68 1.03-.58.05-1.02-.38-1.58-.75-.88-.58-1.38-.94-2.23-1.5-.99-.65-.35-1.01.22-1.59.15-.15 2.71-2.48 2.76-2.69a.2.2 0 00-.05-.18c-.06-.05-.14-.03-.21-.02-.09.02-1.49.95-4.22 2.79-.4.27-.76.41-1.08.4-.36-.01-1.04-.2-1.55-.37-.63-.2-1.12-.31-1.08-.66.02-.18.27-.36.74-.55 2.92-1.27 4.86-2.11 5.83-2.51 2.78-1.16 3.35-1.36 3.73-1.36.08 0 .27.02.39.12.1.08.13.19.14.27-.01.06.01.24 0 .38z" data-v-20b19b53></path></svg></button><button class="social-btn" title="飞书" data-v-20b19b53><svg viewBox="0 0 24 24" fill="currentColor" data-v-20b19b53><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z" data-v-20b19b53></path></svg></button></div></div>', 1))
2518
+ _[8] || (_[8] = Ae('<div class="form-footer" data-v-20b19b53><p data-v-20b19b53>其他登录方式</p><div class="social-login" data-v-20b19b53><button class="social-btn" title="企业微信" data-v-20b19b53><svg viewBox="0 0 24 24" fill="currentColor" data-v-20b19b53><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-1 17.93c-3.95-.49-7-3.85-7-7.93 0-.62.08-1.21.21-1.79L9 15v1c0 1.1.9 2 2 2v1.93zm6.9-2.54c-.26-.81-1-1.39-1.9-1.39h-1v-3c0-.55-.45-1-1-1H8v-2h2c.55 0 1-.45 1-1V7h2c1.1 0 2-.9 2-2v-.41c2.93 1.19 5 4.06 5 7.41 0 2.08-.8 3.97-2.1 5.39z" data-v-20b19b53></path></svg></button><button class="social-btn" title="钉钉" data-v-20b19b53><svg viewBox="0 0 24 24" fill="currentColor" data-v-20b19b53><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm4.64 6.8c-.15 1.58-.8 5.42-1.13 7.19-.14.75-.42 1-.68 1.03-.58.05-1.02-.38-1.58-.75-.88-.58-1.38-.94-2.23-1.5-.99-.65-.35-1.01.22-1.59.15-.15 2.71-2.48 2.76-2.69a.2.2 0 00-.05-.18c-.06-.05-.14-.03-.21-.02-.09.02-1.49.95-4.22 2.79-.4.27-.76.41-1.08.4-.36-.01-1.04-.2-1.55-.37-.63-.2-1.12-.31-1.08-.66.02-.18.27-.36.74-.55 2.92-1.27 4.86-2.11 5.83-2.51 2.78-1.16 3.35-1.36 3.73-1.36.08 0 .27.02.39.12.1.08.13.19.14.27-.01.06.01.24 0 .38z" data-v-20b19b53></path></svg></button><button class="social-btn" title="飞书" data-v-20b19b53><svg viewBox="0 0 24 24" fill="currentColor" data-v-20b19b53><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z" data-v-20b19b53></path></svg></button></div></div>', 1))
2498
2519
  ]),
2499
2520
  _[9] || (_[9] = e("div", { class: "copyright" }, [
2500
2521
  e("p", null, "© 2024 XTO Team. All rights reserved.")
@@ -2502,31 +2523,31 @@ const Jn = /* @__PURE__ */ ie(rn, [["render", un], ["__scopeId", "data-v-ac63e34
2502
2523
  ])
2503
2524
  ]));
2504
2525
  }
2505
- }), bn = /* @__PURE__ */ ie(yn, [["__scopeId", "data-v-20b19b53"]]), kn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2526
+ }), Nn = /* @__PURE__ */ ue(Sn, [["__scopeId", "data-v-20b19b53"]]), En = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2506
2527
  __proto__: null,
2507
- default: bn
2508
- }, Symbol.toStringTag, { value: "Module" })), wn = { class: "error-page" }, xn = { class: "error-container" }, Cn = { class: "error-content" }, $n = { class: "error-actions" }, Ln = /* @__PURE__ */ le({
2528
+ default: Nn
2529
+ }, Symbol.toStringTag, { value: "Module" })), In = { class: "error-page" }, Un = { class: "error-container" }, Tn = { class: "error-content" }, Pn = { class: "error-actions" }, zn = /* @__PURE__ */ ie({
2509
2530
  __name: "404",
2510
2531
  setup(t) {
2511
- const n = he(), u = () => {
2532
+ const n = be(), m = () => {
2512
2533
  n.push("/");
2513
2534
  };
2514
- return (s, o) => (a(), c("div", wn, [
2515
- e("div", xn, [
2516
- o[7] || (o[7] = e("div", { class: "error-bg" }, [
2535
+ return (o, s) => (a(), c("div", In, [
2536
+ e("div", Un, [
2537
+ s[7] || (s[7] = e("div", { class: "error-bg" }, [
2517
2538
  e("div", { class: "bg-circle circle-1" }),
2518
2539
  e("div", { class: "bg-circle circle-2" }),
2519
2540
  e("div", { class: "bg-circle circle-3" })
2520
2541
  ], -1)),
2521
- e("div", Cn, [
2522
- o[5] || (o[5] = Pe('<div class="error-code" data-v-c36cc0ad><span class="code-digit" data-v-c36cc0ad>4</span><span class="code-zero" data-v-c36cc0ad><span class="zero-inner" data-v-c36cc0ad>0</span></span><span class="code-digit" data-v-c36cc0ad>4</span></div><div class="error-illustration" data-v-c36cc0ad><svg viewBox="0 0 200 120" fill="none" xmlns="http://www.w3.org/2000/svg" data-v-c36cc0ad><rect x="40" y="20" width="120" height="80" rx="8" fill="var(--xto-fill-color, #F2F3F5)" stroke="var(--xto-border-color, #D9DCE1)" stroke-width="2" data-v-c36cc0ad></rect><rect x="50" y="30" width="100" height="60" rx="4" fill="var(--xto-bg-color, #FFFFFF)" data-v-c36cc0ad></rect><line x1="60" y1="45" x2="140" y2="45" stroke="var(--xto-border-color-light, #E5E6EB)" stroke-width="2" data-v-c36cc0ad></line><line x1="60" y1="55" x2="120" y2="55" stroke="var(--xto-border-color-light, #E5E6EB)" stroke-width="2" data-v-c36cc0ad></line><line x1="60" y1="65" x2="100" y2="65" stroke="var(--xto-border-color-light, #E5E6EB)" stroke-width="2" data-v-c36cc0ad></line><text x="100" y="75" text-anchor="middle" fill="var(--xto-color-primary, #4F46E5)" font-size="24" font-weight="600" data-v-c36cc0ad>?</text><circle cx="150" cy="35" r="12" stroke="var(--xto-color-primary, #4F46E5)" stroke-width="2" fill="none" data-v-c36cc0ad></circle><line x1="158" y1="43" x2="168" y2="53" stroke="var(--xto-color-primary, #4F46E5)" stroke-width="2" stroke-linecap="round" data-v-c36cc0ad></line></svg></div><h1 class="error-title" data-v-c36cc0ad>页面不存在</h1><p class="error-desc" data-v-c36cc0ad>抱歉,您访问的页面不存在或已被删除</p>', 4)),
2523
- e("div", $n, [
2524
- b(l($e), {
2542
+ e("div", Tn, [
2543
+ s[5] || (s[5] = Ae('<div class="error-code" data-v-c36cc0ad><span class="code-digit" data-v-c36cc0ad>4</span><span class="code-zero" data-v-c36cc0ad><span class="zero-inner" data-v-c36cc0ad>0</span></span><span class="code-digit" data-v-c36cc0ad>4</span></div><div class="error-illustration" data-v-c36cc0ad><svg viewBox="0 0 200 120" fill="none" xmlns="http://www.w3.org/2000/svg" data-v-c36cc0ad><rect x="40" y="20" width="120" height="80" rx="8" fill="var(--xto-fill-color, #F2F3F5)" stroke="var(--xto-border-color, #D9DCE1)" stroke-width="2" data-v-c36cc0ad></rect><rect x="50" y="30" width="100" height="60" rx="4" fill="var(--xto-bg-color, #FFFFFF)" data-v-c36cc0ad></rect><line x1="60" y1="45" x2="140" y2="45" stroke="var(--xto-border-color-light, #E5E6EB)" stroke-width="2" data-v-c36cc0ad></line><line x1="60" y1="55" x2="120" y2="55" stroke="var(--xto-border-color-light, #E5E6EB)" stroke-width="2" data-v-c36cc0ad></line><line x1="60" y1="65" x2="100" y2="65" stroke="var(--xto-border-color-light, #E5E6EB)" stroke-width="2" data-v-c36cc0ad></line><text x="100" y="75" text-anchor="middle" fill="var(--xto-color-primary, #4F46E5)" font-size="24" font-weight="600" data-v-c36cc0ad>?</text><circle cx="150" cy="35" r="12" stroke="var(--xto-color-primary, #4F46E5)" stroke-width="2" fill="none" data-v-c36cc0ad></circle><line x1="158" y1="43" x2="168" y2="53" stroke="var(--xto-color-primary, #4F46E5)" stroke-width="2" stroke-linecap="round" data-v-c36cc0ad></line></svg></div><h1 class="error-title" data-v-c36cc0ad>页面不存在</h1><p class="error-desc" data-v-c36cc0ad>抱歉,您访问的页面不存在或已被删除</p>', 4)),
2544
+ e("div", Pn, [
2545
+ y(l(Ie), {
2525
2546
  type: "primary",
2526
2547
  size: "large",
2527
- onClick: u
2548
+ onClick: m
2528
2549
  }, {
2529
- icon: M(() => [...o[1] || (o[1] = [
2550
+ icon: S(() => [...s[1] || (s[1] = [
2530
2551
  e("svg", {
2531
2552
  viewBox: "0 0 24 24",
2532
2553
  fill: "none",
@@ -2537,16 +2558,16 @@ const Jn = /* @__PURE__ */ ie(rn, [["render", un], ["__scopeId", "data-v-ac63e34
2537
2558
  e("polyline", { points: "9,22 9,12 15,12 15,22" })
2538
2559
  ], -1)
2539
2560
  ])]),
2540
- default: M(() => [
2541
- o[2] || (o[2] = ye(" 返回首页 ", -1))
2561
+ default: S(() => [
2562
+ s[2] || (s[2] = Ce(" 返回首页 ", -1))
2542
2563
  ]),
2543
2564
  _: 1
2544
2565
  }),
2545
- b(l($e), {
2566
+ y(l(Ie), {
2546
2567
  size: "large",
2547
- onClick: o[0] || (o[0] = (i) => l(n).go(-1))
2568
+ onClick: s[0] || (s[0] = (h) => l(n).go(-1))
2548
2569
  }, {
2549
- icon: M(() => [...o[3] || (o[3] = [
2570
+ icon: S(() => [...s[3] || (s[3] = [
2550
2571
  e("svg", {
2551
2572
  viewBox: "0 0 24 24",
2552
2573
  fill: "none",
@@ -2556,13 +2577,13 @@ const Jn = /* @__PURE__ */ ie(rn, [["render", un], ["__scopeId", "data-v-ac63e34
2556
2577
  e("path", { d: "M19 12H5M12 19l-7-7 7-7" })
2557
2578
  ], -1)
2558
2579
  ])]),
2559
- default: M(() => [
2560
- o[4] || (o[4] = ye(" 返回上一页 ", -1))
2580
+ default: S(() => [
2581
+ s[4] || (s[4] = Ce(" 返回上一页 ", -1))
2561
2582
  ]),
2562
2583
  _: 1
2563
2584
  })
2564
2585
  ]),
2565
- o[6] || (o[6] = e("div", { class: "error-tip" }, [
2586
+ s[6] || (s[6] = e("div", { class: "error-tip" }, [
2566
2587
  e("p", null, "您可以尝试:"),
2567
2588
  e("ul", null, [
2568
2589
  e("li", null, "检查您输入的网址是否正确"),
@@ -2574,31 +2595,31 @@ const Jn = /* @__PURE__ */ ie(rn, [["render", un], ["__scopeId", "data-v-ac63e34
2574
2595
  ])
2575
2596
  ]));
2576
2597
  }
2577
- }), Mn = /* @__PURE__ */ ie(Ln, [["__scopeId", "data-v-c36cc0ad"]]), mt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2598
+ }), Fn = /* @__PURE__ */ ue(zn, [["__scopeId", "data-v-c36cc0ad"]]), _t = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2578
2599
  __proto__: null,
2579
- default: Mn
2580
- }, Symbol.toStringTag, { value: "Module" })), Sn = { class: "error-page" }, Nn = { class: "error-container" }, In = { class: "error-content" }, En = { class: "error-actions" }, Un = /* @__PURE__ */ le({
2600
+ default: Fn
2601
+ }, Symbol.toStringTag, { value: "Module" })), Dn = { class: "error-page" }, An = { class: "error-container" }, Bn = { class: "error-content" }, Vn = { class: "error-actions" }, On = /* @__PURE__ */ ie({
2581
2602
  __name: "403",
2582
2603
  setup(t) {
2583
- const n = he(), u = () => {
2604
+ const n = be(), m = () => {
2584
2605
  n.push("/");
2585
2606
  };
2586
- return (s, o) => (a(), c("div", Sn, [
2587
- e("div", Nn, [
2588
- o[7] || (o[7] = e("div", { class: "error-bg" }, [
2607
+ return (o, s) => (a(), c("div", Dn, [
2608
+ e("div", An, [
2609
+ s[7] || (s[7] = e("div", { class: "error-bg" }, [
2589
2610
  e("div", { class: "bg-circle circle-1" }),
2590
2611
  e("div", { class: "bg-circle circle-2" }),
2591
2612
  e("div", { class: "bg-circle circle-3" })
2592
2613
  ], -1)),
2593
- e("div", In, [
2594
- o[5] || (o[5] = Pe('<div class="error-code" data-v-e6e1f7ac><span class="code-digit" data-v-e6e1f7ac>4</span><span class="code-zero warning" data-v-e6e1f7ac><span class="zero-inner" data-v-e6e1f7ac>0</span></span><span class="code-digit" data-v-e6e1f7ac>3</span></div><div class="error-illustration" data-v-e6e1f7ac><svg viewBox="0 0 200 120" fill="none" xmlns="http://www.w3.org/2000/svg" data-v-e6e1f7ac><path d="M100 15 L150 35 L150 70 C150 95 100 110 100 110 C100 110 50 95 50 70 L50 35 Z" fill="var(--xto-color-warning-light-9, #FFF3E8)" stroke="var(--xto-color-warning, #FF7D00)" stroke-width="2" data-v-e6e1f7ac></path><rect x="85" y="55" width="30" height="25" rx="4" fill="var(--xto-color-warning, #FF7D00)" data-v-e6e1f7ac></rect><path d="M92 55 V48 A8 8 0 0 1 108 48 V55" fill="none" stroke="var(--xto-color-warning, #FF7D00)" stroke-width="3" data-v-e6e1f7ac></path><circle cx="100" cy="67" r="6" fill="none" stroke="#fff" stroke-width="2" data-v-e6e1f7ac></circle><line x1="96" y1="63" x2="104" y2="71" stroke="#fff" stroke-width="2" data-v-e6e1f7ac></line></svg></div><h1 class="error-title" data-v-e6e1f7ac>无访问权限</h1><p class="error-desc" data-v-e6e1f7ac>抱歉,您没有权限访问此页面,请联系管理员获取权限</p>', 4)),
2595
- e("div", En, [
2596
- b(l($e), {
2614
+ e("div", Bn, [
2615
+ s[5] || (s[5] = Ae('<div class="error-code" data-v-e6e1f7ac><span class="code-digit" data-v-e6e1f7ac>4</span><span class="code-zero warning" data-v-e6e1f7ac><span class="zero-inner" data-v-e6e1f7ac>0</span></span><span class="code-digit" data-v-e6e1f7ac>3</span></div><div class="error-illustration" data-v-e6e1f7ac><svg viewBox="0 0 200 120" fill="none" xmlns="http://www.w3.org/2000/svg" data-v-e6e1f7ac><path d="M100 15 L150 35 L150 70 C150 95 100 110 100 110 C100 110 50 95 50 70 L50 35 Z" fill="var(--xto-color-warning-light-9, #FFF3E8)" stroke="var(--xto-color-warning, #FF7D00)" stroke-width="2" data-v-e6e1f7ac></path><rect x="85" y="55" width="30" height="25" rx="4" fill="var(--xto-color-warning, #FF7D00)" data-v-e6e1f7ac></rect><path d="M92 55 V48 A8 8 0 0 1 108 48 V55" fill="none" stroke="var(--xto-color-warning, #FF7D00)" stroke-width="3" data-v-e6e1f7ac></path><circle cx="100" cy="67" r="6" fill="none" stroke="#fff" stroke-width="2" data-v-e6e1f7ac></circle><line x1="96" y1="63" x2="104" y2="71" stroke="#fff" stroke-width="2" data-v-e6e1f7ac></line></svg></div><h1 class="error-title" data-v-e6e1f7ac>无访问权限</h1><p class="error-desc" data-v-e6e1f7ac>抱歉,您没有权限访问此页面,请联系管理员获取权限</p>', 4)),
2616
+ e("div", Vn, [
2617
+ y(l(Ie), {
2597
2618
  type: "primary",
2598
2619
  size: "large",
2599
- onClick: u
2620
+ onClick: m
2600
2621
  }, {
2601
- icon: M(() => [...o[1] || (o[1] = [
2622
+ icon: S(() => [...s[1] || (s[1] = [
2602
2623
  e("svg", {
2603
2624
  viewBox: "0 0 24 24",
2604
2625
  fill: "none",
@@ -2609,16 +2630,16 @@ const Jn = /* @__PURE__ */ ie(rn, [["render", un], ["__scopeId", "data-v-ac63e34
2609
2630
  e("polyline", { points: "9,22 9,12 15,12 15,22" })
2610
2631
  ], -1)
2611
2632
  ])]),
2612
- default: M(() => [
2613
- o[2] || (o[2] = ye(" 返回首页 ", -1))
2633
+ default: S(() => [
2634
+ s[2] || (s[2] = Ce(" 返回首页 ", -1))
2614
2635
  ]),
2615
2636
  _: 1
2616
2637
  }),
2617
- b(l($e), {
2638
+ y(l(Ie), {
2618
2639
  size: "large",
2619
- onClick: o[0] || (o[0] = (i) => l(n).go(-1))
2640
+ onClick: s[0] || (s[0] = (h) => l(n).go(-1))
2620
2641
  }, {
2621
- icon: M(() => [...o[3] || (o[3] = [
2642
+ icon: S(() => [...s[3] || (s[3] = [
2622
2643
  e("svg", {
2623
2644
  viewBox: "0 0 24 24",
2624
2645
  fill: "none",
@@ -2628,13 +2649,13 @@ const Jn = /* @__PURE__ */ ie(rn, [["render", un], ["__scopeId", "data-v-ac63e34
2628
2649
  e("path", { d: "M19 12H5M12 19l-7-7 7-7" })
2629
2650
  ], -1)
2630
2651
  ])]),
2631
- default: M(() => [
2632
- o[4] || (o[4] = ye(" 返回上一页 ", -1))
2652
+ default: S(() => [
2653
+ s[4] || (s[4] = Ce(" 返回上一页 ", -1))
2633
2654
  ]),
2634
2655
  _: 1
2635
2656
  })
2636
2657
  ]),
2637
- o[6] || (o[6] = e("div", { class: "error-tip" }, [
2658
+ s[6] || (s[6] = e("div", { class: "error-tip" }, [
2638
2659
  e("p", null, "可能的原因:"),
2639
2660
  e("ul", null, [
2640
2661
  e("li", null, "您的账号权限不足"),
@@ -2646,17 +2667,17 @@ const Jn = /* @__PURE__ */ ie(rn, [["render", un], ["__scopeId", "data-v-ac63e34
2646
2667
  ])
2647
2668
  ]));
2648
2669
  }
2649
- }), Zn = /* @__PURE__ */ ie(Un, [["__scopeId", "data-v-e6e1f7ac"]]);
2650
- function Qn() {
2651
- const t = pe(), n = re(), u = ze(), s = w(() => n.userName || ""), o = w(() => n.userInfo), i = w(() => t.appName), h = w(() => u.isLoggedIn), v = w(() => t.isDark), d = w(() => t.theme), g = w(() => t.isCollapsed), _ = w(() => t.layout);
2670
+ }), rl = /* @__PURE__ */ ue(On, [["__scopeId", "data-v-e6e1f7ac"]]);
2671
+ function il() {
2672
+ const t = he(), n = ce(), m = De(), o = w(() => n.userName || ""), s = w(() => n.userInfo), h = w(() => t.appName), i = w(() => m.isLoggedIn), v = w(() => t.isDark), d = w(() => t.theme), f = w(() => t.isCollapsed), _ = w(() => t.layout);
2652
2673
  return {
2653
- userName: s,
2654
- userInfo: o,
2655
- appName: i,
2656
- isLoggedIn: h,
2674
+ userName: o,
2675
+ userInfo: s,
2676
+ appName: h,
2677
+ isLoggedIn: i,
2657
2678
  isDark: v,
2658
2679
  theme: d,
2659
- isCollapsed: g,
2680
+ isCollapsed: f,
2660
2681
  layout: _,
2661
2682
  toggleTheme: () => {
2662
2683
  t.toggleTheme();
@@ -2666,124 +2687,124 @@ function Qn() {
2666
2687
  }
2667
2688
  };
2668
2689
  }
2669
- function el() {
2670
- const t = re();
2690
+ function cl() {
2691
+ const t = ce();
2671
2692
  return {
2672
2693
  isLoggedIn: w(() => t.isLoggedIn)
2673
2694
  };
2674
2695
  }
2675
- function tl(t, n = {}) {
2676
- const { rules: u, onSubmit: s } = n, o = y(), i = He({ ...t }), h = y(!1), v = y(!1), d = y(!1), g = () => {
2677
- m(), d.value = !1, v.value = !0;
2678
- }, _ = (D) => {
2679
- Object.assign(i, D), d.value = !0, v.value = !0;
2680
- }, f = () => {
2681
- v.value = !1, m();
2682
- }, m = () => {
2683
- var D;
2684
- Object.keys(t).forEach((W) => {
2685
- i[W] = t[W];
2686
- }), (D = o.value) == null || D.resetFields();
2696
+ function ul(t, n = {}) {
2697
+ const { rules: m, onSubmit: o } = n, s = g(), h = Je({ ...t }), i = g(!1), v = g(!1), d = g(!1), f = () => {
2698
+ u(), d.value = !1, v.value = !0;
2699
+ }, _ = (A) => {
2700
+ Object.assign(h, A), d.value = !0, v.value = !0;
2701
+ }, k = () => {
2702
+ v.value = !1, u();
2703
+ }, u = () => {
2704
+ var A;
2705
+ Object.keys(t).forEach((j) => {
2706
+ h[j] = t[j];
2707
+ }), (A = s.value) == null || A.resetFields();
2687
2708
  };
2688
2709
  return {
2689
- formRef: o,
2690
- formData: i,
2691
- rules: u,
2692
- loading: h,
2710
+ formRef: s,
2711
+ formData: h,
2712
+ rules: m,
2713
+ loading: i,
2693
2714
  visible: v,
2694
2715
  isEdit: d,
2695
- openAdd: g,
2716
+ openAdd: f,
2696
2717
  openEdit: _,
2697
- close: f,
2698
- resetForm: m,
2718
+ close: k,
2719
+ resetForm: u,
2699
2720
  handleSubmit: async () => {
2700
- var D;
2721
+ var A;
2701
2722
  try {
2702
- await ((D = o.value) == null ? void 0 : D.validate()), h.value = !0, await (s == null ? void 0 : s(i)), f();
2703
- } catch (W) {
2704
- console.error(W);
2723
+ await ((A = s.value) == null ? void 0 : A.validate()), i.value = !0, await (o == null ? void 0 : o(h)), k();
2724
+ } catch (j) {
2725
+ console.error(j);
2705
2726
  } finally {
2706
- h.value = !1;
2727
+ i.value = !1;
2707
2728
  }
2708
2729
  }
2709
2730
  };
2710
2731
  }
2711
- function sl(t) {
2712
- const { fetchData: n, defaultPageSize: u = 10 } = t, s = y(!1), o = y([]), i = y(0), h = y(1), v = y(u), d = He({}), g = async () => {
2713
- s.value = !0;
2732
+ function dl(t) {
2733
+ const { fetchData: n, defaultPageSize: m = 10 } = t, o = g(!1), s = g([]), h = g(0), i = g(1), v = g(m), d = Je({}), f = async () => {
2734
+ o.value = !0;
2714
2735
  try {
2715
- const A = {
2736
+ const B = {
2716
2737
  ...d,
2717
- page: h.value,
2738
+ page: i.value,
2718
2739
  pageSize: v.value
2719
- }, V = await n(A);
2720
- o.value = V.list, i.value = V.total;
2721
- } catch (A) {
2722
- console.error(A);
2740
+ }, W = await n(B);
2741
+ s.value = W.list, h.value = W.total;
2742
+ } catch (B) {
2743
+ console.error(B);
2723
2744
  } finally {
2724
- s.value = !1;
2745
+ o.value = !1;
2725
2746
  }
2726
2747
  }, _ = () => {
2727
- h.value = 1, g();
2728
- }, f = () => {
2729
- Object.keys(d).forEach((A) => {
2730
- d[A] = void 0;
2731
- }), h.value = 1, g();
2732
- }, m = (A) => {
2733
- h.value = A, g();
2734
- }, j = (A) => {
2735
- v.value = A, h.value = 1, g();
2736
- }, D = () => {
2737
- g();
2738
- }, W = w(() => ({
2739
- current: h.value,
2748
+ i.value = 1, f();
2749
+ }, k = () => {
2750
+ Object.keys(d).forEach((B) => {
2751
+ d[B] = void 0;
2752
+ }), i.value = 1, f();
2753
+ }, u = (B) => {
2754
+ i.value = B, f();
2755
+ }, K = (B) => {
2756
+ v.value = B, i.value = 1, f();
2757
+ }, A = () => {
2758
+ f();
2759
+ }, j = w(() => ({
2760
+ current: i.value,
2740
2761
  pageSize: v.value,
2741
- total: i.value
2762
+ total: h.value
2742
2763
  }));
2743
2764
  return {
2744
- loading: s,
2745
- data: o,
2746
- total: i,
2747
- currentPage: h,
2765
+ loading: o,
2766
+ data: s,
2767
+ total: h,
2768
+ currentPage: i,
2748
2769
  pageSize: v,
2749
2770
  searchParams: d,
2750
- pagination: W,
2751
- getData: g,
2771
+ pagination: j,
2772
+ getData: f,
2752
2773
  handleSearch: _,
2753
- handleReset: f,
2754
- handlePageChange: m,
2755
- handleSizeChange: j,
2756
- refresh: D
2774
+ handleReset: k,
2775
+ handlePageChange: u,
2776
+ handleSizeChange: K,
2777
+ refresh: A
2757
2778
  };
2758
2779
  }
2759
- const Ze = Ue("locale", () => {
2760
- const t = E.get("locale") || "zh-CN", n = Et(t), u = y(t), s = Ut(), { t: o, messages: i, setLocale: h, mergeMessages: v } = zt(), d = w(() => {
2761
- const m = s.find((j) => j.code === u.value);
2762
- return (m == null ? void 0 : m.name) || u.value;
2780
+ const st = Fe("locale", () => {
2781
+ const t = T.get("locale") || "zh-CN", n = At(t), m = g(t), o = Bt(), { t: s, messages: h, setLocale: i, mergeMessages: v } = Vt(), d = w(() => {
2782
+ const u = o.find((K) => K.code === m.value);
2783
+ return (u == null ? void 0 : u.name) || m.value;
2763
2784
  });
2764
2785
  return {
2765
- locale: u,
2786
+ locale: m,
2766
2787
  localeName: d,
2767
- locales: s,
2768
- messages: i,
2769
- t: o,
2770
- changeLocale: (m) => {
2771
- u.value = m, h(m), E.set("locale", m), n.setLocale(m);
2788
+ locales: o,
2789
+ messages: h,
2790
+ t: s,
2791
+ changeLocale: (u) => {
2792
+ m.value = u, i(u), T.set("locale", u), n.setLocale(u);
2772
2793
  },
2773
- addMessages: (m) => {
2774
- v(m);
2794
+ addMessages: (u) => {
2795
+ v(u);
2775
2796
  },
2776
2797
  initLocale: () => {
2777
- h(t);
2798
+ i(t);
2778
2799
  },
2779
2800
  provider: n
2780
2801
  };
2781
- }), zn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2802
+ }), Rn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2782
2803
  __proto__: null,
2783
- useLocaleStore: Ze
2804
+ useLocaleStore: st
2784
2805
  }, Symbol.toStringTag, { value: "Module" }));
2785
- function ol() {
2786
- const t = Ze();
2806
+ function ml() {
2807
+ const t = st();
2787
2808
  return {
2788
2809
  /** 当前语言代码 */
2789
2810
  locale: t.locale,
@@ -2801,39 +2822,39 @@ function ol() {
2801
2822
  addMessages: t.addMessages
2802
2823
  };
2803
2824
  }
2804
- function al() {
2805
- return Ze().t;
2825
+ function pl() {
2826
+ return st().t;
2806
2827
  }
2807
- function nl(t) {
2808
- const n = re(), u = ve();
2809
- return n.isLoggedIn ? u.hasPermission(t) : !1;
2828
+ function vl(t) {
2829
+ const n = ce(), m = _e();
2830
+ return n.isLoggedIn ? m.hasPermission(t) : !1;
2810
2831
  }
2811
- function ll(t) {
2812
- return re().isLoggedIn;
2832
+ function hl(t) {
2833
+ return ce().isLoggedIn;
2813
2834
  }
2814
- function rl() {
2835
+ function _l() {
2815
2836
  return !0;
2816
2837
  }
2817
- const pt = [
2838
+ const ft = [
2818
2839
  {
2819
2840
  path: "/login",
2820
2841
  name: "Login",
2821
- component: () => Promise.resolve().then(() => kn),
2842
+ component: () => Promise.resolve().then(() => En),
2822
2843
  meta: {
2823
2844
  title: "登录",
2824
2845
  hidden: !0
2825
2846
  }
2826
2847
  }
2827
- ], vt = {
2848
+ ], gt = {
2828
2849
  path: "/",
2829
2850
  name: "Layout",
2830
- component: () => Promise.resolve().then(() => sn),
2851
+ component: () => Promise.resolve().then(() => mn),
2831
2852
  redirect: "/dashboard",
2832
2853
  children: [
2833
2854
  {
2834
2855
  path: "/dashboard",
2835
2856
  name: "Dashboard",
2836
- component: () => import("./index-DiRXF9DF.js"),
2857
+ component: () => import("./index-Biperpfs.js"),
2837
2858
  meta: {
2838
2859
  title: "仪表盘",
2839
2860
  icon: "dashboard",
@@ -2844,7 +2865,7 @@ const pt = [
2844
2865
  {
2845
2866
  path: "/system/user",
2846
2867
  name: "SystemUser",
2847
- component: () => import("./index-MrCwrOqR.js"),
2868
+ component: () => import("./index-BL_15V_t.js"),
2848
2869
  meta: {
2849
2870
  title: "用户管理",
2850
2871
  icon: "user",
@@ -2854,7 +2875,7 @@ const pt = [
2854
2875
  {
2855
2876
  path: "/system/role",
2856
2877
  name: "SystemRole",
2857
- component: () => import("./index-B2_D0EED.js"),
2878
+ component: () => import("./index-Bv0RBhQX.js"),
2858
2879
  meta: {
2859
2880
  title: "角色管理",
2860
2881
  icon: "role",
@@ -2864,7 +2885,7 @@ const pt = [
2864
2885
  {
2865
2886
  path: "/system/menu",
2866
2887
  name: "SystemMenu",
2867
- component: () => import("./index-CZsvJ9LK.js"),
2888
+ component: () => import("./index-BTlDtwrl.js"),
2868
2889
  meta: {
2869
2890
  title: "菜单管理",
2870
2891
  icon: "menu",
@@ -2875,18 +2896,18 @@ const pt = [
2875
2896
  {
2876
2897
  path: "/:pathMatch(.*)*",
2877
2898
  name: "CatchAll",
2878
- component: () => Promise.resolve().then(() => mt),
2899
+ component: () => Promise.resolve().then(() => _t),
2879
2900
  meta: {
2880
2901
  title: "404",
2881
2902
  hidden: !0
2882
2903
  }
2883
2904
  }
2884
2905
  ]
2885
- }, il = [
2906
+ }, fl = [
2886
2907
  {
2887
2908
  path: "/dashboard",
2888
2909
  name: "Dashboard",
2889
- component: () => import("./index-DiRXF9DF.js"),
2910
+ component: () => import("./index-Biperpfs.js"),
2890
2911
  meta: {
2891
2912
  title: "仪表盘",
2892
2913
  icon: "dashboard",
@@ -2906,7 +2927,7 @@ const pt = [
2906
2927
  {
2907
2928
  path: "user",
2908
2929
  name: "SystemUser",
2909
- component: () => import("./index-MrCwrOqR.js"),
2930
+ component: () => import("./index-BL_15V_t.js"),
2910
2931
  meta: {
2911
2932
  title: "用户管理",
2912
2933
  icon: "user",
@@ -2916,7 +2937,7 @@ const pt = [
2916
2937
  {
2917
2938
  path: "role",
2918
2939
  name: "SystemRole",
2919
- component: () => import("./index-B2_D0EED.js"),
2940
+ component: () => import("./index-Bv0RBhQX.js"),
2920
2941
  meta: {
2921
2942
  title: "角色管理",
2922
2943
  icon: "role",
@@ -2926,7 +2947,7 @@ const pt = [
2926
2947
  {
2927
2948
  path: "menu",
2928
2949
  name: "SystemMenu",
2929
- component: () => import("./index-CZsvJ9LK.js"),
2950
+ component: () => import("./index-BTlDtwrl.js"),
2930
2951
  meta: {
2931
2952
  title: "菜单管理",
2932
2953
  icon: "menu",
@@ -2935,7 +2956,7 @@ const pt = [
2935
2956
  }
2936
2957
  ]
2937
2958
  }
2938
- ], Pn = [
2959
+ ], Kn = [
2939
2960
  {
2940
2961
  menuCode: "dashboard",
2941
2962
  menuName: "仪表盘",
@@ -2983,20 +3004,20 @@ const pt = [
2983
3004
  }
2984
3005
  ]
2985
3006
  }
2986
- ], ht = Ye({
2987
- history: Ge(),
2988
- routes: [...pt, vt],
3007
+ ], yt = Ze({
3008
+ history: Qe(),
3009
+ routes: [...ft, gt],
2989
3010
  scrollBehavior: () => ({ left: 0, top: 0 })
2990
- }), Tn = ["/login"];
2991
- ht.beforeEach(async (t, n, u) => {
2992
- const s = pe();
2993
- if (s.initTheme(), nt())
3011
+ }), jn = ["/login"];
3012
+ yt.beforeEach(async (t, n, m) => {
3013
+ const o = he();
3014
+ if (o.initTheme(), ct())
2994
3015
  if (t.path === "/login")
2995
- u({ path: "/" });
3016
+ m({ path: "/" });
2996
3017
  else {
2997
- const o = re();
2998
- o.isLoggedIn || (o.setUserInfo({
2999
- appId: Ie(),
3018
+ const s = ce();
3019
+ s.isLoggedIn || (s.setUserInfo({
3020
+ appId: Ne(),
3000
3021
  userId: "1",
3001
3022
  userName: "管理员",
3002
3023
  departmentName: "技术部",
@@ -3004,23 +3025,23 @@ ht.beforeEach(async (t, n, u) => {
3004
3025
  mobilePhone: "13800138000",
3005
3026
  positionName: "管理员",
3006
3027
  avatar: ""
3007
- }), ve().setMenuList(Pn)), t.name && t.meta.keepAlive && s.addCachedView(t.name), u();
3028
+ }), _e().setMenuList(Kn)), t.name && t.meta.keepAlive && o.addCachedView(t.name), m();
3008
3029
  }
3009
3030
  else
3010
- Tn.includes(t.path) ? u() : u("/login");
3031
+ jn.includes(t.path) ? m() : m("/login");
3011
3032
  });
3012
- function cl() {
3013
- const t = Ye({
3014
- history: Ge(),
3015
- routes: [...pt, vt]
3033
+ function gl() {
3034
+ const t = Ze({
3035
+ history: Qe(),
3036
+ routes: [...ft, gt]
3016
3037
  });
3017
- ht.matcher = t.matcher;
3038
+ yt.matcher = t.matcher;
3018
3039
  }
3019
- function ul(t, n = {}) {
3020
- const u = n.indexPath || "/dashboard", s = n.logoSrc || Ee("/vite.svg"), o = {
3040
+ function yl(t, n = {}) {
3041
+ const m = n.indexPath || "/dashboard", o = n.logoSrc, s = {
3021
3042
  path: "/:pathMatch(.*)*",
3022
3043
  name: "CatchAll",
3023
- component: () => Promise.resolve().then(() => mt),
3044
+ component: () => Promise.resolve().then(() => _t),
3024
3045
  meta: {
3025
3046
  title: "404"
3026
3047
  }
@@ -3028,84 +3049,84 @@ function ul(t, n = {}) {
3028
3049
  return {
3029
3050
  path: "/",
3030
3051
  name: "Layout",
3031
- component: le({
3052
+ component: ie({
3032
3053
  name: "LayoutWrapper",
3033
3054
  render() {
3034
- return $t(dt, { logoSrc: s });
3055
+ return Ut(ht, { logoSrc: o || ze("/vite.svg") });
3035
3056
  }
3036
3057
  }),
3037
- redirect: u,
3038
- children: [...t, o]
3058
+ redirect: m,
3059
+ children: [...t, s]
3039
3060
  };
3040
3061
  }
3041
- function dl(t, n = {}) {
3042
- const u = n.base || ft();
3043
- return Ye({
3044
- history: Ge(u),
3062
+ function bl(t, n = {}) {
3063
+ const m = n.base || kt();
3064
+ return Ze({
3065
+ history: Qe(m),
3045
3066
  routes: t,
3046
3067
  scrollBehavior: () => ({ left: 0, top: 0 })
3047
3068
  });
3048
3069
  }
3049
- const Fn = ["login", "404", "403", "/login", "/404", "/403"];
3050
- function Dn(t, n) {
3070
+ const Wn = ["login", "404", "403", "/login", "/404", "/403"];
3071
+ function qn(t, n) {
3051
3072
  if (n.includes(t)) return !0;
3052
- const u = t.startsWith("/") ? t.slice(1) : t;
3053
- return n.includes(u);
3073
+ const m = t.startsWith("/") ? t.slice(1) : t;
3074
+ return n.includes(m);
3054
3075
  }
3055
- function ml(t, n = {}) {
3056
- const u = n.whiteList || Fn;
3057
- t.beforeEach(async (s, o, i) => {
3058
- const h = pe(), v = re(), d = ve(), g = h.loginPath || n.loginPath || "/login";
3059
- if (h.initTheme(), at())
3060
- if (s.path === g || s.name === "Login")
3061
- i({ name: "Dashboard" });
3076
+ function wl(t, n = {}) {
3077
+ const m = n.whiteList || Wn;
3078
+ t.beforeEach(async (o, s, h) => {
3079
+ const i = he(), v = ce(), d = _e(), f = i.loginPath || n.loginPath || "/login";
3080
+ if (i.initTheme(), it())
3081
+ if (o.path === f || o.name === "Login")
3082
+ h({ name: "Dashboard" });
3062
3083
  else if (v.isLoggedIn) {
3063
3084
  if (!d.hasMenu)
3064
3085
  try {
3065
- const f = n.fetchMenu ? await n.fetchMenu() : await et(n.appId);
3066
- d.setMenuList(f);
3067
- } catch (f) {
3068
- console.warn("补拉菜单失败:", f);
3086
+ const k = n.fetchMenu ? await n.fetchMenu() : await at(n.appId);
3087
+ d.setMenuList(k);
3088
+ } catch (k) {
3089
+ console.warn("补拉菜单失败:", k);
3069
3090
  }
3070
- s.name && s.meta.keepAlive && h.addCachedView(s.name), i();
3091
+ o.name && o.meta.keepAlive && i.addCachedView(o.name), h();
3071
3092
  } else
3072
3093
  try {
3073
3094
  if (n.fetchUserInfo) {
3074
- const f = await n.fetchUserInfo();
3075
- v.setUserInfo(f);
3095
+ const k = await n.fetchUserInfo();
3096
+ v.setUserInfo(k);
3076
3097
  } else {
3077
- const f = await gt();
3078
- v.setUserInfo(f);
3098
+ const k = await xt();
3099
+ v.setUserInfo(k);
3079
3100
  }
3080
3101
  if (n.fetchMenu) {
3081
- const f = await n.fetchMenu();
3082
- d.setMenuList(f);
3102
+ const k = await n.fetchMenu();
3103
+ d.setMenuList(k);
3083
3104
  } else {
3084
- const f = await et(n.appId);
3085
- d.setMenuList(f);
3105
+ const k = await at(n.appId);
3106
+ d.setMenuList(k);
3086
3107
  }
3087
- n.onLoginSuccess && n.onLoginSuccess(), s.name && s.meta.keepAlive && h.addCachedView(s.name), i({ ...s, replace: !0 });
3088
- } catch (f) {
3089
- console.error("获取用户信息失败:", f), v.clearUserInfo(), d.clearMenu(), lt(), i({ name: "Login", query: { redirect: s.fullPath } });
3108
+ n.onLoginSuccess && n.onLoginSuccess(), o.name && o.meta.keepAlive && i.addCachedView(o.name), h({ ...o, replace: !0 });
3109
+ } catch (k) {
3110
+ console.error("获取用户信息失败:", k), v.clearUserInfo(), d.clearMenu(), ut(), h({ name: "Login", query: { redirect: o.fullPath } });
3090
3111
  }
3091
3112
  else
3092
- Dn(s.path, u) || s.name === "Login" || s.name === "NotFound" || s.name === "Forbidden" ? i() : i({ name: "Login", query: { redirect: s.fullPath } });
3113
+ qn(o.path, m) || o.name === "Login" || o.name === "NotFound" || o.name === "Forbidden" ? h() : h({ name: "Login", query: { redirect: o.fullPath } });
3093
3114
  }), t.afterEach(() => {
3094
3115
  });
3095
3116
  }
3096
- var An = /* @__PURE__ */ ((t) => (t[t.ENABLED = 1] = "ENABLED", t[t.DISABLED = 0] = "DISABLED", t))(An || {}), Bn = /* @__PURE__ */ ((t) => (t[t.UNKNOWN = 0] = "UNKNOWN", t[t.MALE = 1] = "MALE", t[t.FEMALE = 2] = "FEMALE", t))(Bn || {}), Vn = /* @__PURE__ */ ((t) => (t[t.DIRECTORY = 0] = "DIRECTORY", t[t.MENU = 1] = "MENU", t[t.BUTTON = 2] = "BUTTON", t))(Vn || {});
3097
- const pl = {
3117
+ var Hn = /* @__PURE__ */ ((t) => (t[t.ENABLED = 1] = "ENABLED", t[t.DISABLED = 0] = "DISABLED", t))(Hn || {}), Yn = /* @__PURE__ */ ((t) => (t[t.UNKNOWN = 0] = "UNKNOWN", t[t.MALE = 1] = "MALE", t[t.FEMALE = 2] = "FEMALE", t))(Yn || {}), Gn = /* @__PURE__ */ ((t) => (t[t.DIRECTORY = 0] = "DIRECTORY", t[t.MENU = 1] = "MENU", t[t.BUTTON = 2] = "BUTTON", t))(Gn || {});
3118
+ const kl = {
3098
3119
  1: "启用",
3099
3120
  0: "禁用"
3100
- }, vl = {
3121
+ }, xl = {
3101
3122
  0: "未知",
3102
3123
  1: "男",
3103
3124
  2: "女"
3104
- }, hl = {
3125
+ }, Cl = {
3105
3126
  0: "目录",
3106
3127
  1: "菜单",
3107
3128
  2: "按钮"
3108
- }, _l = [
3129
+ }, $l = [
3109
3130
  {
3110
3131
  label: "启用",
3111
3132
  value: 1
@@ -3116,7 +3137,7 @@ const pl = {
3116
3137
  value: 0
3117
3138
  /* DISABLED */
3118
3139
  }
3119
- ], fl = [
3140
+ ], Ll = [
3120
3141
  {
3121
3142
  label: "未知",
3122
3143
  value: 0
@@ -3132,7 +3153,7 @@ const pl = {
3132
3153
  value: 2
3133
3154
  /* FEMALE */
3134
3155
  }
3135
- ], gl = [
3156
+ ], Ml = [
3136
3157
  {
3137
3158
  label: "目录",
3138
3159
  value: 0
@@ -3148,37 +3169,49 @@ const pl = {
3148
3169
  value: 2
3149
3170
  /* BUTTON */
3150
3171
  }
3151
- ], yl = {
3172
+ ], Sl = {
3152
3173
  mounted(t, n) {
3153
- var h, v;
3154
- const u = re(), s = ve();
3155
- if (!u.isLoggedIn) {
3156
- (h = t.parentNode) == null || h.removeChild(t);
3174
+ var i, v;
3175
+ const m = ce(), o = _e();
3176
+ if (!m.isLoggedIn) {
3177
+ (i = t.parentNode) == null || i.removeChild(t);
3157
3178
  return;
3158
3179
  }
3159
- const o = n.value, i = Array.isArray(o) ? o : [o];
3160
- s.hasPermission(i) || (v = t.parentNode) == null || v.removeChild(t);
3180
+ const s = n.value, h = Array.isArray(s) ? s : [s];
3181
+ o.hasPermission(h) || (v = t.parentNode) == null || v.removeChild(t);
3161
3182
  }
3162
3183
  };
3163
- async function bl(t) {
3164
- await yt(t.basePath);
3165
- const n = tt();
3166
- return n && bt(n), kt({
3184
+ async function Nl(t) {
3185
+ await Ct(t.basePath);
3186
+ const n = nt();
3187
+ n && $t(n), Lt({
3167
3188
  appId: t.appId,
3168
3189
  clientId: t.clientId,
3169
3190
  apiBaseUrl: n || t.apiBaseUrl,
3170
3191
  basePath: t.basePath
3171
- }), t.basePath && wt(t.basePath), Promise.resolve().then(() => Tt).then(({ useAppStore: u }) => {
3172
- const s = u();
3192
+ }), t.basePath && Mt(t.basePath);
3193
+ const m = t.appId || Ne();
3194
+ if (m)
3195
+ try {
3196
+ const o = await Promise.race([
3197
+ St(m),
3198
+ new Promise((s) => setTimeout(() => s(null), 2e3))
3199
+ ]);
3200
+ o && typeof o == "object" && Nt(o);
3201
+ } catch (o) {
3202
+ console.warn("加载应用界面配置失败,使用内置默认", o);
3203
+ }
3204
+ return Promise.resolve().then(() => Kt).then(({ useAppStore: o }) => {
3205
+ const s = o();
3173
3206
  t.appName && s.setAppName(t.appName), t.indexPath && s.setIndexPath(t.indexPath), t.loginPath && s.setLoginPath(t.loginPath);
3174
- }), t.locale && Promise.resolve().then(() => zn).then(({ useLocaleStore: u }) => {
3175
- u().changeLocale(t.locale);
3207
+ }), t.locale && Promise.resolve().then(() => Rn).then(({ useLocaleStore: o }) => {
3208
+ o().changeLocale(t.locale);
3176
3209
  }), {
3177
3210
  config: {
3178
3211
  appName: t.appName || "XTO App",
3179
- appId: Ie(),
3180
- clientId: it(),
3181
- apiBaseUrl: tt(),
3212
+ appId: Ne(),
3213
+ clientId: mt(),
3214
+ apiBaseUrl: nt(),
3182
3215
  basePath: t.basePath || "/",
3183
3216
  indexPath: t.indexPath || "/dashboard",
3184
3217
  loginPath: t.loginPath || "/login",
@@ -3187,47 +3220,47 @@ async function bl(t) {
3187
3220
  };
3188
3221
  }
3189
3222
  export {
3190
- pe as A,
3191
- el as B,
3192
- ze as C,
3193
- tl as D,
3194
- ol as E,
3195
- Jn as F,
3196
- Bn as G,
3197
- Ks as H,
3198
- Ze as I,
3199
- ve as J,
3200
- sl as K,
3201
- dt as L,
3202
- Vn as M,
3203
- re as N,
3204
- An as S,
3205
- Xn as T,
3206
- ie as _,
3207
- _l as a,
3208
- gl as b,
3209
- Zn as c,
3210
- fl as d,
3211
- vl as e,
3212
- hl as f,
3213
- Mn as g,
3214
- ot as h,
3215
- bn as i,
3216
- pl as j,
3217
- ul as k,
3218
- dl as l,
3219
- al as m,
3220
- bl as n,
3221
- il as o,
3222
- nl as p,
3223
- ll as q,
3224
- rl as r,
3225
- vt as s,
3226
- Pn as t,
3227
- yl as u,
3228
- cl as v,
3229
- ht as w,
3230
- ml as x,
3231
- pt as y,
3232
- Qn as z
3223
+ he as A,
3224
+ cl as B,
3225
+ De as C,
3226
+ ul as D,
3227
+ ml as E,
3228
+ ll as F,
3229
+ Yn as G,
3230
+ Zs as H,
3231
+ st as I,
3232
+ _e as J,
3233
+ dl as K,
3234
+ ht as L,
3235
+ Gn as M,
3236
+ ce as N,
3237
+ Hn as S,
3238
+ nl as T,
3239
+ ue as _,
3240
+ $l as a,
3241
+ Ml as b,
3242
+ rl as c,
3243
+ Ll as d,
3244
+ xl as e,
3245
+ Cl as f,
3246
+ Fn as g,
3247
+ rt as h,
3248
+ Nn as i,
3249
+ kl as j,
3250
+ yl as k,
3251
+ bl as l,
3252
+ pl as m,
3253
+ Nl as n,
3254
+ fl as o,
3255
+ vl as p,
3256
+ hl as q,
3257
+ _l as r,
3258
+ gt as s,
3259
+ Kn as t,
3260
+ Sl as u,
3261
+ gl as v,
3262
+ yt as w,
3263
+ wl as x,
3264
+ ft as y,
3265
+ il as z
3233
3266
  };