Skip to content

Commit fc90ce5

Browse files
committed
Merge origin/main (0389650) into claude/issue-9547-ongrid-onnavigate-prop
Claude-Session: https://claude.ai/code/session_0122Knsowci76D2rBWReCzzZ Co-authored-by: Claude <noreply@anthropic.com>
2 parents 0c73dfb + 0389650 commit fc90ce5

51 files changed

Lines changed: 3279 additions & 223 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
---
2+
'@object-ui/components': minor
3+
---
4+
5+
The four `action:*` blocks now publish the `@objectstack/spec` keys their
6+
renderers honour, and stop publishing what the spec refuses (objectui#11168,
7+
slice 1). Each key was decided by measuring it through `SchemaRenderer` and the
8+
action runner, per the objectui#11111 ruling: declare what the block path
9+
honours, refuse or retire what it does not.
10+
11+
Newly published, so the SDUI manifest, the JSX intrinsics and the page
12+
validator accept them instead of reporting `unknown-prop`:
13+
14+
- `action:button` and `action:icon`: `visible`, `disabled`, `params`,
15+
`description`, `openIn`, `method`, `bodyExtra`, `bodyShape`, `operation`,
16+
`patch`, `confirmText`, `successMessage`, `errorMessage`, `refreshAfter`,
17+
`locations`, `toast`, `resultDialog`, `onSuccess` and `objectName`; and
18+
`recordIdField` on `action:button`. `params` is published as the list of
19+
parameters to collect; static execution values stay under
20+
`properties.params`.
21+
- `action:group`: `location` and `visible`.
22+
- `action:menu`: `size` and `visible`.
23+
24+
Retired and narrowed (breaking for an author who wrote them, which the spec
25+
already refuses):
26+
27+
- `action:group` no longer publishes `name`. Nothing reads a group-level
28+
`name`; each member action's own `name` identifies it.
29+
- `actions` on `action:group` and `action:menu` is published as a list of action
30+
objects, not an `object`. Both blocks read the key as a list, so an object
31+
there could not render.
32+
- `action:group.size` publishes `default`, `sm`, `lg` and `icon`, and no longer
33+
`md`. A stored `md` still renders as before.
34+
35+
Still unpublished, pending a decision on objectui#11168: `endpoint` on
36+
`action:button` and `action:icon`, and `undoable` on `action:button`. The
37+
renderers keep forwarding both, so nothing changes at runtime.
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
---
2+
'@object-ui/app-shell': patch
3+
---
4+
5+
fix(app-shell): Studio's nav autosave sends every nav edit it has shown — "Done" sends the edit, and a completing save clears only what it sent
6+
7+
Two ways Studio's Interfaces pillar could show a nav edit on a writable package
8+
and never save it:
9+
10+
- **"Done" inside the autosave's debounce.** The nav autosave only runs while
11+
nav editing is open, so clicking "Done" within 1.5 s of an edit cancelled the
12+
pending save. The edit stayed on screen, unsaved, until nav editing was
13+
opened again, and the unsaved-changes guard stayed held.
14+
- **An edit taken while a nav save was in flight.** The completing save marked
15+
the navigation clean whatever had been edited meanwhile, and the re-read it
16+
triggers installed the saved document over the editor. The later edit
17+
disappeared from the screen, was never saved, and the unsaved-changes guard
18+
let go of it without a warning.
19+
20+
"Done" now saves an unsaved nav edit at once, waits for a save already in
21+
flight, and closes nav editing once everything shown has been saved. If that
22+
save fails, editing stays open with the error on screen. A completing save now
23+
marks the navigation clean only if nothing was edited after it was sent, so a
24+
later edit stays on screen, keeps the unsaved-changes guard, and goes out in the
25+
next save. A re-read of the same package (after a save, a publish, or a copilot
26+
change) no longer replaces navigation edits that have not been saved yet.
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
---
2+
'@object-ui/app-shell': patch
3+
'@object-ui/i18n': patch
4+
---
5+
6+
fix(app-shell): the save warning has a sentence of its own for a formula field the server ignored
7+
8+
objectstack `b2805465` gave the write path a fourth strip reason, `computed`: a
9+
value the caller sends for a `formula` field is stripped on every write path,
10+
because the server computes that field and has nowhere to store it. The save
11+
warning now words that reason as what it is — "Calculated by the server from a
12+
formula, so the value sent did not take effect: …" — through a new
13+
`detail.writeStrippedComputed` key in all ten locale packs, and never as a
14+
read-only lock, which would send the user after a permission problem that does
15+
not exist.
16+
17+
The reason table stays exhaustive over the spec's union, and one spelling now
18+
compiles against both the published `@objectstack/spec` 17.5.0 (which does not
19+
name the arm) and objectstack `main` (which does), which is what the
20+
`Spec Main Shape Gate` needs to go green again.
21+
22+
When the sentence reaches a user: the adapter judges a reported reason against
23+
the spec release this bundle is built with, and 17.5.0 does not declare
24+
`computed`, so until that release carries it a formula strip from a newer server
25+
is still reported as "Not applied by the server: …" — truthful, but without the
26+
cause. The new sentence is used from the spec release that declares the arm on.
Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
---
2+
'@object-ui/plugin-grid': minor
3+
'@object-ui/plugin-list': minor
4+
'@object-ui/plugin-kanban': minor
5+
---
6+
7+
A page size with nothing declared is now the one `@objectstack/spec` declares for
8+
`pagination.pageSize`, on every surface that has a pager; a fetch that has no
9+
pager keeps its own fetch batch, which does not follow it (objectui#9853).
10+
11+
"Page size" now means one page, and only where there is a pager. The grid,
12+
the list and the board read the display default from the spec (`PaginationConfigSchema`)
13+
instead of keeping numbers of their own, so it is declared once, in the protocol.
14+
`@objectstack/spec` 17.5.0 declares **50**. The views that fetch one window and
15+
page nothing keep a fetch batch of their own, with the value they had, so no
16+
view loses records it could reach before.
17+
18+
⚠️ **Visible change where no page size is declared.** Measured on the renderer
19+
with `@objectstack/spec` 17.5.0. Declare `pagination: { pageSize: N }` (or, on a
20+
board, `limit`) to keep an old count:
21+
22+
| surface (nothing declared) | before | after |
23+
|:--|--:|--:|
24+
| `object-grid` that fetches its own rows: rows per page, and the `$top` of each page fetch | 50 | 50 (unchanged) |
25+
| `object-grid` over inline `data`: rows per page | 10 | **50** |
26+
| grouped `object-grid`: groups per page | 10 | **50** |
27+
| grouped `object-grid` over a data source that groups on the server: rows per group page (`$top`) | 50 | 50 (unchanged) |
28+
| `list-view`, grid view (paged on the server): rows per page, and `$top` | 100 | **50** |
29+
| `list-view`, every view it does not page (kanban, calendar, gallery, timeline and the rest, and a grouped grid): the one fetch's `$top` | 100 | 100 (unchanged) |
30+
| `object-kanban` with no `limit`: the board's `$top` | 100 | 100 (unchanged) |
31+
32+
What changed underneath:
33+
34+
- **`@object-ui/plugin-grid`.** `ObjectGrid` falls back to the spec's display
35+
default on every page it shows, with no local number behind it: if a future
36+
spec stops declaring the default, the module throws at load instead of
37+
inventing one. The old "server window" constant is renamed
38+
`DEFAULT_FETCH_BATCH_SIZE` and keeps its value. Since grouping moved to the
39+
server, it is read only when the grid groups a window of rows in the browser
40+
because the server does not group it (a grouping key the principal may not
41+
read), and never as a page size. The grouped view's rows-per-page selector
42+
also lists the size in force when it is not one of its fixed steps.
43+
- **`@object-ui/plugin-list`.** `ListView` splits its undeclared fallback by
44+
whether the view pages. The grid view, which it pages on the server, falls
45+
back to the spec's display default. Every other view falls back to a fetch
46+
batch of 100, the value it had. A declared `pagination.pageSize` sizes the
47+
window on every view, as before. With no declared size, switching between the
48+
grid view and an unpaged view now changes the window, so the list fetches
49+
again: one request, whose `$top` is the fetch batch. That qualifies the
50+
objectui#10512 note in this same release, which says a switch into a dataset
51+
chart with no user filter set issues no new request: it still holds when a
52+
page size is declared. A refused page size still warns, and the warning names
53+
the fallback that view actually used.
54+
- **`@object-ui/plugin-kanban`.** The board's default `limit` is renamed from
55+
`DEFAULT_KANBAN_LIMIT` to `DEFAULT_KANBAN_FETCH_BATCH_SIZE` and stays 100. Its
56+
diagnostic for a refused `limit` now calls it the board's fetch batch.
57+
58+
The display default follows the `@objectstack/spec` a host installs. A host
59+
that resolves an older spec gets that spec's default, on every surface alike.
60+
61+
Released as `minor`, not `major`: this repository keeps its major aligned with
62+
`@objectstack/spec`, so the behaviour change is spelled out here instead.

‎apps/console/src/__tests__/public-block-binding-reach.test.tsx‎

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,19 @@ const NO_DATA_REACH: Readonly<Record<string, string>> = {
117117
// titles the panel.
118118
'record:related_list':
119119
'needs the parent record id from RecordContext before it may fetch; declines to fetch without one (objectstack#4413 ledger)',
120+
// objectui#11168 slice 1 published the spec key `objectName` on the two
121+
// action leaves, and on these blocks the key is not a data binding at all:
122+
// it names the object the ACTION acts on. The block draws a button and
123+
// fetches nothing; the key takes effect when the action is dispatched, where
124+
// the server-action route becomes `/api/v1/actions/{objectName}/{action}`
125+
// instead of the page's object. That dispatch read is pinned in
126+
// `packages/components/src/renderers/action/__tests__/action-button-icon-inputs-11168.test.tsx`;
127+
// what this ledger asserts is the other half — that the block still asks the
128+
// data layer for NOTHING under that name.
129+
'action:button':
130+
'objectName names the object the action is dispatched against (the server-action route), not a data binding; the block renders a button and fetches nothing (objectui#11168)',
131+
'action:icon':
132+
'objectName names the object the action is dispatched against (the server-action route), not a data binding; the block renders an icon button and fetches nothing (objectui#11168)',
120133

121134
// `list-view` and `embeddable-form` were the other two entries here for
122135
// exactly one release of this file. Neither registration bridged the
@@ -178,6 +191,11 @@ const EXPECTED_CANDIDATES = [
178191
// an `objectName`, so it joins this derived population — additive, and the
179192
// probe below is what decides whether the binding actually reaches.
180193
'object-tree',
194+
// objectui#11168 slice 1 published `objectName` on the two action leaves, so
195+
// they join the population too; both are ledgered in NO_DATA_REACH, because
196+
// on an action block the key is a dispatch target rather than a binding.
197+
'action:button',
198+
'action:icon',
181199
];
182200

183201
/**

0 commit comments

Comments
 (0)