Uh oh!
There was an error while loading. Please reload this page.
feat(chart): grouped series for multi-dimension dataset charts (#1759) - #1761
Merged
Conversation
…k#1890) Chart views (list `type:'chart'` + object chart view) only read the removed legacy inline `xAxisField`/`yAxisFields`/`aggregation` shape, so a chart authored to the current spec (ADR-0021: dataset + dimensions + values) rendered nothing. - ObjectChart: when `schema.dataset` is set, fetch via the governed `dataSource.queryDataset` path (same as dashboard DatasetWidget) instead of the legacy single-object aggregate; server resolves dimension labels + formats. - object-chart schema (types): `objectName`/`xAxisField` now optional; added optional `dataset`/`dimensions`/`values`. - ListView + ObjectView (plugin-view & app-shell): chart case emits the dataset shape when `chart.dataset` is set; legacy aggregate kept as deprecated fallback. Verified in-browser: showcase task "Hours by Status (Chart)" view (binds showcase_task_metrics) now renders a bar chart (was blank before). Refs objectstack-ai/objectstack#1890 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
) Dataset charts with two dimensions only rendered the first; the second was invisible (repeated x-axis labels, no grouping/legend). - @object-ui/core: new shared buildChartSeries(rows, dimensions, values, fields) — pivots a 2nd dimension (single measure) into one series per distinct value (long→wide); otherwise first dim = x-axis, measures = series. Unit-tested. - ObjectChart (plugin-charts): dataset mode derives data/xAxisKey/series via buildChartSeries instead of only honouring dimensions[0]. - DatasetWidget (plugin-dashboard): chart branch uses the same helper, so dashboard + chart-view render multi-dim charts identically. Refs #1759, objectstack-ai/objectstack#1890 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The latest updates on your projects. Learn more about Vercel for GitHub. |
Contributor
✅ Console Performance Budget
📦 Bundle Size Report
Size Limits
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for freeto join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Follow-up to #1757 (closes#1759). A dataset-bound chart with two dimensions (e.g.
dimensions: ['status','priority']) previously only honoured the first dimension:xAxisKey = dimensions[0],series = values. The second dimension was invisible — the x-axis just repeated the first-dimension label once per second-dimension bucket, with no grouping/colour/legend. Data was correct; the second dimension wasn't visualised.Change
@object-ui/core— new sharedbuildChartSeries(rows, dimensions, values, fields):xAxisKey= first dimension.ObjectChart(plugin-charts) — dataset mode now derivesdata/xAxisKey/seriesvia the helper.DatasetWidget(plugin-dashboard) — chart branch uses the same helper, so dashboard widgets and chart views render multi-dimension charts identically (grouped/coloured bars + legend).Verification
buildChartSeriesunit tests (5) cover single-dim, multi-measure, two-dim pivot, field labels, nullish input — all green.@object-ui/core,plugin-charts,plugin-dashboardbuild green.Refs objectstack-ai/objectstack#1890