Skip to content

Commit 918e7e1

Browse files
xuyushun441-sysos-zhuangclaude
authored
docs(ui): document dashboard drill-in (drill-through + drill-to-record chain) (#2126)
Dashboards drill in two ways and the docs/skill didn't cover it — the objectstack-ui skill even had a 'Drilldown' header with no content. Documents: - table/pivot dataset widgets drill through to the underlying records (raw group keys preserved); the drilled record list now drills into the clicked record, completing the group → records → record chain. - metric/chart dataset widgets are not click-drillable (surface detail via a table/pivot widget). - the ObjectUI renderer's richer options.drillDown block (mode filter|record, drawer/dialog target, column whitelist, scatter/treemap/sankey chart drill) for object/record-backed surfaces. Fixes the guide's overclaim that every dataset widget has 'drill-down affordances', and notes the completed record chain in implementation-status. Co-authored-by: Jack Zhuang <277994282+os-zhuang@users.noreply.github.com> Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
1 parent 173f420 commit 918e7e1

3 files changed

Lines changed: 69 additions & 4 deletions

File tree

content/docs/concepts/implementation-status.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -208,7 +208,7 @@ The data (`/data`), metadata (`/meta`), and batch endpoints are implemented in `
208208
| **FormView** || 🟡 | 🟡 ObjectUI forms support live field rules (`visibleWhen` / `readonlyWhen` / `requiredWhen`), inline-grid row rules, and server-aligned required enforcement |
209209
| **Page** || 🟡 | 🟡 Record-page authoring, page create flows, block canvas editing, slotted record pages, and selected page blocks are implemented in ObjectUI; full component catalogue remains in progress |
210210
| **App** || 🟡 | 🟡 Navigation metadata is consumed by the console/app shell; full renderer parity remains in progress |
211-
| **Dashboard** || 🟡 | 🟡 ObjectUI renders metric/chart/list/pivot/funnel/table widgets, drill-downs, type-aware cells, and dataset-bound widgets; Studio can author per-widget dataset bindings (`dataset` / `dimensions` / `values`) |
211+
| **Dashboard** || 🟡 | 🟡 ObjectUI renders metric/chart/list/pivot/funnel/table widgets, drill-downs (group → records → record chain), type-aware cells, and dataset-bound widgets; Studio can author per-widget dataset bindings (`dataset` / `dimensions` / `values`) |
212212
| **Report** || 🟡 | 🟡 ObjectUI renders spec-native tabular/summary/matrix/joined reports, chart/KPI blocks, drill-downs, and dataset-bound reports |
213213
| **Action** || 🟡 | 🟡 ObjectUI supports row/global/header actions, action modal transport, parameter collection, visibility CEL, and nested action runners |
214214
| **Component** || 🟡 | 🟡 Selected page/record components render in ObjectUI (`record:alert`, related lists, highlights, page blocks); catalogue parity remains in progress |

content/docs/guides/metadata/dashboard.mdx

Lines changed: 42 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -164,9 +164,10 @@ the base object and joined objects.
164164

165165
ObjectUI currently renders dataset-backed metric, chart,
166166
table/list, pivot, funnel, and gauge-style widgets with type-aware cells,
167-
field/option labels, date bucketing, numeric/currency formatting, and
168-
drill-down affordances. Use declarative drill-down settings and preserve raw
169-
group keys so the generated filter can navigate to the underlying records.
167+
field/option labels, date bucketing, and numeric/currency formatting.
168+
`table` and `pivot` widgets are also **drill-through** (see
169+
[Drill-down](#drill-down) below); the dataset preserves raw group keys so the
170+
generated filter navigates to the exact underlying records.
170171

171172
### Chart Types
172173

@@ -188,6 +189,44 @@ group keys so the generated filter can navigate to the underlying records.
188189
Additional types: `horizontal-bar`, `column`, `donut`, `sankey`, `solid-gauge`,
189190
`kpi`, and `bullet`. The default type is `metric`.
190191

192+
### Drill-down
193+
194+
`table` and `pivot` widgets are **drill-through**: clicking an aggregated row
195+
(table) or cell (pivot) opens a side drawer listing the **underlying records**
196+
behind that group. Because the dataset preserves each grouped row's raw group
197+
keys, the drawer's filter matches the exact records — no label-to-id guessing.
198+
199+
The drilled record list is itself **drill-to-record**: click any row in the
200+
drawer to open that single record's detail. This completes the
201+
**group → records → record** chain (e.g. *Revenue by Region* → the orders in
202+
the *West* bucket → one order).
203+
204+
```typescript
205+
// A drill-through table widget. No drill configuration is required — it is
206+
// automatic whenever the dataset exposes the base object and the widget groups
207+
// by at least one dimension.
208+
{
209+
id: 'orders_by_region',
210+
title: 'Orders by Region',
211+
type: 'table',
212+
dataset: 'sales',
213+
dimensions: ['region'],
214+
values: ['revenue', 'deal_count'],
215+
layout: { x: 0, y: 0, w: 6, h: 4 },
216+
}
217+
```
218+
219+
Drill-through is automatic — there is no per-widget drill configuration in the
220+
dataset form. `metric` and `chart` widgets render the aggregate only and are not
221+
click-drillable; expose the detail through a `table`/`pivot` widget instead.
222+
223+
> **Renderer note.** Object/record-backed list and table surfaces (and the
224+
> ObjectUI renderer's `options.drillDown` block) support a richer drill model —
225+
> a `mode: 'filter' | 'record'` discriminator, drawer-vs-dialog target, a column
226+
> whitelist, and chart-segment drill for the `scatter` / `treemap` / `sankey`
227+
> families. Those knobs live in the renderer; dataset-bound dashboards drill
228+
> through the semantic layer as described above.
229+
191230
### Aggregation Functions
192231

193232
Aggregation is declared on the dataset's **measures** (via `aggregate`), not on

skills/objectstack-ui/SKILL.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -952,6 +952,32 @@ defineDataset({
952952
compareTo: 'previousYear' }
953953
```
954954

955+
### Drilldown
956+
957+
Dashboards drill in two ways: **drill-through** turns an aggregate into the rows
958+
behind it; **drill-to-record** opens one record.
959+
960+
* **`table` / `pivot` widgets drill through.** Clicking an aggregated table row
961+
or pivot cell opens a side drawer listing the underlying records. The dataset
962+
preserves each grouped row's raw group keys, so the drawer filters to the
963+
*exact* records (no label→id guessing). Automatic — no per-widget config.
964+
* **The drilled record list drills to record.** Any row in that drawer opens the
965+
single record's detail, completing the **group → records → record** chain.
966+
* **`metric` / `chart` widgets are not click-drillable** in the dataset form
967+
(they render the aggregate only; `compareTo` still applies). Surface the detail
968+
through a `table` / `pivot` widget instead.
969+
970+
> **Renderer note (object/record-backed surfaces).** The ObjectUI renderer
971+
> exposes a richer `options.drillDown` block for non-dataset list/table widgets
972+
> and the drill drawers — `enabled`, `mode` (`'filter'` = aggregate → filtered
973+
> list; `'record'` = row → that record), `target` (`'drawer'` | `'dialog'`),
974+
> `columns` (whitelist), and `title` (`${event.*}` interpolation). At the
975+
> renderer level drill-through covers the `bar` / `line` / `area` / `pie` /
976+
> `donut` / `funnel` / `scatter` / `treemap` / `sankey` families and pivot
977+
> cell/row/column/total clicks (`radar` is excluded — no single clickable
978+
> category point). **Dataset-bound dashboards use the semantic-layer drill above
979+
> and ignore this block.**
980+
955981
| `dateGranularity` | Rendered bucket label |
956982
|:--|:--|
957983
| `'day'` | `YYYY-MM-DD` |

0 commit comments

Comments
 (0)