@zyacreatives/shared 2.2.6 → 2.2.8

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.
@@ -177,6 +177,11 @@ export declare const JOB_STATUS: {
177
177
  readonly ARCHIVED: "ARCHIVED";
178
178
  readonly DELETED: "DELETED";
179
179
  };
180
+ export declare const PROJECT_STATUS: {
181
+ readonly ACTIVE: "ACTIVE";
182
+ readonly DRAFT: "DRAFT";
183
+ readonly ARCHIVED: "ARCHIVED";
184
+ };
180
185
  export declare const POST_BADGE_TYPES: {
181
186
  readonly NETWORKING: "Networking";
182
187
  readonly FUNDING: "Funding";
@@ -261,6 +266,7 @@ export type GeographicFocus = (typeof GEOGRAPHIC_FOCUS)[keyof typeof GEOGRAPHIC_
261
266
  export type InvestorVerificationDocumentStatus = (typeof INVESTOR_VERIFICATION_DOCUMENT_STATUSES)[keyof typeof INVESTOR_VERIFICATION_DOCUMENT_STATUSES];
262
267
  export type InvestorVerificationDocumentType = (typeof INVESTOR_VERIFICATION_DOCUMENT_TYPES)[keyof typeof INVESTOR_VERIFICATION_DOCUMENT_TYPES];
263
268
  export type VentureStage = (typeof VENTURE_STAGES)[keyof typeof VENTURE_STAGES];
269
+ export type ProjectStatus = (typeof PROJECT_STATUS)[keyof typeof PROJECT_STATUS];
264
270
  export declare const API_ROUTES: {
265
271
  readonly healthCheck: "/health";
266
272
  readonly username: {
package/dist/constants.js CHANGED
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ANALYTICS_EVENTS = exports.DEFAULT_DISCIPLINES = exports.API_ROUTES = exports.VENTURE_STAGES = 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;
3
+ exports.ANALYTICS_EVENTS = exports.DEFAULT_DISCIPLINES = exports.API_ROUTES = exports.VENTURE_STAGES = exports.NOTIFICATION_TYPES = exports.APPLICATION_STATUS = exports.LINK_TYPES = exports.ACTIVITY_TYPES = exports.POST_BADGE_TYPES = exports.PROJECT_STATUS = 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",
@@ -179,6 +179,11 @@ exports.JOB_STATUS = {
179
179
  ARCHIVED: "ARCHIVED",
180
180
  DELETED: "DELETED",
181
181
  };
182
+ exports.PROJECT_STATUS = {
183
+ ACTIVE: "ACTIVE",
184
+ DRAFT: "DRAFT",
185
+ ARCHIVED: "ARCHIVED",
186
+ };
182
187
  exports.POST_BADGE_TYPES = {
183
188
  NETWORKING: "Networking",
184
189
  FUNDING: "Funding",
@@ -15,6 +15,11 @@ export declare const ProjectEntitySchema: z.ZodObject<{
15
15
  readonly ADMIN: "ADMIN";
16
16
  }>;
17
17
  clientId: z.ZodOptional<z.ZodString>;
18
+ status: z.ZodEnum<{
19
+ readonly ACTIVE: "ACTIVE";
20
+ readonly DRAFT: "DRAFT";
21
+ readonly ARCHIVED: "ARCHIVED";
22
+ }>;
18
23
  clientType: z.ZodOptional<z.ZodEnum<{
19
24
  readonly CREATIVE: "CREATIVE";
20
25
  readonly BRAND: "BRAND";
@@ -84,6 +89,11 @@ export declare const ProjectDetailsEntitySchema: z.ZodObject<{
84
89
  readonly ADMIN: "ADMIN";
85
90
  }>;
86
91
  clientId: z.ZodOptional<z.ZodString>;
92
+ status: z.ZodEnum<{
93
+ readonly ACTIVE: "ACTIVE";
94
+ readonly DRAFT: "DRAFT";
95
+ readonly ARCHIVED: "ARCHIVED";
96
+ }>;
87
97
  clientType: z.ZodOptional<z.ZodEnum<{
88
98
  readonly CREATIVE: "CREATIVE";
89
99
  readonly BRAND: "BRAND";
@@ -164,6 +174,11 @@ export declare const CreateProjectInputSchema: z.ZodObject<{
164
174
  imagePlaceholderUrl: z.ZodURL;
165
175
  tags: z.ZodDefault<z.ZodArray<z.ZodString>>;
166
176
  startDate: z.ZodOptional<z.ZodCoercedDate<unknown>>;
177
+ status: z.ZodDefault<z.ZodEnum<{
178
+ readonly ACTIVE: "ACTIVE";
179
+ readonly DRAFT: "DRAFT";
180
+ readonly ARCHIVED: "ARCHIVED";
181
+ }>>;
167
182
  endDate: z.ZodOptional<z.ZodCoercedDate<unknown>>;
168
183
  projectCreatorType: z.ZodDefault<z.ZodEnum<{
169
184
  readonly CREATIVE: "CREATIVE";
@@ -207,6 +222,11 @@ export declare const UpdateProjectInputSchema: z.ZodObject<{
207
222
  }>>;
208
223
  clientName: z.ZodOptional<z.ZodString>;
209
224
  isFeatured: z.ZodOptional<z.ZodBoolean>;
225
+ status: z.ZodOptional<z.ZodEnum<{
226
+ readonly ACTIVE: "ACTIVE";
227
+ readonly DRAFT: "DRAFT";
228
+ readonly ARCHIVED: "ARCHIVED";
229
+ }>>;
210
230
  problemBeingSolved: z.ZodOptional<z.ZodString>;
211
231
  whoItsFor: z.ZodOptional<z.ZodString>;
212
232
  ventureStage: z.ZodOptional<z.ZodEnum<{
@@ -256,6 +276,11 @@ export declare const CreateProjectOutputSchema: z.ZodObject<{
256
276
  readonly ADMIN: "ADMIN";
257
277
  }>;
258
278
  clientId: z.ZodOptional<z.ZodString>;
279
+ status: z.ZodEnum<{
280
+ readonly ACTIVE: "ACTIVE";
281
+ readonly DRAFT: "DRAFT";
282
+ readonly ARCHIVED: "ARCHIVED";
283
+ }>;
259
284
  clientType: z.ZodOptional<z.ZodEnum<{
260
285
  readonly CREATIVE: "CREATIVE";
261
286
  readonly BRAND: "BRAND";
@@ -312,6 +337,11 @@ export declare const UpdateProjectOutputSchema: z.ZodObject<{
312
337
  readonly ADMIN: "ADMIN";
313
338
  }>;
314
339
  clientId: z.ZodOptional<z.ZodString>;
340
+ status: z.ZodEnum<{
341
+ readonly ACTIVE: "ACTIVE";
342
+ readonly DRAFT: "DRAFT";
343
+ readonly ARCHIVED: "ARCHIVED";
344
+ }>;
315
345
  clientType: z.ZodOptional<z.ZodEnum<{
316
346
  readonly CREATIVE: "CREATIVE";
317
347
  readonly BRAND: "BRAND";
@@ -368,6 +398,11 @@ export declare const DeleteProjectOutputSchema: z.ZodObject<{
368
398
  readonly ADMIN: "ADMIN";
369
399
  }>;
370
400
  clientId: z.ZodOptional<z.ZodString>;
401
+ status: z.ZodEnum<{
402
+ readonly ACTIVE: "ACTIVE";
403
+ readonly DRAFT: "DRAFT";
404
+ readonly ARCHIVED: "ARCHIVED";
405
+ }>;
371
406
  clientType: z.ZodOptional<z.ZodEnum<{
372
407
  readonly CREATIVE: "CREATIVE";
373
408
  readonly BRAND: "BRAND";
@@ -424,6 +459,11 @@ export declare const GetProjectOutputSchema: z.ZodObject<{
424
459
  readonly ADMIN: "ADMIN";
425
460
  }>;
426
461
  clientId: z.ZodOptional<z.ZodString>;
462
+ status: z.ZodEnum<{
463
+ readonly ACTIVE: "ACTIVE";
464
+ readonly DRAFT: "DRAFT";
465
+ readonly ARCHIVED: "ARCHIVED";
466
+ }>;
427
467
  clientType: z.ZodOptional<z.ZodEnum<{
428
468
  readonly CREATIVE: "CREATIVE";
429
469
  readonly BRAND: "BRAND";
@@ -54,6 +54,7 @@ exports.ProjectEntitySchema = zod_openapi_1.z
54
54
  description: "CUID2 of the client if this is a client project.",
55
55
  example: "ckl1y9xyz0000qv7a0h1efgh4",
56
56
  }),
57
+ status: zod_openapi_1.z.enum(constants_1.PROJECT_STATUS),
57
58
  clientType: zod_openapi_1.z.enum(constants_1.CLIENT_TYPES).optional().openapi({
58
59
  description: "Type of client for this project.",
59
60
  example: "BRAND",
@@ -151,6 +152,7 @@ exports.CreateProjectInputSchema = zod_openapi_1.z
151
152
  imagePlaceholderUrl: zod_openapi_1.z.url(),
152
153
  tags: zod_openapi_1.z.array(zod_openapi_1.z.string()).default([]),
153
154
  startDate: zod_openapi_1.z.coerce.date().optional(),
155
+ status: zod_openapi_1.z.enum(constants_1.PROJECT_STATUS).default(constants_1.PROJECT_STATUS.ACTIVE),
154
156
  endDate: zod_openapi_1.z.coerce.date().optional(),
155
157
  projectCreatorType: zod_openapi_1.z.enum(constants_1.ROLES).default(constants_1.ROLES.CREATIVE),
156
158
  clientId: zod_openapi_1.z.string().optional(),
@@ -196,6 +198,7 @@ exports.UpdateProjectInputSchema = zod_openapi_1.z
196
198
  clientType: zod_openapi_1.z.enum(constants_1.CLIENT_TYPES).optional(),
197
199
  clientName: zod_openapi_1.z.string().optional(),
198
200
  isFeatured: zod_openapi_1.z.boolean().optional(),
201
+ status: zod_openapi_1.z.enum(constants_1.PROJECT_STATUS).optional(),
199
202
  problemBeingSolved: zod_openapi_1.z.string().max(600).optional(),
200
203
  whoItsFor: zod_openapi_1.z.string().max(600).optional(),
201
204
  ventureStage: zod_openapi_1.z.enum(constants_1.VENTURE_STAGES).optional(),
@@ -226,6 +226,11 @@ export declare const UserWithProjectsEntitySchema: z.ZodObject<{
226
226
  readonly ADMIN: "ADMIN";
227
227
  }>;
228
228
  clientId: z.ZodOptional<z.ZodString>;
229
+ status: z.ZodEnum<{
230
+ readonly ACTIVE: "ACTIVE";
231
+ readonly DRAFT: "DRAFT";
232
+ readonly ARCHIVED: "ARCHIVED";
233
+ }>;
229
234
  clientType: z.ZodOptional<z.ZodEnum<{
230
235
  readonly CREATIVE: "CREATIVE";
231
236
  readonly BRAND: "BRAND";
@@ -737,6 +742,11 @@ export declare const GetAuthenticatedUserWithProjectsOutputSchema: z.ZodObject<{
737
742
  readonly ADMIN: "ADMIN";
738
743
  }>;
739
744
  clientId: z.ZodOptional<z.ZodString>;
745
+ status: z.ZodEnum<{
746
+ readonly ACTIVE: "ACTIVE";
747
+ readonly DRAFT: "DRAFT";
748
+ readonly ARCHIVED: "ARCHIVED";
749
+ }>;
740
750
  clientType: z.ZodOptional<z.ZodEnum<{
741
751
  readonly CREATIVE: "CREATIVE";
742
752
  readonly BRAND: "BRAND";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zyacreatives/shared",
3
- "version": "2.2.6",
3
+ "version": "2.2.8",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
package/src/constants.ts CHANGED
@@ -200,6 +200,12 @@ export const JOB_STATUS = {
200
200
  DELETED: "DELETED",
201
201
  } as const;
202
202
 
203
+ export const PROJECT_STATUS = {
204
+ ACTIVE: "ACTIVE",
205
+ DRAFT: "DRAFT",
206
+ ARCHIVED: "ARCHIVED",
207
+ } as const;
208
+
203
209
  export const POST_BADGE_TYPES = {
204
210
  NETWORKING: "Networking",
205
211
  FUNDING: "Funding",
@@ -304,7 +310,9 @@ export type InvestorVerificationDocumentStatus =
304
310
  export type InvestorVerificationDocumentType =
305
311
  (typeof INVESTOR_VERIFICATION_DOCUMENT_TYPES)[keyof typeof INVESTOR_VERIFICATION_DOCUMENT_TYPES];
306
312
  export type VentureStage = (typeof VENTURE_STAGES)[keyof typeof VENTURE_STAGES];
307
-
313
+ export type ProjectStatus =
314
+ (typeof PROJECT_STATUS)[keyof typeof PROJECT_STATUS];
315
+
308
316
  export const API_ROUTES = {
309
317
  healthCheck: "/health",
310
318
  username: {
@@ -1,6 +1,7 @@
1
1
  import { z } from "@hono/zod-openapi";
2
2
  import {
3
3
  CLIENT_TYPES,
4
+ PROJECT_STATUS,
4
5
  ROLES,
5
6
  VENTURE_STAGES,
6
7
  WAGES_CURRENCY,
@@ -58,6 +59,7 @@ export const ProjectEntitySchema = z
58
59
  description: "CUID2 of the client if this is a client project.",
59
60
  example: "ckl1y9xyz0000qv7a0h1efgh4",
60
61
  }),
62
+ status: z.enum(PROJECT_STATUS),
61
63
  clientType: z.enum(CLIENT_TYPES).optional().openapi({
62
64
  description: "Type of client for this project.",
63
65
  example: "BRAND",
@@ -162,6 +164,7 @@ export const CreateProjectInputSchema = z
162
164
  imagePlaceholderUrl: z.url(),
163
165
  tags: z.array(z.string()).default([]),
164
166
  startDate: z.coerce.date().optional(),
167
+ status: z.enum(PROJECT_STATUS).default(PROJECT_STATUS.ACTIVE),
165
168
  endDate: z.coerce.date().optional(),
166
169
  projectCreatorType: z.enum(ROLES).default(ROLES.CREATIVE),
167
170
  clientId: z.string().optional(),
@@ -209,6 +212,7 @@ export const UpdateProjectInputSchema = z
209
212
  clientType: z.enum(CLIENT_TYPES).optional(),
210
213
  clientName: z.string().optional(),
211
214
  isFeatured: z.boolean().optional(),
215
+ status: z.enum(PROJECT_STATUS).optional(),
212
216
  problemBeingSolved: z.string().max(600).optional(),
213
217
  whoItsFor: z.string().max(600).optional(),
214
218
  ventureStage: z.enum(VENTURE_STAGES).optional(),