@skyfox2000/webui 1.0.13 → 1.2.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.
Files changed (162) hide show
  1. package/lib/assets/modules/file-upload-CBUcsUnR.js +170 -0
  2. package/lib/assets/modules/form-validate-CgX7aR7T.js +297 -0
  3. package/lib/assets/modules/index-Civhd8xG.js +112 -0
  4. package/lib/assets/modules/index-DQMdt51R.js +726 -0
  5. package/lib/assets/modules/{index-BEWJ_qAH.js → index-DmWrkTXX.js} +1 -1
  6. package/lib/assets/modules/{menuTabs-BXdbFZor.js → menuTabs-BRYvFWA-.js} +131 -121
  7. package/lib/assets/modules/settingInfo-BZakNKIN.js +999 -0
  8. package/lib/assets/modules/uploadList-B7XoxGOh.js +278 -0
  9. package/lib/components/common/icon/index.vue.d.ts +1 -1
  10. package/lib/components/content/dialog/index.vue.d.ts +1 -1
  11. package/lib/components/content/drawer/index.vue.d.ts +1 -1
  12. package/lib/components/content/form/index.vue.d.ts +1 -1
  13. package/lib/components/content/search/index.vue.d.ts +1 -1
  14. package/lib/components/content/table/index.vue.d.ts +1 -1
  15. package/lib/components/content/table/tableOperate.vue.d.ts +1 -1
  16. package/lib/components/content/toolbar/icontool.vue.d.ts +1 -1
  17. package/lib/components/content/toolbar/index.vue.d.ts +1 -1
  18. package/lib/components/content/tree/index.vue.d.ts +1 -1
  19. package/lib/components/form/transfer/transferTable.vue.d.ts +1 -1
  20. package/lib/components/form/treeSelect/index.vue.d.ts +1 -1
  21. package/lib/components/form/upload/uploadList.vue.d.ts +1 -1
  22. package/lib/const/options.d.ts +32 -0
  23. package/lib/directives/enter-submit.d.ts +4 -0
  24. package/lib/directives/index.d.ts +2 -0
  25. package/lib/directives/permission.d.ts +5 -0
  26. package/lib/es/AceEditor/index.js +9 -8
  27. package/lib/es/BasicLayout/index.js +28 -24
  28. package/lib/es/Error403/index.js +15 -10
  29. package/lib/es/Error404/index.js +15 -10
  30. package/lib/es/ExcelForm/index.js +380 -175
  31. package/lib/es/UploadForm/index.js +23 -20
  32. package/lib/index.d.ts +42 -2
  33. package/lib/router/index.d.ts +16 -0
  34. package/lib/stores/appInfo.d.ts +34 -0
  35. package/lib/stores/hostInfo.d.ts +9 -0
  36. package/lib/stores/pageInfo.d.ts +18 -0
  37. package/lib/stores/pinia.d.ts +3 -0
  38. package/lib/stores/settingInfo.d.ts +8 -0
  39. package/lib/stores/userInfo.d.ts +21 -0
  40. package/lib/typings/data.d.ts +80 -0
  41. package/lib/typings/form.d.ts +171 -0
  42. package/lib/typings/menu.d.ts +7 -0
  43. package/lib/typings/option.d.ts +175 -0
  44. package/lib/typings/page.d.ts +69 -0
  45. package/lib/typings/table.d.ts +181 -0
  46. package/lib/typings/tools.d.ts +130 -0
  47. package/lib/typings/tree.d.ts +72 -0
  48. package/lib/typings/upload.d.ts +161 -0
  49. package/lib/typings/urls.d.ts +69 -0
  50. package/lib/utils/cache.d.ts +23 -0
  51. package/lib/utils/data.d.ts +6 -0
  52. package/lib/utils/download.d.ts +4 -0
  53. package/lib/utils/eventbus.d.ts +16 -0
  54. package/lib/utils/export-table.d.ts +12 -0
  55. package/lib/utils/file-upload.d.ts +15 -0
  56. package/lib/utils/form-excel.d.ts +30 -0
  57. package/lib/utils/form-validate.d.ts +29 -0
  58. package/lib/utils/form.d.ts +9 -0
  59. package/lib/utils/icon-loader.d.ts +125 -0
  60. package/lib/utils/isEmpty.d.ts +1 -0
  61. package/lib/utils/main-openapis.d.ts +9 -0
  62. package/lib/utils/menu.d.ts +6 -0
  63. package/lib/utils/options.d.ts +10 -0
  64. package/lib/utils/page.d.ts +25 -0
  65. package/lib/utils/table.d.ts +21 -0
  66. package/lib/utils/tools.d.ts +18 -0
  67. package/lib/utils/tree.d.ts +3 -0
  68. package/lib/vite-env.d.ts +8 -0
  69. package/lib/webui.css +1 -1
  70. package/lib/webui.es.js +1020 -854
  71. package/package.json +7 -6
  72. package/src/components/common/icon/appicon.vue +1 -1
  73. package/src/components/common/icon/fullscreen.vue +2 -1
  74. package/src/components/common/icon/index.vue +1 -1
  75. package/src/components/common/icon/layoutIcon.vue +1 -1
  76. package/src/components/common/icon/projectIcon.vue +1 -1
  77. package/src/components/common/icon/toolIcon.vue +1 -1
  78. package/src/components/content/dialog/excelForm.vue +2 -2
  79. package/src/components/content/dialog/index.vue +1 -1
  80. package/src/components/content/dialog/uploadForm.vue +7 -6
  81. package/src/components/content/drawer/index.vue +43 -18
  82. package/src/components/content/form/formItem.vue +1 -1
  83. package/src/components/content/form/index.vue +1 -1
  84. package/src/components/content/search/index.vue +1 -1
  85. package/src/components/content/search/searchItem.vue +1 -1
  86. package/src/components/content/table/index.vue +8 -5
  87. package/src/components/content/table/tableOperate.vue +8 -4
  88. package/src/components/content/toolbar/icontool.vue +2 -2
  89. package/src/components/content/toolbar/index.vue +9 -5
  90. package/src/components/content/tree/index.vue +1 -1
  91. package/src/components/error/error403.vue +2 -2
  92. package/src/components/error/error404.vue +2 -2
  93. package/src/components/form/autoComplete/index.vue +1 -1
  94. package/src/components/form/cascader/index.vue +1 -2
  95. package/src/components/form/checkbox/index.vue +11 -5
  96. package/src/components/form/datePicker/index.vue +1 -1
  97. package/src/components/form/input/index.vue +1 -1
  98. package/src/components/form/input/inputNumber.vue +1 -1
  99. package/src/components/form/input/inputPassword.vue +1 -1
  100. package/src/components/form/radio/index.vue +1 -1
  101. package/src/components/form/radio/radioStatus.vue +1 -1
  102. package/src/components/form/rangePicker/index.vue +1 -1
  103. package/src/components/form/select/index.vue +1 -1
  104. package/src/components/form/switch/index.vue +7 -3
  105. package/src/components/form/textarea/index.vue +1 -1
  106. package/src/components/form/transfer/index.vue +1 -1
  107. package/src/components/form/transfer/transferTable.vue +42 -22
  108. package/src/components/form/treeSelect/index.vue +2 -3
  109. package/src/components/form/upload/uploadList.vue +1 -1
  110. package/src/components/layout/breadcrumb/index.vue +1 -1
  111. package/src/components/layout/header/headerExits.vue +1 -1
  112. package/src/components/layout/header/index.vue +1 -1
  113. package/src/components/layout/header/user.vue +2 -1
  114. package/src/components/layout/menu/index.vue +9 -3
  115. package/src/components/layout/menu/menuTabs.vue +10 -12
  116. package/src/components/layout/page/basicLayout.vue +1 -1
  117. package/src/const/options.ts +114 -0
  118. package/src/directives/enter-submit.ts +13 -0
  119. package/src/directives/index.ts +26 -0
  120. package/src/directives/permission.ts +144 -0
  121. package/src/index.ts +201 -0
  122. package/src/router/index.ts +196 -0
  123. package/src/stores/appInfo.ts +471 -0
  124. package/src/stores/hostInfo.ts +117 -0
  125. package/src/stores/pageInfo.ts +131 -0
  126. package/src/stores/pinia.ts +10 -0
  127. package/src/stores/settingInfo.ts +53 -0
  128. package/src/stores/userInfo.ts +392 -0
  129. package/src/typings/data.d.ts +81 -0
  130. package/src/typings/form.d.ts +172 -0
  131. package/src/typings/menu.d.ts +7 -0
  132. package/src/typings/option.d.ts +177 -0
  133. package/src/typings/page.d.ts +70 -0
  134. package/src/typings/table.d.ts +182 -0
  135. package/src/typings/tools.d.ts +131 -0
  136. package/src/typings/tree.d.ts +73 -0
  137. package/src/typings/upload.d.ts +162 -0
  138. package/src/typings/urls.d.ts +70 -0
  139. package/src/utils/cache.ts +175 -0
  140. package/src/utils/data.ts +189 -0
  141. package/src/utils/download.ts +80 -0
  142. package/src/utils/eventbus.ts +78 -0
  143. package/src/utils/export-table.ts +155 -0
  144. package/src/utils/file-upload.ts +304 -0
  145. package/src/utils/form-excel.ts +523 -0
  146. package/src/utils/form-validate.ts +368 -0
  147. package/src/utils/form.ts +188 -0
  148. package/src/utils/icon-loader.ts +412 -0
  149. package/src/utils/isEmpty.ts +18 -0
  150. package/src/utils/main-openapis.ts +72 -0
  151. package/src/utils/menu.ts +89 -0
  152. package/src/utils/options.ts +324 -0
  153. package/src/utils/page.ts +262 -0
  154. package/src/utils/table.ts +274 -0
  155. package/src/utils/tools.ts +362 -0
  156. package/src/utils/tree.ts +28 -0
  157. package/tsconfig.json +1 -8
  158. package/vite.config.ts +7 -4
  159. package/lib/assets/modules/index-BahGnrAq.js +0 -415
  160. package/lib/assets/modules/index-BoKIa2sr.js +0 -109
  161. package/lib/assets/modules/index-D47Ci-T3.js +0 -107
  162. package/lib/assets/modules/uploadList-Dzlg47V0.js +0 -182
@@ -1,7 +1,7 @@
1
1
  import { defineComponent as i, createBlock as s, openBlock as l, unref as a, withCtx as p, renderSlot as f, createCommentVNode as u, mergeProps as d } from "vue";
2
2
  import { Tooltip as I } from "ant-design-vue";
3
3
  import { SERVER_HOST as r } from "@skyfox2000/fapi";
4
- import { createFromIconfont as S } from "@skyfox2000/webbase";
4
+ import { c as S } from "./settingInfo-BZakNKIN.js";
5
5
  const T = /* @__PURE__ */ i({
6
6
  __name: "index",
7
7
  props: {
@@ -1,28 +1,31 @@
1
- import { defineComponent as _, createBlock as v, createCommentVNode as I, openBlock as p, unref as t, mergeProps as C, useAttrs as D, computed as P, ref as h, watch as S, withCtx as m, createElementBlock as g, normalizeStyle as T, createElementVNode as x, inject as q, onMounted as U, createVNode as u, toDisplayString as R, Fragment as L, createTextVNode as O, reactive as J, nextTick as W, renderList as G, withModifiers as Q } from "vue";
2
- import { a as A, _ as k } from "./index-BEWJ_qAH.js";
3
- import { createFromIconfont as V, getIconTransform as j, usePageInfo as B, showBreadcrumb as K, crumbs as E, useUserInfo as F, useSettingInfo as H, initMenu as X, AppRouter as Y, useAppInfo as w } from "@skyfox2000/webbase";
1
+ import { defineComponent as _, createBlock as y, createCommentVNode as I, openBlock as p, unref as t, mergeProps as C, useAttrs as q, computed as P, ref as h, watch as k, withCtx as m, createElementBlock as g, normalizeStyle as T, createElementVNode as x, inject as J, onMounted as U, createVNode as u, toDisplayString as R, Fragment as L, createTextVNode as O, reactive as W, nextTick as G, renderList as Q, withModifiers as X } from "vue";
2
+ import { a as w, _ as b } from "./index-DmWrkTXX.js";
3
+ import { c as F, g as j, e as B, s as K, f as E, b as H, u as V, i as Y, r as D, d as A } from "./settingInfo-BZakNKIN.js";
4
4
  import { theme as N, Breadcrumb as Z, Modal as ee, Flex as te, LayoutHeader as ne, Space as oe, Menu as se, Tabs as ie, TabPane as ce } from "ant-design-vue";
5
- import { SERVER_HOST as z } from "@skyfox2000/fapi";
6
5
  import { mainAppApis as M } from "@skyfox2000/microbase";
7
- const le = /* @__PURE__ */ _({
6
+ import { SERVER_HOST as z } from "@skyfox2000/fapi";
7
+ import "vue-m-message";
8
+ import "async-validator";
9
+ import "dayjs";
10
+ const ae = /* @__PURE__ */ _({
8
11
  __name: "appicon",
9
12
  props: {
10
13
  icon: {
11
14
  type: String
12
15
  }
13
16
  },
14
- setup(o) {
15
- const c = o, e = V({
17
+ setup(s) {
18
+ const c = s, e = F({
16
19
  iconUrl: `${z.APP_ICONS}`,
17
20
  icon: c.icon
18
21
  });
19
- return (a, l) => o.icon ? (p(), v(t(e), C({
22
+ return (l, a) => s.icon ? (p(), y(t(e), C({
20
23
  key: 0,
21
- icon: o.icon,
24
+ icon: s.icon,
22
25
  class: ["text-2xl", "align-middle", "w-6", "h-6"]
23
- }, a.$attrs), null, 16, ["icon"])) : I("", !0);
26
+ }, l.$attrs), null, 16, ["icon"])) : I("", !0);
24
27
  }
25
- }), ae = ["xlink:href"], re = /* @__PURE__ */ _({
28
+ }), le = ["xlink:href"], re = /* @__PURE__ */ _({
26
29
  inheritAttrs: !1,
27
30
  __name: "index",
28
31
  props: {
@@ -266,63 +269,63 @@ const le = /* @__PURE__ */ _({
266
269
  */
267
270
  "update:iconIndex"
268
271
  ],
269
- setup(o, { emit: c }) {
270
- const i = D(), e = o, a = c, l = P(() => {
272
+ setup(s, { emit: c }) {
273
+ const i = q(), e = s, l = c, a = P(() => {
271
274
  if (Array.isArray(e.size)) return e.size;
272
275
  {
273
- let n = e.size;
274
- return [n, n];
276
+ let o = e.size;
277
+ return [o, o];
275
278
  }
276
- }), s = h(e.icon), d = h(e.iconIndex);
277
- S(
279
+ }), n = h(e.icon), d = h(e.iconIndex);
280
+ k(
278
281
  () => e.icon,
279
- (n) => {
280
- s.value = n;
282
+ (o) => {
283
+ n.value = o;
281
284
  }
282
- ), S(
285
+ ), k(
283
286
  () => e.iconIndex,
284
- (n) => {
285
- d.value = n, s.value = e.icons[n];
287
+ (o) => {
288
+ d.value = o, n.value = e.icons[o];
286
289
  }
287
290
  );
288
291
  const r = P({
289
292
  get() {
290
293
  return d.value;
291
294
  },
292
- set(n) {
293
- d.value = n, a("update:iconIndex", d.value);
295
+ set(o) {
296
+ d.value = o, l("update:iconIndex", d.value);
294
297
  }
295
298
  });
296
- e.icons.length > 0 ? (r.value = r.value >= e.icons.length ? 0 : r.value, s.value = e.icons[d.value]) : s.value = e.icon;
297
- const b = (n) => {
298
- if (n.stopPropagation(), e.clickEvent) {
299
- const y = e.clickEvent.split("#");
300
- y.length === 2 && q("$" + y[0]).$emit(y[1], e.data);
299
+ e.icons.length > 0 ? (r.value = r.value >= e.icons.length ? 0 : r.value, n.value = e.icons[d.value]) : n.value = e.icon;
300
+ const S = (o) => {
301
+ if (o.stopPropagation(), e.clickEvent) {
302
+ const v = e.clickEvent.split("#");
303
+ v.length === 2 && J("$" + v[0]).$emit(v[1], e.data);
301
304
  }
302
- e.autoSwitch && e.icons.length > 0 && (r.value = (r.value + 1) % e.icons.length, s.value = e.icons[d.value]), a("click");
305
+ e.autoSwitch && e.icons.length > 0 && (r.value = (r.value + 1) % e.icons.length, n.value = e.icons[d.value]), l("click");
303
306
  }, f = () => {
304
- let n = "";
305
- return e.spin && (n += "rotate"), e.flip && (n += " flip"), n;
307
+ let o = "";
308
+ return e.spin && (o += "rotate"), e.flip && (o += " flip"), o;
306
309
  };
307
- return (n, y) => (p(), v(A, {
310
+ return (o, v) => (p(), y(w, {
308
311
  title: e.tiptext,
309
312
  disabled: e.tiptext ? void 0 : "disabled",
310
- color: o.tipcolor,
311
- placement: o.placement,
312
- size: o.tipsize
313
+ color: s.tipcolor,
314
+ placement: s.placement,
315
+ size: s.tipsize
313
316
  }, {
314
317
  default: m(() => {
315
318
  var $;
316
319
  return [
317
- s.value ? (p(), g("div", {
320
+ n.value ? (p(), g("div", {
318
321
  key: 0,
319
322
  class: "re-icon-container",
320
323
  style: T({
321
- width: l.value[0].toString(),
322
- height: l.value[1].toString()
324
+ width: a.value[0].toString(),
325
+ height: a.value[1].toString()
323
326
  })
324
327
  }, [
325
- ($ = s.value) != null && $.startsWith("sym-") ? (p(), g("svg", C({ key: 1 }, t(i), {
328
+ ($ = n.value) != null && $.startsWith("sym-") ? (p(), g("svg", C({ key: 1 }, t(i), {
326
329
  class: ["re-icon symbol", [e.clickable ? "clickable" : "", f(), e.className]],
327
330
  "aria-hidden": "true",
328
331
  style: {
@@ -335,10 +338,10 @@ const le = /* @__PURE__ */ _({
335
338
  }
336
339
  }), [
337
340
  x("use", {
338
- "xlink:href": "#icon-" + s.value.replace("sym-", "")
339
- }, null, 8, ae)
341
+ "xlink:href": "#icon-" + n.value.replace("sym-", "")
342
+ }, null, 8, le)
340
343
  ], 16)) : (p(), g("i", C({ key: 0 }, t(i), {
341
- class: ["re-icon iconfont fontclass", [e.clickable ? "clickable" : "", "icon-" + s.value, f(), e.className]],
344
+ class: ["re-icon iconfont fontclass", [e.clickable ? "clickable" : "", "icon-" + n.value, f(), e.className]],
342
345
  style: {
343
346
  top: e.position ? e.position[1] : 1,
344
347
  left: e.position ? e.position[0] : 0,
@@ -348,7 +351,7 @@ const le = /* @__PURE__ */ _({
348
351
  color: e.color
349
352
  },
350
353
  "aria-hidden": "true",
351
- onClick: b
354
+ onClick: S
352
355
  }), null, 16))
353
356
  ], 4)) : I("", !0)
354
357
  ];
@@ -356,12 +359,12 @@ const le = /* @__PURE__ */ _({
356
359
  _: 1
357
360
  }, 8, ["title", "disabled", "color", "placement", "size"]));
358
361
  }
359
- }), ue = (o, c) => {
360
- const i = o.__vccOpts || o;
361
- for (const [e, a] of c)
362
- i[e] = a;
362
+ }), ue = (s, c) => {
363
+ const i = s.__vccOpts || s;
364
+ for (const [e, l] of c)
365
+ i[e] = l;
363
366
  return i;
364
- }, $e = /* @__PURE__ */ ue(re, [["__scopeId", "data-v-e29c02e6"]]), pe = /* @__PURE__ */ _({
367
+ }, we = /* @__PURE__ */ ue(re, [["__scopeId", "data-v-0146f00c"]]), pe = /* @__PURE__ */ _({
365
368
  __name: "projectIcon",
366
369
  props: {
367
370
  icon: {
@@ -378,54 +381,54 @@ const le = /* @__PURE__ */ _({
378
381
  default: !0
379
382
  }
380
383
  },
381
- setup(o) {
382
- const c = o, e = V({
384
+ setup(s) {
385
+ const c = s, e = F({
383
386
  iconUrl: `${c.iconUrl ?? z.PROJECT_ICONS ?? z.TOOL_ICONS}`,
384
387
  monoColor: c.monoColor,
385
388
  icon: c.icon,
386
389
  icons: c.icons
387
390
  });
388
- return (a, l) => o.icon || o.icons ? (p(), v(t(e), C({
391
+ return (l, a) => s.icon || s.icons ? (p(), y(t(e), C({
389
392
  key: 0,
390
- icon: o.icon,
391
- icons: o.icons,
393
+ icon: s.icon,
394
+ icons: s.icons,
392
395
  class: ["align-middle"]
393
- }, a.$attrs), null, 16, ["icon", "icons"])) : I("", !0);
396
+ }, l.$attrs), null, 16, ["icon", "icons"])) : I("", !0);
394
397
  }
395
398
  }), de = { class: "text-xs leading-[3]" }, fe = {
396
399
  key: 0,
397
400
  class: "leading-[2.5] mx-[6px] text-[rgba(0,0,0,0.45)]"
398
401
  }, me = /* @__PURE__ */ _({
399
402
  __name: "index",
400
- setup(o) {
403
+ setup(s) {
401
404
  const { useToken: c } = N, { token: i } = c(), e = B();
402
- return S(
405
+ return k(
403
406
  () => e.TabActive,
404
407
  () => K()
405
408
  ), U(() => {
406
409
  K();
407
- }), (a, l) => (p(), g("div", {
410
+ }), (l, a) => (p(), g("div", {
408
411
  class: "ml-5 h-fit p-0 flex items-center justify-between",
409
412
  style: T({
410
413
  backgroundColor: t(i).colorBgContainer
411
414
  })
412
415
  }, [
413
- u(t(k), {
416
+ u(t(b), {
414
417
  icon: "icon-home",
415
418
  class: "w-[15px] h-[15px]"
416
419
  }),
417
- l[0] || (l[0] = x("span", { class: "leading-[2.5] mx-[6px] text-[rgba(0,0,0,0.45)]" }, ">", -1)),
420
+ a[0] || (a[0] = x("span", { class: "leading-[2.5] mx-[6px] text-[rgba(0,0,0,0.45)]" }, ">", -1)),
418
421
  u(t(Z), {
419
422
  routes: t(E),
420
423
  separator: ""
421
424
  }, {
422
- itemRender: m(({ route: s }) => [
423
- x("span", de, R(s.breadcrumbName), 1),
424
- u(t(k), {
425
- icon: s.icon,
425
+ itemRender: m(({ route: n }) => [
426
+ x("span", de, R(n.breadcrumbName), 1),
427
+ u(t(b), {
428
+ icon: n.icon,
426
429
  fontsize: "15px"
427
430
  }, null, 8, ["icon"]),
428
- s.index < t(E).length - 1 ? (p(), g("span", fe, ">")) : I("", !0)
431
+ n.index < t(E).length - 1 ? (p(), g("span", fe, ">")) : I("", !0)
429
432
  ]),
430
433
  _: 1
431
434
  }, 8, ["routes"])
@@ -433,21 +436,21 @@ const le = /* @__PURE__ */ _({
433
436
  }
434
437
  }), ge = /* @__PURE__ */ _({
435
438
  __name: "headerExits",
436
- setup(o) {
437
- const c = F(), i = h(!1), e = () => {
439
+ setup(s) {
440
+ const c = H(), i = h(!1), e = () => {
438
441
  i.value = !1, M.value ? M.value.userLogout() : c.logout();
439
442
  };
440
- return (a, l) => (p(), g(L, null, [
441
- u(t(k), {
443
+ return (l, a) => (p(), g(L, null, [
444
+ u(t(b), {
442
445
  icon: "icon-logout",
443
- onClick: l[0] || (l[0] = (s) => i.value = !0),
446
+ onClick: a[0] || (a[0] = (n) => i.value = !0),
444
447
  clickable: "",
445
448
  class: "w-5 h-5",
446
449
  title: "退出系统"
447
450
  }),
448
451
  u(t(ee), {
449
452
  open: i.value,
450
- "onUpdate:open": l[1] || (l[1] = (s) => i.value = s),
453
+ "onUpdate:open": a[1] || (a[1] = (n) => i.value = n),
451
454
  title: "确定退出?",
452
455
  "ok-text": "确定",
453
456
  "cancel-text": "取消",
@@ -461,12 +464,12 @@ const le = /* @__PURE__ */ _({
461
464
  style: { padding: "0 32px", margin: "20px 0" }
462
465
  }, {
463
466
  default: m(() => [
464
- u(t(k), {
467
+ u(t(b), {
465
468
  icon: "icon-question-circle",
466
469
  color: "orange",
467
470
  class: "w-[60px] h-[60px]"
468
471
  }),
469
- l[2] || (l[2] = x("div", { style: { margin: "0 0 0 20px", "font-weight": "400", "font-size": "16px" } }, [
472
+ a[2] || (a[2] = x("div", { style: { margin: "0 0 0 20px", "font-weight": "400", "font-size": "16px" } }, [
470
473
  O("是否退出系统,"),
471
474
  x("br"),
472
475
  O("清除用户缓存信息?")
@@ -482,24 +485,24 @@ const le = /* @__PURE__ */ _({
482
485
  }
483
486
  }), xe = /* @__PURE__ */ _({
484
487
  __name: "user",
485
- setup(o) {
486
- const c = F().userInfo;
487
- return (i, e) => (p(), v(t(A), {
488
+ setup(s) {
489
+ const c = H().userInfo;
490
+ return (i, e) => (p(), y(t(w), {
488
491
  title: t(c).Name
489
492
  }, {
490
493
  default: m(() => [
491
- u(t(le), { icon: "icon-account" })
494
+ u(t(ae), { icon: "icon-account" })
492
495
  ]),
493
496
  _: 1
494
497
  }, 8, ["title"]));
495
498
  }
496
- }), _e = { class: "flex items-center" }, we = /* @__PURE__ */ _({
499
+ }), _e = { class: "flex items-center" }, Be = /* @__PURE__ */ _({
497
500
  __name: "index",
498
- setup(o) {
499
- const { useToken: c } = N, { token: i } = c(), e = H(), a = () => {
501
+ setup(s) {
502
+ const { useToken: c } = N, { token: i } = c(), e = V(), l = () => {
500
503
  e.setMenuCollapse(!e.menuCollapse);
501
504
  };
502
- return (l, s) => (p(), v(t(ne), {
505
+ return (a, n) => (p(), y(t(ne), {
503
506
  class: "w-full relative z-[1] shadow-[0_-3px_6px_#000] py-0 flex items-center justify-between",
504
507
  style: T({
505
508
  height: "40px",
@@ -511,12 +514,12 @@ const le = /* @__PURE__ */ _({
511
514
  }, {
512
515
  default: m(() => [
513
516
  x("div", _e, [
514
- u(t(k), {
517
+ u(t(b), {
515
518
  icon: "icon-menu",
516
519
  clickable: "",
517
520
  class: "w-[18px] h-[18px]",
518
521
  angle: t(e).menuCollapse ? 90 : 0,
519
- onClick: a
522
+ onClick: l
520
523
  }, null, 8, ["angle"]),
521
524
  u(me)
522
525
  ]),
@@ -536,53 +539,60 @@ const le = /* @__PURE__ */ _({
536
539
  _: 1
537
540
  }, 8, ["style"]));
538
541
  }
539
- }), ze = /* @__PURE__ */ _({
542
+ }), Ne = /* @__PURE__ */ _({
540
543
  __name: "index",
541
544
  props: {
542
545
  routes: {}
543
546
  },
544
- setup(o) {
545
- const c = o, i = h([]), e = h([]), a = J([]), l = B(), s = (f) => {
546
- w().push(f.key.toString());
547
- }, d = H(), r = h([]), b = () => {
548
- let f = l.TabActive;
549
- const n = f.split("/");
550
- n.pop(), i.value = [n.join("/")], d.menuCollapse || (r.value = [n.join("/")]), e.value = [f];
547
+ setup(s) {
548
+ const c = s, i = h([]), e = h([]), l = W([]), a = B(), n = (f) => {
549
+ A().push(f.key.toString());
550
+ }, d = V(), r = h([]), S = () => {
551
+ let f = a.TabActive;
552
+ const o = f.split("/");
553
+ o.pop(), i.value = [o.join("/")], d.menuCollapse || (r.value = [o.join("/")]), e.value = [f];
551
554
  };
552
- return S(
555
+ return k(
553
556
  () => d.menuCollapse,
554
557
  (f) => {
555
- f || (r.value = [], W(() => {
558
+ f || (r.value = [], G(() => {
556
559
  r.value = [...i.value];
557
560
  }));
558
561
  }
559
- ), S(
560
- () => l.TabActive,
562
+ ), k(
563
+ () => a.TabActive,
561
564
  () => {
562
- b();
565
+ S();
563
566
  }
564
567
  ), U(() => {
565
- X(c.routes, a, pe, { class: "!w-5 !h-5" }), l.setTabActive(Y.currentRoute.value.path), b();
566
- }), (f, n) => (p(), v(t(se), {
568
+ Y(c.routes, l, pe, { class: "!w-5 !h-5" }), a.setTabActive(D.currentRoute.value.path), S();
569
+ }), (f, o) => (p(), y(t(se), {
567
570
  openKeys: r.value,
568
- "onUpdate:openKeys": n[0] || (n[0] = (y) => r.value = y),
571
+ "onUpdate:openKeys": o[0] || (o[0] = (v) => r.value = v),
569
572
  selectedKeys: e.value,
570
- "onUpdate:selectedKeys": n[1] || (n[1] = (y) => e.value = y),
573
+ "onUpdate:selectedKeys": o[1] || (o[1] = (v) => e.value = v),
571
574
  mode: "inline",
572
575
  theme: "dark",
573
- items: a,
574
- onClick: s
576
+ items: l,
577
+ onClick: n
575
578
  }, null, 8, ["openKeys", "selectedKeys", "items"]));
576
579
  }
577
- }), ye = { class: "flex items-center" }, ve = { class: "flex" }, he = ["onClick"], Ae = /* @__PURE__ */ _({
580
+ }), ve = { class: "flex items-center" }, ye = { class: "flex" }, he = ["onClick"], Pe = /* @__PURE__ */ _({
578
581
  __name: "menuTabs",
579
- setup(o) {
580
- const { useToken: c } = N, { token: i } = c(), e = B(), a = (s) => {
581
- w().push(s);
582
- }, l = (s) => {
583
- e.removeTabPane(s), w().push(e.TabActive);
582
+ setup(s) {
583
+ const { useToken: c } = N, { token: i } = c(), e = B();
584
+ k(
585
+ () => D.currentRoute.value.path,
586
+ (n) => {
587
+ n !== e.TabActive && e.setTabActive(n);
588
+ }
589
+ );
590
+ const l = (n) => {
591
+ A().push(n);
592
+ }, a = (n) => {
593
+ e.removeTabPane(n), A().push(e.TabActive);
584
594
  };
585
- return (s, d) => (p(), g("div", {
595
+ return (n, d) => (p(), g("div", {
586
596
  style: T({ height: "38px", backgroundColor: t(i).colorBgBase })
587
597
  }, [
588
598
  u(t(ie), {
@@ -590,16 +600,16 @@ const le = /* @__PURE__ */ _({
590
600
  "hide-add": "",
591
601
  size: "small",
592
602
  tabBarStyle: { padding: "0 20px" },
593
- onTabClick: a
603
+ onTabClick: l
594
604
  }, {
595
605
  default: m(() => [
596
- (p(!0), g(L, null, G(t(e).TabPanes, (r) => (p(), v(t(ce), {
606
+ (p(!0), g(L, null, Q(t(e).TabPanes, (r) => (p(), y(t(ce), {
597
607
  key: r.key
598
608
  }, {
599
609
  tab: m(() => [
600
- x("div", ye, [
601
- x("span", ve, R(r.title), 1),
602
- u(t(A), {
610
+ x("div", ve, [
611
+ x("span", ye, R(r.title), 1),
612
+ u(t(w), {
603
613
  title: "关闭",
604
614
  placement: "top",
605
615
  size: "small"
@@ -608,9 +618,9 @@ const le = /* @__PURE__ */ _({
608
618
  t(e).TabPanes.length > 1 && r.closable ? (p(), g("div", {
609
619
  key: 0,
610
620
  class: "inline-block mx-auto relative flex items-center",
611
- onClick: Q((b) => l(r.key), ["stop"])
621
+ onClick: X((S) => a(r.key), ["stop"])
612
622
  }, [
613
- u(t(k), {
623
+ u(t(b), {
614
624
  icon: "icon-new",
615
625
  angle: 45,
616
626
  clickable: "",
@@ -632,13 +642,13 @@ const le = /* @__PURE__ */ _({
632
642
  }
633
643
  });
634
644
  export {
635
- $e as I,
645
+ we as I,
636
646
  ue as _,
637
- le as a,
647
+ ae as a,
638
648
  pe as b,
639
649
  me as c,
640
- we as d,
650
+ Be as d,
641
651
  ge as e,
642
- ze as f,
643
- Ae as g
652
+ Ne as f,
653
+ Pe as g
644
654
  };