@opencrvs/toolkit 2.0.1-rc.5803153 → 2.0.1-rc.68eb027
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/application-config/index.js +3 -1
- package/dist/cli.js +3 -1
- package/dist/commons/events/ActionConfig.d.ts +4 -0
- package/dist/commons/events/FormConfig.d.ts +6 -0
- package/dist/commons/events/PageConfig.d.ts +4 -0
- package/dist/commons/events/utils.d.ts +4 -0
- package/dist/conditionals/index.js +3 -1
- package/dist/events/index.js +7 -1
- package/dist/migrations/v2.0/index.js +3 -1
- package/dist/notification/index.js +7 -1
- package/dist/scopes/index.js +3 -1
- package/opencrvs-toolkit-2.0.1-rc.68eb027.tgz +0 -0
- package/package.json +1 -1
- package/opencrvs-toolkit-2.0.1-rc.5803153.tgz +0 -0
|
@@ -651,7 +651,9 @@ var PlainScopeType = z11.enum([
|
|
|
651
651
|
"performance.vital-statistics-export",
|
|
652
652
|
// Scopes used exclusively by countryconfig integration token
|
|
653
653
|
"record.confirm-registration",
|
|
654
|
-
"record.reject-registration"
|
|
654
|
+
"record.reject-registration",
|
|
655
|
+
// bootstrap: allows countryconfig to register integrations on startup
|
|
656
|
+
"integration.create"
|
|
655
657
|
]);
|
|
656
658
|
var scopeByEvent = z11.preprocess(
|
|
657
659
|
(val) => val === void 0 ? void 0 : [val].flat(),
|
package/dist/cli.js
CHANGED
|
@@ -2178,7 +2178,9 @@ var PlainScopeType = z3.enum([
|
|
|
2178
2178
|
"performance.vital-statistics-export",
|
|
2179
2179
|
// Scopes used exclusively by countryconfig integration token
|
|
2180
2180
|
"record.confirm-registration",
|
|
2181
|
-
"record.reject-registration"
|
|
2181
|
+
"record.reject-registration",
|
|
2182
|
+
// bootstrap: allows countryconfig to register integrations on startup
|
|
2183
|
+
"integration.create"
|
|
2182
2184
|
]);
|
|
2183
2185
|
var scopeByEvent = z3.preprocess(
|
|
2184
2186
|
(val) => val === void 0 ? void 0 : [val].flat(),
|
|
@@ -214,6 +214,7 @@ export declare const ActionConfig: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
214
214
|
id: z.ZodString;
|
|
215
215
|
title: z.ZodObject<import("./TranslationConfig").MessageDescriptorZod, z.core.$strip>;
|
|
216
216
|
requireCompletionToContinue: z.ZodDefault<z.ZodBoolean>;
|
|
217
|
+
showClearButton: z.ZodOptional<z.ZodBoolean>;
|
|
217
218
|
fields: z.ZodArray<z.ZodType<FieldConfig, import("./FieldConfig").FieldConfigInput, z.core.$ZodTypeInternals<FieldConfig, import("./FieldConfig").FieldConfigInput>>>;
|
|
218
219
|
conditional: z.ZodOptional<z.ZodAny>;
|
|
219
220
|
type: z.ZodDefault<z.ZodLiteral<"FORM">>;
|
|
@@ -221,6 +222,7 @@ export declare const ActionConfig: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
221
222
|
id: z.ZodString;
|
|
222
223
|
title: z.ZodObject<import("./TranslationConfig").MessageDescriptorZod, z.core.$strip>;
|
|
223
224
|
requireCompletionToContinue: z.ZodDefault<z.ZodBoolean>;
|
|
225
|
+
showClearButton: z.ZodOptional<z.ZodBoolean>;
|
|
224
226
|
fields: z.ZodArray<z.ZodType<FieldConfig, import("./FieldConfig").FieldConfigInput, z.core.$ZodTypeInternals<FieldConfig, import("./FieldConfig").FieldConfigInput>>>;
|
|
225
227
|
conditional: z.ZodOptional<z.ZodAny>;
|
|
226
228
|
type: z.ZodLiteral<"VERIFICATION">;
|
|
@@ -270,6 +272,7 @@ export declare const ActionConfig: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
270
272
|
id: z.ZodString;
|
|
271
273
|
title: z.ZodObject<import("./TranslationConfig").MessageDescriptorZod, z.core.$strip>;
|
|
272
274
|
requireCompletionToContinue: z.ZodDefault<z.ZodBoolean>;
|
|
275
|
+
showClearButton: z.ZodOptional<z.ZodBoolean>;
|
|
273
276
|
fields: z.ZodArray<z.ZodType<FieldConfig, import("./FieldConfig").FieldConfigInput, z.core.$ZodTypeInternals<FieldConfig, import("./FieldConfig").FieldConfigInput>>>;
|
|
274
277
|
conditional: z.ZodOptional<z.ZodAny>;
|
|
275
278
|
type: z.ZodDefault<z.ZodLiteral<"FORM">>;
|
|
@@ -277,6 +280,7 @@ export declare const ActionConfig: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
277
280
|
id: z.ZodString;
|
|
278
281
|
title: z.ZodObject<import("./TranslationConfig").MessageDescriptorZod, z.core.$strip>;
|
|
279
282
|
requireCompletionToContinue: z.ZodDefault<z.ZodBoolean>;
|
|
283
|
+
showClearButton: z.ZodOptional<z.ZodBoolean>;
|
|
280
284
|
fields: z.ZodArray<z.ZodType<FieldConfig, import("./FieldConfig").FieldConfigInput, z.core.$ZodTypeInternals<FieldConfig, import("./FieldConfig").FieldConfigInput>>>;
|
|
281
285
|
conditional: z.ZodOptional<z.ZodAny>;
|
|
282
286
|
type: z.ZodLiteral<"VERIFICATION">;
|
|
@@ -5,6 +5,7 @@ export declare const DeclarationFormConfig: z.ZodObject<{
|
|
|
5
5
|
id: z.ZodString;
|
|
6
6
|
title: z.ZodObject<import("./TranslationConfig").MessageDescriptorZod, z.core.$strip>;
|
|
7
7
|
requireCompletionToContinue: z.ZodDefault<z.ZodBoolean>;
|
|
8
|
+
showClearButton: z.ZodOptional<z.ZodBoolean>;
|
|
8
9
|
fields: z.ZodArray<z.ZodType<import("./FieldConfig").FieldConfig, import("./FieldConfig").FieldConfigInput, z.core.$ZodTypeInternals<import("./FieldConfig").FieldConfig, import("./FieldConfig").FieldConfigInput>>>;
|
|
9
10
|
conditional: z.ZodOptional<z.ZodAny>;
|
|
10
11
|
type: z.ZodDefault<z.ZodLiteral<"FORM">>;
|
|
@@ -18,6 +19,7 @@ export declare const ActionFormConfig: z.ZodObject<{
|
|
|
18
19
|
id: z.ZodString;
|
|
19
20
|
title: z.ZodObject<import("./TranslationConfig").MessageDescriptorZod, z.core.$strip>;
|
|
20
21
|
requireCompletionToContinue: z.ZodDefault<z.ZodBoolean>;
|
|
22
|
+
showClearButton: z.ZodOptional<z.ZodBoolean>;
|
|
21
23
|
fields: z.ZodArray<z.ZodType<import("./FieldConfig").FieldConfig, import("./FieldConfig").FieldConfigInput, z.core.$ZodTypeInternals<import("./FieldConfig").FieldConfig, import("./FieldConfig").FieldConfigInput>>>;
|
|
22
24
|
conditional: z.ZodOptional<z.ZodAny>;
|
|
23
25
|
type: z.ZodDefault<z.ZodLiteral<"FORM">>;
|
|
@@ -25,6 +27,7 @@ export declare const ActionFormConfig: z.ZodObject<{
|
|
|
25
27
|
id: z.ZodString;
|
|
26
28
|
title: z.ZodObject<import("./TranslationConfig").MessageDescriptorZod, z.core.$strip>;
|
|
27
29
|
requireCompletionToContinue: z.ZodDefault<z.ZodBoolean>;
|
|
30
|
+
showClearButton: z.ZodOptional<z.ZodBoolean>;
|
|
28
31
|
fields: z.ZodArray<z.ZodType<import("./FieldConfig").FieldConfig, import("./FieldConfig").FieldConfigInput, z.core.$ZodTypeInternals<import("./FieldConfig").FieldConfig, import("./FieldConfig").FieldConfigInput>>>;
|
|
29
32
|
conditional: z.ZodOptional<z.ZodAny>;
|
|
30
33
|
type: z.ZodLiteral<"VERIFICATION">;
|
|
@@ -50,6 +53,7 @@ export declare const FormConfig: z.ZodUnion<readonly [z.ZodObject<{
|
|
|
50
53
|
id: z.ZodString;
|
|
51
54
|
title: z.ZodObject<import("./TranslationConfig").MessageDescriptorZod, z.core.$strip>;
|
|
52
55
|
requireCompletionToContinue: z.ZodDefault<z.ZodBoolean>;
|
|
56
|
+
showClearButton: z.ZodOptional<z.ZodBoolean>;
|
|
53
57
|
fields: z.ZodArray<z.ZodType<import("./FieldConfig").FieldConfig, import("./FieldConfig").FieldConfigInput, z.core.$ZodTypeInternals<import("./FieldConfig").FieldConfig, import("./FieldConfig").FieldConfigInput>>>;
|
|
54
58
|
conditional: z.ZodOptional<z.ZodAny>;
|
|
55
59
|
type: z.ZodDefault<z.ZodLiteral<"FORM">>;
|
|
@@ -60,6 +64,7 @@ export declare const FormConfig: z.ZodUnion<readonly [z.ZodObject<{
|
|
|
60
64
|
id: z.ZodString;
|
|
61
65
|
title: z.ZodObject<import("./TranslationConfig").MessageDescriptorZod, z.core.$strip>;
|
|
62
66
|
requireCompletionToContinue: z.ZodDefault<z.ZodBoolean>;
|
|
67
|
+
showClearButton: z.ZodOptional<z.ZodBoolean>;
|
|
63
68
|
fields: z.ZodArray<z.ZodType<import("./FieldConfig").FieldConfig, import("./FieldConfig").FieldConfigInput, z.core.$ZodTypeInternals<import("./FieldConfig").FieldConfig, import("./FieldConfig").FieldConfigInput>>>;
|
|
64
69
|
conditional: z.ZodOptional<z.ZodAny>;
|
|
65
70
|
type: z.ZodDefault<z.ZodLiteral<"FORM">>;
|
|
@@ -67,6 +72,7 @@ export declare const FormConfig: z.ZodUnion<readonly [z.ZodObject<{
|
|
|
67
72
|
id: z.ZodString;
|
|
68
73
|
title: z.ZodObject<import("./TranslationConfig").MessageDescriptorZod, z.core.$strip>;
|
|
69
74
|
requireCompletionToContinue: z.ZodDefault<z.ZodBoolean>;
|
|
75
|
+
showClearButton: z.ZodOptional<z.ZodBoolean>;
|
|
70
76
|
fields: z.ZodArray<z.ZodType<import("./FieldConfig").FieldConfig, import("./FieldConfig").FieldConfigInput, z.core.$ZodTypeInternals<import("./FieldConfig").FieldConfig, import("./FieldConfig").FieldConfigInput>>>;
|
|
71
77
|
conditional: z.ZodOptional<z.ZodAny>;
|
|
72
78
|
type: z.ZodLiteral<"VERIFICATION">;
|
|
@@ -9,6 +9,7 @@ export declare const FormPageConfig: z.ZodObject<{
|
|
|
9
9
|
id: z.ZodString;
|
|
10
10
|
title: z.ZodObject<import("./TranslationConfig").MessageDescriptorZod, z.core.$strip>;
|
|
11
11
|
requireCompletionToContinue: z.ZodDefault<z.ZodBoolean>;
|
|
12
|
+
showClearButton: z.ZodOptional<z.ZodBoolean>;
|
|
12
13
|
fields: z.ZodArray<z.ZodType<FieldConfig, import("./FieldConfig").FieldConfigInput, z.core.$ZodTypeInternals<FieldConfig, import("./FieldConfig").FieldConfigInput>>>;
|
|
13
14
|
conditional: z.ZodOptional<z.ZodAny>;
|
|
14
15
|
type: z.ZodDefault<z.ZodLiteral<"FORM">>;
|
|
@@ -31,6 +32,7 @@ export declare const VerificationPageConfig: z.ZodObject<{
|
|
|
31
32
|
id: z.ZodString;
|
|
32
33
|
title: z.ZodObject<import("./TranslationConfig").MessageDescriptorZod, z.core.$strip>;
|
|
33
34
|
requireCompletionToContinue: z.ZodDefault<z.ZodBoolean>;
|
|
35
|
+
showClearButton: z.ZodOptional<z.ZodBoolean>;
|
|
34
36
|
fields: z.ZodArray<z.ZodType<FieldConfig, import("./FieldConfig").FieldConfigInput, z.core.$ZodTypeInternals<FieldConfig, import("./FieldConfig").FieldConfigInput>>>;
|
|
35
37
|
conditional: z.ZodOptional<z.ZodAny>;
|
|
36
38
|
type: z.ZodLiteral<"VERIFICATION">;
|
|
@@ -52,6 +54,7 @@ export declare const PageConfig: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
52
54
|
id: z.ZodString;
|
|
53
55
|
title: z.ZodObject<import("./TranslationConfig").MessageDescriptorZod, z.core.$strip>;
|
|
54
56
|
requireCompletionToContinue: z.ZodDefault<z.ZodBoolean>;
|
|
57
|
+
showClearButton: z.ZodOptional<z.ZodBoolean>;
|
|
55
58
|
fields: z.ZodArray<z.ZodType<FieldConfig, import("./FieldConfig").FieldConfigInput, z.core.$ZodTypeInternals<FieldConfig, import("./FieldConfig").FieldConfigInput>>>;
|
|
56
59
|
conditional: z.ZodOptional<z.ZodAny>;
|
|
57
60
|
type: z.ZodDefault<z.ZodLiteral<"FORM">>;
|
|
@@ -59,6 +62,7 @@ export declare const PageConfig: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
59
62
|
id: z.ZodString;
|
|
60
63
|
title: z.ZodObject<import("./TranslationConfig").MessageDescriptorZod, z.core.$strip>;
|
|
61
64
|
requireCompletionToContinue: z.ZodDefault<z.ZodBoolean>;
|
|
65
|
+
showClearButton: z.ZodOptional<z.ZodBoolean>;
|
|
62
66
|
fields: z.ZodArray<z.ZodType<FieldConfig, import("./FieldConfig").FieldConfigInput, z.core.$ZodTypeInternals<FieldConfig, import("./FieldConfig").FieldConfigInput>>>;
|
|
63
67
|
conditional: z.ZodOptional<z.ZodAny>;
|
|
64
68
|
type: z.ZodLiteral<"VERIFICATION">;
|
|
@@ -22,6 +22,7 @@ export declare function getDeclarationPages(configuration: EventConfig): {
|
|
|
22
22
|
requireCompletionToContinue: boolean;
|
|
23
23
|
fields: FieldConfig[];
|
|
24
24
|
type: "FORM";
|
|
25
|
+
showClearButton?: boolean | undefined;
|
|
25
26
|
conditional?: any;
|
|
26
27
|
}[];
|
|
27
28
|
export declare function getDeclaration(configuration: EventConfig): {
|
|
@@ -40,6 +41,7 @@ export declare function getDeclaration(configuration: EventConfig): {
|
|
|
40
41
|
requireCompletionToContinue: boolean;
|
|
41
42
|
fields: FieldConfig[];
|
|
42
43
|
type: "FORM";
|
|
44
|
+
showClearButton?: boolean | undefined;
|
|
43
45
|
conditional?: any;
|
|
44
46
|
}[];
|
|
45
47
|
};
|
|
@@ -60,6 +62,7 @@ export declare function getPrintCertificatePages(configuration: EventConfig): ({
|
|
|
60
62
|
requireCompletionToContinue: boolean;
|
|
61
63
|
fields: FieldConfig[];
|
|
62
64
|
type: "FORM";
|
|
65
|
+
showClearButton?: boolean | undefined;
|
|
63
66
|
conditional?: any;
|
|
64
67
|
} | {
|
|
65
68
|
id: string;
|
|
@@ -99,6 +102,7 @@ export declare function getPrintCertificatePages(configuration: EventConfig): ({
|
|
|
99
102
|
};
|
|
100
103
|
};
|
|
101
104
|
};
|
|
105
|
+
showClearButton?: boolean | undefined;
|
|
102
106
|
conditional?: any;
|
|
103
107
|
})[];
|
|
104
108
|
export declare const getActionAnnotationFields: (actionConfig: ActionConfig) => FieldConfig[];
|
|
@@ -177,7 +177,9 @@ var PlainScopeType = z6.enum([
|
|
|
177
177
|
"performance.vital-statistics-export",
|
|
178
178
|
// Scopes used exclusively by countryconfig integration token
|
|
179
179
|
"record.confirm-registration",
|
|
180
|
-
"record.reject-registration"
|
|
180
|
+
"record.reject-registration",
|
|
181
|
+
// bootstrap: allows countryconfig to register integrations on startup
|
|
182
|
+
"integration.create"
|
|
181
183
|
]);
|
|
182
184
|
var scopeByEvent = z6.preprocess(
|
|
183
185
|
(val) => val === void 0 ? void 0 : [val].flat(),
|
package/dist/events/index.js
CHANGED
|
@@ -506,7 +506,9 @@ var PlainScopeType = z2.enum([
|
|
|
506
506
|
"performance.vital-statistics-export",
|
|
507
507
|
// Scopes used exclusively by countryconfig integration token
|
|
508
508
|
"record.confirm-registration",
|
|
509
|
-
"record.reject-registration"
|
|
509
|
+
"record.reject-registration",
|
|
510
|
+
// bootstrap: allows countryconfig to register integrations on startup
|
|
511
|
+
"integration.create"
|
|
510
512
|
]);
|
|
511
513
|
var scopeByEvent = z2.preprocess(
|
|
512
514
|
(val) => val === void 0 ? void 0 : [val].flat(),
|
|
@@ -3044,6 +3046,9 @@ var PageConfigBase = z21.object({
|
|
|
3044
3046
|
requireCompletionToContinue: z21.boolean().default(false).describe(
|
|
3045
3047
|
"If true, all required fields must be filled before continuing to the next page"
|
|
3046
3048
|
),
|
|
3049
|
+
showClearButton: z21.boolean().optional().describe(
|
|
3050
|
+
'If true, a "Clear" button is shown at the top of the page allowing the user to reset all fields on the page to their default state'
|
|
3051
|
+
),
|
|
3047
3052
|
fields: z21.array(FieldConfig).describe("Fields to be rendered on the page"),
|
|
3048
3053
|
conditional: Conditional.optional().describe(
|
|
3049
3054
|
"Page will be shown if condition is met. If conditional is not defined, the page will be always shown."
|
|
@@ -7760,6 +7765,7 @@ var TENNIS_CLUB_DECLARATION_FORM = defineDeclarationForm({
|
|
|
7760
7765
|
defaultMessage: "Who is applying for the membership?",
|
|
7761
7766
|
description: "This is the title of the section"
|
|
7762
7767
|
},
|
|
7768
|
+
showClearButton: true,
|
|
7763
7769
|
fields: [
|
|
7764
7770
|
{
|
|
7765
7771
|
id: "applicant.name",
|
|
@@ -2190,7 +2190,9 @@ var PlainScopeType = z3.enum([
|
|
|
2190
2190
|
"performance.vital-statistics-export",
|
|
2191
2191
|
// Scopes used exclusively by countryconfig integration token
|
|
2192
2192
|
"record.confirm-registration",
|
|
2193
|
-
"record.reject-registration"
|
|
2193
|
+
"record.reject-registration",
|
|
2194
|
+
// bootstrap: allows countryconfig to register integrations on startup
|
|
2195
|
+
"integration.create"
|
|
2194
2196
|
]);
|
|
2195
2197
|
var scopeByEvent = z3.preprocess(
|
|
2196
2198
|
(val) => val === void 0 ? void 0 : [val].flat(),
|
|
@@ -104,7 +104,9 @@ var PlainScopeType = z2.enum([
|
|
|
104
104
|
"performance.vital-statistics-export",
|
|
105
105
|
// Scopes used exclusively by countryconfig integration token
|
|
106
106
|
"record.confirm-registration",
|
|
107
|
-
"record.reject-registration"
|
|
107
|
+
"record.reject-registration",
|
|
108
|
+
// bootstrap: allows countryconfig to register integrations on startup
|
|
109
|
+
"integration.create"
|
|
108
110
|
]);
|
|
109
111
|
var scopeByEvent = z2.preprocess(
|
|
110
112
|
(val) => val === void 0 ? void 0 : [val].flat(),
|
|
@@ -2501,6 +2503,9 @@ var PageConfigBase = z21.object({
|
|
|
2501
2503
|
requireCompletionToContinue: z21.boolean().default(false).describe(
|
|
2502
2504
|
"If true, all required fields must be filled before continuing to the next page"
|
|
2503
2505
|
),
|
|
2506
|
+
showClearButton: z21.boolean().optional().describe(
|
|
2507
|
+
'If true, a "Clear" button is shown at the top of the page allowing the user to reset all fields on the page to their default state'
|
|
2508
|
+
),
|
|
2504
2509
|
fields: z21.array(FieldConfig).describe("Fields to be rendered on the page"),
|
|
2505
2510
|
conditional: Conditional.optional().describe(
|
|
2506
2511
|
"Page will be shown if condition is met. If conditional is not defined, the page will be always shown."
|
|
@@ -5532,6 +5537,7 @@ var TENNIS_CLUB_DECLARATION_FORM = defineDeclarationForm({
|
|
|
5532
5537
|
defaultMessage: "Who is applying for the membership?",
|
|
5533
5538
|
description: "This is the title of the section"
|
|
5534
5539
|
},
|
|
5540
|
+
showClearButton: true,
|
|
5535
5541
|
fields: [
|
|
5536
5542
|
{
|
|
5537
5543
|
id: "applicant.name",
|
package/dist/scopes/index.js
CHANGED
|
@@ -135,7 +135,9 @@ var PlainScopeType = z3.enum([
|
|
|
135
135
|
"performance.vital-statistics-export",
|
|
136
136
|
// Scopes used exclusively by countryconfig integration token
|
|
137
137
|
"record.confirm-registration",
|
|
138
|
-
"record.reject-registration"
|
|
138
|
+
"record.reject-registration",
|
|
139
|
+
// bootstrap: allows countryconfig to register integrations on startup
|
|
140
|
+
"integration.create"
|
|
139
141
|
]);
|
|
140
142
|
var scopeByEvent = z3.preprocess(
|
|
141
143
|
(val) => val === void 0 ? void 0 : [val].flat(),
|
|
Binary file
|
package/package.json
CHANGED
|
Binary file
|