@opencrvs/toolkit 1.9.6-rc.3c3bfa8 → 1.9.6-rc.3f7d879
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/dist/commons/events/FieldConfig.d.ts +6 -44
- package/dist/commons/events/FieldValue.d.ts +1 -0
- package/dist/commons/events/TemplateConfig.d.ts +0 -2
- package/dist/conditionals/index.js +2 -8
- package/dist/events/index.js +25 -31
- package/dist/notification/index.js +25 -30
- package/package.json +1 -1
|
@@ -1768,21 +1768,7 @@ declare const DateField: z.ZodObject<z.objectUtil.extendShape<{
|
|
|
1768
1768
|
analytics: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
|
|
1769
1769
|
}, {
|
|
1770
1770
|
type: z.ZodLiteral<"DATE">;
|
|
1771
|
-
defaultValue: z.ZodOptional<z.ZodUnion<[z.
|
|
1772
|
-
$$date: z.ZodLiteral<"now">;
|
|
1773
|
-
$$time: z.ZodLiteral<"now">;
|
|
1774
|
-
}, "strip", z.ZodTypeAny, {
|
|
1775
|
-
$$date: "now";
|
|
1776
|
-
$$time: "now";
|
|
1777
|
-
}, {
|
|
1778
|
-
$$date: "now";
|
|
1779
|
-
$$time: "now";
|
|
1780
|
-
}>, {
|
|
1781
|
-
$$date: "now";
|
|
1782
|
-
}, {
|
|
1783
|
-
$$date: "now";
|
|
1784
|
-
$$time: "now";
|
|
1785
|
-
}>, z.ZodString]>>;
|
|
1771
|
+
defaultValue: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<"$$now">, z.ZodString]>>;
|
|
1786
1772
|
configuration: z.ZodOptional<z.ZodObject<{
|
|
1787
1773
|
notice: z.ZodOptional<z.ZodObject<import("./TranslationConfig").MessageDescriptorZod, "strip", z.ZodTypeAny, TranslationConfig, {
|
|
1788
1774
|
id: string;
|
|
@@ -1839,9 +1825,7 @@ declare const DateField: z.ZodObject<z.objectUtil.extendShape<{
|
|
|
1839
1825
|
hideLabel?: boolean | undefined;
|
|
1840
1826
|
uncorrectable?: boolean | undefined;
|
|
1841
1827
|
analytics?: boolean | undefined;
|
|
1842
|
-
defaultValue?: string |
|
|
1843
|
-
$$date: "now";
|
|
1844
|
-
} | undefined;
|
|
1828
|
+
defaultValue?: string | undefined;
|
|
1845
1829
|
configuration?: {
|
|
1846
1830
|
notice?: TranslationConfig | undefined;
|
|
1847
1831
|
} | undefined;
|
|
@@ -1906,10 +1890,7 @@ declare const DateField: z.ZodObject<z.objectUtil.extendShape<{
|
|
|
1906
1890
|
hideLabel?: boolean | undefined;
|
|
1907
1891
|
uncorrectable?: boolean | undefined;
|
|
1908
1892
|
analytics?: boolean | undefined;
|
|
1909
|
-
defaultValue?: string |
|
|
1910
|
-
$$date: "now";
|
|
1911
|
-
$$time: "now";
|
|
1912
|
-
} | undefined;
|
|
1893
|
+
defaultValue?: string | undefined;
|
|
1913
1894
|
configuration?: {
|
|
1914
1895
|
notice?: {
|
|
1915
1896
|
id: string;
|
|
@@ -2284,21 +2265,7 @@ declare const TimeField: z.ZodObject<z.objectUtil.extendShape<{
|
|
|
2284
2265
|
analytics: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
|
|
2285
2266
|
}, {
|
|
2286
2267
|
type: z.ZodLiteral<"TIME">;
|
|
2287
|
-
defaultValue: z.ZodOptional<z.ZodUnion<[z.
|
|
2288
|
-
$$date: z.ZodLiteral<"now">;
|
|
2289
|
-
$$time: z.ZodLiteral<"now">;
|
|
2290
|
-
}, "strip", z.ZodTypeAny, {
|
|
2291
|
-
$$date: "now";
|
|
2292
|
-
$$time: "now";
|
|
2293
|
-
}, {
|
|
2294
|
-
$$date: "now";
|
|
2295
|
-
$$time: "now";
|
|
2296
|
-
}>, {
|
|
2297
|
-
$$time: "now";
|
|
2298
|
-
}, {
|
|
2299
|
-
$$date: "now";
|
|
2300
|
-
$$time: "now";
|
|
2301
|
-
}>, z.ZodString]>>;
|
|
2268
|
+
defaultValue: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<"$$now">, z.ZodString]>>;
|
|
2302
2269
|
configuration: z.ZodOptional<z.ZodObject<{
|
|
2303
2270
|
use12HourFormat: z.ZodOptional<z.ZodBoolean>;
|
|
2304
2271
|
notice: z.ZodOptional<z.ZodObject<import("./TranslationConfig").MessageDescriptorZod, "strip", z.ZodTypeAny, TranslationConfig, {
|
|
@@ -2358,9 +2325,7 @@ declare const TimeField: z.ZodObject<z.objectUtil.extendShape<{
|
|
|
2358
2325
|
hideLabel?: boolean | undefined;
|
|
2359
2326
|
uncorrectable?: boolean | undefined;
|
|
2360
2327
|
analytics?: boolean | undefined;
|
|
2361
|
-
defaultValue?: string |
|
|
2362
|
-
$$time: "now";
|
|
2363
|
-
} | undefined;
|
|
2328
|
+
defaultValue?: string | undefined;
|
|
2364
2329
|
configuration?: {
|
|
2365
2330
|
notice?: TranslationConfig | undefined;
|
|
2366
2331
|
use12HourFormat?: boolean | undefined;
|
|
@@ -2426,10 +2391,7 @@ declare const TimeField: z.ZodObject<z.objectUtil.extendShape<{
|
|
|
2426
2391
|
hideLabel?: boolean | undefined;
|
|
2427
2392
|
uncorrectable?: boolean | undefined;
|
|
2428
2393
|
analytics?: boolean | undefined;
|
|
2429
|
-
defaultValue?: string |
|
|
2430
|
-
$$date: "now";
|
|
2431
|
-
$$time: "now";
|
|
2432
|
-
} | undefined;
|
|
2394
|
+
defaultValue?: string | undefined;
|
|
2433
2395
|
configuration?: {
|
|
2434
2396
|
notice?: {
|
|
2435
2397
|
id: string;
|
|
@@ -38,6 +38,7 @@ export declare const AgeUpdateValue: z.ZodNullable<z.ZodOptional<z.ZodObject<{
|
|
|
38
38
|
asOfDateRef: string;
|
|
39
39
|
}>>>;
|
|
40
40
|
export declare const TimeValue: z.ZodString;
|
|
41
|
+
export type TimeValue = z.infer<typeof TimeValue>;
|
|
41
42
|
export declare const DatetimeValue: z.ZodString;
|
|
42
43
|
export declare const SelectDateRangeValue: z.ZodEnum<["last7Days", "last30Days", "last90Days", "last365Days"]>;
|
|
43
44
|
export declare const DateRangeFieldValue: z.ZodUnion<[z.ZodObject<{
|
|
@@ -109,15 +109,9 @@ function omitKeyDeep(obj, keyToRemove) {
|
|
|
109
109
|
|
|
110
110
|
// ../commons/src/events/serializers/date/serializer.ts
|
|
111
111
|
var import_zod2 = require("zod");
|
|
112
|
-
var SerializedNowDateTime = import_zod2.z.
|
|
113
|
-
$$date: import_zod2.z.literal("now"),
|
|
114
|
-
$$time: import_zod2.z.literal("now")
|
|
115
|
-
});
|
|
112
|
+
var SerializedNowDateTime = import_zod2.z.literal("$$now");
|
|
116
113
|
function todayDateTimeValueSerializer() {
|
|
117
|
-
return
|
|
118
|
-
$$date: "now",
|
|
119
|
-
$$time: "now"
|
|
120
|
-
};
|
|
114
|
+
return "$$now";
|
|
121
115
|
}
|
|
122
116
|
|
|
123
117
|
// ../commons/src/conditionals/conditionals.ts
|
package/dist/events/index.js
CHANGED
|
@@ -1908,15 +1908,9 @@ var SearchScopeAccessLevels = {
|
|
|
1908
1908
|
|
|
1909
1909
|
// ../commons/src/events/serializers/date/serializer.ts
|
|
1910
1910
|
var import_zod15 = require("zod");
|
|
1911
|
-
var SerializedNowDateTime = import_zod15.z.
|
|
1912
|
-
$$date: import_zod15.z.literal("now"),
|
|
1913
|
-
$$time: import_zod15.z.literal("now")
|
|
1914
|
-
});
|
|
1911
|
+
var SerializedNowDateTime = import_zod15.z.literal("$$now");
|
|
1915
1912
|
function todayDateTimeValueSerializer() {
|
|
1916
|
-
return
|
|
1917
|
-
$$date: "now",
|
|
1918
|
-
$$time: "now"
|
|
1919
|
-
};
|
|
1913
|
+
return "$$now";
|
|
1920
1914
|
}
|
|
1921
1915
|
|
|
1922
1916
|
// ../commons/src/events/FieldConfig.ts
|
|
@@ -2052,9 +2046,7 @@ var EmailField = BaseField.extend({
|
|
|
2052
2046
|
});
|
|
2053
2047
|
var DateField = BaseField.extend({
|
|
2054
2048
|
type: import_zod16.z.literal(FieldType.DATE),
|
|
2055
|
-
defaultValue: SerializedNowDateTime.
|
|
2056
|
-
$$date: "now"
|
|
2057
|
-
})).or(DateValue).optional().openapi({ effectType: "input", type: "string" }).describe("A single time input (HH-mm)"),
|
|
2049
|
+
defaultValue: SerializedNowDateTime.or(DateValue).optional().openapi({ effectType: "input", type: "string" }).describe("Default date value(yyyy-MM-dd)"),
|
|
2058
2050
|
configuration: import_zod16.z.object({
|
|
2059
2051
|
notice: TranslationConfig.describe(
|
|
2060
2052
|
"Text to display above the date input"
|
|
@@ -2072,9 +2064,7 @@ var AgeField = BaseField.extend({
|
|
|
2072
2064
|
}).describe("An age input field which uses the current date as the asOfDate");
|
|
2073
2065
|
var TimeField = BaseField.extend({
|
|
2074
2066
|
type: import_zod16.z.literal(FieldType.TIME),
|
|
2075
|
-
defaultValue: SerializedNowDateTime.
|
|
2076
|
-
$$time: "now"
|
|
2077
|
-
})).or(TimeValue).optional().openapi({ effectType: "input", type: "string" }).describe("A single time input (HH-mm)"),
|
|
2067
|
+
defaultValue: SerializedNowDateTime.or(TimeValue).optional().openapi({ effectType: "input", type: "object" }).describe("Default time value (HH-mm)"),
|
|
2078
2068
|
configuration: import_zod16.z.object({
|
|
2079
2069
|
use12HourFormat: import_zod16.z.boolean().optional().describe("Whether to use 12-hour format"),
|
|
2080
2070
|
notice: TranslationConfig.describe(
|
|
@@ -5714,7 +5704,7 @@ function field(fieldId, options = {}) {
|
|
|
5714
5704
|
|
|
5715
5705
|
// ../commons/src/fixtures/forms.ts
|
|
5716
5706
|
var import_date_fns3 = require("date-fns");
|
|
5717
|
-
var PRINT_CERTIFICATE_FORM = {
|
|
5707
|
+
var PRINT_CERTIFICATE_FORM = defineActionForm({
|
|
5718
5708
|
label: {
|
|
5719
5709
|
id: "event.tennis-club-membership.action.certificate.form.label",
|
|
5720
5710
|
defaultMessage: "Tennis club membership certificate collector",
|
|
@@ -6370,7 +6360,7 @@ var PRINT_CERTIFICATE_FORM = {
|
|
|
6370
6360
|
}
|
|
6371
6361
|
}
|
|
6372
6362
|
]
|
|
6373
|
-
};
|
|
6363
|
+
});
|
|
6374
6364
|
var TENNIS_CLUB_DECLARATION_REVIEW = {
|
|
6375
6365
|
title: {
|
|
6376
6366
|
id: "event.tennis-club-membership.action.declare.form.review.title",
|
|
@@ -6415,7 +6405,7 @@ function isDomesticAddress() {
|
|
|
6415
6405
|
field("addressType").isEqualTo(AddressType.DOMESTIC)
|
|
6416
6406
|
);
|
|
6417
6407
|
}
|
|
6418
|
-
var TENNIS_CLUB_DECLARATION_FORM = {
|
|
6408
|
+
var TENNIS_CLUB_DECLARATION_FORM = defineDeclarationForm({
|
|
6419
6409
|
label: {
|
|
6420
6410
|
id: "event.tennis-club-membership.action.declare.form.label",
|
|
6421
6411
|
defaultMessage: "Tennis club membership application",
|
|
@@ -6900,7 +6890,7 @@ var TENNIS_CLUB_DECLARATION_FORM = {
|
|
|
6900
6890
|
// Intentional always-true page conditional to exercise interactions between page-level and field-level conditionals in tests
|
|
6901
6891
|
}
|
|
6902
6892
|
]
|
|
6903
|
-
};
|
|
6893
|
+
});
|
|
6904
6894
|
var statusOptions = [
|
|
6905
6895
|
{
|
|
6906
6896
|
value: "ALL",
|
|
@@ -7709,7 +7699,7 @@ var footballClubMembershipEvent = defineConfig({
|
|
|
7709
7699
|
});
|
|
7710
7700
|
|
|
7711
7701
|
// ../commons/src/fixtures/library-membership-event.ts
|
|
7712
|
-
var libraryMembershipForm = {
|
|
7702
|
+
var libraryMembershipForm = defineDeclarationForm({
|
|
7713
7703
|
label: {
|
|
7714
7704
|
id: "event.library-membership.action.declare.form.label",
|
|
7715
7705
|
defaultMessage: "Library membership application",
|
|
@@ -7749,7 +7739,7 @@ var libraryMembershipForm = {
|
|
|
7749
7739
|
]
|
|
7750
7740
|
}
|
|
7751
7741
|
]
|
|
7752
|
-
};
|
|
7742
|
+
});
|
|
7753
7743
|
var libraryMembershipEvent = defineConfig({
|
|
7754
7744
|
id: "library-membership",
|
|
7755
7745
|
label: {
|
|
@@ -7775,7 +7765,7 @@ function generateTranslationConfig(message) {
|
|
|
7775
7765
|
id: message
|
|
7776
7766
|
};
|
|
7777
7767
|
}
|
|
7778
|
-
var child = {
|
|
7768
|
+
var child = defineFormPage({
|
|
7779
7769
|
id: "child",
|
|
7780
7770
|
type: PageTypes.enum.FORM,
|
|
7781
7771
|
title: generateTranslationConfig("Child's details"),
|
|
@@ -7798,8 +7788,8 @@ var child = {
|
|
|
7798
7788
|
label: generateTranslationConfig("Date of birth")
|
|
7799
7789
|
}
|
|
7800
7790
|
]
|
|
7801
|
-
};
|
|
7802
|
-
var mother = {
|
|
7791
|
+
});
|
|
7792
|
+
var mother = defineFormPage({
|
|
7803
7793
|
id: "mother",
|
|
7804
7794
|
type: PageTypes.enum.FORM,
|
|
7805
7795
|
title: generateTranslationConfig("Mother's details"),
|
|
@@ -7871,7 +7861,7 @@ var mother = {
|
|
|
7871
7861
|
validation: []
|
|
7872
7862
|
}
|
|
7873
7863
|
]
|
|
7874
|
-
};
|
|
7864
|
+
});
|
|
7875
7865
|
var BIRTH_DECLARATION_REVIEW = {
|
|
7876
7866
|
title: generateTranslationConfig(
|
|
7877
7867
|
"{child.name.firstname, select, __EMPTY__ {Birth declaration} other {{child.name.surname, select, __EMPTY__ {Birth declaration for {child.name.firstname}} other {Birth declaration for {child.name.firstname} {child.name.surname}}}}}"
|
|
@@ -7892,10 +7882,10 @@ var BIRTH_DECLARATION_REVIEW = {
|
|
|
7892
7882
|
}
|
|
7893
7883
|
]
|
|
7894
7884
|
};
|
|
7895
|
-
var BIRTH_DECLARATION_FORM = {
|
|
7885
|
+
var BIRTH_DECLARATION_FORM = defineDeclarationForm({
|
|
7896
7886
|
label: generateTranslationConfig("Birth decalration form"),
|
|
7897
7887
|
pages: [child, mother]
|
|
7898
|
-
};
|
|
7888
|
+
});
|
|
7899
7889
|
var v2BirthEvent = defineConfig({
|
|
7900
7890
|
id: BIRTH_EVENT,
|
|
7901
7891
|
title: generateTranslationConfig(
|
|
@@ -7932,7 +7922,7 @@ var v2BirthEvent = defineConfig({
|
|
|
7932
7922
|
});
|
|
7933
7923
|
|
|
7934
7924
|
// ../commons/src/fixtures/digital-identity-issuance-event.ts
|
|
7935
|
-
var PRINT_DIGITAL_ID_CERTIFICATE_FORM = {
|
|
7925
|
+
var PRINT_DIGITAL_ID_CERTIFICATE_FORM = defineActionForm({
|
|
7936
7926
|
label: {
|
|
7937
7927
|
id: "event.digital-identity.action.certificate.form.label",
|
|
7938
7928
|
defaultMessage: "Digital identity certificate printer",
|
|
@@ -8076,8 +8066,8 @@ var PRINT_DIGITAL_ID_CERTIFICATE_FORM = {
|
|
|
8076
8066
|
]
|
|
8077
8067
|
}
|
|
8078
8068
|
]
|
|
8079
|
-
};
|
|
8080
|
-
var digitalIdentityForm = {
|
|
8069
|
+
});
|
|
8070
|
+
var digitalIdentityForm = defineDeclarationForm({
|
|
8081
8071
|
label: {
|
|
8082
8072
|
id: "event.digital-identity.action.declare.form.label",
|
|
8083
8073
|
defaultMessage: "Digital identity issuance",
|
|
@@ -8117,7 +8107,7 @@ var digitalIdentityForm = {
|
|
|
8117
8107
|
]
|
|
8118
8108
|
}
|
|
8119
8109
|
]
|
|
8120
|
-
};
|
|
8110
|
+
});
|
|
8121
8111
|
var digitalIdentityEvent = defineConfig({
|
|
8122
8112
|
id: "digital-identity",
|
|
8123
8113
|
label: {
|
|
@@ -8897,8 +8887,12 @@ var window2 = () => ({
|
|
|
8897
8887
|
}
|
|
8898
8888
|
}
|
|
8899
8889
|
});
|
|
8890
|
+
var KNOWN_SYSTEM_KEYS = ["$$date", "$$time"];
|
|
8900
8891
|
function isTemplateVariable(value) {
|
|
8901
|
-
|
|
8892
|
+
if (typeof value === "string" && KNOWN_SYSTEM_KEYS.includes(value)) {
|
|
8893
|
+
return true;
|
|
8894
|
+
}
|
|
8895
|
+
return false;
|
|
8902
8896
|
}
|
|
8903
8897
|
function isFieldValue(value) {
|
|
8904
8898
|
return FieldValue.safeParse(value).success;
|
|
@@ -1430,15 +1430,9 @@ var SearchQuery = import_zod14.z.object({
|
|
|
1430
1430
|
|
|
1431
1431
|
// ../commons/src/events/serializers/date/serializer.ts
|
|
1432
1432
|
var import_zod15 = require("zod");
|
|
1433
|
-
var SerializedNowDateTime = import_zod15.z.
|
|
1434
|
-
$$date: import_zod15.z.literal("now"),
|
|
1435
|
-
$$time: import_zod15.z.literal("now")
|
|
1436
|
-
});
|
|
1433
|
+
var SerializedNowDateTime = import_zod15.z.literal("$$now");
|
|
1437
1434
|
function todayDateTimeValueSerializer() {
|
|
1438
|
-
return
|
|
1439
|
-
$$date: "now",
|
|
1440
|
-
$$time: "now"
|
|
1441
|
-
};
|
|
1435
|
+
return "$$now";
|
|
1442
1436
|
}
|
|
1443
1437
|
|
|
1444
1438
|
// ../commons/src/events/FieldConfig.ts
|
|
@@ -1574,9 +1568,7 @@ var EmailField = BaseField.extend({
|
|
|
1574
1568
|
});
|
|
1575
1569
|
var DateField = BaseField.extend({
|
|
1576
1570
|
type: import_zod16.z.literal(FieldType.DATE),
|
|
1577
|
-
defaultValue: SerializedNowDateTime.
|
|
1578
|
-
$$date: "now"
|
|
1579
|
-
})).or(DateValue).optional().openapi({ effectType: "input", type: "string" }).describe("A single time input (HH-mm)"),
|
|
1571
|
+
defaultValue: SerializedNowDateTime.or(DateValue).optional().openapi({ effectType: "input", type: "string" }).describe("Default date value(yyyy-MM-dd)"),
|
|
1580
1572
|
configuration: import_zod16.z.object({
|
|
1581
1573
|
notice: TranslationConfig.describe(
|
|
1582
1574
|
"Text to display above the date input"
|
|
@@ -1594,9 +1586,7 @@ var AgeField = BaseField.extend({
|
|
|
1594
1586
|
}).describe("An age input field which uses the current date as the asOfDate");
|
|
1595
1587
|
var TimeField = BaseField.extend({
|
|
1596
1588
|
type: import_zod16.z.literal(FieldType.TIME),
|
|
1597
|
-
defaultValue: SerializedNowDateTime.
|
|
1598
|
-
$$time: "now"
|
|
1599
|
-
})).or(TimeValue).optional().openapi({ effectType: "input", type: "string" }).describe("A single time input (HH-mm)"),
|
|
1589
|
+
defaultValue: SerializedNowDateTime.or(TimeValue).optional().openapi({ effectType: "input", type: "object" }).describe("Default time value (HH-mm)"),
|
|
1600
1590
|
configuration: import_zod16.z.object({
|
|
1601
1591
|
use12HourFormat: import_zod16.z.boolean().optional().describe("Whether to use 12-hour format"),
|
|
1602
1592
|
notice: TranslationConfig.describe(
|
|
@@ -2699,6 +2689,11 @@ var EventConfig = import_zod27.z.object({
|
|
|
2699
2689
|
ref: "EventConfig"
|
|
2700
2690
|
}).describe("Configuration defining an event type.");
|
|
2701
2691
|
|
|
2692
|
+
// ../commons/src/events/EventConfigInput.ts
|
|
2693
|
+
var defineDeclarationForm = (form) => DeclarationFormConfig.parse(form);
|
|
2694
|
+
var defineActionForm = (actionForm) => ActionFormConfig.parse(actionForm);
|
|
2695
|
+
var defineFormPage = (formPage) => FormPageConfig.parse(formPage);
|
|
2696
|
+
|
|
2702
2697
|
// ../commons/src/events/WorkqueueConfig.ts
|
|
2703
2698
|
var import_zod31 = require("zod");
|
|
2704
2699
|
|
|
@@ -3962,7 +3957,7 @@ function field(fieldId, options = {}) {
|
|
|
3962
3957
|
|
|
3963
3958
|
// ../commons/src/fixtures/forms.ts
|
|
3964
3959
|
var import_date_fns3 = require("date-fns");
|
|
3965
|
-
var PRINT_CERTIFICATE_FORM = {
|
|
3960
|
+
var PRINT_CERTIFICATE_FORM = defineActionForm({
|
|
3966
3961
|
label: {
|
|
3967
3962
|
id: "event.tennis-club-membership.action.certificate.form.label",
|
|
3968
3963
|
defaultMessage: "Tennis club membership certificate collector",
|
|
@@ -4618,7 +4613,7 @@ var PRINT_CERTIFICATE_FORM = {
|
|
|
4618
4613
|
}
|
|
4619
4614
|
}
|
|
4620
4615
|
]
|
|
4621
|
-
};
|
|
4616
|
+
});
|
|
4622
4617
|
var TENNIS_CLUB_DECLARATION_REVIEW = {
|
|
4623
4618
|
title: {
|
|
4624
4619
|
id: "event.tennis-club-membership.action.declare.form.review.title",
|
|
@@ -4663,7 +4658,7 @@ function isDomesticAddress() {
|
|
|
4663
4658
|
field("addressType").isEqualTo(AddressType.DOMESTIC)
|
|
4664
4659
|
);
|
|
4665
4660
|
}
|
|
4666
|
-
var TENNIS_CLUB_DECLARATION_FORM = {
|
|
4661
|
+
var TENNIS_CLUB_DECLARATION_FORM = defineDeclarationForm({
|
|
4667
4662
|
label: {
|
|
4668
4663
|
id: "event.tennis-club-membership.action.declare.form.label",
|
|
4669
4664
|
defaultMessage: "Tennis club membership application",
|
|
@@ -5148,7 +5143,7 @@ var TENNIS_CLUB_DECLARATION_FORM = {
|
|
|
5148
5143
|
// Intentional always-true page conditional to exercise interactions between page-level and field-level conditionals in tests
|
|
5149
5144
|
}
|
|
5150
5145
|
]
|
|
5151
|
-
};
|
|
5146
|
+
});
|
|
5152
5147
|
var statusOptions = [
|
|
5153
5148
|
{
|
|
5154
5149
|
value: "ALL",
|
|
@@ -5957,7 +5952,7 @@ var footballClubMembershipEvent = defineConfig({
|
|
|
5957
5952
|
});
|
|
5958
5953
|
|
|
5959
5954
|
// ../commons/src/fixtures/library-membership-event.ts
|
|
5960
|
-
var libraryMembershipForm = {
|
|
5955
|
+
var libraryMembershipForm = defineDeclarationForm({
|
|
5961
5956
|
label: {
|
|
5962
5957
|
id: "event.library-membership.action.declare.form.label",
|
|
5963
5958
|
defaultMessage: "Library membership application",
|
|
@@ -5997,7 +5992,7 @@ var libraryMembershipForm = {
|
|
|
5997
5992
|
]
|
|
5998
5993
|
}
|
|
5999
5994
|
]
|
|
6000
|
-
};
|
|
5995
|
+
});
|
|
6001
5996
|
var libraryMembershipEvent = defineConfig({
|
|
6002
5997
|
id: "library-membership",
|
|
6003
5998
|
label: {
|
|
@@ -6023,7 +6018,7 @@ function generateTranslationConfig(message) {
|
|
|
6023
6018
|
id: message
|
|
6024
6019
|
};
|
|
6025
6020
|
}
|
|
6026
|
-
var child = {
|
|
6021
|
+
var child = defineFormPage({
|
|
6027
6022
|
id: "child",
|
|
6028
6023
|
type: PageTypes.enum.FORM,
|
|
6029
6024
|
title: generateTranslationConfig("Child's details"),
|
|
@@ -6046,8 +6041,8 @@ var child = {
|
|
|
6046
6041
|
label: generateTranslationConfig("Date of birth")
|
|
6047
6042
|
}
|
|
6048
6043
|
]
|
|
6049
|
-
};
|
|
6050
|
-
var mother = {
|
|
6044
|
+
});
|
|
6045
|
+
var mother = defineFormPage({
|
|
6051
6046
|
id: "mother",
|
|
6052
6047
|
type: PageTypes.enum.FORM,
|
|
6053
6048
|
title: generateTranslationConfig("Mother's details"),
|
|
@@ -6119,7 +6114,7 @@ var mother = {
|
|
|
6119
6114
|
validation: []
|
|
6120
6115
|
}
|
|
6121
6116
|
]
|
|
6122
|
-
};
|
|
6117
|
+
});
|
|
6123
6118
|
var BIRTH_DECLARATION_REVIEW = {
|
|
6124
6119
|
title: generateTranslationConfig(
|
|
6125
6120
|
"{child.name.firstname, select, __EMPTY__ {Birth declaration} other {{child.name.surname, select, __EMPTY__ {Birth declaration for {child.name.firstname}} other {Birth declaration for {child.name.firstname} {child.name.surname}}}}}"
|
|
@@ -6140,10 +6135,10 @@ var BIRTH_DECLARATION_REVIEW = {
|
|
|
6140
6135
|
}
|
|
6141
6136
|
]
|
|
6142
6137
|
};
|
|
6143
|
-
var BIRTH_DECLARATION_FORM = {
|
|
6138
|
+
var BIRTH_DECLARATION_FORM = defineDeclarationForm({
|
|
6144
6139
|
label: generateTranslationConfig("Birth decalration form"),
|
|
6145
6140
|
pages: [child, mother]
|
|
6146
|
-
};
|
|
6141
|
+
});
|
|
6147
6142
|
var v2BirthEvent = defineConfig({
|
|
6148
6143
|
id: BIRTH_EVENT,
|
|
6149
6144
|
title: generateTranslationConfig(
|
|
@@ -6180,7 +6175,7 @@ var v2BirthEvent = defineConfig({
|
|
|
6180
6175
|
});
|
|
6181
6176
|
|
|
6182
6177
|
// ../commons/src/fixtures/digital-identity-issuance-event.ts
|
|
6183
|
-
var PRINT_DIGITAL_ID_CERTIFICATE_FORM = {
|
|
6178
|
+
var PRINT_DIGITAL_ID_CERTIFICATE_FORM = defineActionForm({
|
|
6184
6179
|
label: {
|
|
6185
6180
|
id: "event.digital-identity.action.certificate.form.label",
|
|
6186
6181
|
defaultMessage: "Digital identity certificate printer",
|
|
@@ -6324,8 +6319,8 @@ var PRINT_DIGITAL_ID_CERTIFICATE_FORM = {
|
|
|
6324
6319
|
]
|
|
6325
6320
|
}
|
|
6326
6321
|
]
|
|
6327
|
-
};
|
|
6328
|
-
var digitalIdentityForm = {
|
|
6322
|
+
});
|
|
6323
|
+
var digitalIdentityForm = defineDeclarationForm({
|
|
6329
6324
|
label: {
|
|
6330
6325
|
id: "event.digital-identity.action.declare.form.label",
|
|
6331
6326
|
defaultMessage: "Digital identity issuance",
|
|
@@ -6365,7 +6360,7 @@ var digitalIdentityForm = {
|
|
|
6365
6360
|
]
|
|
6366
6361
|
}
|
|
6367
6362
|
]
|
|
6368
|
-
};
|
|
6363
|
+
});
|
|
6369
6364
|
var digitalIdentityEvent = defineConfig({
|
|
6370
6365
|
id: "digital-identity",
|
|
6371
6366
|
label: {
|