@huyooo/ui 2.1.4 → 2.1.8
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-BJWwY3T-.js → AuthkitAppSetting-CHVSyEY1.js} +1 -1
- package/dist/{FeedbackModal.vue_vue_type_script_setup_true_lang-BJj1bNKu.js → FeedbackModal.vue_vue_type_script_setup_true_lang-FIZdBxIZ.js} +1 -1
- package/dist/{LegalDocViewer-DCDSLVjc.js → LegalDocViewer-DiNoy_oj.js} +2 -2
- package/dist/PaySubscriptions-pEZtjp1g.js +1287 -0
- package/dist/{PricingPlans-CXk2DNb4.js → PricingPlans-qRWHwi9x.js} +2 -2
- package/dist/{ReferrerReferees-ZhroFXBA.js → ReferrerReferees-t5s4LzbY.js} +1 -1
- package/dist/UserMenuInvitationsItem.vue_vue_type_script_setup_true_lang-DbkGYZ2f.js +601 -0
- package/dist/{WidthContainer-CDf1GiFk.js → WidthContainer-FXZqDMid.js} +4 -4
- package/dist/authkit.js +3 -3
- package/dist/common.js +1 -1
- package/dist/components/Authkit/AuthkitAppSetting.vue.d.ts +2 -2
- package/dist/components/Feedback/FeedbackModal.vue.d.ts +2 -2
- package/dist/components/LandingPage/LandingPageSections.vue.d.ts +1 -1
- package/dist/components/Message/MessageTabs.vue.d.ts +2 -2
- package/dist/components/Pay/PaySubscriptions.vue.d.ts +2 -2
- package/dist/components/UserMenu/UserMenuModals.vue.d.ts +9 -9
- package/dist/composables/Billing/useBillingPlans.d.ts +10 -2
- package/dist/composables/Billing/useBillingSubscriptionSummary.d.ts +77 -258
- package/dist/composables.js +3 -3
- package/dist/feedback.js +1 -1
- package/dist/main.js +103 -102
- package/dist/pay.d.ts +1 -1
- package/dist/pay.js +18 -17
- package/dist/referrer.js +1 -1
- package/dist/style.css +1 -1
- package/dist/types/api/billing.generated.d.ts +2 -2
- package/dist/types/subscription.d.ts +57 -0
- package/dist/types/user.d.ts +3 -0
- package/dist/useAuthkitUsersProfile-D4H_Gxgd.js +67 -0
- package/dist/useBillingSubscriptionSummary-BC3G0N4t.js +43 -0
- package/dist/{useRoutePermission-ZOeRg6Wq.js → useRoutePermission-CGq_LIZM.js} +1 -1
- package/dist/useSubscriptionCheckout-Dmg0kt4F.js +399 -0
- package/dist/user.js +1 -1
- package/dist/utils/subscriptionDisplay.d.ts +6 -6
- package/package.json +1 -1
- package/dist/PaySubscriptions-CXLqpfgf.js +0 -1331
- package/dist/UserMenuInvitationsItem.vue_vue_type_script_setup_true_lang-COM36ViG.js +0 -598
- package/dist/useAuthkitUsersProfile-DX2PYmdU.js +0 -59
- package/dist/useSubscriptionCheckout-DAwwBVAk.js +0 -353
|
@@ -5,11 +5,11 @@ import { g as ve } from "./apiClients-CWSwNzGk.js";
|
|
|
5
5
|
import { defineComponent as K, computed as h, onMounted as ne, onUnmounted as pe, openBlock as n, createElementBlock as s, createElementVNode as i, unref as e, createBlock as O, toDisplayString as a, createVNode as k, withCtx as w, createTextVNode as R, ref as ye, resolveDirective as he, withDirectives as ke, normalizeClass as L, Fragment as I, renderList as C, createCommentVNode as y } from "vue";
|
|
6
6
|
import { Spin as se, Button as A, Message as F } from "@arco-design/web-vue";
|
|
7
7
|
import { useRoute as be, useRouter as Te } from "vue-router";
|
|
8
|
-
import {
|
|
8
|
+
import { a as we } from "./PaySubscriptions-pEZtjp1g.js";
|
|
9
9
|
import { _ as U } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
10
10
|
import { L as Ie, a as Ce, b as Be } from "./LandingPageSectionHeader-3hiuw6G0.js";
|
|
11
11
|
import { Icon as te } from "@iconify/vue";
|
|
12
|
-
import { u as Le, a as Re } from "./useSubscriptionCheckout-
|
|
12
|
+
import { u as Le, a as Re } from "./useSubscriptionCheckout-Dmg0kt4F.js";
|
|
13
13
|
import { u as Ae } from "./useEnsureAuthenticated-RZ1DflLz.js";
|
|
14
14
|
const kt = "/Pay/Return";
|
|
15
15
|
function G(l) {
|
|
@@ -8,7 +8,7 @@ import { C as P } from "./CustomTable-BY0oHLXc.js";
|
|
|
8
8
|
import { C as G } from "./index-BYH7DaQf.js";
|
|
9
9
|
/* empty css */
|
|
10
10
|
import { _ as D } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
11
|
-
import { u as H } from "./useAuthkitUsersProfile-
|
|
11
|
+
import { u as H } from "./useAuthkitUsersProfile-D4H_Gxgd.js";
|
|
12
12
|
const j = {
|
|
13
13
|
email: "邮箱",
|
|
14
14
|
phone: "手机",
|
|
@@ -0,0 +1,601 @@
|
|
|
1
|
+
/* empty css */
|
|
2
|
+
/* empty css */
|
|
3
|
+
import "./index-BYH7DaQf.js";
|
|
4
|
+
import { defineComponent as m, computed as b, openBlock as r, createElementBlock as p, toDisplayString as M, createCommentVNode as U, createVNode as _, unref as n, createBlock as v, withCtx as g, createTextVNode as k, ref as x, createElementVNode as d, watch as A, onMounted as ee, Fragment as Y, normalizeClass as q, renderSlot as w } from "vue";
|
|
5
|
+
import { Avatar as G, Button as N, Dropdown as te, Badge as ne } from "@arco-design/web-vue";
|
|
6
|
+
import { u as R } from "./useAuthkitUsersProfile-D4H_Gxgd.js";
|
|
7
|
+
import { u as y } from "./useUserMenu-ClPBlvaM.js";
|
|
8
|
+
/* empty css */
|
|
9
|
+
import { g as J, a as se, R as ae } from "./ReferrerReferees-t5s4LzbY.js";
|
|
10
|
+
import { _ as S } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
11
|
+
/* empty css */
|
|
12
|
+
import { u as oe } from "./apiClients-CWSwNzGk.js";
|
|
13
|
+
import { useBillingSubscriptionSummary as ie } from "./useBillingSubscriptionSummary-BC3G0N4t.js";
|
|
14
|
+
import { d as re } from "./useBillingStatusOptions-C6edto7H.js";
|
|
15
|
+
import { f as ue, g as le, b as ce, s as de, P as pe } from "./PaySubscriptions-pEZtjp1g.js";
|
|
16
|
+
import { A as me } from "./AuthkitAppSetting-CHVSyEY1.js";
|
|
17
|
+
import { c as fe, u as K } from "./FeedbackModal.vue_vue_type_script_setup_true_lang-FIZdBxIZ.js";
|
|
18
|
+
import { M as _e } from "./MessageHandle-DDGFSJMg.js";
|
|
19
|
+
import "./Menu-uCexrsKP.js";
|
|
20
|
+
import { Icon as ve } from "@iconify/vue";
|
|
21
|
+
const ge = {
|
|
22
|
+
class: "UserAvatar"
|
|
23
|
+
}, be = ["title"], Ue = /* @__PURE__ */ m({
|
|
24
|
+
__name: "UserAvatar",
|
|
25
|
+
props: {
|
|
26
|
+
userId: {
|
|
27
|
+
default: ""
|
|
28
|
+
},
|
|
29
|
+
nickname: {
|
|
30
|
+
default: ""
|
|
31
|
+
},
|
|
32
|
+
email: {
|
|
33
|
+
default: ""
|
|
34
|
+
},
|
|
35
|
+
phone: {
|
|
36
|
+
default: ""
|
|
37
|
+
},
|
|
38
|
+
avatar: {
|
|
39
|
+
default: ""
|
|
40
|
+
}
|
|
41
|
+
},
|
|
42
|
+
setup(t) {
|
|
43
|
+
const e = t, o = b(() => J({
|
|
44
|
+
userId: e.userId,
|
|
45
|
+
nickname: e.nickname,
|
|
46
|
+
email: e.email,
|
|
47
|
+
phone: e.phone
|
|
48
|
+
}));
|
|
49
|
+
return (s, i) => (r(), p("div", ge, [o.value ? (r(), p("span", {
|
|
50
|
+
key: 0,
|
|
51
|
+
class: "UserAvatar__nickname",
|
|
52
|
+
title: o.value
|
|
53
|
+
}, M(o.value), 9, be)) : U("", !0), _(n(G), {
|
|
54
|
+
"image-url": t.avatar,
|
|
55
|
+
size: 32,
|
|
56
|
+
"object-fit": "cover"
|
|
57
|
+
}, null, 8, ["image-url"])]));
|
|
58
|
+
}
|
|
59
|
+
}), ke = /* @__PURE__ */ S(Ue, [["__scopeId", "data-v-949e953e"]]), ye = /* @__PURE__ */ m({
|
|
60
|
+
__name: "UserSignInButton",
|
|
61
|
+
setup(t) {
|
|
62
|
+
const {
|
|
63
|
+
open: e
|
|
64
|
+
} = oe();
|
|
65
|
+
return (o, s) => (r(), v(n(N), {
|
|
66
|
+
type: "primary",
|
|
67
|
+
class: "UserSignInButton",
|
|
68
|
+
onClick: s[0] || (s[0] = (i) => n(e)())
|
|
69
|
+
}, {
|
|
70
|
+
default: g(() => [...s[1] || (s[1] = [k("登录", -1)])]),
|
|
71
|
+
_: 1
|
|
72
|
+
}));
|
|
73
|
+
}
|
|
74
|
+
}), Ie = /* @__PURE__ */ S(ye, [["__scopeId", "data-v-85695587"]]), he = {}, Se = {
|
|
75
|
+
class: "UserMenuDivider",
|
|
76
|
+
role: "separator"
|
|
77
|
+
};
|
|
78
|
+
function Be(t, e) {
|
|
79
|
+
return r(), p("div", Se);
|
|
80
|
+
}
|
|
81
|
+
const $e = /* @__PURE__ */ S(he, [["render", Be], ["__scopeId", "data-v-c7d18d97"]]), X = x(0);
|
|
82
|
+
let P = null;
|
|
83
|
+
function Me() {
|
|
84
|
+
async function t() {
|
|
85
|
+
return P || (P = (async () => {
|
|
86
|
+
const {
|
|
87
|
+
data: e,
|
|
88
|
+
error: o
|
|
89
|
+
} = await re.productOptions();
|
|
90
|
+
o || !Array.isArray(e) || (X.value = e.filter((s) => {
|
|
91
|
+
var i;
|
|
92
|
+
return (i = s.prices) == null ? void 0 : i.some((c) => c.type === "recurring");
|
|
93
|
+
}).length);
|
|
94
|
+
})().finally(() => {
|
|
95
|
+
P = null;
|
|
96
|
+
}), P);
|
|
97
|
+
}
|
|
98
|
+
return {
|
|
99
|
+
paidProductCount: X,
|
|
100
|
+
loadPaidProductCount: t
|
|
101
|
+
};
|
|
102
|
+
}
|
|
103
|
+
const Ce = {
|
|
104
|
+
class: "UserBasicInformation"
|
|
105
|
+
}, xe = {
|
|
106
|
+
class: "UserBasicInformation__extra"
|
|
107
|
+
}, Ae = ["title"], we = ["title"], Pe = /* @__PURE__ */ m({
|
|
108
|
+
__name: "UserBasicInformation",
|
|
109
|
+
props: {
|
|
110
|
+
userId: {
|
|
111
|
+
default: ""
|
|
112
|
+
},
|
|
113
|
+
nickname: {
|
|
114
|
+
default: ""
|
|
115
|
+
},
|
|
116
|
+
email: {
|
|
117
|
+
default: ""
|
|
118
|
+
},
|
|
119
|
+
phone: {
|
|
120
|
+
default: ""
|
|
121
|
+
},
|
|
122
|
+
avatarUrl: {
|
|
123
|
+
default: ""
|
|
124
|
+
},
|
|
125
|
+
avatarSize: {
|
|
126
|
+
default: 32
|
|
127
|
+
}
|
|
128
|
+
},
|
|
129
|
+
setup(t) {
|
|
130
|
+
const e = t, o = b(() => ({
|
|
131
|
+
userId: e.userId,
|
|
132
|
+
nickname: e.nickname,
|
|
133
|
+
email: e.email,
|
|
134
|
+
phone: e.phone
|
|
135
|
+
})), s = b(() => J(o.value)), i = b(() => se(o.value));
|
|
136
|
+
return (c, a) => (r(), p("div", Ce, [_(n(G), {
|
|
137
|
+
"image-url": t.avatarUrl,
|
|
138
|
+
size: t.avatarSize,
|
|
139
|
+
"object-fit": "cover"
|
|
140
|
+
}, null, 8, ["image-url", "size"]), d("div", xe, [d("span", {
|
|
141
|
+
class: "UserBasicInformation__nickname",
|
|
142
|
+
title: s.value
|
|
143
|
+
}, M(s.value), 9, Ae), i.value ? (r(), p("span", {
|
|
144
|
+
key: 0,
|
|
145
|
+
class: "UserBasicInformation__contact",
|
|
146
|
+
title: i.value
|
|
147
|
+
}, M(i.value), 9, we)) : U("", !0)])]));
|
|
148
|
+
}
|
|
149
|
+
}), Q = /* @__PURE__ */ S(Pe, [["__scopeId", "data-v-cb95c00d"]]), De = {
|
|
150
|
+
class: "UserSubscriptionBaseInformation"
|
|
151
|
+
}, Ne = {
|
|
152
|
+
class: "UserSubscriptionBaseInformation__row"
|
|
153
|
+
}, Re = {
|
|
154
|
+
class: "UserSubscriptionBaseInformation__info"
|
|
155
|
+
}, He = ["title"], Oe = {
|
|
156
|
+
key: 0,
|
|
157
|
+
class: "UserSubscriptionBaseInformation__info"
|
|
158
|
+
}, Ve = ["title"], ze = {
|
|
159
|
+
class: "UserSubscriptionBaseInformation__row"
|
|
160
|
+
}, Te = {
|
|
161
|
+
class: "UserSubscriptionBaseInformation__info"
|
|
162
|
+
}, Le = {
|
|
163
|
+
class: "UserSubscriptionBaseInformation__value"
|
|
164
|
+
}, Ee = {
|
|
165
|
+
key: 1,
|
|
166
|
+
class: "UserSubscriptionBaseInformation__row"
|
|
167
|
+
}, je = /* @__PURE__ */ m({
|
|
168
|
+
__name: "UserSubscriptionBaseInformation",
|
|
169
|
+
props: {
|
|
170
|
+
currentVersionName: {
|
|
171
|
+
default: ""
|
|
172
|
+
},
|
|
173
|
+
expireDate: {
|
|
174
|
+
default: ""
|
|
175
|
+
},
|
|
176
|
+
pointsBalance: {},
|
|
177
|
+
pendingInvoiceTotal: {},
|
|
178
|
+
loading: {
|
|
179
|
+
type: Boolean,
|
|
180
|
+
default: !1
|
|
181
|
+
},
|
|
182
|
+
canUpgrade: {
|
|
183
|
+
type: Boolean,
|
|
184
|
+
default: !1
|
|
185
|
+
},
|
|
186
|
+
actionLabel: {
|
|
187
|
+
default: "升级"
|
|
188
|
+
}
|
|
189
|
+
},
|
|
190
|
+
emits: ["upgradeHandle", "payHandle", "pointsHandle"],
|
|
191
|
+
setup(t, {
|
|
192
|
+
emit: e
|
|
193
|
+
}) {
|
|
194
|
+
const o = t, s = e, i = b(() => ue(o.pointsBalance));
|
|
195
|
+
return (c, a) => (r(), p("div", De, [d("div", Ne, [d("div", Re, [a[3] || (a[3] = d("span", {
|
|
196
|
+
class: "UserSubscriptionBaseInformation__label"
|
|
197
|
+
}, "当前权益:", -1)), d("span", {
|
|
198
|
+
class: "UserSubscriptionBaseInformation__value",
|
|
199
|
+
title: t.currentVersionName
|
|
200
|
+
}, M(t.currentVersionName), 9, He)]), t.canUpgrade ? (r(), v(n(N), {
|
|
201
|
+
key: 0,
|
|
202
|
+
type: "primary",
|
|
203
|
+
size: "mini",
|
|
204
|
+
class: "UserSubscriptionBaseInformation__action",
|
|
205
|
+
loading: t.loading,
|
|
206
|
+
onClick: a[0] || (a[0] = (u) => s("upgradeHandle"))
|
|
207
|
+
}, {
|
|
208
|
+
default: g(() => [k(M(t.actionLabel), 1)]),
|
|
209
|
+
_: 1
|
|
210
|
+
}, 8, ["loading"])) : U("", !0)]), t.expireDate ? (r(), p("div", Oe, [a[4] || (a[4] = d("span", {
|
|
211
|
+
class: "UserSubscriptionBaseInformation__label"
|
|
212
|
+
}, "有效期至:", -1)), d("span", {
|
|
213
|
+
class: "UserSubscriptionBaseInformation__value",
|
|
214
|
+
title: t.expireDate
|
|
215
|
+
}, M(t.expireDate), 9, Ve)])) : U("", !0), d("div", ze, [d("div", Te, [a[5] || (a[5] = d("span", {
|
|
216
|
+
class: "UserSubscriptionBaseInformation__label"
|
|
217
|
+
}, "积分余额:", -1)), d("span", Le, M(i.value), 1)]), _(n(N), {
|
|
218
|
+
type: "primary",
|
|
219
|
+
size: "mini",
|
|
220
|
+
class: "UserSubscriptionBaseInformation__action",
|
|
221
|
+
loading: t.loading,
|
|
222
|
+
onClick: a[1] || (a[1] = (u) => s("pointsHandle"))
|
|
223
|
+
}, {
|
|
224
|
+
default: g(() => [...a[6] || (a[6] = [k(" 充值 ", -1)])]),
|
|
225
|
+
_: 1
|
|
226
|
+
}, 8, ["loading"])]), typeof t.pendingInvoiceTotal == "number" && t.pendingInvoiceTotal > 0 ? (r(), p("div", Ee, [a[8] || (a[8] = d("span", {
|
|
227
|
+
class: "UserSubscriptionBaseInformation__warning"
|
|
228
|
+
}, "有待支付订阅账单", -1)), _(n(N), {
|
|
229
|
+
type: "primary",
|
|
230
|
+
status: "warning",
|
|
231
|
+
size: "mini",
|
|
232
|
+
class: "UserSubscriptionBaseInformation__action",
|
|
233
|
+
loading: t.loading,
|
|
234
|
+
onClick: a[2] || (a[2] = (u) => s("payHandle"))
|
|
235
|
+
}, {
|
|
236
|
+
default: g(() => [...a[7] || (a[7] = [k(" 去支付 ", -1)])]),
|
|
237
|
+
_: 1
|
|
238
|
+
}, 8, ["loading"])])) : U("", !0)]));
|
|
239
|
+
}
|
|
240
|
+
}), Fe = /* @__PURE__ */ S(je, [["__scopeId", "data-v-7938abb7"]]), Xe = /* @__PURE__ */ m({
|
|
241
|
+
__name: "UserMenuHeader",
|
|
242
|
+
props: {
|
|
243
|
+
showSubscription: {
|
|
244
|
+
type: Boolean,
|
|
245
|
+
default: !0
|
|
246
|
+
},
|
|
247
|
+
currentVersionName: {
|
|
248
|
+
default: ""
|
|
249
|
+
},
|
|
250
|
+
expireDate: {
|
|
251
|
+
default: ""
|
|
252
|
+
},
|
|
253
|
+
canUpgrade: {
|
|
254
|
+
type: Boolean,
|
|
255
|
+
default: !0
|
|
256
|
+
}
|
|
257
|
+
},
|
|
258
|
+
setup(t) {
|
|
259
|
+
const e = t, {
|
|
260
|
+
userProfile: o
|
|
261
|
+
} = R(), {
|
|
262
|
+
isOpen: s,
|
|
263
|
+
openSubscriptions: i
|
|
264
|
+
} = y(), {
|
|
265
|
+
entitlement: c,
|
|
266
|
+
product: a,
|
|
267
|
+
pointsBalance: u,
|
|
268
|
+
loading: f,
|
|
269
|
+
refresh: B
|
|
270
|
+
} = ie(), {
|
|
271
|
+
paidProductCount: I,
|
|
272
|
+
loadPaidProductCount: $
|
|
273
|
+
} = Me(), l = b(() => {
|
|
274
|
+
var h;
|
|
275
|
+
return e.currentVersionName ? e.currentVersionName : le(c.value, (h = a.value) == null ? void 0 : h.name);
|
|
276
|
+
}), H = b(() => {
|
|
277
|
+
var h;
|
|
278
|
+
return e.expireDate || ((h = c.value) == null ? void 0 : h.endAt) || "";
|
|
279
|
+
}), W = b(() => ce(c.value, I.value)), Z = b(() => de(c.value, I.value, e.canUpgrade));
|
|
280
|
+
function O() {
|
|
281
|
+
e.showSubscription && (B(), $());
|
|
282
|
+
}
|
|
283
|
+
return A(s, (h) => {
|
|
284
|
+
h && O();
|
|
285
|
+
}), ee(() => {
|
|
286
|
+
s.value && O();
|
|
287
|
+
}), (h, C) => {
|
|
288
|
+
var V, z, T, L, E, j;
|
|
289
|
+
return r(), p(Y, null, [_(Q, {
|
|
290
|
+
"user-id": (V = n(o)) == null ? void 0 : V.id,
|
|
291
|
+
"avatar-url": (z = n(o)) == null ? void 0 : z.avatarUrl,
|
|
292
|
+
nickname: (T = n(o)) == null ? void 0 : T.nickname,
|
|
293
|
+
email: (L = n(o)) == null ? void 0 : L.email,
|
|
294
|
+
phone: (E = n(o)) == null ? void 0 : E.phone
|
|
295
|
+
}, null, 8, ["user-id", "avatar-url", "nickname", "email", "phone"]), t.showSubscription ? (r(), v(Fe, {
|
|
296
|
+
key: 0,
|
|
297
|
+
"current-version-name": l.value,
|
|
298
|
+
"expire-date": H.value,
|
|
299
|
+
"points-balance": ((j = n(u)) == null ? void 0 : j.totalPoints) ?? 0,
|
|
300
|
+
loading: n(f),
|
|
301
|
+
"can-upgrade": Z.value,
|
|
302
|
+
"action-label": W.value,
|
|
303
|
+
onUpgradeHandle: C[0] || (C[0] = (F) => n(i)()),
|
|
304
|
+
onPayHandle: C[1] || (C[1] = (F) => n(i)({
|
|
305
|
+
target: "invoices"
|
|
306
|
+
})),
|
|
307
|
+
onPointsHandle: C[2] || (C[2] = (F) => n(i)({
|
|
308
|
+
target: "points"
|
|
309
|
+
}))
|
|
310
|
+
}, null, 8, ["current-version-name", "expire-date", "points-balance", "loading", "can-upgrade", "action-label"])) : U("", !0)], 64);
|
|
311
|
+
};
|
|
312
|
+
}
|
|
313
|
+
}), Ye = {
|
|
314
|
+
key: 0,
|
|
315
|
+
"aria-hidden": "true"
|
|
316
|
+
}, qe = {
|
|
317
|
+
class: "UserMenu__content"
|
|
318
|
+
}, Ge = {
|
|
319
|
+
class: "UserMenu__header"
|
|
320
|
+
}, Je = /* @__PURE__ */ m({
|
|
321
|
+
__name: "UserMenu",
|
|
322
|
+
props: {
|
|
323
|
+
position: {
|
|
324
|
+
default: "br"
|
|
325
|
+
},
|
|
326
|
+
dropdownOffsetX: {
|
|
327
|
+
default: "0"
|
|
328
|
+
},
|
|
329
|
+
dropdownOffsetY: {
|
|
330
|
+
default: "0"
|
|
331
|
+
}
|
|
332
|
+
},
|
|
333
|
+
setup(t) {
|
|
334
|
+
const {
|
|
335
|
+
userProfile: e,
|
|
336
|
+
authSessionState: o
|
|
337
|
+
} = R(), {
|
|
338
|
+
isOpen: s,
|
|
339
|
+
setOpen: i
|
|
340
|
+
} = y(), c = b({
|
|
341
|
+
get: () => s.value,
|
|
342
|
+
set: (a) => i(a)
|
|
343
|
+
});
|
|
344
|
+
return (a, u) => (r(), p("div", {
|
|
345
|
+
class: q(["UserMenu-auth-chrome", {
|
|
346
|
+
"UserMenu-auth-chrome--custom-trigger": a.$slots.trigger
|
|
347
|
+
}])
|
|
348
|
+
}, [n(o) === "pending" ? (r(), p("span", Ye)) : n(o) === "unauthenticated" ? (r(), v(Ie, {
|
|
349
|
+
key: 1
|
|
350
|
+
})) : (r(), v(n(te), {
|
|
351
|
+
key: 2,
|
|
352
|
+
"popup-visible": c.value,
|
|
353
|
+
"onUpdate:popupVisible": u[0] || (u[0] = (f) => c.value = f),
|
|
354
|
+
class: "UserMenu",
|
|
355
|
+
position: t.position,
|
|
356
|
+
"popup-max-height": !1,
|
|
357
|
+
"popup-style": {
|
|
358
|
+
"--user-menu-translate-x": t.dropdownOffsetX ?? "0",
|
|
359
|
+
"--user-menu-translate-y": t.dropdownOffsetY ?? "0"
|
|
360
|
+
}
|
|
361
|
+
}, {
|
|
362
|
+
content: g(() => [d("div", qe, [d("div", Ge, [w(a.$slots, "header", {
|
|
363
|
+
user: n(e)
|
|
364
|
+
}, () => [_(Xe)], !0)]), a.$slots.items ? (r(), v($e, {
|
|
365
|
+
key: 0
|
|
366
|
+
})) : U("", !0), w(a.$slots, "items", {}, void 0, !0)])]),
|
|
367
|
+
default: g(() => [w(a.$slots, "trigger", {
|
|
368
|
+
user: n(e)
|
|
369
|
+
}, () => {
|
|
370
|
+
var f, B, I, $, l;
|
|
371
|
+
return [_(ke, {
|
|
372
|
+
"user-id": (f = n(e)) == null ? void 0 : f.id,
|
|
373
|
+
nickname: (B = n(e)) == null ? void 0 : B.nickname,
|
|
374
|
+
email: (I = n(e)) == null ? void 0 : I.email,
|
|
375
|
+
phone: ($ = n(e)) == null ? void 0 : $.phone,
|
|
376
|
+
avatar: (l = n(e)) == null ? void 0 : l.avatarUrl
|
|
377
|
+
}, null, 8, ["user-id", "nickname", "email", "phone", "avatar"])];
|
|
378
|
+
}, !0)]),
|
|
379
|
+
_: 3
|
|
380
|
+
}, 8, ["popup-visible", "position", "popup-style"]))], 2));
|
|
381
|
+
}
|
|
382
|
+
}), ht = /* @__PURE__ */ S(Je, [["__scopeId", "data-v-c03d428f"]]), Ke = ["disabled"], Qe = {
|
|
383
|
+
class: "UserMenuItem__label"
|
|
384
|
+
}, We = {
|
|
385
|
+
class: "UserMenuItem__label-text"
|
|
386
|
+
}, Ze = {
|
|
387
|
+
key: 0,
|
|
388
|
+
class: "UserMenuItem__icon"
|
|
389
|
+
}, et = /* @__PURE__ */ m({
|
|
390
|
+
__name: "UserMenuItem",
|
|
391
|
+
props: {
|
|
392
|
+
icon: {
|
|
393
|
+
default: void 0
|
|
394
|
+
},
|
|
395
|
+
danger: {
|
|
396
|
+
type: Boolean,
|
|
397
|
+
default: !1
|
|
398
|
+
},
|
|
399
|
+
disabled: {
|
|
400
|
+
type: Boolean,
|
|
401
|
+
default: !1
|
|
402
|
+
},
|
|
403
|
+
closeOnClick: {
|
|
404
|
+
type: Boolean,
|
|
405
|
+
default: !0
|
|
406
|
+
},
|
|
407
|
+
badge: {
|
|
408
|
+
default: 0
|
|
409
|
+
}
|
|
410
|
+
},
|
|
411
|
+
emits: ["click"],
|
|
412
|
+
setup(t, {
|
|
413
|
+
emit: e
|
|
414
|
+
}) {
|
|
415
|
+
const o = t, s = b(() => o.badge > 0), i = e, {
|
|
416
|
+
close: c
|
|
417
|
+
} = y();
|
|
418
|
+
function a(u) {
|
|
419
|
+
u.stopPropagation(), !o.disabled && (o.closeOnClick && c(), i("click", u));
|
|
420
|
+
}
|
|
421
|
+
return (u, f) => (r(), p("button", {
|
|
422
|
+
type: "button",
|
|
423
|
+
class: q(["UserMenuItem", {
|
|
424
|
+
"is-danger": t.danger,
|
|
425
|
+
"is-disabled": t.disabled
|
|
426
|
+
}]),
|
|
427
|
+
disabled: t.disabled,
|
|
428
|
+
onClick: a
|
|
429
|
+
}, [d("span", Qe, [s.value ? (r(), v(n(ne), {
|
|
430
|
+
key: 0,
|
|
431
|
+
count: t.badge,
|
|
432
|
+
"max-count": 99,
|
|
433
|
+
offset: [10, 0]
|
|
434
|
+
}, {
|
|
435
|
+
default: g(() => [d("span", We, [w(u.$slots, "default", {}, void 0, !0)])]),
|
|
436
|
+
_: 3
|
|
437
|
+
}, 8, ["count"])) : w(u.$slots, "default", {
|
|
438
|
+
key: 1
|
|
439
|
+
}, void 0, !0)]), u.$slots.icon || t.icon ? (r(), p("span", Ze, [w(u.$slots, "icon", {}, () => [t.icon ? (r(), v(n(ve), {
|
|
440
|
+
key: 0,
|
|
441
|
+
icon: t.icon,
|
|
442
|
+
width: 16,
|
|
443
|
+
height: 16
|
|
444
|
+
}, null, 8, ["icon"])) : U("", !0)], !0)])) : U("", !0)], 10, Ke));
|
|
445
|
+
}
|
|
446
|
+
}), D = /* @__PURE__ */ S(et, [["__scopeId", "data-v-d5d01729"]]), St = /* @__PURE__ */ m({
|
|
447
|
+
__name: "UserMenuModals",
|
|
448
|
+
setup(t) {
|
|
449
|
+
const {
|
|
450
|
+
settingTrigger: e,
|
|
451
|
+
subscriptionsTrigger: o,
|
|
452
|
+
subscriptionsOptions: s,
|
|
453
|
+
messagesTrigger: i,
|
|
454
|
+
feedbackTrigger: c,
|
|
455
|
+
invitationsTrigger: a
|
|
456
|
+
} = y(), u = x(null), f = x(null), B = x(null), I = x(null), $ = x(null);
|
|
457
|
+
return A(e, () => {
|
|
458
|
+
var l;
|
|
459
|
+
(l = u.value) == null || l.setData(null, !0);
|
|
460
|
+
}), A(o, () => {
|
|
461
|
+
var l;
|
|
462
|
+
(l = f.value) == null || l.setData(s.value, !0);
|
|
463
|
+
}), A(i, () => {
|
|
464
|
+
var l;
|
|
465
|
+
(l = B.value) == null || l.openNotification();
|
|
466
|
+
}), A(c, () => {
|
|
467
|
+
var l;
|
|
468
|
+
(l = I.value) == null || l.setData(!0);
|
|
469
|
+
}), A(a, () => {
|
|
470
|
+
var l;
|
|
471
|
+
(l = $.value) == null || l.setData(!0);
|
|
472
|
+
}), (l, H) => (r(), p(Y, null, [_(me, {
|
|
473
|
+
ref_key: "appSettingRef",
|
|
474
|
+
ref: u
|
|
475
|
+
}, null, 512), _(pe, {
|
|
476
|
+
ref_key: "paySubsRef",
|
|
477
|
+
ref: f
|
|
478
|
+
}, null, 512), _(_e, {
|
|
479
|
+
ref_key: "messageHandleRef",
|
|
480
|
+
ref: B
|
|
481
|
+
}, null, 512), _(fe, {
|
|
482
|
+
ref_key: "feedbackModalRef",
|
|
483
|
+
ref: I
|
|
484
|
+
}, null, 512), _(ae, {
|
|
485
|
+
ref_key: "refereesRef",
|
|
486
|
+
ref: $
|
|
487
|
+
}, null, 512)], 64));
|
|
488
|
+
}
|
|
489
|
+
}), tt = {
|
|
490
|
+
class: "UserAccountMenu"
|
|
491
|
+
}, nt = /* @__PURE__ */ m({
|
|
492
|
+
__name: "UserAccountMenu",
|
|
493
|
+
setup(t) {
|
|
494
|
+
const {
|
|
495
|
+
userProfile: e
|
|
496
|
+
} = R();
|
|
497
|
+
return (o, s) => {
|
|
498
|
+
var i, c, a, u, f;
|
|
499
|
+
return r(), p("div", tt, [_(Q, {
|
|
500
|
+
"user-id": (i = n(e)) == null ? void 0 : i.id,
|
|
501
|
+
"avatar-url": (c = n(e)) == null ? void 0 : c.avatarUrl,
|
|
502
|
+
nickname: (a = n(e)) == null ? void 0 : a.nickname,
|
|
503
|
+
email: (u = n(e)) == null ? void 0 : u.email,
|
|
504
|
+
phone: (f = n(e)) == null ? void 0 : f.phone
|
|
505
|
+
}, null, 8, ["user-id", "avatar-url", "nickname", "email", "phone"])]);
|
|
506
|
+
};
|
|
507
|
+
}
|
|
508
|
+
}), Bt = /* @__PURE__ */ S(nt, [["__scopeId", "data-v-fe79b69c"]]), $t = /* @__PURE__ */ m({
|
|
509
|
+
__name: "UserMenuMessageItem",
|
|
510
|
+
setup(t) {
|
|
511
|
+
const {
|
|
512
|
+
openMessages: e
|
|
513
|
+
} = y(), {
|
|
514
|
+
messageUnreadCount: o
|
|
515
|
+
} = K();
|
|
516
|
+
return (s, i) => (r(), v(D, {
|
|
517
|
+
icon: "lucide:chevron-right",
|
|
518
|
+
badge: n(o),
|
|
519
|
+
onClick: n(e)
|
|
520
|
+
}, {
|
|
521
|
+
default: g(() => [...i[0] || (i[0] = [k(" 消息中心 ", -1)])]),
|
|
522
|
+
_: 1
|
|
523
|
+
}, 8, ["badge", "onClick"]));
|
|
524
|
+
}
|
|
525
|
+
}), Mt = /* @__PURE__ */ m({
|
|
526
|
+
__name: "UserMenuSettingItem",
|
|
527
|
+
setup(t) {
|
|
528
|
+
const {
|
|
529
|
+
openSetting: e
|
|
530
|
+
} = y();
|
|
531
|
+
return (o, s) => (r(), v(D, {
|
|
532
|
+
icon: "lucide:user-round",
|
|
533
|
+
onClick: n(e)
|
|
534
|
+
}, {
|
|
535
|
+
default: g(() => [...s[0] || (s[0] = [k("用户信息", -1)])]),
|
|
536
|
+
_: 1
|
|
537
|
+
}, 8, ["onClick"]));
|
|
538
|
+
}
|
|
539
|
+
}), Ct = /* @__PURE__ */ m({
|
|
540
|
+
__name: "UserMenuSubscriptionItem",
|
|
541
|
+
setup(t) {
|
|
542
|
+
const {
|
|
543
|
+
openSubscriptions: e
|
|
544
|
+
} = y();
|
|
545
|
+
return (o, s) => (r(), v(D, {
|
|
546
|
+
icon: "lucide:chevron-right",
|
|
547
|
+
onClick: s[0] || (s[0] = (i) => n(e)())
|
|
548
|
+
}, {
|
|
549
|
+
default: g(() => [...s[1] || (s[1] = [k("订阅与积分", -1)])]),
|
|
550
|
+
_: 1
|
|
551
|
+
}));
|
|
552
|
+
}
|
|
553
|
+
}), xt = /* @__PURE__ */ m({
|
|
554
|
+
__name: "UserMenuFeedbackItem",
|
|
555
|
+
setup(t) {
|
|
556
|
+
const {
|
|
557
|
+
openFeedback: e
|
|
558
|
+
} = y(), {
|
|
559
|
+
feedbackUnreadCount: o
|
|
560
|
+
} = K();
|
|
561
|
+
return (s, i) => (r(), v(D, {
|
|
562
|
+
icon: "lucide:chevron-right",
|
|
563
|
+
badge: n(o),
|
|
564
|
+
onClick: n(e)
|
|
565
|
+
}, {
|
|
566
|
+
default: g(() => [...i[0] || (i[0] = [k(" 系统反馈 ", -1)])]),
|
|
567
|
+
_: 1
|
|
568
|
+
}, 8, ["badge", "onClick"]));
|
|
569
|
+
}
|
|
570
|
+
}), At = /* @__PURE__ */ m({
|
|
571
|
+
__name: "UserMenuInvitationsItem",
|
|
572
|
+
setup(t) {
|
|
573
|
+
const {
|
|
574
|
+
openInvitations: e
|
|
575
|
+
} = y();
|
|
576
|
+
return (o, s) => (r(), v(D, {
|
|
577
|
+
icon: "lucide:chevron-right",
|
|
578
|
+
onClick: n(e)
|
|
579
|
+
}, {
|
|
580
|
+
default: g(() => [...s[0] || (s[0] = [k("邀请", -1)])]),
|
|
581
|
+
_: 1
|
|
582
|
+
}, 8, ["onClick"]));
|
|
583
|
+
}
|
|
584
|
+
});
|
|
585
|
+
export {
|
|
586
|
+
Bt as U,
|
|
587
|
+
xt as _,
|
|
588
|
+
ke as a,
|
|
589
|
+
Q as b,
|
|
590
|
+
ht as c,
|
|
591
|
+
$e as d,
|
|
592
|
+
Xe as e,
|
|
593
|
+
At as f,
|
|
594
|
+
D as g,
|
|
595
|
+
$t as h,
|
|
596
|
+
St as i,
|
|
597
|
+
Mt as j,
|
|
598
|
+
Ct as k,
|
|
599
|
+
Ie as l,
|
|
600
|
+
Fe as m
|
|
601
|
+
};
|
|
@@ -7,13 +7,13 @@ import "./apiClients-CWSwNzGk.js";
|
|
|
7
7
|
import { u as ye } from "./useAuthkitAppsAuthPageInfo-2izIyMfu.js";
|
|
8
8
|
import { s as be, a as ke } from "./runtime-DDJRAtkv.js";
|
|
9
9
|
import "@vafast/api-client";
|
|
10
|
-
import "./useAuthkitUsersProfile-
|
|
10
|
+
import "./useAuthkitUsersProfile-D4H_Gxgd.js";
|
|
11
11
|
import { useRouter as Z, useRoute as ee } from "vue-router";
|
|
12
|
-
import { b as te, c as ne, f as oe, w as se, a as ae, d as re } from "./useRoutePermission-
|
|
12
|
+
import { b as te, c as ne, f as oe, w as se, a as ae, d as re } from "./useRoutePermission-CGq_LIZM.js";
|
|
13
13
|
import "@unhead/vue";
|
|
14
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 we, i as he } from "./UserMenuInvitationsItem.vue_vue_type_script_setup_true_lang-
|
|
16
|
-
import "./
|
|
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 we, i as he } from "./UserMenuInvitationsItem.vue_vue_type_script_setup_true_lang-DbkGYZ2f.js";
|
|
16
|
+
import "./useBillingSubscriptionSummary-BC3G0N4t.js";
|
|
17
17
|
/* empty css */
|
|
18
18
|
/* empty css */
|
|
19
19
|
import { M as $e } from "./Menu-uCexrsKP.js";
|
package/dist/authkit.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { A as s, B as i, a as e, _ as u, b as h, O as A, P as o, c as r, d as n, e as k, f as d, S as g, g as l, h as p, u as P, i as f } from "./AuthkitAppSetting-
|
|
2
|
-
import { A as m, a as S, b as L, c as O, d as U, E as w, e as x, f as B, g as D, O as E, h as b, P as y, i as C, j as I, _ as v, R as V, S as _, k as R, l as T, m as G, n as M, o as j, p as z, L as F } from "./LegalDocViewer-
|
|
1
|
+
import { A as s, B as i, a as e, _ as u, b as h, O as A, P as o, c as r, d as n, e as k, f as d, S as g, g as l, h as p, u as P, i as f } from "./AuthkitAppSetting-CHVSyEY1.js";
|
|
2
|
+
import { A as m, a as S, b as L, c as O, d as U, E as w, e as x, f as B, g as D, O as E, h as b, P as y, i as C, j as I, _ as v, R as V, S as _, k as R, l as T, m as G, n as M, o as j, p as z, L as F } from "./LegalDocViewer-DiNoy_oj.js";
|
|
3
3
|
import { u as Y } from "./useAuthkitAppsAuthPageInfo-2izIyMfu.js";
|
|
4
4
|
import { u as H } from "./useAuthkitAuth-CWHJs8zY.js";
|
|
5
5
|
import { u as N } from "./apiClients-CWSwNzGk.js";
|
|
6
6
|
import { u as W } from "./useEnsureAuthenticated-RZ1DflLz.js";
|
|
7
7
|
import { L as Z, a as $, b as tt, i as at, o as st, r as it, c as et, u as ut } from "./useLegalDocs-xXYvYpPC.js";
|
|
8
8
|
import { f as At } from "./fetchAuthPageAboutUs-CLQlGhQy.js";
|
|
9
|
-
import { u as rt } from "./useAuthkitUsersProfile-
|
|
9
|
+
import { u as rt } from "./useAuthkitUsersProfile-D4H_Gxgd.js";
|
|
10
10
|
import { u as kt } from "./useAuthkitCreateAndUpdate-COI5KVPJ.js";
|
|
11
11
|
export {
|
|
12
12
|
s as AuthkitAppSetting,
|
package/dist/common.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { A as s, a as o, C as r, D as t, G as p, H as n, b as l, S as m, W as u } from "./WidthContainer-
|
|
1
|
+
import { A as s, a as o, C as r, D as t, G as p, H as n, b as l, S as m, W as u } from "./WidthContainer-FXZqDMid.js";
|
|
2
2
|
import { C as d, a as f } from "./CollapseItem-DUzZA6tx.js";
|
|
3
3
|
import { C as x, E as b } from "./CustomTable-BY0oHLXc.js";
|
|
4
4
|
import { L } from "./Logo-B9DFBxDU.js";
|
|
@@ -2,10 +2,10 @@ declare function setData(_data: unknown, state: boolean): void;
|
|
|
2
2
|
declare const _default: import('vue').DefineComponent<{}, {
|
|
3
3
|
setData: typeof setData;
|
|
4
4
|
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
5
|
-
confirm: (...args: any[]) => void;
|
|
6
5
|
cancel: (...args: any[]) => void;
|
|
6
|
+
confirm: (...args: any[]) => void;
|
|
7
7
|
}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{
|
|
8
|
-
onConfirm?: ((...args: any[]) => any) | undefined;
|
|
9
8
|
onCancel?: ((...args: any[]) => any) | undefined;
|
|
9
|
+
onConfirm?: ((...args: any[]) => any) | undefined;
|
|
10
10
|
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
11
11
|
export default _default;
|
|
@@ -2,10 +2,10 @@ declare function setData(state: boolean): void;
|
|
|
2
2
|
declare const _default: import('vue').DefineComponent<{}, {
|
|
3
3
|
setData: typeof setData;
|
|
4
4
|
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
5
|
-
confirm: (...args: any[]) => void;
|
|
6
5
|
cancel: (...args: any[]) => void;
|
|
6
|
+
confirm: (...args: any[]) => void;
|
|
7
7
|
}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{
|
|
8
|
-
onConfirm?: ((...args: any[]) => any) | undefined;
|
|
9
8
|
onCancel?: ((...args: any[]) => any) | undefined;
|
|
9
|
+
onConfirm?: ((...args: any[]) => any) | undefined;
|
|
10
10
|
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
11
11
|
export default _default;
|