@opencrvs/toolkit 2.0.0-rc.13de0a3 → 2.0.0-rc.14244b1

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.
@@ -206,11 +206,6 @@ var FieldTypesToHideInReview = [
206
206
  FieldType.ALPHA_PRINT_BUTTON,
207
207
  FieldType.ALPHA_HIDDEN
208
208
  ];
209
- var HiddenFieldTypes = [
210
- FieldType.HTTP,
211
- FieldType.QUERY_PARAM_READER,
212
- FieldType.ALPHA_HIDDEN
213
- ];
214
209
 
215
210
  // ../commons/src/events/FieldValue.ts
216
211
  var z7 = __toESM(require("zod/v4"));
@@ -1500,7 +1495,6 @@ var NumberField = BaseField.extend({
1500
1495
  configuration: import_v43.default.object({
1501
1496
  min: import_v43.default.number().optional().describe("Minimum value"),
1502
1497
  max: import_v43.default.number().optional().describe("Maximum value"),
1503
- integer: import_v43.default.boolean().optional().describe("When true, only whole numbers are allowed"),
1504
1498
  prefix: TranslationConfig.optional(),
1505
1499
  postfix: TranslationConfig.optional()
1506
1500
  }).optional()
@@ -7374,13 +7374,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
7374
7374
  output: void;
7375
7375
  meta: import("trpc-to-openapi").OpenApiMeta;
7376
7376
  }>;
7377
- requestContactChange: import("@trpc/server").TRPCMutationProcedure<{
7377
+ sendVerifyCode: import("@trpc/server").TRPCMutationProcedure<{
7378
7378
  input: {
7379
- notificationEvent: "change-email-address";
7380
- email: string;
7381
- } | {
7382
- notificationEvent: "change-phone-number";
7383
- phoneNumber: string;
7379
+ notificationEvent: "change-phone-number" | "change-email-address";
7384
7380
  };
7385
7381
  output: {
7386
7382
  nonce: string;
@@ -267,7 +267,6 @@ declare const NumberField: z.ZodObject<{
267
267
  configuration: z.ZodOptional<z.ZodObject<{
268
268
  min: z.ZodOptional<z.ZodNumber>;
269
269
  max: z.ZodOptional<z.ZodNumber>;
270
- integer: z.ZodOptional<z.ZodBoolean>;
271
270
  prefix: z.ZodOptional<z.ZodObject<import("./TranslationConfig").MessageDescriptorZod, z.core.$strip>>;
272
271
  postfix: z.ZodOptional<z.ZodObject<import("./TranslationConfig").MessageDescriptorZod, z.core.$strip>>;
273
272
  }, z.core.$strip>>;
@@ -75,5 +75,4 @@ export type FieldType = (typeof fieldTypes)[number];
75
75
  */
76
76
  export declare const compositeFieldTypes: ("NAME" | "ADDRESS" | "DATE_RANGE" | "FILE" | "FILE_WITH_OPTIONS" | "DATA" | "ID_READER")[];
77
77
  export declare const FieldTypesToHideInReview: ("IMAGE_VIEW" | "PARAGRAPH" | "PAGE_HEADER" | "BULLET_LIST" | "DIVIDER" | "DATA" | "ALPHA_PRINT_BUTTON" | "HTTP" | "QUERY_PARAM_READER" | "ID_READER" | "LOADER" | "ALPHA_HIDDEN")[];
78
- export declare const HiddenFieldTypes: ("HTTP" | "QUERY_PARAM_READER" | "ALPHA_HIDDEN")[];
79
78
  //# sourceMappingURL=FieldType.d.ts.map
@@ -151,7 +151,6 @@ __export(events_exports, {
151
151
  FormPageConfig: () => FormPageConfig,
152
152
  Fuzzy: () => Fuzzy,
153
153
  GeographicalArea: () => GeographicalArea,
154
- HiddenFieldTypes: () => HiddenFieldTypes,
155
154
  HiddenFieldValue: () => HiddenFieldValue,
156
155
  HttpFieldUpdateValue: () => HttpFieldUpdateValue,
157
156
  HttpFieldValue: () => HttpFieldValue,
@@ -1220,11 +1219,6 @@ var FieldTypesToHideInReview = [
1220
1219
  FieldType.ALPHA_PRINT_BUTTON,
1221
1220
  FieldType.ALPHA_HIDDEN
1222
1221
  ];
1223
- var HiddenFieldTypes = [
1224
- FieldType.HTTP,
1225
- FieldType.QUERY_PARAM_READER,
1226
- FieldType.ALPHA_HIDDEN
1227
- ];
1228
1222
 
1229
1223
  // ../commons/src/events/FieldValue.ts
1230
1224
  var z12 = __toESM(require("zod/v4"));
@@ -2298,7 +2292,6 @@ var NumberField = BaseField.extend({
2298
2292
  configuration: import_v43.default.object({
2299
2293
  min: import_v43.default.number().optional().describe("Minimum value"),
2300
2294
  max: import_v43.default.number().optional().describe("Maximum value"),
2301
- integer: import_v43.default.boolean().optional().describe("When true, only whole numbers are allowed"),
2302
2295
  prefix: TranslationConfig.optional(),
2303
2296
  postfix: TranslationConfig.optional()
2304
2297
  }).optional()
@@ -6492,8 +6485,6 @@ var updateActions = ActionTypes.extract([
6492
6485
  ActionType.ARCHIVE,
6493
6486
  ActionType.PRINT_CERTIFICATE,
6494
6487
  ActionType.REQUEST_CORRECTION,
6495
- ActionType.APPROVE_CORRECTION,
6496
- ActionType.REJECT_CORRECTION,
6497
6488
  ActionType.CUSTOM
6498
6489
  ]);
6499
6490
  function getActionUpdateMetadata(actions) {
@@ -10632,19 +10623,18 @@ var ACTION_FILTERS = {
10632
10623
  function filterActionsByFlags(actions, flags) {
10633
10624
  return actions.filter((action) => ACTION_FILTERS[action]?.(flags) ?? true);
10634
10625
  }
10635
- var REJECTED_ACTIONS = [
10636
- ActionType.READ,
10637
- ActionType.NOTIFY,
10638
- ActionType.CUSTOM,
10639
- ActionType.EDIT,
10640
- ActionType.ARCHIVE
10641
- ];
10642
10626
  function getAvailableActionsWithoutFlagFilters(status2, flags) {
10643
10627
  if (flags.includes(InherentFlags.EDIT_IN_PROGRESS)) {
10644
10628
  return [ActionType.NOTIFY, ActionType.DECLARE, ActionType.REGISTER];
10645
10629
  }
10646
- if (flags.includes(InherentFlags.REJECTED) && status2 !== EventStatus.enum.ARCHIVED) {
10647
- return REJECTED_ACTIONS;
10630
+ if (flags.includes(InherentFlags.REJECTED)) {
10631
+ return [
10632
+ ActionType.READ,
10633
+ ActionType.NOTIFY,
10634
+ ActionType.CUSTOM,
10635
+ ActionType.EDIT,
10636
+ ActionType.ARCHIVE
10637
+ ];
10648
10638
  }
10649
10639
  return AVAILABLE_ACTIONS_BY_EVENT_STATUS[status2];
10650
10640
  }
@@ -770,11 +770,6 @@ var FieldTypesToHideInReview = [
770
770
  FieldType.ALPHA_PRINT_BUTTON,
771
771
  FieldType.ALPHA_HIDDEN
772
772
  ];
773
- var HiddenFieldTypes = [
774
- FieldType.HTTP,
775
- FieldType.QUERY_PARAM_READER,
776
- FieldType.ALPHA_HIDDEN
777
- ];
778
773
 
779
774
  // ../commons/src/events/FieldValue.ts
780
775
  var z12 = __toESM(require("zod/v4"));
@@ -1755,7 +1750,6 @@ var NumberField = BaseField.extend({
1755
1750
  configuration: import_v43.default.object({
1756
1751
  min: import_v43.default.number().optional().describe("Minimum value"),
1757
1752
  max: import_v43.default.number().optional().describe("Maximum value"),
1758
- integer: import_v43.default.boolean().optional().describe("When true, only whole numbers are allowed"),
1759
1753
  prefix: TranslationConfig.optional(),
1760
1754
  postfix: TranslationConfig.optional()
1761
1755
  }).optional()
@@ -4703,8 +4697,6 @@ var updateActions = ActionTypes.extract([
4703
4697
  ActionType.ARCHIVE,
4704
4698
  ActionType.PRINT_CERTIFICATE,
4705
4699
  ActionType.REQUEST_CORRECTION,
4706
- ActionType.APPROVE_CORRECTION,
4707
- ActionType.REJECT_CORRECTION,
4708
4700
  ActionType.CUSTOM
4709
4701
  ]);
4710
4702
 
@@ -7249,13 +7241,6 @@ var ACTION_FILTERS = {
7249
7241
  [ActionType.UNASSIGN]: (flags) => !flags.some((flag) => flag.endsWith(":requested")),
7250
7242
  [ActionType.CUSTOM]: (flags) => !flags.some((flag) => flag.endsWith(":requested"))
7251
7243
  };
7252
- var REJECTED_ACTIONS = [
7253
- ActionType.READ,
7254
- ActionType.NOTIFY,
7255
- ActionType.CUSTOM,
7256
- ActionType.EDIT,
7257
- ActionType.ARCHIVE
7258
- ];
7259
7244
 
7260
7245
  // ../commons/src/events/FileUtils.ts
7261
7246
  var import_lodash7 = require("lodash");
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@opencrvs/toolkit",
3
- "version": "2.0.0-rc.13de0a3",
3
+ "version": "2.0.0-rc.14244b1",
4
4
  "description": "OpenCRVS toolkit for building country configurations",
5
5
  "license": "MPL-2.0",
6
6
  "bin": {