@webiny/api-headless-cms 5.37.0 → 5.37.1-beta.1

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.
@@ -24,26 +24,26 @@ export declare const createModelCreateValidation: () => zod.ZodObject<{
24
24
  label: zod.ZodString;
25
25
  selected: zod.ZodDefault<zod.ZodOptional<zod.ZodBoolean>>;
26
26
  }, "strip", zod.ZodTypeAny, {
27
- value: string;
28
27
  label: string;
28
+ value: string;
29
29
  selected: boolean;
30
30
  }, {
31
- value: string;
32
31
  label: string;
32
+ value: string;
33
33
  selected?: boolean | undefined;
34
34
  }>, "many">>;
35
35
  }, "strip", zod.ZodTypeAny, {
36
36
  values: {
37
- value: string;
38
37
  label: string;
38
+ value: string;
39
39
  selected: boolean;
40
40
  }[];
41
41
  enabled: boolean;
42
42
  }, {
43
43
  enabled: boolean;
44
44
  values?: {
45
- value: string;
46
45
  label: string;
46
+ value: string;
47
47
  selected?: boolean | undefined;
48
48
  }[] | undefined;
49
49
  }>>>;
@@ -60,20 +60,20 @@ export declare const createModelCreateValidation: () => zod.ZodObject<{
60
60
  settings: zod.ZodDefault<zod.ZodEffects<zod.ZodOptional<zod.ZodNullable<zod.ZodOptional<zod.ZodObject<{}, "passthrough", zod.ZodTypeAny, zod.objectOutputType<{}, zod.ZodTypeAny, "passthrough">, zod.objectInputType<{}, zod.ZodTypeAny, "passthrough">>>>>, zod.objectOutputType<{}, zod.ZodTypeAny, "passthrough">, zod.objectInputType<{}, zod.ZodTypeAny, "passthrough"> | null | undefined>>;
61
61
  }, "strip", zod.ZodTypeAny, {
62
62
  name: string;
63
- message: string;
64
63
  settings: {} & {
65
64
  [k: string]: unknown;
66
65
  };
66
+ message: string;
67
67
  }, {
68
68
  name: string;
69
69
  message?: string | undefined;
70
70
  settings?: zod.objectInputType<{}, zod.ZodTypeAny, "passthrough"> | null | undefined;
71
71
  }>, "many">>>>>, {
72
72
  name: string;
73
- message: string;
74
73
  settings: {} & {
75
74
  [k: string]: unknown;
76
75
  };
76
+ message: string;
77
77
  }[], {
78
78
  name: string;
79
79
  message?: string | undefined;
@@ -85,20 +85,20 @@ export declare const createModelCreateValidation: () => zod.ZodObject<{
85
85
  settings: zod.ZodDefault<zod.ZodEffects<zod.ZodOptional<zod.ZodNullable<zod.ZodOptional<zod.ZodObject<{}, "passthrough", zod.ZodTypeAny, zod.objectOutputType<{}, zod.ZodTypeAny, "passthrough">, zod.objectInputType<{}, zod.ZodTypeAny, "passthrough">>>>>, zod.objectOutputType<{}, zod.ZodTypeAny, "passthrough">, zod.objectInputType<{}, zod.ZodTypeAny, "passthrough"> | null | undefined>>;
86
86
  }, "strip", zod.ZodTypeAny, {
87
87
  name: string;
88
- message: string;
89
88
  settings: {} & {
90
89
  [k: string]: unknown;
91
90
  };
91
+ message: string;
92
92
  }, {
93
93
  name: string;
94
94
  message?: string | undefined;
95
95
  settings?: zod.objectInputType<{}, zod.ZodTypeAny, "passthrough"> | null | undefined;
96
96
  }>, "many">>>>>, {
97
97
  name: string;
98
- message: string;
99
98
  settings: {} & {
100
99
  [k: string]: unknown;
101
100
  };
101
+ message: string;
102
102
  }[], {
103
103
  name: string;
104
104
  message?: string | undefined;
@@ -106,11 +106,8 @@ export declare const createModelCreateValidation: () => zod.ZodObject<{
106
106
  }[] | null | undefined>;
107
107
  settings: zod.ZodDefault<zod.ZodEffects<zod.ZodOptional<zod.ZodNullable<zod.ZodOptional<zod.ZodObject<{}, "passthrough", zod.ZodTypeAny, zod.objectOutputType<{}, zod.ZodTypeAny, "passthrough">, zod.objectInputType<{}, zod.ZodTypeAny, "passthrough">>>>>, zod.objectOutputType<{}, zod.ZodTypeAny, "passthrough">, zod.objectInputType<{}, zod.ZodTypeAny, "passthrough"> | null | undefined>>;
108
108
  }, "strip", zod.ZodTypeAny, {
109
- type: string;
110
109
  id: string;
111
- settings: {} & {
112
- [k: string]: unknown;
113
- };
110
+ type: string;
114
111
  storageId: string;
115
112
  fieldId: string;
116
113
  label: string;
@@ -118,24 +115,27 @@ export declare const createModelCreateValidation: () => zod.ZodObject<{
118
115
  placeholderText: string | null;
119
116
  validation: {
120
117
  name: string;
121
- message: string;
122
118
  settings: {} & {
123
119
  [k: string]: unknown;
124
120
  };
121
+ message: string;
125
122
  }[];
126
123
  listValidation: {
127
124
  name: string;
128
- message: string;
129
125
  settings: {} & {
130
126
  [k: string]: unknown;
131
127
  };
128
+ message: string;
132
129
  }[];
133
130
  multipleValues: boolean;
134
131
  tags: string[];
132
+ settings: {} & {
133
+ [k: string]: unknown;
134
+ };
135
135
  predefinedValues?: {
136
136
  values: {
137
- value: string;
138
137
  label: string;
138
+ value: string;
139
139
  selected: boolean;
140
140
  }[];
141
141
  enabled: boolean;
@@ -144,8 +144,8 @@ export declare const createModelCreateValidation: () => zod.ZodObject<{
144
144
  name: string;
145
145
  } | undefined;
146
146
  }, {
147
- type: string;
148
147
  id: string;
148
+ type: string;
149
149
  fieldId: string;
150
150
  label: string;
151
151
  storageId?: string | undefined;
@@ -156,8 +156,8 @@ export declare const createModelCreateValidation: () => zod.ZodObject<{
156
156
  predefinedValues?: {
157
157
  enabled: boolean;
158
158
  values?: {
159
- value: string;
160
159
  label: string;
160
+ value: string;
161
161
  selected?: boolean | undefined;
162
162
  }[] | undefined;
163
163
  } | undefined;
@@ -183,14 +183,10 @@ export declare const createModelCreateValidation: () => zod.ZodObject<{
183
183
  imageFieldId: zod.ZodOptional<zod.ZodNullable<zod.ZodOptional<zod.ZodString>>>;
184
184
  defaultFields: zod.ZodOptional<zod.ZodNullable<zod.ZodBoolean>>;
185
185
  }, "strip", zod.ZodTypeAny, {
186
- group: string;
187
186
  name: string;
188
187
  fields: {
189
- type: string;
190
188
  id: string;
191
- settings: {} & {
192
- [k: string]: unknown;
193
- };
189
+ type: string;
194
190
  storageId: string;
195
191
  fieldId: string;
196
192
  label: string;
@@ -198,24 +194,27 @@ export declare const createModelCreateValidation: () => zod.ZodObject<{
198
194
  placeholderText: string | null;
199
195
  validation: {
200
196
  name: string;
201
- message: string;
202
197
  settings: {} & {
203
198
  [k: string]: unknown;
204
199
  };
200
+ message: string;
205
201
  }[];
206
202
  listValidation: {
207
203
  name: string;
208
- message: string;
209
204
  settings: {} & {
210
205
  [k: string]: unknown;
211
206
  };
207
+ message: string;
212
208
  }[];
213
209
  multipleValues: boolean;
214
210
  tags: string[];
211
+ settings: {} & {
212
+ [k: string]: unknown;
213
+ };
215
214
  predefinedValues?: {
216
215
  values: {
217
- value: string;
218
216
  label: string;
217
+ value: string;
219
218
  selected: boolean;
220
219
  }[];
221
220
  enabled: boolean;
@@ -227,6 +226,7 @@ export declare const createModelCreateValidation: () => zod.ZodObject<{
227
226
  layout: string[][];
228
227
  singularApiName: string;
229
228
  pluralApiName: string;
229
+ group: string;
230
230
  modelId?: string | undefined;
231
231
  description?: string | null | undefined;
232
232
  icon?: string | null | undefined;
@@ -236,16 +236,16 @@ export declare const createModelCreateValidation: () => zod.ZodObject<{
236
236
  imageFieldId?: string | null | undefined;
237
237
  defaultFields?: boolean | null | undefined;
238
238
  }, {
239
- group: string;
240
239
  name: string;
241
240
  singularApiName: string;
242
241
  pluralApiName: string;
242
+ group: string;
243
243
  modelId?: string | undefined;
244
244
  description?: string | null | undefined;
245
245
  icon?: string | null | undefined;
246
246
  fields?: {
247
- type: string;
248
247
  id: string;
248
+ type: string;
249
249
  fieldId: string;
250
250
  label: string;
251
251
  storageId?: string | undefined;
@@ -256,8 +256,8 @@ export declare const createModelCreateValidation: () => zod.ZodObject<{
256
256
  predefinedValues?: {
257
257
  enabled: boolean;
258
258
  values?: {
259
- value: string;
260
259
  label: string;
260
+ value: string;
261
261
  selected?: boolean | undefined;
262
262
  }[] | undefined;
263
263
  } | undefined;
@@ -293,19 +293,19 @@ export declare const createModelCreateFromValidation: () => zod.ZodObject<{
293
293
  icon: zod.ZodOptional<zod.ZodNullable<zod.ZodOptional<zod.ZodString>>>;
294
294
  locale: zod.ZodOptional<zod.ZodString>;
295
295
  }, "strip", zod.ZodTypeAny, {
296
- group: string;
297
296
  name: string;
298
297
  singularApiName: string;
299
298
  pluralApiName: string;
299
+ group: string;
300
300
  modelId?: string | undefined;
301
301
  description?: string | null | undefined;
302
302
  icon?: string | null | undefined;
303
303
  locale?: string | undefined;
304
304
  }, {
305
- group: string;
306
305
  name: string;
307
306
  singularApiName: string;
308
307
  pluralApiName: string;
308
+ group: string;
309
309
  modelId?: string | undefined;
310
310
  description?: string | null | undefined;
311
311
  icon?: string | null | undefined;
@@ -335,26 +335,26 @@ export declare const createModelUpdateValidation: () => zod.ZodObject<{
335
335
  label: zod.ZodString;
336
336
  selected: zod.ZodDefault<zod.ZodOptional<zod.ZodBoolean>>;
337
337
  }, "strip", zod.ZodTypeAny, {
338
- value: string;
339
338
  label: string;
339
+ value: string;
340
340
  selected: boolean;
341
341
  }, {
342
- value: string;
343
342
  label: string;
343
+ value: string;
344
344
  selected?: boolean | undefined;
345
345
  }>, "many">>;
346
346
  }, "strip", zod.ZodTypeAny, {
347
347
  values: {
348
- value: string;
349
348
  label: string;
349
+ value: string;
350
350
  selected: boolean;
351
351
  }[];
352
352
  enabled: boolean;
353
353
  }, {
354
354
  enabled: boolean;
355
355
  values?: {
356
- value: string;
357
356
  label: string;
357
+ value: string;
358
358
  selected?: boolean | undefined;
359
359
  }[] | undefined;
360
360
  }>>>;
@@ -371,20 +371,20 @@ export declare const createModelUpdateValidation: () => zod.ZodObject<{
371
371
  settings: zod.ZodDefault<zod.ZodEffects<zod.ZodOptional<zod.ZodNullable<zod.ZodOptional<zod.ZodObject<{}, "passthrough", zod.ZodTypeAny, zod.objectOutputType<{}, zod.ZodTypeAny, "passthrough">, zod.objectInputType<{}, zod.ZodTypeAny, "passthrough">>>>>, zod.objectOutputType<{}, zod.ZodTypeAny, "passthrough">, zod.objectInputType<{}, zod.ZodTypeAny, "passthrough"> | null | undefined>>;
372
372
  }, "strip", zod.ZodTypeAny, {
373
373
  name: string;
374
- message: string;
375
374
  settings: {} & {
376
375
  [k: string]: unknown;
377
376
  };
377
+ message: string;
378
378
  }, {
379
379
  name: string;
380
380
  message?: string | undefined;
381
381
  settings?: zod.objectInputType<{}, zod.ZodTypeAny, "passthrough"> | null | undefined;
382
382
  }>, "many">>>>>, {
383
383
  name: string;
384
- message: string;
385
384
  settings: {} & {
386
385
  [k: string]: unknown;
387
386
  };
387
+ message: string;
388
388
  }[], {
389
389
  name: string;
390
390
  message?: string | undefined;
@@ -396,20 +396,20 @@ export declare const createModelUpdateValidation: () => zod.ZodObject<{
396
396
  settings: zod.ZodDefault<zod.ZodEffects<zod.ZodOptional<zod.ZodNullable<zod.ZodOptional<zod.ZodObject<{}, "passthrough", zod.ZodTypeAny, zod.objectOutputType<{}, zod.ZodTypeAny, "passthrough">, zod.objectInputType<{}, zod.ZodTypeAny, "passthrough">>>>>, zod.objectOutputType<{}, zod.ZodTypeAny, "passthrough">, zod.objectInputType<{}, zod.ZodTypeAny, "passthrough"> | null | undefined>>;
397
397
  }, "strip", zod.ZodTypeAny, {
398
398
  name: string;
399
- message: string;
400
399
  settings: {} & {
401
400
  [k: string]: unknown;
402
401
  };
402
+ message: string;
403
403
  }, {
404
404
  name: string;
405
405
  message?: string | undefined;
406
406
  settings?: zod.objectInputType<{}, zod.ZodTypeAny, "passthrough"> | null | undefined;
407
407
  }>, "many">>>>>, {
408
408
  name: string;
409
- message: string;
410
409
  settings: {} & {
411
410
  [k: string]: unknown;
412
411
  };
412
+ message: string;
413
413
  }[], {
414
414
  name: string;
415
415
  message?: string | undefined;
@@ -417,11 +417,8 @@ export declare const createModelUpdateValidation: () => zod.ZodObject<{
417
417
  }[] | null | undefined>;
418
418
  settings: zod.ZodDefault<zod.ZodEffects<zod.ZodOptional<zod.ZodNullable<zod.ZodOptional<zod.ZodObject<{}, "passthrough", zod.ZodTypeAny, zod.objectOutputType<{}, zod.ZodTypeAny, "passthrough">, zod.objectInputType<{}, zod.ZodTypeAny, "passthrough">>>>>, zod.objectOutputType<{}, zod.ZodTypeAny, "passthrough">, zod.objectInputType<{}, zod.ZodTypeAny, "passthrough"> | null | undefined>>;
419
419
  }, "strip", zod.ZodTypeAny, {
420
- type: string;
421
420
  id: string;
422
- settings: {} & {
423
- [k: string]: unknown;
424
- };
421
+ type: string;
425
422
  storageId: string;
426
423
  fieldId: string;
427
424
  label: string;
@@ -429,24 +426,27 @@ export declare const createModelUpdateValidation: () => zod.ZodObject<{
429
426
  placeholderText: string | null;
430
427
  validation: {
431
428
  name: string;
432
- message: string;
433
429
  settings: {} & {
434
430
  [k: string]: unknown;
435
431
  };
432
+ message: string;
436
433
  }[];
437
434
  listValidation: {
438
435
  name: string;
439
- message: string;
440
436
  settings: {} & {
441
437
  [k: string]: unknown;
442
438
  };
439
+ message: string;
443
440
  }[];
444
441
  multipleValues: boolean;
445
442
  tags: string[];
443
+ settings: {} & {
444
+ [k: string]: unknown;
445
+ };
446
446
  predefinedValues?: {
447
447
  values: {
448
- value: string;
449
448
  label: string;
449
+ value: string;
450
450
  selected: boolean;
451
451
  }[];
452
452
  enabled: boolean;
@@ -455,8 +455,8 @@ export declare const createModelUpdateValidation: () => zod.ZodObject<{
455
455
  name: string;
456
456
  } | undefined;
457
457
  }, {
458
- type: string;
459
458
  id: string;
459
+ type: string;
460
460
  fieldId: string;
461
461
  label: string;
462
462
  storageId?: string | undefined;
@@ -467,8 +467,8 @@ export declare const createModelUpdateValidation: () => zod.ZodObject<{
467
467
  predefinedValues?: {
468
468
  enabled: boolean;
469
469
  values?: {
470
- value: string;
471
470
  label: string;
471
+ value: string;
472
472
  selected?: boolean | undefined;
473
473
  }[] | undefined;
474
474
  } | undefined;
@@ -494,11 +494,8 @@ export declare const createModelUpdateValidation: () => zod.ZodObject<{
494
494
  tags: zod.ZodOptional<zod.ZodArray<zod.ZodString, "many">>;
495
495
  }, "strip", zod.ZodTypeAny, {
496
496
  fields: {
497
- type: string;
498
497
  id: string;
499
- settings: {} & {
500
- [k: string]: unknown;
501
- };
498
+ type: string;
502
499
  storageId: string;
503
500
  fieldId: string;
504
501
  label: string;
@@ -506,24 +503,27 @@ export declare const createModelUpdateValidation: () => zod.ZodObject<{
506
503
  placeholderText: string | null;
507
504
  validation: {
508
505
  name: string;
509
- message: string;
510
506
  settings: {} & {
511
507
  [k: string]: unknown;
512
508
  };
509
+ message: string;
513
510
  }[];
514
511
  listValidation: {
515
512
  name: string;
516
- message: string;
517
513
  settings: {} & {
518
514
  [k: string]: unknown;
519
515
  };
516
+ message: string;
520
517
  }[];
521
518
  multipleValues: boolean;
522
519
  tags: string[];
520
+ settings: {} & {
521
+ [k: string]: unknown;
522
+ };
523
523
  predefinedValues?: {
524
524
  values: {
525
- value: string;
526
525
  label: string;
526
+ value: string;
527
527
  selected: boolean;
528
528
  }[];
529
529
  enabled: boolean;
@@ -545,8 +545,8 @@ export declare const createModelUpdateValidation: () => zod.ZodObject<{
545
545
  tags?: string[] | undefined;
546
546
  }, {
547
547
  fields: {
548
- type: string;
549
548
  id: string;
549
+ type: string;
550
550
  fieldId: string;
551
551
  label: string;
552
552
  storageId?: string | undefined;
@@ -557,8 +557,8 @@ export declare const createModelUpdateValidation: () => zod.ZodObject<{
557
557
  predefinedValues?: {
558
558
  enabled: boolean;
559
559
  values?: {
560
- value: string;
561
560
  label: string;
561
+ value: string;
562
562
  selected?: boolean | undefined;
563
563
  }[] | undefined;
564
564
  } | undefined;
@@ -150,8 +150,7 @@ const createModelsCrud = params => {
150
150
  return false;
151
151
  }
152
152
  return modelsPermissions.canAccessModel({
153
- model,
154
- locale: getLocale().code
153
+ model
155
154
  });
156
155
  });
157
156
  });
@@ -164,8 +163,7 @@ const createModelsCrud = params => {
164
163
  owns: model.createdBy
165
164
  });
166
165
  await modelsPermissions.ensureCanAccessModel({
167
- model,
168
- locale: getLocale().code
166
+ model
169
167
  });
170
168
  return model;
171
169
  });