@opencrvs/toolkit 1.8.1-rc.be16155 → 1.8.1-rc.d31fe05

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.
@@ -448,11 +448,11 @@ export declare const SearchQueryParams: z.ZodObject<{
448
448
  export type SearchQueryParams = z.infer<typeof SearchQueryParams>;
449
449
  export declare const FieldConfigSchema: z.ZodObject<z.objectUtil.extendShape<{
450
450
  config: z.ZodObject<{
451
- type: z.ZodEnum<["fuzzy", "exact", "range"]>;
451
+ type: z.ZodEnum<["fuzzy", "exact", "range", "within"]>;
452
452
  }, "strip", z.ZodTypeAny, {
453
- type: "exact" | "fuzzy" | "range";
453
+ type: "exact" | "fuzzy" | "range" | "within";
454
454
  }, {
455
- type: "exact" | "fuzzy" | "range";
455
+ type: "exact" | "fuzzy" | "range" | "within";
456
456
  }>;
457
457
  options: z.ZodOptional<z.ZodArray<z.ZodObject<{
458
458
  value: z.ZodString;
@@ -503,7 +503,7 @@ export declare const FieldConfigSchema: z.ZodObject<z.objectUtil.extendShape<{
503
503
  excludeInSearchQuery: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
504
504
  }>, "strip", z.ZodTypeAny, {
505
505
  config: {
506
- type: "exact" | "fuzzy" | "range";
506
+ type: "exact" | "fuzzy" | "range" | "within";
507
507
  };
508
508
  fieldId: string;
509
509
  fieldType: "field";
@@ -530,7 +530,7 @@ export declare const FieldConfigSchema: z.ZodObject<z.objectUtil.extendShape<{
530
530
  excludeInSearchQuery?: boolean | undefined;
531
531
  }, {
532
532
  config: {
533
- type: "exact" | "fuzzy" | "range";
533
+ type: "exact" | "fuzzy" | "range" | "within";
534
534
  };
535
535
  fieldId: string;
536
536
  fieldType: "field";
@@ -572,11 +572,11 @@ export declare const EventFieldId: z.ZodEnum<["trackingId", "status", "legalStat
572
572
  export type EventFieldId = z.infer<typeof EventFieldId>;
573
573
  export declare const EventFieldConfigSchema: z.ZodObject<z.objectUtil.extendShape<{
574
574
  config: z.ZodObject<{
575
- type: z.ZodEnum<["fuzzy", "exact", "range"]>;
575
+ type: z.ZodEnum<["fuzzy", "exact", "range", "within"]>;
576
576
  }, "strip", z.ZodTypeAny, {
577
- type: "exact" | "fuzzy" | "range";
577
+ type: "exact" | "fuzzy" | "range" | "within";
578
578
  }, {
579
- type: "exact" | "fuzzy" | "range";
579
+ type: "exact" | "fuzzy" | "range" | "within";
580
580
  }>;
581
581
  options: z.ZodOptional<z.ZodArray<z.ZodObject<{
582
582
  value: z.ZodString;
@@ -625,7 +625,7 @@ export declare const EventFieldConfigSchema: z.ZodObject<z.objectUtil.extendShap
625
625
  fieldType: z.ZodLiteral<"event">;
626
626
  }>, "strip", z.ZodTypeAny, {
627
627
  config: {
628
- type: "exact" | "fuzzy" | "range";
628
+ type: "exact" | "fuzzy" | "range" | "within";
629
629
  };
630
630
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
631
631
  fieldType: "event";
@@ -650,7 +650,7 @@ export declare const EventFieldConfigSchema: z.ZodObject<z.objectUtil.extendShap
650
650
  }[] | undefined;
651
651
  }, {
652
652
  config: {
653
- type: "exact" | "fuzzy" | "range";
653
+ type: "exact" | "fuzzy" | "range" | "within";
654
654
  };
655
655
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
656
656
  fieldType: "event";
@@ -688,11 +688,11 @@ export declare const EventFieldConfigSchema: z.ZodObject<z.objectUtil.extendShap
688
688
  }>;
689
689
  export declare const SearchField: z.ZodDiscriminatedUnion<"fieldType", [z.ZodObject<z.objectUtil.extendShape<{
690
690
  config: z.ZodObject<{
691
- type: z.ZodEnum<["fuzzy", "exact", "range"]>;
691
+ type: z.ZodEnum<["fuzzy", "exact", "range", "within"]>;
692
692
  }, "strip", z.ZodTypeAny, {
693
- type: "exact" | "fuzzy" | "range";
693
+ type: "exact" | "fuzzy" | "range" | "within";
694
694
  }, {
695
- type: "exact" | "fuzzy" | "range";
695
+ type: "exact" | "fuzzy" | "range" | "within";
696
696
  }>;
697
697
  options: z.ZodOptional<z.ZodArray<z.ZodObject<{
698
698
  value: z.ZodString;
@@ -743,7 +743,7 @@ export declare const SearchField: z.ZodDiscriminatedUnion<"fieldType", [z.ZodObj
743
743
  excludeInSearchQuery: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
744
744
  }>, "strip", z.ZodTypeAny, {
745
745
  config: {
746
- type: "exact" | "fuzzy" | "range";
746
+ type: "exact" | "fuzzy" | "range" | "within";
747
747
  };
748
748
  fieldId: string;
749
749
  fieldType: "field";
@@ -770,7 +770,7 @@ export declare const SearchField: z.ZodDiscriminatedUnion<"fieldType", [z.ZodObj
770
770
  excludeInSearchQuery?: boolean | undefined;
771
771
  }, {
772
772
  config: {
773
- type: "exact" | "fuzzy" | "range";
773
+ type: "exact" | "fuzzy" | "range" | "within";
774
774
  };
775
775
  fieldId: string;
776
776
  fieldType: "field";
@@ -809,11 +809,11 @@ export declare const SearchField: z.ZodDiscriminatedUnion<"fieldType", [z.ZodObj
809
809
  excludeInSearchQuery?: boolean | undefined;
810
810
  }>, z.ZodObject<z.objectUtil.extendShape<{
811
811
  config: z.ZodObject<{
812
- type: z.ZodEnum<["fuzzy", "exact", "range"]>;
812
+ type: z.ZodEnum<["fuzzy", "exact", "range", "within"]>;
813
813
  }, "strip", z.ZodTypeAny, {
814
- type: "exact" | "fuzzy" | "range";
814
+ type: "exact" | "fuzzy" | "range" | "within";
815
815
  }, {
816
- type: "exact" | "fuzzy" | "range";
816
+ type: "exact" | "fuzzy" | "range" | "within";
817
817
  }>;
818
818
  options: z.ZodOptional<z.ZodArray<z.ZodObject<{
819
819
  value: z.ZodString;
@@ -862,7 +862,7 @@ export declare const SearchField: z.ZodDiscriminatedUnion<"fieldType", [z.ZodObj
862
862
  fieldType: z.ZodLiteral<"event">;
863
863
  }>, "strip", z.ZodTypeAny, {
864
864
  config: {
865
- type: "exact" | "fuzzy" | "range";
865
+ type: "exact" | "fuzzy" | "range" | "within";
866
866
  };
867
867
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
868
868
  fieldType: "event";
@@ -887,7 +887,7 @@ export declare const SearchField: z.ZodDiscriminatedUnion<"fieldType", [z.ZodObj
887
887
  }[] | undefined;
888
888
  }, {
889
889
  config: {
890
- type: "exact" | "fuzzy" | "range";
890
+ type: "exact" | "fuzzy" | "range" | "within";
891
891
  };
892
892
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
893
893
  fieldType: "event";
@@ -932,11 +932,11 @@ export declare const AdvancedSearchConfig: z.ZodObject<{
932
932
  }>;
933
933
  fields: z.ZodArray<z.ZodDiscriminatedUnion<"fieldType", [z.ZodObject<z.objectUtil.extendShape<{
934
934
  config: z.ZodObject<{
935
- type: z.ZodEnum<["fuzzy", "exact", "range"]>;
935
+ type: z.ZodEnum<["fuzzy", "exact", "range", "within"]>;
936
936
  }, "strip", z.ZodTypeAny, {
937
- type: "exact" | "fuzzy" | "range";
937
+ type: "exact" | "fuzzy" | "range" | "within";
938
938
  }, {
939
- type: "exact" | "fuzzy" | "range";
939
+ type: "exact" | "fuzzy" | "range" | "within";
940
940
  }>;
941
941
  options: z.ZodOptional<z.ZodArray<z.ZodObject<{
942
942
  value: z.ZodString;
@@ -987,7 +987,7 @@ export declare const AdvancedSearchConfig: z.ZodObject<{
987
987
  excludeInSearchQuery: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
988
988
  }>, "strip", z.ZodTypeAny, {
989
989
  config: {
990
- type: "exact" | "fuzzy" | "range";
990
+ type: "exact" | "fuzzy" | "range" | "within";
991
991
  };
992
992
  fieldId: string;
993
993
  fieldType: "field";
@@ -1014,7 +1014,7 @@ export declare const AdvancedSearchConfig: z.ZodObject<{
1014
1014
  excludeInSearchQuery?: boolean | undefined;
1015
1015
  }, {
1016
1016
  config: {
1017
- type: "exact" | "fuzzy" | "range";
1017
+ type: "exact" | "fuzzy" | "range" | "within";
1018
1018
  };
1019
1019
  fieldId: string;
1020
1020
  fieldType: "field";
@@ -1053,11 +1053,11 @@ export declare const AdvancedSearchConfig: z.ZodObject<{
1053
1053
  excludeInSearchQuery?: boolean | undefined;
1054
1054
  }>, z.ZodObject<z.objectUtil.extendShape<{
1055
1055
  config: z.ZodObject<{
1056
- type: z.ZodEnum<["fuzzy", "exact", "range"]>;
1056
+ type: z.ZodEnum<["fuzzy", "exact", "range", "within"]>;
1057
1057
  }, "strip", z.ZodTypeAny, {
1058
- type: "exact" | "fuzzy" | "range";
1058
+ type: "exact" | "fuzzy" | "range" | "within";
1059
1059
  }, {
1060
- type: "exact" | "fuzzy" | "range";
1060
+ type: "exact" | "fuzzy" | "range" | "within";
1061
1061
  }>;
1062
1062
  options: z.ZodOptional<z.ZodArray<z.ZodObject<{
1063
1063
  value: z.ZodString;
@@ -1106,7 +1106,7 @@ export declare const AdvancedSearchConfig: z.ZodObject<{
1106
1106
  fieldType: z.ZodLiteral<"event">;
1107
1107
  }>, "strip", z.ZodTypeAny, {
1108
1108
  config: {
1109
- type: "exact" | "fuzzy" | "range";
1109
+ type: "exact" | "fuzzy" | "range" | "within";
1110
1110
  };
1111
1111
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
1112
1112
  fieldType: "event";
@@ -1131,7 +1131,7 @@ export declare const AdvancedSearchConfig: z.ZodObject<{
1131
1131
  }[] | undefined;
1132
1132
  }, {
1133
1133
  config: {
1134
- type: "exact" | "fuzzy" | "range";
1134
+ type: "exact" | "fuzzy" | "range" | "within";
1135
1135
  };
1136
1136
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
1137
1137
  fieldType: "event";
@@ -1171,7 +1171,7 @@ export declare const AdvancedSearchConfig: z.ZodObject<{
1171
1171
  title: TranslationConfig;
1172
1172
  fields: ({
1173
1173
  config: {
1174
- type: "exact" | "fuzzy" | "range";
1174
+ type: "exact" | "fuzzy" | "range" | "within";
1175
1175
  };
1176
1176
  fieldId: string;
1177
1177
  fieldType: "field";
@@ -1198,7 +1198,7 @@ export declare const AdvancedSearchConfig: z.ZodObject<{
1198
1198
  excludeInSearchQuery?: boolean | undefined;
1199
1199
  } | {
1200
1200
  config: {
1201
- type: "exact" | "fuzzy" | "range";
1201
+ type: "exact" | "fuzzy" | "range" | "within";
1202
1202
  };
1203
1203
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
1204
1204
  fieldType: "event";
@@ -1230,7 +1230,7 @@ export declare const AdvancedSearchConfig: z.ZodObject<{
1230
1230
  };
1231
1231
  fields: ({
1232
1232
  config: {
1233
- type: "exact" | "fuzzy" | "range";
1233
+ type: "exact" | "fuzzy" | "range" | "within";
1234
1234
  };
1235
1235
  fieldId: string;
1236
1236
  fieldType: "field";
@@ -1269,7 +1269,7 @@ export declare const AdvancedSearchConfig: z.ZodObject<{
1269
1269
  excludeInSearchQuery?: boolean | undefined;
1270
1270
  } | {
1271
1271
  config: {
1272
- type: "exact" | "fuzzy" | "range";
1272
+ type: "exact" | "fuzzy" | "range" | "within";
1273
1273
  };
1274
1274
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
1275
1275
  fieldType: "event";
@@ -9494,11 +9494,11 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
9494
9494
  }>;
9495
9495
  fields: z.ZodArray<z.ZodDiscriminatedUnion<"fieldType", [z.ZodObject<z.objectUtil.extendShape<{
9496
9496
  config: z.ZodObject<{
9497
- type: z.ZodEnum<["fuzzy", "exact", "range"]>;
9497
+ type: z.ZodEnum<["fuzzy", "exact", "range", "within"]>;
9498
9498
  }, "strip", z.ZodTypeAny, {
9499
- type: "exact" | "fuzzy" | "range";
9499
+ type: "exact" | "fuzzy" | "range" | "within";
9500
9500
  }, {
9501
- type: "exact" | "fuzzy" | "range";
9501
+ type: "exact" | "fuzzy" | "range" | "within";
9502
9502
  }>;
9503
9503
  options: z.ZodOptional<z.ZodArray<z.ZodObject<{
9504
9504
  value: z.ZodString;
@@ -9549,7 +9549,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
9549
9549
  excludeInSearchQuery: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
9550
9550
  }>, "strip", z.ZodTypeAny, {
9551
9551
  config: {
9552
- type: "exact" | "fuzzy" | "range";
9552
+ type: "exact" | "fuzzy" | "range" | "within";
9553
9553
  };
9554
9554
  fieldId: string;
9555
9555
  fieldType: "field";
@@ -9576,7 +9576,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
9576
9576
  excludeInSearchQuery?: boolean | undefined;
9577
9577
  }, {
9578
9578
  config: {
9579
- type: "exact" | "fuzzy" | "range";
9579
+ type: "exact" | "fuzzy" | "range" | "within";
9580
9580
  };
9581
9581
  fieldId: string;
9582
9582
  fieldType: "field";
@@ -9615,11 +9615,11 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
9615
9615
  excludeInSearchQuery?: boolean | undefined;
9616
9616
  }>, z.ZodObject<z.objectUtil.extendShape<{
9617
9617
  config: z.ZodObject<{
9618
- type: z.ZodEnum<["fuzzy", "exact", "range"]>;
9618
+ type: z.ZodEnum<["fuzzy", "exact", "range", "within"]>;
9619
9619
  }, "strip", z.ZodTypeAny, {
9620
- type: "exact" | "fuzzy" | "range";
9620
+ type: "exact" | "fuzzy" | "range" | "within";
9621
9621
  }, {
9622
- type: "exact" | "fuzzy" | "range";
9622
+ type: "exact" | "fuzzy" | "range" | "within";
9623
9623
  }>;
9624
9624
  options: z.ZodOptional<z.ZodArray<z.ZodObject<{
9625
9625
  value: z.ZodString;
@@ -9668,7 +9668,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
9668
9668
  fieldType: z.ZodLiteral<"event">;
9669
9669
  }>, "strip", z.ZodTypeAny, {
9670
9670
  config: {
9671
- type: "exact" | "fuzzy" | "range";
9671
+ type: "exact" | "fuzzy" | "range" | "within";
9672
9672
  };
9673
9673
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
9674
9674
  fieldType: "event";
@@ -9693,7 +9693,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
9693
9693
  }[] | undefined;
9694
9694
  }, {
9695
9695
  config: {
9696
- type: "exact" | "fuzzy" | "range";
9696
+ type: "exact" | "fuzzy" | "range" | "within";
9697
9697
  };
9698
9698
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
9699
9699
  fieldType: "event";
@@ -9733,7 +9733,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
9733
9733
  title: TranslationConfig;
9734
9734
  fields: ({
9735
9735
  config: {
9736
- type: "exact" | "fuzzy" | "range";
9736
+ type: "exact" | "fuzzy" | "range" | "within";
9737
9737
  };
9738
9738
  fieldId: string;
9739
9739
  fieldType: "field";
@@ -9760,7 +9760,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
9760
9760
  excludeInSearchQuery?: boolean | undefined;
9761
9761
  } | {
9762
9762
  config: {
9763
- type: "exact" | "fuzzy" | "range";
9763
+ type: "exact" | "fuzzy" | "range" | "within";
9764
9764
  };
9765
9765
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
9766
9766
  fieldType: "event";
@@ -9792,7 +9792,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
9792
9792
  };
9793
9793
  fields: ({
9794
9794
  config: {
9795
- type: "exact" | "fuzzy" | "range";
9795
+ type: "exact" | "fuzzy" | "range" | "within";
9796
9796
  };
9797
9797
  fieldId: string;
9798
9798
  fieldType: "field";
@@ -9831,7 +9831,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
9831
9831
  excludeInSearchQuery?: boolean | undefined;
9832
9832
  } | {
9833
9833
  config: {
9834
- type: "exact" | "fuzzy" | "range";
9834
+ type: "exact" | "fuzzy" | "range" | "within";
9835
9835
  };
9836
9836
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
9837
9837
  fieldType: "event";
@@ -18522,7 +18522,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
18522
18522
  title: TranslationConfig;
18523
18523
  fields: ({
18524
18524
  config: {
18525
- type: "exact" | "fuzzy" | "range";
18525
+ type: "exact" | "fuzzy" | "range" | "within";
18526
18526
  };
18527
18527
  fieldId: string;
18528
18528
  fieldType: "field";
@@ -18549,7 +18549,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
18549
18549
  excludeInSearchQuery?: boolean | undefined;
18550
18550
  } | {
18551
18551
  config: {
18552
- type: "exact" | "fuzzy" | "range";
18552
+ type: "exact" | "fuzzy" | "range" | "within";
18553
18553
  };
18554
18554
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
18555
18555
  fieldType: "event";
@@ -32192,7 +32192,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
32192
32192
  };
32193
32193
  fields: ({
32194
32194
  config: {
32195
- type: "exact" | "fuzzy" | "range";
32195
+ type: "exact" | "fuzzy" | "range" | "within";
32196
32196
  };
32197
32197
  fieldId: string;
32198
32198
  fieldType: "field";
@@ -32231,7 +32231,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
32231
32231
  excludeInSearchQuery?: boolean | undefined;
32232
32232
  } | {
32233
32233
  config: {
32234
- type: "exact" | "fuzzy" | "range";
32234
+ type: "exact" | "fuzzy" | "range" | "within";
32235
32235
  };
32236
32236
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
32237
32237
  fieldType: "event";
@@ -40922,7 +40922,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
40922
40922
  title: TranslationConfig;
40923
40923
  fields: ({
40924
40924
  config: {
40925
- type: "exact" | "fuzzy" | "range";
40925
+ type: "exact" | "fuzzy" | "range" | "within";
40926
40926
  };
40927
40927
  fieldId: string;
40928
40928
  fieldType: "field";
@@ -40949,7 +40949,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
40949
40949
  excludeInSearchQuery?: boolean | undefined;
40950
40950
  } | {
40951
40951
  config: {
40952
- type: "exact" | "fuzzy" | "range";
40952
+ type: "exact" | "fuzzy" | "range" | "within";
40953
40953
  };
40954
40954
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
40955
40955
  fieldType: "event";
@@ -54592,7 +54592,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
54592
54592
  };
54593
54593
  fields: ({
54594
54594
  config: {
54595
- type: "exact" | "fuzzy" | "range";
54595
+ type: "exact" | "fuzzy" | "range" | "within";
54596
54596
  };
54597
54597
  fieldId: string;
54598
54598
  fieldType: "field";
@@ -54631,7 +54631,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
54631
54631
  excludeInSearchQuery?: boolean | undefined;
54632
54632
  } | {
54633
54633
  config: {
54634
- type: "exact" | "fuzzy" | "range";
54634
+ type: "exact" | "fuzzy" | "range" | "within";
54635
54635
  };
54636
54636
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
54637
54637
  fieldType: "event";
@@ -8657,7 +8657,7 @@ export declare const defineConfig: (config: EventConfigInput) => {
8657
8657
  title: import("./TranslationConfig").TranslationConfig;
8658
8658
  fields: ({
8659
8659
  config: {
8660
- type: "exact" | "fuzzy" | "range";
8660
+ type: "exact" | "fuzzy" | "range" | "within";
8661
8661
  };
8662
8662
  fieldId: string;
8663
8663
  fieldType: "field";
@@ -8684,7 +8684,7 @@ export declare const defineConfig: (config: EventConfigInput) => {
8684
8684
  excludeInSearchQuery?: boolean | undefined;
8685
8685
  } | {
8686
8686
  config: {
8687
- type: "exact" | "fuzzy" | "range";
8687
+ type: "exact" | "fuzzy" | "range" | "within";
8688
8688
  };
8689
8689
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
8690
8690
  fieldType: "event";
@@ -33,6 +33,14 @@ declare function eventFn(fieldId: EventFieldId): {
33
33
  type: "fuzzy";
34
34
  };
35
35
  };
36
+ within: () => {
37
+ fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
38
+ fieldType: "event";
39
+ } & {
40
+ config: {
41
+ type: "within";
42
+ };
43
+ };
36
44
  };
37
45
  declare const event: typeof eventFn & {
38
46
  /**
@@ -56,6 +56,20 @@ export declare function field(fieldId: string, options?: {
56
56
  type: "fuzzy";
57
57
  };
58
58
  };
59
+ within: () => {
60
+ options?: SelectOption[];
61
+ excludeInSearchQuery?: boolean;
62
+ alternateFieldIds?: string[];
63
+ conditionals?: FieldConditional[];
64
+ validations?: ValidationConfig[];
65
+ searchCriteriaLabelPrefix?: TranslationConfig;
66
+ fieldId: string;
67
+ fieldType: "field";
68
+ } & {
69
+ config: {
70
+ type: "within";
71
+ };
72
+ };
59
73
  $$field: string;
60
74
  isAfter: () => {
61
75
  days: (days: number) => {
@@ -15520,7 +15520,7 @@ export declare function getEventConfigById(eventConfigs: EventConfig[], id: stri
15520
15520
  title: import("./TranslationConfig").TranslationConfig;
15521
15521
  fields: ({
15522
15522
  config: {
15523
- type: "exact" | "fuzzy" | "range";
15523
+ type: "exact" | "fuzzy" | "range" | "within";
15524
15524
  };
15525
15525
  fieldId: string;
15526
15526
  fieldType: "field";
@@ -15547,7 +15547,7 @@ export declare function getEventConfigById(eventConfigs: EventConfig[], id: stri
15547
15547
  excludeInSearchQuery?: boolean | undefined;
15548
15548
  } | {
15549
15549
  config: {
15550
- type: "exact" | "fuzzy" | "range";
15550
+ type: "exact" | "fuzzy" | "range" | "within";
15551
15551
  };
15552
15552
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
15553
15553
  fieldType: "event";
@@ -1340,7 +1340,7 @@ var SummaryConfig = import_zod14.z.object({
1340
1340
 
1341
1341
  // ../commons/src/events/AdvancedSearchConfig.ts
1342
1342
  var import_zod15 = require("zod");
1343
- var MatchType = import_zod15.z.enum(["fuzzy", "exact", "range"]);
1343
+ var MatchType = import_zod15.z.enum(["fuzzy", "exact", "range", "within"]);
1344
1344
  var BaseField3 = import_zod15.z.object({
1345
1345
  config: import_zod15.z.object({
1346
1346
  type: MatchType.describe("Determines the type of field")
@@ -3175,6 +3175,19 @@ function createSearchConfig(baseField) {
3175
3175
  fuzzy: () => ({
3176
3176
  ...baseField,
3177
3177
  config: { type: "fuzzy" }
3178
+ }),
3179
+ /**
3180
+ * Creates a configuration for matching locations and the child locations
3181
+ * @returns An object containing the field ID and a configuration object with a type of 'within'.
3182
+ * @example field('createdAtLocation').within()
3183
+ * // {
3184
+ * // ...
3185
+ * // config: { type: 'within' }
3186
+ * // }
3187
+ */
3188
+ within: () => ({
3189
+ ...baseField,
3190
+ config: { type: "within" }
3178
3191
  })
3179
3192
  };
3180
3193
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@opencrvs/toolkit",
3
- "version": "1.8.1-rc.be16155",
3
+ "version": "1.8.1-rc.d31fe05",
4
4
  "description": "OpenCRVS toolkit for building country configurations",
5
5
  "license": "MPL-2.0",
6
6
  "exports": {