@zyacreatives/shared 2.5.19 → 2.5.21
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/schemas/project.d.ts +42 -17
- package/dist/schemas/project.js +18 -12
- package/dist/schemas/user.d.ts +5 -5
- package/package.json +1 -1
- package/src/schemas/project.ts +20 -14
|
@@ -43,7 +43,7 @@ export declare const ProjectEntitySchema: z.ZodObject<{
|
|
|
43
43
|
readonly GROWTH: "Growth";
|
|
44
44
|
readonly EXIT: "Exit";
|
|
45
45
|
}>>;
|
|
46
|
-
capitalLookingToRaise: z.
|
|
46
|
+
capitalLookingToRaise: z.ZodNumber;
|
|
47
47
|
capitalLookingToRaiseCurrency: z.ZodOptional<z.ZodEnum<{
|
|
48
48
|
readonly USD: "USD (United States Dollar)";
|
|
49
49
|
readonly EUR: "EUR (Euro)";
|
|
@@ -106,7 +106,7 @@ export declare const ProjectWithFilesEntitySchema: z.ZodObject<{
|
|
|
106
106
|
readonly GROWTH: "Growth";
|
|
107
107
|
readonly EXIT: "Exit";
|
|
108
108
|
}>>;
|
|
109
|
-
capitalLookingToRaise: z.
|
|
109
|
+
capitalLookingToRaise: z.ZodNumber;
|
|
110
110
|
capitalLookingToRaiseCurrency: z.ZodOptional<z.ZodEnum<{
|
|
111
111
|
readonly USD: "USD (United States Dollar)";
|
|
112
112
|
readonly EUR: "EUR (Euro)";
|
|
@@ -219,7 +219,7 @@ export declare const UpdateProjectInputSchema: z.ZodObject<{
|
|
|
219
219
|
readonly GROWTH: "Growth";
|
|
220
220
|
readonly EXIT: "Exit";
|
|
221
221
|
}>>;
|
|
222
|
-
capitalLookingToRaise: z.ZodOptional<z.
|
|
222
|
+
capitalLookingToRaise: z.ZodOptional<z.ZodNumber>;
|
|
223
223
|
capitalLookingToRaiseCurrency: z.ZodOptional<z.ZodEnum<{
|
|
224
224
|
readonly USD: "USD (United States Dollar)";
|
|
225
225
|
readonly EUR: "EUR (Euro)";
|
|
@@ -239,13 +239,6 @@ export declare const UpdateProjectInputSchema: z.ZodObject<{
|
|
|
239
239
|
version: z.ZodNumber;
|
|
240
240
|
}, z.core.$strip>;
|
|
241
241
|
export type UpdateProjectInput = z.infer<typeof UpdateProjectInputSchema>;
|
|
242
|
-
export declare const SearchProjectsInputSchema: z.ZodObject<{
|
|
243
|
-
query: z.ZodOptional<z.ZodString>;
|
|
244
|
-
tags: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
245
|
-
limit: z.ZodDefault<z.ZodCoercedNumber<unknown>>;
|
|
246
|
-
cursor: z.ZodOptional<z.ZodString>;
|
|
247
|
-
}, z.core.$strip>;
|
|
248
|
-
export type SearchProjectsInput = z.infer<typeof SearchProjectsInputSchema>;
|
|
249
242
|
export declare const CommentOnProjectInputSchema: z.ZodObject<{
|
|
250
243
|
id: z.ZodCUID2;
|
|
251
244
|
userId: z.ZodCUID2;
|
|
@@ -315,7 +308,7 @@ export declare const ProjectDetailsEntitySchema: z.ZodObject<{
|
|
|
315
308
|
readonly GROWTH: "Growth";
|
|
316
309
|
readonly EXIT: "Exit";
|
|
317
310
|
}>>;
|
|
318
|
-
capitalLookingToRaise: z.
|
|
311
|
+
capitalLookingToRaise: z.ZodNumber;
|
|
319
312
|
capitalLookingToRaiseCurrency: z.ZodOptional<z.ZodEnum<{
|
|
320
313
|
readonly USD: "USD (United States Dollar)";
|
|
321
314
|
readonly EUR: "EUR (Euro)";
|
|
@@ -414,7 +407,7 @@ export declare const GetProjectOutputSchema: z.ZodObject<{
|
|
|
414
407
|
readonly GROWTH: "Growth";
|
|
415
408
|
readonly EXIT: "Exit";
|
|
416
409
|
}>>;
|
|
417
|
-
capitalLookingToRaise: z.
|
|
410
|
+
capitalLookingToRaise: z.ZodNumber;
|
|
418
411
|
capitalLookingToRaiseCurrency: z.ZodOptional<z.ZodEnum<{
|
|
419
412
|
readonly USD: "USD (United States Dollar)";
|
|
420
413
|
readonly EUR: "EUR (Euro)";
|
|
@@ -489,7 +482,7 @@ export declare const ProjectSearchDocumentSchema: z.ZodObject<{
|
|
|
489
482
|
createdAt: z.ZodNumber;
|
|
490
483
|
updatedAt: z.ZodNumber;
|
|
491
484
|
description: z.ZodOptional<z.ZodString>;
|
|
492
|
-
capitalLookingToRaise: z.ZodOptional<z.
|
|
485
|
+
capitalLookingToRaise: z.ZodOptional<z.ZodNumber>;
|
|
493
486
|
capitalLookingToRaiseCurrency: z.ZodOptional<z.ZodEnum<{
|
|
494
487
|
readonly USD: "USD (United States Dollar)";
|
|
495
488
|
readonly EUR: "EUR (Euro)";
|
|
@@ -553,6 +546,38 @@ export declare const ProjectSearchDocumentSchema: z.ZodObject<{
|
|
|
553
546
|
}, z.core.$strip>>>;
|
|
554
547
|
}, z.core.$strip>;
|
|
555
548
|
export type ProjectSearchDocument = z.infer<typeof ProjectSearchDocumentSchema>;
|
|
549
|
+
export declare const SearchProjectsInputSchema: z.ZodObject<{
|
|
550
|
+
query: z.ZodOptional<z.ZodString>;
|
|
551
|
+
limit: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
552
|
+
cursor: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
553
|
+
tags: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
554
|
+
isOpenToInvestment: z.ZodOptional<z.ZodBoolean>;
|
|
555
|
+
minCapital: z.ZodOptional<z.ZodNumber>;
|
|
556
|
+
maxCapital: z.ZodOptional<z.ZodNumber>;
|
|
557
|
+
ventureStages: z.ZodOptional<z.ZodArray<z.ZodEnum<{
|
|
558
|
+
readonly IDEA: "Idea";
|
|
559
|
+
readonly PRE_SEED: "Pre Seed";
|
|
560
|
+
readonly MVP: "MVP";
|
|
561
|
+
readonly SEED: "Seed";
|
|
562
|
+
readonly SERIES_A: "Series A";
|
|
563
|
+
readonly SERIES_B: "Series B";
|
|
564
|
+
readonly SERIES_C: "Series C";
|
|
565
|
+
readonly GROWTH: "Growth";
|
|
566
|
+
readonly EXIT: "Exit";
|
|
567
|
+
}>>>;
|
|
568
|
+
projectCreatorTypes: z.ZodOptional<z.ZodArray<z.ZodEnum<{
|
|
569
|
+
readonly CREATIVE: "CREATIVE";
|
|
570
|
+
readonly BRAND: "BRAND";
|
|
571
|
+
readonly INVESTOR: "INVESTOR";
|
|
572
|
+
readonly ADMIN: "ADMIN";
|
|
573
|
+
}>>>;
|
|
574
|
+
clientTypes: z.ZodOptional<z.ZodArray<z.ZodEnum<{
|
|
575
|
+
readonly CREATIVE: "CREATIVE";
|
|
576
|
+
readonly BRAND: "BRAND";
|
|
577
|
+
readonly NONE: "NONE";
|
|
578
|
+
}>>>;
|
|
579
|
+
}, z.core.$strip>;
|
|
580
|
+
export type SearchProjectsInput = z.infer<typeof SearchProjectsInputSchema>;
|
|
556
581
|
export declare const SearchProjectsOutputSchema: z.ZodObject<{
|
|
557
582
|
projects: z.ZodArray<z.ZodObject<{
|
|
558
583
|
id: z.ZodString;
|
|
@@ -569,7 +594,7 @@ export declare const SearchProjectsOutputSchema: z.ZodObject<{
|
|
|
569
594
|
createdAt: z.ZodNumber;
|
|
570
595
|
updatedAt: z.ZodNumber;
|
|
571
596
|
description: z.ZodOptional<z.ZodString>;
|
|
572
|
-
capitalLookingToRaise: z.ZodOptional<z.
|
|
597
|
+
capitalLookingToRaise: z.ZodOptional<z.ZodNumber>;
|
|
573
598
|
capitalLookingToRaiseCurrency: z.ZodOptional<z.ZodEnum<{
|
|
574
599
|
readonly USD: "USD (United States Dollar)";
|
|
575
600
|
readonly EUR: "EUR (Euro)";
|
|
@@ -865,7 +890,7 @@ export declare const CreateProjectOutputSchema: z.ZodObject<{
|
|
|
865
890
|
readonly GROWTH: "Growth";
|
|
866
891
|
readonly EXIT: "Exit";
|
|
867
892
|
}>>;
|
|
868
|
-
capitalLookingToRaise: z.
|
|
893
|
+
capitalLookingToRaise: z.ZodNumber;
|
|
869
894
|
capitalLookingToRaiseCurrency: z.ZodOptional<z.ZodEnum<{
|
|
870
895
|
readonly USD: "USD (United States Dollar)";
|
|
871
896
|
readonly EUR: "EUR (Euro)";
|
|
@@ -928,7 +953,7 @@ export declare const UpdateProjectOutputSchema: z.ZodObject<{
|
|
|
928
953
|
readonly GROWTH: "Growth";
|
|
929
954
|
readonly EXIT: "Exit";
|
|
930
955
|
}>>;
|
|
931
|
-
capitalLookingToRaise: z.
|
|
956
|
+
capitalLookingToRaise: z.ZodNumber;
|
|
932
957
|
capitalLookingToRaiseCurrency: z.ZodOptional<z.ZodEnum<{
|
|
933
958
|
readonly USD: "USD (United States Dollar)";
|
|
934
959
|
readonly EUR: "EUR (Euro)";
|
|
@@ -991,7 +1016,7 @@ export declare const DeleteProjectOutputSchema: z.ZodObject<{
|
|
|
991
1016
|
readonly GROWTH: "Growth";
|
|
992
1017
|
readonly EXIT: "Exit";
|
|
993
1018
|
}>>;
|
|
994
|
-
capitalLookingToRaise: z.
|
|
1019
|
+
capitalLookingToRaise: z.ZodNumber;
|
|
995
1020
|
capitalLookingToRaiseCurrency: z.ZodOptional<z.ZodEnum<{
|
|
996
1021
|
readonly USD: "USD (United States Dollar)";
|
|
997
1022
|
readonly EUR: "EUR (Euro)";
|
package/dist/schemas/project.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.ProjectIdSchema = exports.CommentOnProjectOutputSchema = exports.DeleteProjectOutputSchema = exports.UpdateProjectOutputSchema = exports.CreateProjectOutputSchema = exports.ProjectUpdateOutputEntitySchema = exports.ProjectWithProjectBookmarksEntitySchema = exports.ProjectWithProjectViewsEntitySchema = exports.GetProjectWithLikesOutputSchema = exports.ProjectWithLikesEntitySchema = exports.GetProjectWithCommentsOutputSchema = exports.ProjectWithProjectCommentsEntitySchema = exports.SearchProjectsOutputSchema = exports.
|
|
3
|
+
exports.ProjectIdSchema = exports.CommentOnProjectOutputSchema = exports.DeleteProjectOutputSchema = exports.UpdateProjectOutputSchema = exports.CreateProjectOutputSchema = exports.ProjectUpdateOutputEntitySchema = exports.ProjectWithProjectBookmarksEntitySchema = exports.ProjectWithProjectViewsEntitySchema = exports.GetProjectWithLikesOutputSchema = exports.ProjectWithLikesEntitySchema = exports.GetProjectWithCommentsOutputSchema = exports.ProjectWithProjectCommentsEntitySchema = exports.SearchProjectsOutputSchema = exports.SearchProjectsInputSchema = exports.ProjectSearchDocumentSchema = exports.GetProjectOutputSchema = exports.ProjectDetailsEntitySchema = exports.CommentOnProjectInputSchema = exports.UpdateProjectInputSchema = exports.CreateProjectInputSchema = exports.ProjectSocialGraphEntitySchema = exports.MinimalProjectSchema = exports.ProjectWithFilesEntitySchema = exports.ProjectEntitySchema = void 0;
|
|
4
4
|
const zod_openapi_1 = require("@hono/zod-openapi");
|
|
5
5
|
const constants_1 = require("../constants");
|
|
6
6
|
const comment_1 = require("./comment");
|
|
@@ -28,7 +28,7 @@ exports.ProjectEntitySchema = zod_openapi_1.z
|
|
|
28
28
|
problemBeingSolved: zod_openapi_1.z.string().max(600).optional(),
|
|
29
29
|
whoItsFor: zod_openapi_1.z.string().max(600).optional(),
|
|
30
30
|
ventureStage: zod_openapi_1.z.enum(constants_1.VENTURE_STAGES).optional(),
|
|
31
|
-
capitalLookingToRaise: zod_openapi_1.z.
|
|
31
|
+
capitalLookingToRaise: zod_openapi_1.z.number(),
|
|
32
32
|
capitalLookingToRaiseCurrency: zod_openapi_1.z.enum(constants_1.WAGES_CURRENCY).optional(),
|
|
33
33
|
currentTraction: zod_openapi_1.z.string().max(600),
|
|
34
34
|
isOpenToInvestment: zod_openapi_1.z.boolean().default(false),
|
|
@@ -86,7 +86,7 @@ exports.UpdateProjectInputSchema = zod_openapi_1.z
|
|
|
86
86
|
problemBeingSolved: zod_openapi_1.z.string().max(600).optional(),
|
|
87
87
|
whoItsFor: zod_openapi_1.z.string().max(600).optional(),
|
|
88
88
|
ventureStage: zod_openapi_1.z.enum(constants_1.VENTURE_STAGES).optional(),
|
|
89
|
-
capitalLookingToRaise: zod_openapi_1.z.
|
|
89
|
+
capitalLookingToRaise: zod_openapi_1.z.number().optional(),
|
|
90
90
|
capitalLookingToRaiseCurrency: zod_openapi_1.z.enum(constants_1.WAGES_CURRENCY).optional(),
|
|
91
91
|
currentTraction: zod_openapi_1.z.string().max(600).optional(),
|
|
92
92
|
isOpenToInvestment: zod_openapi_1.z.boolean().default(false),
|
|
@@ -113,14 +113,6 @@ exports.UpdateProjectInputSchema = zod_openapi_1.z
|
|
|
113
113
|
}
|
|
114
114
|
})
|
|
115
115
|
.openapi("UpdateProjectInput");
|
|
116
|
-
exports.SearchProjectsInputSchema = zod_openapi_1.z
|
|
117
|
-
.object({
|
|
118
|
-
query: zod_openapi_1.z.string().optional(),
|
|
119
|
-
tags: zod_openapi_1.z.array(zod_openapi_1.z.string()).optional(),
|
|
120
|
-
limit: zod_openapi_1.z.coerce.number().min(1).max(100).default(20),
|
|
121
|
-
cursor: zod_openapi_1.z.string().optional(),
|
|
122
|
-
})
|
|
123
|
-
.openapi("SearchProjectsInput");
|
|
124
116
|
exports.CommentOnProjectInputSchema = comment_1.CommentEntitySchema;
|
|
125
117
|
exports.ProjectDetailsEntitySchema = exports.ProjectEntitySchema.extend({
|
|
126
118
|
user: user_1.MinimalUserSchema,
|
|
@@ -141,7 +133,7 @@ exports.ProjectSearchDocumentSchema = zod_openapi_1.z
|
|
|
141
133
|
createdAt: zod_openapi_1.z.number(),
|
|
142
134
|
updatedAt: zod_openapi_1.z.number(),
|
|
143
135
|
description: zod_openapi_1.z.string().optional(),
|
|
144
|
-
capitalLookingToRaise: zod_openapi_1.z.
|
|
136
|
+
capitalLookingToRaise: zod_openapi_1.z.number().optional(),
|
|
145
137
|
capitalLookingToRaiseCurrency: zod_openapi_1.z.enum(constants_1.WAGES_CURRENCY).optional(),
|
|
146
138
|
ventureStage: zod_openapi_1.z.enum(constants_1.VENTURE_STAGES).optional(),
|
|
147
139
|
url: zod_openapi_1.z.url().optional(),
|
|
@@ -158,6 +150,20 @@ exports.ProjectSearchDocumentSchema = zod_openapi_1.z
|
|
|
158
150
|
files: zod_openapi_1.z.array(file_1.FileEntitySchema).optional(),
|
|
159
151
|
})
|
|
160
152
|
.openapi("ProjectSearchDocument");
|
|
153
|
+
exports.SearchProjectsInputSchema = zod_openapi_1.z
|
|
154
|
+
.object({
|
|
155
|
+
query: zod_openapi_1.z.string().optional(),
|
|
156
|
+
limit: zod_openapi_1.z.number().optional().default(40),
|
|
157
|
+
cursor: zod_openapi_1.z.string().optional().nullable(),
|
|
158
|
+
tags: zod_openapi_1.z.array(zod_openapi_1.z.string()).optional(),
|
|
159
|
+
isOpenToInvestment: zod_openapi_1.z.boolean().optional(),
|
|
160
|
+
minCapital: zod_openapi_1.z.number().optional(),
|
|
161
|
+
maxCapital: zod_openapi_1.z.number().optional(),
|
|
162
|
+
ventureStages: zod_openapi_1.z.array(zod_openapi_1.z.enum(constants_1.VENTURE_STAGES)).optional(),
|
|
163
|
+
projectCreatorTypes: zod_openapi_1.z.array(zod_openapi_1.z.enum(constants_1.ROLES)).optional(),
|
|
164
|
+
clientTypes: zod_openapi_1.z.array(zod_openapi_1.z.enum(constants_1.CLIENT_TYPES)).optional(),
|
|
165
|
+
})
|
|
166
|
+
.openapi("SearchProjectsInput");
|
|
161
167
|
exports.SearchProjectsOutputSchema = zod_openapi_1.z
|
|
162
168
|
.object({
|
|
163
169
|
projects: zod_openapi_1.z.array(exports.ProjectSearchDocumentSchema),
|
package/dist/schemas/user.d.ts
CHANGED
|
@@ -267,7 +267,7 @@ export declare const UserWithProjectsEntitySchema: z.ZodObject<{
|
|
|
267
267
|
readonly GROWTH: "Growth";
|
|
268
268
|
readonly EXIT: "Exit";
|
|
269
269
|
}>>;
|
|
270
|
-
capitalLookingToRaise: z.
|
|
270
|
+
capitalLookingToRaise: z.ZodNumber;
|
|
271
271
|
capitalLookingToRaiseCurrency: z.ZodOptional<z.ZodEnum<{
|
|
272
272
|
readonly USD: "USD (United States Dollar)";
|
|
273
273
|
readonly EUR: "EUR (Euro)";
|
|
@@ -559,7 +559,7 @@ export declare const UserWithProjectBookmarksEntitySchema: z.ZodObject<{
|
|
|
559
559
|
createdAt: z.ZodNumber;
|
|
560
560
|
updatedAt: z.ZodNumber;
|
|
561
561
|
description: z.ZodOptional<z.ZodString>;
|
|
562
|
-
capitalLookingToRaise: z.ZodOptional<z.
|
|
562
|
+
capitalLookingToRaise: z.ZodOptional<z.ZodNumber>;
|
|
563
563
|
capitalLookingToRaiseCurrency: z.ZodOptional<z.ZodEnum<{
|
|
564
564
|
readonly USD: "USD (United States Dollar)";
|
|
565
565
|
readonly EUR: "EUR (Euro)";
|
|
@@ -848,7 +848,7 @@ export declare const GetUserWithProjectBookmarksOutputSchema: z.ZodObject<{
|
|
|
848
848
|
createdAt: z.ZodNumber;
|
|
849
849
|
updatedAt: z.ZodNumber;
|
|
850
850
|
description: z.ZodOptional<z.ZodString>;
|
|
851
|
-
capitalLookingToRaise: z.ZodOptional<z.
|
|
851
|
+
capitalLookingToRaise: z.ZodOptional<z.ZodNumber>;
|
|
852
852
|
capitalLookingToRaiseCurrency: z.ZodOptional<z.ZodEnum<{
|
|
853
853
|
readonly USD: "USD (United States Dollar)";
|
|
854
854
|
readonly EUR: "EUR (Euro)";
|
|
@@ -1475,7 +1475,7 @@ export declare const GetAuthenticatedUserWithProjectsOutputSchema: z.ZodObject<{
|
|
|
1475
1475
|
readonly GROWTH: "Growth";
|
|
1476
1476
|
readonly EXIT: "Exit";
|
|
1477
1477
|
}>>;
|
|
1478
|
-
capitalLookingToRaise: z.
|
|
1478
|
+
capitalLookingToRaise: z.ZodNumber;
|
|
1479
1479
|
capitalLookingToRaiseCurrency: z.ZodOptional<z.ZodEnum<{
|
|
1480
1480
|
readonly USD: "USD (United States Dollar)";
|
|
1481
1481
|
readonly EUR: "EUR (Euro)";
|
|
@@ -1528,7 +1528,7 @@ export declare const GetAuthenticatedUserWithProjectBookmarksOutputSchema: z.Zod
|
|
|
1528
1528
|
createdAt: z.ZodNumber;
|
|
1529
1529
|
updatedAt: z.ZodNumber;
|
|
1530
1530
|
description: z.ZodOptional<z.ZodString>;
|
|
1531
|
-
capitalLookingToRaise: z.ZodOptional<z.
|
|
1531
|
+
capitalLookingToRaise: z.ZodOptional<z.ZodNumber>;
|
|
1532
1532
|
capitalLookingToRaiseCurrency: z.ZodOptional<z.ZodEnum<{
|
|
1533
1533
|
readonly USD: "USD (United States Dollar)";
|
|
1534
1534
|
readonly EUR: "EUR (Euro)";
|
package/package.json
CHANGED
package/src/schemas/project.ts
CHANGED
|
@@ -33,7 +33,7 @@ export const ProjectEntitySchema = z
|
|
|
33
33
|
problemBeingSolved: z.string().max(600).optional(),
|
|
34
34
|
whoItsFor: z.string().max(600).optional(),
|
|
35
35
|
ventureStage: z.enum(VENTURE_STAGES).optional(),
|
|
36
|
-
capitalLookingToRaise: z.
|
|
36
|
+
capitalLookingToRaise: z.number(),
|
|
37
37
|
capitalLookingToRaiseCurrency: z.enum(WAGES_CURRENCY).optional(),
|
|
38
38
|
currentTraction: z.string().max(600),
|
|
39
39
|
isOpenToInvestment: z.boolean().default(false),
|
|
@@ -106,7 +106,7 @@ export const UpdateProjectInputSchema = z
|
|
|
106
106
|
problemBeingSolved: z.string().max(600).optional(),
|
|
107
107
|
whoItsFor: z.string().max(600).optional(),
|
|
108
108
|
ventureStage: z.enum(VENTURE_STAGES).optional(),
|
|
109
|
-
capitalLookingToRaise: z.
|
|
109
|
+
capitalLookingToRaise: z.number().optional(),
|
|
110
110
|
capitalLookingToRaiseCurrency: z.enum(WAGES_CURRENCY).optional(),
|
|
111
111
|
currentTraction: z.string().max(600).optional(),
|
|
112
112
|
isOpenToInvestment: z.boolean().default(false),
|
|
@@ -136,17 +136,6 @@ export const UpdateProjectInputSchema = z
|
|
|
136
136
|
|
|
137
137
|
export type UpdateProjectInput = z.infer<typeof UpdateProjectInputSchema>;
|
|
138
138
|
|
|
139
|
-
export const SearchProjectsInputSchema = z
|
|
140
|
-
.object({
|
|
141
|
-
query: z.string().optional(),
|
|
142
|
-
tags: z.array(z.string()).optional(),
|
|
143
|
-
limit: z.coerce.number().min(1).max(100).default(20),
|
|
144
|
-
cursor: z.string().optional(),
|
|
145
|
-
})
|
|
146
|
-
.openapi("SearchProjectsInput");
|
|
147
|
-
|
|
148
|
-
export type SearchProjectsInput = z.infer<typeof SearchProjectsInputSchema>;
|
|
149
|
-
|
|
150
139
|
export const CommentOnProjectInputSchema = CommentEntitySchema;
|
|
151
140
|
|
|
152
141
|
export type CommentOnProjectInput = z.infer<typeof CommentOnProjectInputSchema>;
|
|
@@ -176,7 +165,7 @@ export const ProjectSearchDocumentSchema = z
|
|
|
176
165
|
createdAt: z.number(),
|
|
177
166
|
updatedAt: z.number(),
|
|
178
167
|
description: z.string().optional(),
|
|
179
|
-
capitalLookingToRaise: z.
|
|
168
|
+
capitalLookingToRaise: z.number().optional(),
|
|
180
169
|
capitalLookingToRaiseCurrency: z.enum(WAGES_CURRENCY).optional(),
|
|
181
170
|
ventureStage: z.enum(VENTURE_STAGES).optional(),
|
|
182
171
|
url: z.url().optional(),
|
|
@@ -196,6 +185,23 @@ export const ProjectSearchDocumentSchema = z
|
|
|
196
185
|
|
|
197
186
|
export type ProjectSearchDocument = z.infer<typeof ProjectSearchDocumentSchema>;
|
|
198
187
|
|
|
188
|
+
export const SearchProjectsInputSchema = z
|
|
189
|
+
.object({
|
|
190
|
+
query: z.string().optional(),
|
|
191
|
+
limit: z.number().optional().default(40),
|
|
192
|
+
cursor: z.string().optional().nullable(),
|
|
193
|
+
tags: z.array(z.string()).optional(),
|
|
194
|
+
isOpenToInvestment: z.boolean().optional(),
|
|
195
|
+
minCapital: z.number().optional(),
|
|
196
|
+
maxCapital: z.number().optional(),
|
|
197
|
+
ventureStages: z.array(z.enum(VENTURE_STAGES)).optional(),
|
|
198
|
+
projectCreatorTypes: z.array(z.enum(ROLES)).optional(),
|
|
199
|
+
clientTypes: z.array(z.enum(CLIENT_TYPES)).optional(),
|
|
200
|
+
})
|
|
201
|
+
.openapi("SearchProjectsInput");
|
|
202
|
+
|
|
203
|
+
export type SearchProjectsInput = z.infer<typeof SearchProjectsInputSchema>;
|
|
204
|
+
|
|
199
205
|
export const SearchProjectsOutputSchema = z
|
|
200
206
|
.object({
|
|
201
207
|
projects: z.array(ProjectSearchDocumentSchema),
|