@panneau/protocol 5.0.0-alpha.3 → 5.0.0-alpha.5
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/conformance/index.d.ts.map +1 -1
- package/dist/conformance/index.js +151 -1
- package/dist/conformance/index.js.map +1 -1
- package/dist/constants.d.ts +2 -2
- package/dist/constants.d.ts.map +1 -1
- package/dist/constants.js +3 -1
- package/dist/constants.js.map +1 -1
- package/dist/index.js +5 -2
- package/dist/libraries.d.ts +16 -0
- package/dist/libraries.d.ts.map +1 -0
- package/dist/libraries.js +15 -0
- package/dist/libraries.js.map +1 -0
- package/dist/lint.d.ts +2 -1
- package/dist/lint.d.ts.map +1 -1
- package/dist/lint.js +34 -2
- package/dist/lint.js.map +1 -1
- package/dist/mock/example.d.ts +2 -1
- package/dist/mock/example.d.ts.map +1 -1
- package/dist/mock/example.js +227 -143
- package/dist/mock/example.js.map +1 -1
- package/dist/mock/index.d.ts +9 -1
- package/dist/mock/index.d.ts.map +1 -1
- package/dist/mock/index.js +257 -11
- package/dist/mock/index.js.map +1 -1
- package/dist/openapi.d.ts.map +1 -1
- package/dist/openapi.js +55 -101
- package/dist/openapi.js.map +1 -1
- package/dist/rules.d.ts.map +1 -1
- package/dist/rules.js +17 -0
- package/dist/rules.js.map +1 -1
- package/dist/runtime/index.d.ts +3 -0
- package/dist/runtime/index.d.ts.map +1 -1
- package/dist/runtime/index.js +4 -1
- package/dist/schemas/action.d.ts +17 -1
- package/dist/schemas/action.d.ts.map +1 -1
- package/dist/schemas/api.d.ts +155 -37
- package/dist/schemas/api.d.ts.map +1 -1
- package/dist/schemas/api.js +89 -28
- package/dist/schemas/api.js.map +1 -1
- package/dist/schemas/definition.d.ts +39 -2
- package/dist/schemas/definition.d.ts.map +1 -1
- package/dist/schemas/definition.js +4 -3
- package/dist/schemas/definition.js.map +1 -1
- package/dist/schemas/field.d.ts +24 -1
- package/dist/schemas/field.d.ts.map +1 -1
- package/dist/schemas/field.js +22 -4
- package/dist/schemas/field.js.map +1 -1
- package/dist/schemas/index.d.ts +262 -40
- package/dist/schemas/index.d.ts.map +1 -1
- package/dist/schemas/index.js +13 -5
- package/dist/schemas/index.js.map +1 -1
- package/dist/schemas/resource.d.ts +37 -2
- package/dist/schemas/resource.d.ts.map +1 -1
- package/dist/schemas/resource.js +4 -1
- package/dist/schemas/resource.js.map +1 -1
- package/dist/search.d.ts +51 -0
- package/dist/search.d.ts.map +1 -0
- package/dist/search.js +53 -0
- package/dist/search.js.map +1 -0
- package/dist/transforms.d.ts +17 -0
- package/dist/transforms.d.ts.map +1 -0
- package/dist/transforms.js +34 -0
- package/dist/transforms.js.map +1 -0
- package/package.json +1 -1
- package/schema/boot.schema.json +84 -1
- package/schema/definition.schema.json +84 -1
- package/schema/openapi.json +771 -605
package/dist/schemas/api.d.ts
CHANGED
|
@@ -217,22 +217,76 @@ export declare const MediaTransform: z.ZodObject<{
|
|
|
217
217
|
x: z.ZodNumber;
|
|
218
218
|
y: z.ZodNumber;
|
|
219
219
|
}, z.core.$loose>>;
|
|
220
|
+
base: z.ZodOptional<z.ZodEnum<{
|
|
221
|
+
media: "media";
|
|
222
|
+
original: "original";
|
|
223
|
+
}>>;
|
|
224
|
+
baseTransform: z.ZodOptional<typeof MediaTransform>;
|
|
220
225
|
}, z.core.$loose>;
|
|
221
|
-
export declare const
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
type: z.ZodString;
|
|
226
|
+
export declare const UploadReference: z.ZodObject<{
|
|
227
|
+
upload: z.ZodString;
|
|
228
|
+
}, z.core.$loose>;
|
|
229
|
+
export declare const StoredFile: z.ZodObject<{
|
|
226
230
|
name: z.ZodString;
|
|
227
|
-
|
|
228
|
-
|
|
231
|
+
url: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
232
|
+
mime: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
233
|
+
size: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
234
|
+
}, z.core.$loose>;
|
|
235
|
+
export declare const Upload: z.ZodObject<{
|
|
236
|
+
id: z.ZodString;
|
|
237
|
+
key: z.ZodOptional<z.ZodString>;
|
|
238
|
+
name: z.ZodOptional<z.ZodString>;
|
|
239
|
+
mime: z.ZodOptional<z.ZodString>;
|
|
240
|
+
size: z.ZodOptional<z.ZodNumber>;
|
|
241
|
+
}, z.core.$loose>;
|
|
242
|
+
export declare const UploadResponse: z.ZodObject<{
|
|
243
|
+
data: z.ZodObject<{
|
|
244
|
+
id: z.ZodString;
|
|
245
|
+
key: z.ZodOptional<z.ZodString>;
|
|
246
|
+
name: z.ZodOptional<z.ZodString>;
|
|
247
|
+
mime: z.ZodOptional<z.ZodString>;
|
|
248
|
+
size: z.ZodOptional<z.ZodNumber>;
|
|
249
|
+
}, z.core.$loose>;
|
|
250
|
+
}, z.core.$loose>;
|
|
251
|
+
export declare const UploadSignRequest: z.ZodObject<{
|
|
252
|
+
method: z.ZodEnum<{
|
|
253
|
+
GET: "GET";
|
|
254
|
+
POST: "POST";
|
|
255
|
+
PUT: "PUT";
|
|
256
|
+
DELETE: "DELETE";
|
|
257
|
+
}>;
|
|
258
|
+
key: z.ZodString;
|
|
259
|
+
uploadId: z.ZodOptional<z.ZodString>;
|
|
260
|
+
partNumber: z.ZodOptional<z.ZodNumber>;
|
|
261
|
+
contentType: z.ZodOptional<z.ZodString>;
|
|
262
|
+
expiresIn: z.ZodOptional<z.ZodNumber>;
|
|
263
|
+
}, z.core.$loose>;
|
|
264
|
+
export declare const UploadSignResponse: z.ZodObject<{
|
|
229
265
|
url: z.ZodString;
|
|
266
|
+
key: z.ZodOptional<z.ZodString>;
|
|
267
|
+
headers: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
268
|
+
upload: z.ZodOptional<z.ZodString>;
|
|
269
|
+
}, z.core.$loose>;
|
|
270
|
+
export declare const MediaInfo: z.ZodObject<{
|
|
271
|
+
type: z.ZodString;
|
|
272
|
+
mime: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
273
|
+
size: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
274
|
+
url: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
230
275
|
thumbnailUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
231
276
|
variants: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
232
277
|
url: z.ZodString;
|
|
233
278
|
width: z.ZodOptional<z.ZodNumber>;
|
|
234
279
|
height: z.ZodOptional<z.ZodNumber>;
|
|
235
280
|
}, z.core.$loose>>>;
|
|
281
|
+
width: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
282
|
+
height: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
283
|
+
duration: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
284
|
+
status: z.ZodOptional<z.ZodEnum<{
|
|
285
|
+
failed: "failed";
|
|
286
|
+
pending: "pending";
|
|
287
|
+
processing: "processing";
|
|
288
|
+
ready: "ready";
|
|
289
|
+
}>>;
|
|
236
290
|
metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
237
291
|
transform: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
238
292
|
crop: z.ZodOptional<z.ZodObject<{
|
|
@@ -248,25 +302,37 @@ export declare const Media: z.ZodObject<{
|
|
|
248
302
|
x: z.ZodNumber;
|
|
249
303
|
y: z.ZodNumber;
|
|
250
304
|
}, z.core.$loose>>;
|
|
305
|
+
base: z.ZodOptional<z.ZodEnum<{
|
|
306
|
+
media: "media";
|
|
307
|
+
original: "original";
|
|
308
|
+
}>>;
|
|
309
|
+
baseTransform: z.ZodOptional<typeof MediaTransform>;
|
|
251
310
|
}, z.core.$loose>>>;
|
|
252
|
-
tags: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
253
311
|
}, z.core.$loose>;
|
|
254
|
-
export declare const
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
312
|
+
export declare const MediaItem: z.ZodObject<{
|
|
313
|
+
id: z.ZodString;
|
|
314
|
+
version: z.ZodNullable<z.ZodString>;
|
|
315
|
+
abilities: z.ZodRecord<z.ZodString, z.ZodBoolean>;
|
|
316
|
+
media: z.ZodObject<{
|
|
259
317
|
type: z.ZodString;
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
url: z.ZodString;
|
|
318
|
+
mime: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
319
|
+
size: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
320
|
+
url: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
264
321
|
thumbnailUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
265
322
|
variants: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
266
323
|
url: z.ZodString;
|
|
267
324
|
width: z.ZodOptional<z.ZodNumber>;
|
|
268
325
|
height: z.ZodOptional<z.ZodNumber>;
|
|
269
326
|
}, z.core.$loose>>>;
|
|
327
|
+
width: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
328
|
+
height: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
329
|
+
duration: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
330
|
+
status: z.ZodOptional<z.ZodEnum<{
|
|
331
|
+
failed: "failed";
|
|
332
|
+
pending: "pending";
|
|
333
|
+
processing: "processing";
|
|
334
|
+
ready: "ready";
|
|
335
|
+
}>>;
|
|
270
336
|
metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
271
337
|
transform: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
272
338
|
crop: z.ZodOptional<z.ZodObject<{
|
|
@@ -282,26 +348,38 @@ export declare const MediaResponse: z.ZodObject<{
|
|
|
282
348
|
x: z.ZodNumber;
|
|
283
349
|
y: z.ZodNumber;
|
|
284
350
|
}, z.core.$loose>>;
|
|
351
|
+
base: z.ZodOptional<z.ZodEnum<{
|
|
352
|
+
media: "media";
|
|
353
|
+
original: "original";
|
|
354
|
+
}>>;
|
|
355
|
+
baseTransform: z.ZodOptional<typeof MediaTransform>;
|
|
285
356
|
}, z.core.$loose>>>;
|
|
286
|
-
tags: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
287
357
|
}, z.core.$loose>;
|
|
288
358
|
}, z.core.$loose>;
|
|
289
|
-
export declare const
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
359
|
+
export declare const MediaReference: z.ZodObject<{
|
|
360
|
+
id: z.ZodString;
|
|
361
|
+
resource: z.ZodOptional<z.ZodString>;
|
|
362
|
+
label: z.ZodOptional<z.ZodString>;
|
|
363
|
+
media: z.ZodOptional<z.ZodObject<{
|
|
294
364
|
type: z.ZodString;
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
url: z.ZodString;
|
|
365
|
+
mime: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
366
|
+
size: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
367
|
+
url: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
299
368
|
thumbnailUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
300
369
|
variants: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
301
370
|
url: z.ZodString;
|
|
302
371
|
width: z.ZodOptional<z.ZodNumber>;
|
|
303
372
|
height: z.ZodOptional<z.ZodNumber>;
|
|
304
373
|
}, z.core.$loose>>>;
|
|
374
|
+
width: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
375
|
+
height: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
376
|
+
duration: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
377
|
+
status: z.ZodOptional<z.ZodEnum<{
|
|
378
|
+
failed: "failed";
|
|
379
|
+
pending: "pending";
|
|
380
|
+
processing: "processing";
|
|
381
|
+
ready: "ready";
|
|
382
|
+
}>>;
|
|
305
383
|
metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
306
384
|
transform: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
307
385
|
crop: z.ZodOptional<z.ZodObject<{
|
|
@@ -317,15 +395,46 @@ export declare const MediaListResponse: z.ZodObject<{
|
|
|
317
395
|
x: z.ZodNumber;
|
|
318
396
|
y: z.ZodNumber;
|
|
319
397
|
}, z.core.$loose>>;
|
|
398
|
+
base: z.ZodOptional<z.ZodEnum<{
|
|
399
|
+
media: "media";
|
|
400
|
+
original: "original";
|
|
401
|
+
}>>;
|
|
402
|
+
baseTransform: z.ZodOptional<typeof MediaTransform>;
|
|
320
403
|
}, z.core.$loose>>>;
|
|
321
|
-
tags: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
322
404
|
}, z.core.$loose>>;
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
405
|
+
transform: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
406
|
+
crop: z.ZodOptional<z.ZodObject<{
|
|
407
|
+
x: z.ZodNumber;
|
|
408
|
+
y: z.ZodNumber;
|
|
409
|
+
width: z.ZodNumber;
|
|
410
|
+
height: z.ZodNumber;
|
|
411
|
+
}, z.core.$loose>>;
|
|
412
|
+
rotate: z.ZodOptional<z.ZodUnion<readonly [z.ZodLiteral<0>, z.ZodLiteral<90>, z.ZodLiteral<180>, z.ZodLiteral<270>]>>;
|
|
413
|
+
flipX: z.ZodOptional<z.ZodBoolean>;
|
|
414
|
+
flipY: z.ZodOptional<z.ZodBoolean>;
|
|
415
|
+
focalPoint: z.ZodOptional<z.ZodObject<{
|
|
416
|
+
x: z.ZodNumber;
|
|
417
|
+
y: z.ZodNumber;
|
|
418
|
+
}, z.core.$loose>>;
|
|
419
|
+
base: z.ZodOptional<z.ZodEnum<{
|
|
420
|
+
media: "media";
|
|
421
|
+
original: "original";
|
|
422
|
+
}>>;
|
|
423
|
+
baseTransform: z.ZodOptional<typeof MediaTransform>;
|
|
424
|
+
}, z.core.$loose>>>;
|
|
425
|
+
}, z.core.$loose>;
|
|
426
|
+
export declare const FieldCheckRequest: z.ZodObject<{
|
|
427
|
+
value: z.ZodString;
|
|
428
|
+
locale: z.ZodOptional<z.ZodString>;
|
|
429
|
+
id: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
430
|
+
values: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
431
|
+
}, z.core.$loose>;
|
|
432
|
+
export declare const FieldCheckResponse: z.ZodObject<{
|
|
433
|
+
available: z.ZodBoolean;
|
|
434
|
+
suggestion: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
435
|
+
prefix: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
436
|
+
url: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
437
|
+
disabled: z.ZodOptional<z.ZodBoolean>;
|
|
329
438
|
}, z.core.$loose>;
|
|
330
439
|
export declare const Session: z.ZodObject<{
|
|
331
440
|
user: z.ZodObject<{
|
|
@@ -334,6 +443,7 @@ export declare const Session: z.ZodObject<{
|
|
|
334
443
|
email: z.ZodOptional<z.ZodString>;
|
|
335
444
|
avatarUrl: z.ZodOptional<z.ZodString>;
|
|
336
445
|
abilities: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
|
|
446
|
+
resource: z.ZodOptional<z.ZodString>;
|
|
337
447
|
}, z.core.$loose>;
|
|
338
448
|
}, z.core.$loose>;
|
|
339
449
|
export declare const SearchResponse: z.ZodObject<{
|
|
@@ -363,9 +473,17 @@ export type ActionResult = z.infer<typeof ActionResult>;
|
|
|
363
473
|
export type ActionRun = z.infer<typeof ActionRun>;
|
|
364
474
|
export type ActionRunResponse = z.infer<typeof ActionRunResponse>;
|
|
365
475
|
export type MediaTransform = z.infer<typeof MediaTransform>;
|
|
366
|
-
export type
|
|
367
|
-
export type
|
|
368
|
-
export type
|
|
476
|
+
export type UploadReference = z.infer<typeof UploadReference>;
|
|
477
|
+
export type StoredFile = z.infer<typeof StoredFile>;
|
|
478
|
+
export type Upload = z.infer<typeof Upload>;
|
|
479
|
+
export type UploadResponse = z.infer<typeof UploadResponse>;
|
|
480
|
+
export type UploadSignRequest = z.infer<typeof UploadSignRequest>;
|
|
481
|
+
export type UploadSignResponse = z.infer<typeof UploadSignResponse>;
|
|
482
|
+
export type FieldCheckRequest = z.infer<typeof FieldCheckRequest>;
|
|
483
|
+
export type FieldCheckResponse = z.infer<typeof FieldCheckResponse>;
|
|
484
|
+
export type MediaInfo = z.infer<typeof MediaInfo>;
|
|
485
|
+
export type MediaItem = z.infer<typeof MediaItem>;
|
|
486
|
+
export type MediaReference = z.infer<typeof MediaReference>;
|
|
369
487
|
export type Session = z.infer<typeof Session>;
|
|
370
488
|
export type SearchResponse = z.infer<typeof SearchResponse>;
|
|
371
489
|
export type PreviewResponse = z.infer<typeof PreviewResponse>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"api.d.ts","sourceRoot":"","sources":["../../src/schemas/api.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,eAAO,MAAM,IAAI;;;;iBAUX,CAAC;AAEP,eAAO,MAAM,UAAU;;;;;iBAKrB,CAAC;AAEH,eAAO,MAAM,YAAY;;;;;;iBAAgC,CAAC;AAE1D,eAAO,MAAM,YAAY;;;;;;;;;;;;iBAA2D,CAAC;AAErF,eAAO,MAAM,OAAO;;;;;;;;;;;;iBAa6E,CAAC;AAElG,eAAO,MAAM,SAAS;;;;;;;;mBAYpB,CAAC;AAEH,eAAO,MAAM,aAAa;;;;;;;;;;;;iBASxB,CAAC;AAEH,eAAO,MAAM,gBAAgB;;;;;;;;iBAQ3B,CAAC;AAEH,eAAO,M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AAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,CAAC;AACpE,MAAM,MAAM,SAAS,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,SAAS,CAAC,CAAC;AAClD,MAAM,MAAM,SAAS,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,SAAS,CAAC,CAAC;AAClD,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;AAC5D,MAAM,MAAM,OAAO,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,OAAO,CAAC,CAAC;AAC9C,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;AAC5D,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,eAAe,CAAC,CAAC"}
|
package/dist/schemas/api.js
CHANGED
|
@@ -86,56 +86,117 @@ var ActionRun = z.looseObject({
|
|
|
86
86
|
var ActionRunResponse = z.looseObject({ run: ActionRun });
|
|
87
87
|
var MediaTransform = z.looseObject({
|
|
88
88
|
crop: z.looseObject({
|
|
89
|
-
x: z.number(),
|
|
90
|
-
y: z.number(),
|
|
91
|
-
width: z.number(),
|
|
92
|
-
height: z.number()
|
|
93
|
-
}).optional().meta({ description: "In pixels of the original image." }),
|
|
89
|
+
x: z.number().int().nonnegative(),
|
|
90
|
+
y: z.number().int().nonnegative(),
|
|
91
|
+
width: z.number().int().positive(),
|
|
92
|
+
height: z.number().int().positive()
|
|
93
|
+
}).optional().meta({ description: "In whole pixels of the upright original image (after its EXIF orientation), from its top left corner." }),
|
|
94
94
|
rotate: z.union([
|
|
95
95
|
z.literal(0),
|
|
96
96
|
z.literal(90),
|
|
97
97
|
z.literal(180),
|
|
98
98
|
z.literal(270)
|
|
99
|
-
]).optional(),
|
|
100
|
-
flipX: z.boolean().optional(),
|
|
101
|
-
flipY: z.boolean().optional(),
|
|
99
|
+
]).optional().meta({ description: "Clockwise, in degrees." }),
|
|
100
|
+
flipX: z.boolean().optional().meta({ description: "Mirrors left to right (horizontal)." }),
|
|
101
|
+
flipY: z.boolean().optional().meta({ description: "Mirrors top to bottom (vertical)." }),
|
|
102
102
|
focalPoint: z.looseObject({
|
|
103
103
|
x: z.number().min(0).max(1),
|
|
104
104
|
y: z.number().min(0).max(1)
|
|
105
|
-
}).optional().meta({ description: "
|
|
106
|
-
})
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
105
|
+
}).optional().meta({ description: "From 0 to 1, relative to the width and height of the upright original image, not of the crop: changing the crop does not move it. Renderers map it into the transformed image and clamp it to the crop." }),
|
|
106
|
+
base: z.enum(["media", "original"]).optional().meta({ description: "What a transform for one use starts from: the original file by default, or the media's own transform (`media`). With `media`, the crop and the focal point are relative to the media's version instead of the original (decision 0031)." }),
|
|
107
|
+
get baseTransform() {
|
|
108
|
+
return MediaTransform.optional().meta({ description: "With `base: \"media\"`: the media's own transform this one was made on. When the media's transform is no longer the same, clients ask to check the crop, and renderers clamp it." });
|
|
109
|
+
}
|
|
110
|
+
}).meta({ description: "Non-destructive edits of an image, applied in this order: crop, then rotate, then flip. Renderers ignore the keys they don't know, which editor tools can add." });
|
|
111
|
+
var UploadReference = z.looseObject({ upload: z.string().min(1) }).meta({ description: "A file uploaded directly to storage, by the id of its upload: in a file value, such as the `file` of a media, or an action parameter." });
|
|
112
|
+
var StoredFile = z.looseObject({
|
|
113
|
+
name: z.string().meta({ description: "The name of the file, as the user knows it." }),
|
|
114
|
+
url: z.string().nullable().optional().meta({ description: "Where to download it. A private file gets a temporary URL." }),
|
|
115
|
+
mime: z.string().nullable().optional(),
|
|
116
|
+
size: z.number().int().nonnegative().nullable().optional()
|
|
117
|
+
}).meta({ description: "A file stored by the backend: the value of a `file` field in items. Requests send it back to keep the file, `{ \"upload\" }` to replace it, or `null` to remove it." });
|
|
118
|
+
var Upload = z.looseObject({
|
|
119
|
+
id: z.string().min(1).meta({ description: "The id of the upload: `upl_…`." }),
|
|
120
|
+
key: z.string().optional().meta({ description: "The key of the object in storage." }),
|
|
121
|
+
name: z.string().optional(),
|
|
122
|
+
mime: z.string().optional(),
|
|
123
|
+
size: z.number().int().nonnegative().optional()
|
|
124
|
+
}).meta({ description: "A file the browser uploaded to storage, before it becomes a media, an import or another value." });
|
|
125
|
+
var UploadResponse = z.looseObject({ data: Upload });
|
|
126
|
+
var UploadSignRequest = z.looseObject({
|
|
127
|
+
method: z.enum([
|
|
128
|
+
"GET",
|
|
129
|
+
"POST",
|
|
130
|
+
"PUT",
|
|
131
|
+
"DELETE"
|
|
132
|
+
]),
|
|
133
|
+
key: z.string().min(1),
|
|
134
|
+
uploadId: z.string().optional().meta({ description: "The S3 multipart upload." }),
|
|
135
|
+
partNumber: z.number().int().positive().optional(),
|
|
136
|
+
contentType: z.string().optional(),
|
|
137
|
+
expiresIn: z.number().int().positive().optional()
|
|
138
|
+
}).meta({ description: "A request of the browser's S3 client to sign (Uppy 6's `signRequest`)." });
|
|
139
|
+
var UploadSignResponse = z.looseObject({
|
|
112
140
|
url: z.string(),
|
|
141
|
+
key: z.string().optional().meta({ description: "The key the backend chose, for the first request of a file." }),
|
|
142
|
+
headers: z.record(z.string(), z.string()).optional().meta({ description: "Headers the URL was signed with, which the browser sends." }),
|
|
143
|
+
upload: z.string().optional().meta({ description: "The upload the first request of a file created: `upl_…`." })
|
|
144
|
+
}).meta({ description: "A presigned request." });
|
|
145
|
+
var MediaInfo = z.looseObject({
|
|
146
|
+
type: z.string().meta({ description: "`image`, `video`, `audio`, `document`, `font`, or another type the backend knows." }),
|
|
147
|
+
mime: z.string().nullable().optional(),
|
|
148
|
+
size: z.number().int().nonnegative().nullable().optional(),
|
|
149
|
+
url: z.string().nullable().optional().meta({ description: "The main file to show or play: a rendition, or the original until it exists." }),
|
|
113
150
|
thumbnailUrl: z.string().nullable().optional(),
|
|
114
151
|
variants: z.record(z.string(), z.looseObject({
|
|
115
152
|
url: z.string(),
|
|
116
153
|
width: z.number().optional(),
|
|
117
154
|
height: z.number().optional()
|
|
118
|
-
})).optional(),
|
|
155
|
+
})).optional().meta({ description: "Named renditions: sizes of an image, qualities of a video." }),
|
|
156
|
+
width: z.number().nullable().optional(),
|
|
157
|
+
height: z.number().nullable().optional(),
|
|
158
|
+
duration: z.number().nullable().optional().meta({ description: "In seconds." }),
|
|
159
|
+
status: z.enum([
|
|
160
|
+
"pending",
|
|
161
|
+
"processing",
|
|
162
|
+
"ready",
|
|
163
|
+
"failed"
|
|
164
|
+
]).optional().meta({ description: "Where the processing of the file is: `pending` and `processing` until its renditions are made, then `ready` or `failed`. Without it, the media is ready." }),
|
|
119
165
|
metadata: z.record(z.string(), z.unknown()).optional(),
|
|
120
|
-
transform: MediaTransform.nullable().optional(),
|
|
121
|
-
|
|
122
|
-
});
|
|
123
|
-
var
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
meta:
|
|
127
|
-
|
|
166
|
+
transform: MediaTransform.nullable().optional().meta({ description: "The media's own transform, from its library, which clients need to draw a transform for one use made over it (decision 0031)." })
|
|
167
|
+
}).meta({ description: "What the backend computed about the file of a media item: the `media` of the items of a `media` resource, and of the values of `media` fields. Read-only: the editable properties of a media are the fields of its resource." });
|
|
168
|
+
var MediaItem = Item.extend({ media: MediaInfo }).meta({ description: "An item of a resource of kind `media`: the values of its fields (`file`, the original, and those of the project), and the `media` the backend computed." });
|
|
169
|
+
var MediaReference = z.looseObject({
|
|
170
|
+
id: Id,
|
|
171
|
+
resource: z.string().optional().meta({ description: "The library of the media. Required for a field that allows several libraries, since ids are unique only within their resource (decision 0027)." }),
|
|
172
|
+
label: z.string().optional().meta({ description: "The `itemTitle` of the media." }),
|
|
173
|
+
media: MediaInfo.optional(),
|
|
174
|
+
transform: MediaTransform.nullable().optional().meta({ description: "The edits of the image for this use only: from the original file, or over the media's own transform with `base: \"media\"`." })
|
|
175
|
+
}).meta({ description: "The value of a `media` or `image` field in items: the media, with what lists and fields show, and its edits for this use. Requests send the id, or `{ id, resource, transform }`: `resource` is required when the field allows several libraries." });
|
|
176
|
+
var FieldCheckRequest = z.looseObject({
|
|
177
|
+
value: z.string().meta({ description: "The value to check, as it is typed." }),
|
|
178
|
+
locale: z.string().optional().meta({ description: "The locale of the value, for a localized field." }),
|
|
179
|
+
id: Id.nullable().optional().meta({ description: "The item being edited, or null when creating one." }),
|
|
180
|
+
values: z.record(z.string(), z.unknown()).optional().meta({ description: "The form's current values, as they would be sent to save, for what the check depends on (a page's parent)." })
|
|
181
|
+
}).meta({ description: "A value of a field with `check`, to check with the backend." });
|
|
182
|
+
var FieldCheckResponse = z.looseObject({
|
|
183
|
+
available: z.boolean().meta({ description: "Whether no other item of the resource, in its scope and the same locale, has the value." }),
|
|
184
|
+
suggestion: z.string().nullable().optional().meta({ description: "An available value close to the one checked, when it is taken." }),
|
|
185
|
+
prefix: z.string().nullable().optional().meta({ description: "What the field shows in front of the value: the start of its URL." }),
|
|
186
|
+
url: z.string().nullable().optional().meta({ description: "The URL the value gives the item, which the field links to." }),
|
|
187
|
+
disabled: z.boolean().optional().meta({ description: "The field doesn't apply to this item (the home page has no slug): the field is read-only." })
|
|
188
|
+
}).meta({ description: "What the backend says about a value: not authoritative, since saving still validates it." });
|
|
128
189
|
var Session = z.looseObject({ user: User });
|
|
129
190
|
var SearchResponse = z.looseObject({ data: z.array(z.looseObject({
|
|
130
|
-
resource: z.string(),
|
|
191
|
+
resource: z.string().meta({ description: "The id of the resource." }),
|
|
131
192
|
items: z.array(Item),
|
|
132
|
-
total: z.number().int().nonnegative().optional()
|
|
133
|
-
})) });
|
|
193
|
+
total: z.number().int().nonnegative().optional().meta({ description: "How many items of the resource match, when the backend counts them: the list of the resource, searched, shows them all." })
|
|
194
|
+
})) }).meta({ description: "The results of the global search: the resources with results, in the order of the definition." });
|
|
134
195
|
var PreviewResponse = z.looseObject({
|
|
135
196
|
url: z.string(),
|
|
136
197
|
expiresAt: z.string().optional()
|
|
137
198
|
});
|
|
138
199
|
//#endregion
|
|
139
|
-
export { ActionItemResult, ActionRequest, ActionResult, ActionRun, ActionRunResponse, Item, ItemResponse, ListResponse,
|
|
200
|
+
export { ActionItemResult, ActionRequest, ActionResult, ActionRun, ActionRunResponse, FieldCheckRequest, FieldCheckResponse, Item, ItemResponse, ListResponse, MediaInfo, MediaItem, MediaReference, MediaTransform, Pagination, PreviewResponse, Problem, SearchResponse, Selection, Session, StoredFile, Upload, UploadReference, UploadResponse, UploadSignRequest, UploadSignResponse };
|
|
140
201
|
|
|
141
202
|
//# sourceMappingURL=api.js.map
|
package/dist/schemas/api.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"api.js","names":[],"sources":["../../src/schemas/api.ts"],"sourcesContent":["import { z } from 'zod';\n\nimport { Abilities, Id, RouteReference } from './common';\nimport { User } from './definition';\n\nexport const Item = z\n .looseObject({\n id: Id,\n version: z.string().nullable().meta({\n description: 'Changes on every update. `null` when the backend has no versions.',\n }),\n abilities: Abilities,\n })\n .meta({\n description: 'An item of a resource. Its other properties are the values of its fields.',\n });\n\nexport const Pagination = z.looseObject({\n page: z.number().int().positive(),\n perPage: z.number().int().positive(),\n total: z.number().int().nonnegative(),\n lastPage: z.number().int().positive(),\n});\n\nexport const ItemResponse = z.looseObject({ data: Item });\n\nexport const ListResponse = z.looseObject({ data: z.array(Item), meta: Pagination });\n\nexport const Problem = z\n .looseObject({\n type: z.string().meta({ description: 'A URI reference that identifies the problem type.' }),\n title: z.string(),\n status: z.number().int().min(400).max(599),\n detail: z.string().optional(),\n instance: z.string().optional(),\n errors: z\n .record(z.string(), z.array(z.string()))\n .optional()\n .meta({ description: '`422`: messages keyed by the dot path of the invalid value.' }),\n current: Item.optional().meta({ description: '`412`: the current version of the item.' }),\n })\n .meta({ description: 'An error, as RFC 9457 problem details (`application/problem+json`).' });\n\nexport const Selection = z.union([\n z.looseObject({ ids: z.array(Id).min(1) }),\n z.looseObject({\n query: z.looseObject({\n filter: z.record(z.string(), z.unknown()).optional().meta({\n description:\n 'The `filter` of the list query, by filter id: a value, a list of values, or the bounds of a range (`{ \"from\": \"2026-01-01\", \"to\": \"2026-01-31\" }`).',\n }),\n q: z.string().optional(),\n }),\n except: z.array(Id).optional(),\n }),\n]);\n\nexport const ActionRequest = z.looseObject({\n selection: Selection.optional().meta({\n description: 'Omitted for actions on the whole resource.',\n }),\n values: z.record(z.string(), z.unknown()).optional(),\n dryRun: z.boolean().optional().meta({\n description:\n 'Answer what the action would do without running it: a `200` action result whose `summary` counts the items that would succeed and those that would be skipped. Only for actions with `dryRun: true`.',\n }),\n});\n\nexport const ActionItemResult = z.looseObject({\n id: Id,\n status: z.enum(['failed', 'skipped']),\n message: z.string().optional(),\n reason: z\n .string()\n .optional()\n .meta({ description: '`skipped`: `forbidden`, `not_found` or `unchanged`.' }),\n});\n\nexport const ActionResult = z.looseObject({\n message: z.string().optional(),\n summary: z\n .looseObject({\n succeeded: z.number().int().nonnegative(),\n failed: z.number().int().nonnegative(),\n skipped: z.number().int().nonnegative(),\n })\n .optional(),\n results: z\n .array(ActionItemResult)\n .optional()\n .meta({ description: 'The items that did not succeed.' }),\n refresh: z.enum(['none', 'items', 'list']).optional(),\n redirect: z.union([z.string(), RouteReference]).nullable().optional(),\n download: z\n .looseObject({\n url: z.string(),\n filename: z.string().optional(),\n expiresAt: z.string().optional(),\n })\n .nullable()\n .optional(),\n});\n\nexport const ActionRun = z.looseObject({\n id: Id,\n action: z.string(),\n resource: z.string(),\n status: z.enum(['queued', 'running', 'succeeded', 'partial', 'failed', 'cancelled']),\n progress: z.number().int().nonnegative(),\n total: z.number().int().nonnegative().nullable(),\n result: ActionResult.optional().meta({ description: 'Set once the run has finished.' }),\n createdAt: z.string().optional(),\n finishedAt: z.string().nullable().optional(),\n});\n\nexport const ActionRunResponse = z.looseObject({ run: ActionRun });\n\nexport const MediaTransform = z.looseObject({\n crop: z\n .looseObject({ x: z.number(), y: z.number(), width: z.number(), height: z.number() })\n .optional()\n .meta({ description: 'In pixels of the original image.' }),\n rotate: z.union([z.literal(0), z.literal(90), z.literal(180), z.literal(270)]).optional(),\n flipX: z.boolean().optional(),\n flipY: z.boolean().optional(),\n focalPoint: z\n .looseObject({ x: z.number().min(0).max(1), y: z.number().min(0).max(1) })\n .optional()\n .meta({ description: 'Relative to the width and height, from 0 to 1.' }),\n});\n\nexport const Media = Item.extend({\n type: z\n .string()\n .meta({ description: '`image`, `video`, `audio`, `document`, `font`, or another type.' }),\n name: z.string(),\n mime: z.string(),\n size: z.number().int().nonnegative(),\n url: z.string(),\n thumbnailUrl: z.string().nullable().optional(),\n variants: z\n .record(\n z.string(),\n z.looseObject({\n url: z.string(),\n width: z.number().optional(),\n height: z.number().optional(),\n }),\n )\n .optional(),\n metadata: z.record(z.string(), z.unknown()).optional(),\n transform: MediaTransform.nullable().optional(),\n tags: z.array(z.string()).optional(),\n});\n\nexport const MediaResponse = z.looseObject({ data: Media });\n\nexport const MediaListResponse = z.looseObject({ data: z.array(Media), meta: Pagination });\n\nexport const Session = z.looseObject({ user: User });\n\nexport const SearchResponse = z.looseObject({\n data: z.array(\n z.looseObject({\n resource: z.string(),\n items: z.array(Item),\n total: z.number().int().nonnegative().optional(),\n }),\n ),\n});\n\nexport const PreviewResponse = z.looseObject({ url: z.string(), expiresAt: z.string().optional() });\n\nexport type Item = z.infer<typeof Item>;\nexport type Pagination = z.infer<typeof Pagination>;\nexport type ItemResponse = z.infer<typeof ItemResponse>;\nexport type ListResponse = z.infer<typeof ListResponse>;\nexport type Problem = z.infer<typeof Problem>;\nexport type Selection = z.infer<typeof Selection>;\nexport type ActionRequest = z.infer<typeof ActionRequest>;\nexport type ActionItemResult = z.infer<typeof ActionItemResult>;\nexport type ActionResult = z.infer<typeof ActionResult>;\nexport type ActionRun = z.infer<typeof ActionRun>;\nexport type ActionRunResponse = z.infer<typeof ActionRunResponse>;\nexport type MediaTransform = z.infer<typeof MediaTransform>;\nexport type Media = z.infer<typeof Media>;\nexport type MediaResponse = z.infer<typeof MediaResponse>;\nexport type MediaListResponse = z.infer<typeof MediaListResponse>;\nexport type Session = z.infer<typeof Session>;\nexport type SearchResponse = z.infer<typeof SearchResponse>;\nexport type PreviewResponse = z.infer<typeof PreviewResponse>;\n"],"mappings":";;;;AAKA,IAAa,OAAO,EACf,YAAY;CACT,IAAI;CACJ,SAAS,EAAE,OAAO,CAAC,CAAC,SAAS,CAAC,CAAC,KAAK,EAChC,aAAa,oEACjB,CAAC;CACD,WAAW;AACf,CAAC,CAAC,CACD,KAAK,EACF,aAAa,4EACjB,CAAC;AAEL,IAAa,aAAa,EAAE,YAAY;CACpC,MAAM,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS;CAChC,SAAS,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS;CACnC,OAAO,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,YAAY;CACpC,UAAU,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS;AACxC,CAAC;AAED,IAAa,eAAe,EAAE,YAAY,EAAE,MAAM,KAAK,CAAC;AAExD,IAAa,eAAe,EAAE,YAAY;CAAE,MAAM,EAAE,MAAM,IAAI;CAAG,MAAM;AAAW,CAAC;AAEnF,IAAa,UAAU,EAClB,YAAY;CACT,MAAM,EAAE,OAAO,CAAC,CAAC,KAAK,EAAE,aAAa,oDAAoD,CAAC;CAC1F,OAAO,EAAE,OAAO;CAChB,QAAQ,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,IAAI,GAAG,CAAC,CAAC,IAAI,GAAG;CACzC,QAAQ,EAAE,OAAO,CAAC,CAAC,SAAS;CAC5B,UAAU,EAAE,OAAO,CAAC,CAAC,SAAS;CAC9B,QAAQ,EACH,OAAO,EAAE,OAAO,GAAG,EAAE,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC,CACvC,SAAS,CAAC,CACV,KAAK,EAAE,aAAa,8DAA8D,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AAM,EAAE,OAAO,CAAC,CAAC,CAAC,SAAS;AACvC,CAAC;AAED,IAAa,gBAAgB,EAAE,YAAY,EAAE,MAAM,MAAM,CAAC;AAE1D,IAAa,oBAAoB,EAAE,YAAY;CAAE,MAAM,EAAE,MAAM,KAAK;CAAG,MAAM;AAAW,CAAC;AAEzF,IAAa,UAAU,EAAE,YAAY,EAAE,MAAM,KAAK,CAAC;AAEnD,IAAa,iBAAiB,EAAE,YAAY,EACxC,MAAM,EAAE,MACJ,EAAE,YAAY;CACV,UAAU,EAAE,OAAO;CACnB,OAAO,EAAE,MAAM,IAAI;CACnB,OAAO,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS;AACnD,CAAC,CACL,EACJ,CAAC;AAED,IAAa,kBAAkB,EAAE,YAAY;CAAE,KAAK,EAAE,OAAO;CAAG,WAAW,EAAE,OAAO,CAAC,CAAC,SAAS;AAAE,CAAC"}
|
|
1
|
+
{"version":3,"file":"api.js","names":[],"sources":["../../src/schemas/api.ts"],"sourcesContent":["import { z } from 'zod';\n\nimport { Abilities, Id, RouteReference } from './common';\nimport { User } from './definition';\n\nexport const Item = z\n .looseObject({\n id: Id,\n version: z.string().nullable().meta({\n description: 'Changes on every update. `null` when the backend has no versions.',\n }),\n abilities: Abilities,\n })\n .meta({\n description: 'An item of a resource. Its other properties are the values of its fields.',\n });\n\nexport const Pagination = z.looseObject({\n page: z.number().int().positive(),\n perPage: z.number().int().positive(),\n total: z.number().int().nonnegative(),\n lastPage: z.number().int().positive(),\n});\n\nexport const ItemResponse = z.looseObject({ data: Item });\n\nexport const ListResponse = z.looseObject({ data: z.array(Item), meta: Pagination });\n\nexport const Problem = z\n .looseObject({\n type: z.string().meta({ description: 'A URI reference that identifies the problem type.' }),\n title: z.string(),\n status: z.number().int().min(400).max(599),\n detail: z.string().optional(),\n instance: z.string().optional(),\n errors: z\n .record(z.string(), z.array(z.string()))\n .optional()\n .meta({ description: '`422`: messages keyed by the dot path of the invalid value.' }),\n current: Item.optional().meta({ description: '`412`: the current version of the item.' }),\n })\n .meta({ description: 'An error, as RFC 9457 problem details (`application/problem+json`).' });\n\nexport const Selection = z.union([\n z.looseObject({ ids: z.array(Id).min(1) }),\n z.looseObject({\n query: z.looseObject({\n filter: z.record(z.string(), z.unknown()).optional().meta({\n description:\n 'The `filter` of the list query, by filter id: a value, a list of values, or the bounds of a range (`{ \"from\": \"2026-01-01\", \"to\": \"2026-01-31\" }`).',\n }),\n q: z.string().optional(),\n }),\n except: z.array(Id).optional(),\n }),\n]);\n\nexport const ActionRequest = z.looseObject({\n selection: Selection.optional().meta({\n description: 'Omitted for actions on the whole resource.',\n }),\n values: z.record(z.string(), z.unknown()).optional(),\n dryRun: z.boolean().optional().meta({\n description:\n 'Answer what the action would do without running it: a `200` action result whose `summary` counts the items that would succeed and those that would be skipped. Only for actions with `dryRun: true`.',\n }),\n});\n\nexport const ActionItemResult = z.looseObject({\n id: Id,\n status: z.enum(['failed', 'skipped']),\n message: z.string().optional(),\n reason: z\n .string()\n .optional()\n .meta({ description: '`skipped`: `forbidden`, `not_found` or `unchanged`.' }),\n});\n\nexport const ActionResult = z.looseObject({\n message: z.string().optional(),\n summary: z\n .looseObject({\n succeeded: z.number().int().nonnegative(),\n failed: z.number().int().nonnegative(),\n skipped: z.number().int().nonnegative(),\n })\n .optional(),\n results: z\n .array(ActionItemResult)\n .optional()\n .meta({ description: 'The items that did not succeed.' }),\n refresh: z.enum(['none', 'items', 'list']).optional(),\n redirect: z.union([z.string(), RouteReference]).nullable().optional(),\n download: z\n .looseObject({\n url: z.string(),\n filename: z.string().optional(),\n expiresAt: z.string().optional(),\n })\n .nullable()\n .optional(),\n});\n\nexport const ActionRun = z.looseObject({\n id: Id,\n action: z.string(),\n resource: z.string(),\n status: z.enum(['queued', 'running', 'succeeded', 'partial', 'failed', 'cancelled']),\n progress: z.number().int().nonnegative(),\n total: z.number().int().nonnegative().nullable(),\n result: ActionResult.optional().meta({ description: 'Set once the run has finished.' }),\n createdAt: z.string().optional(),\n finishedAt: z.string().nullable().optional(),\n});\n\nexport const ActionRunResponse = z.looseObject({ run: ActionRun });\n\nexport const MediaTransform = z\n .looseObject({\n crop: z\n .looseObject({\n x: z.number().int().nonnegative(),\n y: z.number().int().nonnegative(),\n width: z.number().int().positive(),\n height: z.number().int().positive(),\n })\n .optional()\n .meta({\n description:\n 'In whole pixels of the upright original image (after its EXIF orientation), from its top left corner.',\n }),\n rotate: z\n .union([z.literal(0), z.literal(90), z.literal(180), z.literal(270)])\n .optional()\n .meta({ description: 'Clockwise, in degrees.' }),\n flipX: z.boolean().optional().meta({ description: 'Mirrors left to right (horizontal).' }),\n flipY: z.boolean().optional().meta({ description: 'Mirrors top to bottom (vertical).' }),\n focalPoint: z\n .looseObject({ x: z.number().min(0).max(1), y: z.number().min(0).max(1) })\n .optional()\n .meta({\n description:\n 'From 0 to 1, relative to the width and height of the upright original image, not of the crop: changing the crop does not move it. Renderers map it into the transformed image and clamp it to the crop.',\n }),\n base: z.enum(['media', 'original']).optional().meta({\n description:\n \"What a transform for one use starts from: the original file by default, or the media's own transform (`media`). With `media`, the crop and the focal point are relative to the media's version instead of the original (decision 0031).\",\n }),\n // Return types are written out so that declaration files keep the recursion.\n get baseTransform(): z.ZodOptional<typeof MediaTransform> {\n return MediaTransform.optional().meta({\n description:\n 'With `base: \"media\"`: the media\\'s own transform this one was made on. When the media\\'s transform is no longer the same, clients ask to check the crop, and renderers clamp it.',\n });\n },\n })\n .meta({\n description:\n \"Non-destructive edits of an image, applied in this order: crop, then rotate, then flip. Renderers ignore the keys they don't know, which editor tools can add.\",\n });\n\nexport const UploadReference = z.looseObject({ upload: z.string().min(1) }).meta({\n description:\n 'A file uploaded directly to storage, by the id of its upload: in a file value, such as the `file` of a media, or an action parameter.',\n});\n\nexport const StoredFile = z\n .looseObject({\n name: z.string().meta({ description: 'The name of the file, as the user knows it.' }),\n url: z.string().nullable().optional().meta({\n description: 'Where to download it. A private file gets a temporary URL.',\n }),\n mime: z.string().nullable().optional(),\n size: z.number().int().nonnegative().nullable().optional(),\n })\n .meta({\n description:\n 'A file stored by the backend: the value of a `file` field in items. Requests send it back to keep the file, `{ \"upload\" }` to replace it, or `null` to remove it.',\n });\n\nexport const Upload = z\n .looseObject({\n id: z.string().min(1).meta({ description: 'The id of the upload: `upl_…`.' }),\n key: z.string().optional().meta({ description: 'The key of the object in storage.' }),\n name: z.string().optional(),\n mime: z.string().optional(),\n size: z.number().int().nonnegative().optional(),\n })\n .meta({\n description:\n 'A file the browser uploaded to storage, before it becomes a media, an import or another value.',\n });\n\nexport const UploadResponse = z.looseObject({ data: Upload });\n\nexport const UploadSignRequest = z\n .looseObject({\n method: z.enum(['GET', 'POST', 'PUT', 'DELETE']),\n key: z.string().min(1),\n uploadId: z.string().optional().meta({ description: 'The S3 multipart upload.' }),\n partNumber: z.number().int().positive().optional(),\n contentType: z.string().optional(),\n expiresIn: z.number().int().positive().optional(),\n })\n .meta({\n description: \"A request of the browser's S3 client to sign (Uppy 6's `signRequest`).\",\n });\n\nexport const UploadSignResponse = z\n .looseObject({\n url: z.string(),\n key: z\n .string()\n .optional()\n .meta({ description: 'The key the backend chose, for the first request of a file.' }),\n headers: z.record(z.string(), z.string()).optional().meta({\n description: 'Headers the URL was signed with, which the browser sends.',\n }),\n upload: z\n .string()\n .optional()\n .meta({ description: 'The upload the first request of a file created: `upl_…`.' }),\n })\n .meta({ description: 'A presigned request.' });\n\nexport const MediaInfo = z\n .looseObject({\n type: z.string().meta({\n description:\n '`image`, `video`, `audio`, `document`, `font`, or another type the backend knows.',\n }),\n mime: z.string().nullable().optional(),\n size: z.number().int().nonnegative().nullable().optional(),\n url: z.string().nullable().optional().meta({\n description:\n 'The main file to show or play: a rendition, or the original until it exists.',\n }),\n thumbnailUrl: z.string().nullable().optional(),\n variants: z\n .record(\n z.string(),\n z.looseObject({\n url: z.string(),\n width: z.number().optional(),\n height: z.number().optional(),\n }),\n )\n .optional()\n .meta({ description: 'Named renditions: sizes of an image, qualities of a video.' }),\n width: z.number().nullable().optional(),\n height: z.number().nullable().optional(),\n duration: z.number().nullable().optional().meta({ description: 'In seconds.' }),\n status: z.enum(['pending', 'processing', 'ready', 'failed']).optional().meta({\n description:\n 'Where the processing of the file is: `pending` and `processing` until its renditions are made, then `ready` or `failed`. Without it, the media is ready.',\n }),\n metadata: z.record(z.string(), z.unknown()).optional(),\n transform: MediaTransform.nullable().optional().meta({\n description:\n \"The media's own transform, from its library, which clients need to draw a transform for one use made over it (decision 0031).\",\n }),\n })\n .meta({\n description:\n 'What the backend computed about the file of a media item: the `media` of the items of a `media` resource, and of the values of `media` fields. Read-only: the editable properties of a media are the fields of its resource.',\n });\n\nexport const MediaItem = Item.extend({\n media: MediaInfo,\n}).meta({\n description:\n 'An item of a resource of kind `media`: the values of its fields (`file`, the original, and those of the project), and the `media` the backend computed.',\n});\n\nexport const MediaReference = z\n .looseObject({\n id: Id,\n resource: z.string().optional().meta({\n description:\n 'The library of the media. Required for a field that allows several libraries, since ids are unique only within their resource (decision 0027).',\n }),\n label: z.string().optional().meta({ description: 'The `itemTitle` of the media.' }),\n media: MediaInfo.optional(),\n transform: MediaTransform.nullable().optional().meta({\n description:\n 'The edits of the image for this use only: from the original file, or over the media\\'s own transform with `base: \"media\"`.',\n }),\n })\n .meta({\n description:\n 'The value of a `media` or `image` field in items: the media, with what lists and fields show, and its edits for this use. Requests send the id, or `{ id, resource, transform }`: `resource` is required when the field allows several libraries.',\n });\n\nexport const FieldCheckRequest = z\n .looseObject({\n value: z.string().meta({ description: 'The value to check, as it is typed.' }),\n locale: z\n .string()\n .optional()\n .meta({ description: 'The locale of the value, for a localized field.' }),\n id: Id.nullable()\n .optional()\n .meta({ description: 'The item being edited, or null when creating one.' }),\n values: z.record(z.string(), z.unknown()).optional().meta({\n description:\n \"The form's current values, as they would be sent to save, for what the check depends on (a page's parent).\",\n }),\n })\n .meta({ description: 'A value of a field with `check`, to check with the backend.' });\n\nexport const FieldCheckResponse = z\n .looseObject({\n available: z.boolean().meta({\n description:\n 'Whether no other item of the resource, in its scope and the same locale, has the value.',\n }),\n suggestion: z.string().nullable().optional().meta({\n description: 'An available value close to the one checked, when it is taken.',\n }),\n prefix: z.string().nullable().optional().meta({\n description: 'What the field shows in front of the value: the start of its URL.',\n }),\n url: z\n .string()\n .nullable()\n .optional()\n .meta({ description: 'The URL the value gives the item, which the field links to.' }),\n disabled: z.boolean().optional().meta({\n description:\n \"The field doesn't apply to this item (the home page has no slug): the field is read-only.\",\n }),\n })\n .meta({\n description:\n 'What the backend says about a value: not authoritative, since saving still validates it.',\n });\n\nexport const Session = z.looseObject({ user: User });\n\nexport const SearchResponse = z\n .looseObject({\n data: z.array(\n z.looseObject({\n resource: z.string().meta({ description: 'The id of the resource.' }),\n items: z.array(Item),\n total: z.number().int().nonnegative().optional().meta({\n description:\n 'How many items of the resource match, when the backend counts them: the list of the resource, searched, shows them all.',\n }),\n }),\n ),\n })\n .meta({\n description:\n 'The results of the global search: the resources with results, in the order of the definition.',\n });\n\nexport const PreviewResponse = z.looseObject({ url: z.string(), expiresAt: z.string().optional() });\n\nexport type Item = z.infer<typeof Item>;\nexport type Pagination = z.infer<typeof Pagination>;\nexport type ItemResponse = z.infer<typeof ItemResponse>;\nexport type ListResponse = z.infer<typeof ListResponse>;\nexport type Problem = z.infer<typeof Problem>;\nexport type Selection = z.infer<typeof Selection>;\nexport type ActionRequest = z.infer<typeof ActionRequest>;\nexport type ActionItemResult = z.infer<typeof ActionItemResult>;\nexport type ActionResult = z.infer<typeof ActionResult>;\nexport type ActionRun = z.infer<typeof ActionRun>;\nexport type ActionRunResponse = z.infer<typeof ActionRunResponse>;\nexport type MediaTransform = z.infer<typeof MediaTransform>;\nexport type UploadReference = z.infer<typeof UploadReference>;\nexport type StoredFile = z.infer<typeof StoredFile>;\nexport type Upload = z.infer<typeof Upload>;\nexport type UploadResponse = z.infer<typeof UploadResponse>;\nexport type UploadSignRequest = z.infer<typeof UploadSignRequest>;\nexport type UploadSignResponse = z.infer<typeof UploadSignResponse>;\nexport type FieldCheckRequest = z.infer<typeof FieldCheckRequest>;\nexport type FieldCheckResponse = z.infer<typeof FieldCheckResponse>;\nexport type MediaInfo = z.infer<typeof MediaInfo>;\nexport type MediaItem = z.infer<typeof MediaItem>;\nexport type MediaReference = z.infer<typeof MediaReference>;\nexport type Session = z.infer<typeof Session>;\nexport type SearchResponse = z.infer<typeof SearchResponse>;\nexport type PreviewResponse = z.infer<typeof PreviewResponse>;\n"],"mappings":";;;;AAKA,IAAa,OAAO,EACf,YAAY;CACT,IAAI;CACJ,SAAS,EAAE,OAAO,CAAC,CAAC,SAAS,CAAC,CAAC,KAAK,EAChC,aAAa,oEACjB,CAAC;CACD,WAAW;AACf,CAAC,CAAC,CACD,KAAK,EACF,aAAa,4EACjB,CAAC;AAEL,IAAa,aAAa,EAAE,YAAY;CACpC,MAAM,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS;CAChC,SAAS,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS;CACnC,OAAO,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,YAAY;CACpC,UAAU,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS;AACxC,CAAC;AAED,IAAa,eAAe,EAAE,YAAY,EAAE,MAAM,KAAK,CAAC;AAExD,IAAa,eAAe,EAAE,YAAY;CAAE,MAAM,EAAE,MAAM,IAAI;CAAG,MAAM;AAAW,CAAC;AAEnF,IAAa,UAAU,EAClB,YAAY;CACT,MAAM,EAAE,OAAO,CAAC,CAAC,KAAK,EAAE,aAAa,oDAAoD,CAAC;CAC1F,OAAO,EAAE,OAAO;CAChB,QAAQ,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,IAAI,GAAG,CAAC,CAAC,IAAI,GAAG;CACzC,QAAQ,EAAE,OAAO,CAAC,CAAC,SAAS;CAC5B,UAAU,EAAE,OAAO,CAAC,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ACL,EACJ,CAAC,CAAC,CACD,KAAK,EACF,aACI,gGACR,CAAC;AAEL,IAAa,kBAAkB,EAAE,YAAY;CAAE,KAAK,EAAE,OAAO;CAAG,WAAW,EAAE,OAAO,CAAC,CAAC,SAAS;AAAE,CAAC"}
|
|
@@ -5,6 +5,7 @@ export declare const User: z.ZodObject<{
|
|
|
5
5
|
email: z.ZodOptional<z.ZodString>;
|
|
6
6
|
avatarUrl: z.ZodOptional<z.ZodString>;
|
|
7
7
|
abilities: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
|
|
8
|
+
resource: z.ZodOptional<z.ZodString>;
|
|
8
9
|
}, z.core.$loose>;
|
|
9
10
|
export declare const AuthProvider: z.ZodObject<{
|
|
10
11
|
id: z.ZodString;
|
|
@@ -72,6 +73,7 @@ export declare const Definition: z.ZodObject<{
|
|
|
72
73
|
}, z.core.$loose>;
|
|
73
74
|
resources: z.ZodArray<z.ZodObject<{
|
|
74
75
|
id: z.ZodString;
|
|
76
|
+
kind: z.ZodOptional<z.ZodString>;
|
|
75
77
|
label: z.ZodObject<{
|
|
76
78
|
singular: z.ZodString;
|
|
77
79
|
plural: z.ZodString;
|
|
@@ -79,6 +81,8 @@ export declare const Definition: z.ZodObject<{
|
|
|
79
81
|
description: z.ZodOptional<z.ZodString>;
|
|
80
82
|
icon: z.ZodOptional<z.ZodString>;
|
|
81
83
|
itemTitle: z.ZodOptional<z.ZodString>;
|
|
84
|
+
itemSubtitle: z.ZodOptional<z.ZodString>;
|
|
85
|
+
itemImage: z.ZodOptional<z.ZodString>;
|
|
82
86
|
fields: z.ZodArray<z.ZodObject<{
|
|
83
87
|
name: z.ZodString;
|
|
84
88
|
type: z.ZodString;
|
|
@@ -132,6 +136,13 @@ export declare const Definition: z.ZodObject<{
|
|
|
132
136
|
field: z.ZodString;
|
|
133
137
|
}, z.core.$loose>]>;
|
|
134
138
|
message: z.ZodOptional<z.ZodString>;
|
|
139
|
+
}, z.core.$loose>, z.ZodObject<{
|
|
140
|
+
rule: z.ZodLiteral<"crop">;
|
|
141
|
+
value: z.ZodObject<{
|
|
142
|
+
ratios: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
143
|
+
required: z.ZodOptional<z.ZodBoolean>;
|
|
144
|
+
}, z.core.$loose>;
|
|
145
|
+
message: z.ZodOptional<z.ZodString>;
|
|
135
146
|
}, z.core.$loose>, z.ZodObject<{
|
|
136
147
|
rule: z.ZodString;
|
|
137
148
|
message: z.ZodOptional<z.ZodString>;
|
|
@@ -152,9 +163,18 @@ export declare const Definition: z.ZodObject<{
|
|
|
152
163
|
disabled: z.ZodOptional<z.ZodBoolean>;
|
|
153
164
|
}, z.core.$loose>>>;
|
|
154
165
|
multiple: z.ZodOptional<z.ZodBoolean>;
|
|
155
|
-
resource: z.ZodOptional<z.ZodString
|
|
166
|
+
resource: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodString>]>>;
|
|
156
167
|
accept: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
168
|
+
ratios: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
169
|
+
rotate: z.ZodOptional<z.ZodBoolean>;
|
|
170
|
+
focalPoint: z.ZodOptional<z.ZodBoolean>;
|
|
171
|
+
transformBase: z.ZodOptional<z.ZodEnum<{
|
|
172
|
+
media: "media";
|
|
173
|
+
original: "original";
|
|
174
|
+
choose: "choose";
|
|
175
|
+
}>>;
|
|
157
176
|
from: z.ZodOptional<z.ZodString>;
|
|
177
|
+
check: z.ZodOptional<z.ZodBoolean>;
|
|
158
178
|
display: z.ZodOptional<z.ZodString>;
|
|
159
179
|
fields: z.ZodOptional<z.ZodArray<typeof import("./field").Field>>;
|
|
160
180
|
types: z.ZodOptional<z.ZodArray<typeof import("./field").BlockType>>;
|
|
@@ -301,6 +321,13 @@ export declare const Definition: z.ZodObject<{
|
|
|
301
321
|
field: z.ZodString;
|
|
302
322
|
}, z.core.$loose>]>;
|
|
303
323
|
message: z.ZodOptional<z.ZodString>;
|
|
324
|
+
}, z.core.$loose>, z.ZodObject<{
|
|
325
|
+
rule: z.ZodLiteral<"crop">;
|
|
326
|
+
value: z.ZodObject<{
|
|
327
|
+
ratios: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
328
|
+
required: z.ZodOptional<z.ZodBoolean>;
|
|
329
|
+
}, z.core.$loose>;
|
|
330
|
+
message: z.ZodOptional<z.ZodString>;
|
|
304
331
|
}, z.core.$loose>, z.ZodObject<{
|
|
305
332
|
rule: z.ZodString;
|
|
306
333
|
message: z.ZodOptional<z.ZodString>;
|
|
@@ -321,9 +348,18 @@ export declare const Definition: z.ZodObject<{
|
|
|
321
348
|
disabled: z.ZodOptional<z.ZodBoolean>;
|
|
322
349
|
}, z.core.$loose>>>;
|
|
323
350
|
multiple: z.ZodOptional<z.ZodBoolean>;
|
|
324
|
-
resource: z.ZodOptional<z.ZodString
|
|
351
|
+
resource: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodString>]>>;
|
|
325
352
|
accept: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
353
|
+
ratios: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
354
|
+
rotate: z.ZodOptional<z.ZodBoolean>;
|
|
355
|
+
focalPoint: z.ZodOptional<z.ZodBoolean>;
|
|
356
|
+
transformBase: z.ZodOptional<z.ZodEnum<{
|
|
357
|
+
media: "media";
|
|
358
|
+
original: "original";
|
|
359
|
+
choose: "choose";
|
|
360
|
+
}>>;
|
|
326
361
|
from: z.ZodOptional<z.ZodString>;
|
|
362
|
+
check: z.ZodOptional<z.ZodBoolean>;
|
|
327
363
|
display: z.ZodOptional<z.ZodString>;
|
|
328
364
|
fields: z.ZodOptional<z.ZodArray<typeof import("./field").Field>>;
|
|
329
365
|
types: z.ZodOptional<z.ZodArray<typeof import("./field").BlockType>>;
|
|
@@ -501,6 +537,7 @@ export declare const Definition: z.ZodObject<{
|
|
|
501
537
|
email: z.ZodOptional<z.ZodString>;
|
|
502
538
|
avatarUrl: z.ZodOptional<z.ZodString>;
|
|
503
539
|
abilities: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
|
|
540
|
+
resource: z.ZodOptional<z.ZodString>;
|
|
504
541
|
}, z.core.$loose>>>;
|
|
505
542
|
}, z.core.$loose>;
|
|
506
543
|
export type User = z.infer<typeof User>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"definition.d.ts","sourceRoot":"","sources":["../../src/schemas/definition.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAOxB,eAAO,MAAM,IAAI
|
|
1
|
+
{"version":3,"file":"definition.d.ts","sourceRoot":"","sources":["../../src/schemas/definition.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAOxB,eAAO,MAAM,IAAI;;;;;;;iBAUf,CAAC;AAEH,eAAO,MAAM,YAAY;;;;;iBAKvB,CAAC;AAEH,eAAO,MAAM,IAAI;;;;;;;;;;;;;;;;;iBAef,CAAC;AAEH,eAAO,MAAM,QAAQ;;;;;;;;cAYG,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,QAAQ,CAAC,OAAO,QAAQ,CAAC,CAAC;iBAIjB,CAAC;AAElD,eAAO,MAAM,IAAI;;;;;iBAQf,CAAC;AAEH,eAAO,MAAM,MAAM;;;;;;iBAQjB,CAAC;AAEH,eAAO,MAAM,OAAO;;;;;;;;iBAUlB,CAAC;AAEH,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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