Skip to content

Commit 49a8e27

Browse files
committed
chore: regenerate the authorable surface on the merged tree; the released 24298 note is left as main has it
Claude-Session: https://claude.ai/code/session_01Q3mCs3NX4GshNUCh7Fr1b9 Co-authored-by: Claude <noreply@anthropic.com>
1 parent ede2401 commit 49a8e27

3 files changed

Lines changed: 3 additions & 2 deletions

File tree

‎.changeset/24395-draft-changes-surface.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,4 @@ Clause-②: yes (widening)
88

99
- **One closed set, one name.** `MetadataAuthoringSurfaceSchema` (`copilot | studio | api`) is exported from `@objectstack/spec/api`, with its type `MetadataAuthoringSurface`. `GetMetaItemResponseSchema.draftChanges[].by` now reads it instead of an inline enum: the accepted values are unchanged.
1010
- **The save states its surface.** `SaveMetaItemRequestSchema` gains an optional `surface` from that set. A draft save stamps it as `by` on each key path it changes; an absent `surface` stamps `api`. On the REST door and the runtime dispatcher it is the `?surface=` query parameter, which takes `studio` or `api` only: `copilot` is stated by an in-process AI tool, never over HTTP.
11-
- **The writer exists.** The `draftChanges` describe no longer says no server writes it: it states the writer's rules (the first draft save is compared with the stored published row, an item with no stored published row is recorded as `[]`, and a `migrate-stored` rewrite records nothing).
11+
- **The writer exists.** The `draftChanges` describe no longer says no server writes it: it states the writer's rules (the first draft save is compared with the stored published row, an item with no stored published row is recorded as `[]`, and a `migrate-stored` rewrite records nothing). `18.0.0-next.4`'s note said no server writes `draftChanges` yet; from this release the draft save writes it.

‎.changeset/pre/24298-draft-key-provenance.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,5 @@ Clause-②: yes (widening)
88

99
- **The key.** `GetMetaItemResponseSchema` gains an optional `draftChanges` beside `item`: one entry per changed key path of the pending draft body, each `{ path, by, actor, at }`. `path` is an array of the keys from the body root to the deepest key the write changed (`["fields", "renewal_count"]`, `["fields", "renewal_count", "label"]`); an array value is one leaf, so a change to a view's columns is `["columns"]` and never carries an index (which elements differ is read by comparing the array with the published body's; the entry says who last changed the array); `[]` is the whole body of an item created as a draft. `by` is a closed set: `copilot` (an AI assistant's tool writing on a person's behalf), `studio` (a person editing in Studio) or `api` (any other caller of the save door). `actor` is the write's recorded identity or `null`, and `at` its ISO-8601 instant.
1010
- **Where it is served.** Only on the strict draft read (`GET /meta/:type/:name?state=draft`), the read Studio's editor loads an item from, so the marks always describe the body that read returned. It is absent on the active read, the cached branch and the `?preview=draft` read. `ListDraftsResponseSchema` (`GET /meta/_drafts`) is unchanged.
11-
- **Absent means "not recorded".** For a draft row whose saves recorded nothing (one saved before a server recorded the key), the key is absent rather than `[]`, so a reader never takes "not recorded" for "nothing changed".
11+
- **Absent means "not recorded".** No server writes the key yet; until one does, and for a draft row saved before it did, the key is absent rather than `[]`, so a reader never takes "not recorded" for "nothing changed".
1212
- **Nothing breaks.** Every response that parsed before still parses, and no runtime behaviour changes in this release of the spec.

‎packages/spec/authorable-surface/api.json‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1701,6 +1701,7 @@
17011701
"api/TriggerFlowResponse:success",
17021702
"api/UndoImportJobResponse:deleted",
17031703
"api/UndoImportJobResponse:failed",
1704+
"api/UndoImportJobResponse:failures",
17041705
"api/UndoImportJobResponse:jobId",
17051706
"api/UndoImportJobResponse:object",
17061707
"api/UndoImportJobResponse:restored",

0 commit comments

Comments
 (0)