@huyooo/ui 1.0.7 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (74) hide show
  1. package/dist/AuthkitAppSetting-rtYZcSAR.js +2677 -0
  2. package/dist/{Contact-BWuVR9ho.js → Contact-CcWf3UEZ.js} +9 -9
  3. package/dist/{CustomTable-BzGfaAVH.js → CustomTable-HDwqEcmB.js} +1 -1
  4. package/dist/FeedbackModal.vue_vue_type_script_setup_true_lang-DpOmbAg-.js +1491 -0
  5. package/dist/{LegalDocViewer-DM8FYBpf.js → LegalDocViewer-C0tsIbz9.js} +747 -748
  6. package/dist/MessageHandle-BUufez4S.js +1233 -0
  7. package/dist/{MessageList-Ce-_LNTk.js → MessageList-rttvPmxV.js} +4 -4
  8. package/dist/PaySubscriptions-p75aBnHm.js +1331 -0
  9. package/dist/{PricingPlans-CV97ck9p.js → PricingPlans-CQ0qk9Hb.js} +99 -105
  10. package/dist/{ReferrerReferees-DgygiIiE.js → ReferrerReferees-BU9IEQgz.js} +47 -46
  11. package/dist/Upload.vue_vue_type_script_setup_true_lang-bh0NFq9E.js +78 -0
  12. package/dist/{UserMenuInvitationsItem.vue_vue_type_script_setup_true_lang-0Td42Nb3.js → UserMenuInvitationsItem.vue_vue_type_script_setup_true_lang-DG4AuHiO.js} +64 -65
  13. package/dist/WidthContainer-DSE4QbW0.js +717 -0
  14. package/dist/api/billingSubscriptionApi.d.ts +4 -1
  15. package/dist/apiClients-Ctcq8NZs.js +245 -0
  16. package/dist/authkit.js +10 -10
  17. package/dist/common/globalConfig.d.ts +36 -18
  18. package/dist/common.js +2 -2
  19. package/dist/components/Authkit/Auth/AuthkitOauthCallback.vue.d.ts +2 -2
  20. package/dist/components/Authkit/AuthkitProvider.vue.d.ts +0 -5
  21. package/dist/components/Upload/Upload.vue.d.ts +6 -6
  22. package/dist/composables/Authkit/useAuthkitAuth.d.ts +3 -0
  23. package/dist/composables/Billing/usePaymentReturn.d.ts +1 -0
  24. package/dist/composables/uploadFeedbackAttachment.d.ts +2 -1
  25. package/dist/composables/useMessageList.d.ts +2 -1
  26. package/dist/composables.d.ts +2 -2
  27. package/dist/composables.js +46 -46
  28. package/dist/feedback.js +2 -2
  29. package/dist/{fetchAuthPageAboutUs-dzTSwRsB.js → fetchAuthPageAboutUs-DiCqMUX3.js} +4 -4
  30. package/dist/{index-BkLvw1PU.js → index-Cn6LcfZO.js} +1 -1
  31. package/dist/legalDocs/resolveAppId.d.ts +1 -1
  32. package/dist/main.d.ts +4 -3
  33. package/dist/main.js +464 -469
  34. package/dist/message.js +53 -52
  35. package/dist/pay.js +4 -4
  36. package/dist/privateCom.js +1 -1
  37. package/dist/referrer.js +1 -1
  38. package/dist/{useUploadCos-C8BqFPkx.js → runtime-BzCSCUNv.js} +2712 -2609
  39. package/dist/runtime.d.ts +18 -0
  40. package/dist/style.css +1 -1
  41. package/dist/types/api/auth.generated.d.ts +0 -10
  42. package/dist/upload/browserCosTransport.d.ts +25 -0
  43. package/dist/upload/browserUploadService.d.ts +20 -0
  44. package/dist/upload.d.ts +2 -1
  45. package/dist/upload.js +5 -4
  46. package/dist/{useAuthkitAppsAuthPageInfo-CNudJd04.js → useAuthkitAppsAuthPageInfo-DZ1p-P3Q.js} +18 -21
  47. package/dist/useAuthkitAuth-BPTZUSkM.js +272 -0
  48. package/dist/{useAuthkitCreateAndUpdate-BsINsI-E.js → useAuthkitCreateAndUpdate-Bbv7vZZn.js} +1 -1
  49. package/dist/useAuthkitUsersProfile-CW_exa7E.js +39 -0
  50. package/dist/useBillingStatusOptions-Br-iL77Z.js +61 -0
  51. package/dist/{useEnsureAuthenticated-DNkCCy_Y.js → useEnsureAuthenticated-CncOvj2H.js} +2 -2
  52. package/dist/{useLegalDocs-DQP_Yq6B.js → useLegalDocs-D44qU_q0.js} +25 -25
  53. package/dist/useMessageNotifications-D9uikt21.js +80 -0
  54. package/dist/{useRoutePermission-CEiya9AM.js → useRoutePermission-BrQX7NTq.js} +2 -2
  55. package/dist/{useSEO-CDWxbk8B.js → useSEO-_TNouXE_.js} +89 -86
  56. package/dist/useSubscriptionCheckout-BDDCRxSs.js +353 -0
  57. package/dist/user.js +1 -1
  58. package/dist/utils/apiClients.d.ts +20 -12
  59. package/dist/utils/apiMiddlewares.d.ts +9 -23
  60. package/package.json +1 -1
  61. package/dist/AuthkitAppSetting-BN8-xgNq.js +0 -2674
  62. package/dist/FeedbackModal.vue_vue_type_script_setup_true_lang-DrL_XBqf.js +0 -1481
  63. package/dist/MessageHandle-mEkCsv9e.js +0 -1173
  64. package/dist/PaySubscriptions-CXkEjqr2.js +0 -1326
  65. package/dist/Upload.vue_vue_type_script_setup_true_lang-VGh2V4o0.js +0 -76
  66. package/dist/WidthContainer-CFMQRsCy.js +0 -721
  67. package/dist/apiClients-BcXOLuYu.js +0 -272
  68. package/dist/composables/Upload/useUploadCos.d.ts +0 -12
  69. package/dist/useAuthkitAuth-3m0yW6uP.js +0 -267
  70. package/dist/useAuthkitUsersProfile-DJlMsftY.js +0 -40
  71. package/dist/useBillingStatusOptions-CfHQOFNw.js +0 -71
  72. package/dist/useMessageNotifications-CAphguOm.js +0 -75
  73. package/dist/useSubscriptionCheckout-d_M_rKRa.js +0 -368
  74. package/dist/utils/billingFetch.d.ts +0 -1
@@ -1,20 +1,20 @@
1
1
  /* empty css */
2
2
  /* empty css */
3
- import "./index-BkLvw1PU.js";
4
- import { defineComponent as p, computed as b, openBlock as r, createElementBlock as _, toDisplayString as h, createCommentVNode as U, createVNode as f, unref as t, createBlock as v, withCtx as g, createTextVNode as k, ref as C, createElementVNode as c, watch as x, onMounted as ee, Fragment as q, renderSlot as A, normalizeClass as ne } from "vue";
3
+ import "./index-Cn6LcfZO.js";
4
+ import { defineComponent as p, computed as b, openBlock as r, createElementBlock as _, toDisplayString as h, createCommentVNode as U, createVNode as f, unref as t, createBlock as v, withCtx as g, createTextVNode as k, ref as C, createElementVNode as d, watch as x, onMounted as ee, Fragment as q, renderSlot as A, normalizeClass as ne } from "vue";
5
5
  import { Avatar as G, Button as N, Dropdown as te, Badge as ae } from "@arco-design/web-vue";
6
- import { u as H } from "./useAuthkitUsersProfile-DJlMsftY.js";
6
+ import { u as R } from "./useAuthkitUsersProfile-CW_exa7E.js";
7
7
  import { u as y } from "./useUserMenu-ClPBlvaM.js";
8
8
  /* empty css */
9
- import { g as J, a as se, R as oe } from "./ReferrerReferees-DgygiIiE.js";
9
+ import { g as J, a as se, R as oe } from "./ReferrerReferees-BU9IEQgz.js";
10
10
  import { _ as S } from "./_plugin-vue_export-helper-CHgC5LLL.js";
11
11
  /* empty css */
12
- import { u as ie } from "./apiClients-BcXOLuYu.js";
13
- import { f as re, u as le, g as ue, c as ce, s as de, P as pe } from "./PaySubscriptions-CXkEjqr2.js";
14
- import { d as me } from "./useBillingStatusOptions-CfHQOFNw.js";
15
- import { A as fe } from "./AuthkitAppSetting-BN8-xgNq.js";
16
- import { c as _e, u as K } from "./FeedbackModal.vue_vue_type_script_setup_true_lang-DrL_XBqf.js";
17
- import { M as ve } from "./MessageHandle-mEkCsv9e.js";
12
+ import { u as ie } from "./apiClients-Ctcq8NZs.js";
13
+ import { f as re, u as le, g as ue, c as ce, s as de, P as pe } from "./PaySubscriptions-p75aBnHm.js";
14
+ import { d as me } from "./useBillingStatusOptions-Br-iL77Z.js";
15
+ import { A as fe } from "./AuthkitAppSetting-rtYZcSAR.js";
16
+ import { c as _e, u as K } from "./FeedbackModal.vue_vue_type_script_setup_true_lang-DpOmbAg-.js";
17
+ import { M as ve } from "./MessageHandle-BUufez4S.js";
18
18
  import "./Menu-uCexrsKP.js";
19
19
  import { Icon as ge } from "@iconify/vue";
20
20
  const be = {
@@ -77,26 +77,25 @@ const be = {
77
77
  function he(n, e) {
78
78
  return r(), _("div", $e);
79
79
  }
80
- const Me = /* @__PURE__ */ S(Be, [["render", he], ["__scopeId", "data-v-c7d18d97"]]), R = C(0);
80
+ const Me = /* @__PURE__ */ S(Be, [["render", he], ["__scopeId", "data-v-c7d18d97"]]), Y = C(0);
81
81
  let P = null;
82
82
  function Ce() {
83
83
  async function n() {
84
84
  return P || (P = (async () => {
85
- const e = await me.productOptions();
86
- if (!Array.isArray(e)) {
87
- R.value = 0;
88
- return;
89
- }
90
- R.value = e.filter((o) => {
91
- var a;
92
- return (a = o.prices) == null ? void 0 : a.some((i) => i.type === "recurring");
93
- }).length;
85
+ const {
86
+ data: e,
87
+ error: o
88
+ } = await me.productOptions();
89
+ o || !Array.isArray(e) || (Y.value = e.filter((a) => {
90
+ var i;
91
+ return (i = a.prices) == null ? void 0 : i.some((c) => c.type === "recurring");
92
+ }).length);
94
93
  })().finally(() => {
95
94
  P = null;
96
95
  }), P);
97
96
  }
98
97
  return {
99
- paidProductCount: R,
98
+ paidProductCount: Y,
100
99
  loadPaidProductCount: n
101
100
  };
102
101
  }
@@ -133,11 +132,11 @@ const xe = {
133
132
  email: e.email,
134
133
  phone: e.phone
135
134
  })), a = b(() => J(o.value)), i = b(() => se(o.value));
136
- return (d, s) => (r(), _("div", xe, [f(t(G), {
135
+ return (c, s) => (r(), _("div", xe, [f(t(G), {
137
136
  "image-url": n.avatarUrl,
138
137
  size: n.avatarSize,
139
138
  "object-fit": "cover"
140
- }, null, 8, ["image-url", "size"]), c("div", Ae, [c("span", {
139
+ }, null, 8, ["image-url", "size"]), d("div", Ae, [d("span", {
141
140
  class: "UserBasicInformation__nickname",
142
141
  title: a.value
143
142
  }, h(a.value), 9, we), i.value ? (r(), _("span", {
@@ -192,9 +191,9 @@ const xe = {
192
191
  emit: e
193
192
  }) {
194
193
  const o = n, a = e, i = b(() => re(o.pointsBalance));
195
- return (d, s) => (r(), _("div", Ne, [c("div", Re, [c("div", He, [s[3] || (s[3] = c("span", {
194
+ return (c, s) => (r(), _("div", Ne, [d("div", Re, [d("div", He, [s[3] || (s[3] = d("span", {
196
195
  class: "UserSubscriptionBaseInformation__label"
197
- }, "当前权益:", -1)), c("span", {
196
+ }, "当前权益:", -1)), d("span", {
198
197
  class: "UserSubscriptionBaseInformation__value",
199
198
  title: n.currentVersionName
200
199
  }, h(n.currentVersionName), 9, Oe)]), n.canUpgrade ? (r(), v(t(N), {
@@ -207,14 +206,14 @@ const xe = {
207
206
  }, {
208
207
  default: g(() => [k(h(n.actionLabel), 1)]),
209
208
  _: 1
210
- }, 8, ["loading"])) : U("", !0)]), n.expireDate ? (r(), _("div", Ve, [s[4] || (s[4] = c("span", {
209
+ }, 8, ["loading"])) : U("", !0)]), n.expireDate ? (r(), _("div", Ve, [s[4] || (s[4] = d("span", {
211
210
  class: "UserSubscriptionBaseInformation__label"
212
- }, "有效期至:", -1)), c("span", {
211
+ }, "有效期至:", -1)), d("span", {
213
212
  class: "UserSubscriptionBaseInformation__value",
214
213
  title: n.expireDate
215
- }, h(n.expireDate), 9, ze)])) : U("", !0), c("div", Te, [c("div", Le, [s[5] || (s[5] = c("span", {
214
+ }, h(n.expireDate), 9, ze)])) : U("", !0), d("div", Te, [d("div", Le, [s[5] || (s[5] = d("span", {
216
215
  class: "UserSubscriptionBaseInformation__label"
217
- }, "积分余额:", -1)), c("span", Ee, h(i.value), 1)]), f(t(N), {
216
+ }, "积分余额:", -1)), d("span", Ee, h(i.value), 1)]), f(t(N), {
218
217
  type: "primary",
219
218
  size: "mini",
220
219
  class: "UserSubscriptionBaseInformation__action",
@@ -223,7 +222,7 @@ const xe = {
223
222
  }, {
224
223
  default: g(() => [...s[6] || (s[6] = [k(" 充值 ", -1)])]),
225
224
  _: 1
226
- }, 8, ["loading"])]), typeof n.pendingInvoiceTotal == "number" && n.pendingInvoiceTotal > 0 ? (r(), _("div", je, [s[8] || (s[8] = c("span", {
225
+ }, 8, ["loading"])]), typeof n.pendingInvoiceTotal == "number" && n.pendingInvoiceTotal > 0 ? (r(), _("div", je, [s[8] || (s[8] = d("span", {
227
226
  class: "UserSubscriptionBaseInformation__warning"
228
227
  }, "有待支付订阅账单", -1)), f(t(N), {
229
228
  type: "primary",
@@ -258,11 +257,11 @@ const xe = {
258
257
  setup(n) {
259
258
  const e = n, {
260
259
  userProfile: o
261
- } = H(), {
260
+ } = R(), {
262
261
  isOpen: a,
263
262
  openSubscriptions: i
264
263
  } = y(), {
265
- entitlement: d,
264
+ entitlement: c,
266
265
  pointsBalance: s,
267
266
  pendingInvoice: l,
268
267
  loading: m,
@@ -270,39 +269,39 @@ const xe = {
270
269
  } = le(), {
271
270
  paidProductCount: I,
272
271
  loadPaidProductCount: $
273
- } = Ce(), u = b(() => e.currentVersionName ? e.currentVersionName : ue(d.value)), O = b(() => {
272
+ } = Ce(), u = b(() => e.currentVersionName ? e.currentVersionName : ue(c.value)), H = b(() => {
274
273
  var w;
275
- return e.expireDate || ((w = d.value) == null ? void 0 : w.endAt) || "";
276
- }), W = b(() => ce(d.value, I.value)), Z = b(() => de(d.value, I.value, e.canUpgrade));
277
- function V() {
274
+ return e.expireDate || ((w = c.value) == null ? void 0 : w.endAt) || "";
275
+ }), W = b(() => ce(c.value, I.value)), Z = b(() => de(c.value, I.value, e.canUpgrade));
276
+ function O() {
278
277
  e.showSubscription && (B(), $());
279
278
  }
280
279
  return x(a, (w) => {
281
- w && V();
280
+ w && O();
282
281
  }), ee(() => {
283
- a.value && V();
282
+ a.value && O();
284
283
  }), (w, M) => {
285
- var z, T, L, E, j, F, X;
284
+ var V, z, T, L, E, j, F;
286
285
  return r(), _(q, null, [f(Q, {
287
- "user-id": (z = t(o)) == null ? void 0 : z.id,
288
- "avatar-url": (T = t(o)) == null ? void 0 : T.avatarUrl,
289
- nickname: (L = t(o)) == null ? void 0 : L.nickname,
290
- email: (E = t(o)) == null ? void 0 : E.email,
291
- phone: (j = t(o)) == null ? void 0 : j.phone
286
+ "user-id": (V = t(o)) == null ? void 0 : V.id,
287
+ "avatar-url": (z = t(o)) == null ? void 0 : z.avatarUrl,
288
+ nickname: (T = t(o)) == null ? void 0 : T.nickname,
289
+ email: (L = t(o)) == null ? void 0 : L.email,
290
+ phone: (E = t(o)) == null ? void 0 : E.phone
292
291
  }, null, 8, ["user-id", "avatar-url", "nickname", "email", "phone"]), n.showSubscription ? (r(), v(Xe, {
293
292
  key: 0,
294
293
  "current-version-name": u.value,
295
- "expire-date": O.value,
296
- "points-balance": ((F = t(s)) == null ? void 0 : F.totalPoints) ?? 0,
297
- "pending-invoice-total": (X = t(l)) == null ? void 0 : X.total,
294
+ "expire-date": H.value,
295
+ "points-balance": ((j = t(s)) == null ? void 0 : j.totalPoints) ?? 0,
296
+ "pending-invoice-total": (F = t(l)) == null ? void 0 : F.total,
298
297
  loading: t(m),
299
298
  "can-upgrade": Z.value,
300
299
  "action-label": W.value,
301
- onUpgradeHandle: M[0] || (M[0] = (Y) => t(i)()),
302
- onPayHandle: M[1] || (M[1] = (Y) => t(i)({
300
+ onUpgradeHandle: M[0] || (M[0] = (X) => t(i)()),
301
+ onPayHandle: M[1] || (M[1] = (X) => t(i)({
303
302
  target: "invoices"
304
303
  })),
305
- onPointsHandle: M[2] || (M[2] = (Y) => t(i)({
304
+ onPointsHandle: M[2] || (M[2] = (X) => t(i)({
306
305
  target: "points"
307
306
  }))
308
307
  }, null, 8, ["current-version-name", "expire-date", "points-balance", "pending-invoice-total", "loading", "can-upgrade", "action-label"])) : U("", !0)], 64);
@@ -329,17 +328,17 @@ const xe = {
329
328
  const {
330
329
  userProfile: e,
331
330
  isLoggedIn: o
332
- } = H(), {
331
+ } = R(), {
333
332
  isOpen: a,
334
333
  setOpen: i
335
- } = y(), d = b({
334
+ } = y(), c = b({
336
335
  get: () => a.value,
337
336
  set: (s) => i(s)
338
337
  });
339
338
  return (s, l) => t(o) ? (r(), v(t(te), {
340
339
  key: 1,
341
- "popup-visible": d.value,
342
- "onUpdate:popupVisible": l[0] || (l[0] = (m) => d.value = m),
340
+ "popup-visible": c.value,
341
+ "onUpdate:popupVisible": l[0] || (l[0] = (m) => c.value = m),
343
342
  class: "UserMenu",
344
343
  position: n.position,
345
344
  "popup-max-height": !1,
@@ -348,7 +347,7 @@ const xe = {
348
347
  "--user-menu-translate-y": n.dropdownOffsetY ?? "0"
349
348
  }
350
349
  }, {
351
- content: g(() => [c("div", qe, [c("div", Ge, [A(s.$slots, "header", {
350
+ content: g(() => [d("div", qe, [d("div", Ge, [A(s.$slots, "header", {
352
351
  user: t(e)
353
352
  }, () => [f(Ye)], !0)]), s.$slots.items ? (r(), v(Me, {
354
353
  key: 0
@@ -404,10 +403,10 @@ const xe = {
404
403
  emit: e
405
404
  }) {
406
405
  const o = n, a = b(() => o.badge > 0), i = e, {
407
- close: d
406
+ close: c
408
407
  } = y();
409
408
  function s(l) {
410
- l.stopPropagation(), !o.disabled && (o.closeOnClick && d(), i("click", l));
409
+ l.stopPropagation(), !o.disabled && (o.closeOnClick && c(), i("click", l));
411
410
  }
412
411
  return (l, m) => (r(), _("button", {
413
412
  type: "button",
@@ -417,13 +416,13 @@ const xe = {
417
416
  }]),
418
417
  disabled: n.disabled,
419
418
  onClick: s
420
- }, [c("span", Qe, [a.value ? (r(), v(t(ae), {
419
+ }, [d("span", Qe, [a.value ? (r(), v(t(ae), {
421
420
  key: 0,
422
421
  count: n.badge,
423
422
  "max-count": 99,
424
423
  offset: [10, 0]
425
424
  }, {
426
- default: g(() => [c("span", We, [A(l.$slots, "default", {}, void 0, !0)])]),
425
+ default: g(() => [d("span", We, [A(l.$slots, "default", {}, void 0, !0)])]),
427
426
  _: 3
428
427
  }, 8, ["count"])) : A(l.$slots, "default", {
429
428
  key: 1
@@ -442,7 +441,7 @@ const xe = {
442
441
  subscriptionsTrigger: o,
443
442
  subscriptionsOptions: a,
444
443
  messagesTrigger: i,
445
- feedbackTrigger: d,
444
+ feedbackTrigger: c,
446
445
  invitationsTrigger: s
447
446
  } = y(), l = C(null), m = C(null), B = C(null), I = C(null), $ = C(null);
448
447
  return x(e, () => {
@@ -454,13 +453,13 @@ const xe = {
454
453
  }), x(i, () => {
455
454
  var u;
456
455
  (u = B.value) == null || u.openNotification();
457
- }), x(d, () => {
456
+ }), x(c, () => {
458
457
  var u;
459
458
  (u = I.value) == null || u.setData(!0);
460
459
  }), x(s, () => {
461
460
  var u;
462
461
  (u = $.value) == null || u.setData(!0);
463
- }), (u, O) => (r(), _(q, null, [f(fe, {
462
+ }), (u, H) => (r(), _(q, null, [f(fe, {
464
463
  ref_key: "appSettingRef",
465
464
  ref: l
466
465
  }, null, 512), f(pe, {
@@ -484,12 +483,12 @@ const xe = {
484
483
  setup(n) {
485
484
  const {
486
485
  userProfile: e
487
- } = H();
486
+ } = R();
488
487
  return (o, a) => {
489
- var i, d, s, l, m;
488
+ var i, c, s, l, m;
490
489
  return r(), _("div", nn, [f(Q, {
491
490
  "user-id": (i = t(e)) == null ? void 0 : i.id,
492
- "avatar-url": (d = t(e)) == null ? void 0 : d.avatarUrl,
491
+ "avatar-url": (c = t(e)) == null ? void 0 : c.avatarUrl,
493
492
  nickname: (s = t(e)) == null ? void 0 : s.nickname,
494
493
  email: (l = t(e)) == null ? void 0 : l.email,
495
494
  phone: (m = t(e)) == null ? void 0 : m.phone