@huyooo/ui 2.0.8 → 2.0.10
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-eXw1JiyT.js → AuthkitAppSetting-DoC2RJh7.js} +1 -1
- package/dist/{Contact-C5T90358.js → Contact-EqPBWd-E.js} +86 -86
- package/dist/{FeedbackModal.vue_vue_type_script_setup_true_lang-B3CA1z6v.js → FeedbackModal.vue_vue_type_script_setup_true_lang-hveEkBb4.js} +1 -1
- package/dist/{LandingPageLinkGroup-BZJ48Yss.js → LandingPageLinkGroup-C4iHX7Hz.js} +70 -65
- package/dist/{LandingPageSectionTabs-jRjkWlM-.js → LandingPageSectionTabs-BT08gT7_.js} +357 -357
- package/dist/{LegalDocViewer-Dxl4FngI.js → LegalDocViewer-DBr0x1ZE.js} +426 -410
- package/dist/{Logo-D7fyXyB-.js → Logo-B9DFBxDU.js} +1 -1
- package/dist/{ReferrerReferees-D4VEC8QJ.js → ReferrerReferees-CGrH-gYJ.js} +1 -1
- package/dist/{UserMenuInvitationsItem.vue_vue_type_script_setup_true_lang-BdibAudA.js → UserMenuInvitationsItem.vue_vue_type_script_setup_true_lang-QE1ARaXY.js} +195 -211
- package/dist/WidthContainer-Clc_WxY_.js +706 -0
- package/dist/authkit.js +3 -3
- package/dist/common.js +2 -2
- package/dist/components/Gradientbackground.vue.d.ts +1 -1
- package/dist/components/UserMenu/UserMenu.vue.d.ts +2 -2
- package/dist/composables/Authkit/useAppBrand.d.ts +7 -0
- package/dist/composables/Authkit/useAuthkitUsersProfile.d.ts +2 -0
- package/dist/composables.d.ts +1 -0
- package/dist/composables.js +36 -35
- package/dist/feedback.js +1 -1
- package/dist/landingPage.js +3 -3
- package/dist/main.js +234 -233
- package/dist/privateCom.js +1 -1
- package/dist/referrer.js +1 -1
- package/dist/style.css +1 -1
- package/dist/useAuthkitUsersProfile-8FzLTfUJ.js +55 -0
- package/dist/useRoutePermission-DYPZgvYv.js +247 -0
- package/dist/user.js +1 -1
- package/dist/utils/copyright.d.ts +1 -0
- package/package.json +1 -1
- package/dist/WidthContainer-AZl-9MdF.js +0 -717
- package/dist/components/UserMenu/parts/UserMenuAuthPlaceholder.vue.d.ts +0 -7
- package/dist/useAuthkitUsersProfile-CTd6PP-a.js +0 -50
- package/dist/useRoutePermission-B_g-WmDZ.js +0 -226
|
@@ -1,30 +1,30 @@
|
|
|
1
|
-
import { defineComponent as V, computed as
|
|
2
|
-
import { useRouter as be, useRoute as
|
|
1
|
+
import { defineComponent as V, computed as T, openBlock as l, createElementBlock as k, normalizeStyle as G, normalizeClass as he, renderSlot as Z, createBlock as S, unref as e, createCommentVNode as I, createElementVNode as _, toDisplayString as L, ref as A, createVNode as i, withCtx as p, createTextVNode as O, watchEffect as ne, Fragment as D, renderList as re, useModel as Ue, watch as ye, mergeModels as $e, useSlots as Re, onMounted as E, onUnmounted as ue, Teleport as Te } from "vue";
|
|
2
|
+
import { useRouter as be, useRoute as qe } from "vue-router";
|
|
3
3
|
/* empty css */
|
|
4
4
|
/* empty css */
|
|
5
5
|
import "./userMenuModal-D-nDaYqM.js";
|
|
6
|
-
import { Message as X, Form as H, FormItem as P, Input as C, Button as
|
|
7
|
-
import { a as
|
|
8
|
-
import { g as
|
|
6
|
+
import { Message as X, Form as H, FormItem as P, Input as C, Button as B, Link as Y, Tabs as de, TabPane as ce, Checkbox as Oe, Modal as xe, List as Le, ListItem as ae, ListItemMeta as oe, Avatar as te, Alert as fe, Spin as Be, Empty as Me } from "@arco-design/web-vue";
|
|
7
|
+
import { a as F, u as N } from "./useAuthkitAuth-cHrJMM8E.js";
|
|
8
|
+
import { g as M, u as we } from "./apiClients-Ctcq8NZs.js";
|
|
9
9
|
import { u as j } from "./useAuthkitAppsAuthPageInfo-DZ1p-P3Q.js";
|
|
10
|
-
import { o as ve, j as
|
|
10
|
+
import { o as ve, j as Fe, k as ge, l as _e, u as De, m as Ee, n as He, p as Q, q as Ge, i as ke, S as W, r as K, s as Se, t as ze, v as le, w as Ne, x as je, b as We } from "./AuthkitAppSetting-DoC2RJh7.js";
|
|
11
11
|
import { _ as U } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
12
12
|
/* empty css */
|
|
13
13
|
import "./index-Cn6LcfZO.js";
|
|
14
14
|
/* empty css */
|
|
15
|
-
import { u as Ie, L as
|
|
15
|
+
import { u as Ie, L as Ke, i as Je } from "./useLegalDocs-C4qk5CTb.js";
|
|
16
16
|
import { u as pe } from "./runtime-Dp7MgwhI.js";
|
|
17
|
-
import { u as Ae } from "./useAuthkitUsersProfile-
|
|
17
|
+
import { u as Ae } from "./useAuthkitUsersProfile-8FzLTfUJ.js";
|
|
18
18
|
/* empty css */
|
|
19
19
|
/* empty css */
|
|
20
20
|
import "./CustomTable-HDwqEcmB.js";
|
|
21
21
|
/* empty css */
|
|
22
|
-
import { TiptapEditor as
|
|
23
|
-
import { f as
|
|
24
|
-
const
|
|
22
|
+
import { TiptapEditor as Qe, TiptapTitle as Xe } from "@huyooo/vue-tiptap";
|
|
23
|
+
import { f as Ye } from "./fetchAuthPageAboutUs-DV7ArpNZ.js";
|
|
24
|
+
const Ze = ["title", "aria-label", "disabled"], et = {
|
|
25
25
|
key: 0,
|
|
26
26
|
class: "OAuthItem__spinner"
|
|
27
|
-
},
|
|
27
|
+
}, tt = /* @__PURE__ */ V({
|
|
28
28
|
__name: "AuthkitOauthItem",
|
|
29
29
|
props: {
|
|
30
30
|
size: {
|
|
@@ -49,10 +49,10 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
49
49
|
}
|
|
50
50
|
},
|
|
51
51
|
setup(b) {
|
|
52
|
-
const r = b, u =
|
|
52
|
+
const r = b, u = T(() => ({
|
|
53
53
|
width: `${ge}px`,
|
|
54
54
|
height: `${ge}px`,
|
|
55
|
-
padding: `${
|
|
55
|
+
padding: `${Fe}px`,
|
|
56
56
|
"--oauth-icon-size": `${ve}px`
|
|
57
57
|
}));
|
|
58
58
|
return (o, h) => (l(), k("button", {
|
|
@@ -64,23 +64,23 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
64
64
|
"aria-label": r.label,
|
|
65
65
|
disabled: r.disabled || r.loading,
|
|
66
66
|
style: G(u.value)
|
|
67
|
-
}, [r.loading ? (l(), k("span",
|
|
67
|
+
}, [r.loading ? (l(), k("span", et)) : Z(o.$slots, "icon", {
|
|
68
68
|
key: 1
|
|
69
69
|
}, () => [r.icon ? (l(), S(_e, {
|
|
70
70
|
key: 0,
|
|
71
71
|
icon: r.icon,
|
|
72
72
|
size: e(ve)
|
|
73
|
-
}, null, 8, ["icon", "size"])) : I("", !0)], !0)], 14,
|
|
73
|
+
}, null, 8, ["icon", "size"])) : I("", !0)], !0)], 14, Ze));
|
|
74
74
|
}
|
|
75
|
-
}), J = /* @__PURE__ */ U(
|
|
75
|
+
}), J = /* @__PURE__ */ U(tt, [["__scopeId", "data-v-e00c1d80"]]), st = {
|
|
76
76
|
class: "OAuthList"
|
|
77
|
-
},
|
|
77
|
+
}, it = {
|
|
78
78
|
key: 0,
|
|
79
79
|
class: "OAuthDivider"
|
|
80
80
|
}, at = {
|
|
81
81
|
key: 1,
|
|
82
82
|
class: "OAuthHint"
|
|
83
|
-
},
|
|
83
|
+
}, ot = /* @__PURE__ */ V({
|
|
84
84
|
__name: "AuthkitOauthList",
|
|
85
85
|
props: {
|
|
86
86
|
size: {
|
|
@@ -97,9 +97,9 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
97
97
|
} = j(), {
|
|
98
98
|
loading: h,
|
|
99
99
|
supported: g,
|
|
100
|
-
loginWithPasskey:
|
|
100
|
+
loginWithPasskey: a,
|
|
101
101
|
formatError: s
|
|
102
|
-
} =
|
|
102
|
+
} = De(), {
|
|
103
103
|
githubAuth: d,
|
|
104
104
|
googleAuth: v,
|
|
105
105
|
microsoftAuth: t,
|
|
@@ -107,78 +107,78 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
107
107
|
} = ke(), {
|
|
108
108
|
acceptedTerms: n,
|
|
109
109
|
ensureTermsAcceptedForSignIn: w
|
|
110
|
-
} =
|
|
111
|
-
function c(
|
|
112
|
-
w() &&
|
|
110
|
+
} = F();
|
|
111
|
+
function c($) {
|
|
112
|
+
w() && $({
|
|
113
113
|
acceptedTerms: n.value ? !0 : void 0
|
|
114
114
|
});
|
|
115
115
|
}
|
|
116
|
-
const m = b, y =
|
|
117
|
-
const
|
|
118
|
-
return
|
|
116
|
+
const m = b, y = T(() => o.value.authMethods.login.passkey && Ee() || ""), z = T(() => {
|
|
117
|
+
const $ = o.value.oauth, R = $.google.enabled || $.microsoft.enabled || $.github.enabled || $.wechat.enabled, x = o.value.authMethods.login.passkey;
|
|
118
|
+
return R || x;
|
|
119
119
|
});
|
|
120
120
|
async function q() {
|
|
121
121
|
if (w())
|
|
122
122
|
try {
|
|
123
|
-
const
|
|
124
|
-
if (
|
|
123
|
+
const $ = await a();
|
|
124
|
+
if (!$)
|
|
125
125
|
return;
|
|
126
|
-
u("passkeySubmit",
|
|
127
|
-
} catch (
|
|
128
|
-
const
|
|
129
|
-
if (
|
|
130
|
-
X.warning(
|
|
126
|
+
u("passkeySubmit", $);
|
|
127
|
+
} catch ($) {
|
|
128
|
+
const R = s($);
|
|
129
|
+
if ($ instanceof Error && $.name === "NotAllowedError") {
|
|
130
|
+
X.warning(R);
|
|
131
131
|
return;
|
|
132
132
|
}
|
|
133
|
-
X.error(
|
|
133
|
+
X.error(R);
|
|
134
134
|
}
|
|
135
135
|
}
|
|
136
|
-
return (R
|
|
136
|
+
return ($, R) => (l(), k("div", st, [z.value ? (l(), k("div", it, [...R[4] || (R[4] = [_("span", null, "其他登录方式", -1)])])) : I("", !0), _("div", {
|
|
137
137
|
class: "OAuthIcons",
|
|
138
138
|
style: G({
|
|
139
|
-
gap: `${e(
|
|
139
|
+
gap: `${e(He)}px`
|
|
140
140
|
})
|
|
141
141
|
}, [e(o).oauth.google.enabled ? (l(), S(J, {
|
|
142
142
|
key: 0,
|
|
143
143
|
icon: e(Q).google,
|
|
144
144
|
label: "Google",
|
|
145
145
|
size: m.size,
|
|
146
|
-
onClick:
|
|
146
|
+
onClick: R[0] || (R[0] = (x) => c(e(v)))
|
|
147
147
|
}, null, 8, ["icon", "size"])) : I("", !0), e(o).oauth.github.enabled ? (l(), S(J, {
|
|
148
148
|
key: 1,
|
|
149
149
|
icon: e(Q).github,
|
|
150
150
|
label: "Github",
|
|
151
151
|
size: m.size,
|
|
152
|
-
onClick:
|
|
152
|
+
onClick: R[1] || (R[1] = (x) => c(e(d)))
|
|
153
153
|
}, null, 8, ["icon", "size"])) : I("", !0), e(o).oauth.microsoft.enabled ? (l(), S(J, {
|
|
154
154
|
key: 2,
|
|
155
155
|
icon: e(Q).microsoft,
|
|
156
156
|
label: "Microsoft",
|
|
157
157
|
size: m.size,
|
|
158
|
-
onClick:
|
|
158
|
+
onClick: R[2] || (R[2] = (x) => c(e(t)))
|
|
159
159
|
}, null, 8, ["icon", "size"])) : I("", !0), e(o).oauth.wechat.enabled ? (l(), S(J, {
|
|
160
160
|
key: 3,
|
|
161
161
|
icon: e(Q).wechat,
|
|
162
162
|
label: "微信",
|
|
163
163
|
size: m.size,
|
|
164
|
-
onClick:
|
|
164
|
+
onClick: R[3] || (R[3] = (x) => c(e(f)))
|
|
165
165
|
}, null, 8, ["icon", "size"])) : I("", !0), e(o).authMethods.login.passkey ? (l(), S(J, {
|
|
166
166
|
key: 4,
|
|
167
|
-
icon: e(
|
|
167
|
+
icon: e(Ge),
|
|
168
168
|
label: "Passkey",
|
|
169
169
|
size: m.size,
|
|
170
170
|
loading: e(h),
|
|
171
171
|
disabled: !e(g),
|
|
172
172
|
onClick: q
|
|
173
|
-
}, null, 8, ["icon", "size", "loading", "disabled"])) : I("", !0)], 4), y.value ? (l(), k("p", at,
|
|
173
|
+
}, null, 8, ["icon", "size", "loading", "disabled"])) : I("", !0)], 4), y.value ? (l(), k("p", at, L(y.value), 1)) : I("", !0)]));
|
|
174
174
|
}
|
|
175
|
-
}),
|
|
175
|
+
}), lt = /* @__PURE__ */ U(ot, [["__scopeId", "data-v-aa6a61de"]]), nt = {
|
|
176
176
|
class: "content"
|
|
177
|
-
}, nt = {
|
|
178
|
-
class: "sendVerifyCodeItem"
|
|
179
177
|
}, rt = {
|
|
178
|
+
class: "sendVerifyCodeItem"
|
|
179
|
+
}, ut = {
|
|
180
180
|
class: "handle"
|
|
181
|
-
},
|
|
181
|
+
}, dt = /* @__PURE__ */ V({
|
|
182
182
|
__name: "AuthkitPasswordUpdateAndVerify",
|
|
183
183
|
props: {
|
|
184
184
|
size: {
|
|
@@ -195,7 +195,7 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
195
195
|
setup(b, {
|
|
196
196
|
emit: r
|
|
197
197
|
}) {
|
|
198
|
-
const u = r, o = b, h = A(), g = A(!1),
|
|
198
|
+
const u = r, o = b, h = A(), g = A(!1), a = A(), s = A({
|
|
199
199
|
email: void 0,
|
|
200
200
|
userToken: void 0,
|
|
201
201
|
emailVerifyId: void 0,
|
|
@@ -203,9 +203,9 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
203
203
|
confirmPassword: void 0
|
|
204
204
|
});
|
|
205
205
|
async function d() {
|
|
206
|
-
if (!await
|
|
206
|
+
if (!await a.value.validateField(["email"])) {
|
|
207
207
|
g.value = !0;
|
|
208
|
-
const f = await
|
|
208
|
+
const f = await M().auth.verify.email.retry.post({
|
|
209
209
|
email: s.value.email,
|
|
210
210
|
purpose: "resetPassword"
|
|
211
211
|
});
|
|
@@ -213,18 +213,18 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
213
213
|
}
|
|
214
214
|
}
|
|
215
215
|
async function v() {
|
|
216
|
-
|
|
216
|
+
a.value.validate().then((t) => {
|
|
217
217
|
t || u("submit", s.value);
|
|
218
218
|
});
|
|
219
219
|
}
|
|
220
|
-
return (t, f) => (l(), k("div",
|
|
220
|
+
return (t, f) => (l(), k("div", nt, [i(e(H), {
|
|
221
221
|
ref_key: "formRef",
|
|
222
|
-
ref:
|
|
222
|
+
ref: a,
|
|
223
223
|
model: s.value,
|
|
224
224
|
size: o.size,
|
|
225
225
|
"auto-label-width": ""
|
|
226
226
|
}, {
|
|
227
|
-
default: p(() => [
|
|
227
|
+
default: p(() => [i(e(P), {
|
|
228
228
|
field: "email",
|
|
229
229
|
label: "邮箱",
|
|
230
230
|
"hide-label": "",
|
|
@@ -236,13 +236,13 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
236
236
|
message: "请输入有效的邮箱"
|
|
237
237
|
}]
|
|
238
238
|
}, {
|
|
239
|
-
default: p(() => [
|
|
239
|
+
default: p(() => [i(e(C), {
|
|
240
240
|
modelValue: s.value.email,
|
|
241
241
|
"onUpdate:modelValue": f[0] || (f[0] = (n) => s.value.email = n),
|
|
242
242
|
placeholder: "请输入邮箱"
|
|
243
243
|
}, null, 8, ["modelValue"])]),
|
|
244
244
|
_: 1
|
|
245
|
-
}),
|
|
245
|
+
}), i(e(P), {
|
|
246
246
|
field: "userToken",
|
|
247
247
|
label: "验证码",
|
|
248
248
|
"hide-label": "",
|
|
@@ -251,11 +251,11 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
251
251
|
message: "请输入验证码"
|
|
252
252
|
}]
|
|
253
253
|
}, {
|
|
254
|
-
default: p(() => [_("div",
|
|
254
|
+
default: p(() => [_("div", rt, [i(e(C), {
|
|
255
255
|
modelValue: s.value.userToken,
|
|
256
256
|
"onUpdate:modelValue": f[1] || (f[1] = (n) => s.value.userToken = n),
|
|
257
257
|
placeholder: "请输入验证码"
|
|
258
|
-
}, null, 8, ["modelValue"]),
|
|
258
|
+
}, null, 8, ["modelValue"]), i(W, {
|
|
259
259
|
ref_key: "SendVerifyCodeRef",
|
|
260
260
|
ref: h,
|
|
261
261
|
size: o.size,
|
|
@@ -266,7 +266,7 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
266
266
|
onSend: d
|
|
267
267
|
}, null, 8, ["size", "loading"])])]),
|
|
268
268
|
_: 1
|
|
269
|
-
}),
|
|
269
|
+
}), i(e(P), {
|
|
270
270
|
field: "password",
|
|
271
271
|
label: "密码",
|
|
272
272
|
"hide-label": "",
|
|
@@ -278,7 +278,7 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
278
278
|
message: "密码不能少于10字符"
|
|
279
279
|
}]
|
|
280
280
|
}, {
|
|
281
|
-
default: p(() => [
|
|
281
|
+
default: p(() => [i(e(C), {
|
|
282
282
|
modelValue: s.value.password,
|
|
283
283
|
"onUpdate:modelValue": f[2] || (f[2] = (n) => s.value.password = n),
|
|
284
284
|
placeholder: "请输入密码",
|
|
@@ -286,7 +286,7 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
286
286
|
autocomplete: ""
|
|
287
287
|
}, null, 8, ["modelValue"])]),
|
|
288
288
|
_: 1
|
|
289
|
-
}),
|
|
289
|
+
}), i(e(P), {
|
|
290
290
|
field: "confirmPassword",
|
|
291
291
|
label: "确认密码",
|
|
292
292
|
"hide-label": "",
|
|
@@ -302,7 +302,7 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
302
302
|
}
|
|
303
303
|
}]
|
|
304
304
|
}, {
|
|
305
|
-
default: p(() => [
|
|
305
|
+
default: p(() => [i(e(C), {
|
|
306
306
|
modelValue: s.value.confirmPassword,
|
|
307
307
|
"onUpdate:modelValue": f[3] || (f[3] = (n) => s.value.confirmPassword = n),
|
|
308
308
|
placeholder: "请输入确认密码密码",
|
|
@@ -310,7 +310,7 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
310
310
|
autocomplete: ""
|
|
311
311
|
}, null, 8, ["modelValue"])]),
|
|
312
312
|
_: 1
|
|
313
|
-
}, 8, ["rules"]), _("div",
|
|
313
|
+
}, 8, ["rules"]), _("div", ut, [i(e(B), {
|
|
314
314
|
type: "primary",
|
|
315
315
|
loading: o.loading,
|
|
316
316
|
long: "",
|
|
@@ -323,11 +323,11 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
323
323
|
_: 1
|
|
324
324
|
}, 8, ["model", "size"])]));
|
|
325
325
|
}
|
|
326
|
-
}),
|
|
326
|
+
}), ct = /* @__PURE__ */ U(dt, [["__scopeId", "data-v-4091e418"]]), pt = {
|
|
327
327
|
class: "content"
|
|
328
|
-
},
|
|
328
|
+
}, mt = {
|
|
329
329
|
class: "sendVerifyCodeItem"
|
|
330
|
-
},
|
|
330
|
+
}, ft = /* @__PURE__ */ V({
|
|
331
331
|
__name: "AuthkitPhonePasswordUpdateAndVerify",
|
|
332
332
|
props: {
|
|
333
333
|
size: {
|
|
@@ -344,7 +344,7 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
344
344
|
setup(b, {
|
|
345
345
|
emit: r
|
|
346
346
|
}) {
|
|
347
|
-
const u = r, o = b, h = A(), g = A(!1),
|
|
347
|
+
const u = r, o = b, h = A(), g = A(!1), a = A(), s = A({
|
|
348
348
|
phone: void 0,
|
|
349
349
|
code: void 0,
|
|
350
350
|
password: void 0,
|
|
@@ -365,9 +365,9 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
365
365
|
}
|
|
366
366
|
}];
|
|
367
367
|
async function v() {
|
|
368
|
-
if (!await
|
|
368
|
+
if (!await a.value.validateField(["phone"])) {
|
|
369
369
|
g.value = !0;
|
|
370
|
-
const n = await
|
|
370
|
+
const n = await M().auth.verify.sms.send.post({
|
|
371
371
|
phone: s.value.phone,
|
|
372
372
|
purpose: "resetPassword"
|
|
373
373
|
});
|
|
@@ -375,7 +375,7 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
375
375
|
}
|
|
376
376
|
}
|
|
377
377
|
async function t() {
|
|
378
|
-
|
|
378
|
+
a.value.validate().then((f) => {
|
|
379
379
|
f || u("submit", {
|
|
380
380
|
method: "phone",
|
|
381
381
|
phone: s.value.phone,
|
|
@@ -384,14 +384,14 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
384
384
|
});
|
|
385
385
|
});
|
|
386
386
|
}
|
|
387
|
-
return (f, n) => (l(), k("div",
|
|
387
|
+
return (f, n) => (l(), k("div", pt, [i(e(H), {
|
|
388
388
|
ref_key: "formRef",
|
|
389
|
-
ref:
|
|
389
|
+
ref: a,
|
|
390
390
|
model: s.value,
|
|
391
391
|
size: o.size,
|
|
392
392
|
"auto-label-width": ""
|
|
393
393
|
}, {
|
|
394
|
-
default: p(() => [
|
|
394
|
+
default: p(() => [i(e(P), {
|
|
395
395
|
field: "phone",
|
|
396
396
|
label: "手机号",
|
|
397
397
|
"hide-label": "",
|
|
@@ -403,7 +403,7 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
403
403
|
message: "请输入有效的手机号"
|
|
404
404
|
}]
|
|
405
405
|
}, {
|
|
406
|
-
default: p(() => [
|
|
406
|
+
default: p(() => [i(e(C), {
|
|
407
407
|
modelValue: s.value.phone,
|
|
408
408
|
"onUpdate:modelValue": n[0] || (n[0] = (w) => s.value.phone = w),
|
|
409
409
|
placeholder: "请输入手机号",
|
|
@@ -411,7 +411,7 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
411
411
|
type: "tel"
|
|
412
412
|
}, null, 8, ["modelValue"])]),
|
|
413
413
|
_: 1
|
|
414
|
-
}),
|
|
414
|
+
}), i(e(P), {
|
|
415
415
|
field: "code",
|
|
416
416
|
label: "验证码",
|
|
417
417
|
"hide-label": "",
|
|
@@ -420,12 +420,12 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
420
420
|
message: "请输入验证码"
|
|
421
421
|
}]
|
|
422
422
|
}, {
|
|
423
|
-
default: p(() => [_("div",
|
|
423
|
+
default: p(() => [_("div", mt, [i(e(C), {
|
|
424
424
|
modelValue: s.value.code,
|
|
425
425
|
"onUpdate:modelValue": n[1] || (n[1] = (w) => s.value.code = w),
|
|
426
426
|
placeholder: "请输入验证码",
|
|
427
427
|
autocomplete: "one-time-code"
|
|
428
|
-
}, null, 8, ["modelValue"]),
|
|
428
|
+
}, null, 8, ["modelValue"]), i(W, {
|
|
429
429
|
ref_key: "SendVerifyCodeRef",
|
|
430
430
|
ref: h,
|
|
431
431
|
size: o.size,
|
|
@@ -436,7 +436,7 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
436
436
|
onSend: v
|
|
437
437
|
}, null, 8, ["size", "loading"])])]),
|
|
438
438
|
_: 1
|
|
439
|
-
}),
|
|
439
|
+
}), i(e(P), {
|
|
440
440
|
field: "password",
|
|
441
441
|
label: "密码",
|
|
442
442
|
"hide-label": "",
|
|
@@ -448,7 +448,7 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
448
448
|
message: "密码不能少于10字符"
|
|
449
449
|
}]
|
|
450
450
|
}, {
|
|
451
|
-
default: p(() => [
|
|
451
|
+
default: p(() => [i(e(C), {
|
|
452
452
|
modelValue: s.value.password,
|
|
453
453
|
"onUpdate:modelValue": n[2] || (n[2] = (w) => s.value.password = w),
|
|
454
454
|
placeholder: "请输入密码",
|
|
@@ -456,13 +456,13 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
456
456
|
autocomplete: "new-password"
|
|
457
457
|
}, null, 8, ["modelValue"])]),
|
|
458
458
|
_: 1
|
|
459
|
-
}),
|
|
459
|
+
}), i(e(P), {
|
|
460
460
|
field: "confirmPassword",
|
|
461
461
|
label: "确认密码",
|
|
462
462
|
"hide-label": "",
|
|
463
463
|
rules: d
|
|
464
464
|
}, {
|
|
465
|
-
default: p(() => [
|
|
465
|
+
default: p(() => [i(e(C), {
|
|
466
466
|
modelValue: s.value.confirmPassword,
|
|
467
467
|
"onUpdate:modelValue": n[3] || (n[3] = (w) => s.value.confirmPassword = w),
|
|
468
468
|
placeholder: "请输入确认密码",
|
|
@@ -470,7 +470,7 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
470
470
|
autocomplete: "new-password"
|
|
471
471
|
}, null, 8, ["modelValue"])]),
|
|
472
472
|
_: 1
|
|
473
|
-
}),
|
|
473
|
+
}), i(e(B), {
|
|
474
474
|
type: "primary",
|
|
475
475
|
loading: o.loading,
|
|
476
476
|
long: "",
|
|
@@ -483,9 +483,9 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
483
483
|
_: 1
|
|
484
484
|
}, 8, ["model", "size"])]));
|
|
485
485
|
}
|
|
486
|
-
}),
|
|
486
|
+
}), vt = /* @__PURE__ */ U(ft, [["__scopeId", "data-v-a01a994e"]]), gt = {
|
|
487
487
|
class: "SwitchSignIn"
|
|
488
|
-
},
|
|
488
|
+
}, ht = /* @__PURE__ */ V({
|
|
489
489
|
__name: "AuthkitSwitchSignIn",
|
|
490
490
|
emits: ["switchSignIn"],
|
|
491
491
|
setup(b, {
|
|
@@ -495,7 +495,7 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
495
495
|
function o() {
|
|
496
496
|
u("switchSignIn");
|
|
497
497
|
}
|
|
498
|
-
return (h, g) => (l(), k("div",
|
|
498
|
+
return (h, g) => (l(), k("div", gt, [_("span", null, [g[1] || (g[1] = _("span", null, "已经有账号?", -1)), i(e(Y), {
|
|
499
499
|
style: {
|
|
500
500
|
padding: "0px"
|
|
501
501
|
},
|
|
@@ -505,15 +505,15 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
505
505
|
_: 1
|
|
506
506
|
})])]));
|
|
507
507
|
}
|
|
508
|
-
}), me = /* @__PURE__ */ U(
|
|
508
|
+
}), me = /* @__PURE__ */ U(ht, [["__scopeId", "data-v-c09d6c18"]]), yt = {
|
|
509
509
|
class: "ResetPassword"
|
|
510
|
-
},
|
|
510
|
+
}, bt = {
|
|
511
511
|
key: 0,
|
|
512
512
|
class: "tabsContainer"
|
|
513
|
-
},
|
|
513
|
+
}, wt = {
|
|
514
514
|
key: 3,
|
|
515
515
|
class: "empty"
|
|
516
|
-
},
|
|
516
|
+
}, _t = /* @__PURE__ */ V({
|
|
517
517
|
__name: "AuthkitResetPassword",
|
|
518
518
|
props: {
|
|
519
519
|
size: {
|
|
@@ -533,7 +533,7 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
533
533
|
}) {
|
|
534
534
|
const u = r, o = b, {
|
|
535
535
|
appsData: h
|
|
536
|
-
} = j(), g =
|
|
536
|
+
} = j(), g = T(() => h.value.authMethods), a = T(() => {
|
|
537
537
|
const t = [];
|
|
538
538
|
return g.value.login.emailPassword && t.push({
|
|
539
539
|
key: "email",
|
|
@@ -545,7 +545,7 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
545
545
|
}), s = A("email");
|
|
546
546
|
ne(() => {
|
|
547
547
|
var t;
|
|
548
|
-
|
|
548
|
+
a.value.some((f) => f.key === s.value) || (s.value = ((t = a.value[0]) == null ? void 0 : t.key) || "email");
|
|
549
549
|
});
|
|
550
550
|
function d() {
|
|
551
551
|
u("switchSignIn");
|
|
@@ -556,45 +556,45 @@ const Ye = ["title", "aria-label", "disabled"], Ze = {
|
|
|
556
556
|
...t
|
|
557
557
|
});
|
|
558
558
|
}
|
|
559
|
-
return (t, f) => (l(), k("div",
|
|
559
|
+
return (t, f) => (l(), k("div", yt, [a.value.length > 1 ? (l(), k("div", bt, [i(e(de), {
|
|
560
560
|
"active-key": s.value,
|
|
561
561
|
"onUpdate:activeKey": f[0] || (f[0] = (n) => s.value = n)
|
|
562
562
|
}, {
|
|
563
|
-
default: p(() => [(l(!0), k(D, null, re(
|
|
563
|
+
default: p(() => [(l(!0), k(D, null, re(a.value, (n) => (l(), S(e(ce), {
|
|
564
564
|
key: n.key,
|
|
565
565
|
title: n.title
|
|
566
566
|
}, null, 8, ["title"]))), 128))]),
|
|
567
567
|
_: 1
|
|
568
|
-
}, 8, ["active-key"])])) : I("", !0), s.value === "email" && g.value.login.emailPassword ? (l(), S(
|
|
568
|
+
}, 8, ["active-key"])])) : I("", !0), s.value === "email" && g.value.login.emailPassword ? (l(), S(ct, {
|
|
569
569
|
key: 1,
|
|
570
570
|
loading: b.loading,
|
|
571
571
|
size: o.size,
|
|
572
572
|
onSubmit: v
|
|
573
|
-
}, null, 8, ["loading", "size"])) : s.value === "phone" && g.value.login.phonePassword ? (l(), S(
|
|
573
|
+
}, null, 8, ["loading", "size"])) : s.value === "phone" && g.value.login.phonePassword ? (l(), S(vt, {
|
|
574
574
|
key: 2,
|
|
575
575
|
loading: b.loading,
|
|
576
576
|
size: o.size,
|
|
577
577
|
onSubmit: v
|
|
578
|
-
}, null, 8, ["loading", "size"])) : (l(), k("div",
|
|
578
|
+
}, null, 8, ["loading", "size"])) : (l(), k("div", wt, "当前应用未开放找回密码")), i(me, {
|
|
579
579
|
onSwitchSignIn: d
|
|
580
580
|
})]));
|
|
581
581
|
}
|
|
582
|
-
}),
|
|
583
|
-
let se = null,
|
|
584
|
-
function
|
|
585
|
-
se = b.onPrivacyPolicy ?? null,
|
|
582
|
+
}), kt = /* @__PURE__ */ U(_t, [["__scopeId", "data-v-90d789bb"]]);
|
|
583
|
+
let se = null, ie = null;
|
|
584
|
+
function St(b) {
|
|
585
|
+
se = b.onPrivacyPolicy ?? null, ie = b.onUserServiceAgreement ?? null;
|
|
586
586
|
}
|
|
587
|
-
function
|
|
587
|
+
function zt() {
|
|
588
588
|
se == null || se();
|
|
589
589
|
}
|
|
590
|
-
function
|
|
591
|
-
|
|
590
|
+
function It() {
|
|
591
|
+
ie == null || ie();
|
|
592
592
|
}
|
|
593
|
-
const
|
|
593
|
+
const At = {
|
|
594
594
|
key: 2
|
|
595
|
-
},
|
|
595
|
+
}, Pt = /* @__PURE__ */ V({
|
|
596
596
|
__name: "AuthkitServiceAgreementAndPrivacyProtection",
|
|
597
|
-
props: /* @__PURE__ */
|
|
597
|
+
props: /* @__PURE__ */ $e({
|
|
598
598
|
currentView: {}
|
|
599
599
|
}, {
|
|
600
600
|
acceptedTerms: {
|
|
@@ -607,50 +607,50 @@ const It = {
|
|
|
607
607
|
setup(b) {
|
|
608
608
|
const {
|
|
609
609
|
config: r
|
|
610
|
-
} = pe(), u = b, o =
|
|
610
|
+
} = pe(), u = b, o = Ue(b, "acceptedTerms"), {
|
|
611
611
|
getLink: h,
|
|
612
612
|
openLegalDoc: g
|
|
613
613
|
} = Ie(), {
|
|
614
|
-
termsShaking:
|
|
614
|
+
termsShaking: a,
|
|
615
615
|
requiresAcceptanceForSignUp: s,
|
|
616
616
|
requiresAcceptanceForOAuth: d,
|
|
617
617
|
syncAcceptedTerms: v
|
|
618
|
-
} =
|
|
618
|
+
} = F();
|
|
619
619
|
ye(o, (z) => {
|
|
620
620
|
v(z);
|
|
621
621
|
});
|
|
622
|
-
const t =
|
|
622
|
+
const t = T(() => {
|
|
623
623
|
const z = h("userServiceAgreement");
|
|
624
624
|
return z != null && z.configured ? z : void 0;
|
|
625
|
-
}), f =
|
|
625
|
+
}), f = T(() => {
|
|
626
626
|
const z = h("privacyPolicy");
|
|
627
627
|
return z != null && z.configured ? z : void 0;
|
|
628
|
-
}), n =
|
|
628
|
+
}), n = T(() => !!(t.value || f.value)), w = T(() => u.currentView === "signUp" ? s() : u.currentView === "signIn" ? d() : !1), c = T(() => n.value && w.value);
|
|
629
629
|
function m() {
|
|
630
630
|
if (r.legalDocsMode === "builtin") {
|
|
631
631
|
g("userServiceAgreement");
|
|
632
632
|
return;
|
|
633
633
|
}
|
|
634
|
-
|
|
634
|
+
It();
|
|
635
635
|
}
|
|
636
636
|
function y() {
|
|
637
637
|
if (r.legalDocsMode === "builtin") {
|
|
638
638
|
g("privacyPolicy");
|
|
639
639
|
return;
|
|
640
640
|
}
|
|
641
|
-
|
|
641
|
+
zt();
|
|
642
642
|
}
|
|
643
643
|
return (z, q) => c.value ? (l(), k("div", {
|
|
644
644
|
key: 0,
|
|
645
645
|
class: he(["ServiceAgreementAndPrivacyProtection", {
|
|
646
|
-
"terms-shake": e(
|
|
646
|
+
"terms-shake": e(a)
|
|
647
647
|
}])
|
|
648
648
|
}, [n.value ? (l(), k(D, {
|
|
649
649
|
key: 0
|
|
650
|
-
}, [w.value ? (l(), S(e(
|
|
650
|
+
}, [w.value ? (l(), S(e(Oe), {
|
|
651
651
|
key: 0,
|
|
652
652
|
modelValue: o.value,
|
|
653
|
-
"onUpdate:modelValue": q[0] || (q[0] = (
|
|
653
|
+
"onUpdate:modelValue": q[0] || (q[0] = ($) => o.value = $),
|
|
654
654
|
class: "terms-checkbox"
|
|
655
655
|
}, {
|
|
656
656
|
default: p(() => [...q[1] || (q[1] = [_("span", {
|
|
@@ -661,21 +661,21 @@ const It = {
|
|
|
661
661
|
key: 1,
|
|
662
662
|
onClick: m
|
|
663
663
|
}, {
|
|
664
|
-
default: p(() => [O(
|
|
664
|
+
default: p(() => [O(L(t.value.label), 1)]),
|
|
665
665
|
_: 1
|
|
666
|
-
})) : I("", !0), t.value && f.value ? (l(), k("span",
|
|
666
|
+
})) : I("", !0), t.value && f.value ? (l(), k("span", At, "和")) : I("", !0), f.value ? (l(), S(e(Y), {
|
|
667
667
|
key: 3,
|
|
668
668
|
onClick: y
|
|
669
669
|
}, {
|
|
670
|
-
default: p(() => [O(
|
|
670
|
+
default: p(() => [O(L(f.value.label), 1)]),
|
|
671
671
|
_: 1
|
|
672
672
|
})) : I("", !0)], 64)) : I("", !0)], 2)) : I("", !0);
|
|
673
673
|
}
|
|
674
|
-
}), ee = /* @__PURE__ */ U(
|
|
674
|
+
}), ee = /* @__PURE__ */ U(Pt, [["__scopeId", "data-v-a0c2f361"]]), Vt = {
|
|
675
675
|
class: "content"
|
|
676
|
-
},
|
|
676
|
+
}, Ct = {
|
|
677
677
|
class: "handle"
|
|
678
|
-
},
|
|
678
|
+
}, Ut = /* @__PURE__ */ V({
|
|
679
679
|
__name: "AuthkitPasswordAuth",
|
|
680
680
|
props: {
|
|
681
681
|
size: {
|
|
@@ -698,10 +698,10 @@ const It = {
|
|
|
698
698
|
}) {
|
|
699
699
|
const u = r, {
|
|
700
700
|
useTermsFormField: o
|
|
701
|
-
} =
|
|
701
|
+
} = F(), {
|
|
702
702
|
showTermsField: h,
|
|
703
703
|
termsRules: g
|
|
704
|
-
} = o("signIn"),
|
|
704
|
+
} = o("signIn"), a = b, s = A(), d = A({
|
|
705
705
|
identifier: void 0,
|
|
706
706
|
password: void 0,
|
|
707
707
|
acceptedTerms: !1
|
|
@@ -711,14 +711,14 @@ const It = {
|
|
|
711
711
|
t || u("submit", d.value);
|
|
712
712
|
});
|
|
713
713
|
}
|
|
714
|
-
return (t, f) => (l(), k("div",
|
|
714
|
+
return (t, f) => (l(), k("div", Vt, [i(e(H), {
|
|
715
715
|
ref_key: "formRef",
|
|
716
716
|
ref: s,
|
|
717
717
|
model: d.value,
|
|
718
|
-
size:
|
|
718
|
+
size: a.size,
|
|
719
719
|
"auto-label-width": ""
|
|
720
720
|
}, {
|
|
721
|
-
default: p(() => [
|
|
721
|
+
default: p(() => [i(e(P), {
|
|
722
722
|
field: "identifier",
|
|
723
723
|
label: "邮箱或手机号",
|
|
724
724
|
"hide-label": "",
|
|
@@ -727,14 +727,14 @@ const It = {
|
|
|
727
727
|
message: "请输入邮箱或手机号"
|
|
728
728
|
}]
|
|
729
729
|
}, {
|
|
730
|
-
default: p(() => [
|
|
730
|
+
default: p(() => [i(e(C), {
|
|
731
731
|
modelValue: d.value.identifier,
|
|
732
732
|
"onUpdate:modelValue": f[0] || (f[0] = (n) => d.value.identifier = n),
|
|
733
|
-
placeholder:
|
|
733
|
+
placeholder: a.allowPhone ? "请输入邮箱或手机号" : "请输入邮箱",
|
|
734
734
|
autocomplete: "email username"
|
|
735
735
|
}, null, 8, ["modelValue", "placeholder"])]),
|
|
736
736
|
_: 1
|
|
737
|
-
}),
|
|
737
|
+
}), i(e(P), {
|
|
738
738
|
field: "password",
|
|
739
739
|
label: "密码",
|
|
740
740
|
"hide-label": "",
|
|
@@ -743,7 +743,7 @@ const It = {
|
|
|
743
743
|
message: "请输入密码"
|
|
744
744
|
}]
|
|
745
745
|
}, {
|
|
746
|
-
default: p(() => [
|
|
746
|
+
default: p(() => [i(e(C), {
|
|
747
747
|
modelValue: d.value.password,
|
|
748
748
|
"onUpdate:modelValue": f[1] || (f[1] = (n) => d.value.password = n),
|
|
749
749
|
placeholder: "请输入密码",
|
|
@@ -751,11 +751,11 @@ const It = {
|
|
|
751
751
|
autocomplete: "current-password"
|
|
752
752
|
}, null, 8, ["modelValue"])]),
|
|
753
753
|
_: 1
|
|
754
|
-
}), _("div",
|
|
754
|
+
}), _("div", Ct, [i(e(B), {
|
|
755
755
|
type: "primary",
|
|
756
|
-
loading:
|
|
756
|
+
loading: a.loading,
|
|
757
757
|
long: "",
|
|
758
|
-
size:
|
|
758
|
+
size: a.size,
|
|
759
759
|
onClick: v
|
|
760
760
|
}, {
|
|
761
761
|
default: p(() => [...f[3] || (f[3] = [O(" 登录 ", -1)])]),
|
|
@@ -766,7 +766,7 @@ const It = {
|
|
|
766
766
|
"hide-label": "",
|
|
767
767
|
rules: e(g)
|
|
768
768
|
}, {
|
|
769
|
-
default: p(() => [
|
|
769
|
+
default: p(() => [i(ee, {
|
|
770
770
|
"accepted-terms": d.value.acceptedTerms,
|
|
771
771
|
"onUpdate:acceptedTerms": f[2] || (f[2] = (n) => d.value.acceptedTerms = n),
|
|
772
772
|
"current-view": "signIn"
|
|
@@ -776,15 +776,15 @@ const It = {
|
|
|
776
776
|
_: 1
|
|
777
777
|
}, 8, ["model", "size"])]));
|
|
778
778
|
}
|
|
779
|
-
}),
|
|
779
|
+
}), $t = /* @__PURE__ */ U(Ut, [["__scopeId", "data-v-cca59a39"]]), Rt = {
|
|
780
780
|
class: "SignInPhone"
|
|
781
|
-
}, Rt = {
|
|
782
|
-
class: "content"
|
|
783
781
|
}, Tt = {
|
|
784
|
-
class: "
|
|
782
|
+
class: "content"
|
|
785
783
|
}, qt = {
|
|
784
|
+
class: "sendVerifyCodeItem"
|
|
785
|
+
}, Ot = {
|
|
786
786
|
class: "handle"
|
|
787
|
-
},
|
|
787
|
+
}, xt = /* @__PURE__ */ V({
|
|
788
788
|
__name: "AuthkitSignInPhone",
|
|
789
789
|
props: {
|
|
790
790
|
size: {
|
|
@@ -803,10 +803,10 @@ const It = {
|
|
|
803
803
|
}) {
|
|
804
804
|
const u = r, {
|
|
805
805
|
useTermsFormField: o
|
|
806
|
-
} =
|
|
806
|
+
} = F(), {
|
|
807
807
|
showTermsField: h,
|
|
808
808
|
termsRules: g
|
|
809
|
-
} = o("signIn"),
|
|
809
|
+
} = o("signIn"), a = b, s = A(), d = A(!1), v = A(), t = A({
|
|
810
810
|
phone: void 0,
|
|
811
811
|
code: void 0,
|
|
812
812
|
acceptedTerms: !1
|
|
@@ -814,7 +814,7 @@ const It = {
|
|
|
814
814
|
async function f() {
|
|
815
815
|
if (!await v.value.validateField(["phone"])) {
|
|
816
816
|
d.value = !0;
|
|
817
|
-
const c = await
|
|
817
|
+
const c = await M().auth.verify.sms.send.post({
|
|
818
818
|
phone: t.value.phone,
|
|
819
819
|
purpose: "signIn"
|
|
820
820
|
});
|
|
@@ -830,14 +830,14 @@ const It = {
|
|
|
830
830
|
});
|
|
831
831
|
});
|
|
832
832
|
}
|
|
833
|
-
return (w, c) => (l(), k("div",
|
|
833
|
+
return (w, c) => (l(), k("div", Rt, [_("div", Tt, [i(e(H), {
|
|
834
834
|
ref_key: "formRef",
|
|
835
835
|
ref: v,
|
|
836
836
|
model: t.value,
|
|
837
|
-
size:
|
|
837
|
+
size: a.size,
|
|
838
838
|
"auto-label-width": ""
|
|
839
839
|
}, {
|
|
840
|
-
default: p(() => [
|
|
840
|
+
default: p(() => [i(e(P), {
|
|
841
841
|
field: "phone",
|
|
842
842
|
label: "手机号",
|
|
843
843
|
"hide-label": "",
|
|
@@ -849,7 +849,7 @@ const It = {
|
|
|
849
849
|
message: "请输入有效的手机号"
|
|
850
850
|
}]
|
|
851
851
|
}, {
|
|
852
|
-
default: p(() => [
|
|
852
|
+
default: p(() => [i(e(C), {
|
|
853
853
|
modelValue: t.value.phone,
|
|
854
854
|
"onUpdate:modelValue": c[0] || (c[0] = (m) => t.value.phone = m),
|
|
855
855
|
placeholder: "请输入手机号",
|
|
@@ -857,7 +857,7 @@ const It = {
|
|
|
857
857
|
type: "tel"
|
|
858
858
|
}, null, 8, ["modelValue"])]),
|
|
859
859
|
_: 1
|
|
860
|
-
}),
|
|
860
|
+
}), i(e(P), {
|
|
861
861
|
field: "code",
|
|
862
862
|
label: "验证码",
|
|
863
863
|
"hide-label": "",
|
|
@@ -866,15 +866,15 @@ const It = {
|
|
|
866
866
|
message: "请输入验证码"
|
|
867
867
|
}]
|
|
868
868
|
}, {
|
|
869
|
-
default: p(() => [_("div",
|
|
869
|
+
default: p(() => [_("div", qt, [i(e(C), {
|
|
870
870
|
modelValue: t.value.code,
|
|
871
871
|
"onUpdate:modelValue": c[1] || (c[1] = (m) => t.value.code = m),
|
|
872
872
|
placeholder: "请输入验证码",
|
|
873
873
|
autocomplete: "one-time-code"
|
|
874
|
-
}, null, 8, ["modelValue"]),
|
|
874
|
+
}, null, 8, ["modelValue"]), i(W, {
|
|
875
875
|
ref_key: "SendVerifyCodeRef",
|
|
876
876
|
ref: s,
|
|
877
|
-
size:
|
|
877
|
+
size: a.size,
|
|
878
878
|
loading: d.value,
|
|
879
879
|
style: {
|
|
880
880
|
"margin-left": "10px"
|
|
@@ -882,11 +882,11 @@ const It = {
|
|
|
882
882
|
onSend: f
|
|
883
883
|
}, null, 8, ["size", "loading"])])]),
|
|
884
884
|
_: 1
|
|
885
|
-
}), _("div",
|
|
885
|
+
}), _("div", Ot, [i(e(B), {
|
|
886
886
|
type: "primary",
|
|
887
|
-
loading:
|
|
887
|
+
loading: a.loading,
|
|
888
888
|
long: "",
|
|
889
|
-
size:
|
|
889
|
+
size: a.size,
|
|
890
890
|
onClick: n
|
|
891
891
|
}, {
|
|
892
892
|
default: p(() => [...c[3] || (c[3] = [O(" 登录 ", -1)])]),
|
|
@@ -897,7 +897,7 @@ const It = {
|
|
|
897
897
|
"hide-label": "",
|
|
898
898
|
rules: e(g)
|
|
899
899
|
}, {
|
|
900
|
-
default: p(() => [
|
|
900
|
+
default: p(() => [i(ee, {
|
|
901
901
|
"accepted-terms": t.value.acceptedTerms,
|
|
902
902
|
"onUpdate:acceptedTerms": c[2] || (c[2] = (m) => t.value.acceptedTerms = m),
|
|
903
903
|
"current-view": "signIn"
|
|
@@ -907,13 +907,13 @@ const It = {
|
|
|
907
907
|
_: 1
|
|
908
908
|
}, 8, ["model", "size"])])]));
|
|
909
909
|
}
|
|
910
|
-
}),
|
|
910
|
+
}), Lt = /* @__PURE__ */ U(xt, [["__scopeId", "data-v-ef67e91c"]]), Bt = {
|
|
911
911
|
class: "SignInEmailCode"
|
|
912
|
-
}, Bt = {
|
|
913
|
-
class: "sendVerifyCodeItem"
|
|
914
912
|
}, Mt = {
|
|
913
|
+
class: "sendVerifyCodeItem"
|
|
914
|
+
}, Ft = {
|
|
915
915
|
class: "handle"
|
|
916
|
-
},
|
|
916
|
+
}, Dt = /* @__PURE__ */ V({
|
|
917
917
|
__name: "AuthkitSignInEmailCode",
|
|
918
918
|
props: {
|
|
919
919
|
size: {
|
|
@@ -932,10 +932,10 @@ const It = {
|
|
|
932
932
|
}) {
|
|
933
933
|
const u = r, {
|
|
934
934
|
useTermsFormField: o
|
|
935
|
-
} =
|
|
935
|
+
} = F(), {
|
|
936
936
|
showTermsField: h,
|
|
937
937
|
termsRules: g
|
|
938
|
-
} = o("signIn"),
|
|
938
|
+
} = o("signIn"), a = b, s = A(), d = A(!1), v = A(), t = A({
|
|
939
939
|
email: void 0,
|
|
940
940
|
code: void 0,
|
|
941
941
|
emailVerifyId: "",
|
|
@@ -945,7 +945,7 @@ const It = {
|
|
|
945
945
|
var c;
|
|
946
946
|
if (!await v.value.validateField(["email"])) {
|
|
947
947
|
d.value = !0;
|
|
948
|
-
const m = await
|
|
948
|
+
const m = await M().auth.verify.email.retry.post({
|
|
949
949
|
email: t.value.email,
|
|
950
950
|
purpose: "signIn"
|
|
951
951
|
});
|
|
@@ -962,14 +962,14 @@ const It = {
|
|
|
962
962
|
});
|
|
963
963
|
});
|
|
964
964
|
}
|
|
965
|
-
return (w, c) => (l(), k("div",
|
|
965
|
+
return (w, c) => (l(), k("div", Bt, [i(e(H), {
|
|
966
966
|
ref_key: "formRef",
|
|
967
967
|
ref: v,
|
|
968
968
|
model: t.value,
|
|
969
|
-
size:
|
|
969
|
+
size: a.size,
|
|
970
970
|
"auto-label-width": ""
|
|
971
971
|
}, {
|
|
972
|
-
default: p(() => [
|
|
972
|
+
default: p(() => [i(e(P), {
|
|
973
973
|
field: "email",
|
|
974
974
|
"hide-label": "",
|
|
975
975
|
rules: [{
|
|
@@ -980,14 +980,14 @@ const It = {
|
|
|
980
980
|
message: "请输入有效的邮箱"
|
|
981
981
|
}]
|
|
982
982
|
}, {
|
|
983
|
-
default: p(() => [
|
|
983
|
+
default: p(() => [i(e(C), {
|
|
984
984
|
modelValue: t.value.email,
|
|
985
985
|
"onUpdate:modelValue": c[0] || (c[0] = (m) => t.value.email = m),
|
|
986
986
|
placeholder: "请输入邮箱",
|
|
987
987
|
autocomplete: "email"
|
|
988
988
|
}, null, 8, ["modelValue"])]),
|
|
989
989
|
_: 1
|
|
990
|
-
}),
|
|
990
|
+
}), i(e(P), {
|
|
991
991
|
field: "code",
|
|
992
992
|
"hide-label": "",
|
|
993
993
|
rules: [{
|
|
@@ -995,15 +995,15 @@ const It = {
|
|
|
995
995
|
message: "请输入验证码"
|
|
996
996
|
}]
|
|
997
997
|
}, {
|
|
998
|
-
default: p(() => [_("div",
|
|
998
|
+
default: p(() => [_("div", Mt, [i(e(C), {
|
|
999
999
|
modelValue: t.value.code,
|
|
1000
1000
|
"onUpdate:modelValue": c[1] || (c[1] = (m) => t.value.code = m),
|
|
1001
1001
|
placeholder: "请输入验证码",
|
|
1002
1002
|
autocomplete: "one-time-code"
|
|
1003
|
-
}, null, 8, ["modelValue"]),
|
|
1003
|
+
}, null, 8, ["modelValue"]), i(W, {
|
|
1004
1004
|
ref_key: "SendVerifyCodeRef",
|
|
1005
1005
|
ref: s,
|
|
1006
|
-
size:
|
|
1006
|
+
size: a.size,
|
|
1007
1007
|
loading: d.value,
|
|
1008
1008
|
style: {
|
|
1009
1009
|
"margin-left": "10px"
|
|
@@ -1011,11 +1011,11 @@ const It = {
|
|
|
1011
1011
|
onSend: f
|
|
1012
1012
|
}, null, 8, ["size", "loading"])])]),
|
|
1013
1013
|
_: 1
|
|
1014
|
-
}), _("div",
|
|
1014
|
+
}), _("div", Ft, [i(e(B), {
|
|
1015
1015
|
type: "primary",
|
|
1016
|
-
loading:
|
|
1016
|
+
loading: a.loading,
|
|
1017
1017
|
long: "",
|
|
1018
|
-
size:
|
|
1018
|
+
size: a.size,
|
|
1019
1019
|
onClick: n
|
|
1020
1020
|
}, {
|
|
1021
1021
|
default: p(() => [...c[3] || (c[3] = [O(" 登录 ", -1)])]),
|
|
@@ -1026,7 +1026,7 @@ const It = {
|
|
|
1026
1026
|
"hide-label": "",
|
|
1027
1027
|
rules: e(g)
|
|
1028
1028
|
}, {
|
|
1029
|
-
default: p(() => [
|
|
1029
|
+
default: p(() => [i(ee, {
|
|
1030
1030
|
"accepted-terms": t.value.acceptedTerms,
|
|
1031
1031
|
"onUpdate:acceptedTerms": c[2] || (c[2] = (m) => t.value.acceptedTerms = m),
|
|
1032
1032
|
"current-view": "signIn"
|
|
@@ -1036,11 +1036,11 @@ const It = {
|
|
|
1036
1036
|
_: 1
|
|
1037
1037
|
}, 8, ["model", "size"])]));
|
|
1038
1038
|
}
|
|
1039
|
-
}),
|
|
1039
|
+
}), Et = /* @__PURE__ */ U(Dt, [["__scopeId", "data-v-fee4702f"]]), Ht = {
|
|
1040
1040
|
class: "SwitchSignUpOrResetPassword"
|
|
1041
|
-
},
|
|
1041
|
+
}, Gt = {
|
|
1042
1042
|
key: 0
|
|
1043
|
-
},
|
|
1043
|
+
}, Nt = /* @__PURE__ */ V({
|
|
1044
1044
|
__name: "AuthkitSwitchSignUpOrResetPassword",
|
|
1045
1045
|
props: {
|
|
1046
1046
|
showSignUp: {
|
|
@@ -1063,7 +1063,7 @@ const It = {
|
|
|
1063
1063
|
function g() {
|
|
1064
1064
|
o("switchResetPassword");
|
|
1065
1065
|
}
|
|
1066
|
-
return (
|
|
1066
|
+
return (a, s) => (l(), k("div", Ht, [u.showSignUp ? (l(), k("span", Gt, [s[1] || (s[1] = _("span", null, " 还没有账户?", -1)), i(e(Y), {
|
|
1067
1067
|
style: {
|
|
1068
1068
|
padding: "0px"
|
|
1069
1069
|
},
|
|
@@ -1082,12 +1082,12 @@ const It = {
|
|
|
1082
1082
|
_: 1
|
|
1083
1083
|
})) : I("", !0)]));
|
|
1084
1084
|
}
|
|
1085
|
-
}),
|
|
1085
|
+
}), jt = /* @__PURE__ */ U(Nt, [["__scopeId", "data-v-6ca7b1f2"]]), Wt = {
|
|
1086
1086
|
class: "SignIn"
|
|
1087
|
-
},
|
|
1087
|
+
}, Kt = {
|
|
1088
1088
|
key: 0,
|
|
1089
1089
|
class: "tabsContainer"
|
|
1090
|
-
},
|
|
1090
|
+
}, Jt = /* @__PURE__ */ V({
|
|
1091
1091
|
__name: "AuthkitSignIn",
|
|
1092
1092
|
props: {
|
|
1093
1093
|
size: {
|
|
@@ -1104,11 +1104,11 @@ const It = {
|
|
|
1104
1104
|
setup(b, {
|
|
1105
1105
|
emit: r
|
|
1106
1106
|
}) {
|
|
1107
|
-
const u = r, o = b, h =
|
|
1108
|
-
appsData:
|
|
1107
|
+
const u = r, o = b, h = Re(), g = T(() => !!h.OAuth), {
|
|
1108
|
+
appsData: a
|
|
1109
1109
|
} = j(), {
|
|
1110
1110
|
signUpAuthEnabled: s
|
|
1111
|
-
} =
|
|
1111
|
+
} = F(), d = T(() => a.value.authMethods), v = T(() => s.value && (d.value.signUp.email || d.value.signUp.phone)), t = T(() => d.value.login.emailPassword || d.value.login.phonePassword), f = T(() => {
|
|
1112
1112
|
const y = [];
|
|
1113
1113
|
return (d.value.login.emailPassword || d.value.login.phonePassword) && y.push({
|
|
1114
1114
|
key: "password",
|
|
@@ -1137,7 +1137,7 @@ const It = {
|
|
|
1137
1137
|
...y
|
|
1138
1138
|
});
|
|
1139
1139
|
}
|
|
1140
|
-
return (y, z) => (l(), k("div",
|
|
1140
|
+
return (y, z) => (l(), k("div", Wt, [f.value.length > 1 ? (l(), k("div", Kt, [i(e(de), {
|
|
1141
1141
|
"active-key": n.value,
|
|
1142
1142
|
"onUpdate:activeKey": z[0] || (z[0] = (q) => n.value = q)
|
|
1143
1143
|
}, {
|
|
@@ -1146,38 +1146,38 @@ const It = {
|
|
|
1146
1146
|
title: q.title
|
|
1147
1147
|
}, null, 8, ["title"]))), 128))]),
|
|
1148
1148
|
_: 1
|
|
1149
|
-
}, 8, ["active-key"])])) : I("", !0), n.value === "password" && (d.value.login.emailPassword || d.value.login.phonePassword) ? (l(), S(
|
|
1149
|
+
}, 8, ["active-key"])])) : I("", !0), n.value === "password" && (d.value.login.emailPassword || d.value.login.phonePassword) ? (l(), S($t, {
|
|
1150
1150
|
key: 1,
|
|
1151
1151
|
loading: o.loading,
|
|
1152
1152
|
size: o.size,
|
|
1153
1153
|
"allow-phone": d.value.login.phonePassword,
|
|
1154
1154
|
onSubmit: m
|
|
1155
|
-
}, null, 8, ["loading", "size", "allow-phone"])) : n.value === "phoneCode" ? (l(), S(
|
|
1155
|
+
}, null, 8, ["loading", "size", "allow-phone"])) : n.value === "phoneCode" ? (l(), S(Lt, {
|
|
1156
1156
|
key: 2,
|
|
1157
1157
|
loading: o.loading,
|
|
1158
1158
|
size: o.size,
|
|
1159
1159
|
onSubmit: m
|
|
1160
|
-
}, null, 8, ["loading", "size"])) : n.value === "emailCode" ? (l(), S(
|
|
1160
|
+
}, null, 8, ["loading", "size"])) : n.value === "emailCode" ? (l(), S(Et, {
|
|
1161
1161
|
key: 3,
|
|
1162
1162
|
loading: o.loading,
|
|
1163
1163
|
size: o.size,
|
|
1164
1164
|
onSubmit: m
|
|
1165
1165
|
}, null, 8, ["loading", "size"])) : I("", !0), g.value ? Z(y.$slots, "OAuth", {
|
|
1166
1166
|
key: 4
|
|
1167
|
-
}, void 0, !0) : I("", !0),
|
|
1167
|
+
}, void 0, !0) : I("", !0), i(jt, {
|
|
1168
1168
|
"show-sign-up": v.value,
|
|
1169
1169
|
"show-reset-password": t.value,
|
|
1170
1170
|
onSwitchSignUp: w,
|
|
1171
1171
|
onSwitchResetPassword: c
|
|
1172
1172
|
}, null, 8, ["show-sign-up", "show-reset-password"])]));
|
|
1173
1173
|
}
|
|
1174
|
-
}),
|
|
1174
|
+
}), Qt = /* @__PURE__ */ U(Jt, [["__scopeId", "data-v-a7aef80e"]]), Xt = {
|
|
1175
1175
|
class: "content"
|
|
1176
|
-
}, Xt = {
|
|
1177
|
-
class: "sendVerifyCodeItem"
|
|
1178
1176
|
}, Yt = {
|
|
1177
|
+
class: "sendVerifyCodeItem"
|
|
1178
|
+
}, Zt = {
|
|
1179
1179
|
class: "handle"
|
|
1180
|
-
},
|
|
1180
|
+
}, es = /* @__PURE__ */ V({
|
|
1181
1181
|
__name: "AuthkitEmailUpdate",
|
|
1182
1182
|
props: {
|
|
1183
1183
|
size: {
|
|
@@ -1200,10 +1200,10 @@ const It = {
|
|
|
1200
1200
|
}) {
|
|
1201
1201
|
const u = r, {
|
|
1202
1202
|
useTermsFormField: o
|
|
1203
|
-
} =
|
|
1203
|
+
} = F(), {
|
|
1204
1204
|
showTermsField: h,
|
|
1205
1205
|
termsRules: g
|
|
1206
|
-
} = o("signUp"),
|
|
1206
|
+
} = o("signUp"), a = b, s = A(), d = A(!1), v = A(), t = A({
|
|
1207
1207
|
email: void 0,
|
|
1208
1208
|
userToken: void 0,
|
|
1209
1209
|
emailVerifyId: void 0,
|
|
@@ -1219,9 +1219,9 @@ const It = {
|
|
|
1219
1219
|
async function f() {
|
|
1220
1220
|
if (!await v.value.validateField(["email"])) {
|
|
1221
1221
|
d.value = !0;
|
|
1222
|
-
const c = await
|
|
1222
|
+
const c = await M().auth.verify.email.retry.post({
|
|
1223
1223
|
email: t.value.email,
|
|
1224
|
-
purpose:
|
|
1224
|
+
purpose: a.purpose
|
|
1225
1225
|
});
|
|
1226
1226
|
d.value = !1, c.data && (t.value.emailVerifyId = c.data.emailVerifyId), K(s.value, c);
|
|
1227
1227
|
}
|
|
@@ -1231,14 +1231,14 @@ const It = {
|
|
|
1231
1231
|
w || u("submit", t.value);
|
|
1232
1232
|
});
|
|
1233
1233
|
}
|
|
1234
|
-
return (w, c) => (l(), k("div",
|
|
1234
|
+
return (w, c) => (l(), k("div", Xt, [i(e(H), {
|
|
1235
1235
|
ref_key: "formRef",
|
|
1236
1236
|
ref: v,
|
|
1237
1237
|
model: t.value,
|
|
1238
|
-
size:
|
|
1238
|
+
size: a.size,
|
|
1239
1239
|
"auto-label-width": ""
|
|
1240
1240
|
}, {
|
|
1241
|
-
default: p(() => [
|
|
1241
|
+
default: p(() => [i(e(P), {
|
|
1242
1242
|
field: "email",
|
|
1243
1243
|
label: "邮箱",
|
|
1244
1244
|
"hide-label": "",
|
|
@@ -1250,7 +1250,7 @@ const It = {
|
|
|
1250
1250
|
message: "请输入有效的邮箱"
|
|
1251
1251
|
}]
|
|
1252
1252
|
}, {
|
|
1253
|
-
default: p(() => [
|
|
1253
|
+
default: p(() => [i(e(C), {
|
|
1254
1254
|
modelValue: t.value.email,
|
|
1255
1255
|
"onUpdate:modelValue": c[0] || (c[0] = (m) => t.value.email = m),
|
|
1256
1256
|
placeholder: "请输入邮箱",
|
|
@@ -1258,7 +1258,7 @@ const It = {
|
|
|
1258
1258
|
type: "email"
|
|
1259
1259
|
}, null, 8, ["modelValue"])]),
|
|
1260
1260
|
_: 1
|
|
1261
|
-
}),
|
|
1261
|
+
}), i(e(P), {
|
|
1262
1262
|
field: "userToken",
|
|
1263
1263
|
label: "验证码",
|
|
1264
1264
|
"hide-label": "",
|
|
@@ -1267,15 +1267,15 @@ const It = {
|
|
|
1267
1267
|
message: "请输入验证码"
|
|
1268
1268
|
}]
|
|
1269
1269
|
}, {
|
|
1270
|
-
default: p(() => [_("div",
|
|
1270
|
+
default: p(() => [_("div", Yt, [i(e(C), {
|
|
1271
1271
|
modelValue: t.value.userToken,
|
|
1272
1272
|
"onUpdate:modelValue": c[1] || (c[1] = (m) => t.value.userToken = m),
|
|
1273
1273
|
placeholder: "请输入验证码",
|
|
1274
1274
|
autocomplete: "one-time-code"
|
|
1275
|
-
}, null, 8, ["modelValue"]),
|
|
1275
|
+
}, null, 8, ["modelValue"]), i(W, {
|
|
1276
1276
|
ref_key: "SendVerifyCodeRef",
|
|
1277
1277
|
ref: s,
|
|
1278
|
-
size:
|
|
1278
|
+
size: a.size,
|
|
1279
1279
|
loading: d.value,
|
|
1280
1280
|
style: {
|
|
1281
1281
|
"margin-left": "10px"
|
|
@@ -1283,7 +1283,7 @@ const It = {
|
|
|
1283
1283
|
onSend: f
|
|
1284
1284
|
}, null, 8, ["size", "loading"])])]),
|
|
1285
1285
|
_: 1
|
|
1286
|
-
}),
|
|
1286
|
+
}), i(e(P), {
|
|
1287
1287
|
field: "password",
|
|
1288
1288
|
label: "密码",
|
|
1289
1289
|
"hide-label": "",
|
|
@@ -1295,7 +1295,7 @@ const It = {
|
|
|
1295
1295
|
message: "密码不能少于10字符"
|
|
1296
1296
|
}]
|
|
1297
1297
|
}, {
|
|
1298
|
-
default: p(() => [
|
|
1298
|
+
default: p(() => [i(e(C), {
|
|
1299
1299
|
modelValue: t.value.password,
|
|
1300
1300
|
"onUpdate:modelValue": c[2] || (c[2] = (m) => t.value.password = m),
|
|
1301
1301
|
placeholder: "请输入密码",
|
|
@@ -1303,7 +1303,7 @@ const It = {
|
|
|
1303
1303
|
autocomplete: "new-password"
|
|
1304
1304
|
}, null, 8, ["modelValue"])]),
|
|
1305
1305
|
_: 1
|
|
1306
|
-
}),
|
|
1306
|
+
}), i(e(P), {
|
|
1307
1307
|
field: "confirmPassword",
|
|
1308
1308
|
label: "确认密码",
|
|
1309
1309
|
"hide-label": "",
|
|
@@ -1319,7 +1319,7 @@ const It = {
|
|
|
1319
1319
|
}
|
|
1320
1320
|
}]
|
|
1321
1321
|
}, {
|
|
1322
|
-
default: p(() => [
|
|
1322
|
+
default: p(() => [i(e(C), {
|
|
1323
1323
|
modelValue: t.value.confirmPassword,
|
|
1324
1324
|
"onUpdate:modelValue": c[3] || (c[3] = (m) => t.value.confirmPassword = m),
|
|
1325
1325
|
placeholder: "请输入确认密码密码",
|
|
@@ -1327,7 +1327,7 @@ const It = {
|
|
|
1327
1327
|
autocomplete: "new-password"
|
|
1328
1328
|
}, null, 8, ["modelValue"])]),
|
|
1329
1329
|
_: 1
|
|
1330
|
-
}, 8, ["rules"]),
|
|
1330
|
+
}, 8, ["rules"]), i(e(P), {
|
|
1331
1331
|
field: "inviteCode",
|
|
1332
1332
|
label: "邀请码",
|
|
1333
1333
|
"hide-label": "",
|
|
@@ -1335,18 +1335,18 @@ const It = {
|
|
|
1335
1335
|
required: !1
|
|
1336
1336
|
}]
|
|
1337
1337
|
}, {
|
|
1338
|
-
default: p(() => [
|
|
1338
|
+
default: p(() => [i(e(C), {
|
|
1339
1339
|
modelValue: t.value.inviteCode,
|
|
1340
1340
|
"onUpdate:modelValue": c[4] || (c[4] = (m) => t.value.inviteCode = m),
|
|
1341
1341
|
placeholder: "邀请码(可选)",
|
|
1342
1342
|
autocomplete: "off"
|
|
1343
1343
|
}, null, 8, ["modelValue"])]),
|
|
1344
1344
|
_: 1
|
|
1345
|
-
}), _("div",
|
|
1345
|
+
}), _("div", Zt, [i(e(B), {
|
|
1346
1346
|
type: "primary",
|
|
1347
|
-
loading:
|
|
1347
|
+
loading: a.loading,
|
|
1348
1348
|
long: "",
|
|
1349
|
-
size:
|
|
1349
|
+
size: a.size,
|
|
1350
1350
|
onClick: n
|
|
1351
1351
|
}, {
|
|
1352
1352
|
default: p(() => [...c[6] || (c[6] = [O(" 提交 ", -1)])]),
|
|
@@ -1357,7 +1357,7 @@ const It = {
|
|
|
1357
1357
|
"hide-label": "",
|
|
1358
1358
|
rules: e(g)
|
|
1359
1359
|
}, {
|
|
1360
|
-
default: p(() => [
|
|
1360
|
+
default: p(() => [i(ee, {
|
|
1361
1361
|
"accepted-terms": t.value.acceptedTerms,
|
|
1362
1362
|
"onUpdate:acceptedTerms": c[5] || (c[5] = (m) => t.value.acceptedTerms = m),
|
|
1363
1363
|
"current-view": "signUp"
|
|
@@ -1367,15 +1367,15 @@ const It = {
|
|
|
1367
1367
|
_: 1
|
|
1368
1368
|
}, 8, ["model", "size"])]));
|
|
1369
1369
|
}
|
|
1370
|
-
}),
|
|
1370
|
+
}), ts = /* @__PURE__ */ U(es, [["__scopeId", "data-v-07ef9d49"]]), ss = {
|
|
1371
1371
|
class: "SignUpPhone"
|
|
1372
|
-
},
|
|
1372
|
+
}, is = {
|
|
1373
1373
|
class: "content"
|
|
1374
1374
|
}, as = {
|
|
1375
1375
|
class: "sendVerifyCodeItem"
|
|
1376
|
-
},
|
|
1376
|
+
}, os = {
|
|
1377
1377
|
class: "handle"
|
|
1378
|
-
},
|
|
1378
|
+
}, ls = /* @__PURE__ */ V({
|
|
1379
1379
|
__name: "AuthkitSignUpPhone",
|
|
1380
1380
|
props: {
|
|
1381
1381
|
size: {
|
|
@@ -1399,10 +1399,10 @@ const It = {
|
|
|
1399
1399
|
}) {
|
|
1400
1400
|
const u = r, {
|
|
1401
1401
|
useTermsFormField: o
|
|
1402
|
-
} =
|
|
1402
|
+
} = F(), {
|
|
1403
1403
|
showTermsField: h,
|
|
1404
1404
|
termsRules: g
|
|
1405
|
-
} = o("signUp"),
|
|
1405
|
+
} = o("signUp"), a = b, s = A(), d = A(!1), v = A(), t = A({
|
|
1406
1406
|
phone: void 0,
|
|
1407
1407
|
code: void 0,
|
|
1408
1408
|
password: void 0,
|
|
@@ -1428,7 +1428,7 @@ const It = {
|
|
|
1428
1428
|
async function w() {
|
|
1429
1429
|
if (!await v.value.validateField(["phone"])) {
|
|
1430
1430
|
d.value = !0;
|
|
1431
|
-
const y = await
|
|
1431
|
+
const y = await M().auth.verify.sms.send.post({
|
|
1432
1432
|
phone: t.value.phone,
|
|
1433
1433
|
purpose: "signUp"
|
|
1434
1434
|
});
|
|
@@ -1446,14 +1446,14 @@ const It = {
|
|
|
1446
1446
|
});
|
|
1447
1447
|
});
|
|
1448
1448
|
}
|
|
1449
|
-
return (m, y) => (l(), k("div",
|
|
1449
|
+
return (m, y) => (l(), k("div", ss, [_("div", is, [i(e(H), {
|
|
1450
1450
|
ref_key: "formRef",
|
|
1451
1451
|
ref: v,
|
|
1452
1452
|
model: t.value,
|
|
1453
|
-
size:
|
|
1453
|
+
size: a.size,
|
|
1454
1454
|
"auto-label-width": ""
|
|
1455
1455
|
}, {
|
|
1456
|
-
default: p(() => [
|
|
1456
|
+
default: p(() => [i(e(P), {
|
|
1457
1457
|
field: "phone",
|
|
1458
1458
|
label: "手机号",
|
|
1459
1459
|
"hide-label": "",
|
|
@@ -1465,7 +1465,7 @@ const It = {
|
|
|
1465
1465
|
message: "请输入有效的手机号"
|
|
1466
1466
|
}]
|
|
1467
1467
|
}, {
|
|
1468
|
-
default: p(() => [
|
|
1468
|
+
default: p(() => [i(e(C), {
|
|
1469
1469
|
modelValue: t.value.phone,
|
|
1470
1470
|
"onUpdate:modelValue": y[0] || (y[0] = (z) => t.value.phone = z),
|
|
1471
1471
|
placeholder: "请输入手机号",
|
|
@@ -1473,7 +1473,7 @@ const It = {
|
|
|
1473
1473
|
type: "tel"
|
|
1474
1474
|
}, null, 8, ["modelValue"])]),
|
|
1475
1475
|
_: 1
|
|
1476
|
-
}),
|
|
1476
|
+
}), i(e(P), {
|
|
1477
1477
|
field: "code",
|
|
1478
1478
|
label: "验证码",
|
|
1479
1479
|
"hide-label": "",
|
|
@@ -1482,15 +1482,15 @@ const It = {
|
|
|
1482
1482
|
message: "请输入验证码"
|
|
1483
1483
|
}]
|
|
1484
1484
|
}, {
|
|
1485
|
-
default: p(() => [_("div", as, [
|
|
1485
|
+
default: p(() => [_("div", as, [i(e(C), {
|
|
1486
1486
|
modelValue: t.value.code,
|
|
1487
1487
|
"onUpdate:modelValue": y[1] || (y[1] = (z) => t.value.code = z),
|
|
1488
1488
|
placeholder: "请输入验证码",
|
|
1489
1489
|
autocomplete: "one-time-code"
|
|
1490
|
-
}, null, 8, ["modelValue"]),
|
|
1490
|
+
}, null, 8, ["modelValue"]), i(W, {
|
|
1491
1491
|
ref_key: "SendVerifyCodeRef",
|
|
1492
1492
|
ref: s,
|
|
1493
|
-
size:
|
|
1493
|
+
size: a.size,
|
|
1494
1494
|
loading: d.value,
|
|
1495
1495
|
style: {
|
|
1496
1496
|
"margin-left": "10px"
|
|
@@ -1498,20 +1498,20 @@ const It = {
|
|
|
1498
1498
|
onSend: w
|
|
1499
1499
|
}, null, 8, ["size", "loading"])])]),
|
|
1500
1500
|
_: 1
|
|
1501
|
-
}),
|
|
1501
|
+
}), a.requirePassword ? (l(), S(e(P), {
|
|
1502
1502
|
key: 0,
|
|
1503
1503
|
field: "password",
|
|
1504
1504
|
label: "密码",
|
|
1505
1505
|
"hide-label": "",
|
|
1506
1506
|
rules: [{
|
|
1507
|
-
required:
|
|
1507
|
+
required: a.requirePassword,
|
|
1508
1508
|
message: "密码请输入"
|
|
1509
1509
|
}, {
|
|
1510
1510
|
minLength: 10,
|
|
1511
1511
|
message: "密码不能少于10字符"
|
|
1512
1512
|
}]
|
|
1513
1513
|
}, {
|
|
1514
|
-
default: p(() => [
|
|
1514
|
+
default: p(() => [i(e(C), {
|
|
1515
1515
|
modelValue: t.value.password,
|
|
1516
1516
|
"onUpdate:modelValue": y[2] || (y[2] = (z) => t.value.password = z),
|
|
1517
1517
|
placeholder: "请输入密码(可选)",
|
|
@@ -1519,14 +1519,14 @@ const It = {
|
|
|
1519
1519
|
autocomplete: "new-password"
|
|
1520
1520
|
}, null, 8, ["modelValue"])]),
|
|
1521
1521
|
_: 1
|
|
1522
|
-
}, 8, ["rules"])) : I("", !0),
|
|
1522
|
+
}, 8, ["rules"])) : I("", !0), a.requirePassword && t.value.password ? (l(), S(e(P), {
|
|
1523
1523
|
key: 1,
|
|
1524
1524
|
field: "confirmPassword",
|
|
1525
1525
|
label: "确认密码",
|
|
1526
1526
|
"hide-label": "",
|
|
1527
1527
|
rules: f
|
|
1528
1528
|
}, {
|
|
1529
|
-
default: p(() => [
|
|
1529
|
+
default: p(() => [i(e(C), {
|
|
1530
1530
|
modelValue: t.value.confirmPassword,
|
|
1531
1531
|
"onUpdate:modelValue": y[3] || (y[3] = (z) => t.value.confirmPassword = z),
|
|
1532
1532
|
placeholder: "请输入确认密码",
|
|
@@ -1534,7 +1534,7 @@ const It = {
|
|
|
1534
1534
|
autocomplete: "new-password"
|
|
1535
1535
|
}, null, 8, ["modelValue"])]),
|
|
1536
1536
|
_: 1
|
|
1537
|
-
})) : I("", !0),
|
|
1537
|
+
})) : I("", !0), i(e(P), {
|
|
1538
1538
|
field: "inviteCode",
|
|
1539
1539
|
label: "邀请码",
|
|
1540
1540
|
"hide-label": "",
|
|
@@ -1542,18 +1542,18 @@ const It = {
|
|
|
1542
1542
|
required: !1
|
|
1543
1543
|
}]
|
|
1544
1544
|
}, {
|
|
1545
|
-
default: p(() => [
|
|
1545
|
+
default: p(() => [i(e(C), {
|
|
1546
1546
|
modelValue: t.value.inviteCode,
|
|
1547
1547
|
"onUpdate:modelValue": y[4] || (y[4] = (z) => t.value.inviteCode = z),
|
|
1548
1548
|
placeholder: "邀请码(可选)",
|
|
1549
1549
|
autocomplete: "off"
|
|
1550
1550
|
}, null, 8, ["modelValue"])]),
|
|
1551
1551
|
_: 1
|
|
1552
|
-
}), _("div",
|
|
1552
|
+
}), _("div", os, [i(e(B), {
|
|
1553
1553
|
type: "primary",
|
|
1554
|
-
loading:
|
|
1554
|
+
loading: a.loading,
|
|
1555
1555
|
long: "",
|
|
1556
|
-
size:
|
|
1556
|
+
size: a.size,
|
|
1557
1557
|
onClick: c
|
|
1558
1558
|
}, {
|
|
1559
1559
|
default: p(() => [...y[6] || (y[6] = [O(" 注册 ", -1)])]),
|
|
@@ -1564,7 +1564,7 @@ const It = {
|
|
|
1564
1564
|
"hide-label": "",
|
|
1565
1565
|
rules: e(g)
|
|
1566
1566
|
}, {
|
|
1567
|
-
default: p(() => [
|
|
1567
|
+
default: p(() => [i(ee, {
|
|
1568
1568
|
"accepted-terms": t.value.acceptedTerms,
|
|
1569
1569
|
"onUpdate:acceptedTerms": y[5] || (y[5] = (z) => t.value.acceptedTerms = z),
|
|
1570
1570
|
"current-view": "signUp"
|
|
@@ -1572,25 +1572,25 @@ const It = {
|
|
|
1572
1572
|
_: 1
|
|
1573
1573
|
}, 8, ["rules"])) : I("", !0)])]),
|
|
1574
1574
|
_: 1
|
|
1575
|
-
}, 8, ["model", "size"])]),
|
|
1575
|
+
}, 8, ["model", "size"])]), i(me, {
|
|
1576
1576
|
onSwitchSignIn: n
|
|
1577
1577
|
})]));
|
|
1578
1578
|
}
|
|
1579
|
-
}),
|
|
1579
|
+
}), ns = /* @__PURE__ */ U(ls, [["__scopeId", "data-v-d0af58fd"]]), rs = {
|
|
1580
1580
|
class: "SignUp"
|
|
1581
|
-
},
|
|
1581
|
+
}, us = {
|
|
1582
1582
|
key: 0,
|
|
1583
1583
|
class: "tabsContainer"
|
|
1584
|
-
},
|
|
1584
|
+
}, ds = {
|
|
1585
1585
|
key: 1,
|
|
1586
1586
|
class: "empty"
|
|
1587
|
-
},
|
|
1587
|
+
}, cs = {
|
|
1588
1588
|
key: 2,
|
|
1589
1589
|
class: "empty"
|
|
1590
|
-
},
|
|
1590
|
+
}, ps = {
|
|
1591
1591
|
key: 2,
|
|
1592
1592
|
class: "empty"
|
|
1593
|
-
},
|
|
1593
|
+
}, ms = /* @__PURE__ */ V({
|
|
1594
1594
|
__name: "AuthkitSignUp",
|
|
1595
1595
|
props: {
|
|
1596
1596
|
size: {
|
|
@@ -1611,8 +1611,8 @@ const It = {
|
|
|
1611
1611
|
appsData: h
|
|
1612
1612
|
} = j(), {
|
|
1613
1613
|
registrationBlocked: g,
|
|
1614
|
-
signUpAuthEnabled:
|
|
1615
|
-
} =
|
|
1614
|
+
signUpAuthEnabled: a
|
|
1615
|
+
} = F(), s = T(() => h.value.authMethods), d = T(() => {
|
|
1616
1616
|
const n = [];
|
|
1617
1617
|
return s.value.signUp.email && n.push({
|
|
1618
1618
|
key: "email",
|
|
@@ -1635,7 +1635,7 @@ const It = {
|
|
|
1635
1635
|
...n
|
|
1636
1636
|
});
|
|
1637
1637
|
}
|
|
1638
|
-
return (n, w) => (l(), k("div",
|
|
1638
|
+
return (n, w) => (l(), k("div", rs, [d.value.length > 1 ? (l(), k("div", us, [i(e(de), {
|
|
1639
1639
|
"active-key": v.value,
|
|
1640
1640
|
"onUpdate:activeKey": w[0] || (w[0] = (c) => v.value = c)
|
|
1641
1641
|
}, {
|
|
@@ -1644,25 +1644,25 @@ const It = {
|
|
|
1644
1644
|
title: c.title
|
|
1645
1645
|
}, null, 8, ["title"]))), 128))]),
|
|
1646
1646
|
_: 1
|
|
1647
|
-
}, 8, ["active-key"])])) : I("", !0), e(
|
|
1647
|
+
}, 8, ["active-key"])])) : I("", !0), e(a) ? e(g) ? (l(), k("div", cs, " 管理员尚未配置用户协议或隐私政策,暂无法注册。 ")) : (l(), k(D, {
|
|
1648
1648
|
key: 3
|
|
1649
|
-
}, [v.value === "email" && s.value.signUp.email ? (l(), S(
|
|
1649
|
+
}, [v.value === "email" && s.value.signUp.email ? (l(), S(ts, {
|
|
1650
1650
|
key: 0,
|
|
1651
1651
|
size: o.size,
|
|
1652
1652
|
loading: b.loading,
|
|
1653
1653
|
onSubmit: f
|
|
1654
|
-
}, null, 8, ["size", "loading"])) : v.value === "phone" && s.value.signUp.phone ? (l(), S(
|
|
1654
|
+
}, null, 8, ["size", "loading"])) : v.value === "phone" && s.value.signUp.phone ? (l(), S(ns, {
|
|
1655
1655
|
key: 1,
|
|
1656
1656
|
size: o.size,
|
|
1657
1657
|
loading: b.loading,
|
|
1658
1658
|
onSubmit: f,
|
|
1659
1659
|
onSwitchSignIn: t
|
|
1660
|
-
}, null, 8, ["size", "loading"])) : (l(), k("div",
|
|
1660
|
+
}, null, 8, ["size", "loading"])) : (l(), k("div", ps, " 当前应用未开放用户注册 ")), v.value === "email" ? (l(), S(me, {
|
|
1661
1661
|
key: 3,
|
|
1662
1662
|
onSwitchSignIn: t
|
|
1663
|
-
})) : I("", !0)], 64)) : (l(), k("div",
|
|
1663
|
+
})) : I("", !0)], 64)) : (l(), k("div", ds, " 系统已停止用户注册 "))]));
|
|
1664
1664
|
}
|
|
1665
|
-
}),
|
|
1665
|
+
}), fs = /* @__PURE__ */ U(ms, [["__scopeId", "data-v-b211d5ef"]]), vs = ["src"], gs = /* @__PURE__ */ V({
|
|
1666
1666
|
__name: "AuthkitAuthTitle",
|
|
1667
1667
|
props: {
|
|
1668
1668
|
size: {
|
|
@@ -1685,28 +1685,28 @@ const It = {
|
|
|
1685
1685
|
const r = b, u = `${r.size}px`, o = `${r.fontSize}px`, h = `${r.lineHeight}px`, {
|
|
1686
1686
|
currentView: g
|
|
1687
1687
|
} = N(), {
|
|
1688
|
-
appsData:
|
|
1689
|
-
} = j(), s =
|
|
1688
|
+
appsData: a
|
|
1689
|
+
} = j(), s = T(() => g.value === "signIn" ? `${a.value.name}登录` : g.value === "signUp" ? `${a.value.name}账号注册` : g.value === "resetPassword" ? `${a.value.name}密码重置` : "");
|
|
1690
1690
|
return (d, v) => (l(), k("div", {
|
|
1691
1691
|
class: "Title",
|
|
1692
1692
|
style: G({
|
|
1693
1693
|
fontSize: o,
|
|
1694
1694
|
lineHeight: h
|
|
1695
1695
|
})
|
|
1696
|
-
}, [e(
|
|
1696
|
+
}, [e(a).applicationLogoUrl ? (l(), k("img", {
|
|
1697
1697
|
key: 0,
|
|
1698
|
-
src: e(
|
|
1698
|
+
src: e(a).applicationLogoUrl,
|
|
1699
1699
|
srcset: "",
|
|
1700
1700
|
style: G({
|
|
1701
1701
|
width: u
|
|
1702
1702
|
})
|
|
1703
|
-
}, null, 12,
|
|
1703
|
+
}, null, 12, vs)) : I("", !0), _("span", null, L(s.value), 1), Z(d.$slots, "default", {}, void 0, !0)], 4));
|
|
1704
1704
|
}
|
|
1705
|
-
}), Pe = /* @__PURE__ */ U(
|
|
1705
|
+
}), Pe = /* @__PURE__ */ U(gs, [["__scopeId", "data-v-8ebe7939"]]), hs = {
|
|
1706
1706
|
class: "Auth"
|
|
1707
|
-
},
|
|
1707
|
+
}, ys = {
|
|
1708
1708
|
class: "body"
|
|
1709
|
-
},
|
|
1709
|
+
}, bs = /* @__PURE__ */ V({
|
|
1710
1710
|
__name: "AuthkitAuth",
|
|
1711
1711
|
props: {
|
|
1712
1712
|
size: {
|
|
@@ -1724,7 +1724,7 @@ const It = {
|
|
|
1724
1724
|
passkeySignInSubmit: o,
|
|
1725
1725
|
signUpSubmit: h,
|
|
1726
1726
|
resetPasswordSubmit: g,
|
|
1727
|
-
currentView:
|
|
1727
|
+
currentView: a,
|
|
1728
1728
|
authSignInLoading: s,
|
|
1729
1729
|
authSignUpLoading: d,
|
|
1730
1730
|
resetPasswordLoading: v,
|
|
@@ -1732,11 +1732,11 @@ const It = {
|
|
|
1732
1732
|
switchResetPassword: f,
|
|
1733
1733
|
switchSignIn: n
|
|
1734
1734
|
} = N();
|
|
1735
|
-
return (w, c) => (l(), k("div",
|
|
1735
|
+
return (w, c) => (l(), k("div", hs, [b.showTitle ? (l(), S(Pe, {
|
|
1736
1736
|
key: 0,
|
|
1737
1737
|
size: 32,
|
|
1738
1738
|
"font-size": 20
|
|
1739
|
-
})) : I("", !0), _("div",
|
|
1739
|
+
})) : I("", !0), _("div", ys, [e(a) === "signIn" ? (l(), S(Qt, {
|
|
1740
1740
|
key: 0,
|
|
1741
1741
|
size: r.size,
|
|
1742
1742
|
loading: e(s),
|
|
@@ -1744,18 +1744,18 @@ const It = {
|
|
|
1744
1744
|
onSwitchResetPassword: e(f),
|
|
1745
1745
|
onSubmit: c[0] || (c[0] = (m) => e(u)(m))
|
|
1746
1746
|
}, {
|
|
1747
|
-
OAuth: p(() => [
|
|
1747
|
+
OAuth: p(() => [i(lt, {
|
|
1748
1748
|
size: r.size,
|
|
1749
1749
|
onPasskeySubmit: e(o)
|
|
1750
1750
|
}, null, 8, ["size", "onPasskeySubmit"])]),
|
|
1751
1751
|
_: 1
|
|
1752
|
-
}, 8, ["size", "loading", "onSwitchSignUp", "onSwitchResetPassword"])) : e(
|
|
1752
|
+
}, 8, ["size", "loading", "onSwitchSignUp", "onSwitchResetPassword"])) : e(a) === "signUp" ? (l(), S(fs, {
|
|
1753
1753
|
key: 1,
|
|
1754
1754
|
size: r.size,
|
|
1755
1755
|
loading: e(d),
|
|
1756
1756
|
onSwitchSignIn: e(n),
|
|
1757
1757
|
onSubmit: c[1] || (c[1] = (m) => e(h)(m))
|
|
1758
|
-
}, null, 8, ["size", "loading", "onSwitchSignIn"])) : e(
|
|
1758
|
+
}, null, 8, ["size", "loading", "onSwitchSignIn"])) : e(a) === "resetPassword" ? (l(), S(kt, {
|
|
1759
1759
|
key: 2,
|
|
1760
1760
|
size: r.size,
|
|
1761
1761
|
loading: e(v),
|
|
@@ -1763,7 +1763,7 @@ const It = {
|
|
|
1763
1763
|
onSubmit: c[2] || (c[2] = (m) => e(g)(m))
|
|
1764
1764
|
}, null, 8, ["size", "loading", "onSwitchSignIn"])) : I("", !0)])]));
|
|
1765
1765
|
}
|
|
1766
|
-
}),
|
|
1766
|
+
}), ws = /* @__PURE__ */ U(bs, [["__scopeId", "data-v-60874d88"]]), _s = /* @__PURE__ */ V({
|
|
1767
1767
|
__name: "AuthkitAuthModal",
|
|
1768
1768
|
props: {
|
|
1769
1769
|
size: {
|
|
@@ -1780,11 +1780,11 @@ const It = {
|
|
|
1780
1780
|
} = N(), {
|
|
1781
1781
|
close: g
|
|
1782
1782
|
} = we();
|
|
1783
|
-
let
|
|
1783
|
+
let a = null;
|
|
1784
1784
|
E(() => {
|
|
1785
|
-
|
|
1785
|
+
a = o(() => g());
|
|
1786
1786
|
}), ue(() => {
|
|
1787
|
-
|
|
1787
|
+
a == null || a(), a = null;
|
|
1788
1788
|
});
|
|
1789
1789
|
function s(v) {
|
|
1790
1790
|
v || d();
|
|
@@ -1792,7 +1792,7 @@ const It = {
|
|
|
1792
1792
|
function d() {
|
|
1793
1793
|
h(), g(), u("close");
|
|
1794
1794
|
}
|
|
1795
|
-
return (v, t) => (l(), S(e(
|
|
1795
|
+
return (v, t) => (l(), S(e(xe), {
|
|
1796
1796
|
visible: !0,
|
|
1797
1797
|
footer: !1,
|
|
1798
1798
|
"mask-closable": !1,
|
|
@@ -1802,22 +1802,22 @@ const It = {
|
|
|
1802
1802
|
"onUpdate:visible": s,
|
|
1803
1803
|
onClose: d
|
|
1804
1804
|
}, {
|
|
1805
|
-
title: p(() => [
|
|
1806
|
-
default: p(() => [
|
|
1805
|
+
title: p(() => [i(Pe)]),
|
|
1806
|
+
default: p(() => [i(ws, {
|
|
1807
1807
|
"show-title": !1,
|
|
1808
1808
|
size: b.size
|
|
1809
1809
|
}, null, 8, ["size"])]),
|
|
1810
1810
|
_: 1
|
|
1811
1811
|
}));
|
|
1812
1812
|
}
|
|
1813
|
-
}),
|
|
1813
|
+
}), ks = /* @__PURE__ */ U(_s, [["__scopeId", "data-v-19a4d5d0"]]);
|
|
1814
1814
|
function Ve(b, r = {}) {
|
|
1815
1815
|
const {
|
|
1816
1816
|
bindIdentityRedirect: u = "",
|
|
1817
1817
|
closePopupOnBindSuccess: o = !0,
|
|
1818
1818
|
restoreRedirectAfterSignIn: h = !0,
|
|
1819
1819
|
defaultRedirect: g = ""
|
|
1820
|
-
} = r,
|
|
1820
|
+
} = r, a = A(!1), {
|
|
1821
1821
|
completeSignIn: s
|
|
1822
1822
|
} = N();
|
|
1823
1823
|
async function d() {
|
|
@@ -1836,7 +1836,7 @@ function Ve(b, r = {}) {
|
|
|
1836
1836
|
const f = v.searchParams.get("token");
|
|
1837
1837
|
if (!f)
|
|
1838
1838
|
return !1;
|
|
1839
|
-
|
|
1839
|
+
a.value = !0;
|
|
1840
1840
|
try {
|
|
1841
1841
|
const n = v.searchParams.get("userId"), w = v.searchParams.get("appId"), c = v.searchParams.get("needBindIdentity") === "true";
|
|
1842
1842
|
if (window.history.replaceState({}, "", le(v)), s({
|
|
@@ -1846,23 +1846,23 @@ function Ve(b, r = {}) {
|
|
|
1846
1846
|
needBindIdentity: c
|
|
1847
1847
|
}), c && u)
|
|
1848
1848
|
return await b.replace(u), !0;
|
|
1849
|
-
const y =
|
|
1849
|
+
const y = Ne(h) || g;
|
|
1850
1850
|
return y && await b.replace(y), !0;
|
|
1851
1851
|
} finally {
|
|
1852
|
-
|
|
1852
|
+
a.value = !1;
|
|
1853
1853
|
}
|
|
1854
1854
|
}
|
|
1855
1855
|
return {
|
|
1856
|
-
processing:
|
|
1856
|
+
processing: a,
|
|
1857
1857
|
handleOAuthCallback: d
|
|
1858
1858
|
};
|
|
1859
1859
|
}
|
|
1860
|
-
const
|
|
1860
|
+
const Ss = {
|
|
1861
1861
|
key: 0,
|
|
1862
1862
|
class: "AuthkitOAuthCallbackOverlay",
|
|
1863
1863
|
"aria-live": "polite",
|
|
1864
1864
|
"aria-busy": "true"
|
|
1865
|
-
},
|
|
1865
|
+
}, zs = /* @__PURE__ */ V({
|
|
1866
1866
|
__name: "AuthkitOAuthCallbackProvider",
|
|
1867
1867
|
props: {
|
|
1868
1868
|
bindIdentityRedirect: {
|
|
@@ -1888,9 +1888,9 @@ const ks = {
|
|
|
1888
1888
|
});
|
|
1889
1889
|
return E(() => {
|
|
1890
1890
|
h();
|
|
1891
|
-
}), (g,
|
|
1891
|
+
}), (g, a) => (l(), S(Te, {
|
|
1892
1892
|
to: "body"
|
|
1893
|
-
}, [e(o) ? (l(), k("div",
|
|
1893
|
+
}, [e(o) ? (l(), k("div", Ss, [...a[0] || (a[0] = [_("div", {
|
|
1894
1894
|
class: "AuthkitOAuthCallbackOverlay__panel"
|
|
1895
1895
|
}, [_("div", {
|
|
1896
1896
|
class: "AuthkitOAuthCallbackOverlay__spinner"
|
|
@@ -1898,7 +1898,7 @@ const ks = {
|
|
|
1898
1898
|
class: "AuthkitOAuthCallbackOverlay__text"
|
|
1899
1899
|
}, "正在登录...")], -1)])])) : I("", !0)]));
|
|
1900
1900
|
}
|
|
1901
|
-
}),
|
|
1901
|
+
}), Is = /* @__PURE__ */ U(zs, [["__scopeId", "data-v-7162b776"]]), hi = /* @__PURE__ */ V({
|
|
1902
1902
|
__name: "AuthkitProvider",
|
|
1903
1903
|
props: {
|
|
1904
1904
|
handleOAuthCallback: {
|
|
@@ -1938,8 +1938,8 @@ const ks = {
|
|
|
1938
1938
|
}) {
|
|
1939
1939
|
const {
|
|
1940
1940
|
config: u
|
|
1941
|
-
} = pe(), o = b, h = r, g =
|
|
1942
|
-
openLegalDoc:
|
|
1941
|
+
} = pe(), o = b, h = r, g = qe(), {
|
|
1942
|
+
openLegalDoc: a
|
|
1943
1943
|
} = Ie({
|
|
1944
1944
|
route: g
|
|
1945
1945
|
}), {
|
|
@@ -1950,50 +1950,66 @@ const ks = {
|
|
|
1950
1950
|
onSignOut: t
|
|
1951
1951
|
} = N(), {
|
|
1952
1952
|
fetchUserProfile: f,
|
|
1953
|
-
clearUserProfile: n
|
|
1953
|
+
clearUserProfile: n,
|
|
1954
|
+
markAuthSessionBootstrapped: w
|
|
1954
1955
|
} = Ae(), {
|
|
1955
|
-
appsAuthPageInfoApi:
|
|
1956
|
-
} = j(),
|
|
1956
|
+
appsAuthPageInfoApi: c
|
|
1957
|
+
} = j(), m = v(() => {
|
|
1957
1958
|
f();
|
|
1958
|
-
}),
|
|
1959
|
+
}), y = t(() => {
|
|
1959
1960
|
n();
|
|
1960
1961
|
});
|
|
1961
|
-
function
|
|
1962
|
+
function z() {
|
|
1962
1963
|
if (u.legalDocsMode === "builtin") {
|
|
1963
|
-
|
|
1964
|
+
a("privacyPolicy");
|
|
1964
1965
|
return;
|
|
1965
1966
|
}
|
|
1966
1967
|
h("toPrivacyPolicy");
|
|
1967
1968
|
}
|
|
1968
|
-
function
|
|
1969
|
+
function q() {
|
|
1969
1970
|
if (u.legalDocsMode === "builtin") {
|
|
1970
|
-
|
|
1971
|
+
a("userServiceAgreement");
|
|
1971
1972
|
return;
|
|
1972
1973
|
}
|
|
1973
1974
|
h("toUserServiceAgreement");
|
|
1974
1975
|
}
|
|
1975
|
-
|
|
1976
|
-
|
|
1977
|
-
|
|
1978
|
-
|
|
1979
|
-
|
|
1976
|
+
let $ = null;
|
|
1977
|
+
async function R() {
|
|
1978
|
+
try {
|
|
1979
|
+
if (o.fetchAppInfo && c(), o.restoreSession && d()) {
|
|
1980
|
+
await f();
|
|
1981
|
+
return;
|
|
1982
|
+
}
|
|
1983
|
+
n();
|
|
1984
|
+
} finally {
|
|
1985
|
+
w();
|
|
1986
|
+
}
|
|
1987
|
+
}
|
|
1988
|
+
function x() {
|
|
1989
|
+
return $ || ($ = R()), $;
|
|
1990
|
+
}
|
|
1991
|
+
return typeof window < "u" && x(), E(() => {
|
|
1992
|
+
St({
|
|
1993
|
+
onPrivacyPolicy: z,
|
|
1994
|
+
onUserServiceAgreement: q
|
|
1995
|
+
});
|
|
1980
1996
|
}), ue(() => {
|
|
1981
|
-
|
|
1982
|
-
}), (
|
|
1997
|
+
m(), y();
|
|
1998
|
+
}), (Ce, Ws) => (l(), k(D, null, [Z(Ce.$slots, "default"), o.handleOAuthCallback ? (l(), S(Is, {
|
|
1983
1999
|
key: 0,
|
|
1984
2000
|
"bind-identity-redirect": o.bindIdentityRedirect,
|
|
1985
2001
|
"close-popup-on-bind-success": o.closePopupOnBindSuccess,
|
|
1986
2002
|
"restore-redirect-after-sign-in": o.restoreRedirectAfterSignIn
|
|
1987
|
-
}, null, 8, ["bind-identity-redirect", "close-popup-on-bind-success", "restore-redirect-after-sign-in"])) : I("", !0), o.showAuthModal && e(s) ? (l(), S(
|
|
2003
|
+
}, null, 8, ["bind-identity-redirect", "close-popup-on-bind-success", "restore-redirect-after-sign-in"])) : I("", !0), o.showAuthModal && e(s) ? (l(), S(ks, {
|
|
1988
2004
|
key: 1,
|
|
1989
2005
|
size: o.authModalSize
|
|
1990
2006
|
}, null, 8, ["size"])) : I("", !0)], 64));
|
|
1991
2007
|
}
|
|
1992
|
-
}),
|
|
2008
|
+
}), As = {
|
|
1993
2009
|
class: "header"
|
|
1994
|
-
},
|
|
2010
|
+
}, Ps = ["href"], Vs = {
|
|
1995
2011
|
class: "container"
|
|
1996
|
-
},
|
|
2012
|
+
}, Cs = /* @__PURE__ */ V({
|
|
1997
2013
|
__name: "AuthkitAuthContainer",
|
|
1998
2014
|
props: {
|
|
1999
2015
|
applicationLogoUrl: {
|
|
@@ -2036,7 +2052,7 @@ const ks = {
|
|
|
2036
2052
|
}
|
|
2037
2053
|
},
|
|
2038
2054
|
setup(b) {
|
|
2039
|
-
const r = b, u =
|
|
2055
|
+
const r = b, u = T(() => r.backgroundType === "color" ? {
|
|
2040
2056
|
backgroundColor: r.backgroundColor
|
|
2041
2057
|
} : {
|
|
2042
2058
|
backgroundImage: `url(${r.backgroundImage})`
|
|
@@ -2044,7 +2060,7 @@ const ks = {
|
|
|
2044
2060
|
return (o, h) => (l(), k("div", {
|
|
2045
2061
|
class: "auth",
|
|
2046
2062
|
style: G(u.value)
|
|
2047
|
-
}, [_("div",
|
|
2063
|
+
}, [_("div", As, [r.name ? (l(), k("a", {
|
|
2048
2064
|
key: 0,
|
|
2049
2065
|
href: r.appHomePage,
|
|
2050
2066
|
target: "_self",
|
|
@@ -2052,22 +2068,22 @@ const ks = {
|
|
|
2052
2068
|
style: G({
|
|
2053
2069
|
color: r.linkColor
|
|
2054
2070
|
})
|
|
2055
|
-
}, " 返回主页 ", 12,
|
|
2071
|
+
}, " 返回主页 ", 12, Ps)) : I("", !0)]), _("div", Vs, [Z(o.$slots, "default", {}, void 0, !0)])], 4));
|
|
2056
2072
|
}
|
|
2057
|
-
}),
|
|
2073
|
+
}), yi = /* @__PURE__ */ U(Cs, [["__scopeId", "data-v-0e13d3ff"]]), Us = {
|
|
2058
2074
|
class: "box"
|
|
2059
|
-
}, Us = {
|
|
2060
|
-
class: "title"
|
|
2061
2075
|
}, $s = {
|
|
2062
|
-
class: "
|
|
2076
|
+
class: "title"
|
|
2063
2077
|
}, Rs = {
|
|
2064
|
-
class: "
|
|
2078
|
+
class: "content"
|
|
2065
2079
|
}, Ts = {
|
|
2080
|
+
class: "redirect"
|
|
2081
|
+
}, qs = {
|
|
2066
2082
|
style: {
|
|
2067
2083
|
"font-weight": "bold",
|
|
2068
2084
|
"font-size": "12px"
|
|
2069
2085
|
}
|
|
2070
|
-
},
|
|
2086
|
+
}, Os = /* @__PURE__ */ V({
|
|
2071
2087
|
__name: "AuthkitAuthorize",
|
|
2072
2088
|
props: {
|
|
2073
2089
|
size: {
|
|
@@ -2124,45 +2140,45 @@ const ks = {
|
|
|
2124
2140
|
});
|
|
2125
2141
|
async function h() {
|
|
2126
2142
|
const {
|
|
2127
|
-
data:
|
|
2143
|
+
data: a,
|
|
2128
2144
|
error: s
|
|
2129
|
-
} = await
|
|
2130
|
-
s || !
|
|
2131
|
-
name:
|
|
2132
|
-
homePageUrl:
|
|
2145
|
+
} = await M().auth.apps.authPageInfo.post({});
|
|
2146
|
+
s || !a || (o.value = {
|
|
2147
|
+
name: a.name,
|
|
2148
|
+
homePageUrl: a.homePageUrl || "",
|
|
2133
2149
|
createAt: "",
|
|
2134
|
-
authorizationCallback:
|
|
2150
|
+
authorizationCallback: a.authorizationCallback || ""
|
|
2135
2151
|
});
|
|
2136
2152
|
}
|
|
2137
2153
|
h();
|
|
2138
2154
|
async function g() {
|
|
2139
2155
|
r.value = !0;
|
|
2140
2156
|
const {
|
|
2141
|
-
data:
|
|
2157
|
+
data: a,
|
|
2142
2158
|
error: s
|
|
2143
|
-
} = await
|
|
2159
|
+
} = await M().auth.oauth2.authorize.post({
|
|
2144
2160
|
client_id: u.clientId,
|
|
2145
2161
|
response_type: u.responseType,
|
|
2146
2162
|
scope: u.scope,
|
|
2147
2163
|
state: u.state,
|
|
2148
2164
|
redirect_uri: u.redirectUri
|
|
2149
2165
|
});
|
|
2150
|
-
if (r.value = !1, s || !
|
|
2166
|
+
if (r.value = !1, s || !a)
|
|
2151
2167
|
return;
|
|
2152
|
-
const d =
|
|
2168
|
+
const d = a;
|
|
2153
2169
|
window.location.href = d.authorizeUrl;
|
|
2154
2170
|
}
|
|
2155
|
-
return (
|
|
2156
|
-
default: p(() => [
|
|
2171
|
+
return (a, s) => (l(), k("div", Us, [_("div", $s, L(`授权 ${o.value.name}`), 1), _("div", Rs, [i(e(Le), null, {
|
|
2172
|
+
default: p(() => [i(e(ae), null, {
|
|
2157
2173
|
default: p(() => {
|
|
2158
2174
|
var d;
|
|
2159
|
-
return [
|
|
2175
|
+
return [i(e(oe), {
|
|
2160
2176
|
title: o.value.name,
|
|
2161
2177
|
description: `想要使用您的${(d = u.userInfo) == null ? void 0 : d.nickname}账户`
|
|
2162
2178
|
}, {
|
|
2163
2179
|
avatar: p(() => {
|
|
2164
2180
|
var v;
|
|
2165
|
-
return [
|
|
2181
|
+
return [i(e(te), {
|
|
2166
2182
|
shape: "square",
|
|
2167
2183
|
"image-url": (v = u.userInfo) == null ? void 0 : v.avatar
|
|
2168
2184
|
}, null, 8, ["image-url"])];
|
|
@@ -2171,12 +2187,12 @@ const ks = {
|
|
|
2171
2187
|
}, 8, ["title", "description"])];
|
|
2172
2188
|
}),
|
|
2173
2189
|
_: 1
|
|
2174
|
-
}),
|
|
2175
|
-
default: p(() => [
|
|
2190
|
+
}), i(e(ae), null, {
|
|
2191
|
+
default: p(() => [i(e(oe), {
|
|
2176
2192
|
title: "公开信息",
|
|
2177
2193
|
description: "头像、昵称"
|
|
2178
2194
|
}, {
|
|
2179
|
-
avatar: p(() => [
|
|
2195
|
+
avatar: p(() => [i(e(te), {
|
|
2180
2196
|
shape: "square"
|
|
2181
2197
|
}, {
|
|
2182
2198
|
default: p(() => [...s[0] || (s[0] = [_("img", {
|
|
@@ -2188,12 +2204,12 @@ const ks = {
|
|
|
2188
2204
|
_: 1
|
|
2189
2205
|
})]),
|
|
2190
2206
|
_: 1
|
|
2191
|
-
}),
|
|
2192
|
-
default: p(() => [
|
|
2207
|
+
}), i(e(ae), null, {
|
|
2208
|
+
default: p(() => [i(e(oe), {
|
|
2193
2209
|
title: "个人用户数据",
|
|
2194
2210
|
description: "电子邮件地址"
|
|
2195
2211
|
}, {
|
|
2196
|
-
avatar: p(() => [
|
|
2212
|
+
avatar: p(() => [i(e(te), {
|
|
2197
2213
|
shape: "square"
|
|
2198
2214
|
}, {
|
|
2199
2215
|
default: p(() => [...s[1] || (s[1] = [_("img", {
|
|
@@ -2207,7 +2223,7 @@ const ks = {
|
|
|
2207
2223
|
_: 1
|
|
2208
2224
|
})]),
|
|
2209
2225
|
_: 1
|
|
2210
|
-
}),
|
|
2226
|
+
}), i(e(B), {
|
|
2211
2227
|
type: "primary",
|
|
2212
2228
|
size: u.size,
|
|
2213
2229
|
loading: r.value,
|
|
@@ -2215,22 +2231,22 @@ const ks = {
|
|
|
2215
2231
|
}, {
|
|
2216
2232
|
default: p(() => [...s[2] || (s[2] = [O(" 授权 ", -1)])]),
|
|
2217
2233
|
_: 1
|
|
2218
|
-
}, 8, ["size", "loading"]), _("div",
|
|
2234
|
+
}, 8, ["size", "loading"]), _("div", Ts, [s[3] || (s[3] = _("div", {
|
|
2219
2235
|
class: "redirect-hint"
|
|
2220
|
-
}, "授权后将跳转至", -1)), _("div",
|
|
2236
|
+
}, "授权后将跳转至", -1)), _("div", qs, L(o.value.authorizationCallback), 1)])])]));
|
|
2221
2237
|
}
|
|
2222
|
-
}),
|
|
2238
|
+
}), bi = /* @__PURE__ */ U(Os, [["__scopeId", "data-v-6c1792d3"]]), xs = {
|
|
2223
2239
|
class: "oauth-callback"
|
|
2224
|
-
},
|
|
2240
|
+
}, Ls = {
|
|
2225
2241
|
key: 0,
|
|
2226
2242
|
class: "callback-loading"
|
|
2227
|
-
},
|
|
2243
|
+
}, Bs = {
|
|
2228
2244
|
key: 1,
|
|
2229
2245
|
class: "callback-error"
|
|
2230
|
-
},
|
|
2246
|
+
}, Ms = {
|
|
2231
2247
|
key: 2,
|
|
2232
2248
|
class: "callback-success"
|
|
2233
|
-
},
|
|
2249
|
+
}, Fs = /* @__PURE__ */ V({
|
|
2234
2250
|
__name: "AuthkitOauthCallback",
|
|
2235
2251
|
props: {
|
|
2236
2252
|
defaultRedirect: {},
|
|
@@ -2242,7 +2258,7 @@ const ks = {
|
|
|
2242
2258
|
emit: r
|
|
2243
2259
|
}) {
|
|
2244
2260
|
const u = b, o = r, h = A("登录成功,正在跳转..."), g = A(""), {
|
|
2245
|
-
restoreSession:
|
|
2261
|
+
restoreSession: a
|
|
2246
2262
|
} = N(), s = be(), {
|
|
2247
2263
|
processing: d,
|
|
2248
2264
|
handleOAuthCallback: v
|
|
@@ -2253,7 +2269,7 @@ const ks = {
|
|
|
2253
2269
|
async function t() {
|
|
2254
2270
|
const n = new URL(window.location.href);
|
|
2255
2271
|
if (!ze(n)) {
|
|
2256
|
-
if (
|
|
2272
|
+
if (a()) {
|
|
2257
2273
|
await s.replace(u.defaultRedirect || "/");
|
|
2258
2274
|
return;
|
|
2259
2275
|
}
|
|
@@ -2272,28 +2288,28 @@ const ks = {
|
|
|
2272
2288
|
}
|
|
2273
2289
|
return E(() => {
|
|
2274
2290
|
t();
|
|
2275
|
-
}), (n, w) => (l(), k("div",
|
|
2291
|
+
}), (n, w) => (l(), k("div", xs, [e(d) ? (l(), k("div", Ls, [w[0] || (w[0] = _("div", {
|
|
2276
2292
|
class: "spinner"
|
|
2277
|
-
}, null, -1)), _("p", null,
|
|
2293
|
+
}, null, -1)), _("p", null, L(u.loadingText ?? "正在登录..."), 1)])) : g.value ? (l(), k("div", Bs, [w[1] || (w[1] = _("div", {
|
|
2278
2294
|
class: "error-icon"
|
|
2279
|
-
}, "✕", -1)), w[2] || (w[2] = _("h2", null, "登录失败", -1)), _("p", null,
|
|
2295
|
+
}, "✕", -1)), w[2] || (w[2] = _("h2", null, "登录失败", -1)), _("p", null, L(g.value), 1), _("button", {
|
|
2280
2296
|
class: "retry-btn",
|
|
2281
2297
|
type: "button",
|
|
2282
2298
|
onClick: f
|
|
2283
|
-
}, "返回重试")])) : (l(), k("div",
|
|
2299
|
+
}, "返回重试")])) : (l(), k("div", Ms, [w[3] || (w[3] = _("div", {
|
|
2284
2300
|
class: "success-icon"
|
|
2285
|
-
}, "✓", -1)), _("p", null,
|
|
2301
|
+
}, "✓", -1)), _("p", null, L(h.value), 1)]))]));
|
|
2286
2302
|
}
|
|
2287
|
-
}),
|
|
2303
|
+
}), wi = /* @__PURE__ */ U(Fs, [["__scopeId", "data-v-98babf68"]]), Ds = {
|
|
2288
2304
|
class: "oauth-binding-account"
|
|
2289
|
-
},
|
|
2305
|
+
}, Es = {
|
|
2290
2306
|
key: 1,
|
|
2291
2307
|
class: "oauth-binding-account__icon"
|
|
2292
|
-
}, Es = {
|
|
2293
|
-
class: "oauth-binding-account__info"
|
|
2294
2308
|
}, Hs = {
|
|
2309
|
+
class: "oauth-binding-account__info"
|
|
2310
|
+
}, Gs = {
|
|
2295
2311
|
class: "oauth-binding-account__name"
|
|
2296
|
-
},
|
|
2312
|
+
}, Ns = /* @__PURE__ */ V({
|
|
2297
2313
|
__name: "AuthkitGithubBinding",
|
|
2298
2314
|
props: {
|
|
2299
2315
|
size: {
|
|
@@ -2308,8 +2324,8 @@ const ks = {
|
|
|
2308
2324
|
userProfile: u,
|
|
2309
2325
|
fetchUserProfile: o
|
|
2310
2326
|
} = Ae(), h = A("hidden"), g = A(!1);
|
|
2311
|
-
let
|
|
2312
|
-
const s = b, d =
|
|
2327
|
+
let a;
|
|
2328
|
+
const s = b, d = T(() => {
|
|
2313
2329
|
var m, y, z;
|
|
2314
2330
|
return ((y = (m = u.value) == null ? void 0 : m.github) == null ? void 0 : y.avatar_url) || ((z = u.value) == null ? void 0 : z.avatar) || "";
|
|
2315
2331
|
}), {
|
|
@@ -2327,7 +2343,7 @@ const ks = {
|
|
|
2327
2343
|
const {
|
|
2328
2344
|
data: y,
|
|
2329
2345
|
error: z
|
|
2330
|
-
} = await
|
|
2346
|
+
} = await M().auth.oauth.github.login.get({
|
|
2331
2347
|
appId: m,
|
|
2332
2348
|
mode: "bind",
|
|
2333
2349
|
redirectUri: v()
|
|
@@ -2337,7 +2353,7 @@ const ks = {
|
|
|
2337
2353
|
async function n() {
|
|
2338
2354
|
const {
|
|
2339
2355
|
error: m
|
|
2340
|
-
} = await
|
|
2356
|
+
} = await M().auth.users.unbind.oauth.post({
|
|
2341
2357
|
provider: "github"
|
|
2342
2358
|
});
|
|
2343
2359
|
m || (X.success("解绑成功"), h.value = "hidden", o());
|
|
@@ -2349,19 +2365,19 @@ const ks = {
|
|
|
2349
2365
|
g.value && o();
|
|
2350
2366
|
}
|
|
2351
2367
|
return E(() => {
|
|
2352
|
-
u.value || o(),
|
|
2368
|
+
u.value || o(), a = setInterval(c, 1e3);
|
|
2353
2369
|
}), ue(() => {
|
|
2354
|
-
|
|
2370
|
+
a && clearInterval(a);
|
|
2355
2371
|
}), (m, y) => {
|
|
2356
|
-
var z, q,
|
|
2372
|
+
var z, q, $;
|
|
2357
2373
|
return l(), k(D, null, [!((z = e(u)) != null && z.github) && h.value === "hidden" ? (l(), S(e(fe), {
|
|
2358
2374
|
key: 0,
|
|
2359
2375
|
title: "绑定GitHub"
|
|
2360
2376
|
}, {
|
|
2361
|
-
action: p(() => [
|
|
2377
|
+
action: p(() => [i(e(B), {
|
|
2362
2378
|
size: s.size,
|
|
2363
2379
|
type: "primary",
|
|
2364
|
-
onClick: y[0] || (y[0] = (
|
|
2380
|
+
onClick: y[0] || (y[0] = (R) => t("bind"))
|
|
2365
2381
|
}, {
|
|
2366
2382
|
default: p(() => [...y[2] || (y[2] = [O(" 绑定GitHub ", -1)])]),
|
|
2367
2383
|
_: 1
|
|
@@ -2372,110 +2388,110 @@ const ks = {
|
|
|
2372
2388
|
key: 1,
|
|
2373
2389
|
title: "解绑GitHub"
|
|
2374
2390
|
}, {
|
|
2375
|
-
action: p(() => [
|
|
2391
|
+
action: p(() => [i(e(B), {
|
|
2376
2392
|
size: s.size,
|
|
2377
2393
|
type: "primary",
|
|
2378
|
-
onClick: y[1] || (y[1] = (
|
|
2394
|
+
onClick: y[1] || (y[1] = (R) => t("unbind"))
|
|
2379
2395
|
}, {
|
|
2380
2396
|
default: p(() => [...y[5] || (y[5] = [O(" 解绑GitHub ", -1)])]),
|
|
2381
2397
|
_: 1
|
|
2382
2398
|
}, 8, ["size"])]),
|
|
2383
2399
|
default: p(() => {
|
|
2384
|
-
var
|
|
2385
|
-
return [_("div",
|
|
2400
|
+
var R, x;
|
|
2401
|
+
return [_("div", Ds, [d.value ? (l(), S(e(te), {
|
|
2386
2402
|
key: 0,
|
|
2387
2403
|
class: "oauth-binding-account__avatar",
|
|
2388
2404
|
"image-url": d.value,
|
|
2389
2405
|
size: 42
|
|
2390
|
-
}, null, 8, ["image-url"])) : (l(), k("div",
|
|
2406
|
+
}, null, 8, ["image-url"])) : (l(), k("div", Es, [i(_e, {
|
|
2391
2407
|
icon: e(Q).github,
|
|
2392
|
-
size: e(
|
|
2408
|
+
size: e(je),
|
|
2393
2409
|
alt: "GitHub"
|
|
2394
|
-
}, null, 8, ["icon", "size"])])), _("div",
|
|
2410
|
+
}, null, 8, ["icon", "size"])])), _("div", Hs, [y[4] || (y[4] = _("div", {
|
|
2395
2411
|
class: "oauth-binding-account__provider"
|
|
2396
|
-
}, "GitHub", -1)), _("div",
|
|
2412
|
+
}, "GitHub", -1)), _("div", Gs, L(((x = (R = e(u)) == null ? void 0 : R.github) == null ? void 0 : x.login) || "GitHub"), 1)])])];
|
|
2397
2413
|
}),
|
|
2398
2414
|
_: 1
|
|
2399
|
-
})) : I("", !0), h.value === "bind" || h.value === "unbind" ? (l(), S(
|
|
2415
|
+
})) : I("", !0), h.value === "bind" || h.value === "unbind" ? (l(), S(We, {
|
|
2400
2416
|
key: 2,
|
|
2401
2417
|
size: s.size,
|
|
2402
|
-
email: (
|
|
2418
|
+
email: ($ = e(u)) == null ? void 0 : $.email,
|
|
2403
2419
|
onNext: w
|
|
2404
2420
|
}, null, 8, ["size", "email"])) : I("", !0)], 64);
|
|
2405
2421
|
};
|
|
2406
2422
|
}
|
|
2407
|
-
}),
|
|
2423
|
+
}), _i = /* @__PURE__ */ U(Ns, [["__scopeId", "data-v-1cfa8892"]]), js = /* @__PURE__ */ V({
|
|
2408
2424
|
__name: "LegalDocViewer",
|
|
2409
2425
|
props: {
|
|
2410
2426
|
type: {},
|
|
2411
2427
|
appId: {}
|
|
2412
2428
|
},
|
|
2413
2429
|
setup(b) {
|
|
2414
|
-
const r = b, u =
|
|
2430
|
+
const r = b, u = T(() => Ke[r.type] ?? ""), o = A(!1), h = A(null);
|
|
2415
2431
|
async function g() {
|
|
2416
2432
|
if (!r.type || !r.appId) {
|
|
2417
2433
|
h.value = null;
|
|
2418
2434
|
return;
|
|
2419
2435
|
}
|
|
2420
2436
|
o.value = !0;
|
|
2421
|
-
const
|
|
2422
|
-
if (o.value = !1, !
|
|
2437
|
+
const a = await Ye(r.appId);
|
|
2438
|
+
if (o.value = !1, !a) {
|
|
2423
2439
|
h.value = null;
|
|
2424
2440
|
return;
|
|
2425
2441
|
}
|
|
2426
|
-
const s =
|
|
2427
|
-
h.value =
|
|
2442
|
+
const s = a[r.type];
|
|
2443
|
+
h.value = Je(s) ? s : null;
|
|
2428
2444
|
}
|
|
2429
2445
|
return ye(() => [r.type, r.appId], () => {
|
|
2430
2446
|
g();
|
|
2431
2447
|
}, {
|
|
2432
2448
|
immediate: !0
|
|
2433
|
-
}), (
|
|
2449
|
+
}), (a, s) => o.value ? (l(), S(e(Be), {
|
|
2434
2450
|
key: 0,
|
|
2435
2451
|
loading: o.value,
|
|
2436
2452
|
class: "legal-doc-viewer-loading"
|
|
2437
|
-
}, null, 8, ["loading"])) : h.value ? (l(), S(e(
|
|
2453
|
+
}, null, 8, ["loading"])) : h.value ? (l(), S(e(Qe), {
|
|
2438
2454
|
key: 2,
|
|
2439
2455
|
modelValue: h.value,
|
|
2440
2456
|
"onUpdate:modelValue": s[1] || (s[1] = (d) => h.value = d),
|
|
2441
2457
|
editable: !1
|
|
2442
2458
|
}, {
|
|
2443
|
-
title: p(() => [
|
|
2459
|
+
title: p(() => [i(e(Xe), {
|
|
2444
2460
|
modelValue: u.value,
|
|
2445
2461
|
"onUpdate:modelValue": s[0] || (s[0] = (d) => u.value = d),
|
|
2446
2462
|
editable: !1,
|
|
2447
2463
|
class: "legal-doc-viewer-title"
|
|
2448
2464
|
}, null, 8, ["modelValue"])]),
|
|
2449
2465
|
_: 1
|
|
2450
|
-
}, 8, ["modelValue"])) : (l(), S(e(
|
|
2466
|
+
}, 8, ["modelValue"])) : (l(), S(e(Me), {
|
|
2451
2467
|
key: 1,
|
|
2452
2468
|
description: "暂无内容"
|
|
2453
2469
|
}));
|
|
2454
2470
|
}
|
|
2455
|
-
}),
|
|
2471
|
+
}), ki = /* @__PURE__ */ U(js, [["__scopeId", "data-v-fe9a3621"]]);
|
|
2456
2472
|
export {
|
|
2457
|
-
|
|
2458
|
-
|
|
2459
|
-
|
|
2473
|
+
ws as A,
|
|
2474
|
+
ts as E,
|
|
2475
|
+
ki as L,
|
|
2460
2476
|
J as O,
|
|
2461
|
-
|
|
2462
|
-
|
|
2477
|
+
$t as P,
|
|
2478
|
+
kt as R,
|
|
2463
2479
|
ee as S,
|
|
2464
|
-
|
|
2465
|
-
|
|
2466
|
-
|
|
2480
|
+
hi as _,
|
|
2481
|
+
yi as a,
|
|
2482
|
+
ks as b,
|
|
2467
2483
|
Pe as c,
|
|
2468
|
-
|
|
2469
|
-
|
|
2470
|
-
|
|
2471
|
-
|
|
2472
|
-
|
|
2473
|
-
|
|
2474
|
-
|
|
2475
|
-
|
|
2476
|
-
|
|
2477
|
-
|
|
2478
|
-
|
|
2484
|
+
bi as d,
|
|
2485
|
+
_i as e,
|
|
2486
|
+
Is as f,
|
|
2487
|
+
wi as g,
|
|
2488
|
+
lt as h,
|
|
2489
|
+
ct as i,
|
|
2490
|
+
vt as j,
|
|
2491
|
+
Qt as k,
|
|
2492
|
+
Lt as l,
|
|
2493
|
+
fs as m,
|
|
2494
|
+
ns as n,
|
|
2479
2495
|
me as o,
|
|
2480
|
-
|
|
2496
|
+
jt as p
|
|
2481
2497
|
};
|