@huyooo/ui 0.17.2 → 1.0.1

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.
@@ -474,12 +474,11 @@ export type Api = {
474
474
  /** 创建新应用 */
475
475
  post: {
476
476
  body: {
477
- appKey: string;
478
477
  name: string;
478
+ applicationLogo: string;
479
+ description: string;
479
480
  homePageUrl?: string;
480
481
  authorizationCallback?: string;
481
- applicationLogo?: string;
482
- description?: string;
483
482
  extensions?: Record<string, string>;
484
483
  };
485
484
  return: any;
@@ -499,12 +498,11 @@ export type Api = {
499
498
  post: {
500
499
  body: {
501
500
  id: string;
502
- appKey?: string;
501
+ applicationLogo: string;
502
+ description: string;
503
503
  name?: string;
504
504
  homePageUrl?: string;
505
505
  authorizationCallback?: string;
506
- applicationLogo?: string;
507
- description?: string;
508
506
  defaultRoleId?: string;
509
507
  };
510
508
  return: any;
@@ -652,7 +650,6 @@ export type Api = {
652
650
  pageSize: number;
653
651
  where: {
654
652
  id?: string;
655
- appKey?: string;
656
653
  name?: string;
657
654
  homePageUrl?: string;
658
655
  extensions?: Record<string, string>;
@@ -667,7 +664,6 @@ export type Api = {
667
664
  body: {
668
665
  where: {
669
666
  id?: string;
670
- appKey?: string;
671
667
  name?: string;
672
668
  homePageUrl?: string;
673
669
  extensions?: Record<string, string>;
@@ -1636,6 +1632,9 @@ export type Api = {
1636
1632
  body: {
1637
1633
  appId?: string;
1638
1634
  type?: "whitelist" | "blacklist";
1635
+ ip?: string;
1636
+ startTime?: string;
1637
+ endTime?: string;
1639
1638
  page?: number;
1640
1639
  pageSize?: number;
1641
1640
  };
@@ -1696,6 +1695,8 @@ export type Api = {
1696
1695
  type?: string;
1697
1696
  riskLevel?: "low" | "medium" | "high" | "critical";
1698
1697
  resolved?: boolean;
1698
+ startTime?: string;
1699
+ endTime?: string;
1699
1700
  page?: number;
1700
1701
  pageSize?: number;
1701
1702
  };
@@ -1716,6 +1717,8 @@ export type Api = {
1716
1717
  post: {
1717
1718
  body: {
1718
1719
  appId?: string;
1720
+ startTime?: string;
1721
+ endTime?: string;
1719
1722
  };
1720
1723
  return: any;
1721
1724
  };
@@ -2095,12 +2098,11 @@ export interface ApiClient {
2095
2098
  create: {
2096
2099
  /** 创建新应用 */
2097
2100
  post: (body: {
2098
- appKey: string;
2099
2101
  name: string;
2102
+ applicationLogo: string;
2103
+ description: string;
2100
2104
  homePageUrl?: string;
2101
2105
  authorizationCallback?: string;
2102
- applicationLogo?: string;
2103
- description?: string;
2104
2106
  extensions?: Record<string, string>;
2105
2107
  }, config?: RequestConfig) => Promise<ApiResponse<any>>;
2106
2108
  };
@@ -2114,12 +2116,11 @@ export interface ApiClient {
2114
2116
  /** 更新应用信息 */
2115
2117
  post: (body: {
2116
2118
  id: string;
2117
- appKey?: string;
2119
+ applicationLogo: string;
2120
+ description: string;
2118
2121
  name?: string;
2119
2122
  homePageUrl?: string;
2120
2123
  authorizationCallback?: string;
2121
- applicationLogo?: string;
2122
- description?: string;
2123
2124
  defaultRoleId?: string;
2124
2125
  }, config?: RequestConfig) => Promise<ApiResponse<any>>;
2125
2126
  emailConfig: {
@@ -2228,7 +2229,6 @@ export interface ApiClient {
2228
2229
  pageSize: number;
2229
2230
  where: {
2230
2231
  id?: string;
2231
- appKey?: string;
2232
2232
  name?: string;
2233
2233
  homePageUrl?: string;
2234
2234
  extensions?: Record<string, string>;
@@ -2240,7 +2240,6 @@ export interface ApiClient {
2240
2240
  post: (body: {
2241
2241
  where: {
2242
2242
  id?: string;
2243
- appKey?: string;
2244
2243
  name?: string;
2245
2244
  homePageUrl?: string;
2246
2245
  extensions?: Record<string, string>;
@@ -2949,6 +2948,9 @@ export interface ApiClient {
2949
2948
  post: (body: {
2950
2949
  appId?: string;
2951
2950
  type?: "whitelist" | "blacklist";
2951
+ ip?: string;
2952
+ startTime?: string;
2953
+ endTime?: string;
2952
2954
  page?: number;
2953
2955
  pageSize?: number;
2954
2956
  }, config?: RequestConfig) => Promise<ApiResponse<any>>;
@@ -2994,6 +2996,8 @@ export interface ApiClient {
2994
2996
  type?: string;
2995
2997
  riskLevel?: "low" | "medium" | "high" | "critical";
2996
2998
  resolved?: boolean;
2999
+ startTime?: string;
3000
+ endTime?: string;
2997
3001
  page?: number;
2998
3002
  pageSize?: number;
2999
3003
  }, config?: RequestConfig) => Promise<ApiResponse<any>>;
@@ -3008,6 +3012,8 @@ export interface ApiClient {
3008
3012
  /** 获取安全告警统计数据 */
3009
3013
  post: (body: {
3010
3014
  appId?: string;
3015
+ startTime?: string;
3016
+ endTime?: string;
3011
3017
  }, config?: RequestConfig) => Promise<ApiResponse<any>>;
3012
3018
  };
3013
3019
  };
@@ -53,7 +53,6 @@ export interface Brand {
53
53
  }
54
54
  export interface AppsData {
55
55
  id: string;
56
- appKey: string;
57
56
  name: string;
58
57
  description: string;
59
58
  homePageUrl: string;
@@ -0,0 +1,122 @@
1
+ import { ref as r } from "vue";
2
+ import { e as l } from "./apiClients-DrGX2iJy.js";
3
+ function i() {
4
+ return {
5
+ type: "doc",
6
+ content: [{
7
+ type: "paragraph"
8
+ }]
9
+ };
10
+ }
11
+ function u(e) {
12
+ return e.type === "doc" && Array.isArray(e.content) && e.content.length > 0;
13
+ }
14
+ function o(e) {
15
+ return typeof e == "string" || e == null ? i() : u(e) ? e : i();
16
+ }
17
+ function s(e) {
18
+ return {
19
+ personalInformationCollectionList: o(e.personalInformationCollectionList),
20
+ thirdPartyInformationSharingList: o(e.thirdPartyInformationSharingList),
21
+ userServiceAgreement: o(e.userServiceAgreement),
22
+ privacyPolicy: o(e.privacyPolicy),
23
+ licenseInformation: o(e.licenseInformation)
24
+ };
25
+ }
26
+ function c() {
27
+ const e = i();
28
+ return {
29
+ personalInformationCollectionList: e,
30
+ thirdPartyInformationSharingList: e,
31
+ userServiceAgreement: e,
32
+ privacyPolicy: e,
33
+ licenseInformation: e
34
+ };
35
+ }
36
+ const a = r({
37
+ id: "",
38
+ name: "",
39
+ description: "",
40
+ homePageUrl: "",
41
+ applicationLogo: "",
42
+ applicationLogoUrl: "",
43
+ publicRoutes: [],
44
+ oauth: {
45
+ google: {
46
+ // redirectURI: '',
47
+ // clientID: '',
48
+ // clientSecret: '',
49
+ enabled: !1
50
+ },
51
+ microsoft: {
52
+ // redirectURI: '',
53
+ // clientID: '',
54
+ // clientSecret: '',
55
+ enabled: !1
56
+ },
57
+ github: {
58
+ // redirectURI: '',
59
+ // clientID: '',
60
+ // clientSecret: '',
61
+ enabled: !1
62
+ },
63
+ wechat: {
64
+ // redirectURI: '',
65
+ // clientID: '',
66
+ // clientSecret: '',
67
+ enabled: !1
68
+ }
69
+ },
70
+ authMethods: {
71
+ login: {
72
+ emailPassword: !0,
73
+ phonePassword: !1,
74
+ phoneCode: !1,
75
+ emailCode: !1,
76
+ passkey: !1
77
+ },
78
+ signUp: {
79
+ email: !0,
80
+ phone: !1
81
+ }
82
+ },
83
+ authorizationCallback: "",
84
+ aboutUs: c(),
85
+ brand: {
86
+ theme: "dark",
87
+ logo: "",
88
+ favicon: "",
89
+ backgroundType: "image",
90
+ backgroundColor: "",
91
+ backgroundImageUrl: "",
92
+ backgroundImage: "/66a0d5b35203890887f0e1a4/6714e2458fe86895bf3da8ae/1ef8ed72-1731-6e00-93d1-fa24165f1a3e.webp"
93
+ }
94
+ }), n = r(!1), t = r(!1);
95
+ function p(e) {
96
+ a.value.id = e.id, a.value.name = e.name, a.value.description = e.description, a.value.homePageUrl = e.homePageUrl, a.value.applicationLogo = e.applicationLogo, a.value.applicationLogoUrl = e.applicationLogoUrl, a.value.publicRoutes = e.publicRoutes || [], a.value.oauth = e.oauth, a.value.authMethods = e.authMethods || a.value.authMethods, a.value.authorizationCallback = e.authorizationCallback, a.value.aboutUs = s(e.aboutUs), a.value.brand = e.brand;
97
+ }
98
+ async function f() {
99
+ n.value = !0, t.value = !1;
100
+ try {
101
+ const {
102
+ data: e
103
+ } = await l.apps.authPageInfo.post({});
104
+ e && (p(e), t.value = !0);
105
+ } finally {
106
+ n.value = !1;
107
+ }
108
+ }
109
+ function m() {
110
+ async function e() {
111
+ t.value || n.value || await f();
112
+ }
113
+ return {
114
+ appsData: a,
115
+ appsAuthPageInfoApi: e,
116
+ appsAuthPageInfoLoading: n,
117
+ appsAuthPageInfoSuccess: t
118
+ };
119
+ }
120
+ export {
121
+ m as u
122
+ };
@@ -1,6 +1,6 @@
1
1
  import { computed as c } from "vue";
2
2
  import { g as L } from "./apiClients-DrGX2iJy.js";
3
- import { u as m } from "./useAuthkitAppsAuthPageInfo-DWd0bDP-.js";
3
+ import { u as m } from "./useAuthkitAppsAuthPageInfo-C2yKgl8t.js";
4
4
  const l = {
5
5
  userServiceAgreement: "用户服务协议",
6
6
  privacyPolicy: "隐私协议",
@@ -1,6 +1,6 @@
1
1
  import { ref as w, computed as b, watch as S } from "vue";
2
2
  import { useRouter as I, useRoute as T } from "vue-router";
3
- import { u as k } from "./useAuthkitAppsAuthPageInfo-DWd0bDP-.js";
3
+ import { u as k } from "./useAuthkitAppsAuthPageInfo-C2yKgl8t.js";
4
4
  import { u as M } from "./useAuthkitUsersProfile-BZDk21c8.js";
5
5
  const y = w({
6
6
  key: "",
package/dist/user.js CHANGED
@@ -1,4 +1,4 @@
1
- import { U as a, a as n, b as r, c as t, d as U, _ as u, e as i, f as M, g as o, h as m, i as I, j as c, k as d, l as b, m as f } from "./UserMenuInvitationsItem.vue_vue_type_script_setup_true_lang-BVtXbwch.js";
1
+ import { U as a, a as n, b as r, c as t, d as U, _ as u, e as i, f as M, g as o, h as m, i as I, j as c, k as d, l as b, m as f } from "./UserMenuInvitationsItem.vue_vue_type_script_setup_true_lang-Cpgoh88W.js";
2
2
  export {
3
3
  a as UserAccountMenu,
4
4
  n as UserAvatar,
@@ -0,0 +1,9 @@
1
+ import { AboutUs, AboutUsDoc } from '../types/app';
2
+ /** TipTap 空文档:doc 至少包含一个 block 节点 */
3
+ export declare function emptyTiptapDoc(): AboutUsDoc;
4
+ type TiptapDocInput = AboutUsDoc | string | null | undefined;
5
+ /** 将 API / 默认值中的非法 doc(含 content: []、空字符串)规范为 TipTap 可渲染结构 */
6
+ export declare function normalizeTiptapDoc(value: TiptapDocInput): AboutUsDoc;
7
+ export declare function normalizeAboutUs(aboutUs: AboutUs): AboutUs;
8
+ export declare function emptyAboutUs(): AboutUs;
9
+ export {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@huyooo/ui",
3
- "version": "0.17.2",
3
+ "version": "1.0.1",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "files": [
@@ -89,7 +89,7 @@
89
89
  },
90
90
  "peerDependencies": {
91
91
  "@arco-design/web-vue": ">=2.56.3",
92
- "@huyooo/vue-tiptap": ">=0.3.25",
92
+ "@huyooo/vue-tiptap": "^1.0.0",
93
93
  "@iconify/vue": ">=4.1.2",
94
94
  "@unhead/vue": ">=2.0.19",
95
95
  "@vueuse/core": ">=11.3.0",
@@ -1,116 +0,0 @@
1
- import { ref as n } from "vue";
2
- import { e as l } from "./apiClients-DrGX2iJy.js";
3
- const a = n({
4
- id: "",
5
- appKey: "",
6
- name: "",
7
- description: "",
8
- homePageUrl: "",
9
- applicationLogo: "",
10
- applicationLogoUrl: "",
11
- publicRoutes: [],
12
- oauth: {
13
- google: {
14
- // redirectURI: '',
15
- // clientID: '',
16
- // clientSecret: '',
17
- enabled: !1
18
- },
19
- microsoft: {
20
- // redirectURI: '',
21
- // clientID: '',
22
- // clientSecret: '',
23
- enabled: !1
24
- },
25
- github: {
26
- // redirectURI: '',
27
- // clientID: '',
28
- // clientSecret: '',
29
- enabled: !1
30
- },
31
- wechat: {
32
- // redirectURI: '',
33
- // clientID: '',
34
- // clientSecret: '',
35
- enabled: !1
36
- }
37
- },
38
- authMethods: {
39
- login: {
40
- emailPassword: !0,
41
- phonePassword: !1,
42
- phoneCode: !1,
43
- emailCode: !1,
44
- passkey: !1
45
- },
46
- signUp: {
47
- email: !0,
48
- phone: !1
49
- }
50
- },
51
- authorizationCallback: "",
52
- aboutUs: {
53
- // 个人信息收集清单
54
- personalInformationCollectionList: {
55
- type: "doc",
56
- content: []
57
- },
58
- // 第三方信息共享清单
59
- thirdPartyInformationSharingList: {
60
- type: "doc",
61
- content: []
62
- },
63
- // 用户服务协议
64
- userServiceAgreement: {
65
- type: "doc",
66
- content: []
67
- },
68
- // 隐私协议
69
- privacyPolicy: {
70
- type: "doc",
71
- content: []
72
- },
73
- // 证照信息
74
- licenseInformation: {
75
- type: "doc",
76
- content: []
77
- }
78
- },
79
- brand: {
80
- theme: "dark",
81
- logo: "",
82
- favicon: "",
83
- backgroundType: "image",
84
- backgroundColor: "",
85
- backgroundImageUrl: "",
86
- backgroundImage: "/66a0d5b35203890887f0e1a4/6714e2458fe86895bf3da8ae/1ef8ed72-1731-6e00-93d1-fa24165f1a3e.webp"
87
- }
88
- }), o = n(!1), t = n(!1);
89
- function u(e) {
90
- a.value.id = e.id, a.value.appKey = e.appKey, a.value.name = e.name, a.value.description = e.description, a.value.homePageUrl = e.homePageUrl, a.value.applicationLogo = e.applicationLogo, a.value.applicationLogoUrl = e.applicationLogoUrl, a.value.publicRoutes = e.publicRoutes || [], a.value.oauth = e.oauth, a.value.authMethods = e.authMethods || a.value.authMethods, a.value.authorizationCallback = e.authorizationCallback, a.value.aboutUs = e.aboutUs, a.value.brand = e.brand;
91
- }
92
- async function i() {
93
- o.value = !0, t.value = !1;
94
- try {
95
- const {
96
- data: e
97
- } = await l.apps.authPageInfo.post({});
98
- e && (u(e), t.value = !0);
99
- } finally {
100
- o.value = !1;
101
- }
102
- }
103
- function r() {
104
- async function e() {
105
- t.value || o.value || await i();
106
- }
107
- return {
108
- appsData: a,
109
- appsAuthPageInfoApi: e,
110
- appsAuthPageInfoLoading: o,
111
- appsAuthPageInfoSuccess: t
112
- };
113
- }
114
- export {
115
- r as u
116
- };