@forwardslashns/taskit-validation-messages 1.10.52 → 1.10.54

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.
@@ -181,6 +181,11 @@ export declare const CLIENT_CURRENT_ENTITY_STATUS: {
181
181
  message: string;
182
182
  affectedFields: never[];
183
183
  };
184
+ CLIENT_COULD_NOT_BE_DELETED_TASKS_EXIST: {
185
+ severity: "error";
186
+ message: string;
187
+ affectedFields: never[];
188
+ };
184
189
  INITIAL_FILING_DATE_BEFORE_DATE_ESTABLISHED: {
185
190
  severity: "error";
186
191
  message: string;
@@ -1 +1 @@
1
- {"version":3,"file":"client-current-entity-statuses.validation-messages.d.ts","sourceRoot":"","sources":["../../../src/validation/features/client-current-entity-statuses.validation-messages.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAoNvC,CAAC"}
1
+ {"version":3,"file":"client-current-entity-statuses.validation-messages.d.ts","sourceRoot":"","sources":["../../../src/validation/features/client-current-entity-statuses.validation-messages.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAyNvC,CAAC"}
@@ -185,6 +185,11 @@ exports.CLIENT_CURRENT_ENTITY_STATUS = (0, validation_message_types_1.defineVali
185
185
  message: `This client cannot be deleted because it has contacts associated`,
186
186
  affectedFields: [],
187
187
  },
188
+ CLIENT_COULD_NOT_BE_DELETED_TASKS_EXIST: {
189
+ severity: validation_message_types_1.VALIDATION_SEVERITY.ERROR,
190
+ message: `This client cannot be deleted because it has active tasks associated. Delete or close the tasks first.`,
191
+ affectedFields: [],
192
+ },
188
193
  INITIAL_FILING_DATE_BEFORE_DATE_ESTABLISHED: {
189
194
  severity: validation_message_types_1.VALIDATION_SEVERITY.ERROR,
190
195
  message: `Initial filing date cannot be before date established {dateEstablished}. Please adjust the dates to continue.`,
@@ -0,0 +1,77 @@
1
+ export declare const TASKS: {
2
+ NOT_FOUND: {
3
+ severity: "error";
4
+ message: string;
5
+ params: string[];
6
+ affectedFields: string[];
7
+ };
8
+ NOT_FILING_TYPE: {
9
+ severity: "error";
10
+ message: string;
11
+ params: string[];
12
+ affectedFields: string[];
13
+ };
14
+ CANNOT_MARK_FINAL_HAS_LATER_FILINGS: {
15
+ severity: "error";
16
+ message: string;
17
+ affectedFields: string[];
18
+ };
19
+ GENERATION_LOG_NOT_FOUND: {
20
+ severity: "error";
21
+ message: string;
22
+ params: string[];
23
+ affectedFields: string[];
24
+ };
25
+ CANNOT_COMPLETE_NOT_CURRENT: {
26
+ severity: "error";
27
+ message: string;
28
+ affectedFields: string[];
29
+ };
30
+ CANNOT_COMPLETE_ALREADY_COMPLETED: {
31
+ severity: "error";
32
+ message: string;
33
+ affectedFields: string[];
34
+ };
35
+ CANNOT_UNDO_NOT_COMPLETED: {
36
+ severity: "error";
37
+ message: string;
38
+ affectedFields: string[];
39
+ };
40
+ CANNOT_UNDO_NOT_LATEST: {
41
+ severity: "error";
42
+ message: string;
43
+ affectedFields: string[];
44
+ };
45
+ TARGET_DATE_INVALID_FORMAT: {
46
+ severity: "error";
47
+ message: string;
48
+ affectedFields: string[];
49
+ };
50
+ WHY_REQUIRED_WITH_DONT_DO: {
51
+ severity: "error";
52
+ message: string;
53
+ affectedFields: string[];
54
+ };
55
+ WHY_MUST_BE_FROM_ALLOWED_VALUES: {
56
+ severity: "error";
57
+ message: string;
58
+ affectedFields: string[];
59
+ };
60
+ ASSIGNMENT_NOT_FOUND: {
61
+ severity: "error";
62
+ message: string;
63
+ params: string[];
64
+ affectedFields: string[];
65
+ };
66
+ CLIENT_ID_MISMATCH_WITH_CLIENT_TEMPLATE: {
67
+ severity: "error";
68
+ message: string;
69
+ affectedFields: string[];
70
+ };
71
+ CLIENT_TEMPLATE_ENDING_DATE_CONFLICTS_WITH_TASKS: {
72
+ severity: "error";
73
+ message: string;
74
+ affectedFields: string[];
75
+ };
76
+ };
77
+ //# sourceMappingURL=tasks.validation-messages.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tasks.validation-messages.d.ts","sourceRoot":"","sources":["../../../src/validation/features/tasks.validation-messages.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,KAAK;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA+EhB,CAAC"}
@@ -0,0 +1,80 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.TASKS = void 0;
4
+ const validation_message_types_1 = require("../validation-message.types");
5
+ exports.TASKS = (0, validation_message_types_1.defineValidationFeatureMessages)({
6
+ NOT_FOUND: {
7
+ severity: validation_message_types_1.VALIDATION_SEVERITY.ERROR,
8
+ message: 'Task <b>{taskId}</b> does not exist or does not belong to this client.',
9
+ params: ['taskId'],
10
+ affectedFields: ['taskId'],
11
+ },
12
+ NOT_FILING_TYPE: {
13
+ severity: validation_message_types_1.VALIDATION_SEVERITY.ERROR,
14
+ message: 'Task <b>{taskId}</b> is not a Filing type task. Only Filing tasks support this operation.',
15
+ params: ['taskId'],
16
+ affectedFields: ['taskId'],
17
+ },
18
+ CANNOT_MARK_FINAL_HAS_LATER_FILINGS: {
19
+ severity: validation_message_types_1.VALIDATION_SEVERITY.ERROR,
20
+ message: "This filing cannot be marked Final, since there are other filings after this filing's ending period. Only the last filing can be marked final.",
21
+ affectedFields: ['isFinalFiling'],
22
+ },
23
+ GENERATION_LOG_NOT_FOUND: {
24
+ severity: validation_message_types_1.VALIDATION_SEVERITY.ERROR,
25
+ message: 'Task generation log <b>{logId}</b> does not exist.',
26
+ params: ['logId'],
27
+ affectedFields: ['logId'],
28
+ },
29
+ CANNOT_COMPLETE_NOT_CURRENT: {
30
+ severity: validation_message_types_1.VALIDATION_SEVERITY.ERROR,
31
+ message: 'Assignment can only be completed when all previous workflow assignments in order have already been completed.',
32
+ affectedFields: ['status'],
33
+ },
34
+ CANNOT_COMPLETE_ALREADY_COMPLETED: {
35
+ severity: validation_message_types_1.VALIDATION_SEVERITY.ERROR,
36
+ message: 'This assignment has already been completed.',
37
+ affectedFields: ['status'],
38
+ },
39
+ CANNOT_UNDO_NOT_COMPLETED: {
40
+ severity: validation_message_types_1.VALIDATION_SEVERITY.ERROR,
41
+ message: 'Only completed assignments can be undone.',
42
+ affectedFields: ['status'],
43
+ },
44
+ CANNOT_UNDO_NOT_LATEST: {
45
+ severity: validation_message_types_1.VALIDATION_SEVERITY.ERROR,
46
+ message: 'Only the latest completed assignment can be undone. A later assignment has already been completed.',
47
+ affectedFields: ['status'],
48
+ },
49
+ TARGET_DATE_INVALID_FORMAT: {
50
+ severity: validation_message_types_1.VALIDATION_SEVERITY.ERROR,
51
+ message: 'Target date must be a valid date in YYYY-MM-DD format.',
52
+ affectedFields: ['targetDate'],
53
+ },
54
+ WHY_REQUIRED_WITH_DONT_DO: {
55
+ severity: validation_message_types_1.VALIDATION_SEVERITY.ERROR,
56
+ message: 'A reason must be selected when "Don\'t do" is enabled.',
57
+ affectedFields: ['why'],
58
+ },
59
+ WHY_MUST_BE_FROM_ALLOWED_VALUES: {
60
+ severity: validation_message_types_1.VALIDATION_SEVERITY.ERROR,
61
+ message: "The selected reason is not valid. Choose from: Wait for client, Don't respond, Client not paying, Client wants to close, Filing by other accountant, Client put on hold, Decided not to file, No activity.",
62
+ affectedFields: ['why'],
63
+ },
64
+ ASSIGNMENT_NOT_FOUND: {
65
+ severity: validation_message_types_1.VALIDATION_SEVERITY.ERROR,
66
+ message: 'Assignment <b>{assignmentId}</b> does not exist or does not belong to this task.',
67
+ params: ['assignmentId'],
68
+ affectedFields: ['assignmentId'],
69
+ },
70
+ CLIENT_ID_MISMATCH_WITH_CLIENT_TEMPLATE: {
71
+ severity: validation_message_types_1.VALIDATION_SEVERITY.ERROR,
72
+ message: 'The provided client does not match the client of the referenced client template.',
73
+ affectedFields: ['clientId', 'clientTemplateId'],
74
+ },
75
+ CLIENT_TEMPLATE_ENDING_DATE_CONFLICTS_WITH_TASKS: {
76
+ severity: validation_message_types_1.VALIDATION_SEVERITY.ERROR,
77
+ message: 'Client template ending date cannot be set before existing task periods. One or more tasks have periods ending after the selected date.',
78
+ affectedFields: ['endingDate'],
79
+ },
80
+ });
@@ -465,6 +465,11 @@ export declare const VALIDATION_MESSAGES: {
465
465
  message: string;
466
466
  affectedFields: never[];
467
467
  };
468
+ CLIENT_COULD_NOT_BE_DELETED_TASKS_EXIST: {
469
+ severity: "error";
470
+ message: string;
471
+ affectedFields: never[];
472
+ };
468
473
  INITIAL_FILING_DATE_BEFORE_DATE_ESTABLISHED: {
469
474
  severity: "error";
470
475
  message: string;
@@ -2338,5 +2343,81 @@ export declare const VALIDATION_MESSAGES: {
2338
2343
  affectedFields: string[];
2339
2344
  };
2340
2345
  };
2346
+ readonly TASKS: {
2347
+ NOT_FOUND: {
2348
+ severity: "error";
2349
+ message: string;
2350
+ params: string[];
2351
+ affectedFields: string[];
2352
+ };
2353
+ NOT_FILING_TYPE: {
2354
+ severity: "error";
2355
+ message: string;
2356
+ params: string[];
2357
+ affectedFields: string[];
2358
+ };
2359
+ CANNOT_MARK_FINAL_HAS_LATER_FILINGS: {
2360
+ severity: "error";
2361
+ message: string;
2362
+ affectedFields: string[];
2363
+ };
2364
+ GENERATION_LOG_NOT_FOUND: {
2365
+ severity: "error";
2366
+ message: string;
2367
+ params: string[];
2368
+ affectedFields: string[];
2369
+ };
2370
+ CANNOT_COMPLETE_NOT_CURRENT: {
2371
+ severity: "error";
2372
+ message: string;
2373
+ affectedFields: string[];
2374
+ };
2375
+ CANNOT_COMPLETE_ALREADY_COMPLETED: {
2376
+ severity: "error";
2377
+ message: string;
2378
+ affectedFields: string[];
2379
+ };
2380
+ CANNOT_UNDO_NOT_COMPLETED: {
2381
+ severity: "error";
2382
+ message: string;
2383
+ affectedFields: string[];
2384
+ };
2385
+ CANNOT_UNDO_NOT_LATEST: {
2386
+ severity: "error";
2387
+ message: string;
2388
+ affectedFields: string[];
2389
+ };
2390
+ TARGET_DATE_INVALID_FORMAT: {
2391
+ severity: "error";
2392
+ message: string;
2393
+ affectedFields: string[];
2394
+ };
2395
+ WHY_REQUIRED_WITH_DONT_DO: {
2396
+ severity: "error";
2397
+ message: string;
2398
+ affectedFields: string[];
2399
+ };
2400
+ WHY_MUST_BE_FROM_ALLOWED_VALUES: {
2401
+ severity: "error";
2402
+ message: string;
2403
+ affectedFields: string[];
2404
+ };
2405
+ ASSIGNMENT_NOT_FOUND: {
2406
+ severity: "error";
2407
+ message: string;
2408
+ params: string[];
2409
+ affectedFields: string[];
2410
+ };
2411
+ CLIENT_ID_MISMATCH_WITH_CLIENT_TEMPLATE: {
2412
+ severity: "error";
2413
+ message: string;
2414
+ affectedFields: string[];
2415
+ };
2416
+ CLIENT_TEMPLATE_ENDING_DATE_CONFLICTS_WITH_TASKS: {
2417
+ severity: "error";
2418
+ message: string;
2419
+ affectedFields: string[];
2420
+ };
2421
+ };
2341
2422
  };
2342
2423
  //# sourceMappingURL=validation-messages.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"validation-messages.d.ts","sourceRoot":"","sources":["../../src/validation/validation-messages.ts"],"names":[],"mappings":"AA8BA,eAAO,MAAM,mBA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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA+BtB,CAAC"}
@@ -30,6 +30,7 @@ const income_accounts_validation_messages_1 = require("./features/income-account
30
30
  const template_recurrence_settings_validation_messages_1 = require("./features/template-recurrence-settings.validation-messages");
31
31
  const client_templates_validation_messages_1 = require("./features/client-templates.validation-messages");
32
32
  const client_template_assignments_validation_messages_1 = require("./features/client-template-assignments.validation-messages");
33
+ const tasks_validation_messages_1 = require("./features/tasks.validation-messages");
33
34
  exports.VALIDATION_MESSAGES = {
34
35
  ACCOUNT_CATEGORIES: account_categories_validation_messages_1.ACCOUNT_CATEGORIES,
35
36
  ACCOUNT_IDS: account_ids_validation_messages_1.ACCOUNT_IDS,
@@ -60,4 +61,5 @@ exports.VALIDATION_MESSAGES = {
60
61
  TEMPLATE_RECURRENCE_SETTINGS: template_recurrence_settings_validation_messages_1.TEMPLATE_RECURRENCE_SETTINGS,
61
62
  CLIENT_TEMPLATES: client_templates_validation_messages_1.CLIENT_TEMPLATES,
62
63
  CLIENT_TEMPLATE_ASSIGNMENTS: client_template_assignments_validation_messages_1.CLIENT_TEMPLATE_ASSIGNMENTS,
64
+ TASKS: tasks_validation_messages_1.TASKS,
63
65
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@forwardslashns/taskit-validation-messages",
3
- "version": "1.10.52",
3
+ "version": "1.10.54",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "type": "commonjs",
@@ -183,6 +183,11 @@ export const CLIENT_CURRENT_ENTITY_STATUS = defineValidationFeatureMessages({
183
183
  message: `This client cannot be deleted because it has contacts associated`,
184
184
  affectedFields: [],
185
185
  },
186
+ CLIENT_COULD_NOT_BE_DELETED_TASKS_EXIST: {
187
+ severity: VALIDATION_SEVERITY.ERROR,
188
+ message: `This client cannot be deleted because it has active tasks associated. Delete or close the tasks first.`,
189
+ affectedFields: [],
190
+ },
186
191
  INITIAL_FILING_DATE_BEFORE_DATE_ESTABLISHED: {
187
192
  severity: VALIDATION_SEVERITY.ERROR,
188
193
  message: `Initial filing date cannot be before date established {dateEstablished}. Please adjust the dates to continue.`,
@@ -0,0 +1,82 @@
1
+ import { defineValidationFeatureMessages, VALIDATION_SEVERITY } from '../validation-message.types';
2
+
3
+ export const TASKS = defineValidationFeatureMessages({
4
+ NOT_FOUND: {
5
+ severity: VALIDATION_SEVERITY.ERROR,
6
+ message: 'Task <b>{taskId}</b> does not exist or does not belong to this client.',
7
+ params: ['taskId'],
8
+ affectedFields: ['taskId'],
9
+ },
10
+ NOT_FILING_TYPE: {
11
+ severity: VALIDATION_SEVERITY.ERROR,
12
+ message: 'Task <b>{taskId}</b> is not a Filing type task. Only Filing tasks support this operation.',
13
+ params: ['taskId'],
14
+ affectedFields: ['taskId'],
15
+ },
16
+ CANNOT_MARK_FINAL_HAS_LATER_FILINGS: {
17
+ severity: VALIDATION_SEVERITY.ERROR,
18
+ message:
19
+ "This filing cannot be marked Final, since there are other filings after this filing's ending period. Only the last filing can be marked final.",
20
+ affectedFields: ['isFinalFiling'],
21
+ },
22
+ GENERATION_LOG_NOT_FOUND: {
23
+ severity: VALIDATION_SEVERITY.ERROR,
24
+ message: 'Task generation log <b>{logId}</b> does not exist.',
25
+ params: ['logId'],
26
+ affectedFields: ['logId'],
27
+ },
28
+ CANNOT_COMPLETE_NOT_CURRENT: {
29
+ severity: VALIDATION_SEVERITY.ERROR,
30
+ message:
31
+ 'Assignment can only be completed when all previous workflow assignments in order have already been completed.',
32
+ affectedFields: ['status'],
33
+ },
34
+ CANNOT_COMPLETE_ALREADY_COMPLETED: {
35
+ severity: VALIDATION_SEVERITY.ERROR,
36
+ message: 'This assignment has already been completed.',
37
+ affectedFields: ['status'],
38
+ },
39
+ CANNOT_UNDO_NOT_COMPLETED: {
40
+ severity: VALIDATION_SEVERITY.ERROR,
41
+ message: 'Only completed assignments can be undone.',
42
+ affectedFields: ['status'],
43
+ },
44
+ CANNOT_UNDO_NOT_LATEST: {
45
+ severity: VALIDATION_SEVERITY.ERROR,
46
+ message: 'Only the latest completed assignment can be undone. A later assignment has already been completed.',
47
+ affectedFields: ['status'],
48
+ },
49
+ TARGET_DATE_INVALID_FORMAT: {
50
+ severity: VALIDATION_SEVERITY.ERROR,
51
+ message: 'Target date must be a valid date in YYYY-MM-DD format.',
52
+ affectedFields: ['targetDate'],
53
+ },
54
+ WHY_REQUIRED_WITH_DONT_DO: {
55
+ severity: VALIDATION_SEVERITY.ERROR,
56
+ message: 'A reason must be selected when "Don\'t do" is enabled.',
57
+ affectedFields: ['why'],
58
+ },
59
+ WHY_MUST_BE_FROM_ALLOWED_VALUES: {
60
+ severity: VALIDATION_SEVERITY.ERROR,
61
+ message:
62
+ "The selected reason is not valid. Choose from: Wait for client, Don't respond, Client not paying, Client wants to close, Filing by other accountant, Client put on hold, Decided not to file, No activity.",
63
+ affectedFields: ['why'],
64
+ },
65
+ ASSIGNMENT_NOT_FOUND: {
66
+ severity: VALIDATION_SEVERITY.ERROR,
67
+ message: 'Assignment <b>{assignmentId}</b> does not exist or does not belong to this task.',
68
+ params: ['assignmentId'],
69
+ affectedFields: ['assignmentId'],
70
+ },
71
+ CLIENT_ID_MISMATCH_WITH_CLIENT_TEMPLATE: {
72
+ severity: VALIDATION_SEVERITY.ERROR,
73
+ message: 'The provided client does not match the client of the referenced client template.',
74
+ affectedFields: ['clientId', 'clientTemplateId'],
75
+ },
76
+ CLIENT_TEMPLATE_ENDING_DATE_CONFLICTS_WITH_TASKS: {
77
+ severity: VALIDATION_SEVERITY.ERROR,
78
+ message:
79
+ 'Client template ending date cannot be set before existing task periods. One or more tasks have periods ending after the selected date.',
80
+ affectedFields: ['endingDate'],
81
+ },
82
+ });
@@ -27,6 +27,7 @@ import { INCOME_ACCOUNTS } from './features/income-accounts.validation-messages'
27
27
  import { TEMPLATE_RECURRENCE_SETTINGS } from './features/template-recurrence-settings.validation-messages';
28
28
  import { CLIENT_TEMPLATES } from './features/client-templates.validation-messages';
29
29
  import { CLIENT_TEMPLATE_ASSIGNMENTS } from './features/client-template-assignments.validation-messages';
30
+ import { TASKS } from './features/tasks.validation-messages';
30
31
 
31
32
  export const VALIDATION_MESSAGES = {
32
33
  ACCOUNT_CATEGORIES,
@@ -58,4 +59,5 @@ export const VALIDATION_MESSAGES = {
58
59
  TEMPLATE_RECURRENCE_SETTINGS,
59
60
  CLIENT_TEMPLATES,
60
61
  CLIENT_TEMPLATE_ASSIGNMENTS,
62
+ TASKS,
61
63
  } as const;