feat(api): expose table tile alternateRowBackground in the external Dashboards API#2698
feat(api): expose table tile alternateRowBackground in the external Dashboards API#2698alex-fedotyev wants to merge 2 commits into
Conversation
…ashboards API Follow-up to #2519, which added the Alternate Row Background display setting to table tiles in the app and internal schema. That field lives on the shared chart-settings schema, so it applies to both builder and raw SQL table tiles. This exposes it in the external REST Dashboards API on both the builder and raw SQL table chart configs, alongside the OpenAPI docs, so API consumers can set striping wherever the UI allows it. Round-trip integration coverage is extended for POST and PUT on both config kinds. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
🦋 Changeset detectedLatest commit: 11e1ef6 The changes in this PR will be included in the next version bump. This PR includes changesets to release 3 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
🔴 Tier 4 — CriticalTouches auth, data models, config, tasks, OTel pipeline, ClickHouse, or CI/CD. Why this tier:
Review process: Deep review from a domain expert. Synchronous walkthrough may be required. Stats
|
Greptile SummaryThis PR exposes table zebra striping in the external Dashboards API. The main changes are:
Confidence Score: 5/5This looks safe to merge.
Important Files Changed
Reviews (2): Last reviewed commit: "test(api): pin alternateRowBackground om..." | Re-trigger Greptile |
E2E Test Results✅ All tests passed • 242 passed • 1 skipped • 1063s
Tests ran across 4 shards in parallel. |
Deep ReviewScope: Environment note: The shell was non-functional in this run ( ✅ No critical issues found. The change is a clean, symmetric additive field that mirrors the existing 🟡 P2 -- recommended
🔵 P3 nitpicks (1)
Reviewers (4): correctness, adversarial, testing, api-contract. Testing gaps:
|
Adds a table-tile case asserting that omitting alternateRowBackground leaves it absent on read-back, and that an explicit false persists, mirroring the existing omits-orderBy coverage. Addresses a review nit on the field's test coverage. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Summary
Follow-up to #2519, which added the Alternate Row Background display setting (zebra striping) to table tiles in the app and the internal chart schema. That PR shipped the app and
common-utilsslice only; this brings the setting to the external REST Dashboards API.The field lives on the shared chart-settings schema rather than the builder-only config, so it applies to both builder and raw SQL table tiles (we moved it up to the shared schema during the #2519 review so SQL tiles get striping too). The external API now matches:
alternateRowBackground(optional boolean) to both the builder table config and the raw SQL table config in the request/response schemas (zod.ts).onClickfield.TableBuilderChartConfigandTableRawSqlChartConfig, and regeneratesopenapi.json.No new helpers; every edit sits beside the existing
groupByColumnsOnLeft/onClickfields on the same schema, converter, and JSDoc block.Test plan
alternateRowBackground: trueon both a builder table tile and a raw SQL table tile. The raw SQL assertions are new coverage that guards the SQL path.dashboards.int.test.ts: 162/162 passing locally against a ClickHouse + MongoDB stack. This is the end-to-end round-trip proof (POST a dashboard with the field, read it back, field preserved on both config kinds).tsc --noEmit, eslint, and spectral (lint:openapi) all clean.Tier
This lands
review/tier-4because it necessarily touchespackages/api/src/routers/external-api/, which the triage classifier always treats as critical-path. The change itself is small (38 production lines) and mirrors the existinggroupByColumnsOnLeftandonClickfields.Not in this PR