Phase D5 — KPI panel: scalar and named-tuple cards - #231
Merged
Conversation
Add canonical one-row scalar and named-tuple KPI cards with exact typed formatting, shared rendering, panel-owned transport, conservative auto-detection, and consistent workbench, dashboard, and detached execution. Co-Authored-By: OpenAI Codex <noreply@openai.com> Claude-Session: Codex
Enable alias-derived tuple member names in the importable example and document both the query setting and explicit named Tuple cast forms. Co-Authored-By: OpenAI Codex <noreply@openai.com> Claude-Session: Codex
Let the shared KPI panel grow across its dashboard flex host so responsive cards flow horizontally at wide widths while retaining the mobile single-column layout. Co-Authored-By: OpenAI Codex <noreply@openai.com> Claude-Session: Codex
Bound KPI cards to 220–280px tracks, keep each row at its natural tallest-card height, and let KPI tiles use content height in Report and Full-width dashboard layouts. Co-Authored-By: OpenAI Codex <noreply@openai.com> Claude-Session: Codex
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.
What & why
Closes #154.
Adds KPI as a first-class saved-query Presentation Spec panel for exact one-row numeric scalars and named tuples. The canonical schema, pure reader/formatter, shared renderer, and panel-owned typed transport are used consistently by workbench, dashboard, and detached reruns.
Highlights:
The unrelated parallel cold-start E2E server flake discovered during validation is tracked separately in #230.
Verification
npm test— 91 files, 2563 tests, 100% statements/linesnpm run build— single-filedist/sql.htmlnpm run test:e2e -- --workers=1— 96 passed across Chromium, Firefox, and WebKitnpx playwright test tests/e2e/kpi.spec.js --workers=1— 9 passed after final precision fixesnpm audit --omit=dev— 0 vulnerabilitiesChecklist
npm testpasses (the per-file coverage gate is non-negotiable)npm run buildsucceeds (single-filedist/sql.html)src/core/, network insrc/net/(injected fetch), DOM insrc/ui/CHANGELOG.md([Unreleased]) updated