@vitnode/core 1.2.0-canary.48 → 1.2.0-canary.49
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/scripts/plugin.d.ts.map +1 -1
- package/dist/scripts/prepare-database.d.ts.map +1 -1
- package/dist/scripts/prepare-plugins-files.d.ts +1 -1
- package/dist/scripts/prepare-plugins-files.d.ts.map +1 -1
- package/dist/scripts/scripts.js +4 -4
- package/dist/src/api/config.d.ts.map +1 -1
- package/dist/src/api/config.js +3 -1
- package/dist/src/api/lib/check-plugin-id.d.ts.map +1 -1
- package/dist/src/api/lib/check-plugin-id.js +2 -0
- package/dist/src/api/lib/with-pagination.d.ts +2 -24
- package/dist/src/api/lib/with-pagination.d.ts.map +1 -1
- package/dist/src/api/middlewares/global.middleware.d.ts +7 -1
- package/dist/src/api/middlewares/global.middleware.d.ts.map +1 -1
- package/dist/src/api/middlewares/global.middleware.js +6 -2
- package/dist/src/api/models/email.d.ts +3 -1
- package/dist/src/api/models/email.d.ts.map +1 -1
- package/dist/src/api/models/email.js +25 -2
- package/dist/src/api/modules/admin/admin.module.d.ts +41 -288
- package/dist/src/api/modules/admin/admin.module.d.ts.map +1 -1
- package/dist/src/api/modules/admin/debug/debug.admin.module.d.ts +23 -131
- package/dist/src/api/modules/admin/debug/debug.admin.module.d.ts.map +1 -1
- package/dist/src/api/modules/admin/debug/routes/logs.route.d.ts +23 -131
- package/dist/src/api/modules/admin/debug/routes/logs.route.d.ts.map +1 -1
- package/dist/src/api/modules/admin/routes/session.route.d.ts +2 -52
- package/dist/src/api/modules/admin/routes/session.route.d.ts.map +1 -1
- package/dist/src/api/modules/admin/users/routes/list.route.d.ts +16 -105
- package/dist/src/api/modules/admin/users/routes/list.route.d.ts.map +1 -1
- package/dist/src/api/modules/admin/users/routes/users.route.d.ts +18 -105
- package/dist/src/api/modules/admin/users/routes/users.route.d.ts.map +1 -1
- package/dist/src/api/modules/admin/users/users.admin.module.d.ts +16 -105
- package/dist/src/api/modules/admin/users/users.admin.module.d.ts.map +1 -1
- package/dist/src/api/modules/middleware/middleware.module.d.ts +7 -36
- package/dist/src/api/modules/middleware/middleware.module.d.ts.map +1 -1
- package/dist/src/api/modules/middleware/route.d.ts +14 -72
- package/dist/src/api/modules/middleware/route.d.ts.map +1 -1
- package/dist/src/api/modules/users/routes/session.route.d.ts +2 -54
- package/dist/src/api/modules/users/routes/session.route.d.ts.map +1 -1
- package/dist/src/api/modules/users/routes/sign-in.route.d.ts +5 -27
- package/dist/src/api/modules/users/routes/sign-in.route.d.ts.map +1 -1
- package/dist/src/api/modules/users/routes/sign-in.route.js +1 -1
- package/dist/src/api/modules/users/routes/sign-out.route.d.ts +1 -5
- package/dist/src/api/modules/users/routes/sign-out.route.d.ts.map +1 -1
- package/dist/src/api/modules/users/routes/sign-up.route.d.ts +8 -36
- package/dist/src/api/modules/users/routes/sign-up.route.d.ts.map +1 -1
- package/dist/src/api/modules/users/routes/sign-up.route.js +2 -2
- package/dist/src/api/modules/users/routes/test.route.js +1 -1
- package/dist/src/api/modules/users/sso/routes/callback.route.d.ts +3 -19
- package/dist/src/api/modules/users/sso/routes/callback.route.d.ts.map +1 -1
- package/dist/src/api/modules/users/sso/routes/create-url.route.d.ts +2 -10
- package/dist/src/api/modules/users/sso/routes/create-url.route.d.ts.map +1 -1
- package/dist/src/api/modules/users/sso/sso.module.d.ts +5 -29
- package/dist/src/api/modules/users/sso/sso.module.d.ts.map +1 -1
- package/dist/src/api/modules/users/users.module.d.ts +16 -128
- package/dist/src/api/modules/users/users.module.d.ts.map +1 -1
- package/dist/src/components/form/auto-form.d.ts +28 -6
- package/dist/src/components/form/auto-form.d.ts.map +1 -1
- package/dist/src/components/form/auto-form.js +46 -12
- package/dist/src/components/form/fields/checkbox.d.ts +3 -7
- package/dist/src/components/form/fields/checkbox.d.ts.map +1 -1
- package/dist/src/components/form/fields/checkbox.js +5 -4
- package/dist/src/components/form/fields/combobox-async.d.ts +3 -6
- package/dist/src/components/form/fields/combobox-async.d.ts.map +1 -1
- package/dist/src/components/form/fields/combobox-async.js +4 -4
- package/dist/src/components/form/fields/combobox.d.ts +3 -6
- package/dist/src/components/form/fields/combobox.d.ts.map +1 -1
- package/dist/src/components/form/fields/combobox.js +4 -5
- package/dist/src/components/form/fields/input.d.ts +3 -8
- package/dist/src/components/form/fields/input.d.ts.map +1 -1
- package/dist/src/components/form/fields/input.js +8 -4
- package/dist/src/components/form/fields/radio-group.d.ts +3 -6
- package/dist/src/components/form/fields/radio-group.d.ts.map +1 -1
- package/dist/src/components/form/fields/radio-group.js +4 -5
- package/dist/src/components/form/fields/select.d.ts +3 -6
- package/dist/src/components/form/fields/select.d.ts.map +1 -1
- package/dist/src/components/form/fields/select.js +4 -5
- package/dist/src/components/form/fields/switch.d.ts +2 -6
- package/dist/src/components/form/fields/switch.d.ts.map +1 -1
- package/dist/src/components/form/fields/switch.js +9 -9
- package/dist/src/components/form/fields/textarea.d.ts +3 -4
- package/dist/src/components/form/fields/textarea.d.ts.map +1 -1
- package/dist/src/components/form/fields/textarea.js +5 -3
- package/dist/src/components/ui/button-client.d.ts +3 -0
- package/dist/src/components/ui/button-client.d.ts.map +1 -0
- package/dist/src/components/ui/button-client.js +57 -0
- package/dist/src/components/ui/button.d.ts +2 -3
- package/dist/src/components/ui/button.d.ts.map +1 -1
- package/dist/src/components/ui/button.js +5 -39
- package/dist/src/components/ui/form.d.ts +2 -2
- package/dist/src/components/ui/form.d.ts.map +1 -1
- package/dist/src/components/ui/form.js +2 -2
- package/dist/src/components/ui/loader.js +1 -1
- package/dist/src/emails/default-template.d.ts +5 -1
- package/dist/src/emails/default-template.d.ts.map +1 -1
- package/dist/src/emails/default-template.js +10 -11
- package/dist/src/lib/api/get-middleware-api.d.ts +1 -1
- package/dist/src/lib/api/get-session-admin-api.d.ts +2 -2
- package/dist/src/lib/api/get-session-api.d.ts +2 -2
- package/dist/src/lib/helpers/auto-form.d.ts +18 -8
- package/dist/src/lib/helpers/auto-form.d.ts.map +1 -1
- package/dist/src/lib/helpers/auto-form.js +90 -86
- package/dist/src/lib/helpers/auto-form.test.js +299 -138
- package/dist/src/lib/navigation.d.ts +5 -5
- package/dist/src/views/admin/views/core/debug/system-logs/actions/more/more.d.ts +9 -9
- package/dist/src/views/admin/views/core/debug/system-logs/system-logs-view.d.ts +10 -10
- package/dist/src/views/admin/views/core/test.d.ts.map +1 -1
- package/dist/src/views/admin/views/core/test.js +6 -6
- package/dist/src/views/auth/components/password-input.d.ts +2 -1
- package/dist/src/views/auth/components/password-input.d.ts.map +1 -1
- package/dist/src/views/auth/components/password-input.js +15 -8
- package/dist/src/views/auth/sign-in/form/use-form.d.ts +4 -16
- package/dist/src/views/auth/sign-in/form/use-form.d.ts.map +1 -1
- package/dist/src/views/auth/sign-in/form/use-form.js +1 -1
- package/dist/src/views/auth/sign-up/form/form.d.ts.map +1 -1
- package/dist/src/views/auth/sign-up/form/form.js +22 -9
- package/dist/src/views/auth/sign-up/form/mutation-api.d.ts +1 -1
- package/dist/src/views/auth/sign-up/form/use-form.d.ts +18 -36
- package/dist/src/views/auth/sign-up/form/use-form.d.ts.map +1 -1
- package/dist/src/views/auth/sign-up/form/use-form.js +10 -7
- package/dist/src/vitnode.config.d.ts +3 -0
- package/dist/src/vitnode.config.d.ts.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +21 -18
- package/dist/src/components/form/fields/item.d.ts +0 -14
- package/dist/src/components/form/fields/item.d.ts.map +0 -1
- package/dist/src/components/form/fields/item.js +0 -22
|
@@ -2,20 +2,20 @@ export declare const usersAdminModule: import("../../../../api/lib/module").Buil
|
|
|
2
2
|
handler: (c: import("hono").Context<import("../../../middlewares/global.middleware").EnvVitNode, "/list", {
|
|
3
3
|
in: {
|
|
4
4
|
query: {
|
|
5
|
-
order?: "asc" | "desc" | undefined;
|
|
6
5
|
cursor?: string | undefined;
|
|
7
|
-
orderBy?: "name" | "createdAt" | undefined;
|
|
8
6
|
first?: string | undefined;
|
|
9
7
|
last?: string | undefined;
|
|
8
|
+
order?: "asc" | "desc" | undefined;
|
|
9
|
+
orderBy?: "name" | "createdAt" | undefined;
|
|
10
10
|
};
|
|
11
11
|
};
|
|
12
12
|
out: {
|
|
13
13
|
query: {
|
|
14
|
-
order?: "asc" | "desc" | undefined;
|
|
15
14
|
cursor?: string | undefined;
|
|
16
|
-
orderBy?: "name" | "createdAt" | undefined;
|
|
17
15
|
first?: string | undefined;
|
|
18
16
|
last?: string | undefined;
|
|
17
|
+
order?: "asc" | "desc" | undefined;
|
|
18
|
+
orderBy?: "name" | "createdAt" | undefined;
|
|
19
19
|
};
|
|
20
20
|
};
|
|
21
21
|
}>) => Promise<Response & import("hono").TypedResponse<{
|
|
@@ -51,22 +51,15 @@ export declare const usersAdminModule: import("../../../../api/lib/module").Buil
|
|
|
51
51
|
cursor: import("zod").ZodOptional<import("zod").ZodString>;
|
|
52
52
|
first: import("zod").ZodOptional<import("zod").ZodString>;
|
|
53
53
|
last: import("zod").ZodOptional<import("zod").ZodString>;
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
}, {
|
|
64
|
-
order?: "asc" | "desc" | undefined;
|
|
65
|
-
cursor?: string | undefined;
|
|
66
|
-
orderBy?: "name" | "createdAt" | undefined;
|
|
67
|
-
first?: string | undefined;
|
|
68
|
-
last?: string | undefined;
|
|
69
|
-
}>;
|
|
54
|
+
order: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
55
|
+
asc: "asc";
|
|
56
|
+
desc: "desc";
|
|
57
|
+
}>>;
|
|
58
|
+
orderBy: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
59
|
+
name: "name";
|
|
60
|
+
createdAt: "createdAt";
|
|
61
|
+
}>>;
|
|
62
|
+
}, import("zod/v4/core").$strip>;
|
|
70
63
|
};
|
|
71
64
|
responses: {
|
|
72
65
|
200: {
|
|
@@ -85,31 +78,7 @@ export declare const usersAdminModule: import("../../../../api/lib/module").Buil
|
|
|
85
78
|
roleId: import("zod").ZodNumber;
|
|
86
79
|
birthday: import("zod").ZodNullable<import("zod").ZodDate>;
|
|
87
80
|
language: import("zod").ZodString;
|
|
88
|
-
},
|
|
89
|
-
email: string;
|
|
90
|
-
id: number;
|
|
91
|
-
name: string;
|
|
92
|
-
createdAt: Date;
|
|
93
|
-
language: string;
|
|
94
|
-
nameCode: string;
|
|
95
|
-
newsletter: boolean;
|
|
96
|
-
avatarColor: string;
|
|
97
|
-
emailVerified: boolean;
|
|
98
|
-
roleId: number;
|
|
99
|
-
birthday: Date | null;
|
|
100
|
-
}, {
|
|
101
|
-
email: string;
|
|
102
|
-
id: number;
|
|
103
|
-
name: string;
|
|
104
|
-
createdAt: Date;
|
|
105
|
-
language: string;
|
|
106
|
-
nameCode: string;
|
|
107
|
-
newsletter: boolean;
|
|
108
|
-
avatarColor: string;
|
|
109
|
-
emailVerified: boolean;
|
|
110
|
-
roleId: number;
|
|
111
|
-
birthday: Date | null;
|
|
112
|
-
}>, "many">;
|
|
81
|
+
}, import("zod/v4/core").$strip>>;
|
|
113
82
|
pageInfo: import("zod").ZodObject<{
|
|
114
83
|
totalCount: import("zod").ZodNumber;
|
|
115
84
|
count: import("zod").ZodNumber;
|
|
@@ -117,66 +86,8 @@ export declare const usersAdminModule: import("../../../../api/lib/module").Buil
|
|
|
117
86
|
hasPreviousPage: import("zod").ZodBoolean;
|
|
118
87
|
startCursor: import("zod").ZodNullable<import("zod").ZodNumber>;
|
|
119
88
|
endCursor: import("zod").ZodNullable<import("zod").ZodNumber>;
|
|
120
|
-
},
|
|
121
|
-
|
|
122
|
-
totalCount: number;
|
|
123
|
-
hasNextPage: boolean;
|
|
124
|
-
hasPreviousPage: boolean;
|
|
125
|
-
startCursor: number | null;
|
|
126
|
-
endCursor: number | null;
|
|
127
|
-
}, {
|
|
128
|
-
count: number;
|
|
129
|
-
totalCount: number;
|
|
130
|
-
hasNextPage: boolean;
|
|
131
|
-
hasPreviousPage: boolean;
|
|
132
|
-
startCursor: number | null;
|
|
133
|
-
endCursor: number | null;
|
|
134
|
-
}>;
|
|
135
|
-
}, "strip", import("zod").ZodTypeAny, {
|
|
136
|
-
edges: {
|
|
137
|
-
email: string;
|
|
138
|
-
id: number;
|
|
139
|
-
name: string;
|
|
140
|
-
createdAt: Date;
|
|
141
|
-
language: string;
|
|
142
|
-
nameCode: string;
|
|
143
|
-
newsletter: boolean;
|
|
144
|
-
avatarColor: string;
|
|
145
|
-
emailVerified: boolean;
|
|
146
|
-
roleId: number;
|
|
147
|
-
birthday: Date | null;
|
|
148
|
-
}[];
|
|
149
|
-
pageInfo: {
|
|
150
|
-
count: number;
|
|
151
|
-
totalCount: number;
|
|
152
|
-
hasNextPage: boolean;
|
|
153
|
-
hasPreviousPage: boolean;
|
|
154
|
-
startCursor: number | null;
|
|
155
|
-
endCursor: number | null;
|
|
156
|
-
};
|
|
157
|
-
}, {
|
|
158
|
-
edges: {
|
|
159
|
-
email: string;
|
|
160
|
-
id: number;
|
|
161
|
-
name: string;
|
|
162
|
-
createdAt: Date;
|
|
163
|
-
language: string;
|
|
164
|
-
nameCode: string;
|
|
165
|
-
newsletter: boolean;
|
|
166
|
-
avatarColor: string;
|
|
167
|
-
emailVerified: boolean;
|
|
168
|
-
roleId: number;
|
|
169
|
-
birthday: Date | null;
|
|
170
|
-
}[];
|
|
171
|
-
pageInfo: {
|
|
172
|
-
count: number;
|
|
173
|
-
totalCount: number;
|
|
174
|
-
hasNextPage: boolean;
|
|
175
|
-
hasPreviousPage: boolean;
|
|
176
|
-
startCursor: number | null;
|
|
177
|
-
endCursor: number | null;
|
|
178
|
-
};
|
|
179
|
-
}>;
|
|
89
|
+
}, import("zod/v4/core").$strip>;
|
|
90
|
+
}, import("zod/v4/core").$strip>;
|
|
180
91
|
};
|
|
181
92
|
};
|
|
182
93
|
description: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"users.admin.module.d.ts","sourceRoot":"","sources":["../../../../../../src/api/modules/admin/users/users.admin.module.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,gBAAgB
|
|
1
|
+
{"version":3,"file":"users.admin.module.d.ts","sourceRoot":"","sources":["../../../../../../src/api/modules/admin/users/users.admin.module.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;mQAI3B,CAAC"}
|
|
@@ -23,45 +23,16 @@ export declare const middlewareModule: import("../../../api/lib/module").BuildMo
|
|
|
23
23
|
sso: import("zod").ZodArray<import("zod").ZodObject<{
|
|
24
24
|
id: import("zod").ZodString;
|
|
25
25
|
name: import("zod").ZodString;
|
|
26
|
-
},
|
|
27
|
-
id: string;
|
|
28
|
-
name: string;
|
|
29
|
-
}, {
|
|
30
|
-
id: string;
|
|
31
|
-
name: string;
|
|
32
|
-
}>, "many">;
|
|
26
|
+
}, import("zod/v4/core").$strip>>;
|
|
33
27
|
isEmail: import("zod").ZodBoolean;
|
|
34
28
|
captcha: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
35
29
|
siteKey: import("zod").ZodString;
|
|
36
|
-
type: import("zod").ZodEnum<
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
},
|
|
41
|
-
|
|
42
|
-
siteKey: string;
|
|
43
|
-
}>>;
|
|
44
|
-
}, "strip", import("zod").ZodTypeAny, {
|
|
45
|
-
sso: {
|
|
46
|
-
id: string;
|
|
47
|
-
name: string;
|
|
48
|
-
}[];
|
|
49
|
-
isEmail: boolean;
|
|
50
|
-
captcha?: {
|
|
51
|
-
type: "cloudflare_turnstile" | "recaptcha_v3";
|
|
52
|
-
siteKey: string;
|
|
53
|
-
} | undefined;
|
|
54
|
-
}, {
|
|
55
|
-
sso: {
|
|
56
|
-
id: string;
|
|
57
|
-
name: string;
|
|
58
|
-
}[];
|
|
59
|
-
isEmail: boolean;
|
|
60
|
-
captcha?: {
|
|
61
|
-
type: "cloudflare_turnstile" | "recaptcha_v3";
|
|
62
|
-
siteKey: string;
|
|
63
|
-
} | undefined;
|
|
64
|
-
}>;
|
|
30
|
+
type: import("zod").ZodEnum<{
|
|
31
|
+
cloudflare_turnstile: "cloudflare_turnstile";
|
|
32
|
+
recaptcha_v3: "recaptcha_v3";
|
|
33
|
+
}>;
|
|
34
|
+
}, import("zod/v4/core").$strip>>;
|
|
35
|
+
}, import("zod/v4/core").$strip>;
|
|
65
36
|
};
|
|
66
37
|
};
|
|
67
38
|
description: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"middleware.module.d.ts","sourceRoot":"","sources":["../../../../../src/api/modules/middleware/middleware.module.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,gBAAgB
|
|
1
|
+
{"version":3,"file":"middleware.module.d.ts","sourceRoot":"","sources":["../../../../../src/api/modules/middleware/middleware.module.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;gQAI3B,CAAC"}
|
|
@@ -3,45 +3,16 @@ export declare const routeMiddlewareSchema: z.ZodObject<{
|
|
|
3
3
|
sso: z.ZodArray<z.ZodObject<{
|
|
4
4
|
id: z.ZodString;
|
|
5
5
|
name: z.ZodString;
|
|
6
|
-
},
|
|
7
|
-
id: string;
|
|
8
|
-
name: string;
|
|
9
|
-
}, {
|
|
10
|
-
id: string;
|
|
11
|
-
name: string;
|
|
12
|
-
}>, "many">;
|
|
6
|
+
}, z.core.$strip>>;
|
|
13
7
|
isEmail: z.ZodBoolean;
|
|
14
8
|
captcha: z.ZodOptional<z.ZodObject<{
|
|
15
9
|
siteKey: z.ZodString;
|
|
16
|
-
type: z.ZodEnum<
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
},
|
|
21
|
-
|
|
22
|
-
siteKey: string;
|
|
23
|
-
}>>;
|
|
24
|
-
}, "strip", z.ZodTypeAny, {
|
|
25
|
-
sso: {
|
|
26
|
-
id: string;
|
|
27
|
-
name: string;
|
|
28
|
-
}[];
|
|
29
|
-
isEmail: boolean;
|
|
30
|
-
captcha?: {
|
|
31
|
-
type: "cloudflare_turnstile" | "recaptcha_v3";
|
|
32
|
-
siteKey: string;
|
|
33
|
-
} | undefined;
|
|
34
|
-
}, {
|
|
35
|
-
sso: {
|
|
36
|
-
id: string;
|
|
37
|
-
name: string;
|
|
38
|
-
}[];
|
|
39
|
-
isEmail: boolean;
|
|
40
|
-
captcha?: {
|
|
41
|
-
type: "cloudflare_turnstile" | "recaptcha_v3";
|
|
42
|
-
siteKey: string;
|
|
43
|
-
} | undefined;
|
|
44
|
-
}>;
|
|
10
|
+
type: z.ZodEnum<{
|
|
11
|
+
cloudflare_turnstile: "cloudflare_turnstile";
|
|
12
|
+
recaptcha_v3: "recaptcha_v3";
|
|
13
|
+
}>;
|
|
14
|
+
}, z.core.$strip>>;
|
|
15
|
+
}, z.core.$strip>;
|
|
45
16
|
export declare const routeMiddleware: {
|
|
46
17
|
handler: (c: import("hono").Context<import("../../middlewares/global.middleware").EnvVitNode, "/", {}>) => Response & import("hono").TypedResponse<{
|
|
47
18
|
isEmail: boolean;
|
|
@@ -67,45 +38,16 @@ export declare const routeMiddleware: {
|
|
|
67
38
|
sso: z.ZodArray<z.ZodObject<{
|
|
68
39
|
id: z.ZodString;
|
|
69
40
|
name: z.ZodString;
|
|
70
|
-
},
|
|
71
|
-
id: string;
|
|
72
|
-
name: string;
|
|
73
|
-
}, {
|
|
74
|
-
id: string;
|
|
75
|
-
name: string;
|
|
76
|
-
}>, "many">;
|
|
41
|
+
}, z.core.$strip>>;
|
|
77
42
|
isEmail: z.ZodBoolean;
|
|
78
43
|
captcha: z.ZodOptional<z.ZodObject<{
|
|
79
44
|
siteKey: z.ZodString;
|
|
80
|
-
type: z.ZodEnum<
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
},
|
|
85
|
-
|
|
86
|
-
siteKey: string;
|
|
87
|
-
}>>;
|
|
88
|
-
}, "strip", z.ZodTypeAny, {
|
|
89
|
-
sso: {
|
|
90
|
-
id: string;
|
|
91
|
-
name: string;
|
|
92
|
-
}[];
|
|
93
|
-
isEmail: boolean;
|
|
94
|
-
captcha?: {
|
|
95
|
-
type: "cloudflare_turnstile" | "recaptcha_v3";
|
|
96
|
-
siteKey: string;
|
|
97
|
-
} | undefined;
|
|
98
|
-
}, {
|
|
99
|
-
sso: {
|
|
100
|
-
id: string;
|
|
101
|
-
name: string;
|
|
102
|
-
}[];
|
|
103
|
-
isEmail: boolean;
|
|
104
|
-
captcha?: {
|
|
105
|
-
type: "cloudflare_turnstile" | "recaptcha_v3";
|
|
106
|
-
siteKey: string;
|
|
107
|
-
} | undefined;
|
|
108
|
-
}>;
|
|
45
|
+
type: z.ZodEnum<{
|
|
46
|
+
cloudflare_turnstile: "cloudflare_turnstile";
|
|
47
|
+
recaptcha_v3: "recaptcha_v3";
|
|
48
|
+
}>;
|
|
49
|
+
}, z.core.$strip>>;
|
|
50
|
+
}, z.core.$strip>;
|
|
109
51
|
};
|
|
110
52
|
};
|
|
111
53
|
description: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"route.d.ts","sourceRoot":"","sources":["../../../../../src/api/modules/middleware/route.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,eAAO,MAAM,qBAAqB
|
|
1
|
+
{"version":3,"file":"route.d.ts","sourceRoot":"","sources":["../../../../../src/api/modules/middleware/route.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;iBAShC,CAAC;AAEH,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAkC1B,CAAC"}
|
|
@@ -37,60 +37,8 @@ export declare const sessionRoute: {
|
|
|
37
37
|
roleId: z.ZodNumber;
|
|
38
38
|
birthday: z.ZodNullable<z.ZodDate>;
|
|
39
39
|
isAdmin: z.ZodBoolean;
|
|
40
|
-
},
|
|
41
|
-
|
|
42
|
-
id: number;
|
|
43
|
-
name: string;
|
|
44
|
-
createdAt: Date;
|
|
45
|
-
nameCode: string;
|
|
46
|
-
newsletter: boolean;
|
|
47
|
-
avatarColor: string;
|
|
48
|
-
emailVerified: boolean;
|
|
49
|
-
roleId: number;
|
|
50
|
-
birthday: Date | null;
|
|
51
|
-
isAdmin: boolean;
|
|
52
|
-
}, {
|
|
53
|
-
email: string;
|
|
54
|
-
id: number;
|
|
55
|
-
name: string;
|
|
56
|
-
createdAt: Date;
|
|
57
|
-
nameCode: string;
|
|
58
|
-
newsletter: boolean;
|
|
59
|
-
avatarColor: string;
|
|
60
|
-
emailVerified: boolean;
|
|
61
|
-
roleId: number;
|
|
62
|
-
birthday: Date | null;
|
|
63
|
-
isAdmin: boolean;
|
|
64
|
-
}>>;
|
|
65
|
-
}, "strip", z.ZodTypeAny, {
|
|
66
|
-
user: {
|
|
67
|
-
email: string;
|
|
68
|
-
id: number;
|
|
69
|
-
name: string;
|
|
70
|
-
createdAt: Date;
|
|
71
|
-
nameCode: string;
|
|
72
|
-
newsletter: boolean;
|
|
73
|
-
avatarColor: string;
|
|
74
|
-
emailVerified: boolean;
|
|
75
|
-
roleId: number;
|
|
76
|
-
birthday: Date | null;
|
|
77
|
-
isAdmin: boolean;
|
|
78
|
-
} | null;
|
|
79
|
-
}, {
|
|
80
|
-
user: {
|
|
81
|
-
email: string;
|
|
82
|
-
id: number;
|
|
83
|
-
name: string;
|
|
84
|
-
createdAt: Date;
|
|
85
|
-
nameCode: string;
|
|
86
|
-
newsletter: boolean;
|
|
87
|
-
avatarColor: string;
|
|
88
|
-
emailVerified: boolean;
|
|
89
|
-
roleId: number;
|
|
90
|
-
birthday: Date | null;
|
|
91
|
-
isAdmin: boolean;
|
|
92
|
-
} | null;
|
|
93
|
-
}>;
|
|
40
|
+
}, z.core.$strip>>;
|
|
41
|
+
}, z.core.$strip>;
|
|
94
42
|
};
|
|
95
43
|
};
|
|
96
44
|
description: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"session.route.d.ts","sourceRoot":"","sources":["../../../../../../src/api/modules/users/routes/session.route.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,eAAO,MAAM,YAAY
|
|
1
|
+
{"version":3,"file":"session.route.d.ts","sourceRoot":"","sources":["../../../../../../src/api/modules/users/routes/session.route.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA8CvB,CAAC"}
|
|
@@ -1,17 +1,9 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
2
|
export declare const zodSignInSchema: z.ZodObject<{
|
|
3
|
-
email: z.
|
|
3
|
+
email: z.ZodEmail;
|
|
4
4
|
password: z.ZodString;
|
|
5
5
|
isAdmin: z.ZodOptional<z.ZodBoolean>;
|
|
6
|
-
},
|
|
7
|
-
email: string;
|
|
8
|
-
password: string;
|
|
9
|
-
isAdmin?: boolean | undefined;
|
|
10
|
-
}, {
|
|
11
|
-
email: string;
|
|
12
|
-
password: string;
|
|
13
|
-
isAdmin?: boolean | undefined;
|
|
14
|
-
}>;
|
|
6
|
+
}, z.core.$strip>;
|
|
15
7
|
export declare const signInRoute: {
|
|
16
8
|
handler: (c: import("hono").Context<import("../../../middlewares/global.middleware").EnvVitNode, "/sign_in", {
|
|
17
9
|
in: {
|
|
@@ -43,18 +35,10 @@ export declare const signInRoute: {
|
|
|
43
35
|
content: {
|
|
44
36
|
'application/json': {
|
|
45
37
|
schema: z.ZodObject<{
|
|
46
|
-
email: z.
|
|
38
|
+
email: z.ZodEmail;
|
|
47
39
|
password: z.ZodString;
|
|
48
40
|
isAdmin: z.ZodOptional<z.ZodBoolean>;
|
|
49
|
-
},
|
|
50
|
-
email: string;
|
|
51
|
-
password: string;
|
|
52
|
-
isAdmin?: boolean | undefined;
|
|
53
|
-
}, {
|
|
54
|
-
email: string;
|
|
55
|
-
password: string;
|
|
56
|
-
isAdmin?: boolean | undefined;
|
|
57
|
-
}>;
|
|
41
|
+
}, z.core.$strip>;
|
|
58
42
|
};
|
|
59
43
|
};
|
|
60
44
|
};
|
|
@@ -69,13 +53,7 @@ export declare const signInRoute: {
|
|
|
69
53
|
schema: z.ZodObject<{
|
|
70
54
|
id: z.ZodNumber;
|
|
71
55
|
token: z.ZodString;
|
|
72
|
-
},
|
|
73
|
-
token: string;
|
|
74
|
-
id: number;
|
|
75
|
-
}, {
|
|
76
|
-
token: string;
|
|
77
|
-
id: number;
|
|
78
|
-
}>;
|
|
56
|
+
}, z.core.$strip>;
|
|
79
57
|
};
|
|
80
58
|
};
|
|
81
59
|
description: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sign-in.route.d.ts","sourceRoot":"","sources":["../../../../../../src/api/modules/users/routes/sign-in.route.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAQxB,eAAO,MAAM,eAAe
|
|
1
|
+
{"version":3,"file":"sign-in.route.d.ts","sourceRoot":"","sources":["../../../../../../src/api/modules/users/routes/sign-in.route.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAQxB,eAAO,MAAM,eAAe;;;;iBAU1B,CAAC;AAEH,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAoDtB,CAAC"}
|
|
@@ -5,7 +5,7 @@ import { SessionAdminModel } from "../../../models/session-admin.js";
|
|
|
5
5
|
import { UserModel } from "../../../models/user.js";
|
|
6
6
|
import { CONFIG_PLUGIN } from "../../../../config.js";
|
|
7
7
|
export const zodSignInSchema = z.object({
|
|
8
|
-
email: z.
|
|
8
|
+
email: z.email().toLowerCase().openapi({
|
|
9
9
|
example: 'test@test.com'
|
|
10
10
|
}),
|
|
11
11
|
password: z.string().openapi({
|
|
@@ -23,11 +23,7 @@ export declare const signOutRoute: {
|
|
|
23
23
|
'application/json': {
|
|
24
24
|
schema: z.ZodObject<{
|
|
25
25
|
isAdmin: z.ZodOptional<z.ZodBoolean>;
|
|
26
|
-
},
|
|
27
|
-
isAdmin?: boolean | undefined;
|
|
28
|
-
}, {
|
|
29
|
-
isAdmin?: boolean | undefined;
|
|
30
|
-
}>;
|
|
26
|
+
}, z.core.$strip>;
|
|
31
27
|
};
|
|
32
28
|
};
|
|
33
29
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sign-out.route.d.ts","sourceRoot":"","sources":["../../../../../../src/api/modules/users/routes/sign-out.route.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,mBAAmB,CAAC;AAOtC,eAAO,MAAM,YAAY
|
|
1
|
+
{"version":3,"file":"sign-out.route.d.ts","sourceRoot":"","sources":["../../../../../../src/api/modules/users/routes/sign-out.route.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,mBAAmB,CAAC;AAOtC,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAuCvB,CAAC"}
|
|
@@ -1,20 +1,10 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
2
|
export declare const zodSignUpSchema: z.ZodObject<{
|
|
3
|
-
email: z.
|
|
4
|
-
name: z.
|
|
3
|
+
email: z.ZodEmail;
|
|
4
|
+
name: z.ZodString;
|
|
5
5
|
password: z.ZodString;
|
|
6
6
|
newsletter: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
|
|
7
|
-
},
|
|
8
|
-
email: string;
|
|
9
|
-
name: string;
|
|
10
|
-
password: string;
|
|
11
|
-
newsletter?: boolean | undefined;
|
|
12
|
-
}, {
|
|
13
|
-
email: string;
|
|
14
|
-
name: string;
|
|
15
|
-
password: string;
|
|
16
|
-
newsletter?: boolean | undefined;
|
|
17
|
-
}>;
|
|
7
|
+
}, z.core.$strip>;
|
|
18
8
|
export declare const signUpRoute: {
|
|
19
9
|
handler: (c: import("hono").Context<import("../../../middlewares/global.middleware").EnvVitNode, "/sign_up", {
|
|
20
10
|
in: {
|
|
@@ -50,21 +40,11 @@ export declare const signUpRoute: {
|
|
|
50
40
|
content: {
|
|
51
41
|
'application/json': {
|
|
52
42
|
schema: z.ZodObject<{
|
|
53
|
-
email: z.
|
|
54
|
-
name: z.
|
|
43
|
+
email: z.ZodEmail;
|
|
44
|
+
name: z.ZodString;
|
|
55
45
|
password: z.ZodString;
|
|
56
46
|
newsletter: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
|
|
57
|
-
},
|
|
58
|
-
email: string;
|
|
59
|
-
name: string;
|
|
60
|
-
password: string;
|
|
61
|
-
newsletter?: boolean | undefined;
|
|
62
|
-
}, {
|
|
63
|
-
email: string;
|
|
64
|
-
name: string;
|
|
65
|
-
password: string;
|
|
66
|
-
newsletter?: boolean | undefined;
|
|
67
|
-
}>;
|
|
47
|
+
}, z.core.$strip>;
|
|
68
48
|
};
|
|
69
49
|
};
|
|
70
50
|
};
|
|
@@ -76,16 +56,8 @@ export declare const signUpRoute: {
|
|
|
76
56
|
schema: z.ZodObject<{
|
|
77
57
|
id: z.ZodNumber;
|
|
78
58
|
emailVerified: z.ZodBoolean;
|
|
79
|
-
email: z.
|
|
80
|
-
},
|
|
81
|
-
email: string;
|
|
82
|
-
id: number;
|
|
83
|
-
emailVerified: boolean;
|
|
84
|
-
}, {
|
|
85
|
-
email: string;
|
|
86
|
-
id: number;
|
|
87
|
-
emailVerified: boolean;
|
|
88
|
-
}>;
|
|
59
|
+
email: z.ZodEmail;
|
|
60
|
+
}, z.core.$strip>;
|
|
89
61
|
};
|
|
90
62
|
};
|
|
91
63
|
description: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sign-up.route.d.ts","sourceRoot":"","sources":["../../../../../../src/api/modules/users/routes/sign-up.route.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAWxB,eAAO,MAAM,eAAe
|
|
1
|
+
{"version":3,"file":"sign-up.route.d.ts","sourceRoot":"","sources":["../../../../../../src/api/modules/users/routes/sign-up.route.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAWxB,eAAO,MAAM,eAAe;;;;;iBAe1B,CAAC;AAEH,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAwDtB,CAAC"}
|
|
@@ -6,7 +6,7 @@ import { CONFIG_PLUGIN } from "../../../../config.js";
|
|
|
6
6
|
import { SessionModel } from "../../../models/session.js";
|
|
7
7
|
const nameRegex = /^(?!.* {2})[\p{L}\p{N}._@ -]*$/u;
|
|
8
8
|
export const zodSignUpSchema = z.object({
|
|
9
|
-
email: z.
|
|
9
|
+
email: z.email().toLowerCase().openapi({
|
|
10
10
|
example: 'test@test.com'
|
|
11
11
|
}),
|
|
12
12
|
name: z.string().openapi({
|
|
@@ -43,7 +43,7 @@ export const signUpRoute = buildRoute({
|
|
|
43
43
|
schema: z.object({
|
|
44
44
|
id: z.number(),
|
|
45
45
|
emailVerified: z.boolean(),
|
|
46
|
-
email: z.
|
|
46
|
+
email: z.email()
|
|
47
47
|
})
|
|
48
48
|
}
|
|
49
49
|
},
|
|
@@ -30,7 +30,7 @@ export const testRoute = buildRoute({
|
|
|
30
30
|
await c.get('email').send({
|
|
31
31
|
to: 'ithereplay@gmail.com',
|
|
32
32
|
subject: 'Test Email',
|
|
33
|
-
content:
|
|
33
|
+
content: ({ locale })=>`This is a test email in ${locale} locale.`
|
|
34
34
|
});
|
|
35
35
|
// throw new Error('Test error');
|
|
36
36
|
await c.get('log').warn('This is a test warn log');
|
|
@@ -36,21 +36,11 @@ export declare const callbackRoute: {
|
|
|
36
36
|
request: {
|
|
37
37
|
params: z.ZodObject<{
|
|
38
38
|
providerId: z.ZodString;
|
|
39
|
-
},
|
|
40
|
-
providerId: string;
|
|
41
|
-
}, {
|
|
42
|
-
providerId: string;
|
|
43
|
-
}>;
|
|
39
|
+
}, z.core.$strip>;
|
|
44
40
|
query: z.ZodObject<{
|
|
45
41
|
code: z.ZodString;
|
|
46
42
|
state: z.ZodString;
|
|
47
|
-
},
|
|
48
|
-
code: string;
|
|
49
|
-
state: string;
|
|
50
|
-
}, {
|
|
51
|
-
code: string;
|
|
52
|
-
state: string;
|
|
53
|
-
}>;
|
|
43
|
+
}, z.core.$strip>;
|
|
54
44
|
};
|
|
55
45
|
responses: {
|
|
56
46
|
200: {
|
|
@@ -59,13 +49,7 @@ export declare const callbackRoute: {
|
|
|
59
49
|
schema: z.ZodObject<{
|
|
60
50
|
id: z.ZodNumber;
|
|
61
51
|
token: z.ZodString;
|
|
62
|
-
},
|
|
63
|
-
token: string;
|
|
64
|
-
id: number;
|
|
65
|
-
}, {
|
|
66
|
-
token: string;
|
|
67
|
-
id: number;
|
|
68
|
-
}>;
|
|
52
|
+
}, z.core.$strip>;
|
|
69
53
|
};
|
|
70
54
|
};
|
|
71
55
|
description: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"callback.route.d.ts","sourceRoot":"","sources":["../../../../../../../src/api/modules/users/sso/routes/callback.route.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAOxB,eAAO,MAAM,aAAa
|
|
1
|
+
{"version":3,"file":"callback.route.d.ts","sourceRoot":"","sources":["../../../../../../../src/api/modules/users/sso/routes/callback.route.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAOxB,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAuCxB,CAAC"}
|