@opencrvs/toolkit 1.8.0-rc.f7910f3 → 1.8.0-rc.f876361

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.
@@ -70,6 +70,10 @@ export declare const event: {
70
70
  *
71
71
  */
72
72
  export declare function field(fieldId: string): {
73
+ /**
74
+ * @private Internal property used for field reference tracking.
75
+ */
76
+ _returning: string;
73
77
  isAfter: () => {
74
78
  days: (days: number) => {
75
79
  inPast: () => JSONSchema;
@@ -86,7 +90,10 @@ export declare function field(fieldId: string): {
86
90
  date: (date: string) => JSONSchema;
87
91
  now: () => JSONSchema;
88
92
  };
89
- isEqualTo: (value: string | boolean) => JSONSchema;
93
+ isEqualTo: (value: string | boolean | {
94
+ _returning: string;
95
+ [key: string]: unknown;
96
+ }) => JSONSchema;
90
97
  /**
91
98
  * Use case: Some fields are rendered when selection is not made, or boolean false is explicitly selected.
92
99
  * @example field('recommender.none').isFalsy() vs not(field('recommender.none').isEqualTo(true))
@@ -99,6 +106,14 @@ export declare function field(fieldId: string): {
99
106
  isUndefined: () => JSONSchema;
100
107
  inArray: (values: string[]) => JSONSchema;
101
108
  isValidEnglishName: () => JSONSchema;
109
+ isValidNationalId: () => JSONSchema;
110
+ /**
111
+ * Checks if the field value matches a given regular expression pattern.
112
+ * @param pattern - The regular expression pattern to match the field value against.
113
+ * @returns A JSONSchema conditional that validates the field value against the pattern.
114
+ */
115
+ matches: (pattern: string) => JSONSchema;
116
+ isBetween: (min: number, max: number) => JSONSchema;
102
117
  };
103
118
  export {};
104
119
  //# sourceMappingURL=conditionals.d.ts.map