@opencrvs/toolkit 1.8.0-rc.fd6feaa → 1.8.0-rc.fea3888
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/README.md +1 -1
- package/dist/commons/api/router.d.ts +10466 -13734
- package/dist/commons/conditionals/conditionals.d.ts +31 -5
- package/dist/commons/conditionals/validate.d.ts +12 -17
- package/dist/commons/events/ActionConfig.d.ts +85746 -1981
- package/dist/commons/events/ActionDocument.d.ts +8433 -503
- package/dist/commons/events/ActionInput.d.ts +3229 -704
- package/dist/commons/events/ActionType.d.ts +26 -11
- package/dist/commons/events/AdvancedSearchConfig.d.ts +371 -25
- package/dist/commons/events/CompositeFieldValue.d.ts +55 -12
- package/dist/commons/events/Conditional.d.ts +21 -5
- package/dist/commons/events/Draft.d.ts +174 -72
- package/dist/commons/events/EventConfig.d.ts +40845 -1776
- package/dist/commons/events/EventConfigInput.d.ts +6 -3
- package/dist/commons/events/EventDocument.d.ts +1897 -619
- package/dist/commons/events/EventIndex.d.ts +921 -7
- package/dist/commons/events/EventInput.d.ts +13 -0
- package/dist/commons/events/EventMetadata.d.ts +16 -3
- package/dist/commons/events/FieldConfig.d.ts +3911 -759
- package/dist/commons/events/FieldType.d.ts +2 -1
- package/dist/commons/events/FieldTypeMapping.d.ts +57 -8
- package/dist/commons/events/FieldValue.d.ts +31 -11
- package/dist/commons/events/FormConfig.d.ts +38982 -69
- package/dist/commons/events/PageConfig.d.ts +9803 -0
- package/dist/commons/events/SummaryConfig.d.ts +81 -42
- package/dist/commons/events/TemplateConfig.d.ts +5 -5
- package/dist/commons/events/User.d.ts +5 -0
- package/dist/commons/events/WorkqueueConfig.d.ts +44 -20
- package/dist/commons/events/defineConfig.d.ts +6749 -224
- package/dist/commons/events/event.d.ts +25 -0
- package/dist/commons/events/field.d.ts +68 -0
- package/dist/commons/events/index.d.ts +5 -1
- package/dist/commons/events/scopes.d.ts +26 -0
- package/dist/commons/events/test.utils.d.ts +84 -302
- package/dist/commons/events/utils.d.ts +3444 -118
- package/dist/commons/events/utils.test.d.ts +2 -0
- package/dist/conditionals/index.js +196 -108
- package/dist/events/index.js +1984 -1136
- package/package.json +3 -2
@@ -21,8 +21,9 @@ export declare const FieldType: {
|
|
21
21
|
readonly FACILITY: "FACILITY";
|
22
22
|
readonly OFFICE: "OFFICE";
|
23
23
|
readonly SIGNATURE: "SIGNATURE";
|
24
|
+
readonly DATA: "DATA";
|
24
25
|
};
|
25
|
-
export declare const fieldTypes: ("ADDRESS" | "TEXT" | "NUMBER" | "TEXTAREA" | "EMAIL" | "DATE" | "PARAGRAPH" | "PAGE_HEADER" | "RADIO_GROUP" | "FILE" | "FILE_WITH_OPTIONS" | "HIDDEN" | "BULLET_LIST" | "CHECKBOX" | "SELECT" | "COUNTRY" | "LOCATION" | "DIVIDER" | "ADMINISTRATIVE_AREA" | "FACILITY" | "OFFICE" | "SIGNATURE")[];
|
26
|
+
export declare const fieldTypes: ("ADDRESS" | "TEXT" | "NUMBER" | "TEXTAREA" | "EMAIL" | "DATE" | "PARAGRAPH" | "PAGE_HEADER" | "RADIO_GROUP" | "FILE" | "FILE_WITH_OPTIONS" | "HIDDEN" | "BULLET_LIST" | "CHECKBOX" | "SELECT" | "COUNTRY" | "LOCATION" | "DIVIDER" | "ADMINISTRATIVE_AREA" | "FACILITY" | "OFFICE" | "SIGNATURE" | "DATA")[];
|
26
27
|
export type FieldType = (typeof fieldTypes)[number];
|
27
28
|
/**
|
28
29
|
* Composite field types are field types that consist of multiple field values.
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { z } from 'zod';
|
2
|
-
import { AddressField, AdministrativeArea, BulletList, Checkbox, Country, DateField, Divider, Facility, EmailField, FieldConfig, File, FileUploadWithOptions, Location, Office, PageHeader, Paragraph, RadioGroup, SelectField, SignatureField, TextAreaField, TextField, NumberField } from './FieldConfig';
|
2
|
+
import { AddressField, AdministrativeArea, BulletList, Checkbox, Country, DateField, Divider, Facility, EmailField, FieldConfig, File, FileUploadWithOptions, Location, Office, PageHeader, Paragraph, RadioGroup, SelectField, SignatureField, TextAreaField, TextField, NumberField, DataField } from './FieldConfig';
|
3
3
|
import { FieldType } from './FieldType';
|
4
4
|
import { FieldValue, FieldUpdateValueSchema } from './FieldValue';
|
5
5
|
import { AddressFieldValue, FileFieldValue, FileFieldWithOptionValue } from './CompositeFieldValue';
|
@@ -43,7 +43,8 @@ export declare function mapFieldTypeToZod(type: FieldType, required?: boolean):
|
|
43
43
|
filename: string;
|
44
44
|
originalFilename: string;
|
45
45
|
}>>> | z.ZodUnion<[z.ZodDiscriminatedUnion<"urbanOrRural", [z.ZodObject<z.objectUtil.extendShape<{
|
46
|
-
country: z.
|
46
|
+
country: z.ZodString;
|
47
|
+
addressType: z.ZodLiteral<"DOMESTIC">;
|
47
48
|
province: z.ZodString;
|
48
49
|
district: z.ZodString;
|
49
50
|
}, {
|
@@ -56,6 +57,7 @@ export declare function mapFieldTypeToZod(type: FieldType, required?: boolean):
|
|
56
57
|
}>, "strip", z.ZodTypeAny, {
|
57
58
|
country: string;
|
58
59
|
district: string;
|
60
|
+
addressType: "DOMESTIC";
|
59
61
|
province: string;
|
60
62
|
urbanOrRural: "URBAN";
|
61
63
|
number?: string | null | undefined;
|
@@ -66,6 +68,7 @@ export declare function mapFieldTypeToZod(type: FieldType, required?: boolean):
|
|
66
68
|
}, {
|
67
69
|
country: string;
|
68
70
|
district: string;
|
71
|
+
addressType: "DOMESTIC";
|
69
72
|
province: string;
|
70
73
|
urbanOrRural: "URBAN";
|
71
74
|
number?: string | null | undefined;
|
@@ -74,7 +77,8 @@ export declare function mapFieldTypeToZod(type: FieldType, required?: boolean):
|
|
74
77
|
street?: string | null | undefined;
|
75
78
|
zipCode?: string | null | undefined;
|
76
79
|
}>, z.ZodObject<z.objectUtil.extendShape<{
|
77
|
-
country: z.
|
80
|
+
country: z.ZodString;
|
81
|
+
addressType: z.ZodLiteral<"DOMESTIC">;
|
78
82
|
province: z.ZodString;
|
79
83
|
district: z.ZodString;
|
80
84
|
}, {
|
@@ -83,17 +87,20 @@ export declare function mapFieldTypeToZod(type: FieldType, required?: boolean):
|
|
83
87
|
}>, "strip", z.ZodTypeAny, {
|
84
88
|
country: string;
|
85
89
|
district: string;
|
90
|
+
addressType: "DOMESTIC";
|
86
91
|
province: string;
|
87
92
|
urbanOrRural: "RURAL";
|
88
93
|
village?: string | null | undefined;
|
89
94
|
}, {
|
90
95
|
country: string;
|
91
96
|
district: string;
|
97
|
+
addressType: "DOMESTIC";
|
92
98
|
province: string;
|
93
99
|
urbanOrRural: "RURAL";
|
94
100
|
village?: string | null | undefined;
|
95
101
|
}>]>, z.ZodObject<{
|
96
|
-
country: z.
|
102
|
+
country: z.ZodString;
|
103
|
+
addressType: z.ZodLiteral<"INTERNATIONAL">;
|
97
104
|
state: z.ZodString;
|
98
105
|
district2: z.ZodString;
|
99
106
|
cityOrTown: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
@@ -104,6 +111,7 @@ export declare function mapFieldTypeToZod(type: FieldType, required?: boolean):
|
|
104
111
|
}, "strip", z.ZodTypeAny, {
|
105
112
|
country: string;
|
106
113
|
state: string;
|
114
|
+
addressType: "INTERNATIONAL";
|
107
115
|
district2: string;
|
108
116
|
cityOrTown?: string | null | undefined;
|
109
117
|
addressLine1?: string | null | undefined;
|
@@ -113,6 +121,7 @@ export declare function mapFieldTypeToZod(type: FieldType, required?: boolean):
|
|
113
121
|
}, {
|
114
122
|
country: string;
|
115
123
|
state: string;
|
124
|
+
addressType: "INTERNATIONAL";
|
116
125
|
district2: string;
|
117
126
|
cityOrTown?: string | null | undefined;
|
118
127
|
addressLine1?: string | null | undefined;
|
@@ -149,8 +158,9 @@ export declare function mapFieldTypeToZod(type: FieldType, required?: boolean):
|
|
149
158
|
option: string;
|
150
159
|
filename: string;
|
151
160
|
originalFilename: string;
|
152
|
-
}>, "many">>> | z.ZodBoolean | z.ZodOptional<z.ZodNullable<z.ZodBoolean>> | z.ZodNumber | z.ZodOptional<z.ZodNullable<z.ZodNumber>> | z.ZodOptional<z.ZodNullable<z.ZodUnion<[z.ZodDiscriminatedUnion<"urbanOrRural", [z.ZodObject<z.objectUtil.extendShape<{
|
153
|
-
country: z.
|
161
|
+
}>, "many">>> | z.ZodBoolean | z.ZodOptional<z.ZodNullable<z.ZodBoolean>> | z.ZodNumber | z.ZodOptional<z.ZodNullable<z.ZodNumber>> | z.ZodUndefined | z.ZodOptional<z.ZodNullable<z.ZodUndefined>> | z.ZodOptional<z.ZodNullable<z.ZodUnion<[z.ZodDiscriminatedUnion<"urbanOrRural", [z.ZodObject<z.objectUtil.extendShape<{
|
162
|
+
country: z.ZodString;
|
163
|
+
addressType: z.ZodLiteral<"DOMESTIC">;
|
154
164
|
province: z.ZodString;
|
155
165
|
district: z.ZodString;
|
156
166
|
}, {
|
@@ -163,6 +173,7 @@ export declare function mapFieldTypeToZod(type: FieldType, required?: boolean):
|
|
163
173
|
}>, "strip", z.ZodTypeAny, {
|
164
174
|
country: string;
|
165
175
|
district: string;
|
176
|
+
addressType: "DOMESTIC";
|
166
177
|
province: string;
|
167
178
|
urbanOrRural: "URBAN";
|
168
179
|
number?: string | null | undefined;
|
@@ -173,6 +184,7 @@ export declare function mapFieldTypeToZod(type: FieldType, required?: boolean):
|
|
173
184
|
}, {
|
174
185
|
country: string;
|
175
186
|
district: string;
|
187
|
+
addressType: "DOMESTIC";
|
176
188
|
province: string;
|
177
189
|
urbanOrRural: "URBAN";
|
178
190
|
number?: string | null | undefined;
|
@@ -181,7 +193,8 @@ export declare function mapFieldTypeToZod(type: FieldType, required?: boolean):
|
|
181
193
|
street?: string | null | undefined;
|
182
194
|
zipCode?: string | null | undefined;
|
183
195
|
}>, z.ZodObject<z.objectUtil.extendShape<{
|
184
|
-
country: z.
|
196
|
+
country: z.ZodString;
|
197
|
+
addressType: z.ZodLiteral<"DOMESTIC">;
|
185
198
|
province: z.ZodString;
|
186
199
|
district: z.ZodString;
|
187
200
|
}, {
|
@@ -190,17 +203,20 @@ export declare function mapFieldTypeToZod(type: FieldType, required?: boolean):
|
|
190
203
|
}>, "strip", z.ZodTypeAny, {
|
191
204
|
country: string;
|
192
205
|
district: string;
|
206
|
+
addressType: "DOMESTIC";
|
193
207
|
province: string;
|
194
208
|
urbanOrRural: "RURAL";
|
195
209
|
village?: string | null | undefined;
|
196
210
|
}, {
|
197
211
|
country: string;
|
198
212
|
district: string;
|
213
|
+
addressType: "DOMESTIC";
|
199
214
|
province: string;
|
200
215
|
urbanOrRural: "RURAL";
|
201
216
|
village?: string | null | undefined;
|
202
217
|
}>]>, z.ZodObject<{
|
203
|
-
country: z.
|
218
|
+
country: z.ZodString;
|
219
|
+
addressType: z.ZodLiteral<"INTERNATIONAL">;
|
204
220
|
state: z.ZodString;
|
205
221
|
district2: z.ZodString;
|
206
222
|
cityOrTown: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
@@ -211,6 +227,7 @@ export declare function mapFieldTypeToZod(type: FieldType, required?: boolean):
|
|
211
227
|
}, "strip", z.ZodTypeAny, {
|
212
228
|
country: string;
|
213
229
|
state: string;
|
230
|
+
addressType: "INTERNATIONAL";
|
214
231
|
district2: string;
|
215
232
|
cityOrTown?: string | null | undefined;
|
216
233
|
addressLine1?: string | null | undefined;
|
@@ -220,6 +237,7 @@ export declare function mapFieldTypeToZod(type: FieldType, required?: boolean):
|
|
220
237
|
}, {
|
221
238
|
country: string;
|
222
239
|
state: string;
|
240
|
+
addressType: "INTERNATIONAL";
|
223
241
|
district2: string;
|
224
242
|
cityOrTown?: string | null | undefined;
|
225
243
|
addressLine1?: string | null | undefined;
|
@@ -235,6 +253,7 @@ export declare function createValidationSchema(config: FieldConfig[]): z.ZodObje
|
|
235
253
|
} | {
|
236
254
|
country: string;
|
237
255
|
district: string;
|
256
|
+
addressType: "DOMESTIC";
|
238
257
|
province: string;
|
239
258
|
urbanOrRural: "URBAN";
|
240
259
|
number?: string | null | undefined;
|
@@ -245,12 +264,14 @@ export declare function createValidationSchema(config: FieldConfig[]): z.ZodObje
|
|
245
264
|
} | {
|
246
265
|
country: string;
|
247
266
|
district: string;
|
267
|
+
addressType: "DOMESTIC";
|
248
268
|
province: string;
|
249
269
|
urbanOrRural: "RURAL";
|
250
270
|
village?: string | null | undefined;
|
251
271
|
} | {
|
252
272
|
country: string;
|
253
273
|
state: string;
|
274
|
+
addressType: "INTERNATIONAL";
|
254
275
|
district2: string;
|
255
276
|
cityOrTown?: string | null | undefined;
|
256
277
|
addressLine1?: string | null | undefined;
|
@@ -271,6 +292,7 @@ export declare function createValidationSchema(config: FieldConfig[]): z.ZodObje
|
|
271
292
|
} | {
|
272
293
|
country: string;
|
273
294
|
district: string;
|
295
|
+
addressType: "DOMESTIC";
|
274
296
|
province: string;
|
275
297
|
urbanOrRural: "URBAN";
|
276
298
|
number?: string | null | undefined;
|
@@ -281,12 +303,14 @@ export declare function createValidationSchema(config: FieldConfig[]): z.ZodObje
|
|
281
303
|
} | {
|
282
304
|
country: string;
|
283
305
|
district: string;
|
306
|
+
addressType: "DOMESTIC";
|
284
307
|
province: string;
|
285
308
|
urbanOrRural: "RURAL";
|
286
309
|
village?: string | null | undefined;
|
287
310
|
} | {
|
288
311
|
country: string;
|
289
312
|
state: string;
|
313
|
+
addressType: "INTERNATIONAL";
|
290
314
|
district2: string;
|
291
315
|
cityOrTown?: string | null | undefined;
|
292
316
|
addressLine1?: string | null | undefined;
|
@@ -305,6 +329,7 @@ export declare function createValidationSchema(config: FieldConfig[]): z.ZodObje
|
|
305
329
|
*/
|
306
330
|
export declare function mapFieldTypeToMockValue(field: FieldConfig, i: number): string | true | 19 | {
|
307
331
|
country: string;
|
332
|
+
addressType: "DOMESTIC";
|
308
333
|
province: string;
|
309
334
|
district: string;
|
310
335
|
urbanOrRural: string;
|
@@ -321,6 +346,7 @@ export declare function mapFieldTypeToMockValue(field: FieldConfig, i: number):
|
|
321
346
|
originalFilename: string;
|
322
347
|
type: string;
|
323
348
|
country?: undefined;
|
349
|
+
addressType?: undefined;
|
324
350
|
province?: undefined;
|
325
351
|
district?: undefined;
|
326
352
|
urbanOrRural?: undefined;
|
@@ -329,12 +355,27 @@ export declare function mapFieldTypeToMockValue(field: FieldConfig, i: number):
|
|
329
355
|
street?: undefined;
|
330
356
|
number?: undefined;
|
331
357
|
zipCode?: undefined;
|
358
|
+
} | {
|
359
|
+
country?: undefined;
|
360
|
+
addressType?: undefined;
|
361
|
+
province?: undefined;
|
362
|
+
district?: undefined;
|
363
|
+
urbanOrRural?: undefined;
|
364
|
+
town?: undefined;
|
365
|
+
residentialArea?: undefined;
|
366
|
+
street?: undefined;
|
367
|
+
number?: undefined;
|
368
|
+
zipCode?: undefined;
|
369
|
+
filename?: undefined;
|
370
|
+
originalFilename?: undefined;
|
371
|
+
type?: undefined;
|
332
372
|
} | null;
|
333
373
|
/**
|
334
374
|
* Maps complex or nested field types, such as Address fields, to their corresponding empty values.
|
335
375
|
*/
|
336
376
|
export declare function mapFieldTypeToEmptyValue(field: FieldConfig): never[] | {
|
337
377
|
country: null;
|
378
|
+
addressType: "DOMESTIC";
|
338
379
|
province: null;
|
339
380
|
district: null;
|
340
381
|
urbanOrRural: string;
|
@@ -351,6 +392,7 @@ export declare function mapFieldTypeToEmptyValue(field: FieldConfig): never[] |
|
|
351
392
|
originalFilename: string;
|
352
393
|
type: string;
|
353
394
|
country?: undefined;
|
395
|
+
addressType?: undefined;
|
354
396
|
province?: undefined;
|
355
397
|
district?: undefined;
|
356
398
|
urbanOrRural?: undefined;
|
@@ -507,5 +549,12 @@ export declare const isOfficeFieldType: (field: {
|
|
507
549
|
value: string;
|
508
550
|
config: Office;
|
509
551
|
};
|
552
|
+
export declare const isDataFieldType: (field: {
|
553
|
+
config: FieldConfig;
|
554
|
+
value: FieldValue;
|
555
|
+
}) => field is {
|
556
|
+
value: undefined;
|
557
|
+
config: DataField;
|
558
|
+
};
|
510
559
|
export {};
|
511
560
|
//# sourceMappingURL=FieldTypeMapping.d.ts.map
|
@@ -13,13 +13,15 @@ import { AddressFieldValue, AddressFieldUpdateValue, FileFieldValue, FileFieldWi
|
|
13
13
|
*
|
14
14
|
*/
|
15
15
|
export declare const TextValue: z.ZodString;
|
16
|
-
export declare const
|
16
|
+
export declare const NonEmptyTextValue: z.ZodString;
|
17
17
|
export declare const DateValue: z.ZodString;
|
18
18
|
export declare const EmailValue: z.ZodString;
|
19
19
|
export declare const CheckboxFieldValue: z.ZodBoolean;
|
20
20
|
export type CheckboxFieldValue = z.infer<typeof CheckboxFieldValue>;
|
21
21
|
export declare const NumberFieldValue: z.ZodNumber;
|
22
22
|
export type NumberFieldValue = z.infer<typeof NumberFieldValue>;
|
23
|
+
export declare const DataFieldValue: z.ZodUndefined;
|
24
|
+
export type DataFieldValue = z.infer<typeof DataFieldValue>;
|
23
25
|
export declare const FieldValue: z.ZodUnion<[z.ZodString, z.ZodString, z.ZodBoolean, z.ZodNumber, z.ZodObject<{
|
24
26
|
filename: z.ZodString;
|
25
27
|
originalFilename: z.ZodString;
|
@@ -48,7 +50,8 @@ export declare const FieldValue: z.ZodUnion<[z.ZodString, z.ZodString, z.ZodBool
|
|
48
50
|
filename: string;
|
49
51
|
originalFilename: string;
|
50
52
|
}>, "many">, z.ZodObject<z.objectUtil.extendShape<{
|
51
|
-
country: z.
|
53
|
+
country: z.ZodString;
|
54
|
+
addressType: z.ZodLiteral<"DOMESTIC">;
|
52
55
|
province: z.ZodString;
|
53
56
|
district: z.ZodString;
|
54
57
|
}, {
|
@@ -61,6 +64,7 @@ export declare const FieldValue: z.ZodUnion<[z.ZodString, z.ZodString, z.ZodBool
|
|
61
64
|
}>, "strip", z.ZodTypeAny, {
|
62
65
|
country: string;
|
63
66
|
district: string;
|
67
|
+
addressType: "DOMESTIC";
|
64
68
|
province: string;
|
65
69
|
urbanOrRural: "URBAN";
|
66
70
|
number?: string | undefined;
|
@@ -71,6 +75,7 @@ export declare const FieldValue: z.ZodUnion<[z.ZodString, z.ZodString, z.ZodBool
|
|
71
75
|
}, {
|
72
76
|
country: string;
|
73
77
|
district: string;
|
78
|
+
addressType: "DOMESTIC";
|
74
79
|
province: string;
|
75
80
|
urbanOrRural: "URBAN";
|
76
81
|
number?: string | undefined;
|
@@ -79,7 +84,8 @@ export declare const FieldValue: z.ZodUnion<[z.ZodString, z.ZodString, z.ZodBool
|
|
79
84
|
street?: string | undefined;
|
80
85
|
zipCode?: string | undefined;
|
81
86
|
}>, z.ZodObject<z.objectUtil.extendShape<{
|
82
|
-
country: z.
|
87
|
+
country: z.ZodString;
|
88
|
+
addressType: z.ZodLiteral<"DOMESTIC">;
|
83
89
|
province: z.ZodString;
|
84
90
|
district: z.ZodString;
|
85
91
|
}, {
|
@@ -88,17 +94,20 @@ export declare const FieldValue: z.ZodUnion<[z.ZodString, z.ZodString, z.ZodBool
|
|
88
94
|
}>, "strip", z.ZodTypeAny, {
|
89
95
|
country: string;
|
90
96
|
district: string;
|
97
|
+
addressType: "DOMESTIC";
|
91
98
|
province: string;
|
92
99
|
urbanOrRural: "RURAL";
|
93
100
|
village?: string | undefined;
|
94
101
|
}, {
|
95
102
|
country: string;
|
96
103
|
district: string;
|
104
|
+
addressType: "DOMESTIC";
|
97
105
|
province: string;
|
98
106
|
urbanOrRural: "RURAL";
|
99
107
|
village?: string | undefined;
|
100
|
-
}>, z.ZodObject<{
|
101
|
-
country: z.
|
108
|
+
}>, z.ZodUndefined, z.ZodObject<{
|
109
|
+
country: z.ZodString;
|
110
|
+
addressType: z.ZodLiteral<"INTERNATIONAL">;
|
102
111
|
state: z.ZodString;
|
103
112
|
district2: z.ZodString;
|
104
113
|
cityOrTown: z.ZodOptional<z.ZodString>;
|
@@ -109,6 +118,7 @@ export declare const FieldValue: z.ZodUnion<[z.ZodString, z.ZodString, z.ZodBool
|
|
109
118
|
}, "strip", z.ZodTypeAny, {
|
110
119
|
country: string;
|
111
120
|
state: string;
|
121
|
+
addressType: "INTERNATIONAL";
|
112
122
|
district2: string;
|
113
123
|
cityOrTown?: string | undefined;
|
114
124
|
addressLine1?: string | undefined;
|
@@ -118,6 +128,7 @@ export declare const FieldValue: z.ZodUnion<[z.ZodString, z.ZodString, z.ZodBool
|
|
118
128
|
}, {
|
119
129
|
country: string;
|
120
130
|
state: string;
|
131
|
+
addressType: "INTERNATIONAL";
|
121
132
|
district2: string;
|
122
133
|
cityOrTown?: string | undefined;
|
123
134
|
addressLine1?: string | undefined;
|
@@ -154,7 +165,8 @@ export declare const FieldUpdateValue: z.ZodUnion<[z.ZodString, z.ZodString, z.Z
|
|
154
165
|
filename: string;
|
155
166
|
originalFilename: string;
|
156
167
|
}>, "many">, z.ZodObject<z.objectUtil.extendShape<{
|
157
|
-
country: z.
|
168
|
+
country: z.ZodString;
|
169
|
+
addressType: z.ZodLiteral<"DOMESTIC">;
|
158
170
|
province: z.ZodString;
|
159
171
|
district: z.ZodString;
|
160
172
|
}, {
|
@@ -167,6 +179,7 @@ export declare const FieldUpdateValue: z.ZodUnion<[z.ZodString, z.ZodString, z.Z
|
|
167
179
|
}>, "strip", z.ZodTypeAny, {
|
168
180
|
country: string;
|
169
181
|
district: string;
|
182
|
+
addressType: "DOMESTIC";
|
170
183
|
province: string;
|
171
184
|
urbanOrRural: "URBAN";
|
172
185
|
number?: string | null | undefined;
|
@@ -177,6 +190,7 @@ export declare const FieldUpdateValue: z.ZodUnion<[z.ZodString, z.ZodString, z.Z
|
|
177
190
|
}, {
|
178
191
|
country: string;
|
179
192
|
district: string;
|
193
|
+
addressType: "DOMESTIC";
|
180
194
|
province: string;
|
181
195
|
urbanOrRural: "URBAN";
|
182
196
|
number?: string | null | undefined;
|
@@ -185,7 +199,8 @@ export declare const FieldUpdateValue: z.ZodUnion<[z.ZodString, z.ZodString, z.Z
|
|
185
199
|
street?: string | null | undefined;
|
186
200
|
zipCode?: string | null | undefined;
|
187
201
|
}>, z.ZodObject<z.objectUtil.extendShape<{
|
188
|
-
country: z.
|
202
|
+
country: z.ZodString;
|
203
|
+
addressType: z.ZodLiteral<"DOMESTIC">;
|
189
204
|
province: z.ZodString;
|
190
205
|
district: z.ZodString;
|
191
206
|
}, {
|
@@ -194,17 +209,20 @@ export declare const FieldUpdateValue: z.ZodUnion<[z.ZodString, z.ZodString, z.Z
|
|
194
209
|
}>, "strip", z.ZodTypeAny, {
|
195
210
|
country: string;
|
196
211
|
district: string;
|
212
|
+
addressType: "DOMESTIC";
|
197
213
|
province: string;
|
198
214
|
urbanOrRural: "RURAL";
|
199
215
|
village?: string | null | undefined;
|
200
216
|
}, {
|
201
217
|
country: string;
|
202
218
|
district: string;
|
219
|
+
addressType: "DOMESTIC";
|
203
220
|
province: string;
|
204
221
|
urbanOrRural: "RURAL";
|
205
222
|
village?: string | null | undefined;
|
206
|
-
}>, z.ZodObject<{
|
207
|
-
country: z.
|
223
|
+
}>, z.ZodUndefined, z.ZodObject<{
|
224
|
+
country: z.ZodString;
|
225
|
+
addressType: z.ZodLiteral<"INTERNATIONAL">;
|
208
226
|
state: z.ZodString;
|
209
227
|
district2: z.ZodString;
|
210
228
|
cityOrTown: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
@@ -215,6 +233,7 @@ export declare const FieldUpdateValue: z.ZodUnion<[z.ZodString, z.ZodString, z.Z
|
|
215
233
|
}, "strip", z.ZodTypeAny, {
|
216
234
|
country: string;
|
217
235
|
state: string;
|
236
|
+
addressType: "INTERNATIONAL";
|
218
237
|
district2: string;
|
219
238
|
cityOrTown?: string | null | undefined;
|
220
239
|
addressLine1?: string | null | undefined;
|
@@ -224,6 +243,7 @@ export declare const FieldUpdateValue: z.ZodUnion<[z.ZodString, z.ZodString, z.Z
|
|
224
243
|
}, {
|
225
244
|
country: string;
|
226
245
|
state: string;
|
246
|
+
addressType: "INTERNATIONAL";
|
227
247
|
district2: string;
|
228
248
|
cityOrTown?: string | null | undefined;
|
229
249
|
addressLine1?: string | null | undefined;
|
@@ -235,11 +255,11 @@ export type FieldUpdateValue = z.infer<typeof FieldUpdateValue>;
|
|
235
255
|
/**
|
236
256
|
* NOTE: This is an exception. We need schema as a type in order to generate schema dynamically.
|
237
257
|
* */
|
238
|
-
export type FieldValueSchema = typeof FileFieldValue | typeof FileFieldWithOptionValue | typeof CheckboxFieldValue | typeof AddressFieldValue | typeof NumberFieldValue | z.ZodString | z.ZodBoolean;
|
258
|
+
export type FieldValueSchema = typeof FileFieldValue | typeof FileFieldWithOptionValue | typeof CheckboxFieldValue | typeof AddressFieldValue | typeof NumberFieldValue | typeof DataFieldValue | z.ZodString | z.ZodBoolean;
|
239
259
|
/**
|
240
260
|
* NOTE: This is an exception. We need schema as a type in order to generate schema dynamically.
|
241
261
|
*
|
242
262
|
* FieldValueInputSchema uses Input types which have set optional values as nullish
|
243
263
|
* */
|
244
|
-
export type FieldUpdateValueSchema = typeof FileFieldValue | typeof FileFieldWithOptionValue | typeof CheckboxFieldValue | typeof AddressFieldUpdateValue | typeof NumberFieldValue | z.ZodString | z.ZodBoolean;
|
264
|
+
export type FieldUpdateValueSchema = typeof FileFieldValue | typeof FileFieldWithOptionValue | typeof CheckboxFieldValue | typeof AddressFieldUpdateValue | typeof NumberFieldValue | typeof DataFieldValue | z.ZodString | z.ZodBoolean;
|
245
265
|
//# sourceMappingURL=FieldValue.d.ts.map
|