@zyacreatives/shared 2.0.1 → 2.0.11
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 +2 -2
- package/dist/constants.js +2 -2
- package/dist/schemas/job.d.ts +36 -0
- package/dist/schemas/job.js +2 -0
- package/package.json +1 -1
- package/src/constants.ts +4 -3
- package/src/schemas/job.ts +4 -0
package/dist/constants.d.ts
CHANGED
|
@@ -162,7 +162,7 @@ export declare const WAGES_CURRENCY: {
|
|
|
162
162
|
readonly INR: "INR";
|
|
163
163
|
readonly ZAR: "ZAR";
|
|
164
164
|
};
|
|
165
|
-
export declare const
|
|
165
|
+
export declare const JOB_STATUS: {
|
|
166
166
|
readonly ACTIVE: "ACTIVE";
|
|
167
167
|
readonly DRAFT: "DRAFT";
|
|
168
168
|
readonly ARCHIVED: "ARCHIVED";
|
|
@@ -170,7 +170,7 @@ export declare const JOBPOST_STATUS: {
|
|
|
170
170
|
};
|
|
171
171
|
export type JobSections = (typeof JOB_SECTIONS)[keyof typeof JOB_SECTIONS];
|
|
172
172
|
export type WagesCurrency = (typeof WAGES_CURRENCY)[keyof typeof WAGES_CURRENCY];
|
|
173
|
-
export type
|
|
173
|
+
export type JobStatus = (typeof JOB_STATUS)[keyof typeof JOB_STATUS];
|
|
174
174
|
export type Role = (typeof ROLES)[keyof typeof ROLES];
|
|
175
175
|
export type JobType = (typeof JOB_TYPE)[keyof typeof JOB_TYPE];
|
|
176
176
|
export type WorkMode = (typeof WORK_MODE)[keyof typeof WORK_MODE];
|
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.
|
|
3
|
+
exports.DEFAULT_DISCIPLINES = exports.API_ROUTES = exports.JOB_STATUS = exports.WAGES_CURRENCY = exports.GIG_TYPE = 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",
|
|
@@ -164,7 +164,7 @@ exports.WAGES_CURRENCY = {
|
|
|
164
164
|
INR: "INR",
|
|
165
165
|
ZAR: "ZAR",
|
|
166
166
|
};
|
|
167
|
-
exports.
|
|
167
|
+
exports.JOB_STATUS = {
|
|
168
168
|
ACTIVE: "ACTIVE",
|
|
169
169
|
DRAFT: "DRAFT",
|
|
170
170
|
ARCHIVED: "ARCHIVED",
|
package/dist/schemas/job.d.ts
CHANGED
|
@@ -18,6 +18,12 @@ export declare const BaseJobEntitySchema: z.ZodObject<{
|
|
|
18
18
|
Hybrid: "Hybrid";
|
|
19
19
|
"On Site": "On Site";
|
|
20
20
|
}>;
|
|
21
|
+
status: z.ZodEnum<{
|
|
22
|
+
ACTIVE: "ACTIVE";
|
|
23
|
+
DELETED: "DELETED";
|
|
24
|
+
DRAFT: "DRAFT";
|
|
25
|
+
ARCHIVED: "ARCHIVED";
|
|
26
|
+
}>;
|
|
21
27
|
gigType: z.ZodOptional<z.ZodEnum<{
|
|
22
28
|
"One Time": "One Time";
|
|
23
29
|
Recurring: "Recurring";
|
|
@@ -52,6 +58,12 @@ export declare const JobEntitySchema: z.ZodObject<{
|
|
|
52
58
|
GIG: "GIG";
|
|
53
59
|
ROLE: "ROLE";
|
|
54
60
|
}>;
|
|
61
|
+
status: z.ZodEnum<{
|
|
62
|
+
ACTIVE: "ACTIVE";
|
|
63
|
+
DELETED: "DELETED";
|
|
64
|
+
DRAFT: "DRAFT";
|
|
65
|
+
ARCHIVED: "ARCHIVED";
|
|
66
|
+
}>;
|
|
55
67
|
employmentType: z.ZodOptional<z.ZodEnum<{
|
|
56
68
|
"Full Time": "Full Time";
|
|
57
69
|
"Part Time": "Part Time";
|
|
@@ -120,6 +132,12 @@ export declare const JobWithGigDetailsEntitySchema: z.ZodObject<{
|
|
|
120
132
|
brandId: z.ZodCUID2;
|
|
121
133
|
brandName: z.ZodCUID2;
|
|
122
134
|
brandImgUrl: z.ZodOptional<z.ZodCUID2>;
|
|
135
|
+
status: z.ZodEnum<{
|
|
136
|
+
ACTIVE: "ACTIVE";
|
|
137
|
+
DELETED: "DELETED";
|
|
138
|
+
DRAFT: "DRAFT";
|
|
139
|
+
ARCHIVED: "ARCHIVED";
|
|
140
|
+
}>;
|
|
123
141
|
employmentType: z.ZodOptional<z.ZodEnum<{
|
|
124
142
|
"Full Time": "Full Time";
|
|
125
143
|
"Part Time": "Part Time";
|
|
@@ -223,6 +241,12 @@ export declare const JobWithRoleDetailsEntitySchema: z.ZodObject<{
|
|
|
223
241
|
brandId: z.ZodCUID2;
|
|
224
242
|
brandName: z.ZodCUID2;
|
|
225
243
|
brandImgUrl: z.ZodOptional<z.ZodCUID2>;
|
|
244
|
+
status: z.ZodEnum<{
|
|
245
|
+
ACTIVE: "ACTIVE";
|
|
246
|
+
DELETED: "DELETED";
|
|
247
|
+
DRAFT: "DRAFT";
|
|
248
|
+
ARCHIVED: "ARCHIVED";
|
|
249
|
+
}>;
|
|
226
250
|
employmentType: z.ZodOptional<z.ZodEnum<{
|
|
227
251
|
"Full Time": "Full Time";
|
|
228
252
|
"Part Time": "Part Time";
|
|
@@ -504,6 +528,12 @@ export declare const NormalizedJobOutputSchema: z.ZodDiscriminatedUnion<[z.ZodOb
|
|
|
504
528
|
brandId: z.ZodCUID2;
|
|
505
529
|
brandName: z.ZodCUID2;
|
|
506
530
|
brandImgUrl: z.ZodOptional<z.ZodCUID2>;
|
|
531
|
+
status: z.ZodEnum<{
|
|
532
|
+
ACTIVE: "ACTIVE";
|
|
533
|
+
DELETED: "DELETED";
|
|
534
|
+
DRAFT: "DRAFT";
|
|
535
|
+
ARCHIVED: "ARCHIVED";
|
|
536
|
+
}>;
|
|
507
537
|
employmentType: z.ZodOptional<z.ZodEnum<{
|
|
508
538
|
"Full Time": "Full Time";
|
|
509
539
|
"Part Time": "Part Time";
|
|
@@ -569,6 +599,12 @@ export declare const NormalizedJobOutputSchema: z.ZodDiscriminatedUnion<[z.ZodOb
|
|
|
569
599
|
brandId: z.ZodCUID2;
|
|
570
600
|
brandName: z.ZodCUID2;
|
|
571
601
|
brandImgUrl: z.ZodOptional<z.ZodCUID2>;
|
|
602
|
+
status: z.ZodEnum<{
|
|
603
|
+
ACTIVE: "ACTIVE";
|
|
604
|
+
DELETED: "DELETED";
|
|
605
|
+
DRAFT: "DRAFT";
|
|
606
|
+
ARCHIVED: "ARCHIVED";
|
|
607
|
+
}>;
|
|
572
608
|
employmentType: z.ZodOptional<z.ZodEnum<{
|
|
573
609
|
"Full Time": "Full Time";
|
|
574
610
|
"Part Time": "Part Time";
|
package/dist/schemas/job.js
CHANGED
|
@@ -12,6 +12,7 @@ exports.BaseJobEntitySchema = zod_1.z.object({
|
|
|
12
12
|
.enum(Object.values(constants_1.EMPLOYMENT_TYPE))
|
|
13
13
|
.optional(),
|
|
14
14
|
workMode: zod_1.z.enum(Object.values(constants_1.WORK_MODE)),
|
|
15
|
+
status: zod_1.z.enum(Object.values(constants_1.JOB_STATUS)),
|
|
15
16
|
gigType: zod_1.z
|
|
16
17
|
.enum(Object.values(constants_1.GIG_TYPE))
|
|
17
18
|
.optional(),
|
|
@@ -29,6 +30,7 @@ exports.JobEntitySchema = zod_1.z.object({
|
|
|
29
30
|
brandName: zod_1.z.cuid2(),
|
|
30
31
|
brandImgUrl: zod_1.z.cuid2().optional(),
|
|
31
32
|
jobType: zod_1.z.enum(Object.values(constants_1.JOB_TYPE)),
|
|
33
|
+
status: zod_1.z.enum(Object.values(constants_1.JOB_STATUS)),
|
|
32
34
|
employmentType: zod_1.z
|
|
33
35
|
.enum(Object.values(constants_1.EMPLOYMENT_TYPE))
|
|
34
36
|
.optional(),
|
package/package.json
CHANGED
package/src/constants.ts
CHANGED
|
@@ -169,6 +169,7 @@ export const GIG_TYPE = {
|
|
|
169
169
|
ONE_TIME: "One Time",
|
|
170
170
|
RECURRING: "Recurring",
|
|
171
171
|
} as const;
|
|
172
|
+
|
|
172
173
|
export const WAGES_CURRENCY = {
|
|
173
174
|
USD: "USD",
|
|
174
175
|
EUR: "EUR",
|
|
@@ -182,7 +183,7 @@ export const WAGES_CURRENCY = {
|
|
|
182
183
|
ZAR: "ZAR",
|
|
183
184
|
} as const;
|
|
184
185
|
|
|
185
|
-
export const
|
|
186
|
+
export const JOB_STATUS = {
|
|
186
187
|
ACTIVE: "ACTIVE",
|
|
187
188
|
DRAFT: "DRAFT",
|
|
188
189
|
ARCHIVED: "ARCHIVED",
|
|
@@ -192,8 +193,8 @@ export const JOBPOST_STATUS = {
|
|
|
192
193
|
export type JobSections = (typeof JOB_SECTIONS)[keyof typeof JOB_SECTIONS];
|
|
193
194
|
export type WagesCurrency =
|
|
194
195
|
(typeof WAGES_CURRENCY)[keyof typeof WAGES_CURRENCY];
|
|
195
|
-
export type
|
|
196
|
-
(typeof
|
|
196
|
+
export type JobStatus =
|
|
197
|
+
(typeof JOB_STATUS)[keyof typeof JOB_STATUS];
|
|
197
198
|
export type Role = (typeof ROLES)[keyof typeof ROLES];
|
|
198
199
|
export type JobType = (typeof JOB_TYPE)[keyof typeof JOB_TYPE];
|
|
199
200
|
export type WorkMode = (typeof WORK_MODE)[keyof typeof WORK_MODE];
|
package/src/schemas/job.ts
CHANGED
|
@@ -9,9 +9,11 @@ import {
|
|
|
9
9
|
JOB_AVAILABILITY_TYPES,
|
|
10
10
|
JOB_LOCATIONS,
|
|
11
11
|
JOB_SECTIONS,
|
|
12
|
+
JOB_STATUS,
|
|
12
13
|
JOB_TYPE,
|
|
13
14
|
JobAvailabilityTypes,
|
|
14
15
|
JobLocation,
|
|
16
|
+
JobStatus,
|
|
15
17
|
JobType,
|
|
16
18
|
WAGE_TYPES,
|
|
17
19
|
WAGES_CURRENCY,
|
|
@@ -32,6 +34,7 @@ export const BaseJobEntitySchema = z.object({
|
|
|
32
34
|
)
|
|
33
35
|
.optional(),
|
|
34
36
|
workMode: z.enum(Object.values(WORK_MODE) as [WorkMode, ...WorkMode[]]),
|
|
37
|
+
status: z.enum(Object.values(JOB_STATUS) as [JobStatus, ...JobStatus[]]),
|
|
35
38
|
gigType: z
|
|
36
39
|
.enum(Object.values(GIG_TYPE) as [GigType, ...GigType[]])
|
|
37
40
|
.optional(),
|
|
@@ -53,6 +56,7 @@ export const JobEntitySchema = z.object({
|
|
|
53
56
|
brandName: z.cuid2(),
|
|
54
57
|
brandImgUrl: z.cuid2().optional(),
|
|
55
58
|
jobType: z.enum(Object.values(JOB_TYPE) as [JobType, ...JobType[]]),
|
|
59
|
+
status: z.enum(Object.values(JOB_STATUS) as [JobStatus, ...JobStatus[]]),
|
|
56
60
|
employmentType: z
|
|
57
61
|
.enum(
|
|
58
62
|
Object.values(EMPLOYMENT_TYPE) as [EmploymentType, ...EmploymentType[]]
|