@panneau/protocol 5.0.0-alpha.14 → 5.0.0-alpha.15

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.
@@ -470,6 +470,35 @@ export declare const Session: z.ZodObject<{
470
470
  resource: z.ZodOptional<z.ZodString>;
471
471
  }, z.core.$loose>;
472
472
  }, z.core.$loose>;
473
+ export declare const TwoFactorChallenge: z.ZodObject<{
474
+ twoFactor: z.ZodLiteral<true>;
475
+ }, z.core.$loose>;
476
+ export declare const TwoFactorStatus: z.ZodObject<{
477
+ status: z.ZodEnum<{
478
+ disabled: "disabled";
479
+ enabled: "enabled";
480
+ pending: "pending";
481
+ }>;
482
+ required: z.ZodBoolean;
483
+ }, z.core.$loose>;
484
+ export declare const TwoFactorSetup: z.ZodObject<{
485
+ secret: z.ZodString;
486
+ otpauthUrl: z.ZodString;
487
+ qrCode: z.ZodOptional<z.ZodString>;
488
+ }, z.core.$loose>;
489
+ export declare const WebAuthnOptions: z.ZodObject<{
490
+ options: z.ZodRecord<z.ZodString, z.ZodUnknown>;
491
+ }, z.core.$loose>;
492
+ export declare const Passkey: z.ZodObject<{
493
+ id: z.ZodString;
494
+ name: z.ZodString;
495
+ authenticator: z.ZodOptional<z.ZodNullable<z.ZodString>>;
496
+ createdAt: z.ZodString;
497
+ lastUsedAt: z.ZodNullable<z.ZodString>;
498
+ }, z.core.$loose>;
499
+ export declare const RecoveryCodes: z.ZodObject<{
500
+ recoveryCodes: z.ZodArray<z.ZodString>;
501
+ }, z.core.$loose>;
473
502
  export declare const ContextOptionsResponse: z.ZodObject<{
474
503
  data: z.ZodArray<z.ZodObject<{
475
504
  value: z.ZodString;
@@ -557,6 +586,12 @@ export type MediaInfo = z.infer<typeof MediaInfo>;
557
586
  export type MediaItem = z.infer<typeof MediaItem>;
558
587
  export type MediaReference = z.infer<typeof MediaReference>;
559
588
  export type Session = z.infer<typeof Session>;
589
+ export type TwoFactorChallenge = z.infer<typeof TwoFactorChallenge>;
590
+ export type TwoFactorStatus = z.infer<typeof TwoFactorStatus>;
591
+ export type TwoFactorSetup = z.infer<typeof TwoFactorSetup>;
592
+ export type RecoveryCodes = z.infer<typeof RecoveryCodes>;
593
+ export type WebAuthnOptions = z.infer<typeof WebAuthnOptions>;
594
+ export type Passkey = z.infer<typeof Passkey>;
560
595
  export type SearchResponse = z.infer<typeof SearchResponse>;
561
596
  export type PreviewResponse = z.infer<typeof PreviewResponse>;
562
597
  export type EmbedValue = z.infer<typeof EmbedValue>;
@@ -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,gBAAgB;;;;;iBAiBvB,CAAC;AAEP,eAAO,MAAM,YAAY;;;;;;iBAAgC,CAAC;AAE1D,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;iBAGvB,CAAC;AAEH,eAAO,MAAM,OAAO;;;;;;;;;;;;;iBAiB6E,CAAC;AAElG,eAAO,MAAM,SAAS;;;;;;;;mBAYpB,CAAC;AAEH,eAAO,MAAM,aAAa;;;;;;;;;;;;iBASxB,CAAC;AAEH,eAAO,MAAM,gBAAgB;;;;;;;;iBAQ3B,CAAC;AAEH,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAuBvB,CAAC;AAEH,eAAO,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAUpB,CAAC;AAEH,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAAoC,CAAC;AAEnE,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;mBAgCE,CAAC,CAAC,WAAW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Ae,CAAC,CAAC;AAC9D,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;AAC9D,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,UAAU,CAAC,CAAC;AACpD,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAC;AAC1D,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAC"}
@@ -198,6 +198,29 @@ var FieldCheckResponse = z.looseObject({
198
198
  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." })
199
199
  }).meta({ description: "What the backend says about a value: not authoritative, since saving still validates it." });
200
200
  var Session = z.looseObject({ user: User });
201
+ var TwoFactorChallenge = z.looseObject({ twoFactor: z.literal(true) }).meta({ description: "The answer of `POST /auth/login` when a second factor is needed: the login waits for `POST /auth/two-factor/challenge`." });
202
+ var TwoFactorStatus = z.looseObject({
203
+ status: z.enum([
204
+ "disabled",
205
+ "pending",
206
+ "enabled"
207
+ ]).meta({ description: "`pending`: set up, not confirmed with a code yet." }),
208
+ required: z.boolean().meta({ description: "The backend requires it for this user: it can't be turned off." })
209
+ }).meta({ description: "The two-factor authentication of the current user." });
210
+ var TwoFactorSetup = z.looseObject({
211
+ secret: z.string().meta({ description: "The secret, to type in an authenticator app." }),
212
+ otpauthUrl: z.string().meta({ description: "The `otpauth://totp/…` URL of the secret." }),
213
+ qrCode: z.string().optional().meta({ description: "An SVG document of the QR code of `otpauthUrl`. Clients show it as an image, never as markup." })
214
+ }).meta({ description: "A two-factor authentication to confirm with a code." });
215
+ var WebAuthnOptions = z.looseObject({ options: z.record(z.string(), z.unknown()).meta({ description: "The options of `navigator.credentials.get()` or `create()`, in the JSON form of the WebAuthn spec." }) }).meta({ description: "The options of a WebAuthn ceremony." });
216
+ var Passkey = z.looseObject({
217
+ id: Id,
218
+ name: z.string(),
219
+ authenticator: z.string().nullable().optional().meta({ description: "What keeps it, when the backend knows: \"iCloud Keychain\", \"1Password\"…" }),
220
+ createdAt: z.string().meta({ description: "ISO 8601." }),
221
+ lastUsedAt: z.string().nullable().meta({ description: "ISO 8601, or null before its first login." })
222
+ }).meta({ description: "A passkey of the current user." });
223
+ var RecoveryCodes = z.looseObject({ recoveryCodes: z.array(z.string()) }).meta({ description: "Codes that each log in once in place of a code of the authenticator app." });
201
224
  var ContextOptionsResponse = z.looseObject({ data: z.array(ContextOption) }).meta({ description: "The first choices of a param of the context that match `q`." });
202
225
  var SearchResponse = z.looseObject({ data: z.array(z.looseObject({
203
226
  resource: z.string().meta({ description: "The id of the resource." }),
@@ -231,6 +254,6 @@ var LocationValue = z.looseObject({
231
254
  address: z.string().optional()
232
255
  }).meta({ description: "The value of a `location` field: a point, and its address." });
233
256
  //#endregion
234
- export { ActionItemResult, ActionRequest, ActionResult, ActionRun, ActionRunResponse, ContextOptionsResponse, CursorPagination, EmbedResponse, EmbedValue, FieldCheckRequest, FieldCheckResponse, Item, ItemResponse, ListResponse, LocationValue, MediaInfo, MediaItem, MediaReference, MediaTransform, Pagination, PreviewResponse, Problem, SearchResponse, Selection, Session, StoredFile, Upload, UploadReference, UploadResponse, UploadSignRequest, UploadSignResponse };
257
+ export { ActionItemResult, ActionRequest, ActionResult, ActionRun, ActionRunResponse, ContextOptionsResponse, CursorPagination, EmbedResponse, EmbedValue, FieldCheckRequest, FieldCheckResponse, Item, ItemResponse, ListResponse, LocationValue, MediaInfo, MediaItem, MediaReference, MediaTransform, Pagination, Passkey, PreviewResponse, Problem, RecoveryCodes, SearchResponse, Selection, Session, StoredFile, TwoFactorChallenge, TwoFactorSetup, TwoFactorStatus, Upload, UploadReference, UploadResponse, UploadSignRequest, UploadSignResponse, WebAuthnOptions };
235
258
 
236
259
  //# sourceMappingURL=api.js.map
@@ -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 { ContextOption, 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 CursorPagination = z\n .looseObject({\n perPage: z.number().int().positive(),\n nextCursor: z.string().min(1).nullable().meta({\n description: 'The `cursor` of the next page, or `null` on the last page.',\n }),\n previousCursor: z.string().min(1).nullable().optional().meta({\n description:\n 'The `cursor` of the previous page, or `null` when it is the first page, which has none (and on the first page). Without it, clients go back through the cursors they followed.',\n }),\n total: z.number().int().nonnegative().nullable().optional().meta({\n description: 'How many items match, when the backend counts them.',\n }),\n })\n .meta({\n description:\n 'The meta of a page of a list whose `pagination` is `cursor`: no page numbers, and no total unless the backend has one.',\n });\n\nexport const ItemResponse = z.looseObject({ data: Item });\n\nexport const ListResponse = z.looseObject({\n data: z.array(Item),\n meta: z.union([Pagination, CursorPagination]),\n});\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 param: z.string().optional().meta({\n description:\n \"`403` of type `urn:panneau:problem:context`: the param of the context whose value the user can't use.\",\n }),\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 error: z\n .looseObject({\n code: z.string().meta({\n description:\n 'The code of the step that failed, such as a transcoder task code (`timeout`, `input_unreadable`).',\n }),\n message: z.string().optional().meta({ description: 'Why it failed, for people.' }),\n })\n .nullable()\n .optional()\n .meta({\n description:\n \"Why the processing failed, when `status` is `failed`, so that editors see it without the backend's monitoring.\",\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 ContextOptionsResponse = z\n .looseObject({ data: z.array(ContextOption) })\n .meta({ description: 'The first choices of a param of the context that match `q`.' });\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 const EmbedValue = z\n .looseObject({\n url: z.string().meta({ description: 'The URL of the video, sound or post.' }),\n type: z.enum(['video', 'audio', 'photo', 'rich', 'link']).optional(),\n title: z.string().optional(),\n provider: z.string().optional().meta({ description: 'The name of the provider.' }),\n thumbnailUrl: z.string().optional(),\n html: z\n .string()\n .optional()\n .meta({ description: 'The HTML that embeds it, from the oEmbed of its provider.' }),\n width: z.number().optional(),\n height: z.number().optional(),\n })\n .meta({\n description:\n 'The value of an `embed` field: its URL, and what the backend got from its oEmbed.',\n });\n\nexport const EmbedResponse = z.looseObject({ data: EmbedValue });\n\nexport const LocationValue = z\n .looseObject({\n lat: z.number().min(-90).max(90),\n lng: z.number().min(-180).max(180),\n address: z.string().optional(),\n })\n .meta({ description: 'The value of a `location` field: a point, and its address.' });\n\nexport type Item = z.infer<typeof Item>;\nexport type Pagination = z.infer<typeof Pagination>;\nexport type ItemResponse = z.infer<typeof ItemResponse>;\nexport type CursorPagination = z.infer<typeof CursorPagination>;\nexport type ListResponse = z.infer<typeof ListResponse>;\nexport type ContextOptionsResponse = z.infer<typeof ContextOptionsResponse>;\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>;\nexport type EmbedValue = z.infer<typeof EmbedValue>;\nexport type EmbedResponse = z.infer<typeof EmbedResponse>;\nexport type LocationValue = z.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ClC,MAAM,EACD,OAAO,CAAC,CACR,SAAS,CAAC,CACV,KAAK,EAAE,aAAa,4DAA4D,CAAC;CACtF,OAAO,EAAE,OAAO,CAAC,CAAC,SAAS;CAC3B,QAAQ,EAAE,OAAO,CAAC,CAAC,SAAS;AAChC,CAAC,CAAC,CACD,KAAK,EACF,aACI,oFACR,CAAC;AAEL,IAAa,gBAAgB,EAAE,YAAY,EAAE,MAAM,WAAW,CAAC;AAE/D,IAAa,gBAAgB,EACxB,YAAY;CACT,KAAK,EAAE,OAAO,CAAC,CAAC,IAAI,GAAG,CAAC,CAAC,IAAI,EAAE;CAC/B,KAAK,EAAE,OAAO,CAAC,CAAC,IAAI,IAAI,CAAC,CAAC,IAAI,GAAG;CACjC,SAAS,EAAE,OAAO,CAAC,CAAC,SAAS;AACjC,CAAC,CAAC,CACD,KAAK,EAAE,aAAa,6DAA6D,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 { ContextOption, 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 CursorPagination = z\n .looseObject({\n perPage: z.number().int().positive(),\n nextCursor: z.string().min(1).nullable().meta({\n description: 'The `cursor` of the next page, or `null` on the last page.',\n }),\n previousCursor: z.string().min(1).nullable().optional().meta({\n description:\n 'The `cursor` of the previous page, or `null` when it is the first page, which has none (and on the first page). Without it, clients go back through the cursors they followed.',\n }),\n total: z.number().int().nonnegative().nullable().optional().meta({\n description: 'How many items match, when the backend counts them.',\n }),\n })\n .meta({\n description:\n 'The meta of a page of a list whose `pagination` is `cursor`: no page numbers, and no total unless the backend has one.',\n });\n\nexport const ItemResponse = z.looseObject({ data: Item });\n\nexport const ListResponse = z.looseObject({\n data: z.array(Item),\n meta: z.union([Pagination, CursorPagination]),\n});\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 param: z.string().optional().meta({\n description:\n \"`403` of type `urn:panneau:problem:context`: the param of the context whose value the user can't use.\",\n }),\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 error: z\n .looseObject({\n code: z.string().meta({\n description:\n 'The code of the step that failed, such as a transcoder task code (`timeout`, `input_unreadable`).',\n }),\n message: z.string().optional().meta({ description: 'Why it failed, for people.' }),\n })\n .nullable()\n .optional()\n .meta({\n description:\n \"Why the processing failed, when `status` is `failed`, so that editors see it without the backend's monitoring.\",\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 TwoFactorChallenge = z.looseObject({ twoFactor: z.literal(true) }).meta({\n description:\n 'The answer of `POST /auth/login` when a second factor is needed: the login waits for `POST /auth/two-factor/challenge`.',\n});\n\nexport const TwoFactorStatus = z\n .looseObject({\n status: z.enum(['disabled', 'pending', 'enabled']).meta({\n description: '`pending`: set up, not confirmed with a code yet.',\n }),\n required: z.boolean().meta({\n description: \"The backend requires it for this user: it can't be turned off.\",\n }),\n })\n .meta({ description: 'The two-factor authentication of the current user.' });\n\nexport const TwoFactorSetup = z\n .looseObject({\n secret: z.string().meta({ description: 'The secret, to type in an authenticator app.' }),\n otpauthUrl: z.string().meta({ description: 'The `otpauth://totp/…` URL of the secret.' }),\n qrCode: z.string().optional().meta({\n description:\n 'An SVG document of the QR code of `otpauthUrl`. Clients show it as an image, never as markup.',\n }),\n })\n .meta({ description: 'A two-factor authentication to confirm with a code.' });\n\nexport const WebAuthnOptions = z\n .looseObject({\n options: z.record(z.string(), z.unknown()).meta({\n description:\n 'The options of `navigator.credentials.get()` or `create()`, in the JSON form of the WebAuthn spec.',\n }),\n })\n .meta({ description: 'The options of a WebAuthn ceremony.' });\n\nexport const Passkey = z\n .looseObject({\n id: Id,\n name: z.string(),\n authenticator: z.string().nullable().optional().meta({\n description: 'What keeps it, when the backend knows: \"iCloud Keychain\", \"1Password\"…',\n }),\n createdAt: z.string().meta({ description: 'ISO 8601.' }),\n lastUsedAt: z\n .string()\n .nullable()\n .meta({ description: 'ISO 8601, or null before its first login.' }),\n })\n .meta({ description: 'A passkey of the current user.' });\n\nexport const RecoveryCodes = z.looseObject({ recoveryCodes: z.array(z.string()) }).meta({\n description: 'Codes that each log in once in place of a code of the authenticator app.',\n});\n\nexport const ContextOptionsResponse = z\n .looseObject({ data: z.array(ContextOption) })\n .meta({ description: 'The first choices of a param of the context that match `q`.' });\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 const EmbedValue = z\n .looseObject({\n url: z.string().meta({ description: 'The URL of the video, sound or post.' }),\n type: z.enum(['video', 'audio', 'photo', 'rich', 'link']).optional(),\n title: z.string().optional(),\n provider: z.string().optional().meta({ description: 'The name of the provider.' }),\n thumbnailUrl: z.string().optional(),\n html: z\n .string()\n .optional()\n .meta({ description: 'The HTML that embeds it, from the oEmbed of its provider.' }),\n width: z.number().optional(),\n height: z.number().optional(),\n })\n .meta({\n description:\n 'The value of an `embed` field: its URL, and what the backend got from its oEmbed.',\n });\n\nexport const EmbedResponse = z.looseObject({ data: EmbedValue });\n\nexport const LocationValue = z\n .looseObject({\n lat: z.number().min(-90).max(90),\n lng: z.number().min(-180).max(180),\n address: z.string().optional(),\n })\n .meta({ description: 'The value of a `location` field: a point, and its address.' });\n\nexport type Item = z.infer<typeof Item>;\nexport type Pagination = z.infer<typeof Pagination>;\nexport type ItemResponse = z.infer<typeof ItemResponse>;\nexport type CursorPagination = z.infer<typeof CursorPagination>;\nexport type ListResponse = z.infer<typeof ListResponse>;\nexport type ContextOptionsResponse = z.infer<typeof ContextOptionsResponse>;\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 TwoFactorChallenge = z.infer<typeof TwoFactorChallenge>;\nexport type TwoFactorStatus = z.infer<typeof TwoFactorStatus>;\nexport type TwoFactorSetup = z.infer<typeof TwoFactorSetup>;\nexport type RecoveryCodes = z.infer<typeof RecoveryCodes>;\nexport type WebAuthnOptions = z.infer<typeof WebAuthnOptions>;\nexport type Passkey = z.infer<typeof Passkey>;\nexport type SearchResponse = z.infer<typeof SearchResponse>;\nexport type PreviewResponse = z.infer<typeof PreviewResponse>;\nexport type EmbedValue = z.infer<typeof EmbedValue>;\nexport type EmbedResponse = z.infer<typeof EmbedResponse>;\nexport type LocationValue = z.infer<typeof LocationValue>;\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,mBAAmB,EAC3B,YAAY;CACT,SAAS,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS;CACnC,YAAY,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,KAAK,EAC1C,aAAa,6DACjB,CAAC;CACD,gBAAgB,EAAE,OAAO,CAAC,CAAC,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  url: z.ZodOptional<z.ZodString>;
25
25
  icon: z.ZodOptional<z.ZodString>;
26
26
  }, z.core.$loose>>>;
27
+ account: z.ZodOptional<z.ZodBoolean>;
27
28
  passwordReset: z.ZodOptional<z.ZodBoolean>;
28
29
  twoFactor: z.ZodOptional<z.ZodBoolean>;
29
30
  passkeys: z.ZodOptional<z.ZodBoolean>;
@@ -1 +1 @@
1
- {"version":3,"file":"boot.d.ts","sourceRoot":"","sources":["../../src/schemas/boot.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,OAAO,EAAQ,UAAU,EAAE,MAAM,cAAc,CAAC;AAEhD,eAAO,MAAM,UAAU;;;;;gBAsBT,CAAC,CAAC,WAAW,CAAC,OAAO,UAAU,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;iBAaxC,CAAC;AAEP,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,UAAU,CAAC,CAAC;AACpD,yEAAyE;AACzE,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,UAAU,CAAC,CAAC"}
1
+ {"version":3,"file":"boot.d.ts","sourceRoot":"","sources":["../../src/schemas/boot.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,OAAO,EAAQ,UAAU,EAAE,MAAM,cAAc,CAAC;AAEhD,eAAO,MAAM,UAAU;;;;;gBAsBT,CAAC,CAAC,WAAW,CAAC,OAAO,UAAU,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;iBAaxC,CAAC;AAEP,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,UAAU,CAAC,CAAC;AACpD,yEAAyE;AACzE,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,UAAU,CAAC,CAAC"}
@@ -35,6 +35,7 @@ export declare const Auth: z.ZodObject<{
35
35
  url: z.ZodOptional<z.ZodString>;
36
36
  icon: z.ZodOptional<z.ZodString>;
37
37
  }, z.core.$loose>>>;
38
+ account: z.ZodOptional<z.ZodBoolean>;
38
39
  passwordReset: z.ZodOptional<z.ZodBoolean>;
39
40
  twoFactor: z.ZodOptional<z.ZodBoolean>;
40
41
  passkeys: z.ZodOptional<z.ZodBoolean>;
@@ -603,6 +604,7 @@ export declare const Definition: z.ZodObject<{
603
604
  url: z.ZodOptional<z.ZodString>;
604
605
  icon: z.ZodOptional<z.ZodString>;
605
606
  }, z.core.$loose>>>;
607
+ account: z.ZodOptional<z.ZodBoolean>;
606
608
  passwordReset: z.ZodOptional<z.ZodBoolean>;
607
609
  twoFactor: z.ZodOptional<z.ZodBoolean>;
608
610
  passkeys: z.ZodOptional<z.ZodBoolean>;
@@ -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;AAQxB,eAAO,MAAM,IAAI;;;;;;;iBAUf,CAAC;AAEH,eAAO,MAAM,YAAY;;;;;iBAKvB,CAAC;AAEH,eAAO,MAAM,SAAS;;;iBAGpB,CAAC;AAEH,eAAO,MAAM,IAAI;;;;;;;;;;;;;;;;;;;;;;iBA0Bf,CAAC;AAEH,eAAO,MAAM,QAAQ;;;;;;;;cAYG,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,QAAQ,CAAC,OAAO,QAAQ,CAAC,CAAC;iBAIjB,CAAC;AAElD,eAAO,MAAM,IAAI;;;;;;;iBAmBf,CAAC;AAEH,eAAO,MAAM,aAAa;;;;iBAMuC,CAAC;AAElE,eAAO,MAAM,YAAY;;;;;;;;;;;;;iBAqCoD,CAAC;AAE9E,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;iBAUxB,CAAC;AAEP,eAAO,MAAM,MAAM;;;;;;iBAQjB,CAAC;AAEH,eAAO,MAAM,OAAO;;;;;;;;iBAU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AAC,OAAO,SAAS,CAAC,CAAC;AAClD,MAAM,MAAM,IAAI,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,IAAI,CAAC,CAAC;AACxC,MAAM,MAAM,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,QAAQ,CAAC,CAAC;AAChD,MAAM,MAAM,IAAI,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,IAAI,CAAC,CAAC;AACxC,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAC;AAC1D,MAAM,MAAM,YAAY,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,YAAY,CAAC,CAAC;AACxD,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAClE,MAAM,MAAM,MAAM,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,MAAM,CAAC,CAAC;AAC5C,MAAM,MAAM,OAAO,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,OAAO,CAAC,CAAC;AAC9C,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,UAAU,CAAC,CAAC;AACpD,wEAAwE;AACxE,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,UAAU,CAAC,CAAC"}
@@ -16,7 +16,7 @@ var User = z.looseObject({
16
16
  var AuthProvider = z.looseObject({
17
17
  id: z.string().min(1),
18
18
  label: z.string(),
19
- url: z.string().optional().meta({ description: "Where the login with this provider starts." }),
19
+ url: z.string().optional().meta({ description: "Where the login with this provider starts, with a full navigation. The app adds `next`, the path to come back to." }),
20
20
  icon: z.string().optional()
21
21
  });
22
22
  var AuthToken = z.looseObject({
@@ -30,10 +30,11 @@ var Auth = z.looseObject({
30
30
  password: z.boolean().optional().meta({ description: "`panneau`: a login with an email and a password. Defaults to true without `token`." }),
31
31
  token: AuthToken.optional().meta({ description: "`panneau`: a login with a single secret, such as an access token, sent as `token` to `POST /auth/login`." }),
32
32
  providers: z.array(AuthProvider).optional(),
33
- passwordReset: z.boolean().optional(),
34
- twoFactor: z.boolean().optional(),
35
- passkeys: z.boolean().optional(),
36
- emailVerification: z.boolean().optional()
33
+ account: z.boolean().optional().meta({ description: "`panneau`: the account page of the user, on `/account`: their name and email, their password, their two-factor authentication." }),
34
+ passwordReset: z.boolean().optional().meta({ description: "`panneau`: a \"Forgot your password?\" link on the login page, through `POST /auth/password/forgot` and `POST /auth/password/reset`." }),
35
+ twoFactor: z.boolean().optional().meta({ description: "`panneau`: two-factor authentication, which users set up through `/account/two-factor`, and which a password login asks for with a `202`." }),
36
+ passkeys: z.boolean().optional().meta({ description: "`panneau`: logins with a passkey (WebAuthn), which users add on the account page." }),
37
+ emailVerification: z.boolean().optional().meta({ description: "`panneau`: the backend refuses users whose email address isn't verified with a `403` problem of type `urn:panneau:problem:email-unverified`, and verifies it through `POST /auth/email/verification` and `POST /auth/email/verify`." })
37
38
  });
38
39
  var MenuItem = z.looseObject({
39
40
  type: z.string().min(1).meta({ description: "Built-in: `resources`, `resource`, `page`, `link`, `separator`, `group`." }),
@@ -1 +1 @@
1
- {"version":3,"file":"definition.js","names":[],"sources":["../../src/schemas/definition.ts"],"sourcesContent":["import { z } from 'zod';\n\nimport { RESERVED_ROUTE_SEGMENTS } from '../constants';\nimport { PROTOCOL_VERSION } from '../version';\nimport { Abilities, Id } from './common';\nimport { Resource } from './resource';\nimport { DefinitionTheme } from './theme';\n\nexport const User = z.looseObject({\n id: Id,\n name: z.string(),\n email: z.string().optional(),\n avatarUrl: z.string().optional(),\n abilities: Abilities.optional(),\n resource: z.string().optional().meta({\n description:\n 'The resource of users: its item with this `id` is the profile of the user. Without it, clients look for a resource `users`.',\n }),\n});\n\nexport const AuthProvider = z.looseObject({\n id: z.string().min(1),\n label: z.string(),\n url: z.string().optional().meta({ description: 'Where the login with this provider starts.' }),\n icon: z.string().optional(),\n});\n\nexport const AuthToken = z.looseObject({\n label: z.string().optional().meta({ description: 'Label of the field. Defaults to \"Token\".' }),\n help: z.string().optional().meta({ description: 'Help under the field: where to find it.' }),\n});\n\nexport const Auth = z.looseObject({\n mode: z.enum(['panneau', 'external']).meta({\n description: \"`panneau`: Panneau's own login pages. `external`: the site handles login.\",\n }),\n loginUrl: z\n .string()\n .nullable()\n .optional()\n .meta({ description: '`external`: where unauthenticated users are sent.' }),\n logoutUrl: z.string().nullable().optional().meta({\n description:\n \"`external`: where the browser goes to log out, the site's own logout. Without it, the app offers no logout.\",\n }),\n password: z.boolean().optional().meta({\n description:\n '`panneau`: a login with an email and a password. Defaults to true without `token`.',\n }),\n token: AuthToken.optional().meta({\n description:\n '`panneau`: a login with a single secret, such as an access token, sent as `token` to `POST /auth/login`.',\n }),\n providers: z.array(AuthProvider).optional(),\n passwordReset: z.boolean().optional(),\n twoFactor: z.boolean().optional(),\n passkeys: z.boolean().optional(),\n emailVerification: z.boolean().optional(),\n});\n\nexport const MenuItem = z\n .looseObject({\n type: z.string().min(1).meta({\n description: 'Built-in: `resources`, `resource`, `page`, `link`, `separator`, `group`.',\n }),\n label: z.string().optional(),\n icon: z.string().optional(),\n resource: z.string().optional(),\n page: z.string().optional(),\n url: z.string().optional(),\n external: z.boolean().optional(),\n // The return type is written out so that declaration files keep the recursion.\n get children(): z.ZodOptional<z.ZodArray<typeof MenuItem>> {\n return z.array(MenuItem).optional();\n },\n })\n .meta({ description: 'An entry of a menu.' });\n\nexport const Page = z.looseObject({\n component: z\n .string()\n .min(1)\n .meta({ description: 'A page provided by a plugin, or a built-in page.' }),\n path: z.string().optional().meta({ description: 'Path of a custom page.' }),\n label: z.string().optional(),\n props: z.record(z.string(), z.unknown()).optional(),\n params: z\n .array(z.string().regex(/^[A-Za-z_][A-Za-z0-9_]*$/))\n .optional()\n .meta({\n description:\n 'Names of the path segments after the page: `[\"id\"]` makes `{basePath}/pages/{page}/{id}`. The component gets them as `params`, and route references (`{ \"route\": \"<page>\", \"params\": { \"id\": … } }`) can link to the page. A page with `params` is not in menus.',\n }),\n abilities: Abilities.optional().meta({\n description:\n 'What the current user can do with the page (decision 0046). `view: false` leaves it out of menus, and its route shows a forbidden state; `pages.home` falls back to the built-in home. Without it, the page is allowed.',\n }),\n});\n\nexport const ContextOption = z\n .looseObject({\n value: z.string().min(1),\n label: z.string(),\n description: z.string().optional(),\n })\n .meta({ description: 'A choice of a param of the context.' });\n\nexport const ContextParam = z\n .looseObject({\n name: z\n .string()\n .regex(\n new RegExp(`^(?!(?:${RESERVED_ROUTE_SEGMENTS.join('|')})$)[A-Za-z_][A-Za-z0-9_]*$`),\n )\n .meta({\n description:\n 'The name of the param, in the `Panneau-Context` header and in the client routes (`{basePath}/{name}/{value}/…`): an identifier, not a reserved first segment of the routes.',\n }),\n label: z.string(),\n required: z.boolean().optional().meta({\n description:\n 'Whether the app needs a value: without one, it shows a page to pick it in place of the page of the route.',\n }),\n fixed: z.boolean().optional().meta({\n description:\n 'The backend sets the value from the request, such as its domain: the app shows it without a picker, and leaves it out of the path and of the `Panneau-Context` header. Another value in the header is a `403` context problem. A fixed param has a `value`.',\n }),\n allLabel: z.string().optional().meta({\n description: 'An optional param: the label of no value, such as \"All clients\".',\n }),\n options: z.array(ContextOption).optional().meta({\n description:\n 'The choices, inline. Without them, the client searches them with `GET /context/{name}/options`.',\n }),\n value: z.string().min(1).nullable().optional().meta({\n description:\n 'The value the definition was built for: the one the client sent, checked, or the one the backend chose for a required param.',\n }),\n valueLabel: z\n .string()\n .nullable()\n .optional()\n .meta({ description: 'The label of `value`, for the picker.' }),\n })\n .meta({ description: 'A param of the current context (decision 0045).' });\n\nexport const DefinitionContext = z\n .looseObject({\n params: z.array(ContextParam).min(1).meta({\n description:\n 'In order: each param depends on the params before it. The params are the same whatever the values.',\n }),\n })\n .meta({\n description:\n 'The current context the user picks in the app, sent with every request in the `Panneau-Context` header (decision 0045).',\n });\n\nexport const Widget = z.looseObject({\n id: z.string().min(1),\n type: z.string().min(1).meta({\n description: 'Built-in: `stat`, `chart`, `recent-items`, `shortcuts`, `welcome`.',\n }),\n label: z.string().optional(),\n width: z.number().int().min(1).max(12).optional(),\n settings: z.record(z.string(), z.unknown()).optional(),\n});\n\nexport const Uploads = z.looseObject({\n mode: z.enum(['multipart', 'tus', 'presigned']).meta({\n description:\n '`multipart`: files go through `POST /media` and the requests that take them. `presigned`: the browser also sends files to storage itself, with URLs that `POST /uploads/sign` signs, then `POST /uploads/{upload}/complete` gives an upload that values reference.',\n }),\n endpoint: z.string().optional().meta({\n description:\n '`presigned`: the base URL of the upload routes, when they are not `{api.baseUrl}/uploads`.',\n }),\n maxSize: z.number().int().positive().optional(),\n});\n\nexport const Definition = z\n .looseObject({\n protocol: z.literal(PROTOCOL_VERSION),\n name: z.string(),\n locale: z\n .string()\n .min(2)\n .meta({ description: 'BCP 47 locale of the labels and messages.' }),\n locales: z\n .array(z.string().min(2))\n .min(1)\n .meta({ description: 'Locales of localized content fields.' }),\n api: z.looseObject({ baseUrl: z.string() }),\n resources: z.array(Resource),\n pages: z.record(z.string(), Page).optional(),\n menus: z.record(z.string(), z.array(MenuItem)).optional(),\n routes: z.record(z.string(), z.string()).optional().meta({\n description: 'Named paths of the frontend, for `link` actions and redirects.',\n }),\n auth: Auth.optional(),\n dashboard: z.looseObject({ widgets: z.array(Widget) }).optional(),\n search: z.looseObject({ enabled: z.boolean() }).optional(),\n uploads: Uploads.optional(),\n context: DefinitionContext.optional(),\n theme: DefinitionTheme.optional(),\n user: User.nullable().optional(),\n })\n .superRefine((definition, context) => {\n const ids = new Set<string>();\n definition.resources.forEach((resource, index) => {\n if (ids.has(resource.id)) {\n context.addIssue({\n code: 'custom',\n message: `Duplicate resource id \\`${resource.id}\\`.`,\n path: ['resources', index, 'id'],\n });\n }\n ids.add(resource.id);\n });\n const names = new Set<string>();\n definition.context?.params.forEach((param, index) => {\n if (names.has(param.name)) {\n context.addIssue({\n code: 'custom',\n message: `Duplicate context param \\`${param.name}\\`.`,\n path: ['context', 'params', index, 'name'],\n });\n }\n names.add(param.name);\n if (param.fixed === true && (param.value ?? null) === null) {\n context.addIssue({\n code: 'custom',\n message: `The context param \\`${param.name}\\` is fixed without a value.`,\n path: ['context', 'params', index, 'value'],\n });\n }\n });\n })\n .meta({ description: 'Everything a frontend needs to render the admin for the current user.' });\n\nexport type User = z.infer<typeof User>;\nexport type AuthProvider = z.infer<typeof AuthProvider>;\nexport type AuthToken = z.infer<typeof AuthToken>;\nexport type Auth = z.infer<typeof Auth>;\nexport type MenuItem = z.infer<typeof MenuItem>;\nexport type Page = z.infer<typeof Page>;\nexport type ContextOption = z.infer<typeof ContextOption>;\nexport type ContextParam = z.infer<typeof ContextParam>;\nexport type DefinitionContext = z.infer<typeof DefinitionContext>;\nexport type Widget = z.infer<typeof Widget>;\nexport type Uploads = z.infer<typeof Uploads>;\nexport type Definition = z.infer<typeof Definition>;\n/** A definition as a backend writes it, before defaults are applied. */\nexport type DefinitionInput = z.input<typeof Definition>;\n"],"mappings":";;;;;;;AAQA,IAAa,OAAO,EAAE,YAAY;CAC9B,IAAI;CACJ,MAAM,EAAE,OAAO;CACf,OAAO,EAAE,OAAO,CAAC,CAAC,SAAS;CAC3B,WAAW,EAAE,OAAO,CAAC,CAAC,SAAS;CAC/B,WAAW,UAAU,SAAS;CAC9B,UAAU,EAAE,OAAO,CAAC,CAAC,SAAS,CAAC,CAAC,KAAK,EACjC,aACI,8HACR,CAAC;AACL,CAAC;AAED,IAAa,eAAe,EAAE,YAAY;CACtC,IAAI,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC;CACpB,OAAO,EAAE,OAAO;CAChB,KAAK,EAAE,OAAO,CAAC,CAAC,SAAS,CAAC,CAAC,KAAK,EAAE,aAAa,6CAA6C,CAAC;CAC7F,MAAM,EAAE,OAAO,CAAC,CAAC,SAAS;AAC9B,CAAC;AAED,IAAa,YAAY,EAAE,YAAY;CACnC,OAAO,EAAE,OAAO,CAAC,CAAC,SAAS,CAAC,CAAC,KAAK,EAAE,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ACN,SAAS,2BAA2B,SAAS,GAAG;GAChD,MAAM;IAAC;IAAa;IAAO;GAAI;EACnC,CAAC;EAEL,IAAI,IAAI,SAAS,EAAE;CACvB,CAAC;CACD,MAAM,wBAAQ,IAAI,IAAY;CAC9B,WAAW,SAAS,OAAO,SAAS,OAAO,UAAU;EACjD,IAAI,MAAM,IAAI,MAAM,IAAI,GACpB,QAAQ,SAAS;GACb,MAAM;GACN,SAAS,6BAA6B,MAAM,KAAK;GACjD,MAAM;IAAC;IAAW;IAAU;IAAO;GAAM;EAC7C,CAAC;EAEL,MAAM,IAAI,MAAM,IAAI;EACpB,IAAI,MAAM,UAAU,SAAS,MAAM,SAAS,UAAU,MAClD,QAAQ,SAAS;GACb,MAAM;GACN,SAAS,uBAAuB,MAAM,KAAK;GAC3C,MAAM;IAAC;IAAW;IAAU;IAAO;GAAO;EAC9C,CAAC;CAET,CAAC;AACL,CAAC,CAAC,CACD,KAAK,EAAE,aAAa,wEAAwE,CAAC"}
1
+ {"version":3,"file":"definition.js","names":[],"sources":["../../src/schemas/definition.ts"],"sourcesContent":["import { z } from 'zod';\n\nimport { RESERVED_ROUTE_SEGMENTS } from '../constants';\nimport { PROTOCOL_VERSION } from '../version';\nimport { Abilities, Id } from './common';\nimport { Resource } from './resource';\nimport { DefinitionTheme } from './theme';\n\nexport const User = z.looseObject({\n id: Id,\n name: z.string(),\n email: z.string().optional(),\n avatarUrl: z.string().optional(),\n abilities: Abilities.optional(),\n resource: z.string().optional().meta({\n description:\n 'The resource of users: its item with this `id` is the profile of the user. Without it, clients look for a resource `users`.',\n }),\n});\n\nexport const AuthProvider = z.looseObject({\n id: z.string().min(1),\n label: z.string(),\n url: z.string().optional().meta({\n description:\n 'Where the login with this provider starts, with a full navigation. The app adds `next`, the path to come back to.',\n }),\n icon: z.string().optional(),\n});\n\nexport const AuthToken = z.looseObject({\n label: z.string().optional().meta({ description: 'Label of the field. Defaults to \"Token\".' }),\n help: z.string().optional().meta({ description: 'Help under the field: where to find it.' }),\n});\n\nexport const Auth = z.looseObject({\n mode: z.enum(['panneau', 'external']).meta({\n description: \"`panneau`: Panneau's own login pages. `external`: the site handles login.\",\n }),\n loginUrl: z\n .string()\n .nullable()\n .optional()\n .meta({ description: '`external`: where unauthenticated users are sent.' }),\n logoutUrl: z.string().nullable().optional().meta({\n description:\n \"`external`: where the browser goes to log out, the site's own logout. Without it, the app offers no logout.\",\n }),\n password: z.boolean().optional().meta({\n description:\n '`panneau`: a login with an email and a password. Defaults to true without `token`.',\n }),\n token: AuthToken.optional().meta({\n description:\n '`panneau`: a login with a single secret, such as an access token, sent as `token` to `POST /auth/login`.',\n }),\n providers: z.array(AuthProvider).optional(),\n account: z.boolean().optional().meta({\n description:\n '`panneau`: the account page of the user, on `/account`: their name and email, their password, their two-factor authentication.',\n }),\n passwordReset: z.boolean().optional().meta({\n description:\n '`panneau`: a \"Forgot your password?\" link on the login page, through `POST /auth/password/forgot` and `POST /auth/password/reset`.',\n }),\n twoFactor: z.boolean().optional().meta({\n description:\n '`panneau`: two-factor authentication, which users set up through `/account/two-factor`, and which a password login asks for with a `202`.',\n }),\n passkeys: z.boolean().optional().meta({\n description:\n '`panneau`: logins with a passkey (WebAuthn), which users add on the account page.',\n }),\n emailVerification: z.boolean().optional().meta({\n description:\n \"`panneau`: the backend refuses users whose email address isn't verified with a `403` problem of type `urn:panneau:problem:email-unverified`, and verifies it through `POST /auth/email/verification` and `POST /auth/email/verify`.\",\n }),\n});\n\nexport const MenuItem = z\n .looseObject({\n type: z.string().min(1).meta({\n description: 'Built-in: `resources`, `resource`, `page`, `link`, `separator`, `group`.',\n }),\n label: z.string().optional(),\n icon: z.string().optional(),\n resource: z.string().optional(),\n page: z.string().optional(),\n url: z.string().optional(),\n external: z.boolean().optional(),\n // The return type is written out so that declaration files keep the recursion.\n get children(): z.ZodOptional<z.ZodArray<typeof MenuItem>> {\n return z.array(MenuItem).optional();\n },\n })\n .meta({ description: 'An entry of a menu.' });\n\nexport const Page = z.looseObject({\n component: z\n .string()\n .min(1)\n .meta({ description: 'A page provided by a plugin, or a built-in page.' }),\n path: z.string().optional().meta({ description: 'Path of a custom page.' }),\n label: z.string().optional(),\n props: z.record(z.string(), z.unknown()).optional(),\n params: z\n .array(z.string().regex(/^[A-Za-z_][A-Za-z0-9_]*$/))\n .optional()\n .meta({\n description:\n 'Names of the path segments after the page: `[\"id\"]` makes `{basePath}/pages/{page}/{id}`. The component gets them as `params`, and route references (`{ \"route\": \"<page>\", \"params\": { \"id\": … } }`) can link to the page. A page with `params` is not in menus.',\n }),\n abilities: Abilities.optional().meta({\n description:\n 'What the current user can do with the page (decision 0046). `view: false` leaves it out of menus, and its route shows a forbidden state; `pages.home` falls back to the built-in home. Without it, the page is allowed.',\n }),\n});\n\nexport const ContextOption = z\n .looseObject({\n value: z.string().min(1),\n label: z.string(),\n description: z.string().optional(),\n })\n .meta({ description: 'A choice of a param of the context.' });\n\nexport const ContextParam = z\n .looseObject({\n name: z\n .string()\n .regex(\n new RegExp(`^(?!(?:${RESERVED_ROUTE_SEGMENTS.join('|')})$)[A-Za-z_][A-Za-z0-9_]*$`),\n )\n .meta({\n description:\n 'The name of the param, in the `Panneau-Context` header and in the client routes (`{basePath}/{name}/{value}/…`): an identifier, not a reserved first segment of the routes.',\n }),\n label: z.string(),\n required: z.boolean().optional().meta({\n description:\n 'Whether the app needs a value: without one, it shows a page to pick it in place of the page of the route.',\n }),\n fixed: z.boolean().optional().meta({\n description:\n 'The backend sets the value from the request, such as its domain: the app shows it without a picker, and leaves it out of the path and of the `Panneau-Context` header. Another value in the header is a `403` context problem. A fixed param has a `value`.',\n }),\n allLabel: z.string().optional().meta({\n description: 'An optional param: the label of no value, such as \"All clients\".',\n }),\n options: z.array(ContextOption).optional().meta({\n description:\n 'The choices, inline. Without them, the client searches them with `GET /context/{name}/options`.',\n }),\n value: z.string().min(1).nullable().optional().meta({\n description:\n 'The value the definition was built for: the one the client sent, checked, or the one the backend chose for a required param.',\n }),\n valueLabel: z\n .string()\n .nullable()\n .optional()\n .meta({ description: 'The label of `value`, for the picker.' }),\n })\n .meta({ description: 'A param of the current context (decision 0045).' });\n\nexport const DefinitionContext = z\n .looseObject({\n params: z.array(ContextParam).min(1).meta({\n description:\n 'In order: each param depends on the params before it. The params are the same whatever the values.',\n }),\n })\n .meta({\n description:\n 'The current context the user picks in the app, sent with every request in the `Panneau-Context` header (decision 0045).',\n });\n\nexport const Widget = z.looseObject({\n id: z.string().min(1),\n type: z.string().min(1).meta({\n description: 'Built-in: `stat`, `chart`, `recent-items`, `shortcuts`, `welcome`.',\n }),\n label: z.string().optional(),\n width: z.number().int().min(1).max(12).optional(),\n settings: z.record(z.string(), z.unknown()).optional(),\n});\n\nexport const Uploads = z.looseObject({\n mode: z.enum(['multipart', 'tus', 'presigned']).meta({\n description:\n '`multipart`: files go through `POST /media` and the requests that take them. `presigned`: the browser also sends files to storage itself, with URLs that `POST /uploads/sign` signs, then `POST /uploads/{upload}/complete` gives an upload that values reference.',\n }),\n endpoint: z.string().optional().meta({\n description:\n '`presigned`: the base URL of the upload routes, when they are not `{api.baseUrl}/uploads`.',\n }),\n maxSize: z.number().int().positive().optional(),\n});\n\nexport const Definition = z\n .looseObject({\n protocol: z.literal(PROTOCOL_VERSION),\n name: z.string(),\n locale: z\n .string()\n .min(2)\n .meta({ description: 'BCP 47 locale of the labels and messages.' }),\n locales: z\n .array(z.string().min(2))\n .min(1)\n .meta({ description: 'Locales of localized content fields.' }),\n api: z.looseObject({ baseUrl: z.string() }),\n resources: z.array(Resource),\n pages: z.record(z.string(), Page).optional(),\n menus: z.record(z.string(), z.array(MenuItem)).optional(),\n routes: z.record(z.string(), z.string()).optional().meta({\n description: 'Named paths of the frontend, for `link` actions and redirects.',\n }),\n auth: Auth.optional(),\n dashboard: z.looseObject({ widgets: z.array(Widget) }).optional(),\n search: z.looseObject({ enabled: z.boolean() }).optional(),\n uploads: Uploads.optional(),\n context: DefinitionContext.optional(),\n theme: DefinitionTheme.optional(),\n user: User.nullable().optional(),\n })\n .superRefine((definition, context) => {\n const ids = new Set<string>();\n definition.resources.forEach((resource, index) => {\n if (ids.has(resource.id)) {\n context.addIssue({\n code: 'custom',\n message: `Duplicate resource id \\`${resource.id}\\`.`,\n path: ['resources', index, 'id'],\n });\n }\n ids.add(resource.id);\n });\n const names = new Set<string>();\n definition.context?.params.forEach((param, index) => {\n if (names.has(param.name)) {\n context.addIssue({\n code: 'custom',\n message: `Duplicate context param \\`${param.name}\\`.`,\n path: ['context', 'params', index, 'name'],\n });\n }\n names.add(param.name);\n if (param.fixed === true && (param.value ?? null) === null) {\n context.addIssue({\n code: 'custom',\n message: `The context param \\`${param.name}\\` is fixed without a value.`,\n path: ['context', 'params', index, 'value'],\n });\n }\n });\n })\n .meta({ description: 'Everything a frontend needs to render the admin for the current user.' });\n\nexport type User = z.infer<typeof User>;\nexport type AuthProvider = z.infer<typeof AuthProvider>;\nexport type AuthToken = z.infer<typeof AuthToken>;\nexport type Auth = z.infer<typeof Auth>;\nexport type MenuItem = z.infer<typeof MenuItem>;\nexport type Page = z.infer<typeof Page>;\nexport type ContextOption = z.infer<typeof ContextOption>;\nexport type ContextParam = z.infer<typeof ContextParam>;\nexport type DefinitionContext = z.infer<typeof DefinitionContext>;\nexport type Widget = z.infer<typeof Widget>;\nexport type Uploads = z.infer<typeof Uploads>;\nexport type Definition = z.infer<typeof Definition>;\n/** A definition as a backend writes it, before defaults are applied. */\nexport type DefinitionInput = z.input<typeof Definition>;\n"],"mappings":";;;;;;;AAQA,IAAa,OAAO,EAAE,YAAY;CAC9B,IAAI;CACJ,MAAM,EAAE,OAAO;CACf,OAAO,EAAE,OAAO,CAAC,CAAC,SAAS;CAC3B,WAAW,EAAE,OAAO,CAAC,CAAC,SAAS;CAC/B,WAAW,UAAU,SAAS;CAC9B,UAAU,EAAE,OAAO,CAAC,CAAC,SAAS,CAAC,CAAC,KAAK,EACjC,aACI,8HACR,CAAC;AACL,CAAC;AAED,IAAa,eAAe,EAAE,YAAY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1143
  icon: z.ZodOptional<z.ZodString>;
1144
1144
  }, z.core.$loose>>>;
1145
+ account: z.ZodOptional<z.ZodBoolean>;
1145
1146
  passwordReset: z.ZodOptional<z.ZodBoolean>;
1146
1147
  twoFactor: z.ZodOptional<z.ZodBoolean>;
1147
1148
  passkeys: z.ZodOptional<z.ZodBoolean>;
@@ -1879,6 +1880,7 @@ export declare const namedSchemas: {
1879
1880
  url: z.ZodOptional<z.ZodString>;
1880
1881
  icon: z.ZodOptional<z.ZodString>;
1881
1882
  }, z.core.$loose>>>;
1883
+ account: z.ZodOptional<z.ZodBoolean>;
1882
1884
  passwordReset: z.ZodOptional<z.ZodBoolean>;
1883
1885
  twoFactor: z.ZodOptional<z.ZodBoolean>;
1884
1886
  passkeys: z.ZodOptional<z.ZodBoolean>;
@@ -2461,6 +2463,35 @@ export declare const namedSchemas: {
2461
2463
  resource: z.ZodOptional<z.ZodString>;
2462
2464
  }, z.core.$loose>;
2463
2465
  }, z.core.$loose>;
2466
+ TwoFactorChallenge: z.ZodObject<{
2467
+ twoFactor: z.ZodLiteral<true>;
2468
+ }, z.core.$loose>;
2469
+ TwoFactorStatus: z.ZodObject<{
2470
+ status: z.ZodEnum<{
2471
+ disabled: "disabled";
2472
+ enabled: "enabled";
2473
+ pending: "pending";
2474
+ }>;
2475
+ required: z.ZodBoolean;
2476
+ }, z.core.$loose>;
2477
+ TwoFactorSetup: z.ZodObject<{
2478
+ secret: z.ZodString;
2479
+ otpauthUrl: z.ZodString;
2480
+ qrCode: z.ZodOptional<z.ZodString>;
2481
+ }, z.core.$loose>;
2482
+ RecoveryCodes: z.ZodObject<{
2483
+ recoveryCodes: z.ZodArray<z.ZodString>;
2484
+ }, z.core.$loose>;
2485
+ WebAuthnOptions: z.ZodObject<{
2486
+ options: z.ZodRecord<z.ZodString, z.ZodUnknown>;
2487
+ }, z.core.$loose>;
2488
+ Passkey: z.ZodObject<{
2489
+ id: z.ZodString;
2490
+ name: z.ZodString;
2491
+ authenticator: z.ZodOptional<z.ZodNullable<z.ZodString>>;
2492
+ createdAt: z.ZodString;
2493
+ lastUsedAt: z.ZodNullable<z.ZodString>;
2494
+ }, z.core.$loose>;
2464
2495
  SearchResponse: z.ZodObject<{
2465
2496
  data: z.ZodArray<z.ZodObject<{
2466
2497
  resource: z.ZodString;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/schemas/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,OAAO,EAmBH,cAAc,EAajB,MAAM,OAAO,CAAC;AACf,OAAO,EAAa,SAAS,EAA8B,MAAM,UAAU,CAAC;AAC5E,OAAO,EAQH,QAAQ,EAKX,MAAM,cAAc,CAAC;AACtB,OAAO,EAAE,SAAS,EAAE,KAAK,EAAyC,MAAM,SAAS,CAAC;AAElF,OAAO,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AActC,cAAc,UAAU,CAAC;AACzB,cAAc,SAAS,CAAC;AACxB,cAAc,UAAU,CAAC;AACzB,cAAc,QAAQ,CAAC;AACvB,cAAc,UAAU,CAAC;AACzB,cAAc,YAAY,CAAC;AAC3B,cAAc,SAAS,CAAC;AACxB,cAAc,cAAc,CAAC;AAC7B,cAAc,OAAO,CAAC;AACtB,cAAc,QAAQ,CAAC;AAEvB,wGAAwG;AACxG,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA+EY,CAAC;AAEtC,0FAA0F;AAC1F,wBAAgB,oBAAoB;QACE,MAAM;4GAK3C"}
@@ -7,7 +7,7 @@ import { Column, Filter, ListCalendar, ListDefinition } from "./list.js";
7
7
  import { Resource, ResourceFeatures } from "./resource.js";
8
8
  import { DefinitionTheme, Theme, ThemeFont, ThemeFontFace, ThemeFontStylesheet, ThemeTokens, ToneInput, ToneValues } from "./theme.js";
9
9
  import { Auth, AuthProvider, AuthToken, ContextOption, ContextParam, Definition, DefinitionContext, MenuItem, Page, Uploads, User, Widget } from "./definition.js";
10
- import { ActionItemResult, ActionRequest, ActionResult, ActionRun, ActionRunResponse, ContextOptionsResponse, CursorPagination, EmbedResponse, EmbedValue, FieldCheckRequest, FieldCheckResponse, Item, ItemResponse, ListResponse, LocationValue, MediaInfo, MediaItem, MediaReference, MediaTransform, Pagination, PreviewResponse, Problem, SearchResponse, Selection, Session, StoredFile, Upload, UploadReference, UploadResponse, UploadSignRequest, UploadSignResponse } from "./api.js";
10
+ import { ActionItemResult, ActionRequest, ActionResult, ActionRun, ActionRunResponse, ContextOptionsResponse, CursorPagination, EmbedResponse, EmbedValue, FieldCheckRequest, FieldCheckResponse, Item, ItemResponse, ListResponse, LocationValue, MediaInfo, MediaItem, MediaReference, MediaTransform, Pagination, Passkey, PreviewResponse, Problem, RecoveryCodes, SearchResponse, Selection, Session, StoredFile, TwoFactorChallenge, TwoFactorSetup, TwoFactorStatus, Upload, UploadReference, UploadResponse, UploadSignRequest, UploadSignResponse, WebAuthnOptions } from "./api.js";
11
11
  import { BootConfig } from "./boot.js";
12
12
  import { z } from "zod";
13
13
  //#region src/schemas/index.ts
@@ -79,6 +79,12 @@ var namedSchemas = {
79
79
  MediaItem,
80
80
  MediaReference,
81
81
  Session,
82
+ TwoFactorChallenge,
83
+ TwoFactorStatus,
84
+ TwoFactorSetup,
85
+ RecoveryCodes,
86
+ WebAuthnOptions,
87
+ Passkey,
82
88
  SearchResponse,
83
89
  ContextOptionsResponse,
84
90
  PreviewResponse,
@@ -97,6 +103,6 @@ function createSchemaRegistry() {
97
103
  return registry;
98
104
  }
99
105
  //#endregion
100
- export { Abilities, Action, ActionConfirm, ActionItemResult, ActionPlacement, ActionRequest, ActionResult, ActionRun, ActionRunResponse, ActionScope, Auth, AuthProvider, AuthToken, BlockType, BootConfig, Column, Condition, ContextOption, ContextOptionsResponse, ContextParam, CursorPagination, Definition, DefinitionContext, DefinitionTheme, EmbedResponse, EmbedValue, Field, FieldCheckRequest, FieldCheckResponse, Filter, Id, Item, ItemResponse, LayoutNode, ListCalendar, ListDefinition, ListResponse, LocationValue, MediaInfo, MediaItem, MediaReference, MediaTransform, MenuItem, Option, Page, Pagination, PreviewResponse, Problem, Resource, ResourceFeatures, RichTextSettings, RichTextStyle, RouteReference, Rule, SearchResponse, Selection, Session, StoredFile, Theme, ThemeFont, ThemeFontFace, ThemeFontStylesheet, ThemeTokens, ToneInput, ToneValues, Upload, UploadReference, UploadResponse, UploadSignRequest, UploadSignResponse, Uploads, User, Widget, createSchemaRegistry, namedSchemas };
106
+ export { Abilities, Action, ActionConfirm, ActionItemResult, ActionPlacement, ActionRequest, ActionResult, ActionRun, ActionRunResponse, ActionScope, Auth, AuthProvider, AuthToken, BlockType, BootConfig, Column, Condition, ContextOption, ContextOptionsResponse, ContextParam, CursorPagination, Definition, DefinitionContext, DefinitionTheme, EmbedResponse, EmbedValue, Field, FieldCheckRequest, FieldCheckResponse, Filter, Id, Item, ItemResponse, LayoutNode, ListCalendar, ListDefinition, ListResponse, LocationValue, MediaInfo, MediaItem, MediaReference, MediaTransform, MenuItem, Option, Page, Pagination, Passkey, PreviewResponse, Problem, RecoveryCodes, Resource, ResourceFeatures, RichTextSettings, RichTextStyle, RouteReference, Rule, SearchResponse, Selection, Session, StoredFile, Theme, ThemeFont, ThemeFontFace, ThemeFontStylesheet, ThemeTokens, ToneInput, ToneValues, TwoFactorChallenge, TwoFactorSetup, TwoFactorStatus, Upload, UploadReference, UploadResponse, UploadSignRequest, UploadSignResponse, Uploads, User, WebAuthnOptions, Widget, createSchemaRegistry, namedSchemas };
101
107
 
102
108
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":[],"sources":["../../src/schemas/index.ts"],"sourcesContent":["import { z } from 'zod';\n\nimport { Action, ActionConfirm, ActionPlacement, ActionScope } from './action';\nimport {\n ActionItemResult,\n ActionRequest,\n ActionResult,\n ActionRun,\n ActionRunResponse,\n ContextOptionsResponse,\n CursorPagination,\n EmbedResponse,\n EmbedValue,\n FieldCheckRequest,\n FieldCheckResponse,\n Item,\n ItemResponse,\n ListResponse,\n LocationValue,\n MediaInfo,\n MediaItem,\n MediaReference,\n MediaTransform,\n Pagination,\n PreviewResponse,\n Problem,\n SearchResponse,\n Selection,\n Session,\n StoredFile,\n Upload,\n UploadReference,\n UploadResponse,\n UploadSignRequest,\n UploadSignResponse,\n} from './api';\nimport { Abilities, Condition, Id, Option, RouteReference } from './common';\nimport {\n Auth,\n AuthProvider,\n AuthToken,\n ContextOption,\n ContextParam,\n Definition,\n DefinitionContext,\n MenuItem,\n Page,\n Uploads,\n User,\n Widget,\n} from './definition';\nimport { BlockType, Field, RichTextSettings, RichTextStyle, Rule } from './field';\nimport { actionJsonRules } from './jsonRules';\nimport { LayoutNode } from './layout';\nimport { Column, Filter, ListCalendar, ListDefinition } from './list';\nimport { Resource, ResourceFeatures } from './resource';\nimport {\n DefinitionTheme,\n Theme,\n ThemeFont,\n ThemeFontFace,\n ThemeFontStylesheet,\n ThemeTokens,\n ToneInput,\n ToneValues,\n} from './theme';\n\nexport * from './common';\nexport * from './field';\nexport * from './layout';\nexport * from './list';\nexport * from './action';\nexport * from './resource';\nexport * from './theme';\nexport * from './definition';\nexport * from './api';\nexport * from './boot';\n\n/** The named schemas of the protocol, as they appear in the generated JSON Schema and OpenAPI files. */\nexport const namedSchemas = {\n Id,\n Abilities,\n RouteReference,\n Condition,\n Option,\n Rule,\n BlockType,\n Field,\n RichTextStyle,\n RichTextSettings,\n LayoutNode,\n Column,\n Filter,\n ListCalendar,\n ListDefinition,\n ActionScope,\n ActionPlacement,\n ActionConfirm,\n Action,\n ResourceFeatures,\n Resource,\n User,\n AuthProvider,\n AuthToken,\n Auth,\n MenuItem,\n Page,\n Widget,\n Uploads,\n ContextOption,\n ContextParam,\n DefinitionContext,\n ThemeTokens,\n ToneValues,\n ToneInput,\n ThemeFontFace,\n ThemeFontStylesheet,\n ThemeFont,\n Theme,\n DefinitionTheme,\n Definition,\n Item,\n Pagination,\n CursorPagination,\n ItemResponse,\n ListResponse,\n Problem,\n Selection,\n ActionRequest,\n ActionItemResult,\n ActionResult,\n ActionRun,\n ActionRunResponse,\n MediaTransform,\n StoredFile,\n UploadReference,\n Upload,\n UploadResponse,\n UploadSignRequest,\n UploadSignResponse,\n FieldCheckRequest,\n FieldCheckResponse,\n MediaInfo,\n MediaItem,\n MediaReference,\n Session,\n SearchResponse,\n ContextOptionsResponse,\n PreviewResponse,\n EmbedValue,\n EmbedResponse,\n LocationValue,\n} satisfies Record<string, z.ZodType>;\n\n/** A registry of the named schemas, used to reference them by name in generated files. */\nexport function createSchemaRegistry() {\n const registry = z.registry<{ id: string } & Record<string, unknown>>();\n Object.entries(namedSchemas).forEach(([id, schema]) => registry.add(schema, { id }));\n // Checks that Zod makes in code, which the JSON Schema of the definition must make too.\n registry.add(Action, { id: 'Action', ...actionJsonRules });\n return registry;\n}\n"],"mappings":";;;;;;;;;;;;;;AA+EA,IAAa,eAAe;CACxB;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;AACJ;;AAGA,SAAgB,uBAAuB;CACnC,MAAM,WAAW,EAAE,SAAmD;CACtE,OAAO,QAAQ,YAAY,CAAC,CAAC,SAAS,CAAC,IAAI,YAAY,SAAS,IAAI,QAAQ,EAAE,GAAG,CAAC,CAAC;CAEnF,SAAS,IAAI,QAAQ;EAAE,IAAI;EAAU,GAAG;CAAgB,CAAC;CACzD,OAAO;AACX"}
1
+ {"version":3,"file":"index.js","names":[],"sources":["../../src/schemas/index.ts"],"sourcesContent":["import { z } from 'zod';\n\nimport { Action, ActionConfirm, ActionPlacement, ActionScope } from './action';\nimport {\n ActionItemResult,\n ActionRequest,\n ActionResult,\n ActionRun,\n ActionRunResponse,\n ContextOptionsResponse,\n CursorPagination,\n EmbedResponse,\n EmbedValue,\n FieldCheckRequest,\n FieldCheckResponse,\n Item,\n ItemResponse,\n ListResponse,\n LocationValue,\n MediaInfo,\n MediaItem,\n MediaReference,\n MediaTransform,\n Pagination,\n Passkey,\n PreviewResponse,\n Problem,\n RecoveryCodes,\n SearchResponse,\n Selection,\n Session,\n StoredFile,\n TwoFactorChallenge,\n TwoFactorSetup,\n TwoFactorStatus,\n Upload,\n UploadReference,\n UploadResponse,\n UploadSignRequest,\n UploadSignResponse,\n WebAuthnOptions,\n} from './api';\nimport { Abilities, Condition, Id, Option, RouteReference } from './common';\nimport {\n Auth,\n AuthProvider,\n AuthToken,\n ContextOption,\n ContextParam,\n Definition,\n DefinitionContext,\n MenuItem,\n Page,\n Uploads,\n User,\n Widget,\n} from './definition';\nimport { BlockType, Field, RichTextSettings, RichTextStyle, Rule } from './field';\nimport { actionJsonRules } from './jsonRules';\nimport { LayoutNode } from './layout';\nimport { Column, Filter, ListCalendar, ListDefinition } from './list';\nimport { Resource, ResourceFeatures } from './resource';\nimport {\n DefinitionTheme,\n Theme,\n ThemeFont,\n ThemeFontFace,\n ThemeFontStylesheet,\n ThemeTokens,\n ToneInput,\n ToneValues,\n} from './theme';\n\nexport * from './common';\nexport * from './field';\nexport * from './layout';\nexport * from './list';\nexport * from './action';\nexport * from './resource';\nexport * from './theme';\nexport * from './definition';\nexport * from './api';\nexport * from './boot';\n\n/** The named schemas of the protocol, as they appear in the generated JSON Schema and OpenAPI files. */\nexport const namedSchemas = {\n Id,\n Abilities,\n RouteReference,\n Condition,\n Option,\n Rule,\n BlockType,\n Field,\n RichTextStyle,\n RichTextSettings,\n LayoutNode,\n Column,\n Filter,\n ListCalendar,\n ListDefinition,\n ActionScope,\n ActionPlacement,\n ActionConfirm,\n Action,\n ResourceFeatures,\n Resource,\n User,\n AuthProvider,\n AuthToken,\n Auth,\n MenuItem,\n Page,\n Widget,\n Uploads,\n ContextOption,\n ContextParam,\n DefinitionContext,\n ThemeTokens,\n ToneValues,\n ToneInput,\n ThemeFontFace,\n ThemeFontStylesheet,\n ThemeFont,\n Theme,\n DefinitionTheme,\n Definition,\n Item,\n Pagination,\n CursorPagination,\n ItemResponse,\n ListResponse,\n Problem,\n Selection,\n ActionRequest,\n ActionItemResult,\n ActionResult,\n ActionRun,\n ActionRunResponse,\n MediaTransform,\n StoredFile,\n UploadReference,\n Upload,\n UploadResponse,\n UploadSignRequest,\n UploadSignResponse,\n FieldCheckRequest,\n FieldCheckResponse,\n MediaInfo,\n MediaItem,\n MediaReference,\n Session,\n TwoFactorChallenge,\n TwoFactorStatus,\n TwoFactorSetup,\n RecoveryCodes,\n WebAuthnOptions,\n Passkey,\n SearchResponse,\n ContextOptionsResponse,\n PreviewResponse,\n EmbedValue,\n EmbedResponse,\n LocationValue,\n} satisfies Record<string, z.ZodType>;\n\n/** A registry of the named schemas, used to reference them by name in generated files. */\nexport function createSchemaRegistry() {\n const registry = z.registry<{ id: string } & Record<string, unknown>>();\n Object.entries(namedSchemas).forEach(([id, schema]) => registry.add(schema, { id }));\n // Checks that Zod makes in code, which the JSON Schema of the definition must make too.\n registry.add(Action, { id: 'Action', ...actionJsonRules });\n return registry;\n}\n"],"mappings":";;;;;;;;;;;;;;AAqFA,IAAa,eAAe;CACxB;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;AACJ;;AAGA,SAAgB,uBAAuB;CACnC,MAAM,WAAW,EAAE,SAAmD;CACtE,OAAO,QAAQ,YAAY,CAAC,CAAC,SAAS,CAAC,IAAI,YAAY,SAAS,IAAI,QAAQ,EAAE,GAAG,CAAC,CAAC;CAEnF,SAAS,IAAI,QAAQ;EAAE,IAAI;EAAU,GAAG;CAAgB,CAAC;CACzD,OAAO;AACX"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@panneau/protocol",
3
- "version": "5.0.0-alpha.14",
3
+ "version": "5.0.0-alpha.15",
4
4
  "description": "The Panneau protocol: definition schema, HTTP API spec and conformance kit",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -1433,6 +1433,9 @@
1433
1433
  "$ref": "#/$defs/AuthProvider"
1434
1434
  }
1435
1435
  },
1436
+ "account": {
1437
+ "type": "boolean"
1438
+ },
1436
1439
  "passwordReset": {
1437
1440
  "type": "boolean"
1438
1441
  },
@@ -1396,6 +1396,9 @@
1396
1396
  "$ref": "#/$defs/AuthProvider"
1397
1397
  }
1398
1398
  },
1399
+ "account": {
1400
+ "type": "boolean"
1401
+ },
1399
1402
  "passwordReset": {
1400
1403
  "type": "boolean"
1401
1404
  },