@huyooo/ui 1.0.6 → 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/AuthkitAppSetting-rtYZcSAR.js +2677 -0
- package/dist/{Contact-BWuVR9ho.js → Contact-CcWf3UEZ.js} +9 -9
- package/dist/{CustomTable-BzGfaAVH.js → CustomTable-HDwqEcmB.js} +1 -1
- package/dist/FeedbackModal.vue_vue_type_script_setup_true_lang-DpOmbAg-.js +1491 -0
- package/dist/{LegalDocViewer-DM8FYBpf.js → LegalDocViewer-C0tsIbz9.js} +747 -748
- package/dist/MessageHandle-BUufez4S.js +1233 -0
- package/dist/{MessageList-Ce-_LNTk.js → MessageList-rttvPmxV.js} +4 -4
- package/dist/PaySubscriptions-p75aBnHm.js +1331 -0
- package/dist/{PricingPlans-CV97ck9p.js → PricingPlans-CQ0qk9Hb.js} +99 -105
- package/dist/{ReferrerReferees-DgygiIiE.js → ReferrerReferees-BU9IEQgz.js} +47 -46
- package/dist/Upload.vue_vue_type_script_setup_true_lang-bh0NFq9E.js +78 -0
- package/dist/{UserMenuInvitationsItem.vue_vue_type_script_setup_true_lang-zgjpFVln.js → UserMenuInvitationsItem.vue_vue_type_script_setup_true_lang-DG4AuHiO.js} +64 -65
- package/dist/WidthContainer-DSE4QbW0.js +717 -0
- package/dist/api/billingSubscriptionApi.d.ts +4 -1
- package/dist/apiClients-Ctcq8NZs.js +245 -0
- package/dist/authkit.js +10 -10
- package/dist/common/globalConfig.d.ts +36 -18
- package/dist/common.js +2 -2
- package/dist/components/Authkit/Auth/AuthkitOauthCallback.vue.d.ts +2 -2
- package/dist/components/Authkit/AuthkitProvider.vue.d.ts +0 -5
- package/dist/components/Feedback/FeedbackDetails.vue.d.ts +30 -0
- package/dist/components/Upload/Upload.vue.d.ts +6 -6
- package/dist/composables/Authkit/useAuthkitAuth.d.ts +3 -0
- package/dist/composables/Billing/usePaymentReturn.d.ts +1 -0
- package/dist/composables/uploadFeedbackAttachment.d.ts +2 -1
- package/dist/composables/useMessageList.d.ts +2 -1
- package/dist/composables.d.ts +2 -2
- package/dist/composables.js +46 -46
- package/dist/feedback.js +2 -2
- package/dist/{fetchAuthPageAboutUs-dzTSwRsB.js → fetchAuthPageAboutUs-DiCqMUX3.js} +4 -4
- package/dist/{index-BkLvw1PU.js → index-Cn6LcfZO.js} +1 -1
- package/dist/legalDocs/resolveAppId.d.ts +1 -1
- package/dist/main.d.ts +4 -3
- package/dist/main.js +464 -469
- package/dist/message.js +53 -52
- package/dist/pay.js +4 -4
- package/dist/privateCom.js +1 -1
- package/dist/referrer.js +1 -1
- package/dist/{useUploadCos-C8BqFPkx.js → runtime-BzCSCUNv.js} +2712 -2609
- package/dist/runtime.d.ts +18 -0
- package/dist/style.css +1 -1
- package/dist/types/api/auth.generated.d.ts +0 -10
- package/dist/upload/browserCosTransport.d.ts +25 -0
- package/dist/upload/browserUploadService.d.ts +20 -0
- package/dist/upload.d.ts +2 -1
- package/dist/upload.js +5 -4
- package/dist/{useAuthkitAppsAuthPageInfo-CNudJd04.js → useAuthkitAppsAuthPageInfo-DZ1p-P3Q.js} +18 -21
- package/dist/useAuthkitAuth-BPTZUSkM.js +272 -0
- package/dist/{useAuthkitCreateAndUpdate-BsINsI-E.js → useAuthkitCreateAndUpdate-Bbv7vZZn.js} +1 -1
- package/dist/useAuthkitUsersProfile-CW_exa7E.js +39 -0
- package/dist/useBillingStatusOptions-Br-iL77Z.js +61 -0
- package/dist/{useEnsureAuthenticated-DNkCCy_Y.js → useEnsureAuthenticated-CncOvj2H.js} +2 -2
- package/dist/{useLegalDocs-DQP_Yq6B.js → useLegalDocs-D44qU_q0.js} +25 -25
- package/dist/useMessageNotifications-D9uikt21.js +80 -0
- package/dist/{useRoutePermission-CEiya9AM.js → useRoutePermission-BrQX7NTq.js} +2 -2
- package/dist/{useSEO-CDWxbk8B.js → useSEO-_TNouXE_.js} +89 -86
- package/dist/useSubscriptionCheckout-BDDCRxSs.js +353 -0
- package/dist/user.js +1 -1
- package/dist/utils/apiClients.d.ts +20 -12
- package/dist/utils/apiMiddlewares.d.ts +9 -23
- package/package.json +1 -1
- package/dist/AuthkitAppSetting-BN8-xgNq.js +0 -2674
- package/dist/FeedbackModal.vue_vue_type_script_setup_true_lang-B9BqGWm8.js +0 -1480
- package/dist/MessageHandle-mEkCsv9e.js +0 -1173
- package/dist/PaySubscriptions-CXkEjqr2.js +0 -1326
- package/dist/Upload.vue_vue_type_script_setup_true_lang-VGh2V4o0.js +0 -76
- package/dist/WidthContainer-PeWkCK0p.js +0 -721
- package/dist/apiClients-BcXOLuYu.js +0 -272
- package/dist/composables/Upload/useUploadCos.d.ts +0 -12
- package/dist/useAuthkitAuth-3m0yW6uP.js +0 -267
- package/dist/useAuthkitUsersProfile-DJlMsftY.js +0 -40
- package/dist/useBillingStatusOptions-CfHQOFNw.js +0 -71
- package/dist/useMessageNotifications-CAphguOm.js +0 -75
- package/dist/useSubscriptionCheckout-d_M_rKRa.js +0 -368
- package/dist/utils/billingFetch.d.ts +0 -1
|
@@ -0,0 +1,717 @@
|
|
|
1
|
+
/* empty css */
|
|
2
|
+
import "./userMenuModal-D-nDaYqM.js";
|
|
3
|
+
import { defineComponent as P, ref as A, watch as N, openBlock as n, createElementBlock as s, createElementVNode as a, createVNode as r, unref as c, withCtx as B, createTextVNode as K, renderSlot as V, toDisplayString as M, createCommentVNode as x, onMounted as Q, onBeforeUnmount as X, normalizeClass as $, Fragment as L, renderList as E, createBlock as Y, Teleport as ge, nextTick as J, computed as U, normalizeStyle as O } from "vue";
|
|
4
|
+
import { Spin as Z } from "@arco-design/web-vue";
|
|
5
|
+
import { u as ee } from "./useAuthkitAuth-BPTZUSkM.js";
|
|
6
|
+
import "./apiClients-Ctcq8NZs.js";
|
|
7
|
+
import { u as q } from "./useAuthkitAppsAuthPageInfo-DZ1p-P3Q.js";
|
|
8
|
+
import { d as ye, b as be } from "./runtime-BzCSCUNv.js";
|
|
9
|
+
import "@vafast/api-client";
|
|
10
|
+
import "./useAuthkitUsersProfile-CW_exa7E.js";
|
|
11
|
+
import { b as te, f as ne, w as W, a as oe, c as se } from "./useRoutePermission-BrQX7NTq.js";
|
|
12
|
+
import { useRouter as ae, useRoute as re } from "vue-router";
|
|
13
|
+
import "@unhead/vue";
|
|
14
|
+
import "./useUserMenu-ClPBlvaM.js";
|
|
15
|
+
import { c as ie, h as ue, k as le, _ as ce, f as de, j as me, d as pe, g as R, U as ke, i as he } from "./UserMenuInvitationsItem.vue_vue_type_script_setup_true_lang-DG4AuHiO.js";
|
|
16
|
+
import "./PaySubscriptions-p75aBnHm.js";
|
|
17
|
+
/* empty css */
|
|
18
|
+
/* empty css */
|
|
19
|
+
import { M as we } from "./Menu-uCexrsKP.js";
|
|
20
|
+
import "./CollapseItem-DUzZA6tx.js";
|
|
21
|
+
/* empty css */
|
|
22
|
+
/* empty css */
|
|
23
|
+
import "./index-Cn6LcfZO.js";
|
|
24
|
+
/* empty css */
|
|
25
|
+
import "./CustomTable-HDwqEcmB.js";
|
|
26
|
+
import "@vueuse/core";
|
|
27
|
+
import "./index-D56hUMeD.js";
|
|
28
|
+
import { Icon as z } from "@iconify/vue";
|
|
29
|
+
import { L as fe } from "./Logo-D7fyXyB-.js";
|
|
30
|
+
import { _ as C } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
31
|
+
const $e = {
|
|
32
|
+
class: "SidebarCom"
|
|
33
|
+
}, Me = {
|
|
34
|
+
class: "LogoContent"
|
|
35
|
+
}, Ce = {
|
|
36
|
+
class: "MenuContent"
|
|
37
|
+
}, Te = {
|
|
38
|
+
class: "sidebar-footer"
|
|
39
|
+
}, Se = /* @__PURE__ */ P({
|
|
40
|
+
__name: "AppSidebar",
|
|
41
|
+
props: {
|
|
42
|
+
menuType: {
|
|
43
|
+
default: "system"
|
|
44
|
+
},
|
|
45
|
+
showUserPanel: {
|
|
46
|
+
type: Boolean,
|
|
47
|
+
default: !0
|
|
48
|
+
}
|
|
49
|
+
},
|
|
50
|
+
setup(p) {
|
|
51
|
+
const t = p, {
|
|
52
|
+
appsData: d
|
|
53
|
+
} = q(), {
|
|
54
|
+
signOut: h
|
|
55
|
+
} = ee(), {
|
|
56
|
+
menus: i
|
|
57
|
+
} = te(t.menuType), m = ae();
|
|
58
|
+
function g() {
|
|
59
|
+
m.push({
|
|
60
|
+
path: "/"
|
|
61
|
+
});
|
|
62
|
+
}
|
|
63
|
+
async function b() {
|
|
64
|
+
await h(), g();
|
|
65
|
+
}
|
|
66
|
+
const f = re(), w = A([""]);
|
|
67
|
+
function T(y) {
|
|
68
|
+
const e = y.path;
|
|
69
|
+
W(() => {
|
|
70
|
+
m.push({
|
|
71
|
+
path: e,
|
|
72
|
+
query: f.query
|
|
73
|
+
}), w.value = [e], window.scrollTo({
|
|
74
|
+
top: 0,
|
|
75
|
+
behavior: "smooth"
|
|
76
|
+
});
|
|
77
|
+
});
|
|
78
|
+
}
|
|
79
|
+
return N(() => [f.path, i.value], () => {
|
|
80
|
+
const y = ne(i.value, f.path, {
|
|
81
|
+
// Sidebar 中,子路由应该选中子菜单项
|
|
82
|
+
returnParentOnChildMatch: !1,
|
|
83
|
+
// 后备查找函数
|
|
84
|
+
fallback: (e) => oe(f.matched, t.menuType, e)
|
|
85
|
+
});
|
|
86
|
+
y && (w.value = [y]);
|
|
87
|
+
}, {
|
|
88
|
+
immediate: !0,
|
|
89
|
+
deep: !0
|
|
90
|
+
}), (y, e) => (n(), s("div", $e, [a("div", Me, [r(c(fe), {
|
|
91
|
+
icon: c(d).applicationLogoUrl,
|
|
92
|
+
name: c(d).name,
|
|
93
|
+
onTo: g
|
|
94
|
+
}, null, 8, ["icon", "name"])]), a("div", Ce, [r(we, {
|
|
95
|
+
"selected-keys": w.value,
|
|
96
|
+
"onUpdate:selectedKeys": e[0] || (e[0] = (u) => w.value = u),
|
|
97
|
+
menus: c(i),
|
|
98
|
+
onChange: T
|
|
99
|
+
}, null, 8, ["selected-keys", "menus"])]), a("div", Te, [r(c(ie), {
|
|
100
|
+
position: "tr",
|
|
101
|
+
"dropdown-offset-y": "30px"
|
|
102
|
+
}, {
|
|
103
|
+
trigger: B(() => [r(c(ke))]),
|
|
104
|
+
items: B(() => [r(c(ue)), r(c(le)), r(c(ce)), r(c(de)), r(c(me)), r(c(pe)), r(c(R), {
|
|
105
|
+
icon: "lucide:home",
|
|
106
|
+
onClick: g
|
|
107
|
+
}, {
|
|
108
|
+
default: B(() => [...e[1] || (e[1] = [K("主页", -1)])]),
|
|
109
|
+
_: 1
|
|
110
|
+
}), r(c(R), {
|
|
111
|
+
icon: "lucide:log-out",
|
|
112
|
+
danger: "",
|
|
113
|
+
onClick: b
|
|
114
|
+
}, {
|
|
115
|
+
default: B(() => [...e[2] || (e[2] = [K("退出登陆", -1)])]),
|
|
116
|
+
_: 1
|
|
117
|
+
})]),
|
|
118
|
+
_: 1
|
|
119
|
+
}), r(c(he))])]));
|
|
120
|
+
}
|
|
121
|
+
}), Ie = /* @__PURE__ */ C(Se, [["__scopeId", "data-v-a20dd6f7"]]), xe = {
|
|
122
|
+
class: "layout"
|
|
123
|
+
}, Ae = {
|
|
124
|
+
class: "leftContent"
|
|
125
|
+
}, Pe = {
|
|
126
|
+
class: "content"
|
|
127
|
+
}, Be = {
|
|
128
|
+
class: "contentCenter"
|
|
129
|
+
}, Le = {
|
|
130
|
+
class: "pages"
|
|
131
|
+
}, Ue = {
|
|
132
|
+
key: 0,
|
|
133
|
+
class: "loading"
|
|
134
|
+
}, Ke = /* @__PURE__ */ P({
|
|
135
|
+
__name: "AppLayout",
|
|
136
|
+
props: {
|
|
137
|
+
menuType: {
|
|
138
|
+
default: "system"
|
|
139
|
+
},
|
|
140
|
+
showUserPanel: {
|
|
141
|
+
type: Boolean,
|
|
142
|
+
default: !0
|
|
143
|
+
}
|
|
144
|
+
},
|
|
145
|
+
setup(p) {
|
|
146
|
+
const t = p, {
|
|
147
|
+
isChecking: d
|
|
148
|
+
} = se();
|
|
149
|
+
return (h, i) => (n(), s("div", xe, [a("div", Ae, [r(Ie, {
|
|
150
|
+
"menu-type": t.menuType,
|
|
151
|
+
"show-user-panel": t.showUserPanel
|
|
152
|
+
}, null, 8, ["menu-type", "show-user-panel"])]), a("div", Pe, [a("div", Be, [a("div", Le, [c(d) ? (n(), s("div", Ue, [r(c(Z), {
|
|
153
|
+
size: 40
|
|
154
|
+
})])) : V(h.$slots, "default", {
|
|
155
|
+
key: 1
|
|
156
|
+
}, void 0, !0)])])])]));
|
|
157
|
+
}
|
|
158
|
+
}), on = /* @__PURE__ */ C(Ke, [["__scopeId", "data-v-410ad52b"]]), He = {
|
|
159
|
+
class: "ContentHead"
|
|
160
|
+
}, De = {
|
|
161
|
+
class: "title"
|
|
162
|
+
}, Ee = {
|
|
163
|
+
key: 0,
|
|
164
|
+
class: "description"
|
|
165
|
+
}, Re = /* @__PURE__ */ P({
|
|
166
|
+
__name: "ContentHead",
|
|
167
|
+
props: {
|
|
168
|
+
title: {
|
|
169
|
+
type: String,
|
|
170
|
+
required: !0,
|
|
171
|
+
default: () => ""
|
|
172
|
+
},
|
|
173
|
+
description: {
|
|
174
|
+
type: String,
|
|
175
|
+
required: !0,
|
|
176
|
+
default: () => ""
|
|
177
|
+
}
|
|
178
|
+
},
|
|
179
|
+
setup(p) {
|
|
180
|
+
const t = p;
|
|
181
|
+
return (d, h) => (n(), s("div", He, [a("h1", De, M(t.title), 1), t.description ? (n(), s("p", Ee, M(t.description), 1)) : x("", !0)]));
|
|
182
|
+
}
|
|
183
|
+
}), sn = /* @__PURE__ */ C(Re, [["__scopeId", "data-v-209a7bef"]]), ze = {
|
|
184
|
+
class: "desktop-menus"
|
|
185
|
+
}, Oe = {
|
|
186
|
+
key: 0,
|
|
187
|
+
class: "header-menu-item"
|
|
188
|
+
}, We = {
|
|
189
|
+
class: "submenu-popup"
|
|
190
|
+
}, Ne = {
|
|
191
|
+
class: "submenu-content"
|
|
192
|
+
}, Ve = ["onClick"], qe = {
|
|
193
|
+
key: 0,
|
|
194
|
+
class: "submenu-item-icon"
|
|
195
|
+
}, Ge = {
|
|
196
|
+
class: "submenu-item-content"
|
|
197
|
+
}, je = {
|
|
198
|
+
class: "submenu-item-title"
|
|
199
|
+
}, Fe = {
|
|
200
|
+
key: 0,
|
|
201
|
+
class: "submenu-item-description"
|
|
202
|
+
}, Je = ["onClick"], Qe = ["aria-expanded", "aria-label"], Xe = {
|
|
203
|
+
class: "mobile-menu-content",
|
|
204
|
+
"aria-label": "主导航"
|
|
205
|
+
}, Ye = {
|
|
206
|
+
key: 0,
|
|
207
|
+
class: "mobile-menu-group"
|
|
208
|
+
}, Ze = ["aria-expanded", "onClick"], et = {
|
|
209
|
+
key: 0,
|
|
210
|
+
class: "mobile-submenu"
|
|
211
|
+
}, tt = ["onClick"], nt = ["onClick"], ot = /* @__PURE__ */ P({
|
|
212
|
+
__name: "HeaderMenus",
|
|
213
|
+
props: {
|
|
214
|
+
menus: {
|
|
215
|
+
type: Array,
|
|
216
|
+
required: !0
|
|
217
|
+
},
|
|
218
|
+
activateKey: {
|
|
219
|
+
type: String,
|
|
220
|
+
required: !0
|
|
221
|
+
},
|
|
222
|
+
theme: {
|
|
223
|
+
type: String,
|
|
224
|
+
default: "light"
|
|
225
|
+
}
|
|
226
|
+
},
|
|
227
|
+
emits: ["change"],
|
|
228
|
+
setup(p, {
|
|
229
|
+
emit: t
|
|
230
|
+
}) {
|
|
231
|
+
const d = p, h = t, i = A(!1), m = A({}), g = A(null), b = A(null);
|
|
232
|
+
let f = "";
|
|
233
|
+
function w(o) {
|
|
234
|
+
return Array.from(o.querySelectorAll('button:not([disabled]), a[href], input:not([disabled]), select:not([disabled]), textarea:not([disabled]), [tabindex]:not([tabindex="-1"])'));
|
|
235
|
+
}
|
|
236
|
+
function T() {
|
|
237
|
+
i.value || (f = document.body.style.overflow, document.body.style.overflow = "hidden", i.value = !0, J(() => {
|
|
238
|
+
var o;
|
|
239
|
+
return (o = w(b.value ?? document.body)[0]) == null ? void 0 : o.focus();
|
|
240
|
+
}));
|
|
241
|
+
}
|
|
242
|
+
function y() {
|
|
243
|
+
i.value && (i.value = !1, document.body.style.overflow = f, J(() => {
|
|
244
|
+
var o;
|
|
245
|
+
return (o = g.value) == null ? void 0 : o.focus();
|
|
246
|
+
}));
|
|
247
|
+
}
|
|
248
|
+
function e() {
|
|
249
|
+
i.value && (i.value = !1, document.body.style.overflow = f);
|
|
250
|
+
}
|
|
251
|
+
function u() {
|
|
252
|
+
i.value ? y() : T();
|
|
253
|
+
}
|
|
254
|
+
function S(o) {
|
|
255
|
+
h("change", o);
|
|
256
|
+
}
|
|
257
|
+
function I(o) {
|
|
258
|
+
h("change", o), e();
|
|
259
|
+
}
|
|
260
|
+
function H(o) {
|
|
261
|
+
m.value[o] = !m.value[o];
|
|
262
|
+
}
|
|
263
|
+
function D(o) {
|
|
264
|
+
const _ = d.activateKey, l = o.path;
|
|
265
|
+
if (_ === l || _.startsWith(l + "/"))
|
|
266
|
+
return !0;
|
|
267
|
+
if (o.children && o.children.length > 0) {
|
|
268
|
+
for (const k of o.children)
|
|
269
|
+
if (_ === k.path || _.startsWith(k.path + "/"))
|
|
270
|
+
return !0;
|
|
271
|
+
}
|
|
272
|
+
return !1;
|
|
273
|
+
}
|
|
274
|
+
function G(o) {
|
|
275
|
+
const _ = d.activateKey, l = o.path;
|
|
276
|
+
return !!(_ === l || _.startsWith(l + "/"));
|
|
277
|
+
}
|
|
278
|
+
function _e(o) {
|
|
279
|
+
h("change", o);
|
|
280
|
+
}
|
|
281
|
+
function j(o) {
|
|
282
|
+
o.key === "Escape" && i.value && y();
|
|
283
|
+
}
|
|
284
|
+
function ve(o) {
|
|
285
|
+
if (o.key !== "Tab" || !b.value) return;
|
|
286
|
+
const _ = w(b.value);
|
|
287
|
+
if (_.length === 0) return;
|
|
288
|
+
const l = _[0], k = _[_.length - 1];
|
|
289
|
+
o.shiftKey && document.activeElement === l ? (o.preventDefault(), k.focus()) : !o.shiftKey && document.activeElement === k && (o.preventDefault(), l.focus());
|
|
290
|
+
}
|
|
291
|
+
return Q(() => document.addEventListener("keydown", j)), X(() => {
|
|
292
|
+
document.removeEventListener("keydown", j), document.body.style.overflow = f;
|
|
293
|
+
}), (o, _) => (n(), s("div", {
|
|
294
|
+
class: $(["HeaderMenus", {
|
|
295
|
+
"HeaderMenus--dark": d.theme === "dark"
|
|
296
|
+
}])
|
|
297
|
+
}, [a("div", ze, [(n(!0), s(L, null, E(d.menus, (l, k) => (n(), s(L, {
|
|
298
|
+
key: k
|
|
299
|
+
}, [l.children && l.children.length > 0 ? (n(), s("div", Oe, [a("div", {
|
|
300
|
+
class: $(["headerLink hasChildren", {
|
|
301
|
+
activate: D(l)
|
|
302
|
+
}])
|
|
303
|
+
}, [K(M(l.name) + " ", 1), r(c(z), {
|
|
304
|
+
icon: "mingcute:down-line",
|
|
305
|
+
class: "dropdown-arrow"
|
|
306
|
+
})], 2), a("div", We, [a("div", Ne, [(n(!0), s(L, null, E(l.children, (v, F) => (n(), s("div", {
|
|
307
|
+
key: F,
|
|
308
|
+
class: $(["submenu-item", {
|
|
309
|
+
active: G(v)
|
|
310
|
+
}]),
|
|
311
|
+
onClick: (Tt) => S(v)
|
|
312
|
+
}, [v.icon ? (n(), s("div", qe, [r(c(z), {
|
|
313
|
+
icon: v.icon
|
|
314
|
+
}, null, 8, ["icon"])])) : x("", !0), a("div", Ge, [a("div", je, M(v.name), 1), v.description ? (n(), s("div", Fe, M(v.description), 1)) : x("", !0)])], 10, Ve))), 128))])])])) : (n(), s("div", {
|
|
315
|
+
key: 1,
|
|
316
|
+
class: $(["headerLink", {
|
|
317
|
+
activate: D(l)
|
|
318
|
+
}]),
|
|
319
|
+
onClick: (v) => _e(l)
|
|
320
|
+
}, M(l.name), 11, Je))], 64))), 128))]), a("button", {
|
|
321
|
+
ref_key: "menuToggleRef",
|
|
322
|
+
ref: g,
|
|
323
|
+
type: "button",
|
|
324
|
+
class: $(["mobile-menu-toggle", {
|
|
325
|
+
active: i.value
|
|
326
|
+
}]),
|
|
327
|
+
"aria-expanded": i.value,
|
|
328
|
+
"aria-controls": "site-mobile-menu",
|
|
329
|
+
"aria-label": i.value ? "关闭导航菜单" : "打开导航菜单",
|
|
330
|
+
onClick: u
|
|
331
|
+
}, [..._[0] || (_[0] = [a("span", {
|
|
332
|
+
class: "hamburger-line"
|
|
333
|
+
}, null, -1), a("span", {
|
|
334
|
+
class: "hamburger-line"
|
|
335
|
+
}, null, -1), a("span", {
|
|
336
|
+
class: "hamburger-line"
|
|
337
|
+
}, null, -1)])], 10, Qe), (n(), Y(ge, {
|
|
338
|
+
to: "body"
|
|
339
|
+
}, [i.value ? (n(), s("div", {
|
|
340
|
+
key: 0,
|
|
341
|
+
class: "mobile-menu-overlay",
|
|
342
|
+
"aria-hidden": "true",
|
|
343
|
+
onClick: y
|
|
344
|
+
})) : x("", !0), i.value ? (n(), s("div", {
|
|
345
|
+
key: 1,
|
|
346
|
+
id: "site-mobile-menu",
|
|
347
|
+
ref_key: "mobileMenuRef",
|
|
348
|
+
ref: b,
|
|
349
|
+
class: "mobile-menu",
|
|
350
|
+
role: "dialog",
|
|
351
|
+
"aria-label": "移动导航",
|
|
352
|
+
"aria-modal": "true",
|
|
353
|
+
onKeydown: ve
|
|
354
|
+
}, [a("nav", Xe, [(n(!0), s(L, null, E(d.menus, (l, k) => (n(), s(L, {
|
|
355
|
+
key: l.path
|
|
356
|
+
}, [l.children && l.children.length > 0 ? (n(), s("div", Ye, [a("button", {
|
|
357
|
+
type: "button",
|
|
358
|
+
class: $(["mobile-menu-item mobile-menu-item-header", {
|
|
359
|
+
activate: D(l)
|
|
360
|
+
}]),
|
|
361
|
+
"aria-expanded": m.value[k] ?? !1,
|
|
362
|
+
onClick: (v) => H(k)
|
|
363
|
+
}, [a("span", null, M(l.name), 1), r(c(z), {
|
|
364
|
+
icon: m.value[k] ? "mingcute:up-line" : "mingcute:down-line",
|
|
365
|
+
class: "mobile-submenu-arrow"
|
|
366
|
+
}, null, 8, ["icon"])], 10, Ze), m.value[k] ? (n(), s("div", et, [(n(!0), s(L, null, E(l.children, (v) => (n(), s("button", {
|
|
367
|
+
key: v.path,
|
|
368
|
+
type: "button",
|
|
369
|
+
class: $(["mobile-submenu-item", {
|
|
370
|
+
active: G(v)
|
|
371
|
+
}]),
|
|
372
|
+
onClick: (F) => I(v)
|
|
373
|
+
}, M(v.name), 11, tt))), 128))])) : x("", !0)])) : (n(), s("button", {
|
|
374
|
+
key: 1,
|
|
375
|
+
type: "button",
|
|
376
|
+
class: $(["mobile-menu-item", {
|
|
377
|
+
activate: D(l)
|
|
378
|
+
}]),
|
|
379
|
+
onClick: (v) => I(l)
|
|
380
|
+
}, M(l.name), 11, nt))], 64))), 128))])], 544)) : x("", !0)]))], 2));
|
|
381
|
+
}
|
|
382
|
+
}), st = /* @__PURE__ */ C(ot, [["__scopeId", "data-v-884ca88b"]]), at = {
|
|
383
|
+
class: "HeaderCom"
|
|
384
|
+
}, rt = {
|
|
385
|
+
class: "HeaderCom-inner"
|
|
386
|
+
}, it = {
|
|
387
|
+
class: "left"
|
|
388
|
+
}, ut = {
|
|
389
|
+
class: "right"
|
|
390
|
+
}, lt = ["aria-label"], ct = {
|
|
391
|
+
key: 0,
|
|
392
|
+
class: "theme-icon",
|
|
393
|
+
"aria-hidden": "true"
|
|
394
|
+
}, dt = {
|
|
395
|
+
key: 1,
|
|
396
|
+
class: "theme-icon",
|
|
397
|
+
"aria-hidden": "true"
|
|
398
|
+
}, mt = /* @__PURE__ */ P({
|
|
399
|
+
__name: "Header",
|
|
400
|
+
props: {
|
|
401
|
+
menuType: {
|
|
402
|
+
default: "header"
|
|
403
|
+
},
|
|
404
|
+
showUserPanel: {
|
|
405
|
+
type: Boolean,
|
|
406
|
+
default: !0
|
|
407
|
+
},
|
|
408
|
+
showThemeToggle: {
|
|
409
|
+
type: Boolean,
|
|
410
|
+
default: !0
|
|
411
|
+
},
|
|
412
|
+
theme: {
|
|
413
|
+
default: "light"
|
|
414
|
+
}
|
|
415
|
+
},
|
|
416
|
+
setup(p) {
|
|
417
|
+
const t = p, {
|
|
418
|
+
appsData: d
|
|
419
|
+
} = q(), {
|
|
420
|
+
signOut: h
|
|
421
|
+
} = ee(), {
|
|
422
|
+
menus: i
|
|
423
|
+
} = te(t.menuType), m = A(""), g = ae(), b = re();
|
|
424
|
+
function f() {
|
|
425
|
+
W(() => {
|
|
426
|
+
g.push({
|
|
427
|
+
path: "/"
|
|
428
|
+
}), window.scrollTo({
|
|
429
|
+
top: 0,
|
|
430
|
+
behavior: "smooth"
|
|
431
|
+
});
|
|
432
|
+
});
|
|
433
|
+
}
|
|
434
|
+
async function w() {
|
|
435
|
+
await h(), f();
|
|
436
|
+
}
|
|
437
|
+
function T(e) {
|
|
438
|
+
const u = e.path;
|
|
439
|
+
W(() => {
|
|
440
|
+
g.push(u), m.value = u, window.scrollTo({
|
|
441
|
+
top: 0,
|
|
442
|
+
behavior: "smooth"
|
|
443
|
+
});
|
|
444
|
+
});
|
|
445
|
+
}
|
|
446
|
+
function y() {
|
|
447
|
+
ye(t.theme === "dark" ? "light" : "dark");
|
|
448
|
+
}
|
|
449
|
+
return N(() => [b.path, i.value], () => {
|
|
450
|
+
m.value = ne(i.value, b.path, {
|
|
451
|
+
// Header 中,子菜单匹配时返回父菜单路径
|
|
452
|
+
returnParentOnChildMatch: !0,
|
|
453
|
+
// 后备查找函数
|
|
454
|
+
fallback: (e) => oe(b.matched, t.menuType, e)
|
|
455
|
+
});
|
|
456
|
+
}, {
|
|
457
|
+
immediate: !0,
|
|
458
|
+
deep: !0
|
|
459
|
+
}), (e, u) => (n(), s("header", at, [a("div", rt, [a("div", it, [r(fe, {
|
|
460
|
+
icon: c(d).applicationLogoUrl,
|
|
461
|
+
name: c(d).name,
|
|
462
|
+
onTo: f
|
|
463
|
+
}, null, 8, ["icon", "name"])]), a("div", ut, [r(st, {
|
|
464
|
+
menus: c(i),
|
|
465
|
+
activateKey: m.value,
|
|
466
|
+
theme: t.theme,
|
|
467
|
+
onChange: T
|
|
468
|
+
}, null, 8, ["menus", "activateKey", "theme"]), t.showThemeToggle ? (n(), s("button", {
|
|
469
|
+
key: 0,
|
|
470
|
+
type: "button",
|
|
471
|
+
class: "theme-toggle",
|
|
472
|
+
"aria-label": t.theme === "dark" ? "切换为浅色" : "切换为深色",
|
|
473
|
+
onClick: y
|
|
474
|
+
}, [t.theme === "dark" ? (n(), s("span", ct, [...u[0] || (u[0] = [a("svg", {
|
|
475
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
476
|
+
width: "20",
|
|
477
|
+
height: "20",
|
|
478
|
+
viewBox: "0 0 24 24",
|
|
479
|
+
fill: "none",
|
|
480
|
+
stroke: "currentColor",
|
|
481
|
+
"stroke-width": "2",
|
|
482
|
+
"stroke-linecap": "round",
|
|
483
|
+
"stroke-linejoin": "round"
|
|
484
|
+
}, [a("circle", {
|
|
485
|
+
cx: "12",
|
|
486
|
+
cy: "12",
|
|
487
|
+
r: "4"
|
|
488
|
+
}), a("path", {
|
|
489
|
+
d: "M12 2v2M12 20v2M4.93 4.93l1.41 1.41M17.66 17.66l1.41 1.41M2 12h2M20 12h2M6.34 17.66l-1.41 1.41M19.07 4.93l-1.41 1.41"
|
|
490
|
+
})], -1)])])) : (n(), s("span", dt, [...u[1] || (u[1] = [a("svg", {
|
|
491
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
492
|
+
width: "20",
|
|
493
|
+
height: "20",
|
|
494
|
+
viewBox: "0 0 24 24",
|
|
495
|
+
fill: "none",
|
|
496
|
+
stroke: "currentColor",
|
|
497
|
+
"stroke-width": "2",
|
|
498
|
+
"stroke-linecap": "round",
|
|
499
|
+
"stroke-linejoin": "round"
|
|
500
|
+
}, [a("path", {
|
|
501
|
+
d: "M21 12.79A9 9 0 1 1 11.21 3 7 7 0 0 0 21 12.79z"
|
|
502
|
+
})], -1)])]))], 8, lt)) : x("", !0), t.showUserPanel ? (n(), Y(ie, {
|
|
503
|
+
key: 1
|
|
504
|
+
}, {
|
|
505
|
+
items: B(() => [r(ue), r(le), r(ce), r(de), r(me), r(pe), r(R, {
|
|
506
|
+
icon: "lucide:home",
|
|
507
|
+
onClick: f
|
|
508
|
+
}, {
|
|
509
|
+
default: B(() => [...u[2] || (u[2] = [K("主页", -1)])]),
|
|
510
|
+
_: 1
|
|
511
|
+
}), r(R, {
|
|
512
|
+
icon: "lucide:log-out",
|
|
513
|
+
danger: "",
|
|
514
|
+
onClick: w
|
|
515
|
+
}, {
|
|
516
|
+
default: B(() => [...u[3] || (u[3] = [K("退出登陆", -1)])]),
|
|
517
|
+
_: 1
|
|
518
|
+
})]),
|
|
519
|
+
_: 1
|
|
520
|
+
})) : x("", !0), r(he)])])]));
|
|
521
|
+
}
|
|
522
|
+
}), pt = /* @__PURE__ */ C(mt, [["__scopeId", "data-v-e85929a0"]]), ht = {
|
|
523
|
+
class: "layout-inner"
|
|
524
|
+
}, ft = {
|
|
525
|
+
key: 0,
|
|
526
|
+
class: "loading"
|
|
527
|
+
}, _t = "none", vt = "var(--huyooo-layout-dark-background)", gt = /* @__PURE__ */ P({
|
|
528
|
+
__name: "DefaultLayout",
|
|
529
|
+
props: {
|
|
530
|
+
menuType: {
|
|
531
|
+
default: "header"
|
|
532
|
+
},
|
|
533
|
+
showUserPanel: {
|
|
534
|
+
type: Boolean,
|
|
535
|
+
default: !0
|
|
536
|
+
},
|
|
537
|
+
showThemeToggle: {
|
|
538
|
+
type: Boolean,
|
|
539
|
+
default: !0
|
|
540
|
+
},
|
|
541
|
+
enableRoutePermission: {
|
|
542
|
+
type: Boolean,
|
|
543
|
+
default: !0
|
|
544
|
+
},
|
|
545
|
+
backgroundImage: {
|
|
546
|
+
default: ""
|
|
547
|
+
},
|
|
548
|
+
theme: {
|
|
549
|
+
default: void 0
|
|
550
|
+
}
|
|
551
|
+
},
|
|
552
|
+
setup(p) {
|
|
553
|
+
var T, y;
|
|
554
|
+
const t = p, {
|
|
555
|
+
appsData: d
|
|
556
|
+
} = q(), h = A(typeof window < "u" && ((y = (T = window.matchMedia) == null ? void 0 : T.call(window, "(prefers-color-scheme: dark)")) == null ? void 0 : y.matches));
|
|
557
|
+
function i() {
|
|
558
|
+
var e, u;
|
|
559
|
+
typeof window > "u" || (h.value = ((u = (e = window.matchMedia) == null ? void 0 : e.call(window, "(prefers-color-scheme: dark)")) == null ? void 0 : u.matches) ?? !1);
|
|
560
|
+
}
|
|
561
|
+
let m;
|
|
562
|
+
Q(() => {
|
|
563
|
+
var u, S;
|
|
564
|
+
i();
|
|
565
|
+
const e = (u = window.matchMedia) == null ? void 0 : u.call(window, "(prefers-color-scheme: dark)");
|
|
566
|
+
(S = e == null ? void 0 : e.addEventListener) == null || S.call(e, "change", i), m = () => {
|
|
567
|
+
var I;
|
|
568
|
+
return (I = e == null ? void 0 : e.removeEventListener) == null ? void 0 : I.call(e, "change", i);
|
|
569
|
+
};
|
|
570
|
+
});
|
|
571
|
+
const g = U(() => {
|
|
572
|
+
var I, H;
|
|
573
|
+
const e = t.theme;
|
|
574
|
+
if (e && e !== "system") return e;
|
|
575
|
+
if (e === "system") return h.value ? "dark" : "light";
|
|
576
|
+
const u = be.value;
|
|
577
|
+
if (u === "dark" || u === "light") return u;
|
|
578
|
+
if (u === "system") return h.value ? "dark" : "light";
|
|
579
|
+
const S = (H = (I = d.value) == null ? void 0 : I.brand) == null ? void 0 : H.theme;
|
|
580
|
+
return S === "dark" || S === "light" ? S : "light";
|
|
581
|
+
}), b = U(() => t.backgroundImage ? t.backgroundImage : g.value === "dark" ? vt : _t), f = U(() => {
|
|
582
|
+
const e = b.value;
|
|
583
|
+
return !e || e === "none" ? {
|
|
584
|
+
backgroundImage: "none",
|
|
585
|
+
backgroundColor: "transparent"
|
|
586
|
+
} : {
|
|
587
|
+
backgroundImage: e,
|
|
588
|
+
backgroundAttachment: "fixed"
|
|
589
|
+
};
|
|
590
|
+
});
|
|
591
|
+
N(g, (e) => {
|
|
592
|
+
typeof document > "u" || (e === "dark" ? (document.body.setAttribute("arco-theme", "dark"), document.body.classList.add("dark")) : (document.body.removeAttribute("arco-theme"), document.body.classList.remove("dark")));
|
|
593
|
+
}, {
|
|
594
|
+
immediate: !0
|
|
595
|
+
}), X(() => {
|
|
596
|
+
m == null || m();
|
|
597
|
+
});
|
|
598
|
+
const w = t.enableRoutePermission ? se().isChecking : A(!1);
|
|
599
|
+
return (e, u) => (n(), s("div", {
|
|
600
|
+
class: $(["layout", {
|
|
601
|
+
"layout--dark": g.value === "dark"
|
|
602
|
+
}]),
|
|
603
|
+
style: O(f.value)
|
|
604
|
+
}, [r(pt, {
|
|
605
|
+
"menu-type": t.menuType,
|
|
606
|
+
"show-user-panel": t.showUserPanel,
|
|
607
|
+
"show-theme-toggle": t.showThemeToggle,
|
|
608
|
+
theme: g.value
|
|
609
|
+
}, null, 8, ["menu-type", "show-user-panel", "show-theme-toggle", "theme"]), a("main", ht, [c(w) ? (n(), s("div", ft, [r(c(Z), {
|
|
610
|
+
size: 40
|
|
611
|
+
})])) : V(e.$slots, "default", {
|
|
612
|
+
key: 1
|
|
613
|
+
}, void 0, !0)])], 6));
|
|
614
|
+
}
|
|
615
|
+
}), an = /* @__PURE__ */ C(gt, [["__scopeId", "data-v-6bfe720c"]]), yt = /* @__PURE__ */ P({
|
|
616
|
+
__name: "Gradientbackground",
|
|
617
|
+
props: {
|
|
618
|
+
width: {
|
|
619
|
+
type: String,
|
|
620
|
+
default: "100%"
|
|
621
|
+
},
|
|
622
|
+
height: {
|
|
623
|
+
type: String,
|
|
624
|
+
default: "100%"
|
|
625
|
+
},
|
|
626
|
+
zIndex: {
|
|
627
|
+
type: String,
|
|
628
|
+
default: "-1"
|
|
629
|
+
},
|
|
630
|
+
top: {
|
|
631
|
+
type: String,
|
|
632
|
+
default: "10%"
|
|
633
|
+
},
|
|
634
|
+
left: {
|
|
635
|
+
type: String,
|
|
636
|
+
default: "0%"
|
|
637
|
+
},
|
|
638
|
+
right: {
|
|
639
|
+
type: String,
|
|
640
|
+
default: "auto"
|
|
641
|
+
},
|
|
642
|
+
blur: {
|
|
643
|
+
type: String,
|
|
644
|
+
default: "0px"
|
|
645
|
+
},
|
|
646
|
+
background: {
|
|
647
|
+
type: String,
|
|
648
|
+
required: !1,
|
|
649
|
+
default: () => "var(--huyooo-gradient-background)"
|
|
650
|
+
}
|
|
651
|
+
},
|
|
652
|
+
setup(p) {
|
|
653
|
+
const t = p, d = U(() => ({
|
|
654
|
+
pointerEvents: "none",
|
|
655
|
+
position: "absolute",
|
|
656
|
+
zIndex: t.zIndex,
|
|
657
|
+
width: t.width,
|
|
658
|
+
height: t.height,
|
|
659
|
+
filter: `blur(${t.blur})`
|
|
660
|
+
})), h = U(() => ({
|
|
661
|
+
width: "100%",
|
|
662
|
+
height: "100%",
|
|
663
|
+
background: t.background
|
|
664
|
+
}));
|
|
665
|
+
return (i, m) => (n(), s("div", {
|
|
666
|
+
class: "ellipsis",
|
|
667
|
+
style: O(d.value)
|
|
668
|
+
}, [a("div", {
|
|
669
|
+
class: "ellipsis-item",
|
|
670
|
+
style: O(h.value)
|
|
671
|
+
}, null, 4)], 4));
|
|
672
|
+
}
|
|
673
|
+
}), rn = /* @__PURE__ */ C(yt, [["__scopeId", "data-v-64c41f65"]]), bt = {
|
|
674
|
+
class: "SvgIcon"
|
|
675
|
+
}, kt = ["href", "fill"], wt = /* @__PURE__ */ P({
|
|
676
|
+
__name: "SvgIcon",
|
|
677
|
+
props: {
|
|
678
|
+
prefix: {
|
|
679
|
+
type: String,
|
|
680
|
+
required: !1,
|
|
681
|
+
default: "icon"
|
|
682
|
+
},
|
|
683
|
+
name: {
|
|
684
|
+
type: String,
|
|
685
|
+
required: !0
|
|
686
|
+
},
|
|
687
|
+
color: {
|
|
688
|
+
type: String,
|
|
689
|
+
required: !1,
|
|
690
|
+
default: "currentColor"
|
|
691
|
+
}
|
|
692
|
+
},
|
|
693
|
+
setup(p) {
|
|
694
|
+
const t = p, d = U(() => `#${t.prefix ?? "icon"}-${t.name}`);
|
|
695
|
+
return (h, i) => (n(), s("svg", bt, [a("use", {
|
|
696
|
+
href: d.value,
|
|
697
|
+
fill: t.color
|
|
698
|
+
}, null, 8, kt)]));
|
|
699
|
+
}
|
|
700
|
+
}), un = /* @__PURE__ */ C(wt, [["__scopeId", "data-v-9d0b08a0"]]), $t = {}, Mt = {
|
|
701
|
+
class: "WidthContainer"
|
|
702
|
+
};
|
|
703
|
+
function Ct(p, t) {
|
|
704
|
+
return n(), s("div", Mt, [V(p.$slots, "default", {}, void 0, !0)]);
|
|
705
|
+
}
|
|
706
|
+
const ln = /* @__PURE__ */ C($t, [["render", Ct], ["__scopeId", "data-v-d06aac1f"]]);
|
|
707
|
+
export {
|
|
708
|
+
on as A,
|
|
709
|
+
sn as C,
|
|
710
|
+
an as D,
|
|
711
|
+
rn as G,
|
|
712
|
+
pt as H,
|
|
713
|
+
un as S,
|
|
714
|
+
ln as W,
|
|
715
|
+
Ie as a,
|
|
716
|
+
st as b
|
|
717
|
+
};
|