@zyacreatives/shared 2.1.27 → 2.1.30
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/constants.d.ts +12 -4
- package/dist/constants.js +16 -6
- package/dist/schemas/auth.d.ts +13 -0
- package/dist/schemas/auth.js +43 -0
- package/dist/schemas/brand.d.ts +4 -4
- package/dist/schemas/common.d.ts +1 -1
- package/dist/schemas/creative.d.ts +4 -4
- package/dist/schemas/index.d.ts +1 -0
- package/dist/schemas/index.js +1 -0
- package/dist/schemas/job-application.d.ts +4 -4
- package/dist/schemas/project.d.ts +4 -4
- package/dist/schemas/user.d.ts +26 -42
- package/dist/schemas/user.js +4 -2
- package/dist/types/auth.d.ts +4 -0
- package/dist/types/auth.js +2 -0
- package/dist/types/index.d.ts +1 -0
- package/dist/types/index.js +1 -0
- package/package.json +1 -1
- package/src/constants.ts +330 -316
- package/src/schemas/auth.ts +43 -0
- package/src/schemas/index.ts +1 -0
- package/src/schemas/user.ts +7 -5
- package/src/types/auth.ts +5 -0
- package/src/types/index.ts +1 -0
- package/dist/types/enums.d.ts +0 -97
- package/dist/types/enums.js +0 -110
package/dist/constants.d.ts
CHANGED
|
@@ -25,11 +25,7 @@ export declare const ONBOARDING_PAGES: {
|
|
|
25
25
|
readonly USERNAME_SELECTION: "USERNAME_SELECTION";
|
|
26
26
|
readonly ACCOUNT_TYPE_SELECTION: "ACCOUNT_TYPE_SELECTION";
|
|
27
27
|
readonly CREATIVE_PROFILE_DETAILS: "CREATIVE_PROFILE_DETAILS";
|
|
28
|
-
readonly CREATIVE_PROFILE_CUSTOMIZE_FEED: "CREATIVE_PROFILE_CUSTOMIZE_FEED";
|
|
29
|
-
readonly CREATIVE_PROFILE_PORTFOLIO: "CREATIVE_PROFILE_PORTFOLIO";
|
|
30
28
|
readonly BRAND_PROFILE_DETAILS: "BRAND_PROFILE_DETAILS";
|
|
31
|
-
readonly BRAND_PROFILE_CUSTOMIZE_FEED: "BRAND_PROFILE_CUSTOMIZE_FEED";
|
|
32
|
-
readonly BRAND_PROFILE_PORTFOLIO: "BRAND_PROFILE_PORTFOLIO";
|
|
33
29
|
readonly INVESTOR_PROFILE_DETAILS: "INVESTOR_PROFILE_DETAILS";
|
|
34
30
|
readonly INVESTOR_INVESTMENT_FOCUS: "INVESTOR_INVESTMENT_FOCUS";
|
|
35
31
|
readonly INVESTOR_VERIFICATION: "INVESTOR_VERIFICATION";
|
|
@@ -211,6 +207,18 @@ export declare const APPLICATION_STATUS: {
|
|
|
211
207
|
readonly OFFERED: "Offered";
|
|
212
208
|
readonly HIRED: "Hired";
|
|
213
209
|
};
|
|
210
|
+
export declare const NOTIFICATION_TYPES: {
|
|
211
|
+
readonly FOLLOW: "Follow";
|
|
212
|
+
readonly LIKE: "Like";
|
|
213
|
+
readonly COMMENT: "Comment";
|
|
214
|
+
readonly REPLY: "Reply";
|
|
215
|
+
readonly MESSAGE: "Message";
|
|
216
|
+
readonly JOB_APPLICATION: "Job Application";
|
|
217
|
+
readonly APPLICATION_STATUS_CHANGE: "Application Status Change";
|
|
218
|
+
readonly SYSTEM_STRIKE: "System Strike";
|
|
219
|
+
readonly PROJECT_FEATURED: "Project Featured";
|
|
220
|
+
};
|
|
221
|
+
export type NotificationType = (typeof NOTIFICATION_TYPES)[keyof typeof NOTIFICATION_TYPES];
|
|
214
222
|
export type ApplicationStatus = (typeof APPLICATION_STATUS)[keyof typeof APPLICATION_STATUS];
|
|
215
223
|
export type ActivityType = (typeof ACTIVITY_TYPES)[keyof typeof ACTIVITY_TYPES];
|
|
216
224
|
export type PostBadgeType = (typeof POST_BADGE_TYPES)[keyof typeof POST_BADGE_TYPES];
|
package/dist/constants.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.DEFAULT_DISCIPLINES = exports.API_ROUTES = exports.APPLICATION_STATUS = exports.LINK_TYPES = exports.ACTIVITY_TYPES = exports.POST_BADGE_TYPES = exports.JOB_STATUS = exports.WAGES_CURRENCY = exports.GIG_TYPE = exports.MESSAGE_TYPES = exports.JOB_LOCATIONS = exports.JOB_SECTIONS = exports.WAGE_TYPES = exports.JOB_AVAILABILITY_TYPES = exports.EMPLOYMENT_TYPE = exports.WORK_MODE = exports.JOB_TYPE = exports.POST_TYPES = exports.ACTIVITY_PARENT_TYPES = exports.INVESTOR_VERIFICATION_DOCUMENT_TYPES = exports.INVESTOR_VERIFICATION_DOCUMENT_STATUSES = exports.GEOGRAPHIC_FOCUS = exports.INVESTMENT_SIZES = exports.INVESTOR_TYPES = exports.ONBOARDING_PAGES = exports.EXPERIENCE_LEVELS = exports.CLIENT_TYPES = exports.USER_STATUSES = exports.ROLES = void 0;
|
|
3
|
+
exports.DEFAULT_DISCIPLINES = exports.API_ROUTES = exports.NOTIFICATION_TYPES = exports.APPLICATION_STATUS = exports.LINK_TYPES = exports.ACTIVITY_TYPES = exports.POST_BADGE_TYPES = exports.JOB_STATUS = exports.WAGES_CURRENCY = exports.GIG_TYPE = exports.MESSAGE_TYPES = exports.JOB_LOCATIONS = exports.JOB_SECTIONS = exports.WAGE_TYPES = exports.JOB_AVAILABILITY_TYPES = exports.EMPLOYMENT_TYPE = exports.WORK_MODE = exports.JOB_TYPE = exports.POST_TYPES = exports.ACTIVITY_PARENT_TYPES = exports.INVESTOR_VERIFICATION_DOCUMENT_TYPES = exports.INVESTOR_VERIFICATION_DOCUMENT_STATUSES = exports.GEOGRAPHIC_FOCUS = exports.INVESTMENT_SIZES = exports.INVESTOR_TYPES = exports.ONBOARDING_PAGES = exports.EXPERIENCE_LEVELS = exports.CLIENT_TYPES = exports.USER_STATUSES = exports.ROLES = void 0;
|
|
4
4
|
exports.ROLES = {
|
|
5
5
|
CREATIVE: "CREATIVE",
|
|
6
6
|
BRAND: "BRAND",
|
|
@@ -28,11 +28,7 @@ exports.ONBOARDING_PAGES = {
|
|
|
28
28
|
USERNAME_SELECTION: "USERNAME_SELECTION",
|
|
29
29
|
ACCOUNT_TYPE_SELECTION: "ACCOUNT_TYPE_SELECTION",
|
|
30
30
|
CREATIVE_PROFILE_DETAILS: "CREATIVE_PROFILE_DETAILS",
|
|
31
|
-
CREATIVE_PROFILE_CUSTOMIZE_FEED: "CREATIVE_PROFILE_CUSTOMIZE_FEED",
|
|
32
|
-
CREATIVE_PROFILE_PORTFOLIO: "CREATIVE_PROFILE_PORTFOLIO",
|
|
33
31
|
BRAND_PROFILE_DETAILS: "BRAND_PROFILE_DETAILS",
|
|
34
|
-
BRAND_PROFILE_CUSTOMIZE_FEED: "BRAND_PROFILE_CUSTOMIZE_FEED",
|
|
35
|
-
BRAND_PROFILE_PORTFOLIO: "BRAND_PROFILE_PORTFOLIO",
|
|
36
32
|
INVESTOR_PROFILE_DETAILS: "INVESTOR_PROFILE_DETAILS",
|
|
37
33
|
INVESTOR_INVESTMENT_FOCUS: "INVESTOR_INVESTMENT_FOCUS",
|
|
38
34
|
INVESTOR_VERIFICATION: "INVESTOR_VERIFICATION",
|
|
@@ -213,6 +209,17 @@ exports.APPLICATION_STATUS = {
|
|
|
213
209
|
OFFERED: "Offered",
|
|
214
210
|
HIRED: "Hired",
|
|
215
211
|
};
|
|
212
|
+
exports.NOTIFICATION_TYPES = {
|
|
213
|
+
FOLLOW: "Follow",
|
|
214
|
+
LIKE: "Like",
|
|
215
|
+
COMMENT: "Comment",
|
|
216
|
+
REPLY: "Reply",
|
|
217
|
+
MESSAGE: "Message",
|
|
218
|
+
JOB_APPLICATION: "Job Application",
|
|
219
|
+
APPLICATION_STATUS_CHANGE: "Application Status Change",
|
|
220
|
+
SYSTEM_STRIKE: "System Strike",
|
|
221
|
+
PROJECT_FEATURED: "Project Featured",
|
|
222
|
+
};
|
|
216
223
|
exports.API_ROUTES = {
|
|
217
224
|
healthCheck: "/health",
|
|
218
225
|
username: {
|
|
@@ -329,7 +336,10 @@ exports.DEFAULT_DISCIPLINES = [
|
|
|
329
336
|
{ name: "Data Science & Analysis", slug: "data_science_analysis" },
|
|
330
337
|
{ name: "Data Visualization", slug: "data_visualization" },
|
|
331
338
|
{ name: "Digital Art", slug: "digital_art" },
|
|
332
|
-
{
|
|
339
|
+
{
|
|
340
|
+
name: "Digital Painting & Matte Painting",
|
|
341
|
+
slug: "digital_painting_matte",
|
|
342
|
+
},
|
|
333
343
|
{ name: "E-commerce & Store Design", slug: "ecommerce_store_design" },
|
|
334
344
|
{ name: "Fashion & Style", slug: "fashion_style" },
|
|
335
345
|
{ name: "Food Content", slug: "food_content" },
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import z from "zod";
|
|
2
|
+
export declare const RegisterSchema: z.ZodObject<{
|
|
3
|
+
firstName: z.ZodString;
|
|
4
|
+
lastName: z.ZodString;
|
|
5
|
+
email: z.ZodEmail;
|
|
6
|
+
username: z.ZodString;
|
|
7
|
+
password: z.ZodString;
|
|
8
|
+
}, z.core.$strip>;
|
|
9
|
+
export declare const LoginSchema: z.ZodObject<{
|
|
10
|
+
identifier: z.ZodString;
|
|
11
|
+
password: z.ZodString;
|
|
12
|
+
rememberMe: z.ZodBoolean;
|
|
13
|
+
}, z.core.$strip>;
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.LoginSchema = exports.RegisterSchema = void 0;
|
|
7
|
+
const zod_1 = __importDefault(require("zod"));
|
|
8
|
+
exports.RegisterSchema = zod_1.default.object({
|
|
9
|
+
firstName: zod_1.default.string().max(255, { message: "First name is too long" }),
|
|
10
|
+
lastName: zod_1.default.string().max(255, { message: "Last name is too long" }),
|
|
11
|
+
email: zod_1.default
|
|
12
|
+
.email({ message: "Enter a valid email address" })
|
|
13
|
+
.max(255, { message: "Email is too long" }),
|
|
14
|
+
username: zod_1.default
|
|
15
|
+
.string()
|
|
16
|
+
.min(3, { message: "Username is too short" })
|
|
17
|
+
.max(32, { message: "Username must be at most 32 characters" })
|
|
18
|
+
.regex(/^[a-zA-Z0-9_]+$/, {
|
|
19
|
+
error: "Username can only contain letters, numbers, and underscores",
|
|
20
|
+
}),
|
|
21
|
+
password: zod_1.default
|
|
22
|
+
.string()
|
|
23
|
+
.min(8, { message: "Password must be at least 8 characters" })
|
|
24
|
+
.max(100, { message: "Password must be at most 100 characters" }),
|
|
25
|
+
});
|
|
26
|
+
exports.LoginSchema = zod_1.default.object({
|
|
27
|
+
identifier: zod_1.default
|
|
28
|
+
.string()
|
|
29
|
+
.trim()
|
|
30
|
+
.min(1, { message: "Email or username is required" })
|
|
31
|
+
.refine((val) => {
|
|
32
|
+
const isEmail = zod_1.default.email().safeParse(val).success;
|
|
33
|
+
const isUsername = /^[a-zA-Z0-9_]{3,20}$/.test(val);
|
|
34
|
+
return isEmail || isUsername;
|
|
35
|
+
}, {
|
|
36
|
+
message: "Enter a valid email or a username (3–20 characters, letters/numbers/underscore)",
|
|
37
|
+
}),
|
|
38
|
+
password: zod_1.default
|
|
39
|
+
.string()
|
|
40
|
+
.min(8, { message: "Password must be at least 8 characters" })
|
|
41
|
+
.max(100, { message: "Password must be at most 100 characters" }),
|
|
42
|
+
rememberMe: zod_1.default.boolean(),
|
|
43
|
+
});
|
package/dist/schemas/brand.d.ts
CHANGED
|
@@ -181,9 +181,9 @@ export declare const BrandWithUserEntitySchema: z.ZodObject<{
|
|
|
181
181
|
createdAt: z.ZodOptional<z.ZodCoercedDate<unknown>>;
|
|
182
182
|
updatedAt: z.ZodCoercedDate<unknown>;
|
|
183
183
|
user: z.ZodObject<{
|
|
184
|
-
id: z.ZodCUID2;
|
|
185
|
-
username: z.ZodOptional<z.ZodString>;
|
|
186
184
|
email: z.ZodString;
|
|
185
|
+
username: z.ZodOptional<z.ZodString>;
|
|
186
|
+
id: z.ZodCUID2;
|
|
187
187
|
name: z.ZodOptional<z.ZodString>;
|
|
188
188
|
image: z.ZodOptional<z.ZodString>;
|
|
189
189
|
role: z.ZodEnum<{
|
|
@@ -210,9 +210,9 @@ export declare const SearchBrandOutputSchema: z.ZodObject<{
|
|
|
210
210
|
createdAt: z.ZodOptional<z.ZodCoercedDate<unknown>>;
|
|
211
211
|
updatedAt: z.ZodCoercedDate<unknown>;
|
|
212
212
|
user: z.ZodObject<{
|
|
213
|
-
id: z.ZodCUID2;
|
|
214
|
-
username: z.ZodOptional<z.ZodString>;
|
|
215
213
|
email: z.ZodString;
|
|
214
|
+
username: z.ZodOptional<z.ZodString>;
|
|
215
|
+
id: z.ZodCUID2;
|
|
216
216
|
name: z.ZodOptional<z.ZodString>;
|
|
217
217
|
image: z.ZodOptional<z.ZodString>;
|
|
218
218
|
role: z.ZodEnum<{
|
package/dist/schemas/common.d.ts
CHANGED
|
@@ -2,8 +2,8 @@ import { z } from "@hono/zod-openapi";
|
|
|
2
2
|
export declare const CuidSchema: z.ZodCUID2;
|
|
3
3
|
export declare const UserIdentifierSchema: z.ZodObject<{
|
|
4
4
|
by: z.ZodDefault<z.ZodOptional<z.ZodEnum<{
|
|
5
|
-
id: "id";
|
|
6
5
|
username: "username";
|
|
6
|
+
id: "id";
|
|
7
7
|
}>>>;
|
|
8
8
|
}, z.core.$strip>;
|
|
9
9
|
export type UserIdentifier = z.infer<typeof UserIdentifierSchema>;
|
|
@@ -272,9 +272,9 @@ export declare const CreativeWithUserEntitySchema: z.ZodObject<{
|
|
|
272
272
|
createdAt: z.ZodOptional<z.ZodCoercedDate<unknown>>;
|
|
273
273
|
updatedAt: z.ZodCoercedDate<unknown>;
|
|
274
274
|
user: z.ZodObject<{
|
|
275
|
-
id: z.ZodCUID2;
|
|
276
|
-
username: z.ZodOptional<z.ZodString>;
|
|
277
275
|
email: z.ZodString;
|
|
276
|
+
username: z.ZodOptional<z.ZodString>;
|
|
277
|
+
id: z.ZodCUID2;
|
|
278
278
|
name: z.ZodOptional<z.ZodString>;
|
|
279
279
|
image: z.ZodOptional<z.ZodString>;
|
|
280
280
|
role: z.ZodEnum<{
|
|
@@ -308,9 +308,9 @@ export declare const SearchCreativeOutputSchema: z.ZodObject<{
|
|
|
308
308
|
createdAt: z.ZodOptional<z.ZodCoercedDate<unknown>>;
|
|
309
309
|
updatedAt: z.ZodCoercedDate<unknown>;
|
|
310
310
|
user: z.ZodObject<{
|
|
311
|
-
id: z.ZodCUID2;
|
|
312
|
-
username: z.ZodOptional<z.ZodString>;
|
|
313
311
|
email: z.ZodString;
|
|
312
|
+
username: z.ZodOptional<z.ZodString>;
|
|
313
|
+
id: z.ZodCUID2;
|
|
314
314
|
name: z.ZodOptional<z.ZodString>;
|
|
315
315
|
image: z.ZodOptional<z.ZodString>;
|
|
316
316
|
role: z.ZodEnum<{
|
package/dist/schemas/index.d.ts
CHANGED
package/dist/schemas/index.js
CHANGED
|
@@ -14,6 +14,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./auth"), exports);
|
|
17
18
|
__exportStar(require("./brand"), exports);
|
|
18
19
|
__exportStar(require("./common"), exports);
|
|
19
20
|
__exportStar(require("./creative"), exports);
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { z } from "@hono/zod-openapi";
|
|
2
2
|
export declare const MinimalJobApplicationEntitySchema: z.ZodObject<{
|
|
3
3
|
user: z.ZodObject<{
|
|
4
|
-
id: z.ZodCUID2;
|
|
5
|
-
username: z.ZodOptional<z.ZodString>;
|
|
6
4
|
email: z.ZodString;
|
|
5
|
+
username: z.ZodOptional<z.ZodString>;
|
|
6
|
+
id: z.ZodCUID2;
|
|
7
7
|
name: z.ZodOptional<z.ZodString>;
|
|
8
8
|
image: z.ZodOptional<z.ZodString>;
|
|
9
9
|
role: z.ZodEnum<{
|
|
@@ -83,9 +83,9 @@ export declare const JobApplicationEntitySchema: z.ZodObject<{
|
|
|
83
83
|
lastName: z.ZodOptional<z.ZodString>;
|
|
84
84
|
jobId: z.ZodCUID2;
|
|
85
85
|
user: z.ZodObject<{
|
|
86
|
-
id: z.ZodCUID2;
|
|
87
|
-
username: z.ZodOptional<z.ZodString>;
|
|
88
86
|
email: z.ZodString;
|
|
87
|
+
username: z.ZodOptional<z.ZodString>;
|
|
88
|
+
id: z.ZodCUID2;
|
|
89
89
|
name: z.ZodOptional<z.ZodString>;
|
|
90
90
|
image: z.ZodOptional<z.ZodString>;
|
|
91
91
|
role: z.ZodEnum<{
|
|
@@ -68,9 +68,9 @@ export declare const ProjectDetailsEntitySchema: z.ZodObject<{
|
|
|
68
68
|
createdAt: z.ZodCoercedDate<unknown>;
|
|
69
69
|
updatedAt: z.ZodCoercedDate<unknown>;
|
|
70
70
|
user: z.ZodObject<{
|
|
71
|
-
id: z.ZodCUID2;
|
|
72
|
-
username: z.ZodOptional<z.ZodString>;
|
|
73
71
|
email: z.ZodString;
|
|
72
|
+
username: z.ZodOptional<z.ZodString>;
|
|
73
|
+
id: z.ZodCUID2;
|
|
74
74
|
name: z.ZodOptional<z.ZodString>;
|
|
75
75
|
image: z.ZodOptional<z.ZodString>;
|
|
76
76
|
role: z.ZodEnum<{
|
|
@@ -278,9 +278,9 @@ export declare const GetProjectOutputSchema: z.ZodObject<{
|
|
|
278
278
|
createdAt: z.ZodCoercedDate<unknown>;
|
|
279
279
|
updatedAt: z.ZodCoercedDate<unknown>;
|
|
280
280
|
user: z.ZodObject<{
|
|
281
|
-
id: z.ZodCUID2;
|
|
282
|
-
username: z.ZodOptional<z.ZodString>;
|
|
283
281
|
email: z.ZodString;
|
|
282
|
+
username: z.ZodOptional<z.ZodString>;
|
|
283
|
+
id: z.ZodCUID2;
|
|
284
284
|
name: z.ZodOptional<z.ZodString>;
|
|
285
285
|
image: z.ZodOptional<z.ZodString>;
|
|
286
286
|
role: z.ZodEnum<{
|
package/dist/schemas/user.d.ts
CHANGED
|
@@ -23,11 +23,7 @@ export declare const UserEntitySchema: z.ZodObject<{
|
|
|
23
23
|
USERNAME_SELECTION: "USERNAME_SELECTION";
|
|
24
24
|
ACCOUNT_TYPE_SELECTION: "ACCOUNT_TYPE_SELECTION";
|
|
25
25
|
CREATIVE_PROFILE_DETAILS: "CREATIVE_PROFILE_DETAILS";
|
|
26
|
-
CREATIVE_PROFILE_CUSTOMIZE_FEED: "CREATIVE_PROFILE_CUSTOMIZE_FEED";
|
|
27
|
-
CREATIVE_PROFILE_PORTFOLIO: "CREATIVE_PROFILE_PORTFOLIO";
|
|
28
26
|
BRAND_PROFILE_DETAILS: "BRAND_PROFILE_DETAILS";
|
|
29
|
-
BRAND_PROFILE_CUSTOMIZE_FEED: "BRAND_PROFILE_CUSTOMIZE_FEED";
|
|
30
|
-
BRAND_PROFILE_PORTFOLIO: "BRAND_PROFILE_PORTFOLIO";
|
|
31
27
|
INVESTOR_PROFILE_DETAILS: "INVESTOR_PROFILE_DETAILS";
|
|
32
28
|
INVESTOR_INVESTMENT_FOCUS: "INVESTOR_INVESTMENT_FOCUS";
|
|
33
29
|
INVESTOR_VERIFICATION: "INVESTOR_VERIFICATION";
|
|
@@ -37,9 +33,9 @@ export declare const UserEntitySchema: z.ZodObject<{
|
|
|
37
33
|
updatedAt: z.ZodCoercedDate<unknown>;
|
|
38
34
|
}, z.core.$strip>;
|
|
39
35
|
export declare const MinimalUserSchema: z.ZodObject<{
|
|
40
|
-
id: z.ZodCUID2;
|
|
41
|
-
username: z.ZodOptional<z.ZodString>;
|
|
42
36
|
email: z.ZodString;
|
|
37
|
+
username: z.ZodOptional<z.ZodString>;
|
|
38
|
+
id: z.ZodCUID2;
|
|
43
39
|
name: z.ZodOptional<z.ZodString>;
|
|
44
40
|
image: z.ZodOptional<z.ZodString>;
|
|
45
41
|
role: z.ZodEnum<{
|
|
@@ -78,11 +74,7 @@ export declare const UserProfileEntitySchema: z.ZodObject<{
|
|
|
78
74
|
USERNAME_SELECTION: "USERNAME_SELECTION";
|
|
79
75
|
ACCOUNT_TYPE_SELECTION: "ACCOUNT_TYPE_SELECTION";
|
|
80
76
|
CREATIVE_PROFILE_DETAILS: "CREATIVE_PROFILE_DETAILS";
|
|
81
|
-
CREATIVE_PROFILE_CUSTOMIZE_FEED: "CREATIVE_PROFILE_CUSTOMIZE_FEED";
|
|
82
|
-
CREATIVE_PROFILE_PORTFOLIO: "CREATIVE_PROFILE_PORTFOLIO";
|
|
83
77
|
BRAND_PROFILE_DETAILS: "BRAND_PROFILE_DETAILS";
|
|
84
|
-
BRAND_PROFILE_CUSTOMIZE_FEED: "BRAND_PROFILE_CUSTOMIZE_FEED";
|
|
85
|
-
BRAND_PROFILE_PORTFOLIO: "BRAND_PROFILE_PORTFOLIO";
|
|
86
78
|
INVESTOR_PROFILE_DETAILS: "INVESTOR_PROFILE_DETAILS";
|
|
87
79
|
INVESTOR_INVESTMENT_FOCUS: "INVESTOR_INVESTMENT_FOCUS";
|
|
88
80
|
INVESTOR_VERIFICATION: "INVESTOR_VERIFICATION";
|
|
@@ -298,9 +290,9 @@ export declare const GetUserFollowersInputSchema: z.ZodObject<{
|
|
|
298
290
|
offset: z.ZodOptional<z.ZodNumber>;
|
|
299
291
|
}, z.core.$strip>;
|
|
300
292
|
export declare const UserWithFollowingEntitySchema: z.ZodObject<{
|
|
301
|
-
id: z.ZodCUID2;
|
|
302
|
-
username: z.ZodOptional<z.ZodString>;
|
|
303
293
|
email: z.ZodString;
|
|
294
|
+
username: z.ZodOptional<z.ZodString>;
|
|
295
|
+
id: z.ZodCUID2;
|
|
304
296
|
name: z.ZodOptional<z.ZodString>;
|
|
305
297
|
image: z.ZodOptional<z.ZodString>;
|
|
306
298
|
role: z.ZodEnum<{
|
|
@@ -310,9 +302,9 @@ export declare const UserWithFollowingEntitySchema: z.ZodObject<{
|
|
|
310
302
|
ADMIN: "ADMIN";
|
|
311
303
|
}>;
|
|
312
304
|
following: z.ZodArray<z.ZodObject<{
|
|
313
|
-
id: z.ZodCUID2;
|
|
314
|
-
username: z.ZodOptional<z.ZodString>;
|
|
315
305
|
email: z.ZodString;
|
|
306
|
+
username: z.ZodOptional<z.ZodString>;
|
|
307
|
+
id: z.ZodCUID2;
|
|
316
308
|
name: z.ZodOptional<z.ZodString>;
|
|
317
309
|
image: z.ZodOptional<z.ZodString>;
|
|
318
310
|
role: z.ZodEnum<{
|
|
@@ -324,9 +316,9 @@ export declare const UserWithFollowingEntitySchema: z.ZodObject<{
|
|
|
324
316
|
}, z.core.$strip>>;
|
|
325
317
|
}, z.core.$strip>;
|
|
326
318
|
export declare const UserWithFollowersEntitySchema: z.ZodObject<{
|
|
327
|
-
id: z.ZodCUID2;
|
|
328
|
-
username: z.ZodOptional<z.ZodString>;
|
|
329
319
|
email: z.ZodString;
|
|
320
|
+
username: z.ZodOptional<z.ZodString>;
|
|
321
|
+
id: z.ZodCUID2;
|
|
330
322
|
name: z.ZodOptional<z.ZodString>;
|
|
331
323
|
image: z.ZodOptional<z.ZodString>;
|
|
332
324
|
role: z.ZodEnum<{
|
|
@@ -336,9 +328,9 @@ export declare const UserWithFollowersEntitySchema: z.ZodObject<{
|
|
|
336
328
|
ADMIN: "ADMIN";
|
|
337
329
|
}>;
|
|
338
330
|
followers: z.ZodArray<z.ZodObject<{
|
|
339
|
-
id: z.ZodCUID2;
|
|
340
|
-
username: z.ZodOptional<z.ZodString>;
|
|
341
331
|
email: z.ZodString;
|
|
332
|
+
username: z.ZodOptional<z.ZodString>;
|
|
333
|
+
id: z.ZodCUID2;
|
|
342
334
|
name: z.ZodOptional<z.ZodString>;
|
|
343
335
|
image: z.ZodOptional<z.ZodString>;
|
|
344
336
|
role: z.ZodEnum<{
|
|
@@ -405,9 +397,9 @@ export declare const UserWithPostsEntitySchema: z.ZodObject<{
|
|
|
405
397
|
}, z.core.$strip>;
|
|
406
398
|
export declare const GetUserFollowingOutputSchema: z.ZodObject<{
|
|
407
399
|
results: z.ZodObject<{
|
|
408
|
-
id: z.ZodCUID2;
|
|
409
|
-
username: z.ZodOptional<z.ZodString>;
|
|
410
400
|
email: z.ZodString;
|
|
401
|
+
username: z.ZodOptional<z.ZodString>;
|
|
402
|
+
id: z.ZodCUID2;
|
|
411
403
|
name: z.ZodOptional<z.ZodString>;
|
|
412
404
|
image: z.ZodOptional<z.ZodString>;
|
|
413
405
|
role: z.ZodEnum<{
|
|
@@ -417,9 +409,9 @@ export declare const GetUserFollowingOutputSchema: z.ZodObject<{
|
|
|
417
409
|
ADMIN: "ADMIN";
|
|
418
410
|
}>;
|
|
419
411
|
following: z.ZodArray<z.ZodObject<{
|
|
420
|
-
id: z.ZodCUID2;
|
|
421
|
-
username: z.ZodOptional<z.ZodString>;
|
|
422
412
|
email: z.ZodString;
|
|
413
|
+
username: z.ZodOptional<z.ZodString>;
|
|
414
|
+
id: z.ZodCUID2;
|
|
423
415
|
name: z.ZodOptional<z.ZodString>;
|
|
424
416
|
image: z.ZodOptional<z.ZodString>;
|
|
425
417
|
role: z.ZodEnum<{
|
|
@@ -433,9 +425,9 @@ export declare const GetUserFollowingOutputSchema: z.ZodObject<{
|
|
|
433
425
|
}, z.core.$strip>;
|
|
434
426
|
export declare const GetUserFollowersOutputSchema: z.ZodObject<{
|
|
435
427
|
results: z.ZodObject<{
|
|
436
|
-
id: z.ZodCUID2;
|
|
437
|
-
username: z.ZodOptional<z.ZodString>;
|
|
438
428
|
email: z.ZodString;
|
|
429
|
+
username: z.ZodOptional<z.ZodString>;
|
|
430
|
+
id: z.ZodCUID2;
|
|
439
431
|
name: z.ZodOptional<z.ZodString>;
|
|
440
432
|
image: z.ZodOptional<z.ZodString>;
|
|
441
433
|
role: z.ZodEnum<{
|
|
@@ -445,9 +437,9 @@ export declare const GetUserFollowersOutputSchema: z.ZodObject<{
|
|
|
445
437
|
ADMIN: "ADMIN";
|
|
446
438
|
}>;
|
|
447
439
|
followers: z.ZodArray<z.ZodObject<{
|
|
448
|
-
id: z.ZodCUID2;
|
|
449
|
-
username: z.ZodOptional<z.ZodString>;
|
|
450
440
|
email: z.ZodString;
|
|
441
|
+
username: z.ZodOptional<z.ZodString>;
|
|
442
|
+
id: z.ZodCUID2;
|
|
451
443
|
name: z.ZodOptional<z.ZodString>;
|
|
452
444
|
image: z.ZodOptional<z.ZodString>;
|
|
453
445
|
role: z.ZodEnum<{
|
|
@@ -483,11 +475,7 @@ export declare const GetAuthenticatedUserOutputSchema: z.ZodObject<{
|
|
|
483
475
|
USERNAME_SELECTION: "USERNAME_SELECTION";
|
|
484
476
|
ACCOUNT_TYPE_SELECTION: "ACCOUNT_TYPE_SELECTION";
|
|
485
477
|
CREATIVE_PROFILE_DETAILS: "CREATIVE_PROFILE_DETAILS";
|
|
486
|
-
CREATIVE_PROFILE_CUSTOMIZE_FEED: "CREATIVE_PROFILE_CUSTOMIZE_FEED";
|
|
487
|
-
CREATIVE_PROFILE_PORTFOLIO: "CREATIVE_PROFILE_PORTFOLIO";
|
|
488
478
|
BRAND_PROFILE_DETAILS: "BRAND_PROFILE_DETAILS";
|
|
489
|
-
BRAND_PROFILE_CUSTOMIZE_FEED: "BRAND_PROFILE_CUSTOMIZE_FEED";
|
|
490
|
-
BRAND_PROFILE_PORTFOLIO: "BRAND_PROFILE_PORTFOLIO";
|
|
491
479
|
INVESTOR_PROFILE_DETAILS: "INVESTOR_PROFILE_DETAILS";
|
|
492
480
|
INVESTOR_INVESTMENT_FOCUS: "INVESTOR_INVESTMENT_FOCUS";
|
|
493
481
|
INVESTOR_VERIFICATION: "INVESTOR_VERIFICATION";
|
|
@@ -520,11 +508,7 @@ export declare const GetAuthenticatedUserProfileOutputSchema: z.ZodObject<{
|
|
|
520
508
|
USERNAME_SELECTION: "USERNAME_SELECTION";
|
|
521
509
|
ACCOUNT_TYPE_SELECTION: "ACCOUNT_TYPE_SELECTION";
|
|
522
510
|
CREATIVE_PROFILE_DETAILS: "CREATIVE_PROFILE_DETAILS";
|
|
523
|
-
CREATIVE_PROFILE_CUSTOMIZE_FEED: "CREATIVE_PROFILE_CUSTOMIZE_FEED";
|
|
524
|
-
CREATIVE_PROFILE_PORTFOLIO: "CREATIVE_PROFILE_PORTFOLIO";
|
|
525
511
|
BRAND_PROFILE_DETAILS: "BRAND_PROFILE_DETAILS";
|
|
526
|
-
BRAND_PROFILE_CUSTOMIZE_FEED: "BRAND_PROFILE_CUSTOMIZE_FEED";
|
|
527
|
-
BRAND_PROFILE_PORTFOLIO: "BRAND_PROFILE_PORTFOLIO";
|
|
528
512
|
INVESTOR_PROFILE_DETAILS: "INVESTOR_PROFILE_DETAILS";
|
|
529
513
|
INVESTOR_INVESTMENT_FOCUS: "INVESTOR_INVESTMENT_FOCUS";
|
|
530
514
|
INVESTOR_VERIFICATION: "INVESTOR_VERIFICATION";
|
|
@@ -709,9 +693,9 @@ export declare const GetAuthenticatedUserWithProjectBookmarksOutputSchema: z.Zod
|
|
|
709
693
|
}, z.core.$strip>>;
|
|
710
694
|
}, z.core.$strip>;
|
|
711
695
|
export declare const GetAuthenticatedUserWithUserFollowingOutputSchema: z.ZodObject<{
|
|
712
|
-
id: z.ZodCUID2;
|
|
713
|
-
username: z.ZodOptional<z.ZodString>;
|
|
714
696
|
email: z.ZodString;
|
|
697
|
+
username: z.ZodOptional<z.ZodString>;
|
|
698
|
+
id: z.ZodCUID2;
|
|
715
699
|
name: z.ZodOptional<z.ZodString>;
|
|
716
700
|
image: z.ZodOptional<z.ZodString>;
|
|
717
701
|
role: z.ZodEnum<{
|
|
@@ -721,9 +705,9 @@ export declare const GetAuthenticatedUserWithUserFollowingOutputSchema: z.ZodObj
|
|
|
721
705
|
ADMIN: "ADMIN";
|
|
722
706
|
}>;
|
|
723
707
|
following: z.ZodArray<z.ZodObject<{
|
|
724
|
-
id: z.ZodCUID2;
|
|
725
|
-
username: z.ZodOptional<z.ZodString>;
|
|
726
708
|
email: z.ZodString;
|
|
709
|
+
username: z.ZodOptional<z.ZodString>;
|
|
710
|
+
id: z.ZodCUID2;
|
|
727
711
|
name: z.ZodOptional<z.ZodString>;
|
|
728
712
|
image: z.ZodOptional<z.ZodString>;
|
|
729
713
|
role: z.ZodEnum<{
|
|
@@ -735,9 +719,9 @@ export declare const GetAuthenticatedUserWithUserFollowingOutputSchema: z.ZodObj
|
|
|
735
719
|
}, z.core.$strip>>;
|
|
736
720
|
}, z.core.$strip>;
|
|
737
721
|
export declare const GetAuthenticatedUserWithUserFollowersOutputSchema: z.ZodObject<{
|
|
738
|
-
id: z.ZodCUID2;
|
|
739
|
-
username: z.ZodOptional<z.ZodString>;
|
|
740
722
|
email: z.ZodString;
|
|
723
|
+
username: z.ZodOptional<z.ZodString>;
|
|
724
|
+
id: z.ZodCUID2;
|
|
741
725
|
name: z.ZodOptional<z.ZodString>;
|
|
742
726
|
image: z.ZodOptional<z.ZodString>;
|
|
743
727
|
role: z.ZodEnum<{
|
|
@@ -747,9 +731,9 @@ export declare const GetAuthenticatedUserWithUserFollowersOutputSchema: z.ZodObj
|
|
|
747
731
|
ADMIN: "ADMIN";
|
|
748
732
|
}>;
|
|
749
733
|
followers: z.ZodArray<z.ZodObject<{
|
|
750
|
-
id: z.ZodCUID2;
|
|
751
|
-
username: z.ZodOptional<z.ZodString>;
|
|
752
734
|
email: z.ZodString;
|
|
735
|
+
username: z.ZodOptional<z.ZodString>;
|
|
736
|
+
id: z.ZodCUID2;
|
|
753
737
|
name: z.ZodOptional<z.ZodString>;
|
|
754
738
|
image: z.ZodOptional<z.ZodString>;
|
|
755
739
|
role: z.ZodEnum<{
|
package/dist/schemas/user.js
CHANGED
|
@@ -112,10 +112,12 @@ exports.UserWithFollowersEntitySchema = exports.MinimalUserSchema.extend({
|
|
|
112
112
|
.array(exports.MinimalUserSchema)
|
|
113
113
|
.openapi({ description: "List of users who follow this user." }),
|
|
114
114
|
}).openapi("UserWithFollowersEntity");
|
|
115
|
-
exports.UserWithPostsEntitySchema = zod_openapi_1.z
|
|
115
|
+
exports.UserWithPostsEntitySchema = zod_openapi_1.z
|
|
116
|
+
.object({
|
|
116
117
|
userId: zod_openapi_1.z.cuid2(),
|
|
117
118
|
posts: zod_openapi_1.z.array(post_1.PostWithFilesEntitySchema),
|
|
118
|
-
})
|
|
119
|
+
})
|
|
120
|
+
.openapi("UserWithPostsEntity");
|
|
119
121
|
exports.GetUserFollowingOutputSchema = zod_openapi_1.z.object({
|
|
120
122
|
results: exports.UserWithFollowingEntitySchema,
|
|
121
123
|
});
|
package/dist/types/index.d.ts
CHANGED
package/dist/types/index.js
CHANGED
|
@@ -14,6 +14,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./auth"), exports);
|
|
17
18
|
__exportStar(require("./brand"), exports);
|
|
18
19
|
__exportStar(require("./common"), exports);
|
|
19
20
|
__exportStar(require("./creative"), exports);
|