feat(dashboard): add structured header and multi-measure pivot support#719
Merged
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Copilot
AI
changed the title
[WIP] Enhance DashboardSchema to support custom header and multi-measure analysis
feat(dashboard): add structured header and multi-measure pivot support
Feb 18, 2026
hotlong
marked this pull request as ready for review
February 18, 2026 07:44
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds two key protocol enhancements to DashboardSchema for Airtable dashboard feature parity:
- Structured Header Configuration: Introduces
DashboardHeaderSchemawithshowTitle,showDescription, and action buttons (DashboardHeaderActionSchema) for dashboard headers. - Multi-Measure Pivot Support: Adds
WidgetMeasureSchemaenabling pivot/matrix widgets to display multiple aggregated measures (e.g., sum of revenue, count of deals, avg margin) in a single widget.
Both features are optional and fully backward compatible, following the repository's "Zod First" architecture and camelCase configuration key conventions.
Changes:
- Added
DashboardHeaderActionSchemaandDashboardHeaderSchemato dashboard.zod.ts with proper validation and optional fields - Added
WidgetMeasureSchemasupporting valueField, aggregate (count/sum/avg/min/max), label, and format fields - Integrated header configuration as optional field on
DashboardSchema - Integrated measures array as optional field on
DashboardWidgetSchema - Added comprehensive test coverage (20 new tests) covering schema validation, backward compatibility, and integration scenarios
- Updated ROADMAP.md to mark Phase 1 protocol items as complete
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| packages/spec/src/ui/dashboard.zod.ts | Added DashboardHeaderSchema, DashboardHeaderActionSchema, and WidgetMeasureSchema with proper validation; integrated header and measures into main schemas; exported new types |
| packages/spec/src/ui/dashboard.test.ts | Added 20 comprehensive tests covering header actions, header schema, widget measures, and full integration scenarios with Dashboard.create factory |
| ROADMAP.md | Marked dashboard header and multi-measure pivot protocol items (issue #714) as complete in Phase 1 |
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 free
to 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.
DashboardSchemalacks a structured header configuration and pivot/matrix widgets only support a single measure. This adds both capabilities as optional extensions with full backward compatibility.Schema additions (
dashboard.zod.ts)DashboardHeaderSchema—showTitle(default true),showDescription(default true),actions[]ofDashboardHeaderActionSchema(label, actionUrl, actionType?, icon?)WidgetMeasureSchema—valueField,aggregate(default count),label?,format?for multi-measure pivot/matrix analysisDashboardSchema.header— optional structured header configDashboardWidgetSchema.measures— optional array ofWidgetMeasureSchemaUsage
Tests & docs
Dashboard.createOriginal prompt
💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.