@ithinkdt/ui 4.0.16 → 4.0.17
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/auto-imports.js +6 -3
- package/esm/{DataTable-DXZ3G4ZO.js → DataTable-BvLINmq3.js} +3 -3
- package/esm/components-DfV9ybsT.js +2167 -0
- package/esm/components.d.ts +158 -67
- package/esm/components.js +2 -1629
- package/esm/design.d.ts +0 -6
- package/esm/directives.js +1 -1
- package/esm/index.js +109 -151
- package/esm/page.d.ts +2 -1
- package/esm/page.js +94 -85
- package/package.json +8 -8
- package/esm/assets-bJgPKDh1.js +0 -187
- /package/esm/{directives-g3YmS-dM.js → directives-Chz4DK1u.js} +0 -0
- /package/esm/{use-i18n-D1TTDOML.js → use-i18n-BUP_StIp.js} +0 -0
package/esm/index.js
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
import { n as e, t } from "./use-i18n-
|
|
1
|
+
import { n as e, t } from "./use-i18n-BUP_StIp.js";
|
|
2
2
|
import n, { c as r, cB as i, cE as a, cM as o } from "./use-style.js";
|
|
3
|
-
import { i as s, n as c, r as l, t as u } from "./directives-
|
|
3
|
+
import { i as s, n as c, r as l, t as u } from "./directives-Chz4DK1u.js";
|
|
4
4
|
import { Fragment as d, computed as f, createVNode as p, defineComponent as m, inject as h, isVNode as g, mergeProps as _, provide as v, reactive as y, ref as b, renderSlot as x, shallowRef as S, toRef as C, toValue as w, unref as T, useTemplateRef as E, watch as D, withDirectives as O } from "vue";
|
|
5
|
-
import { computedAsync as ee, promiseTimeout as k, useElementHover as A, useElementSize as te, useEventListener as ne,
|
|
6
|
-
import { NAvatar as
|
|
7
|
-
import { debounce as
|
|
8
|
-
import { useAtomicBroadcast as
|
|
9
|
-
import { RouterLink as
|
|
10
|
-
import { walkTree as
|
|
11
|
-
import { isNullish as
|
|
12
|
-
import { getOpaqueColor as
|
|
13
|
-
import { format as
|
|
5
|
+
import { computedAsync as ee, promiseTimeout as k, useElementHover as A, useElementSize as te, useEventListener as ne, watchDebounced as re } from "@vueuse/core";
|
|
6
|
+
import { NAvatar as j, NBadge as ie, NBreadcrumb as ae, NBreadcrumbItem as oe, NButton as M, NDrawer as se, NDrawerContent as ce, NDropdown as N, NEmpty as le, NIcon as P, NInput as F, NList as I, NListItem as L, NMenu as R, NPagination as z, NPopover as B, NScrollbar as V, NText as H, NThing as U, useThemeVars as W } from "ithinkdt-ui";
|
|
7
|
+
import { debounce as ue } from "@ithinkdt/common/fn";
|
|
8
|
+
import { useAtomicBroadcast as de } from "@ithinkdt/common/composables";
|
|
9
|
+
import { RouterLink as fe, useRouter as G } from "vue-router";
|
|
10
|
+
import { walkTree as pe } from "@ithinkdt/common/tree";
|
|
11
|
+
import { isNullish as me } from "@ithinkdt/common/object";
|
|
12
|
+
import { getOpaqueColor as he } from "@ithinkdt/common/color";
|
|
13
|
+
import { format as ge } from "date-fns";
|
|
14
14
|
//#region src/design/Account.jsx
|
|
15
15
|
function K(e) {
|
|
16
16
|
return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !g(e);
|
|
17
17
|
}
|
|
18
|
-
var
|
|
18
|
+
var _e = /* @__PURE__ */ m({
|
|
19
19
|
name: "AppAccount",
|
|
20
20
|
props: {
|
|
21
21
|
username: String,
|
|
@@ -32,7 +32,7 @@ var ve = /* @__PURE__ */ m({
|
|
|
32
32
|
},
|
|
33
33
|
emit: ["logout", "change-pwd"],
|
|
34
34
|
setup(t, { emit: n, slots: r }) {
|
|
35
|
-
let i = f(() => /^[\u4E00-\u9FA5]+$/.test(t.nickname) ? t.nickname?.slice(t.nickname?.length > 3 ? 2 : 1) : t.nickname?.split(" ")[0]), { t: a } = e(), o = p(
|
|
35
|
+
let i = f(() => /^[\u4E00-\u9FA5]+$/.test(t.nickname) ? t.nickname?.slice(t.nickname?.length > 3 ? 2 : 1) : t.nickname?.split(" ")[0]), { t: a } = e(), o = p(P, { size: "28" }, { default: () => [p("svg", {
|
|
36
36
|
xmlns: "http://www.w3.org/2000/svg",
|
|
37
37
|
width: "1em",
|
|
38
38
|
height: "1em",
|
|
@@ -52,11 +52,11 @@ var ve = /* @__PURE__ */ m({
|
|
|
52
52
|
return () => {
|
|
53
53
|
let e;
|
|
54
54
|
return p("div", { style: "display: flex; align-items: center" }, [
|
|
55
|
-
p(
|
|
56
|
-
trigger: () => p(
|
|
55
|
+
p(B, { style: "padding: 4px" }, {
|
|
56
|
+
trigger: () => p(M, {
|
|
57
57
|
quaternary: !0,
|
|
58
58
|
style: "--n-padding: 0 12px"
|
|
59
|
-
}, { default: () => [p("div", { style: "display: flex; align-items: center; gap: 8px" }, [p(
|
|
59
|
+
}, { default: () => [p("div", { style: "display: flex; align-items: center; gap: 8px" }, [p(j, {
|
|
60
60
|
key: t.head ? "head" : "no-head",
|
|
61
61
|
src: t.head,
|
|
62
62
|
round: !0,
|
|
@@ -69,12 +69,12 @@ var ve = /* @__PURE__ */ m({
|
|
|
69
69
|
default: t.head ? void 0 : () => i.value
|
|
70
70
|
}), p("span", { style: "font-size: 14px" }, [t.username ?? ""])])] }),
|
|
71
71
|
default: () => {
|
|
72
|
-
let e = () => t.showChangePwd ? p(
|
|
72
|
+
let e = () => t.showChangePwd ? p(M, {
|
|
73
73
|
quaternary: !0,
|
|
74
74
|
style: "justify-content: left",
|
|
75
75
|
onClick: () => n("change-pwd")
|
|
76
76
|
}, {
|
|
77
|
-
icon: () => p(
|
|
77
|
+
icon: () => p(P, null, { default: () => [p("svg", {
|
|
78
78
|
xmlns: "http://www.w3.org/2000/svg",
|
|
79
79
|
width: "1em",
|
|
80
80
|
height: "1em",
|
|
@@ -89,12 +89,12 @@ var ve = /* @__PURE__ */ m({
|
|
|
89
89
|
fill: "currentColor"
|
|
90
90
|
}, null)])] }),
|
|
91
91
|
default: () => a("common.account.changePwd")
|
|
92
|
-
}) : void 0, i = () => t.showLogoutButton ? void 0 : p(
|
|
92
|
+
}) : void 0, i = () => t.showLogoutButton ? void 0 : p(M, {
|
|
93
93
|
quaternary: !0,
|
|
94
94
|
style: "justify-content: left",
|
|
95
95
|
onClick: () => n("logout")
|
|
96
96
|
}, {
|
|
97
|
-
icon: () => p(
|
|
97
|
+
icon: () => p(P, null, K(c) ? c : { default: () => [c] }),
|
|
98
98
|
default: () => [a("common.account.logout")]
|
|
99
99
|
});
|
|
100
100
|
return x(r, "dropdown", {
|
|
@@ -108,11 +108,11 @@ var ve = /* @__PURE__ */ m({
|
|
|
108
108
|
}
|
|
109
109
|
}),
|
|
110
110
|
x(r, "extra"),
|
|
111
|
-
t.showLogoutButton ? O(p(
|
|
111
|
+
t.showLogoutButton ? O(p(M, {
|
|
112
112
|
quaternary: !0,
|
|
113
113
|
style: "--n-padding: 0 12px",
|
|
114
114
|
onClick: () => t.username && n("logout")
|
|
115
|
-
}, K(e = x(r, "logoutButton", void 0, () => [p(
|
|
115
|
+
}, K(e = x(r, "logoutButton", void 0, () => [p(P, { size: "16" }, K(c) ? c : { default: () => [c] })])) ? e : { default: () => [e] }), [[
|
|
116
116
|
s,
|
|
117
117
|
a("common.account.logout"),
|
|
118
118
|
void 0,
|
|
@@ -121,19 +121,19 @@ var ve = /* @__PURE__ */ m({
|
|
|
121
121
|
]);
|
|
122
122
|
};
|
|
123
123
|
}
|
|
124
|
-
}),
|
|
124
|
+
}), ve = /* @__PURE__ */ m({
|
|
125
125
|
name: "AppAppearance",
|
|
126
126
|
props: { mode: String },
|
|
127
127
|
emit: ["update:mode"],
|
|
128
128
|
setup(t, { emit: n }) {
|
|
129
129
|
let { t: r } = e();
|
|
130
|
-
return () => O(p(
|
|
130
|
+
return () => O(p(M, {
|
|
131
131
|
quaternary: !0,
|
|
132
132
|
style: "--n-padding: 0 12px",
|
|
133
133
|
onClick: () => {
|
|
134
134
|
n("update:mode", t.mode === "light" ? "dark" : t.mode === "dark" ? "auto" : "light");
|
|
135
135
|
}
|
|
136
|
-
}, { default: () => [p(
|
|
136
|
+
}, { default: () => [p(P, { size: "18" }, { default: () => [t.mode === "light" ? p("svg", {
|
|
137
137
|
xmlns: "http://www.w3.org/2000/svg",
|
|
138
138
|
"xmlns:xlink": "http://www.w3.org/1999/xlink",
|
|
139
139
|
role: "img",
|
|
@@ -183,10 +183,10 @@ var ve = /* @__PURE__ */ m({
|
|
|
183
183
|
}, null)]), Y = "__APP_CTX__", X = () => h(Y);
|
|
184
184
|
//#endregion
|
|
185
185
|
//#region src/design/Breadcrumb.jsx
|
|
186
|
-
function
|
|
186
|
+
function ye(e) {
|
|
187
187
|
return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !g(e);
|
|
188
188
|
}
|
|
189
|
-
var
|
|
189
|
+
var be = /* @__PURE__ */ m({
|
|
190
190
|
name: "AppBreadcrumb",
|
|
191
191
|
props: {
|
|
192
192
|
items: {
|
|
@@ -201,64 +201,21 @@ var xe = /* @__PURE__ */ m({
|
|
|
201
201
|
setup(e) {
|
|
202
202
|
let t = G(), n = Symbol(), r = Symbol();
|
|
203
203
|
return D(() => e.items, (t) => {
|
|
204
|
-
|
|
204
|
+
pe(t, (t) => {
|
|
205
205
|
t.icon && (typeof t.icon == "string" ? (t[n] = e.getIcon?.(t.icon), t[r] = () => t[n]?.() || J()) : t[r] = t.icon);
|
|
206
206
|
});
|
|
207
207
|
}, { immediate: !0 }), () => {
|
|
208
208
|
let n;
|
|
209
|
-
return p(ae, null,
|
|
209
|
+
return p(ae, null, ye(n = e.items.map((e) => p(oe, {
|
|
210
210
|
clickable: e.href?.length > 0,
|
|
211
211
|
separator: e.separator,
|
|
212
212
|
onClick: e.href && ((n) => {
|
|
213
213
|
n.stopPropagation(), t.push(e.href);
|
|
214
214
|
})
|
|
215
|
-
}, { default: () => [e.icon ? p(d, null, [p(
|
|
215
|
+
}, { default: () => [e.icon ? p(d, null, [p(P, { component: e[r] }, null), " "]) : void 0, w(e.title)] }))) ? n : { default: () => [n] });
|
|
216
216
|
};
|
|
217
217
|
}
|
|
218
|
-
}),
|
|
219
|
-
name: "AppFullscreen",
|
|
220
|
-
props: {},
|
|
221
|
-
emit: ["change"],
|
|
222
|
-
setup(t, { emit: n }) {
|
|
223
|
-
let { t: r } = e(), { isFullscreen: i, toggle: a } = j();
|
|
224
|
-
return () => O(p(N, {
|
|
225
|
-
quaternary: !0,
|
|
226
|
-
style: "--n-padding: 0 12px",
|
|
227
|
-
onClick: () => {
|
|
228
|
-
a(), n("change", i.value);
|
|
229
|
-
}
|
|
230
|
-
}, { default: () => [p(F, { size: "18" }, { default: () => [i.value ? p("svg", {
|
|
231
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
232
|
-
width: "1em",
|
|
233
|
-
height: "1em",
|
|
234
|
-
viewBox: "0 0 24 24"
|
|
235
|
-
}, [p("path", {
|
|
236
|
-
fill: "none",
|
|
237
|
-
stroke: "currentColor",
|
|
238
|
-
"stroke-linecap": "round",
|
|
239
|
-
"stroke-linejoin": "round",
|
|
240
|
-
"stroke-width": "1.5",
|
|
241
|
-
d: "M8.345 3.75v2.095a2.5 2.5 0 0 1-2.5 2.5H3.75M8.345 20.25v-2.095a2.5 2.5 0 0 0-2.5-2.5H3.75M15.655 3.75v2.095a2.5 2.5 0 0 0 2.5 2.5h2.095M15.655 20.25v-2.095a2.5 2.5 0 0 1 2.5-2.5h2.095"
|
|
242
|
-
}, null)]) : p("svg", {
|
|
243
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
244
|
-
width: "1em",
|
|
245
|
-
height: "1em",
|
|
246
|
-
viewBox: "0 0 24 24"
|
|
247
|
-
}, [p("path", {
|
|
248
|
-
fill: "none",
|
|
249
|
-
stroke: "currentColor",
|
|
250
|
-
"stroke-linecap": "round",
|
|
251
|
-
"stroke-linejoin": "round",
|
|
252
|
-
"stroke-width": "1.5",
|
|
253
|
-
d: "M3.75 8.345V6.25a2.5 2.5 0 0 1 2.5-2.5h2.095M3.75 15.655v2.095a2.5 2.5 0 0 0 2.5 2.5h2.095M20.25 8.345V6.25a2.5 2.5 0 0 0-2.5-2.5h-2.095m4.595 11.905v2.095a2.5 2.5 0 0 1-2.5 2.5h-2.095"
|
|
254
|
-
}, null)])] })] }), [[
|
|
255
|
-
s,
|
|
256
|
-
i.value ? r("common.layout.screen.exitfull") : r("common.layout.screen.full"),
|
|
257
|
-
void 0,
|
|
258
|
-
{ bottom: !0 }
|
|
259
|
-
]]);
|
|
260
|
-
}
|
|
261
|
-
}), Ce = /* @__PURE__ */ m({
|
|
218
|
+
}), xe = /* @__PURE__ */ m({
|
|
262
219
|
name: "AppLanguage",
|
|
263
220
|
props: {
|
|
264
221
|
lang: String,
|
|
@@ -266,15 +223,15 @@ var xe = /* @__PURE__ */ m({
|
|
|
266
223
|
},
|
|
267
224
|
emit: ["update:lang"],
|
|
268
225
|
setup(e, { emit: t }) {
|
|
269
|
-
return () => p(
|
|
226
|
+
return () => p(N, {
|
|
270
227
|
options: e.supports,
|
|
271
228
|
keyField: "value",
|
|
272
229
|
showArrow: !0,
|
|
273
230
|
onSelect: (e) => t("update:lang", e)
|
|
274
|
-
}, { default: () => [p(
|
|
231
|
+
}, { default: () => [p(M, {
|
|
275
232
|
quaternary: !0,
|
|
276
233
|
style: "--n-padding: 0 12px"
|
|
277
|
-
}, { default: () => [p(
|
|
234
|
+
}, { default: () => [p(P, { size: "18" }, { default: () => [p("svg", {
|
|
278
235
|
xmlns: "http://www.w3.org/2000/svg",
|
|
279
236
|
"xmlns:xlink": "http://www.w3.org/1999/xlink",
|
|
280
237
|
role: "img",
|
|
@@ -289,7 +246,7 @@ var xe = /* @__PURE__ */ m({
|
|
|
289
246
|
"stroke-width": "1.5"
|
|
290
247
|
}, [p("path", { d: "M2 12c0 5.523 4.477 10 10 10s10-4.477 10-10S17.523 2 12 2S2 6.477 2 12Z" }, null), p("path", { d: "M13 2.05S16 6 16 12c0 6-3 9.95-3 9.95m-2 0S8 18 8 12c0-6 3-9.95 3-9.95M2.63 15.5h18.74m-18.74-7h18.74" }, null)])])] })] })] });
|
|
291
248
|
}
|
|
292
|
-
}),
|
|
249
|
+
}), Se = /* @__PURE__ */ r([
|
|
293
250
|
i("layout", {
|
|
294
251
|
display: "grid",
|
|
295
252
|
gridTemplateAreas: "\n 'sidebar header'\n 'sidebar content'\n 'sidebar footer'\n ",
|
|
@@ -309,7 +266,7 @@ var xe = /* @__PURE__ */ m({
|
|
|
309
266
|
i("header", {
|
|
310
267
|
gridArea: "header",
|
|
311
268
|
overflow: "hidden",
|
|
312
|
-
zIndex: 2,
|
|
269
|
+
zIndex: "2",
|
|
313
270
|
height: "var(--app-header-height, 44px)"
|
|
314
271
|
}),
|
|
315
272
|
i("sidebar", {
|
|
@@ -320,13 +277,14 @@ var xe = /* @__PURE__ */ m({
|
|
|
320
277
|
overflow: "auto",
|
|
321
278
|
position: "relative",
|
|
322
279
|
transition: "width 0.2s ease-in-out",
|
|
323
|
-
zIndex: "
|
|
280
|
+
zIndex: "3"
|
|
324
281
|
}, [a("collapse-btn", {
|
|
325
282
|
"--n-padding": "0 12px",
|
|
326
283
|
position: "absolute",
|
|
327
284
|
zIndex: "2",
|
|
328
285
|
bottom: "8px",
|
|
329
|
-
right: "8px"
|
|
286
|
+
right: "8px",
|
|
287
|
+
"backdrop-filter": "blur(4px)"
|
|
330
288
|
})]),
|
|
331
289
|
i("content", {
|
|
332
290
|
gridArea: "content",
|
|
@@ -340,7 +298,7 @@ var xe = /* @__PURE__ */ m({
|
|
|
340
298
|
textAlign: "center",
|
|
341
299
|
color: "gray"
|
|
342
300
|
})
|
|
343
|
-
]),
|
|
301
|
+
]), Ce = () => p("svg", {
|
|
344
302
|
xmlns: "http://www.w3.org/2000/svg",
|
|
345
303
|
width: "1em",
|
|
346
304
|
height: "1em",
|
|
@@ -353,7 +311,7 @@ var xe = /* @__PURE__ */ m({
|
|
|
353
311
|
"stroke-width": "1.5",
|
|
354
312
|
d: "M11.5 18s-6-4.419-6-6s6-6 6-6m7 12s-6-4.419-6-6s6-6 6-6",
|
|
355
313
|
color: "currentColor"
|
|
356
|
-
}, null)]),
|
|
314
|
+
}, null)]), we = () => p("svg", {
|
|
357
315
|
xmlns: "http://www.w3.org/2000/svg",
|
|
358
316
|
width: "1em",
|
|
359
317
|
height: "1em",
|
|
@@ -366,7 +324,7 @@ var xe = /* @__PURE__ */ m({
|
|
|
366
324
|
"stroke-width": "1.5",
|
|
367
325
|
d: "M12.5 18s6-4.419 6-6s-6-6-6-6m-7 12s6-4.419 6-6s-6-6-6-6",
|
|
368
326
|
color: "currentColor"
|
|
369
|
-
}, null)]),
|
|
327
|
+
}, null)]), Te = /* @__PURE__ */ m({
|
|
370
328
|
name: "AppLayout",
|
|
371
329
|
props: {
|
|
372
330
|
layout: {
|
|
@@ -376,7 +334,7 @@ var xe = /* @__PURE__ */ m({
|
|
|
376
334
|
fullContent: Boolean
|
|
377
335
|
},
|
|
378
336
|
setup(e, { slots: t }) {
|
|
379
|
-
n("-layout",
|
|
337
|
+
n("-layout", Se, b("app"), !1);
|
|
380
338
|
let r = y({
|
|
381
339
|
sidebarWidth: "0px",
|
|
382
340
|
headerHeight: "0px",
|
|
@@ -399,7 +357,7 @@ var xe = /* @__PURE__ */ m({
|
|
|
399
357
|
}, [x(t, "default")]);
|
|
400
358
|
};
|
|
401
359
|
}
|
|
402
|
-
}),
|
|
360
|
+
}), Ee = /* @__PURE__ */ m({
|
|
403
361
|
name: "AppHeader",
|
|
404
362
|
props: { height: {
|
|
405
363
|
type: Number,
|
|
@@ -409,7 +367,7 @@ var xe = /* @__PURE__ */ m({
|
|
|
409
367
|
let n = X();
|
|
410
368
|
return () => (n.headerHeight = e.height + "px", p("div", { class: "app-header" }, [x(t, "default")]));
|
|
411
369
|
}
|
|
412
|
-
}),
|
|
370
|
+
}), De = /* @__PURE__ */ m({
|
|
413
371
|
name: "AppSidebar",
|
|
414
372
|
props: {
|
|
415
373
|
showCollapseBtn: {
|
|
@@ -430,20 +388,20 @@ var xe = /* @__PURE__ */ m({
|
|
|
430
388
|
setup(t, { emit: n, slots: r }) {
|
|
431
389
|
v(q, C(t, "collapsed"));
|
|
432
390
|
let { t: i } = e(), a = X();
|
|
433
|
-
return () => (a.sidebarWidth = (t.collapsed ? t.collapsedWidth : t.width) + "px", p("div", { class: "app-sidebar" }, [x(r, "default"), t.showCollapseBtn ? O(p(
|
|
391
|
+
return () => (a.sidebarWidth = (t.collapsed ? t.collapsedWidth : t.width) + "px", p("div", { class: "app-sidebar" }, [x(r, "default"), t.showCollapseBtn ? O(p(M, {
|
|
434
392
|
class: "app-sidebar__collapse-btn",
|
|
435
393
|
quaternary: !0,
|
|
436
394
|
onClick: () => {
|
|
437
395
|
n("update:collapsed", !t.collapsed);
|
|
438
396
|
}
|
|
439
|
-
}, { default: () => [p(
|
|
397
|
+
}, { default: () => [p(P, { size: "20" }, { default: () => [t.collapsed ? p(we, null, null) : p(Ce, null, null)] })] }), [[s, t.collapsed ? i("common.layout.sidebar.expand") : i("common.layout.sidebar.collapse")]]) : void 0]));
|
|
440
398
|
}
|
|
441
|
-
}),
|
|
399
|
+
}), Oe = /* @__PURE__ */ m({
|
|
442
400
|
name: "AppContent",
|
|
443
401
|
setup(e, { slots: t }) {
|
|
444
402
|
return () => p("div", { class: "app-content" }, [x(t, "default")]);
|
|
445
403
|
}
|
|
446
|
-
}),
|
|
404
|
+
}), ke = /* @__PURE__ */ m({
|
|
447
405
|
name: "AppFooter",
|
|
448
406
|
props: { height: {
|
|
449
407
|
type: Number,
|
|
@@ -456,10 +414,10 @@ var xe = /* @__PURE__ */ m({
|
|
|
456
414
|
});
|
|
457
415
|
//#endregion
|
|
458
416
|
//#region src/design/Logo.jsx
|
|
459
|
-
function
|
|
417
|
+
function Ae(e) {
|
|
460
418
|
return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !g(e);
|
|
461
419
|
}
|
|
462
|
-
var
|
|
420
|
+
var je = /* @__PURE__ */ m({
|
|
463
421
|
name: "AppLogo",
|
|
464
422
|
props: {
|
|
465
423
|
src: [String, Function],
|
|
@@ -509,10 +467,10 @@ var Ne = /* @__PURE__ */ m({
|
|
|
509
467
|
src: n.value,
|
|
510
468
|
alt: "App Logo",
|
|
511
469
|
style: `transition: height 0.2s ease-in-out; height: calc(var(--app-logo-img-size) * ${c})`
|
|
512
|
-
}, null)])])]), i ? p(
|
|
470
|
+
}, null)])])]), i ? p(H, {
|
|
513
471
|
class: "app-logo__name",
|
|
514
472
|
style: "font-size: var(--app-logo-name-size); font-weight: bold; white-space: nowrap; flex: 0 1 auto; overflow: hidden"
|
|
515
|
-
},
|
|
473
|
+
}, Ae(i) ? i : { default: () => [i] }) : void 0]);
|
|
516
474
|
};
|
|
517
475
|
}
|
|
518
476
|
});
|
|
@@ -521,7 +479,7 @@ var Ne = /* @__PURE__ */ m({
|
|
|
521
479
|
function Z(e) {
|
|
522
480
|
return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !g(e);
|
|
523
481
|
}
|
|
524
|
-
var
|
|
482
|
+
var Me = /* @__PURE__ */ m({
|
|
525
483
|
name: "AppMenu",
|
|
526
484
|
props: {
|
|
527
485
|
menus: Array,
|
|
@@ -556,7 +514,7 @@ var Pe = /* @__PURE__ */ m({
|
|
|
556
514
|
_: o,
|
|
557
515
|
key: o.key,
|
|
558
516
|
label: () => e.renderLabel?.(o) ?? o.name,
|
|
559
|
-
icon: n === 0 || o.icon ?
|
|
517
|
+
icon: n === 0 || o.icon ? me(o.icon) || typeof o.icon == "string" ? e.getIcon?.(o.icon, o) ?? J : o.icon : void 0,
|
|
560
518
|
children: r ? void 0 : t,
|
|
561
519
|
path: o.path || (r ? t?.[0]?.path : void 0),
|
|
562
520
|
depth: n
|
|
@@ -578,7 +536,7 @@ var Pe = /* @__PURE__ */ m({
|
|
|
578
536
|
}, [t.label()]);
|
|
579
537
|
else {
|
|
580
538
|
let e;
|
|
581
|
-
i = p(
|
|
539
|
+
i = p(fe, { to: t.path }, Z(e = t.label()) ? e : { default: () => [e] });
|
|
582
540
|
}
|
|
583
541
|
else i = p("span", null, [t.label()]);
|
|
584
542
|
return i.key = `${t.key}:${+!!r}`, t.depth === 0 && !r && (i = O(p("div", null, [i]), [[
|
|
@@ -601,7 +559,7 @@ var Pe = /* @__PURE__ */ m({
|
|
|
601
559
|
}, null)])])), i;
|
|
602
560
|
};
|
|
603
561
|
return () => {
|
|
604
|
-
let i = p(
|
|
562
|
+
let i = p(R, {
|
|
605
563
|
ref: "menu",
|
|
606
564
|
options: t.value,
|
|
607
565
|
rootIndent: 16,
|
|
@@ -615,16 +573,16 @@ var Pe = /* @__PURE__ */ m({
|
|
|
615
573
|
collapsedWidth: e.collapsedWidth,
|
|
616
574
|
width: e.width
|
|
617
575
|
}, null);
|
|
618
|
-
return e.horizontal ? i : p(
|
|
576
|
+
return e.horizontal ? i : p(V, null, Z(i) ? i : { default: () => [i] });
|
|
619
577
|
};
|
|
620
578
|
}
|
|
621
579
|
});
|
|
622
580
|
//#endregion
|
|
623
581
|
//#region src/design/MultiTabs.jsx
|
|
624
|
-
function
|
|
582
|
+
function Ne(e) {
|
|
625
583
|
return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !g(e);
|
|
626
584
|
}
|
|
627
|
-
function
|
|
585
|
+
function Pe(t, n, r) {
|
|
628
586
|
let { t: i } = e(), a = y({
|
|
629
587
|
visible: !1,
|
|
630
588
|
x: 0,
|
|
@@ -645,7 +603,7 @@ function Q(t, n, r) {
|
|
|
645
603
|
key: "reload",
|
|
646
604
|
label: i("common.layout.tabs.reloadTab"),
|
|
647
605
|
disabled: !a.tab || a.tab.key !== n.value,
|
|
648
|
-
icon: () => p(
|
|
606
|
+
icon: () => p(P, { size: 20 }, { default: () => [p("svg", {
|
|
649
607
|
xmlns: "http://www.w3.org/2000/svg",
|
|
650
608
|
"xmlns:xlink": "http://www.w3.org/1999/xlink",
|
|
651
609
|
role: "img",
|
|
@@ -660,7 +618,7 @@ function Q(t, n, r) {
|
|
|
660
618
|
{
|
|
661
619
|
key: "fullTab",
|
|
662
620
|
label: i("common.layout.tabs.fullTab"),
|
|
663
|
-
icon: () => p(
|
|
621
|
+
icon: () => p(P, { size: 16 }, { default: () => [p("svg", {
|
|
664
622
|
xmlns: "http://www.w3.org/2000/svg",
|
|
665
623
|
width: "1em",
|
|
666
624
|
height: "1em",
|
|
@@ -680,7 +638,7 @@ function Q(t, n, r) {
|
|
|
680
638
|
key: "open",
|
|
681
639
|
label: i("common.layout.tabs.openTabBlank"),
|
|
682
640
|
disabled: !a.tab,
|
|
683
|
-
icon: () => p(
|
|
641
|
+
icon: () => p(P, { size: 20 }, { default: () => [p("svg", {
|
|
684
642
|
xmlns: "http://www.w3.org/2000/svg",
|
|
685
643
|
"xmlns:xlink": "http://www.w3.org/1999/xlink",
|
|
686
644
|
role: "img",
|
|
@@ -697,7 +655,7 @@ function Q(t, n, r) {
|
|
|
697
655
|
{
|
|
698
656
|
key: "closeAll",
|
|
699
657
|
label: i("common.layout.tabs.closeAllTabs"),
|
|
700
|
-
icon: () => p(
|
|
658
|
+
icon: () => p(P, { size: 20 }, { default: () => [p("svg", {
|
|
701
659
|
xmlns: "http://www.w3.org/2000/svg",
|
|
702
660
|
"xmlns:xlink": "http://www.w3.org/1999/xlink",
|
|
703
661
|
role: "img",
|
|
@@ -713,7 +671,7 @@ function Q(t, n, r) {
|
|
|
713
671
|
key: "closeLeft",
|
|
714
672
|
label: i("common.layout.tabs.closeLeftTabs"),
|
|
715
673
|
disabled: !a.tab,
|
|
716
|
-
icon: () => p(
|
|
674
|
+
icon: () => p(P, { size: 20 }, { default: () => [p("svg", {
|
|
717
675
|
xmlns: "http://www.w3.org/2000/svg",
|
|
718
676
|
"xmlns:xlink": "http://www.w3.org/1999/xlink",
|
|
719
677
|
role: "img",
|
|
@@ -729,7 +687,7 @@ function Q(t, n, r) {
|
|
|
729
687
|
key: "closeRight",
|
|
730
688
|
label: i("common.layout.tabs.closeRightTabs"),
|
|
731
689
|
disabled: !a.tab,
|
|
732
|
-
icon: () => p(
|
|
690
|
+
icon: () => p(P, { size: 20 }, { default: () => [p("svg", {
|
|
733
691
|
xmlns: "http://www.w3.org/2000/svg",
|
|
734
692
|
"xmlns:xlink": "http://www.w3.org/1999/xlink",
|
|
735
693
|
role: "img",
|
|
@@ -745,7 +703,7 @@ function Q(t, n, r) {
|
|
|
745
703
|
key: "closeOther",
|
|
746
704
|
label: i("common.layout.tabs.closeOtherTabs"),
|
|
747
705
|
disabled: !a.tab,
|
|
748
|
-
icon: () => p(
|
|
706
|
+
icon: () => p(P, { size: 20 }, { default: () => [" ", p("svg", {
|
|
749
707
|
xmlns: "http://www.w3.org/2000/svg",
|
|
750
708
|
"xmlns:xlink": "http://www.w3.org/1999/xlink",
|
|
751
709
|
role: "img",
|
|
@@ -796,7 +754,7 @@ function Q(t, n, r) {
|
|
|
796
754
|
}
|
|
797
755
|
};
|
|
798
756
|
}
|
|
799
|
-
function
|
|
757
|
+
function Fe(e, t, n) {
|
|
800
758
|
function r(n) {
|
|
801
759
|
if (n === -1 || !t.value?.children.length) return;
|
|
802
760
|
let r = t.value.children[n];
|
|
@@ -814,7 +772,7 @@ function Ie(e, t, n) {
|
|
|
814
772
|
content: t
|
|
815
773
|
};
|
|
816
774
|
}
|
|
817
|
-
var
|
|
775
|
+
var Q = (e) => p("svg", e, [
|
|
818
776
|
p("defs", null, [
|
|
819
777
|
p("symbol", {
|
|
820
778
|
id: "geometry-left",
|
|
@@ -850,7 +808,7 @@ var Le = (e) => p("svg", e, [
|
|
|
850
808
|
height: "36",
|
|
851
809
|
fill: "currentColor"
|
|
852
810
|
}, null)])])
|
|
853
|
-
]),
|
|
811
|
+
]), Ie = /* @__PURE__ */ m({
|
|
854
812
|
name: "AppTab",
|
|
855
813
|
props: {
|
|
856
814
|
path: String,
|
|
@@ -865,7 +823,7 @@ var Le = (e) => p("svg", e, [
|
|
|
865
823
|
D(s, async () => {
|
|
866
824
|
await k(1), a.value.style.width = o.value.scrollWidth + "px";
|
|
867
825
|
});
|
|
868
|
-
let c =
|
|
826
|
+
let c = W(), l = f(() => ({
|
|
869
827
|
fontSize: "14px",
|
|
870
828
|
color: e.isCurrent ? c.value.primaryColor : c.value.textColor3,
|
|
871
829
|
maxWidth: "355px",
|
|
@@ -877,7 +835,7 @@ var Le = (e) => p("svg", e, [
|
|
|
877
835
|
top: "0",
|
|
878
836
|
left: "-14px",
|
|
879
837
|
zIndex: e.isCurrent ? -1 : -2,
|
|
880
|
-
color: e.isCurrent ?
|
|
838
|
+
color: e.isCurrent ? he(c.value.primaryColor, e.dark ? .3 : .12, e.dark ? "#000" : "#fff") : i.value ? c.value.borderColor : "transparent"
|
|
881
839
|
}));
|
|
882
840
|
return () => p("div", {
|
|
883
841
|
ref: r,
|
|
@@ -889,12 +847,12 @@ var Le = (e) => p("svg", e, [
|
|
|
889
847
|
}, [p("div", {
|
|
890
848
|
ref: o,
|
|
891
849
|
style: "display: flex; align-items: center; gap: 4px; width: fit-content"
|
|
892
|
-
}, [p("span", { style: l.value }, [x(n, "default")]), e.closable !== !1 && (e.isCurrent || i.value) ? p("span", { style: "line-height: 0; display: inline-block; text-align: right; padding-top: 2px" }, [p(
|
|
850
|
+
}, [p("span", { style: l.value }, [x(n, "default")]), e.closable !== !1 && (e.isCurrent || i.value) ? p("span", { style: "line-height: 0; display: inline-block; text-align: right; padding-top: 2px" }, [p(M, {
|
|
893
851
|
text: !0,
|
|
894
852
|
onClick: (e) => {
|
|
895
853
|
e.stopPropagation(), t("close");
|
|
896
854
|
}
|
|
897
|
-
}, { default: () => [p(
|
|
855
|
+
}, { default: () => [p(P, { size: 18 }, { default: () => [p("svg", {
|
|
898
856
|
xmlns: "http://www.w3.org/2000/svg",
|
|
899
857
|
width: "1em",
|
|
900
858
|
height: "1em",
|
|
@@ -904,10 +862,10 @@ var Le = (e) => p("svg", e, [
|
|
|
904
862
|
d: "m6.4 18.308l-.708-.708l5.6-5.6l-5.6-5.6l.708-.708l5.6 5.6l5.6-5.6l.708.708l-5.6 5.6l5.6 5.6l-.708.708l-5.6-5.6z"
|
|
905
863
|
}, null)])] })] })]) : void 0])]),
|
|
906
864
|
p("span", { style: "height: 50%; width: 1px; background: #aaa; display: inline-block; position: absolute; top: 20%; right: -4px; z-index: -3" }, null),
|
|
907
|
-
p(
|
|
865
|
+
p(Q, { style: u.value }, null)
|
|
908
866
|
]);
|
|
909
867
|
}
|
|
910
|
-
}),
|
|
868
|
+
}), Le = /* @__PURE__ */ m({
|
|
911
869
|
name: "AppMultiTabs",
|
|
912
870
|
props: {
|
|
913
871
|
fullTab: Boolean,
|
|
@@ -920,8 +878,8 @@ var Le = (e) => p("svg", e, [
|
|
|
920
878
|
setup(e, { emit: t, slots: n }) {
|
|
921
879
|
let r = X();
|
|
922
880
|
r.hasMultiTab = !0;
|
|
923
|
-
let i = G(), { ctx: a, onCtx: o, onClickOutside: s, options: c, onSelect: l } =
|
|
924
|
-
return
|
|
881
|
+
let i = G(), { ctx: a, onCtx: o, onClickOutside: s, options: c, onSelect: l } = Pe(C(e, "tabs"), f(() => e.current?.key), () => t("update:fullTab", !e.fullTab)), u = f(() => e.current ? e.tabs.findIndex((t) => t.key === e.current?.key) : -1), d = b(), m = b();
|
|
882
|
+
return Fe(d, m, u), () => p("div", { style: "width: 100%; height: 100%; overflow: hidden; display: flex; justify-content: space-between" }, [p("div", {
|
|
925
883
|
ref: d,
|
|
926
884
|
style: "flex: 1 1 100%; height: 100%; display: flex; overflow: hidden; align-items: center; position: relative"
|
|
927
885
|
}, [
|
|
@@ -932,7 +890,7 @@ var Le = (e) => p("svg", e, [
|
|
|
932
890
|
onContextmenu: (e) => o(e)
|
|
933
891
|
}, [e.tabs.map((t, r, a) => {
|
|
934
892
|
let s, c = e.current?.key === t.key, l = t.title ?? t.path;
|
|
935
|
-
return p(
|
|
893
|
+
return p(Ie, {
|
|
936
894
|
key: t.key,
|
|
937
895
|
isCurrent: c,
|
|
938
896
|
isLast: r === a.length - 1,
|
|
@@ -943,14 +901,14 @@ var Le = (e) => p("svg", e, [
|
|
|
943
901
|
c || i.push(t.fullPath);
|
|
944
902
|
},
|
|
945
903
|
onContextmenu: (e) => o(e, t)
|
|
946
|
-
},
|
|
904
|
+
}, Ne(s = x(n, "name", {
|
|
947
905
|
isCurrent: c,
|
|
948
906
|
name: l,
|
|
949
907
|
tab: t
|
|
950
908
|
}, () => [l])) ? s : { default: () => [s] });
|
|
951
909
|
})]),
|
|
952
910
|
p("div", { style: "height: 100%; flex: 0 0 16px; z-index: 1; position: sticky; right: 0; backdrop-filter: opacity(0.9) blur(5px)" }, null)
|
|
953
|
-
]), p(
|
|
911
|
+
]), p(N, {
|
|
954
912
|
placement: "bottom-start",
|
|
955
913
|
trigger: "manual",
|
|
956
914
|
show: a.visible,
|
|
@@ -967,7 +925,7 @@ var Le = (e) => p("svg", e, [
|
|
|
967
925
|
function $(e) {
|
|
968
926
|
return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !g(e);
|
|
969
927
|
}
|
|
970
|
-
var
|
|
928
|
+
var Re = /* @__PURE__ */ m({
|
|
971
929
|
name: "AppNotification",
|
|
972
930
|
inheritAttrs: !1,
|
|
973
931
|
props: {
|
|
@@ -998,7 +956,7 @@ var Be = /* @__PURE__ */ m({
|
|
|
998
956
|
}).finally(() => {
|
|
999
957
|
l.loading = !1;
|
|
1000
958
|
});
|
|
1001
|
-
}, { sync: m, post: h } =
|
|
959
|
+
}, { sync: m, post: h } = de({
|
|
1002
960
|
channel: "__ithinkdt_mc_shared_channel",
|
|
1003
961
|
onMsg: (e) => {
|
|
1004
962
|
l.unread = e;
|
|
@@ -1006,13 +964,13 @@ var Be = /* @__PURE__ */ m({
|
|
|
1006
964
|
getMsg: () => t.getUnreadCount?.() ?? 0,
|
|
1007
965
|
timeout: () => t.interval,
|
|
1008
966
|
immediate: !0
|
|
1009
|
-
}), g =
|
|
967
|
+
}), g = ue(() => {
|
|
1010
968
|
l.page = 1, f();
|
|
1011
969
|
}, 300), v = (e) => {
|
|
1012
970
|
u.value = e, g();
|
|
1013
971
|
}, S = () => {
|
|
1014
972
|
let e;
|
|
1015
|
-
return O(p(
|
|
973
|
+
return O(p(M, _(r, {
|
|
1016
974
|
quaternary: !0,
|
|
1017
975
|
style: "--n-padding: 0 12px",
|
|
1018
976
|
onClick: () => {
|
|
@@ -1023,7 +981,7 @@ var Be = /* @__PURE__ */ m({
|
|
|
1023
981
|
dot: !0,
|
|
1024
982
|
offset: [-2, 5],
|
|
1025
983
|
processing: !0
|
|
1026
|
-
}, { default: () => [p(
|
|
984
|
+
}, { default: () => [p(P, { size: "18" }, { default: () => [p("svg", {
|
|
1027
985
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1028
986
|
width: "1em",
|
|
1029
987
|
height: "1em",
|
|
@@ -1045,14 +1003,14 @@ var Be = /* @__PURE__ */ m({
|
|
|
1045
1003
|
let e, t;
|
|
1046
1004
|
return p("div", { style: "display: flex; align-items: baseline; gap: 20px" }, [
|
|
1047
1005
|
p("div", { style: "padding-right: 12px" }, [i("common.notification.title")]),
|
|
1048
|
-
p(
|
|
1006
|
+
p(M, {
|
|
1049
1007
|
text: !0,
|
|
1050
1008
|
type: o.value === "all" ? "primary" : "default",
|
|
1051
1009
|
onClick: () => {
|
|
1052
1010
|
o.value = "all", f();
|
|
1053
1011
|
}
|
|
1054
1012
|
}, $(e = i("common.notification.all")) ? e : { default: () => [e] }),
|
|
1055
|
-
p(
|
|
1013
|
+
p(M, {
|
|
1056
1014
|
text: !0,
|
|
1057
1015
|
type: o.value === "unread" ? "primary" : "default",
|
|
1058
1016
|
onClick: () => {
|
|
@@ -1060,14 +1018,14 @@ var Be = /* @__PURE__ */ m({
|
|
|
1060
1018
|
}
|
|
1061
1019
|
}, $(t = i("common.notification.unread", { count: l.unread > 99 ? "99+" : l.unread.toString() })) ? t : { default: () => [t] })
|
|
1062
1020
|
]);
|
|
1063
|
-
}, w = (e) => p(
|
|
1021
|
+
}, w = (e) => p(L, {
|
|
1064
1022
|
key: e.key,
|
|
1065
1023
|
onClick: () => {
|
|
1066
1024
|
e.status === "unread" && (t.markRead?.([e.key]).then(() => {
|
|
1067
1025
|
e.status = "read";
|
|
1068
1026
|
}), l.unread--), e.link && window.open(e.link, "_target");
|
|
1069
1027
|
}
|
|
1070
|
-
}, { default: () => [p(
|
|
1028
|
+
}, { default: () => [p(U, {
|
|
1071
1029
|
bordered: !1,
|
|
1072
1030
|
closable: !0,
|
|
1073
1031
|
contentIndented: !0,
|
|
@@ -1076,7 +1034,7 @@ var Be = /* @__PURE__ */ m({
|
|
|
1076
1034
|
onMouseleave: () => e.hover = !1,
|
|
1077
1035
|
style: "padding: 0 4px; position: relative"
|
|
1078
1036
|
}, {
|
|
1079
|
-
avatar: () => p(
|
|
1037
|
+
avatar: () => p(P, {
|
|
1080
1038
|
size: 22,
|
|
1081
1039
|
color: e.status === "unread" ? "var(--color-primary)" : void 0
|
|
1082
1040
|
}, { default: () => [p("svg", {
|
|
@@ -1092,12 +1050,12 @@ var Be = /* @__PURE__ */ m({
|
|
|
1092
1050
|
default: e.content,
|
|
1093
1051
|
footer: () => {
|
|
1094
1052
|
let n, r;
|
|
1095
|
-
return p("div", { style: "display: flex; align-items: center; justify-content: space-between" }, [p("span", { style: "color: gray" }, [e.hover ?
|
|
1053
|
+
return p("div", { style: "display: flex; align-items: center; justify-content: space-between" }, [p("span", { style: "color: gray" }, [e.hover ? ge(e.date, i("common.notification.time")) : i("common.timeago", { time: e.date })]), e.hover ? p("div", {
|
|
1096
1054
|
style: "display: flex; gap: 12px",
|
|
1097
1055
|
onClick: (e) => {
|
|
1098
1056
|
e.preventDefault(), e.stopPropagation();
|
|
1099
1057
|
}
|
|
1100
|
-
}, [e.status === "unread" ? p(
|
|
1058
|
+
}, [e.status === "unread" ? p(M, {
|
|
1101
1059
|
text: !0,
|
|
1102
1060
|
type: "primary",
|
|
1103
1061
|
onClick: () => {
|
|
@@ -1105,7 +1063,7 @@ var Be = /* @__PURE__ */ m({
|
|
|
1105
1063
|
e.status = "read", l.unread--;
|
|
1106
1064
|
});
|
|
1107
1065
|
}
|
|
1108
|
-
}, $(n = i("common.notification.markRead")) ? n : { default: () => [n] }) : void 0, p(
|
|
1066
|
+
}, $(n = i("common.notification.markRead")) ? n : { default: () => [n] }) : void 0, p(M, {
|
|
1109
1067
|
text: !0,
|
|
1110
1068
|
type: "error",
|
|
1111
1069
|
onClick: () => {
|
|
@@ -1115,12 +1073,12 @@ var Be = /* @__PURE__ */ m({
|
|
|
1115
1073
|
}
|
|
1116
1074
|
})] }), T = () => {
|
|
1117
1075
|
let e;
|
|
1118
|
-
return p("div", null, [p("div", { style: "padding: 12px 20px; position: sticky; z-index: 1; top: 0; backdrop-filter: blur(6px)" }, [p(
|
|
1076
|
+
return p("div", null, [p("div", { style: "padding: 12px 20px; position: sticky; z-index: 1; top: 0; backdrop-filter: blur(6px)" }, [p(F, {
|
|
1119
1077
|
size: "small",
|
|
1120
1078
|
clearable: !0,
|
|
1121
1079
|
value: u.value,
|
|
1122
1080
|
onUpdateValue: v
|
|
1123
|
-
}, { suffix: () => p(
|
|
1081
|
+
}, { suffix: () => p(P, { style: "margin-left: 4px" }, { default: () => [p("svg", {
|
|
1124
1082
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1125
1083
|
width: "1em",
|
|
1126
1084
|
height: "1em",
|
|
@@ -1128,12 +1086,12 @@ var Be = /* @__PURE__ */ m({
|
|
|
1128
1086
|
}, [p("path", {
|
|
1129
1087
|
fill: "currentColor",
|
|
1130
1088
|
d: "m18.031 16.617l4.283 4.282l-1.415 1.415l-4.282-4.283A8.96 8.96 0 0 1 11 20c-4.968 0-9-4.032-9-9s4.032-9 9-9s9 4.032 9 9a8.96 8.96 0 0 1-1.969 5.617m-2.006-.742A6.98 6.98 0 0 0 18 11c0-3.867-3.133-7-7-7s-7 3.133-7 7s3.133 7 7 7a6.98 6.98 0 0 0 4.875-1.975z"
|
|
1131
|
-
}, null)])] }) })]), O(l.records.length > 0 ? p(
|
|
1089
|
+
}, null)])] }) })]), O(l.records.length > 0 ? p(I, {
|
|
1132
1090
|
clickable: !0,
|
|
1133
1091
|
hoverable: !0,
|
|
1134
1092
|
style: "min-height: 50vh"
|
|
1135
1093
|
}, $(e = l.records.map((e) => w(e))) ? e : { default: () => [e] }) : p(le, { style: "margin-top: 30vh" }, null), [[c, l.loading]])]);
|
|
1136
|
-
}, E = () => p("div", { style: "display: flex; justify-content: space-between; width: 100%" }, [o.value === "unread" ? p(
|
|
1094
|
+
}, E = () => p("div", { style: "display: flex; justify-content: space-between; width: 100%" }, [o.value === "unread" ? p(M, {
|
|
1137
1095
|
text: !0,
|
|
1138
1096
|
type: "primary",
|
|
1139
1097
|
disabled: l.records.length === 0,
|
|
@@ -1145,7 +1103,7 @@ var Be = /* @__PURE__ */ m({
|
|
|
1145
1103
|
});
|
|
1146
1104
|
}
|
|
1147
1105
|
}, {
|
|
1148
|
-
icon: () => p(
|
|
1106
|
+
icon: () => p(P, { size: "20" }, { default: () => [p("svg", {
|
|
1149
1107
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1150
1108
|
width: "1em",
|
|
1151
1109
|
height: "1em",
|
|
@@ -1155,7 +1113,7 @@ var Be = /* @__PURE__ */ m({
|
|
|
1155
1113
|
d: "M.41 13.41L6 19l1.41-1.42L1.83 12m20.41-6.42L11.66 16.17L7.5 12l-1.43 1.41L11.66 19l12-12M18 7l-1.41-1.42l-6.35 6.35l1.42 1.41z"
|
|
1156
1114
|
}, null)])] }),
|
|
1157
1115
|
default: () => i("common.notification.markPageRead")
|
|
1158
|
-
}) : p("span", null, null), p(
|
|
1116
|
+
}) : p("span", null, null), p(z, {
|
|
1159
1117
|
simple: !0,
|
|
1160
1118
|
pageSize: l.size,
|
|
1161
1119
|
page: l.page,
|
|
@@ -1183,7 +1141,7 @@ var Be = /* @__PURE__ */ m({
|
|
|
1183
1141
|
footer: E
|
|
1184
1142
|
})] })]);
|
|
1185
1143
|
}
|
|
1186
|
-
}),
|
|
1144
|
+
}), ze = (e) => p("svg", _({
|
|
1187
1145
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1188
1146
|
"xmlns:xlink": "http://www.w3.org/1999/xlink",
|
|
1189
1147
|
role: "img",
|
|
@@ -1193,7 +1151,7 @@ var Be = /* @__PURE__ */ m({
|
|
|
1193
1151
|
}, e), [p("path", {
|
|
1194
1152
|
fill: "currentColor",
|
|
1195
1153
|
d: "m9.55 18l-5.7-5.7l1.425-1.425L9.55 15.15l9.175-9.175L20.15 7.4z"
|
|
1196
|
-
}, null)]),
|
|
1154
|
+
}, null)]), Be = /* @__PURE__ */ m({
|
|
1197
1155
|
name: "AppTenant",
|
|
1198
1156
|
props: {
|
|
1199
1157
|
options: Array,
|
|
@@ -1201,11 +1159,11 @@ var Be = /* @__PURE__ */ m({
|
|
|
1201
1159
|
},
|
|
1202
1160
|
emit: ["update:current"],
|
|
1203
1161
|
setup(t, { emit: n }) {
|
|
1204
|
-
let { t: r } = e(), i = (e) => e.disabled ? p("div", null, [e.name]) : p("div", { style: "display: flex; align-items: center; justify-content: space-between; gap: 20px" }, [p("div", { style: "display: flex; align-items: center; gap: 8px" }, [p(
|
|
1162
|
+
let { t: r } = e(), i = (e) => e.disabled ? p("div", null, [e.name]) : p("div", { style: "display: flex; align-items: center; justify-content: space-between; gap: 20px" }, [p("div", { style: "display: flex; align-items: center; gap: 8px" }, [p(j, {
|
|
1205
1163
|
round: !0,
|
|
1206
1164
|
size: 22,
|
|
1207
1165
|
color: "var(--color-primary-hover)"
|
|
1208
|
-
}, { default: () => [e.icon?.() || e.name[0]] }), p("span", { style: e.id === t.current ? "color: var(--color-primary)" : "" }, [e.name])]), e.id === t.current ? p(
|
|
1166
|
+
}, { default: () => [e.icon?.() || e.name[0]] }), p("span", { style: e.id === t.current ? "color: var(--color-primary)" : "" }, [e.name])]), e.id === t.current ? p(ze, { style: "color: var(--color-primary); font-size: 20px" }, null) : p("div", null, null)]), a = f(() => [{
|
|
1209
1167
|
id: "___",
|
|
1210
1168
|
name: r("common.account.changeTenant"),
|
|
1211
1169
|
disabled: !0
|
|
@@ -1213,7 +1171,7 @@ var Be = /* @__PURE__ */ m({
|
|
|
1213
1171
|
return () => {
|
|
1214
1172
|
if (!t.options?.length) return;
|
|
1215
1173
|
let e = t.options.find((e) => e.id === t.current);
|
|
1216
|
-
return p(
|
|
1174
|
+
return p(N, {
|
|
1217
1175
|
options: a.value,
|
|
1218
1176
|
placement: "bottom-end",
|
|
1219
1177
|
keyField: "id",
|
|
@@ -1221,11 +1179,11 @@ var Be = /* @__PURE__ */ m({
|
|
|
1221
1179
|
showArrow: !0,
|
|
1222
1180
|
renderLabel: i,
|
|
1223
1181
|
onSelect: (e) => e !== t.current && n("update:current", e)
|
|
1224
|
-
}, { default: () => [p(
|
|
1182
|
+
}, { default: () => [p(M, {
|
|
1225
1183
|
quaternary: !0,
|
|
1226
1184
|
style: "--n-padding: 0 6px"
|
|
1227
1185
|
}, {
|
|
1228
|
-
icon: () => p(
|
|
1186
|
+
icon: () => p(P, { size: "18" }, { default: () => [p("svg", {
|
|
1229
1187
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1230
1188
|
"xmlns:xlink": "http://www.w3.org/1999/xlink",
|
|
1231
1189
|
viewBox: "0 0 1024 1024",
|
|
@@ -1240,7 +1198,7 @@ var Be = /* @__PURE__ */ m({
|
|
|
1240
1198
|
})] });
|
|
1241
1199
|
};
|
|
1242
1200
|
}
|
|
1243
|
-
}),
|
|
1201
|
+
}), Ve = /* @__PURE__ */ m({
|
|
1244
1202
|
name: "UIProvider",
|
|
1245
1203
|
props: { i18n: Function },
|
|
1246
1204
|
setup(e, { slots: n }) {
|
|
@@ -1248,4 +1206,4 @@ var Be = /* @__PURE__ */ m({
|
|
|
1248
1206
|
}
|
|
1249
1207
|
});
|
|
1250
1208
|
//#endregion
|
|
1251
|
-
export {
|
|
1209
|
+
export { _e as AppAccount, ve as AppAppearance, be as AppBreadcrumb, Oe as AppContent, ke as AppFooter, Ee as AppHeader, xe as AppLanguage, Te as AppLayout, je as AppLogo, Me as AppMenu, Le as AppMultiTabs, Re as AppNotification, De as AppSidebar, Be as AppTenant, u as SpinDirectiveProvider, l as TooltipDirectiveProvider, Ve as UIProvider, c as vSpin, s as vTooltip };
|