@lyxa.ai/core 1.0.3879 → 1.1.2
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/libraries/bullmq/bull-mq-service.d.ts +1 -1
- package/dist/libraries/bullmq/bull-mq-service.js.map +1 -1
- package/dist/libraries/mongo/models/embedded/capacity-settings.model.d.ts +5 -0
- package/dist/libraries/mongo/models/embedded/capacity-settings.model.js +17 -0
- package/dist/libraries/mongo/models/embedded/capacity-settings.model.js.map +1 -1
- package/dist/libraries/mongo/models/user.model.d.ts +1 -1
- package/dist/libraries/trpc/middlewares/createSocketSubscriptionProcedure.d.ts +2 -2
- package/dist/types/README.md +1 -1
- package/dist/types/package.json +1 -1
- package/dist/types/utilities/validation/common-validation.d.ts +2 -78
- package/dist/types/utilities/validation/global-validation.d.ts +14 -38
- package/dist/types/utilities/validation/index.d.ts +1 -0
- package/dist/types/utilities/validation/index.js +1 -0
- package/dist/types/utilities/validation/index.js.map +1 -1
- package/dist/types/utilities/validation/validation-for-frontend.d.ts +22 -0
- package/dist/types/utilities/validation/validation-for-frontend.js +13 -0
- package/dist/types/utilities/validation/validation-for-frontend.js.map +1 -0
- package/dist/utilities/validation/common-validation.d.ts +2 -78
- package/dist/utilities/validation/global-validation.d.ts +14 -38
- package/dist/utilities/validation/index.d.ts +1 -0
- package/dist/utilities/validation/index.js +1 -0
- package/dist/utilities/validation/index.js.map +1 -1
- package/dist/utilities/validation/validation-for-frontend.d.ts +22 -0
- package/dist/utilities/validation/validation-for-frontend.js +13 -0
- package/dist/utilities/validation/validation-for-frontend.js.map +1 -0
- package/package.json +63 -63
|
@@ -5,5 +5,5 @@ export declare class BullMQService {
|
|
|
5
5
|
private connection;
|
|
6
6
|
constructor(redisService: RedisService);
|
|
7
7
|
createQueue(queueName: string): Queue;
|
|
8
|
-
createWorker<T>(queueName: string, processor: (job: Job<T>) => Promise<
|
|
8
|
+
createWorker<T = any, R = void>(queueName: string, processor: (job: Job<T>) => Promise<R>, options?: Omit<WorkerOptions, 'connection'>): Worker<T, R>;
|
|
9
9
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bull-mq-service.js","sourceRoot":"/","sources":["libraries/bullmq/bull-mq-service.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAEA,mCAAyC;AACzC,mCAAyE;AACzE,0CAA8C;AAGvC,IAAM,aAAa,GAAnB,MAAM,aAAa;IAGuB;IAFxC,UAAU,CAAe;IAEjC,YAAgD,YAA0B;QAA1B,iBAAY,GAAZ,YAAY,CAAc;QACzE,IAAI,CAAC,UAAU,GAAG,EAAE,UAAU,EAAE,IAAI,CAAC,YAAY,CAAC,WAAW,EAAE,CAAC;IACjE,CAAC;IAKM,WAAW,CAAC,SAAiB;QACnC,OAAO,IAAI,cAAK,CAAC,SAAS,EAAE,IAAI,CAAC,UAAU,CAAC,CAAC;IAC9C,CAAC;IAKM,YAAY,CAClB,SAAiB,EACjB,
|
|
1
|
+
{"version":3,"file":"bull-mq-service.js","sourceRoot":"/","sources":["libraries/bullmq/bull-mq-service.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAEA,mCAAyC;AACzC,mCAAyE;AACzE,0CAA8C;AAGvC,IAAM,aAAa,GAAnB,MAAM,aAAa;IAGuB;IAFxC,UAAU,CAAe;IAEjC,YAAgD,YAA0B;QAA1B,iBAAY,GAAZ,YAAY,CAAc;QACzE,IAAI,CAAC,UAAU,GAAG,EAAE,UAAU,EAAE,IAAI,CAAC,YAAY,CAAC,WAAW,EAAE,CAAC;IACjE,CAAC;IAKM,WAAW,CAAC,SAAiB;QACnC,OAAO,IAAI,cAAK,CAAC,SAAS,EAAE,IAAI,CAAC,UAAU,CAAC,CAAC;IAC9C,CAAC;IAKM,YAAY,CAClB,SAAiB,EACjB,SAAsC,EACtC,OAA2C;QAE3C,OAAO,IAAI,eAAM,CAAO,SAAS,EAAE,SAAS,EAAE;YAC7C,GAAG,IAAI,CAAC,UAAU;YAClB,GAAG,OAAO;SACV,CAAC,CAAC;IACJ,CAAC;CACD,CAAA;AA3BY,sCAAa;wBAAb,aAAa;IADzB,IAAA,gBAAO,GAAE;IAII,WAAA,IAAA,eAAM,EAAC,GAAG,EAAE,CAAC,oBAAY,CAAC,CAAA;qCAAuB,oBAAY;GAH9D,aAAa,CA2BzB","sourcesContent":["// lyxa-core/libraries/bullmq/BullMQService.ts\n\nimport { Service, Inject } from 'typedi';\nimport { Queue, Worker, Job, QueueOptions, WorkerOptions } from 'bullmq';\nimport { RedisService } from '../redis/index';\n\n@Service()\nexport class BullMQService {\n\tprivate connection: QueueOptions;\n\n\tconstructor(@Inject(() => RedisService) private redisService: RedisService) {\n\t\tthis.connection = { connection: this.redisService.redisClient };\n\t}\n\n\t/**\n\t * Creates a new queue.\n\t */\n\tpublic createQueue(queueName: string): Queue {\n\t\treturn new Queue(queueName, this.connection);\n\t}\n\n\t/**\n\t * Creates a worker to process jobs from a given queue.\n\t */\n\tpublic createWorker<T = any, R = void>(\n\t\tqueueName: string,\n\t\tprocessor: (job: Job<T>) => Promise<R>,\n\t\toptions?: Omit<WorkerOptions, 'connection'>\n\t): Worker<T, R> {\n\t\treturn new Worker<T, R>(queueName, processor, {\n\t\t\t...this.connection,\n\t\t\t...options,\n\t\t});\n\t}\n}\n"]}
|
|
@@ -9,9 +9,14 @@ declare class Capacity {
|
|
|
9
9
|
day: WeekDay;
|
|
10
10
|
services: Services[];
|
|
11
11
|
}
|
|
12
|
+
declare class FurnitureCleaningConfiguration {
|
|
13
|
+
numberOfPackages: number;
|
|
14
|
+
numberOfProfessionals: number;
|
|
15
|
+
}
|
|
12
16
|
export declare class CapacitySettings {
|
|
13
17
|
slotBufferTime: number;
|
|
14
18
|
slotInterval: number;
|
|
15
19
|
capacity: Capacity[];
|
|
20
|
+
furnitureCleaningConfig?: FurnitureCleaningConfiguration[];
|
|
16
21
|
}
|
|
17
22
|
export {};
|
|
@@ -39,10 +39,23 @@ __decorate([
|
|
|
39
39
|
(0, typegoose_1.prop)({ type: () => [Services] }),
|
|
40
40
|
__metadata("design:type", Array)
|
|
41
41
|
], Capacity.prototype, "services", void 0);
|
|
42
|
+
class FurnitureCleaningConfiguration {
|
|
43
|
+
numberOfPackages;
|
|
44
|
+
numberOfProfessionals;
|
|
45
|
+
}
|
|
46
|
+
__decorate([
|
|
47
|
+
(0, typegoose_1.prop)({ required: true }),
|
|
48
|
+
__metadata("design:type", Number)
|
|
49
|
+
], FurnitureCleaningConfiguration.prototype, "numberOfPackages", void 0);
|
|
50
|
+
__decorate([
|
|
51
|
+
(0, typegoose_1.prop)({ required: true }),
|
|
52
|
+
__metadata("design:type", Number)
|
|
53
|
+
], FurnitureCleaningConfiguration.prototype, "numberOfProfessionals", void 0);
|
|
42
54
|
let CapacitySettings = class CapacitySettings {
|
|
43
55
|
slotBufferTime;
|
|
44
56
|
slotInterval;
|
|
45
57
|
capacity;
|
|
58
|
+
furnitureCleaningConfig;
|
|
46
59
|
};
|
|
47
60
|
exports.CapacitySettings = CapacitySettings;
|
|
48
61
|
__decorate([
|
|
@@ -65,6 +78,10 @@ __decorate([
|
|
|
65
78
|
(0, typegoose_1.prop)({ type: () => [Capacity] }),
|
|
66
79
|
__metadata("design:type", Array)
|
|
67
80
|
], CapacitySettings.prototype, "capacity", void 0);
|
|
81
|
+
__decorate([
|
|
82
|
+
(0, typegoose_1.prop)({ type: () => [FurnitureCleaningConfiguration] }),
|
|
83
|
+
__metadata("design:type", Array)
|
|
84
|
+
], CapacitySettings.prototype, "furnitureCleaningConfig", void 0);
|
|
68
85
|
exports.CapacitySettings = CapacitySettings = __decorate([
|
|
69
86
|
(0, typegoose_1.modelOptions)({ schemaOptions: { collection: 'capacitySettings' } })
|
|
70
87
|
], CapacitySettings);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"capacity-settings.model.js","sourceRoot":"/","sources":["libraries/mongo/models/embedded/capacity-settings.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA+D;AAC/D,qDAAqD;AAIrD,MAAM,QAAQ;IAEH,OAAO,CAAe;IAMtB,qBAAqB,CAAU;CACzC;AAPU;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;yCACI;AAMtB;IAJN,IAAA,gBAAI,EAAC;QACF,QAAQ,EAAE,IAAI;QACd,IAAI,EAAE,MAAM;KACf,CAAC;;uDACoC;AAG1C,MAAM,QAAQ;IAEH,GAAG,CAAW;IAGd,QAAQ,CAAa;CAC/B;AAJU;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,cAAO,EAAE,CAAC;;qCACjC;AAGd;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,CAAC,QAAQ,CAAC,EAAE,CAAC;;0CACL;
|
|
1
|
+
{"version":3,"file":"capacity-settings.model.js","sourceRoot":"/","sources":["libraries/mongo/models/embedded/capacity-settings.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA+D;AAC/D,qDAAqD;AAIrD,MAAM,QAAQ;IAEH,OAAO,CAAe;IAMtB,qBAAqB,CAAU;CACzC;AAPU;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;yCACI;AAMtB;IAJN,IAAA,gBAAI,EAAC;QACF,QAAQ,EAAE,IAAI;QACd,IAAI,EAAE,MAAM;KACf,CAAC;;uDACoC;AAG1C,MAAM,QAAQ;IAEH,GAAG,CAAW;IAGd,QAAQ,CAAa;CAC/B;AAJU;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,cAAO,EAAE,CAAC;;qCACjC;AAGd;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,CAAC,QAAQ,CAAC,EAAE,CAAC;;0CACL;AAGhC,MAAM,8BAA8B;IAEzB,gBAAgB,CAAU;IAG1B,qBAAqB,CAAU;CACzC;AAJU;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;wEACQ;AAG1B;IADN,IAAA,gBAAI,EAAC,EAAC,QAAQ,EAAE,IAAI,EAAE,CAAC;;6EACc;AAInC,IAAM,gBAAgB,GAAtB,MAAM,gBAAgB;IAMlB,cAAc,CAAS;IAOvB,YAAY,CAAS;IAGrB,QAAQ,CAAY;IAGpB,uBAAuB,CAAmC;CACpE,CAAA;AApBY,4CAAgB;AAMlB;IALN,IAAA,gBAAI,EAAC;QACF,GAAG,EAAE,CAAC;QACN,GAAG,EAAE,EAAE;QACP,OAAO,EAAE,CAAC;KACb,CAAC;;wDAC4B;AAOvB;IALN,IAAA,gBAAI,EAAC;QACF,GAAG,EAAE,EAAE;QACP,GAAG,EAAE,GAAG;QACR,OAAO,EAAE,EAAE;KACd,CAAC;;sDAC0B;AAGrB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,CAAC,QAAQ,CAAC,EAAC,CAAC;;kDACL;AAGpB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,CAAC,8BAA8B,CAAC,EAAE,CAAC;;iEACU;2BAnBxD,gBAAgB;IAD5B,IAAA,wBAAY,EAAC,EAAE,aAAa,EAAE,EAAE,UAAU,EAAE,kBAAkB,EAAE,EAAE,CAAC;GACvD,gBAAgB,CAoB5B","sourcesContent":["import { modelOptions, prop, Ref } from '@typegoose/typegoose';\nimport { WeekDay } from '../../../../utilities/enum';\nimport { Service } from '../service.model';\n\n\nclass Services {\n @prop({ required: true })\n public service!: Ref<Service>\n\n @prop({\n required: true,\n type: Number,\n })\n public numberOfProfessionals!: number;\n}\n\nclass Capacity {\n @prop({ required: true, type: Number, enum: WeekDay })\n public day!: WeekDay;\n\n @prop({ type: () => [Services] })\n public services!: Services[]\n}\n\nclass FurnitureCleaningConfiguration {\n @prop({ required: true })\n public numberOfPackages!: number;\n\n @prop({required: true })\n public numberOfProfessionals!: number;\n}\n\n@modelOptions({ schemaOptions: { collection: 'capacitySettings' } })\nexport class CapacitySettings {\n @prop({\n min: 5,\n max: 60,\n default: 5,\n })\n public slotBufferTime: number; // minutes\n\n @prop({\n min: 30,\n max: 120,\n default: 30,\n })\n public slotInterval: number; // minutes\n\n @prop({ type: () => [Capacity]})\n public capacity: Capacity[]\n\n @prop({ type: () => [FurnitureCleaningConfiguration] })\n public furnitureCleaningConfig?: FurnitureCleaningConfiguration[]\n}\n"]}
|
|
@@ -31,7 +31,7 @@ export declare class User extends TimeStamps {
|
|
|
31
31
|
isPhoneVerified?: boolean;
|
|
32
32
|
onlineStatus?: OnlineStatus;
|
|
33
33
|
fcmTokens?: string[];
|
|
34
|
-
static updateWallet(this: ReturnModelType<typeof User>, userId: string, amount: number): Promise<(import("mongoose").Document<unknown, import("@typegoose/typegoose/lib/types").BeAnObject, User, import("@typegoose/typegoose/lib/types").BeAnyObject> & Omit<User & {
|
|
34
|
+
static updateWallet(this: ReturnModelType<typeof User>, userId: string, amount: number): Promise<(import("mongoose").Document<unknown, import("@typegoose/typegoose/lib/types").BeAnObject, User, import("@typegoose/typegoose/lib/types").BeAnyObject, {}> & Omit<User & {
|
|
35
35
|
_id: import("mongoose").Types.ObjectId;
|
|
36
36
|
} & {
|
|
37
37
|
__v: number;
|
|
@@ -8,7 +8,7 @@ export declare function createSocketSubscriptionProcedure<I extends ZodTypeAny,
|
|
|
8
8
|
outputSchema: O;
|
|
9
9
|
getId: (out: z.infer<O>) => string;
|
|
10
10
|
}): import("@trpc/server").TRPCSubscriptionProcedure<{
|
|
11
|
-
input: import("@trpc/server/dist/unstable-core-do-not-import.d-
|
|
12
|
-
output: AsyncIterable<import("@trpc/server/dist/unstable-core-do-not-import.d-
|
|
11
|
+
input: import("@trpc/server/dist/unstable-core-do-not-import.d-C8vB_hCN.cjs").inferParser<I>["in"] extends infer T ? T extends import("@trpc/server/dist/unstable-core-do-not-import.d-C8vB_hCN.cjs").inferParser<I>["in"] ? T extends import("@trpc/server").TRPCUnsetMarker ? void : T : never : never;
|
|
12
|
+
output: AsyncIterable<import("@trpc/server/dist/unstable-core-do-not-import.d-C8vB_hCN.cjs").TrackedData<any>, void, unknown>;
|
|
13
13
|
meta: object;
|
|
14
14
|
}>;
|
package/dist/types/README.md
CHANGED
package/dist/types/package.json
CHANGED
|
@@ -587,7 +587,7 @@ export declare const createResponseSchema: <T>(schema: z.ZodSchema<T>) => z.ZodO
|
|
|
587
587
|
totalPages: number;
|
|
588
588
|
} | undefined;
|
|
589
589
|
}>, z.ZodType<T, z.ZodTypeDef, T>]>>;
|
|
590
|
-
}>, any> extends infer T_1 ? { [k in keyof T_1]: z.
|
|
590
|
+
}>, any> extends infer T_1 ? { [k in keyof T_1]: T_1[k]; } : never, z.baseObjectInputType<{
|
|
591
591
|
success: z.ZodBoolean;
|
|
592
592
|
message: z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
|
|
593
593
|
data: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
|
|
@@ -625,83 +625,7 @@ export declare const createResponseSchema: <T>(schema: z.ZodSchema<T>) => z.ZodO
|
|
|
625
625
|
totalPages: number;
|
|
626
626
|
} | undefined;
|
|
627
627
|
}>, z.ZodType<T, z.ZodTypeDef, T>]>>;
|
|
628
|
-
}
|
|
629
|
-
success: z.ZodBoolean;
|
|
630
|
-
message: z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
|
|
631
|
-
data: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
|
|
632
|
-
metadata: z.ZodOptional<z.ZodObject<{
|
|
633
|
-
page: z.ZodNumber;
|
|
634
|
-
size: z.ZodNumber;
|
|
635
|
-
totalElements: z.ZodNumber;
|
|
636
|
-
totalPages: z.ZodNumber;
|
|
637
|
-
}, "strip", z.ZodTypeAny, {
|
|
638
|
-
size: number;
|
|
639
|
-
page: number;
|
|
640
|
-
totalElements: number;
|
|
641
|
-
totalPages: number;
|
|
642
|
-
}, {
|
|
643
|
-
size: number;
|
|
644
|
-
page: number;
|
|
645
|
-
totalElements: number;
|
|
646
|
-
totalPages: number;
|
|
647
|
-
}>>;
|
|
648
|
-
documents: z.ZodArray<z.ZodType<T, z.ZodTypeDef, T>, "many">;
|
|
649
|
-
}, "strip", z.ZodTypeAny, {
|
|
650
|
-
documents: T[];
|
|
651
|
-
metadata?: {
|
|
652
|
-
size: number;
|
|
653
|
-
page: number;
|
|
654
|
-
totalElements: number;
|
|
655
|
-
totalPages: number;
|
|
656
|
-
} | undefined;
|
|
657
|
-
}, {
|
|
658
|
-
documents: T[];
|
|
659
|
-
metadata?: {
|
|
660
|
-
size: number;
|
|
661
|
-
page: number;
|
|
662
|
-
totalElements: number;
|
|
663
|
-
totalPages: number;
|
|
664
|
-
} | undefined;
|
|
665
|
-
}>, z.ZodType<T, z.ZodTypeDef, T>]>>;
|
|
666
|
-
}> extends infer T_2 ? { [k_1 in keyof T_2]: z.baseObjectInputType<{
|
|
667
|
-
success: z.ZodBoolean;
|
|
668
|
-
message: z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
|
|
669
|
-
data: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
|
|
670
|
-
metadata: z.ZodOptional<z.ZodObject<{
|
|
671
|
-
page: z.ZodNumber;
|
|
672
|
-
size: z.ZodNumber;
|
|
673
|
-
totalElements: z.ZodNumber;
|
|
674
|
-
totalPages: z.ZodNumber;
|
|
675
|
-
}, "strip", z.ZodTypeAny, {
|
|
676
|
-
size: number;
|
|
677
|
-
page: number;
|
|
678
|
-
totalElements: number;
|
|
679
|
-
totalPages: number;
|
|
680
|
-
}, {
|
|
681
|
-
size: number;
|
|
682
|
-
page: number;
|
|
683
|
-
totalElements: number;
|
|
684
|
-
totalPages: number;
|
|
685
|
-
}>>;
|
|
686
|
-
documents: z.ZodArray<z.ZodType<T, z.ZodTypeDef, T>, "many">;
|
|
687
|
-
}, "strip", z.ZodTypeAny, {
|
|
688
|
-
documents: T[];
|
|
689
|
-
metadata?: {
|
|
690
|
-
size: number;
|
|
691
|
-
page: number;
|
|
692
|
-
totalElements: number;
|
|
693
|
-
totalPages: number;
|
|
694
|
-
} | undefined;
|
|
695
|
-
}, {
|
|
696
|
-
documents: T[];
|
|
697
|
-
metadata?: {
|
|
698
|
-
size: number;
|
|
699
|
-
page: number;
|
|
700
|
-
totalElements: number;
|
|
701
|
-
totalPages: number;
|
|
702
|
-
} | undefined;
|
|
703
|
-
}>, z.ZodType<T, z.ZodTypeDef, T>]>>;
|
|
704
|
-
}>[k_1]; } : never>;
|
|
628
|
+
}> extends infer T_2 ? { [k_1 in keyof T_2]: T_2[k_1]; } : never>;
|
|
705
629
|
export type PaginatedDTO<T> = {
|
|
706
630
|
metadata: DTO<typeof metadataSchema>;
|
|
707
631
|
documents: T[];
|
|
@@ -76,34 +76,22 @@ export declare class SchemaBuilder<T extends z.ZodRawShape> {
|
|
|
76
76
|
private baseSchema;
|
|
77
77
|
constructor(baseFields: T, includeTimestamps?: boolean, includeTracking?: boolean);
|
|
78
78
|
private createBaseSchema;
|
|
79
|
-
getBaseSchema(): z.ZodObject<T, "strict", z.ZodTypeAny, z.objectUtil.addQuestionMarks<z.baseObjectOutputType<T>, any> extends infer T_1 ? { [k in keyof T_1]:
|
|
79
|
+
getBaseSchema(): z.ZodObject<T, "strict", z.ZodTypeAny, z.objectUtil.addQuestionMarks<z.baseObjectOutputType<T>, any> extends infer T_1 ? { [k in keyof T_1]: T_1[k]; } : never, z.baseObjectInputType<T> extends infer T_2 ? { [k_1 in keyof T_2]: T_2[k_1]; } : never>;
|
|
80
80
|
getEntitySchema(): z.ZodObject<z.objectUtil.extendShape<T, {
|
|
81
81
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
82
|
-
}> extends infer T_1 extends z.ZodRawShape ? { [k in keyof T_1]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
82
|
+
}> extends infer T_1 extends z.ZodRawShape ? { [k in keyof T_1]: z.ZodOptional<T_1[k]>; } : never, "passthrough", z.ZodTypeAny, z.objectOutputType<z.objectUtil.extendShape<T, {
|
|
83
83
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
84
|
-
}>[k]>; } : never,
|
|
84
|
+
}> extends infer T_2 extends z.ZodRawShape ? { [k in keyof T_2]: z.ZodOptional<T_2[k]>; } : never, z.ZodTypeAny, "passthrough">, z.objectInputType<z.objectUtil.extendShape<T, {
|
|
85
85
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
86
|
-
}> extends infer
|
|
87
|
-
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
88
|
-
}>[k]>; } : never, z.ZodTypeAny, "passthrough">, z.objectInputType<z.objectUtil.extendShape<T, {
|
|
89
|
-
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
90
|
-
}> extends infer T_3 extends z.ZodRawShape ? { [k in keyof T_3]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
91
|
-
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
92
|
-
}>[k]>; } : never, z.ZodTypeAny, "passthrough">>;
|
|
86
|
+
}> extends infer T_3 extends z.ZodRawShape ? { [k in keyof T_3]: z.ZodOptional<T_3[k]>; } : never, z.ZodTypeAny, "passthrough">>;
|
|
93
87
|
getIdSchema(): z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
94
88
|
getUpdateSchema(excludeFields?: ExcludeFromUpdate): z.ZodObject<z.objectUtil.extendShape<T, {
|
|
95
89
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
96
|
-
}> extends infer T_1 extends z.ZodRawShape ? { [k in keyof T_1]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
97
|
-
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
98
|
-
}>[k]>; } : never, "passthrough", z.ZodTypeAny, z.objectOutputType<z.objectUtil.extendShape<T, {
|
|
99
|
-
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
100
|
-
}> extends infer T_2 extends z.ZodRawShape ? { [k in keyof T_2]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
101
|
-
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
102
|
-
}>[k]>; } : never, z.ZodTypeAny, "passthrough">, z.objectInputType<z.objectUtil.extendShape<T, {
|
|
90
|
+
}> extends infer T_1 extends z.ZodRawShape ? { [k in keyof T_1]: z.ZodOptional<T_1[k]>; } : never, "passthrough", z.ZodTypeAny, z.objectOutputType<z.objectUtil.extendShape<T, {
|
|
103
91
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
104
|
-
}> extends infer
|
|
92
|
+
}> extends infer T_2 extends z.ZodRawShape ? { [k in keyof T_2]: z.ZodOptional<T_2[k]>; } : never, z.ZodTypeAny, "passthrough">, z.objectInputType<z.objectUtil.extendShape<T, {
|
|
105
93
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
106
|
-
}>[k]>; } : never, z.ZodTypeAny, "passthrough">> | z.ZodObject<{
|
|
94
|
+
}> extends infer T_3 extends z.ZodRawShape ? { [k in keyof T_3]: z.ZodOptional<T_3[k]>; } : never, z.ZodTypeAny, "passthrough">> | z.ZodObject<{
|
|
107
95
|
[x: string]: z.ZodOptional<z.ZodTypeAny>;
|
|
108
96
|
}, "strict", z.ZodTypeAny, {
|
|
109
97
|
[x: string]: any;
|
|
@@ -126,34 +114,22 @@ export declare class SchemaBuilder<T extends z.ZodRawShape> {
|
|
|
126
114
|
[x: string]: any;
|
|
127
115
|
}>;
|
|
128
116
|
getAllSchemas(excludeFromUpdate?: ExcludeFromUpdate): {
|
|
129
|
-
BaseSchema: z.ZodObject<T, "strict", z.ZodTypeAny, z.objectUtil.addQuestionMarks<z.baseObjectOutputType<T>, any> extends infer T_1 ? { [k in keyof T_1]:
|
|
117
|
+
BaseSchema: z.ZodObject<T, "strict", z.ZodTypeAny, z.objectUtil.addQuestionMarks<z.baseObjectOutputType<T>, any> extends infer T_1 ? { [k in keyof T_1]: T_1[k]; } : never, z.baseObjectInputType<T> extends infer T_2 ? { [k_1 in keyof T_2]: T_2[k_1]; } : never>;
|
|
130
118
|
EntitySchema: z.ZodObject<z.objectUtil.extendShape<T, {
|
|
131
119
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
132
|
-
}> extends infer T_3 extends z.ZodRawShape ? { [k_2 in keyof T_3]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
120
|
+
}> extends infer T_3 extends z.ZodRawShape ? { [k_2 in keyof T_3]: z.ZodOptional<T_3[k_2]>; } : never, "passthrough", z.ZodTypeAny, z.objectOutputType<z.objectUtil.extendShape<T, {
|
|
133
121
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
134
|
-
}>[k_2]>; } : never,
|
|
122
|
+
}> extends infer T_4 extends z.ZodRawShape ? { [k_2 in keyof T_4]: z.ZodOptional<T_4[k_2]>; } : never, z.ZodTypeAny, "passthrough">, z.objectInputType<z.objectUtil.extendShape<T, {
|
|
135
123
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
136
|
-
}> extends infer
|
|
137
|
-
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
138
|
-
}>[k_2]>; } : never, z.ZodTypeAny, "passthrough">, z.objectInputType<z.objectUtil.extendShape<T, {
|
|
139
|
-
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
140
|
-
}> extends infer T_5 extends z.ZodRawShape ? { [k_2 in keyof T_5]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
141
|
-
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
142
|
-
}>[k_2]>; } : never, z.ZodTypeAny, "passthrough">>;
|
|
124
|
+
}> extends infer T_5 extends z.ZodRawShape ? { [k_2 in keyof T_5]: z.ZodOptional<T_5[k_2]>; } : never, z.ZodTypeAny, "passthrough">>;
|
|
143
125
|
IdSchema: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
144
126
|
UpdateSchema: z.ZodObject<z.objectUtil.extendShape<T, {
|
|
145
127
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
146
|
-
}> extends infer T_6 extends z.ZodRawShape ? { [k_2 in keyof T_6]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
147
|
-
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
148
|
-
}>[k_2]>; } : never, "passthrough", z.ZodTypeAny, z.objectOutputType<z.objectUtil.extendShape<T, {
|
|
149
|
-
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
150
|
-
}> extends infer T_7 extends z.ZodRawShape ? { [k_2 in keyof T_7]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
151
|
-
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
152
|
-
}>[k_2]>; } : never, z.ZodTypeAny, "passthrough">, z.objectInputType<z.objectUtil.extendShape<T, {
|
|
128
|
+
}> extends infer T_6 extends z.ZodRawShape ? { [k_2 in keyof T_6]: z.ZodOptional<T_6[k_2]>; } : never, "passthrough", z.ZodTypeAny, z.objectOutputType<z.objectUtil.extendShape<T, {
|
|
153
129
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
154
|
-
}> extends infer
|
|
130
|
+
}> extends infer T_7 extends z.ZodRawShape ? { [k_2 in keyof T_7]: z.ZodOptional<T_7[k_2]>; } : never, z.ZodTypeAny, "passthrough">, z.objectInputType<z.objectUtil.extendShape<T, {
|
|
155
131
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
156
|
-
}>[k_2]>; } : never, z.ZodTypeAny, "passthrough">> | z.ZodObject<{
|
|
132
|
+
}> extends infer T_8 extends z.ZodRawShape ? { [k_2 in keyof T_8]: z.ZodOptional<T_8[k_2]>; } : never, z.ZodTypeAny, "passthrough">> | z.ZodObject<{
|
|
157
133
|
[x: string]: z.ZodOptional<z.ZodTypeAny>;
|
|
158
134
|
}, "strict", z.ZodTypeAny, {
|
|
159
135
|
[x: string]: any;
|
|
@@ -16,4 +16,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
__exportStar(require("./common-validation"), exports);
|
|
18
18
|
__exportStar(require("./global-validation"), exports);
|
|
19
|
+
__exportStar(require("./validation-for-frontend"), exports);
|
|
19
20
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"/","sources":["utilities/validation/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,sDAAoC;AACpC,sDAAoC","sourcesContent":["export * from './common-validation';\nexport * from './global-validation';\n"]}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"/","sources":["utilities/validation/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,sDAAoC;AACpC,sDAAoC;AACpC,4DAA0C","sourcesContent":["export * from './common-validation';\nexport * from './global-validation';\nexport * from './validation-for-frontend';\n"]}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { DTO } from './global-validation';
|
|
2
|
+
import { z } from 'zod';
|
|
3
|
+
export declare const UserAddressFrontendSchema: z.ZodObject<{
|
|
4
|
+
addressLabel: z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
|
|
5
|
+
apartment: z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
|
|
6
|
+
buildingName: z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
|
|
7
|
+
deliveryOption: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
8
|
+
instructions: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
9
|
+
}, "strip", z.ZodTypeAny, {
|
|
10
|
+
addressLabel: string;
|
|
11
|
+
apartment: string;
|
|
12
|
+
buildingName: string;
|
|
13
|
+
deliveryOption?: string | undefined;
|
|
14
|
+
instructions?: string | undefined;
|
|
15
|
+
}, {
|
|
16
|
+
addressLabel: string;
|
|
17
|
+
apartment: string;
|
|
18
|
+
buildingName: string;
|
|
19
|
+
deliveryOption?: string | undefined;
|
|
20
|
+
instructions?: string | undefined;
|
|
21
|
+
}>;
|
|
22
|
+
export type UserAddressFrontendDTO = DTO<typeof UserAddressFrontendSchema>;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.UserAddressFrontendSchema = void 0;
|
|
4
|
+
const global_validation_1 = require("./global-validation");
|
|
5
|
+
const zod_1 = require("zod");
|
|
6
|
+
exports.UserAddressFrontendSchema = zod_1.z.object({
|
|
7
|
+
addressLabel: global_validation_1.ZodValidation.string('Address Label', { maxLength: 20 }),
|
|
8
|
+
apartment: global_validation_1.ZodValidation.string('Apt/Suite/Floor', { maxLength: 30 }),
|
|
9
|
+
buildingName: global_validation_1.ZodValidation.string('Building Name', { maxLength: 30 }),
|
|
10
|
+
deliveryOption: global_validation_1.ZodValidation.string('Delivery Option').optional(),
|
|
11
|
+
instructions: global_validation_1.ZodValidation.string('Instructions', { maxLength: 250 }).optional(),
|
|
12
|
+
});
|
|
13
|
+
//# sourceMappingURL=validation-for-frontend.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"validation-for-frontend.js","sourceRoot":"/","sources":["utilities/validation/validation-for-frontend.ts"],"names":[],"mappings":";;;AAAA,2DAAyD;AACzD,6BAAwB;AAEX,QAAA,yBAAyB,GAAG,OAAC,CAAC,MAAM,CAAC;IACjD,YAAY,EAAE,iCAAa,CAAC,MAAM,CAAC,eAAe,EAAE,EAAC,SAAS,EAAE,EAAE,EAAC,CAAC;IACpE,SAAS,EAAE,iCAAa,CAAC,MAAM,CAAC,iBAAiB,EAAE,EAAC,SAAS,EAAE,EAAE,EAAC,CAAC;IACnE,YAAY,EAAE,iCAAa,CAAC,MAAM,CAAC,eAAe,EAAE,EAAC,SAAS,EAAE,EAAE,EAAC,CAAC;IACpE,cAAc,EAAE,iCAAa,CAAC,MAAM,CAAC,iBAAiB,CAAC,CAAC,QAAQ,EAAE;IAClE,YAAY,EAAE,iCAAa,CAAC,MAAM,CAAC,cAAc,EAAE,EAAC,SAAS,EAAE,GAAG,EAAC,CAAC,CAAC,QAAQ,EAAE;CAC/E,CAAC,CAAC","sourcesContent":["import { DTO, ZodValidation } from './global-validation';\nimport { z } from 'zod';\n\nexport const UserAddressFrontendSchema = z.object({\n\taddressLabel: ZodValidation.string('Address Label', {maxLength: 20}),\n\tapartment: ZodValidation.string('Apt/Suite/Floor', {maxLength: 30}),\n\tbuildingName: ZodValidation.string('Building Name', {maxLength: 30}),\n\tdeliveryOption: ZodValidation.string('Delivery Option').optional(),\n\tinstructions: ZodValidation.string('Instructions', {maxLength: 250}).optional(),\n});\nexport type UserAddressFrontendDTO = DTO<typeof UserAddressFrontendSchema>;"]}
|
|
@@ -587,7 +587,7 @@ export declare const createResponseSchema: <T>(schema: z.ZodSchema<T>) => z.ZodO
|
|
|
587
587
|
totalPages: number;
|
|
588
588
|
} | undefined;
|
|
589
589
|
}>, z.ZodType<T, z.ZodTypeDef, T>]>>;
|
|
590
|
-
}>, any> extends infer T_1 ? { [k in keyof T_1]: z.
|
|
590
|
+
}>, any> extends infer T_1 ? { [k in keyof T_1]: T_1[k]; } : never, z.baseObjectInputType<{
|
|
591
591
|
success: z.ZodBoolean;
|
|
592
592
|
message: z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
|
|
593
593
|
data: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
|
|
@@ -625,83 +625,7 @@ export declare const createResponseSchema: <T>(schema: z.ZodSchema<T>) => z.ZodO
|
|
|
625
625
|
totalPages: number;
|
|
626
626
|
} | undefined;
|
|
627
627
|
}>, z.ZodType<T, z.ZodTypeDef, T>]>>;
|
|
628
|
-
}
|
|
629
|
-
success: z.ZodBoolean;
|
|
630
|
-
message: z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
|
|
631
|
-
data: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
|
|
632
|
-
metadata: z.ZodOptional<z.ZodObject<{
|
|
633
|
-
page: z.ZodNumber;
|
|
634
|
-
size: z.ZodNumber;
|
|
635
|
-
totalElements: z.ZodNumber;
|
|
636
|
-
totalPages: z.ZodNumber;
|
|
637
|
-
}, "strip", z.ZodTypeAny, {
|
|
638
|
-
page: number;
|
|
639
|
-
size: number;
|
|
640
|
-
totalElements: number;
|
|
641
|
-
totalPages: number;
|
|
642
|
-
}, {
|
|
643
|
-
page: number;
|
|
644
|
-
size: number;
|
|
645
|
-
totalElements: number;
|
|
646
|
-
totalPages: number;
|
|
647
|
-
}>>;
|
|
648
|
-
documents: z.ZodArray<z.ZodType<T, z.ZodTypeDef, T>, "many">;
|
|
649
|
-
}, "strip", z.ZodTypeAny, {
|
|
650
|
-
documents: T[];
|
|
651
|
-
metadata?: {
|
|
652
|
-
page: number;
|
|
653
|
-
size: number;
|
|
654
|
-
totalElements: number;
|
|
655
|
-
totalPages: number;
|
|
656
|
-
} | undefined;
|
|
657
|
-
}, {
|
|
658
|
-
documents: T[];
|
|
659
|
-
metadata?: {
|
|
660
|
-
page: number;
|
|
661
|
-
size: number;
|
|
662
|
-
totalElements: number;
|
|
663
|
-
totalPages: number;
|
|
664
|
-
} | undefined;
|
|
665
|
-
}>, z.ZodType<T, z.ZodTypeDef, T>]>>;
|
|
666
|
-
}> extends infer T_2 ? { [k_1 in keyof T_2]: z.baseObjectInputType<{
|
|
667
|
-
success: z.ZodBoolean;
|
|
668
|
-
message: z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
|
|
669
|
-
data: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
|
|
670
|
-
metadata: z.ZodOptional<z.ZodObject<{
|
|
671
|
-
page: z.ZodNumber;
|
|
672
|
-
size: z.ZodNumber;
|
|
673
|
-
totalElements: z.ZodNumber;
|
|
674
|
-
totalPages: z.ZodNumber;
|
|
675
|
-
}, "strip", z.ZodTypeAny, {
|
|
676
|
-
page: number;
|
|
677
|
-
size: number;
|
|
678
|
-
totalElements: number;
|
|
679
|
-
totalPages: number;
|
|
680
|
-
}, {
|
|
681
|
-
page: number;
|
|
682
|
-
size: number;
|
|
683
|
-
totalElements: number;
|
|
684
|
-
totalPages: number;
|
|
685
|
-
}>>;
|
|
686
|
-
documents: z.ZodArray<z.ZodType<T, z.ZodTypeDef, T>, "many">;
|
|
687
|
-
}, "strip", z.ZodTypeAny, {
|
|
688
|
-
documents: T[];
|
|
689
|
-
metadata?: {
|
|
690
|
-
page: number;
|
|
691
|
-
size: number;
|
|
692
|
-
totalElements: number;
|
|
693
|
-
totalPages: number;
|
|
694
|
-
} | undefined;
|
|
695
|
-
}, {
|
|
696
|
-
documents: T[];
|
|
697
|
-
metadata?: {
|
|
698
|
-
page: number;
|
|
699
|
-
size: number;
|
|
700
|
-
totalElements: number;
|
|
701
|
-
totalPages: number;
|
|
702
|
-
} | undefined;
|
|
703
|
-
}>, z.ZodType<T, z.ZodTypeDef, T>]>>;
|
|
704
|
-
}>[k_1]; } : never>;
|
|
628
|
+
}> extends infer T_2 ? { [k_1 in keyof T_2]: T_2[k_1]; } : never>;
|
|
705
629
|
export type PaginatedDTO<T> = {
|
|
706
630
|
metadata: DTO<typeof metadataSchema>;
|
|
707
631
|
documents: T[];
|
|
@@ -76,34 +76,22 @@ export declare class SchemaBuilder<T extends z.ZodRawShape> {
|
|
|
76
76
|
private baseSchema;
|
|
77
77
|
constructor(baseFields: T, includeTimestamps?: boolean, includeTracking?: boolean);
|
|
78
78
|
private createBaseSchema;
|
|
79
|
-
getBaseSchema(): z.ZodObject<T, "strict", z.ZodTypeAny, z.objectUtil.addQuestionMarks<z.baseObjectOutputType<T>, any> extends infer T_1 ? { [k in keyof T_1]:
|
|
79
|
+
getBaseSchema(): z.ZodObject<T, "strict", z.ZodTypeAny, z.objectUtil.addQuestionMarks<z.baseObjectOutputType<T>, any> extends infer T_1 ? { [k in keyof T_1]: T_1[k]; } : never, z.baseObjectInputType<T> extends infer T_2 ? { [k_1 in keyof T_2]: T_2[k_1]; } : never>;
|
|
80
80
|
getEntitySchema(): z.ZodObject<z.objectUtil.extendShape<T, {
|
|
81
81
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
82
|
-
}> extends infer T_1 extends z.ZodRawShape ? { [k in keyof T_1]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
82
|
+
}> extends infer T_1 extends z.ZodRawShape ? { [k in keyof T_1]: z.ZodOptional<T_1[k]>; } : never, "passthrough", z.ZodTypeAny, z.objectOutputType<z.objectUtil.extendShape<T, {
|
|
83
83
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
84
|
-
}>[k]>; } : never,
|
|
84
|
+
}> extends infer T_2 extends z.ZodRawShape ? { [k in keyof T_2]: z.ZodOptional<T_2[k]>; } : never, z.ZodTypeAny, "passthrough">, z.objectInputType<z.objectUtil.extendShape<T, {
|
|
85
85
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
86
|
-
}> extends infer
|
|
87
|
-
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
88
|
-
}>[k]>; } : never, z.ZodTypeAny, "passthrough">, z.objectInputType<z.objectUtil.extendShape<T, {
|
|
89
|
-
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
90
|
-
}> extends infer T_3 extends z.ZodRawShape ? { [k in keyof T_3]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
91
|
-
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
92
|
-
}>[k]>; } : never, z.ZodTypeAny, "passthrough">>;
|
|
86
|
+
}> extends infer T_3 extends z.ZodRawShape ? { [k in keyof T_3]: z.ZodOptional<T_3[k]>; } : never, z.ZodTypeAny, "passthrough">>;
|
|
93
87
|
getIdSchema(): z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
94
88
|
getUpdateSchema(excludeFields?: ExcludeFromUpdate): z.ZodObject<z.objectUtil.extendShape<T, {
|
|
95
89
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
96
|
-
}> extends infer T_1 extends z.ZodRawShape ? { [k in keyof T_1]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
97
|
-
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
98
|
-
}>[k]>; } : never, "passthrough", z.ZodTypeAny, z.objectOutputType<z.objectUtil.extendShape<T, {
|
|
99
|
-
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
100
|
-
}> extends infer T_2 extends z.ZodRawShape ? { [k in keyof T_2]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
101
|
-
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
102
|
-
}>[k]>; } : never, z.ZodTypeAny, "passthrough">, z.objectInputType<z.objectUtil.extendShape<T, {
|
|
90
|
+
}> extends infer T_1 extends z.ZodRawShape ? { [k in keyof T_1]: z.ZodOptional<T_1[k]>; } : never, "passthrough", z.ZodTypeAny, z.objectOutputType<z.objectUtil.extendShape<T, {
|
|
103
91
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
104
|
-
}> extends infer
|
|
92
|
+
}> extends infer T_2 extends z.ZodRawShape ? { [k in keyof T_2]: z.ZodOptional<T_2[k]>; } : never, z.ZodTypeAny, "passthrough">, z.objectInputType<z.objectUtil.extendShape<T, {
|
|
105
93
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
106
|
-
}>[k]>; } : never, z.ZodTypeAny, "passthrough">> | z.ZodObject<{
|
|
94
|
+
}> extends infer T_3 extends z.ZodRawShape ? { [k in keyof T_3]: z.ZodOptional<T_3[k]>; } : never, z.ZodTypeAny, "passthrough">> | z.ZodObject<{
|
|
107
95
|
[x: string]: z.ZodOptional<z.ZodTypeAny>;
|
|
108
96
|
}, "strict", z.ZodTypeAny, {
|
|
109
97
|
[x: string]: any;
|
|
@@ -126,34 +114,22 @@ export declare class SchemaBuilder<T extends z.ZodRawShape> {
|
|
|
126
114
|
[x: string]: any;
|
|
127
115
|
}>;
|
|
128
116
|
getAllSchemas(excludeFromUpdate?: ExcludeFromUpdate): {
|
|
129
|
-
BaseSchema: z.ZodObject<T, "strict", z.ZodTypeAny, z.objectUtil.addQuestionMarks<z.baseObjectOutputType<T>, any> extends infer T_1 ? { [k in keyof T_1]:
|
|
117
|
+
BaseSchema: z.ZodObject<T, "strict", z.ZodTypeAny, z.objectUtil.addQuestionMarks<z.baseObjectOutputType<T>, any> extends infer T_1 ? { [k in keyof T_1]: T_1[k]; } : never, z.baseObjectInputType<T> extends infer T_2 ? { [k_1 in keyof T_2]: T_2[k_1]; } : never>;
|
|
130
118
|
EntitySchema: z.ZodObject<z.objectUtil.extendShape<T, {
|
|
131
119
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
132
|
-
}> extends infer T_3 extends z.ZodRawShape ? { [k_2 in keyof T_3]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
120
|
+
}> extends infer T_3 extends z.ZodRawShape ? { [k_2 in keyof T_3]: z.ZodOptional<T_3[k_2]>; } : never, "passthrough", z.ZodTypeAny, z.objectOutputType<z.objectUtil.extendShape<T, {
|
|
133
121
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
134
|
-
}>[k_2]>; } : never,
|
|
122
|
+
}> extends infer T_4 extends z.ZodRawShape ? { [k_2 in keyof T_4]: z.ZodOptional<T_4[k_2]>; } : never, z.ZodTypeAny, "passthrough">, z.objectInputType<z.objectUtil.extendShape<T, {
|
|
135
123
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
136
|
-
}> extends infer
|
|
137
|
-
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
138
|
-
}>[k_2]>; } : never, z.ZodTypeAny, "passthrough">, z.objectInputType<z.objectUtil.extendShape<T, {
|
|
139
|
-
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
140
|
-
}> extends infer T_5 extends z.ZodRawShape ? { [k_2 in keyof T_5]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
141
|
-
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
142
|
-
}>[k_2]>; } : never, z.ZodTypeAny, "passthrough">>;
|
|
124
|
+
}> extends infer T_5 extends z.ZodRawShape ? { [k_2 in keyof T_5]: z.ZodOptional<T_5[k_2]>; } : never, z.ZodTypeAny, "passthrough">>;
|
|
143
125
|
IdSchema: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
144
126
|
UpdateSchema: z.ZodObject<z.objectUtil.extendShape<T, {
|
|
145
127
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
146
|
-
}> extends infer T_6 extends z.ZodRawShape ? { [k_2 in keyof T_6]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
147
|
-
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
148
|
-
}>[k_2]>; } : never, "passthrough", z.ZodTypeAny, z.objectOutputType<z.objectUtil.extendShape<T, {
|
|
149
|
-
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
150
|
-
}> extends infer T_7 extends z.ZodRawShape ? { [k_2 in keyof T_7]: z.ZodOptional<z.objectUtil.extendShape<T, {
|
|
151
|
-
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
152
|
-
}>[k_2]>; } : never, z.ZodTypeAny, "passthrough">, z.objectInputType<z.objectUtil.extendShape<T, {
|
|
128
|
+
}> extends infer T_6 extends z.ZodRawShape ? { [k_2 in keyof T_6]: z.ZodOptional<T_6[k_2]>; } : never, "passthrough", z.ZodTypeAny, z.objectOutputType<z.objectUtil.extendShape<T, {
|
|
153
129
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
154
|
-
}> extends infer
|
|
130
|
+
}> extends infer T_7 extends z.ZodRawShape ? { [k_2 in keyof T_7]: z.ZodOptional<T_7[k_2]>; } : never, z.ZodTypeAny, "passthrough">, z.objectInputType<z.objectUtil.extendShape<T, {
|
|
155
131
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>;
|
|
156
|
-
}>[k_2]>; } : never, z.ZodTypeAny, "passthrough">> | z.ZodObject<{
|
|
132
|
+
}> extends infer T_8 extends z.ZodRawShape ? { [k_2 in keyof T_8]: z.ZodOptional<T_8[k_2]>; } : never, z.ZodTypeAny, "passthrough">> | z.ZodObject<{
|
|
157
133
|
[x: string]: z.ZodOptional<z.ZodTypeAny>;
|
|
158
134
|
}, "strict", z.ZodTypeAny, {
|
|
159
135
|
[x: string]: any;
|
|
@@ -16,4 +16,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
__exportStar(require("./common-validation"), exports);
|
|
18
18
|
__exportStar(require("./global-validation"), exports);
|
|
19
|
+
__exportStar(require("./validation-for-frontend"), exports);
|
|
19
20
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"/","sources":["utilities/validation/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,sDAAoC;AACpC,sDAAoC","sourcesContent":["export * from './common-validation';\nexport * from './global-validation';\n"]}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"/","sources":["utilities/validation/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,sDAAoC;AACpC,sDAAoC;AACpC,4DAA0C","sourcesContent":["export * from './common-validation';\nexport * from './global-validation';\nexport * from './validation-for-frontend';\n"]}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { DTO } from './global-validation';
|
|
2
|
+
import { z } from 'zod';
|
|
3
|
+
export declare const UserAddressFrontendSchema: z.ZodObject<{
|
|
4
|
+
addressLabel: z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
|
|
5
|
+
apartment: z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
|
|
6
|
+
buildingName: z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
|
|
7
|
+
deliveryOption: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
8
|
+
instructions: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
9
|
+
}, "strip", z.ZodTypeAny, {
|
|
10
|
+
addressLabel: string;
|
|
11
|
+
apartment: string;
|
|
12
|
+
buildingName: string;
|
|
13
|
+
deliveryOption?: string | undefined;
|
|
14
|
+
instructions?: string | undefined;
|
|
15
|
+
}, {
|
|
16
|
+
addressLabel: string;
|
|
17
|
+
apartment: string;
|
|
18
|
+
buildingName: string;
|
|
19
|
+
deliveryOption?: string | undefined;
|
|
20
|
+
instructions?: string | undefined;
|
|
21
|
+
}>;
|
|
22
|
+
export type UserAddressFrontendDTO = DTO<typeof UserAddressFrontendSchema>;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.UserAddressFrontendSchema = void 0;
|
|
4
|
+
const global_validation_1 = require("./global-validation");
|
|
5
|
+
const zod_1 = require("zod");
|
|
6
|
+
exports.UserAddressFrontendSchema = zod_1.z.object({
|
|
7
|
+
addressLabel: global_validation_1.ZodValidation.string('Address Label', { maxLength: 20 }),
|
|
8
|
+
apartment: global_validation_1.ZodValidation.string('Apt/Suite/Floor', { maxLength: 30 }),
|
|
9
|
+
buildingName: global_validation_1.ZodValidation.string('Building Name', { maxLength: 30 }),
|
|
10
|
+
deliveryOption: global_validation_1.ZodValidation.string('Delivery Option').optional(),
|
|
11
|
+
instructions: global_validation_1.ZodValidation.string('Instructions', { maxLength: 250 }).optional(),
|
|
12
|
+
});
|
|
13
|
+
//# sourceMappingURL=validation-for-frontend.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"validation-for-frontend.js","sourceRoot":"/","sources":["utilities/validation/validation-for-frontend.ts"],"names":[],"mappings":";;;AAAA,2DAAyD;AACzD,6BAAwB;AAEX,QAAA,yBAAyB,GAAG,OAAC,CAAC,MAAM,CAAC;IACjD,YAAY,EAAE,iCAAa,CAAC,MAAM,CAAC,eAAe,EAAE,EAAC,SAAS,EAAE,EAAE,EAAC,CAAC;IACpE,SAAS,EAAE,iCAAa,CAAC,MAAM,CAAC,iBAAiB,EAAE,EAAC,SAAS,EAAE,EAAE,EAAC,CAAC;IACnE,YAAY,EAAE,iCAAa,CAAC,MAAM,CAAC,eAAe,EAAE,EAAC,SAAS,EAAE,EAAE,EAAC,CAAC;IACpE,cAAc,EAAE,iCAAa,CAAC,MAAM,CAAC,iBAAiB,CAAC,CAAC,QAAQ,EAAE;IAClE,YAAY,EAAE,iCAAa,CAAC,MAAM,CAAC,cAAc,EAAE,EAAC,SAAS,EAAE,GAAG,EAAC,CAAC,CAAC,QAAQ,EAAE;CAC/E,CAAC,CAAC","sourcesContent":["import { DTO, ZodValidation } from './global-validation';\nimport { z } from 'zod';\n\nexport const UserAddressFrontendSchema = z.object({\n\taddressLabel: ZodValidation.string('Address Label', {maxLength: 20}),\n\tapartment: ZodValidation.string('Apt/Suite/Floor', {maxLength: 30}),\n\tbuildingName: ZodValidation.string('Building Name', {maxLength: 30}),\n\tdeliveryOption: ZodValidation.string('Delivery Option').optional(),\n\tinstructions: ZodValidation.string('Instructions', {maxLength: 250}).optional(),\n});\nexport type UserAddressFrontendDTO = DTO<typeof UserAddressFrontendSchema>;"]}
|
package/package.json
CHANGED
|
@@ -1,65 +1,65 @@
|
|
|
1
1
|
{
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
2
|
+
"name": "@lyxa.ai/core",
|
|
3
|
+
"version": "1.1.2",
|
|
4
|
+
"description": "The Core system of the Lyxa services.",
|
|
5
|
+
"author": "elie <42282499+Internalizable@users.noreply.github.com>",
|
|
6
|
+
"license": "MIT",
|
|
7
|
+
"files": [
|
|
8
|
+
"dist/**/*"
|
|
9
|
+
],
|
|
10
|
+
"main": "dist/index.js",
|
|
11
|
+
"types": "dist/index.d.ts",
|
|
12
|
+
"scripts": {
|
|
13
|
+
"build": "node build.js",
|
|
14
|
+
"clean": "rimraf dist",
|
|
15
|
+
"start": "npx ts-node src/index.ts",
|
|
16
|
+
"publish:types": "cd dist/types && npm publish",
|
|
17
|
+
"publish:core": "npm publish --ignore-scripts",
|
|
18
|
+
"release": "npm run build && npm run publish:types && npm run publish:core"
|
|
19
|
+
},
|
|
20
|
+
"peerDependencies": {
|
|
21
|
+
"@trpc/client": "^11.4.3",
|
|
22
|
+
"@trpc/server": "^11.4.3"
|
|
23
|
+
},
|
|
24
|
+
"dependencies": {
|
|
25
|
+
"@google-cloud/secret-manager": "^5.6.0",
|
|
26
|
+
"@mapbox/polyline": "^1.2.1",
|
|
27
|
+
"@typegoose/typegoose": "^12.10.1",
|
|
28
|
+
"@types/amqplib": "^0.10.7",
|
|
29
|
+
"@types/node": "^22.10.2",
|
|
30
|
+
"@types/twilio": "^3.19.3",
|
|
31
|
+
"amqplib": "^0.10.5",
|
|
32
|
+
"bcryptjs": "^3.0.2",
|
|
33
|
+
"bullmq": "^5.56.0",
|
|
34
|
+
"dayjs": "^1.11.13",
|
|
35
|
+
"firebase": "^11.1.0",
|
|
36
|
+
"firebase-admin": "^13.0.1",
|
|
37
|
+
"ioredis": "^5.4.1",
|
|
38
|
+
"jsonwebtoken": "^9.0.2",
|
|
39
|
+
"libphonenumber-js": "^1.12.8",
|
|
40
|
+
"mime-types": "^3.0.1",
|
|
41
|
+
"moment": "^2.30.1",
|
|
42
|
+
"mongoose": "^8.13.0",
|
|
43
|
+
"nanoid": "^5.1.5",
|
|
44
|
+
"pino": "9.5.0",
|
|
45
|
+
"pino-mongodb": "4.3.0",
|
|
46
|
+
"pino-pretty": "13.0.0",
|
|
47
|
+
"sharp": "^0.33.5",
|
|
48
|
+
"shortid": "^2.2.16",
|
|
49
|
+
"slugify": "^1.6.6",
|
|
50
|
+
"twilio": "^5.4.0",
|
|
51
|
+
"typedi": "^0.10.0",
|
|
52
|
+
"typescript": "^5.7.2",
|
|
53
|
+
"ws": "^8.18.3",
|
|
54
|
+
"zod": "^3.24.1"
|
|
55
|
+
},
|
|
56
|
+
"devDependencies": {
|
|
57
|
+
"@trpc/client": "^11.4.3",
|
|
58
|
+
"@trpc/server": "^11.4.3",
|
|
59
|
+
"@types/mapbox__polyline": "^1.0.5",
|
|
60
|
+
"@types/mime-types": "^2.1.4",
|
|
61
|
+
"@types/shortid": "^2.2.0",
|
|
62
|
+
"@types/ws": "^8.18.1",
|
|
63
|
+
"prettier": "3.5.3"
|
|
64
|
+
}
|
|
65
65
|
}
|