@chewel611/naive-ui-plus 0.0.29 → 0.0.30

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1,281 +1,240 @@
1
- import { useDialog as Ne, useMessage as fe, NCard as Ae, NDataTable as Ge, NModal as De, NSpace as ke, NButton as K, NTooltip as ze, NIcon as M, NDropdown as Z, NAvatar as Le, NBreadcrumb as Je, NBreadcrumbItem as Ze, NDivider as Qe, useThemeVars as et, NMenu as tt, NLayout as Ee, NLayoutSider as at, NFlex as nt, NLayoutHeader as ot, NLayoutContent as lt, NBackTop as st, NConfigProvider as rt, dateZhCN as it, zhCN as ct, NDialogProvider as ut, NNotificationProvider as dt, NMessageProvider as ft, NText as gt, NEmpty as pt, NSpin as ht, NResult as Ce } from "naive-ui";
2
- import { defineComponent as I, ref as $, computed as F, unref as a, onMounted as Q, openBlock as p, createBlock as S, withCtx as l, createElementVNode as b, createElementBlock as R, renderSlot as j, createCommentVNode as N, createVNode as r, normalizeStyle as de, createTextVNode as Y, toDisplayString as H, h as W, toRaw as J, reactive as xe, normalizeClass as ae, withDirectives as mt, vShow as vt, nextTick as ne, inject as Ie, Fragment as Me, renderList as _t, resolveDynamicComponent as we, withModifiers as Pe, resolveComponent as Be, KeepAlive as yt, useCssVars as bt, watch as We, provide as wt, mergeProps as Pt, onBeforeMount as kt } from "vue";
3
- import { PlusSquareOutlined as Lt, DeleteOutlined as Ct, ReloadOutlined as Se, MoreOutlined as xt, MenuUnfoldOutlined as St, MenuFoldOutlined as Tt, FullscreenOutlined as $t, FullscreenExitOutlined as Ot, CloseOutlined as Re, ColumnWidthOutlined as Et, MinusOutlined as Mt, LeftOutlined as Rt, RightOutlined as Nt, DownOutlined as At, AlertOutlined as Dt } from "@vicons/antd";
4
- import { cloneDeep as zt } from "lodash";
5
- import { defineStore as Te } from "pinia";
6
- import { useRouter as oe, useRoute as le } from "vue-router";
7
- import It from "element-resize-detector";
8
- import Bt from "vuedraggable";
9
- const je = (t) => {
10
- Object.keys(t).forEach((n) => {
11
- const c = t[n];
12
- Array.isArray(c) ? t[n] = [] : c !== null && typeof c == "object" ? je(c) : t[n] = void 0;
13
- });
14
- }, Wt = { class: "text-lg font-medium" }, jt = { id: "data-content" }, Ht = {
1
+ import { useDialog as $e, useMessage as ue, NCard as Oe, NDataTable as Me, NSpace as _e, NTooltip as Ee, NIcon as D, NDropdown as G, NButton as ve, NAvatar as be, NBreadcrumb as Ie, NBreadcrumbItem as Be, NDivider as He, useThemeVars as We, NMenu as Ue, NLayout as xe, NLayoutSider as je, NFlex as qe, NLayoutHeader as Fe, NLayoutContent as Ve, NBackTop as Ke, NConfigProvider as Ye, dateZhCN as Xe, zhCN as Je, NDialogProvider as Ze, NNotificationProvider as Ge, NMessageProvider as Qe, NModal as et, NText as tt, NEmpty as at, NSpin as nt, NResult as ye } from "naive-ui";
2
+ import { defineComponent as B, ref as N, computed as K, unref as a, onMounted as Q, openBlock as h, createBlock as C, withCtx as o, createElementVNode as b, createElementBlock as M, renderSlot as Y, createCommentVNode as I, createVNode as l, toDisplayString as q, h as U, toRaw as Ce, reactive as we, normalizeClass as oe, withDirectives as ot, vShow as st, nextTick as se, inject as Re, Fragment as Se, renderList as lt, resolveDynamicComponent as he, withModifiers as me, resolveComponent as Ne, KeepAlive as ct, useCssVars as rt, watch as ze, normalizeStyle as De, provide as it, mergeProps as ut, createTextVNode as pe, onBeforeMount as dt } from "vue";
3
+ import { PlusSquareOutlined as ft, DeleteOutlined as gt, ReloadOutlined as Pe, MoreOutlined as pt, MenuUnfoldOutlined as ht, MenuFoldOutlined as mt, FullscreenOutlined as _t, FullscreenExitOutlined as vt, CloseOutlined as Te, ColumnWidthOutlined as bt, MinusOutlined as yt, LeftOutlined as wt, RightOutlined as Pt, DownOutlined as kt, AlertOutlined as Lt } from "@vicons/antd";
4
+ import { defineStore as ke } from "pinia";
5
+ import { useRouter as le, useRoute as ce } from "vue-router";
6
+ import xt from "element-resize-detector";
7
+ import Ct from "vuedraggable";
8
+ const St = { class: "text-lg font-medium" }, Tt = { id: "data-content" }, $t = {
15
9
  key: 0,
16
10
  class: "rounded-lg bg-gray-50 flex flex-row gap-2 items-center justify-end p-4 mb-4"
17
- }, Ut = { key: 1 }, qt = { key: 2 }, Ft = /* @__PURE__ */ I({
11
+ }, Ot = /* @__PURE__ */ B({
18
12
  __name: "PTable",
19
13
  props: {
20
14
  title: {},
21
15
  idField: { default: "id" },
22
- item: { default: {} },
23
16
  columns: {},
24
- modalWidth: { default: 800 },
25
- hiddenAdd: { type: Boolean, default: !1 },
26
- hiddenEdit: { type: Boolean, default: !1 },
27
- hiddenDelete: { type: Boolean, default: !1 },
28
17
  onLoad: {},
29
- onGet: {},
30
- onOpenModal: {},
31
- onCloseModal: {},
32
- onSave: {},
33
- onDelete: {}
18
+ onDelete: {},
19
+ onAdd: {},
20
+ onEdit: {}
34
21
  },
35
- setup(t, { expose: n }) {
36
- const c = $(null), y = Ne(), h = fe(), u = $(!1), k = $([]), _ = $([]), T = $(null), O = $(!1), i = $(!1), w = $(!1), d = $({}), C = $({
22
+ setup(e, { expose: n }) {
23
+ const i = N(null), _ = $e(), g = ue(), c = N(!1), P = N([]), m = N([]), T = N({
37
24
  page: 1,
38
25
  itemCount: 0,
39
26
  pageSize: 10,
40
27
  pageSizes: [10, 20, 30, 50],
41
28
  showSizePicker: !0,
42
- onChange: async (g) => {
43
- C.value.page = g, await q();
29
+ onChange: async (w) => {
30
+ T.value.page = w, await O();
44
31
  },
45
- onUpdatePageSize: async (g) => {
46
- C.value.pageSize = g, await q();
32
+ onUpdatePageSize: async (w) => {
33
+ T.value.pageSize = w, await O();
47
34
  }
48
- }), m = t, f = (g) => {
49
- const e = (o) => {
50
- const s = [];
51
- return g && g.forEach((L) => {
52
- L.key !== "edit" && L.key !== "delete" && s.push({
53
- label: L.name,
54
- key: L.key,
55
- props: { onClick: () => L.action(o) }
35
+ }), L = e, s = (w) => {
36
+ const k = (x) => {
37
+ const E = [];
38
+ return w && w.forEach((H) => {
39
+ H.key !== "edit" && H.key !== "delete" && E.push({
40
+ label: H.name,
41
+ key: H.key,
42
+ props: { onClick: () => H.action(x) }
56
43
  });
57
- }), s;
44
+ }), E;
58
45
  };
59
46
  return {
60
47
  title: "操作",
61
48
  key: "actions",
62
49
  width: 100,
63
50
  fixed: "right",
64
- render: (o) => {
65
- let s = [];
66
- if (m.hiddenEdit || s.push({
51
+ render: (x) => {
52
+ let E = [];
53
+ if (L.onEdit && E.push({
67
54
  label: "编辑",
68
55
  key: "edit",
69
- props: { onClick: () => ge(o) }
70
- }), m.hiddenDelete || s.push({
56
+ props: { onClick: async () => await L.onEdit(x) }
57
+ }), L.onDelete && E.push({
71
58
  label: "删除",
72
59
  key: "delete",
73
- props: { onClick: () => A(o) }
74
- }), s = [...s, ...e(o)], !(s.length <= 0))
75
- return W(
76
- Z,
60
+ props: { onClick: () => $(x) }
61
+ }), E = [...E, ...k(x)], !(E.length <= 0))
62
+ return U(
63
+ G,
77
64
  {
78
- options: s,
65
+ options: E,
79
66
  placement: "bottom-start"
80
67
  },
81
68
  {
82
- default: () => W(
83
- K,
69
+ default: () => U(
70
+ ve,
84
71
  { size: "small", type: "primary" },
85
- { default: () => ["操作", W(M, () => W(xt))] }
72
+ { default: () => ["操作", U(D, () => U(pt))] }
86
73
  )
87
74
  }
88
75
  );
89
76
  }
90
77
  };
91
- }, P = F(() => {
92
- const g = m.columns.filter((o) => o.key != "action").map((o) => ({
93
- title: o.title,
94
- key: o.key,
95
- width: o.width,
96
- fixed: o.fixed ?? !1,
97
- render: o.render,
98
- ellipsis: o.ellipsis ? { tooltip: !0 } : !1
99
- })), e = m.columns.reduce(
100
- (o, s) => s.key === "action" ? s : o,
78
+ }, y = K(() => {
79
+ const w = L.columns.filter((x) => x.key != "action").map((x) => ({
80
+ title: x.title,
81
+ key: x.key,
82
+ width: x.width,
83
+ fixed: x.fixed ?? !1,
84
+ render: x.render,
85
+ ellipsis: x.ellipsis ? { tooltip: !0 } : !1
86
+ })), k = L.columns.reduce(
87
+ (x, E) => E.key === "action" ? E : x,
101
88
  void 0
102
89
  )?.action;
103
- return e && e?.length > 0 || !m.hiddenDelete || !m.hiddenEdit ? [
90
+ return k && k?.length > 0 || L.onEdit || L.onDelete ? [
104
91
  { type: "selection", fixed: "left" },
105
- ...g,
106
- f(e)
107
- ] : [{ type: "selection", fixed: "left" }, ...g];
108
- }), v = async () => {
109
- await q();
110
- }, A = (g) => {
111
- x([g]);
112
- }, E = () => {
113
- const g = G();
114
- x(g);
115
- }, x = (g) => {
116
- g && g.length > 0 && y.warning({
92
+ ...w,
93
+ s(k)
94
+ ] : [{ type: "selection", fixed: "left" }, ...w];
95
+ }), r = async () => await O(), $ = (w) => u([w]), z = () => {
96
+ const w = v();
97
+ u(w);
98
+ }, u = (w) => {
99
+ w && w.length > 0 && _.warning({
117
100
  title: "警告",
118
101
  content: "删除数据不可恢复, 确认删除吗?",
119
102
  positiveText: "确定",
120
103
  negativeText: "取消",
121
104
  onPositiveClick: async () => {
122
- if (m.onDelete)
105
+ if (L.onDelete)
123
106
  try {
124
- await m.onDelete(g) ? (q(), h.success("删除成功")) : h.error("删除失败");
125
- } catch (e) {
126
- h.error(e.message);
107
+ await L.onDelete(w) ? (O(), g.success("删除成功")) : g.error("删除失败");
108
+ } catch (k) {
109
+ g.error(k.message);
127
110
  }
128
111
  }
129
112
  });
130
- }, ee = () => {
131
- T.value = null, ie();
132
- }, ge = async (g) => {
133
- T.value = zt(g), ie(T.value, async () => {
134
- m.onGet && (T.value = await m.onGet(g[m.idField])), Object.assign(m.item, T.value);
135
- });
136
- }, re = async () => {
137
- if (m.onSave)
113
+ }, v = () => P.value ? m.value.filter((k) => P.value.includes(k.id)).map((k) => Ce(k)) : [], p = () => v()[0], A = () => Ce(m.value), O = async () => {
114
+ if (!c.value) {
115
+ c.value = !0;
138
116
  try {
139
- w.value = !0, (O.value ? await m.onSave(void 0, J(m.item)) : await m.onSave(T.value[m.idField], J(m.item))) && (X(), await q());
140
- } catch (g) {
141
- h.error(g.message);
142
- } finally {
143
- w.value = !1;
144
- }
145
- }, ie = async (g, e) => {
146
- m.onOpenModal?.(g), await e?.(), g ? (O.value = !1, i.value = !0) : (i.value = !1, O.value = !0);
147
- }, X = () => {
148
- T.value = null, je(m.item), Object.assign(m.item, { ...J(d.value) }), m.onCloseModal?.(m.item), O.value = !1, i.value = !1;
149
- }, G = () => k.value ? _.value.filter((e) => k.value.includes(e.id)).map((e) => J(e)) : [], pe = () => G()[0], he = () => J(_.value), q = async () => {
150
- if (!u.value) {
151
- u.value = !0;
152
- try {
153
- if (m.onLoad) {
154
- var { data: g, total: e } = await m.onLoad(
155
- C.value.page,
156
- C.value.pageSize
117
+ if (L.onLoad) {
118
+ var { data: w, total: k } = await L.onLoad(
119
+ T.value.page,
120
+ T.value.pageSize
157
121
  );
158
- _.value = g, C.value.itemCount = e;
122
+ m.value = w, T.value.itemCount = k;
159
123
  }
160
- } catch (o) {
161
- h.error(o.message);
124
+ } catch (x) {
125
+ g.error(x.message);
162
126
  } finally {
163
- u.value = !1;
127
+ c.value = !1;
164
128
  }
165
129
  }
166
- }, me = F(() => {
167
- const g = a(c);
168
- if (!g) return;
169
- const e = g?.$el, o = e.querySelector(".n-data-table-thead "), { bottomIncludeBody: s } = te(o), L = 48;
170
- let D = 12, z = 24;
171
- const V = e.querySelector(
130
+ }, S = K(() => {
131
+ const w = a(i);
132
+ if (!w) return;
133
+ const k = w?.$el, x = k.querySelector(".n-data-table-thead "), { bottomIncludeBody: E } = de(x), H = 48;
134
+ let j = 12, Z = 24;
135
+ const X = k.querySelector(
172
136
  ".n-data-table__pagination"
173
137
  );
174
- if (V) {
175
- const _e = V.offsetHeight;
176
- D += _e || 0;
138
+ if (X) {
139
+ const J = X.offsetHeight;
140
+ j += J || 0;
177
141
  } else
178
- D += 28;
179
- return s - (L + D + z);
180
- }), ce = (g) => !g || !g.getBoundingClientRect ? 0 : g.getBoundingClientRect(), te = (g) => {
181
- const e = document.documentElement, o = e.scrollLeft, s = e.scrollTop, L = e.clientLeft, D = e.clientTop, z = window.pageXOffset, V = window.pageYOffset, ue = ce(g), {
182
- left: _e,
183
- top: Ue,
184
- width: qe,
185
- height: Fe
186
- } = ue, Ve = (z || o) - (L || 0), Ke = (V || s) - (D || 0), Ye = _e + z, Xe = Ue + V, ye = Ye - Ve, be = Xe - Ke, $e = window.document.documentElement.clientWidth, Oe = window.document.documentElement.clientHeight;
142
+ j += 28;
143
+ return E - (H + j + Z);
144
+ }), ee = (w) => !w || !w.getBoundingClientRect ? 0 : w.getBoundingClientRect(), de = (w) => {
145
+ const k = document.documentElement, x = k.scrollLeft, E = k.scrollTop, H = k.clientLeft, j = k.clientTop, Z = window.pageXOffset, X = window.pageYOffset, te = ee(w), {
146
+ left: J,
147
+ top: fe,
148
+ width: ge,
149
+ height: t
150
+ } = te, d = (Z || x) - (H || 0), f = (X || E) - (j || 0), R = J + Z, V = fe + X, ae = R - d, ne = V - f, ie = window.document.documentElement.clientWidth, Le = window.document.documentElement.clientHeight;
187
151
  return {
188
- left: ye,
189
- top: be,
190
- right: $e - qe - ye,
191
- bottom: Oe - Fe - be,
192
- rightIncludeBody: $e - ye,
193
- bottomIncludeBody: Oe - be
152
+ left: ae,
153
+ top: ne,
154
+ right: ie - ge - ae,
155
+ bottom: Le - t - ne,
156
+ rightIncludeBody: ie - ae,
157
+ bottomIncludeBody: Le - ne
194
158
  };
195
- }, ve = () => {
196
- d.value = { ...J(m.item) };
197
159
  };
198
- return Q(async () => {
199
- ve(), await q();
200
- }), n({
201
- getData: he,
202
- getSelectedRow: pe,
203
- getSelectedRows: G,
204
- closeModal: X,
205
- refreshData: q,
160
+ return Q(async () => await O()), n({
161
+ getData: A,
162
+ getSelectedRow: p,
163
+ getSelectedRows: v,
164
+ refreshData: O,
206
165
  resetPage: () => {
207
- C.value.page = 1;
166
+ T.value.page = 1;
208
167
  }
209
- }), (g, e) => {
210
- const o = ze, s = ke, L = Ge, D = De;
211
- return p(), S(a(Ae), { bordered: !1 }, {
212
- header: l(() => [
213
- r(s, {
168
+ }), (w, k) => {
169
+ const x = Ee, E = _e, H = Me;
170
+ return h(), C(a(Oe), { bordered: !1 }, {
171
+ header: o(() => [
172
+ l(E, {
214
173
  justify: "space-between",
215
174
  align: "center",
216
175
  class: "w-full"
217
176
  }, {
218
- default: l(() => [
219
- b("span", Wt, H(t.title), 1),
220
- r(s, null, {
221
- default: l(() => [
222
- t.hiddenAdd ? N("", !0) : (p(), S(o, {
177
+ default: o(() => [
178
+ b("span", St, q(e.title), 1),
179
+ l(E, null, {
180
+ default: o(() => [
181
+ L.onAdd ? (h(), C(x, {
223
182
  key: 0,
224
183
  trigger: "hover"
225
184
  }, {
226
- trigger: l(() => [
227
- r(a(M), {
185
+ trigger: o(() => [
186
+ l(a(D), {
228
187
  size: "18",
229
188
  class: "mr-1 cursor-pointer hover:text-blue-600",
230
- onClick: ee
189
+ onClick: L.onAdd
231
190
  }, {
232
- default: l(() => [
233
- r(a(Lt))
191
+ default: o(() => [
192
+ l(a(ft))
234
193
  ]),
235
194
  _: 1
236
- })
195
+ }, 8, ["onClick"])
237
196
  ]),
238
- default: l(() => [
239
- e[3] || (e[3] = b("span", null, "新增", -1))
197
+ default: o(() => [
198
+ k[1] || (k[1] = b("span", null, "新增", -1))
240
199
  ]),
241
200
  _: 1
242
- })),
243
- t.hiddenDelete ? N("", !0) : (p(), S(o, {
201
+ })) : I("", !0),
202
+ L.onDelete ? (h(), C(x, {
244
203
  key: 1,
245
204
  trigger: "hover"
246
205
  }, {
247
- trigger: l(() => [
248
- r(a(M), {
206
+ trigger: o(() => [
207
+ l(a(D), {
249
208
  size: "18",
250
209
  class: "mr-1 cursor-pointer hover:text-blue-600",
251
- onClick: E
210
+ onClick: z
252
211
  }, {
253
- default: l(() => [
254
- r(a(Ct))
212
+ default: o(() => [
213
+ l(a(gt))
255
214
  ]),
256
215
  _: 1
257
216
  })
258
217
  ]),
259
- default: l(() => [
260
- e[4] || (e[4] = b("span", null, "删除", -1))
218
+ default: o(() => [
219
+ k[2] || (k[2] = b("span", null, "删除", -1))
261
220
  ]),
262
221
  _: 1
263
- })),
264
- r(o, { trigger: "hover" }, {
265
- trigger: l(() => [
266
- r(a(M), {
222
+ })) : I("", !0),
223
+ l(x, { trigger: "hover" }, {
224
+ trigger: o(() => [
225
+ l(a(D), {
267
226
  size: "18",
268
227
  class: "cursor-pointer hover:text-blue-600",
269
- onClick: v
228
+ onClick: r
270
229
  }, {
271
- default: l(() => [
272
- r(a(Se))
230
+ default: o(() => [
231
+ l(a(Pe))
273
232
  ]),
274
233
  _: 1
275
234
  })
276
235
  ]),
277
- default: l(() => [
278
- e[5] || (e[5] = b("span", null, "刷新", -1))
236
+ default: o(() => [
237
+ k[3] || (k[3] = b("span", null, "刷新", -1))
279
238
  ]),
280
239
  _: 1
281
240
  })
@@ -286,123 +245,39 @@ const je = (t) => {
286
245
  _: 1
287
246
  })
288
247
  ]),
289
- default: l(() => [
290
- b("div", jt, [
291
- g.$slots.toolbar ? (p(), R("div", Ht, [
292
- j(g.$slots, "toolbar")
293
- ])) : N("", !0),
294
- r(L, {
248
+ default: o(() => [
249
+ b("div", Tt, [
250
+ w.$slots.toolbar ? (h(), M("div", $t, [
251
+ Y(w.$slots, "toolbar")
252
+ ])) : I("", !0),
253
+ l(H, {
295
254
  remote: "",
296
255
  ref_key: "$table",
297
- ref: c,
298
- "checked-row-keys": k.value,
299
- "onUpdate:checkedRowKeys": e[0] || (e[0] = (z) => k.value = z),
300
- "max-height": me.value,
301
- loading: u.value,
256
+ ref: i,
257
+ "checked-row-keys": P.value,
258
+ "onUpdate:checkedRowKeys": k[0] || (k[0] = (j) => P.value = j),
259
+ "max-height": S.value,
260
+ loading: c.value,
302
261
  bordered: !1,
303
262
  "single-line": !1,
304
- columns: P.value,
305
- data: _.value,
306
- pagination: C.value,
307
- "row-key": (z) => z[t.idField]
308
- }, null, 8, ["checked-row-keys", "max-height", "loading", "columns", "data", "pagination", "row-key"]),
309
- g.$slots.addModal ? (p(), R("div", Ut, [
310
- r(D, {
311
- title: "新增",
312
- preset: "card",
313
- show: O.value,
314
- "onUpdate:show": e[1] || (e[1] = (z) => O.value = z),
315
- "header-class": "bg-gray-50",
316
- closable: !1,
317
- "close-on-esc": !1,
318
- "mask-closable": !1,
319
- draggable: !0,
320
- style: de({ width: `${t.modalWidth}px` })
321
- }, {
322
- action: l(() => [
323
- r(s, { justify: "end" }, {
324
- default: l(() => [
325
- r(a(K), {
326
- type: "primary",
327
- loading: w.value,
328
- onClick: re
329
- }, {
330
- default: l(() => [...e[6] || (e[6] = [
331
- Y("保存", -1)
332
- ])]),
333
- _: 1
334
- }, 8, ["loading"]),
335
- r(a(K), { onClick: X }, {
336
- default: l(() => [...e[7] || (e[7] = [
337
- Y("取消", -1)
338
- ])]),
339
- _: 1
340
- })
341
- ]),
342
- _: 1
343
- })
344
- ]),
345
- default: l(() => [
346
- j(g.$slots, "addModal")
347
- ]),
348
- _: 3
349
- }, 8, ["show", "style"])
350
- ])) : N("", !0),
351
- g.$slots.editModal ? (p(), R("div", qt, [
352
- r(D, {
353
- title: "编辑",
354
- show: i.value,
355
- "onUpdate:show": e[2] || (e[2] = (z) => i.value = z),
356
- preset: "card",
357
- "header-class": "bg-gray-50",
358
- closable: !1,
359
- "close-on-esc": !1,
360
- "mask-closable": !1,
361
- draggable: !0,
362
- style: de({ width: `${t.modalWidth}px` })
363
- }, {
364
- action: l(() => [
365
- r(s, { justify: "end" }, {
366
- default: l(() => [
367
- r(a(K), {
368
- type: "primary",
369
- loading: w.value,
370
- onClick: re
371
- }, {
372
- default: l(() => [...e[8] || (e[8] = [
373
- Y("保存", -1)
374
- ])]),
375
- _: 1
376
- }, 8, ["loading"]),
377
- r(a(K), { onClick: X }, {
378
- default: l(() => [...e[9] || (e[9] = [
379
- Y("取消", -1)
380
- ])]),
381
- _: 1
382
- })
383
- ]),
384
- _: 1
385
- })
386
- ]),
387
- default: l(() => [
388
- j(g.$slots, "editModal")
389
- ]),
390
- _: 3
391
- }, 8, ["show", "style"])
392
- ])) : N("", !0)
263
+ columns: y.value,
264
+ data: m.value,
265
+ pagination: T.value,
266
+ "row-key": (j) => j[e.idField]
267
+ }, null, 8, ["checked-row-keys", "max-height", "loading", "columns", "data", "pagination", "row-key"])
393
268
  ])
394
269
  ]),
395
270
  _: 3
396
271
  });
397
272
  };
398
273
  }
399
- }), B = (t) => {
400
- const n = t;
401
- return n.install = function(c) {
402
- c.component(n.__name, t);
403
- }, t;
404
- }, Vt = B(Ft), Kt = ["Redirect", "RedirectSon", "login"], se = Te("p-layout", () => {
405
- const t = xe({
274
+ }), W = (e) => {
275
+ const n = e;
276
+ return n.install = function(i) {
277
+ i.component(n.__name, e);
278
+ }, e;
279
+ }, Et = W(Ot), Rt = ["Redirect", "RedirectSon", "login"], re = ke("p-layout", () => {
280
+ const e = we({
406
281
  collapsed: !1,
407
282
  title: "输入项目名称",
408
283
  logo: "https://picsum.photos/id/1/100/100",
@@ -414,164 +289,164 @@ const je = (t) => {
414
289
  enableLanguage: !1
415
290
  });
416
291
  return {
417
- state: t,
418
- initTabs: (f) => {
419
- f.sort((P, v) => (v.meta.affix ? 1 : 0) - (P.meta.affix ? 1 : 0)), t.tabs = f;
292
+ state: e,
293
+ initTabs: (u) => {
294
+ u.sort((v, p) => (p.meta.affix ? 1 : 0) - (v.meta.affix ? 1 : 0)), e.tabs = u;
420
295
  },
421
- addTab: (f) => Kt.includes(f.name) ? !1 : (t.tabs?.some(
422
- (v) => v.fullPath == f.fullPath
423
- ) || t.tabs?.push(f), !0),
424
- closeCurrentTab: (f) => {
425
- const P = t.tabs.findIndex(
426
- (v) => v.fullPath == f.fullPath
296
+ addTab: (u) => Rt.includes(u.name) ? !1 : (e.tabs?.some(
297
+ (p) => p.fullPath == u.fullPath
298
+ ) || e.tabs?.push(u), !0),
299
+ closeCurrentTab: (u) => {
300
+ const v = e.tabs.findIndex(
301
+ (p) => p.fullPath == u.fullPath
427
302
  );
428
- t.tabs.splice(P, 1);
303
+ e.tabs.splice(v, 1);
429
304
  },
430
305
  closeAllTabs: () => {
431
- t.tabs = t.tabs.filter((f) => f?.meta?.affix ?? !1);
306
+ e.tabs = e.tabs.filter((u) => u?.meta?.affix ?? !1);
432
307
  },
433
- closeOtherTabs: (f) => {
434
- t.tabs = t.tabs.filter(
435
- (P) => P.fullPath == f.fullPath || (P?.meta?.affix ?? !1)
308
+ closeOtherTabs: (u) => {
309
+ e.tabs = e.tabs.filter(
310
+ (v) => v.fullPath == u.fullPath || (v?.meta?.affix ?? !1)
436
311
  );
437
312
  },
438
- closeLeftTabs: (f) => {
439
- const P = t.tabs.findIndex(
440
- (v) => v.fullPath == f.fullPath
313
+ closeLeftTabs: (u) => {
314
+ const v = e.tabs.findIndex(
315
+ (p) => p.fullPath == u.fullPath
441
316
  );
442
- t.tabs = t.tabs.filter(
443
- (v, A) => A >= P || (v?.meta?.affix ?? !1)
317
+ e.tabs = e.tabs.filter(
318
+ (p, A) => A >= v || (p?.meta?.affix ?? !1)
444
319
  );
445
320
  },
446
- closeRightTabs: (f) => {
447
- const P = t.tabs.findIndex(
448
- (v) => v.fullPath == f.fullPath
321
+ closeRightTabs: (u) => {
322
+ const v = e.tabs.findIndex(
323
+ (p) => p.fullPath == u.fullPath
449
324
  );
450
- t.tabs = t.tabs.filter(
451
- (v, A) => A <= P || (v?.meta?.affix ?? !1)
325
+ e.tabs = e.tabs.filter(
326
+ (p, A) => A <= v || (p?.meta?.affix ?? !1)
452
327
  );
453
328
  },
454
329
  collapse: () => {
455
- t.collapsed = !t.collapsed;
330
+ e.collapsed = !e.collapsed;
456
331
  },
457
- setTitle: (f) => {
458
- t.title = f;
332
+ setTitle: (u) => {
333
+ e.title = u;
459
334
  },
460
- setLogo: (f) => {
461
- t.logo = f;
335
+ setLogo: (u) => {
336
+ e.logo = u;
462
337
  },
463
- setUser: (f, P) => {
464
- t.uid = f, t.uname = P;
338
+ setUser: (u, v) => {
339
+ e.uid = u, e.uname = v;
465
340
  },
466
- setSettingPages: (f) => {
467
- t.settingPages = f;
341
+ setSettingPages: (u) => {
342
+ e.settingPages = u;
468
343
  },
469
- setLogout: (f) => {
470
- t.logout = f;
344
+ setLogout: (u) => {
345
+ e.logout = u;
471
346
  },
472
- enableLanguage: (f) => {
473
- t.enableLanguage = f;
347
+ enableLanguage: (u) => {
348
+ e.enableLanguage = u;
474
349
  }
475
350
  };
476
- }), Yt = { class: "logo" }, Xt = /* @__PURE__ */ I({
351
+ }), Nt = { class: "logo" }, zt = /* @__PURE__ */ B({
477
352
  __name: "PLogo",
478
- setup(t) {
479
- const n = se();
480
- return (c, y) => (p(), R("div", Yt, [
481
- r(a(Le), {
353
+ setup(e) {
354
+ const n = re();
355
+ return (i, _) => (h(), M("div", Nt, [
356
+ l(a(be), {
482
357
  color: "var(--color-logo)",
483
358
  size: 32,
484
359
  src: a(n).state.logo,
485
- class: ae({ "mr-2": !a(n).state.collapsed })
360
+ class: oe({ "mr-2": !a(n).state.collapsed })
486
361
  }, null, 8, ["src", "class"]),
487
- mt(b("h1", { class: "font-bold ease-in-out ml-2 logo-size" }, H(a(n).state.title), 513), [
488
- [vt, !a(n).state.collapsed]
362
+ ot(b("h1", { class: "font-bold ease-in-out ml-2 logo-size" }, q(a(n).state.title), 513), [
363
+ [st, !a(n).state.collapsed]
489
364
  ])
490
365
  ]));
491
366
  }
492
- }), U = (t, n) => {
493
- const c = t.__vccOpts || t;
494
- for (const [y, h] of n)
495
- c[y] = h;
496
- return c;
497
- }, Gt = /* @__PURE__ */ U(Xt, [["__scopeId", "data-v-e48aeefa"]]), Jt = {
367
+ }), F = (e, n) => {
368
+ const i = e.__vccOpts || e;
369
+ for (const [_, g] of n)
370
+ i[_] = g;
371
+ return i;
372
+ }, Dt = /* @__PURE__ */ F(zt, [["__scopeId", "data-v-e48aeefa"]]), At = {
498
373
  translationApiUrl: "https://translate.zvo.cn/api",
499
374
  defaultLanguage: "chinese",
500
375
  currentLanguage: "",
501
376
  options: [],
502
377
  initLanguages: async () => [],
503
- selectLanguage: async (t) => {
378
+ selectLanguage: async (e) => {
504
379
  }
505
- }, Zt = Te("language", () => {
506
- const t = $(Jt), n = async () => (t.value.options.length === 0 && (t.value.options = await t.value.initLanguages()), t.value.options);
380
+ }, Mt = ke("language", () => {
381
+ const e = N(At), n = async () => (e.value.options.length === 0 && (e.value.options = await e.value.initLanguages()), e.value.options);
507
382
  return {
508
- select: async (i) => {
509
- if (t.value.currentLanguage === i)
383
+ select: async (s) => {
384
+ if (e.value.currentLanguage === s)
510
385
  return;
511
- const w = (await n()).find(
512
- (d) => d.key === i
386
+ const y = (await n()).find(
387
+ (r) => r.key === s
513
388
  );
514
- w && (t.value.currentLanguage = w.key, t.value.selectLanguage(w));
389
+ y && (e.value.currentLanguage = y.key, e.value.selectLanguage(y));
515
390
  },
516
- selectLanguageCallback: async (i) => {
517
- t.value.selectLanguage = i;
391
+ selectLanguageCallback: async (s) => {
392
+ e.value.selectLanguage = s;
518
393
  },
519
- initLanguagesCallback: async (i) => {
520
- t.value.initLanguages = i;
394
+ initLanguagesCallback: async (s) => {
395
+ e.value.initLanguages = s;
521
396
  },
522
397
  getLanguages: n,
523
398
  getCurrentLanguage: async () => {
524
- if (t.value.currentLanguage)
399
+ if (e.value.currentLanguage)
525
400
  return (await n()).find(
526
- (i) => i.key === t.value.currentLanguage
401
+ (s) => s.key === e.value.currentLanguage
527
402
  );
528
403
  },
529
- setTranslationApiUrl: (i) => {
530
- t.value.translationApiUrl = i;
404
+ setTranslationApiUrl: (s) => {
405
+ e.value.translationApiUrl = s;
531
406
  },
532
- getTranslationApiUrl: () => t.value.translationApiUrl,
533
- getDefaultLanguage: () => t.value.defaultLanguage ? t.value.defaultLanguage : "chinese_simplified",
534
- setDefaultLanguage: (i) => {
535
- (i === "Chinese" || i === "chinese") && (i = "chinese_simplified"), t.value.defaultLanguage = i;
407
+ getTranslationApiUrl: () => e.value.translationApiUrl,
408
+ getDefaultLanguage: () => e.value.defaultLanguage ? e.value.defaultLanguage : "chinese_simplified",
409
+ setDefaultLanguage: (s) => {
410
+ (s === "Chinese" || s === "chinese") && (s = "chinese_simplified"), e.value.defaultLanguage = s;
536
411
  }
537
412
  };
538
- }), Qt = { key: 1 }, He = /* @__PURE__ */ I({
413
+ }), It = { key: 1 }, Ae = /* @__PURE__ */ B({
539
414
  __name: "PLanguage",
540
- setup(t) {
415
+ setup(e) {
541
416
  const {
542
417
  select: n,
543
- getLanguages: c,
544
- getCurrentLanguage: y,
545
- getDefaultLanguage: h,
546
- getTranslationApiUrl: u
547
- } = Zt(), k = $(), _ = $([]), T = async (i) => await n(i), O = async () => {
548
- const i = window.translate;
549
- i && (i.selectLanguageTag.show = !1, i.selectLanguageTag.languages = (await c()).map((w) => w.key).join(","), i.ignore.class.push("ignore-translate-flag"), i.ignore.id.push("ignore-translation"), i.language.setLocal(h()), i.request.api.translate = "api/v1/translation", i.request.api.connectTest = "api/v1/translation/connect-test", i.request.api.init = "api/v1/translation/init", i.request.api.language = "api/v1/translation/language", i.request.setHost(u()), i.request.listener.start(), i.listener.start(), i.whole.enableAll(), i.execute());
418
+ getLanguages: i,
419
+ getCurrentLanguage: _,
420
+ getDefaultLanguage: g,
421
+ getTranslationApiUrl: c
422
+ } = Mt(), P = N(), m = N([]), T = async (s) => await n(s), L = async () => {
423
+ const s = window.translate;
424
+ s && (s.selectLanguageTag.show = !1, s.selectLanguageTag.languages = (await i()).map((y) => y.key).join(","), s.ignore.class.push("ignore-translate-flag"), s.ignore.id.push("ignore-translation"), s.language.setLocal(g()), s.request.api.translate = "api/v1/translation", s.request.api.connectTest = "api/v1/translation/connect-test", s.request.api.init = "api/v1/translation/init", s.request.api.language = "api/v1/translation/language", s.request.setHost(c()), s.request.listener.start(), s.listener.start(), s.whole.enableAll(), s.execute());
550
425
  };
551
426
  return Q(async () => {
552
- await ne(), await O(), k.value = await y(), _.value = await c();
553
- }), (i, w) => {
554
- const d = M, C = K;
555
- return _.value.length > 0 ? (p(), S(a(Z), {
427
+ await se(), await L(), P.value = await _(), m.value = await i();
428
+ }), (s, y) => {
429
+ const r = D, $ = ve;
430
+ return m.value.length > 0 ? (h(), C(a(G), {
556
431
  key: 0,
557
432
  id: "ignore-translation",
558
433
  placement: "bottom-start",
559
434
  trigger: "hover",
560
435
  class: "flex flex-col justify-center h-full ignore",
561
436
  onSelect: T,
562
- options: _.value
437
+ options: m.value
563
438
  }, {
564
- default: l(() => [
565
- r(C, {
439
+ default: o(() => [
440
+ l($, {
566
441
  quaternary: "",
567
442
  type: "info"
568
443
  }, {
569
- default: l(() => [
570
- k.value ? (p(), R("label", Qt, H(k.value?.label), 1)) : (p(), S(d, {
444
+ default: o(() => [
445
+ P.value ? (h(), M("label", It, q(P.value?.label), 1)) : (h(), C(r, {
571
446
  key: 0,
572
447
  size: "18"
573
448
  }, {
574
- default: l(() => [...w[0] || (w[0] = [
449
+ default: o(() => [...y[0] || (y[0] = [
575
450
  b("svg", {
576
451
  xmlns: "http://www.w3.org/2000/svg",
577
452
  "xmlns:xlink": "http://www.w3.org/1999/xlink",
@@ -594,57 +469,57 @@ const je = (t) => {
594
469
  })
595
470
  ]),
596
471
  _: 1
597
- }, 8, ["options"])) : N("", !0);
472
+ }, 8, ["options"])) : I("", !0);
598
473
  };
599
474
  }
600
- }), ea = { class: "layout-header" }, ta = { class: "layout-header-left" }, aa = { class: "link-text" }, na = {
475
+ }), Bt = { class: "layout-header" }, Ht = { class: "layout-header-left" }, Wt = { class: "link-text" }, Ut = {
601
476
  key: 1,
602
477
  class: "link-text"
603
- }, oa = { class: "layout-header-right" }, la = {
478
+ }, jt = { class: "layout-header-right" }, qt = {
604
479
  key: 0,
605
480
  class: "layout-header-trigger-min"
606
- }, sa = { class: "layout-header-trigger layout-header-trigger-min" }, ra = { class: "layout-header-trigger layout-header-trigger-min" }, ia = { class: "avatar" }, ca = /* @__PURE__ */ I({
481
+ }, Ft = { class: "layout-header-trigger layout-header-trigger-min" }, Vt = { class: "layout-header-trigger layout-header-trigger-min" }, Kt = { class: "avatar" }, Yt = /* @__PURE__ */ B({
607
482
  __name: "PHeader",
608
- setup(t) {
609
- const n = fe(), c = Ne(), y = se(), h = oe(), u = le(), k = Ie("reloadPage"), _ = (f) => h.push({ name: f }), T = F(() => O(u.matched)), O = (f) => f.map((P) => {
610
- const v = {
611
- key: P.name,
612
- label: P.meta.title,
613
- icon: P.meta.icon,
614
- meta: P.meta,
615
- disabled: P.path === "/",
483
+ setup(e) {
484
+ const n = ue(), i = $e(), _ = re(), g = le(), c = ce(), P = Re("reloadPage"), m = (u) => g.push({ name: u }), T = K(() => L(c.matched)), L = (u) => u.map((v) => {
485
+ const p = {
486
+ key: v.name,
487
+ label: v.meta.title,
488
+ icon: v.meta.icon,
489
+ meta: v.meta,
490
+ disabled: v.path === "/",
616
491
  children: void 0
617
492
  };
618
- return P.children && P.children.length > 0 && (v.children = O(
619
- P.children
620
- )), v;
621
- }), i = $(!1), w = () => {
622
- document.fullscreenElement ? document.exitFullscreen && (document.exitFullscreen(), i.value = !1) : (document.documentElement.requestFullscreen(), i.value = !0);
623
- }, d = F(() => {
624
- const f = [];
625
- return f.push({
493
+ return v.children && v.children.length > 0 && (p.children = L(
494
+ v.children
495
+ )), p;
496
+ }), s = N(!1), y = () => {
497
+ document.fullscreenElement ? document.exitFullscreen && (document.exitFullscreen(), s.value = !1) : (document.documentElement.requestFullscreen(), s.value = !0);
498
+ }, r = K(() => {
499
+ const u = [];
500
+ return u.push({
626
501
  label: "退出登录",
627
502
  key: "logout"
628
- }), y.state.settingPages && y.state.settingPages.length > 0 && y.state.settingPages.forEach((P) => {
629
- f.push({
630
- label: P.title,
631
- key: P.route
503
+ }), _.state.settingPages && _.state.settingPages.length > 0 && _.state.settingPages.forEach((v) => {
504
+ u.push({
505
+ label: v.title,
506
+ key: v.route
632
507
  });
633
- }), f;
634
- }), C = (f) => {
635
- f === "logout" ? m() : h.push({ name: f });
636
- }, m = () => {
637
- c.info({
508
+ }), u;
509
+ }), $ = (u) => {
510
+ u === "logout" ? z() : g.push({ name: u });
511
+ }, z = () => {
512
+ i.info({
638
513
  title: "提示",
639
514
  content: "您确定要退出登录吗",
640
515
  positiveText: "确定",
641
516
  negativeText: "取消",
642
517
  onPositiveClick: async () => {
643
- if (y.state.logout)
518
+ if (_.state.logout)
644
519
  try {
645
- await y.state.logout(), localStorage.removeItem("TABS-ROUTES"), n.error("退出成功");
646
- } catch (f) {
647
- console.error(f), n.error("退出登录失败");
520
+ await _.state.logout(), localStorage.removeItem("TABS-ROUTES"), n.error("退出成功");
521
+ } catch (u) {
522
+ console.error(u), n.error("退出登录失败");
648
523
  } finally {
649
524
  location.reload();
650
525
  }
@@ -655,112 +530,112 @@ const je = (t) => {
655
530
  }
656
531
  });
657
532
  };
658
- return (f, P) => {
659
- const v = ze, A = Qe, E = Le;
660
- return p(), R("div", ea, [
661
- b("div", ta, [
533
+ return (u, v) => {
534
+ const p = Ee, A = He, O = be;
535
+ return h(), M("div", Bt, [
536
+ b("div", Ht, [
662
537
  b("div", {
663
538
  class: "ml-1 layout-header-trigger layout-header-trigger-min",
664
- onClick: P[0] || (P[0] = //@ts-ignore
665
- (...x) => a(y).collapse && a(y).collapse(...x))
539
+ onClick: v[0] || (v[0] = //@ts-ignore
540
+ (...S) => a(_).collapse && a(_).collapse(...S))
666
541
  }, [
667
- a(y).state.collapsed ? (p(), S(a(M), {
542
+ a(_).state.collapsed ? (h(), C(a(D), {
668
543
  key: 0,
669
544
  size: "18"
670
545
  }, {
671
- default: l(() => [
672
- r(a(St))
546
+ default: o(() => [
547
+ l(a(ht))
673
548
  ]),
674
549
  _: 1
675
- })) : (p(), S(a(M), {
550
+ })) : (h(), C(a(D), {
676
551
  key: 1,
677
552
  size: "18"
678
553
  }, {
679
- default: l(() => [
680
- r(a(Tt))
554
+ default: o(() => [
555
+ l(a(mt))
681
556
  ]),
682
557
  _: 1
683
558
  }))
684
559
  ]),
685
560
  b("div", {
686
561
  class: "mr-1 layout-header-trigger layout-header-trigger-min",
687
- onClick: P[1] || (P[1] = //@ts-ignore
688
- (...x) => a(k) && a(k)(...x))
562
+ onClick: v[1] || (v[1] = //@ts-ignore
563
+ (...S) => a(P) && a(P)(...S))
689
564
  }, [
690
- r(a(M), { size: "18" }, {
691
- default: l(() => [
692
- r(a(Se))
565
+ l(a(D), { size: "18" }, {
566
+ default: o(() => [
567
+ l(a(Pe))
693
568
  ]),
694
569
  _: 1
695
570
  })
696
571
  ]),
697
- r(a(Je), null, {
698
- default: l(() => [
699
- (p(!0), R(Me, null, _t(T.value, (x) => (p(), R(Me, {
700
- key: x.label
572
+ l(a(Ie), null, {
573
+ default: o(() => [
574
+ (h(!0), M(Se, null, lt(T.value, (S) => (h(), M(Se, {
575
+ key: S.label
701
576
  }, [
702
- x.label ? (p(), S(a(Ze), { key: 0 }, {
703
- default: l(() => [
704
- x.children && x.children.length ? (p(), S(a(Z), {
577
+ S.label ? (h(), C(a(Be), { key: 0 }, {
578
+ default: o(() => [
579
+ S.children && S.children.length ? (h(), C(a(G), {
705
580
  key: 0,
706
- options: x.children,
707
- onSelect: _
581
+ options: S.children,
582
+ onSelect: m
708
583
  }, {
709
- default: l(() => [
710
- b("span", aa, [
711
- x.icon ? (p(), S(we(x.icon), { key: 0 })) : N("", !0),
712
- b("span", null, H(x.label), 1)
584
+ default: o(() => [
585
+ b("span", Wt, [
586
+ S.icon ? (h(), C(he(S.icon), { key: 0 })) : I("", !0),
587
+ b("span", null, q(S.label), 1)
713
588
  ])
714
589
  ]),
715
590
  _: 2
716
- }, 1032, ["options"])) : (p(), R("span", na, [
717
- x.icon ? (p(), S(we(x.icon), { key: 0 })) : N("", !0),
718
- b("span", null, H(x.label), 1)
591
+ }, 1032, ["options"])) : (h(), M("span", Ut, [
592
+ S.icon ? (h(), C(he(S.icon), { key: 0 })) : I("", !0),
593
+ b("span", null, q(S.label), 1)
719
594
  ]))
720
595
  ]),
721
596
  _: 2
722
- }, 1024)) : N("", !0)
597
+ }, 1024)) : I("", !0)
723
598
  ], 64))), 128))
724
599
  ]),
725
600
  _: 1
726
601
  })
727
602
  ]),
728
- b("div", oa, [
729
- a(y).state.enableLanguage ? (p(), R("div", la, [
730
- r(He)
731
- ])) : N("", !0),
732
- b("div", sa, [
733
- r(v, { placement: "bottom" }, {
734
- trigger: l(() => [
735
- r(a(M), {
603
+ b("div", jt, [
604
+ a(_).state.enableLanguage ? (h(), M("div", qt, [
605
+ l(Ae)
606
+ ])) : I("", !0),
607
+ b("div", Ft, [
608
+ l(p, { placement: "bottom" }, {
609
+ trigger: o(() => [
610
+ l(a(D), {
736
611
  size: "18",
737
- onClick: Pe(w, ["stop"])
612
+ onClick: me(y, ["stop"])
738
613
  }, {
739
- default: l(() => [
740
- i.value ? (p(), S(a(Ot), { key: 1 })) : (p(), S(a($t), { key: 0 }))
614
+ default: o(() => [
615
+ s.value ? (h(), C(a(vt), { key: 1 })) : (h(), C(a(_t), { key: 0 }))
741
616
  ]),
742
617
  _: 1
743
618
  })
744
619
  ]),
745
- default: l(() => [
746
- P[2] || (P[2] = b("span", null, "全屏", -1))
620
+ default: o(() => [
621
+ v[2] || (v[2] = b("span", null, "全屏", -1))
747
622
  ]),
748
623
  _: 1
749
624
  })
750
625
  ]),
751
- b("div", ra, [
752
- r(a(Z), {
626
+ b("div", Vt, [
627
+ l(a(G), {
753
628
  trigger: "hover",
754
- onSelect: C,
755
- options: d.value
629
+ onSelect: $,
630
+ options: r.value
756
631
  }, {
757
- default: l(() => [
758
- b("div", ia, [
759
- b("span", null, H(a(y).state.uname), 1),
760
- r(A, { vertical: "" }),
761
- r(E, {
632
+ default: o(() => [
633
+ b("div", Kt, [
634
+ b("span", null, q(a(_).state.uname), 1),
635
+ l(A, { vertical: "" }),
636
+ l(O, {
762
637
  round: "",
763
- src: a(y).state.avatar
638
+ src: a(_).state.avatar
764
639
  }, null, 8, ["src"])
765
640
  ])
766
641
  ]),
@@ -771,20 +646,20 @@ const je = (t) => {
771
646
  ]);
772
647
  };
773
648
  }
774
- }), ua = /* @__PURE__ */ U(ca, [["__scopeId", "data-v-563e4e55"]]), da = { class: "mt-1" }, fa = /* @__PURE__ */ I({
649
+ }), Xt = /* @__PURE__ */ F(Yt, [["__scopeId", "data-v-563e4e55"]]), Jt = { class: "mt-1" }, Zt = /* @__PURE__ */ B({
775
650
  __name: "PContent",
776
651
  props: {
777
652
  loading: { type: Boolean, default: !1 }
778
653
  },
779
- setup(t) {
780
- return (n, c) => {
781
- const y = Be("RouterView");
782
- return p(), R("div", da, [
783
- t.loading ? N("", !0) : (p(), S(y, { key: 0 }, {
784
- default: l(({ Component: h, route: u }) => [
785
- (p(), S(yt, null, [
786
- (p(), S(we(h), {
787
- key: u.fullPath
654
+ setup(e) {
655
+ return (n, i) => {
656
+ const _ = Ne("RouterView");
657
+ return h(), M("div", Jt, [
658
+ e.loading ? I("", !0) : (h(), C(_, { key: 0 }, {
659
+ default: o(({ Component: g, route: c }) => [
660
+ (h(), C(ct, null, [
661
+ (h(), C(he(g), {
662
+ key: c.fullPath
788
663
  }))
789
664
  ], 1024))
790
665
  ]),
@@ -793,259 +668,259 @@ const je = (t) => {
793
668
  ]);
794
669
  };
795
670
  }
796
- }), ga = { class: "tabs-view-main" }, pa = ["id", "onClick", "onContextmenu"], ha = { class: "tabs-close" }, ma = { class: "tabs-close-btn" }, va = /* @__PURE__ */ I({
671
+ }), Gt = { class: "tabs-view-main" }, Qt = ["id", "onClick", "onContextmenu"], ea = { class: "tabs-close" }, ta = { class: "tabs-close-btn" }, aa = /* @__PURE__ */ B({
797
672
  __name: "PTabs",
798
- setup(t) {
799
- bt((e) => ({
800
- v141ddb06: c.value,
801
- cf709148: y.value
673
+ setup(e) {
674
+ rt((t) => ({
675
+ v141ddb06: i.value,
676
+ cf709148: _.value
802
677
  }));
803
- const n = et(), c = F(() => n.value.cardColor), y = F(() => n.value.textColor1), h = fe(), u = le(), k = oe(), _ = $(null), T = $(null), O = $(!1), i = se(), w = F(() => i.state.tabs), d = xe({
804
- activeKey: u.fullPath,
678
+ const n = We(), i = K(() => n.value.cardColor), _ = K(() => n.value.textColor1), g = ue(), c = ce(), P = le(), m = N(null), T = N(null), L = N(!1), s = re(), y = K(() => s.state.tabs), r = we({
679
+ activeKey: c.fullPath,
805
680
  scrollable: !0,
806
681
  dropdownX: 0,
807
682
  dropdownY: 0,
808
683
  showDropdown: !1,
809
684
  isMultiHeaderFixed: !0,
810
685
  multiTabsSetting: !0
811
- }), C = ["Login", "Redirect", "ErrorPage"], m = (e) => {
812
- const { fullPath: o, hash: s, meta: L, name: D, params: z, path: V, query: ue } = e;
813
- return { fullPath: o, hash: s, meta: L, name: D, params: z, path: V, query: ue };
814
- }, f = F(() => {
815
- const s = i.state.collapsed ? "64px" : "272px";
686
+ }), $ = ["Login", "Redirect", "ErrorPage"], z = (t) => {
687
+ const { fullPath: d, hash: f, meta: R, name: V, params: ae, path: ne, query: ie } = t;
688
+ return { fullPath: d, hash: f, meta: R, name: V, params: ae, path: ne, query: ie };
689
+ }, u = K(() => {
690
+ const f = s.state.collapsed ? "64px" : "272px";
816
691
  return {
817
- left: s,
818
- width: `calc(100% - ${s})`
692
+ left: f,
693
+ width: `calc(100% - ${f})`
819
694
  };
820
- }), P = F(() => {
821
- const e = w.value.length <= 1;
695
+ }), v = K(() => {
696
+ const t = y.value.length <= 1;
822
697
  return [
823
698
  {
824
699
  label: "刷新当前",
825
700
  key: "1",
826
- icon: () => W(M, null, { default: () => W(Se) })
701
+ icon: () => U(D, null, { default: () => U(Pe) })
827
702
  },
828
703
  {
829
704
  label: "关闭当前",
830
705
  key: "2",
831
- disabled: O.value || e,
832
- icon: () => W(M, null, { default: () => W(Re) })
706
+ disabled: L.value || t,
707
+ icon: () => U(D, null, { default: () => U(Te) })
833
708
  },
834
709
  {
835
710
  label: "关闭其他",
836
711
  key: "3",
837
- disabled: e,
838
- icon: () => W(M, null, { default: () => W(Et) })
712
+ disabled: t,
713
+ icon: () => U(D, null, { default: () => U(bt) })
839
714
  },
840
715
  {
841
716
  label: "关闭全部",
842
717
  key: "4",
843
- disabled: e,
844
- icon: () => W(M, null, { default: () => W(Mt) })
718
+ disabled: t,
719
+ icon: () => U(D, null, { default: () => U(yt) })
845
720
  }
846
721
  ];
847
- }), v = () => {
848
- let e = [];
849
- const o = m(u);
722
+ }), p = () => {
723
+ let t = [];
724
+ const d = z(c);
850
725
  try {
851
- if (i.state.cacheTabs) {
852
- const s = localStorage.getItem("TABS_ROUTES");
853
- e = s ? JSON.parse(s) : [o];
726
+ if (s.state.cacheTabs) {
727
+ const f = localStorage.getItem("TABS_ROUTES");
728
+ t = f ? JSON.parse(f) : [d];
854
729
  }
855
730
  } catch {
856
- e = [o];
731
+ t = [d];
857
732
  } finally {
858
- return e;
733
+ return t;
859
734
  }
860
- }, A = (e) => {
861
- const o = k.getRoutes();
862
- e.forEach((s) => {
863
- const L = o.find((D) => D.path === s.path);
864
- L && (s.meta = L.meta || s.meta, s.name = L.name || s.name);
865
- }), i.state.cacheTabs && localStorage.setItem("TABS_ROUTES", JSON.stringify(e));
866
- }, E = () => {
867
- const e = v();
868
- A(e), i.initTabs(e);
869
- }, x = async (e) => {
870
- if (await ne(), !_.value) return;
871
- const o = _.value.offsetWidth, s = _.value.scrollWidth;
872
- o < s ? (d.scrollable = !0, e && [..._.value.querySelectorAll(".tabs-card-scroll-item") || []].forEach((D) => {
873
- D.id === `tag${d.activeKey.split("/").join("/")}` && D.scrollIntoView && D.scrollIntoView();
874
- })) : d.scrollable = !1;
875
- }, ee = (e) => !(e.draggedContext.element.meta.affix || e.relatedContext.element.meta.affix), ge = () => {
876
- let e;
877
- e = It(), e.listenTo(T.value, () => x(!0));
878
- }, re = (e) => {
879
- const { fullPath: o } = e;
880
- if (o === u.fullPath || (d.activeKey = o, !e))
735
+ }, A = (t) => {
736
+ const d = P.getRoutes();
737
+ t.forEach((f) => {
738
+ const R = d.find((V) => V.path === f.path);
739
+ R && (f.meta = R.meta || f.meta, f.name = R.name || f.name);
740
+ }), s.state.cacheTabs && localStorage.setItem("TABS_ROUTES", JSON.stringify(t));
741
+ }, O = () => {
742
+ const t = p();
743
+ A(t), s.initTabs(t);
744
+ }, S = async (t) => {
745
+ if (await se(), !m.value) return;
746
+ const d = m.value.offsetWidth, f = m.value.scrollWidth;
747
+ d < f ? (r.scrollable = !0, t && [...m.value.querySelectorAll(".tabs-card-scroll-item") || []].forEach((V) => {
748
+ V.id === `tag${r.activeKey.split("/").join("/")}` && V.scrollIntoView && V.scrollIntoView();
749
+ })) : r.scrollable = !1;
750
+ }, ee = (t) => !(t.draggedContext.element.meta.affix || t.relatedContext.element.meta.affix), de = () => {
751
+ let t;
752
+ t = xt(), t.listenTo(T.value, () => S(!0));
753
+ }, w = (t) => {
754
+ const { fullPath: d } = t;
755
+ if (d === c.fullPath || (r.activeKey = d, !t))
881
756
  return;
882
- const { replace: s } = k;
883
- toString.call(e), s(e).catch(console.error);
884
- }, ie = (e, o) => {
885
- e.preventDefault(), O.value = o.path === "/home", d.showDropdown = !1, ne().then(() => {
886
- d.showDropdown = !0, d.dropdownX = e.clientX, d.dropdownY = e.clientY;
757
+ const { replace: f } = P;
758
+ toString.call(t), f(t).catch(console.error);
759
+ }, k = (t, d) => {
760
+ t.preventDefault(), L.value = d.path === "/home", r.showDropdown = !1, se().then(() => {
761
+ r.showDropdown = !0, r.dropdownX = t.clientX, r.dropdownY = t.clientY;
887
762
  });
888
- }, X = () => {
889
- if (u.meta.keepAlive) {
890
- var e = k.currentRoute.value.matched.find(
891
- (o) => o.name == u.name
763
+ }, x = () => {
764
+ if (c.meta.keepAlive) {
765
+ var t = P.currentRoute.value.matched.find(
766
+ (d) => d.name == c.name
892
767
  );
893
- e && e.components?.default?.name;
768
+ t && t.components?.default?.name;
894
769
  }
895
- }, G = (e) => {
896
- if (w.value.length === 1)
897
- return h.warning("这已经是最后一页,不能再关闭了!");
898
- if (X(), i.closeCurrentTab(e), d.activeKey === e.fullPath) {
899
- const o = w.value[Math.max(0, w.value.length - 1)];
900
- d.activeKey = o.fullPath, k.push(o);
770
+ }, E = (t) => {
771
+ if (y.value.length === 1)
772
+ return g.warning("这已经是最后一页,不能再关闭了!");
773
+ if (x(), s.closeCurrentTab(t), r.activeKey === t.fullPath) {
774
+ const d = y.value[Math.max(0, y.value.length - 1)];
775
+ r.activeKey = d.fullPath, P.push(d);
901
776
  }
902
- x();
903
- }, pe = (e) => {
904
- const { fullPath: o } = e, s = w.value.find((L) => L.fullPath == o);
905
- G(s);
906
- }, he = (e) => {
907
- i.closeOtherTabs(e), d.activeKey = e.fullPath, k.replace(e.fullPath), x();
908
- }, q = () => {
909
- i.closeAllTabs(), x();
910
- }, me = Ie("reloadPage"), ce = (e) => {
911
- switch (e) {
777
+ S();
778
+ }, H = (t) => {
779
+ const { fullPath: d } = t, f = y.value.find((R) => R.fullPath == d);
780
+ E(f);
781
+ }, j = (t) => {
782
+ s.closeOtherTabs(t), r.activeKey = t.fullPath, P.replace(t.fullPath), S();
783
+ }, Z = () => {
784
+ s.closeAllTabs(), S();
785
+ }, X = Re("reloadPage"), te = (t) => {
786
+ switch (t) {
912
787
  //刷新
913
788
  case "1":
914
- me();
789
+ X();
915
790
  break;
916
791
  //关闭
917
792
  case "2":
918
- G(u);
793
+ E(c);
919
794
  break;
920
795
  //关闭其他
921
796
  case "3":
922
- he(u);
797
+ j(c);
923
798
  break;
924
799
  //关闭所有
925
800
  case "4":
926
- q();
801
+ Z();
927
802
  break;
928
803
  }
929
- x(), d.showDropdown = !1;
930
- }, te = (e, o) => {
931
- const s = _.value.scrollLeft, L = o > 0 && s + o >= e || o < 0 && s + o <= e ? e : s + o;
932
- if (_.value && _.value.scrollTo(L, 0), L !== e)
933
- return window.requestAnimationFrame(() => te(e, o));
934
- }, ve = () => {
935
- const e = _.value.offsetWidth, o = _.value.scrollLeft;
936
- if (!o) return;
937
- const s = o > e ? o - e : 0;
938
- te(s, (s - o) / 20);
939
- }, g = () => {
940
- const e = _.value.offsetWidth, o = _.value.scrollWidth, s = _.value.scrollLeft;
941
- if (o - s <= e) return;
942
- const L = o - s > e * 2 ? s + e : o - e;
943
- te(L, (L - s) / 20);
804
+ S(), r.showDropdown = !1;
805
+ }, J = (t, d) => {
806
+ const f = m.value.scrollLeft, R = d > 0 && f + d >= t || d < 0 && f + d <= t ? t : f + d;
807
+ if (m.value && m.value.scrollTo(R, 0), R !== t)
808
+ return window.requestAnimationFrame(() => J(t, d));
809
+ }, fe = () => {
810
+ const t = m.value.offsetWidth, d = m.value.scrollLeft;
811
+ if (!d) return;
812
+ const f = d > t ? d - t : 0;
813
+ J(f, (f - d) / 20);
814
+ }, ge = () => {
815
+ const t = m.value.offsetWidth, d = m.value.scrollWidth, f = m.value.scrollLeft;
816
+ if (d - f <= t) return;
817
+ const R = d - f > t * 2 ? f + t : d - t;
818
+ J(R, (R - f) / 20);
944
819
  };
945
820
  return window.addEventListener("beforeunload", () => {
946
- localStorage.setItem("TABS_ROUTES", JSON.stringify(w.value));
821
+ localStorage.setItem("TABS_ROUTES", JSON.stringify(y.value));
947
822
  }), window.addEventListener(
948
823
  "scroll",
949
- (e) => {
950
- let o = e.target.scrollTop || document.documentElement.scrollTop || window.pageYOffset || document.body.scrollTop;
951
- d.isMultiHeaderFixed = o >= 64;
824
+ (t) => {
825
+ let d = t.target.scrollTop || document.documentElement.scrollTop || window.pageYOffset || document.body.scrollTop;
826
+ r.isMultiHeaderFixed = d >= 64;
952
827
  },
953
828
  !0
954
- ), We(
955
- () => u.fullPath,
956
- (e) => {
957
- C.includes(u.name) || (d.activeKey = e, i.addTab(m(u)), x(!0));
829
+ ), ze(
830
+ () => c.fullPath,
831
+ (t) => {
832
+ $.includes(c.name) || (r.activeKey = t, s.addTab(z(c)), S(!0));
958
833
  },
959
834
  { immediate: !0 }
960
- ), E(), Q(() => ge()), (e, o) => (p(), R("div", {
835
+ ), O(), Q(() => de()), (t, d) => (h(), M("div", {
961
836
  class: "box-border tabs-view tabs-view-fix tabs-view-default-background",
962
- style: de(f.value)
837
+ style: De(u.value)
963
838
  }, [
964
- b("div", ga, [
839
+ b("div", Gt, [
965
840
  b("div", {
966
841
  ref_key: "navWrap",
967
842
  ref: T,
968
- class: ae(["tabs-card", { "tabs-card-scrollable": d.scrollable }])
843
+ class: oe(["tabs-card", { "tabs-card-scrollable": r.scrollable }])
969
844
  }, [
970
845
  b("span", {
971
- class: ae(["tabs-card-prev", { "tabs-card-prev-hide": !d.scrollable }]),
972
- onClick: ve
846
+ class: oe(["tabs-card-prev", { "tabs-card-prev-hide": !r.scrollable }]),
847
+ onClick: fe
973
848
  }, [
974
- r(a(M), {
849
+ l(a(D), {
975
850
  size: "16",
976
851
  color: "#515a6e"
977
852
  }, {
978
- default: l(() => [
979
- r(a(Rt))
853
+ default: o(() => [
854
+ l(a(wt))
980
855
  ]),
981
856
  _: 1
982
857
  })
983
858
  ], 2),
984
859
  b("span", {
985
- class: ae(["tabs-card-next", { "tabs-card-next-hide": !d.scrollable }]),
986
- onClick: g
860
+ class: oe(["tabs-card-next", { "tabs-card-next-hide": !r.scrollable }]),
861
+ onClick: ge
987
862
  }, [
988
- r(a(M), {
863
+ l(a(D), {
989
864
  size: "16",
990
865
  color: "#515a6e"
991
866
  }, {
992
- default: l(() => [
993
- r(a(Nt))
867
+ default: o(() => [
868
+ l(a(Pt))
994
869
  ]),
995
870
  _: 1
996
871
  })
997
872
  ], 2),
998
873
  b("div", {
999
874
  ref_key: "navScroll",
1000
- ref: _,
875
+ ref: m,
1001
876
  class: "tabs-card-scroll"
1002
877
  }, [
1003
- r(a(Bt), {
1004
- list: w.value,
878
+ l(a(Ct), {
879
+ list: y.value,
1005
880
  animation: "300",
1006
881
  "item-key": "fullPath",
1007
882
  class: "flex",
1008
883
  move: ee
1009
884
  }, {
1010
- item: l(({ element: s }) => [
885
+ item: o(({ element: f }) => [
1011
886
  b("div", {
1012
- id: `tag${s.fullPath.split("/").join("/")}`,
1013
- class: ae(["tabs-card-scroll-item", { "active-item": d.activeKey === s.fullPath }]),
1014
- onClick: Pe((L) => re(s), ["stop"]),
1015
- onContextmenu: (L) => ie(L, s)
887
+ id: `tag${f.fullPath.split("/").join("/")}`,
888
+ class: oe(["tabs-card-scroll-item", { "active-item": r.activeKey === f.fullPath }]),
889
+ onClick: me((R) => w(f), ["stop"]),
890
+ onContextmenu: (R) => k(R, f)
1016
891
  }, [
1017
- b("span", null, H(s.meta.title), 1),
1018
- s.meta.affix ? N("", !0) : (p(), S(a(M), {
892
+ b("span", null, q(f.meta.title), 1),
893
+ f.meta.affix ? I("", !0) : (h(), C(a(D), {
1019
894
  key: 0,
1020
895
  size: "14",
1021
- onClick: Pe((L) => pe(s), ["stop"])
896
+ onClick: me((R) => H(f), ["stop"])
1022
897
  }, {
1023
- default: l(() => [
1024
- r(a(Re))
898
+ default: o(() => [
899
+ l(a(Te))
1025
900
  ]),
1026
901
  _: 1
1027
902
  }, 8, ["onClick"]))
1028
- ], 42, pa)
903
+ ], 42, Qt)
1029
904
  ]),
1030
905
  _: 1
1031
906
  }, 8, ["list"])
1032
907
  ], 512)
1033
908
  ], 2),
1034
- b("div", ha, [
1035
- r(a(Z), {
909
+ b("div", ea, [
910
+ l(a(G), {
1036
911
  trigger: "hover",
1037
- onSelect: ce,
912
+ onSelect: te,
1038
913
  placement: "bottom-end",
1039
- options: P.value
914
+ options: v.value
1040
915
  }, {
1041
- default: l(() => [
1042
- b("div", ma, [
1043
- r(a(M), {
916
+ default: o(() => [
917
+ b("div", ta, [
918
+ l(a(D), {
1044
919
  size: "16",
1045
920
  color: "#515a6e"
1046
921
  }, {
1047
- default: l(() => [
1048
- r(a(At))
922
+ default: o(() => [
923
+ l(a(kt))
1049
924
  ]),
1050
925
  _: 1
1051
926
  })
@@ -1054,115 +929,115 @@ const je = (t) => {
1054
929
  _: 1
1055
930
  }, 8, ["options"])
1056
931
  ]),
1057
- r(a(Z), {
1058
- show: d.showDropdown,
1059
- x: d.dropdownX,
1060
- y: d.dropdownY,
1061
- onClickoutside: o[0] || (o[0] = (s) => d.showDropdown = !1),
932
+ l(a(G), {
933
+ show: r.showDropdown,
934
+ x: r.dropdownX,
935
+ y: r.dropdownY,
936
+ onClickoutside: d[0] || (d[0] = (f) => r.showDropdown = !1),
1062
937
  placement: "bottom-start",
1063
- onSelect: ce,
1064
- options: P.value
938
+ onSelect: te,
939
+ options: v.value
1065
940
  }, null, 8, ["show", "x", "y", "options"])
1066
941
  ])
1067
942
  ], 4));
1068
943
  }
1069
- }), _a = /* @__PURE__ */ U(va, [["__scopeId", "data-v-48b3be2d"]]), ya = /* @__PURE__ */ I({
944
+ }), na = /* @__PURE__ */ F(aa, [["__scopeId", "data-v-48b3be2d"]]), oa = /* @__PURE__ */ B({
1070
945
  __name: "PMenus",
1071
- setup(t) {
1072
- const n = le(), c = oe(), y = se(), h = $(n.name), u = $(
1073
- n.matched && n.matched.length ? n.matched.map((d) => d.name) : []
1074
- ), k = $([]), _ = (d) => {
1075
- /http(s)?:/.test(d) ? window.open(d) : c.push({ name: d });
1076
- }, T = (d) => {
1077
- if (!d) return;
1078
- const C = d.find((m) => u.value.indexOf(m) === -1);
1079
- u.value = C ? [C] : [];
1080
- }, O = () => {
1081
- const d = n.matched;
1082
- u.value = d.map((m) => m.name);
1083
- const C = n.meta?.activeMenu || "";
1084
- h.value = C || n.name;
1085
- }, i = (d, C = [], m = !1) => {
1086
- const f = [], P = [
946
+ setup(e) {
947
+ const n = ce(), i = le(), _ = re(), g = N(n.name), c = N(
948
+ n.matched && n.matched.length ? n.matched.map((r) => r.name) : []
949
+ ), P = N([]), m = (r) => {
950
+ /http(s)?:/.test(r) ? window.open(r) : i.push({ name: r });
951
+ }, T = (r) => {
952
+ if (!r) return;
953
+ const $ = r.find((z) => c.value.indexOf(z) === -1);
954
+ c.value = $ ? [$] : [];
955
+ }, L = () => {
956
+ const r = n.matched;
957
+ c.value = r.map((z) => z.name);
958
+ const $ = n.meta?.activeMenu || "";
959
+ g.value = $ || n.name;
960
+ }, s = (r, $ = [], z = !1) => {
961
+ const u = [], v = [
1087
962
  "/:path(.*)*",
1088
963
  "/redirect",
1089
964
  "/redirect/:path(.*)",
1090
965
  "/login",
1091
966
  "/oidc-callback"
1092
967
  ];
1093
- if (!d || d.length === 0)
1094
- return f;
1095
- d = d.sort((v, A) => {
1096
- let E = (A.children?.length ? 1 : 0) - (v.children?.length ? 1 : 0);
1097
- return E === 0 && (E = (v.meta?.sort ?? 0) - (A.meta?.sort ?? 0)), E;
968
+ if (!r || r.length === 0)
969
+ return u;
970
+ r = r.sort((p, A) => {
971
+ let O = (A.children?.length ? 1 : 0) - (p.children?.length ? 1 : 0);
972
+ return O === 0 && (O = (p.meta?.sort ?? 0) - (A.meta?.sort ?? 0)), O;
1098
973
  });
1099
- for (const v of d) {
1100
- if (m || (v.meta?.hidden || !1) == !0 || P.includes(v.path)) {
1101
- C.push(v.name), v.children && v.children.length > 0 && i(v.children, C, !0);
974
+ for (const p of r) {
975
+ if (z || (p.meta?.hidden || !1) == !0 || v.includes(p.path)) {
976
+ $.push(p.name), p.children && p.children.length > 0 && s(p.children, $, !0);
1102
977
  continue;
1103
978
  }
1104
- const A = v.meta?.alwaysShow != !0 && v?.children?.filter((ee) => !ee?.meta?.hidden)?.length === 1, E = A ? v.children[0] : v, x = {
1105
- key: E.name,
1106
- label: E.meta?.title,
1107
- affix: E.meta?.affix,
1108
- sort: E.meta?.sort,
1109
- path: E.path,
1110
- redirect: E.redirect,
1111
- icon: A ? v.meta?.icon : E.meta?.icon,
1112
- permissions: E.meta?.permissions,
1113
- meta: E.meta,
979
+ const A = p.meta?.alwaysShow != !0 && p?.children?.filter((ee) => !ee?.meta?.hidden)?.length === 1, O = A ? p.children[0] : p, S = {
980
+ key: O.name,
981
+ label: O.meta?.title,
982
+ affix: O.meta?.affix,
983
+ sort: O.meta?.sort,
984
+ path: O.path,
985
+ redirect: O.redirect,
986
+ icon: A ? p.meta?.icon : O.meta?.icon,
987
+ permissions: O.meta?.permissions,
988
+ meta: O.meta,
1114
989
  children: void 0
1115
990
  };
1116
- if (!C.includes(v.name)) {
1117
- if (f.push(x), C.push(v.name), A) {
1118
- i(v.children, C, m);
991
+ if (!$.includes(p.name)) {
992
+ if (u.push(S), $.push(p.name), A) {
993
+ s(p.children, $, z);
1119
994
  continue;
1120
995
  }
1121
- v.children && v.children.length > 0 && (x.children = i(v.children, C, m));
996
+ p.children && p.children.length > 0 && (S.children = s(p.children, $, z));
1122
997
  }
1123
998
  }
1124
- return f;
1125
- }, w = () => {
1126
- const d = c.getRoutes();
1127
- k.value = i(d);
999
+ return u;
1000
+ }, y = () => {
1001
+ const r = i.getRoutes();
1002
+ P.value = s(r);
1128
1003
  };
1129
- return We(
1004
+ return ze(
1130
1005
  () => n.fullPath,
1131
1006
  () => {
1132
- O();
1007
+ L();
1133
1008
  }
1134
1009
  ), Q(() => {
1135
- w(), O();
1136
- }), (d, C) => (p(), S(a(tt), {
1010
+ y(), L();
1011
+ }), (r, $) => (h(), C(a(Ue), {
1137
1012
  class: "h-full",
1138
1013
  inverted: "",
1139
1014
  mode: "vertical",
1140
- options: k.value,
1141
- collapsed: a(y).state.collapsed,
1015
+ options: P.value,
1016
+ collapsed: a(_).state.collapsed,
1142
1017
  "collapsed-width": 64,
1143
1018
  "collapsed-icon-size": 20,
1144
1019
  indent: 24,
1145
- "expanded-keys": u.value,
1146
- value: h.value,
1147
- "onUpdate:value": _,
1020
+ "expanded-keys": c.value,
1021
+ value: g.value,
1022
+ "onUpdate:value": m,
1148
1023
  "onUpdate:expandedKeys": T
1149
1024
  }, null, 8, ["options", "collapsed", "expanded-keys", "value"]));
1150
1025
  }
1151
- }), ba = { class: "layout-content-main layout-content-main-fix" }, wa = { class: "main-view main-view-fix" }, Pa = /* @__PURE__ */ I({
1026
+ }), sa = { class: "layout-content-main layout-content-main-fix" }, la = { class: "main-view main-view-fix" }, ca = /* @__PURE__ */ B({
1152
1027
  __name: "PLayout",
1153
- setup(t) {
1154
- const n = se(), c = $(!1);
1155
- return wt("reloadPage", () => {
1156
- c.value = !0, ne(() => c.value = !1);
1157
- }), (h, u) => {
1158
- const k = st;
1159
- return p(), S(a(Ee), {
1028
+ setup(e) {
1029
+ const n = re(), i = N(!1);
1030
+ return it("reloadPage", () => {
1031
+ i.value = !0, se(() => i.value = !1);
1032
+ }), (g, c) => {
1033
+ const P = Ke;
1034
+ return h(), C(a(xe), {
1160
1035
  "has-sider": "",
1161
1036
  class: "layout",
1162
1037
  position: "absolute"
1163
1038
  }, {
1164
- default: l(() => [
1165
- r(a(at), {
1039
+ default: o(() => [
1040
+ l(a(je), {
1166
1041
  class: "layout-sider",
1167
1042
  inverted: "",
1168
1043
  "show-trigger": "bar",
@@ -1176,37 +1051,37 @@ const je = (t) => {
1176
1051
  onCollapse: a(n).collapse,
1177
1052
  onExpand: a(n).collapse
1178
1053
  }, {
1179
- default: l(() => [
1180
- r(a(nt), { vertical: "" }, {
1181
- default: l(() => [
1182
- r(Gt),
1183
- r(ya)
1054
+ default: o(() => [
1055
+ l(a(qe), { vertical: "" }, {
1056
+ default: o(() => [
1057
+ l(Dt),
1058
+ l(oa)
1184
1059
  ]),
1185
1060
  _: 1
1186
1061
  })
1187
1062
  ]),
1188
1063
  _: 1
1189
1064
  }, 8, ["collapsed", "onCollapse", "onExpand"]),
1190
- r(a(Ee), null, {
1191
- default: l(() => [
1192
- r(a(ot), { position: "absolute" }, {
1193
- default: l(() => [
1194
- r(ua)
1065
+ l(a(xe), null, {
1066
+ default: o(() => [
1067
+ l(a(Fe), { position: "absolute" }, {
1068
+ default: o(() => [
1069
+ l(Xt)
1195
1070
  ]),
1196
1071
  _: 1
1197
1072
  }),
1198
- r(a(lt), { class: "layout-content layout-default-background" }, {
1199
- default: l(() => [
1200
- b("div", ba, [
1201
- r(_a),
1202
- b("div", wa, [
1203
- r(fa, { loading: c.value }, null, 8, ["loading"])
1073
+ l(a(Ve), { class: "layout-content layout-default-background" }, {
1074
+ default: o(() => [
1075
+ b("div", sa, [
1076
+ l(na),
1077
+ b("div", la, [
1078
+ l(Zt, { loading: i.value }, null, 8, ["loading"])
1204
1079
  ])
1205
1080
  ])
1206
1081
  ]),
1207
1082
  _: 1
1208
1083
  }),
1209
- r(k, {
1084
+ l(P, {
1210
1085
  right: 20,
1211
1086
  class: "z-50"
1212
1087
  })
@@ -1218,12 +1093,12 @@ const je = (t) => {
1218
1093
  });
1219
1094
  };
1220
1095
  }
1221
- }), ka = /* @__PURE__ */ U(Pa, [["__scopeId", "data-v-0bac2e7d"]]), La = {};
1222
- function Ca(t, n) {
1223
- const c = Be("router-view");
1224
- return p(), S(c);
1096
+ }), ra = /* @__PURE__ */ F(ca, [["__scopeId", "data-v-0bac2e7d"]]), ia = {};
1097
+ function ua(e, n) {
1098
+ const i = Ne("router-view");
1099
+ return h(), C(i);
1225
1100
  }
1226
- const xa = /* @__PURE__ */ U(La, [["render", Ca]]), Sa = B(xa), Ta = B(ka), $a = /* @__PURE__ */ I({
1101
+ const da = /* @__PURE__ */ F(ia, [["render", ua]]), fa = W(da), ga = W(ra), pa = /* @__PURE__ */ B({
1227
1102
  __name: "PApplication",
1228
1103
  props: {
1229
1104
  theme: {},
@@ -1239,23 +1114,23 @@ const xa = /* @__PURE__ */ U(La, [["render", Ca]]), Sa = B(xa), Ta = B(ka), $a =
1239
1114
  }
1240
1115
  } }
1241
1116
  },
1242
- setup(t) {
1243
- return (n, c) => {
1244
- const y = rt;
1245
- return p(), S(y, {
1246
- locale: a(ct),
1247
- theme: t.theme,
1248
- "theme-overrides": t.themeOverrides,
1249
- "date-locale": a(it)
1117
+ setup(e) {
1118
+ return (n, i) => {
1119
+ const _ = Ye;
1120
+ return h(), C(_, {
1121
+ locale: a(Je),
1122
+ theme: e.theme,
1123
+ "theme-overrides": e.themeOverrides,
1124
+ "date-locale": a(Xe)
1250
1125
  }, {
1251
- default: l(() => [
1252
- r(a(ut), null, {
1253
- default: l(() => [
1254
- r(a(dt), null, {
1255
- default: l(() => [
1256
- r(a(ft), null, {
1257
- default: l(() => [
1258
- j(n.$slots, "default")
1126
+ default: o(() => [
1127
+ l(a(Ze), null, {
1128
+ default: o(() => [
1129
+ l(a(Ge), null, {
1130
+ default: o(() => [
1131
+ l(a(Qe), null, {
1132
+ default: o(() => [
1133
+ Y(n.$slots, "default")
1259
1134
  ]),
1260
1135
  _: 3
1261
1136
  })
@@ -1270,11 +1145,10 @@ const xa = /* @__PURE__ */ U(La, [["render", Ca]]), Sa = B(xa), Ta = B(ka), $a =
1270
1145
  }, 8, ["locale", "theme", "theme-overrides", "date-locale"]);
1271
1146
  };
1272
1147
  }
1273
- }), Oa = B($a), Ea = /* @__PURE__ */ I({
1148
+ }), ha = W(pa), ma = /* @__PURE__ */ B({
1274
1149
  __name: "PModal",
1275
1150
  props: {
1276
1151
  saveBtnText: { default: "保存" },
1277
- closable: { type: Boolean, default: !1 },
1278
1152
  title: {},
1279
1153
  width: { default: 800 },
1280
1154
  height: { default: 500 },
@@ -1284,90 +1158,90 @@ const xa = /* @__PURE__ */ U(La, [["render", Ca]]), Sa = B(xa), Ta = B(ka), $a =
1284
1158
  onClose: {}
1285
1159
  },
1286
1160
  emits: ["update:visible", "update:loading"],
1287
- setup(t, { expose: n, emit: c }) {
1288
- const y = fe(), h = t, u = c, k = async () => {
1289
- u("update:loading", !0);
1161
+ setup(e, { expose: n, emit: i }) {
1162
+ const _ = ue(), g = e, c = i, P = async () => {
1163
+ c("update:loading", !0);
1290
1164
  try {
1291
- h.onSave && await h.onSave() && _();
1292
- } catch (w) {
1293
- y.error(w.message);
1165
+ g.onSave && await g.onSave() && m();
1166
+ } catch (y) {
1167
+ _.error(y.message);
1294
1168
  } finally {
1295
- u("update:loading", !1);
1169
+ c("update:loading", !1);
1296
1170
  }
1297
- }, _ = () => {
1298
- u("update:visible", !1), u("update:loading", !1);
1171
+ }, m = () => {
1172
+ c("update:visible", !1), c("update:loading", !1);
1299
1173
  }, T = async () => {
1300
1174
  try {
1301
- h.onClose ? await h.onClose() && _() : _();
1302
- } catch (w) {
1303
- y.error(w.message), u("update:loading", !1);
1175
+ g.onClose ? await g.onClose() && m() : m();
1176
+ } catch (y) {
1177
+ _.error(y.message), c("update:loading", !1);
1304
1178
  }
1305
1179
  };
1306
1180
  return n({
1307
1181
  open: () => {
1308
- u("update:visible", !0), u("update:loading", !1);
1182
+ c("update:visible", !0), c("update:loading", !1);
1309
1183
  },
1310
1184
  close: () => {
1311
- u("update:visible", !1), u("update:loading", !1);
1185
+ c("update:visible", !1), c("update:loading", !1);
1312
1186
  }
1313
- }), (w, d) => {
1314
- const C = gt, m = K, f = ke;
1315
- return p(), S(a(De), Pt({
1187
+ }), (y, r) => {
1188
+ const $ = tt, z = ve, u = _e;
1189
+ return h(), C(a(et), ut({
1316
1190
  ref: "$modal",
1317
1191
  preset: "card"
1318
- }, w.$attrs, {
1192
+ }, y.$attrs, {
1319
1193
  "header-class": "bg-gray-50",
1320
- show: h.visible,
1194
+ show: g.visible,
1321
1195
  draggable: !0,
1322
1196
  closable: !1,
1323
1197
  "close-on-esc": !1,
1324
1198
  "mask-closable": !1,
1325
1199
  bordered: !1,
1326
- style: { width: `${h.width}px` },
1327
- onClose: _
1200
+ style: { width: `${g.width}px` },
1201
+ onClose: m
1328
1202
  }), {
1329
- header: l(() => [
1330
- w.$slots.header ? j(w.$slots, "header", { key: 0 }) : h.title ? (p(), S(C, { key: 1 }, {
1331
- default: l(() => [
1332
- Y(H(t.title), 1)
1203
+ header: o(() => [
1204
+ y.$slots.header ? Y(y.$slots, "header", { key: 0 }) : g.title ? (h(), C($, { key: 1 }, {
1205
+ default: o(() => [
1206
+ pe(q(e.title), 1)
1333
1207
  ]),
1334
1208
  _: 1
1335
- })) : N("", !0)
1209
+ })) : I("", !0)
1336
1210
  ]),
1337
- "header-extra": l(() => [
1338
- j(w.$slots, "header-extra")
1211
+ "header-extra": o(() => [
1212
+ Y(y.$slots, "header-extra")
1339
1213
  ]),
1340
- default: l(() => [
1214
+ default: o(() => [
1341
1215
  b("div", {
1342
1216
  class: "overflow-y-auto overflow-hidden mt-5",
1343
- style: de({ maxHeight: `${h.height}px` })
1217
+ style: De({ maxHeight: `${g.height}px` })
1344
1218
  }, [
1345
- j(w.$slots, "default")
1219
+ Y(y.$slots, "default")
1346
1220
  ], 4)
1347
1221
  ]),
1348
- footer: l(() => [
1349
- j(w.$slots, "footer")
1222
+ footer: o(() => [
1223
+ Y(y.$slots, "footer")
1350
1224
  ]),
1351
- action: l(() => [
1352
- r(f, { justify: "end" }, {
1353
- default: l(() => [
1354
- r(m, {
1225
+ action: o(() => [
1226
+ l(u, { justify: "end" }, {
1227
+ default: o(() => [
1228
+ l(z, {
1355
1229
  type: "primary",
1356
- loading: t.loading,
1357
- onClick: k
1230
+ loading: e.loading,
1231
+ onClick: P
1358
1232
  }, {
1359
- default: l(() => [
1360
- Y(H(t.saveBtnText), 1)
1233
+ default: o(() => [
1234
+ pe(q(e.saveBtnText), 1)
1361
1235
  ]),
1362
1236
  _: 1
1363
1237
  }, 8, ["loading"]),
1364
- j(w.$slots, "action-extra", { loading: t.loading }),
1365
- r(m, {
1238
+ Y(y.$slots, "action-extra", { loading: e.loading }),
1239
+ l(z, {
1366
1240
  onClick: T,
1367
- loading: t.loading
1241
+ loading: e.loading
1368
1242
  }, {
1369
- default: l(() => [...d[0] || (d[0] = [
1370
- Y("取消", -1)
1243
+ default: o(() => [...r[0] || (r[0] = [
1244
+ pe("取消", -1)
1371
1245
  ])]),
1372
1246
  _: 1
1373
1247
  }, 8, ["loading"])
@@ -1379,103 +1253,103 @@ const xa = /* @__PURE__ */ U(La, [["render", Ca]]), Sa = B(xa), Ta = B(ka), $a =
1379
1253
  }, 16, ["show", "style"]);
1380
1254
  };
1381
1255
  }
1382
- }), Ma = B(Ea), Ra = B(He), Na = I({
1256
+ }), _a = W(ma), va = W(Ae), ba = B({
1383
1257
  name: "Redirect",
1384
1258
  setup() {
1385
- const t = le(), n = oe();
1386
- return kt(() => {
1387
- const { params: c, query: y } = t, { path: h } = c;
1259
+ const e = ce(), n = le();
1260
+ return dt(() => {
1261
+ const { params: i, query: _ } = e, { path: g } = i;
1388
1262
  n.replace({
1389
- path: "/" + (Array.isArray(h) ? h.join("/") : h),
1390
- query: y
1263
+ path: "/" + (Array.isArray(g) ? g.join("/") : g),
1264
+ query: _
1391
1265
  });
1392
- }), () => /* @__PURE__ */ React.createElement(pt, null);
1266
+ }), () => /* @__PURE__ */ React.createElement(at, null);
1393
1267
  }
1394
- }), Aa = B(Na), Da = { class: "frame" }, za = ["src"], Ia = /* @__PURE__ */ I({
1268
+ }), ya = W(ba), wa = { class: "frame" }, Pa = ["src"], ka = /* @__PURE__ */ B({
1395
1269
  __name: "PIframe",
1396
- setup(t) {
1397
- const n = le(), c = $(!1), y = $(null), h = $("");
1398
- a(n.meta)?.frameSrc && (h.value = a(n.meta)?.frameSrc);
1399
- function u() {
1400
- c.value = !1;
1270
+ setup(e) {
1271
+ const n = ce(), i = N(!1), _ = N(null), g = N("");
1272
+ a(n.meta)?.frameSrc && (g.value = a(n.meta)?.frameSrc);
1273
+ function c() {
1274
+ i.value = !1;
1401
1275
  }
1402
- function k() {
1403
- ne(() => {
1404
- const _ = a(y);
1405
- if (!_) return;
1406
- const T = _;
1276
+ function P() {
1277
+ se(() => {
1278
+ const m = a(_);
1279
+ if (!m) return;
1280
+ const T = m;
1407
1281
  T.attachEvent ? T.attachEvent("onload", () => {
1408
- u();
1409
- }) : _.onload = () => {
1410
- u();
1282
+ c();
1283
+ }) : m.onload = () => {
1284
+ c();
1411
1285
  };
1412
1286
  });
1413
1287
  }
1414
1288
  return Q(() => {
1415
- c.value = !0, k();
1416
- }), (_, T) => {
1417
- const O = ht;
1418
- return p(), S(O, { show: c.value }, {
1419
- default: l(() => [
1420
- b("div", Da, [
1289
+ i.value = !0, P();
1290
+ }), (m, T) => {
1291
+ const L = nt;
1292
+ return h(), C(L, { show: i.value }, {
1293
+ default: o(() => [
1294
+ b("div", wa, [
1421
1295
  b("iframe", {
1422
- src: h.value,
1296
+ src: g.value,
1423
1297
  class: "frame-iframe",
1424
1298
  ref_key: "frameRef",
1425
- ref: y
1426
- }, null, 8, za)
1299
+ ref: _
1300
+ }, null, 8, Pa)
1427
1301
  ])
1428
1302
  ]),
1429
1303
  _: 1
1430
1304
  }, 8, ["show"]);
1431
1305
  };
1432
1306
  }
1433
- }), Ba = /* @__PURE__ */ U(Ia, [["__scopeId", "data-v-161a378e"]]), Wa = B(Ba), ja = { class: "border border-gray-100 rounded-lg" }, Ha = { class: "text-xl font-semibold text-gray-800" }, Ua = { class: "text-sm text-gray-500 mt-1" }, qa = /* @__PURE__ */ I({
1307
+ }), La = /* @__PURE__ */ F(ka, [["__scopeId", "data-v-161a378e"]]), xa = W(La), Ca = { class: "border border-gray-100 rounded-lg" }, Sa = { class: "text-xl font-semibold text-gray-800" }, Ta = { class: "text-sm text-gray-500 mt-1" }, $a = /* @__PURE__ */ B({
1434
1308
  __name: "PPage",
1435
1309
  props: {
1436
- icon: { type: Object, required: !1, default: () => Dt },
1310
+ icon: { type: Object, required: !1, default: () => Lt },
1437
1311
  title: { type: String, required: !0 },
1438
1312
  subtitle: { type: String, required: !1 }
1439
1313
  },
1440
- setup(t) {
1441
- const n = t;
1442
- return (c, y) => {
1443
- const h = M, u = Le, k = ke, _ = Ae;
1444
- return p(), R("div", ja, [
1445
- n.title ? (p(), S(_, {
1314
+ setup(e) {
1315
+ const n = e;
1316
+ return (i, _) => {
1317
+ const g = D, c = be, P = _e, m = Oe;
1318
+ return h(), M("div", Ca, [
1319
+ n.title ? (h(), C(m, {
1446
1320
  key: 0,
1447
1321
  class: "mb-4",
1448
1322
  bordered: !1,
1449
1323
  "content-class": "py-4"
1450
1324
  }, {
1451
- default: l(() => [
1452
- r(k, {
1325
+ default: o(() => [
1326
+ l(P, {
1453
1327
  align: "center",
1454
1328
  justify: "space-between"
1455
1329
  }, {
1456
- default: l(() => [
1457
- r(k, {
1330
+ default: o(() => [
1331
+ l(P, {
1458
1332
  align: "center",
1459
1333
  size: 16
1460
1334
  }, {
1461
- default: l(() => [
1462
- n.icon ? (p(), S(u, {
1335
+ default: o(() => [
1336
+ n.icon ? (h(), C(c, {
1463
1337
  key: 0,
1464
1338
  size: 48,
1465
1339
  class: "bg-linear-to-br from-blue-500 to-indigo-600"
1466
1340
  }, {
1467
- default: l(() => [
1468
- r(h, {
1341
+ default: o(() => [
1342
+ l(g, {
1469
1343
  size: 24,
1470
1344
  component: n.icon,
1471
1345
  color: "#fff"
1472
1346
  }, null, 8, ["component"])
1473
1347
  ]),
1474
1348
  _: 1
1475
- })) : N("", !0),
1349
+ })) : I("", !0),
1476
1350
  b("div", null, [
1477
- b("div", Ha, H(n.title), 1),
1478
- b("div", Ua, H(n.subtitle ?? n.title + "主页"), 1)
1351
+ b("div", Sa, q(n.title), 1),
1352
+ b("div", Ta, q(n.subtitle ?? n.title + "主页"), 1)
1479
1353
  ])
1480
1354
  ]),
1481
1355
  _: 1
@@ -1485,83 +1359,83 @@ const xa = /* @__PURE__ */ U(La, [["render", Ca]]), Sa = B(xa), Ta = B(ka), $a =
1485
1359
  })
1486
1360
  ]),
1487
1361
  _: 1
1488
- })) : N("", !0),
1489
- c.$slots.search ? (p(), S(_, {
1362
+ })) : I("", !0),
1363
+ i.$slots.search ? (h(), C(m, {
1490
1364
  key: 1,
1491
1365
  class: "mb-4",
1492
1366
  bordered: !1,
1493
1367
  "content-class": "py-4"
1494
1368
  }, {
1495
- default: l(() => [
1496
- j(c.$slots, "search")
1369
+ default: o(() => [
1370
+ Y(i.$slots, "search")
1497
1371
  ]),
1498
1372
  _: 3
1499
- })) : N("", !0),
1500
- c.$slots.default ? (p(), S(_, {
1373
+ })) : I("", !0),
1374
+ i.$slots.default ? (h(), C(m, {
1501
1375
  key: 2,
1502
1376
  bordered: !1,
1503
1377
  "content-class": "!py-0"
1504
1378
  }, {
1505
- default: l(() => [
1506
- j(c.$slots, "default")
1379
+ default: o(() => [
1380
+ Y(i.$slots, "default")
1507
1381
  ]),
1508
1382
  _: 3
1509
- })) : N("", !0)
1383
+ })) : I("", !0)
1510
1384
  ]);
1511
1385
  };
1512
1386
  }
1513
- }), Fa = B(qa), Va = {}, Ka = { class: "flex flex-col justify-center page-container" };
1514
- function Ya(t, n) {
1515
- const c = Ce;
1516
- return p(), R("div", Ka, [
1517
- r(c, {
1387
+ }), Oa = W($a), Ea = {}, Ra = { class: "flex flex-col justify-center page-container" };
1388
+ function Na(e, n) {
1389
+ const i = ye;
1390
+ return h(), M("div", Ra, [
1391
+ l(i, {
1518
1392
  status: "500",
1519
1393
  title: "服务器错误",
1520
1394
  description: "抱歉,服务器出错了"
1521
1395
  })
1522
1396
  ]);
1523
1397
  }
1524
- const Xa = /* @__PURE__ */ U(Va, [["render", Ya], ["__scopeId", "data-v-89cb65c7"]]), Ga = {}, Ja = { class: "flex flex-col justify-center page-container" };
1525
- function Za(t, n) {
1526
- const c = Ce;
1527
- return p(), R("div", Ja, [
1528
- r(c, {
1398
+ const za = /* @__PURE__ */ F(Ea, [["render", Na], ["__scopeId", "data-v-89cb65c7"]]), Da = {}, Aa = { class: "flex flex-col justify-center page-container" };
1399
+ function Ma(e, n) {
1400
+ const i = ye;
1401
+ return h(), M("div", Aa, [
1402
+ l(i, {
1529
1403
  status: "404",
1530
1404
  title: "资源不存在",
1531
1405
  description: "抱歉,你访问的页面不存在"
1532
1406
  })
1533
1407
  ]);
1534
1408
  }
1535
- const Qa = /* @__PURE__ */ U(Ga, [["render", Za], ["__scopeId", "data-v-99232671"]]), en = {}, tn = { class: "flex flex-col justify-center page-container" };
1536
- function an(t, n) {
1537
- const c = Ce;
1538
- return p(), R("div", tn, [
1539
- r(c, {
1409
+ const Ia = /* @__PURE__ */ F(Da, [["render", Ma], ["__scopeId", "data-v-99232671"]]), Ba = {}, Ha = { class: "flex flex-col justify-center page-container" };
1410
+ function Wa(e, n) {
1411
+ const i = ye;
1412
+ return h(), M("div", Ha, [
1413
+ l(i, {
1540
1414
  status: "403",
1541
1415
  title: "禁止访问",
1542
1416
  description: "抱歉,你无权访问该页面"
1543
1417
  })
1544
1418
  ]);
1545
1419
  }
1546
- const nn = /* @__PURE__ */ U(en, [["render", an], ["__scopeId", "data-v-3baa9c16"]]), on = B(Xa), ln = B(Qa), sn = B(nn), rn = Te("app-oidc", () => {
1547
- const t = xe({});
1420
+ const Ua = /* @__PURE__ */ F(Ba, [["render", Wa], ["__scopeId", "data-v-3baa9c16"]]), ja = W(za), qa = W(Ia), Fa = W(Ua), Va = ke("app-oidc", () => {
1421
+ const e = we({});
1548
1422
  return {
1549
- setCallback: (u) => t.callback = u,
1550
- callCallback: async (u) => await t.callback?.(u),
1551
- setError: (u) => t.error = u,
1552
- callError: async (u, k) => await t.error?.(u, k)
1423
+ setCallback: (c) => e.callback = c,
1424
+ callCallback: async (c) => await e.callback?.(c),
1425
+ setError: (c) => e.error = c,
1426
+ callError: async (c, P) => await e.error?.(c, P)
1553
1427
  };
1554
- }), cn = { class: "view-auth-callback" }, un = /* @__PURE__ */ I({
1428
+ }), Ka = { class: "view-auth-callback" }, Ya = /* @__PURE__ */ B({
1555
1429
  __name: "POidc",
1556
- setup(t) {
1557
- const n = oe(), { callCallback: c, callError: y } = rn();
1430
+ setup(e) {
1431
+ const n = le(), { callCallback: i, callError: _ } = Va();
1558
1432
  return Q(async () => {
1559
1433
  try {
1560
- await c(n);
1561
- } catch (h) {
1562
- await y(n, h);
1434
+ await i(n);
1435
+ } catch (g) {
1436
+ await _(n, g);
1563
1437
  }
1564
- }), (h, u) => (p(), R("div", cn, [...u[0] || (u[0] = [
1438
+ }), (g, c) => (h(), M("div", Ka, [...c[0] || (c[0] = [
1565
1439
  b("div", { class: "view-auth-callback-content" }, [
1566
1440
  b("div", { class: "view-auth-callback-spinner" }, [
1567
1441
  b("span", null, "正在处理登录回调...")
@@ -1569,43 +1443,43 @@ const nn = /* @__PURE__ */ U(en, [["render", an], ["__scopeId", "data-v-3baa9c16
1569
1443
  ], -1)
1570
1444
  ])]));
1571
1445
  }
1572
- }), dn = /* @__PURE__ */ U(un, [["__scopeId", "data-v-167395ae"]]), fn = B(dn), gn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1446
+ }), Xa = /* @__PURE__ */ F(Ya, [["__scopeId", "data-v-167395ae"]]), Ja = W(Xa), Za = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1573
1447
  __proto__: null,
1574
- P403: sn,
1575
- P404: ln,
1576
- P500: on,
1577
- PApplication: Oa,
1578
- PEmptyLayout: Sa,
1579
- PIframe: Wa,
1580
- PLanguage: Ra,
1581
- PLayout: Ta,
1582
- PModal: Ma,
1583
- POidc: fn,
1584
- PPage: Fa,
1585
- PRedirect: Aa,
1586
- PTable: Vt
1587
- }, Symbol.toStringTag, { value: "Module" })), pn = (t, n) => (Object.values(gn).forEach((c) => {
1588
- c.install && t.use(c);
1589
- }), n?.(), t), kn = {
1590
- install: pn
1448
+ P403: Fa,
1449
+ P404: qa,
1450
+ P500: ja,
1451
+ PApplication: ha,
1452
+ PEmptyLayout: fa,
1453
+ PIframe: xa,
1454
+ PLanguage: va,
1455
+ PLayout: ga,
1456
+ PModal: _a,
1457
+ POidc: Ja,
1458
+ PPage: Oa,
1459
+ PRedirect: ya,
1460
+ PTable: Et
1461
+ }, Symbol.toStringTag, { value: "Module" })), Ga = (e, n) => (Object.values(Za).forEach((i) => {
1462
+ i.install && e.use(i);
1463
+ }), n?.(), e), ln = {
1464
+ install: Ga
1591
1465
  };
1592
1466
  export {
1593
- sn as P403,
1594
- ln as P404,
1595
- on as P500,
1596
- Oa as PApplication,
1597
- Sa as PEmptyLayout,
1598
- Wa as PIframe,
1599
- Ra as PLanguage,
1600
- Ta as PLayout,
1601
- Ma as PModal,
1602
- fn as POidc,
1603
- Fa as PPage,
1604
- Aa as PRedirect,
1605
- Vt as PTable,
1606
- kn as default,
1607
- pn as install,
1608
- Zt as useLanguageStore,
1609
- se as useLayoutStore,
1610
- rn as useOidcStore
1467
+ Fa as P403,
1468
+ qa as P404,
1469
+ ja as P500,
1470
+ ha as PApplication,
1471
+ fa as PEmptyLayout,
1472
+ xa as PIframe,
1473
+ va as PLanguage,
1474
+ ga as PLayout,
1475
+ _a as PModal,
1476
+ Ja as POidc,
1477
+ Oa as PPage,
1478
+ ya as PRedirect,
1479
+ Et as PTable,
1480
+ ln as default,
1481
+ Ga as install,
1482
+ Mt as useLanguageStore,
1483
+ re as useLayoutStore,
1484
+ Va as useOidcStore
1611
1485
  };