@zyacreatives/shared 2.1.22 → 2.1.24

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.
@@ -404,14 +404,63 @@ export declare const TrackedJobApplicationEntitySchema: z.ZodObject<{
404
404
  }>>;
405
405
  }, z.core.$strip>]>;
406
406
  }, z.core.$strip>;
407
- export declare const UpdateJobApplicationStatusSchema: z.ZodObject<{
408
- applicationStatus: z.ZodEnum<{
407
+ export declare const UpdateJobApplicationInputSchema: z.ZodObject<{
408
+ jobId: z.ZodOptional<z.ZodCUID2>;
409
+ applicantId: z.ZodOptional<z.ZodCUID2>;
410
+ jobSections: z.ZodOptional<z.ZodOptional<z.ZodArray<z.ZodEnum<{
411
+ readonly PERSONAL_INFORMATION: "PERSONAL_INFORMATION";
412
+ readonly PHONE_NO: "PHONE_NO";
413
+ readonly PROFESSIONAL_INFORMATION: "PROFESSIONAL_INFORMATION";
414
+ readonly RESUME: "RESUME";
415
+ readonly COVER_LETTER: "COVER_LETTER";
416
+ readonly PORTFOLIO_OR_WORK_SAMPLES: "PORTFOLIO_OR_WORK_SAMPLES";
417
+ readonly AVAILABILITY: "AVAILABILITY";
418
+ readonly WAGES: "WAGES";
419
+ }>>>>;
420
+ firstName: z.ZodOptional<z.ZodOptional<z.ZodString>>;
421
+ lastName: z.ZodOptional<z.ZodOptional<z.ZodString>>;
422
+ emailAddress: z.ZodOptional<z.ZodOptional<z.ZodEmail>>;
423
+ phoneNumber: z.ZodOptional<z.ZodOptional<z.ZodString>>;
424
+ currentRole: z.ZodOptional<z.ZodOptional<z.ZodString>>;
425
+ experienceLevel: z.ZodOptional<z.ZodOptional<z.ZodEnum<{
426
+ "0-1 year": "0-1 year";
427
+ "1-3 years": "1-3 years";
428
+ "3-5 years": "3-5 years";
429
+ "5+ years": "5+ years";
430
+ }>>>;
431
+ resumeUrl: z.ZodOptional<z.ZodOptional<z.ZodURL>>;
432
+ coverLetter: z.ZodOptional<z.ZodOptional<z.ZodString>>;
433
+ availability: z.ZodOptional<z.ZodOptional<z.ZodEnum<{
434
+ readonly IMMEDIATE: "Immediate (Within 1 week)";
435
+ readonly TWO_WEEKS_NOTICE: "2 weeks notice";
436
+ readonly ONE_MONTH_NOTICE: "1 month notice";
437
+ readonly FLEXIBLE: "Flexible";
438
+ }>>>;
439
+ wagesAmount: z.ZodOptional<z.ZodOptional<z.ZodCoercedNumber<unknown>>>;
440
+ receiveEmailUpdates: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
441
+ workSampleUrls: z.ZodOptional<z.ZodOptional<z.ZodArray<z.ZodObject<{
442
+ url: z.ZodURL;
443
+ name: z.ZodOptional<z.ZodString>;
444
+ mimeType: z.ZodOptional<z.ZodString>;
445
+ }, z.core.$strip>>>>;
446
+ linkUrls: z.ZodOptional<z.ZodOptional<z.ZodArray<z.ZodObject<{
447
+ url: z.ZodURL;
448
+ isPortfolioUrl: z.ZodBoolean;
449
+ }, z.core.$strip>>>>;
450
+ zyaProjects: z.ZodOptional<z.ZodOptional<z.ZodArray<z.ZodObject<{
451
+ projectName: z.ZodString;
452
+ projectId: z.ZodCUID2;
453
+ projectImgUrl: z.ZodURL;
454
+ tags: z.ZodOptional<z.ZodArray<z.ZodString>>;
455
+ }, z.core.$strip>>>>;
456
+ id: z.ZodCUID2;
457
+ applicationStatus: z.ZodOptional<z.ZodEnum<{
409
458
  readonly SENT: "Application Sent";
410
459
  readonly OPENED: "Opened";
411
460
  readonly REJECTED: "Rejected";
412
461
  readonly OFFERED: "Offered";
413
462
  readonly HIRED: "Hired";
414
- }>;
463
+ }>>;
415
464
  }, z.core.$strip>;
416
465
  export declare const GetTrackedJobApplicationsInputSchema: z.ZodObject<{
417
466
  query: z.ZodOptional<z.ZodString>;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.GetTrackedJobApplicationsOutputSchema = exports.GetTrackedJobApplicationsInputSchema = exports.UpdateJobApplicationStatusSchema = exports.TrackedJobApplicationEntitySchema = exports.CreateJobApplicationInputSchema = exports.JobApplicationEntitySchema = exports.BaseJobApplicationEntitySchema = exports.MinimalJobApplicationEntitySchema = void 0;
3
+ exports.GetTrackedJobApplicationsOutputSchema = exports.GetTrackedJobApplicationsInputSchema = exports.UpdateJobApplicationInputSchema = exports.TrackedJobApplicationEntitySchema = exports.CreateJobApplicationInputSchema = exports.JobApplicationEntitySchema = exports.BaseJobApplicationEntitySchema = exports.MinimalJobApplicationEntitySchema = void 0;
4
4
  const zod_openapi_1 = require("@hono/zod-openapi");
5
5
  const constants_1 = require("../constants");
6
6
  const user_1 = require("./user");
@@ -141,8 +141,9 @@ exports.TrackedJobApplicationEntitySchema = zod_openapi_1.z.object({
141
141
  applicationStatus: zod_openapi_1.z.enum(Object.values(constants_1.APPLICATION_STATUS)),
142
142
  job: job_1.NormalizedJobSchema,
143
143
  });
144
- exports.UpdateJobApplicationStatusSchema = zod_openapi_1.z.object({
145
- applicationStatus: zod_openapi_1.z.enum(constants_1.APPLICATION_STATUS),
144
+ exports.UpdateJobApplicationInputSchema = exports.CreateJobApplicationInputSchema.partial().extend({
145
+ id: zod_openapi_1.z.cuid2(),
146
+ applicationStatus: zod_openapi_1.z.enum(constants_1.APPLICATION_STATUS).optional(),
146
147
  });
147
148
  exports.GetTrackedJobApplicationsInputSchema = zod_openapi_1.z.object({
148
149
  query: zod_openapi_1.z.string().optional(),
@@ -1,7 +1,7 @@
1
1
  import z from "zod";
2
- import { JobApplicationEntitySchema, CreateJobApplicationInputSchema, UpdateJobApplicationStatusSchema, MinimalJobApplicationEntitySchema, BaseJobApplicationEntitySchema, TrackedJobApplicationEntitySchema, GetTrackedJobApplicationsInputSchema, GetTrackedJobApplicationsOutputSchema } from "../schemas/job-application";
2
+ import { JobApplicationEntitySchema, CreateJobApplicationInputSchema, UpdateJobApplicationInputSchema, MinimalJobApplicationEntitySchema, BaseJobApplicationEntitySchema, TrackedJobApplicationEntitySchema, GetTrackedJobApplicationsInputSchema, GetTrackedJobApplicationsOutputSchema } from "../schemas/job-application";
3
3
  export type CreateJobApplicationInput = z.infer<typeof CreateJobApplicationInputSchema>;
4
- export type UpdateJobApplicationStatusInput = z.infer<typeof UpdateJobApplicationStatusSchema>;
4
+ export type UpdateJobApplicationInput = z.infer<typeof UpdateJobApplicationInputSchema>;
5
5
  export type JobApplicationEntity = z.infer<typeof JobApplicationEntitySchema>;
6
6
  export type MinimalJobApplicationEntity = z.infer<typeof MinimalJobApplicationEntitySchema>;
7
7
  export type BaseJobApplicationEntity = z.infer<typeof BaseJobApplicationEntitySchema>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zyacreatives/shared",
3
- "version": "2.1.22",
3
+ "version": "2.1.24",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -211,9 +211,11 @@ export const TrackedJobApplicationEntitySchema = z.object({
211
211
  job: NormalizedJobSchema,
212
212
  });
213
213
 
214
- export const UpdateJobApplicationStatusSchema = z.object({
215
- applicationStatus: z.enum(APPLICATION_STATUS),
216
- });
214
+ export const UpdateJobApplicationInputSchema =
215
+ CreateJobApplicationInputSchema.partial().extend({
216
+ id: z.cuid2(),
217
+ applicationStatus: z.enum(APPLICATION_STATUS).optional(),
218
+ });
217
219
 
218
220
  export const GetTrackedJobApplicationsInputSchema = z.object({
219
221
  query: z.string().optional(),
@@ -2,7 +2,7 @@ import z from "zod";
2
2
  import {
3
3
  JobApplicationEntitySchema,
4
4
  CreateJobApplicationInputSchema,
5
- UpdateJobApplicationStatusSchema,
5
+ UpdateJobApplicationInputSchema,
6
6
  MinimalJobApplicationEntitySchema,
7
7
  BaseJobApplicationEntitySchema,
8
8
  TrackedJobApplicationEntitySchema,
@@ -14,8 +14,8 @@ export type CreateJobApplicationInput = z.infer<
14
14
  typeof CreateJobApplicationInputSchema
15
15
  >;
16
16
 
17
- export type UpdateJobApplicationStatusInput = z.infer<
18
- typeof UpdateJobApplicationStatusSchema
17
+ export type UpdateJobApplicationInput = z.infer<
18
+ typeof UpdateJobApplicationInputSchema
19
19
  >;
20
20
 
21
21
  export type JobApplicationEntity = z.infer<typeof JobApplicationEntitySchema>;
package/src/types/job.ts CHANGED
@@ -14,7 +14,6 @@ import {
14
14
  BaseJobEntitySchema,
15
15
  JobIdSchema,
16
16
  GetJobsOutputSchema,
17
- NormalizedJobSchema,
18
17
  GetJobsInputSchema,
19
18
  GetCreatedJobsOutputSchema,
20
19
  } from "../schemas/job";