Repository navigation
fix(plugin-dashboard): the editable grid's object-bound table fetches its rows, and its object-bound pivot shows the retired-widget placeholder (objectui#10528) - #10596
Conversation
…fetches its rows (objectui#10528)
DashboardGridLayout mapped a table-family widget whose data is
`{ provider: 'object', object }` to a static `data-table` node with
`data: []` and an `objectName` that `data-table` never reads, so the tile
drew an empty table and issued no query. DashboardRenderer maps the same
stored widget to the self-fetching `object-data-table`.
The grid's table arm now emits that node with the renderer's props: the
provider filter, the declared searchable/pagination (never on a list), and
default-on drill-to-record. Drag stays gated to the `.drag-handle`
element, and the grid has no widget selection, so the row drill does not
fight the editor. A parity pin holds the two copies equal. The static
branches and the provider-object pivot arm are unchanged.
Claude-Session: https://claude.ai/code/session_01KUxVUa7e39aNjhkKi1gsoy
Co-authored-by: Claude <noreply@anthropic.com>
…-pivot-fetch Claude-Session: https://claude.ai/code/session_01KUxVUa7e39aNjhkKi1gsoy Co-authored-by: Claude <noreply@anthropic.com>
✅ Console Performance Budget
The eager closure is every chunk the entry reaches through static imports — what the browser fetches and parses before the app renders. The entry chunk on its own is a small fraction of it. 📦 Bundle Size Report
Size Limits
|
…vot like the read dashboard (objectui#10528) Round 2 of the card, amended claim 5831757648 (option B). The grid's pivot arm turned a `provider: 'object'` pivot into a static `pivot` node with `data: []` and an `objectName` PivotTable never reads, so it drew an empty cross-tab and sent no query. DashboardRenderer answers every non-dataset pivot with LEGACY_RETIRED_WIDGET_SCHEMA, since ADR-0021 puts a cross-tab on the dataset layer only. The grid's provider-object pivot branch now returns that same shared object. The static-data pivot branch is unchanged. DashboardRenderer's pivot-arm comment (comment only) now says the grid still draws static-data pivots and retires the provider-object shape. The 7353 pin's grid-pivot row, which pinned the removed branch, is replaced by a row pinning the placeholder. The 10528 pin gains a placeholder case and a same-object parity case against the renderer. The changeset covers both halves and stays patch. Claude-Session: https://claude.ai/code/session_01KUxVUa7e39aNjhkKi1gsoy Co-authored-by: Claude <noreply@anthropic.com>
✅ Console Performance Budget
The eager closure is every chunk the entry reaches through static imports — what the browser fetches and parses before the app renders. The entry chunk on its own is a small fraction of it. 📦 Bundle Size Report
Size Limits
|
…objectui#10528 The pending `.changeset/7353-retire-widget-dataprovider.md` said the grid's provider-object `data-table` and `pivot` nodes still write `objectName`. After objectui#10528 the grid builds the self-fetching `object-data-table` for such a table widget and shows the retired-widget placeholder for such a pivot widget, which writes no `objectName`. Only those two sentences of that bullet change; the front matter and every other sentence are byte-identical. Prose only, authorized by the seat for this card's ACCEPT. Claude-Session: https://claude.ai/code/session_01KUxVUa7e39aNjhkKi1gsoy Co-authored-by: Claude <noreply@anthropic.com>
✅ Console Performance Budget
The eager closure is every chunk the entry reaches through static imports — what the browser fetches and parses before the app renders. The entry chunk on its own is a small fraction of it. 📦 Bundle Size Report
Size Limits
|
Contract reviewServed-tier: ① Derived judgmentsRead: card objectui#10528 (body); triage Behaviour changes, item by item (line numbers at the head):
Existing pins edited or deleted:
New pins can fail:
② Semver level
10528 changeset prose, sentence by sentence:
Pending
Docs/README prose added by the diff: none. No ③ Boundary flagsPR body flags and open questions:
CI at the head Draft: yes (
Main movement: Implemented-by: VERDICT: PASS |
Fixes #10528
Clause-②: no
What changed
The editable
dashboard-grid(DashboardGridLayout) turned a table-family widget whose data is{ provider: 'object', object }into a staticdata-tablenode. That node haddata: []and anobjectNamethatdata-tablenever reads. So the tile drew an empty table and sent no query.DashboardRendererturns the same stored widget intoobject-data-table, which fetches its rows.The grid's table arm now emits the same node
DashboardRenderer's table arm emits, prop for prop:typedata-tableobject-data-tabledata[]filterfilter, else the widget'sfiltersearchable/paginationfalsewidget.searchable ?? false/widget.pagination ?? false; alwaysfalseon alistdrillDownoptions.drillDown ?? { enabled: true, mode: 'record' }objectName,className, and the...optionsspread withoutdataFiles changed, round 1 (the table half):
packages/plugin-dashboard/src/DashboardGridLayout.tsx: only theprovider: 'object'branch of the table arm;Rounds 2 and 3 (below) add the pivot half and two prose corrections: at the head the PR changes six files.
DashboardGridLayout.tsx's provider-object pivot branch,DashboardRenderer.tsx's pivot-arm comment (comment only), the 7353 pin's grid-pivot row and the pending7353changeset's prose all move. These stay byte-unchanged: the static-data branches of the table and pivot arms.drillDown on the editable grid: kept on by default, as on the renderer
I measured this with a one-off probe on the fixed tree, in "Edit Layout" mode. The probe was not committed.
happy-dom gives the grid a zero width and a null
offsetParent, and react-grid-layout's drag start returns early without anoffsetParent. So the probe stubbed both. In the first two runs, without those stubs, the positive control did not fire either, so I discarded those readings..drag-handlereact-draggable-dragging)record-detail-body)On the grid, a drag can start only from
dragConfig.handle: '.drag-handle'. The grid also has no widget selection: there is noonWidgetClickorselectedWidgetId, unlikeDashboardRenderer's design mode. So a row click cannot start a drag or a selection, and the renderer's default stays as it is. There is no difference to pin, and the parity pin keeps the two nodes equal.Round 1: the provider-object pivot arm stopped at the decision
I measured the dispatch's pivot hypothesis, and the pivot half stops here:
object-pivot(ObjectPivotTable) exists and is registered. It fetches throughobjectNameandfilter, then cross-tabs the rows client-side overrowField/columnField/valueField/aggregation. It reads no provideraggregate.widgetDispatch.tsdocuments the family as "Cross-tab — dataset-bound only; a non-dataset pivot is stale metadata."DashboardRenderer's pivot arm answers every non-dataset pivot withLEGACY_RETIRED_WIDGET_SCHEMA.LEGACY_WIDGET_ANALYTICS_KEYSnamesrowField/columnField/valueField/aggregationas part of the removed pre-ADR-0021 inline analytics shape.Round 1 left that arm untouched and took the question to the card, analysed on the four axes. The seat decided it (option B) in the amended claim
5831757648; round 2 below carries it out.Round 2 (claim
5831757648, head7a4f697)The seat took option B for the pivot half (amended claim
5831757648): the grid'sprovider: 'object'pivot arm is retired, the same answer the read dashboard gives (ADR-0021).DashboardGridLayout.tsx: the pivot arm's provider-object branch returnsLEGACY_RETIRED_WIDGET_SCHEMA, imported from./legacyRetiredWidget(the renderer's own source; no second copy). The static-data pivot branch is byte-unchanged.DashboardRenderer.tsx: comment only (0 non-comment lines). The pivot-arm comment now says the grid still draws static-data pivots and answers the provider-object pivot with the same placeholder.widgetDataProviderRetired-7353.test.tsx: the grid-pivot row that pinned the removed branch is replaced by a row pinning the placeholder (identity), with nofindcall, citing the claim.DashboardGridLayout.objectProviderFetch-10528.test.tsx: an object-provider pivot on the grid renders the placeholder and calls nofind; the grid andDashboardRendererhandSchemaRendererthe same placeholder object for the same widget. The static-data table and pivot lit controls and all table-half pins stay green.DashboardGridLayout.tsxat the round-2 base,Tests 3 failed | 12 passed (15)(exit 1; exactly the three pivot cases); at7a4f697,Tests 15 passed (15)(exit 0).7a4f697: the plugin-dashboard suite plus 13 cross-package readers (143 files, 1712 tests, exit 0);type-checkfor@object-ui/plugin-dashboard(exit 0); eslint (0 errors, no new warnings); the control-byte, test-path, vi-mock, line-citation and changeset gates (exit 0 each);check-governed-queue-guardNOT GOVERNED. CI: 43 check-runs, 40 success, 3 skipped, 0 failed.patch.Pins
packages/plugin-dashboard/src/__tests__/DashboardGridLayout.objectProviderFetch-10528.test.tsxheld 8 tests in round 1; round 2 adds the two pivot cases (10 at the head):object-data-table, withobjectName: 'account'and nodataProvider. The adapter'sfindis called, and only foraccount. The rows it returns (Acme,Globex) are on screen.filterreachesfindas$filter.toEquals the nodeDashboardRenderercomposes. The widgets: a plain table; a table with a provider filter,searchable,paginationandcolumns; alistwithsearchableandpaginationauthored; a table with an authoreddrillDown.data-table/pivot, and never callfind.Red, then green, run from the committed state. The script is trap-guarded. The restore is proven by the file's blob hash equalling
HEAD's and by an emptygit diff HEAD.DashboardGridLayout.tsxat basee5f4343HEAD6e9abeaGates, on
6fce3f1(after mergingorigin/mainatcaf0ed0)pnpm exec vitest run --maxWorkers=2 packages/plugin-dashboard/, plus the 9 test files outside the package that render or read the grid: 139 files (130 package files + 9), 1562 tests passed, exit 0.pnpm turbo run type-check --filter @object-ui/plugin-dashboard --concurrency=2: 14/14 tasks, exit 0. The package task was a cache miss and ran bothtsclegs, andtsconfig.test.json --listFilesOnlylists the new pin.check:control-bytes,check:test-path-rootscheck:vi-mock-specifiers,check:vi-mock-inherit,check:vi-mock-override-shapecheck:new-line-citations(0 new; report-only)check:changeset-claims,check:pending-changeset-literalscheck-changeset-presence,check-changeset-no-majorcheck-governed-queue-guard --teston the 3 paths: NOT GOVERNED.Acceptance notes
--format jsoncounts 2 files linted.no-explicit-anywarnings, in the listener mock copied fromwidgetDataProviderRetired-7353.test.tsx. This repo deliberately leaves--max-warningsunset.eslint-rules/rule reads other files. So this diff cannot change the lint verdict of any file it does not touch.pnpm lintrun is CI's.widgetDataProviderRetired-7353.test.tsx, the grid table row still passes. It now reads thedata-tablenode thatObjectDataTablerenders onward, not a node the grid composes. The new pin checks that the grid's ownobject-data-tablenode carries nodataProvider. The row's name ("becomes a data-table node") now describes that onward node. That table row is left as it is; round 2 edits only the file's grid-pivot row, which the amended claim5831757648brought into the surface.data-table/pivotnodes false (the grid now buildsobject-data-tablefor a provider-object table and the retired-widget placeholder for a provider-object pivot). The prose round (3e3c9ae, seat-authorized) rewrote those two sentences so each reads true at the head; its front matter is byte-identical.10528-grid-object-table-fetch.md, not the dispatched10528-grid-object-table-pivot-fetch.md; the name dates from round 1. It now covers both halves, and it is kept as is because the presence gate passes with it.dataSourceprop. The grid hands itsdataSourceprop toDatasetWidgetonly. Theobject-*nodes it composes, the new table node included, read the adapter fromSchemaRendererContext.DashboardRendereralso passes its prop to each childSchemaRenderer. Not measured as reachable: no host in this repo mounts the grid outside a provider. Carrier: none. Noted, not filed.DashboardRenderer's pivot-arm comment. It says the grid "does still draw pivots from static data and from theprovider: 'object'config". In effect, the second half has been false: the grid draws an empty pivot and sends no query. This belongs to the pivot decision.content/docsstatement covers the grid's object-bound tables (checked by grepping fordashboard-gridandDashboardGridLayout), so no doc edit is owed.Session:
https://claude.ai/code/session_01KUxVUa7e39aNjhkKi1gsoyGenerated by Claude Code