@opencrvs/toolkit 1.9.12-rc.d350fab → 1.9.12-rc.f1e116d

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.
@@ -1688,7 +1688,8 @@ var File = BaseField.extend({
1688
1688
  }).describe("File upload");
1689
1689
  var SelectOption = import_zod17.z.object({
1690
1690
  value: import_zod17.z.string().describe("The value of the option"),
1691
- label: import_zod17.z.union([import_zod17.z.string(), TranslationConfig]).describe("The label of the option")
1691
+ label: import_zod17.z.union([import_zod17.z.string(), TranslationConfig]).describe("The label of the option"),
1692
+ conditionals: import_zod17.z.array(ActionConditional).default([]).optional()
1692
1693
  });
1693
1694
  var NumberWithUnitField = BaseField.extend({
1694
1695
  type: import_zod17.z.literal(FieldType.NUMBER_WITH_UNIT),
@@ -1839,12 +1840,19 @@ var Office = BaseField.extend({
1839
1840
  var DefaultAddressFieldValue = DomesticAddressFieldValue.extend({
1840
1841
  administrativeArea: import_zod17.z.union([UUID, SerializedUserField]).optional()
1841
1842
  });
1843
+ var DomesticAddressField = BaseField.pick({
1844
+ id: true,
1845
+ required: true,
1846
+ conditionals: true
1847
+ }).transform((config) => ({
1848
+ ...config,
1849
+ type: config.id === "country" ? FieldType.COUNTRY : FieldType.ADMINISTRATIVE_AREA
1850
+ })).openapi({ effectType: "input", type: "object" });
1842
1851
  var Address = BaseField.extend({
1843
1852
  type: import_zod17.z.literal(FieldType.ADDRESS),
1844
1853
  configuration: import_zod17.z.object({
1845
1854
  lineSeparator: import_zod17.z.string().optional(),
1846
- fields: import_zod17.z.array(import_zod17.z.enum(["country", "administrativeArea"])).optional(),
1847
- administrativeLevels: import_zod17.z.array(import_zod17.z.string()).optional(),
1855
+ fields: import_zod17.z.array(DomesticAddressField).optional(),
1848
1856
  streetAddressForm: import_zod17.z.array(
1849
1857
  import_zod17.z.object({
1850
1858
  id: import_zod17.z.string(),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@opencrvs/toolkit",
3
- "version": "1.9.12-rc.d350fab",
3
+ "version": "1.9.12-rc.f1e116d",
4
4
  "description": "OpenCRVS toolkit for building country configurations",
5
5
  "license": "MPL-2.0",
6
6
  "exports": {