@opencrvs/toolkit 1.8.0-rc.fa72fdf → 1.8.0-rc.faacbde

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.
@@ -20,14 +20,14 @@ export declare const EventIndex: z.ZodObject<z.objectUtil.extendShape<{
20
20
  updatedBy: z.ZodString;
21
21
  trackingId: z.ZodString;
22
22
  }, {
23
- data: z.ZodRecord<z.ZodString, z.ZodAny>;
23
+ declaration: z.ZodRecord<z.ZodString, z.ZodAny>;
24
24
  }>, "strip", z.ZodTypeAny, {
25
25
  type: string;
26
26
  id: string;
27
27
  status: "ARCHIVED" | "CERTIFIED" | "DECLARED" | "REGISTERED" | "REJECTED" | "VALIDATED" | "CREATED" | "NOTIFIED";
28
- data: Record<string, any>;
29
28
  createdAt: string;
30
29
  createdBy: string;
30
+ declaration: Record<string, any>;
31
31
  createdAtLocation: string;
32
32
  trackingId: string;
33
33
  modifiedAt: string;
@@ -37,9 +37,9 @@ export declare const EventIndex: z.ZodObject<z.objectUtil.extendShape<{
37
37
  type: string;
38
38
  id: string;
39
39
  status: "ARCHIVED" | "CERTIFIED" | "DECLARED" | "REGISTERED" | "REJECTED" | "VALIDATED" | "CREATED" | "NOTIFIED";
40
- data: Record<string, any>;
41
40
  createdAt: string;
42
41
  createdBy: string;
42
+ declaration: Record<string, any>;
43
43
  createdAtLocation: string;
44
44
  trackingId: string;
45
45
  modifiedAt: string;
@@ -747,6 +747,9 @@ declare const TextAreaField: z.ZodObject<z.objectUtil.extendShape<{
747
747
  } | undefined;
748
748
  }>;
749
749
  export type TextAreaField = z.infer<typeof TextAreaField>;
750
+ export declare const ImageMimeType: z.ZodEnum<["image/png", "image/jpg", "image/jpeg", "image/svg+xml"]>;
751
+ export declare const MimeType: z.ZodEnum<["image/png", "image/jpg", "image/jpeg", "image/svg+xml"]>;
752
+ export type MimeType = z.infer<typeof MimeType>;
750
753
  declare const SignatureField: z.ZodObject<z.objectUtil.extendShape<{
751
754
  id: z.ZodString;
752
755
  defaultValue: z.ZodOptional<z.ZodUnion<[z.ZodUnion<[z.ZodString, z.ZodString, z.ZodString, z.ZodNumber, z.ZodBoolean]>, z.ZodObject<{
@@ -800,20 +803,24 @@ declare const SignatureField: z.ZodObject<z.objectUtil.extendShape<{
800
803
  description: string;
801
804
  defaultMessage: string;
802
805
  }>;
803
- configuration: z.ZodOptional<z.ZodDefault<z.ZodObject<{
804
- maxSizeMb: z.ZodOptional<z.ZodNumber>;
805
- allowedFileFormats: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
806
+ configuration: z.ZodDefault<z.ZodObject<{
807
+ maxFileSize: z.ZodDefault<z.ZodNumber>;
808
+ acceptedFileTypes: z.ZodOptional<z.ZodArray<z.ZodEnum<["image/png", "image/jpg", "image/jpeg", "image/svg+xml"]>, "many">>;
806
809
  }, "strip", z.ZodTypeAny, {
807
- maxSizeMb?: number | undefined;
808
- allowedFileFormats?: string[] | undefined;
810
+ maxFileSize: number;
811
+ acceptedFileTypes?: ("image/png" | "image/jpg" | "image/jpeg" | "image/svg+xml")[] | undefined;
809
812
  }, {
810
- maxSizeMb?: number | undefined;
811
- allowedFileFormats?: string[] | undefined;
812
- }>>>;
813
+ maxFileSize?: number | undefined;
814
+ acceptedFileTypes?: ("image/png" | "image/jpg" | "image/jpeg" | "image/svg+xml")[] | undefined;
815
+ }>>;
813
816
  }>, "strip", z.ZodTypeAny, {
814
817
  type: "SIGNATURE";
815
818
  id: string;
816
819
  label: TranslationConfig;
820
+ configuration: {
821
+ maxFileSize: number;
822
+ acceptedFileTypes?: ("image/png" | "image/jpg" | "image/jpeg" | "image/svg+xml")[] | undefined;
823
+ };
817
824
  signaturePromptLabel: TranslationConfig;
818
825
  validation?: {
819
826
  message: TranslationConfig;
@@ -836,10 +843,6 @@ declare const SignatureField: z.ZodObject<z.objectUtil.extendShape<{
836
843
  hidden?: boolean | undefined;
837
844
  placeholder?: TranslationConfig | undefined;
838
845
  hideLabel?: boolean | undefined;
839
- configuration?: {
840
- maxSizeMb?: number | undefined;
841
- allowedFileFormats?: string[] | undefined;
842
- } | undefined;
843
846
  }, {
844
847
  type: "SIGNATURE";
845
848
  id: string;
@@ -883,8 +886,8 @@ declare const SignatureField: z.ZodObject<z.objectUtil.extendShape<{
883
886
  } | undefined;
884
887
  hideLabel?: boolean | undefined;
885
888
  configuration?: {
886
- maxSizeMb?: number | undefined;
887
- allowedFileFormats?: string[] | undefined;
889
+ maxFileSize?: number | undefined;
890
+ acceptedFileTypes?: ("image/png" | "image/jpg" | "image/jpeg" | "image/svg+xml")[] | undefined;
888
891
  } | undefined;
889
892
  }>;
890
893
  export type SignatureField = z.infer<typeof SignatureField>;
@@ -1491,32 +1494,40 @@ declare const File: z.ZodObject<z.objectUtil.extendShape<{
1491
1494
  hideLabel: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
1492
1495
  }, {
1493
1496
  type: z.ZodLiteral<"FILE">;
1494
- options: z.ZodOptional<z.ZodObject<{
1495
- style: z.ZodObject<{
1496
- fullWidth: z.ZodBoolean;
1497
+ configuration: z.ZodDefault<z.ZodObject<{
1498
+ maxFileSize: z.ZodDefault<z.ZodNumber>;
1499
+ acceptedFileTypes: z.ZodOptional<z.ZodArray<z.ZodEnum<["image/png", "image/jpg", "image/jpeg", "image/svg+xml"]>, "many">>;
1500
+ style: z.ZodOptional<z.ZodObject<{
1501
+ width: z.ZodOptional<z.ZodEnum<["full", "auto"]>>;
1497
1502
  }, "strip", z.ZodTypeAny, {
1498
- fullWidth: boolean;
1503
+ width?: "full" | "auto" | undefined;
1499
1504
  }, {
1500
- fullWidth: boolean;
1501
- }>;
1505
+ width?: "full" | "auto" | undefined;
1506
+ }>>;
1502
1507
  }, "strip", z.ZodTypeAny, {
1503
- style: {
1504
- fullWidth: boolean;
1505
- };
1508
+ maxFileSize: number;
1509
+ acceptedFileTypes?: ("image/png" | "image/jpg" | "image/jpeg" | "image/svg+xml")[] | undefined;
1510
+ style?: {
1511
+ width?: "full" | "auto" | undefined;
1512
+ } | undefined;
1506
1513
  }, {
1507
- style: {
1508
- fullWidth: boolean;
1509
- };
1514
+ maxFileSize?: number | undefined;
1515
+ acceptedFileTypes?: ("image/png" | "image/jpg" | "image/jpeg" | "image/svg+xml")[] | undefined;
1516
+ style?: {
1517
+ width?: "full" | "auto" | undefined;
1518
+ } | undefined;
1510
1519
  }>>;
1511
1520
  }>, "strip", z.ZodTypeAny, {
1512
1521
  type: "FILE";
1513
1522
  id: string;
1514
1523
  label: TranslationConfig;
1515
- options?: {
1516
- style: {
1517
- fullWidth: boolean;
1518
- };
1519
- } | undefined;
1524
+ configuration: {
1525
+ maxFileSize: number;
1526
+ acceptedFileTypes?: ("image/png" | "image/jpg" | "image/jpeg" | "image/svg+xml")[] | undefined;
1527
+ style?: {
1528
+ width?: "full" | "auto" | undefined;
1529
+ } | undefined;
1530
+ };
1520
1531
  validation?: {
1521
1532
  message: TranslationConfig;
1522
1533
  validator: import(".").JSONSchema;
@@ -1546,11 +1557,6 @@ declare const File: z.ZodObject<z.objectUtil.extendShape<{
1546
1557
  description: string;
1547
1558
  defaultMessage: string;
1548
1559
  };
1549
- options?: {
1550
- style: {
1551
- fullWidth: boolean;
1552
- };
1553
- } | undefined;
1554
1560
  validation?: {
1555
1561
  message: {
1556
1562
  id: string;
@@ -1580,6 +1586,13 @@ declare const File: z.ZodObject<z.objectUtil.extendShape<{
1580
1586
  defaultMessage: string;
1581
1587
  } | undefined;
1582
1588
  hideLabel?: boolean | undefined;
1589
+ configuration?: {
1590
+ maxFileSize?: number | undefined;
1591
+ acceptedFileTypes?: ("image/png" | "image/jpg" | "image/jpeg" | "image/svg+xml")[] | undefined;
1592
+ style?: {
1593
+ width?: "full" | "auto" | undefined;
1594
+ } | undefined;
1595
+ } | undefined;
1583
1596
  }>;
1584
1597
  export type File = z.infer<typeof File>;
1585
1598
  declare const SelectOption: z.ZodObject<{
@@ -2322,22 +2335,22 @@ export type Country = z.infer<typeof Country>;
2322
2335
  export declare const AdministrativeAreas: z.ZodEnum<["ADMIN_STRUCTURE", "HEALTH_FACILITY", "CRVS_OFFICE"]>;
2323
2336
  declare const AdministrativeAreaConfiguration: z.ZodObject<{
2324
2337
  partOf: z.ZodOptional<z.ZodObject<{
2325
- $data: z.ZodString;
2338
+ $declaration: z.ZodString;
2326
2339
  }, "strip", z.ZodTypeAny, {
2327
- $data: string;
2340
+ $declaration: string;
2328
2341
  }, {
2329
- $data: string;
2342
+ $declaration: string;
2330
2343
  }>>;
2331
2344
  type: z.ZodEnum<["ADMIN_STRUCTURE", "HEALTH_FACILITY", "CRVS_OFFICE"]>;
2332
2345
  }, "strip", z.ZodTypeAny, {
2333
2346
  type: "ADMIN_STRUCTURE" | "HEALTH_FACILITY" | "CRVS_OFFICE";
2334
2347
  partOf?: {
2335
- $data: string;
2348
+ $declaration: string;
2336
2349
  } | undefined;
2337
2350
  }, {
2338
2351
  type: "ADMIN_STRUCTURE" | "HEALTH_FACILITY" | "CRVS_OFFICE";
2339
2352
  partOf?: {
2340
- $data: string;
2353
+ $declaration: string;
2341
2354
  } | undefined;
2342
2355
  }>;
2343
2356
  declare const AdministrativeArea: z.ZodObject<z.objectUtil.extendShape<{
@@ -2400,22 +2413,22 @@ declare const AdministrativeArea: z.ZodObject<z.objectUtil.extendShape<{
2400
2413
  }>]>>;
2401
2414
  configuration: z.ZodObject<{
2402
2415
  partOf: z.ZodOptional<z.ZodObject<{
2403
- $data: z.ZodString;
2416
+ $declaration: z.ZodString;
2404
2417
  }, "strip", z.ZodTypeAny, {
2405
- $data: string;
2418
+ $declaration: string;
2406
2419
  }, {
2407
- $data: string;
2420
+ $declaration: string;
2408
2421
  }>>;
2409
2422
  type: z.ZodEnum<["ADMIN_STRUCTURE", "HEALTH_FACILITY", "CRVS_OFFICE"]>;
2410
2423
  }, "strip", z.ZodTypeAny, {
2411
2424
  type: "ADMIN_STRUCTURE" | "HEALTH_FACILITY" | "CRVS_OFFICE";
2412
2425
  partOf?: {
2413
- $data: string;
2426
+ $declaration: string;
2414
2427
  } | undefined;
2415
2428
  }, {
2416
2429
  type: "ADMIN_STRUCTURE" | "HEALTH_FACILITY" | "CRVS_OFFICE";
2417
2430
  partOf?: {
2418
- $data: string;
2431
+ $declaration: string;
2419
2432
  } | undefined;
2420
2433
  }>;
2421
2434
  }>, "strip", z.ZodTypeAny, {
@@ -2425,7 +2438,7 @@ declare const AdministrativeArea: z.ZodObject<z.objectUtil.extendShape<{
2425
2438
  configuration: {
2426
2439
  type: "ADMIN_STRUCTURE" | "HEALTH_FACILITY" | "CRVS_OFFICE";
2427
2440
  partOf?: {
2428
- $data: string;
2441
+ $declaration: string;
2429
2442
  } | undefined;
2430
2443
  };
2431
2444
  validation?: {
@@ -2460,7 +2473,7 @@ declare const AdministrativeArea: z.ZodObject<z.objectUtil.extendShape<{
2460
2473
  configuration: {
2461
2474
  type: "ADMIN_STRUCTURE" | "HEALTH_FACILITY" | "CRVS_OFFICE";
2462
2475
  partOf?: {
2463
- $data: string;
2476
+ $declaration: string;
2464
2477
  } | undefined;
2465
2478
  };
2466
2479
  validation?: {
@@ -2682,6 +2695,16 @@ declare const FileUploadWithOptions: z.ZodObject<z.objectUtil.extendShape<{
2682
2695
  defaultMessage: string;
2683
2696
  };
2684
2697
  }>, "many">;
2698
+ configuration: z.ZodDefault<z.ZodObject<{
2699
+ maxFileSize: z.ZodDefault<z.ZodNumber>;
2700
+ acceptedFileTypes: z.ZodOptional<z.ZodArray<z.ZodEnum<["image/png", "image/jpg", "image/jpeg", "image/svg+xml"]>, "many">>;
2701
+ }, "strip", z.ZodTypeAny, {
2702
+ maxFileSize: number;
2703
+ acceptedFileTypes?: ("image/png" | "image/jpg" | "image/jpeg" | "image/svg+xml")[] | undefined;
2704
+ }, {
2705
+ maxFileSize?: number | undefined;
2706
+ acceptedFileTypes?: ("image/png" | "image/jpg" | "image/jpeg" | "image/svg+xml")[] | undefined;
2707
+ }>>;
2685
2708
  }>, "strip", z.ZodTypeAny, {
2686
2709
  type: "FILE_WITH_OPTIONS";
2687
2710
  id: string;
@@ -2690,6 +2713,10 @@ declare const FileUploadWithOptions: z.ZodObject<z.objectUtil.extendShape<{
2690
2713
  label: TranslationConfig;
2691
2714
  }[];
2692
2715
  label: TranslationConfig;
2716
+ configuration: {
2717
+ maxFileSize: number;
2718
+ acceptedFileTypes?: ("image/png" | "image/jpg" | "image/jpeg" | "image/svg+xml")[] | undefined;
2719
+ };
2693
2720
  validation?: {
2694
2721
  message: TranslationConfig;
2695
2722
  validator: import(".").JSONSchema;
@@ -2756,6 +2783,10 @@ declare const FileUploadWithOptions: z.ZodObject<z.objectUtil.extendShape<{
2756
2783
  defaultMessage: string;
2757
2784
  } | undefined;
2758
2785
  hideLabel?: boolean | undefined;
2786
+ configuration?: {
2787
+ maxFileSize?: number | undefined;
2788
+ acceptedFileTypes?: ("image/png" | "image/jpg" | "image/jpeg" | "image/svg+xml")[] | undefined;
2789
+ } | undefined;
2759
2790
  }>;
2760
2791
  export type FileUploadWithOptions = z.infer<typeof FileUploadWithOptions>;
2761
2792
  declare const Facility: z.ZodObject<z.objectUtil.extendShape<{
@@ -3050,8 +3081,9 @@ declare const Address: z.ZodObject<z.objectUtil.extendShape<{
3050
3081
  hideLabel: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
3051
3082
  }, {
3052
3083
  type: z.ZodLiteral<"ADDRESS">;
3053
- defaultValue: z.ZodOptional<z.ZodDiscriminatedUnion<"urbanOrRural", [z.ZodObject<z.objectUtil.extendShape<{
3084
+ defaultValue: z.ZodOptional<z.ZodUnion<[z.ZodDiscriminatedUnion<"urbanOrRural", [z.ZodObject<z.objectUtil.extendShape<{
3054
3085
  country: z.ZodString;
3086
+ addressType: z.ZodLiteral<"DOMESTIC">;
3055
3087
  province: z.ZodString;
3056
3088
  district: z.ZodString;
3057
3089
  }, {
@@ -3064,6 +3096,7 @@ declare const Address: z.ZodObject<z.objectUtil.extendShape<{
3064
3096
  }>, "strip", z.ZodTypeAny, {
3065
3097
  country: string;
3066
3098
  district: string;
3099
+ addressType: "DOMESTIC";
3067
3100
  province: string;
3068
3101
  urbanOrRural: "URBAN";
3069
3102
  number?: string | undefined;
@@ -3074,6 +3107,7 @@ declare const Address: z.ZodObject<z.objectUtil.extendShape<{
3074
3107
  }, {
3075
3108
  country: string;
3076
3109
  district: string;
3110
+ addressType: "DOMESTIC";
3077
3111
  province: string;
3078
3112
  urbanOrRural: "URBAN";
3079
3113
  number?: string | undefined;
@@ -3083,6 +3117,7 @@ declare const Address: z.ZodObject<z.objectUtil.extendShape<{
3083
3117
  zipCode?: string | undefined;
3084
3118
  }>, z.ZodObject<z.objectUtil.extendShape<{
3085
3119
  country: z.ZodString;
3120
+ addressType: z.ZodLiteral<"DOMESTIC">;
3086
3121
  province: z.ZodString;
3087
3122
  district: z.ZodString;
3088
3123
  }, {
@@ -3091,15 +3126,47 @@ declare const Address: z.ZodObject<z.objectUtil.extendShape<{
3091
3126
  }>, "strip", z.ZodTypeAny, {
3092
3127
  country: string;
3093
3128
  district: string;
3129
+ addressType: "DOMESTIC";
3094
3130
  province: string;
3095
3131
  urbanOrRural: "RURAL";
3096
3132
  village?: string | undefined;
3097
3133
  }, {
3098
3134
  country: string;
3099
3135
  district: string;
3136
+ addressType: "DOMESTIC";
3100
3137
  province: string;
3101
3138
  urbanOrRural: "RURAL";
3102
3139
  village?: string | undefined;
3140
+ }>]>, z.ZodObject<{
3141
+ country: z.ZodString;
3142
+ addressType: z.ZodLiteral<"INTERNATIONAL">;
3143
+ state: z.ZodString;
3144
+ district2: z.ZodString;
3145
+ cityOrTown: z.ZodOptional<z.ZodString>;
3146
+ addressLine1: z.ZodOptional<z.ZodString>;
3147
+ addressLine2: z.ZodOptional<z.ZodString>;
3148
+ addressLine3: z.ZodOptional<z.ZodString>;
3149
+ postcodeOrZip: z.ZodOptional<z.ZodString>;
3150
+ }, "strip", z.ZodTypeAny, {
3151
+ country: string;
3152
+ state: string;
3153
+ addressType: "INTERNATIONAL";
3154
+ district2: string;
3155
+ cityOrTown?: string | undefined;
3156
+ addressLine1?: string | undefined;
3157
+ addressLine2?: string | undefined;
3158
+ addressLine3?: string | undefined;
3159
+ postcodeOrZip?: string | undefined;
3160
+ }, {
3161
+ country: string;
3162
+ state: string;
3163
+ addressType: "INTERNATIONAL";
3164
+ district2: string;
3165
+ cityOrTown?: string | undefined;
3166
+ addressLine1?: string | undefined;
3167
+ addressLine2?: string | undefined;
3168
+ addressLine3?: string | undefined;
3169
+ postcodeOrZip?: string | undefined;
3103
3170
  }>]>>;
3104
3171
  }>, "strip", z.ZodTypeAny, {
3105
3172
  type: "ADDRESS";
@@ -3114,6 +3181,7 @@ declare const Address: z.ZodObject<z.objectUtil.extendShape<{
3114
3181
  defaultValue?: {
3115
3182
  country: string;
3116
3183
  district: string;
3184
+ addressType: "DOMESTIC";
3117
3185
  province: string;
3118
3186
  urbanOrRural: "URBAN";
3119
3187
  number?: string | undefined;
@@ -3124,9 +3192,20 @@ declare const Address: z.ZodObject<z.objectUtil.extendShape<{
3124
3192
  } | {
3125
3193
  country: string;
3126
3194
  district: string;
3195
+ addressType: "DOMESTIC";
3127
3196
  province: string;
3128
3197
  urbanOrRural: "RURAL";
3129
3198
  village?: string | undefined;
3199
+ } | {
3200
+ country: string;
3201
+ state: string;
3202
+ addressType: "INTERNATIONAL";
3203
+ district2: string;
3204
+ cityOrTown?: string | undefined;
3205
+ addressLine1?: string | undefined;
3206
+ addressLine2?: string | undefined;
3207
+ addressLine3?: string | undefined;
3208
+ postcodeOrZip?: string | undefined;
3130
3209
  } | undefined;
3131
3210
  conditionals?: ({
3132
3211
  type: "SHOW";
@@ -3160,6 +3239,7 @@ declare const Address: z.ZodObject<z.objectUtil.extendShape<{
3160
3239
  defaultValue?: {
3161
3240
  country: string;
3162
3241
  district: string;
3242
+ addressType: "DOMESTIC";
3163
3243
  province: string;
3164
3244
  urbanOrRural: "URBAN";
3165
3245
  number?: string | undefined;
@@ -3170,9 +3250,237 @@ declare const Address: z.ZodObject<z.objectUtil.extendShape<{
3170
3250
  } | {
3171
3251
  country: string;
3172
3252
  district: string;
3253
+ addressType: "DOMESTIC";
3173
3254
  province: string;
3174
3255
  urbanOrRural: "RURAL";
3175
3256
  village?: string | undefined;
3257
+ } | {
3258
+ country: string;
3259
+ state: string;
3260
+ addressType: "INTERNATIONAL";
3261
+ district2: string;
3262
+ cityOrTown?: string | undefined;
3263
+ addressLine1?: string | undefined;
3264
+ addressLine2?: string | undefined;
3265
+ addressLine3?: string | undefined;
3266
+ postcodeOrZip?: string | undefined;
3267
+ } | undefined;
3268
+ conditionals?: ({
3269
+ type: "SHOW";
3270
+ conditional: import(".").JSONSchema;
3271
+ } | {
3272
+ type: "ENABLE";
3273
+ conditional: import(".").JSONSchema;
3274
+ })[] | undefined;
3275
+ disabled?: boolean | undefined;
3276
+ hidden?: boolean | undefined;
3277
+ placeholder?: {
3278
+ id: string;
3279
+ description: string;
3280
+ defaultMessage: string;
3281
+ } | undefined;
3282
+ hideLabel?: boolean | undefined;
3283
+ }>;
3284
+ export declare const DataEntry: z.ZodUnion<[z.ZodObject<{
3285
+ label: z.ZodObject<import("./TranslationConfig").MessageDescriptorZod, "strip", z.ZodTypeAny, TranslationConfig, {
3286
+ id: string;
3287
+ description: string;
3288
+ defaultMessage: string;
3289
+ }>;
3290
+ value: z.ZodString;
3291
+ }, "strip", z.ZodTypeAny, {
3292
+ value: string;
3293
+ label: TranslationConfig;
3294
+ }, {
3295
+ value: string;
3296
+ label: {
3297
+ id: string;
3298
+ description: string;
3299
+ defaultMessage: string;
3300
+ };
3301
+ }>, z.ZodObject<{
3302
+ fieldId: z.ZodString;
3303
+ }, "strip", z.ZodTypeAny, {
3304
+ fieldId: string;
3305
+ }, {
3306
+ fieldId: string;
3307
+ }>]>;
3308
+ export type DataEntry = z.infer<typeof DataEntry>;
3309
+ declare const DataField: z.ZodObject<z.objectUtil.extendShape<{
3310
+ id: z.ZodString;
3311
+ defaultValue: z.ZodOptional<z.ZodUnion<[z.ZodUnion<[z.ZodString, z.ZodString, z.ZodString, z.ZodNumber, z.ZodBoolean]>, z.ZodObject<{
3312
+ dependsOn: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
3313
+ expression: z.ZodString;
3314
+ }, "strip", z.ZodTypeAny, {
3315
+ dependsOn: string[];
3316
+ expression: string;
3317
+ }, {
3318
+ expression: string;
3319
+ dependsOn?: string[] | undefined;
3320
+ }>]>>;
3321
+ conditionals: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodDiscriminatedUnion<"type", import("./Conditional").AllActionConditionalFields[]>, "many">>>;
3322
+ required: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
3323
+ disabled: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
3324
+ hidden: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
3325
+ placeholder: z.ZodOptional<z.ZodObject<import("./TranslationConfig").MessageDescriptorZod, "strip", z.ZodTypeAny, TranslationConfig, {
3326
+ id: string;
3327
+ description: string;
3328
+ defaultMessage: string;
3329
+ }>>;
3330
+ validation: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodObject<{
3331
+ validator: z.ZodType<import(".").JSONSchema, z.ZodTypeDef, import(".").JSONSchema>;
3332
+ message: z.ZodObject<import("./TranslationConfig").MessageDescriptorZod, "strip", z.ZodTypeAny, TranslationConfig, {
3333
+ id: string;
3334
+ description: string;
3335
+ defaultMessage: string;
3336
+ }>;
3337
+ }, "strip", z.ZodTypeAny, {
3338
+ message: TranslationConfig;
3339
+ validator: import(".").JSONSchema;
3340
+ }, {
3341
+ message: {
3342
+ id: string;
3343
+ description: string;
3344
+ defaultMessage: string;
3345
+ };
3346
+ validator: import(".").JSONSchema;
3347
+ }>, "many">>>;
3348
+ dependsOn: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodString, "many">>>;
3349
+ label: z.ZodObject<import("./TranslationConfig").MessageDescriptorZod, "strip", z.ZodTypeAny, TranslationConfig, {
3350
+ id: string;
3351
+ description: string;
3352
+ defaultMessage: string;
3353
+ }>;
3354
+ hideLabel: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
3355
+ }, {
3356
+ type: z.ZodLiteral<"DATA">;
3357
+ configuration: z.ZodObject<{
3358
+ subtitle: z.ZodOptional<z.ZodObject<import("./TranslationConfig").MessageDescriptorZod, "strip", z.ZodTypeAny, TranslationConfig, {
3359
+ id: string;
3360
+ description: string;
3361
+ defaultMessage: string;
3362
+ }>>;
3363
+ data: z.ZodArray<z.ZodUnion<[z.ZodObject<{
3364
+ label: z.ZodObject<import("./TranslationConfig").MessageDescriptorZod, "strip", z.ZodTypeAny, TranslationConfig, {
3365
+ id: string;
3366
+ description: string;
3367
+ defaultMessage: string;
3368
+ }>;
3369
+ value: z.ZodString;
3370
+ }, "strip", z.ZodTypeAny, {
3371
+ value: string;
3372
+ label: TranslationConfig;
3373
+ }, {
3374
+ value: string;
3375
+ label: {
3376
+ id: string;
3377
+ description: string;
3378
+ defaultMessage: string;
3379
+ };
3380
+ }>, z.ZodObject<{
3381
+ fieldId: z.ZodString;
3382
+ }, "strip", z.ZodTypeAny, {
3383
+ fieldId: string;
3384
+ }, {
3385
+ fieldId: string;
3386
+ }>]>, "many">;
3387
+ }, "strip", z.ZodTypeAny, {
3388
+ data: ({
3389
+ value: string;
3390
+ label: TranslationConfig;
3391
+ } | {
3392
+ fieldId: string;
3393
+ })[];
3394
+ subtitle?: TranslationConfig | undefined;
3395
+ }, {
3396
+ data: ({
3397
+ value: string;
3398
+ label: {
3399
+ id: string;
3400
+ description: string;
3401
+ defaultMessage: string;
3402
+ };
3403
+ } | {
3404
+ fieldId: string;
3405
+ })[];
3406
+ subtitle?: {
3407
+ id: string;
3408
+ description: string;
3409
+ defaultMessage: string;
3410
+ } | undefined;
3411
+ }>;
3412
+ }>, "strip", z.ZodTypeAny, {
3413
+ type: "DATA";
3414
+ id: string;
3415
+ label: TranslationConfig;
3416
+ configuration: {
3417
+ data: ({
3418
+ value: string;
3419
+ label: TranslationConfig;
3420
+ } | {
3421
+ fieldId: string;
3422
+ })[];
3423
+ subtitle?: TranslationConfig | undefined;
3424
+ };
3425
+ validation?: {
3426
+ message: TranslationConfig;
3427
+ validator: import(".").JSONSchema;
3428
+ }[] | undefined;
3429
+ required?: boolean | undefined;
3430
+ dependsOn?: string[] | undefined;
3431
+ defaultValue?: string | number | boolean | {
3432
+ dependsOn: string[];
3433
+ expression: string;
3434
+ } | undefined;
3435
+ conditionals?: ({
3436
+ type: "SHOW";
3437
+ conditional: import(".").JSONSchema;
3438
+ } | {
3439
+ type: "ENABLE";
3440
+ conditional: import(".").JSONSchema;
3441
+ })[] | undefined;
3442
+ disabled?: boolean | undefined;
3443
+ hidden?: boolean | undefined;
3444
+ placeholder?: TranslationConfig | undefined;
3445
+ hideLabel?: boolean | undefined;
3446
+ }, {
3447
+ type: "DATA";
3448
+ id: string;
3449
+ label: {
3450
+ id: string;
3451
+ description: string;
3452
+ defaultMessage: string;
3453
+ };
3454
+ configuration: {
3455
+ data: ({
3456
+ value: string;
3457
+ label: {
3458
+ id: string;
3459
+ description: string;
3460
+ defaultMessage: string;
3461
+ };
3462
+ } | {
3463
+ fieldId: string;
3464
+ })[];
3465
+ subtitle?: {
3466
+ id: string;
3467
+ description: string;
3468
+ defaultMessage: string;
3469
+ } | undefined;
3470
+ };
3471
+ validation?: {
3472
+ message: {
3473
+ id: string;
3474
+ description: string;
3475
+ defaultMessage: string;
3476
+ };
3477
+ validator: import(".").JSONSchema;
3478
+ }[] | undefined;
3479
+ required?: boolean | undefined;
3480
+ dependsOn?: string[] | undefined;
3481
+ defaultValue?: string | number | boolean | {
3482
+ expression: string;
3483
+ dependsOn?: string[] | undefined;
3176
3484
  } | undefined;
3177
3485
  conditionals?: ({
3178
3486
  type: "SHOW";
@@ -3190,11 +3498,17 @@ declare const Address: z.ZodObject<z.objectUtil.extendShape<{
3190
3498
  } | undefined;
3191
3499
  hideLabel?: boolean | undefined;
3192
3500
  }>;
3501
+ export type DataField = z.infer<typeof DataField>;
3502
+ /** @knipignore */
3503
+ export type AllFields = typeof Address | typeof TextField | typeof NumberField | typeof TextAreaField | typeof DateField | typeof Paragraph | typeof RadioGroup | typeof BulletList | typeof PageHeader | typeof Select | typeof Checkbox | typeof File | typeof Country | typeof AdministrativeArea | typeof Divider | typeof Location | typeof Facility | typeof Office | typeof SignatureField | typeof EmailField | typeof FileUploadWithOptions | typeof DataField;
3193
3504
  /** @knipignore */
3194
- export type AllFields = typeof Address | typeof TextField | typeof NumberField | typeof TextAreaField | typeof DateField | typeof Paragraph | typeof RadioGroup | typeof BulletList | typeof PageHeader | typeof Select | typeof Checkbox | typeof File | typeof Country | typeof AdministrativeArea | typeof Divider | typeof Location | typeof Facility | typeof Office | typeof SignatureField | typeof EmailField | typeof FileUploadWithOptions;
3505
+ export type Inferred = z.infer<typeof Address> | z.infer<typeof TextField> | z.infer<typeof NumberField> | z.infer<typeof TextAreaField> | z.infer<typeof DateField> | z.infer<typeof Paragraph> | z.infer<typeof RadioGroup> | z.infer<typeof BulletList> | z.infer<typeof PageHeader> | z.infer<typeof Select> | z.infer<typeof Checkbox> | z.infer<typeof File> | z.infer<typeof FileUploadWithOptions> | z.infer<typeof Country> | z.infer<typeof AdministrativeArea> | z.infer<typeof Divider> | z.infer<typeof Location> | z.infer<typeof Facility> | z.infer<typeof Office> | z.infer<typeof SignatureField> | z.infer<typeof EmailField> | z.infer<typeof DataField>;
3195
3506
  /** @knipignore */
3196
- export type Inferred = z.infer<typeof Address> | z.infer<typeof TextField> | z.infer<typeof NumberField> | z.infer<typeof TextAreaField> | z.infer<typeof DateField> | z.infer<typeof Paragraph> | z.infer<typeof RadioGroup> | z.infer<typeof BulletList> | z.infer<typeof PageHeader> | z.infer<typeof Select> | z.infer<typeof Checkbox> | z.infer<typeof File> | z.infer<typeof FileUploadWithOptions> | z.infer<typeof Country> | z.infer<typeof AdministrativeArea> | z.infer<typeof Divider> | z.infer<typeof Location> | z.infer<typeof Facility> | z.infer<typeof Office> | z.infer<typeof SignatureField> | z.infer<typeof EmailField>;
3197
- export declare const FieldConfig: z.ZodType<Inferred, any, Inferred>;
3507
+ /**
3508
+ * This is the type that should be used for the input of the FieldConfig. Useful when config uses zod defaults.
3509
+ */
3510
+ export type InferredInput = z.input<typeof Address> | z.input<typeof TextField> | z.input<typeof NumberField> | z.input<typeof TextAreaField> | z.input<typeof DateField> | z.input<typeof Paragraph> | z.input<typeof RadioGroup> | z.input<typeof BulletList> | z.input<typeof PageHeader> | z.input<typeof Select> | z.input<typeof Checkbox> | z.input<typeof File> | z.input<typeof FileUploadWithOptions> | z.input<typeof Country> | z.input<typeof AdministrativeArea> | z.input<typeof Divider> | z.input<typeof Location> | z.input<typeof Facility> | z.input<typeof Office> | z.input<typeof SignatureField> | z.input<typeof EmailField> | z.input<typeof DataField>;
3511
+ export declare const FieldConfig: z.ZodType<Inferred, any, InferredInput>;
3198
3512
  export type SelectField = z.infer<typeof Select>;
3199
3513
  export type LocationField = z.infer<typeof Location>;
3200
3514
  export type RadioField = z.infer<typeof RadioGroup>;
@@ -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.